This repository was archived by the owner on Feb 15, 2019. It is now read-only.
Allow setting statusBar height via route config#263
Open
cooperka wants to merge 1 commit intoexpo:masterfrom
Open
Allow setting statusBar height via route config#263cooperka wants to merge 1 commit intoexpo:masterfrom
cooperka wants to merge 1 commit intoexpo:masterfrom
Conversation
Contributor
|
i get that you want a custom behaviour but most app: on ios: hide the status bar when you open the drawer. |
Author
|
@chirag04 thanks for the input. I explored a few different apps on iOS and they all seem to be slightly different. Several hide the status bar and several don't. Personally I like being able to see the status bar even with the drawer open, and it's nice having the option to do so. |
|
@chirag04 To be fair, that Android behaviour you describe isn't even implemented in ex-navigation yet. |
Contributor
|
You have to set the window translucent value in your values.xml I will post the exact values when I get back on my laptop |
Author
|
Hi @chirag04, any updates on this? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
In the same vein as #104, allow setting the status bar height via route config.
Example
<StackNavigation initialRoute={'home'} defaultRouteConfig={{ navigationBar: { backgroundColor: '#fff', }, + statusBar: { + height: 0, + }, }} />Motivation
I use a custom status bar in order to have it appear on top of my entire app, including the drawer and scrim. I feel like this makes the drawer look nicer when it's open (see screenshot). I'm sure there are other use cases for this as well.