mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-19 16:42:17 +03:00
5e7edb9da5
refs https://github.com/TryGhost/Team/issues/3274 Co-authored-by: Sanne de Vries <sannedv@protonmail.com> Co-authored-by: Ronald Langeveld <hi@ronaldlangeveld.com> Co-authored-by: Jono Mingard <reason.koan@gmail.com> Co-authored-by: Sag <guptazy@gmail.com>
318 lines
16 KiB
Handlebars
318 lines
16 KiB
Handlebars
<section class="gh-canvas">
|
||
<GhCanvasHeader class="gh-canvas-header">
|
||
<div class="flex flex-column">
|
||
<div class="gh-canvas-breadcrumb">
|
||
<LinkTo @route="settings">
|
||
Settings
|
||
</LinkTo>
|
||
{{svg-jar "arrow-right-small"}} Labs
|
||
</div>
|
||
<h2 class="gh-canvas-title" data-test-screen-title>
|
||
Labs
|
||
</h2>
|
||
</div>
|
||
</GhCanvasHeader>
|
||
|
||
<section class="view-container settings-debug">
|
||
<p class="gh-box gh-box-tip">{{svg-jar "idea"}}This is a testing ground for new or experimental features. They may change, break or inexplicably disappear at any time.</p>
|
||
|
||
<div class="gh-main-section">
|
||
<h4 class="gh-main-section-header small bn">Migration options</h4>
|
||
<div class="gh-expandable {{if this.importErrors "overflow-hidden"}}">
|
||
<div class="gh-expandable-block">
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Import content</h4>
|
||
<p class="gh-expandable-description">Import posts from a JSON or zip file</p>
|
||
</div>
|
||
<LinkTo @route="settings.labs.import" class="gh-btn" data-test-link="import-content">
|
||
<span>Open Importer</span>
|
||
</LinkTo>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="gh-expandable-block">
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Export your content</h4>
|
||
<p class="gh-expandable-description">Download all of your posts and settings in a single, glorious JSON file</p>
|
||
</div>
|
||
<button type="button" class="gh-btn" {{action "downloadFile" "db"}}><span>Export</span></button>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="gh-expandable-block">
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Delete all content</h4>
|
||
<p class="gh-expandable-description">Permanently delete all posts and tags from the database, a hard reset</p>
|
||
</div>
|
||
<button type="button" class="gh-btn gh-btn-red" {{on "click" this.confirmDeleteAll}} data-test-button="delete-all"><span>Delete</span></button>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="gh-main-section">
|
||
<h4 class="gh-main-section-header small bn">Beta features</h4>
|
||
<div class="gh-expandable">
|
||
<Labs::Lexical />
|
||
|
||
<div class="gh-expandable-block">
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Substack migrator</h4>
|
||
<p class="gh-expandable-description">A <a href="https://ghost.org/help/importing-from-substack/" target="_blank" rel="noopener noreferrer">step-by-step tool</a> to easily import all your content, members and paid subscriptions</p>
|
||
</div>
|
||
<LinkTo @route="migrate" class="gh-btn" data-test-link="migrate">
|
||
<span>Open</span>
|
||
</LinkTo>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="gh-expandable-block">
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Portal translation</h4>
|
||
<p class="gh-expandable-description">
|
||
Translate your membership flows into your publication language (<a href="https://github.com/TryGhost/Ghost/tree/main/ghost/i18n/locales" target="_blank" rel="noopener noreferrer">supported languages</a>). Don’t see yours? <a href="https://forum.ghost.org/t/help-translate-ghost-beta/37461" target="_blank" rel="noopener noreferrer">Get involved</a>
|
||
</p>
|
||
</div>
|
||
<div class="for-switch">
|
||
<GhFeatureFlag @flag="i18n" />
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="gh-expandable-block">
|
||
<GhUploader
|
||
@extensions={{this.redirectsFileExtensions}}
|
||
@uploadUrl="/redirects/upload/"
|
||
@paramName="redirects"
|
||
@onUploadSuccess={{perform this.redirectUploadResult true}}
|
||
@onUploadFailure={{perform this.redirectUploadResult false}}
|
||
as |uploader|
|
||
>
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Redirects</h4>
|
||
<p class="gh-expandable-description">Configure redirects for old or moved content, more info in <a href="https://ghost.org/tutorials/implementing-redirects/" target="_blank" rel="noopener noreferrer">the docs</a></p>
|
||
</div>
|
||
<div class="gh-setting-action flex flex-column items-end">
|
||
{{#if uploader.isUploading}}
|
||
{{uploader.progressBar}}
|
||
{{else}}
|
||
<button
|
||
type="button"
|
||
class="gh-btn gh-btn-icon {{if this.redirectSuccess "gh-btn-green"}} {{if this.redirectFailure "gh-btn-red"}}"
|
||
onclick={{action "triggerFileDialog"}}
|
||
data-test-button="upload-redirects"
|
||
>
|
||
<span>
|
||
{{#if this.redirectSuccess}}
|
||
{{svg-jar "check-circle"}} Uploaded
|
||
{{else if this.redirectFailure}}
|
||
{{svg-jar "retry"}} Upload Failed
|
||
{{else}}
|
||
Upload redirects YAML/JSON
|
||
{{/if}}
|
||
</span>
|
||
</button>
|
||
<div><a href="#" {{action "downloadFile" "redirects/download"}} data-test-link="download-redirects">Download current redirects</a></div>
|
||
{{/if}}
|
||
|
||
{{#each uploader.errors as |error|}}
|
||
<div class="gh-setting-error" data-test-error="redirects">{{or error.context error.message}}</div>
|
||
{{/each}}
|
||
|
||
<div style="display:none">
|
||
<GhFileInput @multiple={{false}} @action={{uploader.setFiles}} @accept={{this.redirectsFileMimeTypes}} data-test-file-input="redirects" />
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</GhUploader>
|
||
</div>
|
||
|
||
<div class="gh-expandable-block">
|
||
<GhUploader
|
||
@extensions={{this.yamlExtension}}
|
||
@uploadUrl="/settings/routes/yaml/"
|
||
@paramName="routes"
|
||
@onUploadSuccess={{perform this.routesUploadResult true}}
|
||
@onUploadFailure={{perform this.routesUploadResult false}}
|
||
as |uploader|
|
||
>
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Routes</h4>
|
||
<p class="gh-expandable-description">Configure dynamic routing by modifying the routes.yaml file</p>
|
||
</div>
|
||
<div class="gh-setting-action flex flex-column items-end">
|
||
{{#if uploader.isUploading}}
|
||
{{uploader.progressBar}}
|
||
{{else}}
|
||
<button
|
||
type="button"
|
||
class="gh-btn gh-btn-icon {{if this.routesSuccess "gh-btn-green"}} {{if this.routesFailure "gh-btn-red"}}"
|
||
onclick={{action "triggerFileDialog"}}
|
||
data-test-button="upload-routes"
|
||
>
|
||
<span>
|
||
{{#if this.routesSuccess}}
|
||
{{svg-jar "check-circle"}} Uploaded
|
||
{{else if this.routesFailure}}
|
||
{{svg-jar "retry"}} Upload Failed
|
||
{{else}}
|
||
Upload routes YAML
|
||
{{/if}}
|
||
</span>
|
||
</button>
|
||
<div><a href="#" {{action "downloadFile" "settings/routes/yaml"}} data-test-link="download-routes">Download current routes.yaml</a></div>
|
||
{{/if}}
|
||
|
||
{{#each uploader.errors as |error|}}
|
||
<div class="gh-setting-error" data-test-error="routes">{{or error.context error.message}}</div>
|
||
{{/each}}
|
||
|
||
<div style="display:none">
|
||
<GhFileInput @multiple={{false}} @action={{uploader.setFiles}} @accept={{this.yamlAccept}} data-test-file-input="routes" />
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</GhUploader>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
|
||
{{#if (enable-developer-experiments)}}
|
||
<div class="gh-main-section">
|
||
<h4 class="gh-main-section-header small bn">Alpha Features</h4>
|
||
<div class="gh-expandable">
|
||
<div class="gh-expandable-block">
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">URL cache</h4>
|
||
<p class="gh-expandable-description">
|
||
Enable URL Caching
|
||
</p>
|
||
</div>
|
||
<div class="for-switch">
|
||
<GhFeatureFlag @flag="urlCache" />
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="gh-expandable-block">
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Lexical multiplayer</h4>
|
||
<p class="gh-expandable-description">
|
||
Enables multiplayer editing in the lexical editor.
|
||
</p>
|
||
</div>
|
||
<div class="for-switch">
|
||
<GhFeatureFlag @flag="lexicalMultiplayer" />
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="gh-expandable-block">
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Webmentions</h4>
|
||
<p class="gh-expandable-description">
|
||
Allows viewing received mentions on the dashboard.
|
||
</p>
|
||
</div>
|
||
<div class="for-switch">
|
||
<GhFeatureFlag @flag="webmentions" />
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="gh-expandable-block">
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Websockets</h4>
|
||
<p class="gh-expandable-description">
|
||
Test out Websockets functionality at <code>/ghost/#/websockets</code>.
|
||
</p>
|
||
</div>
|
||
<div class="for-switch">
|
||
<GhFeatureFlag @flag="websockets" />
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="gh-expandable-block">
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Stripe Automatic Tax</h4>
|
||
<p class="gh-expandable-description">
|
||
Use Stripe Automatic Tax at Stripe Checkout. Needs to be enabled in Stripe
|
||
</p>
|
||
</div>
|
||
<div class="for-switch">
|
||
<GhFeatureFlag @flag="stripeAutomaticTax" />
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="gh-expandable-block">
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Email customization</h4>
|
||
<p class="gh-expandable-description">
|
||
Adding more control over the newsletter template
|
||
</p>
|
||
</div>
|
||
<div class="for-switch">
|
||
<GhFeatureFlag @flag="emailCustomization" />
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="gh-expandable-block">
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Signup Card</h4>
|
||
<p class="gh-expandable-description">
|
||
Enables the signup card in the Lexical editor
|
||
</p>
|
||
</div>
|
||
<div class="for-switch">
|
||
<GhFeatureFlag @flag="signupCard" />
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="gh-expandable-block">
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Collections</h4>
|
||
<p class="gh-expandable-description">
|
||
Enables Collections 2.0
|
||
</p>
|
||
</div>
|
||
<div class="for-switch">
|
||
<GhFeatureFlag @flag="collections" />
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="gh-expandable-block">
|
||
<div class="gh-expandable-header">
|
||
<div>
|
||
<h4 class="gh-expandable-title">Admin X</h4>
|
||
<p class="gh-expandable-description">
|
||
Enables Admin X, the new admin UI for Ghost
|
||
</p>
|
||
</div>
|
||
<div class="for-switch">
|
||
<GhFeatureFlag @flag="adminXSettings" />
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
{{/if}}
|
||
</section>
|
||
</section>
|