This commit is contained in:
Jesse Winton
2025-04-04 11:44:37 -04:00
parent f548d8995a
commit bbc73067f5
3 changed files with 11 additions and 74 deletions

View File

@@ -1,8 +1,8 @@
<script lang="ts">
import { type Theme, currentTheme } from '$routes/+layout.svelte';
import Select, { type SelectOption } from './Select.svelte';
import { Select as Select2 } from '$lib/components/ui';
import { themeStore, setTheme, type Theme } from '$lib/providers/theme';
import { get } from 'svelte/store';
const options = [
{
@@ -23,5 +23,11 @@
];
</script>
<Select {options} bind:value={$currentTheme} placement="top" />
<Select2 {options} bind:value={$currentTheme} />
<Select {options} bind:value={$themeStore.theme} placement="top" />
<Select2
{options}
bind:value={$themeStore.theme}
onValueChange={(e) => {
setTheme(e as Theme);
}}
/>