Conversation
|
Someone is attempting to deploy a commit to the Modem Team on Vercel. A member of the Team first needs to authorize it. |
Contributor
|
PR author is not in the allowed authors list. |
Member
|
Thanks for submitting this! Sorry it took me a while. |
- Add `scroll_off` config key and `--scroll-off <rows>` flag (0-40), mirroring Vim's scrolloff - Apply margin in computeLineRevealScrollTop so stepping keeps the current line clear of the viewport edge - Add unit and PTY coverage, update docs and changeset
Member
|
Rebased onto current Validation on Linux: This comment was generated by Pi using gpt-6.1-sol |
benvinegar
force-pushed
the
feat/scroll-off
branch
from
October 12, 2026 15:53
a7549b4 to
34ebb40
Compare
benvinegar
enabled auto-merge (squash)
October 12, 2026 16:09
1 task
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.
Fixes #793
Summary
scroll_offconfig key and--scroll-off <rows>flag (0-40), mirroring Vim'sscrolloff: the current line keeps that many rows clear of the viewport edge instead of only reacting once it reaches the edge.computeLineRevealScrollTop, consumed by both line-cursor stepping and the draft-note reveal path (the note-reveal call site was missing the newscrollOffparam — now consistent with the stepping call site).Test plan
bun run typecheckbun test packages/hunk/src/ui/lib/hunkScroll.test.ts packages/hunk/src/core/run/scrollOff.test.ts packages/hunk/src/core/run/config.test.ts packages/hunk/src/app/cli.test.ts(240 pass)bun test packages/hunk/src/ui/components/panes/DiffPane.test.tsx(2 pass)bun run test:integration— 181/186 pass; the 5 failures are pre-existingtest/pty/lifecycle.test.tsSIGHUP/SIGQUIT/SIGPIPE flakes unrelated to this change (reproduce onmain).test/pty/cursor-line.test.ts's dedicatedscroll-off starts scrolling before the current line reaches the viewport edgetest passes.Before: (notice the active line on animations = true)

After:
