Browse Source

[FF64] Fix Backspace in phone number input

master
Eduard Kuzmenko 4 years ago
parent
commit
d203337cb7
  1. 2
      src/pages/pageSignIn.ts

2
src/pages/pageSignIn.ts

@ -306,7 +306,7 @@ let onFirstMount = () => { @@ -306,7 +306,7 @@ let onFirstMount = () => {
//console.log('keypress', this.value);
if(!btnNext.style.visibility &&/* this.value.length >= 9 && */ e.key === 'Enter') {
return onSubmit();
} else if(/\D/.test(e.key) && !(e.metaKey || e.ctrlKey) && !(e.key === '+' && e.shiftKey/* && !this.value */)) {
} else if(/\D/.test(e.key) && !(e.metaKey || e.ctrlKey) && e.key !== 'Backspace' && !(e.key === '+' && e.shiftKey/* && !this.value */)) {
e.preventDefault();
return false;
}

Loading…
Cancel
Save