diff --git a/Architype.js b/Architype.js index 112907c..706ba43 100644 --- a/Architype.js +++ b/Architype.js @@ -99,8 +99,6 @@ class Architype { } draw(steps) { - console.log(steps); - this.grid_.innerHTML = ''; this.gridNodes_ = []; @@ -133,6 +131,7 @@ class Architype { node.innerText = label; node.style.gridColumn = pos[0] + 1; node.style.gridRow = pos[1] + 1; + this.gridNodes_.push(node); } fixSizes() { diff --git a/Layout.js b/Layout.js index 8386aab..7a3b2c0 100644 --- a/Layout.js +++ b/Layout.js @@ -90,6 +90,7 @@ class Layout { } obj.savePos(); obj.moveBy(offset); + this.setTension(objects); let testTension = this.getTotalTension(objects); obj.restorePos(); if (testTension < newTension) {