"use client"; import Link from "next/link"; import { usePathname } from "next/navigation"; import { Icon } from "../Icon"; import type { NavItem } from "./nav"; export function AdminNav({ groups, badges }: { groups: { group: string; items: NavItem[] }[]; badges: Record }) { const pathname = usePathname(); const active = (href: string) => (href === "/admin" ? pathname === "/admin" : pathname === href || pathname.startsWith(href + "/")); return ( ); }