-
Notifications
You must be signed in to change notification settings - Fork 36
DonutChart: Tooltips of inner layers are wrong #58
Comments
Hi, this is most propably not a problem of this addon but of the underlying chartjs javascript library. It may be fixed in the latest js release but I'm not sure. So please try to reproduce in pure javascript and in case it's really a js bug report it in ChartJS repo. thanks, Michael |
Hi @sebastiansto, could you share your code. It would help me a lot hunting your problem down. BR |
Hi Michael, Thank you for the fast response. My code looks like this:
BR |
Is this your real config? You have 2 datasets and only add values equals 1.0.
Please recheck your config. |
The tooltips in this example work. Unfortuantly I'm not sure want you mean by "stuck"
|
It's a node count, so yes, it's correct. application.getApplicationType().name() would be something like this: applicationIdDataset.addLabeledData(application.getApplicationId(), 1.0); would be something like this: The combinations like TYPE_A and TYPE_A_APP01 can exist multiple times in the list (for every node there is). When I now go over the outer layer, the tooltip is fine: But when I move my mouse over the inner layer e.g. TYPE_A_APP01, I still get the outer layers tooltip: I think the problem here is, that I only add the outer layer to the label list (I don't want to see every subcategory there). But then it doesn't generate the inner tooltips. BR P.S.: The Clicklistener shows always the correct data. |
Ok thx for the clearification. This is indeed weared. Could you please enable the javascript logging
and paste the json config output here. |
Sure:
|
I think I now understand what's the difference between your need and the demo example. The data in the inner "ring" has nothing in common with the outer ring. I searched for a chartjs example but did not find one. So please create a plunkr in javascript with chartjs for your need and post the link here. Right now I can not do any further research but if this is possible with javascript I will include it in the next release. |
Ok, thank you for your help so far. BR |
Hi, sorry for the long wait. I played around a little and this is what would work for me:
I added labels into the dataset and used the callback method for label. BR |
Hi Sebastian, thanks for taking the time to try this. I feared that a JS callback function is the only way to realize your request/question. I will try to find a solution but can not give you a specific timeline. I hope to get it done in November. BR |
Hi Michael, Thank you for taking this on. On my side this isn't an urgent matter. BR |
Hi Michael, Are there any plans yet regarding the JS callback function? BR |
Hi there,
When you have multiple layers in a DonutChart, the tooltips of the inner layers are not correct.
The tooltip is always "stuck" with the outer tooltip.
It would be nice, if the correct data of the layer is used (like in the ClickListener):
BR
The text was updated successfully, but these errors were encountered: