Ghost/ghost/admin/app/components/gh-image-uploader-with-preview.hbs

19 lines
573 B
Handlebars
Raw Normal View History

{{#if this.image}}
<div class="gh-image-uploader -with-image">
<div><img src={{this.image}}></div>
<a class="image-cancel" title="Delete" {{action "remove"}}>
{{svg-jar "trash"}}
<span class="hidden">Delete</span>
</a>
</div>
{{else}}
<GhImageUploader
@text={{this.text}}
@altText={{this.altText}}
@allowUnsplash={{this.allowUnsplash}}
@update={{action "update"}}
@uploadStarted={{action "uploadStarted"}}
@uploadFinished={{action "uploadFinished"}}
/>
{{/if}}