mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-03-19 00:55:48 +00:00
persian datepicker bug fixed (#1668)
* add single client bug fixed * persian datepicker bug fixed
This commit is contained in:
@@ -11,6 +11,7 @@
|
||||
function createThemeSwitcher() {
|
||||
const isDarkTheme = localStorage.getItem('dark-mode') === 'true';
|
||||
const theme = isDarkTheme ? 'dark' : 'light';
|
||||
document.querySelector('body').setAttribute('class', theme)
|
||||
return {
|
||||
isDarkTheme,
|
||||
get currentTheme() {
|
||||
@@ -19,6 +20,7 @@
|
||||
toggleTheme() {
|
||||
this.isDarkTheme = !this.isDarkTheme;
|
||||
localStorage.setItem('dark-mode', this.isDarkTheme);
|
||||
document.querySelector('body').setAttribute('class', this.isDarkTheme ? 'dark' : 'light')
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user