Form control buttons
Form control buttons provide semantic button elements that look like form inputs. They are designed for scenarios where you need interactive buttons within form layouts while maintaining consistent form control styling.
EuiFormControlButton
EuiFormControlButton renders a button that looks like a form input field. It can be used to trigger actions (e.g. opening popovers) from within a EuiFormControlLayout to ensure expected visual output and consistency with input controls.
EuiFormControlButton is meant to only be used inside EuiFormControlLayout.
The component provides a mix of base EuiButtonEmpty props and input specific props - e.g. use value
and placeholder
to provide content similar to an input element. You can customize the content by passing additional content via the children
prop.
Dropdown styling
Set isDropdown
on EuiFormControlLayout to indicate a dropdown toggle that accounts for other form layout icons.
Props
EuiFormControlButton
Prop | Description and type | Default value |
---|---|---|
Prop placeholder# | Description and type Placeholder value to be shown when no string | Default value |
Prop compressed# | Description and type When boolean | Default value |
Prop isInvalid# | Description and type Defines invalid state styling boolean | Default value false |
Prop target# | Description and type Type: string | Default value |
Prop rel# | Description and type Type: string | Default value |
Prop className# | Description and type Type: string | Default value |
Prop css# | Description and type Type: Interpolation<Theme> | Default value |
Prop contentProps# |