c3js / c3

:bar_chart: A D3-based reusable chart library
http://c3js.org
MIT License
9.34k stars 1.39k forks source link

Tooltip options #1050

Closed netAction closed 7 years ago

netAction commented 9 years ago

An option to group tooltip values only when they are in a small range would be nice. This is important since I don't have the cursor's value in tooltips.contents option to fix it myself.

It should be possible to order the entries of grouped tooltips by value. Is there a way to run getTooltipContent() from tooltip.js in a tooltips.contents option to achieve this behaviour manually? If not, it would be great to have a tooltips.contents example with the default behaviour.

markdboyd commented 9 years ago

I'm not sure if this is what you are looking for, but there is the ability to override the tooltip contents function via an option:

http://c3js.org/reference.html#tooltip-contents

In terms of the default behavior for tooltips, I think this covers it:

https://github.com/masayuki0812/c3/issues/444#issuecomment-53986614

kriticism commented 9 years ago

image

It seems that using 'data.order : null' has caused the shown stacking bottom-to-top in the stacked chart, top-to-bottom in tool-tip, and left-to-right in the legend. I want to change the order of contents displayed in the tool-tip. Like VNe on top, then Ne, then N and so on. Or any other customization (which, say, is stored in an array). How do i do that?

michaelrodov commented 8 years ago

Hi there If this Is still relevant please provide a more detailed description of the desired functionality, including drawings when needed and use cases. thank you for understanding

aashish-chaubey commented 6 years ago

Hey people I am having an issue with the tooltip. I did not open a separate issue for this because it seems to be a responsiveness issue.

tooltip-issue

Please look at the above image. The tooltip text goes on the next line. How to fix this.

Thanks

sibasishm commented 6 years ago

Hey people, I am trying to add a functionality in my line chart create using C3. I want to hide the tooltip when the value is 0 and show it only for data points having non-zero values, is it possible? Please suggest me how to accomplish this. Thanks.

aaronELBorg commented 3 years ago

I too would like the functionality mentioned by sibasishm. Has it been added? Thank you.