diff --git a/packages/node_modules/@node-red/editor-client/locales/en-US/editor.json b/packages/node_modules/@node-red/editor-client/locales/en-US/editor.json index 4f3a3b104..01107d49d 100755 --- a/packages/node_modules/@node-red/editor-client/locales/en-US/editor.json +++ b/packages/node_modules/@node-red/editor-client/locales/en-US/editor.json @@ -3,7 +3,7 @@ "label": { "name": "Name", "ok": "Ok", - "done":"Done", + "done": "Done", "cancel": "Cancel", "delete": "Delete", "close": "Close", @@ -66,7 +66,7 @@ "listSubflows": "List subflows", "status": "Status", "enabled": "Enabled", - "disabled":"Disabled", + "disabled": "Disabled", "info": "Description", "selectNodes": "Click nodes to select" }, @@ -114,7 +114,7 @@ "keyboardShortcuts": "Keyboard shortcuts", "login": "Login", "logout": "Logout", - "editPalette":"Manage palette", + "editPalette": "Manage palette", "other": "Other", "showTips": "Show tips", "showWelcomeTours": "Show guided tours for new versions", @@ -130,19 +130,19 @@ "ungroupSelection": "Ungroup selection", "groupMergeSelection": "Merge selection", "groupRemoveSelection": "Remove from group", - "arrange":"Arrange", - "alignLeft":"Align to left", - "alignCenter":"Align to center", - "alignRight":"Align to right", - "alignTop":"Align to top", - "alignMiddle":"Align to middle", - "alignBottom":"Align to bottom", - "distributeHorizontally":"Distribute horizontally", - "distributeVertically":"Distribute vertically", - "moveToBack":"Move to back", - "moveToFront":"Move to front", - "moveBackwards":"Move backwards", - "moveForwards":"Move forwards" + "arrange": "Arrange", + "alignLeft": "Align to left", + "alignCenter": "Align to center", + "alignRight": "Align to right", + "alignTop": "Align to top", + "alignMiddle": "Align to middle", + "alignBottom": "Align to bottom", + "distributeHorizontally": "Distribute horizontally", + "distributeVertically": "Distribute vertically", + "moveToBack": "Move to back", + "moveToFront": "Move to front", + "moveBackwards": "Move backwards", + "moveForwards": "Move forwards" } }, "actions": { @@ -176,10 +176,10 @@ "nodeActionDisabledSubflow": "node actions disabled within subflow", "missing-types": "
Flows stopped due to missing node types.
", "missing-modules": "Flows stopped due to missing modules.
", - "safe-mode":"Flows stopped in safe mode.
You can modify your flows and deploy the changes to restart.
", + "safe-mode": "Flows stopped in safe mode.
You can modify your flows and deploy the changes to restart.
", "restartRequired": "Node-RED must be restarted to enable upgraded modules", "credentials_load_failed": "Flows stopped as the credentials could not be decrypted.
The flow credential file is encrypted, but the project's encryption key is missing or invalid.
", - "credentials_load_failed_reset":"Credentials could not be decrypted
The flow credential file is encrypted, but the project's encryption key is missing or invalid.
The flow credential file will be reset on the next deployment. Any existing flow credentials will be cleared.
", + "credentials_load_failed_reset": "Credentials could not be decrypted
The flow credential file is encrypted, but the project's encryption key is missing or invalid.
The flow credential file will be reset on the next deployment. Any existing flow credentials will be cleared.
", "missing_flow_file": "Project flow file not found.
The project is not configured with a flow file.
", "missing_package_file": "Project package file not found.
The project is missing a package.json file.
", "project_empty": "The project is empty.
Do you want to create a default set of project files?
Otherwise, you will have to manually add files to the project outside of the editor.
Imported nodes without a valid flow id
They have been added to a new flow called '__flowName__'.
", "export": { - "selected":"selected nodes", - "current":"current flow", - "all":"all flows", - "compact":"compact", - "formatted":"formatted", + "selected": "selected nodes", + "current": "current flow", + "all": "all flows", + "compact": "compact", + "formatted": "formatted", "copy": "Copy to clipboard", "export": "Export to library", "exportAs": "Export as", @@ -301,10 +301,10 @@ "successfulDeploy": "Successfully deployed", "successfulRestart": "Successfully restarted flows", "deployFailed": "Deploy failed: __message__", - "unusedConfigNodes":"You have some unused configuration nodes.", - "unusedConfigNodesButton":"Search unused config nodes", - "unknownNodesButton":"Search for unknown nodes", - "invalidNodesButton":"Search for invalid nodes", + "unusedConfigNodes": "You have some unused configuration nodes.", + "unusedConfigNodesButton": "Search unused config nodes", + "unknownNodesButton": "Search for unknown nodes", + "invalidNodesButton": "Search for invalid nodes", "errors": { "noResponse": "no response from server" }, @@ -351,8 +351,8 @@ }, "nodeCount": "__count__ node", "nodeCount_plural": "__count__ nodes", - "local":"Local changes", - "remote":"Remote changes", + "local": "Local changes", + "remote": "Remote changes", "reviewChanges": "Review Changes", "noBinaryFileShowed": "Cannot show binary file contents", "viewCommitDiff": "View Commit Changes", @@ -436,7 +436,7 @@ "inputType": "Input type", "selectType": "select types...", "loadCredentials": "Loading node credentials", - "inputs" : { + "inputs": { "input": "input", "select": "select", "checkbox": "checkbox", @@ -617,19 +617,19 @@ }, "confirm": { "install": { - "body":"Installing '__module__'
Before installing, please read the node's documentation. Some nodes have dependencies that cannot be automatically resolved and can require a restart of Node-RED.
", + "body": "Installing '__module__'
Before installing, please read the node's documentation. Some nodes have dependencies that cannot be automatically resolved and can require a restart of Node-RED.
", "title": "Install nodes" }, "remove": { - "body":"Removing '__module__'
Removing the node will uninstall it from Node-RED. The node may continue to use resources until Node-RED is restarted.
", + "body": "Removing '__module__'
Removing the node will uninstall it from Node-RED. The node may continue to use resources until Node-RED is restarted.
", "title": "Remove nodes" }, "update": { - "body":"Updating '__module__'
Updating the node will require a restart of Node-RED to complete the update. This must be done manually.
", + "body": "Updating '__module__'
Updating the node will require a restart of Node-RED to complete the update. This must be done manually.
", "title": "Update nodes" }, "cannotUpdate": { - "body":"An update for this node is available, but it is not installed in a location that the palette manager can update.The Buffer type is stored as a JSON array of byte values. The editor will attempt to parse the entered value as a JSON array. If it is not valid JSON, it will be treated as a UTF-8 String and converted to an array of the individual character code points.
For example, a value of Hello World
will be converted to the JSON array:
[72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100]" + "modeDesc": "
The Buffer type is stored as a JSON array of byte values. The editor will attempt to parse the entered value as a JSON array. If it is not valid JSON, it will be treated as a UTF-8 String and converted to an array of the individual character code points.
For example, a value of Hello World
will be converted to the JSON array:
[72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100]" }, "projects": { "config-git": "Configure Git client", @@ -1140,7 +1140,7 @@ "no-empty": "Cannot create default file set on a non-empty project", "git-error": "git error" }, - "errors" : { + "errors": { "no-username-email": "Your Git client is not configured with a username/email.", "unexpected": "An unexpected error occurred", "code": "code" @@ -1163,7 +1163,7 @@ "diagnostics": { "title": "System Info" }, - "languages" : { + "languages": { "de": "German", "en-US": "English", "ja": "Japanese", @@ -1174,18 +1174,18 @@ }, "validator": { "errors": { - "invalid-json": "Invalid JSON data: __error__", - "invalid-json-prop": "__prop__: invalid JSON data: __error__", - "invalid-prop": "Invalid property expression", - "invalid-prop-prop": "__prop__: invalid property expression", - "invalid-num": "Invalid number", - "invalid-num-prop": "__prop__: invalid number", - "invalid-regexp": "Invalid input pattern", - "invalid-regex-prop": "__prop__: invalid input pattern", - "missing-required-prop": "__prop__: property value missing", - "invalid-config": "__prop__: invalid configuration node", - "missing-config": "__prop__: missing configuration node", - "validation-error": "__prop__: validation error: __node__, __id__: __error__" - } + "invalid-json": "Invalid JSON data: __error__", + "invalid-json-prop": "__prop__: invalid JSON data: __error__", + "invalid-prop": "Invalid property expression", + "invalid-prop-prop": "__prop__: invalid property expression", + "invalid-num": "Invalid number", + "invalid-num-prop": "__prop__: invalid number", + "invalid-regexp": "Invalid input pattern", + "invalid-regex-prop": "__prop__: invalid input pattern", + "missing-required-prop": "__prop__: property value missing", + "invalid-config": "__prop__: invalid configuration node", + "missing-config": "__prop__: missing configuration node", + "validation-error": "__prop__: validation error: __node__, __id__: __error__" + } } } diff --git a/packages/node_modules/@node-red/editor-client/locales/en-US/infotips.json b/packages/node_modules/@node-red/editor-client/locales/en-US/infotips.json index 21a7e735f..a958868ee 100755 --- a/packages/node_modules/@node-red/editor-client/locales/en-US/infotips.json +++ b/packages/node_modules/@node-red/editor-client/locales/en-US/infotips.json @@ -1,23 +1,23 @@ { "info": { - "tip0" : "You can remove the selected nodes or links with {{core:delete-selection}}", - "tip1" : "Search for nodes using {{core:search}}", - "tip2" : "{{core:toggle-sidebar}} will toggle the view of this sidebar", - "tip3" : "You can manage your palette of nodes with {{core:manage-palette}}", - "tip4" : "Your flow configuration nodes are listed in the sidebar panel. It can be accessed from the menu or with {{core:show-config-tab}}", - "tip5" : "Enable or disable these tips from the option in the settings", - "tip6" : "Move the selected nodes using the [left] [up] [down] and [right] keys. Hold [shift] to nudge them further", - "tip7" : "Dragging a node onto a wire will splice it into the link", - "tip8" : "Export the selected nodes, or the current tab with {{core:show-export-dialog}}", - "tip9" : "Import a flow by dragging its JSON into the editor, or with {{core:show-import-dialog}}", - "tip10" : "[shift] [click] and drag on a node port to move all of the attached wires or just the selected one", - "tip11" : "Show the Info tab with {{core:show-info-tab}} or the Debug tab with {{core:show-debug-tab}}", - "tip12" : "[ctrl] [click] in the workspace to open the quick-add dialog", - "tip13" : "Hold down [ctrl] when you [click] on a node port to enable quick-wiring", - "tip14" : "Hold down [shift] when you [click] on a node to also select all of its connected nodes", - "tip15" : "Hold down [ctrl] when you [click] on a node to add or remove it from the current selection", - "tip16" : "Switch flow tabs with {{core:show-previous-tab}} and {{core:show-next-tab}}", - "tip17" : "You can confirm your changes in the node edit tray with {{core:confirm-edit-tray}} or cancel them with {{core:cancel-edit-tray}}", - "tip18" : "Pressing {{core:edit-selected-node}} will edit the first node in the current selection" + "tip0": "You can remove the selected nodes or links with {{core:delete-selection}}", + "tip1": "Search for nodes using {{core:search}}", + "tip2": "{{core:toggle-sidebar}} will toggle the view of this sidebar", + "tip3": "You can manage your palette of nodes with {{core:manage-palette}}", + "tip4": "Your flow configuration nodes are listed in the sidebar panel. It can be accessed from the menu or with {{core:show-config-tab}}", + "tip5": "Enable or disable these tips from the option in the settings", + "tip6": "Move the selected nodes using the [left] [up] [down] and [right] keys. Hold [shift] to nudge them further", + "tip7": "Dragging a node onto a wire will splice it into the link", + "tip8": "Export the selected nodes, or the current tab with {{core:show-export-dialog}}", + "tip9": "Import a flow by dragging its JSON into the editor, or with {{core:show-import-dialog}}", + "tip10": "[shift] [click] and drag on a node port to move all of the attached wires or just the selected one", + "tip11": "Show the Info tab with {{core:show-info-tab}} or the Debug tab with {{core:show-debug-tab}}", + "tip12": "[ctrl] [click] in the workspace to open the quick-add dialog", + "tip13": "Hold down [ctrl] when you [click] on a node port to enable quick-wiring", + "tip14": "Hold down [shift] when you [click] on a node to also select all of its connected nodes", + "tip15": "Hold down [ctrl] when you [click] on a node to add or remove it from the current selection", + "tip16": "Switch flow tabs with {{core:show-previous-tab}} and {{core:show-next-tab}}", + "tip17": "You can confirm your changes in the node edit tray with {{core:confirm-edit-tray}} or cancel them with {{core:cancel-edit-tray}}", + "tip18": "Pressing {{core:edit-selected-node}} will edit the first node in the current selection" } } diff --git a/packages/node_modules/@node-red/editor-client/locales/en-US/jsonata.json b/packages/node_modules/@node-red/editor-client/locales/en-US/jsonata.json index 6a00a3c09..b24a898b7 100755 --- a/packages/node_modules/@node-red/editor-client/locales/en-US/jsonata.json +++ b/packages/node_modules/@node-red/editor-client/locales/en-US/jsonata.json @@ -52,52 +52,52 @@ "desc": "Finds occurrences of `pattern` within `str` and replaces them with `replacement`.\n\nThe optional `limit` parameter is the maximum number of replacements." }, "$now": { - "args":"$[picture [, timezone]]", - "desc":"Generates a timestamp in ISO 8601 compatible format and returns it as a string. If the optional picture and timezone parameters are supplied, then the current timestamp is formatted as described by the `$fromMillis()` function" + "args": "$[picture [, timezone]]", + "desc": "Generates a timestamp in ISO 8601 compatible format and returns it as a string. If the optional picture and timezone parameters are supplied, then the current timestamp is formatted as described by the `$fromMillis()` function" }, "$base64encode": { - "args":"string", - "desc":"Converts an ASCII string to a base 64 representation. Each character in the string is treated as a byte of binary data. This requires that all characters in the string are in the 0x00 to 0xFF range, which includes all characters in URI encoded strings. Unicode characters outside of that range are not supported." + "args": "string", + "desc": "Converts an ASCII string to a base 64 representation. Each character in the string is treated as a byte of binary data. This requires that all characters in the string are in the 0x00 to 0xFF range, which includes all characters in URI encoded strings. Unicode characters outside of that range are not supported." }, "$base64decode": { - "args":"string", - "desc":"Converts base 64 encoded bytes to a string, using a UTF-8 Unicode codepage." + "args": "string", + "desc": "Converts base 64 encoded bytes to a string, using a UTF-8 Unicode codepage." }, "$number": { "args": "arg", "desc": "Casts the `arg` parameter to a number using the following casting rules:\n\n - Numbers are unchanged\n - Strings that contain a sequence of characters that represent a legal JSON number are converted to that number\n - All other values cause an error to be thrown." }, "$abs": { - "args":"number", - "desc":"Returns the absolute value of the `number` parameter." + "args": "number", + "desc": "Returns the absolute value of the `number` parameter." }, "$floor": { - "args":"number", - "desc":"Returns the value of `number` rounded down to the nearest integer that is smaller or equal to `number`." + "args": "number", + "desc": "Returns the value of `number` rounded down to the nearest integer that is smaller or equal to `number`." }, "$ceil": { - "args":"number", - "desc":"Returns the value of `number` rounded up to the nearest integer that is greater than or equal to `number`." + "args": "number", + "desc": "Returns the value of `number` rounded up to the nearest integer that is greater than or equal to `number`." }, "$round": { - "args":"number [, precision]", - "desc":"Returns the value of the `number` parameter rounded to the number of decimal places specified by the optional `precision` parameter." + "args": "number [, precision]", + "desc": "Returns the value of the `number` parameter rounded to the number of decimal places specified by the optional `precision` parameter." }, "$power": { - "args":"base, exponent", - "desc":"Returns the value of `base` raised to the power of `exponent`." + "args": "base, exponent", + "desc": "Returns the value of `base` raised to the power of `exponent`." }, "$sqrt": { - "args":"number", - "desc":"Returns the square root of the value of the `number` parameter." + "args": "number", + "desc": "Returns the square root of the value of the `number` parameter." }, "$random": { - "args":"", - "desc":"Returns a pseudo random number greater than or equal to zero and less than one." + "args": "", + "desc": "Returns a pseudo random number greater than or equal to zero and less than one." }, "$millis": { - "args":"", - "desc":"Returns the number of milliseconds since the Unix Epoch (1 January, 1970 UTC) as a number. All invocations of `$millis()` within an evaluation of an expression will all return the same value." + "args": "", + "desc": "Returns the number of milliseconds since the Unix Epoch (1 January, 1970 UTC) as a number. All invocations of `$millis()` within an evaluation of an expression will all return the same value." }, "$sum": { "args": "array", @@ -136,20 +136,20 @@ "desc": "Appends two arrays" }, "$sort": { - "args":"array [, function]", - "desc":"Returns an array containing all the values in the `array` parameter, but sorted into order.\n\nIf a comparator `function` is supplied, then it must be a function that takes two parameters:\n\n`function(left, right)`\n\nThis function gets invoked by the sorting algorithm to compare two values left and right. If the value of left should be placed after the value of right in the desired sort order, then the function must return Boolean `true` to indicate a swap. Otherwise it must return `false`." + "args": "array [, function]", + "desc": "Returns an array containing all the values in the `array` parameter, but sorted into order.\n\nIf a comparator `function` is supplied, then it must be a function that takes two parameters:\n\n`function(left, right)`\n\nThis function gets invoked by the sorting algorithm to compare two values left and right. If the value of left should be placed after the value of right in the desired sort order, then the function must return Boolean `true` to indicate a swap. Otherwise it must return `false`." }, "$reverse": { - "args":"array", - "desc":"Returns an array containing all the values from the `array` parameter, but in reverse order." + "args": "array", + "desc": "Returns an array containing all the values from the `array` parameter, but in reverse order." }, "$shuffle": { - "args":"array", - "desc":"Returns an array containing all the values from the `array` parameter, but shuffled into random order." + "args": "array", + "desc": "Returns an array containing all the values from the `array` parameter, but shuffled into random order." }, "$zip": { - "args":"array, ...", - "desc":"Returns a convolved (zipped) array containing grouped arrays of values from the `array1` … `arrayN` arguments from index 0, 1, 2...." + "args": "array, ...", + "desc": "Returns a convolved (zipped) array containing grouped arrays of values from the `array1` … `arrayN` arguments from index 0, 1, 2...." }, "$keys": { "args": "object", @@ -168,24 +168,24 @@ "desc": "Merges an array of `objects` into a single `object` containing all the key/value pairs from each of the objects in the input array. If any of the input objects contain the same key, then the returned `object` will contain the value of the last one in the array. It is an error if the input array contains an item that is not an object." }, "$sift": { - "args":"object, function", - "desc":"Returns an object that contains only the key/value pairs from the `object` parameter that satisfy the predicate `function` passed in as the second parameter.\n\nThe `function` that is supplied as the second parameter must have the following signature:\n\n`function(value [, key [, object]])`" + "args": "object, function", + "desc": "Returns an object that contains only the key/value pairs from the `object` parameter that satisfy the predicate `function` passed in as the second parameter.\n\nThe `function` that is supplied as the second parameter must have the following signature:\n\n`function(value [, key [, object]])`" }, "$each": { - "args":"object, function", - "desc":"Returns an array containing the values return by the `function` when applied to each key/value pair in the `object`." + "args": "object, function", + "desc": "Returns an array containing the values return by the `function` when applied to each key/value pair in the `object`." }, "$map": { - "args":"array, function", - "desc":"Returns an array containing the results of applying the `function` parameter to each value in the `array` parameter.\n\nThe `function` that is supplied as the second parameter must have the following signature:\n\n`function(value [, index [, array]])`" + "args": "array, function", + "desc": "Returns an array containing the results of applying the `function` parameter to each value in the `array` parameter.\n\nThe `function` that is supplied as the second parameter must have the following signature:\n\n`function(value [, index [, array]])`" }, "$filter": { - "args":"array, function", - "desc":"Returns an array containing only the values in the `array` parameter that satisfy the `function` predicate.\n\nThe `function` that is supplied as the second parameter must have the following signature:\n\n`function(value [, index [, array]])`" + "args": "array, function", + "desc": "Returns an array containing only the values in the `array` parameter that satisfy the `function` predicate.\n\nThe `function` that is supplied as the second parameter must have the following signature:\n\n`function(value [, index [, array]])`" }, "$reduce": { - "args":"array, function [, init]", - "desc":"Returns an aggregated value derived from applying the `function` parameter successively to each value in `array` in combination with the result of the previous application of the function.\n\nThe function must accept two arguments, and behaves like an infix operator between each value within the `array`. The signature of `function` must be of the form: `myfunc($accumulator, $value[, $index[, $array]])`\n\nThe optional `init` parameter is used as the initial value in the aggregation." + "args": "array, function [, init]", + "desc": "Returns an aggregated value derived from applying the `function` parameter successively to each value in `array` in combination with the result of the previous application of the function.\n\nThe function must accept two arguments, and behaves like an infix operator between each value within the `array`. The signature of `function` must be of the form: `myfunc($accumulator, $value[, $index[, $array]])`\n\nThe optional `init` parameter is used as the initial value in the aggregation." }, "$flowContext": { "args": "string[, string]", diff --git a/packages/node_modules/@node-red/editor-client/locales/ja/editor.json b/packages/node_modules/@node-red/editor-client/locales/ja/editor.json index 9713e2bab..4c918b615 100644 --- a/packages/node_modules/@node-red/editor-client/locales/ja/editor.json +++ b/packages/node_modules/@node-red/editor-client/locales/ja/editor.json @@ -907,7 +907,8 @@ "uknownNodes": "未知のノード", "unusedSubflows": "未使用のサブフロー", "hiddenFlows": "非表示のフロー", - "modifiedNodes": "修正したノードやフロー" + "modifiedNodes": "修正したノードやフロー", + "thisFlow": "現在のフロー" } }, "expressionEditor": { diff --git a/packages/node_modules/@node-red/editor-client/locales/ja/infotips.json b/packages/node_modules/@node-red/editor-client/locales/ja/infotips.json index 45ba8450e..14459fa10 100644 --- a/packages/node_modules/@node-red/editor-client/locales/ja/infotips.json +++ b/packages/node_modules/@node-red/editor-client/locales/ja/infotips.json @@ -17,7 +17,7 @@ "tip14": "[shift] を押しながらノードを [click] すると、接続された全てのノードを選択できます。", "tip15": "[ctrl] を押しながらノードを [click] すると、選択/非選択を切り替えできます。", "tip16": "{{core:show-previous-tab}} や {{core:show-next-tab}} で、タブの切り替えができます。", - "tip17": "ノードのプロバティ設定画面にて {{core:confirm-edit-tray}} を押すと、変更を確定できます。また、 {{core:cancel-edit-tray}} を押すと、変更を取り消せます。", + "tip17": "ノードのプロパティ設定画面にて {{core:confirm-edit-tray}} を押すと、変更を確定できます。また、 {{core:cancel-edit-tray}} を押すと、変更を取り消せます。", "tip18": "ノードを選択し、 {{core:edit-selected-node}} を押すとプロパティ設定画面が表示されます。" } } diff --git a/packages/node_modules/@node-red/editor-client/src/js/ui/library.js b/packages/node_modules/@node-red/editor-client/src/js/ui/library.js index ee176dee2..d276b1572 100755 --- a/packages/node_modules/@node-red/editor-client/src/js/ui/library.js +++ b/packages/node_modules/@node-red/editor-client/src/js/ui/library.js @@ -363,106 +363,112 @@ RED.library = (function() { options.onconfirm(item); } }); - var itemTools = $("
msg.payload
based on type:",
- "object":"Object",
- "objectSend":"Send a message for each key/value pair",
- "strBuff":"String / Buffer",
- "array":"Array",
- "splitUsing":"Split using",
- "splitLength":"Fixed length of",
- "stream":"Handle as a stream of messages",
- "addname":" Copy key to "
+ "intro": "Split msg.payload
based on type:",
+ "object": "Object",
+ "objectSend": "Send a message for each key/value pair",
+ "strBuff": "String / Buffer",
+ "array": "Array",
+ "splitUsing": "Split using",
+ "splitLength": "Fixed length of",
+ "stream": "Handle as a stream of messages",
+ "addname": " Copy key to "
},
"join": {
"join": "join",
@@ -1030,7 +1028,7 @@
"complete": "After a message with the msg.complete
property set",
"tip": "This mode assumes this node is either paired with a split node or the received messages will have a properly configured msg.parts
property.",
"too-many": "too many pending messages in join node",
- "message-prop": "message property",
+ "message-prop": "message property",
"merge": {
"topics-label": "Merged Topics",
"topics": "topics",
@@ -1049,51 +1047,51 @@
"invalid-type": "Cannot join __error__ to buffer"
}
},
- "sort" : {
+ "sort": {
"sort": "sort",
- "target" : "Sort",
- "seq" : "message sequence",
- "key" : "Key",
- "elem" : "element value",
- "order" : "Order",
- "ascending" : "ascending",
- "descending" : "descending",
- "as-number" : "as number",
- "invalid-exp" : "Invalid JSONata expression in sort node: __message__",
- "too-many" : "Too many pending messages in sort node",
- "clear" : "clear pending message in sort node"
+ "target": "Sort",
+ "seq": "message sequence",
+ "key": "Key",
+ "elem": "element value",
+ "order": "Order",
+ "ascending": "ascending",
+ "descending": "descending",
+ "as-number": "as number",
+ "invalid-exp": "Invalid JSONata expression in sort node: __message__",
+ "too-many": "Too many pending messages in sort node",
+ "clear": "clear pending message in sort node"
},
- "batch" : {
+ "batch": {
"batch": "batch",
"mode": {
- "label" : "Mode",
- "num-msgs" : "Group by number of messages",
- "interval" : "Group by time interval",
- "concat" : "Concatenate sequences"
+ "label": "Mode",
+ "num-msgs": "Group by number of messages",
+ "interval": "Group by time interval",
+ "concat": "Concatenate sequences"
},
"count": {
- "label" : "Number of messages",
- "overlap" : "Overlap",
- "count" : "count",
- "invalid" : "Invalid count and overlap"
+ "label": "Number of messages",
+ "overlap": "Overlap",
+ "count": "count",
+ "invalid": "Invalid count and overlap"
},
"interval": {
- "label" : "Interval",
- "seconds" : "seconds",
- "empty" : "send empty message when no message arrives"
+ "label": "Interval",
+ "seconds": "seconds",
+ "empty": "send empty message when no message arrives"
},
"concat": {
"topics-label": "Topics",
- "topic" : "topic"
+ "topic": "topic"
},
- "too-many" : "too many pending messages in batch node",
- "unexpected" : "unexpected mode",
- "no-parts" : "no parts property in message",
- "error": {
- "invalid-count": "Invalid count",
- "invalid-overlap": "Invalid overlap",
- "invalid-interval": "Invalid interval"
- }
+ "too-many": "too many pending messages in batch node",
+ "unexpected": "unexpected mode",
+ "no-parts": "no parts property in message",
+ "error": {
+ "invalid-count": "Invalid count",
+ "invalid-overlap": "Invalid overlap",
+ "invalid-interval": "Invalid interval"
+ }
},
"rbe": {
"rbe": "filter",
@@ -1103,11 +1101,11 @@
"start": "Start value",
"name": "Name",
"septopics": "Apply mode separately for each ",
- "gap": "value change",
- "property": "property",
- "topic": "topic"
+ "gap": "value change",
+ "property": "property",
+ "topic": "topic"
},
- "placeholder":{
+ "placeholder": {
"bandgap": "e.g. 10 or 5%",
"start": "leave blank to use first data received"
},
diff --git a/packages/node_modules/@node-red/nodes/locales/ja/messages.json b/packages/node_modules/@node-red/nodes/locales/ja/messages.json
index c331f5912..c508a3e76 100644
--- a/packages/node_modules/@node-red/nodes/locales/ja/messages.json
+++ b/packages/node_modules/@node-red/nodes/locales/ja/messages.json
@@ -137,7 +137,7 @@
"toConsole": "システムコンソール",
"toStatus": "ノードステータス(32 文字)",
"severity": "Level",
- "node": "ノード",
+ "node": "ノード",
"notification": {
"activated": "有効化しました: __label__",
"deactivated": "無効化しました: __label__"
@@ -729,8 +729,8 @@
"property": "プロパティ",
"rule": "条件",
"repair": "メッセージ列の補正",
- "value-rules": "値ルール",
- "sequence-rules": "列ルール"
+ "value-rules": "値ルール",
+ "sequence-rules": "列ルール"
},
"previous": "前回の値",
"and": "~",
diff --git a/packages/node_modules/@node-red/runtime/locales/en-US/runtime.json b/packages/node_modules/@node-red/runtime/locales/en-US/runtime.json
index cb2e08aab..3b46d0c9f 100644
--- a/packages/node_modules/@node-red/runtime/locales/en-US/runtime.json
+++ b/packages/node_modules/@node-red/runtime/locales/en-US/runtime.json
@@ -8,7 +8,6 @@
"httpStatic": "HTTP Static : __path__"
}
},
-
"server": {
"loading": "Loading palette nodes",
"palette-editor": {
@@ -61,7 +60,6 @@
"function-required": "httpsRefreshInterval requires https property to be a function"
}
},
-
"api": {
"flows": {
"error-save": "Error saving flows: __message__",
@@ -79,18 +77,16 @@
"error-enable": "Failed to enable node:"
}
},
-
"comms": {
"error": "Communication channel error: __message__",
"error-server": "Communication server error: __message__",
"error-send": "Communication send error: __message__"
},
-
"settings": {
"user-not-available": "Cannot save user settings: __message__",
"not-available": "Settings not available",
"property-read-only": "Property '__prop__' is read-only",
- "readonly-mode" : "Runtime in read-only mode. Changes will not be saved."
+ "readonly-mode": "Runtime in read-only mode. Changes will not be saved."
},
"library": {
"unknownLibrary": "Unknown library: __library__",
@@ -101,12 +97,12 @@
},
"nodes": {
"credentials": {
- "error":"Error loading credentials: __message__",
- "error-saving":"Error saving credentials: __message__",
+ "error": "Error loading credentials: __message__",
+ "error-saving": "Error saving credentials: __message__",
"not-registered": "Credential type '__type__' is not registered",
"system-key-warning": "\n\n---------------------------------------------------------------------\nYour flow credentials file is encrypted using a system-generated key.\n\nIf the system-generated key is lost for any reason, your credentials\nfile will not be recoverable, you will have to delete it and re-enter\nyour credentials.\n\nYou should set your own key using the 'credentialSecret' option in\nyour settings file. Node-RED will then re-encrypt your credentials\nfile using your chosen key the next time you deploy a change.\n---------------------------------------------------------------------\n",
- "unencrypted" : "Using unencrypted credentials",
- "encryptedNotFound" : "Encrypted credentials not found"
+ "unencrypted": "Using unencrypted credentials",
+ "encryptedNotFound": "Encrypted credentials not found"
},
"flows": {
"safe-mode": "Flows stopped in safe mode. Deploy to start.",
@@ -150,7 +146,6 @@
}
}
},
-
"storage": {
"index": {
"forbidden-flow-name": "forbidden flow name"
@@ -180,7 +175,6 @@
}
}
},
-
"context": {
"log-store-init": "Context store : '__name__' [__info__]",
"error-loading-module": "Error loading context store: __message__",
@@ -195,5 +189,4 @@
"error-write": "Error writing context: __message__"
}
}
-
}
diff --git a/packages/node_modules/@node-red/util/lib/util.js b/packages/node_modules/@node-red/util/lib/util.js
index a6fec8f98..d82de0d1d 100644
--- a/packages/node_modules/@node-red/util/lib/util.js
+++ b/packages/node_modules/@node-red/util/lib/util.js
@@ -641,7 +641,12 @@ function evaluateNodeProperty(value, type, node, msg, callback) {
result = Date.now();
} else if (type === 'bin') {
var data = JSON.parse(value);
- result = Buffer.from(data);
+ if (Array.isArray(data) || (typeof(data) === "string")) {
+ result = Buffer.from(data);
+ }
+ else {
+ throw createError("INVALID_BUFFER_DATA", "Not string or array");
+ }
} else if (type === 'msg' && msg) {
try {
result = getMessageProperty(msg,value);
diff --git a/test/nodes/core/common/20-inject_spec.js b/test/nodes/core/common/20-inject_spec.js
index cb14690d0..a4dbdd9e4 100644
--- a/test/nodes/core/common/20-inject_spec.js
+++ b/test/nodes/core/common/20-inject_spec.js
@@ -906,6 +906,7 @@ describe('inject node', function() {
msg.should.have.property("str1", "1"); //injected prop
msg.should.have.property("num1", 1); //injected prop
msg.should.have.property("bool1", true); //injected prop
+ msg.should.have.property("jsonata1", "AB"); //injected prop
helper.clearFlows().then(function() {
done();
@@ -919,6 +920,7 @@ describe('inject node', function() {
{p:"str1", v:"1", vt:"str"}, //new prop
{p:"num1", v:"1", vt:"num"}, //new prop
{p:"bool1", v:"true", vt:"bool"}, //new prop
+ {p:"jsonata1", v:'"A" & "B"', vt:"jsonata"}, //new prop
]})
.expect(200).end(function(err) {
if (err) {
diff --git a/test/unit/@node-red/util/lib/util_spec.js b/test/unit/@node-red/util/lib/util_spec.js
index 2013f143e..3bab2739a 100644
--- a/test/unit/@node-red/util/lib/util_spec.js
+++ b/test/unit/@node-red/util/lib/util_spec.js
@@ -388,6 +388,19 @@ describe("@node-red/util/util", function() {
result[0].should.eql(1);
result[1].should.eql(2);
});
+ it('throws an error if buffer data is not array or string', function (done) {
+ try {
+ var result = util.evaluateNodeProperty('12','bin');
+ done("should throw an error");
+ } catch (err) {
+ if (err.code === "INVALID_BUFFER_DATA") {
+ done();
+ }
+ else {
+ done("should throw an error");
+ }
+ }
+ });
it('returns msg property',function() {
var result = util.evaluateNodeProperty('foo.bar','msg',{},{foo:{bar:"123"}});
result.should.eql("123");