@rhinestone/deposit-modal 0.0.0-dev-20260727145407 → 0.0.0-dev-20260727172000

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 (57) hide show
  1. package/README.md +65 -5
  2. package/dist/{chunk-QMN3IYME.cjs → DepositModalReown-2VJFCAUT.cjs} +66 -10
  3. package/dist/{chunk-UMVDMKCX.mjs → DepositModalReown-XIJUAOYR.mjs} +60 -4
  4. package/dist/{chunk-KLTJCZCH.cjs → chunk-4ALOTMS6.cjs} +118 -84
  5. package/dist/{chunk-ORYDX7FS.mjs → chunk-5S7WGG7V.mjs} +122 -88
  6. package/dist/chunk-62PQAA3X.mjs +6 -0
  7. package/dist/{chunk-CF5ZAKST.mjs → chunk-7PLFGGXC.mjs} +921 -1181
  8. package/dist/chunk-7RZPE5KV.cjs +6 -0
  9. package/dist/chunk-EGB3NWML.cjs +809 -0
  10. package/dist/{chunk-2HB26BWN.mjs → chunk-ESWMFZEV.mjs} +22 -17
  11. package/dist/{chunk-DKU6CVY6.cjs → chunk-H7TD7XE5.cjs} +83 -82
  12. package/dist/chunk-KZGITCZT.mjs +809 -0
  13. package/dist/{chunk-SE7ADCVW.cjs → chunk-ONPO2OFC.cjs} +828 -1088
  14. package/dist/{chunk-4F2BWS5E.mjs → chunk-PGBW524J.mjs} +3 -2
  15. package/dist/{chunk-XIPHQRGF.cjs → chunk-U2SADOVK.cjs} +217 -301
  16. package/dist/{chunk-RSLT2RQW.mjs → chunk-UI3JRDXX.mjs} +10 -9
  17. package/dist/{chunk-V76RECLR.cjs → chunk-UIN4SMPX.cjs} +88 -83
  18. package/dist/{chunk-5I6LUZTB.cjs → chunk-UKS5VK74.cjs} +4 -3
  19. package/dist/{chunk-JLPVWF2O.mjs → chunk-VZKUD5IN.mjs} +148 -232
  20. package/dist/{chunk-XBNXKZHQ.cjs → chunk-W3WWC4LD.cjs} +6 -2
  21. package/dist/{chunk-OMREKQB2.mjs → chunk-YJP274QC.mjs} +5 -1
  22. package/dist/claim.cjs +6 -5
  23. package/dist/claim.d.cts +3 -6
  24. package/dist/claim.d.ts +3 -6
  25. package/dist/claim.mjs +5 -4
  26. package/dist/constants.cjs +4 -2
  27. package/dist/constants.d.cts +1 -1
  28. package/dist/constants.d.ts +1 -1
  29. package/dist/constants.mjs +4 -2
  30. package/dist/deposit.cjs +8 -7
  31. package/dist/deposit.d.cts +2 -2
  32. package/dist/deposit.d.ts +2 -2
  33. package/dist/deposit.mjs +7 -6
  34. package/dist/index.cjs +10 -9
  35. package/dist/index.d.cts +1 -1
  36. package/dist/index.d.ts +1 -1
  37. package/dist/index.mjs +11 -10
  38. package/dist/polymarket.cjs +5 -4
  39. package/dist/polymarket.mjs +2 -1
  40. package/dist/server.cjs +96 -0
  41. package/dist/server.d.cts +60 -0
  42. package/dist/server.d.ts +60 -0
  43. package/dist/server.mjs +96 -0
  44. package/dist/styles.css +16 -2
  45. package/dist/{types-Dt3ABm1K.d.cts → types-Cuyhz25e.d.cts} +71 -18
  46. package/dist/{types-Dt3ABm1K.d.ts → types-Cuyhz25e.d.ts} +71 -18
  47. package/dist/withdraw.cjs +6 -5
  48. package/dist/withdraw.d.cts +2 -2
  49. package/dist/withdraw.d.ts +2 -2
  50. package/dist/withdraw.mjs +5 -4
  51. package/package.json +11 -1
  52. package/dist/ClaimModalReown-DXYTMXIX.cjs +0 -35
  53. package/dist/ClaimModalReown-YFGZEVQO.mjs +0 -35
  54. package/dist/DepositModalReown-FLY7Y7PQ.mjs +0 -64
  55. package/dist/DepositModalReown-XTZ7I5IB.cjs +0 -64
  56. package/dist/chunk-7S4WRVJ4.mjs +0 -802
  57. package/dist/chunk-A4VMWNDE.cjs +0 -802
package/README.md CHANGED
@@ -8,6 +8,24 @@ React modal for cross-chain deposits and withdrawals via Rhinestone smart accoun
8
8
  npm install @rhinestone/deposit-modal viem
9
9
  ```
10
10
 
11
+ ### Content Security Policy
12
+
13
+ Every logo the modal renders — chain, token, exchange, card-network, wallet and
14
+ dapp marks — is served from Rhinestone's public asset CDN. **A host with an
15
+ explicit `img-src` policy must allow it:**
16
+
17
+ ```
18
+ img-src 'self' data: https://s3.rhinestone.dev;
19
+ ```
20
+
21
+ Omit this and icons render blank — image loads fail silently, so there is no
22
+ console error pointing at the CSP. Hosts without an explicit `img-src` (or with
23
+ `img-src *`) need no change.
24
+
25
+ > Before v0.9 these marks were inlined as `data:` URIs, so `data:` alone was
26
+ > sufficient. They now come from the CDN, which drops ~20 kB (brotli) from the
27
+ > bundle and gives every Rhinestone surface one source of truth.
28
+
11
29
  ## Example
12
30
 
13
31
  ```tsx
@@ -80,7 +98,7 @@ The user picks the destination chain, token, recipient, and amount in the modal;
80
98
 
81
99
  ## Claim a failed deposit
82
100
 
