Problems using Keyboard and mouse in a 3d widget Editable text box

Goal: Having the player be able to interact with an editable text box in a 3d widget.

At first, my widget interaction component worked with every 3d widget, the problem shows when I try to interact with the text box, I can select text but I can’t type.
To try to solve this I use the set focus node in a “on mouse enter” event and then go back to using “set input game only” in a “on mouse leave” event. And I can type.
However, I lose this if I click on the text box.
To keep being able to type and to try to still be able to select text with the mouse, I “set focus” in a tick event if the mouse button is not down and on the widget. This works ±, but I lose the selection when I release the mouse button, which is not ideal.

I’m looking for a better solution.