woocommerce/plugins/woocommerce-blocks/assets/js/blocks/product-collection
Manish Menaria c70750b85a
Fix: Show preview label only when Product Collection block is selected (#48795)
* Fix: Show preview label only when Product Collection block is selected

Updated the `ProductCollectionContent` component to display the preview label only when the Product Collection block itself is selected. Previously, the preview label was shown when either the block or any of its inner blocks were selected.

Key Changes:
- Removed the `isSelectedOrInnerBlockSelected` constant and its logic.
- Updated the condition to use `props.isSelected` directly to determine if the block is selected.

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

* Update E2E tests

---------

Co-authored-by: github-actions <github-actions@github.com>
2024-06-28 16:48:11 +05:30
..
collections Product Collection: Implement Preview Mode (#46369) 2024-05-15 13:18:43 +05:30
edit Fix: Show preview label only when Product Collection block is selected (#48795) 2024-06-28 16:48:11 +05:30
inner-blocks/no-results New flow of adding Product Collection and basic set of Collections (#42696) 2023-12-27 11:07:27 +01:00
variations Restructure Product Collection editor files (https://github.com/woocommerce/woocommerce-blocks/pull/11981) 2023-12-06 15:50:24 +01:00
block.json Hide Products (Beta) from inserter (#48204) 2024-06-12 15:45:27 +02:00
constants.ts Replace Products (Beta) with Product Collection in product archive templates (#48112) 2024-06-12 15:45:09 +02:00
frontend.tsx Product Collection: Disable client side navigation if blocks incompatible with Interactivity API are detected (#45435) 2024-03-18 08:24:03 +01:00
icon.tsx Foundation of New Product Collection Block (https://github.com/woocommerce/woocommerce-blocks/pull/9352) 2023-05-15 08:51:49 +00:00
index.tsx Fix incompability of Query Pagination block with Product Collection (#47749) 2024-05-23 13:01:57 +02:00
save.tsx Foundation of New Product Collection Block (https://github.com/woocommerce/woocommerce-blocks/pull/9352) 2023-05-15 08:51:49 +00:00
style.scss Improve Accessibility in Product Collection Navigation (#44599) 2024-02-19 11:35:14 +05:30
tracks-utils.ts Fix: handle undefined templateSlug in Product Collection tracking utils (#47504) 2024-05-16 11:17:52 +05:30
types.ts Product Collection: Implement Preview Mode (#46369) 2024-05-15 13:18:43 +05:30
utils.tsx Fix incompability of Query Pagination block with Product Collection (#47749) 2024-05-23 13:01:57 +02:00