Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- - platform: template
- sensors:
- placeholder:
- value_template: ' '
- sidebar_greeting:
- value_template: >
- {% set time = now().hour %}
- {% if time <= 1 %} Good night {{'\U0001F611'}}
- {% elif time <= 3 %} Good night {{'\U0001F62A'}}
- {% elif time <= 5 %} Good night {{'\U0001F634'}}
- {% elif time <= 7 %} Good morning {{'\U0001F4A9'}}
- {% elif time <= 9 %} Good morning {{'\u2615\uFE0F'}}
- {% elif time <= 10 %} Good morning {{'\U0001F642'}}
- {% elif time <= 12 %} Good afternoon {{'\U0001F60A'}}
- {% elif time <= 15 %} Good afternoon {{'\U0001F60E'}}
- {% elif time <= 17 %} Good afternoon {{'\U0001F44B\U0001F3FB'}}
- {% elif time <= 19 %} Good evening {{'\U0001F44B\U0001F3FB'}}
- {% elif time <= 22 %} Good evening {{'\U0001F60C'}}
- {% elif time <= 23 %} Good evening {{'\U0001F974'}}
- {% else %} Good evening {{'\U0001F974'}}
- {% endif %}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement