-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tooltip colors for Pie/Donut charts don't reflect custom colors #2980
Tooltip colors for Pie/Donut charts don't reflect custom colors #2980
Comments
Had the same problem when forcing chart colours as you did. var options = {
chart: {
height: 380,
width: "100%",
type: "donut",
labels: ["Apple", "Orange", "Mango"]
},
fill: {
colors: ["#f44336", "#ff9800", "#4caf50"]
},
series: [1, 5, 10],
legend: {
// Show the legend
show: true,
markers: {
// Set the legend colors as the ones passed in
fillColors: ["#f44336", "#ff9800", "#4caf50"]
}
},
tooltip: {
enabled: true,
fillSeriesColor: true
},
colors: ["#f44336", "#ff9800", "#4caf50"] //Add this line
}; |
Thanks it helps me a lot |
I recently have a problem with tooltip im displaying in web, the problem occurs when the light theme is on, i mean THIS:
The tooltip is displaying fine, but the information on it shows white and the background is white so... ik this problem can be fixed changing the theme color to dark or this solution i applied:
Im changing the tooltip theme to dark, so the tooltip background changes to black and you can see now your information on color white, i've been searching about change color for the tooltip but i only can find how to change the background color on CSS, not the color text, i'm already post this issue on this repo but they closed my issue, so if someone who works on apex charts can add a way to change the info color it could be awesome. Hope my post help anyone folks. |
This does not work for me. Are you using the latest version of apexcharts? I am and I still see the problem. Can you try fixing it in the link I posted in the description of the issue? |
You are right about using the This didn't work: fill: {
colors: this.colors,
},
colors: this.colors,
tooltip: {
enabled: true,
fillSeriesColor: true,
}, But this does and fixes the issue: fill: {
colors: this.colors,
},
colors: this.colors,
tooltip: {
enabled: true,
}, |
Description
Can't seem to change the color of the tooltip and the donut labels displayed inside the chart. I updated the colors for the legend and the actual slices but not the tooltip and inside label.
Steps to Reproduce
Chart options that reproduce the issue:
Expected Behavior
The tooltip and the inside labels should use the same colors as the chart slices and legend.
Screenshots
Reproduction Link
See the code here:
https://codepen.io/stanivanov/pen/WNXZvZE
The text was updated successfully, but these errors were encountered: