Daniel Jacobs
Daniel Jacobs
This isn't working on Android when I try to type in an EditText with the virtual keyboard.
A virtual keyboard like the one on Android `isComposing`.
To explain the current logic, which I guess may need comments. 1) If you type a single character using the virtual keyboard, that character fires a keydown and then keyup...
I'm guessing the IME logic can be used to support this more properly, but landing this PR without IME support would regress the virtual keyboard.
Maybe we can do exactly this but also keydown and keyup the [`event.data`](https://developer.mozilla.org/en-US/docs/Web/API/CompositionEvent/data) character(s) on [`compositionend`](https://developer.mozilla.org/en-US/docs/Web/API/Element/compositionend_event).
Tried with GBoard and it worked perfectly. With Samsung Keyboard it's unfortunately a different story, see recording. https://github.com/user-attachments/assets/d3b00611-e2df-4131-8584-3868ea23ead2
As stated on Discord, but putting here for future people, this is now working with Samsung Keyboard.
Explanation of issues: iOS default keyboard Because we clear the input for each character typed, the characters do not combine, as the only input event that fires is an insertText...
I'm about 99.9% sure we need to stop clearing the hidden input for each character typed in the future.
I have a theory for what Mac is doing wrong, and if I'm right I wonder if this would help: ```js this.virtualKeyboard.addEventListener("keydown", this.ignoreComposingKeyEvents.bind(this)); this.virtualKeyboard.addEventListener("keyup", this.ignoreComposingKeyEvents.bind(this)); ignoreComposingKeyEvents(event: KeyboardEvent) { if (event.isComposing)...