|
|
@ -43,12 +43,20 @@ export default class Compose extends React.PureComponent { |
|
|
|
}; |
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
componentDidMount () { |
|
|
|
componentDidMount () { |
|
|
|
|
|
|
|
const { isSearchPage } = this.props; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (!isSearchPage) { |
|
|
|
this.props.dispatch(mountCompose()); |
|
|
|
this.props.dispatch(mountCompose()); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
componentWillUnmount () { |
|
|
|
componentWillUnmount () { |
|
|
|
|
|
|
|
const { isSearchPage } = this.props; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (!isSearchPage) { |
|
|
|
this.props.dispatch(unmountCompose()); |
|
|
|
this.props.dispatch(unmountCompose()); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
onFocus = () => { |
|
|
|
onFocus = () => { |
|
|
|
this.props.dispatch(changeComposing(true)); |
|
|
|
this.props.dispatch(changeComposing(true)); |
|
|
|