Add the saving button title to RegistrationWizard

This commit is contained in:
Eric Schultz 2018-06-28 13:32:49 -05:00
parent 6e50cb6019
commit e6f51940de
4 changed files with 6 additions and 2 deletions

View file

@ -162,6 +162,7 @@ en:
password_confirmation: "Retype Password" password_confirmation: "Retype Password"
phone: "Your Phone (for account recovery)" phone: "Your Phone (for account recovery)"
save_and_finish: "Save & Finish" save_and_finish: "Save & Finish"
saving: "Saving..."
next: "Next" next: "Next"
footer: footer:
terms_and_privacy: "Terms & Privacy" terms_and_privacy: "Terms & Privacy"

View file

@ -197,7 +197,7 @@ export class InnerRegistrationWizard extends React.Component<RegistrationWizardP
buttonText="registration.wizard.next"/> buttonText="registration.wizard.next"/>
<UserInfoPanel tab={this.registrationWizardState.tabsByName['userTab']} <UserInfoPanel tab={this.registrationWizardState.tabsByName['userTab']}
buttonText="registration.wizard.save_and_finish"/> buttonText="registration.wizard.save_and_finish" inProgressTitle="registration.wizard.saving"/>
</Wizard> </Wizard>
} }
} }

View file

@ -39,6 +39,7 @@ export interface UserInfoFormProps
{ {
form: Field form: Field
buttonText:string buttonText:string
inProgressTitle?:string
} }
@ -60,6 +61,7 @@ class UserInfoForm extends React.Component<UserInfoFormProps & InjectedIntlProps
disabled={!this.props.form.isValid} disabled={!this.props.form.isValid}
title={this.props.intl.formatMessage({id: this.props.buttonText})} title={this.props.intl.formatMessage({id: this.props.buttonText})}
inProgress={areWeOrAnyParentSubmitting(this.props.form)} inProgress={areWeOrAnyParentSubmitting(this.props.form)}
titleOnProgress={this.props.intl.formatMessage({id: this.props.inProgressTitle})}
disableOnProgress={true}/> disableOnProgress={true}/>
</fieldset>; </fieldset>;
} }

View file

@ -10,6 +10,7 @@ import UserInfoForm from "./UserInfoForm";
export interface UserInfoPanelProps extends WizardTabPanelProps { export interface UserInfoPanelProps extends WizardTabPanelProps {
buttonText: string buttonText: string
inProgressTitle?:string
} }
class UserInfoPanel extends React.Component<UserInfoPanelProps & InjectedIntlProps, {}> { class UserInfoPanel extends React.Component<UserInfoPanelProps & InjectedIntlProps, {}> {
@ -38,7 +39,7 @@ class UserInfoPanel extends React.Component<UserInfoPanelProps & InjectedIntlPro
return <WizardPanel return <WizardPanel
tab={this.wizardTab} key={this.tabName} tab={this.wizardTab} key={this.tabName}
> >
<UserInfoForm form={this.form} buttonText={this.props.buttonText}/> <UserInfoForm form={this.form} buttonText={this.props.buttonText} inProgressTitle={this.props.inProgressTitle}/>
</WizardPanel>; </WizardPanel>;
} }