@unifold/connect-react 0.1.34 → 0.1.36

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.
package/dist/index.mjs CHANGED
@@ -1218,7 +1218,14 @@ function useUnifold() {
1218
1218
  }
1219
1219
 
1220
1220
  // ../ui-react/dist/index.mjs
1221
- import { useState as useState26, useEffect as useEffect20, useCallback as useCallback32 } from "react";
1221
+ import {
1222
+ useState as useState26,
1223
+ useEffect as useEffect20,
1224
+ useLayoutEffect as useLayoutEffect22,
1225
+ useCallback as useCallback32,
1226
+ useRef as useRef52,
1227
+ useMemo as useMemo82
1228
+ } from "react";
1222
1229
 
1223
1230
  // ../../node_modules/.pnpm/lucide-react@0.454.0_react@18.3.1/node_modules/lucide-react/dist/esm/createLucideIcon.js
1224
1231
  import { forwardRef as forwardRef2, createElement as createElement2 } from "react";
@@ -11904,24 +11911,34 @@ function CurrencyModal({
11904
11911
  onClose: handleClose
11905
11912
  }
11906
11913
  ),
11907
- /* @__PURE__ */ jsx62("div", { className: "", children: /* @__PURE__ */ jsx62("div", { className: "uf-relative", children: /* @__PURE__ */ jsx62(
11908
- "input",
11909
- {
11910
- type: "text",
11911
- value: searchQuery,
11912
- onChange: (e) => setSearchQuery(e.target.value),
11913
- placeholder: "Search",
11914
- className: "uf-w-full uf-px-4 uf-py-2.5 uf-text-sm uf-outline-none focus:uf-ring-2 focus:uf-ring-ring/30",
11915
- style: {
11916
- backgroundColor: components.search.backgroundColor,
11917
- color: components.search.inputColor,
11918
- fontFamily: fonts.regular,
11919
- borderRadius: components.input.borderRadius,
11920
- border: `${components.input.borderWidth}px solid ${components.input.borderColor}`
11914
+ /* @__PURE__ */ jsxs5("div", { className: "uf-pb-2", children: [
11915
+ /* @__PURE__ */ jsx62(
11916
+ "style",
11917
+ {
11918
+ dangerouslySetInnerHTML: {
11919
+ __html: `.uf-currency-modal-search::placeholder { color: ${components.search.placeholderColor}; }`
11920
+ }
11921
11921
  }
11922
- }
11923
- ) }) }),
11924
- /* @__PURE__ */ jsx62("div", { className: "uf-flex-1 sm:uf-flex-none uf-overflow-y-auto uf-pb-6 [scrollbar-width:none] [&::-webkit-scrollbar]:uf-hidden sm:uf-min-h-[200px] sm:uf-max-h-[400px]", children: /* @__PURE__ */ jsxs5("div", { className: "uf-space-y-2", children: [
11922
+ ),
11923
+ /* @__PURE__ */ jsx62("div", { className: "uf-relative", children: /* @__PURE__ */ jsx62(
11924
+ "input",
11925
+ {
11926
+ type: "text",
11927
+ value: searchQuery,
11928
+ onChange: (e) => setSearchQuery(e.target.value),
11929
+ placeholder: "Search",
11930
+ className: "uf-currency-modal-search uf-w-full uf-p-4 uf-text-sm uf-outline-none focus:uf-ring-2 focus:uf-ring-ring/30",
11931
+ style: {
11932
+ backgroundColor: components.search.backgroundColor,
11933
+ color: components.search.inputColor,
11934
+ fontFamily: fonts.regular,
11935
+ borderRadius: components.input.borderRadius,
11936
+ border: `${components.input.borderWidth}px solid ${components.input.borderColor}`
11937
+ }
11938
+ }
11939
+ ) })
11940
+ ] }),
11941
+ /* @__PURE__ */ jsx62("div", { className: "uf-flex-1 sm:uf-flex-none uf-overflow-y-auto uf-pb-4 [scrollbar-width:none] [&::-webkit-scrollbar]:uf-hidden sm:uf-min-h-[200px] sm:uf-max-h-[400px]", children: /* @__PURE__ */ jsxs5("div", { className: "uf-space-y-2", children: [
11925
11942
  /* @__PURE__ */ jsx62(
11926
11943
  CurrencyListSection,
11927
11944
  {
@@ -12443,188 +12460,153 @@ function DepositDetailContent({ execution }) {
12443
12460
  className: "uf-overflow-hidden uf-mb-3",
12444
12461
  style: { backgroundColor: components.card.backgroundColor, borderRadius: components.card.borderRadius, border: `${components.card.borderWidth}px solid ${components.card.borderColor}` },
12445
12462
  children: [
12446
- /* @__PURE__ */ jsxs6(
12447
- "div",
12448
- {
12449
- className: "uf-flex uf-justify-between uf-items-center uf-px-4 uf-py-3 uf-border-b",
12450
- style: { borderColor: colors2.border },
12451
- children: [
12452
- /* @__PURE__ */ jsx72(
12453
- "span",
12454
- {
12455
- className: "uf-text-sm",
12456
- style: {
12457
- color: components.card.labelColor,
12458
- fontFamily: fonts.regular
12459
- },
12460
- children: "Amount Sent"
12461
- }
12462
- ),
12463
- /* @__PURE__ */ jsxs6(
12464
- "span",
12465
- {
12466
- style: {
12467
- color: components.card.titleColor,
12468
- fontFamily: fonts.regular,
12469
- fontSize: "14px"
12470
- },
12471
- children: [
12472
- formatAmount(
12473
- execution.source_amount_base_unit,
12474
- execution.source_token_metadata?.decimals
12475
- ),
12476
- " ",
12477
- formatCurrency(execution.source_currency)
12478
- ]
12479
- }
12480
- )
12481
- ]
12482
- }
12483
- ),
12484
- /* @__PURE__ */ jsxs6(
12485
- "div",
12486
- {
12487
- className: "uf-flex uf-justify-between uf-items-center uf-px-4 uf-py-3 uf-border-b",
12488
- style: { borderColor: colors2.border },
12489
- children: [
12490
- /* @__PURE__ */ jsx72(
12491
- "span",
12492
- {
12493
- className: "uf-text-sm",
12494
- style: {
12495
- color: components.card.labelColor,
12496
- fontFamily: fonts.regular
12497
- },
12498
- children: "Amount Received"
12499
- }
12500
- ),
12501
- /* @__PURE__ */ jsxs6(
12502
- "span",
12503
- {
12504
- style: {
12505
- color: components.card.titleColor,
12506
- fontFamily: fonts.regular,
12507
- fontSize: "14px"
12508
- },
12509
- children: [
12510
- formatAmount(
12511
- execution.destination_amount_base_unit,
12512
- execution.destination_token_metadata?.decimals
12513
- ),
12514
- " ",
12515
- formatCurrency(execution.destination_currency)
12516
- ]
12517
- }
12518
- )
12519
- ]
12520
- }
12521
- ),
12522
- /* @__PURE__ */ jsxs6(
12523
- "div",
12524
- {
12525
- className: "uf-flex uf-justify-between uf-items-center uf-px-4 uf-py-3 uf-border-b",
12526
- style: { borderColor: colors2.border },
12527
- children: [
12528
- /* @__PURE__ */ jsx72(
12529
- "span",
12530
- {
12531
- className: "uf-text-sm",
12532
- style: {
12533
- color: components.card.labelColor,
12534
- fontFamily: fonts.regular
12535
- },
12536
- children: "USD Value"
12537
- }
12538
- ),
12539
- /* @__PURE__ */ jsx72(
12540
- "span",
12541
- {
12542
- style: {
12543
- color: components.card.titleColor,
12544
- fontFamily: fonts.regular,
12545
- fontSize: "14px"
12546
- },
12547
- children: formatUsdAmount2(
12548
- execution.source_amount_usd,
12549
- execution.source_amount_base_unit
12550
- )
12551
- }
12552
- )
12553
- ]
12554
- }
12555
- ),
12556
- isPending && /* @__PURE__ */ jsxs6(
12557
- "div",
12558
- {
12559
- className: "uf-flex uf-justify-between uf-items-center uf-px-4 uf-py-3 uf-border-b",
12560
- style: { borderColor: colors2.border },
12561
- children: [
12562
- /* @__PURE__ */ jsx72(
12563
- "span",
12564
- {
12565
- className: "uf-text-sm",
12566
- style: {
12567
- color: components.card.labelColor,
12568
- fontFamily: fonts.regular
12569
- },
12570
- children: "Estimated delivery time"
12571
- }
12572
- ),
12573
- /* @__PURE__ */ jsx72(
12574
- "span",
12575
- {
12576
- style: {
12577
- color: components.card.titleColor,
12578
- fontFamily: fonts.regular,
12579
- fontSize: "14px"
12580
- },
12581
- children: formatEstimatedTime(execution?.estimated_processing_time)
12582
- }
12463
+ /* @__PURE__ */ jsxs6("div", { className: "uf-flex uf-justify-between uf-items-center uf-px-4 uf-py-3", children: [
12464
+ /* @__PURE__ */ jsx72(
12465
+ "span",
12466
+ {
12467
+ className: "uf-text-sm",
12468
+ style: {
12469
+ color: components.card.rowLeftLabel,
12470
+ fontFamily: fonts.regular
12471
+ },
12472
+ children: "Amount Sent"
12473
+ }
12474
+ ),
12475
+ /* @__PURE__ */ jsxs6(
12476
+ "span",
12477
+ {
12478
+ style: {
12479
+ color: components.card.rowRightLabel,
12480
+ fontFamily: fonts.regular,
12481
+ fontSize: "14px"
12482
+ },
12483
+ children: [
12484
+ formatAmount(
12485
+ execution.source_amount_base_unit,
12486
+ execution.source_token_metadata?.decimals
12487
+ ),
12488
+ " ",
12489
+ formatCurrency(execution.source_currency)
12490
+ ]
12491
+ }
12492
+ )
12493
+ ] }),
12494
+ /* @__PURE__ */ jsxs6("div", { className: "uf-flex uf-justify-between uf-items-center uf-px-4 uf-py-3", children: [
12495
+ /* @__PURE__ */ jsx72(
12496
+ "span",
12497
+ {
12498
+ className: "uf-text-sm",
12499
+ style: {
12500
+ color: components.card.rowLeftLabel,
12501
+ fontFamily: fonts.regular
12502
+ },
12503
+ children: "Amount Received"
12504
+ }
12505
+ ),
12506
+ /* @__PURE__ */ jsxs6(
12507
+ "span",
12508
+ {
12509
+ style: {
12510
+ color: components.card.rowRightLabel,
12511
+ fontFamily: fonts.regular,
12512
+ fontSize: "14px"
12513
+ },
12514
+ children: [
12515
+ formatAmount(
12516
+ execution.destination_amount_base_unit,
12517
+ execution.destination_token_metadata?.decimals
12518
+ ),
12519
+ " ",
12520
+ formatCurrency(execution.destination_currency)
12521
+ ]
12522
+ }
12523
+ )
12524
+ ] }),
12525
+ /* @__PURE__ */ jsxs6("div", { className: "uf-flex uf-justify-between uf-items-center uf-px-4 uf-py-3", children: [
12526
+ /* @__PURE__ */ jsx72(
12527
+ "span",
12528
+ {
12529
+ className: "uf-text-sm",
12530
+ style: {
12531
+ color: components.card.rowLeftLabel,
12532
+ fontFamily: fonts.regular
12533
+ },
12534
+ children: "USD Value"
12535
+ }
12536
+ ),
12537
+ /* @__PURE__ */ jsx72(
12538
+ "span",
12539
+ {
12540
+ style: {
12541
+ color: components.card.rowRightLabel,
12542
+ fontFamily: fonts.regular,
12543
+ fontSize: "14px"
12544
+ },
12545
+ children: formatUsdAmount2(
12546
+ execution.source_amount_usd,
12547
+ execution.source_amount_base_unit
12583
12548
  )
12584
- ]
12585
- }
12586
- ),
12587
- /* @__PURE__ */ jsxs6(
12588
- "div",
12589
- {
12590
- className: "uf-flex uf-justify-between uf-items-center uf-px-4 uf-py-3 uf-border-b",
12591
- style: { borderColor: colors2.border },
12592
- children: [
12593
- /* @__PURE__ */ jsx72(
12594
- "span",
12595
- {
12596
- className: "uf-text-sm",
12597
- style: {
12598
- color: components.card.labelColor,
12599
- fontFamily: fonts.regular
12600
- },
12601
- children: "Source Network"
12602
- }
12603
- ),
12604
- /* @__PURE__ */ jsx72(
12605
- "span",
12606
- {
12607
- style: {
12608
- color: components.card.titleColor,
12609
- fontFamily: fonts.regular,
12610
- fontSize: "14px"
12611
- },
12612
- children: getNetworkName(
12613
- execution.source_chain_type,
12614
- execution.source_chain_id
12615
- )
12616
- }
12549
+ }
12550
+ )
12551
+ ] }),
12552
+ isPending && /* @__PURE__ */ jsxs6("div", { className: "uf-flex uf-justify-between uf-items-center uf-px-4 uf-py-3", children: [
12553
+ /* @__PURE__ */ jsx72(
12554
+ "span",
12555
+ {
12556
+ className: "uf-text-sm",
12557
+ style: {
12558
+ color: components.card.rowLeftLabel,
12559
+ fontFamily: fonts.regular
12560
+ },
12561
+ children: "Estimated delivery time"
12562
+ }
12563
+ ),
12564
+ /* @__PURE__ */ jsx72(
12565
+ "span",
12566
+ {
12567
+ style: {
12568
+ color: components.card.rowRightLabel,
12569
+ fontFamily: fonts.regular,
12570
+ fontSize: "14px"
12571
+ },
12572
+ children: formatEstimatedTime(execution?.estimated_processing_time)
12573
+ }
12574
+ )
12575
+ ] }),
12576
+ /* @__PURE__ */ jsxs6("div", { className: "uf-flex uf-justify-between uf-items-center uf-px-4 uf-py-3", children: [
12577
+ /* @__PURE__ */ jsx72(
12578
+ "span",
12579
+ {
12580
+ className: "uf-text-sm",
12581
+ style: {
12582
+ color: components.card.rowLeftLabel,
12583
+ fontFamily: fonts.regular
12584
+ },
12585
+ children: "Source Network"
12586
+ }
12587
+ ),
12588
+ /* @__PURE__ */ jsx72(
12589
+ "span",
12590
+ {
12591
+ style: {
12592
+ color: components.card.rowRightLabel,
12593
+ fontFamily: fonts.regular,
12594
+ fontSize: "14px"
12595
+ },
12596
+ children: getNetworkName(
12597
+ execution.source_chain_type,
12598
+ execution.source_chain_id
12617
12599
  )
12618
- ]
12619
- }
12620
- ),
12600
+ }
12601
+ )
12602
+ ] }),
12621
12603
  /* @__PURE__ */ jsxs6("div", { className: "uf-flex uf-justify-between uf-items-center uf-px-4 uf-py-3", children: [
12622
12604
  /* @__PURE__ */ jsx72(
12623
12605
  "span",
12624
12606
  {
12625
12607
  className: "uf-text-sm",
12626
12608
  style: {
12627
- color: components.card.labelColor,
12609
+ color: components.card.rowLeftLabel,
12628
12610
  fontFamily: fonts.regular
12629
12611
  },
12630
12612
  children: "Destination Network"
@@ -12634,7 +12616,7 @@ function DepositDetailContent({ execution }) {
12634
12616
  "span",
12635
12617
  {
12636
12618
  style: {
12637
- color: components.card.titleColor,
12619
+ color: components.card.rowRightLabel,
12638
12620
  fontFamily: fonts.regular,
12639
12621
  fontSize: "14px"
12640
12622
  },
@@ -12676,15 +12658,14 @@ function DepositDetailContent({ execution }) {
12676
12658
  href: execution.explorer_url,
12677
12659
  target: "_blank",
12678
12660
  rel: "noopener noreferrer",
12679
- className: "uf-grid uf-grid-cols-[auto_1fr_auto] uf-items-center uf-gap-2 uf-px-4 uf-py-3 uf-border-b hover:uf-bg-card/50 uf-transition-colors",
12680
- style: { borderColor: colors2.border },
12661
+ className: "uf-grid uf-grid-cols-[auto_1fr_auto] uf-items-center uf-gap-2 uf-px-4 uf-py-3 hover:uf-bg-card/50 uf-transition-colors",
12681
12662
  children: [
12682
12663
  /* @__PURE__ */ jsx72(
12683
12664
  "div",
12684
12665
  {
12685
12666
  className: "uf-text-sm",
12686
12667
  style: {
12687
- color: components.card.labelColor,
12668
+ color: components.card.rowLeftLabel,
12688
12669
  fontFamily: fonts.regular
12689
12670
  },
12690
12671
  children: "Deposit Tx"
@@ -12695,7 +12676,7 @@ function DepositDetailContent({ execution }) {
12695
12676
  {
12696
12677
  className: "uf-text-sm uf-text-right",
12697
12678
  style: {
12698
- color: components.card.titleColor,
12679
+ color: components.card.rowRightLabel,
12699
12680
  fontFamily: fonts.regular
12700
12681
  },
12701
12682
  children: formatTransactionHash(execution.transaction_hash)
@@ -12705,7 +12686,7 @@ function DepositDetailContent({ execution }) {
12705
12686
  ExternalLink,
12706
12687
  {
12707
12688
  className: "uf-w-3.5 uf-h-3.5 uf-block",
12708
- style: { color: components.card.actionColor }
12689
+ style: { color: components.card.actionIcon }
12709
12690
  }
12710
12691
  )
12711
12692
  ]
@@ -12724,7 +12705,7 @@ function DepositDetailContent({ execution }) {
12724
12705
  {
12725
12706
  className: "uf-text-sm",
12726
12707
  style: {
12727
- color: components.card.labelColor,
12708
+ color: components.card.rowLeftLabel,
12728
12709
  fontFamily: fonts.regular
12729
12710
  },
12730
12711
  children: "Completion Tx"
@@ -12735,7 +12716,7 @@ function DepositDetailContent({ execution }) {
12735
12716
  {
12736
12717
  className: "uf-text-sm uf-text-right",
12737
12718
  style: {
12738
- color: components.card.titleColor,
12719
+ color: components.card.rowRightLabel,
12739
12720
  fontFamily: fonts.regular
12740
12721
  },
12741
12722
  children: formatTransactionHash(
@@ -12747,7 +12728,7 @@ function DepositDetailContent({ execution }) {
12747
12728
  ExternalLink,
12748
12729
  {
12749
12730
  className: "uf-w-3.5 uf-h-3.5 uf-block",
12750
- style: { color: components.card.actionColor }
12731
+ style: { color: components.card.actionIcon }
12751
12732
  }
12752
12733
  )
12753
12734
  ]
@@ -13506,25 +13487,28 @@ function BuyWithCard({
13506
13487
  }
13507
13488
  }
13508
13489
  ) }) }),
13509
- selectedCurrencyData?.suggested_amounts && selectedCurrencyData.suggested_amounts.length > 0 && /* @__PURE__ */ jsx102("div", { className: "uf-flex uf-gap-3 uf-justify-center", children: selectedCurrencyData.suggested_amounts.map((quickAmount) => /* @__PURE__ */ jsxs8(
13510
- "button",
13511
- {
13512
- onClick: () => handleQuickAmount(quickAmount),
13513
- className: "uf-w-24 uf-py-2 hover:uf-bg-accent uf-transition-colors uf-text-sm uf-font-medium",
13514
- style: {
13515
- backgroundColor: components.card.backgroundColor,
13516
- color: components.card.titleColor,
13517
- fontFamily: fonts.medium,
13518
- borderRadius: components.card.borderRadius,
13519
- border: `${components.card.borderWidth}px solid ${components.card.borderColor}`
13490
+ selectedCurrencyData?.suggested_amounts && selectedCurrencyData.suggested_amounts.length > 0 && /* @__PURE__ */ jsx102("div", { className: "uf-flex uf-gap-3 uf-justify-center", children: selectedCurrencyData.suggested_amounts.map((quickAmount) => {
13491
+ const isSelected = parseFloat(amount) === quickAmount;
13492
+ return /* @__PURE__ */ jsxs8(
13493
+ "button",
13494
+ {
13495
+ onClick: () => handleQuickAmount(quickAmount),
13496
+ className: "uf-w-24 uf-py-2 hover:uf-bg-accent uf-transition-colors uf-text-sm uf-font-medium",
13497
+ style: {
13498
+ backgroundColor: components.card.backgroundColor,
13499
+ color: components.card.titleColor,
13500
+ fontFamily: fonts.medium,
13501
+ borderRadius: components.card.borderRadius,
13502
+ border: `${components.card.borderWidth}px solid ${isSelected ? colors2.primary : components.card.borderColor}`
13503
+ },
13504
+ children: [
13505
+ getCurrencySymbol(currency),
13506
+ quickAmount.toLocaleString()
13507
+ ]
13520
13508
  },
13521
- children: [
13522
- getCurrencySymbol(currency),
13523
- quickAmount.toLocaleString()
13524
- ]
13525
- },
13526
- quickAmount
13527
- )) }),
13509
+ quickAmount
13510
+ );
13511
+ }) }),
13528
13512
  amountValidationError && /* @__PURE__ */ jsx102(
13529
13513
  "div",
13530
13514
  {
@@ -13543,7 +13527,7 @@ function BuyWithCard({
13543
13527
  "span",
13544
13528
  {
13545
13529
  style: {
13546
- color: components.card.headerColor,
13530
+ color: components.card.labelColor,
13547
13531
  fontFamily: fonts.medium
13548
13532
  },
13549
13533
  children: "Provider"
@@ -13602,7 +13586,7 @@ function BuyWithCard({
13602
13586
  {
13603
13587
  className: "uf-text-xs uf-font-normal uf-mb-2",
13604
13588
  style: {
13605
- color: components.card.labelColor,
13589
+ color: components.card.headerColor,
13606
13590
  fontFamily: fonts.regular
13607
13591
  },
13608
13592
  children: "Auto-picked for you"
@@ -13717,8 +13701,8 @@ function BuyWithCard({
13717
13701
  /* @__PURE__ */ jsx102(
13718
13702
  "div",
13719
13703
  {
13720
- className: `uf-transition-all uf-duration-300 uf-min-h-[420px] ${showQuotesView && !showOnrampView ? "uf-opacity-100" : "uf-opacity-0 uf-pointer-events-none uf-absolute uf-inset-0"}`,
13721
- children: /* @__PURE__ */ jsx102("div", { className: "uf-space-y-2 uf-pt-2", children: sortedQuotes.map((quote, index2) => {
13704
+ className: `uf-transition-all uf-duration-300 uf-min-h-[420px] uf-flex uf-flex-col ${showQuotesView && !showOnrampView ? "uf-opacity-100" : "uf-opacity-0 uf-pointer-events-none uf-absolute uf-inset-0"}`,
13705
+ children: /* @__PURE__ */ jsx102("div", { className: "uf-space-y-2 uf-pt-2 uf-pb-8 uf-overflow-y-auto uf-flex-1 uf-min-h-0", children: sortedQuotes.map((quote, index2) => {
13722
13706
  const badges = getProviderBadges(quote, sortedQuotes);
13723
13707
  const displayName = quote.service_provider_display_name;
13724
13708
  const isSelected = selectedProvider?.service_provider === quote.service_provider;
@@ -13735,11 +13719,11 @@ function BuyWithCard({
13735
13719
  },
13736
13720
  onMouseEnter: () => setHoveredProviderIndex(index2),
13737
13721
  onMouseLeave: () => setHoveredProviderIndex(null),
13738
- className: `uf-w-full uf-transition-colors uf-p-3 uf-flex uf-items-center uf-justify-between uf-group ${isSelected ? "uf-ring-2 uf-ring-inset uf-ring-primary" : ""}`,
13722
+ className: "uf-w-full uf-transition-colors uf-p-3 uf-flex uf-items-center uf-justify-between uf-group",
13739
13723
  style: {
13740
13724
  backgroundColor: hoveredProviderIndex === index2 ? colors2.cardHover : components.card.backgroundColor,
13741
13725
  borderRadius: components.card.borderRadius,
13742
- border: `${components.card.borderWidth}px solid ${components.card.borderColor}`
13726
+ border: isSelected ? `2px solid ${colors2.primary}` : `${components.card.borderWidth}px solid ${components.card.borderColor}`
13743
13727
  },
13744
13728
  children: [
13745
13729
  /* @__PURE__ */ jsxs8("div", { className: "uf-flex uf-items-center uf-gap-3", children: [
@@ -13766,7 +13750,8 @@ function BuyWithCard({
13766
13750
  badges.map((badge, i) => /* @__PURE__ */ jsxs8(
13767
13751
  "span",
13768
13752
  {
13769
- className: "uf-text-[10px] uf-text-green-400 uf-font-normal",
13753
+ className: "uf-text-[10px] uf-font-normal",
13754
+ style: { color: colors2.success },
13770
13755
  children: [
13771
13756
  badge,
13772
13757
  i < badges.length - 1 && ","
@@ -13774,8 +13759,25 @@ function BuyWithCard({
13774
13759
  },
13775
13760
  i
13776
13761
  )),
13777
- quote.low_kyc === false && badges.length > 0 && /* @__PURE__ */ jsx102("span", { className: "uf-text-[10px] uf-text-muted-foreground", children: "\u2022" }),
13778
- quote.low_kyc === false && /* @__PURE__ */ jsx102("span", { className: "uf-text-[10px] uf-text-muted-foreground uf-font-normal", children: "No document upload" })
13762
+ quote.low_kyc === false && badges.length > 0 && /* @__PURE__ */ jsx102(
13763
+ "span",
13764
+ {
13765
+ className: "uf-text-[10px]",
13766
+ style: { color: components.card.subtextRightColor },
13767
+ children: "\u2022"
13768
+ }
13769
+ ),
13770
+ quote.low_kyc === false && /* @__PURE__ */ jsx102(
13771
+ "span",
13772
+ {
13773
+ className: "uf-text-[10px] uf-font-normal",
13774
+ style: {
13775
+ color: components.card.subtextRightColor,
13776
+ fontFamily: fonts.regular
13777
+ },
13778
+ children: "No document upload"
13779
+ }
13780
+ )
13779
13781
  ] })
13780
13782
  ] })
13781
13783
  ] }),
@@ -13876,7 +13878,7 @@ function BuyWithCard({
13876
13878
  }
13877
13879
  )
13878
13880
  ] }),
13879
- /* @__PURE__ */ jsx102("div", { className: "uf-px-1 uf-self-start uf-pt-2", children: /* @__PURE__ */ jsx102(ChevronRight, { className: "uf-w-4 uf-h-4", style: { color: components.card.actionColor } }) }),
13881
+ /* @__PURE__ */ jsx102("div", { className: "uf-px-1 uf-self-start uf-pt-2", children: /* @__PURE__ */ jsx102(ChevronRight, { className: "uf-w-4 uf-h-4", style: { color: components.card.iconColor } }) }),
13880
13882
  /* @__PURE__ */ jsxs8("div", { className: "uf-flex uf-flex-col uf-items-center uf-min-w-[72px]", children: [
13881
13883
  /* @__PURE__ */ jsx102("div", { className: "uf-h-8 uf-flex uf-items-center uf-justify-center uf-mb-1.5", children: /* @__PURE__ */ jsxs8("div", { className: "uf-relative", children: [
13882
13884
  /* @__PURE__ */ jsx102(
@@ -13919,7 +13921,7 @@ function BuyWithCard({
13919
13921
  }
13920
13922
  )
13921
13923
  ] }),
13922
- /* @__PURE__ */ jsx102("div", { className: "uf-px-1 uf-self-start uf-pt-2", children: /* @__PURE__ */ jsx102(ChevronRight, { className: "uf-w-4 uf-h-4", style: { color: components.card.actionColor } }) }),
13924
+ /* @__PURE__ */ jsx102("div", { className: "uf-px-1 uf-self-start uf-pt-2", children: /* @__PURE__ */ jsx102(ChevronRight, { className: "uf-w-4 uf-h-4", style: { color: components.card.iconColor } }) }),
13923
13925
  /* @__PURE__ */ jsxs8("div", { className: "uf-flex uf-flex-col uf-items-center uf-min-w-[72px]", children: [
13924
13926
  /* @__PURE__ */ jsx102("div", { className: "uf-h-8 uf-flex uf-items-center uf-justify-center uf-mb-1.5", children: /* @__PURE__ */ jsxs8("div", { className: "uf-relative", children: [
13925
13927
  /* @__PURE__ */ jsx102(
@@ -14401,7 +14403,7 @@ function DepositExecutionItem({
14401
14403
  {
14402
14404
  className: "uf-font-medium uf-text-sm uf-flex-shrink-0",
14403
14405
  style: {
14404
- color: components.card.titleColor,
14406
+ color: components.card.textRightColor,
14405
14407
  fontFamily: fonts.medium
14406
14408
  },
14407
14409
  children: formatUsdAmount2(execution.source_amount_usd || "0")
@@ -14450,7 +14452,7 @@ function TransferCryptoButton({
14450
14452
  Zap,
14451
14453
  {
14452
14454
  className: "uf-w-5 uf-h-5",
14453
- style: { color: colors2.foregroundMuted }
14455
+ style: { color: components.card.iconColor }
14454
14456
  }
14455
14457
  ) }),
14456
14458
  /* @__PURE__ */ jsxs11("div", { className: "uf-text-left", children: [
@@ -14537,7 +14539,7 @@ function DepositWithCardButton({
14537
14539
  CreditCard,
14538
14540
  {
14539
14541
  className: "uf-w-5 uf-h-5",
14540
- style: { color: colors2.foregroundMuted }
14542
+ style: { color: components.card.iconColor }
14541
14543
  }
14542
14544
  ) }),
14543
14545
  /* @__PURE__ */ jsxs12("div", { className: "uf-text-left", children: [
@@ -14630,7 +14632,7 @@ function PayWithExchangeButton({
14630
14632
  ArrowLeftRight,
14631
14633
  {
14632
14634
  className: "uf-w-5 uf-h-5",
14633
- style: { color: colors2.foregroundMuted }
14635
+ style: { color: components.card.iconColor }
14634
14636
  }
14635
14637
  ) }),
14636
14638
  /* @__PURE__ */ jsxs13("div", { className: "uf-text-left", children: [
@@ -14717,7 +14719,7 @@ function DepositTrackerButton({
14717
14719
  Clock,
14718
14720
  {
14719
14721
  className: "uf-w-5 uf-h-5",
14720
- style: { color: colors2.foregroundMuted }
14722
+ style: { color: components.card.iconColor }
14721
14723
  }
14722
14724
  ),
14723
14725
  badge !== void 0 && badge > 0 && /* @__PURE__ */ jsx162(
@@ -17547,7 +17549,7 @@ function DepositsModal({
17547
17549
  onClose: handleClose
17548
17550
  }
17549
17551
  ),
17550
- /* @__PURE__ */ jsx33("div", { className: "uf-flex-1 uf-min-h-0 uf-overflow-y-auto [scrollbar-width:none] [&::-webkit-scrollbar]:uf-hidden", children: /* @__PURE__ */ jsx33("div", { className: "uf-space-y-2", children: allExecutions.length === 0 ? /* @__PURE__ */ jsx33("div", { className: "uf-py-8 uf-px-4 uf-text-center", children: /* @__PURE__ */ jsx33(
17552
+ /* @__PURE__ */ jsx33("div", { className: "uf-flex-1 uf-min-h-0 uf-overflow-y-auto [scrollbar-width:none] [&::-webkit-scrollbar]:uf-hidden", children: /* @__PURE__ */ jsx33("div", { className: "uf-space-y-2 uf-pb-8", children: allExecutions.length === 0 ? /* @__PURE__ */ jsx33("div", { className: "uf-py-8 uf-px-4 uf-text-center", children: /* @__PURE__ */ jsx33(
17551
17553
  "div",
17552
17554
  {
17553
17555
  className: "uf-text-sm",
@@ -17741,23 +17743,33 @@ function TokenSelectorSheet({
17741
17743
  ),
17742
17744
  /* @__PURE__ */ jsx34("div", { className: "uf-w-7 uf-h-5 uf-invisible" })
17743
17745
  ] }),
17744
- /* @__PURE__ */ jsx34("div", { className: "uf-pb-3", children: /* @__PURE__ */ jsx34("div", { style: { position: "relative" }, children: /* @__PURE__ */ jsx34(
17745
- "input",
17746
- {
17747
- type: "text",
17748
- placeholder: "Search",
17749
- value: searchQuery,
17750
- onChange: (e) => setSearchQuery(e.target.value),
17751
- className: "uf-w-full uf-px-4 uf-py-2.5 uf-text-sm uf-outline-none focus:uf-ring-2 focus:uf-ring-ring/30",
17752
- style: {
17753
- backgroundColor: components.search.backgroundColor,
17754
- color: components.search.inputColor,
17755
- fontFamily: fonts.regular,
17756
- borderRadius: components.input.borderRadius,
17757
- border: `${components.input.borderWidth}px solid ${components.input.borderColor}`
17746
+ /* @__PURE__ */ jsxs30("div", { className: "uf-pb-3", children: [
17747
+ /* @__PURE__ */ jsx34(
17748
+ "style",
17749
+ {
17750
+ dangerouslySetInnerHTML: {
17751
+ __html: `.uf-token-sheet-search::placeholder { color: ${components.search.placeholderColor}; }`
17752
+ }
17758
17753
  }
17759
- }
17760
- ) }) }),
17754
+ ),
17755
+ /* @__PURE__ */ jsx34("div", { style: { position: "relative" }, children: /* @__PURE__ */ jsx34(
17756
+ "input",
17757
+ {
17758
+ type: "text",
17759
+ placeholder: "Search",
17760
+ value: searchQuery,
17761
+ onChange: (e) => setSearchQuery(e.target.value),
17762
+ className: "uf-token-sheet-search uf-w-full uf-px-4 uf-py-2.5 uf-text-sm uf-outline-none focus:uf-ring-2 focus:uf-ring-ring/30",
17763
+ style: {
17764
+ backgroundColor: components.search.backgroundColor,
17765
+ color: components.search.inputColor,
17766
+ fontFamily: fonts.regular,
17767
+ borderRadius: components.input.borderRadius,
17768
+ border: `${components.input.borderWidth}px solid ${components.input.borderColor}`
17769
+ }
17770
+ }
17771
+ ) })
17772
+ ] }),
17761
17773
  quickSelectOptions.length > 0 && !searchQuery && /* @__PURE__ */ jsxs30("div", { className: "uf-pb-3 uf--mx-6", children: [
17762
17774
  /* @__PURE__ */ jsx34(
17763
17775
  "div",
@@ -18009,12 +18021,13 @@ function TokenSelectorSheet({
18009
18021
  style: {
18010
18022
  fontSize: 12,
18011
18023
  flexShrink: 0,
18012
- color: components.card.labelColor,
18013
18024
  fontFamily: fonts.regular
18014
18025
  },
18015
18026
  children: [
18016
- "Minimum:",
18017
- " ",
18027
+ /* @__PURE__ */ jsxs30("span", { style: { color: components.card.textRightColor }, children: [
18028
+ "Minimum:",
18029
+ " "
18030
+ ] }),
18018
18031
  /* @__PURE__ */ jsxs30("span", { style: { color: components.card.labelHighlightRightColor }, children: [
18019
18032
  "$",
18020
18033
  chain.minimum_deposit_amount_usd
@@ -18090,13 +18103,15 @@ function DepositPollingUi({
18090
18103
  function DepositFooterLinks({
18091
18104
  onGlossaryClick
18092
18105
  }) {
18106
+ const { colors: colors2 } = useTheme();
18093
18107
  return /* @__PURE__ */ jsxs322("div", { className: "uf-flex uf-justify-end uf-items-center uf-gap-2 uf-text-xs uf-text-muted-foreground", children: [
18094
18108
  /* @__PURE__ */ jsx36(
18095
18109
  "a",
18096
18110
  {
18097
18111
  href: "https://unifold.io/terms",
18098
18112
  target: "_blank",
18099
- className: "uf-cursor-pointer hover:uf-text-foreground uf-transition-colors",
18113
+ className: "uf-cursor-pointer hover:uf-opacity-90 uf-transition-colors",
18114
+ style: { color: colors2.primary },
18100
18115
  children: "Terms"
18101
18116
  }
18102
18117
  ),
@@ -18106,7 +18121,8 @@ function DepositFooterLinks({
18106
18121
  {
18107
18122
  href: "https://unifold.io/support",
18108
18123
  target: "_blank",
18109
- className: "uf-cursor-pointer hover:uf-text-foreground uf-transition-colors",
18124
+ className: "uf-cursor-pointer hover:uf-opacity-90 uf-transition-colors",
18125
+ style: { color: colors2.primary },
18110
18126
  children: "Help"
18111
18127
  }
18112
18128
  ),
@@ -18114,8 +18130,9 @@ function DepositFooterLinks({
18114
18130
  /* @__PURE__ */ jsx36(
18115
18131
  "div",
18116
18132
  {
18117
- className: "uf-cursor-pointer hover:uf-text-foreground uf-transition-colors",
18133
+ className: "uf-cursor-pointer hover:uf-opacity-90 uf-transition-colors",
18118
18134
  onClick: onGlossaryClick,
18135
+ style: { color: colors2.primary },
18119
18136
  children: "Glossary"
18120
18137
  }
18121
18138
  )
@@ -18125,61 +18142,117 @@ var t3 = i18n2.transferCrypto;
18125
18142
  function GlossaryModal({
18126
18143
  open,
18127
18144
  onOpenChange,
18128
- themeClass,
18129
- colors: colors2
18145
+ backgroundColor: backgroundColorProp,
18146
+ themeClass: themeClassProp,
18147
+ colors: colorsProp
18130
18148
  }) {
18149
+ const { themeClass, colors: colors2, components } = useTheme();
18150
+ const resolvedThemeClass = themeClassProp ?? themeClass;
18151
+ const modalBackground = backgroundColorProp ?? colors2.background;
18131
18152
  return /* @__PURE__ */ jsx37(Dialog2, { open, onOpenChange, children: /* @__PURE__ */ jsxs33(
18132
18153
  DialogContent2,
18133
18154
  {
18134
- className: `sm:uf-max-w-[400px] !uf-top-auto !uf-h-auto sm:!uf-top-[50%] uf-border-secondary uf-text-foreground uf-p-0 uf-gap-0 [&>button]:uf-hidden ${themeClass}`,
18135
- style: { backgroundColor: colors2.card },
18155
+ className: `sm:uf-max-w-[400px] !uf-top-auto !uf-h-auto sm:!uf-top-[50%] uf-border-secondary uf-p-0 uf-gap-0 [&>button]:uf-hidden ${resolvedThemeClass}`,
18156
+ style: { backgroundColor: modalBackground },
18136
18157
  children: [
18137
- /* @__PURE__ */ jsxs33("div", { className: "uf-flex uf-items-center uf-justify-between uf-p-4 uf-pb-2", children: [
18138
- /* @__PURE__ */ jsx37(DialogTitle2, { className: "uf-text-base uf-font-semibold", children: "Glossary" }),
18158
+ /* @__PURE__ */ jsxs33("div", { className: "uf-relative uf-flex uf-items-center uf-justify-between", children: [
18159
+ /* @__PURE__ */ jsx37("span", { className: "uf-invisible uf-w-9 uf-h-9 uf-flex uf-shrink-0 uf-items-center uf-justify-center", "aria-hidden": true, children: /* @__PURE__ */ jsx37(X, { className: "uf-w-4 uf-h-4" }) }),
18160
+ /* @__PURE__ */ jsx37(
18161
+ DialogTitle2,
18162
+ {
18163
+ className: "uf-text-base uf-font-medium uf-absolute uf-left-0 uf-right-0 uf-text-center uf-pointer-events-none",
18164
+ style: { color: components.header.titleColor },
18165
+ children: "Glossary"
18166
+ }
18167
+ ),
18139
18168
  /* @__PURE__ */ jsx37(
18140
18169
  "button",
18141
18170
  {
18142
18171
  onClick: () => onOpenChange(false),
18143
- className: "uf-p-1 uf-rounded-lg hover:uf-bg-secondary uf-transition-colors uf-text-muted-foreground hover:uf-text-foreground",
18172
+ className: "uf-p-1 uf-rounded-lg hover:uf-bg-secondary uf-transition-colors uf-flex-shrink-0 uf-z-[1]",
18173
+ style: { color: components.header.buttonColor },
18144
18174
  children: /* @__PURE__ */ jsx37(X, { className: "uf-w-4 uf-h-4" })
18145
18175
  }
18146
18176
  )
18147
18177
  ] }),
18148
- /* @__PURE__ */ jsx37("div", { className: "uf-max-h-[60vh] sm:uf-max-h-[400px] uf-overflow-y-auto uf-px-4 uf-pb-4 [scrollbar-width:none] [&::-webkit-scrollbar]:uf-hidden", children: /* @__PURE__ */ jsxs33("div", { className: "uf-space-y-4", children: [
18149
- /* @__PURE__ */ jsxs33("div", { children: [
18150
- /* @__PURE__ */ jsx37("div", { className: "uf-text-sm uf-font-medium uf-mb-1", children: "Your Deposit Token" }),
18151
- /* @__PURE__ */ jsx37("p", { className: "uf-text-xs uf-text-muted-foreground uf-leading-relaxed", children: t3.selectTokenDepositTooltip })
18152
- ] }),
18153
- /* @__PURE__ */ jsx37("div", { className: "uf-border-t uf-border-border" }),
18154
- /* @__PURE__ */ jsxs33("div", { children: [
18155
- /* @__PURE__ */ jsx37("div", { className: "uf-text-sm uf-font-medium uf-mb-1", children: "Deposit Address" }),
18156
- /* @__PURE__ */ jsx37("p", { className: "uf-text-xs uf-text-muted-foreground uf-leading-relaxed", children: "A unique wallet address generated for you. Send supported tokens to this address and they will be automatically converted and deposited into your account." })
18157
- ] }),
18158
- /* @__PURE__ */ jsx37("div", { className: "uf-border-t uf-border-border" }),
18159
- /* @__PURE__ */ jsxs33("div", { children: [
18160
- /* @__PURE__ */ jsx37("div", { className: "uf-text-sm uf-font-medium uf-mb-1", children: "Price Impact" }),
18161
- /* @__PURE__ */ jsx37("p", { className: "uf-text-xs uf-text-muted-foreground uf-leading-relaxed", children: t3.priceImpact.tooltip })
18162
- ] }),
18163
- /* @__PURE__ */ jsx37("div", { className: "uf-border-t uf-border-border" }),
18164
- /* @__PURE__ */ jsxs33("div", { children: [
18165
- /* @__PURE__ */ jsx37("div", { className: "uf-text-sm uf-font-medium uf-mb-1", children: "Slippage" }),
18166
- /* @__PURE__ */ jsx37("p", { className: "uf-text-xs uf-text-muted-foreground uf-leading-relaxed", children: t3.slippage.tooltip })
18167
- ] }),
18168
- /* @__PURE__ */ jsx37("div", { className: "uf-border-t uf-border-border" }),
18169
- /* @__PURE__ */ jsxs33("div", { children: [
18170
- /* @__PURE__ */ jsx37("div", { className: "uf-text-sm uf-font-medium uf-mb-1", children: "Processing Time" }),
18171
- /* @__PURE__ */ jsx37("p", { className: "uf-text-xs uf-text-muted-foreground uf-leading-relaxed", children: "The estimated time for your deposit to be confirmed and credited. This depends on the source network's block confirmation time and current congestion." })
18172
- ] }),
18173
- /* @__PURE__ */ jsx37("div", { className: "uf-border-t uf-border-border" }),
18174
- /* @__PURE__ */ jsxs33("div", { children: [
18175
- /* @__PURE__ */ jsx37("div", { className: "uf-text-sm uf-font-medium uf-mb-1", children: "Minimum Deposit" }),
18176
- /* @__PURE__ */ jsx37("p", { className: "uf-text-xs uf-text-muted-foreground uf-leading-relaxed", children: t3.minDeposit.tooltip })
18177
- ] }),
18178
- /* @__PURE__ */ jsx37("div", { className: "uf-border-t uf-border-border" }),
18179
- /* @__PURE__ */ jsxs33("div", { children: [
18180
- /* @__PURE__ */ jsx37("div", { className: "uf-text-sm uf-font-medium uf-mb-1", children: "Recipient Address" }),
18181
- /* @__PURE__ */ jsx37("p", { className: "uf-text-xs uf-text-muted-foreground uf-leading-relaxed", children: "The destination address on the target blockchain where your converted deposit will be sent. This is typically your wallet address on the application's native chain." })
18182
- ] })
18178
+ /* @__PURE__ */ jsx37("div", { className: "uf-max-h-[60vh] sm:uf-max-h-[400px] uf-overflow-y-auto uf-pb-4 [scrollbar-width:none] [&::-webkit-scrollbar]:uf-hidden", children: /* @__PURE__ */ jsxs33("div", { className: "uf-space-y-3", children: [
18179
+ /* @__PURE__ */ jsxs33(
18180
+ "div",
18181
+ {
18182
+ className: "uf-rounded-xl uf-p-3",
18183
+ style: { backgroundColor: components.card.backgroundColor },
18184
+ children: [
18185
+ /* @__PURE__ */ jsx37("div", { className: "uf-text-sm uf-font-medium uf-mb-1", style: { color: components.card.titleColor }, children: "Your Deposit Token" }),
18186
+ /* @__PURE__ */ jsx37("p", { className: "uf-text-xs uf-leading-relaxed", style: { color: components.card.descriptionColor }, children: t3.selectTokenDepositTooltip })
18187
+ ]
18188
+ }
18189
+ ),
18190
+ /* @__PURE__ */ jsxs33(
18191
+ "div",
18192
+ {
18193
+ className: "uf-rounded-xl uf-p-3",
18194
+ style: { backgroundColor: components.card.backgroundColor },
18195
+ children: [
18196
+ /* @__PURE__ */ jsx37("div", { className: "uf-text-sm uf-font-medium uf-mb-1", style: { color: components.card.titleColor }, children: "Deposit Address" }),
18197
+ /* @__PURE__ */ jsx37("p", { className: "uf-text-xs uf-leading-relaxed", style: { color: components.card.descriptionColor }, children: "A unique wallet address generated for you. Send supported tokens to this address and they will be automatically converted and deposited into your account." })
18198
+ ]
18199
+ }
18200
+ ),
18201
+ /* @__PURE__ */ jsxs33(
18202
+ "div",
18203
+ {
18204
+ className: "uf-rounded-xl uf-p-3",
18205
+ style: { backgroundColor: components.card.backgroundColor },
18206
+ children: [
18207
+ /* @__PURE__ */ jsx37("div", { className: "uf-text-sm uf-font-medium uf-mb-1", style: { color: components.card.titleColor }, children: "Price Impact" }),
18208
+ /* @__PURE__ */ jsx37("p", { className: "uf-text-xs uf-leading-relaxed", style: { color: components.card.descriptionColor }, children: t3.priceImpact.tooltip })
18209
+ ]
18210
+ }
18211
+ ),
18212
+ /* @__PURE__ */ jsxs33(
18213
+ "div",
18214
+ {
18215
+ className: "uf-rounded-xl uf-p-3",
18216
+ style: { backgroundColor: components.card.backgroundColor },
18217
+ children: [
18218
+ /* @__PURE__ */ jsx37("div", { className: "uf-text-sm uf-font-medium uf-mb-1", style: { color: components.card.titleColor }, children: "Slippage" }),
18219
+ /* @__PURE__ */ jsx37("p", { className: "uf-text-xs uf-leading-relaxed", style: { color: components.card.descriptionColor }, children: t3.slippage.tooltip })
18220
+ ]
18221
+ }
18222
+ ),
18223
+ /* @__PURE__ */ jsxs33(
18224
+ "div",
18225
+ {
18226
+ className: "uf-rounded-xl uf-p-3",
18227
+ style: { backgroundColor: components.card.backgroundColor },
18228
+ children: [
18229
+ /* @__PURE__ */ jsx37("div", { className: "uf-text-sm uf-font-medium uf-mb-1", style: { color: components.card.titleColor }, children: "Processing Time" }),
18230
+ /* @__PURE__ */ jsx37("p", { className: "uf-text-xs uf-leading-relaxed", style: { color: components.card.descriptionColor }, children: "The estimated time for your deposit to be confirmed and credited. This depends on the source network's block confirmation time and current congestion." })
18231
+ ]
18232
+ }
18233
+ ),
18234
+ /* @__PURE__ */ jsxs33(
18235
+ "div",
18236
+ {
18237
+ className: "uf-rounded-xl uf-p-3",
18238
+ style: { backgroundColor: components.card.backgroundColor },
18239
+ children: [
18240
+ /* @__PURE__ */ jsx37("div", { className: "uf-text-sm uf-font-medium uf-mb-1", style: { color: components.card.titleColor }, children: "Minimum Deposit" }),
18241
+ /* @__PURE__ */ jsx37("p", { className: "uf-text-xs uf-leading-relaxed", style: { color: components.card.descriptionColor }, children: t3.minDeposit.tooltip })
18242
+ ]
18243
+ }
18244
+ ),
18245
+ /* @__PURE__ */ jsxs33(
18246
+ "div",
18247
+ {
18248
+ className: "uf-rounded-xl uf-p-3",
18249
+ style: { backgroundColor: components.card.backgroundColor },
18250
+ children: [
18251
+ /* @__PURE__ */ jsx37("div", { className: "uf-text-sm uf-font-medium uf-mb-1", style: { color: components.card.titleColor }, children: "Recipient Address" }),
18252
+ /* @__PURE__ */ jsx37("p", { className: "uf-text-xs uf-leading-relaxed", style: { color: components.card.descriptionColor }, children: "The destination address on the target blockchain where your converted deposit will be sent. This is typically your wallet address on the application's native chain." })
18253
+ ]
18254
+ }
18255
+ )
18183
18256
  ] }) })
18184
18257
  ]
18185
18258
  }
@@ -18420,7 +18493,7 @@ function TransferCryptoSingleInput({
18420
18493
  className: "uf-space-y-3 [scrollbar-width:none] [&::-webkit-scrollbar]:uf-hidden",
18421
18494
  style: { backgroundColor: colors2.background },
18422
18495
  children: [
18423
- /* @__PURE__ */ jsx39("div", { className: "uf-text-xs uf-text-muted-foreground uf-mb-1 uf-flex uf-items-center uf-justify-between", children: /* @__PURE__ */ jsx39("div", { className: "uf-flex uf-items-center uf-gap-1", children: t4.selectTokenDeposit }) }),
18496
+ /* @__PURE__ */ jsx39("div", { className: "uf-text-xs uf-mb-1 uf-flex uf-items-center uf-justify-between", style: { color: components.card.labelColor }, children: /* @__PURE__ */ jsx39("div", { className: "uf-flex uf-items-center uf-gap-1", children: t4.selectTokenDeposit }) }),
18424
18497
  /* @__PURE__ */ jsx39(
18425
18498
  "button",
18426
18499
  {
@@ -18524,7 +18597,7 @@ function TransferCryptoSingleInput({
18524
18597
  ] })
18525
18598
  ] }),
18526
18599
  /* @__PURE__ */ jsxs34("div", { className: "uf-flex uf-flex-col uf-items-center uf-pt-2", children: [
18527
- /* @__PURE__ */ jsx39("div", { className: "uf-text-xs uf-text-muted-foreground uf-mb-2 uf-flex uf-items-center uf-gap-1", children: "Intent address" }),
18600
+ /* @__PURE__ */ jsx39("div", { className: "uf-text-xs uf-mb-2 uf-flex uf-items-center uf-gap-1", style: { color: components.card.labelColor }, children: "Intent address" }),
18528
18601
  /* @__PURE__ */ jsx39("div", { className: "uf-shadow-lg", style: { borderRadius: components.card.borderRadius, border: `${components.card.borderWidth}px solid ${components.card.borderColor}` }, children: loading || tokensLoading || !initialSelectionDone ? (
18529
18602
  // QR Skeleton - matches QR code appearance
18530
18603
  /* @__PURE__ */ jsx39(
@@ -18569,7 +18642,7 @@ function TransferCryptoSingleInput({
18569
18642
  }
18570
18643
  ) })
18571
18644
  ] }),
18572
- /* @__PURE__ */ jsx39("div", { children: /* @__PURE__ */ jsxs34("div", { className: "uf-text-sm uf-text-muted-foreground uf-mb-2 uf-flex uf-justify-center uf-items-center uf-gap-1", children: [
18645
+ /* @__PURE__ */ jsx39("div", { children: /* @__PURE__ */ jsxs34("div", { className: "uf-text-sm uf-mb-2 uf-flex uf-justify-center uf-items-center uf-gap-1", children: [
18573
18646
  loading || tokensLoading || !initialSelectionDone ? (
18574
18647
  // Address skeleton
18575
18648
  /* @__PURE__ */ jsx39(
@@ -18581,12 +18654,13 @@ function TransferCryptoSingleInput({
18581
18654
  }
18582
18655
  }
18583
18656
  )
18584
- ) : /* @__PURE__ */ jsx39("span", { className: "uf-text-sm uf-truncate uf-min-w-0", children: depositAddress ? truncateAddress(depositAddress, 8, 6) : t4.noAddressAvailable }),
18657
+ ) : /* @__PURE__ */ jsx39("span", { className: "uf-text-sm uf-truncate uf-min-w-0", style: { color: components.card.titleColor }, children: depositAddress ? truncateAddress(depositAddress, 8, 6) : t4.noAddressAvailable }),
18585
18658
  depositAddress && initialSelectionDone && /* @__PURE__ */ jsx39(
18586
18659
  "span",
18587
18660
  {
18588
18661
  onClick: handleCopyAddress,
18589
- className: `uf-flex-shrink-0 uf-transition-colors uf-cursor-pointer ${copied ? "uf-text-green-500" : "uf-text-muted-foreground"}`,
18662
+ className: "uf-flex-shrink-0 uf-transition-colors uf-cursor-pointer",
18663
+ style: { color: copied ? colors2.success : components.card.actionColor },
18590
18664
  children: copied ? /* @__PURE__ */ jsx39(Check, { className: "uf-w-3.5 uf-h-3.5" }) : /* @__PURE__ */ jsx39(Copy, { className: "uf-w-3.5 uf-h-3.5" })
18591
18665
  }
18592
18666
  )
@@ -18648,7 +18722,8 @@ function TransferCryptoSingleInput({
18648
18722
  "span",
18649
18723
  {
18650
18724
  onClick: () => handleCopyRecipientAddress(recipientAddress),
18651
- className: `uf-flex-shrink-0 uf-transition-colors uf-cursor-pointer ${copiedRecipient ? "uf-text-green-500" : "uf-text-muted-foreground"}`,
18725
+ className: "uf-flex-shrink-0 uf-transition-colors uf-cursor-pointer",
18726
+ style: { color: copiedRecipient ? colors2.success : components.card.actionColor },
18652
18727
  children: copiedRecipient ? /* @__PURE__ */ jsx39(Check, { className: "uf-w-3.5 uf-h-3.5" }) : /* @__PURE__ */ jsx39(Copy, { className: "uf-w-3.5 uf-h-3.5" })
18653
18728
  }
18654
18729
  )
@@ -19039,7 +19114,7 @@ function TransferCryptoDoubleInput({
19039
19114
  children: [
19040
19115
  /* @__PURE__ */ jsxs36("div", { className: "uf-grid uf-grid-cols-2 uf-gap-2.5", children: [
19041
19116
  /* @__PURE__ */ jsxs36("div", { children: [
19042
- /* @__PURE__ */ jsx41("div", { className: "uf-text-xs uf-text-muted-foreground uf-mb-2 uf-flex uf-items-center uf-gap-1", children: t5.selectedToken }),
19117
+ /* @__PURE__ */ jsx41("div", { className: "uf-text-xs uf-mb-2 uf-flex uf-items-center uf-gap-1", style: { color: components.card.labelColor }, children: t5.selectedToken }),
19043
19118
  /* @__PURE__ */ jsxs36(
19044
19119
  Select2,
19045
19120
  {
@@ -19047,7 +19122,7 @@ function TransferCryptoDoubleInput({
19047
19122
  onValueChange: setToken,
19048
19123
  disabled: tokensLoading || supportedTokens.length === 0,
19049
19124
  children: [
19050
- /* @__PURE__ */ jsx41(SelectTrigger2, { className: "uf-bg-secondary uf-h-10 hover:uf-bg-accent uf-text-foreground disabled:uf-opacity-50", style: { border: `1px solid ${isDarkMode ? "rgba(255,255,255,0.15)" : "rgba(0,0,0,0.15)"}` }, children: /* @__PURE__ */ jsx41(SelectValue2, { children: tokensLoading ? /* @__PURE__ */ jsx41("div", { className: "uf-flex uf-items-center uf-gap-2", children: /* @__PURE__ */ jsx41("span", { className: "uf-text-xs uf-font-light uf-text-muted-foreground", children: t5.loading }) }) : selectedToken ? renderTokenItem(selectedToken) : /* @__PURE__ */ jsx41("div", { className: "uf-flex uf-items-center uf-gap-2", children: /* @__PURE__ */ jsx41("span", { className: "uf-text-xs uf-font-normal", children: token }) }) }) }),
19125
+ /* @__PURE__ */ jsx41(SelectTrigger2, { className: "uf-h-10 hover:uf-opacity-90 uf-text-foreground disabled:uf-opacity-50", style: { backgroundColor: components.card.backgroundColor, border: `${components.card.borderWidth}px solid ${components.card.borderColor}` }, children: /* @__PURE__ */ jsx41(SelectValue2, { children: tokensLoading ? /* @__PURE__ */ jsx41("div", { className: "uf-flex uf-items-center uf-gap-2", children: /* @__PURE__ */ jsx41("span", { className: "uf-text-xs uf-font-light uf-text-muted-foreground", children: t5.loading }) }) : selectedToken ? renderTokenItem(selectedToken) : /* @__PURE__ */ jsx41("div", { className: "uf-flex uf-items-center uf-gap-2", children: /* @__PURE__ */ jsx41("span", { className: "uf-text-xs uf-font-normal", children: token }) }) }) }),
19051
19126
  /* @__PURE__ */ jsx41(SelectContent2, { className: "uf-bg-secondary uf-border uf-text-foreground uf-max-h-[300px]", style: { border: `1px solid ${isDarkMode ? "rgba(255,255,255,0.15)" : "rgba(0,0,0,0.15)"}`, ...fonts.regular ? { "--uf-font-family": fonts.regular } : {} }, children: supportedTokens.map((tokenData) => /* @__PURE__ */ jsx41(
19052
19127
  SelectItem2,
19053
19128
  {
@@ -19062,7 +19137,7 @@ function TransferCryptoDoubleInput({
19062
19137
  )
19063
19138
  ] }),
19064
19139
  /* @__PURE__ */ jsxs36("div", { children: [
19065
- /* @__PURE__ */ jsxs36("div", { className: "uf-text-xs uf-text-muted-foreground uf-mb-2 uf-flex uf-items-center uf-gap-1", children: [
19140
+ /* @__PURE__ */ jsxs36("div", { className: "uf-text-xs uf-mb-2 uf-flex uf-items-center uf-gap-1", style: { color: components.card.labelColor }, children: [
19066
19141
  t5.selectedChain,
19067
19142
  /* @__PURE__ */ jsxs36("span", { className: "uf-font-medium", style: { color: components.card.labelHighlightRightColor }, children: [
19068
19143
  "$",
@@ -19078,7 +19153,7 @@ function TransferCryptoDoubleInput({
19078
19153
  onValueChange: setChain,
19079
19154
  disabled: tokensLoading || availableChainsForToken.length === 0,
19080
19155
  children: [
19081
- /* @__PURE__ */ jsx41(SelectTrigger2, { className: "uf-bg-secondary uf-h-10 hover:uf-bg-accent uf-text-foreground disabled:uf-opacity-50", style: { border: `1px solid ${isDarkMode ? "rgba(255,255,255,0.15)" : "rgba(0,0,0,0.15)"}` }, children: /* @__PURE__ */ jsx41(SelectValue2, { children: tokensLoading ? /* @__PURE__ */ jsx41("div", { className: "uf-flex uf-items-center uf-gap-2", children: /* @__PURE__ */ jsx41("span", { className: "uf-text-xs uf-font-light uf-text-muted-foreground", children: t5.loading }) }) : currentChainFromBackend ? renderChainItem(currentChainFromBackend) : currentChainData ? renderChainItem(currentChainData) : /* @__PURE__ */ jsx41("div", { className: "uf-flex uf-items-center uf-gap-2", children: /* @__PURE__ */ jsx41("span", { className: "uf-text-xs uf-font-normal", children: chain }) }) }) }),
19156
+ /* @__PURE__ */ jsx41(SelectTrigger2, { className: "uf-h-10 hover:uf-opacity-90 uf-text-foreground disabled:uf-opacity-50", style: { backgroundColor: components.card.backgroundColor, border: `${components.card.borderWidth}px solid ${components.card.borderColor}` }, children: /* @__PURE__ */ jsx41(SelectValue2, { children: tokensLoading ? /* @__PURE__ */ jsx41("div", { className: "uf-flex uf-items-center uf-gap-2", children: /* @__PURE__ */ jsx41("span", { className: "uf-text-xs uf-font-light uf-text-muted-foreground", children: t5.loading }) }) : currentChainFromBackend ? renderChainItem(currentChainFromBackend) : currentChainData ? renderChainItem(currentChainData) : /* @__PURE__ */ jsx41("div", { className: "uf-flex uf-items-center uf-gap-2", children: /* @__PURE__ */ jsx41("span", { className: "uf-text-xs uf-font-normal", children: chain }) }) }) }),
19082
19157
  /* @__PURE__ */ jsx41(
19083
19158
  SelectContent2,
19084
19159
  {
@@ -19121,7 +19196,7 @@ function TransferCryptoDoubleInput({
19121
19196
  ] })
19122
19197
  ] }),
19123
19198
  /* @__PURE__ */ jsxs36("div", { className: "uf-flex uf-flex-col uf-items-center uf-pt-2", children: [
19124
- /* @__PURE__ */ jsx41("div", { className: "uf-text-xs uf-text-muted-foreground uf-mb-2 uf-flex uf-items-center uf-gap-1", children: "Intent address" }),
19199
+ /* @__PURE__ */ jsx41("div", { className: "uf-text-xs uf-mb-2 uf-flex uf-items-center uf-gap-1", style: { color: components.card.labelColor }, children: "Intent address" }),
19125
19200
  /* @__PURE__ */ jsx41("div", { className: "uf-shadow-lg", style: { borderRadius: components.card.borderRadius, border: `${components.card.borderWidth}px solid ${components.card.borderColor}` }, children: loading || tokensLoading || !initialSelectionDone ? (
19126
19201
  // QR Skeleton - matches QR code appearance
19127
19202
  /* @__PURE__ */ jsx41(
@@ -19166,7 +19241,7 @@ function TransferCryptoDoubleInput({
19166
19241
  }
19167
19242
  ) })
19168
19243
  ] }),
19169
- /* @__PURE__ */ jsx41("div", { children: /* @__PURE__ */ jsxs36("div", { className: "uf-text-sm uf-text-muted-foreground uf-mb-2 uf-flex uf-justify-center uf-items-center uf-gap-1", children: [
19244
+ /* @__PURE__ */ jsx41("div", { children: /* @__PURE__ */ jsxs36("div", { className: "uf-text-sm uf-mb-2 uf-flex uf-justify-center uf-items-center uf-gap-1", children: [
19170
19245
  loading || tokensLoading || !initialSelectionDone ? (
19171
19246
  // Address skeleton
19172
19247
  /* @__PURE__ */ jsx41(
@@ -19178,12 +19253,13 @@ function TransferCryptoDoubleInput({
19178
19253
  }
19179
19254
  }
19180
19255
  )
19181
- ) : /* @__PURE__ */ jsx41("span", { className: "uf-text-sm uf-truncate uf-min-w-0", children: depositAddress ? truncateAddress(depositAddress, 8, 6) : t5.noAddressAvailable }),
19256
+ ) : /* @__PURE__ */ jsx41("span", { className: "uf-text-sm uf-truncate uf-min-w-0", style: { color: components.card.titleColor }, children: depositAddress ? truncateAddress(depositAddress, 8, 6) : t5.noAddressAvailable }),
19182
19257
  depositAddress && initialSelectionDone && /* @__PURE__ */ jsx41(
19183
19258
  "span",
19184
19259
  {
19185
19260
  onClick: handleCopyAddress,
19186
- className: `uf-flex-shrink-0 uf-transition-colors uf-cursor-pointer ${copied ? "uf-text-green-500" : "uf-text-muted-foreground"}`,
19261
+ className: "uf-flex-shrink-0 uf-transition-colors uf-cursor-pointer",
19262
+ style: { color: copied ? colors2.success : components.card.actionColor },
19187
19263
  children: copied ? /* @__PURE__ */ jsx41(Check, { className: "uf-w-3.5 uf-h-3.5" }) : /* @__PURE__ */ jsx41(Copy, { className: "uf-w-3.5 uf-h-3.5" })
19188
19264
  }
19189
19265
  )
@@ -19245,7 +19321,8 @@ function TransferCryptoDoubleInput({
19245
19321
  "span",
19246
19322
  {
19247
19323
  onClick: () => handleCopyRecipientAddress(recipientAddress),
19248
- className: `uf-flex-shrink-0 uf-transition-colors uf-cursor-pointer ${copiedRecipient ? "uf-text-green-500" : "uf-text-muted-foreground"}`,
19324
+ className: "uf-flex-shrink-0 uf-transition-colors uf-cursor-pointer",
19325
+ style: { color: copiedRecipient ? colors2.success : components.card.actionColor },
19249
19326
  children: copiedRecipient ? /* @__PURE__ */ jsx41(Check, { className: "uf-w-3.5 uf-h-3.5" }) : /* @__PURE__ */ jsx41(Copy, { className: "uf-w-3.5 uf-h-3.5" })
19250
19327
  }
19251
19328
  )
@@ -21242,14 +21319,23 @@ function DepositModal({
21242
21319
  onDepositSuccess,
21243
21320
  onDepositError,
21244
21321
  theme = "dark",
21245
- hideOverlay = false
21322
+ hideOverlay = false,
21323
+ initialScreen = "main"
21246
21324
  }) {
21247
21325
  const { colors: colors2, fonts, components } = useTheme();
21326
+ const effectiveInitialScreen = useMemo82(() => {
21327
+ const s = initialScreen ?? "main";
21328
+ if (s === "tracker" && hideDepositTracker) return "main";
21329
+ return s;
21330
+ }, [initialScreen, hideDepositTracker]);
21248
21331
  const [containerEl, setContainerEl] = useState26(null);
21249
21332
  const containerCallbackRef = useCallback32((el) => {
21250
21333
  setContainerEl(el);
21251
21334
  }, []);
21252
- const [view, setView] = useState26("main");
21335
+ const [view, setView] = useState26(
21336
+ effectiveInitialScreen
21337
+ );
21338
+ const resetViewTimeoutRef = useRef52(null);
21253
21339
  const [cardView, setCardView] = useState26(
21254
21340
  "amount"
21255
21341
  );
@@ -21369,6 +21455,43 @@ function DepositModal({
21369
21455
  const template = errors[code] ?? addressValidationMessages.defaultError;
21370
21456
  return interpolate(template, metadata);
21371
21457
  };
21458
+ const openingScreen = effectiveInitialScreen;
21459
+ const sessionOpenedFromMenu = openingScreen === "main";
21460
+ const standaloneNeedsDepositPrereq = openingScreen !== "main" && (view === "transfer" || view === "card");
21461
+ let depositPrerequisiteBody;
21462
+ if (isCountryLoading || isAddressValidationLoading || tokensLoading || walletsLoading || !projectConfig) {
21463
+ depositPrerequisiteBody = standaloneNeedsDepositPrereq ? /* @__PURE__ */ jsx48(SkeletonButton, { variant: "with-icons" }) : /* @__PURE__ */ jsxs43(Fragment11, { children: [
21464
+ /* @__PURE__ */ jsx48(SkeletonButton, { variant: "with-icons" }),
21465
+ /* @__PURE__ */ jsx48(SkeletonButton, { variant: "with-icons" }),
21466
+ !hideDepositTracker && /* @__PURE__ */ jsx48(SkeletonButton, {})
21467
+ ] });
21468
+ } else if (countryError) {
21469
+ depositPrerequisiteBody = /* @__PURE__ */ jsxs43("div", { className: "uf-flex uf-flex-col uf-items-center uf-justify-center uf-py-8 uf-px-4 uf-text-center", children: [
21470
+ /* @__PURE__ */ jsx48("div", { className: "uf-w-16 uf-h-16 uf-rounded-full uf-bg-muted uf-flex uf-items-center uf-justify-center uf-mb-4", children: /* @__PURE__ */ jsx48(TriangleAlert, { className: "uf-w-8 uf-h-8 uf-text-muted-foreground" }) }),
21471
+ /* @__PURE__ */ jsx48("h3", { className: "uf-text-lg uf-font-semibold uf-text-foreground uf-mb-2", children: "Unable to Verify Location" }),
21472
+ /* @__PURE__ */ jsx48("p", { className: "uf-text-sm uf-text-muted-foreground uf-max-w-[280px]", children: "We couldn't verify your location. Please check your connection and try again." })
21473
+ ] });
21474
+ } else if (!isAllowed) {
21475
+ depositPrerequisiteBody = /* @__PURE__ */ jsxs43("div", { className: "uf-flex uf-flex-col uf-items-center uf-justify-center uf-py-8 uf-px-4 uf-text-center", children: [
21476
+ /* @__PURE__ */ jsx48("div", { className: "uf-w-16 uf-h-16 uf-rounded-full uf-bg-muted uf-flex uf-items-center uf-justify-center uf-mb-4", children: /* @__PURE__ */ jsx48(MapPinOff, { className: "uf-w-8 uf-h-8 uf-text-muted-foreground" }) }),
21477
+ /* @__PURE__ */ jsx48("h3", { className: "uf-text-lg uf-font-semibold uf-text-foreground uf-mb-2", children: "No Tokens Available" }),
21478
+ /* @__PURE__ */ jsx48("p", { className: "uf-text-sm uf-text-muted-foreground uf-max-w-[280px]", children: "There are no supported tokens available from your current location." })
21479
+ ] });
21480
+ } else if (isAddressValid === false) {
21481
+ depositPrerequisiteBody = /* @__PURE__ */ jsxs43("div", { className: "uf-flex uf-flex-col uf-items-center uf-justify-center uf-py-8 uf-px-4 uf-text-center", children: [
21482
+ /* @__PURE__ */ jsx48("div", { className: "uf-w-16 uf-h-16 uf-rounded-full uf-bg-muted uf-flex uf-items-center uf-justify-center uf-mb-4", children: /* @__PURE__ */ jsx48(TriangleAlert, { className: "uf-w-8 uf-h-8 uf-text-muted-foreground" }) }),
21483
+ /* @__PURE__ */ jsx48("h3", { className: "uf-text-lg uf-font-semibold uf-text-foreground uf-mb-2", children: addressValidationMessages.unableToReceiveFunds }),
21484
+ /* @__PURE__ */ jsx48("p", { className: "uf-text-sm uf-text-muted-foreground uf-max-w-[280px]", children: getAddressValidationErrorMessage(
21485
+ addressFailureCode,
21486
+ addressFailureMetadata
21487
+ ) })
21488
+ ] });
21489
+ } else {
21490
+ depositPrerequisiteBody = null;
21491
+ }
21492
+ const showBackTransfer = sessionOpenedFromMenu;
21493
+ const showBackCard = cardView !== "amount" || sessionOpenedFromMenu;
21494
+ const showBackTracker = selectedExecution !== null || sessionOpenedFromMenu;
21372
21495
  const themeClass = resolvedTheme === "dark" ? "uf-dark" : "";
21373
21496
  const handleWalletDisconnect = () => {
21374
21497
  setUserDisconnectedWallet(true);
@@ -21379,13 +21502,37 @@ function DepositModal({
21379
21502
  };
21380
21503
  const handleClose = () => {
21381
21504
  onOpenChange(false);
21382
- setTimeout(() => {
21383
- setView("main");
21505
+ if (resetViewTimeoutRef.current) {
21506
+ clearTimeout(resetViewTimeoutRef.current);
21507
+ }
21508
+ resetViewTimeoutRef.current = setTimeout(() => {
21509
+ setView(effectiveInitialScreen);
21384
21510
  setCardView("amount");
21385
21511
  setExchangeView("providers");
21386
21512
  setBrowserWalletInfo(null);
21513
+ resetViewTimeoutRef.current = null;
21387
21514
  }, 200);
21388
21515
  };
21516
+ useLayoutEffect22(() => {
21517
+ if (!open) return;
21518
+ if (resetViewTimeoutRef.current) {
21519
+ clearTimeout(resetViewTimeoutRef.current);
21520
+ resetViewTimeoutRef.current = null;
21521
+ }
21522
+ setView(effectiveInitialScreen);
21523
+ setCardView("amount");
21524
+ setExchangeView("providers");
21525
+ setBrowserWalletInfo(null);
21526
+ setSelectedExecution(null);
21527
+ }, [open, effectiveInitialScreen]);
21528
+ useEffect20(
21529
+ () => () => {
21530
+ if (resetViewTimeoutRef.current) {
21531
+ clearTimeout(resetViewTimeoutRef.current);
21532
+ }
21533
+ },
21534
+ []
21535
+ );
21389
21536
  const handleBack = () => {
21390
21537
  if (view === "card" && cardView === "quotes") {
21391
21538
  setCardView("amount");
@@ -21498,95 +21645,64 @@ function DepositModal({
21498
21645
  publishableKey
21499
21646
  }
21500
21647
  ),
21501
- /* @__PURE__ */ jsx48("div", { className: "uf-pb-4 uf-space-y-3", children: isCountryLoading || isAddressValidationLoading || tokensLoading || walletsLoading || !projectConfig ? /* @__PURE__ */ jsxs43(Fragment11, { children: [
21502
- /* @__PURE__ */ jsx48(SkeletonButton, { variant: "with-icons" }),
21503
- /* @__PURE__ */ jsx48(SkeletonButton, { variant: "with-icons" }),
21504
- !hideDepositTracker && /* @__PURE__ */ jsx48(SkeletonButton, {})
21505
- ] }) : countryError ? (
21506
- /* Error state - couldn't verify location */
21507
- /* @__PURE__ */ jsxs43("div", { className: "uf-flex uf-flex-col uf-items-center uf-justify-center uf-py-8 uf-px-4 uf-text-center", children: [
21508
- /* @__PURE__ */ jsx48("div", { className: "uf-w-16 uf-h-16 uf-rounded-full uf-bg-muted uf-flex uf-items-center uf-justify-center uf-mb-4", children: /* @__PURE__ */ jsx48(TriangleAlert, { className: "uf-w-8 uf-h-8 uf-text-muted-foreground" }) }),
21509
- /* @__PURE__ */ jsx48("h3", { className: "uf-text-lg uf-font-semibold uf-text-foreground uf-mb-2", children: "Unable to Verify Location" }),
21510
- /* @__PURE__ */ jsx48("p", { className: "uf-text-sm uf-text-muted-foreground uf-max-w-[280px]", children: "We couldn't verify your location. Please check your connection and try again." })
21511
- ] })
21512
- ) : !isAllowed ? (
21513
- /* Blocked country state (isAllowed is false or null without error) */
21514
- /* @__PURE__ */ jsxs43("div", { className: "uf-flex uf-flex-col uf-items-center uf-justify-center uf-py-8 uf-px-4 uf-text-center", children: [
21515
- /* @__PURE__ */ jsx48("div", { className: "uf-w-16 uf-h-16 uf-rounded-full uf-bg-muted uf-flex uf-items-center uf-justify-center uf-mb-4", children: /* @__PURE__ */ jsx48(MapPinOff, { className: "uf-w-8 uf-h-8 uf-text-muted-foreground" }) }),
21516
- /* @__PURE__ */ jsx48("h3", { className: "uf-text-lg uf-font-semibold uf-text-foreground uf-mb-2", children: "No Tokens Available" }),
21517
- /* @__PURE__ */ jsx48("p", { className: "uf-text-sm uf-text-muted-foreground uf-max-w-[280px]", children: "There are no supported tokens available from your current location." })
21518
- ] })
21519
- ) : isAddressValid === false ? (
21520
- /* Invalid recipient address state (e.g., Algorand not opted in) */
21521
- /* @__PURE__ */ jsxs43("div", { className: "uf-flex uf-flex-col uf-items-center uf-justify-center uf-py-8 uf-px-4 uf-text-center", children: [
21522
- /* @__PURE__ */ jsx48("div", { className: "uf-w-16 uf-h-16 uf-rounded-full uf-bg-muted uf-flex uf-items-center uf-justify-center uf-mb-4", children: /* @__PURE__ */ jsx48(TriangleAlert, { className: "uf-w-8 uf-h-8 uf-text-muted-foreground" }) }),
21523
- /* @__PURE__ */ jsx48("h3", { className: "uf-text-lg uf-font-semibold uf-text-foreground uf-mb-2", children: addressValidationMessages.unableToReceiveFunds }),
21524
- /* @__PURE__ */ jsx48("p", { className: "uf-text-sm uf-text-muted-foreground uf-max-w-[280px]", children: getAddressValidationErrorMessage(
21525
- addressFailureCode,
21526
- addressFailureMetadata
21527
- ) })
21528
- ] })
21529
- ) : (
21530
- /* Normal deposit options */
21531
- /* @__PURE__ */ jsxs43(Fragment11, { children: [
21532
- /* @__PURE__ */ jsx48(
21533
- TransferCryptoButton,
21534
- {
21535
- onClick: () => setView("transfer"),
21536
- title: t6.transferCrypto.title,
21537
- subtitle: t6.transferCrypto.subtitle,
21538
- featuredTokens: projectConfig.transfer_crypto.networks
21539
- }
21540
- ),
21541
- enableConnectWallet && !isMobileView && /* @__PURE__ */ jsx48(
21542
- BrowserWalletButton,
21543
- {
21544
- onClick: handleBrowserWalletClick,
21545
- onConnectClick: handleWalletConnectClick,
21546
- onDisconnect: handleWalletDisconnect,
21547
- chainType: browserWalletChainType,
21548
- publishableKey
21549
- }
21550
- ),
21551
- /* @__PURE__ */ jsx48(
21552
- DepositWithCardButton,
21553
- {
21554
- onClick: () => setView("card"),
21555
- title: t6.depositWithCard.title,
21556
- subtitle: t6.depositWithCard.subtitle,
21557
- paymentNetworks: projectConfig.payment_networks.networks
21558
- }
21559
- ),
21560
- showPayWithExchange && /* @__PURE__ */ jsx48(
21561
- PayWithExchangeButton,
21562
- {
21563
- onClick: () => setView("exchange"),
21564
- title: t6.payWithExchange.title,
21565
- subtitle: t6.payWithExchange.subtitle,
21566
- exchanges,
21567
- loading: exchangesLoading
21568
- }
21569
- ),
21570
- !hideDepositTracker && /* @__PURE__ */ jsx48(
21571
- DepositTrackerButton,
21572
- {
21573
- onClick: () => {
21574
- setAllExecutions(depositExecutions);
21575
- setView("tracker");
21576
- },
21577
- title: "Deposit Tracker",
21578
- subtitle: "Track your deposit progress",
21579
- badge: depositExecutions.length > 0 ? depositExecutions.length : void 0
21580
- }
21581
- )
21582
- ] })
21583
- ) })
21648
+ /* @__PURE__ */ jsx48("div", { className: "uf-pb-4 uf-space-y-3", children: depositPrerequisiteBody ?? /* @__PURE__ */ jsxs43(Fragment11, { children: [
21649
+ /* @__PURE__ */ jsx48(
21650
+ TransferCryptoButton,
21651
+ {
21652
+ onClick: () => setView("transfer"),
21653
+ title: t6.transferCrypto.title,
21654
+ subtitle: t6.transferCrypto.subtitle,
21655
+ featuredTokens: projectConfig?.transfer_crypto.networks
21656
+ }
21657
+ ),
21658
+ enableConnectWallet && !isMobileView && /* @__PURE__ */ jsx48(
21659
+ BrowserWalletButton,
21660
+ {
21661
+ onClick: handleBrowserWalletClick,
21662
+ onConnectClick: handleWalletConnectClick,
21663
+ onDisconnect: handleWalletDisconnect,
21664
+ chainType: browserWalletChainType,
21665
+ publishableKey
21666
+ }
21667
+ ),
21668
+ /* @__PURE__ */ jsx48(
21669
+ DepositWithCardButton,
21670
+ {
21671
+ onClick: () => setView("card"),
21672
+ title: t6.depositWithCard.title,
21673
+ subtitle: t6.depositWithCard.subtitle,
21674
+ paymentNetworks: projectConfig?.payment_networks.networks
21675
+ }
21676
+ ),
21677
+ showPayWithExchange && /* @__PURE__ */ jsx48(
21678
+ PayWithExchangeButton,
21679
+ {
21680
+ onClick: () => setView("exchange"),
21681
+ title: t6.payWithExchange.title,
21682
+ subtitle: t6.payWithExchange.subtitle,
21683
+ exchanges,
21684
+ loading: exchangesLoading
21685
+ }
21686
+ ),
21687
+ !hideDepositTracker && /* @__PURE__ */ jsx48(
21688
+ DepositTrackerButton,
21689
+ {
21690
+ onClick: () => {
21691
+ setAllExecutions(depositExecutions);
21692
+ setView("tracker");
21693
+ },
21694
+ title: "Deposit Tracker",
21695
+ subtitle: "Track your deposit progress",
21696
+ badge: depositExecutions.length > 0 ? depositExecutions.length : void 0
21697
+ }
21698
+ )
21699
+ ] }) })
21584
21700
  ] }) : view === "transfer" ? /* @__PURE__ */ jsxs43(Fragment11, { children: [
21585
21701
  /* @__PURE__ */ jsx48(
21586
21702
  DepositHeader,
21587
21703
  {
21588
21704
  title: t6.transferCrypto.title,
21589
- showBack: true,
21705
+ showBack: showBackTransfer,
21590
21706
  onBack: handleBack,
21591
21707
  onClose: handleClose,
21592
21708
  showBalance: showBalanceHeader,
@@ -21598,7 +21714,7 @@ function DepositModal({
21598
21714
  publishableKey
21599
21715
  }
21600
21716
  ),
21601
- transferInputVariant === "single_input" ? /* @__PURE__ */ jsx48(
21717
+ standaloneNeedsDepositPrereq && depositPrerequisiteBody !== null ? /* @__PURE__ */ jsx48("div", { className: "uf-pb-4 uf-space-y-3", children: depositPrerequisiteBody }) : transferInputVariant === "single_input" ? /* @__PURE__ */ jsx48(
21602
21718
  TransferCryptoSingleInput,
21603
21719
  {
21604
21720
  userId,
@@ -21634,12 +21750,12 @@ function DepositModal({
21634
21750
  DepositHeader,
21635
21751
  {
21636
21752
  title: selectedExecution ? "Deposit Details" : "Deposit Tracker",
21637
- showBack: true,
21753
+ showBack: showBackTracker,
21638
21754
  onBack: handleBack,
21639
21755
  onClose: handleClose
21640
21756
  }
21641
21757
  ),
21642
- /* @__PURE__ */ jsx48("div", { className: "uf-h-[460px] uf-overflow-y-auto [scrollbar-width:none] [&::-webkit-scrollbar]:uf-hidden", children: selectedExecution ? /* @__PURE__ */ jsx48(DepositDetailContent, { execution: selectedExecution }) : /* @__PURE__ */ jsx48("div", { className: "uf-space-y-2 uf-pb-4", children: allExecutions.length === 0 ? /* @__PURE__ */ jsx48("div", { className: "uf-py-8 uf-px-4 uf-text-center", children: /* @__PURE__ */ jsx48(
21758
+ /* @__PURE__ */ jsx48("div", { className: "uf-h-[460px] uf-overflow-y-auto [scrollbar-width:none] [&::-webkit-scrollbar]:uf-hidden", children: selectedExecution ? /* @__PURE__ */ jsx48(DepositDetailContent, { execution: selectedExecution }) : /* @__PURE__ */ jsx48("div", { className: "uf-space-y-2 uf-pb-8", children: allExecutions.length === 0 ? /* @__PURE__ */ jsx48("div", { className: "uf-py-8 uf-px-4 uf-text-center", children: /* @__PURE__ */ jsx48(
21643
21759
  "div",
21644
21760
  {
21645
21761
  className: "uf-text-sm",
@@ -21659,7 +21775,7 @@ function DepositModal({
21659
21775
  DepositHeader,
21660
21776
  {
21661
21777
  title: cardView === "quotes" ? t6.quotes : t6.depositWithCard.title,
21662
- showBack: true,
21778
+ showBack: showBackCard,
21663
21779
  onBack: handleBack,
21664
21780
  onClose: handleClose,
21665
21781
  badge: cardView === "quotes" ? { count: quotesCount } : void 0,
@@ -21672,7 +21788,7 @@ function DepositModal({
21672
21788
  publishableKey
21673
21789
  }
21674
21790
  ),
21675
- /* @__PURE__ */ jsx48(
21791
+ standaloneNeedsDepositPrereq && depositPrerequisiteBody !== null ? /* @__PURE__ */ jsx48("div", { className: "uf-pb-4 uf-space-y-3", children: depositPrerequisiteBody }) : /* @__PURE__ */ jsx48(
21676
21792
  BuyWithCard,
21677
21793
  {
21678
21794
  userId,
@@ -21965,7 +22081,8 @@ function UnifoldProvider2({
21965
22081
  enablePayWithExchange: config?.enablePayWithExchange,
21966
22082
  onDepositSuccess: handleDepositSuccess,
21967
22083
  onDepositError: handleDepositError,
21968
- theme: resolvedTheme
22084
+ theme: resolvedTheme,
22085
+ initialScreen: depositConfig.initialScreen ?? config?.defaultInitialScreen
21969
22086
  }
21970
22087
  )
21971
22088
  ]