import { default as React } from 'react'; /** * Navigation item for shell registration */ export interface NavItem { id: string; label: string; path: string; icon?: string | React.ReactNode; group?: string; order?: number; children?: NavItem[]; } /** * Footer item for shell registration */ export interface FooterItem { id: string; label: string; section?: 'left' | 'center' | 'right'; icon?: string | React.ReactNode; } /** * Props for the VibeControlsRoot component */ export interface VibeControlsRootProps { /** * Hosted text-to-speech proxy for the AI assistant, e.g. * `https:///v1/tts`. * * ★ Omit it and the assistant speaks in DEVICE voices — a robotic system * voice, and no voice picker, because the selector hides itself below two * available voices. It degrades silently; nothing errors and nothing logs. * * ★★ The proxy bills per character, so requests carry the caller's auth * header. Do not point this at an endpoint that accepts anonymous POSTs. */ ttsEndpoint?: string; /** * Base path for routing (e.g., '/vibecontrols') */ basePath?: string; /** * Navigation function from the shell */ navigate?: (path: string) => void; /** * Current authenticated user info */ currentUser?: { id: string; email?: string; name?: string; }; /** * Current workspace ID */ workspaceId?: string; /** * Current organization ID */ organizationId?: string; /** * Current project ID */ projectId?: string; /** * Current tenant ID */ tenantId?: string; /** * API Gateway base URL */ apiGatewayUrl?: string; /** * Authentication token */ authToken?: string; /** * Workspace-scoped JWT token. * The gateway requires both authToken (Authorization) and workspaceToken * (X-Workspace-Authorization) for workspace-scoped operations. */ workspaceToken?: string; /** * Optional callback when an agent is selected */ onAgentSelect?: (agent: AgentSummary) => void; /** * Optional callback when a session is started */ onSessionStart?: (session: SessionSummary) => void; /** * Optional callback when a vibe is activated */ onVibeActivate?: (vibe: VibeSummary) => void; /** * Optional default view to show */ defaultView?: VibeControlsView; /** * Optional function to register navigation items with the shell */ registerNavItems?: (items: NavItem | NavItem[]) => () => void; /** * Optional function to register footer items with the shell */ registerFooterItems?: (items: FooterItem | FooterItem[]) => () => void; /** * Callback invoked when an authentication error is detected * (e.g., expired token, UNAUTHENTICATED GraphQL response). * The host shell should use this to trigger logout / redirect to login. */ onAuthError?: () => void; /** * Whether this module should mount its own sonner ``. * * Defaults to `false`. Production host app shells already mount a single * Toaster (via `AppShellProvider`), and sonner is a global singleton — so a * second Toaster here renders every toast twice. Only the standalone dev * harness (`src/dev/main.tsx`), which has no host shell, sets this `true`. */ renderToaster?: boolean; } /** * Summary of an agent for callbacks */ export interface AgentSummary { id: string; name: string; type: string; status: string; } /** * Summary of a session for callbacks */ export interface SessionSummary { id: string; name: string; type: string; status: string; agentId?: string; } /** * Summary of a vibe for callbacks */ export interface VibeSummary { id: string; name: string; type: string; status?: string; path?: string; } /** * View mode for the vibecontrols UI */ export type VibeControlsView = 'agents' | 'sessions' | 'vibes'; /** * Tab in the vibecontrols interface */ export type VibeControlsTab = 'overview' | 'agents' | 'sessions' | 'vibes' | 'connections';