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

Allow Data decimation for line like custom charts #9943

Closed
Geigerkind opened this issue Dec 2, 2021 · 2 comments · Fixed by #10182
Closed

Allow Data decimation for line like custom charts #9943

Geigerkind opened this issue Dec 2, 2021 · 2 comments · Fixed by #10182
Assignees
Milestone

Comments

@Geigerkind
Copy link

Feature Proposal

I suggest that every chart type that extends LineController should be applicable to the decimation plugin.

Currently due to this line, this is not possible:

if (meta.type !== 'line') {
        // Only line datasets are supported
        return;
}

Feature Use Case

I extend the LineController in order to use a line chart, but to also extend the graph with a fancy hover animation, were a custom Pin is shown to highlight the "X" position. As this is still a line chart, I would still really like to make use of the decimation plugin.

Possible Implementation

I dont know the code base. Ideally it would be something along the lines that you check the if something is a LineController.
I can also see that you could add another option like isDecimatable, so a user can tell you that its fine anyway?

if (meta instanceOf LineController) {
        return;
}
@ShaneZhengNZ
Copy link

Totally agree with this. I am trying to get Decimation working on a scatter chart. From my perspective, the scatter chart should be compatible with the line chart data decimation.

@etimberg
Copy link
Member

I opened #10182 to support this. Each controller now exposes a supportsDecimation boolean that if true, enables the decimation plugin.

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

Successfully merging a pull request may close this issue.

3 participants