-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Fix Series Chart examples #1781
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
Conversation
Hi @kum-deepak! If you want me to review this, could you please articulate the problem as well as the solution? It's difficult to review code without knowing its purpose. Yes, any coordinate grid chart can be used in a Series chart. I guess that affected the design of this PR, but it doesn't tell me what the PR is for. It looks like this PR has something to do with the inconsistency of having to using |
You did pick up the correct one without me being clear. I will put more details:
|
Thanks, I think I get it. I would have thought that the scatter series example would cover this case. Was it not working, or working by accident, before this fix? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sound good! Thanks for all your efforts!
I realize that the next set of work around dimensions is going to break test cases and charts. So, before getting deeper I wanted to check if all examples work. That is when I found issues with the Cumulative Line Chart and Scatter Series were not working. During the fix I further realized that there were few minor issues in the current It was the Scatter Series example was miserably failing which gave me idea that something fundamental has gone wrong, I think I am getting some hang of this library 😄 |
Before moving deeper into dimension related work, I wanted to ensure that related examples work. While going through these I realized that Series chart can be used in far more ways than what I had considered.
I had assumed, incorrectly, that only Stack based charts can be used as children in Series charts. The final solution that I came up with involves following:
groupName
is now part of dataProvider. Very few charts use it and ealier it was tangled with group and stack which is no longer the case.group
as the first layer if it is set. This in my opinion gives best of the world. If someone wants to initialize just one layer, they can alternatily configure it like most of the other charts by setting thegroup
. However if they want more than one layer they need to setlayers
. Unlike earlier,group
is not mandatory.