Open crspybits opened 3 years ago
See .toolbar title method: https://sarunw.com/posts/custom-navigation-bar-title-view-in-swiftui/
This is not just when there is a toolbar. I removed that in the Media Items Details screen, and I still get the back button dissappearing. See also https://developer.apple.com/forums/thread/662449
And add .navigationViewStyle(StackNavigationViewStyle())
to the Media Item Details screen doesn't help. I added it when I didn't have the .toolbar.
Tried replacing RefreshableScrollView
with ScrollView
and that doesn't help.
Tried adding RefreshableScrollView
to the object details view and it seems to help-- seems to delay getting the disappearing nav bar, but it still happens.
I tried adding .navigationBarBackButtonHidden(false)
to the object details view, and it doesn't solve the problem.
Adding both together:
.navigationBarHidden(false) .navigationBarBackButtonHidden(false)
Doesn't solve the problem.
I see in the developer console:
2021-06-29 06:40:34.168910-0600 Neebla[5311:2029685] [Assert] displayModeButtonItem is internally managed and not exposed for DoubleColumn style. Returning an empty, disconnected UIBarButtonItem to fulfill the non-null contract.
This is from debugging the nav bar:
Printing description of $16: <_UIButtonBarButton: 0x125f0ac10; frame = (0 0; 0 44); tintColor = UIExtendedSRGBColorSpace 0.0392157 0.517647 1 1; layer = <CALayer: 0x282d08940>>
See https://developer.apple.com/forums/thread/668433 https://developer.apple.com/forums/thread/660265
The solution suggested here seems to have worked: https://developer.apple.com/forums/thread/660265
I've added .navigationViewStyle(StackNavigationViewStyle())
directly to the NavigationView
-- unfortunately that had to be done in the SideMenu
package.
Unfortunately that does change the background color (and size) of the main album list screen. To:
From:
Dany is seeing this on iPad.
https://stackoverflow.com/questions/65195362/swiftui-navigation-bar-items-disappear-on-ios-14