BetaPublic beta — Read the release notes
Documentation

Pagination

Page navigation with prev/next and page numbers.

Package
@solidiom/pagination
Version
0.0.1-next.0
Status
stable

Preview

This preview uses documentation-only styling. Ship with one of the included recipe outputs (CSS, Tailwind, or UnoCSS) for production styles.

Page navigation with prev/next and page numbers.

Usage

Compose Root, Content, Item, PreviousButton, NextButton, Ellipsis.

import * as Pagination from "@solidiom/pagination"

;<Pagination.Root>Pagination content</Pagination.Root>

Installation

Install the package with pnpm add @solidiom/pagination. The package requires compatible solid-js and @solidjs/web peer dependencies.

Parts

Pagination exposes 6 parts:

  • Rootdata-part="root".
  • Contentdata-part="content".
  • Itemdata-part="item".
  • PreviousButtondata-part="previousbutton".
  • NextButtondata-part="nextbutton".
  • Ellipsisdata-part="ellipsis".

Styling

Pagination carries data-scope="pagination" and data-part attributes on each part for CSS/recipe targeting. State attributes like data-state, data-disabled, and data-highlighted are exposed where applicable.

Keyboard & behavior

KeyBehavior
Enter/SpaceActivates the focused page button.

Composition

Pagination is designed to compose with other primitives. Its parts can be combined with Field, Button, or other primitives as needed.

SSR and hydration

Pagination renders as semantic HTML during server rendering. Interactive behavior (keyboard handlers, state management) activates on hydration without layout shift.