I enabled Mac Catalyst
for an iPad App
and encountered an strange Display Problem
of the Sidebar
.
Code:
@State private var selection: NavigationItem? = .start
NavigationView {
List(selection: $selection) {
NavigationLink(destination: StartView(), tag: NavigationItem.start, selection: $selection) {
Label("Start", systemImage: "square.grid.2x2.fill")
.accessibility(label: Text("Start"))
}
.tag(NavigationItem.start)
// 4 more Items
}
.listStyle(SidebarListStyle())
.navigationBarTitle("Impfpass+")
StartView()
}
Question: This Code produces a Standard Sidebar
on the iPad
, however, as you can see, the Mac Version
is looking strange with this angular design
. How can I achieve the Standard macOS Sidebar Design
?
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…