3 :root, body #app.is-light {
4 {{ getVars(themes.light) }}
5 } @media (prefers-color-scheme: light), (prefers-color-scheme:
6 no-preference) { :root, body #app {
7 {{ getVars(themes.light) }}
8 } } body #app.is-dark {
9 {{ getVars(themes.dark) }}
10 } @media (prefers-color-scheme: dark) { :root, body #app {
11 {{ getVars(themes.dark) }}
23 getVars: function (theme) {
25 for (const themeVars in theme) {
26 let value = `${theme[themeVars]}`;
29 } else if (themeVars == "background-image") {
30 value = `url(${theme[themeVars]})`;
32 vars.push(`--${themeVars}: ${value}`);
34 return vars.join(";");