Search documentation

Search the documentation and open a page.

Displays a sequence of controls for navigating through pages.

Loading...

Installation

pnpm dlx shadcn@latest add @wirekyt/pagination

Composition

Pagination ├── PaginationFirst (optional) ├── PaginationPrevious ├── PaginationItem ├── PaginationEllipsis (optional) ├── PaginationNext └── PaginationLast (optional)

Examples

Default

Loading...

Icons Only

Loading...

Previous And Next

Loading...

Rows Per Page

Loading...

With A List

Loading...

API Reference

Pagination

PropTypeDefaultDescription
idstring | undefined—Unique identifier used to connect the component parts.
idsElementIds | undefined—Overrides generated identifiers for individual parts.
translationsIntlTranslations | undefined—Configures translations.
countnumber | undefined—Configures count.
pageSizenumber | undefined—Configures page size.
defaultPageSizenumber | undefined—Configures default page size.
siblingCountnumber | undefined—Configures sibling count.
boundaryCountnumber | undefined—Configures boundary count.
pagenumber | undefined—Configures page.
defaultPagenumber | undefined—Configures default page.
onPageChange((details: PageChangeDetails) => void) | undefined—Runs when page changes.
onPageSizeChange((details: PageSizeChangeDetails) => void) | undefined—Runs when page size changes.
type"button" | "link" | undefined—Configures type.
getPageUrl((details: PageUrlDetails) => string) | undefined—Configures get page url.

Context, Hooks, and Types

ExportAPI
PaginationContextRender-prop component that exposes component state and actions.
PaginationRootProviderProvides an externally created API to the component tree.
usePaginationCreates or accesses the component API.
usePaginationContextReturns the nearest component API.