Fix sheets and covers on iOS 14

This commit is contained in:
Arkadiusz Fal
2021-11-30 23:58:11 +01:00
parent 5ef89ac9f4
commit b5ffa5b267
3 changed files with 78 additions and 57 deletions

View File

@@ -318,17 +318,21 @@ struct VideoDetails: View {
.foregroundColor(.secondary)
}
}
.sheet(isPresented: $presentingAddToPlaylist) {
if let video = video {
AddToPlaylistView(video: video)
.background(
EmptyView().sheet(isPresented: $presentingAddToPlaylist) {
if let video = video {
AddToPlaylistView(video: video)
}
}
}
)
#if os(iOS)
.sheet(isPresented: $presentingShareSheet) {
if let shareURL = shareURL {
ShareSheet(activityItems: [shareURL])
.background(
EmptyView().sheet(isPresented: $presentingShareSheet) {
if let shareURL = shareURL {
ShareSheet(activityItems: [shareURL])
}
}
}
)
#endif
}