Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prepending Items reverse endless scrolling scenario with GroupedVirtuoso #232

Closed
osadchiynikita opened this issue Dec 13, 2020 · 3 comments
Labels
bug Something isn't working released

Comments

@osadchiynikita
Copy link

@petyosi Hello, many thanks and congratulations with v1 release! Reverse endless scrolling works as expected with plain Virtuoso list, and I'm trying to achieve the same behavior with GroupedVirtuoso, but have some issues.

  1. startReached is not triggering callback for some reason. endReached works well though
  2. When setting data prop list rendering not properly, seems like ignoring groups and groupCounts

https://stackblitz.com/edit/react-kjchm8-mxn3ry?file=example.js

Thank you and let me know if any other info needed!

@petyosi petyosi added the bug Something isn't working label Dec 13, 2020
@petyosi
Copy link
Owner

petyosi commented Dec 13, 2020

Thanks for the bug report. I am not sure how to deal with data and grouping, to be honest. What would be your intuitive API? Do you want to pass array of arrays? Do you expect to have data items for the groups?

@osadchiynikita
Copy link
Author

@petyosi thanks for the fast feedback. Not sure I understand the issue properly, but maybe allow to pass totalCount prop for GroupedVirtuoso same as for Virtuoso. And in my case I'll pass totalCount={items.length + groups.length}

P.S. Just a minor note, probably related to the same root - firstItemIndex is not working properly without data

@github-actions
Copy link

🎉 This issue has been resolved in version 1.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working released
Projects
None yet
Development

No branches or pull requests

2 participants