mirror of
https://github.com/Novaloop-AG/healthchat-web.git
synced 2026-11-08 07:28:26 +00:00
Merge pull request #6751 from matrix-org/dbkr/fix_stuck_scroll
Fix scroll being stuck at bottom
This commit is contained in:
@@ -275,8 +275,8 @@ export default class ScrollPanel extends React.Component<IProps> {
|
|||||||
// fractional values (both too big and too small)
|
// fractional values (both too big and too small)
|
||||||
// for scrollTop happen on certain browsers/platforms
|
// for scrollTop happen on certain browsers/platforms
|
||||||
// when scrolled all the way down. E.g. Chrome 72 on debian.
|
// when scrolled all the way down. E.g. Chrome 72 on debian.
|
||||||
// so check difference <= 1;
|
// so check difference < 1;
|
||||||
return Math.abs(sn.scrollHeight - (sn.scrollTop + sn.clientHeight)) <= 1;
|
return Math.abs(sn.scrollHeight - (sn.scrollTop + sn.clientHeight)) < 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
// returns the vertical height in the given direction that can be removed from
|
// returns the vertical height in the given direction that can be removed from
|
||||||
|
|||||||
Reference in New Issue
Block a user