--- a/svghmi/widget_jsontable.ysl2 Mon Nov 08 14:06:29 2021 +0100
+++ b/svghmi/widget_jsontable.ysl2 Mon Nov 08 14:09:44 2021 +0100
@@ -6,7 +6,7 @@
Send given variables as POST to http URL argument, spread returned JSON in
SVG sub-elements of "data" labeled element.
- Documentation to be written. see svbghmi exemple.
+ Documentation to be written. see svghmi exemple. shortdesc > Http POST variables, spread JSON back
@@ -151,15 +151,15 @@
template "svg:use", mode="json_table_elt_render" {
- // cloned element must be part of a HMI:List
+ // cloned element must be part of a HMI:List or a HMI:List const "targetid", "substring-after(@xlink:href,'#')";
const "from_list", "$hmi_lists[(@id | */@id) = $targetid]";
when "count($from_list) > 0" {
- | id("«@id»").setAttribute("xlink:href",
+ | id("«@id»").href.baseVal = // obtain new target id from HMI:List widget
- | "#"+hmi_widgets["«$from_list/@id»"].items[«$expressions/expression[1]/@content»]);
+ | "#"+hmi_widgets["«$from_list/@id»"].items[«$expressions/expression[1]/@content»]; warning > Clones (svg:use) in JsonTable Widget must point to a valid HMI:List widget or item. Reference "«@xlink:href»" is not valid and will not be updated.
--- a/svghmi/widget_list.ysl2 Mon Nov 08 14:06:29 2021 +0100
+++ b/svghmi/widget_list.ysl2 Mon Nov 08 14:09:44 2021 +0100
@@ -22,7 +22,7 @@
foreach "$hmi_element/*[@inkscape:label]" {
- | «@inkscape:label»: "«@id»",
+ | "«@inkscape:label»": "«@id»", --- a/svghmi/widget_switch.ysl2 Mon Nov 08 14:06:29 2021 +0100
+++ b/svghmi/widget_switch.ysl2 Mon Nov 08 14:09:44 2021 +0100
@@ -11,7 +11,7 @@
'"hello"' or '"hello"#another comment' match HMI_STRING 'hello'.
- shortdesc > Show elements whose label match value.
+ shortdesc > Show elements whose label matches value. // TODO: add optional format/precision argument to support floating points
// TODO: support (in)equations and ranges