@bldgblocks/node-red-contrib-control 0.1.32 → 0.1.34

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (72) hide show
  1. package/nodes/accumulate-block.html +1 -1
  2. package/nodes/add-block.html +1 -1
  3. package/nodes/analog-switch-block.html +1 -1
  4. package/nodes/and-block.html +1 -1
  5. package/nodes/average-block.html +1 -1
  6. package/nodes/boolean-switch-block.html +1 -1
  7. package/nodes/boolean-to-number-block.html +1 -1
  8. package/nodes/cache-block.html +1 -1
  9. package/nodes/call-status-block.html +1 -1
  10. package/nodes/changeover-block.html +1 -1
  11. package/nodes/comment-block.html +1 -1
  12. package/nodes/compare-block.html +1 -1
  13. package/nodes/contextual-label-block.html +1 -1
  14. package/nodes/convert-block.html +1 -1
  15. package/nodes/count-block.html +2 -2
  16. package/nodes/delay-block.html +1 -1
  17. package/nodes/divide-block.html +1 -1
  18. package/nodes/edge-block.html +1 -1
  19. package/nodes/enum-switch-block.html +1 -1
  20. package/nodes/frequency-block.html +1 -1
  21. package/nodes/global-getter.html +34 -3
  22. package/nodes/global-getter.js +73 -70
  23. package/nodes/global-setter.html +21 -10
  24. package/nodes/global-setter.js +130 -103
  25. package/nodes/history-collector.html +283 -0
  26. package/nodes/history-collector.js +150 -0
  27. package/nodes/history-config.html +236 -0
  28. package/nodes/history-config.js +8 -0
  29. package/nodes/hysteresis-block.html +1 -1
  30. package/nodes/interpolate-block.html +1 -1
  31. package/nodes/latch-block.html +1 -1
  32. package/nodes/load-sequence-block.html +1 -1
  33. package/nodes/max-block.html +1 -1
  34. package/nodes/memory-block.html +1 -1
  35. package/nodes/min-block.html +1 -1
  36. package/nodes/minmax-block.html +1 -1
  37. package/nodes/modulo-block.html +1 -1
  38. package/nodes/multiply-block.html +1 -1
  39. package/nodes/negate-block.html +1 -1
  40. package/nodes/network-point-registry.html +86 -0
  41. package/nodes/network-point-registry.js +90 -0
  42. package/nodes/network-read.html +56 -0
  43. package/nodes/network-read.js +57 -0
  44. package/nodes/network-register.html +110 -0
  45. package/nodes/network-register.js +112 -0
  46. package/nodes/network-write.html +65 -0
  47. package/nodes/network-write.js +83 -0
  48. package/nodes/nullify-block.html +1 -1
  49. package/nodes/on-change-block.html +1 -1
  50. package/nodes/oneshot-block.html +1 -1
  51. package/nodes/or-block.html +1 -1
  52. package/nodes/pid-block.html +1 -1
  53. package/nodes/priority-block.html +1 -1
  54. package/nodes/rate-limit-block.html +2 -2
  55. package/nodes/rate-of-change-block.html +1 -1
  56. package/nodes/rate-of-change-block.js +5 -2
  57. package/nodes/round-block.html +6 -5
  58. package/nodes/round-block.js +5 -3
  59. package/nodes/saw-tooth-wave-block.html +2 -2
  60. package/nodes/scale-range-block.html +1 -1
  61. package/nodes/sine-wave-block.html +2 -2
  62. package/nodes/string-builder-block.html +1 -1
  63. package/nodes/subtract-block.html +1 -1
  64. package/nodes/thermistor-block.html +1 -1
  65. package/nodes/tick-tock-block.html +2 -2
  66. package/nodes/time-sequence-block.html +1 -1
  67. package/nodes/triangle-wave-block.html +2 -2
  68. package/nodes/tstat-block.html +1 -1
  69. package/nodes/units-block.html +8 -38
  70. package/nodes/units-block.js +3 -42
  71. package/nodes/utils.js +70 -1
  72. package/package.json +11 -4
@@ -15,7 +15,7 @@
15
15
 
16
16
  <script type="text/javascript">
