react-native-youtube-iframe icon indicating copy to clipboard operation
react-native-youtube-iframe copied to clipboard

player becomes non-interactive when wrapper View is position: 'absolute'

Open khldonAlkateeh opened this issue 2 months ago • 0 comments

Inside a panned/zoomed Animated.View (Reanimated + RNGH), the YouTube player renders but doesn’t receive touches when its immediate wrapper View uses position: 'absolute'. The same player inside a normal View works fine.


<Animated.View style={canvasStyle}>
  {/* absolute wrapper: video shows but taps don’t work . i can't play the video*/}
  <View style={{ position: 'absolute', left: 200, top: 200 }}>
    <YouTubeCard card={card} />
  </View>

  {/*  normal wrapper: interactive. works normal. i can play/pause ..etc */}
  <View>
    <YouTubeCard card={card} />
  </View>
</Animated.View>

Only the normally wrapped instance is interactive; the absolute-wrapped instance doesn’t receive touch events(ican't play the video)

Note: position: 'absolute' is required in my canvas (items must be precisely placed), so switching to a normal View isn’t a viable workaround in my case

khldonAlkateeh avatar Oct 25 '25 18:10 khldonAlkateeh