mirror of
https://github.com/home-assistant/core.git
synced 2025-07-14 08:47:10 +00:00
Add icon translations to Tolo (#112313)
This commit is contained in:
parent
d923b56f9f
commit
a13304be5c
@ -34,7 +34,6 @@ class ToloFlowInBinarySensor(ToloSaunaCoordinatorEntity, BinarySensorEntity):
|
||||
_attr_entity_category = EntityCategory.DIAGNOSTIC
|
||||
_attr_translation_key = "water_in_valve"
|
||||
_attr_device_class = BinarySensorDeviceClass.OPENING
|
||||
_attr_icon = "mdi:water-plus-outline"
|
||||
|
||||
def __init__(
|
||||
self, coordinator: ToloSaunaUpdateCoordinator, entry: ConfigEntry
|
||||
@ -56,7 +55,6 @@ class ToloFlowOutBinarySensor(ToloSaunaCoordinatorEntity, BinarySensorEntity):
|
||||
_attr_entity_category = EntityCategory.DIAGNOSTIC
|
||||
_attr_translation_key = "water_out_valve"
|
||||
_attr_device_class = BinarySensorDeviceClass.OPENING
|
||||
_attr_icon = "mdi:water-minus-outline"
|
||||
|
||||
def __init__(
|
||||
self, coordinator: ToloSaunaUpdateCoordinator, entry: ConfigEntry
|
||||
|
@ -30,7 +30,6 @@ class ToloLampNextColorButton(ToloSaunaCoordinatorEntity, ButtonEntity):
|
||||
"""Button for switching to the next lamp color."""
|
||||
|
||||
_attr_entity_category = EntityCategory.CONFIG
|
||||
_attr_icon = "mdi:palette"
|
||||
_attr_translation_key = "next_color"
|
||||
|
||||
def __init__(
|
||||
|
47
homeassistant/components/tolo/icons.json
Normal file
47
homeassistant/components/tolo/icons.json
Normal file
@ -0,0 +1,47 @@
|
||||
{
|
||||
"entity": {
|
||||
"binary_sensor": {
|
||||
"water_in_valve": {
|
||||
"default": "mdi:water-plus-outline"
|
||||
},
|
||||
"water_out_valve": {
|
||||
"default": "mdi:water-minus-outline"
|
||||
}
|
||||
},
|
||||
"button": {
|
||||
"next_color": {
|
||||
"default": "mdi:palette"
|
||||
}
|
||||
},
|
||||
"number": {
|
||||
"power_timer": {
|
||||
"default": "mdi:power-settings"
|
||||
},
|
||||
"salt_bath_timer": {
|
||||
"default": "mdi:shaker-outline"
|
||||
},
|
||||
"fan_timer": {
|
||||
"default": "mdi:fan-auto"
|
||||
}
|
||||
},
|
||||
"select": {
|
||||
"lamp_mode": {
|
||||
"default": "mdi:lightbulb-multiple-outline"
|
||||
}
|
||||
},
|
||||
"sensor": {
|
||||
"water_level": {
|
||||
"default": "mdi:waves-arrow-up"
|
||||
},
|
||||
"power_timer_remaining": {
|
||||
"default": "mdi:power-settings"
|
||||
},
|
||||
"salt_bath_timer_remaining": {
|
||||
"default": "mdi:shaker-outline"
|
||||
},
|
||||
"fan_timer_remaining": {
|
||||
"default": "mdi:fan-auto"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -41,7 +41,6 @@ NUMBERS = (
|
||||
ToloNumberEntityDescription(
|
||||
key="power_timer",
|
||||
translation_key="power_timer",
|
||||
icon="mdi:power-settings",
|
||||
native_unit_of_measurement=UnitOfTime.MINUTES,
|
||||
native_max_value=POWER_TIMER_MAX,
|
||||
getter=lambda settings: settings.power_timer,
|
||||
@ -50,7 +49,6 @@ NUMBERS = (
|
||||
ToloNumberEntityDescription(
|
||||
key="salt_bath_timer",
|
||||
translation_key="salt_bath_timer",
|
||||
icon="mdi:shaker-outline",
|
||||
native_unit_of_measurement=UnitOfTime.MINUTES,
|
||||
native_max_value=SALT_BATH_TIMER_MAX,
|
||||
getter=lambda settings: settings.salt_bath_timer,
|
||||
@ -59,7 +57,6 @@ NUMBERS = (
|
||||
ToloNumberEntityDescription(
|
||||
key="fan_timer",
|
||||
translation_key="fan_timer",
|
||||
icon="mdi:fan-auto",
|
||||
native_unit_of_measurement=UnitOfTime.MINUTES,
|
||||
native_max_value=FAN_TIMER_MAX,
|
||||
getter=lambda settings: settings.fan_timer,
|
||||
|
@ -28,7 +28,6 @@ class ToloLampModeSelect(ToloSaunaCoordinatorEntity, SelectEntity):
|
||||
"""TOLO Sauna lamp mode select."""
|
||||
|
||||
_attr_entity_category = EntityCategory.CONFIG
|
||||
_attr_icon = "mdi:lightbulb-multiple-outline"
|
||||
_attr_options = [lamp_mode.name.lower() for lamp_mode in LampMode]
|
||||
_attr_translation_key = "lamp_mode"
|
||||
|
||||
|
@ -48,7 +48,6 @@ SENSORS = (
|
||||
key="water_level",
|
||||
translation_key="water_level",
|
||||
entity_category=EntityCategory.DIAGNOSTIC,
|
||||
icon="mdi:waves-arrow-up",
|
||||
native_unit_of_measurement=PERCENTAGE,
|
||||
getter=lambda status: status.water_level_percent,
|
||||
availability_checker=None,
|
||||
@ -66,7 +65,6 @@ SENSORS = (
|
||||
key="power_timer_remaining",
|
||||
translation_key="power_timer_remaining",
|
||||
entity_category=EntityCategory.DIAGNOSTIC,
|
||||
icon="mdi:power-settings",
|
||||
native_unit_of_measurement=UnitOfTime.MINUTES,
|
||||
getter=lambda status: status.power_timer,
|
||||
availability_checker=lambda settings, status: status.power_on
|
||||
@ -76,7 +74,6 @@ SENSORS = (
|
||||
key="salt_bath_timer_remaining",
|
||||
translation_key="salt_bath_timer_remaining",
|
||||
entity_category=EntityCategory.DIAGNOSTIC,
|
||||
icon="mdi:shaker-outline",
|
||||
native_unit_of_measurement=UnitOfTime.MINUTES,
|
||||
getter=lambda status: status.salt_bath_timer,
|
||||
availability_checker=lambda settings, status: status.salt_bath_on
|
||||
@ -86,7 +83,6 @@ SENSORS = (
|
||||
key="fan_timer_remaining",
|
||||
translation_key="fan_timer_remaining",
|
||||
entity_category=EntityCategory.DIAGNOSTIC,
|
||||
icon="mdi:fan-auto",
|
||||
native_unit_of_measurement=UnitOfTime.MINUTES,
|
||||
getter=lambda status: status.fan_timer,
|
||||
availability_checker=lambda settings, status: status.fan_on
|
||||
|
Loading…
x
Reference in New Issue
Block a user