Lovelace: mini graph card

How to set a color for the last bar:

  - type: custom:mini-graph-card
    entities:
      - entity: sensor.cleargrass_1_co2
    show:
      graph: bar
    card_mod:
      style: |
        rect.bar:last-of-type {
           fill: red;
        }

изображение

(as an answer for this issue)


More about card-mod.