1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7702],{32256:function(e,t,a){Promise.resolve().then(a.bind(a,50441))},50441:function(e,t,a){"use strict";a.r(t),a.d(t,{default:function(){return _}});var s=a(57437),r=a(2265),n=a(75265),l=a(17437),o=a(99008),i=a(86331),c=a(18868),d=a(32021),h=a(99397),x=a(88893),m=a(87414),u=a(76399),g=a(78867),f=a(6076),p=a(5515),j=a.n(p),b=a(26225),y=a.n(b),v=a(31814),N=a(6803),k=a(27648),w=a(21307);function _(){let[e,t]=(0,r.useState)(""),[a,p]=(0,r.useState)(!1),[b,_]=(0,r.useState)(null),{isOpen:C,onOpen:A,onClose:z}=(0,n.q)(),{userData:S}=(0,N.Z)(),[T,Z]=(0,r.useState)(!1),[E,X]=(0,r.useState)(null),[F,L]=(0,r.useState)(null),[O,Y]=(0,r.useState)(null),[I,P]=(0,r.useState)();(0,r.useEffect)(()=>{(async()=>{if(null==S?void 0:S.profile.stxAddress.mainnet)try{p(!0);let e=await fetch("/api/profile/token_creation?deployed_by=".concat(S.profile.stxAddress.mainnet));if(!e.ok)throw Error("Failed to fetch token creation data");let t=await e.json();_(t)}catch(e){console.error("Error fetching token creation data:",e)}finally{p(!1)}})()},[S]),(0,r.useEffect)(()=>{let e=new URLSearchParams(window.location.search),t=e.get("oauth_token"),a=e.get("oauth_verifier");t&&a&&S&&B(t,a,S.profile.stxAddress.mainnet)},[]);let B=async(e,t,a)=>{Z(!0),X(null);try{let s=await fetch("/api/auth/x/access-token",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({oauth_token:e,oauth_verifier:t,stx_address:a})}),r=await s.json();if(r.access_token){let e={id:r.user_id,screen_name:r.screen_name};Y(e)}else throw Error("Failed to get access token")}catch(e){X("Failed to complete login process"),console.error(e)}finally{V(),Z(!1)}},D=async()=>{Z(!0),X(null),L(null);try{let e=await fetch("/api/auth/x/request-token",{method:"POST"}),t=await e.json();if(t.oauth_token){let e="https://api.x.com/oauth/authenticate?oauth_token=".concat(t.oauth_token);L(e),window.location.href=e}else throw Error("Failed to get request token")}catch(e){X("Failed to initialize login process"),console.error(e)}finally{Z(!1)}},V=async()=>{if(null==S?void 0:S.profile.stxAddress.mainnet)try{let e=await fetch("/api/auth/x/get-verified-info?address=".concat(S.profile.stxAddress.mainnet));if(!e.ok)throw Error("Failed to fetch X verification status");let t=await e.json();P(t)}catch(e){console.error("Error fetching X verification status:",e)}};return(0,r.useEffect)(()=>{V()},[S]),(0,s.jsxs)("div",{className:"flex flex-col min-h-screen bg-gray-50 dark:bg-dark",children:[(0,s.jsxs)(y(),{children:[(0,s.jsx)("title",{children:"Token Creation Checker - STX.CITY"}),(0,s.jsx)("meta",{property:"og:title",content:"Token Creation Checker - STX.CITY"}),(0,s.jsx)("meta",{property:"og:description",content:"Explore tokens created by a specific address on STX.CITY"}),(0,s.jsx)("meta",{property:"og:image",content:"https://stx.city/og-images/token-creation-checker.png"}),(0,s.jsx)("meta",{property:"og:image:width",content:"1200"}),(0,s.jsx)("meta",{property:"og:image:height",content:"630"})]}),(0,s.jsxs)("section",{className:"flex-1 mx-auto px-4 py-8 text-gray-900 dark:text-white",children:[(0,s.jsxs)("div",{className:"flex flex-col items-center space-y-6 mb-8",children:[(0,s.jsx)("h1",{className:"text-3xl font-bold",children:"Dashboard"}),(0,s.jsx)("p",{className:"text-lg text-center text-gray-600 dark:text-gray-300 max-w-2xl",children:"Manage all of your tokens created by you"}),a&&void 0!==S||T&&(0,s.jsxs)("div",{className:"flex flex-col items-center",children:[(0,s.jsx)("img",{src:"https://stx.city/logo-no-bg.svg",alt:"Loading",className:"w-16 h-16 animate-spin animate-bounce",style:{animation:"spin 2s linear infinite, bounce 1s ease-in-out infinite alternate"}}),(0,s.jsx)("p",{className:"mt-4 text-lg font-semibold animate-pulse",children:"Loading..."})]})]}),void 0===S?(0,s.jsx)(w.Z,{message:"Please connect your wallet to view your tokens"}):!a&&b&&(0,s.jsx)("div",{className:"mx-auto px-4 py-8",children:(0,s.jsxs)("div",{className:"space-y-8",children:[(0,s.jsxs)("div",{children:[(0,s.jsx)("h3",{className:"text-xl md:text-2xl font-semibold mb-4",children:"Verify Your X Account"}),(0,s.jsx)(l.w,{className:"p-4 md:p-6 mb-6 md:mb-8",children:(0,s.jsx)(o.G,{className:"flex flex-col items-center gap-4",children:(0,s.jsxs)("div",{className:"flex flex-col gap-2 w-full",children:[(0,s.jsx)("h4",{className:"text-base md:text-lg font-medium text-center",children:(null==I?void 0:I.x_handle)?"X Account Verified":"Connect your X account"}),(null==I?void 0:I.x_handle)?(0,s.jsxs)("div",{className:"text-center",children:[(0,s.jsxs)("p",{className:"text-sm md:text-base text-gray-600 dark:text-gray-300",children:["Your account is verified with X handle: ",(0,s.jsx)(k.default,{target:"_blank",href:"https://x.com/".concat(I.x_handle),className:"hover:underline text-blue-500",children:(0,s.jsxs)("u",{children:["@",I.x_handle]})})]}),(0,s.jsx)(i.A,{color:"primary",variant:"shadow",startContent:(0,s.jsx)("img",{src:"/others/x-logo.svg",alt:"X Logo",className:"w-4 h-4"}),className:"min-w-[140px] mt-4",onClick:D,children:"Re-verify Account"})]}):(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)("p",{className:"text-sm md:text-base text-gray-600 dark:text-gray-300 text-center",children:["Verify ownership of your X account with wallet address"," ",(0,s.jsx)("span",{className:"font-mono bg-gray-100 dark:bg-gray-800 px-2 py-1 rounded break-all",children:null==S?void 0:S.profile.stxAddress.mainnet}),". Once verified, all your tokens will display a verified badge with your X handle."]}),(0,s.jsx)(i.A,{color:"primary",variant:"shadow",startContent:(0,s.jsx)("img",{src:"/others/x-logo.svg",alt:"X Logo",className:"w-4 h-4"}),className:"min-w-[140px]",onClick:D,children:"Verify Now"})]})]})})})]}),(0,s.jsxs)("div",{children:[(0,s.jsxs)("h3",{className:"text-xl font-semibold mb-4",children:["Bonding Curve Tokens (",b.bonding_curve_tokens.length,")"]}),0===b.bonding_curve_tokens.length?(0,s.jsx)(l.w,{className:"p-6",children:(0,s.jsxs)(o.G,{className:"flex flex-col items-center",children:[(0,s.jsx)("p",{className:"text-lg text-center mb-4",children:"You haven't created any bonding curve tokens yet."}),(0,s.jsx)(k.default,{href:"/bonding-curve/create",target:"_blank",children:(0,s.jsx)(i.A,{color:"primary",variant:"shadow",startContent:(0,s.jsx)(h.Z,{size:16}),children:"Create Bonding Curve Token"})})]})}):(0,s.jsx)("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4",children:b.bonding_curve_tokens.map((e,t)=>(0,s.jsxs)("div",{className:"flex flex-col border border-gray-200 dark:border-gray-700 bg-white dark:bg-gray-800 rounded-lg overflow-hidden",children:[(0,s.jsx)(v.Z,{token:e}),(0,s.jsxs)("div",{className:"grid grid-cols-2 gap-2 mt-4 p-4 bg-gradient-to-r from-gray-100 to-gray-200 dark:from-gray-800 dark:to-gray-900 rounded-b-lg",children:[(0,s.jsx)(k.default,{href:"/dashboard/metadata/".concat(e.token_contract,"/bonding"),target:"_blank",className:"col-span-1",children:(0,s.jsx)(i.A,{size:"sm",color:"primary",variant:"shadow",startContent:(0,s.jsx)(x.Z,{size:16}),className:"transition-all duration-300 hover:scale-105 w-full",children:"Update Metadata"})}),(0,s.jsx)(k.default,{href:"/dashboard/airdrop/".concat(e.token_contract),target:"_blank",className:"col-span-1",children:(0,s.jsx)(i.A,{size:"sm",color:"success",variant:"shadow",startContent:(0,s.jsx)(m.Z,{size:16}),className:"transition-all duration-300 hover:scale-105 w-full",children:"Airdrop"})}),(0,s.jsx)(k.default,{href:"/dashboard/burn/".concat(e.token_contract),target:"_blank",className:"col-span-1",children:(0,s.jsx)(i.A,{size:"sm",color:"danger",variant:"shadow",startContent:(0,s.jsx)(u.Z,{size:16}),className:"transition-all duration-300 hover:scale-105 w-full",children:"Burn"})})]})]},t))})]}),(0,s.jsxs)("div",{children:[(0,s.jsxs)("h3",{className:"text-xl font-semibold mb-4",children:["Normal Tokens (",b.deployed_tokens.length,")"]}),0===b.deployed_tokens.length?(0,s.jsx)(l.w,{className:"p-6",children:(0,s.jsxs)(o.G,{className:"flex flex-col items-center",children:[(0,s.jsx)("p",{className:"text-lg text-center mb-4",children:"You haven't created any normal tokens yet."}),(0,s.jsx)(k.default,{href:"/deploy/create",target:"_blank",children:(0,s.jsx)(i.A,{color:"primary",variant:"shadow",startContent:(0,s.jsx)(h.Z,{size:16}),children:"Deploy Normal Token"})})]})}):(0,s.jsx)("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-4",children:b.deployed_tokens.map((e,t)=>(0,s.jsxs)("div",{className:"flex flex-col border border-gray-200 dark:border-gray-700 bg-white dark:bg-gray-800 rounded-lg overflow-hidden",children:[(0,s.jsxs)("div",{className:"p-4",children:[(0,s.jsxs)("div",{className:"flex items-center space-x-4 mb-4",children:[(0,s.jsx)(c.h,{src:e.logo_url,className:"w-16 h-16",alt:e.name}),(0,s.jsxs)("div",{children:[(0,s.jsx)("p",{className:"font-semibold",children:e.name}),(0,s.jsxs)("p",{className:"text-sm text-gray-500",children:["Created: ",new Date(e.deployed_at).toLocaleStr
1ing()]})]})]}),(0,s.jsxs)("div",{className:"grid grid-cols-2 gap-2 text-sm",children:[(0,s.jsxs)("p",{children:[(0,s.jsx)("span",{className:"font-semibold",children:"Symbol:"})," ",e.symbol]}),(0,s.jsxs)("p",{children:[(0,s.jsx)("span",{className:"font-semibold",children:"Supply:"})," ",e.supply]}),(0,s.jsxs)("p",{children:[(0,s.jsx)("span",{className:"font-semibold",children:"Holders:"})," ",e.holders]}),(0,s.jsxs)("div",{className:"col-span-2 flex items-center",children:[(0,s.jsx)("span",{className:"font-semibold mr-2",children:"Contract:"}),(0,s.jsx)("div",{className:"flex-1 overflow-hidden",children:(0,s.jsx)("p",{className:"truncate",children:e.contract_id})}),(0,s.jsx)(i.A,{size:"sm",isIconOnly:!0,"aria-label":"Copy contract ID",className:"ml-2",onClick:()=>{navigator.clipboard.writeText(e.contract_id),j().fire({icon:"success",title:"Copied!",text:"Contract ID copied successfully!",toast:!0,position:"top-end",showConfirmButton:!1,timer:3e3})},children:(0,s.jsx)(g.Z,{size:16})})]})]})]}),(0,s.jsxs)("div",{className:"grid grid-cols-2 gap-2 mt-4 p-4 bg-gradient-to-r from-gray-100 to-gray-200 dark:from-gray-800 dark:to-gray-900 rounded-b-lg",children:[(0,s.jsx)(k.default,{href:"/dashboard/metadata/".concat(e.contract_id,"/normal"),target:"_blank",className:"col-span-1",children:(0,s.jsx)(i.A,{size:"sm",color:"primary",variant:"shadow",startContent:(0,s.jsx)(x.Z,{size:16}),className:"transition-all duration-300 hover:scale-105 w-full bg-blue-500 hover:bg-blue-600 text-white",children:"Update Metadata"})}),(0,s.jsx)(k.default,{href:"/dashboard/listing/".concat(e.contract_id),target:"_blank",className:"col-span-1",children:(0,s.jsx)(i.A,{size:"sm",color:"secondary",variant:"shadow",startContent:(0,s.jsx)(f.Z,{size:16}),className:"transition-all duration-300 hover:scale-105 w-full bg-purple-500 hover:bg-purple-600 text-white",children:"Listing"})}),(0,s.jsx)(k.default,{href:"/dashboard/airdrop/".concat(e.contract_id),target:"_blank",className:"col-span-1",children:(0,s.jsx)(i.A,{size:"sm",color:"success",variant:"shadow",startContent:(0,s.jsx)(m.Z,{size:16}),className:"transition-all duration-300 hover:scale-105 w-full bg-green-500 hover:bg-green-600 text-white",children:"Airdrop"})}),(0,s.jsx)(k.default,{href:"/dashboard/burn/".concat(e.contract_id),target:"_blank",className:"col-span-1",children:(0,s.jsx)(i.A,{size:"sm",color:"danger",variant:"shadow",startContent:(0,s.jsx)(u.Z,{size:16}),className:"transition-all duration-300 hover:scale-105 w-full bg-red-500 hover:bg-red-600 text-white",children:"Burn"})})]})]},t))})]})]})}),(0,s.jsx)(d.$,{})]})]})}},21307:function(e,t,a){"use strict";var s=a(57437);a(2265);var r=a(26748),n=a(86331),l=a(6803);t.Z=e=>{let{message:t="Please connect your wallet to use this feature!"}=e,{handleLogIn:a}=(0,l.Z)();return(0,s.jsx)("div",{className:"rounded-lg bg-white shadow-card dark:bg-light-dark mt-10 mx-10",children:(0,s.jsxs)("div",{className:"p-4 md:p-6 gap-4 flex flex-col items-center justify-center min-h-[250px]",children:[(0,s.jsx)(r.Z,{className:"text-blue-500",size:40}),(0,s.jsx)("div",{className:"text-base md:text-lg text-blue-500 text-center",children:t}),(0,s.jsx)(n.A,{className:"mt-4 relative items-center justify-center overflow-hidden text-center text-xs font-medium outline-none transition-all sm:text-sm bg-brand border-brand hover:-translate-y-0.5 focus:-translate-y-0.5 focus:outline-none text-white rounded-full h-8 md:h-10",onClick:a,children:"Connect Wallet"})]})})}}},function(e){e.O(0,[9461,8635,6242,4007,8955,9318,4426,3335,5227,6331,8468,4243,6047,8704,3326,7997,894,6821,3761,2971,2117,1744],function(){return e(e.s=32256)}),_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.