aria-current is giving an invalid value

Created on 31 August 2023, over 1 year ago
Updated 8 September 2023, over 1 year ago

Problem/Motivation

Follow up to: https://www.drupal.org/project/drupal/issues/2952488 Use aria-current=page in pagination links. Fixed

<nav class="pager" role="navigation" aria-labelledby="pagination-heading">
    <h4 id="pagination-heading" class="visually-hidden">Pagination</h4>
    <ul class="pager__items js-pager__items">
                                                        <li class="pager__item is-active">
                                          <a href="?page=0" title="Current page" aria-current="Current page">
            <span class="visually-hidden">
              Current page
            </span>1</a>
        </li>

The aria-current implementation uses, "Current page" which is not a valid value.

https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attribut...

Steps to reproduce

When accessing a pagination page, the pager will show an accessibility failure because aria-current is not an acceptable value.

Proposed resolution

use an appropriate value. For the current page, this would be, aria-current="page"

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

🐛 Bug report
Status

Fixed

Version

10.1

Component
Markup 

Last updated about 1 month ago

No maintainer
Created by

Live updates comments and jobs are added and updated live.
  • Accessibility

    It affects the ability of people with disabilities or special needs (such as blindness or color-blindness) to use Drupal.

Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024