@wheelx-widget/widget 0.1.4 → 0.1.5

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
@@ -1,5 +1,6 @@
1
1
  import * as React5 from 'react';
2
2
  import React5__default, { createContext, memo, useState, useMemo, useRef, useEffect, useContext, createElement, useCallback } from 'react';
3
+ import { defineRecipe, chakra, Tooltip as Tooltip$1, Portal, VStack, Box, HStack, InputGroup, Input, Icon, Image, useBreakpointValue, Dialog, Spinner, Link, Text, Button, Popover, Collapsible, useDisclosure } from '@chakra-ui/react';
3
4
  import { useQuery, QueryClient, QueryClientProvider, useMutation } from '@tanstack/react-query';
4
5
  import { useUserWallets, DynamicContextProvider, useRpcProviders, useTokenBalances, ChainEnum, useDynamicContext, useDynamicModals, useIsLoggedIn } from '@dynamic-labs/sdk-react-core';
5
6
  import { EthereumWalletConnectors } from '@dynamic-labs/ethereum';
@@ -11,7 +12,6 @@ import { ThemeProvider } from '@emotion/react';
11
12
  import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
12
13
  import axios6, { AxiosError } from 'axios';
13
14
  import { create } from 'zustand';
14
- import { defineRecipe, chakra, Tooltip as Tooltip$1, Portal, VStack, Box, HStack, InputGroup, Input, Icon, Image, useBreakpointValue, Dialog, Spinner, Link, Button, Popover, Collapsible, useDisclosure } from '@chakra-ui/react';
15
15
  import { Fraction, RoundingMode } from 'bi-fraction';
16
16
  import { zeroAddress, createPublicClient, http, parseUnits, erc20Abi, formatUnits, isAddress, hexToString, createClient, custom } from 'viem';
17
17
  import { base, soneium, ink, bsc } from 'viem/chains';
@@ -450,6 +450,37 @@ function WalletConnectionStateSync() {
450
450
  useSyncWalletConnectedStore();
451
451
  return null;
452
452
  }
453
+ function LoadingSkeleton() {
454
+ const { theme } = useWidgetTheme();
455
+ return /* @__PURE__ */ jsxs(
456
+ Box,
457
+ {
458
+ display: "flex",
459
+ flexDirection: "column",
460
+ alignItems: "center",
461
+ justifyContent: "center",
462
+ w: { base: "100%", md: "480px" },
463
+ h: { base: "400px", md: "440px" },
464
+ borderRadius: "24px",
465
+ bg: theme.assistBgColor,
466
+ gap: 4,
467
+ children: [
468
+ /* @__PURE__ */ jsx(
469
+ Box,
470
+ {
471
+ w: "40px",
472
+ h: "40px",
473
+ borderRadius: "full",
474
+ bg: theme.defaultBorderColor,
475
+ opacity: 0.4,
476
+ animation: "pulse 1.5s ease-in-out infinite"
477
+ }
478
+ ),
479
+ /* @__PURE__ */ jsx(Text, { fontSize: "14px", color: theme.defaultTextColor, children: "Loading chains and tokens..." })
480
+ ]
481
+ }
482
+ );
483
+ }
453
484
  function ChainsAndTokensLoader({ children, config }) {
454
485
  const { data } = useChainsAndTokens(true);
455
486
  const { setChains, setSlippagePolicies } = useChainsStore();
@@ -506,7 +537,7 @@ function ChainsAndTokensLoader({ children, config }) {
506
537
  }, [filteredChains, filteredTokens, data, setChains, setTokens, setSlippagePolicies]);
507
538
  const isReady = filteredChains && filteredTokens;
508
539
  if (!isReady) {
509
- return /* @__PURE__ */ jsx("div", { style: { display: "flex", justifyContent: "center", alignItems: "center", height: "200px" }, children: /* @__PURE__ */ jsx("span", { children: "Loading chains and tokens..." }) });
540
+ return /* @__PURE__ */ jsx(LoadingSkeleton, {});
510
541
  }
