UNPKG

1.24 kBTypeScriptView Raw
1/// <reference types="react" />
2import React from 'react';
3import ShortcutPanel from './calendar/ShortcutPanel';
4import Header from './calendar/Header';
5import { Models } from './date/DataTypes';
6import PropsType from './CalendarProps';
7export declare type ExtraData = Models.ExtraData;
8export { PropsType };
9export declare class StateType {
10 showTimePicker: boolean;
11 timePickerTitle?: string;
12 startDate?: Date;
13 endDate?: Date;
14 disConfirmBtn?: boolean;
15 clientHight?: number;
16}
17export default class Calendar extends React.PureComponent<PropsType, StateType> {
18 static DefaultHeader: typeof Header;
19 static DefaultShortcut: typeof ShortcutPanel;
20 static defaultProps: PropsType;
21 constructor(props: PropsType);
22 selectDate: (date: Date, useDateTime?: boolean, startDate?: Date | undefined, endDate?: Date | undefined) => StateType;
23 onSelectedDate: (date: Date) => void;
24 onSelectHasDisableDate: (date: Date[]) => void;
25 onClose: () => void;
26 onCancel: () => void;
27 onConfirm: () => void;
28 onTimeChange: (date: Date) => void;
29 onClear: () => void;
30 shortcutSelect: (startDate: Date, endDate: Date) => void;
31 setClientHight: (height: number) => void;
32 render(): JSX.Element;
33}