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

Add Global mode to TimeSeriesWidget #377

Merged

Conversation

Clebal
Copy link
Contributor

@Clebal Clebal commented Apr 20, 2022

No description provided.

@Clebal Clebal requested a review from VictorVelarde April 20, 2022 10:22
@shortcut-integration
Copy link

This pull request has been linked to Shortcut Story #219452: TimeSeriesWidget - global (remote) mode.

…sc-219452/timeserieswidget-global-remote-mode
@coveralls
Copy link
Collaborator

coveralls commented Apr 20, 2022

Pull Request Test Coverage Report for Build 2196645397

  • 52 of 55 (94.55%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.5%) to 74.799%

Changes Missing Coverage Covered Lines Changed/Added Lines %
packages/react-widgets/src/models/TimeSeriesModel.js 52 55 94.55%
Totals Coverage Status
Change from base Build 2194753017: 0.5%
Covered Lines: 1444
Relevant Lines: 1825

💛 - Coveralls

DAYS = 'days',
HOURS = 'hours',
MINUTES = 'minutes'
YEARS = 'year',
Copy link
Contributor

Choose a reason for hiding this comment

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

Out of curiosity, why this change?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Because in all the providers, these operations are singular :(

Comment on lines 122 to 125
value:
value.filter((_, idx) => idx % 2 === 0).reduce((acc, [val]) => acc + val, 0) /
value.filter((_, idx) => idx % 2 !== 0).reduce((acc, [val]) => acc + val, 0)
}));
Copy link
Contributor

Choose a reason for hiding this comment

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

This final part is a bit obscure, can you comment (or use some better variable names)?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I agree. I'm going to improve it now.

Copy link
Contributor

@VictorVelarde VictorVelarde left a comment

Choose a reason for hiding this comment

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

👍🏻

@VictorVelarde VictorVelarde merged commit 051de2c into master Apr 20, 2022
@VictorVelarde VictorVelarde deleted the feature/sc-219452/timeserieswidget-global-remote-mode branch April 20, 2022 15:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants