I have trided multiple things but I cannot find the solutions. De left side works fine like this:
struct LeftSidebar: View {
@EnvironmentObject var appState: AppState
var body: some View {
VStack {
List {
NavigationLink(destination: HomeMac()) {
Label("Home", systemImage: "house.fill")
}
Section(header: Text("SF-symbolen")) {
NavigationLink(destination: HomeMac()) {
Label("Alle", systemImage: "square.grid.2x2")
}
// NavigationLink(destination: NieuwView()) {
// Label("Nieuw", systemImage: "star")
// }
}
Spacer()
Button(action: {
appState.logOut()
}) {
HStack {
Image(systemName: "arrow.backward.circle")
Text("Loguit")
}
}
}
.listStyle(SidebarListStyle())
.frame(minWidth: 50)
}
.padding()
}
}
var body: some View {
ZStack {
NavigationView {
LeftSidebar()
.environmentObject(appState)
HomeMac()
RightSidebar()
}
.frame(minWidth: 800, minHeight: 600)
}
}
}
But when I want to try this its not working the same.