@rhinestone/deposit-modal 0.19.0 → 0.20.1

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 (83) hide show
  1. package/README.md +154 -61
  2. package/dist/BankOnrampStep-3SNUX6V2.cjs +435 -0
  3. package/dist/BankOnrampStep-4D24HVHV.mjs +435 -0
  4. package/dist/{DepositModalReown-UITYXJ6W.cjs → DepositModalReown-7EHOJTFW.cjs} +21 -20
  5. package/dist/{DepositModalReown-XBNY6QCI.mjs → DepositModalReown-SYQ2SCHC.mjs} +6 -5
  6. package/dist/WithdrawModal-LLJLEYXZ.cjs +12 -0
  7. package/dist/WithdrawModal-LXDIT4UV.mjs +12 -0
  8. package/dist/{bearer-transport-CVHNBgoV.d.cts → bearer-transport-DZyeDG64.d.cts} +5 -1
  9. package/dist/{bearer-transport-CVHNBgoV.d.ts → bearer-transport-DZyeDG64.d.ts} +5 -1
  10. package/dist/{caip-BMi-9t09.d.cts → caip-nwFFL46o.d.cts} +2 -2
  11. package/dist/{caip-BMi-9t09.d.ts → caip-nwFFL46o.d.ts} +2 -2
  12. package/dist/{chunk-FTWKAJGN.mjs → chunk-2FOPO4N5.mjs} +1 -1
  13. package/dist/{chunk-EG4H7OMC.cjs → chunk-CIVFT5KR.cjs} +171 -130
  14. package/dist/{chunk-PYOC6K24.cjs → chunk-D3R3O4CY.cjs} +1 -1
  15. package/dist/chunk-E7IMWVMN.mjs +346 -0
  16. package/dist/chunk-EJDBIWNH.mjs +113 -0
  17. package/dist/chunk-FKJ6EJHH.cjs +346 -0
  18. package/dist/{chunk-LVCD6RHF.cjs → chunk-FVJKUTHF.cjs} +2 -2
  19. package/dist/{chunk-NITKDXHR.mjs → chunk-FW7ZMXQS.mjs} +849 -674
  20. package/dist/chunk-G264OM23.cjs +224 -0
  21. package/dist/chunk-IPHKBBUV.cjs +113 -0
  22. package/dist/{chunk-BIL4ENC3.mjs → chunk-IPKT3FU6.mjs} +73 -32
  23. package/dist/chunk-JPX4MEHV.mjs +19 -0
  24. package/dist/{chunk-HMUGY66O.cjs → chunk-KXSU24RU.cjs} +1569 -1019
  25. package/dist/{chunk-ISLVD5HQ.cjs → chunk-LVMNNMOZ.cjs} +10 -5
  26. package/dist/chunk-O5OW4S7L.cjs +19 -0
  27. package/dist/{chunk-5NWLS5BQ.mjs → chunk-OZPMRTW3.mjs} +1511 -961
  28. package/dist/{chunk-OCWSMLOP.cjs → chunk-PVFEZ3UG.cjs} +1164 -989
  29. package/dist/{chunk-ZGHVJ2XM.mjs → chunk-YQCRXJIL.mjs} +8 -3
  30. package/dist/chunk-YY4ZOAH5.mjs +224 -0
  31. package/dist/{chunk-X6N2XPTO.mjs → chunk-ZOJMB5TZ.mjs} +1 -1
  32. package/dist/compliance.cjs +4 -7
  33. package/dist/compliance.d.cts +26 -3
  34. package/dist/compliance.d.ts +26 -3
  35. package/dist/compliance.mjs +6 -9
  36. package/dist/constants-BQDxVNgr.d.cts +29 -0
  37. package/dist/constants-DjGQW5N5.d.ts +29 -0
  38. package/dist/constants.cjs +3 -37
  39. package/dist/constants.d.cts +4 -20
  40. package/dist/constants.d.ts +4 -20
  41. package/dist/constants.mjs +4 -38
  42. package/dist/deposit.cjs +7 -6
  43. package/dist/deposit.d.cts +5 -3
  44. package/dist/deposit.d.ts +5 -3
  45. package/dist/deposit.mjs +6 -5
  46. package/dist/embed.cjs +21 -20
  47. package/dist/embed.d.cts +3 -2
  48. package/dist/embed.d.ts +3 -2
  49. package/dist/embed.mjs +7 -6
  50. package/dist/index.cjs +8 -35
  51. package/dist/index.d.cts +5 -3
  52. package/dist/index.d.ts +5 -3
  53. package/dist/index.mjs +9 -36
  54. package/dist/onramp.cjs +4 -33
  55. package/dist/onramp.d.cts +51 -33
  56. package/dist/onramp.d.ts +51 -33
  57. package/dist/onramp.mjs +5 -34
  58. package/dist/polymarket.cjs +6 -6
  59. package/dist/polymarket.mjs +2 -2
  60. package/dist/ramp-types-HYWd7CW0.d.cts +108 -0
  61. package/dist/ramp-types-HYWd7CW0.d.ts +108 -0
  62. package/dist/styles.css +255 -0
  63. package/dist/{types-BOxa1DE-.d.ts → types-BEEMfNi2.d.cts} +24 -4
  64. package/dist/{types-BShYNpvO.d.cts → types-DQDUqzsZ.d.ts} +24 -4
  65. package/dist/withdraw.cjs +6 -5
  66. package/dist/withdraw.d.cts +4 -3
  67. package/dist/withdraw.d.ts +4 -3
  68. package/dist/withdraw.mjs +5 -4
  69. package/package.json +9 -17
  70. package/dist/WithdrawModal-DY6A55OA.mjs +0 -11
  71. package/dist/WithdrawModal-V42OK7L3.cjs +0 -11
  72. package/dist/chunk-ADEWTBSN.cjs +0 -19
  73. package/dist/chunk-EAGMY3QE.mjs +0 -962
  74. package/dist/chunk-OY5N3E6L.cjs +0 -962
  75. package/dist/chunk-PP4QE32S.mjs +0 -19
  76. package/dist/constants-BT4ctuHo.d.cts +0 -64
  77. package/dist/constants-D21ZdNOP.d.ts +0 -64
  78. package/dist/offramp.cjs +0 -25
  79. package/dist/offramp.d.cts +0 -28
  80. package/dist/offramp.d.ts +0 -28
  81. package/dist/offramp.mjs +0 -25
  82. package/dist/ramp-types-C6aUz4SZ.d.cts +0 -43
  83. package/dist/ramp-types-C6aUz4SZ.d.ts +0 -43
package/dist/styles.css CHANGED
@@ -2658,6 +2658,28 @@
2658
2658
  animation: rs-token-icon-pulse 1.2s ease-in-out infinite;
2659
2659
  }
2660
2660
 
