mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-23 13:51:20 -08:00
Fix hotkey event handling for non-input elements
This commit is contained in:
1 parent
144ab64421
commit
52be176830
2 files changed
+2
-2
No files matched your search
@@ -4155,7 +4155,7 @@ class Hotkey {
|
||||
if (this.art.isFocus) {
|
||||
const tag = document.activeElement.tagName.toUpperCase();
|
||||
const editable = document.activeElement.getAttribute("contenteditable");
|
||||
if (tag !== "INPUT" && tag !== "TEXTAREA" && editable !== "" && editable !== "true") {
|
||||
if (tag !== "INPUT" && tag !== "TEXTAREA" && editable !== "" && editable !== "true" && !event.altKey && !event.ctrlKey && !event.metaKey && !event.shiftKey) {
|
||||
const events = this.keys[event.keyCode];
|
||||
if (events) {
|
||||
event.preventDefault();
|
||||
|
||||
Reference in new issue
Block a user