Skip to content

Commit

Permalink
Update ToolTip.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
gnbm committed Oct 31, 2024
1 parent fcbac18 commit 8fb451a
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/Providers/DataGrid/Wijmo/Features/ToolTip.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,15 +32,13 @@ namespace Providers.DataGrid.Wijmo.Feature {
this._setCellTooltip(_currTarget, ht.getColumn().binding, ht.row);
}
} else if (cellType === wijmo.grid.CellType.ColumnHeader) {
const col = ht.getColumn(true) as wijmo.grid.ColumnGroup;
// If the Column Header is from a Group Column, we need to use a different approach than the regular header
// We can check if the current target is a ColumnGroup by checking its class and if it has columns or columnGroups
if (
_currTarget.classList.contains(Helper.Constants.CssClasses.ColumnGroup) &&
((ht.getColumn(true)._binding === undefined &&
(ht.getColumn(true) as wijmo.grid.ColumnGroup).columns !== undefined &&
(ht.getColumn(true) as wijmo.grid.ColumnGroup).columns.length > 0) ||
((ht.getColumn(true) as wijmo.grid.ColumnGroup).columnGroups !== undefined &&
(ht.getColumn(true) as wijmo.grid.ColumnGroup).columnGroups.length > 0))
((col._binding === undefined && col.columns !== undefined && col.columns.length > 0) ||
(col.columnGroups !== undefined && col.columnGroups.length > 0))
) {
this._setColumnGroupHeaderTooltip(_currTarget);
} else {
Expand Down

0 comments on commit 8fb451a

Please sign in to comment.