import classNames from 'classnames'; import PropTypes from 'prop-types'; import React, { Component } from 'react'; import Icon from 'Components/Icon'; import Link from 'Components/Link/Link'; import { icons } from 'Helpers/Props'; import styles from './EnhancedSelectInputOption.css'; class EnhancedSelectInputOption extends Component { // // Listeners onPress = () => { const { id, onSelect } = this.props; onSelect(id); } // // Render render() { const { className, isSelected, isDisabled, isHidden, isMobile, children } = this.props; return ( {children} { isMobile &&
} ); } } EnhancedSelectInputOption.propTypes = { className: PropTypes.string.isRequired, id: PropTypes.string.isRequired, isSelected: PropTypes.bool.isRequired, isDisabled: PropTypes.bool.isRequired, isHidden: PropTypes.bool.isRequired, isMobile: PropTypes.bool.isRequired, children: PropTypes.node.isRequired, onSelect: PropTypes.func.isRequired }; EnhancedSelectInputOption.defaultProps = { className: styles.option, isDisabled: false, isHidden: false }; export default EnhancedSelectInputOption;