Separator
A 1 px hairline between groups, horizontal or vertical, on Base UI.
Livestream
Go live to YouTube, Twitch and X at once.
StudioSourcesLibrary
Installation
$ pnpm dlx shadcn@latest add @videorc/separatorUsage
import { Separator } from "@/components/ui/separator";<Separator orientation="vertical" />Theming
| Token or attribute | Meaning |
|---|---|
bg-border | The hairline colour, never more than 1 px |
data-orientation | horizontal or vertical; a vertical one stretches to its row |
Accessibility
A separator is role="separator" with its aria-orientation, so a screen reader hears where one group ends. When a line is only decoration, draw a border-border hairline on the element instead.
API reference
Every Base UI Separator prop.