Open hnfishwu opened 2 years ago
@hnfishwu you can use .segmentTooltipContent
for that purpose.
@vasturiano
Could you give me some example to use this .segmentTooltipContent
?
I have tried this but the tooltip only can show the val or timerange.
I would like to show different tooltip on different segment , and the tooltip is not val or timerange.
Do you have any suggestion? Thanks.
@hnfishwu the segment data is included in the callback function of .segmentTooltipContent
.
So you can do something like:
.segmentTooltipContent(d => d.data.myCustomTooltipText)
@vasturiano Thanks a lot. It works.
I would like to add more additional data on tooltip. I know I can use
myChart.zDataLabel('<div>Additional <b>data</b></div>')
to add more text.But I want to show different text on different segments. Is it possible? Thanks.