File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -881,13 +881,14 @@ function createSpikelines(hoverData, opts) {
881881 xEndSpike = c0 . xa . spikemode . indexOf ( 'across' ) !== - 1 ?
882882 ( ySide === 'left' ? xBase + xLength : xBase - xLength ) :
883883 xPoint ,
884- yEndSpike = c0 . ya . spikemode . indexOf ( 'across' ) !== - 1 ? yBase - yLength : yPoint ;
884+ yEndSpike = c0 . ya . spikemode . indexOf ( 'across' ) !== - 1 ?
885+ ( xSide === 'bottom' ? yBase - yLength : yBase + yLength ) :
886+ yPoint ;
885887
886888 // Remove old spikeline items
887889 container . selectAll ( 'line.spikeline' ) . remove ( ) ;
888890 container . selectAll ( 'circle.spikeline' ) . remove ( ) ;
889891
890-
891892 if ( c0 . ya . showspikes ) {
892893 if ( ySpikeLine ) {
893894 // Background horizontal Line (to y-axis)
@@ -966,7 +967,7 @@ function createSpikelines(hoverData, opts) {
966967 container . append ( 'circle' )
967968 . attr ( {
968969 'cx' : xPoint ,
969- 'cy' : yAnchoredBase - xThickness ,
970+ 'cy' : yAnchoredBase - ( xSide !== 'top' ? xThickness : - xThickness ) ,
970971 'r' : xThickness ,
971972 'fill' : xColor
972973 } )
You can’t perform that action at this time.
0 commit comments