telerik / kendo-angular

Issue tracker - Kendo UI for Angular
http://www.telerik.com/kendo-angular-ui/
Other
467 stars 217 forks source link

Grid with virtual scrolling does not scroll to the row, corresponding to "skip" #1980

Open dtopalov opened 5 years ago

dtopalov commented 5 years ago

When a Grid with virtual scrolling is bound to asynchronous or synchronous data, and the initial skip value is greater than 0, the scrollTop position of the scrollable container is not adjusted accordingly:

https://stackblitz.com/edit/angular-utkih8?file=app%2Fapp.component.ts

Please check the following examples demonstrating similar undesired behaviors of the Grid when using the [skip] property with virtualization and local data:

Angular 8: https://stackblitz.com/edit/angular-qjvobu

Angular 9: https://stackblitz.com/edit/angular-3alx4j

tapopov commented 4 years ago

Fix available in dev (v4.7.4-dev.202008121032)

dtopalov commented 4 years ago

Fix available in v. 4.7.4

proalphaDev commented 4 years ago

I've checked the fix, but for me it does not work.

See example here: https://stackblitz.com/edit/angular-evqsba (same as in https://github.com/telerik/kendo-angular/issues/2307 but with higher kendo-grid version)

The initial skip is set to 30. The scrollbar seems to jump to this specific skip (you can scroll upwards). However, the data displayed is beginning from the frist row.

tapopov commented 4 years ago

@proalphaDev we will investigate further.

proalphaDev commented 4 years ago

I've checked the fix, but for me it does not work.

See example here: https://stackblitz.com/edit/angular-evqsba (same as in #2307 but with higher kendo-grid version)

The initial skip is set to 30. The scrollbar seems to jump to this specific skip (you can scroll upwards). However, the data displayed is beginning from the frist row.

In this example, the slicing was not correct. Here is an example with correct slicing: https://stackblitz.com/edit/angular-evqsba-wyea2a In this example, it initially looks good and seems to jump to row 30. However, if you scroll upwards you first get to the 60th row and, moreover, you cannot scroll to a row less than 30.

Moreover if you grab the scroll bar with the mouse and move it downwards, you always only see row 30 and higher. Sometimes, also scrolling with scroll wheel produces strange jumps.