Problem/Motivation
Expanding a branch or inserting a live comment above the reading position can make the page scroll back and forth, then leave the reader displaced. The compensation loop reverses its own correction on subsequent frames.
A browser reproduction recorded 46 alternating scroll calls and approximately 94 px of final displacement. The existing arrival test can pass while the anchor is briefly in the right place, before it moves again.
Steps to reproduce
- Open a discussion and scroll to a comment below the top of the thread.
- Insert a live root comment above it, or reveal an earlier branch.
- Observe the reading position throughout and after the compensation loop, not just the first corrected frame.
Proposed resolution
Keep the anchor stable by correcting residual displacement without undoing earlier corrections. Superseded compensation must not fight a newer operation or deliberate reader scrolling.
Remaining tasks
- Add a regression test that observes stability throughout and after settling.
- Cover branch expansion, Expand All, and polled arrivals with production
content-visibilityenabled. - Verify in Chromium, Firefox, and WebKit; record unavailable engines explicitly.
User interface changes
The reading position stays stable instead of oscillating or drifting.
API changes
None anticipated.
Data model changes
None anticipated.
Comments
Comment #4
freelockFixed in Alpha4.