Is the only way to show an attribute in a glance to extract it using a template sensor?
I have 2 climate entities that are part of a single z wave thermostat. I want to show on my mobile phone the min/max target set temp as well as the actual temperature.
1 Like
tom_l
August 27, 2019, 7:49am
2
In a Glance card?
Yes.
There’s a custom Lovelace attributes card but it shows them as a list.
Attributes card
Attributes are not that popular because they are hidden inside more info dialog and harder to display. This card aims to simplify it for things like package trackers & other sensors that have more attributes to bring those attributes forward on the main page.
[enitty-attributes-card]
[attributes-in-entities]
You can find the code here
Instructions
The instructions are also found on the above repo.
Download entity-attributes-card.js
Place the file in your config/www folder
I…
Yea i have seen that one but not a fan of the table as it looks like an eye sore. Yea i thought that was the only way. OK i will go about it that way and make an template sensor for the attribute.
crguez
(Carlos Rguez)
March 13, 2022, 10:33am
4
Instead of using type ‘- entity: …’ use ‘- type: attribute: …’.
Example:
- type: attribute
icon: mdi:radiator
name: Heater Mode
entity: climate.lyric
attribute: hvac_action
Result:
The only limitation is that it cannot be used with visual editor.
2 Likes
tom_l
March 13, 2022, 11:04am
5
That was not available three years ago .
And it is still not valid now. Glance cards do not support attributes. What you are showing is the state.
1 Like
I know this post is old, but I came here from a google and it gave me insight into how to achieve it with what I had available which was the stack-in-card
(GitHub - custom-cards/stack-in-card: 🛠 group multiple cards into one card without the borders ) HACS addon,
With this I was able to use:
type: custom:stack-in-card
title: Electric Prices
mode: horizontal
cards:
- type: horizontal-stack
cards:
- type: entity
entity: sensor.octopus_agile_prices
attribute: import
name: Price Now
unit: p
icon: mdi:currency-gbp
- type: entity
entity: sensor.octopus_agile_prices
attribute: import_next
name: Price Next
unit: p
icon: mdi:currency-gbp
To achieve what I wanted, Now and Next electric unit prices next to each other from attributes of a sensor.