import type { MouseEvent, Reducer } from "react"; import type { DateRangePickerCompleteTimeRange, DateRangePickerTimeRange } from "./dateRangePickerTimeRange"; export declare enum DateRangePickerActionTypes { show = "show", dateSelect = "date select", rangeSelect = "range select", mouseDayEnter = "mouse day enter", mouseDayLeave = "mouse day leave", apply = "apply", cancel = "cancel", reset = "reset" } export interface DateRangePickerShowAction { type: DateRangePickerActionTypes.show; payload: boolean; } export interface DateRangePickerDateSelectAction { type: DateRangePickerActionTypes.dateSelect; payload: Date; } export interface DateRangePickerRangeSelectAction { type: DateRangePickerActionTypes.rangeSelect; payload: DateRangePickerCompleteTimeRange; } export interface DateRangePickerMouseEnterAction { type: DateRangePickerActionTypes.mouseDayEnter; payload: Date; meta: { event: MouseEvent; }; } export interface DateRangePickerMouseLeaveAction { type: DateRangePickerActionTypes.mouseDayLeave; meta: { event: MouseEvent; }; } export interface DateRangePickerApplyAction { type: DateRangePickerActionTypes.apply; } export interface DateRangePickerCancelAction { type: DateRangePickerActionTypes.cancel; } export interface DateRangePickerResetAction { type: DateRangePickerActionTypes.reset; } export type DateRangePickerReducerAction = DateRangePickerShowAction | DateRangePickerDateSelectAction | DateRangePickerRangeSelectAction | DateRangePickerMouseEnterAction | DateRangePickerMouseLeaveAction | DateRangePickerApplyAction | DateRangePickerCancelAction | DateRangePickerResetAction; export interface DateRangePickerReducerState { show: boolean; candidateRange: DateRangePickerTimeRange; hovered: Date | null; } export declare const initDateRangePickerReducer: (state: Partial) => DateRangePickerReducerState; export declare const dateRangePickerReducer: Reducer;