mirror of
https://github.com/scratchfoundation/scratch-www.git
synced 2024-11-27 09:35:56 -05:00
Merge pull request #1149 from mewtaylor/issue/r2-4092
For R2-4092: Add checkbox to opt-in to teacher emails
This commit is contained in:
commit
8e82398255
3 changed files with 30 additions and 16 deletions
|
@ -870,23 +870,35 @@ module.exports = {
|
||||||
</p>
|
</p>
|
||||||
<Card>
|
<Card>
|
||||||
<Form onValidSubmit={this.onValidSubmit}>
|
<Form onValidSubmit={this.onValidSubmit}>
|
||||||
<Input label={formatMessage({id: 'general.emailAddress'})}
|
<Input
|
||||||
type="text"
|
label={formatMessage({id: 'general.emailAddress'})}
|
||||||
name="user.email"
|
type="text"
|
||||||
validations="isEmail"
|
name="user.email"
|
||||||
validationError={formatMessage({id: 'general.validationEmail'})}
|
validations="isEmail"
|
||||||
required />
|
validationError={formatMessage({id: 'general.validationEmail'})}
|
||||||
<Input label={formatMessage({id: 'general.confirmEmail'})}
|
required
|
||||||
type="text"
|
/>
|
||||||
name="confirmEmail"
|
<Input
|
||||||
validations="equalsField:user.email"
|
label={formatMessage({id: 'general.confirmEmail'})}
|
||||||
validationErrors={{
|
type="text"
|
||||||
equalsField: formatMessage({id: 'general.validationEmailMatch'})
|
name="confirmEmail"
|
||||||
}}
|
validations="equalsField:user.email"
|
||||||
required />
|
validationErrors={{
|
||||||
|
equalsField: formatMessage({id: 'general.validationEmailMatch'})
|
||||||
|
}}
|
||||||
|
required
|
||||||
|
/>
|
||||||
|
<Checkbox
|
||||||
|
label={formatMessage({id: 'registration.optIn'})}
|
||||||
|
value={true}
|
||||||
|
help={null}
|
||||||
|
name="subscribe"
|
||||||
|
/>
|
||||||
<GeneralError name="all" />
|
<GeneralError name="all" />
|
||||||
<NextStepButton waiting={this.props.waiting}
|
<NextStepButton
|
||||||
text={<intl.FormattedMessage id="registration.nextStep" />} />
|
waiting={this.props.waiting}
|
||||||
|
text={<intl.FormattedMessage id="registration.nextStep" />}
|
||||||
|
/>
|
||||||
</Form>
|
</Form>
|
||||||
</Card>
|
</Card>
|
||||||
<StepNavigation steps={this.props.totalSteps - 1} active={this.props.activeStep} />
|
<StepNavigation steps={this.props.totalSteps - 1} active={this.props.activeStep} />
|
||||||
|
|
|
@ -125,6 +125,7 @@
|
||||||
"registration.newPassword": "New Password",
|
"registration.newPassword": "New Password",
|
||||||
"registration.nextStep": "Next Step",
|
"registration.nextStep": "Next Step",
|
||||||
"registration.notYou": "Not you? Log in as another user",
|
"registration.notYou": "Not you? Log in as another user",
|
||||||
|
"registration.optIn": "Send me updates on using Scratch in educational settings",
|
||||||
"registration.personalStepTitle": "Personal Information",
|
"registration.personalStepTitle": "Personal Information",
|
||||||
"registration.personalStepDescription": "Your individual responses will not be displayed publicly, and will be kept confidential and secure",
|
"registration.personalStepDescription": "Your individual responses will not be displayed publicly, and will be kept confidential and secure",
|
||||||
"registration.selectCountry": "select country",
|
"registration.selectCountry": "select country",
|
||||||
|
|
|
@ -50,6 +50,7 @@ var TeacherRegistration = intl.injectIntl(React.createClass({
|
||||||
this.state.formData.user.gender
|
this.state.formData.user.gender
|
||||||
),
|
),
|
||||||
country: this.state.formData.user.country,
|
country: this.state.formData.user.country,
|
||||||
|
subscribe: formData.subscribe,
|
||||||
is_robot: this.state.formData.user.isRobot,
|
is_robot: this.state.formData.user.isRobot,
|
||||||
first_name: this.state.formData.user.name.first,
|
first_name: this.state.formData.user.name.first,
|
||||||
last_name: this.state.formData.user.name.last,
|
last_name: this.state.formData.user.name.last,
|
||||||
|
|
Loading…
Reference in a new issue