InputNumber: Cleanup KeyDown

pull/5418/head
Melloware 2024-03-14 15:25:53 -04:00 committed by GitHub
parent 1f2e035640
commit 71fbab6825
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 7 deletions

View File

@ -376,23 +376,19 @@ export default {
return;
}
this.lastValue = event.target.value;
if (event.shiftKey || event.altKey) {
this.isSpecialChar = true;
return;
}
this.lastValue = event.target.value;
let selectionStart = event.target.selectionStart;
let selectionEnd = event.target.selectionEnd;
let inputValue = event.target.value;
let newValueStr = null;
if (event.altKey) {
event.preventDefault();
}
switch (event.code) {
case 'ArrowUp':
this.spin(event, 1);
@ -540,7 +536,6 @@ export default {
const isMinusSign = this.isMinusSign(char);
if (((event.code.startsWith('Digit') || event.code.startsWith('Numpad')) && Number(char) >= 0 && Number(char) <= 9) || isMinusSign || isDecimalSign) {
console.log(event.code);
this.insert(event, char, { isDecimalSign, isMinusSign });
}