@rhinestone/deposit-modal 0.12.2 → 0.14.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 (68) hide show
  1. package/README.md +73 -18
  2. package/bridge-transcript.json +653 -0
  3. package/dist/ClaimModal-IKTJU43Y.cjs +13 -0
  4. package/dist/ClaimModal-SEKNWRMA.mjs +13 -0
  5. package/dist/{DepositModalReown-VG66OTIU.cjs → DepositModalReown-46LPVFB6.cjs} +58 -35
  6. package/dist/{DepositModalReown-TEC3MEZ4.mjs → DepositModalReown-Q2JMLT47.mjs} +45 -22
  7. package/dist/{QRCode-WUC652SH.mjs → QRCode-5RGIZZHL.mjs} +1 -1
  8. package/dist/{QRCode-5DXFNKI2.cjs → QRCode-JKXG4RHN.cjs} +2 -2
  9. package/dist/WithdrawModal-5ICGD4HJ.mjs +12 -0
  10. package/dist/WithdrawModal-VP6PMIRO.cjs +12 -0
  11. package/dist/{chunk-O7BCVQ6L.cjs → chunk-4KCSH4T3.cjs} +157 -199
  12. package/dist/chunk-6KG642KH.cjs +31 -0
  13. package/dist/{chunk-PWLEBV5V.cjs → chunk-7ICSHJFE.cjs} +296 -220
  14. package/dist/{chunk-J46WDSRD.mjs → chunk-7SR7ENVJ.mjs} +165 -89
  15. package/dist/{chunk-2TPSF77V.mjs → chunk-CFKC77SV.mjs} +455 -261
  16. package/dist/{chunk-75DVGSAX.cjs → chunk-DW2EQA2U.cjs} +6 -3
  17. package/dist/{chunk-FXXUIK4E.mjs → chunk-IN77XSWO.mjs} +899 -153
  18. package/dist/chunk-K4H6TGBE.mjs +31 -0
  19. package/dist/{chunk-SDSKIJC7.mjs → chunk-KTUVSKR4.mjs} +2410 -1177
  20. package/dist/{chunk-HL5NUKZW.cjs → chunk-LZFRL2AL.cjs} +3 -3
  21. package/dist/{chunk-UQIJU6HV.cjs → chunk-MTFJSE52.cjs} +499 -191
  22. package/dist/{chunk-FLVLYO64.mjs → chunk-PKML3XVS.mjs} +430 -122
  23. package/dist/{chunk-4ZXQPFNU.mjs → chunk-RN5VKWI6.mjs} +4 -1
  24. package/dist/{chunk-BRYNGLDM.cjs → chunk-V2OBGLJD.cjs} +961 -215
  25. package/dist/{chunk-3STTWRAN.mjs → chunk-VUATPOWJ.mjs} +147 -189
  26. package/dist/{chunk-JE4R5VA3.mjs → chunk-WUJIKCFU.mjs} +1 -1
  27. package/dist/chunk-X2IPAPXU.cjs +163 -0
  28. package/dist/{chunk-OIN4CXCP.cjs → chunk-YCQZJQO6.cjs} +2343 -1110
  29. package/dist/{chunk-TM7VGHAG.cjs → chunk-YWMWI7PZ.cjs} +462 -268
  30. package/dist/chunk-ZEO6ADM3.mjs +163 -0
  31. package/dist/claim.cjs +7 -6
  32. package/dist/claim.d.cts +11 -3
  33. package/dist/claim.d.ts +11 -3
  34. package/dist/claim.mjs +6 -5
  35. package/dist/{constants-FuzG3h4m.d.cts → constants-DBrWhJWE.d.cts} +12 -7
  36. package/dist/{constants-FuzG3h4m.d.ts → constants-DBrWhJWE.d.ts} +12 -7
  37. package/dist/constants.cjs +3 -9
  38. package/dist/constants.d.cts +2 -3
  39. package/dist/constants.d.ts +2 -3
  40. package/dist/constants.mjs +4 -10
  41. package/dist/deposit.cjs +8 -8
  42. package/dist/deposit.d.cts +2 -2
  43. package/dist/deposit.d.ts +2 -2
  44. package/dist/deposit.mjs +7 -7
  45. package/dist/embed.cjs +1476 -0
  46. package/dist/embed.d.cts +183 -0
  47. package/dist/embed.d.ts +183 -0
  48. package/dist/embed.mjs +1476 -0
  49. package/dist/index.cjs +11 -16
  50. package/dist/index.d.cts +3 -3
  51. package/dist/index.d.ts +3 -3
  52. package/dist/index.mjs +14 -19
  53. package/dist/modal-ui-state-OD1RmKkK.d.cts +30 -0
  54. package/dist/modal-ui-state-OD1RmKkK.d.ts +30 -0
  55. package/dist/polymarket.cjs +17 -7
  56. package/dist/polymarket.mjs +13 -3
  57. package/dist/styles.css +124 -98
  58. package/dist/types-Bho4OA03.d.ts +982 -0
  59. package/dist/types-DP_3KwlD.d.cts +982 -0
  60. package/dist/withdraw.cjs +6 -6
  61. package/dist/withdraw.d.cts +11 -3
  62. package/dist/withdraw.d.ts +11 -3
  63. package/dist/withdraw.mjs +5 -5
  64. package/package.json +59 -6
  65. package/dist/chunk-IAGFDSNC.mjs +0 -11
  66. package/dist/chunk-L32UI7LA.cjs +0 -11
  67. package/dist/types-BO4iP6fG.d.cts +0 -612
  68. package/dist/types-oFblf65g.d.ts +0 -612
