Visibility condition on specific TV source?

Hi
In Dashboard, i need to show badge only if tv source in live tv

in template this give me right value
{{ state_attr(“media_player.living_tv”, “source”) }}

Badge visibility conditions currently only look at states, not attributes.

Create a template binary sensor helper:

image

State template is:

{{ is_state_attr('media_player.living_tv', 'source', 'live_tv') }}

…with live_tv replaced by the value you actually get.

Then edit the badge visibility to incorporate this new sensor state:

image

1 Like