From 182160de1066a303ae337a50aca6c48f84c5c61b Mon Sep 17 00:00:00 2001 From: GeckoEidechse Date: Thu, 1 Sep 2022 20:12:28 +0200 Subject: Remove elements from template application --- src-ui/src/main.ts | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) (limited to 'src-ui') diff --git a/src-ui/src/main.ts b/src-ui/src/main.ts index 6eaee030..c4a69554 100644 --- a/src-ui/src/main.ts +++ b/src-ui/src/main.ts @@ -14,9 +14,9 @@ var globalState = { document.addEventListener("DOMContentLoaded", async function () { // get the elements - const helloEl = $("div.hello")! as HTMLElement; - let counterButtonEl = $("counter-button") as HTMLElement; - let counterResultEl = $("counter-result") as HTMLElement; + // const helloEl = $("div.hello")! as HTMLElement; + // let counterButtonEl = $("counter-button") as HTMLElement; + // let counterResultEl = $("counter-result") as HTMLElement; let pingEl = $("backend-ping")! as HTMLElement; let panicButtonEl = $("panic-button") as HTMLElement; let installLocationHolderEl = $("install-location-holder") as HTMLElement; @@ -84,20 +84,20 @@ document.addEventListener("DOMContentLoaded", async function () { alert("TODO"); }); - // counter button click - counterButtonEl.addEventListener("pointerup", async function () { - const result = await invoke("add_count", { num: 1 }) as string; - counterResultEl.textContent = result; - }); - - // hello click - helloEl.addEventListener("pointerup", async function () { - const result = await invoke("hello_world") as string; - helloEl.textContent = result; - setTimeout(function () { - helloEl.textContent = "Click again"; - }, 1000); - }) + // // counter button click + // counterButtonEl.addEventListener("pointerup", async function () { + // const result = await invoke("add_count", { num: 1 }) as string; + // counterResultEl.textContent = result; + // }); + + // // hello click + // helloEl.addEventListener("pointerup", async function () { + // const result = await invoke("hello_world") as string; + // helloEl.textContent = result; + // setTimeout(function () { + // helloEl.textContent = "Click again"; + // }, 1000); + // }) // panic button click panicButtonEl.addEventListener("pointerup", async function () { -- cgit v1.2.3