import type { ComponentClass, ForwardedRef, Component } from 'react'; import { RangeValue, Locale as RcPickerLocale } from 'rc-picker/lib/interface'; import { PickerBaseProps as RCPickerBaseProps, PickerDateProps as RCPickerDateProps, PickerTimeProps as RCPickerTimeProps } from 'rc-picker/lib/Picker'; import { RangePickerProps } from 'rc-picker'; declare type SizeType = 'L' | 'M' | 'S' | 'XS'; export declare type DateOutputFormat = 'iso' | 'utc'; export declare function toArray(list: T | T[]): T[]; declare type InjectDefaultProps = Omit & { locale?: PickerLocale; size?: SizeType; borderless?: boolean; alert?: boolean; dateOutputFormat?: DateOutputFormat; }; export interface TimePickerLocale { placeholder?: string; rangePlaceholder?: [string, string]; } export declare type PickerLocale = { lang: RcPickerLocale & AdditionalPickerLocaleLangProps; } & AdditionalPickerLocaleProps; export declare type AdditionalPickerLocaleProps = { dateFormat?: string; dateTimeFormat?: string; weekFormat?: string; monthFormat?: string; }; export declare type AdditionalPickerLocaleLangProps = { placeholder: string; yearPlaceholder?: string; quarterPlaceholder?: string; monthPlaceholder?: string; weekPlaceholder?: string; rangeYearPlaceholder?: [string, string]; rangeMonthPlaceholder?: [string, string]; rangeWeekPlaceholder?: [string, string]; rangePlaceholder?: [string, string]; }; export declare type PickerBaseProps = InjectDefaultProps>; export declare type PickerDateProps = InjectDefaultProps>; export declare type PickerTimeProps = InjectDefaultProps>; export declare type PickerRangeProps = InjectDefaultProps & { showTime?: boolean; }>; export declare type PickerProps = PickerBaseProps | PickerDateProps | PickerTimeProps; export declare type PickerRangeValue = RangeValue; export interface CommonPickerMethods { focus: () => void; blur: () => void; } export interface PickerComponentClass

extends ComponentClass { new (...args: ConstructorParameters>): InstanceType> & CommonPickerMethods; } export declare type PickerRef

= ForwardedRef & CommonPickerMethods>; export declare type DatePickRef = PickerRef>; export {};