import { ForwardRefExoticComponent, ReactNode, PropsWithoutRef, RefAttributes } from 'react'; import { LoadingProps } from '../loading'; import { PopupProps } from '../popup'; import { IconProps } from '../icon'; export interface ToastProps extends PopupProps { type?: 'text' | 'loading' | 'success' | 'fail' | 'custom'; title?: ReactNode; icon?: ReactNode; iconProps?: IconProps; loadingProps?: LoadingProps; duration?: number; onTimeout?: (visible: false) => void; visible?: boolean; defaultVisible?: boolean; onVisible?: (visible: boolean) => void; placement?: 'top' | 'bottom'; } export interface ToastRef { cancelHide: () => void; hideLater: () => void; } export type ToastFC = ForwardRefExoticComponent & RefAttributes>; export declare const Toast: ToastFC; export default Toast;