Skip to content

Commit 5fc220f

Browse files
committed
fix: default to light mode for better initial user experience
1 parent 4bdd3c8 commit 5fc220f

1 file changed

Lines changed: 0 additions & 3 deletions

File tree

src/layouts/Layout.astro

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,6 @@ const { title, description = "Markdown 中文教程 - 完整指南" } = Astro.pr
3030
if (typeof localStorage !== 'undefined' && localStorage.getItem('theme')) {
3131
return localStorage.getItem('theme');
3232
}
33-
if (window.matchMedia('(prefers-color-scheme: dark)').matches) {
34-
return 'dark';
35-
}
3633
return 'light';
3734
})();
3835
if (theme === 'dark') {

0 commit comments

Comments
 (0)