mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-06-28 22:30:04 +00:00
General: Remove role="navigation" from nav elements.
Role="navigation" was required for assistive technology to recognize HTML5 element's native ARIA roles while HTML5 and ARIA were being introduced. With the deprecation of IE11, the role attribute is only required when mapping elements that don't have native role. Props costdev, mukesh27. Fixes #54054. git-svn-id: https://develop.svn.wordpress.org/trunk@51967 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -103,7 +103,7 @@ class WP_Widget_Recent_Posts extends WP_Widget {
|
||||
// The title may be filtered: Strip out HTML and make sure the aria-label is never empty.
|
||||
$title = trim( strip_tags( $title ) );
|
||||
$aria_label = $title ? $title : $default_title;
|
||||
echo '<nav role="navigation" aria-label="' . esc_attr( $aria_label ) . '">';
|
||||
echo '<nav aria-label="' . esc_attr( $aria_label ) . '">';
|
||||
}
|
||||
?>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user