import React from 'react'; import { BaseEventOrig, ITouchEvent } from '@tarojs/components/types/common'; import { InputProps } from '@tarojs/components/types/Input'; import CompCommon from '../../common/type'; declare type OmitInputProps = Omit; declare type InputFunction = (value: T, event?: BaseEventOrig) => R; declare type InputBaseEventDetail = { value: string | number; }; export declare type InputEventDetail = InputBaseEventDetail & { cursor: number; keyCode: number; }; export declare type FocusEventDetail = InputBaseEventDetail & { height: number; }; export declare type BlurEventDetail = InputBaseEventDetail; export declare type ConfirmEventDetail = InputBaseEventDetail; export declare type KeyboardHeightEventDetail = { height: number; duration: number; }; export interface FieldProps extends OmitInputProps, CompCommon { name?: string; label?: string; type?: 'text' | 'number' | 'password' | 'phone' | 'idcard' | 'digit' | 'textarea'; error?: boolean; errorMessage?: string; clear?: boolean; border?: boolean; disabled?: boolean; placeholder?: string; placeholderStyle?: string; placeholderClass?: string; readonly?: boolean; adjustPosition?: boolean; autoFocus?: boolean; autoHeight?: boolean; textareaHeight?: number; showWordLimit?: boolean; fixed?: boolean; focus?: boolean; required?: boolean; contentColor?: String; isLink?: boolean; linkText?: string; linkSlot?: React.ReactNode; labelClass?: string; labelWidth?: number; labelAlign?: 'center' | 'left' | 'right'; valueAlign?: 'center' | 'left' | 'right'; card?: boolean; leftIcon?: string; rightIcon?: string; iconColor?: string; iconSize?: number; onBlur?: InputFunction; onFocus?: InputFunction; onChange?: InputFunction; onConfirm?: InputFunction; onClick?: (event?: ITouchEvent) => void; onKeyboardHeightChange?: (event?: BaseEventOrig) => void; onErrorClick?: (event?: ITouchEvent) => void; onLink?: () => void; onLeftIconClick?: () => void; onRightIconClick?: () => void; } export {};