UNPKG

svelte-5-french-toast

Version:

Buttery smooth Svelte 5 toasts. Lightweight, customizable, and beautiful by default. Svelte 5 Only

18 lines (17 loc) 805 B
import { type Writable } from 'svelte/store'; import type { DefaultToastOptions, Toast } from './types'; interface State { toasts: Writable<Toast[]>; pausedAt: Writable<number | null>; } export declare const toasts: State['toasts']; export declare const pausedAt: State['pausedAt']; export declare function update(toast: Partial<Toast>, clearTimeout?: boolean): void; export declare function add(toast: Toast): void; export declare function upsert(toast: Toast): void; export declare function dismiss(toastId?: Toast['id']): void; export declare function remove(toastId?: Toast['id']): void; export declare function startPause(time: number): void; export declare function endPause(time: number): void; export declare function useToasterStore(toastOptions?: DefaultToastOptions): State; export {};