feat(web): add mobile task flow shell — #206

This commit is contained in:
2026-08-15 01:31:49 +02:00
parent dcf6a84dba
commit a907586f41
4 changed files with 384 additions and 42 deletions

View File

@ -46,9 +46,18 @@ interface WebAgentCellProps {
* `key`, so the terminal/PTY is never recreated by it.
*/
refitSignal?: number;
/** Mobile task-flow session takes the whole viewport instead of a fixed cell. */
fullHeight?: boolean;
}
export function WebAgentCell({ projectId, agentId, cwd, nodeId, refitSignal }: WebAgentCellProps) {
export function WebAgentCell({
projectId,
agentId,
cwd,
nodeId,
refitSignal,
fullHeight = false,
}: WebAgentCellProps) {
const { agent } = useGateways();
const [sessionId, setSessionId] = useState<string | null>(null);
// Input API of the mounted xterm (#69), used by the mobile key bar. Stays
@ -81,7 +90,11 @@ export function WebAgentCell({ projectId, agentId, cwd, nodeId, refitSignal }: W
// lets it shrink inside the flex column instead of pushing the key bar off.
<div
data-testid="web-agent-cell"
className="flex h-[60dvh] min-h-64 w-full flex-col overflow-hidden rounded-md border border-border sm:h-80"
className={
fullHeight
? "flex h-full min-h-0 w-full flex-col overflow-hidden border border-border"
: "flex h-[60dvh] min-h-64 w-full flex-col overflow-hidden rounded-md border border-border sm:h-80"
}
>
<div className="min-h-0 flex-1">
<TerminalView