You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If we navigate (back) to a user having multiple stories it doesn't always work properly. We're facing two issues.
Remain at previous story
If we were not viewing the first story of user 1 before we swiped to user 2, the story we were viewing is visible for a short moment if we're going back to user 1. Then the first story of user 1 becomes visible (or the next story if saveProgress is enabled).
At Instagram, if you're clicking on a user's avatar it starts with the new story or with the first story if you already viewed them all. But if you're swiping through the stories modal and going back to the previous user, it continues with the story you were viewing before you swiped to the next user (or it starts with the last story if you viewed them all).
Is it possible to remain at the story you were viewing before swiping to the next user (the initial story being visible) after swiping back to the previous user in the stories modal?
Wrong content
I think this issue is more important, since it really is a bug. We're using the renderContent() callback to add extra content on top of the stories. As I said above, when swiping back to the previous user, we see the story which we were viewing the previous time for a short moment. The content for that story keeps visible sometimes after the first story becomes visible.
In the attached video you can see we go back to user 1 with the first story being visible but with the content of the second and third story.
For clarity, the white text at the center (for example, "Story 1") is part of the images. The bottom gradient and bottom text (for example "USER 1 - STORY 3") is rendered using the renderContent() callback.
If we navigate (back) to a user having multiple stories it doesn't always work properly. We're facing two issues.
Remain at previous story
If we were not viewing the first story of user 1 before we swiped to user 2, the story we were viewing is visible for a short moment if we're going back to user 1. Then the first story of user 1 becomes visible (or the next story if
saveProgress
is enabled).At Instagram, if you're clicking on a user's avatar it starts with the new story or with the first story if you already viewed them all. But if you're swiping through the stories modal and going back to the previous user, it continues with the story you were viewing before you swiped to the next user (or it starts with the last story if you viewed them all).
Is it possible to remain at the story you were viewing before swiping to the next user (the initial story being visible) after swiping back to the previous user in the stories modal?
Wrong content
I think this issue is more important, since it really is a bug. We're using the
renderContent()
callback to add extra content on top of the stories. As I said above, when swiping back to the previous user, we see the story which we were viewing the previous time for a short moment. The content for that story keeps visible sometimes after the first story becomes visible.In the attached video you can see we go back to user 1 with the first story being visible but with the content of the second and third story.
For clarity, the white text at the center (for example, "Story 1") is part of the images. The bottom gradient and bottom text (for example "USER 1 - STORY 3") is rendered using the
renderContent()
callback.We tried to fix this by removing the
memo
functions at https://github.com/birdwingo/react-native-instagram-stories/blob/main/src/components/Content/index.tsx (line 32 and 38), but that didn't fix this issue.stories-bugs.mp4
The text was updated successfully, but these errors were encountered: