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

Line chart dataset order is wrong #2719

Closed
dmig opened this issue Jun 6, 2016 · 7 comments
Closed

Line chart dataset order is wrong #2719

dmig opened this issue Jun 6, 2016 · 7 comments

Comments

@dmig
Copy link

dmig commented Jun 6, 2016

This fiddle shows the problem: https://jsfiddle.net/dmig/97pxd7eL/4/

When I specify datasets, I expect them to be drawn in that order:

  datasets: [
    {
        label: "Blue", 
      fill: true, 
      backgroundColor: "rgba(32, 162, 219, 1)",
      data: dataPack1,
    },
    {
        label: "Red",
      fill: true,
      backgroundColor: "rgba(196, 93, 105, 1)",
      data: dataPack2,
    },
    ]

Workaround is to reverse their order, but label order in legend/tooltips is also reversed,

@etimberg
Copy link
Member

etimberg commented Jun 6, 2016

Similar to a bunch of other issues that are open, but I can't find them at the moment.

@Jaded-Design
Copy link

If you could just point me to the section where you choose the render order of datasets I could take a look, just don't have time to dig around looking.

Also, here is that similar issue: #2219

@etimberg
Copy link
Member

etimberg commented Jul 9, 2016

@etimberg
Copy link
Member

This will be resolved in #4008 which adds the ability to fill to another dataset. This means that the draw order will become irrelevant since the correct solution for the blue dataset will be to fill to the red one instead of all the way down to 0

@etimberg
Copy link
Member

etimberg commented Jul 3, 2017

Tied in with my comment on #2219

@etimberg etimberg marked this as a duplicate of #4578 Jul 28, 2017
@etimberg
Copy link
Member

Closing per my comment from march. This can be fixed using the fill to other dataset functionality. See https://jsfiddle.net/gz4ev7jr/

@Alumniminium
Copy link

fill to other dataset functionality

Closing per my comment from march. This can be fixed using the fill to other dataset functionality. See https://jsfiddle.net/gz4ev7jr/

Funny how your jsfiddle doesn't work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants