PolyMeilex / rfd

Rusty File Dialog
MIT License
526 stars 60 forks source link

open os file picker directly on pickfile in wasm #128

Open JustFrederik opened 11 months ago

JustFrederik commented 11 months ago

When using pickfile it creates html code like this:

<div id="rfd-card"><input id="rfd-input" type="file" accept=""><button id="rfd-button">Ok</button></div>

Coud you add an option like set_overlay to AsyncFileDialog which lets you skip this rfd-card and open the os file picker directly? The easiest solution would probably be to add an eventlistener to input instead of button.set_onclick(Some(closure.as_ref().unchecked_ref())); in wasm.rs:94 and add the visibility of the body.

JustFrederik commented 11 months ago

https://github.com/JustFrederik/rfd