update reason or joining form to simpletextarea

merge-requests/155/head
Mary Kate 4 years ago
parent 4ce5ba6c1a
commit 774adf9baa

@ -70,7 +70,7 @@ LabelInput.propTypes = {
export const LabelTextarea = ({ label, dispatch, ...props }) => ( export const LabelTextarea = ({ label, dispatch, ...props }) => (
<LabelInputContainer label={label}> <LabelInputContainer label={label}>
<intextarea {...props} /> <textarea {...props} />
</LabelInputContainer> </LabelInputContainer>
); );

@ -9,6 +9,7 @@ import {
SimpleForm, SimpleForm,
SimpleInput, SimpleInput,
TextInput, TextInput,
SimpleTextarea,
Checkbox, Checkbox,
} from 'soapbox/features/forms'; } from 'soapbox/features/forms';
import { register } from 'soapbox/actions/auth'; import { register } from 'soapbox/actions/auth';
@ -24,7 +25,6 @@ const messages = defineMessages({
confirm: { id: 'registration.fields.confirm_placeholder', defaultMessage: 'Password (again)' }, confirm: { id: 'registration.fields.confirm_placeholder', defaultMessage: 'Password (again)' },
agreement: { id: 'registration.agreement', defaultMessage: 'I agree to the {tos}.' }, agreement: { id: 'registration.agreement', defaultMessage: 'I agree to the {tos}.' },
tos: { id: 'registration.tos', defaultMessage: 'Terms of Service' }, tos: { id: 'registration.tos', defaultMessage: 'Terms of Service' },
reason: { id: 'registration.reason', defaultMessage: 'Reason for Joining' },
}); });
const mapStateToProps = (state, props) => ({ const mapStateToProps = (state, props) => ({
@ -138,8 +138,9 @@ class RegistrationForm extends ImmutablePureComponent {
required required
/> />
{instance.get('approval_required') && {instance.get('approval_required') &&
<TextInput <SimpleTextarea
placeholder={intl.formatMessage(messages.reason)} label={<FormattedMessage id='registration.reason' defaultMessage='Why do you want to join?' />}
hint={<FormattedMessage id='registration.reason_hint' defaultMessage='This will help us review your application' />}
name='reason' name='reason'
maxLength={500} maxLength={500}
autoComplete='off' autoComplete='off'

Loading…
Cancel
Save