Browse Source

Improved statusbar color

Arnaud Vergnet 2 years ago
parent
commit
b2073747c9
2 changed files with 6 additions and 7 deletions
  1. 5
    6
      App.js
  2. 1
    1
      app.json

+ 5
- 6
App.js View File

@@ -115,13 +115,12 @@ export default class App extends React.Component<Props, State> {
115 115
      * as the android status bar is always set to black.
116 116
      */
117 117
     setupStatusBar() {
118
-        if (Platform.OS === 'ios') {
119
-            if (ThemeManager.getNightMode()) {
120
-                StatusBar.setBarStyle('light-content', true);
121
-            } else {
122
-                StatusBar.setBarStyle('dark-content', true);
123
-            }
118
+        if (ThemeManager.getNightMode()) {
119
+            StatusBar.setBarStyle('light-content', true);
120
+        } else {
121
+            StatusBar.setBarStyle('dark-content', true);
124 122
         }
123
+        StatusBar.setBackgroundColor(ThemeManager.getCurrentTheme().colors.surface, true);
125 124
     }
126 125
 
127 126
     /**

+ 1
- 1
app.json View File

@@ -21,7 +21,7 @@
21 21
       "barStyle": "light-content",
22 22
       "hidden": false,
23 23
       "translucent": false,
24
-      "backgroundColor": "#000000"
24
+      "backgroundColor": "#be1522"
25 25
     },
26 26
     "androidNavigationBar": {
27 27
       "barStyle": "light-content",

Loading…
Cancel
Save