Pagination: Right to left
usePagination returns the page and ellipsis items for custom layouts. Chevrons flip in right-to-left text.
This adds the example as components/examples/pagination/rtl.tsx, together with the Pagination component and the HextaUI theme tokens it needs.
pnpm dlx shadcn@latest add https://hextaui.com/r/pagination-rtl.jsonTo add only the component, follow the Pagination installation.
Props in this example
The Pagination props this example sets, from the API reference.
| Prop | Type | Default |
|---|---|---|
isActiveMarks the current page with aria-current="page". | boolean | false |
render | ReactElement | (props, state) => ReactElement | <a> |
Every prop is in the Pagination API reference.
See them all, with keyboard support and accessibility notes, on the Pagination page.
- ButtonButtons in every variant and size, with a built-in loading, success and error flow that skips the spinner for fast requests.
- MotionThe easing curves, durations and reduced-motion check every component animates with, plus hooks for size morphs and sliding highlights.
- usePaginationTurns a page and a page count into the list of pages and ellipses to render, keeping its length steady as the page moves.
- BreadcrumbA trail of links to the current page that wraps safely, mirrors in right-to-left layouts and expands collapsed segments in place.
- Navigation menuSite navigation with dropdowns, or one full-width panel that stays open while its content slides between menus.
- SidebarAn app sidebar that collapses to icons or off canvas, stays pinned under your header, and becomes a swipeable sheet on phones.