/** * ----------------------------------------------------------------------------- * @package smartVISU * @author Martin Gleiß * @copyright 2012 - 2022 * @license GPL [http://www.gnu.de] * ----------------------------------------------------------------------------- */ /** * A widget to display messages received in json format * * @param {id=} unique id for this widget (optional) * @param {item(dict,list)} an item contaning messages in json Format * @param {text=title} a parameter name for the title (optional, default ='title') * @param {text=subtitle} a parameter name for the subtitle (optional, default ='subtitle') * @param {text=content} a parameter name for the message (optional, default ='content') * @param {text=level} a parameter name for the severity level (optional, default ='level') - corresponds to an icon and color to be defined in the language file * * @author Wolfram v. Hülsen based on a widget from Bonze */ {% macro activelist(id, item_messages, title, subtitle, content, level) %}
{{ text }}
{% endmacro %} /** * Displays a notification toast * * @param {id=} unique id for this widget(optional) If set, id is also used as class name for the dynamic toast and can be used for css styling. * @param {item(bool)} a trigger item (true to open, false to close) * @param {item(str)=} an item containing the title(optional) * @param {item(str)=} an item containing content (optional) * @param {item(str)=} an item containing an icon (optional) * @param {text=} title (optional) * @param {text=} plain text or html code as content (optional, default = '') * @param {text=} smartvisu icon to be used instead of the standard icons (info, warning, success, error). (optional, default = '') * @param {text=} standard template to be used (success, error, warning, info) (optional, default = '') * @param {item(bool, num, str, list)=} an item to send a value on button-press (optional, default = '') * @param {text=} button text (optional, default = '') button will show only if text is specified * @param {text=0} value to be sent when the button is pressed (optional, default = '0') * @param {text(false,true)=true} an option to close the toast manually (true, false) (optional, default = 'true') * @param {text=5000} time in miliseconds until toast will hide (optional, default = '5000'). 'false' makes it sticky * @param {text(plain,fade,slide)=slide} fade-in effect to show the toast (plain, fade, slide) (optional, default = 'slide') * @param {text(false,true)=true} option to display a bargraph loader (true, false) (optional, default = 'true') * @param {color=#9EC600} font color, not to be defined if a template is used (optional, default = '') * @param {color=gray} background color, not to be defined if a template is used (optional, default = 'gray') * @param {text=5} number of stacked toasts. 'false' to show one stack at a time / count showing the number of stacked toasts (optional, default = '5') * @param {text(left,center,right)=left} Alignment of text in the toast i.e. left, right, center (optional, default = 'left') * @param {text=} Toast position on display (optional, bottom-left, bottom-right, top-left, top-right....) (optional, default = 'bottom-left') * * @author bonze */ {% macro toast(id, item_trigger, item_title, item_content, item_icon, text_title, text_content, text_icon, param_template, item_button, text_button, value_button, param_allowclose, param_hideafter, param_showhide, param_showloader, param_color, param_bgColor, param_stack, param_align, param_position ) %} {% endmacro %}