Update theme.js
This commit is contained in:
1 parent
e74c3c35ea
commit
c17fc68ea3
1 file changed
+6
-1
+6
-1
@@ -38,4 +38,9 @@ function applyTheme() {
|
||||
const theme = getTheme();
|
||||
document.documentElement.setAttribute('data-theme', theme);
|
||||
updateThemeUI(theme);
|
||||
}
|
||||
}
|
||||
|
||||
// 确保 DOM 加载完成后执行
|
||||
document.addEventListener('DOMContentLoaded', function() {
|
||||
applyTheme();
|
||||
});
|
||||
Reference in new issue
Block a user