@craftsjs/alert 5.0.0 → 6.0.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.
Files changed (31) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +146 -145
  3. package/_craftsjs-alert.theme.scss +414 -296
  4. package/esm2022/lib/alert.module.mjs +67 -0
  5. package/{esm2020 → esm2022}/lib/components/dialog-alert/components/alert-info/alert-info.component.mjs +4 -4
  6. package/esm2022/lib/components/dialog-alert/components/alert-success/alert-success.component.mjs +13 -0
  7. package/esm2022/lib/components/dialog-alert/components/buttons/alert-cancel-button/alert-cancel-button.component.mjs +18 -0
  8. package/{esm2020 → esm2022}/lib/components/dialog-alert/components/buttons/alert-ok-button/alert-ok-button.component.mjs +4 -4
  9. package/{esm2020 → esm2022}/lib/components/dialog-alert/components/components.mjs +1 -1
  10. package/esm2022/lib/components/dialog-alert/components/error/error.component.mjs +13 -0
  11. package/esm2022/lib/components/dialog-alert/components/warning/warning.component.mjs +13 -0
  12. package/esm2022/lib/components/dialog-alert/dialog-alert.component.mjs +74 -0
  13. package/{esm2020 → esm2022}/lib/models/alert-enum.model.mjs +1 -1
  14. package/esm2022/lib/models/alert.model.mjs +2 -0
  15. package/{esm2020 → esm2022}/lib/services/alert.service.mjs +5 -5
  16. package/{esm2020 → esm2022}/public-api.mjs +1 -1
  17. package/fesm2022/craftsjs-alert.mjs +296 -0
  18. package/fesm2022/craftsjs-alert.mjs.map +1 -0
  19. package/package.json +12 -17
  20. package/esm2020/lib/alert.module.mjs +0 -67
  21. package/esm2020/lib/components/dialog-alert/components/alert-success/alert-success.component.mjs +0 -13
  22. package/esm2020/lib/components/dialog-alert/components/buttons/alert-cancel-button/alert-cancel-button.component.mjs +0 -18
  23. package/esm2020/lib/components/dialog-alert/components/error/error.component.mjs +0 -13
  24. package/esm2020/lib/components/dialog-alert/components/warning/warning.component.mjs +0 -13
  25. package/esm2020/lib/components/dialog-alert/dialog-alert.component.mjs +0 -74
  26. package/esm2020/lib/models/alert.model.mjs +0 -2
  27. package/fesm2015/craftsjs-alert.mjs +0 -299
  28. package/fesm2015/craftsjs-alert.mjs.map +0 -1
  29. package/fesm2020/craftsjs-alert.mjs +0 -297
  30. package/fesm2020/craftsjs-alert.mjs.map +0 -1
  31. /package/{esm2020 → esm2022}/craftsjs-alert.mjs +0 -0
