diff --git a/apps/nspanel-lovelace-ui/luibackend/pages.py b/apps/nspanel-lovelace-ui/luibackend/pages.py index 71e28e5c..f129e348 100644 --- a/apps/nspanel-lovelace-ui/luibackend/pages.py +++ b/apps/nspanel-lovelace-ui/luibackend/pages.py @@ -215,7 +215,7 @@ class LuiPagesGen(object): device_class = entity.attributes.get("device_class", "") unit_of_measurement = entity.attributes.get("unit_of_measurement", "") value = entity.state + " " + unit_of_measurement - if cardType == "cardGrid": + if cardType == "cardGrid" and entityType == "sensor": icon_id = entity.state[:4] if icon_id[-1] == ".": icon_id = icon_id[:-1]