question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Does not respect hidden StatusBar

See original GitHub issue

I just installed this package in order to fix notch problems on my app. However, I immediately stumbled upon a problem: The inset values don’t make sense to me. I’m getting top: 20 on an iPhone 7, but the iPhone 7 doesn’t have any notches or unsafe areas. At the same time, a Sony Xperia phone that I’m testing with, also without any notches, has top: 0. See below:

Screenshot 2019-11-09 at 13 47 58

What are the values based upon? Is there a way for me to be able to foresee these differences so that I can work around them? I would’ve expected that this library provided the size of the actual unsafe areas, and not to add seemingly arbitrary additional values.

Update Ok, so I’m guessing the 20 additional pixels stem from the status bar. But why is this automatically added, and how come it’s only added on iOS? The status bar is hidden in my app on both Android and iOS, so I can’t really just subtract those 20px in a very convenient way… I’m doing it this way now, but feels like a hack: paddingTop: Platform.OS === 'ios' ? insets.top - 20 : insets.top

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:2
  • Comments:15

github_iconTop GitHub Comments

1reaction
janicduplessiscommented, May 26, 2020

Weird, I can still repro in snack but not locally in my example app. This is going to be hard to investigate.

0reactions
Khuongnbcommented, Dec 15, 2021

Confirm issue still exist in iOS when controlling hidden props of StatusBar with state

Read more comments on GitHub >

github_iconTop Results From Across the Web

[iOS] Hidden status bar not respected. · Issue #62 - GitHub
This SafeAreaView does not respect hidden status bar in iOS as it should. Even, when status bar is hidden, there is a top...
Read more >
hidden - Status bar won't disappear - Stack Overflow
First, Set the "View controller-based status bar appearance" to NO in plist file. Second, in AppDelegate, add this: - (void)application:(UIApplication *) ...
Read more >
Is there *ANY* A11/A12 way to hide/free the status bar space?
But it really doesn't. It allows to hide the *contents* of the status bar, BUT the space there is still covered by an...
Read more >
Configuring the status bar - Expo Documentation
Configuring the status bar while app is loading (Android only). This type of configuration is currently only available on Android.
Read more >
Windows 7 taskbar hides other windows' status bar - Super User
Set the taskbar to Auto-hide. Reboot. Set taskbar NOT to auto-hide. Reboot again.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found