feat(desktop): add KeybindManager with uiohook-napi for global shortcuts

Installs uiohook-napi for OS-level non-consuming input hooks, creates
KeybindManager class that receives keybind configs from the renderer,
matches the OS-wide key/mouse event stream, and sends matched actions
back via IPC. Exposes syncKeybinds, onKeybindAction, onAccessibilityStatus,
onKeybindHookError, and checkAccessibility APIs through the preload bridge.
This commit is contained in:
Jannis Braun
2026-03-22 20:47:41 +01:00
parent 11d802f86c
commit 3ce9ee0db0
5 changed files with 213 additions and 2 deletions
+5 -2
View File
@@ -14,12 +14,15 @@
"dev": "mkdir -p build && cp ../../icon.png build/icon.png && bash scripts/gen-icns.sh && cp build/icon.icns $(find ../../node_modules -path '*/electron/dist/Electron.app/Contents/Resources/electron.icns' 2>/dev/null | head -1) 2>/dev/null; tsc && electron .",
"prebuild": "mkdir -p build && cp ../../icon.png build/icon.png",
"build": "tsc && electron-builder",
"clean": "rm -rf dist dist-electron"
"clean": "rm -rf dist dist-electron",
"postinstall": "electron-rebuild -f -w uiohook-napi"
},
"dependencies": {
"electron-updater": "^6.3.0"
"electron-updater": "^6.3.0",
"uiohook-napi": "^1.5.5"
},
"devDependencies": {
"@electron/rebuild": "^3.7.1",
"electron": "^40.0.0",
"electron-builder": "^25.1.8",
"typescript": "^5.7.2"