Components

Divider

The divider component creates a visual separator to structure content in your layout.

Usage

The divider component is used to create a simple visual separation between elements.

Coffee Catch-up?

Hi Rachel, Hope you’re doing well! Are you free for a quick coffee catch-up later this week? It’s been a while, and I’d love to catch up on things.


Welcome to the Team!

Hey Sarah, Welcome aboard! We’re excited to have you with us. Let me know if you need anything while settling in. Looking forward to working together!

<div class="max-w-sm grid gap-4 p-6 rounded-large bg-background ring ring-default-900/10">
    <div class="flex gap-4">
        <LumexAvatar Name="Rachel Green" Class="shrink-0" />
        <div class="space-y-1">
            <h4 class="font-semibold text-small">Coffee Catch-up?</h4>
            <p class="text-small text-foreground-500 line-clamp-2">
                Hi Rachel,
                Hope you’re doing well! Are you free for a quick coffee catch-up later this week?
                It’s been a while, and I’d love to catch up on things.
            </p>
        </div>
    </div>
    <LumexDivider />
    <div class="flex gap-4">
        <LumexAvatar Name="Sarah Salvatore" Class="shrink-0" />
        <div class="space-y-1">
            <h4 class="font-semibold text-small">Welcome to the Team!</h4>
            <p class="text-small text-foreground-500 line-clamp-2">
                Hey Sarah,
                Welcome aboard! We’re excited to have you with us. 
                Let me know if you need anything while settling in. 
                Looking forward to working together!
            </p>
        </div>
    </div>
</div>

Orientation

The divider component supports both horizontal and vertical orientations. You can switch it to vertical when needed to separate content vertically. Use the Orientation parameter.

@using LumexUI.Shared.Icons

<div class="flex h-8 px-2 py-1 space-x-2 items-center bg-background ring ring-default-900/10 rounded-sm">
    <AlignLeftIcon Size="20" />
    <AlignCenterIcon Size="20" />
    <AlignRightIcon Size="20" />
    <LumexDivider Orientation="@Orientation.Vertical" />
    <BoldIcon Size="20" />
</div>

Custom Styles

You can customize the divider component by passing any Tailwind CSS classes to the component's Class and/or Style parameters.

  • World
  • Economics
  • Sports
  • Art
  • Breaking News
<ul class="flex h-10 p-1 space-x-4 items-center">
    <li>World</li>
    <LumexDivider Orientation="@Orientation.Vertical" />
    <li>Economics</li>
    <LumexDivider Orientation="@Orientation.Vertical" />
    <li>Sports</li>
    <LumexDivider Orientation="@Orientation.Vertical" />
    <li>Art</li>
    <LumexDivider Orientation="@Orientation.Vertical"
                  Class="w-0.5"
                  Style="--lumex-divider: var(--lumex-danger); --lumex-opacity-divider: 50%" />
    <li class="font-medium text-danger">Breaking News</li>
</ul>

API

See the API references below for a complete guide to all the parameters available for the components mentioned here.

An unhandled error has occurred. Reload 🗙