Skip to main content

Function: NumberField()

NumberField(__namedParameters): Element

Defined in: components/NumberField/NumberField.tsx:117

A semantic numeric input built on React Aria's NumberField.

Renders a labelled control box (Group) holding the <input> between a decrement (−) and increment (+) stepper. Entity = Input → reads vars.colors.input.primary.*. Supports minValue/maxValue/step and locale-aware formatOptions (currency, percent, units). Validation is the invalid State (via isInvalid/validate), never an evaluation variant.

Parameters

ParameterType
__namedParametersNumberFieldProps

Returns

Element

Example

<NumberField label="Quantity" minValue={0} defaultValue={1}>
</NumberField>
<NumberField
label="Price"
formatOptions={{ style: 'currency', currency: 'USD' }}
/>