chartjs-plugin-crosshair
chartjs-plugin-crosshair copied to clipboard
Dots on line charts don't appear on the vertical line
I followed all the steps to add this plugin and everything works great except for the little dot(s) that trace the graph and is fixed to the vertical line (in the demo they are little hollow circles). I've tried adjusting config options but cannot get them to appear. Anyone have any ideas? And if they do appear, is there any way to style them? Thanks!
Did you enable the interpolate tooltip mode?
tooltips: {
mode: 'interpolate',
intersect: false
},
Yes, here's a screenshot
Ah, I forgot that you also need to add
interpolate: true
To your dataset configuration
I added it like this, but doesn't seem to work, am I putting that in the wrong place?
You need to add it to your datasets:
options: {
...
data: {
datasets: [
{color: ..., data:..., interpolate: true}
]
}
...
}
Weird, when I do it that way, the tooltips disappear and still no drag-dot. Any other ideas?
For reference, I am using ng2 charts to create this graph (if that helps) https://valor-software.com/ng2-charts/#LineChart
@kadenBeckstead - Were you able to fix your issue? I encountered the same problem with my graph.
@jsaucedo294 - Been a while, but as I recall, we went with a different charting solution. Sorry!