@acorex/core 18.4.4 → 18.5.1
Sign up to get free protection for your applications and to get access to all the features.
- package/date-time/index.d.ts +2 -2
- package/esm2022/config/lib/configs.mjs +1 -1
- package/esm2022/date-time/index.mjs +3 -3
- package/esm2022/date-time/lib/dateTime.config.mjs +1 -1
- package/esm2022/date-time/lib/datetime.pipe.mjs +1 -1
- package/esm2022/date-time/lib/formatters/datetime-formatter.mjs +1 -1
- package/esm2022/date-time/lib/georgian.calendar.mjs +4 -9
- package/esm2022/date-time/lib/holidays.loader.mjs +1 -1
- package/esm2022/date-time/lib/jalali.calendar.mjs +10 -33
- package/esm2022/file/index.mjs +3 -3
- package/esm2022/file/lib/file-download-ref.class.mjs +1 -1
- package/esm2022/file/lib/file-upload-ref.class.mjs +1 -1
- package/esm2022/format/index.mjs +2 -2
- package/esm2022/format/lib/format.module.mjs +2 -2
- package/esm2022/format/lib/format.pipe.mjs +4 -8
- package/esm2022/image/lib/image.service.mjs +1 -1
- package/esm2022/pipes/lib/safe/safe.pipe.mjs +2 -2
- package/esm2022/platform/lib/platform.service.mjs +2 -1
- package/esm2022/storage/cookie-storage.service.mjs +5 -11
- package/esm2022/translation/index.mjs +3 -3
- package/esm2022/translation/lib/translation-scope.resolver.mjs +2 -2
- package/esm2022/translation/lib/translation.config.mjs +1 -1
- package/esm2022/translation/lib/translation.loader.mjs +1 -1
- package/esm2022/translation/lib/translation.module.mjs +4 -4
- package/esm2022/translation/lib/translator.directive.mjs +2 -2
- package/esm2022/translation/lib/translator.pipe.mjs +2 -2
- package/esm2022/utils/lib/auto-unsubscribe.mjs +1 -1
- package/esm2022/utils/lib/color-util.mjs +2 -4
- package/esm2022/utils/lib/drawing-util.mjs +4 -10
- package/esm2022/utils/lib/string-util.mjs +1 -1
- package/esm2022/validation/lib/rules/between-rule.mjs +2 -2
- package/esm2022/validation/lib/rules/equal-rule.mjs +2 -2
- package/esm2022/validation/lib/rules/greater-than.mjs +3 -7
- package/esm2022/validation/lib/rules/length-rule.mjs +2 -5
- package/esm2022/validation/lib/rules/less-than-rule.mjs +3 -7
- package/esm2022/validation/lib/rules/maxlength-rule.mjs +3 -6
- package/esm2022/validation/lib/rules/minlength-rule.mjs +3 -6
- package/esm2022/validation/lib/rules/regex-rule.mjs +5 -8
- package/esm2022/validation/lib/rules/required-rule.mjs +6 -4
- package/esm2022/validation/lib/validation.config.mjs +1 -1
- package/esm2022/validation/lib/validation.module.mjs +10 -10
- package/esm2022/validation/lib/validation.service.mjs +3 -3
- package/esm2022/validation/lib/validation.types.mjs +1 -1
- package/fesm2022/acorex-core-config.mjs.map +1 -1
- package/fesm2022/acorex-core-date-time.mjs +87 -115
- package/fesm2022/acorex-core-date-time.mjs.map +1 -1
- package/fesm2022/acorex-core-file.mjs +42 -42
- package/fesm2022/acorex-core-file.mjs.map +1 -1
- package/fesm2022/acorex-core-format.mjs +2 -6
- package/fesm2022/acorex-core-format.mjs.map +1 -1
- package/fesm2022/acorex-core-image.mjs.map +1 -1
- package/fesm2022/acorex-core-pipes.mjs.map +1 -1
- package/fesm2022/acorex-core-platform.mjs +1 -0
- package/fesm2022/acorex-core-platform.mjs.map +1 -1
- package/fesm2022/acorex-core-storage.mjs +4 -10
- package/fesm2022/acorex-core-storage.mjs.map +1 -1
- package/fesm2022/acorex-core-translation.mjs +27 -27
- package/fesm2022/acorex-core-translation.mjs.map +1 -1
- package/fesm2022/acorex-core-utils.mjs +4 -12
- package/fesm2022/acorex-core-utils.mjs.map +1 -1
- package/fesm2022/acorex-core-validation.mjs +11 -29
- package/fesm2022/acorex-core-validation.mjs.map +1 -1
- package/file/index.d.ts +2 -2
- package/format/index.d.ts +1 -1
- package/format/lib/format.pipe.d.ts +1 -1
- package/package.json +17 -17
- package/platform/lib/platform.service.d.ts +1 -1
- package/translation/index.d.ts +2 -2
- package/translation/lib/translation.loader.d.ts +1 -1
- package/translation/lib/translator.pipe.d.ts +1 -1
- package/validation/lib/validation.service.d.ts +2 -2
@@ -94,9 +94,7 @@ export class AXColorUtil {
|
|
94
94
|
X * 0.051713 - Y * 0.121364 + Z * 1.01153,
|
95
95
|
];
|
96
96
|
// Apply reverse gamma correction.
|
97
|
-
rgb = rgb.map((x) => x <= 0.0031308
|
98
|
-
? 12.92 * x
|
99
|
-
: (1.0 + 0.055) * Math.pow(x, 1.0 / 2.4) - 0.055);
|
97
|
+
rgb = rgb.map((x) => (x <= 0.0031308 ? 12.92 * x : (1.0 + 0.055) * Math.pow(x, 1.0 / 2.4) - 0.055));
|
100
98
|
// Bring all negative components to zero.
|
101
99
|
rgb = rgb.map((x) => Math.max(0, x));
|
102
100
|
// If one component is greater than 1, weight components by that value.
|
@@ -108,4 +106,4 @@ export class AXColorUtil {
|
|
108
106
|
return 'rgb(' + rgb.join(',') + ')';
|
109
107
|
}
|
110
108
|
}
|
111
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29sb3ItdXRpbC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL2xpYnMvY29yZS91dGlscy9zcmMvbGliL2NvbG9yLXV0aWwudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBRUEsT0FBTyxTQUF5QixNQUFNLFlBQVksQ0FBQztBQUNuRCxPQUFPLFlBQTBCLE1BQU0saUJBQWlCLENBQUM7QUFJekQsTUFBTSxPQUFPLFdBQVc7SUFDdEIsTUFBTSxDQUFDLEVBQUUsQ0FBQyxLQUFvQixFQUFFLElBQWlCO1FBQy9DLE1BQU0sTUFBTSxHQUFHLFNBQVMsQ0FBQyxLQUFLLENBQUMsQ0FBQztRQUNoQyxRQUFRLElBQUksRUFBRSxDQUFDO1lBQ2IsS0FBSyxNQUFNO2dCQUNULE9BQU8sTUFBTSxDQUFDLEtBQUssRUFBRSxDQUFDO1lBQ3hCLEtBQUssTUFBTTtnQkFDVCxPQUFPLE1BQU0sQ0FBQyxLQUFLLEVBQUUsQ0FBQztZQUN4QixLQUFLL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XG4gICAgLy8gQ29udmVydCB0byBSR0IgdXNpbmcgV2lkZSBSR0IgRDY1IGNvbnZlcnNpb24uXG4gICAgbGV0IHJnYiA9IFtcbiAgICAgIFggKiAxLjY1NjQ5MiAtIFkgKiAwLjM1NDg1MSAtIFogKiAwLjI1NTAzOCxcbiAgICAgIC1YICogMC43MDcxOTYgKyBZICogMS42NTUzOTcgKyBaICogMC4wMzYxNTIsXG4gICAgICBYICogMC4wNTE3MTMgLSBZICogMC4xMjEzNjQgKyBaICogMS4wMTE1MyxcbiAgICBdO1xuXG4gICAgLy8gQXBwbHkgcmV2ZXJzZSBnYW1tYSBjb3JyZWN0aW9uLlxuICAgIHJnYiA9IHJnYi5tYXAoKHgpID0+ICh4IDw9IDAuMDAzMTMwOCA/IDEyLjkyICogeCA6ICgxLjAgKyAwLjA1NSkgKiBNYXRoLnBvdyh4LCAxLjAgLyAyLjQpIC0gMC4wNTUpKTtcblxuICAgIC8vIEJyaW5nIGFsbCBuZWdhdGl2ZSBjb21wb25lbnRzIHRvIHplcm8uXG4gICAgcmdiID0gcmdiLm1hcCgoeCkgPT4gTWF0aC5tYXgoMCwgeCkpO1xuXG4gICAgLy8gSWYgb25lIGNvbXBvbmVudCBpcyBncmVhdGVyIHRoYW4gMSwgd2VpZ2h0IGNvbXBvbmVudHMgYnkgdGhhdCB2YWx1ZS5cbiAgICBjb25zdCBtYXggPSBNYXRoLm1heCguLi5yZ2IpO1xuICAgIGlmIChtYXggPiAxKSB7XG4gICAgICByZ2IgPSByZ2IubWFwKCh4KSA9PiB4IC8gbWF4KTtcbiAgICB9XG5cbiAgICByZ2IgPSByZ2IubWFwKCh4KSA9PiBNYXRoLnJvdW5kKHggKiAyNTUpKTtcblxuICAgIHJldHVybiAncmdiKCcgKyByZ2Iuam9pbignLCcpICsgJyknO1xuICB9XG59XG4iXX0=
|
@@ -3,10 +3,7 @@ export class AXDrawingUtil {
|
|
3
3
|
static collision(a, b) {
|
4
4
|
const ac = a.getBoundingClientRect();
|
5
5
|
const bc = b.getBoundingClientRect();
|
6
|
-
if (ac.left < bc.left + bc.width &&
|
7
|
-
ac.left + ac.width > bc.left &&
|
8
|
-
ac.top < bc.top + bc.height &&
|
9
|
-
ac.top + ac.height > bc.top) {
|
6
|
+
if (ac.left < bc.left + bc.width && ac.left + ac.width > bc.left && ac.top < bc.top + bc.height && ac.top + ac.height > bc.top) {
|
10
7
|
return true;
|
11
8
|
}
|
12
9
|
else {
|
@@ -23,13 +20,10 @@ export class AXDrawingUtil {
|
|
23
20
|
});
|
24
21
|
}
|
25
22
|
static isInRecPoint(pos, rec) {
|
26
|
-
return
|
27
|
-
pos.x <= rec.left + rec.width &&
|
28
|
-
pos.y >= rec.top &&
|
29
|
-
pos.y <= rec.top + rec.height);
|
23
|
+
return pos.x >= rec.left && pos.x <= rec.left + rec.width && pos.y >= rec.top && pos.y <= rec.top + rec.height;
|
30
24
|
}
|
31
25
|
static convertRemToPixels(rem) {
|
32
|
-
return
|
26
|
+
return rem * parseFloat(getComputedStyle(document.documentElement).fontSize);
|
33
27
|
}
|
34
28
|
}
|
35
|
-
//# sourceMappingURL=data:application/json;base64,
|
29
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZHJhd2luZy11dGlsLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vbGlicy9jb3JlL3V0aWxzL3NyYy9saWIvZHJhd2luZy11dGlsLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQWFBLFdBQVc7QUFDWCxNQUFNLE9BQU8sYUFBYTtJQUN4QixNQUFNLENBQUMsU0FBUyxDQUFDLENBQWMsRUFBRSxDQUFjO1FBQzdDLE1BQU0sRUFBRSxHQUFHLENBQUMsQ0FBQyxxQkFBcUIsRUFBRSxDQUFDO1FBQ3JDLE1BQU0sRUFBRSxHQUFHLENBQUMsQ0FBQyxxQkFBcUIsRUFBRSxDQUFD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gIHJldHVybiB0cnVlO1xuICAgIH0gZWxzZSB7XG4gICAgICByZXR1cm4gZmFsc2U7XG4gICAgfVxuICB9XG5cbiAgc3RhdGljIGlzSW5FbGVtZW50Qm91bmQocG9zOiBBWFBvaW50LCBlbGVtZW50OiBIVE1MRWxlbWVudCk6IGJvb2xlYW4ge1xuICAgIGNvbnN0IGVsQm91bmQgPSBlbGVtZW50LmdldEJvdW5kaW5nQ2xpZW50UmVjdCgpO1xuICAgIHJldHVybiBBWERyYXdpbmdVdGlsLmlzSW5SZWNQb2ludChwb3MsIHtcbiAgICAgIGxlZnQ6IGVsQm91bmQueCxcbiAgICAgIHdpZHRoOiBlbEJvdW5kLndpZHRoLFxuICAgICAgdG9wOiBlbEJvdW5kLnksXG4gICAgICBoZWlnaHQ6IGVsQm91bmQuaGVpZ2h0LFxuICAgIH0pO1xuICB9XG5cbiAgc3RhdGljIGlzSW5SZWNQb2ludChwb3M6IEFYUG9pbnQsIHJlYzogQVhCb3VuZGluZ0NsaWVudFJlY3QgfCBhbnkpOiBib29sZWFuIHtcbiAgICByZXR1cm4gcG9zLnggPj0gcmVjLmxlZnQgJiYgcG9zLnggPD0gcmVjLmxlZnQgKyByZWMud2lkdGggJiYgcG9zLnkgPj0gcmVjLnRvcCAmJiBwb3MueSA8PSByZWMudG9wICsgcmVjLmhlaWdodDtcbiAgfVxuXG4gIHN0YXRpYyBjb252ZXJ0UmVtVG9QaXhlbHMocmVtOiBudW1iZXIpOiBudW1iZXIge1xuICAgIHJldHVybiByZW0gKiBwYXJzZUZsb2F0KGdldENvbXB1dGVkU3R5bGUoZG9jdW1lbnQuZG9jdW1lbnRFbGVtZW50KS5mb250U2l6ZSk7XG4gIH1cbn1cbiJdfQ==
|
@@ -16,4 +16,4 @@ export class AXStringUtil {
|
|
16
16
|
};
|
17
17
|
}
|
18
18
|
}
|
19
|
-
//# sourceMappingURL=data:application/json;base64,
|
19
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjoz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xuZXhwb3J0IGNsYXNzIEFYU3RyaW5nVXRpbCB7XG4gIHN0YXRpYyBnZXRXb3JkQm91bmRzQXRQb3NpdGlvbihzdHI6IHN0cmluZywgcG9zaXRpb246IG51bWJlcik6IHsgc3RhcnQ6IG51bWJlcjsgZW5kOiBudW1iZXIgfSB7XG4gICAgY29uc3QgaXNTcGFjZSA9IChjKSA9PiAvW15hLXpBLVowLTldKy9pLnRlc3QoYyk7XG4gICAgbGV0IHN0YXJ0ID0gcG9zaXRpb24gLSAxO1xuXG4gICAgd2hpbGUgKHN0YXJ0ID49IDAgJiYgIWlzU3BhY2Uoc3RyW3N0YXJ0XSkpIHtcbiAgICAgIHN0YXJ0IC09IDE7XG4gICAgfVxuICAgIHN0YXJ0ID0gTWF0aC5tYXgoMCwgc3RhcnQgKyAxKTtcbiAgICBjb25zdCBsZWZ0U2lkZVN0cmluZzogYW55ID0gc3RyLnNsaWNlKHN0YXJ0KS5tYXRjaCgvW2EtekEtWjAtOV0rL2kpO1xuICAgIHN0YXJ0ICs9IGxlZnRTaWRlU3RyaW5nLmluZGV4O1xuICAgIGxldCBlbmQgPSBzdGFydCArIGxlZnRTaWRlU3RyaW5nWzBdLmxlbmd0aDtcbiAgICByZXR1cm4ge1xuICAgICAgc3RhcnQsXG4gICAgICBlbmQsXG4gICAgfTtcbiAgfVxufVxuIl19
|
@@ -1,5 +1,5 @@
|
|
1
|
-
import { isEmpty } from 'lodash-es';
|
2
1
|
import { Injectable } from '@angular/core';
|
2
|
+
import { isEmpty } from 'lodash-es';
|
3
3
|
import * as i0 from "@angular/core";
|
4
4
|
export class AXBetweenValidationRule {
|
5
5
|
get name() {
|
@@ -28,4 +28,4 @@ export class AXBetweenValidationRule {
|
|
28
28
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.2", ngImport: i0, type: AXBetweenValidationRule, decorators: [{
|
29
29
|
type: Injectable
|
30
30
|
}] });
|
31
|
-
//# sourceMappingURL=data:application/json;base64,
|
31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IG9wdGlvbnM/Lm1lc3NhZ2UgPz8gYmFzZU1lc3NhZ2UsXG4gICAgICB2YWx1ZTogdmFsdWUsXG4gICAgfTtcbiAgfVxufVxuIl19
|
@@ -1,6 +1,6 @@
|
|
1
1
|
// ax-equal-validation-rule.ts
|
2
|
-
import { isEqual } from 'lodash-es';
|
3
2
|
import { Injectable } from '@angular/core';
|
3
|
+
import { isEqual } from 'lodash-es';
|
4
4
|
import * as i0 from "@angular/core";
|
5
5
|
export class AXEqualValidationRule {
|
6
6
|
get name() {
|
@@ -23,4 +23,4 @@ export class AXEqualValidationRule {
|
|
23
23
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.2", ngImport: i0, type: AXEqualValidationRule, decorators: [{
|
24
24
|
type: Injectable
|
25
25
|
}] });
|
26
|
-
//# sourceMappingURL=data:application/json;base64,
|
26
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZXF1YWwtcnVsZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uLy4uL2xpYnMvY29yZS92YWxpZGF0aW9uL3NyYy9saWIvcnVsZXMvZXF1YWwtcnVsZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSw4QkFBOEI7QUFDOUIsT0FBTyxFQUFFLFVBQVUsRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUMzQyxPQUFPLEVBQUUsT0FBTyxFQUFFLE1BQU0sV0FBVyxDQUFDOztBQWNwQyxNQUFNLE9BQU8scUJBQXFCO0lBQ2hDLElBQUksSUFBSTtRQUNOLE9BQU8sT0FBTyxDQUFDO0lBQ2pCLENBQUM7SUFFRCxLQUFLLENBQUMsUUFBUSxDQUFDLEtBQVUsRUFBRSxPQUFxQztRQUM5RCxNQUFNLFlBQVksR0FBRyxPQUFPLENBQUMsS0FBSyxFQUFFLE9BQU8sQ0FBQyxLQUFLLENBQ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sXG4gICAgfTtcbiAgfVxufVxuIl19
|
@@ -1,17 +1,13 @@
|
|
1
1
|
// ax-greater-than-validation-rule.ts
|
2
|
-
import { isNull, isUndefined } from 'lodash-es';
|
3
2
|
import { Injectable } from '@angular/core';
|
3
|
+
import { isNull, isUndefined } from 'lodash-es';
|
4
4
|
import * as i0 from "@angular/core";
|
5
5
|
export class AXGreaterThanValidationRule {
|
6
6
|
get name() {
|
7
7
|
return 'greaterThan';
|
8
8
|
}
|
9
9
|
async validate(value, options) {
|
10
|
-
const isValid = isNull(value) || isUndefined(value)
|
11
|
-
? true
|
12
|
-
: options.inclusive
|
13
|
-
? value >= options.value
|
14
|
-
: value > options.value;
|
10
|
+
const isValid = isNull(value) || isUndefined(value) ? true : options.inclusive ? value >= options.value : value > options.value;
|
15
11
|
const baseMessage = `The value must be ${options.inclusive ? 'greater than or equal to' : 'greater than'} ${options.value}.`;
|
16
12
|
return {
|
17
13
|
rule: this.name,
|
@@ -26,4 +22,4 @@ export class AXGreaterThanValidationRule {
|
|
26
22
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.2", ngImport: i0, type: AXGreaterThanValidationRule, decorators: [{
|
27
23
|
type: Injectable
|
28
24
|
}] });
|
29
|
-
//# sourceMappingURL=data:application/json;base64,
|
25
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZ3JlYXRlci10aGFuLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vLi4vbGlicy9jb3JlL3ZhbGlkYXRpb24vc3JjL2xpYi9ydWxlcy9ncmVhdGVyLXRoYW4udHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEscUNBQXFDO0FBQ3JDLE9BQU8sRUFBRSxVQUFVLEVBQUUsTUFBTSxlQUFlLENBQUM7QUFDM0MsT0FBTyxFQUFFLE1BQU0sRUFBRSxXQUFXLEVBQUUsTUFB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lvbnMuaW5jbHVzaXZlID8gdmFsdWUgPj0gb3B0aW9ucy52YWx1ZSA6IHZhbHVlID4gb3B0aW9ucy52YWx1ZTtcbiAgICBjb25zdCBiYXNlTWVzc2FnZSA9IGBUaGUgdmFsdWUgbXVzdCBiZSAke29wdGlvbnMuaW5jbHVzaXZlID8gJ2dyZWF0ZXIgdGhhbiBvciBlcXVhbCB0bycgOiAnZ3JlYXRlciB0aGFuJ30gJHtvcHRpb25zLnZhbHVlfS5gO1xuXG4gICAgcmV0dXJuIHtcbiAgICAgIHJ1bGU6IHRoaXMubmFtZSxcbiAgICAgIHJlc3VsdDogaXNWYWxpZCxcbiAgICAgIG1lc3NhZ2U6IGlzVmFsaWQgPyAnJyA6IG9wdGlvbnM/Lm1lc3NhZ2UgPz8gYmFzZU1lc3NhZ2UsXG4gICAgICB2YWx1ZTogdmFsdWUsXG4gICAgfTtcbiAgfVxufVxuIl19
|
@@ -10,10 +10,7 @@ export class AXLengthValidationRule {
|
|
10
10
|
return {
|
11
11
|
rule: this.name,
|
12
12
|
result: isValid,
|
13
|
-
message: isValid
|
14
|
-
? null
|
15
|
-
: options?.message ??
|
16
|
-
`The value must be between ${options.min} and ${options.max} chars`,
|
13
|
+
message: isValid ? null : options?.message ?? `The value must be between ${options.min} and ${options.max} chars`,
|
17
14
|
value: value,
|
18
15
|
};
|
19
16
|
}
|
@@ -23,4 +20,4 @@ export class AXLengthValidationRule {
|
|
23
20
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.2", ngImport: i0, type: AXLengthValidationRule, decorators: [{
|
24
21
|
type: Injectable
|
25
22
|
}] });
|
26
|
-
//# sourceMappingURL=data:application/json;base64,
|
23
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibGVuZ3RoLXJ1bGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9saWJzL2NvcmUvdm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6IHZhbHVlLFxuICAgIH07XG4gIH1cbn1cbiJdfQ==
|
@@ -1,17 +1,13 @@
|
|
1
1
|
// ax-less-than-validation-rule.ts
|
2
|
-
import { isNull, isUndefined } from 'lodash-es';
|
3
2
|
import { Injectable } from '@angular/core';
|
3
|
+
import { isNull, isUndefined } from 'lodash-es';
|
4
4
|
import * as i0 from "@angular/core";
|
5
5
|
export class AXLessThanValidationRule {
|
6
6
|
get name() {
|
7
7
|
return 'lessThan';
|
8
8
|
}
|
9
9
|
async validate(value, options) {
|
10
|
-
const isValid = isNull(value) || isUndefined(value)
|
11
|
-
? true
|
12
|
-
: options.inclusive
|
13
|
-
? value <= options.value
|
14
|
-
: value < options.value;
|
10
|
+
const isValid = isNull(value) || isUndefined(value) ? true : options.inclusive ? value <= options.value : value < options.value;
|
15
11
|
const baseMessage = `The value must be ${options.inclusive ? 'less than or equal to' : 'less than'} ${options.value}.`;
|
16
12
|
return {
|
17
13
|
rule: this.name,
|
@@ -26,4 +22,4 @@ export class AXLessThanValidationRule {
|
|
26
22
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.2", ngImport: i0, type: AXLessThanValidationRule, decorators: [{
|
27
23
|
type: Injectable
|
28
24
|
}] });
|
29
|
-
//# sourceMappingURL=data:application/json;base64,
|
25
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibGVzcy10aGFuLXJ1bGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9saWJzL2NvcmUvdmFsaWRhdGlvbi9zcmMvbGliL3J1bGVzL2xlc3MtdGhhbi1ydWxlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLGtDQUFrQztBQUNsQyxPQUFPLEVBQUUsVUFBVSxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBQzNDLE9BQU8sRUFBRSxNQUFNLEVBQUUsV0FBVyxFQU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vbnMudmFsdWUgOiB2YWx1ZSA8IG9wdGlvbnMudmFsdWU7XG4gICAgY29uc3QgYmFzZU1lc3NhZ2UgPSBgVGhlIHZhbHVlIG11c3QgYmUgJHtvcHRpb25zLmluY2x1c2l2ZSA/ICdsZXNzIHRoYW4gb3IgZXF1YWwgdG8nIDogJ2xlc3MgdGhhbid9ICR7b3B0aW9ucy52YWx1ZX0uYDtcblxuICAgIHJldHVybiB7XG4gICAgICBydWxlOiB0aGlzLm5hbWUsXG4gICAgICByZXN1bHQ6IGlzVmFsaWQsXG4gICAgICBtZXNzYWdlOiBpc1ZhbGlkID8gJycgOiBvcHRpb25zPy5tZXNzYWdlID8/IGJhc2VNZXNzYWdlLFxuICAgICAgdmFsdWU6IHZhbHVlLFxuICAgIH07XG4gIH1cbn1cbiJdfQ==
|
@@ -1,6 +1,6 @@
|
|
1
1
|
// ax-max-length-validation-rule.ts
|
2
|
-
import { isEmpty } from 'lodash-es';
|
3
2
|
import { Injectable } from '@angular/core';
|
3
|
+
import { isEmpty } from 'lodash-es';
|
4
4
|
import * as i0 from "@angular/core";
|
5
5
|
export class AXMaxLengthValidationRule {
|
6
6
|
get name() {
|
@@ -11,10 +11,7 @@ export class AXMaxLengthValidationRule {
|
|
11
11
|
return {
|
12
12
|
rule: this.name,
|
13
13
|
result: isValid,
|
14
|
-
message: isValid
|
15
|
-
? ''
|
16
|
-
: options?.message ??
|
17
|
-
`The value must not exceed ${options.value} characters.`,
|
14
|
+
message: isValid ? '' : options?.message ?? `The value must not exceed ${options.value} characters.`,
|
18
15
|
value: value,
|
19
16
|
};
|
20
17
|
}
|
@@ -24,4 +21,4 @@ export class AXMaxLengthValidationRule {
|
|
24
21
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.2", ngImport: i0, type: AXMaxLengthValidationRule, decorators: [{
|
25
22
|
type: Injectable
|
26
23
|
}] });
|
27
|
-
//# sourceMappingURL=data:application/json;base64,
|
24
|
+
//# sourceMappingURL=data:application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AgcmV0dXJuIHtcbiAgICAgIHJ1bGU6IHRoaXMubmFtZSxcbiAgICAgIHJlc3VsdDogaXNWYWxpZCxcbiAgICAgIG1lc3NhZ2U6IGlzVmFsaWQgPyAnJyA6IG9wdGlvbnM/Lm1lc3NhZ2UgPz8gYFRoZSB2YWx1ZSBtdXN0IG5vdCBleGNlZWQgJHtvcHRpb25zLnZhbHVlfSBjaGFyYWN0ZXJzLmAsXG4gICAgICB2YWx1ZTogdmFsdWUsXG4gICAgfTtcbiAgfVxufVxuIl19
|
@@ -1,5 +1,5 @@
|
|
1
|
-
import { isEmpty } from 'lodash-es';
|
2
1
|
import { Injectable } from '@angular/core';
|
2
|
+
import { isEmpty } from 'lodash-es';
|
3
3
|
import * as i0 from "@angular/core";
|
4
4
|
export class AXMinLengthValidationRule {
|
5
5
|
get name() {
|
@@ -10,10 +10,7 @@ export class AXMinLengthValidationRule {
|
|
10
10
|
return {
|
11
11
|
rule: this.name,
|
12
12
|
result: isValid,
|
13
|
-
message: isValid
|
14
|
-
? ''
|
15
|
-
: options?.message ??
|
16
|
-
`The value must be at least ${options.value} characters long.`,
|
13
|
+
message: isValid ? '' : options?.message ?? `The value must be at least ${options.value} characters long.`,
|
17
14
|
value: value,
|
18
15
|
};
|
19
16
|
}
|
@@ -23,4 +20,4 @@ export class AXMinLengthValidationRule {
|
|
23
20
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.2", ngImport: i0, type: AXMinLengthValidationRule, decorators: [{
|
24
21
|
type: Injectable
|
25
22
|
}] });
|
26
|
-
//# sourceMappingURL=data:application/json;base64,
|
23
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibWlubGVuZ3RoLXJ1bGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9saWJzL2NvcmUvdmFsaWRhdGlvbi9zcmMvbGliL3J1bGVzL21pbmxlbmd0a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ZTogdmFsdWUsXG4gICAgfTtcbiAgfVxufVxuIl19
|
@@ -1,6 +1,6 @@
|
|
1
|
-
import { isEmpty, isString } from 'lodash-es';
|
2
|
-
import { Injectable, inject } from '@angular/core';
|
3
1
|
import { AXTranslationService } from '@acorex/core/translation';
|
2
|
+
import { Injectable, inject } from '@angular/core';
|
3
|
+
import { isEmpty, isString } from 'lodash-es';
|
4
4
|
import * as i0 from "@angular/core";
|
5
5
|
export class AXRegexValidationRule {
|
6
6
|
constructor() {
|
@@ -11,9 +11,7 @@ export class AXRegexValidationRule {
|
|
11
11
|
}
|
12
12
|
async validate(value, options) {
|
13
13
|
// Convert string pattern to RegExp if necessary
|
14
|
-
const regexPattern = typeof options.pattern === 'string'
|
15
|
-
? new RegExp(options.pattern)
|
16
|
-
: options.pattern;
|
14
|
+
const regexPattern = typeof options.pattern === 'string' ? new RegExp(options.pattern) : options.pattern;
|
17
15
|
if (!value || (isString(value) && isEmpty(value.trim()))) {
|
18
16
|
return {
|
19
17
|
rule: this.name,
|
@@ -31,8 +29,7 @@ export class AXRegexValidationRule {
|
|
31
29
|
};
|
32
30
|
}
|
33
31
|
const isValid = regexPattern.test(value);
|
34
|
-
const translatedMessage = await this.traslationService.translateAsync(options?.message ??
|
35
|
-
`The value does not match the pattern ${regexPattern}.`, { params: { title: options?.['title'] } });
|
32
|
+
const translatedMessage = await this.traslationService.translateAsync(options?.message ?? `The value does not match the pattern ${regexPattern}.`, { params: { title: options?.['title'] } });
|
36
33
|
return {
|
37
34
|
rule: this.name,
|
38
35
|
result: isValid,
|
@@ -46,4 +43,4 @@ export class AXRegexValidationRule {
|
|
46
43
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.2", ngImport: i0, type: AXRegexValidationRule, decorators: [{
|
47
44
|
type: Injectable
|
48
45
|
}] });
|
49
|
-
//# sourceMappingURL=data:application/json;base64,
|
46
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlI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ICk7XG4gICAgcmV0dXJuIHtcbiAgICAgIHJ1bGU6IHRoaXMubmFtZSxcbiAgICAgIHJlc3VsdDogaXNWYWxpZCxcbiAgICAgIG1lc3NhZ2U6IGlzVmFsaWQgPyBudWxsIDogdHJhbnNsYXRlZE1lc3NhZ2UsXG4gICAgICB2YWx1ZTogdmFsdWUsXG4gICAgfTtcbiAgfVxufVxuIl19
|
@@ -1,6 +1,6 @@
|
|
1
|
-
import { find, isArray, isEmpty, isNull, isNumber, isString, isUndefined, } from 'lodash-es';
|
2
|
-
import { Injectable, inject } from '@angular/core';
|
3
1
|
import { AXTranslationService } from '@acorex/core/translation';
|
2
|
+
import { Injectable, inject } from '@angular/core';
|
3
|
+
import { find, isArray, isEmpty, isNull, isNumber, isString, isUndefined } from 'lodash-es';
|
4
4
|
import * as i0 from "@angular/core";
|
5
5
|
export class AXRequiredValidationRule {
|
6
6
|
constructor() {
|
@@ -18,7 +18,9 @@ export class AXRequiredValidationRule {
|
|
18
18
|
];
|
19
19
|
const failedRule = find(rules, (rule) => rule.test(value));
|
20
20
|
const isValid = !failedRule;
|
21
|
-
const translatedMessage = await this.traslationService.translateAsync('validation.messages.required', {
|
21
|
+
const translatedMessage = await this.traslationService.translateAsync('validation.messages.required', {
|
22
|
+
params: { title: options?.['title'] },
|
23
|
+
});
|
22
24
|
const message = failedRule ? options?.message ?? translatedMessage : null;
|
23
25
|
return {
|
24
26
|
rule: this.name,
|
@@ -33,4 +35,4 @@ export class AXRequiredValidationRule {
|
|
33
35
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.2", ngImport: i0, type: AXRequiredValidationRule, decorators: [{
|
34
36
|
type: Injectable
|
35
37
|
}] });
|
36
|
-
//# sourceMappingURL=data:application/json;base64,
|
38
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVxdWlyZWQtcnVsZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbI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G4gICAgY29uc3QgcnVsZXMgPSBbXG4gICAgICB7IHRlc3Q6ICh2YWwpID0+IGlzTnVsbCh2YWwpIHx8IGlzVW5kZWZpbmVkKHZhbCkgfSxcbiAgICAgIHsgdGVzdDogKHZhbCkgPT4gaXNTdHJpbmcodmFsKSAmJiBpc0VtcHR5KHZhbC50cmltKCkpIH0sXG4gICAgICB7IHRlc3Q6ICh2YWwpID0+IGlzTnVtYmVyKHZhbCkgJiYgaXNOYU4odmFsKSB9LFxuICAgICAgeyB0ZXN0OiAodmFsKSA9PiBpc0FycmF5KHZhbCkgJiYgaXNFbXB0eSh2YWwpIH0sXG4gICAgXTtcblxuICAgIGNvbnN0IGZhaWxlZFJ1bGUgPSBmaW5kKHJ1bGVzLCAocnVsZSkgPT4gcnVsZS50ZXN0KHZhbHVlKSk7XG4gICAgY29uc3QgaXNWYWxpZCA9ICFmYWlsZWRSdWxlO1xuICAgIGNvbnN0IHRyYW5zbGF0ZWRNZXNzYWdlID0gYXdhaXQgdGhpcy50cmFzbGF0aW9uU2VydmljZS50cmFuc2xhdGVBc3luYygndmFsaWRhdGlvbi5tZXNzYWdlcy5yZXF1aXJlZCcsIHtcbiAgICAgIHBhcmFtczogeyB0aXRsZTogb3B0aW9ucz8uWyd0aXRsZSddIH0sXG4gICAgfSk7XG4gICAgY29uc3QgbWVzc2FnZSA9IGZhaWxlZFJ1bGUgPyBvcHRpb25zPy5tZXNzYWdlID8/IHRyYW5zbGF0ZWRNZXNzYWdlIDogbnVsbDtcblxuICAgIHJldHVybiB7XG4gICAgICBydWxlOiB0aGlzLm5hbWUsXG4gICAgICByZXN1bHQ6IGlzVmFsaWQsXG4gICAgICBtZXNzYWdlOiBtZXNzYWdlLFxuICAgICAgdmFsdWUsXG4gICAgfTtcbiAgfVxufVxuIl19
|
@@ -30,4 +30,4 @@ export function validationConfig(config = {}) {
|
|
30
30
|
};
|
31
31
|
return result;
|
32
32
|
}
|
33
|
-
//# sourceMappingURL=data:application/json;base64,
|
33
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KFwiLitcIikpQCgoXFxbWzAtOV17MSwzfVxcLlswLTldezEsM31cXC5bMC05XXsxLDN9XFwuWzAtOV17MSwzfVxcXSl8KChbYS16QS1aXFwtMC05XStcXC4pK1thLXpBLVpdezIsfSkpJC8sXG4gICAgICAgIG1lc3NhZ2U6ICd2YWxpZGF0aW9uLm1lc3NhZ2VzLmVtYWlsJyxcbiAgICAgIH0sXG4gICAgfSxcbiAgICBwaG9uZToge1xuICAgICAgcnVsZTogJ3JlZ2V4JyxcbiAgICAgIG9wdGlvbnM6IHtcbiAgICAgICAgcGF0dGVybjogL15bK10qWyhdezAsMX1bMC05XXsxLDR9WyldezAsMX1bLVxcc1xcLi8wLTldKiQvLFxuICAgICAgICBtZXNzYWdlOiAndmFsaWRhdGlvbi5tZXNzYWdlcy5waG9uZScsXG4gICAgICB9LFxuICAgIH0sXG4gIH0sXG59O1xuXG5leHBvcnQgdHlwZSBBWFBhcnRpYWxWYWxpZGF0aW9uQ29uZmlnID0gUGFydGlhbDxBWFZhbGlkYXRpb25Db25maWc+O1xuXG5leHBvcnQgZnVuY3Rpb24gdmFsaWRhdGlvbkNvbmZpZyhjb25maWc6IEFYUGFydGlhbFZhbGlkYXRpb25Db25maWcgPSB7fSk6IEFYVmFsaWRhdGlvbkNvbmZpZyB7XG4gIGNvbnN0IHJlc3VsdCA9IHtcbiAgICAuLi5BWFZhbGlkYXRpb25EZWZhdWx0Q29uZmlnLFxuICAgIC4uLmNvbmZpZyxcbiAgfTtcbiAgcmV0dXJuIHJlc3VsdDtcbn1cbiJdfQ==
|
@@ -1,15 +1,15 @@
|
|
1
|
-
import { Inject, NgModule
|
2
|
-
import {
|
3
|
-
import { AXRegexValidationRule } from './rules/regex-rule';
|
4
|
-
import { AXRequiredValidationRule } from './rules/required-rule';
|
1
|
+
import { Inject, NgModule } from '@angular/core';
|
2
|
+
import { AXBetweenValidationRule } from './rules/between-rule';
|
5
3
|
import { AXCallbackValidationRule } from './rules/callback-rule';
|
6
|
-
import { AXMinLengthValidationRule } from './rules/minlength-rule';
|
7
|
-
import { AXMaxLengthValidationRule } from './rules/maxlength-rule';
|
8
|
-
import { AXLengthValidationRule } from './rules/length-rule';
|
9
4
|
import { AXEqualValidationRule } from './rules/equal-rule';
|
10
|
-
import { AXLessThanValidationRule } from './rules/less-than-rule';
|
11
5
|
import { AXGreaterThanValidationRule } from './rules/greater-than';
|
12
|
-
import {
|
6
|
+
import { AXLengthValidationRule } from './rules/length-rule';
|
7
|
+
import { AXLessThanValidationRule } from './rules/less-than-rule';
|
8
|
+
import { AXMaxLengthValidationRule } from './rules/maxlength-rule';
|
9
|
+
import { AXMinLengthValidationRule } from './rules/minlength-rule';
|
10
|
+
import { AXRegexValidationRule } from './rules/regex-rule';
|
11
|
+
import { AXRequiredValidationRule } from './rules/required-rule';
|
12
|
+
import { AXValidationRegistryService } from './validation.service';
|
13
13
|
import * as i0 from "@angular/core";
|
14
14
|
const BUILT_IN_RULES = [
|
15
15
|
AXRequiredValidationRule,
|
@@ -81,4 +81,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.2", ngImpor
|
|
81
81
|
type: Inject,
|
82
82
|
args: ['AXValidationModuleFactory']
|
83
83
|
}] }] });
|
84
|
-
//# sourceMappingURL=data:application/json;base64,
|
84
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidmFsaWRhdGlvbi5tb2R1bGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9saWJzL2NvcmUvdmFsaWRhdGlvbi9zcmMvbGliL3ZhbGlkYXRpb24ubW9kdWxlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxNQUFNLEVBQXVCLFFBQVEsRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUN0RSxPQUFPLEVBQUUsdUJBQXVCLEVBQUUsTUFBTSxzQkFBc0IsQ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6IEFYVmFsaWRhdGlvbk1vZHVsZSxcbiAgICAgIHByb3ZpZGVyczogW1xuICAgICAgICAuLi4oY29uZmlncz8ucnVsZXMgfHwgW10pLFxuICAgICAgICB7XG4gICAgICAgICAgcHJvdmlkZTogJ0FYVmFsaWRhdGlvbk1vZHVsZUZhY3RvcnknLFxuICAgICAgICAgIHVzZUZhY3Rvcnk6IChwbHVnaW5SZWdpc3RyeTogQVhWYWxpZGF0aW9uUmVnaXN0cnlTZXJ2aWNlKSA9PiAoKSA9PiB7XG4gICAgICAgICAgICBwbHVnaW5SZWdpc3RyeS5yZWdpc3RlciguLi5bLi4uQlVJTFRfSU5fUlVMRVMsIC4uLihjb25maWdzPy5ydWxlcyB8fCBbXSldKTtcbiAgICAgICAgICB9LFxuICAgICAgICAgIGRlcHM6IFtBWFZhbGlkYXRpb25SZWdpc3RyeVNlcnZpY2VdLFxuICAgICAgICAgIG11bHRpOiB0cnVlLFxuICAgICAgICB9LFxuICAgICAgXSxcbiAgICB9O1xuICB9XG5cbiAgLyoqXG4gICAqIEBpZ25vcmVcbiAgICovXG4gIGNvbnN0cnVjdG9yKEBJbmplY3QoJ0FYVmFsaWRhdGlvbk1vZHVsZUZhY3RvcnknKSBpbnN0YW5jZXM6IGFueVtdKSB7XG4gICAgaW5zdGFuY2VzLmZvckVhY2goKGYpID0+IHtcbiAgICAgIGYoKTtcbiAgICB9KTtcbiAgfVxufVxuIl19
|
@@ -1,7 +1,7 @@
|
|
1
|
-
import { Injectable, Injector, inject } from '@angular/core';
|
2
|
-
import { AX_VALIDATION_CONFIG, } from './validation.config';
|
3
1
|
import { AXTranslationService } from '@acorex/core/translation';
|
2
|
+
import { Injectable, Injector, inject } from '@angular/core';
|
4
3
|
import { merge } from 'lodash-es';
|
4
|
+
import { AX_VALIDATION_CONFIG } from './validation.config';
|
5
5
|
import * as i0 from "@angular/core";
|
6
6
|
import * as i1 from "@acorex/core/translation";
|
7
7
|
export class AXValidationRegistryService {
|
@@ -95,4 +95,4 @@ class AXValidationRuleChain {
|
|
95
95
|
return this.validationSummary;
|
96
96
|
}
|
97
97
|
}
|
98
|
-
//# sourceMappingURL=data:application/json;base64,
|
98
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidmFsaWRhdGlvbi5zZXJ2aWNlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vbGlicy9jb3JlL3ZhbGlkYXRpb24vc3JjL2xpYi92YWxpZGF0aW9uLnNlcnZpY2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLG9CQUFvQixFQUFFLE1BQU0sMEJBQTBCLENBQUM7QUFDaEUsT0FBTyxFQUFFLFVBQVUsRUFBRSxRQUFRLEVBQUUsTUFBTSxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBQzdELE9BQU8sRUFBRSxLQUFLLEVBQUUsTUFBTSxXQUFXLENBQUM7QUFDbEMsT0FBTyxFQUEyQixvQkFBb0IsRUFBRSxNQUFNLHFCQUFxQixDQUFDOzs7QUFZcEYsTUFBTSxPQUFPLDJCQUEyQjtJQUt0QyxJQUFXLFdBQVc7UUFDcEIsT0FBTyxJQUFJLENBQUMsT0FBTyxDQUFDLEtBQUssQ0FBQztJQUM1QixDQUFDO0lBSUQsWUFBWSxRQUFrQjtRQVZ0QixZQUFPLEdBQXVCLEVBQUUsQ0FBQztRQUVqQyxZQUFPLEdBQUcsTUFBTSxDQUFDLG9CQUFvQixDQUFDLENBQUM7UUFTN0MsSUFBSSxDQUFDLFFBQVEsR0FBRyxRQUFRLENBQUM7SUFDM0IsQ0FBQztJQUVELFFBQVEsQ0FBQyxHQUFHLE9BQXVDO1FBQ2pELE9BQU8sQ0FBQyxPQUFPLENBQUMsQ0FBQyxDQUFDLEVBQUUsRUFBRTtZQUNwQixNQUFNLGFBQWEsR0FBRyxRQUFRLENBQUMsTUFBTSxDQUFDO2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