Blinkendes Badge-Icon

Philips Hue Wandschalter Modul, Doppelpack, ermöglicht ständige Erreichbarkeit von Hue Lampen, Installation hinter vorhandende Wandschalter, 2-er Pack, Weiß
Philips Hue Wandschalter Modul, Doppelpack, ermöglicht ständige Erreichbarkeit von Hue Lampen, Installation hinter vorhandende Wandschalter, 2-er Pack, Weiß
Unverb. Preisempf.: 79,99 €
59,99 €
Sie sparen 20,00 € (25%)

Wollt ihr eure Badges je nach Zustand „blinken“ lassen?
Das geht mit folgendem Code und custom:bade-card

type: custom:badge-card
name: neu
badges:
  - entity: sensor.wz_temp
    card_mod:
      style: |
        @keyframes blinker { 50% { opacity: 0; } }
        :host {
          {% if states(config.entity)|int > 29 %}
          --label-badge-background-color: red;
          --label-badge-text-color: white;
          animation: blinker 2s linear infinite;
          font-weight: bold;
          text-shadow: 1px 1px #0005;
          {% elif states(config.entity)|int > 27 %}
          --label-badge-background-color: #FF9800;
          --label-badge-text-color: white;
          --label-badge-red: #FF9800;
          font-weight: bold;
          text-shadow: 1px 1px #0005;
          {% elif states(config.entity)|int > 18 %}
          --label-badge-background-color: green;
          --label-badge-text-color: white;
          --label-badge-red: green;
          font-weight: bold;
          text-shadow: 1px 1px #0005;
          {% else %}
          --label-badge-background-color: #039BE5;
          --label-badge-text-color: white;
          --label-badge-red: #039BE5;
          font-weight: bold;
          text-shadow: 1px 1px #0005;
          animation: blinker 2s linear infinite;
          {% endif %}
        }