diff options
| author | Alexandre Flament <alex@al-f.net> | 2021-11-19 13:49:16 +0100 |
|---|---|---|
| committer | Alexandre Flament <alex@al-f.net> | 2021-11-19 16:45:50 +0100 |
| commit | ec5a82fccd658790708b230516fa6ce93f9c7612 (patch) | |
| tree | 4e8c67b41670ccc5bd0132b5b1005eca45ac77bb /searx/static/themes/simple/src/js | |
| parent | f6bfc8f4615ba91f3c54687ae9f0dc828507573e (diff) | |
[enh] simple theme: add "simple-style" preferences
Diffstat (limited to 'searx/static/themes/simple/src/js')
| -rw-r--r-- | searx/static/themes/simple/src/js/head/00_init.js | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/searx/static/themes/simple/src/js/head/00_init.js b/searx/static/themes/simple/src/js/head/00_init.js index d359a9174..21b1754bf 100644 --- a/searx/static/themes/simple/src/js/head/00_init.js +++ b/searx/static/themes/simple/src/js/head/00_init.js @@ -27,5 +27,10 @@ }; // update the css - d.getElementsByTagName("html")[0].className = (w.searxng.touch)?"js touch":"js"; + var hmtlElement = d.getElementsByTagName("html")[0]; + hmtlElement.classList.remove('no-js'); + hmtlElement.classList.add('js'); + if (w.searxng.touch) { + hmtlElement.classList.add('touch'); + } })(window, document);
\ No newline at end of file |