-
-
Notifications
You must be signed in to change notification settings - Fork 50.1k
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
enhance: Improve the a11y of the upload progress bar #42704
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
afc163
approved these changes
May 29, 2023
afc163
changed the title
Improve the a11y of the upload progress bar
feat: Improve the a11y of the upload progress bar
May 29, 2023
CI failed. Use |
Is it better to use https://developer.mozilla.org/en-US/docs/Web/HTML/Element/progress instead of div. |
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## master #42704 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 641 641
Lines 10869 10869
Branches 2944 2944
=========================================
Hits 10869 10869
☔ View full report in Codecov by Sentry. |
afc163
reviewed
May 30, 2023
afc163
reviewed
May 31, 2023
afc163
reviewed
May 31, 2023
afc163
reviewed
May 31, 2023
afc163
reviewed
May 31, 2023
afc163
changed the title
feat: Improve the a11y of the upload progress bar
enhance: Improve the a11y of the upload progress bar
May 31, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
[中文版模板 / Chinese template]
🤔 This is a ...
🔗 Related issue link
fix #42703
💡 Background and solution
The following accessibility features are added to the upload progress:
aria-valuenow
which announces the current progress percentaria-label
which announced the name of the progressaria-labelledby
which announces the associated label of the progress📝 Changelog
☑️ Self-Check before Merge
🚀 Summary
🤖 Generated by Copilot at 2d941d9
Improved the accessibility of the
Progress
andUpload
components by adding new props for custom labels. Refactored some types and imports for clarity and consistency.🔍 Walkthrough
🤖 Generated by Copilot at 2d941d9
ariaLabel
andariaLabelledBy
props toProgress
andUploadFile
interfaces to allow accessible labels for progress and upload components (link, link)props
andfile
to thediv
andProgress
elements inProgress
andListItem
functions respectively (link, link, link)ProgressType
andProgressStatuses
to use brackets instead oftypeof
directly, to avoid confusion with the TypeScript operator (link, link, link)RcUploadProps
ininterface.ts
to match the alphabetical order of the other imported types (link)