Skip to content

fix: keep focused thread editor steady as replies arrive - #1458

Merged
leaf-agent merged 1 commit into
mainfrom
fix/issue-1457
Sep 30, 2026
Merged

leaf-agent merged 1 commit into
mainfrom
fix/issue-1457

Conversation

@leaf-agent

Copy link
Copy Markdown
Collaborator

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

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
@leaf-agent
leaf-agent merged commit 528dc6b into main Sep 30, 2026
4 checks passed
@leaf-agent
leaf-agent deleted the fix/issue-1457 branch September 30, 2026 04:16
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]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ci-fix: main CI thread reply follow moves the focused editor

1 participant