#frontend-archived
1 messages · Page 13 of 1
Still from that button i can’t click the differnet things right? Is just a unique button so unique interaction
right
Is just a way to display multiple information
so that's when you'd want to nest
Exactly, i need a mix of the two
sorry, afk
is this the code that was causing the issue?
I couldn't reproduce it even on phone it renders in an instant (even with 9x copies of the card)
(althou it looks weird a bit like some borders are still there and probably shouldn't be)
🤷♂️
I'm going through my config and I only have 1 nested button card
which I built specifically for a separated tap action
lol it looks like I removed all examples that would help you Steel
crap
Yes i tested several time yesterday.
the example I do have heavily uses lovelace_gen
This is an entities card
and colors at the bottom are custom button cards
bah, sorry, I don't have any good examples
Okay, you can only stack vertically with entities right?
no, you can put horizontal stacks in there
you can literally put any card in an entities row
tbh, vertical-stack can be easier, if you stack mostly non-entities cards
especially when embedding custom:button-card, the modding is just a bit easier
Hey i noticed that there is a halo around white. Is because is last clicked or match current state? How did you make that logic?
and embedding a horizontal-stack inside a vertical-stack is what it's designed for , so yes, easy too
Yes then i need remove all backgrounds and apply a unique background and shadow
that's a dropshadow box-shadow style
Basically doing same stack-in-card does
type: custom:multiple-entity-row
secondary_info:
attribute:
- ip
show_state: false
state_color: true
entities:
- attribute: connection_type
name: Connection
- attribute: {{ "1" }}
name: Uptime
stack-in-card basically does:```
type: custom:mod-card
card_mod:
style: |
:host {
--stack-card-margin: 0px;
}
card:
type: vertical-stack
Is this possible to achive?
So instead of taking the attribute value i want to template it? Its not a template question since i know how to do the template however is it possible to use template here?
Awesome. Also removes background right?
or - type: custom:mod-card card_mod: style: | :host { --grid-card-gap: 0px; } card: type: grid for a grid card
not sure there, but you could probably add that to the mod too, maybe even to the 'ha-card' the mod-card adds.
Multiple Entity Row does not support templates.
You need to put it into Button Card / Config Template Card or smh that does.
And even then You cannot overwrite generated state.
But you can generate whole static string "name: value" since Multiple Entity Row supports it.
Cool. I will try tonight this looks good for replacing my need when i need multiple button to click entities, then instead i can work with petro example just for displaying information
@fiery ledge I converted your message into a file since it's above 15 lines :+1:
heck, sorry there
@haughty vine so you noticed no performance issue with my code? That’s weird tho.
Any developer tool to check better what slows down?
nope. As @tacit cave stated there is some overtly complex stacking but I would not expect that kind of performance issues that You shown in the video from this
I sus there might be something else.
None JS errors in the console ?
there won't be any errors for something like that
Beside testing new code that surely can be better, can i scout old code with console to get more understanding if issue is mitigated but rooutcaused elswere?
You can, but you'll have to figure out how to do that yourself
This 3 top elementa were the slowest, around 300ms each
Ok.... i was trying config template just before you wrote and starting to understand why i cant get my text into the attribute..... could you avaluate further on the name:value approach you lost me there
the button card hasn't ever been 'optimized'
there is this general concept of templates being evaluated in the backend server (Jinja in yaml configs) vs those evaluated in the Frontend browser. Depending on your hardware, that can make a lot of difference. Nowadays people tend to throw everything in the frontend, and even using auto-entities and config-template-card at that. It can be overwhelming for the Frontend device
combine those with screen size dependent layouts (state-switch, layout card etc) and you get the drift
yeah, but it only works with secondary_info field
type: custom:multiple-entity-row
entity: sun.sun
secondary_info: |-
[[[ "attribute: " + value_from_template ]]]
entities: []
I don't think you can render arbitrary state value in entities: [] section besides custom names and units
(You can render standalone icons thou)
And can i write my dashboard to load more one side or another?
I have a nas and surely hands better workload that my ipad or iphone
well, yeah, sure. what I mean is, you can have this backend template
or, have a mushroom template card figure it out in the frontend. Or, have that as a css template in button card.
while you could also set the color of the card to use that template sensors state
Thanks a lot you really helped me out....
it all adds up, a single card wont be noticed, but several of those layout cards, with a config-template, and be assured to see bigger delays than in your screenmovie
maybe you also have some history using graph cards on that same view...? I have a few of those, and they are way slower than other views
Hmmm...
v1 or v2 ?
(or anything else to fill the rather empty binary_sensor tiles?)
Hi all, I'm trying to resize the icons in my picture-element card and its not working. Can some one take a look and tell me what I'm doing wrong please.
entity: switch.basement_wall_switch
icon: mdi:led-strip
class: light
title: Basement Light
tap_action:
action: toggle
style:
top: 49%
left: 45%
width: 30%
'-- iron-icon-fill-color': '#11AB7D'
'-- iron-icon-height': 190px
'-- iron-icon-width': 190px```
hey there, i am trying some test about the today discussion. I can get similar result compared to stack-in-card but still if i remove the roundess border i also remove from the outside ones
here
here with round borders
this is the goal, only round outside
what's the trick with card_mod only changing inside roundness?
@fiery ledge
well as far as i see there are always several ways to reach frontend results, and i am sure i can accept compromises of any sorta. What i can't accept is to compromise usability and performance and either because of hardware or because of what i need to display it's time for me to optimize the frontend load of my code
i feel button card and some CSS coding on it the most flexible tool i've found, but any tips for frontload performance is well accepted
i also use some javascript inside the button to go beyond standard options for state or reference to other entities, not sure if this also is not helping.
This is all empty but these cards, quite fast but still from iphone SE 3rd gen see a delay in loading stack-in-card and also card mod on the weather that remove background and reduce margin gap between wind/sun/rain and the weather card
I found it - instead of --iron-icon-width use --mdc-icon--size: 10%
@native anchor I converted your message into a file since it's above 15 lines :+1:
@native anchor let me get this straight ... you wanna completely opaque yellow (but not icon itself) circle around icon normally
but it gets transparent yellow when hover?
thats not gonna look like mushroom / tile icon at all
Something like that! Or really, I mainly just want to find where the control for it is. They're train lines, so it might look best to do opaque, or it might not. If that changes the question though, disregard it 🙂
type: entities
title: BART
entities:
- type: conditional
conditions:
- entity: sensor.antioch
state_not: unknown
row:
entity: sensor.antioch
card_mod:
style:
':first-child$':
hui-generic-entity-row$: |
state-badge { background: #ffff00; }
state-badge:hover, state-badge:active { background: #ffff0033; }
just to add my 3 cents... conditional rows often breaks card_mod styles when row is initially hidden
at least 4 me
@opal jay I converted your message into a file since it's above 15 lines :+1:
does anyone know how to remove the borders with this card?
must confess I havent found that yet.. Ive also tried it with```
- type: custom:mod-card
card_mod:
style: |
:host {
--stack-card-margin: 0px;
--ha-card-border-radius: 12px;
}
card:
type: horizontal-stack
this works though
hide the overflow (and I did embed it in an additional entities card
didnt you try the obvious in button-card: ```
- border: none
? or its mushroom variant ofc. Or set it globally in your theme with
ha-card-border-width: 0px```
Hey! No problem, at the moment best result was to still use a button-card as external container with shadow and then use card-mod as a replacement of stack-in-card exploiting horizontal and vertical stack
With this setup is WAY faster! And thanks to you ❤️
Okay cool i’ll take a look if can further improve. Question: what is the actual shadowing template of that screenshot? I really like the depth effect of shadowing i see there can you share it?
This
I use this in my themes:```
ha-card-border-radius: 0px
ha-card-border-width: 0px
ha-dialog-border-radius: var(--ha-card-border-radius)
dialog-content-padding: 8px 16px 16px 16px
ha-card-box-shadow: 0 4px 8px 0 rgba(0,0,0,0.2), 0 6px 20px 0 rgba(0,0,0,0.19)
btw, if you share yaml, please do so in a code block formatted with the <> in the toolbar. we can not decipher those screenshots ..... nor copy from them
@earnest plover I converted your message into a file since it's above 15 lines :+1:
Hello guys! Started to make a room card for my dashboard and I'm struggling with the alignment of the icons.
Does anybody know how to do that?
I'd like to be able to do alignments like (start, justify, end and center)
All the cards are Mushroom Template cards and I'm using stack-in-card to combine them and card-mod to style (remove borders, background and etc...)
you might be best served by posting in https://community.home-assistant.io/t/mushroom-cards-build-a-beautiful-dashboard-easily/, where all Mushroom expertise is hangin out 😉
I don't think the problem is related to mushroom cards at all
how are you placing the buttons at the bottom
I think It's gonna be related to card-mod in this case
let's me get the code for you
if you're using a horizontal-stack, that's what's spacing your cards
using stack-in-card (but there is no native option for alignment) so I'm trying to do it with card-mod
I was able to change the icons sizes and background
that's the thing, you can put any stack in it
but I'm struggling with the alignment
gonna try now
stack in accepts any card, so you can use a position card to orient things the way you want to orient them
I'm not able to align them with Grid card or Horizontal stack
put blank cards in the grid and you can align it
like custom button card with nothing added to it
not sure if frontend, but using picture glance in 'live' mode with my nest doorbell (wired gen2) and the card plays the live video but stops playing after a length of time. clicking on it always brings up the live stream as it seems to re-establish the connection. not sure what to do
Is there a way to switch the view automatically?
I.e. I would like to change the displayed view on the Ipad with a trigger.
i have a problem where my frontend looks like this on every pc: (note i zoomed out to make it viewable at full)
for some reason the cards dont align themselves automatically
(theme is masonry(default) not layout-card)
@ me if you have any idea on what i could do, none of the cards are in a stack
If I had to guess the custom thermostat cards are not declaring their size correctly. If you replace them with the stock thermostat, does it work correctly?
Thank you Petro !
Hey guys!
I was wondering if someone could help me, is there a way to make Custom mushroom chip cards bigger I find them quite tiny.
I tried google but i am just not able to figure out how to make the code work, I am pretty new in Home assistant, but I can find my way in the GUI, just the yaml code I am struggling with.
I have tried
Width: and height:
the style command, and i believe it was icon_height.
I wasn't sure where to post this my apologies if i posted in the wrong channel 🙂
@half ore I converted your message into a file since it's above 15 lines :+1:
still had to figure out how to create a block in discord 😅
Nevermind figured it ouy had to add:
style: |
ha-card {
--chip-height: 50px;
}
I'm trying to use images as title backgrounds in my frontend. (using card-mod on markdown cards).
style: |
ha-card {
background: url('/local/kantoor.jpg');
This works now on my pc but the mobile app doesn't seem to load the image, what could go wrong here?
I've tried restarting the phone and HA app, no succes. Phone is connected to local network just like the pc.
Seems like a local path is not working on mobile?? When uploading the image to imgur and using that as a url it works on mobile & desktop.
Edit: when using a picture elements card the local path works fine on both desktop and mobile. No idea why it's not working with card-mod.
good evening everyone,
i hope you're all fine?
can someone please help me with button-card?
from here: https://github.com/custom-cards/button-card#merging-state-by-id or via HACS
where do i have to put this:
- url: /hacsfiles/button-card/button-card.js
type: module```
the manual said:
Add the configuration to your ui-lovelace.yaml
but i'm unsure because 1st: i didn't seeh this file and 2nd: many sources said "do not touch this file"
@willow turtle Settings -> Dashboards -> menu top right -> sources
hello werra,
there is no menu on the top right...
@half ore I converted your message into a file since it's above 15 lines :+1:
@winter blade do you mean dashboard -> 3 dots -> edit dashboard -> 3 dots -> raw...?
Can anyone help me with some yaml code?
I am trying to get the battery icon in the same card as my person card.
I have been using google to find some code but i cant seem to figure it out.
type: custom:stack-in-card
mode: vertical
cards:
- type: custom:mushroom-person-card
entity: person.name
layout: horizontal
icon_type: entity-picture
- type: custom:mushroom-chips-card
chips:
- type: entity
entity: sensor.fold3_battery_level
alignment: center
I hope someone could help me with a solution, would really appreciate it been going at it for 2 hours now.
@willow turtle Ahh, than you probably need to enable advanced mode. Go to your profile settings and enable it.
That should give you the 3 dot menu in the top right
ah, i worked as admin, not as owner
@winter blade looks good so far. the examples are working.
thank you for this
i' now unsure where to add this:
https://deebot.readthedocs.io/integrations/home-assistant/examples/ui/advanced/#ui-configuration
it works 🥳
i go to raw-edit and put it at the start
thank you for all
good night
I've only recently (yeah, shh, I know) discovered custom:gap-card (included in layout-card) and replaced 99.9% of my empty button cards with those... save yet another line in the yaml, or extra anchors
just checked for you, but this does in fact work as expected:```
card_mod:
style: |
ha-card {
background: url('/local/images/balloons.png');
background-size: contain;
background-repeat: no-repeat;
}
if its only on mobile: these have nasty caches that can be a bit hard to refresh. New imaes dont always show up immediately, so be sure to close and restart the app, if must, force refresh in the settings
Thanks so much! Trying that today
Any way to make a "cover.xxx" entity show up as a "binary_sensor.xxx"
annoys me that these icons look different
or better yet... is there a way to make "Badges" change based on the state of the entity?
is there any way of getting the value 24.7 and showing that as a card on a dashboard?
Yes that would be the current_temperature attribute of the climate object. There are many ways you could display that. You can display it in an Entity card, by selecting the climate entity, with attribute selector set to current_temperature, or you can create a template sensor, and then display that sensor in the same way you would display any other entity.
ohh I see. thanks I'll look into it using those terms. makes sense to me conceptually at least
[edit]
got it I can edit the entity card and use:
entity: climate.bedroom
type: attribute
attribute: current_temperature```
Hi everyone, I noticed that dashboard's title gets hidden when adding views. It's just views title that are visible. Is there a way to have both dashboard and views titles?
ok hear me out - i have no clue why it isnt working.
I have 2 cards in my dashboard. one has simple switches to switch smart plugs on/ off.
The other one has buttons for different lights. the last one (woZi) talks to a group of all the 3 previous smart plugs mentioned before. when I push the "WoZi" button, all of the switches below turn on/ off. BUT THE LIGHTS WONT REACT. it works when I push all of the lower switches per hand ....
anyone with an idea what is going wrong?
You're doing something wrong in your WoZi entity, has nothing to do with the frontend.
petro, would you be able to help me with the dashboard title?
No idea what you're talking about, sorry
dashboard's title gets hidden when adding views
that's what it's supposed to look like
but the title get's hidden leaving only icons
Yeah people didn't like that on mobile so they did away with it
now it's a thin bar at the top always
you can potentially change it using custom cards
Oh, I see. Thanks for explaining that to me. What custom cards are you referring to?
got it, thanks!
I have a custom button. I want two if statements in the color code, but this does not work. Any clues? https://codeshare.io/AdxW4e
Only the first section of Ifs work
Or idk what actually works. Something works, but its not working like i want it to
You have to use {} after your major if statements when there's more than 1 line. Look up JS if statement examples.
Worked! Thanks:)
That thingy is " legacy " and is only visible in edit mode or on dashboard with one (or none) views.
Out of curiosity - why insist on keeping this space wasting thing?
I need it for desktop
My dashboard consists of two views: weekly and monthly. With the dashboard title (Usage) it makes more sense
ok, makes sense
You can always use view names without icons thou
not sure if card_mod can change it - it it only operates on cards and child elements of a card
Hello guys!
Does anybody know how would be the yaml to change this --mdc-icon-size property in card-mod?
Changing on chrome does exactly what I need, but I can’t find out how I’m supposed to do in yaml.
Hi guys
I have added pihole to my Home Assistant I'm not sure if i should setup automation from the front-end or back-end
reason I ask is back-end doesn't log the dns disable / re-enable
At this time i have it running with front end with automation so once i disable pihole it with auto enable after 03:00
What I'm missing
- To log when pihole dns is being disable / re-enable should this automation be setup front or back-end..
and a progression bar / countdown timer so i how long left when testing and may developed with a countdown timer etc etc
would love some info please
I'm using Nest Doorbell (wired gen2) and doing a Picture Glance card per the documentation for a live stream on my dashboard. It works, but then the live stream stops after some amount of time. Not sure what to do to keep it going, any idea?
did you enable the live view with in the card
Yes
@sacred gyro try a picture-entity
im pretty sure thats what i started with but ill give it another shot
It'll have the same result, check your log for errors
going to have to clear it and see. the only related error seems to be this one, but i often get this when editing the dashboard and updating it too many times so I am not sure if it is related Error handling WebRTC offer: Nest API error: Error from API: 429: RESOURCE_EXHAUSTED: Rate limited for the GenerateWebRtcStream API for the user.: Too Many Requests
hello everyone! where can i find the integrations configuration file?
my configurations file only shows this:
Loads default set of integrations. Do not remove.
default_config:
Load frontend themes from the themes folder
frontend:
themes: !include_dir_merge_named themes
Text to speech
tts:
- platform: google_translate
automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml
is it normal?
yes
ok thanks, so where can ia find the integrations config files
please do not crosspost
quick question. why does my app start up in Edit UI ?? is it because i am using Mushroom and not lovelace ? if so how do i make Mushroom the std frontend ?
make the dashboard your default, mushroom cards are just cards
they run inside lovelace, so that's not the issue
What is a "back-end" automation vs a "front-end" automation? As I mentioned in other channel, a helper timer is a good way to get a countdown progress in dashboard UI.
cleared the logs, it happened again, nothing in log related, searched for logs for "nest" and the ip address of my doorbell and don't see anything
Hey guys i hope someone could help me out with icons based on state.
i have a galaxy watch with the icon mdi:watch but when i charge it the icon does not change
is there a way to make it change icon based on when its charging.
when its not charging it shows the icon mdi:watch and when it starts charging it changes icon to something else then mdi:watch?
is there a way to get this in the yaml code?
Hey guys i hope someone could help me
Hmm, can’t we rename input_boolean helpers in the Ui ? Only solution I saw was to delete the existing and create new ones ? Seems a bad bug
Click on the entity to bring up the state and history. Click the settings gear in the top right corner. Change Entity ID
Like any entity
damn. you beat me to it RobC.
Sure. I know what to do. Changing the name doesn’t work
Admittedly, I first changed (translated) the entity_id, updated and then changed ( again, translated ) the name , updated again. Name doesn’t change…
Now you may have something:
It does seem to change the name, but not the titles where it's displayed?
Bingo…
I seem to recall an earlier issue, but couldn’t find it on mobile now
Must write it up if it’s not there then
how can i change the font family which is used?
hey guys, not sure which is the right channel for this but i was wondering if this is possible: i want to add a remote view for my tv in home assistant dashboard and add volume buttons that work like a normal tv's volume buttons - so if you tap it it increases by 1, but if you hold it down it increases until you let go
is that something HA can do? or will i have to tap it 20 times to increase the volume by 20?
yes i'm aware you said that but I'm asking to how one does it this is my first time and I'm asking how does one add a helper timer
I don't know how ie . witch card or how to add it to an card
at this time i have the following set up
show_name: true
show_icon: true
type: button
tap_action:
action: call-service
service: pi_hole.disable
target:
device_id:
- 7e72cc5a1343ade0650de991c706c8f3
- f756fe36be6acd2841a2dd372d2289ae
data:
duration: '00:03:00'
icon: mdi:pi-hole
name: Disable "core" "NAS" 03:00
this works but when your looking at the screen thinking hum when will the 03:00 be up etc etc
this is front-end i see that But i was also asking in this chat should i set this up as a card or should i be setting this up like the following
Settings > Devices & Services > Pihole > "click on" Settings > on this screen there "Automations" maybe that the way to set it up....?
Hi Mems
On iOS I often get this when open HA
I must exit it many time and open again
Orr refresh serveral times
Did someone know how to solve it?
Hey guys; I've just upgraded to the latest version of HA and of course you're aware the light dialogs have changed. Where we were once able to change color and brightness from the same 'panel,' now we have to push extra buttons to access brightness vs color.
Is there a way to go back to the old dialog? Sorry if this was covered above... not sure what keywords to search. Thanks!
Helpers can be created at Settings -> Devices & Services -> Helpers. Once you create the timer, you can then create a script with two service calls in it:
- the first one calls your pi_hole.disable service, as you have above
- the second one calls timer.start with a duration of 3 minutes.
Instead of calling pi_hole.disable on button tap, you start the script you just created from button tap, which does both things.
Then in lovelace, in an entity card, or an entities card, you add the timer.xxx entity you created earlier. You should see a live countdown while it is running.
hey guys, i have a question about custom layout card - not sure if this is the right place or not
i'm trying to make a tv remote dashboard for my HA and want to have a small row for the power button, and then a 3x3 grid that i want to use for the arrow keys/enter button etc
this is the code i have, but no matter what i do with the grid template rows, it doesn't actually change the height or anything for me
layout_type: grid
layout:
grid-template-columns: auto
grid-template-rows: 5% 75% 10% 10%```
as a side note, if i use px instead of % it works, but i'd rather have it based off % if i can help it
also the columns work with %, so it's just the rows
edit: actually changing it to px only partially works - the top row is overlapped by the rest of the thing when i change it to something like what i'd want it to look like
Just throwing this out there. I made some custom:button-card battery indicators with percentages on the side. The battery percentages were rotated 90 degrees. They would show fine on Firefox but would not rotate on my Fire tablet running Fully Kiosk Browser. I changed - rotate: '-90deg' to - transform: rotate(90deg) and it works in both browsers. (Decided to turn it the other way just because.)
Hello Tim0
Thanks so much for that I really appreciation your support
I have done part of what you said as i understood it
there also part i don't but
Helpers can be created at Settings -> Devices & Services -> Helpers ✅
then create a script called pi_hole.disable service ✅
second script with timer.start with a duration of 3 minutes ❌
But I really appreciation you for you trying to help me with this is a big issues i would love to get right and not mess up
as i said this is the first time iv done anything of this type right now
Thanks for your help
reason is i can't find or understand what you use for the script time start do i set to enable...?
or do i set it to ....
You should read the documents on timers instead of guessing what they do
There's services associated with them and once you take a look at the docs, you'll understand how to use them
Isn't it standard to have vertical text starting at the bottom finishing at the top when on the left side of items?
think graphs & plots
Is there any way to specify exactly where a card will be shown in the screen? Obviously there are various stack and layout cards, but I'm looking to try to define an X,Y location such as the bottom right corner of the screen.
You can attempt to remove the position by setting an absolute position w/ CSS and card mod.
it likely will only work inside the card you're working in and not the entire screen
I'm not sure about standard but I was having some difficulty with the justification, specifically if the battery at a 100%. This way seemed to be any easy compromise.
also keep in mind, absolute position is based on the upper left corner of the object, not the center
so if the text changes size, it will not be in the correct position
There are ways to add calculations to positions as well
I think that is basically the issue that I was having so I essentially put the upper left corner of the text at the top of the card.
I didn't want to put it on the right side of the card because then when the device is charging the different icon kinda messed with the appearance. (lightning bolt too close to the percentage)
I tend to "wrap" all of my dashboard pages in a grid card and then vertical stack cards. I wonder if the CSS would position somewhere within the first grid card. ```yaml
type: grid
columns: 2
cards:
- type: vertical-stack
cards:- type: custom:layout-card
layout_type: grid
layout:
grid-template-columns: 66% 17% 17%
cards:
- type: custom:layout-card
The main issue I have with trying to apply CSS is some cards "handle" the syntax differently. What works on one card might not work on another.
all cards handle it the same, it's where the css is applied that's different
for example, if the grid card uses a typical grid, then you'll want to learn up on grids
if it's not using a grid, then you don't need to apply the grid's requirements
also, different browsers interpret the CSS differently
iOS is notoriously rigid, where chrome allows 'goofy' configurations. I.e. you should style it for iOS instead of chrome because then it will work on all your platforms
Do you think iOS and FKB are about the same? Notice Firefox and FKB sometimes don't play nicely. (Hence the OP with the battery level)
I'm stumped, and tried various options and read the forum threads but can't seem to figure it out. How do you change the icon color on a picture elements card based on state, without using themes? I believe card-mod or something similar might be the solution, but still unsure...
I didn't mean create two scripts; you want to create a single script, with two actions.
Problem with Helpers on the dashboard
Hi All, wanted to ask if there is a way to use the native toggle that is in home assistant in my dashboard. If i go to a entity that can toggle and i click on it a popup appears with that toggle, I would love to use that in my dashboard. Not sure if that is possible?
cheers
Hello,
Can someone help me out with a dashboard entity please
I'm working on a dashboard with a floorplan as background and everything is working fine but I have some temperature sensors which I'd like to add that show the temp without any interaction.
Right now adding it as an entity shows the icon but I have to click on it to see the temp
is it somehow possible to have the temp showing instead of the icon?
You need some #templates-archived magic along the lines of {{ states('sensor.temp_sensor') }}°C
ok thank you! I'll look into templates
Hi Everyone
I wish to say Thanks to @ Tim0 for the help yesterday I got it all running as i needed Thank you so much
Now to work on the HA Steam intergrations please with me luck
No.
But someone with JS skills could probably wrap it into a working card (or hui-element).
Shouldn't be hard.
A bit uglier solution but there is also a thing called "more-info-card" in HACS that (combined with card_mod and hiding) will get you pure toggler.
Just use a state label instead of state icon. No template required.
How can I see the UI examples mentioned here: https://github.com/And3rsL/Deebot-for-Home-Assistant#ui-examples
Are they cards/images/dashboards?
I’m using custom card mod and trying to apply custom css to #calendar .—fc-page-bg-colour but I can’t figure out why it won’t apply can someone help me out please with apply css to this
Normally I’d over ride the background colour but I’ve never used the — things before
you're the best 😄 exactly what I needed
Asking again - I'm stumped, and tried various options and read the forum threads but can't seem to figure it out. How do you change the icon color on a picture elements card based on state, without using themes? I believe card-mod or something similar might be the solution, but still unsure...
type: picture-elements
elements:
- type: state-badge
entity: binary_sensor.basement_floor_wet
style:
top: 32%
left: 40%
'--label-badge-text-color': var(--green-color) #icon color
color: var(--pink-color) # text color
card_mod: # only needed for badge border
style:
ha-state-label-badge$: |
ha-label-badge { --ha-label-badge-color: var(--red-color) !important }
image: https://demo.home-assistant.io/stub_config/floorplan.png
oh, just read the requirement part "based on state without themes"... u just had to make it extra difficult, eh?
type: picture-elements
elements:
- type: state-icon
entity: ...
style: ...
card_mod:
style:
'state-badge$': | #need to tweak selectors to entity type
ha-state-icon[data-state="on"] { color: red; }
ha-state-icon[data-state="off"] { color: blue; }
state_color: false
ps this will not work with state-bage type
Thank you - Will try it out.. Much appreciated!
Another approach is to simply define state variables on card level with card_mod (instead of theme).
This will work with less entity types (e.g. not lights) and device classes. But will work e.g. with battery sensors.
Hello I think this is the right chat, I currently show my Sonos system in a media player card on my dashboard. I want to hide the Sonos media player card when the Sonos entity is playing “TV” and then display another card with media controls for the tv on it. How would I go about functionality the design I can sort myself thank you in advance 🙂
Heres my code so far:
conditions:
- entity: media_player.connors_room
state_not: 'off'
card:
type: custom:mushroom-template-card
primary: Test Card
secondary: ''
icon: mdi:home
Instead of using state_not: I want to check if sensor.connors_room_audio_input_format == Dolby 2.0
Dunno... Does Sonos thing simply sets "TV" as state (not attribute) of media player?
Just updated my original message 🙂
Conditional card doesn't do attributes afaik. State Filter does but it has painful other limitations.
State Switch or Button Card or Config Template card (HACS) using templates are best option.
edit: lovelace-card-templater and even Auto Entities (a bit less intuitive) can also be used for this
which would would auto do it when the state changed?
Any with right code. State Switch should be easiest.
it's basically a stack of cards that shows the one that matches condition.
Sounds good thank you will install it now and have a go if I need anything I will give you a shout 🙂
The sensor is there but this doesn't show anything
entity: template
template: >-
{% if states('sensor.connors_room_audio_input_format', 'No input')} tv {% else
%} sonos {% endif %}
states:
tv:
type: markdown
content: TV
sonos:
type: markdown
content: SONOS```
TemplateSyntaxError: unexpected '}'
you meant to use is_state(id, 'state') or state(id) == 'state' ?
I'm a donut got it thank you 🙂
@tacit cave I made some progress with positioning cards in the bottom right corner of a tablet's screen. The media player card is conditional and is only visible while playing which would subsequently push down lower cards. Not so much any more. Accomplished using a custom:layout-card with grid-template-areas defined. Not completely sure how to use it but I think it will do what I want.
Worked perfectly! Thank you so much...
https://www.home-assistant.io/integrations/tomorrowio/ might prefer using this
On a picture elements card, using state-icon, I'm trying to get the icon to blink when the state is 'on'. I tried this unsuccessfully, any suggestions/pointers will be appreciated.```
card_mod:
style:
'state-badge$': |
ha-state-icon[data-state="on"] {
color: gold;
animation: blink 2s linear infinite;
}
ha-state-icon[data-state="off"] { color: green; }
state_color: false
Got it working... 🙂
Hi guys
I have a timer setup now and running I would love to ask how does one make a progression bar to work with the timer or "in the same card"
I probs don't need it i would just like to work out how to so i can look at if i should keep it or not
Cheers
is there no way to clone a dashboard in the UI?
Hi, I need a media player card a bit like mini media player but with the library button which allows me to browse my media any ideas? Please ping me with response
I currently use the default media player card just because I can browse my media but I’d love one where I can customise the play buttons to call services etc
The issue I have with the default media player is it doesn’t pause my tv it just pushes the home button essentially and brings up the YouTube video info
Long story short, mini-media-player but with a library browse button like the one built into ha default media player
Danggg it’s a shame there’s no way to have the button on custom ones or a way to toggle the media browser using a call service
I remember it was relatively easy, just needed to make a button that fired some event with media player id to open the dialog
hope it haven't changed
I will look into it but not today 4 sure
I would appreciate that when you get a chance thank you
any chance of a compressed entities card? with tighter spacing?
Stuck.. I want to use something like this:
- type: picture-elements
image: /local/images/alexa.jpg
elements:
- type: custom:button-card
template: network_status
entity: device_tracker.kitchen_show
style:
left: 20%
top: 30%
- type: custom:button-card
template: network_status
entity: device_tracker.bedroom_spot
style:
left: 50%
top: 30%```
and this is the template:
``` network_status:
styles:
img_cell:
- border-radius: 100%
- width: 50px
- height: 50px
card:
- background-color: rgba(0, 0, 0, 0)
- box-shadow: none
- max-width: 100px
name:
- color: white
- align-self: middle
- white-space: pre-line
- word-wrap: break-word
- font-weight: bold
icon:
- width: 60%
label:
- font-size: 70%
- background-color: rgba(0, 0, 0, 0.1)```
My problem is I don't know where to put the template part.. any guidance will be appreciated thank you
yeah, with card_mod as usual.
you can shrink card margin and spacing between rows - pretty basic stuff
The templates need to be at root of dashboard config
(details depends on whenever u have classic UI or "yaml" dashboard type)
https://github.com/custom-cards/button-card#Configuration-Templates
In case of standard dashboard you must select "Raw configuration editor" mode and put it there:
make sure to copy entire config somewhere (ect to notepad) in case you mess up badly and config "gets cleared"
edit: ok it shouldn't happen ad 2023 but it's always better to be safe
hey guys, i'm a little stuck with a view i'm trying to make - i'm trying to make a remote control for my tv and want to have power, navigation buttons and a few other things that i haven't added yet i'm trying to make it so that all the buttons don't "use" up as much space if that makes sense? so instead of something like in the first image where there's a lot of space around the button, it'll be like the second image
also i was wondering if there's a way to make all the nav buttons have the same code without pasting it into each place
here's my code:
http://pastie.org/p/1LJJbxyCLA4ujA5KQjMxza
sorry if i'm missing something obvious, i'm very new to all this and banging my head against the wall
trying to figure out which css is needed; so far no good
ha-card {
color: red;
padding: 1px
border-spacing: 0px;
margin: 0px;
line-spacing: 40px;
}
I have a sensor that I mostly use for a trigger when the house group is empty (when all registered HA users are away )|
Can I add a simple toggle to enable something like Guest Mode - where an additional entity is included in that group and would thereby prevent the house from showing as empty ?
type: entities
entities: [...]
card_mod:
style: |
#states {
padding: 2px; /* spacing for whole card (16px default)*/
}
#states > div {
/* 2px = between rows (8px default), you can try negative values here */
margin: 2px 0px;
}
is there any way to have a folder in the sidebar to group together (and collapse) stuff?
Thank you
@haughty vine thank you I’ll give that a try
Anyone know why over the last month I have been getting incomplete renders of my dashboards on the mobile/companion app (eg missing several of the cards - usually the first couple) ? I believe it started after the 02 or 03 update.
It is an intermittent thing
when you control-click on a panel in the sidebar even though it opens in a new tab it changes the focus
is the sidebar even part of ha? should i raise an issue for this?
hmm I can't seem to actually ping a mod but that's spam
It’s often broken on mobile but if you type out @ mod without a space between @ and mod it will still ping the mod role
oh weird, I'm actually on desktop
shrug seems like message is gone now so all good
maybe it's because I'm new to the server
Discord breaks itself on desktop too
The discord coders are too busy finding the worst possible fonts to fix that bug
😅
Hi All. Looking for some suggestions for how to start troubleshooting my HA frontend. in the last 3 months i've noticed that the frontend is extremely slow to respond. I've got some dashboards where you can see in real time as each card gets rendered and added to the dashboard. Also find that just clicking on buttons can take seconds for the click to be registered. This also applies to things like tapping on the hamburger button to open the side menu on the mobile app.
This slowness seems to occur equally on the companion app and a desktop browser. Its hard to say when it started happening, but I would say some time this year (but as I can't pinpoint when i'm not sure if it was a HA release or a change I made).
Now i'm open to the fact that I might just be doing too much in the frontend (although I don't think my dashboard is that complicated), but I have no idea where to begin troubleshooting or profiling the front end to try to understand whether there is a specific thing thats behaving badly, or if its just overall load. Any help/pointers would be greatly appreciated.
Hello everyone, I cast my dashboard to my nest. That works fine. But everything is a bit small. Is there a way to scale everything up? Like 200% or something?
One slow method to try:
- create a new dashboard
- put one card type (or Button Card with selected template) there that you frequently use or sus.
(in multiple copies with different entities if possible) - refresh browser page so it renders new dashboard view from start
- check performance impact
(welp the correct answer is:
spend a lot of time in devtools > performance tab while u know what your doing, pull some hair out until u finally pinpoint the source of the problem)
I already have 4 different dashboards of varying size and complexity (including one that just has the default entity cards) and they all show the same behaviour unfortunately.
I suspect that will be the answer, which is where I was hoping there might be some guidance on what to look for.
btw. out of curiosity: are you using Button Card templates (or UI-Minimalist or other solution based on it)?
There’s a mix. But one of the dashboards purely uses auto-entities and the default entity card, and that still exhibits slowness.
hmmm.. that's not a good sign
it might be not a card related problem
but let's make a small sidestep back and check one important thing...
when u open browser devtools > console
any errors, warnings (or even standard messages) that loops constantly? (the faster they loop the more sus)
Is there anyways to change a color light back to standard white, using the mushroom card? If not, how are people accomplishing this? Seems like being able to go back to a standard white light is a valuable feature. I tried playing with the RGBs but couldn't find anything that resembles the standard white light.
Just add "Temperature color control" and pick white on the temperature slider?
Noticing this error within my log file and not quite sure what it means. Everything on the dashboard functions normally. Seems to happen upon every restart of HA.
Is this something I should be worried about?
dunno, report it?
there is no much detail on screenshot here (just "Uncaught") I would have expected some additional lines below to pinpoint where exactly it came from.
Will report but was just curious to see if anyone else ever ran into it.
Yeah, I thought the same thing regarding more detail but that is the whole error message, unfortunately.
No, no errors or warnings on the console. And the messages just print once and that’s it.
Thanks for the response. That seems to work with my Hue lights but for some reason, my Mercury lights which uses the Tuya integration do not show the temperature controls. Any idea why that may be?
they don't support color temperature modes probably
(you can verify that in dev tools checking "supported_color_modes:" attribute)
And if they don't then I'm assuming the only way is to select white in RGB wheel?
IIRC, some Tuya-based lights used to have issues with RGB and color_temp. There was a way to force supported features.
yeah, they're using customize mechanism to force-enable additional color modes.
this will probably trick frontend but how backend (and integration) reacts is a different song
if the bulb supports a color mode but it's not exposed in frontend it's a bug and should be addressed as such imho
And, I still have those bulbs configured even though they're long gone.
It's not really a bug. Just the light's quirks or something like that identified the bulbs are having different features.
This also tricks the backend. Object inheritance will make it use the functions that the TUYA integration inherits from. Which is most likely a basic TUYA light, so if the light that has a 'reporting features' issue, this trick will fix that problem.
it's also likely a bug in the TUYA hardware, not necessarily the integration
usually quirks are handled by integrations (ZHA, Z2M) but with all the hardware on the market (and DIYs) I understand why people are doing it that way 😉
and also some revisions. I think I had issues with Sengled bulbs. First batch was fine but second batch needed the customization.
supported features is just a flag that enables the actions in home assistant. The only way that wouldn't work is if the actions are not defined in the integration itself. And in that case, it would silently fail because the base light entity does nothing when a missing method is referenced
just FYI.
That thread is mostly from 2020. The supported_features: is currently depracted (but may still be used by some code or cards!)
The attribute responsible is now supported_color_modes:
And the exact values (comma separated) can be found in the source code:
https://github.com/home-assistant/core/blob/dev/homeassistant/components/light/__init__.py#L68
Yup. But there's also a reason why it has over 18k views. Was pretty common back then. Not so much any more.
The attribute is not deprecated, the SUPPORT_ constants are
As from 2022.5 all possible flags are now deprecated for Light entities at least.
So the attribute still exists for compatibility purpose only now.
In fact looking at the blog:
https://developers.home-assistant.io/blog/2022/04/02/support-constants-deprecation/
it looks like any possible flag is depracated so there is no purpose for supported_features attr. any longer
I haven't used Tuya-based bulbs in over two years so I'm not really up to current events on them.
I don't think you understand the change
the deprecation is for the Constants in favor of enums
and the enums match the old SUPPORT_ values
Light was a special case where color and a few other supported features were moved into separate 'supported feature' categories
this was done during the great migration to enums so that HA could handle translations on attributes
which has basically spanned the past ~year because it's still not fully complete
ok. my bad. I get that now . I was fooled by the new attribute on Light
(I don't follow the source code except just occasional peaks under the hood)
Hi ! i add camera lovelance on my dashboard and since that im not able to load home assistant anymore :S There is a way to remove the config or accessing the code ?
- Switch to view that doesn't contain camera and enter edit mode (easiest, ui dashboard)
(try "Raw configuration editor") - edit source directly (yaml dashboard)
- locate config in
config/.storage/lovelace.$nameedit it and restart (ui dashboard)
careful with this approach!
I am in the process of installing Debian 11, I am now getting a message I have missing firmware files iwlwifi-7265D-22, 23, 24, 25, 26,27, 28. Went back to my computer found firmware file, but came up only as "Readme". Then got confused on Debian site.
What are you trying to do, long term and what hardware are you using?
Also, why do you need wifi?
trying to install Debian to run Home Assistant,
Ok, so you're going to run what version of home assistant: HomeAssistant OS, Home Assistant Container, Home Assistant Core, or Home Assistant Supervised?
I am using a Lenovo laptop that is going to be used for only home assistant, it has 4gb ram, 64bit, 450gb hard drive,
Home assistant supervised
ok, what is an easier way, that is what I want
HAOS
if all you're doing is running home assistant, that's the easiest route
However, that doesn't mean it will make your wifi adapter work
which is why I asked "why do you need wifi"?
I will be direct plugged to the internet once I'm done, or should I be plugged in now?
if you're going with an ethernet connection, you don't need to care about the wifi adapter
So, I recommend trying the generic arc 64 bit Home Asisstant OS installation
and plug it into ethernet when you're setting it up
Ok, I struggled this far, how do I get started from here to installing the generic arc 64 bit Home Assistant OS installation
I can't seem to get my nest doorbell camera to keep streaming to my dashboard picture glance/entity. it always times out after a while. im thinking its a nest problem. is there a way i can somehow request an image from the camera every 10 seconds and just have the dashboard display the latest image?
does your nest device have ONVIF, RTSP, or RTMP feeds?
according to the documentation only webrtc
whelp, i'm all out of ideas then
How can i show a HA Dashboard and/or direct media player to a ROKU TV?
Get a chromecast lol
Tho really those only support airplay/miracast and like no browsers
You might be able to find a cast app in the store but I recall them being non-free and pretty clunky
With a chromecast/androidtv you can do live camera feed popups on your screen even
@tulip zodiac Thanks, Is there a way to automate switching to the chromecast then display a dashboard for say 30 seconds and then return to what was previously being viewed
Like with video or just various cards?
both options if possible
I'm sure it's possible, you have the cast.show_lovelace_view call, it might take some automations to auto exit it however
For video popups on chromecast I use this: https://github.com/fathome/PiPup
Ok so I assume, close down my computer in the middle of installing Debian. Then with my computer hooked direct to the internet, I boot up in bios. UEFI Boot mode, no where do I get the bootable HAOS? It was easy to find in Linux page.
uh
did you install it?
@dense nova you have to read every paragraph in the installation guide
the first 4 steps are before you even install anything
Whenever the UI shows this timeline-with-color-bars view for history it seems useless for most purposes.
How do I change the view to show all the values in a list with timestamps like it shows with some other entities?
It's especially bad if the entity in question has a bunch of different transitions in a short period of time and the bars are a single pixel wide.
Any way to have it just display a list of the previous values with their timestamps?
Is there a better card for showing something that briefly runs for a few seconds, say, once an hour? With the history-graph it's almost impossible to see the razer thin lines of when my sump pump has run.
I had just been looking at the Amp graph (the pump is just hooked up to a power monitor) which shows the spikes well but my power monitor went a little nuts a couple times and reported values way outside typical usage which kills the y-axis range making it useless.
So I made a helper to just capture when the watts are above a running threshold and convert that to Running/Not Running but the history-graph display isn't very useful.
anyone have any suggestions for this? I think maybe I just like easy shortcuts to places
This is essentially the exact problem i posted above yours.
Need some way to show the value changes with timestamps instead of a color bar history.
Having a way to fold the sidebar would be lovely too. For example if dashboards could have their tabs folded in the sidebar, that would make mobile usage pretty nice for dashboards that have many tabs.
I was just merging some of my dashboards into tabs, but yeah that would definitely be neat
Frequently when I open my dashboard on my TV via Fully Kiosk or the HA app (sideloaded) it briefly displays large red error cards for custom cards. It almost always resolves after a second or so and displays the card, but I'm wondering what the underlying problem is here and why the error in the first place and if there's something I can do?
This is more of a problem for me with certain cards that wrap other cards. I've only noticed it with auto-entities and switch-state cards. They seem to try to render these custom cards, and when they fail, those cards just never get rendered.
I posted more about this here:
https://github.com/thomasloven/lovelace-auto-entities/issues/329#issuecomment-1475530005
hmmm maybe try very slimmed (card_mod) logbook?
(you can go slimmer with fonts, puddings.. maybe even 2 columns design)
Hi i get ring-mqtt and know i searching to put a lovelance for livestream
im trying to setup a music view for my dashboard. i have my media player connected to my sonos. is there any way of retrieving the lyrics for the currently playing song and display them? ideally scrolling but that might be asking for too much
I'm more going for something I can visually recognize a trend with. I want to tell if my water inflow is accelerating or decelerating.
I think there are trend sensors as well that could be useful, but I don't have any specific advice.
https://www.home-assistant.io/integrations/trend/
Oh, that's interesting. Thanks.
How do i set a default theme that is used when no option in the user config is set?
this is not a good sight at a dark mode kde desktop
found it.
if you want HA widgets in plasma. clone the webbrowser plasma and set the default url and remove the nav panel
hey guys, i'm trying to make a tv remote dashboard and am a little stuck with card mod related stuff
here's my code: http://pastie.org/p/5rFOJb38yBKZJbQP4YmAOs
i'm trying to make it so that a) the buttons themselves aren't as wide, so the arrow keys and the circle enter button are closer together without compromising the side of the icons?
and b) all the buttons have the same look (black icon, no background/border) - i can do that manually on each button if need be, but was curious if there's a better way?
Is this a bug? In the companion app when I click a sensor like a temperature sensor and choose a start and end date to try to reduce the duration the graph shown, the date picker seems to jump back one month. Eg when filtering a sensor today, the date picker shows February instead of March by default in the date picker.
This is a UI/template question, so I'll start out asking here in the hopes that this is the right place:
I found this article: https://cyan-automation.medium.com/using-a-template-to-change-a-sensors-icon-in-home-assistant-41766a959ddf that describes how to use templating to change an icon.
I have a basic, default "Light Card" that I'd like to change the icon for under certain circumstances. Do I simply click the Show Code Editor button on the card then replace the icon: mdi:lightbulb line at the bottom with the icon_template: >- code bit from the bottom of that linked article to look at the sensors I want and the icons I want?
Is it really that simple or am I missing something entirely?
Nope, not that simple. icon_template: >- just gives me the same icon I had before with no change based on the value of the input_boolean I'm looking at, while icon: >- gives me no icon at all with a template there.
I guess this moves on to #templates-archived for further help?
No, I don't think so. I pasted my template statement into
and it changes the result exactly as I'd expect it to, so I think that the issue is in how I'm defining it in the card
This is the code I've got:
{% if is_state('input_boolean.allowlightchangelivingroom', 'on') %}
icon: mdi:lightbulb-auto
{% else %}
icon: mdi:lightbulb
{% endif %}
Anyone see an obvious error that I'm not seeing?
ditch the icon:
btw, this is a #templates-archived thingy
also, instead if checking old web posts, better check the official docs: https://www.home-assistant.io/integrations/template/#state-based-binary-sensor---change-the-icon-when-a-state-changes
and you can not define this in/on any core card, because templates are not suported, except in markdown
Thanks. I've been in templates and my template is working. The issue seems to be that the core card I've chosen doesn't support templated icons.
Now to find a listing of cards I can use to find one that'll work for me.
Gotcha.
I am attempting my first go at designing a dashboard and I love one shown on ESH's channel. How do you make columns in desktop/tablet view of unequal width? This video shows what I mean. The first column is narrower than the others, but if I add 4 vertical-stacks to 1 horizontal-stack, I get equal width... https://youtu.be/FBjVss96C0E?t=1038
You need to change the template though to syntax of the used card
Check layout card
Is there a thorough, somewhat "official" listing of custom cards available for me to browse through, or is it grab ideas tossed at me (I appreciate them and will look at what you've suggested) or search the web for various ones and give 'em a try?
I do see this: https://github.com/custom-cards but I'm not sure if this is officially sanctioned or just someone's collection.
Thank you! I always seemt o look in the wrong place 🙂
I do have HACS installed and have found your suggestions there. Button-card might just be the basis of what I'm looking for. TYVM.
did not follow all but adding templates to cards also works with (hacs) card-templater...not straightforwards but I made it work for 3 cards in my setup
That changes the options of another card . It will depend on your requirement but might be better if with a card that natively supports those options
Button-card is famous and can do anything . Best of the best if you ask me
Hello !
What could I add on the main page of my dashboard I find empty?
How to improve the text of the buttons to change page
such an open question begs for an open answer: why dont you check https://community.home-assistant.io/t/mushroom-cards-build-a-beautiful-dashboard-easily/388590 and find inspiration there
thanks 😄
only 6000 posts to find your ideas in 😉
thanks !!!!!
you bet you will run into things like this https://community.home-assistant.io/t/mushroom-cards-build-a-beautiful-dashboard-easily/388590/6104
or some of the amazing stuff Rhys manages to do with that https://community.home-assistant.io/t/mushroom-cards-build-a-beautiful-dashboard-easily/388590/5993
ok I'll look at this, it's true that discussions are the best things to get ideas!
Hi guys... Can someone help me out with using a power-flow-card?
I noticed this too. It used to work fine.
Had to go run some errands... Not sure I follow your first statement there, but I'm reading through the docs and will play with this over the next day or two - see what I can come up with.
is the sidebar hidden/panel order stored in the browser or is it by user/device?
in the browser, if you log into different user with same browser (or browser container) it will overwrite settings
(last time I checked)
ah that's an odd design choice...
maybe. but considering user can log from multiple devices, and it's rare for users to share same browser session those days it makes sense. And in order to restore proper device config from server it would require to generate proper unique id for particular "browser" (or hardware id for device).
they decided to kept it simple
You could always use kiosk_mode (https://github.com/maykar/kiosk-mode; available in HACS) and do some customizing
Having issues with getting a button-card to change its icon based on the state of an input_boolean. I have zero experience with JavaScript, so I wouldn't be shocked if the issue is there, but this seems to "work" (i.e. it allows me to save it), but it doesn't do what I want it to do. Tips, pointers, or clue-by-four would be appreciated:
entity: light.living_room_light_switch_light
name: Living Room
color: auto
triggers_update: input_boolean.allowlightchangelivingroom
icon: |
[[[
if (states.allowlightchangelivingroom === 'on')
return 'mdi:lightbulb';
else
return 'mdi:lightbulb-auto';
]]]
Not sure where the icon: | comes from. I type in icon: > and it gets converted automagically...
@torpid harbor I think there is an issue with how your trying to get the "allow" state.
From one of my custom:button-cards yaml if (states['binary_sensor.s22_ultra_is_charging'].state === 'on') return 'blink 2s ease infinite';
As I said, application of the clue-by-four is appreciated...
styles:
icon:
- animation: |
[[[
if (states['binary_sensor.s22_ultra_is_charging'].state === 'on') return 'blink 2s ease infinite';
]]]
- color: |
[[[
if (states['binary_sensor.s22_ultra_is_charging'].state === 'on')
return 'red';
]]] ```
Icon is flashing in this example
in that vein:
[[[
if (states['input_boolean.allowlightchangelivingroom'].state === 'on')
return 'mdi:lightbulb';
else
return 'mdi:lightbulb-auto';
]]]
doesn't seem to work either. Am I doing that right?
Oddly, in
template editor,
mdi:lightbulb-auto
{% else %}
mdi:lightbulb
{% endif %}
had been responding, but now it's not.
weird... I added the styles: you suggested. that didn't help.
I deleted it and now it's working fine. 🤷♂️
Yeah. That's for something else I have going on in a different button-card. I removed that post since it was wrong in this case.
Weird... Done for the day on this. brain's fried, not going to risk screwing things up...
The card you've designed: basically it allows you to turn on/off the light, but shows a different icon based on the input_boolean?
I took out the triggers_update line and it still seems to change the icon as the input boolean is being toggled.
The card you ve designed basically it
morning,
I was wondering how can I create a dashboard page as this person did.
It was shown on the Everything Smart Home YT Channel.
(I mean how did he created this dark background as well)
Hello, would you have a map to see the average temperature in the house of the heating over 24 and 7 days?
I use ui minimalist I think I can add card mushroom I'm not sure
sorry for adding yet another question but is there a way to make the blue color yellow as well-?
Depends on your take on ”map”; there’s https://github.com/kandsten/ha-heatmap-card (disclaimer: I’m the author) which may or may not be what you’re after.
How can I insert a fixed text in the personalized card?
I have put this but it doesn't work.
- type: custom: text-element
text: "State:"
style:
top: 59.6%
left: 26.8%
-type: text
text: "State:"
style:
top: 59.6%
left: 26.8%
markdown?
no, in pictures-elemens
OK so now I have my own problem for a change
I want to put a History Graph card into Button Card, but I'm experiencing problems with how to css it correctly.
If I don't set overflow on field the canvas chart will not resize correctly or try to "escape" the button.
On the other hand I want tooltips to render correctly - they should overflow button if possible since there is no space for them inside.
How do I?
@haughty vine I converted your message into a file since it's above 15 lines :+1:
Is this normal that it doesn't work?
I get the jpg image, but an error as if the text card could not be displayed.
type: picture-elements
image: /local/tesla_y_top.jpg
elements:
-type: text
text: My Personalized Card
style:
top: 5%
left: 50%
font-size: 28px
font-weight: bold
colour: white
@gritty hull I converted your message into a file since it's above 15 lines :+1:
I left on this a simpler graph thank you, a person would be add me in the middle top next to heating an average over 48h?
any ideas ?
Hi, I have a mushroom-template-card (see what I sent) can I put it on my minimalist ui?
Or could someone convert it to ui minimalist, because I just tested it doesn't work 😦
I don't know how to do it
Has anyone made or seen dashboard made in Lovelace that mimic how stream deck buttons look and work? I might have to
how do i change the color of a toggle
Does anyone know why this will not open on HA Mobile App?
Works if I open from web up via Addons and works fine on computer
Just not on mobile apps
It’s just blank
Hey, I’ll take the liberty of doing a one-time and totally shameless plug for my Heatmap card, hoping others may also find it useful. Takes a sensor in one end and outputs a heatmap in the other end. Details can be found in the repo at https://github.com/kandsten/ha-heatmap-card
Hello I'm trying to change the background color of the below:
See Screenshot 1
Heres the html:
See screenshot 2
@haughty sorrel I converted your message into a file since it's above 15 lines :+1:
its inside a fire-dom-event
Heres my updated code line 10 - 12 is what I tried using card mod to apply it to the fire dom event can you please ping me with a reply thank you 🙂
ha-dialog div.content {
background-color: #FFFFFF;
}
@haughty sorrel I converted your message into a file since it's above 15 lines :+1:
That's really neat. I'm guessing the number of days available depends on the recorder purge_keep_days setting? If so, you may want to put a note in your documentation about that to head of questions of "why can I only see ten days?" (the default for the recorder).
Never mind. I see it is using LTS. Nice.
Hey there,
I have created an entities card within a vertical stack and I want the icon of the entities will blink whenever state is changed to detected, I have done something like that in the past but can't manage to implement it to the new card.
This is the entities card:
http://pastie.org/p/163XUb6TKJFEtg2Kb1uhWx
This is the old card with the blink part:
http://pastie.org/p/3T3uqbRPbNQwDs6qLLge52
Thanks for your help!
Hello guys, can someone help me with this:
Is this normal that it doesn't work with the card: pictures-elemens?
I get the jpg image, but an error as if the text card could not be displayed.
image: /local/tesla_y_top.jpg
elements:
-type: text
text: My Personalized Card
style:
top: 5%
left: 50%
font-size: 28px
font-weight: bold
colour: white```
i am using mushroom light cards. when i tap on the light button in the mushroom card it toggles the state of the light off and 100% on. I want it to restore the light to the percentage it was before it was turned off and not 100%. How can I do that?
Can anyone help me with mushroom? I'm trying to get my secondary information for a motion sensor to show as "Clear | x minutes ago" but the best I can manage to get is "Clear | 13:47" which also happens to be an hour behind even though my timezone is set correctly and the history shows the correct time?
Clear | {{ states.binary_sensor.hall_motion_sensor_occupancy.last_changed.astimezone().strftime('%H:%M') }} this is what I have currently, I understand that astimezone() is what is causing it to be an hour behind (UK time) but I'm not sure what to replace this with and how to get it to say minutes ago instead
Clear | {{ ((now() - states.binary_sensor.hall_motion_sensor_occupancy.last_changed).total_seconds() / 60) | int }} minutes ago
do note that if the binary sensor is on it will also show the same thing (unless you check the state first)
it shows the wrong time because it's DST now in the UK, and the timestamp is in UTC
you can use as_local to covert it to your local time
Newbie question, how to put a card to take the entire row of the page ?
after - title: ?
Yes. Or in the view options in the GUI there's a "View Type" selector.
I think it's actually type: panel nowadays
When did that change?
Probably around the time the sidebar view type was introduced 🤷 https://www.home-assistant.io/dashboards/panel/
Cool, good to know. Thanks
i have a binary sensor and a button, how can i make this a single button where the icon changes based on the binary sensor?
Hi all I have been banging my head for the last few days trying to work out how to make card with an input_datetime update today's date and now time. I have consulted documentations and can't seem to hang the pieces together. It would seem like the sort of thing you should be able to do in the card config but I think that is a feature request. Hence I am not sure about what I need to do this, ie entity, script, automation or card. Also please let me know if I am asking in the wrong place. As FYI this is the field I want to be now.
Hey there,
I have created an entities card within a vertical stack and I want the icon of the entities will blink whenever state is changed to detected, I have done something like that in the past but can't manage to implement it to the new card.
This is the entities card:
http://pastie.org/p/6DLEJJ01eOTZlzPl2CYAh7
This is the old card with the blink part:
http://pastie.org/p/0hNQFEfVxhzRMQBeJ2tjxW
Thanks for your help!
I must ask stupid questions,or ask questions stupidly, because I never get answers here. But I'll keep trying. In panel view cards are too long and go below the bottom of screen when in landscape. I want a panel card on a tablet in landscape to fit. height: or max-height does nada. Please help and ty.
I don’t have a specific answer to your question but you might have better luck with a Reddit post. Custom stuff like this is hit or miss if people can / are willing to help
is it just me or does the dashboard "search cards" not actually work
When I look at the history of a sensor, and I click on Start date or End date to adjust the interval, the calendar that pops up normally shows the current month. For a while now, it's been popping up with February... how do I get it to go back to showing the current month?
I created dashboard for monitoring. How to give without any change another home assistant and computer for my friend.
how does one use the sidebar view? Can't make heads or tails from the docs on the site.. anyone have an example of the yaml?
@polar kelp
Saw your name pop up in the chat and just wanted to say thank you for all of the wonderful repos you've created for home assistant!
Yeah I feel like it's impossible to create not-basic dashboard that isn't using at leas one of his cards / frontend addons. They are just so versatile.
@polar kelp - Really great job man.
I am getting the following error:
The automation "Notify: Abby Home Enter" (automation.abby_is_home_notify) has an action that calls an unknown service: notify.mobile_app_aarons_iphone.
This error prevents the automation from running correctly. Maybe this service is no longer available, or perhaps a typo caused it.
To fix this error, edit the automation and remove the action that calls this service.
Click on SUBMIT below to confirm you have fixed this automation.
The notify.mobile_app_aarons_iphone used to exist, but now appears to be gone. I haven't removed my phone or done anything with it. It is still the same phone and the icloud service is still running in HA. Any thoughts??
Judging by service name this is about official Companion App.
You should try #ios_and_mac-archived for help
Is there any error related to integration?
Have you renamed the device? Service name is derived from device name in companion app.
I don't even have a Device Name entered in the companion app
I see the phone battery level, focus, connection type, etc. inside the people tab I have.
have you tried simply typing "notify.mobile_app_" in Dev Tools > services and see if anything pops up related to your phone ?
there should be at least one service for each mobile_app connected
if it's not there then it's almost certainly some error
There is one for each phone showing. . . however, since then I did input the device name of aarons_iphone. . . .
That device name missing in the companion app must have been it, because the service also shows as an option inside the automation from which it was previously missing. Very strange as I never set a device name in the companion app when it was working before. . . . but it appears to be fixed now!! Thank you for the help!
np
This issue has been ongoing since the last core update. Maybe the last core update made it reconcile the companion app device name and since it was blank it didn't know what to do?? Who knows. Working now
I always forget about using the developer tools to call services and such. Thanks for the reminder on that too!
in the Android the field is always set
the initial value comes from device name of Android
Avoid changing it after install since entity ids will not automatically follow
and generally changing 80+ entity ids is a nightmare to deal with
Searching for hours to find the correct card_mod style for this JS path, anyone have any idea? 🙂
"ha-dialog>div>hui-vertical-stack-card$#root>alarmo-card$#keypad>alarmo-button:nth-child(1)$button"
not sure why you needed "ha-dialog>div>hui-vertical-stack-card" part,
but if you anchor card_mod to alarmo card it should be simple:
card_mod:
style:
'#keypad>alarmo-button:nth-child(1)$':
mwc-button$: |
button { ... }
You can theoretically put this selector in single line
(the rule is to split selector part that returns more then one result)
Thanks! Just tested but it seems that it's not working?
style: |
'#keypad>alarmo-button:nth-child(1)$':
mwc-button$: |
button { background-color: red }```
- You made a typo, there is no "
|" afterstyle: - You need stronger selector, try
button.mdc-button
card_mod:
style:
'#keypad>alarmo-button:nth-child(1)$':
mwc-button$: |
button.mdc-button { background-color: red }
How do I get my covers to have both up and down buttons enabled at the same time, seems this shoudld be simple. I’d like to be able to move them up and down without having to go all the way ip or down first
dm me
it should be working as I had setup actual alarmo card myslef to verify it
Can you accept my invite? Thx
Anyone have ideas for this?
I use an ESP32 in ESPHome to measure a pH probe with it's A/D. I specify in the ESP yaml a unit_of_measurement of "pH". All works well but HA continues to give me a warning that the sensor "is using native unit of measurement 'pH' which is not a valid unit for the device class ('voltage') it is using...". I see that pH is not a unit that falls into any of the list of available device classes. Anybody know how to get around this persistent warning?
type: entities
entities:
- type: conditional
conditions:
- entity: binary_sensor.entity
state: on
row:
entity: button.entity
icon: mdi:icon_when_on
- type: conditional
conditions:
- entity: binary_sensor.entity
state_not: on
row:
entity: button.entity
icon: mdi:icon_when_off
if you want the most basic solution (depending on what you define as "one button")
That's perfect
Thank you so much
it's unfortunate that philips hue bulb groups are so wonky in regards to response times in the UI
the office and utility room lights are wifi and they're updated instantly
for the garage door button i actually ended up doing a stack (vertical or horizontal doesn't matter) with two conditional cards for each state of the binary sensor
help?
it does the same for me. It's likely a frontend bug in HA
is there any way to start on a default view for a dashboard for a particular user? (but still have all the views visible)
ok, found the issue. It's been reported and fixed 2 weeks ago.. we're just waiting for a frontend update to include it: https://github.com/home-assistant/frontend/pull/15808
I want to create a tablet dashboard with the netflix, plex, youtube apps that are installed on the tablet. so for my use of it is - the kitchen area so once i walk into the kitchen the lights will turn on and the tablet will turn on the HA dashboard
is this possible
Yep
I get the whole turning on the light when motion is sense but how do I make the tablet turn on well wake up the tablet as if i passed by as well
Fully kiosk browser using an android or fire tablet
aaahh thats what i figured
No iPads
iPads are better for literally everything else tho
so i have a android tablet on the hallway between the rooms to open/close the garage and weather and shows date and time and the garage camera
but i want to create something similar to the kitchen tablet but showcasing the app that i use mostly on the HA dashboard.
so if i click on youtube, it opens up the youtube app on the tablet
basically a customize homescreen cuz i want the garage camere shown on the dashboard thats why
Hi guys. I recently installed multiple shutters powered by the fibaro roller shitter 3. Controlling them works, but the ui buttons always alternate between up and down. This means I must run them all the way down, before they can go up, but sometimes I want to move them up and down wothout goong all the way. Does anyone know how I get my covers to have both up and down buttons enabled at the same time, seems this should be simple. It works as expected woth services manually, so its just the ui
FYI: famous Sun Card is obsolete and replaced by Horizon Card fork.
(repo needs to be manually added as it's not in HACS default listing atm)
Make a template switch that calls button.press for the turn_on and turn_off. Use the garage door sensor as the state of the switch. #templates-archived can help.
It's a bug in the current release. Wait until the next (major) release.
It's not simple. If your device does not output a position but only an on/off state, HA does not know that it's in the middle of the transition. If you have multiple sensors, you can determine that it's in the middle if neither sensor sees the door. That would require using the cover template integration and some Jinja magic.
Is there anyway I can use my Flutter design as frontend?
Nope, you have to take your design and make it using CSS & custom cards
Hi i have setup a schedule helper that has the page with columns to select schedule. I am using this helper with an automation to turn on and off the Water Heater.
Issue is that the schedule helper columns page is not accessible to Users other than Administrator. Is there any workaround so that users can also access this column page to apply schedule as well.
I just want both buttons to be enabled, regardless of the state. I saw something about setting the assumed state attribute, but I cant say I got it to work
assumed state will do the same thing
So there is no simple solution? I use mushroom cards too, could it be a toggle there to just let the button stay enabled, regardless of state?
There is no simple solution
you can create 2 buttons
but you can't modify that control
I see, too bad
If I have not configured any themes, where would I add changes to the main theme to change the color values of a graph? In other words, I need to play with these values in the main theme: energy-grid-consumption-color: "#488fc2"
energy-grid-return-color: "#8353d1"
energy-solar-color: "#ff9800"
energy-non-fossil-color: "#0f9d58"
energy-battery-out-color: "#4db6ac"
energy-battery-in-color: "#f06292"
energy-gas-color: "#8E021b"
or is there a good video on how to manage the main theme?
This is probably not possible yet with how early Assist is. But is there anyway to get Assist to show when using kiosk mode? Or even better, the ability to open it with a button press in the dashboard itself?
It would be excellent to have it launch with a button press in the dashboard so I can keep that ugly header bar hidden from users
When displaying a dashboard, can i show the name of the Area the client is in?
I'm thinking something like this:
what hardware device is that?
Lenovo smart clock 2, HA sideloaded.
Don't know if you're in the USA, but here's a link:
Thx
can someone help me get my bearings around lovelace and buiding dashboards?
ive created a custom card in the www folder but using vscode im super confused at where to start making the lovelace dashboards. i added a lovelace.yaml but nothing i add to there makes a difference anywhere. I have 2 UI Lovelace Minimalist items in my sidebar that look like they have different content thats failing cause its an example. when i click edit in either of these dasboards i gett an msg that i cannot edit them in yaml mode. i dont know where that is set or where to actually start editing these dashboards? any suggestions?
You don't need to edit yaml if you don't want. If you go to a dashboard and click on the 3 dot menu in the top right, you can edit from there
i thought that would edit the built-in dashboards that are not as flexible as a lovelace? i think im very confused about the relations/difference between a lovelace or HA dashboard then?
once you are in there you can click the 3 dots again and select raw configuration editor
when you click Edit Dashboard whats it say?
try going to Settings, then Dashboards, then add Dashboard and try from that one
it lets me create HA dashboards, but i dont see anything that defines it as a lovelace
I'm believe that you want to move away from Lovelace yaml mode and start using the UI editor?
Lovelace doesn't mean what you think it means 😉
i would love to if i can find where its defined
ohhhhhhhh, tell me more Rosemary 🙂
so if its just integrated now, how do i add custom cards?
i feel like ive read things that say a million different ways to do it
I think you may need to do this:
Remove mode: yaml from configuration.yaml.
Restart Home Assistant.
Click the overflow menu (three vertical dots) in the UI’s top right-hand corner and select Configure UI.
Switch to Raw Editor mode
and none are correct
theres no yaml mode in my config
Hey all, could someone direct me how to stretch my Frigate Lovelace panel? I have it set to 4:3 but I'd love to have it stretched to fill the empty space at the sides. Thank you 🙌🙌
wouldn't it be fit: fill ?
correction object-fit: fill;
https://github.com/dermotduffy/frigate-hass-card#media-layout
i guess since lovelace is now integrated as the normal dashboards, how do i get it to recognize the card i just added to the www folder?
That worked. "fit: fill" - thank you so much 👍
Awesome, I guess I shouldn't have doubted myself the first time
If you were using the UI editor (when dashboard is open by selecting in sidebar and selecting 3 dots at top right, then Edit Dashboard) then there should be an +ADD CARD button bottom right
Right. The card I created doesn't appear there, that's why I started wondering if I wasn't understanding Lovelace vs HA
I put a .J's file in the www folder
see how the guest bedroom fan changes icon when it's turned on? is there any way that i can make lights do this without having to use conditional cards?
conditional cards make it impossible to use the header toggle feature of entities cards
Uses card-mod (https://github.com/thomasloven/lovelace-card-mod). (Don't mind the centering; looks fine on tablet.)```yaml
type: entities
entities:
- entity: light.hallway
card_mod:
style: |-
:host {
{% if is_state('light.hallway', 'off') %}
--card-mod-icon: mdi:light-switch-off;
{% else %}
--card-mod-icon: mdi:light-switch;
{% endif %}
}
this is perfect, thank you
Code above can also be used to answer this question. (I was trying to figure it out when you posted before but didn't have any luck.)
yeah this is amazing, tysm
Added some color since the button doesn't have any. ```yaml
type: entities
entities:
- entity: button.living_room_door_identify
card_mod:
style: |-
:host {
{% if is_state('light.hallway', 'off') %}
--card-mod-icon: mdi:light-switch-off;
--paper-item-icon-color: gray;
{% else %}
--card-mod-icon: mdi:light-switch;
--paper-item-icon-color: yellow;
{% endif %}
}```
@white turret Some cards are stylized differently that don't require card_mod. Mushroom chip card (via template) (there's a bug in the chip cards that don't like to style the icon last time I checked.)yaml type: custom:mushroom-template-card entity: sensor.fire_computer_desk_battery_level primary: '{{ states(''sensor.fire_computer_desk_battery_level'') }} %' icon: >- {{ is_state('binary_sensor.fire_computer_desk_plugged_in', 'on') | iif('mdi:battery', 'mdi:power-plug') }} icon_color: >- {{ is_state('binary_sensor.fire_computer_desk_plugged_in', 'on') | iif('red', 'green') }}
oh the card-mod thing is the first frontend thing i've installed from hacs
i'm not huge on making my dashboard look like it belongs on a design students portfolio
just wanted the icons to be a little more functional
check out button-card and mushroom card for a lot of possibilities.
@tribal galleon do you have any ideas why this wouldn't work? ```yaml
card_mod:
style:
div#wrapper: |-
state-badge {
animation: rotating 2s linear infinite;
}
@keyframes rotating {
0% {
transform: rotate(0deg);
}
100% {
transform: rotate(360deg);
}
}
nvm i got it working, sorry for ping
does anyone know how to display the full number?
the temperature is 12.4 instead of 2.4..
Please be aware there currently is an issue using custom cards in 2023.4 beta where changes in the Frontend cause several important custom cards to break. This is the case for at least: card-mod, button-card, decluttering-card and apexcharts-card. If you use those, please follow in #beta for updates on the matter. And do NOT install 2023.4.0b0 just yet
From https://community.home-assistant.io/t/custom-animated-weather-card-for-lovelace/58338/496
card_mod:
style: |
ha-card div.current span.temp {
font-size: 2.9em;
right: 1.25em;
top:0.8em;
}```
Wonder if changing font size from an em to px. Maybe iOS doesn't like the font size defined that way.
Hello, I am trying to make some changes to a custom card. I copied the card's JS into my ~/config/www, and I renamed the card and I'm able to see my JS loading instead of the one in HACS. But now, when I change the JS, it doesn't change what lovelace loads. If I use the browser's resource inspector, it seems like it's caching the first modified card's JS. What should I do to get the card to not be cacheD?
You can tell Chrome not to cache requests (network inspector, iirc) and force reload. I usually have to do it twice. PITA.
(Might be smarter ways. I hope there is 🙂
😦 thank you!
definitely a PITA
Has anyone implemented haptics for a custom lovelace card? I am trying to add haptic feedback, and it's not working. The documentation is...sparse...and I don't understand why what I'm doing doesn't result in a haptic firing
Disable cache on the networking tab and CTRL+F5 with dev tools open.
Also add a ? on your resource
path\to\custom\resource.js?
Nevermind, I figured out the haptic!
Thanks @tacit cave for helping me get a dev flow working
it's easy to fix things when it's possible to change them, lol
hey guys, not sure if this is the right channel but i'm looking for dashboard inspirations - preferably something that works nicely with mobile
the main issue i have at the moment is that i'm only just getting into HA now (just got some shelly relays installed so can finally do automation stuff)
the problem i'm facing is that most of my rooms only have a single light, but some have 2-3 things, and i don't know of a good way to display it all while still looking good?
i'm not good at making things look good, so anything you guys have is appreciated! thanks in advanced!
I love the new More Info sliders for lights ! Is there a way to display them directly in a Lovelace dashboard, as a card ? I'd like to have a few of these sliders side-by-side on a wall-mounted tablet.
Would be a nice idea
Here's how I do it personally.
Each room gets his own View in a dashboard, with the titles being icons only, no text.
The view is a "Masonry" view (the default), with a single vertical-stack card containing one card for each entity in this room. I personally uses the mushroom cards.
yeah, but the "circling" around the icon is not intuitive for non-everyday users. Right now I uses mushroom cards, with horizontal sliders (As shown in my example to Opaquer).
But these new sliders and on/off switches would be wonderful to replace that in some views.
I know, I like your idea 😎
when I add a new scene and click save, what do I do after to get it to show up?
Use scene.turn_on
where/how?
What are you trying to achieve exactly ? You've saved a scene, and you'd like to enable it under which circumstances ?
Ohh okay I tought you meant how to enable/activate the scene once it's been created.
Hmm it should show up directly after you've saved it. Are you getting an error when hitting save ?
the save button is disabled for a few seconds and then disappears
and it remains on the "new scene" page
response from the request is '{"result":"ok"}'
ok, it should return to the newly created scene after hitting save. Sounds odd. Try to check logs whern hitting save to see if you have any errors ?
Install the Log Viewer addons to see all logs in real time
Ah, I guess I need to switch to using a VM
@gritty loom I converted your message into a file since it's above 15 lines :+1:
The current action of this card opens a smaller window when tapped on, and then has an increment button. but i want it to increment directly from the tap action, is there a change i can make to my yaml to accomplish this? ☝️
Looking for some inspiration for controlling skylights and roller shades. Anyone got an awesome design/setup ?
does anyone know if its possible to get following in "auto entities"?
Id love to get this for all users.. And if its possible does anyone know how?^^
Theres something strange about my profile. The data wont load properly, seems like the UI is empty when i try to look at my profile. Anyone know how to fix this?
there's a couple of ways - one is to use the {{ user }} feature in templates, which tells you who the user is and then you can do if statements based on that
the other (which is what i've got) is using a text helper for each person with the name of the person's phone
then you can do something like this
{% set battery_percent = int(states('sensor.' + phone_name + '_battery_level'))//10 * 10 %}```
it gets the name of the phone based on the user's input text value, then gets the value of the battery based on that (or whatever you want to do with that info)
not sure if there's a better way, or how well this works (only have 1 user set up so far since i'm pretty new to HA), but that 1 user is working well so far
hey guys, is there a way to get something like this https://ui-lovelace-minimalist.github.io/UI/usage/cards/card_room/ without installing minimalist? i don't want to use minimalist for my whole theme, but do want something like this where there's extra buttons on the side that have extra actions
Sure, it’s just a custom button card…
Is there a gallery or something where frontend custom cards are showcased?
I'm looking for a nice, user-friendly time picker card, and I find a few when googling, but would be nice if I could filter, etc
Hacs
Ah ok, just checking the depositories there and searching. Will do thanks
Hmm, looks like there's no datetime picker card. Only time. Can of course add a "tomorrow" and work with that, but that seems like a lot of extra work 🙂
Can anyone point me in the right direction for a dynamic colouring of an apexchart? Basically I want the "value" part of this to be dynamic based on the values in the chart.
color_threshold:
- value: 0
color: green
opacity: 1
- value: 1
color: rgb(200,140,0)
- value: 2
color: rgb(180,0,0)
- value: 5
color: rgb(255,0,0)
I think I found something on the forum, but it's not working, but also no errors, so finding it hard to troubleshoot:
@upbeat geyser I converted your message into a file since it's above 15 lines :+1:
If I change the line with MOVINGAVERAGE.state to a number, it works fine. So I can't tell if it's going wrong where I'm setting the variable, or where I'm calling it.
Hey all, what am I doing wrong here?
Hi I'm trying to set a new tap action but for some reason it's not toggle my entity
tap_action:
service: switch.toggle
target:
entity_id: switch.tv_office
Is my syntax alright in this code?
what card is that?
because depending on that, you might need tap_action: action: call-service service: switch.toggle service_data: entity_id: > [[[ return variables.id; ]]] used in a custom:button-card, or check https://www.home-assistant.io/dashboards/actions/#tap_action on HA core entities
@mystic timber I converted your message into a file since it's above 15 lines :+1:
since you use main entity: input_select on the card, but action toggle the switch: why not use the entity: switch in the card? that way a click would by default toggle the switch, and no action needed
also, you could take out most of the styles section out of the state:...if the only change is color: yellow when on
Can I get this date/time picker as a card in a dashboard. The time picker card only has time...
Yeah but I want the color to remain gray if the device is not on 'ON' state.
I believe an input_datetime in an entities card row will have that datetime picker
all that is needed would be a template in that option then. [[[ return (entity.state === 'on') ? 'yellow' : 'grey'; ]]]
but why use the entity: input_select.office_tv_status?
are you selecting other tv status's too?
you'd have to set that to entity: switch.tv_office
let me try that.
testing...
Oh I get what you saying because it's a switch... problem is sometimes people turn on this specific TV by the remote and not by using the HA instance I got, so it won't show the TV as ON without that input_select
right, that was my question indeed 😉 yet, it doesnt matter for the styling
so how should I change it in your opinion?
@mystic timber I converted your message into a file since it's above 15 lines :+1:
This is the living room TV (using script in this one to turn it on/off)
well, always minimize yaml.
that's true, but what should I remove in my code to make it better?
in that button too, you duplicate most of your styles
take all that is not state dependent out of the states: section
@mystic timber I converted your message into a file since it's above 15 lines :+1:
or the other part
is there an actual switch? I mean, if one runs the script, is the actual switch toggled? or is it virtual
virtual
btw, please stop posting code blocks like that
it's a restful command actually
use a text file or code share site
its not me, its Discord rules here in the server 😉
btw if you use dpaste.org you can switch it to work up to one year. useful for others searching here after a while
but triggering the rest command does turn on/off the switch entity?
nope
there is no way to know if the tv is on or off without that helper that I used
(the input_select)
how does the helper get its state then?
@worthy falcon I converted your message into a file since it's above 15 lines :+1:
guess I dont get your hardware situation. Its a tv in standby, which can be toggled by a remote, and then you measure power consumption, if above 1 watt, its on, else off. Like that?
then what does the restful command do?
send the power command to the TV itself
by IR signal
which currently doing the Power button on my remote
so state is determined by power consumption?
yeah
right, then use that, easy too!
if it's more than 5 W for 7 seconds state is ON, if less than 4 W for 27 seconds state is OFF
.js Lovelace Coding question
not so easy....
well, do whatever you want, but I'd would simplify it with 50%.. as said, the action has nothing to do with the styling. If you can use state:, you can use a template on that same state
can you show me how then? because the way you showed me before won't work because I need that input_select to determine the state of the device to change the icon color
just add the service, and change the entity:
the beauty of button-card is, you can throw styles: card: - height: 100px icon: - width: 25% - opacity: 0.5 - padding-top: 10px - color: > [[[ return (entity.state === 'on') ? 'yellow' : 'grey'; ]]] name: - padding: 10px - font-size: 15px - text-overflow: unset - white-space: unset - word-break: break-word in a template and use that for all of you other cards there
nice
how can I make the color more bright to look yellow-ish like the living room icon?
delete the opacity/or change it
Thanks!
it the TV on vs the office off btw?
on vs other states
ah I see
all that would remain would be: type: custom:button-card entity: input_select.office_tv_status name: Office icon: mdi:television-classic template: switches tap_action: action: call-service service: switch.toggle target: entity_id: switch.tv_office
one step beyond that would be setting a variable on the service entity, and also take that config section to the template
but start with the base template first
Thanks !
I want to create a dashboard for my kitchen tablet, How do I about making a button to open an app such as Netflix, YouTube and etc. That's installed on the tablet.
Here's a good discussion that Google turned up: https://community.home-assistant.io/t/open-app-on-android-phone/375769
I'm trying to change font but on this card it isn't working
type: custom:mushroom-title-card title: Living subtitle: Mediacorner alignment: justify card_mod: style: | ha-card { font-size: 20px; font-weight: thin; font-family: 'Unbounded', cursive; letter-spacing: '-0.05em'; }
Any ideas?
what doesn't work?
it doesn't show the title and subtitle in the Unbounded font
Hi. How can I enlarge a card to full screen ?
to be more specific, do you want one card fullscreen all the time or a button to enlargen one you're looking at
I want one card fullscreen all the time
edit the view in the dashboard (top tab row) and select Panel (1 card)
I'm not so sure the mushroom-title-card makes use of ha-card. maybe check that first
I fixed it. Thanks
👍
@crisp rapids seems like the suggestion is to throw your card into another card like vertical-stack first? lol
and then style that
yeah tried that too
I guess you'll have to play around with it more since it can't find the element to path from. CSS fun
The downside to panel is it doesn’t scale well.. at all
i'm getting there @sonic rapids
Looks fine on a desktop in a browser.. on mobile it’s cancer
🙂
Mobile panel 😂
yikes lol
hmm yeah I guess if you had 5x grid cards so that mobile they'd scroll... but I think the desktop doesn't lay it out horizontally like that
lol I work in laying out stuff at work... reflow logic drives me nuts anyhow
Im using custom:button-card and trying to round a sensor to show 2 decimals. Can anybody help me with that?
This '[[[return Math.round(Number(entity.state)).toFixed(2);]]]' gives me "xx.00". The decimals is static 00
try it out in the dev tols templates first to make it easier but maybe something like entity.state | float | round(2) ?
oh wait this is JS isn't it lol
Thanks. I got it. '[[[return (Number(entity.state).toFixed(2));]]]'
Math.round() works fine, just dont use both methods together 😉 and they are not identical btw https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/round
Round wouldn't work as easily
You'd need to multiply first since it's integer rounding
Is there an easy way to get to text to speech on a speaker from a dashboard? Right now on my dashboard I have the speaker -> browse media -> text to speech -> google -> finally get to type the message -> say.
Lots of clicks.
I'm trying to make a simple card in a dashboard that exposes some sensors (perhaps also with a calculation in there). Shouldn't this simply work, or am I missing something simple?
type: custom:config-template-card
entities:
- sensor.mysensor
card:
type: custom:mushroom-template-card
primary: {{ now() }}
secondary: {{ state('sensor.mysensor') }}
icon: mdi:clock
Hey folks. Is there a way of renaming all entities of a device together?
I just renamed an auto-detected Sonos device in a new install, but only the display name changed. Same thing if I rename its primary media_player entity.
I believe there used to be an option to rename all entities along with the device (e.g. all the entities like number.tv_bass -> number.soundbar_bass)… did I imagine it? Did it move, or get removed? 😅
Hello, I have some buttons with an animated fan. I want to stop/start the animation based on a feedback entity, so whatever state that entity is in will start or stop 4 different buttons. Is this possible? I am using custom button card
Check out my message here for some code and video of state-based animation with a custom:button-card.
#1090840955185274920 message
Hi, I'm using the standard layout where I have four light entities, three show up on the first row and one on the second. Those are followed by a map card. Is there any way to have this map card take up the double horizontal space, so that it fills from left to right instead of an open space next to this map card as three cards show up per row?
Hi,
I would like to have an overview of all icons that are available in my HA. Does there exist a card that just adds all available icons to it (e.g. with the name as tooltip). This would be helpful to add to an invisible view to quickly scan for good icons 🙂
I can't find anything like it, but I suspect I'm not the first to have this problem 🙂
https://pictogrammers.com/library/mdi/ most are here
yes, the default ones, but I installed some extra as well. That's why I would like to have an overview on the ones in my HA. They are available in the dropdown (including) search of course. But a matrix which could be scanned quickly would sometimes be helpful
ah I see
Hi everyone!!
Can someone help me? How can I automatically change a title of a toggle when I turn on/off an automation in a climate card?
I tried this, but didn't work..
@unborn venture I converted your message into a file since it's above 15 lines :+1:
using the HA app to view on the tablet or is it better to use Full Kiosk
my fan light switch only has a toggle ability. is there any way to configure the entity so that if you press the off button and it's already "off" that it doesn't send any commands (since it actually turns the light on)
oh wait, it's a setting in my bond bridge for "trust tracked state"
Do you have the custom:button-card installed?
Or are you trying to use the apexcharts card?
Any idea??
qq, with the recent/coming changes to the frontend DOM. I was wondering, what is the reason for traversing the entire DOM with queryselectors? (in some custom cards / plugins) Is it because of the shadowroots, or because that's the only way to uniquely target something?
For example if I'd try to select all children of a custom:layout-card in grid mode, can I just select that element directly or does the shadowroot structure forbid that needing the full chain of correct queryselectors from outermost to what I'm targeting? (not sure where to post it, not really frontend related from a user perspective, probably more a generic frontend dev / js question)
yes
I put the apexcharts here
Can anyone assist me in (a link for) making a simple card on a dashboard that can put a state (or attribute) of an entity in a sentence? I gave it a go with what I could find online, but no luck yet.
No card type found refers to this line:
- type: "custom:button-card"
You get the error because in the GUI you don't need to add the hyphen before the type: key; like you would do if you use yaml-mode with a code-editor
So try instead:
type: "custom:button-card"
and adjust the spacing of the rest of the code accordingly
But based on your code that will also not work because you trying to use an ULM-card in the GUI which is not supported
Is there a way to get Max value+time and Min value+time in the top of an apexchart?
Or should I do this with template cards above the card?
button-card should be fixed in the latest button-card 3.5.0 release with the latest HA beta, it's using ha-drawer so update HA to the latest beta
(I'll go ahead and fix decluttering card + apexcharts-card tonight)
How do I create an button that can turn off/on lights scenes?
should just be a matter of setting the entity to the scene and most cards should just work
oddly enough, I created a button from a scene entity.. when the lights is OFF... when i press the button, it turns the scene lights ON
scenes only turn on
but need to know how to turn off the lights in that room
thanks that sorted that out...back to the drawing board
another question
I created a tablet dashboard and i have fully kiosk on it, how can I just show the dashboard on that tablet in my hallway
no sidebar and or top bar as well
nevermind - i found the frontend kiosk-mode
Kiosk mode is good for that! What I did was create a non-admin user which my dashboard uses, and then on your Dashboard go to the three dots at the top right > Edit Dashboard > three dots again > Raw configuration editor and put this at the very top of your config
kiosk_mode:
non_admin_settings:
kiosk: true
ignore_entity_settings: true
Then sign into your HA dashboard on the tablet 🙂
ah, well there's the ode anyway lmao
ill have to go that route then
ugh! getting this error - Unable to parse YAML: YAMLException: can not read an implicit mapping pair; a colon is missed (10:41) 7 | ... put_boolean.kiosk_mode: 'on" 8 | ... header: true 9 | ... ty: 10 | ... put_boolean.kiosk_mode: ' off' -----------------------------------------^ 11 | ... header: false 12 | ...
following Smart Home junkie video tutorial on this
try changing put_boolean.kiosk_mode: 'on" to put_boolean.kiosk_mode: "on"
not sure if that'll actually help but sometimes it gets confused with strings depending on how you quote things
kiosk_mode:
non_admin_settings:
kiosk: true
ignore_entity_settings: true
entity_settings:
- entity:
put_boolean.kiosk_mode: 'on"
hide_header: true
- entity:
put_boolean.kiosk_mode: ' off'
hide_header: false
like that?
kiosk_mode:
non_admin_settings:
kiosk: true
ignore_entity_settings: true
entity_settings:
- entity:
put_boolean.kiosk_mode: "on"
hide_header: true
- entity:
put_boolean.kiosk_mode: "off"
hide_header: false
like this
idk how you have it indented but make sure kiosk mode and entity_settings have the same indentation iirc
sorry still a bit new to this
all good, we've gotta start somewhere!
Unable to parse YAML: YAMLException: bad indentation of a mapping entry (8:3) 5 | entity_settings: 6 | - entity: 7 | put_boolean.kiosk_mode: "on" 8 | hide_header: true -------^ 9 | - entity: 10 | put_boolean.kiosk_mode: "off"
can you post your config here but with three ` s either side of it please?
apexcharts-card and decluttering-card also fixed for the latest beta. Please report back if it's still not working!
actually nevermind... i think i got it
noiceeee
on my tablet it doesnt show the sidebar or the top bar...
yep that’s kiosk mode!
good luck!
Got an idea and I'm trying to find the best way to incorporate it to my dashboard. I have 6 scripts being ran for fan control off an Rm4 Pro. They work fine, but having 6 scripts lined up in a dashboard is kind of ugly. Is there a way to change the title of a script, instead of 'run', to have an icon? Then I can have two lines and 3 icons per. Can send a picture if necessary
i'm gonna need it... i currently have the tablet next to me on an arm and messing with the dashboard on my pc, while trying to watch Rabbit Hole (tvshow)
how can i create a card bigger than its default
camera_view: live
type: picture-glance
entities: []
camera_image: camera.garage_camera
entity: cover.smart_garage_door_garage
tap_action:
action: toggle
hold_action:
action: none
how can i make this bigger
@faint rampart I've posted my entire dashboard if you want to see how I set up Kiosk Mode with entity settings.
will check it out and learn from it
onto my next thing
Check out https://www.home-assistant.io/dashboards/picture-glance/
Looks like it has settings for the aspect_ratio: ```aspect_ratio string (Optional)
Forces the height of the image to be a ratio of the width. Valid formats: Height percentage value (23%) or ratio expressed with colon or “x” separator (16:9 or 16x9). For a ratio, the second element can be omitted and will default to “1” (1.78 equals 1.78:1).```
hhhmmm
next question
how do i make a custom:digital-clock, the fonts to be bigger
It looks like that card doesn't have a lot a features and hasn't been updated in two years. But there is an issue posted that might help you. https://github.com/wassy92x/lovelace-digital-clock/issues/23#issuecomment-1242105626
what do you recommend for a digital clock card
I use a custom:button-card showing sensor.time (along with a templated sensor that I made for the date).
basically i want to maximize the space and not have black bars on the side
my picture glance is a live camera that i can toggle open/close the garage
is there a way to create a scene without changing the color temp in the UI?
Hi, i installed HA in Hyper-v VM and eneverything works except images. I alredy searched forums but nothing shows this specificaly. Any idea where the problem is?
Why didn’t you go wsl2?
how can I use a title to showcase the entity of a garage that its closed/closing or open/opening
The specifics depends on the card you're using. Here's an example using a custom:buttom-card. yaml type: custom:button-card entity: light.living_room1 name: '[[[ return entity.attributes.brightness]]]' show_icon: false
Got an idea and I'm trying to find the best way to incorporate it to my dashboard. I have 6 scripts being ran for fan control off an Rm4 Pro. They work fine, but having 6 scripts lined up in a dashboard is kind of ugly. Is there a way to change the title of a script, instead of 'run', to have an icon? Then I can have two lines and 3 icons per. Can send a picture if necessary (sent this about 7 hours ago, sorry for the repost)