@softpak/components 19.3.1 → 19.5.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +24 -24
- package/fesm2022/softpak-components-spx-alert.mjs +25 -159
- package/fesm2022/softpak-components-spx-alert.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-app-configuration.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-app-expiry.mjs +56 -56
- package/fesm2022/softpak-components-spx-app-expiry.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-button.mjs +28 -111
- package/fesm2022/softpak-components-spx-button.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-capitalize.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-card.mjs +80 -293
- package/fesm2022/softpak-components-spx-card.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-change-details.mjs +5 -5
- package/fesm2022/softpak-components-spx-change-details.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-channel-selection.mjs +52 -52
- package/fesm2022/softpak-components-spx-channel-selection.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-check-digit.mjs +3 -3
- package/fesm2022/softpak-components-spx-check-digit.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-form-section.mjs +22 -22
- package/fesm2022/softpak-components-spx-form-section.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-form-view.mjs +23 -202
- package/fesm2022/softpak-components-spx-form-view.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-helpers.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-inputs.mjs +421 -1290
- package/fesm2022/softpak-components-spx-inputs.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-navigation.mjs +44 -44
- package/fesm2022/softpak-components-spx-navigation.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-number-check.mjs +77 -79
- package/fesm2022/softpak-components-spx-number-check.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-pagination.mjs +2 -2
- package/fesm2022/softpak-components-spx-pagination.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-patch.mjs +25 -25
- package/fesm2022/softpak-components-spx-patch.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-pipes.mjs +28 -0
- package/fesm2022/softpak-components-spx-pipes.mjs.map +1 -0
- package/fesm2022/softpak-components-spx-progress-bar.mjs +14 -14
- package/fesm2022/softpak-components-spx-progress-bar.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-spinner.mjs +142 -142
- package/fesm2022/softpak-components-spx-spinner.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-stock-info.mjs +2 -2
- package/fesm2022/softpak-components-spx-stock-info.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-storage.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-suggestion.mjs +3 -47
- package/fesm2022/softpak-components-spx-suggestion.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-toaster.mjs +93 -93
- package/fesm2022/softpak-components-spx-toaster.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-translate.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-update.mjs +4 -7
- package/fesm2022/softpak-components-spx-update.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-validation.mjs +2 -2
- package/fesm2022/softpak-components-spx-validation.mjs.map +1 -1
- package/package.json +29 -25
- package/spx-alert/spx-alert.component.d.ts +9 -14
- package/spx-button/spx-button.component.d.ts +15 -18
- package/spx-card/public-api.d.ts +3 -3
- package/spx-card/{spx-card-grid.component.d.ts → spx-card-grid/spx-card-grid.component.d.ts} +2 -2
- package/spx-card/spx-card-item/spx-card-item.component.d.ts +15 -0
- package/spx-card/spx-card-line/spx-card-line.component.d.ts +16 -0
- package/spx-change-details/spx-change-details.component.d.ts +2 -2
- package/spx-form-view/spx-autocomplete-search.component.d.ts +3 -4
- package/spx-form-view/spx-form-field.interface.d.ts +1 -1
- package/spx-form-view/spx-form-view.component.d.ts +10 -10
- package/spx-inputs/input.service.d.ts +11 -0
- package/spx-inputs/public-api.d.ts +2 -2
- package/spx-inputs/{spx-dropdown.component.d.ts → spx-dropdown/spx-dropdown.component.d.ts} +7 -7
- package/spx-inputs/spx-input-box/spx-input-box.component.d.ts +38 -0
- package/spx-inputs/spx-input-date/spx-input-date.component.d.ts +8 -4
- package/spx-inputs/spx-input-float/spx-input-float.component.d.ts +30 -0
- package/spx-inputs/spx-input-number/spx-input-number.component.d.ts +23 -0
- package/spx-inputs/spx-input-radio/spx-input-radio.component.d.ts +27 -0
- package/spx-inputs/spx-input-text/spx-input-text.component.d.ts +33 -0
- package/spx-inputs/spx-input-time/spx-input-time.component.d.ts +35 -0
- package/spx-inputs/{spx-input-time-modal.component.d.ts → spx-input-time-modal/spx-input-time-modal.component.d.ts} +6 -7
- package/spx-inputs/spx-input-type.enum.d.ts +2 -1
- package/spx-inputs/spx-input.component.d.ts +44 -49
- package/spx-navigation/spx-navigation-item.interface.d.ts +3 -2
- package/spx-number-check/spx-number-check.component.d.ts +1 -3
- package/spx-pipes/index.d.ts +5 -0
- package/spx-pipes/public-api.d.ts +1 -0
- package/spx-pipes/spx-severity-pipe.d.ts +8 -0
- package/tailwind.css +1 -1
- package/spx-card/spx-card-item.component.d.ts +0 -24
- package/spx-card/spx-card-line.component.d.ts +0 -17
- package/spx-inputs/spx-input-box.component.d.ts +0 -40
- package/spx-inputs/spx-input-float.component.d.ts +0 -30
- package/spx-inputs/spx-input-number.component.d.ts +0 -23
- package/spx-inputs/spx-input-radio.component.d.ts +0 -27
- package/spx-inputs/spx-input-text.component.d.ts +0 -31
- package/spx-inputs/spx-input-time.component.d.ts +0 -45
package/README.md
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
# NgComponents
|
|
2
|
-
|
|
3
|
-
This library was generated with [Angular CLI](https://github.com/angular/angular-cli) version 17.1.0.
|
|
4
|
-
|
|
5
|
-
## Code scaffolding
|
|
6
|
-
|
|
7
|
-
Run `ng generate component component-name --project components` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module --project components`.
|
|
8
|
-
> Note: Don't forget to add `--project components` or else it will be added to the default project in your `angular.json` file.
|
|
9
|
-
|
|
10
|
-
## Build
|
|
11
|
-
|
|
12
|
-
Run `ng build components` to build the project. The build artifacts will be stored in the `dist/` directory.
|
|
13
|
-
|
|
14
|
-
## Publishing
|
|
15
|
-
|
|
16
|
-
After building your library with `ng build components`, go to the dist folder `cd dist/components` and run `npm publish`.
|
|
17
|
-
|
|
18
|
-
## Running unit tests
|
|
19
|
-
|
|
20
|
-
Run `ng test components` to execute the unit tests via [Karma](https://karma-runner.github.io).
|
|
21
|
-
|
|
22
|
-
## Further help
|
|
23
|
-
|
|
24
|
-
To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI Overview and Command Reference](https://angular.io/cli) page.
|
|
1
|
+
# NgComponents
|
|
2
|
+
|
|
3
|
+
This library was generated with [Angular CLI](https://github.com/angular/angular-cli) version 17.1.0.
|
|
4
|
+
|
|
5
|
+
## Code scaffolding
|
|
6
|
+
|
|
7
|
+
Run `ng generate component component-name --project components` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module --project components`.
|
|
8
|
+
> Note: Don't forget to add `--project components` or else it will be added to the default project in your `angular.json` file.
|
|
9
|
+
|
|
10
|
+
## Build
|
|
11
|
+
|
|
12
|
+
Run `ng build components` to build the project. The build artifacts will be stored in the `dist/` directory.
|
|
13
|
+
|
|
14
|
+
## Publishing
|
|
15
|
+
|
|
16
|
+
After building your library with `ng build components`, go to the dist folder `cd dist/components` and run `npm publish`.
|
|
17
|
+
|
|
18
|
+
## Running unit tests
|
|
19
|
+
|
|
20
|
+
Run `ng test components` to execute the unit tests via [Karma](https://karma-runner.github.io).
|
|
21
|
+
|
|
22
|
+
## Further help
|
|
23
|
+
|
|
24
|
+
To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI Overview and Command Reference](https://angular.io/cli) page.
|
|
@@ -1,31 +1,31 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import {
|
|
2
|
+
import { output, input, model, Component } from '@angular/core';
|
|
3
3
|
import * as i1 from '@fortawesome/angular-fontawesome';
|
|
4
4
|
import { FontAwesomeModule } from '@fortawesome/angular-fontawesome';
|
|
5
5
|
import { faCheck, faCircleInfo, faTriangleExclamation, faTimes } from '@fortawesome/free-solid-svg-icons';
|
|
6
6
|
import { SpxSeverityEnum } from '@softpak/components/spx-helpers';
|
|
7
|
+
import { IsSeverityPipe } from '@softpak/components/spx-pipes';
|
|
7
8
|
|
|
8
9
|
class SpxAlertComponent {
|
|
9
10
|
constructor() {
|
|
10
|
-
this.spxClose =
|
|
11
|
-
this.
|
|
12
|
-
this.
|
|
13
|
-
this.
|
|
14
|
-
this.
|
|
11
|
+
this.spxClose = output();
|
|
12
|
+
this.spxAutoclose = input();
|
|
13
|
+
this.spxCloseable = input(false);
|
|
14
|
+
this.spxHideTitle = input(false);
|
|
15
|
+
this.spxTitle = model();
|
|
16
|
+
this.spxMarginTop = input(false);
|
|
17
|
+
this.spxSeverity = input();
|
|
18
|
+
this.SpxSeverity = SpxSeverityEnum;
|
|
15
19
|
this.faCheck = faCheck;
|
|
16
20
|
this.faCircleInfo = faCircleInfo;
|
|
17
21
|
this.faTriangleExclamation = faTriangleExclamation;
|
|
18
22
|
this.faTimes = faTimes;
|
|
19
23
|
}
|
|
20
|
-
get isSeverityError() { return this.spxSeverity === SpxSeverityEnum.error; }
|
|
21
|
-
get isSeverityInfo() { return this.spxSeverity === SpxSeverityEnum.info; }
|
|
22
|
-
get isSeveritySuccess() { return this.spxSeverity === SpxSeverityEnum.success; }
|
|
23
|
-
get isSeverityWarning() { return this.spxSeverity === SpxSeverityEnum.warning; }
|
|
24
24
|
componentDidLoad() {
|
|
25
|
-
if (this.spxAutoclose) {
|
|
25
|
+
if (this.spxAutoclose()) {
|
|
26
26
|
this.prepareAutoClose();
|
|
27
27
|
}
|
|
28
|
-
if (!this.spxTitle) {
|
|
28
|
+
if (!this.spxTitle()) {
|
|
29
29
|
this._assignDefaultTitle();
|
|
30
30
|
}
|
|
31
31
|
}
|
|
@@ -33,173 +33,39 @@ class SpxAlertComponent {
|
|
|
33
33
|
this._autoCloseTimeout = setTimeout(() => {
|
|
34
34
|
this.onClose();
|
|
35
35
|
this._autoCloseTimeout = null;
|
|
36
|
-
|
|
37
|
-
}, this.spxAutoclose);
|
|
36
|
+
}, this.spxAutoclose());
|
|
38
37
|
}
|
|
39
38
|
_assignDefaultTitle() {
|
|
40
|
-
switch (this.spxSeverity) {
|
|
39
|
+
switch (this.spxSeverity()) {
|
|
41
40
|
case SpxSeverityEnum.error:
|
|
42
|
-
this.spxTitle
|
|
41
|
+
this.spxTitle.set('Error');
|
|
43
42
|
break;
|
|
44
43
|
case SpxSeverityEnum.info:
|
|
45
|
-
this.spxTitle
|
|
44
|
+
this.spxTitle.set('Info');
|
|
46
45
|
break;
|
|
47
46
|
case SpxSeverityEnum.success:
|
|
48
|
-
this.spxTitle
|
|
47
|
+
this.spxTitle.set('Notification');
|
|
49
48
|
break;
|
|
50
49
|
case SpxSeverityEnum.warning:
|
|
51
|
-
this.spxTitle
|
|
50
|
+
this.spxTitle.set('Warning');
|
|
52
51
|
break;
|
|
53
52
|
}
|
|
54
53
|
}
|
|
55
54
|
onClose() {
|
|
56
|
-
if (this.spxCloseable) {
|
|
55
|
+
if (this.spxCloseable()) {
|
|
57
56
|
this.spxClose.emit();
|
|
58
57
|
}
|
|
59
58
|
}
|
|
60
59
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.5", ngImport: i0, type: SpxAlertComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
61
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.0.5", type: SpxAlertComponent, isStandalone: true, selector: "spx-alert", inputs: { spxAutoclose: "spxAutoclose", spxCloseable: "spxCloseable", spxHideTitle: "spxHideTitle", spxTitle: "spxTitle", spxMarginTop: "spxMarginTop", spxSeverity: "spxSeverity",
|
|
62
|
-
<div class="flex items-center gap-3 border-t-4 rounded px-4 py-3 shadow-md"
|
|
63
|
-
[class.cursor-pointer]="this.spxCloseable"
|
|
64
|
-
[class.bg-red-100]="this.isSeverityError"
|
|
65
|
-
[class.border-red-500]="this.isSeverityError"
|
|
66
|
-
[class.text-red-900]="this.isSeverityError"
|
|
67
|
-
[class.bg-cyan-100]="this.isSeverityInfo"
|
|
68
|
-
[class.border-cyan-500]="this.isSeverityInfo"
|
|
69
|
-
[class.text-cyan-900]="this.isSeverityInfo"
|
|
70
|
-
[class.bg-lime-100]="this.isSeveritySuccess"
|
|
71
|
-
[class.border-lime-500]="this.isSeveritySuccess"
|
|
72
|
-
[class.text-lime-900]="this.isSeveritySuccess"
|
|
73
|
-
[class.bg-amber-100]="this.isSeverityWarning"
|
|
74
|
-
[class.border-amber-500]="this.isSeverityWarning"
|
|
75
|
-
[class.text-amber-900]="this.isSeverityWarning"
|
|
76
|
-
[class.focus:ring-red-600]="this.spxCloseable && this.isSeverityError"
|
|
77
|
-
[class.hover:bg-red-200]="this.spxCloseable && this.isSeverityError"
|
|
78
|
-
[class.over:border-red-600]="this.spxCloseable && this.isSeverityError"
|
|
79
|
-
[class.focus:ring-cyan-600]="this.spxCloseable && this.isSeverityInfo"
|
|
80
|
-
[class.hover:bg-cyan-200]="this.spxCloseable && this.isSeverityInfo"
|
|
81
|
-
[class.over:border-cyan-600]="this.spxCloseable && this.isSeverityInfo"
|
|
82
|
-
[class.focus:ring-lime-600]="this.spxCloseable && this.isSeveritySuccess"
|
|
83
|
-
[class.hover:bg-lime-200]="this.spxCloseable && this.isSeveritySuccess"
|
|
84
|
-
[class.over:border-lime-600]="this.spxCloseable && this.isSeveritySuccess"
|
|
85
|
-
[class.focus:ring-amber-600]="this.spxCloseable && this.isSeverityWarning"
|
|
86
|
-
[class.hover:bg-amber-200]="this.spxCloseable && this.isSeverityWarning"
|
|
87
|
-
[class.over:border-amber-600]="this.spxCloseable && this.isSeverityWarning"
|
|
88
|
-
(click)="onClose()">
|
|
89
|
-
@if (this.isSeverityInfo) {
|
|
90
|
-
<fa-icon
|
|
91
|
-
[icon]="faCircleInfo" class="block text-xl text-cyan-600"></fa-icon>
|
|
92
|
-
}
|
|
93
|
-
@if (this.isSeverityError) {
|
|
94
|
-
<fa-icon
|
|
95
|
-
[icon]="faTriangleExclamation" class="block text-xl text-red-600"></fa-icon>
|
|
96
|
-
}
|
|
97
|
-
@if (this.isSeveritySuccess) {
|
|
98
|
-
<fa-icon
|
|
99
|
-
[icon]="faCheck" class="block text-xl text-lime-600"></fa-icon>
|
|
100
|
-
}
|
|
101
|
-
@if (this.isSeverityWarning) {
|
|
102
|
-
<fa-icon
|
|
103
|
-
[icon]="faTriangleExclamation" class="block text-xl text-amber-600"></fa-icon>
|
|
104
|
-
}
|
|
105
|
-
<div class="grow">
|
|
106
|
-
@if (this.spxTitle && !this.spxHideTitle) {
|
|
107
|
-
<p class="font-bold">{{this.spxTitle}}</p>
|
|
108
|
-
}
|
|
109
|
-
<p class="text-sm">
|
|
110
|
-
<ng-content></ng-content>
|
|
111
|
-
</p>
|
|
112
|
-
</div>
|
|
113
|
-
@if (this.spxCloseable) {
|
|
114
|
-
<fa-icon
|
|
115
|
-
[icon]="faTimes" class="block text-xl"></fa-icon>
|
|
116
|
-
}
|
|
117
|
-
</div>
|
|
118
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: FontAwesomeModule }, { kind: "component", type: i1.FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }] }); }
|
|
60
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.0.5", type: SpxAlertComponent, isStandalone: true, selector: "spx-alert", inputs: { spxAutoclose: { classPropertyName: "spxAutoclose", publicName: "spxAutoclose", isSignal: true, isRequired: false, transformFunction: null }, spxCloseable: { classPropertyName: "spxCloseable", publicName: "spxCloseable", isSignal: true, isRequired: false, transformFunction: null }, spxHideTitle: { classPropertyName: "spxHideTitle", publicName: "spxHideTitle", isSignal: true, isRequired: false, transformFunction: null }, spxTitle: { classPropertyName: "spxTitle", publicName: "spxTitle", isSignal: true, isRequired: false, transformFunction: null }, spxMarginTop: { classPropertyName: "spxMarginTop", publicName: "spxMarginTop", isSignal: true, isRequired: false, transformFunction: null }, spxSeverity: { classPropertyName: "spxSeverity", publicName: "spxSeverity", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { spxClose: "spxClose", spxTitle: "spxTitleChange" }, ngImport: i0, template: "<div class=\"flex items-center gap-3 border-t-4 rounded px-4 py-3 shadow-md\"\r\n [class.cursor-pointer]=\"this.spxCloseable()\"\r\n [class.bg-red-100]=\"this.spxSeverity() | isSeverity: SpxSeverity.error\"\r\n [class.border-red-500]=\"this.spxSeverity() | isSeverity: SpxSeverity.error\"\r\n [class.text-red-900]=\"this.spxSeverity() | isSeverity: SpxSeverity.error\"\r\n [class.bg-cyan-100]=\"this.spxSeverity() | isSeverity: SpxSeverity.info\"\r\n [class.border-cyan-500]=\"this.spxSeverity() | isSeverity: SpxSeverity.info\"\r\n [class.text-cyan-900]=\"this.spxSeverity() | isSeverity: SpxSeverity.info\"\r\n [class.bg-lime-100]=\"this.spxSeverity() | isSeverity: SpxSeverity.success\"\r\n [class.border-lime-500]=\"this.spxSeverity() | isSeverity: SpxSeverity.success\"\r\n [class.text-lime-900]=\"this.spxSeverity() | isSeverity: SpxSeverity.success\"\r\n [class.bg-amber-100]=\"this.spxSeverity() | isSeverity: SpxSeverity.warning\"\r\n [class.border-amber-500]=\"this.spxSeverity() | isSeverity: SpxSeverity.warning\"\r\n [class.text-amber-900]=\"this.spxSeverity() | isSeverity: SpxSeverity.warning\"\r\n [class.focus:ring-red-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.error)\"\r\n [class.hover:bg-red-200]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.error)\"\r\n [class.over:border-red-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.error)\"\r\n [class.focus:ring-cyan-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.info)\"\r\n [class.hover:bg-cyan-200]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.info)\"\r\n [class.over:border-cyan-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.info)\"\r\n [class.focus:ring-lime-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.success)\"\r\n [class.hover:bg-lime-200]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.success)\"\r\n [class.over:border-lime-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.success)\"\r\n [class.focus:ring-amber-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.warning)\"\r\n [class.hover:bg-amber-200]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.warning)\"\r\n [class.over:border-amber-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.warning)\"\r\n (click)=\"onClose()\">\r\n @if ((this.spxSeverity() | isSeverity: SpxSeverity.info)) {\r\n <fa-icon\r\n [icon]=\"faCircleInfo\" class=\"block text-xl text-cyan-600\"></fa-icon>\r\n }\r\n @if (this.spxSeverity() | isSeverity: SpxSeverity.error) {\r\n <fa-icon\r\n [icon]=\"faTriangleExclamation\" class=\"block text-xl text-red-600\"></fa-icon>\r\n }\r\n @if (this.spxSeverity() | isSeverity: SpxSeverity.success) {\r\n <fa-icon\r\n [icon]=\"faCheck\" class=\"block text-xl text-lime-600\"></fa-icon>\r\n }\r\n @if (this.spxSeverity() | isSeverity: SpxSeverity.warning) {\r\n <fa-icon\r\n [icon]=\"faTriangleExclamation\" class=\"block text-xl text-amber-600\"></fa-icon>\r\n }\r\n <div class=\"grow\">\r\n @if (this.spxTitle() && !this.spxHideTitle()) {\r\n <p class=\"font-bold\">{{this.spxTitle()}}</p>\r\n }\r\n <p class=\"text-sm\">\r\n <ng-content></ng-content>\r\n </p>\r\n </div>\r\n @if (this.spxCloseable()) {\r\n <fa-icon\r\n [icon]=\"faTimes\" class=\"block text-xl\"></fa-icon>\r\n }\r\n </div>", dependencies: [{ kind: "ngmodule", type: FontAwesomeModule }, { kind: "component", type: i1.FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }, { kind: "pipe", type: IsSeverityPipe, name: "isSeverity" }] }); }
|
|
119
61
|
}
|
|
120
62
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.5", ngImport: i0, type: SpxAlertComponent, decorators: [{
|
|
121
63
|
type: Component,
|
|
122
|
-
args: [{
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
template: `
|
|
128
|
-
<div class="flex items-center gap-3 border-t-4 rounded px-4 py-3 shadow-md"
|
|
129
|
-
[class.cursor-pointer]="this.spxCloseable"
|
|
130
|
-
[class.bg-red-100]="this.isSeverityError"
|
|
131
|
-
[class.border-red-500]="this.isSeverityError"
|
|
132
|
-
[class.text-red-900]="this.isSeverityError"
|
|
133
|
-
[class.bg-cyan-100]="this.isSeverityInfo"
|
|
134
|
-
[class.border-cyan-500]="this.isSeverityInfo"
|
|
135
|
-
[class.text-cyan-900]="this.isSeverityInfo"
|
|
136
|
-
[class.bg-lime-100]="this.isSeveritySuccess"
|
|
137
|
-
[class.border-lime-500]="this.isSeveritySuccess"
|
|
138
|
-
[class.text-lime-900]="this.isSeveritySuccess"
|
|
139
|
-
[class.bg-amber-100]="this.isSeverityWarning"
|
|
140
|
-
[class.border-amber-500]="this.isSeverityWarning"
|
|
141
|
-
[class.text-amber-900]="this.isSeverityWarning"
|
|
142
|
-
[class.focus:ring-red-600]="this.spxCloseable && this.isSeverityError"
|
|
143
|
-
[class.hover:bg-red-200]="this.spxCloseable && this.isSeverityError"
|
|
144
|
-
[class.over:border-red-600]="this.spxCloseable && this.isSeverityError"
|
|
145
|
-
[class.focus:ring-cyan-600]="this.spxCloseable && this.isSeverityInfo"
|
|
146
|
-
[class.hover:bg-cyan-200]="this.spxCloseable && this.isSeverityInfo"
|
|
147
|
-
[class.over:border-cyan-600]="this.spxCloseable && this.isSeverityInfo"
|
|
148
|
-
[class.focus:ring-lime-600]="this.spxCloseable && this.isSeveritySuccess"
|
|
149
|
-
[class.hover:bg-lime-200]="this.spxCloseable && this.isSeveritySuccess"
|
|
150
|
-
[class.over:border-lime-600]="this.spxCloseable && this.isSeveritySuccess"
|
|
151
|
-
[class.focus:ring-amber-600]="this.spxCloseable && this.isSeverityWarning"
|
|
152
|
-
[class.hover:bg-amber-200]="this.spxCloseable && this.isSeverityWarning"
|
|
153
|
-
[class.over:border-amber-600]="this.spxCloseable && this.isSeverityWarning"
|
|
154
|
-
(click)="onClose()">
|
|
155
|
-
@if (this.isSeverityInfo) {
|
|
156
|
-
<fa-icon
|
|
157
|
-
[icon]="faCircleInfo" class="block text-xl text-cyan-600"></fa-icon>
|
|
158
|
-
}
|
|
159
|
-
@if (this.isSeverityError) {
|
|
160
|
-
<fa-icon
|
|
161
|
-
[icon]="faTriangleExclamation" class="block text-xl text-red-600"></fa-icon>
|
|
162
|
-
}
|
|
163
|
-
@if (this.isSeveritySuccess) {
|
|
164
|
-
<fa-icon
|
|
165
|
-
[icon]="faCheck" class="block text-xl text-lime-600"></fa-icon>
|
|
166
|
-
}
|
|
167
|
-
@if (this.isSeverityWarning) {
|
|
168
|
-
<fa-icon
|
|
169
|
-
[icon]="faTriangleExclamation" class="block text-xl text-amber-600"></fa-icon>
|
|
170
|
-
}
|
|
171
|
-
<div class="grow">
|
|
172
|
-
@if (this.spxTitle && !this.spxHideTitle) {
|
|
173
|
-
<p class="font-bold">{{this.spxTitle}}</p>
|
|
174
|
-
}
|
|
175
|
-
<p class="text-sm">
|
|
176
|
-
<ng-content></ng-content>
|
|
177
|
-
</p>
|
|
178
|
-
</div>
|
|
179
|
-
@if (this.spxCloseable) {
|
|
180
|
-
<fa-icon
|
|
181
|
-
[icon]="faTimes" class="block text-xl"></fa-icon>
|
|
182
|
-
}
|
|
183
|
-
</div>
|
|
184
|
-
`
|
|
185
|
-
}]
|
|
186
|
-
}], propDecorators: { spxClose: [{
|
|
187
|
-
type: Output
|
|
188
|
-
}], spxAutoclose: [{
|
|
189
|
-
type: Input
|
|
190
|
-
}], spxCloseable: [{
|
|
191
|
-
type: Input
|
|
192
|
-
}], spxHideTitle: [{
|
|
193
|
-
type: Input
|
|
194
|
-
}], spxTitle: [{
|
|
195
|
-
type: Input
|
|
196
|
-
}], spxMarginTop: [{
|
|
197
|
-
type: Input
|
|
198
|
-
}], spxSeverity: [{
|
|
199
|
-
type: Input
|
|
200
|
-
}], tick: [{
|
|
201
|
-
type: Input
|
|
202
|
-
}] } });
|
|
64
|
+
args: [{ selector: 'spx-alert', imports: [
|
|
65
|
+
FontAwesomeModule,
|
|
66
|
+
IsSeverityPipe
|
|
67
|
+
], template: "<div class=\"flex items-center gap-3 border-t-4 rounded px-4 py-3 shadow-md\"\r\n [class.cursor-pointer]=\"this.spxCloseable()\"\r\n [class.bg-red-100]=\"this.spxSeverity() | isSeverity: SpxSeverity.error\"\r\n [class.border-red-500]=\"this.spxSeverity() | isSeverity: SpxSeverity.error\"\r\n [class.text-red-900]=\"this.spxSeverity() | isSeverity: SpxSeverity.error\"\r\n [class.bg-cyan-100]=\"this.spxSeverity() | isSeverity: SpxSeverity.info\"\r\n [class.border-cyan-500]=\"this.spxSeverity() | isSeverity: SpxSeverity.info\"\r\n [class.text-cyan-900]=\"this.spxSeverity() | isSeverity: SpxSeverity.info\"\r\n [class.bg-lime-100]=\"this.spxSeverity() | isSeverity: SpxSeverity.success\"\r\n [class.border-lime-500]=\"this.spxSeverity() | isSeverity: SpxSeverity.success\"\r\n [class.text-lime-900]=\"this.spxSeverity() | isSeverity: SpxSeverity.success\"\r\n [class.bg-amber-100]=\"this.spxSeverity() | isSeverity: SpxSeverity.warning\"\r\n [class.border-amber-500]=\"this.spxSeverity() | isSeverity: SpxSeverity.warning\"\r\n [class.text-amber-900]=\"this.spxSeverity() | isSeverity: SpxSeverity.warning\"\r\n [class.focus:ring-red-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.error)\"\r\n [class.hover:bg-red-200]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.error)\"\r\n [class.over:border-red-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.error)\"\r\n [class.focus:ring-cyan-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.info)\"\r\n [class.hover:bg-cyan-200]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.info)\"\r\n [class.over:border-cyan-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.info)\"\r\n [class.focus:ring-lime-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.success)\"\r\n [class.hover:bg-lime-200]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.success)\"\r\n [class.over:border-lime-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.success)\"\r\n [class.focus:ring-amber-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.warning)\"\r\n [class.hover:bg-amber-200]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.warning)\"\r\n [class.over:border-amber-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.warning)\"\r\n (click)=\"onClose()\">\r\n @if ((this.spxSeverity() | isSeverity: SpxSeverity.info)) {\r\n <fa-icon\r\n [icon]=\"faCircleInfo\" class=\"block text-xl text-cyan-600\"></fa-icon>\r\n }\r\n @if (this.spxSeverity() | isSeverity: SpxSeverity.error) {\r\n <fa-icon\r\n [icon]=\"faTriangleExclamation\" class=\"block text-xl text-red-600\"></fa-icon>\r\n }\r\n @if (this.spxSeverity() | isSeverity: SpxSeverity.success) {\r\n <fa-icon\r\n [icon]=\"faCheck\" class=\"block text-xl text-lime-600\"></fa-icon>\r\n }\r\n @if (this.spxSeverity() | isSeverity: SpxSeverity.warning) {\r\n <fa-icon\r\n [icon]=\"faTriangleExclamation\" class=\"block text-xl text-amber-600\"></fa-icon>\r\n }\r\n <div class=\"grow\">\r\n @if (this.spxTitle() && !this.spxHideTitle()) {\r\n <p class=\"font-bold\">{{this.spxTitle()}}</p>\r\n }\r\n <p class=\"text-sm\">\r\n <ng-content></ng-content>\r\n </p>\r\n </div>\r\n @if (this.spxCloseable()) {\r\n <fa-icon\r\n [icon]=\"faTimes\" class=\"block text-xl\"></fa-icon>\r\n }\r\n </div>" }]
|
|
68
|
+
}] });
|
|
203
69
|
|
|
204
70
|
class SpxAlertI {
|
|
205
71
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"softpak-components-spx-alert.mjs","sources":["../../../../projects/softpak/components/spx-alert/spx-alert.component.ts","../../../../projects/softpak/components/spx-alert/spx-alert.interface.ts","../../../../projects/softpak/components/spx-alert/softpak-components-spx-alert.ts"],"sourcesContent":["\nimport { Component,
|
|
1
|
+
{"version":3,"file":"softpak-components-spx-alert.mjs","sources":["../../../../projects/softpak/components/spx-alert/spx-alert.component.ts","../../../../projects/softpak/components/spx-alert/spx-alert.component.html","../../../../projects/softpak/components/spx-alert/spx-alert.interface.ts","../../../../projects/softpak/components/spx-alert/softpak-components-spx-alert.ts"],"sourcesContent":["\r\nimport { Component, input, model, output } from '@angular/core';\r\nimport { FontAwesomeModule } from '@fortawesome/angular-fontawesome';\r\nimport { faCheck, faCircleInfo, faTimes, faTriangleExclamation } from '@fortawesome/free-solid-svg-icons';\r\nimport { SpxSeverityEnum } from '@softpak/components/spx-helpers';\r\nimport { IsSeverityPipe } from \"@softpak/components/spx-pipes\";\r\n\r\n@Component({\r\n selector: 'spx-alert',\r\n imports: [\r\n FontAwesomeModule,\r\n IsSeverityPipe\r\n],\r\n templateUrl: './spx-alert.component.html'\r\n})\r\nexport class SpxAlertComponent {\r\n _autoCloseTimeout: any;\r\n spxClose = output();\r\n readonly spxAutoclose = input<number>();\r\n readonly spxCloseable = input<boolean | undefined>(false);\r\n readonly spxHideTitle = input(false);\r\n readonly spxTitle = model<string>();\r\n readonly spxMarginTop = input(false);\r\n readonly spxSeverity = input<SpxSeverityEnum>();\r\n SpxSeverity = SpxSeverityEnum;\r\n faCheck = faCheck;\r\n faCircleInfo = faCircleInfo;\r\n faTriangleExclamation = faTriangleExclamation;\r\n faTimes = faTimes;\r\n\r\n componentDidLoad() {\r\n if (this.spxAutoclose()) {\r\n this.prepareAutoClose();\r\n }\r\n if (!this.spxTitle()) {\r\n this._assignDefaultTitle();\r\n }\r\n }\r\n\r\n private prepareAutoClose(): void {\r\n this._autoCloseTimeout = setTimeout(() => {\r\n this.onClose();\r\n this._autoCloseTimeout = null;\r\n }, this.spxAutoclose());\r\n }\r\n\r\n private _assignDefaultTitle(): void {\r\n switch (this.spxSeverity()) {\r\n case SpxSeverityEnum.error:\r\n this.spxTitle.set('Error');\r\n break;\r\n case SpxSeverityEnum.info:\r\n this.spxTitle.set('Info');\r\n break;\r\n case SpxSeverityEnum.success:\r\n this.spxTitle.set('Notification');\r\n break;\r\n case SpxSeverityEnum.warning:\r\n this.spxTitle.set('Warning');\r\n break;\r\n }\r\n }\r\n\r\n onClose() {\r\n if (this.spxCloseable()) {\r\n this.spxClose.emit();\r\n }\r\n }\r\n}\r\n","<div class=\"flex items-center gap-3 border-t-4 rounded px-4 py-3 shadow-md\"\r\n [class.cursor-pointer]=\"this.spxCloseable()\"\r\n [class.bg-red-100]=\"this.spxSeverity() | isSeverity: SpxSeverity.error\"\r\n [class.border-red-500]=\"this.spxSeverity() | isSeverity: SpxSeverity.error\"\r\n [class.text-red-900]=\"this.spxSeverity() | isSeverity: SpxSeverity.error\"\r\n [class.bg-cyan-100]=\"this.spxSeverity() | isSeverity: SpxSeverity.info\"\r\n [class.border-cyan-500]=\"this.spxSeverity() | isSeverity: SpxSeverity.info\"\r\n [class.text-cyan-900]=\"this.spxSeverity() | isSeverity: SpxSeverity.info\"\r\n [class.bg-lime-100]=\"this.spxSeverity() | isSeverity: SpxSeverity.success\"\r\n [class.border-lime-500]=\"this.spxSeverity() | isSeverity: SpxSeverity.success\"\r\n [class.text-lime-900]=\"this.spxSeverity() | isSeverity: SpxSeverity.success\"\r\n [class.bg-amber-100]=\"this.spxSeverity() | isSeverity: SpxSeverity.warning\"\r\n [class.border-amber-500]=\"this.spxSeverity() | isSeverity: SpxSeverity.warning\"\r\n [class.text-amber-900]=\"this.spxSeverity() | isSeverity: SpxSeverity.warning\"\r\n [class.focus:ring-red-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.error)\"\r\n [class.hover:bg-red-200]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.error)\"\r\n [class.over:border-red-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.error)\"\r\n [class.focus:ring-cyan-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.info)\"\r\n [class.hover:bg-cyan-200]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.info)\"\r\n [class.over:border-cyan-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.info)\"\r\n [class.focus:ring-lime-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.success)\"\r\n [class.hover:bg-lime-200]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.success)\"\r\n [class.over:border-lime-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.success)\"\r\n [class.focus:ring-amber-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.warning)\"\r\n [class.hover:bg-amber-200]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.warning)\"\r\n [class.over:border-amber-600]=\"this.spxCloseable() && (this.spxSeverity() | isSeverity: SpxSeverity.warning)\"\r\n (click)=\"onClose()\">\r\n @if ((this.spxSeverity() | isSeverity: SpxSeverity.info)) {\r\n <fa-icon\r\n [icon]=\"faCircleInfo\" class=\"block text-xl text-cyan-600\"></fa-icon>\r\n }\r\n @if (this.spxSeverity() | isSeverity: SpxSeverity.error) {\r\n <fa-icon\r\n [icon]=\"faTriangleExclamation\" class=\"block text-xl text-red-600\"></fa-icon>\r\n }\r\n @if (this.spxSeverity() | isSeverity: SpxSeverity.success) {\r\n <fa-icon\r\n [icon]=\"faCheck\" class=\"block text-xl text-lime-600\"></fa-icon>\r\n }\r\n @if (this.spxSeverity() | isSeverity: SpxSeverity.warning) {\r\n <fa-icon\r\n [icon]=\"faTriangleExclamation\" class=\"block text-xl text-amber-600\"></fa-icon>\r\n }\r\n <div class=\"grow\">\r\n @if (this.spxTitle() && !this.spxHideTitle()) {\r\n <p class=\"font-bold\">{{this.spxTitle()}}</p>\r\n }\r\n <p class=\"text-sm\">\r\n <ng-content></ng-content>\r\n </p>\r\n </div>\r\n @if (this.spxCloseable()) {\r\n <fa-icon\r\n [icon]=\"faTimes\" class=\"block text-xl\"></fa-icon>\r\n }\r\n </div>","import { SpxSeverityEnum } from \"@softpak/components/spx-helpers\";\r\n\r\nexport class SpxAlertI {\r\n closeable?: boolean;\r\n id?: number;\r\n message?: string;\r\n severity?: SpxSeverityEnum;\r\n}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;MAea,iBAAiB,CAAA;AAR9B,IAAA,WAAA,GAAA;QAUE,IAAQ,CAAA,QAAA,GAAG,MAAM,EAAE;QACV,IAAY,CAAA,YAAA,GAAG,KAAK,EAAU;AAC9B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EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,WAAA,EAAA,EAAA,iBAAA,EAAA,aAAA,EAAA,UAAA,EAAA,aAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,OAAA,EAAA,EAAA,QAAA,EAAA,UAAA,EAAA,QAAA,EAAA,gBAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EAAA,slHAuDQ,ED7CJ,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAA,iBAAiB,wPACjB,cAAc,EAAA,IAAA,EAAA,YAAA,EAAA,CAAA,EAAA,CAAA,CAAA;;2FAIL,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAR7B,SAAS;AACI,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,WAAW,EACZ,OAAA,EAAA;wBACT,iBAAiB;wBACjB;AACH,qBAAA,EAAA,QAAA,EAAA,slHAAA,EAAA;;;MEVY,SAAS,CAAA;AAKrB;;ACPD;;AAEG;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"softpak-components-spx-app-configuration.mjs","sources":["../../../../projects/softpak/components/spx-app-configuration/spx-app-channel-type.enum.ts","../../../../projects/softpak/components/spx-app-configuration/spx-app-id.enum.ts","../../../../projects/softpak/components/spx-app-configuration/spx-app-lang.enum.ts","../../../../projects/softpak/components/spx-app-configuration/softpak-components-spx-app-configuration.ts"],"sourcesContent":["export enum SpxAppChannelTypeEnum {\n production = 'Production',\n beta = 'Beta',\n alpha = 'Alpha',\n development = 'Development',\n}\n","export enum SpxAppIdEnum {\n container = 'container',\n depot = 'depot',\n eucon = 'eucon',\n orders = 'orders',\n}\n","export enum SpxAppLangEnum {\n english = 'en',\n dutch = 'nl',\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":"IAAY;AAAZ,CAAA,UAAY,qBAAqB,EAAA;AAC/B,IAAA,qBAAA,CAAA,YAAA,CAAA,GAAA,YAAyB;AACzB,IAAA,qBAAA,CAAA,MAAA,CAAA,GAAA,MAAa;AACb,IAAA,qBAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACf,IAAA,qBAAA,CAAA,aAAA,CAAA,GAAA,aAA2B;AAC7B,CAAC,EALW,qBAAqB,KAArB,qBAAqB,GAKhC,EAAA,CAAA,CAAA;;ICLW;AAAZ,CAAA,UAAY,YAAY,EAAA;AACtB,IAAA,YAAA,CAAA,WAAA,CAAA,GAAA,WAAuB;AACvB,IAAA,YAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACf,IAAA,YAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACf,IAAA,YAAA,CAAA,QAAA,CAAA,GAAA,QAAiB;AACnB,CAAC,EALW,YAAY,KAAZ,YAAY,GAKvB,EAAA,CAAA,CAAA;;ICLW;AAAZ,CAAA,UAAY,cAAc,EAAA;AACxB,IAAA,cAAA,CAAA,SAAA,CAAA,GAAA,IAAc;AACd,IAAA,cAAA,CAAA,OAAA,CAAA,GAAA,IAAY;AACd,CAAC,EAHW,cAAc,KAAd,cAAc,GAGzB,EAAA,CAAA,CAAA;;ACHD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"softpak-components-spx-app-configuration.mjs","sources":["../../../../projects/softpak/components/spx-app-configuration/spx-app-channel-type.enum.ts","../../../../projects/softpak/components/spx-app-configuration/spx-app-id.enum.ts","../../../../projects/softpak/components/spx-app-configuration/spx-app-lang.enum.ts","../../../../projects/softpak/components/spx-app-configuration/softpak-components-spx-app-configuration.ts"],"sourcesContent":["export enum SpxAppChannelTypeEnum {\r\n production = 'Production',\r\n beta = 'Beta',\r\n alpha = 'Alpha',\r\n development = 'Development',\r\n}\r\n","export enum SpxAppIdEnum {\r\n container = 'container',\r\n depot = 'depot',\r\n eucon = 'eucon',\r\n orders = 'orders',\r\n}\r\n","export enum SpxAppLangEnum {\r\n english = 'en',\r\n dutch = 'nl',\r\n}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":"IAAY;AAAZ,CAAA,UAAY,qBAAqB,EAAA;AAC/B,IAAA,qBAAA,CAAA,YAAA,CAAA,GAAA,YAAyB;AACzB,IAAA,qBAAA,CAAA,MAAA,CAAA,GAAA,MAAa;AACb,IAAA,qBAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACf,IAAA,qBAAA,CAAA,aAAA,CAAA,GAAA,aAA2B;AAC7B,CAAC,EALW,qBAAqB,KAArB,qBAAqB,GAKhC,EAAA,CAAA,CAAA;;ICLW;AAAZ,CAAA,UAAY,YAAY,EAAA;AACtB,IAAA,YAAA,CAAA,WAAA,CAAA,GAAA,WAAuB;AACvB,IAAA,YAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACf,IAAA,YAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACf,IAAA,YAAA,CAAA,QAAA,CAAA,GAAA,QAAiB;AACnB,CAAC,EALW,YAAY,KAAZ,YAAY,GAKvB,EAAA,CAAA,CAAA;;ICLW;AAAZ,CAAA,UAAY,cAAc,EAAA;AACxB,IAAA,cAAA,CAAA,SAAA,CAAA,GAAA,IAAc;AACd,IAAA,cAAA,CAAA,OAAA,CAAA,GAAA,IAAY;AACd,CAAC,EAHW,cAAc,KAAd,cAAc,GAGzB,EAAA,CAAA,CAAA;;ACHD;;AAEG;;;;"}
|
|
@@ -28,34 +28,34 @@ class SpxAppExpiryComponent {
|
|
|
28
28
|
}
|
|
29
29
|
}
|
|
30
30
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.5", ngImport: i0, type: SpxAppExpiryComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
31
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.0.5", type: SpxAppExpiryComponent, isStandalone: true, selector: "spx-app-expiry", inputs: { txtContactHelpdeskOrSoftpak: "txtContactHelpdeskOrSoftpak", txtExpired: "txtExpired", txtLastReminder: "txtLastReminder", txtPleaseOpenTheAppStore: "txtPleaseOpenTheAppStore", txtPleaseUpdate: "txtPleaseUpdate", txtThisVersionWillExpireSoon: "txtThisVersionWillExpireSoon", txtUpdateAvailable: "txtUpdateAvailable", txtUpdateTheAppToTheLatestVersion: "txtUpdateTheAppToTheLatestVersion", spxExpiry: "spxExpiry", spxVersion: "spxVersion" }, usesOnChanges: true, ngImport: i0, template: `
|
|
32
|
-
@if (warning || finalWarning || expired) {
|
|
33
|
-
<div class="m-3">
|
|
34
|
-
<div
|
|
35
|
-
class="p-3 font-bold text-white rounded-t text-xl"
|
|
36
|
-
[class.bg-lime-600]="warning"
|
|
37
|
-
[class.bg-red-600]="expired"
|
|
38
|
-
[class.bg-amber-600]="finalWarning">
|
|
39
|
-
@if (warning) {
|
|
40
|
-
{{ txtUpdateAvailable }}
|
|
41
|
-
}
|
|
42
|
-
@if (finalWarning) {
|
|
43
|
-
{{ txtLastReminder }}
|
|
44
|
-
}
|
|
45
|
-
@if (expired) {
|
|
46
|
-
{{ txtExpired }}
|
|
47
|
-
}
|
|
48
|
-
</div>
|
|
49
|
-
<div
|
|
50
|
-
class="bg-amber-50 p-3 text-black rounded-b mb-3">
|
|
51
|
-
<div>{{ txtPleaseOpenTheAppStore }}.</div>
|
|
52
|
-
<div>{{ txtUpdateTheAppToTheLatestVersion }}.</div>
|
|
53
|
-
<div>{{ txtContactHelpdeskOrSoftpak }}.</div>
|
|
54
|
-
@if (finalWarning) {
|
|
55
|
-
<div>{{ txtThisVersionWillExpireSoon }}.</div>
|
|
56
|
-
}
|
|
57
|
-
</div>
|
|
58
|
-
</div>
|
|
31
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.0.5", type: SpxAppExpiryComponent, isStandalone: true, selector: "spx-app-expiry", inputs: { txtContactHelpdeskOrSoftpak: "txtContactHelpdeskOrSoftpak", txtExpired: "txtExpired", txtLastReminder: "txtLastReminder", txtPleaseOpenTheAppStore: "txtPleaseOpenTheAppStore", txtPleaseUpdate: "txtPleaseUpdate", txtThisVersionWillExpireSoon: "txtThisVersionWillExpireSoon", txtUpdateAvailable: "txtUpdateAvailable", txtUpdateTheAppToTheLatestVersion: "txtUpdateTheAppToTheLatestVersion", spxExpiry: "spxExpiry", spxVersion: "spxVersion" }, usesOnChanges: true, ngImport: i0, template: `
|
|
32
|
+
@if (warning || finalWarning || expired) {
|
|
33
|
+
<div class="m-3">
|
|
34
|
+
<div
|
|
35
|
+
class="p-3 font-bold text-white rounded-t text-xl"
|
|
36
|
+
[class.bg-lime-600]="warning"
|
|
37
|
+
[class.bg-red-600]="expired"
|
|
38
|
+
[class.bg-amber-600]="finalWarning">
|
|
39
|
+
@if (warning) {
|
|
40
|
+
{{ txtUpdateAvailable }}
|
|
41
|
+
}
|
|
42
|
+
@if (finalWarning) {
|
|
43
|
+
{{ txtLastReminder }}
|
|
44
|
+
}
|
|
45
|
+
@if (expired) {
|
|
46
|
+
{{ txtExpired }}
|
|
47
|
+
}
|
|
48
|
+
</div>
|
|
49
|
+
<div
|
|
50
|
+
class="bg-amber-50 p-3 text-black rounded-b mb-3">
|
|
51
|
+
<div>{{ txtPleaseOpenTheAppStore }}.</div>
|
|
52
|
+
<div>{{ txtUpdateTheAppToTheLatestVersion }}.</div>
|
|
53
|
+
<div>{{ txtContactHelpdeskOrSoftpak }}.</div>
|
|
54
|
+
@if (finalWarning) {
|
|
55
|
+
<div>{{ txtThisVersionWillExpireSoon }}.</div>
|
|
56
|
+
}
|
|
57
|
+
</div>
|
|
58
|
+
</div>
|
|
59
59
|
}`, isInline: true }); }
|
|
60
60
|
}
|
|
61
61
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.5", ngImport: i0, type: SpxAppExpiryComponent, decorators: [{
|
|
@@ -63,34 +63,34 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.5", ngImpor
|
|
|
63
63
|
args: [{
|
|
64
64
|
selector: 'spx-app-expiry',
|
|
65
65
|
imports: [],
|
|
66
|
-
template: `
|
|
67
|
-
@if (warning || finalWarning || expired) {
|
|
68
|
-
<div class="m-3">
|
|
69
|
-
<div
|
|
70
|
-
class="p-3 font-bold text-white rounded-t text-xl"
|
|
71
|
-
[class.bg-lime-600]="warning"
|
|
72
|
-
[class.bg-red-600]="expired"
|
|
73
|
-
[class.bg-amber-600]="finalWarning">
|
|
74
|
-
@if (warning) {
|
|
75
|
-
{{ txtUpdateAvailable }}
|
|
76
|
-
}
|
|
77
|
-
@if (finalWarning) {
|
|
78
|
-
{{ txtLastReminder }}
|
|
79
|
-
}
|
|
80
|
-
@if (expired) {
|
|
81
|
-
{{ txtExpired }}
|
|
82
|
-
}
|
|
83
|
-
</div>
|
|
84
|
-
<div
|
|
85
|
-
class="bg-amber-50 p-3 text-black rounded-b mb-3">
|
|
86
|
-
<div>{{ txtPleaseOpenTheAppStore }}.</div>
|
|
87
|
-
<div>{{ txtUpdateTheAppToTheLatestVersion }}.</div>
|
|
88
|
-
<div>{{ txtContactHelpdeskOrSoftpak }}.</div>
|
|
89
|
-
@if (finalWarning) {
|
|
90
|
-
<div>{{ txtThisVersionWillExpireSoon }}.</div>
|
|
91
|
-
}
|
|
92
|
-
</div>
|
|
93
|
-
</div>
|
|
66
|
+
template: `
|
|
67
|
+
@if (warning || finalWarning || expired) {
|
|
68
|
+
<div class="m-3">
|
|
69
|
+
<div
|
|
70
|
+
class="p-3 font-bold text-white rounded-t text-xl"
|
|
71
|
+
[class.bg-lime-600]="warning"
|
|
72
|
+
[class.bg-red-600]="expired"
|
|
73
|
+
[class.bg-amber-600]="finalWarning">
|
|
74
|
+
@if (warning) {
|
|
75
|
+
{{ txtUpdateAvailable }}
|
|
76
|
+
}
|
|
77
|
+
@if (finalWarning) {
|
|
78
|
+
{{ txtLastReminder }}
|
|
79
|
+
}
|
|
80
|
+
@if (expired) {
|
|
81
|
+
{{ txtExpired }}
|
|
82
|
+
}
|
|
83
|
+
</div>
|
|
84
|
+
<div
|
|
85
|
+
class="bg-amber-50 p-3 text-black rounded-b mb-3">
|
|
86
|
+
<div>{{ txtPleaseOpenTheAppStore }}.</div>
|
|
87
|
+
<div>{{ txtUpdateTheAppToTheLatestVersion }}.</div>
|
|
88
|
+
<div>{{ txtContactHelpdeskOrSoftpak }}.</div>
|
|
89
|
+
@if (finalWarning) {
|
|
90
|
+
<div>{{ txtThisVersionWillExpireSoon }}.</div>
|
|
91
|
+
}
|
|
92
|
+
</div>
|
|
93
|
+
</div>
|
|
94
94
|
}`
|
|
95
95
|
}]
|
|
96
96
|
}], propDecorators: { txtContactHelpdeskOrSoftpak: [{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"softpak-components-spx-app-expiry.mjs","sources":["../../../../projects/softpak/components/spx-app-expiry/spx-check-expiry-warning.interface.ts","../../../../projects/softpak/components/spx-app-expiry/spx-check-expiry-final-warning.interface.ts","../../../../projects/softpak/components/spx-app-expiry/spx-check-expiry-happened.interface.ts","../../../../projects/softpak/components/spx-app-expiry/spx-app-expiry.component.ts","../../../../projects/softpak/components/spx-app-expiry/softpak-components-spx-app-expiry.ts"],"sourcesContent":["import { DateTime } from \"luxon\";\nimport { SpxAppExpiryI } from \"./spx-app-expiry.interface\";\n\nexport const spxCheckExpiryWarning = (appStoreVersion: string, spxAppExpiry?: SpxAppExpiryI): boolean => {\n return spxAppExpiry !== undefined && appStoreVersion.substring(0,3) !== spxAppExpiry.requiredVersion.substring(0,3) && DateTime.now() > spxAppExpiry.warning;\n}","import { DateTime } from \"luxon\";\nimport { SpxAppExpiryI } from \"./spx-app-expiry.interface\";\n\nexport const spxCheckExpiryFinalWarning = (appStoreVersion: string, spxAppExpiry?: SpxAppExpiryI) => {\n return spxAppExpiry !== undefined && appStoreVersion.substring(0,3) !== spxAppExpiry.requiredVersion.substring(0,3) && DateTime.now() > spxAppExpiry.finalWarning;\n}","import { DateTime } from \"luxon\";\nimport { SpxAppExpiryI } from \"./spx-app-expiry.interface\";\n\nexport const spxCheckExpiryHappened = (appStoreVersion: string, spxAppExpiry: SpxAppExpiryI): boolean => {\n return spxAppExpiry !== undefined && appStoreVersion.substring(0,3) !== spxAppExpiry.requiredVersion.substring(0,3) && DateTime.now() > spxAppExpiry.expiry;\n}","\nimport { Component, Input, OnChanges } from '@angular/core';\nimport { SpxAppExpiryI } from './spx-app-expiry.interface';\nimport { spxCheckExpiryWarning } from './spx-check-expiry-warning.interface';\nimport { spxCheckExpiryFinalWarning } from './spx-check-expiry-final-warning.interface';\nimport { spxCheckExpiryHappened } from './spx-check-expiry-happened.interface';\n\n@Component({\n selector: 'spx-app-expiry',\n imports: [],\n template: `\n @if (warning || finalWarning || expired) {\n <div class=\"m-3\">\n <div\n class=\"p-3 font-bold text-white rounded-t text-xl\"\n [class.bg-lime-600]=\"warning\"\n [class.bg-red-600]=\"expired\"\n [class.bg-amber-600]=\"finalWarning\">\n @if (warning) {\n {{ txtUpdateAvailable }}\n }\n @if (finalWarning) {\n {{ txtLastReminder }}\n }\n @if (expired) {\n {{ txtExpired }}\n }\n </div>\n <div\n class=\"bg-amber-50 p-3 text-black rounded-b mb-3\">\n <div>{{ txtPleaseOpenTheAppStore }}.</div>\n <div>{{ txtUpdateTheAppToTheLatestVersion }}.</div>\n <div>{{ txtContactHelpdeskOrSoftpak }}.</div>\n @if (finalWarning) {\n <div>{{ txtThisVersionWillExpireSoon }}.</div>\n }\n </div>\n </div>\n }`\n})\nexport class SpxAppExpiryComponent implements OnChanges {\n @Input() txtContactHelpdeskOrSoftpak!: string;\n @Input() txtExpired!: string;\n @Input() txtLastReminder!: string;\n @Input() txtPleaseOpenTheAppStore!: string;\n @Input() txtPleaseUpdate!: string;\n @Input() txtThisVersionWillExpireSoon!: string;\n @Input() txtUpdateAvailable!: string;\n @Input() txtUpdateTheAppToTheLatestVersion!: string;\n @Input() spxExpiry!: SpxAppExpiryI;\n @Input() spxVersion!: string;\n warning = false;\n finalWarning = false;\n expired = false;\n ngOnChanges(): void {\n if (this.spxExpiry && this.spxVersion) {\n this.expired = spxCheckExpiryHappened(this.spxVersion, this.spxExpiry);\n this.finalWarning = spxCheckExpiryFinalWarning(this.spxVersion, this.spxExpiry) && !this.expired;\n this.warning = spxCheckExpiryWarning(this.spxVersion, this.spxExpiry) && !this.finalWarning && !this.expired;\n }\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;MAGa,qBAAqB,GAAG,CAAC,eAAuB,EAAE,YAA4B,KAAa;AACtG,IAAA,OAAO,YAAY,KAAK,SAAS,IAAI,eAAe,CAAC,SAAS,CAAC,CAAC,EAAC,CAAC,CAAC,KAAK,YAAY,CAAC,eAAe,CAAC,SAAS,CAAC,CAAC,EAAC,CAAC,CAAC,IAAI,QAAQ,CAAC,GAAG,EAAE,GAAG,YAAY,CAAC,OAAO;AAC9J;;MCFa,0BAA0B,GAAG,CAAC,eAAuB,EAAE,YAA4B,KAAI;AAClG,IAAA,OAAO,YAAY,KAAK,SAAS,IAAI,eAAe,CAAC,SAAS,CAAC,CAAC,EAAC,CAAC,CAAC,KAAK,YAAY,CAAC,eAAe,CAAC,SAAS,CAAC,CAAC,EAAC,CAAC,CAAC,IAAK,QAAQ,CAAC,GAAG,EAAE,GAAG,YAAY,CAAC,YAAY;AACpK;;MCFa,sBAAsB,GAAG,CAAC,eAAuB,EAAE,YAA2B,KAAa;AACtG,IAAA,OAAO,YAAY,KAAK,SAAS,IAAI,eAAe,CAAC,SAAS,CAAC,CAAC,EAAC,CAAC,CAAC,KAAK,YAAY,CAAC,eAAe,CAAC,SAAS,CAAC,CAAC,EAAC,CAAC,CAAC,IAAI,QAAQ,CAAC,GAAG,EAAE,GAAG,YAAY,CAAC,MAAM;AAC7J;;MCmCa,qBAAqB,CAAA;AAjClC,IAAA,WAAA,GAAA;QA4CE,IAA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;;;;;;;;;;AA4BV,GAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,CAAA;;2FAES,qBAAqB,EAAA,UAAA,EAAA,CAAA;kBAjCjC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,gBAAgB;AAC1B,oBAAA,OAAO,EAAE,EAAE;AACX,oBAAA,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA4BV,GAAA;AACH,iBAAA;8BAEU,2BAA2B,EAAA,CAAA;sBAAnC;gBACQ,UAAU,EAAA,CAAA;sBAAlB;gBACQ,eAAe,EAAA,CAAA;sBAAvB;gBACQ,wBAAwB,EAAA,CAAA;sBAAhC;gBACQ,eAAe,EAAA,CAAA;sBAAvB;gBACQ,4BAA4B,EAAA,CAAA;sBAApC;gBACQ,kBAAkB,EAAA,CAAA;sBAA1B;gBACQ,iCAAiC,EAAA,CAAA;sBAAzC;gBACQ,SAAS,EAAA,CAAA;sBAAjB;gBACQ,UAAU,EAAA,CAAA;sBAAlB;;;AClDH;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"softpak-components-spx-app-expiry.mjs","sources":["../../../../projects/softpak/components/spx-app-expiry/spx-check-expiry-warning.interface.ts","../../../../projects/softpak/components/spx-app-expiry/spx-check-expiry-final-warning.interface.ts","../../../../projects/softpak/components/spx-app-expiry/spx-check-expiry-happened.interface.ts","../../../../projects/softpak/components/spx-app-expiry/spx-app-expiry.component.ts","../../../../projects/softpak/components/spx-app-expiry/softpak-components-spx-app-expiry.ts"],"sourcesContent":["import { DateTime } from \"luxon\";\r\nimport { SpxAppExpiryI } from \"./spx-app-expiry.interface\";\r\n\r\nexport const spxCheckExpiryWarning = (appStoreVersion: string, spxAppExpiry?: SpxAppExpiryI): boolean => {\r\n return spxAppExpiry !== undefined && appStoreVersion.substring(0,3) !== spxAppExpiry.requiredVersion.substring(0,3) && DateTime.now() > spxAppExpiry.warning;\r\n}","import { DateTime } from \"luxon\";\r\nimport { SpxAppExpiryI } from \"./spx-app-expiry.interface\";\r\n\r\nexport const spxCheckExpiryFinalWarning = (appStoreVersion: string, spxAppExpiry?: SpxAppExpiryI) => {\r\n return spxAppExpiry !== undefined && appStoreVersion.substring(0,3) !== spxAppExpiry.requiredVersion.substring(0,3) && DateTime.now() > spxAppExpiry.finalWarning;\r\n}","import { DateTime } from \"luxon\";\r\nimport { SpxAppExpiryI } from \"./spx-app-expiry.interface\";\r\n\r\nexport const spxCheckExpiryHappened = (appStoreVersion: string, spxAppExpiry: SpxAppExpiryI): boolean => {\r\n return spxAppExpiry !== undefined && appStoreVersion.substring(0,3) !== spxAppExpiry.requiredVersion.substring(0,3) && DateTime.now() > spxAppExpiry.expiry;\r\n}","\r\nimport { Component, Input, OnChanges } from '@angular/core';\r\nimport { SpxAppExpiryI } from './spx-app-expiry.interface';\r\nimport { spxCheckExpiryWarning } from './spx-check-expiry-warning.interface';\r\nimport { spxCheckExpiryFinalWarning } from './spx-check-expiry-final-warning.interface';\r\nimport { spxCheckExpiryHappened } from './spx-check-expiry-happened.interface';\r\n\r\n@Component({\r\n selector: 'spx-app-expiry',\r\n imports: [],\r\n template: `\r\n @if (warning || finalWarning || expired) {\r\n <div class=\"m-3\">\r\n <div\r\n class=\"p-3 font-bold text-white rounded-t text-xl\"\r\n [class.bg-lime-600]=\"warning\"\r\n [class.bg-red-600]=\"expired\"\r\n [class.bg-amber-600]=\"finalWarning\">\r\n @if (warning) {\r\n {{ txtUpdateAvailable }}\r\n }\r\n @if (finalWarning) {\r\n {{ txtLastReminder }}\r\n }\r\n @if (expired) {\r\n {{ txtExpired }}\r\n }\r\n </div>\r\n <div\r\n class=\"bg-amber-50 p-3 text-black rounded-b mb-3\">\r\n <div>{{ txtPleaseOpenTheAppStore }}.</div>\r\n <div>{{ txtUpdateTheAppToTheLatestVersion }}.</div>\r\n <div>{{ txtContactHelpdeskOrSoftpak }}.</div>\r\n @if (finalWarning) {\r\n <div>{{ txtThisVersionWillExpireSoon }}.</div>\r\n }\r\n </div>\r\n </div>\r\n }`\r\n})\r\nexport class SpxAppExpiryComponent implements OnChanges {\r\n @Input() txtContactHelpdeskOrSoftpak!: string;\r\n @Input() txtExpired!: string;\r\n @Input() txtLastReminder!: string;\r\n @Input() txtPleaseOpenTheAppStore!: string;\r\n @Input() txtPleaseUpdate!: string;\r\n @Input() txtThisVersionWillExpireSoon!: string;\r\n @Input() txtUpdateAvailable!: string;\r\n @Input() txtUpdateTheAppToTheLatestVersion!: string;\r\n @Input() spxExpiry!: SpxAppExpiryI;\r\n @Input() spxVersion!: string;\r\n warning = false;\r\n finalWarning = false;\r\n expired = false;\r\n ngOnChanges(): void {\r\n if (this.spxExpiry && this.spxVersion) {\r\n this.expired = spxCheckExpiryHappened(this.spxVersion, this.spxExpiry);\r\n this.finalWarning = spxCheckExpiryFinalWarning(this.spxVersion, this.spxExpiry) && !this.expired;\r\n this.warning = spxCheckExpiryWarning(this.spxVersion, this.spxExpiry) && !this.finalWarning && !this.expired;\r\n }\r\n }\r\n}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;MAGa,qBAAqB,GAAG,CAAC,eAAuB,EAAE,YAA4B,KAAa;AACtG,IAAA,OAAO,YAAY,KAAK,SAAS,IAAI,eAAe,CAAC,SAAS,CAAC,CAAC,EAAC,CAAC,CAAC,KAAK,YAAY,CAAC,eAAe,CAAC,SAAS,CAAC,CAAC,EAAC,CAAC,CAAC,IAAI,QAAQ,CAAC,GAAG,EAAE,GAAG,YAAY,CAAC,OAAO;AAC9J;;MCFa,0BAA0B,GAAG,CAAC,eAAuB,EAAE,YAA4B,KAAI;AAClG,IAAA,OAAO,YAAY,KAAK,SAAS,IAAI,eAAe,CAAC,SAAS,CAAC,CAAC,EAAC,CAAC,CAAC,KAAK,YAAY,CAAC,eAAe,CAAC,SAAS,CAAC,CAAC,EAAC,CAAC,CAAC,IAAK,QAAQ,CAAC,GAAG,EAAE,GA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