@rxap/schematic-angular 16.2.0-dev.20 → 16.2.0-dev.22

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 (189) hide show
  1. package/CHANGELOG.md +19 -0
  2. package/README.md +1 -1
  3. package/collection.json +15 -0
  4. package/package.json +7 -7
  5. package/src/lib/coerce-form-component.js +15 -3
  6. package/src/lib/coerce-form-component.js.map +1 -1
  7. package/src/lib/data-grid-item.d.ts +3 -3
  8. package/src/lib/data-grid-item.js +2 -2
  9. package/src/lib/data-grid-item.js.map +1 -1
  10. package/src/lib/form/abstract-control.d.ts +29 -0
  11. package/src/lib/form/abstract-control.js +37 -0
  12. package/src/lib/form/abstract-control.js.map +1 -0
  13. package/src/lib/form/array/base-form-array.d.ts +18 -0
  14. package/src/lib/form/array/base-form-array.js +40 -0
  15. package/src/lib/form/array/base-form-array.js.map +1 -0
  16. package/src/lib/form/array/form-array-kind.d.ts +3 -0
  17. package/src/lib/form/array/form-array-kind.js +8 -0
  18. package/src/lib/form/array/form-array-kind.js.map +1 -0
  19. package/src/lib/form/array/form-array.d.ts +12 -0
  20. package/src/lib/form/array/form-array.js +18 -0
  21. package/src/lib/form/array/form-array.js.map +1 -0
  22. package/src/lib/form/coerce-control-component-imports.d.ts +3 -0
  23. package/src/lib/form/coerce-control-component-imports.js +18 -0
  24. package/src/lib/form/coerce-control-component-imports.js.map +1 -0
  25. package/src/lib/form/control/autocomplete-table-select-form-control.d.ts +6 -0
  26. package/src/lib/form/control/autocomplete-table-select-form-control.js +34 -0
  27. package/src/lib/form/control/autocomplete-table-select-form-control.js.map +1 -0
  28. package/src/lib/form/control/base-form-control.d.ts +14 -0
  29. package/src/lib/form/control/base-form-control.js +19 -0
  30. package/src/lib/form/control/base-form-control.js.map +1 -0
  31. package/src/lib/form/control/checkbox-form-control.d.ts +11 -0
  32. package/src/lib/form/control/checkbox-form-control.js +23 -0
  33. package/src/lib/form/control/checkbox-form-control.js.map +1 -0
  34. package/src/lib/form/control/form-control-kind.d.ts +9 -0
  35. package/src/lib/form/control/form-control-kind.js +14 -0
  36. package/src/lib/form/control/form-control-kind.js.map +1 -0
  37. package/src/lib/form/control/form-control.d.ts +18 -0
  38. package/src/lib/form/control/form-control.js +43 -0
  39. package/src/lib/form/control/form-control.js.map +1 -0
  40. package/src/lib/form/control/form-field-form-control.d.ts +33 -0
  41. package/src/lib/form/control/form-field-form-control.js +76 -0
  42. package/src/lib/form/control/form-field-form-control.js.map +1 -0
  43. package/src/lib/form/control/input-form-control.d.ts +14 -0
  44. package/src/lib/form/control/input-form-control.js +71 -0
  45. package/src/lib/form/control/input-form-control.js.map +1 -0
  46. package/src/lib/form/control/select-form-control.d.ts +18 -0
  47. package/src/lib/form/control/select-form-control.js +29 -0
  48. package/src/lib/form/control/select-form-control.js.map +1 -0
  49. package/src/lib/form/control/slide-toggle-form-control.d.ts +11 -0
  50. package/src/lib/form/control/slide-toggle-form-control.js +23 -0
  51. package/src/lib/form/control/slide-toggle-form-control.js.map +1 -0
  52. package/src/lib/form/control/table-select-form-control.d.ts +43 -0
  53. package/src/lib/form/control/table-select-form-control.js +69 -0
  54. package/src/lib/form/control/table-select-form-control.js.map +1 -0
  55. package/src/lib/form/control.d.ts +8 -0
  56. package/src/lib/form/control.js +38 -0
  57. package/src/lib/form/control.js.map +1 -0
  58. package/src/lib/form/generate-form-template.d.ts +2 -2
  59. package/src/lib/form/group/base-form-group.d.ts +17 -0
  60. package/src/lib/form/group/base-form-group.js +20 -0
  61. package/src/lib/form/group/base-form-group.js.map +1 -0
  62. package/src/lib/form/group/form-group-kind.d.ts +3 -0
  63. package/src/lib/form/group/form-group-kind.js +8 -0
  64. package/src/lib/form/group/form-group-kind.js.map +1 -0
  65. package/src/lib/form/group/form-group.d.ts +12 -0
  66. package/src/lib/form/group/form-group.js +18 -0
  67. package/src/lib/form/group/form-group.js.map +1 -0
  68. package/src/lib/table-column.d.ts +4 -3
  69. package/src/lib/table-column.js +5 -4
  70. package/src/lib/table-column.js.map +1 -1
  71. package/src/schema.json +1691 -1311
  72. package/src/schematic-input.schema.json +109 -156
  73. package/src/schematics/abstract-control.schema.json +78 -0
  74. package/src/schematics/accordion/accordion-component/schema.json +127 -127
  75. package/src/schematics/accordion/accordion-item-component/schema.json +18 -18
  76. package/src/schematics/accordion/item/accordion-item-data-grid-component/schema.json +685 -81
  77. package/src/schematics/accordion/item/accordion-item-switch-component/schema.json +76 -76
  78. package/src/schematics/accordion/item/accordion-item-table-component/schema.json +555 -97
  79. package/src/schematics/accordion/item/accordion-item-tree-table-component/schema.json +537 -79
  80. package/src/schematics/autocomplete-table-select-form-control.schema.json +96 -0
  81. package/src/schematics/base-form-array.schema.json +45 -0
  82. package/src/schematics/base-form-control.schema.json +27 -0
  83. package/src/schematics/base-form-group.schema.json +42 -0
  84. package/src/schematics/checkbox-form-control.schema.json +30 -0
  85. package/src/schematics/control.schema.json +26 -0
  86. package/src/schematics/data-grid-component/index.js +4 -0
  87. package/src/schematics/data-grid-component/index.js.map +1 -1
  88. package/src/schematics/data-grid-component/schema.json +685 -81
  89. package/src/schematics/data-grid-item.schema.json +3 -3
  90. package/src/schematics/form/control/autocomplete-table-select-form-control/index.d.ts +10 -0
  91. package/src/schematics/form/control/autocomplete-table-select-form-control/index.js +247 -0
  92. package/src/schematics/form/control/autocomplete-table-select-form-control/index.js.map +1 -0
  93. package/src/schematics/form/control/autocomplete-table-select-form-control/schema.d.ts +4 -0
  94. package/src/schematics/form/control/autocomplete-table-select-form-control/schema.json +453 -0
  95. package/src/schematics/form/control/autocomplete-table-select-form-control/template.schema.json +39 -0
  96. package/src/schematics/form/control/input-form-control/index.d.ts +1 -1
  97. package/src/schematics/form/control/input-form-control/index.js +4 -4
  98. package/src/schematics/form/control/input-form-control/index.js.map +1 -1
  99. package/src/schematics/form/control/input-form-control/schema.d.ts +2 -2
  100. package/src/schematics/form/control/input-form-control/schema.json +256 -86
  101. package/src/schematics/form/control/input-form-control/template.schema.json +16 -3
  102. package/src/schematics/form/control/select-form-control/index.d.ts +2 -2
  103. package/src/schematics/form/control/select-form-control/index.js +21 -14
  104. package/src/schematics/form/control/select-form-control/index.js.map +1 -1
  105. package/src/schematics/form/control/select-form-control/schema.d.ts +2 -3
  106. package/src/schematics/form/control/select-form-control/schema.json +249 -90
  107. package/src/schematics/form/control/select-form-control/template.schema.json +16 -3
  108. package/src/schematics/form/control/table-select-form-control/index.d.ts +3 -9
  109. package/src/schematics/form/control/table-select-form-control/index.js +24 -18
  110. package/src/schematics/form/control/table-select-form-control/index.js.map +1 -1
  111. package/src/schematics/form/control/table-select-form-control/schema.d.ts +2 -3
  112. package/src/schematics/form/control/table-select-form-control/schema.json +325 -123
  113. package/src/schematics/form/control/table-select-form-control/template.schema.json +16 -60
  114. package/src/schematics/form/form-array/index.d.ts +9 -0
  115. package/src/schematics/form/form-array/index.js +54 -0
  116. package/src/schematics/form/form-array/index.js.map +1 -0
  117. package/src/schematics/form/form-array/schema.d.ts +4 -0
  118. package/src/schematics/form/form-array/schema.json +906 -0
  119. package/src/schematics/form/form-array/template.schema.json +33 -0
  120. package/src/schematics/form/form-component/files/component/__componentName__.component.html.hbs +4 -1
  121. package/src/schematics/form/form-component/index.d.ts +2 -4
  122. package/src/schematics/form/form-component/index.js +8 -24
  123. package/src/schematics/form/form-component/index.js.map +1 -1
  124. package/src/schematics/form/form-component/schema.d.ts +2 -2
  125. package/src/schematics/form/form-component/schema.json +749 -86
  126. package/src/schematics/form/form-control/index.d.ts +3 -5
  127. package/src/schematics/form/form-control/index.js +8 -20
  128. package/src/schematics/form/form-control/index.js.map +1 -1
  129. package/src/schematics/form/form-control/schema.d.ts +2 -4
  130. package/src/schematics/form/form-control/schema.json +599 -59
  131. package/src/schematics/form/form-control/template.schema.json +1 -2
  132. package/src/schematics/form/form-definition/index.d.ts +2 -2
  133. package/src/schematics/form/form-definition/index.js +28 -15
  134. package/src/schematics/form/form-definition/index.js.map +1 -1
  135. package/src/schematics/form/form-definition/schema.d.ts +2 -2
  136. package/src/schematics/form/form-definition/schema.json +743 -56
  137. package/src/schematics/form/form-group/index.d.ts +9 -0
  138. package/src/schematics/form/form-group/index.js +54 -0
  139. package/src/schematics/form/form-group/index.js.map +1 -0
  140. package/src/schematics/form/form-group/schema.d.ts +4 -0
  141. package/src/schematics/form/form-group/schema.json +906 -0
  142. package/src/schematics/form/form-group/template.schema.json +33 -0
  143. package/src/schematics/form/templates/checkbox-form-control.hbs +1 -1
  144. package/src/schematics/form/templates/default-form-array.hbs +27 -0
  145. package/src/schematics/form/templates/default-form-group.hbs +13 -0
  146. package/src/schematics/form/templates/input-form-control.hbs +7 -7
  147. package/src/schematics/form/templates/select-form-control.hbs +5 -0
  148. package/src/schematics/form/templates/table-select-form-control.hbs +16 -16
  149. package/src/schematics/form-array.schema.json +40 -0
  150. package/src/schematics/form-control.schema.json +69 -54
  151. package/src/schematics/form-definition.schema.json +3 -3
  152. package/src/schematics/form-group.schema.json +40 -0
  153. package/src/schematics/input-form-control.schema.json +10 -6
  154. package/src/schematics/select-form-control.schema.json +8 -4
  155. package/src/schematics/slide-toggle-form-control.schema.json +30 -0
  156. package/src/schematics/table/action/dialog-table-action/schema.json +20 -20
  157. package/src/schematics/table/action/form-table-action/index.d.ts +2 -2
  158. package/src/schematics/table/action/form-table-action/index.js +3 -4
  159. package/src/schematics/table/action/form-table-action/index.js.map +1 -1
  160. package/src/schematics/table/action/form-table-action/schema.d.ts +2 -2
  161. package/src/schematics/table/action/form-table-action/schema.json +750 -87
  162. package/src/schematics/table/action/navigation-table-action/schema.json +20 -20
  163. package/src/schematics/table/action/open-api-table-action/schema.json +20 -20
  164. package/src/schematics/table/action/operation-table-action/schema.json +20 -20
  165. package/src/schematics/table/header-button/form-table-header-button/index.d.ts +2 -2
  166. package/src/schematics/table/header-button/form-table-header-button/index.js +2 -2
  167. package/src/schematics/table/header-button/form-table-header-button/index.js.map +1 -1
  168. package/src/schematics/table/header-button/form-table-header-button/schema.d.ts +2 -2
  169. package/src/schematics/table/header-button/form-table-header-button/schema.json +818 -81
  170. package/src/schematics/table/header-button/form-table-header-button/template.schema.json +4 -22
  171. package/src/schematics/table/header-button/navigation-table-header-button/schema.json +20 -20
  172. package/src/schematics/table/table-action/schema.json +47 -47
  173. package/src/schematics/table/table-component/index.d.ts +2 -2
  174. package/src/schematics/table/table-component/schema.json +537 -79
  175. package/src/schematics/table/table-header-button/schema.json +40 -40
  176. package/src/schematics/table/tree-table-component/files/component/__componentName__.component.html.hbs +1 -1
  177. package/src/schematics/table/tree-table-component/schema.json +521 -63
  178. package/src/schematics/table-select-form-control.schema.json +96 -0
  179. package/src/schematics/textarea-form-control.schema.json +32 -0
  180. package/src/template.schema.json +45 -0
  181. package/src/lib/form-component-control.d.ts +0 -8
  182. package/src/lib/form-component-control.js +0 -15
  183. package/src/lib/form-component-control.js.map +0 -1
  184. package/src/lib/form-control.d.ts +0 -136
  185. package/src/lib/form-control.js +0 -265
  186. package/src/lib/form-control.js.map +0 -1
  187. package/src/lib/form-definition-control.d.ts +0 -5
  188. package/src/lib/form-definition-control.js +0 -30
  189. package/src/lib/form-definition-control.js.map +0 -1
