@graphcommerce/next-ui 10.1.0-canary.5 → 10.1.0-canary.7

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,13 @@
1
1
  # Change Log
2
2
 
3
+ ## 10.1.0-canary.7
4
+
5
+ ### Patch Changes
6
+
7
+ - [#2610](https://github.com/graphcommerce-org/graphcommerce/pull/2610) [`7b6ba3f`](https://github.com/graphcommerce-org/graphcommerce/commit/7b6ba3fc5367f0b01df302d98b6ab55cc89b051f) - Fix duplicate React key warning in `<NumberFormat>` / `<CurrencyFormat>` / `<Money>` for numbers with a thousands group separator. `Intl.NumberFormat.formatToParts()` emits multiple parts with `type: "integer"` (one per group, e.g. `1.234,56` produces two `integer` parts). Using `key={part.type}` therefore collided. Switched to an index key — parts are already wrapped in `suppressHydrationWarning`, so SSR/client divergence isn't an issue. ([@paales](https://github.com/paales))
8
+
9
+ ## 10.1.0-canary.6
10
+
3
11
  ## 10.1.0-canary.5
4
12
 
5
13
  ## 10.1.0-canary.4
@@ -17,8 +17,9 @@ export const NumberFormat = forwardRef<HTMLSpanElement, NumberFormatProps>((prop
17
17
 
18
18
  return (
19
19
  <Box component='span' className='NumberFormat' suppressHydrationWarning ref={ref} sx={sx}>
20
- {formatter.formatToParts(value).map((part) => (
21
- <span className={part.type} key={part.type} suppressHydrationWarning>
20
+ {formatter.formatToParts(value).map((part, i) => (
21
+ // eslint-disable-next-line react/no-array-index-key
22
+ <span className={part.type} key={i} suppressHydrationWarning>
22
23
  {part.value}
23
24
  </span>
24
25
  ))}
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@graphcommerce/next-ui",
3
3
  "homepage": "https://www.graphcommerce.org/",
4
4
  "repository": "github:graphcommerce-org/graphcommerce",
5
- "version": "10.1.0-canary.5",
5
+ "version": "10.1.0-canary.7",
6
6
  "sideEffects": false,
7
7
  "prettier": "@graphcommerce/prettier-config-pwa",
8
8
  "eslintConfig": {
@@ -43,13 +43,13 @@
43
43
  "@emotion/react": "^11.14.0",
44
44
  "@emotion/server": "^11.11.0",
45
45
  "@emotion/styled": "^11.14.1",
46
- "@graphcommerce/eslint-config-pwa": "^10.1.0-canary.5",
47
- "@graphcommerce/framer-next-pages": "^10.1.0-canary.5",
48
- "@graphcommerce/framer-scroller": "^10.1.0-canary.5",
49
- "@graphcommerce/framer-utils": "^10.1.0-canary.5",
50
- "@graphcommerce/image": "^10.1.0-canary.5",
51
- "@graphcommerce/prettier-config-pwa": "^10.1.0-canary.5",
52
- "@graphcommerce/typescript-config-pwa": "^10.1.0-canary.5",
46
+ "@graphcommerce/eslint-config-pwa": "^10.1.0-canary.7",
47
+ "@graphcommerce/framer-next-pages": "^10.1.0-canary.7",
48
+ "@graphcommerce/framer-scroller": "^10.1.0-canary.7",
49
+ "@graphcommerce/framer-utils": "^10.1.0-canary.7",
50
+ "@graphcommerce/image": "^10.1.0-canary.7",
51
+ "@graphcommerce/prettier-config-pwa": "^10.1.0-canary.7",
52
+ "@graphcommerce/typescript-config-pwa": "^10.1.0-canary.7",
53
53
  "@lingui/core": "^5",
54
54
  "@lingui/macro": "^5",
55
55
  "@lingui/react": "^5",