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:
parent
b1742168e1
commit
93a8629910
2 changed files with 21 additions and 67 deletions
|
@ -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) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue