Hello guys,
Is there the possibility to COLOR a png entity_picture? I need it to be âvar(âprimary-background-color)â.
Thank you!
Hello guys,
Is there the possibility to COLOR a png entity_picture? I need it to be âvar(âprimary-background-color)â.
Thank you!
Please give us 2-3 examples of COLORED images.
Hello Community,
I am stuck. I would like to embed the mm2-clock.carc (GitHub - shbatm/mm2-clock-card: A Simple Digital/Analog Clock Card for Home Assistant Lovelace) into a a custom button-card.
I´ve tried so many different versions of the code but I cannot seem to find the right way. Could some one point me in the right direction? Maybe there is an even simpler solution which by now I haven´t found.
My main dashboard shows only active devices in my home, all in their own button-card field. all fields are the same size (280x170px).
I would like to show a clock (hour:minute AND counting seconds) plus date and shown weekday.
This is the code generating the date and time:
- platform: time_date
display_options:
- "time"
- "date"
- platform: template
sensors:
startseitenuhr_zeit_und_tag:
value_template: >
{% set x = states('sensor.time') %}
{% set tag = ["Sonntag", "Montag", "Dienstag", "Mittwoch", "Donnerstag", "Freitag", "Samstag"] %}
{{ tag[now().isoweekday()] + now().strftime(", %H:%M")}}
friendly_name: "Aktuelle Zeit"
I will spare you my button-card code :).
Please tell me if my wish is doable.
Thank you.
Greetings from Austria
Chris
EDIT: TyposâŚ
Could someone help me with a extremely simple template that just takes the current temperature from a entity, and places it in the middle of a custom card button, please.
(I know. And Iâve tried to Google and read up on it, but itâs kinda messy with the yaml code and stuff).
Best regards
Hi everyone,
is it possible to define or call up the attributes via state?
I want to change the icon when the roller blind is at 50%.
Or how can I best implement this?
Hi everyone, I had a lot of fun with this component. If you want to see more details here is my post :
because of `Thomasâ post above, I re-visited my search to find a way for a back buttonâŚ
- type: custom:button-card
template: button_shortcut_menu
tooltip: Back
icon: mdi:arrow-left
tap_action:
action: navigate
navigation_path: history.back(-1)
to give you an idea, and "Go Back" Button | CSS-Tricks being the source for that.
looks fine:
@RomRider , would you know of a way to accomplish this âbackâ-button, truly navigating the Lovelace browser history? How can we implement the âhistory.back(-1)â
Would hope it to be doable, since entering it in the inspector command line does exactly that, go back in history 1 step
never noticed before, probably because I have my border-radius set to 0 by default, but on these new âchipsâ I notice a squared pop up background border upon tap:
can I make those use the same border-radius as the chip itself? what would be the correct css option for that please? this is my chip config:
styles:
img_cell:
- width: 24px
card:
- border-radius: 30px
- box-shadow: var(--ha-card-box-shadow)
- height: 36px
- width: auto
- padding-left: 6px
- padding-right: 6px
grid:
- grid-template-areas: '"l"'
label:
- justify-self: center
- padding: 0px 6px
- font-weight: bold
- font-size: 14px
Edit the image with gimp or photoshop and remove the background and make it transparent. Then you wonât need to manipulate the image.
This is not possible. Nothing will count seconds in the UI.
you donât need a template. Just follow the docs and use a temperature sensor as the entity for the card. It will display the state without any crazy template. The regular built in button card does this too.
please can you explain how to have this visualization? copy your code ?
Iâm trying to have this, without success.
Well that code is over 2 years old, so that will probably no longer work. And I have to be honest, I wouldnât really know how I did that. However you can check out my current project and install that instead.
You can find it here: GitHub - jimz011/homekit-infused: Homekit Infused v4.0.0rc
Anyone know if the button card can be used to launch the âmedia browserâ popup dialog for HA ?
(Iâm talking about the one that you see if you click the browse button on the spotify player lovelace card for example)
Iâve been searching a while, but have not managed to find out if itâs possible to open this popup dialog directly⌠iâd like to get the custom button on my dashboard to browse the spotify source.
Hi, anyone know a way to create a color âdotâ that matches the actual color of a light entity? I have seen something like this, but I canât find it anywhere. Kinda like this:
custom_fields:
notification:
- background-color: >
[[[
if (states['input_number.test'].state == 0)
return "green";
return "red";
]]]
But then it should return the color of the entity itâs put in (using button-card templates). Anyone has an idea?
use var(--button-card-light-color)
or --button-card-light-color-no-temperature
?
Thanks! Canât believe I totally missed that basic function.
So this is strange. Perhaps Iâm missing something, or just doesnât work like I intend to. I have a simple button card with a grid style that only shows the name. I defined that the name should always start from left with justify-self: start
. This all works great and has no issues. However, if I use a template in the name field WITH an icon inside that template, itâs centered. For instance:
Is aligned left (working as intended):
name: 'Flows'
name: '[[[ return `Flows` ]]]'
Is centered (not working as intended):
name: '[[[ return `Flows <ha-icon icon="mdi:rotate-right" style=" color: var(--text-color); height: 7%; width: 7%"></ha-icon> ` ]]]'
So I thought, well maybe because I now define a style in the template, itâs back at default. So then I added justify-self: start
to the template style, but same result. I also tried defining the icon style under styles
(eventhough icon is not even in the grid), but itâs always centered.
Can someone help me align the name to the left WITH an icon in the template?
You can combine
styles:
name:
- justify-self: start
- text-align: left
or just use
styles:
name:
- text-align: left
Thank you, this fixes it! Do you know why suddenly it needs text-align
as soon as an icon comes into the template? Just curious as to why it suddenly changes its behaviour.