Creative Button Card Templates for Lovelace Dashboards

Thanks @Kanecaine,

I feel as though your questions would be far better suited to this topic on button-card however seem as you’re here you could try this:

Rather than use grid_gap you could change the grid-template-columns property to use percentages rather than fractions and change the grid-template-areas to have a blank section, you shouldn’t need to use the aspect_ratio as the card contents should size appropriately for the width. For example:

grid:
  - grid-template-areas: |
      "light1 . light2"
  - grid-template-columns: 68% 4% 28%
  - grid-template-rows: 1fr
# ...

Or change those percentages for whatever works for you. You could also just use a margin in the styles for both custom fields and have the areas set to 70% 30% and let CSS figure it out. Disclaimer: I haven’t tested that code but in theory it should work.

That said, if you are only doing this for layout and the main button doesn’t have a function then why not use a horizontal-stack and set the width of one of the cards with a percentage?

Or just use my light_group template and let it figure it out for you. :wink: