FIX: Close hyperlink modal on ESC key (#13166)
This commit is contained in:
parent
83dd47f0b4
commit
ea68bab135
|
@ -22,7 +22,6 @@ export default Controller.extend(ModalFunctionality, {
|
|||
|
||||
schedule("afterRender", () => {
|
||||
const element = document.querySelector(".insert-link");
|
||||
|
||||
element.addEventListener("keydown", this.keyDown);
|
||||
|
||||
element
|
||||
|
@ -57,6 +56,8 @@ export default Controller.extend(ModalFunctionality, {
|
|||
this.set("searchResults", []);
|
||||
event.preventDefault();
|
||||
event.stopPropagation();
|
||||
} else {
|
||||
this.send("closeModal");
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue