From 7ce83dde99498598a20dc6628a162ab6701315c0 Mon Sep 17 00:00:00 2001 From: Ed Spencer Date: Fri, 23 Aug 2024 17:58:06 -0400 Subject: [PATCH] Fix dependencies --- .changeset/tricky-ghosts-tickle.md | 5 + package.json | 25 ++- pnpm-lock.yaml | 280 ++++++++++++----------------- src/test/InformAIContext.test.tsx | 14 +- 4 files changed, 136 insertions(+), 188 deletions(-) create mode 100644 .changeset/tricky-ghosts-tickle.md diff --git a/.changeset/tricky-ghosts-tickle.md b/.changeset/tricky-ghosts-tickle.md new file mode 100644 index 0000000..e61ad92 --- /dev/null +++ b/.changeset/tricky-ghosts-tickle.md @@ -0,0 +1,5 @@ +--- +"inform-ai": patch +--- + +Rearrange dependencies, devDependencies and peerDependencies diff --git a/package.json b/package.json index d23bc7c..dda768d 100644 --- a/package.json +++ b/package.json @@ -31,12 +31,14 @@ "@jest/globals": "^29.7.0", "@rollup/plugin-commonjs": "^26.0.1", "@rollup/plugin-node-resolve": "^15.2.3", + "@testing-library/dom": "^10.4.0", "@testing-library/jest-dom": "^6.4.8", + "@testing-library/react": "^16.0.0", "@types/jest": "^29.5.12", - "@types/react": "npm:types-react@19.0.0-rc.1", - "@types/react-dom": "npm:types-react-dom@19.0.0-rc.1", + "@types/react": "^18.3.4", + "@types/react-dom": "^18.3.0", "@types/uuid": "^10.0.0", - "ai": "^3.3.6", + "ai": "^3.3.17", "autoprefixer": "^10.4.20", "concurrently": "^8.2.2", "eslint": "^8.57.0", @@ -46,8 +48,11 @@ "jest": "^29.7.0", "jest-environment-jsdom": "^29.7.0", "postcss": "^8.4.41", + "react": "^18 || ^19", + "react-dom": "^18 || ^19", "rollup": "^4.20.0", "rollup-plugin-peer-deps-external": "^2.2.4", + "rollup-plugin-postcss": "^4.0.2", "rollup-plugin-typescript2": "^0.36.0", "tailwindcss": "^3.4.9", "ts-jest": "^29.2.4", @@ -55,19 +60,13 @@ "typescript": "^5.5.4" }, "dependencies": { - "@ai-sdk/openai": "^0.0.44", - "@testing-library/dom": "^10.4.0", - "@testing-library/react": "^16.0.0", "clsx": "^2.1.1", - "nanoid": "^5.0.7", - "react": "19.0.0-rc-cc1ec60d0d-20240607", - "react-dom": "19.0.0-rc-cc1ec60d0d-20240607", "react18-json-view": "^0.2.8", - "rollup-plugin-postcss": "^4.0.2", - "uuid": "^10.0.0", - "zod": "^3.23.8" + "uuid": "^10.0.0" }, "peerDependencies": { - "ai": "^3.3.6" + "ai": "^3.3.17", + "react": "^18 || ^19", + "react-dom": "^18 || ^19" } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index ddc6573..8161e4f 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -8,39 +8,15 @@ importers: .: dependencies: - '@ai-sdk/openai': - specifier: ^0.0.44 - version: 0.0.44(zod@3.23.8) - '@testing-library/dom': - specifier: ^10.4.0 - version: 10.4.0 - '@testing-library/react': - specifier: ^16.0.0 - version: 16.0.0(@testing-library/dom@10.4.0)(react-dom@19.0.0-rc-cc1ec60d0d-20240607(react@19.0.0-rc-cc1ec60d0d-20240607))(react@19.0.0-rc-cc1ec60d0d-20240607)(types-react-dom@19.0.0-rc.1)(types-react@19.0.0-rc.1) clsx: specifier: ^2.1.1 version: 2.1.1 - nanoid: - specifier: ^5.0.7 - version: 5.0.7 - react: - specifier: 19.0.0-rc-cc1ec60d0d-20240607 - version: 19.0.0-rc-cc1ec60d0d-20240607 - react-dom: - specifier: 19.0.0-rc-cc1ec60d0d-20240607 - version: 19.0.0-rc-cc1ec60d0d-20240607(react@19.0.0-rc-cc1ec60d0d-20240607) react18-json-view: specifier: ^0.2.8 - version: 0.2.8(react@19.0.0-rc-cc1ec60d0d-20240607) - rollup-plugin-postcss: - specifier: ^4.0.2 - version: 4.0.2(postcss@8.4.41)(ts-node@10.9.2(@types/node@12.20.55)(typescript@5.5.4)) + version: 0.2.8(react@18.3.1) uuid: specifier: ^10.0.0 version: 10.0.0 - zod: - specifier: ^3.23.8 - version: 3.23.8 devDependencies: '@changesets/cli': specifier: ^2.27.7 @@ -54,24 +30,30 @@ importers: '@rollup/plugin-node-resolve': specifier: ^15.2.3 version: 15.2.3(rollup@4.20.0) + '@testing-library/dom': + specifier: ^10.4.0 + version: 10.4.0 '@testing-library/jest-dom': specifier: ^6.4.8 version: 6.4.8 + '@testing-library/react': + specifier: ^16.0.0 + version: 16.0.0(@testing-library/dom@10.4.0)(@types/react-dom@18.3.0)(@types/react@18.3.4)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) '@types/jest': specifier: ^29.5.12 version: 29.5.12 '@types/react': - specifier: npm:types-react@19.0.0-rc.1 - version: types-react@19.0.0-rc.1 + specifier: ^18.3.4 + version: 18.3.4 '@types/react-dom': - specifier: npm:types-react-dom@19.0.0-rc.1 - version: types-react-dom@19.0.0-rc.1 + specifier: ^18.3.0 + version: 18.3.0 '@types/uuid': specifier: ^10.0.0 version: 10.0.0 ai: - specifier: ^3.3.6 - version: 3.3.6(react@19.0.0-rc-cc1ec60d0d-20240607)(sswr@2.1.0(svelte@4.2.18))(svelte@4.2.18)(vue@3.4.37(typescript@5.5.4))(zod@3.23.8) + specifier: ^3.3.17 + version: 3.3.17(react@18.3.1)(sswr@2.1.0(svelte@4.2.18))(svelte@4.2.18)(vue@3.4.37(typescript@5.5.4))(zod@3.23.8) autoprefixer: specifier: ^10.4.20 version: 10.4.20(postcss@8.4.41) @@ -99,12 +81,21 @@ importers: postcss: specifier: ^8.4.41 version: 8.4.41 + react: + specifier: ^18 || ^19 + version: 18.3.1 + react-dom: + specifier: ^18 || ^19 + version: 18.3.1(react@18.3.1) rollup: specifier: ^4.20.0 version: 4.20.0 rollup-plugin-peer-deps-external: specifier: ^2.2.4 version: 2.2.4(rollup@4.20.0) + rollup-plugin-postcss: + specifier: ^4.0.2 + version: 4.0.2(postcss@8.4.41)(ts-node@10.9.2(@types/node@12.20.55)(typescript@5.5.4)) rollup-plugin-typescript2: specifier: ^0.36.0 version: 0.36.0(rollup@4.20.0)(typescript@5.5.4) @@ -126,14 +117,8 @@ packages: '@adobe/css-tools@4.4.0': resolution: {integrity: sha512-Ff9+ksdQQB3rMncgqDK78uLznstjyfIf2Arnh22pW8kBpLs6rpKDwgnZT46hin5Hl1WzazzK64DOrhSwYpS7bQ==} - '@ai-sdk/openai@0.0.44': - resolution: {integrity: sha512-fIUypicSnuWIOdoRG+dgzAnZDWQrhzqyUvQaLC8hQB6UDAUXkn8sIPdsqKEV35vs3mNXDz/KZ4EEeLxSVGrzMg==} - engines: {node: '>=18'} - peerDependencies: - zod: ^3.0.0 - - '@ai-sdk/provider-utils@1.0.10': - resolution: {integrity: sha512-xciXF2PorLQMNdhYe+n9CafVkXZANHURsME85RXjtAoZSs631l2t8Blqwz2C/pHUb9bxLdMRRuIEB4PnHLnHvQ==} + '@ai-sdk/provider-utils@1.0.16': + resolution: {integrity: sha512-8Nd8vIkGTIthhfgJEdP9KyMlykehBNP/1J47eMC3vQqYgJV6r5Bgvl3LFVfWi9KzamiD8tp9nU2NJKTeo4MH/A==} engines: {node: '>=18'} peerDependencies: zod: ^3.0.0 @@ -141,25 +126,12 @@ packages: zod: optional: true - '@ai-sdk/provider-utils@1.0.9': - resolution: {integrity: sha512-yfdanjUiCJbtGoRGXrcrmXn0pTyDfRIeY6ozDG96D66f2wupZaZvAgKptUa3zDYXtUCQQvcNJ+tipBBfQD/UYA==} - engines: {node: '>=18'} - peerDependencies: - zod: ^3.0.0 - peerDependenciesMeta: - zod: - optional: true - - '@ai-sdk/provider@0.0.17': - resolution: {integrity: sha512-f9j+P5yYRkqKFHxvWae5FI0j6nqROPCoPnMkpc2hc2vC7vKjqzrxBJucD8rpSaUjqiBnY/QuRJ0QeV717Uz5tg==} + '@ai-sdk/provider@0.0.21': + resolution: {integrity: sha512-9j95uaPRxwYkzQdkl4XO/MmWWW5c5vcVSXtqvALpD9SMB9fzH46dO3UN4VbOJR2J3Z84CZAqgZu5tNlkptT9qQ==} engines: {node: '>=18'} - '@ai-sdk/provider@0.0.18': - resolution: {integrity: sha512-LF4aUAKDTKIHa2e7ozwRJDMhUC9cs7t224sUilG1HfyFWyyh+01oPZwMob/hj111SozZkvXIukN0BIa+sXS0mw==} - engines: {node: '>=18'} - - '@ai-sdk/react@0.0.42': - resolution: {integrity: sha512-oiwXKLc5n7SwaTZWldMrpyJEWTgLh35NXuxQIGDGVHTIryxxMk9lgOQ+vQ8uri3WGMzGQQGRfwh8MTijJ8cN2A==} + '@ai-sdk/react@0.0.51': + resolution: {integrity: sha512-Hq5splFSB6OVovHamXvpnd1S7jfIz/CXWjaLo9sr90jd/W370NA8GhBd6oSLfqMeKrPosV4qRBH5S8lv2bauqA==} engines: {node: '>=18'} peerDependencies: react: ^18 || ^19 @@ -170,8 +142,8 @@ packages: zod: optional: true - '@ai-sdk/solid@0.0.33': - resolution: {integrity: sha512-6AV4g6IrQ7bPcfQgwOjNMT50W2lljk/sgzJ3qx+Bt/lobvhA7khyW1RVYTnxx3OBdf4/qB1D2BAAbUrrm/na8A==} + '@ai-sdk/solid@0.0.41': + resolution: {integrity: sha512-w4vSkd2388FJMnKPALP8SL4p3XAR70FAPj0qrd5AoYyQMMjX/E6zQGc8YAhAAnGSwiQwq/DZaE4y0lorwFVyOw==} engines: {node: '>=18'} peerDependencies: solid-js: ^1.7.7 @@ -179,8 +151,8 @@ packages: solid-js: optional: true - '@ai-sdk/svelte@0.0.35': - resolution: {integrity: sha512-vbDmvcu2MRZvvxoOtCUH8ydKSaugaQkhiBtZRp/U1YvSIuzR7xUkYSf0EQ173kWBWsaoPO9PFava0WxF7k1q4g==} + '@ai-sdk/svelte@0.0.43': + resolution: {integrity: sha512-lUve6AGc3dtue14LLGiZs7J7L/3jEHh6SGXwuG/nDygeicKPzmG9drWZlhTdpNHN9wKtBgrCdJxQ96HKswLDNA==} engines: {node: '>=18'} peerDependencies: svelte: ^3.0.0 || ^4.0.0 @@ -188,8 +160,8 @@ packages: svelte: optional: true - '@ai-sdk/ui-utils@0.0.30': - resolution: {integrity: sha512-ifmYSQtSVdeY1XlOFirAdbgWVnSg5hYPhG8bEiNI9TvR1HFdMN/zZhxscjLyKXXAelf/ACYvUjwNQmCnWSurZQ==} + '@ai-sdk/ui-utils@0.0.38': + resolution: {integrity: sha512-SyyfqBu7xnsfUuq3kSxzP+fxGCTMqaSL5WYGiBJpr/yLWySjBJCg/k7WueO440AqVpZBzCd3nWoCpPmjfMK8Yg==} engines: {node: '>=18'} peerDependencies: zod: ^3.0.0 @@ -197,8 +169,8 @@ packages: zod: optional: true - '@ai-sdk/vue@0.0.34': - resolution: {integrity: sha512-Nbht63i4NJrau5Yrf6dH6paH2mj/5CSmHopjA0IRHdOTvh3lKe382oZP2hLnN/xa575r25as67l7P/j/iq8ULQ==} + '@ai-sdk/vue@0.0.43': + resolution: {integrity: sha512-bJB7muMpmP/wPKbDU8GCmDpI1HSkuTWz9DsQ4ZlBaCk5wqRLKxRtzM9NxfeQ15RojSLxYhKf/lDwW10RPtjcaw==} engines: {node: '>=18'} peerDependencies: vue: ^3.3.4 @@ -810,8 +782,11 @@ packages: '@types/prop-types@15.7.12': resolution: {integrity: sha512-5zvhXYtRNRluoE/jAp4GVsSduVUzNWKkOZrCDBWYtE7biZywwdC2AcEzg+cSMLFRfVgeAFqpfNabiPjxFddV1Q==} - '@types/react@18.3.3': - resolution: {integrity: sha512-hti/R0pS0q1/xx+TsI73XIqk26eBsISZ2R0wUijXIngRK9R/e7Xw/cXVxQK7R5JjW+SV4zGcn5hXjudkN/pLIw==} + '@types/react-dom@18.3.0': + resolution: {integrity: sha512-EhwApuTmMBmXuFOikhQLIBUn6uFg81SwLMOAUgodJF14SOBOCMdU04gDoYi0WOJJHD144TL32z4yDqCW3dnkQg==} + + '@types/react@18.3.4': + resolution: {integrity: sha512-J7W30FTdfCxDDjmfRM+/JqLHBIyl7xUIp9kwK637FGmY7+mkSFSe6L4jpZzhj5QMfLssSDP4/i75AKkrdC7/Jw==} '@types/resolve@1.20.2': resolution: {integrity: sha512-60BCwRFOZCQhDncwQdxxeOEEkbc5dIMccYLwbxsS4TUNeVECQ/pBJ0j09mrHOl/JJvpRPGwO9SvE4nR2Nb/a4Q==} @@ -891,8 +866,8 @@ packages: resolution: {integrity: sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==} engines: {node: '>= 6.0.0'} - ai@3.3.6: - resolution: {integrity: sha512-XrbjYyugNF0SlTEVAO8B7tlW6iW47+DYk1hkyGj0vwp93J0F19bdrtN6NbFJOzSHj/R4FGvGk0IPQz5A3Eq1IQ==} + ai@3.3.17: + resolution: {integrity: sha512-Z3cPRImctE8GMZV0e15ZlO+bqfLlVWqO+JiShJT20l3iYlZYwsQMQXjt5hiF3m7+VvbzIq+ORdp1Ai11GxzBVQ==} engines: {node: '>=18'} peerDependencies: openai: ^4.42.0 @@ -2427,11 +2402,6 @@ packages: engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} hasBin: true - nanoid@5.0.7: - resolution: {integrity: sha512-oLxFY2gd2IqnjcYyOXD8XGCftpGtZP2AbHbOkthDkvRywH5ayNtPVy9YlOPcHckXzbLTCHpkb7FB+yuxKV13pQ==} - engines: {node: ^18 || >=20} - hasBin: true - natural-compare@1.4.0: resolution: {integrity: sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==} @@ -2918,10 +2888,10 @@ packages: queue-microtask@1.2.3: resolution: {integrity: sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==} - react-dom@19.0.0-rc-cc1ec60d0d-20240607: - resolution: {integrity: sha512-paspD9kAfKKuURVwKWJ0/g3qYw1DGi9h1k9xQV2iQN9cSVZ4JAOD727yjVLyp1zdzsoygjFfLMtSBdZ+oERYvA==} + react-dom@18.3.1: + resolution: {integrity: sha512-5m4nQKp+rZRb09LNH59GM4BxTh9251/ylbKIbpe7TpGxfJ+9kv6BLkLBXIjjspbgbnIBNqlI23tRnTWT0snUIw==} peerDependencies: - react: 19.0.0-rc-cc1ec60d0d-20240607 + react: ^18.3.1 react-is@16.13.1: resolution: {integrity: sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==} @@ -2937,8 +2907,8 @@ packages: peerDependencies: react: '>=16.8.0' - react@19.0.0-rc-cc1ec60d0d-20240607: - resolution: {integrity: sha512-q8A0/IdJ2wdHsjDNO1igFcSSFIMqSKmO7oJZtAjxIA9g0klK45Lxt15NQJ7z7cBvgD1r3xRTtQ/MAqnmwYHs1Q==} + react@18.3.1: + resolution: {integrity: sha512-wS+hAgJShR0KhEvPJArfuPVN1+Hz1t0Y6n5jLrGQbkb4urgPE/0Rve+1kMB1v/oWgHgm4WIcV+i7F2pTVj+2iQ==} engines: {node: '>=0.10.0'} read-cache@1.0.0: @@ -3056,8 +3026,8 @@ packages: resolution: {integrity: sha512-xAg7SOnEhrm5zI3puOOKyy1OMcMlIJZYNJY7xLBwSze0UjhPLnWfj2GF2EpT0jmzaJKIWKHLsaSSajf35bcYnA==} engines: {node: '>=v12.22.7'} - scheduler@0.25.0-rc-cc1ec60d0d-20240607: - resolution: {integrity: sha512-yFVKy6SDJkN2bOJSeH6gNo4+1MTygTZXnLRY5IHvEB6P9+O6WYRWz9PkELLjnl64lQwRgiigwzWQRSMNEboOGQ==} + scheduler@0.23.2: + resolution: {integrity: sha512-UOShsPwz7NrMUqhR6t0hWjFduvOzbtv7toDH1/hIrfRNIDBnnBWd0CwJTGvTpngVlmwGCdP9/Zl/tVrDqcuYzQ==} secure-json-parse@2.7.0: resolution: {integrity: sha512-6aU+Rwsezw7VR8/nyvKTx8QpWH9FrcYiXXlqC4z5d5XQBDRqtbfsRjnwGyqbi3gddNtWHuEk9OANUotL26qKUw==} @@ -3391,12 +3361,6 @@ packages: resolution: {integrity: sha512-/OxDN6OtAk5KBpGb28T+HZc2M+ADtvRxXrKKbUwtsLgdoxgX13hyy7ek6bFRl5+aBs2yZzB0c4CnQfAtVypW/g==} engines: {node: '>= 0.4'} - types-react-dom@19.0.0-rc.1: - resolution: {integrity: sha512-VSLZJl8VXCD0fAWp7DUTFUDCcZ8DVXOQmjhJMD03odgeFmu14ZQJHCXeETm3BEAhJqfgJaFkLnGkQv88sRx0fQ==} - - types-react@19.0.0-rc.1: - resolution: {integrity: sha512-RshndUfqTW6K3STLPis8BtAYCGOkMbtvYsi90gmVNDZBXUyUc5juf2PE9LfS/JmOlUIRO8cWTS/1MTnmhjDqyQ==} - typescript@5.5.4: resolution: {integrity: sha512-Mtq29sKDAEYP7aljRgtPOpTvOfbwRWlS6dPRzwjdE+C0R4brX/GUyhHSecbHMFLNBLcJIPt9nl9yG5TZ1weH+Q==} engines: {node: '>=14.17'} @@ -3580,10 +3544,10 @@ packages: resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} engines: {node: '>=10'} - zod-to-json-schema@3.22.5: - resolution: {integrity: sha512-+akaPo6a0zpVCCseDed504KBJUQpEW5QZw7RMneNmKw+fGaML1Z9tUNLnHHAC8x6dzVRO1eB2oEMyZRnuBZg7Q==} + zod-to-json-schema@3.23.2: + resolution: {integrity: sha512-uSt90Gzc/tUfyNqxnjlfBs8W6WSGpNBv0rVsNxP/BVSMHMKGdthPYff4xtCHYloJGM0CFxFsb3NbC0eqPhfImw==} peerDependencies: - zod: ^3.22.4 + zod: ^3.23.3 zod@3.23.8: resolution: {integrity: sha512-XBx9AXhXktjUqnepgTiE5flcKIYWi/rme0Eaj+5Y0lftuGBq+jyRu/md4WnuxqgP1ubdpNCsYEYPxrzVHD8d6g==} @@ -3592,78 +3556,59 @@ snapshots: '@adobe/css-tools@4.4.0': {} - '@ai-sdk/openai@0.0.44(zod@3.23.8)': - dependencies: - '@ai-sdk/provider': 0.0.17 - '@ai-sdk/provider-utils': 1.0.9(zod@3.23.8) - zod: 3.23.8 - - '@ai-sdk/provider-utils@1.0.10(zod@3.23.8)': - dependencies: - '@ai-sdk/provider': 0.0.18 - eventsource-parser: 1.1.2 - nanoid: 3.3.6 - secure-json-parse: 2.7.0 - optionalDependencies: - zod: 3.23.8 - - '@ai-sdk/provider-utils@1.0.9(zod@3.23.8)': + '@ai-sdk/provider-utils@1.0.16(zod@3.23.8)': dependencies: - '@ai-sdk/provider': 0.0.17 + '@ai-sdk/provider': 0.0.21 eventsource-parser: 1.1.2 nanoid: 3.3.6 secure-json-parse: 2.7.0 optionalDependencies: zod: 3.23.8 - '@ai-sdk/provider@0.0.17': + '@ai-sdk/provider@0.0.21': dependencies: json-schema: 0.4.0 - '@ai-sdk/provider@0.0.18': + '@ai-sdk/react@0.0.51(react@18.3.1)(zod@3.23.8)': dependencies: - json-schema: 0.4.0 - - '@ai-sdk/react@0.0.42(react@19.0.0-rc-cc1ec60d0d-20240607)(zod@3.23.8)': - dependencies: - '@ai-sdk/provider-utils': 1.0.10(zod@3.23.8) - '@ai-sdk/ui-utils': 0.0.30(zod@3.23.8) - swr: 2.2.5(react@19.0.0-rc-cc1ec60d0d-20240607) + '@ai-sdk/provider-utils': 1.0.16(zod@3.23.8) + '@ai-sdk/ui-utils': 0.0.38(zod@3.23.8) + swr: 2.2.5(react@18.3.1) optionalDependencies: - react: 19.0.0-rc-cc1ec60d0d-20240607 + react: 18.3.1 zod: 3.23.8 - '@ai-sdk/solid@0.0.33(zod@3.23.8)': + '@ai-sdk/solid@0.0.41(zod@3.23.8)': dependencies: - '@ai-sdk/provider-utils': 1.0.10(zod@3.23.8) - '@ai-sdk/ui-utils': 0.0.30(zod@3.23.8) + '@ai-sdk/provider-utils': 1.0.16(zod@3.23.8) + '@ai-sdk/ui-utils': 0.0.38(zod@3.23.8) transitivePeerDependencies: - zod - '@ai-sdk/svelte@0.0.35(svelte@4.2.18)(zod@3.23.8)': + '@ai-sdk/svelte@0.0.43(svelte@4.2.18)(zod@3.23.8)': dependencies: - '@ai-sdk/provider-utils': 1.0.10(zod@3.23.8) - '@ai-sdk/ui-utils': 0.0.30(zod@3.23.8) + '@ai-sdk/provider-utils': 1.0.16(zod@3.23.8) + '@ai-sdk/ui-utils': 0.0.38(zod@3.23.8) sswr: 2.1.0(svelte@4.2.18) optionalDependencies: svelte: 4.2.18 transitivePeerDependencies: - zod - '@ai-sdk/ui-utils@0.0.30(zod@3.23.8)': + '@ai-sdk/ui-utils@0.0.38(zod@3.23.8)': dependencies: - '@ai-sdk/provider': 0.0.18 - '@ai-sdk/provider-utils': 1.0.10(zod@3.23.8) + '@ai-sdk/provider': 0.0.21 + '@ai-sdk/provider-utils': 1.0.16(zod@3.23.8) json-schema: 0.4.0 secure-json-parse: 2.7.0 - zod-to-json-schema: 3.22.5(zod@3.23.8) + zod-to-json-schema: 3.23.2(zod@3.23.8) optionalDependencies: zod: 3.23.8 - '@ai-sdk/vue@0.0.34(vue@3.4.37(typescript@5.5.4))(zod@3.23.8)': + '@ai-sdk/vue@0.0.43(vue@3.4.37(typescript@5.5.4))(zod@3.23.8)': dependencies: - '@ai-sdk/provider-utils': 1.0.10(zod@3.23.8) - '@ai-sdk/ui-utils': 0.0.30(zod@3.23.8) + '@ai-sdk/provider-utils': 1.0.16(zod@3.23.8) + '@ai-sdk/ui-utils': 0.0.38(zod@3.23.8) swrv: 1.0.4(vue@3.4.37(typescript@5.5.4)) optionalDependencies: vue: 3.4.37(typescript@5.5.4) @@ -4428,15 +4373,15 @@ snapshots: lodash: 4.17.21 redent: 3.0.0 - '@testing-library/react@16.0.0(@testing-library/dom@10.4.0)(react-dom@19.0.0-rc-cc1ec60d0d-20240607(react@19.0.0-rc-cc1ec60d0d-20240607))(react@19.0.0-rc-cc1ec60d0d-20240607)(types-react-dom@19.0.0-rc.1)(types-react@19.0.0-rc.1)': + '@testing-library/react@16.0.0(@testing-library/dom@10.4.0)(@types/react-dom@18.3.0)(@types/react@18.3.4)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: '@babel/runtime': 7.25.0 '@testing-library/dom': 10.4.0 - react: 19.0.0-rc-cc1ec60d0d-20240607 - react-dom: 19.0.0-rc-cc1ec60d0d-20240607(react@19.0.0-rc-cc1ec60d0d-20240607) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) optionalDependencies: - '@types/react': types-react@19.0.0-rc.1 - '@types/react-dom': types-react-dom@19.0.0-rc.1 + '@types/react': 18.3.4 + '@types/react-dom': 18.3.0 '@tootallnate/once@2.0.0': {} @@ -4506,7 +4451,11 @@ snapshots: '@types/prop-types@15.7.12': {} - '@types/react@18.3.3': + '@types/react-dom@18.3.0': + dependencies: + '@types/react': 18.3.4 + + '@types/react@18.3.4': dependencies: '@types/prop-types': 15.7.12 csstype: 3.1.3 @@ -4606,24 +4555,24 @@ snapshots: transitivePeerDependencies: - supports-color - ai@3.3.6(react@19.0.0-rc-cc1ec60d0d-20240607)(sswr@2.1.0(svelte@4.2.18))(svelte@4.2.18)(vue@3.4.37(typescript@5.5.4))(zod@3.23.8): + ai@3.3.17(react@18.3.1)(sswr@2.1.0(svelte@4.2.18))(svelte@4.2.18)(vue@3.4.37(typescript@5.5.4))(zod@3.23.8): dependencies: - '@ai-sdk/provider': 0.0.18 - '@ai-sdk/provider-utils': 1.0.10(zod@3.23.8) - '@ai-sdk/react': 0.0.42(react@19.0.0-rc-cc1ec60d0d-20240607)(zod@3.23.8) - '@ai-sdk/solid': 0.0.33(zod@3.23.8) - '@ai-sdk/svelte': 0.0.35(svelte@4.2.18)(zod@3.23.8) - '@ai-sdk/ui-utils': 0.0.30(zod@3.23.8) - '@ai-sdk/vue': 0.0.34(vue@3.4.37(typescript@5.5.4))(zod@3.23.8) + '@ai-sdk/provider': 0.0.21 + '@ai-sdk/provider-utils': 1.0.16(zod@3.23.8) + '@ai-sdk/react': 0.0.51(react@18.3.1)(zod@3.23.8) + '@ai-sdk/solid': 0.0.41(zod@3.23.8) + '@ai-sdk/svelte': 0.0.43(svelte@4.2.18)(zod@3.23.8) + '@ai-sdk/ui-utils': 0.0.38(zod@3.23.8) + '@ai-sdk/vue': 0.0.43(vue@3.4.37(typescript@5.5.4))(zod@3.23.8) '@opentelemetry/api': 1.9.0 eventsource-parser: 1.1.2 json-schema: 0.4.0 jsondiffpatch: 0.6.0 nanoid: 3.3.6 secure-json-parse: 2.7.0 - zod-to-json-schema: 3.22.5(zod@3.23.8) + zod-to-json-schema: 3.23.2(zod@3.23.8) optionalDependencies: - react: 19.0.0-rc-cc1ec60d0d-20240607 + react: 18.3.1 sswr: 2.1.0(svelte@4.2.18) svelte: 4.2.18 zod: 3.23.8 @@ -6516,8 +6465,6 @@ snapshots: nanoid@3.3.7: {} - nanoid@5.0.7: {} - natural-compare@1.4.0: {} node-int64@0.4.0: {} @@ -6961,10 +6908,11 @@ snapshots: queue-microtask@1.2.3: {} - react-dom@19.0.0-rc-cc1ec60d0d-20240607(react@19.0.0-rc-cc1ec60d0d-20240607): + react-dom@18.3.1(react@18.3.1): dependencies: - react: 19.0.0-rc-cc1ec60d0d-20240607 - scheduler: 0.25.0-rc-cc1ec60d0d-20240607 + loose-envify: 1.4.0 + react: 18.3.1 + scheduler: 0.23.2 react-is@16.13.1: {} @@ -6972,11 +6920,13 @@ snapshots: react-is@18.3.1: {} - react18-json-view@0.2.8(react@19.0.0-rc-cc1ec60d0d-20240607): + react18-json-view@0.2.8(react@18.3.1): dependencies: - react: 19.0.0-rc-cc1ec60d0d-20240607 + react: 18.3.1 - react@19.0.0-rc-cc1ec60d0d-20240607: {} + react@18.3.1: + dependencies: + loose-envify: 1.4.0 read-cache@1.0.0: dependencies: @@ -7137,7 +7087,9 @@ snapshots: dependencies: xmlchars: 2.2.0 - scheduler@0.25.0-rc-cc1ec60d0d-20240607: {} + scheduler@0.23.2: + dependencies: + loose-envify: 1.4.0 secure-json-parse@2.7.0: {} @@ -7356,11 +7308,11 @@ snapshots: picocolors: 1.0.1 stable: 0.1.8 - swr@2.2.5(react@19.0.0-rc-cc1ec60d0d-20240607): + swr@2.2.5(react@18.3.1): dependencies: client-only: 0.0.1 - react: 19.0.0-rc-cc1ec60d0d-20240607 - use-sync-external-store: 1.2.2(react@19.0.0-rc-cc1ec60d0d-20240607) + react: 18.3.1 + use-sync-external-store: 1.2.2(react@18.3.1) swrev@4.0.0: {} @@ -7523,14 +7475,6 @@ snapshots: is-typed-array: 1.1.13 possible-typed-array-names: 1.0.0 - types-react-dom@19.0.0-rc.1: - dependencies: - '@types/react': 18.3.3 - - types-react@19.0.0-rc.1: - dependencies: - csstype: 3.1.3 - typescript@5.5.4: {} unbox-primitive@1.0.2: @@ -7561,9 +7505,9 @@ snapshots: querystringify: 2.2.0 requires-port: 1.0.0 - use-sync-external-store@1.2.2(react@19.0.0-rc-cc1ec60d0d-20240607): + use-sync-external-store@1.2.2(react@18.3.1): dependencies: - react: 19.0.0-rc-cc1ec60d0d-20240607 + react: 18.3.1 util-deprecate@1.0.2: {} @@ -7712,7 +7656,7 @@ snapshots: yocto-queue@0.1.0: {} - zod-to-json-schema@3.22.5(zod@3.23.8): + zod-to-json-schema@3.23.2(zod@3.23.8): dependencies: zod: 3.23.8 diff --git a/src/test/InformAIContext.test.tsx b/src/test/InformAIContext.test.tsx index 5875ea2..989fe92 100644 --- a/src/test/InformAIContext.test.tsx +++ b/src/test/InformAIContext.test.tsx @@ -136,15 +136,15 @@ describe("InformAIProvider", () => { }); it("throws error when useInformAIContext is used outside of provider", () => { - const renderOutsideProvider = () => { - const TestComponent = () => { - useInformAIContext(); - return null; - }; + const consoleError = jest.spyOn(console, "error").mockImplementation(() => {}); - render(); + const TestComponent = () => { + useInformAIContext(); + return null; }; - expect(renderOutsideProvider).toThrow("useInformAIContext must be used within an InformAIProvider"); + expect(() => render()).toThrow("useInformAIContext must be used within an InformAIProvider"); + + consoleError.mockRestore(); // Restore the original console.error behavior }); });