@@ -1,74 +0,0 @@
1
- import { Component, ChangeDetectionStrategy, Inject, ViewEncapsulation, Injector, InjectionToken, ViewChildren, TemplateRef } from '@angular/core';
2
- import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';
3
- import { alertComponents } from './components/components';
4
- import { DynamicDirective } from '@craftsjs/core';
5
- import * as i0 from "@angular/core";
6
- import * as i1 from "@angular/material/dialog";
7
- import * as i2 from "@angular/common";
8
- import * as i3 from "@craftsjs/core";
9
- import * as i4 from "./components/buttons/alert-ok-button/alert-ok-button.component";
10
- import * as i5 from "./components/buttons/alert-cancel-button/alert-cancel-button.component";
11
- import * as i6 from "@ngx-translate/core";
12
- export const CRAFTSJS_ALERT_DATA = new InjectionToken('CraftsjsAlertData');
13
- export class DialogAlertComponent {
14
- constructor(dialogRef, data) {
15
- this.dialogRef = dialogRef;
16
- this.data = data;
17
- }
18
- ngOnInit() {
19
- }
20
- ngAfterViewInit() {
21
- this.loadComponents();
22
- }
23
- loadComponents() {
24
- const itemComponent = alertComponents.find(x => x.type === this.data.type);
25
- const component = itemComponent && itemComponent.component;
26
- this.resolveComponent(component, this.appDynamic.find(x => x.name === 'alert-icon').viewContainerRef);
27
- this.resolveComponent(this.data.customBody, this.appDynamic.find(x => x.name === 'alert-body').viewContainerRef);
28
- this.resolveComponent(this.data.customButtonComponent, this.appDynamic.find(x => x.name === 'alert-buttons').viewContainerRef);
29
- }
30
- resolveComponent(component, viewContainerRef) {
31
- if (!component) {
32
- return;
33
- }
34
- viewContainerRef.clear();
35
- if (component instanceof TemplateRef) {
36
- viewContainerRef.createEmbeddedView(component, { $implicit: this.data, dialogRef: this.dialogRef });
37
- }
38
- else {
39
- const injector = this.createInjector(viewContainerRef.injector);
40
- viewContainerRef.createComponent(component, {
41
- injector
42
- });
43
- }
44
- }
45
- createInjector(injector) {
46
- return Injector.create({
47
- providers: [{
48
- provide: CRAFTSJS_ALERT_DATA,
49
- useValue: this.data
50
- },
51
- {
52
- provide: MatDialogRef,
53
- useValue: this.dialogRef
54
- }],
55
- parent: injector
56
- });
57
- }
58
- buttonClick(result) {
59
- this.dialogRef.close({ data: this.data, result });
60
- }
61
- }
62
- DialogAlertComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: DialogAlertComponent, deps: [{ token: i1.MatDialogRef }, { token: MAT_DIALOG_DATA }], target: i0.ɵɵFactoryTarget.Component });
63
- DialogAlertComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: DialogAlertComponent, selector: "dialog-alert", viewQueries: [{ propertyName: "appDynamic", predicate: DynamicDirective, descendants: true }], ngImport: i0, template: "<ng-template craftsjsDynamic name=\"alert-icon\"></ng-template>\n<div *ngIf=\"data?.title\" class=\"alert-title\">\n <span>\n {{data.title | translate}}\n </span>\n</div>\n<div *ngIf=\"data?.text\" class=\"alert-text\">\n <span>\n {{data.text | translate}}\n </span>\n</div>\n<ng-template craftsjsDynamic name=\"alert-body\"></ng-template>\n<div class=\"alert-footer\" *ngIf=\"!data?.hiddenButtons\">\n <alert-ok-button *ngIf=\"!data?.customButtonComponent\" (click)=\"buttonClick('ok')\">\n </alert-ok-button>\n <alert-cancel-button *ngIf=\"!data?.customButtonComponent && data?.showCancelButton\"\n (click)=\"buttonClick('cancel')\">\n </alert-cancel-button>\n</div>\n<ng-template craftsjsDynamic name=\"alert-buttons\"></ng-template>", styles: [".alert-icon{width:80px;height:80px;border-width:4px;border-style:solid;border-radius:50%;padding:0;position:relative;box-sizing:content-box;margin:20px auto}.alert-icon-custom{width:auto;height:auto;max-width:100%;border:none;border-radius:0}.alert-icon img{max-width:100%;max-height:100%}.alert-title{color:#000000a6;font-weight:600;text-transform:none;position:relative;display:block;font-size:27px;line-height:normal;text-align:center;margin-bottom:0}.alert-title:first-child{margin-top:26px}.alert-title:not(:first-child){padding-bottom:0}.alert-title:not(:last-child){margin-bottom:13px}.alert-text{font-size:16px;position:relative;float:none;line-height:normal;vertical-align:top;text-align:center;display:inline-block;margin:0;padding:0 10px;font-weight:400;color:#000000a3;overflow-wrap:break-word;box-sizing:border-box;width:100%}.alert-text:first-child{margin-top:45px}.alert-text:last-child{margin-bottom:45px}.alert-footer{text-align:right;margin-top:13px;padding:13px 16px;border-radius:inherit;border-top-left-radius:0;border-top-right-radius:0}.alert-footer-button-container{margin:5px;display:inline-block;position:relative}.alert-footer>*{display:inline-block;margin-right:.5em}.alert-footer>:last-child{margin-right:inherit}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.DynamicDirective, selector: "[craftsjsDynamic]", inputs: ["name"] }, { kind: "component", type: i4.AlertOkButtonComponent, selector: "alert-ok-button", outputs: ["click"] }, { kind: "component", type: i5.AlertCancelButtonComponent, selector: "alert-cancel-button", outputs: ["click"] }, { kind: "pipe", type: i6.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
64
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: DialogAlertComponent, decorators: [{
65
- type: Component,
66
- args: [{ selector: 'dialog-alert', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<ng-template craftsjsDynamic name=\"alert-icon\"></ng-template>\n<div *ngIf=\"data?.title\" class=\"alert-title\">\n <span>\n {{data.title | translate}}\n </span>\n</div>\n<div *ngIf=\"data?.text\" class=\"alert-text\">\n <span>\n {{data.text | translate}}\n </span>\n</div>\n<ng-template craftsjsDynamic name=\"alert-body\"></ng-template>\n<div class=\"alert-footer\" *ngIf=\"!data?.hiddenButtons\">\n <alert-ok-button *ngIf=\"!data?.customButtonComponent\" (click)=\"buttonClick('ok')\">\n </alert-ok-button>\n <alert-cancel-button *ngIf=\"!data?.customButtonComponent && data?.showCancelButton\"\n (click)=\"buttonClick('cancel')\">\n </alert-cancel-button>\n</div>\n<ng-template craftsjsDynamic name=\"alert-buttons\"></ng-template>", styles: [".alert-icon{width:80px;height:80px;border-width:4px;border-style:solid;border-radius:50%;padding:0;position:relative;box-sizing:content-box;margin:20px auto}.alert-icon-custom{width:auto;height:auto;max-width:100%;border:none;border-radius:0}.alert-icon img{max-width:100%;max-height:100%}.alert-title{color:#000000a6;font-weight:600;text-transform:none;position:relative;display:block;font-size:27px;line-height:normal;text-align:center;margin-bottom:0}.alert-title:first-child{margin-top:26px}.alert-title:not(:first-child){padding-bottom:0}.alert-title:not(:last-child){margin-bottom:13px}.alert-text{font-size:16px;position:relative;float:none;line-height:normal;vertical-align:top;text-align:center;display:inline-block;margin:0;padding:0 10px;font-weight:400;color:#000000a3;overflow-wrap:break-word;box-sizing:border-box;width:100%}.alert-text:first-child{margin-top:45px}.alert-text:last-child{margin-bottom:45px}.alert-footer{text-align:right;margin-top:13px;padding:13px 16px;border-radius:inherit;border-top-left-radius:0;border-top-right-radius:0}.alert-footer-button-container{margin:5px;display:inline-block;position:relative}.alert-footer>*{display:inline-block;margin-right:.5em}.alert-footer>:last-child{margin-right:inherit}\n"] }]
67
- }], ctorParameters: function () { return [{ type: i1.MatDialogRef }, { type: undefined, decorators: [{
68
- type: Inject,
69
- args: [MAT_DIALOG_DATA]
70
- }] }]; }, propDecorators: { appDynamic: [{
71
- type: ViewChildren,
72
- args: [DynamicDirective]
73
- }] } });
74
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGlhbG9nLWFsZXJ0LmNvbXBvbmVudC5qcyIsInNvdXJjZV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bGF0ZVJlZjxhbnk+O1xuICAgIGN1c3RvbUJvZHk/OiBUeXBlPGFueT4gfCBUZW1wbGF0ZVJlZjxhbnk+O1xuICAgIHNob3dDYW5jZWxCdXR0b24/OiBib29sZWFuO1xufVxuIl19
@@ -1,299 +0,0 @@
1
- import * as i0 from '@angular/core';
2
- import { Component, ChangeDetectionStrategy, ViewEncapsulation, EventEmitter, Output, InjectionToken, TemplateRef, Injector, Inject, ViewChildren, Injectable, NgModule } from '@angular/core';
3
- import * as i1 from '@angular/material/button';
4
- import { MatButtonModule } from '@angular/material/button';
5
- import * as i1$1 from '@angular/material/dialog';
6
- import { MatDialogRef, MAT_DIALOG_DATA, MatDialogModule } from '@angular/material/dialog';
7
- import * as i2 from '@ngx-translate/core';
8
- import { TranslateModule } from '@ngx-translate/core';
9
- import * as i2$1 from '@angular/common';
10
- import { CommonModule } from '@angular/common';
11
- import * as i3 from '@craftsjs/core';
12
- import { DynamicDirective, CoreModule } from '@craftsjs/core';
13
-
14
- class AlertSuccessComponent {
15
- }
16
- AlertSuccessComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AlertSuccessComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
17
- AlertSuccessComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: AlertSuccessComponent, selector: "alert-success", host: { classAttribute: "alert-icon alert-icon-success" }, ngImport: i0, template: "<span class=\"alert-icon-success-line alert-icon-success-line-long\"></span>\n<span class=\"alert-icon-success-line alert-icon-success-line-tip\"></span>\n<div class=\"alert-icon-success-ring\"></div>\n<div class=\"alert-icon-success-hide-corners\"></div>", styles: [""], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
18
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AlertSuccessComponent, decorators: [{
19
- type: Component,
20
- args: [{ selector: 'alert-success', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, host: {
21
- class: 'alert-icon alert-icon-success'
22
- }, template: "<span class=\"alert-icon-success-line alert-icon-success-line-long\"></span>\n<span class=\"alert-icon-success-line alert-icon-success-line-tip\"></span>\n<div class=\"alert-icon-success-ring\"></div>\n<div class=\"alert-icon-success-hide-corners\"></div>" }]
23
- }] });
24
-
25
- var AlertEnum;
26
- (function (AlertEnum) {
27
- AlertEnum["success"] = "success";
28
- AlertEnum["error"] = "error";
29
- AlertEnum["info"] = "info";
30
- AlertEnum["warning"] = "warning";
31
- })(AlertEnum || (AlertEnum = {}));
32
-
33
- class AlertInfoComponent {
34
- }
35
- AlertInfoComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AlertInfoComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
36
- AlertInfoComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: AlertInfoComponent, selector: "alert-info", host: { classAttribute: "alert-icon alert-icon-info" }, ngImport: i0, template: "", styles: [""], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
37
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AlertInfoComponent, decorators: [{
38
- type: Component,
39
- args: [{ selector: 'alert-info', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, host: {
40
- class: 'alert-icon alert-icon-info'
41
- }, template: "" }]
42
- }] });
43
-
44
- class WarningComponent {
45
- }
46
- WarningComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: WarningComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
47
- WarningComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: WarningComponent, selector: "alert-warning", host: { classAttribute: "alert-icon alert-icon-warning " }, ngImport: i0, template: "<span class=\"alert-icon-warning-body\">\n <span class=\"alert-icon-warning-dot\"></span>\n</span>", styles: [""], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
48
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: WarningComponent, decorators: [{
49
- type: Component,
50
- args: [{ selector: 'alert-warning', host: {
51
- class: 'alert-icon alert-icon-warning '
52
- }, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<span class=\"alert-icon-warning-body\">\n <span class=\"alert-icon-warning-dot\"></span>\n</span>" }]
53
- }] });
54
-
55
- class ErrorComponent {
56
- }
57
- ErrorComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: ErrorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
58
- ErrorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: ErrorComponent, selector: "alert-error", host: { classAttribute: "alert-icon alert-icon-error" }, ngImport: i0, template: "<div class=\"alert-icon-error-x-mark\">\n <span class=\"alert-icon-error-line alert-icon-error-line-left\"></span>\n <span class=\"alert-icon-error-line alert-icon-error-line-right\"></span>\n</div>", styles: [""], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
59
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: ErrorComponent, decorators: [{
60
- type: Component,
61
- args: [{ selector: 'alert-error', host: {
62
- class: 'alert-icon alert-icon-error'
63
- }, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"alert-icon-error-x-mark\">\n <span class=\"alert-icon-error-line alert-icon-error-line-left\"></span>\n <span class=\"alert-icon-error-line alert-icon-error-line-right\"></span>\n</div>" }]
64
- }] });
65
-
66
- const alertComponents = [
67
- {
68
- type: AlertEnum.success,
69
- component: AlertSuccessComponent
70
- },
71
- {
72
- type: AlertEnum.info,
73
- component: AlertInfoComponent
74
- },
75
- {
76
- type: AlertEnum.warning,
77
- component: WarningComponent
78
- },
79
- {
80
- type: AlertEnum.error,
81
- component: ErrorComponent
82
- }
83
- ];
84
-
85
- class AlertOkButtonComponent {
86
- constructor() {
87
- this.click = new EventEmitter();
88
- }
89
- }
90
- AlertOkButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AlertOkButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
91
- AlertOkButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: AlertOkButtonComponent, selector: "alert-ok-button", outputs: { click: "click" }, ngImport: i0, template: "<button mat-raised-button color=\"primary\" (click)=\"click.emit($event)\">{{'general.ok' | translate}}</button>", styles: [""], dependencies: [{ kind: "component", type: i1.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
92
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AlertOkButtonComponent, decorators: [{
93
- type: Component,
94
- args: [{ selector: 'alert-ok-button', changeDetection: ChangeDetectionStrategy.OnPush, template: "<button mat-raised-button color=\"primary\" (click)=\"click.emit($event)\">{{'general.ok' | translate}}</button>" }]
95
- }], propDecorators: { click: [{
96
- type: Output
97
- }] } });
98
-
99
- class AlertCancelButtonComponent {
100
- constructor() {
101
- this.click = new EventEmitter();
102
- }
103
- }
104
- AlertCancelButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AlertCancelButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
105
- AlertCancelButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: AlertCancelButtonComponent, selector: "alert-cancel-button", outputs: { click: "click" }, ngImport: i0, template: "<button mat-raised-button (click)=\"click.emit($event)\">{{'general.cancel' | translate}}</button>", styles: [""], dependencies: [{ kind: "component", type: i1.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
106
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AlertCancelButtonComponent, decorators: [{
107
- type: Component,
108
- args: [{ selector: 'alert-cancel-button', changeDetection: ChangeDetectionStrategy.OnPush, template: "<button mat-raised-button (click)=\"click.emit($event)\">{{'general.cancel' | translate}}</button>" }]
109
- }], propDecorators: { click: [{
110
- type: Output
111
- }] } });
112
-
113
- const CRAFTSJS_ALERT_DATA = new InjectionToken('CraftsjsAlertData');
114
- class DialogAlertComponent {
115
- constructor(dialogRef, data) {
116
- this.dialogRef = dialogRef;
117
- this.data = data;
118
- }
119
- ngOnInit() {
120
- }
121
- ngAfterViewInit() {
122
- this.loadComponents();
123
- }
124
- loadComponents() {
125
- const itemComponent = alertComponents.find(x => x.type === this.data.type);
126
- const component = itemComponent && itemComponent.component;
127
- this.resolveComponent(component, this.appDynamic.find(x => x.name === 'alert-icon').viewContainerRef);
128
- this.resolveComponent(this.data.customBody, this.appDynamic.find(x => x.name === 'alert-body').viewContainerRef);
129
- this.resolveComponent(this.data.customButtonComponent, this.appDynamic.find(x => x.name === 'alert-buttons').viewContainerRef);
130
- }
131
- resolveComponent(component, viewContainerRef) {
132
- if (!component) {
133
- return;
134
- }
135
- viewContainerRef.clear();
136
- if (component instanceof TemplateRef) {
137
- viewContainerRef.createEmbeddedView(component, { $implicit: this.data, dialogRef: this.dialogRef });
138
- }
139
- else {
140
- const injector = this.createInjector(viewContainerRef.injector);
141
- viewContainerRef.createComponent(component, {
142
- injector
143
- });
144
- }
145
- }
146
- createInjector(injector) {
147
- return Injector.create({
148
- providers: [{
149
- provide: CRAFTSJS_ALERT_DATA,
150
- useValue: this.data
151
- },
152
- {
153
- provide: MatDialogRef,
154
- useValue: this.dialogRef
155
- }],
156
- parent: injector
157
- });
158
- }
159
- buttonClick(result) {
160
- this.dialogRef.close({ data: this.data, result });
161
- }
162
- }
163
- DialogAlertComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: DialogAlertComponent, deps: [{ token: i1$1.MatDialogRef }, { token: MAT_DIALOG_DATA }], target: i0.ɵɵFactoryTarget.Component });
164
- DialogAlertComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: DialogAlertComponent, selector: "dialog-alert", viewQueries: [{ propertyName: "appDynamic", predicate: DynamicDirective, descendants: true }], ngImport: i0, template: "<ng-template craftsjsDynamic name=\"alert-icon\"></ng-template>\n<div *ngIf=\"data?.title\" class=\"alert-title\">\n <span>\n {{data.title | translate}}\n </span>\n</div>\n<div *ngIf=\"data?.text\" class=\"alert-text\">\n <span>\n {{data.text | translate}}\n </span>\n</div>\n<ng-template craftsjsDynamic name=\"alert-body\"></ng-template>\n<div class=\"alert-footer\" *ngIf=\"!data?.hiddenButtons\">\n <alert-ok-button *ngIf=\"!data?.customButtonComponent\" (click)=\"buttonClick('ok')\">\n </alert-ok-button>\n <alert-cancel-button *ngIf=\"!data?.customButtonComponent && data?.showCancelButton\"\n (click)=\"buttonClick('cancel')\">\n </alert-cancel-button>\n</div>\n<ng-template craftsjsDynamic name=\"alert-buttons\"></ng-template>", styles: [".alert-icon{width:80px;height:80px;border-width:4px;border-style:solid;border-radius:50%;padding:0;position:relative;box-sizing:content-box;margin:20px auto}.alert-icon-custom{width:auto;height:auto;max-width:100%;border:none;border-radius:0}.alert-icon img{max-width:100%;max-height:100%}.alert-title{color:#000000a6;font-weight:600;text-transform:none;position:relative;display:block;font-size:27px;line-height:normal;text-align:center;margin-bottom:0}.alert-title:first-child{margin-top:26px}.alert-title:not(:first-child){padding-bottom:0}.alert-title:not(:last-child){margin-bottom:13px}.alert-text{font-size:16px;position:relative;float:none;line-height:normal;vertical-align:top;text-align:center;display:inline-block;margin:0;padding:0 10px;font-weight:400;color:#000000a3;overflow-wrap:break-word;box-sizing:border-box;width:100%}.alert-text:first-child{margin-top:45px}.alert-text:last-child{margin-bottom:45px}.alert-footer{text-align:right;margin-top:13px;padding:13px 16px;border-radius:inherit;border-top-left-radius:0;border-top-right-radius:0}.alert-footer-button-container{margin:5px;display:inline-block;position:relative}.alert-footer>*{display:inline-block;margin-right:.5em}.alert-footer>:last-child{margin-right:inherit}\n"], dependencies: [{ kind: "directive", type: i2$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.DynamicDirective, selector: "[craftsjsDynamic]", inputs: ["name"] }, { kind: "component", type: AlertOkButtonComponent, selector: "alert-ok-button", outputs: ["click"] }, { kind: "component", type: AlertCancelButtonComponent, selector: "alert-cancel-button", outputs: ["click"] }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
165
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: DialogAlertComponent, decorators: [{
166
- type: Component,
167
- args: [{ selector: 'dialog-alert', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<ng-template craftsjsDynamic name=\"alert-icon\"></ng-template>\n<div *ngIf=\"data?.title\" class=\"alert-title\">\n <span>\n {{data.title | translate}}\n </span>\n</div>\n<div *ngIf=\"data?.text\" class=\"alert-text\">\n <span>\n {{data.text | translate}}\n </span>\n</div>\n<ng-template craftsjsDynamic name=\"alert-body\"></ng-template>\n<div class=\"alert-footer\" *ngIf=\"!data?.hiddenButtons\">\n <alert-ok-button *ngIf=\"!data?.customButtonComponent\" (click)=\"buttonClick('ok')\">\n </alert-ok-button>\n <alert-cancel-button *ngIf=\"!data?.customButtonComponent && data?.showCancelButton\"\n (click)=\"buttonClick('cancel')\">\n </alert-cancel-button>\n</div>\n<ng-template craftsjsDynamic name=\"alert-buttons\"></ng-template>", styles: [".alert-icon{width:80px;height:80px;border-width:4px;border-style:solid;border-radius:50%;padding:0;position:relative;box-sizing:content-box;margin:20px auto}.alert-icon-custom{width:auto;height:auto;max-width:100%;border:none;border-radius:0}.alert-icon img{max-width:100%;max-height:100%}.alert-title{color:#000000a6;font-weight:600;text-transform:none;position:relative;display:block;font-size:27px;line-height:normal;text-align:center;margin-bottom:0}.alert-title:first-child{margin-top:26px}.alert-title:not(:first-child){padding-bottom:0}.alert-title:not(:last-child){margin-bottom:13px}.alert-text{font-size:16px;position:relative;float:none;line-height:normal;vertical-align:top;text-align:center;display:inline-block;margin:0;padding:0 10px;font-weight:400;color:#000000a3;overflow-wrap:break-word;box-sizing:border-box;width:100%}.alert-text:first-child{margin-top:45px}.alert-text:last-child{margin-bottom:45px}.alert-footer{text-align:right;margin-top:13px;padding:13px 16px;border-radius:inherit;border-top-left-radius:0;border-top-right-radius:0}.alert-footer-button-container{margin:5px;display:inline-block;position:relative}.alert-footer>*{display:inline-block;margin-right:.5em}.alert-footer>:last-child{margin-right:inherit}\n"] }]
168
- }], ctorParameters: function () {
169
- return [{ type: i1$1.MatDialogRef }, { type: undefined, decorators: [{
170
- type: Inject,
171
- args: [MAT_DIALOG_DATA]
172
- }] }];
173
- }, propDecorators: { appDynamic: [{
174
- type: ViewChildren,
175
- args: [DynamicDirective]
176
- }] } });
177
-
178
- class AlertService {
179
- constructor(_dialog) {
180
- this._dialog = _dialog;
181
- }
182
- showSimple(title, message) {
183
- return this._open({
184
- title,
185
- text: message
186
- });
187
- }
188
- showSuccess(title, message) {
189
- return this._open({
190
- title,
191
- text: message,
192
- type: AlertEnum.success
193
- });
194
- }
195
- showError(title, message) {
196
- return this._open({
197
- title,
198
- text: message,
199
- type: AlertEnum.error
200
- });
201
- }
202
- showInfo(title, message) {
203
- return this._open({
204
- title,
205
- text: message,
206
- type: AlertEnum.info
207
- });
208
- }
209
- showWarning(title, message) {
210
- return this._open({
211
- title,
212
- text: message,
213
- type: AlertEnum.warning
214
- });
215
- }
216
- showConfirmation(title, message) {
217
- return this._open({
218
- title,
219
- text: message,
220
- type: AlertEnum.warning,
221
- showCancelButton: true
222
- });
223
- }
224
- _open(alertModel) {
225
- return this._dialog.open(DialogAlertComponent, {
226
- width: '500px',
227
- data: alertModel
228
- });
229
- }
230
- }
231
- AlertService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AlertService, deps: [{ token: i1$1.MatDialog }], target: i0.ɵɵFactoryTarget.Injectable });
232
- AlertService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AlertService });
233
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AlertService, decorators: [{
234
- type: Injectable
235
- }], ctorParameters: function () { return [{ type: i1$1.MatDialog }]; } });
236
-
237
- class AlertModule {
238
- static forRoot() {
239
- return {
240
- ngModule: AlertModule,
241
- providers: [
242
- AlertService
243
- ]
244
- };
245
- }
246
- }
247
- AlertModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AlertModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
248
- AlertModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.0.4", ngImport: i0, type: AlertModule, declarations: [DialogAlertComponent,
249
- AlertSuccessComponent,
250
- AlertInfoComponent,
251
- WarningComponent,
252
- ErrorComponent,
253
- AlertOkButtonComponent,
254
- AlertCancelButtonComponent], imports: [CommonModule,
255
- TranslateModule,
256
- MatButtonModule,
257
- CoreModule,
258
- MatDialogModule], exports: [DialogAlertComponent] });
259
- AlertModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AlertModule, imports: [CommonModule,
260
- TranslateModule,
261
- MatButtonModule,
262
- CoreModule,
263
- MatDialogModule] });
264
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AlertModule, decorators: [{
265
- type: NgModule,
266
- args: [{
267
- imports: [
268
- CommonModule,
269
- TranslateModule,
270
- MatButtonModule,
271
- CoreModule,
272
- MatDialogModule
273
- ],
274
- declarations: [
275
- DialogAlertComponent,
276
- AlertSuccessComponent,
277
- AlertInfoComponent,
278
- WarningComponent,
279
- ErrorComponent,
280
- AlertOkButtonComponent,
281
- AlertCancelButtonComponent
282
- ],
283
- exports: [
284
- DialogAlertComponent
285
- ]
286
- }]
287
- }] });
288
-
289
- /*
290
- * Public API Surface of alert
291
- */
292
-
293
- /**
294
- * Generated bundle index. Do not edit.
295
- */
296
-
297
- export { AlertCancelButtonComponent, AlertEnum, AlertInfoComponent, AlertModule, AlertOkButtonComponent, AlertService, AlertSuccessComponent, CRAFTSJS_ALERT_DATA, DialogAlertComponent, ErrorComponent, WarningComponent, alertComponents };
298
- //# sourceMappingURL=craftsjs-alert.mjs.map
299
- //# sourceMappingURL=craftsjs-alert.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"craftsjs-alert.mjs","sources":["../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/components/alert-success/alert-success.component.ts","../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/components/alert-success/alert-success.component.html","../../../../projects/craftsjs/alert/src/lib/models/alert-enum.model.ts","../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/components/alert-info/alert-info.component.ts","../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/components/alert-info/alert-info.component.html","../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/components/warning/warning.component.ts","../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/components/warning/warning.component.html","../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/components/error/error.component.ts","../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/components/error/error.component.html","../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/components/components.ts","../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/components/buttons/alert-ok-button/alert-ok-button.component.ts","../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/components/buttons/alert-ok-button/alert-ok-button.component.html","../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/components/buttons/alert-cancel-button/alert-cancel-button.component.ts","../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/components/buttons/alert-cancel-button/alert-cancel-button.component.html","../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/dialog-alert.component.ts","../../../../projects/craftsjs/alert/src/lib/components/dialog-alert/dialog-alert.component.html","../../../../projects/craftsjs/alert/src/lib/services/alert.service.ts","../../../../projects/craftsjs/alert/src/lib/alert.module.ts","../../../../projects/craftsjs/alert/src/public-api.ts","../../../../projects/craftsjs/alert/src/craftsjs-alert.ts"],"sourcesContent":["import { Component, ChangeDetectionStrategy, ViewEncapsulation } from '@angular/core';\n\n@Component({\n selector: 'alert-success',\n templateUrl: './alert-success.component.html',\n styleUrls: ['./alert-success.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n host: {\n class: 'alert-icon alert-icon-success'\n }\n})\nexport class AlertSuccessComponent { }\n","<span class=\"alert-icon-success-line alert-icon-success-line-long\"></span>\n<span class=\"alert-icon-success-line alert-icon-success-line-tip\"></span>\n<div class=\"alert-icon-success-ring\"></div>\n<div class=\"alert-icon-success-hide-corners\"></div>","export enum AlertEnum {\n success = 'success',\n error = 'error',\n info = 'info',\n warning = 'warning'\n}\n","import { Component, ChangeDetectionStrategy, ViewEncapsulation } from '@angular/core';\n\n@Component({\n selector: 'alert-info',\n templateUrl: './alert-info.component.html',\n styleUrls: ['./alert-info.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n host: {\n class: 'alert-icon alert-icon-info'\n }\n})\nexport class AlertInfoComponent { }\n","","import { Component, ChangeDetectionStrategy, ViewEncapsulation } from '@angular/core';\n\n@Component({\n selector: 'alert-warning',\n templateUrl: './warning.component.html',\n styleUrls: ['./warning.component.scss'],\n host: {\n class: 'alert-icon alert-icon-warning '\n },\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None\n})\nexport class WarningComponent { }\n","<span class=\"alert-icon-warning-body\">\n <span class=\"alert-icon-warning-dot\"></span>\n</span>","import { Component, ViewEncapsulation, ChangeDetectionStrategy } from '@angular/core';\n\n@Component({\n selector: 'alert-error',\n templateUrl: './error.component.html',\n styleUrls: ['./error.component.scss'],\n host: {\n class: 'alert-icon alert-icon-error'\n },\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class ErrorComponent { }\n","<div class=\"alert-icon-error-x-mark\">\n <span class=\"alert-icon-error-line alert-icon-error-line-left\"></span>\n <span class=\"alert-icon-error-line alert-icon-error-line-right\"></span>\n</div>","import { AlertSuccessComponent } from './alert-success/alert-success.component';\nimport { AlertEnum } from '../../../models/alert-enum.model';\nimport { AlertInfoComponent } from './alert-info/alert-info.component';\nimport { WarningComponent } from './warning/warning.component';\nimport { ErrorComponent } from './error/error.component';\n\nexport const alertComponents = [\n {\n type: AlertEnum.success,\n component: AlertSuccessComponent\n },\n {\n type: AlertEnum.info,\n component: AlertInfoComponent\n },\n {\n type: AlertEnum.warning,\n component: WarningComponent\n },\n {\n type: AlertEnum.error,\n component: ErrorComponent\n }\n];\n","import { Component, ChangeDetectionStrategy, Output, EventEmitter } from '@angular/core';\n\n@Component({\n selector: 'alert-ok-button',\n templateUrl: './alert-ok-button.component.html',\n styleUrls: ['./alert-ok-button.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class AlertOkButtonComponent {\n @Output()\n click = new EventEmitter();\n}\n","<button mat-raised-button color=\"primary\" (click)=\"click.emit($event)\">{{'general.ok' | translate}}</button>","import { Component, ChangeDetectionStrategy, Output, EventEmitter } from '@angular/core';\n\n@Component({\n selector: 'alert-cancel-button',\n templateUrl: './alert-cancel-button.component.html',\n styleUrls: ['./alert-cancel-button.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class AlertCancelButtonComponent {\n @Output()\n click = new EventEmitter();\n}\n","<button mat-raised-button (click)=\"click.emit($event)\">{{'general.cancel' | translate}}</button>","import {\n Component,\n ChangeDetectionStrategy,\n Inject,\n ViewEncapsulation,\n OnInit,\n Injector,\n InjectionToken,\n Type,\n ViewContainerRef,\n QueryList,\n ViewChildren,\n AfterViewInit,\n TemplateRef\n} from '@angular/core';\nimport { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';\nimport { AlertModel } from '../../models/alert.model';\nimport { alertComponents } from './components/components';\nimport { DynamicDirective } from '@craftsjs/core';\n\nexport const CRAFTSJS_ALERT_DATA = new InjectionToken<any>('CraftsjsAlertData');\n\n@Component({\n selector: 'dialog-alert',\n templateUrl: './dialog-alert.component.html',\n styleUrls: ['./dialog-alert.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None\n})\nexport class DialogAlertComponent implements OnInit, AfterViewInit {\n\n @ViewChildren(DynamicDirective)\n appDynamic: QueryList<DynamicDirective>;\n\n constructor(\n public dialogRef: MatDialogRef<DialogAlertComponent>,\n @Inject(MAT_DIALOG_DATA) public data: AlertModel,\n ) {\n }\n\n ngOnInit(): void {\n\n }\n\n ngAfterViewInit(): void {\n this.loadComponents();\n }\n\n private loadComponents() {\n const itemComponent = alertComponents.find(x => x.type === this.data.type);\n const component = itemComponent && itemComponent.component;\n this.resolveComponent(component, this.appDynamic.find(x => x.name === 'alert-icon').viewContainerRef);\n this.resolveComponent(this.data.customBody, this.appDynamic.find(x => x.name === 'alert-body').viewContainerRef);\n this.resolveComponent(this.data.customButtonComponent, this.appDynamic.find(x => x.name === 'alert-buttons').viewContainerRef);\n }\n\n private resolveComponent(component: Type<any> | TemplateRef<any>, viewContainerRef: ViewContainerRef) {\n if (!component) { return; }\n viewContainerRef.clear();\n if (component instanceof TemplateRef) {\n viewContainerRef.createEmbeddedView(component, { $implicit: this.data, dialogRef: this.dialogRef });\n } else {\n const injector = this.createInjector(viewContainerRef.injector);\n viewContainerRef.createComponent(component, {\n injector\n });\n }\n }\n\n private createInjector(injector: Injector) {\n return Injector.create({\n providers: [{\n provide: CRAFTSJS_ALERT_DATA,\n useValue: this.data\n },\n {\n provide: MatDialogRef,\n useValue: this.dialogRef\n }],\n parent: injector\n })\n }\n\n buttonClick(result: string) {\n this.dialogRef.close({ data: this.data, result });\n }\n\n}\n","<ng-template craftsjsDynamic name=\"alert-icon\"></ng-template>\n<div *ngIf=\"data?.title\" class=\"alert-title\">\n <span>\n {{data.title | translate}}\n </span>\n</div>\n<div *ngIf=\"data?.text\" class=\"alert-text\">\n <span>\n {{data.text | translate}}\n </span>\n</div>\n<ng-template craftsjsDynamic name=\"alert-body\"></ng-template>\n<div class=\"alert-footer\" *ngIf=\"!data?.hiddenButtons\">\n <alert-ok-button *ngIf=\"!data?.customButtonComponent\" (click)=\"buttonClick('ok')\">\n </alert-ok-button>\n <alert-cancel-button *ngIf=\"!data?.customButtonComponent && data?.showCancelButton\"\n (click)=\"buttonClick('cancel')\">\n </alert-cancel-button>\n</div>\n<ng-template craftsjsDynamic name=\"alert-buttons\"></ng-template>","import { Injectable } from '@angular/core';\nimport { MatDialog } from '@angular/material/dialog';\nimport { AlertModel } from '../models/alert.model';\nimport { AlertEnum } from '../models/alert-enum.model';\nimport { DialogAlertComponent } from '../components/dialog-alert/dialog-alert.component';\n\n@Injectable()\nexport class AlertService {\n\n constructor(private _dialog: MatDialog) { }\n\n showSimple(title: string, message: string) {\n return this._open({\n title,\n text: message\n } as AlertModel);\n }\n\n showSuccess(title: string, message: string) {\n return this._open({\n title,\n text: message,\n type: AlertEnum.success\n });\n }\n\n showError(title: string, message: string) {\n return this._open({\n title,\n text: message,\n type: AlertEnum.error\n });\n }\n\n showInfo(title: string, message: string) {\n return this._open({\n title,\n text: message,\n type: AlertEnum.info\n });\n }\n\n showWarning(title: string, message: string) {\n return this._open({\n title,\n text: message,\n type: AlertEnum.warning\n });\n }\n\n showConfirmation(title: string, message: string) {\n return this._open({\n title,\n text: message,\n type: AlertEnum.warning,\n showCancelButton: true\n });\n }\n\n private _open(alertModel: AlertModel) {\n return this._dialog.open(DialogAlertComponent, {\n width: '500px',\n data: alertModel\n });\n }\n}\n","import { NgModule, ModuleWithProviders } from '@angular/core';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatDialogModule } from '@angular/material/dialog';\nimport { TranslateModule } from '@ngx-translate/core';\nimport { CommonModule } from '@angular/common';\nimport { CoreModule } from '@craftsjs/core';\nimport { DialogAlertComponent } from './components/dialog-alert/dialog-alert.component';\nimport { AlertSuccessComponent } from './components/dialog-alert/components/alert-success/alert-success.component';\nimport { AlertInfoComponent } from './components/dialog-alert/components/alert-info/alert-info.component';\nimport { WarningComponent } from './components/dialog-alert/components/warning/warning.component';\nimport { ErrorComponent } from './components/dialog-alert/components/error/error.component';\nimport { AlertOkButtonComponent } from './components/dialog-alert/components/buttons/alert-ok-button/alert-ok-button.component';\nimport {\n AlertCancelButtonComponent\n} from './components/dialog-alert/components/buttons/alert-cancel-button/alert-cancel-button.component';\nimport { AlertService } from './services/alert.service';\n\n@NgModule({\n imports: [\n CommonModule,\n TranslateModule,\n MatButtonModule,\n CoreModule,\n MatDialogModule\n ],\n declarations: [\n DialogAlertComponent,\n AlertSuccessComponent,\n AlertInfoComponent,\n WarningComponent,\n ErrorComponent,\n AlertOkButtonComponent,\n AlertCancelButtonComponent\n ],\n exports: [\n DialogAlertComponent\n ]\n})\nexport class AlertModule {\n static forRoot(): ModuleWithProviders<AlertModule> {\n return {\n ngModule: AlertModule,\n providers: [\n AlertService\n ]\n };\n }\n}\n","/*\n * Public API Surface of alert\n */\n\nexport * from './lib/alert.module';\nexport * from './lib/components/dialog-alert/dialog-alert.component';\nexport * from './lib/components/dialog-alert/components/alert-info/alert-info.component';\nexport * from './lib/components/dialog-alert/components/alert-success/alert-success.component';\nexport * from './lib/components/dialog-alert/components/buttons/alert-cancel-button/alert-cancel-button.component';\nexport * from './lib/components/dialog-alert/components/buttons/alert-ok-button/alert-ok-button.component';\nexport * from './lib/components/dialog-alert/components/components';\nexport * from './lib/components/dialog-alert/components/error/error.component';\nexport * from './lib/components/dialog-alert/components/warning/warning.component';\nexport * from './lib/models/alert-enum.model';\nexport * from './lib/models/alert.model';\nexport * from './lib/services/alert.service';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i2","i4.AlertOkButtonComponent","i5.AlertCancelButtonComponent","i6","i1"],"mappings":";;;;;;;;;;;;;MAYa,qBAAqB,CAAA;;kHAArB,qBAAqB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAArB,qBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,qBAAqB,gHCZlC,iQAGmD,EAAA,MAAA,EAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA,CAAA;2FDStC,qBAAqB,EAAA,UAAA,EAAA,CAAA;kBAVjC,SAAS;+BACE,eAAe,EAAA,eAAA,EAGR,uBAAuB,CAAC,M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