Dodaios is an open-source agent OS for your desktop: it runs your coding agents, browser and apps by voice or chat, on your own machine. Formerly Personal Jarvis.
Python agent-orchestrationai-agentai-coding-assistantclaude-codecoding-agentcomputer-usedesktop-applocal-firstmcppersonal-jarvisvoice-assistantvoice-coding
feat(agents): drop the caption switch and name pill, chat reaches the top (#1106)
Ruben Lütke1e352a7270dc
diff --git a/dodaios/ui/web/frontend/src/App.tsx b/dodaios/ui/web/frontend/src/App.tsxindex f72d2edf5c..3841a26499 100644--- a/dodaios/ui/web/frontend/src/App.tsx+++ b/dodaios/ui/web/frontend/src/App.tsx@@ -351,8 +351,10 @@ export default function App() {*/}<main className="relative flex min-w-0 flex-1 flex-col">{/* Gray, like the sidebar. The content panel below rounds its- top-left corner so this gray shows in the curve. */}- <div className="h-8 shrink-0" data-testid="caption-rule" />+ top-left corner so this gray shows in the curve. The Agents page+ draws its own columns up to the window's top edge, so the chat+ stays dark right under the caption. */}+ {!(sectionFullscreen && activeSection === "agents") && <div className="h-8 shrink-0" data-testid="caption-rule" />}<div className={sectionFullscreen ? "flex min-h-0 min-w-0 flex-1 flex-col" : "jarvis-sheet flex min-h-0 min-w-0 flex-1 flex-col"}>{/* Outside input software (dictation, text expanders, auto-type) cannotreach an elevated window: an OS-level gate the user must be tolddiff --git a/dodaios/ui/web/frontend/src/components/society/agentSection.css b/dodaios/ui/web/frontend/src/components/society/agentSection.cssindex 5e8c598e87..40ab655203 100644--- a/dodaios/ui/web/frontend/src/components/society/agentSection.css+++ b/dodaios/ui/web/frontend/src/components/society/agentSection.css@@ -117,6 +117,12 @@background: hsl(var(--background));}+/* Where the page reaches the window's top edge, each column keeps the+ caption's height clear in its own colour (set by the Agents page). */+.as-shell > .as-region {+ padding-top: var(--as-caption-gap, 0px);+}+/* The pane's content draws its own edge (the details rail has a left border). */.as-pane {background: hsl(var(--sidebar));diff --git a/dodaios/ui/web/frontend/src/components/society/card/AgentCardOverlay.test.tsx b/dodaios/ui/web/frontend/src/components/society/card/AgentCardOverlay.test.tsxindex c5a0d5efd9..3daab877b2 100644--- a/dodaios/ui/web/frontend/src/components/society/card/AgentCardOverlay.test.tsx+++ b/dodaios/ui/web/frontend/src/components/society/card/AgentCardOverlay.test.tsx@@ -1,5 +1,5 @@/**- * The workspace wires the frame together: roster, header and chat in one+ * The workspace wires the frame together: roster and chat in one* grid, a model save in the details pane held against the composer's Send,* and the keyboard shortcuts live only while the section is on screen.*/@@ -60,11 +60,12 @@ function mount(props: Partial<Parameters<typeof AgentCardOverlay>[0]> = {}) {}describe("AgentCardOverlay", () => {- it("renders roster, header, chat and details once, without a render storm", () => {+ it("renders roster, chat and details once, without a render storm", () => {renders.chat = 0;mount();expect(screen.getByTestId("society-roster-rail")).toBeTruthy();- expect(screen.getByTestId("agent-header-name").textContent).toBe("Alpha");+ // No name pill over the chat: the chat reaches the top of its column.+ expect(screen.queryByTestId("agent-header")).toBeNull();// The details pane is mounted but closed: the section opens on a plain chat.expect(screen.getByRole("complementary", { name: "Details", hidden: true }).textContent).toContain("Alpha");expect(screen.getByTestId("shell-details").hidden).toBe(true);@@ -79,10 +80,15 @@ describe("AgentCardOverlay", () => {expect(screen.getByTestId("chat-probe").dataset.saving).toBe("yes");});- it("opens the details pane from the name pill", () => {- mount();- fireEvent.click(screen.getByTestId("shell-details-toggle"));+ it("opens and closes the details pane from the open agent's roster row", () => {+ const { onSelectAgent } = mount();+ const row = document.querySelector<HTMLButtonElement>('[data-testid="society-roster-rail"] [aria-current="true"]');+ expect(row).toBeTruthy();+ fireEvent.click(row!);expect(screen.getByTestId("shell-details").hidden).toBe(false);+ fireEvent.click(row!);+ expect(screen.getByTestId("shell-details").hidden).toBe(true);+ expect(onSelectAgent).not.toHaveBeenCalled();});it("steps to the next agent with Alt + Arrow Down only while active", () => {diff --git a/dodaios/ui/web/frontend/src/components/society/card/AgentCardOverlay.tsx b/dodaios/ui/web/frontend/src/components/society/card/AgentCardOverlay.tsxindex c52aec0b1b..9c709c13b5 100644--- a/dodaios/ui/web/frontend/src/components/society/card/AgentCardOverlay.tsx+++ b/dodaios/ui/web/frontend/src/components/society/card/AgentCardOverlay.tsx@@ -19,7 +19,6 @@ import { useRosterActivity } from "../roster/useRosterActivity";import type { SocietyChatGroup } from "@/lib/societyChatGroups";import { OptionsRail } from "./OptionsRail";import { AgentChatLayout } from "./AgentChatLayout";-import { AgentHeader } from "./AgentHeader";import { HeaderModelSlotContext } from "./headerModelSlot";export interface AgentCardOverlayProps {@@ -90,7 +89,7 @@ export function AgentCardOverlay({)}<AgentChatLayoutresetKey={agent.agentId}- roster={({ collapsed, onToggleCollapsed }) => (+ roster={({ collapsed, onToggleCollapsed, onToggleDetails }) => (<RosterRailagents={roster}groups={groups}@@ -101,7 +100,7 @@ export function AgentCardOverlay({teamsPending={teamsPending}sample={sample}activeAgentId={agent.agentId}- onOpen={(id) => { if (id !== agent.agentId) onSelectAgent?.(id); }}+ onOpen={(id) => { if (id === agent.agentId) onToggleDetails(); else onSelectAgent?.(id); }}onCreate={() => onCreate?.()}side="left"className="w-full border-0"@@ -112,7 +111,7 @@ export function AgentCardOverlay({keyboard={active}/>)}- header={(details) => <AgentHeader agent={agent} details={details} />}+ header={() => null}options={<OptionsRail agent={agent} onRetired={onClose} sample={sample} onModelSavingChange={setModelSaving} />}><section className="flex min-h-0 min-w-0 flex-1 flex-col" aria-label={t("society.card.chat")} data-testid="agent-card-chat">diff --git a/dodaios/ui/web/frontend/src/components/society/card/AgentChatLayout.tsx b/dodaios/ui/web/frontend/src/components/society/card/AgentChatLayout.tsxindex 50fcfc973b..927c0a4ece 100644--- a/dodaios/ui/web/frontend/src/components/society/card/AgentChatLayout.tsx+++ b/dodaios/ui/web/frontend/src/components/society/card/AgentChatLayout.tsx@@ -38,6 +38,8 @@ export interface RosterSlotState {/** Show the avatar rail instead of rows. */collapsed: boolean;onToggleCollapsed: () => void;+ /** Opens or closes the details pane (a press on the open agent's row). */+ onToggleDetails: () => void;}/** What the chat header needs to open and close the details pane from its name pill. */@@ -267,7 +269,7 @@ export function AgentChatLayout({ children, options, roster, header, resetKey }:<div className="as-region" style={{ zIndex: rosterSheet ? 30 : undefined }}><div ref={rosterRef} className={cn("flex min-h-0 flex-1 flex-col", rosterSheet && "as-roster-overlay")}style={rosterSheet ? { width: ROSTER_DEFAULT } : undefined} data-testid="shell-roster">- {roster({ collapsed: rosterCollapsed, onToggleCollapsed: toggleRoster })}+ {roster({ collapsed: rosterCollapsed, onToggleCollapsed: toggleRoster, onToggleDetails: togglePane })}</div>{layout.roster === "full" ? separator("roster", rosterWidth) : null}</div>diff --git a/dodaios/ui/web/frontend/src/views/society/SocietyView.attention.test.tsx b/dodaios/ui/web/frontend/src/views/society/SocietyView.attention.test.tsxindex ce2a80c0d2..807de69c4c 100644--- a/dodaios/ui/web/frontend/src/views/society/SocietyView.attention.test.tsx+++ b/dodaios/ui/web/frontend/src/views/society/SocietyView.attention.test.tsx@@ -40,9 +40,10 @@ beforeEach(() => {});afterEach(() => cleanup());-it("puts the bell in the caption beside the mode switch", () => {+it("keeps the caption clear of the bell", () => {render(<SocietyView />);- expect(screen.getByTestId("mode-switch").contains(screen.getByTestId("attention-bell"))).toBe(true);+ expect(screen.queryByTestId("mode-switch")).toBeNull();+ expect(screen.queryByTestId("attention-bell")).toBeNull();});it("opens the requested agent and reveals the card", async () => {diff --git a/dodaios/ui/web/frontend/src/views/society/SocietyView.deferred.test.tsx b/dodaios/ui/web/frontend/src/views/society/SocietyView.deferred.test.tsxindex 6c55cb0ece..1bf342f35a 100644--- a/dodaios/ui/web/frontend/src/views/society/SocietyView.deferred.test.tsx+++ b/dodaios/ui/web/frontend/src/views/society/SocietyView.deferred.test.tsx@@ -35,7 +35,7 @@ vi.mock("@/components/society/card/BuildingCardOverlay", () => {});afterEach(cleanup);-it("never evaluates closed dialog modules; creates agents without a dialog", async () => {+it("never evaluates the Verse or dialog modules; creates agents without a dialog", async () => {const client = new QueryClient();render(<QueryClientProvider client={client}><SocietyView /></QueryClientProvider>);expect(loaded).toEqual({ building: 0, world: 0 });@@ -48,21 +48,8 @@ it("never evaluates closed dialog modules; creates agents without a dialog", asyexpect(screen.getByLabelText("Existing chat draft")).toBe(draft);expect((draft as HTMLInputElement).value).toBe("Keep this draft");- const worldTab = screen.getByRole("tab", { name: "society.shell.mode_verse" });- fireEvent.pointerEnter(worldTab);- await waitFor(() => expect(loaded.world).toBe(1));+ // The Verse has no entry on this page any more: its chunk stays unloaded.+ expect(loaded).toEqual({ building: 0, world: 0 });expect(screen.queryByTestId("society-world-surface")).toBeNull();- expect(screen.queryByRole("button", { name: "Open foundry" })).toBeNull();- fireEvent.click(worldTab);- fireEvent.click(await screen.findByRole("button", { name: "Open foundry" }));- expect(await screen.findByRole("dialog", { name: "Building" })).toBeTruthy();- expect(screen.getByText("foundry")).toBeTruthy();- expect(loaded).toEqual({ building: 1, world: 1 });- fireEvent.click(screen.getByRole("button", { name: "Close building" }));- fireEvent.click(screen.getByRole("button", { name: "Open docks" }));- expect(await screen.findByRole("dialog", { name: "Building" })).toBeTruthy();- expect(screen.getByText("plugins")).toBeTruthy();- fireEvent.click(screen.getByRole("button", { name: "Close building" }));- expect(screen.queryByRole("dialog")).toBeNull();client.clear();});diff --git a/dodaios/ui/web/frontend/src/views/society/SocietyView.test.tsx b/dodaios/ui/web/frontend/src/views/society/SocietyView.test.tsxindex 94e3882394..183c8330bb 100644--- a/dodaios/ui/web/frontend/src/views/society/SocietyView.test.tsx+++ b/dodaios/ui/web/frontend/src/views/society/SocietyView.test.tsx@@ -1,6 +1,5 @@-import { cleanup, fireEvent, render, screen, waitFor, within } from "@testing-library/react";+import { cleanup, fireEvent, render, screen } from "@testing-library/react";import { afterEach, beforeEach, expect, it, vi } from "vitest";-import { setMapFullscreen } from "@/lib/mapFullscreen";import { LAST_AGENT_STORAGE_KEY } from "./lastAgent";import { SocietyView } from "./SocietyView";@@ -63,27 +62,6 @@ it("opens a group from the agent rail and returns to an individual member chat",expect(screen.getByTestId("workspace").textContent).toContain("Specialist");});-it("switches to Map and back without losing the selected agent or draft", async () => {- render(<SocietyView />);- fireEvent.click(screen.getByText("Select specialist"));- const draft = screen.getByLabelText("Draft") as HTMLInputElement;- fireEvent.change(draft, { target: { value: "Unsent message" } });- fireEvent.click(screen.getByRole("tab", { name: "society.shell.mode_verse" }));- const map = await screen.findByTestId("map");- expect(map.dataset.active).toBe("true");- fireEvent.click(screen.getByRole("tab", { name: "society.roster.title" }));- expect(screen.getByTestId("society-world-surface").getAttribute("aria-hidden")).toBe("true");- expect(screen.getByText("Specialist")).toBeTruthy();- expect(screen.getByLabelText("Draft")).toBe(draft);- expect(draft.value).toBe("Unsent message");- expect(screen.getByTestId("map")).toBe(map);- expect(map.dataset.active).toBe("false");- fireEvent.click(screen.getByRole("tab", { name: "society.shell.mode_verse" }));- expect(screen.getByTestId("map")).toBe(map);- expect(map.dataset.active).toBe("true");- expect(screen.getByTestId("society-world-surface").getAttribute("aria-hidden")).toBe("false");-});-it("restores the most recently selected agent after the view is remounted", () => {const firstVisit = render(<SocietyView />);fireEvent.click(screen.getByText("Select specialist"));@@ -95,16 +73,6 @@ it("restores the most recently selected agent after the view is remounted", () =expect(screen.getByText("Specialist")).toBeTruthy();});-it("opens map selections in Agents and keeps creation available", async () => {- render(<SocietyView />);- fireEvent.click(screen.getByRole("tab", { name: "society.shell.mode_verse" }));- fireEvent.click(await screen.findByText("Map specialist"));- expect(screen.getByTestId("society-world-surface").getAttribute("aria-hidden")).toBe("true");- expect(screen.getByText("Specialist")).toBeTruthy();- fireEvent.click(screen.getByText("Create agent"));- await waitFor(() => expect(quick.create).toHaveBeenCalledTimes(1));-});-it("one click creates an agent and opens its chat", async () => {render(<SocietyView />);expect(screen.getByText("Lead")).toBeTruthy();@@ -122,40 +90,14 @@ it("shows a failed one-click creation instead of inventing a row", async () => {});-it("keeps the Map/Agents switch in the caption in both modes", async () => {- render(<SocietyView />);- // Agents mode: no second bar, no "Back to app" — the workspace expands- // straight under the caption, the switch rides centered in it.- expect(screen.queryByRole("button", { name: "settings_hub.back_to_app" })).toBeNull();- const captionSwitch = screen.getByTestId("mode-switch");- expect(within(captionSwitch).getByRole("tab", { name: "society.shell.mode_verse" })).toBeTruthy();- fireEvent.click(within(captionSwitch).getByRole("tab", { name: "society.shell.mode_verse" }));- await screen.findByTestId("map");- // Map mode takes the native window fullscreen: the switch stays in the- // caption instead of shrinking into the map HUD, so Agents stays reachable.- expect(screen.getByTestId("mode-switch")).toBeTruthy();- expect(screen.queryByRole("button", { name: "settings_hub.back_to_app" })).toBeNull();- fireEvent.click(screen.getByRole("tab", { name: "society.roster.title" }));- expect(screen.getByTestId("society-world-surface").getAttribute("aria-hidden")).toBe("true");- expect(screen.getByTestId("mode-switch")).toBeTruthy();- expect(screen.queryByRole("button", { name: "settings_hub.back_to_app" })).toBeNull();-});-it("navigates back through the window caption instead of a sections toggle", () => {render(<SocietyView />);expect(screen.queryByRole("button", { name: "society.world.toggle_sections" })).toBeNull();expect(screen.queryByRole("button", { name: "settings_hub.back_to_app" })).toBeNull();- // The caption back button leaves this fullscreen section. The sidebar toggle is gone.- expect(screen.getByTestId("mode-switch")).toBeTruthy();-});--it("leaves Map on Escape without requesting native fullscreen in a browser", async () => {- render(<SocietyView />);- fireEvent.click(screen.getByRole("tab", { name: "society.shell.mode_verse" }));- await screen.findByTestId("map");- expect(setMapFullscreen).not.toHaveBeenCalledWith(true);- fireEvent.keyDown(document, { key: "Escape" });- expect(screen.getByTestId("society-world-surface").getAttribute("aria-hidden")).toBe("true");+ // The caption back button leaves this fullscreen section. The sidebar toggle is gone,+ // and nothing of this page rides in the caption.+ expect(screen.queryByTestId("mode-switch")).toBeNull();+ expect(screen.queryByRole("tab", { name: "society.shell.mode_verse" })).toBeNull();});it("shows no station shortcut in Agents mode", () => {@@ -163,41 +105,3 @@ it("shows no station shortcut in Agents mode", () => {render(<SocietyView />);expect(screen.queryByRole("button", { name: "society.mars.station_title" })).toBeNull();});--it("does not discard a Mars form when Escape belongs to its input", async () => {- render(<SocietyView />);- fireEvent.click(screen.getByRole("tab", { name: "society.shell.mode_verse" }));- const field = await screen.findByLabelText("Mars draft");- fireEvent.change(field, { target: { value: "Unsent station draft" } });- fireEvent.keyDown(field, { key: "Escape" });- expect(screen.getByTestId("map")).toBeTruthy();- expect((field as HTMLInputElement).value).toBe("Unsent station draft");- fireEvent.keyDown(document, { key: "Escape" });- expect(screen.getByTestId("society-world-surface").getAttribute("aria-hidden")).toBe("true");-});--it.each(["Mars draft", "Player viewport", "Follow viewport"])("preserves focused %s when the browser exits fullscreen without a keydown", async (target) => {- render(<SocietyView />);- fireEvent.click(screen.getByRole("tab", { name: "society.shell.mode_verse" }));- const field = await screen.findByLabelText("Mars draft");- fireEvent.change(field, { target: { value: "Unsent station draft" } });- const focused = target === "Mars draft" ? field : screen.getByText(target);- focused.focus();- expect(document.fullscreenElement).toBeFalsy();- fireEvent(document, new Event("fullscreenchange"));- expect(screen.getByTestId("map")).toBeTruthy();- expect(screen.getByLabelText("Mars draft")).toBe(field);- expect((field as HTMLInputElement).value).toBe("Unsent station draft");- fireEvent.click(screen.getByRole("tab", { name: "society.roster.title" }));- expect(screen.getByTestId("society-world-surface").getAttribute("aria-hidden")).toBe("true");-});--it("still leaves the ordinary map when browser fullscreen exits", async () => {- render(<SocietyView />);- fireEvent.click(screen.getByRole("tab", { name: "society.shell.mode_verse" }));- await screen.findByTestId("map");- fireEvent(document, new Event("fullscreenchange"));- expect(screen.getByTestId("society-world-surface").getAttribute("aria-hidden")).toBe("true");-});--diff --git a/dodaios/ui/web/frontend/src/views/society/SocietyView.tsx b/dodaios/ui/web/frontend/src/views/society/SocietyView.tsxindex 9fcd485d3e..49ceb22288 100644--- a/dodaios/ui/web/frontend/src/views/society/SocietyView.tsx+++ b/dodaios/ui/web/frontend/src/views/society/SocietyView.tsx@@ -1,15 +1,11 @@import { lazy, Suspense, useCallback, useMemo, useState, useEffect } from "react";-import { createPortal } from "react-dom";import { useQueryClient } from "@tanstack/react-query";-import { Orbit, Users } from "lucide-react";import { setMapFullscreen } from "@/lib/mapFullscreen";import { inDesktopShell } from "@/lib/nativeDrop";import { useLocaleChunk, useT } from "@/i18n";import { cn } from "@/lib/utils";-import { CAPTION_ICON_STROKE, CAPTION_SEGMENT_OFF, CAPTION_SEGMENT_ON, CAPTION_TRACK } from "@/components/layout/captionSwitch";import { AgentCardOverlay } from "@/components/society/card/AgentCardOverlay";-import { BrowserProfilesButton } from "@/components/society/browser/BrowserProfilesButton";import { BUILDING_CARDS, isBuildingPlace, type BuildingPlace } from "@/components/society/card/buildingCards";import { DeferredSocietyDialog } from "@/components/society/card/DeferredSocietyDialog";import type { PlaceId } from "@/components/society/world/islandLayout";@@ -22,31 +18,15 @@ import { ChatGroupPanel } from "@/components/society/chat/ChatGroupPanel";import { useSocietyChatStore } from "@/components/society/chat/AgentChatPanel";import { chatGroupsKnown, createSocietyChatGroup, updateSocietyChatGroup, useSocietyChatGroups } from "@/lib/societyChatGroups";import { CanvasActivity } from "@/hooks/useCanvasAwake";-import { AttentionBell } from "@/components/society/attention/AttentionBell";import { useAgentChatStore } from "@/store/agentChat";import { forgetLastAgentId, rememberLastAgentId, storedLastAgentId } from "./lastAgent";import { revealCard, setAgentOnScreen, takeAgentRequest, useAgentNavigation } from "./agentNavigation";-/** The page's two faces, in caption order: the agents, then the Verse. */-const MODES = [- { value: "agents", labelKey: "society.roster.title", titleKey: "society.roster.title", Icon: Users },- { value: "world", labelKey: "society.shell.mode_verse", titleKey: "society.world.mode_map", Icon: Orbit },-] as const;-// Small and three.js-free: the fallback in front of the lazy Verse chunk.-import { VerseLoadingScreen, preloadLoadingArt } from "@/components/society/verse/VerseLoadingScreen";--/** A labelled segment on the caption track: icon plus word, the "on" one lifted. */-const MODE_SEGMENT =- "relative z-[1] flex h-full items-center gap-1.5 rounded-full border px-3 text-xs font-medium " +- "transition-[background-color,color,border-color,box-shadow] duration-150 ease-out motion-reduce:transition-none " +- "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring";-const MODE_SEGMENT_ON =- "border-border-strong/60 bg-background shadow-[0_1px_2px_rgb(var(--scrim-rgb)/0.25)] dark:border-border-strong dark:bg-surface-raised";+import { VerseLoadingScreen } from "@/components/society/verse/VerseLoadingScreen";const loadWorld = () => import("@/views/DodaiosAgentsView").then((m) => ({ default: m.DodaiosAgentsView }));const JarvisAgentsBoard = lazy(loadWorld);-const preloadWorld = () => { preloadLoadingArt(); void loadWorld().catch((error) => console.debug("World preload unavailable", error)); };// Do not evaluate either dialog's 3D dependencies until someone opens it.const loadBuildingDialog = () => import("@/components/society/card/BuildingCardOverlay")@@ -225,38 +205,9 @@ export function SocietyView() {if (isBuildingPlace(place)) setOpenPlace(place);}, []);- // Labelled, in the caption look the Agentic IDE's switch uses: a word- // names each face, so the switch reads without hovering.- const modeSwitch = (- <div role="tablist" aria-label={t("society.world.mode_label")} className={CAPTION_TRACK}>- {MODES.map(({ value, labelKey, titleKey, Icon }) => {- const on = mode === value;- return <button key={value} type="button" role="tab" aria-selected={on}- title={t(titleKey)} data-testid={`society-mode-${value}`}- onClick={() => switchMode(value)}- onPointerEnter={value === "world" ? preloadWorld : undefined}- onFocus={value === "world" ? preloadWorld : undefined}- className={cn(MODE_SEGMENT, on ? cn(CAPTION_SEGMENT_ON, MODE_SEGMENT_ON) : cn(CAPTION_SEGMENT_OFF, "border-transparent"))}>- <Icon aria-hidden className="h-3.5 w-3.5" strokeWidth={CAPTION_ICON_STROKE} />- <span>{t(labelKey)}</span>- </button>;- })}- </div>- );-return (<div className={mode === "world" ? "fixed inset-x-0 bottom-0 top-8 z-30 flex flex-col bg-background" : "relative flex h-full min-h-0 w-full flex-col"} data-testid="society-view" data-tour="agents-page"><div className="flex min-h-0 min-w-0 flex-1 flex-col">- {/* Map mode takes the native window fullscreen, so the switch cannot- live inside the map HUD: it would shrink into the corner and strand- the user on the island. It rides in the window caption in BOTH- modes — one switch, always centered, always a way back. */}- {createPortal(- <div className="pointer-events-none fixed inset-x-0 top-0 z-[140] flex h-8 items-center justify-center" data-testid="mode-switch">- <div className="pointer-events-auto flex items-center gap-2">{modeSwitch}<BrowserProfilesButton iconOnly /><AttentionBell /></div>- </div>,- document.body,- )}{fullscreenError && <p role="alert" className="bg-card px-4 py-2 text-sm text-destructive">{t("society.world.fullscreen_failed")}</p>}{groupError && <p role="alert" className="bg-card px-4 py-2 text-sm text-destructive">{groupError}</p>}{createError && <p role="alert" className="bg-card px-4 py-2 text-sm text-destructive">{createError}</p>}@@ -274,7 +225,7 @@ export function SocietyView() {</div>) : null}- <div className={mode === "agents" ? "flex min-h-0 flex-1 flex-col" : "hidden"}>+ <div className={mode === "agents" ? cn("flex min-h-0 flex-1 flex-col [--as-caption-gap:2rem]", !openAgent || openGroup ? "pt-8" : null) : "hidden"}>{openGroup ? (<ChatGroupPanel group={openGroup} groups={groups} roster={agents} onOpenAgent={selectAgent} onOpenGroup={selectGroup}onCreateAgent={createAgent} onDeleted={() => setOpenGroupId(null)}