@craftsjs/alert 5.1.0 → 6.1.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/LICENSE +21 -21
- package/README.md +160 -145
- package/_craftsjs-alert.theme.scss +414 -414
- package/esm2022/lib/alert.module.mjs +69 -0
- package/esm2022/lib/alert.providers.mjs +14 -0
- package/esm2022/lib/components/dialog-alert/components/alert-info/alert-info.component.mjs +13 -0
- package/esm2022/lib/components/dialog-alert/components/alert-success/alert-success.component.mjs +13 -0
- package/esm2022/lib/components/dialog-alert/components/buttons/alert-cancel-button/alert-cancel-button.component.mjs +20 -0
- package/esm2022/lib/components/dialog-alert/components/buttons/alert-ok-button/alert-ok-button.component.mjs +20 -0
- package/{esm2020 → esm2022}/lib/components/dialog-alert/components/components.mjs +1 -1
- package/esm2022/lib/components/dialog-alert/components/error/error.component.mjs +13 -0
- package/esm2022/lib/components/dialog-alert/components/warning/warning.component.mjs +13 -0
- package/esm2022/lib/components/dialog-alert/dialog-alert.component.mjs +78 -0
- package/{esm2020 → esm2022}/lib/models/alert-enum.model.mjs +1 -1
- package/esm2022/lib/models/alert.model.mjs +2 -0
- package/{esm2020 → esm2022}/lib/services/alert.service.mjs +5 -5
- package/{esm2020 → esm2022}/public-api.mjs +2 -1
- package/fesm2022/craftsjs-alert.mjs +313 -0
- package/fesm2022/craftsjs-alert.mjs.map +1 -0
- package/lib/alert.module.d.ts +12 -13
- package/lib/alert.providers.d.ts +6 -0
- package/lib/components/dialog-alert/components/alert-info/alert-info.component.d.ts +1 -1
- package/lib/components/dialog-alert/components/alert-success/alert-success.component.d.ts +1 -1
- package/lib/components/dialog-alert/components/buttons/alert-cancel-button/alert-cancel-button.component.d.ts +1 -1
- package/lib/components/dialog-alert/components/buttons/alert-ok-button/alert-ok-button.component.d.ts +1 -1
- package/lib/components/dialog-alert/components/error/error.component.d.ts +1 -1
- package/lib/components/dialog-alert/components/warning/warning.component.d.ts +1 -1
- package/lib/components/dialog-alert/dialog-alert.component.d.ts +1 -1
- package/package.json +12 -17
- package/public-api.d.ts +1 -0
- package/esm2020/lib/alert.module.mjs +0 -67
- package/esm2020/lib/components/dialog-alert/components/alert-info/alert-info.component.mjs +0 -13
- package/esm2020/lib/components/dialog-alert/components/alert-success/alert-success.component.mjs +0 -13
- package/esm2020/lib/components/dialog-alert/components/buttons/alert-cancel-button/alert-cancel-button.component.mjs +0 -18
- package/esm2020/lib/components/dialog-alert/components/buttons/alert-ok-button/alert-ok-button.component.mjs +0 -18
- package/esm2020/lib/components/dialog-alert/components/error/error.component.mjs +0 -13
- package/esm2020/lib/components/dialog-alert/components/warning/warning.component.mjs +0 -13
- package/esm2020/lib/components/dialog-alert/dialog-alert.component.mjs +0 -74
- package/esm2020/lib/models/alert.model.mjs +0 -2
- package/fesm2015/craftsjs-alert.mjs +0 -299
- package/fesm2015/craftsjs-alert.mjs.map +0 -1
- package/fesm2020/craftsjs-alert.mjs +0 -297
- package/fesm2020/craftsjs-alert.mjs.map +0 -1
- /package/{esm2020 → esm2022}/craftsjs-alert.mjs +0 -0
|
@@ -0,0 +1,313 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { ViewEncapsulation, ChangeDetectionStrategy, Component, EventEmitter, Output, InjectionToken, TemplateRef, Injector, ViewChildren, Inject, Injectable, NgModule, makeEnvironmentProviders, importProvidersFrom } 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 { CommonModule } from '@angular/common';
|
|
10
|
+
import { DynamicDirective } from '@craftsjs/core';
|
|
11
|
+
|
|
12
|
+
class AlertSuccessComponent {
|
|
13
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AlertSuccessComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
14
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: AlertSuccessComponent, isStandalone: true, 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>\r\n<span class=\"alert-icon-success-line alert-icon-success-line-tip\"></span>\r\n<div class=\"alert-icon-success-ring\"></div>\r\n<div class=\"alert-icon-success-hide-corners\"></div>", styles: [""], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
15
|
+
}
|
|
16
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AlertSuccessComponent, decorators: [{
|
|
17
|
+
type: Component,
|
|
18
|
+
args: [{ selector: 'alert-success', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, host: {
|
|
19
|
+
class: 'alert-icon alert-icon-success'
|
|
20
|
+
}, standalone: true, template: "<span class=\"alert-icon-success-line alert-icon-success-line-long\"></span>\r\n<span class=\"alert-icon-success-line alert-icon-success-line-tip\"></span>\r\n<div class=\"alert-icon-success-ring\"></div>\r\n<div class=\"alert-icon-success-hide-corners\"></div>" }]
|
|
21
|
+
}] });
|
|
22
|
+
|
|
23
|
+
var AlertEnum;
|
|
24
|
+
(function (AlertEnum) {
|
|
25
|
+
AlertEnum["success"] = "success";
|
|
26
|
+
AlertEnum["error"] = "error";
|
|
27
|
+
AlertEnum["info"] = "info";
|
|
28
|
+
AlertEnum["warning"] = "warning";
|
|
29
|
+
})(AlertEnum || (AlertEnum = {}));
|
|
30
|
+
|
|
31
|
+
class AlertInfoComponent {
|
|
32
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AlertInfoComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
33
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: AlertInfoComponent, isStandalone: true, selector: "alert-info", host: { classAttribute: "alert-icon alert-icon-info" }, ngImport: i0, template: "", styles: [""], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
34
|
+
}
|
|
35
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AlertInfoComponent, decorators: [{
|
|
36
|
+
type: Component,
|
|
37
|
+
args: [{ selector: 'alert-info', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, host: {
|
|
38
|
+
class: 'alert-icon alert-icon-info'
|
|
39
|
+
}, standalone: true, template: "" }]
|
|
40
|
+
}] });
|
|
41
|
+
|
|
42
|
+
class WarningComponent {
|
|
43
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: WarningComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
44
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: WarningComponent, isStandalone: true, selector: "alert-warning", host: { classAttribute: "alert-icon alert-icon-warning " }, ngImport: i0, template: "<span class=\"alert-icon-warning-body\">\r\n <span class=\"alert-icon-warning-dot\"></span>\r\n</span>", styles: [""], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
45
|
+
}
|
|
46
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: WarningComponent, decorators: [{
|
|
47
|
+
type: Component,
|
|
48
|
+
args: [{ selector: 'alert-warning', host: {
|
|
49
|
+
class: 'alert-icon alert-icon-warning '
|
|
50
|
+
}, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, standalone: true, template: "<span class=\"alert-icon-warning-body\">\r\n <span class=\"alert-icon-warning-dot\"></span>\r\n</span>" }]
|
|
51
|
+
}] });
|
|
52
|
+
|
|
53
|
+
class ErrorComponent {
|
|
54
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: ErrorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
55
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: ErrorComponent, isStandalone: true, selector: "alert-error", host: { classAttribute: "alert-icon alert-icon-error" }, ngImport: i0, template: "<div class=\"alert-icon-error-x-mark\">\r\n <span class=\"alert-icon-error-line alert-icon-error-line-left\"></span>\r\n <span class=\"alert-icon-error-line alert-icon-error-line-right\"></span>\r\n</div>", styles: [""], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
56
|
+
}
|
|
57
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: ErrorComponent, decorators: [{
|
|
58
|
+
type: Component,
|
|
59
|
+
args: [{ selector: 'alert-error', host: {
|
|
60
|
+
class: 'alert-icon alert-icon-error'
|
|
61
|
+
}, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, template: "<div class=\"alert-icon-error-x-mark\">\r\n <span class=\"alert-icon-error-line alert-icon-error-line-left\"></span>\r\n <span class=\"alert-icon-error-line alert-icon-error-line-right\"></span>\r\n</div>" }]
|
|
62
|
+
}] });
|
|
63
|
+
|
|
64
|
+
const alertComponents = [
|
|
65
|
+
{
|
|
66
|
+
type: AlertEnum.success,
|
|
67
|
+
component: AlertSuccessComponent
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
type: AlertEnum.info,
|
|
71
|
+
component: AlertInfoComponent
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
type: AlertEnum.warning,
|
|
75
|
+
component: WarningComponent
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
type: AlertEnum.error,
|
|
79
|
+
component: ErrorComponent
|
|
80
|
+
}
|
|
81
|
+
];
|
|
82
|
+
|
|
83
|
+
class AlertOkButtonComponent {
|
|
84
|
+
constructor() {
|
|
85
|
+
this.click = new EventEmitter();
|
|
86
|
+
}
|
|
87
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AlertOkButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
88
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: AlertOkButtonComponent, isStandalone: true, 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: "ngmodule", type: MatButtonModule }, { kind: "component", type: i1.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
89
|
+
}
|
|
90
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AlertOkButtonComponent, decorators: [{
|
|
91
|
+
type: Component,
|
|
92
|
+
args: [{ selector: 'alert-ok-button', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [MatButtonModule, TranslateModule], template: "<button mat-raised-button color=\"primary\" (click)=\"click.emit($event)\">{{'general.ok' | translate}}</button>" }]
|
|
93
|
+
}], propDecorators: { click: [{
|
|
94
|
+
type: Output
|
|
95
|
+
}] } });
|
|
96
|
+
|
|
97
|
+
class AlertCancelButtonComponent {
|
|
98
|
+
constructor() {
|
|
99
|
+
this.click = new EventEmitter();
|
|
100
|
+
}
|
|
101
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AlertCancelButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
102
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: AlertCancelButtonComponent, isStandalone: true, 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: "ngmodule", type: MatButtonModule }, { kind: "component", type: i1.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
103
|
+
}
|
|
104
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AlertCancelButtonComponent, decorators: [{
|
|
105
|
+
type: Component,
|
|
106
|
+
args: [{ selector: 'alert-cancel-button', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [MatButtonModule, TranslateModule], template: "<button mat-raised-button (click)=\"click.emit($event)\">{{'general.cancel' | translate}}</button>" }]
|
|
107
|
+
}], propDecorators: { click: [{
|
|
108
|
+
type: Output
|
|
109
|
+
}] } });
|
|
110
|
+
|
|
111
|
+
const CRAFTSJS_ALERT_DATA = new InjectionToken('CraftsjsAlertData');
|
|
112
|
+
class DialogAlertComponent {
|
|
113
|
+
constructor(dialogRef, data) {
|
|
114
|
+
this.dialogRef = dialogRef;
|
|
115
|
+
this.data = data;
|
|
116
|
+
}
|
|
117
|
+
ngOnInit() {
|
|
118
|
+
}
|
|
119
|
+
ngAfterViewInit() {
|
|
120
|
+
this.loadComponents();
|
|
121
|
+
}
|
|
122
|
+
loadComponents() {
|
|
123
|
+
const itemComponent = alertComponents.find(x => x.type === this.data.type);
|
|
124
|
+
const component = itemComponent && itemComponent.component;
|
|
125
|
+
this.resolveComponent(component, this.appDynamic.find(x => x.name === 'alert-icon').viewContainerRef);
|
|
126
|
+
this.resolveComponent(this.data.customBody, this.appDynamic.find(x => x.name === 'alert-body').viewContainerRef);
|
|
127
|
+
this.resolveComponent(this.data.customButtonComponent, this.appDynamic.find(x => x.name === 'alert-buttons').viewContainerRef);
|
|
128
|
+
}
|
|
129
|
+
resolveComponent(component, viewContainerRef) {
|
|
130
|
+
if (!component) {
|
|
131
|
+
return;
|
|
132
|
+
}
|
|
133
|
+
viewContainerRef.clear();
|
|
134
|
+
if (component instanceof TemplateRef) {
|
|
135
|
+
viewContainerRef.createEmbeddedView(component, { $implicit: this.data, dialogRef: this.dialogRef });
|
|
136
|
+
}
|
|
137
|
+
else {
|
|
138
|
+
const injector = this.createInjector(viewContainerRef.injector);
|
|
139
|
+
viewContainerRef.createComponent(component, {
|
|
140
|
+
injector
|
|
141
|
+
});
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
createInjector(injector) {
|
|
145
|
+
return Injector.create({
|
|
146
|
+
providers: [{
|
|
147
|
+
provide: CRAFTSJS_ALERT_DATA,
|
|
148
|
+
useValue: this.data
|
|
149
|
+
},
|
|
150
|
+
{
|
|
151
|
+
provide: MatDialogRef,
|
|
152
|
+
useValue: this.dialogRef
|
|
153
|
+
}],
|
|
154
|
+
parent: injector
|
|
155
|
+
});
|
|
156
|
+
}
|
|
157
|
+
buttonClick(result) {
|
|
158
|
+
this.dialogRef.close({ data: this.data, result });
|
|
159
|
+
}
|
|
160
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DialogAlertComponent, deps: [{ token: i1$1.MatDialogRef }, { token: MAT_DIALOG_DATA }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
161
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.13", type: DialogAlertComponent, isStandalone: true, selector: "dialog-alert", viewQueries: [{ propertyName: "appDynamic", predicate: DynamicDirective, descendants: true }], ngImport: i0, template: "<ng-template craftsjsDynamic name=\"alert-icon\"></ng-template>\r\n@if (data?.title) {\r\n <div class=\"alert-title\">\r\n <span>\r\n {{data.title | translate}}\r\n </span>\r\n </div>\r\n}\r\n@if (data?.text) {\r\n <div class=\"alert-text\">\r\n <span>\r\n {{data.text | translate}}\r\n </span>\r\n </div>\r\n}\r\n<ng-template craftsjsDynamic name=\"alert-body\"></ng-template>\r\n@if (!data?.hiddenButtons) {\r\n <div class=\"alert-footer\">\r\n @if (!data?.customButtonComponent) {\r\n <alert-ok-button (click)=\"buttonClick('ok')\">\r\n </alert-ok-button>\r\n }\r\n @if (!data?.customButtonComponent && data?.showCancelButton) {\r\n <alert-cancel-button\r\n (click)=\"buttonClick('cancel')\">\r\n </alert-cancel-button>\r\n }\r\n </div>\r\n}\r\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: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }, { kind: "directive", type: 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"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
162
|
+
}
|
|
163
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DialogAlertComponent, decorators: [{
|
|
164
|
+
type: Component,
|
|
165
|
+
args: [{ selector: 'dialog-alert', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, standalone: true, imports: [
|
|
166
|
+
TranslateModule,
|
|
167
|
+
DynamicDirective,
|
|
168
|
+
AlertOkButtonComponent,
|
|
169
|
+
AlertCancelButtonComponent
|
|
170
|
+
], template: "<ng-template craftsjsDynamic name=\"alert-icon\"></ng-template>\r\n@if (data?.title) {\r\n <div class=\"alert-title\">\r\n <span>\r\n {{data.title | translate}}\r\n </span>\r\n </div>\r\n}\r\n@if (data?.text) {\r\n <div class=\"alert-text\">\r\n <span>\r\n {{data.text | translate}}\r\n </span>\r\n </div>\r\n}\r\n<ng-template craftsjsDynamic name=\"alert-body\"></ng-template>\r\n@if (!data?.hiddenButtons) {\r\n <div class=\"alert-footer\">\r\n @if (!data?.customButtonComponent) {\r\n <alert-ok-button (click)=\"buttonClick('ok')\">\r\n </alert-ok-button>\r\n }\r\n @if (!data?.customButtonComponent && data?.showCancelButton) {\r\n <alert-cancel-button\r\n (click)=\"buttonClick('cancel')\">\r\n </alert-cancel-button>\r\n }\r\n </div>\r\n}\r\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"] }]
|
|
171
|
+
}], ctorParameters: () => [{ type: i1$1.MatDialogRef }, { type: undefined, decorators: [{
|
|
172
|
+
type: Inject,
|
|
173
|
+
args: [MAT_DIALOG_DATA]
|
|
174
|
+
}] }], propDecorators: { appDynamic: [{
|
|
175
|
+
type: ViewChildren,
|
|
176
|
+
args: [DynamicDirective]
|
|
177
|
+
}] } });
|
|
178
|
+
|
|
179
|
+
class AlertService {
|
|
180
|
+
constructor(_dialog) {
|
|
181
|
+
this._dialog = _dialog;
|
|
182
|
+
}
|
|
183
|
+
showSimple(title, message) {
|
|
184
|
+
return this._open({
|
|
185
|
+
title,
|
|
186
|
+
text: message
|
|
187
|
+
});
|
|
188
|
+
}
|
|
189
|
+
showSuccess(title, message) {
|
|
190
|
+
return this._open({
|
|
191
|
+
title,
|
|
192
|
+
text: message,
|
|
193
|
+
type: AlertEnum.success
|
|
194
|
+
});
|
|
195
|
+
}
|
|
196
|
+
showError(title, message) {
|
|
197
|
+
return this._open({
|
|
198
|
+
title,
|
|
199
|
+
text: message,
|
|
200
|
+
type: AlertEnum.error
|
|
201
|
+
});
|
|
202
|
+
}
|
|
203
|
+
showInfo(title, message) {
|
|
204
|
+
return this._open({
|
|
205
|
+
title,
|
|
206
|
+
text: message,
|
|
207
|
+
type: AlertEnum.info
|
|
208
|
+
});
|
|
209
|
+
}
|
|
210
|
+
showWarning(title, message) {
|
|
211
|
+
return this._open({
|
|
212
|
+
title,
|
|
213
|
+
text: message,
|
|
214
|
+
type: AlertEnum.warning
|
|
215
|
+
});
|
|
216
|
+
}
|
|
217
|
+
showConfirmation(title, message) {
|
|
218
|
+
return this._open({
|
|
219
|
+
title,
|
|
220
|
+
text: message,
|
|
221
|
+
type: AlertEnum.warning,
|
|
222
|
+
showCancelButton: true
|
|
223
|
+
});
|
|
224
|
+
}
|
|
225
|
+
_open(alertModel) {
|
|
226
|
+
return this._dialog.open(DialogAlertComponent, {
|
|
227
|
+
width: '500px',
|
|
228
|
+
data: alertModel
|
|
229
|
+
});
|
|
230
|
+
}
|
|
231
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AlertService, deps: [{ token: i1$1.MatDialog }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
232
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AlertService }); }
|
|
233
|
+
}
|
|
234
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AlertService, decorators: [{
|
|
235
|
+
type: Injectable
|
|
236
|
+
}], ctorParameters: () => [{ type: i1$1.MatDialog }] });
|
|
237
|
+
|
|
238
|
+
class AlertModule {
|
|
239
|
+
static forRoot() {
|
|
240
|
+
return {
|
|
241
|
+
ngModule: AlertModule,
|
|
242
|
+
providers: [
|
|
243
|
+
AlertService
|
|
244
|
+
]
|
|
245
|
+
};
|
|
246
|
+
}
|
|
247
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AlertModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
248
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.13", ngImport: i0, type: AlertModule, imports: [CommonModule,
|
|
249
|
+
TranslateModule,
|
|
250
|
+
MatButtonModule,
|
|
251
|
+
MatDialogModule,
|
|
252
|
+
// standalone components used by consumers or inside the dialog
|
|
253
|
+
DialogAlertComponent,
|
|
254
|
+
AlertSuccessComponent,
|
|
255
|
+
AlertInfoComponent,
|
|
256
|
+
WarningComponent,
|
|
257
|
+
ErrorComponent,
|
|
258
|
+
AlertOkButtonComponent,
|
|
259
|
+
AlertCancelButtonComponent], exports: [DialogAlertComponent] }); }
|
|
260
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AlertModule, imports: [CommonModule,
|
|
261
|
+
TranslateModule,
|
|
262
|
+
MatButtonModule,
|
|
263
|
+
MatDialogModule,
|
|
264
|
+
// standalone components used by consumers or inside the dialog
|
|
265
|
+
DialogAlertComponent,
|
|
266
|
+
AlertOkButtonComponent,
|
|
267
|
+
AlertCancelButtonComponent] }); }
|
|
268
|
+
}
|
|
269
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AlertModule, decorators: [{
|
|
270
|
+
type: NgModule,
|
|
271
|
+
args: [{
|
|
272
|
+
imports: [
|
|
273
|
+
CommonModule,
|
|
274
|
+
TranslateModule,
|
|
275
|
+
MatButtonModule,
|
|
276
|
+
MatDialogModule,
|
|
277
|
+
// standalone components used by consumers or inside the dialog
|
|
278
|
+
DialogAlertComponent,
|
|
279
|
+
AlertSuccessComponent,
|
|
280
|
+
AlertInfoComponent,
|
|
281
|
+
WarningComponent,
|
|
282
|
+
ErrorComponent,
|
|
283
|
+
AlertOkButtonComponent,
|
|
284
|
+
AlertCancelButtonComponent
|
|
285
|
+
],
|
|
286
|
+
declarations: [],
|
|
287
|
+
exports: [
|
|
288
|
+
DialogAlertComponent
|
|
289
|
+
]
|
|
290
|
+
}]
|
|
291
|
+
}] });
|
|
292
|
+
|
|
293
|
+
/**
|
|
294
|
+
* Standalone provider for CraftsJS Alert.
|
|
295
|
+
* - Provides MatDialog infrastructure and AlertService.
|
|
296
|
+
*/
|
|
297
|
+
function provideCraftsjsAlert() {
|
|
298
|
+
return makeEnvironmentProviders([
|
|
299
|
+
importProvidersFrom(MatDialogModule),
|
|
300
|
+
AlertService
|
|
301
|
+
]);
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
/*
|
|
305
|
+
* Public API Surface of alert
|
|
306
|
+
*/
|
|
307
|
+
|
|
308
|
+
/**
|
|
309
|
+
* Generated bundle index. Do not edit.
|
|
310
|
+
*/
|
|
311
|
+
|
|
312
|
+
export { AlertCancelButtonComponent, AlertEnum, AlertInfoComponent, AlertModule, AlertOkButtonComponent, AlertService, AlertSuccessComponent, CRAFTSJS_ALERT_DATA, DialogAlertComponent, ErrorComponent, WarningComponent, alertComponents, provideCraftsjsAlert };
|
|
313
|
+
//# sourceMappingURL=craftsjs-alert.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
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/lib/alert.providers.ts","../../../../projects/craftsjs/alert/src/public-api.ts","../../../../projects/craftsjs/alert/src/craftsjs-alert.ts"],"sourcesContent":["import { Component, ChangeDetectionStrategy, ViewEncapsulation } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'alert-success',\r\n templateUrl: './alert-success.component.html',\r\n styleUrls: ['./alert-success.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n encapsulation: ViewEncapsulation.None,\r\n host: {\r\n class: 'alert-icon alert-icon-success'\r\n },\r\n standalone: true\r\n})\r\nexport class AlertSuccessComponent { }\r\n","<span class=\"alert-icon-success-line alert-icon-success-line-long\"></span>\r\n<span class=\"alert-icon-success-line alert-icon-success-line-tip\"></span>\r\n<div class=\"alert-icon-success-ring\"></div>\r\n<div class=\"alert-icon-success-hide-corners\"></div>","export enum AlertEnum {\r\n success = 'success',\r\n error = 'error',\r\n info = 'info',\r\n warning = 'warning'\r\n}\r\n","import { Component, ChangeDetectionStrategy, ViewEncapsulation } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'alert-info',\r\n templateUrl: './alert-info.component.html',\r\n styleUrls: ['./alert-info.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n encapsulation: ViewEncapsulation.None,\r\n host: {\r\n class: 'alert-icon alert-icon-info'\r\n },\r\n standalone: true\r\n})\r\nexport class AlertInfoComponent { }\r\n","","import { Component, ChangeDetectionStrategy, ViewEncapsulation } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'alert-warning',\r\n templateUrl: './warning.component.html',\r\n styleUrls: ['./warning.component.scss'],\r\n host: {\r\n class: 'alert-icon alert-icon-warning '\r\n },\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n encapsulation: ViewEncapsulation.None,\r\n standalone: true\r\n})\r\nexport class WarningComponent { }\r\n","<span class=\"alert-icon-warning-body\">\r\n <span class=\"alert-icon-warning-dot\"></span>\r\n</span>","import { Component, ViewEncapsulation, ChangeDetectionStrategy } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'alert-error',\r\n templateUrl: './error.component.html',\r\n styleUrls: ['./error.component.scss'],\r\n host: {\r\n class: 'alert-icon alert-icon-error'\r\n },\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n standalone: true\r\n})\r\nexport class ErrorComponent { }\r\n","<div class=\"alert-icon-error-x-mark\">\r\n <span class=\"alert-icon-error-line alert-icon-error-line-left\"></span>\r\n <span class=\"alert-icon-error-line alert-icon-error-line-right\"></span>\r\n</div>","import { AlertSuccessComponent } from './alert-success/alert-success.component';\r\nimport { AlertEnum } from '../../../models/alert-enum.model';\r\nimport { AlertInfoComponent } from './alert-info/alert-info.component';\r\nimport { WarningComponent } from './warning/warning.component';\r\nimport { ErrorComponent } from './error/error.component';\r\n\r\nexport const alertComponents = [\r\n {\r\n type: AlertEnum.success,\r\n component: AlertSuccessComponent\r\n },\r\n {\r\n type: AlertEnum.info,\r\n component: AlertInfoComponent\r\n },\r\n {\r\n type: AlertEnum.warning,\r\n component: WarningComponent\r\n },\r\n {\r\n type: AlertEnum.error,\r\n component: ErrorComponent\r\n }\r\n];\r\n","import { Component, ChangeDetectionStrategy, Output, EventEmitter } from '@angular/core';\r\nimport { MatButtonModule } from '@angular/material/button';\r\nimport { TranslateModule } from '@ngx-translate/core';\r\n\r\n@Component({\r\n selector: 'alert-ok-button',\r\n templateUrl: './alert-ok-button.component.html',\r\n styleUrls: ['./alert-ok-button.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n standalone: true,\r\n imports: [MatButtonModule, TranslateModule]\r\n})\r\nexport class AlertOkButtonComponent {\r\n @Output()\r\n click = new EventEmitter();\r\n}\r\n","<button mat-raised-button color=\"primary\" (click)=\"click.emit($event)\">{{'general.ok' | translate}}</button>","import { Component, ChangeDetectionStrategy, Output, EventEmitter } from '@angular/core';\r\nimport { MatButtonModule } from '@angular/material/button';\r\nimport { TranslateModule } from '@ngx-translate/core';\r\n\r\n@Component({\r\n selector: 'alert-cancel-button',\r\n templateUrl: './alert-cancel-button.component.html',\r\n styleUrls: ['./alert-cancel-button.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n standalone: true,\r\n imports: [MatButtonModule, TranslateModule]\r\n})\r\nexport class AlertCancelButtonComponent {\r\n @Output()\r\n click = new EventEmitter();\r\n}\r\n","<button mat-raised-button (click)=\"click.emit($event)\">{{'general.cancel' | translate}}</button>","import {\r\n Component,\r\n ChangeDetectionStrategy,\r\n Inject,\r\n ViewEncapsulation,\r\n OnInit,\r\n Injector,\r\n InjectionToken,\r\n Type,\r\n ViewContainerRef,\r\n QueryList,\r\n ViewChildren,\r\n AfterViewInit,\r\n TemplateRef\r\n} from '@angular/core';\r\nimport { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';\r\nimport { AlertModel } from '../../models/alert.model';\r\nimport { alertComponents } from './components/components';\r\nimport { DynamicDirective } from '@craftsjs/core';\r\n\r\nimport { TranslateModule } from '@ngx-translate/core';\r\nimport { AlertOkButtonComponent } from './components/buttons/alert-ok-button/alert-ok-button.component';\r\nimport { AlertCancelButtonComponent } from './components/buttons/alert-cancel-button/alert-cancel-button.component';\r\n\r\nexport const CRAFTSJS_ALERT_DATA = new InjectionToken<any>('CraftsjsAlertData');\r\n\r\n@Component({\r\n selector: 'dialog-alert',\r\n templateUrl: './dialog-alert.component.html',\r\n styleUrls: ['./dialog-alert.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n encapsulation: ViewEncapsulation.None,\r\n standalone: true,\r\n imports: [\r\n TranslateModule,\r\n DynamicDirective,\r\n AlertOkButtonComponent,\r\n AlertCancelButtonComponent\r\n]\r\n})\r\nexport class DialogAlertComponent implements OnInit, AfterViewInit {\r\n\r\n @ViewChildren(DynamicDirective)\r\n appDynamic: QueryList<DynamicDirective>;\r\n\r\n constructor(\r\n public dialogRef: MatDialogRef<DialogAlertComponent>,\r\n @Inject(MAT_DIALOG_DATA) public data: AlertModel,\r\n ) {\r\n }\r\n\r\n ngOnInit(): void {\r\n\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n this.loadComponents();\r\n }\r\n\r\n private loadComponents() {\r\n const itemComponent = alertComponents.find(x => x.type === this.data.type);\r\n const component = itemComponent && itemComponent.component;\r\n this.resolveComponent(component, this.appDynamic.find(x => x.name === 'alert-icon').viewContainerRef);\r\n this.resolveComponent(this.data.customBody, this.appDynamic.find(x => x.name === 'alert-body').viewContainerRef);\r\n this.resolveComponent(this.data.customButtonComponent, this.appDynamic.find(x => x.name === 'alert-buttons').viewContainerRef);\r\n }\r\n\r\n private resolveComponent(component: Type<any> | TemplateRef<any>, viewContainerRef: ViewContainerRef) {\r\n if (!component) { return; }\r\n viewContainerRef.clear();\r\n if (component instanceof TemplateRef) {\r\n viewContainerRef.createEmbeddedView(component, { $implicit: this.data, dialogRef: this.dialogRef });\r\n } else {\r\n const injector = this.createInjector(viewContainerRef.injector);\r\n viewContainerRef.createComponent(component, {\r\n injector\r\n });\r\n }\r\n }\r\n\r\n private createInjector(injector: Injector) {\r\n return Injector.create({\r\n providers: [{\r\n provide: CRAFTSJS_ALERT_DATA,\r\n useValue: this.data\r\n },\r\n {\r\n provide: MatDialogRef,\r\n useValue: this.dialogRef\r\n }],\r\n parent: injector\r\n })\r\n }\r\n\r\n buttonClick(result: string) {\r\n this.dialogRef.close({ data: this.data, result });\r\n }\r\n\r\n}\r\n","<ng-template craftsjsDynamic name=\"alert-icon\"></ng-template>\r\n@if (data?.title) {\r\n <div class=\"alert-title\">\r\n <span>\r\n {{data.title | translate}}\r\n </span>\r\n </div>\r\n}\r\n@if (data?.text) {\r\n <div class=\"alert-text\">\r\n <span>\r\n {{data.text | translate}}\r\n </span>\r\n </div>\r\n}\r\n<ng-template craftsjsDynamic name=\"alert-body\"></ng-template>\r\n@if (!data?.hiddenButtons) {\r\n <div class=\"alert-footer\">\r\n @if (!data?.customButtonComponent) {\r\n <alert-ok-button (click)=\"buttonClick('ok')\">\r\n </alert-ok-button>\r\n }\r\n @if (!data?.customButtonComponent && data?.showCancelButton) {\r\n <alert-cancel-button\r\n (click)=\"buttonClick('cancel')\">\r\n </alert-cancel-button>\r\n }\r\n </div>\r\n}\r\n<ng-template craftsjsDynamic name=\"alert-buttons\"></ng-template>","import { Injectable } from '@angular/core';\r\nimport { MatDialog } from '@angular/material/dialog';\r\nimport { AlertModel } from '../models/alert.model';\r\nimport { AlertEnum } from '../models/alert-enum.model';\r\nimport { DialogAlertComponent } from '../components/dialog-alert/dialog-alert.component';\r\n\r\n@Injectable()\r\nexport class AlertService {\r\n\r\n constructor(private _dialog: MatDialog) { }\r\n\r\n showSimple(title: string, message: string) {\r\n return this._open({\r\n title,\r\n text: message\r\n } as AlertModel);\r\n }\r\n\r\n showSuccess(title: string, message: string) {\r\n return this._open({\r\n title,\r\n text: message,\r\n type: AlertEnum.success\r\n });\r\n }\r\n\r\n showError(title: string, message: string) {\r\n return this._open({\r\n title,\r\n text: message,\r\n type: AlertEnum.error\r\n });\r\n }\r\n\r\n showInfo(title: string, message: string) {\r\n return this._open({\r\n title,\r\n text: message,\r\n type: AlertEnum.info\r\n });\r\n }\r\n\r\n showWarning(title: string, message: string) {\r\n return this._open({\r\n title,\r\n text: message,\r\n type: AlertEnum.warning\r\n });\r\n }\r\n\r\n showConfirmation(title: string, message: string) {\r\n return this._open({\r\n title,\r\n text: message,\r\n type: AlertEnum.warning,\r\n showCancelButton: true\r\n });\r\n }\r\n\r\n private _open(alertModel: AlertModel) {\r\n return this._dialog.open(DialogAlertComponent, {\r\n width: '500px',\r\n data: alertModel\r\n });\r\n }\r\n}\r\n","import { NgModule, ModuleWithProviders } from '@angular/core';\r\nimport { MatButtonModule } from '@angular/material/button';\r\nimport { MatDialogModule } from '@angular/material/dialog';\r\nimport { TranslateModule } from '@ngx-translate/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { DialogAlertComponent } from './components/dialog-alert/dialog-alert.component';\r\nimport { AlertSuccessComponent } from './components/dialog-alert/components/alert-success/alert-success.component';\r\nimport { AlertInfoComponent } from './components/dialog-alert/components/alert-info/alert-info.component';\r\nimport { WarningComponent } from './components/dialog-alert/components/warning/warning.component';\r\nimport { ErrorComponent } from './components/dialog-alert/components/error/error.component';\r\nimport { AlertOkButtonComponent } from './components/dialog-alert/components/buttons/alert-ok-button/alert-ok-button.component';\r\nimport {\r\n AlertCancelButtonComponent\r\n} from './components/dialog-alert/components/buttons/alert-cancel-button/alert-cancel-button.component';\r\nimport { AlertService } from './services/alert.service';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n TranslateModule,\r\n MatButtonModule,\r\n MatDialogModule,\r\n // standalone components used by consumers or inside the dialog\r\n DialogAlertComponent,\r\n AlertSuccessComponent,\r\n AlertInfoComponent,\r\n WarningComponent,\r\n ErrorComponent,\r\n AlertOkButtonComponent,\r\n AlertCancelButtonComponent\r\n ],\r\n declarations: [],\r\n exports: [\r\n DialogAlertComponent\r\n ]\r\n})\r\nexport class AlertModule {\r\n static forRoot(): ModuleWithProviders<AlertModule> {\r\n return {\r\n ngModule: AlertModule,\r\n providers: [\r\n AlertService\r\n ]\r\n };\r\n }\r\n}\r\n","import { EnvironmentProviders, importProvidersFrom, makeEnvironmentProviders } from '@angular/core';\r\nimport { MatDialogModule } from '@angular/material/dialog';\r\nimport { AlertService } from './services/alert.service';\r\n\r\n/**\r\n * Standalone provider for CraftsJS Alert.\r\n * - Provides MatDialog infrastructure and AlertService.\r\n */\r\nexport function provideCraftsjsAlert(): EnvironmentProviders {\r\n return makeEnvironmentProviders([\r\n importProvidersFrom(MatDialogModule),\r\n AlertService\r\n ]);\r\n}\r\n","/*\r\n * Public API Surface of alert\r\n */\r\n\r\nexport * from './lib/alert.module';\r\nexport * from './lib/components/dialog-alert/dialog-alert.component';\r\nexport * from './lib/components/dialog-alert/components/alert-info/alert-info.component';\r\nexport * from './lib/components/dialog-alert/components/alert-success/alert-success.component';\r\nexport * from './lib/components/dialog-alert/components/buttons/alert-cancel-button/alert-cancel-button.component';\r\nexport * from './lib/components/dialog-alert/components/buttons/alert-ok-button/alert-ok-button.component';\r\nexport * from './lib/components/dialog-alert/components/components';\r\nexport * from './lib/components/dialog-alert/components/error/error.component';\r\nexport * from './lib/components/dialog-alert/components/warning/warning.component';\r\nexport * from './lib/models/alert-enum.model';\r\nexport * from './lib/models/alert.model';\r\nexport * from './lib/services/alert.service';\r\nexport * from './lib/alert.providers';\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i1"],"mappings":";;;;;;;;;;;MAaa,qBAAqB,CAAA;+GAArB,qBAAqB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,C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oB,CAAA,EAAA,CAAA,CAAA;AAGf,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAW,YAlBhB,YAAY;YACZ,eAAe;YACf,eAAe;YACnB,eAAe;;YAEf,oBAAoB;YAKpB,sBAAsB;YACtB,0BAA0B,CAAA,EAAA,CAAA,CAAA;;4FAOjB,WAAW,EAAA,UAAA,EAAA,CAAA;kBApBvB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACN,oBAAA,OAAO,EAAE;wBACL,YAAY;wBACZ,eAAe;wBACf,eAAe;wBACnB,eAAe;;wBAEf,oBAAoB;wBACpB,qBAAqB;wBACrB,kBAAkB;wBAClB,gBAAgB;wBAChB,cAAc;wBACd,sBAAsB;wBACtB;AACC,qBAAA;AACH,oBAAA,YAAY,EAAE,EAAE;AACd,oBAAA,OAAO,EAAE;wBACL;AACH;AACJ,iBAAA;;;AC/BD;;;AAGG;SACa,oBAAoB,GAAA;AAClC,IAAA,OAAO,wBAAwB,CAAC;QAC9B,mBAAmB,CAAC,eAAe,CAAC;QACpC;AACD,KAAA,CAAC;AACJ;;ACbA;;AAEG;;ACFH;;AAEG;;;;"}
|
package/lib/alert.module.d.ts
CHANGED
|
@@ -1,20 +1,19 @@
|
|
|
1
1
|
import { ModuleWithProviders } from '@angular/core';
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
|
-
import * as i1 from "
|
|
4
|
-
import * as i2 from "
|
|
5
|
-
import * as i3 from "
|
|
6
|
-
import * as i4 from "
|
|
7
|
-
import * as i5 from "./components/dialog-alert/
|
|
8
|
-
import * as i6 from "./components/dialog-alert/components/
|
|
9
|
-
import * as i7 from "./components/dialog-alert/components/
|
|
10
|
-
import * as i8 from "
|
|
11
|
-
import * as i9 from "
|
|
12
|
-
import * as i10 from "
|
|
13
|
-
import * as i11 from "
|
|
14
|
-
import * as i12 from "@angular/material/dialog";
|
|
3
|
+
import * as i1 from "@angular/common";
|
|
4
|
+
import * as i2 from "@ngx-translate/core";
|
|
5
|
+
import * as i3 from "@angular/material/button";
|
|
6
|
+
import * as i4 from "@angular/material/dialog";
|
|
7
|
+
import * as i5 from "./components/dialog-alert/dialog-alert.component";
|
|
8
|
+
import * as i6 from "./components/dialog-alert/components/alert-success/alert-success.component";
|
|
9
|
+
import * as i7 from "./components/dialog-alert/components/alert-info/alert-info.component";
|
|
10
|
+
import * as i8 from "./components/dialog-alert/components/warning/warning.component";
|
|
11
|
+
import * as i9 from "./components/dialog-alert/components/error/error.component";
|
|
12
|
+
import * as i10 from "./components/dialog-alert/components/buttons/alert-ok-button/alert-ok-button.component";
|
|
13
|
+
import * as i11 from "./components/dialog-alert/components/buttons/alert-cancel-button/alert-cancel-button.component";
|
|
15
14
|
export declare class AlertModule {
|
|
16
15
|
static forRoot(): ModuleWithProviders<AlertModule>;
|
|
17
16
|
static ɵfac: i0.ɵɵFactoryDeclaration<AlertModule, never>;
|
|
18
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<AlertModule, [typeof i1.
|
|
17
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<AlertModule, never, [typeof i1.CommonModule, typeof i2.TranslateModule, typeof i3.MatButtonModule, typeof i4.MatDialogModule, typeof i5.DialogAlertComponent, typeof i6.AlertSuccessComponent, typeof i7.AlertInfoComponent, typeof i8.WarningComponent, typeof i9.ErrorComponent, typeof i10.AlertOkButtonComponent, typeof i11.AlertCancelButtonComponent], [typeof i5.DialogAlertComponent]>;
|
|
19
18
|
static ɵinj: i0.ɵɵInjectorDeclaration<AlertModule>;
|
|
20
19
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
export declare class AlertInfoComponent {
|
|
3
3
|
static ɵfac: i0.ɵɵFactoryDeclaration<AlertInfoComponent, never>;
|
|
4
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<AlertInfoComponent, "alert-info", never, {}, {}, never, never,
|
|
4
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AlertInfoComponent, "alert-info", never, {}, {}, never, never, true, never>;
|
|
5
5
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
export declare class AlertSuccessComponent {
|
|
3
3
|
static ɵfac: i0.ɵɵFactoryDeclaration<AlertSuccessComponent, never>;
|
|
4
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<AlertSuccessComponent, "alert-success", never, {}, {}, never, never,
|
|
4
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AlertSuccessComponent, "alert-success", never, {}, {}, never, never, true, never>;
|
|
5
5
|
}
|
|
@@ -3,5 +3,5 @@ import * as i0 from "@angular/core";
|
|
|
3
3
|
export declare class AlertCancelButtonComponent {
|
|
4
4
|
click: EventEmitter<any>;
|
|
5
5
|
static ɵfac: i0.ɵɵFactoryDeclaration<AlertCancelButtonComponent, never>;
|
|
6
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<AlertCancelButtonComponent, "alert-cancel-button", never, {}, { "click": "click"; }, never, never,
|
|
6
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AlertCancelButtonComponent, "alert-cancel-button", never, {}, { "click": "click"; }, never, never, true, never>;
|
|
7
7
|
}
|
|
@@ -3,5 +3,5 @@ import * as i0 from "@angular/core";
|
|
|
3
3
|
export declare class AlertOkButtonComponent {
|
|
4
4
|
click: EventEmitter<any>;
|
|
5
5
|
static ɵfac: i0.ɵɵFactoryDeclaration<AlertOkButtonComponent, never>;
|
|
6
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<AlertOkButtonComponent, "alert-ok-button", never, {}, { "click": "click"; }, never, never,
|
|
6
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AlertOkButtonComponent, "alert-ok-button", never, {}, { "click": "click"; }, never, never, true, never>;
|
|
7
7
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
export declare class ErrorComponent {
|
|
3
3
|
static ɵfac: i0.ɵɵFactoryDeclaration<ErrorComponent, never>;
|
|
4
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<ErrorComponent, "alert-error", never, {}, {}, never, never,
|
|
4
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ErrorComponent, "alert-error", never, {}, {}, never, never, true, never>;
|
|
5
5
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
export declare class WarningComponent {
|
|
3
3
|
static ɵfac: i0.ɵɵFactoryDeclaration<WarningComponent, never>;
|
|
4
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<WarningComponent, "alert-warning", never, {}, {}, never, never,
|
|
4
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<WarningComponent, "alert-warning", never, {}, {}, never, never, true, never>;
|
|
5
5
|
}
|
|
@@ -16,5 +16,5 @@ export declare class DialogAlertComponent implements OnInit, AfterViewInit {
|
|
|
16
16
|
private createInjector;
|
|
17
17
|
buttonClick(result: string): void;
|
|
18
18
|
static ɵfac: i0.ɵɵFactoryDeclaration<DialogAlertComponent, never>;
|
|
19
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<DialogAlertComponent, "dialog-alert", never, {}, {}, never, never,
|
|
19
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<DialogAlertComponent, "dialog-alert", never, {}, {}, never, never, true, never>;
|
|
20
20
|
}
|
package/package.json
CHANGED
|
@@ -1,18 +1,19 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@craftsjs/alert",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "6.1.0",
|
|
4
4
|
"author": "craftsjs",
|
|
5
5
|
"description": "Material alert library for angular",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"homepage": "https://github.com/addapptables/angular-miscellaneous",
|
|
8
8
|
"peerDependencies": {
|
|
9
|
-
"@angular/common": ">=
|
|
10
|
-
"@angular/core": ">=
|
|
11
|
-
"@angular/material": ">=
|
|
12
|
-
"@angular/cdk": ">=
|
|
13
|
-
"@angular/animations": ">=
|
|
9
|
+
"@angular/common": ">= 18.0.0 < 19.0.0",
|
|
10
|
+
"@angular/core": ">= 18.0.0 < 19.0.0",
|
|
11
|
+
"@angular/material": ">= 18.0.0 < 19.0.0",
|
|
12
|
+
"@angular/cdk": ">= 18.0.0 < 19.0.0",
|
|
13
|
+
"@angular/animations": ">= 18.0.0 < 19.0.0",
|
|
14
14
|
"@ngx-translate/core": ">= 14.0.0 < 17.0.0",
|
|
15
|
-
"@craftsjs/core": ">=
|
|
15
|
+
"@craftsjs/core": ">=6.1.0 < 7.0.0",
|
|
16
|
+
"rxjs": "6.6.3"
|
|
16
17
|
},
|
|
17
18
|
"repository": {
|
|
18
19
|
"type": "git",
|
|
@@ -31,11 +32,7 @@
|
|
|
31
32
|
"dependencies": {
|
|
32
33
|
"tslib": "^2.0.0"
|
|
33
34
|
},
|
|
34
|
-
"module": "
|
|
35
|
-
"es2020": "fesm2020/craftsjs-alert.mjs",
|
|
36
|
-
"esm2020": "esm2020/craftsjs-alert.mjs",
|
|
37
|
-
"fesm2020": "fesm2020/craftsjs-alert.mjs",
|
|
38
|
-
"fesm2015": "fesm2015/craftsjs-alert.mjs",
|
|
35
|
+
"module": "fesm2022/craftsjs-alert.mjs",
|
|
39
36
|
"typings": "index.d.ts",
|
|
40
37
|
"exports": {
|
|
41
38
|
"./package.json": {
|
|
@@ -43,11 +40,9 @@
|
|
|
43
40
|
},
|
|
44
41
|
".": {
|
|
45
42
|
"types": "./index.d.ts",
|
|
46
|
-
"
|
|
47
|
-
"
|
|
48
|
-
"
|
|
49
|
-
"node": "./fesm2015/craftsjs-alert.mjs",
|
|
50
|
-
"default": "./fesm2020/craftsjs-alert.mjs"
|
|
43
|
+
"esm2022": "./esm2022/craftsjs-alert.mjs",
|
|
44
|
+
"esm": "./esm2022/craftsjs-alert.mjs",
|
|
45
|
+
"default": "./fesm2022/craftsjs-alert.mjs"
|
|
51
46
|
}
|
|
52
47
|
},
|
|
53
48
|
"sideEffects": false
|
package/public-api.d.ts
CHANGED