Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Merge pull request #4783 from matrix-org/travis/room-list/sticky-head…
Browse files Browse the repository at this point in the history
…ers-reliability

Clear `top` when not sticking headers to the top
  • Loading branch information
turt2live authored Jun 18, 2020
2 parents 4a5cc85 + 8f3a6fc commit c26513b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/components/structures/LeftPanel2.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ export default class LeftPanel2 extends React.Component<IProps, IState> {
header.classList.add("mx_RoomSublist2_headerContainer_sticky");
header.classList.add("mx_RoomSublist2_headerContainer_stickyBottom");
header.style.width = `${headerStickyWidth}px`;
header.style.top = `unset`;
gotBottom = true;
} else if (slRect.top < top) {
header.classList.add("mx_RoomSublist2_headerContainer_sticky");
Expand All @@ -119,6 +120,7 @@ export default class LeftPanel2 extends React.Component<IProps, IState> {
header.classList.remove("mx_RoomSublist2_headerContainer_stickyTop");
header.classList.remove("mx_RoomSublist2_headerContainer_stickyBottom");
header.style.width = `unset`;
header.style.top = `unset`;
}
}
};
Expand Down

0 comments on commit c26513b

Please sign in to comment.