Fix light with brightness

This commit is contained in:
Gerard
2022-03-20 00:17:50 +01:00
committed by GitHub
parent 2f21594289
commit 1e9a8df3f8

View File

@@ -381,7 +381,7 @@ class NsPanelLovelaceUI:
color = rgb_brightness(color, entity.attributes.brightness)
icon_color = rgb_dec565(color)
elif "brightness" in entity.attributes:
color = rgb_brightness(color, [253, 216, 53])
color = rgb_brightness([253, 216, 53], entity.attributes.brightness)
icon_color = rgb_dec565(color)
return f",{item_type},{item},1,{icon_color},{name},{switch_val}"
@@ -537,7 +537,7 @@ class NsPanelLovelaceUI:
color = rgb_brightness(color, entity.attributes.brightness)
icon_color = rgb_dec565(color)
elif "brightness" in entity.attributes:
color = rgb_brightness(color, [253, 216, 53])
color = rgb_brightness([253, 216, 53], entity.attributes.brightness)
icon_color = rgb_dec565(color)
brightness = "disable"