Style a type:button entity-row?

I have this button:

button1

  - entity: water_heater.ecodan
    name: Extra varmvatten
    icon: mdi:water-pump
    type: button
    tap_action:
      action: call-service
      service: water_heater.set_operation_mode
      target:
        entity_id: water_heater.ecodan
      data:
        operation_mode: force_hot_water

It does indeed work. But I was wondering if there is a clever way to actually style it like a button? Instead of a “link” which does not look very intutive.

This is in the entities card, right? The type: button is a text button, according to the documentation (I would just call it a link, but whatever).

You have 2 options: either use the button card (not the entities card), or use type: buttons in the entities card, which creates buttons as icons, and you can have multiple in the same row. See the documentation with examples:

@Fanful was faster in writing. Sorry about that :sweat_smile:. But I think now we have 3 options :grinning:.

Hi Karl,

you have two options I know of:

  1. Using the entities card as you seem to do now you would need an HAOS custom component like the Paper buttons row to somehow design the card like a button. Above component can be installed using HACS.
  2. Or you don’t use the entites card but button cards. There are several options how to design them: E.g. using the sections layout dashboard view you can layout their size directly, with masonry you would need something like the Grid Card.

Ah exactly, it seems to work more or less like a link. I would prefer to have the button in the same card though.:grin:

Thank you, Paper buttons row is probalby what i am looking for ! Gonna test it now.

But doesn’t the buttons-type @Fanful mentioned just do what you wanted? As it seems Paper buttons row just gives you more options. It also visualizes the state…

See the example on the official docs using the buttons-type how the default type would look like and the possible options. It’s always a good thing to just use the basic HA things rather then custom components as they might break in the future.

@trallan
Go to the main card-mod thread - 1st post - link at the bottom titled “fantastic” - Entities card - styles for button row
image