Prodular UI

Input group

An input with icons, text, keyboard hints or buttons attached inside the same border.

npx prodular-ui add input-group

Icons, prefixes and suffixes

/
tidewater.app/

Lowercase letters, numbers and dashes.

$
USD per month

With buttons

Copy and reveal actions for links and secrets.

Sizes

Anatomy

<InputGroup>  <InputGroupAddon>    <InputGroupText>tidewater.app/</InputGroupText>  </InputGroupAddon>  <InputGroupInput defaultValue="northbeam" /></InputGroup>

Guidance

Use it when

  • A fixed prefix or suffix: a URL host, a currency, a unit.
  • A search field with an icon or a keyboard shortcut.
  • An inline action that belongs to the value, such as copy or show.

Avoid

  • Separate buttons that act on the whole form. Put them next to the group, or use ButtonGroup.

Rules for AI agents

Published in llms-full.txt, the registry and the MCP server, so coding agents follow them when they build with this component.

  • Use InputGroupInput, not Input, inside the group. It inherits the group size.
  • Put addons in InputGroupAddon with align inline-start or inline-end. Text goes in InputGroupText.
  • Icon-only InputGroupButton needs aria-label.
  • Set size on InputGroup, not on the input.

API

InputGroup

PropTypeDefaultDescription
size"sm" | "default" | "lg""default"Height of the group and its input.

InputGroupAddon

PropTypeDefaultDescription
align"inline-start" | "inline-end" | "block-start" | "block-end""inline-start"Where the addon sits.

InputGroupButton

PropTypeDefaultDescription
size"xs" | "sm" | "icon-xs" | "icon-sm""xs"Compact sizes that fit inside the group.

Installation

The Prodular UI CLI adds the source to components/ui with everything it depends on. In a project that already uses shadcn/ui, the shadcn CLI installs it from the Prodular registry too. See Installation for the first setup.

npx prodular-ui add input-group# or, with the registry in components.jsonnpx shadcn@latest add @prodular/input-group