With the following code:
import SwiftUI
struct ContentView: View {
@State private var showPopover = false
var body: some View {
NavigationView {
List {
EmptyView()
}
.popover(isPresented: $showPopover, content: EmptyView.init)
.navigationBarItems(
trailing: Button("Show") {
self.showPopover = true
}
)
}
}
}
Follow these steps to reproduce the issue:
- Tap "Show"
- Drag modal down to dismiss
- Tap "Show" again repeatedly
- Notice that there is no effect
- Scroll the List
- Tap "Show" again
- Notice that the modal is shown once again
Fixed as of iOS 14.6, maybe earlier.