import { useState } from "react"
import { NavLink, useNavigate } from "react-router"
import {
LayoutDashboard,
BookOpen,
FolderOpen,
TreePine,
Users,
MessageSquare,
Settings,
LogOut,
FileCheck,
AlertCircle,
Shield,
BookMarked,
KeyRound,
} from "lucide-react"
import { cn } from "@/lib/utils"
import { useAuth } from "@/hooks/use-auth"
import { ChangePasswordDialog } from "@/components/admin/ChangePasswordDialog"
const navItems = [
{ to: "/", label: "数据看板", icon: LayoutDashboard, end: true },
{ to: "/questions", label: "题库管理", icon: BookOpen },
{ to: "/questions?source=ugc", label: "UGC 审核", icon: FileCheck },
{ to: "/categories", label: "分类管理", icon: FolderOpen },
{ to: "/knowledge-cards", label: "知识卡", icon: BookMarked },
{ to: "/skill-tree", label: "技能树", icon: TreePine },
{ to: "/users", label: "用户管理", icon: Users },
{ to: "/feedback", label: "用户反馈", icon: MessageSquare },
{ to: "/reports", label: "举报处理", icon: AlertCircle },
{ to: "/admins", label: "管理员", icon: Shield },
{ to: "/settings", label: "系统设置", icon: Settings },
]
export function Sidebar() {
const { logout } = useAuth()
const navigate = useNavigate()
const [changePasswordOpen, setChangePasswordOpen] = useState(false)
function handleLogout() {
logout()
navigate("/login")
}
return (
<>
>
)
}