From f9cc24262ccc7930a14343cd0a13dfc45e62816d Mon Sep 17 00:00:00 2001 From: fringefilmsoz Date: Sat, 27 Nov 2021 01:37:34 +1000 Subject: [PATCH] Spelling. Loops notation (#1626) * Spelling. Loops notation Corrected error in spelling of fragments (from fragements). Changed notation of state of item in a loop to: items[loop.item.name].state (was loop.item.state). This will ensure items update state with state changes. Signed-off-by: fringefilmsoz --- tutorials/getting_started/custom_widgets.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tutorials/getting_started/custom_widgets.md b/tutorials/getting_started/custom_widgets.md index b9988030e..03221831b 100644 --- a/tutorials/getting_started/custom_widgets.md +++ b/tutorials/getting_started/custom_widgets.md @@ -372,7 +372,7 @@ slots: default: - component: oh-repeater config: - fragement: true + fragment: true for: item sourceType: itemsWithTags itemTags: Switch,Light @@ -382,8 +382,8 @@ slots: - component: oh-toggle-item config: icon: f7:lightbulb - iconColor: '=(loop.item.state == "ON") ? "yellow" : "gray"' - color: '=(loop.item.state == "ON") ? "yellow" : "gray"' + iconColor: '=(items[loop.item.name].state == "ON") ? "yellow" : "gray"' + color: '=(items[loop.item.name].state == "ON") ? "yellow" : "gray"' title: =loop.item.label item: =loop.item.name ```