@amsterdam/design-system-react
Version:
All React components from the Amsterdam Design System. Use it to compose pages in your website or application.
105 lines (104 loc) • 4.15 kB
TypeScript
/**
* @license EUPL-1.2+
* Copyright Gemeente Amsterdam
*/
import type { AnchorHTMLAttributes, ComponentType, HTMLAttributes } from 'react';
export type PaginationProps = HTMLAttributes<HTMLElement> & {
/** The accessible name for the Pagination component. */
accessibleName?: string;
/**
* Connects the component with an internal element that defines its accessible name.
* Note: must be unique for the page.
*/
accessibleNameId?: string;
/** The React component to use for the links. */
linkComponent?: ComponentType<AnchorHTMLAttributes<HTMLAnchorElement>>;
/** The template used to construct the link hrefs. */
linkTemplate: (page: number) => string;
/** The maximum amount of pages shown. Minimum value: 5. */
maxVisiblePages?: number;
/** The accessible name for the link to the next page. */
nextAccessibleName?: string;
/** The visible label for the link to the next page. */
nextLabel?: string;
/**
* @deprecated Use `nextAccessibleName` instead.
* The accessible name for the link to the next page.
*/
nextVisuallyHiddenLabel?: string;
/** The current page number. */
page?: number;
/** The accessible name for the link to the previous page. */
previousAccessibleName?: string;
/** The visible label for the link to the previous page. */
previousLabel?: string;
/**
* @deprecated Use `previousAccessibleName` instead.
* The accessible name for the link to the previous page.
*/
previousVisuallyHiddenLabel?: string;
/** The total amount of pages. */
totalPages: number;
/**
* @deprecated Use `accessibleName` instead.
* The accessible name for the Pagination component.
*/
visuallyHiddenLabel?: string;
/**
* @deprecated Use `accessibleNameId` instead.
* Connects the component with an internal element that defines its accessible name.
* Note: must be unique for the page.
*/
visuallyHiddenLabelId?: string;
};
/**
* @see {@link https://designsystem.amsterdam/?path=/docs/components-navigation-pagination--docs Pagination docs at Amsterdam Design System}
*/
export declare const Pagination: import("react").ForwardRefExoticComponent<HTMLAttributes<HTMLElement> & {
/** The accessible name for the Pagination component. */
accessibleName?: string;
/**
* Connects the component with an internal element that defines its accessible name.
* Note: must be unique for the page.
*/
accessibleNameId?: string;
/** The React component to use for the links. */
linkComponent?: ComponentType<AnchorHTMLAttributes<HTMLAnchorElement>>;
/** The template used to construct the link hrefs. */
linkTemplate: (page: number) => string;
/** The maximum amount of pages shown. Minimum value: 5. */
maxVisiblePages?: number;
/** The accessible name for the link to the next page. */
nextAccessibleName?: string;
/** The visible label for the link to the next page. */
nextLabel?: string;
/**
* @deprecated Use `nextAccessibleName` instead.
* The accessible name for the link to the next page.
*/
nextVisuallyHiddenLabel?: string;
/** The current page number. */
page?: number;
/** The accessible name for the link to the previous page. */
previousAccessibleName?: string;
/** The visible label for the link to the previous page. */
previousLabel?: string;
/**
* @deprecated Use `previousAccessibleName` instead.
* The accessible name for the link to the previous page.
*/
previousVisuallyHiddenLabel?: string;
/** The total amount of pages. */
totalPages: number;
/**
* @deprecated Use `accessibleName` instead.
* The accessible name for the Pagination component.
*/
visuallyHiddenLabel?: string;
/**
* @deprecated Use `accessibleNameId` instead.
* Connects the component with an internal element that defines its accessible name.
* Note: must be unique for the page.
*/
visuallyHiddenLabelId?: string;
} & import("react").RefAttributes<HTMLElement>>;