@softpak/components 19.24.0 → 19.25.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/fesm2022/softpak-components-spx-change-details.mjs +8 -6
- package/fesm2022/softpak-components-spx-change-details.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-tabs.mjs +18 -6
- package/fesm2022/softpak-components-spx-tabs.mjs.map +1 -1
- package/fesm2022/softpak-components-spx-validation-messages.mjs +25 -0
- package/fesm2022/softpak-components-spx-validation-messages.mjs.map +1 -0
- package/package.json +28 -24
- package/spx-tabs/public-api.d.ts +2 -0
- package/spx-tabs/src/spx-tabs.component.d.ts +2 -1
- package/spx-validation-messages/index.d.ts +5 -0
- package/spx-validation-messages/public-api.d.ts +1 -0
- package/spx-validation-messages/spx-validation-messages.component.d.ts +11 -0
|
@@ -138,12 +138,14 @@ class SpxChangeDetailsComponent {
|
|
|
138
138
|
return formControl._rawValidators;
|
|
139
139
|
}
|
|
140
140
|
onBlur(data) {
|
|
141
|
-
|
|
142
|
-
this.
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
this.
|
|
146
|
-
|
|
141
|
+
setTimeout(() => {
|
|
142
|
+
if (data.field.key === spxCtrlCategory && valuePairToValue(this.formGroup().get(spxCtrlCategory).value) !== null) {
|
|
143
|
+
this.spxBlurCategory.emit(data.valuePair);
|
|
144
|
+
}
|
|
145
|
+
if (data.field.key === spxCtrlContainerType && valuePairToValue(this.formGroup().get(spxCtrlContainerType).value) !== null) {
|
|
146
|
+
this.spxBlurContainerType.emit(data.valuePair);
|
|
147
|
+
}
|
|
148
|
+
}, 300);
|
|
147
149
|
}
|
|
148
150
|
onSearch(data) {
|
|
149
151
|
if (data.field.key === spxCtrlCategory) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"softpak-components-spx-change-details.mjs","sources":["../../../../projects/softpak/components/spx-change-details/spx-change-details.component.ts","../../../../projects/softpak/components/spx-change-details/spx-change-details.component.html","../../../../projects/softpak/components/spx-change-details/softpak-components-spx-change-details.ts"],"sourcesContent":["import { ChangeDetectionStrategy, computed, effect, input, output } from '@angular/core';\r\nimport { Component } from '@angular/core';\r\nimport {\r\n FormBuilder,\r\n FormControl,\r\n FormGroup,\r\n FormsModule,\r\n ReactiveFormsModule,\r\n} from '@angular/forms';\r\nimport { Subscription } from 'rxjs';\r\nimport { SpxChangeDetailsValueI } from './spx-change-details-value.interface';\r\nimport { SpxFormViewComponent, SpxFormI, SpxFormButtonTypeEnum, SpxFormFieldI } from '@softpak/components/spx-form-view';\r\nimport { SpxSeverityEnum, valuePairToValue } from '@softpak/components/spx-helpers';\r\nimport { SpxValuePair, SpxInputTypeEnum } from '@softpak/components/spx-inputs';\r\nimport { spxValidatorRequired } from '@softpak/components/spx-validation';\r\n\r\nexport const spxSectionChangeDetails = 'changeDetails';\r\nexport const spxCtrlContainerNumber = 'containerNumber';\r\nexport const spxCtrlContainerSeqNr = 'containerSeqNr';\r\nexport const spxCtrlContainerType = 'containerType';\r\nexport const spxCtrlCustomer = 'customer';\r\nexport const spxCtrlTonsTested = 'tonsTested';\r\nexport const spxCtrlLicensePlate = 'licensePlate';\r\nexport const spxCtrlCategory = 'category';\r\nexport const spxCtrlUseCategories = 'useCategories';\r\n\r\n@Component({\r\n selector: 'spx-change-details',\r\n templateUrl: './spx-change-details.component.html',\r\n imports: [\r\n FormsModule,\r\n ReactiveFormsModule,\r\n SpxFormViewComponent,\r\n ],\r\n standalone: true,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n})\r\nexport class SpxChangeDetailsComponent {\r\n readonly formGroup = input<FormGroup>();\r\n readonly suggestions = input<any>();\r\n private readonly showTonsTested = computed(() =>\r\n this.suggestions()?.[spxCtrlTonsTested] &&\r\n this.suggestions()?.[spxCtrlTonsTested].length &&\r\n this.suggestions()?.[spxCtrlTonsTested].length > 0\r\n );\r\n readonly textCategory = input<string>();\r\n readonly textContainerNumber = input<string>();\r\n readonly textContainerType = input<string>();\r\n readonly textCustomer = input<string>();\r\n readonly textLicensePlate = input<string>();\r\n readonly textSave = input<string>();\r\n readonly textTonsTested = input<string>();\r\n spxBlurCategory = output<SpxValuePair<string>>();\r\n spxBlurContainerType = output<SpxValuePair<string>>();\r\n spxSearchCategory = output<SpxValuePair<string>>();\r\n spxSearchContainerType = output<SpxValuePair<string>>();\r\n spxSearchTonsTested = output<SpxValuePair<string>>();\r\n submit = output<SpxChangeDetailsValueI>();\r\n\r\n form: SpxFormI = {\r\n buttons: [\r\n {\r\n severity: SpxSeverityEnum.success,\r\n type: SpxFormButtonTypeEnum.submit,\r\n label: () => this.textSave()!,\r\n }\r\n ],\r\n sections: [\r\n {\r\n key: spxSectionChangeDetails,\r\n showTitle: () => false,\r\n fields: [\r\n {\r\n key: spxCtrlContainerSeqNr,\r\n type: () => SpxInputTypeEnum.hidden,\r\n validators: () => [spxValidatorRequired()],\r\n },\r\n {\r\n key: spxCtrlContainerNumber,\r\n type: () => SpxInputTypeEnum.text,\r\n label: () => this.textContainerNumber()!,\r\n readonly: () => true,\r\n validators: () => [spxValidatorRequired()],\r\n },\r\n {\r\n key: spxCtrlCustomer,\r\n type: () => SpxInputTypeEnum.text,\r\n capitalize: () => true,\r\n readonly: () => true,\r\n label: () => this.textCustomer()!,\r\n validators: () => [spxValidatorRequired()],\r\n },\r\n {\r\n key: spxCtrlContainerType,\r\n type: () => SpxInputTypeEnum.autocomplete,\r\n label: () => this.textContainerType()!,\r\n capitalize: () => true,\r\n validators: () => [spxValidatorRequired()],\r\n },\r\n {\r\n key: spxCtrlTonsTested,\r\n type: () => SpxInputTypeEnum.radio,\r\n label: () => this.textTonsTested()!,\r\n show: () => this.showTonsTested(),\r\n },\r\n {\r\n key: spxCtrlLicensePlate,\r\n type: () => SpxInputTypeEnum.text,\r\n label: () => this.textLicensePlate()!,\r\n capitalize: () => true,\r\n },\r\n {\r\n key: spxCtrlUseCategories,\r\n type: () => SpxInputTypeEnum.hidden,\r\n capitalize: () => true,\r\n },\r\n {\r\n key: spxCtrlCategory,\r\n type: () => SpxInputTypeEnum.autocomplete,\r\n label: () => this.textCategory()!,\r\n capitalize: () => true,\r\n show: () => valuePairToValue(this.ctrlUseCategories()?.value),\r\n validators: () => valuePairToValue(this.ctrlUseCategories()?.value) ? [spxValidatorRequired()] : [],\r\n }\r\n ]\r\n }\r\n ]\r\n };\r\n\r\n readonly ctrlCategory = computed(() => this.formGroup()?.get(spxCtrlCategory) as FormControl);\r\n readonly ctrlCustomer = computed(() => this.formGroup()?.get(spxCtrlCustomer) as FormControl);\r\n readonly ctrlContainerType = computed(() => this.formGroup()?.get(spxCtrlContainerType) as FormControl);\r\n readonly ctrlLicensePlate = computed(() => this.formGroup()?.get(spxCtrlLicensePlate) as FormControl);\r\n readonly ctrlTonsTested = computed(() => this.formGroup()?.get(spxCtrlTonsTested) as FormControl);\r\n readonly ctrlUseCategories = computed(() => this.formGroup()?.get(spxCtrlUseCategories) as FormControl);\r\n\r\n private subContainerType?: Subscription;\r\n\r\n constructor(readonly formBuilder: FormBuilder) {\r\n effect(() => {\r\n if (\r\n this.showTonsTested()\r\n ) {\r\n this.ctrlTonsTested()?.addValidators([spxValidatorRequired()]);\r\n this.ctrlTonsTested()?.updateValueAndValidity();\r\n } else {\r\n this.ctrlTonsTested()?.clearValidators();\r\n this.ctrlTonsTested()?.updateValueAndValidity();\r\n }\r\n });\r\n }\r\n\r\n createForm(): FormGroup {\r\n return SpxFormViewComponent.createForm(\r\n this.formBuilder,\r\n this.form.sections\r\n );\r\n }\r\n\r\n ngOnInit(): void {\r\n this.listenToContainerType();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n if (this.subContainerType) {\r\n this.subContainerType.unsubscribe();\r\n }\r\n }\r\n\r\n getRawValidators(formControl: FormControl) {\r\n return (formControl as any)._rawValidators;\r\n }\r\n\r\n onBlur(data: { field: SpxFormFieldI; valuePair: SpxValuePair<any> }) {\r\n if (data.field.key === spxCtrlCategory) {\r\n this.spxBlurCategory.emit(data.valuePair);\r\n }\r\n if (data.field.key === spxCtrlContainerType) {\r\n this.spxBlurContainerType.emit(data.valuePair);\r\n }\r\n }\r\n\r\n onSearch(data: { field: SpxFormFieldI; valuePair: SpxValuePair<any> }) {\r\n if (data.field.key === spxCtrlCategory) {\r\n this.spxSearchCategory.emit(data.valuePair);\r\n }\r\n if (data.field.key === spxCtrlContainerType) {\r\n this.spxSearchContainerType.emit(data.valuePair);\r\n }\r\n if (data.field.key === spxCtrlTonsTested) {\r\n this.spxSearchTonsTested.emit(data.valuePair);\r\n }\r\n }\r\n\r\n onSubmit(): void {\r\n this.submit.emit({\r\n category: valuePairToValue(this.ctrlUseCategories().value) ? this.ctrlCategory().value : null,\r\n containerType: this.ctrlContainerType().value,\r\n licensePlate: this.ctrlLicensePlate().value,\r\n tonsTested: this.ctrlTonsTested().value,\r\n })\r\n }\r\n\r\n private listenToContainerType(): void {\r\n this.subContainerType = this.ctrlContainerType().valueChanges.subscribe(valuePair => {\r\n this.ctrlTonsTested().setValue({ value: null });\r\n this.spxSearchTonsTested.emit(valuePair);\r\n });\r\n }\r\n}\r\n","<form [formGroup]=\"formGroup()!\" class=\"max-w-lg mx-auto flex flex-col gap-3\" (ngSubmit)=\"onSubmit()\">\r\n <spx-form-view\r\n [spxFormGroup]=\"formGroup()!\"\r\n [spxForm]=\"form\"\r\n [spxSuggestions]=\"suggestions()\"\r\n (spxBlur)=\"onBlur($event)\"\r\n (spxSearch)=\"onSearch($event)\">\r\n </spx-form-view>\r\n</form>","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;AAgBO,MAAM,uBAAuB,GAAG;AAChC,MAAM,sBAAsB,GAAG;AAC/B,MAAM,qBAAqB,GAAG;AAC9B,MAAM,oBAAoB,GAAG;AAC7B,MAAM,eAAe,GAAG;AACxB,MAAM,iBAAiB,GAAG;AAC1B,MAAM,mBAAmB,GAAG;AAC5B,MAAM,eAAe,GAAG;AACxB,MAAM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B,CAAC,MAAM,EAAA,QAAA,EAAA,2VAAA,EAAA;;;AEnCnD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"softpak-components-spx-change-details.mjs","sources":["../../../../projects/softpak/components/spx-change-details/spx-change-details.component.ts","../../../../projects/softpak/components/spx-change-details/spx-change-details.component.html","../../../../projects/softpak/components/spx-change-details/softpak-components-spx-change-details.ts"],"sourcesContent":["import { ChangeDetectionStrategy, computed, effect, input, output } from '@angular/core';\r\nimport { Component } from '@angular/core';\r\nimport {\r\n FormBuilder,\r\n FormControl,\r\n FormGroup,\r\n FormsModule,\r\n ReactiveFormsModule,\r\n} from '@angular/forms';\r\nimport { Subscription } from 'rxjs';\r\nimport { SpxChangeDetailsValueI } from './spx-change-details-value.interface';\r\nimport { SpxFormViewComponent, SpxFormI, SpxFormButtonTypeEnum, SpxFormFieldI } from '@softpak/components/spx-form-view';\r\nimport { SpxSeverityEnum, valuePairToValue } from '@softpak/components/spx-helpers';\r\nimport { SpxValuePair, SpxInputTypeEnum } from '@softpak/components/spx-inputs';\r\nimport { spxValidatorRequired } from '@softpak/components/spx-validation';\r\n\r\nexport const spxSectionChangeDetails = 'changeDetails';\r\nexport const spxCtrlContainerNumber = 'containerNumber';\r\nexport const spxCtrlContainerSeqNr = 'containerSeqNr';\r\nexport const spxCtrlContainerType = 'containerType';\r\nexport const spxCtrlCustomer = 'customer';\r\nexport const spxCtrlTonsTested = 'tonsTested';\r\nexport const spxCtrlLicensePlate = 'licensePlate';\r\nexport const spxCtrlCategory = 'category';\r\nexport const spxCtrlUseCategories = 'useCategories';\r\n\r\n@Component({\r\n selector: 'spx-change-details',\r\n templateUrl: './spx-change-details.component.html',\r\n imports: [\r\n FormsModule,\r\n ReactiveFormsModule,\r\n SpxFormViewComponent,\r\n ],\r\n standalone: true,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n})\r\nexport class SpxChangeDetailsComponent {\r\n readonly formGroup = input<FormGroup>();\r\n readonly suggestions = input<any>();\r\n private readonly showTonsTested = computed(() =>\r\n this.suggestions()?.[spxCtrlTonsTested] &&\r\n this.suggestions()?.[spxCtrlTonsTested].length &&\r\n this.suggestions()?.[spxCtrlTonsTested].length > 0\r\n );\r\n readonly textCategory = input<string>();\r\n readonly textContainerNumber = input<string>();\r\n readonly textContainerType = input<string>();\r\n readonly textCustomer = input<string>();\r\n readonly textLicensePlate = input<string>();\r\n readonly textSave = input<string>();\r\n readonly textTonsTested = input<string>();\r\n spxBlurCategory = output<SpxValuePair<string>>();\r\n spxBlurContainerType = output<SpxValuePair<string>>();\r\n spxSearchCategory = output<SpxValuePair<string>>();\r\n spxSearchContainerType = output<SpxValuePair<string>>();\r\n spxSearchTonsTested = output<SpxValuePair<string>>();\r\n submit = output<SpxChangeDetailsValueI>();\r\n\r\n form: SpxFormI = {\r\n buttons: [\r\n {\r\n severity: SpxSeverityEnum.success,\r\n type: SpxFormButtonTypeEnum.submit,\r\n label: () => this.textSave()!,\r\n }\r\n ],\r\n sections: [\r\n {\r\n key: spxSectionChangeDetails,\r\n showTitle: () => false,\r\n fields: [\r\n {\r\n key: spxCtrlContainerSeqNr,\r\n type: () => SpxInputTypeEnum.hidden,\r\n validators: () => [spxValidatorRequired()],\r\n },\r\n {\r\n key: spxCtrlContainerNumber,\r\n type: () => SpxInputTypeEnum.text,\r\n label: () => this.textContainerNumber()!,\r\n readonly: () => true,\r\n validators: () => [spxValidatorRequired()],\r\n },\r\n {\r\n key: spxCtrlCustomer,\r\n type: () => SpxInputTypeEnum.text,\r\n capitalize: () => true,\r\n readonly: () => true,\r\n label: () => this.textCustomer()!,\r\n validators: () => [spxValidatorRequired()],\r\n },\r\n {\r\n key: spxCtrlContainerType,\r\n type: () => SpxInputTypeEnum.autocomplete,\r\n label: () => this.textContainerType()!,\r\n capitalize: () => true,\r\n validators: () => [spxValidatorRequired()],\r\n },\r\n {\r\n key: spxCtrlTonsTested,\r\n type: () => SpxInputTypeEnum.radio,\r\n label: () => this.textTonsTested()!,\r\n show: () => this.showTonsTested(),\r\n },\r\n {\r\n key: spxCtrlLicensePlate,\r\n type: () => SpxInputTypeEnum.text,\r\n label: () => this.textLicensePlate()!,\r\n capitalize: () => true,\r\n },\r\n {\r\n key: spxCtrlUseCategories,\r\n type: () => SpxInputTypeEnum.hidden,\r\n capitalize: () => true,\r\n },\r\n {\r\n key: spxCtrlCategory,\r\n type: () => SpxInputTypeEnum.autocomplete,\r\n label: () => this.textCategory()!,\r\n capitalize: () => true,\r\n show: () => valuePairToValue(this.ctrlUseCategories()?.value),\r\n validators: () => valuePairToValue(this.ctrlUseCategories()?.value) ? [spxValidatorRequired()] : [],\r\n }\r\n ]\r\n }\r\n ]\r\n };\r\n\r\n readonly ctrlCategory = computed(() => this.formGroup()?.get(spxCtrlCategory) as FormControl);\r\n readonly ctrlCustomer = computed(() => this.formGroup()?.get(spxCtrlCustomer) as FormControl);\r\n readonly ctrlContainerType = computed(() => this.formGroup()?.get(spxCtrlContainerType) as FormControl);\r\n readonly ctrlLicensePlate = computed(() => this.formGroup()?.get(spxCtrlLicensePlate) as FormControl);\r\n readonly ctrlTonsTested = computed(() => this.formGroup()?.get(spxCtrlTonsTested) as FormControl);\r\n readonly ctrlUseCategories = computed(() => this.formGroup()?.get(spxCtrlUseCategories) as FormControl);\r\n\r\n private subContainerType?: Subscription;\r\n\r\n constructor(readonly formBuilder: FormBuilder) {\r\n effect(() => {\r\n if (\r\n this.showTonsTested()\r\n ) {\r\n this.ctrlTonsTested()?.addValidators([spxValidatorRequired()]);\r\n this.ctrlTonsTested()?.updateValueAndValidity();\r\n } else {\r\n this.ctrlTonsTested()?.clearValidators();\r\n this.ctrlTonsTested()?.updateValueAndValidity();\r\n }\r\n });\r\n }\r\n\r\n createForm(): FormGroup {\r\n return SpxFormViewComponent.createForm(\r\n this.formBuilder,\r\n this.form.sections\r\n );\r\n }\r\n\r\n ngOnInit(): void {\r\n this.listenToContainerType();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n if (this.subContainerType) {\r\n this.subContainerType.unsubscribe();\r\n }\r\n }\r\n\r\n getRawValidators(formControl: FormControl) {\r\n return (formControl as any)._rawValidators;\r\n }\r\n\r\n onBlur(data: { field: SpxFormFieldI; valuePair: SpxValuePair<any> }) {\r\n setTimeout(() => {\r\n if (data.field.key === spxCtrlCategory && valuePairToValue(this.formGroup()!.get(spxCtrlCategory)!.value) !== null) {\r\n this.spxBlurCategory.emit(data.valuePair);\r\n }\r\n if (data.field.key === spxCtrlContainerType && valuePairToValue(this.formGroup()!.get(spxCtrlContainerType)!.value) !== null) {\r\n this.spxBlurContainerType.emit(data.valuePair);\r\n }\r\n }, 300);\r\n }\r\n\r\n onSearch(data: { field: SpxFormFieldI; valuePair: SpxValuePair<any> }) {\r\n if (data.field.key === spxCtrlCategory) {\r\n this.spxSearchCategory.emit(data.valuePair);\r\n }\r\n if (data.field.key === spxCtrlContainerType) {\r\n this.spxSearchContainerType.emit(data.valuePair);\r\n }\r\n if (data.field.key === spxCtrlTonsTested) {\r\n this.spxSearchTonsTested.emit(data.valuePair);\r\n }\r\n }\r\n\r\n onSubmit(): void {\r\n this.submit.emit({\r\n category: valuePairToValue(this.ctrlUseCategories().value) ? this.ctrlCategory().value : null,\r\n containerType: this.ctrlContainerType().value,\r\n licensePlate: this.ctrlLicensePlate().value,\r\n tonsTested: this.ctrlTonsTested().value,\r\n })\r\n }\r\n\r\n private listenToContainerType(): void {\r\n this.subContainerType = this.ctrlContainerType().valueChanges.subscribe(valuePair => {\r\n this.ctrlTonsTested().setValue({ value: null });\r\n this.spxSearchTonsTested.emit(valuePair);\r\n });\r\n }\r\n}\r\n","<form [formGroup]=\"formGroup()!\" class=\"max-w-lg mx-auto flex flex-col gap-3\" (ngSubmit)=\"onSubmit()\">\r\n <spx-form-view\r\n [spxFormGroup]=\"formGroup()!\"\r\n [spxForm]=\"form\"\r\n [spxSuggestions]=\"suggestions()\"\r\n (spxBlur)=\"onBlur($event)\"\r\n (spxSearch)=\"onSearch($event)\">\r\n </spx-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AAA,oBAAA,EAAA,QAAA,EAAA,0FAAA,EAAA,EAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAA,mBAAmB,gLACnB,oBAAoB,EAAA,QAAA,EAAA,eAAA,EAAA,MAAA,EAAA,CAAA,cAAA,EAAA,SAAA,EAAA,gBAAA,CAAA,EAAA,OAAA,EAAA,CAAA,SAAA,EAAA,UAAA,EAAA,WAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA;;4FAKX,yBAAyB,EAAA,UAAA,EAAA,CAAA;kBAXrC,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,oBAAoB,EAErB,OAAA,EAAA;wBACP,WAAW;wBACX,mBAAmB;wBACnB,oBAAoB;AACrB,qBAAA,EAAA,UAAA,EACW,IAAI,EAAA,eAAA,EACC,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,2VAAA,EAAA;;;AEnCjD;;AAEG;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { signal, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
2
|
+
import { signal, input, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
3
|
import { FormsModule } from '@angular/forms';
|
|
4
4
|
import { FaIconComponent } from '@fortawesome/angular-fontawesome';
|
|
5
5
|
import { IonTabs, IonTabBar, IonTabButton } from '@ionic/angular/standalone';
|
|
@@ -14,10 +14,15 @@ const all = union({
|
|
|
14
14
|
ctrl: ctrl,
|
|
15
15
|
});
|
|
16
16
|
|
|
17
|
+
var spxShortcuts_actions = /*#__PURE__*/Object.freeze({
|
|
18
|
+
__proto__: null,
|
|
19
|
+
ctrl: ctrl
|
|
20
|
+
});
|
|
21
|
+
|
|
17
22
|
const initialState = {
|
|
18
23
|
ctrlIsDown: false,
|
|
19
24
|
};
|
|
20
|
-
var spxShortCutsReducer = createFeature({
|
|
25
|
+
var spxShortCutsReducer$1 = createFeature({
|
|
21
26
|
name: 'spxShortcuts',
|
|
22
27
|
reducer: createReducer(initialState, on(ctrl, (state, { keyIsDown }) => ({
|
|
23
28
|
...state,
|
|
@@ -25,11 +30,18 @@ var spxShortCutsReducer = createFeature({
|
|
|
25
30
|
})))
|
|
26
31
|
});
|
|
27
32
|
|
|
33
|
+
var spxShortcuts_reducer = /*#__PURE__*/Object.freeze({
|
|
34
|
+
__proto__: null,
|
|
35
|
+
default: spxShortCutsReducer$1,
|
|
36
|
+
initialState: initialState
|
|
37
|
+
});
|
|
38
|
+
|
|
28
39
|
class SpxTabsComponent {
|
|
29
40
|
constructor(store) {
|
|
30
41
|
this.store = store;
|
|
31
42
|
this.navItems = signal([]);
|
|
32
43
|
this.showShortcuts = signal(false);
|
|
44
|
+
this.optionalNavItemBool = input(true);
|
|
33
45
|
this.subscription = {};
|
|
34
46
|
}
|
|
35
47
|
ngOnInit() {
|
|
@@ -40,17 +52,17 @@ class SpxTabsComponent {
|
|
|
40
52
|
unsubscribeSubscriptions(this.subscription);
|
|
41
53
|
}
|
|
42
54
|
listenToCtrlState() {
|
|
43
|
-
this.subscription.ctrlState = this.store.select(spxShortCutsReducer.selectCtrlIsDown).subscribe(ctrlIsDown => {
|
|
55
|
+
this.subscription.ctrlState = this.store.select(spxShortCutsReducer$1.selectCtrlIsDown).subscribe(ctrlIsDown => {
|
|
44
56
|
this.showShortcuts.set(ctrlIsDown);
|
|
45
57
|
});
|
|
46
58
|
}
|
|
47
59
|
listenToMenuState() {
|
|
48
60
|
this.subscription.menuState = this.store.select(spxNavigationReducer.default.selectTabs).subscribe((tabs) => {
|
|
49
|
-
this.navItems.set(tabs.filter(tab => !tab.currentSettingsRequired || (tab.currentSettingsRequired)));
|
|
61
|
+
this.navItems.set(tabs.filter(tab => !tab.currentSettingsRequired || (tab.currentSettingsRequired && this.optionalNavItemBool())));
|
|
50
62
|
});
|
|
51
63
|
}
|
|
52
64
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.11", ngImport: i0, type: SpxTabsComponent, deps: [{ token: i1.Store }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
53
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.11", type: SpxTabsComponent, isStandalone: true, selector: "spx-tabs", ngImport: i0, template: "<ion-tabs #tabs select=\"home\">\r\n <ion-tab-bar slot=\"bottom\" class=\"border-t border-gray-200\">\r\n @for (item of navItems(); track item.title) {\r\n <ion-tab-button [ngClass]=\"'ion-tab-button--' + item.code\" [tab]=\"item.code\"\r\n [attr.data-e2e]=\"'tab--' + item.code\">\r\n <fa-icon class=\"text-xl\" [icon]=\"showShortcuts() ? item.iconShortcut! : item.iconTab!\"></fa-icon>\r\n </ion-tab-button>\r\n }\r\n </ion-tab-bar>\r\n</ion-tabs>", styles: ["ion-tab-button{--color--active-tab: #FAB206;--color-focused: var(--color--active-tab);--color-selected: var(--color--active-tab);font-size:14px;padding-top:10px;padding-bottom:10px}ion-tab-button.ion-tab-button--hme{--color--active-tab: var(--color-hme);--ripple-color: var(--color-hme)}ion-tab-button.ion-tab-button--ord{--color--active-tab: var(--color-ord);--ripple-color: var(--color-ord)}ion-tab-button.ion-tab-button--qua{--color--active-tab: var(--color-qua);--ripple-color: var(--color-qua)}ion-tab-button.ion-tab-button--rel{--color--active-tab: var(--color-rel);--ripple-color: var(--color-rel)}ion-tab-button.ion-tab-button--rfr{--color--active-tab: var(--color-rfr);--ripple-color: var(--color-rfr)}ion-tab-button.ion-tab-button--sta{--color--active-tab: var(--color-sta);--ripple-color: var(--color-sta)}\n"], dependencies: [{ kind: "component", type: IonTabs, selector: "ion-tabs" }, { kind: "ngmodule", type: FormsModule }, { kind: "component", type: IonTabBar, selector: "ion-tab-bar", inputs: ["color", "mode", "selectedTab", "translucent"] }, { kind: "component", type: IonTabButton, selector: "ion-tab-button", inputs: ["disabled", "download", "href", "layout", "mode", "rel", "selected", "tab", "target"] }, { kind: "component", type: FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
65
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.11", type: SpxTabsComponent, isStandalone: true, selector: "spx-tabs", inputs: { optionalNavItemBool: { classPropertyName: "optionalNavItemBool", publicName: "optionalNavItemBool", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<ion-tabs #tabs select=\"home\">\r\n <ion-tab-bar slot=\"bottom\" class=\"border-t border-gray-200\">\r\n @for (item of navItems(); track item.title) {\r\n <ion-tab-button [ngClass]=\"'ion-tab-button--' + item.code\" [tab]=\"item.code\"\r\n [attr.data-e2e]=\"'tab--' + item.code\">\r\n <fa-icon class=\"text-xl\" [icon]=\"showShortcuts() ? item.iconShortcut! : item.iconTab!\"></fa-icon>\r\n </ion-tab-button>\r\n }\r\n </ion-tab-bar>\r\n</ion-tabs>", styles: ["ion-tab-button{--color--active-tab: #FAB206;--color-focused: var(--color--active-tab);--color-selected: var(--color--active-tab);font-size:14px;padding-top:10px;padding-bottom:10px}ion-tab-button.ion-tab-button--hme{--color--active-tab: var(--color-hme);--ripple-color: var(--color-hme)}ion-tab-button.ion-tab-button--ord{--color--active-tab: var(--color-ord);--ripple-color: var(--color-ord)}ion-tab-button.ion-tab-button--qua{--color--active-tab: var(--color-qua);--ripple-color: var(--color-qua)}ion-tab-button.ion-tab-button--rel{--color--active-tab: var(--color-rel);--ripple-color: var(--color-rel)}ion-tab-button.ion-tab-button--rfr{--color--active-tab: var(--color-rfr);--ripple-color: var(--color-rfr)}ion-tab-button.ion-tab-button--sta{--color--active-tab: var(--color-sta);--ripple-color: var(--color-sta)}\n"], dependencies: [{ kind: "component", type: IonTabs, selector: "ion-tabs" }, { kind: "ngmodule", type: FormsModule }, { kind: "component", type: IonTabBar, selector: "ion-tab-bar", inputs: ["color", "mode", "selectedTab", "translucent"] }, { kind: "component", type: IonTabButton, selector: "ion-tab-button", inputs: ["disabled", "download", "href", "layout", "mode", "rel", "selected", "tab", "target"] }, { kind: "component", type: FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
54
66
|
}
|
|
55
67
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.11", ngImport: i0, type: SpxTabsComponent, decorators: [{
|
|
56
68
|
type: Component,
|
|
@@ -68,5 +80,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.11", ngImpo
|
|
|
68
80
|
* Generated bundle index. Do not edit.
|
|
69
81
|
*/
|
|
70
82
|
|
|
71
|
-
export { SpxTabsComponent };
|
|
83
|
+
export { SpxTabsComponent, spxShortcuts_actions as spxShortCutsActions, spxShortcuts_reducer as spxShortCutsReducer };
|
|
72
84
|
//# sourceMappingURL=softpak-components-spx-tabs.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"softpak-components-spx-tabs.mjs","sources":["../../../../projects/softpak/components/spx-tabs/store/spx-shortcuts.actions.ts","../../../../projects/softpak/components/spx-tabs/store/spx-shortcuts.reducer.ts","../../../../projects/softpak/components/spx-tabs/src/spx-tabs.component.ts","../../../../projects/softpak/components/spx-tabs/src/spx-tabs.component.html","../../../../projects/softpak/components/spx-tabs/softpak-components-spx-tabs.ts"],"sourcesContent":["import { createAction, props, union } from '@ngrx/store';\r\n\r\nexport const ctrl = createAction('[SPX / Shortcuts] CTRL', props<{ keyIsDown: boolean; }>());\r\n\r\nconst all = union({\r\n ctrl: ctrl,\r\n});\r\nexport type Actions = typeof all;","import * as actions from './spx-shortcuts.actions';\r\nimport { createFeature, createReducer, on } from '@ngrx/store';\r\n\r\nexport interface StateI {\r\n ctrlIsDown: boolean;\r\n}\r\n\r\nexport const initialState: StateI = {\r\n ctrlIsDown: false,\r\n};\r\n\r\nexport default createFeature({\r\n name: 'spxShortcuts',\r\n reducer: createReducer(\r\n initialState,\r\n on(actions.ctrl, (state: StateI, { keyIsDown }): StateI => ({\r\n ...state,\r\n ctrlIsDown: keyIsDown,\r\n })),\r\n )}\r\n);","import { ChangeDetectionStrategy, Component, OnInit, signal } from \"@angular/core\";\r\nimport { FormsModule } from \"@angular/forms\";\r\nimport { FaIconComponent } from \"@fortawesome/angular-fontawesome\";\r\nimport { IonTabBar, IonTabButton, IonTabs } from \"@ionic/angular/standalone\";\r\nimport { Store } from \"@ngrx/store\";\r\nimport { unsubscribeSubscriptions } from \"@softpak/components/spx-helpers\";\r\nimport { SpxNavigationItemI, spxNavigationReducer } from \"@softpak/components/spx-navigation\";\r\nimport { Subscription } from \"rxjs\";\r\nimport { NgClass } from \"@angular/common\";\r\nimport spxShortCutsReducer from '../store/spx-shortcuts.reducer';\r\n\r\n@Component({\r\n // eslint-disable-next-line @angular-eslint/component-selector\r\n selector: 'spx-tabs',\r\n standalone: true,\r\n imports: [\r\n IonTabs, \r\n FormsModule,\r\n IonTabBar,\r\n IonTabButton,\r\n FaIconComponent,\r\n NgClass\r\n ],\r\n templateUrl: './spx-tabs.component.html',\r\n styleUrl: './spx-tabs.component.scss',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SpxTabsComponent implements OnInit {\r\n navItems = signal<SpxNavigationItemI[]>([]);\r\n showShortcuts = signal<boolean>(false);\r\n private subscription: {\r\n ctrlState?: Subscription;\r\n menuState?: Subscription;\r\n } = {};\r\n\r\n constructor(\r\n private readonly store: Store,\r\n ) { }\r\n\r\n ngOnInit() {\r\n this.listenToMenuState();\r\n this.listenToCtrlState();\r\n }\r\n\r\n ngOnDestroy() {\r\n unsubscribeSubscriptions(this.subscription);\r\n }\r\n\r\n private listenToCtrlState(): void {\r\n this.subscription.ctrlState = this.store.select(spxShortCutsReducer.selectCtrlIsDown).subscribe(ctrlIsDown => {\r\n this.showShortcuts.set(ctrlIsDown);\r\n });\r\n }\r\n\r\n private listenToMenuState(): void {\r\n this.subscription.menuState = this.store.select(spxNavigationReducer.default.selectTabs).subscribe((tabs) => {\r\n this.navItems.set(tabs.filter(tab => !tab.currentSettingsRequired || (tab.currentSettingsRequired)));\r\n });\r\n }\r\n\r\n}","<ion-tabs #tabs select=\"home\">\r\n <ion-tab-bar slot=\"bottom\" class=\"border-t border-gray-200\">\r\n @for (item of navItems(); track item.title) {\r\n <ion-tab-button [ngClass]=\"'ion-tab-button--' + item.code\" [tab]=\"item.code\"\r\n [attr.data-e2e]=\"'tab--' + item.code\">\r\n <fa-icon class=\"text-xl\" [icon]=\"showShortcuts() ? item.iconShortcut! : item.iconTab!\"></fa-icon>\r\n </ion-tab-button>\r\n }\r\n </ion-tab-bar>\r\n</ion-tabs>","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["actions.ctrl"],"mappings":";;;;;;;;;;;AAEO,MAAM,IAAI,GAAG,YAAY,CAAC,wBAAwB,EAAE,KAAK,EAA2B,CAAC;AAE5F,MAAM,GAAG,GAAG,KAAK,CAAC;AACd,IAAA,IAAI,EAAE,IAAI;AACb,CAAA,CAAC
|
|
1
|
+
{"version":3,"file":"softpak-components-spx-tabs.mjs","sources":["../../../../projects/softpak/components/spx-tabs/store/spx-shortcuts.actions.ts","../../../../projects/softpak/components/spx-tabs/store/spx-shortcuts.reducer.ts","../../../../projects/softpak/components/spx-tabs/src/spx-tabs.component.ts","../../../../projects/softpak/components/spx-tabs/src/spx-tabs.component.html","../../../../projects/softpak/components/spx-tabs/softpak-components-spx-tabs.ts"],"sourcesContent":["import { createAction, props, union } from '@ngrx/store';\r\n\r\nexport const ctrl = createAction('[SPX / Shortcuts] CTRL', props<{ keyIsDown: boolean; }>());\r\n\r\nconst all = union({\r\n ctrl: ctrl,\r\n});\r\nexport type Actions = typeof all;","import * as actions from './spx-shortcuts.actions';\r\nimport { createFeature, createReducer, on } from '@ngrx/store';\r\n\r\nexport interface StateI {\r\n ctrlIsDown: boolean;\r\n}\r\n\r\nexport const initialState: StateI = {\r\n ctrlIsDown: false,\r\n};\r\n\r\nexport default createFeature({\r\n name: 'spxShortcuts',\r\n reducer: createReducer(\r\n initialState,\r\n on(actions.ctrl, (state: StateI, { keyIsDown }): StateI => ({\r\n ...state,\r\n ctrlIsDown: keyIsDown,\r\n })),\r\n )}\r\n);","import { ChangeDetectionStrategy, Component, input, OnInit, signal } from \"@angular/core\";\r\nimport { FormsModule } from \"@angular/forms\";\r\nimport { FaIconComponent } from \"@fortawesome/angular-fontawesome\";\r\nimport { IonTabBar, IonTabButton, IonTabs } from \"@ionic/angular/standalone\";\r\nimport { Store } from \"@ngrx/store\";\r\nimport { unsubscribeSubscriptions } from \"@softpak/components/spx-helpers\";\r\nimport { SpxNavigationItemI, spxNavigationReducer } from \"@softpak/components/spx-navigation\";\r\nimport { Subscription } from \"rxjs\";\r\nimport { NgClass } from \"@angular/common\";\r\nimport spxShortCutsReducer from '../store/spx-shortcuts.reducer';\r\n\r\n@Component({\r\n // eslint-disable-next-line @angular-eslint/component-selector\r\n selector: 'spx-tabs',\r\n standalone: true,\r\n imports: [\r\n IonTabs, \r\n FormsModule,\r\n IonTabBar,\r\n IonTabButton,\r\n FaIconComponent,\r\n NgClass\r\n ],\r\n templateUrl: './spx-tabs.component.html',\r\n styleUrl: './spx-tabs.component.scss',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SpxTabsComponent implements OnInit {\r\n navItems = signal<SpxNavigationItemI[]>([]);\r\n showShortcuts = signal<boolean>(false);\r\n optionalNavItemBool = input<boolean>(true);\r\n private subscription: {\r\n ctrlState?: Subscription;\r\n menuState?: Subscription;\r\n } = {};\r\n\r\n constructor(\r\n private readonly store: Store,\r\n ) { }\r\n\r\n ngOnInit() {\r\n this.listenToMenuState();\r\n this.listenToCtrlState();\r\n }\r\n\r\n ngOnDestroy() {\r\n unsubscribeSubscriptions(this.subscription);\r\n }\r\n\r\n private listenToCtrlState(): void {\r\n this.subscription.ctrlState = this.store.select(spxShortCutsReducer.selectCtrlIsDown).subscribe(ctrlIsDown => {\r\n this.showShortcuts.set(ctrlIsDown);\r\n });\r\n }\r\n\r\n private listenToMenuState(): void {\r\n this.subscription.menuState = this.store.select(spxNavigationReducer.default.selectTabs).subscribe((tabs) => {\r\n this.navItems.set(tabs.filter(tab => !tab.currentSettingsRequired || (tab.currentSettingsRequired && this.optionalNavItemBool())));\r\n });\r\n }\r\n\r\n}","<ion-tabs #tabs select=\"home\">\r\n <ion-tab-bar slot=\"bottom\" class=\"border-t border-gray-200\">\r\n @for (item of navItems(); track item.title) {\r\n <ion-tab-button [ngClass]=\"'ion-tab-button--' + item.code\" [tab]=\"item.code\"\r\n [attr.data-e2e]=\"'tab--' + item.code\">\r\n <fa-icon class=\"text-xl\" [icon]=\"showShortcuts() ? item.iconShortcut! : item.iconTab!\"></fa-icon>\r\n </ion-tab-button>\r\n }\r\n </ion-tab-bar>\r\n</ion-tabs>","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["actions.ctrl","spxShortCutsReducer"],"mappings":";;;;;;;;;;;AAEO,MAAM,IAAI,GAAG,YAAY,CAAC,wBAAwB,EAAE,KAAK,EAA2B,CAAC;AAE5F,MAAM,GAAG,GAAG,KAAK,CAAC;AACd,IAAA,IAAI,EAAE,IAAI;AACb,CAAA,CAAC;;;;;;;ACCK,MAAM,YAAY,GAAW;AAClC,IAAA,UAAU,EAAE,KAAK;CAClB;AAED,4BAAe,aAAa,CAAC;AAC3B,IAAA,IAAI,EAAE,cAAc;IACpB,OAAO,EAAE,aAAa,CAC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AAA,eAAe,4MACf,OAAO,EAAA,QAAA,EAAA,WAAA,EAAA,MAAA,EAAA,CAAA,OAAA,EAAA,SAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA;;4FAMA,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAhB5B,SAAS;+BAEI,UAAU,EAAA,UAAA,EACR,IAAI,EACP,OAAA,EAAA;wBACP,OAAO;wBACP,WAAW;wBACX,SAAS;wBACT,YAAY;wBACZ,eAAe;wBACf;qBACD,EAGgB,eAAA,EAAA,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,meAAA,EAAA,MAAA,EAAA,CAAA,qzBAAA,CAAA,EAAA;;;AEzBnD;;AAEG;;;;"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { input, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
|
+
|
|
4
|
+
class SpxValidationMessagesComponent {
|
|
5
|
+
constructor() {
|
|
6
|
+
this.errors = input.required();
|
|
7
|
+
this.touched = input.required();
|
|
8
|
+
this.formControlI = input(undefined);
|
|
9
|
+
this.fieldLabel = input(undefined);
|
|
10
|
+
this.submitTried = input(undefined);
|
|
11
|
+
}
|
|
12
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.11", ngImport: i0, type: SpxValidationMessagesComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
13
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.11", 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: "\r\n@if (formControlI() && errors() && (touched() || submitTried())) {\r\n @if (errors()[\"maxlength\"]) {\r\n <div>'{{fieldLabel()}}' is too long, the maximum length is {{errors()[\"maxlength\"].requiredLength}}.</div>\r\n }\r\n @if (errors()[\"minlength\"]) {\r\n <div>'{{fieldLabel()}}' is too short, the minimum length is {{errors()[\"minlength\"].requiredLength}}.</div>\r\n }\r\n @if (errors()[\"max\"]) {\r\n <div>The value of '{{fieldLabel()}}' is too high, the maximum is {{errors()[\"max\"].max}}.</div>\r\n }\r\n @if (errors()[\"min\"]) {\r\n <div>The value of '{{fieldLabel()}}' is too low, the minimum is {{errors()[\"min\"].min}}.</div>\r\n }\r\n @if (errors()[\"pattern\"]) {\r\n <div>The pattern of '{{fieldLabel()}}' not valid.</div>\r\n }\r\n @if (errors()[\"required\"]) {\r\n <div>'{{fieldLabel()}}' is required.</div>\r\n }\r\n @if (errors()[\"year\"]) {\r\n <div>Please choose a year between 1991 and the current year.</div>\r\n }\r\n @if (errors()[\"yearFuture\"]) {\r\n <div>Please choose a year between the current year and 2050.</div>\r\n }\r\n @if (errors()[\"month\"]) {\r\n <div>Please choose a valid month (a value between 01 and 12).</div>\r\n }\r\n @if (errors()[\"future\"]) {\r\n <div>The selected date may not be in the future.</div>\r\n }\r\n @if (errors()[\"past\"]) {\r\n <div>The selected date may not be in the past.</div>\r\n }\r\n @if (errors()[\"invalidCode\"]) {\r\n <div>The {{ errors()[\"invalidCode\"].name }} code {{ errors()[\"invalidCode\"].code }} does not exist.</div>\r\n }\r\n}", styles: [":host{display:block}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
14
|
+
}
|
|
15
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.11", ngImport: i0, type: SpxValidationMessagesComponent, decorators: [{
|
|
16
|
+
type: Component,
|
|
17
|
+
args: [{ selector: 'spx-validation-messages', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, template: "\r\n@if (formControlI() && errors() && (touched() || submitTried())) {\r\n @if (errors()[\"maxlength\"]) {\r\n <div>'{{fieldLabel()}}' is too long, the maximum length is {{errors()[\"maxlength\"].requiredLength}}.</div>\r\n }\r\n @if (errors()[\"minlength\"]) {\r\n <div>'{{fieldLabel()}}' is too short, the minimum length is {{errors()[\"minlength\"].requiredLength}}.</div>\r\n }\r\n @if (errors()[\"max\"]) {\r\n <div>The value of '{{fieldLabel()}}' is too high, the maximum is {{errors()[\"max\"].max}}.</div>\r\n }\r\n @if (errors()[\"min\"]) {\r\n <div>The value of '{{fieldLabel()}}' is too low, the minimum is {{errors()[\"min\"].min}}.</div>\r\n }\r\n @if (errors()[\"pattern\"]) {\r\n <div>The pattern of '{{fieldLabel()}}' not valid.</div>\r\n }\r\n @if (errors()[\"required\"]) {\r\n <div>'{{fieldLabel()}}' is required.</div>\r\n }\r\n @if (errors()[\"year\"]) {\r\n <div>Please choose a year between 1991 and the current year.</div>\r\n }\r\n @if (errors()[\"yearFuture\"]) {\r\n <div>Please choose a year between the current year and 2050.</div>\r\n }\r\n @if (errors()[\"month\"]) {\r\n <div>Please choose a valid month (a value between 01 and 12).</div>\r\n }\r\n @if (errors()[\"future\"]) {\r\n <div>The selected date may not be in the future.</div>\r\n }\r\n @if (errors()[\"past\"]) {\r\n <div>The selected date may not be in the past.</div>\r\n }\r\n @if (errors()[\"invalidCode\"]) {\r\n <div>The {{ errors()[\"invalidCode\"].name }} code {{ errors()[\"invalidCode\"].code }} does not exist.</div>\r\n }\r\n}", styles: [":host{display:block}\n"] }]
|
|
18
|
+
}] });
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Generated bundle index. Do not edit.
|
|
22
|
+
*/
|
|
23
|
+
|
|
24
|
+
export { SpxValidationMessagesComponent };
|
|
25
|
+
//# sourceMappingURL=softpak-components-spx-validation-messages.mjs.map
|
|
@@ -0,0 +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 { ChangeDetectionStrategy, Component, input } from '@angular/core';\r\nimport { AbstractControl, ValidationErrors } from '@angular/forms';\r\n\r\n@Component({\r\n selector: 'spx-validation-messages',\r\n standalone: true,\r\n templateUrl: './spx-validation-messages.component.html',\r\n styleUrl: './spx-validation-messages.component.scss',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SpxValidationMessagesComponent { \r\n readonly errors = input.required<ValidationErrors>();\r\n readonly touched = input.required<boolean>();\r\n readonly formControlI = input<AbstractControl<any,any> | undefined>(undefined);\r\n readonly fieldLabel = input<string | undefined>(undefined);\r\n readonly submitTried = input<boolean | undefined>(undefined);\r\n}\r\n","\r\n@if (formControlI() && errors() && (touched() || submitTried())) {\r\n @if (errors()[\"maxlength\"]) {\r\n <div>'{{fieldLabel()}}' is too long, the maximum length is {{errors()[\"maxlength\"].requiredLength}}.</div>\r\n }\r\n @if (errors()[\"minlength\"]) {\r\n <div>'{{fieldLabel()}}' is too short, the minimum length is {{errors()[\"minlength\"].requiredLength}}.</div>\r\n }\r\n @if (errors()[\"max\"]) {\r\n <div>The value of '{{fieldLabel()}}' is too high, the maximum is {{errors()[\"max\"].max}}.</div>\r\n }\r\n @if (errors()[\"min\"]) {\r\n <div>The value of '{{fieldLabel()}}' is too low, the minimum is {{errors()[\"min\"].min}}.</div>\r\n }\r\n @if (errors()[\"pattern\"]) {\r\n <div>The pattern of '{{fieldLabel()}}' not valid.</div>\r\n }\r\n @if (errors()[\"required\"]) {\r\n <div>'{{fieldLabel()}}' is required.</div>\r\n }\r\n @if (errors()[\"year\"]) {\r\n <div>Please choose a year between 1991 and the current year.</div>\r\n }\r\n @if (errors()[\"yearFuture\"]) {\r\n <div>Please choose a year between the current year and 2050.</div>\r\n }\r\n @if (errors()[\"month\"]) {\r\n <div>Please choose a valid month (a value between 01 and 12).</div>\r\n }\r\n @if (errors()[\"future\"]) {\r\n <div>The selected date may not be in the future.</div>\r\n }\r\n @if (errors()[\"past\"]) {\r\n <div>The selected date may not be in the past.</div>\r\n }\r\n @if (errors()[\"invalidCode\"]) {\r\n <div>The {{ errors()[\"invalidCode\"].name }} code {{ errors()[\"invalidCode\"].code }} does not exist.</div>\r\n }\r\n}","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;MAUa,8BAA8B,CAAA;AAP3C,IAAA,WAAA,GAAA;AAQW,QAAA,IAAA,CAAA,MAAM,GAAG,KAAK,CAAC,QAAQ,EAAoB;AAC3C,QAAA,IAAA,CAAA,OAAO,GAAG,KAAK,CAAC,QAAQ,EAAW;AACnC,QAAA,IAAA,CAAA,YAAY,GAAG,KAAK,CAAuC,SAAS,CAAC;AACrE,QAAA,IAAA,CAAA,UAAU,GAAG,KAAK,CAAqB,SAAS,CAAC;AACjD,QAAA,IAAA,CAAA,WAAW,GAAG,KAAK,CAAsB,SAAS,CAAC;AAC7D;+GANY,8BAA8B,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,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,SAAA,EAAA,IAAA,EAAA,8BAA8B,ovBCV3C,yjDAsCC,EAAA,MAAA,EAAA,CAAA,wBAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA;;4FD5BY,8BAA8B,EAAA,UAAA,EAAA,CAAA;kBAP1C,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,yBAAyB,EACvB,UAAA,EAAA,IAAI,EAGC,eAAA,EAAA,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,yjDAAA,EAAA,MAAA,EAAA,CAAA,wBAAA,CAAA,EAAA;;;AERjD;;AAEG;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@softpak/components",
|
|
3
|
-
"version": "19.
|
|
3
|
+
"version": "19.25.1",
|
|
4
4
|
"private": false,
|
|
5
5
|
"peerDependencies": {
|
|
6
6
|
"@angular/common": "19.x.x",
|
|
@@ -37,30 +37,30 @@
|
|
|
37
37
|
"types": "./spx-alert/index.d.ts",
|
|
38
38
|
"default": "./fesm2022/softpak-components-spx-alert.mjs"
|
|
39
39
|
},
|
|
40
|
-
"./spx-app-configuration": {
|
|
41
|
-
"types": "./spx-app-configuration/index.d.ts",
|
|
42
|
-
"default": "./fesm2022/softpak-components-spx-app-configuration.mjs"
|
|
43
|
-
},
|
|
44
40
|
"./spx-app-expiry": {
|
|
45
41
|
"types": "./spx-app-expiry/index.d.ts",
|
|
46
42
|
"default": "./fesm2022/softpak-components-spx-app-expiry.mjs"
|
|
47
43
|
},
|
|
48
|
-
"./spx-
|
|
49
|
-
"types": "./spx-
|
|
50
|
-
"default": "./fesm2022/softpak-components-spx-
|
|
51
|
-
},
|
|
52
|
-
"./spx-capitalize": {
|
|
53
|
-
"types": "./spx-capitalize/index.d.ts",
|
|
54
|
-
"default": "./fesm2022/softpak-components-spx-capitalize.mjs"
|
|
44
|
+
"./spx-app-configuration": {
|
|
45
|
+
"types": "./spx-app-configuration/index.d.ts",
|
|
46
|
+
"default": "./fesm2022/softpak-components-spx-app-configuration.mjs"
|
|
55
47
|
},
|
|
56
48
|
"./spx-card": {
|
|
57
49
|
"types": "./spx-card/index.d.ts",
|
|
58
50
|
"default": "./fesm2022/softpak-components-spx-card.mjs"
|
|
59
51
|
},
|
|
52
|
+
"./spx-button": {
|
|
53
|
+
"types": "./spx-button/index.d.ts",
|
|
54
|
+
"default": "./fesm2022/softpak-components-spx-button.mjs"
|
|
55
|
+
},
|
|
60
56
|
"./spx-change-details": {
|
|
61
57
|
"types": "./spx-change-details/index.d.ts",
|
|
62
58
|
"default": "./fesm2022/softpak-components-spx-change-details.mjs"
|
|
63
59
|
},
|
|
60
|
+
"./spx-capitalize": {
|
|
61
|
+
"types": "./spx-capitalize/index.d.ts",
|
|
62
|
+
"default": "./fesm2022/softpak-components-spx-capitalize.mjs"
|
|
63
|
+
},
|
|
64
64
|
"./spx-channel-selection": {
|
|
65
65
|
"types": "./spx-channel-selection/index.d.ts",
|
|
66
66
|
"default": "./fesm2022/softpak-components-spx-channel-selection.mjs"
|
|
@@ -105,14 +105,14 @@
|
|
|
105
105
|
"types": "./spx-patch/index.d.ts",
|
|
106
106
|
"default": "./fesm2022/softpak-components-spx-patch.mjs"
|
|
107
107
|
},
|
|
108
|
-
"./spx-pipes": {
|
|
109
|
-
"types": "./spx-pipes/index.d.ts",
|
|
110
|
-
"default": "./fesm2022/softpak-components-spx-pipes.mjs"
|
|
111
|
-
},
|
|
112
108
|
"./spx-progress-bar": {
|
|
113
109
|
"types": "./spx-progress-bar/index.d.ts",
|
|
114
110
|
"default": "./fesm2022/softpak-components-spx-progress-bar.mjs"
|
|
115
111
|
},
|
|
112
|
+
"./spx-pipes": {
|
|
113
|
+
"types": "./spx-pipes/index.d.ts",
|
|
114
|
+
"default": "./fesm2022/softpak-components-spx-pipes.mjs"
|
|
115
|
+
},
|
|
116
116
|
"./spx-spinner": {
|
|
117
117
|
"types": "./spx-spinner/index.d.ts",
|
|
118
118
|
"default": "./fesm2022/softpak-components-spx-spinner.mjs"
|
|
@@ -121,26 +121,26 @@
|
|
|
121
121
|
"types": "./spx-stock-info/index.d.ts",
|
|
122
122
|
"default": "./fesm2022/softpak-components-spx-stock-info.mjs"
|
|
123
123
|
},
|
|
124
|
-
"./spx-storage": {
|
|
125
|
-
"types": "./spx-storage/index.d.ts",
|
|
126
|
-
"default": "./fesm2022/softpak-components-spx-storage.mjs"
|
|
127
|
-
},
|
|
128
124
|
"./spx-suggestion": {
|
|
129
125
|
"types": "./spx-suggestion/index.d.ts",
|
|
130
126
|
"default": "./fesm2022/softpak-components-spx-suggestion.mjs"
|
|
131
127
|
},
|
|
128
|
+
"./spx-storage": {
|
|
129
|
+
"types": "./spx-storage/index.d.ts",
|
|
130
|
+
"default": "./fesm2022/softpak-components-spx-storage.mjs"
|
|
131
|
+
},
|
|
132
132
|
"./spx-tabs": {
|
|
133
133
|
"types": "./spx-tabs/index.d.ts",
|
|
134
134
|
"default": "./fesm2022/softpak-components-spx-tabs.mjs"
|
|
135
135
|
},
|
|
136
|
-
"./spx-toaster": {
|
|
137
|
-
"types": "./spx-toaster/index.d.ts",
|
|
138
|
-
"default": "./fesm2022/softpak-components-spx-toaster.mjs"
|
|
139
|
-
},
|
|
140
136
|
"./spx-toggle": {
|
|
141
137
|
"types": "./spx-toggle/index.d.ts",
|
|
142
138
|
"default": "./fesm2022/softpak-components-spx-toggle.mjs"
|
|
143
139
|
},
|
|
140
|
+
"./spx-toaster": {
|
|
141
|
+
"types": "./spx-toaster/index.d.ts",
|
|
142
|
+
"default": "./fesm2022/softpak-components-spx-toaster.mjs"
|
|
143
|
+
},
|
|
144
144
|
"./spx-translate": {
|
|
145
145
|
"types": "./spx-translate/index.d.ts",
|
|
146
146
|
"default": "./fesm2022/softpak-components-spx-translate.mjs"
|
|
@@ -152,6 +152,10 @@
|
|
|
152
152
|
"./spx-validation": {
|
|
153
153
|
"types": "./spx-validation/index.d.ts",
|
|
154
154
|
"default": "./fesm2022/softpak-components-spx-validation.mjs"
|
|
155
|
+
},
|
|
156
|
+
"./spx-validation-messages": {
|
|
157
|
+
"types": "./spx-validation-messages/index.d.ts",
|
|
158
|
+
"default": "./fesm2022/softpak-components-spx-validation-messages.mjs"
|
|
155
159
|
}
|
|
156
160
|
}
|
|
157
161
|
}
|
package/spx-tabs/public-api.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ export declare class SpxTabsComponent implements OnInit {
|
|
|
6
6
|
private readonly store;
|
|
7
7
|
navItems: import("@angular/core").WritableSignal<SpxNavigationItemI[]>;
|
|
8
8
|
showShortcuts: import("@angular/core").WritableSignal<boolean>;
|
|
9
|
+
optionalNavItemBool: import("@angular/core").InputSignal<boolean>;
|
|
9
10
|
private subscription;
|
|
10
11
|
constructor(store: Store);
|
|
11
12
|
ngOnInit(): void;
|
|
@@ -13,5 +14,5 @@ export declare class SpxTabsComponent implements OnInit {
|
|
|
13
14
|
private listenToCtrlState;
|
|
14
15
|
private listenToMenuState;
|
|
15
16
|
static ɵfac: i0.ɵɵFactoryDeclaration<SpxTabsComponent, never>;
|
|
16
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<SpxTabsComponent, "spx-tabs", never, {}, {}, never, never, true, never>;
|
|
17
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SpxTabsComponent, "spx-tabs", never, { "optionalNavItemBool": { "alias": "optionalNavItemBool"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
17
18
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './spx-validation-messages.component';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { AbstractControl, ValidationErrors } from '@angular/forms';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export declare class SpxValidationMessagesComponent {
|
|
4
|
+
readonly errors: import("@angular/core").InputSignal<ValidationErrors>;
|
|
5
|
+
readonly touched: import("@angular/core").InputSignal<boolean>;
|
|
6
|
+
readonly formControlI: import("@angular/core").InputSignal<AbstractControl<any, any> | undefined>;
|
|
7
|
+
readonly fieldLabel: import("@angular/core").InputSignal<string | undefined>;
|
|
8
|
+
readonly submitTried: import("@angular/core").InputSignal<boolean | undefined>;
|
|
9
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SpxValidationMessagesComponent, never>;
|
|
10
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SpxValidationMessagesComponent, "spx-validation-messages", never, { "errors": { "alias": "errors"; "required": true; "isSignal": true; }; "touched": { "alias": "touched"; "required": true; "isSignal": true; }; "formControlI": { "alias": "formControlI"; "required": false; "isSignal": true; }; "fieldLabel": { "alias": "fieldLabel"; "required": false; "isSignal": true; }; "submitTried": { "alias": "submitTried"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
11
|
+
}
|