fix(meteor): Scroll position is lost when loading older messages (#29454)

pull/29304/head^2
gabriellsh 3 years ago committed by GitHub
parent 9160c21118
commit 40d7f7955c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      .changeset/honest-mails-try.md
  2. 2
      apps/meteor/app/ui-utils/client/lib/RoomHistoryManager.ts

@ -0,0 +1,5 @@
---
"@rocket.chat/meteor": patch
---
fix(meteor): Scroll position is lost when loading older messages

@ -164,7 +164,7 @@ class RoomHistoryManagerClass extends Emitter {
room.unreadNotLoaded.set(result.unreadNotLoaded);
room.firstUnread.set(result.firstUnread);
const wrapper = await waitForElement('.messages-box .wrapper');
const wrapper = await waitForElement('.messages-box .wrapper .rc-scrollbars-view');
if (wrapper) {
previousHeight = wrapper.scrollHeight;

Loading…
Cancel
Save