prevent keyboard shortcuts with more modifier keys (#26826)

This commit is contained in:
Bram Kragten
2025-09-02 09:39:54 +02:00
committed by GitHub
parent 7c6c92c856
commit 1f0d83190d
2 changed files with 10 additions and 1 deletions

View File

@@ -80,10 +80,14 @@ export class HaAutomationRow extends LitElement {
ev.key !== " " &&
!(
(this.sortSelected || ev.altKey) &&
!(ev.ctrlKey || ev.metaKey) &&
!ev.shiftKey &&
(ev.key === "ArrowUp" || ev.key === "ArrowDown")
) &&
!(
(ev.ctrlKey || ev.metaKey) &&
!ev.shiftKey &&
!ev.altKey &&
(ev.key === "c" || ev.key === "x" || ev.key === "Delete")
)
) {