diff --git a/package-lock.json b/package-lock.json index e62db041b..28edd47f0 100644 --- a/package-lock.json +++ b/package-lock.json @@ -16,14 +16,14 @@ "@icp-sdk/auth": "^5.0.0", "@icp-sdk/canisters": "^3.5.2", "@icp-sdk/core": "5.2.1", - "@junobuild/admin": "^4.3.2", - "@junobuild/auth": "^4.1.1", - "@junobuild/cdn": "^2.4.2", - "@junobuild/core": "^5.3.1", - "@junobuild/ic-client": "^8.1.2", - "@junobuild/schema": "^1.2.1", - "@junobuild/storage": "^2.4.1", - "@junobuild/utils": "^1.0.2", + "@junobuild/admin": "^4.3.3", + "@junobuild/auth": "^4.1.2", + "@junobuild/cdn": "^2.5.0", + "@junobuild/core": "^5.4.0", + "@junobuild/ic-client": "^8.1.3", + "@junobuild/schema": "^1.2.3", + "@junobuild/storage": "^2.4.2", + "@junobuild/utils": "^1.0.3", "@zip.js/zip.js": "^2.8.26", "date-fns": "^4.1.0", "dompurify": "^3.3.3", @@ -41,11 +41,11 @@ "@dfinity/pic": "^0.21.0", "@dfinity/response-verification": "^3.0.4", "@icp-sdk/bindgen": "^0.3.0", - "@junobuild/cli-tools": "^0.13.3", - "@junobuild/config": "^2.15.1", - "@junobuild/config-loader": "^0.4.10", - "@junobuild/errors": "^0.2.6", - "@junobuild/functions": "^0.8.2", + "@junobuild/cli-tools": "^0.14.0", + "@junobuild/config": "^3.0.0", + "@junobuild/config-loader": "^0.4.11", + "@junobuild/errors": "^0.2.8", + "@junobuild/functions": "^0.8.3", "@ltd/j-toml": "^1.38.0", "@playwright/test": "^1.59.1", "@sveltejs/adapter-static": "^3.0.10", @@ -2172,9 +2172,9 @@ } }, "node_modules/@junobuild/admin": { - "version": "4.3.2", - "resolved": "https://registry.npmjs.org/@junobuild/admin/-/admin-4.3.2.tgz", - "integrity": "sha512-RY78gfIyMwfMljoa01vM6A7VXdqcLftIrxog9NCAoOH/51JsCck5YTsS9VoAqUqk0AMtztVCgy67W/e7N0k8mw==", + "version": "4.3.3", + "resolved": "https://registry.npmjs.org/@junobuild/admin/-/admin-4.3.3.tgz", + "integrity": "sha512-l8cgcctrt7lBazFWPeBwZs1HtiERnDi5CulBomPe6th8cakjcuPVcbzO/ml1XlOIeDV+P4qyFyyw05iPJ3/taw==", "license": "MIT", "peerDependencies": { "@icp-sdk/canisters": "^3.3", @@ -2187,9 +2187,9 @@ } }, "node_modules/@junobuild/auth": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/@junobuild/auth/-/auth-4.1.1.tgz", - "integrity": "sha512-0xD4GZ3TCsNi2R5Ge/ycllOa9Tg+DBcHPQ0ydNo6FxP3iNPCIxI7lUwnEX9vJnopzGGWCBoFAZYLLz0w9I1yQA==", + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/@junobuild/auth/-/auth-4.1.2.tgz", + "integrity": "sha512-AR6qDeg6cUN4YabM92kD8P0oDK5NeP1ZA8kD/E5WAknUpDIyqSIE8/AXXj9YJlb6WUgrHhDK8JhRaTxlRdRRVw==", "license": "MIT", "peerDependencies": { "@icp-sdk/core": "^5", @@ -2198,14 +2198,13 @@ } }, "node_modules/@junobuild/cdn": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/@junobuild/cdn/-/cdn-2.4.2.tgz", - "integrity": "sha512-gpdJzX6ixJ5pWeHrJepSR234U9lXFqcWhkf3qU1PO+2WqrIGtMdMeTQzPty8rHXOmGgz/nL+sZI2ZgIwyYguJg==", + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/@junobuild/cdn/-/cdn-2.5.0.tgz", + "integrity": "sha512-ZErAIAxcJG/QYNUkD++VDV9CYfZrFjhKhA7PeUdjvYgkYUUtY+tGi+WP6YbLbNQ42iRbu/IKC+FNEPKz6302QQ==", "license": "MIT", "peerDependencies": { "@icp-sdk/canisters": "^3.3", "@icp-sdk/core": "^5", - "@junobuild/config": "*", "@junobuild/ic-client": "^8.1", "@junobuild/storage": "^2.4", "@junobuild/utils": "^1.0.2", @@ -2213,9 +2212,9 @@ } }, "node_modules/@junobuild/cli-tools": { - "version": "0.13.3", - "resolved": "https://registry.npmjs.org/@junobuild/cli-tools/-/cli-tools-0.13.3.tgz", - "integrity": "sha512-N2RCF+SC6sdcRqdloa0lwsdq/6x4f1W5ii9aq7pSjqlSFb7SghWE7RhvMTSFXhjvP6T0UVd77nypzJplZi092A==", + "version": "0.14.0", + "resolved": "https://registry.npmjs.org/@junobuild/cli-tools/-/cli-tools-0.14.0.tgz", + "integrity": "sha512-akkzWI9TfqjT9G9T9xpffQn9O1zfEefMu+0Gp7yQwyKMRK9c4ardNEPDZg7Mzpq0D3TDuNn5FkwDb/mTzsSJXA==", "dev": true, "license": "MIT", "dependencies": { @@ -2226,7 +2225,7 @@ }, "peerDependencies": { "@junobuild/cdn": "^2.4", - "@junobuild/config": "^2.14", + "@junobuild/config": "^3", "@junobuild/functions-tools": "^0.6", "@junobuild/storage": "^2.4", "@junobuild/utils": "^1.0.2", @@ -2274,9 +2273,9 @@ } }, "node_modules/@junobuild/config": { - "version": "2.15.1", - "resolved": "https://registry.npmjs.org/@junobuild/config/-/config-2.15.1.tgz", - "integrity": "sha512-UVVZQNe8pOjE6Vwo7YxN1E+iZ8aBwnEs9/E7DurW2yqs9aNH0V72ziNUi5/urEq/GE8zY8M9u2MF0uUKQyJcrA==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@junobuild/config/-/config-3.0.0.tgz", + "integrity": "sha512-JP3T0V1IWh7o1HYyhK5Bq8eAMO7K2A52zqrP3PxA7jsb7QGstzVphjKVxrsLGrXbwMTBw1xTHEQkYHavG1D0LA==", "license": "MIT", "peerDependencies": { "@junobuild/schema": "^1.2", @@ -2284,9 +2283,9 @@ } }, "node_modules/@junobuild/config-loader": { - "version": "0.4.10", - "resolved": "https://registry.npmjs.org/@junobuild/config-loader/-/config-loader-0.4.10.tgz", - "integrity": "sha512-Hr5VrouGq9nnLaED+/No+tIfDU0pPl2W/3VkmpFGiN9ZNlD6qXYg7NSKArS3JdZ7ChZfTdai7v+8JhPpoL3nZQ==", + "version": "0.4.11", + "resolved": "https://registry.npmjs.org/@junobuild/config-loader/-/config-loader-0.4.11.tgz", + "integrity": "sha512-8T2/WfKMP6kKOZnsFCjayc0Ha6YRLdisqmmQLmGPatGp7HPzyTWXkzEvubLzHVJg5DjqMi3Qm7Pg1tb7ZXLQgA==", "dev": true, "license": "MIT", "peerDependencies": { @@ -2297,9 +2296,9 @@ } }, "node_modules/@junobuild/core": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/@junobuild/core/-/core-5.3.1.tgz", - "integrity": "sha512-w+5pC1vU4KqfRihSN5DsT1RPJ3YqZHFQBDIMXeuG6peXuzy3IHs5NpAp9CrKH2xlX9PFn9wPoQzV5sraRZlGMg==", + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/@junobuild/core/-/core-5.4.0.tgz", + "integrity": "sha512-XW2O8S7HxNt8zPM9loxhd5z6st+ISY7ffGiYRdk2rzQsjlzGDlNdKdTjFcZqEC7mStnQJjsypJyFHhEzj81C8A==", "license": "MIT", "dependencies": { "@junobuild/auth": "^4.1", @@ -2314,15 +2313,15 @@ } }, "node_modules/@junobuild/errors": { - "version": "0.2.6", - "resolved": "https://registry.npmjs.org/@junobuild/errors/-/errors-0.2.6.tgz", - "integrity": "sha512-B+0qKmUZUaCCRC54DE/J7vSW5Nr3UE4mcUQnIXQJG79wUKjT8ydYvye5D5vUsUDFspQGs5xGGdElPKVSDLusKQ==", + "version": "0.2.8", + "resolved": "https://registry.npmjs.org/@junobuild/errors/-/errors-0.2.8.tgz", + "integrity": "sha512-n2rXof9nIqGDCARHZETXcicG3JH6+1JGB9iTuFzkziPZm7q/G1KSzh8gRJYzrFC3XrSGPRWvhX4hKEnoxAbisQ==", "license": "MIT" }, "node_modules/@junobuild/functions": { - "version": "0.8.2", - "resolved": "https://registry.npmjs.org/@junobuild/functions/-/functions-0.8.2.tgz", - "integrity": "sha512-CjZAYKI1kbcB5HHZaeFkqixgMSxDsMNPLXTnBHVUwV3e2fvro8K2MZuWTh8gMYEerkujJqwOgBWHXeMHii87bA==", + "version": "0.8.3", + "resolved": "https://registry.npmjs.org/@junobuild/functions/-/functions-0.8.3.tgz", + "integrity": "sha512-EcgxNxN8NZ3p1MiEpzxcBxYnenaQWN9PaMT4uSzCqCIZlJlNCRGHTJ1ukopA/WZfcRgckkKfkHlSEanrDLD3Cw==", "dev": true, "license": "MIT", "peerDependencies": { @@ -2333,9 +2332,9 @@ } }, "node_modules/@junobuild/functions-tools": { - "version": "0.6.2", - "resolved": "https://registry.npmjs.org/@junobuild/functions-tools/-/functions-tools-0.6.2.tgz", - "integrity": "sha512-zl7Lho1+/N6M+ejrIomGkxtbdiqu1QXTchavwfzhV+h/Y1SKR+NfgO/3R4CBLtLgXXSS4kJQh5yANGKd7GTALQ==", + "version": "0.6.6", + "resolved": "https://registry.npmjs.org/@junobuild/functions-tools/-/functions-tools-0.6.6.tgz", + "integrity": "sha512-qMg5Offrxek87AhVUZKDkC1kjihpn/PFlLArYgix8xXi5Puk3p4SVJ6PPkdYIRfwnSSk38CTKNKXuLZPWvv7/g==", "dev": true, "license": "MIT", "peer": true, @@ -2347,15 +2346,15 @@ "@babel/traverse": "7.28.4", "@babel/types": "7.28.4", "@junobuild/functions": "^0.8", - "@junobuild/schema": "^1.2", + "@junobuild/schema": "^1.2.3", "@junobuild/utils": "^1.0.2", "zod": "^4.3" } }, "node_modules/@junobuild/ic-client": { - "version": "8.1.2", - "resolved": "https://registry.npmjs.org/@junobuild/ic-client/-/ic-client-8.1.2.tgz", - "integrity": "sha512-sUaCeWqfkbk4VVcgYbsO4J16A0Vag37+qDACl+1qjcgaN661HmksTtyn+W85NTNZ3TzbgAgK5HvpdHsSQvpWSA==", + "version": "8.1.3", + "resolved": "https://registry.npmjs.org/@junobuild/ic-client/-/ic-client-8.1.3.tgz", + "integrity": "sha512-vRgPiOaoezxn8KXz4FAn0hoyssP2yETIarIREMT+Dj8rA8ibuDZ1msEJAvufI085NLF+CAdyHVwIPJuAD39aOg==", "license": "MIT", "peerDependencies": { "@icp-sdk/core": "^5", @@ -2364,9 +2363,9 @@ } }, "node_modules/@junobuild/schema": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/@junobuild/schema/-/schema-1.2.1.tgz", - "integrity": "sha512-jaBt9Ob7qeqnSzepeaSungOs+z1bYzNLxbOnOhhQalOBxC2OTJHAUbiQKMfjn+TXl0zTxUeeiBihtiZSLKQDfg==", + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/@junobuild/schema/-/schema-1.2.3.tgz", + "integrity": "sha512-80hQRu/OUh1oopntIjPqS+ug2Un8xbAizOwS3G8x6oaiD5zaLZ34P7hs6ZFUjgYclAAzUGOKri7DZuRL3noELA==", "license": "MIT", "dependencies": { "@dfinity/zod-schemas": "^3.2" @@ -2376,9 +2375,9 @@ } }, "node_modules/@junobuild/storage": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/@junobuild/storage/-/storage-2.4.1.tgz", - "integrity": "sha512-vDAPvzMC7aojV8hXPAmvWVOvHO3OqqL+l6icSncZLDSqDU8Yb/EX9n0Pjmn29HNC0FJAz6FlNkpO5dMIlAU88g==", + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/@junobuild/storage/-/storage-2.4.2.tgz", + "integrity": "sha512-2rI2S/P8pCW7h8FtQjeKDzJ/OSFrdqWDMuAIxCkqjzhmUwS05TMmQJ5JUqBBS2DnwnlVj5rpOxEHNfT4ISVvmQ==", "license": "MIT", "peerDependencies": { "@icp-sdk/core": "^5", @@ -2387,9 +2386,9 @@ } }, "node_modules/@junobuild/utils": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@junobuild/utils/-/utils-1.0.2.tgz", - "integrity": "sha512-GMkupzpm2OrhOF9zWQ+2ZcVuJGNJEab18h0X9p7nxIu0KuuXQJXMCEmag/Y8N9RE0KBvYEmBbQVRMqRfH+9Dyg==", + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@junobuild/utils/-/utils-1.0.3.tgz", + "integrity": "sha512-jeO1VthkesaT940cG7+Qjm13ndSynkQulx1JGxtXKKhR79ummxaWLAvFJqMPRQl/KsPT8LcPoJQximUuv84CZg==", "license": "MIT", "peerDependencies": { "@icp-sdk/core": "^5" @@ -4532,9 +4531,9 @@ } }, "node_modules/baseline-browser-mapping": { - "version": "2.10.13", - "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.10.13.tgz", - "integrity": "sha512-BL2sTuHOdy0YT1lYieUxTw/QMtPBC3pmlJC6xk8BBYVv6vcw3SGdKemQ+Xsx9ik2F/lYDO9tqsFQH1r9PFuHKw==", + "version": "2.10.19", + "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.10.19.tgz", + "integrity": "sha512-qCkNLi2sfBOn8XhZQ0FXsT1Ki/Yo5P90hrkRamVFRS7/KV9hpfA4HkoWNU152+8w0zPjnxo5psx5NL3PSGgv5g==", "dev": true, "license": "Apache-2.0", "peer": true, @@ -4697,9 +4696,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001784", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001784.tgz", - "integrity": "sha512-WU346nBTklUV9YfUl60fqRbU5ZqyXlqvo1SgigE1OAXK5bFL8LL9q1K7aap3N739l4BvNqnkm3YrGHiY9sfUQw==", + "version": "1.0.30001788", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001788.tgz", + "integrity": "sha512-6q8HFp+lOQtcf7wBK+uEenxymVWkGKkjFpCvw5W25cmMwEDU45p1xQFBQv8JDlMMry7eNxyBaR+qxgmTUZkIRQ==", "dev": true, "funding": [ { @@ -5321,9 +5320,9 @@ } }, "node_modules/electron-to-chromium": { - "version": "1.5.331", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.331.tgz", - "integrity": "sha512-IbxXrsTlD3hRodkLnbxAPP4OuJYdWCeM3IOdT+CpcMoIwIoDfCmRpEtSPfwBXxVkg9xmBeY7Lz2Eo2TDn/HC3Q==", + "version": "1.5.336", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.336.tgz", + "integrity": "sha512-AbH9q9J455r/nLmdNZes0G0ZKcRX73FicwowalLs6ijwOmCJSRRrLX63lcAlzy9ux3dWK1w1+1nsBJEWN11hcQ==", "dev": true, "license": "ISC", "peer": true @@ -6314,9 +6313,9 @@ } }, "node_modules/file-type": { - "version": "22.0.0", - "resolved": "https://registry.npmjs.org/file-type/-/file-type-22.0.0.tgz", - "integrity": "sha512-cmBmnYo8Zymabm2+qAP7jTFbKF10bQpYmxoGfuZbRFRcq00BRddJdGNH/P7GA1EMpJy5yQbqa9B7yROb3z8Ziw==", + "version": "22.0.1", + "resolved": "https://registry.npmjs.org/file-type/-/file-type-22.0.1.tgz", + "integrity": "sha512-ww5Mhre0EE+jmBvOXTmXAbEMuZE7uX4a3+oRCQFNj8w++g3ev913N6tXQz0XTXbueQ5TWQfm6BdaViEHHn8bhA==", "dev": true, "license": "MIT", "dependencies": { @@ -9531,9 +9530,9 @@ "license": "MIT" }, "node_modules/stdin-discarder": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/stdin-discarder/-/stdin-discarder-0.3.1.tgz", - "integrity": "sha512-reExS1kSGoElkextOcPkel4NE99S0BWxjUHQeDFnR8S993JxpPX7KU4MNmO19NXhlJp+8dmdCbKQVNgLJh2teA==", + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/stdin-discarder/-/stdin-discarder-0.3.2.tgz", + "integrity": "sha512-eCPu1qRxPVkl5605OTWF8Wz40b4Mf45NY5LQmVPQ599knfs5QhASUm9GbJ5BDMDOXgrnh0wyEdvzmL//YMlw0A==", "dev": true, "license": "MIT", "peer": true, diff --git a/package.json b/package.json index 30520abbd..67c6a8f37 100644 --- a/package.json +++ b/package.json @@ -79,11 +79,11 @@ "@dfinity/pic": "^0.21.0", "@dfinity/response-verification": "^3.0.4", "@icp-sdk/bindgen": "^0.3.0", - "@junobuild/cli-tools": "^0.13.3", - "@junobuild/config": "^2.15.1", - "@junobuild/config-loader": "^0.4.10", - "@junobuild/errors": "^0.2.6", - "@junobuild/functions": "^0.8.2", + "@junobuild/cli-tools": "^0.14.0", + "@junobuild/config": "^3.0.0", + "@junobuild/config-loader": "^0.4.11", + "@junobuild/errors": "^0.2.8", + "@junobuild/functions": "^0.8.3", "@ltd/j-toml": "^1.38.0", "@playwright/test": "^1.59.1", "@sveltejs/adapter-static": "^3.0.10", @@ -121,14 +121,14 @@ "@icp-sdk/auth": "^5.0.0", "@icp-sdk/canisters": "^3.5.2", "@icp-sdk/core": "5.2.1", - "@junobuild/admin": "^4.3.2", - "@junobuild/auth": "^4.1.1", - "@junobuild/cdn": "^2.4.2", - "@junobuild/core": "^5.3.1", - "@junobuild/ic-client": "^8.1.2", - "@junobuild/schema": "^1.2.1", - "@junobuild/storage": "^2.4.1", - "@junobuild/utils": "^1.0.2", + "@junobuild/admin": "^4.3.3", + "@junobuild/auth": "^4.1.2", + "@junobuild/cdn": "^2.5.0", + "@junobuild/core": "^5.4.0", + "@junobuild/ic-client": "^8.1.3", + "@junobuild/schema": "^1.2.3", + "@junobuild/storage": "^2.4.2", + "@junobuild/utils": "^1.0.3", "@zip.js/zip.js": "^2.8.26", "date-fns": "^4.1.0", "dompurify": "^3.3.3", diff --git a/src/tests/fixtures/test_sputnik/resources/custom-functions-option.ts b/src/tests/fixtures/test_sputnik/resources/custom-functions-option.ts index 53b6861af..8b9d38589 100644 --- a/src/tests/fixtures/test_sputnik/resources/custom-functions-option.ts +++ b/src/tests/fixtures/test_sputnik/resources/custom-functions-option.ts @@ -48,3 +48,14 @@ export const testQuery = defineQuery({ preferences: undefined }) }); + +export const testQuery2 = defineQuery({ + result: j.strictObject({ + // Issue: optional enum fields incorrectly emitted #[json_data(nested)] because + // needsJsonData was not forwarded when wrapping a composite type in opt. + role: j.enum(['admin', 'user'] as const).optional() + }), + handler: () => ({ + role: undefined + }) +});