Event backspace
hiukky opened this issue · 4 comments
And hey buddy! congratulations for lib I'm using now and finding the input-core features very interesting.
I'm just having problems with the backspace event ... the characters are removed normally but when I arrive at a set in the mask the same lock and I did not allow the exclusion of this character!
How can I fix this? Mask intention is to be dynamic and appear and disappear according to user iteration
const handleKeyDown = (e: React.KeyboardEvent<HTMLInputElement>) => {
setSelection()
if (e.which === 8) {
fieldMask?.removePreviosOrSelected()
}
}
Hi @hiukky!
Could you provide an example of the described issue please so that I can fix it?
@xnimorz Here is my implementation.
https://github.com/glity/core/blob/develop/src/components/TextField/index.tsx
You are welcome to PR me, or otherwise, I'd fix it later
As the repo is inaccessible, I'll close the issue. If you have an example of how to reproduce the problem feel free to reopen an issue or create a new one