/** * Refactor by liuxiangyang on 2021/9/7. */ import React, { Component } from 'react'; import moment from 'moment'; import type { Locale, PanelMode } from 'rc-picker/lib/interface'; import type { Moment } from 'moment'; import type { DatePickerProps, DatePickerState } from './iPicker'; export declare const _PREFIX_CLS: string; declare class DatePicker extends Component { pickerRef: React.RefObject; yearUl?: HTMLDivElement | null; monthUl?: HTMLDivElement | null; constructor(props: DatePickerProps); componentDidMount(): void; componentWillReceiveProps(nextProps: DatePickerProps): void; componentWillUnmount(): void; initOpen: (props: DatePickerProps) => boolean | undefined; initSelectValue: () => void; initValue: ({ value, showTime, picker, locale, format: customFormat, disabledDateValid, disabledDate, onChange }: DatePickerProps) => string | moment.Moment | null | undefined; initFix: () => boolean; generateFormat: (customFormat?: string | string[]) => string; /** * 格式化Input输入内容 */ handleInputFormat: (e: any) => void; /** * 删除尾部分隔符 * @param {dateString} value 日期字符串 * @param {formatString} format 格式字符串 */ deleteTailSeperator: (value: string, format: string) => { value: string; format: string; }; getValue: (value: moment.Moment | string) => string; getShowTimeOptions: (props: DatePickerProps) => {}; getPlacement: () => import("../../wui-core/src/utils/type").PlacementType; handleOpenChange: (open: boolean) => void; handleKeyDown: (e: any) => void; handleBlur: (e: React.FocusEvent) => void; handleFocus: (e: React.FocusEvent) => void; handleClick: (e: React.MouseEvent) => void; _getFormatStartDate: ({ showTime, picker, value, format: customFormat }: DatePickerProps) => moment.Moment | null; handleChange: (value: moment.Moment, dateString: string) => void; handleSelect: (value: moment.Moment) => void; handleOk: (value: moment.Moment) => void; dateRender: (currentDate: moment.Moment, today: moment.Moment) => JSX.Element; monthCellRender: (currentDate: moment.Moment, locale: Locale) => JSX.Element | undefined; generateClearIcon: () => React.ReactNode; iconClick: (e: React.MouseEvent) => void; generateSuffixIcon: (props: DatePickerProps) => React.ReactNode; disabledDate: (current: moment.Moment) => boolean; getPopupContainerDom: (dom: HTMLElement) => HTMLElement; onPanelChange: (viewValue: moment.Moment, mode: PanelMode) => void; cascaderChange: (val: any) => void; onChangeYear: (val: string, index: number) => void; onChangeMonth: (monthValue: string, index: number) => void; clickValue: (e: any) => void; headerSelect: () => JSX.Element; getOptions: () => { label: string; value: string; }[]; render(): JSX.Element; } export default DatePicker;