Input

Single-line text field with the Select trigger's hairline and native field states.

Installation

This component is primitive-agnostic — same source under both flavors.

Basic

Inspect

We only use it to send your ticket.

Invalid

Inspect

The red hairline lasts until the field receives focus. Focus then wins with a neutral border, so the value being fixed is not still marked as wrong.

Number

Inspect

Native spinner arrows are removed. The inset minus/plus buttons step the value and stay out of the tab order, so arrow keys still own the focused field.

File

Inspect

Sizes

Inspect

Disabled

Inspect

API Reference

PropTypeDefaultDescription
size"default" | "compact"from SizeProviderPins the field to one step of the size ladder; omitting it follows the provider.
typestring"text"Any native type. "number" replaces the browser spinners with minus/plus buttons; "file" shows a file glyph and muted text until a file is chosen.
aria-invalidboolean—Tints the hairline red until the field receives focus.
disabledbooleanfalseDims the field and removes pointer interaction.
...propsInputHTMLAttributes—Every native input attribute: value, placeholder, min, max, step, onChange, etc.