From 3d98bc986b434640d429d22d4e51c525167edcd7 Mon Sep 17 00:00:00 2001 From: abmantis Date: Wed, 16 Jul 2025 15:32:33 +0100 Subject: [PATCH] Move target selector to toplevel; add strings and icons --- homeassistant/components/light/icons.json | 5 +++++ homeassistant/components/light/strings.json | 13 +++++++++++++ homeassistant/components/light/triggers.yaml | 9 +++------ 3 files changed, 21 insertions(+), 6 deletions(-) diff --git a/homeassistant/components/light/icons.json b/homeassistant/components/light/icons.json index 6218c733f4c..18901ea196f 100644 --- a/homeassistant/components/light/icons.json +++ b/homeassistant/components/light/icons.json @@ -22,5 +22,10 @@ "turn_on": { "service": "mdi:lightbulb-on" } + }, + "triggers": { + "state": { + "trigger": "mdi:state-machine" + } } } diff --git a/homeassistant/components/light/strings.json b/homeassistant/components/light/strings.json index 7a53f2569e7..02d3285567f 100644 --- a/homeassistant/components/light/strings.json +++ b/homeassistant/components/light/strings.json @@ -461,5 +461,18 @@ } } } + }, + "triggers": { + "state": { + "name": "State", + "description": "When the state of a light changes, such as turning on or off.", + "description_configured": "When the state of a light changes", + "fields": { + "state": { + "name": "State", + "description": "The state to trigger on." + } + } + } } } diff --git a/homeassistant/components/light/triggers.yaml b/homeassistant/components/light/triggers.yaml index b4dd741986f..e60e7eb2153 100644 --- a/homeassistant/components/light/triggers.yaml +++ b/homeassistant/components/light/triggers.yaml @@ -1,11 +1,8 @@ state: + target: + entity: + domain: light fields: - target: - required: true - selector: - target: - entity: - domain: light state: required: true selector: