Skip to main content
161

Search Lumen

Find components, APIs, guides, and recipes.

GitHub
React Native docs
FeedbackReact Native

Alert dialog

Request a controlled native confirmation with explicit cancel and confirm states.

Public APILumenAlertDialogReact Native

Native example

Use Alert dialog

Use for short consequential confirmations. Keep visibility and mutation state in the application and reserve destructive styling for irreversible or difficult-to-recover actions.

View verified React Native runtime capture
Alert dialog rendered in the Expo web renderer Lumen playground
Verified runtime captureExpo web renderer
tsx
<LumenAlertDialog
  visible={showConfirmation}
  title="Delete report?"
  confirmLabel="Delete"
  destructive
  onConfirm={deleteReport}
  onDismiss={() => setShowConfirmation(false)}
/>

Reference

Public API

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

APIValues or typeDefaultDescription
visiblebooleanRequiredControls native modal presentation.
title / descriptionNative localized textDescription optionalExplains the decision.
confirmLabel / cancelLabelNative localized textCancel label: CancelNames both actions.
destructivebooleanfalseCommunicates whether the confirm action is destructive.
confirmDisabledbooleanfalseControls whether the confirm action can be activated.
confirmLoadingbooleanfalseCommunicates asynchronous confirmation progress.

Native behavior

Design and accessibility

When to use it

Use for short consequential confirmations. Keep visibility and mutation state in the application and reserve destructive styling for irreversible or difficult-to-recover actions.

Accessibility

Native modal focus stays inside the confirmation surface and cancel and confirm remain independently named actions.

Shared component

Available on other platforms

Apple / SwiftUIAndroid / Compose
React Native docsNative primitives