Skip to content
Pebble Pro is here at $49 one timeSee what’s included ↗
Pebble
ComponentsDocsMCPPricing
⌕ Find a component↗Log in
All components 673

Categories

Core inputs & forms46Buttons & actions33Navigation36Overlays & feedback49Data display33Charts & data viz40Cards & layout43Marketing blocks38App shells & pages37AI interfaces40Text & typography effects33Backgrounds & visual effects38Motion & transitions32Numbers & counters32Media34E-commerce333D & interactive36Themed sets40
Start with the essentials.Installation guide ↗Connect your agent ↗
← All componentsNavigation

Breadcrumb

A trail of links to the current page, with swappable separators, a collapsed-levels ellipsis and asChild links.

Preview

  1. Workspace
  2. Pebble notes
  3. Spring survey

Spring survey

48 sites · edited by Ines 3 min ago

IAMOPS
  1. Archive
  2. /
  3. 3 hidden folders
  4. /
  5. Maps
  6. /
  7. Coastline 1998.pdf
  1. TTomás’s team
  2. Projects
  3. Harbor redesignLive

Install

Add the editable source with the shadcn CLI. Your project also needs the shared theme tokens this component uses. Setup and requirements. The Pebble installer is not published yet.

npx shadcn@latest add https://pebbleui.com/r/breadcrumb.json

Props

PropTypeDefaultDescription
aria-labelstring"Breadcrumb"Breadcrumb: landmark name; change it when a page has several trails.
variant"plain" | "raised""plain"BreadcrumbList: raised puts the trail on a small card.
asChildbooleanfalseBreadcrumbLink: render the child element (e.g. a router link) instead of an <a>.
childrenReactNodechevronBreadcrumbSeparator: replaces the default chevron (e.g. "/").
labelstring"More"BreadcrumbEllipsis: screen-reader text for the collapsed levels.
Build notes
Plain semantic HTML: `nav > ol > li`, with separators as their own `li` elements so the list wraps cleanly with `flex flex-wrap` and a gap (`gap-1.5`, `sm:gap-2`). `BreadcrumbLink` swaps the `<a>` for Radix `Slot.Root` under `asChild`, so `data-slot`, classes and props merge onto a framework link. Icons are inline 16-unit SVGs drawn with `currentColor` (chevron stroke, three filled dots) so they follow the text colour; the separator sizes its SVG child with `[&>svg]:size-3.5`. No client hooks, so no `"use client"`; the parts render in server components. Compared with the source: lucide icons replaced by inline SVGs, landmark label capitalised and overridable, `role="link"`/`aria-disabled` dropped from the page, the ellipsis label made audible and configurable, link focus ring and hover underline added.

**Pebble (2026-11-03).** Links became small `h-7 px-1.5 rounded-md` hit targets with a `bg-muted` hover tint instead of an underline, a felt press (`active:scale-[0.97]`, off under `motion-reduce`) and the loud `ring-2 ring-ring ring-offset-2` focus ring. The page matches their height and padding so the trail does not shift. Type is 13 px; items keep `gap-1.5` for icon children (sized `3.5`), the list tightens to `gap-0.5` since each link now carries its own padding, and separators fade to `text-muted-foreground/60` with a slimmer chevron. `BreadcrumbList` gains `variant="raised"` (with `data-variant`), a card pebble: `bg-card ring-1 ring-hairline shadow-raised-xs inset-shadow-highlight`. Still no client hooks.

<!-- PEBBLE-LICENSE -->
View source

registry/nav/breadcrumb/breadcrumb.tsx

/* PEBBLE-LICENSE
Built by Pebble. Component: breadcrumb.

First-party license: MIT

The following first-party terms apply only to original Pebble material.

MIT License

Copyright (c) 2026 Praxys Solutions LLC (Pebble)

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

THIRD-PARTY NOTICES
These notices apply to identified upstream portions; Pebble terms do not replace or narrow their rights.

Upstream: https://raw.githubusercontent.com/shadcn-ui/ui/main/LICENSE.md
MIT License

Copyright (c) 2023 shadcn

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
END PEBBLE-LICENSE */

import * as React from "react";
import { Slot } from "radix-ui";

import { cn } from "@/lib/utils";

export function Breadcrumb({ "aria-label": ariaLabel, ...props }: React.ComponentProps<"nav">) {
  return <nav data-slot="breadcrumb" aria-label={ariaLabel ?? "Breadcrumb"} {...props} />;
}

