ng-tablekit 1.0.2 → 1.0.3

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ng-tablekit",
3
- "version": "1.0.2",
3
+ "version": "1.0.3",
4
4
  "description": "Cross-platform CLI for adding Angular 19 and NG-ZORRO report and master table pages.",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -229,8 +229,11 @@
229
229
  /* Pagination */
230
230
  :host ::ng-deep .ant-pagination {
231
231
  margin-top: 12px !important;
232
+ margin-bottom: 0 !important;
232
233
  display: flex;
234
+ flex-wrap: wrap;
233
235
  justify-content: flex-end;
236
+ row-gap: 8px;
234
237
  }
235
238
 
236
239
  :host ::ng-deep .ant-pagination-item,
@@ -63,7 +63,7 @@
63
63
  </form>
64
64
  }
65
65
  <nz-table #table nzBordered nzSize="small" [nzData]="records" [(nzPageIndex)]="pageIndex" [nzPageSize]="10"
66
- [nzShowSizeChanger]="true" [nzPageSizeOptions]="pageSizeOptions" [nzScroll]="{ y: '55vh' }"
66
+ [nzShowSizeChanger]="true" [nzPageSizeOptions]="pageSizeOptions" [nzScroll]="{ x: '920px', y: tableScrollY }"
67
67
  (nzQueryParams)="onQueryParamsChange($event)">
68
68
  <thead>
69
69
  <tr>
@@ -90,6 +90,11 @@ export class MasterPageComponent {
90
90
  protected filterVisible = false;
91
91
  protected searchText = '';
92
92
  protected pageIndex = 1;
93
+ protected get tableScrollY(): string {
94
+ return this.filterVisible
95
+ ? 'clamp(120px, calc(100dvh - 640px), 38dvh)'
96
+ : 'clamp(140px, calc(100dvh - 430px), 52dvh)';
97
+ }
93
98
  private allRecords: TableRecord[] = TABLE_RECORDS.map(record => ({ ...record }));
94
99
  protected records: TableRecord[] = [...this.allRecords];
95
100
  protected currentSort: { key: string | null; value: string | null } = { key: null, value: null };
@@ -229,8 +229,11 @@
229
229
  /* Pagination */
230
230
  :host ::ng-deep .ant-pagination {
231
231
  margin-top: 12px !important;
232
+ margin-bottom: 0 !important;
232
233
  display: flex;
234
+ flex-wrap: wrap;
233
235
  justify-content: flex-end;
236
+ row-gap: 8px;
234
237
  }
235
238
 
236
239
  :host ::ng-deep .ant-pagination-item,
@@ -52,7 +52,7 @@
52
52
  </form>
53
53
  }
54
54
  <nz-table #table nzBordered nzSize="small" [nzData]="records" [(nzPageIndex)]="pageIndex" [nzPageSize]="10"
55
- [nzShowSizeChanger]="true" [nzPageSizeOptions]="pageSizeOptions" [nzScroll]="{ y: '55vh' }"
55
+ [nzShowSizeChanger]="true" [nzPageSizeOptions]="pageSizeOptions" [nzScroll]="{ x: '770px', y: tableScrollY }"
56
56
  (nzQueryParams)="onQueryParamsChange($event)">
57
57
  <thead>
58
58
  <tr>@for(column of columns; track column.key){
@@ -59,6 +59,11 @@ export class ReportPageComponent {
59
59
  protected filterVisible = false;
60
60
  protected searchText = '';
61
61
  protected pageIndex = 1;
62
+ protected get tableScrollY(): string {
63
+ return this.filterVisible
64
+ ? 'clamp(120px, calc(100dvh - 640px), 38dvh)'
65
+ : 'clamp(140px, calc(100dvh - 430px), 52dvh)';
66
+ }
62
67
  protected records: TableRecord[] = TABLE_RECORDS;
63
68
  protected currentSort: { key: string | null; value: string | null } = { key: null, value: null };
64
69