diff --git a/packages/node_modules/@node-red/editor-client/src/js/ui/utils.js b/packages/node_modules/@node-red/editor-client/src/js/ui/utils.js
index 6475b19f5..d0e2c4256 100644
--- a/packages/node_modules/@node-red/editor-client/src/js/ui/utils.js
+++ b/packages/node_modules/@node-red/editor-client/src/js/ui/utils.js
@@ -483,6 +483,16 @@ RED.utils = (function() {
$('').css('backgroundColor',obj).appendTo(e);
}
+ let n = RED.nodes.node(obj) ?? RED.nodes.workspace(obj);
+ if (n) {
+ if (options.nodeSelector && "function" == typeof options.nodeSelector) {
+ e.css('cursor', 'pointer').on("click", function(evt) {
+ evt.preventDefault();
+ options.nodeSelector(n.id);
+ })
+ }
+ }
+
} else if (typeof obj === 'number') {
e = $('').appendTo(entryObj);
@@ -589,6 +599,7 @@ RED.utils = (function() {
exposeApi: exposeApi,
// tools: tools // Do not pass tools down as we
// keep them attached to the top-level header
+ nodeSelector: options.nodeSelector,
}
).appendTo(row);
}
@@ -619,6 +630,7 @@ RED.utils = (function() {
exposeApi: exposeApi,
// tools: tools // Do not pass tools down as we
// keep them attached to the top-level header
+ nodeSelector: options.nodeSelector,
}
).appendTo(row);
}
@@ -675,6 +687,7 @@ RED.utils = (function() {
exposeApi: exposeApi,
// tools: tools // Do not pass tools down as we
// keep them attached to the top-level header
+ nodeSelector: options.nodeSelector,
}
).appendTo(row);
}
diff --git a/packages/node_modules/@node-red/nodes/core/common/lib/debug/debug-utils.js b/packages/node_modules/@node-red/nodes/core/common/lib/debug/debug-utils.js
index a4cd4c68d..b244273dc 100644
--- a/packages/node_modules/@node-red/nodes/core/common/lib/debug/debug-utils.js
+++ b/packages/node_modules/@node-red/nodes/core/common/lib/debug/debug-utils.js
@@ -512,7 +512,8 @@ RED.debug = (function() {
hideKey: false,
path: path,
sourceId: sourceNode&&sourceNode.id,
- rootPath: path
+ rootPath: path,
+ nodeSelector: config.messageSourceClick,
});
// Do this in a separate step so the element functions aren't stripped
debugMessage.appendTo(el);