@getpara/react-sdk-lite 2.18.0 → 2.19.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.
Files changed (144) hide show
  1. package/dist/aa/hooks/alchemy.d.ts +15 -0
  2. package/dist/aa/hooks/alchemy.js +9 -0
  3. package/dist/aa/hooks/biconomy.d.ts +15 -0
  4. package/dist/aa/hooks/biconomy.js +9 -0
  5. package/dist/aa/hooks/cdp.d.ts +14 -0
  6. package/dist/aa/hooks/cdp.js +9 -0
  7. package/dist/aa/hooks/gelato.d.ts +14 -0
  8. package/dist/aa/hooks/gelato.js +9 -0
  9. package/dist/aa/hooks/pimlico.d.ts +15 -0
  10. package/dist/aa/hooks/pimlico.js +9 -0
  11. package/dist/aa/hooks/porto.d.ts +15 -0
  12. package/dist/aa/hooks/porto.js +9 -0
  13. package/dist/aa/hooks/rhinestone.d.ts +15 -0
  14. package/dist/aa/hooks/rhinestone.js +9 -0
  15. package/dist/aa/hooks/safe.d.ts +15 -0
  16. package/dist/aa/hooks/safe.js +9 -0
  17. package/dist/aa/hooks/thirdweb.d.ts +13 -0
  18. package/dist/aa/hooks/thirdweb.js +9 -0
  19. package/dist/aa/hooks/zerodev.d.ts +15 -0
  20. package/dist/aa/hooks/zerodev.js +9 -0
  21. package/dist/aa/useWagmiSignerEnhancer.d.ts +15 -0
  22. package/dist/aa/useWagmiSignerEnhancer.js +45 -0
  23. package/dist/cli/cli.mjs +0 -0
  24. package/dist/index.d.ts +11 -12
  25. package/dist/index.js +10 -12
  26. package/dist/modal/ParaModal.js +1 -1
  27. package/dist/modal/components/Header/hooks/useStepTitle.d.ts +1 -1
  28. package/dist/modal/components/OnRampComponents/OnRampProviderButton.js +1 -1
  29. package/dist/modal/components/QuantityInput.js +1 -0
  30. package/dist/modal/components/SearchableButtonList.js +20 -11
  31. package/dist/modal/components/flows/account/AddFunds/AddFundsSettings.js +1 -0
  32. package/dist/modal/components/flows/account/Wallet/Wallet.js +1 -1
  33. package/dist/provider/ParaProviderMin.js +46 -54
  34. package/dist/provider/actions/index.d.ts +2 -34
  35. package/dist/provider/actions/index.js +43 -34
  36. package/dist/provider/hooks/mutations/index.d.ts +2 -29
  37. package/dist/provider/hooks/mutations/index.js +3 -58
  38. package/dist/provider/hooks/mutations/useAddAuthMethod.d.ts +2 -2
  39. package/dist/provider/hooks/mutations/useExportPrivateKey.d.ts +24 -4
  40. package/dist/provider/hooks/mutations/useExportPrivateKey.js +7 -2
  41. package/dist/provider/hooks/mutations/useSwitchWallets.d.ts +2 -2
  42. package/dist/provider/hooks/mutations/useVerifyNewAccount.d.ts +2 -2
  43. package/dist/provider/hooks/queries/index.d.ts +2 -2
  44. package/dist/provider/hooks/queries/index.js +2 -3
  45. package/dist/provider/hooks/queries/useAccount.d.ts +14 -69
  46. package/dist/provider/hooks/queries/useAccount.js +30 -136
  47. package/dist/provider/hooks/queries/useParaStatus.d.ts +7 -11
  48. package/dist/provider/hooks/queries/useParaStatus.js +9 -16
  49. package/dist/provider/hooks/queries/useProfileBalance.js +1 -1
  50. package/dist/provider/hooks/utils/useAutoSessionKeepAlive.js +14 -10
  51. package/dist/provider/hooks/utils/useEventListeners.js +1 -1
  52. package/dist/provider/index.d.ts +1 -0
  53. package/dist/provider/utils/renameMutations.d.ts +4 -2
  54. package/package.json +19 -18
  55. package/dist/aa/alchemy/hook.d.ts +0 -16708
  56. package/dist/aa/alchemy/hook.js +0 -26
  57. package/dist/aa/biconomy/hook.d.ts +0 -44
  58. package/dist/aa/biconomy/hook.js +0 -26
  59. package/dist/aa/cdp/hook.d.ts +0 -11
  60. package/dist/aa/cdp/hook.js +0 -26
  61. package/dist/aa/createSmartAccountHook.d.ts +0 -13
  62. package/dist/aa/createSmartAccountHook.js +0 -81
  63. package/dist/aa/gelato/hook.d.ts +0 -11
  64. package/dist/aa/gelato/hook.js +0 -26
  65. package/dist/aa/pimlico/hook.d.ts +0 -838
  66. package/dist/aa/pimlico/hook.js +0 -26
  67. package/dist/aa/porto/hook.d.ts +0 -12
  68. package/dist/aa/porto/hook.js +0 -26
  69. package/dist/aa/rhinestone/hook.d.ts +0 -12
  70. package/dist/aa/rhinestone/hook.js +0 -26
  71. package/dist/aa/safe/hook.d.ts +0 -12
  72. package/dist/aa/safe/hook.js +0 -26
  73. package/dist/aa/thirdweb/hook.d.ts +0 -12
  74. package/dist/aa/thirdweb/hook.js +0 -26
  75. package/dist/aa/types.d.ts +0 -21
  76. package/dist/aa/types.js +0 -1
  77. package/dist/aa/zerodev/hook.d.ts +0 -12
  78. package/dist/aa/zerodev/hook.js +0 -26
  79. package/dist/modal/components/flows/account/AddFunds/MoonPayEmbed.d.ts +0 -2
  80. package/dist/modal/components/flows/account/AddFunds/MoonPayEmbed.js +0 -7
  81. package/dist/provider/actions/getEmbeddedAccount.d.ts +0 -27
  82. package/dist/provider/actions/getEmbeddedAccount.js +0 -66
  83. package/dist/provider/actions/getWallet.d.ts +0 -5
  84. package/dist/provider/actions/getWallet.js +0 -18
  85. package/dist/provider/hooks/mutations/useAuthenticateWithEmailOrPhone.d.ts +0 -34
  86. package/dist/provider/hooks/mutations/useAuthenticateWithEmailOrPhone.js +0 -28
  87. package/dist/provider/hooks/mutations/useAuthenticateWithOAuth.d.ts +0 -34
  88. package/dist/provider/hooks/mutations/useAuthenticateWithOAuth.js +0 -28
  89. package/dist/provider/hooks/mutations/useClaimPregenWallets.d.ts +0 -34
  90. package/dist/provider/hooks/mutations/useClaimPregenWallets.js +0 -31
  91. package/dist/provider/hooks/mutations/useCreateGuestWallets.d.ts +0 -34
  92. package/dist/provider/hooks/mutations/useCreateGuestWallets.js +0 -31
  93. package/dist/provider/hooks/mutations/useCreatePregenWallet.d.ts +0 -34
  94. package/dist/provider/hooks/mutations/useCreatePregenWallet.js +0 -31
  95. package/dist/provider/hooks/mutations/useCreatePregenWalletPerType.d.ts +0 -34
  96. package/dist/provider/hooks/mutations/useCreatePregenWalletPerType.js +0 -28
  97. package/dist/provider/hooks/mutations/useCreateWallet.d.ts +0 -34
  98. package/dist/provider/hooks/mutations/useCreateWallet.js +0 -31
  99. package/dist/provider/hooks/mutations/useCreateWalletPerType.d.ts +0 -34
  100. package/dist/provider/hooks/mutations/useCreateWalletPerType.js +0 -28
  101. package/dist/provider/hooks/mutations/useEnable2fa.d.ts +0 -34
  102. package/dist/provider/hooks/mutations/useEnable2fa.js +0 -28
  103. package/dist/provider/hooks/mutations/useHasPregenWallet.d.ts +0 -34
  104. package/dist/provider/hooks/mutations/useHasPregenWallet.js +0 -28
  105. package/dist/provider/hooks/mutations/useIssueJwt.d.ts +0 -34
  106. package/dist/provider/hooks/mutations/useIssueJwt.js +0 -28
  107. package/dist/provider/hooks/mutations/useKeepSessionAlive.d.ts +0 -33
  108. package/dist/provider/hooks/mutations/useKeepSessionAlive.js +0 -28
  109. package/dist/provider/hooks/mutations/useLoginExternalWallet.d.ts +0 -34
  110. package/dist/provider/hooks/mutations/useLoginExternalWallet.js +0 -31
  111. package/dist/provider/hooks/mutations/useLogout.d.ts +0 -34
  112. package/dist/provider/hooks/mutations/useLogout.js +0 -28
  113. package/dist/provider/hooks/mutations/useResendVerificationCode.d.ts +0 -34
  114. package/dist/provider/hooks/mutations/useResendVerificationCode.js +0 -31
  115. package/dist/provider/hooks/mutations/useSetup2fa.d.ts +0 -34
  116. package/dist/provider/hooks/mutations/useSetup2fa.js +0 -28
  117. package/dist/provider/hooks/mutations/useSignMessage.d.ts +0 -34
  118. package/dist/provider/hooks/mutations/useSignMessage.js +0 -28
  119. package/dist/provider/hooks/mutations/useSignTransaction.d.ts +0 -34
  120. package/dist/provider/hooks/mutations/useSignTransaction.js +0 -31
  121. package/dist/provider/hooks/mutations/useSignUpOrLogIn.d.ts +0 -34
  122. package/dist/provider/hooks/mutations/useSignUpOrLogIn.js +0 -31
  123. package/dist/provider/hooks/mutations/useUpdatePregenWalletIdentifier.d.ts +0 -34
  124. package/dist/provider/hooks/mutations/useUpdatePregenWalletIdentifier.js +0 -31
  125. package/dist/provider/hooks/mutations/useVerify2fa.d.ts +0 -34
  126. package/dist/provider/hooks/mutations/useVerify2fa.js +0 -28
  127. package/dist/provider/hooks/mutations/useVerifyExternalWallet.d.ts +0 -34
  128. package/dist/provider/hooks/mutations/useVerifyExternalWallet.js +0 -31
  129. package/dist/provider/hooks/mutations/useVerifyFarcaster.d.ts +0 -34
  130. package/dist/provider/hooks/mutations/useVerifyFarcaster.js +0 -31
  131. package/dist/provider/hooks/mutations/useVerifyOAuth.d.ts +0 -34
  132. package/dist/provider/hooks/mutations/useVerifyOAuth.js +0 -28
  133. package/dist/provider/hooks/mutations/useVerifyTelegram.d.ts +0 -34
  134. package/dist/provider/hooks/mutations/useVerifyTelegram.js +0 -28
  135. package/dist/provider/hooks/mutations/useWaitForLogin.d.ts +0 -34
  136. package/dist/provider/hooks/mutations/useWaitForLogin.js +0 -31
  137. package/dist/provider/hooks/mutations/useWaitForSignup.d.ts +0 -34
  138. package/dist/provider/hooks/mutations/useWaitForSignup.js +0 -28
  139. package/dist/provider/hooks/mutations/useWaitForWalletCreation.d.ts +0 -34
  140. package/dist/provider/hooks/mutations/useWaitForWalletCreation.js +0 -28
  141. package/dist/provider/hooks/queries/useIsFullyLoggedIn.d.ts +0 -8
  142. package/dist/provider/hooks/queries/useIsFullyLoggedIn.js +0 -29
  143. package/dist/provider/hooks/queries/useWallet.d.ts +0 -5
  144. package/dist/provider/hooks/queries/useWallet.js +0 -26
