diff --git a/homeassistant/components/demo/fan.py b/homeassistant/components/demo/fan.py index 73cae4a64b1..644c4cb7860 100644 --- a/homeassistant/components/demo/fan.py +++ b/homeassistant/components/demo/fan.py @@ -90,6 +90,7 @@ class BaseDemoFan(FanEntity): """A demonstration fan component that uses legacy fan speeds.""" _attr_should_poll = False + _attr_translation_key = "demo" def __init__( self, diff --git a/homeassistant/components/demo/icons.json b/homeassistant/components/demo/icons.json index 79c18bc0a2e..9c746c633d4 100644 --- a/homeassistant/components/demo/icons.json +++ b/homeassistant/components/demo/icons.json @@ -23,6 +23,21 @@ } } }, + "fan": { + "demo": { + "state_attributes": { + "preset_mode": { + "default": "mdi:circle-medium", + "state": { + "auto": "mdi:fan-auto", + "sleep": "mdi:bed", + "smart": "mdi:brain", + "on": "mdi:power" + } + } + } + } + }, "number": { "volume": { "default": "mdi:volume-high" diff --git a/homeassistant/components/demo/strings.json b/homeassistant/components/demo/strings.json index 555760a5af9..aa5554e9fcc 100644 --- a/homeassistant/components/demo/strings.json +++ b/homeassistant/components/demo/strings.json @@ -46,6 +46,20 @@ } } }, + "fan": { + "demo": { + "state_attributes": { + "preset_mode": { + "state": { + "auto": "[%key:component::climate::entity_component::_::state_attributes::fan_mode::state::auto%]", + "sleep": "[%key:component::climate::entity_component::_::state_attributes::preset_mode::state::sleep%]", + "smart": "Smart", + "on": "[%key:common::state::on%]" + } + } + } + } + }, "event": { "push": { "state_attributes": { diff --git a/homeassistant/components/fan/icons.json b/homeassistant/components/fan/icons.json index ebc4988e87f..f962d1e7c1a 100644 --- a/homeassistant/components/fan/icons.json +++ b/homeassistant/components/fan/icons.json @@ -11,6 +11,10 @@ "state": { "reverse": "mdi:rotate-left" } + }, + "preset_mode": { + "default": "mdi:circle-medium", + "state": {} } } }