@trudb/tru-common-lib 0.1.962 → 0.1.964

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.
@@ -6036,21 +6036,21 @@ class TruDataGridHeaderFilter {
6036
6036
  value: 'asc',
6037
6037
  label: 'Sort A to Z',
6038
6038
  selected: false,
6039
- display: !this.filterParams.column.isSortAscending(),
6039
+ display: () => { return !this.filterParams.column.isSortAscending(); },
6040
6040
  icon: 'asc-sort-icon'
6041
6041
  },
6042
6042
  {
6043
6043
  value: 'desc',
6044
6044
  label: 'Sort Z to A',
6045
6045
  selected: false,
6046
- display: !this.filterParams.column.isSortDescending(),
6046
+ display: () => { return !this.filterParams.column.isSortDescending(); },
6047
6047
  icon: 'desc-sort-icon'
6048
6048
  },
6049
6049
  {
6050
6050
  value: null,
6051
6051
  label: 'Clear Sort',
6052
6052
  selected: false,
6053
- display: this.filterParams.column.isSortAscending() || this.filterParams.column.isSortDescending(),
6053
+ display: () => { return this.filterParams.column.isSortAscending() || this.filterParams.column.isSortDescending(); },
6054
6054
  icon: 'no-sort-icon'
6055
6055
  }
6056
6056
  ];
@@ -6084,14 +6084,14 @@ class TruDataGridHeaderFilter {
6084
6084
  this.filterParams.filterChangedCallback();
6085
6085
  }
6086
6086
  onSortSelection = (changeEvent) => {
6087
- this.filterParams.colDef.headerComponentParams.setSort(changeEvent.options[0].value, false);
6087
+ this.filterParams.colDef.headerComponentParams.setSort(changeEvent.options[0].value.value, false);
6088
6088
  };
6089
6089
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.3", ngImport: i0, type: TruDataGridHeaderFilter, deps: [], target: i0.ɵɵFactoryTarget.Component });
6090
6090
  static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.3", type: TruDataGridHeaderFilter, isStandalone: true, selector: "ng-component", ngImport: i0, template: `
6091
6091
  <div class="tru-data-grid-header-filter-container">
6092
6092
  <mat-selection-list #sort [multiple]="false" (selectionChange)="onSortSelection($event)">
6093
6093
  @for (typeOfSort of typesOfSort; track typeOfSort.value) {
6094
- <mat-list-option [value]='typeOfSort' *ngIf="typeOfSort.display">
6094
+ <mat-list-option [value]='typeOfSort' *ngIf="typeOfSort.display()">
6095
6095
  <mat-icon [svgIcon]="typeOfSort.icon"></mat-icon>
6096
6096
  <span matListItem>{{typeOfSort.label}}</span>
6097
6097
  </mat-list-option>
@@ -6135,7 +6135,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.3", ngImpor
6135
6135
  <div class="tru-data-grid-header-filter-container">
6136
6136
  <mat-selection-list #sort [multiple]="false" (selectionChange)="onSortSelection($event)">
6137
6137
  @for (typeOfSort of typesOfSort; track typeOfSort.value) {
6138
- <mat-list-option [value]='typeOfSort' *ngIf="typeOfSort.display">
6138
+ <mat-list-option [value]='typeOfSort' *ngIf="typeOfSort.display()">
6139
6139
  <mat-icon [svgIcon]="typeOfSort.icon"></mat-icon>
6140
6140
  <span matListItem>{{typeOfSort.label}}</span>
6141
6141
  </mat-list-option>