Skip to content

Fix narrow pane tab close UX - #15957

Merged
teamleaderleo merged 49 commits into
mainfrom
fix/pane-tab-close
Sep 30, 2026
Merged

teamleaderleo merged 49 commits into
mainfrom
fix/pane-tab-close

Conversation

@teamleaderleo

@teamleaderleo teamleaderleo commented Sep 30, 2026 •

Copy link
Copy Markdown
Collaborator

What changed

Narrow pane tab bars now keep tabs readable and closable:

  • Every tab keeps a minimum width and shows its x on hover, with the selected-tab affordance preserved.
  • Middle-click routes through the same explicit close path as the x button, including active-command and agent-session warnings.
  • Right-click includes Close Tab and Close Other Tabs.
  • Below 520 px, the trailing action cluster collapses to one overflow menu so tab space wins and repeated actions are deduplicated.
  • Added regression coverage for middle-click warning routing and narrow action-lane layout.

Verification

  • python3 scripts/verify-local.py: 16/16 selected checks passed.
  • ./scripts/sync-test-wiring --check: passed.
  • python3 scripts/localization_catalog.py check: 10 catalogs, 9 locales, 0 parity errors.
  • swift test --filter TabBarLayoutFeedbackTests in the Bonsplit submodule: 5 tests passed.
  • Fleet app build and dogfood for feature SHA 01c216216d5fd480d6f7bb60906581eee4846fa7 ran on the managed fleet (tag pr-15957-pane-tab-close-v18). The selected XCUITest passed every tour step; the wrapper was marked failed only because its app-host socket-listener evidence check did not recognize the successful test host output.
  • The branch was then caught up with current upstream/main and the Bonsplit pointer was merged forward. Additional current-head fleet submissions hit worker volume cleanup or disk-image attach infrastructure failures before compilation.

Media

Before:

Before: narrow pane action cluster

After: narrow-pane tab bar with a persistent minimum tab width, hover close affordance, and collapsed actions:

After: tab close demo

After: tab bar

After: tab context menu

The fleet dogfood run was 36757777040; its selected UI test passed, with only the wrapper evidence check failing. The merged PR head after catch-up is aa99953d93f3ebc534c214769fb8d14f6276e077.

Changelog

Fixed: Narrow pane tabs retain hover close, middle-click close warnings, context-menu close, and an overflow action menu.


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.


Summary by cubic

Fixes tab closing across narrow panes and closes a safety gap where a close that would kill a live foreground process could be confirmed or silently executed without an explicit opt-in.

Tab close UX

  • Narrow pane tab bars keep a minimum tab width; the x button appears on hover.
  • Middle-click routes through the same guarded close path as the x button, wired consistently across Workspace, DockSplitStore, and the remote tmux mirror.
  • The tab context menu adds Close Tab and Close Other Tabs, both honoring allowCloseTabs close permissions and pinned-tab restrictions.
  • Below 520 px, trailing actions collapse into one overflow menu.

Active-process close guard

  • Non-forced closes that would terminate a live process now return an error instead of silently killing it.
  • surface.close, workspace.close, window.close, tab.action, the mobile workspace list, and the legacy v1 commands accept force to bypass the confirmation.
  • The safety warning can't be silenced by "Don't ask again" — only user-preference warnings are.
  • Added regression coverage for middle-click warning routing, force forwarding, disabled close via context menu, and confirmation responses.

Written for commit aa99953. Summary will update on new commits.

Review in cubic

Summary by CodeRabbit

  • New Features
    • Added --force to close commands for windows, workspaces, tabs, and surfaces. Without it, closing items with active processes prompts for confirmation and explains how to retry.
    • Added middle-click tab closing, with confirmation when a tab has an active process.
  • Bug Fixes
    • Tab context-menu close actions now respect close permissions and pinned-tab restrictions.
    • Safety confirmations remain in effect even when other close warnings are disabled.

