From 4525a9d5ed08a959debdfe9301983f7dd1badebd Mon Sep 17 00:00:00 2001 From: Pieter Vander Vennet Date: Wed, 22 Jan 2025 02:27:26 +0100 Subject: [PATCH] Chore: small refactorings --- src/UI/StatisticsGUI.ts | 5 +++-- src/index.ts | 1 - 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/UI/StatisticsGUI.ts b/src/UI/StatisticsGUI.ts index 90a3674e8..f3e659134 100644 --- a/src/UI/StatisticsGUI.ts +++ b/src/UI/StatisticsGUI.ts @@ -1,4 +1,5 @@ -import SvelteUIElement from "./Base/SvelteUIElement" import { default as StatisticsSvelte } from "../UI/Statistics/StatisticsGui.svelte" -new SvelteUIElement(StatisticsSvelte).AttachTo("main") +const target = document.getElementById("main") +target.innerHTML = "" +new StatisticsSvelte({ target }) diff --git a/src/index.ts b/src/index.ts index c5013c067..b74554698 100644 --- a/src/index.ts +++ b/src/index.ts @@ -52,7 +52,6 @@ async function main() { DetermineTheme.getTheme(), await getAvailableLayers(), ]) - availableLayers?.delete("cycle_highways") // TODO remove after next cache.mapcomplete.org update console.log("The available layers on server are", Array.from(availableLayers)) const state = new ThemeViewState(theme, availableLayers) const target = document.getElementById("maindiv")