I have a grid that binds data with the async pipe, and it subscribes to the dataPreLoad pipe for scrolling and adding new records into the grid. For example, a grid source has 300 records, loads 25 initially and every time I scroll to the last chunk, it'll load 25 more and the scroll bar will resize accordingly. If scrolling happens too fast and exactly at wrong times, some sort of race condition occurs where the scroll bar will disappear. This is hard to reproduce, happens maybe 1 of 5 times and have to be scrolling very fast.
What I traced it to is the individualSizeCache property of verticalScrollContainer gets undefined values in it, which happens in handleCacheChanges() when it tries to update with item.previousIndex, but previousIndex actually gets higher then the length of individualSizeCache, so you get undefined. Seems like perhaps initSizesCache does not run before handleCacheChanges to push the newly scrolled into items? If it is a race condition and incredibly sporadic, I could see this being the case.
Would it make sense to set the default size (in the else condition) if this happens, or is there something I can do in the implementation to prevent this? I included a screencap with the items in the watchlist that show how this would occur.
Hello Matt,
Thank you for bringing this to our attention.
I followed the steps you described and prepared a small sample on StackBlitz to verify the behavior: https://stackblitz.com/edit/s4dfue8z?file=src%2Fapp%2Fgrid%2Fgrid-sample-2%2Fgrid-sample-2.component.html. In my testing, I was not able to reproduce the issue. You mentioned sending a screenshot or screencast, but I did not receive it—if convenient, please resend it so I can review the exact scenario you encountered.
To proceed effectively, it would be helpful if you could either reproduce the behavior in the StackBlitz sample (you can fork it) or share a minimal example where the issue occurs. Additionally, any details about the precise sequence of actions, your environment (browser and version, Angular and Ignite UI versions), any custom styling, and any console messages would help us narrow this down.
I appreciate your collaboration and patience. Once I have a reproducible sample, I will continue the investigation and report back with findings and next steps.
Best Regards,Arkan AhmedovInfragistics