When to use it
Wrap the existing scrollable content. Keep requests, cancellation, retry policy, and completion in application code. Disabled state removes gestures while an already-running host operation retains feedback.
Refresh existing scrollable content with native gestures and accessible progress.
Native example
Wrap the existing scrollable content. Keep requests, cancellation, retry policy, and completion in application code. Disabled state removes gestures while an already-running host operation retains feedback.
LumenPullToRefresh(
isRefreshing = refreshing,
onRefresh = ::refreshProjects,
refreshLabel = "Refresh projects",
refreshingLabel = "Refreshing projects"
) {
LazyColumn { /* application-owned rows */ }
}Reference
The primary shared and platform-specific options exposed by LumenPullToRefresh.
| API | Values or type | Default | Description |
|---|---|---|---|
| isRefreshing / onRefresh | Boolean / () -> Unit | Required | Controls progress and starts application-owned refresh work. |
| modifier | Modifier | Modifier | Applies container layout and accessibility. |
| enabled | Boolean | true | Enables the refresh gesture and accessible action when idle. |
| refreshLabel / refreshingLabel | String | Refresh / Refreshing | Localizes the action and progress state. |
| content | @Composable BoxScope.() -> Unit | Required | Renders application-owned scrolling content. |
Native behavior
Wrap the existing scrollable content. Keep requests, cancellation, retry policy, and completion in application code. Disabled state removes gestures while an already-running host operation retains feedback.
Provides a named refresh accessibility action alongside the native gesture, announces progress, and removes refresh actions while disabled or busy.