diff --git a/Webserver/src/routes/image/+page.svelte b/Webserver/src/routes/image/+page.svelte index cadd518..b53df87 100644 --- a/Webserver/src/routes/image/+page.svelte +++ b/Webserver/src/routes/image/+page.svelte @@ -9,9 +9,7 @@ let imageURL: string, uploadData: UploadData; - async function sendImage(data: ImageData) {} - - async function loadImage(url: string): Promise {} + async function sendImage() {} function uploadImage(event: Event) { // Revoke previous image url, if any @@ -30,17 +28,12 @@ {#if imageURL} User uploaded - {#await loadImage(imageURL)} -

Loading image data . . .

+ {#await sendImage()} +

Sending image . . .

{uploadData.elapsed} seconds elapsed.

- {:then data} - {#await sendImage(data)} -

Uploading image data . . .

-

{uploadData.elapsed} seconds elapsed.

- {:then} -

Done!

-

{uploadData.elapsed} seconds elapsed.

- {clearInterval(uploadData.interval)} - {/await} + {:then} +

Done!

+

{uploadData.elapsed} seconds elapsed.

+ {clearInterval(uploadData.interval)} {/await} {/if}