UNPKG

@uiw/react-form

Version:
23 lines (22 loc) 707 B
import React from 'react'; import { IProps, HTMLInputProps } from '@uiw/utils'; import { FormFieldsProps } from './Form'; import './style/form-item.less'; export interface FormItemProps<T> extends IProps, HTMLInputProps { inline?: boolean; hasError?: boolean; label?: React.ReactNode; required?: boolean; labelFor?: string; labelClassName?: string; help?: React.ReactNode; labelStyle?: React.CSSProperties; initialValue?: string | number | T; validator?: FormFieldsProps<T>['validator']; } export default class FormItem<T> extends React.PureComponent<FormItemProps<T>> { static defaultProps: { prefixCls: string; }; render(): React.JSX.Element; }