You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I've been thinking it would be useful to have some more options along the lines of hide_unavailable and think I've come up with a flexible solution although I've no experience in this kind of thing so just hoping it triggers some ideas.
Initially I was just going to propose hide_off: true/false to hide binary sensors where the state is equivalent to off. Then I got thinking it would be cool to be able to set thresholds for any sensor, and then I realised that "unavailable" is also a state so you could have a structure like this:
hide_if:
attribute: < optional attribute name, default to the main state >
value: < exact state/attribute value e.g. "off", "0", "on", "unavailable" >
above: < upper threshold for state/attr >
below: < lower threshold for state/attr >
I guess you could combine any given value/above/below combination as ORs although not sure how actually useful that would be.
It does lengthen the current hide_unavailable implementation somewhat but I think that seems a fair price for the added functionality, and maybe hide_unavailable could be kept in for a while to ease the transition.
The text was updated successfully, but these errors were encountered:
Some more overnight thoughts - might be useful to accept a list of values in the value field, so you could say "hide this if it's unavailable or turned off", and you could also combine with above/below to say something like "hide this if it's unavailable, turned off or the value is below 10" for example. Hope that makes sense!
Hi, I've been thinking it would be useful to have some more options along the lines of hide_unavailable and think I've come up with a flexible solution although I've no experience in this kind of thing so just hoping it triggers some ideas.
Initially I was just going to propose
hide_off: true/false
to hide binary sensors where the state is equivalent to off. Then I got thinking it would be cool to be able to set thresholds for any sensor, and then I realised that "unavailable" is also a state so you could have a structure like this:I guess you could combine any given value/above/below combination as ORs although not sure how actually useful that would be.
It does lengthen the current
hide_unavailable
implementation somewhat but I think that seems a fair price for the added functionality, and maybehide_unavailable
could be kept in for a while to ease the transition.The text was updated successfully, but these errors were encountered: