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

[Bug]: V5 SnapToIndexFails if another render cycle interrupts #2057

Closed
joshuadunning opened this issue Nov 21, 2024 · 1 comment
Closed

[Bug]: V5 SnapToIndexFails if another render cycle interrupts #2057

joshuadunning opened this issue Nov 21, 2024 · 1 comment
Labels
bug Something isn't working invalid This doesn't seem right

Comments

@joshuadunning
Copy link

Version

v5

Reanimated Version

v3

Gesture Handler Version

v2

Platforms

iOS

What happened?

We have a few sheets and modals that need to be coordinated together. As a result, we have a managing component that maintains an object of which snappoints should be shown for each sheet.

It looks like updating to Reanimated 3.16 with bottom-sheet 5.0.6 has an issue where calling snapToIndex can be lost if another rerender occurs shortly after. Sometimes the snap point never moves things. Sometimes it moves and jumps back. Sometimes the sheet hides altogether.

I am about to head out of town for a few days, so I wanted to ask if this has been seen before or if there is a better way to organize a few modals together to prevent this behavior.

The key is having the orchestrating component to manage which sheets should be opened at any given time.

Reproduction steps

  • I don't have time to put this together yet since it's inconsistent. Inquiring first to see if there is a better approach or if someone has solved this before. If it's still a problem I'll get a full repro once I get back in town.

Reproduction sample

https://www.google.com/url?sa=i&url=https%3A%2F%2Fwww.nationalgeographic.com%2Fanimals%2Fmammals%2Ffacts%2Fdomestic-cat&psig=AOvVaw1Udd33s4RkzpO73A7oRUct&ust=1732243754891000&source=images&cd=vfe&opi=89978449&ved=0CBQQjRxqFwoTCIjIkP-07IkDFQAAAAAdAAAAABAE

Relevant log output

No response

@joshuadunning joshuadunning added the bug Something isn't working label Nov 21, 2024
Copy link

Hello @joshuadunning 👋, this issue is being automatically closed and locked because it does not follow the issue template.

@github-actions github-actions bot added the invalid This doesn't seem right label Nov 21, 2024
@github-actions github-actions bot locked as spam and limited conversation to collaborators Nov 21, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working invalid This doesn't seem right
Projects
None yet
Development

No branches or pull requests

1 participant