UNPKG

2.27 kBTypeScriptView Raw
1import { ModuleWithProviders } from '@angular/core';
2import { ApplicationRef, OnDestroy } from '@angular/core';
3import { GlobalConfig, IndividualConfig, ToastPackage } from './toastr-config';
4import { ToastrService } from './toastr.service';
5import * as i0 from "@angular/core";
6export declare class ToastNoAnimation implements OnDestroy {
7 protected toastrService: ToastrService;
8 toastPackage: ToastPackage;
9 protected appRef: ApplicationRef;
10 message?: string | null;
11 title?: string;
12 options: IndividualConfig;
13 duplicatesCount: number;
14 originalTimeout: number;
15 /** width of progress bar */
16 width: import("@angular/core").WritableSignal<number>;
17 /** a combination of toast type and options.toastClass */
18 toastClasses: string;
19 /** hides component when waiting to be displayed */
20 get displayStyle(): string;
21 /** controls animation */
22 state: import("@angular/core").WritableSignal<string>;
23 private timeout;
24 private intervalId;
25 private hideTime;
26 private sub;
27 private sub1;
28 private sub2;
29 private sub3;
30 constructor(toastrService: ToastrService, toastPackage: ToastPackage, appRef: ApplicationRef);
31 ngOnDestroy(): void;
32 /**
33 * activates toast and sets timeout
34 */
35 activateToast(): void;
36 /**
37 * updates progress bar width
38 */
39 updateProgress(): void;
40 resetTimeout(): void;
41 /**
42 * tells toastrService to remove this toast after animation time
43 */
44 remove(): void;
45 tapToast(): void;
46 stickAround(): void;
47 delayedHideToast(): void;
48 static ɵfac: i0.ɵɵFactoryDeclaration<ToastNoAnimation, never>;
49 static ɵcmp: i0.ɵɵComponentDeclaration<ToastNoAnimation, "[toast-component]", never, {}, {}, never, never, true, never>;
50}
51export declare const DefaultNoAnimationsGlobalConfig: GlobalConfig;
52export declare class ToastNoAnimationModule {
53 static forRoot(config?: Partial<GlobalConfig>): ModuleWithProviders<ToastNoAnimationModule>;
54 static ɵfac: i0.ɵɵFactoryDeclaration<ToastNoAnimationModule, never>;
55 static ɵmod: i0.ɵɵNgModuleDeclaration<ToastNoAnimationModule, never, [typeof ToastNoAnimation], [typeof ToastNoAnimation]>;
56 static ɵinj: i0.ɵɵInjectorDeclaration<ToastNoAnimationModule>;
57}