@apipass/schemas 0.2.16 → 1.0.7

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 (75) hide show
  1. package/README.md +33 -33
  2. package/base-schema.component.d.ts +12 -12
  3. package/{esm2015/apipass-schemas.js → esm2020/apipass-schemas.mjs} +4 -4
  4. package/esm2020/base-schema.component.mjs +37 -0
  5. package/esm2020/public-api.mjs +17 -0
  6. package/esm2020/schema-custom-attributes/schema-custom-attributes.mjs +169 -0
  7. package/esm2020/schema-fields.service.mjs +80 -0
  8. package/esm2020/schema-form/schema-array/array-session/array-session.mjs +143 -0
  9. package/esm2020/schema-form/schema-array/schema-array.mjs +220 -0
  10. package/esm2020/schema-form/schema-form.mjs +107 -0
  11. package/esm2020/schema-form/schema-input/field-render/field-render.mjs +69 -0
  12. package/esm2020/schema-form/schema-input/input-render/boolean-input/boolean-input.component.mjs +46 -0
  13. package/esm2020/schema-form/schema-input/input-render/input-render.mjs +192 -0
  14. package/esm2020/schema-form/schema-input/input-render/number-input/number-input.component.mjs +44 -0
  15. package/esm2020/schema-form/schema-input/schema-input.mjs +96 -0
  16. package/esm2020/schema-form/schema-object/schema-object.mjs +123 -0
  17. package/esm2020/schema-form-render.mjs +126 -0
  18. package/esm2020/schema-form-render.module.mjs +108 -0
  19. package/esm2020/schema-validation-field.mjs +14 -0
  20. package/esm2020/struct.utils.mjs +9 -0
  21. package/esm2020/type-script-compile/type-script-compile.base.mjs +114 -0
  22. package/fesm2015/apipass-schemas.mjs +1801 -0
  23. package/fesm2015/apipass-schemas.mjs.map +1 -0
  24. package/fesm2020/apipass-schemas.mjs +1616 -0
  25. package/fesm2020/apipass-schemas.mjs.map +1 -0
  26. package/{apipass-schemas.d.ts → index.d.ts} +5 -5
  27. package/package.json +32 -19
  28. package/public-api.d.ts +16 -16
  29. package/schema-custom-attributes/schema-custom-attributes.d.ts +21 -21
  30. package/schema-fields.service.d.ts +14 -15
  31. package/schema-form/schema-array/array-session/array-session.d.ts +19 -19
  32. package/schema-form/schema-array/schema-array.d.ts +32 -32
  33. package/schema-form/schema-form.d.ts +31 -31
  34. package/schema-form/schema-input/field-render/field-render.d.ts +16 -16
  35. package/schema-form/schema-input/input-render/boolean-input/boolean-input.component.d.ts +15 -15
  36. package/schema-form/schema-input/input-render/input-render.d.ts +29 -29
  37. package/schema-form/schema-input/input-render/number-input/number-input.component.d.ts +15 -15
  38. package/schema-form/schema-input/schema-input.d.ts +19 -19
  39. package/schema-form/schema-object/schema-object.d.ts +34 -34
  40. package/schema-form-render.d.ts +31 -31
  41. package/schema-form-render.module.d.ts +23 -22
  42. package/schema-validation-field.d.ts +23 -23
  43. package/struct.utils.d.ts +1 -1
  44. package/type-script-compile/type-script-compile.base.d.ts +17 -17
  45. package/assets/css/buttons.scss +0 -118
  46. package/assets/css/colors.scss +0 -34
  47. package/assets/css/fonts.scss +0 -24
  48. package/assets/css/inputs.scss +0 -197
  49. package/assets/css/pt_sans.scss +0 -144
  50. package/assets/css/spacing.scss +0 -28
  51. package/assets/css/texts.scss +0 -18
  52. package/bundles/apipass-schemas.umd.js +0 -2339
  53. package/bundles/apipass-schemas.umd.js.map +0 -1
  54. package/bundles/apipass-schemas.umd.min.js +0 -16
  55. package/bundles/apipass-schemas.umd.min.js.map +0 -1
  56. package/esm2015/base-schema.component.js +0 -38
  57. package/esm2015/public-api.js +0 -17
  58. package/esm2015/schema-custom-attributes/schema-custom-attributes.js +0 -192
  59. package/esm2015/schema-fields.service.js +0 -87
  60. package/esm2015/schema-form/schema-array/array-session/array-session.js +0 -161
  61. package/esm2015/schema-form/schema-array/schema-array.js +0 -234
  62. package/esm2015/schema-form/schema-form.js +0 -114
  63. package/esm2015/schema-form/schema-input/field-render/field-render.js +0 -74
  64. package/esm2015/schema-form/schema-input/input-render/boolean-input/boolean-input.component.js +0 -50
  65. package/esm2015/schema-form/schema-input/input-render/input-render.js +0 -199
  66. package/esm2015/schema-form/schema-input/input-render/number-input/number-input.component.js +0 -48
  67. package/esm2015/schema-form/schema-input/schema-input.js +0 -111
  68. package/esm2015/schema-form/schema-object/schema-object.js +0 -134
  69. package/esm2015/schema-form-render.js +0 -136
  70. package/esm2015/schema-form-render.module.js +0 -124
  71. package/esm2015/schema-validation-field.js +0 -15
  72. package/esm2015/struct.utils.js +0 -9
  73. package/esm2015/type-script-compile/type-script-compile.base.js +0 -112
  74. package/fesm2015/apipass-schemas.js +0 -1745
  75. package/fesm2015/apipass-schemas.js.map +0 -1
