Post

Replies

Boosts

Views

Activity

Reply to SwiftUI BottomBar Toolbar on parent view breaks leading navigation swipe on iOS 17.0
The issue is observed also with top toolbar. If you try to swipe upward, but you change your mind and stay at the Detail view then the top toolbar disappears, the back button also disappears and you are stuck. Thanks @domagojbu the workaround works in that case too. struct ToolbarIssueView: View { var body: some View { NavigationStack { NavigationLink { Text("Detail View") .navigationTitle("Detail") .toolbar { ToolbarItemGroup(placement: .navigationBarTrailing) { Text("Problematic view!!!") } } } label: { Text("To Detail View") } .toolbar { // This seems to cause strange behavior ToolbarItem(placement: .bottomBar) { if showBottomBar { Text("Bottom Bar Content") } } } .navigationTitle("Main") } } }
Mar ’24