Open
Description
🐛 Bug Report
Followup to #3502
The set mode
was fixed in #3516, but the colorSchemeListener
does not use the mode setter, it just changes the baseLayerLuminance.
Also theming is very inconsistent in behaviour:
- If mode is not set on
loading-theme
, thendata-theme
on not set and css-styling is thus not possible. - If mode is set to system on
loading-theme
, thendata-theme
is set, but colorSchemeListener doesnt work. - If any mode is set on
loading-theme
, thestorage-name
is ignored. - If you have
<FluentDesignTheme />
in static context, it is same asloading-theme
without mode, butstorage-name
works. - If you have
<FluentDesignTheme />
in interactive context, it is same asloading-theme
with mode set tosystem
. - And even if all of these were working, the data-theme on body is not re-applied on page changes on enhanced navigation.
- And if you try to monitor
--base-layer-luminance
you also lose, since that always resets to 0.15 on enhanced navigation. - And if you visit an external page, and then press back... data-theme is gone.
So it is pretty much impossible to find a set of settings that works no matter if a user starts on a static page, a dynamic page, has set their theme, haven't set their theme etc.