Logo

Component Blueprint

X: 1280 · Y: 720 · Grid: 8px

Pagination

Page navigation primitives with previous, next, active links, ellipsis, disabled states, dropdown pairing, and RTL support.

01 Hero Preview

Grid: 8px · Scale: 1:1

Showing page 6 of 12

02 Usage

TS

import { signal } from '@angular/core';
import { FrPaginationModule } from '@frame-ui-ng/components/pagination';

readonly totalPages = 12;
readonly currentPage = signal(6);

HTML

<p>Showing page {{ currentPage() }} of {{ totalPages }}</p>

<nav
  frPagination
  #pagination="frPagination"
  aria-label="Pagination"
  [(page)]="currentPage"
  [totalPages]="totalPages"
>
  <ul frPaginationContent>
    <li frPaginationItem>
      <button frPaginationPrevious type="button"></button>
    </li>

    @for (page of pagination.pages(); track $index) {
      <li frPaginationItem>
        @if (page === 'ellipsis') {
          <span frPaginationEllipsis></span>
        } @else {
          <button frPaginationLink type="button" [page]="page">
            {{ page }}
          </button>
        }
      </li>
    }

    <li frPaginationItem>
      <button frPaginationNext type="button"></button>
    </li>
  </ul>
</nav>

03 Examples

Basic

Keep page state in your component and render a small window around the current page with ellipsis gaps.

Component Sheet

Grid: 8px · Scale: 1:1

Showing page 6 of 12

Simple

A simple pagination with only page numbers.

Component Sheet

Grid: 8px · Scale: 1:1

Icons Only

Project custom icons into previous and next controls for compact table pagination.

Component Sheet

Grid: 8px · Scale: 1:1

Rows per page

Rows per page

Pair pagination with the dropdown menu primitive for rows-per-page controls.

Component Sheet

Grid: 8px · Scale: 1:1

Disabled

Disable unavailable page controls with the disabled input.

Component Sheet

Grid: 8px · Scale: 1:1

RTL support

Override previous and next text for localized RTL pagination.

Component Sheet

Grid: 8px · Scale: 1:1

04 Custom Styling

Override pagination tokens to customize link shape, active treatment, hover color, and focus ring.

Component Sheet

Grid: 8px · Scale: 1:1

05 Token Inspector

Inspect the pagination root, content, links, active state, controls, and ellipsis.

06 Design Tokens

Pagination defines tokens for layout spacing, link sizing, active and hover states, disabled opacity, focus ring, and ellipsis color.

SCSS


  --frame-pagination-gap: 0.25rem;
  --frame-pagination-color: var(--frame-foreground);
  --frame-pagination-link-size: 2.25rem;
  --frame-pagination-link-min-width: 2.25rem;
  --frame-pagination-link-padding-x: 0.75rem;
  --frame-pagination-link-gap: 0.375rem;
  --frame-pagination-link-radius: var(--frame-radius-md);
  --frame-pagination-link-bg: transparent;
  --frame-pagination-link-color: var(--frame-muted-foreground);
  --frame-pagination-link-border: transparent;
  --frame-pagination-link-hover-bg: var(--frame-accent);
  --frame-pagination-link-hover-color: var(--frame-accent-foreground);
  --frame-pagination-link-active-bg: var(--frame-surface);
  --frame-pagination-link-active-color: var(--frame-foreground);
  --frame-pagination-link-active-border: var(--frame-border);
  --frame-pagination-link-disabled-opacity: 0.5;
  --frame-pagination-ellipsis-color: var(--frame-muted-foreground);