Initial commit: NexusArchitect Professional Workstation Overhaul

This commit is contained in:
Debian
2026-04-24 20:27:22 +02:00
commit f3e94c4f42
193 changed files with 5809 additions and 0 deletions
@@ -0,0 +1,20 @@
export function attachKeyboardListener(dotNetHelper) {
const handler = (e) => {
// Exclude inputs, textareas, etc.
const activeNode = document.activeElement ? document.activeElement.nodeName.toLowerCase() : '';
if (activeNode === 'input' || activeNode === 'textarea') return;
if (e.key === 'f' || e.key === 'F') {
dotNetHelper.invokeMethodAsync('OnFocusKeypressed');
}
};
window.addEventListener('keydown', handler);
return handler;
}
export function detachKeyboardListener(handler) {
if (handler) {
window.removeEventListener('keydown', handler);
}
}