For my app, I need to radically change the entire UX for touch devices using an onscreen keyboard (eg. mobile, touch TV) vs mouse/kbd devices (eg. desktop, a mobile with a bluetooth mouse/kbd).
NB. I’ve already grokked responsive layout with CSS grid and media queries, so that aspect is dealt with. My issue isn’t one of layout, it’s that the entire UX needs to be fundamentally different. The best option I have so far is to listen for a mousemove on the whole viewport.
How can I do this using modern browsers?
Note I’ve already read the existing answers which are all several years old, and generally conclude that it can’t be done.