mirror of
https://github.com/vector-im/hydrogen-web.git
synced 2025-01-11 20:47:18 +01:00
Add explaining comment
Signed-off-by: RMidhunSuresh <hi@midhun.dev>
This commit is contained in:
parent
b979e11ef5
commit
7e8c0109ae
@ -53,6 +53,12 @@ export class TimelineViewModel extends ViewModel {
|
|||||||
let hasSeenUpdate = false;
|
let hasSeenUpdate = false;
|
||||||
const checkForUpdate = (idx, tile) => {
|
const checkForUpdate = (idx, tile) => {
|
||||||
if (tile.shape !== "gap") {
|
if (tile.shape !== "gap") {
|
||||||
|
/*
|
||||||
|
It's possible that this method executes before the GapTile has been rendered,
|
||||||
|
so don't count the GapTile as an update.
|
||||||
|
Usually happens when onScroll() is triggered by a non-timeline UI change,
|
||||||
|
eg: SessionStatusView being rendered
|
||||||
|
*/
|
||||||
hasSeenUpdate = true;
|
hasSeenUpdate = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user