@graphcommerce/magento-product 8.0.5 → 8.0.6-canary.1
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,14 @@
|
|
1
1
|
# Change Log
|
2
2
|
|
3
|
+
## 8.0.6-canary.1
|
4
|
+
|
5
|
+
## 8.0.6-canary.0
|
6
|
+
|
7
|
+
### Patch Changes
|
8
|
+
|
9
|
+
- [#2196](https://github.com/graphcommerce-org/graphcommerce/pull/2196) [`84c50e4`](https://github.com/graphcommerce-org/graphcommerce/commit/84c50e49a1a7f154d4a8f4045c37e773e20283ad) - Allow Lingui to use linguiLocale with country identifiers like `en-us`, it would always load `en` in this case. Introced a new `useLocale` hook to use the correct locale string to use in Intl methods.
|
10
|
+
([@paales](https://github.com/paales))
|
11
|
+
|
3
12
|
## 8.0.5
|
4
13
|
|
5
14
|
### Patch Changes
|
@@ -9,9 +9,9 @@ import {
|
|
9
9
|
MessageSnackbar,
|
10
10
|
MessageSnackbarProps,
|
11
11
|
nonNullable,
|
12
|
+
useLocale,
|
12
13
|
} from '@graphcommerce/next-ui'
|
13
14
|
import { Trans } from '@lingui/react'
|
14
|
-
import { useRouter } from 'next/router'
|
15
15
|
import { useMemo } from 'react'
|
16
16
|
import { findAddedItems } from './findAddedItems'
|
17
17
|
import { toUserErrors } from './toUserErrors'
|
@@ -26,9 +26,8 @@ export function AddProductsToCartSnackbar(props: AddProductsToCartSnackbarProps)
|
|
26
26
|
const { errorSnackbar, successSnackbar } = props
|
27
27
|
const { error, data, redirect, control, submittedVariables } = useFormAddProductsToCart()
|
28
28
|
const formState = useFormState({ control })
|
29
|
-
const { locale } = useRouter()
|
30
29
|
|
31
|
-
const formatter = new Intl.ListFormat(
|
30
|
+
const formatter = new Intl.ListFormat(useLocale(), { style: 'long', type: 'conjunction' })
|
32
31
|
|
33
32
|
const userErrors = toUserErrors(data)
|
34
33
|
|
@@ -1,12 +1,10 @@
|
|
1
1
|
import { JsonLd } from '@graphcommerce/next-ui'
|
2
2
|
import { JsonLdProductFragment } from './JsonLdProduct.gql'
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
}
|
8
|
-
|
9
|
-
export function ProductPageJsonLd<T extends { '@type': string }>(props: ProductPageJsonLdProps<T>) {
|
4
|
+
export function ProductPageJsonLd<
|
5
|
+
T extends { '@type': string },
|
6
|
+
P extends JsonLdProductFragment,
|
7
|
+
>(props: { product: P; render: (product: P) => T & { '@context': 'https://schema.org' } }) {
|
10
8
|
const { product, render } = props
|
11
9
|
return <JsonLd<T> item={render(product)} />
|
12
10
|
}
|
package/package.json
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
"name": "@graphcommerce/magento-product",
|
3
3
|
"homepage": "https://www.graphcommerce.org/",
|
4
4
|
"repository": "github:graphcommerce-org/graphcommerce",
|
5
|
-
"version": "8.0.
|
5
|
+
"version": "8.0.6-canary.1",
|
6
6
|
"sideEffects": false,
|
7
7
|
"prettier": "@graphcommerce/prettier-config-pwa",
|
8
8
|
"eslintConfig": {
|
@@ -18,18 +18,18 @@
|
|
18
18
|
"typescript": "5.3.3"
|
19
19
|
},
|
20
20
|
"peerDependencies": {
|
21
|
-
"@graphcommerce/ecommerce-ui": "^8.0.
|
22
|
-
"@graphcommerce/eslint-config-pwa": "^8.0.
|
23
|
-
"@graphcommerce/framer-next-pages": "^8.0.
|
24
|
-
"@graphcommerce/framer-scroller": "^8.0.
|
25
|
-
"@graphcommerce/graphql": "^8.0.
|
26
|
-
"@graphcommerce/graphql-mesh": "^8.0.
|
27
|
-
"@graphcommerce/image": "^8.0.
|
28
|
-
"@graphcommerce/magento-cart": "^8.0.
|
29
|
-
"@graphcommerce/magento-store": "^8.0.
|
30
|
-
"@graphcommerce/next-ui": "^8.0.
|
31
|
-
"@graphcommerce/prettier-config-pwa": "^8.0.
|
32
|
-
"@graphcommerce/typescript-config-pwa": "^8.0.
|
21
|
+
"@graphcommerce/ecommerce-ui": "^8.0.6-canary.1",
|
22
|
+
"@graphcommerce/eslint-config-pwa": "^8.0.6-canary.1",
|
23
|
+
"@graphcommerce/framer-next-pages": "^8.0.6-canary.1",
|
24
|
+
"@graphcommerce/framer-scroller": "^8.0.6-canary.1",
|
25
|
+
"@graphcommerce/graphql": "^8.0.6-canary.1",
|
26
|
+
"@graphcommerce/graphql-mesh": "^8.0.6-canary.1",
|
27
|
+
"@graphcommerce/image": "^8.0.6-canary.1",
|
28
|
+
"@graphcommerce/magento-cart": "^8.0.6-canary.1",
|
29
|
+
"@graphcommerce/magento-store": "^8.0.6-canary.1",
|
30
|
+
"@graphcommerce/next-ui": "^8.0.6-canary.1",
|
31
|
+
"@graphcommerce/prettier-config-pwa": "^8.0.6-canary.1",
|
32
|
+
"@graphcommerce/typescript-config-pwa": "^8.0.6-canary.1",
|
33
33
|
"@lingui/core": "^4.2.1",
|
34
34
|
"@lingui/macro": "^4.2.1",
|
35
35
|
"@lingui/react": "^4.2.1",
|