@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
@@ -65,58 +65,75 @@
65
65
  }
66
66
  ],
67
67
  "definitions": {
68
- "formComponent": {
68
+ "abstractControl": {
69
69
  "allOf": [
70
70
  {
71
- "$ref": "#/definitions/formDefinition"
71
+ "$ref": "#/definitions/property"
72
72
  },
73
73
  {
74
74
  "type": "object",
75
75
  "properties": {
76
- "window": {
76
+ "name": {
77
+ "type": "string",
78
+ "description": "The name of the control"
79
+ },
80
+ "isArray": {
77
81
  "type": "boolean",
78
- "description": "Whether the form can be opened in a window"
82
+ "description": "Whether the control value is an array",
83
+ "default": false
79
84
  },
80
- "role": {
85
+ "state": {
81
86
  "type": "string",
82
- "description": "Define the role of the form"
87
+ "description": "The initial state of the control"
83
88
  },
84
- "matFormFieldDefaultOptions": {
85
- "appearance": {
86
- "type": "string",
87
- "description": "The appearance of the mat form field",
88
- "enum": [
89
- "legacy",
90
- "standard",
91
- "fill",
92
- "outline"
93
- ]
89
+ "isRequired": {
90
+ "type": "boolean",
91
+ "description": "Whether the control value is required",
92
+ "default": false
93
+ },
94
+ "isReadonly": {
95
+ "type": "boolean",
96
+ "description": "Whether the control value is readonly",
97
+ "default": false
98
+ },
99
+ "isDisabled": {
100
+ "type": "boolean",
101
+ "description": "Whether the control value is disabled",
102
+ "default": false
103
+ },
104
+ "validatorList": {
105
+ "type": "array",
106
+ "items": {
107
+ "type": "string"
94
108
  }
95
109
  },
96
- "identifier": {
97
- "$ref": "#/definitions/accordionIdentifier"
98
- }
99
- }
100
- }
101
- ]
102
- },
103
- "tableActionSchematic": {
104
- "allOf": [
105
- {
106
- "$ref": "#/definitions/angular"
107
- },
108
- {
109
- "$ref": "#/definitions/tableAction"
110
- },
111
- {
112
- "type": "object",
113
- "properties": {
114
- "tableName": {
115
- "alias": "table",
110
+ "kind": {
116
111
  "type": "string",
117
- "description": "The name of the table action"
112
+ "description": "The kind of the control",
113
+ "default": "default"
114
+ },
115
+ "importList": {
116
+ "type": "array",
117
+ "items": {
118
+ "$ref": "#/definitions/type"
119
+ }
120
+ },
121
+ "template": {
122
+ "type": "string",
123
+ "description": "The template of the control"
124
+ },
125
+ "role": {
126
+ "type": "string",
127
+ "description": "The role of the control",
128
+ "enum": [
129
+ "control",
130
+ "group",
131
+ "array"
132
+ ],
133
+ "default": "control"
118
134
  }
119
- }
135
+ },
136
+ "additionalProperties": true
120
137
  }
121
138
  ]
122
139
  },
@@ -189,6 +206,86 @@
189
206
  }
190
207
  ]
191
208
  },
209
+ "autocompleteTableSelectFormControl": {
210
+ "allOf": [
211
+ {
212
+ "$ref": "#/definitions/baseFormControl"
213
+ },
214
+ {
215
+ "type": "object",
216
+ "properties": {
217
+ "formField": {
218
+ "$ref": "#/definitions/formField"
219
+ },
220
+ "kind": {
221
+ "type": "string",
222
+ "const": "table-select"
223
+ },
224
+ "placeholder": {
225
+ "type": "string"
226
+ },
227
+ "columnList": {
228
+ "alias": "column",
229
+ "type": "array",
230
+ "items": {
231
+ "description": "table column name",
232
+ "type": "object",
233
+ "properties": {
234
+ "name": {
235
+ "type": "string",
236
+ "description": "table column name"
237
+ },
238
+ "title": {
239
+ "type": "string",
240
+ "description": "table column label"
241
+ },
242
+ "hasFilter": {
243
+ "type": "boolean",
244
+ "description": "Whether the column has a filter"
245
+ },
246
+ "kind": {
247
+ "type": "string",
248
+ "description": "The kind of data in the column"
249
+ }
250
+ }
251
+ },
252
+ "description": "List of table column names"
253
+ },
254
+ "title": {
255
+ "type": "string",
256
+ "description": "The title of the table select window"
257
+ },
258
+ "toDisplay": {
259
+ "type": "object",
260
+ "properties": {
261
+ "property": {
262
+ "$ref": "#/definitions/property"
263
+ }
264
+ }
265
+ },
266
+ "toValue": {
267
+ "type": "object",
268
+ "properties": {
269
+ "property": {
270
+ "$ref": "#/definitions/property"
271
+ }
272
+ }
273
+ },
274
+ "upstream": {
275
+ "$ref": "#/definitions/upstream"
276
+ },
277
+ "resolver": {
278
+ "type": "object",
279
+ "properties": {
280
+ "upstream": {
281
+ "$ref": "#/definitions/upstream"
282
+ }
283
+ }
284
+ }
285
+ }
286
+ }
287
+ ]
288
+ },
192
289
  "backend": {
193
290
  "type": "string",
194
291
  "description": "The backend that should be used to handel data",
@@ -200,66 +297,274 @@
200
297
  ],
201
298
  "default": "none"
202
299
  },
203
- "formControl": {
300
+ "baseFormArray": {
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
+ "groupLegend": {
319
+ "type": "string"
320
+ },
321
+ "kind": {
322
+ "type": "string",
323
+ "description": "The kind of the array",
324
+ "const": "default",
325
+ "default": "default"
326
+ },
327
+ "role": {
328
+ "type": "string",
329
+ "const": "array"
330
+ }
331
+ }
332
+ }
333
+ ]
334
+ },
335
+ "baseFormControl": {
336
+ "allOf": [
337
+ {
338
+ "$ref": "#/definitions/abstractControl"
339
+ },
340
+ {
341
+ "type": "object",
342
+ "properties": {
343
+ "label": {
344
+ "type": "string",
345
+ "description": "The label of the control"
346
+ },
347
+ "role": {
348
+ "type": "string",
349
+ "const": "control"
350
+ }
351
+ }
352
+ }
353
+ ]
354
+ },
355
+ "baseFormGroup": {
356
+ "allOf": [
357
+ {
358
+ "$ref": "#/definitions/abstractControl"
359
+ },
360
+ {
361
+ "type": "object",
362
+ "properties": {
363
+ "controlList": {
364
+ "type": "array",
365
+ "description": "The list of controls in the group",
366
+ "items": {
367
+ "$ref": "#/definitions/control"
368
+ }
369
+ },
370
+ "legend": {
371
+ "type": "string"
372
+ },
373
+ "kind": {
374
+ "type": "string",
375
+ "description": "The kind of the group",
376
+ "const": "default",
377
+ "default": "default"
378
+ },
379
+ "role": {
380
+ "type": "string",
381
+ "const": "group"
382
+ }
383
+ }
384
+ }
385
+ ]
386
+ },
387
+ "button": {
204
388
  "type": "object",
205
389
  "properties": {
206
- "name": {
207
- "type": "string",
208
- "description": "The name of the control"
390
+ "svgIcon": {
391
+ "type": "string"
209
392
  },
210
- "type": {
211
- "$ref": "#/definitions/type"
393
+ "icon": {
394
+ "type": "string"
212
395
  },
213
- "isArray": {
214
- "type": "boolean",
215
- "description": "Whether the control value is an array",
216
- "default": false
396
+ "directiveList": {
397
+ "type": "array",
398
+ "items": {
399
+ "$ref": "#/definitions/type"
400
+ }
217
401
  },
218
- "state": {
219
- "type": "string",
220
- "description": "The initial state of the control"
402
+ "importList": {
403
+ "type": "array",
404
+ "items": {
405
+ "$ref": "#/definitions/type"
406
+ }
407
+ }
408
+ }
409
+ },
410
+ "checkboxFormControl": {
411
+ "allOf": [
412
+ {
413
+ "$ref": "#/definitions/baseFormControl"
221
414
  },
222
- "isRequired": {
223
- "type": "boolean",
224
- "description": "Whether the control value is required",
225
- "default": false
415
+ {
416
+ "type": "object",
417
+ "properties": {
418
+ "kind": {
419
+ "type": "string",
420
+ "const": "checkbox"
421
+ },
422
+ "labelPosition": {
423
+ "type": "string",
424
+ "enum": [
425
+ "before",
426
+ "after"
427
+ ]
428
+ }
429
+ }
430
+ }
431
+ ]
432
+ },
433
+ "control": {
434
+ "oneOf": [
435
+ {
436
+ "$ref": "#/definitions/formGroup"
226
437
  },
227
- "isReadonly": {
228
- "type": "boolean",
229
- "description": "Whether the control value is readonly",
230
- "default": false
438
+ {
439
+ "$ref": "#/definitions/formArray"
231
440
  },
232
- "isDisabled": {
233
- "type": "boolean",
234
- "description": "Whether the control value is disabled",
235
- "default": false
441
+ {
442
+ "$ref": "#/definitions/formControl"
443
+ }
444
+ ]
445
+ },
446
+ "formArray": {
447
+ "allOf": [
448
+ {
449
+ "type": "object",
450
+ "properties": {
451
+ "role": {
452
+ "type": "string",
453
+ "const": "array"
454
+ }
455
+ }
236
456
  },
237
- "validatorList": {
238
- "type": "array",
239
- "items": {
240
- "type": "string"
457
+ {
458
+ "oneOf": [
459
+ {
460
+ "allOf": [
461
+ {
462
+ "$ref": "#/definitions/baseFormArray"
463
+ },
464
+ {
465
+ "type": "object",
466
+ "properties": {
467
+ "kind": {
468
+ "type": "string",
469
+ "const": "default"
470
+ }
471
+ }
472
+ }
473
+ ]
474
+ }
475
+ ]
476
+ }
477
+ ]
478
+ },
479
+ "formComponent": {
480
+ "allOf": [
481
+ {
482
+ "$ref": "#/definitions/formDefinition"
483
+ },
484
+ {
485
+ "type": "object",
486
+ "properties": {
487
+ "window": {
488
+ "type": "boolean",
489
+ "description": "Whether the form can be opened in a window"
490
+ },
491
+ "role": {
492
+ "type": "string",
493
+ "description": "Define the role of the form"
494
+ },
495
+ "matFormFieldDefaultOptions": {
496
+ "appearance": {
497
+ "type": "string",
498
+ "description": "The appearance of the mat form field",
499
+ "enum": [
500
+ "legacy",
501
+ "standard",
502
+ "fill",
503
+ "outline"
504
+ ]
505
+ }
506
+ },
507
+ "identifier": {
508
+ "$ref": "#/definitions/accordionIdentifier"
509
+ }
510
+ }
511
+ }
512
+ ]
513
+ },
514
+ "formControl": {
515
+ "allOf": [
516
+ {
517
+ "type": "object",
518
+ "properties": {
519
+ "role": {
520
+ "type": "string",
521
+ "const": "control",
522
+ "default": "control"
523
+ }
241
524
  }
242
525
  },
243
- "kind": {
244
- "type": "string",
245
- "description": "The name of the template",
246
- "enum": [
247
- "default",
248
- "input",
249
- "select",
250
- "checkbox",
251
- "autocomplete-table-select",
252
- "table-select",
253
- "textarea",
254
- "slide-toggle"
255
- ],
256
- "default": "default"
526
+ {
527
+ "oneOf": [
528
+ {
529
+ "allOf": [
530
+ {
531
+ "$ref": "#/definitions/baseFormControl"
532
+ },
533
+ {
534
+ "type": "object",
535
+ "properties": {
536
+ "kind": {
537
+ "type": "string",
538
+ "const": "default"
539
+ }
540
+ }
541
+ }
542
+ ]
543
+ },
544
+ {
545
+ "$ref": "#/definitions/inputFormControl"
546
+ },
547
+ {
548
+ "$ref": "#/definitions/selectFormControl"
549
+ },
550
+ {
551
+ "$ref": "#/definitions/checkboxFormControl"
552
+ },
553
+ {
554
+ "$ref": "#/definitions/textareaFormControl"
555
+ },
556
+ {
557
+ "$ref": "#/definitions/tableSelectFormControl"
558
+ },
559
+ {
560
+ "$ref": "#/definitions/slideToggleFormControl"
561
+ },
562
+ {
563
+ "$ref": "#/definitions/autocompleteTableSelectFormControl"
564
+ }
565
+ ]
257
566
  }
258
- },
259
- "required": [
260
- "name"
261
- ],
262
- "additionalProperties": true
567
+ ]
263
568
  },
264
569
  "formDefinition": {
265
570
  "type": "object",
@@ -268,7 +573,7 @@
268
573
  "alias": "control",
269
574
  "type": "array",
270
575
  "items": {
271
- "$ref": "#/definitions/formControl"
576
+ "$ref": "#/definitions/control"
272
577
  }
273
578
  }
274
579
  },
@@ -276,6 +581,56 @@
276
581
  "controlList"
277
582
  ]
278
583
  },
584
+ "formField": {
585
+ "type": "object",
586
+ "properties": {
587
+ "label": {
588
+ "type": "string"
589
+ },
590
+ "prefixButton": {
591
+ "$ref": "#/definitions/button"
592
+ },
593
+ "suffixButton": {
594
+ "$ref": "#/definitions/button"
595
+ },
596
+ "hasClearButton": {
597
+ "type": "boolean"
598
+ }
599
+ }
600
+ },
601
+ "formGroup": {
602
+ "allOf": [
603
+ {
604
+ "type": "object",
605
+ "properties": {
606
+ "role": {
607
+ "type": "string",
608
+ "const": "group"
609
+ }
610
+ }
611
+ },
612
+ {
613
+ "oneOf": [
614
+ {
615
+ "allOf": [
616
+ {
617
+ "$ref": "#/definitions/baseFormGroup"
618
+ },
619
+ {
620
+ "type": "object",
621
+ "properties": {
622
+ "kind": {
623
+ "type": "string",
624
+ "const": "default"
625
+ }
626
+ }
627
+ }
628
+ ]
629
+ }
630
+ ]
631
+ }
632
+ ]
633
+ },
279
634
  "general": {
280
635
  "type": "object",
281
636
  "properties": {
@@ -312,6 +667,55 @@
312
667
  }
313
668
  }
314
669
  },
670
+ "inputFormControl": {
671
+ "allOf": [
672
+ {
673
+ "$ref": "#/definitions/baseFormControl"
674
+ },
675
+ {
676
+ "type": "object",
677
+ "properties": {
678
+ "kind": {
679
+ "type": "string",
680
+ "const": "input"
681
+ },
682
+ "formField": {
683
+ "$ref": "#/definitions/formField"
684
+ },
685
+ "inputType": {
686
+ "type": "string",
687
+ "enum": [
688
+ "text",
689
+ "password",
690
+ "email",
691
+ "number",
692
+ "tel",
693
+ "url",
694
+ "checkbox",
695
+ "color",
696
+ "date",
697
+ "time",
698
+ "datetime-local",
699
+ "file",
700
+ "hidden",
701
+ "image",
702
+ "month",
703
+ "radio",
704
+ "reset",
705
+ "button",
706
+ "search",
707
+ "submit",
708
+ "week",
709
+ "range"
710
+ ]
711
+ },
712
+ "placeholder": {
713
+ "type": "string"
714
+ }
715
+ }
716
+ }
717
+ ]
718
+ },
315
719
  "property": {
316
720
  "oneOf": [
317
721
  {
@@ -336,6 +740,84 @@
336
740
  }
337
741
  ]
338
742
  },
743
+ "selectFormControl": {
744
+ "allOf": [
745
+ {
746
+ "$ref": "#/definitions/baseFormControl"
747
+ },
748
+ {
749
+ "type": "object",
750
+ "properties": {
751
+ "formField": {
752
+ "$ref": "#/definitions/formField"
753
+ },
754
+ "kind": {
755
+ "type": "string",
756
+ "const": "select"
757
+ },
758
+ "optionList": {
759
+ "type": "array",
760
+ "items": {
761
+ "type": "object",
762
+ "properties": {
763
+ "display": {
764
+ "type": "string"
765
+ },
766
+ "value": {
767
+ "oneOf": [
768
+ {
769
+ "type": "string"
770
+ },
771
+ {
772
+ "type": "number"
773
+ },
774
+ {
775
+ "type": "boolean"
776
+ },
777
+ {
778
+ "type": "object",
779
+ "additionalProperties": true
780
+ }
781
+ ]
782
+ }
783
+ }
784
+ }
785
+ },
786
+ "backend": {
787
+ "$ref": "#/definitions/backend"
788
+ },
789
+ "multiple": {
790
+ "alias": "multi",
791
+ "type": "boolean",
792
+ "description": "Whether the select form control is multiple mode"
793
+ }
794
+ }
795
+ }
796
+ ]
797
+ },
798
+ "slideToggleFormControl": {
799
+ "allOf": [
800
+ {
801
+ "$ref": "#/definitions/baseFormControl"
802
+ },
803
+ {
804
+ "type": "object",
805
+ "properties": {
806
+ "kind": {
807
+ "type": "string",
808
+ "const": "slide-toggle"
809
+ },
810
+ "labelPosition": {
811
+ "type": "string",
812
+ "enum": [
813
+ "before",
814
+ "after"
815
+ ]
816
+ }
817
+ }
818
+ }
819
+ ]
820
+ },
339
821
  "tableAction": {
340
822
  "type": "object",
341
823
  "properties": {
@@ -395,6 +877,128 @@
395
877
  "type"
396
878
  ]
397
879
  },
880
+ "tableActionSchematic": {
881
+ "allOf": [
882
+ {
883
+ "$ref": "#/definitions/angular"
884
+ },
885
+ {
886
+ "$ref": "#/definitions/tableAction"
887
+ },
888
+ {
889
+ "type": "object",
890
+ "properties": {
891
+ "tableName": {
892
+ "alias": "table",
893
+ "type": "string",
894
+ "description": "The name of the table action"
895
+ }
896
+ }
897
+ }
898
+ ]
899
+ },
900
+ "tableSelectFormControl": {
901
+ "allOf": [
902
+ {
903
+ "$ref": "#/definitions/baseFormControl"
904
+ },
905
+ {
906
+ "type": "object",
907
+ "properties": {
908
+ "formField": {
909
+ "$ref": "#/definitions/formField"
910
+ },
911
+ "kind": {
912
+ "type": "string",
913
+ "const": "table-select"
914
+ },
915
+ "placeholder": {
916
+ "type": "string"
917
+ },
918
+ "columnList": {
919
+ "alias": "column",
920
+ "type": "array",
921
+ "items": {
922
+ "description": "table column name",
923
+ "type": "object",
924
+ "properties": {
925
+ "name": {
926
+ "type": "string",
927
+ "description": "table column name"
928
+ },
929
+ "title": {
930
+ "type": "string",
931
+ "description": "table column label"
932
+ },
933
+ "hasFilter": {
934
+ "type": "boolean",
935
+ "description": "Whether the column has a filter"
936
+ },
937
+ "kind": {
938
+ "type": "string",
939
+ "description": "The kind of data in the column"
940
+ }
941
+ }
942
+ },
943
+ "description": "List of table column names"
944
+ },
945
+ "title": {
946
+ "type": "string",
947
+ "description": "The title of the table select window"
948
+ },
949
+ "toDisplay": {
950
+ "type": "object",
951
+ "properties": {
952
+ "property": {
953
+ "$ref": "#/definitions/property"
954
+ }
955
+ }
956
+ },
957
+ "toValue": {
958
+ "type": "object",
959
+ "properties": {
960
+ "property": {
961
+ "$ref": "#/definitions/property"
962
+ }
963
+ }
964
+ },
965
+ "upstream": {
966
+ "$ref": "#/definitions/upstream"
967
+ },
968
+ "resolver": {
969
+ "type": "object",
970
+ "properties": {
971
+ "upstream": {
972
+ "$ref": "#/definitions/upstream"
973
+ }
974
+ }
975
+ }
976
+ }
977
+ }
978
+ ]
979
+ },
980
+ "textareaFormControl": {
981
+ "allOf": [
982
+ {
983
+ "$ref": "#/definitions/baseFormControl"
984
+ },
985
+ {
986
+ "type": "object",
987
+ "properties": {
988
+ "formField": {
989
+ "$ref": "#/definitions/formField"
990
+ },
991
+ "kind": {
992
+ "type": "string",
993
+ "const": "textarea"
994
+ },
995
+ "placeholder": {
996
+ "type": "string"
997
+ }
998
+ }
999
+ }
1000
+ ]
1001
+ },
398
1002
  "type": {
399
1003
  "oneOf": [
400
1004
  {
@@ -427,6 +1031,65 @@
427
1031
  ]
428
1032
  }
429
1033
  ]
1034
+ },
1035
+ "upstream": {
1036
+ "oneOf": [
1037
+ {
1038
+ "type": "object",
1039
+ "properties": {
1040
+ "kind": {
1041
+ "type": "string",
1042
+ "enum": [
1043
+ "open-api"
1044
+ ]
1045
+ },
1046
+ "operationId": {
1047
+ "type": "string"
1048
+ },
1049
+ "scope": {
1050
+ "type": "string"
1051
+ },
1052
+ "mapper": {
1053
+ "type": "object",
1054
+ "properties": {
1055
+ "pageIndex": {
1056
+ "type": "string"
1057
+ },
1058
+ "pageSize": {
1059
+ "type": "string"
1060
+ },
1061
+ "sortBy": {
1062
+ "type": "string"
1063
+ },
1064
+ "sortDirection": {
1065
+ "type": "string"
1066
+ },
1067
+ "list": {
1068
+ "type": "string"
1069
+ },
1070
+ "total": {
1071
+ "type": "string"
1072
+ },
1073
+ "filter": {
1074
+ "type": "object",
1075
+ "properties": {
1076
+ "eq": {
1077
+ "type": "string"
1078
+ },
1079
+ "join": {
1080
+ "type": "string"
1081
+ }
1082
+ }
1083
+ }
1084
+ }
1085
+ }
1086
+ },
1087
+ "required": [
1088
+ "kind",
1089
+ "operationId"
1090
+ ]
1091
+ }
1092
+ ]
430
1093
  }
431
1094
  }
432
1095
  }