Add explicit sizing to sheets on macOS

Give player, download, source, and login sheets minimum frame dimensions on macOS so they open at a usable size instead of collapsing.
This commit is contained in:
Arkadiusz Fal
2026-05-21 18:19:19 +02:00
parent 7cb068c800
commit 64171a9cfb
10 changed files with 197 additions and 147 deletions

View File

@@ -144,6 +144,9 @@ struct ErrorDetailsSheet: View {
#if os(iOS)
.presentationDetents([.medium])
#endif
#if os(macOS)
.frame(minWidth: 450, minHeight: 300)
#endif
}
private func copyToClipboard() {

View File

@@ -227,8 +227,13 @@ struct QualitySelectorView: View {
NavigationStack {
stackRoot
}
#if os(iOS)
.presentationDetents([.medium, .large])
#endif
#if os(macOS)
.frame(minWidth: 450, minHeight: 500)
#endif
#endif
}
@ViewBuilder

View File

@@ -136,7 +136,12 @@ struct QueueManagementSheet: View {
}
}
.presentationDragIndicator(.visible)
#if os(iOS)
.presentationDetents([.medium, .large])
#endif
#if os(macOS)
.frame(minWidth: 450, minHeight: 500)
#endif
}
// MARK: - Views