flyrmyr / system-flow-card

A system flow card inspired by the official Energy Distribution card for Home Assistant
41 stars 2 forks source link

Card does not resize with elements used. #72

Open stav242 opened 10 months ago

stav242 commented 10 months ago

If the card has no top element, the card size does not adjust to fit the remaining elements and still shows a large empty space at the top of the card..

scantagithub commented 9 months ago

I confirm. is there a way to tell the card to resize relative to the contents??

seidler2547 commented 13 hours ago

Using card-mod I got this cobbled together to remove top and bottom parts:

card_mod:
  style: |
    div.card-content {
      padding-top:0px!important;
      padding-bottom:0px!important;
    }
    .spacer {
      height: 0px!important;
      padding: 0px!important;
    }
    svg {
      height: 200px!important;
      top:-95px!important;
      padding:0!important;
    }

Probably needs some more specific rules to only hide the top part.