InputNumber
Input numerical values with a customizable range.
Basic usage
Bind a variable to v-model in <er-input-number> element and you are set.
Disabled
Use disabled attribute to determine whether InputNumber is disabled. It accepts a Boolean value.
Steps
Allows you use step attribute to define incremental steps.
Sizes
Use attribute size to set additional sizes with large, small, default size is default.
API
Attributes
| Name | Description | Type | Default |
|---|---|---|---|
| v-model | binding value | number | — |
| min | the minimum allowed value | number | -Infinity |
| max | the maximum allowed value | number | Infinity |
| step | incremental step | number | 1 |
| size | size of the component | 'large' | 'default' | 'small' | default |
| disabled | whether the component is disabled | boolean | false |
Events
| Name | Description | Parameters |
|---|---|---|
| change | triggers when the value changes | value: number, oldValue: number |
| blur | triggers when Input blurs | event: FocusEvent |
| focus | triggers when Input focuses | event: FocusEvent |
Exposes
| Name | Description | Parameters |
|---|---|---|
| focus | get focus the input component | — |
| blur | remove focus the input component | — |