Commit Graph

64152 Commits

Author SHA1 Message Date
github-actions[bot] 9fb0aacc25
Delete changelog files based on PR 48077 (#48093)
Delete changelog files for 48077

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-06-03 16:31:27 +08:00
Bart Kalisz 44efb7ffac
Blocks E2E: Use layout-based selectors in Thumbnails block tests (#47904)
* Use layout-based selectors in Thumbnails block tests

* improve test readability

* add changelog entry
2024-06-03 10:26:27 +02:00
Seghir Nadir b4efa72b07
Revert "Add phone number to my account shipping address. (#47062)" (#48077)
* Revert "Add phone number to my account shipping address. (#47062)"

This reverts commit 4840af874a.

* Add changefile(s) from automation for the following project(s): woocommerce

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-03 09:11:02 +02:00
Adrian Moldovan d2bde1368a
Tweak the changes configuration for e2e and api tests (#48067) 2024-05-31 07:49:49 -07:00
Maikel Perez a0f9d159e5
New image empty state for variations (#47909)
* Fix the variations image block placeholder to show only one image

* Add changelog file
2024-05-31 11:14:33 -03:00
Sam Seay b04c8bb9ec
Add path ignore to assess bundle action to reduce how often it runs (#48058) 2024-06-01 00:46:44 +12:00
Roy Ho b85e1aa402
Use correct AND expression (#48011)
* Use correct AND expression

* Add changefile(s) from automation for the following project(s): woocommerce-blocks

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-31 05:23:57 -07:00
Barry Hughes 9403cc46ba
Do not update the `last_access` field of API keys unnecessarily. #47912) 2024-05-31 12:44:01 +02:00
github-actions[bot] c44af56029
Delete changelog files based on PR 47994 (#48043)
Delete changelog files for 47994

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-05-31 16:51:34 +08:00
github-actions[bot] be89612237
Delete changelog files based on PR 47004 (#48041)
Delete changelog files for 47004

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-05-31 16:36:47 +08:00
Luigi Teschio 0712c6037b
Add To Cart Form: Improve the default style and add the `Stepper` style (#47664)
* Add To Cart Form: Improve the default style and add the Stepper style

* fix height button when no variation is selected

* not allow the user to set 0 as value of the input

* format css

* fix padding

* format css

* fix CSS

* unset margin to align with the button
2024-05-31 10:25:04 +02:00
github-actions[bot] 2b319684e2
Delete changelog files based on PR 47798 (#47982)
Delete changelog files for 47798

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-05-31 16:20:35 +08:00
Chi-Hsuan Huang 8cbf2356ff
Update LYS survey completion track prop names (#47985)
* Update survey completion track in Congrats component

* Add changelog

* Update prop name

* Fix survey score
2024-05-31 15:06:45 +08:00
Chi-Hsuan Huang c49960df74
Fix coming soon footer banner doesn't display properly on tablet and mobile (#47980)
* Fix coming soon footer banner doesn't display properly on tablet and mobile

* Add changelog

* Fix test

* Revert button text change

* Revert test change
2024-05-31 15:05:59 +08:00
github-actions[bot] 239d33d70e
Delete changelog files based on PR 47871 (#47946)
Delete changelog files for 47871

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-05-31 15:03:19 +08:00
Karol Manijak fe30778293
Increase product excerpt default length in Single Product template and block (#47651)
* Increase the length of Product Summary block (core/post-excerpt variation)

* Add changelog

* Bring back the Product Summary variation to original length

* Increase the Product Summary length to max 100 words in Single Product template and block

* Increase the Product Summary length to max 100 words in Single Product block

* Update tests

* Change the attribute type froms tring to niumber as expected
2024-05-31 08:19:06 +02:00
Patricia Hillebrandt 5dd7713346
[Performance]: Replace `classnames` usage with `clsx` (#47760)
* Replace classnames with clsx within woocommerce-blocks.

* Undo unnecessary change to getClassnames const.

* Replace classnames with clsx within woocommerce-admin.

* Add changelog.

* Update the pnpm lock file

* Address lint.

* Address lint errors for the block-library.
2024-05-31 05:49:36 +02:00
Chi-Hsuan Huang 38dbde4ba8
Clean up tasklist progression headercard experiment (#47983)
* Clean up tasklist progression headercard experiment

* Add changelog
2024-05-31 11:45:12 +08:00
Manzur Ahammed a7ade5d2dc
Show notice for expired and expiring subscriptions in settings and in-app extensions page (#47004)
* show notice on WC core about subs expired

* add notice in wc core my subscription page

* dismiss subscription notice

* add rest api for dismiss subscription notioce

* dismiss notice permanently

* code refactor

* fix issue in expired subs

* not showing expiring subs notice if expired sub notice render

not showing expiring subs notice if expired sub notice render

* fix lint

* added changelog

* update comment

* fix js lint

* update response

* added new endpoint for notice

* update the endpoint URL

* update the endpoint URL

* show notice after one month

* add css class for refactor

* fix lint

* Add missing callback after the merge

* check plugin is installed on current site

* add comments, and fix missing price

* fix lint

* remove unnecessary duplicate asset load

* fix notice so that it only trigger dismiss API on notices close

* localize the renew product price

* track events in the wc settings page

* Use the correct field product_regular_price instead of product_price

* Add missing period in the notice message

* add nonce to the dismiss notice API

* extract dismiss notice API call to different code

* extract expired and expiring component to 1 component

* add track events for tsx components

* fix nonce checking

* fix lint

* fix lint

* enrich the button and hyperlink url to contains the product_id of expiring / expired subscription

* fix lint

* fix lint

---------

Co-authored-by: Akeda Bagus <akeda.bagus@automattic.com>
Co-authored-by: prahesa.setia <prahesa.kusuma.setia@automattic.com>
2024-05-31 08:34:36 +07:00
Moon 04a5e67d88
LYS - Delete WooPay test orders on launch (#47832)
* Add woopayments/test-orders-count endpoint

* Load test order count

* Call deleteTestOrders

* Remove test code

* Use wc_get_orders to retrive test orders

* Add changefile(s) from automation for the following project(s): woocommerce

* typecast deleteTestOrders

* Type removeTestOrders input

* Remove woopayment activation check -- do not need as we are using wc_get_orders

* Add tests for test order count and delete endpoints

* Delete test class

* Add tests for test order count and delete endpoints

* Lint fixes

* Lint fixes

* Lint fixes

* Remove unused import

* Fix timing issue with counting test orders

* Add hasWooPayments guard

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: rjchow <me@rjchow.com>
2024-05-30 16:19:30 -07:00
Barry Hughes 3bf01a50d3
Fix the permissions check for customer downloads REST API endpoints. (#47854)
Ensures the customer ID is actually retrieved during a permissions check.

Fixes #27109
2024-05-30 16:04:20 -07:00
Brent MacKinnon 64281612aa
docs: Adding Performance category and best practices (#48027) 2024-05-30 17:01:28 -04:00
Brent MacKinnon 50396961b0
Adding tutorials for Extensible Product Type Onboarding and Tour Guide (#48024) 2024-05-30 15:22:39 -04:00
Sam Seay de5d73061d
Introduce asset size check action to CI (#47880) 2024-05-31 05:08:28 +12:00
Brent MacKinnon 0606b9580b
Docs: Adding Best Practices for Compatibility, Maintainability, Privacy Standards, Support and Documentation (#47976)
Adding quality+best practices docs
2024-05-30 12:40:59 -04:00
Manish Menaria 4bee1547b7
Fix: "On Sale" collection isn't displaying on Editor side (#47994)
* Fix the issue

* Add changefile(s) from automation for the following project(s): woocommerce-blocks

* Add E2E test to cover this regression

* Fix: On sale collection should be visible after refresh in Post

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-30 21:55:49 +05:30
github-actions[bot] 8519e621e4
Delete changelog files based on PR 47987 (#48006)
Delete changelog files for 47987

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-05-30 23:08:13 +08:00
github-actions[bot] c90b1af1b3
Delete changelog files based on PR 47938 (#48004)
Delete changelog files for 47938

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-05-30 22:58:56 +08:00
Jorge A. Torres 9766816b80
Handle `screen-reader-text` on e-mails (#47738)
* Add changelog

* Remove 'screen-reader-text' elements from e-mails using XPath

* Undo screen-reader-text removal via XPath

* Add screen-reader-text CSS to e-mail styles

* Remove screen-reader-text from e-mail CSS template

* Introduce "must use" styles for e-mails

* Document filter
2024-05-30 14:16:00 +00:00
Patricia Hillebrandt 1d593e3d89
Update pnpm lock file with react 18 (#47993)
* Update the pnpm lock file

* add changelog
2024-05-30 13:24:39 +02:00
Damián Suárez ac6fe9f933
Product Block Editor: populate shipping class slug automatically (#47896)
* extend shipping_classses with '/suggest-slug' endpoint

* generate slug automatically

* changelog

* jsdoc

* polish setting and pulling the slug

* replace checkbox by button

* reword slug inout label with "Slug"

* add slug help

* use prefix input property

* isPrimary is deprecated. Use "variant" instead

* fixing typo. props to @mdperez86
2024-05-30 12:05:34 +01:00
louwie17 b0a1787304
Revert some changes around class loading (#47987)
* Revert some changes around class loading

* Add changelog
2024-05-30 07:22:59 -03:00
Sam Seay 5080008e1d
Update the lock file on trunk (#47990) 2024-05-30 09:46:59 +00:00
Albert Juhé Lluveras 712ffa3381
Add zoom and flex slider functionatility gallery images for variable products with missing Product Image (#47714)
* Add zoom functionatility to Single Product gallery images when main Product Image is missing

* Alternative approach

* Add changelog file

* Still add placeholder class for extra backwards compatibility

* Bump template version

* Remove unnecessary class name change

* Fix wrong type
2024-05-30 10:41:05 +02:00
Néstor Soriano c6424c09d1
Make the plugin autoinstall process more robust (#47798)
* Fix PluginInstaller::install_plugin_core so it works on Windows

* Wrap the autoinstall of the Legacy REST API plugin in try-catch block
and log any exception thrown

* Make sure that the wc_installing transient is deleted even if install fails
2024-05-30 09:01:47 +02:00
Ilyas Foo c9752f1eaf
Fix analytics chart previous year data when date range includes 29 Feb (#45874)
* Temp commit

* Clean up unused codes and streamline logic

* More cleanups and add comment

* Better naming and fix logic

* Rename and comment

* Changelog

* Changelog

* Lint

* Moved leap year utils to date package, added tests

* Moved functions to utils, add tests

* Add more test

* Fix changelog
2024-05-30 12:54:00 +08:00
Ilyas Foo 98b32b5ecc
Fix getPreviousDate default behaviour to compare previous year (#47951)
* Add default compare previous_year and add tests

* Changelogs
2024-05-30 11:31:10 +08:00
Paul Sealock a39ca21df5
[LYS] Add woocommerce_coming_soon_exclude hook (#47787) 2024-05-30 10:58:14 +12:00
Toby Herbert 0f21660277
Prevent the possibility of unpublished coupons from being available (#47739)
* Clean up the cache when a coupon is updated

When the coupon’s status transitions from publish to future, the ‘coupon_id_from_code’ cache entry needs to be deleted otherwise the coupon will remain available for use.

* Remove coupon cache entries when not published

* Add changefile(s) from automation for the following project(s): woocommerce

---------

Co-authored-by: Toby Herbert <tobyherbert@nialtoservices.co.uk>
Co-authored-by: github-actions <github-actions@github.com>
2024-05-29 17:31:02 -05:00
jonathansadowski f56d3e3ee0
Update PR template and auto change log with better no-entry support (#44023)
* Update PR template and auto change log

* Ignore .github md files in linting

* Rebuilt monorepo-utils to solve conflict

* Updated regex pattern to include uppercase X

* Move the changelog entry not required checkbox on top of the description.

* Return the comment even if shouldAutomateNoChangelog is false

* Updated tests

* Rebuilt monorepo-utils

---------

Co-authored-by: Adrian Moldovan <3854374+adimoldovan@users.noreply.github.com>
2024-05-29 17:06:59 -03:00
Jonathan Lane 2f4c9ecf57
Update pnpm lock file with react 18 (#47973)
* Update pnpm-lock file with new react

* Changelog

---------

Co-authored-by: Jon Lane <jon.lane@automattic.com>
2024-05-29 17:03:48 -03:00
Damián Suárez 6f8bce8bb0
Product Block Editor: load and create shipping classes optimistically (#47848)
* define ans use shippingClassRequestQuery

* do not invalidate getProductShippingClasses

* changelog
2024-05-29 19:59:24 +01:00
Moon 8cdd549038
Use LYS API endpoint for woocommerce_admin_launch_your_store_survey_completed option (#47915)
* Add status-completed endpoint

* Use new status-completed endpoint

* Add changefile(s) from automation for the following project(s): woocommerce

* Revert back unwanted changes

* Cache /wc-admin/launch-your-store/survey-completed call

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-29 11:14:20 -07:00
louwie17 494e65f77b
Fix tracking files being loaded on the front end (#47938)
* Only init WC Site Tracking if in admin or a rest request

* Add changelog

* Refactor tracks logic

* Create helper function store store api requests and make use of this

* Move conditionals back to woocommerce class

* Remove use of is_rest_api_request within is_store_api_request

* Fix lint errors

* Add check to see if WC_Tracks exist

* Also include tracking in CLI

* Make use of wc_admin_record_tracks_event instead of WC_Tracks directly
2024-05-29 14:06:42 -03:00
Jorge A. Torres e0455f86ed
Add `woocommerce_order_note_deleted` hook (redux) (#47916)
* Add `woocommerce_order_note_deleted` hook for a successful order note delete

* Update plugins/woocommerce/includes/wc-order-functions.php

Co-authored-by: Jorge A. Torres <jorge@0xbad.com>

* Include `order_id` in order note object

* Introduce `woocommerce_order_note_deleted` hook

* Appease linter

* Adjust unit test

* Add changelog

---------

Co-authored-by: EVOKE <evoke.lektrique@gmail.com>
2024-05-29 09:42:48 -07:00
Sam Seay 82f5b84a80
Remove isFeaturePlugin and flag code from FeatureGating class (#47866) 2024-05-30 02:50:09 +12:00
Fernando Marichal 88970a72a9
Fix product tracks when importing (#47857)
* Fix product tracks when importing

* Add changelog

* Fix lint

* Fix lint

* Fix source value
2024-05-29 10:54:07 -03:00
Manish Menaria bb3f38a3d8
Fix: Product Collection block does not display when editing template/post (#47871)
* Fix issue where Product Collection wasn't showing anything

- Moved queryId logic to a new `useQueryId` custom hook to encapsulate the logic.
- Simplified attribute setting in `useEffect` by using a default attributes value.
- Utilized `fastDeepEqual` to check for attribute equality

These changes fix the issue where the Product Collection block did not display properly in the template editor, ensuring consistent rendering of products.

* Add comment

* Add changefile(s) from automation for the following project(s): woocommerce-blocks

* Remove leftover comment

* Add e2e tests for Product Collection block visibility after refresh

Added end-to-end tests to verify the visibility of the Product Collection block after page refresh in both Product Archive and Post contexts.

- Added tests to ensure the Product Collection block remains visible after refreshing the template or post editor.
- Updated existing tests to use `BLOCK_LABELS` for better readability and maintainability.

* Improve E2E tests

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-29 16:35:36 +05:30
Jonathan Lane 938c7d97dc
Fix flaky core profiler e2e test (#47917)
Co-authored-by: Jon Lane <jon.lane@automattic.com>
2024-05-29 13:27:55 +03:00
Alba Rincón 02fdd916d3
[CYS] Patterns Migration: Performance - ensure the initial request to fetch patterns from the PTK is async (#47551)
* Add PatternsToolkit class to fetch patterns from PTK

* Pass the new PatternsToolkit class to the BlockPatterns constructor

* Extract the pattern registration code to the 'register_block_pattern' function

* Extract the file patterns registration to `register_block_patterns_from_files`

* Registers patterns from ptk

* Add ids of excluded patterns (because they have jetpack deps)

* Add PTK client tests

* Filter out patterns with post_type diff than "wp_block"

* Add missing excluded pattern

* Add error log and improve error messages from the PTK client

* Extract function to register patterns to PatternRegistry class

* Extract function to register patterns from PTK

* Rename PatternsToolkitClient to PTKClient

* Extract AI related code to the AIPatterns class

* Rename test to match class name

* Add missing package dep in BlockPatterns

* Cache and register PTK patterns

* Add feature flag

* Fix linting errors

* Add tests for the PatternRegistry

* Add tests for the PTKPatternsStore

* Add changefile(s) from automation for the following project(s): woocommerce

* Check pattern ID exists to filter

* Check title is set when registering the pattern

* Remove unnecessary code from test

* Add more patterns to the excluded list

* Add actions to reset the patterns transient on plugin deactivation and tracking option updates

* Schedule fetching pattern async when updating or activating the plugin and on allowing tracking

* Fetch patterns always async

* Add changefile(s) from automation for the following project(s): woocommerce

* Only schedule the fetch_patterns actions if it's not pending

* Add changefile(s) from automation for the following project(s): woocommerce

* Remove unnecessary import

* Fix tests

* Return empty array instead of error

* Fix imports and comments

* Remove unused function

* Fix lint errors

* Fix log

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-29 11:46:56 +02:00