Clip inline menu header to prevent split-pane overflow#10811
Conversation
|
I'm starting a first review of this pull request. You can view the conversation on Warp. I reviewed this pull request and requested human review from: Comment Powered by Oz |
There was a problem hiding this comment.
Overview
This PR updates two UI layout surfaces to keep cloud agent footer controls and inline menu header controls within narrow split-pane bounds by switching the V2 footer row to the existing wrap/fill pattern and clipping the inline menu header.
Concerns
- No blocking correctness concerns found.
- No security concerns found in the changed layout-only code.
Verdict
Found: 0 critical, 0 important, 0 suggestions
Approve
Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).
Powered by Oz
|
Hi @zachbai, could you please take a look at this? A small UI fix. |
|
@advait-m can you take a look? |
will do |
| // Clip so trailing controls don't paint past the pane in a narrow split pane. | ||
| Some(Clipped::new(header).finish()) |
There was a problem hiding this comment.
Thanks for adding the screen recordings here - this makes sense to me!
| .with_child(right.finish()) | ||
| .with_child(WrapFill::new(0., left.finish()).finish()) | ||
| .with_child(WrapFill::new(0., right.finish()).finish()) | ||
| .with_run_spacing(CLOUD_MODE_V2_FOOTER_GAP) |
There was a problem hiding this comment.
Could you add before/after recording for this (can be just 1 vid or 2)? I'm trying to figure out what the original issue was here
Let me know if I missed catching this in original videos
There was a problem hiding this comment.
@advait-m I have added both the videos in PR description. In the first video, observe the first pane, when I reduce the width, the pane items overflow into the next pane's UI.
That doesn't happen in the second video
There was a problem hiding this comment.
@SagarSDagdu CloudModeInputV2 feature flag is dogfood-only so this actually isn't live anywhere, could you revert this part of the PR
There was a problem hiding this comment.
ah wait, I think it might be enabled through cloud_mode FF indirectly
There was a problem hiding this comment.
You're right that CloudModeInputV2 is dogfood-only, so that footer change wasn't fixing anything live. I've dropped commit 73552289 (the Flex → Wrap change in render_cloud_mode_v2_footer) via rebase + force-push. The PR is now scoped to just the inline-menu Clipped change, which fixes the overflow shown in the image you attached (the /model menu header). I'll leave a note that the V2 footer needs the same treatment before that flag promotes.
The InlineMenuView body is already wrapped in `Clipped`, but the header row (label, tabs, drag indicator, "Manage defaults" trailing button) was rendered raw. In a narrow split pane the trailing controls painted past the pane boundary into the adjacent pane. Wrap the returned header in `Clipped` to match the body's clipping behavior. Refs warpdotdev#10724
a1b17a6 to
a6442c3
Compare

Description
InlineMenuView::render_headerinapp/src/terminal/input/inline_menu/view.rsreturned its header row unclipped, while the menu body below was already wrapped inClipped. In a narrow split pane the header's trailing controls (drag indicator + e.g. "Manage defaults" button for the/modelmenu) painted past the pane boundary into the adjacent pane.This PR wraps the returned header in
Clippedto match the body's behavior.InlineMenuViewis the shared inline menu used by/model,/commands, etc., so all of them benefit.Videos
Before
Screen.Recording.2026-05-13.at.7.36.59.PM.mov
After
Screen.Recording.2026-05-13.at.7.39.15.PM.mov
Linked Issue
Fixes #10724
ready-to-specorready-to-implement.Testing
./script/runReproduction:
/model(or any inline menu trigger) to open the inline menu.Before:
Manage defaultsand drag indicator extended past the divider into the adjacent pane.After: the menu header clips at the pane edge, matching the menu body which was already clipped.
cargo fmt --checkandcargo clippy -p warp --all-targets -- -D warningsboth clean.No integration test added — fix is a single
Clippedwrapper and is most cheaply verified by manual repro in a narrow split pane.Agent Mode