UNPKG

ukelli-ui

Version:

Base on React's UI lib. Make frontend's dev simpler and faster.

20 lines (19 loc) 636 B
import { NotifyConfig, NotificationProps } from './notification'; export interface NotifyParams extends NotifyConfig { /** 广播 Notify 的配置 */ config?: NotifyConfig; /** 广播通知的位置 */ position?: string; /** 点击通知项时的回调 */ handleClick?: NotificationProps['handleClick']; } export declare type NotifyID = number | string; /** * 将返回 config 的 id,用于消除该通知 * @param {object} options */ export default function Notify(options: NotifyParams): NotifyID; /** * 用于消除 Notify ,传入 notifyID */ export declare function CancelNotify(id: NotifyID): any;