83
- `ClaimModal` lets the smart-account owner recover a failed or rejected EVM deposit to any recipient on its source chain. The connected wallet signs one EIP-712 authorization that binds the deposit, amount, recipient, and deadline, the client never handles the processor API key.
101
+ `ClaimModal` lets a user get a failed or rejected EVM deposit sent back to them on its source chain. They paste the deposit's transaction hash and name a destination — **no wallet connection is involved at any point**.
84
102
 
85
103
  ```tsx
86
104
  import { ClaimModal } from "@rhinestone/deposit-modal/claim";
@@ -88,16 +106,58 @@ import { ClaimModal } from "@rhinestone/deposit-modal/claim";
88
106
  <ClaimModal
89
107
  isOpen={claimOpen}
90
108
  onClose={() => setClaimOpen(false)}
91
- dappWalletClient={walletClient}
92
- // Optional lookup/recipient prefills:
109
+ refundEndpoint="/api/refund"
110
+ // Optional lookup/destination prefills:
93
111
  defaultSourceChain={42161}
94
112
  defaultTxHash={depositTxHash}
95
- defaultRecipient={address}
96
113
  onLifecycle={(event) => console.log(event)}
97
114
  />
98
115
  ```
99
116
 
100
- The backend must proxy both `GET /deposits` and `POST /deposits/recover` while injecting its existing processor API key. A separate recovery API key is not required: the API key scopes the tenant, while the owner signature authorizes the transfer.
117
+ ### Why you have to authorize it
118
+
119
+ Deposit accounts are owned by the Rhinestone service, so there is no user wallet that can sign for a refund — and when the deposit arrived from an exchange, the sender can't sign either. Whether a deposit belongs to a given user is something **only your app knows**: you authenticated them, and you chose the `recipient` you passed to the widget.
120
+
121
+ So `refundEndpoint` points at something you control. Two shapes:
122
+
123
+ **Your own backend** — same-origin, so the session cookie authenticates it. `createRefundHandler` does everything except the auth decision:
124
+
125
+ ```ts
126
+ // app/api/refund/route.ts
127
+ import { createRefundHandler } from "@rhinestone/deposit-modal/server";
128
+
129
+ export const POST = createRefundHandler({
130
+ apiKey: process.env.RHINESTONE_API_KEY!,
131
+ async authorize(request) {
132
+ const session = await getSession(request);
133
+ if (!session) return null; // → 401
134
+ return { recipient: session.depositRecipient }; // the one YOU passed the widget
135
+ },
136
+ });
137
+ ```
138
+
139
+ It verifies the deposit really belongs to that recipient before spending your API key, and 403s otherwise. Return a `destination` from `authorize` to pin where funds go and take that choice away from the browser — the handler reports the effective destination back, so the modal's success screen and `complete` event name the address that was actually paid rather than the one the browser asked for.
140
+
141
+ If you write your own endpoint instead, echo a `destination` in the success body whenever you override the requested one, for the same reason.
142
+
143
+ **A deposit-widget-proxy** — cross-origin, so cookies don't travel. Set `REFUND_TOKEN_SECRET` on the proxy and mint a short-lived token instead:
144
+
145
+ ```tsx
146
+ <ClaimModal
147
+ refundEndpoint="https://your-proxy.example/deposits/refund"
148
+ getUserToken={(refund) =>
149
+ fetch("/api/refund-token", {
150
+ method: "POST",
151
+ body: JSON.stringify(refund),
152
+ }).then((r) => r.json()).then((r) => r.token)
153
+ }
154
+ /* … */
155
+ />
156
+ ```
157
+
158
+ Bind the token to the specific refund it authorizes, not just to the user — an identity-only token is a bearer credential spendable on any destination. See the deposit-widget-proxy README for the mint endpoint.
159
+
160
+ `GET /deposits` still needs to be proxied for the lookup step, as before.
101
161
 
102
162
  ## Fiat on-ramp (Swapped)
103
163
 
@@ -1,14 +1,24 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
2
2
 
3
+ var _chunkONPO2OFCcjs = require('./chunk-ONPO2OFC.cjs');
4
+ require('./chunk-UIN4SMPX.cjs');
5
+ require('./chunk-UKS5VK74.cjs');
3
6
 
4
- var _chunkKLTJCZCHcjs = require('./chunk-KLTJCZCH.cjs');
5
7
 
6
8
 
9
+ var _chunk4ALOTMS6cjs = require('./chunk-4ALOTMS6.cjs');
10
+ require('./chunk-7RZPE5KV.cjs');
11
+ require('./chunk-W3WWC4LD.cjs');
7
12
 
8
- var _chunkA4VMWNDEcjs = require('./chunk-A4VMWNDE.cjs');
9
13
 
10
- // src/core/reown.tsx
14
+
15
+ var _chunkEGB3NWMLcjs = require('./chunk-EGB3NWML.cjs');
16
+
17
+ // src/DepositModalReown.tsx
11
18
  var _react = require('react');
19
+
20
+ // src/core/reown.tsx
21
+
12
22
  var _reactquery = require('@tanstack/react-query');
13
23
  var _appkitadapterwagmi = require('@reown/appkit-adapter-wagmi');
14
24
  var _appkitadaptersolana = require('@reown/appkit-adapter-solana');
@@ -59,7 +69,7 @@ var APPKIT_NETWORK_BY_ID = {
59
69
  [_networks.katana.id]: _networks.katana,
60
70
  [_networks.hyperEvm.id]: _networks.hyperEvm
61
71
  };
