/** * `ProjectTabs` — the project tab bar rendered below the app header. * * Shows one tab per open project with a close control, and a "+" button to the * right that opens the **Projects** panel (floating) — the single entry point * for creating a project or switching to a known one (#26). Purely * presentational: all state lives in the parent (ProjectsView via useProjects). * * The bar is always present (even with no open project) so the "+" stays * reachable; the empty case shows a muted placeholder next to it. */ import type { TabItem } from "@/shared"; import { Button, Tabs, cn } from "@/shared"; export interface ProjectTabsProps { items: TabItem[]; activeTabId: string | null; onSelect: (id: string) => void; onClose: (id: string) => void; /** Whether the Projects panel is currently open (in any placement). */ projectsPanelOpen: boolean; /** Open the Projects panel (floating) — create/switch project. */ onOpenProjectsPanel: () => void; className?: string; } export function ProjectTabs({ items, activeTabId, onSelect, onClose, projectsPanelOpen, onOpenProjectsPanel, className, }: ProjectTabsProps) { return (
No open tabs.
) : (