From 5665bbf8271edead442dce81b7b1a6de48aea253 Mon Sep 17 00:00:00 2001 From: iris Date: Thu, 5 Nov 2026 12:35:32 +0100 Subject: [PATCH] swarm-ui: a maximize button on each pane of a terminal group opens that agent's own terminal --- docs/swarm/ui.md | 3 ++- .../swarm-ui/src/pages/agents/AgentGroupPage.tsx | 9 +++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/docs/swarm/ui.md b/docs/swarm/ui.md index 1038b511..61d30cc4 100644 --- a/docs/swarm/ui.md +++ b/docs/swarm/ui.md @@ -166,7 +166,8 @@ a group of the two, with its own header tab at `/agents/group/`. In a group, the same drag onto a pane splits that pane, as many times as you like, and dragging a pane's header badge onto another pane moves it there. The **split** button in a pane's header does the same for an agent whose terminal tab is open: -**right** or **below** puts it beside the pane. The **×** takes the pane's +**right** or **below** puts it beside the pane. **maximize** opens that +agent's own terminal in its tab, or goes to the tab when one is open already. The **×** takes the pane's agent out of the group, and a group left with one agent goes, landing on that agent's own terminal. Drag a divider to resize, or focus it and use the arrow keys. Panes have no minimum size; a divider stops at 2% so a pane can't diff --git a/frontend/packages/swarm-ui/src/pages/agents/AgentGroupPage.tsx b/frontend/packages/swarm-ui/src/pages/agents/AgentGroupPage.tsx index c0a3f871..c12dc8bb 100644 --- a/frontend/packages/swarm-ui/src/pages/agents/AgentGroupPage.tsx +++ b/frontend/packages/swarm-ui/src/pages/agents/AgentGroupPage.tsx @@ -10,6 +10,7 @@ import { useEffect } from "preact/hooks"; import { useLocation, type RouteComponentProps } from "wouter-preact"; import { Badge } from "@hive/shared/badge.js"; +import { ExpandIcon } from "@hive/shared/icons.js"; import { AgentIcon } from "../../agent/AgentIcon.js"; import { AgentTermPreview, @@ -158,6 +159,14 @@ export function AgentGroupPage({ groups.update(id, (r) => splitPane(r, agent, other, side)) } /> + } + value="maximize" + title={`open ${agent}'s terminal on its own`} + onClick={() => + open({ href: termPaths(agent).page, label: agent }) + } + />