diff --git a/src/app.html b/src/app.html index b4100c2..0787360 100644 --- a/src/app.html +++ b/src/app.html @@ -40,8 +40,8 @@ } if (localStorage.theme === 'system') { - document.documentElement.classList.add(prefersDarkTheme ? 'dark' : 'light'); - metaThemeColorTag.setAttribute('content', prefersDarkTheme ? '#171717' : '#ffffff'); + document.documentElement.classList.add('light'); + metaThemeColorTag.setAttribute('content', '#171717'); } else if (localStorage.theme === 'oled-dark') { document.documentElement.style.setProperty('--color-gray-800', '#101010'); document.documentElement.style.setProperty('--color-gray-850', '#050505'); @@ -61,19 +61,19 @@ metaThemeColorTag.setAttribute('content', '#171717'); } - window.matchMedia('(prefers-color-scheme: dark)').addListener((e) => { - if (localStorage.theme === 'system') { - if (e.matches) { - document.documentElement.classList.add('dark'); - document.documentElement.classList.remove('light'); - metaThemeColorTag.setAttribute('content', '#171717'); - } else { - document.documentElement.classList.add('light'); - document.documentElement.classList.remove('dark'); - metaThemeColorTag.setAttribute('content', '#ffffff'); - } - } - }); + // window.matchMedia('(prefers-color-scheme: dark)').addListener((e) => { + // if (localStorage.theme === 'system') { + // if (e.matches) { + // document.documentElement.classList.add('dark'); + // document.documentElement.classList.remove('light'); + // metaThemeColorTag.setAttribute('content', '#171717'); + // } else { + // document.documentElement.classList.add('light'); + // document.documentElement.classList.remove('dark'); + // metaThemeColorTag.setAttribute('content', '#ffffff'); + // } + // } + // }); })(); diff --git a/src/lib/components/chat/Header.svelte b/src/lib/components/chat/Header.svelte new file mode 100644 index 0000000..b99e412 --- /dev/null +++ b/src/lib/components/chat/Header.svelte @@ -0,0 +1,136 @@ + + +
需要我帮您做点什么?
+{itemP.label}
+ {/each} +