import Link from "next/link"; import { BookOpen, ClipboardCheck, ListTree, PenLine, Sparkles, type LucideIcon, } from "lucide-react"; import { AiToolbarMoreMenu } from "@/components/AiToolbarMoreMenu"; import { aiToolItems, primaryAiToolItems, secondaryAiToolItems, } from "@/lib/nav/ai-tools"; import type { ActiveNav } from "@/lib/nav/items"; import { buttonClass } from "@/lib/ui/variants"; interface AiToolbarProps { projectId: string; activeNav?: ActiveNav; } // T4-a · 项目内页常驻 AI 工具条(顶栏下,UX §3/§5)。 // 桌面展示完整工具条;窄屏只保留写本章/审稿,把低频入口收进更多菜单。 export function AiToolbar({ projectId, activeNav }: AiToolbarProps) { const primaryItems = primaryAiToolItems(projectId); const secondaryItems = secondaryAiToolItems(projectId); return ( ); } function toolIcon(key: ActiveNav): LucideIcon { if (key === "write") return PenLine; if (key === "review") return ClipboardCheck; if (key === "outline") return ListTree; if (key === "codex") return BookOpen; return Sparkles; } function toolClassName(isPrimary: boolean, isActive: boolean): string { if (isActive) { return buttonClass({ variant: "outline", size: "sm" }); } if (isPrimary) { return buttonClass({ variant: "primary", size: "sm" }); } return buttonClass({ variant: "secondary", size: "sm" }); }