Skip to main content

Examples

  • Basic Dividers
  • Labeled Dividers

Dividers automatically adapt to horizontal and vertical layouts.

Column(
  children: [
    Text("Above"),
    Gap(theme.spacings.medium),
    NeoDivider(),
    Gap(theme.spacings.medium),
    Text("Below"),
  ],
),

Properties

Content

label
String
Optional text label displayed in the center of the divider. Useful for semantic separation or indicating transitions between content sections.

Styling

color
Color
default:"theme.colors.borderTertiary"
The color of the divider line.

Best Practices

  • Semantic Separation: Use dividers to create logical groupings and improve content hierarchy
  • Label Usage: Use the label property to provide context for content transitions (e.g., “Settings”, “OR”, “Advanced Options”)
  • Spacing: Combine with appropriate padding or margins for optimal visual balance

Integration Notes

  • Layout Detection: The widget automatically inspects its parent widget tree to determine orientation. If placed inside a Column, it renders horizontally; if inside a Row, it renders vertically.
  • Border Radius: Uses theme.radii.full for fully rounded edge caps in the default theme. Can be customized through the theming system.
I