Captures text input from the user.
Default input field.
import { Input } from "@/components/ui/input" export function InputDemo() { return <Input placeholder="Email" /> }
Prop | Type | Default | Description |
---|---|---|---|
type | string | text | Type of the input (text, email, password, etc.) |
placeholder | string | - | Text to display when the input is empty. |
disabled | boolean | - | Whether the input is disabled. |
required | boolean | - | Whether the input is required in a form. |
value | string | - | The controlled value of the input. |
onChange | function | - | Event handler called when the input's value changes. |