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

super_sliver_list adds initial value configuration #69

Open
maxfrees opened this issue Aug 29, 2024 · 1 comment
Open

super_sliver_list adds initial value configuration #69

maxfrees opened this issue Aug 29, 2024 · 1 comment

Comments

@maxfrees
Copy link

I have a requirement. If I have 5000 options, I hope to use super_sliver_list to display them in the bottomSheet. How can I set the initial value so that the initial value can be displayed in the center?

If I have 5000 data, and if I set the initial value to 2000, I expect that when I open the bottomSheet, the 2000 th option will be centered

image

@knopp
Copy link
Collaborator

knopp commented Aug 29, 2024

There is no initial index in SuperSliverList. Right now you have to layout the SliverList at least once (for one frame) in order to jump to an item. This is something I'd want to figure out eventually but it's quite difficult since scroll offset estimation depends on viewport being available, which is only after first build.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants