We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 12e2d1e commit d90febfCopy full SHA for d90febf
src/core.ts
@@ -212,7 +212,7 @@ export function keydownHandler(event: KeyboardEvent, el: CustomInputElement) {
212
const { options } = el
213
const regExp = new RegExp(`${options.prefix}|${options.suffix}`, 'g')
214
const newValue = el.value.replace(regExp, '')
215
- const canNegativeInput = options.min < 0 || !options.min
+ const canNegativeInput = options.min < 0
216
if (([110, 190].includes(event.keyCode) || event.key === options.decimal) && newValue.includes(options.decimal)) {
217
event.preventDefault()
218
} else if ([109].includes(event.keyCode) && !canNegativeInput) {
0 commit comments