import { PureComponent, ReactNode } from 'react'; declare type DialogType = 'success' | 'warn' | 'error'; declare type DialogStyle = 'wide' | 'auto' | 'jumbo' | 'narrow'; interface DialogTheme { readonly 'dialog': string; readonly 'dialog__body': string; readonly 'dialog__contentsPosition': string; readonly 'dialog__contents': string; readonly 'dialog__title': string; readonly 'dialog__closeBtn': string; readonly 'dialog__actions': string; readonly 'dialog--wide': string; readonly 'dialog--auto': string; readonly 'dialog--jumbo': string; readonly 'dialog--narrow': string; readonly 'dialog--success': string; readonly 'dialog--warn': string; readonly 'dialog--error': string; readonly 'dialog--effect__shake': string; } export interface DialogProps { /** * An optional `id` to attach to the wrapper. */ readonly id?: string; /** * This prop controls the rendered state of the Dialog, when falsy, nothing gets rendered into the DOM. */ readonly isOpen: boolean; /** * An optional handler, which gets called once the user clicks outside the dialog to close it or presses the escape key. If preventClosing is set the dialog will never be requested to be closed. */ readonly onRequestClose?: () => void; /** * An optional boolean flag to keep the dialog open when clicking outside or pressing the escape key. */ readonly preventClosing?: boolean; /** * The title to be rendered on top of the Dialogs contents. */ readonly title: ReactNode; /** * The `type` prop defines the type of the `Dialog`. */ readonly type?: DialogType; /** * The `style` prop defines the visual style of the `Dialog`. * Set to "wide" by default. */ readonly style?: DialogStyle; /** * The contents to be rendered within the Dialog. */ readonly children: ReactNode; /** * An Array of nodes(e.g. Action Buttons) which are placed at the bottom of the Dialog. */ readonly actions: ReadonlyArray; /** * This prop controls the focus state of the Dialog. */ readonly autoFocus: boolean; /** * An optional `className` to attach to the wrapper. */ readonly className?: string; /** * An optional `contentsClassName` to attach to the content area of the dialog. */ readonly contentsClassName?: string; /** * An optional css theme to be injected. */ readonly theme?: DialogTheme; } declare class DialogWithOverlay extends PureComponent { private ref?; private dialog; state: Readonly<{ isShaking: boolean; }>; private startShaking; renderDialogWithoutOverlay(): JSX.Element; private readonly handleReference; readonly componentDidMount: () => void; readonly componentWillUnmount: () => void; render(): JSX.Element | null; private readonly handleOverlayClick; } export default DialogWithOverlay;