Skip to content

Commit 9bf60fa

Browse files
MKirovaMayaKirova
authored andcommitted
chore(*): Update scrollOffset when container size changes.
1 parent 90899a0 commit 9bf60fa

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

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

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1614,6 +1614,10 @@ export class IgxGridForOfDirective<T, U extends T[] = T[]> extends IgxForOfDirec
16141614
const containerSize = 'igxForContainerSize';
16151615
if (containerSize in changes && !changes[containerSize].firstChange && this.igxForOf) {
16161616
this._recalcOnContainerChange();
1617+
if (changes[containerSize].previousValue) {
1618+
this.scrollComponent.scrollAmount = this.scrollComponent.nativeElement[this.igxForScrollOrientation === "horizontal" ? "scrollLeft" : "scrollTop"];
1619+
this._updateScrollOffset();
1620+
}
16171621
}
16181622
}
16191623

0 commit comments

Comments
 (0)