WordPress.org

Make WordPress Core


Ignore:
Timestamp:
09/23/2019 12:18:53 PM (2 months ago)
Author:
afercia
Message:

Accessibility: Media: Make screen readers announce the Media search results.

  • adds audible messages via wp.a11y.speak() to announce the search results
  • removes a keyup event that was there only to support old browsers
  • removes aria-modal="true" from the media modal dialog as it prevents the ARIA live regions to be perceived by screen readers
  • triggers the search only after 2 ASCII characters have been typed

Props anevins, antpb, aduth, loreleiaurora, afercia.
Fixes #47146.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/script-loader.php

    r46189 r46239  
    16251625    // To enqueue media-views or media-editor, call wp_enqueue_media().
    16261626    // Both rely on numerous settings, styles, and templates to operate correctly.
    1627     $scripts->add( 'media-views', "/wp-includes/js/media-views$suffix.js", array( 'utils', 'media-models', 'wp-plupload', 'jquery-ui-sortable', 'wp-mediaelement', 'wp-api-request' ), false, 1 );
     1627    $scripts->add( 'media-views', "/wp-includes/js/media-views$suffix.js", array( 'utils', 'media-models', 'wp-plupload', 'jquery-ui-sortable', 'wp-mediaelement', 'wp-api-request', 'wp-a11y' ), false, 1 );
    16281628    $scripts->add( 'media-editor', "/wp-includes/js/media-editor$suffix.js", array( 'shortcode', 'media-views' ), false, 1 );
    16291629    $scripts->add( 'media-audiovideo', "/wp-includes/js/media-audiovideo$suffix.js", array( 'media-editor' ), false, 1 );
Note: See TracChangeset for help on using the changeset viewer.