diff --git a/frontend/packages/swarm-ui/src/pages/agents/AgentTermPreview.css b/frontend/packages/swarm-ui/src/pages/agents/AgentTermPreview.css index c6ea8838..396efc59 100644 --- a/frontend/packages/swarm-ui/src/pages/agents/AgentTermPreview.css +++ b/frontend/packages/swarm-ui/src/pages/agents/AgentTermPreview.css @@ -8,16 +8,11 @@ margin-block-start: 1rem; } -/* Holds the connection-status badge + (unless `fullHeight`) the - expand-to-fullscreen trigger — `margin-left: auto` targets the expand - trigger by its OWN class, not `:last-child` (tried that first; it - silently broke when `fullHeight` hides the expand trigger, since the - status badge then becomes the `:last-child` too and gets pushed to - the right edge instead of staying flush left — caught by actually - rendering the `fullHeight` case, not just reasoning about the CSS). - Same split-row intent `Shell.css`'s `.shell-header-actions` already - uses for its own pair of triggers, just addressed directly instead of - positionally. */ +/* Holds the connection-status badge and the expand-to-fullscreen + trigger (absent from the `fullHeight` mount, which floats the status + badge inside the terminal instead). `margin-left: auto` targets the + expand trigger by its own class rather than `:last-child`, same + split-row intent `Shell.css`'s `.shell-header-actions` uses. */ .ui-agent-term-preview-toolbar { display: flex; align-items: center; @@ -51,6 +46,7 @@ .ui-agent-term-preview-full { display: flex; flex-direction: column; + margin-block-start: 0; } .ui-agent-term-preview-full .ui-agent-term-preview-wrap.terminal-wrap { max-height: none; @@ -61,6 +57,14 @@ max-height: none; height: 100%; } +/* Flush to the header bar and the viewport sides; the input row below + gets its own padding so it doesn't touch the screen edge. */ +.ui-agent-term-preview-full .ui-agent-term-preview-wrap.terminal-wrap { + margin: 0; +} +.ui-agent-term-preview-full .ui-agent-input { + padding: 0.4em 0.75em 0.6em; +} /* `box-sizing: border-box`, not the browser's default `content-box` — `.live.terminal`'s own `padding: 0.8em 1em 0.4em` (terminal.css) is @@ -105,3 +109,12 @@ gap: 0.25em; max-width: calc(100% - 0.8em); } + +/* Full-tab mount's connection badge — top-left floating twin of + `.ui-agent-term-preview-header-badges` (top-right), same anchor. */ +.ui-agent-term-preview-live { + position: absolute; + top: 0.4em; + left: 0.4em; + z-index: 1; +} diff --git a/frontend/packages/swarm-ui/src/pages/agents/AgentTermPreview.tsx b/frontend/packages/swarm-ui/src/pages/agents/AgentTermPreview.tsx index 7d0f54e1..49c02c7d 100644 --- a/frontend/packages/swarm-ui/src/pages/agents/AgentTermPreview.tsx +++ b/frontend/packages/swarm-ui/src/pages/agents/AgentTermPreview.tsx @@ -175,13 +175,16 @@ export function AgentTermPreview({ (fullHeight ? " ui-agent-term-preview-full" : "") } > -
+ )}