Input Group

Compound input with inline and block addons. Wraps the Input primitive with a pointer-proximity tint, a spring scale-up pulse on valid, and a horizontal shake when aria-invalid flips to true.

Leading icon

Trailing button

Prefix and suffix text

https://
.svelte

Block addons

Description

Invalid — shake on error

Tooltip

Wrap an icon addon in a Tooltip to surface contextual help without cluttering the label.

Textarea

Swap the inner control for a Textarea — block addons reflow above and below automatically.

Message

Spinner

An inline Spinner addon communicates async validation without a full loading overlay.

Label addon

A Label inside an addon acts as a prefix descriptor — useful for unit inputs or tagged fields.

units

Pair a DropdownMenu trigger with an Input for patterns like country-code + phone number.

InputGroup props

Root accepts native div attributes. A MutationObserver watches the inner control's aria-invalid — flip it to trigger the shake; flip back for the spring-scale valid pulse.

PropTypeDescription
stringMerged onto the root via tailwind-merge.
HTMLDivElement | nullTwo-way-bindable element reference.

InputGroupAddon props

PropTypeDescription
'inline-start' | 'inline-end' | 'block-start' | 'block-end'Placement. Inline addons sit left or right of the control; block addons stack above or below it and the group reshapes to match.
stringMerged onto the addon via tailwind-merge.

InputGroupButton props

Wraps Button with input-friendly sizing. Unlike the top-level Button, `href` is disabled — keep navigation outside the group.

PropTypeDescription
'xs' | 'sm' | 'icon-xs' | 'icon-sm'Input-scale sizing only. Icon sizes render as a square.
ButtonVariantInherits Button variants. Ghost is the quiet default inside a group.