petyosi / react-virtuoso

The most powerful virtual list component for React
https://virtuoso.dev
MIT License
5.25k stars 301 forks source link

an item is considered "in view" if the top of the item is within view, not the whole item (or actually top AND bottom of the item). #748

Closed petyosi closed 2 years ago

petyosi commented 2 years ago

An item is considered "in view" if the top of the item is within view, not the whole item (or actually top AND bottom of the item). I'm attaching a screencast to show the issue. Notice that the bottom item is barely visible at the beginning, everything works fine as long as the top of the item you are scrolling is not visible :) (This is virtuoso 2.18.0) Screencast from 07. sep. 2022 kl. 09.16 +0200.webm

Originally posted by @mortmoe in https://github.com/petyosi/react-virtuoso/issues/745#issuecomment-1239015871

mortmoe commented 2 years ago

Cool. Thanks for the great work and quick responses :) I'm in the process of refactoring several virtualized lists in my app to Virtuoso and really appreciate it. It simplifies the components a lot and just works better :D

Nathan-Notifi commented 2 years ago

Dealing with this too. I'd like to set it for prepending items where the bottom of the virtualized item is used

maccman commented 2 years ago

We are seeing this issue crop up in Reflect too.

https://user-images.githubusercontent.com/2142/193395399-178aeaae-73a9-48f9-bb1d-997fdd767a08.mp4

petyosi commented 2 years ago

@maccman @mortmoe , the problem was specific to the table, not considering the header/footer sizes.

github-actions[bot] commented 2 years ago

:tada: This issue has been resolved in version 2.19.1 :tada:

The release is available on:

Your semantic-release bot :package::rocket:

maccman commented 2 years ago

@petyosi you are a hero!

mortmoe commented 2 years ago

@petyosi Thanks, works like a charm now :D