{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "breadcrumb",
  "title": "Breadcrumb",
  "author": "AniBT <https://anibt.net>",
  "description": "AniBT trail: 13px muted steps, links that turn pink, the current page in ink, small chevrons; asChild or Base UI render for router links.",
  "dependencies": [
    "lucide-react",
    "radix-ui"
  ],
  "registryDependencies": [
    "@anibt/theme"
  ],
  "files": [
    {
      "path": "registry/anibt/ui/breadcrumb.tsx",
      "content": "import * as React from \"react\"\nimport { ChevronRightIcon, MoreHorizontalIcon } from \"lucide-react\"\nimport { Slot } from \"radix-ui\"\n\nimport { cn } from \"@/lib/utils\"\n\n/**\n * Breadcrumb — the AniBT 「贴纸手账」 trail.\n *\n * 13px, muted; a link is `--anibt-ink2` and turns pink under the pointer; the\n * current page is ink at 600 and not a link. Separators are a small muted\n * chevron. The trail wraps rather than scrolls; keep it to three or four\n * steps and fold the middle into `BreadcrumbEllipsis`.\n *\n * No washi tape here: the tape is the single \"you are here\" mark of the main\n * navigation, and a second one on the same page would compete with it.\n *\n * The parts are shadcn's. `BreadcrumbLink` takes `asChild` (Radix) or\n * `render={<Link … />}` (Base UI) to hand the link to a router.\n */\nfunction Breadcrumb({ ...props }: React.ComponentProps<\"nav\">) {\n  return <nav aria-label=\"面包屑\" data-slot=\"breadcrumb\" {...props} />\n}\n\nfunction BreadcrumbList({ className, ...props }: React.ComponentProps<\"ol\">) {\n  return (\n    <ol\n      data-slot=\"breadcrumb-list\"\n      className={cn(\n        \"flex flex-wrap items-center gap-1.5 text-[13px] leading-5 break-words text-muted-foreground\",\n        className\n      )}\n      {...props}\n    />\n  )\n}\n\nfunction BreadcrumbItem({ className, ...props }: React.ComponentProps<\"li\">) {\n  return (\n    <li data-slot=\"breadcrumb-item\" className={cn(\"inline-flex min-w-0 items-center gap-1.5\", className)} {...props} />\n  )\n}\n\nfunction BreadcrumbLink({\n  asChild = false,\n  render,\n  className,\n  children,\n  ...props\n}: React.ComponentProps<\"a\"> & {\n  asChild?: boolean\n  /** Base UI's form of `asChild`: `render={<Link href=\"…\" />}`. */\n  render?: React.ReactElement\n}) {\n  const classes = cn(\n    \"inline-flex items-center gap-1 rounded-[6px] font-medium text-anibt-ink2 underline-offset-4 outline-hidden transition-colors duration-150 hover:text-accent-foreground focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-ring focus-visible:outline-solid [&>svg]:size-3.5 [&>svg]:shrink-0\",\n    className\n  )\n  if (asChild || render) {\n    const child = render ? (children !== undefined ? React.cloneElement(render, undefined, children) : render) : children\n    return (\n      <Slot.Root data-slot=\"breadcrumb-link\" className={classes} {...props}>\n        {child}\n      </Slot.Root>\n    )\n  }\n  return (\n    <a data-slot=\"breadcrumb-link\" className={classes} {...props}>\n      {children}\n    </a>\n  )\n}\n\nfunction BreadcrumbPage({ className, ...props }: React.ComponentProps<\"span\">) {\n  return (\n    <span\n      data-slot=\"breadcrumb-page\"\n      role=\"link\"\n      aria-disabled=\"true\"\n      aria-current=\"page\"\n      className={cn(\"anibt-ell font-semibold text-foreground\", className)}\n      {...props}\n    />\n  )\n}\n\nfunction BreadcrumbSeparator({ children, className, ...props }: React.ComponentProps<\"li\">) {\n  return (\n    <li\n      data-slot=\"breadcrumb-separator\"\n      role=\"presentation\"\n      aria-hidden=\"true\"\n      className={cn(\"text-muted-foreground/80 [&>svg]:size-3.5\", className)}\n      {...props}\n    >\n      {children ?? <ChevronRightIcon />}\n    </li>\n  )\n}\n\nfunction BreadcrumbEllipsis({ className, label = \"更多\", ...props }: React.ComponentProps<\"span\"> & { label?: string }) {\n  return (\n    <span\n      data-slot=\"breadcrumb-ellipsis\"\n      role=\"presentation\"\n      aria-hidden=\"true\"\n      className={cn(\"flex size-5 items-center justify-center [&>svg]:size-4\", className)}\n      {...props}\n    >\n      <MoreHorizontalIcon />\n      <span className=\"sr-only\">{label}</span>\n    </span>\n  )\n}\n\nexport {\n  Breadcrumb,\n  BreadcrumbList,\n  BreadcrumbItem,\n  BreadcrumbLink,\n  BreadcrumbPage,\n  BreadcrumbSeparator,\n  BreadcrumbEllipsis,\n}\n",
      "type": "registry:ui"
    }
  ],
  "categories": [
    "navigation"
  ],
  "type": "registry:ui"
}