Add icon translations to Version (#112343)

This commit is contained in:
Joost Lekkerkerker 2024-03-11 19:00:56 +01:00 committed by GitHub
parent 23ffcaf187
commit 0b6307fa53
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 10 additions and 2 deletions

View file

@ -0,0 +1,9 @@
{
"entity": {
"sensor": {
"version": {
"default": "mdi:package-up"
}
}
}
}

View file

@ -32,6 +32,7 @@ async def async_setup_entry(
entity_description=SensorEntityDescription(
key=str(entry.data[CONF_SOURCE]),
name=entity_name,
translation_key="version",
),
)
]
@ -42,8 +43,6 @@ async def async_setup_entry(
class VersionSensorEntity(VersionEntity, SensorEntity):
"""Version sensor entity class."""
_attr_icon = "mdi:package-up"
@property
def native_value(self) -> StateType:
"""Return the native value of this sensor."""