* introduce packages/js/data/src/user/types.ts pref
* be able to dismiss the Upsells advice
* rename user pref key
* typify product_advice_card_dismissed prop
* store is dismissed state in the user pref
* delegate the dismiss state to the component
* changelog
* remove console.log :'(
* fix TS issue
* fix TS issue
* changelog
* Create and register product-linked-list-field block
* Add upsells and cross-sells blocks to the simple product template
* Create formatted price component
* Add linked product table to the linked product list block
* Add remove product button to each product row
* Add see product page button
* Add link to the product name so it can be edited in a new tab
* Fix some styles
* Add product search field to the linked product list block
* Fix styles
* Add changelog files
* Fix linter error
* Fix rebase conflicts
* Use useProductEntityProp instead of useEntityProp within product-linked-list-field block
* Move the product list to its own component
* Move the product select to its own component
* Move the product image to its own component
* Fix linter error
* Remove old noticed on classic checkout when applying coupon code
* Remove old noticed on classic checkout when applying coupon code
* Add changefile(s) from automation for the following project(s): woocommerce
---------
Co-authored-by: github-actions <github-actions@github.com>
* Show default patterns and products if the images request fails
* Add changefile(s) from automation for the following project(s): woocommerce
* Remove space
* Simplify condition
* Removed unused call
---------
Co-authored-by: github-actions <github-actions@github.com>
* Remove the double quotes from the AI generated content before saving it
This will avoid having two consecutive double quotes and breaking the JSON.
* Add changefile(s) from automation for the following project(s): woocommerce
* Fix lint error
---------
Co-authored-by: github-actions <github-actions@github.com>
* Add rating and change product card layout
* Fix some minor CSS bugs in existing code
* Implement skeleton loader
* Update theme card styling to match design
* Add changefile(s) from automation for the following project(s): woocommerce
---------
Co-authored-by: github-actions <github-actions@github.com>
* Fix namespace
* Add changefile(s) from automation for the following project(s): woocommerce-blocks
---------
Co-authored-by: github-actions <github-actions@github.com>
* Endpoint shell
* Single layout template route
* Add area query arg
* Fix BlockTemplateRegistry::get_registered() return type
* Check if templates are registered before registering
* Use json format for layout templates response
* Remove unused use
* Use json format for layout templates response for get_items
* Consolidate processing for get_items and get_item
* LayoutTemplateRegistry
* Fix matching by id
* Get templates from LayoutTemplateRegistry
* Remove unused method
* Fix typo in code doc
* Move template instantiation to registry
* Return template instance, not json when instantiating
* Use LayoutTemplateRegistry instead of BlockTemplateRegistry
* Add code docs for rest controller
* Fix code doc in BlockTemplateRegistry
* Code docs for LayoutTemplateRegistry
* Changelog
* Add code doc for LayoutTemplatesServiceProvider
* Unit test for registering a layout template
* Unit tests for invalid params when registering layout template
* Unit test for layout template instantiation
* Unit test for instantiating layout templates with query params
* Unit test for layout template instance caching
* Cache layout template instances
* Refactor layout template info querying
* Add unit test for layout template instantiation actions
* Add before and after layout template instantiation actions
* Use layout template ID for array key
* REST API unit test to get all items
* Unit test for unregister_all
* Method to unregister all layout templates
* REST API unit test to get all items for a specific area
* Fix to_json() in TestLayoutTemplate
* REST API unit test to get single item
* Fix get_item
* REST API unit test for single item with invalid id
* REST API unit test for get all items for invalid area
* Fix test_cached_instances - array access
* Test that old register hook is called
* Call old register hook
* Remove before hook (will put in separate PR)
* Fix occurrences where Installer_Error exception is returned instead of being thrown.
* Add changefile(s) from automation for the following project(s): woocommerce
* Add @throws tag in function comment.
- Stop tracking order attribution when the consent is revoked on the same page.
Switch `wp_consent_type_defined` to VanillaJS event, as this is what the latest Complianz dispatches.
Remove jQuery dependency.
5427807509
- Update checkout block data when consent is given/revoked on the same page
263d0b8a14
- Register WPConsentAPI integration for OrderAttribution
cde9f642a1
- Don't store empty meta values for order attribution
If no values at all are sent, don't create meta records
00b83eed00
- Don't translate or add parenthesis to unknown placeholder
bbc4b1f699
- Un-hardcode marketing category in wp-consent-api-integration.js
45014a715a
Co-authored-by: Justin Palmer <228780+layoutd@users.noreply.github.com>
* introduce UserPreference panel
* render user preference panel
* expose UserPreferences type
* introduce force mode to update user pref
* rename global object with `__wcbt`
* changelog
* changelog
* Fix typo
* Fix `acceleratedReleaseDate` output
* Comment unnecessary steps, jobs
* Do only a dry-run
* Revert "Do only a dry-run"
This reverts commit a41ea99401.
* Revert "Comment unnecessary steps, jobs"
This reverts commit 97985a0ad0.
* Add changelog
* Prevent Command Palette scripts to enqueue unnecessary scripts in the editor
* Add changefile(s) from automation for the following project(s): woocommerce
* Properly set script asset dependencies
* Create util function to simplify the code
* Fix JS warning when registering WooCommerce Commands
---------
Co-authored-by: github-actions <github-actions@github.com>
* add: multiple select support to attribute dropdown
* fix: remove active filter from dropdown
* chore: remove unused extractBuiltinColor
---------
Co-authored-by: Tung Du <dinhtungdu@gmail.com>
* replace forward tick with ' in docs folder
* replace encoded bcktick with single quote in docs folder
---------
Co-authored-by: Ron Rennick <ronald.rennick@automattic.com>
* Add e2e tests for image transition in Product Gallery block
* Create e2e tests for the Product Gallery block when it is inside the pop-up
* Add changelog
* Remove unnecessary lodash dependency import
* Increase product images width to 400 to have a better resolution
* Add changefile(s) from automation for the following project(s): woocommerce
---------
Co-authored-by: github-actions <github-actions@github.com>
* add: query filters count class
* chore: method comments
* refactor: rename class to QueryFilters
* fix: price filter count
* fix: price filter url
* chore: remove unnecessary transformation
* chore: remove unused meta query filter
* chore: put public methods on the top of the class
* fix: passing $wp_query
* Add changefile(s) from automation for the following project(s): woocommerce-blocks, woocommerce
* fix: stock query clause
* fix: handle and query type for attribute filter
* fix: ensure passing non null value to floor/ceil
* [Experimental] Collection Filter blocks: ensure the namespace is always rendered (#43112)
* fix: ensure the namespace is always rendered
* fix: target only wc queries
* fix: properly reset part of query to make new filter blocks work with Product Collection block
* Add tooltip attr to Pricing field
* Remove Fragment reference
* Add tooltip to regular price
* Add tooltip to sale price
* Remove "labelToShow" const
* Add changelog
* Revert "Trigger event `experimental__woocommerce_blocks-cart-add-item` in the SSR Product Button vis Interactivity API (#42946)"
This reverts commit 4fec136da1.
* Add changefile(s) from automation for the following project(s): woocommerce-blocks
---------
Co-authored-by: github-actions <github-actions@github.com>
* Update woocommerce.com URLs in documentation and code files
* Add changelog
* Fix github repository link in extend-rest-api-add-custom-fields.md
Co-authored-by: Albert Juhé Lluveras <contact@albertjuhe.com>
* Add github reporter (#42974)
* Add github reporter
* Add changelog
---------
Co-authored-by: Jon Lane <jon.lane@automattic.com>
* Fix product task redirect to support grouped and external products (#43051)
* Rearrange product redirection logic to better accept grouped and external produc types
* Add changelog
* Modify feedback modal actions (#43005)
* Adapt feedback modal actions
* Add changelogs
* Modify comments
* Fix tests
* Fix test
* Update class-wc-gateway-bacs.php (#43054)
* Update class-wc-gateway-bacs.php
Fix typo in textdomain
* Add changefile(s) from automation for the following project(s): woocommerce
---------
Co-authored-by: github-actions <github-actions@github.com>
* [Product Block Editor]: Add `Linked product` tab (#43009)
* add linked-products to group IDs
* add Linked Products tab
* tweak hideConditions condition
* changelog
* fix typo in doc comment
* Introduce a product type selection within the new experience (#41823)
* Create a relation between the product type and the product block template
* Add 'patterns' to name the kind of products that can be created for a specific template
* Resolve template using its id as a template query param
* Rename ProductEditPattern to ProductTemplate
* Rename get_patterns hook to woocommerce_product_editor_get_product_templates
* Return the list of templates to the client
* Set layout template events as array
* Register the layout template based on the product template or the post type in case of product variations
* Registering non supported product types
* Create and register the woocommerce/product-details-section-description block
* Add the product type to the section description
* Create product type selector
* Fix menu item style
* Highlight selected menu item
* Set the selected product template
* Set product template title to lowercase in the content description
* Rename blocks by blockTemplates under the AbstractBlockTemplate class
* Rename to woocommerce_product_editor_product_templates filter
* Remove product_template_ prefix from the supported_product_types map
* Rename get_formatted to to_JSON and convert the props to client side like
* Refactor get_product_templates
* Fix icon resolution
* Add a confirmation modal for unsupported product templates
* Add changelog files
* Remove product types using for testing
* Fix redirection when changing to a non supported product template
* Set the change button state to busy when it is saving the product
* Fix php linter errors
* Fix rebase conflict
* Move ProductTemplate to Automattic\WooCommerce\Admin\Features\ProductBlockEditor namespace
* Add the to_json definition to the BlockTemplateInterface
* Create default product template by custom product type if it does not have a template associated yet
* Fix some comments and product template creation validation
* Add support to load the product template icon from an external resource
* Fix php linter
* Fix the changelog description
* [Experimental] Interactivity Dropdown multi-select mode, ratings filter and introduce each directive (#42981)
---------
Co-authored-by: David Arenas <david.arenas@automattic.com>
* Introduce the transient files engine (#42877)
Co-authored-by: Corey McKrill <916023+coreymckrill@users.noreply.github.com>
* Change marketplace install API request to POST instead of GET (#43033)
* Change marketplace install API to using POST instead of GET
* Fix linting error
* Add changefile(s) from automation for the following project(s): woocommerce
---------
Co-authored-by: github-actions <github-actions@github.com>
* Prep trunk for 8.6 cycle (#43021)
Prep trunk for 8.6 cycle with version bump to 8.6.0-dev
Co-authored-by: WooCommerce Bot <no-reply@woo.com>
* Add Playwright tests for All Reviews, Reviews by Product and Reviews by Category blocks (#42903)
* Remove Reviews blocks Puppeteer tests
* Minor code cleanup
* Typos
* Create publishAndVisitPost() editor util
* Fix subcategories when importing products in Playwright and add reviews
* Add Reviews blocks tests in Playwright
* More typos
* Add changefile(s) from automation for the following project(s): woocommerce-blocks
* Create a 'reviews' object in data.ts so we can store reviews data in one single place
* Update test so instead of creating a new post in each test, we go to the already-created post
* Add source comments to reviews data to match it with the script
---------
Co-authored-by: github-actions <github-actions@github.com>
* Release: Remove 8.5 change files (#43022)
Delete changelog files from 8.5 release
Co-authored-by: WooCommerce Bot <no-reply@woo.com>
Co-authored-by: Alex López <alex.lopez@automattic.com>
* Delete changelog files based on PR 43033 (#43079)
Delete changelog files for 43033
Co-authored-by: WooCommerce Bot <no-reply@woo.com>
* Delete changelog files based on PR 43051 (#43081)
Delete changelog files for 43051
Co-authored-by: WooCommerce Bot <no-reply@woo.com>
* Interactive Price Filter: use `context` instead of `state` (#42980)
* feat: use context instead of state
* fix: temporary move the context to inner element for diffing to work
* fix: update context before navigation for optimistic UI
* Load google analytics gtag script asynchronously in WooCommerce Blocks (#43040)
Co-authored-by: github-actions <github-actions@github.com>
* set WOOCOMMERCE_BLOCKS_PHASE to 1 for the production build (#43074)
* set WOOCOMMERCE_BLOCKS_PHASE to 1 for the production build
* Add changefile(s) from automation for the following project(s): woocommerce
---------
Co-authored-by: github-actions <github-actions@github.com>
* Revert "Fix schedule sales error" (#43094)
Revert "Fix schedule sales error (#42700)"
This reverts commit 9b800aa179.
* [Product Block Editor]: add Linked product sections. First approach. (#43013)
* add Linked products, Upsell section
* changelog
* add Cross-lens section
* add links to the Upsell sections
* changelog
* fix lint issues
* fix lint issus
* fix linting issue :-|
* check whether the linked product group is defined
* [Product Block Editor]: introduce ShoppingBags component (#43042)
* add ShoppingBags component
* Add ShoppingBag story
* changelog
* Fix: Collection data being leaked between Collection Filters blocks (#43044)
* fix: CYS - change heading color (#43076)
* fix: CYS - change heading color
* Add changefile(s) from automation for the following project(s): woocommerce
---------
Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Patricia Hillebrandt <patriciahillebrandt@gmail.com>
* Delete changelog files based on PR 43074 (#43118)
Delete changelog files for 43074
Co-authored-by: WooCommerce Bot <no-reply@woo.com>
* [Product Block Editor]: fix feature flag to hide the Linked products (#43119)
* fix flag to hide/show product editor
* changelog
* Add changelog
---------
Co-authored-by: Albert Juhé Lluveras <contact@albertjuhe.com>
Co-authored-by: Jonathan Lane <lanej0@users.noreply.github.com>
Co-authored-by: Jon Lane <jon.lane@automattic.com>
Co-authored-by: louwie17 <lourensschep@gmail.com>
Co-authored-by: Fernando Marichal <fernando.marichal@automattic.com>
Co-authored-by: Marc Guay <marc.guay@gmail.com>
Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Damián Suárez <rdsuarez@gmail.com>
Co-authored-by: Maikel David Pérez Gómez <maikel.perez@automattic.com>
Co-authored-by: Sam Seay <samueljseay@gmail.com>
Co-authored-by: Néstor Soriano <konamiman@konamiman.com>
Co-authored-by: Corey McKrill <916023+coreymckrill@users.noreply.github.com>
Co-authored-by: Kyle Nel <22053773+kdevnel@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: WooCommerce Bot <no-reply@woo.com>
Co-authored-by: Alex López <alex.lopez@automattic.com>
Co-authored-by: Tung Du <dinhtungdu@gmail.com>
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
Co-authored-by: Luigi Teschio <gigitux@gmail.com>
Co-authored-by: Patricia Hillebrandt <patriciahillebrandt@gmail.com>
* Fix: Enable Pagination Block Visibility in Product Collection Block
This commit resolves an issue where the Pagination block was not visible in the block insertor within the Product Collection block.
- The core query pagination block name, initially hardcoded, is now declared as a constant `coreQueryPaginationBlockName` in `constants.ts`. This change not only improves code readability but also ensures consistency in using the block name across different files.
- In `index.tsx`, the `addProductCollectionBlockToParentOfPaginationBlock` utility function from `utils.tsx` is imported and executed. This function plays a crucial role in the fix. It dynamically adds the Product Collection block to the parent array of the Core Pagination block, ensuring the latter's visibility in the insertor when editing the Product Collection block.
- The utility function employs WordPress hooks and version checks to gracefully handle different WordPress environments. This careful approach maintains backward compatibility while addressing the current issue.
With these changes, merchants can now easily add a Pagination block from the insertor while working on the Product Collection block, enhancing the user experience and functionality.
* Add changefile(s) from automation for the following project(s): woocommerce-blocks
---------
Co-authored-by: github-actions <github-actions@github.com>
* Update product query block templates with WooCommerce namespace
It modifies the `<wp:post-template>` block in multiple files to include a new attribute: `{"__woocommerceNamespace":"woocommerce/product-query/product-template"}`.
The inclusion of the `__woocommerceNamespace` attribute is a strategic enhancement, ensuring that these block templates are explicitly recognized as part of the WooCommerce namespace.
This fix the issue where migration from Products beta block to Product Collection block doesn't work properly.
* Fix linting error
* Add changefile(s) from automation for the following project(s): woocommerce-blocks, woocommerce
---------
Co-authored-by: github-actions <github-actions@github.com>
Certain order properties (or metadata) are not relevant for HPOS verification. For example, `_edit_lock` which is an ephemeral key. So far we've been hardcoding these keys in various places. This provides a new API to access these keys. It also introduces hook `woocommerce_hpos_sync_ignored_order_props` which allows 3rd party code to add new keys to be ignored by sync/verification code.
Fixes#41907