mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-13 22:41:32 -05:00
349fd649f8
Fixes #3813 - Add togglePreview action to controller - Implement action and bind attributes - Remove the now pointless - Update to comply with issue suggestions
35 lines
No EOL
1.5 KiB
Handlebars
35 lines
No EOL
1.5 KiB
Handlebars
<header class="page-header">
|
|
<a class="menu-button" href="#"><span class="sr-only">Menu</span></a>
|
|
<h2 class="page-title">Editor</h2>
|
|
</header>
|
|
|
|
<div class="page-content">
|
|
<header>
|
|
<section class="box entry-title">
|
|
{{gh-trim-focus-input type="text" id="entry-title" placeholder="Your Post Title" value=titleScratch tabindex="1" focus=shouldFocusTitle}}
|
|
</section>
|
|
</header>
|
|
|
|
<section {{bind-attr class=":entry-markdown isPreview::active"}}>
|
|
<header {{action "togglePreview" false}} class="floatingheader">
|
|
<small>Markdown</small>
|
|
<a class="markdown-help" href="" {{action "openModal" "markdown"}}><span class="hidden">What is Markdown?</span></a>
|
|
</header>
|
|
<section id="entry-markdown-content" class="entry-markdown-content">
|
|
{{gh-codemirror value=scratch scrollInfo=view.markdownScrollInfo setCodeMirror="setCodeMirror" openModal="openModal"}}
|
|
</section>
|
|
</section>
|
|
|
|
<section {{bind-attr class=":entry-preview isPreview:active"}}>
|
|
<header {{action "togglePreview" true}} class="floatingheader">
|
|
<small>Preview <span class="entry-word-count js-entry-word-count">{{gh-count-words scratch}}</span></small>
|
|
</header>
|
|
<section class="entry-preview-content">
|
|
{{gh-markdown markdown=scratch scrollPosition=view.scrollPosition
|
|
uploadStarted="disableCodeMirror" uploadFinished="enableCodeMirror" uploadSuccess="handleImgUpload"}}
|
|
</section>
|
|
</section>
|
|
|
|
{{partial "publish-bar"}}
|
|
|
|
</div> |