From 04c82177246449a42abd564e3fa3d546683f5609 Mon Sep 17 00:00:00 2001 From: desrosj Date: Wed, 9 Sep 2020 16:15:06 +0000 Subject: [PATCH] Administration: Add the `aria-hidden` attribute to admin menu icons. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The admin menu icons are included as a visual element to support the text links. Without the `aria-hidden=“true”` attribute, they are also exposed to assistive technologies (which can process icon fonts in unpredictable ways). This change improves the experience for multiple types of assistive technologies, including screen reading and voice control software. With `aria-hidden=“true”` added, the icons will not be read, and a user can now trigger a click of a top level admin menu item with commands such as “click posts”, or “click plugins”. Props joedolson, afercia, audrasjb, adriantirusli. Fixes #51012. Built from https://develop.svn.wordpress.org/trunk@48963 git-svn-id: http://core.svn.wordpress.org/trunk@48725 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/menu-header.php | 8 ++++---- wp-includes/version.php | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/wp-admin/menu-header.php b/wp-admin/menu-header.php index 5bcffe2bd4..3e81e0bea7 100644 --- a/wp-admin/menu-header.php +++ b/wp-admin/menu-header.php @@ -165,9 +165,9 @@ function _wp_menu_output( $menu, $submenu, $submenu_as_parent = true ) { && ! file_exists( ABSPATH . "/wp-admin/$menu_file" ) ) ) { $admin_is_parent = true; - echo "$arrow"; + echo "$arrow"; } else { - echo "\n\t$arrow"; + echo "\n\t$arrow"; } } elseif ( ! empty( $item[2] ) && current_user_can( $item[1] ) ) { $menu_hook = get_plugin_page_hook( $item[2], 'admin.php' ); @@ -184,9 +184,9 @@ function _wp_menu_output( $menu, $submenu, $submenu_as_parent = true ) { && ! file_exists( ABSPATH . "/wp-admin/$menu_file" ) ) ) { $admin_is_parent = true; - echo "\n\t$arrow"; + echo "\n\t$arrow"; } else { - echo "\n\t$arrow"; + echo "\n\t$arrow"; } } diff --git a/wp-includes/version.php b/wp-includes/version.php index 18d8d7ae7b..c589b0eaf6 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -13,7 +13,7 @@ * * @global string $wp_version */ -$wp_version = '5.6-alpha-48962'; +$wp_version = '5.6-alpha-48963'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.