Input

Forms

A text field for capturing user input. Supports labels, hints, error states, and multiple input types.

Preview

Props API

PropTypeDefaultDescription
labelstring"Email address"Visible label above the input
placeholderstring"you@example.com"Placeholder shown when the field is empty
typeselect"text" | "email" | "password" | "number" | "search" | "url""text"HTML input type
hintstring""Helper text shown below the input
errorstring""Error message — replaces hint and visually marks the field
disabledbooleanfalsePrevents interaction with the input
requiredbooleanfalseMarks the field as required

Usage

Always pair an input with a visible label — never rely on placeholder text alone. Use "hint" to explain expected format or constraints. The "error" prop takes over from "hint" and should describe what went wrong and how to fix it.

Accessibility

  • Label is always associated with the input via matching for/id attributes.

  • Error messages are linked via aria-describedby so screen readers announce them.

  • Required fields include aria-required="true".

  • Error state uses aria-invalid="true" to signal invalid input to assistive tech.