useMouseEvents
Subscribes to global mouse click and wheel (trackpad scroll) events streamed from the Fluxlay desktop app. Coordinates are normalized to the wallpaper window with the Y axis flipped to a math-style system (positive Y is up).
Import
Signature
Pass only the callbacks you need; missing ones are simply ignored.
Usage
Event types
MouseButtonEvent
MouseWheelEvent
Notes
- The subscription is scoped to the window identified by the
window_labelquery parameter of the current URL, defaulting to"main". - Like
useMousePosition, the Y axis is inverted (positive Y is up). Flip it back when feeding into CSS coordinates. - On macOS, the user must grant Fluxlay "Input Monitoring" in System Settings. On Windows the global hook may be flagged by some antivirus software, and events targeting processes running at higher integrity levels (e.g. apps launched as Administrator) are not delivered due to UIPI.