mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-23 02:41:50 +03:00
3f1e5b9fa9
refs https://github.com/TryGhost/Ghost/issues/9311 - wraps embed card in same container as the markdown card to handle mouse selection/edit toggles etc - add render mode to embed card - autofocus CodeMirror editor when switching to edit mode - fix incorrect pointer on cards
19 lines
483 B
Handlebars
19 lines
483 B
Handlebars
{{#koenig-card
|
|
icon="koenig/markdown"
|
|
isSelected=isSelected
|
|
isEditing=isEditing
|
|
onEnterEdit=(action "enterEditMode")
|
|
selectCard=(action selectCard)
|
|
editCard=(action editCard)
|
|
}}
|
|
{{#if isEditing}}
|
|
{{gh-textarea
|
|
class="koenig-card-markdown"
|
|
value=payload.markdown
|
|
update=(action "updateMarkdown")
|
|
autoExpand=".gh-koenig-editor"}}
|
|
{{else}}
|
|
{{renderedMarkdown}}
|
|
{{/if}}
|
|
{{/koenig-card}}
|