Drag-and-drop of folders on web
- Dominant language
- Rust
- Stars
- 30.6k
- Forks
- 2.1k
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 72
Description
eframe supports drag-dropping files into a web app, but not folders.
According to https://web.dev/patterns/files/drag-and-drop-directories we need to use `DataTransferItem.getAsFileSystemHandle()` which isn’t exposed in `web_sys`: https://docs.rs/web-sys/latest/web_sys/struct.DataTransferItem.html
The relevant code in eframe:
https://github.com/emilk/egui/blob/c8dd3dd01a7ea40b95925b8de11ecfa981eaa738/crates/eframe/src/web/events.rs#L516-L566
Contributor guide
Research direction
Start in crates/eframe/src/web/events.rs around the linked drag-and-drop handling, then compare it with the web.dev directory drag-and-drop pattern and the web_sys DataTransferItem API. The work is complete when folder drops are supported through getAsFileSystemHandle() in the web app without regressing file drops.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust, wasm
- Domain
- frontend, web-dev
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100