Merge pull request #6751 from matrix-org/dbkr/fix_stuck_scroll

Fix scroll being stuck at bottom
This commit is contained in:
David Baker
2021-09-07 09:48:17 +01:00
committed by GitHub

View File

@@ -275,8 +275,8 @@ export default class ScrollPanel extends React.Component<IProps> {
// fractional values (both too big and too small)
// for scrollTop happen on certain browsers/platforms
// when scrolled all the way down. E.g. Chrome 72 on debian.
// so check difference <= 1;
return Math.abs(sn.scrollHeight - (sn.scrollTop + sn.clientHeight)) <= 1;
// so check difference < 1;
return Math.abs(sn.scrollHeight - (sn.scrollTop + sn.clientHeight)) < 1;
};
// returns the vertical height in the given direction that can be removed from