UNPKG

reablocks

Version:
67 lines (66 loc) 1.66 kB
import { FC, ReactNode } from 'react'; import { PagerTheme } from './PagerTheme'; export interface PagerProps { /** * The class name to add to the pager. */ className?: string; /** * The class name to add to the page buttons. */ pageClassName?: string; /** * The class name for the active page button. */ activePageClassName?: string; /** * The class name to add to the pages container. */ pagesContainerClassName?: string; /** * The current page number. */ page: number; /** * The number of items per page. */ size: number; /** * The total number of items. */ total: number; /** * The React node or string to use for the previous arrow. * @default <PreviousArrow /> */ previousArrow?: ReactNode | string; /** * The React node or string to use for the next arrow. * @default <NextArrow /> */ nextArrow?: ReactNode | string; /** * The React node or string to use for the start arrow. * @default <StartArrow /> */ startArrow?: ReactNode | string; /** * The React node or string to use for the end arrow. * @default <EndArrow /> */ endArrow?: ReactNode | string; /** * A callback function that is called when the page changes. */ onPageChange?: (page: number) => void; /** * The type of table data for the pager to display. * @default 'pages' */ displayMode?: 'pages' | 'items' | 'all'; /** * The theme for the Pager. */ theme?: PagerTheme; } export declare const Pager: FC<PagerProps>;