teamleaderleo and others added 30 commits September 24, 2026 07:07
GitHub only dispatches workflows that exist on the default branch; the
content that runs comes from the dispatched ref.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Catch-up merge by scripts/ci/catch_up_pr.py (RFC #14631).
Merged by scripts/merge-main.sh: mf/main at 7051bb5.

Resolved conflicts:
- Resources/Localizable.xcstrings: xcstrings key-level union

Catch-up-previous-head: e7d76d2
Catch-up-base: 7051bb5
Catch-up merge by scripts/ci/catch_up_pr.py (RFC #14631).
Merged by scripts/merge-main.sh: mf/main at 40138c6.

Resolved conflicts:
- Resources/Localizable.xcstrings: xcstrings key-level union

Catch-up-previous-head: 8430f3a
Catch-up-base: 40138c6
Catch-up merge by scripts/ci/catch_up_pr.py (RFC #14631).
Merged by scripts/merge-main.sh: mf/main at 8265e78.

Resolved conflicts:
- Resources/Localizable.xcstrings: xcstrings key-level union

Catch-up-previous-head: 0728468
Catch-up-base: 8265e78
@coderabbitai

coderabbitai Bot commented Sep 30, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

Note

Currently processing new changes in this PR. This may take a few minutes, please wait...

⚙️ Run configuration

Configuration used: Repository: manaflow-ai/cmux/.coderabbit.yaml

Review profile: ASSERTIVE

Plan: Advanced

Run ID: 25dea5ff-5ec7-497f-a0a3-1f2db57fc32e

📥 Commits

Reviewing files that changed from the base of the PR and between 6171d8c and aa99953.

📒 Files selected for processing (8)
  • Packages/macOS/CmuxAppKitSupportUI/Tests/CmuxAppKitSupportUITests/MiddleClickCaptureViewTests.swift
  • Resources/Localizable.xcstrings
  • Sources/DockSplitStore+TabContextActions.swift
  • Sources/DockSplitStore.swift
  • Sources/RemoteTmuxWindowMirror+Bonsplit.swift
  • Sources/Workspace.swift
  • cmuxTests/WorkspaceCloseTabsContextMenuTests.swift
  • vendor/bonsplit
 _____________________________
< The Da Vinci Code Reviewer. >
 -----------------------------
  \
   \   \
        \ /\
        ( )
      .( o ).
✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Autopilot is currently an internal CodeRabbit preview.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown
Contributor

All contributors have signed the CLA ✍️ ✅
Posted by the CLA Assistant Lite bot.

@teamleaderleo teamleaderleo added the dev-build Build a fleet dogfood build of each push (newest head under load) label Sep 30, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Automatic catch-up couldn't merge main (6d7ad149121a): vendor/bonsplit (both sides changed it). Nothing was pushed; merge it by hand. A new push or /catch-up tries again.

Label no-auto-catch-up to opt out · Catch-up run

@github-actions

github-actions Bot commented Sep 30, 2026 •

Copy link
Copy Markdown
Contributor

Dogfood build of aa99953d93f3ebc534c214769fb8d14f6276e077

cmux DEV pr-15957-aa99953d.app

The link opens this exact commit in the cmux dev menu bar app; the page waits until the build is ready. Builds run only while this PR has the dev-build label. Under load the fleet builds the newest push each time a worker frees up, so some pushes are skipped. It signs in against production, so Cloud or backend changes still need a tagged build with a development backend.

Covers 58d1509d..aa99953d (commits: 32) since the previous link, cmux DEV pr-15957-58d1509d.app; if that push was skipped, its page names the newer build. To build a commit in between: cmux-ci build cmux --ref <sha> --tag bisect-<sha8> --workspace https://github.com/manaflow-ai/cmux/pull/15957.

@github-actions

github-actions Bot commented Sep 30, 2026 •

Copy link
Copy Markdown
Contributor

CI failure attribution

CI stopped on 01c216216d (run 36753490274 attempt 2): 1 code.

Job Verdict Why
macos / swift-package-tests code a test failed
Matched log lines
macos / swift-package-tests: /Users/cmux/actions-runner-glaeda-1/_work/cmux/cmux/vendor/bonsplit/Tests/BonsplitTests/BonsplitTests.swift:3590: error: -[BonsplitTests.BonsplitTests testSelectedTabIndicatorFadesWithTabContentBeforeSplitButtonBackdrop] : XCTAssertLessThan failed: ("1.0") is not less than ("0.9") - The indicator sh

Not re-run automatically: macos / swift-package-tests is not a machine failure.

Written by scripts/ci/classify_failures.py (ci-failure-attribution.yml); signatures are its SIGNATURES table. A machine verdict is the runner's fault, not this PR's.

@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Review: Fresh subagent review of 01c2162 with Bonsplit 1b673629f300e3ec0b13fe5cef53f299bcabeaf5 found no concrete findings. It verified the shared MiddleClickCapture injection, close-setting and pinned-tab guards, narrow overflow layout, and warning routing.
Fixed: Context-menu Close Tab now respects allowCloseTabs and pinned tabs; middle-click uses the shared press-time capture view and follows the x-button warning path; narrow panes reserve no hidden action lane; the Bonsplit pointer is forward-compatible with main.
Left: Fleet app build and exact-SHA dogfood are still pending; native compilation and UI tests remain fleet-owned.

Merge-main commit by scripts/merge-main.sh.
Merged by scripts/merge-main.sh: origin/main at 57fd5ac, the newest commit with green CI fast guards (21 newer skipped).

Resolved conflicts:
- Resources/Localizable.xcstrings: xcstrings key-level union

Merge-main-previous-head: 01c2162
Merge-main-base: 57fd5ac
@cursor

cursor Bot commented Sep 30, 2026

Copy link
Copy Markdown

Bugbot is paused — on-demand spend limit reached

Bugbot uses usage-based billing for this team and has hit its on-demand spend limit.

A team admin can raise the spend limit in the Cursor dashboard, or wait for the next billing cycle to continue.

@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Review: Latest subagent review of 58d1509 found no concrete pane-tab-close regressions or Bonsplit conflicts.
Fixed: No new fixes needed after the current-main catch-up merge; the shared MiddleClickCapture path, close warning routing, context gating, 48pt minimum tab width, 520pt narrow threshold, and 36pt overflow lane remain intact.
Left: Fleet CI and current-head dogfood evidence.

@teamleaderleo
teamleaderleo enabled auto-merge (squash) September 30, 2026 19:46
@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

recheck

@teamleaderleo
teamleaderleo merged commit 6e997e2 into main Sep 30, 2026
48 of 51 checks passed
@teamleaderleo
teamleaderleo deleted the fix/pane-tab-close branch September 30, 2026 20:18
@github-actions

Copy link
Copy Markdown
Contributor

Merge receipt for aa99953d93, merged 2026-09-30 20:18:20 UTC

  • Not verified at merge: ci-status (not reported), macOS compile admission (in progress), CI fast guards (in progress), GhosttyKit release check (in progress), guards (18) (in progress), package-conventions-lint (in progress), swift-package-tests (in progress)
  • Verified: catalog-structure, detect-ios-changes, Dogfood build #​15957, Fast static checks, runner, Testbox broker trust boundary, Web complexity, web-validation
  • Skipped by policy: admission-placement, browser, Claude wrapper regressions, full-suite-coverage, remote-daemon, suite-coverage, web, web-build, web-database-tests, web-tests
  • Full suite: runs on main after merge.

Labeled merged-unverified: if main breaks near this merge, look here first.

@github-actions github-actions Bot added the merged-unverified A judging check was not green at merge; see the merge receipt comment label Sep 30, 2026
rustybret pushed a commit to rustybret/bmux that referenced this pull request Sep 30, 2026
5e83d80 Keep agent mode controls reachable and respect disabled choices (manaflow-ai#15971)
24f1ee0 fix(codex): arm the transcript monitor's watch before it reads (manaflow-ai#15913)
17f370e fix: pass the action reference for untrusted setting tab-bar buttons (manaflow-ai#16223)
5e33b84 Agent messages that never land in a human's draft: cmux agent message (manaflow-ai#15279)
522ba05 fix(sidebar): replay agent runtime changes for late observers (manaflow-ai#15829)
3016cf3 Fix browser state helper package convention (manaflow-ai#16205)
b1fd787 Preserve agent Stop completion before session teardown (manaflow-ai#16122)
7ba9740 Prevent duplicate pool VMs after lost create responses (manaflow-ai#15946)
e6e6982 Keep Cloud agent chat recoverable when browser storage fails (manaflow-ai#15968)
d8f62dc fix(ci): production-secret jobs run only from protected refs (manaflow-ai#16171)
8aa9b5c fix(agents): isolate OpenCode workspace auto-naming (manaflow-ai#16210)
7bce471 Add cmux agent hibernate and wake (manaflow-ai#15308)
90d2fb9 fix(agent-chat): surface a rejected send on the transcript branch (manaflow-ai#16216)
d01e8ce fix: list setting actions in Actions discovery so main compiles (manaflow-ai#16222)
b3ca418 Serialize Pi Agent Chat startup before prompts (manaflow-ai#16121)
75650a8 fix: end CodeRouter sessions on team removal; fresh auth for presence mutations (manaflow-ai#16169)
1831681 fix(web): refuse to publish the Cloud VM daemon port (manaflow-ai#16144)
258c2ee Let remote workspaces use cmux agent message through the SSH relay (manaflow-ai#15863)
3b196d0 Merge pull request manaflow-ai#16160 from manaflow-ai/ci/failfast
f02bdec Fix browser state restoration ordering (manaflow-ai#16204)
2fdf7d0 fix(coderouter): pin the OpenCode provider address per request (manaflow-ai#16165)
aaebb18 Fix Cmd+I notifications popover anchor (manaflow-ai#14582)
ef3e658 Preserve valid Claude hook sessions after decode drift (manaflow-ai#16196)
a0660ce test: avoid fixed cancellation delay
6e997e2 Fix narrow pane tab close UX (manaflow-ai#15957)
a018381 ci: run process tree regression in guard preflight
723bbe6 fix(ci): bound artifact fallback at workflow call sites
7cbc73e test: require caller bounded artifact downloads
6120003 fix(ci): retain artifact download action
c801205 test: keep artifact fallback action wired
c1f0509 docs: record overstay evidence and bounded transfers
e91d51b fix(ci): bound artifact download fallback
a2679ce test(ci): require bounded artifact fallback transfer
ef447e2 ci: bound process tree reaping after kill
8f342fc test: bound process tree reaping
5d7af99 test: update cancellation guard expectations
984bf0c Merge remote-tracking branch 'mf/main' into ci/failfast
2c47268 Merge commit '57fd5ac4df7641c05eb73df76fe3554a2a604264' into ci/failfast
83998ac ci: skip cancelled iOS status rollup
bd5692e ci: stop leaking cancelled test processes
55a1003 ci: reap detached processes on cancellation
0351680 test: bound cancellation cleanup for stubborn CI children
bfe79f1 test: cover CI cancellation process cleanup
f20c7d3 ci: cancel useless downstream work
fd0a123 test: require job-scoped CI fail-fast cancellation

# Conflicts:
#	.github/workflows/ci-guards.yml
#	.github/workflows/ci-macos.yml
#	.github/workflows/ci-web.yml
#	.github/workflows/ci.yml
#	.github/workflows/cmux-tui-artifacts.yml
#	.github/workflows/ios-app-store.yml
#	.github/workflows/ios-appstore-upload.yml
#	.github/workflows/ios-testflight.yml
#	.github/workflows/iroh-release-gate.yml
#	.github/workflows/nightly.yml
#	.github/workflows/release.yml
#	.github/workflows/repair-nightly-appcast-content-types.yml
#	.github/workflows/repair-v0-64-25-helper-rpaths.yml
#	.github/workflows/test-e2e.yml
#	.github/workflows/test-ios.yml
#	.github/workflows/update-homebrew.yml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dev-build Build a fleet dogfood build of each push (newest head under load) merged-unverified A judging check was not green at merge; see the merge receipt comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant