Problem/Motivation

As discussed in the Accessibility meeting
Currently, the result count + additional info are in an <output> element. This is an active element that conveys info to screen readers. However, it will only convey that information when the content of the element changes. This results in a problem - if a filter/search change has the same number of results, the <output> contents do not change, and thus nothing is conveyed to the screen reader.

For example Choose "accessibility" category , amd set the filters to "covered by a security policy" and "maintained". Toggle the "development status" and the result count will be the same. Currently that means the screenreader says nothing, but a screenreader user needs to know the number of results after they choose a new filter, even if the result count is the same. It's relevant information and it's absence could lead to the impression that the operation did not complete.

Steps to reproduce

Proposed resolution

Instead of relying on <output>, use Drupal.announce() for greater control over the information conveyed.

Remaining tasks

  • ✅ File an issue about this project
  • ☐ Manual Testing
  • ☐ Code Review
  • ☐ Accessibility Review
  • ☐ Automated tests needed/written?
Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

Utkarsh_33 created an issue. See original summary.

narendrar’s picture

Issue tags: +Accessibility, +core-mvp

bnjmnm made their first commit to this issue’s fork.

bnjmnm’s picture

Issue summary: View changes
Status: Active » Needs review
narendrar’s picture

Status: Needs review » Needs work

I tested it manually and it seems it is not working properly.
Steps to reproduce:

  1. Select Accessibility category and Covered by a security policy, Maintained and Active as filters.
  2. Reload the page
  3. Open Voiceover and click on filters.
  4. Select Show all as Development Status and then change back to Active. (It does not announce results)
  5. Now change Maintenance Status to Show all (It does not announce results)
  6. Now change Security Advisory Coverage to Show all. (It will announce 43 results, sorted by active installs, which is wrong)
bnjmnm’s picture

Status: Needs work » Needs review

Looks like this needed to account for a 200ms debounce built into Drupal.announce(). Updated MR with something that fixed it for me at least, lets see how it goes!

narendrar’s picture

Status: Needs review » Reviewed & tested by the community

Changes looks good to me. Marking RTBC

tim.plunkett made their first commit to this issue’s fork.

  • tim.plunkett committed 8e48377f on 1.0.x authored by bnjmnm
    Issue #3323531 by bnjmnm, narendraR: Update the screen readers about...
tim.plunkett’s picture

Status: Reviewed & tested by the community » Fixed

Merged, thanks!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.