[desktop] apply theme's type if available
This commit is contained in:
parent
f0786bcdd6
commit
a6df1332b8
|
@ -52,9 +52,15 @@ var checkLocalStorage = (function () {
|
||||||
}
|
}
|
||||||
})();
|
})();
|
||||||
|
|
||||||
if ( window.desktop && window.desktop.theme && (window.desktop.theme.id || window.desktop.theme.type)) {
|
if ( window.desktop && window.desktop.theme ) {
|
||||||
|
if ( window.desktop.theme.id ) {
|
||||||
// params.uitheme = undefined;
|
// params.uitheme = undefined;
|
||||||
localStorage.setItem("ui-theme-id", window.desktop.theme.id);
|
localStorage.setItem("ui-theme-id", window.desktop.theme.id);
|
||||||
|
} else
|
||||||
|
if ( window.desktop.theme.type ) {
|
||||||
|
if ( window.desktop.theme.type == 'dark' ) params.uitheme == 'default-dark'; else
|
||||||
|
if ( window.desktop.theme.type == 'light' ) params.uitheme == 'default-light';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( !!params.uitheme && checkLocalStorage && !localStorage.getItem("ui-theme-id") ) {
|
if ( !!params.uitheme && checkLocalStorage && !localStorage.getItem("ui-theme-id") ) {
|
||||||
|
|
Loading…
Reference in a new issue