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 ComparativePieWidgetUI #510

Merged
merged 8 commits into from
Nov 25, 2022
Merged

Conversation

juandjara
Copy link
Contributor

Description

This PR implements part of the work proposed in RFC #479

Changes added in this PR include:

  • A new widget called ComparativePieWidgetUI in the widgets folder
  • Typescript typings for ComparativePieWidgetUI
  • JSDoc typings comments for ComparativePieWidgetUI
  • Prop-types validation for ComparativePieWidgetUI
  • A basic storybook story for ComparativePieWidgetUI where all prop combinations can be tested and tweaked. A screenshot of this storybook is added as visual feedback.

Captura de pantalla 2022-10-26 a las 16 22 53

Type of change

  • Feature

Acceptance

  1. Open the local storybook running yarn storybook:start in the react-ui folder.
  2. Pick a set of properties to use for testing by tweaking the storybook configuration.
  3. Use this set of properties to render a ComparativePieWidgetUI in your sample project, by importing ComparativePieWidgetUI from @carto/react-ui. You can use this branch of carto-react-template to skip this step if you want, as a test screen is already setup there. Bear in mind that if this feature is not published to npm you will have to link your local version of @carto/react-* packages with yarn link.
  4. Check that the rendered version of the widget in your sample project looks the same as it looks in the storybook.

Basic checklist

  • Good PR name
  • Shortcut link
  • Changelog entry
  • Just one issue per PR
  • GitHub labels
  • Proper status & reviewers
  • Tests
  • Documentation

@coveralls
Copy link
Collaborator

coveralls commented Oct 26, 2022

Pull Request Test Coverage Report for Build 3549580545

  • 32 of 60 (53.33%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.8%) to 71.62%

Changes Missing Coverage Covered Lines Changed/Added Lines %
packages/react-ui/src/widgets/comparative/ComparativePieWidgetUI.js 32 60 53.33%
Totals Coverage Status
Change from base Build 3494786134: -0.8%
Covered Lines: 1879
Relevant Lines: 2434

💛 - Coveralls

@juandjara
Copy link
Contributor Author

@VictorVelarde test for comparative Pie Widget UI are now ready. I've added a small change to test utils to support this, let know if you find any problem with that pls.

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.

Looks really nice, thx for contributing Juan!

@VictorVelarde VictorVelarde merged commit 2ca036d into master Nov 25, 2022
@VictorVelarde VictorVelarde deleted the feature/comparative-pie-widget branch November 25, 2022 16:58
@VictorVelarde VictorVelarde changed the title Comparative Pie Widget UI Add ComparativePieWidgetUI Nov 25, 2022
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