Skip to main content
161

Search Lumen

Find components, APIs, guides, and recipes.

GitHub
Apple docs
LayoutApple

Divider

Separate related native content with the shared semantic line role.

Public APILumenDividerApple / SwiftUISwift product: LumenUI

Apple availability

Supported native targets

Import LumenUI in the target that uses this component. iPad support follows the iOS package baseline and uses native iPad layout behavior.

iPhone · iOS 16+iPad · iPadOS 16+Mac · macOS 13+Apple TV · tvOS 16+Apple Vision · visionOS 1+Apple Watch · watchOS 9+

Native example

Use Divider

Use a divider only when spacing and grouping are insufficient to communicate a boundary. Avoid creating dense grids of lines.

Divider rendered in the iPhone simulator Lumen playground
Verified runtime captureiPhone simulator
swift
LumenDivider()

Reference

Public API

The primary shared and platform-specific options exposed by LumenDivider.

APIValues or typeDefaultDescription
SwiftUI modifiersNative layout APIControls placement and length.
colorSemantic line rolelineUses the generated divider color.

Native behavior

Design and accessibility

When to use it

Use a divider only when spacing and grouping are insufficient to communicate a boundary. Avoid creating dense grids of lines.

Accessibility

The divider is decorative and is hidden from assistive technology.

Shared component

Available on other platforms

React NativeAndroid / Compose
Apple docsSwiftUI package