Icon color difference
See original GitHub issueChecklist
- [x ] I updated the card to the latest version available
- [ x] I cleared the cache of my browser
Describe the bug A clear and concise description of what the bug is. I have 2 cards, but both Icon color are different
The icon of the first button gets the color from --paper-item-icon-color The secon one from --primary-text-color
Do I have any errors in my configuration? Tried a lot of configurations, but always behaved the same for me
Version of the card Version: 3.0.0
To Reproduce This is the configuration I used:
- color_type: icon
entity: variable.washingmachine_running
name: Waschmaschine
state:
- icon: 'mdi:washing-machine'
operator: default
- icon: 'mdi:washing-machine'
value: 'on'
tap_action:
action: more-info
type: 'custom:button-card'
- aspect_ratio: 1.68/1
icon: 'mdi:flash'
color_type: icon
entity: sensor.washingmachine_current_consumption
name: |
[[[
if (states["variable.washingmachine_running"].state == "on") return (states["sensor.washingmachine_current_consumption"].state + ' W');
else return states["variable.washingmachine_last_consumption"].state + ' kWh';
]]]
tap_action:
action: more-info
type: 'custom:button-card'
Screenshots If applicable, add screenshots to help explain your problem.
Expected behavior Icon color should be the same for both buttons
Desktop (please complete the following information):
- Chrome
- Version 79.0.3945.88
Additional context
Issue Analytics
- State:
- Created 4 years ago
- Comments:5
Top Results From Across the Web
Which Color Should You Use For Your Icon?
Standing out in a sea of blue: Which color should you pick for your icon? · Red · Orange · Yellow · Green...
Read more >Compare icon in Color Style
Download Compare vector icon in Color style. Available in png, svg, pdf, html code. Modify, resize, recolor Compare icon.
Read more >Choosing best colours for your next icon set
Depending on the style of your icons you can decide to make them monochromatic, use the shades of the same colour, or choose...
Read more >Word: Working with Icons - GCFGlobal
Icons are a library of modern, professional graphics included with Office 365 and ... To change the color of an icon, select the...
Read more >How to style icon color, size, and shadow of FontAwesome ...
For example, FontAwesome's site will show some icons in white and some in red but won't show the CSS for how to style...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
You have the same behaviour with the core button card as far as I know. This is why I did it like this in the first place. But I think it’s written in the documentation: https://github.com/custom-cards/button-card/blob/master/README.md#main-options in the
color
parameterGuess that will fix it, but at least for me this seems a bit inconsistent and confusing. As its not stated anywhere (at least where if found) And also, I dont see why the Icon should have --primary-text-color, as its obviously not a text I’ll close. Thanks for the great work anyway.