mirror of
https://gitlab1.ptb.de/waltem01/Matrix
synced 2024-11-14 00:43:50 +00:00
update matrix by swapping canvas buffers
This commit is contained in:
parent
6a2e1f48f9
commit
0264a9bd30
@ -10,6 +10,11 @@
|
||||
let imageURL: string | null, lastImage: File;
|
||||
let uploadData: UploadData;
|
||||
|
||||
async function updateMatrix() {
|
||||
await fetch('/api/redirect?endpoint=update');
|
||||
clearInterval(uploadData.interval);
|
||||
}
|
||||
|
||||
async function placeImage() {
|
||||
const fdata = new FormData();
|
||||
fdata.append('x', '0');
|
||||
@ -108,10 +113,15 @@
|
||||
{#await placeImage()}
|
||||
<p>Placing image . . .</p>
|
||||
<p>{uploadData.elapsed} seconds elapsed.</p>
|
||||
{:then}
|
||||
{#await updateMatrix()}
|
||||
<p>Updating matrix . . .</p>
|
||||
<p>{uploadData.elapsed} seconds elapsed.</p>
|
||||
{:then}
|
||||
<p>Done!</p>
|
||||
<p>{uploadData.elapsed} seconds elapsed.</p>
|
||||
{/await}
|
||||
{/await}
|
||||
{/await}
|
||||
{/await}
|
||||
{/if}
|
||||
|
Loading…
Reference in New Issue
Block a user