Skip to content
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

Nav bar disappearing #22

Open
crspybits opened this issue Jun 29, 2021 · 10 comments
Open

Nav bar disappearing #22

crspybits opened this issue Jun 29, 2021 · 10 comments

Comments

@crspybits
Copy link
Member

Dany is seeing this on iPad.

https://stackoverflow.com/questions/65195362/swiftui-navigation-bar-items-disappear-on-ios-14

@crspybits
Copy link
Member Author

@crspybits
Copy link
Member Author

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

@crspybits
Copy link
Member Author

And add .navigationViewStyle(StackNavigationViewStyle()) to the Media Item Details screen doesn't help. I added it when I didn't have the .toolbar.

@crspybits
Copy link
Member Author

Tried replacing RefreshableScrollView with ScrollView and that doesn't help.

@crspybits
Copy link
Member Author

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.

@crspybits
Copy link
Member Author

I tried adding .navigationBarBackButtonHidden(false) to the object details view, and it doesn't solve the problem.

@crspybits
Copy link
Member Author

Adding both together:

.navigationBarHidden(false)
.navigationBarBackButtonHidden(false)

Doesn't solve the problem.

@crspybits
Copy link
Member Author

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>>

@crspybits
Copy link
Member Author

crspybits commented Jun 29, 2021

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:

IMG_0049

From:

IMG_0050

@crspybits
Copy link
Member Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant