Add new weather data provider UK Met Office (Datapoint)

This commit is contained in:
Malcolm Oakes
2019-04-03 15:19:32 +01:00
parent b508a629e8
commit c80e04fe8d
12 changed files with 2664 additions and 1190 deletions

17
modules/default/weather/current.njk Normal file → Executable file
View File

@@ -9,7 +9,7 @@
{{ current.windSpeed | round }}
{% endif %}
{% if config.showWindDirection %}
<sup>
<sup>
{% if config.showWindDirectionAsArrow %}
<i class="fa fa-long-arrow-up" style="transform:rotate({{ current.windDirection }}deg);"></i>
{% else %}
@@ -56,11 +56,18 @@
</div>
{% endif %}
</div>
{% if config.showFeelsLike and not config.onlyTemp %}
{% if (config.showFeelsLike or config.showPrecipitationAmount) and not config.onlyTemp %}
<div class="normal medium">
<span class="dimmed">
{{ "FEELS" | translate }} {{ current.feelsLike() | roundValue | unit("temperature") | decimalSymbol }}
</span>
{% if config.showFeelsLike %}
<span class="dimmed">
{{ "FEELS" | translate }} {{ current.feelsLike() | roundValue | unit("temperature") | decimalSymbol }}
</span>
{% endif %}
{% if config.showPrecipitationAmount %}
<span class="dimmed">
{{ "PRECIP" | translate }} {{ current.precipitation | unit("precip") }}
</span>
{% endif %}
</div>
{% endif %}
{% else %}