make .no-label an auto assignment

thanks @rschamp!
This commit is contained in:
Matthew Taylor 2016-07-26 10:44:19 -04:00
parent b510d154df
commit 69ac5b60bd
3 changed files with 2 additions and 4 deletions

View file

@ -30,7 +30,8 @@ var Input = React.createClass({
render: function () {
var classes = classNames(
this.state.status,
this.props.className
this.props.className,
{'no-label': (typeof this.props.label === 'undefined')}
);
return (
<FRCInput {... this.props}

View file

@ -223,7 +223,6 @@ var Navigation = React.createClass({
<Form onSubmit={this.onSearchSubmit}>
<Button type="submit" className="btn-search" />
<Input type="text"
className="no-label"
aria-label={formatMessage({id: 'general.search'})}
placeholder={formatMessage({id: 'general.search'})}
name="q" />

View file

@ -315,7 +315,6 @@ module.exports = {
<div className="gender-input">
<Input name="user.genderOther"
type="text"
className="no-label"
disabled={this.state.otherDisabled}
required={!this.state.otherDisabled}
help={null} />
@ -500,7 +499,6 @@ module.exports = {
</div>
<div className="other-input">
<Input type="text"
className="no-label"
name="organization.other"
disabled={this.state.otherDisabled}
required="isFalse"