UNPKG

@extclp/vexip-ui

Version:

A Vue 3 UI library, Highly customizability, full TypeScript, performance pretty good

43 lines (42 loc) 1.33 kB
import { App, MaybeRef } from 'vue'; import { MaybeInstance } from '@vexip-ui/hooks'; import { ToastOptions, ToastType } from './symbol'; export { toastProps } from './props'; export type { ToastProps, ToastCProps } from './props'; export type { ToastType, ToastOptions }; type FuzzyOptions = string | ToastOptions; interface AipMethod { (options: ToastOptions): () => void; (content: string, duration?: number): () => void; /** @internal */ (options: FuzzyOptions, duration?: number): () => void; } export declare class ToastManager { name: string; defaults: Record<string, unknown>; open: AipMethod; success: AipMethod; warning: AipMethod; error: AipMethod; loading: AipMethod; private _mountedApp; private _instance; private _innerApp; private _container; private _timer; private _wrapper; private _mountedEl; constructor(options?: Partial<ToastOptions>); close(): void; config(options: Record<string, unknown>): void; clone(): ToastManager; destroy(): void; isDestroyed(): boolean; install(app: App, options?: Partial<ToastOptions> & { property?: string; }): void; transferTo(target: MaybeRef<string | MaybeInstance>): void; private _getInstance; private _open; } export declare const Toast: ToastManager;