d3-book icon indicating copy to clipboard operation
d3-book copied to clipboard

New labels should start 1/2 a bar-width to right

Open Selbosh opened this issue 7 years ago • 1 comments

Line 192 should add half a bar width to the horizontal starting position of labels in the enter() selection, otherwise they are incorrectly aligned with the bar during the transition.

Selbosh avatar Jan 24 '18 17:01 Selbosh

Ah, thank you! Very good catch, and I expect you're the first person to notice this very small and fast-moving discrepancy. :-)

I'm going to leave this PR open for now; I'd like to apply this, but not until the code excerpts and explanations in the book can be updated at the same time.

scotthmurray avatar Jan 25 '18 20:01 scotthmurray