clear unread message count more aggressively (and revert previous thinko)
This commit is contained in:
@@ -335,7 +335,7 @@ module.exports = {
|
|||||||
if (this.refs.messagePanel) {
|
if (this.refs.messagePanel) {
|
||||||
var messageWrapperScroll = this._getScrollNode();
|
var messageWrapperScroll = this._getScrollNode();
|
||||||
var wasAtBottom = this.atBottom;
|
var wasAtBottom = this.atBottom;
|
||||||
this.atBottom = messageWrapperScroll.scrollHeight - messageWrapperScroll.scrollTop <= messageWrapperScroll.clientHeight - 1;
|
this.atBottom = messageWrapperScroll.scrollHeight - messageWrapperScroll.scrollTop <= messageWrapperScroll.clientHeight + 1;
|
||||||
if (this.atBottom && !wasAtBottom) {
|
if (this.atBottom && !wasAtBottom) {
|
||||||
this.forceUpdate(); // remove unread msg count
|
this.forceUpdate(); // remove unread msg count
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user