import React from 'react'; const searchBoxStyling = { float: 'right', height: '28px', backgroundColor: 'white', position: 'absolute', right: '10px', top: '25px', width: '224px', zIndex: '9999' }; const enterKey = 13; export default class SearchBox extends React.PureComponent { constructor(props) { super(props); this.searchTerm = ''; } handleChange = event => { this.searchTerm = event.target.value; if (event.keyCode === enterKey) { this.props.search(event.target.value); } }; render() { return (
input && input.focus()} /> this.props.prev(this.searchTerm)}> {' '} ←{' '} this.props.next(this.searchTerm)}> {' '} →{' '} this.props.close()}> {' '} x{' '}
); } }