Skip to content

InputTextField

A versatile text input field that supports multiple input types through HTML5 input elements.

PropTypeDefaultDescription
value(instance: TCommand) => unknownRequired. Accessor function returning the property value from the command instance.
titlestringThe label for the field.
type'text' | 'email' | 'password' | 'color' | 'date' | 'datetime-local' | 'time' | 'url' | 'tel' | 'search''text'The HTML input type.
placeholderstringPlaceholder text shown when empty.
requiredbooleanOverride automatic required detection.

Text Input:

<InputTextField<UserCommand> value={c => c.name} title="Full Name" placeholder="Enter your name" />

Email Input:

<InputTextField<UserCommand> value={c => c.email} type="email" title="Email" placeholder="your@email.com" />

Password Input:

<InputTextField<UserCommand> value={c => c.password} type="password" title="Password" />

Date Input:

<InputTextField<UserCommand> value={c => c.birthDate} type="date" title="Birth Date" />

Color Picker:

<InputTextField<UserCommand> value={c => c.favoriteColor} type="color" title="Favorite Color" />

URL Input:

<InputTextField<UserCommand> value={c => c.website} type="url" title="Website" placeholder="https://example.com" />