@@ -0,0 +1,1616 @@
1
+ import * as i0 from '@angular/core';
2
+ import { EventEmitter, Component, Input, Output, TemplateRef, ContentChild, Injectable, Optional, SkipSelf, NgModule } from '@angular/core';
3
+ import * as i1 from '@angular/common';
4
+ import { CommonModule } from '@angular/common';
5
+ import * as i3 from '@angular/forms';
6
+ import { FormControl, Validators, FormsModule } from '@angular/forms';
7
+ import * as i2 from 'ngx-drag-drop';
8
+ import { DndModule } from 'ngx-drag-drop';
9
+ import * as i2$1 from '@angular/material/tooltip';
10
+ import { MatTooltipModule } from '@angular/material/tooltip';
11
+ import * as i4 from '@apipass/inputs';
12
+ import { InputsModule } from '@apipass/inputs';
13
+ import * as i5 from '@apipass/icons';
14
+ import { IconsModule } from '@apipass/icons';
15
+
16
+ class BaseSchemaComponent {
17
+ constructor() {
18
+ this.modelChange = new EventEmitter();
19
+ }
20
+ getSchemaProperties() {
21
+ return this.schema.properties instanceof Array ? this.schema.properties : [this.schema.properties];
22
+ }
23
+ canRender(property) {
24
+ property.canRender = property?.conditionExpression ? eval(property.conditionExpression) : true;
25
+ return property.canRender;
26
+ }
27
+ onDrop(event, attr) {
28
+ const data = event.data;
29
+ if (!attr) {
30
+ attr = '';
31
+ }
32
+ attr += `{{${data}}}`;
33
+ return attr;
34
+ }
35
+ }
36
+ BaseSchemaComponent.ɵfac = function BaseSchemaComponent_Factory(t) { return new (t || BaseSchemaComponent)(); };
37
+ BaseSchemaComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: BaseSchemaComponent, selectors: [["ng-component"]], inputs: { model: "model", schema: "schema" }, outputs: { modelChange: "modelChange" }, decls: 0, vars: 0, template: function BaseSchemaComponent_Template(rf, ctx) { }, encapsulation: 2 });
38
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(BaseSchemaComponent, [{
39
+ type: Component,
40
+ args: [{
41
+ template: ''
42
+ }]
43
+ }], null, { model: [{
44
+ type: Input
45
+ }], schema: [{
46
+ type: Input
47
+ }], modelChange: [{
48
+ type: Output
49
+ }] }); })();
50
+
51
+ function onDropStruct(event, attr) {
52
+ const data = event.data;
53
+ if (!attr) {
54
+ attr = '';
55
+ }
56
+ attr += `{{${data}}}`;
57
+ return attr;
58
+ }
59
+
60
+ const _c0$6 = function () { return { standalone: true }; };
61
+ function ArraySessionComponent_div_4_div_4_Template(rf, ctx) { if (rf & 1) {
62
+ const _r8 = i0.ɵɵgetCurrentView();
63
+ i0.ɵɵelementStart(0, "div", 0)(1, "div", 12)(2, "label", 13);
64
+ i0.ɵɵtext(3, "Loop");
65
+ i0.ɵɵelementEnd();
66
+ i0.ɵɵelementStart(4, "input", 14);
67
+ i0.ɵɵlistener("ngModelChange", function ArraySessionComponent_div_4_div_4_Template_input_ngModelChange_4_listener($event) { i0.ɵɵrestoreView(_r8); const item_r2 = i0.ɵɵnextContext().$implicit; return i0.ɵɵresetView(item_r2.loop = $event); })("dndDrop", function ArraySessionComponent_div_4_div_4_Template_input_dndDrop_4_listener($event) { i0.ɵɵrestoreView(_r8); const item_r2 = i0.ɵɵnextContext().$implicit; const ctx_r9 = i0.ɵɵnextContext(); return i0.ɵɵresetView(item_r2.loop = ctx_r9.onDrop($event, item_r2.loop)); });
68
+ i0.ɵɵelementEnd()();
69
+ i0.ɵɵelementStart(5, "div", 15)(6, "label", 13);
70
+ i0.ɵɵtext(7, "Alias");
71
+ i0.ɵɵelementEnd();
72
+ i0.ɵɵelementStart(8, "input", 14);
73
+ i0.ɵɵlistener("ngModelChange", function ArraySessionComponent_div_4_div_4_Template_input_ngModelChange_8_listener($event) { i0.ɵɵrestoreView(_r8); const item_r2 = i0.ɵɵnextContext().$implicit; return i0.ɵɵresetView(item_r2.alias = $event); })("dndDrop", function ArraySessionComponent_div_4_div_4_Template_input_dndDrop_8_listener($event) { i0.ɵɵrestoreView(_r8); const item_r2 = i0.ɵɵnextContext().$implicit; const ctx_r13 = i0.ɵɵnextContext(); return i0.ɵɵresetView(item_r2.alias = ctx_r13.onDrop($event, item_r2.alias)); });
74
+ i0.ɵɵelementEnd()()();
75
+ } if (rf & 2) {
76
+ const item_r2 = i0.ɵɵnextContext().$implicit;
77
+ i0.ɵɵadvance(4);
78
+ i0.ɵɵproperty("ngModel", item_r2.loop)("ngModelOptions", i0.ɵɵpureFunction0(4, _c0$6));
79
+ i0.ɵɵadvance(4);
80
+ i0.ɵɵproperty("ngModel", item_r2.alias)("ngModelOptions", i0.ɵɵpureFunction0(5, _c0$6));
81
+ } }
82
+ function ArraySessionComponent_div_4_ng_container_5_Template(rf, ctx) { if (rf & 1) {
83
+ i0.ɵɵelementContainer(0);
84
+ } }
85
+ const _c1$2 = function (a0, a1, a2) { return { items: a0, index: a1, mappingAttributes: a2 }; };
86
+ const _c2 = function (a0) { return { $implicit: a0 }; };
87
+ function ArraySessionComponent_div_4_Template(rf, ctx) { if (rf & 1) {
88
+ const _r17 = i0.ɵɵgetCurrentView();
89
+ i0.ɵɵelementStart(0, "div", 7)(1, "div", 8);
90
+ i0.ɵɵtext(2);
91
+ i0.ɵɵelementStart(3, "i", 9);
92
+ i0.ɵɵlistener("click", function ArraySessionComponent_div_4_Template_i_click_3_listener() { const restoredCtx = i0.ɵɵrestoreView(_r17); const item_r2 = restoredCtx.$implicit; const ctx_r16 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r16.remove(item_r2)); });
93
+ i0.ɵɵelementEnd()();
94
+ i0.ɵɵtemplate(4, ArraySessionComponent_div_4_div_4_Template, 9, 6, "div", 10);
95
+ i0.ɵɵtemplate(5, ArraySessionComponent_div_4_ng_container_5_Template, 1, 0, "ng-container", 11);
96
+ i0.ɵɵelementEnd();
97
+ } if (rf & 2) {
98
+ const item_r2 = ctx.$implicit;
99
+ const index_r3 = ctx.index;
100
+ const ctx_r0 = i0.ɵɵnextContext();
101
+ i0.ɵɵadvance(2);
102
+ i0.ɵɵtextInterpolate2("", ctx_r0.removeLabel, " ", index_r3 + 1, " ");
103
+ i0.ɵɵadvance(2);
104
+ i0.ɵɵproperty("ngIf", item_r2.mappingAttributes || item_r2.mappingAttributes === "");
105
+ i0.ɵɵadvance(1);
106
+ i0.ɵɵproperty("ngTemplateOutlet", ctx_r0.subsectionItem)("ngTemplateOutletContext", i0.ɵɵpureFunction1(9, _c2, i0.ɵɵpureFunction3(5, _c1$2, ctx_r0.model, index_r3, item_r2.mappingAttributes || item_r2.mappingAttributes === "" ? item_r2.mappingAttributes : item_r2)));
107
+ } }
108
+ function ArraySessionComponent_button_9_Template(rf, ctx) { if (rf & 1) {
109
+ const _r19 = i0.ɵɵgetCurrentView();
110
+ i0.ɵɵelementStart(0, "button", 16);
111
+ i0.ɵɵlistener("click", function ArraySessionComponent_button_9_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r19); const ctx_r18 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r18.addLoop()); });
112
+ i0.ɵɵtext(1);
113
+ i0.ɵɵelementEnd();
114
+ } if (rf & 2) {
115
+ const ctx_r1 = i0.ɵɵnextContext();
116
+ i0.ɵɵadvance(1);
117
+ i0.ɵɵtextInterpolate(ctx_r1.addLoopLabel);
118
+ } }
119
+ class ArraySessionComponent extends BaseSchemaComponent {
120
+ constructor() {
121
+ super(...arguments);
122
+ this.label = '';
123
+ this.removeLabel = 'Remove';
124
+ this.addItemLabel = 'Add Item';
125
+ this.addLoopLabel = 'Add Loop';
126
+ this.showAddLoop = true;
127
+ this.onAdd = new EventEmitter();
128
+ this.onAddLoop = new EventEmitter();
129
+ this.subsectionItem = null;
130
+ }
131
+ add() {
132
+ this.onAdd.next();
133
+ }
134
+ addLoop() {
135
+ this.onAddLoop.next();
136
+ }
137
+ remove(item) {
138
+ const values = this.model;
139
+ const index = values.indexOf(item);
140
+ values.splice(index, 1);
141
+ this.model = values;
142
+ }
143
+ trackByIndex(index, obj) {
144
+ return index;
145
+ }
146
+ }
147
+ ArraySessionComponent.ɵfac = /*@__PURE__*/ function () { let ɵArraySessionComponent_BaseFactory; return function ArraySessionComponent_Factory(t) { return (ɵArraySessionComponent_BaseFactory || (ɵArraySessionComponent_BaseFactory = i0.ɵɵgetInheritedFactory(ArraySessionComponent)))(t || ArraySessionComponent); }; }();
148
+ ArraySessionComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ArraySessionComponent, selectors: [["array-session"]], contentQueries: function ArraySessionComponent_ContentQueries(rf, ctx, dirIndex) { if (rf & 1) {
149
+ i0.ɵɵcontentQuery(dirIndex, TemplateRef, 5, TemplateRef);
150
+ } if (rf & 2) {
151
+ let _t;
152
+ i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.subsectionItem = _t.first);
153
+ } }, inputs: { label: "label", removeLabel: "removeLabel", addItemLabel: "addItemLabel", addLoopLabel: "addLoopLabel", showAddLoop: "showAddLoop" }, outputs: { onAdd: "onAdd", onAddLoop: "onAddLoop" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 10, vars: 5, consts: [[1, "row"], [1, "col-md-12"], [1, "info-label", "bold"], ["class", "subsection-element", 4, "ngFor", "ngForOf", "ngForTrackBy"], [1, "row", "add-buttons"], [1, "btn", "btn-outline-primary", "float-left", "btn-personal-edit", 3, "click"], ["class", "btn btn-outline-primary float-left btn-personal-edit ml-2", 3, "click", 4, "ngIf"], [1, "subsection-element"], [1, "subsection-item-title"], [1, "far", "fa-trash-alt", 3, "click"], ["class", "row", 4, "ngIf"], [4, "ngTemplateOutlet", "ngTemplateOutletContext"], [1, "col-md-8"], [1, "info-label"], ["type", "text", "dndDropzone", "", 1, "form-control", 3, "ngModel", "ngModelOptions", "ngModelChange", "dndDrop"], [1, "col-md-4"], [1, "btn", "btn-outline-primary", "float-left", "btn-personal-edit", "ml-2", 3, "click"]], template: function ArraySessionComponent_Template(rf, ctx) { if (rf & 1) {
154
+ i0.ɵɵelementStart(0, "div", 0)(1, "div", 1)(2, "label", 2);
155
+ i0.ɵɵtext(3);
156
+ i0.ɵɵelementEnd();
157
+ i0.ɵɵtemplate(4, ArraySessionComponent_div_4_Template, 6, 11, "div", 3);
158
+ i0.ɵɵelementEnd()();
159
+ i0.ɵɵelementStart(5, "div", 4)(6, "div", 1)(7, "button", 5);
160
+ i0.ɵɵlistener("click", function ArraySessionComponent_Template_button_click_7_listener() { return ctx.add(); });
161
+ i0.ɵɵtext(8);
162
+ i0.ɵɵelementEnd();
163
+ i0.ɵɵtemplate(9, ArraySessionComponent_button_9_Template, 2, 1, "button", 6);
164
+ i0.ɵɵelementEnd()();
165
+ } if (rf & 2) {
166
+ i0.ɵɵadvance(3);
167
+ i0.ɵɵtextInterpolate(ctx.label);
168
+ i0.ɵɵadvance(1);
169
+ i0.ɵɵproperty("ngForOf", ctx.model)("ngForTrackBy", ctx.trackByIndex);
170
+ i0.ɵɵadvance(4);
171
+ i0.ɵɵtextInterpolate(ctx.addItemLabel);
172
+ i0.ɵɵadvance(1);
173
+ i0.ɵɵproperty("ngIf", ctx.showAddLoop);
174
+ } }, dependencies: [i1.NgForOf, i1.NgIf, i1.NgTemplateOutlet, i2.DndDropzoneDirective, i3.DefaultValueAccessor, i3.NgControlStatus, i3.NgModel], styles: [".subsection-element[_ngcontent-%COMP%]{padding:5px 15px 15px;margin-top:10px;border:1px solid #CCC;border-radius:5px;background:#FFF}.subsection-element[_ngcontent-%COMP%]:first-child{margin-top:0!important}.btn-personal-edit[_ngcontent-%COMP%]{margin:5px 0}.subsection-item-title[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;width:calc(100% + 30px);padding:7px 10px 7px 14px;margin-top:-5px;margin-bottom:5px;margin-left:-15px;background:#EEE;border-radius:5px 5px 0 0;font-weight:700;border-bottom:1px solid #CCC}.subsection-item-title[_ngcontent-%COMP%] .fa-trash-alt[_ngcontent-%COMP%]{color:red;cursor:pointer}.subsection-item-title[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{font-weight:700}.add-buttons[_ngcontent-%COMP%]{margin-top:5px}"] });
175
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ArraySessionComponent, [{
176
+ type: Component,
177
+ args: [{ selector: 'array-session', template: "<div class=\"row\">\r\n <div class=\"col-md-12\">\r\n <label class=\"info-label bold\">{{ label }}</label>\r\n <div class=\"subsection-element\" *ngFor=\"let item of model; let index = index; trackBy:trackByIndex;\">\r\n <div class=\"subsection-item-title\">{{ removeLabel }} {{ index + 1 }}\r\n <i class=\"far fa-trash-alt\" (click)=\"remove(item)\"></i>\r\n </div>\r\n <div class=\"row\" *ngIf=\"item.mappingAttributes || item.mappingAttributes === ''\">\r\n <div class=\"col-md-8\">\r\n <label class=\"info-label\">Loop</label>\r\n <input class=\"form-control\" type=\"text\" [(ngModel)]=\"item.loop\" [ngModelOptions]=\"{standalone: true}\"\r\n dndDropzone (dndDrop)=\"item.loop = this.onDrop($event, item.loop)\" />\r\n </div>\r\n <div class=\"col-md-4\">\r\n <label class=\"info-label\">Alias</label>\r\n <input class=\"form-control\" type=\"text\" [(ngModel)]=\"item.alias\" [ngModelOptions]=\"{standalone: true}\"\r\n dndDropzone (dndDrop)=\"item.alias = this.onDrop($event, item.alias)\" />\r\n </div>\r\n </div>\r\n <ng-container *ngTemplateOutlet=\"subsectionItem, context: {\r\n $implicit: {\r\n items: model, index: index,\r\n mappingAttributes: (item.mappingAttributes || item.mappingAttributes === '') ? item.mappingAttributes : item\r\n }\r\n }\"></ng-container>\r\n </div>\r\n </div>\r\n</div>\r\n<div class=\"row add-buttons\">\r\n <div class=\"col-md-12\">\r\n <button class=\"btn btn-outline-primary float-left btn-personal-edit\" (click)=\"add()\">{{ this.addItemLabel }}</button>\r\n <button class=\"btn btn-outline-primary float-left btn-personal-edit ml-2\" *ngIf=\"showAddLoop\" (click)=\"addLoop()\">{{ this.addLoopLabel }}</button>\r\n </div>\r\n</div>\r\n", styles: [".subsection-element{padding:5px 15px 15px;margin-top:10px;border:1px solid #CCC;border-radius:5px;background:#FFF}.subsection-element:first-child{margin-top:0!important}.btn-personal-edit{margin:5px 0}.subsection-item-title{display:flex;justify-content:space-between;align-items:center;width:calc(100% + 30px);padding:7px 10px 7px 14px;margin-top:-5px;margin-bottom:5px;margin-left:-15px;background:#EEE;border-radius:5px 5px 0 0;font-weight:700;border-bottom:1px solid #CCC}.subsection-item-title .fa-trash-alt{color:red;cursor:pointer}.subsection-item-title label{font-weight:700}.add-buttons{margin-top:5px}\n"] }]
178
+ }], null, { label: [{
179
+ type: Input
180
+ }], removeLabel: [{
181
+ type: Input
182
+ }], addItemLabel: [{
183
+ type: Input
184
+ }], addLoopLabel: [{
185
+ type: Input
186
+ }], showAddLoop: [{
187
+ type: Input
188
+ }], onAdd: [{
189
+ type: Output
190
+ }], onAddLoop: [{
191
+ type: Output
192
+ }], subsectionItem: [{
193
+ type: ContentChild,
194
+ args: [TemplateRef, { read: TemplateRef }]
195
+ }] }); })();
196
+
197
+ function SchemaFormComponent_div_0_Template(rf, ctx) { if (rf & 1) {
198
+ const _r4 = i0.ɵɵgetCurrentView();
199
+ i0.ɵɵelementStart(0, "div", 1)(1, "schema-input", 2);
200
+ i0.ɵɵlistener("modelChange", function SchemaFormComponent_div_0_Template_schema_input_modelChange_1_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r3 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r3.model = $event); });
201
+ i0.ɵɵelementEnd();
202
+ i0.ɵɵelementStart(2, "schema-object", 3);
203
+ i0.ɵɵlistener("modelChange", function SchemaFormComponent_div_0_Template_schema_object_modelChange_2_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r5 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r5.model = $event); });
204
+ i0.ɵɵelementEnd();
205
+ i0.ɵɵelementStart(3, "schema-array", 3);
206
+ i0.ɵɵlistener("modelChange", function SchemaFormComponent_div_0_Template_schema_array_modelChange_3_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r6 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r6.model = $event); });
207
+ i0.ɵɵelementEnd()();
208
+ } if (rf & 2) {
209
+ const schema_r1 = ctx.$implicit;
210
+ const i_r2 = ctx.index;
211
+ const ctx_r0 = i0.ɵɵnextContext();
212
+ i0.ɵɵadvance(1);
213
+ i0.ɵɵproperty("selectPlaceHolderLabel", ctx_r0.selectPlaceHolderLabel)("selectSearchPlaceHolderLabel", ctx_r0.selectSearchPlaceHolderLabel)("selectClearLabel", ctx_r0.selectClearLabel)("selectNotFoundLabel", ctx_r0.selectNotFoundLabel)("requiredLabel", ctx_r0.requiredLabel)("idPrefix", ctx_r0.idPrefix)("model", ctx_r0.model)("schema", schema_r1)("editing", ctx_r0.editing)("index", i_r2);
214
+ i0.ɵɵadvance(1);
215
+ i0.ɵɵproperty("selectPlaceHolderLabel", ctx_r0.selectPlaceHolderLabel)("selectSearchPlaceHolderLabel", ctx_r0.selectSearchPlaceHolderLabel)("selectClearLabel", ctx_r0.selectClearLabel)("selectNotFoundLabel", ctx_r0.selectNotFoundLabel)("requiredLabel", ctx_r0.requiredLabel)("addItemLabel", ctx_r0.addItemLabel)("addLoopLabel", ctx_r0.addLoopLabel)("additionalAttributesLabel", ctx_r0.additionalAttributesLabel)("customAttributeRemoveLabel", ctx_r0.customAttributeRemoveLabel)("newCustomFieldNameLabel", ctx_r0.newCustomFieldNameLabel)("newCustomFieldValueLabel", ctx_r0.newCustomFieldValueLabel)("newCustomFieldAddLabel", ctx_r0.newCustomFieldAddLabel)("newCustomFieldSaveLabel", ctx_r0.newCustomFieldSaveLabel)("newCustomFieldCancelLabel", ctx_r0.newCustomFieldCancelLabel)("idPrefix", ctx_r0.idPrefix)("model", ctx_r0.model)("schema", schema_r1)("editing", ctx_r0.editing)("index", i_r2);
216
+ i0.ɵɵadvance(1);
217
+ i0.ɵɵproperty("selectPlaceHolderLabel", ctx_r0.selectPlaceHolderLabel)("selectSearchPlaceHolderLabel", ctx_r0.selectSearchPlaceHolderLabel)("selectClearLabel", ctx_r0.selectClearLabel)("selectNotFoundLabel", ctx_r0.selectNotFoundLabel)("requiredLabel", ctx_r0.requiredLabel)("addItemLabel", ctx_r0.addItemLabel)("addLoopLabel", ctx_r0.addLoopLabel)("additionalAttributesLabel", ctx_r0.additionalAttributesLabel)("customAttributeRemoveLabel", ctx_r0.customAttributeRemoveLabel)("newCustomFieldNameLabel", ctx_r0.newCustomFieldNameLabel)("newCustomFieldValueLabel", ctx_r0.newCustomFieldValueLabel)("newCustomFieldAddLabel", ctx_r0.newCustomFieldAddLabel)("newCustomFieldSaveLabel", ctx_r0.newCustomFieldSaveLabel)("newCustomFieldCancelLabel", ctx_r0.newCustomFieldCancelLabel)("idPrefix", ctx_r0.idPrefix)("model", ctx_r0.model)("schema", schema_r1)("editing", ctx_r0.editing)("index", i_r2);
218
+ } }
219
+ class SchemaFormComponent extends BaseSchemaComponent {
220
+ constructor() {
221
+ super(...arguments);
222
+ this.requiredLabel = '(required)';
223
+ this.addItemLabel = 'Add Item';
224
+ this.addLoopLabel = 'Add Loop';
225
+ this.additionalAttributesLabel = 'Additional Fields';
226
+ this.customAttributeRemoveLabel = 'Remove';
227
+ this.newCustomFieldNameLabel = 'Name';
228
+ this.newCustomFieldValueLabel = 'Value';
229
+ this.newCustomFieldAddLabel = 'Add';
230
+ this.newCustomFieldSaveLabel = 'Save';
231
+ this.newCustomFieldCancelLabel = 'Cancel';
232
+ this.selectPlaceHolderLabel = 'Select Item';
233
+ this.selectSearchPlaceHolderLabel = 'Search';
234
+ this.selectClearLabel = 'Clear';
235
+ this.selectNotFoundLabel = 'No Items Found';
236
+ this.schemas = [];
237
+ this.customProperties = false;
238
+ this.editing = false;
239
+ this.loaded = false;
240
+ }
241
+ ngAfterContentInit() {
242
+ this.loaded = true;
243
+ }
244
+ onDrop($event, modelElement) {
245
+ return onDropStruct($event, modelElement);
246
+ }
247
+ getId(index) {
248
+ return `${this.idPrefix}-struct-${index}`;
249
+ }
250
+ }
251
+ SchemaFormComponent.ɵfac = /*@__PURE__*/ function () { let ɵSchemaFormComponent_BaseFactory; return function SchemaFormComponent_Factory(t) { return (ɵSchemaFormComponent_BaseFactory || (ɵSchemaFormComponent_BaseFactory = i0.ɵɵgetInheritedFactory(SchemaFormComponent)))(t || SchemaFormComponent); }; }();
252
+ SchemaFormComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SchemaFormComponent, selectors: [["schema-form"]], inputs: { requiredLabel: "requiredLabel", addItemLabel: "addItemLabel", addLoopLabel: "addLoopLabel", additionalAttributesLabel: "additionalAttributesLabel", customAttributeRemoveLabel: "customAttributeRemoveLabel", newCustomFieldNameLabel: "newCustomFieldNameLabel", newCustomFieldValueLabel: "newCustomFieldValueLabel", newCustomFieldAddLabel: "newCustomFieldAddLabel", newCustomFieldSaveLabel: "newCustomFieldSaveLabel", newCustomFieldCancelLabel: "newCustomFieldCancelLabel", selectPlaceHolderLabel: "selectPlaceHolderLabel", selectSearchPlaceHolderLabel: "selectSearchPlaceHolderLabel", selectClearLabel: "selectClearLabel", selectNotFoundLabel: "selectNotFoundLabel", idPrefix: "idPrefix", schemas: "schemas", customProperties: "customProperties", editing: "editing", inputType: "inputType" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "schema-properties", 4, "ngFor", "ngForOf"], [1, "schema-properties"], [3, "selectPlaceHolderLabel", "selectSearchPlaceHolderLabel", "selectClearLabel", "selectNotFoundLabel", "requiredLabel", "idPrefix", "model", "schema", "editing", "index", "modelChange"], [3, "selectPlaceHolderLabel", "selectSearchPlaceHolderLabel", "selectClearLabel", "selectNotFoundLabel", "requiredLabel", "addItemLabel", "addLoopLabel", "additionalAttributesLabel", "customAttributeRemoveLabel", "newCustomFieldNameLabel", "newCustomFieldValueLabel", "newCustomFieldAddLabel", "newCustomFieldSaveLabel", "newCustomFieldCancelLabel", "idPrefix", "model", "schema", "editing", "index", "modelChange"]], template: function SchemaFormComponent_Template(rf, ctx) { if (rf & 1) {
253
+ i0.ɵɵtemplate(0, SchemaFormComponent_div_0_Template, 4, 48, "div", 0);
254
+ } if (rf & 2) {
255
+ i0.ɵɵproperty("ngForOf", ctx.schemas);
256
+ } } });
257
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SchemaFormComponent, [{
258
+ type: Component,
259
+ args: [{ selector: 'schema-form', template: "<div class=\"schema-properties\" *ngFor=\"let schema of schemas; let i = index\">\r\n <schema-input\r\n [selectPlaceHolderLabel]=\"selectPlaceHolderLabel\"\r\n [selectSearchPlaceHolderLabel]=\"selectSearchPlaceHolderLabel\"\r\n [selectClearLabel]=\"selectClearLabel\"\r\n [selectNotFoundLabel]=\"selectNotFoundLabel\"\r\n [requiredLabel]=\"requiredLabel\"\r\n [idPrefix]=\"idPrefix\"\r\n [(model)]=\"model\"\r\n [schema]=\"schema\"\r\n [editing]=\"this.editing\"\r\n [index]=\"i\">\r\n </schema-input>\r\n <schema-object\r\n [selectPlaceHolderLabel]=\"selectPlaceHolderLabel\"\r\n [selectSearchPlaceHolderLabel]=\"selectSearchPlaceHolderLabel\"\r\n [selectClearLabel]=\"selectClearLabel\"\r\n [selectNotFoundLabel]=\"selectNotFoundLabel\"\r\n [requiredLabel]=\"requiredLabel\"\r\n [addItemLabel]=\"addItemLabel\"\r\n [addLoopLabel]=\"addLoopLabel\"\r\n [additionalAttributesLabel]=\"additionalAttributesLabel\"\r\n [customAttributeRemoveLabel]=\"customAttributeRemoveLabel\"\r\n [newCustomFieldNameLabel]=\"newCustomFieldNameLabel\"\r\n [newCustomFieldValueLabel]=\"newCustomFieldValueLabel\"\r\n [newCustomFieldAddLabel]=\"newCustomFieldAddLabel\"\r\n [newCustomFieldSaveLabel]=\"newCustomFieldSaveLabel\"\r\n [newCustomFieldCancelLabel]=\"newCustomFieldCancelLabel\"\r\n [idPrefix]=\"idPrefix\"\r\n [(model)]=\"model\"\r\n [schema]=\"schema\"\r\n [editing]=\"this.editing\"\r\n [index]=\"i\">\r\n </schema-object>\r\n <schema-array\r\n [selectPlaceHolderLabel]=\"selectPlaceHolderLabel\"\r\n [selectSearchPlaceHolderLabel]=\"selectSearchPlaceHolderLabel\"\r\n [selectClearLabel]=\"selectClearLabel\"\r\n [selectNotFoundLabel]=\"selectNotFoundLabel\"\r\n [requiredLabel]=\"requiredLabel\"\r\n [addItemLabel]=\"addItemLabel\"\r\n [addLoopLabel]=\"addLoopLabel\"\r\n [additionalAttributesLabel]=\"additionalAttributesLabel\"\r\n [customAttributeRemoveLabel]=\"customAttributeRemoveLabel\"\r\n [newCustomFieldNameLabel]=\"newCustomFieldNameLabel\"\r\n [newCustomFieldValueLabel]=\"newCustomFieldValueLabel\"\r\n [newCustomFieldAddLabel]=\"newCustomFieldAddLabel\"\r\n [newCustomFieldSaveLabel]=\"newCustomFieldSaveLabel\"\r\n [newCustomFieldCancelLabel]=\"newCustomFieldCancelLabel\"\r\n [idPrefix]=\"idPrefix\"\r\n [(model)]=\"model\"\r\n [schema]=\"schema\"\r\n [editing]=\"this.editing\"\r\n [index]=\"i\">\r\n </schema-array>\r\n</div>\r\n" }]
260
+ }], null, { requiredLabel: [{
261
+ type: Input
262
+ }], addItemLabel: [{
263
+ type: Input
264
+ }], addLoopLabel: [{
265
+ type: Input
266
+ }], additionalAttributesLabel: [{
267
+ type: Input
268
+ }], customAttributeRemoveLabel: [{
269
+ type: Input
270
+ }], newCustomFieldNameLabel: [{
271
+ type: Input
272
+ }], newCustomFieldValueLabel: [{
273
+ type: Input
274
+ }], newCustomFieldAddLabel: [{
275
+ type: Input
276
+ }], newCustomFieldSaveLabel: [{
277
+ type: Input
278
+ }], newCustomFieldCancelLabel: [{
279
+ type: Input
280
+ }], selectPlaceHolderLabel: [{
281
+ type: Input
282
+ }], selectSearchPlaceHolderLabel: [{
283
+ type: Input
284
+ }], selectClearLabel: [{
285
+ type: Input
286
+ }], selectNotFoundLabel: [{
287
+ type: Input
288
+ }], idPrefix: [{
289
+ type: Input
290
+ }], schemas: [{
291
+ type: Input
292
+ }], customProperties: [{
293
+ type: Input
294
+ }], editing: [{
295
+ type: Input
296
+ }], inputType: [{
297
+ type: Input
298
+ }] }); })();
299
+
300
+ const _c0$5 = function () { return { standalone: true }; };
301
+ function SchemaCustomAttributesComponent_div_0_Template(rf, ctx) { if (rf & 1) {
302
+ const _r8 = i0.ɵɵgetCurrentView();
303
+ i0.ɵɵelementStart(0, "div", 6)(1, "div", 7)(2, "label", 8);
304
+ i0.ɵɵtext(3);
305
+ i0.ɵɵelementEnd();
306
+ i0.ɵɵelementStart(4, "span", 9);
307
+ i0.ɵɵlistener("click", function SchemaCustomAttributesComponent_div_0_Template_span_click_4_listener() { const restoredCtx = i0.ɵɵrestoreView(_r8); const i_r6 = restoredCtx.index; const ctx_r7 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r7.removeCustomAttribute(i_r6)); });
308
+ i0.ɵɵelement(5, "i", 10);
309
+ i0.ɵɵelementEnd();
310
+ i0.ɵɵelementStart(6, "input", 11);
311
+ i0.ɵɵlistener("ngModelChange", function SchemaCustomAttributesComponent_div_0_Template_input_ngModelChange_6_listener($event) { const restoredCtx = i0.ɵɵrestoreView(_r8); const attribute_r5 = restoredCtx.$implicit; return i0.ɵɵresetView(attribute_r5.value = $event); })("dndDrop", function SchemaCustomAttributesComponent_div_0_Template_input_dndDrop_6_listener($event) { const restoredCtx = i0.ɵɵrestoreView(_r8); const attribute_r5 = restoredCtx.$implicit; const ctx_r10 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r10.onDropAttr($event, "value", attribute_r5)); });
312
+ i0.ɵɵelementEnd()()();
313
+ } if (rf & 2) {
314
+ const attribute_r5 = ctx.$implicit;
315
+ const ctx_r0 = i0.ɵɵnextContext();
316
+ i0.ɵɵadvance(3);
317
+ i0.ɵɵtextInterpolate(attribute_r5.label);
318
+ i0.ɵɵadvance(2);
319
+ i0.ɵɵproperty("matTooltip", ctx_r0.customAttributeRemoveLabel);
320
+ i0.ɵɵadvance(1);
321
+ i0.ɵɵproperty("ngModel", attribute_r5.value)("ngModelOptions", i0.ɵɵpureFunction0(4, _c0$5));
322
+ } }
323
+ function SchemaCustomAttributesComponent_div_1_Template(rf, ctx) { if (rf & 1) {
324
+ const _r12 = i0.ɵɵgetCurrentView();
325
+ i0.ɵɵelementStart(0, "div", 12)(1, "div", 13)(2, "div", 7)(3, "label", 8);
326
+ i0.ɵɵtext(4);
327
+ i0.ɵɵelementStart(5, "strong");
328
+ i0.ɵɵtext(6, "*");
329
+ i0.ɵɵelementEnd()();
330
+ i0.ɵɵelementStart(7, "input", 11);
331
+ i0.ɵɵlistener("ngModelChange", function SchemaCustomAttributesComponent_div_1_Template_input_ngModelChange_7_listener($event) { i0.ɵɵrestoreView(_r12); const ctx_r11 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r11.newCustomField.label = $event); })("dndDrop", function SchemaCustomAttributesComponent_div_1_Template_input_dndDrop_7_listener($event) { i0.ɵɵrestoreView(_r12); const ctx_r13 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r13.onDropAttr($event, "label", ctx_r13.newCustomField)); });
332
+ i0.ɵɵelementEnd()()();
333
+ i0.ɵɵelementStart(8, "div", 13)(9, "div", 7)(10, "label", 8);
334
+ i0.ɵɵtext(11);
335
+ i0.ɵɵelementStart(12, "strong");
336
+ i0.ɵɵtext(13, "*");
337
+ i0.ɵɵelementEnd()();
338
+ i0.ɵɵelementStart(14, "input", 11);
339
+ i0.ɵɵlistener("ngModelChange", function SchemaCustomAttributesComponent_div_1_Template_input_ngModelChange_14_listener($event) { i0.ɵɵrestoreView(_r12); const ctx_r14 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r14.newCustomField.value = $event); })("dndDrop", function SchemaCustomAttributesComponent_div_1_Template_input_dndDrop_14_listener($event) { i0.ɵɵrestoreView(_r12); const ctx_r15 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r15.onDropAttr($event, "value", ctx_r15.newCustomField)); });
340
+ i0.ɵɵelementEnd()()()();
341
+ } if (rf & 2) {
342
+ const ctx_r1 = i0.ɵɵnextContext();
343
+ i0.ɵɵadvance(4);
344
+ i0.ɵɵtextInterpolate(ctx_r1.newCustomFieldNameLabel);
345
+ i0.ɵɵadvance(3);
346
+ i0.ɵɵproperty("ngModel", ctx_r1.newCustomField.label)("ngModelOptions", i0.ɵɵpureFunction0(6, _c0$5));
347
+ i0.ɵɵadvance(4);
348
+ i0.ɵɵtextInterpolate(ctx_r1.newCustomFieldValueLabel);
349
+ i0.ɵɵadvance(3);
350
+ i0.ɵɵproperty("ngModel", ctx_r1.newCustomField.value)("ngModelOptions", i0.ɵɵpureFunction0(7, _c0$5));
351
+ } }
352
+ function SchemaCustomAttributesComponent_button_4_Template(rf, ctx) { if (rf & 1) {
353
+ const _r17 = i0.ɵɵgetCurrentView();
354
+ i0.ɵɵelementStart(0, "button", 14);
355
+ i0.ɵɵlistener("click", function SchemaCustomAttributesComponent_button_4_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r17); const ctx_r16 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r16.newCustomField = {}); });
356
+ i0.ɵɵtext(1);
357
+ i0.ɵɵelementEnd();
358
+ } if (rf & 2) {
359
+ const ctx_r2 = i0.ɵɵnextContext();
360
+ i0.ɵɵadvance(1);
361
+ i0.ɵɵtextInterpolate1(" ", ctx_r2.newCustomFieldAddLabel, " ");
362
+ } }
363
+ function SchemaCustomAttributesComponent_button_5_Template(rf, ctx) { if (rf & 1) {
364
+ const _r19 = i0.ɵɵgetCurrentView();
365
+ i0.ɵɵelementStart(0, "button", 15);
366
+ i0.ɵɵlistener("click", function SchemaCustomAttributesComponent_button_5_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r19); const ctx_r18 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r18.newCustomField = null); });
367
+ i0.ɵɵtext(1);
368
+ i0.ɵɵelementEnd();
369
+ } if (rf & 2) {
370
+ const ctx_r3 = i0.ɵɵnextContext();
371
+ i0.ɵɵadvance(1);
372
+ i0.ɵɵtextInterpolate1(" ", ctx_r3.newCustomFieldCancelLabel, " ");
373
+ } }
374
+ function SchemaCustomAttributesComponent_button_6_Template(rf, ctx) { if (rf & 1) {
375
+ const _r21 = i0.ɵɵgetCurrentView();
376
+ i0.ɵɵelementStart(0, "button", 14);
377
+ i0.ɵɵlistener("click", function SchemaCustomAttributesComponent_button_6_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r21); const ctx_r20 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r20.saveNewAttribute(ctx_r20.newCustomField)); });
378
+ i0.ɵɵtext(1);
379
+ i0.ɵɵelementEnd();
380
+ } if (rf & 2) {
381
+ const ctx_r4 = i0.ɵɵnextContext();
382
+ i0.ɵɵadvance(1);
383
+ i0.ɵɵtextInterpolate1(" ", ctx_r4.newCustomFieldSaveLabel, " ");
384
+ } }
385
+ class SchemaCustomAttributesComponent extends BaseSchemaComponent {
386
+ constructor() {
387
+ super(...arguments);
388
+ this.customAttributeRemoveLabel = 'Remove';
389
+ this.newCustomFieldNameLabel = 'Name';
390
+ this.newCustomFieldValueLabel = 'Value';
391
+ this.newCustomFieldAddLabel = 'Add';
392
+ this.newCustomFieldSaveLabel = 'Save';
393
+ this.newCustomFieldCancelLabel = 'Cancel';
394
+ this.onSaveAttribute = new EventEmitter();
395
+ this.onDropOnAttribute = new EventEmitter();
396
+ }
397
+ ngAfterContentInit() {
398
+ if (!this.model) {
399
+ this.model = [];
400
+ }
401
+ }
402
+ saveNewAttribute(newCustomField) {
403
+ this.onSaveAttribute.emit(newCustomField);
404
+ this.model.push(newCustomField);
405
+ this.newCustomField = null;
406
+ this.modelChange.emit(this.model);
407
+ }
408
+ removeCustomAttribute(attributeIndex) {
409
+ this.model.splice(attributeIndex, 1);
410
+ this.modelChange.emit(this.model);
411
+ }
412
+ onDropAttr($event, value, newCustomField) {
413
+ if (!newCustomField[value]) {
414
+ newCustomField[value] = '';
415
+ }
416
+ newCustomField[value] += `{{${$event.data}}}`;
417
+ }
418
+ }
419
+ SchemaCustomAttributesComponent.ɵfac = /*@__PURE__*/ function () { let ɵSchemaCustomAttributesComponent_BaseFactory; return function SchemaCustomAttributesComponent_Factory(t) { return (ɵSchemaCustomAttributesComponent_BaseFactory || (ɵSchemaCustomAttributesComponent_BaseFactory = i0.ɵɵgetInheritedFactory(SchemaCustomAttributesComponent)))(t || SchemaCustomAttributesComponent); }; }();
420
+ SchemaCustomAttributesComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SchemaCustomAttributesComponent, selectors: [["schema-custom-attributes"]], inputs: { onDropFunction: "onDropFunction", customAttributeRemoveLabel: "customAttributeRemoveLabel", newCustomFieldNameLabel: "newCustomFieldNameLabel", newCustomFieldValueLabel: "newCustomFieldValueLabel", newCustomFieldAddLabel: "newCustomFieldAddLabel", newCustomFieldSaveLabel: "newCustomFieldSaveLabel", newCustomFieldCancelLabel: "newCustomFieldCancelLabel" }, outputs: { onSaveAttribute: "onSaveAttribute", onDropOnAttribute: "onDropOnAttribute" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 7, vars: 5, consts: [["class", "row custom-attributes", 4, "ngFor", "ngForOf"], ["class", "struct-custom-field", 4, "ngIf"], [1, "row", "actions-buttons"], [1, "col-md-12", "pull-right"], ["class", "btn btn-outline-primary float-left", 3, "click", 4, "ngIf"], ["class", "btn btn-outline-danger float-left ml-2", 3, "click", 4, "ngIf"], [1, "row", "custom-attributes"], [1, "col-md-12"], [1, "info-label"], [1, "customAttributeDeleteIcon", 3, "click"], [1, "far", "fa-trash-alt", 3, "matTooltip"], ["dndDropzone", "", 1, "form-control", 3, "ngModel", "ngModelOptions", "ngModelChange", "dndDrop"], [1, "struct-custom-field"], [1, "row"], [1, "btn", "btn-outline-primary", "float-left", 3, "click"], [1, "btn", "btn-outline-danger", "float-left", "ml-2", 3, "click"]], template: function SchemaCustomAttributesComponent_Template(rf, ctx) { if (rf & 1) {
421
+ i0.ɵɵtemplate(0, SchemaCustomAttributesComponent_div_0_Template, 7, 5, "div", 0);
422
+ i0.ɵɵtemplate(1, SchemaCustomAttributesComponent_div_1_Template, 15, 8, "div", 1);
423
+ i0.ɵɵelementStart(2, "div", 2)(3, "div", 3);
424
+ i0.ɵɵtemplate(4, SchemaCustomAttributesComponent_button_4_Template, 2, 1, "button", 4);
425
+ i0.ɵɵtemplate(5, SchemaCustomAttributesComponent_button_5_Template, 2, 1, "button", 5);
426
+ i0.ɵɵtemplate(6, SchemaCustomAttributesComponent_button_6_Template, 2, 1, "button", 4);
427
+ i0.ɵɵelementEnd()();
428
+ } if (rf & 2) {
429
+ i0.ɵɵproperty("ngForOf", ctx.model);
430
+ i0.ɵɵadvance(1);
431
+ i0.ɵɵproperty("ngIf", ctx.newCustomField);
432
+ i0.ɵɵadvance(3);
433
+ i0.ɵɵproperty("ngIf", !ctx.newCustomField);
434
+ i0.ɵɵadvance(1);
435
+ i0.ɵɵproperty("ngIf", ctx.newCustomField);
436
+ i0.ɵɵadvance(1);
437
+ i0.ɵɵproperty("ngIf", ctx.newCustomField && ctx.newCustomField.label && ctx.newCustomField.value);
438
+ } }, dependencies: [i1.NgForOf, i1.NgIf, i2.DndDropzoneDirective, i3.DefaultValueAccessor, i3.NgControlStatus, i3.NgModel, i2$1.MatTooltip], styles: [".customAttributeDeleteIcon[_ngcontent-%COMP%]{position:absolute;right:15px;top:4px;cursor:pointer;font-size:16px;color:red}.customAttributeDeleteIcon[_ngcontent-%COMP%]:hover{color:#777}.struct-custom-field[_ngcontent-%COMP%]{margin-top:16px;padding:8px 16px 16px;background-color:#ececec}"] });
439
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SchemaCustomAttributesComponent, [{
440
+ type: Component,
441
+ args: [{ selector: 'schema-custom-attributes', template: "<div class=\"row custom-attributes\" *ngFor=\"let attribute of model; let i = index\">\r\n <div class=\"col-md-12\">\r\n <label class=\"info-label\">{{ attribute.label }}</label>\r\n <span (click)=\"removeCustomAttribute(i)\" class=\"customAttributeDeleteIcon\">\r\n <i class=\"far fa-trash-alt\" [matTooltip]=\"this.customAttributeRemoveLabel\"></i>\r\n </span>\r\n\r\n <input\r\n class=\"form-control\"\r\n [(ngModel)]=\"attribute.value\"\r\n [ngModelOptions]=\"{standalone: true}\"\r\n dndDropzone\r\n (dndDrop)=\"onDropAttr($event, 'value', attribute)\"\r\n />\r\n </div>\r\n</div>\r\n<div *ngIf=\"newCustomField\" class=\"struct-custom-field\">\r\n <div class=\"row\">\r\n <div class=\"col-md-12\">\r\n <label class=\"info-label\">{{ this.newCustomFieldNameLabel }}<strong>*</strong></label>\r\n <input \r\n class=\"form-control\" \r\n [(ngModel)]=\"newCustomField.label\" \r\n [ngModelOptions]=\"{standalone: true}\"\r\n dndDropzone\r\n (dndDrop)=\"onDropAttr($event, 'label', newCustomField)\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"col-md-12\">\r\n <label class=\"info-label\">{{ this.newCustomFieldValueLabel }}<strong>*</strong></label>\r\n <input\r\n class=\"form-control\"\r\n [(ngModel)]=\"newCustomField.value\"\r\n [ngModelOptions]=\"{standalone: true}\"\r\n dndDropzone\r\n (dndDrop)=\"onDropAttr($event, 'value', newCustomField)\"\r\n />\r\n </div>\r\n </div>\r\n</div>\r\n<div class=\"row actions-buttons\">\r\n <div class=\"col-md-12 pull-right\">\r\n <button class=\"btn btn-outline-primary float-left\" *ngIf=\"!newCustomField\" (click)=\"newCustomField = {}\">\r\n {{ this.newCustomFieldAddLabel }}\r\n </button>\r\n <button\r\n class=\"btn btn-outline-danger float-left ml-2\"\r\n *ngIf=\"newCustomField\"\r\n (click)=\"newCustomField = null\"\r\n >\r\n {{ this.newCustomFieldCancelLabel }}\r\n </button>\r\n <button\r\n class=\"btn btn-outline-primary float-left\"\r\n *ngIf=\"newCustomField && newCustomField.label && newCustomField.value\"\r\n (click)=\"saveNewAttribute(newCustomField)\"\r\n >\r\n {{ this.newCustomFieldSaveLabel }}\r\n </button>\r\n </div>\r\n</div>\r\n", styles: [".customAttributeDeleteIcon{position:absolute;right:15px;top:4px;cursor:pointer;font-size:16px;color:red}.customAttributeDeleteIcon:hover{color:#777}.struct-custom-field{margin-top:16px;padding:8px 16px 16px;background-color:#ececec}\n"] }]
442
+ }], null, { onDropFunction: [{
443
+ type: Input
444
+ }], customAttributeRemoveLabel: [{
445
+ type: Input
446
+ }], newCustomFieldNameLabel: [{
447
+ type: Input
448
+ }], newCustomFieldValueLabel: [{
449
+ type: Input
450
+ }], newCustomFieldAddLabel: [{
451
+ type: Input
452
+ }], newCustomFieldSaveLabel: [{
453
+ type: Input
454
+ }], newCustomFieldCancelLabel: [{
455
+ type: Input
456
+ }], onSaveAttribute: [{
457
+ type: Output
458
+ }], onDropOnAttribute: [{
459
+ type: Output
460
+ }] }); })();
461
+
462
+ function SchemaArrayComponent_div_0_ng_template_2_schema_form_0_Template(rf, ctx) { if (rf & 1) {
463
+ const _r8 = i0.ɵɵgetCurrentView();
464
+ i0.ɵɵelementStart(0, "schema-form", 4);
465
+ i0.ɵɵlistener("modelChange", function SchemaArrayComponent_div_0_ng_template_2_schema_form_0_Template_schema_form_modelChange_0_listener($event) { i0.ɵɵrestoreView(_r8); const item_r3 = i0.ɵɵnextContext().$implicit; const ctx_r7 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r7.model[ctx_r7.schema.id][item_r3.index].mappingAttributes = $event); });
466
+ i0.ɵɵelementEnd();
467
+ } if (rf & 2) {
468
+ const item_r3 = i0.ɵɵnextContext().$implicit;
469
+ const ctx_r4 = i0.ɵɵnextContext(2);
470
+ i0.ɵɵproperty("selectPlaceHolderLabel", ctx_r4.selectPlaceHolderLabel)("selectSearchPlaceHolderLabel", ctx_r4.selectSearchPlaceHolderLabel)("selectClearLabel", ctx_r4.selectClearLabel)("selectNotFoundLabel", ctx_r4.selectNotFoundLabel)("requiredLabel", ctx_r4.requiredLabel)("addItemLabel", ctx_r4.addItemLabel)("addLoopLabel", ctx_r4.addLoopLabel)("additionalAttributesLabel", ctx_r4.additionalAttributesLabel)("customAttributeRemoveLabel", ctx_r4.customAttributeRemoveLabel)("newCustomFieldNameLabel", ctx_r4.newCustomFieldNameLabel)("newCustomFieldValueLabel", ctx_r4.newCustomFieldValueLabel)("newCustomFieldAddLabel", ctx_r4.newCustomFieldAddLabel)("newCustomFieldSaveLabel", ctx_r4.newCustomFieldSaveLabel)("newCustomFieldCancelLabel", ctx_r4.newCustomFieldCancelLabel)("idPrefix", ctx_r4.idPrefix)("model", ctx_r4.model[ctx_r4.schema.id][item_r3.index].mappingAttributes)("schemas", ctx_r4.getSchemaProperties())("editing", ctx_r4.editing);
471
+ } }
472
+ function SchemaArrayComponent_div_0_ng_template_2_schema_form_1_Template(rf, ctx) { if (rf & 1) {
473
+ const _r12 = i0.ɵɵgetCurrentView();
474
+ i0.ɵɵelementStart(0, "schema-form", 4);
475
+ i0.ɵɵlistener("modelChange", function SchemaArrayComponent_div_0_ng_template_2_schema_form_1_Template_schema_form_modelChange_0_listener($event) { i0.ɵɵrestoreView(_r12); const item_r3 = i0.ɵɵnextContext().$implicit; const ctx_r11 = i0.ɵɵnextContext(2); return i0.ɵɵresetView((ctx_r11.model[ctx_r11.schema.id][item_r3.index] = $event)); });
476
+ i0.ɵɵelementEnd();
477
+ } if (rf & 2) {
478
+ const item_r3 = i0.ɵɵnextContext().$implicit;
479
+ const ctx_r5 = i0.ɵɵnextContext(2);
480
+ i0.ɵɵproperty("selectPlaceHolderLabel", ctx_r5.selectPlaceHolderLabel)("selectSearchPlaceHolderLabel", ctx_r5.selectSearchPlaceHolderLabel)("selectClearLabel", ctx_r5.selectClearLabel)("selectNotFoundLabel", ctx_r5.selectNotFoundLabel)("requiredLabel", ctx_r5.requiredLabel)("addItemLabel", ctx_r5.addItemLabel)("addLoopLabel", ctx_r5.addLoopLabel)("additionalAttributesLabel", ctx_r5.additionalAttributesLabel)("customAttributeRemoveLabel", ctx_r5.customAttributeRemoveLabel)("newCustomFieldNameLabel", ctx_r5.newCustomFieldNameLabel)("newCustomFieldValueLabel", ctx_r5.newCustomFieldValueLabel)("newCustomFieldAddLabel", ctx_r5.newCustomFieldAddLabel)("newCustomFieldSaveLabel", ctx_r5.newCustomFieldSaveLabel)("newCustomFieldCancelLabel", ctx_r5.newCustomFieldCancelLabel)("idPrefix", ctx_r5.idPrefix)("model", ctx_r5.model[ctx_r5.schema.id][item_r3.index])("schemas", ctx_r5.getSchemaProperties())("editing", ctx_r5.editing);
481
+ } }
482
+ function SchemaArrayComponent_div_0_ng_template_2_div_2_Template(rf, ctx) { if (rf & 1) {
483
+ const _r16 = i0.ɵɵgetCurrentView();
484
+ i0.ɵɵelementStart(0, "div", 5)(1, "div", 6)(2, "label", 7);
485
+ i0.ɵɵtext(3);
486
+ i0.ɵɵelementEnd();
487
+ i0.ɵɵelementStart(4, "schema-custom-attributes", 8);
488
+ i0.ɵɵlistener("modelChange", function SchemaArrayComponent_div_0_ng_template_2_div_2_Template_schema_custom_attributes_modelChange_4_listener($event) { i0.ɵɵrestoreView(_r16); const item_r3 = i0.ɵɵnextContext().$implicit; const ctx_r15 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r15.model[ctx_r15.schema.id][item_r3.index].customAttributes = $event); });
489
+ i0.ɵɵelementEnd()()();
490
+ } if (rf & 2) {
491
+ const item_r3 = i0.ɵɵnextContext().$implicit;
492
+ const ctx_r6 = i0.ɵɵnextContext(2);
493
+ i0.ɵɵadvance(3);
494
+ i0.ɵɵtextInterpolate(ctx_r6.additionalAttributesLabel);
495
+ i0.ɵɵadvance(1);
496
+ i0.ɵɵproperty("customAttributeRemoveLabel", ctx_r6.customAttributeRemoveLabel)("newCustomFieldNameLabel", ctx_r6.newCustomFieldNameLabel)("newCustomFieldValueLabel", ctx_r6.newCustomFieldValueLabel)("newCustomFieldAddLabel", ctx_r6.newCustomFieldAddLabel)("newCustomFieldSaveLabel", ctx_r6.newCustomFieldSaveLabel)("newCustomFieldCancelLabel", ctx_r6.newCustomFieldCancelLabel)("model", ctx_r6.model[ctx_r6.schema.id][item_r3.index].customAttributes)("onDropFunction", ctx_r6.onDrop);
497
+ } }
498
+ function SchemaArrayComponent_div_0_ng_template_2_Template(rf, ctx) { if (rf & 1) {
499
+ i0.ɵɵtemplate(0, SchemaArrayComponent_div_0_ng_template_2_schema_form_0_Template, 1, 18, "schema-form", 2);
500
+ i0.ɵɵtemplate(1, SchemaArrayComponent_div_0_ng_template_2_schema_form_1_Template, 1, 18, "schema-form", 2);
501
+ i0.ɵɵtemplate(2, SchemaArrayComponent_div_0_ng_template_2_div_2_Template, 5, 9, "div", 3);
502
+ } if (rf & 2) {
503
+ const item_r3 = ctx.$implicit;
504
+ const ctx_r2 = i0.ɵɵnextContext(2);
505
+ i0.ɵɵproperty("ngIf", ctx_r2.model[ctx_r2.schema.id][item_r3.index].loop !== undefined);
506
+ i0.ɵɵadvance(1);
507
+ i0.ɵɵproperty("ngIf", ctx_r2.model[ctx_r2.schema.id][item_r3.index].loop == undefined);
508
+ i0.ɵɵadvance(1);
509
+ i0.ɵɵproperty("ngIf", ctx_r2.model[ctx_r2.schema.id][item_r3.index] && ctx_r2.schema.customProperties);
510
+ } }
511
+ function SchemaArrayComponent_div_0_Template(rf, ctx) { if (rf & 1) {
512
+ const _r20 = i0.ɵɵgetCurrentView();
513
+ i0.ɵɵelementStart(0, "div")(1, "array-session", 1);
514
+ i0.ɵɵlistener("modelChange", function SchemaArrayComponent_div_0_Template_array_session_modelChange_1_listener($event) { i0.ɵɵrestoreView(_r20); const ctx_r19 = i0.ɵɵnextContext(); return i0.ɵɵresetView((ctx_r19.model[ctx_r19.schema.id] = $event)); })("onAdd", function SchemaArrayComponent_div_0_Template_array_session_onAdd_1_listener() { i0.ɵɵrestoreView(_r20); const ctx_r21 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r21.addArrayItem(ctx_r21.schema.id, {})); })("onAddLoop", function SchemaArrayComponent_div_0_Template_array_session_onAddLoop_1_listener() { i0.ɵɵrestoreView(_r20); const ctx_r22 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r22.addArrayLoop(ctx_r22.schema.id, {})); });
515
+ i0.ɵɵtemplate(2, SchemaArrayComponent_div_0_ng_template_2_Template, 3, 3, "ng-template");
516
+ i0.ɵɵelementEnd()();
517
+ } if (rf & 2) {
518
+ const ctx_r0 = i0.ɵɵnextContext();
519
+ i0.ɵɵadvance(1);
520
+ i0.ɵɵproperty("addItemLabel", ctx_r0.addItemLabel)("addLoopLabel", ctx_r0.addLoopLabel)("label", ctx_r0.schema.title)("removeLabel", ctx_r0.schema.title)("model", ctx_r0.model[ctx_r0.schema.id])("showAddLoop", ctx_r0.schema.withoutLoop !== true);
521
+ } }
522
+ const _c0$4 = function () { return { standalone: true }; };
523
+ function SchemaArrayComponent_div_1_ng_template_2_input_2_Template(rf, ctx) { if (rf & 1) {
524
+ const _r30 = i0.ɵɵgetCurrentView();
525
+ i0.ɵɵelementStart(0, "input", 12);
526
+ i0.ɵɵlistener("ngModelChange", function SchemaArrayComponent_div_1_ng_template_2_input_2_Template_input_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r30); const item_r24 = i0.ɵɵnextContext().$implicit; return i0.ɵɵresetView(item_r24.items[item_r24.index].mappingAttributes = $event); })("dndDrop", function SchemaArrayComponent_div_1_ng_template_2_input_2_Template_input_dndDrop_0_listener($event) { i0.ɵɵrestoreView(_r30); const item_r24 = i0.ɵɵnextContext().$implicit; const ctx_r31 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(item_r24.items[item_r24.index].mappingAttributes = ctx_r31.onDrop($event, item_r24.items[item_r24.index].mappingAttributes)); });
527
+ i0.ɵɵelementEnd();
528
+ } if (rf & 2) {
529
+ const item_r24 = i0.ɵɵnextContext().$implicit;
530
+ const ctx_r25 = i0.ɵɵnextContext(2);
531
+ i0.ɵɵproperty("ngModel", item_r24.items[item_r24.index].mappingAttributes)("ngModelOptions", i0.ɵɵpureFunction0(3, _c0$4))("id", ctx_r25.getId(ctx_r25.index) + "-" + item_r24.index);
532
+ } }
533
+ function SchemaArrayComponent_div_1_ng_template_2_ng_template_3_Template(rf, ctx) { if (rf & 1) {
534
+ const _r36 = i0.ɵɵgetCurrentView();
535
+ i0.ɵɵelementStart(0, "input", 12);
536
+ i0.ɵɵlistener("ngModelChange", function SchemaArrayComponent_div_1_ng_template_2_ng_template_3_Template_input_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r36); const item_r24 = i0.ɵɵnextContext().$implicit; return i0.ɵɵresetView((item_r24.items[item_r24.index] = $event)); })("dndDrop", function SchemaArrayComponent_div_1_ng_template_2_ng_template_3_Template_input_dndDrop_0_listener($event) { i0.ɵɵrestoreView(_r36); const item_r24 = i0.ɵɵnextContext().$implicit; const ctx_r37 = i0.ɵɵnextContext(2); return i0.ɵɵresetView((item_r24.items[item_r24.index] = ctx_r37.onDrop($event, item_r24.items[item_r24.index]))); });
537
+ i0.ɵɵelementEnd();
538
+ } if (rf & 2) {
539
+ const item_r24 = i0.ɵɵnextContext().$implicit;
540
+ const ctx_r27 = i0.ɵɵnextContext(2);
541
+ i0.ɵɵproperty("ngModel", item_r24.items[item_r24.index])("ngModelOptions", i0.ɵɵpureFunction0(3, _c0$4))("id", ctx_r27.getId(ctx_r27.index) + "-" + item_r24.index);
542
+ } }
543
+ function SchemaArrayComponent_div_1_ng_template_2_Template(rf, ctx) { if (rf & 1) {
544
+ i0.ɵɵelementStart(0, "label", 9);
545
+ i0.ɵɵtext(1);
546
+ i0.ɵɵelementEnd();
547
+ i0.ɵɵtemplate(2, SchemaArrayComponent_div_1_ng_template_2_input_2_Template, 1, 4, "input", 10);
548
+ i0.ɵɵtemplate(3, SchemaArrayComponent_div_1_ng_template_2_ng_template_3_Template, 1, 4, "ng-template", null, 11, i0.ɵɵtemplateRefExtractor);
549
+ } if (rf & 2) {
550
+ const item_r24 = ctx.$implicit;
551
+ const _r26 = i0.ɵɵreference(4);
552
+ const ctx_r23 = i0.ɵɵnextContext(2);
553
+ i0.ɵɵproperty("htmlFor", ctx_r23.getId(ctx_r23.index) + "-" + item_r24.index);
554
+ i0.ɵɵadvance(1);
555
+ i0.ɵɵtextInterpolate(ctx_r23.schema.title);
556
+ i0.ɵɵadvance(1);
557
+ i0.ɵɵproperty("ngIf", item_r24.items[item_r24.index].mappingAttributes || item_r24.items[item_r24.index].mappingAttributes === "")("ngIfElse", _r26);
558
+ } }
559
+ function SchemaArrayComponent_div_1_Template(rf, ctx) { if (rf & 1) {
560
+ const _r41 = i0.ɵɵgetCurrentView();
561
+ i0.ɵɵelementStart(0, "div")(1, "array-session", 1);
562
+ i0.ɵɵlistener("modelChange", function SchemaArrayComponent_div_1_Template_array_session_modelChange_1_listener($event) { i0.ɵɵrestoreView(_r41); const ctx_r40 = i0.ɵɵnextContext(); return i0.ɵɵresetView((ctx_r40.model[ctx_r40.schema.id] = $event)); })("onAdd", function SchemaArrayComponent_div_1_Template_array_session_onAdd_1_listener() { i0.ɵɵrestoreView(_r41); const ctx_r42 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r42.addArrayItem(ctx_r42.schema.id, "")); })("onAddLoop", function SchemaArrayComponent_div_1_Template_array_session_onAddLoop_1_listener() { i0.ɵɵrestoreView(_r41); const ctx_r43 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r43.addArrayLoop(ctx_r43.schema.id, "")); });
563
+ i0.ɵɵtemplate(2, SchemaArrayComponent_div_1_ng_template_2_Template, 5, 4, "ng-template");
564
+ i0.ɵɵelementEnd()();
565
+ } if (rf & 2) {
566
+ const ctx_r1 = i0.ɵɵnextContext();
567
+ i0.ɵɵadvance(1);
568
+ i0.ɵɵproperty("addItemLabel", ctx_r1.addItemLabel)("addLoopLabel", ctx_r1.addLoopLabel)("label", ctx_r1.schema.title)("removeLabel", ctx_r1.schema.title)("model", ctx_r1.model[ctx_r1.schema.id])("showAddLoop", ctx_r1.schema.withoutLoop !== true);
569
+ } }
570
+ class SchemaArrayComponent extends BaseSchemaComponent {
571
+ constructor() {
572
+ super(...arguments);
573
+ this.requiredLabel = '(required)';
574
+ this.addItemLabel = 'Add Item';
575
+ this.addLoopLabel = 'Add Loop';
576
+ this.additionalAttributesLabel = 'Additional Fields';
577
+ this.customAttributeRemoveLabel = 'Remove';
578
+ this.newCustomFieldNameLabel = 'Name';
579
+ this.newCustomFieldValueLabel = 'Value';
580
+ this.newCustomFieldAddLabel = 'Add';
581
+ this.newCustomFieldSaveLabel = 'Save';
582
+ this.newCustomFieldCancelLabel = 'Cancel';
583
+ this.selectPlaceHolderLabel = 'Select Item';
584
+ this.selectSearchPlaceHolderLabel = 'Search';
585
+ this.selectClearLabel = 'Clear';
586
+ this.selectNotFoundLabel = 'No Items Found';
587
+ this.editing = false;
588
+ }
589
+ ngAfterContentInit() {
590
+ if (this.schema?.type === 'array' && this.model && !this.model[this.schema.id]) {
591
+ this.model[this.schema.id] = [];
592
+ }
593
+ this.loaded = true;
594
+ }
595
+ onDrop($event, modelElement) {
596
+ return onDropStruct($event, modelElement);
597
+ }
598
+ getId(index) {
599
+ return `${this.idPrefix}-struct-${index}`;
600
+ }
601
+ addArrayItem(id, param) {
602
+ this.model[id] = this.model[id] || [];
603
+ if (this.schema.properties) {
604
+ param = {};
605
+ Object.keys(this.schema.properties).forEach(key => {
606
+ const schemaProperty = this.schema.properties[key];
607
+ if (schemaProperty.type === 'object') {
608
+ param[schemaProperty.id] = {};
609
+ }
610
+ else if (schemaProperty.type === 'array') {
611
+ param[schemaProperty.id] = [];
612
+ }
613
+ });
614
+ }
615
+ this.model[id].push(param);
616
+ }
617
+ addArrayLoop(id, mappingAttributes) {
618
+ this.model[id] = this.model[id] || [];
619
+ this.model[id].push({ loop: '', alias: '', mappingAttributes });
620
+ }
621
+ }
622
+ SchemaArrayComponent.ɵfac = /*@__PURE__*/ function () { let ɵSchemaArrayComponent_BaseFactory; return function SchemaArrayComponent_Factory(t) { return (ɵSchemaArrayComponent_BaseFactory || (ɵSchemaArrayComponent_BaseFactory = i0.ɵɵgetInheritedFactory(SchemaArrayComponent)))(t || SchemaArrayComponent); }; }();
623
+ SchemaArrayComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SchemaArrayComponent, selectors: [["schema-array"]], inputs: { requiredLabel: "requiredLabel", addItemLabel: "addItemLabel", addLoopLabel: "addLoopLabel", additionalAttributesLabel: "additionalAttributesLabel", customAttributeRemoveLabel: "customAttributeRemoveLabel", newCustomFieldNameLabel: "newCustomFieldNameLabel", newCustomFieldValueLabel: "newCustomFieldValueLabel", newCustomFieldAddLabel: "newCustomFieldAddLabel", newCustomFieldSaveLabel: "newCustomFieldSaveLabel", newCustomFieldCancelLabel: "newCustomFieldCancelLabel", selectPlaceHolderLabel: "selectPlaceHolderLabel", selectSearchPlaceHolderLabel: "selectSearchPlaceHolderLabel", selectClearLabel: "selectClearLabel", selectNotFoundLabel: "selectNotFoundLabel", idPrefix: "idPrefix", schema: "schema", editing: "editing", index: "index" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 2, vars: 2, consts: [[4, "ngIf"], [3, "addItemLabel", "addLoopLabel", "label", "removeLabel", "model", "showAddLoop", "modelChange", "onAdd", "onAddLoop"], [3, "selectPlaceHolderLabel", "selectSearchPlaceHolderLabel", "selectClearLabel", "selectNotFoundLabel", "requiredLabel", "addItemLabel", "addLoopLabel", "additionalAttributesLabel", "customAttributeRemoveLabel", "newCustomFieldNameLabel", "newCustomFieldValueLabel", "newCustomFieldAddLabel", "newCustomFieldSaveLabel", "newCustomFieldCancelLabel", "idPrefix", "model", "schemas", "editing", "modelChange", 4, "ngIf"], ["class", "row struct-custom-properties", 4, "ngIf"], [3, "selectPlaceHolderLabel", "selectSearchPlaceHolderLabel", "selectClearLabel", "selectNotFoundLabel", "requiredLabel", "addItemLabel", "addLoopLabel", "additionalAttributesLabel", "customAttributeRemoveLabel", "newCustomFieldNameLabel", "newCustomFieldValueLabel", "newCustomFieldAddLabel", "newCustomFieldSaveLabel", "newCustomFieldCancelLabel", "idPrefix", "model", "schemas", "editing", "modelChange"], [1, "row", "struct-custom-properties"], [1, "col-md-12"], [1, "info-label", "bold"], [3, "customAttributeRemoveLabel", "newCustomFieldNameLabel", "newCustomFieldValueLabel", "newCustomFieldAddLabel", "newCustomFieldSaveLabel", "newCustomFieldCancelLabel", "model", "onDropFunction", "modelChange"], [1, "info-label", 3, "htmlFor"], ["class", "form-control", "type", "text", "dndDropzone", "", 3, "ngModel", "ngModelOptions", "id", "ngModelChange", "dndDrop", 4, "ngIf", "ngIfElse"], ["elseBlock", ""], ["type", "text", "dndDropzone", "", 1, "form-control", 3, "ngModel", "ngModelOptions", "id", "ngModelChange", "dndDrop"]], template: function SchemaArrayComponent_Template(rf, ctx) { if (rf & 1) {
624
+ i0.ɵɵtemplate(0, SchemaArrayComponent_div_0_Template, 3, 6, "div", 0);
625
+ i0.ɵɵtemplate(1, SchemaArrayComponent_div_1_Template, 3, 6, "div", 0);
626
+ } if (rf & 2) {
627
+ i0.ɵɵproperty("ngIf", ctx.loaded && ctx.canRender(ctx.schema) && ctx.schema.type === "array" && ctx.schema.properties);
628
+ i0.ɵɵadvance(1);
629
+ i0.ɵɵproperty("ngIf", ctx.schema && ctx.canRender(ctx.schema) && ctx.schema.type === "array" && !ctx.schema.properties);
630
+ } }, dependencies: [i1.NgIf, i2.DndDropzoneDirective, i3.DefaultValueAccessor, i3.NgControlStatus, i3.NgModel, ArraySessionComponent, SchemaFormComponent, SchemaCustomAttributesComponent] });
631
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SchemaArrayComponent, [{
632
+ type: Component,
633
+ args: [{ selector: 'schema-array', template: "<div *ngIf=\"loaded && canRender(schema) && schema.type === 'array' && schema.properties\">\r\n <array-session\r\n [addItemLabel]=\"addItemLabel\"\r\n [addLoopLabel]=\"addLoopLabel\"\r\n [label]=\"schema.title\"\r\n [removeLabel]=\"schema.title\"\r\n [(model)]=\"this.model[schema.id]\"\r\n [showAddLoop]=\"schema.withoutLoop !== true\"\r\n (onAdd)=\"addArrayItem(schema.id, {})\"\r\n (onAddLoop)=\"addArrayLoop(schema.id, {})\">\r\n <ng-template let-item>\r\n <schema-form\r\n *ngIf=\"this.model[schema.id][item.index].loop !== undefined\"\r\n [selectPlaceHolderLabel]=\"selectPlaceHolderLabel\"\r\n [selectSearchPlaceHolderLabel]=\"selectSearchPlaceHolderLabel\"\r\n [selectClearLabel]=\"selectClearLabel\"\r\n [selectNotFoundLabel]=\"selectNotFoundLabel\"\r\n [requiredLabel]=\"requiredLabel\"\r\n [addItemLabel]=\"addItemLabel\"\r\n [addLoopLabel]=\"addLoopLabel\"\r\n [additionalAttributesLabel]=\"additionalAttributesLabel\"\r\n [customAttributeRemoveLabel]=\"customAttributeRemoveLabel\"\r\n [newCustomFieldNameLabel]=\"newCustomFieldNameLabel\"\r\n [newCustomFieldValueLabel]=\"newCustomFieldValueLabel\"\r\n [newCustomFieldAddLabel]=\"newCustomFieldAddLabel\"\r\n [newCustomFieldSaveLabel]=\"newCustomFieldSaveLabel\"\r\n [newCustomFieldCancelLabel]=\"newCustomFieldCancelLabel\"\r\n [idPrefix]=\"idPrefix\"\r\n [(model)]=\"this.model[schema.id][item.index].mappingAttributes\"\r\n [schemas]=\"getSchemaProperties()\"\r\n [editing]=\"this.editing\">\r\n </schema-form>\r\n <schema-form\r\n *ngIf=\"this.model[schema.id][item.index].loop == undefined\"\r\n [selectPlaceHolderLabel]=\"selectPlaceHolderLabel\"\r\n [selectSearchPlaceHolderLabel]=\"selectSearchPlaceHolderLabel\"\r\n [selectClearLabel]=\"selectClearLabel\"\r\n [selectNotFoundLabel]=\"selectNotFoundLabel\"\r\n [requiredLabel]=\"requiredLabel\"\r\n [addItemLabel]=\"addItemLabel\"\r\n [addLoopLabel]=\"addLoopLabel\"\r\n [additionalAttributesLabel]=\"additionalAttributesLabel\"\r\n [customAttributeRemoveLabel]=\"customAttributeRemoveLabel\"\r\n [newCustomFieldNameLabel]=\"newCustomFieldNameLabel\"\r\n [newCustomFieldValueLabel]=\"newCustomFieldValueLabel\"\r\n [newCustomFieldAddLabel]=\"newCustomFieldAddLabel\"\r\n [newCustomFieldSaveLabel]=\"newCustomFieldSaveLabel\"\r\n [newCustomFieldCancelLabel]=\"newCustomFieldCancelLabel\"\r\n [idPrefix]=\"idPrefix\"\r\n [(model)]=\"this.model[schema.id][item.index]\"\r\n [schemas]=\"getSchemaProperties()\"\r\n [editing]=\"this.editing\">\r\n </schema-form>\r\n\r\n <div class=\"row struct-custom-properties\" *ngIf=\"this.model[schema.id][item.index] && schema.customProperties\">\r\n <div class=\"col-md-12\">\r\n <label class=\"info-label bold\">{{ this.additionalAttributesLabel }}</label>\r\n <schema-custom-attributes\r\n [customAttributeRemoveLabel]=\"customAttributeRemoveLabel\"\r\n [newCustomFieldNameLabel]=\"newCustomFieldNameLabel\"\r\n [newCustomFieldValueLabel]=\"newCustomFieldValueLabel\"\r\n [newCustomFieldAddLabel]=\"newCustomFieldAddLabel\"\r\n [newCustomFieldSaveLabel]=\"newCustomFieldSaveLabel\"\r\n [newCustomFieldCancelLabel]=\"newCustomFieldCancelLabel\"\r\n [(model)]=\"this.model[schema.id][item.index].customAttributes\"\r\n [onDropFunction]=\"onDrop\">\r\n </schema-custom-attributes>\r\n </div>\r\n </div>\r\n\r\n </ng-template>\r\n </array-session>\r\n</div>\r\n<div *ngIf=\"schema && canRender(schema) && schema.type === 'array' && !schema.properties\">\r\n <array-session\r\n [addItemLabel]=\"addItemLabel\"\r\n [addLoopLabel]=\"addLoopLabel\"\r\n [label]=\"schema.title\"\r\n [removeLabel]=\"schema.title\"\r\n [(model)]=\"this.model[schema.id]\"\r\n [showAddLoop]=\"schema.withoutLoop !== true\"\r\n (onAdd)=\"addArrayItem(schema.id, '')\"\r\n (onAddLoop)=\"addArrayLoop(schema.id, '')\"\r\n >\r\n <ng-template let-item>\r\n <label class=\"info-label\" [htmlFor]=\"getId(index)+'-'+item.index\">{{ schema.title }}</label>\r\n <input class=\"form-control\" type=\"text\" [(ngModel)]=\"item.items[item.index].mappingAttributes\"\r\n [ngModelOptions]=\"{standalone: true}\" dndDropzone\r\n (dndDrop)=\"item.items[item.index].mappingAttributes = this.onDrop($event, item.items[item.index].mappingAttributes)\"\r\n *ngIf=\"item.items[item.index].mappingAttributes || item.items[item.index].mappingAttributes === ''; else elseBlock\"\r\n [id]=\"getId(index)+'-'+item.index\"/>\r\n <ng-template #elseBlock>\r\n <input class=\"form-control\" type=\"text\" [(ngModel)]=\"item.items[item.index]\"\r\n [ngModelOptions]=\"{standalone: true}\" dndDropzone\r\n (dndDrop)=\"item.items[item.index] = this.onDrop($event, item.items[item.index])\"\r\n [id]=\"getId(index)+'-'+item.index\"/>\r\n </ng-template>\r\n </ng-template>\r\n </array-session>\r\n</div>\r\n" }]
634
+ }], null, { requiredLabel: [{
635
+ type: Input
636
+ }], addItemLabel: [{
637
+ type: Input
638
+ }], addLoopLabel: [{
639
+ type: Input
640
+ }], additionalAttributesLabel: [{
641
+ type: Input
642
+ }], customAttributeRemoveLabel: [{
643
+ type: Input
644
+ }], newCustomFieldNameLabel: [{
645
+ type: Input
646
+ }], newCustomFieldValueLabel: [{
647
+ type: Input
648
+ }], newCustomFieldAddLabel: [{
649
+ type: Input
650
+ }], newCustomFieldSaveLabel: [{
651
+ type: Input
652
+ }], newCustomFieldCancelLabel: [{
653
+ type: Input
654
+ }], selectPlaceHolderLabel: [{
655
+ type: Input
656
+ }], selectSearchPlaceHolderLabel: [{
657
+ type: Input
658
+ }], selectClearLabel: [{
659
+ type: Input
660
+ }], selectNotFoundLabel: [{
661
+ type: Input
662
+ }], idPrefix: [{
663
+ type: Input
664
+ }], schema: [{
665
+ type: Input
666
+ }], editing: [{
667
+ type: Input
668
+ }], index: [{
669
+ type: Input
670
+ }] }); })();
671
+
672
+ const _c0$3 = function (a0) { return { "has-error": a0 }; };
673
+ function FieldRenderComponent_small_3_Template(rf, ctx) { if (rf & 1) {
674
+ i0.ɵɵelementStart(0, "small", 0);
675
+ i0.ɵɵtext(1);
676
+ i0.ɵɵelementEnd();
677
+ } if (rf & 2) {
678
+ const ctx_r0 = i0.ɵɵnextContext();
679
+ i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(2, _c0$3, ctx_r0.state && !ctx_r0.state.valid && ctx_r0.state.errors));
680
+ i0.ɵɵadvance(1);
681
+ i0.ɵɵtextInterpolate(ctx_r0.requiredLabel);
682
+ } }
683
+ function FieldRenderComponent_span_4_Template(rf, ctx) { if (rf & 1) {
684
+ i0.ɵɵelementStart(0, "span", 4);
685
+ i0.ɵɵelement(1, "i", 5);
686
+ i0.ɵɵelementEnd();
687
+ } if (rf & 2) {
688
+ const ctx_r1 = i0.ɵɵnextContext();
689
+ i0.ɵɵpropertyInterpolate("matTooltip", ctx_r1.tooltip);
690
+ } }
691
+ const _c1$1 = ["*"];
692
+ class FieldRenderComponent {
693
+ constructor() {
694
+ this.requiredLabel = '(required)';
695
+ this.label = '';
696
+ this.required = true;
697
+ }
698
+ }
699
+ FieldRenderComponent.ɵfac = function FieldRenderComponent_Factory(t) { return new (t || FieldRenderComponent)(); };
700
+ FieldRenderComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: FieldRenderComponent, selectors: [["field-render"]], inputs: { requiredLabel: "requiredLabel", label: "label", inputId: "inputId", tooltip: "tooltip", required: "required", state: "state" }, ngContentSelectors: _c1$1, decls: 6, vars: 7, consts: [[3, "ngClass"], [1, "info-label", "bold", 3, "htmlFor"], [3, "ngClass", 4, "ngIf"], ["class", "info-icon", 3, "matTooltip", 4, "ngIf"], [1, "info-icon", 3, "matTooltip"], [1, "far", "fa-question-circle"]], template: function FieldRenderComponent_Template(rf, ctx) { if (rf & 1) {
701
+ i0.ɵɵprojectionDef();
702
+ i0.ɵɵelementStart(0, "div", 0)(1, "label", 1);
703
+ i0.ɵɵtext(2);
704
+ i0.ɵɵtemplate(3, FieldRenderComponent_small_3_Template, 2, 4, "small", 2);
705
+ i0.ɵɵtemplate(4, FieldRenderComponent_span_4_Template, 2, 1, "span", 3);
706
+ i0.ɵɵelementEnd();
707
+ i0.ɵɵprojection(5);
708
+ i0.ɵɵelementEnd();
709
+ } if (rf & 2) {
710
+ i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(5, _c0$3, ctx.state && !ctx.state.valid && (!ctx.state.pristine || ctx.state.touched) && ctx.state.errors));
711
+ i0.ɵɵadvance(1);
712
+ i0.ɵɵproperty("htmlFor", ctx.inputId);
713
+ i0.ɵɵadvance(1);
714
+ i0.ɵɵtextInterpolate1(" ", ctx.label, " ");
715
+ i0.ɵɵadvance(1);
716
+ i0.ɵɵproperty("ngIf", ctx.required);
717
+ i0.ɵɵadvance(1);
718
+ i0.ɵɵproperty("ngIf", ctx.tooltip);
719
+ } }, dependencies: [i1.NgClass, i1.NgIf, i2$1.MatTooltip], styles: [".info-icon[_ngcontent-%COMP%]{color:#222d57;font-size:13px;float:right;margin-left:4px}"] });
720
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(FieldRenderComponent, [{
721
+ type: Component,
722
+ args: [{ selector: 'field-render', template: "<div [ngClass]=\"{'has-error':state && !state.valid && (!state.pristine || state.touched) && state.errors}\">\r\n <label class=\"info-label bold\" [htmlFor]=\"inputId\">\r\n {{ label }}\r\n <small [ngClass]=\"{'has-error':state && !state.valid && state.errors}\" *ngIf=\"required\">{{this.requiredLabel}}</small>\r\n <span class=\"info-icon\" matTooltip=\"{{ tooltip }}\" *ngIf=\"tooltip\">\r\n <i class=\"far fa-question-circle\"></i>\r\n </span>\r\n </label>\r\n\r\n <!-- Input, textarea or select -->\r\n <ng-content></ng-content>\r\n</div>\r\n", styles: [".info-icon{color:#222d57;font-size:13px;float:right;margin-left:4px}\n"] }]
723
+ }], null, { requiredLabel: [{
724
+ type: Input
725
+ }], label: [{
726
+ type: Input
727
+ }], inputId: [{
728
+ type: Input
729
+ }], tooltip: [{
730
+ type: Input
731
+ }], required: [{
732
+ type: Input
733
+ }], state: [{
734
+ type: Input
735
+ }] }); })();
736
+
737
+ const _c0$2 = function () { return { standalone: true }; };
738
+ class BooleanInputComponent extends BaseSchemaComponent {
739
+ ngAfterContentInit() {
740
+ this.value = this.model;
741
+ }
742
+ onDropCallBack($event, value) {
743
+ this.value = value = super.onDrop($event, value);
744
+ this.changeValue(value);
745
+ }
746
+ changeValue($event) {
747
+ if ($event && ($event === 'true' || $event === 'false')) {
748
+ this.model = $event === 'true';
749
+ this.value = this.model;
750
+ this.modelChange.emit(this.model);
751
+ }
752
+ else {
753
+ this.model = $event;
754
+ this.value = this.model;
755
+ this.modelChange.emit(this.model);
756
+ }
757
+ }
758
+ }
759
+ BooleanInputComponent.ɵfac = /*@__PURE__*/ function () { let ɵBooleanInputComponent_BaseFactory; return function BooleanInputComponent_Factory(t) { return (ɵBooleanInputComponent_BaseFactory || (ɵBooleanInputComponent_BaseFactory = i0.ɵɵgetInheritedFactory(BooleanInputComponent)))(t || BooleanInputComponent); }; }();
760
+ BooleanInputComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: BooleanInputComponent, selectors: [["boolean-input"]], inputs: { placeholder: "placeholder", inputId: "inputId", maxLength: "maxLength" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 1, vars: 6, consts: [["dndDropzone", "", 1, "form-control", 3, "id", "placeholder", "ngModel", "ngModelOptions", "maxlength", "ngModelChange", "dndDrop"]], template: function BooleanInputComponent_Template(rf, ctx) { if (rf & 1) {
761
+ i0.ɵɵelementStart(0, "input", 0);
762
+ i0.ɵɵlistener("ngModelChange", function BooleanInputComponent_Template_input_ngModelChange_0_listener($event) { return ctx.value = $event; })("ngModelChange", function BooleanInputComponent_Template_input_ngModelChange_0_listener($event) { return ctx.changeValue($event); })("dndDrop", function BooleanInputComponent_Template_input_dndDrop_0_listener($event) { return ctx.onDropCallBack($event, ctx.value); });
763
+ i0.ɵɵelementEnd();
764
+ } if (rf & 2) {
765
+ i0.ɵɵproperty("id", ctx.inputId)("placeholder", ctx.placeholder)("ngModel", ctx.value)("ngModelOptions", i0.ɵɵpureFunction0(5, _c0$2))("maxlength", ctx.maxLength);
766
+ } }, dependencies: [i2.DndDropzoneDirective, i3.DefaultValueAccessor, i3.NgControlStatus, i3.MaxLengthValidator, i3.NgModel], encapsulation: 2 });
767
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(BooleanInputComponent, [{
768
+ type: Component,
769
+ args: [{ selector: 'boolean-input', template: "<input class=\"form-control\"\r\n [id]=\"inputId\"\r\n [placeholder]=\"placeholder\"\r\n [(ngModel)]=\"value\"\r\n [ngModelOptions]=\"{standalone: true}\"\r\n (ngModelChange)=\"changeValue($event)\"\r\n dndDropzone (dndDrop)=\"onDropCallBack($event, value)\"\r\n [maxlength]=\"maxLength\">\r\n" }]
770
+ }], null, { placeholder: [{
771
+ type: Input
772
+ }], inputId: [{
773
+ type: Input
774
+ }], maxLength: [{
775
+ type: Input
776
+ }] }); })();
777
+
778
+ const _c0$1 = function () { return { standalone: true }; };
779
+ class NumberInputComponent extends BaseSchemaComponent {
780
+ ngAfterContentInit() {
781
+ this.value = this.model;
782
+ }
783
+ onDropCallBack($event, value) {
784
+ this.value = value = super.onDrop($event, value);
785
+ this.changeValue(value);
786
+ }
787
+ changeValue($event) {
788
+ if ($event && !isNaN($event)) {
789
+ this.model = Number($event);
790
+ this.modelChange.emit(this.model);
791
+ }
792
+ else {
793
+ this.model = $event;
794
+ this.modelChange.emit(this.model);
795
+ }
796
+ }
797
+ }
798
+ NumberInputComponent.ɵfac = /*@__PURE__*/ function () { let ɵNumberInputComponent_BaseFactory; return function NumberInputComponent_Factory(t) { return (ɵNumberInputComponent_BaseFactory || (ɵNumberInputComponent_BaseFactory = i0.ɵɵgetInheritedFactory(NumberInputComponent)))(t || NumberInputComponent); }; }();
799
+ NumberInputComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: NumberInputComponent, selectors: [["number-input"]], inputs: { placeholder: "placeholder", inputId: "inputId", maxLength: "maxLength" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 1, vars: 6, consts: [["dndDropzone", "", 1, "form-control", "number-input", 3, "id", "placeholder", "ngModel", "ngModelOptions", "maxlength", "ngModelChange", "dndDrop"]], template: function NumberInputComponent_Template(rf, ctx) { if (rf & 1) {
800
+ i0.ɵɵelementStart(0, "input", 0);
801
+ i0.ɵɵlistener("ngModelChange", function NumberInputComponent_Template_input_ngModelChange_0_listener($event) { return ctx.value = $event; })("ngModelChange", function NumberInputComponent_Template_input_ngModelChange_0_listener($event) { return ctx.changeValue($event); })("dndDrop", function NumberInputComponent_Template_input_dndDrop_0_listener($event) { return ctx.onDropCallBack($event, ctx.value); });
802
+ i0.ɵɵelementEnd();
803
+ } if (rf & 2) {
804
+ i0.ɵɵproperty("id", ctx.inputId)("placeholder", ctx.placeholder)("ngModel", ctx.value)("ngModelOptions", i0.ɵɵpureFunction0(5, _c0$1))("maxlength", ctx.maxLength);
805
+ } }, dependencies: [i2.DndDropzoneDirective, i3.DefaultValueAccessor, i3.NgControlStatus, i3.MaxLengthValidator, i3.NgModel], encapsulation: 2 });
806
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(NumberInputComponent, [{
807
+ type: Component,
808
+ args: [{ selector: 'number-input', template: "<input class=\"form-control number-input\"\r\n [id]=\"inputId\"\r\n [placeholder]=\"placeholder\"\r\n [(ngModel)]=\"value\"\r\n [ngModelOptions]=\"{standalone: true}\"\r\n (ngModelChange)=\"changeValue($event)\"\r\n dndDropzone (dndDrop)=\"onDropCallBack($event, value)\"\r\n [maxlength]=\"maxLength\">\r\n" }]
809
+ }], null, { placeholder: [{
810
+ type: Input
811
+ }], inputId: [{
812
+ type: Input
813
+ }], maxLength: [{
814
+ type: Input
815
+ }] }); })();
816
+
817
+ function InputRenderComponent_div_1_icon_1_Template(rf, ctx) { if (rf & 1) {
818
+ const _r8 = i0.ɵɵgetCurrentView();
819
+ i0.ɵɵelementStart(0, "icon", 8);
820
+ i0.ɵɵlistener("onClick", function InputRenderComponent_div_1_icon_1_Template_icon_onClick_0_listener() { i0.ɵɵrestoreView(_r8); const ctx_r7 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r7.editPassword()); });
821
+ i0.ɵɵelementEnd();
822
+ } if (rf & 2) {
823
+ i0.ɵɵproperty("name", "fas fa-pencil-alt");
824
+ } }
825
+ function InputRenderComponent_div_1_icon_2_Template(rf, ctx) { if (rf & 1) {
826
+ const _r10 = i0.ɵɵgetCurrentView();
827
+ i0.ɵɵelementStart(0, "icon", 9);
828
+ i0.ɵɵlistener("mousedown", function InputRenderComponent_div_1_icon_2_Template_icon_mousedown_0_listener($event) { i0.ɵɵrestoreView(_r10); const ctx_r9 = i0.ɵɵnextContext(2); ctx_r9.cancelEditPassword(); return i0.ɵɵresetView($event.stopPropagation()); });
829
+ i0.ɵɵelementEnd();
830
+ } if (rf & 2) {
831
+ i0.ɵɵproperty("name", "fas fa-ban");
832
+ } }
833
+ function InputRenderComponent_div_1_Template(rf, ctx) { if (rf & 1) {
834
+ i0.ɵɵelementStart(0, "div", 5);
835
+ i0.ɵɵtemplate(1, InputRenderComponent_div_1_icon_1_Template, 1, 1, "icon", 6);
836
+ i0.ɵɵtemplate(2, InputRenderComponent_div_1_icon_2_Template, 1, 1, "icon", 7);
837
+ i0.ɵɵelementEnd();
838
+ } if (rf & 2) {
839
+ const ctx_r0 = i0.ɵɵnextContext();
840
+ i0.ɵɵadvance(1);
841
+ i0.ɵɵproperty("ngIf", ctx_r0.schema.readOnlyPassword);
842
+ i0.ɵɵadvance(1);
843
+ i0.ɵɵproperty("ngIf", !ctx_r0.schema.readOnlyPassword);
844
+ } }
845
+ const _c0 = function () { return { standalone: true }; };
846
+ function InputRenderComponent_input_2_Template(rf, ctx) { if (rf & 1) {
847
+ const _r12 = i0.ɵɵgetCurrentView();
848
+ i0.ɵɵelementStart(0, "input", 10);
849
+ i0.ɵɵlistener("blur", function InputRenderComponent_input_2_Template_input_blur_0_listener() { i0.ɵɵrestoreView(_r12); const ctx_r11 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r11.onInputBlur()); })("ngModelChange", function InputRenderComponent_input_2_Template_input_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r12); const ctx_r13 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r13.value = $event); })("ngModelChange", function InputRenderComponent_input_2_Template_input_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r12); const ctx_r14 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r14.onChange($event)); })("dndDrop", function InputRenderComponent_input_2_Template_input_dndDrop_0_listener($event) { i0.ɵɵrestoreView(_r12); const ctx_r15 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r15.onDropCallBack($event, ctx_r15.value)); });
850
+ i0.ɵɵelementEnd();
851
+ } if (rf & 2) {
852
+ const ctx_r1 = i0.ɵɵnextContext();
853
+ i0.ɵɵpropertyInterpolate("placeholder", ctx_r1.schema.type === "password" && ctx_r1.schema.readOnlyPassword ? "*****" : ctx_r1.schema.description);
854
+ i0.ɵɵproperty("disabled", ctx_r1.schema.readOnlyPassword)("type", ctx_r1.schema.type === "password" ? "password" : "text")("ngModel", ctx_r1.value)("ngModelOptions", i0.ɵɵpureFunction0(7, _c0))("id", ctx_r1.inputId)("maxlength", ctx_r1.schema.maxLength);
855
+ } }
856
+ function InputRenderComponent_select_box_3_Template(rf, ctx) { if (rf & 1) {
857
+ const _r17 = i0.ɵɵgetCurrentView();
858
+ i0.ɵɵelementStart(0, "select-box", 11);
859
+ i0.ɵɵlistener("ngModelChange", function InputRenderComponent_select_box_3_Template_select_box_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r17); const ctx_r16 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r16.value = $event); })("ngModelChange", function InputRenderComponent_select_box_3_Template_select_box_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r17); const ctx_r18 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r18.onChange($event.key)); });
860
+ i0.ɵɵelementEnd();
861
+ } if (rf & 2) {
862
+ const ctx_r2 = i0.ɵɵnextContext();
863
+ i0.ɵɵproperty("id", ctx_r2.inputId)("ngModel", ctx_r2.value)("ngModelOptions", i0.ɵɵpureFunction0(12, _c0))("placeholder", ctx_r2.schema.description || ctx_r2.selectPlaceHolderLabel)("searchPlaceHolder", ctx_r2.selectSearchPlaceHolderLabel)("clearText", ctx_r2.selectClearLabel)("notFoundText", ctx_r2.selectNotFoundLabel)("bindKey", "key")("bindValue", "value")("enabledSearch", true)("limitItens", 30)("data", ctx_r2.schema.options);
864
+ } }
865
+ function InputRenderComponent_number_input_4_Template(rf, ctx) { if (rf & 1) {
866
+ const _r20 = i0.ɵɵgetCurrentView();
867
+ i0.ɵɵelementStart(0, "number-input", 12);
868
+ i0.ɵɵlistener("modelChange", function InputRenderComponent_number_input_4_Template_number_input_modelChange_0_listener($event) { i0.ɵɵrestoreView(_r20); const ctx_r19 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r19.value = $event); })("modelChange", function InputRenderComponent_number_input_4_Template_number_input_modelChange_0_listener($event) { i0.ɵɵrestoreView(_r20); const ctx_r21 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r21.onChange($event)); });
869
+ i0.ɵɵelementEnd();
870
+ } if (rf & 2) {
871
+ const ctx_r3 = i0.ɵɵnextContext();
872
+ i0.ɵɵproperty("model", ctx_r3.value)("inputId", ctx_r3.inputId)("placeholder", ctx_r3.schema.description)("maxLength", ctx_r3.schema.maxLength);
873
+ } }
874
+ function InputRenderComponent_boolean_input_5_Template(rf, ctx) { if (rf & 1) {
875
+ const _r23 = i0.ɵɵgetCurrentView();
876
+ i0.ɵɵelementStart(0, "boolean-input", 12);
877
+ i0.ɵɵlistener("modelChange", function InputRenderComponent_boolean_input_5_Template_boolean_input_modelChange_0_listener($event) { i0.ɵɵrestoreView(_r23); const ctx_r22 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r22.value = $event); })("modelChange", function InputRenderComponent_boolean_input_5_Template_boolean_input_modelChange_0_listener($event) { i0.ɵɵrestoreView(_r23); const ctx_r24 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r24.onChange($event)); });
878
+ i0.ɵɵelementEnd();
879
+ } if (rf & 2) {
880
+ const ctx_r4 = i0.ɵɵnextContext();
881
+ i0.ɵɵproperty("model", ctx_r4.value)("inputId", ctx_r4.inputId)("placeholder", ctx_r4.schema.description)("maxLength", ctx_r4.schema.maxLength);
882
+ } }
883
+ const _c1 = function (a0) { return { "schema-input-container-password": a0 }; };
884
+ class InputRenderComponent extends BaseSchemaComponent {
885
+ constructor() {
886
+ super(...arguments);
887
+ this.selectPlaceHolderLabel = 'Select Item';
888
+ this.selectSearchPlaceHolderLabel = 'Search';
889
+ this.selectClearLabel = 'Clear';
890
+ this.selectNotFoundLabel = 'No Items Found';
891
+ this.schema = {};
892
+ this.editing = false;
893
+ this.onDropEvent = new EventEmitter();
894
+ }
895
+ ngAfterContentInit() {
896
+ if (this.schema?.type !== 'object' && this.schema?.type !== 'array') {
897
+ if (!this.editing && this.schema.options) {
898
+ const $event = this.schema.options.filter((item) => item.selected === true);
899
+ if ($event[0]) {
900
+ this.onChange($event[0].key);
901
+ this.value = $event[0];
902
+ }
903
+ }
904
+ else if (this.editing && this.schema.options && this.model) {
905
+ const $event = this.schema.options.filter((item) => item.key === this.model);
906
+ if ($event[0]) {
907
+ this.onChange($event[0].key);
908
+ this.value = $event[0];
909
+ }
910
+ }
911
+ else {
912
+ this.value = this.model;
913
+ }
914
+ }
915
+ if (this.editing && this.schema?.type === 'password') {
916
+ this.schema.readOnlyPassword = true;
917
+ }
918
+ }
919
+ onDropCallBack($event, value) {
920
+ this.value = value = super.onDrop($event, value);
921
+ this.onChange(value);
922
+ }
923
+ onChange($event) {
924
+ if (this.schema.type !== 'password' || !this.editing) {
925
+ this.model = $event;
926
+ this.modelChange.emit(this.model);
927
+ }
928
+ }
929
+ onInputBlur() {
930
+ if (this.schema?.type === 'password') {
931
+ this.savePassword();
932
+ }
933
+ }
934
+ savePassword() {
935
+ this.model = this.value || '';
936
+ this.modelChange.emit(this.model);
937
+ this.setReadOnlyPassword(true);
938
+ }
939
+ cancelEditPassword() {
940
+ setTimeout(() => {
941
+ this.value = undefined;
942
+ this.model = undefined;
943
+ this.modelChange.emit(this.model);
944
+ this.setReadOnlyPassword(true);
945
+ }, 100);
946
+ }
947
+ editPassword() {
948
+ this.setReadOnlyPassword(false);
949
+ }
950
+ setReadOnlyPassword(value) {
951
+ this.schema.readOnlyPassword = value;
952
+ }
953
+ }
954
+ InputRenderComponent.ɵfac = /*@__PURE__*/ function () { let ɵInputRenderComponent_BaseFactory; return function InputRenderComponent_Factory(t) { return (ɵInputRenderComponent_BaseFactory || (ɵInputRenderComponent_BaseFactory = i0.ɵɵgetInheritedFactory(InputRenderComponent)))(t || InputRenderComponent); }; }();
955
+ InputRenderComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: InputRenderComponent, selectors: [["input-render"]], inputs: { selectPlaceHolderLabel: "selectPlaceHolderLabel", selectSearchPlaceHolderLabel: "selectSearchPlaceHolderLabel", selectClearLabel: "selectClearLabel", selectNotFoundLabel: "selectNotFoundLabel", schema: "schema", modelPropertiesPath: "modelPropertiesPath", inputId: "inputId", editing: "editing" }, outputs: { onDropEvent: "onDropEvent" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 6, vars: 8, consts: [[1, "schema-input-container", 3, "ngClass"], ["class", "edit-icon", 4, "ngIf"], ["class", "form-control", "dndDropzone", "", 3, "disabled", "type", "placeholder", "ngModel", "ngModelOptions", "id", "maxlength", "blur", "ngModelChange", "dndDrop", 4, "ngIf"], [3, "id", "ngModel", "ngModelOptions", "placeholder", "searchPlaceHolder", "clearText", "notFoundText", "bindKey", "bindValue", "enabledSearch", "limitItens", "data", "ngModelChange", 4, "ngIf"], [3, "model", "inputId", "placeholder", "maxLength", "modelChange", 4, "ngIf"], [1, "edit-icon"], ["size", "15", "type", "primary", 3, "name", "onClick", 4, "ngIf"], ["size", "15", "type", "primary clickable", 3, "name", "mousedown", 4, "ngIf"], ["size", "15", "type", "primary", 3, "name", "onClick"], ["size", "15", "type", "primary clickable", 3, "name", "mousedown"], ["dndDropzone", "", 1, "form-control", 3, "disabled", "type", "placeholder", "ngModel", "ngModelOptions", "id", "maxlength", "blur", "ngModelChange", "dndDrop"], [3, "id", "ngModel", "ngModelOptions", "placeholder", "searchPlaceHolder", "clearText", "notFoundText", "bindKey", "bindValue", "enabledSearch", "limitItens", "data", "ngModelChange"], [3, "model", "inputId", "placeholder", "maxLength", "modelChange"]], template: function InputRenderComponent_Template(rf, ctx) { if (rf & 1) {
956
+ i0.ɵɵelementStart(0, "div", 0);
957
+ i0.ɵɵtemplate(1, InputRenderComponent_div_1_Template, 3, 2, "div", 1);
958
+ i0.ɵɵtemplate(2, InputRenderComponent_input_2_Template, 1, 8, "input", 2);
959
+ i0.ɵɵtemplate(3, InputRenderComponent_select_box_3_Template, 1, 13, "select-box", 3);
960
+ i0.ɵɵtemplate(4, InputRenderComponent_number_input_4_Template, 1, 4, "number-input", 4);
961
+ i0.ɵɵtemplate(5, InputRenderComponent_boolean_input_5_Template, 1, 4, "boolean-input", 4);
962
+ i0.ɵɵelementEnd();
963
+ } if (rf & 2) {
964
+ i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(6, _c1, ctx.schema.type === "password"));
965
+ i0.ɵɵadvance(1);
966
+ i0.ɵɵproperty("ngIf", ctx.schema.type === "password" && ctx.editing);
967
+ i0.ɵɵadvance(1);
968
+ i0.ɵɵproperty("ngIf", (ctx.schema.type === "string" || ctx.schema.type === "password") && !ctx.schema.options);
969
+ i0.ɵɵadvance(1);
970
+ i0.ɵɵproperty("ngIf", ctx.schema.type === "string" && ctx.schema.options);
971
+ i0.ɵɵadvance(1);
972
+ i0.ɵɵproperty("ngIf", ctx.schema.type === "number");
973
+ i0.ɵɵadvance(1);
974
+ i0.ɵɵproperty("ngIf", ctx.schema.type === "boolean");
975
+ } }, dependencies: [i1.NgClass, i1.NgIf, i2.DndDropzoneDirective, i3.DefaultValueAccessor, i3.NgControlStatus, i3.MaxLengthValidator, i3.NgModel, i4.SelectBoxComponent, i5.IconComponent, BooleanInputComponent, NumberInputComponent], styles: [".schema-input-container-password[_ngcontent-%COMP%]{position:relative}.schema-input-container-password[_ngcontent-%COMP%] .edit-icon[_ngcontent-%COMP%]{position:absolute;width:30px;right:-5px;top:10px;z-index:1}.schema-input-container-password[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{display:block;padding-right:38px!important;width:calc(100% - 51px)!important}"] });
976
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(InputRenderComponent, [{
977
+ type: Component,
978
+ args: [{ selector: 'input-render', template: "<div class=\"schema-input-container\" [ngClass]=\"{'schema-input-container-password' : schema.type === 'password' }\" >\r\n <div *ngIf=\"schema.type === 'password' && editing\" class=\"edit-icon\">\r\n <icon *ngIf=\"this.schema.readOnlyPassword\" size=\"15\" type=\"primary\" [name]=\"'fas fa-pencil-alt'\"\r\n (onClick)=\"editPassword()\">\r\n </icon>\r\n <icon *ngIf=\"!this.schema.readOnlyPassword\" size=\"15\" type=\"primary clickable\" [name]=\"'fas fa-ban'\"\r\n (mousedown)=\"cancelEditPassword(); $event.stopPropagation()\">\r\n </icon>\r\n </div>\r\n <input (blur)=\"onInputBlur()\"\r\n [disabled]=\"schema.readOnlyPassword\" class=\"form-control\"\r\n [type]=\"schema.type === 'password' ? 'password' : 'text'\"\r\n placeholder=\"{{schema.type === 'password' && this.schema.readOnlyPassword ? '*****' : schema.description}}\"\r\n *ngIf=\"(schema.type === 'string' || schema.type === 'password') && !schema.options\"\r\n [(ngModel)]=\"value\" [ngModelOptions]=\"{standalone: true}\"\r\n (ngModelChange)=\"onChange($event)\"\r\n dndDropzone (dndDrop)=\"onDropCallBack($event, value)\" [id]=\"inputId\" [maxlength]=\"schema.maxLength\"/>\r\n\r\n <select-box\r\n [id]=\"inputId\"\r\n [(ngModel)]=\"value\"\r\n (ngModelChange)=\"onChange($event.key)\"\r\n [ngModelOptions]=\"{standalone: true}\"\r\n *ngIf=\"schema.type === 'string' && schema.options\"\r\n [placeholder]=\"schema.description || this.selectPlaceHolderLabel\"\r\n [searchPlaceHolder]=\"selectSearchPlaceHolderLabel\"\r\n [clearText]=\"this.selectClearLabel\"\r\n [notFoundText]=\"this.selectNotFoundLabel\"\r\n [bindKey]=\"'key'\"\r\n [bindValue]=\"'value'\"\r\n [enabledSearch]=\"true\"\r\n [limitItens]=\"30\"\r\n [data]=\"schema.options\">\r\n </select-box>\r\n\r\n <number-input [(model)]=\"value\" [inputId]=\"inputId\"\r\n *ngIf=\"schema.type === 'number'\"\r\n [placeholder]=\"schema.description\" [maxLength]=\"schema.maxLength\"\r\n (modelChange)=\"onChange($event)\"></number-input>\r\n\r\n <boolean-input [(model)]=\"value\" [inputId]=\"inputId\"\r\n *ngIf=\"schema.type === 'boolean'\"\r\n [placeholder]=\"schema.description\" [maxLength]=\"schema.maxLength\"\r\n (modelChange)=\"onChange($event)\"></boolean-input>\r\n</div>\r\n", styles: [".schema-input-container-password{position:relative}.schema-input-container-password .edit-icon{position:absolute;width:30px;right:-5px;top:10px;z-index:1}.schema-input-container-password input{display:block;padding-right:38px!important;width:calc(100% - 51px)!important}\n"] }]
979
+ }], null, { selectPlaceHolderLabel: [{
980
+ type: Input
981
+ }], selectSearchPlaceHolderLabel: [{
982
+ type: Input
983
+ }], selectClearLabel: [{
984
+ type: Input
985
+ }], selectNotFoundLabel: [{
986
+ type: Input
987
+ }], schema: [{
988
+ type: Input
989
+ }], modelPropertiesPath: [{
990
+ type: Input
991
+ }], inputId: [{
992
+ type: Input
993
+ }], editing: [{
994
+ type: Input
995
+ }], onDropEvent: [{
996
+ type: Output
997
+ }] }); })();
998
+
999
+ function SchemaInputComponent_div_0_Template(rf, ctx) { if (rf & 1) {
1000
+ const _r3 = i0.ɵɵgetCurrentView();
1001
+ i0.ɵɵelementStart(0, "div", 1)(1, "div", 2)(2, "field-render", 3)(3, "input-render", 4);
1002
+ i0.ɵɵlistener("modelChange", function SchemaInputComponent_div_0_Template_input_render_modelChange_3_listener($event) { i0.ɵɵrestoreView(_r3); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView((ctx_r2.model[ctx_r2.schema.id] = $event)); });
1003
+ i0.ɵɵelementEnd()()()();
1004
+ } if (rf & 2) {
1005
+ const ctx_r0 = i0.ɵɵnextContext();
1006
+ i0.ɵɵadvance(2);
1007
+ i0.ɵɵproperty("requiredLabel", ctx_r0.requiredLabel)("label", ctx_r0.schema.title)("tooltip", ctx_r0.schema.help)("inputId", ctx_r0.getId(ctx_r0.index));
1008
+ i0.ɵɵadvance(1);
1009
+ i0.ɵɵproperty("selectPlaceHolderLabel", ctx_r0.selectPlaceHolderLabel)("selectSearchPlaceHolderLabel", ctx_r0.selectSearchPlaceHolderLabel)("selectClearLabel", ctx_r0.selectClearLabel)("selectNotFoundLabel", ctx_r0.selectNotFoundLabel)("inputId", ctx_r0.getId(ctx_r0.index))("schema", ctx_r0.schema)("model", ctx_r0.model[ctx_r0.schema.id])("modelPropertiesPath", "mappingAttributes." + ctx_r0.schema.id)("editing", ctx_r0.editing);
1010
+ } }
1011
+ function SchemaInputComponent_div_1_span_4_Template(rf, ctx) { if (rf & 1) {
1012
+ i0.ɵɵelementStart(0, "span", 7);
1013
+ i0.ɵɵtext(1, "?");
1014
+ i0.ɵɵelementEnd();
1015
+ } if (rf & 2) {
1016
+ const ctx_r4 = i0.ɵɵnextContext(2);
1017
+ i0.ɵɵpropertyInterpolate("matTooltip", ctx_r4.schema.help);
1018
+ } }
1019
+ function SchemaInputComponent_div_1_Template(rf, ctx) { if (rf & 1) {
1020
+ const _r6 = i0.ɵɵgetCurrentView();
1021
+ i0.ɵɵelementStart(0, "div", 1)(1, "div", 2)(2, "label", 5);
1022
+ i0.ɵɵtext(3);
1023
+ i0.ɵɵtemplate(4, SchemaInputComponent_div_1_span_4_Template, 2, 1, "span", 6);
1024
+ i0.ɵɵelementEnd();
1025
+ i0.ɵɵelementStart(5, "input-render", 4);
1026
+ i0.ɵɵlistener("modelChange", function SchemaInputComponent_div_1_Template_input_render_modelChange_5_listener($event) { i0.ɵɵrestoreView(_r6); const ctx_r5 = i0.ɵɵnextContext(); return i0.ɵɵresetView((ctx_r5.model[ctx_r5.schema.id] = $event)); });
1027
+ i0.ɵɵelementEnd()()();
1028
+ } if (rf & 2) {
1029
+ const ctx_r1 = i0.ɵɵnextContext();
1030
+ i0.ɵɵadvance(2);
1031
+ i0.ɵɵproperty("htmlFor", ctx_r1.getId(ctx_r1.index));
1032
+ i0.ɵɵadvance(1);
1033
+ i0.ɵɵtextInterpolate1(" ", ctx_r1.schema.title, " ");
1034
+ i0.ɵɵadvance(1);
1035
+ i0.ɵɵproperty("ngIf", ctx_r1.schema.help);
1036
+ i0.ɵɵadvance(1);
1037
+ i0.ɵɵproperty("selectPlaceHolderLabel", ctx_r1.selectPlaceHolderLabel)("selectSearchPlaceHolderLabel", ctx_r1.selectSearchPlaceHolderLabel)("selectClearLabel", ctx_r1.selectClearLabel)("selectNotFoundLabel", ctx_r1.selectNotFoundLabel)("inputId", ctx_r1.getId(ctx_r1.index))("schema", ctx_r1.schema)("model", ctx_r1.model[ctx_r1.schema.id])("modelPropertiesPath", "mappingAttributes." + ctx_r1.schema.id)("editing", ctx_r1.editing);
1038
+ } }
1039
+ class SchemaInputComponent extends BaseSchemaComponent {
1040
+ constructor() {
1041
+ super(...arguments);
1042
+ this.requiredLabel = '(required)';
1043
+ this.selectPlaceHolderLabel = 'Select Item';
1044
+ this.selectSearchPlaceHolderLabel = 'Search';
1045
+ this.selectClearLabel = 'Clear';
1046
+ this.selectNotFoundLabel = 'No Items Found';
1047
+ this.editing = false;
1048
+ }
1049
+ ngAfterContentInit() {
1050
+ this.loaded = true;
1051
+ }
1052
+ getId(index) {
1053
+ return `${this.idPrefix}-struct-${index}`;
1054
+ }
1055
+ }
1056
+ SchemaInputComponent.ɵfac = /*@__PURE__*/ function () { let ɵSchemaInputComponent_BaseFactory; return function SchemaInputComponent_Factory(t) { return (ɵSchemaInputComponent_BaseFactory || (ɵSchemaInputComponent_BaseFactory = i0.ɵɵgetInheritedFactory(SchemaInputComponent)))(t || SchemaInputComponent); }; }();
1057
+ SchemaInputComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SchemaInputComponent, selectors: [["schema-input"]], inputs: { requiredLabel: "requiredLabel", selectPlaceHolderLabel: "selectPlaceHolderLabel", selectSearchPlaceHolderLabel: "selectSearchPlaceHolderLabel", selectClearLabel: "selectClearLabel", selectNotFoundLabel: "selectNotFoundLabel", idPrefix: "idPrefix", schema: "schema", editing: "editing", index: "index" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 2, vars: 2, consts: [["class", "row schema-input", 4, "ngIf"], [1, "row", "schema-input"], [1, "col-md-12"], [3, "requiredLabel", "label", "tooltip", "inputId"], [3, "selectPlaceHolderLabel", "selectSearchPlaceHolderLabel", "selectClearLabel", "selectNotFoundLabel", "inputId", "schema", "model", "modelPropertiesPath", "editing", "modelChange"], [1, "info-label", "bold", 3, "htmlFor"], ["class", "config-tooltip", 3, "matTooltip", 4, "ngIf"], [1, "config-tooltip", 3, "matTooltip"]], template: function SchemaInputComponent_Template(rf, ctx) { if (rf & 1) {
1058
+ i0.ɵɵtemplate(0, SchemaInputComponent_div_0_Template, 4, 13, "div", 0);
1059
+ i0.ɵɵtemplate(1, SchemaInputComponent_div_1_Template, 6, 12, "div", 0);
1060
+ } if (rf & 2) {
1061
+ i0.ɵɵproperty("ngIf", ctx.loaded && ctx.canRender(ctx.schema) && ctx.schema.type !== "array" && ctx.schema.type !== "object" && ctx.schema.minLength && ctx.schema.minLength > 0);
1062
+ i0.ɵɵadvance(1);
1063
+ i0.ɵɵproperty("ngIf", ctx.loaded && ctx.canRender(ctx.schema) && ctx.schema.type !== "array" && ctx.schema.type !== "object" && (!ctx.schema.minLength || ctx.schema.minLength === 0));
1064
+ } }, dependencies: [i1.NgIf, i2$1.MatTooltip, FieldRenderComponent, InputRenderComponent] });
1065
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SchemaInputComponent, [{
1066
+ type: Component,
1067
+ args: [{ selector: 'schema-input', template: "<div class=\"row schema-input\"\r\n *ngIf=\"loaded && canRender(schema) && schema.type !== 'array' && schema.type !== 'object' && schema.minLength && schema.minLength > 0\">\r\n <div class=\"col-md-12\">\r\n <field-render [requiredLabel]=\"requiredLabel\" [label]=\"schema.title\" [tooltip]=\"schema.help\" [inputId]=\"getId(index)\">\r\n <input-render\r\n [selectPlaceHolderLabel]=\"selectPlaceHolderLabel\"\r\n [selectSearchPlaceHolderLabel]=\"selectSearchPlaceHolderLabel\"\r\n [selectClearLabel]=\"selectClearLabel\"\r\n [selectNotFoundLabel]=\"selectNotFoundLabel\"\r\n [inputId]=\"getId(index)\"\r\n [schema]=\"schema\"\r\n [(model)]=\"this.model[schema.id]\"\r\n [modelPropertiesPath]=\"'mappingAttributes.' + schema.id\"\r\n [editing]=\"this.editing\"></input-render>\r\n </field-render>\r\n </div>\r\n</div>\r\n<div class=\"row schema-input\"\r\n *ngIf=\"loaded && canRender(schema) && schema.type !== 'array' && schema.type !== 'object' && (!schema.minLength || schema.minLength === 0)\">\r\n <div class=\"col-md-12\">\r\n <label class=\"info-label bold\" [htmlFor]=\"getId(index)\">\r\n {{schema.title}}\r\n <span class=\"config-tooltip\" matTooltip=\"{{ schema.help }}\" *ngIf=\"schema.help\">?</span>\r\n </label>\r\n <input-render\r\n [selectPlaceHolderLabel]=\"selectPlaceHolderLabel\"\r\n [selectSearchPlaceHolderLabel]=\"selectSearchPlaceHolderLabel\"\r\n [selectClearLabel]=\"selectClearLabel\"\r\n [selectNotFoundLabel]=\"selectNotFoundLabel\"\r\n [inputId]=\"getId(index)\"\r\n [schema]=\"schema\"\r\n [(model)]=\"this.model[schema.id]\"\r\n [modelPropertiesPath]=\"'mappingAttributes.' + schema.id\"\r\n [editing]=\"this.editing\"></input-render>\r\n </div>\r\n</div>\r\n" }]
1068
+ }], null, { requiredLabel: [{
1069
+ type: Input
1070
+ }], selectPlaceHolderLabel: [{
1071
+ type: Input
1072
+ }], selectSearchPlaceHolderLabel: [{
1073
+ type: Input
1074
+ }], selectClearLabel: [{
1075
+ type: Input
1076
+ }], selectNotFoundLabel: [{
1077
+ type: Input
1078
+ }], idPrefix: [{
1079
+ type: Input
1080
+ }], schema: [{
1081
+ type: Input
1082
+ }], editing: [{
1083
+ type: Input
1084
+ }], index: [{
1085
+ type: Input
1086
+ }] }); })();
1087
+
1088
+ function SchemaObjectComponent_div_0_div_4_Template(rf, ctx) { if (rf & 1) {
1089
+ const _r3 = i0.ɵɵgetCurrentView();
1090
+ i0.ɵɵelementStart(0, "div", 5)(1, "div", 6)(2, "label", 7);
1091
+ i0.ɵɵtext(3);
1092
+ i0.ɵɵelementEnd();
1093
+ i0.ɵɵelementStart(4, "schema-custom-attributes", 8);
1094
+ i0.ɵɵlistener("modelChange", function SchemaObjectComponent_div_0_div_4_Template_schema_custom_attributes_modelChange_4_listener($event) { i0.ɵɵrestoreView(_r3); const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.model[ctx_r2.schema.id].customAttributes = $event); });
1095
+ i0.ɵɵelementEnd()()();
1096
+ } if (rf & 2) {
1097
+ const ctx_r1 = i0.ɵɵnextContext(2);
1098
+ i0.ɵɵadvance(3);
1099
+ i0.ɵɵtextInterpolate(ctx_r1.additionalAttributesLabel);
1100
+ i0.ɵɵadvance(1);
1101
+ i0.ɵɵproperty("customAttributeRemoveLabel", ctx_r1.customAttributeRemoveLabel)("newCustomFieldNameLabel", ctx_r1.newCustomFieldNameLabel)("newCustomFieldValueLabel", ctx_r1.newCustomFieldValueLabel)("newCustomFieldAddLabel", ctx_r1.newCustomFieldAddLabel)("newCustomFieldSaveLabel", ctx_r1.newCustomFieldSaveLabel)("newCustomFieldCancelLabel", ctx_r1.newCustomFieldCancelLabel)("model", ctx_r1.model[ctx_r1.schema.id].customAttributes)("onDropFunction", ctx_r1.onDrop);
1102
+ } }
1103
+ function SchemaObjectComponent_div_0_Template(rf, ctx) { if (rf & 1) {
1104
+ const _r5 = i0.ɵɵgetCurrentView();
1105
+ i0.ɵɵelementStart(0, "div", 1)(1, "div", 2);
1106
+ i0.ɵɵtext(2);
1107
+ i0.ɵɵelementEnd();
1108
+ i0.ɵɵelementStart(3, "schema-form", 3);
1109
+ i0.ɵɵlistener("modelChange", function SchemaObjectComponent_div_0_Template_schema_form_modelChange_3_listener($event) { i0.ɵɵrestoreView(_r5); const ctx_r4 = i0.ɵɵnextContext(); return i0.ɵɵresetView((ctx_r4.model[ctx_r4.schema.id] = $event)); });
1110
+ i0.ɵɵelementEnd();
1111
+ i0.ɵɵtemplate(4, SchemaObjectComponent_div_0_div_4_Template, 5, 9, "div", 4);
1112
+ i0.ɵɵelementEnd();
1113
+ } if (rf & 2) {
1114
+ const ctx_r0 = i0.ɵɵnextContext();
1115
+ i0.ɵɵadvance(2);
1116
+ i0.ɵɵtextInterpolate(ctx_r0.schema.title);
1117
+ i0.ɵɵadvance(1);
1118
+ i0.ɵɵproperty("selectPlaceHolderLabel", ctx_r0.selectPlaceHolderLabel)("selectSearchPlaceHolderLabel", ctx_r0.selectSearchPlaceHolderLabel)("selectClearLabel", ctx_r0.selectClearLabel)("selectNotFoundLabel", ctx_r0.selectNotFoundLabel)("requiredLabel", ctx_r0.requiredLabel)("addItemLabel", ctx_r0.addItemLabel)("addLoopLabel", ctx_r0.addLoopLabel)("additionalAttributesLabel", ctx_r0.additionalAttributesLabel)("customAttributeRemoveLabel", ctx_r0.customAttributeRemoveLabel)("newCustomFieldNameLabel", ctx_r0.newCustomFieldNameLabel)("newCustomFieldValueLabel", ctx_r0.newCustomFieldValueLabel)("newCustomFieldAddLabel", ctx_r0.newCustomFieldAddLabel)("newCustomFieldSaveLabel", ctx_r0.newCustomFieldSaveLabel)("newCustomFieldCancelLabel", ctx_r0.newCustomFieldCancelLabel)("idPrefix", ctx_r0.idPrefix)("model", ctx_r0.model[ctx_r0.schema.id])("schemas", ctx_r0.getSchemaProperties())("editing", ctx_r0.editing);
1119
+ i0.ɵɵadvance(1);
1120
+ i0.ɵɵproperty("ngIf", ctx_r0.model[ctx_r0.schema.id] && ctx_r0.schema.customProperties);
1121
+ } }
1122
+ class SchemaObjectComponent extends BaseSchemaComponent {
1123
+ constructor() {
1124
+ super(...arguments);
1125
+ this.requiredLabel = '(required)';
1126
+ this.addItemLabel = 'Add Item';
1127
+ this.addLoopLabel = 'Add Loop';
1128
+ this.additionalAttributesLabel = 'Additional Fields';
1129
+ this.customAttributeRemoveLabel = 'Remove';
1130
+ this.newCustomFieldNameLabel = 'Name';
1131
+ this.newCustomFieldValueLabel = 'Value';
1132
+ this.newCustomFieldAddLabel = 'Add';
1133
+ this.newCustomFieldSaveLabel = 'Save';
1134
+ this.newCustomFieldCancelLabel = 'Cancel';
1135
+ this.selectPlaceHolderLabel = 'Select Item';
1136
+ this.selectSearchPlaceHolderLabel = 'Search';
1137
+ this.selectClearLabel = 'Clear';
1138
+ this.selectNotFoundLabel = 'No Items Found';
1139
+ this.editing = false;
1140
+ this.onDropEvent = new EventEmitter();
1141
+ this.loaded = false;
1142
+ }
1143
+ ngAfterContentInit() {
1144
+ if (this.schema?.type === 'object' && this.model) {
1145
+ this.model[this.schema.id] = this.model[this.schema.id] || {};
1146
+ }
1147
+ this.loaded = true;
1148
+ }
1149
+ onDrop($event, modelElement) {
1150
+ return onDropStruct($event, modelElement);
1151
+ }
1152
+ }
1153
+ SchemaObjectComponent.ɵfac = /*@__PURE__*/ function () { let ɵSchemaObjectComponent_BaseFactory; return function SchemaObjectComponent_Factory(t) { return (ɵSchemaObjectComponent_BaseFactory || (ɵSchemaObjectComponent_BaseFactory = i0.ɵɵgetInheritedFactory(SchemaObjectComponent)))(t || SchemaObjectComponent); }; }();
1154
+ SchemaObjectComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SchemaObjectComponent, selectors: [["schema-object"]], inputs: { requiredLabel: "requiredLabel", addItemLabel: "addItemLabel", addLoopLabel: "addLoopLabel", additionalAttributesLabel: "additionalAttributesLabel", customAttributeRemoveLabel: "customAttributeRemoveLabel", newCustomFieldNameLabel: "newCustomFieldNameLabel", newCustomFieldValueLabel: "newCustomFieldValueLabel", newCustomFieldAddLabel: "newCustomFieldAddLabel", newCustomFieldSaveLabel: "newCustomFieldSaveLabel", newCustomFieldCancelLabel: "newCustomFieldCancelLabel", selectPlaceHolderLabel: "selectPlaceHolderLabel", selectSearchPlaceHolderLabel: "selectSearchPlaceHolderLabel", selectClearLabel: "selectClearLabel", selectNotFoundLabel: "selectNotFoundLabel", idPrefix: "idPrefix", modelPropertiesPath: "modelPropertiesPath", inputId: "inputId", editing: "editing", index: "index" }, outputs: { onDropEvent: "onDropEvent" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "schema-object-container", 4, "ngIf"], [1, "schema-object-container"], [1, "schema-object-title"], [3, "selectPlaceHolderLabel", "selectSearchPlaceHolderLabel", "selectClearLabel", "selectNotFoundLabel", "requiredLabel", "addItemLabel", "addLoopLabel", "additionalAttributesLabel", "customAttributeRemoveLabel", "newCustomFieldNameLabel", "newCustomFieldValueLabel", "newCustomFieldAddLabel", "newCustomFieldSaveLabel", "newCustomFieldCancelLabel", "idPrefix", "model", "schemas", "editing", "modelChange"], ["class", "row struct-custom-properties", 4, "ngIf"], [1, "row", "struct-custom-properties"], [1, "col-md-12"], [1, "info-label", "bold"], [3, "customAttributeRemoveLabel", "newCustomFieldNameLabel", "newCustomFieldValueLabel", "newCustomFieldAddLabel", "newCustomFieldSaveLabel", "newCustomFieldCancelLabel", "model", "onDropFunction", "modelChange"]], template: function SchemaObjectComponent_Template(rf, ctx) { if (rf & 1) {
1155
+ i0.ɵɵtemplate(0, SchemaObjectComponent_div_0_Template, 5, 20, "div", 0);
1156
+ } if (rf & 2) {
1157
+ i0.ɵɵproperty("ngIf", ctx.loaded && ctx.canRender(ctx.schema) && ctx.schema.type == "object");
1158
+ } }, dependencies: [i1.NgIf, SchemaFormComponent, SchemaCustomAttributesComponent], styles: [".schema-object-container[_ngcontent-%COMP%]{border:1px solid #ddd;padding:10px;margin-top:10px;margin-bottom:10px;border-radius:5px}.schema-object-container[_ngcontent-%COMP%] .schema-object-title[_ngcontent-%COMP%]{background:#EEEEEE;font-weight:700;border-bottom:1px solid #ddd;padding:10px;margin-top:-10px;margin-left:-10px;width:calc(100% + 20px)}"] });
1159
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SchemaObjectComponent, [{
1160
+ type: Component,
1161
+ args: [{ selector: 'schema-object', template: "<div class=\"schema-object-container\" *ngIf=\"loaded && canRender(schema) && schema.type == 'object'\">\r\n <div class=\"schema-object-title\">{{schema.title}}</div>\r\n <schema-form\r\n [selectPlaceHolderLabel]=\"selectPlaceHolderLabel\"\r\n [selectSearchPlaceHolderLabel]=\"selectSearchPlaceHolderLabel\"\r\n [selectClearLabel]=\"selectClearLabel\"\r\n [selectNotFoundLabel]=\"selectNotFoundLabel\"\r\n [requiredLabel]=\"requiredLabel\"\r\n [addItemLabel]=\"addItemLabel\"\r\n [addLoopLabel]=\"addLoopLabel\"\r\n [additionalAttributesLabel]=\"additionalAttributesLabel\"\r\n [customAttributeRemoveLabel]=\"customAttributeRemoveLabel\"\r\n [newCustomFieldNameLabel]=\"newCustomFieldNameLabel\"\r\n [newCustomFieldValueLabel]=\"newCustomFieldValueLabel\"\r\n [newCustomFieldAddLabel]=\"newCustomFieldAddLabel\"\r\n [newCustomFieldSaveLabel]=\"newCustomFieldSaveLabel\"\r\n [newCustomFieldCancelLabel]=\"newCustomFieldCancelLabel\"\r\n [idPrefix]=\"idPrefix\"\r\n [(model)]=\"model[schema.id]\"\r\n [schemas]=\"getSchemaProperties()\"\r\n [editing]=\"this.editing\">\r\n </schema-form>\r\n\r\n <div class=\"row struct-custom-properties\" *ngIf=\"this.model[schema.id] && schema.customProperties\">\r\n <div class=\"col-md-12\">\r\n <label class=\"info-label bold\">{{ this.additionalAttributesLabel }}</label>\r\n <schema-custom-attributes\r\n [customAttributeRemoveLabel]=\"customAttributeRemoveLabel\"\r\n [newCustomFieldNameLabel]=\"newCustomFieldNameLabel\"\r\n [newCustomFieldValueLabel]=\"newCustomFieldValueLabel\"\r\n [newCustomFieldAddLabel]=\"newCustomFieldAddLabel\"\r\n [newCustomFieldSaveLabel]=\"newCustomFieldSaveLabel\"\r\n [newCustomFieldCancelLabel]=\"newCustomFieldCancelLabel\"\r\n [(model)]=\"this.model[schema.id].customAttributes\"\r\n [onDropFunction]=\"onDrop\">\r\n </schema-custom-attributes>\r\n </div>\r\n </div>\r\n\r\n</div>\r\n", styles: [".schema-object-container{border:1px solid #ddd;padding:10px;margin-top:10px;margin-bottom:10px;border-radius:5px}.schema-object-container .schema-object-title{background:#EEEEEE;font-weight:700;border-bottom:1px solid #ddd;padding:10px;margin-top:-10px;margin-left:-10px;width:calc(100% + 20px)}\n"] }]
1162
+ }], null, { requiredLabel: [{
1163
+ type: Input
1164
+ }], addItemLabel: [{
1165
+ type: Input
1166
+ }], addLoopLabel: [{
1167
+ type: Input
1168
+ }], additionalAttributesLabel: [{
1169
+ type: Input
1170
+ }], customAttributeRemoveLabel: [{
1171
+ type: Input
1172
+ }], newCustomFieldNameLabel: [{
1173
+ type: Input
1174
+ }], newCustomFieldValueLabel: [{
1175
+ type: Input
1176
+ }], newCustomFieldAddLabel: [{
1177
+ type: Input
1178
+ }], newCustomFieldSaveLabel: [{
1179
+ type: Input
1180
+ }], newCustomFieldCancelLabel: [{
1181
+ type: Input
1182
+ }], selectPlaceHolderLabel: [{
1183
+ type: Input
1184
+ }], selectSearchPlaceHolderLabel: [{
1185
+ type: Input
1186
+ }], selectClearLabel: [{
1187
+ type: Input
1188
+ }], selectNotFoundLabel: [{
1189
+ type: Input
1190
+ }], idPrefix: [{
1191
+ type: Input
1192
+ }], modelPropertiesPath: [{
1193
+ type: Input
1194
+ }], inputId: [{
1195
+ type: Input
1196
+ }], editing: [{
1197
+ type: Input
1198
+ }], index: [{
1199
+ type: Input
1200
+ }], onDropEvent: [{
1201
+ type: Output
1202
+ }] }); })();
1203
+
1204
+ class SchemaValidationField {
1205
+ constructor(emptyFields, invalidMinLengthFields, invalidMaxLengthFields) {
1206
+ this.emptyFields = emptyFields;
1207
+ this.invalidMinLengthFields = invalidMinLengthFields;
1208
+ this.invalidMaxLengthFields = invalidMaxLengthFields;
1209
+ }
1210
+ isValidSchemaFields() {
1211
+ return this.emptyFields?.length < 1 && this.invalidMinLengthFields?.length < 1 && this.invalidMaxLengthFields?.length < 1;
1212
+ }
1213
+ isInvalidSchemaFields() {
1214
+ return !this.isValidSchemaFields();
1215
+ }
1216
+ }
1217
+
1218
+ class SchemaFieldsService {
1219
+ async validateSchemaFields(propertiesRendered, model, editing) {
1220
+ if (!propertiesRendered) {
1221
+ return new SchemaValidationField([], [], []);
1222
+ }
1223
+ const emptyFields = [];
1224
+ const invalidMinLengthFields = [];
1225
+ const invalidMaxLengthFields = [];
1226
+ this.processProperties(propertiesRendered, model, editing, emptyFields, invalidMinLengthFields, invalidMaxLengthFields);
1227
+ const structValidationField = new SchemaValidationField(emptyFields, invalidMinLengthFields, invalidMaxLengthFields);
1228
+ structValidationField.validationErrorsLabel = await this.getErrorsStringArray(structValidationField);
1229
+ return structValidationField;
1230
+ }
1231
+ processProperties(propertiesRendered, model, editing, emptyFields, invalidMinLengthFields, invalidMaxLengthFields, recursive) {
1232
+ for (const property of propertiesRendered) {
1233
+ if ((property.type === 'object' || property.type === 'array') && property.properties) {
1234
+ this.processProperties(property.properties, model[property.id], editing, emptyFields, invalidMinLengthFields, invalidMaxLengthFields, true);
1235
+ }
1236
+ else if (property.type === 'array' && !property.properties) {
1237
+ const newProperty = { ...property };
1238
+ newProperty.type = 'string';
1239
+ this.processProperties([newProperty], model[property.id], editing, emptyFields, invalidMinLengthFields, invalidMaxLengthFields, true);
1240
+ }
1241
+ else {
1242
+ const validateModel = recursive ? model : model[property.id];
1243
+ if (property.type !== 'password' || !editing || validateModel !== undefined) {
1244
+ if (property?.canRender && property?.minLength > 0 &&
1245
+ (validateModel === undefined || validateModel === '' || validateModel === null)) {
1246
+ emptyFields.push(property);
1247
+ }
1248
+ else if (property?.canRender && property?.minLength > 0 && (validateModel?.length < property.minLength)) {
1249
+ invalidMinLengthFields.push(property);
1250
+ }
1251
+ else if (property?.canRender && property?.maxLength > 0 && (validateModel?.length > property.maxLength)) {
1252
+ invalidMaxLengthFields.push(property);
1253
+ }
1254
+ }
1255
+ }
1256
+ }
1257
+ }
1258
+ async getErrorsStringArray(structValidation) {
1259
+ if (!structValidation.isInvalidSchemaFields()) {
1260
+ return [];
1261
+ }
1262
+ const errors = [];
1263
+ for (const field of structValidation.emptyFields) {
1264
+ const fieldName = field.title || field.id;
1265
+ errors.push({
1266
+ type: 'emptyFields',
1267
+ fieldName
1268
+ });
1269
+ }
1270
+ for (const field of structValidation.invalidMinLengthFields) {
1271
+ const fieldName = field.title || field.id;
1272
+ errors.push({
1273
+ type: 'invalidMinLengthFields',
1274
+ fieldName,
1275
+ minLength: field.minLength
1276
+ });
1277
+ }
1278
+ for (const field of structValidation.invalidMaxLengthFields) {
1279
+ const fieldName = field.title || field.id;
1280
+ errors.push({
1281
+ type: 'invalidMaxLengthFields',
1282
+ fieldName,
1283
+ maxLength: field.maxLength
1284
+ });
1285
+ }
1286
+ return errors;
1287
+ }
1288
+ }
1289
+ SchemaFieldsService.ɵfac = function SchemaFieldsService_Factory(t) { return new (t || SchemaFieldsService)(); };
1290
+ SchemaFieldsService.ɵprov = /*@__PURE__*/ i0.ɵɵdefineInjectable({ token: SchemaFieldsService, factory: SchemaFieldsService.ɵfac });
1291
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SchemaFieldsService, [{
1292
+ type: Injectable
1293
+ }], null, null); })();
1294
+
1295
+ function SchemaFormRenderComponent_div_0_div_2_div_1_Template(rf, ctx) { if (rf & 1) {
1296
+ const _r6 = i0.ɵɵgetCurrentView();
1297
+ i0.ɵɵelementStart(0, "div", 6)(1, "div", 7)(2, "label", 8);
1298
+ i0.ɵɵtext(3);
1299
+ i0.ɵɵelementEnd();
1300
+ i0.ɵɵelementStart(4, "schema-custom-attributes", 9);
1301
+ i0.ɵɵlistener("modelChange", function SchemaFormRenderComponent_div_0_div_2_div_1_Template_schema_custom_attributes_modelChange_4_listener($event) { i0.ɵɵrestoreView(_r6); const ctx_r5 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r5.model.customAttributes = $event); });
1302
+ i0.ɵɵelementEnd()()();
1303
+ } if (rf & 2) {
1304
+ const ctx_r4 = i0.ɵɵnextContext(3);
1305
+ i0.ɵɵadvance(3);
1306
+ i0.ɵɵtextInterpolate(ctx_r4.additionalAttributesLabel);
1307
+ i0.ɵɵadvance(1);
1308
+ i0.ɵɵproperty("customAttributeRemoveLabel", ctx_r4.customAttributeRemoveLabel)("newCustomFieldNameLabel", ctx_r4.newCustomFieldNameLabel)("newCustomFieldValueLabel", ctx_r4.newCustomFieldValueLabel)("newCustomFieldAddLabel", ctx_r4.newCustomFieldAddLabel)("newCustomFieldSaveLabel", ctx_r4.newCustomFieldSaveLabel)("newCustomFieldCancelLabel", ctx_r4.newCustomFieldCancelLabel)("model", ctx_r4.model.customAttributes)("onDropFunction", ctx_r4.onDrop);
1309
+ } }
1310
+ function SchemaFormRenderComponent_div_0_div_2_Template(rf, ctx) { if (rf & 1) {
1311
+ i0.ɵɵelementStart(0, "div", 4);
1312
+ i0.ɵɵtemplate(1, SchemaFormRenderComponent_div_0_div_2_div_1_Template, 5, 9, "div", 5);
1313
+ i0.ɵɵelementEnd();
1314
+ } if (rf & 2) {
1315
+ const ctx_r1 = i0.ɵɵnextContext(2);
1316
+ i0.ɵɵadvance(1);
1317
+ i0.ɵɵproperty("ngIf", ctx_r1.model && ctx_r1.customProperties);
1318
+ } }
1319
+ function SchemaFormRenderComponent_div_0_Template(rf, ctx) { if (rf & 1) {
1320
+ const _r8 = i0.ɵɵgetCurrentView();
1321
+ i0.ɵɵelementStart(0, "div", 1)(1, "schema-form", 2);
1322
+ i0.ɵɵlistener("modelChange", function SchemaFormRenderComponent_div_0_Template_schema_form_modelChange_1_listener($event) { i0.ɵɵrestoreView(_r8); const ctx_r7 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r7.model = $event); });
1323
+ i0.ɵɵelementEnd();
1324
+ i0.ɵɵtemplate(2, SchemaFormRenderComponent_div_0_div_2_Template, 2, 1, "div", 3);
1325
+ i0.ɵɵelementEnd();
1326
+ } if (rf & 2) {
1327
+ const ctx_r0 = i0.ɵɵnextContext();
1328
+ i0.ɵɵadvance(1);
1329
+ i0.ɵɵproperty("selectPlaceHolderLabel", ctx_r0.selectPlaceHolderLabel)("selectSearchPlaceHolderLabel", ctx_r0.selectSearchPlaceHolderLabel)("selectClearLabel", ctx_r0.selectClearLabel)("selectNotFoundLabel", ctx_r0.selectNotFoundLabel)("requiredLabel", ctx_r0.requiredLabel)("addItemLabel", ctx_r0.addItemLabel)("addLoopLabel", ctx_r0.addLoopLabel)("additionalAttributesLabel", ctx_r0.additionalAttributesLabel)("customAttributeRemoveLabel", ctx_r0.customAttributeRemoveLabel)("newCustomFieldNameLabel", ctx_r0.newCustomFieldNameLabel)("newCustomFieldValueLabel", ctx_r0.newCustomFieldValueLabel)("newCustomFieldAddLabel", ctx_r0.newCustomFieldAddLabel)("newCustomFieldSaveLabel", ctx_r0.newCustomFieldSaveLabel)("newCustomFieldCancelLabel", ctx_r0.newCustomFieldCancelLabel)("idPrefix", ctx_r0.idPrefix)("model", ctx_r0.model)("schemas", ctx_r0.schemas)("editing", ctx_r0.editing);
1330
+ i0.ɵɵadvance(1);
1331
+ i0.ɵɵproperty("ngForOf", ctx_r0.schemas);
1332
+ } }
1333
+ class SchemaFormRenderComponent extends BaseSchemaComponent {
1334
+ constructor() {
1335
+ super(...arguments);
1336
+ this.requiredLabel = '(required)';
1337
+ this.addItemLabel = 'Add Item';
1338
+ this.addLoopLabel = 'Add Loop';
1339
+ this.additionalAttributesLabel = 'Additional Fields';
1340
+ this.customAttributeRemoveLabel = 'Remove';
1341
+ this.newCustomFieldNameLabel = 'Name';
1342
+ this.newCustomFieldValueLabel = 'Value';
1343
+ this.newCustomFieldAddLabel = 'Add';
1344
+ this.newCustomFieldSaveLabel = 'Save';
1345
+ this.newCustomFieldCancelLabel = 'Cancel';
1346
+ this.selectPlaceHolderLabel = 'Select Item';
1347
+ this.selectSearchPlaceHolderLabel = 'Search';
1348
+ this.selectClearLabel = 'Clear';
1349
+ this.selectNotFoundLabel = 'No Items Found';
1350
+ this.schemas = [];
1351
+ this.customProperties = false;
1352
+ this.editing = false;
1353
+ this.loaded = false;
1354
+ }
1355
+ ngAfterContentInit() {
1356
+ this.loaded = true;
1357
+ }
1358
+ onDrop($event, modelElement) {
1359
+ return onDropStruct($event, modelElement);
1360
+ }
1361
+ getId(index) {
1362
+ return `${this.idPrefix}-struct-${index}`;
1363
+ }
1364
+ }
1365
+ SchemaFormRenderComponent.ɵfac = /*@__PURE__*/ function () { let ɵSchemaFormRenderComponent_BaseFactory; return function SchemaFormRenderComponent_Factory(t) { return (ɵSchemaFormRenderComponent_BaseFactory || (ɵSchemaFormRenderComponent_BaseFactory = i0.ɵɵgetInheritedFactory(SchemaFormRenderComponent)))(t || SchemaFormRenderComponent); }; }();
1366
+ SchemaFormRenderComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SchemaFormRenderComponent, selectors: [["schema-form-render"]], inputs: { requiredLabel: "requiredLabel", addItemLabel: "addItemLabel", addLoopLabel: "addLoopLabel", additionalAttributesLabel: "additionalAttributesLabel", customAttributeRemoveLabel: "customAttributeRemoveLabel", newCustomFieldNameLabel: "newCustomFieldNameLabel", newCustomFieldValueLabel: "newCustomFieldValueLabel", newCustomFieldAddLabel: "newCustomFieldAddLabel", newCustomFieldSaveLabel: "newCustomFieldSaveLabel", newCustomFieldCancelLabel: "newCustomFieldCancelLabel", selectPlaceHolderLabel: "selectPlaceHolderLabel", selectSearchPlaceHolderLabel: "selectSearchPlaceHolderLabel", selectClearLabel: "selectClearLabel", selectNotFoundLabel: "selectNotFoundLabel", idPrefix: "idPrefix", schemas: "schemas", customProperties: "customProperties", editing: "editing", inputType: "inputType" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "schema", 4, "ngIf"], [1, "schema"], [3, "selectPlaceHolderLabel", "selectSearchPlaceHolderLabel", "selectClearLabel", "selectNotFoundLabel", "requiredLabel", "addItemLabel", "addLoopLabel", "additionalAttributesLabel", "customAttributeRemoveLabel", "newCustomFieldNameLabel", "newCustomFieldValueLabel", "newCustomFieldAddLabel", "newCustomFieldSaveLabel", "newCustomFieldCancelLabel", "idPrefix", "model", "schemas", "editing", "modelChange"], ["class", "schema-properties", 4, "ngFor", "ngForOf"], [1, "schema-properties"], ["class", "row struct-custom-properties", 4, "ngIf"], [1, "row", "struct-custom-properties"], [1, "col-md-12"], [1, "info-label", "bold"], [3, "customAttributeRemoveLabel", "newCustomFieldNameLabel", "newCustomFieldValueLabel", "newCustomFieldAddLabel", "newCustomFieldSaveLabel", "newCustomFieldCancelLabel", "model", "onDropFunction", "modelChange"]], template: function SchemaFormRenderComponent_Template(rf, ctx) { if (rf & 1) {
1367
+ i0.ɵɵtemplate(0, SchemaFormRenderComponent_div_0_Template, 3, 19, "div", 0);
1368
+ } if (rf & 2) {
1369
+ i0.ɵɵproperty("ngIf", ctx.loaded);
1370
+ } }, dependencies: [i1.NgForOf, i1.NgIf, SchemaFormComponent, SchemaCustomAttributesComponent], styles: [".schema[_ngcontent-%COMP%] .info-label{display:block}.schema[_ngcontent-%COMP%] input.form-control{width:calc(100% - 24px);padding:11px;border:1px solid #DDD;border-radius:3px;background:#FFF}.schema[_ngcontent-%COMP%] input.form-control:disabled{background:#ccc}.schema[_ngcontent-%COMP%] select.form-control{width:100%;padding:11px;border-radius:4px;border:1px solid #DDD;color:#777;cursor:pointer}.schema[_ngcontent-%COMP%] .ng-select-container{height:38px!important;min-height:38px!important}.schema[_ngcontent-%COMP%] .btn-outline-primary{padding:5px 15px;background:var(--color-primary);border:1px solid var(--color-secondary);color:var(--color-secondary);border-radius:4px;cursor:pointer}.schema[_ngcontent-%COMP%] .btn-outline-primary:hover{background:var(--color-primary-hover)}.schema[_ngcontent-%COMP%] .subsection-item-title{color:var(--color-primary)}.schema[_ngcontent-%COMP%] array-session .subsection-element{color:var(--color-primary)}"] });
1371
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SchemaFormRenderComponent, [{
1372
+ type: Component,
1373
+ args: [{ selector: 'schema-form-render', template: "<div class=\"schema\" *ngIf=\"loaded\">\r\n <schema-form\r\n [selectPlaceHolderLabel]=\"selectPlaceHolderLabel\"\r\n [selectSearchPlaceHolderLabel]=\"selectSearchPlaceHolderLabel\"\r\n [selectClearLabel]=\"selectClearLabel\"\r\n [selectNotFoundLabel]=\"selectNotFoundLabel\"\r\n [requiredLabel]=\"requiredLabel\"\r\n [addItemLabel]=\"addItemLabel\"\r\n [addLoopLabel]=\"addLoopLabel\"\r\n [additionalAttributesLabel]=\"additionalAttributesLabel\"\r\n [customAttributeRemoveLabel]=\"customAttributeRemoveLabel\"\r\n [newCustomFieldNameLabel]=\"newCustomFieldNameLabel\"\r\n [newCustomFieldValueLabel]=\"newCustomFieldValueLabel\"\r\n [newCustomFieldAddLabel]=\"newCustomFieldAddLabel\"\r\n [newCustomFieldSaveLabel]=\"newCustomFieldSaveLabel\"\r\n [newCustomFieldCancelLabel]=\"newCustomFieldCancelLabel\"\r\n [idPrefix]=\"idPrefix\"\r\n [(model)]=\"model\"\r\n [schemas]=\"schemas\"\r\n [editing]=\"this.editing\"></schema-form>\r\n\r\n <div class=\"schema-properties\" *ngFor=\"let schema of schemas; let i = index\">\r\n <div class=\"row struct-custom-properties\" *ngIf=\"this.model && customProperties\">\r\n <div class=\"col-md-12\">\r\n <label class=\"info-label bold\">{{ this.additionalAttributesLabel }}</label>\r\n <schema-custom-attributes\r\n [customAttributeRemoveLabel]=\"customAttributeRemoveLabel\"\r\n [newCustomFieldNameLabel]=\"newCustomFieldNameLabel\"\r\n [newCustomFieldValueLabel]=\"newCustomFieldValueLabel\"\r\n [newCustomFieldAddLabel]=\"newCustomFieldAddLabel\"\r\n [newCustomFieldSaveLabel]=\"newCustomFieldSaveLabel\"\r\n [newCustomFieldCancelLabel]=\"newCustomFieldCancelLabel\"\r\n [(model)]=\"model.customAttributes\"\r\n [onDropFunction]=\"onDrop\">\r\n </schema-custom-attributes>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n</div>\r\n", styles: [".schema ::ng-deep .info-label{display:block}.schema ::ng-deep input.form-control{width:calc(100% - 24px);padding:11px;border:1px solid #DDD;border-radius:3px;background:#FFF}.schema ::ng-deep input.form-control:disabled{background:#ccc}.schema ::ng-deep select.form-control{width:100%;padding:11px;border-radius:4px;border:1px solid #DDD;color:#777;cursor:pointer}.schema ::ng-deep .ng-select-container{height:38px!important;min-height:38px!important}.schema ::ng-deep .btn-outline-primary{padding:5px 15px;background:var(--color-primary);border:1px solid var(--color-secondary);color:var(--color-secondary);border-radius:4px;cursor:pointer}.schema ::ng-deep .btn-outline-primary:hover{background:var(--color-primary-hover)}.schema ::ng-deep .subsection-item-title{color:var(--color-primary)}.schema ::ng-deep array-session .subsection-element{color:var(--color-primary)}\n"] }]
1374
+ }], null, { requiredLabel: [{
1375
+ type: Input
1376
+ }], addItemLabel: [{
1377
+ type: Input
1378
+ }], addLoopLabel: [{
1379
+ type: Input
1380
+ }], additionalAttributesLabel: [{
1381
+ type: Input
1382
+ }], customAttributeRemoveLabel: [{
1383
+ type: Input
1384
+ }], newCustomFieldNameLabel: [{
1385
+ type: Input
1386
+ }], newCustomFieldValueLabel: [{
1387
+ type: Input
1388
+ }], newCustomFieldAddLabel: [{
1389
+ type: Input
1390
+ }], newCustomFieldSaveLabel: [{
1391
+ type: Input
1392
+ }], newCustomFieldCancelLabel: [{
1393
+ type: Input
1394
+ }], selectPlaceHolderLabel: [{
1395
+ type: Input
1396
+ }], selectSearchPlaceHolderLabel: [{
1397
+ type: Input
1398
+ }], selectClearLabel: [{
1399
+ type: Input
1400
+ }], selectNotFoundLabel: [{
1401
+ type: Input
1402
+ }], idPrefix: [{
1403
+ type: Input
1404
+ }], schemas: [{
1405
+ type: Input
1406
+ }], customProperties: [{
1407
+ type: Input
1408
+ }], editing: [{
1409
+ type: Input
1410
+ }], inputType: [{
1411
+ type: Input
1412
+ }] }); })();
1413
+
1414
+ class TypeScriptCompileBase {
1415
+ getTranslate(text) {
1416
+ return text;
1417
+ }
1418
+ addItemToFormProperties(formProperties, item, key) {
1419
+ this.translateProperties(item);
1420
+ if (item.minLength && item.minLength > 0) {
1421
+ formProperties[key] = new FormControl([null, [Validators.required]]);
1422
+ }
1423
+ else {
1424
+ formProperties[key] = new FormControl([null]);
1425
+ }
1426
+ }
1427
+ compileProperties(input) {
1428
+ const compiledProperties = [];
1429
+ const formProperties = {};
1430
+ let inputData = {};
1431
+ const inputToCompile = JSON.parse(JSON.stringify(input));
1432
+ this.translateProperties(inputToCompile);
1433
+ if (inputToCompile.properties) {
1434
+ if (inputToCompile.type === 'array') {
1435
+ inputData = [];
1436
+ }
1437
+ if (inputToCompile.type === 'object') {
1438
+ inputData = {};
1439
+ }
1440
+ inputToCompile.id = 'inputData';
1441
+ this.proccessProperties(inputToCompile, formProperties, 'inputData');
1442
+ this.translateProperties(inputToCompile);
1443
+ compiledProperties.push(inputToCompile);
1444
+ }
1445
+ else if (inputToCompile.type === 'array') {
1446
+ inputToCompile.id = 'inputData';
1447
+ inputData = [];
1448
+ this.addItemToFormProperties(formProperties, inputToCompile, 'inputData');
1449
+ compiledProperties.push(inputToCompile);
1450
+ }
1451
+ else if (!inputToCompile.type) {
1452
+ for (let index = 0; index < Object.keys(inputToCompile).length; index++) {
1453
+ const key = Object.keys(inputToCompile)[index];
1454
+ const item = inputToCompile[key];
1455
+ item.id = key;
1456
+ if (item.type === 'array') {
1457
+ inputData[item.id] = [];
1458
+ }
1459
+ if (item.type === 'object') {
1460
+ inputData[item.id] = {};
1461
+ }
1462
+ this.proccessProperties(item, formProperties, key);
1463
+ this.translateProperties(item);
1464
+ compiledProperties.push(item);
1465
+ }
1466
+ }
1467
+ compiledProperties.sort((a, b) => a.propertyOrder - b.propertyOrder);
1468
+ return { compiledProperties, formProperties, inputData };
1469
+ }
1470
+ translateProperties(input) {
1471
+ if (input?.title) {
1472
+ input.title = this.getTranslate(input.title);
1473
+ }
1474
+ if (input?.description) {
1475
+ input.description = this.getTranslate(input.description);
1476
+ }
1477
+ if (input?.options instanceof Array) {
1478
+ input?.options.forEach((option) => {
1479
+ option.value = this.getTranslate(option.value);
1480
+ });
1481
+ }
1482
+ }
1483
+ proccessProperties(item, formProperties, key) {
1484
+ this.translateProperties(item);
1485
+ if (this.hasProperties(item)) {
1486
+ const arFieldsChild = [];
1487
+ for (let indexChild = 0; indexChild < Object.keys(item.properties).length; indexChild++) {
1488
+ const keyChild = Object.keys(item.properties)[indexChild];
1489
+ const itemChild = item.properties[keyChild];
1490
+ itemChild.id = keyChild;
1491
+ if (this.hasProperties(itemChild)) {
1492
+ this.proccessProperties(itemChild, formProperties, keyChild);
1493
+ arFieldsChild.push(itemChild);
1494
+ }
1495
+ else {
1496
+ this.addItemToFormProperties(formProperties, itemChild, keyChild);
1497
+ arFieldsChild.push(itemChild);
1498
+ }
1499
+ }
1500
+ item.properties = arFieldsChild;
1501
+ }
1502
+ else {
1503
+ this.addItemToFormProperties(formProperties, item, key);
1504
+ }
1505
+ }
1506
+ hasProperties(item) {
1507
+ return item.type === 'object' || (item.type === 'array' && item.properties);
1508
+ }
1509
+ }
1510
+ TypeScriptCompileBase.ɵfac = function TypeScriptCompileBase_Factory(t) { return new (t || TypeScriptCompileBase)(); };
1511
+ TypeScriptCompileBase.ɵprov = /*@__PURE__*/ i0.ɵɵdefineInjectable({ token: TypeScriptCompileBase, factory: TypeScriptCompileBase.ɵfac, providedIn: 'root' });
1512
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TypeScriptCompileBase, [{
1513
+ type: Injectable,
1514
+ args: [{ providedIn: 'root' }]
1515
+ }], null, null); })();
1516
+ function APIPASS_TYPESCRIPT_COMPILE_BASE_PROVIDER_FACTORY(parentIntl) {
1517
+ return parentIntl || new TypeScriptCompileBase();
1518
+ }
1519
+ const APIPASS_TYPESCRIPT_COMPILE_INTL_PROVIDER = {
1520
+ provide: TypeScriptCompileBase,
1521
+ deps: [[new Optional(), new SkipSelf(), TypeScriptCompileBase]],
1522
+ useFactory: APIPASS_TYPESCRIPT_COMPILE_BASE_PROVIDER_FACTORY
1523
+ };
1524
+
1525
+ class SchemaFormRenderModule {
1526
+ }
1527
+ SchemaFormRenderModule.ɵfac = function SchemaFormRenderModule_Factory(t) { return new (t || SchemaFormRenderModule)(); };
1528
+ SchemaFormRenderModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: SchemaFormRenderModule });
1529
+ SchemaFormRenderModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ providers: [
1530
+ SchemaFieldsService,
1531
+ APIPASS_TYPESCRIPT_COMPILE_INTL_PROVIDER
1532
+ ], imports: [CommonModule,
1533
+ DndModule,
1534
+ FormsModule,
1535
+ MatTooltipModule,
1536
+ InputsModule,
1537
+ IconsModule] });
1538
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SchemaFormRenderModule, [{
1539
+ type: NgModule,
1540
+ args: [{
1541
+ imports: [
1542
+ CommonModule,
1543
+ DndModule,
1544
+ FormsModule,
1545
+ MatTooltipModule,
1546
+ InputsModule,
1547
+ IconsModule
1548
+ ],
1549
+ declarations: [
1550
+ ArraySessionComponent,
1551
+ SchemaArrayComponent,
1552
+ FieldRenderComponent,
1553
+ InputRenderComponent,
1554
+ BooleanInputComponent,
1555
+ NumberInputComponent,
1556
+ SchemaInputComponent,
1557
+ SchemaObjectComponent,
1558
+ SchemaFormRenderComponent,
1559
+ SchemaFormComponent,
1560
+ SchemaCustomAttributesComponent
1561
+ ],
1562
+ exports: [
1563
+ ArraySessionComponent,
1564
+ SchemaArrayComponent,
1565
+ FieldRenderComponent,
1566
+ InputRenderComponent,
1567
+ BooleanInputComponent,
1568
+ NumberInputComponent,
1569
+ SchemaInputComponent,
1570
+ SchemaObjectComponent,
1571
+ SchemaFormRenderComponent,
1572
+ SchemaFormComponent,
1573
+ SchemaCustomAttributesComponent
1574
+ ],
1575
+ providers: [
1576
+ SchemaFieldsService,
1577
+ APIPASS_TYPESCRIPT_COMPILE_INTL_PROVIDER
1578
+ ]
1579
+ }]
1580
+ }], null, null); })();
1581
+ (function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(SchemaFormRenderModule, { declarations: [ArraySessionComponent,
1582
+ SchemaArrayComponent,
1583
+ FieldRenderComponent,
1584
+ InputRenderComponent,
1585
+ BooleanInputComponent,
1586
+ NumberInputComponent,
1587
+ SchemaInputComponent,
1588
+ SchemaObjectComponent,
1589
+ SchemaFormRenderComponent,
1590
+ SchemaFormComponent,
1591
+ SchemaCustomAttributesComponent], imports: [CommonModule,
1592
+ DndModule,
1593
+ FormsModule,
1594
+ MatTooltipModule,
1595
+ InputsModule,
1596
+ IconsModule], exports: [ArraySessionComponent,
1597
+ SchemaArrayComponent,
1598
+ FieldRenderComponent,
1599
+ InputRenderComponent,
1600
+ BooleanInputComponent,
1601
+ NumberInputComponent,
1602
+ SchemaInputComponent,
1603
+ SchemaObjectComponent,
1604
+ SchemaFormRenderComponent,
1605
+ SchemaFormComponent,
1606
+ SchemaCustomAttributesComponent] }); })();
1607
+ i0.ɵɵsetComponentScope(SchemaFormComponent, [i1.NgForOf, SchemaArrayComponent,
1608
+ SchemaInputComponent,
1609
+ SchemaObjectComponent], []);
1610
+
1611
+ /**
1612
+ * Generated bundle index. Do not edit.
1613
+ */
1614
+
1615
+ export { APIPASS_TYPESCRIPT_COMPILE_BASE_PROVIDER_FACTORY, APIPASS_TYPESCRIPT_COMPILE_INTL_PROVIDER, ArraySessionComponent, BaseSchemaComponent, BooleanInputComponent, FieldRenderComponent, InputRenderComponent, NumberInputComponent, SchemaArrayComponent, SchemaCustomAttributesComponent, SchemaFieldsService, SchemaFormComponent, SchemaFormRenderComponent, SchemaFormRenderModule, SchemaInputComponent, SchemaObjectComponent, SchemaValidationField, TypeScriptCompileBase };
1616
+ //# sourceMappingURL=apipass-schemas.mjs.map