Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Selectmenu: Tweak ARIA impplementation #931

Closed
wants to merge 1 commit into
from

Conversation

Projects
None yet
2 participants
Owner

jzaefferer commented Mar 7, 2013

Goals: Have the screenreader read the current value, the label and the role on focus. Have it read the selected value when it changes.

Achieved by: Using an initial aria-labelledby pointing at the button itself and the label. Make the button a live region and change the labelledby when the selection changes. Restore the original labelling on blur to get the correct description the next time the button is focused.

Side notes: Updating aria-selected caused NVDA/Firefox to announce "not selected" when changing selection with the open menu. Without it, it instead announces the items as proper menu items (x of n), that's much better.

TODOs: Not sure if removing the menu's labelledby was actually necessary. Though since menu doesn't receive focus, its likely that none of the menu aria changes are necessary. In fact they should probably just be removed.

Tested with: VoiceOver/Safari, NVDA/Firefox, JAWS/IE9. The first two are really solid, JAWS is good enough. Forgot what part it skipped, but we aren't done here anyway.

Selectmenu: Tweak ARIA impplementation
Goals: Have the screenreader read the current value, the label and the role on focus. Have it read the selected value when it changes.

Achieved by: Using an initial aria-labelledby pointing at the button itself and the label. Make the button a live region and change the labelledby when the selection changes. Restore the original labelling on blur to get the correct description the next time the button is focused.

Side notes: Updating aria-selected caused NVDA/Firefox to announce "not selected" when changing selection with the open menu. Without it, it instead announces the items as proper menu items (x of n), that's much better.

TODOs: Not sure if removing the menu's labelledby was actually necessary. Though since menu doesn't receive focus, its likely that none of the menu aria changes are necessary. In fact they should probably just be removed.

Tested with: VoiceOver/Safari, NVDA/Firefox, JAWS/IE9. The first two are really solid, JAWS is good enough. Forgot what part it skipped, but we aren't done here anyway.

@jzaefferer jzaefferer referenced this pull request Mar 7, 2013

Closed

Selectmenu ARIA tweaks #877

Member

fnagel commented on a78c0d8 Mar 8, 2013

My test results on Win7 for the selectmenu-aria2 branch:

FF/NVDA: solid, but does not read value on focus
IE/JAWS: solid, but does not reas role

I've tested the selectmenu branch too and it already meets the above mentioned goals, at least on Windows.
@jzaefferer Could you test the selectmenu branch too and post your results?

Owner

jzaefferer commented Mar 9, 2013

Tried again, after making sure that I'm running latest version of both Firefox and NVDA and could confirm your result. I've just commited a change to the selectmenu branch to remove the aria-selected usage, but beyond that, this implementation is pretty solid. This one works a little better with VoiceOver, but the original is still usable, as long as the user opens the menu first.

I think we spend enough time on this. Let's get this released and focus on fixing remaining bugs along with working with ARIA "vendors" to fix ARIA and its implementations.

@jzaefferer jzaefferer closed this Mar 9, 2013

Member

fnagel commented Mar 9, 2013

Nice, since your change FF/NVDA reads value on focus!
I will update the API docs and we're ready to go!

Member

fnagel commented Mar 9, 2013

Nice, since your change FF/NVDA reads value on focus!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment