Input group: Keyboard hint
A plain <kbd> inside an addon is styled as a key cap. It's a visual hint only, so bind the shortcut yourself.
This adds the example as components/examples/input-group/kbd.tsx, together with the Input group component and the HextaUI theme tokens it needs.
pnpm dlx shadcn@latest add https://hextaui.com/r/input-group-kbd.jsonTo add only the component, follow the Input group installation.
Props in this example
The Input group props this example sets, from the API reference.
| Prop | Type | Default |
|---|---|---|
align | "inline-start" | "inline-end" | "block-start" | "block-end" | "inline-start" |
Every prop is in the Input group API reference.
- Icon
- Clear
- Character count
- Text
- Button
- Textarea
- Header
- Password
- Sizes
- Invalid
- Disabled
- Loading
- Dropdown
- Long content
- Right to left
See them all, with keyboard support and accessibility notes, on the Input group page.
- ButtonButtons in every variant and size, with a built-in loading, success and error flow that skips the spinner for fast requests.
- InputA text input with three sizes, invalid and read-only states, native validation styling and a 16px touch font so phones never zoom in.
- MotionThe easing curves, durations and reduced-motion check every component animates with, plus hooks for size morphs and sliding highlights.
- useAutosizeGrows a textarea with what you write between its minimum and maximum height, animating each change without ever touching the text.
- useComposedRefKeeps a ref to your own element while still forwarding it to whatever ref the parent passed in.
- useInvalidShakeShakes a form control when a submit attempt finds it invalid, and never while someone is still typing.