2

I am using following code to import files,

if #available(iOS 14, *) {
        let supportedTypes: [UTType] = [UTType.text, UTType.data]
        let documentPicker = UIDocumentPickerViewController(forOpeningContentTypes: supportedTypes, asCopy: true)
        documentPicker.delegate = self
        documentPicker.modalPresentationStyle = .formSheet
       
        self.present(documentPicker, animated: true, completion: nil)
    }

In the output we can see transparent view between "Recent/Browser" tab bar and document content view.

Here is the screenshot of the output:

image 1 image 2

If I change the presentation style to fullScreen, transparent view will become grey coloured view

documentPicker.modalPresentationStyle = .fullScreen

Here is the screenshot of the fullScreen output:

image 3 image 4

Does anyone know how to resolve this?

1 Answers1

4

Check UITabBar.appearance().isTranslucent property. I had the same problem when this property was false