I have a card with some Broadlink IR control buttons and I want to show this card only if the user is home. So for example, I have two users: Tom and Chris.
If Tom is home and Chris is away: ā Show card to Tom, hide card from Chris
If Tom is away and Chris is home: ā Hide card from Tom, show card to Chris
Both are away: ā Hide card from both
Both are home ā Show card to both
So this is not only dependent on the current logged in user but also on the users state (home / away).
I donāt know how to do this. Can someone help me please.
Can this card use inside picture element? Currently Iām using conditional card but it giving lot of 0.0 error from time to time. I need a replacement option.
Hey guys,
I have a custom-buton-card that shows my tabletsā battery percentage. When I open the FullyKiosk on either of them or even on my computer, that button-card goes missing. When I go to another HA page and go back to the desired one, it appears and stays there. It looks that custom-state-switch can not figure out which user is active for the first time we open the HA in browser. - or Iām doing somthing wrong. Please take a look at my code below and tell where Iām wrong.
Actually at first I tried with deviceID and got the same behaviour. Then I created a user for each tablet and yet the same.
I have an issue with hash state-switch not working when inside custom:grid-layout. I can get it to work by manually typing in the #state in the URL, but only if I first use the state that is not assigned as default. Here is my code:
Further explanation of the issue:
When selecting the dashboard in lovelace or entering the dashboard URL into the browser, nothing loads in the state-switch area. When adding #rooms to the URL, again nothing loads. When adding #devices to the URL, the devices state will load. From there, I can then select the button created for #rooms and #media and those entities will load. I have also tested this by changing the default: state, which confirmed that the default will not load, even when initially manually putting the # in the URL. Iām not sure if itās a problem with my code or a problem with the state-switch card.
Hi! Is there an easy way to make the entity-buttons highlighted depending on the currently selected state?? I couldnāt find the answer here. In the readme, the animation shows exactly how I would want it to be (blue background of the selected state), but in the text (for hash), there is just some kind of dummy light switch entity for each of the buttonsā¦ that doesnāt work. These are then just normal buttons. Should we create a numeric input and somehow check for the value and then highlight the appropriate entity-button? Itās doable, not sure if thatās the prettiest solution. Thanks.
Iāve created radio buttons from multiple switches following this post:
ā¦and so pressing a button (the type has to be custom:button-card) the corresponding switch is turned on, all the rest of the buttons are turned off. The tap action should be something like this:
I think thatās still not the best solution. Thereās no way to dynamically set the default state value from eg. the current input_select option. Perhaps at least thereās a way to run a script on load which would toggle the switch of the selected default state right after the buttons card is loaded.
Even then that still wonāt be a perfect solution. For example, if someone else uses the HA simultaneously switching between the states it causes highlighting different buttons in your view even when no button is being pressed.
Is it possible to have multiple state-switch entities nested within each other? Currently Iām getting the second set of state-switch both showing the on and off state cards (so 2 cards per ui edit).
Started using this card and loving it. Just wondering if thereās an easy way to show the same cards for multiple states. i.e. for a media player state, I want the same cards to show whether the state is āonā, āplayingā, āpausedā, but different cards for āidleā and āoffā (I think).
Is there a way to have the same cards show for on, paused and playing, but not for off and idle?
My current work around is to have just āplayingā and āoffā as the specified state cards, and the default set as āplayingā, so that if the state is actually āpausedā it still shows the āplayingā cards.
The alternative I guess is to make a template binary sensor based on the states and reference that instead of the media player.
But this raises an error: No such file or directory: '/config/lovelace/media/remote_sources.yaml !include remote_dish.yaml'
Adding a newline between the !includes raises the same error.