/** * ----------------------------------------------------------------------------- * @package smartVISU * @author Martin Gleiß * @copyright 2012 - 2015 * @license GPL [http://www.gnu.de] * ----------------------------------------------------------------------------- */ {% extends "index.html" %} {% import "popup.html" as popup %} {% block content %}

Popups

There are two popup widgets you can use for easier implementation of specific widgets. Motion sensor/light locks Popup
{% filter trim|escape|nl2br %}{% verbatim %} {{ basic.symbol('', ['item_lock', 'item_bwmlock', 'item_force'], '', 'secur_locked', 1, 'min', '', '#locks_popup', 'popup') }} {{ basic.symbol('', ['item_lock', 'item_bwmlock', 'item_force'], '', 'secur_open', 0, 'and', '', '#locks_popup', 'popup') }} {{ popup.locks('locks_popup', ['item_lock', ['green', 'red']], ['item_bwmlock', ['green', 'red']], ['item_force', 'red']) }} {% endverbatim %}{% endfilter %}
{{ basic.symbol('', ['item_lock', 'item_bwmlock', 'item_force'], '', 'secur_locked', 1, 'min', '', '#locks_popup', 'popup') }} {{ basic.symbol('', ['item_lock', 'item_bwmlock', 'item_force'], '', 'secur_open', 0, 'and', '', '#locks_popup', 'popup') }} {{ popup.locks('locks_popup', ['item_lock', ['green', 'red']], ['item_bwmlock', ['green', 'red']], ['item_force', 'red']) }}
Any simple widget in popup
{% filter trim|escape|nl2br %}{% verbatim %} Extended Popup {{ popup.extpopup('ext_popup', ['header', 'Suspendzeit'], ['plot', [['env.system.load','env.core.memory'],'avg', '1d', '', '', '', '',['system load', 'memory'],['#a00','#070'], '',['Time', 'CPU', 'Memory'],'', [1,2], [0,1],['#f00','#0a0']]], [['linetext', 'slider'], 'Slider', ['licht.modus.automatik.settings.suspendduration', '0', '100', '10', 'horizontal', 'handle']], [['symbol', 'slider'], ['item_lock', '', 'secur_locked', '1'], ['licht.modus.automatik.settings.suspendduration', '0', '100', '10', 'horizontal', 'handle']]) }} {% endverbatim %}{% endfilter %}
Extended Popup {{ popup.extpopup('ext_popup', ['header', 'Suspendzeit'], ['plot', [['env.system.load','env.core.memory'],'avg', '1d', '', '', '', '',['system load', 'memory'],['#a00','#070'], '',['Time', 'CPU', 'Memory'],'', [1,2], [0,1],['#f00','#0a0']]], [['linetext', 'slider'], 'Slider', ['licht.modus.automatik.settings.suspendduration', '0', '100', '10', 'horizontal', 'handle']], [['symbol', 'slider'], ['item_lock', '', 'secur_locked', '1'], ['licht.modus.automatik.settings.suspendduration', '0', '100', '10', 'horizontal', 'handle']]) }}
Here are some examples to show how popups are used.
Examples
A horizontal popup with some switches
{% filter trim|escape|nl2br %}{% verbatim %} Popup_1
{{ basic.stateswitch('', 'bath.light.switch', 'icon') }} {{ basic.stateswitch('', 'bath.light.switch', 'icon') }} {{ basic.stateswitch('', 'bath.light.switch', 'icon') }}
{% endverbatim %}{% endfilter %}
Popup_1
A vertical popup with some switches
{% filter trim|escape|nl2br %}{% verbatim %} Popup_2
{{ basic.stateswitch('', 'bath.light.switch', 'icon') }} {{ basic.stateswitch('', 'bath.light.switch', 'icon') }} {{ basic.stateswitch('', 'bath.light.switch', 'icon') }}
{% endverbatim %}{% endfilter %}
Popup_2
Individual size popup with a close button
{% filter trim|escape|nl2br %}{% verbatim %} Popup_3
Close Content
{% endverbatim %}{% endfilter %}
Popup_3
{% endblock %}