Add icon translations to Garages Amsterdam (#111610)

This commit is contained in:
Joost Lekkerkerker 2024-02-27 10:39:31 +01:00 committed by GitHub
parent 497b63216a
commit c09212e5aa
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 22 additions and 5 deletions

View File

@ -0,0 +1,18 @@
{
"entity": {
"sensor": {
"free_space_short": {
"default": "mdi:car"
},
"free_space_long": {
"default": "mdi:car"
},
"short_capacity": {
"default": "mdi:car"
},
"long_capacity": {
"default": "mdi:car"
}
}
}
}

View File

@ -11,10 +11,10 @@ from . import get_coordinator
from .entity import GaragesAmsterdamEntity
SENSORS = {
"free_space_short": "mdi:car",
"free_space_long": "mdi:car",
"short_capacity": "mdi:car",
"long_capacity": "mdi:car",
"free_space_short",
"free_space_long",
"short_capacity",
"long_capacity",
}
@ -50,7 +50,6 @@ class GaragesAmsterdamSensor(GaragesAmsterdamEntity, SensorEntity):
"""Initialize garages amsterdam sensor."""
super().__init__(coordinator, garage_name, info_type)
self._attr_translation_key = info_type
self._attr_icon = SENSORS[info_type]
@property
def available(self) -> bool: