mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-21 09:52:06 +03:00
beb5ae1737
no issue
- This will help with the octane migration and you can still run the lint rules even when they are todos. (Checkout the docs at 158b119667/docs/todos.md
) The good news is any new code will be checked against the recommended config.
- I fixed all the auto fixable things we could get in this PR as well
35 lines
1.2 KiB
Handlebars
35 lines
1.2 KiB
Handlebars
{{#if this.file}}
|
|
{{!-- Upload in progress! --}}
|
|
{{#if this.failureMessage}}
|
|
<div class="failed">{{this.failureMessage}}</div>
|
|
{{/if}}
|
|
<div class="progress-container">
|
|
<div class="progress">
|
|
<div class="bar {{if this.failureMessage "fail"}}" style={{this.progressStyle}}></div>
|
|
</div>
|
|
</div>
|
|
{{#if this.failureMessage}}
|
|
<button class="gh-btn gh-btn-green" type="button" {{action "reset"}}><span>Try Again</span></button>
|
|
{{/if}}
|
|
{{else}}
|
|
{{!-- file selection/drag-n-drop --}}
|
|
<div class="upload-form">
|
|
<GhFileInput @multiple={{false}} @alt={{this.description}} @action={{action "fileSelected"}} @accept={{this.accept}}>
|
|
<div class="gh-btn gh-btn-white" data-test-file-input-description><span>{{this.description}}</span></div>
|
|
</GhFileInput>
|
|
|
|
{{#if (and this.allowUnsplash this.settings.unsplash)}}
|
|
<div class="gh-image-uploader-unsplash" {{action (toggle "_showUnsplash" this)}}>
|
|
{{svg-jar "unsplash"}}
|
|
</div>
|
|
{{/if}}
|
|
</div>
|
|
{{/if}}
|
|
|
|
{{#if this._showUnsplash}}
|
|
<GhUnsplash
|
|
@select={{action "addUnsplashPhoto"}}
|
|
@close={{action (toggle "_showUnsplash" this)}}
|
|
/>
|
|
{{/if}}
|