diff --git a/.changeset/cozy-teeth-speak.md b/.changeset/cozy-teeth-speak.md new file mode 100644 index 0000000000000..c0a9c6aa9631a --- /dev/null +++ b/.changeset/cozy-teeth-speak.md @@ -0,0 +1,5 @@ +--- +'@node-core/ui-components': patch +--- + +Move react to peerDependencies and devDependencies to fix runtime duplicate hooks error in consumer applications diff --git a/packages/ui-components/package.json b/packages/ui-components/package.json index db216390090a9..eff2282237a90 100644 --- a/packages/ui-components/package.json +++ b/packages/ui-components/package.json @@ -61,8 +61,7 @@ "@radix-ui/react-tabs": "^1.1.18", "@radix-ui/react-tooltip": "^1.2.13", "@vcarl/remark-headings": "~0.1.0", - "classnames": "catalog:", - "react": "catalog:" + "classnames": "catalog:" }, "devDependencies": { "@eslint-react/eslint-plugin": "~5.8.6", @@ -86,6 +85,7 @@ "postcss-calc": "~11.2.1", "postcss-cli": "^11.0.1", "postcss-loader": "8.2.1", + "react": "catalog:", "storybook": "~10.6.0", "style-loader": "4.0.0", "stylelint": "17.14.1", @@ -96,6 +96,9 @@ "tsx": "4.23.1", "typescript": "catalog:" }, + "peerDependencies": { + "react": "^19.0.0" + }, "imports": { "#ui/*": { "types": [ diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 539a0081be605..fb90fe055e568 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -389,7 +389,7 @@ importers: version: 1.62.0 '@testing-library/user-event': specifier: ~14.6.1 - version: 14.6.1(@testing-library/dom@10.4.1) + version: 14.6.7(@testing-library/dom@10.4.1) '@types/mdast': specifier: ^4.0.4 version: 4.0.4 @@ -650,9 +650,6 @@ importers: classnames: specifier: 'catalog:' version: 2.5.1 - react: - specifier: 'catalog:' - version: 19.3.0 devDependencies: '@eslint-react/eslint-plugin': specifier: ~5.8.6 @@ -680,7 +677,7 @@ importers: version: 4.3.3 '@testing-library/user-event': specifier: ~14.6.1 - version: 14.6.1(@testing-library/dom@10.4.1) + version: 14.6.7(@testing-library/dom@10.4.1) '@types/node': specifier: 'catalog:' version: 24.10.1 @@ -717,6 +714,9 @@ importers: postcss-loader: specifier: 8.2.1 version: 8.2.1(postcss@8.5.28)(typescript@5.9.3)(webpack@5.109.2(@swc/core@1.15.40(@swc/helpers@0.5.23))(clean-css@5.3.3)(esbuild@0.28.1)(html-minifier-terser@6.1.0)(lightningcss@1.32.0)(postcss@8.5.28)(uglify-js@3.19.3)) + react: + specifier: 'catalog:' + version: 19.3.0 storybook: specifier: ~10.6.0 version: 10.6.0(@types/react@19.3.0)(prettier@3.9.6)(react@19.3.0) @@ -4780,12 +4780,6 @@ packages: '@types/react-dom': optional: true - '@testing-library/user-event@14.6.1': - resolution: {integrity: sha512-vq7fv0rnt+QTXgPxr5Hjc210p6YKq2kmdziLgnsZGgLJ9e6VAShx1pACLuRjd/AS/sr7phAR58OIIpf0LlmQNw==} - engines: {node: '>=12', npm: '>=6'} - peerDependencies: - '@testing-library/dom': '>=7.21.4' - '@testing-library/user-event@14.6.7': resolution: {integrity: sha512-MPCpX8bxe8zS+JmmTwLp8jd0dy1rAm60Te/SL8JrQM3qvQJcBOs1d7IefJMyZzqM3EWBrDn/LWDt1BCGu4ASfg==} engines: {node: '>=12', npm: '>=6'} @@ -5390,11 +5384,6 @@ packages: ajv-formats@2.1.1: resolution: {integrity: sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA==} - peerDependencies: - ajv: ^8.0.0 - peerDependenciesMeta: - ajv: - optional: true ajv-keywords@3.5.2: resolution: {integrity: sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ==} @@ -5418,7 +5407,6 @@ packages: ansi-html-community@0.0.8: resolution: {integrity: sha512-1APHAyr3+PCamwNw3bXCPp4HFLONZt/yIH0sZp0/469KWNTEy+qN5jQ3GVX6DMZ1UXAi34yVwtTeaG/HpBuuzw==} - engines: {'0': node >= 0.8.0} hasBin: true ansi-regex@5.0.1: @@ -5765,7 +5753,6 @@ packages: concat-stream@2.0.0: resolution: {integrity: sha512-MWufYdFw53ccGjCA+Ol7XJYpAlW6/prSMzuPOTRnJGcGzuhLn4Scrz7qf6o8bROZ514ltazcIFJZevcfbo0x7A==} - engines: {'0': node >= 6.0} concurrently@9.2.1: resolution: {integrity: sha512-fsfrO0MxV64Znoy8/l1vVIjjHa29SZyyqPgQBwhiDcaW8wJc2W3XWVOGx4M3oJBnv/zdUZIIp1gDeS98GzP8Ng==} @@ -13864,10 +13851,6 @@ snapshots: optionalDependencies: '@types/react': 19.3.0 - '@testing-library/user-event@14.6.1(@testing-library/dom@10.4.1)': - dependencies: - '@testing-library/dom': 10.4.1 - '@testing-library/user-event@14.6.7(@testing-library/dom@10.4.1)': dependencies: '@testing-library/dom': 10.4.1 @@ -14474,8 +14457,8 @@ snapshots: '@ai-sdk/provider-utils': 5.0.30(zod@4.4.3) zod: 4.4.3 - ajv-formats@2.1.1(ajv@8.20.0): - optionalDependencies: + ajv-formats@2.1.1: + dependencies: ajv: 8.20.0 ajv-keywords@3.5.2(ajv@6.15.0): @@ -18849,7 +18832,7 @@ snapshots: dependencies: '@types/json-schema': 7.0.15 ajv: 8.20.0 - ajv-formats: 2.1.1(ajv@8.20.0) + ajv-formats: 2.1.1 ajv-keywords: 5.1.0(ajv@8.20.0) section-matter@1.0.0: