NumberInput

Beta notice: This page is being built.Edit on GitHub(opens in new tab)

Edits a constrained number without wheel editing or custom value formatting.

longlink docs component "NumberInput"

Example

Properties

NumberInput - Properties
labelstring
Label text for the input (always rendered for accessibility).
descriptionstring
Description text displayed between the label and input.
namestring
Includes the themed control's value under this form submission name.
requiredboolean
Requires a value before native form submission.
disabledboolean
Prevents interaction and excludes the field from submission.
valuenumber | null
Current value of the input.
defaultValuenumber
Initial value.
minnumber | null
Minimum value allowed. A smaller entry commits at this value on blur or Enter.
maxnumber | null
Maximum value allowed. A larger entry commits at this value on blur or Enter.
stepnumber | null
Step increment for the input.
placeholderstring
Placeholder text.
unitsstring | null
Units text to display at the end of the input (e.g., "%" or "GB").
isIntegerOnlyboolean
Only allow integer values (no floating point).
autoCompletestring
HTML autocomplete attribute.
onChange(value: number | null) => void
Receives committed edits, step changes, or cleared values.