-
Notifications
You must be signed in to change notification settings - Fork 7.5k
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
Fix for accessibility: Modal Dialog Button #3400
Conversation
@gkatsev , @OwenEdwards How do the above changes look ? |
|
Are the translations from Google Translate? The German and Dutch at least aren't right. |
@gkatsev I think the https://github.com/videojs/video.js/blob/master/src/js/close-button.js#L15
@mister-ben is there a specific procedure for adding new text which needs translating? Should it just be added into the |
I think just updating the |
@mister-ben Sure, we could update the template. Also I was using Google translate to translate the text as I do not know many of the languages. |
Google translate really isn't that good, and missing keys won't break anything. I'd let a native speaker add a good translation when they discover there are missing keys, which has happened fairly well organically so far, rather than add poor translations. Again, I think it's worth putting something together that will check for missing translations (again much simpler to check for missing keys) so contributors speaking a language can know what needs addressing. I can see if I can figure something out for that. |
@mister-ben I'm fine with letting native translators translate text. What do you guys think @gkatsev , @OwenEdwards ? |
I've looked at how localize() works, and tested it, and it seems like it can handle both a missing key and So this is more of a style decision than a programmatic decision. Personally, I think having null values in the language files (the second pattern) is confusing, rather than having @mister-ben it would certainly be useful if something could detect whether/which language files are incomplete, and maybe also enforce what you decide about whether null keys are allowed? @vdeshpande can you undo the changes in everything except |
@gkatsev Changes undone , done! |
@mister-ben maybe this tool could be part of the automated checking/maintaining translations? https://github.com/edenspiekermann/translations. @gkatsev should I open a separate issue on "translations maintenance"? Seems like we could add some guidance in CONTRIBUTING.md? |
@@ -256,6 +256,7 @@ class ModalDialog extends Component { | |||
let temp = this.contentEl_; | |||
this.contentEl_ = this.el_; | |||
close = this.addChild('closeButton'); | |||
close.controlText('Close Modal Dialog'); |
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.
I think this would be better like this:
close = this.addChild('closeButton', {controlText: 'Close Modal Dialog'});
It avoids multiple internal calls to controlText()
.
LGTM @OwenEdwards I like the idea of adding some translations maintenance to the CONTRIBUTING.md file. |
yeah, CONTRIBUTING.md needs to be rewritten. It's probably the next thing I'm going to pick up after doing merging a bunch of stuff and making a release. |
Description
This fix is to make the screen reader read the Modal Dialog Close button better.
Specific Changes proposed
Please list the specific changes involved in this pull request.
Requirements Checklist