mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-28 22:43:30 +03:00
f1512d12c2
refs https://github.com/TryGhost/Ghost/issues/7515 - changes to `gh-task-button`: - can take `buttonText` (default: "Save"), `runningText` ("Saving"), `successText` ("Saved"), and `failureText` ("Retry") params - positional param for `buttonText` - default button display can be overridden by passing in a block, in that scenario the component will yield a hash containing all states to be used in this fashion: ``` {{#gh-task-button task=myTask as |task|}} {{if task.isIdle "Save me"}} {{if task.isRunning "Saving"}} {{if task.isSuccess "Thank you!"}} {{if task.isFailure "Nooooooo!"}} {{/gh-task-button}} ``` - update existing uses of `gh-task-button` to match new component signature
19 lines
1.1 KiB
Handlebars
19 lines
1.1 KiB
Handlebars
<div class="gh-flow">
|
|
<div class="gh-flow-content-wrap">
|
|
<section class="gh-flow-content fade-in">
|
|
<form id="reset" class="gh-signin" method="post" novalidate="novalidate" {{action "submit" on="submit"}}>
|
|
{{#gh-form-group errors=errors hasValidated=hasValidated property="newPassword"}}
|
|
{{gh-input newPassword type="password" name="newpassword" placeholder="Password" class="password" autocorrect="off" autofocus="autofocus" update=(action (mut newPassword))}}
|
|
{{/gh-form-group}}
|
|
{{#gh-form-group errors=errors hasValidated=hasValidated property="ne2Password"}}
|
|
{{gh-input ne2Password type="password" name="ne2password" placeholder="Confirm Password" class="password" autocorrect="off" autofocus="autofocus" update=(action (mut ne2Password))}}
|
|
{{/gh-form-group}}
|
|
|
|
{{gh-task-button "Reset Password" task=resetPassword class="gh-btn gh-btn-blue gh-btn-block" type="submit" autoWidth="false"}}
|
|
</form>
|
|
|
|
<p class="main-error">{{{flowErrors}}}</p>
|
|
</section>
|
|
</div>
|
|
</div>
|