Skip to content

Commit 2e29d73

Browse files
MKirovaMayaKirova
authored andcommitted
chore(*): Fix another test.
1 parent 9a7101c commit 2e29d73

File tree

2 files changed

+3
-7
lines changed

2 files changed

+3
-7
lines changed

projects/igniteui-angular/src/lib/directives/for-of/for_of.directive.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1630,7 +1630,7 @@ export class IgxGridForOfDirective<T, U extends T[] = T[]> extends IgxForOfDirec
16301630
if (changes[containerSize].previousValue && this.igxForScrollOrientation === "horizontal") {
16311631
const scrollAmount = this.scrollComponent.nativeElement["scrollLeft"];
16321632
this.scrollComponent.scrollAmount = scrollAmount;
1633-
this.onHScroll(scrollAmount);
1633+
this._updateScrollOffset();
16341634
}
16351635
}
16361636
}

projects/igniteui-angular/src/lib/grids/grid-base.directive.ts

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6312,12 +6312,8 @@ export abstract class IgxGridBaseDirective implements GridType,
63126312
// in case state is no longer valid - update it.
63136313
const rowForOf = row.virtDirRow;
63146314
const gridScrLeft = rowForOf.getScroll().scrollLeft;
6315-
const left = -parseInt(rowForOf.dc.instance._viewContainer.element.nativeElement.style.left, 10);
6316-
const actualScrollLeft = left + rowForOf.getColumnScrollLeft(rowForOf.state.startIndex);
6317-
if (gridScrLeft !== actualScrollLeft) {
6318-
rowForOf.onHScroll(gridScrLeft);
6319-
rowForOf.cdr.detectChanges();
6320-
}
6315+
rowForOf.onHScroll(gridScrLeft);
6316+
rowForOf.cdr.detectChanges();
63216317
}
63226318

63236319
protected changeRowEditingOverlayStateOnScroll(row: RowType) {

0 commit comments

Comments
 (0)