| alignment | 'left' | 'right' | Sets the alignment inside the input. | - |
| ariaLabel | string | Specifies a string to be used as the name for the textInput element when no label is provided. | - |
| clearable | boolean | If true, the input will have an action to clear the entered value. | - |
| config | {
thousandSeparator?: string;
decimalSeparator?: string;
symbolPosition?: 'before' | 'after';
} & (
| {
currencyConfig?: {
currency: string;
currencyDisplay?: 'code' |
'symbol' |
'narrowSymbol' |
'name';
currencySign?: 'standard' | 'accounting';
};
unitsConfig?: never;
}
| {
currencyConfig?: never;
unitsConfig?: {
unit: string;
unitDisplay?: 'short' | 'long' | 'narrow';
};
}
)
| Configuration for the amount input, including currency or units, and formatting options such as thousand and decimal separators and the position of the currency symbol. currencyConfig and unitsConfig are mutually exclusive. To better understand the allowed values for currencies and units, please refer to the respective documentation. | - |
| defaultValue | string | Initial value of the input, only when it is uncontrolled. | - |
| disabled | boolean | If true, the component will be disabled. | - |
| error | string | If it is a defined value and also a truthy string, the component will change its appearance, showing the error below the input component. If the defined value is an empty string, it will reserve a space below the component for a future error, but it would not change its look. In case of being undefined or null, both the appearance and the space for the error message would not be modified. | - |
| helperText | string | Helper text to be placed above the input. | - |
| label | string | Text to be placed above the input. This label will be used as the aria-label attribute of the list of suggestions. | - |
| maxValue | number | Specifies the maximum value allowed in the input. | - |
| minValue | number | Specifies the minimum value allowed in the input. | - |
| name | string | Name attribute of the input element. | - |
| numberOfDecimals | number | Specifies the number of decimal places allowed in the input. By default it is set to 3 or the permitted amount by the currency. | - |
| numberOfIntegers | number | Specifies the number of integer places allowed in the input. | - |
| onBlur | (val: { value: string; error?: string }) => void | This function will be called when the input element loses the focus. An object including the input value and the error (if the value entered is not valid) will be passed to this function. If there is no error, error will not be defined. | - |
| onChange | (val: { value: string; error?: string }) => void | This function will be called when the user types within the input element of the component. An object including the current value and the error (if the value entered is not valid) will be passed to this function. If there is no error, error will not be defined. | - |
| optional | boolean | If true, the input will be optional, showing '(Optional)' next to the label. Otherwise, the field will be considered required and an error will be passed as a parameter to the onBlur and onChange functions when it has not been filled. | - |
| placeholder | string | Text to be put as placeholder of the input. | - |
| readOnly | boolean | If true, the component will not be mutable, meaning the user can not edit the control. In addition, the clear action will not be displayed even if the flag is set to true. | - |
| ref | React.Ref<HTMLInputElement> | Ref to the input element. | - |
| size | 'small' | 'medium' | 'large' | 'fillParent' | Size of the component. | - |
| tabIndex | number | Value of the tabindex attribute. | - |
| value | string | Value of the input. If undefined, the component will be uncontrolled and the value will be managed internally by the component. | - |