@rxap/schematic-angular 16.1.0-dev.9 → 16.1.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 +346 -0
- package/README.md +1 -1
- package/collection.json +5 -0
- package/package.json +47 -41
- package/src/lib/accordion-item.d.ts +2 -2
- package/src/lib/accordion-item.js +4 -4
- package/src/lib/accordion-item.js.map +1 -1
- package/src/lib/adapter-options.d.ts +11 -5
- package/src/lib/adapter-options.js +8 -5
- package/src/lib/adapter-options.js.map +1 -1
- package/src/lib/angular-options.js +1 -1
- package/src/lib/angular-options.js.map +1 -1
- package/src/lib/data-grid-item.d.ts +1 -1
- package/src/lib/data-grid-item.js +2 -2
- package/src/lib/data-grid-item.js.map +1 -1
- package/src/lib/data-grid-options.d.ts +3 -3
- package/src/lib/data-grid-options.js +1 -1
- package/src/lib/data-grid-options.js.map +1 -1
- package/src/lib/dialog-action.d.ts +1 -1
- package/src/lib/dialog-action.js +2 -2
- package/src/lib/dialog-action.js.map +1 -1
- package/src/lib/existing-method.d.ts +11 -2
- package/src/lib/existing-method.js +8 -2
- package/src/lib/existing-method.js.map +1 -1
- package/src/lib/form-component-control.d.ts +1 -1
- package/src/lib/form-component-control.js +2 -2
- package/src/lib/form-component-control.js.map +1 -1
- package/src/lib/form-definition-control.d.ts +1 -1
- package/src/lib/form-definition-control.js +6 -4
- package/src/lib/form-definition-control.js.map +1 -1
- package/src/lib/minimum-table-component-options.d.ts +5 -3
- package/src/lib/minimum-table-component-options.js +85 -27
- package/src/lib/minimum-table-component-options.js.map +1 -1
- package/src/lib/minimum-table-options.d.ts +9 -6
- package/src/lib/minimum-table-options.js +7 -4
- package/src/lib/minimum-table-options.js.map +1 -1
- package/src/lib/table-action.d.ts +1 -1
- package/src/lib/table-action.js +11 -5
- package/src/lib/table-action.js.map +1 -1
- package/src/lib/table-column.d.ts +16 -4
- package/src/lib/table-column.js +93 -6
- package/src/lib/table-column.js.map +1 -1
- package/src/lib/table-header-button.d.ts +4 -6
- package/src/lib/table-header-button.js +2 -1
- package/src/lib/table-header-button.js.map +1 -1
- package/src/lib/table-open-api-options.d.ts +3 -2
- package/src/lib/table-open-api-options.js +1 -1
- package/src/lib/table-open-api-options.js.map +1 -1
- package/src/lib/table-options.d.ts +9 -5
- package/src/lib/table-options.js +1 -1
- package/src/lib/table-options.js.map +1 -1
- package/src/lib/table-property.d.ts +14 -0
- package/src/lib/table-property.js +46 -0
- package/src/lib/table-property.js.map +1 -0
- package/src/lib/table-row-action.d.ts +5 -1
- package/src/lib/table-row-action.js +9 -7
- package/src/lib/table-row-action.js.map +1 -1
- package/src/lib/tree-table-options.d.ts +10 -6
- package/src/lib/tree-table-options.js +2 -2
- package/src/lib/tree-table-options.js.map +1 -1
- package/src/lib/type-import.d.ts +4 -0
- package/src/lib/type-import.js +38 -0
- package/src/lib/type-import.js.map +1 -0
- package/src/schematics/accordion/accordion-component/files/component/__componentName__.component.ts.template +1 -1
- package/src/schematics/accordion/accordion-component/index.d.ts +3 -1
- package/src/schematics/accordion/accordion-component/index.js +2 -2
- package/src/schematics/accordion/accordion-component/index.js.map +1 -1
- package/src/schematics/accordion/accordion-component/schema.json +13 -3
- package/src/schematics/accordion/accordion-item-component/files/component/__componentName__.component.html.template +1 -1
- package/src/schematics/accordion/accordion-item-component/index.js +2 -2
- package/src/schematics/accordion/accordion-item-component/index.js.map +1 -1
- package/src/schematics/accordion/accordion-item-component/schema.json +13 -3
- package/src/schematics/accordion/item/accordion-item-data-grid-component/index.d.ts +3 -3
- package/src/schematics/accordion/item/accordion-item-data-grid-component/index.js +5 -5
- 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 +13 -3
- package/src/schematics/accordion/item/accordion-item-table-component/index.d.ts +7 -4
- package/src/schematics/accordion/item/accordion-item-table-component/index.js +5 -5
- 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 +57 -8
- package/src/schematics/accordion/item/accordion-item-tree-table-component/index.d.ts +4 -1
- package/src/schematics/accordion/item/accordion-item-tree-table-component/index.js +1 -1
- 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 +62 -9
- package/src/schematics/angular.schema.json +61 -0
- package/src/schematics/data-grid-component/index.d.ts +1 -1
- package/src/schematics/data-grid-component/index.js +1 -1
- package/src/schematics/data-grid-component/index.js.map +1 -1
- package/src/schematics/data-grid-component/schema.json +13 -3
- package/src/schematics/dialog-component/index.js +3 -3
- package/src/schematics/dialog-component/index.js.map +1 -1
- package/src/schematics/dialog-component/schema.json +13 -3
- package/src/schematics/form/control/input-form-control/index.js +1 -1
- package/src/schematics/form/control/input-form-control/index.js.map +1 -1
- package/src/schematics/form/control/select-form-control/index.js +1 -1
- package/src/schematics/form/control/select-form-control/index.js.map +1 -1
- package/src/schematics/form/control/table-select-form-control/index.d.ts +2 -2
- package/src/schematics/form/control/table-select-form-control/index.js +3 -3
- package/src/schematics/form/control/table-select-form-control/index.js.map +1 -1
- package/src/schematics/form/form-component/index.d.ts +1 -1
- package/src/schematics/form/form-component/index.js +1 -1
- package/src/schematics/form/form-component/index.js.map +1 -1
- package/src/schematics/form/form-control/index.js +1 -1
- package/src/schematics/form/form-control/index.js.map +1 -1
- package/src/schematics/form/form-definition/index.d.ts +2 -2
- package/src/schematics/form/form-definition/index.js +16 -9
- package/src/schematics/form/form-definition/index.js.map +1 -1
- package/src/schematics/form/form-definition/schema.d.ts +2 -1
- package/src/schematics/form/form-definition/schema.json +5 -0
- package/src/schematics/general.schema.json +41 -0
- package/src/schematics/table/action/dialog-table-action/index.d.ts +3 -1
- package/src/schematics/table/action/dialog-table-action/index.js +1 -1
- package/src/schematics/table/action/dialog-table-action/index.js.map +1 -1
- package/src/schematics/table/action/dialog-table-action/schema.json +12 -2
- package/src/schematics/table/action/form-table-action/index.d.ts +6 -3
- package/src/schematics/table/action/form-table-action/index.js +46 -18
- package/src/schematics/table/action/form-table-action/index.js.map +1 -1
- package/src/schematics/table/action/form-table-action/schema.d.ts +13 -1
- package/src/schematics/table/action/form-table-action/schema.json +71 -3
- package/src/schematics/table/action/navigation-table-action/index.js +4 -3
- package/src/schematics/table/action/navigation-table-action/index.js.map +1 -1
- package/src/schematics/table/action/navigation-table-action/schema.d.ts +1 -0
- package/src/schematics/table/action/navigation-table-action/schema.json +5 -0
- package/src/schematics/table/action/open-api-table-action/index.d.ts +10 -0
- package/src/schematics/table/action/open-api-table-action/index.js +50 -0
- package/src/schematics/table/action/open-api-table-action/index.js.map +1 -0
- package/src/schematics/table/action/open-api-table-action/schema.d.ts +9 -0
- package/src/schematics/table/action/open-api-table-action/schema.json +121 -0
- package/src/schematics/table/action/operation-table-action/index.js +1 -1
- package/src/schematics/table/action/operation-table-action/index.js.map +1 -1
- package/src/schematics/table/header-button/form-table-header-button/index.d.ts +10 -3
- package/src/schematics/table/header-button/form-table-header-button/index.js +57 -48
- 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 +8 -0
- package/src/schematics/table/header-button/form-table-header-button/schema.json +17 -1
- package/src/schematics/table/header-button/navigation-table-header-button/index.js +30 -8
- package/src/schematics/table/header-button/navigation-table-header-button/index.js.map +1 -1
- package/src/schematics/table/header-button/navigation-table-header-button/schema.d.ts +1 -0
- package/src/schematics/table/header-button/navigation-table-header-button/schema.json +8 -6
- package/src/schematics/table/table-action/index.js +1 -1
- package/src/schematics/table/table-action/index.js.map +1 -1
- package/src/schematics/table/table-action/schema.json +8 -0
- package/src/schematics/table/table-component/files/component/__componentName__.component.html.template +31 -40
- package/src/schematics/table/table-component/files/component/__componentName__.component.ts.template +17 -3
- package/src/schematics/table/table-component/index.d.ts +6 -8
- package/src/schematics/table/table-component/index.js +41 -28
- package/src/schematics/table/table-component/index.js.map +1 -1
- package/src/schematics/table/table-component/schema.json +267 -218
- package/src/schematics/table/table-header-button/index.d.ts +2 -4
- package/src/schematics/table/table-header-button/index.js +1 -1
- package/src/schematics/table/table-header-button/index.js.map +1 -1
- package/src/schematics/table/table-header-button/schema.d.ts +2 -1
- package/src/schematics/table/tree-table-component/files/component/__componentName__.component.html.template +94 -82
- package/src/schematics/table/tree-table-component/files/component/__componentName__.component.ts.template +17 -4
- package/src/schematics/table/tree-table-component/index.d.ts +1 -1
- package/src/schematics/table/tree-table-component/index.js +19 -24
- package/src/schematics/table/tree-table-component/index.js.map +1 -1
- package/src/schematics/table/tree-table-component/schema.json +60 -7
- package/src/schematics/tree-component/index.d.ts +2 -2
- package/src/schematics/tree-component/index.js +2 -2
- package/src/schematics/tree-component/index.js.map +1 -1
- package/src/schematics/tree-component/schema.json +11 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<div class="flex flex-col gap-y-4 m-4">
|
|
2
2
|
<% if (hasNavigationBackHeader) { %>
|
|
3
3
|
<rxap-navigate-back-button>
|
|
4
|
-
<h1 i18n><%=
|
|
4
|
+
<h1 i18n><%= title %></h1>
|
|
5
5
|
</rxap-navigate-back-button>
|
|
6
6
|
<mat-divider></mat-divider>
|
|
7
7
|
<% } %>
|
|
@@ -12,29 +12,28 @@
|
|
|
12
12
|
rxapCardProgressBar
|
|
13
13
|
[loading$]="tableDataSourceDirective.loading$"
|
|
14
14
|
></mat-progress-bar>
|
|
15
|
-
<mat-card-header class="min-h-full h-12">
|
|
16
|
-
<% if (!
|
|
17
|
-
<mat-card-title i18n><%=
|
|
15
|
+
<mat-card-header class="min-h-full h-12<% if (!headerButton && hasWithoutTitle) { %> justify-end<% } %>">
|
|
16
|
+
<% if (!hasWithoutTitle) { %>
|
|
17
|
+
<mat-card-title i18n><%= title %></mat-card-title>
|
|
18
18
|
<% } %>
|
|
19
19
|
<% if (headerButton) { %>
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
>
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
<rxap-table-column-menu matCard #rxapTableColumns="rxapTableColumns" [ngClass]="{ 'hidden': tableDataSourceDirective.hasError$ | async }">
|
|
35
|
-
<rxap-table-column-option hidden name="tree"></rxap-table-column-option>
|
|
20
|
+
<button
|
|
21
|
+
mat-card-avatar
|
|
22
|
+
mat-mini-fab
|
|
23
|
+
color="primary"
|
|
24
|
+
matTooltip
|
|
25
|
+
[disabled]="tableDataSourceDirective.hasError$ | async"
|
|
26
|
+
[rxapTableHeaderButton]="tableDataSourceDirective"
|
|
27
|
+
<% if (headerButton.permission) { %>rxapHasEnablePermission="<%= headerButton.permission %>"<% } %>
|
|
28
|
+
>
|
|
29
|
+
<% if (headerButton.icon) { %><mat-icon><%= headerButton.icon %></mat-icon><% } else if (headerButton.svgIcon) { %><mat-icon svgIcon="<%= headerButton.svgIcon %>"></mat-icon><% } else { %><mat-icon>add</mat-icon><% } %>
|
|
30
|
+
</button>
|
|
31
|
+
<mat-card-subtitle i18n><%= headerButton.label %></mat-card-subtitle>
|
|
32
|
+
<% } %>
|
|
33
|
+
<rxap-table-column-menu matCard #rxapTableColumns="rxapTableColumns" <% if (!headerButton && hasWithoutTitle) { %>inline<% } %>>
|
|
36
34
|
<% for (const column of columnList) { %>
|
|
37
|
-
<rxap-table-column-option
|
|
35
|
+
<rxap-table-column-option
|
|
36
|
+
name="<%= column.name %>"<% if (column.active) { %><%= ' active' %><% } %><% if (column.hidden) { %><%= ' hidden' %><% } %><% if (column.inactive) { %><%= ' inactive' %><% } %><% if (column.show) { %><%= ' show' %><% } %>>
|
|
38
37
|
<ng-container i18n><%= column.title %></ng-container>
|
|
39
38
|
</rxap-table-column-option>
|
|
40
39
|
<% } %>
|
|
@@ -48,7 +47,7 @@
|
|
|
48
47
|
<rxap-table-show-archived-slide></rxap-table-show-archived-slide>
|
|
49
48
|
</span>
|
|
50
49
|
</rxap-table-column-menu>
|
|
51
|
-
|
|
50
|
+
</mat-card-header>
|
|
52
51
|
|
|
53
52
|
<mat-card-content>
|
|
54
53
|
<rxap-data-source-error
|
|
@@ -57,7 +56,7 @@
|
|
|
57
56
|
*ngIf="tableDataSourceDirective.hasError$ | async"
|
|
58
57
|
[refresh]="tableDataSourceDirective.retry">
|
|
59
58
|
</rxap-data-source-error>
|
|
60
|
-
<div class="table-scroll-container mt-4 overflow-x-auto overscroll-
|
|
59
|
+
<div class="table-scroll-container mt-4 overflow-x-auto overscroll-auto">
|
|
61
60
|
<table
|
|
62
61
|
[ngClass]="{ 'hidden': tableDataSourceDirective.hasError$ | async }"
|
|
63
62
|
matSort
|
|
@@ -69,71 +68,104 @@
|
|
|
69
68
|
>
|
|
70
69
|
<!-- region columns -->
|
|
71
70
|
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
71
|
+
<% if (actionList.length) { %>
|
|
72
|
+
<ng-container matColumnDef="actions" stickyEnd>
|
|
73
|
+
<th mat-header-cell *matHeaderCellDef>
|
|
74
|
+
<% if (selectColumn) { %>
|
|
75
|
+
<div class="flex flex-row" *rxapSelectedRows="let selected">
|
|
76
|
+
<% for (const action of actionList) { %>
|
|
77
|
+
<% if (action.inHeader) { %>
|
|
78
|
+
<button
|
|
79
|
+
rxapTableRowHeaderAction="<%= action.type %>"
|
|
80
|
+
mat-icon-button
|
|
81
|
+
<% if (action.color) { %>color="<%= action.color %>"<% } %>
|
|
82
|
+
<% if (action.cssClass) { %>class="<%= action.cssClass %>"<% } %>
|
|
83
|
+
*ngIf="selected | rxapRowActionCheck:'<%= action.type %>'"
|
|
84
|
+
<% if (action.permission) { %>rxapHasEnablePermission="<%= action.permission %>"<% } %>
|
|
85
|
+
matTooltip
|
|
86
|
+
>
|
|
87
|
+
<% if (action.icon) { %><mat-icon><%= action.icon %></mat-icon><% } else if (action.svgIcon) { %><mat-icon svgIcon="<%= action.svgIcon %>"></mat-icon><% } else { %><mat-icon><%= action.type %></mat-icon><% } %>
|
|
88
|
+
<mat-progress-bar
|
|
89
|
+
*rxapTableRowActionExecuting
|
|
90
|
+
mode="indeterminate"
|
|
91
|
+
></mat-progress-bar>
|
|
92
|
+
</button>
|
|
93
|
+
<% } %>
|
|
94
|
+
<% } %>
|
|
95
|
+
</div>
|
|
96
|
+
<% } %>
|
|
75
97
|
</th>
|
|
76
98
|
|
|
77
|
-
<td mat-cell *matCellDef="let element">
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
99
|
+
<td mat-cell *matCellDef="let element">
|
|
100
|
+
<div class="flex flex-row">
|
|
101
|
+
<% for (const action of actionList) { %>
|
|
102
|
+
<button
|
|
103
|
+
rxapTableRowAction="<%= action.type %>"
|
|
104
|
+
[element]="element"
|
|
105
|
+
<% if (action.color) { %>color="<%= action.color %>"<% } %>
|
|
106
|
+
<% if (action.cssClass) { %>class="<%= action.cssClass %>"<% } %>
|
|
107
|
+
mat-icon-button
|
|
108
|
+
*ngIf="element | rxapRowActionCheck:'<%= action.type %>'"
|
|
109
|
+
<% if (action.permission) { %>rxapHasEnablePermission="<%= action.permission %>"<% } %>
|
|
110
|
+
matTooltip
|
|
111
|
+
>
|
|
112
|
+
<% if (action.icon) { %><mat-icon><%= action.icon %></mat-icon><% } else if (action.svgIcon) { %><mat-icon svgIcon="<%= action.svgIcon %>"></mat-icon><% } else { %><mat-icon><%= action.type %></mat-icon><% } %>
|
|
113
|
+
<mat-progress-bar
|
|
114
|
+
*rxapTableRowActionExecuting
|
|
115
|
+
mode="indeterminate"
|
|
116
|
+
></mat-progress-bar>
|
|
117
|
+
</button>
|
|
118
|
+
<% } %>
|
|
119
|
+
</div>
|
|
120
|
+
</td>
|
|
87
121
|
</ng-container>
|
|
88
|
-
|
|
122
|
+
<% } %>
|
|
89
123
|
<% for (const column of columnList) { %>
|
|
90
|
-
<% if (column.
|
|
124
|
+
<% if (column.role === 'copy-to-clipboard') { %>
|
|
91
125
|
<ng-container matColumnDef="<%= column.name %>">
|
|
92
126
|
<th mat-header-cell *matHeaderCellDef mat-sort-header>
|
|
93
127
|
<ng-container i18n><%= column.title %></ng-container>
|
|
94
128
|
</th>
|
|
95
|
-
|
|
96
|
-
<td mat-cell *matCellDef="let element">{{ element?.<%= column.propertyPath %> }}</td>
|
|
129
|
+
<td *matCellDef="let element" mat-cell <% if (column.cssClass) { %>class="<%= column.cssClass %>"<% } %> [rxap-copy-to-clipboard-cell]="element?.<%= column.propertyPath %>"></td>
|
|
97
130
|
</ng-container>
|
|
98
|
-
<% } else if (column.
|
|
131
|
+
<% } else if (column.role === 'link') { %>
|
|
99
132
|
<ng-container matColumnDef="<%= column.name %>">
|
|
100
133
|
<th mat-header-cell *matHeaderCellDef mat-sort-header>
|
|
101
134
|
<ng-container i18n><%= column.title %></ng-container>
|
|
102
135
|
</th>
|
|
103
|
-
|
|
104
|
-
<td *matCellDef="let element" [rxap-link-cell]="element?.<%= column.propertyPath %>"></td>
|
|
136
|
+
<td *matCellDef="let element" mat-cell <% if (column.cssClass) { %>class="<%= column.cssClass %>"<% } %> [rxap-link-cell]="element?.<%= column.propertyPath %>"></td>
|
|
105
137
|
</ng-container>
|
|
106
|
-
<% } else if (column.
|
|
138
|
+
<% } else if (column.role === 'date') { %>
|
|
107
139
|
<ng-container matColumnDef="<%= column.name %>">
|
|
108
140
|
<th mat-header-cell *matHeaderCellDef mat-sort-header>
|
|
109
141
|
<ng-container i18n><%= column.title %></ng-container>
|
|
110
142
|
</th>
|
|
111
143
|
|
|
112
|
-
<td *matCellDef="let element" [rxap-date-cell]="element?.<%= column.propertyPath %>"></td>
|
|
144
|
+
<td *matCellDef="let element" mat-cell <% if (column.cssClass) { %>class="<%= column.cssClass %>"<% } %> [rxap-date-cell]="element?.<%= column.propertyPath %>" format="dd.MM.yyyy HH:mm:ss"></td>
|
|
113
145
|
</ng-container>
|
|
114
|
-
<% } else if (column.
|
|
146
|
+
<% } else if (column.role === 'boolean') { %>
|
|
115
147
|
<ng-container matColumnDef="<%= column.name %>">
|
|
116
148
|
<th mat-header-cell *matHeaderCellDef mat-sort-header>
|
|
117
149
|
<ng-container i18n><%= column.title %></ng-container>
|
|
118
150
|
</th>
|
|
119
151
|
|
|
120
|
-
<td *matCellDef="let element" [rxap-boolean-cell]="element?.<%= column.propertyPath %>"></td>
|
|
152
|
+
<td *matCellDef="let element" mat-cell <% if (column.cssClass) { %>class="<%= column.cssClass %>"<% } %> [rxap-boolean-cell]="element?.<%= column.propertyPath %>"></td>
|
|
121
153
|
</ng-container>
|
|
122
|
-
<% } else if (column.
|
|
154
|
+
<% } else if (column.role === 'icon') { %>
|
|
123
155
|
<ng-container matColumnDef="<%= column.name %>">
|
|
124
156
|
<th mat-header-cell *matHeaderCellDef mat-sort-header>
|
|
125
157
|
<ng-container i18n><%= column.title %></ng-container>
|
|
126
158
|
</th>
|
|
127
159
|
|
|
128
|
-
<td *matCellDef="let element" [rxap-icon-cell]="element?.<%= column.propertyPath %>"></td>
|
|
160
|
+
<td *matCellDef="let element" mat-cell <% if (column.cssClass) { %>class="<%= column.cssClass %>"<% } %> [rxap-icon-cell]="element?.<%= column.propertyPath %>"></td>
|
|
129
161
|
</ng-container>
|
|
130
|
-
<% } else if (column.
|
|
162
|
+
<% } else if (column.role === 'component') { %>
|
|
131
163
|
<ng-container matColumnDef="<%= column.name %>">
|
|
132
164
|
<th mat-header-cell *matHeaderCellDef mat-sort-header>
|
|
133
165
|
<ng-container i18n><%= column.title %></ng-container>
|
|
134
166
|
</th>
|
|
135
167
|
|
|
136
|
-
<td *matCellDef="let element"
|
|
168
|
+
<td *matCellDef="let element" mat-cell <% if (column.cssClass) { %>class="<%= column.cssClass %>"<% } %> <%= prefix %>-<%= column.name %>-cell [element]="element" [value]="element?.<%= column.propertyPath %>"></td>
|
|
137
169
|
</ng-container>
|
|
138
170
|
<% } else { %>
|
|
139
171
|
<ng-container matColumnDef="<%= column.name %>">
|
|
@@ -141,39 +173,19 @@
|
|
|
141
173
|
<ng-container i18n><%= column.title %></ng-container>
|
|
142
174
|
</th>
|
|
143
175
|
|
|
144
|
-
<td mat-cell
|
|
176
|
+
<td mat-cell <% if (column.cssClass) { %>class="<%= column.cssClass %>"<% } %> *matCellDef="let element">
|
|
177
|
+
<% if (column.template) { %>
|
|
178
|
+
<%= column.template %>
|
|
179
|
+
<% } else if (column.pipeList.length) { %>
|
|
180
|
+
{{ element?.<%= column.propertyPath %><% for (const pipe of column.pipeList) { %> | <%= pipe.name %><% } %> }}
|
|
181
|
+
<% } else { %>
|
|
182
|
+
{{ element?.<%= column.propertyPath %> }}
|
|
183
|
+
<% } %>
|
|
184
|
+
</td>
|
|
145
185
|
</ng-container>
|
|
146
186
|
<% } %>
|
|
147
187
|
<% } %>
|
|
148
188
|
|
|
149
|
-
<% if (actionList.length) { %>
|
|
150
|
-
<ng-container matColumnDef="actions" stickyEnd>
|
|
151
|
-
<th mat-header-cell *matHeaderCellDef></th>
|
|
152
|
-
|
|
153
|
-
<td mat-cell *matCellDef="let element">
|
|
154
|
-
<div class="flex flex-row">
|
|
155
|
-
<% for (const action of actionList) { %>
|
|
156
|
-
<button
|
|
157
|
-
rxapTableRowAction="<%= action.type %>"
|
|
158
|
-
[element]="element"
|
|
159
|
-
mat-icon-button
|
|
160
|
-
*ngIf="element | rxapRowActionCheck:'<%= action.type %>'"
|
|
161
|
-
<% if (action.permission) { %>rxapHasEnablePermission="<%= action.permission %>"<% } %>
|
|
162
|
-
matTooltip="<%= action.type %>"
|
|
163
|
-
i18n-matTooltip
|
|
164
|
-
>
|
|
165
|
-
<% if (action.icon) { %><mat-icon><%= action.icon %></mat-icon><% } else if (action.svgIcon) { %><mat-icon svgIcon="<%= action.svgIcon %>"></mat-icon><% } else { %><mat-icon><%= action.type %></mat-icon><% } %>
|
|
166
|
-
<mat-progress-bar
|
|
167
|
-
*rxapTableRowActionExecuting
|
|
168
|
-
mode="indeterminate"
|
|
169
|
-
></mat-progress-bar>
|
|
170
|
-
</button>
|
|
171
|
-
<% } %>
|
|
172
|
-
</div>
|
|
173
|
-
</td>
|
|
174
|
-
</ng-container>
|
|
175
|
-
<% } %>
|
|
176
|
-
|
|
177
189
|
<!-- endregion -->
|
|
178
190
|
|
|
179
191
|
<tr
|
|
@@ -182,10 +194,10 @@
|
|
|
182
194
|
></tr>
|
|
183
195
|
|
|
184
196
|
<tr
|
|
185
|
-
[@rowsAnimation]
|
|
197
|
+
[@rowsAnimation]=""
|
|
186
198
|
mat-row
|
|
187
199
|
[ngClass]="{ 'rxap-row-odd !bg-neutral-200 dark:!bg-neutral-600': odd, 'rxap-row-even': even }"
|
|
188
|
-
|
|
200
|
+
class="hover:!bg-neutral-400 dark:hover:!bg-neutral-800"
|
|
189
201
|
*matRowDef="
|
|
190
202
|
let element;
|
|
191
203
|
columns: rxapTableColumns.displayColumns;
|
|
@@ -14,7 +14,6 @@ import {
|
|
|
14
14
|
TableColumnMenuModule, TableCreateButtonDirective,
|
|
15
15
|
TableDataSourceDirective,
|
|
16
16
|
TableFilterModule, TableRowActionsModule,
|
|
17
|
-
TableRowControlsModule,
|
|
18
17
|
} from '@rxap/material-table-system';
|
|
19
18
|
import { MatCardModule } from '@angular/material/card';
|
|
20
19
|
import { MatProgressBarModule } from '@angular/material/progress-bar';
|
|
@@ -40,7 +39,14 @@ import { CommonModule } from '@angular/common';
|
|
|
40
39
|
import { DataSourceErrorComponent } from '@rxap/data-source';
|
|
41
40
|
import { MatCheckboxModule } from '@angular/material/checkbox';
|
|
42
41
|
import { MatSnackBarModule } from '@angular/material/snack-bar';
|
|
43
|
-
|
|
42
|
+
<% for (const column of columnList) { %>
|
|
43
|
+
<% if (column.role === 'component') { %>
|
|
44
|
+
import { <%= classify(column.name) %>CellComponent } from './<%= dasherize(column.name) %>-cell/<%= dasherize(column.name) %>-cell.component';
|
|
45
|
+
<% } %>
|
|
46
|
+
<% for (const pipe of column.pipeList) { %>
|
|
47
|
+
import { <%= pipe.namedImport %> } from '<%= pipe.moduleSpecifier %>';
|
|
48
|
+
<% } %>
|
|
49
|
+
<% } %>
|
|
44
50
|
|
|
45
51
|
@Component({
|
|
46
52
|
selector: '<%= prefix %>-<%= name %>-table',
|
|
@@ -50,6 +56,14 @@ import { MatSnackBarModule } from '@angular/material/snack-bar';
|
|
|
50
56
|
animations: [ RowAnimation ],
|
|
51
57
|
standalone: true,
|
|
52
58
|
imports: [
|
|
59
|
+
<% for (const column of columnList) { %>
|
|
60
|
+
<% if (column.role === 'component') { %>
|
|
61
|
+
<%= classify(column.name) %>CellComponent,
|
|
62
|
+
<% } %>
|
|
63
|
+
<% for (const pipe of column.pipeList) { %>
|
|
64
|
+
<%= pipe.namedImport %>,
|
|
65
|
+
<% } %>
|
|
66
|
+
<% } %>
|
|
53
67
|
CommonModule,
|
|
54
68
|
MatCardModule,
|
|
55
69
|
MatProgressBarModule,
|
|
@@ -66,7 +80,6 @@ import { MatSnackBarModule } from '@angular/material/snack-bar';
|
|
|
66
80
|
<% if (hasNavigationBackHeader) { %>
|
|
67
81
|
NavigateBackButtonComponent,
|
|
68
82
|
<% } %>
|
|
69
|
-
TableRowControlsModule,
|
|
70
83
|
TableColumnMenuModule,
|
|
71
84
|
DateCellComponent,
|
|
72
85
|
|
|
@@ -99,4 +112,4 @@ export class <%= classify(componentName) %>Component {
|
|
|
99
112
|
|
|
100
113
|
}
|
|
101
114
|
|
|
102
|
-
export default <%= classify(componentName) %>Component
|
|
115
|
+
<% if (exportDefault) { %>export default <%= classify(componentName) %>Component;<% } %>
|
|
@@ -2,7 +2,7 @@ import { Normalized } from '@rxap/utilities';
|
|
|
2
2
|
import { NormalizedAngularOptions } from '../../../lib/angular-options';
|
|
3
3
|
import { NormalizedTreeTableOptions } from '../../../lib/tree-table-options';
|
|
4
4
|
import { TreeTableComponentOptions } from './schema';
|
|
5
|
-
export interface NormalizedTreeTableComponentOptions extends Readonly<Normalized<TreeTableComponentOptions
|
|
5
|
+
export interface NormalizedTreeTableComponentOptions extends Readonly<Normalized<Omit<TreeTableComponentOptions, keyof NormalizedTreeTableOptions>> & NormalizedTreeTableOptions & NormalizedAngularOptions> {
|
|
6
6
|
name: string;
|
|
7
7
|
controllerName: string;
|
|
8
8
|
}
|
|
@@ -3,6 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.NormalizedTreeTableComponentOptions = void 0;
|
|
4
4
|
const schematics_1 = require("@angular-devkit/schematics");
|
|
5
5
|
const schematics_ts_morph_1 = require("@rxap/schematics-ts-morph");
|
|
6
|
+
const ts_morph_1 = require("@rxap/ts-morph");
|
|
6
7
|
const utilities_1 = require("@rxap/utilities");
|
|
7
8
|
const angular_options_1 = require("../../../lib/angular-options");
|
|
8
9
|
const backend_types_1 = require("../../../lib/backend-types");
|
|
@@ -13,7 +14,7 @@ function NormalizedTreeTableComponentOptions(options) {
|
|
|
13
14
|
(0, angular_options_1.AssertAngularOptionsNameProperty)(normalizedMinimumTableComponentOptions);
|
|
14
15
|
const { name } = normalizedMinimumTableComponentOptions;
|
|
15
16
|
const normalizedTreeTableOptions = (0, tree_table_options_1.NormalizeTreeTableOptions)(options, name);
|
|
16
|
-
return Object.
|
|
17
|
+
return Object.freeze(Object.assign(Object.assign({}, normalizedMinimumTableComponentOptions), normalizedTreeTableOptions));
|
|
17
18
|
}
|
|
18
19
|
exports.NormalizedTreeTableComponentOptions = NormalizedTreeTableComponentOptions;
|
|
19
20
|
function printOptions(options) {
|
|
@@ -33,7 +34,7 @@ function printOptions(options) {
|
|
|
33
34
|
}
|
|
34
35
|
function componentRule(normalizedOptions) {
|
|
35
36
|
const { project, feature, shared, componentName, directory, overwrite, modifiers, columnList, } = normalizedOptions;
|
|
36
|
-
const templateOptions = Object.assign(Object.assign({}, normalizedOptions), { hasNavigationBackHeader: modifiers.includes('navigation-back-header'), hasWithoutTitle: modifiers.includes('without-title'), hasColumnWithFilter: columnList.some((c) => c.hasFilter) });
|
|
37
|
+
const templateOptions = Object.assign(Object.assign({}, normalizedOptions), { hasNavigationBackHeader: modifiers.includes('navigation-back-header'), hasWithoutTitle: modifiers.includes('without-title'), hasColumnWithFilter: columnList.some((c) => c.hasFilter), exportDefault: !!feature && !directory });
|
|
37
38
|
return (0, schematics_1.chain)([
|
|
38
39
|
() => console.log(`Coerce the table component ${componentName}`),
|
|
39
40
|
(0, schematics_ts_morph_1.CoerceComponentRule)({
|
|
@@ -114,12 +115,12 @@ function nestjsBackendRule(normalizedOptions) {
|
|
|
114
115
|
overwrite,
|
|
115
116
|
tsMorphTransform: (project, [sourceFile]) => {
|
|
116
117
|
(0, schematics_ts_morph_1.AddComponentProvider)(sourceFile, {
|
|
117
|
-
provide: '
|
|
118
|
+
provide: 'RXAP_TREE_TABLE_DATA_SOURCE_ROOT_METHOD',
|
|
118
119
|
useClass: 'TreeTableRootProxyMethod',
|
|
119
120
|
}, [
|
|
120
121
|
{
|
|
121
122
|
moduleSpecifier: '@rxap/data-source/table/tree',
|
|
122
|
-
namedImports: ['
|
|
123
|
+
namedImports: ['RXAP_TREE_TABLE_DATA_SOURCE_ROOT_METHOD'],
|
|
123
124
|
},
|
|
124
125
|
{
|
|
125
126
|
moduleSpecifier: './tree-table-root-proxy.method',
|
|
@@ -127,12 +128,12 @@ function nestjsBackendRule(normalizedOptions) {
|
|
|
127
128
|
},
|
|
128
129
|
]);
|
|
129
130
|
(0, schematics_ts_morph_1.AddComponentProvider)(sourceFile, {
|
|
130
|
-
provide: '
|
|
131
|
+
provide: 'RXAP_TREE_TABLE_DATA_SOURCE_CHILDREN_METHOD',
|
|
131
132
|
useClass: 'TreeTableChildrenProxyMethod',
|
|
132
133
|
}, [
|
|
133
134
|
{
|
|
134
135
|
moduleSpecifier: '@rxap/data-source/table/tree',
|
|
135
|
-
namedImports: ['
|
|
136
|
+
namedImports: ['RXAP_TREE_TABLE_DATA_SOURCE_CHILDREN_METHOD'],
|
|
136
137
|
},
|
|
137
138
|
{
|
|
138
139
|
moduleSpecifier: './tree-table-children-proxy.method',
|
|
@@ -155,12 +156,12 @@ function localBackendRule(normalizedOptions) {
|
|
|
155
156
|
overwrite,
|
|
156
157
|
tsMorphTransform: (project, [sourceFile]) => {
|
|
157
158
|
(0, schematics_ts_morph_1.AddComponentProvider)(sourceFile, {
|
|
158
|
-
provide: '
|
|
159
|
+
provide: 'RXAP_TREE_TABLE_DATA_SOURCE_ROOT_METHOD',
|
|
159
160
|
useClass: `${(0, utilities_1.classify)(name)}RootTableMethod`,
|
|
160
161
|
}, [
|
|
161
162
|
{
|
|
162
163
|
moduleSpecifier: '@rxap/data-source/table/tree',
|
|
163
|
-
namedImports: ['
|
|
164
|
+
namedImports: ['RXAP_TREE_TABLE_DATA_SOURCE_ROOT_METHOD'],
|
|
164
165
|
},
|
|
165
166
|
{
|
|
166
167
|
moduleSpecifier: `./${name}-root-table.method`,
|
|
@@ -168,12 +169,12 @@ function localBackendRule(normalizedOptions) {
|
|
|
168
169
|
},
|
|
169
170
|
]);
|
|
170
171
|
(0, schematics_ts_morph_1.AddComponentProvider)(sourceFile, {
|
|
171
|
-
provide: '
|
|
172
|
+
provide: 'RXAP_TREE_TABLE_DATA_SOURCE_CHILDREN_METHOD',
|
|
172
173
|
useClass: `${(0, utilities_1.classify)(name)}ChildTableMethod`,
|
|
173
174
|
}, [
|
|
174
175
|
{
|
|
175
176
|
moduleSpecifier: '@rxap/data-source/table/tree',
|
|
176
|
-
namedImports: ['
|
|
177
|
+
namedImports: ['RXAP_TREE_TABLE_DATA_SOURCE_CHILDREN_METHOD'],
|
|
177
178
|
},
|
|
178
179
|
{
|
|
179
180
|
moduleSpecifier: `./${name}-child-table.method`,
|
|
@@ -260,30 +261,24 @@ function treeTableMethodRule(normalizedOptions) {
|
|
|
260
261
|
overwrite,
|
|
261
262
|
tsMorphTransform: (project, [sourceFile]) => {
|
|
262
263
|
(0, schematics_ts_morph_1.AddComponentProvider)(sourceFile, {
|
|
263
|
-
provide: '
|
|
264
|
-
useClass: tableRootMethod.
|
|
264
|
+
provide: 'RXAP_TREE_TABLE_DATA_SOURCE_ROOT_METHOD',
|
|
265
|
+
useClass: tableRootMethod.name,
|
|
265
266
|
}, [
|
|
266
267
|
{
|
|
267
268
|
moduleSpecifier: '@rxap/data-source/table/tree',
|
|
268
|
-
namedImports: ['
|
|
269
|
-
},
|
|
270
|
-
{
|
|
271
|
-
moduleSpecifier: tableRootMethod.importPath,
|
|
272
|
-
namedImports: [tableRootMethod.className],
|
|
269
|
+
namedImports: ['RXAP_TREE_TABLE_DATA_SOURCE_ROOT_METHOD'],
|
|
273
270
|
},
|
|
271
|
+
(0, ts_morph_1.TypeImportToImportStructure)(tableRootMethod),
|
|
274
272
|
]);
|
|
275
273
|
(0, schematics_ts_morph_1.AddComponentProvider)(sourceFile, {
|
|
276
|
-
provide: '
|
|
277
|
-
useClass: tableChildMethod.
|
|
274
|
+
provide: 'RXAP_TREE_TABLE_DATA_SOURCE_CHILDREN_METHOD',
|
|
275
|
+
useClass: tableChildMethod.name,
|
|
278
276
|
}, [
|
|
279
277
|
{
|
|
280
278
|
moduleSpecifier: '@rxap/data-source/table/tree',
|
|
281
|
-
namedImports: ['
|
|
282
|
-
},
|
|
283
|
-
{
|
|
284
|
-
moduleSpecifier: tableChildMethod.importPath,
|
|
285
|
-
namedImports: [tableChildMethod.className],
|
|
279
|
+
namedImports: ['RXAP_TREE_TABLE_DATA_SOURCE_CHILDREN_METHOD'],
|
|
286
280
|
},
|
|
281
|
+
(0, ts_morph_1.TypeImportToImportStructure)(tableChildMethod),
|
|
287
282
|
]);
|
|
288
283
|
},
|
|
289
284
|
}),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../../../packages/schematic/angular/src/schematics/table/tree-table-component/index.ts"],"names":[],"mappings":";;;AAAA,2DAGoC;AACpC,mEAUmC;AACnC,+CAGyB;AAKzB,kEAIsC;AACtC,8DAA0D;AAC1D,kGAMsD;AACtD,wEAGyC;AASzC,SAAgB,mCAAmC,CACjD,OAA4C;IAE5C,MAAM,sCAAsC,GAAG,IAAA,uEAAqC,EAAC,OAAO,CAAC,CAAC;IAC9F,IAAA,kDAAgC,EAAC,sCAAsC,CAAC,CAAC;IACzE,MAAM,EAAE,IAAI,EAAE,GAAG,sCAAsC,CAAC;IACxD,MAAM,0BAA0B,GAAG,IAAA,8CAAyB,EAAC,OAAO,EAAE,IAAI,CAAC,CAAC;IAC5E,OAAO,MAAM,CAAC,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../../../packages/schematic/angular/src/schematics/table/tree-table-component/index.ts"],"names":[],"mappings":";;;AAAA,2DAGoC;AACpC,mEAUmC;AACnC,6CAA6D;AAC7D,+CAGyB;AAKzB,kEAIsC;AACtC,8DAA0D;AAC1D,kGAMsD;AACtD,wEAGyC;AASzC,SAAgB,mCAAmC,CACjD,OAA4C;IAE5C,MAAM,sCAAsC,GAAG,IAAA,uEAAqC,EAAC,OAAO,CAAC,CAAC;IAC9F,IAAA,kDAAgC,EAAC,sCAAsC,CAAC,CAAC;IACzE,MAAM,EAAE,IAAI,EAAE,GAAG,sCAAsC,CAAC;IACxD,MAAM,0BAA0B,GAAG,IAAA,8CAAyB,EAAC,OAAO,EAAE,IAAI,CAAC,CAAC;IAC5E,OAAO,MAAM,CAAC,MAAM,iCACf,sCAAsC,GACtC,0BAA0B,EAC7B,CAAC;AACL,CAAC;AAXD,kFAWC;AAED,SAAS,YAAY,CAAC,OAA4C;IAChE,IAAA,qCAAmB,EAAC,sBAAsB,EAAE,OAAO,CAAC,CAAC;IACrD,IAAI,OAAO,CAAC,UAAU,CAAC,MAAM,EAAE;QAC7B,OAAO,CAAC,GAAG,CAAC,wBAAyB,OAAO,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,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AAI,GAAE,CAAC;AAEhB,CAAC;AAED,mBAAyB,OAAkC;IACzD,MAAM,iBAAiB,GAAG,mCAAmC,CAAC,OAAO,CAAC,CAAC;IACvE,YAAY,CAAC,iBAAiB,CAAC,CAAC;IAEhC,OAAO,GAAG,EAAE;QACV,OAAO,IAAA,kBAAK,EAAC;YACX,IAAA,oDAAkB,EAAC,iBAAiB,CAAC;YACrC,aAAa,CAAC,iBAAiB,CAAC;YAChC,IAAA,gDAAc,EAAC,iBAAiB,CAAC;YACjC,IAAA,mDAAiB,EAAC,iBAAiB,CAAC;YACpC,IAAA,kDAAgB,EAAC,iBAAiB,CAAC;YACnC,WAAW,CAAC,iBAAiB,CAAC;YAC9B,mBAAmB,CAAC,iBAAiB,CAAC;SACvC,CAAC,CAAC;IACL,CAAC,CAAC;AACJ,CAAC;AAfD,4BAeC"}
|
|
@@ -95,12 +95,47 @@
|
|
|
95
95
|
"type": {
|
|
96
96
|
"type": "string"
|
|
97
97
|
},
|
|
98
|
+
"role": {
|
|
99
|
+
"type": "string"
|
|
100
|
+
},
|
|
98
101
|
"modifiers": {
|
|
99
102
|
"type": "array",
|
|
100
103
|
"items": {
|
|
101
104
|
"type": "string"
|
|
102
105
|
}
|
|
103
106
|
},
|
|
107
|
+
"template": {
|
|
108
|
+
"type": "string"
|
|
109
|
+
},
|
|
110
|
+
"pipeList": {
|
|
111
|
+
"type": "array",
|
|
112
|
+
"items": {
|
|
113
|
+
"oneOf": [
|
|
114
|
+
{
|
|
115
|
+
"type": "string"
|
|
116
|
+
},
|
|
117
|
+
{
|
|
118
|
+
"type": "object",
|
|
119
|
+
"properties": {
|
|
120
|
+
"name": {
|
|
121
|
+
"type": "string"
|
|
122
|
+
},
|
|
123
|
+
"namedImport": {
|
|
124
|
+
"type": "string"
|
|
125
|
+
},
|
|
126
|
+
"moduleSpecifier": {
|
|
127
|
+
"type": "string"
|
|
128
|
+
}
|
|
129
|
+
},
|
|
130
|
+
"required": [
|
|
131
|
+
"name",
|
|
132
|
+
"namedImport",
|
|
133
|
+
"moduleSpecifier"
|
|
134
|
+
]
|
|
135
|
+
}
|
|
136
|
+
]
|
|
137
|
+
}
|
|
138
|
+
},
|
|
104
139
|
"hasFilter": {
|
|
105
140
|
"type": "boolean"
|
|
106
141
|
},
|
|
@@ -198,7 +233,17 @@
|
|
|
198
233
|
}
|
|
199
234
|
},
|
|
200
235
|
"overwrite": {
|
|
201
|
-
"
|
|
236
|
+
"anyOf": [
|
|
237
|
+
{
|
|
238
|
+
"type": "boolean"
|
|
239
|
+
},
|
|
240
|
+
{
|
|
241
|
+
"type": "array",
|
|
242
|
+
"items": {
|
|
243
|
+
"type": "string"
|
|
244
|
+
}
|
|
245
|
+
}
|
|
246
|
+
],
|
|
202
247
|
"description": "Overwrite existing files",
|
|
203
248
|
"default": false
|
|
204
249
|
},
|
|
@@ -209,28 +254,36 @@
|
|
|
209
254
|
"tableRootMethod": {
|
|
210
255
|
"type": "object",
|
|
211
256
|
"properties": {
|
|
212
|
-
"
|
|
257
|
+
"name": {
|
|
213
258
|
"type": "string",
|
|
214
259
|
"description": "The name of the table method class"
|
|
215
260
|
},
|
|
216
|
-
"
|
|
261
|
+
"moduleSpecifier": {
|
|
217
262
|
"type": "string",
|
|
218
263
|
"description": "The import path for the table method class"
|
|
219
264
|
}
|
|
220
|
-
}
|
|
265
|
+
},
|
|
266
|
+
"required": [
|
|
267
|
+
"name",
|
|
268
|
+
"moduleSpecifier"
|
|
269
|
+
]
|
|
221
270
|
},
|
|
222
271
|
"tableChildMethod": {
|
|
223
272
|
"type": "object",
|
|
224
273
|
"properties": {
|
|
225
|
-
"
|
|
274
|
+
"name": {
|
|
226
275
|
"type": "string",
|
|
227
276
|
"description": "The name of the table method class"
|
|
228
277
|
},
|
|
229
|
-
"
|
|
278
|
+
"moduleSpecifier": {
|
|
230
279
|
"type": "string",
|
|
231
280
|
"description": "The import path for the table method class"
|
|
232
281
|
}
|
|
233
|
-
}
|
|
282
|
+
},
|
|
283
|
+
"required": [
|
|
284
|
+
"name",
|
|
285
|
+
"moduleSpecifier"
|
|
286
|
+
]
|
|
234
287
|
}
|
|
235
288
|
},
|
|
236
289
|
"required": [
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { TreeComponentOptions } from './schema';
|
|
2
|
-
import { NormalizedAngularOptions } from '../../lib/angular-options';
|
|
3
1
|
import { Normalized } from '@rxap/utilities';
|
|
2
|
+
import { NormalizedAngularOptions } from '../../lib/angular-options';
|
|
3
|
+
import { TreeComponentOptions } from './schema';
|
|
4
4
|
export interface NormalizedTreeComponentOptions extends Readonly<Normalized<TreeComponentOptions> & NormalizedAngularOptions> {
|
|
5
5
|
name: string;
|
|
6
6
|
controllerName: string;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.NormalizeTreeComponentOptions = void 0;
|
|
4
|
-
const schematics_utilities_1 = require("@rxap/schematics-utilities");
|
|
5
4
|
const schematics_1 = require("@angular-devkit/schematics");
|
|
6
5
|
const schematics_ts_morph_1 = require("@rxap/schematics-ts-morph");
|
|
6
|
+
const schematics_utilities_1 = require("@rxap/schematics-utilities");
|
|
7
7
|
const angular_options_1 = require("../../lib/angular-options");
|
|
8
8
|
function NormalizeTreeComponentOptions(options) {
|
|
9
9
|
var _a, _b, _c;
|
|
@@ -11,7 +11,7 @@ function NormalizeTreeComponentOptions(options) {
|
|
|
11
11
|
(0, angular_options_1.AssertAngularOptionsNameProperty)(normalizedAngularOptions);
|
|
12
12
|
const { name } = normalizedAngularOptions;
|
|
13
13
|
const componentName = (0, schematics_utilities_1.CoerceSuffix)((0, schematics_utilities_1.dasherize)(name), '-tree');
|
|
14
|
-
return Object.
|
|
14
|
+
return Object.freeze(Object.assign(Object.assign({}, normalizedAngularOptions), { modifiers: (_a = options.modifiers) !== null && _a !== void 0 ? _a : [], controllerName: (_b = options.controllerName) !== null && _b !== void 0 ? _b : componentName, componentName, fullTree: (_c = options.fullTree) !== null && _c !== void 0 ? _c : true }));
|
|
15
15
|
}
|
|
16
16
|
exports.NormalizeTreeComponentOptions = NormalizeTreeComponentOptions;
|
|
17
17
|
function default_1(options) {
|