@miniben90/x-win
This package allows you to retrieve precise information about active and open windows on Windows, MacOS, and Linux. You can obtain the position, size, title, and other memory of windows.
page-lifecycle
A JavaScript library to observe Page Lifecycle API states: https://github.com/WICG/page-lifecycle
react-interactive
Better hover, active and focus states than CSS pseudo-classes, and a callback when the interactive state changes.