Skip to content

Tooltip not displaying data with dynamic keys in BarChart #2583

Answered by plouc
vladimirzb asked this question in Q&A
Discussion options

You must be logged in to vote

@vladimirzb, thank you, it really helped :)

So the tooltips are working, the problem comes from your styles:

@media (prefers-color-scheme: dark) {
  :root {
    --foreground-rgb: 255, 255, 255;
  }
}

body {
  color: rgb(var(--foreground-rgb));
}

By default the text color is white, and so is the tooltip background, that's why it seems empty, you can either adjust your css or pass a theme to the chart:

theme={{ tooltip: { wrapper: { color: "#000000" } } }}

Replies: 3 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@vladimirzb
Comment options

Answer selected by vladimirzb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
2 participants