@graphcommerce/magento-wishlist 9.0.0-canary.77 → 9.0.0-canary.78

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @graphcommerce/magento-wishlist
2
2
 
3
+ ## 9.0.0-canary.78
4
+
5
+ ### Patch Changes
6
+
7
+ - [#2354](https://github.com/graphcommerce-org/graphcommerce/pull/2354) [`811d5e6`](https://github.com/graphcommerce-org/graphcommerce/commit/811d5e60ebafea6c4a0a968fdc366e5e316bc64e) - Contain ripple to wishlist button instead of propagating to product list item ([@bramvanderholst](https://github.com/bramvanderholst))
8
+
3
9
  ## 9.0.0-canary.77
4
10
 
5
11
  ## 9.0.0-canary.76
@@ -57,12 +57,11 @@ export function useAddProductToWishlistAction(
57
57
  if (selectedOptions.length !== productOptionsCount) return wishlistOptionsCount === 0
58
58
  if (wishlistOptionsCount !== productOptionsCount) return false
59
59
 
60
- return selectedOptions.every(
61
- (option) =>
62
- item.configurable_options?.some(
63
- // If an option is undefined this means the item is a wishlistItem but not all options were selected prior.
64
- (opt) => opt?.configurable_product_option_value_uid === option,
65
- ),
60
+ return selectedOptions.every((option) =>
61
+ item.configurable_options?.some(
62
+ // If an option is undefined this means the item is a wishlistItem but not all options were selected prior.
63
+ (opt) => opt?.configurable_product_option_value_uid === option,
64
+ ),
66
65
  )
67
66
  })
68
67
 
@@ -92,8 +91,8 @@ export function useAddProductToWishlistAction(
92
91
  const configurableOptions = selectedOptions.map((selected_option) => {
93
92
  if (product.__typename !== 'ConfigurableProduct') return null
94
93
 
95
- const configurable_option = product.configurable_options?.find(
96
- (confOption) => confOption?.values?.find((values) => values?.uid === selected_option),
94
+ const configurable_option = product.configurable_options?.find((confOption) =>
95
+ confOption?.values?.find((values) => values?.uid === selected_option),
97
96
  )
98
97
 
99
98
  const value = configurable_option?.values?.find((values) => values?.uid === selected_option)
@@ -133,6 +132,7 @@ export function useAddProductToWishlistAction(
133
132
  }),
134
133
  toggleItem: useEventCallback(toggleItem),
135
134
  cancelBubble: useEventCallback((e) => {
135
+ e.stopPropagation()
136
136
  e.preventDefault()
137
137
  }),
138
138
  showSuccess,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@graphcommerce/magento-wishlist",
3
- "version": "9.0.0-canary.77",
3
+ "version": "9.0.0-canary.78",
4
4
  "sideEffects": false,
5
5
  "prettier": "@graphcommerce/prettier-config-pwa",
6
6
  "browserslist": [
@@ -13,20 +13,20 @@
13
13
  }
14
14
  },
15
15
  "peerDependencies": {
16
- "@graphcommerce/ecommerce-ui": "^9.0.0-canary.77",
17
- "@graphcommerce/eslint-config-pwa": "^9.0.0-canary.77",
18
- "@graphcommerce/graphql": "^9.0.0-canary.77",
19
- "@graphcommerce/graphql-mesh": "^9.0.0-canary.77",
20
- "@graphcommerce/image": "^9.0.0-canary.77",
21
- "@graphcommerce/magento-cart": "^9.0.0-canary.77",
22
- "@graphcommerce/magento-customer": "^9.0.0-canary.77",
23
- "@graphcommerce/magento-product": "^9.0.0-canary.77",
24
- "@graphcommerce/magento-product-configurable": "^9.0.0-canary.77",
25
- "@graphcommerce/magento-store": "^9.0.0-canary.77",
26
- "@graphcommerce/next-config": "^9.0.0-canary.77",
27
- "@graphcommerce/next-ui": "^9.0.0-canary.77",
28
- "@graphcommerce/prettier-config-pwa": "^9.0.0-canary.77",
29
- "@graphcommerce/typescript-config-pwa": "^9.0.0-canary.77",
16
+ "@graphcommerce/ecommerce-ui": "^9.0.0-canary.78",
17
+ "@graphcommerce/eslint-config-pwa": "^9.0.0-canary.78",
18
+ "@graphcommerce/graphql": "^9.0.0-canary.78",
19
+ "@graphcommerce/graphql-mesh": "^9.0.0-canary.78",
20
+ "@graphcommerce/image": "^9.0.0-canary.78",
21
+ "@graphcommerce/magento-cart": "^9.0.0-canary.78",
22
+ "@graphcommerce/magento-customer": "^9.0.0-canary.78",
23
+ "@graphcommerce/magento-product": "^9.0.0-canary.78",
24
+ "@graphcommerce/magento-product-configurable": "^9.0.0-canary.78",
25
+ "@graphcommerce/magento-store": "^9.0.0-canary.78",
26
+ "@graphcommerce/next-config": "^9.0.0-canary.78",
27
+ "@graphcommerce/next-ui": "^9.0.0-canary.78",
28
+ "@graphcommerce/prettier-config-pwa": "^9.0.0-canary.78",
29
+ "@graphcommerce/typescript-config-pwa": "^9.0.0-canary.78",
30
30
  "@lingui/core": "^4.2.1",
31
31
  "@lingui/macro": "^4.2.1",
32
32
  "@lingui/react": "^4.2.1",