@trudb/tru-common-lib 0.1.951 → 0.1.953
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.
|
@@ -5901,7 +5901,7 @@ class TruDataGridHeader {
|
|
|
5901
5901
|
noSort = 'inactive';
|
|
5902
5902
|
isHovering = false;
|
|
5903
5903
|
columnMenuIsOpen = false;
|
|
5904
|
-
showFilterMenu =
|
|
5904
|
+
showFilterMenu = false;
|
|
5905
5905
|
agInit(params) {
|
|
5906
5906
|
this.params = params;
|
|
5907
5907
|
this.params.column.addEventListener('sortChanged', this.onSortChanged.bind(this));
|
|
@@ -5956,6 +5956,7 @@ class TruDataGridHeader {
|
|
|
5956
5956
|
onFilterMenuButtonClicked(event) {
|
|
5957
5957
|
if (!this.columnMenuIsOpen) {
|
|
5958
5958
|
this.params.showColumnMenu(event.target, () => {
|
|
5959
|
+
this.columnMenuIsOpen = false;
|
|
5959
5960
|
});
|
|
5960
5961
|
this.columnMenuIsOpen = true;
|
|
5961
5962
|
}
|
|
@@ -5964,6 +5965,14 @@ class TruDataGridHeader {
|
|
|
5964
5965
|
this.columnMenuIsOpen = false;
|
|
5965
5966
|
}
|
|
5966
5967
|
}
|
|
5968
|
+
onHeaderMouseEnter(event) {
|
|
5969
|
+
this.isHovering = true;
|
|
5970
|
+
this.showFilterMenu = this.isHovering && this.params.api.getDisplayedRowCount() > 0 || this.columnMenuIsOpen;
|
|
5971
|
+
}
|
|
5972
|
+
onHeaderMouseLeave(event) {
|
|
5973
|
+
this.isHovering = false;
|
|
5974
|
+
this.showFilterMenu = this.isHovering && this.params.api.getDisplayedRowCount() > 0 || this.columnMenuIsOpen;
|
|
5975
|
+
}
|
|
5967
5976
|
ngOnDestroy() {
|
|
5968
5977
|
this.params.column.removeEventListener('sortChanged', this.onSortChanged.bind(this));
|
|
5969
5978
|
this.params.api.removeEventListener('cellFocused', this.onCellFocused.bind(this));
|
|
@@ -5971,7 +5980,7 @@ class TruDataGridHeader {
|
|
|
5971
5980
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.3", ngImport: i0, type: TruDataGridHeader, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
5972
5981
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.3", type: TruDataGridHeader, isStandalone: true, selector: "ng-component", viewQueries: [{ propertyName: "headerRef", first: true, predicate: ["header"], descendants: true }], ngImport: i0, template: `
|
|
5973
5982
|
<div #header class="ag-cell-label-container" role="presentation">
|
|
5974
|
-
<div ref="eLabel" class="ag-header-cell-label" role="presentation" (mouseenter)="
|
|
5983
|
+
<div ref="eLabel" class="ag-header-cell-label" role="presentation" (mouseenter)="onHeaderMouseEnter($event)" (mouseleave)="onHeaderMouseLeave($event)">
|
|
5975
5984
|
<div class="ag-header-control-container">
|
|
5976
5985
|
<div>
|
|
5977
5986
|
<span ref="eText" class="ag-header-cell-text">{{params.displayName}}</span>
|
|
@@ -5989,7 +5998,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.3", ngImpor
|
|
|
5989
5998
|
type: Component,
|
|
5990
5999
|
args: [{ standalone: true, imports: [NgIf, NgClass, CommonModule, MatIconModule], template: `
|
|
5991
6000
|
<div #header class="ag-cell-label-container" role="presentation">
|
|
5992
|
-
<div ref="eLabel" class="ag-header-cell-label" role="presentation" (mouseenter)="
|
|
6001
|
+
<div ref="eLabel" class="ag-header-cell-label" role="presentation" (mouseenter)="onHeaderMouseEnter($event)" (mouseleave)="onHeaderMouseLeave($event)">
|
|
5993
6002
|
<div class="ag-header-control-container">
|
|
5994
6003
|
<div>
|
|
5995
6004
|
<span ref="eText" class="ag-header-cell-text">{{params.displayName}}</span>
|