|
I'm using a NavigationSplitView with two columns (SidebarView and ContentView) and a detail view that is a TabView. I want each of the tab views (here, Bingo and Bongo) to have different toolbars but I'm tying myself in knots. Currently I can present a toolbar for the first tab but it doesn't change when the second tab is selected. Even if it did correctly change the toolbar I wouldn't be happy adding the toolbar inside the NavigationSplitView (as happens right now) since I'd have problems executing the button methods properly for each of the intended tab views. Has anyone faced this kind of problem? I know that nesting NavigationViews isn't the way forward so I'm steering clear of that but I'm at the hair pulling stage of debugging.
|
|
Hi. I just refactored your code to use enums instead of strings. Seems like now it works without a hitch.
|
|
|
|
The issue was here
you indicated tag to be optional. If you change them to String this will work as expected as well. |
SPONSORED Still waiting on your CI build? Speed it up ~3x with Blaze - change one line, pay less, keep your existing GitHub workflows. First 25 HWS readers to use code HACKING at checkout get 50% off the first year. Try it now for free!
Sponsor Hacking with Swift and reach the world's largest Swift community!
This topic has been closed due to inactivity, so you can't reply. Please create a new topic if you need to.
All interactions here are governed by our code of conduct.
Link copied to your pasteboard.