package/dist/withdraw.cjs CHANGED
@@ -1,10 +1,10 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _chunkUQIJU6HVcjs = require('./chunk-UQIJU6HV.cjs');
4
- require('./chunk-PWLEBV5V.cjs');
5
- require('./chunk-BRYNGLDM.cjs');
6
- require('./chunk-L32UI7LA.cjs');
7
- require('./chunk-O7BCVQ6L.cjs');
3
+ var _chunkMTFJSE52cjs = require('./chunk-MTFJSE52.cjs');
4
+ require('./chunk-7ICSHJFE.cjs');
5
+ require('./chunk-V2OBGLJD.cjs');
6
+ require('./chunk-6KG642KH.cjs');
7
+ require('./chunk-4KCSH4T3.cjs');
8
8
 
9
9
 
10
- exports.WithdrawModal = _chunkUQIJU6HVcjs.WithdrawModal;
10
+ exports.WithdrawModal = _chunkMTFJSE52cjs.WithdrawModal;
@@ -1,9 +1,17 @@
1
1
  import * as react from 'react';
2
- import { p as WithdrawModalProps } from './types-BO4iP6fG.cjs';
3
- export { a as AssetOption, e as ConnectedEventData, E as ErrorEventData, R as RpcUrlMap, m as WithdrawCompleteEventData, n as WithdrawFailedEventData, q as WithdrawSubmittedEventData, r as WithdrawTransferRequest } from './types-BO4iP6fG.cjs';
2
+ import { a9 as WithdrawModalProps } from './types-DP_3KwlD.cjs';
3
+ export { A as AnalyticsEventEnvelope, a as AnalyticsIngestFailureEvent, b as AnalyticsIngestFailureReason, c as AnalyticsReasonFamily, e as AssetOption, p as ConnectedEventData, V as ErrorEventData, Z as RpcUrlMap, _ as WithdrawAnalyticsAbandonmentReason, $ as WithdrawAnalyticsCloseSource, a0 as WithdrawAnalyticsEvent, a1 as WithdrawAnalyticsEventPayload, a2 as WithdrawAnalyticsFailureReason, a3 as WithdrawAnalyticsSessionProperties, a4 as WithdrawAnalyticsStep, a5 as WithdrawAnalyticsUiOutcome, a6 as WithdrawCompleteEventData, a7 as WithdrawFailedEventData, aa as WithdrawSubmittedEventData, ab as WithdrawTransferRequest } from './types-DP_3KwlD.cjs';
4
+ import { M as ModalUiState } from './modal-ui-state-OD1RmKkK.cjs';
4
5
  import 'viem';
5
6
  import './caip-D8aRWdEY.cjs';
6
7
 
7
- declare function WithdrawModal({ accountAddress, sourceChain: sourceChainProp, sourceToken, targetChain: targetChainProp, targetToken, recipient, defaultAmount, isOpen, onClose, inline, closeOnOverlayClick, backendUrl, rpcUrls: rpcUrlsProp, forceRegister, onSendTransaction, theme, uiConfig, className, onReady, onLifecycle, onEvent, onError, debug, ...removedProps }: WithdrawModalProps): react.JSX.Element;
8
+ /**
9
+ * Not part of `WithdrawModalProps`: the native embed is the only consumer, and
10
+ * a published prop is immediately someone else's import.
11
+ */
12
+ interface WithdrawModalInternalProps {
13
+ onUiState?: (state: ModalUiState) => void;
14
+ }
15
+ declare function WithdrawModal({ accountAddress, sourceChain: sourceChainProp, sourceToken, targetChain: targetChainProp, targetToken, recipient, defaultAmount, isOpen, onClose, inline, closeOnOverlayClick, backendUrl, rpcUrls: rpcUrlsProp, forceRegister, onSendTransaction, theme, uiConfig, className, onReady, onLifecycle, onEvent, onError, enableAnalyticsIngest, analyticsIngestUrl, debug, onUiState, ...removedProps }: WithdrawModalProps & WithdrawModalInternalProps): react.JSX.Element;
8
16
 
