From bd2bdf326f15422052a0f376c951139c21ae85e3 Mon Sep 17 00:00:00 2001 From: wukko Date: Mon, 8 Jul 2024 19:29:30 +0600 Subject: [PATCH] web/Omnibox: handle enter key press --- web/src/components/save/Omnibox.svelte | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/web/src/components/save/Omnibox.svelte b/web/src/components/save/Omnibox.svelte index f0d5bbd7..2b8b59f0 100644 --- a/web/src/components/save/Omnibox.svelte +++ b/web/src/components/save/Omnibox.svelte @@ -57,6 +57,10 @@ linkInput.focus(); } + if (e.key === "Enter" && validLink(link)) { + downloadButton.download(link); + } + if (['Escape', 'Clear'].includes(e.key)) { link = ""; }