From 81b146a87ad7a60e6e704105de827c0a03d6e283 Mon Sep 17 00:00:00 2001 From: Jonas Daniels Date: Tue, 14 Jan 2025 18:03:18 -0800 Subject: [PATCH] Version Packages (#5921) Co-authored-by: github-actions[bot] --- .changeset/blue-ears-sit.md | 5 -- .changeset/breezy-items-relate.md | 5 -- .changeset/cool-pianos-walk.md | 5 -- .changeset/green-rockets-lie.md | 17 ----- .changeset/happy-carrots-appear.md | 13 ---- .changeset/hip-llamas-wash.md | 5 -- .changeset/serious-geese-chew.md | 36 --------- .changeset/six-snails-reflect.md | 5 -- .changeset/warm-dodos-destroy.md | 44 ----------- packages/thirdweb/CHANGELOG.md | 114 ++++++++++++++++++++++++++++ packages/thirdweb/package.json | 78 ++++++++++++++----- packages/wagmi-adapter/CHANGELOG.md | 2 + packages/wagmi-adapter/package.json | 2 +- 13 files changed, 175 insertions(+), 156 deletions(-) delete mode 100644 .changeset/blue-ears-sit.md delete mode 100644 .changeset/breezy-items-relate.md delete mode 100644 .changeset/cool-pianos-walk.md delete mode 100644 .changeset/green-rockets-lie.md delete mode 100644 .changeset/happy-carrots-appear.md delete mode 100644 .changeset/hip-llamas-wash.md delete mode 100644 .changeset/serious-geese-chew.md delete mode 100644 .changeset/six-snails-reflect.md delete mode 100644 .changeset/warm-dodos-destroy.md diff --git a/.changeset/blue-ears-sit.md b/.changeset/blue-ears-sit.md deleted file mode 100644 index a8d4c66d1e5..00000000000 --- a/.changeset/blue-ears-sit.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"thirdweb": patch ---- - -Export `toEventSelector` utility function from "thirdweb/utils" diff --git a/.changeset/breezy-items-relate.md b/.changeset/breezy-items-relate.md deleted file mode 100644 index edaa244004e..00000000000 --- a/.changeset/breezy-items-relate.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"thirdweb": patch ---- - -Fix deploy version for published contracts diff --git a/.changeset/cool-pianos-walk.md b/.changeset/cool-pianos-walk.md deleted file mode 100644 index 96294d270a1..00000000000 --- a/.changeset/cool-pianos-walk.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"thirdweb": patch ---- - -Ensure resetting deploy flag on bundler errors diff --git a/.changeset/green-rockets-lie.md b/.changeset/green-rockets-lie.md deleted file mode 100644 index 34906c8e3cc..00000000000 --- a/.changeset/green-rockets-lie.md +++ /dev/null @@ -1,17 +0,0 @@ ---- -"thirdweb": minor ---- - -Exposes autoConnect as a standalone function for use outside of react. - -```tsx -import { autoConnect } from "thirdweb/wallets"; - -const autoConnected = await autoConnect({ - client, - onConnect: (wallet) => { - console.log("wallet", wallet); /// wallet that is have been auto connected. - }, -}); -console.log('isAutoConnected', isAutoConnected) // true or false -``` diff --git a/.changeset/happy-carrots-appear.md b/.changeset/happy-carrots-appear.md deleted file mode 100644 index ec268dbb9c1..00000000000 --- a/.changeset/happy-carrots-appear.md +++ /dev/null @@ -1,13 +0,0 @@ ---- -"thirdweb": patch ---- - -Add `isValidENSName` utility function for checking if a string is a valid ENS name. It does not check if the name is actually registered, it only checks if the string is in a valid format. - -```ts -import { isValidENSName } from "thirdweb/utils"; - -isValidENSName("thirdweb.eth"); // true -isValidENSName("foo.bar.com"); // true -isValidENSName("foo"); // false -``` diff --git a/.changeset/hip-llamas-wash.md b/.changeset/hip-llamas-wash.md deleted file mode 100644 index 3624a0001d8..00000000000 --- a/.changeset/hip-llamas-wash.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"thirdweb": patch ---- - -Migrated underlying functionality to Ox diff --git a/.changeset/serious-geese-chew.md b/.changeset/serious-geese-chew.md deleted file mode 100644 index 604f177d1a7..00000000000 --- a/.changeset/serious-geese-chew.md +++ /dev/null @@ -1,36 +0,0 @@ ---- -"thirdweb": minor ---- - -Introducing `engineAccount()` for backend usage - -You can now use `engineAccount()` on the backend to create an account that can send transactions via your engine instance. - -This lets you use the full catalog of thirdweb SDK functions and extensions on the backend, with the performance, reliability, and monitoring of your engine instance. - -```ts -// get your engine url, auth token, and wallet address from your engine instance on the dashboard -const engine = engineAccount({ - engineUrl: process.env.ENGINE_URL, - authToken: process.env.ENGINE_AUTH_TOKEN, - walletAddress: process.env.ENGINE_WALLET_ADDRESS, -}); - -// Now you can use engineAcc to send transactions, deploy contracts, etc. -// For example, you can prepare extension functions: -const tx = await claimTo({ - contract: getContract({ client, chain, address: "0x..." }), - to: "0x...", - tokenId: 0n, - quantity: 1n, -}); - -// And then send the transaction via engine -// this will automatically wait for the transaction to be mined and return the transaction hash -const result = await sendTransaction({ - account: engine, // forward the transaction to your engine instance - transaction: tx, -}); - -console.log(result.transactionHash); -``` diff --git a/.changeset/six-snails-reflect.md b/.changeset/six-snails-reflect.md deleted file mode 100644 index 714a265ba66..00000000000 --- a/.changeset/six-snails-reflect.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"thirdweb": patch ---- - -Do not prompt user for signing message for SIWE auth in Connect UI for Ecosystem wallets diff --git a/.changeset/warm-dodos-destroy.md b/.changeset/warm-dodos-destroy.md deleted file mode 100644 index 40037c5adf7..00000000000 --- a/.changeset/warm-dodos-destroy.md +++ /dev/null @@ -1,44 +0,0 @@ ---- -"thirdweb": minor ---- - -Introducing Nebula API - -You can now chat with Nebula and ask it to execute transactions with your wallet. - -Ask questions about real time blockchain data. - -```ts -import { Nebula } from "thirdweb/ai"; - -const response = await Nebula.chat({ - client: TEST_CLIENT, - prompt: - "What's the symbol of this contract: 0xe2cb0eb5147b42095c2FfA6F7ec953bb0bE347D8", - context: { - chains: [sepolia], - }, -}); - -console.log("chat response:", response.message); -``` - -Ask it to execute transactions with your wallet. - -```ts -import { Nebula } from "thirdweb/ai"; - -const wallet = createWallet("io.metamask"); -const account = await wallet.connect({ client }); - -const result = await Nebula.execute({ - client, - prompt: "send 0.0001 ETH to vitalik.eth", - account, - context: { - chains: [sepolia], - }, -}); - -console.log("executed transaction:", result.transactionHash); -``` diff --git a/packages/thirdweb/CHANGELOG.md b/packages/thirdweb/CHANGELOG.md index ebe676a3de4..35bd58572a2 100644 --- a/packages/thirdweb/CHANGELOG.md +++ b/packages/thirdweb/CHANGELOG.md @@ -1,5 +1,119 @@ # thirdweb +## 5.84.0 + +### Minor Changes + +- [#5889](https://github.com/thirdweb-dev/js/pull/5889) [`7a3dff0`](https://github.com/thirdweb-dev/js/commit/7a3dff01cd4ef1b20b783312f4cb755dd2fddcbd) Thanks [@ElasticBottle](https://github.com/ElasticBottle)! - Exposes autoConnect as a standalone function for use outside of react. + + ```tsx + import { autoConnect } from "thirdweb/wallets"; + + const autoConnected = await autoConnect({ + client, + onConnect: (wallet) => { + console.log("wallet", wallet); /// wallet that is have been auto connected. + }, + }); + console.log("isAutoConnected", isAutoConnected); // true or false + ``` + +- [#5947](https://github.com/thirdweb-dev/js/pull/5947) [`d1c03b0`](https://github.com/thirdweb-dev/js/commit/d1c03b0cbc524d39d827f1e0d48f3532a837efb0) Thanks [@joaquim-verges](https://github.com/joaquim-verges)! - Introducing `engineAccount()` for backend usage + + You can now use `engineAccount()` on the backend to create an account that can send transactions via your engine instance. + + This lets you use the full catalog of thirdweb SDK functions and extensions on the backend, with the performance, reliability, and monitoring of your engine instance. + + ```ts + // get your engine url, auth token, and wallet address from your engine instance on the dashboard + const engine = engineAccount({ + engineUrl: process.env.ENGINE_URL, + authToken: process.env.ENGINE_AUTH_TOKEN, + walletAddress: process.env.ENGINE_WALLET_ADDRESS, + }); + + // Now you can use engineAcc to send transactions, deploy contracts, etc. + // For example, you can prepare extension functions: + const tx = await claimTo({ + contract: getContract({ client, chain, address: "0x..." }), + to: "0x...", + tokenId: 0n, + quantity: 1n, + }); + + // And then send the transaction via engine + // this will automatically wait for the transaction to be mined and return the transaction hash + const result = await sendTransaction({ + account: engine, // forward the transaction to your engine instance + transaction: tx, + }); + + console.log(result.transactionHash); + ``` + +- [#5948](https://github.com/thirdweb-dev/js/pull/5948) [`b10f306`](https://github.com/thirdweb-dev/js/commit/b10f306fba2140cf7a702d4fc5c55c316986a6b6) Thanks [@joaquim-verges](https://github.com/joaquim-verges)! - Introducing Nebula API + + You can now chat with Nebula and ask it to execute transactions with your wallet. + + Ask questions about real time blockchain data. + + ```ts + import { Nebula } from "thirdweb/ai"; + + const response = await Nebula.chat({ + client: TEST_CLIENT, + prompt: + "What's the symbol of this contract: 0xe2cb0eb5147b42095c2FfA6F7ec953bb0bE347D8", + context: { + chains: [sepolia], + }, + }); + + console.log("chat response:", response.message); + ``` + + Ask it to execute transactions with your wallet. + + ```ts + import { Nebula } from "thirdweb/ai"; + + const wallet = createWallet("io.metamask"); + const account = await wallet.connect({ client }); + + const result = await Nebula.execute({ + client, + prompt: "send 0.0001 ETH to vitalik.eth", + account, + context: { + chains: [sepolia], + }, + }); + + console.log("executed transaction:", result.transactionHash); + ``` + +### Patch Changes + +- [#5926](https://github.com/thirdweb-dev/js/pull/5926) [`4b5661b`](https://github.com/thirdweb-dev/js/commit/4b5661b9817d1e0d67a8574d7c5931d3e892a006) Thanks [@MananTank](https://github.com/MananTank)! - Export `toEventSelector` utility function from "thirdweb/utils" + +- [#5923](https://github.com/thirdweb-dev/js/pull/5923) [`42a313f`](https://github.com/thirdweb-dev/js/commit/42a313f3b2d89696d5374e5a705e9f144bf46ebe) Thanks [@kumaryash90](https://github.com/kumaryash90)! - Fix deploy version for published contracts + +- [#5924](https://github.com/thirdweb-dev/js/pull/5924) [`7fb5ce1`](https://github.com/thirdweb-dev/js/commit/7fb5ce1cc3af8bc9d99fef52018d3e1c7b558eaa) Thanks [@joaquim-verges](https://github.com/joaquim-verges)! - Ensure resetting deploy flag on bundler errors + +- [#5937](https://github.com/thirdweb-dev/js/pull/5937) [`0e2b3df`](https://github.com/thirdweb-dev/js/commit/0e2b3df42aee57f30b7e8c32dbf034f5deb37303) Thanks [@MananTank](https://github.com/MananTank)! - Add `isValidENSName` utility function for checking if a string is a valid ENS name. It does not check if the name is actually registered, it only checks if the string is in a valid format. + + ```ts + import { isValidENSName } from "thirdweb/utils"; + + isValidENSName("thirdweb.eth"); // true + isValidENSName("foo.bar.com"); // true + isValidENSName("foo"); // false + ``` + +- [#5790](https://github.com/thirdweb-dev/js/pull/5790) [`e331e43`](https://github.com/thirdweb-dev/js/commit/e331e433ac90920fc3bd710d8aa00bc9ec03fa22) Thanks [@gregfromstl](https://github.com/gregfromstl)! - Migrated underlying functionality to Ox + +- [#5914](https://github.com/thirdweb-dev/js/pull/5914) [`c5c6f9d`](https://github.com/thirdweb-dev/js/commit/c5c6f9d7415a438ddb0823764884d9c77b687163) Thanks [@MananTank](https://github.com/MananTank)! - Do not prompt user for signing message for SIWE auth in Connect UI for Ecosystem wallets + ## 5.83.1 ### Patch Changes diff --git a/packages/thirdweb/package.json b/packages/thirdweb/package.json index 3a3885eaa70..a8a46bc17d6 100644 --- a/packages/thirdweb/package.json +++ b/packages/thirdweb/package.json @@ -1,6 +1,6 @@ { "name": "thirdweb", - "version": "5.83.1", + "version": "5.84.0", "repository": { "type": "git", "url": "git+https://github.com/thirdweb-dev/js.git#main" @@ -132,25 +132,63 @@ }, "typesVersions": { "*": { - "adapters/*": ["./dist/types/exports/adapters/*.d.ts"], - "auth": ["./dist/types/exports/auth.d.ts"], - "chains": ["./dist/types/exports/chains.d.ts"], - "contract": ["./dist/types/exports/contract.d.ts"], - "deploys": ["./dist/types/exports/deploys.d.ts"], - "event": ["./dist/types/exports/event.d.ts"], - "extensions/*": ["./dist/types/exports/extensions/*.d.ts"], - "pay": ["./dist/types/exports/pay.d.ts"], - "react": ["./dist/types/exports/react.d.ts"], - "react-native": ["./dist/types/exports/react-native.d.ts"], - "rpc": ["./dist/types/exports/rpc.d.ts"], - "storage": ["./dist/types/exports/storage.d.ts"], - "transaction": ["./dist/types/exports/transaction.d.ts"], - "utils": ["./dist/types/exports/utils.d.ts"], - "wallets": ["./dist/types/exports/wallets.d.ts"], - "wallets/*": ["./dist/types/exports/wallets/*.d.ts"], - "modules": ["./dist/types/exports/modules.d.ts"], - "social": ["./dist/types/exports/social.d.ts"], - "ai": ["./dist/types/exports/ai.d.ts"] + "adapters/*": [ + "./dist/types/exports/adapters/*.d.ts" + ], + "auth": [ + "./dist/types/exports/auth.d.ts" + ], + "chains": [ + "./dist/types/exports/chains.d.ts" + ], + "contract": [ + "./dist/types/exports/contract.d.ts" + ], + "deploys": [ + "./dist/types/exports/deploys.d.ts" + ], + "event": [ + "./dist/types/exports/event.d.ts" + ], + "extensions/*": [ + "./dist/types/exports/extensions/*.d.ts" + ], + "pay": [ + "./dist/types/exports/pay.d.ts" + ], + "react": [ + "./dist/types/exports/react.d.ts" + ], + "react-native": [ + "./dist/types/exports/react-native.d.ts" + ], + "rpc": [ + "./dist/types/exports/rpc.d.ts" + ], + "storage": [ + "./dist/types/exports/storage.d.ts" + ], + "transaction": [ + "./dist/types/exports/transaction.d.ts" + ], + "utils": [ + "./dist/types/exports/utils.d.ts" + ], + "wallets": [ + "./dist/types/exports/wallets.d.ts" + ], + "wallets/*": [ + "./dist/types/exports/wallets/*.d.ts" + ], + "modules": [ + "./dist/types/exports/modules.d.ts" + ], + "social": [ + "./dist/types/exports/social.d.ts" + ], + "ai": [ + "./dist/types/exports/ai.d.ts" + ] } }, "browser": { diff --git a/packages/wagmi-adapter/CHANGELOG.md b/packages/wagmi-adapter/CHANGELOG.md index adac4a350ce..c9589efe549 100644 --- a/packages/wagmi-adapter/CHANGELOG.md +++ b/packages/wagmi-adapter/CHANGELOG.md @@ -1,5 +1,7 @@ # @thirdweb-dev/wagmi-adapter +## 0.1.8 + ## 0.1.7 ## 0.1.6 diff --git a/packages/wagmi-adapter/package.json b/packages/wagmi-adapter/package.json index d579b0c7802..1fe8bf724ff 100644 --- a/packages/wagmi-adapter/package.json +++ b/packages/wagmi-adapter/package.json @@ -1,6 +1,6 @@ { "name": "@thirdweb-dev/wagmi-adapter", - "version": "0.1.7", + "version": "0.1.8", "repository": { "type": "git", "url": "git+https://github.com/thirdweb-dev/js.git#main"