-
Notifications
You must be signed in to change notification settings - Fork 202
Move file-and-directory-entries out of drafts
#2633
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
foolip
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The computed Baseline status is false. Is that because some part of this is deprecated? Or we need compute_from?
|
The MDN page for this API mentions two main entry points — via |
|
Hmm, this might also be broken in Chrome too? See mdn/browser-compat-data#19304 |
Looks like the interface names are different between Firefox and Chromium: dropping files on an The spec disagrees with Chromium: https://wicg.github.io/entries-api/#api-fileentry That said, this code works both in Chromium and Firefox, irrespective of the interface names: <!DOCTYPE html>
<label for="file-input">Drop files on the input</label>
<input type="file" id="file-input" multiple>
<script>
const inputEl = document.getElementById('file-input');
inputEl.addEventListener('change', function(event) {
const entries = inputEl.webkitEntries;
console.log(entries);
});
</script> |
|
There are now three open PRs for file and directory entries: |
This is an extremely old draft feature that we added almost at the very beginning. It kinda works still but overlapping keys are a bit of a fuss.
See also: #2632