2021-07-02 21:03:52 +03:00
|
|
|
|
<div
|
|
|
|
|
class="settings-menu-container {{if (and this.isViewingSubview (not (eq this.subview "email-settings"))) "settings-menu-container-wide"}}"
|
|
|
|
|
{{did-insert this.setSidebarWidthFromElement}}
|
|
|
|
|
{{did-update this.setSidebarWidthFromElement this.isViewingSubview}}
|
|
|
|
|
>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
<div id="entry-controls">
|
2021-07-02 21:03:52 +03:00
|
|
|
|
<div class="settings-menu settings-menu-pane settings-menu-pane-main">
|
2017-08-02 12:32:51 +03:00
|
|
|
|
<div class="settings-menu-header">
|
2019-12-13 17:20:29 +03:00
|
|
|
|
<h4>{{capitalize this.post.displayName}} settings</h4>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
</div>
|
|
|
|
|
<div class="settings-menu-content">
|
2022-07-13 19:25:46 +03:00
|
|
|
|
<form aria-label="Post settings">
|
2017-08-02 12:32:51 +03:00
|
|
|
|
<div class="form-group">
|
2019-12-13 17:20:29 +03:00
|
|
|
|
<label for="url">{{capitalize this.post.displayName}} URL</label>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
{{!-- new posts don't have a preview link --}}
|
2019-12-13 17:20:29 +03:00
|
|
|
|
{{#unless this.post.isNew}}
|
2021-08-31 18:57:32 +03:00
|
|
|
|
{{#if (or this.post.isPublished this.post.isSent)}}
|
2022-02-02 19:09:43 +03:00
|
|
|
|
<a class="post-view-link" target="_blank" href="{{this.post.url}}" rel="noopener noreferrer">
|
2019-12-13 17:20:29 +03:00
|
|
|
|
View {{this.post.displayName}} {{svg-jar "external"}}
|
2017-08-02 12:32:51 +03:00
|
|
|
|
</a>
|
2021-07-02 21:03:52 +03:00
|
|
|
|
{{else if this.post.isScheduled}}
|
2022-02-02 19:09:43 +03:00
|
|
|
|
<a class="post-view-link" target="_blank" href="{{this.post.previewUrl}}" rel="noopener noreferrer">
|
2018-03-19 12:57:31 +03:00
|
|
|
|
Preview {{svg-jar "external"}}
|
2017-08-02 12:32:51 +03:00
|
|
|
|
</a>
|
|
|
|
|
{{/if}}
|
|
|
|
|
{{/unless}}
|
|
|
|
|
|
|
|
|
|
<div class="gh-input-icon gh-icon-link">
|
2018-03-19 12:57:31 +03:00
|
|
|
|
{{svg-jar "link"}}
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhTextInput
|
|
|
|
|
@class="post-setting-slug"
|
|
|
|
|
@id="url"
|
|
|
|
|
@name="post-setting-slug"
|
|
|
|
|
@value={{readonly this.slugValue}}
|
|
|
|
|
@input={{action (mut this.slugValue) value="target.value"}}
|
|
|
|
|
@focus-out={{action "updateSlug" this.slugValue}}
|
|
|
|
|
@stopEnterKeyDownPropagation={{true}} />
|
2017-08-02 12:32:51 +03:00
|
|
|
|
</div>
|
2021-08-13 16:47:02 +03:00
|
|
|
|
{{#if this.post.isSent}}
|
2021-08-19 11:50:43 +03:00
|
|
|
|
<GhUrlPreview @prefix="email" @slug={{this.uuidValue}} @tagName="p" @classNames="description" />
|
2021-08-13 16:47:02 +03:00
|
|
|
|
{{else}}
|
|
|
|
|
<GhUrlPreview @slug={{this.slugValue}} @tagName="p" @classNames="description" />
|
|
|
|
|
{{/if}}
|
2017-08-02 12:32:51 +03:00
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="form-group">
|
2021-10-07 16:18:51 +03:00
|
|
|
|
{{#if (or this.post.isDraft this.post.isPublished this.post.pastScheduledTime this.post.isSent)}}
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<label>Publish date</label>
|
2017-07-22 02:11:24 +03:00
|
|
|
|
{{else}}
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<label>Scheduled date</label>
|
2017-07-22 02:11:24 +03:00
|
|
|
|
{{/if}}
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhDateTimePicker
|
|
|
|
|
@date={{this.post.publishedAtBlogDate}}
|
|
|
|
|
@time={{this.post.publishedAtBlogTime}}
|
|
|
|
|
@setDate={{action "setPublishedAtBlogDate"}}
|
|
|
|
|
@setTime={{action "setPublishedAtBlogTime"}}
|
|
|
|
|
@errors={{this.post.errors}}
|
|
|
|
|
@dateErrorProperty="publishedAtBlogDate"
|
|
|
|
|
@timeErrorProperty="publishedAtBlogTime"
|
|
|
|
|
@maxDate="now"
|
|
|
|
|
@disabled={{this.post.isScheduled}}
|
2021-07-02 21:57:58 +03:00
|
|
|
|
@isActive={{not this.isViewingSubview}}
|
2020-01-16 18:14:03 +03:00
|
|
|
|
/>
|
2021-10-07 16:18:51 +03:00
|
|
|
|
{{#unless (or this.post.isDraft this.post.isPublished this.post.pastScheduledTime this.post.isSent)}}
|
2019-06-18 13:47:21 +03:00
|
|
|
|
<p>Use the publish menu to re-schedule</p>
|
|
|
|
|
{{/unless}}
|
2017-04-14 19:22:14 +03:00
|
|
|
|
</div>
|
2014-08-16 01:18:36 +04:00
|
|
|
|
|
2019-12-13 17:20:29 +03:00
|
|
|
|
{{#unless this.session.user.isContributor}}
|
2017-08-02 12:32:51 +03:00
|
|
|
|
<div class="form-group">
|
|
|
|
|
<label for="tag-input">Tags</label>
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhPsmTagsInput @post={{this.post}} @triggerId="tag-input" />
|
2017-08-02 12:32:51 +03:00
|
|
|
|
</div>
|
2018-02-07 12:42:46 +03:00
|
|
|
|
{{/unless}}
|
2014-09-04 17:56:07 +04:00
|
|
|
|
|
2021-01-28 18:25:21 +03:00
|
|
|
|
{{#if this.showVisibilityInput}}
|
2022-05-16 18:25:03 +03:00
|
|
|
|
<GhFormGroup @errors={{this.post.errors}} @hasValidated={{this.post.hasValidated}} @property="visibility">
|
|
|
|
|
<label for="visibility-input">{{capitalize @post.displayName}} access</label>
|
|
|
|
|
<GhPsmVisibilityInput @post={{this.post}} @triggerId="visibility-input" />
|
|
|
|
|
</GhFormGroup>
|
2021-07-02 19:35:10 +03:00
|
|
|
|
|
2022-05-16 18:25:03 +03:00
|
|
|
|
{{#if (eq this.post.visibility "tiers")}}
|
|
|
|
|
<GhFormGroup @errors={{this.post.errors}} @hasValidated={{this.post.hasValidated}} @property="tiers" @class="nt3">
|
|
|
|
|
<GhPostSettingsMenu::VisibilitySegmentSelect
|
|
|
|
|
@tiers={{this.post.tiers}}
|
|
|
|
|
@onChange={{action "setVisibility"}}
|
|
|
|
|
@renderInPlace={{true}}
|
|
|
|
|
@hideOptionsWhenAllSelected={{true}}
|
|
|
|
|
/>
|
|
|
|
|
<GhErrorMessage @errors={{this.post.errors}} @property="tiers" data-test-error="tiers" />
|
|
|
|
|
</GhFormGroup>
|
2021-06-23 21:45:17 +03:00
|
|
|
|
{{/if}}
|
2019-10-01 16:00:53 +03:00
|
|
|
|
{{/if}}
|
|
|
|
|
|
|
|
|
|
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhFormGroup @errors={{this.post.errors}} @hasValidated={{this.post.hasValidated}} @property="customExcerpt">
|
2017-08-02 12:32:51 +03:00
|
|
|
|
<label for="custom-excerpt">Excerpt</label>
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhTextarea
|
|
|
|
|
@class="post-setting-custom-excerpt"
|
|
|
|
|
@id="custom-excerpt"
|
|
|
|
|
@name="post-setting-custom-excerpt"
|
|
|
|
|
@value={{readonly this.customExcerptScratch}}
|
|
|
|
|
@input={{action (mut this.customExcerptScratch) value="target.value"}}
|
|
|
|
|
@focus-out={{action "setCustomExcerpt" this.customExcerptScratch}}
|
|
|
|
|
@stopEnterKeyDownPropagation="true"
|
|
|
|
|
data-test-field="custom-excerpt"
|
|
|
|
|
/>
|
2019-12-13 19:11:49 +03:00
|
|
|
|
<GhErrorMessage @errors={{this.post.errors}} @property="customExcerpt" data-test-error="custom-excerpt" />
|
2020-01-16 18:14:03 +03:00
|
|
|
|
</GhFormGroup>
|
2015-08-10 16:22:37 +03:00
|
|
|
|
|
2019-12-13 17:20:29 +03:00
|
|
|
|
{{#unless this.session.user.isAuthorOrContributor}}
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhFormGroup @class="for-select" @errors={{this.post.errors}} @hasValidated={{this.post.hasValidated}} @property="authors" data-test-input="authors">
|
2018-03-13 14:17:29 +03:00
|
|
|
|
<label for="author-list">Authors</label>
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhPsmAuthorsInput @selectedAuthors={{this.post.authors}} @updateAuthors={{action "changeAuthors"}} @triggerId="author-list" />
|
2019-12-13 19:11:49 +03:00
|
|
|
|
<GhErrorMessage @errors={{this.post.errors}} @property="authors" data-test-error="authors" />
|
2020-01-16 18:14:03 +03:00
|
|
|
|
</GhFormGroup>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
{{/unless}}
|
2014-10-13 19:23:06 +04:00
|
|
|
|
|
2017-08-02 12:32:51 +03:00
|
|
|
|
<ul class="nav-list nav-list-block">
|
2022-02-11 12:10:18 +03:00
|
|
|
|
<li class="nav-list-item">
|
|
|
|
|
<button type="button" {{action "showSubview" "meta-data"}} data-test-button="meta-data">
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<b>Meta data</b>
|
2017-08-03 14:45:14 +03:00
|
|
|
|
<span>Extra content for search engines</span>
|
|
|
|
|
</button>
|
2018-03-19 12:57:31 +03:00
|
|
|
|
{{svg-jar "arrow-right"}}
|
2017-08-03 14:45:14 +03:00
|
|
|
|
</li>
|
2022-02-11 12:10:18 +03:00
|
|
|
|
<li class="nav-list-item">
|
|
|
|
|
<button type="button" {{action "showSubview" "twitter-data"}} data-test-button="twitter-data">
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<b>Twitter card</b>
|
2021-06-09 18:28:19 +03:00
|
|
|
|
<span>Customize structured data for Twitter</span>
|
2017-08-03 14:45:14 +03:00
|
|
|
|
</button>
|
2018-03-19 12:57:31 +03:00
|
|
|
|
{{svg-jar "arrow-right"}}
|
2017-08-03 14:45:14 +03:00
|
|
|
|
</li>
|
2022-02-11 12:10:18 +03:00
|
|
|
|
<li class="nav-list-item">
|
|
|
|
|
<button type="button" {{action "showSubview" "facebook-data"}} data-test-button="facebook-data">
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<b>Facebook card</b>
|
2021-06-09 18:28:19 +03:00
|
|
|
|
<span>Customize Open Graph data</span>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
</button>
|
2018-03-19 12:57:31 +03:00
|
|
|
|
{{svg-jar "arrow-right"}}
|
2017-08-02 12:32:51 +03:00
|
|
|
|
</li>
|
2022-02-11 11:29:11 +03:00
|
|
|
|
{{#if (and this.post.isPost this.showEmailNewsletter (not-eq this.settings.membersSignupAccess "none") (not-eq this.settings.editorDefaultEmailRecipients "disabled"))}}
|
2022-02-11 12:10:18 +03:00
|
|
|
|
<li class="nav-list-item">
|
|
|
|
|
<button type="button" {{action "showSubview" "email-settings"}} data-test-button="email-settings">
|
2022-02-11 11:29:11 +03:00
|
|
|
|
<b>Email newsletter</b>
|
|
|
|
|
<span>Customize email settings</span>
|
|
|
|
|
</button>
|
|
|
|
|
{{svg-jar "arrow-right"}}
|
|
|
|
|
</li>
|
2019-11-04 09:15:13 +03:00
|
|
|
|
{{/if}}
|
2022-02-11 12:10:18 +03:00
|
|
|
|
<li class="nav-list-item">
|
|
|
|
|
<button type="button" {{action "showSubview" "codeinjection"}} data-test-button="codeinjection">
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<b>Code injection</b>
|
2017-08-03 14:45:14 +03:00
|
|
|
|
<span>Add styles/scripts to the header & footer</span>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
</button>
|
2018-03-19 12:57:31 +03:00
|
|
|
|
{{svg-jar "arrow-right"}}
|
2017-08-02 12:32:51 +03:00
|
|
|
|
</li>
|
|
|
|
|
</ul>
|
2014-09-04 17:56:07 +04:00
|
|
|
|
|
2019-05-28 11:38:43 +03:00
|
|
|
|
{{#unless this.session.user.isAuthorOrContributor}}
|
2017-08-02 12:32:51 +03:00
|
|
|
|
<div class="form-group for-checkbox">
|
|
|
|
|
<label class="checkbox" for="featured" {{action "toggleFeatured" bubbles="false"}}>
|
2018-02-28 14:44:03 +03:00
|
|
|
|
<input
|
|
|
|
|
type="checkbox"
|
2019-12-13 17:20:29 +03:00
|
|
|
|
checked={{this.post.featured}}
|
2018-02-28 14:44:03 +03:00
|
|
|
|
class="gh-input post-settings-featured"
|
2019-12-13 17:20:29 +03:00
|
|
|
|
onclick={{action (mut this.post.featured) value="target.checked"}}
|
2017-11-02 12:47:52 +03:00
|
|
|
|
data-test-checkbox="featured"
|
2018-02-28 14:44:03 +03:00
|
|
|
|
>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
<span class="input-toggle-component"></span>
|
2019-12-13 17:20:29 +03:00
|
|
|
|
<p>Feature this {{this.post.displayName}}</p>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
</label>
|
2014-09-04 17:56:07 +04:00
|
|
|
|
</div>
|
2019-05-28 11:38:43 +03:00
|
|
|
|
{{/unless}}
|
2017-08-02 12:32:51 +03:00
|
|
|
|
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhPsmTemplateSelect
|
|
|
|
|
@post={{this.post}}
|
|
|
|
|
@onTemplateSelect={{action (mut this.post.customTemplate)}} />
|
2017-10-10 15:26:19 +03:00
|
|
|
|
|
2019-12-13 17:20:29 +03:00
|
|
|
|
{{#unless this.post.isNew}}
|
2022-02-01 12:34:03 +03:00
|
|
|
|
<button type="button" class="gh-btn gh-btn-hover-red gh-btn-icon settings-menu-delete-button" {{action "deletePostInternal"}}><span>{{svg-jar "trash"}} Delete {{this.post.displayName}}</span></button>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
{{/unless}}
|
|
|
|
|
|
|
|
|
|
</form>
|
|
|
|
|
</div>{{! .settings-menu-content }}
|
|
|
|
|
</div>{{! .post-settings-menu }}
|
|
|
|
|
|
2021-07-02 21:03:52 +03:00
|
|
|
|
{{#if this.isViewingSubview}}
|
|
|
|
|
<div class="settings-menu settings-menu-pane {{unless (eq this.subview "email-settings") "settings-menu-pane-wide"}}">
|
2017-08-02 12:32:51 +03:00
|
|
|
|
<div class="active">
|
2019-12-13 17:20:29 +03:00
|
|
|
|
{{#if (eq this.subview "meta-data")}}
|
2017-08-02 12:32:51 +03:00
|
|
|
|
<div class="settings-menu-header subview">
|
2022-07-13 18:27:24 +03:00
|
|
|
|
<button aria-label="Close meta data panel" class="back settings-menu-header-action" data-test-button="close-psm-subview" type="button" {{action "closeSubview"}}>{{svg-jar "arrow-left"}}<span class="hidden">Back</span></button>
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<h4>Meta data</h4>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
<div style="width:23px;"></div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="settings-menu-content">
|
2022-07-13 19:25:46 +03:00
|
|
|
|
<form {{action "discardEnter" on="submit"}} aria-label="Meta data settings">
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhFormGroup @errors={{this.post.errors}} @hasValidated={{this.post.hasValidated}} @property="metaTitle">
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<label for="meta-title">Meta title</label>
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhTextInput
|
|
|
|
|
@class="post-setting-meta-title"
|
|
|
|
|
@id="meta-title"
|
|
|
|
|
@name="post-setting-meta-title"
|
2021-03-03 15:30:41 +03:00
|
|
|
|
@placeholder={{this.seoTitle}}
|
2020-01-16 18:14:03 +03:00
|
|
|
|
@value={{readonly this.metaTitleScratch}}
|
|
|
|
|
@input={{action (mut this.metaTitleScratch) value="target.value"}}
|
|
|
|
|
@focus-out={{action "setMetaTitle" this.metaTitleScratch}}
|
|
|
|
|
@stopEnterKeyDownPropagation={{true}}
|
|
|
|
|
data-test-field="meta-title" />
|
2021-03-30 11:41:36 +03:00
|
|
|
|
<p>Recommended: <b>60</b> characters. You’ve used {{gh-count-down-characters this.metaTitleScratch 60}}</p>
|
2019-12-13 19:11:49 +03:00
|
|
|
|
<GhErrorMessage @errors={{this.post.errors}} @property="meta-title" />
|
2020-01-16 18:14:03 +03:00
|
|
|
|
</GhFormGroup>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhFormGroup @errors={{this.post.errors}} @hasValidated={{this.post.hasValidated}} @property="metaDescription">
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<label for="meta-description">Meta description</label>
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhTextarea
|
|
|
|
|
@class="post-setting-meta-description"
|
|
|
|
|
@id="meta-description"
|
|
|
|
|
@name="post-setting-meta-description"
|
2021-03-03 15:30:41 +03:00
|
|
|
|
@placeholder={{truncate this.seoDescription 150}}
|
2020-01-16 18:14:03 +03:00
|
|
|
|
@value={{readonly this.metaDescriptionScratch}}
|
|
|
|
|
@input={{action (mut this.metaDescriptionScratch) value="target.value"}}
|
|
|
|
|
@focus-out={{action "setMetaDescription" this.metaDescriptionScratch}}
|
|
|
|
|
@stopEnterKeyDownPropagation="true"
|
|
|
|
|
data-test-field="meta-description" />
|
2021-05-05 18:33:59 +03:00
|
|
|
|
<p>Recommended: <b>145</b> characters. You’ve used {{gh-count-down-characters this.metaDescriptionScratch 145}}</p>
|
2019-12-13 19:11:49 +03:00
|
|
|
|
<GhErrorMessage @errors={{this.post.errors}} @property="meta-description" />
|
2020-01-16 18:14:03 +03:00
|
|
|
|
</GhFormGroup>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhFormGroup @errors={{this.post.errors}} @hasValidated={{this.post.hasValidated}} @property="canonicalUrl">
|
2019-03-12 13:40:07 +03:00
|
|
|
|
<label for="canonicalUrl">Canonical URL</label>
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhTextInput
|
|
|
|
|
@class="post-setting-canonicalUrl"
|
|
|
|
|
@name="post-setting-canonicalUrl"
|
2022-07-13 17:59:28 +03:00
|
|
|
|
@placeholder={{this.post.url}}
|
2020-01-16 18:14:03 +03:00
|
|
|
|
@value={{readonly this.canonicalUrlScratch}}
|
|
|
|
|
@input={{action (mut this.canonicalUrlScratch) value="target.value"}}
|
|
|
|
|
@focus-out={{action "setCanonicalUrl" this.canonicalUrlScratch}}
|
|
|
|
|
@stopEnterKeyDownPropagation="true"
|
|
|
|
|
data-test-field="canonicalUrl" />
|
2019-12-13 19:11:49 +03:00
|
|
|
|
<GhErrorMessage @errors={{this.post.errors}} @property="canonicalUrl" />
|
2020-01-16 18:14:03 +03:00
|
|
|
|
</GhFormGroup>
|
2019-03-12 13:40:07 +03:00
|
|
|
|
|
2017-08-02 12:32:51 +03:00
|
|
|
|
<div class="form-group">
|
|
|
|
|
<label>Search Engine Result Preview</label>
|
2021-02-24 15:04:56 +03:00
|
|
|
|
<div class="gh-seo-container">
|
|
|
|
|
<div class="gh-seo-preview">
|
|
|
|
|
<div class="flex mb7">
|
|
|
|
|
{{svg-jar "google"}}
|
|
|
|
|
<div class="gh-seo-search-bar">{{svg-jar "google-search"}}</div>
|
|
|
|
|
</div>
|
2021-03-30 12:10:34 +03:00
|
|
|
|
<div class="gh-seo-preview-link">{{this.seoURL}}</div>
|
2021-03-30 11:41:36 +03:00
|
|
|
|
<div class="gh-seo-preview-title">{{truncate this.seoTitle 60}}</div>
|
2021-05-05 18:33:59 +03:00
|
|
|
|
<div class="gh-seo-preview-desc">{{moment-format (now) "DD MMM YYYY"}} — {{truncate this.seoDescription 149}}</div>
|
2021-02-24 15:04:56 +03:00
|
|
|
|
</div>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</form>
|
|
|
|
|
</div>
|
|
|
|
|
{{/if}}
|
|
|
|
|
|
2019-12-13 17:20:29 +03:00
|
|
|
|
{{#if (eq this.subview "twitter-data")}}
|
2017-08-03 14:45:14 +03:00
|
|
|
|
<div class="settings-menu-header subview">
|
2022-07-13 18:27:24 +03:00
|
|
|
|
<button aria-label="Close Twitter card panel" class="back settings-menu-header-action" data-test-button="close-psm-subview" type="button" {{action "closeSubview"}}>{{svg-jar "arrow-left"}}<span class="hidden">Back</span></button>
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<h4>Twitter card</h4>
|
2017-08-03 14:45:14 +03:00
|
|
|
|
<div style="width:23px;"></div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="settings-menu-content">
|
|
|
|
|
|
2022-07-13 19:25:46 +03:00
|
|
|
|
<form {{action "discardEnter" on="submit"}} aria-label="Twitter card settings">
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhImageUploaderWithPreview
|
|
|
|
|
@image={{this.post.twitterImage}}
|
|
|
|
|
@text="Add Twitter image"
|
|
|
|
|
@allowUnsplash={{true}}
|
|
|
|
|
@update={{action "setTwitterImage"}}
|
|
|
|
|
@remove={{action "clearTwitterImage"}}
|
|
|
|
|
/>
|
|
|
|
|
<GhFormGroup @errors={{this.post.errors}} @hasValidated={{this.post.hasValidated}} @property="twitterTitle">
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<label for="twitter-title">Twitter title</label>
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhTextInput
|
|
|
|
|
@class="post-setting-twitter-title"
|
|
|
|
|
@id="twitter-title"
|
|
|
|
|
@name="post-setting-twitter-title"
|
|
|
|
|
@placeholder={{truncate this.twitterTitle 40}}
|
|
|
|
|
@value={{readonly this.twitterTitleScratch}}
|
|
|
|
|
@input={{action (mut this.twitterTitleScratch) value="target.value"}}
|
|
|
|
|
@focus-out={{action "setTwitterTitle" this.twitterTitleScratch}}
|
|
|
|
|
@stopEnterKeyDownPropagation={{true}}
|
|
|
|
|
data-test-field="twitter-title" />
|
2019-12-13 19:11:49 +03:00
|
|
|
|
<GhErrorMessage @errors={{this.post.errors}} @property="twitterTitle" data-test-error="twitter-title" />
|
2020-01-16 18:14:03 +03:00
|
|
|
|
</GhFormGroup>
|
2017-08-03 14:45:14 +03:00
|
|
|
|
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhFormGroup @errors={{this.post.errors}} @hasValidated={{this.post.hasValidated}} @property="twitterDescription">
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<label for="twitter-description">Twitter description</label>
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhTextarea
|
|
|
|
|
@class="post-setting-twitter-description"
|
|
|
|
|
@id="twitter-description"
|
|
|
|
|
@name="post-setting-twitter-description"
|
2021-03-03 15:30:41 +03:00
|
|
|
|
@placeholder={{truncate this.twitterDescription 150}}
|
2020-01-16 18:14:03 +03:00
|
|
|
|
@stopEnterKeyDownPropagation="true"
|
|
|
|
|
@value={{readonly this.twitterDescriptionScratch}}
|
|
|
|
|
@input={{action (mut this.twitterDescriptionScratch) value="target.value"}}
|
|
|
|
|
@focus-out={{action "setTwitterDescription" this.twitterDescriptionScratch}}
|
|
|
|
|
data-test-field="twitter-description" />
|
2019-12-13 19:11:49 +03:00
|
|
|
|
<GhErrorMessage @errors={{this.post.errors}} @property="twitterDescription" data-test-error="twitter-description" />
|
2020-01-16 18:14:03 +03:00
|
|
|
|
</GhFormGroup>
|
2017-08-03 14:45:14 +03:00
|
|
|
|
|
|
|
|
|
<div class="form-group">
|
2021-02-24 15:04:56 +03:00
|
|
|
|
<label>Twitter preview</label>
|
|
|
|
|
<div class="gh-social-twitter-post-preview">
|
2019-12-13 17:20:29 +03:00
|
|
|
|
{{#if this.twitterImage}}
|
2021-02-24 15:04:56 +03:00
|
|
|
|
<div class="gh-social-twitter-preview-image" style={{background-image-style this.twitterImage}}></div>
|
2017-08-03 14:45:14 +03:00
|
|
|
|
{{/if}}
|
2021-02-24 15:04:56 +03:00
|
|
|
|
<div class="gh-social-twitter-preview-content">
|
|
|
|
|
<div class="gh-social-twitter-preview-title">{{this.twitterTitle}}</div>
|
|
|
|
|
<div class="gh-social-twitter-preview-desc">{{truncate this.twitterDescription}}</div>
|
|
|
|
|
<div class="gh-social-twitter-preview-meta">
|
|
|
|
|
{{svg-jar "twitter-link"}}
|
|
|
|
|
{{this.config.blogDomain}}
|
2017-08-03 14:45:14 +03:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</form>
|
|
|
|
|
</div>
|
|
|
|
|
{{/if}}
|
|
|
|
|
|
2019-12-13 17:20:29 +03:00
|
|
|
|
{{#if (eq this.subview "email-settings")}}
|
2019-11-08 11:56:56 +03:00
|
|
|
|
<GhPostSettingsMenu::Email
|
|
|
|
|
@post={{this.post}}
|
2021-06-21 17:05:29 +03:00
|
|
|
|
@savePostTask={{this.savePostTask}}
|
2019-11-08 11:56:56 +03:00
|
|
|
|
@close={{action "closeSubview"}}
|
|
|
|
|
/>
|
2019-11-04 09:15:13 +03:00
|
|
|
|
{{/if}}
|
|
|
|
|
|
2019-12-13 17:20:29 +03:00
|
|
|
|
{{#if (eq this.subview "facebook-data")}}
|
2017-08-03 14:45:14 +03:00
|
|
|
|
<div class="settings-menu-header subview">
|
2022-07-13 18:27:24 +03:00
|
|
|
|
<button aria-label="Close Facebook card panel" class="back settings-menu-header-action" data-test-button="close-psm-subview" type="button" {{action "closeSubview"}}>{{svg-jar "arrow-left"}}<span class="hidden">Back</span></button>
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<h4>Facebook card</h4>
|
2017-08-03 14:45:14 +03:00
|
|
|
|
<div style="width:23px;"></div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="settings-menu-content">
|
2022-07-13 19:25:46 +03:00
|
|
|
|
<form {{action "discardEnter" on="submit"}} aria-label="Facebook card settings">
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhImageUploaderWithPreview
|
|
|
|
|
@image={{this.post.ogImage}}
|
|
|
|
|
@text="Add Facebook image"
|
|
|
|
|
@allowUnsplash={{true}}
|
|
|
|
|
@update={{action "setOgImage"}}
|
|
|
|
|
@remove={{action "clearOgImage"}}
|
|
|
|
|
/>
|
|
|
|
|
<GhFormGroup @errors={{this.post.errors}} @hasValidated={{this.post.hasValidated}} @property="ogTitle">
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<label for="og-title">Facebook title</label>
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhTextInput
|
|
|
|
|
@class="post-setting-og-title"
|
|
|
|
|
@id="og-title"
|
|
|
|
|
@name="post-setting-og-title"
|
|
|
|
|
@placeholder={{truncate this.facebookTitle 40}}
|
|
|
|
|
@value={{readonly this.ogTitleScratch}}
|
|
|
|
|
@input={{action (mut this.ogTitleScratch) value="target.value"}}
|
|
|
|
|
@focus-out={{action "setOgTitle" this.ogTitleScratch}}
|
|
|
|
|
@stopEnterKeyDownPropagation={{true}}
|
|
|
|
|
data-test-field="og-title" />
|
2019-12-13 19:11:49 +03:00
|
|
|
|
<GhErrorMessage @errors={{this.post.errors}} @property="ogTitle" data-test-error="og-title" />
|
2020-01-16 18:14:03 +03:00
|
|
|
|
</GhFormGroup>
|
2017-08-03 14:45:14 +03:00
|
|
|
|
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhFormGroup @errors={{this.post.errors}} @hasValidated={{this.post.hasValidated}} @property="ogDescription">
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<label for="og-description">Facebook description</label>
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhTextarea
|
|
|
|
|
@class="post-setting-og-description"
|
|
|
|
|
@id="og-description" @name="post-setting-og-description"
|
2021-03-03 15:30:41 +03:00
|
|
|
|
@placeholder={{truncate this.facebookDescription 150}}
|
2020-01-16 18:14:03 +03:00
|
|
|
|
@value={{readonly this.ogDescriptionScratch}}
|
|
|
|
|
@input={{action (mut this.ogDescriptionScratch) value="target.value"}}
|
|
|
|
|
@focus-out={{action "setOgDescription" this.ogDescriptionScratch}}
|
|
|
|
|
@stopEnterKeyDownPropagation="true"
|
|
|
|
|
data-test-field="og-description" />
|
2019-12-13 19:11:49 +03:00
|
|
|
|
<GhErrorMessage @errors={{this.post.errors}} @property="ogDescription" data-test-error="og-description" />
|
2020-01-16 18:14:03 +03:00
|
|
|
|
</GhFormGroup>
|
2017-08-03 14:45:14 +03:00
|
|
|
|
|
|
|
|
|
<div class="form-group">
|
2021-02-24 15:04:56 +03:00
|
|
|
|
<label>Facebook preview</label>
|
|
|
|
|
<div class="gh-social-og-preview no-container">
|
2019-12-13 17:20:29 +03:00
|
|
|
|
{{#if this.facebookImage}}
|
2021-02-24 15:04:56 +03:00
|
|
|
|
<div class="gh-social-og-preview-image" style={{background-image-style this.facebookImage}}></div>
|
2017-08-03 14:45:14 +03:00
|
|
|
|
{{/if}}
|
2021-03-02 15:24:54 +03:00
|
|
|
|
<div class="gh-social-og-preview-bookmark">
|
|
|
|
|
{{!-- Ensures description is hidden if title exceeds one line --}}
|
|
|
|
|
<div class="gh-social-og-preview-content">
|
|
|
|
|
<div class="gh-social-og-preview-meta">
|
|
|
|
|
{{this.config.blogDomain}}
|
|
|
|
|
</div>
|
|
|
|
|
<div class="gh-social-og-preview-title">{{truncate this.facebookTitle}}</div>
|
|
|
|
|
<div class="gh-social-og-preview-desc">{{truncate this.facebookDescription}}</div>
|
2017-08-03 14:45:14 +03:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</form>
|
|
|
|
|
</div>
|
|
|
|
|
{{/if}}
|
|
|
|
|
|
2019-12-13 17:20:29 +03:00
|
|
|
|
{{#if (eq this.subview "codeinjection")}}
|
2017-08-02 12:32:51 +03:00
|
|
|
|
<div class="settings-menu-header subview">
|
2022-07-13 18:27:24 +03:00
|
|
|
|
<button aria-label="Close code injection panel" class="back settings-menu-header-action" data-test-button="close-psm-subview" type="button" {{action "closeSubview"}}>{{svg-jar "arrow-left"}}<span class="hidden">Back</span></button>
|
2019-11-08 09:19:19 +03:00
|
|
|
|
<h4>Code injection</h4>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
<div style="width:23px;"></div>
|
|
|
|
|
</div>
|
|
|
|
|
|
2018-01-02 21:29:03 +03:00
|
|
|
|
<div class="settings-menu-content settings-menu-content-codeinjection">
|
2022-07-13 19:25:46 +03:00
|
|
|
|
<form {{action "discardEnter" on="submit"}} aria-label="Code injection settings">
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhFormGroup @errors={{this.post.errors}} @hasValidated={{this.post.hasValidated}} @property="codeinjectionHead">
|
2019-12-13 17:20:29 +03:00
|
|
|
|
<label for="codeinjection-head">{{capitalize this.post.displayName}} header <code>\{{ghost_head}}</code></label>
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhCmEditor @value={{this.codeinjectionHeadScratch}}
|
|
|
|
|
@id="post-setting-codeinjection-head"
|
|
|
|
|
@class="post-setting-codeinjection"
|
|
|
|
|
@name="post-setting-codeinjection-head"
|
|
|
|
|
@focusOut={{action "setHeaderInjection" this.codeinjectionHeadScratch}}
|
|
|
|
|
@stopEnterKeyDownPropagation="true"
|
|
|
|
|
@update={{action (mut this.codeinjectionHeadScratch)}}
|
|
|
|
|
data-test-field="codeinjection-head" />
|
2019-12-13 19:11:49 +03:00
|
|
|
|
<GhErrorMessage @errors={{this.post.errors}} @property="codeinjectionHead" data-test-error="codeinjection-head" />
|
2020-01-16 18:14:03 +03:00
|
|
|
|
</GhFormGroup>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhFormGroup @errors={{this.post.errors}} @hasValidated={{this.post.hasValidated}} @property="codeinjectionFoot">
|
2019-12-13 17:20:29 +03:00
|
|
|
|
<label for="codeinjection-foot">{{capitalize this.post.displayName}} footer <code>\{{ghost_foot}}</code></label>
|
2020-01-16 18:14:03 +03:00
|
|
|
|
<GhCmEditor @value={{this.codeinjectionFootScratch}}
|
|
|
|
|
@id="post-setting-codeinjection-foot"
|
|
|
|
|
@class="post-setting-codeinjection"
|
|
|
|
|
@name="post-setting-codeinjection-foot"
|
|
|
|
|
@focusOut={{action "setFooterInjection" this.codeinjectionFootScratch}}
|
|
|
|
|
@stopEnterKeyDownPropagation="true"
|
|
|
|
|
@update={{action (mut this.codeinjectionFootScratch)}}
|
|
|
|
|
data-test-field="codeinjection-foot" />
|
2019-12-13 19:11:49 +03:00
|
|
|
|
<GhErrorMessage @errors={{this.post.errors}} @property="codeinjectionFoot" data-test-error="codeinjection-foot" />
|
2020-01-16 18:14:03 +03:00
|
|
|
|
</GhFormGroup>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
</form>
|
|
|
|
|
</div>
|
|
|
|
|
{{/if}}
|
2014-12-02 01:45:45 +03:00
|
|
|
|
</div>
|
2017-08-02 12:32:51 +03:00
|
|
|
|
</div>
|
2021-07-02 21:03:52 +03:00
|
|
|
|
{{/if}}
|
2014-09-19 03:42:07 +04:00
|
|
|
|
</div>
|
2021-06-23 21:45:17 +03:00
|
|
|
|
</div>
|