full-width-divider
efferd-/full-width-dividerFreeComponent
Full-width divider component.
Live preview
live · rendered by the registry
Rendered by efferd on their own page — this is the component running, not a screenshot of it.Install it
npx shadcn@latest add http://efferd.com/r/full-width-divider.jsonSource
1import { cn } from "@/lib/utils";23type FullWidthDividerProps = React.ComponentProps<"div"> & {4 contained?: boolean;5 position?: "top" | "bottom";6};78export function FullWidthDivider({9 className,10 contained = false,11 position,12 ...props13}: FullWidthDividerProps) {14 return (15 <div16 aria-hidden="true"17 className={cn(18 "pointer-events-none absolute h-px bg-border",19 // full-bleed (default)20 "data-[contained=false]:left-1/2 data-[contained=false]:w-screen data-[contained=false]:-translate-x-1/2",21 // contained22 "data-[contained=true]:inset-x-0 data-[contained=true]:w-full",23 // position24 position &&25 "data-[position=top]:-top-px data-[position=bottom]:-bottom-px",26 className27 )}28 data-contained={contained}29 data-position={position}30 {...props}31 />32 );33}
Files it writes
More from efferd
All 201 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| apple-iconapple-icon | efferd | Components | Free | no deps | |
| auth-dividerauth-divider | efferd | Components | Free | no deps | |
| copy-buttoncopy-button | efferd | Components | Free | no deps | |
| decor-icondecor-icon | efferd | Components | Free | no deps | |
| discord-icondiscord-icon | efferd | Components | Free | no deps | |
| facebook-iconfacebook-icon | efferd | Components | Free | no deps | |
| figma-iconfigma-icon | efferd | Components | Free | no deps | |
| formaterformater | efferd | Components | Free | no deps |