@@ -0,0 +1,15 @@
1
+ import { ALCHEMY_SMART_ACCOUNT_BASE_KEY } from '@getpara/react-core/internal';
2
+ export { ALCHEMY_SMART_ACCOUNT_BASE_KEY };
3
+ /**
4
+ * React / React Native hook to create and manage an Alchemy smart account.
5
+ *
6
+ * Supports both EIP-4337 and EIP-7702 modes. Uses Alchemy's Account Kit for
7
+ * bundler and paymaster infrastructure.
8
+ *
9
+ * Requires `@getpara/aa-alchemy` to be installed.
10
+ * On web, automatically detects connected external wallets (MetaMask, etc.) via wagmi
11
+ * and uses them as the signer when no Para embedded wallet is active.
12
+ */
13
+ export declare const useAlchemySmartAccount: (params?: import("@getpara/aa-alchemy").AlchemySmartAccountConfig & {
14
+ enabled?: boolean;
15
+ }) => import("@getpara/react-core/internal").UseSmartAccountResult<import("@getpara/aa-alchemy").SmartAccount>;
@@ -0,0 +1,9 @@
1
+ "use client";
2
+ import "../../chunk-MMUBH76A.js";
3
+ import { createAlchemySmartAccountHook, ALCHEMY_SMART_ACCOUNT_BASE_KEY } from "@getpara/react-core/internal";
4
+ import { useWagmiSignerEnhancer } from "../useWagmiSignerEnhancer.js";
5
+ const useAlchemySmartAccount = createAlchemySmartAccountHook(useWagmiSignerEnhancer);
6
+ export {
7
+ ALCHEMY_SMART_ACCOUNT_BASE_KEY,
8
+ useAlchemySmartAccount
9
+ };
@@ -0,0 +1,15 @@
1
+ import { BICONOMY_SMART_ACCOUNT_BASE_KEY } from '@getpara/react-core/internal';
2
+ export { BICONOMY_SMART_ACCOUNT_BASE_KEY };
3
+ /**
4
+ * React / React Native hook to create and manage a Biconomy smart account.
5
+ *
6
+ * Supports both EIP-4337 and EIP-7702 modes. Transactions are executed via
7
+ * Biconomy's MEE (Multi-chain Execution Environment).
8
+ *
9
+ * Requires `@getpara/aa-biconomy` to be installed.
10
+ * On web, automatically detects connected external wallets (MetaMask, etc.) via wagmi
11
+ * and uses them as the signer when no Para embedded wallet is active.
12
+ */
13
+ export declare const useBiconomySmartAccount: (params?: import("@getpara/aa-biconomy").BiconomySmartAccountConfig & {
14
+ enabled?: boolean;
15
+ }) => import("@getpara/react-core/internal").UseSmartAccountResult<import("@getpara/aa-alchemy").SmartAccount>;
@@ -0,0 +1,9 @@
1
+ "use client";
2
+ import "../../chunk-MMUBH76A.js";
3
+ import { createBiconomySmartAccountHook, BICONOMY_SMART_ACCOUNT_BASE_KEY } from "@getpara/react-core/internal";
4
+ import { useWagmiSignerEnhancer } from "../useWagmiSignerEnhancer.js";
5
+ const useBiconomySmartAccount = createBiconomySmartAccountHook(useWagmiSignerEnhancer);
6
+ export {
7
+ BICONOMY_SMART_ACCOUNT_BASE_KEY,
8
+ useBiconomySmartAccount
9
+ };
@@ -0,0 +1,14 @@
1
+ import { CDP_SMART_ACCOUNT_BASE_KEY } from '@getpara/react-core/internal';
2
+ export { CDP_SMART_ACCOUNT_BASE_KEY };
3
+ /**
4
+ * React / React Native hook to create and manage a Coinbase Developer Platform smart account.
5
+ *
6
+ * CDP operates in EIP-4337 mode only. Only supports Base and Base Sepolia.
7
+ *
8
+ * Requires `@getpara/aa-cdp` to be installed.
9
+ * On web, automatically detects connected external wallets (MetaMask, etc.) via wagmi
10
+ * and uses them as the signer when no Para embedded wallet is active.
11
+ */
12
+ export declare const useCDPSmartAccount: (params?: import("@getpara/aa-cdp").CDPSmartAccountConfig & {
13
+ enabled?: boolean;
14
+ }) => import("@getpara/react-core/internal").UseSmartAccountResult<import("@getpara/aa-alchemy").SmartAccount>;
@@ -0,0 +1,9 @@
1
+ "use client";
2
+ import "../../chunk-MMUBH76A.js";
3
+ import { createCDPSmartAccountHook, CDP_SMART_ACCOUNT_BASE_KEY } from "@getpara/react-core/internal";
4
+ import { useWagmiSignerEnhancer } from "../useWagmiSignerEnhancer.js";
5
+ const useCDPSmartAccount = createCDPSmartAccountHook(useWagmiSignerEnhancer);
6
+ export {
7
+ CDP_SMART_ACCOUNT_BASE_KEY,
8
+ useCDPSmartAccount
9
+ };
@@ -0,0 +1,14 @@
1
+ import { GELATO_SMART_ACCOUNT_BASE_KEY } from '@getpara/react-core/internal';
2
+ export { GELATO_SMART_ACCOUNT_BASE_KEY };
3
+ /**
4
+ * React / React Native hook to create and manage a Gelato smart account.
5
+ *
6
+ * Gelato operates in EIP-7702 mode only. Uses Gelato's relay for gas-sponsored transactions.
7
+ *
8
+ * Requires `@getpara/aa-gelato` to be installed.
9
+ * On web, automatically detects connected external wallets (MetaMask, etc.) via wagmi
10
+ * and uses them as the signer when no Para embedded wallet is active.
11
+ */
12
+ export declare const useGelatoSmartAccount: (params?: import("@getpara/aa-gelato").GelatoSmartAccountConfig & {
13
+ enabled?: boolean;
14
+ }) => import("@getpara/react-core/internal").UseSmartAccountResult<import("@getpara/aa-alchemy").SmartAccount>;
@@ -0,0 +1,9 @@
1
+ "use client";
2
+ import "../../chunk-MMUBH76A.js";
3
+ import { createGelatoSmartAccountHook, GELATO_SMART_ACCOUNT_BASE_KEY } from "@getpara/react-core/internal";
4
+ import { useWagmiSignerEnhancer } from "../useWagmiSignerEnhancer.js";
5
+ const useGelatoSmartAccount = createGelatoSmartAccountHook(useWagmiSignerEnhancer);
6
+ export {
7
+ GELATO_SMART_ACCOUNT_BASE_KEY,
8
+ useGelatoSmartAccount
9
+ };
@@ -0,0 +1,15 @@
1
+ import { PIMLICO_SMART_ACCOUNT_BASE_KEY } from '@getpara/react-core/internal';
2
+ export { PIMLICO_SMART_ACCOUNT_BASE_KEY };
3
+ /**
4
+ * React / React Native hook to create and manage a Pimlico smart account.
5
+ *
6
+ * Supports both EIP-4337 and EIP-7702 modes. Uses Pimlico's bundler and paymaster
7
+ * infrastructure for gas sponsorship.
8
+ *
9
+ * Requires `@getpara/aa-pimlico` to be installed.
10
+ * On web, automatically detects connected external wallets (MetaMask, etc.) via wagmi
11
+ * and uses them as the signer when no Para embedded wallet is active.
12
+ */
13
+ export declare const usePimlicoSmartAccount: (params?: import("@getpara/aa-pimlico").PimlicoSmartAccountConfig & {
14
+ enabled?: boolean;
15
+ }) => import("@getpara/react-core/internal").UseSmartAccountResult<import("@getpara/aa-alchemy").SmartAccount>;
@@ -0,0 +1,9 @@
1
+ "use client";
2
+ import "../../chunk-MMUBH76A.js";
3
+ import { createPimlicoSmartAccountHook, PIMLICO_SMART_ACCOUNT_BASE_KEY } from "@getpara/react-core/internal";
4
+ import { useWagmiSignerEnhancer } from "../useWagmiSignerEnhancer.js";
5
+ const usePimlicoSmartAccount = createPimlicoSmartAccountHook(useWagmiSignerEnhancer);
6
+ export {
7
+ PIMLICO_SMART_ACCOUNT_BASE_KEY,
8
+ usePimlicoSmartAccount
9
+ };
@@ -0,0 +1,15 @@
1
+ import { PORTO_ACCOUNT_BASE_KEY } from '@getpara/react-core/internal';
2
+ export { PORTO_ACCOUNT_BASE_KEY };
3
+ /**
4
+ * React / React Native hook to create and manage a Porto smart account.
5
+ *
6
+ * Porto operates in EIP-7702 mode only. No API key required — Porto uses its own relay RPC.
7
+ * On testnets, Porto's relay sponsors gas by default. For mainnet, pass `merchantUrl`.
8
+ *
9
+ * Requires `@getpara/aa-porto` to be installed.
10
+ * On web, automatically detects connected external wallets (MetaMask, etc.) via wagmi
11
+ * and uses them as the signer when no Para embedded wallet is active.
12
+ */
13
+ export declare const usePortoSmartAccount: (params?: import("@getpara/aa-porto").PortoAccountConfig & {
14
+ enabled?: boolean;
15
+ }) => import("@getpara/react-core/internal").UseSmartAccountResult<import("@getpara/aa-alchemy").SmartAccount>;
@@ -0,0 +1,9 @@
1
+ "use client";
2
+ import "../../chunk-MMUBH76A.js";
3
+ import { createPortoSmartAccountHook, PORTO_ACCOUNT_BASE_KEY } from "@getpara/react-core/internal";
4
+ import { useWagmiSignerEnhancer } from "../useWagmiSignerEnhancer.js";
5
+ const usePortoSmartAccount = createPortoSmartAccountHook(useWagmiSignerEnhancer);
6
+ export {
7
+ PORTO_ACCOUNT_BASE_KEY,
8
+ usePortoSmartAccount
9
+ };
@@ -0,0 +1,15 @@
1
+ import { RHINESTONE_SMART_ACCOUNT_BASE_KEY } from '@getpara/react-core/internal';
2
+ export { RHINESTONE_SMART_ACCOUNT_BASE_KEY };
3
+ /**
4
+ * React / React Native hook to create and manage a Rhinestone smart account.
5
+ *
6
+ * Rhinestone operates in EIP-4337 mode only. Uses Rhinestone's orchestrator
7
+ * with Pimlico's bundler infrastructure.
8
+ *
9
+ * Requires `@getpara/aa-rhinestone` to be installed.
10
+ * On web, automatically detects connected external wallets (MetaMask, etc.) via wagmi
11
+ * and uses them as the signer when no Para embedded wallet is active.
12
+ */
13
+ export declare const useRhinestoneSmartAccount: (params?: import("@getpara/aa-rhinestone").RhinestoneSmartAccountConfig & {
14
+ enabled?: boolean;
15
+ }) => import("@getpara/react-core/internal").UseSmartAccountResult<import("@getpara/aa-alchemy").SmartAccount>;
@@ -0,0 +1,9 @@
1
+ "use client";
2
+ import "../../chunk-MMUBH76A.js";
3
+ import { createRhinestoneSmartAccountHook, RHINESTONE_SMART_ACCOUNT_BASE_KEY } from "@getpara/react-core/internal";
4
+ import { useWagmiSignerEnhancer } from "../useWagmiSignerEnhancer.js";
5
+ const useRhinestoneSmartAccount = createRhinestoneSmartAccountHook(useWagmiSignerEnhancer);
6
+ export {
7
+ RHINESTONE_SMART_ACCOUNT_BASE_KEY,
8
+ useRhinestoneSmartAccount
9
+ };
@@ -0,0 +1,15 @@
1
+ import { SAFE_SMART_ACCOUNT_BASE_KEY } from '@getpara/react-core/internal';
2
+ export { SAFE_SMART_ACCOUNT_BASE_KEY };
3
+ /**
4
+ * React / React Native hook to create and manage a Safe smart account.
5
+ *
6
+ * Safe operates in EIP-4337 mode only. Uses permissionless's Safe implementation
7
+ * with Pimlico's bundler and paymaster infrastructure.
8
+ *
9
+ * Requires `@getpara/aa-safe` to be installed.
10
+ * On web, automatically detects connected external wallets (MetaMask, etc.) via wagmi
11
+ * and uses them as the signer when no Para embedded wallet is active.
12
+ */
13
+ export declare const useSafeSmartAccount: (params?: import("@getpara/aa-safe").SafeSmartAccountConfig & {
14
+ enabled?: boolean;
15
+ }) => import("@getpara/react-core/internal").UseSmartAccountResult<import("@getpara/aa-alchemy").SmartAccount>;
@@ -0,0 +1,9 @@
1
+ "use client";
2
+ import "../../chunk-MMUBH76A.js";
3
+ import { createSafeSmartAccountHook, SAFE_SMART_ACCOUNT_BASE_KEY } from "@getpara/react-core/internal";
4
+ import { useWagmiSignerEnhancer } from "../useWagmiSignerEnhancer.js";
5
+ const useSafeSmartAccount = createSafeSmartAccountHook(useWagmiSignerEnhancer);
6
+ export {
7
+ SAFE_SMART_ACCOUNT_BASE_KEY,
8
+ useSafeSmartAccount
9
+ };
@@ -0,0 +1,13 @@
1
+ import { THIRDWEB_SMART_ACCOUNT_BASE_KEY } from '@getpara/react-core/internal';
2
+ export { THIRDWEB_SMART_ACCOUNT_BASE_KEY };
3
+ /**
4
+ * React / React Native hook to create and manage a Thirdweb smart account.
5
+ *
6
+ * Supports both EIP-4337 and EIP-7702 modes. Uses Thirdweb's smart wallet
7
+ * infrastructure with optional gas sponsorship.
8
+ *
9
+ * Requires `@getpara/aa-thirdweb` to be installed.
10
+ * On web, automatically detects connected external wallets (MetaMask, etc.) via wagmi
11
+ * and uses them as the signer when no Para embedded wallet is active.
12
+ */
13
+ export declare const useThirdwebSmartAccount: (params?: any) => import("@getpara/react-core/internal").UseSmartAccountResult<import("@getpara/aa-alchemy").SmartAccount>;
@@ -0,0 +1,9 @@
1
+ "use client";
2
+ import "../../chunk-MMUBH76A.js";
3
+ import { createThirdwebSmartAccountHook, THIRDWEB_SMART_ACCOUNT_BASE_KEY } from "@getpara/react-core/internal";
4
+ import { useWagmiSignerEnhancer } from "../useWagmiSignerEnhancer.js";
5
+ const useThirdwebSmartAccount = createThirdwebSmartAccountHook(useWagmiSignerEnhancer);
6
+ export {
7
+ THIRDWEB_SMART_ACCOUNT_BASE_KEY,
8
+ useThirdwebSmartAccount
9
+ };
@@ -0,0 +1,15 @@
1
+ import { ZERODEV_SMART_ACCOUNT_BASE_KEY } from '@getpara/react-core/internal';
2
+ export { ZERODEV_SMART_ACCOUNT_BASE_KEY };
3
+ /**
4
+ * React / React Native hook to create and manage a ZeroDev smart account.
5
+ *
6
+ * Supports both EIP-4337 and EIP-7702 modes. Uses ZeroDev's Kernel account
7
+ * with ECDSA validation and gas sponsorship.
8
+ *
9
+ * Requires `@getpara/aa-zerodev` to be installed.
10
+ * On web, automatically detects connected external wallets (MetaMask, etc.) via wagmi
11
+ * and uses them as the signer when no Para embedded wallet is active.
12
+ */
13
+ export declare const useZeroDevSmartAccount: (params?: import("@getpara/aa-zerodev").ZeroDevSmartAccountConfig & {
14
+ enabled?: boolean;
15
+ }) => import("@getpara/react-core/internal").UseSmartAccountResult<import("@getpara/aa-alchemy").SmartAccount>;
@@ -0,0 +1,9 @@
1
+ "use client";
2
+ import "../../chunk-MMUBH76A.js";
3
+ import { createZeroDevSmartAccountHook, ZERODEV_SMART_ACCOUNT_BASE_KEY } from "@getpara/react-core/internal";
4
+ import { useWagmiSignerEnhancer } from "../useWagmiSignerEnhancer.js";
5
+ const useZeroDevSmartAccount = createZeroDevSmartAccountHook(useWagmiSignerEnhancer);
6
+ export {
7
+ ZERODEV_SMART_ACCOUNT_BASE_KEY,
8
+ useZeroDevSmartAccount
9
+ };
@@ -0,0 +1,15 @@
1
+ import type { Hex } from 'viem';
2
+ import type { SmartAccountEnhancement } from '@getpara/react-core/internal';
3
+ /**
4
+ * Wagmi-based enhancer hook for `createSmartAccountHook`.
5
+ * Provides external wallet signer auto-detection on web via wagmi's context.
6
+ *
7
+ * When no Para embedded wallet is available but an external EVM wallet is
8
+ * connected (e.g. MetaMask via RainbowKit), this hook resolves the wagmi
9
+ * WalletClient as the signer for the smart account.
10
+ */
11
+ export declare function useWagmiSignerEnhancer<TParams extends {
12
+ address?: Hex;
13
+ walletId?: string;
14
+ signer?: any;
15
+ }>(params: TParams): SmartAccountEnhancement;
@@ -0,0 +1,45 @@
1
+ "use client";
2
+ import "../chunk-MMUBH76A.js";
3
+ import { useContext } from "react";
4
+ import { useStore } from "../provider/stores/useStore.js";
5
+ import { useClient, useWallet } from "../provider/index.js";
6
+ function useWagmiSignerEnhancer(params) {
7
+ var _a, _b, _c, _d, _e;
8
+ const para = useClient();
9
+ const { data: wallet } = useWallet();
10
+ const evmContext = useStore((state) => state.evmContext);
11
+ const evmCtxValue = useContext(evmContext);
12
+ const noopUseAccount = () => void 0;
13
+ const noopUseWalletClient = () => ({
14
+ data: void 0,
15
+ isLoading: false
16
+ });
17
+ const useEvmAccount = (_a = evmCtxValue == null ? void 0 : evmCtxValue.useAccount) != null ? _a : noopUseAccount;
18
+ const useEvmWalletClient = (_b = evmCtxValue == null ? void 0 : evmCtxValue.useWalletClient) != null ? _b : noopUseWalletClient;
19
+ const evmAccount = useEvmAccount();
20
+ const { data: evmWalletClient, isLoading: isEvmWalletClientLoading } = useEvmWalletClient();
21
+ const contextAddress = (wallet == null ? void 0 : wallet.type) === "EVM" && !(wallet == null ? void 0 : wallet.isExternal) ? wallet == null ? void 0 : wallet.address : void 0;
22
+ const hasEmbeddedWallet = !!contextAddress;
23
+ const externalEvmAddress = evmAccount == null ? void 0 : evmAccount.address;
24
+ const addressParamIsExternal = (() => {
25
+ if (!para || !(params == null ? void 0 : params.address)) return false;
26
+ try {
27
+ const w = para.findWalletByAddress(params.address, { type: ["EVM"] });
28
+ return !!(w == null ? void 0 : w.isExternal);
29
+ } catch (e) {
30
+ return false;
31
+ }
32
+ })();
33
+ const isPotentiallyExternal = !hasEmbeddedWallet && !!externalEvmAddress || addressParamIsExternal;
34
+ const autoExternalSigner = !(params == null ? void 0 : params.signer) && isPotentiallyExternal && evmWalletClient ? !addressParamIsExternal || (externalEvmAddress == null ? void 0 : externalEvmAddress.toLowerCase()) === ((_c = params == null ? void 0 : params.address) == null ? void 0 : _c.toLowerCase()) ? evmWalletClient : void 0 : void 0;
35
+ const effectiveSigner = (_d = params == null ? void 0 : params.signer) != null ? _d : autoExternalSigner;
36
+ const signerAddress = effectiveSigner ? "address" in effectiveSigner ? effectiveSigner.address : (_e = effectiveSigner.account) == null ? void 0 : _e.address : void 0;
37
+ return {
38
+ signer: effectiveSigner != null ? effectiveSigner : null,
39
+ signerAddress: signerAddress != null ? signerAddress : null,
40
+ isLoading: isPotentiallyExternal && !(params == null ? void 0 : params.signer) && isEvmWalletClientLoading
41
+ };
42
+ }
43
+ export {
44
+ useWagmiSignerEnhancer
45
+ };
package/dist/cli/cli.mjs CHANGED
File without changes
package/dist/index.d.ts CHANGED
@@ -5,15 +5,14 @@ export type { Theme } from '@getpara/react-components';
5
5
  import ParaWeb from '@getpara/web-sdk';