511
542
  return /* @__PURE__ */ jsx(FavoritesProvider, { children: /* @__PURE__ */ jsxs(TokenFavoritesProvider, { children: [
512
543
  /* @__PURE__ */ jsx(WalletConnectionStateSync, {}),
@@ -2834,13 +2865,17 @@ var extractVPathSegment = () => {
2834
2865
  const match = pathname.match(/^\/v\/([a-zA-Z0-9-+]+)/);
2835
2866
  return match ? match[1] : "";
2836
2867
  };
2837
- var toBigInt = (value) => {
2838
- try {
2839
- return BigInt(value);
2840
- } catch {
2841
- return BigInt(0);
2842
- }
2843
- };
2868
+ function toBigInt(balance, decimals = 6) {
2869
+ const balanceStr = typeof balance === "number" ? balance.toString() : balance;
2870
+ const [integerPart, decimalPart = ""] = balanceStr.split(".");
2871
+ const integerBigInt = BigInt(integerPart);
2872
+ const neededDecimalDigits = Math.min(decimalPart.length, decimals);
2873
+ const trimmedDecimal = decimalPart.slice(0, neededDecimalDigits);
2874
+ const paddedDecimal = trimmedDecimal.padEnd(decimals, "0");
2875
+ const decimalBigInt = BigInt(paddedDecimal);
2876
+ const multiplier = BigInt(10 ** decimals);
2877
+ return integerBigInt * multiplier + decimalBigInt;
2878
+ }
2844
2879
  function BackIcon(props = {}) {
2845
2880
  return createElement("svg", {
2846
2881
  xmlns: "http://www.w3.org/2000/svg",
@@ -2862,7 +2897,7 @@ function ArrowRightIcon(props = {}) {
2862
2897
  height: props.size || 16,
2863
2898
  ...props,
2864
2899
  style: { display: "inline-block", verticalAlign: "middle", ...props.style || {} },
2865
- dangerouslySetInnerHTML: { __html: `<circle cx="23.0434" cy="23.5005" r="22.9565" fill="#81728C" />
2900
+ dangerouslySetInnerHTML: { __html: `<circle cx="23.0434" cy="23.5005" r="22.9565" fill="currentColor" />
2866
2901
  <path
2867
2902
  d="M14.0898 22.8301C14.0896 22.822 14.0889 22.8138 14.0889 22.8057C14.0889 22.3529 14.463 21.9813 14.9424 21.9365L15.0391 21.9316L29.0293 21.9316L25.582 18.7607C25.1215 18.3371 25.0489 17.7165 25.4199 17.375C25.7913 17.0335 26.466 17.1007 26.9268 17.5244L31.7939 22.001C32.1346 22.1339 32.374 22.4439 32.374 22.8057C32.374 22.8251 32.3715 22.8442 32.3701 22.8633C32.3705 22.874 32.3721 22.8847 32.3721 22.8955C32.3718 23.2561 32.1341 23.5657 31.7949 23.6992L26.9268 28.1768C26.4661 28.6002 25.7912 28.6674 25.4199 28.3262C25.0488 27.9848 25.1218 27.3641 25.582 26.9404L29.0293 23.7695L15.0371 23.7695L14.9404 23.7646C14.4611 23.7198 14.0872 23.3481 14.0869 22.8955C14.0869 22.8735 14.0881 22.8517 14.0898 22.8301Z"
2868
2903
  fill="white" />` }
@@ -3218,7 +3253,7 @@ var textRecipe = defineRecipe({
3218
3253
  }
3219
3254
  });
3220
3255
  var Heading = chakra("h2", headingRecipe);
3221
- var Text = chakra("p", textRecipe);
3256
+ var Text2 = chakra("p", textRecipe);
3222
3257
  var isTouchDevice = () => {
3223
3258
  if (typeof window === "undefined") return false;
3224
3259
  return "ontouchstart" in window || navigator.maxTouchPoints > 0;
@@ -3895,7 +3930,7 @@ var FormButton = ({
3895
3930
  const renderButton = () => {
3896
3931
  if (errorMessage || quoteMessage) {
3897
3932
  return /* @__PURE__ */ jsx(Button, { ...buttonStyles, disabled: true, bg: theme.disabledButtonBg, children: /* @__PURE__ */ jsx(
3898
- Text,
3933
+ Text2,
3899
3934
  {
3900
3935
  variant: {
3901
3936
  base: "content9",
@@ -3961,7 +3996,7 @@ var FormButton = ({
3961
3996
  }
3962
3997
  ),
3963
3998
  /* @__PURE__ */ jsx(
3964
- Text,
3999
+ Text2,
3965
4000
  {
3966
4001
  position: "absolute",
3967
4002
  w: "28px",
@@ -3976,7 +4011,7 @@ var FormButton = ({
3976
4011
  ]
3977
4012
  }
3978
4013
  ),
3979
- /* @__PURE__ */ jsx(Text, { children: "AI is Thinking the Best Price" })
4014
+ /* @__PURE__ */ jsx(Text2, { children: "AI is Thinking the Best Price" })
3980
4015
  ] }) })
3981
4016
  }
3982
4017
  );
@@ -4572,7 +4607,7 @@ var Network = ({
4572
4607
  }
4573
4608
  ),
4574
4609
  /* @__PURE__ */ jsxs(
4575
- Text,
4610
+ Text2,
4576
4611
  {
4577
4612
  variant: {
4578
4613
  base: "content7",
@@ -4707,7 +4742,7 @@ var TokenAmountText = ({
4707
4742
  });
4708
4743
  const leadingZeros = countLeadingZerosAfterDecimal(_amount);
4709
4744
  if (leadingZeros > 5) {
4710
- return /* @__PURE__ */ jsxs(Text, { variant: "content8", ...props, children: [
4745
+ return /* @__PURE__ */ jsxs(Text2, { variant: "content8", ...props, children: [
4711
4746
  prefix,
4712
4747
  " ",
4713
4748
  _amount.slice(0, 3),
@@ -4726,7 +4761,7 @@ var TokenAmountText = ({
4726
4761
  suffix
4727
4762
  ] });
4728
4763
  }
4729
- return /* @__PURE__ */ jsxs(Text, { variant: "content7", ...props, children: [
4764
+ return /* @__PURE__ */ jsxs(Text2, { variant: "content7", ...props, children: [
4730
4765
  prefix,
4731
4766
  " ",
4732
4767
  _amount,
@@ -5039,7 +5074,7 @@ var TokenAndAddress = ({
5039
5074
  )
5040
5075
  ] }),
5041
5076
  /* @__PURE__ */ jsx(
5042
- Text,
5077
+ Text2,
5043
5078
  {
5044
5079
  variant: {
5045
5080
  base: "content9",
@@ -5067,7 +5102,7 @@ var TokenAndAddress = ({
5067
5102
  }
5068
5103
  ),
5069
5104
  /* @__PURE__ */ jsx(
5070
- Text,
5105
+ Text2,
5071
5106
  {
5072
5107
  variant: {
5073
5108
  base: "content9",
@@ -5271,7 +5306,7 @@ var TokenList = ({
5271
5306
  }
5272
5307
  } else {
5273
5308
  return /* @__PURE__ */ jsx(HStack, { w: "100%", h: "50px", justify: "center", align: "center", children: /* @__PURE__ */ jsx(
5274
- Text,
5309
+ Text2,
5275
5310
  {
5276
5311
  color: theme.weakTextColor,
5277
5312
  variant: {
@@ -5370,7 +5405,7 @@ var TokenList = ({
5370
5405
  cursor: "pointer",
5371
5406
  children: [
5372
5407
  /* @__PURE__ */ jsx(Icon, { as: item.icon, boxSize: "14px" }),
5373
- /* @__PURE__ */ jsx(Text, { children: item.name })
5408
+ /* @__PURE__ */ jsx(Text2, { children: item.name })
5374
5409
  ]
5375
5410
  },
5376
5411
  index
@@ -5670,7 +5705,7 @@ var MobileContent = memo(function MobileContent2({
5670
5705
  objectFit: "cover"
5671
5706
  }
5672
5707
  ) }),
5673
- /* @__PURE__ */ jsx(Icon, { as: ArrowDownIcon, boxSize: "16px" })
5708
+ /* @__PURE__ */ jsx(Icon, { as: ArrowDownIcon, boxSize: "16px", color: theme.defaultTextColor })
5674
5709
  ]
5675
5710
  }
5676
5711
  )
@@ -5726,10 +5761,10 @@ var MobileContent = memo(function MobileContent2({
5726
5761
  children: [
5727
5762
  /* @__PURE__ */ jsx(AllChainsIcon, {}),
5728
5763
  /* @__PURE__ */ jsx(
5729
- Text,
5764
+ Text2,
5730
5765
  {
5731
5766
  variant: "content6_1",
5732
- color: "brand-grey1",
5767
+ color: theme.defaultTextColor,
5733
5768
  whiteSpace: "nowrap",
5734
5769
  children: "Chains with assets"
5735
5770
  }
@@ -5741,7 +5776,7 @@ var MobileContent = memo(function MobileContent2({
5741
5776
  ]
5742
5777
  }
5743
5778
  ),
5744
- !isPreconfigured && /* @__PURE__ */ jsx(Text, { px: 2, color: theme.weakTextColor, variant: "content7", my: 2, children: "Popular" }),
5779
+ !isPreconfigured && /* @__PURE__ */ jsx(Text2, { px: 2, color: theme.weakTextColor, variant: "content7", my: 2, children: "Popular" }),
5745
5780
  /* @__PURE__ */ jsxs(VStack, { w: "100%", align: "start", gap: 0, children: [
5746
5781
  popularChains?.map((chain) => /* @__PURE__ */ jsx(
5747
5782
  Network,
@@ -5777,7 +5812,7 @@ var MobileContent = memo(function MobileContent2({
5777
5812
  chain.chain_id + "fav-chains"
5778
5813
  ))
5779
5814
  ] }),
5780
- !isPreconfigured && /* @__PURE__ */ jsx(Text, { px: 2, color: theme.weakTextColor, variant: "content7", my: 2, children: "Chains (A-Z)" }),
5815
+ !isPreconfigured && /* @__PURE__ */ jsx(Text2, { px: 2, color: theme.weakTextColor, variant: "content7", my: 2, children: "Chains (A-Z)" }),
5781
5816
  /* @__PURE__ */ jsx(VStack, { w: "100%", align: "start", gap: 0, children: orderedChains?.filter((chain) => chain.is_testnet !== true)?.map((chain) => /* @__PURE__ */ jsx(
5782
5817
  Network,
5783
5818
  {
@@ -5794,7 +5829,7 @@ var MobileContent = memo(function MobileContent2({
5794
5829
  chain.chain_id + "ordered-chains"
5795
5830
  )) }),
5796
5831
  !isSelectingFromToken && !isPreconfigured && /* @__PURE__ */ jsxs(Fragment, { children: [
5797
- /* @__PURE__ */ jsx(Text, { px: 2, color: theme.weakTextColor, variant: "content7", my: 2, children: "Prediction" }),
5832
+ /* @__PURE__ */ jsx(Text2, { px: 2, color: theme.weakTextColor, variant: "content7", my: 2, children: "Prediction" }),
5798
5833
  orderedPredictionChains?.map((chain) => /* @__PURE__ */ jsx(
5799
5834
  Network,
5800
5835
  {
@@ -5812,7 +5847,7 @@ var MobileContent = memo(function MobileContent2({
5812
5847
  chain.chain_id + "prediction-chains"
5813
5848
  ))
5814
5849
  ] }),
5815
- !isPreconfigured && /* @__PURE__ */ jsx(Text, { px: 2, color: theme.weakTextColor, variant: "content7", my: 2, children: "Testnet" }),
5850
+ !isPreconfigured && /* @__PURE__ */ jsx(Text2, { px: 2, color: theme.weakTextColor, variant: "content7", my: 2, children: "Testnet" }),
5816
5851
  orderedChains?.filter((chain) => chain.is_testnet === true)?.map((chain) => /* @__PURE__ */ jsx(
5817
5852
  Network,
5818
5853
  {
@@ -6006,7 +6041,7 @@ var DesktopContent = ({
6006
6041
  children: [
6007
6042
  /* @__PURE__ */ jsx(AllChainsIcon, {}),
6008
6043
  /* @__PURE__ */ jsx(
6009
- Text,
6044
+ Text2,
6010
6045
  {
6011
6046
  variant: "content6_1",
6012
6047
  color: theme.defaultTextColor,
@@ -6033,7 +6068,7 @@ var DesktopContent = ({
6033
6068
  },
6034
6069
  chain.chain_id + "search-chains"
6035
6070
  )) }) : /* @__PURE__ */ jsxs(Fragment, { children: [
6036
- !isPreconfigured && /* @__PURE__ */ jsx(Text, { px: 2, color: theme.weakTextColor, variant: "content7", mb: 2, children: "Popular" }),
6071
+ !isPreconfigured && /* @__PURE__ */ jsx(Text2, { px: 2, color: theme.weakTextColor, variant: "content7", mb: 2, children: "Popular" }),
6037
6072
  popularChains?.map((chain) => /* @__PURE__ */ jsx(
6038
6073
  Network,
6039
6074
  {
@@ -6061,7 +6096,7 @@ var DesktopContent = ({
6061
6096
  },
6062
6097
  chain.chain_id + "fav-chains"
6063
6098
  )),
6064
- !isPreconfigured && /* @__PURE__ */ jsx(Text, { px: 2, color: theme.weakTextColor, variant: "content7", my: 2, children: "Chains (A-Z)" }),
6099
+ !isPreconfigured && /* @__PURE__ */ jsx(Text2, { px: 2, color: theme.weakTextColor, variant: "content7", my: 2, children: "Chains (A-Z)" }),
6065
6100
  orderedChains?.filter((chain) => chain.is_testnet === false)?.map((chain) => /* @__PURE__ */ jsx(
6066
6101
  Network,
6067
6102
  {
@@ -6077,7 +6112,7 @@ var DesktopContent = ({
6077
6112
  )),
6078
6113
  !isSelectingFromToken && !isPreconfigured && /* @__PURE__ */ jsxs(Fragment, { children: [
6079
6114
  /* @__PURE__ */ jsx(
6080
- Text,
6115
+ Text2,
6081
6116
  {
6082
6117
  px: 2,
6083
6118
  color: theme.weakTextColor,
@@ -6103,7 +6138,7 @@ var DesktopContent = ({
6103
6138
  chain.chain_id + "prediction-chains"
6104
6139
  ))
6105
6140
  ] }),
6106
- !isPreconfigured && /* @__PURE__ */ jsx(Text, { px: 2, color: theme.weakTextColor, variant: "content7", my: 2, children: "Testnet" }),
6141
+ !isPreconfigured && /* @__PURE__ */ jsx(Text2, { px: 2, color: theme.weakTextColor, variant: "content7", my: 2, children: "Testnet" }),
6107
6142
  orderedChains?.filter((chain) => chain.is_testnet === true)?.map((chain) => /* @__PURE__ */ jsx(
6108
6143
  Network,
6109
6144
  {
@@ -6533,7 +6568,7 @@ var TokenInfoCom = ({ tokenInfo, priority = false }) => {
6533
6568
  }
6534
6569
  ),
6535
6570
  /* @__PURE__ */ jsx(
6536
- Text,
6571
+ Text2,
6537
6572
  {
6538
6573
  variant: {
6539
6574
  base: "content9",
@@ -6614,7 +6649,9 @@ var TokenSelectAndInput = ({
6614
6649
  const toTokenBalanceHyper = {
6615
6650
  formatted: toTokenBalanceHyperBack?.withdrawable,
6616
6651
  value: toBigInt(
6617
- toTokenBalanceHyperBack?.withdrawable ? toTokenBalanceHyperBack?.withdrawable : "0")
6652
+ toTokenBalanceHyperBack?.withdrawable ? toTokenBalanceHyperBack?.withdrawable : "0",
6653
+ 6
6654
+ )
6618
6655
  };
6619
6656
  useEffect(() => {
6620
6657
  if (!isFrom) {
@@ -6803,7 +6840,7 @@ var TokenSelectAndInput = ({
6803
6840
  const loss = -(+toAmountToUsd - +fromAmountToUsd) / +fromAmountToUsd;
6804
6841
  if (loss >= 0.1) {
6805
6842
  return /* @__PURE__ */ jsx(
6806
- Text,
6843
+ Text2,
6807
6844
  {
6808
6845
  as: "span",
6809
6846
  color: "#ff4267",
@@ -6838,7 +6875,7 @@ var TokenSelectAndInput = ({
6838
6875
  return /* @__PURE__ */ jsxs(HStack, { gap: 1, children: [
6839
6876
  renderSolanaWalletIcon(),
6840
6877
  /* @__PURE__ */ jsx(
6841
- Text,
6878
+ Text2,
6842
6879
  {
6843
6880
  variant: "content8",
6844
6881
  backgroundColor: theme.highlightBgColor,
@@ -6855,7 +6892,7 @@ var TokenSelectAndInput = ({
6855
6892
  return /* @__PURE__ */ jsxs(HStack, { gap: 1, children: [
6856
6893
  walletIcon,
6857
6894
  /* @__PURE__ */ jsx(
6858
- Text,
6895
+ Text2,
6859
6896
  {
6860
6897
  variant: "content8",
6861
6898
  backgroundColor: theme.highlightBgColor,
@@ -6874,7 +6911,7 @@ var TokenSelectAndInput = ({
6874
6911
  return /* @__PURE__ */ jsxs(HStack, { gap: 1, children: [
6875
6912
  walletIcon,
6876
6913
  /* @__PURE__ */ jsx(
6877
- Text,
6914
+ Text2,
6878
6915
  {
6879
6916
  variant: "content8",
6880
6917
  backgroundColor: theme.assistBgColor,
@@ -6888,7 +6925,7 @@ var TokenSelectAndInput = ({
6888
6925
  }
6889
6926
  return /* @__PURE__ */ jsxs(HStack, { gap: 1, children: [
6890
6927
  /* @__PURE__ */ jsx(
6891
- Text,
6928
+ Text2,
6892
6929
  {
6893
6930
  variant: "content8",
6894
6931
  backgroundColor: theme.assistBgColor,
@@ -6917,7 +6954,7 @@ var TokenSelectAndInput = ({
6917
6954
  cursor: "pointer",
6918
6955
  children: [
6919
6956
  /* @__PURE__ */ jsx(
6920
- Text,
6957
+ Text2,
6921
6958
  {
6922
6959
  variant: "content8",
6923
6960
  backgroundColor: theme.assistBgColor,
@@ -6956,7 +6993,7 @@ var TokenSelectAndInput = ({
6956
6993
  cursor: "pointer",
6957
6994
  children: [
6958
6995
  /* @__PURE__ */ jsx(
6959
- Text,
6996
+ Text2,
6960
6997
  {
6961
6998
  variant: "content8",
6962
6999
  backgroundColor: theme.assistBgColor,
@@ -6990,7 +7027,7 @@ var TokenSelectAndInput = ({
6990
7027
  return /* @__PURE__ */ jsxs(HStack, { gap: 1, children: [
6991
7028
  walletIcon,
6992
7029
  /* @__PURE__ */ jsx(
6993
- Text,
7030
+ Text2,
6994
7031
  {
6995
7032
  variant: "content8",
6996
7033
  backgroundColor: theme.assistBgColor,
@@ -7050,7 +7087,7 @@ var TokenSelectAndInput = ({
7050
7087
  border: "1px solid",
7051
7088
  borderColor: theme.highlightTextColor,
7052
7089
  onClick: () => handleQuickInput("50%"),
7053
- children: /* @__PURE__ */ jsx(Text, { variant: "content9", color: theme.highlightTextColor, children: "50%" })
7090
+ children: /* @__PURE__ */ jsx(Text2, { variant: "content9", color: theme.highlightTextColor, children: "50%" })
7054
7091
  }
7055
7092
  ),
7056
7093
  /* @__PURE__ */ jsx(
@@ -7063,10 +7100,10 @@ var TokenSelectAndInput = ({
7063
7100
  borderRadius: "4px",
7064
7101
  bg: theme.highlightButtonBg,
7065
7102
  onClick: () => handleQuickInput("Max"),
7066
- children: /* @__PURE__ */ jsx(Text, { variant: "content9", color: theme.highlightButtonText, children: "Max" })
7103
+ children: /* @__PURE__ */ jsx(Text2, { variant: "content9", color: theme.highlightButtonText, children: "Max" })
7067
7104
  }
7068
7105
  ),
7069
- /* @__PURE__ */ jsxs(Text, { variant: "content8", color: theme.weakTextColor, children: [
7106
+ /* @__PURE__ */ jsxs(Text2, { variant: "content8", color: theme.weakTextColor, children: [
7070
7107
  "Balance:",
7071
7108
  " ",
7072
7109
  tokenInfo.isSolana && solanaBalance ? solanaBalance.formatted : balance
@@ -7183,7 +7220,7 @@ var TokenSelectAndInput = ({
7183
7220
  }
7184
7221
  ),
7185
7222
  /* @__PURE__ */ jsxs(
7186
- Text,
7223
+ Text2,
7187
7224
  {
7188
7225
  variant: {
7189
7226
  base: "content9",
@@ -7221,10 +7258,10 @@ var TokenSelectAndInput = ({
7221
7258
  bottom: ["6px", "8px"],
7222
7259
  left: 0,
7223
7260
  paddingRight: [2, 4],
7224
- children: !isFrom && !isDepositPlatformToken && /* @__PURE__ */ jsx(Fragment, { children: tokenInfo.isSolana ? solanaWalletAddress && /* @__PURE__ */ jsxs(Text, { variant: "content8", children: [
7261
+ children: !isFrom && !isDepositPlatformToken && /* @__PURE__ */ jsx(Fragment, { children: tokenInfo.isSolana ? solanaWalletAddress && /* @__PURE__ */ jsxs(Text2, { variant: "content8", children: [
7225
7262
  "Balance: ",
7226
7263
  displayBalance
7227
- ] }) : address && /* @__PURE__ */ jsxs(Text, { variant: "content8", children: [
7264
+ ] }) : address && /* @__PURE__ */ jsxs(Text2, { variant: "content8", children: [
7228
7265
  "Balance: ",
7229
7266
  displayBalance
7230
7267
  ] }) })
@@ -7318,7 +7355,7 @@ var TipsContent = ({
7318
7355
  const renderFee = (fee) => {
7319
7356
  if (fee === "0") {
7320
7357
  return /* @__PURE__ */ jsx(
7321
- Text,
7358
+ Text2,
7322
7359
  {
7323
7360
  variant: "content9",
7324
7361
  color: "white",
@@ -7330,7 +7367,7 @@ var TipsContent = ({
7330
7367
  );
7331
7368
  }
7332
7369
  return /* @__PURE__ */ jsxs(
7333
- Text,
7370
+ Text2,
7334
7371
  {
7335
7372
  variant: {
7336
7373
  base: "content9",
@@ -7355,7 +7392,7 @@ var TipsContent = ({
7355
7392
  const sif = +swapImpactFee();
7356
7393
  if (toAmountToUsd === null) {
7357
7394
  return /* @__PURE__ */ jsx(
7358
- Text,
7395
+ Text2,
7359
7396
  {
7360
7397
  variant: {
7361
7398
  base: "content9",
@@ -7368,7 +7405,7 @@ var TipsContent = ({
7368
7405
  }
7369
7406
  if (sif > 0 || sif === 0) {
7370
7407
  return /* @__PURE__ */ jsxs(
7371
- Text,
7408
+ Text2,
7372
7409
  {
7373
7410
  variant: {
7374
7411
  base: "content9",
@@ -7383,7 +7420,7 @@ var TipsContent = ({
7383
7420
  );
7384
7421
  }
7385
7422
  return /* @__PURE__ */ jsxs(
7386
- Text,
7423
+ Text2,
7387
7424
  {
7388
7425
  variant: {
7389
7426
  base: "content9",
@@ -7418,7 +7455,7 @@ var TipsContent = ({
7418
7455
  ),
7419
7456
  /* @__PURE__ */ jsxs(HStack, { justify: "space-between", w: "100%", children: [
7420
7457
  /* @__PURE__ */ jsx(
7421
- Text,
7458
+ Text2,
7422
7459
  {
7423
7460
  variant: {
7424
7461
  base: "content9",
@@ -7432,7 +7469,7 @@ var TipsContent = ({
7432
7469
  ] }),
7433
7470
  /* @__PURE__ */ jsxs(HStack, { justify: "space-between", w: "100%", children: [
7434
7471
  /* @__PURE__ */ jsx(
7435
- Text,
7472
+ Text2,
7436
7473
  {
7437
7474
  variant: {
7438
7475
  base: "content9",
@@ -7443,7 +7480,7 @@ var TipsContent = ({
7443
7480
  }
7444
7481
  ),
7445
7482
  points === "0" && !fromTokenInfo.isSolana ? /* @__PURE__ */ jsx(
7446
- Text,
7483
+ Text2,
7447
7484
  {
7448
7485
  variant: "content9",
7449
7486
  color: "white",
@@ -7482,7 +7519,7 @@ var TipsContent = ({
7482
7519
  ),
7483
7520
  /* @__PURE__ */ jsxs(HStack, { justify: "space-between", w: "100%", children: [
7484
7521
  /* @__PURE__ */ jsx(
7485
- Text,
7522
+ Text2,
7486
7523
  {
7487
7524
  variant: {
7488
7525
  base: "content9",
@@ -7496,7 +7533,7 @@ var TipsContent = ({
7496
7533
  ] }),
7497
7534
  /* @__PURE__ */ jsxs(HStack, { justify: "space-between", w: "100%", children: [
7498
7535
  /* @__PURE__ */ jsx(
7499
- Text,
7536
+ Text2,
7500
7537
  {
7501
7538
  variant: {
7502
7539
  base: "content9",
@@ -7513,7 +7550,7 @@ var TipsContent = ({
7513
7550
  ] }),
7514
7551
  /* @__PURE__ */ jsxs(HStack, { justify: "space-between", w: "100%", children: [
7515
7552
  /* @__PURE__ */ jsx(
7516
- Text,
7553
+ Text2,
7517
7554
  {
7518
7555
  variant: {
7519
7556
  base: "content9",
@@ -7524,7 +7561,7 @@ var TipsContent = ({
7524
7561
  }
7525
7562
  ),
7526
7563
  points === "0" && !fromTokenInfo.isSolana ? /* @__PURE__ */ jsx(
7527
- Text,
7564
+ Text2,
7528
7565
  {
7529
7566
  variant: "content9",
7530
7567
  color: "white",
@@ -7581,7 +7618,7 @@ var TxInfo = ({
7581
7618
  const renderPriceImpactPercentage = () => {
7582
7619
  if (priceImpact.bridgeFee === "0" && priceImpact.dstGasFee === "0" && priceImpact.swapFee === "0") {
7583
7620
  return /* @__PURE__ */ jsx(
7584
- Text,
7621
+ Text2,
7585
7622
  {
7586
7623
  variant: "content9",
7587
7624
  color: theme.highlightButtonText,
@@ -7596,17 +7633,17 @@ var TxInfo = ({
7596
7633
  const inPrice = Number(fromAmountToUsd.replace(/,/g, ""));
7597
7634
  const outPrice = Number(toAmountToUsd.replace(/,/g, ""));
7598
7635
  if (outPrice > inPrice) {
7599
- return /* @__PURE__ */ jsx(Text, { variant: textVariant, color: theme.defaultTextColor, children: `+${((outPrice - inPrice) / inPrice * 100).toFixed(2)}%` });
7636
+ return /* @__PURE__ */ jsx(Text2, { variant: textVariant, color: theme.defaultTextColor, children: `+${((outPrice - inPrice) / inPrice * 100).toFixed(2)}%` });
7600
7637
  }
7601
- return /* @__PURE__ */ jsx(Text, { variant: textVariant, color: theme.defaultTextColor, children: `-${((inPrice - outPrice) / inPrice * 100).toFixed(2)}%` });
7638
+ return /* @__PURE__ */ jsx(Text2, { variant: textVariant, color: theme.defaultTextColor, children: `-${((inPrice - outPrice) / inPrice * 100).toFixed(2)}%` });
7602
7639
  }
7603
- return /* @__PURE__ */ jsx(Text, { variant: textVariant, color: theme.defaultTextColor, children: "-" });
7640
+ return /* @__PURE__ */ jsx(Text2, { variant: textVariant, color: theme.defaultTextColor, children: "-" });
7604
7641
  };
7605
7642
  const renderSoneiumScore = useMemo(() => {
7606
7643
  if (fromTokenInfo.chain_id === 1868 && toTokenInfo.chain_id !== 1868 || fromTokenInfo.chain_id === 1868 && toTokenInfo.chain_id === 1868) {
7607
7644
  return /* @__PURE__ */ jsxs(HStack, { w: "100%", justify: "space-between", children: [
7608
- /* @__PURE__ */ jsx(Text, { variant: textVariant, color: theme.weakTextColor, children: "Soneium Score" }),
7609
- /* @__PURE__ */ jsx(Text, { variant: textVariant, children: "+ 1" })
7645
+ /* @__PURE__ */ jsx(Text2, { variant: textVariant, color: theme.weakTextColor, children: "Soneium Score" }),
7646
+ /* @__PURE__ */ jsx(Text2, { variant: textVariant, children: "+ 1" })
7610
7647
  ] });
7611
7648
  }
7612
7649
  return /* @__PURE__ */ jsx(Fragment, {});
@@ -7625,7 +7662,7 @@ var TxInfo = ({
7625
7662
  alignItems: "center",
7626
7663
  children: [
7627
7664
  /* @__PURE__ */ jsx(
7628
- Text,
7665
+ Text2,
7629
7666
  {
7630
7667
  variant: textVariant,
7631
7668
  fontSize: ["10px", "12px"],
@@ -7642,7 +7679,7 @@ var TxInfo = ({
7642
7679
  margin: "0 2px"
7643
7680
  }
7644
7681
  ),
7645
- /* @__PURE__ */ jsx(Text, { variant: textVariant, fontSize: ["10px", "12px"], children: "Score" })
7682
+ /* @__PURE__ */ jsx(Text2, { variant: textVariant, fontSize: ["10px", "12px"], children: "Score" })
7646
7683
  ]
7647
7684
  }
7648
7685
  );
@@ -7708,7 +7745,7 @@ var TxInfo = ({
7708
7745
  ] }, index);
7709
7746
  }) });
7710
7747
  }
7711
- return /* @__PURE__ */ jsx(Text, { variant: textVariant, children: router });
7748
+ return /* @__PURE__ */ jsx(Text2, { variant: textVariant, children: router });
7712
7749
  };
7713
7750
  return /* @__PURE__ */ jsxs(
7714
7751
  Collapsible.Root,
@@ -7738,7 +7775,7 @@ var TxInfo = ({
7738
7775
  h: "14px"
7739
7776
  }
7740
7777
  ),
7741
- /* @__PURE__ */ jsx(Text, { variant: textVariant, whiteSpace: "nowrap", children: isRateReversed ? `1 ${toTokenInfo.symbol} = ${fromAmountInUnit} ${fromTokenInfo.symbol}` : `1 ${fromTokenInfo.symbol} = ${toAmountInUnitStr} ${toTokenInfo.symbol}` })
7778
+ /* @__PURE__ */ jsx(Text2, { variant: textVariant, whiteSpace: "nowrap", children: isRateReversed ? `1 ${toTokenInfo.symbol} = ${fromAmountInUnit} ${fromTokenInfo.symbol}` : `1 ${fromTokenInfo.symbol} = ${toAmountInUnitStr} ${toTokenInfo.symbol}` })
7742
7779
  ]
7743
7780
  }
7744
7781
  ),
@@ -7760,7 +7797,7 @@ var TxInfo = ({
7760
7797
  /* @__PURE__ */ jsx(Collapsible.Content, { w: "100%", pb: 1.5, color: theme.defaultTextColor, children: /* @__PURE__ */ jsxs(VStack, { w: "100%", align: "start", fontSize: "xs", gap: 3, children: [
7761
7798
  /* @__PURE__ */ jsxs(VStack, { bg: theme.defaultBgColor, p: 3, borderRadius: "12px", w: "100%", children: [
7762
7799
  /* @__PURE__ */ jsxs(HStack, { w: "100%", justify: "space-between", children: [
7763
- /* @__PURE__ */ jsx(Text, { variant: textVariant, color: theme.weakTextColor, children: "Price Impact" }),
7800
+ /* @__PURE__ */ jsx(Text2, { variant: textVariant, color: theme.weakTextColor, children: "Price Impact" }),
7764
7801
  /* @__PURE__ */ jsxs(HStack, { gap: 1, children: [
7765
7802
  renderPriceImpactPercentage(),
7766
7803
  /* @__PURE__ */ jsx(
@@ -7790,14 +7827,14 @@ var TxInfo = ({
7790
7827
  ] })
7791
7828
  ] }),
7792
7829
  /* @__PURE__ */ jsxs(HStack, { w: "100%", justify: "space-between", children: [
7793
- /* @__PURE__ */ jsx(Text, { variant: textVariant, color: theme.weakTextColor, children: "Slippage" }),
7794
- /* @__PURE__ */ jsxs(Text, { variant: textVariant, children: [
7830
+ /* @__PURE__ */ jsx(Text2, { variant: textVariant, color: theme.weakTextColor, children: "Slippage" }),
7831
+ /* @__PURE__ */ jsxs(Text2, { variant: textVariant, children: [
7795
7832
  formatSlippage(slippage),
7796
7833
  "%"
7797
7834
  ] })
7798
7835
  ] }),
7799
7836
  /* @__PURE__ */ jsxs(HStack, { w: "100%", justify: "space-between", children: [
7800
- /* @__PURE__ */ jsx(Text, { variant: textVariant, color: theme.weakTextColor, children: "Min. Received" }),
7837
+ /* @__PURE__ */ jsx(Text2, { variant: textVariant, color: theme.weakTextColor, children: "Min. Received" }),
7801
7838
  /* @__PURE__ */ jsx(HStack, { gap: 1, children: /* @__PURE__ */ jsx(
7802
7839
  TokenAmountText,
7803
7840
  {
@@ -7810,10 +7847,10 @@ var TxInfo = ({
7810
7847
  ] }),
7811
7848
  /* @__PURE__ */ jsxs(VStack, { bg: theme.defaultBgColor, p: 3, borderRadius: "12px", w: "100%", children: [
7812
7849
  /* @__PURE__ */ jsxs(HStack, { w: "100%", justify: "space-between", children: [
7813
- /* @__PURE__ */ jsx(Text, { variant: textVariant, color: theme.weakTextColor, children: "Estimated Time" }),
7850
+ /* @__PURE__ */ jsx(Text2, { variant: textVariant, color: theme.weakTextColor, children: "Estimated Time" }),
7814
7851
  /* @__PURE__ */ jsxs(HStack, { gap: 1, children: [
7815
7852
  /* @__PURE__ */ jsx(Icon, { boxSize: "14px", children: /* @__PURE__ */ jsx(TimeIcon, {}) }),
7816
- /* @__PURE__ */ jsxs(Text, { variant: textVariant, children: [
7853
+ /* @__PURE__ */ jsxs(Text2, { variant: textVariant, children: [
7817
7854
  "~",
7818
7855
  estimatedTime,
7819
7856
  "s"
@@ -7821,11 +7858,11 @@ var TxInfo = ({
7821
7858
  ] })
7822
7859
  ] }),
7823
7860
  /* @__PURE__ */ jsxs(HStack, { w: "100%", justify: "space-between", children: [
7824
- /* @__PURE__ */ jsx(Text, { variant: textVariant, color: theme.weakTextColor, children: "Recipient Address" }),
7825
- /* @__PURE__ */ jsx(Text, { variant: textVariant, children: sliceAddress(recipient) })
7861
+ /* @__PURE__ */ jsx(Text2, { variant: textVariant, color: theme.weakTextColor, children: "Recipient Address" }),
7862
+ /* @__PURE__ */ jsx(Text2, { variant: textVariant, children: sliceAddress(recipient) })
7826
7863
  ] }),
7827
7864
  /* @__PURE__ */ jsxs(HStack, { w: "100%", justify: "space-between", children: [
7828
- /* @__PURE__ */ jsx(Text, { variant: textVariant, color: theme.weakTextColor, children: "AI Router" }),
7865
+ /* @__PURE__ */ jsx(Text2, { variant: textVariant, color: theme.weakTextColor, children: "AI Router" }),
7829
7866
  renderAiRouter()
7830
7867
  ] }),
7831
7868
  renderSoneiumScore
@@ -8232,10 +8269,6 @@ var DifferentAddressDialog = ({
8232
8269
  );
8233
8270
  };
8234
8271
  var DifferentAddressDialog_default = DifferentAddressDialog;
8235
- var useRouter = () => ({ push: (_url) => {
8236
- }, replace: (_url) => {
8237
- } });
8238
- var usePathname = () => "";
8239
8272
  var FormBody = ({
8240
8273
  getQuote,
8241
8274
  quoteInfo,
@@ -8247,6 +8280,7 @@ var FormBody = ({
8247
8280
  refetchQuote,
8248
8281
  config
8249
8282
  }) => {
8283
+ const { theme } = useWidgetTheme();
8250
8284
  const {
8251
8285
  fromAmount,
8252
8286
  toAmount,
@@ -8262,14 +8296,14 @@ var FormBody = ({
8262
8296
  } = useSwapAndBridgeContextStore();
8263
8297
  const { chains } = useChainsStore();
8264
8298
  const { tokens } = useTokensStore();
8265
- const { replace: replaceLink } = useRouter();
8266
- const pathname = usePathname();
8267
- const { isTrendingOpen, setTrendingClientReact, setIsTrendingLonger } = { isTrendingOpen: false, setTrendingClientReact: (_v) => {
8268
- }, setIsTrendingLonger: (_v) => {
8269
- } };
8270
- const isMobile = useBreakpointValue({ base: true, md: false });
8271
8299
  const [isFromHyperChain, setIsFromHyperChain] = useState(false);
8272
8300
  const [isToHyperChain, setIsToHyperChain] = useState(false);
8301
+ const pathname = typeof window !== "undefined" ? window.location.pathname : "";
8302
+ const replaceLink = useCallback((url) => {
8303
+ if (typeof window !== "undefined") {
8304
+ window.history.replaceState(null, "", url);
8305
+ }
8306
+ }, []);
8273
8307
  const updateSearchParams = useCallback(
8274
8308
  (params) => {
8275
8309
  if (typeof window === "undefined") return;
@@ -8408,20 +8442,24 @@ var FormBody = ({
8408
8442
  address,
8409
8443
  isToHyperChain
8410
8444
  );
8411
- const fromTokenBalanceHyper = {
8445
+ const fromTokenBalanceHyper = useMemo(() => ({
8412
8446
  decimals: 6,
8413
8447
  formatted: fromTokenBalanceHyperBack?.withdrawable,
8414
8448
  symbol: "USDC",
8415
8449
  value: toBigInt(
8416
- fromTokenBalanceHyperBack?.withdrawable ? fromTokenBalanceHyperBack?.withdrawable : "0")
8417
- };
8418
- const toTokenBalanceHyper = {
8450
+ fromTokenBalanceHyperBack?.withdrawable ? fromTokenBalanceHyperBack?.withdrawable : "0",
8451
+ 6
8452
+ )
8453
+ }), [fromTokenBalanceHyperBack?.withdrawable]);
8454
+ const toTokenBalanceHyper = useMemo(() => ({
8419
8455
  decimals: 6,
8420
8456
  formatted: toTokenBalanceHyperBack?.withdrawable,
8421
8457
  symbol: "USDC",
8422
8458
  value: toBigInt(
8423
- toTokenBalanceHyperBack?.withdrawable ? toTokenBalanceHyperBack?.withdrawable : "0")
8424
- };
8459
+ toTokenBalanceHyperBack?.withdrawable ? toTokenBalanceHyperBack?.withdrawable : "0",
8460
+ 6
8461
+ )
8462
+ }), [toTokenBalanceHyperBack?.withdrawable]);
8425
8463
  useEffect(() => {
8426
8464
  if (fromTokenInfo.chain_id === hyperliquidChainId) {
8427
8465
  setIsFromHyperChain(true);
@@ -8778,15 +8816,6 @@ var FormBody = ({
8778
8816
  const handleToAmountChange = (value) => {
8779
8817
  setToAmount(value);
8780
8818
  };
8781
- useEffect(() => {
8782
- document.getElementById("js_main_form");
8783
- }, [
8784
- isMobile,
8785
- isTrendingOpen,
8786
- setTrendingClientReact,
8787
- quoteInfo,
8788
- setIsTrendingLonger
8789
- ]);
8790
8819
  useEffect(() => {
8791
8820
  const refetchQuote2 = async () => {
8792
8821
  await getQuote({
@@ -8842,7 +8871,7 @@ var FormBody = ({
8842
8871
  transform: ["translate(-50%, -100%)", "translate(-50%, -82.5%)"],
8843
8872
  cursor: toTokenInfo.chain_id === hyperliquidChainId ? "default" : "pointer",
8844
8873
  onClick: handleSwitchTokens,
8845
- color: "#81728C",
8874
+ color: theme.weakTextColor,
8846
8875
  boxSize: {
8847
8876
  base: "20px",
8848
8877
  md: "30px"
@@ -9135,7 +9164,7 @@ var SlippageSettings = ({ refetchQuote }) => {
9135
9164
  boxShadow: "0px 0px 10px 0px rgba(0, 0, 0, 0.1)"
9136
9165
  },
9137
9166
  content: /* @__PURE__ */ jsx(
9138
- Text,
9167
+ Text2,
9139
9168
  {
9140
9169
  variant: {
9141
9170
  base: "content8",
@@ -9170,7 +9199,7 @@ var SlippageSettings = ({ refetchQuote }) => {
9170
9199
  top: 0,
9171
9200
  right: 0,
9172
9201
  children: /* @__PURE__ */ jsx(
9173
- Text,
9202
+ Text2,
9174
9203
  {
9175
9204
  variant: {
9176
9205
  base: "content9",
@@ -9201,7 +9230,7 @@ var SlippageSettings = ({ refetchQuote }) => {
9201
9230
  borderRadius: "10px",
9202
9231
  onClick: () => handlePresetClick(presetValue),
9203
9232
  children: /* @__PURE__ */ jsxs(
9204
- Text,
9233
+ Text2,
9205
9234
  {
9206
9235
  variant: {
9207
9236
  base: "content9",
@@ -9289,7 +9318,7 @@ var SlippageSettings = ({ refetchQuote }) => {
9289
9318
  }
9290
9319
  ),
9291
9320
  /* @__PURE__ */ jsx(
9292
- Text,
9321
+ Text2,
9293
9322
  {
9294
9323
  variant: {
9295
9324
  base: "content9",
@@ -9418,7 +9447,7 @@ var FormTop = ({
9418
9447
  textAlign: "center",
9419
9448
  lineHeight: "28px",
9420
9449
  fontSize: "10px",
9421
- color: countdown <= 10 ? "#FF4D4F" : "#81728C",
9450
+ color: countdown <= 10 ? theme.defaultTextColor : theme.highlightTextColor,
9422
9451
  children: isPolling && !hideCountdown && countdown > 0 ? countdown : ""
9423
9452
  }
9424
9453
  )
@@ -9473,7 +9502,7 @@ var Timer = ({ stop, onTick }) => {
9473
9502
  }
9474
9503
  }, [stop]);
9475
9504
  return /* @__PURE__ */ jsx(
9476
- Text,
9505
+ Text2,
9477
9506
  {
9478
9507
  variant: {
9479
9508
  base: "content8",
@@ -9855,7 +9884,7 @@ var TxState = ({
9855
9884
  if (isSolanaTransaction && solanaFromTxHash) {
9856
9885
  if (solanaStatus === "confirmed") {
9857
9886
  return /* @__PURE__ */ jsx(Link, { href: getSolanaTxLink(solanaFromTxHash), target: "_blank", children: /* @__PURE__ */ jsxs(
9858
- Text,
9887
+ Text2,
9859
9888
  {
9860
9889
  variant: {
9861
9890
  base: "content9",
@@ -9873,7 +9902,7 @@ var TxState = ({
9873
9902
  }
9874
9903
  if (solanaStatus === "failed") {
9875
9904
  return /* @__PURE__ */ jsx(
9876
- Text,
9905
+ Text2,
9877
9906
  {
9878
9907
  variant: {
9879
9908
  base: "content9",
@@ -9885,7 +9914,7 @@ var TxState = ({
9885
9914
  );
9886
9915
  }
9887
9916
  return /* @__PURE__ */ jsx(
9888
- Text,
9917
+ Text2,
9889
9918
  {
9890
9919
  variant: {
9891
9920
  base: "content9",
@@ -9903,7 +9932,7 @@ var TxState = ({
9903
9932
  href: getTxLink(fromTxHash, fromTokenInfo.chain_id),
9904
9933
  target: "_blank",
9905
9934
  children: /* @__PURE__ */ jsxs(
9906
- Text,
9935
+ Text2,
9907
9936
  {
9908
9937
  variant: {
9909
9938
  base: "content9",
@@ -9923,7 +9952,7 @@ var TxState = ({
9923
9952
  }
9924
9953
  if (fromTxHash && receiptStatus === "failed" || isFetched) {
9925
9954
  return /* @__PURE__ */ jsx(
9926
- Text,
9955
+ Text2,
9927
9956
  {
9928
9957
  variant: {
9929
9958
  base: "content9",
@@ -9936,7 +9965,7 @@ var TxState = ({
9936
9965
  }
9937
9966
  if (isTransactionBlocked) {
9938
9967
  return /* @__PURE__ */ jsx(
9939
- Text,
9968
+ Text2,
9940
9969
  {
9941
9970
  variant: {
9942
9971
  base: "content9",
@@ -9948,7 +9977,7 @@ var TxState = ({
9948
9977
  );
9949
9978
  }
9950
9979
  return /* @__PURE__ */ jsx(
9951
- Text,
9980
+ Text2,
9952
9981
  {
9953
9982
  variant: {
9954
9983
  base: "content9",
@@ -10098,7 +10127,7 @@ var TxState = ({
10098
10127
  }
10099
10128
  ),
10100
10129
  /* @__PURE__ */ jsx(
10101
- Text,
10130
+ Text2,
10102
10131
  {
10103
10132
  variant: {
10104
10133
  base: "content8",
@@ -10110,7 +10139,7 @@ var TxState = ({
10110
10139
  )
10111
10140
  ] }),
10112
10141
  /* @__PURE__ */ jsx(
10113
- Text,
10142
+ Text2,
10114
10143
  {
10115
10144
  variant: {
10116
10145
  base: "content8",
@@ -10162,6 +10191,7 @@ var TxState = ({
10162
10191
  md: "16px"
10163
10192
  },
10164
10193
  w: "100%",
10194
+ backgroundColor: theme.assistBgColor,
10165
10195
  children: /* @__PURE__ */ jsxs(HStack, { w: "100%", justify: "space-between", gap: 1, children: [
10166
10196
  /* @__PURE__ */ jsx(
10167
10197
  BoxWithBg,
@@ -10205,6 +10235,7 @@ var TxState = ({
10205
10235
  base: "20px",
10206
10236
  md: "32px"
10207
10237
  },
10238
+ color: theme.weakTextColor,
10208
10239
  as: ArrowRightIcon
10209
10240
  }
10210
10241
  ),
@@ -10251,7 +10282,7 @@ var TxState = ({
10251
10282
  ),
10252
10283
  target: "_blank",
10253
10284
  children: /* @__PURE__ */ jsxs(
10254
- Text,
10285
+ Text2,
10255
10286
  {
10256
10287
  variant: {
10257
10288
  base: "content9",
@@ -10268,7 +10299,7 @@ var TxState = ({
10268
10299
  )
10269
10300
  }
10270
10301
  ) : /* @__PURE__ */ jsx(
10271
- Text,
10302
+ Text2,
10272
10303
  {
10273
10304
  variant: {
10274
10305
  base: "content9",
@@ -10302,7 +10333,7 @@ var TxState = ({
10302
10333
  /* @__PURE__ */ jsxs(HStack, { gap: 1, children: [
10303
10334
  /* @__PURE__ */ jsx(Icon, { as: DateIcon }),
10304
10335
  /* @__PURE__ */ jsx(
10305
- Text,
10336
+ Text2,
10306
10337
  {
10307
10338
  variant: {
10308
10339
  base: "content8",
@@ -10314,7 +10345,7 @@ var TxState = ({
10314
10345
  )
10315
10346
  ] }),
10316
10347
  /* @__PURE__ */ jsx(
10317
- Text,
10348
+ Text2,
10318
10349
  {
10319
10350
  variant: {
10320
10351
  base: "content8",
@@ -10329,7 +10360,7 @@ var TxState = ({
10329
10360
  /* @__PURE__ */ jsxs(HStack, { gap: 1, children: [
10330
10361
  /* @__PURE__ */ jsx(Icon, { as: TimeIcon }),
10331
10362
  /* @__PURE__ */ jsx(
10332
- Text,
10363
+ Text2,
10333
10364
  {
10334
10365
  variant: {
10335
10366
  base: "content8",
@@ -10352,7 +10383,7 @@ var TxState = ({
10352
10383
  /* @__PURE__ */ jsxs(HStack, { gap: 1, children: [
10353
10384
  /* @__PURE__ */ jsx(Icon, { as: MoneyIcon }),
10354
10385
  /* @__PURE__ */ jsx(
10355
- Text,
10386
+ Text2,
10356
10387
  {
10357
10388
  variant: {
10358
10389
  base: "content8",
@@ -10364,7 +10395,7 @@ var TxState = ({
10364
10395
  )
10365
10396
  ] }),
10366
10397
  /* @__PURE__ */ jsx(
10367
- Text,
10398
+ Text2,
10368
10399
  {
10369
10400
  variant: {
10370
10401
  base: "content8",
@@ -10937,7 +10968,7 @@ var MainForm = ({ config }) => {
10937
10968
  href: "https://github.com/wheelx-fi/wheelx-contracts/blob/main/audits/ABDK_WheelX_WheelXContracts_v_1_0.pdf",
10938
10969
  target: "_blank",
10939
10970
  children: /* @__PURE__ */ jsxs(
10940
- Text,
10971
+ Text2,
10941
10972
  {
10942
10973
  color: "#5D6270",
10943
10974
  display: "flex",