Skip to content

Commit

Permalink
fix(menu): toggle filter bar could be out of sync w/horizontal scroll
Browse files Browse the repository at this point in the history
- when toggling the filter bar (on and off), the horizontal scroll could become out of sync (the alignment of the filters with the column and its data), this happen because the filters are recreated every time we toggle back the filter bar, for that issue we simply need to move the horizontal scroll back to top-left and that fixes the issue
  • Loading branch information
ghiscoding committed Jun 16, 2021
1 parent 7c999e0 commit ab7f589
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions packages/common/src/extensions/gridMenuExtension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -477,6 +477,7 @@ export class GridMenuExtension implements Extension {
// when displaying header row, we'll call "setColumns" which in terms will recreate the header row filters
if (showHeaderRow === true) {
this.sharedService.slickGrid.setColumns(this.sharedService.columnDefinitions);
this.sharedService.slickGrid.scrollColumnIntoView(0); // quick fix to avoid filter being out of sync with horizontal scroll
}
break;
case 'toggle-toppanel':
Expand Down

0 comments on commit ab7f589

Please sign in to comment.