1. components
  2. pagination
  3. react

Pagination

Navigate between multiple pages of content.

IDNameEmailCountry
1Randal LabadieHumberto.Rippin@gmail.comBahamas
2Charlene BinsErin.Schmitt45@hotmail.comPortugal
3Duane KoeppRoberto.Metz36@gmail.comIndonesia
4Terry VeumGarfield69@gmail.comKuwait
5Dr. Marion WillmsErnestina5@yahoo.comNiger
6Jerome CroninAmie.Herzog@hotmail.comSouth Africa
7Nicole Lehner-Veum IMoriah14@yahoo.comCambodia
8Ross SengerAllan_Bartoletti36@yahoo.comNauru
9Antonia BechtelarDanika28@gmail.comTokelau
10Victor GottliebLeonard.Huel-Hilpert26@hotmail.comFrench Southern Territories

Page Size

IDNameEmailCountry
1Courtney BaumbachBreanna.Grady@yahoo.comSouth Africa
2Leona RempelCorbin84@gmail.comEcuador
3Kelly Heidenreich IVKarlie.Boehm@yahoo.comAustria
4Latoya McLaughlinHarmon28@hotmail.comZambia
5Angel KrisMyrl58@gmail.comCape Verde
6Lee Stroman DVMDock72@hotmail.comMali
7Mrs. Nichole HermistonLavada.Upton@yahoo.comLebanon
8Preston JonesTess_OKon96@yahoo.comIceland
9Todd WolfKim67@gmail.comBonaire, Sint Eustatius and Saba
10Muriel SatterfieldRachel_Rogahn@yahoo.comUnited States Minor Outlying Islands

Direction

IDNameEmailCountry
1Delia KuvalisLonny.Emmerich@gmail.comSlovenia
2Jennie AdamsNakia.Nicolas@hotmail.comColombia
3Martin JaskolskiPhilip.Schultz43@gmail.comSwitzerland
4Marion JohnsLila.Rohan46@yahoo.comTonga
5Kelli LubowitzCraig0@yahoo.comSwitzerland
6Micheal Towne IIBernie.Mante94@gmail.comGuernsey
7Vanessa RatkeMagali_Welch97@hotmail.comJersey
8Daniel McKenzieBrandyn0@hotmail.comLiechtenstein
9Gretchen Mohr-Larson DVMGriffin_Wilderman5@yahoo.comMarshall Islands
10Bill WalterGrover22@gmail.comAmerican Samoa

Total Count

For server-side pagination, your data source may be truncated. Make sure to specify the total records using count.

{
"data": [...],
"pagination": {
"page": 1,
"limit": 10,
"count": 500,
}
}
<Pagination
page={response.pagination.page}
count={response.pagination.count}
pageSize={response.pagination.limit}
>
...
</Pagination>

API Reference

Root

Property Default Type
ids -
Partial<{ root: string; ellipsis: (index: number) => string; prevTrigger: string; nextTrigger: string; item: (page: number) => string; }> | undefined
The ids of the elements in the accordion. Useful for composition.
translations -
IntlTranslations | undefined
Specifies the localized strings that identifies the accessibility elements and their states
count -
number | undefined
Total number of data items
pageSize -
number | undefined
The controlled number of data items per page
defaultPageSize 10
number | undefined
The initial number of data items per page when rendered. Use when you don't need to control the page size of the pagination.
siblingCount 1
number | undefined
Number of pages to show beside active page
page -
number | undefined
The controlled active page
defaultPage 1
number | undefined
The initial active page when rendered. Use when you don't need to control the active page of the pagination.
onPageChange -
((details: PageChangeDetails) => void) | undefined
Called when the page number is changed
onPageSizeChange -
((details: PageSizeChangeDetails) => void) | undefined
Called when the page size is changed
type "button"
"button" | "link" | undefined
The type of the trigger element
getPageUrl -
((details: PageUrlDetails) => string) | undefined
Function to generate href attributes for pagination links. Only used when `type` is set to "link".
dir "ltr"
"ltr" | "rtl" | undefined
The document's text/writing direction.
getRootNode -
(() => ShadowRoot | Node | Document) | undefined
A root node to correctly resolve document in custom environments. E.x.: Iframes, Electron.
element -
((attributes: HTMLAttributes<"nav">) => Element) | undefined
Render the element yourself

RootProvider

Property Default Type
value -
PaginationApi<PropTypes>
element -
((attributes: HTMLAttributes<"nav">) => Element) | undefined
Render the element yourself

RootContext

Property Default Type
children -
(pagination: PaginationApi<PropTypes>) => ReactNode

PrevTrigger

Property Default Type
element -
((attributes: HTMLAttributes<"button">) => Element) | undefined
Render the element yourself

Item

Property Default Type
type -
"page"
value -
number
element -
((attributes: HTMLAttributes<"a">) => Element) | undefined
Render the element yourself

Ellipsis

Property Default Type
index -
number
element -
((attributes: HTMLAttributes<"span">) => Element) | undefined
Render the element yourself

NextTrigger

Property Default Type
element -
((attributes: HTMLAttributes<"button">) => Element) | undefined
Render the element yourself