Ghost/ghost/admin/lib/koenig-editor/addon/templates/components/koenig-card-markdown.hbs
Kevin Ansfield 4f08b7fb8d Koenig - Switch card context menu to Spirit classes
refs https://github.com/TryGhost/Ghost/issues/9505
- use Spirit classes for card context menu
- add button and icon class options for context menu items
- add ability to have icon+text for context menu items
- add "Edit" context menu item to markdown and html cards
2018-04-03 18:34:01 +01:00

22 lines
613 B
Handlebars

{{#koenig-card
icon="koenig/markdown"
class=(kg-style "container-card")
toolbar=toolbar
isSelected=isSelected
isEditing=isEditing
onEnterEdit=(action "enterEditMode")
onLeaveEdit=(action "leaveEditMode")
selectCard=(action selectCard)
editCard=(action editCard)
}}
{{#if isEditing}}
{{gh-textarea
class="koenig-card-markdown"
value=(readonly payload.markdown)
input=(action "updateMarkdown" value="target.value")
autoExpand=".gh-koenig-editor"}}
{{else}}
{{renderedMarkdown}}
{{/if}}
{{/koenig-card}}