hello I need help, I’m trying to make a card on the panel with an automation, in it I use the entity field and I’m trying to change the person according to the connected profile
Is there a way for the dashboard to identify which user is logged in? if so how would i do that, currently i tried this code but it didn’t work
entity: |-
{% if is('person.lucas') %}
person.lucas
{% elif is('person.renato') %}
person.renato
{% elif is('person.lilian') %}
person.lilian
{% else %}
person.painel
{% endif %}
a version of the code that worked was this
badge_icon: |-
{% if is_state('person.lucas','home') %}
mdi:home
{% elif is_state('person.renato','home') %}
mdi:home
{% elif is_state('person.lilian','home') %}
mdi:home
{% else %}
mdi:home-assistant
{% endif %}
but what I want to do, I imagine that the panel needs to identify which user is logged in, if it has any code that I can use to pull this information?