2661
+ .rs-token-icon--pending {
2662
+ display: inline-block;
2663
+ width: 100%;
2664
+ height: 100%;
2665
+ border-radius: 50%;
2666
+ }
2667
+
2668
+ /* Text badge for a token with no hosted logo; fills whatever slot holds it. */
2669
+ .rs-token-initials {
2670
+ display: flex;
2671
+ align-items: center;
2672
+ justify-content: center;
2673
+ width: 100%;
2674
+ height: 100%;
2675
+ border-radius: 50%;
2676
+ background-color: var(--rs-border-surface);
2677
+ color: var(--rs-muted-foreground);
2678
+ font-size: 9px;
2679
+ font-weight: 600;
2680
+ line-height: 1;
2681
+ }
2682
+
2661
2683
  @keyframes rs-token-icon-pulse {
2662
2684
  0%,
2663
2685
  100% {
@@ -4409,6 +4431,11 @@
4409
4431
  color: var(--rs-muted);
4410
4432
  }
4411
4433
 
4434
+ /* The overlap is for the chain badge; without one the label needs the room. */
4435
+ .rs-history-card-token:last-child {
4436
+ margin-right: 0;
4437
+ }
4438
+
4412
4439
  .rs-history-card-token img {
4413
4440
  width: 100%;
4414
4441
  height: 100%;
@@ -5143,6 +5170,219 @@
5143
5170
  Fiat On-Ramp (Swapped iframe flow)
5144
5171
  ============================================================================= */
5145
5172
 
5173
+ /* =============================================================================
5174
+ Hosted-frame sizing.
5175
+
5176
+ Noah's hosted views are a provider surface carrying a form and a QR code,
5177
+ and at the default size the customer scrolls a ~420px box to reach either.
5178
+ These rules give them the same treatment the Swapped iframe already gets:
5179
+ span the modal and grow with the viewport rather than scroll inside it.
5180
+
5181
+ Every rule is scoped to `:has(.rs-bank-onramp-hosted)` — i.e. only while a
5182
+ frame is actually mounted. The currency picker is a three-row list, and a
5183
+ tall floor there would leave dead space under it, which is the same reason
5184
+ the Swapped rules exclude their tracker phase.
5185
+
5186
+ The modal's own `max-height` is already lifted for us: BankOnrampStep renders
5187
+ inside `data-flow-mode="fiat-onramp"`, which raises it to
5188
+ `calc(100vh - 40px)`. What was missing is everything below.
5189
+ ============================================================================= */
5190
+
5191
+ /* Matches the width Swapped Connect uses for its embedded widget rather than
5192
+ inventing a number; Noah's forms are laid out for roughly the same measure. */
5193
+ .rs-modal-content:has(.rs-bank-onramp-hosted) {
5194
+ max-width: 445px;
5195
+ }
5196
+
5197
+ /* Full-bleed while a frame is mounted, matching the Swapped iframe phase. The
5198
+ header and the Back rows that used to sit beside the frame are gone, so the
5199
+ only remaining siblings are the payment status line and the currency switch,
5200
+ which keep their own inset below. Historic note kept because the reasoning
5201
+ reads backwards otherwise: this was inset while those siblings existed, and they
5202
+ would end up flush against the modal edges. Width comes from the raised
5203
+ max-width above instead.
5204
+
5205
+ The actual cause of the scrolling: `.rs-screen-body` does not grow, so the
5206
+ frame's `flex: 1` had nothing to fill and collapsed to its floor however tall
5207
+ the modal was. `min-height: 0` lets a flex child shrink below its content
5208
+ size, without which the frame would push the modal past the viewport. */
5209
+ .rs-bank-onramp:has(.rs-bank-onramp-hosted) .rs-screen-body {
5210
+ flex: 1;
5211
+ min-height: 0;
5212
+ }
5213
+
5214
+ .rs-bank-onramp-hosted {
5215
+ position: relative;
5216
+ display: flex;
5217
+ flex: 1;
5218
+ /* Floor, not the target: the frame grows to whatever the modal offers. This
5219
+ only matters on a viewport too short to give it more. */
5220
+ min-height: 586px;
5221
+ flex-direction: column;
5222
+ gap: 12px;
5223
+ }
5224
+
5225
+ .rs-bank-onramp-hosted iframe {
5226
+ width: 100%;
5227
+ min-height: 420px;
5228
+ flex: 1;
5229
+ border: 0;
5230
+ border-radius: 8px;
5231
+ background: var(--rs-background-secondary);
5232
+ }
5233
+
5234
+ .rs-bank-onramp-frame-loading {
5235
+ position: absolute;
5236
+ inset: 0 0 52px;
5237
+ display: flex;
5238
+ align-items: center;
5239
+ justify-content: center;
5240
+ background: var(--rs-background);
5241
+ }
5242
+
5243
+ /* Payment position, shown under the bank details. Colour is carried by the
5244
+ accent bar rather than the text so the copy stays readable in both themes
5245
+ and the state is still distinguishable without relying on hue alone. */
5246
+ .rs-bank-onramp-status {
5247
+ display: flex;
5248
+ flex-direction: column;
5249
+ gap: 2px;
5250
+ padding: 10px 12px;
5251
+ border-radius: 8px;
5252
+ border-left: 3px solid var(--rs-text-secondary);
5253
+ background: var(--rs-background-secondary);
5254
+ }
5255
+
5256
+ .rs-bank-native {
5257
+ display: flex;
5258
+ flex-direction: column;
5259
+ gap: 16px;
5260
+ }
5261
+
5262
+ .rs-bank-rails {
5263
+ display: grid;
5264
+ grid-auto-flow: column;
5265
+ grid-auto-columns: 1fr;
5266
+ padding: 3px;
5267
+ background: var(--rs-segmented-track);
5268
+ border-radius: var(--rs-radius-full);
5269
+ }
5270
+
5271
+ .rs-bank-rail {
5272
+ appearance: none;
5273
+ border: 0;
5274
+ background: transparent;
5275
+ padding: 6px 12px;
5276
+ border-radius: var(--rs-radius-full);
5277
+ font-family: inherit;
5278
+ font-size: 13px;
5279
+ font-weight: 500;
5280
+ color: var(--rs-segmented-idle-fg);
5281
+ cursor: pointer;
5282
+ }
5283
+
5284
+ .rs-bank-rail[aria-pressed="true"] {
5285
+ background: var(--rs-segmented-active-bg);
5286
+ color: var(--rs-segmented-active-fg);
5287
+ box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
5288
+ }
5289
+
5290
+ .rs-bank-rail:focus-visible {
5291
+ outline: 2px solid var(--rs-border-accent);
5292
+ outline-offset: 2px;
5293
+ }
5294
+
5295
+ .rs-bank-fields {
5296
+ border-radius: var(--rs-radius-lg);
5297
+ border: 1px solid var(--rs-border-surface);
5298
+ background: var(--rs-background-secondary);
5299
+ padding: 4px 16px;
5300
+ }
5301
+
5302
+ .rs-bank-detail + .rs-bank-detail {
5303
+ border-top: 1px solid var(--rs-border-surface);
5304
+ }
5305
+
5306
+ .rs-bank-copy {
5307
+ display: inline-flex;
5308
+ align-items: center;
5309
+ justify-content: center;
5310
+ flex: none;
5311
+ width: 32px;
5312
+ height: 32px;
5313
+ border: 1px solid var(--rs-border-surface);
5314
+ border-radius: var(--rs-radius-sm);
5315
+ background: var(--rs-background);
5316
+ color: var(--rs-icon);
5317
+ cursor: pointer;
5318
+ }
5319
+
5320
+ .rs-bank-copy:hover {
5321
+ background: var(--rs-surface-hover);
5322
+ }
5323
+
5324
+ .rs-bank-copy:focus-visible {
5325
+ outline: none;
5326
+ box-shadow:
5327
+ 0 0 0 2px var(--rs-background),
5328
+ 0 0 0 4px var(--rs-border-accent);
5329
+ }
5330
+
5331
+ .rs-bank-detail {
5332
+ display: flex;
5333
+ align-items: center;
5334
+ justify-content: space-between;
5335
+ gap: 12px;
5336
+ padding: 12px 0;
5337
+ }
5338
+
5339
+ .rs-bank-detail-text {
5340
+ min-width: 0;
5341
+ }
5342
+
5343
+ .rs-bank-detail-label {
5344
+ color: var(--rs-muted);
5345
+ font-size: 12px;
5346
+ line-height: 1.5;
5347
+ margin: 0;
5348
+ }
5349
+
5350
+ .rs-bank-detail-value {
5351
+ color: var(--rs-foreground);
5352
+ font-size: 14px;
5353
+ overflow-wrap: anywhere;
5354
+ user-select: text;
5355
+ }
5356
+
5357
+ .rs-bank-fee {
5358
+ font-size: 13px;
5359
+ line-height: 1.5;
5360
+ }
5361
+
5362
+ .rs-bank-onramp-status-title {
5363
+ font-size: 14px;
5364
+ font-weight: 600;
5365
+ color: var(--rs-text-primary);
5366
+ }
5367
+
5368
+ .rs-bank-onramp-status-subtitle {
5369
+ font-size: 12px;
5370
+ color: var(--rs-text-secondary);
5371
+ }
5372
+
5373
+ .rs-bank-onramp-status--delivered {
5374
+ border-left-color: var(--rs-success, #1f9d55);
5375
+ }
5376
+
5377
+ .rs-bank-onramp-status--on_hold {
5378
+ border-left-color: var(--rs-warning, #b7791f);
5379
+ }
5380
+
5381
+ .rs-bank-onramp-status--failed,
5382
+ .rs-bank-onramp-status--returned {
5383
+ border-left-color: var(--rs-error, #c53030);
5384
+ }
5385
+
5146
5386
  /* `.rs-fiat-onramp` is a marker class on the .rs-screen root so the
5147
5387
  modal-content `:has()` rules below can size correctly. The Swapped iframe
5148
5388
  phase intentionally omits our header chrome so the embedded widget owns the
@@ -5196,6 +5436,21 @@
5196
5436
  padding-inline: 0;
5197
5437
  }
5198
5438
 
5439
+ /* Same treatment for Noah's frames. Scoped to `:has(.rs-bank-onramp-hosted)`
5440
+ so the currency picker — a three-row list — keeps the normal inset. */
5441
+ .rs-modal-body[data-flow-mode="fiat-onramp"]:has(.rs-bank-onramp-hosted) {
5442
+ padding-inline: 0;
5443
+ }
5444
+
5445
+ /* The status line is the only sibling left beside the frame, and it keeps its
5446
+ inset. Padding is deliberately NOT applied to `.rs-screen-button-row`: that
5447
+ row is `width: 100%` in a content box, so an inset there makes it 32px wider
5448
+ than the full-bleed body, and the body clips the overflow — losing the right
5449
+ edge rather than insetting both. No button row renders beside a frame now. */
5450
+ .rs-bank-onramp:has(.rs-bank-onramp-hosted) .rs-bank-onramp-status {
5451
+ padding-inline: 16px;
5452
+ }
5453
+
5199
5454
  /* Connect keeps our back/close chrome above the embedded widget. In the iframe
5200
5455
  phase, drop only the bottom shell padding so the iframe lands flush with the
5201
5456
  modal bottom edge; the side inset still lets the body negative margin expand
@@ -1,5 +1,6 @@
1
- import { D as DisplayChainId, d as TargetChain } from './caip-BMi-9t09.js';
1
+ import { D as DisplayChainId, d as TargetChain } from './caip-nwFFL46o.cjs';
2
2
  import { TypedDataDefinition, Address, Hex, WalletClient, PublicClient, Chain } from 'viem';
3
+ import { a as CustomerSession } from './bearer-transport-DZyeDG64.cjs';
3
4
 
4
5
  /**
5
6
  * Consumer-supplied RPC URL overrides, scoped to a single modal instance (see
@@ -93,6 +94,17 @@ type RecoveryErrorCode = "DEPOSIT_NOT_RECOVERABLE" | "RECOVERY_UNSUPPORTED" | "S
93
94
  */
94
95
  type HistoryStatus = "pending" | "processing" | "completed" | "failed" | "refunded" | "spam";
95
96
 
97
+ /** Opt-in customer session and locale for hosted bank-transfer setup. */
98
+ interface BankOnrampConfig {
99
+ /** HTTPS support page or mailto address for bank-transfer questions. */
100
+ supportUrl?: string;
101
+ /**
102
+ * Return a short-lived customer session for the registered deposit account.
103
+ * The modal requests a fresh session for each backend request and never stores
104
+ * its bearer token.
105
+ */
106
+ getSession: (smartAccount: Address) => CustomerSession | Promise<CustomerSession>;
107
+ }
96
108
  type Caip2ChainId = `eip155:${number}` | `solana:${string}`;
97
109
  type ChainId = DisplayChainId | Caip2ChainId;
98
110
  interface DepositModalTheme {
@@ -299,6 +311,12 @@ interface DepositModalProps {
299
311
  */
300
312
  enableWallet?: boolean;
301
313
  enableFiatOnramp?: boolean;
314
+ /**
315
+ * Use Noah for Bank transfer when provisioned; unavailable routes use Swapped.
316
+ * Other fiat methods continue to use Swapped. When
317
+ * `fiatMethods` is provided, it must explicitly enable `"bank-transfer"`.
318
+ */
319
+ bankOnramp?: BankOnrampConfig;
302
320
  /** Show the Transfer Crypto / QR row. Default: true. */
303
321
  enableQrTransfer?: boolean;
304
322
  /**
@@ -706,13 +724,13 @@ type DepositAnalyticsFiatStep = "fiat_regional_payment_method" | "fiat_provider_
706
724
  type DepositAnalyticsExchangeStep = "exchange_selection" | "exchange_fee_acknowledgement" | "exchange_provider_mint" | "exchange_provider_handoff" | "exchange_tracking" | "exchange_finalising" | "exchange_receipt";
707
725
  type DepositAnalyticsMigrationStep = "migration_boot_resolve" | "migration_provider_selection" | "migration_asset_selection" | "migration_amount" | "migration_review" | "migration_submit" | "migration_processing";
708
726
  type DepositAnalyticsStep = DepositAnalyticsSharedStep | DepositAnalyticsWalletStep | DepositAnalyticsTransferStep | DepositAnalyticsFiatStep | DepositAnalyticsExchangeStep | DepositAnalyticsMigrationStep;
709
- type AnalyticsReasonFamily = "account_setup" | "amount" | "exchange" | "lookup" | "migration" | "modal" | "processor" | "provider" | "quote" | "recipient" | "recovery" | "refund" | "regional_methods" | "registration" | "route" | "signature" | "submission" | "swapped" | "transfer" | "wallet";
727
+ type AnalyticsReasonFamily = "account_setup" | "amount" | "bank" | "exchange" | "lookup" | "migration" | "modal" | "processor" | "provider" | "quote" | "recipient" | "recovery" | "refund" | "regional_methods" | "registration" | "route" | "signature" | "submission" | "swapped" | "transfer" | "wallet";
710
728
  /**
711
729
  * Reason prefixes are stable downstream routing keys. Multiword families are
712
730
  * matched from this declared list, not by splitting at the first underscore.
713
731
  */
714
732
  type RoutableAnalyticsReason<Reason extends `${AnalyticsReasonFamily}_${string}`> = Reason;
715
- type DepositAnalyticsFailureReason = RoutableAnalyticsReason<"account_setup_pending" | "account_setup_stale_response" | "account_setup_failed" | "wallet_connection_requested" | "wallet_connection_rejected" | "wallet_connection_failed" | "wallet_disconnected" | "wallet_portfolio_load_failed" | "wallet_no_supported_assets" | "wallet_no_funded_assets" | "amount_invalid" | "amount_insufficient_balance" | "amount_below_minimum" | "amount_above_maximum" | "quote_source_price_unavailable" | "quote_target_price_unavailable" | "quote_unavailable" | "wallet_chain_switch_rejected" | "wallet_chain_switch_failed" | "wallet_permit_preparation_unavailable" | "wallet_signature_rejected" | "submission_rejected" | "submission_failed" | "submission_missing_hash" | "submission_uncertain" | "transfer_source_unavailable" | "transfer_address_unavailable" | "transfer_clipboard_failed" | "processor_status_poll_failed" | "regional_methods_timeout" | "regional_methods_failed" | "regional_methods_fallback" | "regional_methods_empty" | "exchange_list_failed" | "exchange_list_empty" | "exchange_setup_unavailable" | "exchange_fee_changed" | "exchange_fee_not_acknowledged" | "swapped_mint_failed" | "swapped_url_untrusted" | "swapped_iframe_timeout" | "swapped_browser_open_failed" | "provider_cancelled" | "provider_failed" | "processor_failed" | "migration_wallet_required" | "migration_availability_loading" | "migration_availability_failed" | "migration_unavailable" | "migration_no_balance" | "migration_partial_availability" | "migration_coming_soon">;
733
+ type DepositAnalyticsFailureReason = RoutableAnalyticsReason<"account_setup_pending" | "account_setup_stale_response" | "account_setup_failed" | "wallet_connection_requested" | "wallet_connection_rejected" | "wallet_connection_failed" | "wallet_disconnected" | "wallet_portfolio_load_failed" | "wallet_no_supported_assets" | "wallet_no_funded_assets" | "amount_invalid" | "amount_insufficient_balance" | "amount_below_minimum" | "amount_above_maximum" | "quote_source_price_unavailable" | "quote_target_price_unavailable" | "quote_unavailable" | "wallet_chain_switch_rejected" | "wallet_chain_switch_failed" | "wallet_permit_preparation_unavailable" | "wallet_signature_rejected" | "submission_rejected" | "submission_failed" | "submission_missing_hash" | "submission_uncertain" | "transfer_source_unavailable" | "transfer_address_unavailable" | "transfer_clipboard_failed" | "processor_status_poll_failed" | "regional_methods_timeout" | "regional_methods_failed" | "regional_methods_fallback" | "regional_methods_empty" | "exchange_list_failed" | "exchange_list_empty" | "exchange_setup_unavailable" | "exchange_fee_changed" | "exchange_fee_not_acknowledged" | "swapped_mint_failed" | "swapped_url_untrusted" | "swapped_iframe_timeout" | "swapped_browser_open_failed" | "bank_options_failed" | "bank_setup_failed" | "bank_details_failed" | "bank_details_pending" | "provider_cancelled" | "provider_failed" | "processor_failed" | "migration_wallet_required" | "migration_availability_loading" | "migration_availability_failed" | "migration_unavailable" | "migration_no_balance" | "migration_partial_availability" | "migration_coming_soon">;
716
734
  type DepositAnalyticsAbandonmentReason = "back" | "modal_close" | "provider_back" | "wallet_disconnect" | "method_replacement" | "initial_migration_fallback";
717
735
  type DepositAnalyticsCloseSource = "header_button" | "escape" | "overlay" | "host_controlled" | "provider_back" | "native_dismiss_request" | "success_done" | "failure_cancel" | "new_deposit_reset";
718
736
  type DepositAnalyticsUiOutcome = "completed" | "failed" | "cancelled";
@@ -736,6 +754,8 @@ interface DepositWalletMethodIdentifiers {
736
754
  interface DepositFiatOnrampMethodIdentifiers {
737
755
  readonly payment_method: string;
738
756
  readonly source: "personalized" | "fallback" | "configured";
757
+ /** Who serves the row: `noah` for bank details, else `swapped`. */
758
+ readonly provider?: "swapped" | "noah";
739
759
  }
740
760
  interface DepositExchangeConnectMethodIdentifiers {
741
761
  readonly exchange: string;
@@ -1052,4 +1072,4 @@ interface AnalyticsIngestFailureEvent {
1052
1072
  }
1053
1073
  type ModalAnalyticsEvent = DepositAnalyticsEvent | WithdrawAnalyticsEvent | ClaimAnalyticsEvent | AnalyticsIngestFailureEvent;
1054
1074
 
1055
- export type { OutputTokenRule as $, AnalyticsEventEnvelope as A, DepositAnalyticsStep as B, ChainId as C, DepositAnalyticsAbandonmentReason as D, DepositAnalyticsTransferStep as E, DepositAnalyticsUiOutcome as F, DepositAnalyticsWalletStep as G, DepositAssetMigrationMethodIdentifiers as H, DepositCompleteEventData as I, DepositExchangeConnectMethodIdentifiers as J, DepositFailedEventData as K, DepositFiatOnrampMethodIdentifiers as L, DepositFundingMethod as M, DepositLifecycleEvent as N, DepositModalProps as O, DepositModalTheme as P, DepositModalUIConfig as Q, DepositSubmittedEventData as R, DepositTransferHandoffIdentifiers as S, DepositWalletIntegration as T, DepositWalletMethodIdentifiers as U, ErrorEventData as V, FiatMethodsConfig as W, HistoryAnalyticsBadge as X, HistoryClaimEntrySource as Y, HistoryStatus as Z, ModalAnalyticsEvent as _, AnalyticsIngestFailureEvent as a, PaymentConfig as a0, RecoveryErrorCode as a1, RpcUrlMap as a2, SignRecovery as a3, SignRecoveryPayload as a4, WithdrawAnalyticsAbandonmentReason as a5, WithdrawAnalyticsCloseSource as a6, WithdrawAnalyticsEvent as a7, WithdrawAnalyticsEventPayload as a8, WithdrawAnalyticsFailureReason as a9, WithdrawAnalyticsSessionProperties as aa, WithdrawAnalyticsStep as ab, WithdrawAnalyticsUiOutcome as ac, WithdrawCompleteEventData as ad, WithdrawFailedEventData as ae, WithdrawLifecycleEvent as af, WithdrawModalProps as ag, WithdrawSubmittedEventData as ah, WithdrawTransferRequest as ai, AnalyticsIngestFailureReason as b, AnalyticsReasonFamily as c, AssetMigrationsConfig as d, AssetOption as e, ClaimAnalyticsAbandonmentReason as f, ClaimAnalyticsCloseSource as g, ClaimAnalyticsCorrelation as h, ClaimAnalyticsEntrySource as i, ClaimAnalyticsEvent as j, ClaimAnalyticsEventPayload as k, ClaimAnalyticsFailureReason as l, ClaimAnalyticsSessionProperties as m, ClaimAnalyticsStep as n, ClaimAnalyticsUiOutcome as o, ConnectedEventData as p, DepositAnalyticsCloseSource as q, DepositAnalyticsCorrelator as r, DepositAnalyticsEvent as s, DepositAnalyticsEventPayload as t, DepositAnalyticsExchangeStep as u, DepositAnalyticsFailureReason as v, DepositAnalyticsFiatStep as w, DepositAnalyticsMigrationStep as x, DepositAnalyticsSessionProperties as y, DepositAnalyticsSharedStep as z };
1075
+ export type { ModalAnalyticsEvent as $, AnalyticsEventEnvelope as A, BankOnrampConfig as B, ChainId as C, DepositAnalyticsAbandonmentReason as D, DepositAnalyticsStep as E, DepositAnalyticsTransferStep as F, DepositAnalyticsUiOutcome as G, DepositAnalyticsWalletStep as H, DepositAssetMigrationMethodIdentifiers as I, DepositCompleteEventData as J, DepositExchangeConnectMethodIdentifiers as K, DepositFailedEventData as L, DepositFiatOnrampMethodIdentifiers as M, DepositFundingMethod as N, DepositLifecycleEvent as O, DepositModalProps as P, DepositModalTheme as Q, DepositModalUIConfig as R, DepositSubmittedEventData as S, DepositTransferHandoffIdentifiers as T, DepositWalletIntegration as U, DepositWalletMethodIdentifiers as V, ErrorEventData as W, FiatMethodsConfig as X, HistoryAnalyticsBadge as Y, HistoryClaimEntrySource as Z, HistoryStatus as _, AnalyticsIngestFailureEvent as a, OutputTokenRule as a0, PaymentConfig as a1, RecoveryErrorCode as a2, RpcUrlMap as a3, SignRecovery as a4, SignRecoveryPayload as a5, WithdrawAnalyticsAbandonmentReason as a6, WithdrawAnalyticsCloseSource as a7, WithdrawAnalyticsEvent as a8, WithdrawAnalyticsEventPayload as a9, WithdrawAnalyticsFailureReason as aa, WithdrawAnalyticsSessionProperties as ab, WithdrawAnalyticsStep as ac, WithdrawAnalyticsUiOutcome as ad, WithdrawCompleteEventData as ae, WithdrawFailedEventData as af, WithdrawLifecycleEvent as ag, WithdrawModalProps as ah, WithdrawSubmittedEventData as ai, WithdrawTransferRequest as aj, AnalyticsIngestFailureReason as b, AnalyticsReasonFamily as c, AssetMigrationsConfig as d, AssetOption as e, ClaimAnalyticsAbandonmentReason as f, ClaimAnalyticsCloseSource as g, ClaimAnalyticsCorrelation as h, ClaimAnalyticsEntrySource as i, ClaimAnalyticsEvent as j, ClaimAnalyticsEventPayload as k, ClaimAnalyticsFailureReason as l, ClaimAnalyticsSessionProperties as m, ClaimAnalyticsStep as n, ClaimAnalyticsUiOutcome as o, ConnectedEventData as p, DepositAnalyticsCloseSource as q, DepositAnalyticsCorrelator as r, DepositAnalyticsEvent as s, DepositAnalyticsEventPayload as t, DepositAnalyticsExchangeStep as u, DepositAnalyticsFailureReason as v, DepositAnalyticsFiatStep as w, DepositAnalyticsMigrationStep as x, DepositAnalyticsSessionProperties as y, DepositAnalyticsSharedStep as z };
@@ -1,5 +1,6 @@
1
- import { D as DisplayChainId, d as TargetChain } from './caip-BMi-9t09.cjs';
1
+ import { D as DisplayChainId, d as TargetChain } from './caip-nwFFL46o.js';
2
2
  import { TypedDataDefinition, Address, Hex, WalletClient, PublicClient, Chain } from 'viem';
3
+ import { a as CustomerSession } from './bearer-transport-DZyeDG64.js';
3
4
 
4
5
  /**
5
6
  * Consumer-supplied RPC URL overrides, scoped to a single modal instance (see
@@ -93,6 +94,17 @@ type RecoveryErrorCode = "DEPOSIT_NOT_RECOVERABLE" | "RECOVERY_UNSUPPORTED" | "S
93
94
  */
94
95
  type HistoryStatus = "pending" | "processing" | "completed" | "failed" | "refunded" | "spam";
95
96
 
97
+ /** Opt-in customer session and locale for hosted bank-transfer setup. */
98
+ interface BankOnrampConfig {
99
+ /** HTTPS support page or mailto address for bank-transfer questions. */
100
+ supportUrl?: string;
101
+ /**
102
+ * Return a short-lived customer session for the registered deposit account.
103
+ * The modal requests a fresh session for each backend request and never stores
104
+ * its bearer token.
105
+ */
106
+ getSession: (smartAccount: Address) => CustomerSession | Promise<CustomerSession>;
107
+ }
96
108
  type Caip2ChainId = `eip155:${number}` | `solana:${string}`;
97
109
  type ChainId = DisplayChainId | Caip2ChainId;
98
110
  interface DepositModalTheme {
@@ -299,6 +311,12 @@ interface DepositModalProps {
299
311
  */
300
312
  enableWallet?: boolean;
301
313
  enableFiatOnramp?: boolean;
314
+ /**
315
+ * Use Noah for Bank transfer when provisioned; unavailable routes use Swapped.
316
+ * Other fiat methods continue to use Swapped. When
317
+ * `fiatMethods` is provided, it must explicitly enable `"bank-transfer"`.
318
+ */
319
+ bankOnramp?: BankOnrampConfig;
302
320
  /** Show the Transfer Crypto / QR row. Default: true. */
303
321
  enableQrTransfer?: boolean;
304
322
  /**
@@ -706,13 +724,13 @@ type DepositAnalyticsFiatStep = "fiat_regional_payment_method" | "fiat_provider_
706
724
  type DepositAnalyticsExchangeStep = "exchange_selection" | "exchange_fee_acknowledgement" | "exchange_provider_mint" | "exchange_provider_handoff" | "exchange_tracking" | "exchange_finalising" | "exchange_receipt";
707
725
  type DepositAnalyticsMigrationStep = "migration_boot_resolve" | "migration_provider_selection" | "migration_asset_selection" | "migration_amount" | "migration_review" | "migration_submit" | "migration_processing";
708
726
  type DepositAnalyticsStep = DepositAnalyticsSharedStep | DepositAnalyticsWalletStep | DepositAnalyticsTransferStep | DepositAnalyticsFiatStep | DepositAnalyticsExchangeStep | DepositAnalyticsMigrationStep;
709
- type AnalyticsReasonFamily = "account_setup" | "amount" | "exchange" | "lookup" | "migration" | "modal" | "processor" | "provider" | "quote" | "recipient" | "recovery" | "refund" | "regional_methods" | "registration" | "route" | "signature" | "submission" | "swapped" | "transfer" | "wallet";
727
+ type AnalyticsReasonFamily = "account_setup" | "amount" | "bank" | "exchange" | "lookup" | "migration" | "modal" | "processor" | "provider" | "quote" | "recipient" | "recovery" | "refund" | "regional_methods" | "registration" | "route" | "signature" | "submission" | "swapped" | "transfer" | "wallet";
710
728
  /**
711
729
  * Reason prefixes are stable downstream routing keys. Multiword families are
712
730
  * matched from this declared list, not by splitting at the first underscore.
713
731
  */
714
732
  type RoutableAnalyticsReason<Reason extends `${AnalyticsReasonFamily}_${string}`> = Reason;
715
- type DepositAnalyticsFailureReason = RoutableAnalyticsReason<"account_setup_pending" | "account_setup_stale_response" | "account_setup_failed" | "wallet_connection_requested" | "wallet_connection_rejected" | "wallet_connection_failed" | "wallet_disconnected" | "wallet_portfolio_load_failed" | "wallet_no_supported_assets" | "wallet_no_funded_assets" | "amount_invalid" | "amount_insufficient_balance" | "amount_below_minimum" | "amount_above_maximum" | "quote_source_price_unavailable" | "quote_target_price_unavailable" | "quote_unavailable" | "wallet_chain_switch_rejected" | "wallet_chain_switch_failed" | "wallet_permit_preparation_unavailable" | "wallet_signature_rejected" | "submission_rejected" | "submission_failed" | "submission_missing_hash" | "submission_uncertain" | "transfer_source_unavailable" | "transfer_address_unavailable" | "transfer_clipboard_failed" | "processor_status_poll_failed" | "regional_methods_timeout" | "regional_methods_failed" | "regional_methods_fallback" | "regional_methods_empty" | "exchange_list_failed" | "exchange_list_empty" | "exchange_setup_unavailable" | "exchange_fee_changed" | "exchange_fee_not_acknowledged" | "swapped_mint_failed" | "swapped_url_untrusted" | "swapped_iframe_timeout" | "swapped_browser_open_failed" | "provider_cancelled" | "provider_failed" | "processor_failed" | "migration_wallet_required" | "migration_availability_loading" | "migration_availability_failed" | "migration_unavailable" | "migration_no_balance" | "migration_partial_availability" | "migration_coming_soon">;
733
+ type DepositAnalyticsFailureReason = RoutableAnalyticsReason<"account_setup_pending" | "account_setup_stale_response" | "account_setup_failed" | "wallet_connection_requested" | "wallet_connection_rejected" | "wallet_connection_failed" | "wallet_disconnected" | "wallet_portfolio_load_failed" | "wallet_no_supported_assets" | "wallet_no_funded_assets" | "amount_invalid" | "amount_insufficient_balance" | "amount_below_minimum" | "amount_above_maximum" | "quote_source_price_unavailable" | "quote_target_price_unavailable" | "quote_unavailable" | "wallet_chain_switch_rejected" | "wallet_chain_switch_failed" | "wallet_permit_preparation_unavailable" | "wallet_signature_rejected" | "submission_rejected" | "submission_failed" | "submission_missing_hash" | "submission_uncertain" | "transfer_source_unavailable" | "transfer_address_unavailable" | "transfer_clipboard_failed" | "processor_status_poll_failed" | "regional_methods_timeout" | "regional_methods_failed" | "regional_methods_fallback" | "regional_methods_empty" | "exchange_list_failed" | "exchange_list_empty" | "exchange_setup_unavailable" | "exchange_fee_changed" | "exchange_fee_not_acknowledged" | "swapped_mint_failed" | "swapped_url_untrusted" | "swapped_iframe_timeout" | "swapped_browser_open_failed" | "bank_options_failed" | "bank_setup_failed" | "bank_details_failed" | "bank_details_pending" | "provider_cancelled" | "provider_failed" | "processor_failed" | "migration_wallet_required" | "migration_availability_loading" | "migration_availability_failed" | "migration_unavailable" | "migration_no_balance" | "migration_partial_availability" | "migration_coming_soon">;
716
734
  type DepositAnalyticsAbandonmentReason = "back" | "modal_close" | "provider_back" | "wallet_disconnect" | "method_replacement" | "initial_migration_fallback";
717
735
  type DepositAnalyticsCloseSource = "header_button" | "escape" | "overlay" | "host_controlled" | "provider_back" | "native_dismiss_request" | "success_done" | "failure_cancel" | "new_deposit_reset";
718
736
  type DepositAnalyticsUiOutcome = "completed" | "failed" | "cancelled";
@@ -736,6 +754,8 @@ interface DepositWalletMethodIdentifiers {
736
754
  interface DepositFiatOnrampMethodIdentifiers {
737
755
  readonly payment_method: string;
738
756
  readonly source: "personalized" | "fallback" | "configured";
757
+ /** Who serves the row: `noah` for bank details, else `swapped`. */
758
+ readonly provider?: "swapped" | "noah";
739
759
  }
740
760
  interface DepositExchangeConnectMethodIdentifiers {
741
761
  readonly exchange: string;
@@ -1052,4 +1072,4 @@ interface AnalyticsIngestFailureEvent {
1052
1072
  }
1053
1073
  type ModalAnalyticsEvent = DepositAnalyticsEvent | WithdrawAnalyticsEvent | ClaimAnalyticsEvent | AnalyticsIngestFailureEvent;
1054
1074
 
1055
- export type { OutputTokenRule as $, AnalyticsEventEnvelope as A, DepositAnalyticsStep as B, ChainId as C, DepositAnalyticsAbandonmentReason as D, DepositAnalyticsTransferStep as E, DepositAnalyticsUiOutcome as F, DepositAnalyticsWalletStep as G, DepositAssetMigrationMethodIdentifiers as H, DepositCompleteEventData as I, DepositExchangeConnectMethodIdentifiers as J, DepositFailedEventData as K, DepositFiatOnrampMethodIdentifiers as L, DepositFundingMethod as M, DepositLifecycleEvent as N, DepositModalProps as O, DepositModalTheme as P, DepositModalUIConfig as Q, DepositSubmittedEventData as R, DepositTransferHandoffIdentifiers as S, DepositWalletIntegration as T, DepositWalletMethodIdentifiers as U, ErrorEventData as V, FiatMethodsConfig as W, HistoryAnalyticsBadge as X, HistoryClaimEntrySource as Y, HistoryStatus as Z, ModalAnalyticsEvent as _, AnalyticsIngestFailureEvent as a, PaymentConfig as a0, RecoveryErrorCode as a1, RpcUrlMap as a2, SignRecovery as a3, SignRecoveryPayload as a4, WithdrawAnalyticsAbandonmentReason as a5, WithdrawAnalyticsCloseSource as a6, WithdrawAnalyticsEvent as a7, WithdrawAnalyticsEventPayload as a8, WithdrawAnalyticsFailureReason as a9, WithdrawAnalyticsSessionProperties as aa, WithdrawAnalyticsStep as ab, WithdrawAnalyticsUiOutcome as ac, WithdrawCompleteEventData as ad, WithdrawFailedEventData as ae, WithdrawLifecycleEvent as af, WithdrawModalProps as ag, WithdrawSubmittedEventData as ah, WithdrawTransferRequest as ai, AnalyticsIngestFailureReason as b, AnalyticsReasonFamily as c, AssetMigrationsConfig as d, AssetOption as e, ClaimAnalyticsAbandonmentReason as f, ClaimAnalyticsCloseSource as g, ClaimAnalyticsCorrelation as h, ClaimAnalyticsEntrySource as i, ClaimAnalyticsEvent as j, ClaimAnalyticsEventPayload as k, ClaimAnalyticsFailureReason as l, ClaimAnalyticsSessionProperties as m, ClaimAnalyticsStep as n, ClaimAnalyticsUiOutcome as o, ConnectedEventData as p, DepositAnalyticsCloseSource as q, DepositAnalyticsCorrelator as r, DepositAnalyticsEvent as s, DepositAnalyticsEventPayload as t, DepositAnalyticsExchangeStep as u, DepositAnalyticsFailureReason as v, DepositAnalyticsFiatStep as w, DepositAnalyticsMigrationStep as x, DepositAnalyticsSessionProperties as y, DepositAnalyticsSharedStep as z };
1075
+ export type { ModalAnalyticsEvent as $, AnalyticsEventEnvelope as A, BankOnrampConfig as B, ChainId as C, DepositAnalyticsAbandonmentReason as D, DepositAnalyticsStep as E, DepositAnalyticsTransferStep as F, DepositAnalyticsUiOutcome as G, DepositAnalyticsWalletStep as H, DepositAssetMigrationMethodIdentifiers as I, DepositCompleteEventData as J, DepositExchangeConnectMethodIdentifiers as K, DepositFailedEventData as L, DepositFiatOnrampMethodIdentifiers as M, DepositFundingMethod as N, DepositLifecycleEvent as O, DepositModalProps as P, DepositModalTheme as Q, DepositModalUIConfig as R, DepositSubmittedEventData as S, DepositTransferHandoffIdentifiers as T, DepositWalletIntegration as U, DepositWalletMethodIdentifiers as V, ErrorEventData as W, FiatMethodsConfig as X, HistoryAnalyticsBadge as Y, HistoryClaimEntrySource as Z, HistoryStatus as _, AnalyticsIngestFailureEvent as a, OutputTokenRule as a0, PaymentConfig as a1, RecoveryErrorCode as a2, RpcUrlMap as a3, SignRecovery as a4, SignRecoveryPayload as a5, WithdrawAnalyticsAbandonmentReason as a6, WithdrawAnalyticsCloseSource as a7, WithdrawAnalyticsEvent as a8, WithdrawAnalyticsEventPayload as a9, WithdrawAnalyticsFailureReason as aa, WithdrawAnalyticsSessionProperties as ab, WithdrawAnalyticsStep as ac, WithdrawAnalyticsUiOutcome as ad, WithdrawCompleteEventData as ae, WithdrawFailedEventData as af, WithdrawLifecycleEvent as ag, WithdrawModalProps as ah, WithdrawSubmittedEventData as ai, WithdrawTransferRequest as aj, AnalyticsIngestFailureReason as b, AnalyticsReasonFamily as c, AssetMigrationsConfig as d, AssetOption as e, ClaimAnalyticsAbandonmentReason as f, ClaimAnalyticsCloseSource as g, ClaimAnalyticsCorrelation as h, ClaimAnalyticsEntrySource as i, ClaimAnalyticsEvent as j, ClaimAnalyticsEventPayload as k, ClaimAnalyticsFailureReason as l, ClaimAnalyticsSessionProperties as m, ClaimAnalyticsStep as n, ClaimAnalyticsUiOutcome as o, ConnectedEventData as p, DepositAnalyticsCloseSource as q, DepositAnalyticsCorrelator as r, DepositAnalyticsEvent as s, DepositAnalyticsEventPayload as t, DepositAnalyticsExchangeStep as u, DepositAnalyticsFailureReason as v, DepositAnalyticsFiatStep as w, DepositAnalyticsMigrationStep as x, DepositAnalyticsSessionProperties as y, DepositAnalyticsSharedStep as z };
package/dist/withdraw.cjs CHANGED
@@ -1,9 +1,10 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _chunkEG4H7OMCcjs = require('./chunk-EG4H7OMC.cjs');
4
- require('./chunk-HMUGY66O.cjs');
5
- require('./chunk-OY5N3E6L.cjs');
6
- require('./chunk-PYOC6K24.cjs');
3
+ var _chunkCIVFT5KRcjs = require('./chunk-CIVFT5KR.cjs');
4
+ require('./chunk-KXSU24RU.cjs');
5
+ require('./chunk-G264OM23.cjs');
6
+ require('./chunk-FKJ6EJHH.cjs');
7
+ require('./chunk-D3R3O4CY.cjs');
7
8
 
8
9
 
9
- exports.WithdrawModal = _chunkEG4H7OMCcjs.WithdrawModal;
10
+ exports.WithdrawModal = _chunkCIVFT5KRcjs.WithdrawModal;
@@ -1,8 +1,9 @@
1
1
  import * as react from 'react';
2
- import { ag as WithdrawModalProps } from './types-BShYNpvO.cjs';
3
- export { A as AnalyticsEventEnvelope, a as AnalyticsIngestFailureEvent, b as AnalyticsIngestFailureReason, c as AnalyticsReasonFamily, e as AssetOption, f as ClaimAnalyticsAbandonmentReason, g as ClaimAnalyticsCloseSource, h as ClaimAnalyticsCorrelation, i as ClaimAnalyticsEntrySource, j as ClaimAnalyticsEvent, k as ClaimAnalyticsEventPayload, l as ClaimAnalyticsFailureReason, m as ClaimAnalyticsSessionProperties, n as ClaimAnalyticsStep, o as ClaimAnalyticsUiOutcome, p as ConnectedEventData, V as ErrorEventData, X as HistoryAnalyticsBadge, Y as HistoryClaimEntrySource, Z as HistoryStatus, a1 as RecoveryErrorCode, a2 as RpcUrlMap, a3 as SignRecovery, a4 as SignRecoveryPayload, a5 as WithdrawAnalyticsAbandonmentReason, a6 as WithdrawAnalyticsCloseSource, a7 as WithdrawAnalyticsEvent, a8 as WithdrawAnalyticsEventPayload, a9 as WithdrawAnalyticsFailureReason, aa as WithdrawAnalyticsSessionProperties, ab as WithdrawAnalyticsStep, ac as WithdrawAnalyticsUiOutcome, ad as WithdrawCompleteEventData, ae as WithdrawFailedEventData, ah as WithdrawSubmittedEventData, ai as WithdrawTransferRequest } from './types-BShYNpvO.cjs';
4
- import './caip-BMi-9t09.cjs';
2
+ import { ah as WithdrawModalProps } from './types-BEEMfNi2.cjs';
3
+ export { A as AnalyticsEventEnvelope, a as AnalyticsIngestFailureEvent, b as AnalyticsIngestFailureReason, c as AnalyticsReasonFamily, e as AssetOption, f as ClaimAnalyticsAbandonmentReason, g as ClaimAnalyticsCloseSource, h as ClaimAnalyticsCorrelation, i as ClaimAnalyticsEntrySource, j as ClaimAnalyticsEvent, k as ClaimAnalyticsEventPayload, l as ClaimAnalyticsFailureReason, m as ClaimAnalyticsSessionProperties, n as ClaimAnalyticsStep, o as ClaimAnalyticsUiOutcome, p as ConnectedEventData, W as ErrorEventData, Y as HistoryAnalyticsBadge, Z as HistoryClaimEntrySource, _ as HistoryStatus, a2 as RecoveryErrorCode, a3 as RpcUrlMap, a4 as SignRecovery, a5 as SignRecoveryPayload, a6 as WithdrawAnalyticsAbandonmentReason, a7 as WithdrawAnalyticsCloseSource, a8 as WithdrawAnalyticsEvent, a9 as WithdrawAnalyticsEventPayload, aa as WithdrawAnalyticsFailureReason, ab as WithdrawAnalyticsSessionProperties, ac as WithdrawAnalyticsStep, ad as WithdrawAnalyticsUiOutcome, ae as WithdrawCompleteEventData, af as WithdrawFailedEventData, ai as WithdrawSubmittedEventData, aj as WithdrawTransferRequest } from './types-BEEMfNi2.cjs';
4
+ import './caip-nwFFL46o.cjs';
5
5
  import 'viem';
6
+ import './bearer-transport-DZyeDG64.cjs';
6
7
 
7
8
  /**
8
9
  * What a flow is showing, for a surface that draws its own chrome around it.
@@ -1,8 +1,9 @@
1
1
  import * as react from 'react';
2
- import { ag as WithdrawModalProps } from './types-BOxa1DE-.js';
3
- export { A as AnalyticsEventEnvelope, a as AnalyticsIngestFailureEvent, b as AnalyticsIngestFailureReason, c as AnalyticsReasonFamily, e as AssetOption, f as ClaimAnalyticsAbandonmentReason, g as ClaimAnalyticsCloseSource, h as ClaimAnalyticsCorrelation, i as ClaimAnalyticsEntrySource, j as ClaimAnalyticsEvent, k as ClaimAnalyticsEventPayload, l as ClaimAnalyticsFailureReason, m as ClaimAnalyticsSessionProperties, n as ClaimAnalyticsStep, o as ClaimAnalyticsUiOutcome, p as ConnectedEventData, V as ErrorEventData, X as HistoryAnalyticsBadge, Y as HistoryClaimEntrySource, Z as HistoryStatus, a1 as RecoveryErrorCode, a2 as RpcUrlMap, a3 as SignRecovery, a4 as SignRecoveryPayload, a5 as WithdrawAnalyticsAbandonmentReason, a6 as WithdrawAnalyticsCloseSource, a7 as WithdrawAnalyticsEvent, a8 as WithdrawAnalyticsEventPayload, a9 as WithdrawAnalyticsFailureReason, aa as WithdrawAnalyticsSessionProperties, ab as WithdrawAnalyticsStep, ac as WithdrawAnalyticsUiOutcome, ad as WithdrawCompleteEventData, ae as WithdrawFailedEventData, ah as WithdrawSubmittedEventData, ai as WithdrawTransferRequest } from './types-BOxa1DE-.js';
4
- import './caip-BMi-9t09.js';
2
+ import { ah as WithdrawModalProps } from './types-DQDUqzsZ.js';
3
+ export { A as AnalyticsEventEnvelope, a as AnalyticsIngestFailureEvent, b as AnalyticsIngestFailureReason, c as AnalyticsReasonFamily, e as AssetOption, f as ClaimAnalyticsAbandonmentReason, g as ClaimAnalyticsCloseSource, h as ClaimAnalyticsCorrelation, i as ClaimAnalyticsEntrySource, j as ClaimAnalyticsEvent, k as ClaimAnalyticsEventPayload, l as ClaimAnalyticsFailureReason, m as ClaimAnalyticsSessionProperties, n as ClaimAnalyticsStep, o as ClaimAnalyticsUiOutcome, p as ConnectedEventData, W as ErrorEventData, Y as HistoryAnalyticsBadge, Z as HistoryClaimEntrySource, _ as HistoryStatus, a2 as RecoveryErrorCode, a3 as RpcUrlMap, a4 as SignRecovery, a5 as SignRecoveryPayload, a6 as WithdrawAnalyticsAbandonmentReason, a7 as WithdrawAnalyticsCloseSource, a8 as WithdrawAnalyticsEvent, a9 as WithdrawAnalyticsEventPayload, aa as WithdrawAnalyticsFailureReason, ab as WithdrawAnalyticsSessionProperties, ac as WithdrawAnalyticsStep, ad as WithdrawAnalyticsUiOutcome, ae as WithdrawCompleteEventData, af as WithdrawFailedEventData, ai as WithdrawSubmittedEventData, aj as WithdrawTransferRequest } from './types-DQDUqzsZ.js';
4
+ import './caip-nwFFL46o.js';
5
5
  import 'viem';
6
+ import './bearer-transport-DZyeDG64.js';
6
7
 
7
8
  /**
8
9
  * What a flow is showing, for a surface that draws its own chrome around it.
package/dist/withdraw.mjs CHANGED
@@ -1,9 +1,10 @@
1
1
  import {
2
2
  WithdrawModal
3
- } from "./chunk-BIL4ENC3.mjs";
4
- import "./chunk-5NWLS5BQ.mjs";
5
- import "./chunk-EAGMY3QE.mjs";
6
- import "./chunk-X6N2XPTO.mjs";
3
+ } from "./chunk-IPKT3FU6.mjs";
4
+ import "./chunk-OZPMRTW3.mjs";
5
+ import "./chunk-YY4ZOAH5.mjs";
6
+ import "./chunk-E7IMWVMN.mjs";
7
+ import "./chunk-ZOJMB5TZ.mjs";
7
8
  export {
8
9
  WithdrawModal
9
10
  };
package/package.json CHANGED
@@ -1,8 +1,9 @@
1
1
  {
2
2
  "name": "@rhinestone/deposit-modal",
3
- "version": "0.19.0",
4
- "description": "React modal component for Rhinestone cross-chain deposits",
5
- "author": "Rhinestone <dev@rhinestone.wtf>",
3
+ "version": "0.20.1",
4
+ "description": "React modal for Rhinestone Deposits and withdrawals",
5
+ "author": "Rhinestone <gm@rhinestone.dev>",
6
+ "homepage": "https://docs.rhinestone.dev/deposits/overview/widget/quickstart",
6
7
  "bugs": {
7
8
  "url": "https://github.com/rhinestonewtf/deposit-modal/issues"
8
9
  },
@@ -71,16 +72,6 @@
71
72
  "default": "./dist/onramp.cjs"
72
73
  }
73
74
  },
74
- "./offramp": {
75
- "import": {
76
- "types": "./dist/offramp.d.ts",
77
- "default": "./dist/offramp.mjs"
78
- },
79
- "require": {
80
- "types": "./dist/offramp.d.cts",
81
- "default": "./dist/offramp.cjs"
82
- }
83
- },
84
75
  "./compliance": {
85
76
  "import": {
86
77
  "types": "./dist/compliance.d.ts",
@@ -182,6 +173,7 @@
182
173
  "@testing-library/jest-dom": "^6",
183
174
  "@testing-library/react": "^16",
184
175
  "@testing-library/user-event": "^14",
176
+ "@types/node": "^22.20.4",
185
177
  "@types/react": "^19.0.0",
186
178
  "@types/react-dom": "^19.0.0",
187
179
  "@vitest/coverage-v8": "^4.0.10",
@@ -201,7 +193,7 @@
201
193
  {
202
194
  "name": "Total Bundle (Everything)",
203
195
  "path": "dist/index.mjs",
204
- "limit": "100.5 kB",
196
+ "limit": "108 kB",
205
197
  "ignore": [
206
198
  "react",
207
199
  "react-dom",
@@ -220,7 +212,7 @@
220
212
  {
221
213
  "name": "Native Embed (deposit & withdraw)",
222
214
  "path": "dist/embed.mjs",
223
- "limit": "107 kB",
215
+ "limit": "114.5 kB",
224
216
  "ignore": [
225
217
  "react",
226
218
  "react-dom",
@@ -240,7 +232,7 @@
240
232
  "name": "Deposit & Withdraw Modals Only",
241
233
  "path": "dist/index.mjs",
242
234
  "import": "{ DepositModal, WithdrawModal }",
243
- "limit": "100 kB",
235
+ "limit": "107.5 kB",
244
236
  "ignore": [
245
237
  "react",
246
238
  "react-dom",
@@ -259,7 +251,7 @@
259
251
  {
260
252
  "name": "Withdraw Modal Only",
261
253
  "path": "dist/withdraw.mjs",
262
- "limit": "47.1 kB",
254
+ "limit": "50 kB",
263
255
  "ignore": [
264
256
  "react",
265
257
  "react-dom",
@@ -1,11 +0,0 @@
1
- import {
2
- WithdrawModal,
3
- buildWithdrawAnalyticsSessionProperties
4
- } from "./chunk-BIL4ENC3.mjs";
5
- import "./chunk-5NWLS5BQ.mjs";
6
- import "./chunk-EAGMY3QE.mjs";
7
- import "./chunk-X6N2XPTO.mjs";
8
- export {
9
- WithdrawModal,
10
- buildWithdrawAnalyticsSessionProperties
11
- };
@@ -1,11 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
-
3
-
4
- var _chunkEG4H7OMCcjs = require('./chunk-EG4H7OMC.cjs');
5
- require('./chunk-HMUGY66O.cjs');
6
- require('./chunk-OY5N3E6L.cjs');
7
- require('./chunk-PYOC6K24.cjs');
8
-
9
-
10
-
11
- exports.WithdrawModal = _chunkEG4H7OMCcjs.WithdrawModal; exports.buildWithdrawAnalyticsSessionProperties = _chunkEG4H7OMCcjs.buildWithdrawAnalyticsSessionProperties;
@@ -1,19 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});// src/core/ramp-utils.ts
2
- function rampQuery(value) {
3
- return new URLSearchParams(
4
- Object.entries(value).filter(([, value2]) => value2 !== void 0).map(([key, value2]) => [key, String(value2)])
5
- ).toString();
6
- }
7
- function rampResourceId(value) {
8
- if (!/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i.test(
9
- value
10
- )) {
11
- throw new Error("Invalid ramp resource ID");
12
- }
13
- return value;
14
- }
15
-
16
-
17
-
18
-
19
- exports.rampQuery = rampQuery; exports.rampResourceId = rampResourceId;