React-native-navigation: Regression - iOS Statusbar color scheme not working with RN 0.55.3

Created on 4 May 2018  路  5Comments  路  Source: wix/react-native-navigation

Issue Description

There seems to be a regression \ bug with RN 0.55.3 and RNN 1.1.457. Setting the statusBarTextColorScheme and statusBarTextColorSchemeSingleScreen to light have no effect and the status bar text color stays dark.

update

Seems to be broken in RN 0.54.3 as well

Tried both in appStyle:

  appStyle: {
    statusBarTextColorScheme: 'light',
    statusBarTextColorSchemeSingleScreen: 'light',
    ...
  },

and navigatorStyle:

  static navigatorStyle = {
    statusBarTextColorScheme: 'light',
    statusBarTextColorSchemeSingleScreen: 'light',
    ...
  };

Steps to Reproduce / Code Snippets / Screenshots

clone this repo:
https://github.com/odesey/rnn_rn55.git
then run
npm install

react-native start
react-native run-ios


Environment

  • React Native Navigation version: 1.1.457
  • React Native version: 0.55.3
  • Platform(s) (iOS, Android, or both?): iOS
  • Device info (Simulator/Device? OS version? Debug/Release?): Both simulator and device, ios 11.2
looking for contributors

Most helpful comment

I still had this issue but I changed <key>UIViewControllerBasedStatusBarAppearance</key> <false/> to <key>UIViewControllerBasedStatusBarAppearance</key> <true/> in the Info.plist. I hope it helps someone.

All 5 comments

Just some more details...

If I run react-native init and then 'yarn add react-native-navigation`. The bug presents itself.

If I git clone https://github.com/wix/react-native-navigation.git then upgrade the example app to RN 0.55.3 using:

https://github.com/ncuillery/rn-diff

No bug!

Bothe style options work as expected.
statusBarTextColorScheme: 'light'
statusBarTextColorSchemeSingleScreen: 'light'

I had this issue. It was fixed by setting View controller-based status bar appearance in Info.plist to YES. The default for new project is set to NO.

thanks @dyc5828

I still had this issue but I changed <key>UIViewControllerBasedStatusBarAppearance</key> <false/> to <key>UIViewControllerBasedStatusBarAppearance</key> <true/> in the Info.plist. I hope it helps someone.

@timotew Good hour of debugging wasted until finding your comment. Thank you!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

kiroukou picture kiroukou  路  3Comments

yedidyak picture yedidyak  路  3Comments

edcs picture edcs  路  3Comments

birkir picture birkir  路  3Comments

henrikra picture henrikra  路  3Comments