diff --git a/public/red/ui/palette.js b/public/red/ui/palette.js index 6a79438e9..ecdb3c80c 100644 --- a/public/red/ui/palette.js +++ b/public/red/ui/palette.js @@ -79,7 +79,11 @@ RED.palette = (function() { if (label != type) { l = "

"+label+"
"+type+"

"; } - popOverContent = $(l+($("script[data-help-name|='"+type+"']").html()||"

no information available

").trim()).slice(0,2); + + popOverContent = $(l+($("script[data-help-name|='"+type+"']").html()||"

no information available

").trim()) + .filter(function(n) { + return this.nodeType == 1 || (this.nodeType == 3 && this.textContent.trim().length > 0) + }).slice(0,2); } catch(err) { // Malformed HTML may cause errors. TODO: need to understand what can break console.log("Error generating pop-over label for '"+type+"'.");