Thnx @BebeMischa! I appreciate it
@C.G.B.Spender
I understand your ocd, suffer myself as well.
Try the active state for the color;
icon:
template:
styles: >
if (entity.state > 35) return
'color:var(--paper-item-icon-active-color)';
Check out version 1.07.01 this will fix the icon color updating
@marcokreeft87 Will do when I get home work, cheers!
@GH2user I recently found the gold
color is the yellow that the ha theme uses, but your suggestion has the added benefit of working with every theme I believe, Iāll be implementing that, thanks!
1.07.01 works great, the media player icon now changes colors consistently with the player state. Many thanks once again!
question about marigin - how to make it smaller ?
I would like to make margin smaller on topā¦
I figured out that for header I can do it something like this - and is`t working
style: |
.card-header {font-size: 130%; padding-top: 0px;}
but how to make it the same for entity-info ?
thanks in advance !
The entity row has its own CSS domain. Hereās an example of some changes I made to mine:
.entities-info-row {
padding: 0px;
right: -10px;
top: 0px;
}
Ive already try this but doesn
t work
type: custom:room-card
title: Julia
style: |
.card-header {font-size: 130%; padding-top: 0px;}
.entities-info-row {
padding: 50px;
right: 50px;
top: 50px;}
I`ve also try without header modification:
style: |
.entities-info-row {
padding: 50px;
right: 50px;
top: 50px;}
here is my whole code - maybe I`m doing something wrong ?
type: custom:room-card
title: Julia
style: |
.card-header {font-size: 130%; padding-top: 0px;}
.entities-info-row {
padding: 50px;
right: 50px;
top: 50px;}
entity: group.julia
icon: mdi:string-lights
state_color: true
show_icon: null
tap_action:
action: toggle
entities:
- entity: light.julia_1
name: sufit
show_icon: true
tap_action:
action: toggle
- entity: light.juliawall
name: nocna
show_icon: true
tap_action:
action: toggle
info_entities:
- entity: switch.gniazdka_tv_julia
show_icon: true
state_color: true
icon: mdi:google-home
tap_action:
action: toggle
styles:
width: 20px
You need to use styles, not style. Style is an config attribute for card-mod.
It also expects an object, so like this:
styles: >
color: green
thanks but as I trying this there is no option to make margin smallerā¦ I try use with different options etc -no one workingā¦ can you help to find correct syntax for margin smaller ?
as you can see that works for header ā¦ so basically should also works if I know what should be in place ā.card-headerā and should worksā¦ of course should be ā.entities-info-rowā but doesn`t work
type: custom:room-card
title: Oliwia
style: |
.card-header {
font-size: 130%;
padding-top: 0px;}
I even try to use div for all arrea
div {
margin: -5px;
padding-top: 0px;
}
but that make a mess for other areasā¦ so I try to modify all I can believe that
s the only one optionsā¦
.entities-info-row {
padding: 10px;
right: 10px;
top: 50px;
}
div {
margin: -10px 0px 0px 0px;
padding-top: 0px;
}
.entities-row .entity {
padding-top: 20px;
margin-left: 0px;
}
.entity {
padding-top: 10px;
margin-left: 0px;
}
.card-header {
font-size: 150%;
padding-top: 20px
}
but looks like ā.entities-info-rowā doesn`t work at all ā¦
Hello,
Iām using Room Card, I really like it!
However, this error often occurs:
Cannot read properties of undefined (reading āstyleā)
It occurs both in the browser, and in the Android app and iOS appā¦
Does it happen to anyone else?
If I keep refreshing the page (F5) or closing and opening the app again, it solvesā¦ but itās something that gets in the way of using itā¦
you need to manually delete the browser cache on desktop and reload the page (have to do this each time you install/update lovelace card from hacs)
on android you need to go to apps/home assistant/force close/data/clear cache/restart app
on iphone I have no idea
Yeah weird right. HACS used to do it for you but not since the last big update
Hello and many thanks for this card. Iāve looked for something like this since days. But iām not sure, if i found a bug or if i am missing something. Please have a look at this screenshot:
Two aspects:
-
The toggle switch does not appear, neither for the switch-domain nor does it show for climate devices. I suppose the setting is completely ignored. Or am i doing something wrong?
-
Attributes would also not be shown.
Could you plz check if these are bugs? Thank you in advance.
Iām running into a weird problem. My room cards are working perfectly on the mobile app, but throwing an error in Chrome, claiming that the custom element āhorizontal-stackā doesnāt exist. When I created the cards an hour ago they displayed properly, then suddenly decided to quit. Hereās the code for one of the cards:
type: custom:room-card
title: Guest Room
entity: light.guest_bedroom_ceiling_fixture
icon: mdi:ceiling-fan-light
show_icon: true
tap_action:
action: toggle
cards:
- type: horizontal-stack
cards:
- show_name: true
show_icon: true
type: button
tap_action:
action: toggle
entity: scene.guest_bedroom_off
name: 'Off'
show_state: false
icon_height: 20px
- show_name: true
show_icon: true
type: button
tap_action:
action: toggle
entity: scene.guest_bedroom_bright
name: Bright
icon_height: 20px
Iāve tried clearing the cache and cookies in Chrome, restarting the browser, no luck. It works fine in the mobile app, but not in Chrome. Not in mobile Chrome using the nabu casa link either.
Any idea whatās going on?
And now I changed one of the horizontal stack cards to a grid, which works fine. But as soon as I saved that change, all the other cards are magically fixed, displaying their horizontal stacks properly again.
This has to be a bug in the Room Card, right?
- You are right. But this is not a bug. I just copied too much in the wiki
- Attributes are not shown by the card, thats correct
Some of the default cards arent supported by room card.
But why are you using a horizontal card in room card? The entities are displayed horizontalā¦
I wanted some separation between two lists: individual lights displayed within the main room card, and scene buttons below using the horizontal stack. It was an aesthetic preference, and I was hoping to keep all of it within a single card for each room. Hereās what Iām targeting:
I got this working with the grid card instead of the horizontal stack. It seems to be a workable alternative so far.
You can use rows in room card. That might be what you are looking for