Repository navigation
fix: keep focused thread editor steady as replies arrive - #1458
Merged
Merged
Conversation
Following an incoming thread turn used to consume the gap below a focused editor, pulling it upward even when the new words were visible. Keep the editor at its prior place while following the turn; the exact panel-foot alignment still applies without a focused editor. The browser test now checks the editor's position and the reply's visibility instead of requiring the card's end at the foot in this focused state. Closes #1457
max-sixty
added a commit
that referenced
this pull request
Sep 30, 2026
… its thread up (#1464) A reply landing in the selected thread moved the thread cards after it and the reply box without input, which `test_incoming_reply_follows_a_selected_thread_before_later_cards` showed on Linux CI. The test passed on macOS only because it runs within 500ms of its own summary click, so Chrome credited every frame to that press; under 6x CPU throttling macOS reports all three moves. Two causes, both measured with the Layout Instability API: - The list's place hold (`user-place.js`) held the card the user had named, by its top, even when that top had scrolled far above the band (the focused summary and the pointer both named it, at -315 to -1131px). Holding a top the user cannot see keeps nothing they see still: the card grew down and pushed every later card, off-screen for a long reply. Now only an item whose top stands in the band can be named or lead the hold; the item the band's top cuts holds the place only where no item begins in view. Held by the first later card, the thread grows up into the room scrolled past and nothing after it moves. - Following (`thread-list.js`) landed the thread's end at the landing band's foot, scrolling by the growth plus whatever it took to bring the reply box into the band. In one frame with the growth, that moved the box and the cards after it. Following now keeps the thread's end where it stood, scrolling by exactly the growth, instantly, in the render's frame. This is the rule #1458 gave a focused reply box, now for every follow, so its focus special case is gone. Behavior that moved: - A followed thread's newest words stand where the latest ones did, rather than the thread's end landing at the band's foot. A reply box below the band stays there. `FOLLOWED` now asserts the newest words are in the landing band. - A reader of later cards keeps those cards where they stood; the test asserted the list's scrollTop was unchanged, which is what pushed them. The known-shift entry for this test keeps only `lf-shortcut`, which another decision owns. > _This was written by Claude Code on behalf of max-sixty_ 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 5.5 (1M context) <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Incoming replies now keep a focused thread editor at the position where the user left it while bringing the reply's newest words into view. The previous follow scroll also closed any gap below the editor, moving it without input; the focused case now preserves that gap. With no focused editor, the thread still follows to the panel's foot.
The browser regression checks the editor's position and reply visibility. Before the change, its direct position assertion failed by 40 px, and the existing stability watch failed in all 18 concurrent copies with a 114 px shift. After the change, all 18 copies passed; the full chrome contract file passed 49 tests, and the runtime suite passed 188 tests.
Closes #1457 — automated triage