react-native-webview: iOS fullscreen Video - Breaks Dimensions API

Bug description:

On iOS, if the webview opens a fullscreen video and the user rotates the device, Dimensions.get('window') (and callbacks) will return height/width switched around. Oddly, Dimensions.get('screen') return the right values.

Works fine on Android.

To Reproduce:

Render a webview that has a video in it. Play the video full screen and rotate the device. Call Dimensions.get('window') on a timeout or an event listener and observe returned values when the device rotates.

Expected behavior:

react-native-webview should not interfere with the Dimensions API.

Screenshots/Videos:

Environment:

  • OS: iOS
  • OS version: 14.3 and 14.4
  • react-native version: 0.62.2
  • react-native-webview version: 11.2.3

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Reactions: 2
  • Comments: 16 (4 by maintainers)

Most upvoted comments

Still a bug.