In SwiftUI, .popover shows as popover on Mac and iPad, but as .sheet on iPhone (compact size class)
We can use minWidth, minHeight to specify sizes on Mac and iPad.
On iPhone, we can check and wrap it inside NavigationView. Setting navigationTitle without being embedded in NavigationView has not effect
In SwiftUI,
.popover
shows as popover on Mac and iPad, but as.sheet
on iPhone (compact size class)We can use
minWidth, minHeight
to specify sizes on Mac and iPad. On iPhone, we can check and wrap it insideNavigationView
. SettingnavigationTitle
without being embedded inNavigationView
has not effect``