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

Allow expanding diff elements to stay in-sync deeper

This commit is contained in:
Nick O'Leary 2017-08-04 14:23:28 +01:00
parent 7de1bf9d95
commit 1671d1f580
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9
2 changed files with 11 additions and 2 deletions

View File

@ -82,7 +82,6 @@
that.addItem({});
});
}
console.log(this.element.prop('id'));
if (this.element.css("position") === "absolute") {
["top","left","bottom","right"].forEach(function(s) {
var v = that.element.css(s);
@ -90,7 +89,6 @@
that.topContainer.css(s,v);
that.uiContainer.css(s,"0");
that.element.css(s,'auto');
console.log(s,v);
}
})
this.element.css("position","static");

View File

@ -536,6 +536,17 @@ RED.utils = (function() {
}
} else if (subElements[targetPath] && subElements[targetPath].prop('expand') ) {
subElements[targetPath].prop('expand')(targetPath,state);
} else {
for (var p in subElements) {
if (subElements.hasOwnProperty(p)) {
if (targetPath.indexOf(p) === 0) {
if (subElements[p].prop('expand') ) {
subElements[p].prop('expand')(targetPath,state);
}
break;
}
}
}
}
}});
}