Post

Replies

Boosts

Views

Activity

Reply to TabView more tab has double navigation bar when there's more than five tabs
But in the example above, there are exactly six tabs. If the recommendation is "six or fewer", then I should not have ran into this issue. There are many cases where it does make sense to have more than 6 top level tabs. In my app, each top level tab providing different ways to view user data. Different user might find different set of views as most useful, and thus customize the tab order to their need. Switching to NavigationSplitView is not always a good option, because I don't want user to have to go back to a list of tabs to switch between tabs. That defeats the whole point of tabs. Alternatively if I switch between split view and tab view depending on size class, then I would run into issue with state restoration (e.g. infinite scrolling with a paginated server API) @DTS Engineer, thank you for your comments -- regardless of the alternatives, you do agree with me that there should not be double navigation bars, right? I mean if you are not planning to fix it, IMO a reasonable thing to do is acknowledge it in documentation for TabView that more than 5 tabs are not going to work on compact size classes when each tab has NavigationStack. So that folks can either decide to use UIKit or redesign their UI interface or do something else
Sep ’24