Bubble-Card icon indicating copy to clipboard operation
Bubble-Card copied to clipboard

Light Entity Icon Color

Open joshuazd opened this issue 1 year ago β€’ 66 comments

Describe the bug
The icon color of light entities is hard coded in the card when the light is on, instead of using variables. Additionally, the icon background is handled in a way that makes the icon hard to see when using a light theme and --ha-card-background is close to white.

To Reproduce
Steps to reproduce the behavior:

  1. Use a theme with a light mode (the default Home Assistant theme works)
  2. Create a bubble card for a light
  3. Turn the light on

Expected behavior
The icon should respect the --state-light-active-color variable. I think the fallback order the tile card uses is --state-light-on-color -> --state-light-active-color -> --state-active-color. Handle the color of the icon background so that the icon is more visible

Screenshots
Current state: Screenshot 2024-08-08 at 13 05 52

Tile card example: Screenshot 2024-08-08 at 13 04 15

Informations (please complete the following information):

  • OS: macOS/Windows 11/Android 14
  • Browser/App: Firefox/HA Android app
  • Bubble Card version: 2.1.1
  • Home Assistant version: 2024.7.4

Thank you! 🍻

joshuazd avatar Aug 08 '24 18:08 joshuazd

+1. Also, the Card background doesn’t always reflect the actual Light colour, so this can be confusing and unreadable at times.

ncodee avatar Aug 21 '24 20:08 ncodee

+1 I confirm the issue image

samuel9554 avatar Aug 27 '24 00:08 samuel9554

Did you solve it please

Ya7ya-mohammed avatar Sep 14 '24 23:09 Ya7ya-mohammed

Same here - noticing that in styling sub buttons can't get the state active color

a-bianucci avatar Sep 24 '24 13:09 a-bianucci

Hi! I've added this issue to my to-do list. I'm working on a really complex issue (the editor slowness on some configs) but I hope it will be fixed soon so that I can move on to other ones 🀞

Clooos avatar Sep 24 '24 14:09 Clooos

+1, hoping this will be fixed soon, thanks.

oerix avatar Oct 19 '24 18:10 oerix

+1, this would be great

giuseppebaldi avatar Nov 19 '24 01:11 giuseppebaldi

@Clooos Sorry for nudge, but could this annoying issue be prioritised higher please? thanks

oerix avatar Nov 19 '24 14:11 oerix

+1!!!

DavidinoX avatar Nov 19 '24 14:11 DavidinoX

Wow, I guess that this one will be my priority indeed, sorry for that everyone! I will do my best to fix that in the next release!

Clooos avatar Nov 19 '24 14:11 Clooos

You're amazing, I have rarely seen a developer who is so reactive. What you did is already fantastic!!! Thank you again

biva avatar Nov 19 '24 14:11 biva

Here what a white light slider will looks like in the next release on a light theme, what do you think everyone?

image

And I'm sorry again, I don't use a light theme, that's why I forgot about that one πŸ˜…

Clooos avatar Nov 19 '24 17:11 Clooos

I think that looks great, thank you!

giuseppebaldi avatar Nov 19 '24 18:11 giuseppebaldi

Hi, I think it looks good indeed, but why not the full orange, like the others? On the picture below, even on a dark theme, why not the same color for lights and other sliders? image

biva avatar Nov 19 '24 19:11 biva

Hi, I think it looks good indeed, but why not the full orange, like the others? On the picture below, even on a dark theme, why not the same color for lights and other sliders? image

This! I would also use the same orange tint

DavidinoX avatar Nov 19 '24 19:11 DavidinoX

@biva @DavidinoX don't you think that it is best to differentiate lights to other entities?

I think we should start a poll here, it's a serious breaking change for everyone who is used to the previous color πŸ˜…

Tell me your opinion everyone πŸ™‚

Clooos avatar Nov 19 '24 21:11 Clooos

Personally, it's not important to me that lights and slider entities are the same color, especially if it's a major, branding change.

giuseppebaldi avatar Nov 19 '24 21:11 giuseppebaldi

Both are fine for me, as long as the colour for lights is darker (deeper)

biva avatar Nov 19 '24 21:11 biva

I like it, especially if the background color matches the theme.

Ultimately if this is the default this is perfect, and if you could leverage the variables mentioned above to override if you wanted to, even more perfect!

a-bianucci avatar Nov 19 '24 21:11 a-bianucci

Either are fine actually :)

DavidinoX avatar Nov 19 '24 21:11 DavidinoX

I've already added variables that can be edited directly in the theme, this way it will be really easy to replace the color I've defined. I will let it like that then πŸ™‚

Once the v2.3.0 will be over, I will document every available variables πŸ‘Œ

Clooos avatar Nov 19 '24 22:11 Clooos

The new beta is here, and it should looks way better on light/bright themes! 🀞

https://github.com/Clooos/Bubble-Card/releases/tag/v2.3.0-beta.8

Clooos avatar Nov 21 '24 16:11 Clooos

The new beta is here, and it should looks way better on light/bright themes! 🀞

https://github.com/Clooos/Bubble-Card/releases/tag/v2.3.0-beta.8

Thanks, that fixed icon being visible. However light state colour still isn't reflected, and has become much worse.

Bubble Button Switch: Screenshot 2024-11-21 at 16 53 09

Actual light temperature: Screenshot 2024-11-21 at 16 53 43

oerix avatar Nov 21 '24 16:11 oerix

Well indeed, the issue here is that if I set it to the real color, the text inside the cards will not be visible anymore. But I can indeed change that default color to something less warm.

Clooos avatar Nov 21 '24 17:11 Clooos

Well indeed, the issue here is that if I set it to the real color, the text inside the cards will not be visible anymore. But I can indeed change that default color to something less warm.

Text still looks visible to me using the same colour. I see the default background opacity is 0.5 if I'm not mistaken, maybe reduce it for more whiter hues, or use text/box shadows that are adaptable? Another possible option, is for a toggle to enable background gradient like for media_player but for lights, however I believe you're not a fan of it.

Screenshot 2024-11-21 at 17 23 34

oerix avatar Nov 21 '24 17:11 oerix

I will change this, this was a mistake, I wanted to only change that for light themes. I will change that in the next release.

Clooos avatar Nov 21 '24 17:11 Clooos

This should now be perfect on both light and dark themes. To install this version, you need to remove Bubble Card from HACS first, then install it with the "Without HACS" method. Once installed, don't forget to clear your cache.

bubble-card.js.zip

Clooos avatar Nov 21 '24 17:11 Clooos

Hello, I updated to the latest version but all bubbles (icon and background) are grey by default IMG_1260

DavidinoX avatar Dec 01 '24 20:12 DavidinoX

I don't have this issue, here's how it looks on mine with a light theme and some lights that are turned on.

Screenshot_2024-12-01-22-02-28-407_io homeassistant companion android

Clooos avatar Dec 01 '24 21:12 Clooos

For the record, downgrading to beta-8 changes colors to this. Sub buttons colors are still weird. Might be some other plugin conflicting? I have no idea πŸ˜”πŸ˜”

IMG_1261

DavidinoX avatar Dec 01 '24 21:12 DavidinoX