jondavidjohn / payform

:credit_card: A library for building credit card forms, validating inputs, and formatting numbers.
https://jondavidjohn.github.io/payform/
Other
427 stars 81 forks source link

Selected text is not always cleared when typing #29

Open slavafomin opened 6 years ago

slavafomin commented 6 years ago

There is a use-case pattern when user presses Ctrl+A and then Backspace to clear the input. However it doesn't work around delimiters.

How to reproduce:

  1. Enter 5213, then space is automatically inserted: 5213.
  2. Press Ctrl+A and then Backspace.

It will remove only the last character, instead of entire string.


Also, there is another failing pattern:

Enter 123, then press Ctrl+A, then start to type the replacement number. It will not clear the selected text.