// Pebble: `plain` sits on the page; `raised` puts the trail on a small card
// pebble (hairline ring, low shadow, top highlight) for toolbars and headers.
const listVariants = {
  plain: "gap-0.5",
  raised:
    "min-h-9 py-1 gap-0.5 rounded-lg bg-card px-1.5 shadow-raised-xs ring-1 inset-shadow-highlight ring-hairline",
} as const;

export type BreadcrumbListProps = React.ComponentProps<"ol"> & {
  variant?: keyof typeof listVariants;
};

export function BreadcrumbList({ variant = "plain", className, ...props }: BreadcrumbListProps) {
  return (
    <ol
      data-slot="breadcrumb-list"
      data-variant={variant}
      className={cn(
        "flex w-fit max-w-full flex-wrap items-center text-[13px] break-words text-muted-foreground",
        listVariants[variant],
        className,
      )}
      {...props}
    />
  );
}

export function BreadcrumbItem({ className, ...props }: React.ComponentProps<"li">) {
  return (
    <li
      data-slot="breadcrumb-item"
      className={cn("inline-flex min-w-0 items-center gap-1.5", className)}
      {...props}
    />
  );
}

export type BreadcrumbLinkProps = React.ComponentProps<"a"> & {
  /** Render the single child element (e.g. a router link) instead of an `<a>`. */
  asChild?: boolean;
};

export function BreadcrumbLink({ asChild = false, className, ...props }: BreadcrumbLinkProps) {
  const Comp = asChild ? Slot.Root : "a";
  return (
    <Comp
      data-slot="breadcrumb-link"
      className={cn(
        // A whisper of a tint on hover, a felt press, a loud focus ring.
        "inline-flex h-7 items-center gap-1.5 rounded-md px-1.5 whitespace-nowrap [&_svg]:size-3.5 [&_svg]:shrink-0",
        "transition-[background-color,color,transform] duration-(--motion-fast) ease-enter motion-reduce:transition-none",
        "hover:bg-muted hover:text-foreground active:scale-[0.97] motion-reduce:active:scale-100",
        "focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background focus-visible:outline-none",
        className,
      )}
      {...props}
    />
  );
}

export function BreadcrumbPage({ className, ...props }: React.ComponentProps<"span">) {
  // The current page is plain text marked with aria-current; it is not a link.
  return (
    <span
      data-slot="breadcrumb-page"
      aria-current="page"
      className={cn(
        "inline-flex h-7 items-center gap-1.5 px-1.5 font-medium text-foreground [&_svg]:size-3.5 [&_svg]:shrink-0",
        className,
      )}
      {...props}
    />
  );
}

function ChevronIcon() {
  return (
    <svg
      aria-hidden="true"
      viewBox="0 0 16 16"
      fill="none"
      stroke="currentColor"
      strokeWidth="1.5"
      strokeLinecap="round"
      strokeLinejoin="round"
      className="rtl:-scale-x-100"
    >
      <path d="M6.5 4 10 8l-3.5 4" />
    </svg>
  );
}

export function BreadcrumbSeparator({ children, className, ...props }: React.ComponentProps<"li">) {
  return (
    <li
      data-slot="breadcrumb-separator"
      role="presentation"
      aria-hidden="true"
      className={cn(
        "inline-flex items-center px-0.5 text-muted-foreground/60 [&>svg]:size-3.5",
        className,
      )}
      {...props}
    >
      {children ?? <ChevronIcon />}
    </li>
  );
}

export function BreadcrumbEllipsis({
  label = "More",
  className,
  ...props
}: React.ComponentProps<"span"> & {
  /** Text read by screen readers in place of the dots. */
  label?: string;
}) {
  return (
    <span
      data-slot="breadcrumb-ellipsis"
      className={cn("flex h-7 w-8 items-center justify-center rounded-md", className)}
      {...props}
    >
      <svg aria-hidden="true" viewBox="0 0 16 16" fill="currentColor" className="size-4">
        <circle cx="3.5" cy="8" r="1.1" />
        <circle cx="8" cy="8" r="1.1" />
        <circle cx="12.5" cy="8" r="1.1" />
      </svg>
      <span className="sr-only">{label}</span>
    </span>
  );
}
Pebble

Small details.
Better interfaces.

React components to explore, make your own, and build on.

Library

  • Components
  • Installation
  • Pricing

Resources

  • For agents
  • About
  • Support

Legal

  • License
  • Terms
  • Privacy
  • Final sale

Built by Pebble

A product of Praxys Solutions LLC ↗

Pebble Pro is live

$49 one time, lifetime updates ↗