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