Skip to content

WCAG accessibility considerations #102

Description

@npujar

I used this library (version 2.1.4) to paginate a search results page, and it works great. However, it was flagged for several important accessibility related issues.

The pagination number links, disabled next/prev buttons may not compliant with accessibility standards.

  1. Users may find it difficult to understand what page they are currently on or what result set they are looking at because the only way current page number is indicated is through data-num and .active class name.
  2. When a button is disabled, an aria-disabled="true" on that button could be helpful.
  3. Links in pagination control must have descriptive labels and valid hrefs.
  4. The <ul> must also be wrapped in a <nav> tag.

On doing some digging, this article also speaks about similar considerations:
https://www.a11ymatters.com/pattern/pagination/#wrap-the-pagination-links-in-a-nav-element

Is there a way to address these currently, or is there a way to customize the markup of the pagination bar?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions