@rhinestone/deposit-modal 0.3.1 → 0.4.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 (38) hide show
  1. package/dist/{DepositModalReown-MECHBE6P.cjs → DepositModalReown-KFTMS2WX.cjs} +9 -9
  2. package/dist/{DepositModalReown-G7UX4IBZ.mjs → DepositModalReown-PC7EX5VK.mjs} +6 -6
  3. package/dist/{WithdrawModalReown-CUJAFUQM.mjs → WithdrawModalReown-BE23LUMT.mjs} +5 -5
  4. package/dist/{WithdrawModalReown-WJ6VBZKK.cjs → WithdrawModalReown-Z2YF2FSJ.cjs} +8 -8
  5. package/dist/{chunk-ULEAK63T.cjs → chunk-3MXWIYAT.cjs} +16 -6
  6. package/dist/{chunk-QYSCCX4K.mjs → chunk-3PVDRSJ7.mjs} +539 -412
  7. package/dist/{chunk-SPUZLWQS.cjs → chunk-7MP2UWIQ.cjs} +519 -392
  8. package/dist/{chunk-MILJQWPT.cjs → chunk-ABVRVW3P.cjs} +133 -8
  9. package/dist/{chunk-LEL6GMEQ.cjs → chunk-AE5LHTPM.cjs} +121 -101
  10. package/dist/{chunk-TQ2AYMWS.mjs → chunk-F7P4MV72.mjs} +1 -1
  11. package/dist/{chunk-BAEB5AFZ.mjs → chunk-FJWLC4AM.mjs} +1 -1
  12. package/dist/{chunk-3C35DVPE.mjs → chunk-GKC22JC4.mjs} +901 -428
  13. package/dist/{chunk-R5CPOBCF.cjs → chunk-NRNJAQUA.cjs} +4 -4
  14. package/dist/{chunk-MQIJZNTP.cjs → chunk-OQVLEVNR.cjs} +760 -287
  15. package/dist/{chunk-AJHFNHG3.cjs → chunk-UEKPBRBY.cjs} +3 -3
  16. package/dist/{chunk-R5WDHHVM.mjs → chunk-UFKFSGT3.mjs} +14 -4
  17. package/dist/{chunk-DZQD3DAV.mjs → chunk-WCIGOV34.mjs} +32 -12
  18. package/dist/{chunk-6YRDD462.mjs → chunk-WJX3TJFK.mjs} +135 -10
  19. package/dist/constants.cjs +2 -2
  20. package/dist/constants.mjs +1 -1
  21. package/dist/deposit.cjs +6 -6
  22. package/dist/deposit.d.cts +2 -2
  23. package/dist/deposit.d.ts +2 -2
  24. package/dist/deposit.mjs +5 -5
  25. package/dist/index.cjs +7 -7
  26. package/dist/index.d.cts +1 -1
  27. package/dist/index.d.ts +1 -1
  28. package/dist/index.mjs +6 -6
  29. package/dist/polymarket.cjs +6 -6
  30. package/dist/polymarket.mjs +3 -3
  31. package/dist/styles.css +218 -9
  32. package/dist/{types-RzfAD14B.d.ts → types-CFRuisqK.d.cts} +1 -1
  33. package/dist/{types-RzfAD14B.d.cts → types-CFRuisqK.d.ts} +1 -1
  34. package/dist/withdraw.cjs +5 -5
  35. package/dist/withdraw.d.cts +2 -2
  36. package/dist/withdraw.d.ts +2 -2
  37. package/dist/withdraw.mjs +4 -4
  38. package/package.json +1 -1
@@ -2,9 +2,9 @@ import {
2
2
  POLYMARKET_POLYGON_CHAIN_ID,
3
3
  fetchPolymarketProxyWallet,
4
4
  readPolymarketBalances
5
- } from "./chunk-BAEB5AFZ.mjs";
6
- import "./chunk-TQ2AYMWS.mjs";
7
- import "./chunk-6YRDD462.mjs";
5
+ } from "./chunk-FJWLC4AM.mjs";
6
+ import "./chunk-F7P4MV72.mjs";
7
+ import "./chunk-WJX3TJFK.mjs";
8
8
 
9
9
  // src/core/dapp-imports/polymarket/account.ts
10
10
  import {
package/dist/styles.css CHANGED
@@ -77,6 +77,11 @@
77
77
  --rs-button-ghost-bg: #e4e4e7;
78
78
  --rs-button-ghost-bg-hover: #d4d4d8;
79
79
  --rs-button-ghost-text: #27272a;
80
+ /* Segmented toggle (Crypto/Cash) — track + raised selected pill. */
81
+ --rs-segmented-track: #e4e4e7;
82
+ --rs-segmented-active-bg: #ffffff;
83
+ --rs-segmented-active-fg: #18181b;
84
+ --rs-segmented-idle-fg: #52525c;
80
85
 
81
86
  /* Primary (CTA). Default theme uses the dark-on-light pair.
82
87
  A custom theme overrides these directly via inline CSS vars,
@@ -218,6 +223,11 @@
218
223
  --rs-button-ghost-bg: #27272a;
219
224
  --rs-button-ghost-bg-hover: #3f3f46;
220
225
  --rs-button-ghost-text: #e4e4e7;
226
+ /* Segmented toggle (Crypto/Cash) — dark track + raised selected pill. */
227
+ --rs-segmented-track: #27272a;
228
+ --rs-segmented-active-bg: #52525c;
229
+ --rs-segmented-active-fg: #fafafa;
230
+ --rs-segmented-idle-fg: #9f9fa9;
221
231
  --rs-surface-hover: #3f3f46;
222
232
  /* Figma coin-select/selected (dark) — zinc-900 fill + zinc-700 border. */
223
233
  --rs-asset-selected-bg: #18181b;
@@ -2229,6 +2239,75 @@
2229
2239
  width: 100%;
2230
2240
  }
2231
2241
 
2242
+ /* Expandable "Fees" row on the Swapped receipt. Summary matches a detail row;
2243
+ the breakdown reveals below. */
2244
+ .rs-fees-accordion {
2245
+ display: flex;
2246
+ flex-direction: column;
2247
+ }
2248
+
2249
+ .rs-fees-accordion-summary {
2250
+ display: flex;
2251
+ align-items: center;
2252
+ justify-content: space-between;
2253
+ gap: 12px;
2254
+ width: 100%;
2255
+ padding: 0;
2256
+ background: none;
2257
+ border: 0;
2258
+ font-family: inherit;
2259
+ font-size: 14px;
2260
+ font-weight: 500;
2261
+ line-height: normal;
2262
+ color: var(--rs-muted);
2263
+ cursor: pointer;
2264
+ }
2265
+
2266
+ .rs-fees-accordion-summary:disabled {
2267
+ cursor: default;
2268
+ }
2269
+
2270
+ .rs-fees-accordion-summary:focus-visible {
2271
+ outline: 2px solid var(--rs-border-accent);
2272
+ outline-offset: 2px;
2273
+ border-radius: 4px;
2274
+ }
2275
+
2276
+ .rs-fees-accordion-chevron {
2277
+ display: inline-flex;
2278
+ align-items: center;
2279
+ justify-content: center;
2280
+ color: var(--rs-muted);
2281
+ transition: transform 0.18s ease;
2282
+ }
2283
+
2284
+ .rs-fees-accordion-chevron svg {
2285
+ width: 16px;
2286
+ height: 16px;
2287
+ }
2288
+
2289
+ .rs-fees-accordion-chevron--open {
2290
+ transform: rotate(180deg);
2291
+ }
2292
+
2293
+ .rs-fees-accordion-rows {
2294
+ display: flex;
2295
+ flex-direction: column;
2296
+ gap: 8px;
2297
+ margin-top: 8px;
2298
+ }
2299
+
2300
+ .rs-fees-accordion-row {
2301
+ display: flex;
2302
+ align-items: center;
2303
+ justify-content: space-between;
2304
+ gap: 12px;
2305
+ font-size: 13px;
2306
+ font-weight: 500;
2307
+ line-height: normal;
2308
+ color: var(--rs-muted);
2309
+ }
2310
+
2232
2311
  .rs-review-detail-row {
2233
2312
  display: flex;
2234
2313
  align-items: center;
@@ -4482,6 +4561,20 @@
4482
4561
  display: flex;
4483
4562
  flex-direction: column;
4484
4563
  gap: 4px;
4564
+ min-width: 0;
4565
+ }
4566
+
4567
+ /* Row that holds the title/subtitle block plus an optional right-aligned
4568
+ aside (the Crypto/Cash toggle on the method picker). */
4569
+ .rs-body-header-main {
4570
+ display: flex;
4571
+ align-items: center;
4572
+ justify-content: space-between;
4573
+ gap: 12px;
4574
+ }
4575
+
4576
+ .rs-body-header-aside {
4577
+ flex-shrink: 0;
4485
4578
  }
4486
4579
 
4487
4580
  .rs-body-header-title {
@@ -4500,6 +4593,45 @@
4500
4593
  margin: 0;
4501
4594
  }
4502
4595
 
4596
+ /* Segmented toggle (Crypto / Cash) — Figma "toggle container". */
4597
+ .rs-segmented {
4598
+ display: inline-flex;
4599
+ align-items: center;
4600
+ gap: 2px;
4601
+ padding: 2px;
4602
+ background: var(--rs-segmented-track);
4603
+ border-radius: var(--rs-radius-full);
4604
+ }
4605
+
4606
+ .rs-segmented-option {
4607
+ appearance: none;
4608
+ border: 0;
4609
+ background: transparent;
4610
+ padding: 5px 12px;
4611
+ border-radius: var(--rs-radius-full);
4612
+ font-family: inherit;
4613
+ font-size: 13px;
4614
+ font-weight: 500;
4615
+ line-height: 1.25;
4616
+ color: var(--rs-segmented-idle-fg);
4617
+ cursor: pointer;
4618
+ transition:
4619
+ background-color 0.15s,
4620
+ color 0.15s,
4621
+ box-shadow 0.15s;
4622
+ }
4623
+
4624
+ .rs-segmented-option:focus-visible {
4625
+ outline: 2px solid var(--rs-border-accent);
4626
+ outline-offset: 2px;
4627
+ }
4628
+
4629
+ .rs-segmented-option--active {
4630
+ background: var(--rs-segmented-active-bg);
4631
+ color: var(--rs-segmented-active-fg);
4632
+ box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
4633
+ }
4634
+
4503
4635
  /* Ticker — per-digit odometer-style animation for the live timer.
4504
4636
  Each slot clips its content; the outgoing digit slides up and out while
4505
4637
  the incoming digit slides up from below. Static chars (e.g. ":") never
@@ -4693,7 +4825,6 @@
4693
4825
  .rs-list-row-meta-icons {
4694
4826
  display: flex;
4695
4827
  align-items: center;
4696
- gap: 4px;
4697
4828
  }
4698
4829
 
4699
4830
  .rs-list-row-meta-icons > * {
@@ -4703,6 +4834,15 @@
4703
4834
  align-items: center;
4704
4835
  justify-content: center;
4705
4836
  flex-shrink: 0;
4837
+ border-radius: 50%;
4838
+ overflow: hidden;
4839
+ /* Ring in the row's surface color so overlapping marks read cleanly. */
4840
+ box-shadow: 0 0 0 1.5px var(--rs-background-secondary);
4841
+ }
4842
+
4843
+ /* Overlap each subsequent mark for the stacked-cluster look. */
4844
+ .rs-list-row-meta-icons > * + * {
4845
+ margin-left: -6px;
4706
4846
  }
