Skip to content

Commit b74eb5a

Browse files
fix(*): adjust header scroll position when focused el i scrolled in view #13547 (#13602)
Co-authored-by: Hristo <[email protected]>
1 parent 864ff85 commit b74eb5a

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

projects/igniteui-angular/src/lib/grids/headers/grid-header-row.component.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<div role="rowgroup" class="igx-grid-thead__wrapper" [style.width.px]="width"
1+
<div role="rowgroup" class="igx-grid-thead__wrapper" (scroll)="scroll($event)" [style.width.px]="width"
22
[class.igx-grid__tr--mrl]="hasMRL">
33

44
<!-- Column headers area -->

projects/igniteui-angular/src/lib/grids/headers/grid-header-row.component.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -196,6 +196,13 @@ export class IgxGridHeaderRowComponent implements DoCheck {
196196
this.cdr.markForCheck();
197197
}
198198

199+
/**
200+
* @hidden @internal
201+
*/
202+
public scroll(event: Event) {
203+
this.grid.preventHeaderScroll(event);
204+
}
205+
199206
public headerRowSelection(event: MouseEvent) {
200207
if (!this.grid.isMultiRowSelectionEnabled) {
201208
return;

0 commit comments

Comments
 (0)