docs(set_leds): note that segment start/length are now optional

The set_leds service handler is already pass-through, so the new
server-side defaults (start=0, length=rest-of-strip) work with no
code change. Refresh the field descriptions in services.yaml and
strings.json so the UI surfaces the simpler {"mode","color"} payload.
This commit is contained in:
2026-04-26 23:45:25 +03:00
parent ca5b0a8014
commit e8f2b5e528
2 changed files with 18 additions and 4 deletions
+5 -3
View File
@@ -11,9 +11,11 @@ set_leds:
segments: segments:
name: Segments name: Segments
description: > description: >
List of segment objects. Each segment has: start (int), length (int), List of segment objects. Each segment has: start (int, optional —
mode ("solid"/"per_pixel"/"gradient"), color ([R,G,B] for solid), defaults to 0), length (int, optional — defaults to the rest of the
colors ([[R,G,B],...] for per_pixel/gradient) strip from start), mode ("solid"/"per_pixel"/"gradient"), color
([R,G,B] for solid), colors ([[R,G,B],...] for per_pixel/gradient).
Example fill-whole-strip: [{"mode": "solid", "color": [255, 0, 0]}].
required: true required: true
selector: selector:
object: object:
+13 -1
View File
@@ -29,6 +29,9 @@
"button": { "button": {
"activate_scene": { "activate_scene": {
"name": "{scene_name}" "name": "{scene_name}"
},
"sync_clock_reset": {
"name": "Reset"
} }
}, },
"light": { "light": {
@@ -39,6 +42,9 @@
"switch": { "switch": {
"processing": { "processing": {
"name": "Processing" "name": "Processing"
},
"sync_clock_running": {
"name": "Running"
} }
}, },
"sensor": { "sensor": {
@@ -56,6 +62,9 @@
}, },
"mapped_lights": { "mapped_lights": {
"name": "Mapped Lights" "name": "Mapped Lights"
},
"sync_clock_elapsed": {
"name": "Elapsed Time"
} }
}, },
"number": { "number": {
@@ -76,6 +85,9 @@
}, },
"api_input_timeout": { "api_input_timeout": {
"name": "Fallback Timeout" "name": "Fallback Timeout"
},
"sync_clock_speed": {
"name": "Speed"
} }
}, },
"select": { "select": {
@@ -106,7 +118,7 @@
}, },
"segments": { "segments": {
"name": "Segments", "name": "Segments",
"description": "List of segment objects with start, length, mode, and color/colors fields." "description": "List of segment objects. start and length are optional (default to 0 and the rest of the strip); mode is one of solid/per_pixel/gradient with color or colors."
} }
} }
} }