Separator
adn-ui/separatorFreeComponent
A separator element accessible to screen readers.
Live preview
live · rendered by the registry
Rendered by adn-ui on their own page — this is the component running, not a screenshot of it.Install it
npx shadcn@latest add https://ui.awaiden.com/r/separator.jsonSource
1"use client";23import "./separator.css";4import { Separator as BaseSeparator } from "@base-ui/react/separator";5import type React from "react";6import { cn } from "tailwind-variants";78import { SeparatorContext } from "./separator.context";9import { separatorVariants, type SeparatorVariants } from "./separator.variants";1011export type SeparatorProps = SeparatorVariants & React.ComponentProps<typeof BaseSeparator>;1213export const SeparatorRoot = ({14 className,15 orientation = "horizontal",16 ...props17}: SeparatorProps) => {18 const slots = separatorVariants({ orientation });1920 return (21 <SeparatorContext.Provider value={{ slots }}>22 <BaseSeparator className={cn(slots.root(), className)} orientation={orientation} {...props} />23 </SeparatorContext.Provider>24 );25};2627export const Separator = SeparatorRoot;
What it pulls in
npm packages
Files it writes
More from adn-ui
All 46 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| Accordionaccordion | adn-ui | Components | Free | 2 deps · 5 files | |
| Alert Dialogalert-dialog | adn-ui | Components | Free | 2 deps · 5 files | |
| Aspect Ratioaspect-ratio | adn-ui | Components | Free | 1 dep · 5 files | |
| Autocompleteautocomplete | adn-ui | Components | Free | 2 deps · 5 files | |
| Avataravatar | adn-ui | Components | Free | 2 deps · 5 files | |
| Badgebadge | adn-ui | Components | Free | 1 dep · 5 files | |
| Breadcrumbbreadcrumb | adn-ui | Components | Free | 1 dep · 5 files | |
| Buttonbutton | adn-ui | Components | Free | 1 dep · 4 files |
