Commit Graph

64922 Commits

Author SHA1 Message Date
Bart Kalisz d731edc868
Product Collection: Fix max price filter query value inclusion (#49917) 2024-07-29 11:51:26 +02:00
Alba Rincón df4bd38297
CYS - Run appropriate tests depending on the WordPress version (#50016)
* WIP

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

* Add missing code in before all

* Fix lint

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-07-29 10:32:29 +02:00
Ilyas Foo 11c8567c4c
Hide main payment settings save changes button (#50064)
* Hide save changes button for main payment settings screen

* Changelog

* Moved logic
2024-07-29 05:30:01 +00:00
Gabriel Manussakis 928271b427
[Accessibility ]Fix typos in experimental select control test (#48643)
* Fix "begining" and "fullfiled" typos

* Add changelog file
2024-07-29 03:16:01 +00:00
Gabriel Manussakis b2a822d44d
[Accessibility] Fix typo in Find Country Option test (#48648)
* Fix "comparsion" typo

* Add changelog file
2024-07-29 11:06:24 +08:00
Gabriel Manussakis c7003646ce
[Accessibility] Fix typos in packages/js/ resolvers error messages (#48646)
* Fix "retriving" typo

* Add changelog file
2024-07-29 11:05:55 +08:00
Veljko V. 0ccf3c013d
Remove unnecessary pause in e2e test (#50043) 2024-07-26 21:34:17 +02:00
rodelgc 8be71d467d
Whitelist a line in WC Beta Tester from QIT security tests (#49965)
* Whitelist succeeding line from QIT's security scanner

* Add changelog
2024-07-26 12:31:51 -07:00
nigeljamesstevenson 236cd442d6
Update stable tag to 9.1.4 (#50037)
woorelease: Update stable tag to 9.1.4
2024-07-26 19:15:52 +01:00
Seghir Nadir 0dcd359b25
Add validation to select fields and add placeholder option to additional fields API (#49929)
* Add validation and empty value to select components

* address feedback

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

* remove console log

* Update plugins/woocommerce-blocks/docs/third-party-developers/extensibility/checkout-block/additional-checkout-fields.md

Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>

* Update plugins/woocommerce-blocks/docs/third-party-developers/extensibility/checkout-block/additional-checkout-fields.md

Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>

* remove test

* Fix tests

* also move select to parent

* fix tests

* add empty enum to schema

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
2024-07-26 16:38:44 +00:00
Marco Almeida 9fefa6a54d
Fix #49982 - "Creation of dynamic property WC_Beta_Tester::$wporg_data is deprecated" on PHP 8.2 (#49983)
* Fix #49982

Fixes #49982

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

---------

Co-authored-by: Vladimir Reznichenko <kalessil@gmail.com>
Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Adrian Moldovan <3854374+adimoldovan@users.noreply.github.com>
2024-07-26 09:31:44 -07:00
Mike Jolley 0b13563a2f
[WIP] Fix logout endpoint handling (#49605)
* `wc_get_account_endpoint_url` should handle nonces for logout endpoint

* Handle logout without redirect, unless a nonce is missing.

* `wc_logout_url` should not use the account page endpoint because that does not support custom redirects

* Handle navigation nonces

* changelog

* Bump versions

---------

Co-authored-by: Seghir Nadir <nadir.seghir@gmail.com>
2024-07-26 15:26:35 +01:00
RJ 68cdc2941c
add: render react placeholders for offline and woocommerce_payments settings sections (#50008)
* Added a whitelist of sections to render an alternative output in the WC_Settings_Payment_Gateways_React class.

* Renamed constant and updated its contents to only include 'offline'

* Added a branch in the `output()` method to output an appropriate div with an id if the current section is in the whitelist.

* Added "experimental" prefix to payment settings div ID.

* Replicated the render for the offline section similar to the main payments settings.

* Added a new settings-payments-offline screen to the WooCommerce admin plugin.

* Implemented new offline settings page component.

* Removed the ErrorBoundary components from the SettingsPaymentsMainWrapper and SettingsPaymentsOfflineWrapper.

* Added a new SettingsPaymentsOfflineWrapper component and its corresponding SCSS styles.

* Implemented the WooCommerce Payments section in the settings page.

* Removed WooCommerce Payments settings logic and replaced with a placeholder.

* Added a placeholder for the offline payments screen.

* Added 'main' to the REACTIFY_RENDER_SECTIONS array and refactored the output method to improve readability and maintainability.

* Renamed `render_gateway_section` method to `render_classic_gateway_settings_page` in the `class-wc-settings-payment-gateways-react.php` file.

* Added a filter for the REACTIFY_RENDER_SECTIONS so that plugins can modify this list.

* Added inline documentation for the filter in the `get_reactify_render_sections` method.

* changelog

* Matched the CSS styles for the WooCommerce Payments section to the offline section.

* Removed unnecessary Card component and placeholder text from WooCommerce Payments settings.

* Linted the `class-wc-settings-payment-gateways-react.php` file, addressing the reported linting issues.

* Refactored the payment settings UI to use React components and lazy loading.

* lint

* Nit: Removed unnecessary comment and moved a small code

* Update name to experimental

* Fix save button missing from section pages

* Fix saving sections

---------

Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>
2024-07-26 20:55:19 +08:00
Mike Jolley 7195ec2e32
Fix shortcode cart shipping calculator placeholder (#49684)
* Reset default placeholder in country select JS

* Handle shipping calculator in address-i18n

* changelog
2024-07-26 12:53:37 +01:00
nigeljamesstevenson cdf89ee951
Update my-account-orders Perf Test to ensure the variable boundary operates with new codebase (#48937)
* Update my-account-orders.js

* 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>
Co-authored-by: Tam Mullen <tam.mullen@automattic.com>
2024-07-26 12:46:13 +01:00
Adrian Moldovan f06302bbb5
[testing workflows] Harden the run condition for reporting jobs to only run in the monorepo (#50017) 2024-07-26 12:40:14 +01:00
Brian Taylor 406cc67c47
Update link to caching documentation in store launch message (#49961) 2024-07-26 09:46:43 +00:00
Vladimir Reznichenko 5a37ae4333
CI: tweaks around 'Build Live Branch' job start conditions. (#50005)
The PR scope was reduced to filtering out the `.github` folder from target changes, except the workflow itself. It should reduce the amount of the job runs when we are working with GitHub actions related files.
2024-07-26 11:41:10 +02:00
Vladimir Reznichenko 2d6811e689
CI: speedup 'Check Asset Sizes' job (take 2) (#49992) 2024-07-26 11:21:58 +02:00
Alba Rincón 85c6c0944c
CYS - Full composability tests (#49748)
* WIP

* Add e2e tests for the full composability

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

* Fix lint errors

* Enable the full composability flag for want more patterns banner

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-07-26 11:12:35 +02:00
Adrian Moldovan 142f7e5865
[e2e tests] Cleanup: remove console logging of environment data (#49997)
* Removed console logging or environmentData

* Add changelog
2024-07-26 11:21:49 +03:00
Chi-Hsuan Huang b2f4828c16
Use MC Stats for PHP fatal error counting (#49658)
* Add automattic/jetpack-a8c-mc-stats

* Count fatal errors

* Add tests

* Output as img tag

* Add changelog

* Fix lint

* Fix lint

* Move McStats to ./src/Internal

* Check user's consent before sending stats

* Remove test

* Send stats from server side

* Update plugins/woocommerce/src/Internal/McStats.php

Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>

* Add unit tests

---------

Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>
2024-07-26 08:00:53 +00:00
Niels Lange 752273e6ce
[React 18] Use `createRoot().render()` instead of `render()` (#48843)
* Use createRoot().render() instead of render()

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

* Replace `unmountComponentAtNode()` with `createRoot().unmount()`

* Adjust JS unit tests

* Remove obsolete import

* Remove “ReactDOM.render is no longer supported” check

* Update pnpm-lock.yaml

* Migrate JS unit test to React 18

* Revert "Update pnpm-lock.yaml"

This reverts commit 18bfc967aa.

* Migrate JS unit test to React 18

* Migrate JS unit test to React 18

* Minor refactor

* Unskip previously skipped tests

* Fix JS unit test error related to root.unmount()

* Remove obsolete dependency

* Fix failing blocks e2e test

* Fix failing core e2e tests

* Optimise memoisation to prevent “Maximum update depth exceeded” error.

* Fix Filters JS tests in #48796 (#49973)

* Run cleanup in Rating Filter JS tests

* Run cleanup and wait user interactions in Stock Status Filter JS tests

* Rename constant

* Simplify conditional statement

* Introduce TS type

* Address lint error

* Rename TS type

* Optimise multiple TS types

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Sam Seay <samueljseay@gmail.com>
Co-authored-by: Karol Manijak <20098064+kmanijak@users.noreply.github.com>
2024-07-26 09:18:48 +02:00
Ilyas Foo 33222c20e2
Add reactified main payments screen (#49972)
* Add new payments settings class, add new settings-payments module and a demo main component

* Minor edits

* Changelog

* Lint

* Lint php

* Use createRoot

* Hide payment recommendations when feature flag is enabled

* Moved logic
2024-07-26 12:40:18 +08:00
github-actions[bot] fe85d2b1ab
Prepare Packages for Release (#50000)
Automated change: Prep @woocommerce/experimental for release.

Co-authored-by: lanej0 <lanej0@users.noreply.github.com>
2024-07-25 14:54:32 -07:00
Jonathan Lane d6fad9f6d5
Add changelogs to trigger version bumps in packages (#48645)
* Add changelogs to trigger version bumps in packages

* Don’t update already updated packages

* Don’t update other packages

* extend-cart-checkout-block has been released

---------

Co-authored-by: Jon Lane <jon.lane@automattic.com>
2024-07-25 13:57:30 -07:00
79mplus Admin a39d926457
fixed warning: Undefined array key "class" (#48079)
* fixed warning: undefined index class

* Update plugins/woocommerce/includes/admin/class-wc-admin-profile.php

Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>

* add changlog

* Tweak changelog.

---------

Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>
Co-authored-by: Naman Malhotra <naman03malhotra@gmail.com>
2024-07-25 12:56:07 -07:00
github-actions[bot] 0f26b50972
Prep trunk for 9.3 cycle (#49962)
* Prep trunk for 9.3 cycle with version bump to 9.3.0-dev

* Add comment explaining why no changelog is needed.

---------

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>
2024-07-25 18:16:31 +00:00
Adrian Moldovan 1b2e06a6f6
[e2e tests] Add environment info rest route and environment reporter (#49988) 2024-07-25 11:07:25 -07:00
github-actions[bot] e74464fa17
Release: Remove 9.2 change files (#49963)
Delete changelog files from 9.2 release

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>
2024-07-25 08:57:20 -07:00
Ames Plant 9b521edda4
[Accessibility] Fix/43628 view button orders page (#49424)
* Add an aria-label to the View order buttons

* Add changelog

* Add translator comment

* Bump template version number

* Fix space / tab formating issue

* Update plugins/woocommerce/changelog/fix-43628-view-button-orders-page

Co-authored-by: Mike Jolley <mike.jolley@me.com>

* Fix translation

* Fix linting errors in orders.php

---------

Co-authored-by: amesplant <95257231+amesplant-dmv@users.noreply.github.com>
Co-authored-by: Mike Jolley <mike.jolley@me.com>
2024-07-25 15:07:01 +01:00
Mike Jolley 95ba494d03
Only filter page title on order confirmation page when using an FSE theme (#49986)
* Only filter page title on order confirmation page

* changelog
2024-07-25 15:06:44 +01:00
Gabriel Manussakis 2840c2f3d3
[Accessibility] Inform screen reader users when mini cart updates (#48295)
* Create add_to_cart_success_message method in WC_Product_Simple class

* Add data-success_message attribute to remove item button in cart

* Add data-success_message to Add to cart button

* Make screen readers announce mini cart updates

* Add changelog file related to #37597 #37598

* Add translator comment to remove button data-success_message attribute

* Add docblock to woocommerce_product_add_to_cart_success_message filter

* Bump mini-cart template version

* Refresh mini cart live region by removing it from the DOM

* Add mini cart live region to DOM beforehand

* Remove aria-relevant attribute before adding new content to live region

* Add a delay before updating live region

* Bump mini-cart template version from 9.1.0 to 9.2.0

Co-authored-by: Paulo Arromba <17236129+wavvves@users.noreply.github.com>

* Bump version of woocommerce_product_add_to_cart_success_message filter

Co-authored-by: Paulo Arromba <17236129+wavvves@users.noreply.github.com>

* Add description to the $text param on woocommerce_product_add_to_cart_success_message filter

* Refactor logic in the add_to_cart_success_message function

---------

Co-authored-by: Paulo Arromba <17236129+wavvves@users.noreply.github.com>
2024-07-25 14:22:40 +01:00
Herman c2fc236341
Ensure wccomHelper data is only added on In-App Marketplace pages (#49758)
* Ensure wccomHelper data is only added on In-App Marketplace pages

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

* Fix linting

- Looking for GET requests for admin users, so no nonce available to check

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-07-25 12:49:35 +02:00
Luigi Teschio 9d63830063
CYS: Skip PTK is down test on WordPress 6.5 (#49970)
* CYS: Skip PTK is down test on WordPress 6.5

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-07-25 08:59:59 +00:00
Sam Seay 0a47061ace
Don't render aria described by if the arg is not passed in add-to-cart.php (#48969) 2024-07-25 20:16:16 +12:00
louwie17 4ac3ce099c
Add track unit tests for `wcadmin_product_add_publish` track (#49916)
* Add helper function to clear track events

* Add additional test cases for product_add_publish track event

* Add changelog

* Add empty save use case

* Address lint issues
2024-07-25 04:38:21 -03:00
RJ 0a48da3135
add: reactify payments settings feature flag (#49966) 2024-07-25 12:48:34 +08:00
Tung Du 234f5d7e49
[Experimental] Attribute Filter: Update Inspector Control Settings (#49751)
* add: new inspector controls

* update: cleanup the edit component

* chore: remove unused old inspector component

* tweak: add formatting to help text

as Jarek said:

> Here’s the copy. Please mind the formatting.

* add: default attribute id that closest to 30

* update: pass the whole attribute object

* update: use default attribute term in Product Filters template

* add: style settings

* add: sorting and show empty behavior in the editor preview

* tweak: use hideEmpty to align with existing settings

* chore: changelog

* test: add basic e2e tests

* chore: restore previous default value

* add: attribute help text and border support

* chore: lint

* fix: add missing context
2024-07-25 09:13:56 +07:00
Alexandre Lara 6000a1e83c
[Experimental] Product Filters Redesign: Create the template part (#49692)
* Add Product Filters template part

* Improve Product Filters template part description

* Hide Product Filters block from the inserter

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

* Add E2E tests

* Fix lint error

* Fix lint error

* add: register variation for unmodified template part

We should move this to abstract class later.

* Fix lint error

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Tung Du <dinhtungdu@gmail.com>
2024-07-24 17:36:18 -03:00
Alba Rincón 3fab8e7519
CYS - Update the intro pages for different type of themes (#49910)
* CYS - Revert the button copy customize the TT4 theme

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

* CYS - Add banner for block themes

* Add banner for block themes

* Fix tests

* Fix tests

* Fix intro banners

* Add modal to the use store designer

* Fix tests

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

* Fix lint errors

* use sendEvent instead of redirect

* fix lint error

* fix logic on ai flow

* fix build

* improve check

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Luigi Teschio <gigitux@gmail.com>
2024-07-24 18:09:12 +02:00
Thomas Roberts df8d5b751e
Revert "[Enhancement]: Add option to show price on the place order button" (#49899)
* Revert "[Enhancement]: Add option to show price on the place order button (#4…"

This reverts commit a71fb4d7a6.

* Add changelog
2024-07-24 18:08:05 +02:00
Fernando Marichal 4e368a1b67
Add readme for validations (#49723)
* Add readme for validators

* Add changelog

* Add docs manifest

* Fix product-editor.md

* Fix readme
2024-07-24 13:02:02 -03:00
Sam Seay 137a2e8aa6
Checkout: Add placeholder option to country and state select, add error validation (#49616)
* WIP

* Add empty option for state as well

* Add client-side validation to country select inputs

* Add validation messages for state.

* Clean up redundant destructuring.

* Fix up the validation logic, fix bug where empty select was shown in some cases.

* Remove unused import

* Use import aliases instead of large relative paths

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

* Fix a typo

Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>

* use SelectOption type

* Also handle when address changes, because we shouldnt validate state when there is an address change

* adjust validation to handle any address change, not just country. translate field validations and use lowercase

* add a lowercase label for the country select as well

* Fix an issue where scroll to would not scroll to invalid select

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
2024-07-24 17:59:15 +02:00
Vladimir Reznichenko 474b7624d0
Monorepo: rework deps patching in favour of built-in pnpm functionality (#49892)
* Monorepo: added pach.

* Monorepo: added patch.

* Monorepo: added patch.

* Monorepo: added patch.

* Monorepo: added patch.

* Monorepo: cleanup.

* Monorepo: cleanup.

* Monorepo: changelog entry.
2024-07-24 08:38:32 -07:00
Gabriel Manussakis b796b90d68
[Accessibility] Add address title to edit/add buttons on My Account page (#49171)
* Add address title to edit/add buttons on my account

* Add chengelog file

* Bump my-address template version

* Use placeholder in the edit/add address translation

* Replace sprintf with printf
2024-07-24 16:15:08 +01:00
Maikel Perez 4689a09ec3
Create combobox-control (#49691)
* Create combobox-control

* Exporting the combobox control

* Integrate the combobox control into the custom field names component

* Remove some non needed styles

* Add changelog file

* Fix comment text typo

Co-authored-by: louwie17 <lourensschep@gmail.com>

* Fix linter errors

---------

Co-authored-by: louwie17 <lourensschep@gmail.com>
2024-07-24 11:13:24 -04:00
Tung Du ac5b051fc2
Fix: Make woocommerce/product-price available in the Single Product template (#49906)
* fix: register woocommerce/product-price using registerBlockSingleProductTemplate

* fix: remove unnecessary blockMetadata

* chore: changelog

* Enable Product Price in post editor

---------

Co-authored-by: Karol Manijak <20098064+kmanijak@users.noreply.github.com>
2024-07-24 15:58:20 +02:00
Mino e39da623cf
enhancement: making tooltips message be selected based on order status slug. changes to get_order_status_label filter (#49812)
* enhancement: making tooltips message be selected based on order status. passes order object in woocommerce_get_order_status_labels filter for more personalized tooltips.

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

* fix: change incorrect keys of order status in order_status array

* remove duplicate changelog file

* fix: linting issues

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Adrian Duffell <9312929+adrianduffell@users.noreply.github.com>
2024-07-24 13:04:59 +00:00
Tom Cafferkey 193f4e47bd
CYS: Remove strong tags from patterns (#49901)
* Remove strong tags from patterns

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

* remove bold header

---------

Co-authored-by: Luigi Teschio <gigitux@gmail.com>
Co-authored-by: github-actions <github-actions@github.com>
2024-07-24 13:57:42 +01:00