mirror of
https://github.com/home-assistant/core.git
synced 2025-07-19 03:07:37 +00:00
Add icon translations to Twinkly (#112328)
This commit is contained in:
parent
bf23672d39
commit
d42dd0114d
9
homeassistant/components/twinkly/icons.json
Normal file
9
homeassistant/components/twinkly/icons.json
Normal file
@ -0,0 +1,9 @@
|
||||
{
|
||||
"entity": {
|
||||
"light": {
|
||||
"light": {
|
||||
"default": "mdi:string-lights"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -66,7 +66,7 @@ class TwinklyLight(LightEntity):
|
||||
|
||||
_attr_has_entity_name = True
|
||||
_attr_name = None
|
||||
_attr_icon = "mdi:string-lights"
|
||||
_attr_translation_key = "light"
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
|
@ -8,7 +8,6 @@
|
||||
'effect_list': list([
|
||||
]),
|
||||
'friendly_name': 'twinkly_test_device_name',
|
||||
'icon': 'mdi:string-lights',
|
||||
'supported_color_modes': list([
|
||||
'brightness',
|
||||
]),
|
||||
|
@ -30,9 +30,6 @@ async def test_initial_state(hass: HomeAssistant) -> None:
|
||||
assert state.state == "on"
|
||||
assert state.attributes[ATTR_BRIGHTNESS] == 26
|
||||
assert state.attributes["friendly_name"] == TEST_NAME
|
||||
assert state.attributes["icon"] == "mdi:string-lights"
|
||||
|
||||
assert entity.original_icon == "mdi:string-lights"
|
||||
|
||||
assert device.name == TEST_NAME
|
||||
assert device.model == TEST_MODEL
|
||||
|
Loading…
x
Reference in New Issue
Block a user