UNPKG

@nutui/nutui-react-taro

Version:

京东风格的轻量级移动端 React 组件库,支持一套代码生成 H5 和小程序

24 lines (23 loc) 1.25 kB
import { default as React, FunctionComponent } from 'react'; import { PickerOption, PickerProps } from '../picker/index'; import { BasicComponent } from '../../utils/typings'; export interface DatePickerProps extends BasicComponent { value?: Date; defaultValue?: Date; visible: boolean; title: string; type: 'date' | 'time' | 'year-month' | 'month-day' | 'datehour' | 'datetime' | 'hour-minutes'; showChinese: boolean; minuteStep: number; startDate: Date; endDate: Date; threeDimensional: boolean; pickerProps: Partial<Omit<PickerProps, 'defaultValue' | 'threeDimensional' | 'title' | 'value' | 'onConfirm' | 'onClose' | 'onCancel' | 'onChange'>>; formatter: (type: string, option: PickerOption) => PickerOption; filter: (type: string, option: PickerOption[]) => PickerOption[]; onClose: () => void; onCancel: () => void; onConfirm: (selectedOptions: PickerOption[], selectedValue: (string | number)[]) => void; onChange?: (selectedOptions: PickerOption[], selectedValue: (string | number)[], columnIndex: number) => void; } export declare const DatePicker: FunctionComponent<Partial<DatePickerProps> & Omit<React.HTMLAttributes<HTMLDivElement>, 'onChange' | 'defaultValue'>>;