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

fix: handle single value vis-type as highcharts chart instance #3289

Conversation

HendrikThePendric
Copy link
Contributor

@HendrikThePendric HendrikThePendric commented Nov 12, 2024

No issue number available

Note for efficient reviewing
This code includes quite a few changes. However, the vast majority of changes were cherry picked from branch #3135, which had already been reviewed. The only file I edited manually was src/components/VisualizationPlugin/ChartPlugin.js.


Key features

  1. Handles the single value visualization as a Highcharts.Chart instance, which it is since @dhis2/analytics version 26.9.0
  2. This new implementation will allow us to do client-side exports using Highchart's Chart.exportChartLocal (IN THE FUTURE, NOT NOW)
  3. Instead of computing the font-size directly on the canvas size, this new implementation scales in steps. This reduces the problem of multiple single value items in a single dashboard all showing a different font-sizes.

TODO

  • Cypress tests
  • Manual testing

@dhis2-bot
Copy link
Contributor

dhis2-bot commented Nov 12, 2024

🚀 Deployed on https://pr-3289.data-visualizer.netlify.dhis2.org

@dhis2-bot dhis2-bot temporarily deployed to netlify November 12, 2024 14:59 Inactive
@dhis2-bot dhis2-bot temporarily deployed to netlify November 12, 2024 15:04 Inactive
@dhis2-bot dhis2-bot temporarily deployed to netlify November 12, 2024 16:14 Inactive
@HendrikThePendric HendrikThePendric self-assigned this Nov 13, 2024
@HendrikThePendric HendrikThePendric added the e2e record Apply this label to a pull request to trigger recording of E2E tests on Cypress Cloud label Nov 13, 2024
Copy link

cypress bot commented Nov 13, 2024

Data Visualizer App    Run #2960

Run Properties:  status check passed Passed #2960  •  git commit 3e952e9310 ℹ️: Merge 44aa4155b26e0efd81ce19feda90e8836a71d34e into 81c9ec3682f0a8843ea84cf754c1...
Project Data Visualizer App
Branch Review feat/use-analytics-version-with-single-value-as-highcharts-chart
Run status status check passed Passed #2960
Run duration 09m 27s
Commit git commit 3e952e9310 ℹ️: Merge 44aa4155b26e0efd81ce19feda90e8836a71d34e into 81c9ec3682f0a8843ea84cf754c1...
Committer Hendrik de Graaf
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 1
Tests that did not run due to a developer annotating a test with .skip  Pending 2
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 734
View all changes introduced in this branch ↗︎

@dhis2-bot dhis2-bot temporarily deployed to netlify November 13, 2024 09:53 Inactive
@dhis2-bot dhis2-bot temporarily deployed to netlify November 13, 2024 09:59 Inactive
@HendrikThePendric HendrikThePendric removed the e2e record Apply this label to a pull request to trigger recording of E2E tests on Cypress Cloud label Nov 13, 2024
@HendrikThePendric HendrikThePendric merged commit 83d0e6c into master Nov 13, 2024
34 of 35 checks passed
@HendrikThePendric HendrikThePendric deleted the feat/use-analytics-version-with-single-value-as-highcharts-chart branch November 13, 2024 14:53
dhis2-bot added a commit that referenced this pull request Nov 13, 2024
## [100.8.5](v100.8.4...v100.8.5) (2024-11-13)

### Bug Fixes

* handle single value vis-type as highcharts chart instance ([#3289](#3289)) ([83d0e6c](83d0e6c))
@dhis2-bot
Copy link
Contributor

🎉 This PR is included in version 100.8.5 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

3 participants