The trick of calling the onclose callback wasn't correct.
Attach a file by drag & drop or click to upload