@one-paragon/angular-utilities 2.3.1 → 2.3.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.
|
@@ -2235,7 +2235,6 @@ class TableStore extends ComponentStore {
|
|
|
2235
2235
|
delete newState.userDefined.headerHeight;
|
|
2236
2236
|
return newState;
|
|
2237
2237
|
}
|
|
2238
|
-
return newState;
|
|
2239
2238
|
});
|
|
2240
2239
|
this.updateStateFromPersistedState = this.updater((state, persistedState) => {
|
|
2241
2240
|
const incomingTableState = cleanPersistedState(state, persistedState);
|
|
@@ -2383,9 +2382,9 @@ class TableStore extends ComponentStore {
|
|
|
2383
2382
|
tableSettings.collapseHeader = !tableSettings.collapseHeader;
|
|
2384
2383
|
return ({ ...state, persistedTableSettings: new PersistedTableSettings(tableSettings) });
|
|
2385
2384
|
});
|
|
2386
|
-
this.toggleCollapseFooter = this.updater((state) => {
|
|
2385
|
+
this.toggleCollapseFooter = this.updater((state, options) => {
|
|
2387
2386
|
const tableSettings = { ...state.persistedTableSettings };
|
|
2388
|
-
tableSettings.collapseFooter = !tableSettings.collapseFooter;
|
|
2387
|
+
tableSettings.collapseFooter = options?.collapseFooter ?? !tableSettings.collapseFooter;
|
|
2389
2388
|
return ({ ...state, persistedTableSettings: new PersistedTableSettings(tableSettings) });
|
|
2390
2389
|
});
|
|
2391
2390
|
this.addGroupByKey = this.updater((state, metaDataKey) => ({
|
|
@@ -2426,6 +2425,16 @@ class TableStore extends ComponentStore {
|
|
|
2426
2425
|
this.setLinkMaps = this.updater((state, maps) => {
|
|
2427
2426
|
return ({ ...state, linkMaps: maps });
|
|
2428
2427
|
});
|
|
2428
|
+
this.updateRowProps = this.updater((state, updates) => {
|
|
2429
|
+
const notPersistedTableSettings = merge$1(new NotPersistedTableSettings(), (state.notPersistedTableSettings));
|
|
2430
|
+
if (updates.rowClasses)
|
|
2431
|
+
notPersistedTableSettings.rowClasses = updates.rowClasses;
|
|
2432
|
+
if (updates.rowClick)
|
|
2433
|
+
notPersistedTableSettings.rowClick = updates.rowClick;
|
|
2434
|
+
if (updates.rowStyles)
|
|
2435
|
+
notPersistedTableSettings.rowStyles = updates.rowStyles;
|
|
2436
|
+
return ({ ...state, notPersistedTableSettings });
|
|
2437
|
+
});
|
|
2429
2438
|
this.on = (srcObservable, func) => {
|
|
2430
2439
|
this.effect(() => srcObservable.pipe(tap(func)));
|
|
2431
2440
|
return this;
|
|
@@ -5157,7 +5166,7 @@ class PaginatorComponent {
|
|
|
5157
5166
|
}
|
|
5158
5167
|
});
|
|
5159
5168
|
});
|
|
5160
|
-
this.$collapseFooter = computed(() => this.state.selectSignal(state => state.persistedTableSettings.collapseFooter)()
|
|
5169
|
+
this.$collapseFooter = computed(() => this.state.selectSignal(state => state.persistedTableSettings.collapseFooter)());
|
|
5161
5170
|
this.$showAllOption = this.state.selectSignal(s => s.notPersistedTableSettings?.paginatorSettings?.includeAllInOptions);
|
|
5162
5171
|
this.$showAll = this.state.$showAll;
|
|
5163
5172
|
}
|
|
@@ -5165,7 +5174,11 @@ class PaginatorComponent {
|
|
|
5165
5174
|
#onPageSizeEffect;
|
|
5166
5175
|
#onMetaPageSizeEffect;
|
|
5167
5176
|
showAll() {
|
|
5168
|
-
|
|
5177
|
+
const showAll = !this.$showAll();
|
|
5178
|
+
this.state.setUserDefinedShowAll(showAll);
|
|
5179
|
+
if (showAll) {
|
|
5180
|
+
this.state.toggleCollapseFooter({ collapseFooter: true });
|
|
5181
|
+
}
|
|
5169
5182
|
}
|
|
5170
5183
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.3", ngImport: i0, type: PaginatorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
5171
5184
|
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.0.3", type: PaginatorComponent, isStandalone: true, selector: "tb-paginator", viewQueries: [{ propertyName: "$paginator", first: true, predicate: MatPaginator, descendants: true, isSignal: true }], ngImport: i0, template: `
|
|
@@ -5177,7 +5190,7 @@ class PaginatorComponent {
|
|
|
5177
5190
|
</div>
|
|
5178
5191
|
}
|
|
5179
5192
|
<mat-paginator [pageSizeOptions]="[5, 10, 20, 50, 100, 500]" showFirstLastButtons
|
|
5180
|
-
[class]="{ 'hide' : $collapseFooter() }">
|
|
5193
|
+
[class]="{ 'hide' : $collapseFooter() || $showAll() }">
|
|
5181
5194
|
</mat-paginator>
|
|
5182
5195
|
@if ($showAllOption() && !$collapseFooter())
|
|
5183
5196
|
{
|
|
@@ -5199,7 +5212,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.3", ngImpor
|
|
|
5199
5212
|
</div>
|
|
5200
5213
|
}
|
|
5201
5214
|
<mat-paginator [pageSizeOptions]="[5, 10, 20, 50, 100, 500]" showFirstLastButtons
|
|
5202
|
-
[class]="{ 'hide' : $collapseFooter() }">
|
|
5215
|
+
[class]="{ 'hide' : $collapseFooter() || $showAll() }">
|
|
5203
5216
|
</mat-paginator>
|
|
5204
5217
|
@if ($showAllOption() && !$collapseFooter())
|
|
5205
5218
|
{
|