62
- var EVM_NETWORKS = _chunkA4VMWNDEcjs.SUPPORTED_CHAINS.map((chain) => {
72
+ var EVM_NETWORKS = _chunkEGB3NWMLcjs.SUPPORTED_CHAINS.map((chain) => {
63
73
  const network = APPKIT_NETWORK_BY_ID[chain.id];
64
74
  if (!network) {
65
75
  throw new Error(
@@ -78,14 +88,14 @@ function buildTransports(rpcUrls) {
78
88
  const transports = {};
79
89
  for (const network of EVM_NETWORKS) {
80
90
  const id = Number(network.id);
81
- transports[id] = _viem.http.call(void 0, _chunkKLTJCZCHcjs.rpcUrlFor.call(void 0, rpcUrls, id));
91
+ transports[id] = _viem.http.call(void 0, _chunk4ALOTMS6cjs.rpcUrlFor.call(void 0, rpcUrls, id));
82
92
  }
83
93
  return transports;
84
94
  }
85
95
  function getEvmRpcFingerprint(rpcUrls) {
86
96
  return EVM_NETWORKS.map((network) => {
87
97
  const id = Number(network.id);
88
- return `${id}=${_nullishCoalesce(_chunkKLTJCZCHcjs.rpcUrlFor.call(void 0, rpcUrls, id), () => ( ""))}`;
98
+ return `${id}=${_nullishCoalesce(_chunk4ALOTMS6cjs.rpcUrlFor.call(void 0, rpcUrls, id), () => ( ""))}`;
89
99
  }).join("|");
90
100
  }
91
101
  var cachedAdapter = null;
@@ -179,9 +189,9 @@ function useReownWallet() {
179
189
  await switchChainAsync({ chainId });
180
190
  }
181
191
  } catch (err) {
182
- if (_chunkKLTJCZCHcjs.isUnsupportedChainSwitchError.call(void 0, err)) {
192
+ if (_chunk4ALOTMS6cjs.isUnsupportedChainSwitchError.call(void 0, err)) {
183
193
  throw new Error(
184
- `Switch to ${_chunkA4VMWNDEcjs.getChainName.call(void 0, chainId)} in your wallet to continue`
194
+ `Switch to ${_chunkEGB3NWMLcjs.getChainName.call(void 0, chainId)} in your wallet to continue`
185
195
  );
186
196
  }
187
197
  throw err;
@@ -190,7 +200,53 @@ function useReownWallet() {
190
200
  };
191
201
  }
192
202
 
203
+ // src/DepositModalReown.tsx
204
+
205
+ var _react5 = require('@reown/appkit-adapter-solana/react');
206
+
207
+ function DepositModalWithReown(props) {
208
+ const reown = useReownWallet();
209
+ const enableSolana = _nullishCoalesce(props.enableSolana, () => ( true));
210
+ const { walletProvider: solanaWalletProvider } = _react3.useAppKitProvider.call(void 0,
211
+ enableSolana ? "solana" : "eip155"
212
+ );
213
+ const { connection: solanaConnection } = _react5.useAppKitConnection.call(void 0, );
214
+ const reownWithSolana = _react.useMemo.call(void 0,
215
+ () => ({
216
+ ...reown,
217
+ solanaProvider: enableSolana && reown.isSolana ? solanaWalletProvider : void 0,
218
+ solanaConnection: enableSolana && reown.isSolana ? solanaConnection : void 0
219
+ }),
220
+ [enableSolana, reown, solanaWalletProvider, solanaConnection]
221
+ );
222
+ const handleConnect = _react.useCallback.call(void 0, () => {
223
+ reown.openConnect();
224
+ }, [reown.openConnect]);
225
+ const handleDisconnect = _react.useCallback.call(void 0, () => {
226
+ reown.disconnect();
227
+ }, [reown.disconnect]);
228
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
229
+ _chunkONPO2OFCcjs.DepositModalInner,
230
+ {
231
+ ...props,
232
+ reownWallet: reownWithSolana,
233
+ onConnect: handleConnect,
234
+ onDisconnect: handleDisconnect
235
+ }
236
+ );
237
+ }
238
+ function DepositModalReown(props) {
239
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
240
+ ReownWalletProvider,
241
+ {
242
+ projectId: props.reownAppId,
243
+ theme: props.theme,
244
+ enableSolana: props.enableSolana,
245
+ rpcUrls: props.rpcUrls,
246
+ children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, DepositModalWithReown, { ...props })
247
+ }
248
+ );
249
+ }
193
250
 
194
251
 
195
-
196
- exports.ReownWalletProvider = ReownWalletProvider; exports.useReownWallet = useReownWallet;
252
+ exports.DepositModalReown = DepositModalReown;
@@ -1,11 +1,21 @@
1
+ import {
2
+ DepositModalInner
3
+ } from "./chunk-7PLFGGXC.mjs";
4
+ import "./chunk-ESWMFZEV.mjs";
5
+ import "./chunk-PGBW524J.mjs";
1
6
  import {
2
7
  isUnsupportedChainSwitchError,
3
8
  rpcUrlFor
4
- } from "./chunk-ORYDX7FS.mjs";
9
+ } from "./chunk-5S7WGG7V.mjs";
10
+ import "./chunk-62PQAA3X.mjs";
11
+ import "./chunk-YJP274QC.mjs";
5
12
  import {
6
13
  SUPPORTED_CHAINS,
7
14
  getChainName
8
- } from "./chunk-7S4WRVJ4.mjs";
15
+ } from "./chunk-KZGITCZT.mjs";
16
+
17
+ // src/DepositModalReown.tsx
18
+ import { useCallback, useMemo } from "react";
9
19
 
10
20
  // src/core/reown.tsx
11
21
  import { useState } from "react";
@@ -190,7 +200,53 @@ function useReownWallet() {
190
200
  };
191
201
  }
192
202
 