4707
4847
 
4708
4848
  .rs-list-row-meta-icons img,
@@ -4712,6 +4852,19 @@
4712
4852
  display: block;
4713
4853
  }
4714
4854
 
4855
+ /* Card-network chips: wider rounded tiles rather than circles. */
4856
+ .rs-list-row-meta-icons--cards > * {
4857
+ width: 26px;
4858
+ height: 18px;
4859
+ border-radius: 3px;
4860
+ overflow: visible;
4861
+ box-shadow: none;
4862
+ }
4863
+
4864
+ .rs-list-row-meta-icons--cards > * + * {
4865
+ margin-left: -4px;
4866
+ }
4867
+
4715
4868
  .rs-list-row-chevron {
4716
4869
  flex-shrink: 0;
4717
4870
  width: 16px;
@@ -4794,14 +4947,14 @@
4794
4947
  color: var(--rs-muted);
4795
4948
  }
4796
4949
 
4797
- /* Iframe wrap sized to Swapped's documented dimensions — 400×482 for the
4950
+ /* Iframe wrap sized to Swapped's documented dimensions — 400×586 for the
4798
4951
  fiat on-ramp, 445×585 for Connect (overrides below). Centered horizontally
4799
4952
  inside the modal so the step body can have header padding. */
4800
4953
  .rs-fiat-onramp-iframe-wrap {
4801
4954
  position: relative;
4802
4955
  width: 100%;
4803
4956
  max-width: 400px;
4804
- min-height: 482px;
4957
+ min-height: 586px;
4805
4958
  margin: 0 auto;
4806
4959
  border-radius: var(--rs-radius);
4807
4960
  overflow: hidden;
@@ -4815,8 +4968,8 @@
4815
4968
  .rs-fiat-onramp-iframe {
4816
4969
  display: block;
4817
4970
  width: 100%;
4818
- height: 482px;
4819
- min-height: 482px;
4971
+ height: 586px;
4972
+ min-height: 586px;
4820
4973
  border: 0;
4821
4974
  background: var(--rs-background);
4822
4975
  }
@@ -4826,6 +4979,51 @@
4826
4979
  min-height: 585px;
4827
4980
  }
4828
4981
 
4982
+ /* Finalising deposit — compact centered spinner screen (Swapped Connect). */
4983
+ .rs-finalising-body {
4984
+ display: flex;
4985
+ flex-direction: column;
4986
+ align-items: center;
4987
+ justify-content: center;
4988
+ gap: 24px;
4989
+ padding: 32px 0 24px;
4990
+ text-align: center;
4991
+ }
4992
+
4993
+ .rs-finalising-spinner {
4994
+ display: inline-flex;
4995
+ color: var(--color-blue10);
4996
+ }
4997
+
4998
+ .rs-finalising-spinner .rs-spinner {
4999
+ width: 56px;
5000
+ height: 56px;
5001
+ }
5002
+
5003
+ .rs-finalising-text {
5004
+ display: flex;
5005
+ flex-direction: column;
5006
+ align-items: center;
5007
+ gap: 6px;
5008
+ }
5009
+
5010
+ .rs-finalising-title {
5011
+ font-size: 16px;
5012
+ font-weight: 700;
5013
+ line-height: 1.2;
5014
+ color: var(--rs-foreground);
5015
+ margin: 0;
5016
+ }
5017
+
5018
+ .rs-finalising-subtitle {
5019
+ font-size: 14px;
5020
+ font-weight: 500;
5021
+ line-height: 1.4;
5022
+ color: var(--rs-muted);
5023
+ margin: 0;
5024
+ max-width: 280px;
5025
+ }
5026
+
4829
5027
  .rs-fiat-onramp-loading,