6
6
  export default ParaWeb;
7
7
  export type { StepOverride } from './modal/types/modalProps.js';
8
- export { createSmartAccountHook } from './aa/createSmartAccountHook.js';
9
- export type { UseSmartAccountResult, SmartAccountHookConfig } from './aa/types.js';
10
- export { useAlchemySmartAccount, ALCHEMY_SMART_ACCOUNT_BASE_KEY } from './aa/alchemy/hook.js';
11
- export { useBiconomySmartAccount, BICONOMY_SMART_ACCOUNT_BASE_KEY } from './aa/biconomy/hook.js';
12
- export { useCDPSmartAccount, CDP_SMART_ACCOUNT_BASE_KEY } from './aa/cdp/hook.js';
13
- export { useGelatoSmartAccount, GELATO_SMART_ACCOUNT_BASE_KEY } from './aa/gelato/hook.js';
14
- export { usePimlicoSmartAccount, PIMLICO_SMART_ACCOUNT_BASE_KEY } from './aa/pimlico/hook.js';
15
- export { usePortoSmartAccount, PORTO_ACCOUNT_BASE_KEY } from './aa/porto/hook.js';
16
- export { useRhinestoneSmartAccount, RHINESTONE_SMART_ACCOUNT_BASE_KEY } from './aa/rhinestone/hook.js';
17
- export { useSafeSmartAccount, SAFE_SMART_ACCOUNT_BASE_KEY } from './aa/safe/hook.js';
18
- export { useThirdwebSmartAccount, THIRDWEB_SMART_ACCOUNT_BASE_KEY } from './aa/thirdweb/hook.js';
19
- export { useZeroDevSmartAccount, ZERODEV_SMART_ACCOUNT_BASE_KEY } from './aa/zerodev/hook.js';
8
+ export type { UseSmartAccountResult } from '@getpara/react-core/internal';
9
+ export { useAlchemySmartAccount, ALCHEMY_SMART_ACCOUNT_BASE_KEY } from './aa/hooks/alchemy.js';
10
+ export { useBiconomySmartAccount, BICONOMY_SMART_ACCOUNT_BASE_KEY } from './aa/hooks/biconomy.js';
11
+ export { useCDPSmartAccount, CDP_SMART_ACCOUNT_BASE_KEY } from './aa/hooks/cdp.js';
12
+ export { useGelatoSmartAccount, GELATO_SMART_ACCOUNT_BASE_KEY } from './aa/hooks/gelato.js';
13
+ export { usePimlicoSmartAccount, PIMLICO_SMART_ACCOUNT_BASE_KEY } from './aa/hooks/pimlico.js';
14
+ export { usePortoSmartAccount, PORTO_ACCOUNT_BASE_KEY } from './aa/hooks/porto.js';
15
+ export { useRhinestoneSmartAccount, RHINESTONE_SMART_ACCOUNT_BASE_KEY } from './aa/hooks/rhinestone.js';
16
+ export { useSafeSmartAccount, SAFE_SMART_ACCOUNT_BASE_KEY } from './aa/hooks/safe.js';
17
+ export { useThirdwebSmartAccount, THIRDWEB_SMART_ACCOUNT_BASE_KEY } from './aa/hooks/thirdweb.js';
18
+ export { useZeroDevSmartAccount, ZERODEV_SMART_ACCOUNT_BASE_KEY } from './aa/hooks/zerodev.js';
package/dist/index.js CHANGED
@@ -5,17 +5,16 @@ export * from "./provider/index.js";
5
5
  export * from "@getpara/web-sdk";
6
6
  import ParaWeb from "@getpara/web-sdk";
7
7
  var src_default = ParaWeb;
8
- import { createSmartAccountHook } from "./aa/createSmartAccountHook.js";
9
- import { useAlchemySmartAccount, ALCHEMY_SMART_ACCOUNT_BASE_KEY } from "./aa/alchemy/hook.js";
10
- import { useBiconomySmartAccount, BICONOMY_SMART_ACCOUNT_BASE_KEY } from "./aa/biconomy/hook.js";
11
- import { useCDPSmartAccount, CDP_SMART_ACCOUNT_BASE_KEY } from "./aa/cdp/hook.js";
12
- import { useGelatoSmartAccount, GELATO_SMART_ACCOUNT_BASE_KEY } from "./aa/gelato/hook.js";
13
- import { usePimlicoSmartAccount, PIMLICO_SMART_ACCOUNT_BASE_KEY } from "./aa/pimlico/hook.js";
14
- import { usePortoSmartAccount, PORTO_ACCOUNT_BASE_KEY } from "./aa/porto/hook.js";
15
- import { useRhinestoneSmartAccount, RHINESTONE_SMART_ACCOUNT_BASE_KEY } from "./aa/rhinestone/hook.js";
16
- import { useSafeSmartAccount, SAFE_SMART_ACCOUNT_BASE_KEY } from "./aa/safe/hook.js";
17
- import { useThirdwebSmartAccount, THIRDWEB_SMART_ACCOUNT_BASE_KEY } from "./aa/thirdweb/hook.js";
18
- import { useZeroDevSmartAccount, ZERODEV_SMART_ACCOUNT_BASE_KEY } from "./aa/zerodev/hook.js";
8
+ import { useAlchemySmartAccount, ALCHEMY_SMART_ACCOUNT_BASE_KEY } from "./aa/hooks/alchemy.js";
9
+ import { useBiconomySmartAccount, BICONOMY_SMART_ACCOUNT_BASE_KEY } from "./aa/hooks/biconomy.js";
10
+ import { useCDPSmartAccount, CDP_SMART_ACCOUNT_BASE_KEY } from "./aa/hooks/cdp.js";
11
+ import { useGelatoSmartAccount, GELATO_SMART_ACCOUNT_BASE_KEY } from "./aa/hooks/gelato.js";
12
+ import { usePimlicoSmartAccount, PIMLICO_SMART_ACCOUNT_BASE_KEY } from "./aa/hooks/pimlico.js";
13
+ import { usePortoSmartAccount, PORTO_ACCOUNT_BASE_KEY } from "./aa/hooks/porto.js";
14
+ import { useRhinestoneSmartAccount, RHINESTONE_SMART_ACCOUNT_BASE_KEY } from "./aa/hooks/rhinestone.js";
15
+ import { useSafeSmartAccount, SAFE_SMART_ACCOUNT_BASE_KEY } from "./aa/hooks/safe.js";
16
+ import { useThirdwebSmartAccount, THIRDWEB_SMART_ACCOUNT_BASE_KEY } from "./aa/hooks/thirdweb.js";
17
+ import { useZeroDevSmartAccount, ZERODEV_SMART_ACCOUNT_BASE_KEY } from "./aa/hooks/zerodev.js";
19
18
  export {
20
19
  ALCHEMY_SMART_ACCOUNT_BASE_KEY,
21
20
  BICONOMY_SMART_ACCOUNT_BASE_KEY,
@@ -27,7 +26,6 @@ export {
27
26
  SAFE_SMART_ACCOUNT_BASE_KEY,
28
27
  THIRDWEB_SMART_ACCOUNT_BASE_KEY,
29
28
  ZERODEV_SMART_ACCOUNT_BASE_KEY,
30
- createSmartAccountHook,
31
29
  src_default as default,
32
30
  useAlchemySmartAccount,
33
31
  useBiconomySmartAccount,
@@ -99,7 +99,7 @@ const ParaModal = forwardRef((props, ref) => {
99
99
  onClose,
100
100
  defaultAuthIdentifier
101
101
  }), rest),
102
- reactSdkVersion: "2.18.0"
102
+ reactSdkVersion: "2.19.0"
103
103
  });
