2018-02-15 18:57:44 +03:00
|
|
|
{{#koenig-card
|
2018-03-14 14:44:09 +03:00
|
|
|
class=(concat (kg-style "media-card") " mih10 miw-100 tc")
|
2018-04-03 20:34:01 +03:00
|
|
|
toolbar=toolbar
|
2018-02-15 18:57:44 +03:00
|
|
|
isSelected=isSelected
|
|
|
|
isEditing=isEditing
|
|
|
|
selectCard=(action selectCard)
|
|
|
|
editCard=(action editCard)
|
2018-03-15 20:54:15 +03:00
|
|
|
onLeaveEdit=(action "leaveEditMode")
|
2018-02-03 21:20:50 +03:00
|
|
|
}}
|
2018-02-15 18:57:44 +03:00
|
|
|
{{#if isEditing}}
|
|
|
|
{{gh-cm-editor payload.html
|
|
|
|
class="koenig-card-html--editor"
|
|
|
|
autofocus=true
|
|
|
|
update=(action "updateHtml")
|
|
|
|
}}
|
2018-02-20 18:53:58 +03:00
|
|
|
|
|
|
|
<input
|
|
|
|
value={{payload.caption}}
|
|
|
|
type="text"
|
|
|
|
class="miw-100 tc bn form-text"
|
|
|
|
oninput={{action "updateCaption" value="target.value"}}
|
|
|
|
placeholder="Type caption for embed (optional)">
|
2018-02-15 18:57:44 +03:00
|
|
|
{{else}}
|
|
|
|
{{{payload.html}}}
|
2018-02-20 18:53:58 +03:00
|
|
|
|
|
|
|
{{#if payload.caption}}
|
|
|
|
<p class={{kg-style "figcaption"}}>{{{payload.caption}}}</p>
|
|
|
|
{{/if}}
|
|
|
|
|
2018-02-15 20:14:30 +03:00
|
|
|
<div class="koenig-card-click-overlay"></div>
|
2018-02-15 18:57:44 +03:00
|
|
|
{{/if}}
|
|
|
|
{{/koenig-card}}
|