mirror of
https://github.com/ascribe/onion.git
synced 2024-12-22 17:33:14 +01:00
fix InputTextareaToggable
This commit is contained in:
parent
90d6ec20f6
commit
4acbc2c923
@ -19,6 +19,12 @@ let InputTextAreaToggable = React.createClass({
|
||||
};
|
||||
},
|
||||
|
||||
componentDidMount() {
|
||||
this.setState({
|
||||
value: this.props.defaultValue
|
||||
});
|
||||
},
|
||||
|
||||
componentDidUpdate() {
|
||||
// If the initial value of state.value is null, we want to set props.defaultValue
|
||||
// as a value. In all other cases TextareaAutosize.onChange is updating.handleChange already
|
||||
|
Loading…
Reference in New Issue
Block a user