How can I dismiss a view that I presented with a NavigationButton
where the NavigationBar
is hidden.
I intentionally have hidden the NavigationBar so I can put items on top of the NavigationBar in the center which is not possible by default(only trailing and leading).
My current code is this:
NavigationView {
VStack {
...
NavigationButton(destination: SignUpView(), isDetail: true) {
Text("Account erstellen").bold()
.frame(minWidth: 0, maxWidth: .infinity)
.frame(minHeight: 40).padding(.top, 0)
.background(Color.blue)
.foregroundColor(.white)
.cornerRadius(20)
}
...
}
.navigationBarItem(title: Text(""), titleDisplayMode: .inline, hidesBackButton: true)
.navigationBarHidden(true)
}
On SignUp View I have an dismissBtn but without functionality which I want to add now.