|
|
|
@ -48,19 +48,32 @@ export default class ColumnsArea extends ImmutablePureComponent {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
componentDidMount() {
|
|
|
|
|
if (!this.props.singleColumn) {
|
|
|
|
|
this.node.addEventListener('wheel', this.handleWheel, detectPassiveEvents ? { passive: true } : false);
|
|
|
|
|
}
|
|
|
|
|
this.lastIndex = getIndex(this.context.router.history.location.pathname);
|
|
|
|
|
this.setState({ shouldAnimate: true });
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
componentDidUpdate() {
|
|
|
|
|
componentWillUpdate(nextProps) {
|
|
|
|
|
if (this.props.singleColumn !== nextProps.singleColumn && nextProps.singleColumn) {
|
|
|
|
|
this.node.removeEventListener('wheel', this.handleWheel);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
componentDidUpdate(prevProps) {
|
|
|
|
|
if (this.props.singleColumn !== prevProps.singleColumn && !this.props.singleColumn) {
|
|
|
|
|
this.node.addEventListener('wheel', this.handleWheel, detectPassiveEvents ? { passive: true } : false);
|
|
|
|
|
}
|
|
|
|
|
this.lastIndex = getIndex(this.context.router.history.location.pathname);
|
|
|
|
|
this.setState({ shouldAnimate: true });
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
componentWillUnmount () {
|
|
|
|
|
if (!this.props.singleColumn) {
|
|
|
|
|
this.node.removeEventListener('wheel', this.handleWheel);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
handleChildrenContentChange() {
|
|
|
|
|
if (!this.props.singleColumn) {
|
|
|
|
|