Pagination affords navigation between pages of content, and it highlights which page is currently in view.
<nav class="mds-pagination__wrapper" aria-label="Pagination Navigation">
<ul class="mds-pagination">
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link mds-pagination__link--disabled" aria-label="Go to First Page" aria-disabled="true" tabindex="-1">
<svg class="mds-icon mds-pagination__icon" aria-hidden="true">
<use xlink:href="/assets/icons/mds_icons.svg#angle-double-left--s"> </use>
</svg>
</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link mds-pagination__link--disabled" aria-label="Go to Previous Page" aria-disabled="true" tabindex="-1">
<svg class="mds-icon mds-pagination__icon" aria-hidden="true">
<use xlink:href="/assets/icons/mds_icons.svg#angle-left--s"> </use>
</svg>
</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link mds-pagination__link--selected" aria-label="Current Page, Page 1" aria-current="page"> 1 </a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 2">2</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 3">3</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 4">4</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 5">5</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 6">6</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 7">7</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 8">8</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Next Page">
<svg class="mds-icon mds-pagination__icon" aria-hidden="true">
<use xlink:href="/assets/icons/mds_icons.svg#angle-right--s"> </use>
</svg>
</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Last Page">
<svg class="mds-icon mds-pagination__icon" aria-hidden="true">
<use xlink:href="/assets/icons/mds_icons.svg#angle-double-right--s"> </use>
</svg>
</a>
</li>
</ul>
</nav>
pagination-left--s
/ pagination-right--s
, increments by one page.pagination-left-double--s
/ pagination-right-double--s
, jumps to the first or last page.<nav class="mds-pagination__wrapper" aria-label="Pagination Navigation">
<ul class="mds-pagination">
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to First Page">
<svg class="mds-icon mds-pagination__icon" aria-hidden="true">
<use xlink:href="/assets/icons/mds_icons.svg#angle-double-left--s"> </use>
</svg> First </a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Previous Page">
<svg class="mds-icon mds-pagination__icon" aria-hidden="true">
<use xlink:href="/assets/icons/mds_icons.svg#angle-left--s"> </use>
</svg> Previous </a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 1">1</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 2">2</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 3">3</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link mds-pagination__link--selected" aria-label="Current Page, Page 4" aria-current="page"> 4 </a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link mds-pagination__link--disabled" aria-label="Go to Next Page" aria-disabled="true" tabindex="-1"> Next
<svg class="mds-icon mds-pagination__icon" aria-hidden="true">
<use xlink:href="/assets/icons/mds_icons.svg#angle-right--s"> </use>
</svg>
</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link mds-pagination__link--disabled" aria-label="Go to Last Page" aria-disabled="true" tabindex="-1"> Last
<svg class="mds-icon mds-pagination__icon" aria-hidden="true">
<use xlink:href="/assets/icons/mds_icons.svg#angle-double-right--s"> </use>
</svg>
</a>
</li>
</ul>
</nav>
<nav class="mds-pagination__wrapper" aria-label="Pagination Navigation">
<ul class="mds-pagination">
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 1">1</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 2">2</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link mds-pagination__link--selected" aria-label="Current Page, Page 3" aria-current="page"> 3 </a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 4">4</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 5">5</a>
</li>
<li class="mds-pagination__item">
<a href="#" class="mds-pagination__link" aria-label="Go to Page 6">6</a>
</li>
</ul>
</nav>
<nav class=”mds-pagination__wrapper” role="navigation" aria-label="Pagination Navigation">
to explicitly communicate that page navigation is present and that it’s intended for pagination.<a href="/page-1" aria-label="Go to Page 1">
. This ensures that the screen readers deliver an appropriate message to a user for each link in the pagination component.<a href="/page-3" aria-label="Current Page, Page 3" aria-current="page">3</a>
.mds-pagination__link--disabled
class, combined with aria-disabled="true"
and tabindex="-1"
to accessibly disable those links.Class | Applies to | Outcome |
---|---|---|
|
|
Applies the selected visual style to a pagination link. Use to indicate the current or active page. Combine with |
|
|
Applies disabled visual style to a pagination link. Combine with |