-
Notifications
You must be signed in to change notification settings - Fork 440
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
onClose, Carousel index jumps back to "currentIndex" defined in prop #365
Comments
Any chance you have some input on this @jossmac ? Would love to know what is going wrong here! |
bump... |
I avoided the problem in this way
|
Helped for me. Else we can change currentIndex when navigate between images with onViewChange prop
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Steps to reproduce the behavior:
I'm explicitly defining the
currentIndex
based on state so that when an image is clicked it opens at that index. However, if you navigate to other images from the Modal and then close the Modal it "jumps" the index back to the one set from the state when initially opened, causing a brief image swap while the Modal fades out.Expected behavior:
The index of the Carousel to remain the same onClose
Actual behavior:
Index "jumps" onClose, showing wrong image during modal closing animation.
The text was updated successfully, but these errors were encountered: