/// import { CSSProperties } from 'react'; import { BasicConfig, BasicContainer, BasicContainerPropsInterface } from '../../render/core/Container/types'; export declare class InputConfig extends BasicConfig { /** * Input的数据模型Key */ name?: string; /** * Input 分组的配置 */ groups?: { name: string; label: string; }[]; /** * 默认值 */ defaultValue?: string | number; /** * 延迟一定时间再更新数据模型 */ debounce?: number; /** * 输入框类型 * @public * @default text */ inputType: 'text' | 'number' | 'password' | 'email' | 'search'; /** * 输入框ID * @public * @default '' */ id: string; /** * 空间大小 * @public * @default 'default' */ size: 'default' | 'large' | 'small'; /** * 是否禁用 * @public * @default false */ disabled: boolean; /** * 带标签的 input,设置前置标签 * @public * @default '' */ addonBefore: string; /** * 带标签的 input,设置后置标签 * @public * @default '' */ addonAfter: string; /** * 没有输入展示的文字 */ placeholder?: string; /** * 是否可读 */ readOnly?: boolean; /** * 前置图标 */ prefix?: string; /** * 后置图标 */ suffix?: string; /** * 文字检查 */ spellCheck?: boolean; /** * CSS class */ className?: string; /** * 内联CSS属性 */ style?: CSSProperties; /** * 自动聚焦 */ autoFocus?: boolean; } export declare class InputPropsInterface extends BasicContainerPropsInterface { info: InputConfig; } export interface InputStateInterface { /** * inputGroup的选中项 */ selectedName: string; /** * 保存一份数据, 提供debounce功能 */ value: string | number; } declare class AbstractInput extends BasicContainer { private debounce$SetData; constructor(props: InputPropsInterface); componentWillMount(): void; private handleChange(key); componentWillReceiveProps(nextProps: InputPropsInterface): void; private mapOptions(info); private createInputElement(info, value, key); render(): JSX.Element; } export default AbstractInput;