Open ildar170975 opened 1 year ago
A similar synthetic case:
- type: custom:template-entity-row
entity: sun.sun
icon: '{{ "phu:roborock" }}'
works unstable too.
Same with Font Awesome icons from https://github.com/thomasloven/hass-fontawesome this works:
- type: custom:template-entity-row
entity: sun.sun
icon: fas:heart
this is unstable:
- type: custom:template-entity-row
entity: sun.sun
icon: '{{"fas:heart"}}'
as this is unstable too:
- type: custom:template-entity-row
entity: sun.sun
icon: '{{"state_attr(.....,'icon')"}}'
if a custom icon set for this entity.
There is a custom "phu" icon from this package: https://github.com/elax46/custom-brand-icons
The package is installed via HACS & declared here too:
The icon is used to customize some entity and is displayed persistently in Lovelace. But it may NOT be displayed when used in
template-entity-row
.Consider this code:
The icon is
phu:roborock
, the customized entity isdevice_tracker.xiaomi_roborock_s5
. In the code above the icon is supposed to be displayed: -- Line 1: as an icon of an entity; -- Line 2: as an explicitly defined icon (icon: xxxx
); -- Line 3: as an icon taken from an attribute (state_attr(xxx,'icon')
). -- Line 4: here a different MDI icon is taken from an attribute of another entity (to demonstrate that usingstate_attr()
works).Here is how it should be displayed:![image](https://user-images.githubusercontent.com/71872483/202699772-76652f01-b8e9-42a6-9eba-b0d324321f89.png)
But this custom "phu" icon is usually displayed in Editor window only - if defined using![image](https://user-images.githubusercontent.com/71872483/202700790-6ffaedd6-ad6c-4533-b483-58c64340bd75.png)
state_attr()
:Sometimes the icon displayed on the dashboard too:
But after pressing F5 is disappeared again.
Win 10x64, Chrome (observed in iOS companion app too) 2022.11.3 latest
template-entity-row
(1.3.0)