thomasloven/lovelace-state-switch

State-Switch with Mushroom Cards - Doesnt render the full size

adirburke opened this issue · 2 comments

Hi

As you can see in the image below, the state-swtich (Garage) doesnt render the full size when used with a template mushroom card

Screenshot 2023-09-15 at 9 51 38 am

Code :

type: custom:state-switch
entity: user
states:
  Adir:
    type: custom:mushroom-template-card
    primary: Garage
    secondary: '{{ states[''sensor.state_of_garage_door''].state }}'
    icon: mdi:garage
    entity: switch.garage_control
    icon_color: |-
      {% if is_state('sensor.state_of_garage_door', 'Open') %}
      amber
      {% endif %}
    layout: vertical
    tap_action:
      action: navigate
      navigation_path: /lovelace/garage
    double_tap_action:
      action: toggle
    fill_container: true

Just run into the same issue. It looks like state_switch card messes "fill_container: true" settings.

sr01 commented

try wrapping a state with a grid, and set the grid square to true.