Skip to content

Adding Custom "Off-Type" Icons for State Representation in the Dashboard #785

Answered by rchiileea
Menelao147 asked this question in Q&A
Discussion options

You must be logged in to vote

of type icons end up weighing down the libary and HA will show on and off by icon color change, you could have the icon as normal for in garage, red for out of garage and blue for charge.
iicon section of custom button cardin custom button card

      styles:
          icon: |
                [[[ 
                   if ( device_tracker.ioniq_5_location.state >= home) return 'white';
                   else if (device_tracker.ioniq_5_location.state >= away) return 'red';
                   else if (binary_sensor.ioniq_5_ev_battery_plug >= plugged) return 'blue';
                   else if (sensor.ioniq_5_ev_battery_level >= 100) return 'green';
                   else return 'yellow';
     …

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by rchiileea
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
question Further information is requested
3 participants