ngx-toastr 14.2.2 → 14.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -2
- package/esm2020/overlay/overlay-container.mjs +7 -5
- package/esm2020/overlay/overlay.mjs +3 -3
- package/esm2020/toastr/toast-noanimation.component.mjs +12 -12
- package/esm2020/toastr/toast.component.mjs +8 -8
- package/esm2020/toastr/toast.directive.mjs +7 -7
- package/esm2020/toastr/toastr.module.mjs +8 -8
- package/esm2020/toastr/toastr.service.mjs +3 -3
- package/fesm2015/ngx-toastr.mjs +45 -43
- package/fesm2015/ngx-toastr.mjs.map +1 -1
- package/fesm2020/ngx-toastr.mjs +45 -43
- package/fesm2020/ngx-toastr.mjs.map +1 -1
- package/overlay/overlay-container.d.ts +2 -1
- package/package.json +1 -1
package/fesm2020/ngx-toastr.mjs
CHANGED
@@ -14,9 +14,9 @@ class ToastContainerDirective {
|
|
14
14
|
return this.el.nativeElement;
|
15
15
|
}
|
16
16
|
}
|
17
|
-
ToastContainerDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2
|
18
|
-
ToastContainerDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.2
|
19
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2
|
17
|
+
ToastContainerDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastContainerDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
|
18
|
+
ToastContainerDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.2", type: ToastContainerDirective, selector: "[toastContainer]", exportAs: ["toastContainer"], ngImport: i0 });
|
19
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastContainerDirective, decorators: [{
|
20
20
|
type: Directive,
|
21
21
|
args: [{
|
22
22
|
selector: '[toastContainer]',
|
@@ -25,10 +25,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.5", ngImpor
|
|
25
25
|
}], ctorParameters: function () { return [{ type: i0.ElementRef }]; } });
|
26
26
|
class ToastContainerModule {
|
27
27
|
}
|
28
|
-
ToastContainerModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2
|
29
|
-
ToastContainerModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2
|
30
|
-
ToastContainerModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2
|
31
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2
|
28
|
+
ToastContainerModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastContainerModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
29
|
+
ToastContainerModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastContainerModule, declarations: [ToastContainerDirective], exports: [ToastContainerDirective] });
|
30
|
+
ToastContainerModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastContainerModule });
|
31
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastContainerModule, decorators: [{
|
32
32
|
type: NgModule,
|
33
33
|
args: [{
|
34
34
|
declarations: [ToastContainerDirective],
|
@@ -342,18 +342,20 @@ class OverlayContainer {
|
|
342
342
|
}
|
343
343
|
/**
|
344
344
|
* Create the overlay container element, which is simply a div
|
345
|
-
* with the 'cdk-overlay-container' class on the document body
|
345
|
+
* with the 'cdk-overlay-container' class on the document body
|
346
|
+
* and 'aria-live="polite"'
|
346
347
|
*/
|
347
348
|
_createContainer() {
|
348
349
|
const container = this._document.createElement('div');
|
349
350
|
container.classList.add('overlay-container');
|
351
|
+
container.setAttribute('aria-live', 'polite');
|
350
352
|
this._document.body.appendChild(container);
|
351
353
|
this._containerElement = container;
|
352
354
|
}
|
353
355
|
}
|
354
|
-
OverlayContainer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2
|
355
|
-
OverlayContainer.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2
|
356
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2
|
356
|
+
OverlayContainer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: OverlayContainer, deps: [{ token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Injectable });
|
357
|
+
OverlayContainer.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: OverlayContainer, providedIn: 'root' });
|
358
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: OverlayContainer, decorators: [{
|
357
359
|
type: Injectable,
|
358
360
|
args: [{ providedIn: 'root' }]
|
359
361
|
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
@@ -429,9 +431,9 @@ class Overlay {
|
|
429
431
|
return new OverlayRef(this._createPortalHost(pane));
|
430
432
|
}
|
431
433
|
}
|
432
|
-
Overlay.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2
|
433
|
-
Overlay.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2
|
434
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2
|
434
|
+
Overlay.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: Overlay, deps: [{ token: OverlayContainer }, { token: i0.ComponentFactoryResolver }, { token: i0.ApplicationRef }, { token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Injectable });
|
435
|
+
Overlay.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: Overlay, providedIn: 'root' });
|
436
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: Overlay, decorators: [{
|
435
437
|
type: Injectable,
|
436
438
|
args: [{ providedIn: 'root' }]
|
437
439
|
}], ctorParameters: function () { return [{ type: OverlayContainer }, { type: i0.ComponentFactoryResolver }, { type: i0.ApplicationRef }, { type: undefined, decorators: [{
|
@@ -619,9 +621,9 @@ class ToastrService {
|
|
619
621
|
return ins;
|
620
622
|
}
|
621
623
|
}
|
622
|
-
ToastrService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2
|
623
|
-
ToastrService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2
|
624
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2
|
624
|
+
ToastrService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastrService, deps: [{ token: TOAST_CONFIG }, { token: Overlay }, { token: i0.Injector }, { token: i2.DomSanitizer }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Injectable });
|
625
|
+
ToastrService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastrService, providedIn: 'root' });
|
626
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastrService, decorators: [{
|
625
627
|
type: Injectable,
|
626
628
|
args: [{ providedIn: 'root' }]
|
627
629
|
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
@@ -794,18 +796,18 @@ class Toast {
|
|
794
796
|
}
|
795
797
|
}
|
796
798
|
}
|
797
|
-
Toast.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2
|
798
|
-
Toast.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2
|
799
|
+
Toast.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: Toast, deps: [{ token: ToastrService }, { token: ToastPackage }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
|
800
|
+
Toast.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: Toast, selector: "[toast-component]", host: { listeners: { "click": "tapToast()", "mouseenter": "stickAround()", "mouseleave": "delayedHideToast()" }, properties: { "class": "this.toastClasses", "@flyInOut": "this.state", "style.display": "this.displayStyle" } }, ngImport: i0, template: `
|
799
801
|
<button *ngIf="options.closeButton" (click)="remove()" type="button" class="toast-close-button" aria-label="Close">
|
800
802
|
<span aria-hidden="true">×</span>
|
801
803
|
</button>
|
802
804
|
<div *ngIf="title" [class]="options.titleClass" [attr.aria-label]="title">
|
803
805
|
{{ title }} <ng-container *ngIf="duplicatesCount">[{{ duplicatesCount + 1 }}]</ng-container>
|
804
806
|
</div>
|
805
|
-
<div *ngIf="message && options.enableHtml" role="
|
807
|
+
<div *ngIf="message && options.enableHtml" role="alert"
|
806
808
|
[class]="options.messageClass" [innerHTML]="message">
|
807
809
|
</div>
|
808
|
-
<div *ngIf="message && !options.enableHtml" role="
|
810
|
+
<div *ngIf="message && !options.enableHtml" role="alert"
|
809
811
|
[class]="options.messageClass" [attr.aria-label]="message">
|
810
812
|
{{ message }}
|
811
813
|
</div>
|
@@ -821,7 +823,7 @@ Toast.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.5
|
|
821
823
|
transition('active => removed', animate('{{ easeTime }}ms {{ easing }}'))
|
822
824
|
])
|
823
825
|
] });
|
824
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2
|
826
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: Toast, decorators: [{
|
825
827
|
type: Component,
|
826
828
|
args: [{
|
827
829
|
selector: '[toast-component]',
|
@@ -832,10 +834,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.5", ngImpor
|
|
832
834
|
<div *ngIf="title" [class]="options.titleClass" [attr.aria-label]="title">
|
833
835
|
{{ title }} <ng-container *ngIf="duplicatesCount">[{{ duplicatesCount + 1 }}]</ng-container>
|
834
836
|
</div>
|
835
|
-
<div *ngIf="message && options.enableHtml" role="
|
837
|
+
<div *ngIf="message && options.enableHtml" role="alert"
|
836
838
|
[class]="options.messageClass" [innerHTML]="message">
|
837
839
|
</div>
|
838
|
-
<div *ngIf="message && !options.enableHtml" role="
|
840
|
+
<div *ngIf="message && !options.enableHtml" role="alert"
|
839
841
|
[class]="options.messageClass" [attr.aria-label]="message">
|
840
842
|
{{ message }}
|
841
843
|
</div>
|
@@ -894,10 +896,10 @@ class ToastrModule {
|
|
894
896
|
};
|
895
897
|
}
|
896
898
|
}
|
897
|
-
ToastrModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2
|
898
|
-
ToastrModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2
|
899
|
-
ToastrModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2
|
900
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2
|
899
|
+
ToastrModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastrModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
900
|
+
ToastrModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastrModule, declarations: [Toast], imports: [CommonModule], exports: [Toast] });
|
901
|
+
ToastrModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastrModule, imports: [[CommonModule]] });
|
902
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastrModule, decorators: [{
|
901
903
|
type: NgModule,
|
902
904
|
args: [{
|
903
905
|
imports: [CommonModule],
|
@@ -922,10 +924,10 @@ class ToastrComponentlessModule {
|
|
922
924
|
};
|
923
925
|
}
|
924
926
|
}
|
925
|
-
ToastrComponentlessModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2
|
926
|
-
ToastrComponentlessModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2
|
927
|
-
ToastrComponentlessModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2
|
928
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2
|
927
|
+
ToastrComponentlessModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastrComponentlessModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
928
|
+
ToastrComponentlessModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastrComponentlessModule, imports: [CommonModule] });
|
929
|
+
ToastrComponentlessModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastrComponentlessModule, imports: [[CommonModule]] });
|
930
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastrComponentlessModule, decorators: [{
|
929
931
|
type: NgModule,
|
930
932
|
args: [{
|
931
933
|
imports: [CommonModule],
|
@@ -1071,18 +1073,18 @@ class ToastNoAnimation {
|
|
1071
1073
|
}
|
1072
1074
|
}
|
1073
1075
|
}
|
1074
|
-
ToastNoAnimation.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2
|
1075
|
-
ToastNoAnimation.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2
|
1076
|
+
ToastNoAnimation.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastNoAnimation, deps: [{ token: ToastrService }, { token: ToastPackage }, { token: i0.ApplicationRef }], target: i0.ɵɵFactoryTarget.Component });
|
1077
|
+
ToastNoAnimation.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: ToastNoAnimation, selector: "[toast-component]", host: { listeners: { "click": "tapToast()", "mouseenter": "stickAround()", "mouseleave": "delayedHideToast()" }, properties: { "class": "this.toastClasses", "style.display": "this.displayStyle" } }, ngImport: i0, template: `
|
1076
1078
|
<button *ngIf="options.closeButton" (click)="remove()" type="button" class="toast-close-button" aria-label="Close">
|
1077
1079
|
<span aria-hidden="true">×</span>
|
1078
1080
|
</button>
|
1079
1081
|
<div *ngIf="title" [class]="options.titleClass" [attr.aria-label]="title">
|
1080
1082
|
{{ title }} <ng-container *ngIf="duplicatesCount">[{{ duplicatesCount + 1 }}]</ng-container>
|
1081
1083
|
</div>
|
1082
|
-
<div *ngIf="message && options.enableHtml" role="alert"
|
1084
|
+
<div *ngIf="message && options.enableHtml" role="alert"
|
1083
1085
|
[class]="options.messageClass" [innerHTML]="message">
|
1084
1086
|
</div>
|
1085
|
-
<div *ngIf="message && !options.enableHtml" role="alert"
|
1087
|
+
<div *ngIf="message && !options.enableHtml" role="alert"
|
1086
1088
|
[class]="options.messageClass" [attr.aria-label]="message">
|
1087
1089
|
{{ message }}
|
1088
1090
|
</div>
|
@@ -1090,7 +1092,7 @@ ToastNoAnimation.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", versi
|
|
1090
1092
|
<div class="toast-progress" [style.width]="width + '%'"></div>
|
1091
1093
|
</div>
|
1092
1094
|
`, isInline: true, directives: [{ type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
1093
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2
|
1095
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastNoAnimation, decorators: [{
|
1094
1096
|
type: Component,
|
1095
1097
|
args: [{
|
1096
1098
|
selector: '[toast-component]',
|
@@ -1101,10 +1103,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.5", ngImpor
|
|
1101
1103
|
<div *ngIf="title" [class]="options.titleClass" [attr.aria-label]="title">
|
1102
1104
|
{{ title }} <ng-container *ngIf="duplicatesCount">[{{ duplicatesCount + 1 }}]</ng-container>
|
1103
1105
|
</div>
|
1104
|
-
<div *ngIf="message && options.enableHtml" role="alert"
|
1106
|
+
<div *ngIf="message && options.enableHtml" role="alert"
|
1105
1107
|
[class]="options.messageClass" [innerHTML]="message">
|
1106
1108
|
</div>
|
1107
|
-
<div *ngIf="message && !options.enableHtml" role="alert"
|
1109
|
+
<div *ngIf="message && !options.enableHtml" role="alert"
|
1108
1110
|
[class]="options.messageClass" [attr.aria-label]="message">
|
1109
1111
|
{{ message }}
|
1110
1112
|
</div>
|
@@ -1149,10 +1151,10 @@ class ToastNoAnimationModule {
|
|
1149
1151
|
};
|
1150
1152
|
}
|
1151
1153
|
}
|
1152
|
-
ToastNoAnimationModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2
|
1153
|
-
ToastNoAnimationModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2
|
1154
|
-
ToastNoAnimationModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2
|
1155
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2
|
1154
|
+
ToastNoAnimationModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastNoAnimationModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
1155
|
+
ToastNoAnimationModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastNoAnimationModule, declarations: [ToastNoAnimation], imports: [CommonModule], exports: [ToastNoAnimation] });
|
1156
|
+
ToastNoAnimationModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastNoAnimationModule, imports: [[CommonModule]] });
|
1157
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: ToastNoAnimationModule, decorators: [{
|
1156
1158
|
type: NgModule,
|
1157
1159
|
args: [{
|
1158
1160
|
imports: [CommonModule],
|