Skip to content
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

[Charts] Add ability to fully customize chart legends #5777

Open
1 task done
allen138 opened this issue May 3, 2024 · 0 comments
Open
1 task done

[Charts] Add ability to fully customize chart legends #5777

allen138 opened this issue May 3, 2024 · 0 comments
Labels
feature-request New feature or request SAP SF

Comments

@allen138
Copy link

allen138 commented May 3, 2024

Is your feature request related to a problem?

Currently, we can modify the position and the alignment of the chart legend via chartConfig. We can also specify if we want to hide the legend through component prop. But we cannot specify exactly how we want the legend to look. Similar to how we have a 'lineConfig' for the lineCharts exposed, we should have a legendConfig so we can fully utilize the props from the lib. https://recharts.org/en-US/api/Legend/.

Our designers would like to have something like this:
image

However, this is not easily achievable without having access to some of the props such as the legend formatter. If the flexibility of the formatter may still not satisfy the needs of the designers, than we can consider to use the content prop to have full control.

Describe the solution you'd like

Ability to have full control over the Legend component by exposing a config prop that would pass the to the underlying recharts component

Describe alternatives you've considered

No response

Additional Context

No response

Organization

SF

Declaration

  • I’m not disclosing any internal or sensitive information.
@allen138 allen138 added the feature-request New feature or request label May 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request New feature or request SAP SF
Projects
Status: 🆕 New
Development

No branches or pull requests

2 participants