Clean up device class based entity translations in Elgato (#95122)

* Clean up device class based entity translations in Elgato

* Update snapshots
This commit is contained in:
Franck Nijhof 2023-06-24 12:45:47 +02:00 committed by GitHub
parent fe9366eee6
commit a2f9caa482
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 2 additions and 10 deletions

View File

@ -47,7 +47,6 @@ BUTTONS = [
),
ElgatoButtonEntityDescription(
key="restart",
translation_key="restart",
device_class=ButtonDeviceClass.RESTART,
entity_category=EntityCategory.CONFIG,
press_fn=lambda client: client.restart(),

View File

@ -45,7 +45,6 @@ class ElgatoSensorEntityDescription(
SENSORS = [
ElgatoSensorEntityDescription(
key="battery",
translation_key="battery",
device_class=SensorDeviceClass.BATTERY,
entity_category=EntityCategory.DIAGNOSTIC,
native_unit_of_measurement=PERCENTAGE,

View File

@ -26,15 +26,9 @@
"button": {
"identify": {
"name": "Identify"
},
"restart": {
"name": "[%key:component::button::entity_component::restart::name%]"
}
},
"sensor": {
"battery": {
"name": "[%key:component::sensor::entity_component::battery::name%]"
},
"charge_power": {
"name": "Charging power"
},

View File

@ -111,7 +111,7 @@
'original_name': 'Restart',
'platform': 'elgato',
'supported_features': 0,
'translation_key': 'restart',
'translation_key': None,
'unique_id': 'GW24L1A02987_restart',
'unit_of_measurement': None,
})

View File

@ -44,7 +44,7 @@
'original_name': 'Battery',
'platform': 'elgato',
'supported_features': 0,
'translation_key': 'battery',
'translation_key': None,
'unique_id': 'GW24L1A02987_battery',
'unit_of_measurement': '%',
})