diff --git a/web/src/components/save/Omnibox.svelte b/web/src/components/save/Omnibox.svelte index 63d68fa9..3cd09beb 100644 --- a/web/src/components/save/Omnibox.svelte +++ b/web/src/components/save/Omnibox.svelte @@ -28,6 +28,8 @@ let linkInput: HTMLInputElement | undefined; let isFocused = false; + let isDisabled: boolean = false; + let downloadButton: SvelteComponent; const validLink = (link: string) => { @@ -67,7 +69,7 @@ }; const handleKeydown = (e: KeyboardEvent) => { - if (!linkInput || $dialogs.length > 0) { + if (!linkInput || $dialogs.length > 0 || isDisabled) { return; } @@ -136,7 +138,7 @@ (link = "")} /> {/if} {#if validLink(link)} - + {/if} diff --git a/web/src/components/save/buttons/DownloadButton.svelte b/web/src/components/save/buttons/DownloadButton.svelte index 5201b3bc..c6a37969 100644 --- a/web/src/components/save/buttons/DownloadButton.svelte +++ b/web/src/components/save/buttons/DownloadButton.svelte @@ -10,6 +10,7 @@ import type { DialogInfo } from "$lib/types/dialog"; export let url: string; + export let isDisabled = false; $: buttonText = ">>"; $: buttonAltText = $t('a11y.save.download');