Input

Inputs & Controls

macOS recessed text input field featuring blue halo focus ring.

Installation

$npx shadcn-macos@latest add input

Examples

Props

<Input />
PropTypeDefaultDescription
typestring"text"HTML input element type (e.g. text, password, email, number, search).
placeholderstringPlaceholder text rendered when the field is empty.
valuestringControlled string value of the input.
defaultValuestringInitial uncontrolled value of the input.
disabledbooleanfalseDisables interaction and dims the field.
onChange(event: React.ChangeEvent<HTMLInputElement>) => voidCallback fired whenever the input text changes.
classNamestringAdditional CSS classes.