Added auto darkmode

This commit is contained in:
Jeroen De Meerleer 2023-08-17 00:22:55 +02:00
parent f8b7247346
commit a89efa0ddb
Signed by: JeroenED
GPG Key ID: 28CCCB8F62BFADD6

View File

@ -7,6 +7,7 @@
import '../app.postcss'; import '../app.postcss';
import {alerts, globals} from "$lib/stores.js"; import {alerts, globals} from "$lib/stores.js";
import { autoModeWatcher } from '@skeletonlabs/skeleton';
let alertsvar; let alertsvar;
let globalvars; let globalvars;
@ -25,7 +26,7 @@
globalvars = value; globalvars = value;
}); });
</script> </script>
<svelte:head>{@html `<script>${autoModeWatcher.toString()} autoModeWatcher();</script>`}</svelte:head>
{#if typeof globalvars.user !== 'undefined' } {#if typeof globalvars.user !== 'undefined' }
{#each alertsvar as alert, i} {#each alertsvar as alert, i}
<aside class="alert variant-filled-{alert.class}"> <aside class="alert variant-filled-{alert.class}">