203
+ // src/DepositModalReown.tsx
204
+ import { useAppKitProvider } from "@reown/appkit/react";
205
+ import { useAppKitConnection } from "@reown/appkit-adapter-solana/react";
206
+ import { jsx as jsx2 } from "react/jsx-runtime";
207
+ function DepositModalWithReown(props) {
208
+ const reown = useReownWallet();
209
+ const enableSolana = props.enableSolana ?? true;
210
+ const { walletProvider: solanaWalletProvider } = useAppKitProvider(
211
+ enableSolana ? "solana" : "eip155"
212
+ );
213
+ const { connection: solanaConnection } = useAppKitConnection();
214
+ const reownWithSolana = useMemo(
215
+ () => ({
216
+ ...reown,
217
+ solanaProvider: enableSolana && reown.isSolana ? solanaWalletProvider : void 0,
218
+ solanaConnection: enableSolana && reown.isSolana ? solanaConnection : void 0
219
+ }),
220
+ [enableSolana, reown, solanaWalletProvider, solanaConnection]
221
+ );
222
+ const handleConnect = useCallback(() => {
223
+ reown.openConnect();
224
+ }, [reown.openConnect]);
225
+ const handleDisconnect = useCallback(() => {
226
+ reown.disconnect();
227
+ }, [reown.disconnect]);
228
+ return /* @__PURE__ */ jsx2(
229
+ DepositModalInner,
230
+ {
231
+ ...props,
232
+ reownWallet: reownWithSolana,
233
+ onConnect: handleConnect,
234
+ onDisconnect: handleDisconnect
235
+ }
236
+ );
237
+ }
238
+ function DepositModalReown(props) {
239
+ return /* @__PURE__ */ jsx2(
240
+ ReownWalletProvider,
241
+ {
242
+ projectId: props.reownAppId,
243
+ theme: props.theme,
244
+ enableSolana: props.enableSolana,
245
+ rpcUrls: props.rpcUrls,
246
+ children: /* @__PURE__ */ jsx2(DepositModalWithReown, { ...props })
247
+ }
248
+ );
249
+ }
193
250
  export {
194
- ReownWalletProvider,
195
- useReownWallet
251
+ DepositModalReown
196
252
  };
@@ -1,5 +1,6 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
2
2
 
3
+ var _chunk7RZPE5KVcjs = require('./chunk-7RZPE5KV.cjs');
3
4
 
4
5
 
5
6
 
@@ -14,7 +15,9 @@
14
15
 
15
16
 
16
17
 
17
- var _chunkA4VMWNDEcjs = require('./chunk-A4VMWNDE.cjs');
18
+
19
+
20
+ var _chunkEGB3NWMLcjs = require('./chunk-EGB3NWML.cjs');
18
21
 
19
22
  // src/components/ui/Modal.tsx
20
23
 
@@ -217,6 +220,39 @@ var CircleArrowOutUpLeftIcon = _lucidereact.CircleArrowOutUpLeft;
217
220
  var CardIcon = _lucidereact.CreditCard;
218
221
  var BankIcon = _lucidereact.Landmark;
219
222
  var UnplugIcon = _lucidereact.Unplug;
223
+ function MigrateAssetsIcon() {
224
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
225
+ "svg",
226
+ {
227
+ width: "24",
228
+ height: "24",
229
+ viewBox: "0 0 24 24",
230
+ fill: "none",
231
+ xmlns: "http://www.w3.org/2000/svg",
232
+ "aria-hidden": "true",
233
+ children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
234
+ "g",
235
+ {
236
+ stroke: "currentColor",
237
+ strokeWidth: "2",
238
+ strokeLinecap: "round",
239
+ strokeLinejoin: "round",
240
+ children: [
241
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
242
+ "path",
243
+ {
244
+ d: "M19 4.344V3C19 2.46957 18.7893 1.96086 18.4142 1.58579C18.0391 1.21071 17.5304 1 17 1H3C2.46957 1 1.96086 1.21071 1.58579 1.58579C1.21071 1.96086 1 2.46957 1 3V17C1 17.5304 1.21071 18.0391 1.58579 18.4142C1.96086 18.7893 2.46957 19 3 19H17C17.5304 19 18.0391 18.7893 18.4142 18.4142C18.7893 18.0391 19 17.5304 19 17V15.656",
245
+ transform: "translate(2 2)"
246
+ }
247
+ ),
248
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { d: "M1 1H12", transform: "translate(9 11)" }),
249
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { d: "M1 9L5 5L1 1", transform: "translate(16 7)" })
250
+ ]
251
+ }
252
+ )
253
+ }
254
+ );
255
+ }
220
256
  function AppleIcon() {
221
257
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
222
258
  "svg",
@@ -318,6 +354,50 @@ function BodyHeader({
318
354
  }
319
355
  BodyHeader.displayName = "BodyHeader";
320
356
 
357
+ // src/components/ui/CdnIcon.tsx
358
+
359
+
360
+ function preconnectIconCdn() {
361
+ if (typeof document === "undefined") return;
362
+ if (document.getElementById("rs-icon-cdn-preconnect")) return;
363
+ const link = document.createElement("link");
364
+ link.id = "rs-icon-cdn-preconnect";
365
+ link.rel = "preconnect";
366
+ link.href = _chunkEGB3NWMLcjs.ICON_CDN;
367
+ link.crossOrigin = "anonymous";
368
+ document.head.appendChild(link);
369
+ }
370
+ preconnectIconCdn();
371
+ function CdnIcon({
372
+ src,
373
+ alt = "",
374
+ className,
375
+ fallback,
376
+ loading = "eager"
377
+ }) {
378
+ const [loadedSrc, setLoadedSrc] = _react.useState.call(void 0, null);
379
+ const [erroredSrc, setErroredSrc] = _react.useState.call(void 0, null);
380
+ if (!src || erroredSrc === src) {
381
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _jsxruntime.Fragment, { children: fallback });
382
+ }
383
+ const isLoading = loadedSrc !== src;
384
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
385
+ "img",
386
+ {
387
+ src,
388
+ alt,
389
+ className: `rs-cdn-icon ${_nullishCoalesce(className, () => ( ""))}`.trimEnd(),
390
+ loading,
391
+ decoding: "async",
392
+ "data-loading": isLoading ? "" : void 0,
393
+ onLoad: () => setLoadedSrc(src),
394
+ onError: () => setErroredSrc(src)
395
+ },
396
+ src
397
+ );
398
+ }
399
+ CdnIcon.displayName = "CdnIcon";
400
+
321
401
  // src/components/ui/PoweredBy.tsx
322
402
 
323
403
  var rhinestoneLogo = /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
@@ -471,37 +551,14 @@ Button.displayName = "Button";
471
551
 
472
552
  // src/components/ui/TokenIcon.tsx
473
553
 
