1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,66790,19455,e=>{"use strict";let t,r;var n=e.i(9735),a=e.i(7744);e.i(35910);var s=e.i(92615),o=e.i(87642),i=e.i(4849),l=e.i(65455),d=e.i(62902);let c=a.createContext(void 0);function u(e){return(0,s.isHTMLElement)(e)&&"BUTTON"===e.tagName}var h=e.i(81263);let x=a.forwardRef(function(e,t){let{render:r,className:n,disabled:s=!1,focusableWhenDisabled:x=!1,nativeButton:m=!0,...p}=e,{getButtonProps:f,buttonRef:v}=function(e={}){let{disabled:t=!1,focusableWhenDisabled:r,tabIndex:n=0,native:s=!0,composite:h}=e,x=a.useRef(null),m=function(e=!1){let t=a.useContext(c);if(void 0===t&&!e)throw Error((0,d.default)(16));return t}(!0),p=h??void 0!==m,{props:f}=function(e){let{focusableWhenDisabled:t,disabled:r,composite:n=!1,tabIndex:s=0,isNativeButton:o}=e,i=n&&!1!==t,l=n&&!1===t;return{props:a.useMemo(()=>{let e={onKeyDown(e){r&&t&&"Tab"!==e.key&&e.preventDefault()}};return n||(e.tabIndex=s,!o&&r&&(e.tabIndex=t?s:-1)),(o&&(t||i)||!o&&r)&&(e["aria-disabled"]=r),o&&(!t||l)&&(e.disabled=r),e},[n,r,t,i,l,o,s])}}({focusableWhenDisabled:r,disabled:t,composite:p,tabIndex:n,isNativeButton:s}),v=a.useCallback(()=>{let e=x.current;u(e)&&p&&t&&void 0===f.disabled&&e.disabled&&(e.disabled=!1)},[t,f.disabled,p]);return(0,i.useIsoLayoutEffect)(v,[v]),{getButtonProps:a.useCallback((e={})=>{let{onClick:r,onMouseDown:n,onKeyUp:a,onKeyDown:o,onPointerDown:i,...d}=e,c=s?"button":void 0;return(0,l.mergeProps)({type:c,onClick(e){t?e.preventDefault():r?.(e)},onMouseDown(e){t||n?.(e)},onKeyDown(e){var n;if(t||((0,l.makeEventPreventable)(e),o?.(e),e.baseUIHandlerPrevented))return;let a=e.target===e.currentTarget,i=e.currentTarget,d=u(i),c=!s&&(n=i,!!(n?.tagName==="A"&&n?.href)),h=a&&(s?d:!c),x="Enter"===e.key,m=" "===e.key,f=i.getAttribute("role"),v=f?.startsWith("menuitem")||"option"===f||"gridcell"===f;if(a&&p&&m){if(e.defaultPrevented&&v)return;e.preventDefault(),c||s&&d?(i.click(),e.preventBaseUIHandler()):h&&(r?.(e),e.preventBaseUIHandler());return}h&&(!s&&(m||x)&&e.preventDefault(),!s&&x&&r?.(e))},onKeyUp(e){t||(((0,l.makeEventPreventable)(e),a?.(e),e.target===e.currentTarget&&s&&p&&u(e.currentTarget)&&" "===e.key)?e.preventDefault():!e.baseUIHandlerPrevented&&(e.target!==e.currentTarget||s||p||" "!==e.key||r?.(e)))},onPointerDown(e){t?e.preventDefault():i?.(e)}},s?void 0:{role:"button"},f,d)},[t,f,p,s]),buttonRef:(0,o.useStableCallback)(e=>{x.current=e,v()})}}({disabled:s,focusableWhenDisabled:x,native:m});return(0,h.useRenderElement)("button",e,{state:{disabled:s},ref:[t,v],props:[p,f]})});var m=e.i(7284);let p=e=>"boolean"==typeof e?`${e}`:0===e?"0":e,f=m.clsx;var v=e.i(75157);let g=(t="group/button inline-flex shrink-0 items-center justify-center rounded-lg border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",r={variants:{variant:{default:"bg-primary text-primary-foreground [a]:hover:bg-primary/80",outline:"border-border bg-background hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80 aria-expanded:bg-secondary aria-expanded:text-secondary-foreground",ghost:"hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50",destructive:"bg-destructive/10 text-destructive hover:bg-destructive/20 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:hover:bg-destructive/30 dark:focus-visible:ring-destructive/40",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-8 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",xs:"h-6 gap-1 rounded-[min(var(--radius-md),10px)] px-2 text-xs in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3",sm:"h-7 gap-1 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5",lg:"h-9 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",icon:"size-8","icon-xs":"size-6 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-lg [&_svg:not([class*='size-'])]:size-3","icon-sm":"size-7 rounded-[min(var(--radius-md),12px)] in-data-[slot=button-group]:rounded-lg","icon-lg":"size-9"}},defaultVariants:{variant:"default",size:"default"}},e=>{var n;if((null==r?void 0:r.variants)==null)return f(t,null==e?void 0:e.class,null==e?void 0:e.className);let{variants:a,defaultVariants:s}=r,o=Object.keys(a).map(t=>{let r=null==e?void 0:e[t],n=null==s?void 0:s[t];if(null===r)return null;let o=p(r)||p(n);return a[t][o]}),i=e&&Object.entries(e).reduce((e,t)=>
1{let[r,n]=t;return void 0===n||(e[r]=n),e},{});return f(t,o,null==r||null==(n=r.compoundVariants)?void 0:n.reduce((e,t)=>{let{class:r,className:n,...a}=t;return Object.entries(a).every(e=>{let[t,r]=e;return Array.isArray(r)?r.includes({...s,...i}[t]):({...s,...i})[t]===r})?[...e,r,n]:e},[]),null==e?void 0:e.class,null==e?void 0:e.className)});function b({className:e,variant:t="default",size:r="default",...a}){return(0,n.jsx)(x,{"data-slot":"button",className:(0,v.cn)(g({variant:t,size:r,className:e})),...a})}e.s(["Button",0,b],19455),e.s(["CopyButton",0,function({value:e,label:t,className:r}){let[s,o]=(0,a.useState)(!1),i=(0,a.useCallback)(async()=>{try{await navigator.clipboard.writeText(e),o(!0),setTimeout(()=>o(!1),1500)}catch{let t=document.createElement("textarea");t.value=e,t.style.position="fixed",t.style.opacity="0",document.body.appendChild(t),t.select(),document.execCommand("copy"),document.body.removeChild(t),o(!0),setTimeout(()=>o(!1),1500)}},[e]);return(0,n.jsxs)(b,{variant:"ghost",size:"xs",className:r,onClick:i,title:s?"å·²å¤å¶":`å¤å¶ ${e}`,children:[(0,n.jsx)("span",{className:"font-mono",children:t??e}),s?(0,n.jsx)("svg",{className:"size-3 text-emerald-500",viewBox:"0 0 16 16",fill:"currentColor",children:(0,n.jsx)("path",{d:"M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.75.75 0 0 1 1.06-1.06L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"})}):(0,n.jsxs)("svg",{className:"size-3 text-muted-foreground",viewBox:"0 0 16 16",fill:"currentColor",children:[(0,n.jsx)("path",{d:"M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"}),(0,n.jsx)("path",{d:"M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"})]})]})}],66790)},95858,57983,e=>{"use strict";var t=e.i(9735),r=e.i(7744);e.s(["LoadMoreTrigger",0,function({hasMore:e,loading:n,onLoadMore:a}){let s=(0,r.useRef)(null),o=(0,r.useRef)(n),i=(0,r.useRef)(a),[l,d]=(0,r.useState)(!1);return((0,r.useEffect)(()=>{o.current=n,i.current=a}),(0,r.useEffect)(()=>{if(!l)return;let t=s.current;if(!t||!e)return;let r=new IntersectionObserver(([e])=>{e.isIntersecting&&!o.current&&i.current()},{rootMargin:"200px"});return r.observe(t),()=>r.disconnect()},[l,e]),e)?(0,t.jsx)("div",{ref:s,className:"flex justify-center py-4",children:l?n&&(0,t.jsx)("span",{className:"text-sm text-muted-foreground",children:"å è½½ä¸..."}):(0,t.jsx)("button",{type:"button",onClick:()=>{n||(d(!0),a())},disabled:n,className:"rounded-md border border-border/60 bg-card px-4 py-2 text-sm text-muted-foreground transition-colors hover:bg-accent hover:text-foreground disabled:cursor-not-allowed disabled:opacity-60",children:n?"å è½½ä¸...":"å è½½æ´å¤"})}):null}],95858),e.s(["PendingBanner",0,function({count:e,label:r="æ¡æ°æ¶æ¯",onFlush:n}){return 0===e?null:(0,t.jsx)("div",{className:"fixed left-1/2 top-20 z-50 -translate-x-1/2",children:(0,t.jsxs)("button",{onClick:n,className:"rounded-full bg-[var(--brand-primary)] px-5 py-2 text-sm font-medium text-white shadow-lg transition-all hover:bg-[var(--brand-primary-hover)] hover:shadow-xl",children:[e," ",r]})})}],57983)},95218,e=>{"use strict";var t=e.i(9735),r=e.i(7665),n=e.i(7744),a=e.i(66790),s=e.i(95858),o=e.i(57983);function i(e){return!e||e.length<12?e:`${e.slice(0,6)}...${e.slice(-4)}`}let l=Math.floor(Date.now()/1e3),d=new Set,c=null;function u(e){return d.add(e),c||(c=setInterval(()=>{for(let e of(l=Math.floor(Date.now()/1e3),d))e()},1e3)),()=>{d.delete(e),0===d.size&&c&&(clearInterval(c),c=null)}}function h(){return l}function x(){return 0}let m={Ethereum:"https://etherscan.io/tx/",Base:"https://basescan.org/tx/","BNB Chain":"https://bscscan.com/tx/",Polygon:"https://polygonscan.com/tx/","Arbitrum One":"https://arbiscan.io/tx/",Optimism:"https://optimistic.etherscan.io/tx/","Avalanche C-Chain":"https://snowtrace.io/tx/",Fantom:"https://ftmscan.com/tx/",Cronos:"https://cronoscan.com/tx/","zkSync Era":"https://explorer.zksync.io/tx/",Linea:"https://lineascan.build/tx/",Scroll:"https://scrollscan.com/tx/",Mantle:"https://mantlescan.xyz/tx/",Blast:"https://blastscan.io/tx/",Solana:"https://solscan.io/tx/",TRON:"https://tronscan.org/#/transaction/",Bitcoin:"https://mempool.space/tx/"};function p(e,t){let r=m[e];return r?`${r}${t}`:null}function f({transfer:e,isNew:s}){var o,l,d,c;
1let m,v=(0,n.useRef)(null),g=(0,n.useSyncExternalStore)(u,h,x);return(0,n.useEffect)(()=>{if(s&&v.current){v.current.classList.add("whale-row-flash");let e=setTimeout(()=>{v.current?.classList.remove("whale-row-flash")},1500);return()=>clearTimeout(e)}},[s]),(0,t.jsxs)("tr",{ref:v,className:"border-b border-border/30 transition-colors hover:bg-accent/50",children:[(0,t.jsx)("td",{className:"whitespace-nowrap px-3 py-2.5 text-xs text-muted-foreground",suppressHydrationWarning:!0,children:(m=g-e.timestamp)<60?`${m}ç§å`:m<3600?`${Math.floor(m/60)}åéå`:m<86400?`${Math.floor(m/3600)}å°æ¶å`:`${Math.floor(m/86400)}天å`}),(0,t.jsx)("td",{className:"px-3 py-2.5",children:(0,t.jsxs)("div",{className:"flex items-center gap-1.5",children:[e.chainLogo&&(0,t.jsx)(r.default,{src:e.chainLogo,alt:e.chain,width:16,height:16,unoptimized:!0,className:"size-4 rounded-full",loading:"lazy"}),(0,t.jsx)("span",{className:"text-sm",children:e.chain})]})}),(0,t.jsx)("td",{className:"px-3 py-2.5",children:(0,t.jsxs)("div",{className:"flex items-center gap-1.5",children:[e.tokenLogo&&(0,t.jsx)(r.default,{src:e.tokenLogo,alt:e.tokenSymbol,width:16,height:16,unoptimized:!0,className:"size-4 rounded-full",loading:"lazy"}),(0,t.jsx)("span",{className:"font-mono text-sm text-muted-foreground",children:(o=e.value,l=e.tokenSymbol,o>=1e6?`${(o/1e6).toFixed(2)}M ${l}`:o>=1e3?`${(o/1e3).toFixed(2)}K ${l}`:`${o.toFixed(2)} ${l}`)})]})}),(0,t.jsx)("td",{className:`whitespace-nowrap px-3 py-2.5 font-mono text-sm font-semibold ${(d=e.valueUsd)>=1e8?"text-red-600 dark:text-red-400":d>=1e7?"text-amber-600 dark:text-amber-400":"text-foreground"}`,children:(c=e.valueUsd)>=1e9?`$${(c/1e9).toFixed(2)}B`:c>=1e6?`$${(c/1e6).toFixed(2)}M`:c>=1e3?`$${(c/1e3).toFixed(0)}K`:`$${c.toFixed(0)}`}),(0,t.jsx)("td",{className:"hidden px-3 py-2.5 md:table-cell",children:e.fromAddress&&(0,t.jsx)(a.CopyButton,{value:e.fromAddress,label:i(e.fromAddress),className:"text-xs text-muted-foreground"})}),(0,t.jsx)("td",{className:"hidden px-3 py-2.5 md:table-cell",children:e.toAddress&&(0,t.jsx)(a.CopyButton,{value:e.toAddress,label:i(e.toAddress),className:"text-xs text-muted-foreground"})}),(0,t.jsx)("td",{className:"px-3 py-2.5",children:e.txHash&&(0,t.jsxs)("div",{className:"flex items-center gap-0.5",children:[(0,t.jsx)(a.CopyButton,{value:e.txHash,label:e.txHash.slice(0,8)+"...",className:"text-xs text-muted-foreground"}),p(e.chain,e.txHash)&&(0,t.jsx)("a",{href:p(e.chain,e.txHash),target:"_blank",rel:"noopener noreferrer nofollow",className:"inline-flex size-6 items-center justify-center rounded text-muted-foreground transition-colors hover:bg-accent hover:text-foreground",title:"å¨åºåæµè§å¨ä¸æ¥ç",children:(0,t.jsx)("svg",{className:"size-3",viewBox:"0 0 16 16",fill:"currentColor",children:(0,t.jsx)("path",{d:"M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-.22a.75.75 0 0 1 .396-.03h3.25a.75.75 0 0 1 .75.75v3.25a.75.75 0 0 1-1.5 0V4.56l-5.22 5.22a.75.75 0 0 1-1.06-1.06l5.22-5.22H10.5a.75.75 0 0 1 0-1.5h.104Z"})})})]})})]})}e.s(["WhaleAlertList",0,function({initialData:e}){let{transfers:r,loading:a,hasMore:i,loadMore:l,newIds:d,pendingCount:c,flushPending:u}=function(e){let[t,r]=(0,n.useState)(e?.items??[]),[a,s]=(0,n.useState)(e?.total??0),[o,i]=(0,n.useState)(!1),[l,d]=(0,n.useState)(null),[c,u]=(0,n.use
1State)(new Set),[h,x]=(0,n.useState)([]),m=(0,n.useRef)(new Set(e?.items.map(e=>e.id)??[])),p=(0,n.useRef)(e?.items.length??0),f=(0,n.useRef)(!0),v=(0,n.useRef)(h);v.current=h;let g=(0,n.useRef)(e),b=(0,n.useCallback)(e=>{r(t=>[...e,...t]),p.current+=e.length,u(new Set(e.map(e=>e.id))),setTimeout(()=>u(new Set),1500),x([])},[]);(0,n.useEffect)(()=>{function e(){let e=window.scrollY<100;f.current=e,e&&v.current.length>0&&b(v.current)}return window.addEventListener("scroll",e,{passive:!0}),()=>window.removeEventListener("scroll",e)},[b]),(0,n.useEffect)(()=>{let e=null;async function t(){try{let e=await fetch("/api/whalealert/recent?limit=50&offset=0",{cache:"no-store"});if(!e.ok)throw Error(`HTTP ${e.status}`);let t=await e.json(),r=t.items.filter(e=>!m.current.has(e.id));for(let e of t.items)m.current.add(e.id);r.length>0&&(f.current?b(r):x(e=>[...r,...e])),s(t.total),d(null)}catch(e){d(e instanceof Error?e.message:"å 载失败")}}return async function(){if(g.current)await t();else{i(!0);try{let e=await fetch("/api/whalealert/recent?limit=50&offset=0",{cache:"no-store"});if(!e.ok)throw Error(`HTTP ${e.status}`);let t=await e.json();for(let e of t.items)m.current.add(e.id);r(t.items),s(t.total),p.current=t.items.length}catch(e){d(e instanceof Error?e.message:"å 载失败")}finally{i(!1)}}e=setInterval(t,3e4)}(),()=>{e&&clearInterval(e)}},[b]);let y=(0,n.useCallback)(()=>{0!==h.length&&(b(h),window.scrollTo({top:0,behavior:"smooth"}))},[h,b]),w=(0,n.useCallback)(async()=>{if(!o){i(!0);try{let e=await fetch(`/api/whalealert/recent?limit=50&offset=${p.current}`,{cache:"no-store"});if(!e.ok)throw Error(`HTTP ${e.status}`);let t=await e.json(),n=t.items.filter(e=>!m.current.has(e.id));for(let e of n)m.current.add(e.id);r(e=>[...e,...n]),s(t.total),p.current+=t.items.length}catch(e){d(e instanceof Error?e.message:"å 载失败")}finally{i(!1)}}},[o]),j=t.length<a;return{transfers:t,loading:o,error:l,hasMore:j,loadMore:w,newIds:c,pendingCount:h.length,flushPending:y}}(e);return(0,t.jsxs)("div",{className:"space-y-3",children:[(0,t.jsx)(o.PendingBanner,{count:c,label:"æ¡æ°è½¬è´¦",onFlush:u}),(0,t.jsx)("div",{className:"overflow-x-auto overflow-hidden rounded-lg card-surface",children:(0,t.jsxs)("table",{className:"w-full text-left",children:[(0,t.jsx)("thead",{children:(0,t.jsxs)("tr",{className:"border-b border-border/40 bg-muted/60 text-xs font-medium uppercase tracking-wider text-muted-foreground",children:[(0,t.jsx)("th",{className:"px-3 py-2.5",children:"æ¶é´"}),(0,t.jsx)("th",{className:"px-3 py-2.5",children:"é¾"}),(0,t.jsx)("th",{className:"px-3 py-2.5",children:"ä»£å¸ / æ°é"}),(0,t.jsx)("th",{className:"px-3 py-2.5",children:"USD"}),(0,t.jsx)("th",{className:"hidden px-3 py-2.5 md:table-cell",children:"åéæ¹"}),(0,t.jsx)("th",{className:"hidden px-3 py-2.5 md:table-cell",children:"æ¥æ¶æ¹"}),(0,t.jsx)("th",{className:"px-3 py-2.5",children:"交æ"})]})}),(0,t.jsx)("tbody",{children:0===r.length&&a?(0,t.jsx)("tr",{children:(0,t.jsx)("td",{colSpan:7,className:"px-3 py-12 text-center text-sm text-muted-foreground",children:"å è½½ä¸..."})}):0===r.length?(0,t.jsx)("tr",{children:(0,t.jsx)("td",{colSpan:7,className:"px-3 py-12 text-center text-sm text-muted-foreground",children:"ææ æ°æ®"})}):r.map(e=>(0,t.jsx)(f,{transfer:e,isNew:d.has(e.id)},e.id))})]})}),(0,t.jsx)(s.LoadMoreTrigger,{hasMore:i,loading:a,onLoadMore:l})]})}],95218)}]);
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.