Skip to content

[WC-2922]: Add aggregate utils for charts #1562

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

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

rahmanunver
Copy link
Contributor

Pull request type

Bug fix (non-breaking change which fixes an issue)


Description

Added a new aggregations.ts in the charts utilities to be used instead of the deprecated plotly.js aggregations.

What should be covered while testing?

All Charts (area, bar, bubble, column, line, time-series) should have working aggregations displayed in the charts/graphs.

@rahmanunver rahmanunver requested a review from a team as a code owner May 8, 2025 15:55
@rahmanunver rahmanunver force-pushed the wc-2922_charts-aggregate-utils branch from 068af2d to 190c64e Compare May 8, 2025 15:55
const pts =
line.aggregationType === "none"
? dataPoints
: aggregateDataPoints(line.aggregationType, dataPoints);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

checking type none is already done in the function aggregateDataPoints. this is no longer needed

@gjulivan
Copy link
Collaborator

gjulivan commented May 8, 2025

i think we can remove all transform property from all charts,
and simply put aggregateDataPoints inside extractDataPoints function.
this way all other charts code are intact.

maybe need to add
aggregationType: AggregationTypeEnum; to PlotDataSeries
to complete the type.
the data seems to be already there

@rahmanunver rahmanunver force-pushed the wc-2922_charts-aggregate-utils branch 2 times, most recently from c47560c to 6314070 Compare May 20, 2025 09:13
@rahmanunver rahmanunver force-pushed the wc-2922_charts-aggregate-utils branch from 29a1379 to c2f33aa Compare May 20, 2025 14:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants