mirror of
https://github.com/home-assistant/core.git
synced 2025-07-14 16:57:10 +00:00
Add icon translations to Aseko (#108398)
This commit is contained in:
parent
4f998acb78
commit
5d5a2d1381
@ -38,7 +38,6 @@ UNIT_BINARY_SENSORS: tuple[AsekoBinarySensorEntityDescription, ...] = (
|
|||||||
AsekoBinarySensorEntityDescription(
|
AsekoBinarySensorEntityDescription(
|
||||||
key="water_flow",
|
key="water_flow",
|
||||||
translation_key="water_flow",
|
translation_key="water_flow",
|
||||||
icon="mdi:waves-arrow-right",
|
|
||||||
value_fn=lambda unit: unit.water_flow,
|
value_fn=lambda unit: unit.water_flow,
|
||||||
),
|
),
|
||||||
AsekoBinarySensorEntityDescription(
|
AsekoBinarySensorEntityDescription(
|
||||||
|
17
homeassistant/components/aseko_pool_live/icons.json
Normal file
17
homeassistant/components/aseko_pool_live/icons.json
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
{
|
||||||
|
"entity": {
|
||||||
|
"binary_sensor": {
|
||||||
|
"water_flow": {
|
||||||
|
"default": "mdi:waves-arrow-right"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"sensor": {
|
||||||
|
"free_chlorine": {
|
||||||
|
"default": "mdi:flask"
|
||||||
|
},
|
||||||
|
"water_temperature": {
|
||||||
|
"default": "mdi:coolant-temperature"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -59,10 +59,8 @@ class VariableSensorEntity(AsekoEntity, SensorEntity):
|
|||||||
self._attr_native_unit_of_measurement = self._variable.unit
|
self._attr_native_unit_of_measurement = self._variable.unit
|
||||||
|
|
||||||
self._attr_icon = {
|
self._attr_icon = {
|
||||||
"clf": "mdi:flask",
|
|
||||||
"rx": "mdi:test-tube",
|
"rx": "mdi:test-tube",
|
||||||
"waterLevel": "mdi:waves",
|
"waterLevel": "mdi:waves",
|
||||||
"waterTemp": "mdi:coolant-temperature",
|
|
||||||
}.get(self._variable.type)
|
}.get(self._variable.type)
|
||||||
|
|
||||||
self._attr_device_class = {
|
self._attr_device_class = {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user