Input
A text input field with optional label, helper text, and error state support.
Examples
Interactive Playground
import { Input } from 'kalki-design'
<Input></Input>With Error
Invalid email format
import { Input } from 'kalki-design'
export default function Example() {
return (
<Input
label="Email address"
placeholder="hello@example.com"
error="Invalid email format"
/>
)
}Disabled
import { Input } from 'kalki-design'
export default function Example() {
return (
<Input
label="Email address"
placeholder="hello@example.com"
disabled
/>
)
}Installation
npx kalki-design add inputUsage
import { Input } from 'kalki-design'
export default function Example() {
return <Input />
}API Reference
| Name | Type | Default | Description |
|---|---|---|---|
Namelabel | Typestring | Default— | DescriptionAccessible label rendered above the input. |
Nameplaceholder | Typestring | Default— | DescriptionPlaceholder text displayed when the input is empty. |
Namesize | Type'sm' | 'md' | 'lg' | Default'md' | DescriptionHeight of the input field: sm (28px), md (32px), lg (36px). |
Nameerror | Typestring | boolean | Default— | DescriptionError state. Pass a string for an error message or true to apply error styling. |
NamehelperText | Typestring | Default— | DescriptionSupplementary text displayed below the input. |
Namedisabled | Typeboolean | Defaultfalse | DescriptionPrevents interaction and applies muted styling. |