nervetattoo / banner-card

A fluffy banner card for Home Assistant 🥰
MIT License
604 stars 58 forks source link

Can't set icon to input_boolean entity #92

Open cvroque opened 4 years ago

cvroque commented 4 years ago

Hello,

First of all, thanks for this amazing add-on, it's made my HA interface pretty nice and simple to use!

Recently I've added an input_boolen as a 'Vacation Mode' toggle, and when it's 'on' I would like to add one icon (mdi:beach) to my dashboard. But no matter what option I try the input will always stay as a toggle!

I've tried icon, value, map_state and the toggle is always there without being overwritten.

image

Am I missing something? Should I just create a template sensor and move on?

I did see the release notes on 0.7.0 which is "Render input_boolean as a toggle" but I thought the overwrite option should still work.

Thanks in advance!

conradhagemans commented 3 years ago

Do something like this:


  - entity: binary_sensor.deursensor01
    name: Meterkast
    map_state:
      'on': 'mdi:door-open'
      'off': 'mdi:door-closed'
cvroque commented 3 years ago

Do something like this:

  - entity: binary_sensor.deursensor01
    name: Meterkast
    map_state:
      'on': 'mdi:door-open'
      'off': 'mdi:door-closed'

Thanks for the reply, unfortunately it still just shows as a toggle when dealing with a input_boolean, here's two examples:

image

image

The way I "fixed" it was creating a template based on this toggle to show the icon I wanted, but I believe the expected result is for the input_boolean to also accept an icon overwrite.

conradhagemans commented 3 years ago

Did you try to add domain: sensor To the entity

cvroque commented 3 years ago

I just added and then restarted for good measure, still the same, it seems to be fixed for input_boolean.

image image

julian100004 commented 1 year ago

Did you somehow manage to get it working? I also want to set custom text for a binary_sensor, but it's only working for input_booleans.