Registry Index

Search the catalog

Type to search items across every indexed registry, or pick a page.

ComponentReactregistry:ui3 dependencies

ConfirmButton

confirm-button

Tap-again-to-confirm button for a destructive or disruptive action, with the armed state announced to assistive tech.

Live, loading

Starting the live preview…

Runs in a sandboxed frame on a separate origin, in its registry's own theme. Mounted with no props — an item that paints an empty box is given its name as text, and some items need input to show anything.

Notes from the author

Use ConfirmButton for an inline destructive action where a modal would be heavy: delete a row, clear data, reset a setting. The first tap arms it and the second commits. Keep the confirm label explicit about what is about to happen. Pass controlled armed/onArmedChange when sibling actions must be mutually exclusive. It is `destructive` by default; pass `variant` for an action that is disruptive rather than destructive -- signing out earns the same guard while red would overstate it. `label` takes a node, so a button that carried an icon keeps it.
1 other registry

Similar components

Other registries' take on confirm-button.

@whiskeyjack

More from @whiskeyjack