Files
buzz-sheet/components/admin/image-generator-nav.tsx
T
gunshiz db554228bc
CI / Verify (push) Successful in 1m29s
CI / Build immutable images and deploy (push) Failing after 1m42s
feat(admin-images) : add standalone export generators
2026-09-29 17:13:24 +07:00

50 lines
1.3 KiB
TypeScript

"use client";
import Link from "next/link";
import { usePathname } from "next/navigation";
import {
ChartNoAxesColumnIncreasingIcon,
ImageIcon,
SwordsIcon,
UsersIcon,
} from "lucide-react";
import { Button } from "@/components/ui/button";
const links = [
{ href: "/admin/image/overview", label: "Overview", icon: ImageIcon },
{ href: "/admin/image/team", label: "Team", icon: UsersIcon },
{ href: "/admin/image/weapon", label: "Weapon", icon: SwordsIcon },
{
href: "/admin/image/constellation",
label: "Constellation",
icon: ChartNoAxesColumnIncreasingIcon,
},
];
export function ImageGeneratorNav() {
const pathname = usePathname();
return (
<aside className="min-w-0 lg:w-48 lg:shrink-0">
<nav
aria-label="Image generator navigation"
className="flex min-w-0 gap-1 overflow-x-auto lg:sticky lg:top-4 lg:flex-col"
>
{links.map(({ href, label, icon: Icon }) => (
<Button
key={href}
variant={pathname === href ? "secondary" : "ghost"}
className="justify-start"
nativeButton={false}
render={<Link href={href} />}
>
<Icon data-icon="inline-start" />
{label}
</Button>
))}
</nav>
</aside>
);
}