/**
* -----------------------------------------------------------------------------
* @package smartVISU
* @author Martin Gleiß
* @copyright 2012 - 2015
* @license GPL [http://www.gnu.de]
* -----------------------------------------------------------------------------
*/
/**
* Displays the current weather at location
*
* @param {id} unique id for this widget
* @param {text=} location as string (optional)
* @param {duration=15i} the refresh interval for this widget using relative time format (optional, default 15i = 15 minutes)
* @param {item(num)=} item for temperature from backend (optional) will be displayed as value with unit 'temp'
* @param {item(num,str)=} item for wind speed from backend (optional) either as value or as text from backend
* @param {text=value} format for wind: 'value' = value with unit 'speed' or 'text' = text item from backend (optional, default='value')
* @param {item(num)=} item for an additional feature (e.g. humidity, rain or air pressure)
* @param {text=} leading text for additional feature
* @param {text=} format or unit for additional feature (e.g. '%','l/m²' or 'hPa') (optional)
* @param {item(num)=} item for a second additional feature (e.g. humidity, rain or air pressure)
* @param {text=} leading text for second additional feature
* @param {text=} format or unit for second additional feature (e.g. '%','l/m²' or 'hPa') (optional)
* @param {item(num)=} item for a third additional feature (e.g. humidity, rain or air pressure)
* @param {text=} leading text for third additional feature
* @param {text=} format or unit for third additional feature (e.g. '%', 'l/m²' or 'hPa') (optional)
*
* @info based on jDigiClock by Radoslav Dimov
* @link http://www.radoslavdimov.com
*/
{% macro current(id, location, repeat, itemtemp, itemwind, windfmt, itemhumi, humitxt, humifmt, itemmisc, misctxt, miscfmt, itemmisc1, misc1txt, misc1fmt) %}
{% set uid = uid(page, id) %}
{% if once('digiweather') %}
{% endif %}
{% endmacro %}
/**
* Displays the forecast weather of one day at location
*
* @param {id} unique id for this widget
* @param {text=} location as string (optional)
* @param {value=1} offset: 0 for today, 1 for tomorrow (default), 2 the day after tomorrow, ... (optional, default 1)
* @param {duration=3h} the refresh interval for this widget using relative time format (optional, default 3h)
*
* @info based on jDigiClock by Radoslav Dimov
* @link http://www.radoslavdimov.com
*/
{% macro forecast(id, location, day, repeat) %}
{% set uid = uid(page, id) %}
{% if once('digiweather') %}
{% endif %}
{% endmacro %}
/**
* Displays the forecast weather of the next 4 days
*
* @param {id} unique id for this widget
* @param {text=} location as string (optional)
* @param {duration=3h} the refresh interval for this widget using relative time format (optional, default 3h)
*
* @info based on jDigiClock by Radoslav Dimov
* @link http://www.radoslavdimov.com
*/
{% macro forecastweek(id, location, repeat) %}
{% set uid = uid(page, id) %}
{% if once('digiweather') %}
{% endif %}
{% endmacro %}
/**
* A Block with a map. The type specifies the kind of map.
*
* @param {id} unique id for this widget
* @param {text=} title of the block
* @param {text(day,night,forecast,wind,europe)} the mode: 'day', 'night', 'forecast', 'wind', 'europe'
*
* @info Maps from tagesschau.de, Hessischer Rundfunk, Deutscher Wetterdienst
* @link http://www.tagesschau.de
*/
{% macro map(id, title, mode) %}
{% import "@widgets/multimedia.html" as multimedia %}
{% endmacro %}
/**
* A block with some weather-maps in a slideshow
*
* @param {id} unique id for this widget
* @param {text=} title of the block
* @param {value=2} delay between the slides in sec (optional, default: 2 sec)
*
* @info based on cycle2 jquery-plugin: (c) 2012 M. Alsup; Dual licensed: MIT/GPL
* @link http://jquery.malsup.com/cycle2
*/
{% macro mapslides(id, title, delay) %}
{% set uid = uid(page, id) %}