Make WordPress Core


Ignore:
Timestamp:
11/01/2021 09:45:45 PM (3 years ago)
Author:
joedolson
Message:

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.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-content/themes/twentyfourteen/comments.php

    r45932 r51967  
    4747
    4848        <?php if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) : ?>
    49     <nav id="comment-nav-above" class="navigation comment-navigation" role="navigation">
     49    <nav id="comment-nav-above" class="navigation comment-navigation">
    5050        <h1 class="screen-reader-text"><?php _e( 'Comment navigation', 'twentyfourteen' ); ?></h1>
    5151        <div class="nav-previous"><?php previous_comments_link( __( '&larr; Older Comments', 'twentyfourteen' ) ); ?></div>
     
    6767
    6868        <?php if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) : ?>
    69     <nav id="comment-nav-below" class="navigation comment-navigation" role="navigation">
     69    <nav id="comment-nav-below" class="navigation comment-navigation">
    7070        <h1 class="screen-reader-text"><?php _e( 'Comment navigation', 'twentyfourteen' ); ?></h1>
    7171        <div class="nav-previous"><?php previous_comments_link( __( '&larr; Older Comments', 'twentyfourteen' ) ); ?></div>
Note: See TracChangeset for help on using the changeset viewer.