Gugul
(Gugul)
September 4, 2022, 7:28am
1
Hi all, I’m noob at yaml. I want to display a timer running in secondary info of the custom template card in mushroom. It shows static time configured in timer, without countdown seconds.
type: custom:mushroom-template-card
primary: Boiler
secondary: |-
{% if is_state('switch.boiler', 'on') %}
{{ state_attr('timer.boiler', 'remaining') }}
{% else %}
OFF
{% endif %}
icon: |-
{% if is_state('switch.boiler', 'on') %}
mdi:water-boiler
{% else %}
mdi:water-boiler-off
{% endif %}
entity: switch.boiler
tap_action:
action: toggle
hold_action:
action: none
double_tap_action:
action: none
icon_color: |-
{% if is_state('switch.boiler', 'on') %}
red
{% endif %}
multiline_secondary: true
Is it possible to see time counting down to know how many time left?
flemmingss
(Flemmingss)
September 18, 2022, 9:21am
2
I am wondering about this myself.
I know this is displaying the set-time:
{{ state_attr("timer.caffe_maker_countdown", "duration") }}
but I have not found a way to show the current time.
It looks like remaining is not remaining, but equal, to duration
flemmingss
(Flemmingss)
September 18, 2022, 5:58pm
3
flemmingss
(Flemmingss)
September 20, 2022, 10:05am
4
3 Likes
Looking exactly for the same solution…
I’ve opened a feature request:
opened 08:25PM - 07 Jun 24 UTC
enhancement
### Requirements
- [X] I have updated Mushroom to the latest available version
… - [X] I did a search to see if there is a similar issue or if a pull request is open.
### Is your feature request related to a problem?
Trying to custom my mushroom-entity card , to show the time left on the timer of my switch.
### Describe the solution you'd like
Something like:
```
type: custom:mushroom-entity-card
entity: switch.toalheiro
name: Toalheiro
tap_action:
action: none
double_tap_action:
action: call-service
service: script.toalheiro_2h
target: {}
icon_color: red
fill_container: false
primary_info: name
secondary_info: {{states("number.toalheiro_timer")}}
```
### Describe alternatives you've considered
found nothing until now...
### Additional context
Better dashboard customization and optimization where I can put the necessary info grouped.