import { TNode, Styles, AttachNode, AppContext } from '../common'; export interface TdNotificationProps { closeBtn?: string | boolean | TNode; content?: string | TNode; default?: string | TNode; duration?: number; footer?: string | TNode; icon?: boolean | TNode; theme?: NotificationThemeList; title?: string | TNode; onClose?: () => void; onCloseBtnClick?: (context: { e: MouseEvent; }) => void; onDurationEnd?: () => void; } export interface NotificationOptions extends TdNotificationProps { attach?: AttachNode; className?: string; offset?: Array; placement?: NotificationPlacementList; style?: string | Styles; zIndex?: number; } export type NotificationThemeList = 'info' | 'success' | 'warning' | 'error'; export type NotificationPlacementList = 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right'; export interface NotificationInstance { close: () => void; } export type NotificationMethod = (theme: NotificationThemeList, options: NotificationOptions, context?: AppContext) => Promise; export type NotificationInfoOptions = Omit; export type NotificationInfoMethod = (options: NotificationInfoOptions, context?: AppContext) => Promise; export type NotificationWarningMethod = (options: NotificationInfoOptions, context?: AppContext) => Promise; export type NotificationErrorMethod = (options: NotificationInfoOptions, context?: AppContext) => Promise; export type NotificationSuccessMethod = (options: NotificationInfoOptions, context?: AppContext) => Promise; export type NotificationCloseMethod = (options: Promise) => void; export type NotificationCloseAllMethod = () => void; export type NotificationConfigMethod = (notify: NotificationOptions) => void;