474
-
475
- function preconnectIconCdn() {
476
- if (typeof document === "undefined") return;
477
- if (document.getElementById("rs-icon-cdn-preconnect")) return;
478
- const link = document.createElement("link");
479
- link.id = "rs-icon-cdn-preconnect";
480
- link.rel = "preconnect";
481
- link.href = "https://s3.rhinestone.dev";
482
- link.crossOrigin = "anonymous";
483
- document.head.appendChild(link);
484
- }
485
- preconnectIconCdn();
486
554
  function TokenIcon({ symbol, className, fallback }) {
487
- const [loadedSymbol, setLoadedSymbol] = _react.useState.call(void 0, null);
488
- const [erroredSymbol, setErroredSymbol] = _react.useState.call(void 0, null);
489
- if (erroredSymbol === symbol) {
490
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _jsxruntime.Fragment, { children: fallback });
491
- }
492
- const loading = loadedSymbol !== symbol;
493
555
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
494
- "img",
556
+ CdnIcon,
495
557
  {
496
- src: _chunkA4VMWNDEcjs.tokenIconUrl.call(void 0, symbol),
497
- alt: "",
558
+ src: _chunkEGB3NWMLcjs.tokenIconUrl.call(void 0, symbol),
498
559
  className: `rs-token-icon ${_nullishCoalesce(className, () => ( ""))}`.trimEnd(),
499
- decoding: "async",
500
- "data-loading": loading ? "" : void 0,
501
- onLoad: () => setLoadedSymbol(symbol),
502
- onError: () => setErroredSymbol(symbol)
503
- },
504
- symbol
560
+ fallback
561
+ }
505
562
  );
506
563
  }
507
564
  TokenIcon.displayName = "TokenIcon";
