Ghost/ghost/admin/app/components/gh-task-button.hbs

14 lines
577 B
Handlebars
Raw Normal View History

{{#if (has-block)}}
{{yield (hash
isIdle=this.isIdle
isRunning=this.isRunning
isSuccess=this.isSuccess
isFailure=this.isFailure
)}}
{{else}}
{{#if this.isRunning}}<span>{{svg-jar "spinner" class="gh-icon-spinner"}}{{this.runningText}}</span>{{/if}}
{{#if this.isIdle}}<span>{{this.buttonText}}</span>{{/if}}
{{#if this.isSuccess}}<span {{did-insert this.handleReset}}>{{svg-jar "check-circle"}} {{this.successText}}</span>{{/if}}
{{#if this.isFailure}}<span>{{svg-jar "retry"}} {{this.failureText}}</span>{{/if}}
{{/if}}