1 | import { AnimationBuilder, Color, Mode } from '../../interface';
|
2 | import { IonicSafeString } from '../../utils/sanitization';
|
3 | export interface ToastOptions {
|
4 | header?: string;
|
5 | message?: string | IonicSafeString;
|
6 | cssClass?: string | string[];
|
7 | duration?: number;
|
8 | buttons?: (ToastButton | string)[];
|
9 | position?: 'top' | 'bottom' | 'middle';
|
10 | translucent?: boolean;
|
11 | animated?: boolean;
|
12 | color?: Color;
|
13 | mode?: Mode;
|
14 | keyboardClose?: boolean;
|
15 | id?: string;
|
16 | enterAnimation?: AnimationBuilder;
|
17 | leaveAnimation?: AnimationBuilder;
|
18 | }
|
19 | export interface ToastButton {
|
20 | text?: string;
|
21 | icon?: string;
|
22 | side?: 'start' | 'end';
|
23 | role?: 'cancel' | string;
|
24 | cssClass?: string | string[];
|
25 | handler?: () => boolean | void | Promise<boolean | void>;
|
26 | }
|