Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit f0d4e58

Browse files
committed
tweak for last node styles
1 parent 9237a7e commit f0d4e58

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/traces/sankey/render.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1099,7 +1099,8 @@ module.exports = function(gd, svg, calcData, layout, callbacks) {
10991099
})
11001100
.attr('x', (d) => {
11011101
var x = 0;
1102-
x = d.horizontal && d.left ? -45 : 5;
1102+
var length = d.displayText.length * 7 * -1;
1103+
x = d.horizontal && d.left ? length : 5;
11031104

11041105
return x;
11051106
})

0 commit comments

Comments
 (0)