17
17
  RED.nodes.registerType("accumulate-block", {
18
- category: "control",
18
+ category: "bldgblocks control",
19
19
  color: "#301934",
20
20
  defaults: {
21
21
  name: { value: "" },
@@ -11,7 +11,7 @@
11
11
 
12
12
  <script type="text/javascript">
13
13
  RED.nodes.registerType("add-block", {
14
- category: "control",
14
+ category: "bldgblocks control",
15
15
  color: "#301934",
16
16
  defaults: {
17
17
  name: { value: "" },
@@ -13,7 +13,7 @@
13
13
  <!-- JavaScript Section: Registers the node and handles editor logic -->
14
14
  <script type="text/javascript">
15
15
  RED.nodes.registerType("analog-switch-block", {
16
- category: "control",
16
+ category: "bldgblocks control",
17
17
  color: "#301934",
18
18
  defaults: {
19
19
  name: { value: "" },
@@ -11,7 +11,7 @@
11
11
 
12
12
  <script type="text/javascript">
13
13
  RED.nodes.registerType("and-block", {
14
- category: "control",
14
+ category: "bldgblocks control",
15
15
  color: "#301934",
16
16
  defaults: {
17
17
  name: { value: "" },
@@ -21,7 +21,7 @@
21
21
 
22
22
  <script type="text/javascript">
23
23
  RED.nodes.registerType("average-block", {
24
- category: "control",
24
+ category: "bldgblocks control",
25
25
  color: "#301934",
26
26
  defaults: {
27
27
  name: { value: "" },
@@ -9,7 +9,7 @@
9
9
  <!-- JavaScript Section -->
10
10
  <script type="text/javascript">
11
11
  RED.nodes.registerType("boolean-switch-block", {
12
- category: "control",
12
+ category: "bldgblocks control",
13
13
  color: "#301934",
14
14
  defaults: {
15
15
  name: { value: "" },
@@ -13,7 +13,7 @@
13
13
  <!-- JavaScript Section -->
14
14
  <script type="text/javascript">
15
15
  RED.nodes.registerType("boolean-to-number-block", {
16
- category: "control",
16
+ category: "bldgblocks control",
17
17
  color: "#301934",
18
18
  defaults: {
19
19
  name: { value: "" },
@@ -13,7 +13,7 @@
13
13
  <!-- JavaScript Section: Registers the node and handles editor logic -->
14
14
  <script type="text/javascript">
15
15
  RED.nodes.registerType("cache-block", {
16
- category: "control",
16
+ category: "bldgblocks control",
17
17
  color: "#301934",
18
18
  defaults: {
19
19
  name: { value: "" },
@@ -33,7 +33,7 @@
33
33
  <!-- JavaScript Section: Registers the node and handles editor logic -->
34
34
  <script type="text/javascript">
35
35
  RED.nodes.registerType("call-status-block", {
36
- category: "control",
36
+ category: "bldgblocks control",
37
37
  color: "#301934",
38
38
  defaults: {
39
39
  name: { value: "" },
@@ -93,7 +93,7 @@
93
93
 
94
94
  <script type="text/javascript">
95
95
  RED.nodes.registerType("changeover-block", {
96
- category: "control",
96
+ category: "bldgblocks control",
97
97
  color: "#301934",
98
98
  defaults: {
99
99
  name: { value: "" },
@@ -19,7 +19,7 @@
19
19
 
20
20
  <script type="text/javascript">
21
21
  RED.nodes.registerType("comment-block", {
22
- category: "control",
22
+ category: "bldgblocks control",
23
23
  color: "#301934",
24
24
  defaults: {
25
25
  name: { value: "comment" },
@@ -13,7 +13,7 @@
13
13
  <!-- JavaScript Section: Registers the node and handles editor logic -->
14
14
  <script type="text/javascript">
15
15
  RED.nodes.registerType("compare-block", {
16
- category: "control",
16
+ category: "bldgblocks control",
17
17
  color: "#301934",
18
18
  defaults: {
19
19
  name: { value: "" },
@@ -15,7 +15,7 @@
15
15
 
16
16
  <script type="text/javascript">
17
17
  RED.nodes.registerType("contextual-label-block", {
18
- category: "control",
18
+ category: "bldgblocks control",
19
19
  color: "#301934",
20
20
  defaults: {
21
21
  name: { value: "" },
@@ -58,7 +58,7 @@
58
58
 
59
59
  <script type="text/javascript">
60
60
  RED.nodes.registerType("convert-block", {
61
- category: "control",
61
+ category: "bldgblocks control",
62
62
  color: "#301934",
63
63
  defaults: {
64
64
  name: { value: "" },
@@ -9,7 +9,7 @@
9
9
  <!-- JavaScript Section: Registers the node and handles editor logic -->
10
10
  <script type="text/javascript">
11
11
  RED.nodes.registerType("count-block", {
12
- category: "control",
12
+ category: "bldgblocks control",
13
13
  color: "#301934",
14
14
  defaults: {
15
15
  name: { value: "" }
@@ -18,7 +18,7 @@
18
18
  outputs: 1,
19
19
  inputLabels: ["input"],
20
20
  outputLabels: ["count"],
21
- icon: "font-awesome/fa-tally",
21
+ icon: "font-awesome/fa-calculator",
22
22
  paletteLabel: "count",
23
23
  label: function() {
24
24
  return this.name || "count";
@@ -33,7 +33,7 @@
33
33
  <!-- JavaScript Section: Registers the node and handles editor logic -->
34
34
  <script type="text/javascript">
35
35
  RED.nodes.registerType("delay-block", {
36
- category: "control",
36
+ category: "bldgblocks control",
37
37
  color: "#301934",
38
38
  defaults: {
39
39
  name: { value: "" },
@@ -11,7 +11,7 @@
11
11
 
12
12
  <script type="text/javascript">
13
13
  RED.nodes.registerType("divide-block", {
14
- category: "control",
14
+ category: "bldgblocks control",
15
15
  color: "#301934",
16
16
  defaults: {
17
17
  name: { value: "" },
@@ -16,7 +16,7 @@
16
16
  <!-- JavaScript Section -->
17
17
  <script type="text/javascript">
18
18
  RED.nodes.registerType("edge-block", {
19
- category: "control",
19
+ category: "bldgblocks control",
20
20
  color: "#301934",
21
21
  defaults: {
22
22
  name: { value: "" },
@@ -31,7 +31,7 @@
31
31
 
32
32
  <script type="text/javascript">
33
33
  RED.nodes.registerType("enum-switch-block", {
34
- category: "control",
34
+ category: "bldgblocks control",
35
35
  color: "#301934",
36
36
  defaults: {
37
37
  name: { value: "" },
@@ -9,7 +9,7 @@
9
9
  <!-- JavaScript Section: Registers the node and handles editor logic -->
10
10
  <script type="text/javascript">
11
11
  RED.nodes.registerType("frequency-block", {
12
- category: "control",
12
+ category: "bldgblocks control",
13
13
  color: "#301934",
14
14
  defaults: {
15
15
  name: { value: "" }
@@ -26,7 +26,7 @@
26
26
  </div>
27
27
 
28
28
  <div class="form-row">
29
- <label for="node-input-detail"><i class="fa fa-bolt"></i> Trigger</label>
29
+ <label for="node-input-detail"><i class="fa fa-book"></i> Detail</label>
30
30
  <select id="node-input-detail" style="width: 70%;">
31
31
  <option value="getValue">Get Simple Value</option>
32
32
  <option value="getObject">Get Full Object</option>
@@ -40,7 +40,7 @@
40
40
 
41
41
  <script type="text/javascript">
42
42
  RED.nodes.registerType('global-getter', {
43
- category: 'control',
43
+ category: "bldgblocks control",
44
44
  color: '#3FADB5',
45
45
  defaults: {
46
46
  name: { value: "" },
@@ -56,7 +56,7 @@
56
56
  if (this.targetNode) {
57
57
  const target = RED.nodes.node(this.targetNode);
58
58
  if (target) {
59
- let lbl = target.path || target.name;
59
+ let lbl = target.name || target.path;
60
60
  if(lbl && lbl.startsWith("#") && lbl.includes(":")) {
61
61
  lbl = lbl.substring(lbl.indexOf(":") + 1);
62
62
  }
@@ -99,3 +99,34 @@
99
99
  }
100
100
  });
101
101
  </script>
102
+
103
+ <!-- Help Section -->
104
+ <script type="text/markdown" data-help-name="global-setter">
105
+ Manage a global variable in a repeatable way.
106
+
107
+ ### Inputs
108
+ Retreived object will overwrite msg.
109
+
110
+ ### Outputs
111
+ : payload (object) : The stored object with values and metadata.
112
+
113
+ ### Details
114
+ Global variables are meant to be retrieved in other places, this necessarily means managing the same string in multiple places.
115
+
116
+ This node allows you to get a global variable anywhere from one source, while supporting rename and deletion.
117
+
118
+ The source can be found using the search button. The payload property can be specified and can be set to only the value for chaining.
119
+
120
+ Reactive updates means every time the source is updated those nodes will receive the new value via event.
121
+
122
+ ### Status
123
+ - Green (dot): Configuration update
124
+ - Blue (dot): State changed
125
+ - Blue (ring): State unchanged
126
+ - Red (ring): Error
127
+ - Yellow (ring): Warning
128
+
129
+ ### References
130
+ - [Node-RED Documentation](https://nodered.org/docs/)
131
+ - [GitHub Repository](https://github.com/BldgBlocks/node-red-contrib-buildingblocks-control.git)
132
+ </script>
@@ -1,4 +1,5 @@
1
1
  module.exports = function(RED) {
2
+ const utils = require('./utils')(RED);
2
3
  function GlobalGetterNode(config) {
3
4
  RED.nodes.createNode(this, config);
4
5
  const node = this;
@@ -6,75 +7,62 @@ module.exports = function(RED) {
6
7
  node.outputProperty = config.outputProperty || "payload";
7
8
  node.updates = config.updates;
8
9
  node.detail = config.detail;
9
-
10
+
10
11
  let setterNode = null;
11
- let retryInterval = null;
12
+ let retryAction = null;
13
+ let healthCheckAction = null;
12
14
  let updateListener = null;
13
15
  let retryCount = 0;
14
16
  const retryDelays = [0, 100, 500, 1000, 2000, 4000, 8000, 16000];
15
17
  const maxRetries = retryDelays.length - 1;
16
18
 
17
- // --- HELPER: Process Wrapper and Send Msg ---
18
- function sendValue(storedObject, msgToReuse) {
19
+ // --- Output Helper ---
20
+ function sendValue(storedObject, msgToReuse, done) {
19
21
  const msg = msgToReuse || {};
20
22
 
21
23
  if (storedObject !== undefined && storedObject !== null) {
22
-
23
- // CHECK: Is this our Wrapper Format? (Created by Global Setter)
24
- if (storedObject && typeof storedObject === 'object' && storedObject.hasOwnProperty('value')) {
25
-
26
- // 1. Separate the Value from everything else (Rest operator)
27
- // 'attributes' will contain: priority, units, metadata, topic, etc.
28
- const { value, ...attributes } = storedObject;
29
-
30
- // 2. Set the Main Output (e.g. msg.payload = 75)
31
- RED.util.setMessageProperty(msg, node.outputProperty, value);
32
-
33
- // 3. Merge all attributes onto the msg root
34
- // This automatically handles priority, units, metadata, and any future fields
24
+ // Check if this is our custom wrapper object
25
+ if (storedObject && typeof storedObject === 'object' && storedObject.hasOwnProperty('value')) {
35
26
  if (node.detail === "getObject") {
36
- Object.assign(msg, attributes);
27
+ Object.assign(msg, storedObject);
37
28
  }
38
-
29
+ RED.util.setMessageProperty(msg, node.outputProperty, storedObject.value);
39
30
  } else {
40
- // Handle Legacy/Raw values (not created by your Setter)
31
+ // Legacy/Raw values
41
32
  RED.util.setMessageProperty(msg, node.outputProperty, storedObject);
42
33
  msg.metadata = { path: setterNode ? setterNode.varName : "unknown", legacy: true };
43
34
  }
44
35
 
45
- // Visual Status
46
- const valDisplay = RED.util.getMessageProperty(msg, node.outputProperty);
47
- node.status({ fill: "blue", shape: "dot", text: `get: ${valDisplay}` });
36
+ let valDisplay = RED.util.getMessageProperty(msg, node.outputProperty);
37
+ valDisplay = typeof valDisplay === "number" ? valDisplay : valDisplay;
48
38
 
49
- node.send(msg);
50
-
39
+ utils.sendSuccess(node, msg, done, `get: ${valDisplay}`, null, "dot");
51
40
  } else {
52
- node.status({ fill: "red", shape: "ring", text: "global variable undefined" });
41
+ utils.sendError(node, msg, done, "global variable undefined");
53
42
  }
54
43
  }
55
44
 
56
- // --- HELPER: Manage Event Subscription ---
45
+ // --- Connection Logic ---
57
46
  function establishListener() {
58
47
  setterNode = RED.nodes.getNode(node.targetNodeId);
59
48
 
60
49
  if (setterNode && setterNode.varName && node.updates === 'always') {
61
50
  if (updateListener) {
62
- // Remove existing listener if we're retrying
63
51
  RED.events.removeListener("bldgblocks-global-update", updateListener);
64
52
  }
65
53
 
66
54
  updateListener = function(evt) {
67
55
  if (evt.key === setterNode.varName && evt.store === setterNode.storeName) {
68
- sendValue(evt.data, {});
56
+ // Event Trigger: Pass null for done, as it's not a node input
57
+ sendValue(evt.data, {}, null);
69
58
  }
70
59
  };
71
60
 
72
61
  RED.events.on("bldgblocks-global-update", updateListener);
73
62
 
74
- // Clear retry interval once successful
75
- if (retryInterval) {
76
- clearInterval(retryInterval);
77
- retryInterval = null;
63
+ if (retryAction) {
64
+ clearInterval(retryAction);
65
+ retryAction = null;
78
66
  }
79
67
 
80
68
  node.status({ fill: "green", shape: "dot", text: "Connected" });
@@ -83,52 +71,67 @@ module.exports = function(RED) {
83
71
  return false;
84
72
  }
85
73
 
86
- // --- HANDLE MANUAL INPUT ---
87
- node.on('input', function(msg, send, done) {
74
+ function startHealthCheck() {
75
+ const check = () => {
76
+ const listeners = RED.events.listeners("bldgblocks-global-update");
77
+ const hasOurListener = listeners.includes(updateListener);
78
+ if (!hasOurListener) {
79
+ node.warn("Event listener lost, reconnecting...");
80
+ if (establishListener()) {
81
+ node.status({ fill: "green", shape: "dot", text: "Reconnected" });
82
+ }
83
+ }
84
+ setTimeout(check, 30000);
85
+ };
86
+ setTimeout(check, 30000);
87
+ }
88
+
89
+ function subscribeWithRetry() {
90
+ retryAction = () => {
91
+ if (retryCount >= maxRetries) {
92
+ utils.sendError(node, null, null, "Connection failed");
93
+ return;
94
+ }
95
+ if (establishListener()) {
96
+ retryCount = 0;
97
+ return;
98
+ }
99
+ retryCount++;
100
+ setTimeout(retryAction, retryDelays[Math.min(retryCount, maxRetries - 1)]);
101
+ };
102
+ setTimeout(retryAction, retryDelays[0]);
103
+ }
104
+
105
+ // --- INPUT HANDLER ---
106
+ node.on('input', async function(msg, send, done) {
88
107
  send = send || function() { node.send.apply(node, arguments); };
89
108
 
90
- if (setterNode && setterNode.varName) {
91
- const globalContext = node.context().global;
92
- const storedObject = globalContext.get(setterNode.varName, setterNode.storeName);
93
- sendValue(storedObject, msg);
94
- } else {
95
- node.warn("Source node not found or not configured.");
96
- node.status({ fill: "red", shape: "ring", text: "Source node not found" });
109
+ try {
110
+ setterNode ??= RED.nodes.getNode(node.targetNodeId);
111
+
112
+ if (setterNode && setterNode.varName) {
113
+ // Async Get
114
+ const storedObject = await utils.getGlobalState(node, setterNode.varName, setterNode.storeName);
115
+ sendValue(storedObject, msg, done);
116
+ } else {
117
+ node.warn("Source node not found or not configured.");
118
+ utils.sendError(node, msg, done, "Source node not found");
119
+ }
120
+ } catch (err) {
121
+ node.error(err);
122
+ utils.sendError(node, msg, done, `Internal Error: ${err.message}`);
97
123
  }
98
-
99
- if (done) done();
100
124
  });
101
125
 
102
- // --- HANDLE REACTIVE UPDATES ---
126
+ // --- INIT ---
103
127
  if (node.updates === 'always') {
104
- if (!establishListener()) {
105
- // Recursive retry
106
- const retry = () => {
107
- if (retryCount >= maxRetries) {
108
- node.error("Failed to connect to setter node after multiple attempts");
109
- node.status({ fill: "red", shape: "ring", text: "Connection failed" });
110
- return;
111
- }
112
-
113
- if (establishListener()) {
114
- retryCount = 0;
115
- return; // Success
116
- }
117
-
118
- retryCount++;
119
- setTimeout(retry, retryDelays[Math.min(retryCount, maxRetries - 1)]);
120
- };
121
-
122
- // Try immediately
123
- setTimeout(retry, retryDelays[0]);
124
- }
128
+ subscribeWithRetry();
129
+ startHealthCheck();
125
130
  }
126
131
 
127
- // --- CLEANUP ---
128
132
  node.on('close', function(removed, done) {
129
- if (retryInterval) {
130
- clearInterval(retryInterval);
131
- }
133
+ if (healthCheckAction) clearInterval(healthCheckAction);
134
+ if (retryAction) clearInterval(retryAction);
132
135
  if (removed && updateListener) {
133
136
  RED.events.removeListener("bldgblocks-global-update", updateListener);
134
137
  }
@@ -20,45 +20,56 @@
20
20
  <hr>
21
21
 
22
22
  <div class="form-row">
23
- <label for="node-input-defaultValue" title="Static default value to ensure one exists. You may write to default through message configuration."><i class="fa fa-undo"></i> Default</label>
23
+ <label for="node-input-defaultValue" title="Manual default value to ensure one always exists. You may write to default through message configuration but may not set it to null."><i class="fa fa-undo"></i> Default</label>
24
24
  <input type="text" id="node-input-defaultValue" placeholder="e.g. 0 or false">
25
+ <input type="hidden" id="node-input-defaultValueType">
25
26
  </div>
26
27
 
27
28
  <div class="form-tips">
28
- <b>Note:</b> This node writes to the selected <b>Priority Level</b>. The actual Global Variable value will be the highest active priority.
29
+ <b>Note:</b> This node writes to the selected <b>Priority</b>, manually, by msg or flow. The actual Global Variable value will be the highest active priority.
29
30
  </div>
30
31
  </script>
31
32
 
32
33
  <script type="text/javascript">
33
34
  RED.nodes.registerType('global-setter', {
34
- category: 'control',
35
+ category: "bldgblocks control",
35
36
  color: '#E2D96E',
36
37
  defaults: {
37
38
  name: { value: "" },
38
39
  path: { value: "", required: true },
39
40
  property: { value: "payload", required: true },
40
41
  defaultValue: { value: "", required: true },
41
- writePriority: { value: "16", required: true },
42
+ defaultValueType: { value: "num", required: true },
43
+ writePriority: { value: "default", required: true },
42
44
  writePriorityType: { value: "dropdown" }
43
45
  },
44
46
  inputs: 1,
45
47
  outputs: 1,
46
48
  icon: "font-awesome/fa-align-right",
47
49
  label: function() {
48
- let lbl = this.path;
49
- if (lbl && lbl.startsWith("#") && lbl.includes(":")) {
50
- lbl = lbl.substring(lbl.indexOf(":") + 1);
50
+ let lbl = this.name || this.path;
51
+ if (lbl) {
52
+ if (lbl && lbl.startsWith("#") && lbl.includes(":")) {
53
+ lbl = lbl.substring(lbl.indexOf(":") + 1);
54
+ }
55
+ return "set: " + lbl;
51
56
  }
52
- return this.name || "set: " + lbl || "global set";
57
+ return this.name || "global set";
53
58
  },
54
59
  paletteLabel: "global set",
55
60
  oneditprepare: function() {
61
+ const node = this;
62
+
56
63
  // These are read as strings not evaluated typed-inputs.
57
64
  $("#node-input-path").typedInput({ types: ['global'] });
58
65
  // getMessageProperty handles msg access on the incoming message at the specified path.
59
66
  $("#node-input-property").typedInput({ types: ['msg'] });
60
67
  // Default for the default value, meaning it should only be manually set. You can still pass default values through messages.
61
- $("#node-input-defaultValue").typedInput({ types: ['str','num','bool'] });
68
+ $("#node-input-defaultValue").typedInput({
69
+ default: "num",
70
+ types: ["str", "num", "bool", "json"],
71
+ typeField: "#node-input-defaultValueType"
72
+ }).typedInput("type", node.defaultValueType || "num").typedInput("value", node.defaultValue);
62
73
 
63
74
  $("#node-input-writePriority").typedInput({
64
75
  default: "dropdown",
@@ -80,7 +91,7 @@
80
91
  { value: "13", label: "13"},
81
92
  { value: "14", label: "14"},
82
93
  { value: "15", label: "15"},
83
- { value: "16", label: "16 (Schedule/Logic)"},
94
+ { value: "16", label: "16 (Network Logic)"},
84
95
  { value: "default", label: "default (fallback)"},
85
96
  ]
86
97
  }, "msg", "flow"],