@graphcommerce/magento-cart 8.0.6-canary.3 → 8.0.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,20 +1,6 @@
1
1
  # Change Log
2
2
 
3
- ## 8.0.6-canary.3
4
-
5
- ## 8.0.6-canary.2
6
-
7
- ### Patch Changes
8
-
9
- - [#2234](https://github.com/graphcommerce-org/graphcommerce/pull/2234) [`0767bc4`](https://github.com/graphcommerce-org/graphcommerce/commit/0767bc40f7b596209f24ca4e745ff0441f3275c9) - Upgrade input components to no longer use muiRegister, which improves INP scores
10
- ([@FrankHarland](https://github.com/FrankHarland))
11
-
12
- - [#2234](https://github.com/graphcommerce-org/graphcommerce/pull/2234) [`530076e`](https://github.com/graphcommerce-org/graphcommerce/commit/530076e3664703cb8b577b7fcf1998a420819f60) - Moved all usages of useFormPersist to the <FormPersist/> component to prevent rerenders.
13
- ([@FrankHarland](https://github.com/FrankHarland))
14
-
15
- ## 8.0.6-canary.1
16
-
17
- ## 8.0.6-canary.0
3
+ ## 8.0.6
18
4
 
19
5
  ## 8.0.5
20
6
 
@@ -2,10 +2,10 @@ import { CheckboxElement } from '@graphcommerce/ecommerce-ui'
2
2
  import { useQuery } from '@graphcommerce/graphql'
3
3
  import { extendableComponent, FormDiv } from '@graphcommerce/next-ui'
4
4
  import {
5
- FormPersist,
6
5
  useForm,
7
6
  useFormCompose,
8
7
  UseFormComposeOptions,
8
+ useFormPersist,
9
9
  } from '@graphcommerce/react-hook-form'
10
10
  import { i18n } from '@lingui/core'
11
11
  import { Box, Link, SxProps, Theme } from '@mui/material'
@@ -39,6 +39,8 @@ export function CartAgreementsForm(props: CartAgreementsFormProps) {
39
39
  console.log(values)
40
40
  })
41
41
 
42
+ useFormPersist({ form, name: 'PaymentAgreementsForm' })
43
+
42
44
  useFormCompose({ form, step, submit, key: 'PaymentAgreementsForm' })
43
45
 
44
46
  if (data?.checkoutAgreements?.length === 0) return null
@@ -48,7 +50,6 @@ export function CartAgreementsForm(props: CartAgreementsFormProps) {
48
50
  className={classes.form}
49
51
  sx={[(theme) => ({ pt: theme.spacings.md }), ...(Array.isArray(sx) ? sx : [sx])]}
50
52
  >
51
- <FormPersist form={form} name='PaymentAgreementsForm' />
52
53
  <form noValidate onSubmit={submit} name='cartAgreements'>
53
54
  <Box className={classes.formInner} sx={{ typography: 'body1', display: 'inline-block' }}>
54
55
  {data?.checkoutAgreements &&
@@ -21,7 +21,7 @@ const { classes } = extendableComponent<OwnerState, typeof compName, typeof part
21
21
  export function CartSummary(props: CartSummaryProps) {
22
22
  const { children, editable, sx = [] } = props
23
23
 
24
- const { data } = useCartQuery(GetCartSummaryDocument)
24
+ const { data } = useCartQuery(GetCartSummaryDocument, { allowUrl: true })
25
25
  const { href: historyHref, onClick: historyOnClick } = useHistoryLink({
26
26
  href: '/checkout',
27
27
  })
@@ -11,7 +11,7 @@ fragment CartTotals on Cart
11
11
  ...Money
12
12
  }
13
13
  }
14
- # todo: https://github.com/magento/magento2/pull/31322
14
+ # https://github.com/magento/magento2/pull/31322
15
15
  available_shipping_methods {
16
16
  carrier_code
17
17
  method_code
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@graphcommerce/magento-cart",
3
3
  "homepage": "https://www.graphcommerce.org/",
4
4
  "repository": "github:graphcommerce-org/graphcommerce",
5
- "version": "8.0.6-canary.3",
5
+ "version": "8.0.6",
6
6
  "sideEffects": false,
7
7
  "prettier": "@graphcommerce/prettier-config-pwa",
8
8
  "eslintConfig": {
@@ -12,20 +12,20 @@
12
12
  }
13
13
  },
14
14
  "peerDependencies": {
15
- "@graphcommerce/ecommerce-ui": "^8.0.6-canary.3",
16
- "@graphcommerce/eslint-config-pwa": "^8.0.6-canary.3",
17
- "@graphcommerce/framer-next-pages": "^8.0.6-canary.3",
18
- "@graphcommerce/framer-scroller": "^8.0.6-canary.3",
19
- "@graphcommerce/framer-utils": "^8.0.6-canary.3",
20
- "@graphcommerce/graphql": "^8.0.6-canary.3",
21
- "@graphcommerce/image": "^8.0.6-canary.3",
22
- "@graphcommerce/magento-customer": "^8.0.6-canary.3",
23
- "@graphcommerce/magento-graphql": "^8.0.6-canary.3",
24
- "@graphcommerce/magento-store": "^8.0.6-canary.3",
25
- "@graphcommerce/next-ui": "^8.0.6-canary.3",
26
- "@graphcommerce/prettier-config-pwa": "^8.0.6-canary.3",
27
- "@graphcommerce/react-hook-form": "^8.0.6-canary.3",
28
- "@graphcommerce/typescript-config-pwa": "^8.0.6-canary.3",
15
+ "@graphcommerce/ecommerce-ui": "^8.0.6",
16
+ "@graphcommerce/eslint-config-pwa": "^8.0.6",
17
+ "@graphcommerce/framer-next-pages": "^8.0.6",
18
+ "@graphcommerce/framer-scroller": "^8.0.6",
19
+ "@graphcommerce/framer-utils": "^8.0.6",
20
+ "@graphcommerce/graphql": "^8.0.6",
21
+ "@graphcommerce/image": "^8.0.6",
22
+ "@graphcommerce/magento-customer": "^8.0.6",
23
+ "@graphcommerce/magento-graphql": "^8.0.6",
24
+ "@graphcommerce/magento-store": "^8.0.6",
25
+ "@graphcommerce/next-ui": "^8.0.6",
26
+ "@graphcommerce/prettier-config-pwa": "^8.0.6",
27
+ "@graphcommerce/react-hook-form": "^8.0.6",
28
+ "@graphcommerce/typescript-config-pwa": "^8.0.6",
29
29
  "@lingui/core": "^4.2.1",
30
30
  "@lingui/macro": "^4.2.1",
31
31
  "@lingui/react": "^4.2.1",
package/typePolicies.ts CHANGED
@@ -9,9 +9,6 @@ export const cartTypePolicies: StrictTypedTypePolicies = {
9
9
  CartPrices: {
10
10
  merge: (exiting, incoming, { mergeObjects }) => mergeObjects(exiting, incoming),
11
11
  },
12
- CartItemPrices: {
13
- merge: (exiting, incoming, { mergeObjects }) => mergeObjects(exiting, incoming),
14
- },
15
12
  Cart: {
16
13
  fields: {
17
14
  shipping_addresses: {