ngx-t-forms 2.0.9 → 2.0.11
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/{ngx-t-forms-api-value-access-rules.component-DjZDnTHz.mjs → ngx-t-forms-api-value-access-rules.component-Cz4ruucP.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-api-value-access-rules.component-DjZDnTHz.mjs.map → ngx-t-forms-api-value-access-rules.component-Cz4ruucP.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-calculated-field-rules.component-E3l7DQo7.mjs → ngx-t-forms-calculated-field-rules.component-DdAzjsV9.mjs} +3 -3
- package/fesm2022/{ngx-t-forms-calculated-field-rules.component-E3l7DQo7.mjs.map → ngx-t-forms-calculated-field-rules.component-DdAzjsV9.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-config-mscoa-additional-inputs.component-sOC54w4T.mjs → ngx-t-forms-config-mscoa-additional-inputs.component-CZglpHAQ.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-config-mscoa-additional-inputs.component-sOC54w4T.mjs.map → ngx-t-forms-config-mscoa-additional-inputs.component-CZglpHAQ.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-form-input-selector.component-CB03sPjA.mjs → ngx-t-forms-form-input-selector.component-D8sg5JiD.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-form-input-selector.component-CB03sPjA.mjs.map → ngx-t-forms-form-input-selector.component-D8sg5JiD.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-form-json-view.component-C1AZujJH.mjs → ngx-t-forms-form-json-view.component-CO7EYgoY.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-form-json-view.component-C1AZujJH.mjs.map → ngx-t-forms-form-json-view.component-CO7EYgoY.mjs.map} +1 -1
- package/fesm2022/ngx-t-forms-form-section-stepper.component-DYfPkzOO.mjs +243 -0
- package/fesm2022/ngx-t-forms-form-section-stepper.component-DYfPkzOO.mjs.map +1 -0
- package/fesm2022/{ngx-t-forms-forms-builder-menu.component-CPIcPREp.mjs → ngx-t-forms-forms-builder-menu.component-Coppm548.mjs} +13 -7
- package/fesm2022/ngx-t-forms-forms-builder-menu.component-Coppm548.mjs.map +1 -0
- package/fesm2022/{ngx-t-forms-input-editor.component-__grERM8.mjs → ngx-t-forms-input-editor.component-BuSjy9Xq.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-input-editor.component-__grERM8.mjs.map → ngx-t-forms-input-editor.component-BuSjy9Xq.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-mat-chip-list-editor.component-DcdHYqhN.mjs → ngx-t-forms-mat-chip-list-editor.component-C1uQVrVP.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-mat-chip-list-editor.component-DcdHYqhN.mjs.map → ngx-t-forms-mat-chip-list-editor.component-C1uQVrVP.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-mat-slider-editor.component-C9rintm4.mjs → ngx-t-forms-mat-slider-editor.component-B0Qcx6y9.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-mat-slider-editor.component-C9rintm4.mjs.map → ngx-t-forms-mat-slider-editor.component-B0Qcx6y9.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-mat-slider-toggle-editor.component-CItK6kXf.mjs → ngx-t-forms-mat-slider-toggle-editor.component-B3N3mb8E.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-mat-slider-toggle-editor.component-CItK6kXf.mjs.map → ngx-t-forms-mat-slider-toggle-editor.component-B3N3mb8E.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-missing-form-configs.component-Da3SdUn6.mjs → ngx-t-forms-missing-form-configs.component-me7NBrdO.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-missing-form-configs.component-Da3SdUn6.mjs.map → ngx-t-forms-missing-form-configs.component-me7NBrdO.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-mscoa-segment-config.component-4hrEpLk3.mjs → ngx-t-forms-mscoa-segment-config.component-BY67rkzl.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-mscoa-segment-config.component-4hrEpLk3.mjs.map → ngx-t-forms-mscoa-segment-config.component-BY67rkzl.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-ngx-t-forms-1Roar4qK.mjs → ngx-t-forms-ngx-t-forms-C6wZyKbR.mjs} +683 -324
- package/fesm2022/ngx-t-forms-ngx-t-forms-C6wZyKbR.mjs.map +1 -0
- package/fesm2022/{ngx-t-forms-pipeline-generator.component-BQDykLNH.mjs → ngx-t-forms-pipeline-generator.component-Bu94_5ji.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-pipeline-generator.component-BQDykLNH.mjs.map → ngx-t-forms-pipeline-generator.component-Bu94_5ji.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-required-inputs.component-BGK3DNu0.mjs → ngx-t-forms-required-inputs.component-BdKBo1bW.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-required-inputs.component-BGK3DNu0.mjs.map → ngx-t-forms-required-inputs.component-BdKBo1bW.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-rest-api-call-setup.component-CCaRUSVQ.mjs → ngx-t-forms-rest-api-call-setup.component-59CnCXEt.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-rest-api-call-setup.component-CCaRUSVQ.mjs.map → ngx-t-forms-rest-api-call-setup.component-59CnCXEt.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-section-report.component-C8Ja_G_3.mjs → ngx-t-forms-section-report.component-DB_5Jx3j.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-section-report.component-C8Ja_G_3.mjs.map → ngx-t-forms-section-report.component-DB_5Jx3j.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-selection-options-editor.component-cYkn1O48.mjs → ngx-t-forms-selection-options-editor.component-B4LtSVfp.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-selection-options-editor.component-cYkn1O48.mjs.map → ngx-t-forms-selection-options-editor.component-B4LtSVfp.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-validators-config.component-CGXCCl45.mjs → ngx-t-forms-validators-config.component-CehxpsPR.mjs} +3 -3
- package/fesm2022/{ngx-t-forms-validators-config.component-CGXCCl45.mjs.map → ngx-t-forms-validators-config.component-CehxpsPR.mjs.map} +1 -1
- package/fesm2022/ngx-t-forms.mjs +1 -1
- package/lib/components/form-builder/elements/form-section-stepper/form-section-stepper.component.d.ts +5 -0
- package/lib/components/form-builder/elements/forms-builder-menu/forms-builder-menu.component.d.ts +2 -0
- package/lib/components/form-builder/elements/select-form-template/select-form-template.component.d.ts +7 -2
- package/lib/components/forms/forms.component.d.ts +1 -1
- package/lib/components/t-form-input/elements/Geo-location-form-input/geo-location.component.d.ts +1 -4
- package/lib/components/t-form-input/elements/auto-complete-input-element/auto-complete-input-element.component.d.ts +1 -4
- package/lib/components/t-form-input/elements/auto-complete-input-element/core/auto-complet-reactive-input/auto-complet-reactive-input.component.d.ts +19 -0
- package/lib/components/t-form-input/elements/basic-input-input-element/basic-input-input-element.component.d.ts +1 -4
- package/lib/components/t-form-input/elements/date-picker-input-element/core/date-picker-reactive-input/date-picker-reactive-input.component.d.ts +16 -0
- package/lib/components/t-form-input/elements/date-picker-input-element/date-picker-input-element.component.d.ts +1 -5
- package/lib/components/t-form-input/elements/date-range-picker-input-element/core/date-range-picker-reactive-input/date-range-picker-reactive-input.component.d.ts +17 -0
- package/lib/components/t-form-input/elements/date-range-picker-input-element/date-range-picker-input-element.component.d.ts +22 -5
- package/lib/components/t-form-input/elements/editor-input-element/core/form-input-rich-text-editor/config.d.ts +1 -0
- package/lib/components/t-form-input/elements/editor-input-element/editor-input-element.component.d.ts +1 -4
- package/lib/components/t-form-input/elements/file-upload-input-element/file-upload-input-element.component.d.ts +1 -4
- package/lib/components/t-form-input/elements/image-capture-input-element/image-capture-input-element.component.d.ts +1 -4
- package/lib/components/t-form-input/elements/mscoa-form-input/elements/mscoa-chart/mscoa-chart.component.d.ts +3 -1
- package/lib/components/t-form-input/elements/mscoa-form-input/elements/mscoa-reactive-form-field/mscoa-reactive-form-field.component.d.ts +1 -0
- package/lib/components/t-form-input/elements/mscoa-form-input/mscoa-form-input.component.d.ts +2 -5
- package/lib/components/t-form-input/elements/multiple-input-input-element/core/multiple-input-table/multiple-input-table.component.d.ts +8 -6
- package/lib/components/t-form-input/elements/multiple-input-input-element/multiple-input-input-element.component.d.ts +1 -4
- package/lib/components/t-form-input/elements/select-input-element/elements/select-input/select-input.component.d.ts +1 -0
- package/lib/components/t-form-input/elements/select-input-element/select-input-element.component.d.ts +1 -5
- package/lib/components/t-form-input/elements/select-table-input/select-table-input.component.d.ts +1 -4
- package/lib/components/t-form-input/elements/signature-input-element/signature-input-element.component.d.ts +1 -4
- package/lib/components/t-form-input/elements/textarea-input-element/core/text-area-reactive-input/text-area-reactive-input.component.d.ts +20 -0
- package/lib/components/t-form-input/elements/textarea-input-element/textarea-input-element.component.d.ts +1 -4
- package/lib/components/t-form-input/elements/toggle-input-element/core/toggle/toggle.component.d.ts +1 -0
- package/lib/components/t-form-input/elements/toggle-input-element/toggle-input-element.component.d.ts +1 -4
- package/lib/components/t-form-input/t-form-input.component.d.ts +1 -4
- package/lib/components/t-form-input-status/t-form-input-status.component.d.ts +1 -0
- package/lib/services/core/t-form-controller/function/multipleFormInputsMapValueToFormInputId.d.ts +2 -0
- package/lib/services/core/t-form-section-controller/Functions/commonFormOperations.d.ts +1 -1
- package/lib/services/core/t-form-tower-controller/form-tower-controller.service.d.ts +1 -1
- package/lib/services/core/t-input-controller/functions/baseCustomInput.d.ts +0 -1
- package/package.json +2 -2
- package/fesm2022/ngx-t-forms-api-value-access-rules.component-Zg1ddSDb.mjs +0 -813
- package/fesm2022/ngx-t-forms-api-value-access-rules.component-Zg1ddSDb.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-calculated-field-rules.component-ZepKycLR.mjs +0 -532
- package/fesm2022/ngx-t-forms-calculated-field-rules.component-ZepKycLR.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-config-mscoa-additional-inputs.component-DLnB3R7t.mjs +0 -297
- package/fesm2022/ngx-t-forms-config-mscoa-additional-inputs.component-DLnB3R7t.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-form-input-selector.component-BjwzDiCY.mjs +0 -187
- package/fesm2022/ngx-t-forms-form-input-selector.component-BjwzDiCY.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-form-json-view.component-CqtTYCRH.mjs +0 -28
- package/fesm2022/ngx-t-forms-form-json-view.component-CqtTYCRH.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-form-section-stepper.component-Ba5WCLzp.mjs +0 -673
- package/fesm2022/ngx-t-forms-form-section-stepper.component-Ba5WCLzp.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-form-section-stepper.component-C_dciQhe.mjs +0 -225
- package/fesm2022/ngx-t-forms-form-section-stepper.component-C_dciQhe.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-forms-builder-menu.component-CPIcPREp.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-forms-builder-menu.component-DbxEBvpt.mjs +0 -735
- package/fesm2022/ngx-t-forms-forms-builder-menu.component-DbxEBvpt.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-input-editor.component-BnsC-jsN.mjs +0 -445
- package/fesm2022/ngx-t-forms-input-editor.component-BnsC-jsN.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-mat-chip-list-editor.component-DS6s98ZX.mjs +0 -111
- package/fesm2022/ngx-t-forms-mat-chip-list-editor.component-DS6s98ZX.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-mat-slider-editor.component-ChiiJYK2.mjs +0 -130
- package/fesm2022/ngx-t-forms-mat-slider-editor.component-ChiiJYK2.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-mat-slider-toggle-editor.component-DFcLzkSF.mjs +0 -171
- package/fesm2022/ngx-t-forms-mat-slider-toggle-editor.component-DFcLzkSF.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-missing-form-configs.component-DNkGCH0e.mjs +0 -104
- package/fesm2022/ngx-t-forms-missing-form-configs.component-DNkGCH0e.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-mscoa-segment-config.component-CrHAIRAw.mjs +0 -455
- package/fesm2022/ngx-t-forms-mscoa-segment-config.component-CrHAIRAw.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-ngx-t-forms-1Roar4qK.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-ngx-t-forms-DaAFB-HX.mjs +0 -14694
- package/fesm2022/ngx-t-forms-ngx-t-forms-DaAFB-HX.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-pipeline-generator.component-U0d8jQKW.mjs +0 -1362
- package/fesm2022/ngx-t-forms-pipeline-generator.component-U0d8jQKW.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-required-inputs.component-S3cbA-zG.mjs +0 -383
- package/fesm2022/ngx-t-forms-required-inputs.component-S3cbA-zG.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-rest-api-call-setup.component-DDg4fCFx.mjs +0 -457
- package/fesm2022/ngx-t-forms-rest-api-call-setup.component-DDg4fCFx.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-section-report.component-C_h0KIR4.mjs +0 -314
- package/fesm2022/ngx-t-forms-section-report.component-C_h0KIR4.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-selection-options-editor.component-CllhwZ5Y.mjs +0 -231
- package/fesm2022/ngx-t-forms-selection-options-editor.component-CllhwZ5Y.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-validators-config.component-BPJZRtjT.mjs +0 -434
- package/fesm2022/ngx-t-forms-validators-config.component-BPJZRtjT.mjs.map +0 -1
|
@@ -1,104 +0,0 @@
|
|
|
1
|
-
import * as i0 from '@angular/core';
|
|
2
|
-
import { Component } from '@angular/core';
|
|
3
|
-
import { F as FormsStoreService, M as MatModulesModule } from './ngx-t-forms-ngx-t-forms-DaAFB-HX.mjs';
|
|
4
|
-
import * as i2$1 from '@angular/common';
|
|
5
|
-
import { CommonModule } from '@angular/common';
|
|
6
|
-
import * as i2 from '@angular/material/button';
|
|
7
|
-
import * as i6 from '@angular/material/icon';
|
|
8
|
-
import * as i9 from '@angular/material/toolbar';
|
|
9
|
-
import * as i8 from '@angular/material/tooltip';
|
|
10
|
-
|
|
11
|
-
function MissingFormConfigsComponent_Conditional_0_Template(rf, ctx) { if (rf & 1) {
|
|
12
|
-
const _r1 = i0.ɵɵgetCurrentView();
|
|
13
|
-
i0.ɵɵelementStart(0, "button", 2);
|
|
14
|
-
i0.ɵɵlistener("click", function MissingFormConfigsComponent_Conditional_0_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.hideDetails = false); });
|
|
15
|
-
i0.ɵɵelementStart(1, "mat-icon");
|
|
16
|
-
i0.ɵɵtext(2, "error");
|
|
17
|
-
i0.ɵɵelementEnd()();
|
|
18
|
-
} }
|
|
19
|
-
function MissingFormConfigsComponent_Conditional_1_For_16_Template(rf, ctx) { if (rf & 1) {
|
|
20
|
-
i0.ɵɵelementStart(0, "li");
|
|
21
|
-
i0.ɵɵtext(1);
|
|
22
|
-
i0.ɵɵelementEnd();
|
|
23
|
-
} if (rf & 2) {
|
|
24
|
-
const issue_r4 = ctx.$implicit;
|
|
25
|
-
i0.ɵɵadvance();
|
|
26
|
-
i0.ɵɵtextInterpolate1(" ", issue_r4, " ");
|
|
27
|
-
} }
|
|
28
|
-
function MissingFormConfigsComponent_Conditional_1_Conditional_18_For_5_Template(rf, ctx) { if (rf & 1) {
|
|
29
|
-
i0.ɵɵelementStart(0, "li");
|
|
30
|
-
i0.ɵɵtext(1);
|
|
31
|
-
i0.ɵɵelementEnd();
|
|
32
|
-
} if (rf & 2) {
|
|
33
|
-
const error_r5 = ctx.$implicit;
|
|
34
|
-
i0.ɵɵadvance();
|
|
35
|
-
i0.ɵɵtextInterpolate1(" ", error_r5, " ");
|
|
36
|
-
} }
|
|
37
|
-
function MissingFormConfigsComponent_Conditional_1_Conditional_18_Template(rf, ctx) { if (rf & 1) {
|
|
38
|
-
i0.ɵɵelementStart(0, "h5")(1, "strong");
|
|
39
|
-
i0.ɵɵtext(2, " Form validationErrors : ");
|
|
40
|
-
i0.ɵɵelementEnd()();
|
|
41
|
-
i0.ɵɵelementStart(3, "ul");
|
|
42
|
-
i0.ɵɵrepeaterCreate(4, MissingFormConfigsComponent_Conditional_1_Conditional_18_For_5_Template, 2, 1, "li", null, i0.ɵɵrepeaterTrackByIdentity);
|
|
43
|
-
i0.ɵɵpipe(6, "async");
|
|
44
|
-
i0.ɵɵelementEnd();
|
|
45
|
-
} if (rf & 2) {
|
|
46
|
-
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
47
|
-
i0.ɵɵadvance(4);
|
|
48
|
-
i0.ɵɵrepeater(i0.ɵɵpipeBind1(6, 0, ctx_r1.errors$));
|
|
49
|
-
} }
|
|
50
|
-
function MissingFormConfigsComponent_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
51
|
-
const _r3 = i0.ɵɵgetCurrentView();
|
|
52
|
-
i0.ɵɵelementStart(0, "div", 1)(1, "mat-toolbar", 3)(2, "button", 4);
|
|
53
|
-
i0.ɵɵlistener("click", function MissingFormConfigsComponent_Conditional_1_Template_button_click_2_listener() { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.hideDetails = true); });
|
|
54
|
-
i0.ɵɵelementStart(3, "mat-icon");
|
|
55
|
-
i0.ɵɵtext(4, " close ");
|
|
56
|
-
i0.ɵɵelementEnd()();
|
|
57
|
-
i0.ɵɵtext(5, " Missing configurations: ");
|
|
58
|
-
i0.ɵɵelement(6, "span", 5);
|
|
59
|
-
i0.ɵɵelementStart(7, "button", 6);
|
|
60
|
-
i0.ɵɵlistener("click", function MissingFormConfigsComponent_Conditional_1_Template_button_click_7_listener() { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.showAllErrors = !ctx_r1.showAllErrors); });
|
|
61
|
-
i0.ɵɵelementStart(8, "mat-icon");
|
|
62
|
-
i0.ɵɵtext(9, " unfold_more ");
|
|
63
|
-
i0.ɵɵelementEnd()()();
|
|
64
|
-
i0.ɵɵelementStart(10, "section", 7)(11, "h5")(12, "strong");
|
|
65
|
-
i0.ɵɵtext(13, " Overall form issues: ");
|
|
66
|
-
i0.ɵɵelementEnd()();
|
|
67
|
-
i0.ɵɵelementStart(14, "ul");
|
|
68
|
-
i0.ɵɵrepeaterCreate(15, MissingFormConfigsComponent_Conditional_1_For_16_Template, 2, 1, "li", null, i0.ɵɵrepeaterTrackByIdentity);
|
|
69
|
-
i0.ɵɵpipe(17, "async");
|
|
70
|
-
i0.ɵɵelementEnd();
|
|
71
|
-
i0.ɵɵtemplate(18, MissingFormConfigsComponent_Conditional_1_Conditional_18_Template, 7, 2);
|
|
72
|
-
i0.ɵɵelementEnd()();
|
|
73
|
-
} if (rf & 2) {
|
|
74
|
-
const ctx_r1 = i0.ɵɵnextContext();
|
|
75
|
-
i0.ɵɵadvance(7);
|
|
76
|
-
i0.ɵɵproperty("matTooltip", ctx_r1.showAllErrors ? "Hide all errors" : "Show all errors");
|
|
77
|
-
i0.ɵɵadvance(8);
|
|
78
|
-
i0.ɵɵrepeater(i0.ɵɵpipeBind1(17, 2, ctx_r1.missingConfigs$));
|
|
79
|
-
i0.ɵɵadvance(3);
|
|
80
|
-
i0.ɵɵconditional(ctx_r1.showAllErrors ? 18 : -1);
|
|
81
|
-
} }
|
|
82
|
-
class MissingFormConfigsComponent {
|
|
83
|
-
constructor(store) {
|
|
84
|
-
this.store = store;
|
|
85
|
-
this.errors$ = this.store.formBuilderSelectors.formValidationErrorsMessages$;
|
|
86
|
-
this.missingConfigs$ = this.store.formBuilderSelectors.missingConfig$;
|
|
87
|
-
this.hideDetails = true;
|
|
88
|
-
this.showAllErrors = false;
|
|
89
|
-
}
|
|
90
|
-
static { this.ɵfac = function MissingFormConfigsComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || MissingFormConfigsComponent)(i0.ɵɵdirectiveInject(FormsStoreService)); }; }
|
|
91
|
-
static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: MissingFormConfigsComponent, selectors: [["app-missing-form-configs"]], decls: 2, vars: 1, consts: [["matTooltip", "Click to view form configuration issues and validation errors", "mat-fab", "", "color", "warn", "aria-label", "Error icon", 2, "margin", "16px"], [1, "content", 2, "margin", "8px", "position", "relative"], ["matTooltip", "Click to view form configuration issues and validation errors", "mat-fab", "", "color", "warn", "aria-label", "Error icon", 2, "margin", "16px", 3, "click"], ["color", "warn"], ["mat-icon-button", "", 3, "click"], [1, "spacer"], ["mat-icon-button", "", 3, "click", "matTooltip"], [2, "padding", "16px"]], template: function MissingFormConfigsComponent_Template(rf, ctx) { if (rf & 1) {
|
|
92
|
-
i0.ɵɵtemplate(0, MissingFormConfigsComponent_Conditional_0_Template, 3, 0, "button", 0)(1, MissingFormConfigsComponent_Conditional_1_Template, 19, 4, "div", 1);
|
|
93
|
-
} if (rf & 2) {
|
|
94
|
-
i0.ɵɵconditional(ctx.hideDetails ? 0 : 1);
|
|
95
|
-
} }, dependencies: [MatModulesModule, i2.MatIconButton, i2.MatFabButton, i6.MatIcon, i9.MatToolbar, i8.MatTooltip, CommonModule, i2$1.AsyncPipe], styles: [".content[_ngcontent-%COMP%]{width:400px;background:var(--mat-toolbar-container-background-color, var(--mat-app-surface));border:solid var(--mat-form-field-error-text-color, var(--mat-app-error)) 1px}ul[_ngcontent-%COMP%]{margin-top:0}h5[_ngcontent-%COMP%]{padding-left:16px;padding-right:16px;padding-top:8px}"] }); }
|
|
96
|
-
}
|
|
97
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(MissingFormConfigsComponent, [{
|
|
98
|
-
type: Component,
|
|
99
|
-
args: [{ selector: 'app-missing-form-configs', standalone: true, imports: [MatModulesModule, CommonModule], template: "@if (hideDetails) {\r\n<button \r\nmatTooltip=\"Click to view form configuration issues and validation errors\"\r\nstyle=\"margin: 16px;\" (click)=\"hideDetails = false\" mat-fab color=\"warn\" aria-label=\"Error icon\">\r\n <mat-icon>error</mat-icon>\r\n</button>\r\n}@else {\r\n<div style=\"margin: 8px;position:relative\" class=\"content \">\r\n <mat-toolbar color=\"warn\">\r\n <button (click)=\" hideDetails = true\" mat-icon-button>\r\n <mat-icon>\r\n close\r\n </mat-icon>\r\n </button>\r\n Missing configurations:\r\n <span class=\"spacer\"></span>\r\n <button [matTooltip]=\"showAllErrors?'Hide all errors':'Show all errors'\"\r\n (click)=\"showAllErrors = !showAllErrors\" mat-icon-button>\r\n\r\n <mat-icon>\r\n unfold_more\r\n </mat-icon>\r\n </button>\r\n </mat-toolbar>\r\n <section style=\"padding: 16px;\" >\r\n <h5>\r\n <strong>\r\n Overall form issues:\r\n </strong>\r\n </h5>\r\n <ul>\r\n @for (issue of (missingConfigs$|async);track issue) {\r\n <li>\r\n {{issue}}\r\n </li>\r\n }\r\n </ul>\r\n\r\n @if(showAllErrors){\r\n <h5>\r\n <strong>\r\n\r\n Form validationErrors :\r\n\r\n </strong>\r\n\r\n\r\n </h5>\r\n <ul>\r\n @for (error of errors$|async; track error) {\r\n\r\n <li>\r\n\r\n {{error}}\r\n\r\n </li>\r\n\r\n }\r\n </ul>\r\n }\r\n\r\n\r\n\r\n\r\n\r\n </section>\r\n\r\n</div>\r\n}", styles: [".content{width:400px;background:var(--mat-toolbar-container-background-color, var(--mat-app-surface));border:solid var(--mat-form-field-error-text-color, var(--mat-app-error)) 1px}ul{margin-top:0}h5{padding-left:16px;padding-right:16px;padding-top:8px}\n"] }]
|
|
100
|
-
}], () => [{ type: FormsStoreService }], null); })();
|
|
101
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(MissingFormConfigsComponent, { className: "MissingFormConfigsComponent", filePath: "lib/components/form-builder/elements/missing-form-configs/missing-form-configs.component.ts", lineNumber: 16 }); })();
|
|
102
|
-
|
|
103
|
-
export { MissingFormConfigsComponent };
|
|
104
|
-
//# sourceMappingURL=ngx-t-forms-missing-form-configs.component-DNkGCH0e.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-t-forms-missing-form-configs.component-DNkGCH0e.mjs","sources":["../../../projects/ngx-t-forms/src/lib/components/form-builder/elements/missing-form-configs/missing-form-configs.component.html","../../../projects/ngx-t-forms/src/lib/components/form-builder/elements/missing-form-configs/missing-form-configs.component.ts"],"sourcesContent":["@if (hideDetails) {\r\n<button \r\nmatTooltip=\"Click to view form configuration issues and validation errors\"\r\nstyle=\"margin: 16px;\" (click)=\"hideDetails = false\" mat-fab color=\"warn\" aria-label=\"Error icon\">\r\n <mat-icon>error</mat-icon>\r\n</button>\r\n}@else {\r\n<div style=\"margin: 8px;position:relative\" class=\"content \">\r\n <mat-toolbar color=\"warn\">\r\n <button (click)=\" hideDetails = true\" mat-icon-button>\r\n <mat-icon>\r\n close\r\n </mat-icon>\r\n </button>\r\n Missing configurations:\r\n <span class=\"spacer\"></span>\r\n <button [matTooltip]=\"showAllErrors?'Hide all errors':'Show all errors'\"\r\n (click)=\"showAllErrors = !showAllErrors\" mat-icon-button>\r\n\r\n <mat-icon>\r\n unfold_more\r\n </mat-icon>\r\n </button>\r\n </mat-toolbar>\r\n <section style=\"padding: 16px;\" >\r\n <h5>\r\n <strong>\r\n Overall form issues:\r\n </strong>\r\n </h5>\r\n <ul>\r\n @for (issue of (missingConfigs$|async);track issue) {\r\n <li>\r\n {{issue}}\r\n </li>\r\n }\r\n </ul>\r\n\r\n @if(showAllErrors){\r\n <h5>\r\n <strong>\r\n\r\n Form validationErrors :\r\n\r\n </strong>\r\n\r\n\r\n </h5>\r\n <ul>\r\n @for (error of errors$|async; track error) {\r\n\r\n <li>\r\n\r\n {{error}}\r\n\r\n </li>\r\n\r\n }\r\n </ul>\r\n }\r\n\r\n\r\n\r\n\r\n\r\n </section>\r\n\r\n</div>\r\n}","import { Component } from '@angular/core';\r\nimport { MatModulesModule } from '../../../../shared/modules/mat-modules.module';\r\n\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsStoreService } from '../../../forms/store/forms-store.service';\r\n\r\n\r\n\r\n@Component({\r\n selector: 'app-missing-form-configs',\r\n standalone: true,\r\n imports: [MatModulesModule, CommonModule],\r\n templateUrl: './missing-form-configs.component.html',\r\n styleUrl: './missing-form-configs.component.scss'\r\n})\r\nexport class MissingFormConfigsComponent {\r\n errors$ = this.store.formBuilderSelectors.formValidationErrorsMessages$\r\n missingConfigs$ = this.store.formBuilderSelectors.missingConfig$\r\n constructor(private store: FormsStoreService) { }\r\n hideDetails: boolean = true;\r\n showAllErrors: boolean = false\r\n\r\n}\r\n"],"names":["i1.FormsStoreService","i6"],"mappings":";;;;;;;;;;;;IACA,EAEiG,CAAA,cAAA,CAAA,CAAA,EAAA,QAAA,EAAA,CAAA,CAAA;AAA3E,IAAA,EAAA,CAAA,UAAA,CAAA,OAAA,EAAA,SAAA,0EAAA,GAAA,EAAA,EAAA,CAAA,aAAA,CAAA,GAAA,CAAA,CAAA,CAAA,MAAA,MAAA,GAAA,EAAA,CAAA,aAAA,EAAA,CAAA,CAAA,OAAA,EAAA,CAAA,WAAA,CAAA,MAAA,CAAA,WAAA,GAAuB,KAAK,CAAC,CAAA,EAAA,CAAA;IAC/C,EAAU,CAAA,cAAA,CAAA,CAAA,EAAA,UAAA,CAAA;IAAA,EAAK,CAAA,MAAA,CAAA,CAAA,EAAA,OAAA,CAAA;AACnB,IADmB,iBAAW,EACrB;;;IA2BG,EAAI,CAAA,cAAA,CAAA,CAAA,EAAA,IAAA,CAAA;IACA,EACJ,CAAA,MAAA,CAAA,CAAA,CAAA;IAAA,EAAK,CAAA,YAAA,EAAA;;;IADD,EACJ,CAAA,SAAA,EAAA;IADI,EACJ,CAAA,kBAAA,CAAA,GAAA,EAAA,QAAA,EA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
-
import { CommonModule } from '@angular/common';
|
|
3
|
-
import * as i0 from '@angular/core';
|
|
4
|
-
import { EventEmitter, Component, Optional, Self, Output, Input, HostBinding } from '@angular/core';
|
|
5
|
-
import * as i1 from '@angular/forms';
|
|
6
|
-
import { Validators, ReactiveFormsModule, FormsModule } from '@angular/forms';
|
|
7
|
-
import { Subject, BehaviorSubject, take, tap, catchError, takeUntil } from 'rxjs';
|
|
8
|
-
import { M as MatModulesModule } from './ngx-t-forms-ngx-t-forms-DaAFB-HX.mjs';
|
|
9
|
-
import * as i3$2 from '@angular/material/form-field';
|
|
10
|
-
import { MatFormFieldControl } from '@angular/material/form-field';
|
|
11
|
-
import { v4 } from 'uuid';
|
|
12
|
-
import * as i3 from '@angular/material/core';
|
|
13
|
-
import * as i2$1 from '@angular/material/button';
|
|
14
|
-
import * as i3$1 from '@angular/material/card';
|
|
15
|
-
import * as i4 from '@angular/material/chips';
|
|
16
|
-
import * as i6 from '@angular/material/icon';
|
|
17
|
-
import * as i7 from '@angular/material/select';
|
|
18
|
-
import * as i2$2 from '@angular/material/slide-toggle';
|
|
19
|
-
import * as i9 from '@angular/material/toolbar';
|
|
20
|
-
import * as i12 from '@angular/material/input';
|
|
21
|
-
|
|
22
|
-
const _c0 = () => [];
|
|
23
|
-
const _forTrack0 = ($index, $item) => $item.segment;
|
|
24
|
-
function MscoaSegmentConfigComponent_div_0_Template(rf, ctx) { if (rf & 1) {
|
|
25
|
-
i0.ɵɵelementStart(0, "div", 4)(1, "mat-icon", 6);
|
|
26
|
-
i0.ɵɵtext(2, "info");
|
|
27
|
-
i0.ɵɵelementEnd();
|
|
28
|
-
i0.ɵɵelementStart(3, "span");
|
|
29
|
-
i0.ɵɵtext(4, "SCOA Segments Configuration");
|
|
30
|
-
i0.ɵɵelementEnd()();
|
|
31
|
-
} }
|
|
32
|
-
function MscoaSegmentConfigComponent_mat_chip_listbox_1_For_2_Conditional_8_Template(rf, ctx) { if (rf & 1) {
|
|
33
|
-
i0.ɵɵelementStart(0, "button", 13)(1, "mat-icon");
|
|
34
|
-
i0.ɵɵtext(2, "cancel");
|
|
35
|
-
i0.ɵɵelementEnd()();
|
|
36
|
-
} if (rf & 2) {
|
|
37
|
-
i0.ɵɵattribute("aria-label", "remove");
|
|
38
|
-
} }
|
|
39
|
-
function MscoaSegmentConfigComponent_mat_chip_listbox_1_For_2_Template(rf, ctx) { if (rf & 1) {
|
|
40
|
-
const _r1 = i0.ɵɵgetCurrentView();
|
|
41
|
-
i0.ɵɵelementStart(0, "mat-chip-option", 9);
|
|
42
|
-
i0.ɵɵlistener("removed", function MscoaSegmentConfigComponent_mat_chip_listbox_1_For_2_Template_mat_chip_option_removed_0_listener() { const $index_r2 = i0.ɵɵrestoreView(_r1).$index; const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.removeSegment($index_r2)); })("click", function MscoaSegmentConfigComponent_mat_chip_listbox_1_For_2_Template_mat_chip_option_click_0_listener() { const $index_r2 = i0.ɵɵrestoreView(_r1).$index; const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.startEdit($index_r2)); });
|
|
43
|
-
i0.ɵɵelementStart(1, "div", 10)(2, "span", 11);
|
|
44
|
-
i0.ɵɵtext(3);
|
|
45
|
-
i0.ɵɵelementEnd();
|
|
46
|
-
i0.ɵɵelementStart(4, "mat-icon", 12);
|
|
47
|
-
i0.ɵɵtext(5);
|
|
48
|
-
i0.ɵɵelementEnd();
|
|
49
|
-
i0.ɵɵelementStart(6, "mat-icon", 12);
|
|
50
|
-
i0.ɵɵtext(7);
|
|
51
|
-
i0.ɵɵelementEnd()();
|
|
52
|
-
i0.ɵɵtemplate(8, MscoaSegmentConfigComponent_mat_chip_listbox_1_For_2_Conditional_8_Template, 3, 1, "button", 13);
|
|
53
|
-
i0.ɵɵelementEnd();
|
|
54
|
-
} if (rf & 2) {
|
|
55
|
-
const segment_r4 = ctx.$implicit;
|
|
56
|
-
const $index_r2 = ctx.$index;
|
|
57
|
-
const ctx_r2 = i0.ɵɵnextContext(2);
|
|
58
|
-
i0.ɵɵproperty("value", segment_r4 == null ? null : segment_r4.segment)("selected", ctx_r2.editingIndex === $index_r2);
|
|
59
|
-
i0.ɵɵadvance(3);
|
|
60
|
-
i0.ɵɵtextInterpolate1(" ", segment_r4.label, " ");
|
|
61
|
-
i0.ɵɵadvance(2);
|
|
62
|
-
i0.ɵɵtextInterpolate1(" ", segment_r4.singleSelect ? "done" : " done_all", " ");
|
|
63
|
-
i0.ɵɵadvance(2);
|
|
64
|
-
i0.ɵɵtextInterpolate1(" ", segment_r4.readOnly ? "edit_off" : "edit", " ");
|
|
65
|
-
i0.ɵɵadvance();
|
|
66
|
-
i0.ɵɵconditional(ctx_r2.showAllSegments === false ? 8 : -1);
|
|
67
|
-
} }
|
|
68
|
-
function MscoaSegmentConfigComponent_mat_chip_listbox_1_Template(rf, ctx) { if (rf & 1) {
|
|
69
|
-
i0.ɵɵelementStart(0, "mat-chip-listbox", 7);
|
|
70
|
-
i0.ɵɵrepeaterCreate(1, MscoaSegmentConfigComponent_mat_chip_listbox_1_For_2_Template, 9, 6, "mat-chip-option", 8, _forTrack0);
|
|
71
|
-
i0.ɵɵelementEnd();
|
|
72
|
-
} if (rf & 2) {
|
|
73
|
-
const ctx_r2 = i0.ɵɵnextContext();
|
|
74
|
-
i0.ɵɵadvance();
|
|
75
|
-
i0.ɵɵrepeater(ctx_r2.value || i0.ɵɵpureFunction0(0, _c0));
|
|
76
|
-
} }
|
|
77
|
-
function MscoaSegmentConfigComponent_ng_template_2_Template(rf, ctx) { if (rf & 1) {
|
|
78
|
-
i0.ɵɵelementStart(0, "div", 4)(1, "mat-icon", 6);
|
|
79
|
-
i0.ɵɵtext(2, "info");
|
|
80
|
-
i0.ɵɵelementEnd();
|
|
81
|
-
i0.ɵɵelementStart(3, "span");
|
|
82
|
-
i0.ɵɵtext(4, "No segment configuration available. Start by adding a segment below.");
|
|
83
|
-
i0.ɵɵelementEnd()();
|
|
84
|
-
} }
|
|
85
|
-
function MscoaSegmentConfigComponent_mat_toolbar_4_Template(rf, ctx) { if (rf & 1) {
|
|
86
|
-
const _r5 = i0.ɵɵgetCurrentView();
|
|
87
|
-
i0.ɵɵelementStart(0, "mat-toolbar")(1, "button", 14);
|
|
88
|
-
i0.ɵɵlistener("click", function MscoaSegmentConfigComponent_mat_toolbar_4_Template_button_click_1_listener() { i0.ɵɵrestoreView(_r5); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.startAddNew()); });
|
|
89
|
-
i0.ɵɵtext(2, " Add New Segment ");
|
|
90
|
-
i0.ɵɵelementStart(3, "mat-icon");
|
|
91
|
-
i0.ɵɵtext(4, "add");
|
|
92
|
-
i0.ɵɵelementEnd()()();
|
|
93
|
-
} }
|
|
94
|
-
function MscoaSegmentConfigComponent_Conditional_5_Template(rf, ctx) { if (rf & 1) {
|
|
95
|
-
i0.ɵɵelementStart(0, "div", 4)(1, "mat-icon", 6);
|
|
96
|
-
i0.ɵɵtext(2, "info");
|
|
97
|
-
i0.ɵɵelementEnd();
|
|
98
|
-
i0.ɵɵelementStart(3, "span");
|
|
99
|
-
i0.ɵɵtext(4);
|
|
100
|
-
i0.ɵɵelementEnd()();
|
|
101
|
-
} if (rf & 2) {
|
|
102
|
-
const ctx_r2 = i0.ɵɵnextContext();
|
|
103
|
-
i0.ɵɵadvance(4);
|
|
104
|
-
i0.ɵɵtextInterpolate1(" ", ctx_r2.getMscoaError, " ");
|
|
105
|
-
} }
|
|
106
|
-
function MscoaSegmentConfigComponent_mat_card_6_For_16_Template(rf, ctx) { if (rf & 1) {
|
|
107
|
-
i0.ɵɵelementStart(0, "mat-option", 21);
|
|
108
|
-
i0.ɵɵtext(1);
|
|
109
|
-
i0.ɵɵelementEnd();
|
|
110
|
-
} if (rf & 2) {
|
|
111
|
-
const segment_r7 = ctx.$implicit;
|
|
112
|
-
const ctx_r2 = i0.ɵɵnextContext(2);
|
|
113
|
-
i0.ɵɵproperty("disabled", ctx_r2.alreadyExists(segment_r7))("value", segment_r7.segment);
|
|
114
|
-
i0.ɵɵadvance();
|
|
115
|
-
i0.ɵɵtextInterpolate1(" ", segment_r7.label, " ");
|
|
116
|
-
} }
|
|
117
|
-
function MscoaSegmentConfigComponent_mat_card_6_Template(rf, ctx) { if (rf & 1) {
|
|
118
|
-
const _r6 = i0.ɵɵgetCurrentView();
|
|
119
|
-
i0.ɵɵelementStart(0, "mat-card")(1, "mat-card-header")(2, "mat-card-subtitle");
|
|
120
|
-
i0.ɵɵtext(3);
|
|
121
|
-
i0.ɵɵelementEnd()();
|
|
122
|
-
i0.ɵɵelementStart(4, "mat-card-content")(5, "form", 15);
|
|
123
|
-
i0.ɵɵlistener("ngSubmit", function MscoaSegmentConfigComponent_mat_card_6_Template_form_ngSubmit_5_listener() { i0.ɵɵrestoreView(_r6); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.saveSegment()); });
|
|
124
|
-
i0.ɵɵelementStart(6, "mat-toolbar", 16)(7, "mat-slide-toggle", 17);
|
|
125
|
-
i0.ɵɵlistener("change", function MscoaSegmentConfigComponent_mat_card_6_Template_mat_slide_toggle_change_7_listener($event) { i0.ɵɵrestoreView(_r6); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.multiLevelSelectChange($event)); });
|
|
126
|
-
i0.ɵɵtext(8, " Enable Multi-Level Segmentation ");
|
|
127
|
-
i0.ɵɵelementEnd()();
|
|
128
|
-
i0.ɵɵelementStart(9, "mat-hint", 18);
|
|
129
|
-
i0.ɵɵtext(10, " This allows sub-classifications within this segment for more detailed accounting hierarchies ");
|
|
130
|
-
i0.ɵɵelementEnd();
|
|
131
|
-
i0.ɵɵelementStart(11, "mat-form-field", 19)(12, "mat-label");
|
|
132
|
-
i0.ɵɵtext(13, "Segment");
|
|
133
|
-
i0.ɵɵelementEnd();
|
|
134
|
-
i0.ɵɵelementStart(14, "mat-select", 20);
|
|
135
|
-
i0.ɵɵlistener("selectionChange", function MscoaSegmentConfigComponent_mat_card_6_Template_mat_select_selectionChange_14_listener($event) { i0.ɵɵrestoreView(_r6); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.selectSegment($event)); });
|
|
136
|
-
i0.ɵɵrepeaterCreate(15, MscoaSegmentConfigComponent_mat_card_6_For_16_Template, 2, 3, "mat-option", 21, _forTrack0);
|
|
137
|
-
i0.ɵɵelementEnd()();
|
|
138
|
-
i0.ɵɵelementStart(17, "mat-hint", 18);
|
|
139
|
-
i0.ɵɵtext(18, " Select an account segment type from your chart of accounts ");
|
|
140
|
-
i0.ɵɵelementEnd();
|
|
141
|
-
i0.ɵɵelementStart(19, "mat-form-field", 19)(20, "mat-label");
|
|
142
|
-
i0.ɵɵtext(21, "Label");
|
|
143
|
-
i0.ɵɵelementEnd();
|
|
144
|
-
i0.ɵɵelement(22, "input", 22);
|
|
145
|
-
i0.ɵɵelementStart(23, "mat-hint");
|
|
146
|
-
i0.ɵɵtext(24, "Provide a descriptive name for this segment (e.g., 'Department', 'Project', 'Cost Center')");
|
|
147
|
-
i0.ɵɵelementEnd()();
|
|
148
|
-
i0.ɵɵelementStart(25, "mat-toolbar", 16)(26, "mat-slide-toggle", 17);
|
|
149
|
-
i0.ɵɵlistener("change", function MscoaSegmentConfigComponent_mat_card_6_Template_mat_slide_toggle_change_26_listener($event) { i0.ɵɵrestoreView(_r6); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.singleSelectChange($event)); });
|
|
150
|
-
i0.ɵɵtext(27, " Single Value Selection ");
|
|
151
|
-
i0.ɵɵelementEnd()();
|
|
152
|
-
i0.ɵɵelementStart(28, "mat-hint", 18);
|
|
153
|
-
i0.ɵɵtext(29, " When enabled, transactions can only be assigned to one value within this segment. When disabled, transactions can be split across multiple values. ");
|
|
154
|
-
i0.ɵɵelementEnd();
|
|
155
|
-
i0.ɵɵelementStart(30, "mat-toolbar", 16)(31, "mat-slide-toggle", 17);
|
|
156
|
-
i0.ɵɵlistener("change", function MscoaSegmentConfigComponent_mat_card_6_Template_mat_slide_toggle_change_31_listener($event) { i0.ɵɵrestoreView(_r6); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.readOnly($event)); });
|
|
157
|
-
i0.ɵɵtext(32, " Read-Only Segment ");
|
|
158
|
-
i0.ɵɵelementEnd()();
|
|
159
|
-
i0.ɵɵelementStart(33, "mat-hint", 18);
|
|
160
|
-
i0.ɵɵtext(34, " Prevents users from modifying segment values after initial setup. Use for regulatory or policy-controlled segments. ");
|
|
161
|
-
i0.ɵɵelementEnd();
|
|
162
|
-
i0.ɵɵelement(35, "br");
|
|
163
|
-
i0.ɵɵelementStart(36, "mat-card-actions")(37, "button", 23);
|
|
164
|
-
i0.ɵɵtext(38, "Save");
|
|
165
|
-
i0.ɵɵelementEnd();
|
|
166
|
-
i0.ɵɵelementStart(39, "button", 24);
|
|
167
|
-
i0.ɵɵlistener("click", function MscoaSegmentConfigComponent_mat_card_6_Template_button_click_39_listener() { i0.ɵɵrestoreView(_r6); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.cancelEdit()); });
|
|
168
|
-
i0.ɵɵtext(40, "Cancel");
|
|
169
|
-
i0.ɵɵelementEnd()()()()();
|
|
170
|
-
} if (rf & 2) {
|
|
171
|
-
const ctx_r2 = i0.ɵɵnextContext();
|
|
172
|
-
i0.ɵɵadvance(3);
|
|
173
|
-
i0.ɵɵtextInterpolate1(" ", ctx_r2.isAddingNew ? "Add a new" : "Update", " Segment ");
|
|
174
|
-
i0.ɵɵadvance(2);
|
|
175
|
-
i0.ɵɵproperty("formGroup", ctx_r2.segmentForm);
|
|
176
|
-
i0.ɵɵadvance(2);
|
|
177
|
-
i0.ɵɵproperty("checked", ctx_r2.segmentForm.value.segmentExtension);
|
|
178
|
-
i0.ɵɵadvance(7);
|
|
179
|
-
i0.ɵɵproperty("value", ctx_r2.value);
|
|
180
|
-
i0.ɵɵadvance();
|
|
181
|
-
i0.ɵɵrepeater(ctx_r2.treeSegments);
|
|
182
|
-
i0.ɵɵadvance(7);
|
|
183
|
-
i0.ɵɵproperty("disabled", !ctx_r2.segmentForm.value.segmentExtension);
|
|
184
|
-
i0.ɵɵadvance(4);
|
|
185
|
-
i0.ɵɵproperty("checked", ctx_r2.segmentForm.value.singleSelect);
|
|
186
|
-
i0.ɵɵadvance(5);
|
|
187
|
-
i0.ɵɵproperty("checked", ctx_r2.segmentForm.value.readOnly);
|
|
188
|
-
i0.ɵɵadvance(6);
|
|
189
|
-
i0.ɵɵproperty("disabled", !ctx_r2.segmentForm.valid);
|
|
190
|
-
} }
|
|
191
|
-
function MscoaSegmentConfigComponent_span_7_Template(rf, ctx) { if (rf & 1) {
|
|
192
|
-
i0.ɵɵelementStart(0, "span", 25)(1, "p");
|
|
193
|
-
i0.ɵɵtext(2);
|
|
194
|
-
i0.ɵɵelementEnd()();
|
|
195
|
-
} if (rf & 2) {
|
|
196
|
-
const error_r8 = ctx.ngIf;
|
|
197
|
-
i0.ɵɵadvance(2);
|
|
198
|
-
i0.ɵɵtextInterpolate(error_r8);
|
|
199
|
-
} }
|
|
200
|
-
class MscoaSegmentConfigComponent {
|
|
201
|
-
static { this.nextId = 0; }
|
|
202
|
-
constructor(fb, ngControl, _elementRef) {
|
|
203
|
-
this.fb = fb;
|
|
204
|
-
this.ngControl = ngControl;
|
|
205
|
-
this._elementRef = _elementRef;
|
|
206
|
-
this.stateChanges = new Subject();
|
|
207
|
-
this.id = `app-mscoa-segment-config'-${MscoaSegmentConfigComponent.nextId++}`;
|
|
208
|
-
this.placeholder = '';
|
|
209
|
-
this.focused = false;
|
|
210
|
-
this.required = false;
|
|
211
|
-
this.disabled = false;
|
|
212
|
-
this.touched = false;
|
|
213
|
-
this.onTouched = () => { };
|
|
214
|
-
this.errors = [];
|
|
215
|
-
this._showAllSegments = false;
|
|
216
|
-
this.valueChanged = new EventEmitter();
|
|
217
|
-
this._value = new BehaviorSubject([]);
|
|
218
|
-
this.destroy$ = new Subject();
|
|
219
|
-
this.error$ = new BehaviorSubject(null);
|
|
220
|
-
this.editingIndex = null;
|
|
221
|
-
this.isAddingNew = false;
|
|
222
|
-
this.getMscoaError = undefined;
|
|
223
|
-
this.segmentForm = this.createSegmentForm();
|
|
224
|
-
}
|
|
225
|
-
get empty() {
|
|
226
|
-
return !this.value;
|
|
227
|
-
}
|
|
228
|
-
get shouldLabelFloat() {
|
|
229
|
-
return this.focused || !this.empty;
|
|
230
|
-
}
|
|
231
|
-
get errorState() {
|
|
232
|
-
const hasError = !!this.ngControl?.control?.errors || (this.errors || []).length > 0 && this.touched;
|
|
233
|
-
return !this.value && !!this.required || hasError;
|
|
234
|
-
}
|
|
235
|
-
setDescribedByIds(ids) {
|
|
236
|
-
// Ensure the component view is initialized
|
|
237
|
-
if (this._elementRef && this._elementRef.nativeElement) {
|
|
238
|
-
const controlElement = this._elementRef.nativeElement.querySelector('.app-mscoa-segment-config');
|
|
239
|
-
// Check if the controlElement exists before attempting to set its attribute
|
|
240
|
-
if (controlElement) {
|
|
241
|
-
controlElement.setAttribute('aria-describedby', ids.join(' '));
|
|
242
|
-
}
|
|
243
|
-
}
|
|
244
|
-
}
|
|
245
|
-
onContainerClick(event) {
|
|
246
|
-
this.markAsTouched();
|
|
247
|
-
this.stateChanges.next();
|
|
248
|
-
}
|
|
249
|
-
markAsTouched() {
|
|
250
|
-
console.log('markAsTouched');
|
|
251
|
-
if (!this.touched) {
|
|
252
|
-
this.onTouched();
|
|
253
|
-
this.touched = true;
|
|
254
|
-
}
|
|
255
|
-
}
|
|
256
|
-
set value(val) {
|
|
257
|
-
this._value.next(val || []);
|
|
258
|
-
}
|
|
259
|
-
get value() {
|
|
260
|
-
return this._value.value;
|
|
261
|
-
}
|
|
262
|
-
set showAllSegments(val) {
|
|
263
|
-
if (!!val) {
|
|
264
|
-
this.checkShowAllSegments();
|
|
265
|
-
}
|
|
266
|
-
this._showAllSegments = !!val;
|
|
267
|
-
}
|
|
268
|
-
get showAllSegments() {
|
|
269
|
-
return this._showAllSegments;
|
|
270
|
-
}
|
|
271
|
-
set getMscoaTree(options$) {
|
|
272
|
-
if (!!options$ && this._getMscoaTree === undefined) {
|
|
273
|
-
this.getMscoaError = undefined;
|
|
274
|
-
this._getMscoaTree = options$;
|
|
275
|
-
this.loadMscoa();
|
|
276
|
-
}
|
|
277
|
-
else if (!options$) {
|
|
278
|
-
this.getMscoaError = 'No loader provided';
|
|
279
|
-
}
|
|
280
|
-
}
|
|
281
|
-
ngOnInit() {
|
|
282
|
-
this.listenToFormChanges();
|
|
283
|
-
}
|
|
284
|
-
ngOnDestroy() {
|
|
285
|
-
this.destroy$.next();
|
|
286
|
-
this.destroy$.complete();
|
|
287
|
-
}
|
|
288
|
-
loadMscoa() {
|
|
289
|
-
this._getMscoaTree?.pipe(take(1), tap((options) => {
|
|
290
|
-
this.mscoaTree = options;
|
|
291
|
-
this.treeSegments = options?.accountTreeKeys?.map((treeKey) => ({
|
|
292
|
-
id: v4(),
|
|
293
|
-
segment: treeKey,
|
|
294
|
-
singleSelect: true,
|
|
295
|
-
segmentExtension: false,
|
|
296
|
-
label: this.toTitleCase(treeKey),
|
|
297
|
-
readOnly: this.value.find((v) => v.segment === treeKey)?.readOnly || false,
|
|
298
|
-
})) || [];
|
|
299
|
-
}), catchError((error) => {
|
|
300
|
-
this.getMscoaError = 'Failed to fetch mscoa tree';
|
|
301
|
-
console.error('Error while fetching SCOA tree:', error);
|
|
302
|
-
return [null];
|
|
303
|
-
})).subscribe();
|
|
304
|
-
}
|
|
305
|
-
createSegmentForm(segment = {
|
|
306
|
-
segment: '', label: '',
|
|
307
|
-
id: v4(),
|
|
308
|
-
singleSelect: true,
|
|
309
|
-
segmentExtension: false,
|
|
310
|
-
readOnly: false
|
|
311
|
-
}) {
|
|
312
|
-
return this.fb.group({
|
|
313
|
-
segment: [segment.segment, Validators.required],
|
|
314
|
-
segmentExtension: [segment.segmentExtension, Validators.required],
|
|
315
|
-
readOnly: [segment.readOnly, Validators.required],
|
|
316
|
-
label: [segment.label, Validators.required],
|
|
317
|
-
singleSelect: [segment.singleSelect, Validators.required]
|
|
318
|
-
});
|
|
319
|
-
}
|
|
320
|
-
listenToFormChanges() {
|
|
321
|
-
this.segmentForm.valueChanges
|
|
322
|
-
.pipe(takeUntil(this.destroy$))
|
|
323
|
-
.subscribe((v) => console.log(v));
|
|
324
|
-
}
|
|
325
|
-
startAddNew() {
|
|
326
|
-
this.isAddingNew = true;
|
|
327
|
-
this.editingIndex = null;
|
|
328
|
-
this.segmentForm = this.createSegmentForm();
|
|
329
|
-
}
|
|
330
|
-
startEdit(index) {
|
|
331
|
-
this.editingIndex = index;
|
|
332
|
-
this.isAddingNew = false;
|
|
333
|
-
this.segmentForm = this.createSegmentForm(this.value[index]);
|
|
334
|
-
}
|
|
335
|
-
cancelEdit() {
|
|
336
|
-
this.editingIndex = null;
|
|
337
|
-
this.isAddingNew = false;
|
|
338
|
-
this.segmentForm.reset();
|
|
339
|
-
}
|
|
340
|
-
saveSegment() {
|
|
341
|
-
if (this.segmentForm.valid) {
|
|
342
|
-
const newSegment = ({
|
|
343
|
-
id: this.segmentForm.value.id || v4(),
|
|
344
|
-
segment: this.segmentForm.value.segment,
|
|
345
|
-
customSegment: !!this.segmentForm.value.segmentExtension ? this.segmentForm.value.label?.toLocaleUpperCase() : undefined,
|
|
346
|
-
segmentExtension: this.segmentForm.value.segmentExtension,
|
|
347
|
-
label: this.toTitleCase(this.segmentForm.value.label),
|
|
348
|
-
singleSelect: this.segmentForm.value.singleSelect,
|
|
349
|
-
readOnly: this.segmentForm.value.readOnly
|
|
350
|
-
});
|
|
351
|
-
const updatedValue = [...this.value];
|
|
352
|
-
if (this.isAddingNew) {
|
|
353
|
-
updatedValue.push(newSegment);
|
|
354
|
-
}
|
|
355
|
-
else if (this.editingIndex !== null) {
|
|
356
|
-
updatedValue[this.editingIndex] = newSegment;
|
|
357
|
-
}
|
|
358
|
-
this._value.next(updatedValue);
|
|
359
|
-
this.valueChanged.emit(updatedValue);
|
|
360
|
-
this.cancelEdit();
|
|
361
|
-
}
|
|
362
|
-
}
|
|
363
|
-
readOnly(event) {
|
|
364
|
-
this.segmentForm.patchValue({ readOnly: event.checked });
|
|
365
|
-
}
|
|
366
|
-
singleSelectChange(event) {
|
|
367
|
-
this.segmentForm.patchValue({ singleSelect: event.checked });
|
|
368
|
-
console.error('singleSelectChange', this.segmentForm.value);
|
|
369
|
-
}
|
|
370
|
-
removeSegment(index) {
|
|
371
|
-
const updatedValue = this.value.filter((_, i) => i !== index);
|
|
372
|
-
this._value.next(updatedValue);
|
|
373
|
-
this.valueChanged.emit(updatedValue);
|
|
374
|
-
}
|
|
375
|
-
toTitleCase(str) {
|
|
376
|
-
return str.replace(/\w\S*/g, (txt) => txt.charAt(0).toUpperCase() + txt.substr(1).toLowerCase());
|
|
377
|
-
}
|
|
378
|
-
alreadyExists(segment) {
|
|
379
|
-
if (this.segmentForm.value.segmentExtension)
|
|
380
|
-
return false;
|
|
381
|
-
return this.value.find((v) => v.segment === segment.segment);
|
|
382
|
-
}
|
|
383
|
-
checkShowAllSegments() {
|
|
384
|
-
if (!this._getMscoaTree || !this.treeSegments)
|
|
385
|
-
return;
|
|
386
|
-
const updatedValue = this.treeSegments.map(segment => ({
|
|
387
|
-
...segment,
|
|
388
|
-
...(this.value.find(v => v.segment === segment.segment) || {})
|
|
389
|
-
}));
|
|
390
|
-
if (JSON.stringify(updatedValue) !== JSON.stringify(this.value)) {
|
|
391
|
-
this.valueChanged.emit([{}]);
|
|
392
|
-
setTimeout(() => {
|
|
393
|
-
this.valueChanged.emit(updatedValue);
|
|
394
|
-
}, 0);
|
|
395
|
-
}
|
|
396
|
-
}
|
|
397
|
-
selectSegment($event) {
|
|
398
|
-
this.segmentForm.patchValue({ segment: $event.value });
|
|
399
|
-
if (!this.segmentForm.value.segmentExtension) {
|
|
400
|
-
this.segmentForm.patchValue({ label: this.toTitleCase($event.value) });
|
|
401
|
-
}
|
|
402
|
-
}
|
|
403
|
-
multiLevelSelectChange(event) {
|
|
404
|
-
this.segmentForm.patchValue({ segmentExtension: event.checked });
|
|
405
|
-
}
|
|
406
|
-
static { this.ɵfac = function MscoaSegmentConfigComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || MscoaSegmentConfigComponent)(i0.ɵɵdirectiveInject(i1.FormBuilder), i0.ɵɵdirectiveInject(i1.NgControl, 10), i0.ɵɵdirectiveInject(i0.ElementRef)); }; }
|
|
407
|
-
static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: MscoaSegmentConfigComponent, selectors: [["app-mscoa-segment-config"]], hostVars: 1, hostBindings: function MscoaSegmentConfigComponent_HostBindings(rf, ctx) { if (rf & 2) {
|
|
408
|
-
i0.ɵɵhostProperty("id", ctx.id);
|
|
409
|
-
} }, inputs: { errors: "errors", value: "value", showAllSegments: "showAllSegments", getMscoaTree: "getMscoaTree" }, outputs: { valueChanged: "valueChanged" }, features: [i0.ɵɵProvidersFeature([{ provide: MatFormFieldControl, useExisting: MscoaSegmentConfigComponent }])], decls: 9, vars: 10, consts: [["noSegments", ""], ["class", "tree-instructions", 4, "ngIf"], ["aria-label", "Fish selection", 4, "ngIf", "ngIfElse"], [4, "ngIf"], [1, "tree-instructions"], ["color", "danger", 4, "ngIf"], ["color", "primary", 1, "info-icon"], ["aria-label", "Fish selection"], ["color", "accent", 3, "value", "selected"], ["color", "accent", 3, "removed", "click", "value", "selected"], [2, "display", "flex", "align-items", "center", "gap", "1px"], [2, "margin-right", "2px"], [1, "icons"], ["matChipRemove", ""], ["mat-stroked-button", "", 2, "width", "100%", 3, "click"], [3, "ngSubmit", "formGroup"], [1, "segment-toolbar"], [3, "change", "checked"], [1, "segment-hint"], ["subscriptSizing", "dynamic", "floatLabel", "always", "appearance", "outline"], ["matNativeControl", "", "formControlName", "segment", "placeholder", "Select segment", 3, "selectionChange", "value"], [3, "disabled", "value"], ["matInput", "", "formControlName", "label", "placeholder", "Enter label", 3, "disabled"], ["mat-flat-button", "", "color", "primary", "type", "submit", 3, "disabled"], ["mat-button", "", 3, "click"], ["color", "danger"]], template: function MscoaSegmentConfigComponent_Template(rf, ctx) { if (rf & 1) {
|
|
410
|
-
i0.ɵɵtemplate(0, MscoaSegmentConfigComponent_div_0_Template, 5, 0, "div", 1)(1, MscoaSegmentConfigComponent_mat_chip_listbox_1_Template, 3, 1, "mat-chip-listbox", 2)(2, MscoaSegmentConfigComponent_ng_template_2_Template, 5, 0, "ng-template", null, 0, i0.ɵɵtemplateRefExtractor)(4, MscoaSegmentConfigComponent_mat_toolbar_4_Template, 5, 0, "mat-toolbar", 3)(5, MscoaSegmentConfigComponent_Conditional_5_Template, 5, 1, "div", 4)(6, MscoaSegmentConfigComponent_mat_card_6_Template, 41, 8, "mat-card", 3)(7, MscoaSegmentConfigComponent_span_7_Template, 3, 1, "span", 5);
|
|
411
|
-
i0.ɵɵpipe(8, "async");
|
|
412
|
-
} if (rf & 2) {
|
|
413
|
-
const noSegments_r9 = i0.ɵɵreference(3);
|
|
414
|
-
i0.ɵɵproperty("ngIf", (ctx.value || i0.ɵɵpureFunction0(9, _c0)).length > 0);
|
|
415
|
-
i0.ɵɵadvance();
|
|
416
|
-
i0.ɵɵproperty("ngIf", ((ctx.value == null ? null : ctx.value.length) || 0) > 0)("ngIfElse", noSegments_r9);
|
|
417
|
-
i0.ɵɵadvance(3);
|
|
418
|
-
i0.ɵɵproperty("ngIf", !ctx.isAddingNew && ctx.editingIndex === null && ctx.showAllSegments === false);
|
|
419
|
-
i0.ɵɵadvance();
|
|
420
|
-
i0.ɵɵconditional(!!ctx.getMscoaError ? 5 : -1);
|
|
421
|
-
i0.ɵɵadvance();
|
|
422
|
-
i0.ɵɵproperty("ngIf", ctx.isAddingNew || ctx.editingIndex !== null);
|
|
423
|
-
i0.ɵɵadvance();
|
|
424
|
-
i0.ɵɵproperty("ngIf", i0.ɵɵpipeBind1(8, 7, ctx.error$));
|
|
425
|
-
} }, dependencies: [CommonModule, i2.NgIf, i2.AsyncPipe, MatModulesModule, i3.MatOption, i2$1.MatButton, i3$1.MatCard, i3$1.MatCardActions, i3$1.MatCardContent, i3$1.MatCardHeader, i3$1.MatCardSubtitle, i4.MatChipListbox, i4.MatChipOption, i4.MatChipRemove, i6.MatIcon, i3$2.MatFormField, i3$2.MatLabel, i3$2.MatHint, i7.MatSelect, i2$2.MatSlideToggle, i9.MatToolbar, i12.MatInput, ReactiveFormsModule, i1.ɵNgNoValidate, i1.DefaultValueAccessor, i1.NgControlStatus, i1.NgControlStatusGroup, i1.FormGroupDirective, i1.FormControlName, FormsModule], styles: [".info-icon[_ngcontent-%COMP%]{min-width:38px}.tree-instructions[_ngcontent-%COMP%]{display:flex;align-items:center;gap:8px;padding:12px;background:azure;border-radius:4px;margin-bottom:16px}.json-error[_ngcontent-%COMP%]{background:inherit;color:#e74c3c}mat-form-field[_ngcontent-%COMP%]{width:100%;margin-bottom:8px;background:azure}.segment-toolbar[_ngcontent-%COMP%]{background:azure}.icons[_ngcontent-%COMP%]{font-size:14px;height:14px;width:14px}.segment-hint[_ngcontent-%COMP%]{display:block;padding:0 16px;margin-bottom:8px;-webkit-font-smoothing:antialiased;font-family:var(--mat-form-field-subscript-text-font, var(--mat-sys-body-small-font));line-height:var(--mat-form-field-subscript-text-line-height, var(--mat-sys-body-small-line-height));font-size:var(--mat-form-field-subscript-text-size, var(--mat-sys-body-small-size));letter-spacing:var(--mat-form-field-subscript-text-tracking, var(--mat-sys-body-small-tracking));font-weight:var(--mat-form-field-subscript-text-weight, var(--mat-sys-body-small-weight))}mat-card[_ngcontent-%COMP%]{background:var(--mat-toolbar-container-background-color, var(--mat-sys-surface))}"] }); }
|
|
426
|
-
}
|
|
427
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(MscoaSegmentConfigComponent, [{
|
|
428
|
-
type: Component,
|
|
429
|
-
args: [{ selector: 'app-mscoa-segment-config', standalone: true, imports: [
|
|
430
|
-
CommonModule,
|
|
431
|
-
MatModulesModule,
|
|
432
|
-
ReactiveFormsModule,
|
|
433
|
-
FormsModule
|
|
434
|
-
], providers: [{ provide: MatFormFieldControl, useExisting: MscoaSegmentConfigComponent }], template: "<div *ngIf=\"(value||[]).length>0\" class=\"tree-instructions\">\n <mat-icon class=\"info-icon\" color=\"primary\">info</mat-icon>\n <span>SCOA Segments Configuration</span>\n</div>\n\n<mat-chip-listbox *ngIf=\"(value?.length || 0) > 0; else noSegments\" aria-label=\"Fish selection\">\n @for (segment of value||[]; track segment.segment) {\n <mat-chip-option (removed)=\"removeSegment($index)\" (click)=\"startEdit($index)\" color=\"accent\"\n [value]=\"segment?.segment\" [selected]=\"this.editingIndex === $index\">\n <div style=\" \n display: flex;\n align-items: center;\n gap: 1px;\">\n <span style=\"margin-right: 2px;\">\n {{ segment.label }}\n </span>\n <mat-icon class=\"icons\">\n {{ segment.singleSelect ? 'done' : ' done_all' }}\n </mat-icon>\n <mat-icon class=\"icons\">\n\n {{ segment.readOnly ? 'edit_off' : 'edit' }}\n </mat-icon>\n </div>\n\n @if ( showAllSegments === false) {\n <button matChipRemove [attr.aria-label]=\"'remove' \">\n <mat-icon>cancel</mat-icon>\n </button>\n }\n\n </mat-chip-option>\n }\n</mat-chip-listbox>\n\n\n\n\n\n<ng-template #noSegments>\n <div class=\"tree-instructions\">\n <mat-icon class=\"info-icon\" color=\"primary\">info</mat-icon>\n <span>No segment configuration available. Start by adding a segment below.</span>\n </div>\n</ng-template>\n\n<mat-toolbar *ngIf=\"!isAddingNew && editingIndex === null && showAllSegments === false\">\n <button style=\"width:100%\" mat-stroked-button (click)=\"startAddNew()\">\n Add New Segment <mat-icon>add</mat-icon>\n </button>\n</mat-toolbar>\n\n@if (!!getMscoaError) {\n<div class=\"tree-instructions\">\n <mat-icon class=\"info-icon\" color=\"primary\">info</mat-icon>\n <span>\n {{ getMscoaError }}\n </span>\n</div>\n}\n<mat-card *ngIf=\"isAddingNew || editingIndex !== null\">\n <mat-card-header>\n <mat-card-subtitle>\n {{ isAddingNew ? 'Add a new' : 'Update' }} Segment\n </mat-card-subtitle>\n </mat-card-header>\n <mat-card-content>\n <form [formGroup]=\"segmentForm\" (ngSubmit)=\"saveSegment()\">\n <mat-toolbar class=\"segment-toolbar\">\n <mat-slide-toggle \n (change)=\"multiLevelSelectChange($event)\" \n [checked]=\"segmentForm.value.segmentExtension\">\n Enable Multi-Level Segmentation\n </mat-slide-toggle>\n \n </mat-toolbar>\n <mat-hint class=\"segment-hint\">\n This allows sub-classifications within this segment for more detailed accounting hierarchies\n </mat-hint>\n <mat-form-field subscriptSizing=\"dynamic\" floatLabel=\"always\" appearance=\"outline\">\n <mat-label>Segment</mat-label>\n <mat-select (selectionChange)=\"selectSegment($event)\" matNativeControl formControlName=\"segment\" [value]=\"value\" placeholder=\"Select segment\">\n @for ( segment of treeSegments; track segment.segment) {\n <mat-option [disabled]=\"alreadyExists(segment)\" [value]=\"segment.segment\"> \n {{ segment.label }}\n </mat-option>\n }\n </mat-select>\n \n </mat-form-field>\n <mat-hint class=\"segment-hint\">\n Select an account segment type from your chart of accounts\n </mat-hint>\n \n <mat-form-field subscriptSizing=\"dynamic\" floatLabel=\"always\" appearance=\"outline\">\n <mat-label>Label</mat-label>\n <input matInput formControlName=\"label\"\n [disabled]=\"!this.segmentForm.value.segmentExtension\"\n placeholder=\"Enter label\">\n <mat-hint>Provide a descriptive name for this segment (e.g., 'Department', 'Project', 'Cost Center')</mat-hint>\n </mat-form-field>\n \n <mat-toolbar class=\"segment-toolbar\">\n <mat-slide-toggle (change)=\"singleSelectChange($event)\" [checked]=\"segmentForm.value.singleSelect\">\n Single Value Selection\n </mat-slide-toggle>\n\n </mat-toolbar>\n <mat-hint class=\"segment-hint\">\n When enabled, transactions can only be assigned to one value within this segment. When disabled, transactions can be split across multiple values.\n </mat-hint>\n <mat-toolbar class=\"segment-toolbar\">\n <mat-slide-toggle (change)=\"readOnly($event)\" [checked]=\"segmentForm.value.readOnly\">\n Read-Only Segment\n </mat-slide-toggle>\n \n </mat-toolbar>\n <mat-hint class=\"segment-hint\">\n Prevents users from modifying segment values after initial setup. Use for regulatory or policy-controlled segments.\n </mat-hint>\n \n <br>\n <mat-card-actions>\n <button mat-flat-button color=\"primary\" type=\"submit\" [disabled]=\"!segmentForm.valid\">Save</button>\n <button mat-button (click)=\"cancelEdit()\">Cancel</button>\n </mat-card-actions>\n </form>\n </mat-card-content>\n</mat-card>\n\n<span color=\"danger\" *ngIf=\"error$ | async as error\">\n <p>{{ error }}</p>\n</span>", styles: [".info-icon{min-width:38px}.tree-instructions{display:flex;align-items:center;gap:8px;padding:12px;background:azure;border-radius:4px;margin-bottom:16px}.json-error{background:inherit;color:#e74c3c}mat-form-field{width:100%;margin-bottom:8px;background:azure}.segment-toolbar{background:azure}.icons{font-size:14px;height:14px;width:14px}.segment-hint{display:block;padding:0 16px;margin-bottom:8px;-webkit-font-smoothing:antialiased;font-family:var(--mat-form-field-subscript-text-font, var(--mat-sys-body-small-font));line-height:var(--mat-form-field-subscript-text-line-height, var(--mat-sys-body-small-line-height));font-size:var(--mat-form-field-subscript-text-size, var(--mat-sys-body-small-size));letter-spacing:var(--mat-form-field-subscript-text-tracking, var(--mat-sys-body-small-tracking));font-weight:var(--mat-form-field-subscript-text-weight, var(--mat-sys-body-small-weight))}mat-card{background:var(--mat-toolbar-container-background-color, var(--mat-sys-surface))}\n"] }]
|
|
435
|
-
}], () => [{ type: i1.FormBuilder }, { type: i1.NgControl, decorators: [{
|
|
436
|
-
type: Optional
|
|
437
|
-
}, {
|
|
438
|
-
type: Self
|
|
439
|
-
}] }, { type: i0.ElementRef }], { id: [{
|
|
440
|
-
type: HostBinding
|
|
441
|
-
}], errors: [{
|
|
442
|
-
type: Input
|
|
443
|
-
}], value: [{
|
|
444
|
-
type: Input
|
|
445
|
-
}], showAllSegments: [{
|
|
446
|
-
type: Input
|
|
447
|
-
}], getMscoaTree: [{
|
|
448
|
-
type: Input
|
|
449
|
-
}], valueChanged: [{
|
|
450
|
-
type: Output
|
|
451
|
-
}] }); })();
|
|
452
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(MscoaSegmentConfigComponent, { className: "MscoaSegmentConfigComponent", filePath: "lib/components/t-dynamic-data-edit/elements/mscoa-segment-config/mscoa-segment-config.component.ts", lineNumber: 30 }); })();
|
|
453
|
-
|
|
454
|
-
export { MscoaSegmentConfigComponent };
|
|
455
|
-
//# sourceMappingURL=ngx-t-forms-mscoa-segment-config.component-CrHAIRAw.mjs.map
|