fix(chat): release end pinning while the list width resizes
A pinned viewport shook during window resizes while a scrolled-up one stayed calm: both pinning mechanisms — the growth corrections and the list's maintain-scroll-at-end — re-assert the end against rows that are still re-measuring, fighting the size compensation that keeps the free case stable. While the width is actively changing, stand both down and hold the reading position the same way the free path does, then re-assert the live edge once with a single instant write after the resize settles (only when the viewport was still following).
This commit is contained in:
@@ -1061,7 +1061,11 @@ const TimelineList = React.memo(({
|
||||
contentInsetEndAdjustment={composerOverlayHeight}
|
||||
// While a turn is anchored, the reserved end space — not the
|
||||
// live edge — defines where the viewport rests.
|
||||
maintainScrollAtEnd={anchoredEndSpace || !streamingAutoFollowEnabled
|
||||
// Also released while the width resizes: re-pinning against
|
||||
// rows that are still re-measuring shakes the pinned
|
||||
// viewport; the owning hook re-asserts the end once the
|
||||
// resize settles.
|
||||
maintainScrollAtEnd={anchoredEndSpace || !streamingAutoFollowEnabled || isWidthResizing
|
||||
? false
|
||||
: { animated: false, on: { dataChange: true, itemLayout: true, layout: true } }}
|
||||
// Prepending older history must not move what the user is
|
||||
|
||||
Reference in New Issue
Block a user