The top of the scrollable notifications will be invisible after unmounting.
The Redux state should be updated accordingly in such a case so that the
unread notification counter will be updated later.
trackScroll: true,
};
+ componentWillUnmount () {
+ this.handleScrollToBottom.cancel();
+ this.handleScrollToTop.cancel();
+ this.handleScroll.cancel();
+ this.props.dispatch(scrollTopNotifications(false));
+ }
+
handleScrollToBottom = debounce(() => {
this.props.dispatch(scrollTopNotifications(false));
this.props.dispatch(expandNotifications());