Skip to content

shadcn.io is not affiliated with official shadcn/ui

Shadcn Separator for React

Visually separate content with a line.

shadcn/ui
The Foundation for your Design System
A set of beautifully designed components that you can customize, extend, and build on.

Installation

bunx --bun shadcn@latest add https://kit.dev/r/radix/separator.json

Usage

import { Separator } from "@/components/ui/separator";
<div className="flex max-w-sm flex-col gap-4 text-sm">
  <div className="flex flex-col gap-1.5">
    <div className="font-medium leading-none">shadcn/ui</div>
    <div className="text-muted-foreground">
      The Foundation for your Design System
    </div>
  </div>
  <Separator />
  <div>
    A set of beautifully designed components that you can customize, extend,
    and build on.
  </div>
</div>

Demos

Vertical

Vertical separators between inline items.

Vertical separators between menu items with descriptions.

List

Horizontal separators between list items.

Rtl

Right-to-left separator. See the RTL configuration guide for document direction.

API Reference

Separator

PropType
AttributeType