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

Improve accessibility of drop–downs #1037

Closed
oleq opened this issue May 23, 2018 · 5 comments
Closed

Improve accessibility of drop–downs #1037

oleq opened this issue May 23, 2018 · 5 comments
Labels
domain:accessibility This issue reports an accessibility problem. domain:ui/ux This issue reports a problem related to UI or UX. squad:features Issue to be handled by the Features team. type:feature This issue reports a feature request (an idea for a new functionality or a missing option).

Comments

@oleq
Copy link
Member

oleq commented May 23, 2018

  1. The screen reader should properly announce that the button has a popup, (Buttons with dropdown should feature proper semantic markup #12258)
    1. The screen reader should explain the way to open it, (this will also be handled by Buttons with dropdown should feature proper semantic markup #12258)
  2. The screen reader focus should move properly to the drop–down and follow the navigation across its content (The placement of focus after opening dropdowns #11838)
  3. Exiting the drop–down should also be explained by the text reader. (not needed as discussed later)
@oleq oleq added type:feature This issue reports a feature request (an idea for a new functionality or a missing option). status:confirmed labels May 23, 2018
@oleq oleq added domain:ui/ux This issue reports a problem related to UI or UX. module:ux labels Dec 11, 2018
@mlewand mlewand added the domain:accessibility This issue reports an accessibility problem. label Jul 15, 2019
@Mgsy Mgsy added this to the backlog milestone Aug 8, 2019
@Reinmar Reinmar removed the module:ux label Jan 15, 2020
@pomek pomek removed this from the backlog milestone Feb 21, 2022
@oleq
Copy link
Member Author

oleq commented Mar 28, 2022

  1. Our dropdowns have no aria-expanded but should have (see an example from w3c https://www.w3.org/TR/wai-aria-practices-1.1/examples/listbox/listbox-collapsible.html)
    • The only places that have that attribute are CollapsibleView (list properties: start index, reversed section) and SplitButtonView (a button for dropdowns with an “extra arrow”).

@wimleers
Copy link

wimleers commented May 31, 2022

AFAICT this overlaps with #11568, #11041, #10368, #3184, #5146, #2000, #3215, #3185, #3176 and #11838.

What seems different about this ticket is that it seems to stress the screen reader aspect.

So I propose to retitle/rescope this to Improve screenreader support of dropdowns, and to do this after it's been made keyboard-accessible. Doing that first is necessary anyway, and may solve some of the problems outlined here 😊

@mlewand mlewand added the squad:features Issue to be handled by the Features team. label Jun 1, 2022
@Comandeer
Copy link
Member

The screen reader should properly announce that the button has a popup,

It can be done by adding the [aria-haspopup] and [aria-expanded] attributes to buttons triggering dropdowns. Depending on what the dropdown is, the [aria-haspopup] attribute can take different values instead of generic true (e.g. menu if the dropdown is some kind of a menu). We also need to ensure that the dropdown itself has an appropriate role (e.g. [role=menu] in case of menu dropdown). ARIA Practices contains a decent menu button sample.

The screen reader should explain the way to open it,

Using the combination of [aria-haspopup] and [aria-expanded] attributes should be enough for that.

The screen reader focus should move properly to the drop–down and follow the navigation across its content,

As @wimleers pointed out, keyboard accessibility will be covered in other issues and should resolve the issue with screen reader focus.

Exiting the drop–down should also be explained by the text reader.

IMO it does not need to be if exiting the dropdown can be done by a standard means (e.g. pressing Esc) and the focus is moved back to the button that opened the dropdown. If really needed, this behavior can be described in the accessibility help dialog (#1014).

@wimleers
Copy link

FYI: tracking this at https://www.drupal.org/project/drupal/issues/3283804 😊

IMO it does not need to be if exiting the dropdown can be done by a standard means

Agreed: having a screen reader speak too much is not a great experience either!

@mlewand
Copy link
Contributor

mlewand commented Aug 16, 2022

Closing this umbrella issue as the only one open part is #12258.

@mlewand mlewand closed this as completed Aug 16, 2022
@CKEditorBot CKEditorBot added this to the upcoming milestone Aug 16, 2022
@Reinmar Reinmar modified the milestones: upcoming, iteration 56 Aug 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain:accessibility This issue reports an accessibility problem. domain:ui/ux This issue reports a problem related to UI or UX. squad:features Issue to be handled by the Features team. type:feature This issue reports a feature request (an idea for a new functionality or a missing option).
Projects
None yet
Development

No branches or pull requests

8 participants