-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Labels
feature:builtin-chartsgood first issueGood for newcomersGood for newcomerstype:enhancementRequests for feature enhancements or new featuresRequests for feature enhancements or new features
Description
Checklist
- I have searched the existing issues for similar feature requests.
- I added a descriptive title and summary to this issue.
Summary
Our built-in charts (e.g. st.area_chart, st.line_chart, etc) have a color parameter. But this parameter does not accept the built-in color names we use e.g. for colored Markdown text or st.badge (red, orange, yellow, blue, green, violet, gray/grey, or primary). We should support those as well!
Why?
- Makes our commands more consistent
- Makes it easier to pick colors that look good and consistent with the rest of the app.
- Allows theming these colors.
How?
- The
colorparameter forst.area_chart,st.line_chart,st.bar_chart,st.scatter_chartshould accept the following colors: red, orange, yellow, blue, green, violet, gray/grey, or primary - This should work just like a HEX or RGB string for long and wide formats and for single and multiple series.
- The charts should use the "main" colors from theming, e.g.
theme.redColorifcolor="red"is set. - In the docstring, we should list the built-in color names as the first option and also show them in examples if we add some, so we drive users towards using these nice and simple colors instead of having to find their own custom colors.
Additional Context
Related:
github-actions, tanushka-jha23 and iyertrisha
Metadata
Metadata
Assignees
Labels
feature:builtin-chartsgood first issueGood for newcomersGood for newcomerstype:enhancementRequests for feature enhancements or new featuresRequests for feature enhancements or new features