Skip to content

feat(next): route agent beside opens through right pane - #26603

Open
teamleaderleo wants to merge 5 commits into
open-rightfrom
open-right-a2
Open

teamleaderleo wants to merge 5 commits into
open-rightfrom
open-right-a2

Conversation

@teamleaderleo

Copy link
Copy Markdown
Collaborator

Stacked on #26582 (A1). This routes real agent beside callers through the shared right-column decision path.

Leo said: "leo view changes is still bad / it should open to the right" and clarified that documents should use the top-right area while the first session gets a bottom split, with later sessions staying in the matching area.

Changes:

  • wires AgentTabStore with a workspace-local right-pane lookup backed by LinkOpener;
  • makes header and Session Info document opens reuse the existing right pane and its active-tab order;
  • makes subagent opens use the right pane for the first session, split below it once, then reuse the bottom session area for later subagents;
  • keeps the existing new-right-column path when no right pane exists and never crosses workspace/window boundaries.

Validation: git diff --check. Swift compilation is delegated to the managed PR CI route (Swift is unavailable on this Linux host). Real-app before/after capture remains part of the parent capture pass.

Related: #26093, #25721

agent-identity footer --repo manaflow-ai/cmux

@cursor

cursor Bot commented Oct 28, 2026

Copy link
Copy Markdown

Bugbot needs on-demand usage enabled

Bugbot uses usage-based billing for this team and requires on-demand usage to be enabled.

A team admin can enable on-demand usage in the Cursor dashboard.

@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Review (codex gpt-6-astra high, independent): BLOCK at 0db5494

  • Handlers/TabLifecycle.swift:262-264, Links/LinkOpener.swift:191-196: selectExistingWeb runs for agent besideCaller requests too and unconditionally focuses the existing tab. A background agent open of an already-open URL steals focus from the chat, bypassing allowsViewChange and the placement callback.
  • Handlers/AgentBesidePlacement.swift:63-68: the existing-right-pane path selects the new tab without the existing focus-generation/person-action guard. If the user focuses another pane while the move is pending, completion still steals focus back.

@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Interaction with #28989 (carry of #28044, landing today): agent beside opens (subagents, side chats, Session Info) now go through AgentTabStore.openOnRight and RightColumnPlacement: split right, then one split below, then tabs in the lower pane, serialized per source pane by RightColumnTurns. This PR's RightPanePlacement routing of the same callers conflicts with it in AgentTabs+Header.swift, AgentTabs.swift and LinkOpener.swift. A rebase should adopt RightColumnPlacement rather than reintroduce a second decision path.

This branch was previously deployed

1 inactive deployment
ci-routing-agent — 0db54947 Deployed Oct 28, 2026 by teamleaderleo via wait for same-key tree publisher #69067
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.

1 participant