UNPKG

@renderlesskit/react

Version:

Collection of headless components/hooks that are accessible, composable, customizable from low level to build your own UI & Design System powered by Reakit

53 lines (52 loc) 3 kB
import * as React from "react"; import { ButtonHTMLProps, ButtonOptions } from "reakit"; import { PaginationStateReturn } from "./PaginationState"; export declare type TGoto = "nextPage" | "prevPage" | "lastPage" | "firstPage" | number; export declare type PaginationButtonOptions = ButtonOptions & Pick<PaginationStateReturn, "currentPage" | "movePage" | "nextPage" | "prevPage" | "firstPage" | "lastPage" | "isAtLastPage" | "isAtFirstPage"> & { goto: TGoto; }; export declare type PaginationButtonHTMLProps = ButtonHTMLProps; export declare type PaginationButtonProps = PaginationButtonOptions & PaginationButtonHTMLProps; export declare const usePaginationButton: { (options?: PaginationButtonOptions | undefined, htmlProps?: ButtonHTMLProps | undefined, unstable_ignoreUseOptions?: boolean | undefined): ButtonHTMLProps; unstable_propsAreEqual: (prev: import("reakit").RoleOptions & { disabled?: boolean | undefined; focusable?: boolean | undefined; } & { unstable_clickOnEnter?: boolean | undefined; unstable_clickOnSpace?: boolean | undefined; } & Pick<PaginationStateReturn, "currentPage" | "isAtFirstPage" | "isAtLastPage" | "movePage" | "nextPage" | "prevPage" | "firstPage" | "lastPage"> & { goto: TGoto; } & React.HTMLAttributes<any> & React.RefAttributes<any> & { wrapElement?: ((element: React.ReactNode) => React.ReactNode) | undefined; } & { disabled?: boolean | undefined; } & React.ButtonHTMLAttributes<any>, next: import("reakit").RoleOptions & { disabled?: boolean | undefined; focusable?: boolean | undefined; } & { unstable_clickOnEnter?: boolean | undefined; unstable_clickOnSpace?: boolean | undefined; } & Pick<PaginationStateReturn, "currentPage" | "isAtFirstPage" | "isAtLastPage" | "movePage" | "nextPage" | "prevPage" | "firstPage" | "lastPage"> & { goto: TGoto; } & React.HTMLAttributes<any> & React.RefAttributes<any> & { wrapElement?: ((element: React.ReactNode) => React.ReactNode) | undefined; } & { disabled?: boolean | undefined; } & React.ButtonHTMLAttributes<any>) => boolean; __keys: readonly any[]; __useOptions: (options: PaginationButtonOptions, htmlProps: ButtonHTMLProps) => PaginationButtonOptions; }; export declare const PaginationButton: import("../system").Component<"button", import("reakit").RoleOptions & { disabled?: boolean | undefined; focusable?: boolean | undefined; } & { unstable_clickOnEnter?: boolean | undefined; unstable_clickOnSpace?: boolean | undefined; } & Pick<PaginationStateReturn, "currentPage" | "isAtFirstPage" | "isAtLastPage" | "movePage" | "nextPage" | "prevPage" | "firstPage" | "lastPage"> & { goto: TGoto; } & React.HTMLAttributes<any> & React.RefAttributes<any> & { wrapElement?: ((element: React.ReactNode) => React.ReactNode) | undefined; } & { disabled?: boolean | undefined; } & React.ButtonHTMLAttributes<any>>;