import type { CSSProperties, ReactNode } from 'react'; import type { DialogSize } from '../Dialog/index.cjs'; import type { ButtonColor } from '../Button/index.cjs'; import type { SxProp } from '../Layout/sx.cjs'; export interface ConfirmDialogProps { /** Controlled open state. */ open: boolean; /** Called with the next open state (e.g. on Esc, backdrop, or cancel). */ onOpenChange: (open: boolean) => void; /** Dialog heading. */ title: ReactNode; /** Body copy. Ignored when `children` is provided. */ message?: ReactNode; /** Custom body; overrides `message`. */ children?: ReactNode; /** Confirm button label. Default `'Confirm'`. */ confirmLabel?: string; /** Cancel button label. Default `'Cancel'`. */ cancelLabel?: string; /** Render the confirm button in the danger color. Shorthand for `color="danger"`. */ danger?: boolean; /** Confirm button colour (`primary` | `danger` | `warning` | `success` | `info`). Wins over `danger`. Default: `primary`. */ color?: ButtonColor; /** Show a spinner on confirm and disable both buttons. */ loading?: boolean; /** * Type-to-confirm: the confirm button stays disabled until the user types * this exact text. Use for destructive actions (e.g. the resource name). */ requireText?: string; /** Fired when the confirm button is clicked. */ onConfirm: () => void; /** Fired when the cancel button is clicked (before close). */ onCancel?: () => void; /** Hide the X close button (the dialog then closes via Cancel / Confirm, Esc and outside click unless disabled below). */ hideClose?: boolean; /** Close on Esc (as Cancel). Default: true. */ closeOnEscape?: boolean; /** Close on an outside / backdrop click (as Cancel). Default: true. */ closeOnOutsideClick?: boolean; /** Width preset. Default: `sm`. */ size?: DialogSize; className?: string; /** Inline style forwarded to the underlying Dialog content panel. */ style?: CSSProperties; /** * One-off CSS forwarded to the underlying Dialog content panel, same as * `Box`'s `sx`: each value may be a scalar or a responsive breakpoint map * (`{ base, sm, md, lg, xl }`). Scalar-only sx merges into inline style; * responsive sx injects a scoped class. */ sx?: SxProp; } /** * ConfirmDialog — a small Dialog preset for destructive / confirmation prompts. * Composes the base `Dialog` and `Button`. */ export declare function ConfirmDialog({ open, onOpenChange, title, message, children, confirmLabel, cancelLabel, danger, color, loading, requireText, onConfirm, onCancel, hideClose, closeOnEscape, closeOnOutsideClick, size, className, style, sx, }: ConfirmDialogProps): import("react/jsx-runtime").JSX.Element;