UNPKG

@adaptui/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

22 lines (21 loc) 889 B
import { HTMLAttributes } from "react"; import { AriaButtonProps } from "@react-types/button"; import { CalendarProps, DateValue } from "@react-types/calendar"; import { CalendarBaseState } from "./calendar-base-state"; export declare function useCalendarState({ state, ...props }: CalendarStateProps): CalendarState; export declare type CalendarState = { /** Props for the calendar grouping element. */ calendarProps: HTMLAttributes<HTMLElement>; /** Props for the next button. */ nextButtonProps: AriaButtonProps; /** Props for the previous button. */ prevButtonProps: AriaButtonProps; /** A description of the visible date range, for use in the calendar title. */ title: string; }; export declare type CalendarStateProps = CalendarProps<DateValue> & { /** * Object returned by the `useSliderState` hook. */ state: CalendarBaseState; };