@rxap/schematic-angular 16.2.0-dev.8 → 16.2.0
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.
- package/CHANGELOG.md +398 -0
- package/README.md +1 -1
- package/collection.json +20 -0
- package/package.json +19 -20
- package/src/lib/accordion-header.js +8 -5
- package/src/lib/accordion-header.js.map +1 -1
- package/src/lib/accordion-identifier.d.ts +8 -4
- package/src/lib/accordion-identifier.js +4 -3
- package/src/lib/accordion-identifier.js.map +1 -1
- package/src/lib/accordion-item.d.ts +13 -6
- package/src/lib/accordion-item.js +42 -15
- package/src/lib/accordion-item.js.map +1 -1
- package/src/lib/angular-options.d.ts +2 -2
- package/src/lib/angular-options.js.map +1 -1
- package/src/lib/coerce-accordion-component.js +4 -2
- package/src/lib/coerce-accordion-component.js.map +1 -1
- package/src/lib/coerce-accordion-item-table-component.js +1 -1
- package/src/lib/coerce-accordion-item-table-component.js.map +1 -1
- package/src/lib/coerce-form-component.js +16 -3
- package/src/lib/coerce-form-component.js.map +1 -1
- package/src/lib/coerce-minimum-table-component.js +16 -5
- package/src/lib/coerce-minimum-table-component.js.map +1 -1
- package/src/lib/coerce-tree-table-component.js +1 -5
- package/src/lib/coerce-tree-table-component.js.map +1 -1
- package/src/lib/component-options.d.ts +10 -0
- package/src/lib/component-options.js +14 -0
- package/src/lib/component-options.js.map +1 -0
- package/src/lib/css-class.d.ts +9 -0
- package/src/lib/css-class.js +52 -0
- package/src/lib/css-class.js.map +1 -0
- package/src/lib/data-grid-item.d.ts +45 -7
- package/src/lib/data-grid-item.js +102 -6
- package/src/lib/data-grid-item.js.map +1 -1
- package/src/lib/data-grid-mode.d.ts +4 -0
- package/src/lib/data-grid-mode.js +9 -0
- package/src/lib/data-grid-mode.js.map +1 -0
- package/src/lib/data-grid-options.d.ts +10 -5
- package/src/lib/data-grid-options.js +42 -15
- package/src/lib/data-grid-options.js.map +1 -1
- package/src/lib/form/abstract-control.d.ts +31 -0
- package/src/lib/form/abstract-control.js +48 -0
- package/src/lib/form/abstract-control.js.map +1 -0
- package/src/lib/form/array/base-form-array.d.ts +18 -0
- package/src/lib/form/array/base-form-array.js +41 -0
- package/src/lib/form/array/base-form-array.js.map +1 -0
- package/src/lib/form/array/form-array-kind.d.ts +3 -0
- package/src/lib/form/array/form-array-kind.js +8 -0
- package/src/lib/form/array/form-array-kind.js.map +1 -0
- package/src/lib/form/array/form-array.d.ts +12 -0
- package/src/lib/form/array/form-array.js +18 -0
- package/src/lib/form/array/form-array.js.map +1 -0
- package/src/lib/form/coerce-control-component-imports.d.ts +3 -0
- package/src/lib/form/coerce-control-component-imports.js +18 -0
- package/src/lib/form/coerce-control-component-imports.js.map +1 -0
- package/src/lib/form/control/autocomplete-table-select-form-control.d.ts +9 -0
- package/src/lib/form/control/autocomplete-table-select-form-control.js +58 -0
- package/src/lib/form/control/autocomplete-table-select-form-control.js.map +1 -0
- package/src/lib/form/control/base-form-control.d.ts +15 -0
- package/src/lib/form/control/base-form-control.js +19 -0
- package/src/lib/form/control/base-form-control.js.map +1 -0
- package/src/lib/form/control/checkbox-form-control.d.ts +11 -0
- package/src/lib/form/control/checkbox-form-control.js +23 -0
- package/src/lib/form/control/checkbox-form-control.js.map +1 -0
- package/src/lib/form/control/form-control-kind.d.ts +10 -0
- package/src/lib/form/control/form-control-kind.js +15 -0
- package/src/lib/form/control/form-control-kind.js.map +1 -0
- package/src/lib/form/control/form-control.d.ts +20 -0
- package/src/lib/form/control/form-control.js +46 -0
- package/src/lib/form/control/form-control.js.map +1 -0
- package/src/lib/form/control/form-field-form-control.d.ts +39 -0
- package/src/lib/form/control/form-field-form-control.js +87 -0
- package/src/lib/form/control/form-field-form-control.js.map +1 -0
- package/src/lib/form/control/input-form-control.d.ts +15 -0
- package/src/lib/form/control/input-form-control.js +75 -0
- package/src/lib/form/control/input-form-control.js.map +1 -0
- package/src/lib/form/control/select-form-control.d.ts +22 -0
- package/src/lib/form/control/select-form-control.js +47 -0
- package/src/lib/form/control/select-form-control.js.map +1 -0
- package/src/lib/form/control/slide-toggle-form-control.d.ts +11 -0
- package/src/lib/form/control/slide-toggle-form-control.js +23 -0
- package/src/lib/form/control/slide-toggle-form-control.js.map +1 -0
- package/src/lib/form/control/table-select-form-control.d.ts +46 -0
- package/src/lib/form/control/table-select-form-control.js +82 -0
- package/src/lib/form/control/table-select-form-control.js.map +1 -0
- package/src/lib/form/control/textarea-form-control.d.ts +22 -0
- package/src/lib/form/control/textarea-form-control.js +52 -0
- package/src/lib/form/control/textarea-form-control.js.map +1 -0
- package/src/lib/form/control.d.ts +8 -0
- package/src/lib/form/control.js +38 -0
- package/src/lib/form/control.js.map +1 -0
- package/src/lib/form/generate-form-template.d.ts +2 -2
- package/src/lib/form/group/base-form-group.d.ts +17 -0
- package/src/lib/form/group/base-form-group.js +20 -0
- package/src/lib/form/group/base-form-group.js.map +1 -0
- package/src/lib/form/group/form-group-kind.d.ts +3 -0
- package/src/lib/form/group/form-group-kind.js +8 -0
- package/src/lib/form/group/form-group-kind.js.map +1 -0
- package/src/lib/form/group/form-group.d.ts +12 -0
- package/src/lib/form/group/form-group.js +18 -0
- package/src/lib/form/group/form-group.js.map +1 -0
- package/src/lib/load-handlebars-template.d.ts +3 -0
- package/src/lib/load-handlebars-template.js +13 -1
- package/src/lib/load-handlebars-template.js.map +1 -1
- package/src/lib/minimum-table-component-options.d.ts +1 -1
- package/src/lib/minimum-table-component-options.js +22 -15
- package/src/lib/minimum-table-component-options.js.map +1 -1
- package/src/lib/minimum-table-options.d.ts +22 -4
- package/src/lib/minimum-table-options.js +40 -6
- package/src/lib/minimum-table-options.js.map +1 -1
- package/src/lib/pipe-option.d.ts +11 -0
- package/src/lib/pipe-option.js +75 -0
- package/src/lib/pipe-option.js.map +1 -0
- package/src/lib/route-component.d.ts +16 -0
- package/src/lib/route-component.js +15 -0
- package/src/lib/route-component.js.map +1 -0
- package/src/lib/table/column/base-table-column.d.ts +61 -0
- package/src/lib/table/column/base-table-column.js +309 -0
- package/src/lib/table/column/base-table-column.js.map +1 -0
- package/src/lib/table/column/boolean-table-column.d.ts +8 -0
- package/src/lib/table/column/boolean-table-column.js +10 -0
- package/src/lib/table/column/boolean-table-column.js.map +1 -0
- package/src/lib/table/column/custom-table-column.d.ts +11 -0
- package/src/lib/table/column/custom-table-column.js +11 -0
- package/src/lib/table/column/custom-table-column.js.map +1 -0
- package/src/lib/table/column/date-table-column.d.ts +11 -0
- package/src/lib/table/column/date-table-column.js +11 -0
- package/src/lib/table/column/date-table-column.js.map +1 -0
- package/src/lib/table/sortable.d.ts +16 -0
- package/src/lib/table/sortable.js +27 -0
- package/src/lib/table/sortable.js.map +1 -0
- package/src/lib/table/table-column-kind.d.ts +13 -0
- package/src/lib/table/table-column-kind.js +21 -0
- package/src/lib/table/table-column-kind.js.map +1 -0
- package/src/lib/table/table-column-modifier.d.ts +12 -0
- package/src/lib/table/table-column-modifier.js +20 -0
- package/src/lib/table/table-column-modifier.js.map +1 -0
- package/src/lib/table/table-column-pipe.d.ts +4 -0
- package/src/lib/table/table-column-pipe.js +3 -0
- package/src/lib/table/table-column-pipe.js.map +1 -0
- package/src/lib/table/table-column-sticky.d.ts +5 -0
- package/src/lib/table/table-column-sticky.js +13 -0
- package/src/lib/table/table-column-sticky.js.map +1 -0
- package/src/lib/table/table-column.d.ts +6 -0
- package/src/lib/table/table-column.js +36 -0
- package/src/lib/table/table-column.js.map +1 -0
- package/src/lib/table/table-filter-column-rule.js +5 -4
- package/src/lib/table/table-filter-column-rule.js.map +1 -1
- package/src/lib/table-action.js.map +1 -1
- package/src/lib/table-options.d.ts +4 -3
- package/src/lib/table-options.js +23 -3
- package/src/lib/table-options.js.map +1 -1
- package/src/lib/table-row-action.d.ts +4 -2
- package/src/lib/table-row-action.js +8 -7
- package/src/lib/table-row-action.js.map +1 -1
- package/src/lib/tree-table-options.d.ts +4 -3
- package/src/lib/tree-table-options.js +40 -3
- package/src/lib/tree-table-options.js.map +1 -1
- package/src/lib/use-pick-from-table-interface-as-form-type.d.ts +1 -1
- package/src/lib/value-option.d.ts +12 -0
- package/src/lib/value-option.js +66 -0
- package/src/lib/value-option.js.map +1 -0
- package/src/schema.json +3319 -0
- package/src/schematic-input.schema.json +579 -0
- package/src/schematics/abstract-control.schema.json +78 -0
- package/src/schematics/accordion/accordion-component/files/component/__componentName__.component.html.hbs +16 -7
- package/src/schematics/accordion/accordion-component/index.d.ts +6 -2
- package/src/schematics/accordion/accordion-component/index.js +72 -42
- package/src/schematics/accordion/accordion-component/index.js.map +1 -1
- package/src/schematics/accordion/accordion-component/schema.d.ts +6 -0
- package/src/schematics/accordion/accordion-component/schema.json +2075 -0
- package/src/schematics/accordion/accordion-component/template.schema.json +23 -20
- package/src/schematics/accordion/accordion-item-component/index.d.ts +7 -2
- package/src/schematics/accordion/accordion-item-component/index.js +79 -51
- package/src/schematics/accordion/accordion-item-component/index.js.map +1 -1
- package/src/schematics/accordion/accordion-item-component/schema.json +2006 -0
- package/src/schematics/accordion/accordion-item-component/template.schema.json +8 -9
- package/src/schematics/accordion/item/accordion-item-data-grid-component/index.d.ts +1 -1
- package/src/schematics/accordion/item/accordion-item-data-grid-component/index.js +20 -38
- package/src/schematics/accordion/item/accordion-item-data-grid-component/index.js.map +1 -1
- package/src/schematics/accordion/item/accordion-item-data-grid-component/schema.json +1252 -0
- package/src/schematics/accordion/item/accordion-item-data-grid-component/template.schema.json +6 -17
- package/src/schematics/accordion/item/accordion-item-switch-component/index.d.ts +1 -1
- package/src/schematics/accordion/item/accordion-item-switch-component/index.js +14 -6
- package/src/schematics/accordion/item/accordion-item-switch-component/index.js.map +1 -1
- package/src/schematics/accordion/item/accordion-item-switch-component/schema.json +1994 -0
- package/src/schematics/accordion/item/accordion-item-switch-component/template.schema.json +7 -71
- package/src/schematics/accordion/item/accordion-item-table-component/index.d.ts +1 -1
- package/src/schematics/accordion/item/accordion-item-table-component/index.js +5 -52
- package/src/schematics/accordion/item/accordion-item-table-component/index.js.map +1 -1
- package/src/schematics/accordion/item/accordion-item-table-component/schema.json +1539 -0
- package/src/schematics/accordion/item/accordion-item-table-component/template.schema.json +6 -32
- package/src/schematics/accordion/item/accordion-item-tree-table-component/index.d.ts +1 -1
- package/src/schematics/accordion/item/accordion-item-tree-table-component/index.js +21 -80
- package/src/schematics/accordion/item/accordion-item-tree-table-component/index.js.map +1 -1
- package/src/schematics/accordion/item/accordion-item-tree-table-component/schema.json +1527 -0
- package/src/schematics/accordion/item/accordion-item-tree-table-component/template.schema.json +7 -33
- package/src/schematics/accordion/templates/accordion-header.hbs +7 -3
- package/src/schematics/accordion/templates/switch-accordion-item.hbs +12 -4
- package/src/schematics/accordion-identifier.schema.json +24 -0
- package/src/schematics/accordion-item.schema.json +47 -30
- package/src/schematics/angular.schema.json +11 -3
- package/src/schematics/autocomplete-table-select-form-control.schema.json +97 -0
- package/src/schematics/base-accordion-item.schema.json +52 -0
- package/src/schematics/base-form-array.schema.json +45 -0
- package/src/schematics/base-form-control.schema.json +27 -0
- package/src/schematics/base-form-group.schema.json +42 -0
- package/src/schematics/base-table-column.schema.json +81 -0
- package/src/schematics/boolean-table-column.schema.json +24 -0
- package/src/schematics/button.schema.json +1 -1
- package/src/schematics/checkbox-form-control.schema.json +31 -0
- package/src/schematics/component-table-column.schema.json +24 -0
- package/src/schematics/component.schema.json +16 -0
- package/src/schematics/control.schema.json +26 -0
- package/src/schematics/copy-to-clipboard-table-column.schema.json +24 -0
- package/src/schematics/css-class.schema.json +34 -0
- package/src/schematics/custom-table-column.schema.json +27 -0
- package/src/schematics/data-grid-accordion-item.schema.json +35 -0
- package/src/schematics/data-grid-component/files/component/__componentName__.component.html.hbs +15 -8
- package/src/schematics/data-grid-component/index.d.ts +2 -3
- package/src/schematics/data-grid-component/index.js +87 -64
- package/src/schematics/data-grid-component/index.js.map +1 -1
- package/src/schematics/data-grid-component/schema.json +1184 -0
- package/src/schematics/data-grid-component/template.schema.json +6 -9
- package/src/schematics/data-grid-component/templates/default-data-grid-item.hbs +3 -0
- package/src/schematics/data-grid-component/templates/link-data-grid-item.hbs +8 -0
- package/src/schematics/data-grid-item.schema.json +39 -12
- package/src/schematics/data-grid.schema.json +26 -4
- package/src/schematics/date-table-column.schema.json +27 -0
- package/src/schematics/dialog-component/schema.json +157 -0
- package/src/schematics/dialog-component/template.schema.json +3 -6
- package/src/schematics/form/control/autocomplete-table-select-form-control/index.d.ts +10 -0
- package/src/schematics/form/control/autocomplete-table-select-form-control/index.js +286 -0
- package/src/schematics/form/control/autocomplete-table-select-form-control/index.js.map +1 -0
- package/src/schematics/form/control/autocomplete-table-select-form-control/schema.d.ts +4 -0
- package/src/schematics/form/control/autocomplete-table-select-form-control/schema.json +542 -0
- package/src/schematics/form/control/autocomplete-table-select-form-control/template.schema.json +39 -0
- package/src/schematics/form/control/input-form-control/index.d.ts +1 -1
- package/src/schematics/form/control/input-form-control/index.js +4 -4
- package/src/schematics/form/control/input-form-control/index.js.map +1 -1
- package/src/schematics/form/control/input-form-control/schema.d.ts +2 -2
- package/src/schematics/form/control/input-form-control/schema.json +410 -0
- package/src/schematics/form/control/input-form-control/template.schema.json +19 -9
- package/src/schematics/form/control/select-form-control/index.d.ts +2 -2
- package/src/schematics/form/control/select-form-control/index.js +23 -16
- package/src/schematics/form/control/select-form-control/index.js.map +1 -1
- package/src/schematics/form/control/select-form-control/schema.d.ts +2 -3
- package/src/schematics/form/control/select-form-control/schema.json +520 -0
- package/src/schematics/form/control/select-form-control/template.schema.json +19 -9
- package/src/schematics/form/control/table-select-form-control/index.d.ts +3 -3
- package/src/schematics/form/control/table-select-form-control/index.js +210 -155
- package/src/schematics/form/control/table-select-form-control/index.js.map +1 -1
- package/src/schematics/form/control/table-select-form-control/schema.d.ts +2 -3
- package/src/schematics/form/control/table-select-form-control/schema.json +562 -0
- package/src/schematics/form/control/table-select-form-control/template.schema.json +16 -55
- package/src/schematics/form/form-array/index.d.ts +9 -0
- package/src/schematics/form/form-array/index.js +54 -0
- package/src/schematics/form/form-array/index.js.map +1 -0
- package/src/schematics/form/form-array/schema.d.ts +4 -0
- package/src/schematics/form/form-array/schema.json +1056 -0
- package/src/schematics/form/form-array/template.schema.json +33 -0
- package/src/schematics/form/form-component/files/component/__componentName__.component.html.hbs +4 -1
- package/src/schematics/form/form-component/index.d.ts +4 -4
- package/src/schematics/form/form-component/index.js +19 -22
- package/src/schematics/form/form-component/index.js.map +1 -1
- package/src/schematics/form/form-component/schema.d.ts +4 -2
- package/src/schematics/form/form-component/schema.json +1093 -0
- package/src/schematics/form/form-component/template.schema.json +6 -9
- package/src/schematics/form/form-control/index.d.ts +3 -5
- package/src/schematics/form/form-control/index.js +10 -20
- package/src/schematics/form/form-control/index.js.map +1 -1
- package/src/schematics/form/form-control/schema.d.ts +2 -4
- package/src/schematics/form/form-control/schema.json +902 -0
- package/src/schematics/form/form-control/template.schema.json +7 -11
- package/src/schematics/form/form-definition/index.d.ts +2 -2
- package/src/schematics/form/form-definition/index.js +28 -15
- package/src/schematics/form/form-definition/index.js.map +1 -1
- package/src/schematics/form/form-definition/schema.d.ts +2 -2
- package/src/schematics/form/form-definition/schema.json +1068 -0
- package/src/schematics/form/form-definition/template.schema.json +6 -9
- package/src/schematics/form/form-group/index.d.ts +9 -0
- package/src/schematics/form/form-group/index.js +54 -0
- package/src/schematics/form/form-group/index.js.map +1 -0
- package/src/schematics/form/form-group/schema.d.ts +4 -0
- package/src/schematics/form/form-group/schema.json +1056 -0
- package/src/schematics/form/form-group/template.schema.json +33 -0
- package/src/schematics/form/templates/autocomplete-table-select-form-control.hbs +34 -0
- package/src/schematics/form/templates/checkbox-form-control.hbs +4 -2
- package/src/schematics/form/templates/default-form-array.hbs +29 -0
- package/src/schematics/form/templates/default-form-group.hbs +15 -0
- package/src/schematics/form/templates/input-form-control.hbs +14 -7
- package/src/schematics/form/templates/mat-form-field.hbs +6 -6
- package/src/schematics/form/templates/select-form-control.hbs +18 -0
- package/src/schematics/form/templates/slide-toggle-form-control.hbs +3 -1
- package/src/schematics/form/templates/table-select-form-control.hbs +23 -16
- package/src/schematics/form/templates/textarea-form-control.hbs +25 -0
- package/src/schematics/form-array.schema.json +42 -0
- package/src/schematics/form-component.schema.json +9 -3
- package/src/schematics/form-control.schema.json +70 -54
- package/src/schematics/form-definition.schema.json +3 -3
- package/src/schematics/form-field.schema.json +6 -0
- package/src/schematics/form-group.schema.json +42 -0
- package/src/schematics/general.schema.json +1 -4
- package/src/schematics/icon-table-column.schema.json +24 -0
- package/src/schematics/input-form-control.schema.json +19 -6
- package/src/schematics/link-table-column.schema.json +24 -0
- package/src/schematics/minimum-table.schema.json +59 -5
- package/src/schematics/pipe.schema.json +38 -0
- package/src/schematics/property.schema.json +14 -4
- package/src/schematics/route-component/files/component/__componentName__.component.html.hbs +1 -0
- package/src/schematics/route-component/index.d.ts +8 -0
- package/src/schematics/route-component/index.js +109 -0
- package/src/schematics/route-component/index.js.map +1 -0
- package/src/schematics/route-component/schema.d.ts +5 -0
- package/src/schematics/route-component/schema.json +154 -0
- package/src/schematics/route-component/template.schema.json +20 -0
- package/src/schematics/route-component.schema.json +35 -0
- package/src/schematics/select-form-control.schema.json +28 -6
- package/src/schematics/slide-toggle-form-control.schema.json +31 -0
- package/src/schematics/spinner-table-column.schema.json +24 -0
- package/src/schematics/switch-accordion-item.schema.json +83 -0
- package/src/schematics/table/action/dialog-table-action/index.js +1 -0
- package/src/schematics/table/action/dialog-table-action/index.js.map +1 -1
- package/src/schematics/table/action/dialog-table-action/schema.json +263 -0
- package/src/schematics/table/action/dialog-table-action/template.schema.json +3 -6
- package/src/schematics/table/action/form-table-action/index.d.ts +2 -2
- package/src/schematics/table/action/form-table-action/index.js +6 -5
- package/src/schematics/table/action/form-table-action/index.js.map +1 -1
- package/src/schematics/table/action/form-table-action/schema.d.ts +2 -2
- package/src/schematics/table/action/form-table-action/schema.json +1226 -0
- package/src/schematics/table/action/form-table-action/template.schema.json +6 -6
- package/src/schematics/table/action/navigation-table-action/schema.json +233 -0
- package/src/schematics/table/action/navigation-table-action/template.schema.json +3 -6
- package/src/schematics/table/action/open-api-table-action/schema.json +261 -0
- package/src/schematics/table/action/open-api-table-action/template.schema.json +3 -6
- package/src/schematics/table/action/operation-table-action/index.js +2 -1
- package/src/schematics/table/action/operation-table-action/index.js.map +1 -1
- package/src/schematics/table/action/operation-table-action/schema.json +219 -0
- package/src/schematics/table/action/operation-table-action/template.schema.json +3 -6
- package/src/schematics/table/header-button/form-table-header-button/index.d.ts +2 -2
- package/src/schematics/table/header-button/form-table-header-button/index.js +2 -2
- package/src/schematics/table/header-button/form-table-header-button/index.js.map +1 -1
- package/src/schematics/table/header-button/form-table-header-button/schema.d.ts +2 -2
- package/src/schematics/table/header-button/form-table-header-button/schema.json +1166 -0
- package/src/schematics/table/header-button/form-table-header-button/template.schema.json +6 -24
- package/src/schematics/table/header-button/navigation-table-header-button/schema.json +183 -0
- package/src/schematics/table/header-button/navigation-table-header-button/template.schema.json +3 -6
- package/src/schematics/table/table-action/schema.json +212 -0
- package/src/schematics/table/table-action/template.schema.json +6 -6
- package/src/schematics/table/table-component/files/component/__componentName__.component.html.hbs +84 -33
- package/src/schematics/table/table-component/index.d.ts +0 -5
- package/src/schematics/table/table-component/index.js +21 -33
- package/src/schematics/table/table-component/index.js.map +1 -1
- package/src/schematics/table/table-component/schema.json +1464 -0
- package/src/schematics/table/table-component/template.schema.json +6 -12
- package/src/schematics/table/table-header-button/schema.json +162 -0
- package/src/schematics/table/table-header-button/template.schema.json +6 -6
- package/src/schematics/table/templates/boolean-table-column.hbs +18 -5
- package/src/schematics/table/templates/component-table-column.hbs +19 -6
- package/src/schematics/table/templates/copy-to-clipboard-table-column.hbs +18 -5
- package/src/schematics/table/templates/custom-table-column.hbs +23 -0
- package/src/schematics/table/templates/date-table-column.hbs +18 -5
- package/src/schematics/table/templates/default-table-column.hbs +20 -5
- package/src/schematics/table/templates/icon-table-column.hbs +18 -5
- package/src/schematics/table/templates/link-table-column.hbs +18 -5
- package/src/schematics/table/templates/mat-column-def.hbs +3 -0
- package/src/schematics/table/templates/spinner-table-column.hbs +27 -0
- package/src/schematics/table/templates/tree-table-column.hbs +21 -0
- package/src/schematics/table/tree-table-component/files/component/__componentName__.component.html.hbs +93 -50
- package/src/schematics/table/tree-table-component/index.d.ts +3 -0
- package/src/schematics/table/tree-table-component/index.js +30 -9
- package/src/schematics/table/tree-table-component/index.js.map +1 -1
- package/src/schematics/table/tree-table-component/schema.json +1452 -0
- package/src/schematics/table/tree-table-component/template.schema.json +6 -12
- package/src/schematics/table-accordion-item.schema.json +42 -0
- package/src/schematics/table-action.schema.json +7 -3
- package/src/schematics/table-column.schema.json +61 -47
- package/src/schematics/table-select-form-control.schema.json +103 -0
- package/src/schematics/table.schema.json +6 -2
- package/src/schematics/templates/css-class.hbs +1 -0
- package/src/schematics/templates/pipe.hbs +4 -0
- package/src/schematics/textarea-form-control.schema.json +44 -0
- package/src/schematics/tree-component/index.js +2 -1
- package/src/schematics/tree-component/index.js.map +1 -1
- package/src/schematics/tree-component/schema.json +131 -0
- package/src/schematics/tree-component/template.schema.json +7 -2
- package/src/schematics/tree-table-accordion-item.schema.json +42 -0
- package/src/schematics/tree-table-column.schema.json +24 -0
- package/src/schematics/tree-table.schema.json +5 -4
- package/src/schematics/upstream.schema.json +62 -23
- package/src/schematics/value.schema.json +26 -0
- package/src/template.schema.json +275 -0
- package/src/lib/form-component-control.d.ts +0 -8
- package/src/lib/form-component-control.js +0 -15
- package/src/lib/form-component-control.js.map +0 -1
- package/src/lib/form-control.d.ts +0 -125
- package/src/lib/form-control.js +0 -303
- package/src/lib/form-control.js.map +0 -1
- package/src/lib/form-definition-control.d.ts +0 -5
- package/src/lib/form-definition-control.js +0 -30
- package/src/lib/form-definition-control.js.map +0 -1
- package/src/lib/merge-with-column-list.d.ts +0 -3
- package/src/lib/merge-with-column-list.js +0 -18
- package/src/lib/merge-with-column-list.js.map +0 -1
- package/src/lib/table-column.d.ts +0 -62
- package/src/lib/table-column.js +0 -313
- package/src/lib/table-column.js.map +0 -1
|
@@ -3,21 +3,18 @@
|
|
|
3
3
|
"$id": "data-grid-component-schematic",
|
|
4
4
|
"allOf": [
|
|
5
5
|
{
|
|
6
|
-
"$ref": "
|
|
6
|
+
"$ref": "#/definitions/angular"
|
|
7
7
|
},
|
|
8
8
|
{
|
|
9
|
-
"$ref": "
|
|
9
|
+
"$ref": "#/definitions/dataGrid"
|
|
10
10
|
}
|
|
11
11
|
],
|
|
12
12
|
"definitions": {
|
|
13
|
-
"
|
|
14
|
-
"$ref": "../
|
|
15
|
-
},
|
|
16
|
-
"property": {
|
|
17
|
-
"$ref": "../property.schema.json"
|
|
13
|
+
"angular": {
|
|
14
|
+
"$ref": "../angular.schema.json"
|
|
18
15
|
},
|
|
19
|
-
"
|
|
20
|
-
"$ref": "../
|
|
16
|
+
"dataGrid": {
|
|
17
|
+
"$ref": "../data-grid.schema.json"
|
|
21
18
|
}
|
|
22
19
|
}
|
|
23
20
|
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
<ng-template let-value rxapDataGridCellDef>
|
|
2
|
+
<a [href]="value{{> pipe pipeList=item.pipeList}}" [matTooltip]="value{{> pipe pipeList=item.pipeList}}" class="link" mat-flat-button target="{{item.target}}">
|
|
3
|
+
<span class="flex flex-row gap-4 items-center">
|
|
4
|
+
<span class="overflow-hidden whitespace-nowrap text-overflow-ellipsis max-w-xs">\{{ value{{> pipe pipeList=item.pipeList}} }}</span>
|
|
5
|
+
<mat-icon inline>open_in_new</mat-icon>
|
|
6
|
+
</span>
|
|
7
|
+
</a>
|
|
8
|
+
</ng-template>
|
|
@@ -1,23 +1,50 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "http://json-schema.org/schema",
|
|
3
3
|
"$id": "data-grid-item",
|
|
4
|
-
"
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
4
|
+
"type": "object",
|
|
5
|
+
"properties":{
|
|
6
|
+
"name": {
|
|
7
|
+
"type": "string",
|
|
8
|
+
"description": "The name of the data grid item"
|
|
9
|
+
},
|
|
10
|
+
"header": {
|
|
11
|
+
"type": "string",
|
|
12
|
+
"description": "The name of the control"
|
|
13
|
+
},
|
|
14
|
+
"pipeList": {
|
|
15
|
+
"type": "array",
|
|
16
|
+
"items": {
|
|
17
|
+
"$ref": "#/definitions/pipe"
|
|
15
18
|
}
|
|
19
|
+
},
|
|
20
|
+
"formControl": {
|
|
21
|
+
"$ref": "#/definitions/control"
|
|
22
|
+
},
|
|
23
|
+
"template": {
|
|
24
|
+
"type": "string"
|
|
25
|
+
},
|
|
26
|
+
"kind": {
|
|
27
|
+
"type": "string",
|
|
28
|
+
"enum": ["default", "link"],
|
|
29
|
+
"default": "default"
|
|
30
|
+
},
|
|
31
|
+
"type": {
|
|
32
|
+
"$ref": "#/definitions/type"
|
|
33
|
+
},
|
|
34
|
+
"isArray": {
|
|
35
|
+
"type": "boolean"
|
|
16
36
|
}
|
|
17
|
-
|
|
37
|
+
},
|
|
38
|
+
"required": ["name"],
|
|
18
39
|
"definitions": {
|
|
19
40
|
"type": {
|
|
20
41
|
"$ref": "./type.schema.json"
|
|
42
|
+
},
|
|
43
|
+
"pipe": {
|
|
44
|
+
"$ref": "./pipe.schema.json"
|
|
45
|
+
},
|
|
46
|
+
"control": {
|
|
47
|
+
"$ref": "./control.schema.json"
|
|
21
48
|
}
|
|
22
49
|
}
|
|
23
50
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "http://json-schema.org/schema",
|
|
3
|
-
"$id": "data-grid
|
|
3
|
+
"$id": "data-grid",
|
|
4
4
|
"type": "object",
|
|
5
5
|
"properties": {
|
|
6
6
|
"mode": {
|
|
@@ -27,18 +27,40 @@
|
|
|
27
27
|
"alias": "item",
|
|
28
28
|
"type": "array",
|
|
29
29
|
"items": {
|
|
30
|
-
"$ref": "
|
|
30
|
+
"$ref": "#/definitions/dataGridItem"
|
|
31
31
|
}
|
|
32
32
|
},
|
|
33
33
|
"inCard": {
|
|
34
34
|
"type": "boolean",
|
|
35
35
|
"description": "Whether the data grid is used in a card.",
|
|
36
36
|
"default": true
|
|
37
|
+
},
|
|
38
|
+
"upstream": {
|
|
39
|
+
"$ref": "#/definitions/upstream"
|
|
40
|
+
},
|
|
41
|
+
"propertyList": {
|
|
42
|
+
"alias": "property",
|
|
43
|
+
"type": "array",
|
|
44
|
+
"items": {
|
|
45
|
+
"$ref": "#/definitions/property"
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
"identifier": {
|
|
49
|
+
"$ref": "#/definitions/accordionIdentifier"
|
|
37
50
|
}
|
|
38
51
|
},
|
|
39
52
|
"definitions": {
|
|
40
|
-
"
|
|
41
|
-
"$ref": "./
|
|
53
|
+
"dataGridItem": {
|
|
54
|
+
"$ref": "./data-grid-item.schema.json"
|
|
55
|
+
},
|
|
56
|
+
"upstream": {
|
|
57
|
+
"$ref": "./upstream.schema.json"
|
|
58
|
+
},
|
|
59
|
+
"property": {
|
|
60
|
+
"$ref": "./property.schema.json"
|
|
61
|
+
},
|
|
62
|
+
"accordionIdentifier": {
|
|
63
|
+
"$ref": "./accordion-identifier.schema.json"
|
|
42
64
|
}
|
|
43
65
|
}
|
|
44
66
|
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/schema",
|
|
3
|
+
"$id": "date-table-column",
|
|
4
|
+
"allOf": [
|
|
5
|
+
{
|
|
6
|
+
"$ref": "#/definitions/baseTableColumn"
|
|
7
|
+
},
|
|
8
|
+
{
|
|
9
|
+
"type": "object",
|
|
10
|
+
"properties": {
|
|
11
|
+
"kind": {
|
|
12
|
+
"type": "string",
|
|
13
|
+
"const": "date"
|
|
14
|
+
},
|
|
15
|
+
"format": {
|
|
16
|
+
"type": "string"
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
"required": ["kind"]
|
|
20
|
+
}
|
|
21
|
+
],
|
|
22
|
+
"definitions": {
|
|
23
|
+
"baseTableColumn": {
|
|
24
|
+
"$ref": "./base-table-column.schema.json"
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
}
|
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/schema",
|
|
3
|
+
"$id": "dialog-component-schematic",
|
|
4
|
+
"allOf": [
|
|
5
|
+
{
|
|
6
|
+
"$ref": "#/definitions/angular"
|
|
7
|
+
},
|
|
8
|
+
{
|
|
9
|
+
"type": "object",
|
|
10
|
+
"properties": {
|
|
11
|
+
"dialogName": {
|
|
12
|
+
"alias": "name",
|
|
13
|
+
"type": "string",
|
|
14
|
+
"description": "The name of the dialog",
|
|
15
|
+
"x-prompt": "Which name should the dialog module have?"
|
|
16
|
+
},
|
|
17
|
+
"title": {
|
|
18
|
+
"type": "string",
|
|
19
|
+
"description": "The title of the dialog"
|
|
20
|
+
},
|
|
21
|
+
"actionList": {
|
|
22
|
+
"alias": "action",
|
|
23
|
+
"type": "array",
|
|
24
|
+
"description": "The list of actions to be added to the dialog",
|
|
25
|
+
"items": {
|
|
26
|
+
"oneOf": [
|
|
27
|
+
{
|
|
28
|
+
"type": "string"
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
"type": "object",
|
|
32
|
+
"properties": {
|
|
33
|
+
"label": {
|
|
34
|
+
"type": "string"
|
|
35
|
+
},
|
|
36
|
+
"color": {
|
|
37
|
+
"type": "string"
|
|
38
|
+
},
|
|
39
|
+
"role": {
|
|
40
|
+
"type": "string",
|
|
41
|
+
"enum": [
|
|
42
|
+
"submit",
|
|
43
|
+
"close"
|
|
44
|
+
]
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
]
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
"required": [
|
|
53
|
+
"dialogName"
|
|
54
|
+
]
|
|
55
|
+
}
|
|
56
|
+
],
|
|
57
|
+
"definitions": {
|
|
58
|
+
"angular": {
|
|
59
|
+
"allOf": [
|
|
60
|
+
{
|
|
61
|
+
"$ref": "#/definitions/general"
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
"type": "object",
|
|
65
|
+
"properties": {
|
|
66
|
+
"componentName": {
|
|
67
|
+
"type": "string"
|
|
68
|
+
},
|
|
69
|
+
"name": {
|
|
70
|
+
"type": "string"
|
|
71
|
+
},
|
|
72
|
+
"context": {
|
|
73
|
+
"type": "string",
|
|
74
|
+
"description": "The context use to generate proper names for class, files, etc"
|
|
75
|
+
},
|
|
76
|
+
"nestModule": {
|
|
77
|
+
"type": "string",
|
|
78
|
+
"description": "The module name for the table nest operations"
|
|
79
|
+
},
|
|
80
|
+
"controllerName": {
|
|
81
|
+
"type": "string"
|
|
82
|
+
},
|
|
83
|
+
"backend": {
|
|
84
|
+
"$ref": "#/definitions/backend"
|
|
85
|
+
},
|
|
86
|
+
"directory": {
|
|
87
|
+
"type": "string",
|
|
88
|
+
"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"
|
|
89
|
+
},
|
|
90
|
+
"shared": {
|
|
91
|
+
"type": "boolean",
|
|
92
|
+
"description": "Whether the generated code is used across the project",
|
|
93
|
+
"default": false
|
|
94
|
+
},
|
|
95
|
+
"scope": {
|
|
96
|
+
"type": "string"
|
|
97
|
+
},
|
|
98
|
+
"prefix": {
|
|
99
|
+
"type": "string"
|
|
100
|
+
},
|
|
101
|
+
"openApi": {
|
|
102
|
+
"type": "object",
|
|
103
|
+
"additionalProperties": true
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
]
|
|
108
|
+
},
|
|
109
|
+
"backend": {
|
|
110
|
+
"type": "string",
|
|
111
|
+
"description": "The backend that should be used to handel data",
|
|
112
|
+
"enum": [
|
|
113
|
+
"none",
|
|
114
|
+
"nestjs",
|
|
115
|
+
"open-api",
|
|
116
|
+
"local"
|
|
117
|
+
],
|
|
118
|
+
"default": "none"
|
|
119
|
+
},
|
|
120
|
+
"general": {
|
|
121
|
+
"type": "object",
|
|
122
|
+
"properties": {
|
|
123
|
+
"project": {
|
|
124
|
+
"type": "string",
|
|
125
|
+
"description": "Project name where the files should be generated"
|
|
126
|
+
},
|
|
127
|
+
"feature": {
|
|
128
|
+
"type": "string",
|
|
129
|
+
"description": "Feature name where the files should be generated"
|
|
130
|
+
},
|
|
131
|
+
"overwrite": {
|
|
132
|
+
"anyOf": [
|
|
133
|
+
{
|
|
134
|
+
"type": "boolean"
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
"type": "array",
|
|
138
|
+
"items": {
|
|
139
|
+
"type": "string"
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
],
|
|
143
|
+
"description": "Overwrite existing files",
|
|
144
|
+
"default": false
|
|
145
|
+
},
|
|
146
|
+
"overwriteHtml": {
|
|
147
|
+
"type": "boolean",
|
|
148
|
+
"default": false
|
|
149
|
+
},
|
|
150
|
+
"replace": {
|
|
151
|
+
"type": "boolean",
|
|
152
|
+
"default": false
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"$id": "dialog-component-schematic",
|
|
4
4
|
"allOf": [
|
|
5
5
|
{
|
|
6
|
-
"$ref": "
|
|
6
|
+
"$ref": "#/definitions/angular"
|
|
7
7
|
},
|
|
8
8
|
{
|
|
9
9
|
"type": "object",
|
|
@@ -55,11 +55,8 @@
|
|
|
55
55
|
}
|
|
56
56
|
],
|
|
57
57
|
"definitions": {
|
|
58
|
-
"
|
|
59
|
-
"$ref": "../
|
|
60
|
-
},
|
|
61
|
-
"property": {
|
|
62
|
-
"$ref": "../property.schema.json"
|
|
58
|
+
"angular": {
|
|
59
|
+
"$ref": "../angular.schema.json"
|
|
63
60
|
}
|
|
64
61
|
}
|
|
65
62
|
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { NonNullableSelected, Normalized } from '@rxap/utilities';
|
|
2
|
+
import { WriterFunction } from 'ts-morph';
|
|
3
|
+
import { NormalizedTableSelectColumn, NormalizedTableSelectFormControl } from '../../../../lib/form/control/table-select-form-control';
|
|
4
|
+
import { NormalizedFormControlOptions } from '../../form-control';
|
|
5
|
+
import { AutocompleteTableSelectFormControlOptions } from './schema';
|
|
6
|
+
export type NormalizedTableSelectFormControlOptions = NonNullableSelected<Readonly<Normalized<Omit<AutocompleteTableSelectFormControlOptions, 'columnList' | 'propertyList'>>> & NormalizedFormControlOptions & NormalizedTableSelectFormControl, 'controllerName'>;
|
|
7
|
+
export declare function NormalizeTableSelectFormControlOptions(options: AutocompleteTableSelectFormControlOptions): NormalizedTableSelectFormControlOptions;
|
|
8
|
+
export declare function TableColumnToTableSelectColumn(column: NormalizedTableSelectColumn): WriterFunction;
|
|
9
|
+
export declare function TableColumnListToTableSelectColumnMap(columnList: Array<NormalizedTableSelectColumn>): WriterFunction;
|
|
10
|
+
export default function (options: AutocompleteTableSelectFormControlOptions): () => import("@angular-devkit/schematics").Rule;
|
|
@@ -0,0 +1,286 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TableColumnListToTableSelectColumnMap = exports.TableColumnToTableSelectColumn = exports.NormalizeTableSelectFormControlOptions = void 0;
|
|
4
|
+
const schematics_1 = require("@angular-devkit/schematics");
|
|
5
|
+
const schematics_ts_morph_1 = require("@rxap/schematics-ts-morph");
|
|
6
|
+
const schematics_utilities_1 = require("@rxap/schematics-utilities");
|
|
7
|
+
const ts_morph_1 = require("@rxap/ts-morph");
|
|
8
|
+
const utilities_1 = require("@rxap/utilities");
|
|
9
|
+
const path_1 = require("path");
|
|
10
|
+
const ts_morph_2 = require("ts-morph");
|
|
11
|
+
const angular_options_1 = require("../../../../lib/angular-options");
|
|
12
|
+
const table_select_form_control_1 = require("../../../../lib/form/control/table-select-form-control");
|
|
13
|
+
const form_control_1 = require("../../form-control");
|
|
14
|
+
function NormalizeTableSelectFormControlOptions(options) {
|
|
15
|
+
const normalizedOptions = (0, form_control_1.NormalizeFormControlOptions)(options);
|
|
16
|
+
return Object.freeze(Object.assign(Object.assign(Object.assign({}, normalizedOptions), (0, table_select_form_control_1.NormalizeTableSelectFormControl)(options)), { controllerName: (0, schematics_ts_morph_1.BuildNestControllerName)(normalizedOptions) }));
|
|
17
|
+
}
|
|
18
|
+
exports.NormalizeTableSelectFormControlOptions = NormalizeTableSelectFormControlOptions;
|
|
19
|
+
function TableColumnToTableSelectColumn(column) {
|
|
20
|
+
const { kind, name, title, hasFilter, } = column;
|
|
21
|
+
const properties = {};
|
|
22
|
+
properties['label'] = `$localize\`${title !== null && title !== void 0 ? title : (0, schematics_utilities_1.capitalize)(name)}\``;
|
|
23
|
+
if (hasFilter) {
|
|
24
|
+
properties['filter'] = 'true';
|
|
25
|
+
}
|
|
26
|
+
properties['type'] = (w) => w.quote(kind);
|
|
27
|
+
return ts_morph_2.Writers.object(properties);
|
|
28
|
+
}
|
|
29
|
+
exports.TableColumnToTableSelectColumn = TableColumnToTableSelectColumn;
|
|
30
|
+
function TableColumnListToTableSelectColumnMap(columnList) {
|
|
31
|
+
return ts_morph_2.Writers.object(columnList.reduce((properties, column) => (Object.assign(Object.assign({}, properties), { [column.name]: TableColumnToTableSelectColumn(column) })), {}));
|
|
32
|
+
}
|
|
33
|
+
exports.TableColumnListToTableSelectColumnMap = TableColumnListToTableSelectColumnMap;
|
|
34
|
+
function printOptions(options) {
|
|
35
|
+
(0, angular_options_1.PrintAngularOptions)('table-select-form-control', options);
|
|
36
|
+
}
|
|
37
|
+
function buildOptionsOperationName({ name }) {
|
|
38
|
+
return ['get', (0, schematics_utilities_1.dasherize)(name), 'control', 'table-select', 'page'].join('-');
|
|
39
|
+
}
|
|
40
|
+
function buildOptionsOperationPath({ name }) {
|
|
41
|
+
return ['control', (0, schematics_utilities_1.dasherize)(name), 'table-select', 'page'].join('/');
|
|
42
|
+
}
|
|
43
|
+
function buildOptionsOperationId(normalizedOptions) {
|
|
44
|
+
return (0, schematics_ts_morph_1.buildOperationId)(normalizedOptions, buildOptionsOperationName(normalizedOptions), (0, schematics_ts_morph_1.BuildNestControllerName)(normalizedOptions));
|
|
45
|
+
}
|
|
46
|
+
function buildDtoSuffix({ context, name }) {
|
|
47
|
+
return (0, utilities_1.joinWithDash)([context, (0, schematics_utilities_1.dasherize)(name), 'table-select']);
|
|
48
|
+
}
|
|
49
|
+
function autocompleteTableSelectResolveRule(normalizedOptions) {
|
|
50
|
+
const { name, project, feature, directory, formName, type, isArray, state, isRequired, validatorList, nestModule, controllerName, shared, context, scope, resolver, propertyList, toDisplay, toValue, role, isOptional, overwrite, identifier, source, } = normalizedOptions;
|
|
51
|
+
const { upstream } = resolver !== null && resolver !== void 0 ? resolver : {};
|
|
52
|
+
const resolveValueOperationName = ['resolve', (0, schematics_utilities_1.dasherize)(name), 'control', 'value'].join('-');
|
|
53
|
+
const resolveValueOperationPath = ['control', (0, schematics_utilities_1.dasherize)(name), 'resolve', ':value'].join('/');
|
|
54
|
+
const resolveValueOperationId = (0, schematics_ts_morph_1.buildOperationId)(normalizedOptions, resolveValueOperationName, (0, schematics_ts_morph_1.BuildNestControllerName)({
|
|
55
|
+
controllerName,
|
|
56
|
+
nestModule,
|
|
57
|
+
}));
|
|
58
|
+
return (0, schematics_1.chain)([
|
|
59
|
+
(0, schematics_ts_morph_1.CoerceAutocompleteTableSelectValueResolveOperationRule)({
|
|
60
|
+
project,
|
|
61
|
+
feature,
|
|
62
|
+
nestModule,
|
|
63
|
+
controllerName,
|
|
64
|
+
upstream,
|
|
65
|
+
overwrite,
|
|
66
|
+
propertyList: propertyList.slice(),
|
|
67
|
+
rowValueProperty: toValue.property,
|
|
68
|
+
rowDisplayProperty: toDisplay.property,
|
|
69
|
+
operationName: resolveValueOperationName,
|
|
70
|
+
path: resolveValueOperationPath,
|
|
71
|
+
dtoClassNameSuffix: (0, utilities_1.joinWithDash)([context, (0, schematics_utilities_1.dasherize)(name), 'control', 'options']),
|
|
72
|
+
context,
|
|
73
|
+
}),
|
|
74
|
+
(0, schematics_ts_morph_1.CoerceFormDefinitionControl)({
|
|
75
|
+
role,
|
|
76
|
+
isOptional,
|
|
77
|
+
source,
|
|
78
|
+
project,
|
|
79
|
+
feature,
|
|
80
|
+
directory,
|
|
81
|
+
formName,
|
|
82
|
+
name,
|
|
83
|
+
type,
|
|
84
|
+
isArray,
|
|
85
|
+
state,
|
|
86
|
+
isRequired,
|
|
87
|
+
validatorList,
|
|
88
|
+
coerceFormControl: (sourceFile, classDeclaration, formTypeName, control) => {
|
|
89
|
+
const { propertyDeclaration, decoratorDeclaration, } = (0, schematics_ts_morph_1.CoerceFormControl)(sourceFile, classDeclaration, formTypeName, control);
|
|
90
|
+
(0, ts_morph_1.CoerceDecorator)(propertyDeclaration, 'UseAutocompleteResolveMethod').set({
|
|
91
|
+
arguments: [
|
|
92
|
+
(0, ts_morph_1.OperationIdToRemoteMethodClassName)(resolveValueOperationId),
|
|
93
|
+
],
|
|
94
|
+
});
|
|
95
|
+
(0, ts_morph_1.CoerceImports)(sourceFile, {
|
|
96
|
+
namedImports: [(0, ts_morph_1.OperationIdToRemoteMethodClassName)(resolveValueOperationId)],
|
|
97
|
+
moduleSpecifier: (0, ts_morph_1.OperationIdToClassRemoteMethodImportPath)(resolveValueOperationId, scope)
|
|
98
|
+
});
|
|
99
|
+
(0, ts_morph_1.CoerceImports)(sourceFile, {
|
|
100
|
+
namedImports: [
|
|
101
|
+
'UseAutocompleteResolveMethod',
|
|
102
|
+
],
|
|
103
|
+
moduleSpecifier: 'autocomplete-table-select',
|
|
104
|
+
});
|
|
105
|
+
return {
|
|
106
|
+
propertyDeclaration,
|
|
107
|
+
decoratorDeclaration,
|
|
108
|
+
};
|
|
109
|
+
},
|
|
110
|
+
}),
|
|
111
|
+
]);
|
|
112
|
+
}
|
|
113
|
+
function autocompleteTableSelectOptionsRule(normalizedOptions) {
|
|
114
|
+
const { name, project, feature, directory, formName, type, isArray, state, isRequired, validatorList, nestModule, controllerName, shared, context, scope, upstream, propertyList, toDisplay, toValue, role, isOptional, identifier, overwrite, source, } = normalizedOptions;
|
|
115
|
+
const optionsOperationName = ['get', (0, schematics_utilities_1.dasherize)(name), 'control', 'options'].join('-');
|
|
116
|
+
const optionsOperationPath = ['control', (0, schematics_utilities_1.dasherize)(name), 'options'].join('/');
|
|
117
|
+
const optionsOperationId = (0, schematics_ts_morph_1.buildOperationId)(normalizedOptions, optionsOperationName, (0, schematics_ts_morph_1.BuildNestControllerName)({
|
|
118
|
+
controllerName,
|
|
119
|
+
nestModule,
|
|
120
|
+
}));
|
|
121
|
+
return (0, schematics_1.chain)([
|
|
122
|
+
(0, schematics_ts_morph_1.CoerceAutocompleteOptionsOperationRule)({
|
|
123
|
+
project,
|
|
124
|
+
feature,
|
|
125
|
+
nestModule,
|
|
126
|
+
controllerName,
|
|
127
|
+
upstream,
|
|
128
|
+
overwrite,
|
|
129
|
+
propertyList: propertyList.slice(),
|
|
130
|
+
toValueProperty: toValue.property,
|
|
131
|
+
toDisplayProperty: toDisplay.property,
|
|
132
|
+
operationName: optionsOperationName,
|
|
133
|
+
path: optionsOperationPath,
|
|
134
|
+
dtoClassNameSuffix: (0, utilities_1.joinWithDash)([context, (0, schematics_utilities_1.dasherize)(name), 'control', 'options']),
|
|
135
|
+
context,
|
|
136
|
+
}),
|
|
137
|
+
(0, schematics_ts_morph_1.CoerceFormDefinitionControl)({
|
|
138
|
+
role,
|
|
139
|
+
isOptional,
|
|
140
|
+
source,
|
|
141
|
+
project,
|
|
142
|
+
feature,
|
|
143
|
+
directory,
|
|
144
|
+
formName,
|
|
145
|
+
name,
|
|
146
|
+
type,
|
|
147
|
+
isArray,
|
|
148
|
+
state,
|
|
149
|
+
isRequired,
|
|
150
|
+
validatorList,
|
|
151
|
+
coerceFormControl: (sourceFile, classDeclaration, formTypeName, control) => {
|
|
152
|
+
const { propertyDeclaration, decoratorDeclaration, } = (0, schematics_ts_morph_1.CoerceFormControl)(sourceFile, classDeclaration, formTypeName, control);
|
|
153
|
+
(0, ts_morph_1.CoerceDecorator)(propertyDeclaration, 'UseAutocompleteOptionsMethod').set({
|
|
154
|
+
arguments: [
|
|
155
|
+
(0, schematics_ts_morph_1.OperationIdToClassName)(optionsOperationId),
|
|
156
|
+
],
|
|
157
|
+
});
|
|
158
|
+
(0, ts_morph_1.CoerceImports)(sourceFile, {
|
|
159
|
+
namedImports: [(0, schematics_ts_morph_1.OperationIdToClassName)(optionsOperationId)],
|
|
160
|
+
moduleSpecifier: (0, schematics_ts_morph_1.OperationIdToClassImportPath)(optionsOperationId, scope),
|
|
161
|
+
});
|
|
162
|
+
(0, ts_morph_1.CoerceImports)(sourceFile, {
|
|
163
|
+
namedImports: [
|
|
164
|
+
'UseAutocompleteOptionsMethod',
|
|
165
|
+
],
|
|
166
|
+
moduleSpecifier: 'autocomplete-table-select',
|
|
167
|
+
});
|
|
168
|
+
return {
|
|
169
|
+
propertyDeclaration,
|
|
170
|
+
decoratorDeclaration,
|
|
171
|
+
};
|
|
172
|
+
},
|
|
173
|
+
}),
|
|
174
|
+
]);
|
|
175
|
+
}
|
|
176
|
+
function tableSelectDataSourceRule(normalizedOptions) {
|
|
177
|
+
const { name, project, feature, directory, formName, type, isArray, state, isRequired, validatorList, nestModule, controllerName, columnList, shared, context, scope, toDisplay, toValue, propertyList, upstream, role, isOptional, identifier, overwrite, source, } = normalizedOptions;
|
|
178
|
+
const optionsOperationName = buildOptionsOperationName(normalizedOptions);
|
|
179
|
+
const optionsOperationPath = buildOptionsOperationPath(normalizedOptions);
|
|
180
|
+
const optionsOperationId = buildOptionsOperationId(normalizedOptions);
|
|
181
|
+
const tableDataSourceName = (0, schematics_utilities_1.classify)([(0, schematics_utilities_1.dasherize)(name), 'select-table', 'data-source'].join('-'));
|
|
182
|
+
const tableDataSourceImportPath = `./data-sources/${(0, schematics_utilities_1.dasherize)(name)}-select-table.data-source`;
|
|
183
|
+
const tableDataSourceDirectory = (0, path_1.join)(directory !== null && directory !== void 0 ? directory : '', 'data-sources');
|
|
184
|
+
return (0, schematics_1.chain)([
|
|
185
|
+
(0, schematics_ts_morph_1.CoerceTableSelectOperationRule)({
|
|
186
|
+
project,
|
|
187
|
+
feature,
|
|
188
|
+
nestModule,
|
|
189
|
+
controllerName,
|
|
190
|
+
overwrite,
|
|
191
|
+
propertyList: propertyList.slice(),
|
|
192
|
+
operationName: optionsOperationName,
|
|
193
|
+
path: optionsOperationPath,
|
|
194
|
+
dtoClassNameSuffix: buildDtoSuffix(normalizedOptions),
|
|
195
|
+
rowValueProperty: toValue.property,
|
|
196
|
+
rowDisplayProperty: toDisplay.property,
|
|
197
|
+
idProperty: identifier.property,
|
|
198
|
+
rowId: toValue.property,
|
|
199
|
+
context,
|
|
200
|
+
upstream
|
|
201
|
+
}),
|
|
202
|
+
(0, schematics_ts_morph_1.CoerceFormProviderRule)({
|
|
203
|
+
project,
|
|
204
|
+
feature,
|
|
205
|
+
directory,
|
|
206
|
+
providerObject: tableDataSourceName,
|
|
207
|
+
importStructures: [
|
|
208
|
+
{
|
|
209
|
+
namedImports: [tableDataSourceName],
|
|
210
|
+
moduleSpecifier: tableDataSourceImportPath,
|
|
211
|
+
},
|
|
212
|
+
],
|
|
213
|
+
}),
|
|
214
|
+
(0, schematics_ts_morph_1.CoerceTableDataSourceRule)({
|
|
215
|
+
scope,
|
|
216
|
+
project,
|
|
217
|
+
feature,
|
|
218
|
+
directory: tableDataSourceDirectory,
|
|
219
|
+
shared,
|
|
220
|
+
name: [(0, schematics_utilities_1.dasherize)(name), 'select-table'].join('-'),
|
|
221
|
+
operationId: optionsOperationId,
|
|
222
|
+
}),
|
|
223
|
+
(0, schematics_ts_morph_1.CoerceFormDefinitionControl)({
|
|
224
|
+
role,
|
|
225
|
+
isOptional,
|
|
226
|
+
source,
|
|
227
|
+
project,
|
|
228
|
+
feature,
|
|
229
|
+
directory,
|
|
230
|
+
formName,
|
|
231
|
+
name,
|
|
232
|
+
type,
|
|
233
|
+
isArray,
|
|
234
|
+
state,
|
|
235
|
+
isRequired,
|
|
236
|
+
validatorList,
|
|
237
|
+
coerceFormControl: (sourceFile, classDeclaration, formTypeName, control) => {
|
|
238
|
+
const { propertyDeclaration, decoratorDeclaration, } = (0, schematics_ts_morph_1.CoerceFormControl)(sourceFile, classDeclaration, formTypeName, control);
|
|
239
|
+
const tableSelectOperationResponseClassName = (0, ts_morph_1.OperationIdToResponseClassName)(optionsOperationId);
|
|
240
|
+
(0, ts_morph_1.CoerceImports)(sourceFile, {
|
|
241
|
+
namedImports: [tableSelectOperationResponseClassName],
|
|
242
|
+
moduleSpecifier: (0, ts_morph_1.OperationIdToResponseClassImportPath)(optionsOperationId),
|
|
243
|
+
});
|
|
244
|
+
(0, ts_morph_1.CoerceDecorator)(propertyDeclaration, 'UseTableSelectDataSource').set({
|
|
245
|
+
arguments: [tableDataSourceName],
|
|
246
|
+
});
|
|
247
|
+
(0, ts_morph_1.CoerceDecorator)(propertyDeclaration, 'UseTableSelectColumns').set({
|
|
248
|
+
arguments: [TableColumnListToTableSelectColumnMap(columnList)],
|
|
249
|
+
});
|
|
250
|
+
(0, ts_morph_1.CoerceImports)(sourceFile, {
|
|
251
|
+
namedImports: [tableDataSourceName],
|
|
252
|
+
moduleSpecifier: tableDataSourceImportPath,
|
|
253
|
+
});
|
|
254
|
+
(0, ts_morph_1.CoerceImports)(sourceFile, {
|
|
255
|
+
namedImports: [
|
|
256
|
+
'UseTableSelectDataSource',
|
|
257
|
+
'UseTableSelectColumns',
|
|
258
|
+
'UseTableSelectToDisplay',
|
|
259
|
+
'UseTableSelectToValue'
|
|
260
|
+
],
|
|
261
|
+
moduleSpecifier: '@rxap/ngx-material-table-select',
|
|
262
|
+
});
|
|
263
|
+
return {
|
|
264
|
+
propertyDeclaration,
|
|
265
|
+
decoratorDeclaration,
|
|
266
|
+
};
|
|
267
|
+
},
|
|
268
|
+
}),
|
|
269
|
+
]);
|
|
270
|
+
}
|
|
271
|
+
function default_1(options) {
|
|
272
|
+
const normalizedOptions = NormalizeTableSelectFormControlOptions(options);
|
|
273
|
+
printOptions(normalizedOptions);
|
|
274
|
+
return () => {
|
|
275
|
+
return (0, schematics_1.chain)([
|
|
276
|
+
() => console.group('[@rxap/schematics-angular:autocomplete-table-select-form-control]'.green),
|
|
277
|
+
tableSelectDataSourceRule(normalizedOptions),
|
|
278
|
+
autocompleteTableSelectResolveRule(normalizedOptions),
|
|
279
|
+
autocompleteTableSelectOptionsRule(normalizedOptions),
|
|
280
|
+
(0, schematics_ts_morph_1.EnforceUseFormControlOrderRule)(normalizedOptions),
|
|
281
|
+
() => console.groupEnd(),
|
|
282
|
+
]);
|
|
283
|
+
};
|
|
284
|
+
}
|
|
285
|
+
exports.default = default_1;
|
|
286
|
+
//# sourceMappingURL=index.js.map
|