react-native-youtube-iframe
react-native-youtube-iframe copied to clipboard
Statistic button responses on Pixel 6 Pro Android 12
Describe the bug Here's a video with the issue:
https://user-images.githubusercontent.com/5567310/152987697-27233894-331b-4e0b-930b-873912a9e905.mp4
As you can see there are two issues:
- The settings menu appears without me doing anything
- Some buttons need more than one press to work, I tried pressing in different variations, but the result is the same (Note that the timeline works just fine, no issues there)
To Reproduce I only have the video, I tried on a Pixel 3 Android 12 emulator and it works as expected, sadly there's no Pixel 6 Pro emulator
Expected behavior Buttons should work, settings shouldn't appear without me pressing them
Smartphone (please complete the following information):
- Device: Pixel 6 Pro
- OS + version: Android 12
-
react-native-youtube-iframe
version: 2.2.2 -
react-native-webview
version: 11.17.1 -
Expo
verison [if using expo]: Not using
Additional context This happens both on debug and release
Encountered the same issue on all of the devices. I tried using past versions,... didn't work =(( .
YouTube doesn't really give us any options to disable this context menu. (we get the same menu on desktop when we right-click)
I've mentioned the problem some possible workarounds here : https://lonelycpp.github.io/react-native-youtube-iframe/remove-context-share
did you guys try this?
That means that the user will no longer have access to other controls =((
Although the context menu is annoying, the bigger issue here is buttons not responding statistically.
The workaround is also not a good solution because you can't start a video that wasn't set to auto play.
You can map a boolean state to play prop, and trigger the state whenever the upper Pressable is tapped
yep, all these are hackish workarounds.
if you guys figure out a good way to avoid the "long press context menu", let me know. I'll add it in the docs :)
I just remembered I opened this issue, so I figured out I might as well update with what was the real issue and the fix for me.
I've been using YoutubePlayer
inside a Modal
component by react-native-modals
. The library is not maintained and it has issues with Touchable items in it on Android, we've had issues with buttons not working reliably.
The fix was to use another library, I migrated to react-native-modal
and I can happily say that now there are 0 issues in the player!
Cheers.
I am having the same issue for react-native-modalize
The video is inside a ScrollView, inside a Modal.
I am having the same issue for
react-native-modalize
The video is inside a ScrollView, inside a Modal.
The issue is not with this library (youtube player), try migrating to react-native-modal instead