"use client"; import { useState } from "react"; import { Button } from "@/components/ui/button"; import useStore from "@/lib/store"; import { Sparkles, FileText, ListTodo, Palette, Presentation, History, Settings, Github, Menu, X, Megaphone } from "lucide-react"; import { cn } from "@/lib/utils"; export type View = "enhance" | "prd" | "action" | "uxdesigner" | "slides" | "googleads" | "history" | "settings"; interface SidebarProps { currentView: View; onViewChange: (view: View) => void; } export default function Sidebar({ currentView, onViewChange }: SidebarProps) { const history = useStore((state) => state.history); const [isMobileMenuOpen, setIsMobileMenuOpen] = useState(false); const menuItems = [ { id: "enhance" as View, label: "Prompt Enhancer", icon: Sparkles }, { id: "prd" as View, label: "PRD Generator", icon: FileText }, { id: "action" as View, label: "Action Plan", icon: ListTodo }, { id: "uxdesigner" as View, label: "UX Designer", icon: Palette }, { id: "slides" as View, label: "Slides Generator", icon: Presentation }, { id: "googleads" as View, label: "Google Ads Gen", icon: Megaphone }, { id: "history" as View, label: "History", icon: History, count: history.length }, { id: "settings" as View, label: "Settings", icon: Settings }, ]; const handleViewChange = (view: View) => { onViewChange(view); setIsMobileMenuOpen(false); }; const SidebarContent = () => ( <>
Quick Tips