> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cognite.com/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Cognite Data Fusion (CDF) is an industrial DataOps platform. Prefer English docs unless the user asks for another locale.
> Follow /_llms/ index links recursively until you reach page URLs ending in .md. Fetch those Markdown twins instead of HTML.
> For REST APIs, default to calendar version 20230101 (stable). Use 20230101-beta or 20230101-alpha only if the user is on a preview API. Cite paths under /api-reference/concepts/<version>/ and the Cdf-Version header. Prefer the Python SDK (cognite-sdk) unless the user is in JavaScript/TypeScript.
> Start here by task: platform overview /cdf/index.md; data modeling /cdf/dm/index.md; data integration /cdf/integration/index.md; access /cdf/access/index.md; CDF Toolkit /cdf/deploy/cdf_toolkit/index.md; REST quickstart /dev/quickstart.md; Python SDK /dev/sdks/python/index.md; Atlas AI /cdf/atlas_ai/concepts/index.md; Flows apps /cdf/flows/index.md; Aura UI /cdf/aura/index.md; MCP and IDE setup /dev/guides/ide_ai_integration.md.
> For implementation work, also load /skill.md.

# Alert dialog

> An Alert dialog is a modal dialog that appears when a user needs to confirm or take action on a specific issue before continuing.

<Badge color="orange">In progress</Badge> | *Storybook link coming soon*

## When to use

Alert dialogs are considered high-emphasis communication as these messages are more noticeable and disruptive. They should be used sparingly and only when user input is urgent or requires immediate action.

* **Critical decisions:** Confirming delete actions, submitting sensitive info.
* **Important messages:** System errors, security warnings that require user attention or input to dismiss.

## When to use something else

* **Non-blocking messages:** Use a [Sonner](/cdf/aura/primitives/sonner), [Banner](/cdf/aura/primitives/banner), or [Alert](/cdf/aura/primitives/alert) (depending on context) if you need to show messages or alerts that don't require immediate action.
* **In-line validation:** Use an [Input](/cdf/aura/primitives/input)'s inline validation to provide contextual and immediate feedback to the user.
* **Focused tasks:** Short forms, template selection, and quick settings adjustments. Use a [Dialog](/cdf/aura/primitives/dialog).
* **Secondary content:** Image zoom-ins, detailed information, video playback. Use a [Dialog](/cdf/aura/primitives/dialog).

## Alert dialog vs Dialog

A [Dialog](/cdf/aura/primitives/dialog) is a flexible, interactive modal used for routine tasks like editing forms, viewing detailed information, or completing multi-step workflows. An Alert dialog is an interruptive, high-priority modal specifically designed for critical or destructive decisions (such as deleting data), halting user workflow until an explicit choice is made.

| Feature / behavior       | Dialog                                                | Alert dialog                                                             |
| :----------------------- | :---------------------------------------------------- | :----------------------------------------------------------------------- |
| Primary purpose          | Standard workflows, forms, settings, and detail views | Destructive actions, system warnings, and data loss prevention           |
| ARIA role                | `role="dialog"`                                       | `role="alertdialog"`                                                     |
| Dismiss on overlay click | Yes (dismissible by clicking outside)                 | No (requires explicit button interaction)                                |
| Dismiss on Escape key    | Yes (closes immediately)                              | Configurable; typically disabled for critical actions                    |
| Initial focus target     | First interactive element or dialog container         | Safest element (typically the Cancel button)                             |
| Top-right close icon (X) | Standard; recommended                                 | Intentionally omitted to prevent accidental triggers                     |
| Required actions         | Flexible (Save, Submit, custom, or none)              | Mandatory explicit pair (`AlertDialogCancel` and `AlertDialogAction`)    |
| Screen reader behavior   | Announces dialog title and context                    | Interrupts speech queue to immediately announce alert and urgent message |
| Interaction flow         | Asynchronous (user can exit at any point)             | Synchronous checkpoint (must resolve before proceeding)                  |

## Behavior

* Alert dialogs should be used to confirm a destructive action or a warning or issue that requires immediate action.
* Alert dialogs should not disappear or close until the user has confirmed the action or dismissed the dialog.
* Alert dialogs should not be used to confirm an action that the user can resolve in a separate context.

## Often used with

Primary and secondary [Button](/cdf/aura/primitives/button) in the footer; optional [Separator](/cdf/aura/primitives/separator) when body scrolls; copy kept short—defer forms to [Dialog](/cdf/aura/primitives/dialog) when possible.

## Accessibility

* Focus trap and placement: Move initial focus to the least destructive action (e.g., "Cancel") upon open. Trap keyboard focus inside the overlay until dismissed.
* Semantics: Apply `role="alertdialog"` and link the container to title/description nodes using `aria-labelledby` and `aria-describedby`.
* Keyboard dismissal: Allow the Escape key to close non-critical dialogs, and ensure focus returns to the triggering element upon closure.
