Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@zendeskgarden/react-pagination

Package Overview
Dependencies
Maintainers
1
Versions
250
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@zendeskgarden/react-pagination

Components relating to pagination in the Garden Design System

  • 9.2.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
112K
increased by109.67%
Maintainers
1
Weekly downloads
 
Created
Source

@zendeskgarden/react-pagination npm version

This package includes components relating to pagination in the Garden Design System.

Installation

npm install @zendeskgarden/react-pagination

# Peer Dependencies - Also Required
npm install react react-dom styled-components @zendeskgarden/react-theming

Usage

Offset Pagination

import { ThemeProvider } from '@zendeskgarden/react-theming';
import { OffsetPagination } from '@zendeskgarden/react-pagination';

initialState = {
  currentPage: 1
};

/**
 * Place a `ThemeProvider` at the root of your React application
 */
<ThemeProvider>
  <OffsetPagination
    totalPages={11}
    currentPage={state.currentPage}
    onChange={currentPage => setState({ currentPage })}
  />
</ThemeProvider>;

Cursor Pagination

import { ThemeProvider } from '@zendeskgarden/react-theming';
import { CursorPagination } from '@zendeskgarden/react-pagination';

/**
 * Place a `ThemeProvider` at the root of your React application
 */
<ThemeProvider>
  <CursorPagination aria-label="Cursor pagination">
    <CursorPagination.First>First</CursorPagination.First>
    <CursorPagination.Previous>Previous</CursorPagination.Previous>
    <CursorPagination.Next>Next</CursorPagination.Next>
    <CursorPagination.Last>Last</CursorPagination.Last>
  </CursorPagination>
</ThemeProvider>;

Keywords

FAQs

Package last updated on 21 Nov 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc