diff options
| author | Shpuld Shpuldson <shp@cock.li> | 2021-02-17 10:16:58 +0200 |
|---|---|---|
| committer | Shpuld Shpuldson <shp@cock.li> | 2021-02-17 10:16:58 +0200 |
| commit | 47770ed7151ad0ba1cd8b77eb52590edd9ce9737 (patch) | |
| tree | e7ccaccbfa8cef56de11c56425cd9b08308ba066 /src/components/chat | |
| parent | aa240f935f5a32ca78cb1ccc26573a5a9fb0ed29 (diff) | |
get rid of older messages when scrolling down in chat to keep it from bloating dom
Diffstat (limited to 'src/components/chat')
| -rw-r--r-- | src/components/chat/chat.js | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/components/chat/chat.js b/src/components/chat/chat.js index e57fcb91..f446f25b 100644 --- a/src/components/chat/chat.js +++ b/src/components/chat/chat.js @@ -241,6 +241,7 @@ const Chat = { this.fetchChat({ maxId: this.currentChatMessageService.minId }) } else if (this.bottomedOut(JUMP_TO_BOTTOM_BUTTON_VISIBILITY_OFFSET)) { this.jumpToBottomButtonVisible = false + this.$store.dispatch('cullOlderMessages', this.currentChatMessageService.chatId) if (this.newMessageCount > 0) { // Use a delay before marking as read to prevent situation where new messages // arrive just as you're leaving the view and messages that you didn't actually |
