Number Input
UI SDK NumberInput: typed, stepped and formatted numbers with step buttons, named by Field.
Example
Remove a seatAdd a seat
Between 1 and 50.
number-input-demo.tsxCopy code
Installation
Copy code
Usage
ImportCopy code
API reference
NumberInput
NumberInputGroup
NumberInputControl
NumberInputDecrement
| Prop | Type | Default |
|---|---|---|
tooltip | ControlTooltipOption | – |
Also takes every prop of UI SDK NumberInputDecrement.
NumberInputIncrement
| Prop | Type | Default |
|---|---|---|
tooltip | ControlTooltipOption | – |
Also takes every prop of UI SDK NumberInputIncrement.
NumberInputScrubArea
NumberInputScrubAreaCursor
Other exports
createNumberInputControllertype NumberInputControllertype NumberInputStatetype NumberInputValueChangeReasonAccessibility
- Arrow keys, Page Up/Down and Home/End step the value; the step buttons need their own aria-label.
- Values are formatted and parsed with Intl in the page's locale.
Agent actions
Runs agent.snapshot() from @ui-sdk/react/agent on the live preview above.