SVGHMI: move declaration of "xmlns" javascript const so that widgets can use it.
This was broken in earlier commit, when changing initial execution order because of implementing websocket reconnect.
--- a/svghmi/inline_svg.ysl2 Thu Nov 24 10:54:58 2022 +0100
+++ b/svghmi/inline_svg.ysl2 Thu Nov 24 11:47:56 2022 +0100
@@ -209,6 +209,7 @@
const "result_svg_ns", "exsl:node-set($result_svg)";
emit "preamble:inline-svg" {
+ | const xmlns = "http://www.w3.org/2000/svg";
| let id = document.getElementById.bind(document);
| var svg_root = id("«$svg/@id»");
}
--- a/svghmi/svghmi.js Thu Nov 24 10:54:58 2022 +0100
+++ b/svghmi/svghmi.js Thu Nov 24 11:47:56 2022 +0100
@@ -666,7 +666,6 @@
create_ws()
-const xmlns = "http://www.w3.org/2000/svg";
var edit_callback;
const localtypes = {"PAGE_LOCAL":null, "HMI_LOCAL":null}
function edit_value(path, valuetype, callback, initial) {