Commit Graph

64445 Commits

Author SHA1 Message Date
Barry Hughes bb9b332ae2
Add best practices advice to the API generation screen (#48483)
* Add "best practice" advice to the API key generation screen.
2024-06-17 15:13:37 +01:00
Vishnu Gopal 28b4d228c9
Prefer update URLs over PluginURI in My Subscriptions (#47950)
* Prefer update URLs over PluginURI in My Subscriptions

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

* Add comments to clarify how the function works

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-17 20:51:14 +07:00
Karol Manijak 65423a4d15
Add `queryId` to the Product Collection in blockified templates (#48530)
* Add hardcoded queryId to the blockified templates

* Add additional check in PC block to verify the content is being rendered

* Add changelog

* Lint fix
2024-06-17 15:39:30 +02:00
Daniel W. Robert a203823d62
Add CYS Fiverr Logo Maker CTA (#48486)
* Add markup for Fiverr logo maker.

Add text CTA with link to WooCommerce landing page for Fiverr logo
maker in sidebar navigation on the logo view.

* Adjust styles for Fiverr logo maker CTA.

* Update string output to use interpolateComponents

The text in this addition is mixed with string and markup.

This segmentation can lead to translation issues because
different languages have different syntactic structures.

Here, we utilize interpolateComponents to remedy these potential issues.

See
https://github.com/woocommerce/woocommerce/pull/48486#discussion_r1639637477
for context.

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

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

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-17 09:12:56 -04:00
Fernando Marichal 0652c2eb4f
Set stock quantity value as 0 by default (#48448)
* Set value to stock quantity

* Add changelog

* Undo set_stock_quantity

* Fix orders.test.js lint

* Fix product-list-test lint
2024-06-17 08:41:24 -03:00
github-actions[bot] efb7f6adda
Prepare Packages for Release (#48499)
* Automated change: Prep @woocommerce/extend-cart-checkout-block for release.

* Re-add removed items from changelog with updated prefixes

---------

Co-authored-by: opr <opr@users.noreply.github.com>
Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
2024-06-17 10:51:29 +01:00
Luigi Teschio 317fcaedc8
CYS: fix logic to disable mover buttons (#48502)
* CYS: fix logic to disable mover buttons

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-17 08:56:45 +00:00
Chi-Hsuan Huang 4162a6ef89
Wrap activity panels in error boundary (#48415)
* Fix review error type

* Add changelog

* Rename global error-boundary class to avoid conflict

* Rename global error-boundary class to avoid conflict

* Wrap panels in error boundary

* Remove console

* Reformat

* Fix test

* Fix test

* Add changelog
2024-06-17 13:05:11 +08:00
Néstor Soriano 1e92b0efaf
Optimize the regeneration of the product attributes lookup table (#47700)
Fixes  #46699 

* Add the ProductAttributesLookup\CLIRunner class

* Fix the restoring of the lookup table usage option

* Fix the restoring of the lookup table usage option

* Improve the progress bar of the regeneration command

* Add changelog file

* Fix existing unit tests

* Add linter exception for TODO comment

* Fix example in CLI runner

* Optimize data insertion/update in the product attributes lookup table

The optimized method uses direct database access to the database tables
required to gather all the required data (posts, terms, teaxonomies)
instead of the standard WordPress and WooCommerce functions.
This is done only if:

1. The curent data store for products is the posts table, AND
2. The woocommerce_attribute_lookup_optimized_updates option is 'yes'

Otherwise, the old existing code is used as a fallback instead.

* Adjust the product attributes lookup table CLI tools.

The "regenerate" and "regenerate_for_product" commands will now
use the optimized update method by default if the data store
for products is the posts table (irrespective of the value of the
woocommerce_attribute_lookup_optimized_updates option).
The --disable-db-optimization argument can be appended to
use the old method instead.

* Adjust unit tests for the product attributes lookup table data store.

Now both the optimized data insert/update method and the old
standard functions based method are tested.

* Change the default step size for product attributes lookup table regeneration

The previous value of 10 was too conservative and slowed down the
regeneration unnecessarily (each step involves a call to
wc_get_products, which is quite slow). The new value of 100 is not
too high as to produce bottlenecks, but provides a significant
performance gain.

* Add a missing exception variable

* Add changelog file

* Replace sneaky spaces with tabs

* Make the linter happy

* Add extra code comment for clarity

* Display error messages after CLI commands if table updates fail.

* Use lookup table name variable in SQL query

Co-authored-by: Corey McKrill <916023+coreymckrill@users.noreply.github.com>

* Better description for the newly introduced setting

Co-authored-by: Corey McKrill <916023+coreymckrill@users.noreply.github.com>

* Fix typo in method name and change |= operator to ||

* Fix linting issue and variable initialization

---------

Co-authored-by: Corey McKrill <916023+coreymckrill@users.noreply.github.com>
2024-06-14 13:42:58 -07:00
Brezo Cordero 49c76bd080
Remove edit_comments_screen_text on gettext filter for performance (#48485)
* Remove filter edit_comments_screen_text on gettext for performance

The filter is removed to improve performance and avoid unnecessary calls. Acceptable tradeoff: When editing a product review in the Admin, the screen title changes from "Edit Review" to "Edit Comment".

* Add changelog
2024-06-14 12:01:49 -07:00
Francesco bd9b2ee4b8
fix: label improvement on my order pages (#48374)
* fix: label improvement on my order pages

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

* Update plugins/woocommerce/changelog/48374-fix-label-improvement-on-my-orders

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

* Update plugins/woocommerce/changelog/48374-fix-label-improvement-on-my-orders

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

* version bump

* Update plugins/woocommerce/changelog/48374-fix-label-improvement-on-my-orders

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

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

* linting

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-14 22:38:10 +04:00
Jorge A. Torres 24391fba0f
Do not attempt to re-save hooks after delivery when not already persisted (#48480)
* Do not re-save hooks not in the DB after delivery

* Add changelog

* Do not try to deliver (async) webhooks that have been deleted
2024-06-14 11:12:04 -07:00
Matt Sherman a5893ac066
Product Editor: Respect system setting for maximum upload file size for Images and Downloads (#48399)
* Move productBlockEditorSettings type to global.d.ts

* Set maxUploadFileSize to system settings

* Changelog

* Add maxUploadFileSize to test

* Set maxUploadFileSize for downloads

* Set maxUploadFileSize for variation image quick action

* Remove unused EditDownloadsModal props

* Fix typo in EditDownloadsModal prop

* Remove unused EditDownloadsModalProps prop

* Remove unused function

* Show specific error message when upload of download file fails

* Show error notice when upload fails for variation image quick action

* Set maxUploadFileSize for download files menu item

* Close downloads menu on error

* Fix up types to avoid duplicate definitions

* Show specific link error
2024-06-14 13:36:31 -04:00
Alexandre Lara cac7e0dfe9
[Experimental] Product Filters Redesign > Parent block: Enable block customizations (#47594)
* Enable block customizations

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

* Enable background and color customization

* Add E2E tests

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-14 13:56:31 -03:00
Veljko V 5dc87bed92
Fix flaky e2e test customize store logo picker (#48503)
* Fix flaky logo picker e2e test

* Add changelog
2024-06-14 19:48:29 +03:00
Adrian Moldovan 90398903ab
Fix core api tests results path and artifacts naming pattern (#48490)
* Fix api tests results path

* Add changelog

* Run Core API tests - HPOS disabled on pull_request

* Update the artifacts name pattern to avoid conflicts

* Revert pull_request trigger
2024-06-14 09:03:43 -07:00
Thomas Roberts 5c70064a85
Update `@woocommerce/extend-cart-checkout-block` package to add Additional Checkout Fields examples (#48280) 2024-06-14 16:01:13 +01:00
Thomas Roberts 214d6341a0
Prevent checkout step divider overflowing causing horizontal scroll on mobile (#48464) 2024-06-14 14:20:03 +01:00
Luigi Teschio a105e2d50e
CYS: set new default patterns (#48467)
* CYS: set new default patterns

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-14 12:51:18 +00:00
Veljko V 83ff0ecb12
Fix flaky color palette picker e2e test (#48496)
* Fix flaky test by repositioning save button

* Add changelog
2024-06-14 14:30:42 +03:00
Luigi Teschio dada673fac
CYS: fix tooltip position (#48495)
* CYS: fix tooltip position

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

* trigger CI

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-14 10:43:07 +00:00
Alba Rincón c18dbb1ce4
[CYS] Show tooltips in delete and shuffle buttons (#48465)
* Show tooltips in delete and shuffle buttons

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-14 10:21:44 +02:00
Ilyas Foo 641370aa4e
Fix LYS private link query parameter when permalink is plain (#48425)
* Properly build URL query parameters

* Changelog
2024-06-14 09:23:32 +08:00
Veljko V a7fc9afa8e
Improve cart util and update relevant e2e tests (#48475)
* Improve cart util and update relevant tests

* Add changelog

* Remove focused test
2024-06-13 12:47:45 -07:00
Lucas 29ee0ab6cf
E2E Tweaks - Stricter selector and smart wait (#48471)
* Strict selector

* Wait for element

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

* Linter

* Tweak

* Use a different selector

* Tweak selector

* Wait for Delete Users to be visible

* Trigger CI

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-13 12:07:00 -07:00
Veljko V 2165bfd29f
Fix flaky merchant customer-list e2e test (#48463)
* Fix flaky merchant customer-list test

[48462]

* Add changelog
2024-06-13 11:53:15 -07:00
Maikel Perez caa7c8707b
Enable pricing inline actions in the variations table (#48164)
* Create VariationPricingForm component

* Add validations to the VariationPricingForm component

* Add changelog file
2024-06-13 14:41:15 -04:00
Fernando Marichal c696b1b5d9
Do not dismiss the error snackbar automatically (#48192)
* Modify Publish button error snackbar

* Modify Preview snackbar and error handling

* Modify Save draft snackbar error handling

* Modify publish button menu error handling

* Modify change product type error handling

* Fix getProductErrorMessageAndProps return types

* Remove getProductErrorMessage

* Rename get-product-error-message file

* Fix tests

* Add changelog

* Fix e2e test

* Add WC changelog

* Improve getProductErrorMessageAndProps

* Fix Variable product

* Remove productType from error object

* Remove productType from errorHandler

* Remove postType from block

* Remove visibleTab
2024-06-13 13:56:26 -03:00
github-actions[bot] 68b9d0830c
Delete changelog files based on PR 48432 (#48478)
Delete changelog files for 48432

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-06-13 18:28:06 +02:00
Maikel Perez 68107ba8a3
Enable manage stock inline actions in the variations table (#48239)
* Create VariationStockStatusForm component

* Integrate VariationStockStatusForm within the VariationsTableRow component

* Add woocommerce_manage_stock option to the default_option_permissions list in the Options rest controller

* Enable track inventory when woocommerce_manage_stock is set to yes

* Add stock_status radio component to the VariationStockStatusForm component

* Fix VariationStockStatusForm padding

* Fix control spacing

* Add stock_quantity to the VariationStockStatusForm component

* Add changelog files

* Fix linter errors

* Fix invalid sortable state in the variations table
2024-06-13 12:08:52 -04:00
Fernando Marichal 9f00f051a5
Re-enable variable product E2E test (#48294)
* Re-enable variable product E2E test

* Add changelog

* Fix timeout
2024-06-13 12:48:10 -03:00
github-actions[bot] e22bddc5a4
Delete changelog files based on PR 48423 (#48474)
Delete changelog files for 48423

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-06-13 17:35:34 +02:00
Luigi Teschio 7f1616242c
Fix CYS crash when loads in WordPress Playground (#48129)
* Fix CYS crash when loads in WordPress Plaground

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-13 13:38:27 +00:00
Luigi Teschio 924fc1687b
CYS: avoid flickering image loading screen (#48460)
* CYS: avoid flickering image loading screen

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-13 13:29:55 +00:00
netzkollektiv c76438906b
clarify the `name` property needs to match between JS and PHP (#48219)
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: github-actions <github-actions@github.com>
2024-06-13 05:57:36 -07:00
Damián Suárez 6328ffdfb2
Product Form Template: populate the template selector control with the PFTs (#48327)
* switch setting templates order

* pull product_form from the entity store

* fix typo

* set post excerpt with template description

* update the description for the Simple template

* rename type for product form post

* introduce isProductFormTemplateEnabled() helper

* render the PFTs into the templates selector

* changelog

* tscripting

* remopve dropdown

* re-write changelog files

* change and rename isProductFormTemplateSystemEnabled

* remove unused component

* try change the template version name
2024-06-13 13:55:07 +01:00
Alba Rincón 7352c7270a
[CYS - Full Composability]: Fix active/inactive patterns for each assembler section (#48458)
* Add inert to header and footer on the homepage

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

* Refactor to pass query as a param to the hook

* Add an observer to enable/disable patterns depending on the assembler section

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

* Rename observer

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-13 14:42:54 +02:00
Corey McKrill 403ff183e0
REST API: Check if stock should be adjusted when updating order line items (#47784)
* Check for stock adjustment during REST order update request

* Add changelog file
2024-06-13 12:58:24 +01:00
Mike Jolley 9cd84a44cb
Fix `WC_Settings_API` textarea validation method (#48432)
* Remove custom `wp_kses` rules in favour of default `wp_kses_post` function

Custom sanitization/validation is no longer needed—we can just inherit wp_kses_post like other field types.

wp_kses was originally implemented for a ShareThis integration a5aa58b135 but this is no longer present in WooCommerce.

iFrame usage is not encouraged in these settings fields so with this change they will be filtered out. Developers who would like to allow iFrames can add a custom `sanitize_callback` function when registering settings fields.

* Apply kses on gateway description unless extended by a plugin

* Code standards + esc in touched abstract payment gateway class

* Changelog

* Use esc_url for icon URL

* Add missing hook docs in payment method class

* Add since documentation

* Skip description if empty

* Run KSES early so we know if the description has content.
2024-06-13 10:16:03 +01:00
Luigi Teschio e044ea9120
CYS: apply white color to the heading elements in the core/cover block (#48447)
* CYS: apply color to the heading elements in the core/cover block

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

* fix color

* add E2E test

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-13 08:48:06 +00:00
Karol Manijak 1f4a86c7f1
Hide Product Summary (Product Elements) from Single Product block (#48253)
* Hide Product Summary (Product Elements) from Single Product block

* Add changelog

* Update comment
2024-06-13 09:58:06 +02:00
Karol Manijak d49db0486e
Update Compatibility Layer docs (#48456)
* Update compatibility layer docs to mention Product Collection

* Add changelog

* Update plugins/woocommerce-blocks/docs/internal-developers/blockified-templates/compatibility-layer.md

Improve my English

Co-authored-by: Albert Juhé Lluveras <contact@albertjuhe.com>

---------

Co-authored-by: Albert Juhé Lluveras <contact@albertjuhe.com>
2024-06-13 09:57:51 +02:00
Alba Rincón 1f9b130357
[CYS - Full Composability]: When the user is in the "Design your homepage" menu, hovering over the header or footer will should not make them highlighted (#48358)
* Add inert to header and footer on the homepage

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

* Refactor to pass query as a param to the hook

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-13 09:37:34 +02:00
Chi-Hsuan Huang 54321a5a60
Add generic error boundary component (#48363)
* Fix storybook

* Add experimental error boundary component

* Add error boundary component

* Fix empty content button

* Add changelog

* Fix storybook

* Reset state after actioned

* Fix story

* Address feedback
2024-06-13 05:05:28 +00:00
Chi-Hsuan Huang 4112c97d13
Handle core profiler get countries error (#48317)
* Handle core profiler get countries error

* Update style

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

* Update button and code style

* Address feedback

* Fix lint

* Record skip step track and rename event

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-13 12:42:30 +08:00
Chi-Hsuan Huang ab1789afd2
Remove onboarding welcome modals (#48346) 2024-06-13 10:39:21 +08:00
Niels Lange 6a0a9be504
Revert #47083 (#48423)
* Revert #47083

* Revert e2e test
2024-06-13 00:23:23 +02:00
Adrian Moldovan 1f534d0280
[e2e tests] Update the report configuration for core e2e tests and add a new workflow call for report publishing (#48424)
* Add a call to a new report workflow in woocommerce-test-reports repo

* Test change to trigger tests

* Update report title

* Test change to trigger tests

* Check REPORT_TITLE

* Add quotes on all arguments

* Update reporting configuration to all core e2e jobs

* Add changelog

* Use GITHUB_HEAD_REF for pull_request

* Set REPORT_TITLE for workflow dispatch

* Updated trigger from daily-e2e to daily-checks
2024-06-12 13:38:37 -07:00
Veljko V 08e44d0c4c
Fix flaky e2e test and update login util (#48446) 2024-06-12 13:35:36 -07:00
Matt Sherman 8a69728312
Product Editor: Show error notice when error occurs uploading an image via drop on Images (#48396)
* Export MediaUploaderErrorCallback

* Show notice when error uploading image

* Changelog

* Changelog

* Wrap error message in __ for translation

* Fix sprintf/__ usage to avoid lint errors
2024-06-12 15:50:48 -04:00