Repository navigation
Fit each file box on the PR page to its diff; Global comment beside Split/Unified - #2632
Merged
Merged
Conversation
…Split/Unified row The PR page's file boxes used the guide's fixed estimate, which counted git's header lines and had a 150px floor, so a 5-line file sat in a 304px box. In GuideView bare mode each box now starts from the hunks' rows and then takes the height AllFilesCodeView reports, capped at 620px as before. The Global comment button moves onto the Split | Unified tab's row (owner, q-bfcf3a4a B); with no tab (a phone) it keeps its own row. Outside bare mode nothing changes.
…remount's first shrink GuideView gets an opt-in fitFileHeights (default: bare only) and GuideReader passes it, so the guided review in a thread fits too; the review app, guides.show and VS Code keep the fixed estimate. The first estimate follows the host's layout (Split pairs removed and added lines). After a remount, a first report that shrinks the box waits two frames for the viewer to draw, so a commented file does not dip for a frame.
…wait The first estimate charged 32 px per separator; the browser draws 40 above a first hunk and 48 between hunks, and a row for each "\ No newline" note, so modified files grew on first mount. Tests: the latest shrinking report lands, a wait dies with its CodeView, and the lease-waiting tests carry an explicit timeout. Wording that still said the fit came from `bare`, or from every Inbox reader, now says what does.
This was referenced Nov 5, 2026
backnotprop
added a commit
that referenced
this pull request
Nov 5, 2026
…the review app's fill The owner decided there is no height limit in the Inbox: #2635 removes the cap for fitted hosts, so this drops --guide-file-fit-max, its 100cqh rule, GuideFileCard's max-height and their tests. GuideFileCard is back to #2632's. The pane stays an inline-size container for the note's room on the controls' row. From REVIEW_FOLD_PANEL_BELOW up the comments column takes the review app's bg-card/30 over --background; folded, the sheet stays a card over the diff.
backnotprop
changed the base branch from
feat/pulls-review-with-agent
to
main
November 5, 2026 02:05
backnotprop
marked this pull request as ready for review
November 5, 2026 02:06
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.
On the PR page (the review in the PR pane, #2615), a 5-line file sat in a 304px box with empty space under its lines. Each file box used the guide's fixed height estimate, which counts git's header lines and has a 150px floor. The diff scrolls inside that fixed box, so the box never shrank to fit.
What changes:
GuideReader(the PR page, the guided review in a thread, the full-window review; the phone surface'sSurfaceGuideReaderandShapeCodeGuidekeep the fixed estimate), through a new opt-inGuideViewprop,fitFileHeights, thatGuideReaderpasses: each file box starts at the height of its hunk rows (in Split, paired removed and added lines count once; 40 px above a first hunk, 48 px between hunks, a row for each\ No newlinenote, as measured in the browser). Then it takes the heightAllFilesCodeViewreports through a new optionalonContentHeightChangeprop. The cap stays at 620px, and a longer diff still scrolls inside its box. Inline comments and wrapped lines make the box grow. After a remount, a first report that shrinks the box waits two frames, so a commented file does not dip.bare), the Global comment button moves onto the Split | Unified tab's row, to the left of the tab (owner, q-bfcf3a4a B). On a phone there is no tab, so the button stays on its own row.The review app, guides.show and VS Code do not opt in and keep the fixed estimate.
Stacked on #2615 (base
feat/pulls-review-with-agent).Tests:
packages/guide-viewer/GuideView.test.tsx(box heights with the opt-in and unchanged without it; the Split estimate; the remount hold; the button row with a tab, without one, and outside bare mode).tests/e2e/inbox-guides.spec.tschecks the thread's box in Chromium.tests/e2e/inbox-pull-requests.spec.tschecks in Chromium that the 5-line file's last row ends within one row of its box, and that the button sits beside the switch without touching it.