Input Group

The InputGroup component combines addons, prefixes, suffixes, and a form control into one framed input row.

Usage & Examples

Amount Field

$
USD
amount-field.tsx
<InputGroup label="Budget" prefix="$" suffix="USD">
  <TextInput placeholder="2500" aria-label="Budget amount" />
</InputGroup>

Props API

38 props
Columns
Input Group props API
Default
Description
childrenReactNodeNopropsMain form control rendered inside the group.
classNamestringNostylingAdditional class name for the component root.
containerClassNamestringNopropsAdditional class name for the outer label/component container.
contentClassNamestringNopropsAdditional class name for the content/control area.
data-testidstringNotestingBackward-compatible alias for test ID attributes.
descriptionReactNodeNopropsSupporting description rendered before the control and connected with aria-describedby.
descriptionClassNamestringNopropsAdditional class name for the description text.
disabledbooleanNopropsfalseWhether the grouped control is disabled.
endAddonReactNodeNopropsAddon content rendered after the shared input frame.
endAddonClassNamestringNopropsAdditional class name for the end addon.
errorReactNodeNopropsError message rendered after the control and announced to assistive technologies.
errorClassNamestringNopropsAdditional class name for error text.