104
104
  } catch (e) {
105
105
  }
@@ -3,5 +3,5 @@ export declare const connectWalletTitle = "Connect Wallet";
3
3
  export declare const useStepTitle: () => {
4
4
  title: string | null;
5
5
  isTitleDisplayed: boolean;
6
- isControls: boolean | undefined;
6
+ isControls: any;
7
7
  };
@@ -13,7 +13,7 @@ const OnRampProviderButton = ({ config, index, onClick: _onClick }) => {
13
13
  const onClick = () => __async(void 0, null, function* () {
14
14
  yield _onClick();
15
15
  });
16
- return /* @__PURE__ */ jsx(StyledButton, { variant: "tertiary", fullWidth: true, onClick, children: /* @__PURE__ */ jsxs(Container, { children: [
16
+ return /* @__PURE__ */ jsx(StyledButton, { variant: "tertiary", fullWidth: true, onClick, "data-testid": `onramp-provider-${provider}`, children: /* @__PURE__ */ jsxs(Container, { children: [
17
17
  /* @__PURE__ */ jsx(IconContainer, { children: /* @__PURE__ */ jsx(CpslIcon, { icon, color: backgroundColors[0] }) }),
18
18
  /* @__PURE__ */ jsxs(ProviderInfoContainer, { children: [
19
19
  /* @__PURE__ */ jsx(CpslText, { variant: "bodyL", weight: "medium", children: name }),
@@ -40,6 +40,7 @@ function QuantityInput({
40
40
  {
41
41
  type: "number",
42
42
  inputMode: "decimal",
43
+ "data-testid": "onramp-quantity-input",
43
44
  value: displayValue,
44
45
  style: { width: `${inputWidth}px` },
45
46
  onFocus: (e) => {
@@ -154,17 +154,26 @@ function SearchableButtonList({
154
154
  ),
155
155
  /* @__PURE__ */ jsx(GradientScroll, { height: "100%", gap: "8px", children: /* @__PURE__ */ jsx("div", { ref: scrollContainerRef, children: /* @__PURE__ */ jsx(List, { style: { paddingTop, paddingBottom }, children: /* @__PURE__ */ jsx(AnimatePresence, { mode: "sync", children: visibleItems.map(({ assetItem, originalItem }) => {
156
156
  const { key, icon, text, textSecondary, endText, endTextSecondary } = assetItem;
157
- return /* @__PURE__ */ jsx(motion.li, __spreadProps(__spreadValues({ style: { width: "100%" } }, contentMotionProps), { children: /* @__PURE__ */ jsxs(AssetButton, { fullWidth: true, variant: "secondary", onClick: () => onSelect(originalItem), children: [
158
- icon,
159
- /* @__PURE__ */ jsxs(Info, { children: [
160
- /* @__PURE__ */ jsx(Code, { color: "contrast", variant: "bodyL", children: text }),
161
- textSecondary && /* @__PURE__ */ jsx(Name, { color: "contrast", variant: "bodyS", children: textSecondary })
162
- ] }),
163
- endText && /* @__PURE__ */ jsxs(End, { children: [
164
- /* @__PURE__ */ jsx(EndText, { color: "primary", variant: "bodyM", children: endText }),
165
- endTextSecondary && /* @__PURE__ */ jsx(EndTextSecondary, { color: "contrast", variant: "bodyS", children: endTextSecondary })
166
- ] })
167
- ] }) }), key);
157
+ return /* @__PURE__ */ jsx(motion.li, __spreadProps(__spreadValues({ style: { width: "100%" } }, contentMotionProps), { children: /* @__PURE__ */ jsxs(
158
+ AssetButton,
159
+ {
160
+ fullWidth: true,
161
+ variant: "secondary",
162
+ onClick: () => onSelect(originalItem),
163
+ "data-testid": `searchable-item-${key}`,
164
+ children: [
165
+ icon,
166
+ /* @__PURE__ */ jsxs(Info, { children: [
167
+ /* @__PURE__ */ jsx(Code, { color: "contrast", variant: "bodyL", children: text }),
168
+ textSecondary && /* @__PURE__ */ jsx(Name, { color: "contrast", variant: "bodyS", children: textSecondary })
169
+ ] }),
170
+ endText && /* @__PURE__ */ jsxs(End, { children: [
171
+ /* @__PURE__ */ jsx(EndText, { color: "primary", variant: "bodyM", children: endText }),
172
+ endTextSecondary && /* @__PURE__ */ jsx(EndTextSecondary, { color: "contrast", variant: "bodyS", children: endTextSecondary })
173
+ ] })
174
+ ]
175
+ }
176
+ ) }), key);
168
177
  }) }) }) }) })
169
178
  ]
170
179
  }
@@ -147,6 +147,7 @@ function AddFundsSettings() {
147
147
  {
148
148
  variant: "tertiary",
149
149
  $isClickable: isClickable,
150
+ "data-testid": "onramp-asset-button",
150
151
  cursor: isClickable ? "pointer" : "auto",
151
152
  onClick: isClickable ? () => {
152
153
  switch (true) {
@@ -29,7 +29,7 @@ const Wallet = () => {
29
29
  const setProfileWallet = useStore((state) => state.setProfileWallet);
30
30
  const setAccountView = useStore((state) => state.setAccountView);
31
31
  const { connectionType } = useAccount();
32
- const { mutate: exportPrivateKey } = useExportPrivateKey();
32
+ const { exportPrivateKey } = useExportPrivateKey();
33
33
  const { disconnectBase, evmDisconnectStatus, solanaDisconnectStatus, cosmosDisconnectStatus } = useExternalWallets();
34
34
  const disconnectStatus = useMemo(() => {
35
35
  if (!(profileWallet == null ? void 0 : profileWallet.isExternal)) {