mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-29 07:09:48 +03:00
be01fa6920
refs https://github.com/TryGhost/Team/issues/459 - pass required properties+actions through editor->post preview modal->publish menu - replace publish button placeholder with `<GhPublishMenu>` - close modal when saving if not a silent save
41 lines
2.2 KiB
Handlebars
41 lines
2.2 KiB
Handlebars
<div class="flex flex-column h-100">
|
|
<header class="modal-header gh-post-preview-header gh-post-preview-header-border" data-test-modal="preview-email">
|
|
<div>
|
|
<button class="blue link" title="Close" {{on "click" this.close}}>
|
|
{{svg-jar "arrow-left" class="w3 fill-blue mr1 nudge-right--2 nudge-top--1"}}
|
|
Back
|
|
</button>
|
|
</div>
|
|
<div class="gh-contentfilter gh-btn-group gh-post-preview-btn-group" style="display:flex;flex-grow:1;justify-content:center">
|
|
<button type="button" class="gh-btn {{if (eq this.tab "browser") "gh-btn-group-selected"}} gh-post-preview-mode" {{on "click" (fn this.changeTab "browser")}}><span>{{svg-jar "desktop"}}</span></button>
|
|
<button type="button" class="gh-btn {{if (eq this.tab "mobile") "gh-btn-group-selected"}} gh-post-preview-mode" {{on "click" (fn this.changeTab "mobile")}}><span>{{svg-jar "mobile-phone"}}</span></button>
|
|
{{#if @model.post.isPost}}
|
|
<button type="button" class="gh-btn {{if (eq this.tab "email") "gh-btn-group-selected"}} gh-post-preview-mode" {{on "click" (fn this.changeTab "email")}}><span>{{svg-jar "email-unread"}}</span></button>
|
|
{{/if}}
|
|
<button type="button" class="gh-btn {{if (eq this.tab "social") "gh-btn-group-selected"}} gh-post-preview-mode" {{on "click" (fn this.changeTab "social")}}><span>{{svg-jar "social-share"}}</span></button>
|
|
</div>
|
|
|
|
<GhPublishmenu
|
|
@post={{@model.post}}
|
|
@postStatus={{@model.post.status}}
|
|
@saveTask={{@model.saveTask}}
|
|
@setSaveType={{@model.setEditorSaveType}}
|
|
@memberCount={{@model.memberCount}} />
|
|
</header>
|
|
|
|
{{#if (eq this.tab "browser")}}
|
|
<ModalPostPreview::Browser @post={{@model.post}} />
|
|
{{/if}}
|
|
|
|
{{#if (and (eq this.tab "mobile") @model.post.isPost)}}
|
|
<ModalPostPreview::Mobile @post={{@model.post}} />
|
|
{{/if}}
|
|
|
|
{{#if (and (eq this.tab "email") @model.post.isPost)}}
|
|
<ModalPostPreview::Email @post={{@model.post}} />
|
|
{{/if}}
|
|
|
|
{{#if (eq this.tab "social")}}
|
|
<ModalPostPreview::Social @post={{@model.post}} />
|
|
{{/if}}
|
|
</div> |