thirdweb 5.116.0 → 5.116.2-nightly-151127d66825365cb0ed949ae28b9906ee4dfc8d-20251213000343

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 (135) hide show
  1. package/dist/cjs/react/core/hooks/x402/useFetchWithPaymentCore.js +5 -1
  2. package/dist/cjs/react/core/hooks/x402/useFetchWithPaymentCore.js.map +1 -1
  3. package/dist/cjs/react/native/hooks/x402/useFetchWithPayment.js +6 -1
  4. package/dist/cjs/react/native/hooks/x402/useFetchWithPayment.js.map +1 -1
  5. package/dist/cjs/react/web/hooks/x402/useFetchWithPayment.js +7 -1
  6. package/dist/cjs/react/web/hooks/x402/useFetchWithPayment.js.map +1 -1
  7. package/dist/cjs/react/web/ui/Bridge/swap-widget/swap-ui.js +20 -0
  8. package/dist/cjs/react/web/ui/Bridge/swap-widget/swap-ui.js.map +1 -1
  9. package/dist/cjs/react/web/ui/Bridge/swap-widget/use-bridge-chains.js +15 -2
  10. package/dist/cjs/react/web/ui/Bridge/swap-widget/use-bridge-chains.js.map +1 -1
  11. package/dist/cjs/react/web/ui/ConnectWallet/WalletEntryButton.js +16 -2
  12. package/dist/cjs/react/web/ui/ConnectWallet/WalletEntryButton.js.map +1 -1
  13. package/dist/cjs/react/web/ui/ConnectWallet/icons/EmailIcon.js +1 -4
  14. package/dist/cjs/react/web/ui/ConnectWallet/icons/EmailIcon.js.map +1 -1
  15. package/dist/cjs/react/web/ui/ConnectWallet/icons/WalletDotIcon.js +1 -1
  16. package/dist/cjs/react/web/ui/ConnectWallet/icons/WalletDotIcon.js.map +1 -1
  17. package/dist/cjs/react/web/ui/ConnectWallet/in-app-wallet-icon.js +101 -0
  18. package/dist/cjs/react/web/ui/ConnectWallet/in-app-wallet-icon.js.map +1 -0
  19. package/dist/cjs/react/web/ui/components/Spinner.js +7 -7
  20. package/dist/cjs/react/web/ui/components/Spinner.js.map +1 -1
  21. package/dist/cjs/react/web/ui/design-system/elements.js +1 -2
  22. package/dist/cjs/react/web/ui/design-system/elements.js.map +1 -1
  23. package/dist/cjs/react/web/wallets/shared/ConnectWalletSocialOptions.js +4 -4
  24. package/dist/cjs/react/web/wallets/shared/ConnectWalletSocialOptions.js.map +1 -1
  25. package/dist/cjs/react/web/wallets/shared/OTPLoginUI.js +13 -7
  26. package/dist/cjs/react/web/wallets/shared/OTPLoginUI.js.map +1 -1
  27. package/dist/cjs/stories/ConnectEmbed.stories.js +34 -0
  28. package/dist/cjs/stories/ConnectEmbed.stories.js.map +1 -1
  29. package/dist/cjs/stories/in-app-wallet-icon.stories.js +59 -0
  30. package/dist/cjs/stories/in-app-wallet-icon.stories.js.map +1 -0
  31. package/dist/cjs/version.js +1 -1
  32. package/dist/cjs/version.js.map +1 -1
  33. package/dist/cjs/wallets/in-app/web/lib/auth/otp.js +12 -1
  34. package/dist/cjs/wallets/in-app/web/lib/auth/otp.js.map +1 -1
  35. package/dist/cjs/x402/fetchWithPayment.js +13 -1
  36. package/dist/cjs/x402/fetchWithPayment.js.map +1 -1
  37. package/dist/cjs/x402/permitSignatureStorage.js +70 -0
  38. package/dist/cjs/x402/permitSignatureStorage.js.map +1 -0
  39. package/dist/cjs/x402/sign.js +51 -4
  40. package/dist/cjs/x402/sign.js.map +1 -1
  41. package/dist/esm/react/core/hooks/x402/useFetchWithPaymentCore.js +5 -1
  42. package/dist/esm/react/core/hooks/x402/useFetchWithPaymentCore.js.map +1 -1
  43. package/dist/esm/react/native/hooks/x402/useFetchWithPayment.js +6 -1
  44. package/dist/esm/react/native/hooks/x402/useFetchWithPayment.js.map +1 -1
  45. package/dist/esm/react/web/hooks/x402/useFetchWithPayment.js +8 -2
  46. package/dist/esm/react/web/hooks/x402/useFetchWithPayment.js.map +1 -1
  47. package/dist/esm/react/web/ui/Bridge/swap-widget/swap-ui.js +20 -0
  48. package/dist/esm/react/web/ui/Bridge/swap-widget/swap-ui.js.map +1 -1
  49. package/dist/esm/react/web/ui/Bridge/swap-widget/use-bridge-chains.js +15 -2
  50. package/dist/esm/react/web/ui/Bridge/swap-widget/use-bridge-chains.js.map +1 -1
  51. package/dist/esm/react/web/ui/ConnectWallet/WalletEntryButton.js +16 -2
  52. package/dist/esm/react/web/ui/ConnectWallet/WalletEntryButton.js.map +1 -1
  53. package/dist/esm/react/web/ui/ConnectWallet/icons/EmailIcon.js +1 -4
  54. package/dist/esm/react/web/ui/ConnectWallet/icons/EmailIcon.js.map +1 -1
  55. package/dist/esm/react/web/ui/ConnectWallet/icons/WalletDotIcon.js +1 -1
  56. package/dist/esm/react/web/ui/ConnectWallet/icons/WalletDotIcon.js.map +1 -1
  57. package/dist/esm/react/web/ui/ConnectWallet/in-app-wallet-icon.js +98 -0
  58. package/dist/esm/react/web/ui/ConnectWallet/in-app-wallet-icon.js.map +1 -0
  59. package/dist/esm/react/web/ui/components/Spinner.js +9 -9
  60. package/dist/esm/react/web/ui/components/Spinner.js.map +1 -1
  61. package/dist/esm/react/web/ui/design-system/elements.js +0 -1
  62. package/dist/esm/react/web/ui/design-system/elements.js.map +1 -1
  63. package/dist/esm/react/web/wallets/shared/ConnectWalletSocialOptions.js +1 -1
  64. package/dist/esm/react/web/wallets/shared/ConnectWalletSocialOptions.js.map +1 -1
  65. package/dist/esm/react/web/wallets/shared/OTPLoginUI.js +13 -7
  66. package/dist/esm/react/web/wallets/shared/OTPLoginUI.js.map +1 -1
  67. package/dist/esm/stories/ConnectEmbed.stories.js +31 -0
  68. package/dist/esm/stories/ConnectEmbed.stories.js.map +1 -1
  69. package/dist/esm/stories/in-app-wallet-icon.stories.js +55 -0
  70. package/dist/esm/stories/in-app-wallet-icon.stories.js.map +1 -0
  71. package/dist/esm/version.js +1 -1
  72. package/dist/esm/version.js.map +1 -1
  73. package/dist/esm/wallets/in-app/web/lib/auth/otp.js +12 -1
  74. package/dist/esm/wallets/in-app/web/lib/auth/otp.js.map +1 -1
  75. package/dist/esm/x402/fetchWithPayment.js +13 -1
  76. package/dist/esm/x402/fetchWithPayment.js.map +1 -1
  77. package/dist/esm/x402/permitSignatureStorage.js +65 -0
  78. package/dist/esm/x402/permitSignatureStorage.js.map +1 -0
  79. package/dist/esm/x402/sign.js +51 -4
  80. package/dist/esm/x402/sign.js.map +1 -1
  81. package/dist/scripts/bridge-widget.js +113 -112
  82. package/dist/types/react/core/hooks/x402/useFetchWithPaymentCore.d.ts +6 -0
  83. package/dist/types/react/core/hooks/x402/useFetchWithPaymentCore.d.ts.map +1 -1
  84. package/dist/types/react/native/hooks/x402/useFetchWithPayment.d.ts +1 -0
  85. package/dist/types/react/native/hooks/x402/useFetchWithPayment.d.ts.map +1 -1
  86. package/dist/types/react/web/hooks/x402/useFetchWithPayment.d.ts.map +1 -1
  87. package/dist/types/react/web/ui/Bridge/swap-widget/swap-ui.d.ts.map +1 -1
  88. package/dist/types/react/web/ui/Bridge/swap-widget/use-bridge-chains.d.ts +1 -2
  89. package/dist/types/react/web/ui/Bridge/swap-widget/use-bridge-chains.d.ts.map +1 -1
  90. package/dist/types/react/web/ui/ConnectWallet/WalletEntryButton.d.ts.map +1 -1
  91. package/dist/types/react/web/ui/ConnectWallet/icons/EmailIcon.d.ts +0 -3
  92. package/dist/types/react/web/ui/ConnectWallet/icons/EmailIcon.d.ts.map +1 -1
  93. package/dist/types/react/web/ui/ConnectWallet/icons/WalletDotIcon.d.ts.map +1 -1
  94. package/dist/types/react/web/ui/ConnectWallet/in-app-wallet-icon.d.ts +7 -0
  95. package/dist/types/react/web/ui/ConnectWallet/in-app-wallet-icon.d.ts.map +1 -0
  96. package/dist/types/react/web/ui/components/Spinner.d.ts.map +1 -1
  97. package/dist/types/react/web/ui/design-system/elements.d.ts +0 -4
  98. package/dist/types/react/web/ui/design-system/elements.d.ts.map +1 -1
  99. package/dist/types/react/web/wallets/shared/ConnectWalletSocialOptions.d.ts +2 -1
  100. package/dist/types/react/web/wallets/shared/ConnectWalletSocialOptions.d.ts.map +1 -1
  101. package/dist/types/react/web/wallets/shared/OTPLoginUI.d.ts.map +1 -1
  102. package/dist/types/stories/ConnectEmbed.stories.d.ts +3 -0
  103. package/dist/types/stories/ConnectEmbed.stories.d.ts.map +1 -1
  104. package/dist/types/stories/in-app-wallet-icon.stories.d.ts +10 -0
  105. package/dist/types/stories/in-app-wallet-icon.stories.d.ts.map +1 -0
  106. package/dist/types/version.d.ts +1 -1
  107. package/dist/types/version.d.ts.map +1 -1
  108. package/dist/types/wallets/in-app/web/lib/auth/otp.d.ts.map +1 -1
  109. package/dist/types/x402/fetchWithPayment.d.ts +6 -0
  110. package/dist/types/x402/fetchWithPayment.d.ts.map +1 -1
  111. package/dist/types/x402/permitSignatureStorage.d.ts +43 -0
  112. package/dist/types/x402/permitSignatureStorage.d.ts.map +1 -0
  113. package/dist/types/x402/sign.d.ts +3 -1
  114. package/dist/types/x402/sign.d.ts.map +1 -1
  115. package/package.json +1 -1
  116. package/src/react/core/hooks/x402/useFetchWithPaymentCore.ts +11 -1
  117. package/src/react/native/hooks/x402/useFetchWithPayment.ts +6 -1
  118. package/src/react/web/hooks/x402/useFetchWithPayment.tsx +12 -2
  119. package/src/react/web/ui/Bridge/swap-widget/swap-ui.tsx +26 -0
  120. package/src/react/web/ui/Bridge/swap-widget/use-bridge-chains.ts +19 -2
  121. package/src/react/web/ui/ConnectWallet/WalletEntryButton.tsx +23 -2
  122. package/src/react/web/ui/ConnectWallet/icons/EmailIcon.tsx +12 -19
  123. package/src/react/web/ui/ConnectWallet/icons/WalletDotIcon.tsx +1 -0
  124. package/src/react/web/ui/ConnectWallet/in-app-wallet-icon.tsx +195 -0
  125. package/src/react/web/ui/components/Spinner.tsx +9 -9
  126. package/src/react/web/ui/design-system/elements.ts +0 -1
  127. package/src/react/web/wallets/shared/ConnectWalletSocialOptions.tsx +1 -1
  128. package/src/react/web/wallets/shared/OTPLoginUI.tsx +24 -11
  129. package/src/stories/ConnectEmbed.stories.tsx +55 -0
  130. package/src/stories/in-app-wallet-icon.stories.tsx +163 -0
  131. package/src/version.ts +1 -1
  132. package/src/wallets/in-app/web/lib/auth/otp.ts +11 -1
  133. package/src/x402/fetchWithPayment.ts +21 -0
  134. package/src/x402/permitSignatureStorage.ts +99 -0
  135. package/src/x402/sign.ts +76 -1
