Input

A text input field with optional label and multiple size variants.

Preview

Default
With Label
Sizes
Disabled

Usage

tsx
import { Input } from "@semajsx/ui/components/input";

<Input placeholder="Enter your name" />
<Input label="Email" type="email" size="lg" />
<Input placeholder="Read only" readOnly />

Props

PropTypeDefaultDescription
type"text" | "email" | "password" | "number" | "search" | "url" | "tel""text"Input type
labelstringLabel text above the input
placeholderstringPlaceholder text
valuestringCurrent value
size"sm" | "md" | "lg""md"Size preset
disabledbooleanfalseDisabled state
readOnlybooleanfalseRead-only state
namestringHTML name attribute
idstringHTML id attribute