diff --git a/src/components/ThemeSelection.svelte b/src/components/ThemeSelection.svelte index a1643b7..c5a5d4d 100644 --- a/src/components/ThemeSelection.svelte +++ b/src/components/ThemeSelection.svelte @@ -18,6 +18,60 @@ classList.toggle('theme-shadow') } + // looks scuffed ik but better than hardcoding things + let themeList = [ + { + id: "theme-darcula", + jsId: "darcula-theme", + name: "Darcula" + }, + { + id: "theme-light", + jsId: "light-theme", + name: "Light" + }, + { + id: "theme-moonlight", + jsId: "moonlight-theme", + name: "Moonlight" + }, + { + id: "theme-purple-rain", + jsId: "purple-rain-theme", + nam: "Purple Rain" + }, + { + id: "theme-gruvbox", + jsId: "gruvbox-theme", + name: "Gruvbox" + }, + { + id: "theme-cat-macchiato", + jsId: "cat-macchiato", + name: "Cat Macchiato" + }, + { + id: "theme-cat-mocha", + jsId: "cat-mocha", + name: "Cat Mocha" + }, + { + id: "theme-cat-frappe", + jsId: "cat-frappe", + name: "Cat Frappe" + }, + { + id: "theme-deep-ocean", + jsId: "deep-ocean-theme", + name: "Deep Ocean" + }, + { + id: "theme-amoled", + jsId: "amoled-theme", + name: "Amoled" + } + ] + function clickedOutside() { if (open) toggleThemeSelector() @@ -30,36 +84,11 @@
-
selectTheme('theme-darcula')}> -

Darcula

-
-
selectTheme('theme-light')}> -

Light

-
-
selectTheme('theme-moonlight')}> -

Moonlight

-
-
selectTheme('theme-purple-rain')}> -

Purple Rain

-
-
selectTheme('theme-gruvbox')}> -

Gruvbox

-
-
selectTheme('theme-cat-macchiato')}> -

Cat Macchiato

-
-
selectTheme('theme-cat-mocha')}> -

Cat Mocha

-
-
selectTheme('theme-cat-frappe')}> -

Cat Frappé

-
-
selectTheme('theme-deep-ocean')}> -

Deep Ocean

-
-
selectTheme('theme-amoled')}> -

Amoled

-
+ {#each themeList as obj} +
selectTheme(obj.id)}> +

{obj.name}

+
+ {/each}

Theme Selection