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

Update AdvancedFilters to use createInterpolateElement instead of interpolateComponents #37967

Merged
merged 29 commits into from Apr 26, 2023

Conversation

mattsherman
Copy link
Contributor

@mattsherman mattsherman commented Apr 24, 2023

Submission Review Guidelines:

Changes proposed in this Pull Request:

This PR updates the AdvancedFilters component in @woocommerce/components to use createInterpolateElement from @wordpress/element instead of interpolateComponents from @automattic/interpolate-components.

Usage of AdvancedFilters in plugins/woocommerce-admin has also been updated. Specially, the following screens are affected:

  • WooCommerce > Customers
  • Analytics > Orders
  • Analytics > Variations
  • Analytics > Downloads

Each of those screens has a Show > Advanced filters option that uses AdvancedFilters.

No functionality has been changed. The screens above should behavior exactly as they did before.

For example, here is what the Analytics > Orders advanced filters look like:

Screenshot 2023-04-25 at 15 01 38

Part of #37312.

How to test the changes in this Pull Request:

Using the WooCommerce Testing Instructions Guide, include your detailed testing instructions:

  1. Verify Storybook stories look correct:
    • pnpm --filter=@woocommerce/storybook storybook
    • There are some slight styling issues not due to this PR... as long as filter controls appear and testing of actual product screens looks correct, these can be ignored
    • AdvancedFilters > Basic
    • ReportFilters > Examples > Advanced filters
  2. Verify the use of advanced filters on WooCommerce > Customers
  3. Verify the use of advanced filters on Analytics > Orders
  4. Verify the use of advanced filters on Analytics > Variations
  5. Verify the use of advanced filters on Analytics > Downloads

@mattsherman mattsherman self-assigned this Apr 24, 2023
@github-actions github-actions bot added focus: react admin [team:Ghidorah] package: @woocommerce/components issues related to @woocommerce/components plugin: woocommerce Issues related to the WooCommerce Core plugin. labels Apr 24, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Apr 25, 2023

Test Results Summary

Commit SHA: 6efa264

Test 🧪Passed ✅Failed 🚨Broken 🚧Skipped ⏭️Unknown ❔Total 📊Duration ⏱️
API Tests26700202690m 52s
E2E Tests1870010019715m 45s

To view the full API test report, click here.
To view the full E2E test report, click here.
To view all test reports, visit the WooCommerce Test Reports Dashboard.

@mattsherman mattsherman force-pushed the update/interpolate-advanced-filters branch from 70c7dd1 to f818b60 Compare April 25, 2023 17:50
@codecov
Copy link

codecov bot commented Apr 25, 2023

Codecov Report

Merging #37967 (f818b60) into trunk (7a63646) will decrease coverage by 0.2%.
The diff coverage is 14.5%.

❗ Current head f818b60 differs from pull request most recent head 6efa264. Consider uploading reports for the commit 6efa264 to get more accurate results

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             trunk   #37967     +/-   ##
==========================================
- Coverage     51.5%    51.3%   -0.2%     
- Complexity   17281    17409    +128     
==========================================
  Files          430      440     +10     
  Lines        80030    80561    +531     
==========================================
+ Hits         41215    41293     +78     
- Misses       38815    39268    +453     
Impacted Files Coverage Δ
...mmerce/includes/admin/class-wc-admin-importers.php 0.0% <0.0%> (ø)
...merce/includes/admin/class-wc-admin-post-types.php 9.5% <0.0%> (ø)
...rters/class-wc-product-csv-importer-controller.php 35.3% <0.0%> (-0.1%) ⬇️
...ugins/woocommerce/includes/class-wc-post-types.php 1.0% <0.0%> (-0.1%) ⬇️
...ludes/tracks/events/class-wc-importer-tracking.php 0.0% <0.0%> (ø)
...ludes/wccom-site/class-wc-wccom-site-installer.php 0.0% <0.0%> (ø)
...ation/class-wc-wccom-site-installation-manager.php 0.0% <0.0%> (ø)
...class-wc-wccom-site-installation-state-storage.php 0.0% <0.0%> (ø)
...llation/class-wc-wccom-site-installation-state.php 0.0% <0.0%> (ø)
...-wccom-site-installation-step-activate-product.php 0.0% <0.0%> (ø)
... and 15 more

@mattsherman mattsherman marked this pull request as ready for review April 25, 2023 19:20
@octaedro octaedro self-requested a review April 25, 2023 20:56
@github-actions
Copy link
Contributor

Hi @octaedro,

Apart from reviewing the code changes, please make sure to review the testing instructions as well.

You can follow this guide to find out what good testing instructions should look like:
https://github.com/woocommerce/woocommerce/wiki/Writing-high-quality-testing-instructions

Copy link
Contributor

@octaedro octaedro left a comment

Choose a reason for hiding this comment

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

Good job @mattsherman! LGTM 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
package: @woocommerce/components issues related to @woocommerce/components plugin: woocommerce Issues related to the WooCommerce Core plugin.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants