primevue icon indicating copy to clipboard operation
primevue copied to clipboard

VirtualScroller scrolling is jarring when itemSize is changed

Open bgoscinski opened this issue 2 years ago • 1 comments

I'm submitting a ... (check one with "x")

[x] bug report => Search github for a similar issue or PR before submitting
[ ] feature request => Please check if request is not on the roadmap already https://github.com/primefaces/primevue/wiki/Roadmap
[ ] support request => Please do not submit support request here, instead see http://forum.primefaces.org/viewforum.php?f=110

CodeSandbox Case (Bug Reports) https://codesandbox.io/s/zen-shamir-5o79w3?file=/src/VirtualScrollerDemo.vue

Current behavior After a change to itemSize scrolling is jarring.

Expected behavior After a change to itemSize scrolling is smooth.

Minimal reproduction of the problem with instructions

  1. Create any VirtualScroller, let it initialize
  2. Scroll it, observe scrolling is smooth and scrollbar doesn't jump (good)
  3. After VirtualScroller initializes change itemSize binding to different value
  4. Scroll it, observe scrolling is jarring - scrollbar jumps back (bad)

scrolll

What is the motivation / use case for changing the behavior? Good UX

Please tell us about your environment: Windows 10, latest Chrome and Brave

  • Vue version: 3.2.31
  • PrimeVue version: 3.12.0
  • Browser: reproduced on Chrome and Brave, didn't check others

bgoscinski avatar Feb 25 '22 11:02 bgoscinski

The bug is still reproducible on PrimeVue 3.15.0

bgoscinski avatar Jun 20 '22 12:06 bgoscinski