mirror of
https://github.com/zen-browser/components.git
synced 2025-07-07 16:55:31 +02:00
Refactor ZenGlanceManager.mjs to prevent default behavior and stop event propagation when Escape key is pressed and there is a current browser
This commit is contained in:
parent
6db4adf0f6
commit
5e791df74c
1 changed files with 2 additions and 0 deletions
|
@ -66,6 +66,8 @@
|
|||
|
||||
onKeyDown(event) {
|
||||
if (event.key === "Escape" && this.#currentBrowser) {
|
||||
event.preventDefault();
|
||||
event.stopPropagation();
|
||||
this.closeGlance();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue