1 | import { Injector, InjectFlags } from '@angular/core';
|
2 | import { Observable } from 'rxjs';
|
3 | import { OverlayRef } from '../overlay/overlay-ref';
|
4 | import { ToastPackage } from './toastr-config';
|
5 |
|
6 |
|
7 |
|
8 | export declare class ToastRef<T> {
|
9 | private _overlayRef;
|
10 |
|
11 | componentInstance: T;
|
12 |
|
13 | private duplicatesCount;
|
14 |
|
15 | private _afterClosed;
|
16 |
|
17 | private _activate;
|
18 |
|
19 | private _manualClose;
|
20 |
|
21 | private _resetTimeout;
|
22 |
|
23 | private _countDuplicate;
|
24 | constructor(_overlayRef: OverlayRef);
|
25 | manualClose(): void;
|
26 | manualClosed(): Observable<any>;
|
27 | timeoutReset(): Observable<any>;
|
28 | countDuplicate(): Observable<number>;
|
29 | /**
|
30 | * Close the toast.
|
31 | */
|
32 | close(): void;
|
33 | /** Gets an observable that is notified when the toast is finished closing. */
|
34 | afterClosed(): Observable<any>;
|
35 | isInactive(): boolean;
|
36 | activate(): void;
|
37 | /** Gets an observable that is notified when the toast has started opening. */
|
38 | afterActivate(): Observable<any>;
|
39 | /** Reset the toast timouts and count duplicates */
|
40 | onDuplicate(resetTimeout: boolean, countDuplicate: boolean): void;
|
41 | }
|
42 | /** Custom injector type specifically for instantiating components with a toast. */
|
43 | export declare class ToastInjector implements Injector {
|
44 | private _toastPackage;
|
45 | private _parentInjector;
|
46 | constructor(_toastPackage: ToastPackage, _parentInjector: Injector);
|
47 | get<T>(token: any, notFoundValue?: T, flags?: InjectFlags): T | ToastPackage;
|
48 | }
|