@@ -1,4 +1,5 @@
1
1
  import type { ThirdwebClient } from "../../../../client/client.js";
2
+ import type { AsyncStorage } from "../../../../utils/storage/AsyncStorage.js";
2
3
  import type { Wallet } from "../../../../wallets/interfaces/wallet.js";
3
4
  import type { RequestedPaymentRequirements } from "../../../../x402/schemas.js";
4
5
  import type { PaymentRequiredResult } from "../../../../x402/types.js";
@@ -6,6 +7,11 @@ export type UseFetchWithPaymentOptions = {
6
7
  maxValue?: bigint;
7
8
  paymentRequirementsSelector?: (paymentRequirements: RequestedPaymentRequirements[]) => RequestedPaymentRequirements | undefined;
8
9
  parseAs?: "json" | "text" | "raw";
10
+ /**
11
+ * Storage for caching permit signatures (for "upto" scheme).
12
+ * When provided, permit signatures will be cached and reused if the on-chain allowance is sufficient.
13
+ */
14
+ storage?: AsyncStorage;
9
15
  };
10
16
  type ShowErrorModalCallback = (data: {
11
17
  errorData: PaymentRequiredResult["responseBody"];
@@ -1 +1 @@
1
- {"version":3,"file":"useFetchWithPaymentCore.d.ts","sourceRoot":"","sources":["../../../../../../src/react/core/hooks/x402/useFetchWithPaymentCore.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,0CAA0C,CAAC;AAEvE,OAAO,KAAK,EAAE,4BAA4B,EAAE,MAAM,6BAA6B,CAAC;AAChF,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,2BAA2B,CAAC;AAGvE,MAAM,MAAM,0BAA0B,GAAG;IACvC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,2BAA2B,CAAC,EAAE,CAC5B,mBAAmB,EAAE,4BAA4B,EAAE,KAChD,4BAA4B,GAAG,SAAS,CAAC;IAC9C,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,KAAK,CAAC;CACnC,CAAC;AAEF,KAAK,sBAAsB,GAAG,CAAC,IAAI,EAAE;IACnC,SAAS,EAAE,qBAAqB,CAAC,cAAc,CAAC,CAAC;IACjD,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,QAAQ,EAAE,MAAM,IAAI,CAAC;CACtB,KAAK,IAAI,CAAC;AAEX,KAAK,wBAAwB,GAAG,CAAC,IAAI,EAAE;IACrC,SAAS,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IACpC,QAAQ,EAAE,MAAM,IAAI,CAAC;CACtB,KAAK,IAAI,CAAC;AAEX;;;;GAIG;AACH,wBAAgB,uBAAuB,CACrC,MAAM,EAAE,cAAc,EACtB,OAAO,CAAC,EAAE,0BAA0B,EACpC,cAAc,CAAC,EAAE,sBAAsB,EACvC,gBAAgB,CAAC,EAAE,wBAAwB;;;;;;;;;;eAShC,WAAW;eACX,WAAW;;;;;;;;;eADX,WAAW;eACX,WAAW;;8BA+FY,WAAW,SAAS,WAAW;;;;eAhGtD,WAAW;eACX,WAAW;;;;;;;;;eADX,WAAW;eACX,WAAW;;;;;;;;;eADX,WAAW;eACX,WAAW;;8BA+FY,WAAW,SAAS,WAAW;;;;;eAhGtD,WAAW;eACX,WAAW;;;;;;;;eADX,WAAW;eACX,WAAW;;;;;;;;;eADX,WAAW;eACX,WAAW;;8BA+FY,WAAW,SAAS,WAAW;;;;;eAhGtD,WAAW;eACX,WAAW;;;;;;;;eADX,WAAW;eACX,WAAW;;;;;;;;;eADX,WAAW;eACX,WAAW;;8BA+FY,WAAW,SAAS,WAAW;EAKlE"}
1
+ {"version":3,"file":"useFetchWithPaymentCore.d.ts","sourceRoot":"","sources":["../../../../../../src/react/core/hooks/x402/useFetchWithPaymentCore.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,KAA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AAW;;;;;eApGtD,WAAW;eACX,WAAW;;;;;;;;eADX,WAAW;eACX,WAAW;;;;;;;;;eADX,WAAW;eACX,WAAW;;8BAmGY,WAAW,SAAS,WAAW;;;;;eApGtD,WAAW;eACX,WAAW;;;;;;;;eADX,WAAW;eACX,WAAW;;;;;;;;;eADX,WAAW;eACX,WAAW;;8BAmGY,WAAW,SAAS,WAAW;EAKlE"}
@@ -22,6 +22,7 @@ export type { UseFetchWithPaymentOptions };
22
22
  * @param options.maxValue - The maximum allowed payment amount in base units
23
23
  * @param options.paymentRequirementsSelector - Custom function to select payment requirements from available options
24
24
  * @param options.parseAs - How to parse the response: "json" (default), "text", or "raw"
25
+ * @param options.storage - Storage for caching permit signatures (for "upto" scheme). Provide your own AsyncStorage implementation for React Native.
25
26
  * @returns An object containing:
26
27
  * - `fetchWithPayment`: Function to make fetch requests with automatic payment handling (returns parsed data)
27
28
  * - `isPending`: Boolean indicating if a request is in progress
@@ -1 +1 @@
1
- {"version":3,"file":"useFetchWithPayment.d.ts","sourceRoot":"","sources":["../../../../../../src/react/native/hooks/x402/useFetchWithPayment.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,EACL,KAAK,0BAA0B,EAEhC,MAAM,qDAAqD,CAAC;AAE7D,YAAY,EAAE,0BAA0B,EAAE,CAAC;AAE3C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8EG;AACH,wBAAgB,mBAAmB,CACjC,MAAM,EAAE,cAAc,EACtB,OAAO,CAAC,EAAE,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAIrC"}
1
+ {"version":3,"file":"useFetchWithPayment.d.ts","sourceRoot":"","sources":["../../../../../../src/react/native/hooks/x402/useFetchWithPayment.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAEnE,OAAO,EACL,KAAK,0BAA0B,EAEhC,MAAM,qDAAqD,CAAC;AAE7D,YAAY,EAAE,0BAA0B,EAAE,CAAC;AAE3C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+EG;AACH,wBAAgB,mBAAmB,CACjC,MAAM,EAAE,cAAc,EACtB,OAAO,CAAC,EAAE,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAOrC"}
@@ -1 +1 @@
1
- {"version":3,"file":"useFetchWithPayment.d.ts","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/x402/useFetchWithPayment.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAEnE,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,sCAAsC,CAAC;AAClE,OAAO,EACL,KAAK,0BAA0B,EAEhC,MAAM,qDAAqD,CAAC;AAE7D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,EACL,KAAK,sBAAsB,EAE5B,MAAM,2CAA2C,CAAC;AAInD,YAAY,EAAE,0BAA0B,EAAE,CAAC;AAE3C,KAAK,yBAAyB,GAAG,0BAA0B,GAAG;IAC5D;;;;OAIG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;;;OAGG;IACH,KAAK,CAAC,EAAE,KAAK,GAAG,OAAO,GAAG,MAAM,CAAC;IACjC;;;OAGG;IACH,iBAAiB,CAAC,EAAE,OAAO,CACzB,IAAI,CACF,cAAc,EACd,QAAQ,GAAG,OAAO,GAAG,cAAc,GAAG,WAAW,GAAG,UAAU,GAAG,OAAO,CACzE,CACF,CAAC;IACF;;;OAGG;IACH,cAAc,CAAC,EAAE,IAAI,CAAC,sBAAsB,EAAE,QAAQ,GAAG,OAAO,CAAC,CAAC;IAClE;;OAEG;IACH,mBAAmB,CAAC,EAAE;QACpB,wCAAwC;QACxC,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,8BAA8B;QAC9B,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,0CAA0C;QAC1C,WAAW,CAAC,EAAE,MAAM,CAAC;KACtB,CAAC;CACH,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2HG;AACH,wBAAgB,mBAAmB,CACjC,MAAM,EAAE,cAAc,EACtB,OAAO,CAAC,EAAE,yBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA4EpC"}
1
+ {"version":3,"file":"useFetchWithPayment.d.ts","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/x402/useFetchWithPayment.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAGnE,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,sCAAsC,CAAC;AAClE,OAAO,EACL,KAAK,0BAA0B,EAEhC,MAAM,qDAAqD,CAAC;AAE7D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,EACL,KAAK,sBAAsB,EAE5B,MAAM,2CAA2C,CAAC;AAInD,YAAY,EAAE,0BAA0B,EAAE,CAAC;AAE3C,KAAK,yBAAyB,GAAG,0BAA0B,GAAG;IAC5D;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AAG,SAAS,CAAC;IACtC,WAAW,EAAE,CAAC,KAAK,EAAE,cAAc,GAAG,SAAS,KAAK,IAAI,CAAC;IACzD,YAAY,EAAE,CAAC,KAAK,EAAE,cAAc,GAAG,SAAS,KAAK,IAAI,CAAC;IAC1D,eAAe,EAAE;QACf,IAAI,EAAE,KAAK,GAAG,MAAM,CAAC;QACrB,MAAM,EAAE,MAAM,CAAC;KAChB,CAAC;IACF,kBAAkB,EAAE,CAAC,eAAe,EAAE;QACpC,IAAI,EAAE,KAAK,GAAG,MAAM,CAAC;QACrB,MAAM,EAAE,MAAM,CAAC;KAChB,KAAK,IAAI,CAAC;IACX,YAAY,EAAE,CAAC,MAAM,IAAI,CAAC,GAAG,SAAS,CAAC;CACxC,CAAC;AAyBF;;GAEG;AACH,wBAAgB,MAAM,CAAC,KAAK,EAAE,WAAW,2CA8YxC"}
@@ -1,4 +1,3 @@
1
- import { chains } from "../../../../../bridge/index.js";
2
1
  import type { ThirdwebClient } from "../../../../../client/client.js";
3
- export declare function useBridgeChains(client: ThirdwebClient): import("@tanstack/react-query").UseQueryResult<chains.Result, Error>;
2
+ export declare function useBridgeChains(client: ThirdwebClient): import("@tanstack/react-query").UseQueryResult<import("../../../../../bridge/index.js").Chain[], Error>;
4
3
  //# sourceMappingURL=use-bridge-chains.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"use-bridge-chains.d.ts","sourceRoot":"","sources":["../../../../../../../src/react/web/ui/Bridge/swap-widget/use-bridge-chains.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,gCAAgC,CAAC;AACxD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AAEtE,wBAAgB,eAAe,CAAC,MAAM,EAAE,cAAc,wEASrD"}
1
+ {"version":3,"file":"use-bridge-chains.d.ts","sourceRoot":"","sources":["../../../../../../../src/react/web/ui/Bridge/swap-widget/use-bridge-chains.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AAEtE,wBAAgB,eAAe,CAAC,MAAM,EAAE,cAAc,2GA0BrD"}
@@ -1 +1 @@
1
- {"version":3,"file":"WalletEntryButton.d.ts","sourceRoot":"","sources":["../../../../../../src/react/web/ui/ConnectWallet/WalletEntryButton.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAGnE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,0CAA0C,CAAC;AAevE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAEvD;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,KAAK,EAAE;IACvC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,MAAM,CAAC;IACf,YAAY,EAAE,MAAM,IAAI,CAAC;IACzB,aAAa,EAAE,aAAa,CAAC;IAC7B,kBAAkB,EAAE,MAAM,EAAE,GAAG,SAAS,CAAC;IACzC,MAAM,EAAE,cAAc,CAAC;IACvB,QAAQ,EAAE,OAAO,CAAC;IAClB,KAAK,EAAE,MAAM,GAAG,SAAS,CAAC;CAC3B,2CA6DA;AAED,eAAO,MAAM,cAAc;;;qHAwBzB,CAAC"}
1
+ {"version":3,"file":"WalletEntryButton.d.ts","sourceRoot":"","sources":["../../../../../../src/react/web/ui/ConnectWallet/WalletEntryButton.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAGnE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,0CAA0C,CAAC;AAgBvE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAEvD;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,KAAK,EAAE;IACvC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,MAAM,CAAC;IACf,YAAY,EAAE,MAAM,IAAI,CAAC;IACzB,aAAa,EAAE,aAAa,CAAC;IAC7B,kBAAkB,EAAE,MAAM,EAAE,GAAG,SAAS,CAAC;IACzC,MAAM,EAAE,cAAc,CAAC;IACvB,QAAQ,EAAE,OAAO,CAAC;IAClB,KAAK,EAAE,MAAM,GAAG,SAAS,CAAC;CAC3B,2CA6EA;AAED,eAAO,MAAM,cAAc;;;qHAwBzB,CAAC"}
@@ -1,6 +1,3 @@
1
1
  import type { IconFC } from "./types.js";
2
- /**
3
- * @internal
4
- */
5
2
  export declare const EmailIcon: IconFC;
6
3
  //# sourceMappingURL=EmailIcon.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"EmailIcon.d.ts","sourceRoot":"","sources":["../../../../../../../src/react/web/ui/ConnectWallet/icons/EmailIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAEzC;;GAEG;AACH,eAAO,MAAM,SAAS,EAAE,MAwBvB,CAAC"}
1
+ {"version":3,"file":"EmailIcon.d.ts","sourceRoot":"","sources":["../../../../../../../src/react/web/ui/ConnectWallet/icons/EmailIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAEzC,eAAO,MAAM,SAAS,EAAE,MAoBvB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"WalletDotIcon.d.ts","sourceRoot":"","sources":["../../../../../../../src/react/web/ui/ConnectWallet/icons/WalletDotIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAEzC;;GAEG;AACH,eAAO,MAAM,aAAa,EAAE,MAgB3B,CAAC"}
1
+ {"version":3,"file":"WalletDotIcon.d.ts","sourceRoot":"","sources":["../../../../../../../src/react/web/ui/ConnectWallet/icons/WalletDotIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAEzC;;GAEG;AACH,eAAO,MAAM,aAAa,EAAE,MAiB3B,CAAC"}
@@ -0,0 +1,7 @@
1
+ import type { ThirdwebClient } from "../../../../client/client.js";
2
+ import type { Wallet } from "../../../../wallets/interfaces/wallet.js";
3
+ export declare function InAppWalletIcon(props: {
4
+ client: ThirdwebClient;
5
+ wallet: Wallet<"inApp">;
6
+ }): import("react/jsx-runtime").JSX.Element | null;
7
+ //# sourceMappingURL=in-app-wallet-icon.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"in-app-wallet-icon.d.ts","sourceRoot":"","sources":["../../../../../../src/react/web/ui/ConnectWallet/in-app-wallet-icon.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,0CAA0C,CAAC;AAgBvE,wBAAgB,eAAe,CAAC,KAAK,EAAE;IACrC,MAAM,EAAE,cAAc,CAAC;IACvB,MAAM,EAAE,MAAM,CAAC,OAAO,CAAC,CAAC;CACzB,kDAsIA"}
@@ -1 +1 @@
1
- {"version":3,"file":"Spinner.d.ts","sourceRoot":"","sources":["../../../../../../src/react/web/ui/components/Spinner.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,sCAAsC,CAAC;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,sCAAsC,CAAC;AAGhE;;GAEG;AACH,eAAO,MAAM,OAAO,EAAE,KAAK,CAAC,EAAE,CAAC;IAC7B,IAAI,EAAE,MAAM,OAAO,QAAQ,CAAC;IAC5B,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IAC5B,KAAK,CAAC,EAAE,MAAM,KAAK,CAAC,QAAQ,CAAC,CAAC;CAC/B,CAsBA,CAAC"}
1
+ {"version":3,"file":"Spinner.d.ts","sourceRoot":"","sources":["../../../../../../src/react/web/ui/components/Spinner.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,sCAAsC,CAAC;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,sCAAsC,CAAC;AAGhE;;GAEG;AACH,eAAO,MAAM,OAAO,EAAE,KAAK,CAAC,EAAE,CAAC;IAC7B,IAAI,EAAE,MAAM,OAAO,QAAQ,CAAC;IAC5B,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IAC5B,KAAK,CAAC,EAAE,MAAM,KAAK,CAAC,QAAQ,CAAC,CAAC;CAC/B,CA2BA,CAAC"}
@@ -6,10 +6,6 @@ export declare const StyledSvg: import("@emotion/styled").CreateStyledComponent<
6
6
  theme?: import("@emotion/react").Theme;
7
7
  as?: React.ElementType;
8
8
  }, import("react").SVGProps<SVGSVGElement>, {}>;
9
- export declare const StyledCircle: import("@emotion/styled").CreateStyledComponent<{
10
- theme?: import("@emotion/react").Theme;
11
- as?: React.ElementType;
12
- }, import("react").SVGProps<SVGCircleElement>, {}>;
13
9
  export declare const StyledSpan: import("@emotion/styled").CreateStyledComponent<{
14
10
  theme?: import("@emotion/react").Theme;
15
11
  as?: React.ElementType;
@@ -1 +1 @@
1
- {"version":3,"file":"elements.d.ts","sourceRoot":"","sources":["../../../../../../src/react/web/ui/design-system/elements.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,SAAS;;;yGAA6B,CAAC;AACpD,eAAO,MAAM,SAAS;;;+CAA6B,CAAC;AACpD,eAAO,MAAM,YAAY;;;kDAAgC,CAAC;AAC1D,eAAO,MAAM,UAAU;;;2GAA8B,CAAC;AACtD,eAAO,MAAM,YAAY;;;qHAA2B,CAAC;AACrD,eAAO,MAAM,YAAY;;;qHAAgC,CAAC;AAC1D,eAAO,MAAM,WAAW;;;kHAA+B,CAAC;AACxD,eAAO,MAAM,WAAW;;;kHAA+B,CAAC;AACxD,eAAO,MAAM,QAAQ;;;iHAA4B,CAAC;AAClD,eAAO,MAAM,OAAO;;;qHAA2B,CAAC;AAChD,eAAO,MAAM,QAAQ;;;6GAA4B,CAAC;AAClD,eAAO,MAAM,YAAY;;;qHAAgC,CAAC;AAC1D,eAAO,MAAM,YAAY;;;qHAAgC,CAAC"}
1
+ {"version":3,"file":"elements.d.ts","sourceRoot":"","sources":["../../../../../../src/react/web/ui/design-system/elements.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,SAAS;;;yGAA6B,CAAC;AACpD,eAAO,MAAM,SAAS;;;+CAA6B,CAAC;AACpD,eAAO,MAAM,UAAU;;;2GAA8B,CAAC;AACtD,eAAO,MAAM,YAAY;;;qHAA2B,CAAC;AACrD,eAAO,MAAM,YAAY;;;qHAAgC,CAAC;AAC1D,eAAO,MAAM,WAAW;;;kHAA+B,CAAC;AACxD,eAAO,MAAM,WAAW;;;kHAA+B,CAAC;AACxD,eAAO,MAAM,QAAQ;;;iHAA4B,CAAC;AAClD,eAAO,MAAM,OAAO;;;qHAA2B,CAAC;AAChD,eAAO,MAAM,QAAQ;;;6GAA4B,CAAC;AAClD,eAAO,MAAM,YAAY;;;qHAAgC,CAAC;AAC1D,eAAO,MAAM,YAAY;;;qHAAgC,CAAC"}
@@ -2,7 +2,7 @@ import type { Chain } from "../../../../chains/types.js";
2
2
  import type { ThirdwebClient } from "../../../../client/client.js";
3
3
  import type { Profile } from "../../../../wallets/in-app/core/authentication/types.js";
4
4
  import type { Account, Wallet } from "../../../../wallets/interfaces/wallet.js";
5
- import { type SocialAuthOption } from "../../../../wallets/types.js";
5
+ import { type AuthOption, type SocialAuthOption } from "../../../../wallets/types.js";
6
6
  import type { EcosystemWalletId } from "../../../../wallets/wallet-types.js";
7
7
  import type { InAppWalletLocale } from "./locale/types.js";
8
8
  export type ConnectWalletSelectUIState = undefined | {
@@ -20,6 +20,7 @@ export type ConnectWalletSelectUIState = undefined | {
20
20
  linking: boolean;
21
21
  };
22
22
  };
23
+ export declare const defaultAuthOptions: AuthOption[];
23
24
  type ConnectWalletSocialOptionsProps = {
24
25
  select: () => void;
25
26
  done: () => void;
@@ -1 +1 @@
1
- {"version":3,"file":"ConnectWalletSocialOptions.d.ts","sourceRoot":"","sources":["../../../../../../src/react/web/wallets/shared/ConnectWalletSocialOptions.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AACzD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAInE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,yDAAyD,CAAC;AAGvF,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,0CAA0C,CAAC;AAChF,OAAO,EAEL,KAAK,gBAAgB,EAEtB,MAAM,8BAA8B,CAAC;AACtC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAwB7E,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAG3D,MAAM,MAAM,0BAA0B,GAClC,SAAS,GACT;IACE,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,WAAW,CAAC,EAAE;QACZ,IAAI,EAAE,gBAAgB,CAAC;QACvB,iBAAiB,EAAE,OAAO,CAAC,OAAO,GAAG,OAAO,EAAE,CAAC,CAAC;KACjD,CAAC;IACF,UAAU,CAAC,EAAE;QACX,iBAAiB,EAAE,OAAO,CAAC,OAAO,GAAG,OAAO,EAAE,CAAC,CAAC;KACjD,CAAC;IACF,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,WAAW,CAAC,EAAE;QACZ,OAAO,EAAE,OAAO,CAAC;KAClB,CAAC;CACH,CAAC;AAWN,KAAK,+BAA+B,GAAG;IACrC,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,IAAI,EAAE,MAAM,IAAI,CAAC;IACjB,MAAM,EAAE,iBAAiB,CAAC;IAC1B,MAAM,EAAE,MAAM,CAAC,iBAAiB,CAAC,GAAG,MAAM,CAAC,OAAO,CAAC,CAAC;IACpD,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,KAAK,EAAE,KAAK,GAAG,SAAS,CAAC;IACzB,MAAM,EAAE,cAAc,CAAC;IACvB,IAAI,EAAE,SAAS,GAAG,MAAM,CAAC;IACzB,SAAS,CAAC,EAAE,OAAO,CAAC;IAEpB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,0BAA0B,GACrC,OAAO,+BAA+B,4CAubvC,CAAC"}
1
+ {"version":3,"file":"ConnectWalletSocialOptions.d.ts","sourceRoot":"","sources":["../../../../../../src/react/web/wallets/shared/ConnectWalletSocialOptions.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AACzD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAInE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,yDAAyD,CAAC;AAGvF,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,0CAA0C,CAAC;AAChF,OAAO,EACL,KAAK,UAAU,EACf,KAAK,gBAAgB,EAEtB,MAAM,8BAA8B,CAAC;AACtC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAwB7E,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAG3D,MAAM,MAAM,0BAA0B,GAClC,SAAS,GACT;IACE,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,WAAW,CAAC,EAAE;QACZ,IAAI,EAAE,gBAAgB,CAAC;QACvB,iBAAiB,EAAE,OAAO,CAAC,OAAO,GAAG,OAAO,EAAE,CAAC,CAAC;KACjD,CAAC;IACF,UAAU,CAAC,EAAE;QACX,iBAAiB,EAAE,OAAO,CAAC,OAAO,GAAG,OAAO,EAAE,CAAC,CAAC;KACjD,CAAC;IACF,YAAY,CAAC,EAAE,OAAO,CAAC;IAC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I,EAAE,MAAM,IAAI,CAAC;IACjB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,MAAM,EAAE,cAAc,CAAC;IACvB,KAAK,EAAE,KAAK,GAAG,SAAS,CAAC;IACzB,IAAI,EAAE,SAAS,GAAG,MAAM,CAAC;IACzB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB,kDAiUA"}
1
+ {"version":3,"file":"OTPLoginUI.d.ts","sourceRoot":"","sources":["../../../../../../src/react/web/wallets/shared/OTPLoginUI.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AACzD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAOnE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,0CAA0C,CAAC;AAYvE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAe3D;;GAEG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE;IAChC,QAAQ,EAAE;QAAE,KAAK,EAAE,MAAM,CAAA;KAAE,GAAG;QAAE,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC;IAChD,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,iBAAiB,CAAC;IAC1B,IAAI,EAAE,MAAM,IAAI,CAAC;IACjB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,MAAM,EAAE,cAAc,CAAC;IACvB,KAAK,EAAE,KAAK,GAAG,SAAS,CAAC;IACzB,IAAI,EAAE,SAAS,GAAG,MAAM,CAAC;IACzB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB,kDA2UA"}
@@ -8,5 +8,8 @@ export declare function WideModal(): import("react/jsx-runtime").JSX.Element;
8
8
  export declare function ClassNameAndStylesAdded(): import("react/jsx-runtime").JSX.Element;
9
9
  export declare function WideModalAndClassNameAndStylesAdded(): import("react/jsx-runtime").JSX.Element;
10
10
  export declare function AllInAppWalletAuthMethods(): import("react/jsx-runtime").JSX.Element;
11
+ export declare function ConfiguredInAppWalletWideModal(): import("react/jsx-runtime").JSX.Element;
12
+ export declare function GoogleLoginWideModal(): import("react/jsx-runtime").JSX.Element;
13
+ export declare function GithubLoginWideModal(): import("react/jsx-runtime").JSX.Element;
11
14
  export declare function EcosystemWallet(): import("react/jsx-runtime").JSX.Element;
12
15
  //# sourceMappingURL=ConnectEmbed.stories.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ConnectEmbed.stories.d.ts","sourceRoot":"","sources":["../../../src/stories/ConnectEmbed.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAE7C,OAAO,EAAE,YAAY,EAAE,MAAM,qDAAqD,CAAC;AAKnF,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,YAAY,CAoBnC,CAAC;AACF,eAAe,IAAI,CAAC;AAEpB,wBAAgB,UAAU,4CAEzB;AAED,wBAAgB,MAAM,4CAUrB;AAED,wBAAgB,SAAS,4CAExB;AAED,wBAAgB,uBAAuB,4CAUtC;AAED,wBAAgB,mCAAmC,4CAWlD;AAED,wBAAgB,yBAAyB,4CAmCxC;AAED,wBAAgB,eAAe,4CAa9B"}
1
+ {"version":3,"file":"ConnectEmbed.stories.d.ts","sourceRoot":"","sources":["../../../src/stories/ConnectEmbed.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAE7C,OAAO,EAAE,YAAY,EAAE,MAAM,qDAAqD,CAAC;AAMnF,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,YAAY,CAoBnC,CAAC;AACF,eAAe,IAAI,CAAC;AAEpB,wBAAgB,UAAU,4CAEzB;AAED,wBAAgB,MAAM,4CAUrB;AAED,wBAAgB,SAAS,4CAExB;AAED,wBAAgB,uBAAuB,4CAUtC;AAED,wBAAgB,mCAAmC,4CAWlD;AAED,wBAAgB,yBAAyB,4CAmCxC;AAED,wBAAgB,8BAA8B,4CAgB7C;AAED,wBAAgB,oBAAoB,4CAgBnC;AAED,wBAAgB,oBAAoB,4CAgBnC;AAED,wBAAgB,eAAe,4CAa9B"}
@@ -0,0 +1,10 @@
1
+ import type { Meta } from "@storybook/react";
2
+ import type { AuthOption } from "../wallets/types.js";
3
+ declare const meta: Meta<typeof Variant>;
4
+ export default meta;
5
+ export declare function LightTheme(): import("react/jsx-runtime").JSX.Element;
6
+ export declare function DarkTheme(): import("react/jsx-runtime").JSX.Element;
7
+ declare function Variant(props: {
8
+ authOptions: AuthOption[];
9
+ }): import("react/jsx-runtime").JSX.Element;
10
+ //# sourceMappingURL=in-app-wallet-icon.stories.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"in-app-wallet-icon.stories.d.ts","sourceRoot":"","sources":["../../../src/stories/in-app-wallet-icon.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAQ7C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAGtD,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,OAAO,CAW9B,CAAC;AACF,eAAe,IAAI,CAAC;AAuGpB,wBAAgB,UAAU,4CAEzB;AAED,wBAAgB,SAAS,4CAExB;AAUD,iBAAS,OAAO,CAAC,KAAK,EAAE;IAAE,WAAW,EAAE,UAAU,EAAE,CAAA;CAAE,2CAWpD"}
@@ -1,2 +1,2 @@
1
- export declare const version = "5.116.0";
1
+ export declare const version = "5.116.2-nightly-151127d66825365cb0ed949ae28b9906ee4dfc8d-20251213000343";
2
2
  //# sourceMappingURL=version.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,YAAY,CAAC"}
1
+ {"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,4EAA4E,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"otp.d.ts","sourceRoot":"","sources":["../../../../../../../src/wallets/in-app/web/lib/auth/otp.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AAMtE,OAAO,KAAK,EACV,mCAAmC,EACnC,qBAAqB,EACrB,eAAe,EAChB,MAAM,uCAAuC,CAAC;AAC/C,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,+BAA+B,CAAC;AAE/D;;GAEG;AACH,eAAO,MAAM,OAAO,GAAU,MAAM,eAAe,KAAG,OAAO,CAAC,IAAI,CAyCjE,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,SAAS,GACpB,MAAM,qBAAqB,GAAG;IAC5B,MAAM,EAAE,cAAc,CAAC;IACvB,SAAS,CAAC,EAAE,SAAS,CAAC;CACvB,KACA,OAAO,CAAC,mCAAmC,CA+C7C,CAAC"}
1
+ {"version":3,"file":"otp.d.ts","sourceRoot":"","sources":["../../../../../../../src/wallets/in-app/web/lib/auth/otp.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AAMtE,OAAO,KAAK,EACV,mCAAmC,EACnC,qBAAqB,EACrB,eAAe,EAChB,MAAM,uCAAuC,CAAC;AAC/C,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,+BAA+B,CAAC;AAE/D;;GAEG;AACH,eAAO,MAAM,OAAO,GAAU,MAAM,eAAe,KAAG,OAAO,CAAC,IAAI,CAmDjE,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,SAAS,GACpB,MAAM,qBAAqB,GAAG;IAC5B,MAAM,EAAE,cAAc,CAAC;IACvB,SAAS,CAAC,EAAE,SAAS,CAAC;CACvB,KACA,OAAO,CAAC,mCAAmC,CA+C7C,CAAC"}
@@ -1,4 +1,5 @@
1
1
  import type { ThirdwebClient } from "../client/client.js";
2
+ import type { AsyncStorage } from "../utils/storage/AsyncStorage.js";
2
3
  import type { Wallet } from "../wallets/interfaces/wallet.js";
3
4
  import { type RequestedPaymentRequirements } from "./schemas.js";
4
5
  /**
@@ -43,5 +44,10 @@ import { type RequestedPaymentRequirements } from "./schemas.js";
43
44
  export declare function wrapFetchWithPayment(fetch: typeof globalThis.fetch, client: ThirdwebClient, wallet: Wallet, options?: {
44
45
  maxValue?: bigint;
45
46
  paymentRequirementsSelector?: (paymentRequirements: RequestedPaymentRequirements[]) => RequestedPaymentRequirements | undefined;
47
+ /**
48
+ * Storage for caching permit signatures (for "upto" scheme).
49
+ * When provided, permit signatures will be cached and reused if the on-chain allowance is sufficient.
50
+ */
51
+ storage?: AsyncStorage;
46
52
  }): (input: RequestInfo, init?: RequestInit) => Promise<Response>;
47
53
  //# sourceMappingURL=fetchWithPayment.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"fetchWithPayment.d.ts","sourceRoot":"","sources":["../../../src/x402/fetchWithPayment.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAC1D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,iCAAiC,CAAC;AAC9D,OAAO,EAGL,KAAK,4BAA4B,EAElC,MAAM,cAAc,CAAC;AAGtB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsCG;AACH,wBAAgB,oBAAoB,CAClC,KAAK,EAAE,OAAO,UAAU,CAAC,KAAK,EAC9B,MAAM,EAAE,cAAc,EACtB,MAAM,EAAE,MAAM,EACd,OAAO,CAAC,EAAE;IACR,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,2BAA2B,CAAC,EAAE,CAC5B,mBAAmB,EAAE,4BAA4B,EAAE,KAChD,4BAA4B,GAAG,SAAS,CAAC;CAC/C,IAEa,OAAO,WAAW,EAAE,OAAO,WAAW,uBA6FrD"}
1
+ {"version":3,"file":"fetchWithPayment.d.ts","sourceRoot":"","sources":["../../../src/x402/fetchWithPayment.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAE1D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAC;AAErE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,iCAAiC,CAAC;AAE9D,OAAO,EAGL,KAAK,4BAA4B,EAElC,MAAM,cAAc,CAAC;AAGtB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsCG;AACH,wBAAgB,oBAAoB,CAClC,KAAK,EAAE,OAAO,UAAU,CAAC,KAAK,EAC9B,MAAM,EAAE,cAAc,EACtB,MAAM,EAAE,MAAM,EACd,OAAO,CAAC,EAAE;IACR,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,2BAA2B,CAAC,EAAE,CAC5B,mBAAmB,EAAE,4BAA4B,EAAE,KAChD,4BAA4B,GAAG,SAAS,CAAC;IAC9C;;;OAGG;IACH,OAAO,CAAC,EAAE,YAAY,CAAC;CACxB,IAEa,OAAO,WAAW,EAAE,OAAO,WAAW,uBAyGrD"}
@@ -0,0 +1,43 @@
1
+ import type { AsyncStorage } from "../utils/storage/AsyncStorage.js";
2
+ import type { RequestedPaymentPayload } from "./schemas.js";
3
+ /**
4
+ * Cached permit signature data structure
5
+ */
6
+ type CachedPermitSignature = {
7
+ payload: RequestedPaymentPayload;
8
+ deadline: string;
9
+ maxAmount: string;
10
+ };
11
+ /**
12
+ * Parameters for generating a permit cache key
13
+ */
14
+ export type PermitCacheKeyParams = {
15
+ chainId: number;
16
+ asset: string;
17
+ owner: string;
18
+ spender: string;
19
+ };
20
+ /**
21
+ * Retrieves a cached permit signature from storage
22
+ * @param storage - The AsyncStorage instance to use
23
+ * @param params - The parameters identifying the cached signature
24
+ * @returns The cached signature data or null if not found
25
+ */
26
+ export declare function getPermitSignatureFromCache(storage: AsyncStorage, params: PermitCacheKeyParams): Promise<CachedPermitSignature | null>;
27
+ /**
28
+ * Saves a permit signature to storage cache
29
+ * @param storage - The AsyncStorage instance to use
30
+ * @param params - The parameters identifying the signature
31
+ * @param payload - The signed payment payload to cache
32
+ * @param deadline - The deadline timestamp of the permit
33
+ * @param maxAmount - The maximum amount authorized
34
+ */
35
+ export declare function savePermitSignatureToCache(storage: AsyncStorage, params: PermitCacheKeyParams, payload: RequestedPaymentPayload, deadline: string, maxAmount: string): Promise<void>;
36
+ /**
37
+ * Clears a cached permit signature from storage
38
+ * @param storage - The AsyncStorage instance to use
39
+ * @param params - The parameters identifying the cached signature
40
+ */
41
+ export declare function clearPermitSignatureFromCache(storage: AsyncStorage, params: PermitCacheKeyParams): Promise<void>;
42
+ export {};
43
+ //# sourceMappingURL=permitSignatureStorage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"permitSignatureStorage.d.ts","sourceRoot":"","sources":["../../../src/x402/permitSignatureStorage.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAC;AACrE,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,cAAc,CAAC;AAE5D;;GAEG;AACH,KAAK,qBAAqB,GAAG;IAC3B,OAAO,EAAE,uBAAuB,CAAC;IACjC,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,oBAAoB,GAAG;IACjC,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;CACjB,CAAC;AAaF;;;;;GAKG;AACH,wBAAsB,2BAA2B,CAC/C,OAAO,EAAE,YAAY,EACrB,MAAM,EAAE,oBAAoB,GAC3B,OAAO,CAAC,qBAAqB,GAAG,IAAI,CAAC,CAWvC;AAED;;;;;;;GAOG;AACH,wBAAsB,0BAA0B,CAC9C,OAAO,EAAE,YAAY,EACrB,MAAM,EAAE,oBAAoB,EAC5B,OAAO,EAAE,uBAAuB,EAChC,QAAQ,EAAE,MAAM,EAChB,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,IAAI,CAAC,CAYf;AAED;;;;GAIG;AACH,wBAAsB,6BAA6B,CACjD,OAAO,EAAE,YAAY,EACrB,MAAM,EAAE,oBAAoB,GAC3B,OAAO,CAAC,IAAI,CAAC,CAOf"}
@@ -1,4 +1,5 @@
1
1
  import type { ThirdwebClient } from "../client/client.js";
2
+ import type { AsyncStorage } from "../utils/storage/AsyncStorage.js";
2
3
  import type { Account } from "../wallets/interfaces/wallet.js";
3
4
  import { type RequestedPaymentRequirements } from "./schemas.js";
4
5
  /**
@@ -7,7 +8,8 @@ import { type RequestedPaymentRequirements } from "./schemas.js";
7
8
  * @param client - The signer wallet instance used to create the payment header
8
9
  * @param x402Version - The version of the X402 protocol to use
9
10
  * @param paymentRequirements - The payment requirements containing scheme and network information
11
+ * @param storage - Optional storage for caching permit signatures (for "upto" scheme)
10
12
  * @returns A promise that resolves to the encoded payment header string
11
13
  */
12
- export declare function createPaymentHeader(client: ThirdwebClient, account: Account, paymentRequirements: RequestedPaymentRequirements, x402Version: number): Promise<string>;
14
+ export declare function createPaymentHeader(client: ThirdwebClient, account: Account, paymentRequirements: RequestedPaymentRequirements, x402Version: number, storage?: AsyncStorage): Promise<string>;
13
15
  //# sourceMappingURL=sign.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"sign.d.ts","sourceRoot":"","sources":["../../../src/x402/sign.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAK1D,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,iCAAiC,CAAC;AAG/D,OAAO,EAIL,KAAK,4BAA4B,EAElC,MAAM,cAAc,CAAC;AAoItB;;;;;;;GAOG;AACH,wBAAsB,mBAAmB,CACvC,MAAM,EAAE,cAAc,EACtB,OAAO,EAAE,OAAO,EAChB,mBAAmB,EAAE,4BAA4B,EACjD,WAAW,EAAE,MAAM,GAClB,OAAO,CAAC,MAAM,CAAC,CAQjB"}
1
+ {"version":3,"file":"sign.d.ts","sourceRoot":"","sources":["../../../src/x402/sign.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAM1D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAC;AACrE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,iCAAiC,CAAC;AAQ/D,OAAO,EAIL,KAAK,4BAA4B,EAElC,MAAM,cAAc,CAAC;AAqMtB;;;;;;;;GAQG;AACH,wBAAsB,mBAAmB,CACvC,MAAM,EAAE,cAAc,EACtB,OAAO,EAAE,OAAO,EAChB,mBAAmB,EAAE,4BAA4B,EACjD,WAAW,EAAE,MAAM,EACnB,OAAO,CAAC,EAAE,YAAY,GACrB,OAAO,CAAC,MAAM,CAAC,CASjB"}
package/package.json CHANGED
@@ -399,7 +399,7 @@
399
399
  }
400
400
  },
401
401
  "typings": "./dist/types/exports/thirdweb.d.ts",
402
- "version": "5.116.0",
402
+ "version": "5.116.2-nightly-151127d66825365cb0ed949ae28b9906ee4dfc8d-20251213000343",
403
403
  "scripts": {
404
404
  "bench": "vitest -c ./test/vitest.config.ts bench",
405
405
  "bench:compare": "bun run ./benchmarks/run.ts",
@@ -2,6 +2,7 @@
2
2
 
3
3
  import { useMutation } from "@tanstack/react-query";
4
4
  import type { ThirdwebClient } from "../../../../client/client.js";
5
+ import type { AsyncStorage } from "../../../../utils/storage/AsyncStorage.js";
5
6
  import type { Wallet } from "../../../../wallets/interfaces/wallet.js";
6
7
  import { wrapFetchWithPayment } from "../../../../x402/fetchWithPayment.js";
7
8
  import type { RequestedPaymentRequirements } from "../../../../x402/schemas.js";
@@ -14,6 +15,11 @@ export type UseFetchWithPaymentOptions = {
14
15
  paymentRequirements: RequestedPaymentRequirements[],
15
16
  ) => RequestedPaymentRequirements | undefined;
16
17
  parseAs?: "json" | "text" | "raw";
18
+ /**
19
+ * Storage for caching permit signatures (for "upto" scheme).
20
+ * When provided, permit signatures will be cached and reused if the on-chain allowance is sufficient.
21
+ */
22
+ storage?: AsyncStorage;
17
23
  };
18
24
 
19
25
  type ShowErrorModalCallback = (data: {
@@ -81,7 +87,11 @@ export function useFetchWithPaymentCore(
81
87
  globalThis.fetch,
82
88
  client,
83
89
  currentWallet,
84
- options,
90
+ {
91
+ maxValue: options?.maxValue,
92
+ paymentRequirementsSelector: options?.paymentRequirementsSelector,
93
+ storage: options?.storage,
94
+ },
85
95
  );
86
96
 
87
97
  const response = await wrappedFetch(input, init);
@@ -1,6 +1,7 @@
1
1
  "use client";
2
2
 
3
3
  import type { ThirdwebClient } from "../../../../client/client.js";
4
+ import { nativeLocalStorage } from "../../../../utils/storage/nativeStorage.js";
4
5
  import {
5
6
  type UseFetchWithPaymentOptions,
6
7
  useFetchWithPaymentCore,
@@ -29,6 +30,7 @@ export type { UseFetchWithPaymentOptions };
29
30
  * @param options.maxValue - The maximum allowed payment amount in base units
30
31
  * @param options.paymentRequirementsSelector - Custom function to select payment requirements from available options
31
32
  * @param options.parseAs - How to parse the response: "json" (default), "text", or "raw"
33
+ * @param options.storage - Storage for caching permit signatures (for "upto" scheme). Provide your own AsyncStorage implementation for React Native.
32
34
  * @returns An object containing:
33
35
  * - `fetchWithPayment`: Function to make fetch requests with automatic payment handling (returns parsed data)
34
36
  * - `isPending`: Boolean indicating if a request is in progress
@@ -92,5 +94,8 @@ export function useFetchWithPayment(
92
94
  options?: UseFetchWithPaymentOptions,
93
95
  ) {
94
96
  // Native version doesn't show modal, errors bubble up naturally
95
- return useFetchWithPaymentCore(client, options);
97
+ return useFetchWithPaymentCore(client, {
98
+ ...options,
99
+ storage: options?.storage ?? nativeLocalStorage,
100
+ });
96
101
  }
@@ -1,7 +1,8 @@
1
1
  "use client";
2
2
 
3
- import { useContext } from "react";
3
+ import { useContext, useMemo } from "react";
4
4
  import type { ThirdwebClient } from "../../../../client/client.js";
5
+ import { webLocalStorage } from "../../../../utils/storage/webStorage.js";
5
6
  import type { Wallet } from "../../../../wallets/interfaces/wallet.js";
6
7
  import type { Theme } from "../../../core/design-system/index.js";
7
8
  import {
@@ -255,9 +256,18 @@ export function useFetchWithPayment(
255
256
  }
256
257
  : undefined;
257
258
 
259
+ // Default to webLocalStorage for permit signature caching
260
+ const resolvedOptions = useMemo(
261
+ () => ({
262
+ ...(options ?? {}),
263
+ storage: options?.storage ?? webLocalStorage,
264
+ }),
265
+ [options],
266
+ );
267
+
258
268
  return useFetchWithPaymentCore(
259
269
  client,
260
- options,
270
+ resolvedOptions,
261
271
  showErrorModal,
262
272
  showConnectModal,
263
273
  );
@@ -6,8 +6,10 @@ import { Buy, Sell } from "../../../../../bridge/index.js";
6
6
  import type { prepare as SellPrepare } from "../../../../../bridge/Sell.js";
7
7
  import type { TokenWithPrices } from "../../../../../bridge/types/Token.js";
8
8
  import type { ThirdwebClient } from "../../../../../client/client.js";
9
+ import { NATIVE_TOKEN_ADDRESS } from "../../../../../constants/addresses.js";
9
10
  import { getToken } from "../../../../../pay/convert/get-token.js";
10
11
  import type { SupportedFiatCurrency } from "../../../../../pay/convert/type.js";
12
+ import { getAddress } from "../../../../../utils/address.js";
11
13
  import { toTokens, toUnits } from "../../../../../utils/units.js";
12
14
  import { useCustomTheme } from "../../../../core/design-system/CustomThemeProvider.js";
13
15
  import {
@@ -245,6 +247,18 @@ export function SwapUI(props: SwapUIProps) {
245
247
  ) {
246
248
  props.setSellToken(undefined);
247
249
  }
250
+
251
+ // if sell token is not selected, set it as native token of the buy token's chain if buy token is not a native token itself
252
+ if (
253
+ !props.sellToken &&
254
+ token.tokenAddress.toLowerCase() !==
255
+ NATIVE_TOKEN_ADDRESS.toLowerCase()
256
+ ) {
257
+ props.setSellToken({
258
+ tokenAddress: getAddress(NATIVE_TOKEN_ADDRESS),
259
+ chainId: token.chainId,
260
+ });
261
+ }
248
262
  }}
249
263
  />
250
264
  )}
@@ -270,6 +284,18 @@ export function SwapUI(props: SwapUIProps) {
270
284
  ) {
271
285
  props.setBuyToken(undefined);
272
286
  }
287
+
288
+ // if buy token is not selected, set it as native token of the sell token's chain if sell token is not a native token itself
289
+ if (
290
+ !props.buyToken &&
291
+ token.tokenAddress.toLowerCase() !==
292
+ NATIVE_TOKEN_ADDRESS.toLowerCase()
293
+ ) {
294
+ props.setBuyToken({
295
+ tokenAddress: getAddress(NATIVE_TOKEN_ADDRESS),
296
+ chainId: token.chainId,
297
+ });
298
+ }
273
299
  }}
274
300
  activeWalletInfo={props.activeWalletInfo}
275
301
  />
@@ -5,8 +5,25 @@ import type { ThirdwebClient } from "../../../../../client/client.js";
5
5
  export function useBridgeChains(client: ThirdwebClient) {
6
6
  return useQuery({
7
7
  queryKey: ["bridge-chains"],
8
- queryFn: () => {
9
- return chains({ client });
8
+ queryFn: async () => {
9
+ const data = await chains({ client });
10
+ const dataCopy = [...data];
11
+ // sort by name, but if name starts with number, put it at the end
12
+
13
+ return dataCopy.sort((a, b) => {
14
+ const aStartsWithNumber = a.name[0]?.match(/^\d/);
15
+ const bStartsWithNumber = b.name[0]?.match(/^\d/);
16
+
17
+ if (aStartsWithNumber && !bStartsWithNumber) {
18
+ return 1;
19
+ }
20
+
21
+ if (!aStartsWithNumber && bStartsWithNumber) {
22
+ return -1;
23
+ }
24
+
25
+ return a.name.localeCompare(b.name);
26
+ });
10
27
  },
11
28
  refetchOnMount: false,
12
29
  refetchOnWindowFocus: false,
@@ -17,6 +17,7 @@ import { Skeleton } from "../components/Skeleton.js";
17
17
  import { Text } from "../components/text.js";
18
18
  import { WalletImage } from "../components/WalletImage.js";
19
19
  import { StyledButton } from "../design-system/elements.js";
20
+ import { InAppWalletIcon } from "./in-app-wallet-icon.js";
20
21
  import type { ConnectLocale } from "./locale/types.js";
21
22
 
22
23
  /**
@@ -52,9 +53,20 @@ export function WalletEntryButton(props: {
52
53
  wallet && walletId === "inApp"
53
54
  ? (wallet.getConfig() as InAppWalletCreationOptions)?.metadata
54
55
  : undefined;
55
- const nameOverride = customMeta?.name || walletName;
56
+ let nameOverride = customMeta?.name || walletName;
56
57
  const iconOverride = customMeta?.icon;
57
58
 
59
+ // change "Social Login" to name of the login method if only 1 method is enabled
60
+ if (wallet.id === "inApp") {
61
+ const config = wallet.getConfig() as InAppWalletCreationOptions;
62
+ if (config?.auth?.options.length === 1) {
63
+ const name = config.auth?.options[0];
64
+ if (name) {
65
+ nameOverride = uppercaseFirstLetter({ text: name });
66
+ }
67
+ }
68
+ }
69
+
58
70
  return (
59
71
  <WalletButtonEl
60
72
  className={props.className}
@@ -64,12 +76,17 @@ export function WalletEntryButton(props: {
64
76
  >
65
77
  {iconOverride ? (
66
78
  <Img
67
- alt={nameOverride}
79
+ alt=""
68
80
  client={props.client}
69
81
  height={`${iconSize.xl}`}
70
82
  src={iconOverride}
71
83
  width={`${iconSize.xl}`}
72
84
  />
85
+ ) : wallet.id === "inApp" ? (
86
+ <InAppWalletIcon
87
+ client={props.client}
88
+ wallet={wallet as Wallet<"inApp">}
89
+ />
73
90
  ) : (
74
91
  <WalletImage client={props.client} id={walletId} size={iconSize.xl} />
75
92
  )}
@@ -119,3 +136,7 @@ export const WalletButtonEl = /* @__PURE__ */ StyledButton((_) => {
119
136
  width: "100%",
120
137
  };
121
138
  });
139
+
140
+ function uppercaseFirstLetter(props: { text: string }) {
141
+ return props.text.charAt(0).toUpperCase() + props.text.slice(1);
142
+ }
@@ -1,30 +1,23 @@
1
1
  import type { IconFC } from "./types.js";
2
2
 
3
- /**
4
- * @internal
5
- */
6
3
  export const EmailIcon: IconFC = (props) => {
7
4
  return (
8
5
  <svg
9
- fill="none"
6
+ xmlns="http://www.w3.org/2000/svg"
7
+ width={props.size}
10
8
  height={props.size}
9
+ viewBox="0 0 24 24"
11
10
  role="presentation"
12
- viewBox="0 0 16 16"
13
- width={props.size}
14
- xmlns="http://www.w3.org/2000/svg"
11
+ fill="none"
12
+ stroke="currentColor"
13
+ strokeWidth="2"
14
+ strokeLinecap="round"
15
+ strokeLinejoin="round"
16
+ className="lucide lucide-mail-icon lucide-mail"
17
+ style={{ color: props.color }}
15
18
  >
16
- <path
17
- d="M13.3335 2.6665H2.66683C1.93045 2.6665 1.3335 3.26346 1.3335 3.99984V11.9998C1.3335 12.7362 1.93045 13.3332 2.66683 13.3332H13.3335C14.0699 13.3332 14.6668 12.7362 14.6668 11.9998V3.99984C14.6668 3.26346 14.0699 2.6665 13.3335 2.6665Z"
18
- stroke={props.color ?? "currentColor"}
19
- strokeLinecap="round"
20
- strokeLinejoin="round"
21
- />
22
- <path
23
- d="M14.6668 4.6665L8.68683 8.4665C8.48101 8.59545 8.24304 8.66384 8.00016 8.66384C7.75728 8.66384 7.51931 8.59545 7.3135 8.4665L1.3335 4.6665"
24
- stroke={props.color ?? "currentColor"}
25
- strokeLinecap="round"
26
- strokeLinejoin="round"
27
- />
19
+ <path d="m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7" />
20
+ <rect x="2" y="4" width="20" height="16" rx="2" />
28
21
  </svg>
29
22
  );
30
23
  };
@@ -11,6 +11,7 @@ export const WalletDotIcon: IconFC = (props) => {
11
11
  viewBox="0 0 18 18"
12
12
  width={props.size}
13
13
  height={props.size}
14
+ style={{ color: props.color }}
14
15
  role="presentation"
15
16
  >
16
17
  <path