Duostrap Separator
A horizontal or vertical one-pixel family-border divider over Base Separator.
Duostrap Separator uses a one-pixel divider paired with the family border palette in light and dark themes, while Base Separator manages orientation and decorative accessibility semantics. This is a simplified palette-derived extension of the archived divider grammar.
Preview
Section titled “Preview” Web Components React Vue Vue 2
Loading interactive preview… The article and source are ready to read. Interactive controls will appear here when ready.
<div
class="flex w-full max-w-sm flex-col gap-4 rounded border border-[#e3e3e3] bg-[#f5f5f5] p-4 text-sm text-[#333333]"
>
<div class="flex flex-col gap-1.5">
<div class="leading-none font-bold">Proto UI</div>
<div class="text-[#666666]">
The foundation for your design system.
</div>
</div>
<wc-duostrap-separator-root></wc-duostrap-separator-root>
<div>
A set of portable component protocols that you can customize,
extend, and build on.
</div>
</div>Installation
Section titled “Installation”Available starting in 0.3.0-rc.1 and later releases. Import separatorRoot from @proto.ui/prototypes-duostrap/separator. Browse the implemented subset.
import { separatorRoot } from '@proto.ui/prototypes-duostrap/separator';import { BootstrapSeparatorRoot } from '../proto-ui/components/react';<BootstrapSeparatorRoot />- Family-border rule: Horizontal rules are
1pxhigh; vertical rules are1pxwide and stretch automatically across flex containers (self-stretch). Both use the family border color. - Decorative vs. semantic: Decorative separators (
decorative={true}, default) stay hidden from the accessibility tree. Passdecorative={false}to exposerole="separator"andaria-orientation. - Layout: Separator is contentless and passive with no built-in margin; length and spacing belong to the surrounding container.
Examples
Section titled “Examples”Vertical
Section titled “Vertical” Web Components React Vue Vue 2
Loading interactive preview… The article and source are ready to read. Interactive controls will appear here when ready.
<div
class="flex h-9 items-center gap-4 rounded border border-[#e3e3e3] bg-[#f5f5f5] px-4 py-2 text-sm text-[#333333]"
>
<div>Blog</div>
<wc-duostrap-separator-root
orientation="vertical"
></wc-duostrap-separator-root>
<div>Docs</div>
<wc-duostrap-separator-root
orientation="vertical"
></wc-duostrap-separator-root>
<div>Source</div>
</div> Web Components React Vue Vue 2
Loading interactive preview… The article and source are ready to read. Interactive controls will appear here when ready.
<div
class="flex items-center gap-3 rounded border border-[#e3e3e3] bg-[#f5f5f5] px-4 py-3 text-sm text-[#333333] md:gap-4"
>
<div class="flex flex-col gap-1">
<span class="font-bold">Settings</span>
<span class="text-xs text-[#666666]">Manage preferences</span>
</div>
<wc-duostrap-separator-root
orientation="vertical"
></wc-duostrap-separator-root>
<div class="flex flex-col gap-1">
<span class="font-bold">Account</span>
<span class="text-xs text-[#666666]">
Profile & security
</span>
</div>
<wc-duostrap-separator-root
orientation="vertical"
class="hidden md:block"
></wc-duostrap-separator-root>
<div class="hidden flex-col gap-1 md:flex">
<span class="font-bold">Help</span>
<span class="text-xs text-[#666666]">Support & docs</span>
</div>
</div> Web Components React Vue Vue 2
Loading interactive preview… The article and source are ready to read. Interactive controls will appear here when ready.
<div
class="flex w-full max-w-sm flex-col gap-2.5 rounded border border-[#e3e3e3] bg-[#f5f5f5] p-4 text-sm text-[#333333]"
>
<div class="flex items-center justify-between">
<span>Item 1</span>
<span class="text-[#666666]">Value 1</span>
</div>
<wc-duostrap-separator-root
decorative="false"
></wc-duostrap-separator-root>
<div class="flex items-center justify-between">
<span>Item 2</span>
<span class="text-[#666666]">Value 2</span>
</div>
<wc-duostrap-separator-root
decorative="false"
></wc-duostrap-separator-root>
<div class="flex items-center justify-between">
<span>Item 3</span>
<span class="text-[#666666]">Value 3</span>
</div>
</div> Web Components React Vue Vue 2
Loading interactive preview… The article and source are ready to read. Interactive controls will appear here when ready.
<div
dir="rtl"
class="flex w-full max-w-sm flex-col gap-4 rounded border border-[#e3e3e3] bg-[#f5f5f5] p-4 text-sm text-[#333333]"
>
<div class="flex flex-col gap-1.5">
<div class="leading-none font-bold">Proto UI</div>
<div class="text-[#666666]">الأساس لنظام التصميم الخاص بك</div>
</div>
<wc-duostrap-separator-root></wc-duostrap-separator-root>
<div>
مجموعة من المكونات القابلة للتخصيص والتوسيع والبناء عليها.
</div>
</div>The following props belong to Root:
| Prop | Type | Default | Description |
|---|---|---|---|
orientation | 'horizontal' 'vertical' | 'horizontal' | Divider orientation |
decorative | boolean | true | Set false to expose semantic role="separator" and aria-orientation |
Exposes read-only orientation and decorative states with no focus or interaction channel.