Skip to content
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

Accessibility is half-baked #17

Open
marcysutton opened this issue Aug 19, 2016 · 2 comments
Open

Accessibility is half-baked #17

marcysutton opened this issue Aug 19, 2016 · 2 comments

Comments

@marcysutton
Copy link

marcysutton commented Aug 19, 2016

Hi, I see there are some ARIA attributes in place for menus. However, the dropdown can't be navigated with the keyboard, and the trigger button is not associated with the menu.

First, the button needs to be bound to the menu–this can be done with aria-controls="theMenuID", aria-haspopup="true", and aria-expanded="true | false".

When the dropdown opens, focus should be sent to the first item (which needs tabindex="0") instead of the unordered list which has tabindex. Using the roving tabindex technique, only one item can be tabbable at a time when the menu is open. You've already got aria-activedescendant working, so the tabindex and focus management portions will get you part of the way there!

Hooking up the escape key to close the menu would be a nice addition, too.

@tigar
Copy link

tigar commented Jun 26, 2020

I'm going to start taking a look at this. Coming here from ant.d component library and really wishing for better accessibility on this component.

@yoyo837
Copy link
Member

yoyo837 commented Jun 26, 2020

ref: #101

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

No branches or pull requests

4 participants