I finally found some time to take a look at this, but I don't seem to be able to reproduce the behavior you were seeing. Do you have some code that demonstrates the problem?
Holding the B button down while opening the keyboard by pressing A in this project doesn't seem to result in any characters being deleted from the text, but please let me know if I'm missing something!
You’re right. It doesn’t appear to happen when I hold B in your code but if I replace AButtonDown with BButtonDown and press B to open it is cut off again.
Background: I first encountered the issue after trying to use B instead of A to confirm and then noticed that it also happened when just holding B but I can’t reproduce the second case anymore.