Skip to content

Commit c49b041

Browse files
committed
Update debug code
1 parent 4e8bc34 commit c49b041

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

test/jasmine/tests/sankey_test.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1308,8 +1308,11 @@ describe('sankey tests', function() {
13081308
.then(function() {
13091309
var nodes = document.getElementsByClassName('sankey-node');
13101310
Array.from(nodes).forEach(function(n, i) {
1311-
var r = n.getBoundingClientRect();
1312-
console.log('node', i, {x: (r.left + r.right) / 2, y: (r.top + r.bottom) / 2, r: r});
1311+
var rect = n.querySelector('.node-rect');
1312+
if(rect) {
1313+
var r = rect.getBoundingClientRect();
1314+
console.log('node', i, 'rect', {x: (r.left + r.right) / 2, y: (r.top + r.bottom) / 2, w: r.width, h: r.height});
1315+
}
13131316
});
13141317
})
13151318
.then(assertNoHoverEvents('node'))

0 commit comments

Comments
 (0)