1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

Handle import of node with non-default number of outputs

This commit is contained in:
Nick O'Leary 2020-06-22 10:43:09 +01:00
parent 1d944bab51
commit e548bf8bc2
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9

View File

@ -3703,15 +3703,14 @@ RED.view = (function() {
var label = RED.utils.getNodeLabel(d, d.type);
var labelParts;
if (this.__hideLabel__ !== hideLabel || d.resize || this.__label__ !== label) {
if (d.resize || this.__hideLabel__ !== hideLabel || this.__label__ !== label || this.__outputs__.length !== d.outputs) {
labelParts = getLabelParts(label, "red-ui-flow-node-label");
this.__label__ = label;
if (labelParts.lines.length !== this.__labelLineCount__) {
d.resize = true;
}
this.__labelLineCount__ = labelParts.lines.length;
}
if (d.resize || this.__hideLabel__ !== hideLabel || this.__outputs__.length !== d.outputs) {
if (hideLabel) {
d.h = Math.max(node_height,(d.outputs || 0) * 15);
} else {