Add icon translations to Bosch SHC (#111350)

* Add icon translations to Bosch SHC

* Update homeassistant/components/bosch_shc/sensor.py

* Update homeassistant/components/bosch_shc/sensor.py
This commit is contained in:
Joost Lekkerkerker 2024-02-25 14:09:44 +01:00 committed by GitHub
parent 0009c9a1de
commit 9ada85af36
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 20 additions and 4 deletions

View File

@ -0,0 +1,20 @@
{
"entity": {
"sensor": {
"purity": {
"default": "mdi:molecule-co2"
},
"communication_quality": {
"default": "mdi:wifi"
},
"valvetappet": {
"default": "mdi:gauge"
}
},
"switch": {
"routing": {
"default": "mdi:wifi"
}
}
}
}

View File

@ -199,7 +199,6 @@ class PuritySensor(SHCEntity, SensorEntity):
"""Representation of an SHC purity reporting sensor."""
_attr_translation_key = "purity"
_attr_icon = "mdi:molecule-co2"
_attr_native_unit_of_measurement = CONCENTRATION_PARTS_PER_MILLION
def __init__(self, device: SHCDevice, parent_id: str, entry_id: str) -> None:
@ -256,7 +255,6 @@ class CommunicationQualitySensor(SHCEntity, SensorEntity):
"""Representation of an SHC communication quality reporting sensor."""
_attr_translation_key = "communication_quality"
_attr_icon = "mdi:wifi"
def __init__(self, device: SHCDevice, parent_id: str, entry_id: str) -> None:
"""Initialize an SHC communication quality reporting sensor."""
@ -339,7 +337,6 @@ class EnergySensor(SHCEntity, SensorEntity):
class ValveTappetSensor(SHCEntity, SensorEntity):
"""Representation of an SHC valve tappet reporting sensor."""
_attr_icon = "mdi:gauge"
_attr_translation_key = "valvetappet"
_attr_state_class = SensorStateClass.MEASUREMENT
_attr_native_unit_of_measurement = PERCENTAGE

View File

@ -199,7 +199,6 @@ class SHCSwitch(SHCEntity, SwitchEntity):
class SHCRoutingSwitch(SHCEntity, SwitchEntity):
"""Representation of a SHC routing switch."""
_attr_icon = "mdi:wifi"
_attr_translation_key = "routing"
_attr_entity_category = EntityCategory.CONFIG