content: /* eslint-disable flowtype/require-valid-file-annotation */
  
  import React from 'react';
  import PropTypes from 'prop-types';
  import { withStyles } from 'material-ui/styles';
  import Input, { InputLabel } from 'material-ui/Input';
  import { FormControl, FormHelperText } from 'material-ui/Form';
  
  const styles = theme => ({
    container: {
      display: 'flex',
      flexWrap: 'wrap',
    },
    formControl: {
      margin: theme.spacing.unit,
    },
  });
  
  class ComposedTextField extends React.Component {
    state = {
      name: 'Composed TextField',
    };
  
    handleChange = event => {
      this.setState({ name: event.target.value });
    };
  
    render() {
      const classes = this.props.classes;
  
      return (
        <div className={classes.container}>
          <FormControl className={classes.formControl}>
            <InputLabel htmlFor="name-simple">Name</InputLabel>
            <Input id="name-simple" value={this.state.name} onChange={this.handleChange} />
          </FormControl>
          <FormControl className={classes.formControl}>
            <InputLabel htmlFor="name-helper">Name</InputLabel>
            <Input id="name-helper" value={this.state.name} onChange={this.handleChange} />
            <FormHelperText>Some important helper text</FormHelperText>
          </FormControl>
          <FormControl className={classes.formControl} disabled>
            <InputLabel htmlFor="name-disabled">Name</InputLabel>
            <Input id="name-disabled" value={this.state.name} onChange={this.handleChange} />
            <FormHelperText>Disabled</FormHelperText>
          </FormControl>
          <FormControl className={classes.formControl} error>
            <InputLabel htmlFor="name-error">Name</InputLabel>
            <Input id="name-error" value={this.state.name} onChange={this.handleChange} />
            <FormHelperText>Error</FormHelperText>
          </FormControl>
        </div>
      );
    }
  }
  
  ComposedTextField.propTypes = {
    classes: PropTypes.object.isRequired,
  };
  
  export default withStyles(styles)(ComposedTextField);
  