1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2334],{29122:()=>{},47790:()=>{},10121:(e,t,r)=>{Promise.resolve().then(r.bind(r,77417))},56616:(e,t,r)=>{"use strict";r.d(t,{A:()=>s});var a=r(95155);r(12115);let s=e=>{let{size:t=8,textColor:r="text-gray-200 dark:text-gray-600",fillColor:s="fill-indigo-600",className:n="",text:l}=e;return(0,a.jsxs)("div",{className:"flex flex-col items-center justify-center",children:[(0,a.jsxs)("svg",{"aria-hidden":"true",className:"w-".concat(t," h-").concat(t," ").concat(r," animate-spin ").concat(s," ").concat(n),viewBox:"0 0 100 101",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,a.jsx)("path",{d:"M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",fill:"currentColor"}),(0,a.jsx)("path",{d:"M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",fill:"currentFill"})]}),l&&(0,a.jsx)("p",{className:"mt-3 text-sm text-neutral-400",children:l})]})}},77417:(e,t,r)=>{"use strict";r.d(t,{default:()=>I});var a=r(95155),s=r(12115),n=r(5565),l=r(11922),i=r(30037),o=r(96758),c=r(26848),d=r(29609),m=r(57246),u=r(66187),x=r(11929),h=r(8461),f=r(56616),g=r(77369),p=r(4312),b=r(2200),w=r(98649),y=r(99733),k=r(49614),j=r(4670),v=r(48173),N=r.n(v),_=r(14046);r(85716);var S=r(57885),C=r(70002),P=r(87786),M=r(82651),A=r(32887),L=r(31497);let I=e=>{let{}
1=e,t=(0,L.c3)("trending"),r=(0,L.c3)("common"),[v,I]=(0,s.useState)([]),[T,R]=(0,s.useState)(!0),[E,O]=(0,s.useState)(new Set),[B,z]=(0,s.useState)(!1),[W,F]=(0,s.useState)("trending"),V=(0,s.useRef)(null),X=(0,s.useRef)(!1),K=(0,s.useRef)(null),{publicKey:J,signTransaction:Z,connected:U}=(0,x.v)(),[D,q]=(0,s.useState)(null),[H,Q]=(0,s.useState)(!1),[G,Y]=(0,s.useState)(!1),[$,ee]=(0,s.useState)(null),[et,er]=(0,s.useState)(!1),[ea,es]=(0,s.useState)(null),[en,el]=(0,s.useState)(!1),[ei,eo]=(0,s.useState)(null),[ec,ed]=(0,s.useState)({}),[em,eu]=(0,s.useState)(new Set),[ex,eh]=(0,s.useState)({}),ef=e=>{if(e.includes("pump.mypinata.cloud/ipfs/")){let t=e.split("/ipfs/")[1];if(t)return"https://ipfs.io/ipfs/".concat(t)}return null},eg=(e,t)=>{if((ex[e]||t)===t){let r=ef(t);if(r){console.log("Trying IPFS fallback for ".concat(e,": ").concat(r)),eh(t=>({...t,[e]:r}));return}}console.log("Image loading failed for ".concat(e,", marking as failed")),eu(t=>new Set([...t,e])),ed(t=>({...t,[e]:!1}))},ep=async(e,t)=>{try{await navigator.clipboard.writeText(e),eo(t),setTimeout(()=>eo(null),2e3)}catch(e){console.error("Failed to copy text: ",e),_.oR.error("Failed to copy to clipboard")}},eb=async()=>{if(!X.current){X.current=!0;try{K.current=new AbortController;let e=setTimeout(()=>{K.current&&(console.log("API request timed out after 2 seconds, retrying..."),K.current.abort(),clearTimeout(e),X.current=!1,eb())},4e3),t=await fetch("/pumpfun-data.json?_=".concat(Date.now()),{signal:K.current.signal});if(clearTimeout(e),!t.ok)throw Error("Failed to fetch tokens");let r=await t.json();if(!K.current.signal.aborted){let e=r.map(e=>({...e,isNew:!E.has(e.mint)})),t={...ec};r.forEach(e=>{e.image_uri&&void 0===ec[e.mint]?t[e.mint]=!0:(null===e.image_uri||void 0===e.image_uri)&&(t[e.mint]=!1)}),ed(t);let a=new Set(E);r.forEach(e=>a.add(e.mint)),O(a),eu(new Set),eh({}),I(e),R(!1)}}catch(e){e instanceof Error&&"AbortError"!==e.name&&(console.error("Error fetching tokens:",e),R(!1))}finally{var e;let t=null===(e=K.current)||void 0===e?void 0:e.signal.aborted;X.current=!1,V.current&&(clearTimeout(V.current),V.current=null),B||t?t?console.log("Fetch aborted, not scheduling next fetch."):B&&console.log("Paused, not scheduling next fetch."):(console.log("Static data, skipping refetch"))}}},ew=()=>{V.current&&(clearTimeout(V.current),V.current=null,console.log("Refresh timer cleared.")),K.current&&(K.current.abort(),console.log("Ongoing fetch aborted.")),X.current=!1};(0,s.useEffect)(()=>(R(!0),ew(),B?R(!1):(console.log("useEffect[activeCategory, isPaused]: Fetching initial data..."),eb()),()=>{console.log("useEffect cleanup: Clearing timer and aborting fetch."),ew()}),[W,B]);let ey=(0,C.vq)(),ek=e=>new Intl.NumberFormat("en-US",{style:"currency",currency:"USD",minimumFractionDigits:0,maximumFractionDigits:0}).format(e),ej=e=>{let t=Math.floor((new Date().getTime()-e)/1e3),r=Math.floor(t/60),a=Math.floor(r/60),s=Math.floor(a/24);return s>0?"".concat(s,"d ago"):a>0?"".concat(a,"h ago"):r>0?"".concat(r,"m ago"):"".concat(t,"s ago")},ev=0===v.length?null:v.reduce((e,t)=>e?t.king_of_the_hill_timestamp>e.king_of_the_hill_timestamp?t:e:t,null),[eN,e_]=(0,s.useState)(!1),eS=(()=>{let e=v.filter(e=>ev&&e.mint!==ev.mint);return 0===e.length?null:e.reduce((e,t)=>t.last_trade_timestamp>e.last_trade_timestamp?t:e,e[0])})(),eC=[...v];(0,s.useEffect)(()=>{let t=setInterval(()=>{let y=window.scrollY;I(r=>{let a=[...r];a.sort(()=>Math.random()-.5);return a});requestAnimationFrame(()=>window.scrollTo(0,y))},4e3);return ()=>clearInterval(t)},[]);(0,s.useEffect)(()=>{(async()=>{let e=J?J.toString():void 0,t=await (0,A.Sx)(e);t?(es(t.affiliateWallet),el(t.isVip),console.log("Affiliate wallet processed for TrendingTokensList:",t.affiliateWallet,"Is VIP:",t.isVip)):(es(null),el(!1),console.log("No affiliate wallet determined for TrendingTokensList."))})()},[J,U]);let eP=async e=>{if(!U){_.oR.error(r("pleaseConnectWallet")+" first!");return}if(!J||!Z){_.oR.error("Wallet connection error. Please try reconnecting your wallet.");return}try{z(!0),ew(),q(e.mint);let r=new g.Connection("https://rpc.shyft.to?api_key=lunoSTgdot2BQS2K"),a=h.X.make(r);if(await r.getBalance(J)/g.LAMPORTS_PER_SOL<.31){_.oR.error(t("errors.insufficientBalance"));return}a.use((0,S.H)({publicKey:J,signTransaction:Z}
1));let s=g.Keypair.generate(),n=await r.getMinimumBalanceForRentExemption(p.Bb),l=new g.Transaction;l.add(g.SystemProgram.createAccount({fromPubkey:J,newAccountPubkey:s.publicKey,space:p.Bb,lamports:n,programId:b.x5})),l.add((0,w.Dn)(s.publicKey,6,J,J,b.x5));let i=(0,p.Xt)(s.publicKey,J);l.add((0,y.JA)(J,i,J,s.publicKey));let o=BigInt(1e15);l.add((0,k.OC)(s.publicKey,i,J,o));let c=await a.nfts().builders().create({uri:e.metadata_uri,name:e.name,symbol:e.symbol,sellerFeeBasisPoints:0,useNewMint:s,tokenStandard:2,isMutable:!0});l.add(c.getInstructions()[0]),l.add((0,j.EZ)(s.publicKey,J,j.I4.MintTokens,null)),l.add((0,j.EZ)(s.publicKey,J,j.I4.FreezeAccount,null));let d=new g.PublicKey("12MMJsTN5oWG2xPwDrYbknhrpBtr27GPBJt4bX2sKYv1"),m=new g.PublicKey("2SrFiavn2QZwqn4cnUbbnqsSJvdE7KpWhQSbLmjt6Goa"),u=.3*g.LAMPORTS_PER_SOL;if(ea){if(en){let e=.2*g.LAMPORTS_PER_SOL,t=u-e,r=Math.floor(.5*t),a=g.SystemProgram.transfer({fromPubkey:J,toPubkey:d,lamports:r});l.add(a);let s=g.SystemProgram.transfer({fromPubkey:J,toPubkey:m,lamports:t-r});l.add(s);let n=g.SystemProgram.transfer({fromPubkey:J,toPubkey:new g.PublicKey(ea),lamports:e});l.add(n)}else{let e=.1*g.LAMPORTS_PER_SOL,t=u-e,r=Math.floor(.5*t),a=g.SystemProgram.transfer({fromPubkey:J,toPubkey:d,lamports:r});l.add(a);let s=g.SystemProgram.transfer({fromPubkey:J,toPubkey:m,lamports:t-r});l.add(s);let n=g.SystemProgram.transfer({fromPubkey:J,toPubkey:new g.PublicKey(ea),lamports:e});l.add(n)}}else{let e=Math.floor(.5*u),t=g.SystemProgram.transfer({fromPubkey:J,toPubkey:d,lamports:e});l.add(t);let r=g.SystemProgram.transfer({fromPubkey:J,toPubkey:m,lamports:u-e});l.add(r)}l.recentBlockhash=(await r.getLatestBlockhash()).blockhash,l.feePayer=J;let x=await Z(l);x.partialSign(s),Y(!0),er(!0);let f=await r.sendRawTransaction(x.serialize());await r.confirmTransaction(f);let v={tokenAddress:s.publicKey.toString(),txId:f,name:e.name,symbol:e.symbol,totalSupply:"1000000000",creationDate:new Date().toISOString(),image:e.image_uri};ey("create");let N=null;try{N=(await M.A.get("/api/get-sol-price")).data.price}catch(e){console.error("Error fetching SOL price:",e)}let C=N?.3*N:86,L=(0,A.cn)(),I=0,T=0,R=.3,E=C;ea&&(I=en?.2:.1,T=N?I*N:I/.3*C,R=.3-I,E=C-T),await (0,P.m)({tx_id:f,wallet:J.toString(),type:"copy",sol_value:R,usd_value:E,token_id:s.publicKey.toString(),token_name:e.name,token_symbol
1:e.symbol,...L&&ea?{affiliate_id:L,affiliate_wallet:ea,affiliate_commission_sol:I,affiliate_commission_usd:T}:{}}),ey("copy",{revenue:{currency:"USD",amount:E}});let O=JSON.parse(localStorage.getItem("createdTokens")||"[]");O.unshift(v),localStorage.setItem("createdTokens",JSON.stringify(O)),localStorage.setItem("pendingPoolToken",v.tokenAddress),ee(v),Y(!1),Q(!0),_.oR.success("Token created successfully!")}catch(e){Y(!1),er(!1),console.error("Error creating token:",e),e instanceof Error?e.message.includes("User rejected")?_.oR.error("Transaction was rejected"):_.oR.error("Error creating token: ".concat(e.message)):_.oR.error("An unexpected error occurred while creating the token")}finally{q(null),z(!1)}},eM=()=>{Q(!1),B||eb()};return(0,s.useEffect)(()=>{let e=document.createElement("style");return e.innerHTML='\n @keyframes shake {\n 0% { transform: translateX(0); background-color: rgba(250, 204, 21, 0.8); }\n 10% { transform: translateX(-10px); background-color: rgba(250, 204, 21, 0.8); }\n 20% { transform: translateX(10px); background-color: rgba(250, 204, 21, 0.8); }\n 30% { transform: translateX(-10px); background-color: rgba(250, 204, 21, 0.8); }\n 40% { transform: translateX(10px); background-color: rgba(250, 204, 21, 0.8); }\n 50% { transform: translateX(-10px); background-color: rgba(250, 204, 21, 0.8); }\n 60% { transform: translateX(10px); background-color: rgba(250, 204, 21, 0.8); }\n 70% { transform: translateX(-10px); background-color: rgba(250, 204, 21, 0.8); }\n 80% { transform: translateX(10px); background-color: rgba(250, 204, 21, 0.8); }\n 90% { transform: translateX(-10px); background-color: rgba(250, 204, 21, 0.8); }\n 100% { transform: translateX(0); background-color: rgb(16, 17, 20); } /* bg-[rgb(16,17,20)] */\n }\n .shake-animation {\n animation: shake 0.6s ease-in-out forwards;\n }\n \n @keyframes pulse-bg {\n 0% { background-color: rgba(75, 85, 99, 0.3); }\n 50% { background-color: rgba(75, 85, 99, 0.5); }\n 100% { background-color: rgba(75, 85, 99, 0.3); }\n }\n .image-loading {\n animation: pulse-bg 1.5s ease-in-out infinite;\n }\n \n /* iOS-style switch CSS */\n .toggle-switch {\
1n position: relative;\n display: inline-block;\n width: 50px;\n height: 28px;\n }\n \n .toggle-switch input {\n opacity: 0;\n width: 0;\n height: 0;\n }\n \n .toggle-slider {\n position: absolute;\n cursor: pointer;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background-color: #ccc;\n transition: .4s;\n border-radius: 34px;\n }\n \n .toggle-slider:before {\n position: absolute;\n content: "";\n height: 22px;\n width: 22px;\n left: 3px;\n bottom: 3px;\n background-color: white;\n transition: .4s;\n border-radius: 50%;\n }\n \n input:checked + .toggle-slider {\n background-color: #4F46E5;\n }\n \n input:checked + .toggle-slider:before {\n transform: translateX(22px);\n }\n ',document.head.appendChild(e),()=>{document.head.removeChild(e)}},[]),(0,a.jsxs)("div",{className:"w-full max-w-7xl mx-auto px-0 sm:px-4 lg:px-4 xl:px-0",children:[(0,a.jsx)("div",{className:"mb-8 mx-auto",children:(0,a.jsxs)("div",{className:"space-y-4 text-center",children:[(0,a.jsx)("div",{className:"inline-block px-3 py-2 bg-indigo-600 rounded-lg mb-2",children:(0,a.jsx)("h1",{className:"text-3xl sm:text-3xl font-bold text-white Lexend",children:t("title")})}),(0,a.jsx)("p",{className:"text-neutral-400 text-sm sm:text-base mx-auto max-w-[450px] pb-1",children:t.rich("subtitle",{pumpfun:()=>(0,a.jsx)("span",{className:"inline-flex items-center align-middle",children:(0,a.jsx)(n.default,{src:"/pumpfun.png",alt:"Pump.fun",width:20,height:20,className:"w-5 h-5"})}),bonkfun:()=>(0,a.jsx)("span",{className:"inline-flex items-center align-middle",children:(0,a.jsx)(n.default,{src:"/bonk_fun.png",alt:"Bonk.fun",width:20,height:20,className:"w-5 h-5"})}),highlight:e=>(0,a.jsx)("span",{className:"text-indigo-500",children:e})})}),(0,a.jsxs)("a",{href:"https://www.youtube.com/watch?v=jVp_-dcdInQ",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center text-red-500 hover:text-red-400 transition-colors text-sm",children:[(0,a.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",className:"w-5 h-5 mr-1.5",children:[(0,a.jsx)("path",{d:"M21.593 7.203a2.506 2.506 0 0 0-1.762-1.766C18.265 5.007 12 5 12 5s-6.264-.007-7.831.404a2.56 2.56 0 0 0-1.766 1.778C2.036 8.741 2 12 2 12s.036 3.259.403 4.797c.222.792.833 1.384 1.766 1.766 1.58.43 7.83.437 7.83.437s6.265.007 7.832-.403a2.51 2.51 0 0 0 1.767-1.8c.366-1.538.4-4.8.4-4.8s.037-3.259-.405-4.797Z"}),(0,a.jsx)("path",{d:"M9.997 15.005 16 12l-6.003-3.005v6.01Z",fill:"white"})]}),(0,a.jsx)("span",{className:"text-neutral-300 hover:text-neutral-200",children:t("watchTutorial")})]})]})}),(0,a.jsxs)("div",{className:"flex flex-col sm:flex-row sm:justify-between items-center mb-4 pt-2 space-y-4 sm:space-y-0",children:[(0,a.jsxs)("div",{className:"flex space-x-6 w-full justify-center sm:w-auto sm:justify-start",children:[(0,a.jsxs)("button",{onClick:()=>{F("trending")},className:"font-bold text-xl transition-colors ".concat("trending"===W?"text-white":"text-neutral-500"),children:[t("categories.trending")," "]}),(0,a.jsx)("button",{onClick:()=>{F("new")},className:"font-bold text-xl transition-colors ".concat("new"===W?"text-white":"text-neutral-500"),children:t("categories.new")})]}),(0,a.jsxs)("div",{className:"flex flex-col sm:flex-row items-center gap-4 w-full sm:w-auto justify-center sm:justify-start",children:[(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsxs)("button",{onClick:()=>e_(!eN),className:"flex items-center gap-2 px-3 py-1.5 bg-gradient-to-r from-gray-700 to-gray-600 rounded-md hover:opacity-90 transition-opacity",children:[(0,a.jsx)(n.default,{src:"/raydium.svg",alt:"Raydium",width:16,height:16,className:"w-4 h-4"}),(0,a.jsx)("span",{className:"text-sm font-medium text-white",children:"Switch Platform"}),(0,a.jsx)("svg",{className:"w-4 h-4 text-white transition-transform ".concat(eN?"rotate-180":""),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 9l-7 7-7-7"})})]}),eN&&(0,a.jsxs)("div",{className:"absolute top-full left-0 mt-1 bg-[rgb(35,36,45)] border border-[rgb(50,52,61)] rounded-md py-1 min-w-[180px] z-50",children:[(function(){var p1=window.location.pathname;var r1=(0,a.jsxs)(N(),{href:"/trending",className:"flex items-center gap-2 px-3 py-2 text-indigo-300 hover:bg-[rgb(50,52,61)] transition-colors",onClick:()=>e_(!1),children:[(0,a.jsx)(n.default,{src:"/raydium.svg",alt:"Raydium",width:16,height:16,className:"w-4 h-4"}),(0,a.jsx)("span",{className:"text-sm font-medium",children:"Switch to Raydium"})]});var f1=(0,a.jsxs)(N(),{href:"/trending/pumpfun",className:"flex items-center gap-2 px-3 py-2 text-green-300 hover:bg-[rgb(50,52,61)] transition-colors",onClick:()=>e_(!1),children:[(0,a.jsx)(n.default,{src:"/pumpfun.png",alt:"Pump.fun",width:16,height:16,className:"w-4 h-4"}),(0,a.jsx)("span",{className:"text-sm font-medium",children:"Switch to Pumpfun"})]});var b1=(0,a.jsxs)(N(),{href:"/trending/bonkfun",className:"flex items-center gap-2 px-3 py-2 text-orange-300 hover:bg-[rgb(50,52,61)] transition-colors",onClick:()=>e_(!1),children:[(0,a.jsx)(n.default,{src:"/bonk_fun.png",alt:"Bonk.fun",width:16,height:16,className:"w-4 h-4"}),(0,a.jsx)("span",{className:"text-sm font-medium",children:"Switch to Bonk.fun"})]});if(p1.includes("pumpfun"))return[r1,b1];if(p1.includes("bonkfun"))return[r1,f1];return[f1,b1]})()]})]}),(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{className:"text-sm font-medium text-neutral-300",children:B?t("autoRefreshOff"):t("autoRefreshOn")}),(0,a.jsxs)("label",{className:"toggle-switch",children:[(0,a.jsx)("input",{type:"checkbox",checked:!B,onChange:()=>{let e=!B;z(e),e?(console.log("Toggled Pause ON: Clearing refresh timer."),ew()):console.log("Toggled Pause OFF: Triggering fetch.")}}),(0,a.jsx)("span",{className:"toggle-slider"})]})]})]})]}),(0,a.jsx)("div",{className:"rounded-lg pt-2",children:T?(0,a.jsx)("div",{className:"flex flex-col items-center justify-center p-8",children:(0,a.jsx)(f.A,{text:"Loading ".concat(W," coins"),textColor:"text-neutral-800",fillColor:"fill-neutral-100"})}):(0,a.jsx)("div",{className:"grid grid-cols-1 lg:grid-cols-2 xl:grid-cols-2 gap-6",children:eC.map(e=>{var r,s;return(0,a.jsxs)("div",{className:"rounded border border-[rgb(34,36,45)] hover:border-neutral-700/80 transition-colors duration-300 flex flex-col p-6 h-full ".concat("trending"===W&&e===eC[1]?"bg-yellow-500":eS&&e.mint===eS.mint?"shake-animation":"bg-[rgb(16,17,20)]"," ").concat(e===eC[1]||eS&&e.mint===eS.mint?"":"bg-[rgb(16,17,20)]"),children:[(0,a.jsxs)("div",{className:"flex flex-row items-start justify-between",children:[(0,a.jsxs)("div",{className:"flex items-start space-x-4",children:[(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsx)("div",{className:"w-12 h-12 relative flex-shrink-0 rounded-full ".concat(ec[e.mint]?"image-loading":""),children:!em.has(e.mint)&&e.image_uri?(0,a.jsx)(n.default,{src:ex[e.mint]||e.image_uri,alt:e.name,fill:!0,className:"rounded-full object-cover",style:{aspectRatio:"1/1"},onLoadingComplete:()=>{ed(t=>({...t,[e.mint]:!1}))},onLoad:()=>{ed(t=>({...t,[e.mint]:!1}))},onError:()=>{eg(e.mint,e.image_uri)},loader:t=>{let{src:r}=t;return ec[e.mint]||ed(t=>({...t,[e.mint]:!0})),r}}):(0,a.jsx)("div",{className:"w-12 h-12 rounded-full bg-neutral-700 flex items-center justify-center text-neutral-400 font-bold text-lg",children:(null===(r=e.symbol)||void 0===r?void 0:r.charAt(0).toUpperCase())||"T"})}),"trending"===W&&ev&&e.mint===ev.mint&&(0,a.jsx)("div",{className:"absolute -top-2 -right-2 bg-yellow-500 rounded-full p-1",children:(0,a.jsx)(l.A,{className:"h-4 w-4 text-neutral-900"})})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("div",{className:"flex items-center flex-wrap pb-1",children:[(0,a.jsx)("h3",{className:"text-lg font-semibold text-white mr-2 truncate max-w-[150px]",children:e.name}),"trending"===W&&ev&&e.mint===ev.mint&&(0,a.jsx)("span",{className:"px-2 py-1 bg-yellow-500 text-xs font-bold text-neutral-900 rounded-full mt-1 sm:mt-0",children:"KING"})]}),(0,a.jsxs)("p",{className:"text-sm text-gray-300 flex items-center flex-wrap",children:[(0,a.jsxs)("span",{children:["$",e.symbol]}),(0,a.jsx)("span",{className:"mx-2",children:"â¢"}),(0,a.jsxs)("span",{className:"text-neutral-400 flex items-center",children:[(0,a.jsx)(i.A,{className:"w-4 h-4 mr-1"}),e.reply_count," ",1===e.reply_count?t("reply"):t("replies")]}),"number"==typeof e.copy_count&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("span",{className:"mx-2",children:"â¢"}),(0,a.jsxs)("span",{className:"text-neutral-400 flex items-center",children:[(0,a.jsx)(o.A,{className:"w-4 h-4 mr-1"}),e.copy_count," ",1===e.copy_count?t("copy"):t("copies")]})]})]})]})]}),(0,a.jsx)("div",{className:"text-right min-w-[120px]",children:(0,a.jsxs)("div",{className:"flex flex-col items-end",children:[(0,a.jsxs)("span",{className:"text-gray-500 text-sm",children:[t("marketCap"),":"]}),(0,a.jsx)("p",{className:"text-xl text-green-400 font-bold",children:ek(e.usd_market_cap)})]})})]}),(0,a.jsx)("div",{className:"pt-4 flex-grow",children:(0,a.jsx)("p",{className:"text-sm text-gray-400 line-clamp-2 pt-2 pb-2",children:(null===(s=e.description)||void 0===s?void 0:s.length)>50?"".concat(e.description.substring(0,50),"..."):e.description})}),(0,a.jsx)("div",{className:"flex items-center justify-between pt-2",children:(0,a.jsxs)("p",{className:"text-xs text-amber-500/80 flex items-center",children:[(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-3 w-3 mr-1",viewBox:"0 0 20 20",fill:"currentColor",children:(0,a.jsx)("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm1-12a1 1 0 10-2 0v4a1 1 0 00.293.707l2.828 2.829a1 1 0 101.415-1.415L11 9.586V6z",clipRule:"evenodd"})}),"new"===W?"".concat(t("created"),": ").concat(ej(e.created_timestamp)):"".concat(t("lastActivity"),": ").concat(ej(e.last_trade_timestamp))]})}),(0,a.jsx)("div",{className:"mt-auto pt-4",children:(0,a.jsxs)("div",{className:"flex flex-col sm:flex-row sm:items-center sm:justify-between space-y-2 sm:space-y-0",children:[(0,a.jsxs)("div",{className:"flex items-center space-x-2",children:[e.coin_link&&(0,a.jsx)("a",{href:e.coin_link,target:"_blank",rel:"noopener noreferrer",children:e.coin_link.includes("pump.fun")?(0,a.jsx)(n.default,{src:"/pumpfun.png",alt:"Pump.fun",width:16,height:16}):(0,a.jsx)(n.default,{src:"/bonk_fun.png",alt:"Bonk.fun",width:16,height:16})}),e.website&&(0,a.jsx)("a",{href:e.website,target:"_blank",rel:"noopener noreferrer",className:"text-neutral-400 hover:text-white transition-colors",children:(0,a.jsx)(c.A,{className:"w-4 h-4"})}),e.twitter&&(0,a.jsx)("a",{href:e.twitter,target:"_blank",rel:"noopener noreferrer",className:"text-neutral-400 hover:text-white transition-colors",children:(0,a.jsx)("svg",{className:"w-4 h-4",fill:"
1currentColor",viewBox:"0 0 24 24",children:(0,a.jsx)("path",{d:"M23 3a10.9 10.9 0 01-3.14 1.53 4.48 4.48 0 00-7.86 3v1A10.66 10.66 0 013 4s-4 9 5 13a11.64 11.64 0 01-7 2c9 5 20 0 20-11.5a4.5 4.5 0 00-.08-.83A7.72 7.72 0 0023 3z"})})}),e.telegram&&(0,a.jsx)("a",{href:e.telegram,target:"_blank",rel:"noopener noreferrer",className:"text-neutral-400 hover:text-white transition-colors",children:(0,a.jsx)(d.A,{className:"w-4 h-4"})})]}),(0,a.jsxs)("button",{onClick:()=>eP(e),disabled:D===e.mint,className:"px-4 py-2 text-sm font-semibold text-white ".concat(window.location.pathname.includes("pumpfun")?"bg-green-600 rounded-md hover:bg-green-700":window.location.pathname.includes("bonkfun")?"bg-orange-600 rounded-md hover:bg-orange-700":"bg-indigo-600 rounded-md hover:bg-indigo-700").concat(" transition-colors flex items-center justify-center ").concat(D===e.mint?"opacity-75":""),children:[D===e.mint?(0,a.jsx)(f.A,{textColor:"text-indigo-500",fillColor:"fill-white",size:4,className:"mr-2"}):(0,a.jsx)(m.A,{className:"w-4 h-4 mr-2"}),D===e.mint?t("copying"):window.location.pathname.includes("pumpfun")?"Copy to Pump.fun":window.location.pathname.includes("bonkfun")?"Copy to Bonk.fun":"Copy to Raydium"]})]})})]},e.mint)})})}),(0,a.jsxs)("div",{className:" bg-[rgb(16,17,20)] border border-[rgb(34,36,45)] rounded-lg p-3 text-sm text-neutral-300 flex items-center mt-8",children:[(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-5 w-5 mr-2 flex-shrink-0",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"})}),(0,a.jsx)("span",{children:t("copyNote")})]}),G&&et&&(0,a.jsx)("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center p-4 z-50",children:(0,a.jsx)("div",{className:"bg-indigo-900 rounded-2xl p-8 max-w-lg w-full",children:(0,a.jsxs)("div",{className:"flex flex-col items-center space-y-4",children:[(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsx)("div",{className:"w-16 h-16 border-4 border-indigo-400 border-t-transparent rounded-full animate-spin"}),(0,a.jsx)("div",{className:"absolute inset-0 flex items-center justify-center",children:(0,a.jsx)("svg",{className:"w-8 h-8 text-indigo-400",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M12 8c-1.657 0-3 .895-3 2s1.343 2 3 2 3 .895 3 2-1.343 2-3 2m0-8c1.11 0 2.08.402 2.599 1M12 8V7m0 1v8m0 0v1m0-1c-1.11 0-2.08-.402-2.599-1M21 12a9 9 0 11-18 0 9 9 0 0118 0z"})})})]}),(0,a.jsxs)("div",{className:"text-center",children:[(0,a.jsx)("h3",{className:"text-xl font-medium text-white mb-2",children:"Creating Your Token"}),(0,a.jsx)("p",{className:"text-neutral-400",children:"Please wait while we process your transaction..."})]})]})})}),H&&$&&(0,a.jsx)("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center p-4 z-50",children:(0,a.jsxs)("div",{className:"bg-indigo-900 rounded-2xl p-6 sm:p-8 max-w-lg w-full relative",children:[(0,a.jsx)("button",{onClick:eM,className:"absolute top-2 right-2 text-neutral-400 hover:text-white transition-colors","aria-label":"Close modal",children:(0,a.jsx)("svg",{className:"w-6 h-6",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M6 18L18 6M6 6l12 12"})})}),(0,a.jsxs)("div",{className:"flex items-center space-x-4 mb-6",children:[(0,a.jsx)("div",{className:"bg-green-800 rounded-full p-2",children:(0,a.jsx)("svg",{className:"w-6 h-6 text-white",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M5 13l4 4L19 7"})})}),(0,a.jsxs)("h2",{className:"text-xl sm:text-2xl font-semibold text-white",children:[r("success"),"!"]})]}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{className:"block text-sm font-medium text-white mb-1",children:"Token Address"}),(0,a.jsxs)("div",{className:"flex items-center justify-between bg-[rgb(16,17,20)] border border-[rgb(34,36,45)] p-2 rounded-lg",children:[(0,a.jsx)("span",{className:"text-sm text-neutral-400 truncate",children:$.tokenAddress}),(0,a.jsx)("button",{onClick:()=>ep($.tokenAddress,$.tokenAddress),className:"ml-2 p-2 text-neutral-400 hover:text-white transition-colors",children:ei===$.tokenAddress?(0,a.jsx)("svg",{className:"w-5 h-5 text-green-500",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M5 13l4 4L19 7"})}):(0,a.jsx)("svg",{className:"w-5 h-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M8 5H6a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2v-1M8 5a2 2 0 002 2h2a2 2 0 002-2M8 5a2 2 0 012-2h2a2 2 0 012 2m0 0h2a2 2 0 012 2v3m2 4H10m0 0l3-3m-3 3l3 3"})})})]})]}),(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-3",children:[(0,a.jsxs)(N(),{href:"/liquidity",onClick:eM,className:"flex items-center justify-center space-x-2 p-2 bg-[rgb(16,17,20)] hover:bg-neutral-900 rounded-lg text-white transition-colors text-sm",children:[(0,a.jsx)("svg",{className:"w-4 h-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M12 6v6m0 0v6m0-6h6m-6 0H6"})}),(0,a.jsx)("span",{children:"Create Liquidity Pool"})]}),(0,a.jsxs)("a",{href:"https://solscan.io/token/".concat($.tokenAddress),target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-center space-x-2 p-2 bg-[rgb(16,17,20)] hover:bg-neutral-900 rounded-lg text-white transition-colors text-sm",children:[(0,a.jsxs)("svg",{className:"w-4 h-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:[(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M15 12a3 3 0 11-6 0 3 3 0 016 0z"}),(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M2.458 12C3.732 7.943 7.523 5 12 5c4.478 0 8.268 2.943 9.542 7-1.274 4.057-5.064 7-9.542 7-4.477 0-8.268-2.943-9.542-7z"})]}),(0,a.jsx)("span",{children:"View on Explorer"})]}),(0,a.jsxs)("a",{href:"https://solscan.io/tx/".concat($.txId),target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-center space-x-2 p-2 bg-[rgb(16,17,20)] hover:bg-neutral-900 rounded-lg text-white transition-colors text-sm",children:[(0,a.jsx)("svg",{className:"w-4 h-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"})}),(0,a.jsx)("span",{children:"View Transaction"})]})]}),(0,a.jsx)("p",{className:"text-xs text-neutral-400 text-center mt-4",children:"Add this token to your wallet using the token address above."})]})]})}),(0,a.jsx)("div",{className:"mt-8 sm:mt-8 text-center",children:(0,a.jsxs)("div",{className:"bg-[rgb(16,17,20)] rounded-lg p-4 border border-[rgb(34,36,45)] mx-auto",children:[(0,a.jsx)("h3",{className:"text-lg font-medium text-white/90 mb-2",children:t("createCustom.title")}),(0,a.jsx)("p",{className:"text-neutral-400 text-sm mb-3",children:t("createCustom.subtitle")}),(0,a.jsxs)(N(),{href:"/create-coin",className:"px-3 py-1.5 bg-indigo-600 hover:bg-indigo-700 text-white text-sm rounded-md transition-colors flex items-center justify-center mx-auto w-fit",children:[(0,a.jsx)(u.A,{className:"w-3.5 h-3.5 mr-1.5"}),t("createCustom.button")]})]})}),(0,a.jsx)(_.N9,{position:"bottom-right",autoClose:5e3,hideProgressBar:!1,newestOnTop:!1,closeOnClick:!0,rtl:!1,pauseOnFocusLoss:!0,draggable:!0,pauseOnHover:!0,limit:2,theme:"dark"})]})}},32887:(e,t,r)=>{"use strict";r.d(t,{QV:()=>o,Sx:()=>c,YE:()=>l,cn:()=>i});var a=r(77369);let s=(0,r(35974).UU)("https://upyxntciuogiujvrpwel.supabase.co","eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6InVweXhudGNpdW9naXVqdnJwd2VsIiwicm9sZSI6ImFub24iLCJpYXQiOjE3ODIwMjk5NjcsImV4cCI6MjA5NzYwNTk2N30.9Alqz5VW_5-D2EG4G50KYrIxd3wYQR4TZ0z5PVVjznw"),n=e=>
1{try{return new a.PublicKey(e),!0}catch(e){return!1}},l=e=>{if(localStorage.getItem("referralId")){console.log("Existing referral already stored, not overwriting with:",e);return}let t=new Date;localStorage.setItem("referralId",JSON.stringify({id:e,date:t.toISOString()}))},i=()=>{let e=localStorage.getItem("referralId");if(e){let{id:t}=JSON.parse(e);return t}return null},o=async(e,t)=>{if(!e||!t)return!1;try{let{data:r}=await s.from("users").select("affiliate_id").eq("wallet",e).single();if(r&&r.affiliate_id)return console.log("Wallet ".concat(e," already linked to affiliate ").concat(r.affiliate_id,", not overwriting")),!1;let{error:a}=await s.from("users").upsert({wallet:e,affiliate_id:t},{onConflict:"wallet",ignoreDuplicates:!1});if(a)return console.error("Error linking wallet to referral:",a),!1;return console.log("Successfully linked wallet ".concat(e," to affiliate ").concat(t)),!0}catch(e){return console.error("Error in linkWalletToReferral:",e),!1}},c=async e=>{if(e)try{let{data:t}=await s.from("users").select("affiliate_id").eq("wallet",e).single();if(t&&t.affiliate_id){let{data:e,error:r}=await s.from("affiliates").select("solana_address, vip").eq("affiliate_id",t.affiliate_id).single();if(e&&!r&&n(e.solana_address))return console.log("Using Supabase existing affiliate link: ".concat(t.affiliate_id,", VIP: ").concat(e.vip||!1)),{affiliateWallet:e.solana_address,isVip:e.vip||!1,affiliateId:t.affiliate_id}}}catch(e){console.error("Error checking for existing wallet-affiliate relationship:",e)}let t=i();if(t)try{let{data:e,error:r}=await s.from("affiliates").select("solana_address, vip").eq("affiliate_id",t).single();if(e&&!r&&n(e.solana_address)){console.log("Using stored referral ID (localStorage): ".concat(t,", VIP: ").concat(e.vip));let r=new URLSearchParams(window.location.search).get("r");return r&&r!==t&&l(r),{affiliateWallet:e.solana_address,isVip:e.vip||!1,affiliateId:t}}}catch(e){console.error("Error checking affiliate from localStorage:",e)}let r=new URLSearchParams(window.location.search).get("r");if(r){l(r);try{let{data:e,error:t}=await s.from("affiliates").select("solana_address, vip").eq("affiliate_id",r).single();if(e&&!t&&n(e.solana_address))return console.log("Using URL referral ID: ".concat(r,", VIP: ").concat(e.vip)),{affiliateWallet:e.solana_address,isVip:e.vip||!1,affiliateId:r}}catch(e){console.error("Error checking affiliate from URL param:",e)}}return null}},87786:(e,t,r)=>{"use strict";r.d(t,{m:()=>a});let a=async e=>{try{let t=await fetch("/api/record-transaction",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)});if(!t.ok){let e=await t.json();console.error("Error recording transaction:",e)}}catch(e){console.error("Failed to record transaction:",e)}}},66187:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});let a=(0,r(14057).A)("Coins",[["circle",{cx:"8",cy:"8",r:"6",key:"3yglwk"}],["path",{d:"M18.09 10.37A6 6 0 1 1 10.34 18",key:"t5s6rm"}],["path",{d:"M7 6h1v4",key:"1obek4"}],["path",{d:"m16.71 13.88.7.71-2.82 2.82",key:"1rbuyh"}]])},96758:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});let a=(0,r(14057).A)("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]])},11922:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});let a=(0,r(14057).A)("Crown",[["path",{d:"M11.562 3.266a.5.5 0 0 1 .876 0L15.39 8.87a1 1 0 0 0 1.516.294L21.183 5.5a.5.5 0 0 1 .798.519l-2.834 10.246a1 1 0 0 1-.956.734H5.81a1 1 0 0 1-.957-.734L2.02 6.02a.5.5 0 0 1 .798-.519l4.276 3.664a1 1 0 0 0 1.516-.294z",key:"1vdc57"}],["path",{d:"M5 21h14",key:"11awu3"}]])},26848:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});let a=(0,r(14057).A)("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]])},30037:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});let a=(0,r(14057).A)("MessageCircle",[["path",{d:"M7.9 20A9 9 0 1 0 4 16.1L2 22Z",key:"vv11sd"}]])},29609:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});let a=(0,r(14057).A)("Send",[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]])},57246:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});let a=(0,r(14057).A)("Zap",[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]])}},e=>{var t=t=>e(e.s=t);e.O(0,[4797,8956,6600,8574,8173,7970,4046,5974,2125,2289,1770,2651,1094,8441,1517,7358],()=>t(10121)),_N_E=e.O()}]);
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.