mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-02 08:13:34 +03:00
1cade0bc08
no issue - Unsplash integration is enabled by default for all users - it's no longer necessary to create your own Unsplash application and configure your application ID
35 lines
1.2 KiB
Handlebars
35 lines
1.2 KiB
Handlebars
{{#if file}}
|
|
{{!-- Upload in progress! --}}
|
|
{{#if failureMessage}}
|
|
<div class="failed">{{failureMessage}}</div>
|
|
{{/if}}
|
|
<div class="progress-container">
|
|
<div class="progress">
|
|
<div class="bar {{if failureMessage "fail"}}" style={{progressStyle}}></div>
|
|
</div>
|
|
</div>
|
|
{{#if failureMessage}}
|
|
<button class="gh-btn gh-btn-green" {{action "reset"}}><span>Try Again</span></button>
|
|
{{/if}}
|
|
{{else}}
|
|
{{!-- file selection/drag-n-drop --}}
|
|
<div class="upload-form">
|
|
{{#gh-file-input multiple=false alt=description action=(action "fileSelected") accept=accept}}
|
|
<div class="gh-btn gh-btn-outline" data-test-file-input-description><span>{{description}}</span></div>
|
|
{{/gh-file-input}}
|
|
|
|
{{#if (and allowUnsplash settings.unsplash.isActive)}}
|
|
<div class="gh-image-uploader-unsplash" {{action (toggle "_showUnsplash" this)}}>
|
|
{{inline-svg "unsplash"}}
|
|
</div>
|
|
{{/if}}
|
|
</div>
|
|
{{/if}}
|
|
|
|
{{#if _showUnsplash}}
|
|
{{gh-unsplash
|
|
insert=(action "addUnsplashPhoto")
|
|
close=(action (toggle "_showUnsplash" this))
|
|
}}
|
|
{{/if}}
|