@softpak/components 20.6.7 → 20.6.8
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.
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { input,
|
|
3
|
-
import { TranslateService } from '@ngx-translate/core';
|
|
2
|
+
import { input, signal, computed, effect, inject, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
4
3
|
import { spxTextTooLong, spxTextTooShort, spxTextTooHigh, spxTextTooLow, spxTextPatternNotValid, spxTextRequired, spxTextChoosePast, spxTextChooseFuture, spxTextChooseValidMonth, spxTextDateMayNotBeFuture, spxTextDateMayNotBePast, spxTextInvalidCode } from '@softpak/components/spx-translate';
|
|
4
|
+
import { TranslateService } from '@ngx-translate/core';
|
|
5
5
|
|
|
6
6
|
class SpxValidationMessagesComponent {
|
|
7
7
|
constructor() {
|
|
@@ -10,6 +10,41 @@ class SpxValidationMessagesComponent {
|
|
|
10
10
|
this.formControlI = input(undefined, ...(ngDevMode ? [{ debugName: "formControlI" }] : []));
|
|
11
11
|
this.fieldLabel = input(undefined, ...(ngDevMode ? [{ debugName: "fieldLabel" }] : []));
|
|
12
12
|
this.submitTried = input(undefined, ...(ngDevMode ? [{ debugName: "submitTried" }] : []));
|
|
13
|
+
this.show = signal(false, ...(ngDevMode ? [{ debugName: "show" }] : []));
|
|
14
|
+
this.shouldShow = computed(() => this.formControlI() && this.errors() && (this.touched() || this.submitTried()), ...(ngDevMode ? [{ debugName: "shouldShow" }] : []));
|
|
15
|
+
this.pending = null;
|
|
16
|
+
this.token = 0;
|
|
17
|
+
// Short delay to avoid growing DOM while clicking on something.
|
|
18
|
+
this._delayShow = effect(() => {
|
|
19
|
+
const want = this.shouldShow();
|
|
20
|
+
// Invalidate any older timeouts.
|
|
21
|
+
this.token++;
|
|
22
|
+
// Cancel any in-flight timeout.
|
|
23
|
+
if (this.pending) {
|
|
24
|
+
clearTimeout(this.pending);
|
|
25
|
+
this.pending = null;
|
|
26
|
+
}
|
|
27
|
+
if (want) {
|
|
28
|
+
const myToken = this.token;
|
|
29
|
+
this.pending = setTimeout(() => {
|
|
30
|
+
// Only set true if no newer change happened AND the condition still holds.
|
|
31
|
+
if (myToken === this.token && this.shouldShow()) {
|
|
32
|
+
this.show.set(true);
|
|
33
|
+
}
|
|
34
|
+
}, 500); // your delay
|
|
35
|
+
}
|
|
36
|
+
else {
|
|
37
|
+
// Turn off immediately.
|
|
38
|
+
this.show.set(false);
|
|
39
|
+
}
|
|
40
|
+
// Clean up if the effect is torn down.
|
|
41
|
+
onCleanup(() => {
|
|
42
|
+
if (this.pending) {
|
|
43
|
+
clearTimeout(this.pending);
|
|
44
|
+
this.pending = null;
|
|
45
|
+
}
|
|
46
|
+
});
|
|
47
|
+
}, ...(ngDevMode ? [{ debugName: "_delayShow" }] : []));
|
|
13
48
|
this.translateService = inject(TranslateService);
|
|
14
49
|
this.textTooLong = computed(() => {
|
|
15
50
|
return this.translateService.instant(spxTextTooLong, { fieldLabel: this.fieldLabel(), error: this.errors()["maxlength"].requiredLength });
|
|
@@ -49,12 +84,15 @@ class SpxValidationMessagesComponent {
|
|
|
49
84
|
}, ...(ngDevMode ? [{ debugName: "textInvalidCode" }] : []));
|
|
50
85
|
}
|
|
51
86
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: SpxValidationMessagesComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
52
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.2", type: SpxValidationMessagesComponent, isStandalone: true, selector: "spx-validation-messages", inputs: { errors: { classPropertyName: "errors", publicName: "errors", isSignal: true, isRequired: true, transformFunction: null }, touched: { classPropertyName: "touched", publicName: "touched", isSignal: true, isRequired: true, transformFunction: null }, formControlI: { classPropertyName: "formControlI", publicName: "formControlI", isSignal: true, isRequired: false, transformFunction: null }, fieldLabel: { classPropertyName: "fieldLabel", publicName: "fieldLabel", isSignal: true, isRequired: false, transformFunction: null }, submitTried: { classPropertyName: "submitTried", publicName: "submitTried", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "\n@if (
|
|
87
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.2", type: SpxValidationMessagesComponent, isStandalone: true, selector: "spx-validation-messages", inputs: { errors: { classPropertyName: "errors", publicName: "errors", isSignal: true, isRequired: true, transformFunction: null }, touched: { classPropertyName: "touched", publicName: "touched", isSignal: true, isRequired: true, transformFunction: null }, formControlI: { classPropertyName: "formControlI", publicName: "formControlI", isSignal: true, isRequired: false, transformFunction: null }, fieldLabel: { classPropertyName: "fieldLabel", publicName: "fieldLabel", isSignal: true, isRequired: false, transformFunction: null }, submitTried: { classPropertyName: "submitTried", publicName: "submitTried", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "\n@if (show()) {\n @if (errors()[\"maxlength\"]) {\n <div>{{ textTooLong() }}</div>\n }\n @if (errors()[\"minlength\"]) {\n <div>{{ textTooShort() }}</div>\n }\n @if (errors()[\"max\"]) {\n <div>{{ textTooHigh() }}</div>\n }\n @if (errors()[\"min\"]) {\n <div>{{ textTooLow() }}</div>\n }\n @if (errors()[\"pattern\"]) {\n <div>{{ textPatternNotValid() }}</div>\n }\n @if (errors()[\"required\"]) {\n <div>{{ textRequired() }}</div>\n }\n @if (errors()[\"year\"]) {\n <div>{{ textChoosePast() }}</div>\n }\n @if (errors()[\"yearFuture\"]) {\n <div>{{ textChooseFuture() }}</div>\n }\n @if (errors()[\"month\"]) {\n <div>{{ textChooseValidMonth() }}</div>\n }\n @if (errors()[\"future\"]) {\n <div>{{ textDateMayNotBeFuture() }}</div>\n }\n @if (errors()[\"past\"]) {\n <div>{{ textDateMayNotBePast() }}</div>\n }\n @if (errors()[\"invalidCode\"]) {\n <div>{{ textInvalidCode() }}</div>\n }\n}", styles: [":host{display:block}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
53
88
|
}
|
|
54
89
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: SpxValidationMessagesComponent, decorators: [{
|
|
55
90
|
type: Component,
|
|
56
|
-
args: [{ selector: 'spx-validation-messages', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, template: "\n@if (
|
|
91
|
+
args: [{ selector: 'spx-validation-messages', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, template: "\n@if (show()) {\n @if (errors()[\"maxlength\"]) {\n <div>{{ textTooLong() }}</div>\n }\n @if (errors()[\"minlength\"]) {\n <div>{{ textTooShort() }}</div>\n }\n @if (errors()[\"max\"]) {\n <div>{{ textTooHigh() }}</div>\n }\n @if (errors()[\"min\"]) {\n <div>{{ textTooLow() }}</div>\n }\n @if (errors()[\"pattern\"]) {\n <div>{{ textPatternNotValid() }}</div>\n }\n @if (errors()[\"required\"]) {\n <div>{{ textRequired() }}</div>\n }\n @if (errors()[\"year\"]) {\n <div>{{ textChoosePast() }}</div>\n }\n @if (errors()[\"yearFuture\"]) {\n <div>{{ textChooseFuture() }}</div>\n }\n @if (errors()[\"month\"]) {\n <div>{{ textChooseValidMonth() }}</div>\n }\n @if (errors()[\"future\"]) {\n <div>{{ textDateMayNotBeFuture() }}</div>\n }\n @if (errors()[\"past\"]) {\n <div>{{ textDateMayNotBePast() }}</div>\n }\n @if (errors()[\"invalidCode\"]) {\n <div>{{ textInvalidCode() }}</div>\n }\n}", styles: [":host{display:block}\n"] }]
|
|
57
92
|
}] });
|
|
93
|
+
function onCleanup(arg0) {
|
|
94
|
+
throw new Error('Function not implemented.');
|
|
95
|
+
}
|
|
58
96
|
|
|
59
97
|
/**
|
|
60
98
|
* Generated bundle index. Do not edit.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"softpak-components-spx-validation-messages.mjs","sources":["../../../../projects/softpak/components/spx-validation-messages/spx-validation-messages.component.ts","../../../../projects/softpak/components/spx-validation-messages/spx-validation-messages.component.html","../../../../projects/softpak/components/spx-validation-messages/softpak-components-spx-validation-messages.ts"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"softpak-components-spx-validation-messages.mjs","sources":["../../../../projects/softpak/components/spx-validation-messages/spx-validation-messages.component.ts","../../../../projects/softpak/components/spx-validation-messages/spx-validation-messages.component.html","../../../../projects/softpak/components/spx-validation-messages/softpak-components-spx-validation-messages.ts"],"sourcesContent":["import { AbstractControl, ValidationErrors } from '@angular/forms';\nimport { ChangeDetectionStrategy, Component, computed, effect, inject, input, signal } from '@angular/core';\nimport { spxTextChooseFuture, spxTextChoosePast, spxTextChooseValidMonth, spxTextDateMayNotBeFuture, spxTextDateMayNotBePast, spxTextInvalidCode, spxTextPatternNotValid, spxTextRequired, spxTextTooHigh, spxTextTooLong, spxTextTooLow, spxTextTooShort } from '@softpak/components/spx-translate';\n\nimport { TranslateService } from '@ngx-translate/core';\n\n@Component({\n selector: 'spx-validation-messages',\n standalone: true,\n templateUrl: './spx-validation-messages.component.html',\n styleUrl: './spx-validation-messages.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class SpxValidationMessagesComponent {\n protected readonly errors = input.required<ValidationErrors>();\n protected readonly touched = input.required<boolean>();\n protected readonly formControlI = input<AbstractControl<any, any> | undefined>(undefined);\n protected readonly fieldLabel = input<string | undefined>(undefined);\n protected readonly submitTried = input<boolean | undefined>(undefined);\n protected readonly show = signal(false);\n private readonly shouldShow = computed(() => this.formControlI() && this.errors() && (this.touched() || this.submitTried()));\n\n private pending: ReturnType<typeof setTimeout> | null = null;\n private token = 0;\n\n // Short delay to avoid growing DOM while clicking on something.\n private _delayShow = effect(() => {\n const want = this.shouldShow();\n\n // Invalidate any older timeouts.\n this.token++;\n\n // Cancel any in-flight timeout.\n if (this.pending) {\n clearTimeout(this.pending);\n this.pending = null;\n }\n\n if (want) {\n const myToken = this.token;\n this.pending = setTimeout(() => {\n // Only set true if no newer change happened AND the condition still holds.\n if (myToken === this.token && this.shouldShow()) {\n this.show.set(true);\n }\n }, 500); // your delay\n } else {\n // Turn off immediately.\n this.show.set(false);\n }\n\n // Clean up if the effect is torn down.\n onCleanup(() => {\n if (this.pending) {\n clearTimeout(this.pending);\n this.pending = null;\n }\n });\n });\n\n translateService = inject(TranslateService);\n\n textTooLong = computed(() => {\n return this.translateService.instant(spxTextTooLong, { fieldLabel: this.fieldLabel(), error: this.errors()[\"maxlength\"].requiredLength });\n });\n\n textTooShort = computed(() => {\n return this.translateService.instant(spxTextTooShort, { fieldLabel: this.fieldLabel(), error: this.errors()[\"minlength\"].requiredLength });\n });\n\n textTooHigh = computed(() => {\n return this.translateService.instant(spxTextTooHigh, { fieldLabel: this.fieldLabel(), error: this.errors()[\"max\"].max });\n });\n\n textTooLow = computed(() => {\n return this.translateService.instant(spxTextTooLow, { fieldLabel: this.fieldLabel(), error: this.errors()[\"min\"].min });\n });\n\n textPatternNotValid = computed(() => {\n return this.translateService.instant(spxTextPatternNotValid, { fieldLabel: this.fieldLabel() });\n });\n\n textRequired = computed(() => {\n return this.translateService.instant(spxTextRequired, { fieldLabel: this.fieldLabel() });\n });\n\n textChoosePast = computed(() => {\n return this.translateService.instant(spxTextChoosePast);\n });\n\n textChooseFuture = computed(() => {\n return this.translateService.instant(spxTextChooseFuture);\n });\n\n textChooseValidMonth = computed(() => {\n return this.translateService.instant(spxTextChooseValidMonth);\n });\n\n textDateMayNotBeFuture = computed(() => {\n return this.translateService.instant(spxTextDateMayNotBeFuture);\n });\n\n textDateMayNotBePast = computed(() => {\n return this.translateService.instant(spxTextDateMayNotBePast);\n });\n\n textInvalidCode = computed(() => {\n return this.translateService.instant(spxTextInvalidCode, { codeName: this.errors()[\"invalidCode\"].name, codeCode: this.errors()[\"invalidCode\"].code });\n });\n\n}\nfunction onCleanup(arg0: () => void) {\n throw new Error('Function not implemented.');\n}\n\n","\n@if (show()) {\n @if (errors()[\"maxlength\"]) {\n <div>{{ textTooLong() }}</div>\n }\n @if (errors()[\"minlength\"]) {\n <div>{{ textTooShort() }}</div>\n }\n @if (errors()[\"max\"]) {\n <div>{{ textTooHigh() }}</div>\n }\n @if (errors()[\"min\"]) {\n <div>{{ textTooLow() }}</div>\n }\n @if (errors()[\"pattern\"]) {\n <div>{{ textPatternNotValid() }}</div>\n }\n @if (errors()[\"required\"]) {\n <div>{{ textRequired() }}</div>\n }\n @if (errors()[\"year\"]) {\n <div>{{ textChoosePast() }}</div>\n }\n @if (errors()[\"yearFuture\"]) {\n <div>{{ textChooseFuture() }}</div>\n }\n @if (errors()[\"month\"]) {\n <div>{{ textChooseValidMonth() }}</div>\n }\n @if (errors()[\"future\"]) {\n <div>{{ textDateMayNotBeFuture() }}</div>\n }\n @if (errors()[\"past\"]) {\n <div>{{ textDateMayNotBePast() }}</div>\n }\n @if (errors()[\"invalidCode\"]) {\n <div>{{ textInvalidCode() }}</div>\n }\n}","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;MAaa,8BAA8B,CAAA;AAP3C,IAAA,WAAA,GAAA;AAQqB,QAAA,IAAA,CAAA,MAAM,GAAG,KAAK,CAAC,QAAQ,iDAAoB;AAC3C,QAAA,IAAA,CAAA,OAAO,GAAG,KAAK,CAAC,QAAQ,kDAAW;AACnC,QAAA,IAAA,CAAA,YAAY,GAAG,KAAK,CAAwC,SAAS,wDAAC;AACtE,QAAA,IAAA,CAAA,UAAU,GAAG,KAAK,CAAqB,SAAS,sDAAC;AACjD,QAAA,IAAA,CAAA,WAAW,GAAG,KAAK,CAAsB,SAAS,uDAAC;AACnD,QAAA,IAAA,CAAA,IAAI,GAAG,MAAM,CAAC,KAAK,gDAAC;AACtB,QAAA,IAAA,CAAA,UAAU,GAAG,QAAQ,CAAC,MAAM,IAAI,CAAC,YAAY,EAAE,IAAI,IAAI,CAAC,MAAM,EAAE,KAAK,IAAI,CAAC,OAAO,EAAE,IAAI,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EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAA9B,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,8BAA8B,ovBCb3C,07BAsCC,EAAA,MAAA,EAAA,CAAA,wBAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA;;2FDzBY,8BAA8B,EAAA,UAAA,EAAA,CAAA;kBAP1C,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,yBAAyB,EAAA,UAAA,EACvB,IAAI,EAAA,eAAA,EAGC,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,07BAAA,EAAA,MAAA,EAAA,CAAA,wBAAA,CAAA,EAAA;;AAoGjD,SAAS,SAAS,CAAC,IAAgB,EAAA;AACjC,IAAA,MAAM,IAAI,KAAK,CAAC,2BAA2B,CAAC;AAC9C;;AEjHA;;AAEG;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@softpak/components",
|
|
3
|
-
"version": "20.6.
|
|
3
|
+
"version": "20.6.8",
|
|
4
4
|
"private": false,
|
|
5
5
|
"peerDependencies": {
|
|
6
6
|
"@angular/common": "20.x.x",
|
|
@@ -32,17 +32,13 @@
|
|
|
32
32
|
"types": "./index.d.ts",
|
|
33
33
|
"default": "./fesm2022/softpak-components.mjs"
|
|
34
34
|
},
|
|
35
|
-
"./spx-alert": {
|
|
36
|
-
"types": "./spx-alert/index.d.ts",
|
|
37
|
-
"default": "./fesm2022/softpak-components-spx-alert.mjs"
|
|
38
|
-
},
|
|
39
35
|
"./spx-404-page": {
|
|
40
36
|
"types": "./spx-404-page/index.d.ts",
|
|
41
37
|
"default": "./fesm2022/softpak-components-spx-404-page.mjs"
|
|
42
38
|
},
|
|
43
|
-
"./spx-
|
|
44
|
-
"types": "./spx-
|
|
45
|
-
"default": "./fesm2022/softpak-components-spx-
|
|
39
|
+
"./spx-alert": {
|
|
40
|
+
"types": "./spx-alert/index.d.ts",
|
|
41
|
+
"default": "./fesm2022/softpak-components-spx-alert.mjs"
|
|
46
42
|
},
|
|
47
43
|
"./spx-app-expiry": {
|
|
48
44
|
"types": "./spx-app-expiry/index.d.ts",
|
|
@@ -52,18 +48,22 @@
|
|
|
52
48
|
"types": "./spx-button/index.d.ts",
|
|
53
49
|
"default": "./fesm2022/softpak-components-spx-button.mjs"
|
|
54
50
|
},
|
|
55
|
-
"./spx-capitalize": {
|
|
56
|
-
"types": "./spx-capitalize/index.d.ts",
|
|
57
|
-
"default": "./fesm2022/softpak-components-spx-capitalize.mjs"
|
|
58
|
-
},
|
|
59
51
|
"./spx-card": {
|
|
60
52
|
"types": "./spx-card/index.d.ts",
|
|
61
53
|
"default": "./fesm2022/softpak-components-spx-card.mjs"
|
|
62
54
|
},
|
|
55
|
+
"./spx-app-configuration": {
|
|
56
|
+
"types": "./spx-app-configuration/index.d.ts",
|
|
57
|
+
"default": "./fesm2022/softpak-components-spx-app-configuration.mjs"
|
|
58
|
+
},
|
|
63
59
|
"./spx-change-details": {
|
|
64
60
|
"types": "./spx-change-details/index.d.ts",
|
|
65
61
|
"default": "./fesm2022/softpak-components-spx-change-details.mjs"
|
|
66
62
|
},
|
|
63
|
+
"./spx-capitalize": {
|
|
64
|
+
"types": "./spx-capitalize/index.d.ts",
|
|
65
|
+
"default": "./fesm2022/softpak-components-spx-capitalize.mjs"
|
|
66
|
+
},
|
|
67
67
|
"./spx-channel-selection": {
|
|
68
68
|
"types": "./spx-channel-selection/index.d.ts",
|
|
69
69
|
"default": "./fesm2022/softpak-components-spx-channel-selection.mjs"
|
|
@@ -80,14 +80,14 @@
|
|
|
80
80
|
"types": "./spx-form-section/index.d.ts",
|
|
81
81
|
"default": "./fesm2022/softpak-components-spx-form-section.mjs"
|
|
82
82
|
},
|
|
83
|
-
"./spx-form-view": {
|
|
84
|
-
"types": "./spx-form-view/index.d.ts",
|
|
85
|
-
"default": "./fesm2022/softpak-components-spx-form-view.mjs"
|
|
86
|
-
},
|
|
87
83
|
"./spx-helpers": {
|
|
88
84
|
"types": "./spx-helpers/index.d.ts",
|
|
89
85
|
"default": "./fesm2022/softpak-components-spx-helpers.mjs"
|
|
90
86
|
},
|
|
87
|
+
"./spx-form-view": {
|
|
88
|
+
"types": "./spx-form-view/index.d.ts",
|
|
89
|
+
"default": "./fesm2022/softpak-components-spx-form-view.mjs"
|
|
90
|
+
},
|
|
91
91
|
"./spx-inputs": {
|
|
92
92
|
"types": "./spx-inputs/index.d.ts",
|
|
93
93
|
"default": "./fesm2022/softpak-components-spx-inputs.mjs"
|
|
@@ -108,22 +108,22 @@
|
|
|
108
108
|
"types": "./spx-patch/index.d.ts",
|
|
109
109
|
"default": "./fesm2022/softpak-components-spx-patch.mjs"
|
|
110
110
|
},
|
|
111
|
-
"./spx-progress-bar": {
|
|
112
|
-
"types": "./spx-progress-bar/index.d.ts",
|
|
113
|
-
"default": "./fesm2022/softpak-components-spx-progress-bar.mjs"
|
|
114
|
-
},
|
|
115
111
|
"./spx-pipes": {
|
|
116
112
|
"types": "./spx-pipes/index.d.ts",
|
|
117
113
|
"default": "./fesm2022/softpak-components-spx-pipes.mjs"
|
|
118
114
|
},
|
|
119
|
-
"./spx-stock-info": {
|
|
120
|
-
"types": "./spx-stock-info/index.d.ts",
|
|
121
|
-
"default": "./fesm2022/softpak-components-spx-stock-info.mjs"
|
|
122
|
-
},
|
|
123
115
|
"./spx-spinner": {
|
|
124
116
|
"types": "./spx-spinner/index.d.ts",
|
|
125
117
|
"default": "./fesm2022/softpak-components-spx-spinner.mjs"
|
|
126
118
|
},
|
|
119
|
+
"./spx-progress-bar": {
|
|
120
|
+
"types": "./spx-progress-bar/index.d.ts",
|
|
121
|
+
"default": "./fesm2022/softpak-components-spx-progress-bar.mjs"
|
|
122
|
+
},
|
|
123
|
+
"./spx-stock-info": {
|
|
124
|
+
"types": "./spx-stock-info/index.d.ts",
|
|
125
|
+
"default": "./fesm2022/softpak-components-spx-stock-info.mjs"
|
|
126
|
+
},
|
|
127
127
|
"./spx-storage": {
|
|
128
128
|
"types": "./spx-storage/index.d.ts",
|
|
129
129
|
"default": "./fesm2022/softpak-components-spx-storage.mjs"
|
|
@@ -132,14 +132,14 @@
|
|
|
132
132
|
"types": "./spx-suggestion/index.d.ts",
|
|
133
133
|
"default": "./fesm2022/softpak-components-spx-suggestion.mjs"
|
|
134
134
|
},
|
|
135
|
-
"./spx-tabs": {
|
|
136
|
-
"types": "./spx-tabs/index.d.ts",
|
|
137
|
-
"default": "./fesm2022/softpak-components-spx-tabs.mjs"
|
|
138
|
-
},
|
|
139
135
|
"./spx-toggle": {
|
|
140
136
|
"types": "./spx-toggle/index.d.ts",
|
|
141
137
|
"default": "./fesm2022/softpak-components-spx-toggle.mjs"
|
|
142
138
|
},
|
|
139
|
+
"./spx-tabs": {
|
|
140
|
+
"types": "./spx-tabs/index.d.ts",
|
|
141
|
+
"default": "./fesm2022/softpak-components-spx-tabs.mjs"
|
|
142
|
+
},
|
|
143
143
|
"./spx-toaster": {
|
|
144
144
|
"types": "./spx-toaster/index.d.ts",
|
|
145
145
|
"default": "./fesm2022/softpak-components-spx-toaster.mjs"
|
|
@@ -148,14 +148,14 @@
|
|
|
148
148
|
"types": "./spx-translate/index.d.ts",
|
|
149
149
|
"default": "./fesm2022/softpak-components-spx-translate.mjs"
|
|
150
150
|
},
|
|
151
|
-
"./spx-validation": {
|
|
152
|
-
"types": "./spx-validation/index.d.ts",
|
|
153
|
-
"default": "./fesm2022/softpak-components-spx-validation.mjs"
|
|
154
|
-
},
|
|
155
151
|
"./spx-update": {
|
|
156
152
|
"types": "./spx-update/index.d.ts",
|
|
157
153
|
"default": "./fesm2022/softpak-components-spx-update.mjs"
|
|
158
154
|
},
|
|
155
|
+
"./spx-validation": {
|
|
156
|
+
"types": "./spx-validation/index.d.ts",
|
|
157
|
+
"default": "./fesm2022/softpak-components-spx-validation.mjs"
|
|
158
|
+
},
|
|
159
159
|
"./spx-validation-messages": {
|
|
160
160
|
"types": "./spx-validation-messages/index.d.ts",
|
|
161
161
|
"default": "./fesm2022/softpak-components-spx-validation-messages.mjs"
|
|
@@ -3,11 +3,16 @@ import { ValidationErrors, AbstractControl } from '@angular/forms';
|
|
|
3
3
|
import { TranslateService } from '@ngx-translate/core';
|
|
4
4
|
|
|
5
5
|
declare class SpxValidationMessagesComponent {
|
|
6
|
-
readonly errors: _angular_core.InputSignal<ValidationErrors>;
|
|
7
|
-
readonly touched: _angular_core.InputSignal<boolean>;
|
|
8
|
-
readonly formControlI: _angular_core.InputSignal<AbstractControl<any, any, any> | undefined>;
|
|
9
|
-
readonly fieldLabel: _angular_core.InputSignal<string | undefined>;
|
|
10
|
-
readonly submitTried: _angular_core.InputSignal<boolean | undefined>;
|
|
6
|
+
protected readonly errors: _angular_core.InputSignal<ValidationErrors>;
|
|
7
|
+
protected readonly touched: _angular_core.InputSignal<boolean>;
|
|
8
|
+
protected readonly formControlI: _angular_core.InputSignal<AbstractControl<any, any, any> | undefined>;
|
|
9
|
+
protected readonly fieldLabel: _angular_core.InputSignal<string | undefined>;
|
|
10
|
+
protected readonly submitTried: _angular_core.InputSignal<boolean | undefined>;
|
|
11
|
+
protected readonly show: _angular_core.WritableSignal<boolean>;
|
|
12
|
+
private readonly shouldShow;
|
|
13
|
+
private pending;
|
|
14
|
+
private token;
|
|
15
|
+
private _delayShow;
|
|
11
16
|
translateService: TranslateService;
|
|
12
17
|
textTooLong: _angular_core.Signal<any>;
|
|
13
18
|
textTooShort: _angular_core.Signal<any>;
|