Skip to content

cmux NEXT: chat tools sit in the tab row; one Browser button opens the chat's page - #22655

Merged
teamleaderleo merged 5 commits into
feat-cmux-nextfrom
cmux/pane-toolbar
Oct 21, 2026
Merged

teamleaderleo merged 5 commits into
feat-cmux-nextfrom
cmux/pane-toolbar

Conversation

@teamleaderleo

@teamleaderleo teamleaderleo commented Oct 20, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

In the current NEXT nightly, a chat's tools (Preview ▷, Terminal, Browser, Sources ☰, "…") sit in a second row under the pane's tab strip, inset to the transcript column, not at the pane's top right. Leo, 2026-10-20: "I thought we moved that all the way up to the top right." Two buttons also did nearly the same thing. ▷ (Preview) opened the chat's local page beside it, and the globe (Browser) opened a blank New Tab beside it. Clicking the globe while the chat was about localhost:5173 gave an empty browser ("something different was opening here").

Why this surface missed the move: lifting the tools into the tab row already exists (chrome.tabs.rowTools, header/tabRow.ts plus AgentPaneTabRow), but since 2026-10-14 it has been a Debug opt-in that is off by default, so the nightly never used it.

Change

  • Tools in the tab row by default. chrome.tabs.rowTools now defaults to on. A chat's tools sit at the right end of its pane's tab row, and the tabs make room. The Debug setting still turns it off. Nothing else changes: the row is offered only while the pane shows its tabs on top, and Quick Chat keeps its own header.

  • One Browser button. When the chat's last turns named a local page, Browser opens that page beside the chat. Its tooltip names it ("Preview localhost:5173"), and it lights while the page is open. Otherwise Browser opens a plain browser split, as before. A toggle click closes whichever one it opened. Preview is no longer a default button. It is still in the header's right-click menu, and anyone who shows it gets the separate Preview and a plain Browser back. A saved agent-pane/layout.json list is kept as is.

  • The preview card's Open in tab is unchanged on purpose. It already goes through the app-wide link rule (layout.linkPlacement, default: the pane on the right, or a new split there). The card's compact layout and "Load preview" are Agent chat: links read as plain text with secrets masked; local preview cards only behind a Debug toggle #22461's.

  • Debug toggles, both on by default:

    • chrome.tabs.rowTools (existing) puts the tools in the tab row.
    • agentChat.browserOpensPreview (new) makes Browser open the chat's page. Turning it off brings back Preview beside a plain Browser for anyone on the default buttons. It applies live through the header state push.

No new strings. The Browser tooltip reuses header.previewAddress.

Before / after

