How do I color specific bars in XY Chart? #5491
Unanswered
LizThompson93
asked this question in
Q&A
Replies: 1 comment
-
The colors your assign using the It's not optimal, but a solution to this use case would be this: ---
config:
xyChart:
width: 500
height: 500
chartOrientation: horizontal
themeVariables:
xyChart:
titleColor: "#ff0000"
plotColorPalette: "#ff0000, #434455"
---
xychart-beta
title "Sales Revenue"
x-axis ["A", "B", "C", "D"]
y-axis "Revenue (in $)" 0 --> 100
bar [16.0, 21.8, 71.5, 8.3]
bar [0, 21.8, 71.5, 8.3]
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Documentation: https://mermaid.js.org/syntax/xyChart.html#chart-theme-variables
Expectation: Specifically make the first bar red, and the other three bars dark gray.
Current: It applies the first color to all bars.
Am I using plotColorPalette wrong? It only applies the first color in the list to all bar instead of the first bar.
Beta Was this translation helpful? Give feedback.
All reactions