must have changed something in my themes somewhere, but can not find the specific variable responsible for my current trouble, so please let me explain.
Using some modding on the sidebar items, example:
a[data-panel='ui-develop'] paper-icon-item ha-icon {
{% set core = is_state('update.home_assistant_core_update','on') %}
--card-mod-icon: {{'mdi:package-up' if core else 'mdi:home-assistant'}};
color: {{'red' if states('sensor.memory_use_percent')|int(default=0) > 25 or
core else 'var(--ha-color)'}};
animation: {{'blink 2s ease infinite' if core else 'none'}};
}
which does this:
regular state, using the ha colors (and some extra notification, which is not the issue at hand, so left that out in the yaml above):
update available:
so far so good.
And then when I select that menu item, it shows a selected colorization I can not explain:
somehow, it overrides the card-mod with my primary-color on sidebar-selected-icon-color:
(which also controls the highlighted background) and seems to not touch sidebar-selected-text-color:
I havent set that sidebar-selected-icon-color
in my theme anywhere though, so it probably is done in core. (unless anyone here can explain it otherwise)?
The second challenge is, how to keep that alert-color when the menu-item is selected?
appreciate any help or hint
update
As far as I have been able to find the official variables we have this:
sidebar-background-color: red #ok also above view icons
sidebar-icon-color: pink #ok
sidebar-text-color: green #ok
sidebar-selected-background-color: orange # ??
sidebar-selected-icon-color: purple #ok !! also sets selected-background-color
sidebar-selected-text-color: yellow #ok
which seems to indicate the sidebar-selected-background-color:
is no longer functional, and background is set by the sidebar-selected-icon-color
.
Still is unclear why my system defaults to the primary-color, unless this is somewhere set inside the core styling (havent found that yet) as fallback default.