SPB Git
699 B · 15 lines tsx
1import Link from "next/link";2import { ChevronRight } from "lucide-react";3export function Breadcrumbs({ items }: { items: { href?: string; label: string }[] }) {4  return (5    <nav aria-label="Breadcrumb" className="text-sm text-fg-3">6      <ol className="flex flex-wrap items-center gap-1">7        <li><Link href="/" className="hover:text-fg">Home</Link></li>8        {items.map((it, i) => (9          <li key={i} className="flex items-center gap-1"><ChevronRight className="h-3.5 w-3.5" aria-hidden />{it.href ? <Link href={it.href} className="hover:text-fg">{it.label}</Link> : <span className="text-fg-2" aria-current="page">{it.label}</span>}</li>10        ))}11      </ol>12    </nav>13  );14}15
Files · d0878ed8ec6f375df09d3e415bf35d941ff62d79
Menu

Theme