Fix indentation on clothing forecast template

This commit is contained in:
2025-08-16 18:18:05 -04:00
parent 1ea19c317c
commit 13ef9c58f8

View File

@@ -1322,39 +1322,43 @@ template:
{% else %} {% else %}
{% set temp = state_attr('weather.iron_nerd_weather_station','temperature')|round %} {% set temp = state_attr('weather.iron_nerd_weather_station','temperature')|round %}
{% endif %} {% endif %}
{%- if states('sensor.todays_high_temp')|int > 63 %} {% if states('sensor.todays_high_temp')|int > 63 %}
{%- if states('sensor.todays_high_temp')|int < 80 %} {% if states('sensor.todays_high_temp')|int < 80 %}
Nice Nice
{% elif states('sensor.todays_high_temp')|int > 90 %} {% elif states('sensor.todays_high_temp')|int > 90 %}
Hot Hot
{% else %} {% else %}
Toasty Toasty
{%- endif %} {% endif %}
{% elif states('sensor.todays_high_temp')|int < 64 %} {% elif states('sensor.todays_high_temp')|int < 64 %}
{%- if states('sensor.todays_high_temp')|int < 32 %} {% if states('sensor.todays_high_temp')|int < 32 %}
Freezing Freezing
{% elif states('sensor.todays_high_temp')|int > 48 %} {% elif states('sensor.todays_high_temp')|int > 48 %}
Chilly Chilly
{% else %} {% else %}
Cold Cold
{%- endif %} {% endif %}
{% else %} {% else %}
Unknown Unknown
{%- endif %} {% endif %}
- name: "Clothing Forecast Detail" - name: "Clothing Forecast Detail"
unique_id: 13065f50-5eef-4afd-830e-2a2c87f47496 unique_id: 13065f50-5eef-4afd-830e-2a2c87f47496
state: >- state: >-
{% from 'formatting.jinja' import cleanup %} {% from 'formatting.jinja' import cleanup %}
{%- macro getReport() -%} {% macro getReport() %}
{% set clothing = states('sensor.clothing_forecast') %}
{% set forecast = states('sensor.current_forecast') %}
{% set weather = states('weather.iron_nerd_weather_station') %}
{% set apparent = state_attr('weather.iron_nerd_weather_station','apparent_temperature') %}
{% if is_state('binary_sensor.morning','on') %} {% if is_state('binary_sensor.morning','on') %}
Based on the forecasted high temperature, Based on the forecasted high temperature,
{% if is_state('sensor.clothing_forecast', 'Freezing') %} {% if clothing == "Freezing" %}
You're gonna freeze your balls off out there. so I suggest wearing long pants and a heavy coat. You're gonna freeze your balls off out there. so I suggest wearing long pants and a heavy coat.
{% elif is_state('sensor.clothing_forecast','Cold') %} {% elif clothing == "Cold" %}
It's gonna be cold as balls today. so I suggest wearing long pants and a light jacket. It's gonna be cold as balls today. so I suggest wearing long pants and a light jacket.
{% elif is_state('sensor.clothing_forecast', 'Chilly') %} {% elif clothing == "Chilly" %}
It's gonna be on the chilly side today. so I suggest wearing at least long pants. It's gonna be on the chilly side today. so I suggest wearing at least long pants.
{% elif is_state('sensor.clothing_forecast', 'Nice') %} {% elif clothing == "Nice" %}
It is going to be It is going to be
{{ [ 'pretty nice outside. ', {{ [ 'pretty nice outside. ',
'a good day to be outside. ', 'a good day to be outside. ',