How to simulate click() on file input with Popups blocked?

I just developed an extension allowing users to upload files to Lufi (A service similar to Firefox Send or WeTransfer) by clicking on the icon of the extension or using a command (shortkey).
To select the file, I create an HTMLInputElement in JavaScript and simulate a click on it to open the file selection dialog.
Everything is working fine except if user is blocking popups.
It seems impossible to open this dialog if popups are blocked.

Is there a way to bypass this? Or any other way to ask for the user a file?

I found the best way to solve this it to simply open a new tab with an html file to import files and when done close the tab.