mirror of
https://github.com/joBr99/nspanel-lovelace-ui.git
synced 2025-12-20 22:47:01 +01:00
fixed binary sensors
This commit is contained in:
@@ -188,7 +188,7 @@ class HAEntity(panel_cards.Entity):
|
||||
icon_char = value
|
||||
case 'binary_sensor':
|
||||
device_class = self.attributes.get("device_class", "")
|
||||
value = get_translation(self.locale, f"backend.component.binary_sensor.state.{device_class}.{entity.state}")
|
||||
value = get_translation(self.locale, f"backend.component.binary_sensor.state.{device_class}.{self.state}")
|
||||
case 'weather':
|
||||
attr = self.config.get("attribute", "temperature")
|
||||
value = str(self.attributes.get(attr, self.state))
|
||||
|
||||
Reference in New Issue
Block a user