ngx-t-forms 2.0.7 → 2.0.9

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.
Files changed (125) hide show
  1. package/fesm2022/{ngx-t-forms-api-value-access-rules.component-Cp0BeYD7.mjs → ngx-t-forms-api-value-access-rules.component-DjZDnTHz.mjs} +11 -11
  2. package/fesm2022/{ngx-t-forms-api-value-access-rules.component-Cp0BeYD7.mjs.map → ngx-t-forms-api-value-access-rules.component-DjZDnTHz.mjs.map} +1 -1
  3. package/fesm2022/ngx-t-forms-api-value-access-rules.component-Zg1ddSDb.mjs +813 -0
  4. package/fesm2022/ngx-t-forms-api-value-access-rules.component-Zg1ddSDb.mjs.map +1 -0
  5. package/fesm2022/{ngx-t-forms-calculated-field-rules.component-C1v-xiGd.mjs → ngx-t-forms-calculated-field-rules.component-E3l7DQo7.mjs} +11 -11
  6. package/fesm2022/{ngx-t-forms-calculated-field-rules.component-C1v-xiGd.mjs.map → ngx-t-forms-calculated-field-rules.component-E3l7DQo7.mjs.map} +1 -1
  7. package/fesm2022/ngx-t-forms-calculated-field-rules.component-ZepKycLR.mjs +532 -0
  8. package/fesm2022/ngx-t-forms-calculated-field-rules.component-ZepKycLR.mjs.map +1 -0
  9. package/fesm2022/ngx-t-forms-config-mscoa-additional-inputs.component-DLnB3R7t.mjs +297 -0
  10. package/fesm2022/ngx-t-forms-config-mscoa-additional-inputs.component-DLnB3R7t.mjs.map +1 -0
  11. package/fesm2022/{ngx-t-forms-config-mscoa-additional-inputs.component-jgXTh0do.mjs → ngx-t-forms-config-mscoa-additional-inputs.component-sOC54w4T.mjs} +9 -9
  12. package/fesm2022/{ngx-t-forms-config-mscoa-additional-inputs.component-jgXTh0do.mjs.map → ngx-t-forms-config-mscoa-additional-inputs.component-sOC54w4T.mjs.map} +1 -1
  13. package/fesm2022/ngx-t-forms-form-input-selector.component-BjwzDiCY.mjs +187 -0
  14. package/fesm2022/ngx-t-forms-form-input-selector.component-BjwzDiCY.mjs.map +1 -0
  15. package/fesm2022/{ngx-t-forms-form-input-selector.component-DbKhNmVM.mjs → ngx-t-forms-form-input-selector.component-CB03sPjA.mjs} +6 -6
  16. package/fesm2022/{ngx-t-forms-form-input-selector.component-DbKhNmVM.mjs.map → ngx-t-forms-form-input-selector.component-CB03sPjA.mjs.map} +1 -1
  17. package/fesm2022/{ngx-t-forms-form-json-view.component-DSnLKnfH.mjs → ngx-t-forms-form-json-view.component-C1AZujJH.mjs} +2 -2
  18. package/fesm2022/{ngx-t-forms-form-json-view.component-DSnLKnfH.mjs.map → ngx-t-forms-form-json-view.component-C1AZujJH.mjs.map} +1 -1
  19. package/fesm2022/ngx-t-forms-form-json-view.component-CqtTYCRH.mjs +28 -0
  20. package/fesm2022/ngx-t-forms-form-json-view.component-CqtTYCRH.mjs.map +1 -0
  21. package/fesm2022/ngx-t-forms-form-section-stepper.component-Ba5WCLzp.mjs +673 -0
  22. package/fesm2022/ngx-t-forms-form-section-stepper.component-Ba5WCLzp.mjs.map +1 -0
  23. package/fesm2022/ngx-t-forms-form-section-stepper.component-C_dciQhe.mjs +225 -0
  24. package/fesm2022/ngx-t-forms-form-section-stepper.component-C_dciQhe.mjs.map +1 -0
  25. package/fesm2022/{ngx-t-forms-forms-builder-menu.component-DQ8JYw6g.mjs → ngx-t-forms-forms-builder-menu.component-CPIcPREp.mjs} +13 -13
  26. package/fesm2022/{ngx-t-forms-forms-builder-menu.component-DQ8JYw6g.mjs.map → ngx-t-forms-forms-builder-menu.component-CPIcPREp.mjs.map} +1 -1
  27. package/fesm2022/ngx-t-forms-forms-builder-menu.component-DbxEBvpt.mjs +735 -0
  28. package/fesm2022/ngx-t-forms-forms-builder-menu.component-DbxEBvpt.mjs.map +1 -0
  29. package/fesm2022/ngx-t-forms-input-editor.component-BnsC-jsN.mjs +445 -0
  30. package/fesm2022/ngx-t-forms-input-editor.component-BnsC-jsN.mjs.map +1 -0
  31. package/fesm2022/{ngx-t-forms-input-editor.component-Gi9MgyHB.mjs → ngx-t-forms-input-editor.component-__grERM8.mjs} +7 -10
  32. package/fesm2022/ngx-t-forms-input-editor.component-__grERM8.mjs.map +1 -0
  33. package/fesm2022/ngx-t-forms-mat-chip-list-editor.component-DS6s98ZX.mjs +111 -0
  34. package/fesm2022/ngx-t-forms-mat-chip-list-editor.component-DS6s98ZX.mjs.map +1 -0
  35. package/fesm2022/{ngx-t-forms-mat-chip-list-editor.component-C2jw_2gf.mjs → ngx-t-forms-mat-chip-list-editor.component-DcdHYqhN.mjs} +2 -3
  36. package/fesm2022/ngx-t-forms-mat-chip-list-editor.component-DcdHYqhN.mjs.map +1 -0
  37. package/fesm2022/{ngx-t-forms-mat-slider-editor.component-D_IMC63r.mjs → ngx-t-forms-mat-slider-editor.component-C9rintm4.mjs} +2 -2
  38. package/fesm2022/{ngx-t-forms-mat-slider-editor.component-D_IMC63r.mjs.map → ngx-t-forms-mat-slider-editor.component-C9rintm4.mjs.map} +1 -1
  39. package/fesm2022/ngx-t-forms-mat-slider-editor.component-ChiiJYK2.mjs +130 -0
  40. package/fesm2022/ngx-t-forms-mat-slider-editor.component-ChiiJYK2.mjs.map +1 -0
  41. package/fesm2022/{ngx-t-forms-mat-slider-toggle-editor.component-DeKGDDuU.mjs → ngx-t-forms-mat-slider-toggle-editor.component-CItK6kXf.mjs} +2 -2
  42. package/fesm2022/{ngx-t-forms-mat-slider-toggle-editor.component-DeKGDDuU.mjs.map → ngx-t-forms-mat-slider-toggle-editor.component-CItK6kXf.mjs.map} +1 -1
  43. package/fesm2022/ngx-t-forms-mat-slider-toggle-editor.component-DFcLzkSF.mjs +171 -0
  44. package/fesm2022/ngx-t-forms-mat-slider-toggle-editor.component-DFcLzkSF.mjs.map +1 -0
  45. package/fesm2022/ngx-t-forms-missing-form-configs.component-DNkGCH0e.mjs +104 -0
  46. package/fesm2022/ngx-t-forms-missing-form-configs.component-DNkGCH0e.mjs.map +1 -0
  47. package/fesm2022/{ngx-t-forms-missing-form-configs.component-BvsopeCg.mjs → ngx-t-forms-missing-form-configs.component-Da3SdUn6.mjs} +4 -4
  48. package/fesm2022/{ngx-t-forms-missing-form-configs.component-BvsopeCg.mjs.map → ngx-t-forms-missing-form-configs.component-Da3SdUn6.mjs.map} +1 -1
  49. package/fesm2022/ngx-t-forms-mscoa-segment-config.component-4hrEpLk3.mjs +258 -0
  50. package/fesm2022/ngx-t-forms-mscoa-segment-config.component-4hrEpLk3.mjs.map +1 -0
  51. package/fesm2022/ngx-t-forms-mscoa-segment-config.component-CrHAIRAw.mjs +455 -0
  52. package/fesm2022/ngx-t-forms-mscoa-segment-config.component-CrHAIRAw.mjs.map +1 -0
  53. package/fesm2022/{ngx-t-forms-ngx-t-forms-DtoFU6uQ.mjs → ngx-t-forms-ngx-t-forms-1Roar4qK.mjs} +710 -1294
  54. package/fesm2022/ngx-t-forms-ngx-t-forms-1Roar4qK.mjs.map +1 -0
  55. package/fesm2022/ngx-t-forms-ngx-t-forms-DaAFB-HX.mjs +14694 -0
  56. package/fesm2022/ngx-t-forms-ngx-t-forms-DaAFB-HX.mjs.map +1 -0
  57. package/fesm2022/{ngx-t-forms-pipeline-generator.component-IwmDgCk9.mjs → ngx-t-forms-pipeline-generator.component-BQDykLNH.mjs} +14 -14
  58. package/fesm2022/{ngx-t-forms-pipeline-generator.component-IwmDgCk9.mjs.map → ngx-t-forms-pipeline-generator.component-BQDykLNH.mjs.map} +1 -1
  59. package/fesm2022/ngx-t-forms-pipeline-generator.component-U0d8jQKW.mjs +1362 -0
  60. package/fesm2022/ngx-t-forms-pipeline-generator.component-U0d8jQKW.mjs.map +1 -0
  61. package/fesm2022/{ngx-t-forms-required-inputs.component-DdNLYKY6.mjs → ngx-t-forms-required-inputs.component-BGK3DNu0.mjs} +10 -10
  62. package/fesm2022/{ngx-t-forms-required-inputs.component-DdNLYKY6.mjs.map → ngx-t-forms-required-inputs.component-BGK3DNu0.mjs.map} +1 -1
  63. package/fesm2022/ngx-t-forms-required-inputs.component-S3cbA-zG.mjs +383 -0
  64. package/fesm2022/ngx-t-forms-required-inputs.component-S3cbA-zG.mjs.map +1 -0
  65. package/fesm2022/{ngx-t-forms-rest-api-call-setup.component-DH5GpWKn.mjs → ngx-t-forms-rest-api-call-setup.component-CCaRUSVQ.mjs} +4 -4
  66. package/fesm2022/{ngx-t-forms-rest-api-call-setup.component-DH5GpWKn.mjs.map → ngx-t-forms-rest-api-call-setup.component-CCaRUSVQ.mjs.map} +1 -1
  67. package/fesm2022/ngx-t-forms-rest-api-call-setup.component-DDg4fCFx.mjs +457 -0
  68. package/fesm2022/ngx-t-forms-rest-api-call-setup.component-DDg4fCFx.mjs.map +1 -0
  69. package/fesm2022/{ngx-t-forms-section-report.component-BAddUET-.mjs → ngx-t-forms-section-report.component-C8Ja_G_3.mjs} +5 -5
  70. package/fesm2022/{ngx-t-forms-section-report.component-BAddUET-.mjs.map → ngx-t-forms-section-report.component-C8Ja_G_3.mjs.map} +1 -1
  71. package/fesm2022/ngx-t-forms-section-report.component-C_h0KIR4.mjs +314 -0
  72. package/fesm2022/ngx-t-forms-section-report.component-C_h0KIR4.mjs.map +1 -0
  73. package/fesm2022/ngx-t-forms-selection-options-editor.component-CllhwZ5Y.mjs +231 -0
  74. package/fesm2022/ngx-t-forms-selection-options-editor.component-CllhwZ5Y.mjs.map +1 -0
  75. package/fesm2022/{ngx-t-forms-selection-options-editor.component-CQh-InJ6.mjs → ngx-t-forms-selection-options-editor.component-cYkn1O48.mjs} +6 -6
  76. package/fesm2022/{ngx-t-forms-selection-options-editor.component-CQh-InJ6.mjs.map → ngx-t-forms-selection-options-editor.component-cYkn1O48.mjs.map} +1 -1
  77. package/fesm2022/ngx-t-forms-validators-config.component-BPJZRtjT.mjs +434 -0
  78. package/fesm2022/ngx-t-forms-validators-config.component-BPJZRtjT.mjs.map +1 -0
  79. package/fesm2022/{ngx-t-forms-validators-config.component-SyL_Vln8.mjs → ngx-t-forms-validators-config.component-CGXCCl45.mjs} +8 -8
  80. package/fesm2022/{ngx-t-forms-validators-config.component-SyL_Vln8.mjs.map → ngx-t-forms-validators-config.component-CGXCCl45.mjs.map} +1 -1
  81. package/fesm2022/ngx-t-forms.mjs +1 -1
  82. package/lib/components/form-builder/elements/form-section-stepper/form-section-stepper.component.d.ts +2 -0
  83. package/lib/components/form-builder/elements/form-submissions-config/form-submissions-config.component.d.ts +1 -1
  84. package/lib/components/form-builder/elements/input-element-editor/input-element-editor.component.d.ts +2 -2
  85. package/lib/components/forms/forms.component.d.ts +1 -1
  86. package/lib/components/forms/store/Form-actions-formBuilder.d.ts +1 -0
  87. package/lib/components/forms/store/Form-selectors-FormBuilder.d.ts +1 -1
  88. package/lib/components/forms/store/forms-store.service.d.ts +2 -1
  89. package/lib/components/index.d.ts +2 -1
  90. package/lib/components/t-dynamic-data-edit/elements/mscoa-segment-config/mscoa-segment-config.component.d.ts +5 -9
  91. package/lib/components/t-form-input/elements/mscoa-form-input/elements/account-value/account-value.component.d.ts +3 -3
  92. package/lib/components/t-form-input/elements/mscoa-form-input/elements/mscoa-chart/mscoa-chart.component.d.ts +67 -52
  93. package/lib/components/t-form-input/elements/mscoa-form-input/elements/mscoa-computation/mscoa-computation.component.d.ts +10 -10
  94. package/lib/components/t-form-input/elements/mscoa-form-input/elements/mscoa-reactive-form-field/mscoa-reactive-form-field.component.d.ts +8 -6
  95. package/lib/components/t-form-input/elements/mscoa-form-input/elements/scoa-account-table/scoa-account-table.component.d.ts +8 -8
  96. package/lib/components/t-form-input/elements/mscoa-form-input/elements/scoa-input/scoa-input.component.d.ts +1 -1
  97. package/lib/components/t-form-input/elements/mscoa-form-input/mscoa-form-input.component.d.ts +4 -3
  98. package/lib/components/t-form-input/elements/mscoa-form-input/store/mscoa-actions.d.ts +5 -5
  99. package/lib/components/t-form-input/elements/mscoa-form-input/store/mscoa-component-store.service.d.ts +27 -31
  100. package/lib/components/t-form-input/elements/mscoa-form-input/store/mscoa-effects.d.ts +2 -2
  101. package/lib/components/t-form-input/elements/mscoa-form-input/store/mscoa-selectors.d.ts +20 -24
  102. package/lib/components/t-form-input/elements/multiple-input-input-element/core/multiple-input-table-edit/multiple-input-table-edit.component.d.ts +1 -1
  103. package/lib/components/t-form-input/elements/select-input-element/elements/select-input/select-input.component.d.ts +20 -0
  104. package/lib/components/t-form-input/elements/select-input-element/select-input-element.component.d.ts +0 -3
  105. package/lib/components/t-form-input/t-form-input.component.d.ts +3 -2
  106. package/lib/components/user-form-stepper/user-form-stepper.component.d.ts +5 -0
  107. package/lib/components/workflow-builder/store/workflow-builder-store.service.d.ts +18 -0
  108. package/lib/components/workflow-builder/store/workflowEditorActions.d.ts +4 -0
  109. package/lib/components/workflow-builder/store/workflowEditorEffects.d.ts +2 -0
  110. package/lib/components/workflow-builder/store/workflowEditorSelectors.d.ts +2 -0
  111. package/lib/components/workflow-builder/workflow-builder.component.d.ts +12 -0
  112. package/lib/services/core/t-form-builder/functions/addScoaExtensionInput.d.ts +2 -0
  113. package/lib/services/core/t-form-tower-controller/form-tower-controller.service.d.ts +2 -0
  114. package/lib/services/core/t-form-tower-controller/functions/allFormInputs.d.ts +2 -3
  115. package/lib/services/core/t-form-tower-controller/functions/getAllFunctionTypes.d.ts +2 -0
  116. package/lib/shared/functions/textIconsForUserHints.d.ts +2 -1
  117. package/package.json +3 -2
  118. package/fesm2022/ngx-t-forms-form-section-stepper.component-hnOcnZGc.mjs +0 -220
  119. package/fesm2022/ngx-t-forms-form-section-stepper.component-hnOcnZGc.mjs.map +0 -1
  120. package/fesm2022/ngx-t-forms-input-editor.component-Gi9MgyHB.mjs.map +0 -1
  121. package/fesm2022/ngx-t-forms-mat-chip-list-editor.component-C2jw_2gf.mjs.map +0 -1
  122. package/fesm2022/ngx-t-forms-mscoa-segment-config.component-D_IIYPud.mjs +0 -230
  123. package/fesm2022/ngx-t-forms-mscoa-segment-config.component-D_IIYPud.mjs.map +0 -1
  124. package/fesm2022/ngx-t-forms-ngx-t-forms-DtoFU6uQ.mjs.map +0 -1
  125. package/testForm.d.ts +0 -797
