thomasloven / lovelace-state-switch

🔹Dynamically replace lovelace cards depending on occasion
MIT License
382 stars 27 forks source link

Using "transition" hides states with custom:mini-graph-card #91

Open arboeh opened 1 year ago

arboeh commented 1 year ago

I have a strange problem which I discovered solving another issue: Turning on transition hides the state-switch-card completely if using mini-graph-cards. I tried with quotes also. Without transition or with simple entities as states it works:

type: custom:state-switch
entity: sensor.power_mode
transition: flip
states:
  import:
    type: custom:mini-graph-card
    entities:
      - entity: sensor.shelly_3em_channel_a_power
  export:
    type: custom:mini-graph-card
    entities:
      - entity: sensor.shelly_3em_channel_a_power
ildar170975 commented 1 year ago

https://community.home-assistant.io/t/lovelace-mini-graph-card/71385/2182?u=ildar_gabdullin

shift-del1 commented 1 year ago

I tried state-switch with a picture glance and a thermostat entity, using transition with 1.9.5 resulted in the same "disappeared cards" effect. Rolling back to 1.9.3 I can still use transition with any cards.

UPDATE: embedding the state-switch card in a horizontal-stack card solved the issue. So I'm on 1.9.5, transition and box shadow both work properly.