Displays an input field with additional elements such as icons, buttons, or text.
Loading...
Installation
Install the following dependencies:
Copy and paste the following code into your project.
Loading...
Update the import paths to match your project setup.
Composition
[appInputGroup] ├── [appInputGroupAddon] (optional) │ ├── [appInputGroupText] │ └── [appInputGroupButton] (optional) └── input[appInputGroupInput] | textarea[appInputGroupTextarea]
Examples
Alignment
Loading...
Button
Loading...
Character Count
Loading...
Default
Loading...
Disabled
Loading...
Dividers
Loading...
Dropdown
Loading...
Icon
Loading...
Loading
Loading...
Sizes
Loading...
Text
Loading...
API Reference
Apply these directives to native elements. Native attributes and events remain available on their
host elements. InputGroupImports contains all six directives listed below.
[appInputGroup]
Adds the input group container styles and role="group" to the host element.
Inputs
| Input | Type | Default | Description |
|---|---|---|---|
size | "default" | "lg" | "xl" | "default" | Controls the size of the complete input group. |
[appInputGroupAddon]
Adds an optional leading, trailing, top, or bottom addon and sets role="group" on its host.
Inputs
| Input | Type | Default | Description |
|---|---|---|---|
align | "inline-start" | "inline-end" | "block-start" | "block-end" | "inline-start" | Positions the addon within the input group. |
[appInputGroupButton]
Styles its host as a button and sets the native type attribute to "button".
Inputs
| Input | Type | Default | Description |
|---|---|---|---|
variant | "default" | "destructive" | "ghost" | "link" | "outline" | "secondary" | "ghost" | Controls the button's visual style. |
size | "xs" | "sm" | "icon-xs" | "icon-sm" | "text" | "xs" | Controls the button size within the input group. |
[appInputGroupText]
Styles text placed inside an addon. It has no public inputs or outputs.
input[appInputGroupInput]
Styles a native <input> as the group's control. Use native input attributes, properties, and
events to configure it.
textarea[appInputGroupTextarea]
Styles a native <textarea> as the group's control. Use native textarea attributes, properties,
and events to configure it.
Angular
React
Solid
Svelte
Vue