/** * * This file may have been modified by Bytedance Inc. (“Bytedance Inc.'s Modifications”). * All Bytedance Inc.'s Modifications are Copyright (year) Bytedance Inc.. * * This source code is licensed under the Apache license. * See LICENSE file in the project root for license information. * */ import type { FormInstance } from '../../../../../@ecom/rc-field-form'; import type { FieldProps } from '../../../../../@ecom/rc-field-form/es/Field'; import * as React from 'react'; import useFormItemStatus from '../hooks/useFormItemStatus'; import type { FormItemInputProps } from '../FormItemInput'; import type { FormItemLabelProps, LabelTooltipType } from '../FormItemLabel'; import { TooltipProps } from '../../../tooltip/ToolTip'; declare const ValidateStatuses: ['success', 'warning', 'error', 'validating', '']; export declare type ValidateStatus = (typeof ValidateStatuses)[number]; declare type RenderChildren = (form: FormInstance) => React.ReactNode; declare type RcFieldProps = Omit, 'children'>; declare type ChildrenType = RenderChildren | React.ReactNode; export interface FormItemProps extends FormItemLabelProps, FormItemInputProps, RcFieldProps { prefixCls?: string; noStyle?: boolean; style?: React.CSSProperties; className?: string; children?: ChildrenType; id?: string; hasFeedback?: boolean; validateStatus?: ValidateStatus; required?: boolean; hidden?: boolean; initialValue?: any; messageVariables?: Record; tooltip?: LabelTooltipType; fieldKey?: React.Key | React.Key[]; isTooltipError?: boolean; tooltipMessageProps?: Omit; } declare function InternalFormItem(props: FormItemProps): React.ReactElement; declare type InternalFormItemType = typeof InternalFormItem; interface FormItemInterface extends InternalFormItemType { useStatus: typeof useFormItemStatus; } declare const FormItem: FormItemInterface; export default FormItem;