Basic-Widgets

basic.button basic.checkbox basic.colordisc basic.dual basic.flip basic.float basic.formula basic.glue basic.multistate basic.rgb basic.shifter basic.shutter basic.slider basic.switch basic.symbol basic.tank basic.text basic.trigger basic.value


basic.symbol

A symbol, with no writing to knx, only displayed when the value of item is equal to val. Symbols may be used in menus. If more than one item is given, they will be combined with mode ('or' / 'and').

Parameters
{{ basic.symbol(id, items, txt, pic, val, mode, color) }}
id
unique id for this widget
items
one or more item(s). More items in array form: [ item1 , item2 ]
txt
the text, printed when item has value val (optional)
pic
the pic, shown when item has value val
val
value (default 1)
mode
the mode, 'or', 'and' (default 'or')
color
the color 'icon1' or e. g. '#f00' for red (default 'icon0' of the design)
Examples
Use this basic.flips (one for 'bath.light.switch' and the other for 'bath.rtr.state') to control the basic.symbol(s)
Symbol is only shown when 'bath.light.switch' = 1
{{ basic.symbol('s1', 'bath.light.switch') }}
With other pictures, in this example both val = 1 an val = 0 is shown.
{{ basic.symbol('s2', 'bath.light.switch', 'Light on', 'light_light.svg', '', '', 'icon1') }}
{{ basic.symbol('s3', 'bath.light.switch', 'Light off', 'light_light.svg', 0) }}
Light on Light off
With other highlight color (green, orange)
{{ basic.symbol('s4', 'bath.light.switch', '', 'light_light.svg', '', '', '#0b0') }}
{{ basic.symbol('s5', 'bath.light.switch', '', 'light_light.svg', '', '', '#fa3') }}
Symbol is shown when 'bath.light.switch' is on OR 'bath.rtr.state' is on.
{{ basic.symbol('s6', ['bath.light.switch', 'bath.rtr.state']) }}
Symbol is shown when 'bath.light.switch' is on AND 'bath.rtr.state' is on.
{{ basic.symbol('s7', ['bath.light.switch', 'bath.rtr.state'], '', '', 1, 'and', 'icon1') }}

Author: Martin GleiƟ and others

Widgets

Design

Misc