/** * TextField Component - Lynx 版 MUI TextField * 100% 一比一复刻 MUI TextField * * TextField 是一个便捷的包装器组件,集成了: * - FormControl * - InputLabel * - Input / OutlinedInput / FilledInput * - FormHelperText * * 对应 MUI: packages/mui-material/src/TextField/TextField.js */ import './TextField.css'; import { InputBaseProps } from '../InputBase'; export interface TextFieldClasses { root: string; } export declare function getTextFieldUtilityClass(slot: string): string; export declare const textFieldClasses: TextFieldClasses; export type TextFieldVariant = 'filled' | 'outlined' | 'standard'; export type TextFieldColor = 'primary' | 'secondary' | 'error' | 'info' | 'success' | 'warning'; export type TextFieldSize = 'small' | 'medium'; export type TextFieldMargin = 'dense' | 'normal' | 'none'; export interface TextFieldProps { /** 自动完成 */ autoComplete?: string; /** 自动聚焦 */ autoFocus?: boolean; /** 子元素 (用于 select) */ children?: any; /** 自定义类名 */ className?: string; /** 颜色 */ color?: TextFieldColor; /** 默认值 */ defaultValue?: any; /** 是否禁用 */ disabled?: boolean; /** 是否错误状态 */ error?: boolean; /** 是否全宽 */ fullWidth?: boolean; /** 帮助文本 */ helperText?: any; /** ID */ id?: string; /** 输入属性 */ inputProps?: Record; /** 输入引用 */ inputRef?: any; /** 标签 */ label?: any; /** 边距 */ margin?: TextFieldMargin; /** 最大行数 */ maxRows?: number; /** 最小行数 */ minRows?: number; /** 是否多行 */ multiline?: boolean; /** 名称 */ name?: string; /** 失焦事件 */ onBlur?: (event?: any) => void; /** 值变化事件 */ onChange?: (event?: any) => void; /** 聚焦事件 */ onFocus?: (event?: any) => void; /** 占位符 */ placeholder?: string; /** 是否必填 */ required?: boolean; /** 行数 */ rows?: number; /** 是否为 select */ select?: boolean; /** 尺寸 */ size?: TextFieldSize; /** 内联样式 */ style?: Record; /** sx 属性 */ sx?: Record; /** 输入类型 */ type?: string; /** 值 */ value?: any; /** 变体 */ variant?: TextFieldVariant; /** InputProps */ InputProps?: Partial; /** InputLabelProps */ InputLabelProps?: Record; /** FormHelperTextProps */ FormHelperTextProps?: Record; } export declare function TextField(props: TextFieldProps): JSX.Element; export default TextField; //# sourceMappingURL=index.d.ts.map