You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "pparth2302 (via GitHub)" <gi...@apache.org> on 2026/03/03 17:16:26 UTC
[D] Custom Color Selector for each line or bar [superset]
GitHub user pparth2302 created a discussion: Custom Color Selector for each line or bar
Im making an OEE Timeline chart where i want Green for Running and Red for Down and Yellow for changeover. But i have been unable to do that in a Gant chart because im so restricted to just using the color schema. Is there no way for me to specifcally select the colors for each range of data?
GitHub link: https://github.com/apache/superset/discussions/38363
----
This is an automatically sent email for notifications@superset.apache.org.
To unsubscribe, please send an email to: notifications-unsubscribe@superset.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [D] Custom Color Selector for each line or bar [superset]
Posted by "pparth2302 (via GitHub)" <gi...@apache.org>.
GitHub user pparth2302 deleted a comment on the discussion: Custom Color Selector for each line or bar
Hey Dosu,
Thanks for the help!
Though im unable to find the JSON metadata file.
FYI Im using version 6.0.0
GitHub link: https://github.com/apache/superset/discussions/38363#discussioncomment-15988326
----
This is an automatically sent email for notifications@superset.apache.org.
To unsubscribe, please send an email to: notifications-unsubscribe@superset.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [D] Custom Color Selector for each line or bar [superset]
Posted by "dosubot[bot] (via GitHub)" <gi...@apache.org>.
GitHub user dosubot[bot] edited a comment on the discussion: Custom Color Selector for each line or bar
<!-- Greeting -->
Hi @pparth2302! I'm [Dosu](https://go.dosu.dev/dosubot) and I’m helping the superset team.
<!-- Answer -->
Yes, you can assign specific colors to your OEE status values! The best approach is using **dashboard-level label colors**.
When you add your Gantt chart to a dashboard, edit the dashboard and go to **JSON Metadata** in the dashboard settings. Add a `label_colors` configuration like this:
```json
{
"label_colors": {
"Running": "#00AA00",
"Down": "#FF0000",
"Changeover": "#FFAA00"
}
}
```
This [takes precedence over the default color scheme](https://github.com/apache/superset/discussions/31855#discussioncomment-11839699) and will consistently apply Green for Running, Red for Down, and Yellow for Changeover across your charts.
Alternatively, you can [define a custom color palette in `superset/config.py`](https://github.com/apache/superset/discussions/37040) using `EXTRA_CATEGORICAL_COLOR_SCHEMES` if you want a reusable palette, but the dashboard metadata approach is simpler for your specific use case.
One caveat: [per-value color mapping through the chart UI itself is limited](https://github.com/apache/superset/issues/33836#issuecomment-2989492653), so the dashboard-level approach is currently the most practical solution without custom code.
<!-- Dosu Comment Footer -->
*To reply, just mention [@dosu](https://go.dosu.dev/dosubot?utm_source=github&utm_medium=bot-comment&utm_campaign=github-comment-footer-20260415&utm_content=reply-with-mention&utm_term=apache%2Fsuperset).*
---
Share context across your team and agents. Try [Dosu](https://dosu.dev?utm_source=github&utm_medium=bot-comment&utm_campaign=github-comment-footer-20260415&utm_content=knowledge-infrastructure-tagline&utm_term=apache%2Fsuperset).
[](https://app.dosu.dev/response-feedback?utm_source=github&utm_medium=bot-comment&utm_campaign=github-comment-footer-20260415&utm_content=knowledge-infrastructure-feedback&utm_term=apache%2Fsuperset&message_id=4b192d8a-f583-4564-a68c-c0ca7b74071a) [](https://github.dosu.com/apache/superset?utm_source=github&utm_medium=bot-comment&utm_campaign=github-comment-footer-20260415&utm_content=knowledge-infrastructure-learn-repo&utm_term=apache%2Fsuperset) [](https://app.dosu.dev/signup?referrer=openSource&source=github-footer&utm_source=github&utm_medium=bot-comment&utm_campaign=github-comment-footer-20260415&utm_content=knowledge-infrastructure-add-team&utm_term=apache%2Fsuperset)
GitHub link: https://github.com/apache/superset/discussions/38363#discussioncomment-15987660
----
This is an automatically sent email for notifications@superset.apache.org.
To unsubscribe, please send an email to: notifications-unsubscribe@superset.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [D] Custom Color Selector for each line or bar [superset]
Posted by "pparth2302 (via GitHub)" <gi...@apache.org>.
GitHub user pparth2302 added a comment to the discussion: Custom Color Selector for each line or bar
Hey Dosu,
Thanks for the help!
Though im unable to find the JSON metadata file.
FYI Im using version 6.0.0
GitHub link: https://github.com/apache/superset/discussions/38363#discussioncomment-15988326
----
This is an automatically sent email for notifications@superset.apache.org.
To unsubscribe, please send an email to: notifications-unsubscribe@superset.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [D] Custom Color Selector for each line or bar [superset]
Posted by "dosubot[bot] (via GitHub)" <gi...@apache.org>.
GitHub user dosubot[bot] added a comment to the discussion: Custom Color Selector for each line or bar
<!-- Greeting -->
Hi @pparth2302! I'm [Dosu](https://go.dosu.dev/dosubot) and I’m helping the superset team.
<!-- Answer -->
Yes, you can assign specific colors to your OEE status values! The best approach is using **dashboard-level label colors**.
When you add your Gantt chart to a dashboard, edit the dashboard and go to **JSON Metadata** in the dashboard settings. Add a `label_colors` configuration like this:
```json
{
"label_colors": {
"Running": "#00AA00",
"Down": "#FF0000",
"Changeover": "#FFAA00"
}
}
```
This [takes precedence over the default color scheme](https://github.com/apache/superset/discussions/31855#discussioncomment-11839699) and will consistently apply Green for Running, Red for Down, and Yellow for Changeover across your charts.
Alternatively, you can [define a custom color palette in `superset/config.py`](https://github.com/apache/superset/discussions/37040) using `EXTRA_CATEGORICAL_COLOR_SCHEMES` if you want a reusable palette, but the dashboard metadata approach is simpler for your specific use case.
One caveat: [per-value color mapping through the chart UI itself is limited](https://github.com/apache/superset/issues/33836#issuecomment-2989492653), so the dashboard-level approach is currently the most practical solution without custom code.
<!-- Dosu Comment Footer -->
*To reply, just mention [@dosu](https://go.dosu.dev/dosubot).*
---
<sup>How did I do? [Good](https://app.dosu.dev/response-feedback/4b192d8a-f583-4564-a68c-c0ca7b74071a?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/4b192d8a-f583-4564-a68c-c0ca7b74071a?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/4b192d8a-f583-4564-a68c-c0ca7b74071a?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/4b192d8a-f583-4564-a68c-c0ca7b74071a?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/4b192d8a-f583-4564-a68c-c0ca7b74071a?feedback_type=hallucination) | [Report 🐛](https://app.dosu.dev/response-feedback/4b192d8a-f583-4564-a68c-c0ca7b74071a?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/4b192d8a-f583-4564-a68c-c0ca7b74071a?feedback_type=other)</sup>
[](https://app.dosu.dev/a28d3c7e-a9d3-459e-9fb6-3a6f9ff4f357/ask?utm_source=github) [](https://cursor.com/link/prompt?text=Yes%2C%20you%20can%20assign%20specific%20colors%20to%20your%20OEE%20status%20values%21%20The%20best%20approach%20is%20using%20%2A%2Adashboard-level%20label%20colors%2A%2A.%0A%0AWhen%20you%20add%20your%20Gantt%20chart%20to%20a%20dashboard%2C%20edit%20the%20dashboard%20and%20go%20to%20%2A%2AJSON%20Metadata%2A%2A%20in%20the%20dashboard%20settings.%20Add%20a%20%60label_colors%60%20configuration%20like%20this%3A%0A%0A%60%60%60json%0A%7B%0A%20%20%20%20%22label_colors%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%22Running%22%3A%20%22%2300AA00%22%2C%0A%20%20%20%20%20%20%20%20%22Down%22%3A%20%22%23FF0000%22%2C%0A%20%20%20%20%20%20%20%20%22Changeover%22%3A%20%22%23FFAA00%22%0A%20%20%20%20%7D%0A%7D%0A%60%60%60%0A%0AThis%20%5Btakes%20precedence%20over%20the%20default%2
0color%20scheme%5D%28https%3A//github.com/apache/superset/discussions/31855%23discussioncomment-11839699%29%20and%20will%20consistently%20apply%20Green%20for%20Running%2C%20Red%20for%20Down%2C%20and%20Yellow%20for%20Changeover%20across%20your%20charts.%0A%0AAlternatively%2C%20you%20can%20%5Bdefine%20a%20custom%20color%20palette%20in%20%60superset/config.py%60%5D%28https%3A//github.com/apache/superset/discussions/37040%29%20using%20%60EXTRA_CATEGORICAL_COLOR_SCHEMES%60%20if%20you%20want%20a%20reusable%20palette%2C%20but%20the%20dashboard%20metadata%20approach%20is%20simpler%20for%20your%20specific%20use%20case.%0A%0AOne%20caveat%3A%20%5Bper-value%20color%20mapping%20through%20the%20chart%20UI%20itself%20is%20limited%5D%28https%3A//github.com/apache/superset/issues/33836%23issuecomment-2989492653%29%2C%20so%20the%20dashboard-level%20approach%20is%20currently%20the%20most%20practical%20solution%20without%20custom%20code.) [](https://go.dosu.dev/discord-bot) [](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/apache/superset/discussions/38363)
GitHub link: https://github.com/apache/superset/discussions/38363#discussioncomment-15987660
----
This is an automatically sent email for notifications@superset.apache.org.
To unsubscribe, please send an email to: notifications-unsubscribe@superset.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [D] Custom Color Selector for each line or bar [superset]
Posted by "pparth2302 (via GitHub)" <gi...@apache.org>.
GitHub user pparth2302 added a comment to the discussion: Custom Color Selector for each line or bar
Thanks for the help Dosu!
GitHub link: https://github.com/apache/superset/discussions/38363#discussioncomment-15988335
----
This is an automatically sent email for notifications@superset.apache.org.
To unsubscribe, please send an email to: notifications-unsubscribe@superset.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org