Skip to main content
161

Search Lumen

Find components, APIs, guides, and recipes.

GitHub
Android docs
ActionsAndroid

Button

Run native actions with shared intent, size, loading, and disabled contracts.

Public APILumenButtonAndroid / Compose

Native example

Use Button

Use primary sparingly for the main action, secondary for alternatives, quiet for low-emphasis actions, and danger for destructive operations.

Button rendered in the Android phone emulator Lumen playground
Verified runtime captureAndroid phone emulator
kotlin
LumenButton(
    onClick = ::continueFlow,
    intent = LumenButtonIntent.Primary
) {
    Text("Continue")
}

Reference

Public API

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

APIValues or typeDefaultDescription
onClickCallbackRequiredRuns the button action.
intentprimary · secondary · quiet · dangerprimarySelects semantic emphasis.
sizesm · md · lgmdSelects shared control height and padding.
loadingBooleanfalseShows native progress and prevents activation.
enabledBooleantrueControls native disabled state.
contentNative contentRequiredProvides the visible button label.

Native behavior

Design and accessibility

When to use it

Use primary sparingly for the main action, secondary for alternatives, quiet for low-emphasis actions, and danger for destructive operations.

Accessibility

Disabled and loading buttons expose native state and cannot trigger their action. The visible label supplies the accessible name.

Shared component

Available on other platforms

React NativeApple / SwiftUI
Android docsCompose module