4830
5028
  .rs-fiat-onramp-error {
4831
5029
  position: absolute;
@@ -4863,7 +5061,7 @@
4863
5061
 
4864
5062
  .rs-exchange-grid {
4865
5063
  display: grid;
4866
- grid-template-columns: repeat(2, minmax(0, 1fr));
5064
+ grid-template-columns: repeat(3, minmax(0, 1fr));
4867
5065
  gap: 8px;
4868
5066
  }
4869
5067
 
@@ -4917,6 +5115,17 @@
4917
5115
  object-fit: contain;
4918
5116
  }
4919
5117
 
5118
+ /* Bundled branded logos fill the tile edge-to-edge (their own brand-colour
5119
+ background), clipped to the tile's rounded corners. */
5120
+ .rs-exchange-card-logo--brand {
5121
+ background: transparent;
5122
+ }
5123
+
5124
+ .rs-exchange-card-logo--brand svg {
5125
+ width: 100%;
5126
+ height: 100%;
5127
+ }
5128
+
4920
5129
  .rs-exchange-card-name {
4921
5130
  width: 100%;
4922
5131
  min-width: 0;
@@ -4951,12 +5160,12 @@
4951
5160
  Modal sizing for the Swapped iframe step
4952
5161
  =============================================================================
4953
5162
  Modal stays at the default 400px width for the fiat variant (matches
4954
- Swapped's 400×482 iframe edge-to-edge). Connect needs 445px because its
5163
+ Swapped's 400×586 iframe edge-to-edge). Connect needs 445px because its
4955
5164
  iframe is 445×585. Height grows with the Rhinestone chrome (header
4956
5165
  icon/title/subtitle + iframe + PoweredBy); cap to viewport so smaller
4957
5166
  laptops get a scrollable modal-body instead of overflowing the screen. */
4958
5167
 
4959
- /* Connect's iframe is 445×585 (vs fiat's 400×482). To preserve the same
5168
+ /* Connect's iframe is 445×585 (vs fiat's 400×586). To preserve the same
4960
5169
  12px horizontal padding as ConnectStep while still giving Swapped's
4961
5170
  Connect iframe its documented width, widen the modal by 24px (12 each
4962
5171
  side) → 469px. Applied from the moment the user enters exchange-connect
@@ -4992,7 +5201,7 @@
4992
5201
  when the iframe→tracker phase swap fires. */
4993
5202
  .rs-modal-content:has(.rs-modal-body[data-flow-mode="fiat-onramp"][data-step-type="setup"]),
4994
5203
  .rs-modal-content:has(.rs-modal-body[data-flow-mode="fiat-onramp"] .rs-fiat-onramp) {
4995
- min-height: 691px;
5204
+ min-height: 795px;
4996
5205
  }
4997
5206
  .rs-modal-content:has(.rs-modal-body[data-flow-mode="exchange-connect"][data-step-type="setup"]),
4998
5207
  .rs-modal-content:has(.rs-modal-body[data-flow-mode="exchange-connect"] .rs-fiat-onramp) {
@@ -231,7 +231,7 @@ interface DepositModalProps {
231
231
  */
232
232
  fiatOnrampMethods?: FiatPaymentMethodOption[];
233
233
  /**
234
- * Show a "Fund from Exchange" row that opens Swapped Connect — the user
234
+ * Show a "Connect exchange" row that opens Swapped Connect — the user
235
235
  * picks their CEX (Coinbase, Binance, Kraken…) or wallet inside the iframe
236
236
  * and Swapped pulls the crypto on-chain to the smart account. Default: false.
237
237
  */
@@ -231,7 +231,7 @@ interface DepositModalProps {
231
231
  */
232
232
  fiatOnrampMethods?: FiatPaymentMethodOption[];
233
233
  /**
234
- * Show a "Fund from Exchange" row that opens Swapped Connect — the user
234
+ * Show a "Connect exchange" row that opens Swapped Connect — the user
235
235
  * picks their CEX (Coinbase, Binance, Kraken…) or wallet inside the iframe
236
236
  * and Swapped pulls the crypto on-chain to the smart account. Default: false.
237
237
  */
package/dist/withdraw.cjs CHANGED
@@ -1,9 +1,9 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _chunkLEL6GMEQcjs = require('./chunk-LEL6GMEQ.cjs');
4
- require('./chunk-MQIJZNTP.cjs');
5
- require('./chunk-AJHFNHG3.cjs');
6
- require('./chunk-MILJQWPT.cjs');
3
+ var _chunkAE5LHTPMcjs = require('./chunk-AE5LHTPM.cjs');
4
+ require('./chunk-OQVLEVNR.cjs');
5
+ require('./chunk-UEKPBRBY.cjs');
6
+ require('./chunk-ABVRVW3P.cjs');
7
7
 
8
8
 
9
- exports.WithdrawModal = _chunkLEL6GMEQcjs.WithdrawModal;
9
+ exports.WithdrawModal = _chunkAE5LHTPMcjs.WithdrawModal;
@@ -1,6 +1,6 @@
1
1
  import * as react from 'react';
2
- import { n as WithdrawModalProps } from './types-RzfAD14B.cjs';
3
- export { A as AssetOption, a as ConnectedEventData, E as ErrorEventData, S as SafeTransactionRequest, k as WithdrawCompleteEventData, l as WithdrawFailedEventData, o as WithdrawSubmittedEventData } from './types-RzfAD14B.cjs';
2
+ import { n as WithdrawModalProps } from './types-CFRuisqK.cjs';
3
+ export { A as AssetOption, a as ConnectedEventData, E as ErrorEventData, S as SafeTransactionRequest, k as WithdrawCompleteEventData, l as WithdrawFailedEventData, o as WithdrawSubmittedEventData } from './types-CFRuisqK.cjs';
4
4
  import 'viem';
5
5
 
6
6
  declare function WithdrawModal(props: WithdrawModalProps): react.JSX.Element;
@@ -1,6 +1,6 @@
1
1
  import * as react from 'react';
2
- import { n as WithdrawModalProps } from './types-RzfAD14B.js';
3
- export { A as AssetOption, a as ConnectedEventData, E as ErrorEventData, S as SafeTransactionRequest, k as WithdrawCompleteEventData, l as WithdrawFailedEventData, o as WithdrawSubmittedEventData } from './types-RzfAD14B.js';
2
+ import { n as WithdrawModalProps } from './types-CFRuisqK.js';
3
+ export { A as AssetOption, a as ConnectedEventData, E as ErrorEventData, S as SafeTransactionRequest, k as WithdrawCompleteEventData, l as WithdrawFailedEventData, o as WithdrawSubmittedEventData } from './types-CFRuisqK.js';
4
4
  import 'viem';
5
5
 
6
6
  declare function WithdrawModal(props: WithdrawModalProps): react.JSX.Element;
package/dist/withdraw.mjs CHANGED
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  WithdrawModal
3
- } from "./chunk-DZQD3DAV.mjs";
4
- import "./chunk-3C35DVPE.mjs";
5
- import "./chunk-TQ2AYMWS.mjs";
6
- import "./chunk-6YRDD462.mjs";
3
+ } from "./chunk-WCIGOV34.mjs";
4
+ import "./chunk-GKC22JC4.mjs";
5
+ import "./chunk-F7P4MV72.mjs";
6
+ import "./chunk-WJX3TJFK.mjs";
7
7
  export {
8
8
  WithdrawModal
9
9
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rhinestone/deposit-modal",
3
- "version": "0.3.1",
3
+ "version": "0.4.0",
4
4
  "description": "React modal component for Rhinestone cross-chain deposits",
5
5
  "author": "Rhinestone <dev@rhinestone.wtf>",
6
6
  "bugs": {