UNPKG

notyf

Version:

A dead simple, responsive, a11y, dependency-free, vanilla JavaScript toast library.

29 lines (28 loc) 947 B
import { NotyfArrayEvent, NotyfNotification } from './notyf.models'; export declare class NotyfView { a11yContainer: HTMLElement; animationEndEventName: string; container: HTMLElement; private notifications; constructor(); update(notification: NotyfNotification, type: NotyfArrayEvent): void; removeNotification(notification: NotyfNotification): void; addNotification(notification: NotyfNotification): void; private _renderNotification; private _popRenderedNotification; private _buildNotificationCard; private _createHTLMElement; /** * Creates an invisible container which will announce the notyfs to * screen readers */ private _createA11yContainer; /** * Announces a message to screenreaders. */ private _announce; /** * Determine which animationend event is supported */ private _getAnimationEndEventName; }