Android cannot touch
I can't touch the button in the layout in my custom layout, even if it's default, I can't touch it. While iOS works normally
same here, cannot close it ou press button inside toast
i tried with z-index: 999; , no resutlt
i still have this bug , cannot push new version of store. any fix please ?
it work on reel android devices but simulator is not working, it was working on both before i'm afraid to don't work on some devices
truncated and cannot click on blue button
same issue here after update to React Native v0.76.1 using react-native-toast-message v2.2.1. So a permanent toast message is a problem because it never disappears
@adrianperomingo
same issue here after update to React Native v0.76.1 using react-native-toast-message v2.2.1. So a permanent toast message is a problem because it never disappears
rollback to 2.2.0 my package.json
"scripts": {
...
"setup": "yarn install && patch-package && cd ios && pod install && cd .. ",
},
"dependencies": {
"react-native-toast-message": "2.2.0",
"patch-package": "^8.0.0",
}
create a patch package like this :
in yourfolder/patches/react-native-toast-message+2.2.0.patch
put this
diff --git a/node_modules/react-native-toast-message/lib/src/hooks/useSlideAnimation.js b/node_modules/react-native-toast-message/lib/src/hooks/useSlideAnimation.js
index 33f0b87..97e2423 100644
--- a/node_modules/react-native-toast-message/lib/src/hooks/useSlideAnimation.js
+++ b/node_modules/react-native-toast-message/lib/src/hooks/useSlideAnimation.js
@@ -16,7 +16,7 @@ export function useSlideAnimation({ position, height, topOffset, bottomOffset, k
const animate = React.useCallback((toValue) => {
Animated.spring(animatedValue.current, {
toValue,
- useNativeDriver,
+ useNativeDriver: true,
friction: 8
}).start();
}, []);
and run patch package with yarn setup
@alainib thank you for the fix, it worked perfectly.
I recommend you to install patch-package in devDependencies
Also, remove from your script setup the part of patch-package and add the script "postinstall": "patch-package". It will be ran after your yarn install automatically
Once again, thanks!
@alainib Thank you for the patch 🙏 I tested it also on 2.2.1, it works fine ! (expo 54 with new architecture). even if this patch looks good (not intrusive and better performances), It really looks like a react native issue :/
@alainib thank you for the fix, it worked perfectly. After updating expo to 52 and all the packages, the Toast stop working.
Hi guys, are you planning to fix this issue? 🙏 Always feeling bad when I need to use patch-package.
I was creating a PR, and I saw this change: https://github.com/freeboub/react-native-toast-message/commit/6a2927564e2340910a1c07bd7b37ca454459f487 It looks like we are trying to workaround react native issues ... BTW: enabling useNativeDriver: true on android should be the good way to do ... here is the fix: https://github.com/calintamas/react-native-toast-message/pull/560
Note: if you are using fully custom Toast (by override each toast type via config props in <Toast>) + you only serve iOS and Android, you can simply just rollback to 2.2.0 as the animation hook is still using the correct value for all native code
for anyone who want to make the PR you can check this part: diff
Note 2:
I even tried using RNGH to fix that with no luck. seems #428 is the main reason the useNativeDriver is turned off.
if anyone get the touch working in 2.2.1+ on Android with latest RN (0.81+) please let us know 🙏
hello, any plan on fixing this?