Adds option to change theme

This commit is contained in:
Rune Harlyk
2024-03-30 17:19:29 +01:00
committed by Rune Harlyk
parent e0fa434aeb
commit e71fc68652
4 changed files with 16 additions and 4 deletions
+9
View File
@@ -11,6 +11,8 @@
import RssiIndicator from '$lib/components/RSSIIndicator.svelte';
import BatteryIndicator from '$lib/components/BatteryIndicator.svelte';
import UpdateIndicator from '$lib/components/UpdateIndicator.svelte';
import MdiWeatherSunny from '~icons/mdi/weather-sunny';
import MdiMoonAndStars from '~icons/mdi/moon-and-stars';
async function postSleep() {
const response = await fetch('/rest/sleep', {
@@ -48,6 +50,13 @@
<div class="indicator flex-none">
<UpdateIndicator />
</div>
<div class="flex-none">
<label class="swap swap-rotate">
<input type="checkbox" value="light" class="theme-controller"/>
<MdiWeatherSunny class="swap-off h-7 w-7"/>
<MdiMoonAndStars class="swap-on h-7 w-7"/>
</label>
</div>
<div class="flex-none">
{#if $telemetry.rssi.disconnected}
<WiFiOff class="h-7 w-7" />