{#
	This template is processed using the Twig template engine
	Learn more at: http://twig.sensiolabs.org/doc/templates.html

	You can override this output by copying this file into your
	theme's directory, in a subfolder named "wunderground". The
	path to the file would look like this:
	/wp-content/themes/my-theme/wunderground/example.html
#}

{# Escape the HTML in the passed data automatically #}
{% autoescape 'html' %}

<div class="wu-wrapper wu-table-vertical {{ class }}">

	{% include 'search-form.html' %}

	{% include 'alert.html' %}

	{% if wunderground.forecast.days is empty %}

		{{ strings.no_results }}

	{% else %}

		<div class="wu-forecast-wrapper">

			<table class="wu-table-{{numdays}}">
				<tbody>

					{% if showdata.current is not empty and wunderground.current_observation is not empty %}
						{% set forecast = wunderground.current_observation %}
						{% include 'table-vertical-row.html' %}
					{% endif %}

					{% for i in range( low = 0, high = (numdays - 1) ) %}

						{% set day = wunderground.forecast.days[i] %}
						{% set summary = day.summary %}
						{% set forecast = day.summary.day %}

						{% include 'table-vertical-row.html' %}

						{% if showdata.night is not empty and day.summary.night is not empty %}
							{% set forecast = day.summary.night %}
							{% include 'table-vertical-row.html' with { 'night' : true } %}
						{% endif %}

					{% endfor %}
				</tbody>
			</table>

		</div>

		{% include 'copyright.html' %}

	{# End if days in forecast #}
	{% endif %}

</div>

{% endautoescape %}
