Skip to main content
196

Search Lumen

Find components, APIs, guides, and recipes.

GitHub
Android docs
LayoutAndroid

Adaptive list detail scaffold

Arrange application-owned lists and details across phones, tablets, and foldable devices.

Public APILumenAdaptiveListDetailScaffoldAndroid / Compose

Native example

Use Adaptive list detail scaffold

Use as a full-window layout. Material adapts to window size and separating hinges. Save selection and pane state in the host; wire system BackHandler through detailOnly and apply screen content insets outside the scaffold.

Adaptive list detail scaffold rendered in the Android phone emulator Lumen playground
Captured exampleAndroid phone emulator
kotlin
LumenAdaptiveListDetailScaffold(
    selectedKey = selectedKey, onBack = { selectedKey = null },
    listLabel = "Projects", detailLabel = "Project details",
    listPane = { ProjectList(onSelect = { selectedKey = it }) },
    emptyDetail = { LumenEmptyState("Choose a project") }
) { key, detailOnly ->
    BackHandler(enabled = detailOnly) { selectedKey = null }
    ProjectDetails(key)
}

Reference

Public API

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

APIValues or typeDefaultDescription
selectedKey / onBackString? / () -> UnitRequiredControls selection; null prioritizes the list.
listLabel / detailLabel / backLabelStringRequired / Required / BackNames panes and compact navigation.
listPane / emptyDetail@Composable () -> UnitRequiredProvides native lists and wide-window empty detail.
detailPane@Composable (String, Boolean) -> UnitRequiredReceives the selected key and whether detail is the only visible pane.
modifierModifierModifierApplies full-window layout.

Native behavior

Design and accessibility

When to use it

Use as a full-window layout. Material adapts to window size and separating hinges. Save selection and pane state in the host; wire system BackHandler through detailOnly and apply screen content insets outside the scaffold.

Accessibility

Names both panes and exposes compact back navigation without owning application routing or selection.

Android docsCompose module