9
17
  export { WithdrawModal, WithdrawModalProps };
@@ -1,9 +1,17 @@
1
1
  import * as react from 'react';
2
- import { p as WithdrawModalProps } from './types-oFblf65g.js';
3
- export { a as AssetOption, e as ConnectedEventData, E as ErrorEventData, R as RpcUrlMap, m as WithdrawCompleteEventData, n as WithdrawFailedEventData, q as WithdrawSubmittedEventData, r as WithdrawTransferRequest } from './types-oFblf65g.js';
2
+ import { a9 as WithdrawModalProps } from './types-Bho4OA03.js';
3
+ export { A as AnalyticsEventEnvelope, a as AnalyticsIngestFailureEvent, b as AnalyticsIngestFailureReason, c as AnalyticsReasonFamily, e as AssetOption, p as ConnectedEventData, V as ErrorEventData, Z as RpcUrlMap, _ as WithdrawAnalyticsAbandonmentReason, $ as WithdrawAnalyticsCloseSource, a0 as WithdrawAnalyticsEvent, a1 as WithdrawAnalyticsEventPayload, a2 as WithdrawAnalyticsFailureReason, a3 as WithdrawAnalyticsSessionProperties, a4 as WithdrawAnalyticsStep, a5 as WithdrawAnalyticsUiOutcome, a6 as WithdrawCompleteEventData, a7 as WithdrawFailedEventData, aa as WithdrawSubmittedEventData, ab as WithdrawTransferRequest } from './types-Bho4OA03.js';
4
+ import { M as ModalUiState } from './modal-ui-state-OD1RmKkK.js';
4
5
  import 'viem';
5
6
  import './caip-D8aRWdEY.js';
6
7
 
7
- declare function WithdrawModal({ accountAddress, sourceChain: sourceChainProp, sourceToken, targetChain: targetChainProp, targetToken, recipient, defaultAmount, isOpen, onClose, inline, closeOnOverlayClick, backendUrl, rpcUrls: rpcUrlsProp, forceRegister, onSendTransaction, theme, uiConfig, className, onReady, onLifecycle, onEvent, onError, debug, ...removedProps }: WithdrawModalProps): react.JSX.Element;
8
+ /**
9
+ * Not part of `WithdrawModalProps`: the native embed is the only consumer, and
10
+ * a published prop is immediately someone else's import.
11
+ */
12
+ interface WithdrawModalInternalProps {
13
+ onUiState?: (state: ModalUiState) => void;
14
+ }
15
+ declare function WithdrawModal({ accountAddress, sourceChain: sourceChainProp, sourceToken, targetChain: targetChainProp, targetToken, recipient, defaultAmount, isOpen, onClose, inline, closeOnOverlayClick, backendUrl, rpcUrls: rpcUrlsProp, forceRegister, onSendTransaction, theme, uiConfig, className, onReady, onLifecycle, onEvent, onError, enableAnalyticsIngest, analyticsIngestUrl, debug, onUiState, ...removedProps }: WithdrawModalProps & WithdrawModalInternalProps): react.JSX.Element;
8
16
 
9
17
  export { WithdrawModal, WithdrawModalProps };
package/dist/withdraw.mjs CHANGED
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  WithdrawModal
3
- } from "./chunk-FLVLYO64.mjs";
4
- import "./chunk-J46WDSRD.mjs";
5
- import "./chunk-FXXUIK4E.mjs";
6
- import "./chunk-IAGFDSNC.mjs";
7
- import "./chunk-3STTWRAN.mjs";
3
+ } from "./chunk-PKML3XVS.mjs";
4
+ import "./chunk-7SR7ENVJ.mjs";
5
+ import "./chunk-IN77XSWO.mjs";
6
+ import "./chunk-K4H6TGBE.mjs";
7
+ import "./chunk-VUATPOWJ.mjs";
8
8
  export {
9
9
  WithdrawModal
10
10
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rhinestone/deposit-modal",
3
- "version": "0.12.2",
3
+ "version": "0.14.0",
4
4
  "description": "React modal component for Rhinestone cross-chain deposits",
5
5
  "author": "Rhinestone <dev@rhinestone.wtf>",
6
6
  "bugs": {
@@ -51,6 +51,16 @@
51
51
  "default": "./dist/claim.cjs"
52
52
  }
53
53
  },
