Fix preserving scroll position on audio toggle

This commit is contained in:
Eduard Kuzmenko 2022-04-04 16:27:09 +03:00
parent cec8098b58
commit d56dcbbd96

View File

@ -892,7 +892,7 @@ export default class ChatBubbles {
let scrolled = 0; let scrolled = 0;
let part = 0; let part = 0;
let rAF = 0; let rAF = 0;
let skipNext = true; // let skipNext = true;
const onResizeEnd = () => { const onResizeEnd = () => {
const height = container.offsetHeight; const height = container.offsetHeight;
@ -926,10 +926,10 @@ export default class ChatBubbles {
}; };
const processEntries: ResizeObserverCallback = (entries) => { const processEntries: ResizeObserverCallback = (entries) => {
if(skipNext) { /* if(skipNext) {
skipNext = false; skipNext = false;
return; return;
} } */
if(skip) { if(skip) {
setEndRAF(false); setEndRAF(false);