@rxap/schematic-angular 16.2.0-dev.14 → 16.2.0-dev.16

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 (135) hide show
  1. package/CHANGELOG.md +27 -0
  2. package/README.md +1 -1
  3. package/package.json +8 -8
  4. package/src/lib/accordion-identifier.d.ts +4 -0
  5. package/src/lib/accordion-identifier.js.map +1 -1
  6. package/src/lib/accordion-item.d.ts +13 -6
  7. package/src/lib/accordion-item.js +19 -4
  8. package/src/lib/accordion-item.js.map +1 -1
  9. package/src/lib/coerce-accordion-component.js +1 -1
  10. package/src/lib/coerce-accordion-component.js.map +1 -1
  11. package/src/lib/coerce-accordion-item-table-component.js +1 -1
  12. package/src/lib/coerce-accordion-item-table-component.js.map +1 -1
  13. package/src/lib/data-grid-options.d.ts +9 -1
  14. package/src/lib/data-grid-options.js +36 -6
  15. package/src/lib/data-grid-options.js.map +1 -1
  16. package/src/lib/form-control.d.ts +9 -3
  17. package/src/lib/form-control.js +19 -54
  18. package/src/lib/form-control.js.map +1 -1
  19. package/src/lib/merge-with-column-list.js +3 -1
  20. package/src/lib/merge-with-column-list.js.map +1 -1
  21. package/src/lib/minimum-table-component-options.js +2 -2
  22. package/src/lib/minimum-table-component-options.js.map +1 -1
  23. package/src/lib/pipe-option.js +0 -2
  24. package/src/lib/pipe-option.js.map +1 -1
  25. package/src/lib/table-column.d.ts +9 -5
  26. package/src/lib/table-column.js +36 -60
  27. package/src/lib/table-column.js.map +1 -1
  28. package/src/schema.json +2368 -0
  29. package/src/schematic-input.schema.json +607 -0
  30. package/src/schematics/accordion/accordion-component/index.d.ts +5 -2
  31. package/src/schematics/accordion/accordion-component/index.js +51 -25
  32. package/src/schematics/accordion/accordion-component/index.js.map +1 -1
  33. package/src/schematics/accordion/accordion-component/schema.d.ts +6 -0
  34. package/src/schematics/accordion/accordion-component/schema.json +183 -360
  35. package/src/schematics/accordion/accordion-component/template.schema.json +22 -25
  36. package/src/schematics/accordion/accordion-item-component/index.d.ts +7 -2
  37. package/src/schematics/accordion/accordion-item-component/index.js +70 -49
  38. package/src/schematics/accordion/accordion-item-component/index.js.map +1 -1
  39. package/src/schematics/accordion/accordion-item-component/schema.json +167 -336
  40. package/src/schematics/accordion/accordion-item-component/template.schema.json +8 -15
  41. package/src/schematics/accordion/item/accordion-item-data-grid-component/index.d.ts +1 -1
  42. package/src/schematics/accordion/item/accordion-item-data-grid-component/index.js +21 -25
  43. package/src/schematics/accordion/item/accordion-item-data-grid-component/index.js.map +1 -1
  44. package/src/schematics/accordion/item/accordion-item-data-grid-component/schema.json +331 -429
  45. package/src/schematics/accordion/item/accordion-item-data-grid-component/template.schema.json +9 -15
  46. package/src/schematics/accordion/item/accordion-item-switch-component/index.d.ts +1 -1
  47. package/src/schematics/accordion/item/accordion-item-switch-component/index.js +14 -6
  48. package/src/schematics/accordion/item/accordion-item-switch-component/index.js.map +1 -1
  49. package/src/schematics/accordion/item/accordion-item-switch-component/schema.json +174 -346
  50. package/src/schematics/accordion/item/accordion-item-switch-component/template.schema.json +6 -15
  51. package/src/schematics/accordion/item/accordion-item-table-component/index.d.ts +1 -1
  52. package/src/schematics/accordion/item/accordion-item-table-component/index.js +11 -13
  53. package/src/schematics/accordion/item/accordion-item-table-component/index.js.map +1 -1
  54. package/src/schematics/accordion/item/accordion-item-table-component/schema.json +453 -614
  55. package/src/schematics/accordion/item/accordion-item-table-component/template.schema.json +9 -18
  56. package/src/schematics/accordion/item/accordion-item-tree-table-component/index.d.ts +1 -1
  57. package/src/schematics/accordion/item/accordion-item-tree-table-component/index.js +37 -61
  58. package/src/schematics/accordion/item/accordion-item-tree-table-component/index.js.map +1 -1
  59. package/src/schematics/accordion/item/accordion-item-tree-table-component/schema.json +431 -592
  60. package/src/schematics/accordion/item/accordion-item-tree-table-component/template.schema.json +10 -19
  61. package/src/schematics/accordion-identifier.schema.json +25 -0
  62. package/src/schematics/accordion-item.schema.json +24 -0
  63. package/src/schematics/angular.schema.json +11 -3
  64. package/src/schematics/button.schema.json +1 -1
  65. package/src/schematics/data-grid-component/index.d.ts +2 -3
  66. package/src/schematics/data-grid-component/index.js +42 -45
  67. package/src/schematics/data-grid-component/index.js.map +1 -1
  68. package/src/schematics/data-grid-component/schema.json +261 -375
  69. package/src/schematics/data-grid-component/template.schema.json +6 -15
  70. package/src/schematics/data-grid-item.schema.json +4 -1
  71. package/src/schematics/data-grid.schema.json +26 -4
  72. package/src/schematics/dialog-component/schema.json +72 -158
  73. package/src/schematics/dialog-component/template.schema.json +3 -6
  74. package/src/schematics/form/control/input-form-control/schema.json +108 -306
  75. package/src/schematics/form/control/input-form-control/template.schema.json +6 -9
  76. package/src/schematics/form/control/select-form-control/schema.json +120 -307
  77. package/src/schematics/form/control/select-form-control/template.schema.json +6 -9
  78. package/src/schematics/form/control/table-select-form-control/index.d.ts +7 -1
  79. package/src/schematics/form/control/table-select-form-control/index.js +195 -149
  80. package/src/schematics/form/control/table-select-form-control/index.js.map +1 -1
  81. package/src/schematics/form/control/table-select-form-control/schema.json +101 -296
  82. package/src/schematics/form/control/table-select-form-control/template.schema.json +11 -6
  83. package/src/schematics/form/form-component/index.d.ts +2 -0
  84. package/src/schematics/form/form-component/index.js +6 -4
  85. package/src/schematics/form/form-component/index.js.map +1 -1
  86. package/src/schematics/form/form-component/schema.d.ts +3 -1
  87. package/src/schematics/form/form-component/schema.json +176 -233
  88. package/src/schematics/form/form-component/template.schema.json +6 -9
  89. package/src/schematics/form/form-control/schema.json +68 -176
  90. package/src/schematics/form/form-control/template.schema.json +6 -9
  91. package/src/schematics/form/form-definition/schema.json +125 -230
  92. package/src/schematics/form/form-definition/template.schema.json +6 -9
  93. package/src/schematics/form-component.schema.json +9 -3
  94. package/src/schematics/form-definition.schema.json +3 -3
  95. package/src/schematics/general.schema.json +1 -4
  96. package/src/schematics/input-form-control.schema.json +11 -3
  97. package/src/schematics/minimum-table.schema.json +11 -5
  98. package/src/schematics/pipe.schema.json +1 -1
  99. package/src/schematics/select-form-control.schema.json +15 -4
  100. package/src/schematics/table/action/dialog-table-action/schema.json +150 -230
  101. package/src/schematics/table/action/dialog-table-action/template.schema.json +3 -6
  102. package/src/schematics/table/action/form-table-action/schema.json +317 -310
  103. package/src/schematics/table/action/form-table-action/template.schema.json +6 -6
  104. package/src/schematics/table/action/navigation-table-action/schema.json +150 -230
  105. package/src/schematics/table/action/navigation-table-action/template.schema.json +3 -6
  106. package/src/schematics/table/action/open-api-table-action/schema.json +150 -230
  107. package/src/schematics/table/action/open-api-table-action/template.schema.json +3 -6
  108. package/src/schematics/table/action/operation-table-action/schema.json +138 -218
  109. package/src/schematics/table/action/operation-table-action/template.schema.json +3 -6
  110. package/src/schematics/table/header-button/form-table-header-button/schema.json +217 -261
  111. package/src/schematics/table/header-button/form-table-header-button/template.schema.json +6 -6
  112. package/src/schematics/table/header-button/navigation-table-header-button/schema.json +131 -211
  113. package/src/schematics/table/header-button/navigation-table-header-button/template.schema.json +3 -6
  114. package/src/schematics/table/table-action/schema.json +56 -139
  115. package/src/schematics/table/table-action/template.schema.json +6 -6
  116. package/src/schematics/table/table-component/index.d.ts +10 -2
  117. package/src/schematics/table/table-component/index.js +13 -1
  118. package/src/schematics/table/table-component/index.js.map +1 -1
  119. package/src/schematics/table/table-component/schema.json +352 -547
  120. package/src/schematics/table/table-component/template.schema.json +6 -18
  121. package/src/schematics/table/table-header-button/schema.json +56 -139
  122. package/src/schematics/table/table-header-button/template.schema.json +6 -6
  123. package/src/schematics/table/tree-table-component/files/component/__componentName__.component.html.hbs +6 -0
  124. package/src/schematics/table/tree-table-component/index.d.ts +3 -0
  125. package/src/schematics/table/tree-table-component/index.js +11 -3
  126. package/src/schematics/table/tree-table-component/index.js.map +1 -1
  127. package/src/schematics/table/tree-table-component/schema.json +352 -547
  128. package/src/schematics/table/tree-table-component/template.schema.json +6 -18
  129. package/src/schematics/table-column.schema.json +4 -1
  130. package/src/schematics/table.schema.json +4 -1
  131. package/src/schematics/tree-component/schema.json +70 -62
  132. package/src/schematics/tree-component/template.schema.json +7 -2
  133. package/src/schematics/tree-table.schema.json +3 -3
  134. package/src/schematics/value.schema.json +1 -1
  135. package/src/template.schema.json +173 -0
