# fix\(web\): let LegendList own end-follow and disclosure anchoring \(\#5449\) · pingdotgg/t3code

[View on GitCafe](https://git.cafe/pingdotgg/t3code/commit/8edf3db19a45483a10eabc758289c88fe4ba08d8)

Repository: [pingdotgg/t3code](https://git.cafe/pingdotgg/t3code)

Visibility: public

Requested revision: 8edf3db19a45483a10eabc758289c88fe4ba08d8

Requested commit: 8edf3db19a45483a10eabc758289c88fe4ba08d8

Commit: 8edf3db19a45483a10eabc758289c88fe4ba08d8

Tree: 28051a90b2ce947234a07b8a732065eac0687281

Author: Julius Marminge

Committer: Julius Marminge

## Message

```
fix(web): let LegendList own end-follow and disclosure anchoring (#5449)

Complete the #5449 architecture on the v2 timeline, following the
LegendList author's direction to lean on the list's native mechanisms
instead of app-side scroll layers:

- maintainScrollAtEnd is enabled and owned by LegendList, gated off only
  while the user reads history (liveFollowEnabled), while a sent turn
  anchors near the top (anchoredEndSpace), or during the two-frame settle
  of a fold toggle.
- maintainVisibleContentPosition compensates size changes natively
  ({data, size, shouldRestorePosition}); fold toggles anchor compensation
  to the toggled row via a disclosure anchor key, so the trigger stays
  under the pointer instead of the viewport chasing the end.
- ChatView's hand-rolled streaming follow (double-rAF scrollToEnd on
  every data change) is gone; the app now only owns streaming
  adjustments during anchored-end-space mode, mirroring main.
- timelineLiveFollowEnabled state mirrors the follow refs so the
  render-visible gate switches native follow off when a gesture breaks
  follow and back on when the viewport returns to the end band.

Timeline tests updated to assert the native-ownership invariants.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

```

## Parents

- [55b51547b7e7693502f2626735e0c127636dcf15](https://git.cafe/pingdotgg/t3code/commit/55b51547b7e7693502f2626735e0c127636dcf15?format=markdown)

[Source at this commit](https://git.cafe/pingdotgg/t3code/tree/8edf3db19a45483a10eabc758289c88fe4ba08d8?format=markdown)
