Migrate TOLO Sauna translations (#83306)

* Migrate TOLO Sauna translations

* Fix capa
This commit is contained in:
Franck Nijhof 2022-12-05 13:55:07 +01:00 committed by GitHub
parent 03dc527a85
commit 73162e6fb5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 21 additions and 9 deletions

View File

@ -27,11 +27,11 @@ async def async_setup_entry(
class ToloLampModeSelect(ToloSaunaCoordinatorEntity, SelectEntity): class ToloLampModeSelect(ToloSaunaCoordinatorEntity, SelectEntity):
"""TOLO Sauna lamp mode select.""" """TOLO Sauna lamp mode select."""
_attr_device_class = "tolo__lamp_mode"
_attr_entity_category = EntityCategory.CONFIG _attr_entity_category = EntityCategory.CONFIG
_attr_icon = "mdi:lightbulb-multiple-outline" _attr_icon = "mdi:lightbulb-multiple-outline"
_attr_name = "Lamp Mode" _attr_name = "Lamp Mode"
_attr_options = [lamp_mode.name.lower() for lamp_mode in LampMode] _attr_options = [lamp_mode.name.lower() for lamp_mode in LampMode]
_attr_translation_key = "lamp_mode"
def __init__( def __init__(
self, coordinator: ToloSaunaUpdateCoordinator, entry: ConfigEntry self, coordinator: ToloSaunaUpdateCoordinator, entry: ConfigEntry

View File

@ -18,5 +18,15 @@
"abort": { "abort": {
"already_configured": "[%key:common::config_flow::abort::already_configured_device%]" "already_configured": "[%key:common::config_flow::abort::already_configured_device%]"
} }
},
"entity": {
"select": {
"lamp_mode": {
"state": {
"automatic": "Automatic",
"manual": "Manual"
}
}
}
} }
} }

View File

@ -1,8 +0,0 @@
{
"state": {
"tolo__lamp_mode": {
"automatic": "automatic",
"manual": "manual"
}
}
}

View File

@ -18,5 +18,15 @@
"description": "Enter the hostname or IP address of your TOLO Sauna device." "description": "Enter the hostname or IP address of your TOLO Sauna device."
} }
} }
},
"entity": {
"select": {
"lamp_mode": {
"state": {
"automatic": "Automatic",
"manual": "Manual"
}
}
}
} }
} }