-
Notifications
You must be signed in to change notification settings - Fork 339
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
Upload file component has no visual target area when dragging and dropping a file #3685
Comments
This is the user agent's native form control. Pretty much all UA's support dragging and dropping of files into inputs, though I'm not aware of any that provide a visual affordance when doing so. We could try rolling our own version of a file upload, but that's not a small ask as we'd likely want to reproduce a fair amount of the native functionality—a visual button, drag and drop, showing the name of the selected file, the option to select multiple files simultaneously, and potentially the We would be investing time and resources into producing something that will, optimistically, equal the functionality of what already exists, and has the potential to be worse. Although I've made a very basic spike to provide a visual affordance on top of the native input, I don't think there's that much value in changing the current component. |
Comment from @davidc-gds on Slack, copied here for posterity:
|
It doesn't seem like there's much appetite for us to do anything here at this time. As such, I'm going to close this issue. The usability issue raised has already been noted in the backlog issue. Discussions about drag and drop functionality, as well as multiple examples of them in use, can be found there: alphagov/govuk-design-system-backlog#49 |
The lack of native drag and drop affordance has been noted on the component's page. |
This issue is from May 2023 external accessibility audit report.
Usability issue
Issue ID:
DAC_Usability_Upload_File_01
URLs:
https://govuk-frontend-pr-3503.herokuapp.com/full-page-examples/upload-your-photo-success
Screen shots
There is no indication provided for users to know that they can drag and drop files onto the page, as well as when doing so, any indication of where they can drop the file, possibly resulting in the file being dropped in an incorrect location and not being successfully added for uploading.
Current code ref(s)
#photo
Cognitive user comments
Solution
Some users rely on visual indication to convey functionality of components to aid them in understanding what is available to them presently on the page. Consider providing some kind of indication on the page that the drag and drop feature is available, and when doing so that there is also an indication of where to drop the file.
The text was updated successfully, but these errors were encountered: