2022-05-12 01:46:01 +03:00
|
|
|
<div class="flex flex-column h-100">
|
2022-05-12 16:27:01 +03:00
|
|
|
<header class="modal-header gh-post-preview-header" data-test-modal="preview-email">
|
2022-05-12 16:43:16 +03:00
|
|
|
<div class="left">
|
2022-05-16 14:50:54 +03:00
|
|
|
<button class="gh-btn-editor gh-editor-back-button" title="Close" type="button" {{on "click" @close}}>
|
2022-05-12 01:46:01 +03:00
|
|
|
<span>{{svg-jar "arrow-left"}} Editor</span>
|
|
|
|
</button>
|
|
|
|
</div>
|
|
|
|
<div class="gh-post-preview-btn-group">
|
|
|
|
<div class="gh-contentfilter gh-btn-group">
|
|
|
|
<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 (and (not-eq this.settings.membersSignupAccess "none") (not-eq this.settings.editorDefaultEmailRecipients "disabled"))}}
|
|
|
|
{{#if @data.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}}
|
|
|
|
{{/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 "twitter"}}</span></button>
|
|
|
|
</div>
|
|
|
|
</div>
|
2022-05-12 16:43:16 +03:00
|
|
|
<div class="right">
|
2022-05-12 16:03:16 +03:00
|
|
|
<button
|
|
|
|
type="button"
|
2022-05-16 14:50:54 +03:00
|
|
|
class="gh-btn gh-btn-editor gh-editor-preview-trigger active"
|
2022-05-12 16:03:16 +03:00
|
|
|
{{on "click" @close}}
|
|
|
|
>
|
|
|
|
<span>Preview</span>
|
|
|
|
</button>
|
2022-05-12 01:46:01 +03:00
|
|
|
<button
|
|
|
|
type="button"
|
2022-05-12 16:03:16 +03:00
|
|
|
class="gh-btn gh-btn-editor darkgrey gh-publish-trigger"
|
2022-05-12 01:46:01 +03:00
|
|
|
{{on "click" @data.togglePreviewPublish}}
|
|
|
|
>
|
|
|
|
<span>Publish</span>
|
|
|
|
</button>
|
2022-05-12 16:03:16 +03:00
|
|
|
<div class="settings-menu-toggle-spacer"></div>
|
2022-05-12 01:46:01 +03:00
|
|
|
</div>
|
|
|
|
</header>
|
|
|
|
|
|
|
|
{{#if this.saveFirstTask.isRunning}}
|
|
|
|
<GhLoadingSpinner />
|
|
|
|
{{else}}
|
|
|
|
{{#if (eq this.tab "browser")}}
|
2022-05-13 16:19:22 +03:00
|
|
|
<EditorLabs::Modals::Preview::Browser @post={{@data.post}} />
|
2022-05-12 01:46:01 +03:00
|
|
|
{{/if}}
|
|
|
|
|
|
|
|
{{#if (and (eq this.tab "mobile"))}}
|
2022-05-13 16:19:22 +03:00
|
|
|
<EditorLabs::Modals::Preview::Mobile @post={{@data.post}} />
|
2022-05-12 01:46:01 +03:00
|
|
|
{{/if}}
|
|
|
|
|
|
|
|
{{#if (and (eq this.tab "email") @data.post.isPost)}}
|
2022-05-16 14:16:12 +03:00
|
|
|
<EditorLabs::Modals::Preview::Email @post={{@data.post}} @newsletter={{@data.newsletter}} />
|
2022-05-12 01:46:01 +03:00
|
|
|
{{/if}}
|
|
|
|
|
|
|
|
{{#if (eq this.tab "social")}}
|
2022-05-13 16:19:22 +03:00
|
|
|
<EditorLabs::Modals::Preview::Social @post={{@data.post}} />
|
2022-05-12 01:46:01 +03:00
|
|
|
{{/if}}
|
|
|
|
{{/if}}
|
|
|
|
</div>
|