Use full-text search for autosuggestions

This commit is contained in:
Eugen Rochko
2016-11-12 14:33:21 +01:00
parent cd765f26a9
commit 09218d4c01
14 changed files with 153 additions and 39 deletions

View File

@ -4,14 +4,15 @@ const Avatar = React.createClass({
propTypes: {
src: React.PropTypes.string.isRequired,
size: React.PropTypes.number.isRequired
size: React.PropTypes.number.isRequired,
style: React.PropTypes.object
},
mixins: [PureRenderMixin],
render () {
return (
<div style={{ width: `${this.props.size}px`, height: `${this.props.size}px` }}>
<div style={{ ...this.props.style, width: `${this.props.size}px`, height: `${this.props.size}px` }}>
<img src={this.props.src} width={this.props.size} height={this.props.size} alt='' style={{ display: 'block', borderRadius: '4px' }} />
</div>
);