PhoenixDuskmoon.Component.Layout.Divider (PhoenixDuskmoon v9.0.1)

View Source

Divider component for separating content sections.

This is a HEEX component using CSS custom properties from the theme.

Examples

<.dm_divider />

<.dm_divider>Section Title</.dm_divider>

<.dm_divider orientation="vertical" />

<.dm_divider variant="primary" style="dashed">
  Settings
</.dm_divider>

<.dm_divider size="lg" variant="primary" />

Attributes

  • orientation - Divider orientation: horizontal, vertical (default: horizontal)
  • variant - Divider color variant: base, primary, secondary, light, dark (default: base)
  • style - Divider line style: solid, dashed, dotted (default: solid)
  • size - Divider thickness: xs, sm, md, lg (default: md)
  • class - Additional CSS classes

Slots

  • :inner_block - Optional content to display in the divider

Summary

Functions

Renders a divider for separating content sections.

Functions

dm_divider(assigns)

Renders a divider for separating content sections.

Examples

<.dm_divider />
<.dm_divider orientation="vertical" />
<.dm_divider variant="primary">Section</.dm_divider>

Attributes

  • orientation (:string) - divider orientation. Defaults to "horizontal". Must be one of "horizontal", or "vertical".
  • variant (:string) - divider color variant. Defaults to "base". Must be one of "base", "primary", "secondary", "light", or "dark".
  • style (:string) - line style. Defaults to "solid". Must be one of "solid", "dashed", or "dotted".
  • size (:string) - divider spacing size. Defaults to "md". Must be one of "xs", "sm", "md", "lg", or "xl".
  • gradient (:boolean) - use gradient divider style. Defaults to false.
  • inset (:string) - inset the divider from edges. Defaults to nil. Must be one of nil, "left", "right", or "both".
  • text_position (:string) - position of text content within the divider. Defaults to nil. Must be one of nil, "left", or "right".
  • class (:any) - additional CSS classes. Defaults to nil.
  • Global attributes are accepted.

Slots

  • inner_block - optional text content displayed within the divider.