Commit Graph

20815 Commits

Author SHA1 Message Date
Karol Manijak 96d951930c
Sync package.json and pnpm-lock.yaml (#47575)
* Add changes added automatically by install/postinstall

* Add changelog
2024-05-17 15:44:58 +02:00
Thilina Pituwala 52fef2c0c5
Remove old in-app marketplace pages and redirect to new in-app section (#47276)
* Remove the view file rendering old market-place page.

* Remove the function for rendering old market-place pages and introduce redirects to new in-app market-place.

* Remove unused code related to legacy market-place.

* Add exit after redirect.

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

* Redirect to search result page when a search term exists.

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-17 20:19:11 +07:00
Dan Q edc22bca24
Add "Shared with you" badge to Extensions > My Subscriptions list as applicable (#46229)
* Add 'shared with you' badge

* Improve spacing where multiple badges span multiple lines

* Decrease font size of badges per new designs

* Include 'Manage on Woo.com' only for non-shared subscriptions

* Made TypeScript happier

* Add 'shared with you' badge

* Improve spacing where multiple badges span multiple lines

* Decrease font size of badges per new designs

* Include 'Manage on Woo.com' only for non-shared subscriptions

* Made TypeScript happier

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

* Addressing linter errors.

* Allow unusually-long email addresses of sharers to wrap

* Switch wordWrap for overflowWrap

Modern browesers interpret the former as an alias of the latter, including allowing the use of 'anywhere'. But the current version of https://www.npmjs.com/package/csstype only recognises 'anywhere' as valid for overflowWrap. Switching it prevents compilation errors, still exhibits the correct behavior.

* Prettier linting

* Update plugins/woocommerce/changelog/46229-add-wccom19063-in-app-shared-by-badge

Co-authored-by: And Finally <andfinally@users.noreply.github.com>

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

* Use pointer as cursor for status popovers

* Don't focus-within the status badge popover on load (prevents ugly link focus issue)

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: And Finally <andfinally@users.noreply.github.com>
2024-05-17 13:22:50 +01:00
Seghir Nadir 1ae7ca5179
Make checkout sidebar (order summary) sticky on desktop (#47376)
* Make sidebar sticky on desktop

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

* limit sidebar sticky to cart only

* add useless new line

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-17 13:13:01 +02:00
Karol Manijak 40b43e8d9c
Prevent collection different than Product Catalog from being filtered (#45820)
* Prevent collection different than Produyct Catalog from being filtered

* Adjust Product Filters tests

* Split taxonomies filter into seperate filter per taxonomy

* Add changelog

* Improve onDeselect function

* Update Product Filter test handlebars so they all use Product Collection that inherits query from template

* Set Product Collection to inherit query from template in PHP unit tests

* Remove unnecessary empty space

* Add changelog

* Update tests

* Fix lint

* Update Product Collection attributes in filter E2E handlebars

* Update the Product Filters testing pages title

* Satisfy TS by returning single React element rather than array of elements

* Revert some incorrect changes

* Cleanup after accidental incorrect merge

* Add template utils to dynamic contents util

* Fix Attribute Filter tests

* Cleanup Attribute tests, refactor and fix types

* Add product filter on top of attirbute filter in handlebars

* Fix lint

* Update Rating filter tests to use Product Archive template instead of post

* Update Rating Filter handlebars

* Update Stock filter tests to use Product Archive template instead of post

* Update Stock Filter handlebars

* Add more granular util to update Produyct Catalog based on handlebar template

* Use Product Catalog util and simplify test scenarios

* Unify handlebar templates

* Fix Product Collection attributes in Product Filter handlebar templates

* Revert temporary timeouts increase

* Remove unused types

* Cleanup types

* Cleanup types

* Lint fix

* Rename updateTemplatesContent to updateTemplateContents to better depict its purpose

* Fix types

* Rename updateProductCatalogContent to updateProductCatalogTemplate to better depict its purpose

* Allow for beforeAll and afterAll in PW tests

* Use beforeAll and afterAll instead of using fixture in active filters test

* Use beforeAll and afterAll instead of using fixture in attribute filters test

* Use beforeAll and afterAll instead of using fixture in price filters test

* Use beforeAll and afterAll instead of using fixture in rating filters test

* Use beforeAll and afterAll instead of using fixture in stock status filters test

* Get rid of updateProductCatalogTemplate util as it's too specific

* Extract some constants

* Remove unused file probably added here by accident

* Adjust Attribute Filter block tests to the new logic

* Merge fix

* Bring back necessary handlebars file

* Merge fix

* Merge fix

* Update beforeAll

* Avoid relying on product collection page object in before all

* Bring back the original order of tests

* Switch Filter by Attribute tests to handlebars

* Fix typo

* Update test to new circumstances

* Fix hooks usage
We no longer use hooks other than `beforeEach` since we're resetting the DB for each test (#46125). Using other hooks was not caught by the linter (on this PR) because I accidentally removed the no-hooks rule in #47228 and restored it just now in #47500. 😅

* Fix the test

* Fix Price filter test

* Update attribute filter tests

* Share the handlebars between tests

* Update price filter tests

* Update rating filter tests

* Update stock filter tests

* Remove unnecessary product collection page object from filter tests

* Fix typo

* Fix Filter by Stock test

* Simplify Attribute filter test by remoiving one filter from page

* Try to wait for element to be visible

* Fix handlebars syntax for filters so it doesnt throw validation errors and warnings

* Wait for filters to be visible for sure before performing further part of test

* Wait for Site Editor canvas loader

* Fix linter error

---------

Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>
2024-05-17 11:23:56 +02:00
Alba Rincón 5427aa5de8
Replace the default image of the Testimonial single pattern (#47535)
* Replace the default image of the Testimonial single pattern

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-17 11:00:51 +02:00
Vedanshu Jain e19110c564
Fix: Deleting a shop coupon using API returns a 500 error (#47474)
* Fix: Deleting a shop coupon via the API returns a 500 error

* Add unit test for coupon delete.

* Add changelog.

* PHPCS fix.

---------

Co-authored-by: 79mplus Admin <36501099+79mplus-admin@users.noreply.github.com>
2024-05-17 11:25:01 +05:30
Moon 15d146fa84
Fix lint errors with remote spec validator endpoint (#47520)
* Fix lint errors

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-16 15:25:59 -07:00
Ron Rennick db50513c42
use valid repository url in blocks package (#46696)
* use valid repository url in blocks package

* add changelog file

---------

Co-authored-by: Ron Rennick <ronald.rennick@automattic.com>
2024-05-16 13:32:41 -07:00
Alexandre Lara 0a5ab942bd
[Experimental] Product Filters Redesign > Clear Button: Fix CSS Not Found error (#47481)
* Fix CSS error on Product Filter Clear Button

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

* Fix css lint error

* Remove unnecessary css file from Product Filter Clear Button block

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-16 15:59:06 -03:00
Jonathan Lane ad19ff51a3
Add Buildkite reporting for e2e PR and daily runs (#47558)
* Add Buildkite reporting for e2e PR runs

* Set up Buildkite reporting on daily runs

---------

Co-authored-by: Jon Lane <jon.lane@automattic.com>
2024-05-16 15:31:21 -03:00
Seghir Nadir edb930e04b
Fix a11y issues in Cart/Checkout (#47470)
* return focus on drawer

* adjust notice button color

* adjust cart/checkout input label color

* return focus for shipping form button

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-16 18:32:22 +02:00
Matt Sherman d6288e2b2e
REST API: Add variation product type to response (#47377)
* Add type to response

* Add type to schema

* Changelog

* Update property count in schema test
2024-05-16 11:13:07 -04:00
Seghir Nadir 4f348eb540
remove the generic incompatible notice from Checkout block. (#47475)
* remove the generic incompatible notice

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-16 16:52:06 +02:00
Seghir Nadir 9b1e9344e0
Turn Cart change address link to button (#47460)
* Turn Change address link to button

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

* fix lint

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-16 16:51:03 +02:00
Bart Kalisz 90ee3f4ed9
Blocks E2E: Remove obsolete waitForSiteEditorFinishLoading util (#47547) 2024-05-16 16:39:30 +02:00
github-actions[bot] 7e01f4d39c
Delete changelog files based on PR 47514 (#47550)
Delete changelog files for 47514

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-05-16 16:25:37 +02:00
Seghir Nadir a13013e9a5
Skip serialization for customer meta and be more defensive around loading it. (#47514)
* skip data serialization for customer meta

* keep casting as is

* skip old comment

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

* actually leave the comment, it still make sense

* reduce code needed

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-16 15:24:36 +02:00
Bart Kalisz a7bbdb99a2
Blocks E2E: Wait for Site Editor canvas loader (#47541) 2024-05-16 14:49:32 +02:00
github-actions[bot] 8bf9e966d4
Delete changelog files based on PR 47507 (#47543)
Delete changelog files for 47507

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-05-16 13:23:44 +02:00
Sam Seay fcc421d550
Update cart/checkout usage of the @wordpress/components Slot Fill (#47105) 2024-05-16 21:46:24 +12:00
Michal Iwanow 5cd46f48ad
Fetch Marketplace promotions - ensure callback is always registered for `woocommerce_marketplace_fetch_promotions` action (#47262)
* Marketplace promotions - ensure action is always there

We started getting errors 'Scheduled action for woocommerce_marketplace_fetch_promotions will not be executed as no callbacks are registered.' on some environments.

In this commit we ensure that WC_Admin_Marketplace_Promotions::fetch_marketplace_promotions() is always added as a calback to our action hook.

* Marketplace promotions - switch from Action Scheduler to transients

We're switching fetching marketplace promotions from using Action Scheduler
every 12 hours, to a 1 day transient. This makes it easier to ensure that
the requests are triggered only for admins, and that they don't impact frontend
users of the stores.

* Changelog

* Clear action from Action Scheduler

Action woocommerce_marketplace_fetch_promotions is no longer used, so we're clearing it when it's triggered.
Since we cannot self-clear the action, we're triggering a new single action when woocommerce_marketplace_fetch_promotions is run.
This new action's sole responsibility is to clear the original action.
2024-05-16 09:56:59 +02:00
Manish Menaria a7a1264fec
Fix input clearing issue in PriceTextField with improved currency parsing (#47354)
* Fix input clearing issue in PriceTextField with improved currency parsing

This commit addresses a usability issue in the PriceTextField component, highlighted by @dinhtungdu, where the input field would clear itself if users omitted a space between the numeric value and the currency symbol when the currency is configured to appear on the right with a space (e.g., "20$" instead of "20 $"). The problem was rooted in the strict parsing logic that did not account for variations in user input related to currency formatting.

The fix involves an enhancement to the numeric parsing function, which now effectively handles various user inputs regardless of space or placement of the currency symbol. The revised parsing logic uses a regular expression to strip out any characters that are not numeric or the designated decimal separator, and then replaces the locale-specific decimal separator with a period for standard numeric conversion. This approach not only fixes the specific issue but also improves the robustness of the component against similar input variations.

* Refactor currency parsing and improve handling in PriceTextField

1. Renaming `formatValueAsCurrency` to `formatNumberAsCurrency` to better
   reflect its functionality.
2. Moving the `convertCurrencyStringToNumber` function outside of the
   PriceTextField component, enhancing readability and reusability.
3. Changing the internal state handling from `newValue` to `inputValue`,
   directly managing the string input and parsing it as needed for further
   processing. This will force input field to re-render.

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

* Fix: Handle empty string in price conversion to prevent 0 value

This commit fixes an issue where an empty string in the price conversion function resulted in a value of 0. Now, empty strings are properly handled and do not convert to a numerical value.

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-16 13:23:47 +05:30
Prahesa Kusuma Setia b669fc8526
Prevent calling wccom when the payload is empty for update check (#47507)
* prevent calling wccom when the payload is empty for update check public and non-public

* add changelog
2024-05-16 13:21:34 +07:00
Manish Menaria 1233fb4745
Fix: handle undefined templateSlug in Product Collection tracking utils (#47504)
* fix: handle undefined templateSlug in Product Collection tracking utils

The modification introduces a check for templateSlug before attempting to access its properties or use it in further logic. This change addresses a bug that manifested when users tried to edit a synchronized Product Collection block, resulting in a JavaScript error because templateSlug could be undefined.

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

* Update types to better reflect reality

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Karol Manijak <20098064+kmanijak@users.noreply.github.com>
2024-05-16 11:17:52 +05:30
Chi-Hsuan Huang a120b99d7d
Fix coming soon page mobile UI issues (#47491)
* Update styles for WooCommerce coming soon page

- Add min-width to container for better responsiveness
- Adjust padding for smaller screens
- Update font size and text wrapping for banner

* Add changelog

* Improve readability
2024-05-16 12:46:26 +08:00
Chi-Hsuan Huang 9e32aafd38
Disable auto zoom when focusing on input for core profiler (#47400)
* chore: Add viewport meta tag for setup wizard

* Add changelog
2024-05-16 10:45:26 +08:00
Alexandre Lara 7abb996017
[Experimental] Product Filters Redesign: Add the Product Filters block (#47294)
* Add Product Filters block

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

* Add the blocks template for the Product Filters block

* Dynamically add the highest product count attribute to the block template

* wip: Add E2E tests for the Product Filters block

* Add E2E tests for the Product Filters block

* Add CSS file to Product Filters block

* Fix css error lint

* Fix lint error

* Fix lint errors

* Remove unnecessary styles for the Product Filters block

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-15 18:09:48 -03:00
Fernando Marichal 8dd87820cf
Disable pre-publish panel (#47430)
* Disable pre-publish panel

* Add changelogs

* Fix e2e tests
2024-05-15 15:52:42 -03:00
Fernando Marichal aa6137128d
Move pricing features to General tab (#47435)
* Move pricing section

* Fix e2e tests

* Fix create-variable-product tests

* Add changelog

* Add changelog in WC
2024-05-15 14:53:27 -03:00
Moon bcd80f4c95
Bump beta tester to 2.3.1 to prep a new release (#47427)
* Bump version to 2.3.1 and add changelog

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

* Update readme.txt and clean up old changelog files

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-15 10:21:54 -07:00
Luigi Teschio 8c6efe072b
Blocks: Fix JS unit tests (#47516)
* Blocks: Fix JS unit tests

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

* trigger CI

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-15 16:03:11 +00:00
Herman e65481aa27
Marketplace business services: Feature branch (#47303)
* Support for Business Services in in-app marketplace ()

Contains the changes from:

#46530
#46725
#47048
#47135
#47183
#47227
#47352
#47452

* Update plugins/woocommerce-admin/client/marketplace/README.md

Fix documentation punctuation

---------

Co-authored-by: Raja Sekar Manimaran <raja.sekar.manimaran@automattic.com>
Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Michal Iwanow <4765119+mcliwanow@users.noreply.github.com>
Co-authored-by: Dan Q <dan@danq.me>
2024-05-15 14:43:06 +02:00
Luigi Teschio 1af8e8a4d4
Blocks: Delete Jest-Puppeteer infrastructure (#46672)
* try db reset in page teardown

* move reset to setup step

* Use wp db cli

* Fix global setup
That part is overriding the logged in user state and wipes out the nonce and rootUrl fields.

* Try importing instead from a generated dump

* Revert "Try importing instead from a generated dump"

This reverts commit 987dc471c9.

* Revert "Revert "Try importing instead from a generated dump""

This reverts commit c8d008cb20.

* Don't bypass visitSiteEditor so that the Welcome Guide is closed

* use createNewPost

* Revert "Revert "Revert "Try importing instead from a generated dump"""

This reverts commit 2684273582.

* [Blocks]: Fix E2E tests (#46344)

* Load local pickup enabled setting as bool not string

* Add changelog

* Remove unused import

* Update plugins/woocommerce-blocks/assets/js/extensions/shipping-methods/pickup-location/utils.ts

Co-authored-by: Niels Lange <info@nielslange.de>

* Use strict equality test

* try now

* try now

* add a new sql file

* remove default.sql

* fix welcome guide tour

* fix E2E tests

* Fix the template revert tests
...where the template is unreachable due to pagination.

* Add changelog entry

* improve logic to closeWelcomeGuideModal

* fix cart checkout tests

* improve flakiness

* improve flakiness

* fix flaky test

* fix company field

* fix E2E test

* fix E2E tests

---------

Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Niels Lange <info@nielslange.de>
Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>

* Replace beforeAll w/ beforeEach + remove all after* hooks

* Fix broken hooks

* Activate plugins via requestUtils API

* [Blocks - E2E]: Add `playwright/no-hooks` ESlint rule (#46432)

add ESLint configuration

* Clean up console logs

* Remove obsolete language setup steps

* Remove more unnecessary setup steps

* Remove even more obsolete setup steps

* tmp: add the LYS fix

* Try stabilizing the company field test

* Use canvas param instead of manually entering edit mode

* Remove double site editor redirect

* Revert "Use canvas param instead of manually entering edit mode"

This reverts commit 5e6cc17154.

* Revert "Remove double site editor redirect"

This reverts commit 69a57a82a8.

* Fix flaky products sorting test

* Blocks: Fix ESLint errors (#46595)

fix eslint error

* Fix ESLint errors (#46626)

* Fix ESLint errors

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

---------

Co-authored-by: github-actions <github-actions@github.com>

* Blocks: Migrate multiple tests to Playwright

* fix path

* migrate other tests

* add product best sellers E2E tests

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

* migrate jest-puppetter E2E tests to Playwright

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

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

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

* Blocks: Delete Jest-Puppeteer infrastructure

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

* Remove obsolete waitForLoadState call

* improve E2E tests

* fix E2E tests

* improve E2E tests

* remove old test

* remove not necessary test

* fix number product

* fix E2E test

* fix number of products

* fix product count

* refactor store notice E2E tests

* update string

* fix E2E test

---------

Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>
Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Niels Lange <info@nielslange.de>
Co-authored-by: github-actions <github-actions@github.com>
2024-05-15 14:22:36 +02:00
Bart Kalisz e765a717d2
Blocks E2E: Restore the no-hooks rule (#47500) 2024-05-15 13:05:52 +02:00
Sam Seay 3ef7a01840
Update blocks JS tests to React 18 (#47383) 2024-05-15 21:33:36 +12:00
Akeda Bagus 02c640480d
Free some in-memory usage when doing HPOS-related batch processing (#47159) 2024-05-15 09:19:56 +00:00
rodelgc 931bfed5c6
Update stable tag to 8.8.3 (#47496)
woorelease: Update stable tag to 8.8.3

Co-authored-by: rodel <rodel@rodels-MacBook-Pro.local>
2024-05-15 16:16:53 +08:00
Manish Menaria 9f5f93cba6
Product Collection: Implement Preview Mode (#46369)
* POC: Preview Mode using HOC

* Add explanation as comments

POC: Implement preview mode for Product Collection block in editor
- Added extensive commentary to clarify the mechanism and usage of the `handlePreviewState` function
- Implemented an internal state within `ProductCollectionContent` to manage preview status and messages, serving as a foundational example of how preview mode can enrich block functionality.
- Showcased the application of `handlePreviewState` by incorporating it as a prop in `BlockEdit`, illustrating the potential for extending the block's capabilities for dynamic and interactive previews.

This POC demonstrates a flexible approach to managing preview states within the editor, paving the way for further development and integration based on feedback and use-case analysis.

* Refactor preview state handling and collection registration

This commit introduces a centralized approach for registering product collection variations and managing their preview states. It abstracts the registration logic into a dedicated function and enhances the flexibility of preview state handling across different collection types.

* Rename file

* Minor improvements

* Don't pass previewState to handlePreviewState

I don't see any good use of it in handlePreviewState. Also, We will be going to call handlePreviewState only once
therefore, it will always have the same value as the initial value of the previewState. If in future, we decide to run it
multiple times then we can pass the previewState as an argument to handlePreviewState.

* Add comment

* Use JS closure to inject handlePreviewState

This commit introduces a refined approach for injecting the `handlePreviewState` function into product collection blocks, utilizing JavaScript closures to streamline the process. This method replaces the previous global registry mechanism, offering a more direct and efficient way to manage preview states.

Advantages of This Approach:
- Utilizing JavaScript closures for injecting `handlePreviewState` simplifies the overall architecture by directly modifying block edit components without relying on an external registry. This method enhances code clarity and reduces the cognitive load for developers.
- The conditional application of `withHandlePreviewState` ensures that the preview state handling logic is only added to blocks that require it, optimizing performance and maintainability.

* Refactor preview state management into custom hook

This commit enhances the organization and readability of the product collection content component by abstracting the preview state management into a custom hook named `usePreviewState`. This change streamlines the component's structure and aligns with React best practices for managing state and side effects.

Key Changes:
- Introduced `usePreviewState`, a custom hook responsible for initializing and managing the preview state (`isPreview` and `previewMessage`) of the product collection block. This hook encapsulates the state logic and its side effects, including the conditional invocation of `handlePreviewState`.
- Modified `ProductCollectionContent` to utilize `usePreviewState` for handling its preview state. This adjustment makes the component cleaner and focuses it more on presentation and behavior rather than state management details.

* Replace useEffect with useLayoutEffect

* Add cleanup function in handlePreviewState function

Based on [this discussion](https://github.com/woocommerce/woocommerce/pull/45703#discussion_r1535323883), I added a cleanup function support for handlePreviewState. `handlePreviewState` can return a function which will be called on cleanup in `useLayoutEffect` hook.

* Fetching random products in Preview mode

* Allow collection to set initial preview state

* Pass location & all attributes to handlePreviewState function

* Handling collection specific query for preview mode

- Consolidated `handlePreviewState` and `initialPreviewState` into a single `preview` prop in `register-product-collection.tsx` and `product-collection-content.tsx` to streamline prop passing and improve the component interface.
- Updated the `queryContextIncludes` in `constants.ts` to include 'previewState'
- Enhanced the `ProductCollection` PHP class to handle preview-specific queries more effectively, introducing a new method `get_preview_query_args` that adjusts query parameters based on the collection being previewed, thereby improving the relevance and accuracy of products displayed in preview mode.

* Always set initialPreviewState on load

* Refine preview state handling

- Renamed `HandlePreviewStateArgs` to `SetPreviewStateArgs` in `featured.tsx` to better reflect its purpose, which is now more focused on setting rather than handling states. The implementation details within `featured.tsx` have also been refined to include async operations and cleanup functions, demonstrating a more sophisticated approach to managing state.

Overall, these updates make the preview state logic more understandable and maintainable.

* Rename "initialState" to "initialPreviewState"

* Fix: Correct merging of newPreviewState into previewState attribute

This commit addresses an issue in the product-collection-content.tsx where the newPreviewState was not properly merged into the existing previewState attribute. Previously, the spread operator was incorrectly applied, leading to potential loss of existing state attributes. By changing the order of operations and correctly spreading the existing attributes before merging the newPreviewState, we ensure that all state attributes are preserved and updated correctly.

* Initial refactor POC code to productionize it

* Move `useSetPreviewState` to Utils

* Implement preview mode for Generic archive templates

Implemented a new useLayoutEffect in `utils.tsx` to dynamically set a preview message in the editor for product collection blocks located in generic archive templates (like Products by Category, Products by Tag, or Products by Attribute).

* Remove preview mode from Featured and On sale collection

* Remove preview query modfication for On Sale collection

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

* Fix: hide/show preview label based on value of "inherit"

If user change the toggle "Sync with current query", then it should reflect for the preview label as well.
- If the toggle is on, then the preview label should be shown.
- If the toggle is off, then the preview label should be hidden.

* Minor improvements

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

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

* Refactor: Simplify SetPreviewState type definition in types.ts

This commit refines the SetPreviewState type definition by eliminating the previously used intermediate interface, SetPreviewStateArgs. The change streamlines the type definition directly within the SetPreviewState type, enhancing readability and reducing redundancy.

* Update import syntax for ElementType in register-product-collection.tsx

This commit updates the import statement for `ElementType` from `@wordpress/element` to use the more modern and concise `import type` syntax. This change does not affect functionality but aligns with TypeScript best practices for importing types, ensuring that type imports are distinguished from regular imports. This helps in clarity and in optimizing the build process by explicitly indicating that `ElementType` is used solely for type checking and not included in the JavaScript runtime.

* Refactor: Update TypeScript usage in Product Collection

This commit introduces several TypeScript refinements across product-collection components:

1. **DEFAULT_ATTRIBUTES** in `constants.ts` now uses `Pick` to explicitly define its shape, ensuring only relevant attributes are included and typed accurately.
2. **ProductCollectionAdvancedInspectorControls** and **ToolbarControls** in the `edit` subdirectory now use `Omit` to exclude the 'preview' property from props, clarifying the intended prop usage and improving type safety.

These changes collectively tighten the type definitions and improve the codebase's adherence to best practices in TypeScript.

* Refactor: Update dependencies of useSetPreviewState hook in utils.tsx

This change enhances the stability and predictability of the hook's behavior, ensuring it updates its internal state accurately when its dependencies change, thus aligning with best practices in React development.

* Refactor preview button CSS and conditional rendering

1. **CSS Refactoring:** Moved the positioning styles of the `.wc-block-product-collection__preview-button` from inline styles in the JSX to the `editor.scss` file. This separation of concerns improves maintainability and readability, aligning the styling responsibilities solely within the CSS file.
2. **Conditional Rendering Logic:** Updated the rendering condition for the preview button. Now, it not only checks if `isPreview` is true but also if the block is currently selected (`props.isSelected`). This prevents the preview button from appearing when the block is not actively selected, reducing visual clutter and enhancing the user experience in the editor.

* Enhance: Update preview button visibility logic in ProductCollectionContent

This commit enhances the visibility logic of the preview button in the `ProductCollectionContent` component:

1. **Added `isSelectedOrInnerBlockSelected`:** Introduced a new `useSelect` hook to determine if the current block or any of its inner blocks are selected. This ensures that the preview button is visible when either the product collection block or any of its inner blocks are selected.
2. **Updated Conditional Rendering:** Adjusted the conditional rendering of the preview button to use the new `isSelectedOrInnerBlockSelected` value, providing a more intuitive user experience by ensuring the preview button remains visible when any relevant block is selected.

* use __private prefix with attribute name

* Add E2E tests for Preview Mode

1. **Template-Specific Tests:** Each template (tag, category, attribute) undergoes a test to ensure the preview button behaves as expected when replacing products with product collections in these contexts.
2. **Visibility Checks:** The tests verify that the preview button is visible when the block or its inner blocks are selected and hidden when the block is not selected. This helps confirm the correct implementation of the preview button visibility logic across different use cases.
3. **Interaction with Inner Blocks:** Additional checks are included to ensure the preview button's visibility toggles appropriately when interacting with inner blocks, reinforcing the dynamic nature of block selection and its effect on UI elements within the editor.

* Add setPreviewState to dependencies

* Add data-test-id to Preview button and update e2e locator

Modifications:
- Added `data-test-id="product-collection-preview-button"` to the Preview button in `product-collection-content.tsx`.
- Updated the corresponding e2e test locator in `product-collection.block_theme.side_effects.spec.ts` to use the new `data-test-id` instead of the class name.

By using `data-test-id`, we ensure that the e2e tests are not affected by changes in the styling or restructuring of the DOM that might alter CSS classes but do not affect functionality.

* Enhance: Localize preview message in useSetPreviewState hook

* Don't show shadow & outline on focus

* Make preview button font same as Admin

* Fix SCSS lint errors

* Add missing await keyword

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-15 13:18:43 +05:30
Michael Pretty e50c8426fb
fix PHP 8 warning in Blocks\Installer\create_pages() callback when oher filters have removed pages (#47094) 2024-05-15 08:45:37 +02:00
Chi-Hsuan Huang d5166dcfed
Fix undefined variable `$exlude_paths` (#47490)
* Fix typo in exclude_paths variable name

* Add changelog
2024-05-15 03:41:53 +00:00
Moon 042766c28c
Do not display smart app banner on the core profiler, LYS, and CYS pages (#47429)
* Do not display smart app banner on the core profiler pages

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

* Ignore hook doc errors -- need to re-visit this later

* Document filters with basic info -- using 6.5.0 for since tag. That is the first release after WC Admin was merged to the core

* Update plugins/woocommerce/src/Internal/Admin/Loader.php

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

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>
2024-05-14 17:41:57 -07:00
Jonathan Lane 6e8a922943
Update stalebot workflow for flaky tests (#47484)
Co-authored-by: Jon Lane <jon.lane@automattic.com>
2024-05-14 16:02:18 -07:00
César Costa f5e45ef376
Update symbol and formatting of the XPF currency (#46960)
* Update XPF currency symbol to XPF

* Change XPF default locale formatting

* Change decimal separator of countries that use XPF to dot

* Add changelog entry

* Update changelog entry

* Fix XPF test data

* Fix some JS linting issues

* Revert "Fix some JS linting issues"

This reverts commit 51abcf4117.

* Fix some JS linting issues
2024-05-15 04:50:55 +07:00
Akeda Bagus b931117f7a
Fix dates dropdown in admin list order page (#47440)
* Fix dates dropdown in admin list order page

The query was missing a filter to order type.

Fixes #47406.

* Fix changelog header
2024-05-14 19:29:45 +00:00
Fernando Marichal 2575d455f7
Fix flaky Attributes and Variations E2E tests (#47471)
* Wait for attributes until request is complete

* Wait for response

* Add changelog
2024-05-14 13:59:34 -04:00
Álvaro Thomas 32d10eacf8
Update stable tag to 8.9.0 (#47482)
woorelease: Update stable tag to 8.9.0
2024-05-14 19:56:10 +02:00
Jorge A. Torres 089be925d9
Add some unit tests to cover changes in PR 46972 (#47098)
* Add unit tests for 's' search parameter in HPOS queries

* Add changelog

* Fix PHPCS issue
2024-05-14 20:34:17 +05:30
Sakri Koskimies 5a8dfac898
Add support for FI and SE postcode validation + Update tests (#45480)
* Add validation for FI, SE postcodes

* Add non-legacy WC_Validation_Test test class

* Add changefile

* Add validation for EE postcode

Co-authored-by: ragulka <illimar.tambek@gmail.com>

* Apply phpcs fixes.

---------

Co-authored-by: ragulka <illimar.tambek@gmail.com>
Co-authored-by: Vedanshu Jain <vedanshu.jain.2012@gmail.com>
2024-05-14 20:09:55 +05:30
Luigi Teschio 603184182b
CYS: mutate the original instance of the block array (#47468)
* mutate the original instance of the block array

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

* trigger CI

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-14 16:05:09 +02:00
Adrian Moldovan 7b96dfca67
[e2e tests] Remove BuildKite reporter (#47449)
* Remove BuildKite reporter

* Changelog

* Remove BuildKite reporter from api tests
2024-05-14 10:25:17 +01:00
Thomas Roberts 35f07934a4
Remove bold text from selected payment method in Checkout block (#47412) 2024-05-14 02:00:30 -07:00
Jorge A. Torres f241b4dd08
Add support to HPOS CLI tool for handling deleted orders (#46970)
* Add support for removed orders to cleanup tool

* Add changelog
2024-05-14 14:24:15 +05:30
Bart Kalisz 1e1e7dd65d
Blocks E2E: Align ESLint and TS configs with Gutenberg (#47228) 2024-05-14 10:23:17 +02:00
Karol Manijak bf2d622a66
Product Collection: telemetry for filter usage (#46545)
* Create trackInteraction function and pass it to query Insprector Controls

* Add tracking to Attribute filter

* Add tracking to Created filter

* Add tracking to Featured filter

* Add tracking to Handpicked Products filter

* Add tracking to Inherit Query filter

* Add tracking to Keyqord filter

* Add tracking to On Sale filter

* Add tracking to Order By option

* Add tracking to Stock Statusoption

* Add tracking to Price Range filter

* Add tracking to Taxonomies filter

* Fix lint errors

* Add changelog

* Rearrange the logic of recognising the tracks location so it's more reliable
2024-05-14 09:45:33 +02:00
Chi-Hsuan Huang d66c5b8efe
Add UTM tags to all product links in core profiler Free features step (#47397)
* Add UTM tags to all product links for core profiler default free extensions

* Add changelog

* Update mailpoet link
2024-05-14 10:32:51 +08:00
Paul Sealock 208e5633ba
[Launch Your Store] Add e2e tests (#47239)
* LYS spec

* get homescreen check working

* move over to shopper

* basic test

* get first test working

* Store only coming soon mode - logged out

* add logged in ttests

* linter

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

* Remove skip from tests

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-14 11:41:35 +12:00
github-actions[bot] d19e90105a
Delete changelog files based on PR 47003 (#47439)
Delete changelog files for 47003

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-05-14 00:24:24 +01:00
Christopher Allford b8aabe9005
Fixed Taxonomy Term Limit On Product Collection Filters (#47155)
In the interest of avoiding pagination this refactor swaps the current term loading with one that doesn't require a cache of all terms. We've removed the need for the cache by storing the ID and term name together in the token/suggestion list and using a display transformation to hide any unnecessary information.
2024-05-13 16:00:24 -07:00
Roy Ho f5dc46a385
Product Filters: add individual clear button (#47101)
* Product Filters: add individual clear button

* Remove unused style.scss

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

* Simplify searching for the tag

* Convert to use button instead of anchor

* Try using iAPI to show/hide clear button

* Use local context instead of global state

* Fix linting error

* Remove unneeded context

* Update clear button block description

* Fix frontend PHP error

* Add e2e tests for attributes filter clear button

* Add e2e tests for price filter clear button

* Add e2e tests for rating filter clear button

* Add e2e tests for stock status filter clear button

* Address feedback and use built in locators

* Address feedback and replace the use of timeouts

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-13 15:19:56 -03:00
Fernando Marichal fdb4069566
Remove not used feature flags (#47150)
* Remove product-virtual-downloadable

* Remove product-variation-management

* Remove product-external-affiliate

* Remove product-grouped

* Remove product-linked

* Remove customer-effort-score-tracks

* Add beta tester changelog

* Add changelogs
2024-05-13 15:05:47 -03:00
Albert Juhé Lluveras 8da8a70839
Update docs about blocks styling to clearly state global styles are the recommended approach (#47269)
* Update docs about blocks styling to clearly state global styles are the recommended approach

* Markdown formatting fixes

* Add changelog file

* Add styling the Product Price block example

* Markdown formatting fixes (II)

* Update plugins/woocommerce-blocks/docs/designers/theming/README.md

Co-authored-by: Patricia Hillebrandt <patriciahillebrandt@gmail.com>

* Update plugins/woocommerce-blocks/docs/designers/theming/README.md

Co-authored-by: Patricia Hillebrandt <patriciahillebrandt@gmail.com>

---------

Co-authored-by: Patricia Hillebrandt <patriciahillebrandt@gmail.com>
2024-05-13 18:26:50 +02:00
Seghir Nadir ccba86a616
Update additional fields document's TOC and link to it from another document. (#47137)
* update docs

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

* fix linting

* update manifest

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-13 15:46:46 +00:00
Seghir Nadir b5850bbfc1
Select a shipping rate after they load (#47120)
* select a shipping rate if there are no shipping rates on mount

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

* move code and explain it

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-13 15:29:04 +00:00
Seghir Nadir de4180c17a
Make german state field visible but not required (#47319)
* Make german state field visible but not required

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-13 15:19:35 +00:00
Bart Kalisz 9a71f3ac5f
Blocks E2E: Remove the DB snapshot on env reset (#47416) 2024-05-13 17:19:15 +02:00
Moon 5183b1bb1b
LYS - Disable the save changes button until changes are made (#47316)
* Disable the save changes button until changes are made

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

* Fix broken test

* Test

* Remove test code

* Tmp fix - fix broken test

* Fix incorrect comparison

* Remove test code

* minor refactor -- re-use setting

* Remove use of loadash isequal

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-13 07:56:51 -07:00
Seghir Nadir b256336176
reset state and postcode if it's not valid for the current country (#47369)
* reset state if it's not valid for the current country

* reset postcode as well

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

* update logic so its in Checkout block instead of store api

* fix linting

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-13 16:46:08 +02:00
Paulo Arromba 98510fe9fd
Add woocommerce_order_received_verify_known_shoppers filter to order confirmation template (#46957)
* Adds filter `woocommerce_order_received_verify_known_shoppers` to allow known shoppers to access the order received page without being logged in in Order Confirmation template

* Added changelog

* Added filter docblock

* Refactored to apply the filter correctly for non-guests only.

* Restored comment.

* Added test

* Added test

* lint

* Change plugin package name

* Update plugin name (apparently slugs are formed from that)

* Added right prefix

* JS linting

* Refactored testing into a test.step()

* typo

* Fixed tests.

* Reverted change done by mistake.

* remove getByRole specificity

* Increase selector specificity specificity

* Change test prefix

* reduce test flakyness

* reduce test flakyness

* reduce test flakyness
2024-05-13 15:28:36 +01:00
Seghir Nadir 76a9e2eb27
Move country to top of form for all countries (#47375)
* Move country to top of form for all countries

* adjust styling

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-13 16:24:40 +02:00
Sam Seay 2db29164f9
Update to pnpm 9.1 (#47385)
* Update to pnpm 9.1 and fix a mini css bug

* Add changefile(s) from automation for the following project(s): @woocommerce/tracks, @woocommerce/product-editor, @woocommerce/onboarding, @woocommerce/number, @woocommerce/notices, @woocommerce/navigation, @woocommerce/internal-js-tests, @woocommerce/extend-cart-checkout-block, @woocommerce/expression-evaluation, @woocommerce/explat, @woocommerce/experimental, @woocommerce/eslint-plugin, @woocommerce/dependency-extraction-webpack-plugin, @woocommerce/date, @woocommerce/data, @woocommerce/customer-effort-score, @woocommerce/currency, @woocommerce/csv-export, @woocommerce/create-woo-extension, @woocommerce/create-product-editor-block, @woocommerce/components, @woocommerce/api, @woocommerce/ai, @woocommerce/admin-e2e-tests, woocommerce-blocks, woocommerce-beta-tester, woocommerce, woo-ai

* temporarily disable swallowing build output to diagnose issue with perf workflow

* Ignore some type issues that commonly resurface when deps slightly change

* Fix persistent type issues that have recurred many times

* Add more ignores

* Fix lint issue

* Revert change to swallow build error

* Improve access of the config that needs updated build dir.

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-13 10:57:39 -03:00
Akeda Bagus 5bbbc52c0d
Respect locale setting to format order counts in admin orders list page (#47373)
* Respect locale setting to format order counts in admin orders list page

Fixes #47372

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-13 14:28:31 +01:00
Bart Kalisz 30756f74e3
Blocks E2E: Refactor configs and workflow (#46409) 2024-05-13 14:58:26 +02:00
Paulo Arromba 4840af874a
Add phone number to my account shipping address. (#47062)
* Added phone number support to Shipping Address and refactor the code.

* Refactored to avoid evaluating extra if on !== billing address form

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

* Fixed tests.

* Mock phone number consistency
2024-05-13 12:48:57 +01:00
Brian 69daa61877
Add aria-label to My Account Navigation Item (#43696)
Co-authored-by: Niels Lange <niels.lange@a8c.com>
Co-authored-by: github-actions <github-actions@github.com>
2024-05-13 14:23:19 +03:00
Patricia Hillebrandt 7313127649
CYS > Add a feature flag for full composability and the Pattern Toolkit (#47392)
* Add a feature flag for full composability and the Pattern Toolkit projects.

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-13 12:28:20 +02:00
Justin Palmer 7796c13b65
Make method getAttributionData globally accessible (#46965)
* Make method to getAttributionData externally accessible

* Include checks for sjbs availability

* Failsafe for the custom html element if sbjs isn't available

* Changelog
2024-05-13 12:24:32 +02:00
github-actions[bot] b164d19328
Delete changelog files based on PR 47398 (#47405)
Delete changelog files for 47398

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-05-13 12:09:56 +02:00
Néstor Soriano f61bdd51d5
Fix fatal error when trying to download log files (#47398)
* Fix inverted logif for readable file check in FileExporter::emit_file

* Fix: instance of WP_Error being passed to PageController::handle_list_table_bulk_actions
2024-05-13 11:28:09 +02:00
Ramon Ahnert 49c379c5a7
Fix typo in the Exposing your data in the Store API documentation (#43488)
* Fix basic usage code snippet example in extend-rest-api-add-data.md

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-13 15:20:07 +07:00
Chi-Hsuan Huang b28adc1703
Use a real em dash character (—) in the coming soon site template (#47394)
* Use a real em dash character (—) in the coming soon template

* Add changelog
2024-05-13 15:51:42 +08:00
Prahesa Kusuma Setia db804f4193
Tracks event for WooCommerce.com connect notice (#47003)
* add tracks event in the wc settings connect notice

* add clicked and dismissed tracks event in the marketplace connect notice

* add shown tracks event in the marketplace connect notice

* add changelog

* fix linter error

* Add Tracks event when connect-notice in plugin is shown and clicked

* Add docblock for maybe_enqueue_scripts_for_connect_notice_in_plugins

---------

Co-authored-by: Akeda Bagus <akeda.bagus@automattic.com>
2024-05-13 13:45:43 +07:00
Ilyas Foo c4ca5f87d9
Reenable global styles for coming soon entire site template (#47388)
* Reenable global styles for coming soon pages

* Changelog

* Update fix-lys-reenable-global-styles
2024-05-13 13:38:54 +08:00
Moon 6cf09f30a8
LYS - Use flow layout for the coming soon template (#47335)
* Use flow layout

* Tmp fix - fix broken test

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

* Use flex layout

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-13 13:15:47 +08:00
RJ 2898efa648
add: lys badge tracks (#46509) 2024-05-13 07:52:49 +08:00
Cem Ünalan 23773e19f0
Freemium: update marketplace product card label (#45982)
* Freemium: update marketplace product card label

* 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-05-10 15:00:05 -05:00
github-actions[bot] 821d764b04
Delete changelog files based on PR 47205 (#47367)
Delete changelog files for 47205

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-05-10 17:13:50 +02:00
Matt Allan 6a89723685
Update when PayPal Standard is loaded to further reduce new store using this legacy payment method (#47205)
* Change default PP Standard should_load logic to be more strict when setting to true

* Remove filter allowing stores to enable PayPal Standard programmatically

* Adds new function to check if the store has any PayPal Standard orders

* Upgrade script that disables PayPal Standard on stores that aren't using it.

* Add changelog entries

* Fix extra comma

* PayPal email is defaulted to the admin email which means checking needs_setup() isn't reliable

* Load PayPal standard in unit tests

* Before installing WC, set the Paypal Standard should load to true

* Remove unnecessary ternary when setting default should_load

* On upgrading WC, only check for PayPal Standard live keys to determine if it's setup

* Remove admin notice if PayPal Standard is disabled on ugprade

* Display an admin notice if the store is using the deprecated filter to load PayPal Standard.

* Add docblock comment above the apply filters

* Added checks around the filter and give pref to enabled.

git add .

* Remove the should load filter notice.

* Add comment noting that init class shouldnt be removed.

* Use proper casting for this->enabled before usage.

---------

Co-authored-by: Vedanshu Jain <vedanshu.jain.2012@gmail.com>
2024-05-10 14:04:32 +01:00
Moon d0a8477b51
LYS - Add padding-left to the copy link (#47313)
* Adding padding to the copy link

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

* Tmp fix - fix broken test

* Fix lint errors

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-10 05:02:35 -07:00
Néstor Soriano 772d796ea3
Fixes in the receipts rendering engine (#47300)
* Fix permission check in RestApiControllerBase

Extra arguments were being passed incorrectly to current_user_can,
causing wrong authentication failures in some cases (e.g.
when hitting the endpoints in a wp.com site via Jetpack tunneling).

* Fix get_order_data in ReceiptRenderingEngine

A fatal error was being thrown when one of the products referenced
in the order did no longer exist.
2024-05-10 13:12:54 +02:00
Moon 0873ed47c3
LYS - Update toolbar store link text (#47315)
* Update toolbar store link

"Preview store" when coming soon mode is enabled
"View store" when the site is set to live

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

* Fix broken test

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-10 04:00:41 -07:00
Moon a8cf226987
LYS - Use Woo branded colors for LYS confetti (#47334)
* Update LYS congrats confetti

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

* remove temporary fix

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-10 04:00:33 -07:00
Naman Malhotra 01069666e6
Fix: Reset password form missing required indicator (#47229)
* Fix: Reset password form missing required indicator

* Added changelog

* Updated templae version

* Address feedback
2024-05-10 10:08:05 +00:00
Moon 7556b7bffc
LYS - Remove admin toolbar button hover background (#47314)
* Remove hover background

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

* Tmp fix - fix broken test

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-10 02:16:54 -07:00
Jonathan Lane c78292e6cc
Add API test for refunds endpoint (#47340)
Co-authored-by: Jon Lane <jon.lane@automattic.com>
2024-05-10 11:56:53 +03:00
Jonathan Lane 396c29d3ec
Install and set up BuildKite test analytics (#47202)
Co-authored-by: Jon Lane <jon.lane@automattic.com>
Co-authored-by: Adrian Moldovan <3854374+adimoldovan@users.noreply.github.com>
2024-05-10 11:47:23 +03:00
Néstor Soriano b7d32ffa30
Add hooks to customize the order receipt generation (#46224)
Also:

- Move CSS to a separate template
- Access receipt data through a $data array in the template
  (don't extract the variables anymore)
2024-05-10 09:26:27 +02:00
Luigi Teschio 8954785c96
CYS: not run font picker tests on WordPress 6.4 (#47182)
* CYS: not run font picker tests on WordPress 6.4

* improve how the test is skipped

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-10 10:26:56 +08:00
Chi-Hsuan Huang 66c57693c1
Fix RIN Display Logic for Banner Alert Notifications (#47167)
* Fix RIN Display Logic for Banner Alert Notifications

* Add tests

* Add changelog

* Update test

* Add test

* chore: fix unactioned note status check in EvaluateAndGetStatus.php
2024-05-10 09:58:09 +08:00
Moon 14018bec62
Replace Options API usage with LaunchYourStore endpoint for LYS (#47252)
* Replace Options.php usage with LaunchYourStore controller

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

* Catch error, but ignore it

* Tmp fix - fix broken test

* Lint fixes

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-09 15:59:36 -07:00
Moon 7360928502
Use wp_plugin_dependencies_slug in PluginVersionRuleProcessor (#47235)
* Use wp_plugin_dependencies_slug

* Fix incorrect function name

* Remove unnessary content-type header

* Add doc block for wp_plugin_dependencies_slug filter

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

* Tmp fix - fix broken test

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-09 15:30:12 -07:00
Corey McKrill 576db0933c
REST API: Add missing line item schemas to refunds endpoint (#47254)
* REST API: Add missing line item schemas to refunds endpoint

In #28241, `fee_lines`, `shipping_lines`, and `tax_lines` properties
were all added to the refund data object sent by v2 and v3 of the
REST API. However, the schema was never updated, so the characteristics
of those properties have not been very discoverable. This simply
copies the relevant schema data from the orders endpoint over to the
refunds endpoint.

Towards #43444

* phpcs cleanup
2024-05-09 21:59:30 +00:00
Corey McKrill 35908b8ee3
Update `WC_Admin_Tests_API_Plugins` to use different plugins for testing (#47337)
Updates the tests in WC_Admin_Tests_API_Plugins to use plugins other than `facebook-for-woocommerce` to hopefully be more reliable in the future.
2024-05-09 13:03:59 -07:00
Adrian Moldovan 5591b25367
[ci-jobs] Add the optional property for jobs (#47261) 2024-05-09 12:22:44 +03:00
Jonathan Lane 18e83a2467
🧪 Fix for a couple of failing e2e tests (#47253)
Co-authored-by: Jon Lane <jon.lane@automattic.com>
2024-05-09 11:33:26 +03:00
Chi-Hsuan Huang f2cf6b56aa
Update @automattic/tour-kit to 1.1.3 and @automattic/components to 2.1.1 (#47129)
* Use @automattic/tour-kit@1.1.3

* Update onPreviousStep and onNextStep callback

* Add changelog

* Add changelog

* Update @automattic/components

* Update package.json

* Fix pnpm-lock.yaml

* Update changelog

* Add changelog

* Enable autoScroll for shipping tour
2024-05-09 08:56:08 +08:00
Jorge A. Torres 875d1a7f8e
Override `get_edit_post_link()` URL for HPOS placeholder posts (#47149)
Rewrites edit post links for HPOS placeholder posts so they go to the actual HPOS orders.

Fixes #45806
2024-05-08 14:08:56 -07:00
github-actions[bot] a06bf69976
Delete changelog files based on PR 47171 (#47282)
Delete changelog files for 47171

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-05-08 17:39:00 +02:00
Adrian Moldovan 082719b0fd
[e2e tests] Disable broken product editor tests (#47268)
Co-authored-by: Luigi Teschio <gigitux@gmail.com>
Co-authored-by: github-actions <github-actions@github.com>
2024-05-08 09:33:27 -05:00
Albert Juhé Lluveras 8b47443a1c
Remove unnecessary links to an ephemeral site (#47270)
* Remove unnecessary links to an ephemeral site

* Add changelog file

* Disable markdown lint in some lines
2024-05-08 15:24:25 +02:00
Luigi Teschio 5cdc7fcd43
CYS: fix color picker E2E test (#47274)
Co-authored-by: github-actions <github-actions@github.com>
2024-05-08 16:08:22 +03:00
Niels Lange e7aff9428f
[Enhancement]: Block-based checkout - Pickup section updates (#47173)
* Change “Pickup options” to “Pickup locations”

* Always show pickup location and truncate pickup details

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

* Adjust spacing between pickup details and more link

* Hide pickup details of unselected pickup location

* Adjust line height of truncated text

* Show “Read more/less” instead of “more/less”

* Ensure both lines are equally filled with text

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-08 17:58:09 +07:00
Bart Kalisz 3ad9ebf52a
Blocks E2E: Fix flaky Product Collection tests (#47211) 2024-05-08 11:26:52 +02:00
Niels Lange 99bed6d7ba
Display price in place order button (#47083)
* WIP: Display price in place order button

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

* Fix JS lint error

* Update e2e tests

* Display default place order button including placeholder in page editor

* Update plugins/woocommerce-blocks/assets/js/blocks/checkout/inner-blocks/checkout-actions-block/constants.tsx

Co-authored-by: Seghir Nadir <nadir.seghir@gmail.com>

* Optimise i18n using sprintf

* Wrap cart totals in “useSelect”

* Temporary skip failing e2e test

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Seghir Nadir <nadir.seghir@gmail.com>
2024-05-08 16:18:48 +07:00
Bart Kalisz c464afc7ad
Blocks E2E: Remove discouraged waitForTimeout from tests (#47214) 2024-05-08 10:14:24 +02:00
Bart Kalisz 2936c4eac8
Blocks E2E: Fix flaky block insertion tests (#47213) 2024-05-08 10:13:30 +02:00
Luigi Teschio 2296e45d33
CYS - Core: Invert the color of the button block inside the cover block when the active style variation is New - Neutral (#47220)
* CYS - Core: fix cover button

* fix type

* fix build

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

* update color in the homepage preview

* move comment

* fix switch style variation

* add comment

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-08 09:36:45 +02:00
Alba Rincón 7a7b513771
[CYS] Fix the triggered event when starting the "no AI" flow (#47181)
* Fix event when starting the no AI flow

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-08 08:52:33 +02:00
Niels Lange b6d9b3a013
Fix broken checkout address forms layout (#47131)
* Fix broken checkout address forms layout

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-08 10:30:12 +07:00
Scott 94ed6a943f
Fix coupon usage limits on failed trashed orders (#47125)
This addresses coupon usage limits for failed & trashed orders by ensuring that coupon usage is decremented when a transaction fails or an order is trashed.

Fixes #31245

* Added tests to check coupon usage count on failed & trashed orders

Signed-off-by: Scott Fleming <scott@noblwheels.com>

* Add filter woocommerce_update_coupon_usage_invalid_statuses, wc_update_coupon_usage_counts actions -> failed/trashed

Signed-off-by: Scott Fleming <scott@noblwheels.com>

* document woocommerce_update_coupon_usage_invalid_statuses filter

Signed-off-by: Scott Fleming <scott@noblwheels.com>

* formatting

Signed-off-by: Scott Fleming <scott@noblwheels.com>

* Add changelog file

Signed-off-by: Scott Fleming <scott@noblwheels.com>

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

Appease the code style linter

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

Appease the code style linter

---------

Signed-off-by: Scott Fleming <scott@noblwheels.com>
Co-authored-by: Corey McKrill <916023+coreymckrill@users.noreply.github.com>
2024-05-07 10:45:38 -07:00
Ron Rennick 15f087da06
Update community PR assignment list for vortex (#47225)
Co-authored-by: Ron Rennick <ronald.rennick@automattic.com>
2024-05-07 10:16:37 -07:00
Justin Palmer f401a98301
Stamp the order attribution HTML element (only once) on a wider set of checkout form actions (#46834)
* Inject the fields (only once) on a large set of checkout form actions

* Changelog

* Better doc format

* Add _once to the new method to clarify functionality

* Filter to modify the default list of actions
2024-05-07 15:54:32 +02:00
Maikel Perez 40486a0151
Remove duplicate code lines in css (#47122)
* Remove duplicate css code from any woo scss file

* Add changelog files
2024-05-07 08:35:25 -04:00
Jonathan Lane 1671523cc0
Remove upload plugin test from Slack reporting on daily (#47067)
Co-authored-by: Jon Lane <jon.lane@automattic.com>
2024-05-07 14:40:12 +03:00
Tom Cafferkey f040e3acf7
Customer Account: Don't hook block unless filter is available. (#47171)
* Check WP version before adding Customer Account hooked block due to usage of hooked_block_{} filter

* Changelog

* Replace global  with get_bloginfo('version') for getting WP version
2024-05-07 09:46:22 +01:00
Ilyas Foo 82795a220b
Remove `noindex` meta from coming soon pages (#47178)
* Remove noindex robot call for coming soon page

* Changelog
2024-05-07 10:01:45 +08:00
Chi-Hsuan Huang e8af1c2ce4
Display `Import Product` task item text and header copies when merchant indicates they are already selling (#47164)
* Update product task header texts

* Update product task item item text

* Add changelog
2024-05-07 09:28:48 +08:00
Maikel Perez b7e30ea5b3
Prevent non used blocks to be registered in the product editor page (#47066)
* Create a hook to filter the woocommerce blocks that can be registered.
This will decrease the server execution time, the amount of css and javascript downloaded.
In the case of the product editor the woocommerce blocks are non needed or required, so it's not necesary to register them all.

* Add changelog file

* Fix php linter errors
2024-05-06 14:29:26 -04:00
kkmuffme 6c3ace8a5d
Logging: prevent file logger from writing only an empty line to a file (#47091)
* Fix https://github.com/woocommerce/woocommerce/issues/47090

* Update plugins/woocommerce/src/Internal/Admin/Logging/FileV2/File.php

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

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

* Update plugins/woocommerce/src/Internal/Admin/Logging/FileV2/File.php

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

---------

Co-authored-by: Corey McKrill <916023+coreymckrill@users.noreply.github.com>
2024-05-06 10:25:43 -07:00
Kathy dd6295bdb6
Catch NotFoundException before `woocommerce_get_batch_processor` (#46975)
* use container's has() method instead of try/catch block to define processor instance.

* Add changelog file

---------

Co-authored-by: Néstor Soriano <konamiman@konamiman.com>
2024-05-07 00:09:06 +07:00
Maikel Perez 5916bacebd
Tax reports not showing correct totals (#46248)
* Get the tax_rate from the woocommerce_order_itemmeta table and country, state and priority from woocommerce_order_items

* Add changelog file

* Fix the resulting items when searching by specific tax rates

* Add some comments to clarify the fix

* Fix php linter errors

* Show modified tax rates and tax names as well as the deleted ones to better show the total calculations

* Fix php tests

* fix Lint issue

* update tests

* Fix some tests

* Add teardown

* Remove tests that were not relevant anymore

* Update teardown function

* Fix linter errors

* Update comment typos

Co-authored-by: Matt Sherman <matt.sherman@automattic.com>

---------

Co-authored-by: Damián Suárez <rdsuarez@gmail.com>
Co-authored-by: Lourens Schep <lourensschep@gmail.com>
Co-authored-by: Matt Sherman <matt.sherman@automattic.com>
2024-05-06 12:44:37 -04:00
Albert Juhé Lluveras 249f83ab8b
Replace div element with main in block templates (#47119)
* Replace div element with main in block templates

* Add changelog file
2024-05-06 16:14:16 +02:00
github-actions[bot] 8005781387
Delete changelog files based on PR 47005 (#47177)
Delete changelog files for 47005

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-05-06 13:26:48 +02:00
Albert Juhé Lluveras f2bb11ffc3
Update block templates documentation (#47110)
* Update block templates documentation

* Add changelog file

* Linting

* Replace 'the' with 'a' to improve understandability
2024-05-06 11:06:40 +02:00
Sam Seay a8be4f3330
Checkout: fix a bug where the local pickup / shipping buttons are rendered incorrectly in the editor (#47157) 2024-05-06 20:57:52 +12:00
Luigi Teschio 2d87573a76
Product Reviews: not use useBlockProps twice (#47136)
* Product Reviews: not use useBlockProps twice

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-06 10:13:53 +02:00
Ilyas Foo 067879263e
Fix GLA site verification with coming soon mode (#47140)
* Set homepage to return 200, add robots hook to ensure no indexing on coming soon pages

* Changelog

* Remove use of 503 status for coming soon
2024-05-06 12:09:32 +08:00
ianlv 6ff0463f24
chore: remove repetitive words (#47158)
* chore: remove repetitive words

Signed-off-by: ianlv <sunlvyun@outlook.com>

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

---------

Signed-off-by: ianlv <sunlvyun@outlook.com>
Co-authored-by: github-actions <github-actions@github.com>
2024-05-06 03:43:39 +00:00
79mplus Admin d2e94e9da6
Add manual_update parameter to v3/orders/<id> endpoint (#46900)
* added a new parameter manual_update when updating order through WC REST API

* added the new parameter to the item schema

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

* Update unit test

---------

Co-authored-by: Corey McKrill <916023+coreymckrill@users.noreply.github.com>
2024-05-03 17:35:29 -07:00
Corey McKrill 78a21956bb
REST API: Add standalone wc/v3/refunds endpoint (#46895)
* REST API: Add endpoint to get refunds directly

This makes it possible to request a list of refunds that are untethered
from their associated orders, with options to specify a date range
and/or a sort order.

Fixes #27568

* Add changelog file

* phpcs cleanup

* Add unit test

* More phpcs cleanup

* Add parent_id to response object

* Appease phpcs
2024-05-03 16:26:04 -07:00
Nathan Silveira 08508dfecc
Add 'placeholder' attribute to taxonomy block and add 'placeholder' a… (#46938)
* Add 'placeholder' attribute to taxonomy block and add 'placeholder' attribute to category field in Simple Product Template

* Only show placeholder when nothing is selected

* Remove suffix from function parameters

* Add changelog for component

* fix unit tests
2024-05-03 15:26:08 -03:00
Albert Juhé Lluveras 2adde79286
Update the version number of some methods in AbstractTemplateCompatibility (#47118)
* Update the version number of some methods in AbstractTemplateCompatibility

* Add changelog file
2024-05-03 13:14:18 +02:00
Luigi Teschio 420207a1d7
Migrate Jest Puppeteer E2E tests to Playwright (#46671)
* try db reset in page teardown

* move reset to setup step

* Use wp db cli

* Fix global setup
That part is overriding the logged in user state and wipes out the nonce and rootUrl fields.

* Try importing instead from a generated dump

* Revert "Try importing instead from a generated dump"

This reverts commit 987dc471c9.

* Revert "Revert "Try importing instead from a generated dump""

This reverts commit c8d008cb20.

* Don't bypass visitSiteEditor so that the Welcome Guide is closed

* use createNewPost

* Revert "Revert "Revert "Try importing instead from a generated dump"""

This reverts commit 2684273582.

* [Blocks]: Fix E2E tests (#46344)

* Load local pickup enabled setting as bool not string

* Add changelog

* Remove unused import

* Update plugins/woocommerce-blocks/assets/js/extensions/shipping-methods/pickup-location/utils.ts

Co-authored-by: Niels Lange <info@nielslange.de>

* Use strict equality test

* try now

* try now

* add a new sql file

* remove default.sql

* fix welcome guide tour

* fix E2E tests

* Fix the template revert tests
...where the template is unreachable due to pagination.

* Add changelog entry

* improve logic to closeWelcomeGuideModal

* fix cart checkout tests

* improve flakiness

* improve flakiness

* fix flaky test

* fix company field

* fix E2E test

* fix E2E tests

---------

Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Niels Lange <info@nielslange.de>
Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>

* Replace beforeAll w/ beforeEach + remove all after* hooks

* Fix broken hooks

* Activate plugins via requestUtils API

* [Blocks - E2E]: Add `playwright/no-hooks` ESlint rule (#46432)

add ESLint configuration

* Clean up console logs

* Remove obsolete language setup steps

* Remove more unnecessary setup steps

* Remove even more obsolete setup steps

* tmp: add the LYS fix

* Try stabilizing the company field test

* Use canvas param instead of manually entering edit mode

* Remove double site editor redirect

* Revert "Use canvas param instead of manually entering edit mode"

This reverts commit 5e6cc17154.

* Revert "Remove double site editor redirect"

This reverts commit 69a57a82a8.

* Fix flaky products sorting test

* Blocks: Fix ESLint errors (#46595)

fix eslint error

* Fix ESLint errors (#46626)

* Fix ESLint errors

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

---------

Co-authored-by: github-actions <github-actions@github.com>

* Blocks: Migrate multiple tests to Playwright

* fix path

* migrate other tests

* add product best sellers E2E tests

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

* migrate jest-puppetter E2E tests to Playwright

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

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

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

* Remove obsolete waitForLoadState call

* improve E2E tests

* fix E2E tests

* improve E2E tests

* remove old test

* remove not necessary test

* fix number product

* fix E2E test

* fix number of products

* fix product count

* refactor store notice E2E tests

* update string

* fix E2E test

* fix E2E tests

---------

Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>
Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Niels Lange <info@nielslange.de>
Co-authored-by: github-actions <github-actions@github.com>
2024-05-03 13:02:37 +02:00
Vishnu Gopal d81f49a046
Fix plugin registration on woocommerce.com for active plugins (#46780) 2024-05-03 17:43:39 +07:00
Albert Juhé Lluveras b0ab7ba213
Fix Merchant → Mini Cart in FSE editor can only be inserted once test (#47134)
* Fix Merchant → Mini Cart in FSE editor can only be inserted once test

* Add changelog file
2024-05-03 11:58:53 +02:00
Luigi Teschio e750b0ff3a
Product Details: not use `useBlockProps` twice (#46785)
* Product Details: not use  twice

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-03 10:21:06 +02:00
Sam Seay 3a5721c0d8
Replace @wordpress/components Button, Radio, RadioGroup with Ariakit Button (#45974) 2024-05-03 15:28:39 +12:00
Ilyas Foo 24348366b4
Fix missing shipping recommendation task (#47117)
* Add secret tasklist to exception for hidden list in tasklist API

* Changelog

* Lint
2024-05-03 11:06:33 +08:00
Khokan Sardar 51c629dee4
Fix extra /wp-admin from action url link for ticket 46993 (#47010)
* Fix extra /wp-admin from action url link for ticket 46993

* Fix extra /wp-admin from task LaunchYourStore get action url

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-03 10:46:57 +08:00
Naman Malhotra 1ba1e91a7e
HPOS - Made the query for retrieving meta keys more performant (#46985)
* Modified query for fetching meta key, making it more perfomant

* added changelog

* Improved query when include_private is true

* Address review feedback

* Address review feedback
2024-05-02 16:24:10 +01:00
Niels Lange 6066c082b0
Relocate helper (child) themes (#47080)
* Relocate helper (child) themes

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

* Correct wrong template slugs

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-02 21:23:52 +07:00
nigeljamesstevenson 296c0cfb23
Update to display full woocommerce version on status page rather than a shortened milestone style version (#46906)
* update to display actual woocommerce version on status page

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-02 14:44:21 +01:00
Moon f5d386f093
Remove wc_update_890_add_launch_your_store_tour_option (#47005)
* Remove wc_update_890_add_launch_your_store_tour_option

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-05-02 06:33:32 -07:00
Naman Malhotra 2b4b8be4e6
Improved readability and better UX for GitHub bug reports, by optimizing the format of the SSR (#47088)
* Improved readability and better UX for GitHub bug reports, by optimising the format of the SSR

* Added changelog
2024-05-02 18:26:37 +07:00
Gan Eng Chin 48f479fd67
Rename and sort filter options in "Add a filter" in Analytics (#46955)
* Rename filter options in Orders Analytics.

* Sort filter options in labels in Orders Analytics.

* Change filter labels to singular.

* Wider label column to accommodate label change.

* Rename filter options in Variations Analytics.

* Change filter options to Attribute, Category and Product in Variations Analytics.

* Revert "Change filter options to Attribute, Category and Product in Variations Analytics."

This reverts commit b3ca5d5807.

* Change "Add a Filter" to "Add a filter".

* Add changelog.

* Add changelog.

* Refactor getAvailableFilterKeys and getAvailableFilters into one function.

* Add code comment and remove unneeded code.

* Code refactor getAvailableFilters.

This is done by starting from allFilterKeys, and filtering with allowMultiple or not yet active.

With this, we don't need to have `inactiveFilterKeys` and "Ensure filters that allow multiples are always present."

* Fix tests and lint issues.

* Simplify code with Object.entries.
2024-05-02 18:34:17 +08:00
Chi-Hsuan Huang 36b3712860
[Launch Your Store] Remove "Powered by WooCommerce" footer (#47075)
* Remove unnecessary powered by WooCommerce link

* Add changelog
2024-05-02 16:52:06 +08:00
Luigi Teschio bbcc73ebeb
Migrate Jest Puppeteer E2E tests to Playwright (#46644)
* try db reset in page teardown

* move reset to setup step

* Use wp db cli

* Fix global setup
That part is overriding the logged in user state and wipes out the nonce and rootUrl fields.

* Try importing instead from a generated dump

* Revert "Try importing instead from a generated dump"

This reverts commit 987dc471c9.

* Revert "Revert "Try importing instead from a generated dump""

This reverts commit c8d008cb20.

* Don't bypass visitSiteEditor so that the Welcome Guide is closed

* use createNewPost

* Revert "Revert "Revert "Try importing instead from a generated dump"""

This reverts commit 2684273582.

* [Blocks]: Fix E2E tests (#46344)

* Load local pickup enabled setting as bool not string

* Add changelog

* Remove unused import

* Update plugins/woocommerce-blocks/assets/js/extensions/shipping-methods/pickup-location/utils.ts

Co-authored-by: Niels Lange <info@nielslange.de>

* Use strict equality test

* try now

* try now

* add a new sql file

* remove default.sql

* fix welcome guide tour

* fix E2E tests

* Fix the template revert tests
...where the template is unreachable due to pagination.

* Add changelog entry

* improve logic to closeWelcomeGuideModal

* fix cart checkout tests

* improve flakiness

* improve flakiness

* fix flaky test

* fix company field

* fix E2E test

* fix E2E tests

---------

Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Niels Lange <info@nielslange.de>
Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>

* Replace beforeAll w/ beforeEach + remove all after* hooks

* Fix broken hooks

* Activate plugins via requestUtils API

* [Blocks - E2E]: Add `playwright/no-hooks` ESlint rule (#46432)

add ESLint configuration

* Clean up console logs

* Remove obsolete language setup steps

* Remove more unnecessary setup steps

* Remove even more obsolete setup steps

* tmp: add the LYS fix

* Try stabilizing the company field test

* Use canvas param instead of manually entering edit mode

* Remove double site editor redirect

* Revert "Use canvas param instead of manually entering edit mode"

This reverts commit 5e6cc17154.

* Revert "Remove double site editor redirect"

This reverts commit 69a57a82a8.

* Fix flaky products sorting test

* Blocks: Fix ESLint errors (#46595)

fix eslint error

* Fix ESLint errors (#46626)

* Fix ESLint errors

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

---------

Co-authored-by: github-actions <github-actions@github.com>

* Blocks: Migrate multiple tests to Playwright

* fix path

* migrate other tests

* add product best sellers E2E tests

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

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

* Remove obsolete waitForLoadState call

* improve E2E tests

* fix E2E tests

* fix E2E test

* remove not necessary changelog

* improve E2E tests

* remove not necessary folder

* fix test

---------

Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>
Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Niels Lange <info@nielslange.de>
Co-authored-by: github-actions <github-actions@github.com>
2024-05-02 10:36:51 +02:00
Chi-Hsuan Huang 75bb52c310
Fix core profiler email field overlapping with continue button in mobile screen (#47077)
* Fix core profiler email field is not positioned correctly in mobile screens

* Add changelog
2024-05-02 16:09:58 +08:00
Chi-Hsuan Huang 1e2133e78c
[Launch Your Store] Fix failed to load coming-soon resources (#47073)
* Fix failed to load coming soon css/js

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

* Update plugins/woocommerce/src/Blocks/BlockTypes/ComingSoon.php

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

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>
2024-05-02 14:41:36 +08:00
Adrian Moldovan de91a0881d
[ci-jobs] Add support for github event and include HPOS disabled e2e tests in ci (#46922)
* Update env setup script to disable hpos

* Use DISABLE_HPOS instead of ENABLE_HPOS

* Log HPOS state

* Configure project for core e2e with HPOS disabled

* Add event argument for ci-jobs util

* Add event option for test jobs

* Add support for github events

* Add changelog

* Configure HPOS tests to run on pull_request

* Fix utils tests for undefined commandVars

* Added some tests for the event configuration

* Revert event for HPOS e2e to push

* Use matrix name in artifact name to avoid duplication

* Test with pull_request event

* Use job-index for unique artifacts names

* Revert event for HPOS e2e to push

* Add api tests for HPOS disabled

* Use unique artifact name for api tests

* Revert event for HPOS disabled api tests to push

* Rebuild monorepo utils to fix a merge conflict

* Updated wording
2024-05-01 10:36:24 -07:00
github-actions[bot] 8aed7ccecf
Delete changelog files based on PR 46935 (#47082)
Delete changelog files for 46935

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-05-01 11:19:39 +01:00
Vedanshu Jain 302da40214
Add index on SKU filed in wc_product_meta_lookup table. (#47051) 2024-05-01 11:18:46 +01:00
Moon 95a32efb2a
Return with home URL when permalink structure is empty (#46664)
* Return with home URL when permalink structure is empty

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

* Always includes home url

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-30 08:41:15 -07:00
Niels Lange 1d93ba0b6a
Block-based checkout - Shipping section changes (#46083)
* Refactor shipping sections

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

* Refactor various files and adjust e2e tests

* Display expected styles for “Ship” and “Pickup” in the page editor

* Use exact selector

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-30 19:59:03 +07:00
Ilyas Foo 35c50ebdb4
Try wrapping entire coming soon page under cover block to fix layout issue (#46914)
* Refactor to wrap everything under cover block

* Changelog

* Cleanup and fix classic theme

* Wrap center with stack for ease of adding elements nearby

* Update styles

* Fix dynamic background color

* Style clean up
2024-04-30 16:56:59 +08:00
Chi-Hsuan Huang fbef56fb4d
Add filter to convert WooCommerce slug for plugin dependencies (#46707)
* Add filter to convert WooCommerce slug for plugin dependencies

* Add changelog

* Add @since tag
2024-04-30 01:46:03 +00:00
Alexis Urien 3451c51cbf
Remove unused code introduced in 2014 but that looks never been used (#46843)
* Remove unused code introduced in 2014 but that has never been used

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

---------

Co-authored-by: Alexis Urien <alexis@smiile.com>
Co-authored-by: github-actions <github-actions@github.com>
2024-04-29 19:55:29 +01:00
Adrian Moldovan e36baab4fe
[e2e tests] Disable woocommerce_coming_soon during test environment setup (#47024)
* Disable woocommerce_coming_soon in test env setup

* Disable woocommerce_coming_soon in test env setup

* Add changelog
2024-04-29 10:27:18 -07:00
Adrian Moldovan 9ff383e703
[e2e tests] Don't exit if the consumer token is not cleared in teardown (#47020)
* Assert for consumer token being cleared, but don't exit

* Add changelog
2024-04-29 10:24:29 -07:00
Álvaro Thomas 15c3135720
Update stable tag to 8.8.3 (#47033)
woorelease: Update stable tag to 8.8.3
2024-04-29 18:04:01 +02:00
Néstor Soriano fbb39807ac
Prevent product from being saved prematurely when updated via REST API (#46674)
* Prevent product being saved prematurely when updated via REST API

This includes the wc_product_attach_featured_image function
getting a new argument, $save_product, defaulting to true.

* Add changelog file
2024-04-29 13:54:54 +01:00
github-actions[bot] 664147a216
Delete changelog files based on PR 46972 (#47017)
Delete changelog files for 46972

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-04-29 13:56:17 +02:00
Patricia Hillebrandt 30054a25c0
CYS > Ensure get_patterns_ai_data_post is triggered only if AI enabled and improve performance (#46999)
* Ensure the get_patterns_ai_data_post method is triggered exclusively whenever AI is enabled. Udate the get_patterns_ai_data_post method to rely on get_posts instead of new WP_Query for fetching the results. Enable autoload for the 'woocommerce_blocks_allow_ai_connection' option to improve performance, since it is invoked in pretty much all page loads.

* Enable autoload for the 'woocommerce_blocks_allow_ai_connection' option to improve performance, since it is invoked in pretty much all page loads.

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

* address lint error.

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-29 13:29:15 +02:00
Michael Pretty 1725ed2075
Use delete query format suppored by wpdb::get_table_from_query() in Abstract_WC_Order_Data_Store_CPT::delete_items() (#46692)
* Use delete query format suppored by wpdb::get_table_from_query() in Abstract_WC_Order_Data_Store_CPT::delete_items()

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

* Add unit test for deleting orders.

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Vedanshu Jain <vedanshu.jain.2012@gmail.com>
2024-04-29 10:08:30 +00:00
Jorge A. Torres 9becfc8c46
Do not urldecode search terms in HPOS searches (#46972)
* Fix HPOS searches involving terms similar to URL-encoded characters

* Make sure search filters are non null
2024-04-29 11:32:53 +02:00
Sam Seay 05f14d9465
Fix incorrectly used aria-describedby in add to cart button of variable product (#46897) 2024-04-29 21:31:34 +12:00
Alba Rincón 79c5359a49
[CYS] Fix error when repeating the prompt on consecutives runs (#46872)
* Fix error when the repeating the prompt

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-29 10:24:48 +02:00
Sam Seay 75b7775e1b
Update Webpack in blocks to latest version (#46711) 2024-04-29 15:50:47 +12:00
Sam Seay 1e225f701f
Add aria label to the customer account block link (#46899) 2024-04-29 13:35:47 +12:00
dependabot[bot] f9a7ff04f0
Bump fast-xml-parser from 4.2.4 to 4.2.5 (#41982)
* Bump fast-xml-parser from 4.2.4 to 4.2.5

Bumps [fast-xml-parser](https://github.com/NaturalIntelligence/fast-xml-parser) from 4.2.4 to 4.2.5.
- [Release notes](https://github.com/NaturalIntelligence/fast-xml-parser/releases)
- [Changelog](https://github.com/NaturalIntelligence/fast-xml-parser/blob/master/CHANGELOG.md)
- [Commits](https://github.com/NaturalIntelligence/fast-xml-parser/compare/v4.2.4...v4.2.5)

---
updated-dependencies:
- dependency-name: fast-xml-parser
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>

* Add changelog

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Jon Lane <jon.lane@automattic.com>
2024-04-26 15:25:30 -07:00
Adrian Moldovan fb9613e92c
[e2e tests] Fix the cleanup of created test pages and move to fixtures (#46944)
* Added testPage fixture and testPgeTitle fixture option

* Update create-cart-block.spec.js to use testPage fixture

* Add changelog

* Update create-checkout-block.spec.js to use testPage fixture

* Update create-page.spec.js to use testPage fixture

* Update create-woocommerce-blocks.spec.js to use testPage fixture

* Update create-woocommerce-patterns.spec.js to use testPage fixture

* Update cart-block.spec.js to use testPage fixture

* Update cart-block-calculate-shipping.spec.js to use testPage fixture

* Update cart-block-coupons.spec.js to use testPage fixture

* Update checkout.spec.js to use some utils

* Update checkout-block-coupons.spec.js to use testPage fixture

* Use cart utils in checkout-create-account.spec.js

* Use cart utils in checkout-login.spec.js

* Use cart utils in order-email-receiving.spec.js

* Update shop-products-filter-by-price.spec.js to use testPage fixture

* Add helpers.js

* Move the page title random name generator in the base fixture to ensure uniqueness

* Remove eslint exceptions

* Use api fixture
2024-04-26 14:50:35 -07:00
Vedanshu Jain 94e438f524
Add experimental support for FTS indexes in HPOS. (#46130)
* Added key for sku

* Add experimental support for FTS indexes in HPOS. Additionally, revert existing HPOS search queries to use post like structure.

* Add unit tests

* Escape the error messages as per new phpcs rules.

* Fix query with index + added test.

* remove uninteded change.

* Unit test fixes.

* Remove unit test since the commit command breaks other tests.

Use message API instead of notices with defensive checks.
2024-04-26 17:25:03 +01:00
dependabot[bot] 3d8e20c62c
Bump octokit from 2.1.0 to 3.1.2 (#42891)
* Bump octokit from 2.1.0 to 3.1.2

Bumps [octokit](https://github.com/octokit/octokit.js) from 2.1.0 to 3.1.2.
- [Release notes](https://github.com/octokit/octokit.js/releases)
- [Commits](https://github.com/octokit/octokit.js/compare/v2.1.0...v3.1.2)

---
updated-dependencies:
- dependency-name: octokit
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

* Rename env variable

* Add changelog

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Jon Lane <jon.lane@automattic.com>
2024-04-26 10:52:25 -03:00
Luigi Teschio ded320df95
[Blocks] Migrate stock filter to playwright (#46580)
* try db reset in page teardown

* move reset to setup step

* Use wp db cli

* Fix global setup
That part is overriding the logged in user state and wipes out the nonce and rootUrl fields.

* Try importing instead from a generated dump

* Revert "Try importing instead from a generated dump"

This reverts commit 987dc471c9.

* Revert "Revert "Try importing instead from a generated dump""

This reverts commit c8d008cb20.

* Don't bypass visitSiteEditor so that the Welcome Guide is closed

* use createNewPost

* Revert "Revert "Revert "Try importing instead from a generated dump"""

This reverts commit 2684273582.

* [Blocks]: Fix E2E tests (#46344)

* Load local pickup enabled setting as bool not string

* Add changelog

* Remove unused import

* Update plugins/woocommerce-blocks/assets/js/extensions/shipping-methods/pickup-location/utils.ts

Co-authored-by: Niels Lange <info@nielslange.de>

* Use strict equality test

* try now

* try now

* add a new sql file

* remove default.sql

* fix welcome guide tour

* fix E2E tests

* Fix the template revert tests
...where the template is unreachable due to pagination.

* Add changelog entry

* improve logic to closeWelcomeGuideModal

* fix cart checkout tests

* improve flakiness

* improve flakiness

* fix flaky test

* fix company field

* fix E2E test

* fix E2E tests

---------

Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Niels Lange <info@nielslange.de>
Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>

* Replace beforeAll w/ beforeEach + remove all after* hooks

* Fix broken hooks

* Activate plugins via requestUtils API

* [Blocks - E2E]: Add `playwright/no-hooks` ESlint rule (#46432)

add ESLint configuration

* Clean up console logs

* Remove obsolete language setup steps

* Remove more unnecessary setup steps

* Remove even more obsolete setup steps

* tmp: add the LYS fix

* Try stabilizing the company field test

* Use canvas param instead of manually entering edit mode

* Blocks: Migrate stock filter to playwright

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

* Remove double site editor redirect

* remove not necessary file

* fix test

* Revert "Use canvas param instead of manually entering edit mode"

This reverts commit 5e6cc17154.

* Revert "Remove double site editor redirect"

This reverts commit 69a57a82a8.

* Fix flaky products sorting test

* Blocks: Fix ESLint errors (#46595)

fix eslint error

* improve E2E tests

* fix test

* Fix ESLint errors (#46626)

* Fix ESLint errors

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

---------

Co-authored-by: github-actions <github-actions@github.com>

* address feedback

---------

Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>
Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Niels Lange <info@nielslange.de>
Co-authored-by: github-actions <github-actions@github.com>
2024-04-26 15:14:54 +02:00
Luigi Teschio 45a4817772
[Blocks] Migrate Attribute filter E2E tests to playwright (#46591)
* try db reset in page teardown

* move reset to setup step

* Use wp db cli

* Fix global setup
That part is overriding the logged in user state and wipes out the nonce and rootUrl fields.

* Try importing instead from a generated dump

* Revert "Try importing instead from a generated dump"

This reverts commit 987dc471c9.

* Revert "Revert "Try importing instead from a generated dump""

This reverts commit c8d008cb20.

* Don't bypass visitSiteEditor so that the Welcome Guide is closed

* use createNewPost

* Revert "Revert "Revert "Try importing instead from a generated dump"""

This reverts commit 2684273582.

* [Blocks]: Fix E2E tests (#46344)

* Load local pickup enabled setting as bool not string

* Add changelog

* Remove unused import

* Update plugins/woocommerce-blocks/assets/js/extensions/shipping-methods/pickup-location/utils.ts

Co-authored-by: Niels Lange <info@nielslange.de>

* Use strict equality test

* try now

* try now

* add a new sql file

* remove default.sql

* fix welcome guide tour

* fix E2E tests

* Fix the template revert tests
...where the template is unreachable due to pagination.

* Add changelog entry

* improve logic to closeWelcomeGuideModal

* fix cart checkout tests

* improve flakiness

* improve flakiness

* fix flaky test

* fix company field

* fix E2E test

* fix E2E tests

---------

Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Niels Lange <info@nielslange.de>
Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>

* Replace beforeAll w/ beforeEach + remove all after* hooks

* Fix broken hooks

* Activate plugins via requestUtils API

* [Blocks - E2E]: Add `playwright/no-hooks` ESlint rule (#46432)

add ESLint configuration

* Clean up console logs

* Remove obsolete language setup steps

* Remove more unnecessary setup steps

* Remove even more obsolete setup steps

* tmp: add the LYS fix

* Try stabilizing the company field test

* Use canvas param instead of manually entering edit mode

* Remove double site editor redirect

* Blocks: Migrate attribute filter E2E tests to playwright

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

* Revert "Use canvas param instead of manually entering edit mode"

This reverts commit 5e6cc17154.

* Revert "Remove double site editor redirect"

This reverts commit 69a57a82a8.

* Fix flaky products sorting test

* Blocks: Fix ESLint errors (#46595)

fix eslint error

* update path

* Fix ESLint errors (#46626)

* Fix ESLint errors

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

---------

Co-authored-by: github-actions <github-actions@github.com>

* address feedback

* fix visitSiteEditor

* fix description

* remove not necessary changelog

---------

Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>
Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Niels Lange <info@nielslange.de>
Co-authored-by: github-actions <github-actions@github.com>
2024-04-26 14:35:03 +02:00
Luigi Teschio 24c2832e4f
[Blocks] Migrate rating filter to playwright (#46583)
* try db reset in page teardown

* move reset to setup step

* Use wp db cli

* Fix global setup
That part is overriding the logged in user state and wipes out the nonce and rootUrl fields.

* Try importing instead from a generated dump

* Revert "Try importing instead from a generated dump"

This reverts commit 987dc471c9.

* Revert "Revert "Try importing instead from a generated dump""

This reverts commit c8d008cb20.

* Don't bypass visitSiteEditor so that the Welcome Guide is closed

* use createNewPost

* Revert "Revert "Revert "Try importing instead from a generated dump"""

This reverts commit 2684273582.

* [Blocks]: Fix E2E tests (#46344)

* Load local pickup enabled setting as bool not string

* Add changelog

* Remove unused import

* Update plugins/woocommerce-blocks/assets/js/extensions/shipping-methods/pickup-location/utils.ts

Co-authored-by: Niels Lange <info@nielslange.de>

* Use strict equality test

* try now

* try now

* add a new sql file

* remove default.sql

* fix welcome guide tour

* fix E2E tests

* Fix the template revert tests
...where the template is unreachable due to pagination.

* Add changelog entry

* improve logic to closeWelcomeGuideModal

* fix cart checkout tests

* improve flakiness

* improve flakiness

* fix flaky test

* fix company field

* fix E2E test

* fix E2E tests

---------

Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Niels Lange <info@nielslange.de>
Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>

* Replace beforeAll w/ beforeEach + remove all after* hooks

* Fix broken hooks

* Activate plugins via requestUtils API

* [Blocks - E2E]: Add `playwright/no-hooks` ESlint rule (#46432)

add ESLint configuration

* Clean up console logs

* Remove obsolete language setup steps

* Remove more unnecessary setup steps

* Remove even more obsolete setup steps

* tmp: add the LYS fix

* Try stabilizing the company field test

* Use canvas param instead of manually entering edit mode

* Remove double site editor redirect

* Blocks: Migrate rating filter to playwright

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

* remove not necessary changelog

* Revert "Use canvas param instead of manually entering edit mode"

This reverts commit 5e6cc17154.

* Revert "Remove double site editor redirect"

This reverts commit 69a57a82a8.

* Fix flaky products sorting test

* Blocks: Fix ESLint errors (#46595)

fix eslint error

* improve tests

* use visitSiteEditor util

Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>

* use locator.fill

* Fix ESLint errors (#46626)

* Fix ESLint errors

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

---------

Co-authored-by: github-actions <github-actions@github.com>

* address feedback

* remove not necessary changelog

---------

Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>
Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Niels Lange <info@nielslange.de>
Co-authored-by: github-actions <github-actions@github.com>
2024-04-26 12:53:07 +02:00
Luigi Teschio 417baee8ef
[Blocks] Migrate Price filter tests to Playwright (#46576)
* try db reset in page teardown

* move reset to setup step

* Use wp db cli

* Fix global setup
That part is overriding the logged in user state and wipes out the nonce and rootUrl fields.

* Try importing instead from a generated dump

* Revert "Try importing instead from a generated dump"

This reverts commit 987dc471c9.

* Revert "Revert "Try importing instead from a generated dump""

This reverts commit c8d008cb20.

* Don't bypass visitSiteEditor so that the Welcome Guide is closed

* use createNewPost

* Revert "Revert "Revert "Try importing instead from a generated dump"""

This reverts commit 2684273582.

* [Blocks]: Fix E2E tests (#46344)

* Load local pickup enabled setting as bool not string

* Add changelog

* Remove unused import

* Update plugins/woocommerce-blocks/assets/js/extensions/shipping-methods/pickup-location/utils.ts

Co-authored-by: Niels Lange <info@nielslange.de>

* Use strict equality test

* try now

* try now

* add a new sql file

* remove default.sql

* fix welcome guide tour

* fix E2E tests

* Fix the template revert tests
...where the template is unreachable due to pagination.

* Add changelog entry

* improve logic to closeWelcomeGuideModal

* fix cart checkout tests

* improve flakiness

* improve flakiness

* fix flaky test

* fix company field

* fix E2E test

* fix E2E tests

---------

Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Niels Lange <info@nielslange.de>
Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>

* Replace beforeAll w/ beforeEach + remove all after* hooks

* Fix broken hooks

* Activate plugins via requestUtils API

* [Blocks - E2E]: Add `playwright/no-hooks` ESlint rule (#46432)

add ESLint configuration

* Clean up console logs

* Remove obsolete language setup steps

* Remove more unnecessary setup steps

* Remove even more obsolete setup steps

* tmp: add the LYS fix

* [Blocks]: Migrate Price Filter tests to Playwright

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

* improve description

* Try stabilizing the company field test

* use Product Collection

* Use canvas param instead of manually entering edit mode

* remove blockData

* Remove double site editor redirect

* Revert "Use canvas param instead of manually entering edit mode"

This reverts commit 5e6cc17154.

* Revert "Remove double site editor redirect"

This reverts commit 69a57a82a8.

* Fix flaky products sorting test

* Blocks: Fix ESLint errors (#46595)

fix eslint error

* update test

* add missing import

* Fix ESLint errors (#46626)

* Fix ESLint errors

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

---------

Co-authored-by: github-actions <github-actions@github.com>

* improve E2E tests

* remove not necessary changelog

---------

Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>
Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Niels Lange <info@nielslange.de>
Co-authored-by: github-actions <github-actions@github.com>
2024-04-26 12:07:00 +02:00
Bart Kalisz 5f7cc39330
Block E2E: Eliminate side effects through improved test isolation (#46125) 2024-04-26 11:39:11 +02:00
Corey McKrill 42902ef96d
Logging: Ensure the woocommerce_format_log_entry filter hook still has access to the log source value (#46851)
* Logging: keep full context in woocommerce_format_log_entry filter hook

The source value gets removed from the context array before it is
converted to JSON and output as part of the log entry. However, this
means that the source value is not available when the
woocommerce_format_log_entry filter hook fires, so plugins can't easily
determine where the log entry came from. This simply ensures that the
source value is still available to the filter hook, even though it's not
included in the JSON.
2024-04-26 09:12:50 +02:00
Paul Sealock d5d25d3bfe
[LYS] Comin soon block - Refactor and hide Styles block on Store Only (#46854) 2024-04-26 16:43:08 +12:00
Darren Ethier ed430bdd72
Block Hooks: Revert opening up hooked blocks to all block themes (#46935)
* Revert opening up hooked blocks to all block themes.

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

* Add version to @since tag in fn comment.

Missing @since version throwing a CI check error:

`A "@since" tag was found but no version declared.`

Adding `8.4.0`, as this was the version referenced before the revert.

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Daniel W. Robert <danielwrobert@gmail.com>
2024-04-25 22:33:05 -04:00
Paul Sealock 86eee17c20
[LYS] Convert status chip files to typescript (#46898) 2024-04-26 11:07:56 +12:00
Adrian Moldovan dd8aa94db9
[e2e tests] Fix more e2e tests with Gutenberg active (#46861)
* Add publish page util

* Update create-woocommerce-patterns.spec.js to use canvas

* Update create-woocommerce-blocks.spec.js to use the publishPage util

* Fix check for pattern

* Add changelog

* Update cart-block-calculate-shipping.spec.js to use canvas

* Add utility for adding a product to cart and only waiting for the relevant request instead of networkidle

* Update cart-block-coupons.spec.js to use canvas and new utils

* Update shopper/cart-block.spec.js to use canvas and new utils

* Update shopper/cart-calculate-shipping.spec.js to use new utils

* Update shopper/cart-checkout-block-calculate-tax.spec.js to use canvas and new utils.

* Use uuid instead of Date.now()

* Update shopper/cart-checkout-calculate-tax.spec.js to use new utils

* Suppress testing-library/await-async-utils eslint rule

* Add currency for a more strict text based locator

* Don't wait for networkidle

* Don't wait for networkidle in cart-checkout-restricted-coupons.spec.js

* Don't wait for networkidle in cart-redirection.spec.js

* Fix cart.spec.js

* Fix checkout-block-coupons.spec.js

* Fix checkout-block.spec.js

* Fix shop-products-filter-by-price.spec.js

* Add gutenberg to wp-env config

* Dirty fix for multiple coupons test

* Remove Gutenberg from wp-env
2024-04-25 13:19:21 -07:00
Alexander Minza ac7bcdbab3
Add filter hook wc_product_pre_has_unique_sku (#46763)
Adds the `wc_product_pre_has_unique_sku` filter hook to allow SKU uniqueness to be determined externally in order to avoid an expensive query.

Fixes #46759
Fixes #31720

---------

Co-authored-by: Corey McKrill <916023+coreymckrill@users.noreply.github.com>
2024-04-25 10:41:33 -07:00
github-actions[bot] f7cad9c4be
Prep trunk for 9.0 cycle (#46893)
Prep trunk for 9.0 cycle with version bump to 9.0.0-dev

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-04-25 18:34:18 +02:00
github-actions[bot] 26a9972ebc
Release: Remove 8.9 change files (#46894)
Delete changelog files from 8.9 release

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2024-04-25 18:33:07 +02:00
Jorge A. Torres 7e763e64ec
Add support for 'customer' field to REST orders controller (v2/v3) (#46878)
* Properly handle 'customer' field in REST API when HPOS is active

* Remove code from v3 orders controller that was moved to v2 controller
2024-04-25 16:56:55 +02:00
Vlad Olaru 8a0ed2dd0b
Revert "Upgrade the WooPayments surfaces to the new designs" (#46915)
Revert "Upgrade the WooPayments surfaces to the new designs (#46873)"

This reverts commit 24808a0a8b.
2024-04-25 16:24:05 +03:00
Roy Ho d6a48ecaf5
Add autogeneration of block list reference documentation (#46479)
* Add autogeneration of block list reference documentation

* Fix typo

* Revert this change

* Fix typo

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

* Add blanklines to surrounding markdown headings

* Generate blocks references markdown

* Add space to header markdown

* Add ancestor information

* Use native Object.keys instead of lodash

* Remove the use of fast-glob

* Revert pnpm lock file changes

* Update plugins/woocommerce-blocks/bin/gen-block-list-doc.js

Co-authored-by: Karol Manijak <20098064+kmanijak@users.noreply.github.com>

* Update doc title

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Karol Manijak <20098064+kmanijak@users.noreply.github.com>
2024-04-25 06:03:41 -07:00
Damián Suárez a0aa4724df
Tidy and update product attribute TypeScript types (#46907)
* rename ProductAttribute with ProductProductAttribute

* introduce ProductAttribute to define actions

* update importing attribute types

* fix select item type

* export ProductAttribute TS type

* update attribute-input-field component

* changelog

* update jsdoc block

* update test
2024-04-25 07:30:02 -04:00
RJ 7d07f0c502
revert: feature flag off (#46853)
revert LYS feature flag off for post-8.9
2024-04-25 18:44:14 +10:00
Fernando Marichal cacac06cef
Add help text under "Include downloads" toggle (#46752)
* Add help text under downloads toggle

* Add changelog
2024-04-25 05:30:17 -03:00
Alex Florisca 7dc8dd63ba
Update Order Summary Design (#45767)
* Add border around order summary on cart & checkout

* Group subtotal, discount, fees, taxes and shiping block

* Move the coupon form in order summary

* Move the coupon form in order summary

* Manage state externally in Panel component and refactor Coupon form to use the Panel component

* Remove descriptions from order summary items

* increase font weight of order summary title

* Tidy up design for desktop and add separator back in for blocks on checkout order summary

* Remove border around order summary on mobile

* Revert "Move the coupon form in order summary"

This reverts commit 4a8044cdcf.

* Change heading styles for cart

* Change font weight to 500 of order summary heading on checkout block

* Remove padding and border between order summary totals items

* Refactor css for cart & checkout totals to work in the editor

* Adjust cart totals heading in the editor

* Last adjustment to checkout totals style to work in editor

* Add changelog

* Change the cursor to pointer for the panel component

* remove unused short and full description from OrderSummaryItem

* Fix failing e2e tests

* Fix lint issues

* Vertically align order summary title in the editor

* Fix e2e tests

* Fix linting issues

* Fix unit tests

* Remove changes from woocommerce.php

* Fix checkout block test

* fix eslint errors in checkout block test

---------

Co-authored-by: Niels Lange <info@nielslange.de>
2024-04-25 12:03:31 +07:00
Corey McKrill d8486e579c
Logging: Add more robust method of filesystem initialization to handle configuration edge cases (#45914)
* Add FilesystemUtil class and unit tests

* Update logger to use FilesystemUtil

* phpcs cleanup

* Add changelog file

* Extract credentials gathering into a separate method

* Add notice when filesystem init fails

* Simplify getting filesystem credentials

* Tweak messaging in Settings when filesystem is not direct

* Remove unnecessary conditional in file deletion method

* Refactor test_clear

* Restore test_clear to its previous state

* Prevent MaxMind unit tests from polluting the state of WP_Filesystem
2024-04-24 12:18:31 -07:00
Vlad Olaru 24808a0a8b
Upgrade the WooPayments surfaces to the new designs (#46873)
* Import colors.native scss variables

* Add changelog

* Refactor WCPay banner and cleanup

We introduce a new WCPayConnectCard onboarding component and
remove/cleanup all other WCPay surface components.

This component uses the new design, updated payment methods icons
and WCPay logo.

* Add changelog

* Upgrade the WCPay payments settings banner

* test: Fix WCPay payments settings banner tests

* Update the WCPay welcome page to use the WCPayConnectCard component

* Update the Payments task page to use the WCPayConnectCard component

* Fix copy for payments settings methods CTA buttons label

* Add changelog

* Further cleanup of no-longer-used WCPay surfaces

* Consolidate onboarding component icons for single sources

* Minor cleanup

* test: Fix WCPay payments settings banner test

* test: Fix payments tasks page tests
2024-04-24 21:41:40 +03:00
Seghir Nadir 2054353f91
Add hooks when reading and writing additional fields (#46870)
* add new filters for reading and writing fields

* rename functions

* add test for action

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

* update docs

* fix typo in test and linting issues

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-24 17:38:15 +02:00
Albert Juhé Lluveras 738bbb0078
Move logic to hide Template selector in Shop page into Product Catalog class and add e2e test (#46405)
* Move logic to hide Template selector in Shop page into Product Catalog class

* Add changelog file

* Update plugins/woocommerce-blocks/tests/e2e/tests/templates/shop-page.block_theme.spec.ts

Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>

* Update plugins/woocommerce-blocks/tests/e2e/tests/templates/shop-page.block_theme.spec.ts

Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>

* Fix linting

---------

Co-authored-by: Bart Kalisz <bartlomiej.kalisz@gmail.com>
2024-04-24 15:57:02 +02:00
Seghir Nadir 0f621c8977
get settings in correct format for Local Pickup (#46799)
* get settings in correct format

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

* expand test to also account for frontend

* remove added test

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-24 15:22:36 +02:00
Albert Juhé Lluveras c59dcbe925
Create update_template_data util and formatting improvements (#46408)
* Create update_template_data util

* Fix comment typo

* Formatting

* Remove unnecessary use of BlockTemplateUtils

* Add changelog file

* Create update_template_data util (II)
2024-04-24 14:57:18 +02:00
Jorge A. Torres 573fe6e612
Fix order counts in status widget for sites with Redis object cache (#46860)
* Use non-persisent 'counts' group for order count cache

* Add changelog

* Apply suggestion
2024-04-24 10:30:31 +00:00
Matt Sherman 955786affc
Product Editor: Add ability to check if product editor made REST request (#46741)
* Add apiFetch middleware to add X-Wc-Product-Editor header to all requests from product editor

* Use productEditorHeaderApiFetchMiddleware

* Update name of header

* Utility function to check header

* Changelog

* Changelog
2024-04-24 06:24:09 -04:00
Ilyas Foo 27e4b07074
Wrap LYS templates and patterns under feature flag (#46856)
* Add feature flag for site editor templates and patterns for coming soon

* Changelog

* Lint

* Fix classic themes
2024-04-24 17:44:35 +08:00
Néstor Soriano 70f49bb389
Add a warning text about the incompatibility of the legacy REST API and HPOS (#46841)
* Add warnings about the incompatibility of the legacy REST API and HPOS:

- A static text in the features settings page, in the HPOS section,
  if the legacy REST API is active.
- A dismissable admin notice that is created at install/update time
  only if both HPOS and the legacy REST API is active
  (it's removed automatically when one of the two ceases to be active)

This covers both the legacy REST API being active in core and the
legacy REST API plugin being installed and active.

* Add changelog file

* - Remove the admin notice (will be added by the Legacy API plugin)
- Add the woocommerce_legacy_api_and_hpos_incompatibility_warning_text filter

* Fix misplaced line feed
2024-04-24 14:59:02 +05:30
Alba Rincón e20641341d
[CYS] Fix AI generated site title comparison (#46819)
* Fix AI generated site titles comparisons

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

* Fix lint errors

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-24 10:49:20 +02:00
Jonathan Lane a6fe8ef3ff
Fix flaky e2e tests (#46845)
Co-authored-by: Jon Lane <jon.lane@automattic.com>
2024-04-24 11:26:16 +03:00
Alba Rincón 5bc0a2c8b1
[CYS] Fix logo position after saving on the assembler (#46833)
* Fix logo position after saving on the assembler

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

* Fix lint error

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-24 09:34:09 +02:00
RJ a0701f6ea5
fix: removed live explat test (#46818) 2024-04-24 16:51:49 +10:00
Fernando Marichal eab9d115d4
Enable "Custom Fields" feature flag for by default (#46832)
* Enable "product-custom-fields"

* Add changelog
2024-04-24 03:12:06 -03:00
RJ b3e7c62914
update: lys feature flag off (#46852) 2024-04-24 02:22:38 +00:00
Adrian Moldovan d57ff87cb3
[e2e tests] Fix blocks tests failing with Gutenberg active (#46842)
* Fix plugin slug for reporting

* Comment out setting of woocommerce_coming_soon

* Add canvas utility

* Update create-cart-block.spec.js to use canvas instead of page

* Update create-checkout-block.spec.js to use canvas instead of page

* Extract common editor actions into editor utils

* Add changelog

* Update post and page creation tests to use canvas

* Update create-woocommerce-blocks.spec.js to use canvas

* Activate Gutenberg to test changes

* Remove plugins listing from env setup script

* Fix eslint errors

* Remove redundant env setup script call

* Install Gutenberg for test in CI

* Test with Gutenberg

* Remove Gutenberg

* Fix block editor variable product test

* Revert "Fix block editor variable product test"

This reverts commit cd004530a7.

---------

Co-authored-by: Jon Lane <jon.lane@automattic.com>
2024-04-23 13:38:19 -07:00
Luigi Teschio bc18547e81
CYS - AI flow: Replace recordEvent with trackEvent (#46823)
* replace recordEvent with trackEvent

* fix type

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

* Add tracking event

* fix implementation

* fix lint error

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-23 19:38:06 +02:00
Luigi Teschio cce1e224ad
CYS - AI flow: keep persisted query param when redirecting (#46820)
* CYS - set flowType when the state machine is instantiated

* remove not necessary code

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

* fix action

* improve logic

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

* CYS - AI Flow: hide X button on the entrepreneur flow

* CYS - AI flow: keep persisted query param when redirect

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-23 15:52:29 +00:00
Thilina Pituwala dae1c963da
Remove red badge on extensions menu when the site is not connected (#46807)
* Allow having two different in-app connect messages based on WooCommerce.com Update Manager installation status.

* Revert to older message.

* Update connect message icon.

* Prevent showing the red badge when site is not connected.

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-23 15:38:11 +00:00
Seghir Nadir 742cbbda9d
Graduate Additional Fields to stable and rename it. (#46805)
* graduate woocommerce_blocks_register_checkout_field

* graduate filters

* Migrate Additional to Order and Other

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

* fix markdown lint

* update tests to use old value

* fix lint issue

* pass field options by reference

* update test helpers

* update tests to use latest api

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-23 16:47:32 +02:00
Seghir Nadir 0f4e675fb5
Correctly serialize data in additional fields API (#46762)
* fix data sanitization on session

* add changelog
2024-04-23 15:34:31 +02:00
Bart Kalisz 190c972332
Blocks: Isolate performance tests from e2e tests (#46773)
* Isolate (cart) performance tests from e2e tests

* Add changelog entry
2024-04-23 13:11:46 +02:00
Seghir Nadir fc31f0c77d
Be less aggressive on selected shipping rate logic for Checkout block (#46719)
* be less aggressive on selected shipping rate logic

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-23 13:03:46 +02:00
Luigi Teschio 25fae0cc27
CYS - AI Flow: hide X button on the entrepreneur flow (#46800)
* CYS - set flowType when the state machine is instantiated

* remove not necessary code

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

* fix action

* improve logic

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

* CYS - AI Flow: hide X button on the entrepreneur flow

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-23 10:27:32 +00:00
Néstor Soriano 37beab9364
Allow enbling HPOS when the only incompatible plugin is the Legacy REST API one (#46634) 2024-04-23 12:19:29 +02:00
Sam Seay 97595ce95d
Fix crashes in mini-cart by externalizing the wc types package. (#46814) 2024-04-23 20:18:37 +12:00
Luigi Teschio 2ae56b2de2
CYS - set flowType when the state machine is instantiated (#46528)
* CYS - set flowType when the state machine is instantiated

* remove not necessary code

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

* fix action

* improve logic

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

* remove not necessary guards

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-23 10:12:35 +02:00
Paul Sealock b9a1b67991
[LYS] Reapply styles from 46619 (#46813)
* copy styles over from 46619

* Fix header padding

* login/out

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

* typo

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-23 19:26:35 +12:00
Paul Sealock 89c330f03e
[Launch Your Store] Use Block to handle template styles (#46751) 2024-04-23 16:07:56 +12:00
Adrian Moldovan a33078ba6b
[performance metrics] Use engines.pnpm version when setting up the environment (#46787) 2024-04-22 12:34:28 -05:00
Jorge A. Torres 05fed19271
Move all HPOS CLI tools to the "hpos" namespace (#46766)
* Deprecate CLI tools in the “cot” namespace

* PHPCS fixes

* Add changelog

* Restore a few args for backwards compatibility
2024-04-22 14:24:40 +01:00
Gan Eng Chin 3ac3a497ba
Change "Origin" column name to "Attribution" in Orders Analytics (#46760)
* Change "Origin" column name to "Attribution" in Analytics.

* Rename "Origin" column to "Attribution" in Orders Analytics report download.

* Add changelog.
2024-04-22 21:20:30 +08:00
Gan Eng Chin c595717d16
Fix "Add a filter" UI issue in Analytics (#46750)
* Fix UI for add filter popover in Analytics.

* Make character casing consistent for filters.

* Add changelog.

* Add changelog.

* Change filter label to sentence case.
2024-04-22 21:15:22 +08:00
Alba Rincón efbce912c5
[CYS] Remove `Save` button from inside the different sections (#46526)
* Remove save button, rename done button and fix tests

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

* Fix error

* Fix lint errors

* Fix more lint errors

* Fix done button tests

* Add missing awaits

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-22 14:26:57 +02:00
Ilyas Foo ecb48cc0fb
Replace LYS coming soon override to use template include filter and handle 404 gracefully (#46667)
* Hide woo breadcrumb

* Update coming soon entire site style

* Update style

* Fix wp group block

* Change coming soon template to use template_include instead

* Changelog

* Change to add_filter

* Proper handling for non-FSE themes

* Update comments

---------

Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>
2024-04-22 17:54:48 +08:00
Chi-Hsuan Huang b9ea5bacd8
Fix back from CYS via LYS goes to Home, not LYS (#46665)
* Add goBack action to customize-store

* Add changelog

* Add __experimentLocationStack to history

* Update customize-store goBack action

* Rename __experimentalLocationStack
2024-04-22 21:26:32 +12:00
kkmuffme 118932d2ee
Skip loading of webhooks if webhooks disabled (#46057)
* Skip loading of webhooks if webhooks disabled

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

* PHP CS fix.

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Vedanshu Jain <vedanshu.jain.2012@gmail.com>
2024-04-22 14:24:56 +05:30
Kyle Barrow d612e893ff
Prevent fatal error on the Status page when the log directory contains an unreadable directory (#46709)
Add flag to RecursiveIteratorIterator to prevent fatal error on Woocommerce Status page when system tmp folder includes unreadable directories
2024-04-22 10:52:48 +02:00
Jorge A. Torres 24a9b8c771
Remove HPOS entries from Tracker and WC status that are no longer in use (#46239)
* Remove unused HPOS props from WC_Tracker and status screen

* Add changelog

* Fix tests
2024-04-22 12:49:07 +05:30
Barry Hughes 99be7b960b
Adjust labelling of refund line items in refund emails and order summaries. (#45455) 2024-04-22 12:45:43 +05:30
Mayisha de3bc938d2
Fix breadcrumb back icon color to follow the admin theme color (#40106)
* prevent breadcrump back icon from being converted to an image

* add changelog file
2024-04-22 12:31:00 +05:30
Mayisha 2f29ef8a5a
Replace pink with WooCommerce purple in reports and ratings (#40243)
* replace pink with wc purple in reports page

* use wc purple in product rating in the dashboard widget

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

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

* use better contrast

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

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-04-22 12:30:25 +05:30
RJ fd52f18f6b
Move LYS coming soon initialization to core profiler flow (#46708)
Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>
2024-04-22 14:49:59 +08:00
Bart Kalisz 007a4238c3
Blocks E2E: Provide correct expected translation (#46756) 2024-04-20 13:23:55 +02:00
Adrian Duffell 073d0eb59d
LYS copy updates (#46668)
* lys blurb

* Add constants for docs

* Store mode copy

* Private link copy

* Coming soon message

* Bug fix
2024-04-20 00:02:53 +00:00
Leif Singer d1be68b88c
Update @woo.com email addresses to @woocommerce.com (#46387)
* update @woo.com email addresses

* update %40woo.com email address

* add changelog file

* update docs manifest
2024-04-19 21:11:01 +00:00