Input
stableA styled text input with focus ring and invalid state.
Basic usage
Examples
States
Input with disabled and invalid (aria-invalid) states.
Native input states
Input forwards native props and styles disabled plus invalid states.
Features
- Hover and focus transitions.
- aria-invalid styling.
- Wraps the native input.
Installation
bash
pnpm dlx structyl add inputAPI Reference
Input
A styled text input. Forwards all native input props.
| Prop | Type | Default |
|---|---|---|
| type | stringNative input type. | 'text' |
| disabled | booleanDisable the input. | false |
| 'aria-invalid' | booleanMarks the field invalid and applies error styling. | — |
| className | stringAdditional Tailwind classes, merged with the component defaults. | — |