import { ReactElement } from 'react'; import { IconName } from '../Icon'; import { CommonProps } from '../common'; import { Option } from '../../fp/Option'; import { Either } from '../../fp/Either'; export interface AlertProps extends CommonProps { /** * Alert content. */ content: string | ReactElement; /** * Icon name or a react element as custom icon. * - undefined: use default icon according to Alert intent. * - null: no icon at all. * - IconName: an icon identifier from hero-design icon list. * - ReactElement: Custom icon by your own. */ icon?: null | IconName | ReactElement; /** * Visual intent color to apply to alert. */ intent?: 'success' | 'info' | 'warning' | 'danger' | 'error'; /** * Closing callback. When onClose is available, an `x` button will be rendered on the right side of alert. The callback will be called when user clicks on `x` button. */ onClose?: () => void; /** * Alert title. */ title?: string | ReactElement; } export declare const getAlertIcon: (defaultIcon: IconName, icon: undefined | null | IconName | ReactElement) => Option>; declare const Alert: ({ intent, title, content, icon, onClose, id, className, style, sx, "data-test-id": dataTestId, }: AlertProps) => ReactElement; export default Alert;