Skip to main content
239

Search Lumen

Find components, APIs, guides, and recipes.

GitHub
Themes
Android docs
ActionsWear OS

Wearable action row

Trigger a compact, full-width action on watchOS and Wear OS.

Public APILumenWearActionRowWear OS / Compose

Wear OS availability

Use the dedicated Wear artifact

Add com.santi020k:lumen-compose-wear:6.0.0 to your Wear OS module and import this component from com.santi020k.lumen. Wrap content in LumenWearTheme, which defaults to dark appearance and uses LumenThemeScope for tokens, named themes, typography, shapes, and androidx.compose.material3.MaterialTheme roles. Your separate Wear Material provider remains application-owned. Wear UI primitives accept a Compose modifier with Modifier as its default.

The release plan targets this version; confirm Maven Central availability before pinning it.

Native example

Use Wearable action row

Use for a compact text action inside native watch scrolling containers. Keep navigation, persistence, and feedback in the application; leading content must be decorative.

Wearable action row rendered in the Wear OS emulator Lumen playground
Captured exampleWear OS emulator
kotlin
import androidx.compose.runtime.*
import com.santi020k.lumen.*

@Composable
fun WearActionExample() {
    var saved by remember { mutableStateOf(false) }
    LumenWearActionRow("Save session", onClick = { saved = true }, enabled = !saved)
}

Reference

Public API

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

APIValues or typeDefaultDescription
labelNative localized textRequiredNames the action.
onClickAction callbackRequiredRuns when enabled.
detailOptional native textnil / nullAdds wrapping supporting text.
enabledBooleantrueDisables interaction and exposes disabled state.
leadingOptional decorative viewEmptyView / nullAdds a supporting icon.

Native behavior

Design and accessibility

When to use it

Use for a compact text action inside native watch scrolling containers. Keep navigation, persistence, and feedback in the application; leading content must be decorative.

Accessibility

Provides one named button target with wrapping text and an exposed disabled state.

Shared component

Available on other platforms

Apple / SwiftUI
Android docsCompose module