PreferenceCenterContent

fun PreferenceCenterContent(identifier: String, modifier: Modifier = Modifier, contentPadding: PaddingValues = PaddingValues(0.dp))(source)

Preference Center content.

The content adapts to the height it is given:

  • When measured with a bounded height (a full screen, or a Modifier.height/heightIn applied by the caller), the list scrolls internally and only composes the visible items.

  • When measured with an unbounded height (inside a Modifier.verticalScroll parent, a lazy list item, or a host that wraps its content such as a Thomas custom view sized height: auto), the content wraps to its full height and does not scroll. Scrolling is then the responsibility of the surrounding container, which must be scrollable to reach content that overflows the viewport.

Inside a scrolling View host, such as a NestedScrollView or a Thomas scroll_layout, the content must be measured with an unbounded height — for a Thomas custom view, size it height: auto. A bounded height inside a scrolling host is not supported: the host claims the vertical drag as soon as it crosses touch slop, so the list's own scrolling can never be reached.

Parameters

identifier

The preference center identifier.

modifier

The modifier to be applied to the content.

contentPadding

Optional padding to be applied to the content.


fun PreferenceCenterContent(state: PreferenceCenterState, modifier: Modifier = Modifier, contentPadding: PaddingValues = PaddingValues(0.dp))(source)

Preference Center content.

The content adapts to the height it is given:

  • When measured with a bounded height (a full screen, or a Modifier.height/heightIn applied by the caller), the list scrolls internally and only composes the visible items.

  • When measured with an unbounded height (inside a Modifier.verticalScroll parent, a lazy list item, or a host that wraps its content such as a Thomas custom view sized height: auto), the content wraps to its full height and does not scroll. Scrolling is then the responsibility of the surrounding container, which must be scrollable to reach content that overflows the viewport.

Inside a scrolling View host, such as a NestedScrollView or a Thomas scroll_layout, the content must be measured with an unbounded height — for a Thomas custom view, size it height: auto. A bounded height inside a scrolling host is not supported: the host claims the vertical drag as soon as it crosses touch slop, so the list's own scrolling can never be reached.

Parameters

state

The preference center state.

modifier

The modifier to be applied to the content.

contentPadding

Optional padding to be applied to the content.