0.10.6
This commit is contained in:
commit
92660a4ba0
228 files changed
+24496
No files matched your search
@@ -0,0 +1,18 @@
|
||||
enum MediaPickerRepresentation: Equatable, Sendable {
|
||||
case photo
|
||||
case video
|
||||
}
|
||||
|
||||
enum MediaPickerSelectionPolicy {
|
||||
static func preferredOrder(
|
||||
supportsImage: Bool,
|
||||
supportsVideo: Bool
|
||||
) -> [MediaPickerRepresentation] {
|
||||
// Live Photos can expose both types. Their still image is the most
|
||||
// predictable cross-client representation; a video-only asset keeps
|
||||
// movie first. The second entry is an explicit provider fallback.
|
||||
supportsVideo && !supportsImage
|
||||
? [.video, .photo]
|
||||
: [.photo, .video]
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user