PageSourceSearch

https://pancakeswap.finance/_next/static/chunks/8708-84b8583015f4a86f.js

js pancakeswap.finance collected 2026-09-24 08:43:34 UTC 81,399 bytes, 1 lines download raw bytes

1try{let e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="de671997-e7c7-4428-b333-ebafa5a49d73",e._sentryDebugIdIdentifier="sentry-dbid-de671997-e7c7-4428-b333-ebafa5a49d73")}catch(e){}"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8708],{5125:(e,t,n)=>{n.d(t,{A:()=>i});var l=n(350979);n(25963);var r=n(257057);let i=e=>(0,l.jsxs)(r.A,{viewBox:"0 0 1024 1024",...e,children:[(0,l.jsxs)("g",{children:[(0,l.jsx)("path",{d:"M1041.52 0H-27V1024H1041.52V0Z",fill:"#2980FE"}),(0,l.jsxs)("g",{clipPath:"url(#clip0_408_225)",children:[(0,l.jsx)("path",{d:"M406.796 438.643H406.927C406.796 437.857 406.796 436.94 406.796 436.154V438.643Z",fill:"#29AEFF"}),(0,l.jsx)("path",{d:"M667.602 463.533H523.249V724.076C523.249 736.389 533.204 746.345 545.517 746.345H645.333C657.647 746.345 667.602 736.389 667.602 724.076V463.533Z",fill:"white"}),(0,l.jsx)("path",{d:"M453.563 277H448.716H190.269C177.955 277 168 286.955 168 299.269V389.653C168 401.967 177.955 411.922 190.269 411.922H250.918H275.021V438.644V724.731C275.021 737.045 284.976 747 297.289 747H392.128C404.441 747 414.396 737.045 414.396 724.731V438.644V436.156V411.922H438.499H448.323H453.17C490.372 411.922 520.631 381.663 520.631 344.461C521.024 307.259 490.765 277 453.563 277Z",fill:"white"}),(0,l.jsx)("path",{d:"M667.735 463.533V645.35C672.713 646.529 677.821 647.446 683.061 648.232C690.397 649.28 697.994 649.935 705.592 650.066C705.985 650.066 706.378 650.066 706.902 650.066V505.45C685.026 504.009 667.735 485.801 667.735 463.533Z",fill:"url(#paint0_linear_408_225)"}),(0,l.jsx)("path",{d:"M709.781 277C606.822 277 523.249 360.573 523.249 463.533C523.249 552.084 584.946 626.225 667.733 645.35V463.533C667.733 440.347 686.596 421.484 709.781 421.484C732.967 421.484 751.83 440.347 751.83 463.533C751.83 483.051 738.6 499.425 720.523 504.14C717.117 505.057 713.449 505.581 709.781 505.581V650.066C713.449 650.066 716.986 649.935 720.523 649.804C818.505 644.171 896.314 562.956 896.314 463.533C896.445 360.573 812.872 277 709.781 277Z",fill:"white"}),(0,l.jsx)("path",{d:"M709.78 650.066V505.581C708.733 505.581 707.816 505.581 706.768 505.45V650.066C707.816 650.066 708.864 650.066 709.78 650.066Z",fill:"white"})]})]}),(0,l.jsxs)("defs",{children:[(0,l.jsxs)("linearGradient",{id:"paint0_linear_408_225",x1:"709.844",y1:"556.827",x2:"667.753",y2:"556.827",gradientUnits:"userSpaceOnUse",children:[(0,l.jsx)("stop",{stopColor:"white"}),(0,l.jsx)("stop",{offset:"0.9667",stopColor:"white",stopOpacity:"0.3233"}),(0,l.jsx)("stop",{offset:"1",stopColor:"white",stopOpacity:"0.3"})]}),(0,l.jsx)("clipPath",{id:"clip0_408_225",children:(0,l.jsx)("rect",{width:"728.448",height:"470",fill:"white",transform:"translate(168 277)"})})]})]})},16720:(e,t,n)=>{let l;n.d(t,{$:()=>r});let r=()=>(l||(l=new Audio("https://cdn.pancakeswap.com/swap.mp3")),l)},48099:(e,t,n)=>{n.d(t,{D:()=>y,A:()=>L});var l=n(350979),r=n(769932),i=n(76273),s=n(686815),o=n(797837),a=n(5125),d=n(861485),c=n(508195),u=n(512729),h=n(41811),x=n(796898),p=n(579518),m=n(501823),f=n(557423),g=n(38519),v=n(17581),j=n(495964),A=n(662928);let C=(0,n(381033).T)(async e=>{try{if("function"!=typeof e.getProvider)return!1;let t=await e.getProvider();return!!(null==t?void 0:t.request)&&"function"==typeof t.request&&await t.request({method:"wallet_watchAsset",params:{}}).then(()=>!0).catch(e=>{if((null==e?void 0:e.code)===-32601||(null==e?void 0:e.code)===-32004)throw e;return!0})}catch(e){if((null==e?void 0:e.code)===-32601||(null==e?void 0:e.code)===-32004)return!1;return console.error(e,"Error while checking wallet token registration support"),!1}},{resolver:e=>null==e?void 0:e.id});var w=n(25963);let b={};var y=function(e){return e[e.NO_TEXT=0]="NO_TEXT",e[e.TEXT=1]="TEXT",e[e.TEXT_WITH_ASSET=2]="TEXT_WITH_ASSET",e}({});let k={Binance:i.A,"Coinbase Wallet":s.A,Opera:o.A,TokenPocket:a.A,"Trust Wallet":d.A,MetaMask:c.A},I=function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],{connector:n}=(0,v.F)();return(0,A.I)({queryKey:["walletIcon",null==n?void 0:n.uid],queryFn:async()=>
1{if(!n)return;let t=null==n?void 0:n.name,r={width:"16px",...e&&{ml:e}};if(t&&k[t]){let e=k[t];return(0,l.jsx)(e,{...r})}try{if("function"!=typeof n.getProvider)return;let e=await n.getProvider();if(e.isTrust)return(0,l.jsx)(d.A,{...r});if(e.isCoinbaseWallet)return(0,l.jsx)(s.A,{...r});if(e.isTokenPocket)return(0,l.jsx)(a.A,{...r});if(e.isOkxWallet)return(0,l.jsx)(u.A,{...r});if(e.isMetaMask)return(0,l.jsx)(c.A,{...r});return(0,l.jsx)(h.A,{...r})}catch(e){console.error("Error fetching provider for wallet icon",e)}},enabled:!!(t&&n),staleTime:1/0,retry:!1})},L=e=>{let{tokenAddress:t,tokenSymbol:n,tokenDecimals:i,tokenLogo:s,textOptions:o=0,marginTextBetweenLogo:a="0px",tooltipPlacement:d="auto",ml:c,mr:u,wrapperProps:h,buttonText:y,showTooltip:k,showWalletIcon:L=!0,...S}=e,{t:M}=(0,r.A)(),{isMobile:T}=(0,x.A)(),{connector:R,isConnected:E}=(0,v.F)(),{data:N}=(0,j.G)(),{isCanRegisterToken:O}=(()=>{let{connector:e}=(0,v.F)(),{data:t}=(0,A.I)({queryKey:["walletSupportsTokenRegistration",null==e?void 0:e.uid],queryFn:()=>C(e),enabled:!!e,retry:!1});return{isCanRegisterToken:null!=t&&t}})(),{data:V}=I(a,O),{targetRef:F,tooltipVisible:Z,tooltip:H}=(0,p.A)(M("Add to your wallet"),{placement:d,avoidToStopPropagation:T}),P=(0,w.useCallback)(async()=>{let e=s?b[s]?void 0:s:void 0;if(N&&t&&n&&i)try{await (0,g.w)(N,{type:"ERC20",options:{address:t,symbol:n,image:e,decimals:i}})}catch(e){console.error("Error watchAsset",e)}},[s,N,t,n,i]);return N&&(!R||"Binance"!==R.name)&&R&&E&&O?(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(m.A,{alignItems:"center",justifyContent:"center",ref:F,ml:c,mr:u,...h,children:(0,l.jsxs)(f.A,{...S,title:M("Add to your wallet"),onClick:P,children:[null!=y?y:((e,t,n)=>0!==e&&(1===e?n("Add to Wallet"):n("Add %asset% to Wallet",{asset:t})))(o,n,M),L&&V]})}),(void 0!==k?k:0===o)&&Z&&H]}):null}},88579:(e,t,n)=>{n.d(t,{A:()=>s});var l=n(350979);n(25963);var r=n(935711),i=n(482335);let s=e=>{let{children:t,component:n,isOpen:s=!1,...o}=e;return(0,l.jsx)(r.A,{options:{placement:"bottom"},component:n,isOpen:s,children:(0,l.jsx)(i.SH,{...o,children:t})})}},102342:(e,t,n)=>{n.d(t,{A:()=>O,_:()=>N});var l=n(350979),r=n(228876),i=n(769932),s=n(3197),o=n(226464),a=n(605641),d=n(579518),c=n(796147),u=n(501823),h=n(672946),x=n(979332),p=n(962478),m=n(673115),f=n(785459),g=n(310085),v=n(865109),j=n(557423),A=n(721745),C=n(158956),w=n(662928),b=n(187012),y=n(768159),k=n(276686),I=n(968349),L=n(118708),S=n(25963),M=n(726053),T=n(735872),R=n(518400),E=n(733775);function N(){let{t:e}=(0,i.A)();return(0,l.jsx)(o.A,{variant:"warning",children:(0,l.jsxs)(a.A,{children:[e("Anyone can create tokens with any name, including fake or misleading versions of existing projects.")," ",(0,l.jsx)("b",{children:e("Buying such fraudulent tokens can lead to permanent loss of funds.")})]})})}let O=function(e){let{tokens:t,handleCurrencySelect:n,chainId:o}=e,{chainId:O}=(0,I.ax)(),V=o||O,F=(0,E.$8)(V),Z=(0,E.iM)(),{t:H}=(0,i.A)(),[P,U]=(0,S.useState)(!1),_=(0,R.Z0)(),B=(0,T.qR)(),W=(0,L.md)(M.yp),$=(0,S.useMemo)(()=>t.filter(e=>!(0,M.OL)(W,e)),[W,t]),{data:D}=(0,w.I)({queryKey:["has-risks",$],queryFn:async()=>(await Promise.all($.map(e=>(0,k.Z)(e.address,e.chainId)))).some(e=>e.riskLevel>=b.K_.MEDIUM),enabled:!!$.length,refetchOnWindowFocus:!1,refetchOnReconnect:!1,refetchOnMount:!1}),{targetRef:q,tooltip:K,tooltipVisible:z}=(0,d.A)(H("I have read the scanning result, understood the risk and want to proceed with token importing."));return(0,l.jsxs)(c.mm,{gap:"lg",children:[(0,l.jsx)(N,{}),t.map(e=>{var t,n;let i=e.chainId&&(null==B||null==(n=B[e.chainId])||null==(t=n[e.address])?void 0:t.list),s=e.address?`${(0,A.A)(e.address)}`:null;return(0,l.jsxs)(u.A,{flexDirection:["column","column","row"],alignItems:["left","left","center"],justifyContent:"space-between",children:[(0,l.jsxs)(h.A,{gridTemplateRows:"1fr 1fr 1fr 1fr",gridGap:"4px",children:[void 0!==i?(0,l.jsxs)(x.A,{variant:"success",outline:!0,scale:"sm",startIcon:i.logoURI&&(0,l.jsx)(C.O,{logoURI:i.logoURI,size:"12px"}),children:[H("via")," ",i.name]}):(0,l.jsx)(x.A,{variant:"failure",outline:!0,scale:"sm",startIcon:(0,l.jsx)(p.A,{color:"failure"}),children:H("Unknown Source")}),(0,l.jsxs)(u.A,{alignItems:"center",children:[(0,l.jsx)(a.A,{mr:"8px",children:e.name}),(0,l.jsxs)(a.A,{children:["(",e.symbol,")"]})]}),!!e.chainId&&(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(a.A,{mr:"4px",children:s}),(0,l.jsxs)(m.A,{href:Z(e.address,"address",e.chainId),external:!0,children:["(",H("View on %site%",{site:F}),e.chainId===r.nU.BSC&&(0,l.jsx)(f.A,{color:"primary",ml:"4px"}),")"]})]})]}),e&&V&&y.s.includes(V)&&(0,l.jsx)(u.A,{mt:["20px","20px","0"],children:(0,l.jsx)(b.Ay,{token:e})})]},e.address)}),(0,l.jsxs)(h.A,{gridTemplateRows:"1fr 1fr",gridGap:"4px",children:[(0,l.jsxs)(u.A,{alignItems:"center",onClick:()=>U(!P),children:[(0,l.jsx)(g.A,{scale:"sm",name:"confirmed",type:"checkbox",checked:P,onChange:()=>U(!P)}),(0,l.jsx)(a.A,{ml:"8px",style:{userSelect:"none"},children:D?H("I acknowledge the risk"):H("I understand")}),D&&(0,l.jsxs)("div",{ref:q,children:[(0,l.jsx)(v.A,{color:"textSubtle"}),z&&K]})]}),(0,l.jsx)(j.A,{variant:"danger",disabled:!P,onClick:()=>
1{t.forEach(e=>{var t;let n=V&&(null==B||null==(t=B[e.chainId])?void 0:t[e.address]),l=e;n&&(l=new s.Xs({...e,logoURI:n.token.logoURI,name:e.name||n.token.name})),_(l)}),n&&n(t[0])},className:".token-dismiss-button",children:D?H("Proceed"):H("Import")})]})]})}},129166:(e,t,n)=>{n.d(t,{A:()=>e1});var l=n(350979),r=n(25963),i=n(968349),s=n(419041),o=n(954335),a=n(90811),d=n(532537),c=n(72912),u=n(861932),h=n(569019),x=n(733775),p=n(401368),m=n(442828),f=n(708033),g=n(228876),v=n(179087),j=n(769932),A=n(311560),C=n(607842),w=n(3197),b=n(796898),y=n(796147),k=n(428089),I=n(605641),L=n(966983),S=n(501823),M=n(28192),T=n(371665),R=n(862373),E=n(734658),N=n(659918),O=n(331281),V=n(662928),F=n(987212),Z=n(801633),H=n(670420),P=n(821399),U=n(767385),_=n(306411),B=n(735872),W=n(131619),$=n(460296),D=n(320669),q=n(970645),K=n(680797),z=n(525033),Q=n(898719),G=n(842807);let J=K.I4.div.withConfig({componentId:"sc-1272f929-0"})(["display:inline-block;vertical-align:top;margin-right:8px;"]),Y=K.I4.div.withConfig({componentId:"sc-1272f929-1"})(["display:flex;align-items:center;padding:6px 4px;transition:background-color 0.15s;border-radius:",";color:"," !important;background-color:",";&:hover{cursor:",";background-color:",";}"],e=>{let{theme:t}=e;return t.radii.default},e=>{let{theme:t,disable:n}=e;return n?t.colors.backgroundAlt:t.colors.textSubtle},e=>{let{theme:t,disable:n}=e;return n?t.colors.textSubtle:t.colors.input},e=>{let{disable:t}=e;return!t&&"pointer"},e=>{let{theme:t,disable:n}=e;return!n&&t.colors.background}),X=K.I4.div.withConfig({componentId:"sc-1272f929-2"})(["white-space:nowrap;overflow-x:auto;scroll-snap-type:x mandatory;scroll-behavior:smooth;-webkit-overflow-scrolling:touch;&::-webkit-scrollbar{display:none;-ms-overflow-style:none;scrollbar-width:none;}"]);function ee(e){let{chainId:t,onSelect:n,selectedCurrency:i,commonBasesType:o,supportCrossChain:a,disabledCurrencies:d,showNative:c=!0}=e,u=(0,s.sA)(t),{t:h}=(0,j.A)(),x=h(o===G.AS.LIQUIDITY?"Common bases":"Popular tokens"),p=(0,r.useMemo)(()=>(null==i?void 0:i.isNative)&&(null==i?void 0:i.chainId)===t||!!(null==d?void 0:d.find(e=>e.equals(u))),[t,d,u,null==i?void 0:i.chainId,null==i?void 0:i.isNative]);return(0,l.jsxs)(y.mm,{gap:"sm",children:[(0,l.jsxs)(D.eF,{children:[(0,l.jsx)(I.A,{color:"textSubtle",fontSize:"14px",children:x}),o===G.AS.LIQUIDITY&&(0,l.jsx)(z.PT,{text:h("These tokens are commonly paired with other tokens."),ml:"4px"})]}),(0,l.jsxs)(X,{children:[c&&(0,l.jsx)(J,{children:(0,l.jsxs)(Y,{onClick:()=>{p||n(u)},disable:p,children:[(0,l.jsx)(Q.Z,{showChainLogo:a,currency:u,containerStyle:{position:"relative",top:"1px"}}),(0,l.jsx)(I.A,{px:"4px",color:"inherit",children:null==u?void 0:u.symbol})]})}),(t&&q.HL[t]||[]).map(e=>{var t;let r=(null==i||null==(t=i.equals)?void 0:t.call(i,e))||!!(null==d?void 0:d.find(t=>t.equals(e)));return(0,l.jsx)(J,{children:(0,l.jsxs)(Y,{onClick:()=>!r&&n(e),disable:r,children:[(0,l.jsx)(Q.Z,{showChainLogo:a,currency:e,style:{borderRadius:"50%"},containerStyle:{position:"relative",top:"1px"}}),(0,l.jsx)(I.A,{px:"4px",color:"inherit",children:e.symbol})]})},`buttonBase#${e.address}`)})]})]})}var et=n(995315),en=n(239612);function el(e){let{onSelect:t,selectedCurrency:n,supportCrossChain:i,allowedChainIds:s}=e,{t:a}=(0,j.A)(),d=(0,_.gO)(),c=(0,B.V6)(),u=(0,r.useMemo)(()=>s?d.filter(e=>s.includes(e.chainId)):d,[d,s]),h=(0,r.useMemo)(()=>u.some(e=>(0,g.fT)(e.chainId)),[u]),{tokenList:p}=(0,o.F)(h),m=(0,r.useCallback)(e=>{try{if(e.isNative){if((0,g.fT)(e.chainId))return A.VU;return A.we.onChain(e.chainId)}if(!e.address)return null;if((0,g.fT)(e.chainId)){let t=p.find(t=>t.address===e.address);if(t)return t;return new E.xx({chainId:e.chainId,address:e.address,decimals:e.decimals,symbol:e.symbol,name:e.name,logoURI:"",programId:"TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"})}let n=(0,x.QR)(e.address);if(n){var t;let l=(null!=(t=c[e.chainId])?t:{})[n];if(l)return l.token}return new A.ou(e.chainId,e.address,e.decimals,e.symbol,e.name)}catch{return null}},[c,p]);return 0===u.length?null:(0,l.jsxs)(y.mm,{gap:"sm",children:[(0,l.jsxs)(et.A,{gap:"3px",children:[(0,l.jsx)(en.A,{width:"18px",color:"textSubtle"}),(0,l.jsx)(I.A,{color:"textSubtle",fontSize:"14px",mb:"2px",children:a("Recent Swaps")})]}),(0,l.jsx)(X,{children:u.map(e=>{var r,s;let o=m(e);if(!o)return null;let a=!!(null==n||null==(r=n.equals)?void 0:r.call(n,o));return(0,l.jsx)(J,{children:(0,l.jsxs)(Y,{onClick:()=>!a&&t(o),disable:a,children:[(0,l.jsx)(Q.Z,{showChainLogo:i,currency:o,style:{borderRadius:"50%"},containerStyle:{position:"relative",top:"1px"}}),(0,l.jsx)(I.A,{px:"4px",color:"inherit",children:e.chainId===g.nU.OPBNB?`${e.symbol} (opBNB)`:e.symbol})]})},`recent-${e.chainId}-${null!=(s=e.address)?s:"native"}`)})})]})}var er=n(91168),ei=n(687287),es=n(810286),eo=n(48099),ea=n(266283),ed=n(96278),ec=n(427554),eu=n(874522),eh=n(452301),ex=n(490233),ep=n(494350),em=n(469079),ef=n(721745),eg=n(899188),ev=n(784027),ej=n(168927),eA=n(279355);function eC(e){return(null==e?void 0:e.isToken)?e.address:(null==e?void 0:e.isNative)?e.symbol:""}function ew(e,t){return!!(e&&t&&e.chainId===t.chainId&&e.equals(t))}function eb(e){if(e&&!e.isNative)return`${e.chainId}:${e.wrapped.address.toLowerCase()}`}let ey=K.I4.div.withConfig({componentId:"sc-96c9217e-0"})(["padding:4px 20px;height:56px;display:grid;grid-gap:16px;align-items:center;"]);function ek(e){let{balance:t}=e,n=(0,ei.Wu)(t,4);return(0,l.jsx)(es.g3,{amount:t,bold:!0,style:{whiteSpace:"nowrap",overflow:"hidden",maxWidth:"5rem",textOverflow:"ellipsis"},children:n})}let eI=(0,K.I4)(D.JA).withConfig({componentId:"sc-96c9217e-1"}
1)(["height:56px;padding:0 8px;"]),eL=(0,K.I4)(et.A).withConfig({componentId:"sc-96c9217e-2"})(["opacity:0;pointer-events:none;transition:opacity 0.15s;"]),eS=K.I4.div.withConfig({componentId:"sc-96c9217e-3"})(["width:100%;padding:6px 12px;border-radius:16px;display:grid;grid-template-columns:auto minmax(auto,1fr) minmax(0,72px);grid-gap:10px;cursor:",";&:hover{background-color:",";}&:hover ",",&:focus-within ","{opacity:1;pointer-events:auto;}opacity:",";transition:background-color 0.15s;"],e=>{let{disabled:t}=e;return!t&&"pointer"},e=>{let{theme:t,disabled:n}=e;return!n&&t.colors.background},eL,eL,e=>{let{disabled:t,selected:n}=e;return t||n?.5:1}),eM=K.I4.span.withConfig({componentId:"sc-96c9217e-4"})(["display:inline-flex;align-items:center;height:16px;margin-left:4px;padding:0 6px;border-radius:999px;font-size:10px;font-weight:600;white-space:nowrap;background:",";color:",";"],e=>{let{$tone:t,theme:n}=e;return"failure"===t?"rgba(237, 75, 158, 0.12)":"warning"===t?"rgba(255, 178, 55, 0.16)":n.colors.tertiary},e=>{let{$tone:t,theme:n}=e;return"failure"===t?n.colors.failure:"warning"===t?n.colors.warning:n.colors.textSubtle});function eT(e){let{selectedCurrency:t}=e,{t:n}=(0,j.A)(),{isMobile:r}=(0,b.A)();return t.isNative?null:(0,l.jsx)(et.A,{ml:"8px",alignItems:"center",children:r?(0,l.jsx)(I.A,{color:"textSubtle",fontSize:"12px",children:(0,ef.A)(t.wrapped.address)}):(0,l.jsxs)(eL,{alignItems:"center",children:[(0,l.jsx)(ex.i,{"data-dd-action-name":"Copy token address",width:"13px",buttonColor:"textSubtle",text:t.wrapped.address,tooltipMessage:n("Token address copied"),defaultTooltipMessage:n("Copy token address"),tooltipPlacement:"top"}),(0,l.jsx)(ed.k,{address:t.wrapped.address,chainId:t.chainId,type:"token",color:"textSubtle",width:"15px",ml:"8px",tooltipPlacement:"top"}),t.chainId===g.Cb.SOLANA?null:(0,l.jsx)(eo.A,{"data-dd-action-name":"Add to wallet",variant:"text",p:"0",ml:"12px",height:"auto",width:"fit-content",tokenAddress:t.wrapped.address,tokenSymbol:t.symbol,tokenDecimals:t.decimals,tokenLogo:t.wrapped instanceof w.Xs?t.wrapped.logoURI:void 0,tooltipPlacement:"top"})]})})}function eR(e){var t;let{currency:n,onSelect:s,isSelected:o,otherSelected:a,style:d,showChainLogo:c,status:u}=e,{account:h,solanaAccount:p}=(0,i.W7)(),{t:f}=(0,j.A)(),v=eC(n),C=(0,B.V6)(),w=(0,x.VN)(C,n),b=(0,W.A1)(n),k=(0,ec.V)(n),[L,S]=(0,r.useState)(!1);(0,r.useEffect)(()=>{if(S(!1),k)return;let e=setTimeout(()=>S(!0),8e3);return()=>clearTimeout(e)},[k,v]);let M=(0,em.y)(n,!!(null==k?void 0:k.greaterThan(0))),T=(0,r.useMemo)(()=>{if(k&&M.data)return new er.A(k.toExact()).times(M.data).toFixed(2)},[k,M]),R=(0,r.useMemo)(()=>n.chainId in A.nU?h:n.chainId===g.Cb.SOLANA?p:h,[h,p,n.chainId]),E=(0,r.useMemo)(()=>{if((0,g.fT)(n.chainId))return"Solana";let e=eg.rY.find(e=>e.id===n.chainId);return e?(0,ev.R)(e.name):""},[n.chainId]);return(0,l.jsx)(eI,{style:d,className:`token-item-${v}`,children:(0,l.jsxs)(eS,{disabled:o,selected:a,onMouseDown:e=>{o||0!==e.button||e.target.closest("a, button")||(e.preventDefault(),s())},children:[(0,l.jsx)(Q.Z,{showChainLogo:c,currency:n,size:"40px"}),(0,l.jsxs)(y.VP,{children:[(0,l.jsxs)(et.A,{alignItems:"center",children:[(0,l.jsx)(I.A,{bold:!0,children:(0,m.En)(null==n||null==(t=n.wrapped)?void 0:t.address,null==n?void 0:n.chainId,null==n?void 0:n.symbol)}),(0,l.jsx)(I.A,{color:"textSubtle",small:!0,ml:"4px",ellipsis:!0,children:null==n?void 0:n.name}),(null==u?void 0:u.label)&&(0,l.jsx)(eM,{$tone:u.tone,children:u.label}),(0,l.jsx)(eT,{selectedCurrency:n})]}),(0,l.jsxs)(I.A,{color:"textSubtle",fontSize:"12px",ellipsis:!0,bold:!0,maxWidth:"200px",children:[!w&&b&&`${f("Added by user")} •`," ",E]})]}),(0,l.jsx)(D.Bp,{style:{justifySelf:"flex-end"},children:k?(0,l.jsxs)(y.mm,{justify:"flex-end",children:[(0,l.jsx)(ek,{balance:k}),(0,l.jsx)("div",{children:T&&Number(T)>0&&(0,l.jsxs)(I.A,{color:"textSubtle",small:!0,ellipsis:!0,maxWidth:"200px",children:["$",T]})})]}):R&&!L?(0,l.jsx)(ej.A,{}):(0,l.jsx)(ep.A,{})})]})})}let eE="popular-header",eN="all-tokens-header";function eO(e){let{height:t,currencies:n,inactiveCurrencies:i,selectedCurrency:o,onCurrencySelect:a,otherCurrency:d,fixedListRef:c,showNative:u,showImportView:h,setImportToken:x,breakIndex:p,showChainLogo:m,chainId:f,popularTokens:v,currencyStatus
1Map:A,showNativeAfterTokens:C,nativeInsertIndex:w}=e,b=(0,s.sA)(f),y=(null==v?void 0:v.length)?v.length+2:0,k=(0,r.useMemo)(()=>{let e,t=y>0?[eE,...v,eN]:[];if(u){let l=null!=w?w:C?n.length:0;e=[...t,...n.slice(0,l),b,...n.slice(l),...i]}else e=[...t,...n,...i];if(void 0!==p){let n=p+t.length;e=[...e.slice(0,n),void 0,...e.slice(n)]}return e},[p,n,i,u,C,w,b,v,y]),{t:L}=(0,j.A)(),S=(0,r.useCallback)(e=>{var t;let{data:r,index:i,style:s}=e,c=r[i],u=ew(o,c),p=ew(d,c),v=!!((0,g.fT)(f)&&(null==c?void 0:c.wrapped)&&(null==d?void 0:d.wrapped)&&d.wrapped.equals(c.wrapped)&&!p);if(c===eE)return(0,l.jsx)("div",{style:{...s,display:"flex",alignItems:"center",paddingLeft:"20px"},children:(0,l.jsx)(I.A,{color:"textSubtle",small:!0,children:L("Popular Tokens")})});if(c===eN)return(0,l.jsx)("div",{style:{...s,display:"flex",alignItems:"end",paddingLeft:"20px",paddingBottom:"8px"},children:(0,l.jsx)(I.A,{color:"textSubtle",small:!0,children:L("All Tokens")})});if(void 0===c)return(0,l.jsx)(ey,{style:s,children:(0,l.jsx)(ea.k0,{padding:"8px 12px",borderRadius:"8px",children:(0,l.jsxs)(D.JA,{children:[(0,l.jsx)(I.A,{small:!0,children:L("Expanded results from inactive Token Lists")}),(0,l.jsx)(z.PT,{text:L("Tokens from inactive lists. Import specific tokens below or click 'Manage' to activate more lists."),ml:"4px"})]})})});let j=()=>a(c),C=(0,eh.dc)(c,null==c?void 0:c.chainId);return i>y+n.length&&C?(0,l.jsx)(eA.A,{onCurrencySelect:j,style:s,token:C,showImportView:h,setImportToken:x,dim:!0}):(0,l.jsx)(eR,{style:s,currency:c,isSelected:u||v,onSelect:j,otherSelected:p,showChainLogo:m,status:null==A?void 0:A[null!=(t=eb(c))?t:""]})},[f,o,d,n.length,y,a,L,h,x,m,A]),M=(0,r.useCallback)((e,t)=>`${eC(t[e])}-${e}`,[]),T=(0,r.useCallback)(e=>k[e]===eE?36:56,[k]);return(0,l.jsx)(eu._m,{height:t,ref:c,width:"100%",itemData:k,itemCount:k.length,itemSize:T,itemKey:M,children:S},y)}var eV=n(727353);let eF=e=>{let{value:t,inputRef:n=null,compact:r=!1,handleEnter:i,onInput:s,autoFocus:o=!0,placeholder:a,...d}=e,{t:c}=(0,j.A)();return(0,l.jsx)(eV.A,{id:"token-search-input",placeholder:null!=a?a:c("Search name / address"),scale:r?"md":"lg",autoComplete:"off",value:t,ref:n,onChange:s,onKeyDown:i,autoFocus:o,...d})};var eZ=n(59678),eH=n(24153),eP=n(617636),eU=n(88579),e_=n(941672),eB=n(33409),eW=n(619174),e$=n.n(eW),eD=n(787288),eq=n.n(eD),eK=n(326848),ez=n(18468),eQ=n(387165);let eG=(0,K.I4)(S.A).withConfig({componentId:"sc-cf8deab9-0"})(["flex-direction:column;overflow:hidden;background-color:",";border:1px solid ",";border-radius:",";animation:",";"],e=>{let{theme:t}=e;return t.colors.input},e=>{let{theme:t}=e;return t.colors.cardBorder},e=>{let{theme:t}=e;return t.radii.card},()=>(0,K.AH)([""," 0.2s ease"],eZ.Sx)),eJ=(0,K.I4)(S.A).withConfig({componentId:"sc-cf8deab9-1"})(["padding:8px 16px;&:hover{cursor:pointer;background-color:",";}transition:background-color 0.15s;"],e=>{let{theme:t}=e;return t.colors.background}),eY=()=>{let e=(0,eK.useRouter)();return e.pathname.includes("twap")||e.pathname.includes("limit")};function eX(e){var t,n;let{chainId:s,onSelect:o,isDependent:a,allowedChainIds:d,preserveChainOrder:c=!1}=e,{chainId:u}=(0,i.ax)(),h=eY(),x=null!=s?s:u,{chains:p,loading:m}=(0,Z.kk)({originChainId:a?u:x}),f=(()=>{if(eY())return eQ.fQ})(),{t:v}=(0,j.A)(),A=h&&a,C=(0,r.useMemo)(()=>{let e=d?new Set(d):void 0,t=t=>!e||e.has(t.id);return e?g.P_.filter(t):A?g.P_.filter(e=>e.id===x).filter(t):a?g.P_.filter(e=>e.id===x||p.includes(e.id)).filter(t):g.P_.filter(e=>{var t;return e.id!==g.Cb.APTOS&&(e.id===g.nU.MONAD_TESTNET||(!("testnet"in e)||!e.testnet)&&(null==(t=ez.Bt.find(t=>t.id===e.id))||!t.testnet))&&(!f||f.includes(e.id))}).filter(t)},[d,p,x,a,f,A]),w=(0,r.useMemo)(()=>{if(!d)return C;let e=new Map(d.map((e,t)=>[e,t]));return[...C].sort((t,n)=>{var l,r;return(null!=(l=e.get(t.id))?l:Number.MAX_SAFE_INTEGER)-(null!=(r=e.get(n.id))?r:Number.MAX_SAFE_INTEGER)})},[d,C]),b=(0,r.useMemo)(()=>C.find(e=>e.id===x),[x,C]),k=(0,r.useRef)(null),L=(null==(n=k.current)||null==(t=n.getBoundingClientRect())?void 0:t.width)||370,[S,M,T]=(0,r.useMemo)(()=>{let e=C.filter(e=>e.id!==x),t=Math.max(1,Math.floor((L-42-5)/47));return[e,eq()(e,t),e$()(e,t)]},[C,x,L]);return(0,l.jsxs)(y.mm,{gap:"sm",children:[(0,l.jsx)(eH.eF,{children:(0,l.jsxs)(I.A,{color:"textSubtle",fontSize:"14px",children:[v("Network"),b?`: ${(0,ev.R)(b.fullName)}`:""]})}),(0,l.jsx)(X,{ref:k,children:(0,l.jsxs)(eP.A,{loading:!d&&m,initialWidth:370,initialHeight:40,children:[c?w.map(e=>{let t=e.id===x;return(0,l.jsx)(J,{style:{marginRight:"5px",height:"40px"},children:(0,l.jsx)(Y,{...t?{disable:!0,id:"selected-chain-wrapper"}:{onClick:()=>o(e.id)},style:{height:"40px"},children:(0,l.jsx)(eB.P,{imageStyles:{borderRadius:"35%"},chainId:e.id,px:"4px",pt:"5px"})})},`buttonNetworkSelect#${e.id}`)}):(0,l.jsxs)(l.Fragment,{children:[b?(0,l.jsx)(J,{style:{marginRight:"5px"},children:(0,l.jsx)(Y,{style:{height:"40px"},id:"selected-chain-wrapper",disable:!0,children:(0,l.jsx)(eB.P,{imageStyles:{borderRadius:"35%"},chainId:b.id,px:"4px",pt:"5px"})})}):null,M.map(e=>(0,l.jsx)(J,{style:{marginRight:"5px",height:"40px"},children:(0,l.jsx)(Y,{onClick:()=>o(e.id),style:{height:"40px"},children:(0,l.jsx)(eB.P,{imageStyles:{borderRadius:"35%"},chainId:e.id,px:"4px",pt:"5px"})})},`buttonNetworkSelect#${e.id}`))]}),!c&&T.length>0&&(0,l.jsx)(eU.A,{component:(0,l.jsx)(J,{style:{marginRight:0,width:"50px"},children:(0,l.jsxs)(Y,{style:{height:"40px"},children:[(0,l.jsxs)(I.A,{color:"textSubtle",bold:!0,pl:"6px",children:["+",T.length]}),(0,l.jsx)(e_.A,{color:"textSubtle",width:"22px",height:"22px",ml:"-1px"})]})}),children:(0,l.jsx)(eG,{children:T.map(e=>(0,l.jsxs)(eJ,{onClick:()=>o(e.id),pb:"8px",children:[(0,l.jsx)(eB.P,{chainId:e.id,px:"4px",imageStyles:{borderRadius:"35%"},pt:"2px"}),(0,l.jsx)(I.A,{color:"inherit",px:"6px",children:(0,ev.R)(e.fullName)})]},`buttonNetworkSelect#${e.id}`))})})]})})]})}var e0=n(16720);let e1=function(e){let{selectedCurrency:t,onCurrencySelect:n,otherSelectedCurrency:q,showCommonBases:K,commonBasesType:z,showSearchInput:Q=!0,searchInputPlaceholder:J,showImportView:X,setImportToken:et,height:en,tokensToShow:er,showChainLogo:ei,showSearchHeader:es,onDismiss:eo,headerTitle:ea,setSelectedChainId:ed,selectedChainId:ec,mode:eu,supportCrossChain:eh=!1,showNative:ex,onSettingsClick:ep,showMultichainBalances:em=!1,enableMultichainSearch:ef=!1,currencyStatus
1Map:eg,allowedChainIds:ev,showNativeChainIds:ej,showNativeAfterTokens:eC,nativeInsertIndex:ew,onChainSelect:ey,preserveChainOrder:ek}=e,{t:eI}=(0,j.A)(),[eL,eS]=(0,r.useState)(""),eM=(0,v.d7)((0,m.A3)(eL,ec,eL),200),eT=(0,r.useRef)(),{isMobile:eR}=(0,b.A)(),[eE]=(0,R.W)(),{chainId:eN}=(0,i.ax)(),eV=ec===g.Cb.SOLANA,eZ=(0,W.JQ)(ec),eH=(0,B.V6)(),{tokenList:eP}=(0,o.F)(eV),eU=(0,s.sA)(ec),{account:e_,solanaAccount:eB}=(0,i.W7)(),eW=(0,r.useMemo)(()=>eP.map(e=>e.address),[eP]),e$=(0,d.y)(eB,eW),eD=(0,r.useMemo)(()=>eW.filter(e=>{var t;return null==(t=e$.balances.get(e))?void 0:t.gt(0)}),[eW,e$.balances]),{data:eq}=(0,c.h3)({mints:eD,enabled:eV&&eD.length>0}),eK=(0,a.n)(eV&&!er?eM:void 0),ez=(0,W.rd)(er?void 0:eM,ec),eQ=eV?eK:ez,eG=(0,W.A1)(ez,ec),eJ=eV?!!eP.find(e=>e.address===(null==eQ?void 0:eQ.address)):eG,eY=(0,C.T)(er?void 0:eM,ec),e1=(0,r.useMemo)(()=>{var e,t,n;if(ej&&(!ec||!ej.includes(ec))||er&&!ex||!ex)return!1;let l=eM.toLowerCase().trim();return eU&&(""===l||(null==(n=eU.symbol)||null==(t=n.toLowerCase)||null==(e=t.call(n))?void 0:e.indexOf(l))!==-1)},[eM,eU,ec,ej,er,ex]),e2=(0,r.useMemo)(()=>{if(eV){let e=eM.toLowerCase().trim(),t=(0,A.V8)(q);return((null==er?void 0:er.length)?er.filter(e=>E.xx.isSPLToken(e)):eP).filter(n=>{var l;return(n.symbol.toLowerCase().includes(e)||(null==(l=n.name)?void 0:l.toLowerCase().includes(e))||n.address.toLowerCase()===e)&&!(t&&(0,A.V8)(n))})}let e=(0,w.gH)(eM,e=>!!(0,x.QR)(e));return Object.values(er||eZ).filter(e=>!ec||e.chainId===ec).filter(e)},[er,eZ,eM,eV,eP,q,ec]),e3=(0,v.CH)(e2,eM),{balances:e7}=(0,h.dy)(ec),e6=(0,r.useMemo)(()=>{if(eV)return[...e2].sort((e,t)=>{var n,l,r,i,s,o;let a=null!=(r=null==(n=e$.balances.get(e.address))?void 0:n.dividedBy(10**(e.decimals||1)))?r:N.AH,d=null!=(i=null==(l=e$.balances.get(t.address))?void 0:l.dividedBy(10**(t.decimals||1)))?i:N.AH,c=null!=(s=null==eq?void 0:eq[e.address])?s:0,u=null!=(o=null==eq?void 0:eq[t.address])?o:0,h=a.multipliedBy(c),x=d.multipliedBy(u);if(!h.eq(x))return x.comparedTo(h);let p=a.gt(0),m=d.gt(0);return p&&m&&!a.eq(d)?d.comparedTo(a):p!==m?m?1:-1:0});let e=(0,A.MF)(null!=e7?e7:{}),n=eM&&eM.trim().length>0,l=e=>er&&eg?e.sort((e,t)=>{var n,l,r,i,s,o;return(null!=(i=null==(n=eg[null!=(r=eb(e))?r:""])?void 0:n.rank)?i:0)-(null!=(o=null==(l=eg[null!=(s=eb(t))?s:""])?void 0:l.rank)?o:0)}):e;if(er&&!n){var r=l([...e2]);if(!(null==t?void 0:t.isToken)||t.chainId!==ec)return r;let e=t.wrapped.address.toLowerCase(),n=r.findIndex(t=>t.address.toLowerCase()===e);return n<=0?r:[r[n],...r.slice(0,n),...r.slice(n+1)]}if(n){let e=null!=e7?e7:{},t=new Set((0,H.OR)(ec).map(e=>e.address.toLowerCase()));return l([...e3].sort((n,l)=>{let r=e[n.address],i=e[l.address],s=0;if(r&&i?s=r.greaterThan(i)?-1:+!r.equalTo(i):r&&r.greaterThan("0")?s=-1:i&&i.greaterThan("0")&&(s=1),0!==s)return s;let o=t.has(n.address.toLowerCase()),a=t.has(l.address.toLowerCase());return o&&!a?-1:!o&&a?1:n.symbol&&l.symbol?n.symbol.toLowerCase()<l.symbol.toLowerCase()?-1:1:n.symbol||l.symbol?-1:0}))}return l([...e3].sort(e))},[e2,e3,e7,eV,e$.balances,eq,ec,eM,er,eg,null==t?void 0:t.chainId,null==t?void 0:t.isToken,null==t?void 0:t.wrapped.address]),e5=eh&&"swap-currency-output"===eu,{chains:e9,loading:e8}=(0,Z.kk)({originChainId:eN}),e4=(0,r.useMemo)(()=>{let e=null!=ec?ec:eN,t=Object.keys(U._e).map(Number).filter(t=>t!==e);return e5&&!e8&&(t=t.filter(e=>e9.includes(e))),t},[ec,eN,e5,e8,e9]),te=ef&&!er&&!!eM&&!eh,tt=(0,P.L)(te?eM:void 0,e4),tn=(0,r.useMemo)(()=>{if(!te||eV||e5&&!e8&&!e9.includes(g.Cb.SOLANA))return[];let e=eM.toLowerCase().trim();return e?eP.filter(t=>{var n;return t.symbol.toLowerCase().includes(e)||(null==(n=t.name)?void 0:n.toLowerCase().includes(e))||t.address.toLowerCase()===e}):[]},[te,eV,e5,e8,e9,eM,eP]),{balances:tl}=(0,O.Ay)(em?e_:void 0,{includeSpam:!1,enabled:!!em}),{balances:tr}=(0,O.Ay)(em&&null!=eB?eB:void 0,{includeSpam:!1,enabled:!!(em&&eB)}),ti=(0,r.useMemo)(()=>[...null!=tl?tl:[],...null!=tr?tr:[]],[tl,tr]),{balances:ts}=(0,O.Y9)(em?e_:void 0,em&&null!=eB?eB:void 0,{enabled:!!em}),{data:to}=(0,c.wm)({mint:"11111111111111111111111111111111",enabled:!!(em&&eB)}),ta=(0,r.useMemo)(()=>ts.filter(e=>e.chainId!==g.Cb.SOLANA).map(e=>e.chainId).sort().join(","),[ts]),{data:td}
1=(0,V.I)({queryKey:["evmNativePrices",ta],queryFn:async()=>{let e=ta.split(",").filter(Boolean).map(Number);return(0,F.JF)(e)},staleTime:3e5,refetchOnWindowFocus:!1,enabled:ta.length>0&&!!em}),tc=(0,r.useMemo)(()=>{let e=new Map;return ts.forEach(t=>{let n=parseFloat((0,f.J)(t.value,t.decimals)),l=0;if(t.chainId===g.Cb.SOLANA)l=null!=to?to:0;else{var r;l=null!=(r=null==td?void 0:td.get(t.chainId))?r:0}e.set(t.chainId,l>0?n*l:Number.EPSILON)}),e},[ts,to,td]),tu=(0,r.useMemo)(()=>{let e=new Map;return ti.forEach(t=>{var n,l,r;let i=null!=(l=(0,p.Sf)(t.chainId,t.token.address))?l:t.token.address.toLowerCase();e.set(`${t.chainId}-${i}`,null!=(r=null==(n=t.price)?void 0:n.totalUsd)?r:0)}),e},[ti]),th=(0,r.useMemo)(()=>new Set(ts.map(e=>{var t;return null==(t=e.currency.symbol)?void 0:t.toUpperCase()})),[ts]),tx=(0,r.useMemo)(()=>!em||!ti.length||er||eh?[]:ti.filter(e=>e.chainId!==(null!=ec?ec:eN)).filter(e=>e.token.address!==E.cF).filter(e=>e.chainId!==g.Cb.SOLANA||!!(0,p.aW)(e.token.address)).filter(e=>{var t;return!th.has(null==(t=e.token.symbol)?void 0:t.toUpperCase())}).filter(e=>{var t;if(e.chainId===g.Cb.SOLANA)return!0;let n=(0,x.QR)(e.token.address);return void 0!==n&&void 0!==(null!=(t=eH[e.chainId])?t:{})[n]}).filter(e=>!e5||e8||e9.includes(e.chainId)).filter(e=>{var t,n;if(!eM)return!0;let l=eM.toLowerCase();return!!((null==(t=e.token.symbol)?void 0:t.toLowerCase().includes(l))||(null==(n=e.token.name)?void 0:n.toLowerCase().includes(l))||e.token.address.toLowerCase()===l)}).map(e=>{if(e.chainId===g.Cb.SOLANA){var t;return new E.xx({chainId:e.chainId,address:e.token.address,decimals:e.token.decimals,symbol:e.token.symbol,name:e.token.name,logoURI:null!=(t=e.token.logoURI)?t:"",programId:"TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"})}return new A.ou(e.chainId,e.token.address,e.token.decimals,e.token.symbol,e.token.name)}),[em,ti,ec,eN,eM,e5,e8,e9,th,eH,er,eh]),tp=(0,r.useMemo)(()=>!em||!ts.length||er||eh?[]:ts.filter(e=>e.chainId!==(null!=ec?ec:eN)).filter(e=>!e5||e8||e9.includes(e.chainId)).filter(e=>{var t,n;if(!eM)return!0;let l=eM.toLowerCase();return(null==(t=e.currency.symbol)?void 0:t.toLowerCase().includes(l))||(null==(n=e.currency.name)?void 0:n.toLowerCase().includes(l))}).map(e=>e.currency),[em,ts,ec,eN,eM,e5,e8,e9,er,eh]),tm=(0,r.useMemo)(()=>{var e,t;if(!te||!tt.length&&!tn.length)return[];let n=new Set;for(let t of tx)if(t.isToken){let l=null!=(e=(0,p.Sf)(t.chainId,t.address))?e:t.address.toLowerCase();n.add(`${t.chainId}:${l}`)}for(let e of e6)if(e.isToken){let l=null!=(t=(0,p.Sf)(e.chainId,e.address))?t:e.address.toLowerCase();n.add(`${e.chainId}:${l}`)}let l=new Map;return[...tt,...tn].filter(e=>{var t,r;if(!e.isToken)return!1;let i=null!=(t=(0,p.Sf)(e.chainId,e.address))?t:e.address.toLowerCase();if(n.has(`${e.chainId}:${i}`))return!1;let s=null!=(r=l.get(e.chainId))?r:0;return!(s>=5)&&(l.set(e.chainId,s+1),!0)})},[te,tt,tn,tx,e6]),tf=(0,r.useMemo)(()=>{let e=em&&(tx.length>0||tp.length>0),t=tm.length>0;return e||t?[...e6,...tx,...tp,...tm].filter(e=>!(e.isToken&&e.address===E.cF)).sort((e,t)=>{var n,l,r,i,s,o;let a,d;if(e.isToken){let t=e.address,r=null!=(n=(0,p.Sf)(e.chainId,t))?n:t.toLowerCase();a=null!=(l=tu.get(`${e.chainId}-${r}`))?l:0}else a=null!=(r=tc.get(e.chainId))?r:0;if(t.isToken){let e=t.address,n=null!=(i=(0,p.Sf)(t.chainId,e))?i:e.toLowerCase();d=null!=(s=tu.get(`${t.chainId}-${n}`))?s:0}else d=null!=(o=tc.get(t.chainId))?o:0;return d-a}):e6},[e6,tx,tp,tm,tu,tc,em]),tg=function(e,t){let n=void 0!==e?(0,$.gK)(e):void 0,l=(0,B.V6)(),i=(0,r.useMemo)(()=>void 0!==e?(0,$.Qv)(e):[],[e]),{data:s}=(0,V.I)({queryKey:["popular-tokens",n,i],queryFn:async e=>{let{signal:t}=e,l=await Promise.all(i.map(e=>(0,$.Fk)(n,e,t))),r=new Map;return i.forEach((e,t)=>{l[t].forEach(e=>{var t;let n=parseFloat(null!=(t=e.volumeUSD24h)?t:"0"),l=e.id.toLowerCase(),i=r.get(l);(!i||n>i.volumeUSD)&&r.set(l,{id:e.id,symbol:e.symbol,name:e.name,decimals:e.decimals,volumeUSD:n})})}),Array.from(r.values()).sort((e,t)=>t.volumeUSD-e.volumeUSD)},enabled:!!(t&&n&&i.length>0),staleTime:3e5});return(0,r.useMemo)(()=>{var n;if(!t||!s||void 0===e)return[];let r=null!=(n=l[e])?n:{};return s.map(t=>{var n,l;if(t.id.toLowerCase()===E.cF.toLowerCase())return A.we.onChain(e);let i=(0,x.QR)(t.id);return i&&null!=(l=null==(n=r[i])?void 0:n.token)?l:null}
1).filter(Boolean).slice(0,50)},[s,e,t,l])}(ec,!e_&&!eB&&!eM&&!er),tv=(0,_.gO)(),tj=(0,r.useCallback)(e=>{n(e),eE&&(0,e0.$)().play()},[eE,n]),tA=(0,r.useRef)();(0,r.useEffect)(()=>{var e;eR||null==(e=tA.current)||e.focus()},[eR]);let tC=(0,r.useCallback)(e=>{var t;let n=e.target.value;eS((0,x.QR)(n)||n),null==(t=eT.current)||t.scrollTo(0)},[]),tw=(0,r.useCallback)(e=>{if("Enter"===e.key){let e=eM.toLowerCase().trim();if(!eV&&ex&&e===eU.symbol.toLowerCase().trim())tj(eU);else if(tf.length>0){var t;(eV||(null==(t=tf[0].symbol)?void 0:t.toLowerCase())===eM.trim().toLowerCase()||1===tf.length)&&tj(tf[0])}}},[eM,tf,tj,eU,eV,ex]),tb=!!(null==eY?void 0:eY.length),ty=(0,r.useCallback)(()=>er||!eQ||eJ||tb?(null==tf?void 0:tf.length)||tb||e1?(0,l.jsx)(k.Ay,{mx:"-24px",mt:"20px",height:"100%",children:(0,l.jsx)(eO,{height:eR?K&&(z!==G.AS.SWAP||tv.length>0)?en||250:en?en+80:350:340,showNative:e1,currencies:tf,inactiveCurrencies:eV?eY:eY.filter(e=>e&&"object"==typeof e&&"equals"in e&&"function"==typeof e.equals),breakIndex:(null==eY?void 0:eY.length)&&tf?tf.length:void 0,onCurrencySelect:tj,otherCurrency:q,selectedCurrency:t,fixedListRef:eT,showImportView:X,setImportToken:et,showChainLogo:em||ef||ei,chainId:ec,popularTokens:tg,currencyStatus
1Map:eg,showNativeAfterTokens:eC,nativeInsertIndex:ew})}):(0,l.jsx)(y.VP,{style:{padding:"20px",height:"100%"},children:(0,l.jsx)(I.A,{color:"textSubtle",textAlign:"center",mb:"20px",children:eI("No results found.")})}):(0,l.jsx)(y.VP,{style:{padding:"20px 0",height:"100%"},children:(0,l.jsx)(eA.A,{chainId:ec,onCurrencySelect:tj,token:eQ,showImportView:X,setImportToken:et})}),[eY,tf,tj,tb,q,eQ,eJ,t,et,e1,X,eI,K,z,tv.length,eR,en,ei,em,ef,ec,eV,er,tg,eg,eC,ew]);return(0,l.jsxs)(l.Fragment,{children:[ec?(0,l.jsx)(u.X,{chainId:ec}):null,es&&(0,l.jsxs)(L.wt,{my:"12px",display:"flex",flexDirection:"column",children:[(0,l.jsxs)(S.A,{justifyContent:"space-between",alignItems:"center",width:"100%",children:[(0,l.jsx)(I.A,{fontSize:"20px",mr:"16px",bold:!0,children:ea}),(0,l.jsx)(k.Ay,{mr:"-16px",children:(0,l.jsx)(L.s_,{onDismiss:eo,padding:"0"})})]}),(0,l.jsxs)(S.A,{width:"100%",alignItems:"center",children:[(0,l.jsx)(eF,{autoFocus:!1,inputRef:tA,handleEnter:tw,onInput:tC,compact:!0}),ep&&(0,l.jsx)(M.A,{onClick:ep,variant:"text",scale:"sm",ml:"8px",children:(0,l.jsx)(Y,{style:{padding:"6px"},children:(0,l.jsx)(T.A,{height:24,width:24,color:"textSubtle"})})})]})]}),(0,l.jsxs)(y.mm,{gap:"16px",children:[Q&&!es&&(0,l.jsx)(D.Ay,{children:(0,l.jsx)(eF,{inputRef:tA,handleEnter:tw,onInput:tC,placeholder:J})}),eh?(0,l.jsx)(eX,{chainId:ec,onSelect:e=>{ed(e),null==ey||ey(e)},isDependent:"swap-currency-output"===eu,allowedChainIds:ev,preserveChainOrder:ek}):null,K&&(z===G.AS.SWAP?(0,l.jsx)(el,{onSelect:tj,selectedCurrency:t,supportCrossChain:eh,allowedChainIds:e5?[eN,...e9]:void 0}):(0,l.jsx)(ee,{supportCrossChain:eh,chainId:ec,onSelect:tj,selectedCurrency:t,commonBasesType:z,disabledCurrencies:(0,A.V8)(null==q?void 0:q.wrapped)?[eU]:void 0,showNative:ex}))]}),ty()]})}},150103:(e,t,n)=>{n.d(t,{Zm:()=>l.Ay,gz:()=>s.A});var l=n(432594);n(350979),n(311560);var r=n(371309);n(247821),n(25963),n(856870);var i=n(680797);n(733775),n(389624),(0,i.I4)(r.A).withConfig({componentId:"sc-576e4e17-0"})(["width:",";height:",";border-radius:",";"],e=>{let{size:t}=e;return t},e=>{let{size:t}=e;return t},e=>{let{size:t}=e;return t}),i.I4.div.withConfig({componentId:"sc-576e4e17-1"})(["position:relative;display:flex;flex-direction:row;align-items:center;width:32px;img:last-child{margin-left:-4px;}&.farm{width:48px;margin-right:-24px;img:first-child{margin-bottom:14px;}img:last-child{margin-left:-14px;margin-top:14px;}svg:last-child{margin-left:-14px;margin-top:14px;}}"]);var s=n(831016)},158956:(e,t,n)=>{n.d(t,{O:()=>l.O});var l=n(300130)},166351:(e,t,n)=>{n.d(t,{A:()=>i});var l=n(350979);n(25963);var r=n(257057);let i=e=>(0,l.jsx)(r.A,{viewBox:"0 0 18 18",...e,children:(0,l.jsx)("path",{d:"M4.10386 15.4522C3.67286 15.4522 3.30573 15.3006 3.00248 14.9974C2.69923 14.6941 2.54761 14.327 2.54761 13.896V4.10361C2.54761 3.67261 2.69923 3.30549 3.00248 3.00224C3.30573 2.69899 3.67286 2.54736 4.10386 2.54736H13.8962C14.3272 2.54736 14.6944 2.69899 14.9976 3.00224C15.3009 3.30549 15.4525 3.67261 15.4525 4.10361H9.45905C8.72692 4.10361 8.10136 4.36311 7.58236 4.88211C7.06336 5.40111 6.80386 6.02668 6.80386 6.7588V11.2498C6.80386 11.9819 7.06336 12.606 7.58236 13.122C8.10136 13.638 8.72692 13.896 9.45905 13.896H15.4525C15.4525 14.3307 15.3009 14.6988 14.9976 15.0002C14.6944 15.3016 14.3272 15.4522 13.8962 15.4522H4.10386ZM9.45905 12.5998C9.0908 12.5998 8.77223 12.4669 8.50336 12.201C8.23448 11.9351 8.10005 11.6181 8.10005 11.2498V6.7588C8.10005 6.39055 8.23448 6.07199 8.50336 5.80311C8.77223 5.53424 9.0908 5.3998 9.45905 5.3998H14.9935C15.3617 5.3998 15.6803 5.53424 15.9492 5.80311C16.218 6.07199 16.3525 6.39055 16.3525 6.7588V11.2498C16.3525 11.6181 16.218 11.9351 15.9492 12.201C15.6803 12.4669 15.3617 12.5998 14.9935 12.5998H9.45905ZM12.15 10.1248C12.4625 10.1248 12.7282 10.0154 12.9469 9.79668C13.1657 9.57793 13.275 9.3123 13.275 8.9998C13.275 8.6873 13.1657 8.42168 12.9469 8.20293C12.7282 7.98418 12.4625 7.8748 12.15 7.8748C11.8375 7.8748 11.5719 7.98418 11.3532 8.20293C11.1344 8.42168 11.025 8.6873 11.025 8.9998C11.025 9.3123 11.1344 9.57793 11.3532 9.79668C11.5719 10.0154 11.8375 10.1248 12.15 10.1248Z",fill:"currentColor"})})},168927:(e,t,n)=>{n.d(t,{A:()=>l});let l=n(805017).m}
1,187012:(e,t,n)=>{n.d(t,{Ay:()=>V,K_:()=>T,Wd:()=>N,zi:()=>R});var l=n(350979),r=n(421770),i=n(769932),s=n(557423),o=n(59678),a=n(579518),d=n(28192),c=n(265449),u=n(501823),h=n(979332),x=n(605641),p=n(865109),m=n(654168),f=n(353540),g=n(530957),v=n(662928),j=n(443171),A=n(768159),C=n(276686),w=n(118708),b=n(25963),y=n(726053),k=n(735872),I=n(479060),L=n(680797),S=n(733775);let M=(0,L.I4)(s.A).withConfig({componentId:"sc-97aac82c-0"})(["animation:",";background-size:1000% 1000%;"],()=>(0,L.AH)([""," 1.5s ease infinite"],o.fd)),T={UNKNOWN:-1,VERY_LOW:0,SOME_RISK:1,LOW:2,MEDIUM:3,HIGH:4,SIGNIFICANT:5},R={[T.VERY_LOW]:(0,l.jsx)(r.x,{children:"Very Low Risk"}),[T.SOME_RISK]:(0,l.jsx)(r.x,{children:"Some Risk"}),[T.LOW]:(0,l.jsx)(r.x,{children:"Low Risk"}),[T.MEDIUM]:(0,l.jsx)(r.x,{children:"Medium Risk"}),[T.HIGH]:(0,l.jsx)(r.x,{children:"High Risk"}),[T.SIGNIFICANT]:(0,l.jsx)(r.x,{children:"Significant Risk"}),[T.UNKNOWN]:(0,l.jsx)(r.x,{children:"Unknown Risk"})};function E(e){let{onClick:t}=e,[n,r]=(0,b.useState)(!1),{t:s}=(0,i.A)(),[o,u]=(0,b.useState)(!1),h=(0,a.A)((0,l.jsxs)(l.Fragment,{children:[s("Risk scanning failed.")," ",!n&&s("Press the button to retry.")]}),{placement:"auto",manualVisible:!0,trigger:"hover"});return(0,l.jsxs)("div",{ref:h.targetRef,children:[(0,l.jsx)(d.A,{ml:"4px",onClick:()=>{r(!0),u(!0),setTimeout(()=>{u(!1)},1e3),t()},"data-dd-action-name":"Risk scan retry button",disabled:n,variant:"text",size:"sm",style:{width:"20px"},height:"20px",children:(0,l.jsx)(c.A,{color:"primary",width:"16px",height:"16px"})}),o&&h.tooltip]})}function N(e){let t=(0,w.md)(y.yp),n=(0,y.OL)(t,e),l=(0,v.I)({queryKey:["third-party-risk",null==e?void 0:e.chainId,null==e?void 0:e.address],queryFn:()=>e&&(0,C.Z)(e.address,e.chainId),enabled:!!(e&&!n&&e.address&&A.s.includes(e.chainId)),refetchOnWindowFocus:!1,refetchOnReconnect:!1,refetchOnMount:!1});return n?{...l,data:void 0,isLoading:!1,isFetching:!1,isPending:!1}:l}let O=e=>{let{token:t}=e,{t:n}=(0,i.A)(),{data:r,refetch:s}=N(t);(0,b.useEffect)(()=>{if(null==r?void 0:r.pollingInterval){let e=setTimeout(()=>s(),null==r?void 0:r.pollingInterval);return()=>clearTimeout(e)}},[null==r?void 0:r.pollingInterval,s]);let o=(0,k.mC)(),d=(0,b.useMemo)(()=>{if(!(null==t?void 0:t.address))return!1;let e=Object.values(o).map(e=>{var t;return null==e||null==(t=e.current)?void 0:t.tokens}).filter(Boolean);return e.length?e.some(e=>null==e?void 0:e.some(e=>(0,S.ho)(e.address,t.address))):null},[o,null==t?void 0:t.address]),{targetRef:c,tooltip:v,tooltipVisible:A}=(0,a.A)((0,l.jsx)(j.A,{riskLevel:null==r?void 0:r.riskLevel,hasResult:null==r?void 0:r.hasResult,tokenAddress:null==r?void 0:r.address,tokenChain:null==r?void 0:r.chainId,riskLevelDescription:null==r?void 0:r.riskLevelDescription}),{placement:"bottom"}),C=(0,b.useMemo)(()=>!r||(null==r?void 0:r.riskLevel)===T.UNKNOWN&&!(null==r?void 0:r.hasResult),[r]),w=(0,b.useMemo)(()=>{if(!(0,g.A)(null==r?void 0:r.riskLevel))return d||(null==r?void 0:r.riskLevel)?null==r?void 0:r.riskLevel:T.UNKNOWN},[r,d]),y=(0,b.useMemo)(()=>(null==r?void 0:r.riskLevel)?r.riskLevel>T.MEDIUM?"failure":r.riskLevel>=T.LOW&&r.riskLevel<=T.MEDIUM?"warning":r.riskLevel>=T.VERY_LOW&&r.riskLevel<=T.SOME_RISK?"primary":"textDisabled":"textDisabled",[null==r?void 0:r.riskLevel]);if(!C){let e=w&&R[w];return e?(0,l.jsx)(u.A,{justifyContent:"flex-end",children:(0,l.jsx)("div",{ref:c,style:{userSelect:"none"},children:(0,l.jsxs)(h.A,{variant:y,children:[(0,l.jsx)(x.A,{bold:!0,small:!0,color:"invertedContrast",children:e}),A&&v,(0,l.jsx)(u.A,{children:(null==r?void 0:r.hasResult)?(0,l.jsx)(p.A,{ml:"4px",width:"16px",height:"16px",color:"invertedContrast"}):(0,l.jsx)(m.A,{spin:!0,ml:"4px",width:"20px",height:"20px",color:"invertedContrast"})})]})})}):null}return(null==r?void 0:r.isError)?(0,l.jsxs)(u.A,{justifyContent:"flex-end",alignItems:"center",children:[(0,l.jsx)("div",{ref:c,style:{userSelect:"none"},children:(0,l.jsxs)(h.A,{variant:"textDisabled",children:[(0,l.jsx)(x.A,{bold:!0,small:!0,color:"invertedContrast",children:n("Unknown")}),A&&v,(0,l.jsx)(u.A,{children:(0,l.jsx)(p.A,{ml:"4px",width:"16px",height:"16px",color:"invertedContrast"})})]})}),(0,l.jsx)(E,{onClick:()=>s()},t.chainId+t.address)]}):(0,l.jsx)(l.Fragment,{children:(0,l.jsxs)(u.A,{justifyContent:"flex-end",minWidth:168,children:[(0,l.jsx)(M,{variant:"bubblegum",scale:"sm",style:{height:"28px"},children:(0,l.jsx)(f.n,{style:{fontSize:"14px"},children:n("Scanning Risk")})}),A&&v,(0,l.jsx)(u.A,{ref:c,children:(null==r?void 0:r.riskLevel)===T.UNKNOWN?(0,l.jsx)(m.A,{spin:!0,ml:"4px",width:"20px",height:"20px",color:"textSubtle"}):(0,l.jsx)(p.A,{ml:"4px",width:"20px",height:"20px",color:"textSubtle"})})]})})},V=e=>{let{token:t}=e,[n]=(0,I.n)(),r=(0,w.md)(y.yp),i=(0,y.OL)(r,t);return n&&!i&&(0,l.jsx)(O,{token:t})}},276686:(e,t,n)=>{n.d(t,{Z:()=>s});var l=n(833438);let r=(e,t)=>({address:e,chainId:t,isError:!0,hasResult:!1,riskLevel:-1,requestId:"",riskLevelDescription:"",pollingInterval:0}),i=async(e,t)=>{var n,i,s,o;let a=await fetch(`${l.a4}`,{headers:{Accept:"application/json","Content-Type":"application/json"},method:"POST",body:JSON.stringify({chain_id:t,address:e})}),d=await a.json().catch(()=>void 0),c=null==d?void 0:d.data;return a.ok&&c&&!c.isError?{address:e,chainId:t,isError:!1,hasResult:!!c.hasResult,riskLevel:null!=(n=c.riskLevel)?n:-1,requestId:null!=(i=c.requestId)?i:"",riskLevelDescription:null!=(s=c.riskLevelDescription)?s:"",pollingInterval:null!=(o=c.pollingInterval)?o:0}:r(e,t)},s=async(e,t)=>{let n=await i(e,t).catch(()=>void 0);return!n||(null==n?void 0:n.isError)?r(e,t):n}},279355:(e,t,n)=>{n.d(t,{A:()=>h});var l=n(350979),r=n(131619),i=n(735872),s=n(435222),o=n(442828),a=n(965691),d=n(150103);let c=(0,a.X)(d.Zm),u=e=>{let{token:t,style:n,dim:r,list:i,onCurrencySelect:a,isActive:d,isAdded:u,setImportToken:h,showImportView:x}=e;return(0,l.jsx)(c,{style:n,token:t,symbolAlias:(0,o.En)(null==t?void 0:t.address,null==t?void 0:t.chainId,null==t?void 0:t.symbol),dim:r,list:i,onCurrencySelect:a,isActive:d,children:(0,l.jsx)(s.m,{token:t,isActive:d,isAdded:u,setImportToken:h,showImportView:x})})};function h(e){var t,n;let{token:s,style:o,dim:a,onCurrencySelect:d,showImportView:c,setImportToken:h,chainId:x}=e,p=(0,i.qR)(),m=(null==s?void 0:s.chainId)&&(null==p||null==(n=p[s.chainId])||null==(t=n[s.address])?void 0:t.list),f=(0,r.A1)(s,x),g=(0,r.FR)(s,x);return(0,l.jsx)(u,{style:o,token:s,dim:a,onCurrencySelect:d,showImportView:c,setImportToken:h,list:m,isActive:g,isAdded:f})}},353540:(e,t,n)=>{n.d(t,{n:()=>l});let l=n(680797).I4.span.withConfig({componentId:"sc-ef186fae-0"})(['&::after{display:inline-block;animation:ellipsis 1.25s infinite;content:".";width:1em;text-align:left;}@keyframes ellipsis{0%{content:".";}33%{content:"..";}66%{content:"...";}}'])},378385:(e,t,n)=>{n.d(t,{x4:()=>x,Eg:()=>p,wO:()=>m,ZV:()=>h,zR:()=>d,_c:()=>c,MS:()=>a,cB:()=>u});var l=n(91168),r=n(659918),i=n(63544);function s(e,t){if(!e)return e;if(!t)return e.replace(/\s+$/,"");let n=RegExp(`[${t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}]+$`);return e.replace(n,"")}var o=n(442841);let a=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:18;return e.times((0,i.E)(t))},d=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:18;return e.dividedBy((0,i.E)(t))},c=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:18;return d(e||r.AH,t).toNumber()},u=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:18,n=arguments.length>2?arguments[2]:void 0,l=d(e,t).toFixed(n);return n?s(s(l,"0"),"."):l},h=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:2;
1return e.toLocaleString(void 0,{minimumFractionDigits:t,maximumFractionDigits:n})},x=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:18,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:18,l=e%10n**BigInt(n-t);return(0,o.J)(e-l,n)},p=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:18,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:18;return(+(0,o.J)(e,n)).toFixed(t)},m=(e,t)=>{let n=d(e,t);return n.lt(1e-5)&&n.gt(0)?"< 0.00001":n.toFixed(5,l.A.ROUND_DOWN)}},427554:(e,t,n)=>{n.d(t,{V:()=>x,c:()=>p});var l=n(311560),r=n(25963),i=n(662928),s=n(206284),o=n(228876),a=n(532537),d=n(529208),c=n(968349),u=n(569019),h=n(638380);function x(e){let{account:t,solanaAccount:n}=(0,c.W7)(),x=(0,h.W)(),p=!!(e&&"programId"in e),m=!!((null==e?void 0:e.isNative)&&(null==e?void 0:e.chainId)===o.Cb.SOLANA),f=(0,a.pd)(n,p?e.address:void 0),{data:g}=(0,i.I)({queryKey:[d.qZ,n,o.Cb.SOLANA],queryFn:async()=>BigInt(await x.getBalance(new s.PublicKey(n))),enabled:!!(m&&n),staleTime:3e5,refetchOnWindowFocus:!1}),v=(0,u.rL)(t,e);return(0,r.useMemo)(()=>p&&f?l.C3.fromRawAmount(e,f.balance.toString()):m&&void 0!==g?l.C3.fromRawAmount(e,g.toString()):v||void 0,[e,p,f,m,g,v])}function p(e){let{account:t,solanaAccount:n}=(0,c.W7)(),i=(0,r.useMemo)(()=>null==e?void 0:e.filter(e=>e&&l.xx.isSPLToken(e)),[e]),s=(0,r.useMemo)(()=>null==e?void 0:e.filter(e=>e&&!l.xx.isSPLToken(e)),[e]),o=(0,r.useMemo)(()=>(null==i?void 0:i.map(e=>e.address))||[],[i]),d=(0,a.y)(n,(null==i?void 0:i.length)>0?o:void 0),h=(0,u.ed)(t,(null==s?void 0:s.length)>0?s:void 0);return(0,r.useMemo)(()=>e?e.map(e=>{if(!e)return;if(l.xx.isSPLToken(e)){let t=null==d?void 0:d.balances.get((null==e?void 0:e.address)||"");return t?l.C3.fromRawAmount(e,t.toString()):void 0}let t=null==s?void 0:s.findIndex(t=>t===e);return void 0!==t&&t>=0?null==h?void 0:h[t]:void 0}):[],[e,d,h,s])}},443171:(e,t,n)=>{n.d(t,{A:()=>u});var l=n(350979),r=n(228876),i=n(769932),s=n(421770),o=n(605641),a=n(673115),d=n(501823),c=n(187012);let u=e=>{let{riskLevel:t,hasResult:n,riskLevelDescription:u,tokenAddress:h,tokenChain:x}=e,{t:p}=(0,i.A)();return t!==c.K_.UNKNOWN&&n?n&&t&&t>=c.K_.VERY_LOW&&h?(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(o.A,{my:"8px",children:u}),(0,l.jsx)(s.x,{i18nKey:"Risk scan results are provided by a third party, <0>HashDit</0>",components:[(0,l.jsx)(a.A,{style:{display:"inline"},ml:"4px",external:!0,href:"https://www.hashdit.io"})]}),x===r.nU.BSC&&(0,l.jsx)(d.A,{mt:"4px",alignItems:"center",children:(0,l.jsx)(s.x,{i18nKey:"Get more details from <0>RedAlarm</0>",components:[(0,l.jsx)(a.A,{ml:"4px",external:!0,href:`https://dappbay.bnbchain.org/risk-scanner/${h}`})]})})]}):(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(o.A,{my:"8px",children:p("Automatic risk scanning for the selected token. This scanning result is for reference only, and should NOT be taken as investment advice.")}),(0,l.jsx)(s.x,{i18nKey:"Provided by <0>HashDit</0>",components:[(0,l.jsx)(a.A,{style:{display:"inline"},ml:"4px",external:!0,href:"https://www.hashdit.io"})]}),(0,l.jsx)(a.A,{mt:"4px",external:!0,href:"https://hashdit.github.io/hashdit/docs/risk-level-description",children:p("Learn More")})]}):(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(o.A,{my:"8px",children:p("Risk scanning is still in progress. It may take up to 5 minutes to fully scan a token which is new to the database.")}),(0,l.jsx)(s.x,{i18nKey:"Provided by <0>HashDit</0>",components:[(0,l.jsx)(a.A,{style:{display:"inline"},ml:"4px",external:!0,href:"https://www.hashdit.io"})]}),(0,l.jsx)(d.A,{mt:"4px",alignItems:"center",children:(0,l.jsx)(s.x,{i18nKey:"Learn more about risk rating <0>here.</0>",components:[(0,l.jsx)(a.A,{ml:"4px",external:!0,href:"https://hashdit.github.io/hashdit/docs/risk-level-description"})]})})]})}},452301:(e,t,n)=>{n.d(t,{U$:()=>r.U$,dc:()=>i});var l=n(311560),r=n(670420);function i(e,t){return t&&(null==e?void 0:e.isNative)?l.xQ[t]:(null==e?void 0:e.isToken)?e:void 0}},482335:(e,t,n)=>{n.d(t,{Dv:()=>o,Qr:()=>a,SH:()=>s,ZO:()=>d});var l=n(680797),r=n(428089),i=n(501823);let s=(0,l.I4)(r.Ay).withConfig({componentId:"sc-64628efd-0"})(["background-color:",";border-radius:",";box-shadow:",";"],e=>{let{theme:t}=e;return t.colors.backgroundAlt},e=>{let{theme:t}=e;return t.radii.card},e=>{let{theme:t}=e;return t.shadows.tooltip}),o=(0,l.I4)(i.A).withConfig({componentId:"sc-64628efd-1"})(["flex-direction:column;overflow:hidden;min-width:136px;background:",";border-radius:",";border:",";"],e=>{let{theme:t}=e;return t.colors.input},e=>{let{theme:t}=e;return t.radii.default},e=>{let{theme:t}=e;return`1px solid ${t.colors.inputSecondary}`}),a=l.I4.div.withConfig({componentId:"sc-64628efd-2"})(["cursor:pointer;display:inline-flex;"]),d=l.I4.button.withConfig({componentId:"sc-64628efd-3"})(["border:0;outline:0;cursor:pointer;background:transparent;padding:8px 16px;color:",";width:100%;font-size:16px;text-align:left;&:hover{background-color:",";text-decoration:none;}"],e=>{let{theme:t}=e;return t.colors.text},e=>{let{theme:t}=e;return t.colors.inputSecondary})}
1,490233:(e,t,n)=>{n.d(t,{i:()=>c});var l=n(350979),r=n(769932),i=n(25963),s=n(579518),o=n(28192),a=n(681711),d=n(567958);let c=e=>{let{text:t,tooltipMessage:n,defaultTooltipMessage:c,width:u,buttonColor:h="primary",tooltipPlacement:x="auto",icon:p=a.A,...m}=e,{t:f}=(0,r.A)(),[g,v]=(0,i.useState)(!1),{targetRef:j,tooltip:A,tooltipVisible:C}=(0,s.A)(g?n:c,{placement:x,manualVisible:!c,trigger:"hover"}),w=c?C:g,b=(0,i.useCallback)(()=>{v(!0)},[]),y=(0,i.useCallback)(e=>{e.stopPropagation(),(0,d.D)(t,b)},[t,b]);return(0,i.useEffect)(()=>{if(g){let e=setTimeout(()=>{v(!1)},1e3);return()=>clearTimeout(e)}},[g]),(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)("div",{ref:j,children:(0,l.jsxs)(o.A,{title:f("Copy"),onClick:y,scale:"sm",variant:"text",style:{width:"auto",position:"relative",height:"fit-content"},children:[m.children,(0,l.jsx)(p,{color:h,width:u,...m})]})}),w&&A]})}},508195:(e,t,n)=>{n.d(t,{A:()=>i});var l=n(350979);n(25963);var r=n(257057);let i=e=>(0,l.jsxs)(r.A,{viewBox:"0 0 40 40",...e,children:[(0,l.jsx)("path",{d:"M36.0112 3.33337L22.1207 13.6277L24.7012 7.56091L36.0112 3.33337Z",fill:"#E17726"}),(0,l.jsx)("path",{d:"M4.00261 3.33337L17.7558 13.7238L15.2989 7.56091L4.00261 3.33337Z",fill:"#E27625"}),(0,l.jsx)("path",{d:"M31.0149 27.2023L27.3227 32.8573L35.2287 35.0397L37.4797 27.3258L31.0149 27.2023Z",fill:"#E27625"}),(0,l.jsx)("path",{d:"M2.53386 27.3258L4.77116 35.0397L12.6772 32.8573L8.9987 27.2023L2.53386 27.3258Z",fill:"#E27625"}),(0,l.jsx)("path",{d:"M12.2518 17.6496L10.0419 20.9712L17.8793 21.3281L17.6048 12.8867L12.2518 17.6496Z",fill:"#E27625"}),(0,l.jsx)("path",{d:"M27.762 17.6494L22.3129 12.7905L22.1207 21.3279L29.9581 20.9711L27.762 17.6494Z",fill:"#E27625"}),(0,l.jsx)("path",{d:"M12.6772 32.8574L17.3989 30.5652L13.336 27.3809L12.6772 32.8574Z",fill:"#E27625"}),(0,l.jsx)("path",{d:"M22.6009 30.5652L27.3226 32.8574L26.6637 27.3809L22.6009 30.5652Z",fill:"#E27625"}),(0,l.jsx)("path",{d:"M27.3226 32.8575L22.6009 30.5653L22.9715 33.6399L22.9303 34.9301L27.3226 32.8575Z",fill:"#D5BFB2"}),(0,l.jsx)("path",{d:"M12.6772 32.8575L17.0694 34.9301L17.042 33.6399L17.3989 30.5653L12.6772 32.8575Z",fill:"#D5BFB2"}),(0,l.jsx)("path",{d:"M17.1518 25.3495L13.2262 24.1965L15.9988 22.92L17.1518 25.3495Z",fill:"#233447"}),(0,l.jsx)("path",{d:"M22.848 25.3495L24.001 22.92L26.801 24.1965L22.848 25.3495Z",fill:"#233447"}),(0,l.jsx)("path",{d:"M12.6773 32.8573L13.3635 27.2023L8.99876 27.3258L12.6773 32.8573Z",fill:"#CC6228"}),(0,l.jsx)("path",{d:"M26.6364 27.2023L27.3227 32.8573L31.0149 27.3258L26.6364 27.2023Z",fill:"#CC6228"}),(0,l.jsx)("path",{d:"M29.9581 20.9709L22.1207 21.3278L22.8482 25.3495L24.0011 22.92L26.8012 24.1965L29.9581 20.9709Z",fill:"#CC6228"}),(0,l.jsx)("path",{d:"M13.2263 24.1965L15.9989 22.92L17.1519 25.3495L17.8793 21.3278L10.0419 20.9709L13.2263 24.1965Z",fill:"#CC6228"}),(0,l.jsx)("path",{d:"M10.0419 20.9709L13.3361 27.3809L13.2263 24.1965L10.0419 20.9709Z",fill:"#E27525"}),(0,l.jsx)("path",{d:"M26.8011 24.1965L26.6638 27.3809L29.958 20.9709L26.8011 24.1965Z",fill:"#E27525"}),(0,l.jsx)("path",{d:"M17.8793 21.3278L17.1519 25.3494L18.0715 30.0985L18.2637 23.8396L17.8793 21.3278Z",fill:"#E27525"}),(0,l.jsx)("path",{d:"M22.1205 21.3278L21.7499 23.8258L21.9283 30.0985L22.848 25.3494L22.1205 21.3278Z",fill:"#E27525"}),(0,l.jsx)("path",{d:"M22.848 25.3496L21.9284 30.0987L22.601 30.5654L26.6638 27.381L26.8011 24.1967L22.848 25.3496Z",fill:"#F5841F"}),(0,l.jsx)("path",{d:"M13.2262 24.1967L13.336 27.381L17.3989 30.5654L18.0714 30.0987L17.1518 25.3496L13.2262 24.1967Z",fill:"#F5841F"}),(0,l.jsx)("path",{d:"M22.9303 34.93L22.9715 33.6398L22.6284 33.3378H17.3714L17.042 33.6398L17.0694 34.93L12.6772 32.8574L14.2145 34.1202L17.3302 36.2751H22.6696L25.7853 34.1202L27.3226 32.8574L22.9303 34.93Z",fill:"#C0AC9D"}),(0,l.jsx)("path",{d:"M22.601 30.5653L21.9284 30.0986H18.0715L17.3989 30.5653L17.0421 33.6399L17.3715 33.3379H22.6285L22.9716 33.6399L22.601 30.5653Z",fill:"#161616"}),(0,l.jsx)("path",{d:"M36.5875 14.3003L37.7542 8.61779L36.011 3.33337L22.6009 13.2846L27.7618 17.6493L35.0365 19.7768L36.6424 17.8964L35.9424 17.3886L37.0679 16.3728L36.2169 15.7003L37.3287 14.863L36.5875 14.3003Z",fill:"#763E1A"}),(0,l.jsx)("path",{d:"M2.24573 8.61779L3.42615 14.3003L2.67123 14.863L3.78302 15.7003L2.93202 16.3728L4.05753 17.3886L3.35752 17.8964L4.96343 19.7768L12.2518 17.6493L17.399 13.2846L4.00263 3.33337L2.24573 8.61779Z",fill:"#763E1A"}),(0,l.jsx)("path",{d:"M35.0365 19.777L27.7619 17.6495L29.958 20.9712L26.6638 27.3811L31.0149 27.3262H37.4797L35.0365 19.777Z",fill:"#F5841F"}),(0,l.jsx)("path",{d:"M12.2517 17.6495L4.96332 19.777L2.53386 27.3262H8.99869L13.336 27.3811L10.0419 20.9712L12.2517 17.6495Z",fill:"#F5841F"}),(0,l.jsx)("path",{d:"M22.1205 21.3276L22.6009 13.2843L24.701 7.56067H15.2988L17.3988 13.2843L17.8792 21.3276L18.0577 23.8531L18.0714 30.0984H21.9283L21.9421 23.8531L22.1205 21.3276Z",fill:"#F5841F"})]})}
1,512729:(e,t,n)=>{n.d(t,{A:()=>i});var l=n(350979);n(25963);var r=n(257057);let i=e=>(0,l.jsxs)(r.A,{viewBox:"0 0 40 40",...e,children:[(0,l.jsx)("rect",{width:"40",height:"40",rx:"8",fill:"#9BED2D"}),(0,l.jsx)("path",{d:"M23.7588 15.666H16.2477C15.9286 15.666 15.6699 15.9246 15.6699 16.2437V23.7549C15.6699 24.0739 15.9286 24.3327 16.2477 24.3327H23.7588C24.0779 24.3327 24.3366 24.0739 24.3366 23.7549V16.2437C24.3366 15.9246 24.0779 15.666 23.7588 15.666Z",fill:"black"}),(0,l.jsx)("path",{d:"M15.0889 6.99902H7.57782C7.25873 6.99902 7 7.25764 7 7.57684V15.0879C7 15.4069 7.25873 15.6657 7.57782 15.6657H15.0889C15.4081 15.6657 15.6667 15.4069 15.6667 15.0879V7.57684C15.6667 7.25764 15.4081 6.99902 15.0889 6.99902Z",fill:"black"}),(0,l.jsx)("path",{d:"M32.423 6.99902H24.9118C24.5927 6.99902 24.334 7.25764 24.334 7.57684V15.0879C24.334 15.4069 24.5927 15.6657 24.9118 15.6657H32.423C32.7421 15.6657 33.0007 15.4069 33.0007 15.0879V7.57684C33.0007 7.25764 32.7421 6.99902 32.423 6.99902Z",fill:"black"}),(0,l.jsx)("path",{d:"M15.0889 24.332H7.57782C7.25873 24.332 7 24.5906 7 24.9097V32.4209C7 32.74 7.25873 32.9987 7.57782 32.9987H15.0889C15.4081 32.9987 15.6667 32.74 15.6667 32.4209V24.9097C15.6667 24.5906 15.4081 24.332 15.0889 24.332Z",fill:"black"}),(0,l.jsx)("path",{d:"M32.423 24.332H24.9118C24.5927 24.332 24.334 24.5906 24.334 24.9097V32.4209C24.334 32.74 24.5927 32.9987 24.9118 32.9987H32.423C32.7421 32.9987 33.0007 32.74 33.0007 32.4209V24.9097C33.0007 24.5906 32.7421 24.332 32.423 24.332Z",fill:"black"})]})},532537:(e,t,n)=>{n.d(t,{JO:()=>u,pd:()=>d,y:()=>c});var l=n(25963),r=n(91168),i=n(118708),s=n(27313),o=n(659918),a=n(429484);function d(e,t){let{data:n,isLoading:s,error:d}=(0,i.md)((0,a.Ww)(e));return(0,l.useMemo)(()=>{var e,l;if(!t)return{balance:o.AH,loading:!1};if(d)return{balance:o.AH,loading:!1,error:d};if(s||!n)return{balance:o.AH,loading:!0};let i=null==(l=n.get(t))||null==(e=l[0])?void 0:e.amount.toString();return{balance:i?new r.A(i):o.AH,loading:!1}},[t,n,s,d])}function c(e,t){let n=(0,l.useMemo)(()=>(0,a.Ww)(null!=e?e:null),[e]),{data:s,isLoading:o,error:d}=(0,i.md)(n);return(0,l.useMemo)(()=>{if(d)return{balances:new Map,loading:!1,error:d};if(o||!s)return{balances:new Map,loading:!0};let e=new Map;return t&&t.length>0?t.forEach(t=>{var n,l;e.set(t,new r.A(null!=(l=null==(n=s.get(t))?void 0:n[0].amount.toString())?l:0))}):s.forEach((t,n)=>{var l,i;e.set(n,new r.A(null!=(i=null==(l=s.get(n))?void 0:l[0].amount.toString())?i:0))}),{balances:e,loading:!1}},[t,s,o,d])}function u(e){let t=(0,s.jE)();return(0,l.useCallback)(()=>{t.invalidateQueries({queryKey:[a._c,e],exact:!1})},[t,e])}},617636:(e,t,n)=>{n.d(t,{A:()=>o});var l=n(350979),r=n(25963),i=n(990296),s=n(605641);let o=e=>{var t,n;let{loading:o,initialWidth:a,initialHeight:d=16,children:c,...u}=e,h=(0,r.useRef)(null);return(0,l.jsx)(l.Fragment,{children:o?(0,l.jsx)(i.Ay,{isDark:!0,width:(null==(t=h.current)?void 0:t.clientWidth)||a,height:(null==(n=h.current)?void 0:n.clientHeight)||d}):(0,l.jsx)(s.A,{ref:h,...u,children:c})})}},671261:(e,t,n)=>{n.d(t,{A:()=>i});var l=n(350979);n(25963);var r=n(257057);let i=e=>(0,l.jsx)(r.A,{viewBox:"0 0 24 24",...e,children:(0,l.jsx)("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V9c0-1.1-.9-2-2-2H8c-1.1 0-2 .9-2 2v10zM9 9h6c.55 0 1 .45 1 1v8c0 .55-.45 1-1 1H9c-.55 0-1-.45-1-1v-8c0-.55.45-1 1-1zm6.5-5l-.71-.71c-.18-.18-.44-.29-.7-.29H9.91c-.26 0-.52.11-.7.29L8.5 4H6c-.55 0-1 .45-1 1s.45 1 1 1h12c.55 0 1-.45 1-1s-.45-1-1-1h-2.5z"})})},686815:(e,t,n)=>{n.d(t,{A:()=>i});var l=n(350979);n(25963);var r=n(257057);let i=e=>(0,l.jsx)(r.A,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0, 0, 400,400",...e,children:(0,l.jsxs)("g",{stroke:"none",fillRule:"evenodd",children:[(0,l.jsx)("path",{d:"M193.4 60.265C87.303 66.651 25.782 181.12 79.826 271.586c57.163 95.688 198.154 89.201 246.382-11.336C371.654 165.512 297.595 53.993 193.4 60.265m47.221 95.946c1.213.75 2.418 1.955 3.168 3.168l1.211 1.958v77.326l-1.211 1.958c-.75 1.213-1.955 2.418-3.168 3.168L238.663 245h-77.326l-1.958-1.211c-1.213-.75-2.418-1.955-3.168-3.168L155 238.663l-.119-37.831c-.08-25.344.018-38.306.297-39.267.685-2.365 2.559-4.562 4.876-5.717l2.127-1.06 38.241.106 38.241.106 1.958 1.211",fill:"#fbfbfc"}),(0,l.jsx)("path",{d:"M183.6.43C41.847 12.741-42.613 163.705 21.396 290.354c49.819 98.572 170.31 138.107 268.958 88.25 98.572-49.819 138.107-170.31 88.25-268.958C348.052 49.197 290.688 9.389 222 .97c-6.325-.775-31.6-1.13-38.4-.54M218 60.975c81.04 11.263 135.239 87.02 119.351 166.825-15.844 79.589-97.673 129.334-175.893 106.929-74.141-21.237-117.409-99.181-96.187-173.271C81.09 106.232 129.39 66.081 186.8 60.433c5.76-.567 25.716-.22 31.2.542m-57.4 94.781c-1.92.838-3.855 2.682-4.648 4.427-.974 2.145-1.175 76.834-.213 79.13.828 1.974 2.657 3.923 4.444 4.735 2.145.974 76.834 1.175 79.13.213 1.974-.828 3.923-2.657 4.735-4.444.974-2.145 1.175-76.834.213-79.13-.828-1.974-2.657-3.923-4.444-4.735-2.115-.96-77.043-1.146-79.217-.196",fill:"#0454fc"}),(0,l.jsx)("path",{d:"M181.5 155.1c10.175.059 26.825.059 37 0 10.175-.06 1.85-.108-18.5-.108s-28.675.048-18.5.108M154.992 200c0 20.35.048 28.675.108 18.5.059-10.175.059-26.825 0-37-.06-10.175-.108-1.85-.108 18.5m90 0c0 20.35.048 28.675.108 18.5.059-10.175.059-26.825 0-37-.06-10.175-.108-1.85-.108 18.5M181.5 245.1c10.175.059 26.825.059 37 0 10.175-.06 1.85-.108-18.5-.108s-28.675.048-18.5.108",fill:"#5286fc"}),(0,l.jsx)("path",{d:"M192.7 60.282a5.661 5.661 0 001.8 0c.495-.095.09-.173-.9-.173s-1.395.078-.9.173m12.8 0a5.661 5.661 0 001.8 0c.495-.095.09-.173-.9-.173s-1.395.078-.9.173M60.109 193.6c0 .99.078 1.395.173.9a5.661 5.661 0 000-1.8c-.095-.495-.173-.09-.173.9m279.6 0c0 .99.078 1.395.173.9a5.661 5.661 0 000-1.8c-.095-.495-.173-.09-.173.9m-279.6 12.8c0 .99.078 1.395.173.9a5.661 5.661 0 000-1.8c-.095-.495-.173-.09-.173.9m279.6 0c0 .99.078 1.395.173.9a5.661 5.661 0 000-1.8c-.095-.495-.173-.09-.173.9m-238.926 92.5c1.658 1.766 2.017 2.084 2.017 1.783 0-.064-.855-.919-1.9-1.9L99 297l1.783 1.9m198.017.1c-.972.99-1.677 1.8-1.567 1.8.11 0 .995-.81 1.967-1.8.972-.99 1.677-1.8 1.567-1.8-.11 0-.995.81-1.967 1.8m-106.1 40.882a5.661 5.661 0 001.8 0c.495-.095.09-.173-.9-.173s-1.395.078-.9.173m12.8 0a5.661 5.661 0 001.8 0c.495-.095.09-.173-.9-.173s-1.395.078-.9.173",fill:"#84acfc"}),(0,l.jsx)("path",{d:"M100.786 101.1l-2.186 2.3 2.3-2.186c2.137-2.032 2.483-2.414 2.186-2.414-.062 0-1.097 1.035-2.3 2.3M298.8 101c1.195 1.21 2.263 2.2 2.373 2.2.11 0-.778-.99-1.973-2.2-1.195-1.21-2.263-2.2-2.373-2.2-.11 0 .778.99 1.973 2.2",fill:"#7cacfc"})]})})},797837:(e,t,n)=>{n.d(t,{A:()=>i});var l=n(350979);n(25963);var r=n(257057);let i=e=>(0,l.jsxs)(r.A,{x:"0px",y:"0px",viewBox:"0 0 1000 1000",...e,children:[(0,l.jsxs)("linearGradient",{id:"a",gradientUnits:"userSpaceOnUse",x1:416.6229,y1:16.304,x2:416.6229,y2:985.446,children:[(0,l.jsx)("stop",{offset:.3,stopColor:"#ff1b2d"}),(0,l.jsx)("stop",{offset:.4381,stopColor:"#fa1a2c"}),(0,l.jsx)("stop",{offset:.5939,stopColor:"#ed1528"}),(0,l.jsx)("stop",{offset:.7581,stopColor:"#d60e21"}),(0,l.jsx)("stop",{offset:.9272,stopColor:"#b70519"}),(0,l.jsx)("stop",{offset:1,stopColor:"#a70014"})]}),(0,l.jsx)("path",{d:"M335.4 781.8c-55.3-65.3-91.1-161.7-93.5-270v-23.6c2.4-108.3 38.2-204.7 93.5-270C407.2 125.1 513.8 66 632.8 66c73.2 0 141.8 22.4 200.4 61.3C745.2 48.5 629.2.5 501.9 0H500C223.9 0 0 223.9 0 500c0 268.2 211.1 487 476.2 499.4 7.9.4 15.8.6 23.8.6 128 0 244.8-48.1 333.2-127.2-58.6 38.8-127.1 61.2-200.4 61.2-119 0-225.6-59.1-297.4-152.2z",fill:"url(#a)"}),(0,l.jsxs)("linearGradient",{id:"b",gradientUnits:"userSpaceOnUse",x1:667.7092,y1:73.4257,x2:667.7092,y2:930.5844,children:[(0,l.jsx)("stop",{offset:0,stopColor:"#9c0000"}),(0,l.jsx)("stop",{offset:.7,stopColor:"#ff4b4b"})]}),(0,l.jsx)("path",{d:"M335.4 218.2c45.9-54.2 105.1-86.8 169.9-86.8 145.6 0 263.5 165 263.5 368.6s-118 368.6-263.5 368.6c-64.7 0-124-32.7-169.9-86.8C407.2 874.9 513.8 934 632.8 934c73.2 0 141.8-22.4 200.4-61.2C935.6 781.2 1000 648.1 1000 500c0-148.1-64.4-281.2-166.8-372.7C774.6 88.4 706.1 66 632.8 66c-119 0-225.6 59.1-297.4 152.2z",fill:"url(#b)"})]})},830640:(e,t,n)=>{n.d(t,{A:()=>eh});var l=n(350979),r=n(769932),i=n(812297),s=n(966983),o=n(819324),a=n(25963),d=n(228876),c=n(680797),u=n(857036),h=n(796147),x=n(677681),p=n(579518),m=n(605641),f=n(430586),g=n(557423),v=n(371665),j=n(779243),A=n(727353),C=n(127243),w=n(990296),b=n(158956),y=n(352234),k=n(266283),I=n(767385),L=n(118708),S=n(334804),M=n(968349),T=n(735872),R=n(320669),E=n(842807);let N=(0,c.I4)(h.VP).withConfig({componentId:"sc-6991ba98-0"})(["width:100%;height:100%;
1"]),O=(0,c.I4)(R.Ay).withConfig({componentId:"sc-6991ba98-1"})(["background-color:",";border:solid 1px;border-color:",";transition:200ms;align-items:center;padding:1rem;border-radius:20px;opacity:",";"],e=>{let{active:t,theme:n}=e;return t?`${n.colors.success19}`:"transparent"},e=>{let{active:t,theme:n}=e;return t?n.colors.success:n.colors.tertiary},e=>{let{hasActiveTokens:t}=e;return t?1:.4}),V=(0,a.memo)(function(e){var t;let{listUrl:n,chainId:i}=e,{chainId:s}=(0,M.ax)(),o=i||s,{t:d}=(0,r.A)(),c=(0,T.pY)(n,o),A=(0,L.md)(T.Ys),[,C]=(0,S.pE)(),{current:w,pendingUpdate:y}=A[n],k=(0,a.useMemo)(()=>w&&o?w.tokens.reduce((e,t)=>t.chainId===o?e+1:e,0):0,[o,w]),I=(0,a.useCallback)(()=>{y&&C((0,u.CG)(n))},[C,n,y]),E=(0,x.S)(),N=(0,a.useCallback)(()=>{E({message:"Please confirm you would like to remove this list",onConfirm:e=>e&&C((0,u.tK)(n))})},[E,C,n]),V=(0,a.useCallback)(()=>{C((0,u.c6)(n))},[C,n]),F=(0,a.useCallback)(()=>{C((0,u.lr)(n))},[C,n]),{targetRef:Z,tooltip:H,tooltipVisible:P}=(0,p.A)((0,l.jsxs)("div",{children:[(0,l.jsx)(m.A,{children:w&&(t=w.version,`v${t.major}.${t.minor}.${t.patch}`)}),(0,l.jsx)(f.A,{external:!0,href:`https://tokenlists.org/token-list?url=${n}`,children:d("See")}),(0,l.jsx)(g.A,{variant:"danger",scale:"xs",onClick:N,disabled:1===Object.keys(A).length,children:d("Remove")}),y&&(0,l.jsx)(g.A,{variant:"text",onClick:I,style:{fontSize:"12px"},children:d("Update list")})]}),{placement:"right-end",trigger:"click",isInPortal:!1});if(!w)return null;let U=function(e){let t=e.logoURI;return(null==t?void 0:t.match(/static\.coingecko\.com/))?"https://tokens.pancakeswap.finance/images/projects/coingecko.png":t||""}(w);return(0,l.jsxs)(O,{active:c,hasActiveTokens:k>0,id:`list-row-${n.replace(/\./g,"-")}`,children:[P&&H,U?(0,l.jsx)(b.O,{size:"40px",style:{marginRight:"1rem"},logoURI:U,alt:`${w.name} list logo`}):(0,l.jsx)("div",{style:{width:"24px",height:"24px",marginRight:"1rem"}}),(0,l.jsxs)(h.VP,{style:{flex:"1"},children:[(0,l.jsx)(R.Ay,{children:(0,l.jsx)(m.A,{bold:!0,children:w.name})}),(0,l.jsxs)(R.Bp,{mt:"4px",children:[(0,l.jsxs)(m.A,{fontSize:"12px",mr:"6px",textTransform:"lowercase",children:[w.tokens.length," ",d("Tokens")]}),(0,l.jsx)("span",{ref:Z,children:(0,l.jsx)(v.A,{color:"text",width:"12px"})})]})]}),(0,l.jsx)(j.A,{checked:c,onChange:()=>{c?F():V()}})]},n)}),F=c.I4.div.withConfig({componentId:"sc-6991ba98-2"})(["padding:1rem 0;height:100%;overflow:auto;"]),Z=function(e){let{setModalView:t,setImportList:n,setListUrl:i,chainId:s}=e,[o,d]=(0,a.useState)(""),{chainId:c}=(0,M.ax)(),x=s||c,{t:p}=(0,r.A)(),[,f]=(0,S.pE)(),v=(0,T.Nn)(x),j=(0,S.gJ)(),L=(0,a.useCallback)(e=>{d(e.target.value)},[]),O=(0,u.jU)(f),Z=(0,a.useMemo)(()=>(0,y.A)(o).length>0,[o]),H=(0,a.useMemo)(()=>Object.keys(v).filter(e=>{if(v[e].current&&!I.An.includes(e)&&x){var t;return null==(t=I._e[x])?void 0:t.includes(e)}return!1}).sort((e,t)=>{let{current:n}=v[e],{current:l}=v[t];if(n&&l){let e="pancakeswap";return!n.name.toLowerCase().includes(e)&&l.name.toLowerCase().includes(e)?1:n.name.toLowerCase()<l.name.toLowerCase()?-1:+(n.name.toLowerCase()!==l.name.toLowerCase())}return n?-1:+!!l}),[v,x]),[P,U]=(0,a.useState)(),[_,B]=(0,a.useState)();(0,a.useEffect)(()=>{Z?O(o,!1).then(e=>U(e)).catch(()=>B("Error importing list")):(U(void 0),""!==o&&B("Enter valid list location")),""===o&&B(void 0)},[O,o,Z]);let W=Object.keys(v).includes(o),$=(0,a.useCallback)(()=>{P&&(n(P),t(E.Yg.importList),i(o))},[o,n,i,t,P]);return(0,l.jsxs)(N,{children:[(0,l.jsxs)(h.mm,{gap:"14px",children:[(0,l.jsx)(R.Ay,{children:(0,l.jsx)(A.A,{id:"list-add-input",scale:"lg",placeholder:p("https:// or ipfs://"),value:o,onChange:L})}),_?(0,l.jsx)(m.A,{color:"failure",style:{textOverflow:"ellipsis",overflow:"hidden"},children:_}):null]}),P&&(0,l.jsx)(h.mm,{style:{marginTop:8},children:(0,l.jsx)(k.Ay,{padding:"12px 20px",children:(0,l.jsxs)(R.JA,{children:[(0,l.jsxs)(R.Bp,{children:[P.logoURI&&(0,l.jsx)(b.O,{logoURI:P.logoURI,size:"40px"}),(0,l.jsxs)(h.mm,{gap:"4px",style:{marginLeft:"20px"},children:[(0,l.jsx)(m.A,{bold:!0,children:P.name}),(0,l.jsxs)(m.A,{color:"textSubtle",small:!0,textTransform:"lowercase",children:[P.tokens.length," ",p("Tokens")]})]})]}),W?(0,l.jsxs)(R.Bp,{children:[(0,l.jsx)(C.A,{width:"16px",mr:"10px"}),(0,l.jsx)(m.A,{children:p("Loaded")})]}):(0,l.jsx)(g.A,{width:"fit-content",onClick:$,children:p("Import")})]})})}),(0,l.jsx)(F,{children:(0,l.jsx)(h.mm,{gap:"md",children:j?H.map(e=>(0,l.jsx)(V,{listUrl:e,chainId:x},e)):(0,l.jsx)(l.Fragment,{children:H.map(e=>(0,l.jsx)(w.Ay,{height:"72px",borderRadius:"20px"},e))})})})]})};var H=n(673115),P=n(785459),U=n(28192),_=n(671261),B=n(150103),W=n(131619),$=n(518400),D=n(961330),q=n(733775),K=n(279355);let z=c.I4.div.withConfig({componentId:"sc-57e72ac6-0"})(["width:100%;height:calc(100% - 60px);position:relative;padding-bottom:60px;"]),Q=c.I4.div.withConfig({componentId:"sc-57e72ac6-1"})(["position:absolute;bottom:0;width:100%;display:flex;justify-content:space-between;align-items:center;"]);function G(e){let{setModalView:t,setImportToken:n,chainId:i}=e,{chainId:s}=(0,M.ax)(),o=i||s,{t:d}=(0,r.A)(),[c,u]=(0,a.useState)(""),x=(0,a.useRef)(),p=(0,a.useCallback)(e=>{let t=e.target.value;u((0,q.QR)(t)||t)},[]),f=(0,W.G2)(c,o),v=(0,D.Ay)(o),j=(0,$.GO)(),C=(0,a.useCallback)(()=>
1{o&&v&&v.forEach(e=>j(o,e.address))},[j,v,o]),w=(0,a.useMemo)(()=>o&&v.map(e=>(0,l.jsxs)(R.JA,{width:"100%",children:[(0,l.jsxs)(R.Bp,{children:[(0,l.jsx)(B.Zm,{currency:e,size:"20px"}),(0,l.jsx)(H.A,{external:!0,href:(0,q.Bz)(e.address,"address",o),color:"textSubtle",ml:"10px",mr:"3px",children:e.symbol}),(0,l.jsx)("a",{href:(0,q.Bz)(e.address,"token",o),target:"_blank",rel:"noreferrer noopener",children:(0,l.jsx)(P.A,{width:"20px",color:"textSubtle"})})]}),(0,l.jsx)(R.Bp,{children:(0,l.jsx)(U.A,{variant:"text",onClick:()=>j(o,e.address),children:(0,l.jsx)(_.A,{color:"textSubtle"})})})]},e.address)),[v,o,j]),b=""===c||(0,q.QR)(c);return(0,l.jsx)(z,{children:(0,l.jsxs)(h.VP,{style:{width:"100%",flex:"1 1"},children:[(0,l.jsxs)(h.mm,{gap:"14px",children:[(0,l.jsx)(R.Ay,{children:(0,l.jsx)(A.A,{id:"token-search-input",scale:"lg",placeholder:"0x0000",value:c,autoComplete:"off",ref:x,onChange:p,isWarning:!b})}),!b&&(0,l.jsx)(m.A,{color:"failure",children:d("Enter valid token address")}),f&&(0,l.jsx)(K.A,{token:f,showImportView:()=>t(E.Yg.importToken),setImportToken:n,style:{height:"fit-content"},chainId:o})]}),w,(0,l.jsxs)(Q,{children:[(0,l.jsxs)(m.A,{bold:!0,color:"textSubtle",children:[null==v?void 0:v.length," ",d(1===v.length?"Imported Token":"Imported Tokens")]}),v.length>0&&(0,l.jsx)(g.A,{variant:"tertiary",onClick:C,children:d("Clear all")})]})]})})}var J=n(619749),Y=n(954335),X=n(60746);let ee=(0,a.memo)(function(e){let{listKey:t,name:n,logoURI:i}=e,{t:s}=(0,r.A)(),[o,d]=(0,L.fp)(X.XF),{tokenCountsByList:c}=(0,Y.F)(),u=t===J.lE.PANCAKESWAP||o[t],x=c[t],p=(0,a.useCallback)(()=>{d(e=>({...e,[t]:!e[t]}))},[t,d]);return(0,l.jsxs)(O,{active:u,hasActiveTokens:u,id:`solana-list-row-${t}`,children:[(0,l.jsx)(b.O,{size:"40px",style:{marginRight:"1rem"},logoURI:i,alt:`${n} list logo`}),(0,l.jsxs)(h.VP,{style:{flex:"1"},children:[(0,l.jsx)(R.Ay,{children:(0,l.jsx)(m.A,{bold:!0,children:n})}),(0,l.jsx)(R.Bp,{mt:"4px",children:(0,l.jsxs)(m.A,{fontSize:"12px",mr:"6px",textTransform:"lowercase",children:[x," ",s("Tokens")]})})]}),t!==J.lE.PANCAKESWAP&&(0,l.jsx)(j.A,{checked:u,onChange:p})]},t)}),et=function(){return(0,l.jsx)(N,{children:(0,l.jsx)(F,{children:(0,l.jsx)(h.mm,{gap:"md",children:J.nq.map(e=>(0,l.jsx)(ee,{listKey:e.key,name:e.name,logoURI:e.logoURI},e.key))})})})};var en=n(206284),el=n(244552),er=n(662928),ei=n(862373),es=n(435222),eo=n(38395),ea=n(638380),ed=n(214687);function ec(e){let{setModalView:t,setImportToken:n}=e,{t:i}=(0,r.A)(),{userTokens:s,tokenList:o,removeUserToken:c,removeAllUserTokens:u}=(0,Y.F)(),[x,p]=(0,a.useState)(""),[f]=(0,L.fp)(ei.fk),v=(0,a.useRef)(),j=(0,a.useCallback)(e=>{p(e.target.value.trim())},[]),{data:C,isError:w}=function(e){let t=(0,ea.W)();return(0,er.I)({queryKey:["solana-useGetTokenInfo",e],queryFn:async()=>{if(!e)return null;try{let n=await t.getAccountInfo(new en.PublicKey(e));if(!n)throw Error("Token address not found");let l=el.x7.decode(n.data),r=e.toString().substring(0,6);return{chainId:d.Cb.SOLANA,address:e,programId:n.owner.toBase58(),logoURI:"",symbol:r,name:r,decimals:l.decimals,tags:[],extensions:{},priority:0,type:"unknown"}}catch(e){throw Error("Token address not found")}},enabled:!!e})}(x),b=(0,a.useCallback)(()=>{if(C){let e={chainId:d.Cb.SOLANA,address:C.address,programId:C.programId,logoURI:C.logoURI||"",symbol:C.symbol,name:C.name||C.symbol||"Unknown Token",decimals:C.decimals,tags:[],priority:5,userAdded:!0,type:"imported",extensions:{}};s.some(t=>t.address===e.address)||(n((0,J.ph)(e)),t(E.Yg.importToken)),p("")}},[C,s,n,t]),y=(0,a.useMemo)(()=>s.map(e=>(0,l.jsxs)(R.JA,{width:"100%",children:[(0,l.jsxs)(R.Bp,{children:[(0,l.jsx)(eo.Z,{currency:(0,J.ph)(e),size:"20px"}),(0,l.jsx)(H.A,{external:!0,href:`${f.host}/token/${e.address}`,color:"textSubtle",ml:"10px",mr:"3px",children:e.symbol}),(0,l.jsx)("a",{href:`${f.host}/token/${e.address}`,target:"_blank",rel:"noreferrer noopener",children:(0,l.jsx)(P.A,{width:"20px",color:"textSubtle"})})]}),(0,l.jsx)(R.Bp,{children:(0,l.jsx)(U.A,{variant:"text",onClick:()=>c(e.address),children:(0,l.jsx)(_.A,{color:"textSubtle"})})})]},e.address)),[s,c,f.host]),k=""===x||(0,ed.T)(x);return(0,l.jsx)(z,{children:(0,l.jsxs)(h.VP,{style:{width:"100%",flex:"1 1"},children:[(0,l.jsxs)(h.mm,{gap:"14px",children:[(0,l.jsx)(R.Ay,{children:(0,l.jsx)(A.A,{id:"token-search-input",scale:"lg",placeholder:"Enter Solana token address",value:x,autoComplete:"off",ref:v,onChange:j,isWarning:!k})}),k?w?(0,l.jsx)(m.A,{color:"failure",children:i("Token address not found")}):null:(0,l.jsx)(m.A,{color:"failure",children:i("Enter valid token address")}
1),C&&(0,l.jsxs)(R.JA,{width:"100%",style:{padding:"4px 20px"},children:[(0,l.jsxs)(R.Bp,{children:[(0,l.jsx)(eo.Z,{currency:C,size:"24px"}),(0,l.jsxs)(h.VP,{style:{marginLeft:"12px"},children:[(0,l.jsx)(m.A,{bold:!0,children:C.symbol}),(0,l.jsx)(m.A,{fontSize:"12px",color:"textSubtle",children:C.name})]})]}),o.some(e=>e.address===C.address)?(0,l.jsxs)(R.Bp,{style:{minWidth:"fit-content"},children:[(0,l.jsx)(es.S,{}),(0,l.jsx)(m.A,{color:"success",children:i("Active")})]}):(0,l.jsx)(g.A,{scale:"sm",onClick:b,children:i("Import")})]})]}),y,(0,l.jsxs)(Q,{children:[(0,l.jsxs)(m.A,{bold:!0,color:"textSubtle",children:[null==s?void 0:s.length," ",i(1===s.length?"Imported Token":"Imported Tokens")]}),s.length>0&&(0,l.jsx)(g.A,{variant:"tertiary",onClick:u,children:i("Clear all")})]})]})})}let eu=(0,c.I4)(i.A).withConfig({componentId:"sc-2a2bb834-0"})(["width:100%;"]);function eh(e){let{setModalView:t,setImportList:n,setImportToken:i,setListUrl:c,chainId:u}=e,[h,x]=(0,a.useState)(!0),{t:p}=(0,r.A)();return(0,l.jsxs)(s.cw,{style:{overflow:"visible"},children:[(0,l.jsxs)(eu,{activeIndex:+!h,onItemClick:()=>x(e=>!e),scale:"sm",variant:"subtle",mb:"32px",children:[(0,l.jsx)(o.A,{width:"50%",children:p("Lists")}),(0,l.jsx)(o.A,{width:"50%",children:p("Tokens")})]}),h?u===d.Cb.SOLANA?(0,l.jsx)(et,{}):(0,l.jsx)(Z,{setModalView:t,setImportList:n,setListUrl:c,chainId:u}):u===d.Cb.SOLANA?(0,l.jsx)(ec,{setModalView:t,setImportToken:i}):(0,l.jsx)(G,{setModalView:t,setImportToken:i,chainId:u})]})}},831016:(e,t,n)=>{n.d(t,{A:()=>o});var l=n(350979),r=n(680797),i=n(432594);let s=r.I4.div.withConfig({componentId:"sc-da8aeab-0"})(["display:flex;flex-direction:row;align-items:center;margin-right:",";"],e=>{let{margin:t}=e;return t&&"4px"});function o(e){let{currency0:t,currency1:n,size:r=20,margin:o=!1}=e;return(0,l.jsxs)(s,{margin:o,children:[t&&(0,l.jsx)(i.Ay,{currency:t,size:`${r.toString()}px`,style:{marginRight:"4px"}}),n&&(0,l.jsx)(i.Ay,{currency:n,size:`${r.toString()}px`})]})}},842807:(e,t,n)=>{n.d(t,{AS:()=>r,Yg:()=>l});var l=function(e){return e[e.search=0]="search",e[e.manage=1]="manage",e[e.importToken=2]="importToken",e[e.importList=3]="importList",e}({}),r=function(e){return e.LIQUIDITY="LIQUIDITY",e.LIMIT_ORDER="LIMIT_ORDER",e.SWAP="SWAP",e.TWAP="TWAP",e}({})},861485:(e,t,n)=>{n.d(t,{A:()=>i});var l=n(350979);n(25963);var r=n(257057);let i=e=>(0,l.jsx)(r.A,{viewBox:"0 0 40 40",...e,children:(0,l.jsx)("path",{opacity:"0.9",d:"M19.9959 4.8377L20.7771 3.82105C20.5523 3.64825 20.2766 3.55457 19.9931 3.55457C19.7095 3.55457 19.4339 3.64825 19.209 3.82105L19.9959 4.8377ZM33.425 8.7837H34.7059C34.7081 8.61378 34.6767 8.44509 34.6134 8.28737C34.5502 8.12965 34.4563 7.98603 34.3372 7.8648C34.2181 7.74358 34.0762 7.64714 33.9196 7.58107C33.763 7.515 33.5949 7.4806 33.425 7.47985V8.7837ZM19.9959 36.2161L19.2837 37.2845C19.4936 37.425 19.7405 37.5 19.9931 37.5C20.2457 37.5 20.4925 37.425 20.7024 37.2845L19.9959 36.2161ZM6.57841 8.7837V7.49709C6.40847 7.49783 6.24036 7.53223 6.0838 7.5983C5.92723 7.66437 5.7853 7.76081 5.66621 7.88204C5.54712 8.00326 5.45322 8.14688 5.38995 8.3046C5.32667 8.46232 5.29526 8.63101 5.29754 8.80093L6.57841 8.7837ZM19.2148 5.84861C25.0275 10.3518 31.6846 10.0646 33.4307 10.0646V7.49709C31.6214 7.49709 25.8259 7.72684 20.7943 3.82105L19.2148 5.84861ZM32.1499 8.76073C32.0522 14.7113 31.7995 18.91 31.317 22.0174C30.8345 25.1248 30.1682 26.9399 29.2894 28.238C28.4106 29.5361 27.2848 30.3804 25.6364 31.3626C23.9879 32.3448 21.8799 33.4361 19.2837 35.1535L20.7312 37.2845C23.1895 35.6475 25.2343 34.6021 26.9747 33.5625C28.7284 32.6075 30.2502 31.2779 31.4319 29.6682C32.5806 27.9451 33.3675 25.6475 33.873 22.408C34.3785 19.1685 34.6369 14.809 34.7346 8.80093L32.1499 8.76073ZM20.7312 35.1535C18.1522 33.4304 16.05 32.362 14.413 31.3684C12.776 30.3747 11.6502 29.582 10.7656 28.238C9.8811 26.8939 9.16312 25.1076 8.66915 22.0174C8.17519 18.9273 7.95692 14.7113 7.85928 8.76073L5.29754 8.80093C5.39518 14.809 5.6594 19.18 6.15911 22.408C6.65882 25.636 7.42275 27.9336 8.59448 29.6682C9.77051 31.2788 11.2888 32.6088 13.0402 33.5625C14.7633 34.6021 16.8254 35.6475 19.2837 37.2845L20.7312 35.1535ZM6.57841 10.0646C8.30155 10.0646 14.9644 10.3518 20.7771 5.84861L19.209 3.82105C14.166 7.72684 8.37048 7.49709 6.57266 7.49709L6.57841 10.0646Z",fill:"#3688EB"})})},935711:(e,t,n)=>{n.d(t,{A:()=>d});var l=n(350979),r=n(25963),i=n(828266),s=n(824961),o=n(450536),a=n(482335);let d=e=>{var t,n,d;let{component:c,options:u,children:h,isOpen:x=!1}=e,[p,m]=(0,r.useState)(null),[f,g]=(0,r.useState)(null),v=null!=(t=null==u?void 0:u.placement)?t:"bottom",j=null!=(n=null==u?void 0:u.offset)?n:[0,10],A=null!=(d=null==u?void 0:u.padding)?d:{left:16,right:16},[C,w]=(0,r.useState)(x),b=()=>{w(e=>!e)};(0,r.useEffect)(()=>{w(x)},[x,w]),(0,r.useEffect)(()=>
1{if(null!==f&&null!==p){let e=e=>{let{target:t}=e;t instanceof Node&&!f.contains(t)&&!p.contains(t)&&w(!1)};return document.addEventListener("click",e),()=>{document.removeEventListener("click",e)}}},[f,p]);let{styles:y,attributes:k}=(0,s.E)(p,f,{placement:v,modifiers:[{name:"offset",options:{offset:j}},{name:"preventOverflow",options:{padding:A}}]}),I=(0,l.jsx)("div",{ref:g,style:{...y.popper,zIndex:100},...k.popper,children:"function"==typeof h?h({toggle:b,open:()=>{w(!0)},close:()=>{w(!1)}}):h}),L=(0,o.A)(),S=L?(0,i.createPortal)(I,L):I;return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(a.Qr,{ref:m,onClick:b,children:c}),C&&S]})}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.