import { Accessibility, FormFieldBehaviorProps } from '@fluentui/accessibility'; import { UIComponentProps, ChildrenComponentProps } from '../../utils'; import { ShorthandValue, FluentComponentStaticProps } from '../../types'; import { TextProps } from '../Text/Text'; import { BoxProps } from '../Box/Box'; import { ComponentWithAs } from '@fluentui/react-bindings'; export interface FormFieldProps extends UIComponentProps, ChildrenComponentProps { /** * Accessibility behavior if overridden by the user. */ accessibility?: Accessibility; /** A control for the form field. */ control?: ShorthandValue; /** The HTML input id. This will be set on the control element and will be use for linking it with the label for correct accessibility. */ id?: string; /** A field can have its label next to instead of above it. */ inline?: boolean; /** A label for the form field. */ label?: ShorthandValue; /** Text message that will be displayed below the control (can be used for error, warning, success messages). */ message?: ShorthandValue; /** The HTML input name. */ name?: string; /** A field can show that input is mandatory. */ required?: boolean; /** The HTML input type. */ type?: string; /** Message to be shown when input has error */ errorMessage?: ShorthandValue; } export declare const formFieldClassName = "ui-form__field"; export declare const formFieldMessageClassName = "ui-form__field__message"; export declare type FormFieldStylesProps = Required> & { hasErrorMessage: boolean; }; /** * A FormField represents a Form element containing a label and an input. */ export declare const FormField: ComponentWithAs<'div', FormFieldProps> & FluentComponentStaticProps;