@@ -10,6 +10,96 @@
10
10
  }
11
11
  ],
12
12
  "definitions": {
13
+ "abstractControl": {
14
+ "allOf": [
15
+ {
16
+ "$ref": "#/definitions/property"
17
+ },
18
+ {
19
+ "type": "object",
20
+ "properties": {
21
+ "name": {
22
+ "type": "string",
23
+ "description": "The name of the control"
24
+ },
25
+ "isArray": {
26
+ "type": "boolean",
27
+ "description": "Whether the control value is an array",
28
+ "default": false
29
+ },
30
+ "state": {
31
+ "type": "string",
32
+ "description": "The initial state of the control"
33
+ },
34
+ "isRequired": {
35
+ "type": "boolean",
36
+ "description": "Whether the control value is required",
37
+ "default": false
38
+ },
39
+ "isReadonly": {
40
+ "type": "boolean",
41
+ "description": "Whether the control value is readonly",
42
+ "default": false
43
+ },
44
+ "isDisabled": {
45
+ "type": "boolean",
46
+ "description": "Whether the control value is disabled",
47
+ "default": false
48
+ },
49
+ "validatorList": {
50
+ "type": "array",
51
+ "items": {
52
+ "type": "string"
53
+ }
54
+ },
55
+ "kind": {
56
+ "type": "string",
57
+ "description": "The kind of the control",
58
+ "default": "default"
59
+ },
60
+ "importList": {
61
+ "type": "array",
62
+ "items": {
63
+ "$ref": "#/definitions/type"
64
+ }
65
+ },
66
+ "template": {
67
+ "type": "string",
68
+ "description": "The template of the control"
69
+ },
70
+ "role": {
71
+ "type": "string",
72
+ "description": "The role of the control",
73
+ "enum": [
74
+ "control",
75
+ "group",
76
+ "array"
77
+ ],
78
+ "default": "control"
79
+ }
80
+ },
81
+ "additionalProperties": true
82
+ }
83
+ ]
84
+ },
85
+ "accordionIdentifier": {
86
+ "type": "object",
87
+ "properties": {
88
+ "property": {
89
+ "$ref": "#/definitions/property"
90
+ },
91
+ "source": {
92
+ "type": "string",
93
+ "enum": [
94
+ "route"
95
+ ],
96
+ "default": "route"
97
+ }
98
+ },
99
+ "required": [
100
+ "property"
101
+ ]
102
+ },
13
103
  "angular": {
14
104
  "allOf": [
15
105
  {
@@ -61,59 +151,86 @@
61
151
  }
62
152
  ]
63
153
  },
64
- "formComponent": {
154
+ "autocompleteTableSelectFormControl": {
65
155
  "allOf": [
66
156
  {
67
- "$ref": "#/definitions/formDefinition"
157
+ "$ref": "#/definitions/baseFormControl"
68
158
  },
69
159
  {
70
160
  "type": "object",
71
161
  "properties": {
72
- "window": {
73
- "type": "boolean",
74
- "description": "Whether the form can be opened in a window"
162
+ "formField": {
163
+ "$ref": "#/definitions/formField"
75
164
  },
76
- "role": {
165
+ "kind": {
77
166
  "type": "string",
78
- "description": "Define the role of the form"
167
+ "const": "table-select"
79
168
  },
80
- "matFormFieldDefaultOptions": {
81
- "appearance": {
82
- "type": "string",
83
- "description": "The appearance of the mat form field",
84
- "enum": [
85
- "legacy",
86
- "standard",
87
- "fill",
88
- "outline"
89
- ]
169
+ "placeholder": {
170
+ "type": "string"
171
+ },
172
+ "columnList": {
173
+ "alias": "column",
174
+ "type": "array",
175
+ "items": {
176
+ "description": "table column name",
177
+ "type": "object",
178
+ "properties": {
179
+ "name": {
180
+ "type": "string",
181
+ "description": "table column name"
182
+ },
183
+ "title": {
184
+ "type": "string",
185
+ "description": "table column label"
186
+ },
187
+ "hasFilter": {
188
+ "type": "boolean",
189
+ "description": "Whether the column has a filter"
190
+ },
191
+ "kind": {
192
+ "type": "string",
193
+ "description": "The kind of data in the column"
194
+ }
195
+ }
196
+ },
197
+ "description": "List of table column names"
198
+ },
199
+ "title": {
200
+ "type": "string",
201
+ "description": "The title of the table select window"
202
+ },
203
+ "toDisplay": {
204
+ "type": "object",
205
+ "properties": {
206
+ "property": {
207
+ "$ref": "#/definitions/property"
208
+ }
90
209
  }
91
210
  },
92
- "identifier": {
93
- "$ref": "#/definitions/accordionIdentifier"
211
+ "toValue": {
212
+ "type": "object",
213
+ "properties": {
214
+ "property": {
215
+ "$ref": "#/definitions/property"
216
+ }
217
+ }
218
+ },
219
+ "upstream": {
220
+ "$ref": "#/definitions/upstream"
221
+ },
222
+ "resolver": {
223
+ "type": "object",
224
+ "properties": {
225
+ "upstream": {
226
+ "$ref": "#/definitions/upstream"
227
+ }
228
+ }
94
229
  }
95
230
  }
96
231
  }
97
232
  ]
98
233
  },
99
- "accordionIdentifier": {
100
- "type": "object",
101
- "properties": {
102
- "property": {
103
- "$ref": "#/definitions/property"
104
- },
105
- "source": {
106
- "type": "string",
107
- "enum": [
108
- "route"
109
- ],
110
- "default": "route"
111
- }
112
- },
113
- "required": [
114
- "property"
115
- ]
116
- },
117
234
  "backend": {
118
235
  "type": "string",
119
236
  "description": "The backend that should be used to handel data",
@@ -125,66 +242,274 @@
125
242
  ],
126
243
  "default": "none"
127
244
  },
128
- "formControl": {
245
+ "baseFormArray": {
246
+ "allOf": [
247
+ {
248
+ "$ref": "#/definitions/abstractControl"
249
+ },
250
+ {
251
+ "type": "object",
252
+ "properties": {
253
+ "controlList": {
254
+ "type": "array",
255
+ "description": "The list of controls in the group",
256
+ "items": {
257
+ "$ref": "#/definitions/control"
258
+ }
259
+ },
260
+ "legend": {
261
+ "type": "string"
262
+ },
263
+ "groupLegend": {
264
+ "type": "string"
265
+ },
266
+ "kind": {
267
+ "type": "string",
268
+ "description": "The kind of the array",
269
+ "const": "default",
270
+ "default": "default"
271
+ },
272
+ "role": {
273
+ "type": "string",
274
+ "const": "array"
275
+ }
276
+ }
277
+ }
278
+ ]
279
+ },
280
+ "baseFormControl": {
281
+ "allOf": [
282
+ {
283
+ "$ref": "#/definitions/abstractControl"
284
+ },
285
+ {
286
+ "type": "object",
287
+ "properties": {
288
+ "label": {
289
+ "type": "string",
290
+ "description": "The label of the control"
291
+ },
292
+ "role": {
293
+ "type": "string",
294
+ "const": "control"
295
+ }
296
+ }
297
+ }
298
+ ]
299
+ },
300
+ "baseFormGroup": {
301
+ "allOf": [
302
+ {
303
+ "$ref": "#/definitions/abstractControl"
304
+ },
305
+ {
306
+ "type": "object",
307
+ "properties": {
308
+ "controlList": {
309
+ "type": "array",
310
+ "description": "The list of controls in the group",
311
+ "items": {
312
+ "$ref": "#/definitions/control"
313
+ }
314
+ },
315
+ "legend": {
316
+ "type": "string"
317
+ },
318
+ "kind": {
319
+ "type": "string",
320
+ "description": "The kind of the group",
321
+ "const": "default",
322
+ "default": "default"
323
+ },
324
+ "role": {
325
+ "type": "string",
326
+ "const": "group"
327
+ }
328
+ }
329
+ }
330
+ ]
331
+ },
332
+ "button": {
129
333
  "type": "object",
130
334
  "properties": {
131
- "name": {
132
- "type": "string",
133
- "description": "The name of the control"
335
+ "svgIcon": {
336
+ "type": "string"
134
337
  },
135
- "type": {
136
- "$ref": "#/definitions/type"
338
+ "icon": {
339
+ "type": "string"
137
340
  },
138
- "isArray": {
139
- "type": "boolean",
140
- "description": "Whether the control value is an array",
141
- "default": false
341
+ "directiveList": {
342
+ "type": "array",
343
+ "items": {
344
+ "$ref": "#/definitions/type"
345
+ }
142
346
  },
143
- "state": {
144
- "type": "string",
145
- "description": "The initial state of the control"
347
+ "importList": {
348
+ "type": "array",
349
+ "items": {
350
+ "$ref": "#/definitions/type"
351
+ }
352
+ }
353
+ }
354
+ },
355
+ "checkboxFormControl": {
356
+ "allOf": [
357
+ {
358
+ "$ref": "#/definitions/baseFormControl"
146
359
  },
147
- "isRequired": {
148
- "type": "boolean",
149
- "description": "Whether the control value is required",
150
- "default": false
360
+ {
361
+ "type": "object",
362
+ "properties": {
363
+ "kind": {
364
+ "type": "string",
365
+ "const": "checkbox"
366
+ },
367
+ "labelPosition": {
368
+ "type": "string",
369
+ "enum": [
370
+ "before",
371
+ "after"
372
+ ]
373
+ }
374
+ }
375
+ }
376
+ ]
377
+ },
378
+ "control": {
379
+ "oneOf": [
380
+ {
381
+ "$ref": "#/definitions/formGroup"
151
382
  },
152
- "isReadonly": {
153
- "type": "boolean",
154
- "description": "Whether the control value is readonly",
155
- "default": false
383
+ {
384
+ "$ref": "#/definitions/formArray"
156
385
  },
157
- "isDisabled": {
158
- "type": "boolean",
159
- "description": "Whether the control value is disabled",
160
- "default": false
386
+ {
387
+ "$ref": "#/definitions/formControl"
388
+ }
389
+ ]
390
+ },
391
+ "formArray": {
392
+ "allOf": [
393
+ {
394
+ "type": "object",
395
+ "properties": {
396
+ "role": {
397
+ "type": "string",
398
+ "const": "array"
399
+ }
400
+ }
161
401
  },
162
- "validatorList": {
163
- "type": "array",
164
- "items": {
165
- "type": "string"
402
+ {
403
+ "oneOf": [
404
+ {
405
+ "allOf": [
406
+ {
407
+ "$ref": "#/definitions/baseFormArray"
408
+ },
409
+ {
410
+ "type": "object",
411
+ "properties": {
412
+ "kind": {
413
+ "type": "string",
414
+ "const": "default"
415
+ }
416
+ }
417
+ }
418
+ ]
419
+ }
420
+ ]
421
+ }
422
+ ]
423
+ },
424
+ "formComponent": {
425
+ "allOf": [
426
+ {
427
+ "$ref": "#/definitions/formDefinition"
428
+ },
429
+ {
430
+ "type": "object",
431
+ "properties": {
432
+ "window": {
433
+ "type": "boolean",
434
+ "description": "Whether the form can be opened in a window"
435
+ },
436
+ "role": {
437
+ "type": "string",
438
+ "description": "Define the role of the form"
439
+ },
440
+ "matFormFieldDefaultOptions": {
441
+ "appearance": {
442
+ "type": "string",
443
+ "description": "The appearance of the mat form field",
444
+ "enum": [
445
+ "legacy",
446
+ "standard",
447
+ "fill",
448
+ "outline"
449
+ ]
450
+ }
451
+ },
452
+ "identifier": {
453
+ "$ref": "#/definitions/accordionIdentifier"
454
+ }
455
+ }
456
+ }
457
+ ]
458
+ },
459
+ "formControl": {
460
+ "allOf": [
461
+ {
462
+ "type": "object",
463
+ "properties": {
464
+ "role": {
465
+ "type": "string",
466
+ "const": "control",
467
+ "default": "control"
468
+ }
166
469
  }
167
470
  },
168
- "kind": {
169
- "type": "string",
170
- "description": "The name of the template",
171
- "enum": [
172
- "default",
173
- "input",
174
- "select",
175
- "checkbox",
176
- "autocomplete-table-select",
177
- "table-select",
178
- "textarea",
179
- "slide-toggle"
180
- ],
181
- "default": "default"
471
+ {
472
+ "oneOf": [
473
+ {
474
+ "allOf": [
475
+ {
476
+ "$ref": "#/definitions/baseFormControl"
477
+ },
478
+ {
479
+ "type": "object",
480
+ "properties": {
481
+ "kind": {
482
+ "type": "string",
483
+ "const": "default"
484
+ }
485
+ }
486
+ }
487
+ ]
488
+ },
489
+ {
490
+ "$ref": "#/definitions/inputFormControl"
491
+ },
492
+ {
493
+ "$ref": "#/definitions/selectFormControl"
494
+ },
495
+ {
496
+ "$ref": "#/definitions/checkboxFormControl"
497
+ },
498
+ {
499
+ "$ref": "#/definitions/textareaFormControl"
500
+ },
501
+ {
502
+ "$ref": "#/definitions/tableSelectFormControl"
503
+ },
504
+ {
505
+ "$ref": "#/definitions/slideToggleFormControl"
506
+ },
507
+ {
508
+ "$ref": "#/definitions/autocompleteTableSelectFormControl"
509
+ }
510
+ ]
182
511
  }
183
- },
184
- "required": [
185
- "name"
186
- ],
187
- "additionalProperties": true
512
+ ]
188
513
  },
189
514
  "formDefinition": {
190
515
  "type": "object",
@@ -193,7 +518,7 @@
193
518
  "alias": "control",
194
519
  "type": "array",
195
520
  "items": {
196
- "$ref": "#/definitions/formControl"
521
+ "$ref": "#/definitions/control"
197
522
  }
198
523
  }
199
524
  },
@@ -201,6 +526,56 @@
201
526
  "controlList"
202
527
  ]
203
528
  },
529
+ "formField": {
530
+ "type": "object",
531
+ "properties": {
532
+ "label": {
533
+ "type": "string"
534
+ },
535
+ "prefixButton": {
536
+ "$ref": "#/definitions/button"
537
+ },
538
+ "suffixButton": {
539
+ "$ref": "#/definitions/button"
540
+ },
541
+ "hasClearButton": {
542
+ "type": "boolean"
543
+ }
544
+ }
545
+ },
546
+ "formGroup": {
547
+ "allOf": [
548
+ {
549
+ "type": "object",
550
+ "properties": {
551
+ "role": {
552
+ "type": "string",
553
+ "const": "group"
554
+ }
555
+ }
556
+ },
557
+ {
558
+ "oneOf": [
559
+ {
560
+ "allOf": [
561
+ {
562
+ "$ref": "#/definitions/baseFormGroup"
563
+ },
564
+ {
565
+ "type": "object",
566
+ "properties": {
567
+ "kind": {
568
+ "type": "string",
569
+ "const": "default"
570
+ }
571
+ }
572
+ }
573
+ ]
574
+ }
575
+ ]
576
+ }
577
+ ]
578
+ },
204
579
  "general": {
205
580
  "type": "object",
206
581
  "properties": {
@@ -237,6 +612,55 @@
237
612
  }
238
613
  }
239
614
  },
615
+ "inputFormControl": {
616
+ "allOf": [
617
+ {
618
+ "$ref": "#/definitions/baseFormControl"
619
+ },
620
+ {
621
+ "type": "object",
622
+ "properties": {
623
+ "kind": {
624
+ "type": "string",
625
+ "const": "input"
626
+ },
627
+ "formField": {
628
+ "$ref": "#/definitions/formField"
629
+ },
630
+ "inputType": {
631
+ "type": "string",
632
+ "enum": [
633
+ "text",
634
+ "password",
635
+ "email",
636
+ "number",
637
+ "tel",
638
+ "url",
639
+ "checkbox",
640
+ "color",
641
+ "date",
642
+ "time",
643
+ "datetime-local",
644
+ "file",
645
+ "hidden",
646
+ "image",
647
+ "month",
648
+ "radio",
649
+ "reset",
650
+ "button",
651
+ "search",
652
+ "submit",
653
+ "week",
654
+ "range"
655
+ ]
656
+ },
657
+ "placeholder": {
658
+ "type": "string"
659
+ }
660
+ }
661
+ }
662
+ ]
663
+ },
240
664
  "property": {
241
665
  "oneOf": [
242
666
  {
@@ -261,6 +685,186 @@
261
685
  }
262
686
  ]
263
687
  },
688
+ "selectFormControl": {
689
+ "allOf": [
690
+ {
691
+ "$ref": "#/definitions/baseFormControl"
692
+ },
693
+ {
694
+ "type": "object",
695
+ "properties": {
696
+ "formField": {
697
+ "$ref": "#/definitions/formField"
698
+ },
699
+ "kind": {
700
+ "type": "string",
701
+ "const": "select"
702
+ },
703
+ "optionList": {
704
+ "type": "array",
705
+ "items": {
706
+ "type": "object",
707
+ "properties": {
708
+ "display": {
709
+ "type": "string"
710
+ },
711
+ "value": {
712
+ "oneOf": [
713
+ {
714
+ "type": "string"
715
+ },
716
+ {
717
+ "type": "number"
718
+ },
719
+ {
720
+ "type": "boolean"
721
+ },
722
+ {
723
+ "type": "object",
724
+ "additionalProperties": true
725
+ }
726
+ ]
727
+ }
728
+ }
729
+ }
730
+ },
731
+ "backend": {
732
+ "$ref": "#/definitions/backend"
733
+ },
734
+ "multiple": {
735
+ "alias": "multi",
736
+ "type": "boolean",
737
+ "description": "Whether the select form control is multiple mode"
738
+ }
739
+ }
740
+ }
741
+ ]
742
+ },
743
+ "slideToggleFormControl": {
744
+ "allOf": [
745
+ {
746
+ "$ref": "#/definitions/baseFormControl"
747
+ },
748
+ {
749
+ "type": "object",
750
+ "properties": {
751
+ "kind": {
752
+ "type": "string",
753
+ "const": "slide-toggle"
754
+ },
755
+ "labelPosition": {
756
+ "type": "string",
757
+ "enum": [
758
+ "before",
759
+ "after"
760
+ ]
761
+ }
762
+ }
763
+ }
764
+ ]
765
+ },
766
+ "tableSelectFormControl": {
767
+ "allOf": [
768
+ {
769
+ "$ref": "#/definitions/baseFormControl"
770
+ },
771
+ {
772
+ "type": "object",
773
+ "properties": {
774
+ "formField": {
775
+ "$ref": "#/definitions/formField"
776
+ },
777
+ "kind": {
778
+ "type": "string",
779
+ "const": "table-select"
780
+ },
781
+ "placeholder": {
782
+ "type": "string"
783
+ },
784
+ "columnList": {
785
+ "alias": "column",
786
+ "type": "array",
787
+ "items": {
788
+ "description": "table column name",
789
+ "type": "object",
790
+ "properties": {
791
+ "name": {
792
+ "type": "string",
793
+ "description": "table column name"
794
+ },
795
+ "title": {
796
+ "type": "string",
797
+ "description": "table column label"
798
+ },
799
+ "hasFilter": {
800
+ "type": "boolean",
801
+ "description": "Whether the column has a filter"
802
+ },
803
+ "kind": {
804
+ "type": "string",
805
+ "description": "The kind of data in the column"
806
+ }
807
+ }
808
+ },
809
+ "description": "List of table column names"
810
+ },
811
+ "title": {
812
+ "type": "string",
813
+ "description": "The title of the table select window"
814
+ },
815
+ "toDisplay": {
816
+ "type": "object",
817
+ "properties": {
818
+ "property": {
819
+ "$ref": "#/definitions/property"
820
+ }
821
+ }
822
+ },
823
+ "toValue": {
824
+ "type": "object",
825
+ "properties": {
826
+ "property": {
827
+ "$ref": "#/definitions/property"
828
+ }
829
+ }
830
+ },
831
+ "upstream": {
832
+ "$ref": "#/definitions/upstream"
833
+ },
834
+ "resolver": {
835
+ "type": "object",
836
+ "properties": {
837
+ "upstream": {
838
+ "$ref": "#/definitions/upstream"
839
+ }
840
+ }
841
+ }
842
+ }
843
+ }
844
+ ]
845
+ },
846
+ "textareaFormControl": {
847
+ "allOf": [
848
+ {
849
+ "$ref": "#/definitions/baseFormControl"
850
+ },
851
+ {
852
+ "type": "object",
853
+ "properties": {
854
+ "formField": {
855
+ "$ref": "#/definitions/formField"
856
+ },
857
+ "kind": {
858
+ "type": "string",
859
+ "const": "textarea"
860
+ },
861
+ "placeholder": {
862
+ "type": "string"
863
+ }
864
+ }
865
+ }
866
+ ]
867
+ },
264
868
  "type": {
265
869
  "oneOf": [
266
870
  {
@@ -293,6 +897,65 @@
293
897
  ]
294
898
  }
295
899
  ]
900
+ },
901
+ "upstream": {
902
+ "oneOf": [
903
+ {
904
+ "type": "object",
905
+ "properties": {
906
+ "kind": {
907
+ "type": "string",
908
+ "enum": [
909
+ "open-api"
910
+ ]
911
+ },
912
+ "operationId": {
913
+ "type": "string"
914
+ },
915
+ "scope": {
916
+ "type": "string"
917
+ },
918
+ "mapper": {
919
+ "type": "object",
920
+ "properties": {
921
+ "pageIndex": {
922
+ "type": "string"
923
+ },
924
+ "pageSize": {
925
+ "type": "string"
926
+ },
927
+ "sortBy": {
928
+ "type": "string"
929
+ },
930
+ "sortDirection": {
931
+ "type": "string"
932
+ },
933
+ "list": {
934
+ "type": "string"
935
+ },
936
+ "total": {
937
+ "type": "string"
938
+ },
939
+ "filter": {
940
+ "type": "object",
941
+ "properties": {
942
+ "eq": {
943
+ "type": "string"
944
+ },
945
+ "join": {
946
+ "type": "string"
947
+ }
948
+ }
949
+ }
950
+ }
951
+ }
952
+ },
953
+ "required": [
954
+ "kind",
955
+ "operationId"
956
+ ]
957
+ }
958
+ ]
296
959
  }
297
960
  }
298
961
  }