Nightly today (Leo's window, tab strip and tool row only): the tools are a second row under the tabs, inset to the transcript column. The lit globe opened the blank "New Tab" on the right, even though the chat was about a local page.

nightly before

Agent pane page, base fce753a vs this branch. Headless Chromium, the pane's dev entry, a stand-in acpmux daemon. The chat's last reply names http://localhost:5173/. The native tab strip is not in these captures: on head, it fills the empty left part of the top row. (The "Load preview" card under the header is #22461's.)

Base: a 44px row of its own with ▷ Preview, Terminal and Browser. A Browser click sends pane.action {id: "splitBrowserRight"}, which opens a blank browser.
base

Head (row offered, now the default): the tools sit in the 28px tab row at the pane's right end, and there is no separate ▷. Browser's tooltip reads "Preview localhost:5173", and a click sends pane.action {id: "preview", url: "http://localhost:5173/", mode: "toggle"}, which opens the page beside the chat.
head

Gallery entry agent-pane.header-tools, Linux Chromium (big-red), base vs head. The PR's gallery advisory run samples only the first 16 of 43 touched states, so it never reached this entry.

panels-open. Base: Changes, ▷ Preview (lit), Terminal and Browser (lit). Head: the globe alone holds the page; its tooltip reads "Preview localhost:5173".
gallery base panels open dark
gallery head panels open dark

New variant browser-preview (head, light):
gallery head browser preview light

Review (independent subagent)

  • Fixed: in tab-row mode, the header's status slot sits under the App's tabs and is hidden, so with the new default "Disconnected", "Reconnecting" and "Failed" showed nowhere. The warning now leads the tools in that mode, with its reason in the tooltip (ChatHeaderInlineStatus, test chat-header-inline-status).
  • Fixed: closing a lit preview from Browser now sends the page too, as Preview did. If the preview was already closed before the lit state caught up, the click reopens it instead of doing nothing.
  • Known, not new (already true while the setting was opt-in): in a narrow pane, the strip gives the tools at most half the row, so a very wide tool set (PR chip, Changes, Terminal, Browser, ☰, …) can slip under the last tab. The native remote-approval and other-install notices pin to the top of the agent view, so in row mode they start under the strip. These are follow-ups.
  • Intended: the Split Browser Right shortcut and the palette still open a plain browser. Only the header button opens the chat's page, so its tooltip shows no keycap.

Fleet build

cmux-ci job 8138173fc42fbfc0438445a0 succeeded on 46c921b998dd with --backend-mode local, because the shared dev-backend VM cmux-dev-backend-1 was unreachable over Tailscale (REPAIR.md row). That makes it compile and package evidence, not a dogfood build. cmux-ci compile-check --app passed on c7a0776acb0c, which includes the Debug toggle (job 1b93a3c23350a68c9fdee626).

Verification

  • test/chat-header-browser-preview.test.tsx (new), plus the default-list expectations in chat-header-fold and chat-header-customize. Commit 1 holds the tests only and is red on base. Commit 2 is the fix.
  • bun test test/chat-header-*.test.tsx test/chat-menu-*.test.tsx: 19 pass. chat-header-tooltips and chat-header-pull-request-status fail only when the files run together, and they fail the same way on base fce753a089e5. Each passes on its own.
  • vp check on the changed files: clean.
  • agent-pane-tab-row.test.ts (Playwright, CI browser lane) covers the row mode that is now the default.

Agent session: cosmic-gray

🤖 Generated with Claude Code

teamleaderleo and others added 2 commits October 20, 2026 16:39
…view is off by default

Fails on base: Browser opens a blank split while the chat names a local page, and
the default buttons still include a separate Preview.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?harness=claude&session=01a15ba2-4ce2-7e02-8fa2-5cd34f7648b1&host=cosmic-gray
…at's page

- chrome.tabs.rowTools defaults on: a chat's header tools sit at the right end of
  its pane's tab row, not in a second row under the tabs.
- Browser opens the chat's local page beside the chat when its last turns named
  one (tooltip: Preview <address>), else a plain browser split; a toggle click
  closes whichever it opened. Preview is no longer a default button (still
  available from the header's right-click menu).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?harness=claude&session=01a15ba2-4ce2-7e02-8fa2-5cd34f7648b1&host=cosmic-gray
@github-actions

github-actions Bot commented Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

cmux status (one comment, edited in place; each line is updated by the job that owns it)

Review c7a0776: HQ feed card · gallery before/after runs · checks

App of this head (app.zip, kept 1 day)

gh workflow run reload-build.yml -R manaflow-ai/cmux --ref feat-cmux-next -f tag=pr22655 -f ref=cmux/pane-toolbar -f platform=macos -f backend_mode=local

Probably yours: composer-send-stop.test.ts fails here but not on main's latest full suite. Seen on other PRs too (likely flaky): agent-pane-math.test.tsx, menu-focus.test.ts, gallery-coverage.test.ts and 7 more.

CI failed on c7a0776acb (run 39518650815 attempt 1): 3 code, 2 unknown.
macOS jobs did not run: compile and app tests were skipped: Fast static checks skipped.

Job Verdict Why
web / react-apps-check (2) code a web test failed
web / react-apps-check (3) code a web test failed
web / react-apps-check (1) unknown no known signature; failed step: Test webviews
web / react-apps-check (4) code a web test failed
web / react-apps-check unknown no known signature; failed step: Check webview test shards

Failures:

  • seen on other PRs agent-pane-math.test.tsx each delimiter typesets once math appears: failed (job)
  • seen on other PRs menu-focus.test.ts (unnamed): failed (job)
  • seen on other PRs gallery-coverage.test.ts gallery coverage > every component and page has an entry or an allowlist line: failed (job)
  • seen on other PRs categories.test.ts every page row has exactly one home: failed (job)
  • seen on other PRs agent-pane-background-tasks.test.ts clicking a background task's end opens its terminal beside the chat: failed (job)
  • seen on other PRs agent-pane-question-records.test.ts answered live, the card goes and the record takes its place: failed (job)
  • new in this PR composer-send-stop.test.ts stops a running turn and restores Send after the host snapshot: failed (job)
  • seen on other PRs new-tab-composer-still.test.ts chromium: the default page's composer stays put in a 900px window: failed (job)
  • seen on other PRs new-tab-composer-still.test.ts webkit: the default page's composer stays put in a 900px window: failed (job)
  • seen on other PRs new-tab-composer-still.test.ts chromium: the default page's composer stays put in a 560px window: failed (job)
  • ... 1 more in the job logs
Matched log lines
web / react-apps-check (2): (fail) each delimiter typesets once math appears [66.90ms]
web / react-apps-check (3): (fail) gallery coverage > every component and page has an entry or an allowlist line [0.50ms]
web / react-apps-check (4): (fail) every page row has exactly one home [0.81ms]

Not re-run automatically: web / react-apps-check (2), web / react-apps-check (3), web / react-apps-check (1), web / react-apps-check (4), web / react-apps-check are not machine failures.

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; yours means the failing file is one this PR changes, also red on main that main's latest full suite fails the same way, seen on other PRs that it failed on another pull request's run lately.

red: web / Web status; NEW: green on the base afffd40; do not merge until green; see lane-rules
red: web / react-apps-check; no finished base run on afffd40 to compare; do not merge until green; see lane-rules
red: web / react-apps-check (1); no finished base run on afffd40 to compare; do not merge until green; see lane-rules
red: web / react-apps-check (2); no finished base run on afffd40 to compare; do not merge until green; see lane-rules
red: web / react-apps-check (3); no finished base run on afffd40 to compare; do not merge until green; see lane-rules
red: web / react-apps-check (4); no finished base run on afffd40 to compare; do not merge until green; see lane-rules

CI fast guards failed on c7a0776acb (https://github.com/manaflow-ai/cmux/actions/runs/39518650815). It does not block the merge; a red guard merged into main breaks it for every open PR.
The log named no failed step; see the run.

Agents: python3 scripts/ci/guard_attribution.py fix applies the mechanical fixes locally.

@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Bead cx-ldo4s created for this PR by the cmux coordinator.

@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

cmux-next guards / defaults-snapshot is red on 20 of 20 fresh feat-cmux-next PR heads in the last 2:00:00, so it is most likely a base red, not this PR's. The base-reds lane has it; a base merge picks up the fix once it lands.

Review of #22655: with the tools in the tab row by default, the header's status slot sits
under the App's tabs and is hidden, so Disconnected/Reconnecting/Failed showed nowhere.
The warning now leads the tools in that mode (its width is part of what the tabs make
room for). Browser also sends the page when it closes a lit preview, as the Preview
button did, so a stale lit state reopens the page instead of doing nothing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?harness=claude&session=01a15ba2-4ce2-7e02-8fa2-5cd34f7648b1&host=cosmic-gray
@teamleaderleo teamleaderleo added the ready-to-land Reviewed at this head; next-autoland merges it into feat-cmux-next when its only reds are base reds label Oct 20, 2026
@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Independent subagent review: two passes, clean after 2ec99a1 (it fixed the hidden connection warning in tab-row mode and the stale-preview click). Remaining red: cmux-next guards / defaults-snapshot, which fails the same way on the base tip 2a63003 (CmuxNextSettings exports stale; this PR touches no settings source). Labeled ready-to-land.

Agent session: cosmic-gray

…be header

The best default ships on (Browser opens the chat's page; no separate Preview button), and
Debug Settings can turn it off for the old pair, live, through the header state push, so the
team can compare without another PR and build.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?harness=claude&session=01a15ba2-4ce2-7e02-8fa2-5cd34f7648b1&host=cosmic-gray
@blacksmith-sh

blacksmith-sh Bot commented Oct 21, 2026 •

Copy link
Copy Markdown

Found 16 test failures on Blacksmith runners:

Failures

Test View Logs
src/pages/settings/categories.test.ts/categories.test View Logs
src/pages/settings/categories.test.ts/categories.test View Logs
test/agent-pane-background-tasks.test.ts/agent-pane-background-tasks.test View Logs
test/agent-pane-background-tasks.test.ts/agent-pane-background-tasks.test View Logs
test/agent-pane-math.test.tsx/agent-pane-math.test.tsx View Logs
test/agent-pane-math.test.tsx/agent-pane-math.test.tsx View Logs
test/agent-pane-question-records.test.ts/agent-pane-question-records.test View Logs
test/agent-pane-question-records.test.ts/agent-pane-question-records.test View Logs
test/composer-send-stop.test.ts/composer-send-stop.test View Logs
test/composer-send-stop.test.ts/composer-send-stop.test View Logs

...and 6 more test failures. View all on Blacksmith

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

@teamleaderleo
teamleaderleo merged commit 8eafafa into feat-cmux-next Oct 21, 2026
@teamleaderleo
teamleaderleo deleted the cmux/pane-toolbar branch October 21, 2026 00:40
teamleaderleo added a commit that referenced this pull request Oct 21, 2026
…state (#22726)

Fixes gallery-coverage on #22655: the new component had no entry. agent-pane.header gets a
tab-row-disconnected variant that offers the row and shows the warning leading the tools.


Agent-Session: https://cmux.com/deeplink/agent?harness=claude&session=01a15ba2-4ce2-7e02-8fa2-5cd34f7648b1&host=cosmic-gray

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

Shipped in:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-to-land Reviewed at this head; next-autoland merges it into feat-cmux-next when its only reds are base reds

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant