Add support for webkitdirectory with <input type="file" />.
Categories
(Firefox for Android :: Browser Engine, enhancement)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox141 | --- | fixed |
People
(Reporter: danielhunterjacobs, Assigned: m_kato)
References
Details
(Keywords: dev-doc-complete, webcompat:platform-bug, Whiteboard: [fxdroid][group1])
Attachments
(3 files)
User Agent: Mozilla/5.0 (Android 14; Mobile; rv:123.0) Gecko/123.0 Firefox/123.0
Steps to reproduce:
Go to https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/webkitdirectory#result on Firefox on Android and try to select a directory.
Actual results:
I could only select individual files.
Expected results:
I should have been able to upload the full content of a directory.
| Reporter | ||
Comment 1•1 year ago
|
||
This was once https://bugzilla.mozilla.org/show_bug.cgi?id=1426349, but that bug was sent to the Firefox for Android graveyard. https://bugzilla.mozilla.org/show_bug.cgi?id=1426349#c10 said to submit this issue to https://github.com/mozilla-mobile/fenix/, but that's a public archive replaced by https://github.com/mozilla-mobile/firefox-android, and https://github.com/mozilla-mobile/firefox-android/issues/5900 says "All the issues related to Fenix, Focus, Android Components, as well as GeckoView, will remain on Bugzilla."
Comment 2•1 year ago
|
||
This is not supported yet.
Ref: https://caniuse.com/input-file-directory
Related Code:
https://searchfox.org/mozilla-central/rev/7bbc54b70e348a11f9cd12071ada2cb47c8a14e3/modules/libpref/init/StaticPrefList.yaml#4570-4573
https://searchfox.org/mozilla-central/rev/7bbc54b70e348a11f9cd12071ada2cb47c8a14e3/mobile/android/components/geckoview/FilePickerDelegate.sys.mjs#19-24
Comment 3•1 year ago
|
||
The severity field is not set for this bug.
:bclark, could you have a look please?
For more information, please visit BugBot documentation.
Comment 4•1 year ago
|
||
The Bugbug bot thinks this bug should belong to the 'Fenix::Browser Engine' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.
Updated•1 year ago
|
| Reporter | ||
Comment 5•1 year ago
|
||
This is now basically a parity:safari and parity:chrome issue, as https://issues.chromium.org/issues/40248532 has been marked fixed (fixed by code changes in https://issues.chromium.org/issues/40101963), as has https://bugs.webkit.org/show_bug.cgi?id=271705 (fixed by https://github.com/WebKit/WebKit/pull/34675).
Of note is that <input type="file" webkitdirectory> crashes Chrome unconditionally when selecting a folder, but that is being fixed by https://chromium-review.googlesource.com/c/chromium/src/+/5982392.
| Reporter | ||
Updated•1 year ago
|
| Assignee | ||
Updated•9 months ago
|
Updated•8 months ago
|
Updated•7 months ago
|
Updated•7 months ago
|
| Assignee | ||
Comment 6•7 months ago
|
||
| Assignee | ||
Comment 7•7 months ago
|
||
I have implemented folder picker API by bug 1674428. This is
implementation for android components.
The folder picker API is two prompts.
The one is conform prompt. The title and body text is from old Fennec's
resources.
The other is folder picker prompt. This shows document tree intent
(ACTION_OPEN_DOCUMENT_TREE).
Updated•7 months ago
|
Updated•7 months ago
|
Comment 8•7 months ago
|
||
Hey :owlish,
It looks like this bug is a geckoview bug - perhaps something for gecko-reviewers?
Comment 9•7 months ago
|
||
Hi Segun, the patch in question is not GV part of it, it is the front end.
Comment 10•6 months ago
|
||
m_kato - can you contact the Content Design Team for review of the string in the patch, per flod's comment on the patch? Thanks!! Looking forward to this landing and knocking out the highest current siteline webcompat bug!
| Assignee | ||
Comment 11•6 months ago
|
||
(In reply to Randell Jesup [:jesup] (needinfo me) from comment #10)
m_kato - can you contact the Content Design Team for review of the string in the patch, per flod's comment on the patch? Thanks!! Looking forward to this landing and knocking out the highest current siteline webcompat bug!
Yes, filed for them
| Assignee | ||
Updated•6 months ago
|
Updated•6 months ago
|
| Assignee | ||
Comment 12•6 months ago
|
||
We are turning on webkitEntries prefs, so we should pass the
webkitEntries tests.
| Reporter | ||
Comment 13•6 months ago
|
||
Out of curiosity, what is this waiting on? The nit in https://phabricator.services.mozilla.com/D245522#inline-1377545?
| Assignee | ||
Comment 15•5 months ago
|
||
(In reply to Randell Jesup [:jesup] (needinfo me) from comment #14)
See comment 13
Content team have sent a feedback for this at last weekend. So I have to update this fix.
Comment 16•5 months ago
|
||
The requested changes to strings have been made and reviewed but we need to wait for the code freeze to finish before landing.
Comment 17•5 months ago
|
||
We've already waited for 2 months for this. I've queued it for landing we can always back it out before the soft freeze ends if we still think it's too risky to let ride.
Comment 18•5 months ago
|
||
Comment 19•5 months ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/9107d6536395
https://hg.mozilla.org/mozilla-central/rev/061972264cf8
https://hg.mozilla.org/mozilla-central/rev/591bf28a7d70
| Reporter | ||
Comment 20•5 months ago
|
||
Comment 21•5 months ago
|
||
MDN docs work for this can be tracked in https://github.com/mdn/content/issues/40024
| Reporter | ||
Comment 22•5 months ago
|
||
After testing this on Android Firefox with https://codepen.io/danieljacobs/pen/VwodKYg, it looks like this did not include functionality for webkitRelativePath for files chosen for a directory, as all files selected from a folder have a webkitRelativePath of the empty string. This works on every desktop browser and Chrome on Android.
| Reporter | ||
Comment 23•5 months ago
|
||
Note that this is the same test as https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/webkitdirectory#result
| Reporter | ||
Comment 24•5 months ago
|
||
Note that for implementation of webkitRelativePath, you may need to do as was done in https://issues.chromium.org/issues/377716464 and pipe the path to the file name through the file enumeration code, as Android uses Content-URIs for paths by default.
| Reporter | ||
Comment 25•5 months ago
|
||
Description
•