I really like this idea
Unfortunately there is no condition to detect if a player is typing in Java, the closest we can come to this is .isCommand() I believe which detect auto completions in commands in a players chat which wouldn’t be much use in the long run.
there are however mods, mods...