Open derynia opened 1 day ago
I also found out that when picking a document, not photo everything works fine.
The problem seems to be in PHPickerViewControllerDelegateProtocol which doesn't have
override fun documentPickerWasCancelled(controller: UIDocumentPickerViewController) { onPickerCancelled() }
as UIDocumentPickerDelegateProtocol does. So it seems to be the problem is in native iOS component.
Also I googled this problem and found some kind of solution here:
https://forums.developer.apple.com/forums/thread/704315
But I don't understand at all how to implement it as I'm very weak in Swift.
Hi @derynia! Thanks for reporting this issue! I'm going to take a look.
I have a following composable function
in my viemodel I check if the file is selected I'm starting to upload it. If the selection dialog is dismissed I clear the state of viewmodel to unblock the selectButton
It works fine in Android. But in iOS if I swipe down file selection dialog insead of pressing Cancel button nothing happens. Event is not generated so the code in viewModel is not called. Again if I dismiss by pressing Cancel in selection dialog everything works fine. In Android all ways of dialog dismiss work fine. The problem exists in both simulator and physical devices on iOS18 and earlier versions.