NumberInputProps Interface


Properties for the NumberInput component


  • { T }


Name Type Description
containerClassName undefined | string CSS class name for the NumberInput component container div  
format undefined | (num: number | null | undefined, formattedValue: string) => string function optional formatting function that takes the number value and the internal formatted value in case function just adds prefix or suffix.  
max undefined | number number or function defaults to Number.MAX_SAFE_INTEGER  
min undefined | number number or function Number.MIN_SAFE_INTEGER  
onChange undefined | (value: number | undefined, stringValue: string) => void Function to call when value is changed.  
parse undefined | (value: string) => number | null | undefined function parseFloat  
precision undefined | number number of decimal places, defaults to 0  
ref undefined | React.Ref<HTMLInputElement> Provides ability to return reference to HTMLInputElement  
showTouchButtons undefined | false | true if true up/down buttons are shown larger and side by side  
snap undefined | false | true Set to true to "snap" to the closest step value while incrementing or decrementing (up/down buttons or arrow keys).  
step undefined | StepFunctionProp increment step value used while incrementing or decrementing (up/down buttons or arrow keys) defaults to 1.  
value undefined | number Numeric value, set to undefined to show placeholder text  

Defined in

Last Updated: 01 December, 2021