Merge pull request #5264 from matrix-org/t3chguy/fix/4303
Fix button label on the Set Password Dialog
This commit is contained in:
commit
442f25ca4b
2 changed files with 5 additions and 2 deletions
|
@ -117,7 +117,9 @@ export default class SetPasswordDialog extends React.Component {
|
||||||
autoFocusNewPasswordInput={true}
|
autoFocusNewPasswordInput={true}
|
||||||
shouldAskForEmail={true}
|
shouldAskForEmail={true}
|
||||||
onError={this._onPasswordChangeError}
|
onError={this._onPasswordChangeError}
|
||||||
onFinished={this._onPasswordChanged} />
|
onFinished={this._onPasswordChanged}
|
||||||
|
buttonLabel={_t("Set Password")}
|
||||||
|
/>
|
||||||
<div className="error">
|
<div className="error">
|
||||||
{ this.state.error }
|
{ this.state.error }
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -35,6 +35,7 @@ export default class ChangePassword extends React.Component {
|
||||||
rowClassName: PropTypes.string,
|
rowClassName: PropTypes.string,
|
||||||
buttonClassName: PropTypes.string,
|
buttonClassName: PropTypes.string,
|
||||||
buttonKind: PropTypes.string,
|
buttonKind: PropTypes.string,
|
||||||
|
buttonLabel: PropTypes.string,
|
||||||
confirm: PropTypes.bool,
|
confirm: PropTypes.bool,
|
||||||
// Whether to autoFocus the new password input
|
// Whether to autoFocus the new password input
|
||||||
autoFocusNewPasswordInput: PropTypes.bool,
|
autoFocusNewPasswordInput: PropTypes.bool,
|
||||||
|
@ -271,7 +272,7 @@ export default class ChangePassword extends React.Component {
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<AccessibleButton className={buttonClassName} kind={this.props.buttonKind} onClick={this.onClickChange}>
|
<AccessibleButton className={buttonClassName} kind={this.props.buttonKind} onClick={this.onClickChange}>
|
||||||
{ _t('Change Password') }
|
{ this.props.buttonLabel || _t('Change Password') }
|
||||||
</AccessibleButton>
|
</AccessibleButton>
|
||||||
</form>
|
</form>
|
||||||
);
|
);
|
||||||
|
|
Loading…
Reference in a new issue