-
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(subs-caps-button): captions items should hide icon from SR #4158
Conversation
01ece2e
to
c59689d
Compare
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 SubCaps menu doesn't render properly with IE11 - I don't know if this was true before this PR, but without it rendering properly it's difficult to review it with JAWS.
Hm... I'll take a look. |
@OwenEdwards are you using |
Awesome, thanks @OwenEdwards. I'll have to look at it some more in IE11. Maybe I'll try the combined-tracks example page directly as well, might be configured differently than my sandbox page at this point. |
Oh, was just able to reproduce what you're seeing @OwenEdwards. I'll investigate. |
@@ -10,7 +10,7 @@ | |||
width: 4em; | |||
@include flex(none); | |||
|
|||
& .vjs-icon-placeholder:before { | |||
& > .vjs-icon-placeholder:before { |
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.
This makes it so that only direct descendants of vjs-control
gets these defaults for icon-placeholder.
In IE11, with the subs-caps menu, the icon-placeholder gets this font-size and the font-size from below applied in that order, so, the menu ends up overflowing and disappearing or looking weird.
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.
LGTM.
We want to visually show that captions items in the subs-caps menu are captions vs subtitles using the captions icon. However, we want to hide this from screen readers. Moreover, we can't display things visually that isn't also conveyed to screen readers.
To do so, I created a Subs Caps Menu Item which adds an icon placeholder for the icon and a localized text of
captions
for screen readers.@OwenEdwards can you review this please? Thanks!