diff --git a/src/App.vue b/src/App.vue index 6d798fd..bce1165 100644 --- a/src/App.vue +++ b/src/App.vue @@ -49,8 +49,8 @@ addEventListener('click', (event) => { addEventListener('keydown', (event) => { if (gameStore.character?.role !== 'gm') return // Only allow toggling the gm panel if the character is a gm - // Check if no input is active - if (event.repeat || event.isComposing || event.defaultPrevented) return + // Check if no input is active or focus is on an input + if (event.repeat || event.isComposing || event.defaultPrevented || document.activeElement?.tagName.toUpperCase() === 'INPUT' || document.activeElement?.tagName.toUpperCase() === 'TEXTAREA') return if (event.key === 'G') { gameStore.toggleGmPanel()