toast-noanimation.component.d.ts 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. import { ModuleWithProviders } from '@angular/compiler/src/core';
  2. import { ApplicationRef, OnDestroy } from '@angular/core';
  3. import { SafeHtml } from '@angular/platform-browser';
  4. import { GlobalConfig, IndividualConfig, ToastPackage } from './toastr-config';
  5. import { ToastrService } from './toastr.service';
  6. export declare class ToastNoAnimation implements OnDestroy {
  7. protected toastrService: ToastrService;
  8. toastPackage: ToastPackage;
  9. protected appRef: ApplicationRef;
  10. message?: string | SafeHtml | null;
  11. title?: string;
  12. options: IndividualConfig;
  13. duplicatesCount: number;
  14. originalTimeout: number;
  15. /** width of progress bar */
  16. width: number;
  17. /** a combination of toast type and options.toastClass */
  18. toastClasses: string;
  19. /** hides component when waiting to be displayed */
  20. readonly displayStyle: string;
  21. /** controls animation */
  22. state: 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. }
  49. export declare const DefaultNoAnimationsGlobalConfig: GlobalConfig;
  50. export declare class ToastNoAnimationModule {
  51. static forRoot(config?: Partial<GlobalConfig>): ModuleWithProviders;
  52. }