Thank you! I got exactly the same. I was building a simple list-detail interface with NavigationSplitView and wondering why it was not updating the detail contents. Wrapping the column content in ZStack helped.
Just in case others hit it, here’s my code.
struct Thing: Identifiable, Hashable {
let id: UUID
let name: String
}
struct ContentView: View {
let things: [Thing]
@State private var selectedThing: Thing?
var body: some View {
NavigationSplitView {
List(things, selection: $selectedThing) { thing in
NavigationLink(value: thing) {
Text("navlink: \(thing.name)")
}
}
} detail: {
// This is the ZStack wrapper, hopefully won’t be needed when 91311311 is fixed.
ZStack {
if let selectedThing {
Text("There is a thing: \(selectedThing.name)")
} else {
Text("There is no thing.")
}
}
}
}
}