@@ -3,195 +3,84 @@
3
3
  "$id": "select-form-control-schematic",
4
4
  "allOf": [
5
5
  {
6
- "allOf": [
7
- {
8
- "allOf": [
9
- {
10
- "type": "object",
11
- "properties": {
12
- "project": {
13
- "type": "string",
14
- "description": "Project name where the files should be generated"
15
- },
16
- "feature": {
17
- "type": "string",
18
- "description": "Feature name where the files should be generated"
19
- },
20
- "overwrite": {
21
- "anyOf": [
22
- {
23
- "type": "boolean"
24
- },
25
- {
26
- "type": "array",
27
- "items": {
28
- "type": "string"
29
- }
30
- }
31
- ],
32
- "description": "Overwrite existing files",
33
- "default": false
34
- },
35
- "overwriteHtml": {
36
- "type": "boolean",
37
- "default": false
38
- },
39
- "replace": {
40
- "type": "boolean",
41
- "default": false
42
- }
43
- },
44
- "required": [
45
- "project"
46
- ]
47
- },
48
- {
49
- "type": "object",
50
- "properties": {
51
- "componentName": {
52
- "type": "string"
53
- },
54
- "name": {
55
- "type": "string"
56
- },
57
- "context": {
58
- "type": "string",
59
- "description": "The context use to generate proper names for class, files, etc"
60
- },
61
- "nestModule": {
62
- "type": "string",
63
- "description": "The module name for the table nest operations"
64
- },
65
- "controllerName": {
66
- "type": "string"
67
- },
68
- "backend": {
69
- "$ref": "#/allOf/1/allOf/1/properties/backend"
70
- },
71
- "directory": {
72
- "type": "string",
73
- "description": "A directory name or absolute path where the files should be generated. Relative to the project and feature base path if a feature is defined"
74
- },
75
- "shared": {
76
- "type": "boolean",
77
- "description": "Whether the generated code is used across the project",
78
- "default": false
79
- },
80
- "scope": {
81
- "type": "string"
82
- },
83
- "prefix": {
84
- "type": "string"
85
- },
86
- "openApi": {
87
- "type": "object",
88
- "additionalProperties": true
89
- }
90
- }
91
- }
92
- ]
6
+ "$ref": "#/definitions/formControl"
7
+ },
8
+ {
9
+ "$ref": "#/definitions/selectFormControl"
10
+ }
11
+ ],
12
+ "definitions": {
13
+ "formControl": {
14
+ "type": "object",
15
+ "properties": {
16
+ "name": {
17
+ "type": "string",
18
+ "description": "The name of the control"
93
19
  },
94
- {
95
- "type": "object",
96
- "properties": {
97
- "name": {
98
- "type": "string",
99
- "description": "The name of the control"
100
- },
101
- "type": {
102
- "$ref": "#/definitions/type"
103
- },
104
- "isArray": {
105
- "type": "boolean",
106
- "description": "Whether the control value is an array",
107
- "default": false
108
- },
109
- "state": {
110
- "type": "string",
111
- "description": "The initial state of the control"
112
- },
113
- "isRequired": {
114
- "type": "boolean",
115
- "description": "Whether the control value is required",
116
- "default": false
117
- },
118
- "isReadonly": {
119
- "type": "boolean",
120
- "description": "Whether the control value is readonly",
121
- "default": false
122
- },
123
- "isDisabled": {
124
- "type": "boolean",
125
- "description": "Whether the control value is disabled",
126
- "default": false
127
- },
128
- "validatorList": {
129
- "type": "array",
130
- "items": {
131
- "type": "string"
132
- }
133
- },
134
- "kind": {
135
- "type": "string",
136
- "description": "The name of the template",
137
- "enum": [
138
- "default",
139
- "input",
140
- "select",
141
- "checkbox",
142
- "autocomplete-table-select",
143
- "table-select",
144
- "textarea",
145
- "slide-toggle"
146
- ],
147
- "default": "default"
148
- }
149
- },
150
- "required": [
151
- "name"
152
- ],
153
- "additionalProperties": true
20
+ "type": {
21
+ "$ref": "#/definitions/type"
154
22
  },
155
- {
156
- "type": "object",
157
- "properties": {
158
- "formName": {
159
- "alias": "form",
160
- "type": "string",
161
- "description": "The name of the form where the form control should be added",
162
- "x-prompt": "Enter the name of the form where the form control should be added"
163
- }
164
- },
165
- "required": [
166
- "formName"
167
- ]
23
+ "isArray": {
24
+ "type": "boolean",
25
+ "description": "Whether the control value is an array",
26
+ "default": false
27
+ },
28
+ "state": {
29
+ "type": "string",
30
+ "description": "The initial state of the control"
31
+ },
32
+ "isRequired": {
33
+ "type": "boolean",
34
+ "description": "Whether the control value is required",
35
+ "default": false
36
+ },
37
+ "isReadonly": {
38
+ "type": "boolean",
39
+ "description": "Whether the control value is readonly",
40
+ "default": false
41
+ },
42
+ "isDisabled": {
43
+ "type": "boolean",
44
+ "description": "Whether the control value is disabled",
45
+ "default": false
46
+ },
47
+ "validatorList": {
48
+ "type": "array",
49
+ "items": {
50
+ "type": "string"
51
+ }
52
+ },
53
+ "kind": {
54
+ "type": "string",
55
+ "description": "The name of the template",
56
+ "enum": [
57
+ "default",
58
+ "input",
59
+ "select",
60
+ "checkbox",
61
+ "autocomplete-table-select",
62
+ "table-select",
63
+ "textarea",
64
+ "slide-toggle"
65
+ ],
66
+ "default": "default"
168
67
  }
169
- ]
68
+ },
69
+ "required": [
70
+ "name"
71
+ ],
72
+ "additionalProperties": true
170
73
  },
171
- {
74
+ "selectFormControl": {
172
75
  "allOf": [
173
76
  {
174
- "$ref": "#/allOf/0/allOf/1"
77
+ "$ref": "#/definitions/formControl"
175
78
  },
176
79
  {
177
80
  "type": "object",
178
81
  "properties": {
179
82
  "formField": {
180
- "type": "object",
181
- "properties": {
182
- "label": {
183
- "type": "string"
184
- },
185
- "prefixButton": {
186
- "$ref": "#/definitions/button"
187
- },
188
- "suffixButton": {
189
- "$ref": "#/definitions/button"
190
- },
191
- "hasClearButton": {
192
- "type": "boolean"
193
- }
194
- }
83
+ "$ref": "#/definitions/formField"
195
84
  },
196
85
  "options": {
197
86
  "type": "array",
@@ -222,15 +111,7 @@
222
111
  }
223
112
  },
224
113
  "backend": {
225
- "type": "string",
226
- "description": "The backend that should be used to handel data",
227
- "enum": [
228
- "none",
229
- "nestjs",
230
- "open-api",
231
- "local"
232
- ],
233
- "default": "none"
114
+ "$ref": "#/definitions/backend"
234
115
  },
235
116
  "multiple": {
236
117
  "alias": "multi",
@@ -240,9 +121,58 @@
240
121
  }
241
122
  }
242
123
  ]
243
- }
244
- ],
245
- "definitions": {
124
+ },
125
+ "backend": {
126
+ "type": "string",
127
+ "description": "The backend that should be used to handel data",
128
+ "enum": [
129
+ "none",
130
+ "nestjs",
131
+ "open-api",
132
+ "local"
133
+ ],
134
+ "default": "none"
135
+ },
136
+ "button": {
137
+ "type": "object",
138
+ "properties": {
139
+ "svgIcon": {
140
+ "type": "string"
141
+ },
142
+ "icon": {
143
+ "type": "string"
144
+ },
145
+ "directiveList": {
146
+ "type": "array",
147
+ "items": {
148
+ "$ref": "#/definitions/type"
149
+ }
150
+ },
151
+ "importList": {
152
+ "type": "array",
153
+ "items": {
154
+ "$ref": "#/definitions/type"
155
+ }
156
+ }
157
+ }
158
+ },
159
+ "formField": {
160
+ "type": "object",
161
+ "properties": {
162
+ "label": {
163
+ "type": "string"
164
+ },
165
+ "prefixButton": {
166
+ "$ref": "#/definitions/button"
167
+ },
168
+ "suffixButton": {
169
+ "$ref": "#/definitions/button"
170
+ },
171
+ "hasClearButton": {
172
+ "type": "boolean"
173
+ }
174
+ }
175
+ },
246
176
  "type": {
247
177
  "oneOf": [
248
178
  {
@@ -275,123 +205,6 @@
275
205
  ]
276
206
  }
277
207
  ]
278
- },
279
- "property": {
280
- "oneOf": [
281
- {
282
- "type": "string"
283
- },
284
- {
285
- "type": "object",
286
- "properties": {
287
- "name": {
288
- "type": "string"
289
- },
290
- "type": {
291
- "$ref": "#/definitions/type"
292
- },
293
- "isArray": {
294
- "type": "boolean"
295
- }
296
- },
297
- "required": [
298
- "name"
299
- ]
300
- }
301
- ],
302
- "definitions": {
303
- "type": {
304
- "oneOf": [
305
- {
306
- "type": "string"
307
- },
308
- {
309
- "type": "object",
310
- "properties": {
311
- "name": {
312
- "type": "string"
313
- },
314
- "isTypeOnly": {
315
- "type": "boolean"
316
- },
317
- "moduleSpecifier": {
318
- "type": "string"
319
- },
320
- "namedImport": {
321
- "type": "string"
322
- },
323
- "namespaceImport": {
324
- "type": "string"
325
- },
326
- "defaultImport": {
327
- "type": "string"
328
- }
329
- },
330
- "required": [
331
- "name"
332
- ]
333
- }
334
- ]
335
- }
336
- }
337
- },
338
- "button": {
339
- "type": "object",
340
- "properties": {
341
- "svgIcon": {
342
- "type": "string"
343
- },
344
- "icon": {
345
- "type": "string"
346
- },
347
- "directiveList": {
348
- "type": "array",
349
- "items": {
350
- "$ref": "#/definitions/type"
351
- }
352
- },
353
- "importList": {
354
- "type": "array",
355
- "items": {
356
- "$ref": "#/definitions/type"
357
- }
358
- }
359
- },
360
- "definitions": {
361
- "type": {
362
- "oneOf": [
363
- {
364
- "type": "string"
365
- },
366
- {
367
- "type": "object",
368
- "properties": {
369
- "name": {
370
- "type": "string"
371
- },
372
- "isTypeOnly": {
373
- "type": "boolean"
374
- },
375
- "moduleSpecifier": {
376
- "type": "string"
377
- },
378
- "namedImport": {
379
- "type": "string"
380
- },
381
- "namespaceImport": {
382
- "type": "string"
383
- },
384
- "defaultImport": {
385
- "type": "string"
386
- }
387
- },
388
- "required": [
389
- "name"
390
- ]
391
- }
392
- ]
393
- }
394
- }
395
208
  }
396
209
  }
397
210
  }
@@ -3,21 +3,18 @@
3
3
  "$id": "select-form-control-schematic",
4
4
  "allOf": [
5
5
  {
6
- "$ref": "../../form-control/template.schema.json"
6
+ "$ref": "#/definitions/formControl"
7
7
  },
8
8
  {
9
- "$ref": "../../../select-form-control.schema.json"
9
+ "$ref": "#/definitions/selectFormControl"
10
10
  }
11
11
  ],
12
12
  "definitions": {
13
- "type": {
14
- "$ref": "../../../type.schema.json"
15
- },
16
- "property": {
17
- "$ref": "../../../property.schema.json"
13
+ "formControl": {
14
+ "$ref": "../../form-control/template.schema.json"
18
15
  },
19
- "button": {
20
- "$ref": "../../../button.schema.json"
16
+ "selectFormControl": {
17
+ "$ref": "../../../select-form-control.schema.json"
21
18
  }
22
19
  }
23
20
  }
@@ -1,9 +1,15 @@
1
+ import { NormalizedUpstreamOptions } from '@rxap/ts-morph';
1
2
  import { Normalized } from '@rxap/utilities';
2
3
  import { WriterFunction } from 'ts-morph';
3
4
  import { NormalizedTableSelectColumn, NormalizedTableSelectFormControl } from '../../../../lib/form-control';
4
5
  import { NormalizedFormControlOptions } from '../../form-control';
5
6
  import { TableSelectFormControlOptions } from './schema';
6
- export type NormalizedTableSelectFormControlOptions = Readonly<Normalized<Omit<TableSelectFormControlOptions, 'columnList' | 'propertyList'>> & NormalizedFormControlOptions & NormalizedTableSelectFormControl>;
7
+ export interface NormalizedTableSelectFormControlOptions extends Readonly<Normalized<Omit<TableSelectFormControlOptions, 'columnList' | 'propertyList'>> & NormalizedFormControlOptions & NormalizedTableSelectFormControl> {
8
+ controllerName: string;
9
+ resolver: {
10
+ upstream: NormalizedUpstreamOptions | null;
11
+ } | null;
12
+ }
7
13
  export declare function NormalizeTableSelectFormControlOptions(options: TableSelectFormControlOptions): NormalizedTableSelectFormControlOptions;
8
14
  export declare function TableColumnToTableSelectColumn(column: NormalizedTableSelectColumn): WriterFunction;
9
15
  export declare function TableColumnListToTableSelectColumnMap(columnList: Array<NormalizedTableSelectColumn>): WriterFunction;