/** * @fileoverview AlertDialog — modal confirmation dialog with a Motion spring entry animation and backdrop fade. * @module packages/ui/components/ui/alert-dialog * @layer core * * Self-contained implementation built on Radix AlertDialog primitive with * Motion transitions. Overlay and content animations respect both the user's * reduced-motion preference and the resolved `animated` design-system axis. * Action and cancel buttons inherit the Saasflare button variant system. * * @component * @example * import { AlertDialog, AlertDialogTrigger, AlertDialogContent, AlertDialogHeader, AlertDialogTitle, AlertDialogAction, AlertDialogCancel } from "@saasflare/ui"; * * * * * Are you sure? * Cancel * Confirm * * */ import * as React from "react"; import * as AlertDialogPrimitive from "@radix-ui/react-alert-dialog"; import { type SaasflareComponentProps } from "../../providers"; /** * Root of the alert dialog. Controls open/close state for its trigger, overlay, * and content. Use for destructive or otherwise irreversible confirmations. */ declare function AlertDialog({ ...props }: React.ComponentProps): import("react/jsx-runtime").JSX.Element; /** Element that opens the alert dialog when activated. Use `asChild` to wrap a custom control. */ declare function AlertDialogTrigger({ ...props }: React.ComponentProps): import("react/jsx-runtime").JSX.Element; /** Portals the overlay and content into the document body, escaping overflow/stacking contexts. */ declare function AlertDialogPortal({ ...props }: React.ComponentProps): import("react/jsx-runtime").JSX.Element; /** * Blurred backdrop rendered behind the dialog content. Honors the resolved * `animated` axis via the `data-animated` attribute forwarded from * {@link AlertDialogContent}, so its fade is neutralized when motion is disabled. */ declare function AlertDialogOverlay({ className, ...props }: React.ComponentProps): import("react/jsx-runtime").JSX.Element; /** * Props for {@link AlertDialogContent}. * * Extends the Radix AlertDialog content props with * {@link SaasflareComponentProps} so the design-system axes * (surface/radius/animated/iconWeight) can be supplied per-instance or * inherited from the provider. */ interface AlertDialogContentProps extends Omit, keyof SaasflareComponentProps>, SaasflareComponentProps { } /** * Centered dialog surface. The visible centerpiece of the alert dialog; resolves * the `surface`, `radius`, and `animated` design-system axes and emits the * matching `data-*` attributes on its root. The spring entry animation is gated * on the resolved `animated` axis (and reduced-motion preference). * * @example * * * * * Delete project? * This action cannot be undone. * * * Cancel * Delete * * * */ declare function AlertDialogContent({ className, children, surface, radius, animated, iconWeight, ...props }: AlertDialogContentProps): import("react/jsx-runtime").JSX.Element; /** Layout slot for the dialog title and description; stacks centered on mobile, left-aligned on `sm+`. */ declare function AlertDialogHeader({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element; /** Layout slot for the action buttons; stacks reversed on mobile, right-aligned in a row on `sm+`. */ declare function AlertDialogFooter({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element; /** Accessible title of the dialog, announced to assistive technology on open. */ declare function AlertDialogTitle({ className, ...props }: React.ComponentProps): import("react/jsx-runtime").JSX.Element; /** Supporting description of the dialog, linked as the accessible description of the content. */ declare function AlertDialogDescription({ className, ...props }: React.ComponentProps): import("react/jsx-runtime").JSX.Element; /** Primary confirm button; closes the dialog and runs the destructive action. Styled with the solid button variant. */ declare function AlertDialogAction({ className, ...props }: React.ComponentProps): import("react/jsx-runtime").JSX.Element; /** Dismiss button; closes the dialog without running the action. Styled with the outline button variant. */ declare function AlertDialogCancel({ className, ...props }: React.ComponentProps): import("react/jsx-runtime").JSX.Element; export { AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, type AlertDialogContentProps, };