monkey-front-core 0.0.389 → 0.0.391
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/esm2020/lib/components/alerts/alerts.component.mjs +11 -3
- package/esm2020/lib/components/alerts/alerts.module.mjs +1 -1
- package/esm2020/lib/core/interfaces/monkeyecx-config.mjs +1 -1
- package/esm2020/lib/core/services/config/monkeyecx-alerts-config.service.mjs +4 -3
- package/fesm2015/monkey-front-core.mjs +14 -5
- package/fesm2015/monkey-front-core.mjs.map +1 -1
- package/fesm2020/monkey-front-core.mjs +13 -4
- package/fesm2020/monkey-front-core.mjs.map +1 -1
- package/lib/components/alerts/alerts.component.d.ts +5 -0
- package/lib/core/interfaces/monkeyecx-config.d.ts +4 -0
- package/monkey-front-core-0.0.391.tgz +0 -0
- package/package.json +1 -1
- package/monkey-front-core-0.0.389.tgz +0 -0
|
@@ -10,6 +10,7 @@ export class AlertsComponent {
|
|
|
10
10
|
this._img = '';
|
|
11
11
|
this._title = '';
|
|
12
12
|
this._message = '';
|
|
13
|
+
this._action = null;
|
|
13
14
|
// not to do
|
|
14
15
|
}
|
|
15
16
|
ngOnInit() {
|
|
@@ -17,19 +18,26 @@ export class AlertsComponent {
|
|
|
17
18
|
this._img = config?.data?.img;
|
|
18
19
|
this._title = config?.data?.title;
|
|
19
20
|
this._message = config?.data?.message;
|
|
21
|
+
this._action = config?.data?.action;
|
|
20
22
|
}
|
|
21
23
|
onClose() {
|
|
22
24
|
this.modalService.close(this.modalRef);
|
|
23
25
|
}
|
|
26
|
+
onAction() {
|
|
27
|
+
const { _action } = this;
|
|
28
|
+
if (_action?.href) {
|
|
29
|
+
window.location.href = _action?.href;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
24
32
|
}
|
|
25
33
|
AlertsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: AlertsComponent, deps: [{ token: i1.MonkeyStyleGuideModalService }], target: i0.ɵɵFactoryTarget.Component });
|
|
26
|
-
AlertsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.1", type: AlertsComponent, selector: "monkeyecx-alerts", inputs: { config: "config", modalRef: "modalRef" }, ngImport: i0, template: "<monkey-modal [config]=\"config\" [modalRef]=\"modalRef\" *ngIf=\"config\">\r\n <div class=\"alert-header\">\r\n <img [src]=\"_img\">\r\n </div>\r\n <div class=\"alert-body\">\r\n <span class=\"title\">\r\n {{ _title | translate }}\r\n </span>\r\n <span class=\"message\">\r\n {{ _message | translate }}\r\n </span>\r\n </div>\r\n <div class=\"alert-footer\">\r\n <monkey-button type=\"tertiary\" color=\"theme\" (click)=\"onClose()\">\r\n {{ 'BUTTONS.CLOSE' | translate }}\r\n </monkey-button>\r\n </div>\r\n</monkey-modal>", styles: [":host ::ng-deep monkey-modal mecx-monkey-modal{padding:0}:host ::ng-deep monkey-modal mecx-monkey-modal .body{margin-bottom:0}:host ::ng-deep monkey-modal .mecx-monkey-modal__size-md{max-width:448px}:host .alert-header{height:100%}@media screen and (max-width: 959px){:host .alert-header{min-height:212px}}:host .alert-header img{border-radius:12px 12px 0 0;-o-object-fit:cover;object-fit:cover;width:100%;max-height:280px}@media screen and (max-width: 959px){:host .alert-header img{height:200px}}:host .alert-body{display:flex;flex-direction:column;gap:16px;padding:24px;margin:auto}:host .alert-body .title{font-style:normal;font-weight:700;font-size:32px;line-height:40px;text-align:center;color:#1f2024}:host .alert-body .message{font-style:normal;font-weight:400;font-size:16px;line-height:24px;text-align:center;letter-spacing:.03em;color:#545a63}:host .alert-footer{display:flex;justify-content:flex-end;padding:0 24px 24px;position:sticky;bottom:0;background:#fafafa}\n"], components: [{ type: i1.MonkeyModalComponent, selector: "monkey-modal", inputs: ["config", "modalRef", "onHandleConfirm"] }, { type: i1.MonkeyButtonComponent, selector: "monkey-button", inputs: ["label", "icon", "iconPosition", "type", "color", "disabled", "size"] }], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], pipes: { "translate": i3.TranslatePipe } });
|
|
34
|
+
AlertsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.1", type: AlertsComponent, selector: "monkeyecx-alerts", inputs: { config: "config", modalRef: "modalRef" }, ngImport: i0, template: "<monkey-modal [config]=\"config\" [modalRef]=\"modalRef\" *ngIf=\"config\">\r\n <div class=\"alert-header\">\r\n <img [src]=\"_img\">\r\n </div>\r\n <div class=\"alert-body\">\r\n <span class=\"title\">\r\n {{ _title | translate }}\r\n </span>\r\n <span class=\"message\">\r\n {{ _message | translate }}\r\n </span>\r\n </div>\r\n <div class=\"alert-footer\">\r\n <monkey-button type=\"tertiary\" color=\"theme\" (click)=\"onClose()\">\r\n {{ 'BUTTONS.CLOSE' | translate }}\r\n </monkey-button>\r\n <ng-container *ngIf=\"_action\">\r\n <monkey-button type=\"primary\" color=\"theme\" (click)=\"onAction()\">\r\n {{ _action.label | translate }}\r\n </monkey-button>\r\n </ng-container>\r\n </div>\r\n</monkey-modal>", styles: [":host ::ng-deep monkey-modal mecx-monkey-modal{padding:0}:host ::ng-deep monkey-modal mecx-monkey-modal .body{margin-bottom:0}:host ::ng-deep monkey-modal .mecx-monkey-modal__size-md{max-width:448px}:host .alert-header{height:100%}@media screen and (max-width: 959px){:host .alert-header{min-height:212px}}:host .alert-header img{border-radius:12px 12px 0 0;-o-object-fit:cover;object-fit:cover;width:100%;max-height:280px}@media screen and (max-width: 959px){:host .alert-header img{height:200px}}:host .alert-body{display:flex;flex-direction:column;gap:16px;padding:24px;margin:auto}:host .alert-body .title{font-style:normal;font-weight:700;font-size:32px;line-height:40px;text-align:center;color:#1f2024}:host .alert-body .message{font-style:normal;font-weight:400;font-size:16px;line-height:24px;text-align:center;letter-spacing:.03em;color:#545a63}:host .alert-footer{display:flex;justify-content:flex-end;padding:0 24px 24px;position:sticky;bottom:0;background:#fafafa}\n"], components: [{ type: i1.MonkeyModalComponent, selector: "monkey-modal", inputs: ["config", "modalRef", "onHandleConfirm"] }, { type: i1.MonkeyButtonComponent, selector: "monkey-button", inputs: ["label", "icon", "iconPosition", "type", "color", "disabled", "size"] }], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], pipes: { "translate": i3.TranslatePipe } });
|
|
27
35
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: AlertsComponent, decorators: [{
|
|
28
36
|
type: Component,
|
|
29
|
-
args: [{ selector: 'monkeyecx-alerts', template: "<monkey-modal [config]=\"config\" [modalRef]=\"modalRef\" *ngIf=\"config\">\r\n <div class=\"alert-header\">\r\n <img [src]=\"_img\">\r\n </div>\r\n <div class=\"alert-body\">\r\n <span class=\"title\">\r\n {{ _title | translate }}\r\n </span>\r\n <span class=\"message\">\r\n {{ _message | translate }}\r\n </span>\r\n </div>\r\n <div class=\"alert-footer\">\r\n <monkey-button type=\"tertiary\" color=\"theme\" (click)=\"onClose()\">\r\n {{ 'BUTTONS.CLOSE' | translate }}\r\n </monkey-button>\r\n </div>\r\n</monkey-modal>", styles: [":host ::ng-deep monkey-modal mecx-monkey-modal{padding:0}:host ::ng-deep monkey-modal mecx-monkey-modal .body{margin-bottom:0}:host ::ng-deep monkey-modal .mecx-monkey-modal__size-md{max-width:448px}:host .alert-header{height:100%}@media screen and (max-width: 959px){:host .alert-header{min-height:212px}}:host .alert-header img{border-radius:12px 12px 0 0;-o-object-fit:cover;object-fit:cover;width:100%;max-height:280px}@media screen and (max-width: 959px){:host .alert-header img{height:200px}}:host .alert-body{display:flex;flex-direction:column;gap:16px;padding:24px;margin:auto}:host .alert-body .title{font-style:normal;font-weight:700;font-size:32px;line-height:40px;text-align:center;color:#1f2024}:host .alert-body .message{font-style:normal;font-weight:400;font-size:16px;line-height:24px;text-align:center;letter-spacing:.03em;color:#545a63}:host .alert-footer{display:flex;justify-content:flex-end;padding:0 24px 24px;position:sticky;bottom:0;background:#fafafa}\n"] }]
|
|
37
|
+
args: [{ selector: 'monkeyecx-alerts', template: "<monkey-modal [config]=\"config\" [modalRef]=\"modalRef\" *ngIf=\"config\">\r\n <div class=\"alert-header\">\r\n <img [src]=\"_img\">\r\n </div>\r\n <div class=\"alert-body\">\r\n <span class=\"title\">\r\n {{ _title | translate }}\r\n </span>\r\n <span class=\"message\">\r\n {{ _message | translate }}\r\n </span>\r\n </div>\r\n <div class=\"alert-footer\">\r\n <monkey-button type=\"tertiary\" color=\"theme\" (click)=\"onClose()\">\r\n {{ 'BUTTONS.CLOSE' | translate }}\r\n </monkey-button>\r\n <ng-container *ngIf=\"_action\">\r\n <monkey-button type=\"primary\" color=\"theme\" (click)=\"onAction()\">\r\n {{ _action.label | translate }}\r\n </monkey-button>\r\n </ng-container>\r\n </div>\r\n</monkey-modal>", styles: [":host ::ng-deep monkey-modal mecx-monkey-modal{padding:0}:host ::ng-deep monkey-modal mecx-monkey-modal .body{margin-bottom:0}:host ::ng-deep monkey-modal .mecx-monkey-modal__size-md{max-width:448px}:host .alert-header{height:100%}@media screen and (max-width: 959px){:host .alert-header{min-height:212px}}:host .alert-header img{border-radius:12px 12px 0 0;-o-object-fit:cover;object-fit:cover;width:100%;max-height:280px}@media screen and (max-width: 959px){:host .alert-header img{height:200px}}:host .alert-body{display:flex;flex-direction:column;gap:16px;padding:24px;margin:auto}:host .alert-body .title{font-style:normal;font-weight:700;font-size:32px;line-height:40px;text-align:center;color:#1f2024}:host .alert-body .message{font-style:normal;font-weight:400;font-size:16px;line-height:24px;text-align:center;letter-spacing:.03em;color:#545a63}:host .alert-footer{display:flex;justify-content:flex-end;padding:0 24px 24px;position:sticky;bottom:0;background:#fafafa}\n"] }]
|
|
30
38
|
}], ctorParameters: function () { return [{ type: i1.MonkeyStyleGuideModalService }]; }, propDecorators: { config: [{
|
|
31
39
|
type: Input
|
|
32
40
|
}], modalRef: [{
|
|
33
41
|
type: Input
|
|
34
42
|
}] } });
|
|
35
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
43
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWxlcnRzLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL21vbmtleS1mcm9udC1jb3JlL3NyYy9saWIvY29tcG9uZW50cy9hbGVydHMvYWxlcnRzLmNvbXBvbmVudC50cyIsIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL21vbmtleS1mcm9udC1jb3JlL3NyYy9saWIvY29tcG9uZW50cy9hbGVydHMvYWxlcnRzLmNvbXBvbmVudC5odG1sIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxTQUFTLEVBQUUsS0FBSyxFQUFVLE1BQU0sZUFBZSxDQUFDOzs7OztBQVF6RCxNQUFNLE9BQU8sZUFBZTtJQWdCMUIsWUFDVSxZQUEwQztRQUExQyxpQkFBWSxHQUFaLFlBQVksQ0FBOEI7UUFoQjNDLFdBQU0sR0FBNkIsSUFBSSxDQUFDO1FBSWpELFNBQUksR0FBRyxFQUFFLENBQUM7UUFFVixXQUFNLEdBQUcsRUFBRSxDQUFDO1FBRVosYUFBUSxHQUFHLEVBQUUsQ0FBQztRQUVkLFlBQU8sR0FHSSxJQUFJLENBQUM7UUFLZCxZQUFZO0lBQ2QsQ0FBQztJQUVELFFBQVE7UUFDTixNQUFNLEVBQUUsTUFBTSxFQUFFLEdBQUcsSUFBSSxDQUFDO1FBQ3hCLElBQUksQ0FBQyxJQUFJLEdBQUcsTUFBTSxFQUFFLElBQUksRUFBRSxHQUFHLENBQUM7UUFDOUIsSUFBSSxDQUFDLE1BQU0sR0FBRyxNQUFNLEVBQUUsSUFBSSxFQUFFLEtBQUssQ0FBQztRQUNsQyxJQUFJLENBQUMsUUFBUSxHQUFHLE1BQU0sRUFB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wiYWxlcnQtaGVhZGVyXCI+XHJcbiAgICA8aW1nIFtzcmNdPVwiX2ltZ1wiPlxyXG4gIDwvZGl2PlxyXG4gIDxkaXYgY2xhc3M9XCJhbGVydC1ib2R5XCI+XHJcbiAgICA8c3BhbiBjbGFzcz1cInRpdGxlXCI+XHJcbiAgICAgIHt7IF90aXRsZSB8IHRyYW5zbGF0ZSB9fVxyXG4gICAgPC9zcGFuPlxyXG4gICAgPHNwYW4gY2xhc3M9XCJtZXNzYWdlXCI+XHJcbiAgICAgIHt7IF9tZXNzYWdlIHwgdHJhbnNsYXRlIH19XHJcbiAgICA8L3NwYW4+XHJcbiAgPC9kaXY+XHJcbiAgPGRpdiBjbGFzcz1cImFsZXJ0LWZvb3RlclwiPlxyXG4gICAgPG1vbmtleS1idXR0b24gdHlwZT1cInRlcnRpYXJ5XCIgY29sb3I9XCJ0aGVtZVwiIChjbGljayk9XCJvbkNsb3NlKClcIj5cclxuICAgICAge3sgJ0JVVFRPTlMuQ0xPU0UnIHwgdHJhbnNsYXRlIH19XHJcbiAgICA8L21vbmtleS1idXR0b24+XHJcbiAgICA8bmctY29udGFpbmVyICpuZ0lmPVwiX2FjdGlvblwiPlxyXG4gICAgICA8bW9ua2V5LWJ1dHRvbiB0eXBlPVwicHJpbWFyeVwiIGNvbG9yPVwidGhlbWVcIiAoY2xpY2spPVwib25BY3Rpb24oKVwiPlxyXG4gICAgICAgIHt7IF9hY3Rpb24ubGFiZWwgfCB0cmFuc2xhdGUgfX1cclxuICAgICAgPC9tb25rZXktYnV0dG9uPlxyXG4gICAgPC9uZy1jb250YWluZXI+XHJcbiAgPC9kaXY+XHJcbjwvbW9ua2V5LW1vZGFsPiJdfQ==
|
|
@@ -18,4 +18,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
|
|
|
18
18
|
exports: [AlertsComponent]
|
|
19
19
|
}]
|
|
20
20
|
}] });
|
|
21
|
-
//# sourceMappingURL=data:application/json;base64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mtleUVjeENvbmZpZ2kxOG47XG4gIGxvZ3M/OiBNb25rZXlFY3hDb25maWdMb2dzO1xuICBleHRlcm5hbGkxOG4/OiBNb25rZXlFY3hDb25maWdFeHRlcm5hbGkxOG47XG4gIG1lc3NhZ2VzPzogTW9ua2V5RWN4Q29uZmlnTWVzc2FnZXM7XG4gIGV4dGVybmFsU2V0dGluZ3M/OiBNb25rZXlFY3hDb25maWdFeHRlcm5hbFNldHRpbmdzO1xuICBndG0/OiBNb25rZXlFY3hDb25maWdHVE07XG4gIGFsZXJ0PzogTW9ua2V5RWN4Q29uZmlnQWxlcnQ7XG59XG4iXX0=
|
|
@@ -11,7 +11,7 @@ export class MonkeyEcxAlertsConfigService {
|
|
|
11
11
|
}
|
|
12
12
|
handleValidation(config) {
|
|
13
13
|
if (config.alert) {
|
|
14
|
-
const { img, title, message, endDate, noEndDate } = config.alert;
|
|
14
|
+
const { img, title, message, endDate, noEndDate, action } = config.alert;
|
|
15
15
|
if (moment.default().isSameOrBefore(moment.default(endDate)) || noEndDate) {
|
|
16
16
|
this.modalService.open(AlertsComponent, {
|
|
17
17
|
color: 'theme',
|
|
@@ -19,7 +19,8 @@ export class MonkeyEcxAlertsConfigService {
|
|
|
19
19
|
data: {
|
|
20
20
|
img,
|
|
21
21
|
title,
|
|
22
|
-
message
|
|
22
|
+
message,
|
|
23
|
+
action
|
|
23
24
|
}
|
|
24
25
|
});
|
|
25
26
|
}
|
|
@@ -37,4 +38,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
|
|
|
37
38
|
providedIn: 'root'
|
|
38
39
|
}]
|
|
39
40
|
}], ctorParameters: function () { return [{ type: i1.MonkeyStyleGuideModalFixedService }]; } });
|
|
40
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
41
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibW9ua2V5ZWN4LWFsZXJ0cy1jb25maWcuc2VydmljZS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lvbihjb25maWc6IE1vbmtleUVjeENvbmZpZykge1xuICAgIGlmIChjb25maWcuYWxlcnQpIHtcbiAgICAgIGNvbnN0IHsgaW1nLCB0aXRsZSwgbWVzc2FnZSwgZW5kRGF0ZSwgbm9FbmREYXRlLCBhY3Rpb24gfSA9IGNvbmZpZy5hbGVydDtcbiAgICAgIGlmIChtb21lbnQuZGVmYXVsdCgpLmlzU2FtZU9yQmVmb3JlKG1vbWVudC5kZWZhdWx0KGVuZERhdGUpKSB8fCBub0VuZERhdGUpIHtcbiAgICAgICAgdGhpcy5tb2RhbFNlcnZpY2Uub3BlbihBbGVydHNDb21wb25lbnQsIHtcbiAgICAgICAgICBjb2xvcjogJ3RoZW1lJyxcbiAgICAgICAgICBzaXplOiAnbWQnLFxuICAgICAgICAgIGRhdGE6IHtcbiAgICAgICAgICAgIGltZyxcbiAgICAgICAgICAgIHRpdGxlLFxuICAgICAgICAgICAgbWVzc2FnZSxcbiAgICAgICAgICAgIGFjdGlvblxuICAgICAgICAgIH1cbiAgICAgICAgfSk7XG4gICAgICB9XG4gICAgfVxuICB9XG5cbiAgcHVibGljIGFwcGx5KGNvbmZpZzogTW9ua2V5RWN4Q29uZmlnKSB7XG4gICAgdGhpcy5oYW5kbGVWYWxpZGF0aW9uKGNvbmZpZyk7XG4gIH1cbn1cbiJdfQ==
|
|
@@ -35,24 +35,32 @@ class AlertsComponent {
|
|
|
35
35
|
this._img = '';
|
|
36
36
|
this._title = '';
|
|
37
37
|
this._message = '';
|
|
38
|
+
this._action = null;
|
|
38
39
|
// not to do
|
|
39
40
|
}
|
|
40
41
|
ngOnInit() {
|
|
41
|
-
var _a, _b, _c;
|
|
42
|
+
var _a, _b, _c, _d;
|
|
42
43
|
const { config } = this;
|
|
43
44
|
this._img = (_a = config === null || config === void 0 ? void 0 : config.data) === null || _a === void 0 ? void 0 : _a.img;
|
|
44
45
|
this._title = (_b = config === null || config === void 0 ? void 0 : config.data) === null || _b === void 0 ? void 0 : _b.title;
|
|
45
46
|
this._message = (_c = config === null || config === void 0 ? void 0 : config.data) === null || _c === void 0 ? void 0 : _c.message;
|
|
47
|
+
this._action = (_d = config === null || config === void 0 ? void 0 : config.data) === null || _d === void 0 ? void 0 : _d.action;
|
|
46
48
|
}
|
|
47
49
|
onClose() {
|
|
48
50
|
this.modalService.close(this.modalRef);
|
|
49
51
|
}
|
|
52
|
+
onAction() {
|
|
53
|
+
const { _action } = this;
|
|
54
|
+
if (_action === null || _action === void 0 ? void 0 : _action.href) {
|
|
55
|
+
window.location.href = _action === null || _action === void 0 ? void 0 : _action.href;
|
|
56
|
+
}
|
|
57
|
+
}
|
|
50
58
|
}
|
|
51
59
|
AlertsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: AlertsComponent, deps: [{ token: i1.MonkeyStyleGuideModalService }], target: i0.ɵɵFactoryTarget.Component });
|
|
52
|
-
AlertsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.1", type: AlertsComponent, selector: "monkeyecx-alerts", inputs: { config: "config", modalRef: "modalRef" }, ngImport: i0, template: "<monkey-modal [config]=\"config\" [modalRef]=\"modalRef\" *ngIf=\"config\">\r\n <div class=\"alert-header\">\r\n <img [src]=\"_img\">\r\n </div>\r\n <div class=\"alert-body\">\r\n <span class=\"title\">\r\n {{ _title | translate }}\r\n </span>\r\n <span class=\"message\">\r\n {{ _message | translate }}\r\n </span>\r\n </div>\r\n <div class=\"alert-footer\">\r\n <monkey-button type=\"tertiary\" color=\"theme\" (click)=\"onClose()\">\r\n {{ 'BUTTONS.CLOSE' | translate }}\r\n </monkey-button>\r\n </div>\r\n</monkey-modal>", styles: [":host ::ng-deep monkey-modal mecx-monkey-modal{padding:0}:host ::ng-deep monkey-modal mecx-monkey-modal .body{margin-bottom:0}:host ::ng-deep monkey-modal .mecx-monkey-modal__size-md{max-width:448px}:host .alert-header{height:100%}@media screen and (max-width: 959px){:host .alert-header{min-height:212px}}:host .alert-header img{border-radius:12px 12px 0 0;-o-object-fit:cover;object-fit:cover;width:100%;max-height:280px}@media screen and (max-width: 959px){:host .alert-header img{height:200px}}:host .alert-body{display:flex;flex-direction:column;gap:16px;padding:24px;margin:auto}:host .alert-body .title{font-style:normal;font-weight:700;font-size:32px;line-height:40px;text-align:center;color:#1f2024}:host .alert-body .message{font-style:normal;font-weight:400;font-size:16px;line-height:24px;text-align:center;letter-spacing:.03em;color:#545a63}:host .alert-footer{display:flex;justify-content:flex-end;padding:0 24px 24px;position:sticky;bottom:0;background:#fafafa}\n"], components: [{ type: i1.MonkeyModalComponent, selector: "monkey-modal", inputs: ["config", "modalRef", "onHandleConfirm"] }, { type: i1.MonkeyButtonComponent, selector: "monkey-button", inputs: ["label", "icon", "iconPosition", "type", "color", "disabled", "size"] }], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], pipes: { "translate": i1$1.TranslatePipe } });
|
|
60
|
+
AlertsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.1", type: AlertsComponent, selector: "monkeyecx-alerts", inputs: { config: "config", modalRef: "modalRef" }, ngImport: i0, template: "<monkey-modal [config]=\"config\" [modalRef]=\"modalRef\" *ngIf=\"config\">\r\n <div class=\"alert-header\">\r\n <img [src]=\"_img\">\r\n </div>\r\n <div class=\"alert-body\">\r\n <span class=\"title\">\r\n {{ _title | translate }}\r\n </span>\r\n <span class=\"message\">\r\n {{ _message | translate }}\r\n </span>\r\n </div>\r\n <div class=\"alert-footer\">\r\n <monkey-button type=\"tertiary\" color=\"theme\" (click)=\"onClose()\">\r\n {{ 'BUTTONS.CLOSE' | translate }}\r\n </monkey-button>\r\n <ng-container *ngIf=\"_action\">\r\n <monkey-button type=\"primary\" color=\"theme\" (click)=\"onAction()\">\r\n {{ _action.label | translate }}\r\n </monkey-button>\r\n </ng-container>\r\n </div>\r\n</monkey-modal>", styles: [":host ::ng-deep monkey-modal mecx-monkey-modal{padding:0}:host ::ng-deep monkey-modal mecx-monkey-modal .body{margin-bottom:0}:host ::ng-deep monkey-modal .mecx-monkey-modal__size-md{max-width:448px}:host .alert-header{height:100%}@media screen and (max-width: 959px){:host .alert-header{min-height:212px}}:host .alert-header img{border-radius:12px 12px 0 0;-o-object-fit:cover;object-fit:cover;width:100%;max-height:280px}@media screen and (max-width: 959px){:host .alert-header img{height:200px}}:host .alert-body{display:flex;flex-direction:column;gap:16px;padding:24px;margin:auto}:host .alert-body .title{font-style:normal;font-weight:700;font-size:32px;line-height:40px;text-align:center;color:#1f2024}:host .alert-body .message{font-style:normal;font-weight:400;font-size:16px;line-height:24px;text-align:center;letter-spacing:.03em;color:#545a63}:host .alert-footer{display:flex;justify-content:flex-end;padding:0 24px 24px;position:sticky;bottom:0;background:#fafafa}\n"], components: [{ type: i1.MonkeyModalComponent, selector: "monkey-modal", inputs: ["config", "modalRef", "onHandleConfirm"] }, { type: i1.MonkeyButtonComponent, selector: "monkey-button", inputs: ["label", "icon", "iconPosition", "type", "color", "disabled", "size"] }], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], pipes: { "translate": i1$1.TranslatePipe } });
|
|
53
61
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: AlertsComponent, decorators: [{
|
|
54
62
|
type: Component,
|
|
55
|
-
args: [{ selector: 'monkeyecx-alerts', template: "<monkey-modal [config]=\"config\" [modalRef]=\"modalRef\" *ngIf=\"config\">\r\n <div class=\"alert-header\">\r\n <img [src]=\"_img\">\r\n </div>\r\n <div class=\"alert-body\">\r\n <span class=\"title\">\r\n {{ _title | translate }}\r\n </span>\r\n <span class=\"message\">\r\n {{ _message | translate }}\r\n </span>\r\n </div>\r\n <div class=\"alert-footer\">\r\n <monkey-button type=\"tertiary\" color=\"theme\" (click)=\"onClose()\">\r\n {{ 'BUTTONS.CLOSE' | translate }}\r\n </monkey-button>\r\n </div>\r\n</monkey-modal>", styles: [":host ::ng-deep monkey-modal mecx-monkey-modal{padding:0}:host ::ng-deep monkey-modal mecx-monkey-modal .body{margin-bottom:0}:host ::ng-deep monkey-modal .mecx-monkey-modal__size-md{max-width:448px}:host .alert-header{height:100%}@media screen and (max-width: 959px){:host .alert-header{min-height:212px}}:host .alert-header img{border-radius:12px 12px 0 0;-o-object-fit:cover;object-fit:cover;width:100%;max-height:280px}@media screen and (max-width: 959px){:host .alert-header img{height:200px}}:host .alert-body{display:flex;flex-direction:column;gap:16px;padding:24px;margin:auto}:host .alert-body .title{font-style:normal;font-weight:700;font-size:32px;line-height:40px;text-align:center;color:#1f2024}:host .alert-body .message{font-style:normal;font-weight:400;font-size:16px;line-height:24px;text-align:center;letter-spacing:.03em;color:#545a63}:host .alert-footer{display:flex;justify-content:flex-end;padding:0 24px 24px;position:sticky;bottom:0;background:#fafafa}\n"] }]
|
|
63
|
+
args: [{ selector: 'monkeyecx-alerts', template: "<monkey-modal [config]=\"config\" [modalRef]=\"modalRef\" *ngIf=\"config\">\r\n <div class=\"alert-header\">\r\n <img [src]=\"_img\">\r\n </div>\r\n <div class=\"alert-body\">\r\n <span class=\"title\">\r\n {{ _title | translate }}\r\n </span>\r\n <span class=\"message\">\r\n {{ _message | translate }}\r\n </span>\r\n </div>\r\n <div class=\"alert-footer\">\r\n <monkey-button type=\"tertiary\" color=\"theme\" (click)=\"onClose()\">\r\n {{ 'BUTTONS.CLOSE' | translate }}\r\n </monkey-button>\r\n <ng-container *ngIf=\"_action\">\r\n <monkey-button type=\"primary\" color=\"theme\" (click)=\"onAction()\">\r\n {{ _action.label | translate }}\r\n </monkey-button>\r\n </ng-container>\r\n </div>\r\n</monkey-modal>", styles: [":host ::ng-deep monkey-modal mecx-monkey-modal{padding:0}:host ::ng-deep monkey-modal mecx-monkey-modal .body{margin-bottom:0}:host ::ng-deep monkey-modal .mecx-monkey-modal__size-md{max-width:448px}:host .alert-header{height:100%}@media screen and (max-width: 959px){:host .alert-header{min-height:212px}}:host .alert-header img{border-radius:12px 12px 0 0;-o-object-fit:cover;object-fit:cover;width:100%;max-height:280px}@media screen and (max-width: 959px){:host .alert-header img{height:200px}}:host .alert-body{display:flex;flex-direction:column;gap:16px;padding:24px;margin:auto}:host .alert-body .title{font-style:normal;font-weight:700;font-size:32px;line-height:40px;text-align:center;color:#1f2024}:host .alert-body .message{font-style:normal;font-weight:400;font-size:16px;line-height:24px;text-align:center;letter-spacing:.03em;color:#545a63}:host .alert-footer{display:flex;justify-content:flex-end;padding:0 24px 24px;position:sticky;bottom:0;background:#fafafa}\n"] }]
|
|
56
64
|
}], ctorParameters: function () { return [{ type: i1.MonkeyStyleGuideModalService }]; }, propDecorators: { config: [{
|
|
57
65
|
type: Input
|
|
58
66
|
}], modalRef: [{
|
|
@@ -3476,7 +3484,7 @@ class MonkeyEcxAlertsConfigService {
|
|
|
3476
3484
|
}
|
|
3477
3485
|
handleValidation(config) {
|
|
3478
3486
|
if (config.alert) {
|
|
3479
|
-
const { img, title, message, endDate, noEndDate } = config.alert;
|
|
3487
|
+
const { img, title, message, endDate, noEndDate, action } = config.alert;
|
|
3480
3488
|
if (moment.default().isSameOrBefore(moment.default(endDate)) || noEndDate) {
|
|
3481
3489
|
this.modalService.open(AlertsComponent, {
|
|
3482
3490
|
color: 'theme',
|
|
@@ -3484,7 +3492,8 @@ class MonkeyEcxAlertsConfigService {
|
|
|
3484
3492
|
data: {
|
|
3485
3493
|
img,
|
|
3486
3494
|
title,
|
|
3487
|
-
message
|
|
3495
|
+
message,
|
|
3496
|
+
action
|
|
3488
3497
|
}
|
|
3489
3498
|
});
|
|
3490
3499
|
}
|