Glass Breadcrumb
washiveil/glass-breadcrumbFreeComponent
Breadcrumb trail in the quiet text register.
Install it
npx shadcn@latest add https://washiveil.alexchih.com/r/glass-breadcrumb.jsonSource
1import * as React from 'react';2import { Slot } from 'radix-ui';3import { ChevronRight, MoreHorizontal } from 'lucide-react';45import { cn } from '@/lib/utils';67function GlassBreadcrumb({ ...props }: React.ComponentProps<'nav'>) {8 return <nav aria-label="breadcrumb" {...props} />;9}1011function GlassBreadcrumbList({ className, ...props }: React.ComponentProps<'ol'>) {12 return (13 <ol14 className={cn('flex flex-wrap items-center gap-1.5 text-sm text-muted-foreground', className)}15 {...props}16 />17 );18}1920function GlassBreadcrumbItem({ className, ...props }: React.ComponentProps<'li'>) {21 return <li className={cn('inline-flex items-center gap-1.5', className)} {...props} />;22}2324interface GlassBreadcrumbLinkProps extends React.ComponentProps<'a'> {25 asChild?: boolean;26}2728function GlassBreadcrumbLink({ asChild, className, ...props }: GlassBreadcrumbLinkProps) {29 const Comp = asChild ? Slot.Root : 'a';30 return (31 <Comp32 className={cn('transition-colors hover:text-ruri dark:hover:text-ruri-soft', className)}33 {...props}34 />35 );36}3738function GlassBreadcrumbPage({ className, ...props }: React.ComponentProps<'span'>) {39 return (40 <span41 role="link"42 aria-disabled="true"43 aria-current="page"44 className={cn('text-foreground', className)}45 {...props}46 />47 );48}4950function GlassBreadcrumbSeparator({ children, className, ...props }: React.ComponentProps<'li'>) {51 return (52 <li role="presentation" aria-hidden="true" className={cn('[&>svg]:size-3.5', className)} {...props}>53 {children ?? <ChevronRight className="text-faint" />}54 </li>55 );56}5758function GlassBreadcrumbEllipsis({ className, ...props }: React.ComponentProps<'span'>) {59 return (60 <span61 className={cn('grid size-9 place-items-center', className)}62 {...props}63 >64 <MoreHorizontal className="size-4 text-faint" />65 <span className="sr-only">More</span>66 </span>67 );68}6970export {71 GlassBreadcrumb,72 GlassBreadcrumbList,73 GlassBreadcrumbItem,74 GlassBreadcrumbLink,75 GlassBreadcrumbPage,76 GlassBreadcrumbSeparator,77 GlassBreadcrumbEllipsis,78};
What it pulls in
npm packages
Other registry items
Files it writes
More from washiveil
All 58 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| Ambient Fieldambient-field | washiveil | Components | Free | no deps | |
| Chipchip | washiveil | Components | Free | 1 dep | |
| Code Badgecode-badge | washiveil | Components | Free | no deps | |
| Glass Accordionglass-accordion | washiveil | Components | Free | 2 deps | |
| Glass Alertglass-alert | washiveil | Components | Free | 1 dep | |
| Glass Alert Dialogglass-alert-dialog | washiveil | Components | Free | 1 dep | |
| Glass Aspect Ratioglass-aspect-ratio | washiveil | Components | Free | 1 dep | |
| Glass Avatarglass-avatar | washiveil | Components | Free | 1 dep |
