Repository navigation
feat(chat): offer split down from the single-session view - #29558
Conversation
Design Review (Opus 5.5) — ✅ PASSDesign-level review of Design-Verdict: PASS Nothing blocks: the change fixes the root cause, which was the first split's direction being hard-coded in [DESIGN-REVIEWED] 0c8b78f Description read[DESCRIPTION-READ] fb403bbce5f5d96dac65727c6e438f4c989615f8897ccebe9ac8dd5931231fc3 That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with |
First Principles Review (Opus 5.5) — ✅ PASSPremise-level review of First-Principles-Verdict: PASS Nothing blocks. The new rows are optional entry points next to the existing default. The button, Cmd/Ctrl+D and the default seed direction are unchanged, so this does not change what users get without choosing. What this change shipsInventory (6 items) — 6 justifiedIntent: a user opens split view with the new pane stacked below the current session in one step, not three (#18880). ADDITION.
[FIRST-PRINCIPLES-REVIEWED] 0c8b78f Description read[DESCRIPTION-READ] b02c35f294010b561d6f53413be98154394647e70b669c86479874b934e4f9c5 That sha256 names the PR description this verdict read. Recompute it with |
UX Review (Opus 5.5) — ✅ PASSUX-level review of UX-Verdict: PASS Nothing blocks: the screenshots show every added row and the stacked state, and the blind reader read "Split down" correctly and said they would use it. Notes
[UX-REVIEWED] 0c8b78f Description read[DESCRIPTION-READ] d751412ddd6ee257362c1383dda492ab5eb6faaea40aed81c6b5008b2e749926 That sha256 names everything this verdict read: the PR description, plus the 7 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with |
Opus 5.5 Review — ✅ no blocking findingsReviewed Verdict parsed from the review's SHA-scoped output markers for commit False positive or not applicable? A repository writer can comment: |
GPT 6.1 Review — ✅ no blocking findingsGPT 6.1 completed its review of This comment is updated in place on each push. Review detailsNo findings. False positive or not applicable? A repository writer can comment: |
Entering split view always put the new pane to the right of the session. A stacked layout took three steps: split right, split down, then close the right pane, because the Split down control lives only on the panes of a view that is already split. Give the entry path a direction. useSessionGrid.seedFromSession takes an optional SplitDir and maps it to the split axis the way splitLeaf does. enterSplit in usePaneLayoutState takes the same optional direction, keeps it in state and hands it to SessionGridView as seedDir. Every entry sets it, so a down entry never carries into the next default one. Offer it as a Split down row in the session menu behind the title chevron, right after Pop out to window, and as a Split down row under Enter split view in the phone More menu. The rows reuse the pane controls' existing "Split down" string, so no new locale keys. The header buttons are unchanged: the split view button, its tooltip, its label and Cmd/Ctrl+D still open side by side. That header group already holds three buttons, so a fourth would break the max-two-buttons-per-row rule. A restored layout still wins over the seed. Closes #18880 Co-authored-by: Javen Cinocca <129346815+javenciu@users.noreply.github.com>
|
🤖 Kiro Crew Auto-Pipeline [operator: buluoray#ce473fca]:
|
8a18bdf to
0c8b78f
Compare
bolichen97
left a comment
There was a problem hiding this comment.
Approving 0c8b78f. I read every non-locale hunk: SessionActionsMenu.tsx, SessionGridView.tsx, useSessionGrid.ts, ChatPage.tsx, ChatHeaderMenu.tsx, ChatTitleOverlay.tsx, MobileTopBar.tsx, paneLayout.tsx and the screenshot harness.
enterSplittakes an optionaldir(default'right') and stores it insplitSeedDir.seedFromSessionmaps'down'to arowsplit, so only a fresh seed changes; a saved layout still restores as before.- Every
enterSplitcall sets the direction, so a Split down entry never carries into the next entry. - Desktop: the row goes in the new
layoutSlotright after the pop-out rows, so no existing row moves. It is offered only when split view is on, not embedded, and the session is not a member of another saved split. - Phone: the row sits under Enter split view and only in the single-session view, where the seed is not spent yet.
- The header split button and its side-by-side default are unchanged.
No new regex outside tests. All checks pass on this head (96 ok, 0 red, 0 pending), readiness is passed, and no human has an open change request. Auto-merge was already enabled by the author, so I left it as is.
Problem / Motivation
Goal: Let a user open split view with the new pane below the current session, straight from the single-session view.
Today the split view button and Cmd/Ctrl+D always put the first new pane to the right. The Split down control exists only on the panes of a view that is already split, so a stacked layout takes three steps: split right, split down, then close the right pane.
Why it matters
A stacked layout suits a wide, short window and sessions with long lines. Users who want it pay three clicks and a throwaway pane every time.
Not a goal
What changed (motivation → approach → change)
Root cause:
useSessionGrid.seedFromSessionhard-codes the first split todir: 'col', andenterSplit(anchor)inpaneLayout.tsxhas no direction argument, so the entry path can only seed side by side. The grid itself already supports stacked splits (splitLeaf(id, 'down')builds arowsplit).Change:
seedFromSession(slot, dir = 'right')mapsdirto the split axis the waysplitLeafdoes. The no-slot path is unchanged.enterSplit(anchor, dir = 'right')stores the direction andChatPagepasses it toSessionGridViewasseedDir. Every entry sets it, so a Split down entry never carries into the next default entry (Cmd/Ctrl+D, the button, the auto re-enter).SessionActionsMenutakes it as an optionallayoutSlot, so no row above it moves. It is a menu row, not a header button, because that header group already holds three buttons (pop out, activity panel, split view) andmax-two-buttons-per-rowforbids a fourth.components.chatPane.split_downstring, so there are no new locale keys.website/scripts/capture-18880-split-down.mjsdrives the built SPA on desktop and phone, asserts the menu order and the resulting layout, and writes the four frames below.This builds on the closed #20040 by @javenciu (credited with a Co-authored-by trailer). Unlike that PR, the phone's default row keeps its current "Enter split view" label.
Backwards compatibility
Compatible: the new
dir/seedDirparameters are optional and default to'right', so every existing caller seeds exactly as before.Removes nothing: the change only adds two menu rows and an optional parameter.
Tests
UseSessionGridCoverage.test.tsx› "stacks the fresh placeholder below the current session when seeded down":seedFromSession(slot, 'down')gives arowsplit of [session, placeholder] with the placeholder focused. "seeds side by side when the direction is right or omitted" pins the default.ChatPageMoreCoverage.test.tsx› "ChatPage split view entry direction": the menu row seedsdownwith no Split right row beside it, and the next header-button entry seedsrightagain; no Split down row when split is off.SessionActionsMenu.popout.test.tsx› "ChatHeaderMenu split down row": Split down sits right after Pop out to window, there is no Split right row, and every row above it keeps its place.ChatPage.mobileTopBarActions.test.tsx› "enters split view with the new pane below"; "offers no Split down row while split view is already open"; no row in a saved split or with split off; the existing Enter split view row still callsenterSplit('slot-a').SessionGridViewCoverage.test.tsx:seedDirreachesseedFromSession.Mutation checks (each run alone, file restored after): forcing
seedFromSessionto always'col'fails "stacks the fresh placeholder below the current session when seeded down"; makingenterSplitignoredirfails "seeds the first split below from the session menu, and the next button entry beside"; dropping the!splitModegate on the phone row fails "offers no Split down row while split view is already open".Proof: not provable -- frontend test (prove.py runs Python only)
npx tsc -bis clean. The five test files above pass: 219 tests.Manual verification
Ran
node scripts/capture-18880-split-down.mjsagainst a freshvite build. On each device a control run through the default entry (the header button on desktop, Enter split view on the phone) lands side by side, and the Split down run lands stacked. All assertions passed.Screenshots / video
Desktop, session menu open: Split down right after Pop out to window.
Phone, More menu open: Split down under Enter split view.
After choosing Split down
Related Issues
Closes #18880
Checklist
feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)Contribution License Agreement
Contributions are accepted under the project's Apache-2.0 license; see the Licensing section of CONTRIBUTING.md.