/** * Copyright (c) 2022 - present TinyVue Authors. * Copyright (c) 2022 - present Huawei Cloud Computing Technologies Co., Ltd. * * Use of this source code is governed by an MIT-style license. * * THE OPEN SOURCE SOFTWARE IN THIS PRODUCT IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL, * BUT WITHOUT ANY WARRANTY, WITHOUT EVEN THE IMPLIED WARRANTY OF MERCHANTABILITY OR FITNESS FOR * A PARTICULAR PURPOSE. SEE THE APPLICABLE LICENSES FOR MORE DETAILS. * */ type NotifyType = 'warning' | 'error' | 'info' | 'success'; type NotifyPosition = 'top-right' | 'bottom-right' | 'top-left' | 'bottom-left'; interface NotifyOptions { type?: NotifyType; duration?: number; position?: NotifyPosition; statusIcon?: any; offset?: number; verticalOffset?: number; debounceDelay?: number; onClose?: (instance: NotifyInstance) => void; [key: string]: any; } interface NotifyState { position: NotifyPosition; verticalOffset: number; visible: boolean; verticalProperty: string; } interface NotifyInstance { id: string; $el: HTMLElement; dom: HTMLElement; state: NotifyState; position: NotifyPosition; getZindex: () => number; close: (id: string) => void; } declare const Notify: { (options: NotifyOptions): NotifyInstance | ((options: NotifyOptions) => Promise<NotifyInstance>); close(id: string, userOnClose?: ((instance: NotifyInstance) => void) | undefined): void; closeAll(): void; }; export default Notify;