@@ -566,6 +623,16 @@ function debugError(enabled, scope, message, error, data) {
566
623
  function getAssetId(asset) {
567
624
  return `${asset.chainId}:${asset.token.toLowerCase()}`;
568
625
  }
626
+ function chainIdsByValue(tokens) {
627
+ const usdByChain = /* @__PURE__ */ new Map();
628
+ for (const token of tokens) {
629
+ if (typeof token.chainId !== "number") continue;
630
+ const usd = Number.isFinite(token.balanceUsd) ? token.balanceUsd : 0;
631
+ if (usd <= 0) continue;
632
+ usdByChain.set(token.chainId, (_nullishCoalesce(usdByChain.get(token.chainId), () => ( 0))) + usd);
633
+ }
634
+ return [...usdByChain.entries()].sort((a, b) => b[1] - a[1]).map(([chainId]) => chainId);
635
+ }
569
636
  function isEvmAddress(value) {
570
637
  return /^0x[a-fA-F0-9]{40}$/.test(value);
571
638
  }
@@ -607,7 +674,7 @@ function isNativeAsset(asset) {
607
674
  // src/core/deposit-service.ts
608
675
  var SERVICE_HEADERS = {
609
676
  "Content-Type": "application/json",
610
- "x-deposit-modal-version": _chunkA4VMWNDEcjs.MODAL_VERSION
677
+ "x-deposit-modal-version": _chunk7RZPE5KVcjs.MODAL_VERSION
611
678
  };
612
679
  function depositRowToEvent(row) {
613
680
  const status = row.status;
@@ -676,13 +743,6 @@ function normalizeEvmAddress(value) {
676
743
  return value;
677
744
  }
678
745
  }
679
- var RecoverDepositError = class extends Error {
680
- constructor(message, code) {
681
- super(message);
682
- this.name = "RecoverDepositError";
683
- this.code = code;
684
- }
685
- };
686
746
  function createDepositService(baseUrl, options) {
687
747
  const normalizedBaseUrl = baseUrl.replace(/\/$/, "");
688
748
  const debug = _optionalChain([options, 'optionalAccess', _ => _.debug]) === true;
@@ -922,34 +982,6 @@ function createDepositService(baseUrl, options) {
922
982
  });
923
983
  return deposits;
924
984
  },
925
- async recoverDeposit(params) {
926
- const url = apiUrl("/deposits/recover");
927
- debugLog(debug, scope, "recoverDeposit:request", {
928
- chain: params.chain,
929
- account: shortRef(params.account),
930
- recipient: shortRef(params.recipient)
931
- });
932
- const response = await fetch(url, {
933
- method: "POST",
934
- headers: SERVICE_HEADERS,
935
- body: JSON.stringify(params)
936
- });
937
- if (!response.ok) {
938
- const error = await response.json().catch(() => ({ error: "Unknown error" }));
939
- debugError(debug, scope, "recoverDeposit:failed", error, {
940
- status: response.status
941
- });
942
- throw new RecoverDepositError(
943
- error.error || `Recovery failed: ${response.status}`,
944
- error.code
945
- );
946
- }
947
- const result = await response.json();
948
- debugLog(debug, scope, "recoverDeposit:success", {
949
- transactionHash: shortRef(result.transactionHash)
950
- });
951
- return result;
952
- },
953
985
  async fetchLatestStatus(address) {
954
986
  const url = apiUrl(
955
987
  `/deposits?account=${encodeURIComponent(address)}&limit=1`
@@ -1057,7 +1089,7 @@ function createDepositService(baseUrl, options) {
1057
1089
  },
1058
1090
  async checkLiquidity(params) {
1059
1091
  if (params.destinationChainId === "solana") {
1060
- const token = _chunkA4VMWNDEcjs.getSolanaTokenByMint.call(void 0, params.destinationToken);
1092
+ const token = _chunkEGB3NWMLcjs.getSolanaTokenByMint.call(void 0, params.destinationToken);
1061
1093
  return {
1062
1094
  hasLiquidity: true,
1063
1095
  symbol: _nullishCoalesce(_optionalChain([token, 'optionalAccess', _26 => _26.symbol]), () => ( "Token")),
@@ -1114,7 +1146,7 @@ function createDepositService(baseUrl, options) {
1114
1146
  const body = {
1115
1147
  account: params.account,
1116
1148
  // HyperCore has its own CAIP-2 namespace — never the eip155 placeholder.
1117
- sourceChainId: params.sourceChainId === "hypercore" ? _chunkA4VMWNDEcjs.HYPERCORE_MAINNET_CAIP2 : `eip155:${params.sourceChainId}`,
1149
+ sourceChainId: params.sourceChainId === "hypercore" ? _chunkEGB3NWMLcjs.HYPERCORE_MAINNET_CAIP2 : `eip155:${params.sourceChainId}`,
1118
1150
  sourceToken: params.sourceToken,
1119
1151
  amount: params.amount
1120
1152
  };
@@ -1437,14 +1469,14 @@ function normalizeOrchestratorPortfolio(data) {
1437
1469
  const unlocked = _nullishCoalesce(_optionalChain([chainBalance, 'access', _33 => _33.balance, 'optionalAccess', _34 => _34.unlocked]), () => ( "0"));
1438
1470
  const normalizedName = tokenData.tokenName.trim();
1439
1471
  const isNativeSymbol = normalizedName.toUpperCase() === "ETH" || normalizedName.toUpperCase() === "ETHER";
1440
- const tokenAddress = _nullishCoalesce(_nullishCoalesce(chainBalance.tokenAddress, () => ( extractTokenAddress(tokenData, chainBalance.chainId))), () => ( _chunkA4VMWNDEcjs.getTokenAddress.call(void 0, tokenData.tokenName, chainBalance.chainId)));
1441
- const resolvedTokenAddress = isNativeSymbol ? _chunkA4VMWNDEcjs.NATIVE_TOKEN_ADDRESS : tokenAddress;
1472
+ const tokenAddress = _nullishCoalesce(_nullishCoalesce(chainBalance.tokenAddress, () => ( extractTokenAddress(tokenData, chainBalance.chainId))), () => ( _chunkEGB3NWMLcjs.getTokenAddress.call(void 0, tokenData.tokenName, chainBalance.chainId)));
1473
+ const resolvedTokenAddress = isNativeSymbol ? _chunkEGB3NWMLcjs.NATIVE_TOKEN_ADDRESS : tokenAddress;
1442
1474
  if (!resolvedTokenAddress) {
1443
1475
  continue;
1444
1476
  }
1445
- const registrySymbol = _chunkA4VMWNDEcjs.getTokenSymbol.call(void 0, resolvedTokenAddress, chainBalance.chainId);
1477
+ const registrySymbol = _chunkEGB3NWMLcjs.getTokenSymbol.call(void 0, resolvedTokenAddress, chainBalance.chainId);
1446
1478
  const symbol = registrySymbol !== "Token" ? registrySymbol : normalizedName || "Token";
1447
- const decimals = registrySymbol !== "Token" ? _chunkA4VMWNDEcjs.getTokenDecimalsByAddress.call(void 0, resolvedTokenAddress, chainBalance.chainId) : _nullishCoalesce(tokenData.tokenDecimals, () => ( 18));
1479
+ const decimals = registrySymbol !== "Token" ? _chunkEGB3NWMLcjs.getTokenDecimalsByAddress.call(void 0, resolvedTokenAddress, chainBalance.chainId) : _nullishCoalesce(tokenData.tokenDecimals, () => ( 18));
1448
1480
  tokens.push({
1449
1481
  chainId: chainBalance.chainId,
1450
1482
  address: resolvedTokenAddress,
@@ -1464,13 +1496,13 @@ function normalizeOrchestratorPortfolio(data) {
1464
1496
  function normalizeDirectToken(token) {
1465
1497
  const rawChainId = _nullishCoalesce(extractNumber(token, "chainId"), () => ( extractNumber(token.chain, "id")));
1466
1498
  const rawChainString = _nullishCoalesce(extractString(token, "chainId"), () => ( extractString(token.chain, "id")));
1467
- const chainId = _nullishCoalesce(rawChainId, () => ( (rawChainString ? _chunkA4VMWNDEcjs.isSolanaCaip2.call(void 0, rawChainString) || rawChainString.toLowerCase() === "solana" ? "solana" : (
1499
+ const chainId = _nullishCoalesce(rawChainId, () => ( (rawChainString ? _chunkEGB3NWMLcjs.isSolanaCaip2.call(void 0, rawChainString) || rawChainString.toLowerCase() === "solana" ? "solana" : (
1468
1500
  // HyperCore (`hypercore:mainnet`) is a non-EVM source; keep its USDC
1469
1501
  // instead of dropping it as an unparseable chain string.
1470
- _chunkA4VMWNDEcjs.isHyperCoreCaip2.call(void 0, rawChainString) || rawChainString.toLowerCase() === "hypercore" ? "hypercore" : _chunkA4VMWNDEcjs.parseEvmChainId.call(void 0, rawChainString)
1502
+ _chunkEGB3NWMLcjs.isHyperCoreCaip2.call(void 0, rawChainString) || rawChainString.toLowerCase() === "hypercore" ? "hypercore" : _chunkEGB3NWMLcjs.parseEvmChainId.call(void 0, rawChainString)
1471
1503
  ) : null)));
1472
1504
  if (chainId === null) return null;
1473
- const registryChainId = typeof chainId === "number" ? chainId : chainId === "hypercore" ? _chunkA4VMWNDEcjs.HYPERCORE_CHAIN_ID : void 0;
1505
+ const registryChainId = typeof chainId === "number" ? chainId : chainId === "hypercore" ? _chunkEGB3NWMLcjs.HYPERCORE_CHAIN_ID : void 0;
1474
1506
  const symbol = _nullishCoalesce(_nullishCoalesce(_nullishCoalesce(extractString(token, "symbol"), () => ( extractString(token, "tokenSymbol"))), () => ( extractString(token, "tokenName"))), () => ( extractString(token, "name")));
1475
1507
  if (!symbol) return null;
1476
1508
  const balanceValue = _nullishCoalesce(_nullishCoalesce(_nullishCoalesce(_nullishCoalesce(_nullishCoalesce(_nullishCoalesce(_nullishCoalesce(extractString(token, "balance"), () => ( extractString(token, "amount"))), () => ( extractString(token, "value"))), () => ( extractString(token, "rawBalance"))), () => ( _optionalChain([extractNumber, 'call', _35 => _35(token, "balance"), 'optionalAccess', _36 => _36.toString, 'call', _37 => _37()]))), () => ( _optionalChain([extractNumber, 'call', _38 => _38(token, "amount"), 'optionalAccess', _39 => _39.toString, 'call', _40 => _40()]))), () => ( _optionalChain([extractNumber, 'call', _41 => _41(token, "value"), 'optionalAccess', _42 => _42.toString, 'call', _43 => _43()]))), () => ( _optionalChain([extractNumber, 'call', _44 => _44(token, "rawBalance"), 'optionalAccess', _45 => _45.toString, 'call', _46 => _46()])));
@@ -1478,14 +1510,14 @@ function normalizeDirectToken(token) {
1478
1510
  const address = _nullishCoalesce(_nullishCoalesce(_nullishCoalesce(extractString(token, "address"), () => ( extractString(token, "tokenAddress"))), () => ( extractString(
1479
1511
  token.token,
1480
1512
  "address"
1481
- ))), () => ( (registryChainId !== void 0 ? _chunkA4VMWNDEcjs.getTokenAddress.call(void 0, symbol, registryChainId) : void 0)));
1513
+ ))), () => ( (registryChainId !== void 0 ? _chunkEGB3NWMLcjs.getTokenAddress.call(void 0, symbol, registryChainId) : void 0)));
1482
1514
  if (!address) return null;
1483
1515
  const balanceUsd = _nullishCoalesce(_nullishCoalesce(_nullishCoalesce(_nullishCoalesce(_nullishCoalesce(_nullishCoalesce(extractNumber(token, "balanceUsd"), () => ( extractNumber(token, "usdValue"))), () => ( extractNumber(token, "valueUsd"))), () => ( extractNumericString(token, "balanceUsd"))), () => ( extractNumericString(token, "usdValue"))), () => ( extractNumericString(token, "valueUsd"))), () => ( 0));
1484
1516
  const isSolanaToken = chainId === "solana";
1485
- const registrySymbol = isSolanaToken ? "Token" : _chunkA4VMWNDEcjs.getTokenSymbol.call(void 0, address, registryChainId);
1517
+ const registrySymbol = isSolanaToken ? "Token" : _chunkEGB3NWMLcjs.getTokenSymbol.call(void 0, address, registryChainId);
1486
1518
  const resolvedSymbol = isSolanaToken ? symbol : registrySymbol !== "Token" ? registrySymbol : symbol;
1487
1519
  const backendDecimals = _nullishCoalesce(extractNumber(token, "decimals"), () => ( extractNumber(token, "tokenDecimals")));
1488
- const resolvedDecimals = !isSolanaToken && registrySymbol !== "Token" ? _chunkA4VMWNDEcjs.getTokenDecimalsByAddress.call(void 0, address, registryChainId) : _nullishCoalesce(backendDecimals, () => ( 18));
1520
+ const resolvedDecimals = !isSolanaToken && registrySymbol !== "Token" ? _chunkEGB3NWMLcjs.getTokenDecimalsByAddress.call(void 0, address, registryChainId) : _nullishCoalesce(backendDecimals, () => ( 18));
1489
1521
  return {
1490
1522
  chainId,
1491
1523
  address,
@@ -1618,18 +1650,18 @@ var EVM_ADDRESS_RE = /^0x[a-fA-F0-9]{40}$/;
1618
1650
  function resolveTokenDisplay(token, chain, fallback) {
1619
1651
  if (token !== void 0) {
1620
1652
  if (chain === "solana") {
1621
- const solanaToken = _chunkA4VMWNDEcjs.getSolanaTokenByMint.call(void 0, token);
1653
+ const solanaToken = _chunkEGB3NWMLcjs.getSolanaTokenByMint.call(void 0, token);
1622
1654
  if (solanaToken) {
1623
1655
  return { symbol: solanaToken.symbol, decimals: solanaToken.decimals };
1624
1656
  }
1625
1657
  } else if (chain === "hypercore") {
1626
- const t = _chunkA4VMWNDEcjs.HYPERCORE_SOURCE_TOKENS.find(
1658
+ const t = _chunkEGB3NWMLcjs.HYPERCORE_SOURCE_TOKENS.find(
1627
1659
  (x) => x.address.toLowerCase() === token.toLowerCase()
1628
1660
  );
1629
1661
  if (t) return { symbol: t.symbol, decimals: t.decimals };
1630
1662
  } else if (EVM_ADDRESS_RE.test(token)) {
1631
- const symbol = _chunkA4VMWNDEcjs.getTokenSymbol.call(void 0, token, chain);
1632
- const decimals = _chunkA4VMWNDEcjs.findTokenDecimals.call(void 0, token, chain);
1663
+ const symbol = _chunkEGB3NWMLcjs.getTokenSymbol.call(void 0, token, chain);
1664
+ const decimals = _chunkEGB3NWMLcjs.findTokenDecimals.call(void 0, token, chain);
1633
1665
  if (symbol !== "Token" || decimals !== void 0) {
1634
1666
  return {
1635
1667
  symbol: symbol !== "Token" ? symbol : _nullishCoalesce(_optionalChain([fallback, 'optionalAccess', _54 => _54.symbol]), () => ( symbol)),
@@ -1678,13 +1710,13 @@ function priceUsdFor(symbol, prices) {
1678
1710
  }
1679
1711
  function isRecognizedToken(address, chain) {
1680
1712
  if (address === void 0 || chain === void 0) return false;
1681
- if (chain === "solana") return _chunkA4VMWNDEcjs.getSolanaTokenByMint.call(void 0, address) !== void 0;
1713
+ if (chain === "solana") return _chunkEGB3NWMLcjs.getSolanaTokenByMint.call(void 0, address) !== void 0;
1682
1714
  if (chain === "hypercore") {
1683
- return _chunkA4VMWNDEcjs.HYPERCORE_SOURCE_TOKENS.some(
1715
+ return _chunkEGB3NWMLcjs.HYPERCORE_SOURCE_TOKENS.some(
1684
1716
  (t) => t.address.toLowerCase() === address.toLowerCase()
1685
1717
  );
1686
1718
  }
1687
- return EVM_ADDRESS_RE.test(address) && _chunkA4VMWNDEcjs.isRegistryTokenOnChain.call(void 0, address, chain);
1719
+ return EVM_ADDRESS_RE.test(address) && _chunkEGB3NWMLcjs.isRegistryTokenOnChain.call(void 0, address, chain);
1688
1720
  }
1689
1721
  function estimateReceiveAmount(params) {
1690
1722
  const {
@@ -1971,4 +2003,6 @@ function applyTheme(element, theme) {
1971
2003
 
1972
2004
 
1973
2005
 
1974
- exports.Modal = Modal; exports.WalletIcon = WalletIcon; exports.ExternalLinkIcon = ExternalLinkIcon; exports.CheckIcon = CheckIcon; exports.TransferCryptoIcon = TransferCryptoIcon; exports.ChevronRightIcon = ChevronRightIcon; exports.ChevronLeftIcon = ChevronLeftIcon; exports.ChevronDownIcon = ChevronDownIcon; exports.CloseIcon = CloseIcon; exports.HandCoinsIcon = HandCoinsIcon; exports.CoinsIcon = CoinsIcon; exports.HistoryIcon = HistoryIcon; exports.InfoIcon = InfoIcon; exports.CopyIcon = CopyIcon; exports.ArrowUpRightIcon = ArrowUpRightIcon; exports.AlertTriangleIcon = AlertTriangleIcon; exports.PercentIcon = PercentIcon; exports.ClockIcon = ClockIcon; exports.PlusCircleIcon = PlusCircleIcon; exports.CircleArrowOutUpLeftIcon = CircleArrowOutUpLeftIcon; exports.CardIcon = CardIcon; exports.BankIcon = BankIcon; exports.UnplugIcon = UnplugIcon; exports.AppleIcon = AppleIcon; exports.Callout = Callout; exports.BodyHeader = BodyHeader; exports.PoweredBy = PoweredBy; exports.Spinner = Spinner; exports.useLatestRef = useLatestRef; exports.Button = Button; exports.TokenIcon = TokenIcon; exports.debugLog = debugLog; exports.debugError = debugError; exports.getAssetId = getAssetId; exports.portfolioToAssets = portfolioToAssets; exports.isNativeAsset = isNativeAsset; exports.RecoverDepositError = RecoverDepositError; exports.createDepositService = createDepositService; exports.currencyFormatter = currencyFormatter; exports.tokenFormatter = tokenFormatter; exports.isUnsupportedChainSwitchError = isUnsupportedChainSwitchError; exports.formatUserError = formatUserError; exports.resolveTokenDisplay = resolveTokenDisplay; exports.formatTokenAmount = formatTokenAmount; exports.tokenAmountToNumber = tokenAmountToNumber; exports.formatRawTokenAmount = formatRawTokenAmount; exports.isDisplayStablecoinSymbol = isDisplayStablecoinSymbol; exports.isRecognizedToken = isRecognizedToken; exports.estimateReceiveAmount = estimateReceiveAmount; exports.formatQuotedReceive = formatQuotedReceive; exports.formatReceiveEstimate = formatReceiveEstimate; exports.rpcUrlFor = rpcUrlFor; exports.RpcUrlsProvider = RpcUrlsProvider; exports.useRpcUrls = useRpcUrls; exports.useStableRpcUrls = useStableRpcUrls; exports.applyTheme = applyTheme;
2006
+
2007
+
2008
+ exports.Modal = Modal; exports.WalletIcon = WalletIcon; exports.ExternalLinkIcon = ExternalLinkIcon; exports.CheckIcon = CheckIcon; exports.TransferCryptoIcon = TransferCryptoIcon; exports.ChevronRightIcon = ChevronRightIcon; exports.ChevronLeftIcon = ChevronLeftIcon; exports.ChevronDownIcon = ChevronDownIcon; exports.CloseIcon = CloseIcon; exports.HandCoinsIcon = HandCoinsIcon; exports.CoinsIcon = CoinsIcon; exports.HistoryIcon = HistoryIcon; exports.InfoIcon = InfoIcon; exports.CopyIcon = CopyIcon; exports.ArrowUpRightIcon = ArrowUpRightIcon; exports.AlertTriangleIcon = AlertTriangleIcon; exports.PercentIcon = PercentIcon; exports.ClockIcon = ClockIcon; exports.PlusCircleIcon = PlusCircleIcon; exports.CircleArrowOutUpLeftIcon = CircleArrowOutUpLeftIcon; exports.CardIcon = CardIcon; exports.BankIcon = BankIcon; exports.UnplugIcon = UnplugIcon; exports.MigrateAssetsIcon = MigrateAssetsIcon; exports.AppleIcon = AppleIcon; exports.Callout = Callout; exports.BodyHeader = BodyHeader; exports.CdnIcon = CdnIcon; exports.PoweredBy = PoweredBy; exports.Spinner = Spinner; exports.useLatestRef = useLatestRef; exports.Button = Button; exports.TokenIcon = TokenIcon; exports.debugLog = debugLog; exports.debugError = debugError; exports.getAssetId = getAssetId; exports.chainIdsByValue = chainIdsByValue; exports.portfolioToAssets = portfolioToAssets; exports.isNativeAsset = isNativeAsset; exports.createDepositService = createDepositService; exports.currencyFormatter = currencyFormatter; exports.tokenFormatter = tokenFormatter; exports.isUnsupportedChainSwitchError = isUnsupportedChainSwitchError; exports.formatUserError = formatUserError; exports.resolveTokenDisplay = resolveTokenDisplay; exports.formatTokenAmount = formatTokenAmount; exports.tokenAmountToNumber = tokenAmountToNumber; exports.formatRawTokenAmount = formatRawTokenAmount; exports.isDisplayStablecoinSymbol = isDisplayStablecoinSymbol; exports.isRecognizedToken = isRecognizedToken; exports.estimateReceiveAmount = estimateReceiveAmount; exports.formatQuotedReceive = formatQuotedReceive; exports.formatReceiveEstimate = formatReceiveEstimate; exports.rpcUrlFor = rpcUrlFor; exports.RpcUrlsProvider = RpcUrlsProvider; exports.useRpcUrls = useRpcUrls; exports.useStableRpcUrls = useStableRpcUrls; exports.applyTheme = applyTheme;