Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BottomSheet safe area insets are not set to expected values #4150

Open
twstokes opened this issue Oct 22, 2021 · 0 comments
Open

BottomSheet safe area insets are not set to expected values #4150

twstokes opened this issue Oct 22, 2021 · 0 comments
Labels
[OS] iOS [Type] Bug Something isn't working

Comments

@twstokes
Copy link
Contributor

Describe the bug

The onSafeAreaInsetsUpdate callback in the BottomSheet component does not receive the expected values when a full screen sheet is rotated from portrait -> landscape -> portrait.

To Reproduce

Prerequisites:

Steps to reproduce:

  1. In the portrait orientation, open the block editor in WPiOS by creating a new post.
  2. Tap the three dots at the top right.
  3. Tap "Help & Support".
  4. Observe that the top of the view is under the notch and observe the value for the result object in the callback.
  5. Rotate the device into landscape.
  6. Rotate the device back to portrait.
  7. Observe that the top of the view is level with the notch and observe the value for the result object in the callback does not match the value from step 4 (specifically the safeAreaInsets.top value).

Expected behavior

The top of the sheet view abides by the Safe Area boundaries and safeAreaInsets is consistent for the two orientations.

Smartphone

  • Device: iPhone 12
  • OS: iOS 14 & 15
  • Version: 1.64.0

Additional context

Please see previous discussions here.

We're currently using this library to compute the safe areas and we may need to consider an alternative approach.

@twstokes twstokes added [Type] Bug Something isn't working [OS] iOS labels Oct 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[OS] iOS [Type] Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant