1 | import React from 'react';
|
2 | import { NativeProps } from '../../utils/native-props';
|
3 | import { DateRange, Page } from './convert';
|
4 | export declare const Context: React.Context<{
|
5 | visible: boolean;
|
6 | }>;
|
7 | export declare type CalendarPickerViewRef = {
|
8 | jumpTo: (page: Page | ((page: Page) => Page)) => void;
|
9 | jumpToToday: () => void;
|
10 | getDateRange: () => DateRange;
|
11 | };
|
12 | export declare type CalendarPickerViewProps = {
|
13 | title?: React.ReactNode;
|
14 | confirmText?: string;
|
15 | weekStartsOn?: 'Monday' | 'Sunday';
|
16 | renderTop?: (date: Date) => React.ReactNode;
|
17 | renderDate?: (date: Date) => React.ReactNode;
|
18 | renderBottom?: (date: Date) => React.ReactNode;
|
19 | allowClear?: boolean;
|
20 | max?: Date;
|
21 | min?: Date;
|
22 | shouldDisableDate?: (date: Date) => boolean;
|
23 | } & ({
|
24 | selectionMode?: undefined;
|
25 | value?: undefined;
|
26 | defaultValue?: undefined;
|
27 | onChange?: undefined;
|
28 | } | {
|
29 | selectionMode: 'single';
|
30 | value?: Date | null;
|
31 | defaultValue?: Date | null;
|
32 | onChange?: (val: Date | null) => void;
|
33 | } | {
|
34 | selectionMode: 'range';
|
35 | value?: [Date, Date] | null;
|
36 | defaultValue?: [Date, Date] | null;
|
37 | onChange?: (val: [Date, Date] | null) => void;
|
38 | }) & NativeProps;
|
39 | export declare const CalendarPickerView: React.ForwardRefExoticComponent<CalendarPickerViewProps & React.RefAttributes<CalendarPickerViewRef>>;
|