54
+ "./embed": {
55
+ "import": {
56
+ "types": "./dist/embed.d.ts",
57
+ "default": "./dist/embed.mjs"
58
+ },
59
+ "require": {
60
+ "types": "./dist/embed.d.cts",
61
+ "default": "./dist/embed.cjs"
62
+ }
63
+ },
54
64
  "./server": {
55
65
  "import": {
56
66
  "types": "./dist/server.d.ts",
@@ -79,10 +89,12 @@
79
89
  "./styles.css": {
80
90
  "types": "./dist/styles.d.ts",
81
91
  "default": "./dist/styles.css"
82
- }
92
+ },
93
+ "./bridge-transcript.json": "./bridge-transcript.json"
83
94
  },
84
95
  "files": [
85
96
  "dist",
97
+ "bridge-transcript.json",
86
98
  "README.md"
87
99
  ],
88
100
  "sideEffects": [
@@ -91,6 +103,8 @@
91
103
  "scripts": {
92
104
  "size": "size-limit",
93
105
  "build": "bun run scripts/sync-version.ts && tsup && bun run scripts/postbuild.ts",
106
+ "build:embed": "vite build --config embed-page/vite.config.ts",
107
+ "size:bundles": "bun run scripts/check-bundles.ts",
94
108
  "clean": "rm -rf dist",
95
109
  "typecheck": "tsc --noEmit",
96
110
  "test": "vitest run",
@@ -158,7 +172,8 @@
158
172
  "size-limit": "^12.0.0",
159
173
  "tsup": "^8.0.0",
160
174
  "typescript": "^5.5.0",
161
- "viem": "^2.53.1",
175
+ "viem": ">=2.53.1 <2.56.0",
176
+ "vite": "^8.1.4",
162
177
  "vitest": "^4.0.10",
163
178
  "wagmi": "^3.6.18"
164
179
  },
@@ -166,7 +181,26 @@
166
181
  {
167
182
  "name": "Total Bundle (Everything)",
168
183
  "path": "dist/index.mjs",
169
- "limit": "88 kB",
184
+ "limit": "92.9 kB",
185
+ "ignore": [
186
+ "react",
187
+ "react-dom",
188
+ "viem",
189
+ "wagmi",
190
+ "@tanstack/react-query",
191
+ "@reown/appkit",
192
+ "@reown/appkit-adapter-wagmi",
193
+ "@walletconnect/ethereum-provider",
194
+ "@coinbase/wallet-sdk",
195
+ "@metamask/sdk",
196
+ "porto",
197
+ "porto/internal"
198
+ ]
199
+ },
200
+ {
201
+ "name": "Native Embed (all three modes)",
202
+ "path": "dist/embed.mjs",
203
+ "limit": "99.2 kB",
170
204
  "ignore": [
171
205
  "react",
172
206
  "react-dom",
@@ -186,7 +220,26 @@
186
220
  "name": "Deposit & Withdraw Modals Only",
187
221
  "path": "dist/index.mjs",
188
222
  "import": "{ DepositModal, WithdrawModal }",
189
- "limit": "84 kB",
223
+ "limit": "88.3 kB",
224
+ "ignore": [
225
+ "react",
226
+ "react-dom",
227
+ "viem",
228
+ "wagmi",
229
+ "@tanstack/react-query",
230
+ "@reown/appkit",
231
+ "@reown/appkit-adapter-wagmi",
232
+ "@walletconnect/ethereum-provider",
233
+ "@coinbase/wallet-sdk",
234
+ "@metamask/sdk",
235
+ "porto",
236
+ "porto/internal"
237
+ ]
238
+ },
239
+ {
240
+ "name": "Withdraw Modal Only",
241
+ "path": "dist/withdraw.mjs",
242
+ "limit": "35.5 kB",
190
243
  "ignore": [
191
244
  "react",
192
245
  "react-dom",
@@ -214,7 +267,7 @@
214
267
  "name": "Claim Modal Only",
215
268
  "path": "dist/claim.mjs",
216
269
  "import": "{ ClaimModal }",
217
- "limit": "24 kB",
270
+ "limit": "25.6 kB",
218
271
  "ignore": [
219
272
  "react",
220
273
  "react-dom",
@@ -1,11 +0,0 @@
1
- // src/core/version.ts
2
- var MODAL_VERSION = "0.12.2";
3
- var SERVICE_HEADERS = {
4
- "Content-Type": "application/json",
5
- "x-deposit-modal-version": MODAL_VERSION
6
- };
7
-
8
- export {
9
- MODAL_VERSION,
10
- SERVICE_HEADERS
11
- };
@@ -1,11 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});// src/core/version.ts
2
- var MODAL_VERSION = "0.12.2";
3
- var SERVICE_HEADERS = {
4
- "Content-Type": "application/json",
5
- "x-deposit-modal-version": MODAL_VERSION
6
- };
7
-
8
-
9
-
10
-
11
- exports.MODAL_VERSION = MODAL_VERSION; exports.SERVICE_HEADERS = SERVICE_HEADERS;