import React from 'react'; import { AccessibleIconButtonProps } from '@leafygreen-ui/icon-button'; import { DarkModeProps, LgIdProps } from '@leafygreen-ui/lib'; import { SelectProps } from '@leafygreen-ui/select'; interface PaginationProps extends React.ComponentProps<'div'>, LgIdProps, DarkModeProps { /** * Number of items visible on the current page. */ itemsPerPage?: ExcludeFromTypeInference; /** * Options to be shown in the Select to indicate items per page. */ itemsPerPageOptions?: Array; /** * onChange prop passed to the Select component that controls the items per page. */ onItemsPerPageOptionChange?: SelectProps['onChange']; /** * Current index of page shown (starting from 1) */ currentPage?: number; /** * onChange prop passed to the Select component that controls the current page index. */ onCurrentPageOptionChange?: SelectProps['onChange']; /** * Total number of records. */ numTotalItems?: number; /** * Function called when the back arrow icon is clicked */ onBackArrowClick: AccessibleIconButtonProps['onClick']; /** * Disables the back arrow button. Back arrow button is only disabled on the first page by default */ shouldDisableBackArrow?: boolean; /** * Function called when the forward arrow icon is clicked */ onForwardArrowClick: AccessibleIconButtonProps['onClick']; /** * Disables the forward arrow button. Forward arrow button is only disabled on the last page by default */ shouldDisableForwardArrow?: boolean; } type ExcludeFromTypeInference = [T][T extends number ? 0 : never]; export type { PaginationProps }; //# sourceMappingURL=Pagination.types.d.ts.map