|
|
@ -58,7 +58,6 @@ class AutosuggestTextarea extends React.Component {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// auto-resize textarea
|
|
|
|
// auto-resize textarea
|
|
|
|
e.target.style.height = 'auto';
|
|
|
|
|
|
|
|
e.target.style.height = `${e.target.scrollHeight}px`;
|
|
|
|
e.target.style.height = `${e.target.scrollHeight}px`;
|
|
|
|
|
|
|
|
|
|
|
|
this.props.onChange(e);
|
|
|
|
this.props.onChange(e);
|
|
|
@ -147,6 +146,10 @@ class AutosuggestTextarea extends React.Component {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
reset () {
|
|
|
|
|
|
|
|
this.textarea.style.height = 'auto';
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
render () {
|
|
|
|
render () {
|
|
|
|
const { value, suggestions, disabled, placeholder, onKeyUp } = this.props;
|
|
|
|
const { value, suggestions, disabled, placeholder, onKeyUp } = this.props;
|
|
|
|
const { suggestionsHidden, selectedSuggestion } = this.state;
|
|
|
|
const { suggestionsHidden, selectedSuggestion } = this.state;
|
|
|
|