Pagination - Skeleton

Skeleton

  1. components
  2. pagination
  3. react

Pagination

Navigate between multiple pages of content.

IDNameEmailCountry
1Antoinette PredovicDaija_Murray99@yahoo.comCook Islands
2Javier WolfEllis.Romaguera@hotmail.comSouth Sudan
3Dr. Blake RohanKali_Nader40@hotmail.comMozambique
4Ms. Leigh HammesDeangelo89@gmail.comJersey
5Clinton JohnsSarai.Ritchie@yahoo.comEcuador
6Mr. Randy MayerTimmy14@hotmail.comAruba
7Patrick BoyleDamian.Heller@yahoo.comDominica
8Rex StreichElijah7@hotmail.comPalau
9Colleen SengerCedrick92@hotmail.comCambodia
10Lauren SchmelerNicholas.Langworth@yahoo.comCocos (Keeling) Islands

Page Size

IDNameEmailCountry
1Willard KundeJunius_Rice50@hotmail.comTurks and Caicos Islands
2Devin HeidenreichArjun.Rowe@yahoo.comBarbados
3Fannie Crooks IIIPearlie_Jacobs10@gmail.comAustria
4Clifton DickensPercival4@gmail.comNew Zealand
5Vicky BartolettiMadisyn84@hotmail.comAland Islands
6Andres CollierKylee.Wisozk@hotmail.comFrance
7Evan HahnKristina.Balistreri@gmail.comMyanmar
8Gustavo BarrowsAmira.Wilkinson@hotmail.comBelarus
9Danielle PurdyIsai.Auer@gmail.comMartinique
10Frankie MorissettePeggie_Schowalter@gmail.comSaint Pierre and Miquelon

Direction

IDNameEmailCountry
1Nora TorpCale46@gmail.comMalaysia
2Joseph VonMariela_Leffler@hotmail.comSierra Leone
3Willis DickinsonRamiro.Haag84@hotmail.comLuxembourg
4Leona AnkundingIsadore.Mueller68@gmail.comFaroe Islands
5Gladys GerlachSophie_Bechtelar@hotmail.comChina
6Dr. Troy BoganRudy_Schamberger@yahoo.comSouth Georgia and the South Sandwich Islands
7Tricia LabadieTanya.Runolfsdottir96@yahoo.comSaint Vincent and the Grenadines
8Ms. Delores BruenKrista.Quigley@gmail.comCroatia
9Armando ThompsonHattie_Schimmel54@hotmail.comUruguay
10Vera FeilLexi_Breitenberg43@gmail.comJersey

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

Ellipsis

btn preset-tonal pointer-events-none
Property Default Type
index -
number
element -
((attributes: HTMLAttributes<"span">) => Element) | undefined
Render the element yourself

Item

btn preset-tonal cursor-pointer select-none data-selected:preset-filled
Property Default Type
type -
"page"
value -
number
element -
((attributes: HTMLAttributes<"a">) => Element) | undefined
Render the element yourself

NextTrigger

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

PrevTrigger

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

RootProvider

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

Root

inline-flex gap-2 p-2 rounded-container preset-outlined-surface-200-800 w-fit
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

RootContext

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