react-next-dates
Version:
Simple and Customizable DatePicker, DateRangePicker and TimePicker for React.
33 lines (32 loc) • 1.2 kB
TypeScript
import { FC, ReactNode } from 'react';
import { DatePickerInputProps, Modifiers, ModifiersClassNames, NullableDateChangeHandler } from '../../index';
export interface DateRangePickerChildrenProps {
startDateInputProps: DatePickerInputProps;
endDateInputProps: DatePickerInputProps;
openStartDatePicker: () => void;
openEndDatePicker: () => void;
}
export declare type DateRangePickerChildren = (props: DateRangePickerChildrenProps) => ReactNode;
export interface DateRangePickerProps {
locale: Locale;
format?: string;
startDate?: Date | null;
endDate?: Date | null;
minDate?: Date;
maxDate?: Date;
minLength?: number;
maxLength?: number;
modifiers?: Modifiers;
modifiersClassNames?: ModifiersClassNames;
startDatePlaceholder?: string;
endDatePlaceholder?: string;
className?: string;
portalContainer?: Element;
readonlyOnTouch?: boolean;
autoOpen?: boolean;
onStartDateChange?: NullableDateChangeHandler;
onEndDateChange?: NullableDateChangeHandler;
children: DateRangePickerChildren;
}
declare const DateRangePicker: FC<DateRangePickerProps>;
export default DateRangePicker;