@@ -0,0 +1,455 @@
1
+ import * as i2 from '@angular/common';
2
+ 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
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ngx-t-forms-mscoa-segment-config.component-CrHAIRAw.mjs","sources":["../../../projects/ngx-t-forms/src/lib/components/t-dynamic-data-edit/elements/mscoa-segment-config/mscoa-segment-config.component.html","../../../projects/ngx-t-forms/src/lib/components/t-dynamic-data-edit/elements/mscoa-segment-config/mscoa-segment-config.component.ts"],"sourcesContent":["<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>","import { CommonModule } from '@angular/common';\r\nimport { Component, ElementRef, EventEmitter, HostBinding, Input, OnDestroy, OnInit, Optional, Output, Self } from '@angular/core';\r\nimport { FormGroup, FormBuilder, Validators, ReactiveFormsModule, NgControl, FormsModule } from '@angular/forms';\r\nimport { BehaviorSubject, catchError, Observable, Subject, take, takeUntil, tap } from 'rxjs';\r\n\r\nimport { MatModulesModule } from '../../../../shared/modules/mat-modules.module';\r\nimport { IGetTreeResponse, IIncludedSegmentConfig } from 'ngx-t-forms-types';\r\n\r\nimport { MatSlideToggleChange } from '@angular/material/slide-toggle';\r\nimport { MatFormFieldControl } from '@angular/material/form-field';\r\nimport { IConfigElementError } from '../../t-dynamic-data-edit.component';\r\nimport { MatSelectChange } from '@angular/material/select';\r\nimport { v4 as uuidv4 } from 'uuid';\r\n\r\n\r\n@Component({\r\n selector: 'app-mscoa-segment-config',\r\n templateUrl: './mscoa-segment-config.component.html',\r\n styleUrls: ['./mscoa-segment-config.component.scss'],\r\n standalone: true,\r\n imports:[\r\n CommonModule,\r\n MatModulesModule,\r\n ReactiveFormsModule,\r\n FormsModule\r\n ],\r\nproviders: [{ provide: MatFormFieldControl, useExisting:MscoaSegmentConfigComponent }],\r\n \r\n})\r\nexport class MscoaSegmentConfigComponent implements OnInit, OnDestroy,MatFormFieldControl<IIncludedSegmentConfig[]|undefined>{\r\n\r\n static nextId = 0;\r\n stateChanges = new Subject<void>();\r\n \r\n @HostBinding() id = `app-mscoa-segment-config'-${MscoaSegmentConfigComponent.nextId++}`;\r\n \r\n placeholder: string = ''\r\n constructor(\r\n private fb: FormBuilder,\r\n @Optional() @Self() public ngControl: NgControl, private _elementRef: ElementRef<HTMLElement>,\r\n ) {\r\n this.segmentForm = this.createSegmentForm();\r\n \r\n }\r\n\r\n focused: boolean = false;\r\n get empty() {\r\n return !this.value\r\n }\r\n get shouldLabelFloat() {\r\n return this.focused || !this.empty;\r\n }\r\n required: boolean = false;\r\n disabled: boolean = false;\r\n get errorState(): boolean {\r\n const hasError = !!this.ngControl?.control?.errors || (this.errors||[]).length > 0 && this.touched\r\n return !this.value && !!this.required || hasError\r\n }\r\n \r\n controlType?: string | undefined;\r\n autofilled?: boolean | undefined;\r\n userAriaDescribedBy?: string | undefined;\r\n disableAutomaticLabeling?: boolean | undefined;\r\n setDescribedByIds(ids: string[]) {\r\n // Ensure the component view is initialized\r\n if (this._elementRef && this._elementRef.nativeElement) {\r\n const controlElement = this._elementRef.nativeElement.querySelector('.app-mscoa-segment-config');\r\n // Check if the controlElement exists before attempting to set its attribute\r\n if (controlElement) {\r\n controlElement.setAttribute('aria-describedby', ids.join(' '));\r\n }\r\n }\r\n }\r\n onContainerClick(event: MouseEvent): void {\r\n this.markAsTouched();\r\n this.stateChanges.next();\r\n }\r\n \r\n touched: boolean = false;\r\n onTouched = () => {};\r\n markAsTouched() {\r\n console.log('markAsTouched') \r\n if (!this.touched) {\r\n this.onTouched();\r\n this.touched = true;\r\n }\r\n } \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n @Input() errors:IConfigElementError[] |undefined = [];\r\n \r\n @Input() set value(val: IIncludedSegmentConfig[]) {\r\n this._value.next(val || []);\r\n }\r\n \r\n get value(): IIncludedSegmentConfig[] {\r\n return this._value.value;\r\n }\r\n _getMscoaTree :Observable<IGetTreeResponse|undefined> | undefined;\r\n _showAllSegments:boolean = false;\r\n @Input() set showAllSegments(val:boolean){\r\n\r\n if(!!val){\r\n this.checkShowAllSegments()\r\n }\r\n this._showAllSegments = !!val\r\n \r\n }\r\n get showAllSegments(){\r\n return this._showAllSegments\r\n }\r\n\r\n @Input() set getMscoaTree(options$:Observable<IGetTreeResponse | undefined> ){\r\n if(!!options$ && this._getMscoaTree === undefined){\r\n this. getMscoaError = undefined \r\n this._getMscoaTree = options$\r\n\r\n this.loadMscoa()\r\n }else if(!options$){\r\n this. getMscoaError = 'No loader provided'\r\n\r\n }\r\n }\r\n@Output() valueChanged = new EventEmitter<IIncludedSegmentConfig[]>();\r\n private _value = new BehaviorSubject<IIncludedSegmentConfig[]>([]);\r\n private destroy$ = new Subject<void>();\r\n\r\n mscoaTree!:IGetTreeResponse | undefined;\r\n treeSegments!:IIncludedSegmentConfig[];\r\n error$ = new BehaviorSubject<string | null>(null);\r\n\r\n segmentForm: FormGroup;\r\n editingIndex: number | null = null;\r\n isAddingNew = false;\r\n\r\n\r\n\r\n ngOnInit() {\r\n this.listenToFormChanges();\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n getMscoaError:string|undefined = undefined\r\n private loadMscoa(){\r\n \r\n this._getMscoaTree?.pipe(\r\n take(1),\r\n tap((options) => {\r\n this.mscoaTree = options;\r\n this.treeSegments = options?.accountTreeKeys?.map((treeKey) => ({\r\n id:uuidv4(), \r\n segment:treeKey,\r\n singleSelect:true,\r\n segmentExtension:false,\r\n label: this.toTitleCase(treeKey),\r\n readOnly: this.value.find((v) => v.segment === treeKey)?.readOnly || false, \r\n })) || [];\r\n }),\r\n catchError((error) => {\r\n this.getMscoaError = 'Failed to fetch mscoa tree';\r\n console.error('Error while fetching SCOA tree:', error);\r\n return [null];\r\n })\r\n ).subscribe();\r\n }\r\n private createSegmentForm(segment: IIncludedSegmentConfig = {\r\n segment: '', label: '',\r\n id:uuidv4(),\r\n singleSelect:true,\r\n segmentExtension:false,\r\n readOnly:false}): FormGroup {\r\n return this.fb.group({\r\n segment: [segment.segment, Validators.required],\r\n segmentExtension:[segment.segmentExtension,Validators.required],\r\n readOnly: [segment.readOnly, Validators.required],\r\n label: [segment.label, Validators.required],\r\n singleSelect:[segment.singleSelect,Validators.required]\r\n });\r\n }\r\n\r\n private listenToFormChanges() {\r\n this.segmentForm.valueChanges\r\n .pipe(takeUntil(this.destroy$))\r\n .subscribe((v) => console.log(v));\r\n }\r\n\r\n startAddNew() {\r\n this.isAddingNew = true;\r\n this.editingIndex = null;\r\n this.segmentForm = this.createSegmentForm();\r\n }\r\n\r\n startEdit(index: number) {\r\n this.editingIndex = index;\r\n this.isAddingNew = false;\r\n this.segmentForm = this.createSegmentForm(this.value[index]);\r\n }\r\n\r\n cancelEdit() {\r\n this.editingIndex = null;\r\n this.isAddingNew = false;\r\n this.segmentForm.reset();\r\n }\r\n\r\n saveSegment() {\r\n if (this.segmentForm.valid) {\r\n const newSegment: IIncludedSegmentConfig = ({\r\n id:this.segmentForm.value.id || uuidv4(),\r\n segment:this.segmentForm.value.segment,\r\n customSegment:!!this.segmentForm.value.segmentExtension? (this.segmentForm.value.label as string)?.toLocaleUpperCase() : undefined,\r\n segmentExtension:this.segmentForm.value.segmentExtension,\r\n label:this.toTitleCase(this.segmentForm.value.label),\r\n singleSelect:this.segmentForm.value.singleSelect,\r\n readOnly:this.segmentForm.value.readOnly\r\n })\r\n const updatedValue = [...this.value];\r\n\r\n if (this.isAddingNew) {\r\n updatedValue.push(newSegment);\r\n } else if (this.editingIndex !== null) {\r\n updatedValue[this.editingIndex] = newSegment;\r\n }\r\n\r\n \r\n this._value.next(updatedValue);\r\n this.valueChanged.emit(updatedValue);\r\n this.cancelEdit();\r\n }\r\n }\r\n readOnly(event:MatSlideToggleChange){\r\n this.segmentForm.patchValue({readOnly:event.checked}) \r\n }\r\n singleSelectChange(event:MatSlideToggleChange){\r\n this.segmentForm.patchValue({singleSelect:event.checked}) \r\n console.error('singleSelectChange',this.segmentForm.value)\r\n }\r\n removeSegment(index: number) {\r\n const updatedValue = this.value.filter((_, i) => i !== index);\r\n this._value.next(updatedValue);\r\n this.valueChanged.emit(updatedValue);\r\n }\r\n\r\n private toTitleCase(str: string): string {\r\n return str.replace(/\\w\\S*/g, (txt) => txt.charAt(0).toUpperCase() + txt.substr(1).toLowerCase());\r\n }\r\n alreadyExists(segment:IIncludedSegmentConfig){\r\n if(this.segmentForm.value.segmentExtension) return false\r\n return this.value.find((v) => v.segment === segment.segment)\r\n }\r\n checkShowAllSegments() {\r\n if (!this._getMscoaTree || !this.treeSegments) return;\r\n \r\n const updatedValue = this.treeSegments.map(segment => ({\r\n ...segment,\r\n ...(this.value.find(v => v.segment === segment.segment) || {})\r\n }));\r\n\r\n if (JSON.stringify(updatedValue) !== JSON.stringify(this.value)) {\r\n this.valueChanged.emit([{} as any]);\r\n setTimeout(() => {\r\n this.valueChanged.emit(updatedValue);\r\n }, 0);\r\n }\r\n }\r\n selectSegment($event: MatSelectChange<any>){\r\n\r\n this.segmentForm.patchValue({segment:$event.value})\r\n if(!this.segmentForm.value.segmentExtension){\r\n this.segmentForm.patchValue({label:this.toTitleCase($event.value)})\r\n }\r\n \r\n\r\n }\r\n multiLevelSelectChange(event:MatSlideToggleChange){\r\n this.segmentForm.patchValue({segmentExtension:event.checked})\r\n }\r\n}"],"names":["uuidv4","i4","i5","i6","i7","i8","i9","i10","i11"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AACE,IADF,8BAA4D,CACd,CAAA,EAAA,UAAA,EAAA,CAAA,CAAA;IAAA,EAAI,CAAA,MAAA,CAAA,CAAA,EAAA,MAAA,CAAA;IAAA,EAAW,CAAA,YAAA,EAAA;IAC3D,EAAM,CAAA,cAAA,CAAA,CAAA,EAAA,MAAA,CAAA;IAAA,EAA2B,CAAA,MAAA,CAAA,CAAA,EAAA,6BAAA,CAAA;AACnC,IADmC,iBAAO,EACpC;;;AAwBA,IADF,kCAAoD,CACxC,CAAA,EAAA,UAAA,CAAA;IAAA,EAAM,CAAA,MAAA,CAAA,CAAA,EAAA,QAAA,CAAA;AAClB,IADkB,iBAAW,EACpB;;;;;;IArBX,EACuE,CAAA,cAAA,CAAA,CAAA,EAAA,iBAAA,EAAA,CAAA,CAAA;AADpB,IAAlC,EAAW,CAAA,UAAA,CAAA,SAAA,EAAA,SAAA,gGAAA,GAAA,EAAA,MAAA,SAAA,GAAA,EAAA,CAAA,aAAA,CAAA,GAAA,CAAA,CAAA,MAAA,CAAA,CAAA,MAAA,MAAA,GAA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