DanXi-Dev / DanXi-swift

A Swift Reimplementation of DanXi
GNU Affero General Public License v3.0
13 stars 3 forks source link

NavigationSplitView has various bugs on iOS 16 #64

Closed singularity-s0 closed 7 months ago

singularity-s0 commented 7 months ago

See this screen recording for details. The issue is only reproducible on iOS 16 devices.

https://github.com/DanXi-Dev/DanXi-swift/assets/12184989/e648ace0-964e-4658-ad11-650f05099743

fsy2001 commented 7 months ago

SwiftUI navigation is a pain in the ass. Current navigation needs a overhaul in future. As a temporary solution, I might use an id modifier on NavigationSplitView to force redraw everything when section changes.

singularity-s0 commented 7 months ago

This originates from SwiftUI bug 91311311

Conditional views in columns of NavigationSplitView fail to update on some state changes. Workaround: Wrap the contents of the column in a ZStack.

Although the workaround does not seem to completely mitigate the bug, we won't invest more efforts into something we can't control. Closing this issue.