Display UI

Separator

A simple line or divider used to visually separate groups of content or UI elements.

Default separator


Success separator


Danger separator

Installation

npx shadcn@latest add https://display-ui.vercel.app/r/Separator

Usage

import { Separator } from "@/components/display-ui/Separator"
<Separator />

API

Separator Props

For Separator Component

AttributeTypeDescriptionDefault
variant"default" | "danger" | "success"Controls the color style of the separator."default"
size"sm" | "md" | "lg"Controls the vertical spacing around the separator."md"
orientation"horizontal" | "vertical"Controls whether the separator is horizontal or vertical."horizontal"
decorativebooleanWhen true, renders the separator as decorative only without accessibility semantics.false
classNamestringAdditional CSS classes to customize the separator styling.-

Examples

Horizontal

OR

Vertical

OR

Credits

This component is inspired by Rehman Kalawant Design Shared On Github.

On this page