Skip to content

fix(web): close Run on picker after selecting a machine - #5

Draft
macodev00 wants to merge 1 commit into
mainfrom
cursor/close-env-picker-4beb
Draft

macodev00 wants to merge 1 commit into
mainfrom
cursor/close-env-picker-4beb

Conversation

@macodev00

Copy link
Copy Markdown
Owner

Fixes pingdotgg#12684.

What Changed

The combined Run on / Workspace menu (MobileRunContextSelector in apps/web/src/components/BranchToolbar.tsx) now passes closeOnClick on every radio row: Auto balance, each machine, Current checkout, New worktree, and previous worktree.

Why

Picking a machine already updated the composer pill, but the popover stayed open. Base UI MenuRadioItem defaults closeOnClick to false. This is the same class of bug as the traits/effort menu (pingdotgg#5879). Environment and workspace picks are single-choice actions, so the menu should dismiss after a click.

Wide-layout host/workspace controls are Selects and already close on pick. Desktop uses the same web renderer, so it is covered. Mobile uses a different picker.

UI Changes

Selecting a machine (or workspace mode) in the compact composer Run on menu now closes the popover. No visual redesign.

Checklist

  • This PR is small and focused
  • I explained what changed and why
  • I included before/after screenshots for any UI changes
  • I included a video for animation/interaction changes
Open in Web Open in Cursor 

Picking a machine in the combined Run on / Workspace menu applied the
change but left the popover open. Base UI radio items default closeOnClick
to false; pass closeOnClick so a pick dismisses the menu, matching the
model and traits pickers.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Environment picker ("Run on") stays open after selecting a machine

1 participant