thirdweb 5.47.1 → 5.48.0
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/dist/cjs/adapters/ethers5.js +87 -1
- package/dist/cjs/adapters/ethers5.js.map +1 -1
- package/dist/cjs/adapters/ethers6.js +85 -15
- package/dist/cjs/adapters/ethers6.js.map +1 -1
- package/dist/cjs/adapters/viem.js +117 -43
- package/dist/cjs/adapters/viem.js.map +1 -1
- package/dist/cjs/contract/actions/compiler-metadata.js.map +1 -1
- package/dist/cjs/exports/utils.js +7 -1
- package/dist/cjs/exports/utils.js.map +1 -1
- package/dist/cjs/extensions/erc721/read/getOwnedNFTs.js +1 -0
- package/dist/cjs/extensions/erc721/read/getOwnedNFTs.js.map +1 -1
- package/dist/cjs/react/core/design-system/index.js +1 -0
- package/dist/cjs/react/core/design-system/index.js.map +1 -1
- package/dist/cjs/react/core/hooks/transaction/transaction-button-utils.js.map +1 -1
- package/dist/cjs/react/core/hooks/transaction/useSendTransaction.js +58 -1
- package/dist/cjs/react/core/hooks/transaction/useSendTransaction.js.map +1 -1
- package/dist/cjs/react/core/hooks/wallets/useAddConnectedWallet.js +23 -0
- package/dist/cjs/react/core/hooks/wallets/useAddConnectedWallet.js.map +1 -0
- package/dist/cjs/react/native/ui/connect/ConnectModal.js +1 -0
- package/dist/cjs/react/native/ui/connect/ConnectModal.js.map +1 -1
- package/dist/cjs/react/native/ui/transaction/TransactionButton.js +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/Details.js +62 -53
- package/dist/cjs/react/web/ui/ConnectWallet/Details.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/MenuButton.js +0 -1
- package/dist/cjs/react/web/ui/ConnectWallet/MenuButton.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/Modal/AllWalletsUI.js +3 -1
- package/dist/cjs/react/web/ui/ConnectWallet/Modal/AllWalletsUI.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/Modal/AnyWalletConnectUI.js +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/Modal/AnyWalletConnectUI.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/WalletSelector.js +8 -6
- package/dist/cjs/react/web/ui/ConnectWallet/WalletSelector.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/locale/en.js +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/WalletSelectorButton.js +1 -2
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/WalletSelectorButton.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/fiat/FiatFlow.js +9 -9
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/fiat/FiatFlow.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Details/WalletManagerScreen.js +3 -3
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Details/WalletManagerScreen.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/LinkProfileScreen.js +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/LinkProfileScreen.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/LinkedProfilesScreen.js +7 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/LinkedProfilesScreen.js.map +1 -1
- package/dist/cjs/react/web/ui/TransactionButton/index.js +1 -1
- package/dist/cjs/react/web/ui/components/ChainIcon.js +3 -2
- package/dist/cjs/react/web/ui/components/ChainIcon.js.map +1 -1
- package/dist/cjs/react/web/ui/components/CopyAddress.js +22 -0
- package/dist/cjs/react/web/ui/components/CopyAddress.js.map +1 -0
- package/dist/cjs/react/web/ui/components/IconContainer.js +25 -0
- package/dist/cjs/react/web/ui/components/IconContainer.js.map +1 -0
- package/dist/cjs/react/web/ui/components/Modal.js +1 -1
- package/dist/cjs/react/web/ui/components/Modal.js.map +1 -1
- package/dist/cjs/react/web/ui/components/WalletImage.js +4 -11
- package/dist/cjs/react/web/ui/components/WalletImage.js.map +1 -1
- package/dist/cjs/react/web/ui/components/formElements.js +3 -3
- package/dist/cjs/react/web/ui/components/formElements.js.map +1 -1
- package/dist/cjs/react/web/wallets/in-app/CountrySelector.js +1 -3
- package/dist/cjs/react/web/wallets/in-app/CountrySelector.js.map +1 -1
- package/dist/cjs/react/web/wallets/in-app/InAppWalletConnectUI.js +4 -0
- package/dist/cjs/react/web/wallets/in-app/InAppWalletConnectUI.js.map +1 -1
- package/dist/cjs/react/web/wallets/in-app/WalletAuth.js +70 -0
- package/dist/cjs/react/web/wallets/in-app/WalletAuth.js.map +1 -0
- package/dist/cjs/react/web/wallets/shared/ConnectWalletSocialOptions.js +9 -1
- package/dist/cjs/react/web/wallets/shared/ConnectWalletSocialOptions.js.map +1 -1
- package/dist/cjs/react/web/wallets/shared/ErrorState.js +14 -0
- package/dist/cjs/react/web/wallets/shared/ErrorState.js.map +1 -0
- package/dist/cjs/react/web/wallets/shared/LoadingState.js +19 -0
- package/dist/cjs/react/web/wallets/shared/LoadingState.js.map +1 -0
- package/dist/cjs/react/web/wallets/shared/PassKeyLogin.js +6 -20
- package/dist/cjs/react/web/wallets/shared/PassKeyLogin.js.map +1 -1
- package/dist/cjs/react/web/wallets/shared/locale/de.js +1 -0
- package/dist/cjs/react/web/wallets/shared/locale/de.js.map +1 -1
- package/dist/cjs/react/web/wallets/shared/locale/en.js +2 -1
- package/dist/cjs/react/web/wallets/shared/locale/en.js.map +1 -1
- package/dist/cjs/react/web/wallets/shared/locale/es.js +1 -0
- package/dist/cjs/react/web/wallets/shared/locale/es.js.map +1 -1
- package/dist/cjs/react/web/wallets/shared/locale/fr.js +1 -0
- package/dist/cjs/react/web/wallets/shared/locale/fr.js.map +1 -1
- package/dist/cjs/react/web/wallets/shared/locale/ja.js +1 -0
- package/dist/cjs/react/web/wallets/shared/locale/ja.js.map +1 -1
- package/dist/cjs/react/web/wallets/shared/locale/kr.js +1 -0
- package/dist/cjs/react/web/wallets/shared/locale/kr.js.map +1 -1
- package/dist/cjs/react/web/wallets/shared/locale/tl.js +1 -0
- package/dist/cjs/react/web/wallets/shared/locale/tl.js.map +1 -1
- package/dist/cjs/react/web/wallets/shared/locale/vi.js +1 -0
- package/dist/cjs/react/web/wallets/shared/locale/vi.js.map +1 -1
- package/dist/cjs/transaction/actions/gasless/providers/biconomy.js.map +1 -1
- package/dist/cjs/transaction/actions/gasless/providers/engine.js.map +1 -1
- package/dist/cjs/transaction/actions/gasless/providers/openzeppelin.js.map +1 -1
- package/dist/cjs/transaction/prepare-contract-call.js +1 -1
- package/dist/cjs/transaction/read-contract.js +21 -2
- package/dist/cjs/transaction/read-contract.js.map +1 -1
- package/dist/cjs/utils/bigint.js +2 -0
- package/dist/cjs/utils/bigint.js.map +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/cjs/wallets/custom/smart/image.js +1 -1
- package/dist/cjs/wallets/custom/smart/image.js.map +1 -1
- package/dist/cjs/wallets/in-app/core/authentication/getLoginPath.js +1 -1
- package/dist/cjs/wallets/in-app/core/authentication/getLoginPath.js.map +1 -1
- package/dist/cjs/wallets/manager/index.js +0 -1
- package/dist/cjs/wallets/manager/index.js.map +1 -1
- package/dist/cjs/wallets/types.js +0 -1
- package/dist/cjs/wallets/types.js.map +1 -1
- package/dist/esm/adapters/ethers5.js +87 -1
- package/dist/esm/adapters/ethers5.js.map +1 -1
- package/dist/esm/adapters/ethers6.js +85 -15
- package/dist/esm/adapters/ethers6.js.map +1 -1
- package/dist/esm/adapters/viem.js +117 -43
- package/dist/esm/adapters/viem.js.map +1 -1
- package/dist/esm/contract/actions/compiler-metadata.js.map +1 -1
- package/dist/esm/exports/utils.js +4 -0
- package/dist/esm/exports/utils.js.map +1 -1
- package/dist/esm/extensions/erc721/read/getOwnedNFTs.js +1 -0
- package/dist/esm/extensions/erc721/read/getOwnedNFTs.js.map +1 -1
- package/dist/esm/react/core/design-system/index.js +1 -0
- package/dist/esm/react/core/design-system/index.js.map +1 -1
- package/dist/esm/react/core/hooks/transaction/transaction-button-utils.js.map +1 -1
- package/dist/esm/react/core/hooks/transaction/useSendTransaction.js +57 -1
- package/dist/esm/react/core/hooks/transaction/useSendTransaction.js.map +1 -1
- package/dist/esm/react/core/hooks/wallets/useAddConnectedWallet.js +20 -0
- package/dist/esm/react/core/hooks/wallets/useAddConnectedWallet.js.map +1 -0
- package/dist/esm/react/native/ui/connect/ConnectModal.js +1 -1
- package/dist/esm/react/native/ui/connect/ConnectModal.js.map +1 -1
- package/dist/esm/react/native/ui/transaction/TransactionButton.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/Details.js +64 -55
- package/dist/esm/react/web/ui/ConnectWallet/Details.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/MenuButton.js +0 -1
- package/dist/esm/react/web/ui/ConnectWallet/MenuButton.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/Modal/AllWalletsUI.js +3 -1
- package/dist/esm/react/web/ui/ConnectWallet/Modal/AllWalletsUI.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/Modal/AnyWalletConnectUI.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/Modal/AnyWalletConnectUI.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/WalletSelector.js +8 -6
- package/dist/esm/react/web/ui/ConnectWallet/WalletSelector.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/locale/en.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/WalletSelectorButton.js +1 -2
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/WalletSelectorButton.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/fiat/FiatFlow.js +9 -9
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/fiat/FiatFlow.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Details/WalletManagerScreen.js +4 -4
- package/dist/esm/react/web/ui/ConnectWallet/screens/Details/WalletManagerScreen.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/LinkProfileScreen.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/LinkProfileScreen.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/LinkedProfilesScreen.js +7 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/LinkedProfilesScreen.js.map +1 -1
- package/dist/esm/react/web/ui/TransactionButton/index.js +1 -1
- package/dist/esm/react/web/ui/components/ChainIcon.js +3 -2
- package/dist/esm/react/web/ui/components/ChainIcon.js.map +1 -1
- package/dist/esm/react/web/ui/components/CopyAddress.js +18 -0
- package/dist/esm/react/web/ui/components/CopyAddress.js.map +1 -0
- package/dist/esm/react/web/ui/components/IconContainer.js +21 -0
- package/dist/esm/react/web/ui/components/IconContainer.js.map +1 -0
- package/dist/esm/react/web/ui/components/Modal.js +1 -1
- package/dist/esm/react/web/ui/components/Modal.js.map +1 -1
- package/dist/esm/react/web/ui/components/WalletImage.js +1 -8
- package/dist/esm/react/web/ui/components/WalletImage.js.map +1 -1
- package/dist/esm/react/web/ui/components/formElements.js +3 -3
- package/dist/esm/react/web/ui/components/formElements.js.map +1 -1
- package/dist/esm/react/web/wallets/in-app/CountrySelector.js +2 -4
- package/dist/esm/react/web/wallets/in-app/CountrySelector.js.map +1 -1
- package/dist/esm/react/web/wallets/in-app/InAppWalletConnectUI.js +4 -0
- package/dist/esm/react/web/wallets/in-app/InAppWalletConnectUI.js.map +1 -1
- package/dist/esm/react/web/wallets/in-app/WalletAuth.js +67 -0
- package/dist/esm/react/web/wallets/in-app/WalletAuth.js.map +1 -0
- package/dist/esm/react/web/wallets/shared/ConnectWalletSocialOptions.js +10 -2
- package/dist/esm/react/web/wallets/shared/ConnectWalletSocialOptions.js.map +1 -1
- package/dist/esm/react/web/wallets/shared/ErrorState.js +11 -0
- package/dist/esm/react/web/wallets/shared/ErrorState.js.map +1 -0
- package/dist/esm/react/web/wallets/shared/LoadingState.js +16 -0
- package/dist/esm/react/web/wallets/shared/LoadingState.js.map +1 -0
- package/dist/esm/react/web/wallets/shared/PassKeyLogin.js +4 -18
- package/dist/esm/react/web/wallets/shared/PassKeyLogin.js.map +1 -1
- package/dist/esm/react/web/wallets/shared/locale/de.js +1 -0
- package/dist/esm/react/web/wallets/shared/locale/de.js.map +1 -1
- package/dist/esm/react/web/wallets/shared/locale/en.js +2 -1
- package/dist/esm/react/web/wallets/shared/locale/en.js.map +1 -1
- package/dist/esm/react/web/wallets/shared/locale/es.js +1 -0
- package/dist/esm/react/web/wallets/shared/locale/es.js.map +1 -1
- package/dist/esm/react/web/wallets/shared/locale/fr.js +1 -0
- package/dist/esm/react/web/wallets/shared/locale/fr.js.map +1 -1
- package/dist/esm/react/web/wallets/shared/locale/ja.js +1 -0
- package/dist/esm/react/web/wallets/shared/locale/ja.js.map +1 -1
- package/dist/esm/react/web/wallets/shared/locale/kr.js +1 -0
- package/dist/esm/react/web/wallets/shared/locale/kr.js.map +1 -1
- package/dist/esm/react/web/wallets/shared/locale/tl.js +1 -0
- package/dist/esm/react/web/wallets/shared/locale/tl.js.map +1 -1
- package/dist/esm/react/web/wallets/shared/locale/vi.js +1 -0
- package/dist/esm/react/web/wallets/shared/locale/vi.js.map +1 -1
- package/dist/esm/transaction/actions/gasless/providers/biconomy.js.map +1 -1
- package/dist/esm/transaction/actions/gasless/providers/engine.js.map +1 -1
- package/dist/esm/transaction/actions/gasless/providers/openzeppelin.js.map +1 -1
- package/dist/esm/transaction/prepare-contract-call.js +1 -1
- package/dist/esm/transaction/read-contract.js +21 -2
- package/dist/esm/transaction/read-contract.js.map +1 -1
- package/dist/esm/utils/bigint.js +2 -0
- package/dist/esm/utils/bigint.js.map +1 -1
- package/dist/esm/version.js +1 -1
- package/dist/esm/wallets/custom/smart/image.js +1 -1
- package/dist/esm/wallets/custom/smart/image.js.map +1 -1
- package/dist/esm/wallets/in-app/core/authentication/getLoginPath.js +1 -1
- package/dist/esm/wallets/in-app/core/authentication/getLoginPath.js.map +1 -1
- package/dist/esm/wallets/manager/index.js +0 -1
- package/dist/esm/wallets/manager/index.js.map +1 -1
- package/dist/esm/wallets/types.js +0 -1
- package/dist/esm/wallets/types.js.map +1 -1
- package/dist/types/adapters/ethers5.d.ts +87 -1
- package/dist/types/adapters/ethers5.d.ts.map +1 -1
- package/dist/types/adapters/ethers6.d.ts +85 -15
- package/dist/types/adapters/ethers6.d.ts.map +1 -1
- package/dist/types/adapters/viem.d.ts +117 -43
- package/dist/types/adapters/viem.d.ts.map +1 -1
- package/dist/types/contract/actions/compiler-metadata.d.ts +7 -1
- package/dist/types/contract/actions/compiler-metadata.d.ts.map +1 -1
- package/dist/types/exports/transaction.d.ts +7 -0
- package/dist/types/exports/transaction.d.ts.map +1 -1
- package/dist/types/exports/utils.d.ts +1 -0
- package/dist/types/exports/utils.d.ts.map +1 -1
- package/dist/types/extensions/erc721/read/getOwnedNFTs.d.ts +1 -0
- package/dist/types/extensions/erc721/read/getOwnedNFTs.d.ts.map +1 -1
- package/dist/types/react/core/design-system/index.d.ts +1 -0
- package/dist/types/react/core/design-system/index.d.ts.map +1 -1
- package/dist/types/react/core/hooks/transaction/transaction-button-utils.d.ts +1 -0
- package/dist/types/react/core/hooks/transaction/transaction-button-utils.d.ts.map +1 -1
- package/dist/types/react/core/hooks/transaction/useSendTransaction.d.ts +1 -0
- package/dist/types/react/core/hooks/transaction/useSendTransaction.d.ts.map +1 -1
- package/dist/types/react/core/hooks/wallets/useAddConnectedWallet.d.ts +16 -0
- package/dist/types/react/core/hooks/wallets/useAddConnectedWallet.d.ts.map +1 -0
- package/dist/types/react/native/ui/connect/ConnectModal.d.ts +3 -0
- package/dist/types/react/native/ui/connect/ConnectModal.d.ts.map +1 -1
- package/dist/types/react/native/ui/transaction/TransactionButton.d.ts +1 -1
- package/dist/types/react/web/ui/ConnectWallet/Details.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/MenuButton.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/Modal/AllWalletsUI.d.ts +1 -0
- package/dist/types/react/web/ui/ConnectWallet/Modal/AllWalletsUI.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/Modal/AnyWalletConnectUI.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/WalletSelector.d.ts +1 -0
- package/dist/types/react/web/ui/ConnectWallet/WalletSelector.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/WalletSelectorButton.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/LinkProfileScreen.d.ts +3 -0
- package/dist/types/react/web/ui/ConnectWallet/screens/LinkProfileScreen.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/LinkedProfilesScreen.d.ts.map +1 -1
- package/dist/types/react/web/ui/TransactionButton/index.d.ts +1 -1
- package/dist/types/react/web/ui/components/ChainIcon.d.ts.map +1 -1
- package/dist/types/react/web/ui/components/CopyAddress.d.ts +7 -0
- package/dist/types/react/web/ui/components/CopyAddress.d.ts.map +1 -0
- package/dist/types/react/web/ui/components/IconContainer.d.ts +10 -0
- package/dist/types/react/web/ui/components/IconContainer.d.ts.map +1 -0
- package/dist/types/react/web/ui/components/WalletImage.d.ts.map +1 -1
- package/dist/types/react/web/wallets/in-app/CountrySelector.d.ts.map +1 -1
- package/dist/types/react/web/wallets/in-app/InAppWalletConnectUI.d.ts +3 -0
- package/dist/types/react/web/wallets/in-app/InAppWalletConnectUI.d.ts.map +1 -1
- package/dist/types/react/web/wallets/in-app/WalletAuth.d.ts +24 -0
- package/dist/types/react/web/wallets/in-app/WalletAuth.d.ts.map +1 -0
- package/dist/types/react/web/wallets/shared/ConnectWalletSocialOptions.d.ts +1 -0
- package/dist/types/react/web/wallets/shared/ConnectWalletSocialOptions.d.ts.map +1 -1
- package/dist/types/react/web/wallets/shared/ErrorState.d.ts +5 -0
- package/dist/types/react/web/wallets/shared/ErrorState.d.ts.map +1 -0
- package/dist/types/react/web/wallets/shared/LoadingState.d.ts +7 -0
- package/dist/types/react/web/wallets/shared/LoadingState.d.ts.map +1 -0
- package/dist/types/react/web/wallets/shared/PassKeyLogin.d.ts.map +1 -1
- package/dist/types/react/web/wallets/shared/locale/de.d.ts +1 -0
- package/dist/types/react/web/wallets/shared/locale/de.d.ts.map +1 -1
- package/dist/types/react/web/wallets/shared/locale/en.d.ts +1 -0
- package/dist/types/react/web/wallets/shared/locale/en.d.ts.map +1 -1
- package/dist/types/react/web/wallets/shared/locale/es.d.ts +1 -0
- package/dist/types/react/web/wallets/shared/locale/es.d.ts.map +1 -1
- package/dist/types/react/web/wallets/shared/locale/fr.d.ts +1 -0
- package/dist/types/react/web/wallets/shared/locale/fr.d.ts.map +1 -1
- package/dist/types/react/web/wallets/shared/locale/ja.d.ts +1 -0
- package/dist/types/react/web/wallets/shared/locale/ja.d.ts.map +1 -1
- package/dist/types/react/web/wallets/shared/locale/kr.d.ts +1 -0
- package/dist/types/react/web/wallets/shared/locale/kr.d.ts.map +1 -1
- package/dist/types/react/web/wallets/shared/locale/tl.d.ts +1 -0
- package/dist/types/react/web/wallets/shared/locale/tl.d.ts.map +1 -1
- package/dist/types/react/web/wallets/shared/locale/types.d.ts +1 -0
- package/dist/types/react/web/wallets/shared/locale/types.d.ts.map +1 -1
- package/dist/types/react/web/wallets/shared/locale/vi.d.ts +1 -0
- package/dist/types/react/web/wallets/shared/locale/vi.d.ts.map +1 -1
- package/dist/types/transaction/actions/gasless/providers/biconomy.d.ts +3 -0
- package/dist/types/transaction/actions/gasless/providers/biconomy.d.ts.map +1 -1
- package/dist/types/transaction/actions/gasless/providers/engine.d.ts +3 -0
- package/dist/types/transaction/actions/gasless/providers/engine.d.ts.map +1 -1
- package/dist/types/transaction/actions/gasless/providers/openzeppelin.d.ts +3 -0
- package/dist/types/transaction/actions/gasless/providers/openzeppelin.d.ts.map +1 -1
- package/dist/types/transaction/actions/gasless/types.d.ts +12 -0
- package/dist/types/transaction/actions/gasless/types.d.ts.map +1 -1
- package/dist/types/transaction/prepare-contract-call.d.ts +1 -1
- package/dist/types/transaction/read-contract.d.ts +21 -2
- package/dist/types/transaction/read-contract.d.ts.map +1 -1
- package/dist/types/utils/bigint.d.ts +2 -0
- package/dist/types/utils/bigint.d.ts.map +1 -1
- package/dist/types/version.d.ts +1 -1
- package/dist/types/wallets/custom/smart/image.d.ts +1 -1
- package/dist/types/wallets/custom/smart/image.d.ts.map +1 -1
- package/dist/types/wallets/in-app/core/authentication/getLoginPath.d.ts +2 -2
- package/dist/types/wallets/in-app/core/authentication/getLoginPath.d.ts.map +1 -1
- package/dist/types/wallets/in-app/core/authentication/types.d.ts +1 -1
- package/dist/types/wallets/in-app/core/authentication/types.d.ts.map +1 -1
- package/dist/types/wallets/manager/index.d.ts.map +1 -1
- package/dist/types/wallets/types.d.ts +1 -1
- package/dist/types/wallets/types.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/adapters/ethers5.ts +87 -1
- package/src/adapters/ethers6.ts +85 -15
- package/src/adapters/viem.ts +117 -44
- package/src/contract/actions/compiler-metadata.ts +4 -2
- package/src/exports/transaction.ts +8 -0
- package/src/exports/utils.ts +5 -0
- package/src/extensions/erc721/read/getOwnedNFTs.ts +1 -0
- package/src/extensions/lens/read/resolveAddress.test.ts +1 -1
- package/src/react/core/design-system/index.ts +1 -0
- package/src/react/core/hooks/transaction/transaction-button-utils.ts +1 -0
- package/src/react/core/hooks/transaction/useSendTransaction.ts +70 -1
- package/src/react/core/hooks/wallets/useAddConnectedWallet.ts +20 -0
- package/src/react/native/ui/connect/ConnectModal.tsx +1 -1
- package/src/react/native/ui/transaction/TransactionButton.tsx +1 -1
- package/src/react/web/ui/ConnectWallet/Details.tsx +158 -157
- package/src/react/web/ui/ConnectWallet/MenuButton.tsx +0 -1
- package/src/react/web/ui/ConnectWallet/Modal/AllWalletsUI.tsx +4 -1
- package/src/react/web/ui/ConnectWallet/Modal/AnyWalletConnectUI.tsx +1 -0
- package/src/react/web/ui/ConnectWallet/WalletSelector.tsx +10 -1
- package/src/react/web/ui/ConnectWallet/locale/en.ts +1 -1
- package/src/react/web/ui/ConnectWallet/screens/Buy/WalletSelectorButton.tsx +0 -6
- package/src/react/web/ui/ConnectWallet/screens/Buy/fiat/FiatFlow.tsx +10 -10
- package/src/react/web/ui/ConnectWallet/screens/Details/WalletManagerScreen.tsx +8 -9
- package/src/react/web/ui/ConnectWallet/screens/LinkProfileScreen.tsx +2 -0
- package/src/react/web/ui/ConnectWallet/screens/LinkedProfilesScreen.tsx +21 -7
- package/src/react/web/ui/TransactionButton/index.tsx +1 -1
- package/src/react/web/ui/components/ChainIcon.tsx +4 -3
- package/src/react/web/ui/components/CopyAddress.tsx +34 -0
- package/src/react/web/ui/components/IconContainer.tsx +31 -0
- package/src/react/web/ui/components/Modal.tsx +1 -1
- package/src/react/web/ui/components/WalletImage.tsx +1 -8
- package/src/react/web/ui/components/formElements.tsx +3 -3
- package/src/react/web/wallets/in-app/CountrySelector.tsx +2 -8
- package/src/react/web/wallets/in-app/InAppWalletConnectUI.tsx +18 -0
- package/src/react/web/wallets/in-app/WalletAuth.tsx +166 -0
- package/src/react/web/wallets/shared/ConnectWalletSocialOptions.tsx +22 -0
- package/src/react/web/wallets/shared/ErrorState.tsx +29 -0
- package/src/react/web/wallets/shared/LoadingState.tsx +47 -0
- package/src/react/web/wallets/shared/PassKeyLogin.tsx +4 -67
- package/src/react/web/wallets/shared/locale/de.ts +1 -0
- package/src/react/web/wallets/shared/locale/en.ts +2 -1
- package/src/react/web/wallets/shared/locale/es.ts +1 -0
- package/src/react/web/wallets/shared/locale/fr.ts +1 -0
- package/src/react/web/wallets/shared/locale/ja.ts +1 -0
- package/src/react/web/wallets/shared/locale/kr.ts +1 -0
- package/src/react/web/wallets/shared/locale/tl.ts +1 -0
- package/src/react/web/wallets/shared/locale/types.ts +1 -0
- package/src/react/web/wallets/shared/locale/vi.ts +1 -0
- package/src/transaction/actions/gasless/providers/biconomy.ts +3 -0
- package/src/transaction/actions/gasless/providers/engine.ts +3 -0
- package/src/transaction/actions/gasless/providers/openzeppelin.ts +3 -0
- package/src/transaction/actions/gasless/types.ts +12 -0
- package/src/transaction/prepare-contract-call.ts +1 -1
- package/src/transaction/read-contract.ts +21 -2
- package/src/utils/bigint.ts +2 -0
- package/src/version.ts +1 -1
- package/src/wallets/custom/smart/image.ts +1 -1
- package/src/wallets/in-app/core/authentication/getLoginPath.ts +4 -4
- package/src/wallets/in-app/core/authentication/types.ts +1 -1
- package/src/wallets/manager/index.ts +0 -2
- package/src/wallets/types.ts +0 -1
@@ -26,6 +26,7 @@ import {
|
|
26
26
|
import { setLastAuthProvider } from "../../../core/utils/storage.js";
|
27
27
|
import {
|
28
28
|
emailIcon,
|
29
|
+
getWalletIcon,
|
29
30
|
passkeyIcon,
|
30
31
|
phoneIcon,
|
31
32
|
socialIcons,
|
@@ -52,6 +53,7 @@ export type ConnectWalletSelectUIState =
|
|
52
53
|
connectionPromise: Promise<Account | Profile[]>;
|
53
54
|
};
|
54
55
|
passkeyLogin?: boolean;
|
56
|
+
walletLogin?: boolean;
|
55
57
|
};
|
56
58
|
|
57
59
|
const defaultAuthOptions: AuthOption[] = [
|
@@ -242,6 +244,13 @@ export const ConnectWalletSocialOptions = (
|
|
242
244
|
props.select();
|
243
245
|
}
|
244
246
|
|
247
|
+
function handleWalletLogin() {
|
248
|
+
setData({
|
249
|
+
walletLogin: true,
|
250
|
+
});
|
251
|
+
props.select();
|
252
|
+
}
|
253
|
+
|
245
254
|
const showOnlyIcons = socialLogins.length > 2;
|
246
255
|
|
247
256
|
return (
|
@@ -390,6 +399,19 @@ export const ConnectWalletSocialOptions = (
|
|
390
399
|
/>
|
391
400
|
</>
|
392
401
|
)}
|
402
|
+
|
403
|
+
{props.isLinking && (
|
404
|
+
<>
|
405
|
+
<WalletTypeRowButton
|
406
|
+
client={props.client}
|
407
|
+
icon={getWalletIcon("")}
|
408
|
+
onClick={() => {
|
409
|
+
handleWalletLogin();
|
410
|
+
}}
|
411
|
+
title={locale.linkWallet}
|
412
|
+
/>
|
413
|
+
</>
|
414
|
+
)}
|
393
415
|
</Container>
|
394
416
|
);
|
395
417
|
};
|
@@ -0,0 +1,29 @@
|
|
1
|
+
import { iconSize } from "../../../../react/core/design-system/index.js";
|
2
|
+
import { AccentFailIcon } from "../../ui/ConnectWallet/icons/AccentFailIcon.js";
|
3
|
+
import { Spacer } from "../../ui/components/Spacer.js";
|
4
|
+
import { Container } from "../../ui/components/basic.js";
|
5
|
+
import { Button } from "../../ui/components/buttons.js";
|
6
|
+
import { Text } from "../../ui/components/text.js";
|
7
|
+
|
8
|
+
export function ErrorState(props: {
|
9
|
+
onTryAgain: () => void;
|
10
|
+
title: string;
|
11
|
+
}) {
|
12
|
+
return (
|
13
|
+
<Container animate="fadein">
|
14
|
+
<Spacer y="xxl" />
|
15
|
+
<Container flex="row" center="x">
|
16
|
+
<AccentFailIcon size={iconSize["3xl"]} />
|
17
|
+
</Container>
|
18
|
+
<Spacer y="lg" />
|
19
|
+
<Text center color="primaryText" size="md">
|
20
|
+
{props.title}
|
21
|
+
</Text>
|
22
|
+
<Spacer y="xl" />
|
23
|
+
<Spacer y="xxl" />
|
24
|
+
<Button variant="accent" fullWidth onClick={props.onTryAgain}>
|
25
|
+
Try Again
|
26
|
+
</Button>
|
27
|
+
</Container>
|
28
|
+
);
|
29
|
+
}
|
@@ -0,0 +1,47 @@
|
|
1
|
+
import type { ReactNode } from "react";
|
2
|
+
import { Spacer } from "../../ui/components/Spacer.js";
|
3
|
+
import { Spinner } from "../../ui/components/Spinner.js";
|
4
|
+
import { Container } from "../../ui/components/basic.js";
|
5
|
+
import { Text } from "../../ui/components/text.js";
|
6
|
+
|
7
|
+
export function LoadingState(props: {
|
8
|
+
title: string;
|
9
|
+
subtitle: string;
|
10
|
+
icon: ReactNode;
|
11
|
+
}) {
|
12
|
+
return (
|
13
|
+
<Container animate="fadein">
|
14
|
+
<Spacer y="xxl" />
|
15
|
+
<Container
|
16
|
+
flex="row"
|
17
|
+
center="x"
|
18
|
+
style={{
|
19
|
+
position: "relative",
|
20
|
+
}}
|
21
|
+
>
|
22
|
+
<Spinner size="4xl" color="accentText" />
|
23
|
+
<Container
|
24
|
+
color="accentText"
|
25
|
+
style={{
|
26
|
+
position: "absolute",
|
27
|
+
top: "50%",
|
28
|
+
left: "50%",
|
29
|
+
transform: "translate(-50%, -50%)",
|
30
|
+
}}
|
31
|
+
>
|
32
|
+
{props.icon}
|
33
|
+
</Container>
|
34
|
+
</Container>
|
35
|
+
<Spacer y="xl" />
|
36
|
+
<Text center color="primaryText" size="lg">
|
37
|
+
{props.title}
|
38
|
+
</Text>
|
39
|
+
<Spacer y="md" />
|
40
|
+
<Text multiline center>
|
41
|
+
{props.subtitle}
|
42
|
+
</Text>
|
43
|
+
<Spacer y="xxl" />
|
44
|
+
<Spacer y="xxl" />
|
45
|
+
</Container>
|
46
|
+
);
|
47
|
+
}
|
@@ -7,15 +7,14 @@ import { isEcosystemWallet } from "../../../../wallets/ecosystem/is-ecosystem-wa
|
|
7
7
|
import { hasStoredPasskey } from "../../../../wallets/in-app/web/lib/auth/passkeys.js";
|
8
8
|
import { iconSize } from "../../../core/design-system/index.js";
|
9
9
|
import { setLastAuthProvider } from "../../../core/utils/storage.js";
|
10
|
-
import { AccentFailIcon } from "../../ui/ConnectWallet/icons/AccentFailIcon.js";
|
11
10
|
import { FingerPrintIcon } from "../../ui/ConnectWallet/icons/FingerPrintIcon.js";
|
12
11
|
import type { ConnectLocale } from "../../ui/ConnectWallet/locale/types.js";
|
13
12
|
import { Spacer } from "../../ui/components/Spacer.js";
|
14
|
-
import { Spinner } from "../../ui/components/Spinner.js";
|
15
13
|
import { Container, ModalHeader } from "../../ui/components/basic.js";
|
16
14
|
import { Button } from "../../ui/components/buttons.js";
|
17
|
-
import {
|
15
|
+
import { ErrorState } from "./ErrorState.js";
|
18
16
|
import { LoadingScreen } from "./LoadingScreen.js";
|
17
|
+
import { LoadingState } from "./LoadingState.js";
|
19
18
|
|
20
19
|
// is passkey stored?
|
21
20
|
// - login
|
@@ -179,6 +178,7 @@ function LoginScreen(props: {
|
|
179
178
|
<LoadingState
|
180
179
|
title="Requesting Passkey"
|
181
180
|
subtitle="A pop-up prompt will appear to sign-in and verify your passkey"
|
181
|
+
icon={<FingerPrintIcon size={iconSize.xxl} />}
|
182
182
|
/>
|
183
183
|
);
|
184
184
|
}
|
@@ -252,6 +252,7 @@ function SignupScreen(props: {
|
|
252
252
|
<LoadingState
|
253
253
|
title="Creating Passkey"
|
254
254
|
subtitle="A pop-up prompt will appear to sign-in and verify your passkey"
|
255
|
+
icon={<FingerPrintIcon size={iconSize.xxl} />}
|
255
256
|
/>
|
256
257
|
);
|
257
258
|
}
|
@@ -297,67 +298,3 @@ function SelectLoginMethod(props: {
|
|
297
298
|
</Container>
|
298
299
|
);
|
299
300
|
}
|
300
|
-
|
301
|
-
function ErrorState(props: {
|
302
|
-
onTryAgain: () => void;
|
303
|
-
title: string;
|
304
|
-
}) {
|
305
|
-
return (
|
306
|
-
<Container animate="fadein">
|
307
|
-
<Spacer y="xxl" />
|
308
|
-
<Container flex="row" center="x">
|
309
|
-
<AccentFailIcon size={iconSize["3xl"]} />
|
310
|
-
</Container>
|
311
|
-
<Spacer y="lg" />
|
312
|
-
<Text center color="primaryText" size="md">
|
313
|
-
{props.title}
|
314
|
-
</Text>
|
315
|
-
<Spacer y="xl" />
|
316
|
-
<Spacer y="xxl" />
|
317
|
-
<Button variant="accent" fullWidth onClick={props.onTryAgain}>
|
318
|
-
Try Again
|
319
|
-
</Button>
|
320
|
-
</Container>
|
321
|
-
);
|
322
|
-
}
|
323
|
-
|
324
|
-
function LoadingState(props: {
|
325
|
-
title: string;
|
326
|
-
subtitle: string;
|
327
|
-
}) {
|
328
|
-
return (
|
329
|
-
<Container animate="fadein">
|
330
|
-
<Spacer y="xxl" />
|
331
|
-
<Container
|
332
|
-
flex="row"
|
333
|
-
center="x"
|
334
|
-
style={{
|
335
|
-
position: "relative",
|
336
|
-
}}
|
337
|
-
>
|
338
|
-
<Spinner size="4xl" color="accentText" />
|
339
|
-
<Container
|
340
|
-
color="accentText"
|
341
|
-
style={{
|
342
|
-
position: "absolute",
|
343
|
-
top: "50%",
|
344
|
-
left: "50%",
|
345
|
-
transform: "translate(-50%, -50%)",
|
346
|
-
}}
|
347
|
-
>
|
348
|
-
<FingerPrintIcon size={iconSize.xxl} />
|
349
|
-
</Container>
|
350
|
-
</Container>
|
351
|
-
<Spacer y="xl" />
|
352
|
-
<Text center color="primaryText" size="lg">
|
353
|
-
{props.title}
|
354
|
-
</Text>
|
355
|
-
<Spacer y="md" />
|
356
|
-
<Text multiline center>
|
357
|
-
{props.subtitle}
|
358
|
-
</Text>
|
359
|
-
<Spacer y="xxl" />
|
360
|
-
<Spacer y="xxl" />
|
361
|
-
</Container>
|
362
|
-
);
|
363
|
-
}
|
@@ -53,6 +53,7 @@ export default {
|
|
53
53
|
invalidPhone: "Invalid phone number",
|
54
54
|
phonePlaceholder: "Phone number",
|
55
55
|
signInWithPhone: "Sign in with phone number",
|
56
|
-
phoneRequired: "
|
56
|
+
phoneRequired: "Phone number is required",
|
57
57
|
passkey: "Passkey",
|
58
|
+
linkWallet: "Link a Wallet",
|
58
59
|
} satisfies InAppWalletLocale;
|
@@ -10,6 +10,9 @@ import type { PreparedTransaction } from "../../../prepare-transaction.js";
|
|
10
10
|
import { readContract } from "../../../read-contract.js";
|
11
11
|
import type { WaitForReceiptOptions } from "../../wait-for-tx-receipt.js";
|
12
12
|
|
13
|
+
/**
|
14
|
+
* @transaction
|
15
|
+
*/
|
13
16
|
export type BiconomyOptions = {
|
14
17
|
provider: "biconomy";
|
15
18
|
// you can find the correct forwarder for your network here: https://docs-gasless.biconomy.io/misc/contract-addresses
|
@@ -8,6 +8,9 @@ import type { PreparedTransaction } from "../../../prepare-transaction.js";
|
|
8
8
|
import { readContract } from "../../../read-contract.js";
|
9
9
|
import type { WaitForReceiptOptions } from "../../wait-for-tx-receipt.js";
|
10
10
|
|
11
|
+
/**
|
12
|
+
* @transaction
|
13
|
+
*/
|
11
14
|
export type OpenZeppelinOptions = {
|
12
15
|
provider: "openzeppelin";
|
13
16
|
relayerUrl: string;
|
@@ -2,6 +2,18 @@ import type { BiconomyOptions } from "./providers/biconomy.js";
|
|
2
2
|
import type { EngineOptions } from "./providers/engine.js";
|
3
3
|
import type { OpenZeppelinOptions } from "./providers/openzeppelin.js";
|
4
4
|
|
5
|
+
/**
|
6
|
+
* Gasless configs for sending gasless transactions.
|
7
|
+
* This config is used in:
|
8
|
+
* - [`TransactionButton`](https://portal.thirdweb.com/references/typescript/v5/TransactionButton)
|
9
|
+
* - [`sendTransaction`](https://portal.thirdweb.com/references/typescript/v5/sendTransaction)
|
10
|
+
* - [`useSendTransaction`](https://portal.thirdweb.com/references/typescript/v5/useSendTransaction)
|
11
|
+
* - [`sendAndConfirmTransaction`](https://portal.thirdweb.com/references/typescript/v5/sendAndConfirmTransaction)
|
12
|
+
* - [`useSendAndConfirmTransaction`](https://portal.thirdweb.com/references/typescript/v5/useSendAndConfirmTransaction)
|
13
|
+
*
|
14
|
+
* Please refer to the docs of those components above for more info.
|
15
|
+
* @transaction
|
16
|
+
*/
|
5
17
|
export type GaslessOptions =
|
6
18
|
| EngineOptions
|
7
19
|
| OpenZeppelinOptions
|
@@ -113,7 +113,7 @@ export type PrepareContractCallOptions<
|
|
113
113
|
* });
|
114
114
|
* ```
|
115
115
|
*
|
116
|
-
* ### Usage with
|
116
|
+
* ### Usage with the ABI defined on the contract:
|
117
117
|
*
|
118
118
|
* ```ts
|
119
119
|
* import { getContract, prepareContractCall } from "thirdweb";
|
@@ -70,7 +70,7 @@ export type ReadContractOptions<
|
|
70
70
|
>;
|
71
71
|
|
72
72
|
/**
|
73
|
-
* Reads state from a deployed smart contract.
|
73
|
+
* ### Reads state from a deployed smart contract.
|
74
74
|
*
|
75
75
|
* You can use raw read calls or read [extensions](https://portal.thirdweb.com/typescript/v5/extensions/use) to read from a contract.
|
76
76
|
*
|
@@ -111,7 +111,26 @@ export type ReadContractOptions<
|
|
111
111
|
*
|
112
112
|
* const { data, isLoading } = useReadContract({
|
113
113
|
* contract,
|
114
|
-
* method: "function tokenURI(uint256 tokenId) returns (string)"})
|
114
|
+
* method: "function tokenURI(uint256 tokenId) returns (string)"}),
|
115
|
+
* params: [1n],
|
116
|
+
* });
|
117
|
+
* ```
|
118
|
+
*
|
119
|
+
* ### Using `resolveMethod`
|
120
|
+
* ```ts
|
121
|
+
* import { getContract, resolveMethod } from "thirdweb";
|
122
|
+
* import { sepolia } from "thirdweb/chains";
|
123
|
+
* import { useReadContract } from "thirdweb/react";
|
124
|
+
*
|
125
|
+
* const contract = getContract({
|
126
|
+
* client,
|
127
|
+
* address: "0x...",
|
128
|
+
* chain: sepolia,
|
129
|
+
* });
|
130
|
+
*
|
131
|
+
* const { data, isLoading } = useReadContract({
|
132
|
+
* contract,
|
133
|
+
* method: resolveMethod("tokenURI"),
|
115
134
|
* params: [1n],
|
116
135
|
* });
|
117
136
|
* ```
|
package/src/utils/bigint.ts
CHANGED
@@ -5,6 +5,7 @@ import { uint8ArrayToHex } from "./encoding/hex.js";
|
|
5
5
|
* @param a - The first BigInt value.
|
6
6
|
* @param b - The second BigInt value.
|
7
7
|
* @returns The smaller of the two BigInt values.
|
8
|
+
* @utils
|
8
9
|
* @example
|
9
10
|
* ```ts
|
10
11
|
* min(1n, 2n)
|
@@ -19,6 +20,7 @@ export function min(a: bigint, b: bigint) {
|
|
19
20
|
* @param a - The first BigInt value.
|
20
21
|
* @param b - The second BigInt value.
|
21
22
|
* @returns The larger of the two BigInt values.
|
23
|
+
* @utils
|
22
24
|
* @example
|
23
25
|
* ```ts
|
24
26
|
* max(1n, 2n)
|
package/src/version.ts
CHANGED
@@ -1 +1 @@
|
|
1
|
-
export const version = "5.
|
1
|
+
export const version = "5.48.0";
|
@@ -1,4 +1,4 @@
|
|
1
1
|
const image =
|
2
|
-
"data:image/svg+xml;base64,
|
2
|
+
"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjQiIGhlaWdodD0iMjQiIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTIwIDEzLjAwMDRDMjAgMTguMDAwNCAxNi41IDIwLjUwMDUgMTIuMzQgMjEuOTUwNUMxMi4xMjIyIDIyLjAyNDMgMTEuODg1NSAyMi4wMjA3IDExLjY3IDIxLjk0MDVDNy41IDIwLjUwMDUgNCAxOC4wMDA0IDQgMTMuMDAwNFY2LjAwMDQ1QzQgNS43MzUyMyA0LjEwNTM2IDUuNDgwODggNC4yOTI4OSA1LjI5MzM0QzQuNDgwNDMgNS4xMDU4MSA0LjczNDc4IDUuMDAwNDUgNSA1LjAwMDQ1QzcgNS4wMDA0NSA5LjUgMy44MDA0NSAxMS4yNCAyLjI4MDQ1QzExLjQ1MTkgMi4wOTk0NSAxMS43MjE0IDIgMTIgMkMxMi4yNzg2IDIgMTIuNTQ4MSAyLjA5OTQ1IDEyLjc2IDIuMjgwNDVDMTQuNTEgMy44MTA0NSAxNyA1LjAwMDQ1IDE5IDUuMDAwNDVDMTkuMjY1MiA1LjAwMDQ1IDE5LjUxOTYgNS4xMDU4MSAxOS43MDcxIDUuMjkzMzRDMTkuODk0NiA1LjQ4MDg4IDIwIDUuNzM1MjMgMjAgNi4wMDA0NVYxMy4wMDA0WiIgc3Ryb2tlPSIjMzM4NUZGIiBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPgo8cGF0aCBkPSJNOSAxMkwxMSAxNEwxNSAxMCIgc3Ryb2tlPSIjMzM4NUZGIiBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPgo8L3N2Zz4K";
|
3
3
|
|
4
4
|
export default image;
|
@@ -3,8 +3,8 @@ import { getThirdwebBaseUrl } from "../../../../utils/domains.js";
|
|
3
3
|
import { type AuthOption, authOptions } from "../../../../wallets/types.js";
|
4
4
|
import type { Ecosystem } from "../../web/types.js";
|
5
5
|
|
6
|
-
const getLoginOptionRoute = (option: AuthOption) => {
|
7
|
-
if (!authOptions.includes(option)) {
|
6
|
+
const getLoginOptionRoute = (option: AuthOption | "wallet") => {
|
7
|
+
if (!authOptions.includes(option as AuthOption) && option !== "wallet") {
|
8
8
|
throw new Error(`Unknown auth option ${option}`);
|
9
9
|
}
|
10
10
|
switch (option) {
|
@@ -22,7 +22,7 @@ export const getLoginUrl = ({
|
|
22
22
|
mode = "popup",
|
23
23
|
redirectUrl,
|
24
24
|
}: {
|
25
|
-
authOption: AuthOption;
|
25
|
+
authOption: AuthOption | "wallet";
|
26
26
|
client: ThirdwebClient;
|
27
27
|
ecosystem?: Ecosystem;
|
28
28
|
mode?: "popup" | "redirect" | "mobile";
|
@@ -58,7 +58,7 @@ export const getLoginCallbackUrl = ({
|
|
58
58
|
client,
|
59
59
|
ecosystem,
|
60
60
|
}: {
|
61
|
-
authOption: AuthOption;
|
61
|
+
authOption: AuthOption | "wallet";
|
62
62
|
client: ThirdwebClient;
|
63
63
|
ecosystem?: Ecosystem;
|
64
64
|
}): string => {
|