-
Notifications
You must be signed in to change notification settings - Fork 24.2k
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
Add method to hide Navigator.NavigationBar #3005
Comments
Can you please use Stack Overflow to ask questions and tag them with react-native? http://stackoverflow.com/questions/tagged/react-native Many people from the community hang out on Stack Overflow and will be able to see your question. Using Stack Overflow for questions also helps us use Github issues to keep track of bugs that need to be fixed. |
I'll ask on StackOverflow. BTW, I've changed my title to reflect that it is more of a feature request than just a question. |
👍 Thanks @satya164! |
We'd like to avoid imperativeAPI as possible as we can. If you want to make the "hidden" state controllable, you may do this.
Still, if imperativeAPI is what you'd like to have, you can do this:
IMHO, this isn't really the core feature that needs to be backed into the core component and there For now, we're working on refactoring the Navigator API so stabilizing the API is high priority for now. |
@hedgerwang Understood. Looking forward to the improved navigator API. Just returning null won't be enough in my case as I'll want to animate hiding there navbar. I'll try playing with Animated to try and achieve that. Thank you. |
@hedgerwang the imperative approach does not work since it is impossible to get a ref to NavigationBarTwo. A ref callback added to the component that is passed to the Navigator's navigationBar property is never called. I'll try to make some minimal examples. |
Is there a way to hide the
Navigator.NavigationBar
?For example, I have a search button, when it is pressed, I want to hide the navigation bar, and show the search bar in place of it. Is it possible?
It'll be very useful to add such a method, and users will be able to do lots of things like hide navigation bar on scroll etc.
The text was updated successfully, but these errors were encountered: