@graphcommerce/magento-cart-shipping-method 3.6.3 → 3.6.6

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,33 @@
1
1
  # Change Log
2
2
 
3
+ ## 3.6.6
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [[`8d5207288`](https://github.com/graphcommerce-org/graphcommerce/commit/8d52072887f124831ed85d28ec79998f0ce55f1c), [`662f510c2`](https://github.com/graphcommerce-org/graphcommerce/commit/662f510c21fc44a63036e5c7a0726ccb33c31600)]:
8
+ - @graphcommerce/magento-cart@4.8.0
9
+ - @graphcommerce/react-hook-form@3.3.3
10
+ - @graphcommerce/magento-cart-shipping-address@3.4.6
11
+
12
+ ## 3.6.5
13
+
14
+ ### Patch Changes
15
+
16
+ - Updated dependencies [[`e8639ec5f`](https://github.com/graphcommerce-org/graphcommerce/commit/e8639ec5f6759504211d70a966f5c348c6b3a7f6)]:
17
+ - @graphcommerce/magento-cart-shipping-address@3.4.5
18
+ - @graphcommerce/magento-cart@4.7.5
19
+
20
+ ## 3.6.4
21
+
22
+ ### Patch Changes
23
+
24
+ - Updated dependencies [[`9b84a68a1`](https://github.com/graphcommerce-org/graphcommerce/commit/9b84a68a1e7311a79eb687c7dcee905d3000facf)]:
25
+ - @graphcommerce/next-ui@4.23.1
26
+ - @graphcommerce/framer-scroller@2.1.35
27
+ - @graphcommerce/magento-cart@4.7.4
28
+ - @graphcommerce/magento-cart-shipping-address@3.4.4
29
+ - @graphcommerce/magento-store@4.2.32
30
+
3
31
  ## 3.6.3
4
32
 
5
33
  ### Patch Changes
@@ -19,21 +19,15 @@ export function ShippingMethodActionCard(props: ShippingMethodActionCardProps) {
19
19
  onReset,
20
20
  ...cardProps
21
21
  } = props
22
- let { hidden = false } = props
23
22
 
24
23
  const isFree = amount && amount.value === 0
25
24
 
26
- if (carrier_code !== 'freeshipping') hidden = !available ? true : hidden
27
-
28
- if (hidden) return false
29
-
30
25
  const title =
31
26
  carrier_title === 'Free Shipping' ? carrier_title : `${carrier_title} ${method_title}`
32
27
 
33
28
  return (
34
29
  <ActionCard
35
30
  {...cardProps}
36
- hidden={hidden}
37
31
  title={title}
38
32
  details={error_message}
39
33
  action={
@@ -52,6 +52,10 @@ export function ShippingMethodForm(props: ShippingMethodFormProps) {
52
52
  availableMethods
53
53
  // Move disabled items to the bottom
54
54
  .sort((a, b) => (a.available ? -1 : 1))
55
+ .filter((m) => {
56
+ if (m.carrier_code === 'freeshipping') return m.available === true
57
+ return m.method_code
58
+ })
55
59
  .map((method) => ({
56
60
  ...method,
57
61
  disabled: !method?.available,
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@graphcommerce/magento-cart-shipping-method",
3
3
  "homepage": "https://www.graphcommerce.org/",
4
4
  "repository": "github:graphcommerce-org/graphcommerce",
5
- "version": "3.6.3",
5
+ "version": "3.6.6",
6
6
  "sideEffects": false,
7
7
  "prettier": "@graphcommerce/prettier-config-pwa",
8
8
  "eslintConfig": {
@@ -19,14 +19,14 @@
19
19
  "type-fest": "^2.12.2"
20
20
  },
21
21
  "dependencies": {
22
- "@graphcommerce/framer-scroller": "2.1.34",
22
+ "@graphcommerce/framer-scroller": "2.1.35",
23
23
  "@graphcommerce/graphql": "3.4.8",
24
24
  "@graphcommerce/image": "3.1.9",
25
- "@graphcommerce/magento-cart": "4.7.3",
26
- "@graphcommerce/magento-cart-shipping-address": "3.4.3",
27
- "@graphcommerce/magento-store": "4.2.31",
28
- "@graphcommerce/next-ui": "4.23.0",
29
- "@graphcommerce/react-hook-form": "3.3.2"
25
+ "@graphcommerce/magento-cart": "4.8.0",
26
+ "@graphcommerce/magento-cart-shipping-address": "3.4.6",
27
+ "@graphcommerce/magento-store": "4.2.32",
28
+ "@graphcommerce/next-ui": "4.23.1",
29
+ "@graphcommerce/react-hook-form": "3.3.3"
30
30
  },
31
31
  "peerDependencies": {
32
32
  "@lingui/react": "^3.13.2",