dylandoamaral / uptime-card

Minimalistic uptime card for Home Assistant Lovelace UI
266 stars 11 forks source link

Ignore unknown state / multiple states for ko and ok #134

Closed robertwigley closed 2 years ago

robertwigley commented 2 years ago

If a binary sensor becomes unknown e.g. during a reboot, the card shows the bar in yellow as a half state. This is not very helpful if you are trying to monitor the status of something and regularly reboot Home Assistant creating lots of unknown states. There needs to be a way to ignore those states and define them as either ko or ok. It would probably be easiest to just expand the current functionality of defining the ko and ok states to allow a list of states to be provided. e.g.

ko:
  - off
  - unknown
ok:
  - on
  - unavailable

Or

ko: 'off','unknown' ok: 'on','unavailable'