Skip to content

Commit 0cfc94f

Browse files
authored
filter out part of string after @
List names when using soundreactive fork introduces artifacts where `@` followed with some variables are added to the name
1 parent 2122772 commit 0cfc94f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

custom_components/ui_lovelace_minimalist/lovelace/ulm_templates/popup_templates/popup_layouts/popup_light_effect_row.yaml

+2-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@ popup_light_effect_row:
33
template: "popup_row_layout"
44
name: >
55
[[[
6-
var name = entity.attributes.effect_list[variables.ulm_popup_light_effect_entity_idx];
6+
var attribute = entity.attributes.effect_list[variables.ulm_popup_light_effect_entity_idx].toString()
7+
var name = (attribute.includes("@") >= 1) ? attribute.substr(0, attribute.indexOf("@")) : attribute;
78
return name;
89
]]]
910
state:

0 commit comments

Comments
 (0)