-
-
Notifications
You must be signed in to change notification settings - Fork 1k
Description
Description
If a component that uses one of the new hook gestures is rendered withing the react 19.2's <Activity> and that activity changes mode (goes from hidden to visible) then the gesture will no longer work.
It's worth noting that the regular Gesture.Tap() API works as expected.
This could be related to #3937 as <Activity> also uses display: "none" under the hood, but I couldn't reproduce this bug using the legacy API on Android. I suspect this has something to do with how <Activity> pauses side-effects of hidden components.
Please see the attached gist for a simple example. No snack since no version of expo go has the gesture handler beta installed.
Tested only on Android using expo 55.0.0-preview.9 development build. I don't have an iOS device on hand to verify if it's also affected
Steps to reproduce
(see attached gist for a simple example)
- Render a component that uses a hook gesture within an
<Activity>withmode="visible" - Change that activity's mode to
hidden - Change it back to
visible - The gesture will no longer be recognized
A link to a Gist, an Expo Snack or a link to a repository based on this template that reproduces the bug.
https://gist.github.com/SewerynKras/5efae42345c44da40a72419c2f8c8e1f
Gesture Handler version
3.0.0-beta.1
React Native version
0.83.1
Platforms
Android
JavaScript runtime
None
Workflow
Using Expo Prebuild or an Expo development build
Architecture
New Architecture (Fabric)
Build type
None
Device
Real device
Device model
No response
Acknowledgements
Yes