redrob-labs

Pagination

Navigation

About

Page controls for a list that always show the first and last page plus a window around the current page, with proper aria-current and aria-label on every button.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Pagination to your project and fits it to your theme.

Code

How Pagination is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

"use client";

import * as React from "react";
import Pagination from "@/components/ui/pagination";

export default function PaginationDemo() {
  const [page, setPage] = React.useState(5);
  const pageCount = 24;

  return (
    <div className="flex min-h-[200px] w-full items-center justify-center bg-background p-8 text-foreground">
      <Pagination page={page} pageCount={pageCount} onChange={setPage} />
    </div>
  );
}

More by redrob-labs

View all
  • Alert

    Alert

    18
  • Schedule Picker

    Schedule Picker

    15
  • Hero Section

    Hero Section

    7
  • Switch

    Switch

    5
  • Status Card

    Status Card

    4
  • Meter

    Meter

    2
  • Memory Scope

    Memory Scope

    2
  • Accordion

    Accordion

    2

More in Navigation

View all
  • Sidebar

    Sidebar

    224
  • Tabs

    Tabs

    52
  • Navbar with Theme Toggle

    Navbar with Theme Toggle

    40
  • Nav List Card

    Nav List Card

    30
  • Breadcrumb

    Breadcrumb

    12
  • Pagination Ant

    Pagination Ant

    3
  • Pagination

    Pagination

    85
  • Footer 2

    Footer 2

    200