I have 3 pages: Check, Login, Home.
I want Check to redirect the user to Login or Home depending on the conditions met.
It should redirect so that there is no navigation bar.
I watched JM's video. There's no explanation. The documentation is the same too. This can be seen in the Shell.Current.GoToAsync() example.
How should I do it ?
as described in the docs, you can hide the navigation bar on a page by doing
<ContentPage ...
Shell.NavBarIsVisible="false">
...
</ContentPage>
Related
How do you navigate from a modal popup?
I've opened a modal page using await NavigationService.PushModalAsync() which I'm using as a login page. With a successful login, I'm trying to close the modal and navigate to an account page.
await NavigationService.PopModalAsync();
await NavigationService.PushAsync();
The modal closes, but it will not show the page specified in the PushAsync Method.
Both lines of code run, no errors thrown.
The page the pushasync() goes to, displays fine if the login modal window is skipped.
The above code is in a [RelayCommand] method using community toolkit mvvm
What do I need to do to get the above to work?
Unfortunately your needs cannot be achieved. As mentioned in the figure above, the login page you created is a modal page, therefore it can navigate only to another modal page. When you call PopModalAsync, the login page pops up from ModalStack directly, meanwhile the (moldeless) page at the top of the NavigationStack will appear. And you call PushAsync to navigate to the account page in modal page, it doesn't work.
I'm working on an app that I would like to have the following navigation structure:
I want to have a welcome view with "Sign up" and "Sign in" buttons as most of apps have:
First Page
I would like it to be such that this view doesn't have any navigation view bar at the top but the two buttons will navigate to the appropriate page e.g. the sign in page will ask for just login info, sign up page with ask the user for data.
Sign In Page
This however, while seemingly simple has been very confusing to achieve in SwiftUI when it comes to the iPad. When I try to use the Navigation Link it doesn't work as the links are stuck in a side bar that is hidden. I can't seem to find any solutions that work online as nearly everything is for the iPhone. Can anyone advise how to stop the links being placed in a sidebar on iPad?
Thanks a lot
I'm developing a flutter application and I'm now struggling to understand what is the best way to implement a complex bottom bar navigation.
Here are my requirements:
each button on the nav bar should lead to a different section
each section should be able to have multiple screens inside of it
user can navigate from any page of a section to any page in another section and back
each section should show the last visited page if we come back to it
for example, let's say we have two sections, each made of two pages: SectionOneA, SectionOneB, SectionTwoA, SectionTwoB.
A few use cases:
user navigates from SectionOneB to SectionTwoB by pressing a button inside SectionOneB, when user presses back (on android) from SectionTwoB, we should navigate back to SectionOneB
user navigates to SectionTwoA by the nav bar, then navigates to SectionTwoB via a button in SectionTwoA, then navigates to SectionOneA via the nav bar and then press the SectionTwo icon in the nav bar again. we should show SectionTwoB. if back is pressed we should navigate to SectionTwoA.
in both these examples, when moving from one section to another, the correct nav bar item should be highlighted.
I'm new to flutter so I'm learning as I go. For now, what I've done is using nav bar with PageViewer to switch from section to section, then each section uses a PageViewer to handle switching from page to page. This worked well until I had to implement the first usecase above, at this point it seems to me that it would be quite challenging to implment a proper navigation stack as demanded by the usecase and I feel it would be better to rethink the whole thing, only I've no idea what is the best way to approach this.
A temporary solution would be to also include SectionTwoB in the PageViewer of section one, but that would not allow me to highlight the proper nav bar item.
Any lead on how to approach this? All the examples I find seems too simple and/or I'm failing at understanding how to connect the pieces together. I'm using flutter_bloc as a state management library.
My requirement is as the title. Basically there are three parts: Search Page, Master Page and Detail Page.
I want to include all of these pages into one page and make them navigable. I considered Splitter layout but it could loose the navigation?
Any ideas??
Best regards,
Thanks,
I think this is a common requirement. I would suggest a full-screen layout, having a search bar and a result list on the landing/first page. From there, when a list item is clicked upon, you can navigate to the detail page.
I need the lightblue bar to scroll up (hide) and display the Facebook bar. For example look at this image.
I need the light blue bar (which contains the search bar, refresh button) to be scrolled up, so it hides and displays from the Dark Blue Facebook bar as shown in this image.
I have seen this in many applications but, how can i implement it in my application programatically ?
There's no way to control safari from your app, and since Facebook serves the HTML there's no way to alter that either. So to achieve what you're looking for you could create your own UIWebView and present it modally instead. The issue you'll have here, though, is that you won't have access to the users cookies, so they'll have to log in to Facebook again.