TODO: bugfixes

This commit is contained in:
waltem01 2022-08-07 21:19:55 +02:00
parent 7aa1dc90cd
commit 0e33907fe9

View File

@ -13,6 +13,7 @@
clearMatrix(); clearMatrix();
const form = event.target as HTMLFormElement; const form = event.target as HTMLFormElement;
// TODO: Calling API via server-side
const response = await fetch(`http://localhost:8080/${form.dataset.endpoint}`, { const response = await fetch(`http://localhost:8080/${form.dataset.endpoint}`, {
mode: 'cors' mode: 'cors'
}); });
@ -42,6 +43,7 @@
// break; // break;
} }
// TODO: Calling API via server-side
const response = await fetch(`http://localhost:8080/${form.dataset.endpoint}`, { const response = await fetch(`http://localhost:8080/${form.dataset.endpoint}`, {
method: form.method, method: form.method,
mode: 'cors', mode: 'cors',
@ -111,6 +113,7 @@
fdata.append('x', x.toString()); fdata.append('x', x.toString());
fdata.append('y', y.toString()); fdata.append('y', y.toString());
// TODO: Calling API via server-side
const response = await fetch('http://localhost:8080/pixel', { const response = await fetch('http://localhost:8080/pixel', {
method: 'POST', method: 'POST',
mode: 'cors', mode: 'cors',
@ -421,7 +424,7 @@
<td <td
data-x={cell.xIndex} data-x={cell.xIndex}
class="p-0.75" class="p-0.75"
style="background-color: #{cell.color}" style="background-color: #{cell.color};"
on:mouseenter={setMousePixel} on:mouseenter={setMousePixel}
/> />
{/each} {/each}