From: Dan Brown Date: Mon, 23 Oct 2023 10:04:09 +0000 (+0100) Subject: Shortcuts: Prevented help shown when in inputs X-Git-Tag: v23.10~1^2~5 X-Git-Url: http://source.bookstackapp.com/bookstack/commitdiff_plain/d42af4affc047893e39be6ad25b384cde6c981ff Shortcuts: Prevented help shown when in inputs For #4606 --- diff --git a/resources/js/components/shortcuts.js b/resources/js/components/shortcuts.js index 85a7c3da7..b22c46731 100644 --- a/resources/js/components/shortcuts.js +++ b/resources/js/components/shortcuts.js @@ -29,17 +29,16 @@ export class Shortcuts extends Component { return; } - this.handleShortcutPress(event); - }); - - window.addEventListener('keydown', event => { if (event.key === '?') { if (this.hintsShowing) { this.hideHints(); } else { this.showHints(); } + return; } + + this.handleShortcutPress(event); }); }