0

Code for the thing

let fileBrowser = UIDocumentPickerViewController(documentTypes: listOfAllTypesOfFiles, in: UIDocumentPickerMode.open)
fileBrowser.allowsMultipleSelection = false
fileBrowser.delegate = self
            
navigationController?.present(fileBrowser, animated: true, completion: nil)

Not sure why, but it shows that empty space at the bottom. Anyone knows what that is?

This is how it looks

Alexander
  • 396
  • 1
  • 11
  • that seems like that some of your views try to out-smart either extedned-edges or safe-area or bottom-layout-guideline and it does it wrongly – post more code / info about how to set up your view's contraints or extended edges. – holex Nov 02 '20 at 14:57
  • @holex I'm a bit confused. That's a system component. Originally I had an issue with transparent background of search bar at the top, but it was fixed via appearance. But I don't know how it's possible to overwrite edges for how ui is constructed in system component. – Alexander Nov 03 '20 at 09:35

2 Answers2

1

Found the issue. It was customizing tab bar via appearance. In particular that big chunk of view was some messed up version of shadow image which looks fine in main app, but not so much there. Don't customize your stuff like that people :)

Alexander
  • 396
  • 1
  • 11
1

It turns out that I had a global appearance() customisation causing issues with the document picker.

In my case this was the line causing the issue, removing it enabled the UIDocumentPickerViewController to display correctly.

UITabBar.appearance().isTranslucent = false

I've applied the appearance to my UITabBar directly instead of globally.

Alexander above (although downvoted) helped track the solution. Hope this helps whoever comes after.

revilo
  • 169
  • 1
  • 8