heilhead / react-bootstrap-validation

Form validation for react-bootstrap
MIT License
136 stars 50 forks source link

horizontal forms? #32

Open ir-fuel opened 8 years ago

ir-fuel commented 8 years ago

It seems not possible to have the label of the input field in front of the field?

haikezegwaard commented 8 years ago

Try to use: <Form className="form-horizontal"> and then in your ValidatedInput components, set the bootstrap column sizes: e.g. <ValidatedInput type='text' label={gettext('First name')} labelClassName='col-sm-4' wrapperClassName='col-sm-12' name='first_name' defaultValue={this.props.first_name} validate='required' errorHelp={{ required: gettext('Please enter your first name') }} />