Fix workspace tab focus from route open intent

This commit is contained in:
Mohamed Boudra
2026-03-06 16:18:19 +07:00
parent 885b575d14
commit 74c99a827d
10 changed files with 318 additions and 34 deletions
@@ -576,8 +576,18 @@ function WorkspaceScreenContent({
tabs: uiTabs,
tabOrder,
focusedTabId,
preferredTarget:
openIntent?.kind === "agent"
? { kind: "agent", agentId: openIntent.agentId }
: openIntent?.kind === "terminal"
? { kind: "terminal", terminalId: openIntent.terminalId }
: openIntent?.kind === "draft"
? { kind: "draft", draftId: openIntent.draftId }
: openIntent?.kind === "file"
? { kind: "file", path: openIntent.path }
: null,
}),
[focusedTabId, tabOrder, terminals, uiTabs, workspaceAgents]
[focusedTabId, openIntent, tabOrder, terminals, uiTabs, workspaceAgents]
);
const activeTabId = tabModel.activeTabId;