MediaBrowser / Emby

Emby Server is a personal media server with apps on just about every device.
https://emby.media
GNU General Public License v2.0
3.99k stars 792 forks source link

[Bug] Can't navigate any `emby-scroller` on touchscreen laptop with mouse. @media (pointer: fine) not reliable #3840

Open frostbitten opened 3 weeks ago

frostbitten commented 3 weeks ago

Any common 10-finger touch windows laptop should allow you to test this.

The arrows to navigate the emby scrollers are only shown on devices that report pointer: fine. However, @media (pointer: fine) is not applicable when a touch input is available. So when using a mouse it can hardly be navigated (the clunky and cumbersome middle click works as a manual workaround).

This isn't a browser bug but expected behavior according to the spec:

If multiple pointing devices are present, the pointer media feature must reflect the characteristics of the “primary” pointing device, as determined by the user agent. (To query the capabilities of any available pointing devices, see the any-pointer media feature.) https://drafts.csswg.org/mediaqueries/#pointer

Potential solution could be to use some javascript to check for a real mousemove and add a css class like .pointer-available to the body.