react-navigation-shared-element
react-navigation-shared-element copied to clipboard
Shared Element transition not happening when image on second screen is changed by the user.
Hey all! :)
When I transition from Screen 1 -> Screen 2, and then from Screen 2 -> Screen 1, the "image move" transition happens perfectly as it should.
However, I allow the user to change their image on Screen 2, and unfortunately, the "image move" transition back to Screen 1 does not happen.
Interestingly, I'm using a tag that does not change. Here's my implementation.
<SharedElement
id={`item.${this.props.route.params["activity"].id}.photo`}
>
<FastImage
style={{
width: screenWidth - 40,
height: 335,
borderRadius: 8,
}}
source={{
uri:
this.state.activityPhoto,
priority: FastImage.priority.high,
cache: FastImage.cacheControl.web,
}}
resizeMode={FastImage.resizeMode.cover}
/>
</SharedElement>
What may be the issue here if the tags remain unchanged? What may be causing the library to not make the correct image move transition?
Below are the following versions that I'm using:
"react-native-shared-element": "0.8.2"
"react-navigation-shared-element": "^5.0.0-alpha1"
Thanks in advance for the help!