ScrollArea

fun UiScope.ScrollArea(state: ScrollState, modifier: Modifier = Modifier, key: ElementKey<*>? = null, scrollRate: Int = 9, content: UiScope.() -> Unit)(source)

Emits one profile-backed scroll viewport containing exactly one root. Primary content presses become taps on release or scrolling after the vertical drag threshold. Dragging continues outside the viewport, and explicitly timed frames advance decelerating momentum after release. Configure dragging and inertia through ScrollState.dragScroll; wheel input and independent scrollbars are unaffected.

Receiver

active owner-thread screen scope.

Parameters

modifier

active behavior applied to the viewport.

key

optional stable sibling identity.

scrollRate

positive logical wheel displacement multiplier.

content

callback that must emit exactly one content root.

Throws

when scrollRate is not positive or content does not emit exactly one root.

when no runtime screen evaluation is active.