I have an App which needs to Access Photos and Videos from the iPhone Photos App. in iOS 14+ Apple has Introduced new API PHPicker but that still lacks lot of common feature like Cropping image, trimming video.
Issue comes, When you have limited Access instead of Access to all photos, How to handle this?
let authorizationStatus = PHPhotoLibrary.authorizationStatus(for: .readWrite)
switch authorizationStatus {
case .limited:
print("limited authorization granted")
// ?????? -> Display UIImagePicker doesn't behave properly
case .authorized:
print("authorization granted")
self.accessLibrary()
case .notDetermined:
print("Status not determined")
PHPhotoLibrary.requestAuthorization(for: .readWrite) { status in
self.checkPhotoAccess()
}
default:
print("Implement this")
break
}
Do we need to create an intermediate screen fetch all the PHAsset and let user select among those first (Photos for which access is given)?
OR there's another way?
Please suggest