import PropTypes from 'prop-types'; import ImmutablePropTypes from 'react-immutable-proptypes'; const style = { display: 'block', fontFamily: 'inherit', marginBottom: '10px', padding: '7px 0', boxSizing: 'border-box', width: '100%' }; class SettingText extends React.PureComponent { constructor (props, context) { super(props, context); this.handleChange = this.handleChange.bind(this); } handleChange (e) { this.props.onChange(this.props.settingKey, e.target.value) } render () { const { settings, settingKey, label } = this.props; return ( ); } } SettingText.propTypes = { settings: ImmutablePropTypes.map.isRequired, settingKey: PropTypes.array.isRequired, label: PropTypes.string.isRequired, onChange: PropTypes.func.isRequired }; export default SettingText;