1
0
Fork 0
mirror of https://github.com/miniflux/v2.git synced 2025-09-30 19:22:11 +00:00

refactor(js): simplify modal_handler.js

This commit is contained in:
Julien Voisin 2025-09-13 02:24:51 +02:00 committed by GitHub
parent b1742168e1
commit 93a8629910
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 21 additions and 67 deletions

View file

@ -570,7 +570,7 @@ function initializeFormHandlers() {
*/
function showKeyboardShortcutsAction() {
const template = document.getElementById("keyboard-shortcuts");
ModalHandler.open(template.content, "dialog-title");
KeyboardModalHandler.open(template.content, "dialog-title");
}
/**
@ -1215,7 +1215,7 @@ function initializeKeyboardShortcuts() {
// UI actions
keyboardHandler.on("?", showKeyboardShortcutsAction);
keyboardHandler.on("Escape", () => ModalHandler.close());
keyboardHandler.on("Escape", () => KeyboardModalHandler.close());
keyboardHandler.on("a", () => {
const enclosureElement = document.querySelector('.entry-enclosures');
if (enclosureElement) {