Problem/Motivation

In reviewing #3035331-14: Improve keyboard focus behaviour of vertical tabs in MediaLibraryWidget, @rainbreaw had this to say:

My Media field allows for Audio, Image, and Video. When I use the space key on the Add Media button in the field on a clean form, it loads the modal, with the Audio tab selected.

The screen reader tells me which tab is selected, and the visuals clearly indicate which tab is focused.

Pressing the tab key gets me to the next vertical tab, and tells me which one it is ("link, Video") and so on.

The thing that I wish, however, is that once I get into the select media button, that it would tell me what type of media I'm selecting. I have to remember that I was on Audio first, and then tabbed through the image and video options without selecting them, if I want to be sure of what type of content I'm adding.

After a bit of discussion, we agreed to open a follow-up (i.e., this issue) for that last bit.

Proposed resolution

The checkboxes that select media items in the library should announce the type of media they are selecting to screen readers and other assistive tech.

Remaining tasks

Figure out the best way to do this, then make it happen.

User interface changes

TBD, but the media library will be a little clearer to assistive tech/screen readers.

API changes

None anticipated.

Data model changes

None anticipated.

Release notes snippet

TBD

Comments

phenaproxima created an issue. See original summary.

xjm credited rainbreaw.

xjm’s picture

Category: Feature request » Task
Priority: Normal » Major

Accessibility issues generally aren't features; they're bugs or at least tasks. Calling it a major task for now since it sounds like this could make the form less confusing for non-sighted users, but if it's more of a "would be nice but not a big deal" we can downgrade it back to normal/could-have.

Also adding issue credit for @rainbreaw who identified this issue.

andrewmacpherson’s picture

Priority: Major » Normal

I'm not entirely sure I understand what's proposed.

The problem section here talks about the "Select media button" (Rain's old comment from another issue), but the proposed solution talks about the checkboxes. The issue summary needs clarification.

Based on Rain's comment, at first I thought it meant the footer button which completes the dialog. That button is called "Insert selected", so I guess that's not the one. FWIW, I don't think this button should change.

So if it's the checkboxes...

The thing that I wish, however, is that once I get into the select media button, that it would tell me what type of media I'm selecting. I have to remember that I was on Audio first, and then tabbed through the image and video options without selecting them,

Early designs for the media library grid view included the bundle name as a little badge, but it was axed in the name of keeping the grid clutter free. It's one of the reasons we kept the table listing on admin/content/media-table, which does include the bundle as a column. In the media library dialog, neither the grid nor the table view show the bundle name, but there's a mandatory filter (the "tabs") so it only ever shows items of one bundle.

So is this about including the bundle name in the checkbox name for every media item?

  • Currently these checkboxes are called "Select media-item-label", e.g. "Select green-parrot.jpg".
  • If the bundle name is added, the checkboxes would be named something like "Select bundle: media-item-label", e.g. "Select image: green-parrot.jpg"

I'm not sure about this. It arguably adds clarity, but also adds verbosity. Whichever it is, we're getting into very fine detail here. (I'm not even sure we need the word "select" in the checkbox name, because that's implied by the checkbox role and appearance. I think we kept that for consistency with some other listing or operation, but I forget which.)

  • I'd think we could treat this as a wait-and-see question, and fix it if problems are reported after the module is marked stable. My hunch is it may amount to excessive hand-holding, but who knows?
  • The Berkeley university Web Access team have a screen reader walkthrough test planned (later today, in fact). We could watch how it performs, and/or ask for an opinion on this.
  • For triage, I would class this as extra polish, rather than a fundamental part of the design. Nice to have, not major or blocker.

It would be a departure from patterns elsewhere. The part about having to remember the filter choice you made is true everywhere we have filters. We don't keep repeating the entity bundle all the way down the list.

  • If you use the content-type filter on admin/content, you have to remember the filter you chose as you tab through links, but we don't use the bundle name on the checkboxes there.
    • However, if you explore the whole table row (not just interactive controls), you will encounter the node bundle name as a column. That kind-of serves as a reminder of the filter you applied, but the main reason it's there is because it shows an unfiltered mixture by default.
  • At admin/content/moderated, the situation is similar.
  • Under admin/content/comments, there are two separate pagns listing published and unapproved comments. Once you pick one of those pages, you have to remember which page you are on. The approval state isn't mentioned anywhere in the list of comments itself.
    • Aside: these two comment listings have different link names (secondary tabs), but identical page <title>. That's probably a failure of WCAG page title, so I'll file an issue for that.

Version: 8.8.x-dev » 8.9.x-dev

Drupal 8.8.0-alpha1 will be released the week of October 14th, 2019, which means new developments and disruptive changes should now be targeted against the 8.9.x-dev branch. (Any changes to 8.9.x will also be committed to 9.0.x in preparation for Drupal 9’s release, but some changes like significant feature additions will be deferred to 9.1.x.). For more information see the Drupal 8 and 9 minor version schedule and the Allowed changes during the Drupal 8 and 9 release cycles.

Version: 8.9.x-dev » 9.1.x-dev

Drupal 8.9.0-beta1 was released on March 20, 2020. 8.9.x is the final, long-term support (LTS) minor release of Drupal 8, which means new developments and disruptive changes should now be targeted against the 9.1.x-dev branch. For more information see the Drupal 8 and 9 minor version schedule and the Allowed changes during the Drupal 8 and 9 release cycles.

Version: 9.1.x-dev » 9.2.x-dev

Drupal 9.1.0-alpha1 will be released the week of October 19, 2020, which means new developments and disruptive changes should now be targeted for the 9.2.x-dev branch. For more information see the Drupal 9 minor version schedule and the Allowed changes during the Drupal 9 release cycle.

Version: 9.2.x-dev » 9.3.x-dev

Drupal 9.2.0-alpha1 will be released the week of May 3, 2021, which means new developments and disruptive changes should now be targeted for the 9.3.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.3.x-dev » 9.4.x-dev

Drupal 9.3.0-rc1 was released on November 26, 2021, which means new developments and disruptive changes should now be targeted for the 9.4.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.4.x-dev » 9.5.x-dev

Drupal 9.4.0-alpha1 was released on May 6, 2022, which means new developments and disruptive changes should now be targeted for the 9.5.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.5.x-dev » 10.1.x-dev

Drupal 9.5.0-beta2 and Drupal 10.0.0-beta2 were released on September 29, 2022, which means new developments and disruptive changes should now be targeted for the 10.1.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 10.1.x-dev » 11.x-dev

Drupal core is moving towards using a “main” branch. As an interim step, a new 11.x branch has been opened, as Drupal.org infrastructure cannot currently fully support a branch named main. New developments and disruptive changes should now be targeted for the 11.x branch, which currently accepts only minor-version allowed changes. For more information, see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

chris matthews’s picture

Status: Active » Postponed (maintainer needs more info)

Based on @andrewmacpherson's comments in #4 from 4 years ago I think the status for this issue should at least be changed to Postponed until Andrew's feedback is addressed.

anicoto’s picture

Hi my name is Ana (@anilu) and we are at Drupalcon Atlanta mentored contribution workshop and are working in documentation for Media core module

smustgrave’s picture

wanted to bump 1 more time.

Version: 11.x-dev » main

Drupal core is now using the main branch as the primary development branch. New developments and disruptive changes should now be targeted to the main branch.

Read more in the announcement.