fix(tui): preserve detached scrolling across layout changes - #350
Merged
Merged
Conversation
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.
Change
When a user scrolls up in fullscreen mode, growing the viewport or shrinking the footer/transcript can clamp the scroll position to the current end. Layout then silently restores follow-tail, so subsequent streamed output moves the viewport away from the user's reading position.
Clamp the position without changing follow state. End, explicitly scrolling back to the bottom, and accepted user submissions retain their existing behavior. Regression coverage includes viewport growth, footer shrink, content shrink, temporarily fitting all content, continued streaming, and resuming with End. Engine change records are updated.
Related to #348 and #349, which contain the same report. This fixes the reproduced fullscreen layout-clamping cases. The reported regular-mode and no-layout-change symptoms remain unconfirmed; these issues are not claimed fully resolved.
Validation
pnpm verify, full profile, clean commit857df53, macOS arm64, Node.js 26.4.0: all 15 applicable gates passed, including source/export checks, release tooling, lint, typecheck, build, artifact checks, capabilities (4,588 passed, 14 skipped), status contract, smoke, BYOK, policy and sandbox.ScrollViewimplementation makes all four layout regressions fail; the fixed implementation passes.18e7278, all 88 subsequent samples moved away from the post-resize anchor; on857df53, none of the 88 samples moved. Each resize run observed 145 streamed chunks.Publication and contribution checks
Maintainer handoff
Publication scope or license changes: none.
Shared-source port: pending.