Leave Yamada UI a star

Star
Yamada UIYamada UIv1.7.2

FormControl

FormControl is a component used to group form elements with label, helper message, error message, etc.

Source@yamada-ui/form-control

Props

FormControlProps

disabled

Description

If true, the form control will be disabled.

Type

boolean

Default

false

errorMessage

Description

The form control error message to use.

Type

type ONLY_FOR_FORMAT = | string | number | boolean | ReactElement<any, string | JSXElementConstructor<any>> | Iterable<ReactNode> | ReactPortal

errorMessageProps

Description

Props the error message component.

Type

ErrorMessageProps

helperMessage

Description

The form control helper message to use.

Type

type ONLY_FOR_FORMAT = | string | number | boolean | ReactElement<any, string | JSXElementConstructor<any>> | Iterable<ReactNode> | ReactPortal

helperMessageProps

Description

Props the label component.

Type

HelperMessageProps

invalid

Description

If true, the form control will be invalid.

Type

boolean

Default

false

isDisabled

Deprecated

Description

If true, the form control will be disabled.

Deprecated

Use disabled instead.

Type

boolean

Default

false

isInvalid

Deprecated

Description

If true, the form control will be invalid.

Deprecated

Use invalid instead.

Type

boolean

Default

false

isReadOnly

Deprecated

Description

If true, the form control will be readonly.

Deprecated

Use readOnly instead.

Type

boolean

Default

false

isReplace

Deprecated

Description

If true, switch between helper message and error message using isInvalid.

Deprecated

Use replace instead.

Type

boolean

Default

true

isRequired

Deprecated

Description

If true, the form control will be required.

Deprecated

Use required instead.

Type

boolean

Default

false

label

Description

The form control label to use.

Type

type ONLY_FOR_FORMAT = | string | number | boolean | ReactElement<any, string | JSXElementConstructor<any>> | Iterable<ReactNode> | ReactPortal

labelProps

Description

Props the label component.

Type

LabelProps

optionalIndicator

Type

type ONLY_FOR_FORMAT = | string | number | boolean | ReactElement<any, string | JSXElementConstructor<any>> | Iterable<ReactNode> | ReactPortal

readOnly

Description

If true, the form control will be readonly.

Type

boolean

Default

false

replace

Description

If true, switch between helper message and error message using isInvalid.

Type

boolean

Default

true

required

Description

If true, the form control will be required.

Type

boolean

Default

false

requiredIndicator

Type

type ONLY_FOR_FORMAT = | string | number | boolean | ReactElement<any, string | JSXElementConstructor<any>> | Iterable<ReactNode> | ReactPortal

LabelProps

isRequired

Deprecated

Deprecated

Use required instead.

Type

boolean

optionalIndicator

Type

type ONLY_FOR_FORMAT = | string | number | boolean | ReactElement<any, string | JSXElementConstructor<any>> | Iterable<ReactNode> | ReactPortal

required

Type

boolean

requiredIndicator

Type

type ONLY_FOR_FORMAT = | string | number | boolean | ReactElement<any, string | JSXElementConstructor<any>> | Iterable<ReactNode> | ReactPortal

HelperMessageProps

ErrorMessageProps

Edit this page on GitHub

PreviousFormsNextFieldset