fix: disable Esc hotkey for guests

Signed-off-by: Maksim Sukharev <antreesy.web@gmail.com>
This commit is contained in:
Maksim Sukharev
2025-07-19 14:20:47 +02:00
parent 51464aefd1
commit 7601855bbd

View File

@ -209,7 +209,9 @@ export default {
created() {
window.addEventListener('beforeunload', this.preventUnload)
useHotKey('f', this.handleAppSearch, { ctrl: true, stop: true, prevent: true })
useHotKey('Escape', this.openRoot, { stop: true, prevent: true })
if (getCurrentUser()) {
useHotKey('Escape', this.openRoot, { stop: true, prevent: true })
}
},
beforeUnmount() {