InputGroup

A single-line input composition shell with leading or trailing addons.

Preview#

https://.com
Controls
import { InputGroup, InputGroupInput } from "raft-ui";

<InputGroup>
  <InputGroupInput />
</InputGroup>

Addons#

/

Text affixes#

$USD
@example.com

Addon variants#

Use variant="default" for light inline adornments such as search icons or keyboard hints. Use variant="container" when the addon is part of the value structure, like a protocol, domain suffix, unit, or icon box.

https://.com

Actions#

Cmd K

States#

Put data-invalid and disabled on InputGroupInput. The wrapper owns the visible state through has-*.

$USD
/

With Field#

API#WIP

PropTypeDefaultDescription
...propsComponentProps<"div">Native div attributes. Renders the shell that owns border, background, focus, invalid, and disabled styling.
PropTypeDefaultDescription
align"inline-start" | "inline-end""inline-start"Which edge the addon hugs.
variant"default" | "container""default"Use container for a muted addon box with an internal divider.
...propsComponentProps<"div">Native div attributes for icons, buttons, keyboard hints, or custom addon content.
PropTypeDefaultDescription
align"inline-start" | "inline-end""inline-start"Which edge the static text hugs.
variant"default" | "container""default"Use container for a muted text box with an internal divider.
...propsComponentProps<"span">Native span attributes for non-interactive text affixes such as currency or unit.
PropTypeDefaultDescription
...propsInputPropsSame native input props as Input, including suppressPasswordManager. Carries data-slot=input-group-control.