When an user has opposite themes for their OS and the website, like OS dark and website light, it generates a flickering behaviour during loadings while browsing the website.
This fix this bug introducing a single line js inside the <head> to update the data-theme if there is a local theme defined by the user. Since this behaviour only happens when the user can toggle the theme, the single line script main_block.js is only deployed if the website config has the EnableThemeToggle set.
When an user has opposite themes for their OS and the website, like OS dark and website light, it generates a flickering behaviour during loadings while browsing the website.
This fix this bug introducing a single line js inside the
<head>
to update thedata-theme
if there is a localtheme
defined by the user. Since this behaviour only happens when the user can toggle the theme, the single line scriptmain_block.js
is only deployed if the website config has theEnableThemeToggle
set.This addresses issue #429.
Tested locally and online. Working perfectly.