ng-angular-popup
Version:
A modern, lightweight, and customizable toast notification library for Angular applications
30 lines (29 loc) • 1.2 kB
TypeScript
import { ToastType } from './toast-type.enum';
/**
* Represents a toast notification message with various configuration options.
*/
export declare class ToastMessage {
message: string;
type: ToastType;
title?: string | undefined;
duration: number;
/** Unique identifier for the toast message */
id: number;
/** Whether to show the progress bar for auto-dismiss countdown */
showProgress: boolean;
/** Timestamp when the toast was created */
createdAt: number;
/** Whether the toast can be dismissed by clicking on it */
dismissible: boolean;
/**
* Creates a new toast message instance.
*
* @param message The content of the toast message
* @param type The visual type/style of the toast
* @param title Optional title for the toast message
* @param duration Time in milliseconds before auto-dismissal (0 for no auto-dismiss)
* @param showProgress Whether to show the progress countdown bar
* @param dismissible Whether the toast can be manually dismissed
*/
constructor(message: string, type: ToastType, title?: string | undefined, duration?: number, showProgress?: boolean, dismissible?: boolean);
}