import React, { ReactNode } from 'react'; import { ModalProps } from '../modal'; import { ButtonProps } from '../button'; import { DrawerCloseReason } from '../drawer'; export type DialogCloseReason = DrawerCloseReason | 'canceled' | 'confirmed'; export interface DialogProps extends Omit { icon?: ReactNode; title?: ReactNode; footer?: ReactNode; prefix?: ReactNode; suffix?: ReactNode; /** 默认为`420` */ width?: string | number; minWidth?: string | number; /** 默认为`100%` */ maxWidth?: string | number; showClose?: boolean; closeProps?: ButtonProps; showConfirm?: boolean; confirmText?: ReactNode; confirmProps?: ButtonProps; onConfirm?(e: React.MouseEvent): any; confirmLoading?: boolean; showCancel?: boolean; cancelText?: ReactNode; cancelProps?: ButtonProps; onCancel?(e: React.MouseEvent | KeyboardEvent): void; /** * 滚动的行为,默认为`card` * @enum 'card' 卡片内部滚动 * @enum 'body' 对话框整体滚动 */ scrollBehavior?: 'card' | 'body'; draggable?: boolean; /** 是否可通过点击遮罩层关闭对话框,默认为`true` */ maskClosable?: boolean; /** 是否可通过键盘的【ESC】键关闭对话框,默认为`true` */ escapeClosable?: boolean; defaultOpen?: boolean; onClose?(closeReason: DialogCloseReason): void; } export declare function Dialog({ icon, title, footer, prefix, suffix, width, minWidth, maxWidth, showClose, closeProps, showConfirm, confirmText, confirmProps, onConfirm, confirmLoading, showCancel, cancelText, cancelProps, onCancel, scrollBehavior, draggable, maskClosable, escapeClosable, defaultOpen, open, onClose, ...props }: DialogProps): import("@emotion/react/jsx-runtime").JSX.Element;