mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-24 11:22:19 +03:00
f6c9ffcf60
refs 8e120a74d6
- we use `data-test-state` inside of some modals which also use `<GhTaskButton>` which caused unrelated tests to start failing due to a change in matching element counts
14 lines
726 B
Handlebars
14 lines
726 B
Handlebars
{{#if (has-block)}}
|
|
{{yield (hash
|
|
isIdle=this.isIdle
|
|
isRunning=this.isRunning
|
|
isSuccess=this.isSuccess
|
|
isFailure=this.isFailure
|
|
)}}
|
|
{{else}}
|
|
{{#if this.isRunning}}<span data-test-task-button-state="running">{{svg-jar "spinner" class="gh-icon-spinner"}}{{this.runningText}}</span>{{/if}}
|
|
{{#if this.isIdle}}<span data-test-task-button-state="idle">{{this.buttonText}}</span>{{/if}}
|
|
{{#if this.isSuccess}}<span {{did-insert this.handleReset}} data-test-task-button-state="success">{{svg-jar "check-circle"}} {{this.successText}}</span>{{/if}}
|
|
{{#if this.isFailure}}<span data-test-task-button-state="failure">{{svg-jar "retry"}} {{this.failureText}}</span>{{/if}}
|
|
{{/if}}
|