Skip to content

A community-supported supercharged document management system: scan, index and archive all your documents

Change: allow modifier+arrow keyboard shortcuts in input fields

shamoon4fa08a9c96b4
diff --git a/src-ui/src/app/services/hot-key.service.ts b/src-ui/src/app/services/hot-key.service.ts
index 22a757581..e30364fc1 100644
--- a/src-ui/src/app/services/hot-key.service.ts
+++ b/src-ui/src/app/services/hot-key.service.ts
@@ -45,11 +45,13 @@ export class HotKeyService {
return new Observable((observer) => {
const handler = (e: KeyboardEvent) => {
if (
- !(e.altKey || e.metaKey || e.ctrlKey) &&
+ (!(e.altKey || e.metaKey || e.ctrlKey) ||
+ e.key.toLowerCase().includes('arrow')) &&
(e.target instanceof HTMLInputElement ||
e.target instanceof HTMLTextAreaElement)
) {
// Ignore keydown events from input elements that dont have a modifier key
+ // or if the key is an arrow key to allow for navigation within the input
return
}