tokentracker-cli 0.5.22 → 0.5.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/DashboardPage-7poMJy2s.js","assets/ThemeToggle-COuzMnU0.js","assets/LeaderboardPage-DYHGsG7D.js","assets/leaderboard-columns-BEPark-B.js","assets/LeaderboardProfilePage-RjYL1DAT.js"])))=>i.map(i=>d[i]);
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/DashboardPage-vIxKP44Z.js","assets/ThemeToggle-8m6pW0Kd.js","assets/LeaderboardPage-VXJBiwkB.js","assets/leaderboard-columns-BtZZjmrK.js","assets/LeaderboardProfilePage-DPeOBsNk.js"])))=>i.map(i=>d[i]);
2
2
  function s2(t,e){for(var n=0;n<e.length;n++){const i=e[n];if(typeof i!="string"&&!Array.isArray(i)){for(const r in i)if(r!=="default"&&!(r in t)){const s=Object.getOwnPropertyDescriptor(i,r);s&&Object.defineProperty(t,r,s.get?s:{enumerable:!0,get:()=>i[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const r of document.querySelectorAll('link[rel="modulepreload"]'))i(r);new MutationObserver(r=>{for(const s of r)if(s.type==="childList")for(const o of s.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&i(o)}).observe(document,{childList:!0,subtree:!0});function n(r){const s={};return r.integrity&&(s.integrity=r.integrity),r.referrerPolicy&&(s.referrerPolicy=r.referrerPolicy),r.crossOrigin==="use-credentials"?s.credentials="include":r.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function i(r){if(r.ep)return;r.ep=!0;const s=n(r);fetch(r.href,s)}})();function D1(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function a2(t){if(Object.prototype.hasOwnProperty.call(t,"__esModule"))return t;var e=t.default;if(typeof e=="function"){var n=function i(){var r=!1;try{r=this instanceof i}catch{}return r?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};n.prototype=e.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(t).forEach(function(i){var r=Object.getOwnPropertyDescriptor(t,i);Object.defineProperty(n,i,r.get?r:{enumerable:!0,get:function(){return t[i]}})}),n}var _m={exports:{}},Lc={},xm={exports:{}},Jt={};var wb;function o2(){if(wb)return Jt;wb=1;var t=Symbol.for("react.element"),e=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),r=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),o=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),f=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),p=Symbol.iterator;function m(B){return B===null||typeof B!="object"?null:(B=p&&B[p]||B["@@iterator"],typeof B=="function"?B:null)}var v={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},_=Object.assign,w={};function y(B,ie,ve){this.props=B,this.context=ie,this.refs=w,this.updater=ve||v}y.prototype.isReactComponent={},y.prototype.setState=function(B,ie){if(typeof B!="object"&&typeof B!="function"&&B!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,B,ie,"setState")},y.prototype.forceUpdate=function(B){this.updater.enqueueForceUpdate(this,B,"forceUpdate")};function x(){}x.prototype=y.prototype;function M(B,ie,ve){this.props=B,this.context=ie,this.refs=w,this.updater=ve||v}var A=M.prototype=new x;A.constructor=M,_(A,y.prototype),A.isPureReactComponent=!0;var T=Array.isArray,D=Object.prototype.hasOwnProperty,I={current:null},U={key:!0,ref:!0,__self:!0,__source:!0};function S(B,ie,ve){var Ce,we={},ne=null,_e=null;if(ie!=null)for(Ce in ie.ref!==void 0&&(_e=ie.ref),ie.key!==void 0&&(ne=""+ie.key),ie)D.call(ie,Ce)&&!U.hasOwnProperty(Ce)&&(we[Ce]=ie[Ce]);var Se=arguments.length-2;if(Se===1)we.children=ve;else if(1<Se){for(var Ie=Array(Se),et=0;et<Se;et++)Ie[et]=arguments[et+2];we.children=Ie}if(B&&B.defaultProps)for(Ce in Se=B.defaultProps,Se)we[Ce]===void 0&&(we[Ce]=Se[Ce]);return{$$typeof:t,type:B,key:ne,ref:_e,props:we,_owner:I.current}}function R(B,ie){return{$$typeof:t,type:B.type,key:ie,ref:B.ref,props:B.props,_owner:B._owner}}function V(B){return typeof B=="object"&&B!==null&&B.$$typeof===t}function F(B){var ie={"=":"=0",":":"=2"};return"$"+B.replace(/[=:]/g,function(ve){return ie[ve]})}var j=/\/+/g;function Z(B,ie){return typeof B=="object"&&B!==null&&B.key!=null?F(""+B.key):ie.toString(36)}function H(B,ie,ve,Ce,we){var ne=typeof B;(ne==="undefined"||ne==="boolean")&&(B=null);var _e=!1;if(B===null)_e=!0;else switch(ne){case"string":case"number":_e=!0;break;case"object":switch(B.$$typeof){case t:case e:_e=!0}}if(_e)return _e=B,we=we(_e),B=Ce===""?"."+Z(_e,0):Ce,T(we)?(ve="",B!=null&&(ve=B.replace(j,"$&/")+"/"),H(we,ie,ve,"",function(et){return et})):we!=null&&(V(we)&&(we=R(we,ve+(!we.key||_e&&_e.key===we.key?"":(""+we.key).replace(j,"$&/")+"/")+B)),ie.push(we)),1;if(_e=0,Ce=Ce===""?".":Ce+":",T(B))for(var Se=0;Se<B.length;Se++){ne=B[Se];var Ie=Ce+Z(ne,Se);_e+=H(ne,ie,ve,Ie,we)}else if(Ie=m(B),typeof Ie=="function")for(B=Ie.call(B),Se=0;!(ne=B.next()).done;)ne=ne.value,Ie=Ce+Z(ne,Se++),_e+=H(ne,ie,ve,Ie,we);else if(ne==="object")throw ie=String(B),Error("Objects are not valid as a React child (found: "+(ie==="[object Object]"?"object with keys {"+Object.keys(B).join(", ")+"}":ie)+"). If you meant to render a collection of children, use an array instead.");return _e}function q(B,ie,ve){if(B==null)return B;var Ce=[],we=0;return H(B,Ce,"","",function(ne){return ie.call(ve,ne,we++)}),Ce}function J(B){if(B._status===-1){var ie=B._result;ie=ie(),ie.then(function(ve){(B._status===0||B._status===-1)&&(B._status=1,B._result=ve)},function(ve){(B._status===0||B._status===-1)&&(B._status=2,B._result=ve)}),B._status===-1&&(B._status=0,B._result=ie)}if(B._status===1)return B._result.default;throw B._result}var Q={current:null},W={transition:null},X={ReactCurrentDispatcher:Q,ReactCurrentBatchConfig:W,ReactCurrentOwner:I};function K(){throw Error("act(...) is not supported in production builds of React.")}return Jt.Children={map:q,forEach:function(B,ie,ve){q(B,function(){ie.apply(this,arguments)},ve)},count:function(B){var ie=0;return q(B,function(){ie++}),ie},toArray:function(B){return q(B,function(ie){return ie})||[]},only:function(B){if(!V(B))throw Error("React.Children.only expected to receive a single React element child.");return B}},Jt.Component=y,Jt.Fragment=n,Jt.Profiler=r,Jt.PureComponent=M,Jt.StrictMode=i,Jt.Suspense=u,Jt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=X,Jt.act=K,Jt.cloneElement=function(B,ie,ve){if(B==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+B+".");var Ce=_({},B.props),we=B.key,ne=B.ref,_e=B._owner;if(ie!=null){if(ie.ref!==void 0&&(ne=ie.ref,_e=I.current),ie.key!==void 0&&(we=""+ie.key),B.type&&B.type.defaultProps)var Se=B.type.defaultProps;for(Ie in ie)D.call(ie,Ie)&&!U.hasOwnProperty(Ie)&&(Ce[Ie]=ie[Ie]===void 0&&Se!==void 0?Se[Ie]:ie[Ie])}var Ie=arguments.length-2;if(Ie===1)Ce.children=ve;else if(1<Ie){Se=Array(Ie);for(var et=0;et<Ie;et++)Se[et]=arguments[et+2];Ce.children=Se}return{$$typeof:t,type:B.type,key:we,ref:ne,props:Ce,_owner:_e}},Jt.createContext=function(B){return B={$$typeof:o,_currentValue:B,_currentValue2:B,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},B.Provider={$$typeof:s,_context:B},B.Consumer=B},Jt.createElement=S,Jt.createFactory=function(B){var ie=S.bind(null,B);return ie.type=B,ie},Jt.createRef=function(){return{current:null}},Jt.forwardRef=function(B){return{$$typeof:c,render:B}},Jt.isValidElement=V,Jt.lazy=function(B){return{$$typeof:h,_payload:{_status:-1,_result:B},_init:J}},Jt.memo=function(B,ie){return{$$typeof:f,type:B,compare:ie===void 0?null:ie}},Jt.startTransition=function(B){var ie=W.transition;W.transition={};try{B()}finally{W.transition=ie}},Jt.unstable_act=K,Jt.useCallback=function(B,ie){return Q.current.useCallback(B,ie)},Jt.useContext=function(B){return Q.current.useContext(B)},Jt.useDebugValue=function(){},Jt.useDeferredValue=function(B){return Q.current.useDeferredValue(B)},Jt.useEffect=function(B,ie){return Q.current.useEffect(B,ie)},Jt.useId=function(){return Q.current.useId()},Jt.useImperativeHandle=function(B,ie,ve){return Q.current.useImperativeHandle(B,ie,ve)},Jt.useInsertionEffect=function(B,ie){return Q.current.useInsertionEffect(B,ie)},Jt.useLayoutEffect=function(B,ie){return Q.current.useLayoutEffect(B,ie)},Jt.useMemo=function(B,ie){return Q.current.useMemo(B,ie)},Jt.useReducer=function(B,ie,ve){return Q.current.useReducer(B,ie,ve)},Jt.useRef=function(B){return Q.current.useRef(B)},Jt.useState=function(B){return Q.current.useState(B)},Jt.useSyncExternalStore=function(B,ie,ve){return Q.current.useSyncExternalStore(B,ie,ve)},Jt.useTransition=function(){return Q.current.useTransition()},Jt.version="18.3.1",Jt}var Eb;function Nv(){return Eb||(Eb=1,xm.exports=o2()),xm.exports}var Mb;function l2(){if(Mb)return Lc;Mb=1;var t=Nv(),e=Symbol.for("react.element"),n=Symbol.for("react.fragment"),i=Object.prototype.hasOwnProperty,r=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s={key:!0,ref:!0,__self:!0,__source:!0};function o(c,u,f){var h,p={},m=null,v=null;f!==void 0&&(m=""+f),u.key!==void 0&&(m=""+u.key),u.ref!==void 0&&(v=u.ref);for(h in u)i.call(u,h)&&!s.hasOwnProperty(h)&&(p[h]=u[h]);if(c&&c.defaultProps)for(h in u=c.defaultProps,u)p[h]===void 0&&(p[h]=u[h]);return{$$typeof:e,type:c,key:m,ref:v,props:p,_owner:r.current}}return Lc.Fragment=n,Lc.jsx=o,Lc.jsxs=o,Lc}var Tb;function c2(){return Tb||(Tb=1,_m.exports=l2()),_m.exports}var O=c2(),k=Nv();const jl=D1(k),N1=s2({__proto__:null,default:jl},[k]);var Id={},bm={exports:{}},Vi={},Sm={exports:{}},wm={};var Ab;function u2(){return Ab||(Ab=1,(function(t){function e(W,X){var K=W.length;W.push(X);e:for(;0<K;){var B=K-1>>>1,ie=W[B];if(0<r(ie,X))W[B]=X,W[K]=ie,K=B;else break e}}function n(W){return W.length===0?null:W[0]}function i(W){if(W.length===0)return null;var X=W[0],K=W.pop();if(K!==X){W[0]=K;e:for(var B=0,ie=W.length,ve=ie>>>1;B<ve;){var Ce=2*(B+1)-1,we=W[Ce],ne=Ce+1,_e=W[ne];if(0>r(we,K))ne<ie&&0>r(_e,we)?(W[B]=_e,W[ne]=K,B=ne):(W[B]=we,W[Ce]=K,B=Ce);else if(ne<ie&&0>r(_e,K))W[B]=_e,W[ne]=K,B=ne;else break e}}return X}function r(W,X){var K=W.sortIndex-X.sortIndex;return K!==0?K:W.id-X.id}if(typeof performance=="object"&&typeof performance.now=="function"){var s=performance;t.unstable_now=function(){return s.now()}}else{var o=Date,c=o.now();t.unstable_now=function(){return o.now()-c}}var u=[],f=[],h=1,p=null,m=3,v=!1,_=!1,w=!1,y=typeof setTimeout=="function"?setTimeout:null,x=typeof clearTimeout=="function"?clearTimeout:null,M=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function A(W){for(var X=n(f);X!==null;){if(X.callback===null)i(f);else if(X.startTime<=W)i(f),X.sortIndex=X.expirationTime,e(u,X);else break;X=n(f)}}function T(W){if(w=!1,A(W),!_)if(n(u)!==null)_=!0,J(D);else{var X=n(f);X!==null&&Q(T,X.startTime-W)}}function D(W,X){_=!1,w&&(w=!1,x(S),S=-1),v=!0;var K=m;try{for(A(X),p=n(u);p!==null&&(!(p.expirationTime>X)||W&&!F());){var B=p.callback;if(typeof B=="function"){p.callback=null,m=p.priorityLevel;var ie=B(p.expirationTime<=X);X=t.unstable_now(),typeof ie=="function"?p.callback=ie:p===n(u)&&i(u),A(X)}else i(u);p=n(u)}if(p!==null)var ve=!0;else{var Ce=n(f);Ce!==null&&Q(T,Ce.startTime-X),ve=!1}return ve}finally{p=null,m=K,v=!1}}var I=!1,U=null,S=-1,R=5,V=-1;function F(){return!(t.unstable_now()-V<R)}function j(){if(U!==null){var W=t.unstable_now();V=W;var X=!0;try{X=U(!0,W)}finally{X?Z():(I=!1,U=null)}}else I=!1}var Z;if(typeof M=="function")Z=function(){M(j)};else if(typeof MessageChannel<"u"){var H=new MessageChannel,q=H.port2;H.port1.onmessage=j,Z=function(){q.postMessage(null)}}else Z=function(){y(j,0)};function J(W){U=W,I||(I=!0,Z())}function Q(W,X){S=y(function(){W(t.unstable_now())},X)}t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(W){W.callback=null},t.unstable_continueExecution=function(){_||v||(_=!0,J(D))},t.unstable_forceFrameRate=function(W){0>W||125<W?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):R=0<W?Math.floor(1e3/W):5},t.unstable_getCurrentPriorityLevel=function(){return m},t.unstable_getFirstCallbackNode=function(){return n(u)},t.unstable_next=function(W){switch(m){case 1:case 2:case 3:var X=3;break;default:X=m}var K=m;m=X;try{return W()}finally{m=K}},t.unstable_pauseExecution=function(){},t.unstable_requestPaint=function(){},t.unstable_runWithPriority=function(W,X){switch(W){case 1:case 2:case 3:case 4:case 5:break;default:W=3}var K=m;m=W;try{return X()}finally{m=K}},t.unstable_scheduleCallback=function(W,X,K){var B=t.unstable_now();switch(typeof K=="object"&&K!==null?(K=K.delay,K=typeof K=="number"&&0<K?B+K:B):K=B,W){case 1:var ie=-1;break;case 2:ie=250;break;case 5:ie=1073741823;break;case 4:ie=1e4;break;default:ie=5e3}return ie=K+ie,W={id:h++,callback:X,priorityLevel:W,startTime:K,expirationTime:ie,sortIndex:-1},K>B?(W.sortIndex=K,e(f,W),n(u)===null&&W===n(f)&&(w?(x(S),S=-1):w=!0,Q(T,K-B))):(W.sortIndex=ie,e(u,W),_||v||(_=!0,J(D))),W},t.unstable_shouldYield=F,t.unstable_wrapCallback=function(W){var X=m;return function(){var K=m;m=X;try{return W.apply(this,arguments)}finally{m=K}}}})(wm)),wm}var Cb;function d2(){return Cb||(Cb=1,Sm.exports=u2()),Sm.exports}var Rb;function f2(){if(Rb)return Vi;Rb=1;var t=Nv(),e=d2();function n(a){for(var l="https://reactjs.org/docs/error-decoder.html?invariant="+a,d=1;d<arguments.length;d++)l+="&args[]="+encodeURIComponent(arguments[d]);return"Minified React error #"+a+"; visit "+l+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var i=new Set,r={};function s(a,l){o(a,l),o(a+"Capture",l)}function o(a,l){for(r[a]=l,a=0;a<l.length;a++)i.add(l[a])}var c=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),u=Object.prototype.hasOwnProperty,f=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,h={},p={};function m(a){return u.call(p,a)?!0:u.call(h,a)?!1:f.test(a)?p[a]=!0:(h[a]=!0,!1)}function v(a,l,d,g){if(d!==null&&d.type===0)return!1;switch(typeof l){case"function":case"symbol":return!0;case"boolean":return g?!1:d!==null?!d.acceptsBooleans:(a=a.toLowerCase().slice(0,5),a!=="data-"&&a!=="aria-");default:return!1}}function _(a,l,d,g){if(l===null||typeof l>"u"||v(a,l,d,g))return!0;if(g)return!1;if(d!==null)switch(d.type){case 3:return!l;case 4:return l===!1;case 5:return isNaN(l);case 6:return isNaN(l)||1>l}return!1}function w(a,l,d,g,b,E,L){this.acceptsBooleans=l===2||l===3||l===4,this.attributeName=g,this.attributeNamespace=b,this.mustUseProperty=d,this.propertyName=a,this.type=l,this.sanitizeURL=E,this.removeEmptyString=L}var y={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(a){y[a]=new w(a,0,!1,a,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(a){var l=a[0];y[l]=new w(l,1,!1,a[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(a){y[a]=new w(a,2,!1,a.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(a){y[a]=new w(a,2,!1,a,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(a){y[a]=new w(a,3,!1,a.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(a){y[a]=new w(a,3,!0,a,null,!1,!1)}),["capture","download"].forEach(function(a){y[a]=new w(a,4,!1,a,null,!1,!1)}),["cols","rows","size","span"].forEach(function(a){y[a]=new w(a,6,!1,a,null,!1,!1)}),["rowSpan","start"].forEach(function(a){y[a]=new w(a,5,!1,a.toLowerCase(),null,!1,!1)});var x=/[\-:]([a-z])/g;function M(a){return a[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(a){var l=a.replace(x,M);y[l]=new w(l,1,!1,a,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(a){var l=a.replace(x,M);y[l]=new w(l,1,!1,a,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(a){var l=a.replace(x,M);y[l]=new w(l,1,!1,a,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(a){y[a]=new w(a,1,!1,a.toLowerCase(),null,!1,!1)}),y.xlinkHref=new w("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(a){y[a]=new w(a,1,!1,a.toLowerCase(),null,!0,!0)});function A(a,l,d,g){var b=y.hasOwnProperty(l)?y[l]:null;(b!==null?b.type!==0:g||!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(_(l,d,b,g)&&(d=null),g||b===null?m(l)&&(d===null?a.removeAttribute(l):a.setAttribute(l,""+d)):b.mustUseProperty?a[b.propertyName]=d===null?b.type===3?!1:"":d:(l=b.attributeName,g=b.attributeNamespace,d===null?a.removeAttribute(l):(b=b.type,d=b===3||b===4&&d===!0?"":""+d,g?a.setAttributeNS(g,l,d):a.setAttribute(l,d))))}var T=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,D=Symbol.for("react.element"),I=Symbol.for("react.portal"),U=Symbol.for("react.fragment"),S=Symbol.for("react.strict_mode"),R=Symbol.for("react.profiler"),V=Symbol.for("react.provider"),F=Symbol.for("react.context"),j=Symbol.for("react.forward_ref"),Z=Symbol.for("react.suspense"),H=Symbol.for("react.suspense_list"),q=Symbol.for("react.memo"),J=Symbol.for("react.lazy"),Q=Symbol.for("react.offscreen"),W=Symbol.iterator;function X(a){return a===null||typeof a!="object"?null:(a=W&&a[W]||a["@@iterator"],typeof a=="function"?a:null)}var K=Object.assign,B;function ie(a){if(B===void 0)try{throw Error()}catch(d){var l=d.stack.trim().match(/\n( *(at )?)/);B=l&&l[1]||""}return`
3
3
  `+B+a}var ve=!1;function Ce(a,l){if(!a||ve)return"";ve=!0;var d=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(l)if(l=function(){throw Error()},Object.defineProperty(l.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(l,[])}catch(ge){var g=ge}Reflect.construct(a,[],l)}else{try{l.call()}catch(ge){g=ge}a.call(l.prototype)}else{try{throw Error()}catch(ge){g=ge}a()}}catch(ge){if(ge&&g&&typeof ge.stack=="string"){for(var b=ge.stack.split(`
4
4
  `),E=g.stack.split(`
@@ -4860,4 +4860,4 @@ void main() {
4860
4860
  vec4 color;
4861
4861
  mainImage(color, gl_FragCoord.xy);
4862
4862
  gl_FragColor = color;
4863
- }`;function D7({raysOrigin:t="top-center",raysColor:e="#ffffff",raysSpeed:n=1,lightSpread:i=1,rayLength:r=2,pulsating:s=!1,fadeDistance:o=1,saturation:c=1,followMouse:u=!0,mouseInfluence:f=.1,noiseAmount:h=0,distortion:p=0,className:m=""}){const v=k.useRef(null),_=k.useRef(null),w=k.useRef(null),y=k.useRef({x:.5,y:.5}),x=k.useRef({x:.5,y:.5}),M=k.useRef(null),A=k.useRef(null),T=k.useRef(null),[D,I]=k.useState(!1),U=k.useRef(null);return k.useEffect(()=>{if(v.current)return U.current=new IntersectionObserver(S=>{I(S[0].isIntersecting)},{threshold:.1}),U.current.observe(v.current),()=>{U.current&&(U.current.disconnect(),U.current=null)}},[]),k.useEffect(()=>!D||!v.current?void 0:(T.current&&(T.current(),T.current=null),(async()=>{if(!v.current||(await new Promise(Q=>setTimeout(Q,10)),!v.current))return;const R=new kW({dpr:Math.min(window.devicePixelRatio,2),alpha:!0});w.current=R;const V=R.gl;for(V.canvas.style.width="100%",V.canvas.style.height="100%";v.current.firstChild;)v.current.removeChild(v.current.firstChild);v.current.appendChild(V.canvas);const F={iTime:{value:0},iResolution:{value:[1,1]},rayPos:{value:[0,0]},rayDir:{value:[0,1]},raysColor:{value:A1(e)},raysSpeed:{value:n},lightSpread:{value:i},rayLength:{value:r},pulsating:{value:s?1:0},fadeDistance:{value:o},saturation:{value:c},mousePos:{value:[.5,.5]},mouseInfluence:{value:f},noiseAmount:{value:h},distortion:{value:p}};_.current=F;const j=new P7(V),Z=new TW(V,{vertex:k7,fragment:L7,uniforms:F}),H=new R7(V,{geometry:j,program:Z});A.current=H;const q=()=>{if(!v.current||!R)return;R.dpr=Math.min(window.devicePixelRatio,2);const{clientWidth:Q,clientHeight:W}=v.current;R.setSize(Q,W);const X=R.dpr,K=Q*X,B=W*X;F.iResolution.value=[K,B];const{anchor:ie,dir:ve}=C1(t,K,B);F.rayPos.value=ie,F.rayDir.value=ve},J=Q=>{if(!(!w.current||!_.current||!A.current)){F.iTime.value=Q*.001,u&&f>0&&(x.current.x=x.current.x*.92+y.current.x*(1-.92),x.current.y=x.current.y*.92+y.current.y*(1-.92),F.mousePos.value=[x.current.x,x.current.y]);try{R.render({scene:H}),M.current=requestAnimationFrame(J)}catch(W){console.warn("WebGL rendering error:",W)}}};window.addEventListener("resize",q),q(),M.current=requestAnimationFrame(J),T.current=()=>{if(M.current&&(cancelAnimationFrame(M.current),M.current=null),window.removeEventListener("resize",q),R)try{const Q=R.gl.getExtension("WEBGL_lose_context");Q&&Q.loseContext();const W=R.gl.canvas;W&&W.parentNode&&W.parentNode.removeChild(W)}catch(Q){console.warn("Error during WebGL cleanup:",Q)}w.current=null,_.current=null,A.current=null}})(),()=>{T.current&&(T.current(),T.current=null)}),[D,t,e,n,i,r,s,o,c,u,f,h,p]),k.useEffect(()=>{if(!_.current||!v.current||!w.current)return;const S=_.current,R=w.current;S.raysColor.value=A1(e),S.raysSpeed.value=n,S.lightSpread.value=i,S.rayLength.value=r,S.pulsating.value=s?1:0,S.fadeDistance.value=o,S.saturation.value=c,S.mouseInfluence.value=f,S.noiseAmount.value=h,S.distortion.value=p;const{clientWidth:V,clientHeight:F}=v.current,j=R.dpr,{anchor:Z,dir:H}=C1(t,V*j,F*j);S.rayPos.value=Z,S.rayDir.value=H},[e,n,i,t,r,s,o,c,f,h,p]),k.useEffect(()=>{if(!u)return;const S=R=>{if(!v.current)return;const V=v.current.getBoundingClientRect();y.current={x:(R.clientX-V.left)/V.width,y:(R.clientY-V.top)/V.height}};return window.addEventListener("mousemove",S),()=>window.removeEventListener("mousemove",S)},[u]),O.jsx("div",{ref:v,className:`w-full h-full pointer-events-none z-[3] overflow-hidden relative ${m}`.trim()})}function N7({className:t}){return O.jsx("svg",{viewBox:"0 0 384 512",className:t,fill:"currentColor",children:O.jsx("path",{d:"M318.7 268.7c-.2-36.7 16.4-64.4 50-84.8-18.8-26.9-47.2-41.7-84.7-44.6-35.5-2.8-74.3 20.7-88.5 20.7-15 0-49.4-19.7-76.4-19.7C63.3 141.2 4 184.8 4 273.5q0 39.3 14.4 81.2c12.8 36.7 59 126.7 107.2 125.2 25.2-.6 43-17.9 75.8-17.9 31.8 0 48.3 17.9 76.4 17.9 48.6-.7 90.4-82.5 102.6-119.3-65.2-30.7-61.7-90-61.7-91.9zm-56.6-164.2c27.3-32.4 24.8-61.9 24-72.5-24.1 1.4-52 16.4-67.9 34.9-17.5 19.8-27.8 44.3-25.6 71.9 26.1 2 49.9-11.4 69.5-34.3z"})})}function I7({className:t}){return O.jsx("svg",{viewBox:"0 0 16 16",className:t,fill:"currentColor",children:O.jsx("path",{d:"M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"})})}function U7({className:t}){return O.jsxs("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:t,children:[O.jsx("rect",{x:"9",y:"9",width:"13",height:"13",rx:"2",ry:"2"}),O.jsx("path",{d:"M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"})]})}function F7({className:t}){return O.jsx("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:t,children:O.jsx("polyline",{points:"20 6 9 17 4 12"})})}const R1="https://github.com/mm7894215/TokenTracker",O7="https://github.com/mm7894215/TokenTracker/releases/latest";function B7(t="default",e="md",n){const i="inline-flex items-center justify-center rounded font-medium transition-colors duration-200 ease-out focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-oai-brand-500 focus-visible:ring-offset-2 dark:focus-visible:ring-offset-oai-gray-950",r={default:"bg-oai-gray-900 text-white hover:bg-oai-gray-800 active:bg-oai-gray-950 dark:bg-white dark:text-oai-gray-900 dark:hover:bg-oai-gray-100 dark:active:bg-oai-gray-200",ghost:"text-oai-gray-600 hover:text-oai-gray-900 hover:bg-oai-gray-100 active:bg-oai-gray-200 dark:text-oai-gray-400 dark:hover:text-white dark:hover:bg-oai-gray-800 dark:active:bg-oai-gray-700"},s={sm:"h-9 px-4 text-sm",md:"h-11 px-6 text-sm",lg:"h-12 px-8 text-base"};return Si(i,r[t],s[e],n)}function z7({copy:t,signInUrl:e,signUpUrl:n,installCommand:i,installCopied:r,onCopyInstallCommand:s}){const o=V5(),[c,u]=k.useState(!1);k.useEffect(()=>{const w=()=>u(window.scrollY>10);return window.addEventListener("scroll",w,{passive:!0}),()=>window.removeEventListener("scroll",w)},[]);const f=typeof window<"u"&&(window.location.hostname==="localhost"||window.location.hostname==="127.0.0.1"),{signedIn:h,loading:p}=Ro(),m=k.useMemo(()=>({codex:t("landing.v2.models.agent.codex"),claude_code:t("landing.v2.models.agent.claude_code"),cursor:t("landing.v2.models.agent.cursor"),gemini:t("landing.v2.models.agent.gemini"),opencode:t("landing.v2.models.agent.opencode"),openclaw:t("landing.v2.models.agent.openclaw")}),[t]),v=k.useMemo(()=>[{id:"codex",icon:"/brand-logos/codex.svg"},{id:"claude_code",icon:"/brand-logos/claude-code.svg"},{id:"cursor",icon:"/brand-logos/cursor.svg"},{id:"gemini",icon:"/brand-logos/gemini.svg"},{id:"opencode",icon:"/brand-logos/opencode.svg"},{id:"openclaw",icon:"/brand-logos/openclaw.svg"}],[]),_=o?{duration:0}:void 0;return O.jsxs("div",{className:"relative min-h-screen bg-oai-gray-950 text-oai-white font-oai antialiased dark",children:[O.jsx("div",{className:"absolute inset-0 z-0 pointer-events-none",style:{height:"100vh"},children:O.jsx(D7,{raysOrigin:"top-center",raysColor:"#b8b3ff",raysSpeed:1,lightSpread:.5,rayLength:3,pulsating:!1,fadeDistance:1,saturation:1,followMouse:!0,mouseInfluence:.1,noiseAmount:0,distortion:0})}),O.jsx("header",{className:Si("sticky top-0 z-50 transition-all duration-300",c?"bg-oai-gray-950/80 backdrop-blur-md border-b border-oai-gray-900":"bg-transparent border-b border-transparent"),children:O.jsxs("div",{className:"mx-auto flex h-14 max-w-7xl items-center justify-between px-4 sm:px-6",children:[O.jsxs("div",{className:"flex items-center gap-5",children:[O.jsxs(po,{to:n||"/",className:"flex items-center gap-3 no-underline outline-none rounded focus-visible:ring-2 focus-visible:ring-oai-brand-500 focus-visible:ring-offset-2 dark:ring-offset-oai-gray-950 transition-opacity hover:opacity-80",children:[O.jsx("img",{src:"/app-icon.png",alt:"",width:24,height:24,className:"rounded-md"}),O.jsx("span",{className:"text-sm font-semibold tracking-wide text-white uppercase",children:"Token Tracker"})]}),O.jsx("div",{className:"hidden sm:block",children:O.jsx(BV,{})})]}),f&&O.jsxs("div",{className:"flex flex-wrap items-center justify-end gap-2 sm:gap-3",children:[O.jsxs(po,{to:FV(),className:Si(B7(h||p?"default":"ghost","sm"),"no-underline px-5 rounded-full group",h||p?"shadow-sm ring-1 ring-white/10":"ring-1 ring-oai-gray-700"),children:[t("landing.v2.cta.primary"),O.jsx("span",{className:"ml-2 inline-block transition-transform duration-200 group-hover:translate-x-0.5",children:"→"})]}),O.jsx(WV,{})]})]})}),O.jsxs("main",{children:[O.jsx("section",{className:"relative py-16 sm:py-24 lg:py-32 overflow-hidden",children:O.jsxs("div",{className:"relative z-10 mx-auto max-w-7xl px-4 sm:px-6 flex flex-col items-center text-center gap-20 lg:gap-36",children:[O.jsxs(Is.div,{initial:o?!1:{opacity:0,y:20},animate:{opacity:1,y:0},transition:_||{duration:.5},className:"w-full max-w-3xl relative z-20",children:[O.jsxs("h1",{className:"text-balance text-5xl font-semibold tracking-tight text-white sm:text-6xl lg:text-[4rem] lg:leading-[1.05]",children:[t("landing.v2.hero.title_line1"),O.jsx("br",{}),O.jsx("span",{className:"bg-gradient-to-b from-white via-oai-gray-200 to-oai-gray-500 bg-clip-text text-transparent font-bold tracking-tight",style:{WebkitTextStroke:"1px rgba(255, 255, 255, 0.15)"},children:t("landing.v2.hero.title_line2")})]}),O.jsx("p",{className:"mt-6 text-lg leading-relaxed text-oai-gray-400",children:t("landing.v2.hero.subtagline")}),O.jsxs("div",{className:"mt-8 w-full max-w-lg mx-auto",children:[O.jsxs(Is.div,{whileHover:{scale:1.01,y:-1},transition:{type:"spring",stiffness:400,damping:25},className:"group relative inline-block w-full overflow-hidden rounded-2xl",style:{padding:"1.5px 0"},children:[O.jsx("div",{className:"absolute w-[300%] h-[50%] opacity-70 bottom-[-11px] right-[-250%] rounded-full animate-star-movement-bottom z-0",style:{background:"radial-gradient(circle, #fbdfff, transparent 10%)",animationDuration:"6s"}}),O.jsx("div",{className:"absolute w-[300%] h-[50%] opacity-70 top-[-10px] left-[-250%] rounded-full animate-star-movement-top z-0",style:{background:"radial-gradient(circle, #fbdfff, transparent 10%)",animationDuration:"6s"}}),O.jsxs("div",{className:"relative z-[1] flex items-center justify-between w-full bg-[#0a0a0a] border border-oai-gray-800 rounded-2xl p-1.5 pl-5 shadow-2xl shadow-black/50",children:[O.jsxs("div",{className:"flex items-center gap-3 overflow-hidden",children:[O.jsx("span",{className:"text-oai-gray-600 font-mono select-none","aria-hidden":"true",children:"›"}),O.jsx("code",{className:"font-mono text-sm text-oai-gray-200 overflow-x-auto whitespace-nowrap py-2 [scrollbar-width:none]",children:i?i.split(" ").map((w,y)=>O.jsxs("span",{className:w==="npx"||w==="tokentracker-cli"?"text-white font-medium":w==="--yes"?"text-oai-gray-500":"text-oai-brand-400",children:[w," "]},y)):null})]}),O.jsx("button",{type:"button",onClick:s,"aria-label":t(r?"landing.install.action.copied":"landing.install.action.copy"),className:"shrink-0 flex h-9 w-9 items-center justify-center text-oai-gray-200 bg-oai-gray-900 border border-oai-gray-700 rounded-lg hover:bg-oai-gray-800 hover:text-white active:scale-95 transition-all duration-200 shadow-sm",children:r?O.jsx(F7,{className:"h-4 w-4 text-green-400","aria-hidden":!0}):O.jsx(U7,{className:"h-4 w-4 opacity-70","aria-hidden":!0})})]})]}),O.jsxs("div",{className:"mt-8 flex flex-wrap items-center justify-center gap-x-6 gap-y-4",children:[O.jsxs("a",{href:O7,target:"_blank",rel:"noopener noreferrer",className:"group flex items-center gap-2 text-sm font-medium text-oai-gray-400 hover:text-white transition-colors",children:[O.jsx("div",{className:"flex items-center justify-center h-8 w-8 rounded-full bg-oai-gray-800 group-hover:bg-oai-gray-700 transition-colors",children:O.jsx(N7,{className:"h-4 w-4 text-oai-gray-400 group-hover:text-white"})}),t("landing.v2.install.mac_cta")]}),O.jsxs("a",{href:R1,target:"_blank",rel:"noopener noreferrer",className:"group flex items-center gap-2 text-sm font-medium text-oai-gray-400 hover:text-white transition-colors",children:[O.jsx("div",{className:"flex items-center justify-center h-8 w-8 rounded-full bg-oai-gray-800 group-hover:bg-oai-gray-700 transition-colors",children:O.jsx(I7,{className:"h-4 w-4 text-oai-gray-400 group-hover:text-white"})}),t("landing.cta.secondary")]})]}),O.jsx("span",{className:"sr-only","aria-live":"polite",children:r?t("landing.install.action.copied"):""})]})]}),O.jsx("div",{className:"relative group w-full",children:O.jsxs(Is.div,{initial:o?!1:{opacity:0,y:24},animate:{opacity:1,y:0},transition:_||{duration:.6,delay:.1},className:"relative w-full",children:[O.jsx("div",{style:{position:"absolute",top:"-256px",left:0,right:0,height:"510px",zIndex:3,pointerEvents:"none"},children:O.jsx(aW,{color:"#8a7aff",wispDensity:2,flowSpeed:.28,verticalSizing:2.2,horizontalSizing:1.22,fogIntensity:4,fogScale:.1,wispSpeed:18,wispIntensity:10,flowStrength:.12,decay:1.1,falloffStart:1.1,fogFallSpeed:.5,horizontalBeamOffset:.22,verticalBeamOffset:0,style:{width:"100%",height:"100%"}})}),O.jsx("div",{className:"relative rounded-xl p-[1px] shadow-2xl bg-gradient-to-b from-[rgba(138,122,255,0.6)] via-[rgba(138,122,255,0.15)] to-[rgba(138,122,255,0.05)]",style:{position:"relative",zIndex:10,boxShadow:"0 20px 60px -10px rgba(138,122,255,0.15), 0 4px 20px rgba(0,0,0,0.4)"},children:O.jsxs("div",{className:"relative rounded-[11px] overflow-hidden bg-oai-gray-950",children:[O.jsx("div",{style:{position:"absolute",top:0,left:0,right:0,height:"180px",background:"linear-gradient(to bottom, rgba(138,122,255,0.35) 0%, rgba(138,122,255,0.12) 40%, transparent 100%)",mixBlendMode:"screen",zIndex:20,pointerEvents:"none"}}),O.jsx("div",{style:{position:"absolute",top:0,left:0,right:0,height:"1px",background:"linear-gradient(90deg, transparent 0%, rgba(138,122,255,0.9) 30%, rgba(180,168,255,1) 50%, rgba(138,122,255,0.9) 70%, transparent 100%)",zIndex:25,pointerEvents:"none"}}),O.jsx("img",{src:"/dashboard-dark.png",alt:t("landing.screenshot.alt"),className:"block h-auto w-full object-cover",style:{position:"relative",zIndex:10},loading:"eager",decoding:"async"})]})})]})})]})}),O.jsx("section",{className:"border-y border-oai-gray-900 bg-oai-gray-950/50 py-12 lg:py-16",children:O.jsx("div",{className:"mx-auto max-w-6xl px-4 sm:px-6",children:O.jsxs("div",{className:"flex flex-col md:flex-row md:items-center justify-between gap-8",children:[O.jsx("p",{className:"text-sm font-semibold uppercase tracking-wider text-oai-gray-400 shrink-0",children:t("landing.v2.models.title")}),O.jsx("div",{className:"flex flex-wrap items-center gap-x-8 gap-y-6 opacity-60 hover:opacity-100 transition-opacity duration-500 grayscale hover:grayscale-0",children:v.map(w=>O.jsxs("div",{className:"flex items-center gap-2.5 transition-transform hover:-translate-y-0.5 duration-300",children:[O.jsx("img",{src:w.icon,alt:"",width:20,height:20,className:"h-5 w-5 object-contain",loading:"lazy"}),O.jsx("span",{className:"text-sm font-medium text-oai-gray-300",children:m[w.id]})]},w.id))})]})})}),O.jsx("section",{className:"py-20 lg:py-32",children:O.jsxs("div",{className:"mx-auto max-w-6xl px-4 sm:px-6 grid grid-cols-1 md:grid-cols-2 gap-16 lg:gap-24 items-start",children:[O.jsxs("div",{className:"max-w-md",children:[O.jsx("p",{className:"text-xs font-bold tracking-widest uppercase text-oai-brand-500 mb-4",children:t("landing.v2.compare.kicker")}),O.jsx("h2",{className:"text-3xl font-semibold tracking-tight text-white sm:text-4xl text-balance",children:t("landing.v2.compare.title")}),O.jsx("p",{className:"mt-6 text-lg leading-relaxed text-oai-gray-400",children:t("landing.v2.compare.subtitle")}),O.jsx("p",{className:"mt-6 text-base leading-relaxed text-oai-gray-500",children:t("landing.v2.distill.body")})]}),O.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-10",children:[O.jsxs("div",{className:"space-y-4",children:[O.jsx("h3",{className:"text-sm font-semibold uppercase tracking-wider text-white border-b border-oai-gray-800 pb-3",children:t("landing.v2.compare.with.title")}),O.jsxs("ul",{className:"space-y-3 text-sm text-oai-gray-400",children:[O.jsxs("li",{className:"flex gap-2",children:[O.jsx("span",{className:"text-oai-brand-500 shrink-0",children:"✦"}),O.jsx("span",{children:t("landing.v2.compare.with.p1")})]}),O.jsxs("li",{className:"flex gap-2",children:[O.jsx("span",{className:"text-oai-brand-500 shrink-0",children:"✦"}),O.jsx("span",{children:t("landing.v2.compare.with.p2")})]}),O.jsxs("li",{className:"flex gap-2",children:[O.jsx("span",{className:"text-oai-brand-500 shrink-0",children:"✦"}),O.jsx("span",{children:t("landing.v2.compare.with.p3")})]})]})]}),O.jsxs("div",{className:"space-y-4",children:[O.jsx("h3",{className:"text-sm font-semibold uppercase tracking-wider text-oai-gray-500 border-b border-oai-gray-800/50 pb-3",children:t("landing.v2.compare.without.title")}),O.jsxs("ul",{className:"space-y-3 text-sm text-oai-gray-500",children:[O.jsxs("li",{className:"flex gap-2",children:[O.jsx("span",{className:"opacity-50 shrink-0",children:"✕"}),O.jsx("span",{children:t("landing.v2.compare.without.p1")})]}),O.jsxs("li",{className:"flex gap-2",children:[O.jsx("span",{className:"opacity-50 shrink-0",children:"✕"}),O.jsx("span",{children:t("landing.v2.compare.without.p2")})]}),O.jsxs("li",{className:"flex gap-2",children:[O.jsx("span",{className:"opacity-50 shrink-0",children:"✕"}),O.jsx("span",{children:t("landing.v2.compare.without.p3")})]})]})]})]})]})})]}),O.jsx("footer",{className:"border-t border-oai-gray-900 bg-oai-gray-950 py-12",children:O.jsxs("div",{className:"mx-auto flex max-w-6xl flex-col items-center justify-between gap-6 px-4 sm:px-6 text-sm text-oai-gray-400 sm:flex-row",children:[O.jsx("p",{children:t("landing.v2.footer.line")}),O.jsxs("div",{className:"flex items-center gap-6",children:[O.jsx("a",{href:R1,className:"font-medium text-oai-gray-400 hover:text-white transition-colors",target:"_blank",rel:"noopener noreferrer",children:t("landing.v2.nav.github")}),f&&O.jsxs(po,{to:e,className:"font-medium text-oai-brand-500 hover:text-oai-brand-400 transition-colors",children:[t("landing.cta.primary")," →"]})]})]})})]})}function V7({prefersReducedMotion:t,screenshotMode:e}){return!(e||t)}function H7(){return k.useMemo(()=>typeof window>"u"||!window.matchMedia?!1:window.matchMedia("(prefers-reduced-motion: reduce)").matches,[])}function G7(t=0,e=!0){const[n,i]=k.useState(()=>!e);return k.useEffect(()=>{if(!e){i(!0);return}let r=null,s=null;const o=()=>i(!0);return typeof window<"u"&&"requestIdleCallback"in window?(s=window.requestIdleCallback(o,{timeout:t||200}),()=>{typeof window.cancelIdleCallback=="function"&&s!=null&&window.cancelIdleCallback(s)}):(r=window.setTimeout(o,t),()=>{r!=null&&window.clearTimeout(r)})},[t,e]),n}function j7({signInUrl:t,signUpUrl:e}){const n=qt("landing.handle.special"),i=qt("landing.handle.default");qt("landing.nav.login"),qt("landing.nav.signup");const[r,s]=k.useState(i),o=H7(),c=k.useMemo(()=>typeof window>"u"?!1:UC(window.location.search),[]),u=V7({prefersReducedMotion:o,screenshotMode:c});G7(250,u);const f="tokentracker.dashboard.from_landing.v1";k.useEffect(()=>{if(!(typeof window>"u"))try{window.sessionStorage.setItem(f,"1")}catch{}},[f]),k.useMemo(()=>qt("landing.handle.placeholder",{handle:n}),[n]),k.useMemo(()=>{const _=qt(r===n?"landing.rank.singularity":"landing.rank.unranked");return qt("landing.rank.expectation",{rank:_})},[r,n]);const h=qt("landing.install.command"),[p,m]=k.useState(!1),v=async()=>{await IV(h)&&(m(!0),window.setTimeout(()=>m(!1),2e3))};return O.jsx(z7,{copy:qt,reduceMotion:o,signInUrl:t,signUpUrl:e,installCommand:h,installCopied:p,onCopyInstallCommand:v})}function W7(t){const e=new URLSearchParams(t).get("next");return typeof e!="string"||e.length===0||!e.startsWith("/")||e.startsWith("//")?"/dashboard":e}const P1={google:"Google",github:"GitHub",microsoft:"Microsoft",discord:"Discord",linkedin:"LinkedIn",facebook:"Facebook",instagram:"Instagram",tiktok:"TikTok",apple:"Apple",x:"X",spotify:"Spotify"};function k1(t){const e=String(t||"").trim();return P1[e]?P1[e]:e.replace(/-/g," ")}function $7(){const t=Eh(),[e,n]=DL(),{enabled:i,loading:r,signedIn:s,refreshUser:o,signInWithPassword:c,signUp:u,signInWithOAuth:f,getPublicAuthConfig:h}=Ro(),p=k.useMemo(()=>W7(e.toString()),[e]),[m,v]=k.useState("signin"),[_,w]=k.useState(""),[y,x]=k.useState(""),[M,A]=k.useState(""),[T,D]=k.useState(!1),[I,U]=k.useState(null),[S,R]=k.useState(null),[V,F]=k.useState(!0),[j,Z]=k.useState([]),[H,q]=k.useState([]),[J,Q]=k.useState(8);k.useEffect(()=>{const we=e.get("insforge_status"),ne=e.get("insforge_type"),_e=e.get("insforge_error");we==="success"&&ne==="verify_email"?R(qt("login.verify_email_success")):we==="error"&&ne==="verify_email"&&_e&&R(qt("shared.error.prefix",{error:_e}))},[e]),k.useEffect(()=>{if(!i){F(!1);return}let we=!0;return(async()=>{const{data:ne,error:_e}=await h();we&&(_e||!ne?(Z(["google","github"]),q([])):(Z(Array.isArray(ne.oAuthProviders)?ne.oAuthProviders:[]),q(Array.isArray(ne.customOAuthProviders)?ne.customOAuthProviders:[]),typeof ne.passwordMinLength=="number"&&ne.passwordMinLength>0&&Q(ne.passwordMinLength)),F(!1))})(),()=>{we=!1}},[i,h]),k.useEffect(()=>{if(!(!i||r)&&s){if(W){window.location.href="/auth/native-callback";return}t(p,{replace:!0})}},[i,r,s,t,p,W]),k.useEffect(()=>{i&&o()},[i,o]);const W=k.useMemo(()=>e.get("native")==="1",[e]),X=k.useMemo(()=>e.get("provider")||null,[e]),K=k.useMemo(()=>typeof window>"u"||W?"":`${window.location.origin}/`,[W]),B=k.useMemo(()=>typeof window>"u"?"":`${window.location.origin}/`,[]),ie=k.useCallback(async we=>{we.preventDefault(),U(null),D(!0);try{if(m==="signup"){const{data:_e,error:Se}=await u({email:_.trim(),password:y,name:M.trim()||void 0,redirectTo:B});if(Se){U(Se.message||String(Se));return}if(_e?.requireEmailVerification){R(qt("login.verify_email_pending")),v("signin");return}t(p,{replace:!0});return}const{error:ne}=await c({email:_.trim(),password:y});if(ne){U(ne.message||String(ne));return}t(p,{replace:!0})}finally{D(!1)}},[m,_,y,M,u,c,t,p,B]),ve=k.useCallback(async we=>{U(null),D(!0);try{const{error:ne}=await f(we,K);ne&&U(ne.message||String(ne))}finally{D(!1)}},[f,K]);k.useEffect(()=>{if(W&&typeof window<"u")try{window.sessionStorage.setItem("tokentracker_native_login","1")}catch{}},[W]),k.useEffect(()=>{if(!i||r||s||V||!W||!X)return;[...j,...H].includes(X)&&ve(X)},[i,r,s,V,W,X,j,H,ve]);const Ce=k.useCallback(()=>{n(we=>{const ne=new URLSearchParams(we);return ne.delete("insforge_status"),ne.delete("insforge_type"),ne.delete("insforge_error"),ne},{replace:!0}),R(null)},[n]);return i?O.jsxs("div",{className:"min-h-screen bg-oai-gray-950 text-oai-white font-oai antialiased dark flex flex-col",children:[O.jsx("header",{className:"border-b border-oai-gray-900 px-4 sm:px-6 h-16 flex items-center justify-between",children:O.jsx(po,{to:"/",className:"text-sm font-medium text-oai-gray-400 hover:text-white no-underline focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-oai-brand-500 rounded",children:qt("login.back_home")})}),O.jsx("main",{className:"flex-1 flex items-center justify-center px-4 py-12",children:O.jsxs("div",{className:"w-full max-w-md space-y-8",children:[O.jsxs("div",{className:"text-center",children:[O.jsx("h1",{className:"text-2xl font-semibold text-white tracking-tight",children:qt("login.title")}),O.jsx("p",{className:"mt-2 text-sm text-oai-gray-500",children:qt("login.subtitle")})]}),S?O.jsxs("div",{className:"rounded-lg border border-oai-gray-800 bg-oai-gray-900/50 px-4 py-3 text-sm text-oai-gray-300 flex justify-between gap-3 items-start",role:"status",children:[O.jsx("span",{children:S}),O.jsx("button",{type:"button",onClick:Ce,className:"shrink-0 text-oai-gray-500 hover:text-white text-xs",children:qt("login.dismiss")})]}):null,I?O.jsx("p",{className:"text-sm text-red-400",role:"alert",children:qt("shared.error.prefix",{error:I})}):null,O.jsx("div",{className:"space-y-3",children:V?O.jsx("div",{className:"h-11 rounded-lg bg-oai-gray-900 animate-pulse","aria-hidden":!0}):O.jsxs(O.Fragment,{children:[j.map(we=>O.jsx("button",{type:"button",disabled:T,onClick:()=>ve(we),className:Si("w-full h-11 rounded-lg border border-oai-gray-700 bg-oai-gray-900 text-sm font-medium text-white","hover:bg-oai-gray-800 transition-colors disabled:opacity-50"),children:qt("login.oauth.continue",{provider:k1(we)})},we)),H.map(we=>O.jsx("button",{type:"button",disabled:T,onClick:()=>ve(we),className:Si("w-full h-11 rounded-lg border border-oai-gray-700 bg-oai-gray-900 text-sm font-medium text-white","hover:bg-oai-gray-800 transition-colors disabled:opacity-50"),children:qt("login.oauth.continue",{provider:k1(we)})},we))]})}),O.jsxs("div",{className:"relative",children:[O.jsx("div",{className:"absolute inset-0 flex items-center","aria-hidden":!0,children:O.jsx("span",{className:"w-full border-t border-oai-gray-800"})}),O.jsx("div",{className:"relative flex justify-center text-xs uppercase tracking-wider",children:O.jsx("span",{className:"bg-oai-gray-950 px-3 text-oai-gray-600",children:qt("login.divider")})})]}),O.jsxs("div",{className:"flex rounded-lg border border-oai-gray-800 p-0.5 bg-oai-gray-900/50",children:[O.jsx("button",{type:"button",className:Si("flex-1 py-2 text-sm font-medium rounded-md transition-colors",m==="signin"?"bg-oai-gray-800 text-white":"text-oai-gray-500 hover:text-oai-gray-300"),onClick:()=>{v("signin"),U(null)},children:qt("login.tab.sign_in")}),O.jsx("button",{type:"button",className:Si("flex-1 py-2 text-sm font-medium rounded-md transition-colors",m==="signup"?"bg-oai-gray-800 text-white":"text-oai-gray-500 hover:text-oai-gray-300"),onClick:()=>{v("signup"),U(null)},children:qt("login.tab.sign_up")})]}),O.jsxs("form",{onSubmit:ie,className:"space-y-4",children:[m==="signup"?O.jsxs("div",{children:[O.jsx("label",{htmlFor:"login-name",className:"block text-xs font-medium text-oai-gray-500 mb-1",children:qt("login.field.name")}),O.jsx("input",{id:"login-name",type:"text",autoComplete:"name",value:M,onChange:we=>A(we.target.value),className:"w-full h-11 rounded-lg border border-oai-gray-800 bg-oai-gray-900 px-3 text-sm text-white placeholder-oai-gray-600 focus:outline-none focus:ring-2 focus:ring-oai-brand-500",placeholder:qt("login.field.name_placeholder")})]}):null,O.jsxs("div",{children:[O.jsx("label",{htmlFor:"login-email",className:"block text-xs font-medium text-oai-gray-500 mb-1",children:qt("login.field.email")}),O.jsx("input",{id:"login-email",type:"email",autoComplete:"email",required:!0,value:_,onChange:we=>w(we.target.value),className:"w-full h-11 rounded-lg border border-oai-gray-800 bg-oai-gray-900 px-3 text-sm text-white placeholder-oai-gray-600 focus:outline-none focus:ring-2 focus:ring-oai-brand-500"})]}),O.jsxs("div",{children:[O.jsx("label",{htmlFor:"login-password",className:"block text-xs font-medium text-oai-gray-500 mb-1",children:qt("login.field.password")}),O.jsx("input",{id:"login-password",type:"password",autoComplete:m==="signup"?"new-password":"current-password",required:!0,minLength:m==="signup"?J:void 0,value:y,onChange:we=>x(we.target.value),className:"w-full h-11 rounded-lg border border-oai-gray-800 bg-oai-gray-900 px-3 text-sm text-white placeholder-oai-gray-600 focus:outline-none focus:ring-2 focus:ring-oai-brand-500"}),m==="signup"?O.jsx("p",{className:"mt-1 text-xs text-oai-gray-600",children:qt("login.password_hint",{min:String(J)})}):null]}),O.jsx("button",{type:"submit",disabled:T||r,className:"w-full h-11 rounded-lg bg-white text-oai-gray-950 text-sm font-semibold hover:bg-oai-gray-100 transition-colors disabled:opacity-50",children:qt(m==="signup"?"login.submit.sign_up":"login.submit.sign_in")})]})]})})]}):O.jsxs("div",{className:"min-h-screen bg-oai-gray-950 text-oai-white font-oai antialiased dark flex flex-col",children:[O.jsx("header",{className:"border-b border-oai-gray-900 px-4 sm:px-6 py-4",children:O.jsx(po,{to:"/",className:"text-sm font-medium text-oai-gray-400 hover:text-white no-underline",children:qt("login.back_home")})}),O.jsx("main",{className:"flex-1 flex items-center justify-center px-4",children:O.jsx("p",{className:"text-oai-gray-400 text-center max-w-md",children:qt("login.cloud_only")})})]})}const X7=typeof window<"u"?window.location.search:"",L1=new URLSearchParams(X7),xf=L1.get("insforge_code")||L1.get("code")||null;function q7(){const{loading:t,signedIn:e}=Ro(),n=Eh(),[i,r]=k.useState("processing"),[s,o]=k.useState(null),c=k.useRef(!1);return k.useEffect(()=>{!xf||c.current||(c.current=!0,(async()=>{try{const f=await(await fetch("/api/auth-bridge/verifier")).json();o(!!f?.native)}catch{o(!1)}})())},[]),k.useEffect(()=>{if(s!==!0||!xf)return;r("redirecting");const u=setTimeout(()=>{window.location.href=`tokentracker://auth/callback?insforge_code=${encodeURIComponent(xf)}`},200);return()=>clearTimeout(u)},[s]),k.useEffect(()=>{if(s!==!1||t)return;if(e){n("/dashboard",{replace:!0});return}const u=setTimeout(()=>{e||r("failed")},5e3);return()=>clearTimeout(u)},[s,t,e,n]),k.useEffect(()=>{if(!xf&&s===null){const u=setTimeout(()=>r("failed"),3e3);return()=>clearTimeout(u)}},[s]),i==="processing"&&s!==!0&&(s===null||s===!1&&t)?O.jsx("div",{className:"min-h-screen bg-oai-gray-950"}):O.jsx("div",{className:"min-h-screen bg-oai-gray-950 text-white font-oai antialiased dark flex items-center justify-center",children:O.jsxs("div",{className:"text-center space-y-4 max-w-sm px-4",children:[i==="processing"&&O.jsxs(O.Fragment,{children:[O.jsx("div",{className:"w-8 h-8 border-2 border-oai-gray-600 border-t-white rounded-full animate-spin mx-auto"}),O.jsx("p",{className:"text-oai-gray-400 text-sm",children:"Processing…"})]}),i==="redirecting"&&O.jsxs(O.Fragment,{children:[O.jsx("div",{className:"w-12 h-12 mx-auto rounded-full bg-green-500/15 flex items-center justify-center",children:O.jsx("svg",{className:"w-6 h-6 text-green-400",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2.5",strokeLinecap:"round",strokeLinejoin:"round",children:O.jsx("path",{d:"M20 6 9 17l-5-5"})})}),O.jsx("p",{className:"text-white text-sm font-medium",children:"Signed in successfully"}),O.jsx("p",{className:"text-oai-gray-500 text-xs",children:"Returning to TokenTracker…"})]}),i==="failed"&&O.jsxs("div",{className:"space-y-3",children:[O.jsx("p",{className:"text-oai-gray-300 text-sm",children:"Sign-in incomplete. Please try again."}),O.jsx("button",{type:"button",onClick:()=>window.close(),className:"px-4 py-2 rounded-lg bg-oai-gray-800 text-sm text-white hover:bg-oai-gray-700 transition-colors",children:"Close this page"})]})]})})}const Y7=jl.lazy(()=>ly(()=>import("./DashboardPage-7poMJy2s.js"),__vite__mapDeps([0,1])).then(t=>({default:t.DashboardPage}))),K7=jl.lazy(()=>ly(()=>import("./LeaderboardPage-DYHGsG7D.js"),__vite__mapDeps([2,3,1])).then(t=>({default:t.LeaderboardPage}))),Z7=jl.lazy(()=>ly(()=>import("./LeaderboardProfilePage-RjYL1DAT.js"),__vite__mapDeps([4,3,1])).then(t=>({default:t.LeaderboardProfilePage})));function J7(){const t=zr(),e=Ro();DV();const n=_r(),i=k.useMemo(()=>typeof window>"u"?!1:UC(window.location.search),[]),r=t?.pathname||"/",s=new URL(window.location.href),o=s.pathname.replace(/\/+$/,"")||"/",u=o.match(/^\/share\/([^/?#]+)$/i)?.[1]||null,f=s.searchParams.get("token")||null,h=u||f,p=o==="/share"||o==="/share.html"||o.startsWith("/share/"),m=typeof window<"u"&&(window.location.hostname==="localhost"||window.location.hostname==="127.0.0.1"),v=r.replace(/\/+$/,"")||"/",_=v.match(/^\/leaderboard\/u\/([^/]+)$/i),w=_?_[1]:null,y=v==="/leaderboard"||!!w,x=!!(e.enabled&&e.signedIn),M=m||x,A=!1,T=Qz(),D=k.useMemo(()=>!e.enabled||!x?null:{getAccessToken:()=>e.getAccessToken()},[e,x]);let I=m||n||i?"dashboard":"landing";v==="/landing"&&(I="landing"),v==="/dashboard"&&(I="dashboard"),y&&(I="dashboard");const U=w?Z7:v==="/leaderboard"?K7:Y7,S=O.jsx("div",{className:"min-h-screen bg-oai-white dark:bg-[#050505]"});let R=null;return v==="/auth/callback"||v==="/auth/native-callback"?R=O.jsx(q7,{}):v==="/login"?R=O.jsx($7,{}):I==="landing"?R=O.jsx(j7,{signInUrl:"/login",signUpUrl:"/login"}):R=O.jsx(k.Suspense,{fallback:S,children:O.jsx(U,{baseUrl:T,auth:D,signedIn:M,sessionSoftExpired:A,signOut:()=>e.enabled?e.signOut():Promise.resolve(),publicMode:p,publicToken:h,userId:w,signInUrl:"/login",signUpUrl:"/login"})}),O.jsx(OU,{children:O.jsx(HU,{children:O.jsxs(GU,{children:[R,O.jsx(Zz,{}),O.jsx(OI,{}),O.jsx(YI,{})]})})})}const Q7=TL([{path:"*",element:O.jsx(J7,{})}]);p2.createRoot(document.getElementById("root")).render(O.jsx(jl.StrictMode,{children:O.jsx(EI,{children:O.jsx(zL,{router:Q7})})}));export{nU as $,k$ as A,kC as B,qt as C,O as D,fy as E,oU as F,wT as G,Nv as H,SU as I,ch as J,OS as K,IS as L,zy as M,u$ as N,dy as O,Sl as P,uy as Q,N1 as R,BL as S,pT as T,TU as U,BS as V,Xl as W,yT as X,US as Y,mT as Z,KI as _,hi as a,tU as a0,ZI as a1,c0 as a2,vT as a3,o$ as a4,eU as a5,l$ as a6,gT as a7,c$ as a8,WV as a9,zr as aA,Eh as aB,f$ as aC,aT as aD,Hd as aE,T$ as aF,BV as aG,FV as aH,PV as aI,A$ as aJ,vI as aK,C$ as aL,BU as aM,po as aa,OV as ab,V5 as ac,Is as ad,gU as ae,jl as af,b$ as ag,x$ as ah,AT as ai,Ro as aj,I0 as ak,UC as al,ro as am,R$ as an,h$ as ao,p$ as ap,S$ as aq,sV as ar,m$ as as,g$ as at,P$ as au,_$ as av,ly as aw,w$ as ax,IV as ay,Si as az,CT as b,ka as c,iw as d,Fh as e,Tn as f,LC as g,_r as h,BF as i,a$ as j,SI as k,U$ as l,Ol as m,lV as n,cV as o,L$ as p,y$ as q,k as r,M$ as s,D$ as t,py as u,N$ as v,v$ as w,kn as x,E$ as y,I$ as z};
4863
+ }`;function D7({raysOrigin:t="top-center",raysColor:e="#ffffff",raysSpeed:n=1,lightSpread:i=1,rayLength:r=2,pulsating:s=!1,fadeDistance:o=1,saturation:c=1,followMouse:u=!0,mouseInfluence:f=.1,noiseAmount:h=0,distortion:p=0,className:m=""}){const v=k.useRef(null),_=k.useRef(null),w=k.useRef(null),y=k.useRef({x:.5,y:.5}),x=k.useRef({x:.5,y:.5}),M=k.useRef(null),A=k.useRef(null),T=k.useRef(null),[D,I]=k.useState(!1),U=k.useRef(null);return k.useEffect(()=>{if(v.current)return U.current=new IntersectionObserver(S=>{I(S[0].isIntersecting)},{threshold:.1}),U.current.observe(v.current),()=>{U.current&&(U.current.disconnect(),U.current=null)}},[]),k.useEffect(()=>!D||!v.current?void 0:(T.current&&(T.current(),T.current=null),(async()=>{if(!v.current||(await new Promise(Q=>setTimeout(Q,10)),!v.current))return;const R=new kW({dpr:Math.min(window.devicePixelRatio,2),alpha:!0});w.current=R;const V=R.gl;for(V.canvas.style.width="100%",V.canvas.style.height="100%";v.current.firstChild;)v.current.removeChild(v.current.firstChild);v.current.appendChild(V.canvas);const F={iTime:{value:0},iResolution:{value:[1,1]},rayPos:{value:[0,0]},rayDir:{value:[0,1]},raysColor:{value:A1(e)},raysSpeed:{value:n},lightSpread:{value:i},rayLength:{value:r},pulsating:{value:s?1:0},fadeDistance:{value:o},saturation:{value:c},mousePos:{value:[.5,.5]},mouseInfluence:{value:f},noiseAmount:{value:h},distortion:{value:p}};_.current=F;const j=new P7(V),Z=new TW(V,{vertex:k7,fragment:L7,uniforms:F}),H=new R7(V,{geometry:j,program:Z});A.current=H;const q=()=>{if(!v.current||!R)return;R.dpr=Math.min(window.devicePixelRatio,2);const{clientWidth:Q,clientHeight:W}=v.current;R.setSize(Q,W);const X=R.dpr,K=Q*X,B=W*X;F.iResolution.value=[K,B];const{anchor:ie,dir:ve}=C1(t,K,B);F.rayPos.value=ie,F.rayDir.value=ve},J=Q=>{if(!(!w.current||!_.current||!A.current)){F.iTime.value=Q*.001,u&&f>0&&(x.current.x=x.current.x*.92+y.current.x*(1-.92),x.current.y=x.current.y*.92+y.current.y*(1-.92),F.mousePos.value=[x.current.x,x.current.y]);try{R.render({scene:H}),M.current=requestAnimationFrame(J)}catch(W){console.warn("WebGL rendering error:",W)}}};window.addEventListener("resize",q),q(),M.current=requestAnimationFrame(J),T.current=()=>{if(M.current&&(cancelAnimationFrame(M.current),M.current=null),window.removeEventListener("resize",q),R)try{const Q=R.gl.getExtension("WEBGL_lose_context");Q&&Q.loseContext();const W=R.gl.canvas;W&&W.parentNode&&W.parentNode.removeChild(W)}catch(Q){console.warn("Error during WebGL cleanup:",Q)}w.current=null,_.current=null,A.current=null}})(),()=>{T.current&&(T.current(),T.current=null)}),[D,t,e,n,i,r,s,o,c,u,f,h,p]),k.useEffect(()=>{if(!_.current||!v.current||!w.current)return;const S=_.current,R=w.current;S.raysColor.value=A1(e),S.raysSpeed.value=n,S.lightSpread.value=i,S.rayLength.value=r,S.pulsating.value=s?1:0,S.fadeDistance.value=o,S.saturation.value=c,S.mouseInfluence.value=f,S.noiseAmount.value=h,S.distortion.value=p;const{clientWidth:V,clientHeight:F}=v.current,j=R.dpr,{anchor:Z,dir:H}=C1(t,V*j,F*j);S.rayPos.value=Z,S.rayDir.value=H},[e,n,i,t,r,s,o,c,f,h,p]),k.useEffect(()=>{if(!u)return;const S=R=>{if(!v.current)return;const V=v.current.getBoundingClientRect();y.current={x:(R.clientX-V.left)/V.width,y:(R.clientY-V.top)/V.height}};return window.addEventListener("mousemove",S),()=>window.removeEventListener("mousemove",S)},[u]),O.jsx("div",{ref:v,className:`w-full h-full pointer-events-none z-[3] overflow-hidden relative ${m}`.trim()})}function N7({className:t}){return O.jsx("svg",{viewBox:"0 0 384 512",className:t,fill:"currentColor",children:O.jsx("path",{d:"M318.7 268.7c-.2-36.7 16.4-64.4 50-84.8-18.8-26.9-47.2-41.7-84.7-44.6-35.5-2.8-74.3 20.7-88.5 20.7-15 0-49.4-19.7-76.4-19.7C63.3 141.2 4 184.8 4 273.5q0 39.3 14.4 81.2c12.8 36.7 59 126.7 107.2 125.2 25.2-.6 43-17.9 75.8-17.9 31.8 0 48.3 17.9 76.4 17.9 48.6-.7 90.4-82.5 102.6-119.3-65.2-30.7-61.7-90-61.7-91.9zm-56.6-164.2c27.3-32.4 24.8-61.9 24-72.5-24.1 1.4-52 16.4-67.9 34.9-17.5 19.8-27.8 44.3-25.6 71.9 26.1 2 49.9-11.4 69.5-34.3z"})})}function I7({className:t}){return O.jsx("svg",{viewBox:"0 0 16 16",className:t,fill:"currentColor",children:O.jsx("path",{d:"M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"})})}function U7({className:t}){return O.jsxs("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:t,children:[O.jsx("rect",{x:"9",y:"9",width:"13",height:"13",rx:"2",ry:"2"}),O.jsx("path",{d:"M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"})]})}function F7({className:t}){return O.jsx("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:t,children:O.jsx("polyline",{points:"20 6 9 17 4 12"})})}const R1="https://github.com/mm7894215/TokenTracker",O7="https://github.com/mm7894215/TokenTracker/releases/latest";function B7(t="default",e="md",n){const i="inline-flex items-center justify-center rounded font-medium transition-colors duration-200 ease-out focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-oai-brand-500 focus-visible:ring-offset-2 dark:focus-visible:ring-offset-oai-gray-950",r={default:"bg-oai-gray-900 text-white hover:bg-oai-gray-800 active:bg-oai-gray-950 dark:bg-white dark:text-oai-gray-900 dark:hover:bg-oai-gray-100 dark:active:bg-oai-gray-200",ghost:"text-oai-gray-600 hover:text-oai-gray-900 hover:bg-oai-gray-100 active:bg-oai-gray-200 dark:text-oai-gray-400 dark:hover:text-white dark:hover:bg-oai-gray-800 dark:active:bg-oai-gray-700"},s={sm:"h-9 px-4 text-sm",md:"h-11 px-6 text-sm",lg:"h-12 px-8 text-base"};return Si(i,r[t],s[e],n)}function z7({copy:t,signInUrl:e,signUpUrl:n,installCommand:i,installCopied:r,onCopyInstallCommand:s}){const o=V5(),[c,u]=k.useState(!1);k.useEffect(()=>{const w=()=>u(window.scrollY>10);return window.addEventListener("scroll",w,{passive:!0}),()=>window.removeEventListener("scroll",w)},[]);const f=typeof window<"u"&&(window.location.hostname==="localhost"||window.location.hostname==="127.0.0.1"),{signedIn:h,loading:p}=Ro(),m=k.useMemo(()=>({codex:t("landing.v2.models.agent.codex"),claude_code:t("landing.v2.models.agent.claude_code"),cursor:t("landing.v2.models.agent.cursor"),gemini:t("landing.v2.models.agent.gemini"),opencode:t("landing.v2.models.agent.opencode"),openclaw:t("landing.v2.models.agent.openclaw")}),[t]),v=k.useMemo(()=>[{id:"codex",icon:"/brand-logos/codex.svg"},{id:"claude_code",icon:"/brand-logos/claude-code.svg"},{id:"cursor",icon:"/brand-logos/cursor.svg"},{id:"gemini",icon:"/brand-logos/gemini.svg"},{id:"opencode",icon:"/brand-logos/opencode.svg"},{id:"openclaw",icon:"/brand-logos/openclaw.svg"}],[]),_=o?{duration:0}:void 0;return O.jsxs("div",{className:"relative min-h-screen bg-oai-gray-950 text-oai-white font-oai antialiased dark",children:[O.jsx("div",{className:"absolute inset-0 z-0 pointer-events-none",style:{height:"100vh"},children:O.jsx(D7,{raysOrigin:"top-center",raysColor:"#b8b3ff",raysSpeed:1,lightSpread:.5,rayLength:3,pulsating:!1,fadeDistance:1,saturation:1,followMouse:!0,mouseInfluence:.1,noiseAmount:0,distortion:0})}),O.jsx("header",{className:Si("sticky top-0 z-50 transition-all duration-300",c?"bg-oai-gray-950/80 backdrop-blur-md border-b border-oai-gray-900":"bg-transparent border-b border-transparent"),children:O.jsxs("div",{className:"mx-auto flex h-14 max-w-7xl items-center justify-between px-4 sm:px-6",children:[O.jsxs("div",{className:"flex items-center gap-5",children:[O.jsxs(po,{to:n||"/",className:"flex items-center gap-3 no-underline outline-none rounded focus-visible:ring-2 focus-visible:ring-oai-brand-500 focus-visible:ring-offset-2 dark:ring-offset-oai-gray-950 transition-opacity hover:opacity-80",children:[O.jsx("img",{src:"/app-icon.png",alt:"",width:24,height:24,className:"rounded-md"}),O.jsx("span",{className:"text-sm font-semibold tracking-wide text-white uppercase",children:"Token Tracker"})]}),O.jsx("div",{className:"hidden sm:block",children:O.jsx(BV,{})})]}),f&&O.jsxs("div",{className:"flex flex-wrap items-center justify-end gap-2 sm:gap-3",children:[O.jsxs(po,{to:FV(),className:Si(B7(h||p?"default":"ghost","sm"),"no-underline px-5 rounded-full group",h||p?"shadow-sm ring-1 ring-white/10":"ring-1 ring-oai-gray-700"),children:[t("landing.v2.cta.primary"),O.jsx("span",{className:"ml-2 inline-block transition-transform duration-200 group-hover:translate-x-0.5",children:"→"})]}),O.jsx(WV,{})]})]})}),O.jsxs("main",{children:[O.jsx("section",{className:"relative py-16 sm:py-24 lg:py-32 overflow-hidden",children:O.jsxs("div",{className:"relative z-10 mx-auto max-w-7xl px-4 sm:px-6 flex flex-col items-center text-center gap-20 lg:gap-36",children:[O.jsxs(Is.div,{initial:o?!1:{opacity:0,y:20},animate:{opacity:1,y:0},transition:_||{duration:.5},className:"w-full max-w-3xl relative z-20",children:[O.jsxs("h1",{className:"text-balance text-5xl font-semibold tracking-tight text-white sm:text-6xl lg:text-[4rem] lg:leading-[1.05]",children:[t("landing.v2.hero.title_line1"),O.jsx("br",{}),O.jsx("span",{className:"bg-gradient-to-b from-white via-oai-gray-200 to-oai-gray-500 bg-clip-text text-transparent font-bold tracking-tight",style:{WebkitTextStroke:"1px rgba(255, 255, 255, 0.15)"},children:t("landing.v2.hero.title_line2")})]}),O.jsx("p",{className:"mt-6 text-lg leading-relaxed text-oai-gray-400",children:t("landing.v2.hero.subtagline")}),O.jsxs("div",{className:"mt-8 w-full max-w-lg mx-auto",children:[O.jsxs(Is.div,{whileHover:{scale:1.01,y:-1},transition:{type:"spring",stiffness:400,damping:25},className:"group relative inline-block w-full overflow-hidden rounded-2xl",style:{padding:"1.5px 0"},children:[O.jsx("div",{className:"absolute w-[300%] h-[50%] opacity-70 bottom-[-11px] right-[-250%] rounded-full animate-star-movement-bottom z-0",style:{background:"radial-gradient(circle, #fbdfff, transparent 10%)",animationDuration:"6s"}}),O.jsx("div",{className:"absolute w-[300%] h-[50%] opacity-70 top-[-10px] left-[-250%] rounded-full animate-star-movement-top z-0",style:{background:"radial-gradient(circle, #fbdfff, transparent 10%)",animationDuration:"6s"}}),O.jsxs("div",{className:"relative z-[1] flex items-center justify-between w-full bg-[#0a0a0a] border border-oai-gray-800 rounded-2xl p-1.5 pl-5 shadow-2xl shadow-black/50",children:[O.jsxs("div",{className:"flex items-center gap-3 overflow-hidden",children:[O.jsx("span",{className:"text-oai-gray-600 font-mono select-none","aria-hidden":"true",children:"›"}),O.jsx("code",{className:"font-mono text-sm text-oai-gray-200 overflow-x-auto whitespace-nowrap py-2 [scrollbar-width:none]",children:i?i.split(" ").map((w,y)=>O.jsxs("span",{className:w==="npx"||w==="tokentracker-cli"?"text-white font-medium":w==="--yes"?"text-oai-gray-500":"text-oai-brand-400",children:[w," "]},y)):null})]}),O.jsx("button",{type:"button",onClick:s,"aria-label":t(r?"landing.install.action.copied":"landing.install.action.copy"),className:"shrink-0 flex h-9 w-9 items-center justify-center text-oai-gray-200 bg-oai-gray-900 border border-oai-gray-700 rounded-lg hover:bg-oai-gray-800 hover:text-white active:scale-95 transition-all duration-200 shadow-sm",children:r?O.jsx(F7,{className:"h-4 w-4 text-green-400","aria-hidden":!0}):O.jsx(U7,{className:"h-4 w-4 opacity-70","aria-hidden":!0})})]})]}),O.jsxs("div",{className:"mt-8 flex flex-wrap items-center justify-center gap-x-6 gap-y-4",children:[O.jsxs("a",{href:O7,target:"_blank",rel:"noopener noreferrer",className:"group flex items-center gap-2 text-sm font-medium text-oai-gray-400 hover:text-white transition-colors",children:[O.jsx("div",{className:"flex items-center justify-center h-8 w-8 rounded-full bg-oai-gray-800 group-hover:bg-oai-gray-700 transition-colors",children:O.jsx(N7,{className:"h-4 w-4 text-oai-gray-400 group-hover:text-white"})}),t("landing.v2.install.mac_cta")]}),O.jsxs("a",{href:R1,target:"_blank",rel:"noopener noreferrer",className:"group flex items-center gap-2 text-sm font-medium text-oai-gray-400 hover:text-white transition-colors",children:[O.jsx("div",{className:"flex items-center justify-center h-8 w-8 rounded-full bg-oai-gray-800 group-hover:bg-oai-gray-700 transition-colors",children:O.jsx(I7,{className:"h-4 w-4 text-oai-gray-400 group-hover:text-white"})}),t("landing.cta.secondary")]})]}),O.jsx("span",{className:"sr-only","aria-live":"polite",children:r?t("landing.install.action.copied"):""})]})]}),O.jsx("div",{className:"relative group w-full",children:O.jsxs(Is.div,{initial:o?!1:{opacity:0,y:24},animate:{opacity:1,y:0},transition:_||{duration:.6,delay:.1},className:"relative w-full",children:[O.jsx("div",{style:{position:"absolute",top:"-256px",left:0,right:0,height:"510px",zIndex:3,pointerEvents:"none"},children:O.jsx(aW,{color:"#8a7aff",wispDensity:2,flowSpeed:.28,verticalSizing:2.2,horizontalSizing:1.22,fogIntensity:4,fogScale:.1,wispSpeed:18,wispIntensity:10,flowStrength:.12,decay:1.1,falloffStart:1.1,fogFallSpeed:.5,horizontalBeamOffset:.22,verticalBeamOffset:0,style:{width:"100%",height:"100%"}})}),O.jsx("div",{className:"relative rounded-xl p-[1px] shadow-2xl bg-gradient-to-b from-[rgba(138,122,255,0.6)] via-[rgba(138,122,255,0.15)] to-[rgba(138,122,255,0.05)]",style:{position:"relative",zIndex:10,boxShadow:"0 20px 60px -10px rgba(138,122,255,0.15), 0 4px 20px rgba(0,0,0,0.4)"},children:O.jsxs("div",{className:"relative rounded-[11px] overflow-hidden bg-oai-gray-950",children:[O.jsx("div",{style:{position:"absolute",top:0,left:0,right:0,height:"180px",background:"linear-gradient(to bottom, rgba(138,122,255,0.35) 0%, rgba(138,122,255,0.12) 40%, transparent 100%)",mixBlendMode:"screen",zIndex:20,pointerEvents:"none"}}),O.jsx("div",{style:{position:"absolute",top:0,left:0,right:0,height:"1px",background:"linear-gradient(90deg, transparent 0%, rgba(138,122,255,0.9) 30%, rgba(180,168,255,1) 50%, rgba(138,122,255,0.9) 70%, transparent 100%)",zIndex:25,pointerEvents:"none"}}),O.jsx("img",{src:"/dashboard-dark.png",alt:t("landing.screenshot.alt"),className:"block h-auto w-full object-cover",style:{position:"relative",zIndex:10},loading:"eager",decoding:"async"})]})})]})})]})}),O.jsx("section",{className:"border-y border-oai-gray-900 bg-oai-gray-950/50 py-12 lg:py-16",children:O.jsx("div",{className:"mx-auto max-w-6xl px-4 sm:px-6",children:O.jsxs("div",{className:"flex flex-col md:flex-row md:items-center justify-between gap-8",children:[O.jsx("p",{className:"text-sm font-semibold uppercase tracking-wider text-oai-gray-400 shrink-0",children:t("landing.v2.models.title")}),O.jsx("div",{className:"flex flex-wrap items-center gap-x-8 gap-y-6 opacity-60 hover:opacity-100 transition-opacity duration-500 grayscale hover:grayscale-0",children:v.map(w=>O.jsxs("div",{className:"flex items-center gap-2.5 transition-transform hover:-translate-y-0.5 duration-300",children:[O.jsx("img",{src:w.icon,alt:"",width:20,height:20,className:`h-5 w-5 object-contain ${w.id==="cursor"?"dark:invert":""}`,loading:"lazy"}),O.jsx("span",{className:"text-sm font-medium text-oai-gray-300",children:m[w.id]})]},w.id))})]})})}),O.jsx("section",{className:"py-20 lg:py-32",children:O.jsxs("div",{className:"mx-auto max-w-6xl px-4 sm:px-6 grid grid-cols-1 md:grid-cols-2 gap-16 lg:gap-24 items-start",children:[O.jsxs("div",{className:"max-w-md",children:[O.jsx("p",{className:"text-xs font-bold tracking-widest uppercase text-oai-brand-500 mb-4",children:t("landing.v2.compare.kicker")}),O.jsx("h2",{className:"text-3xl font-semibold tracking-tight text-white sm:text-4xl text-balance",children:t("landing.v2.compare.title")}),O.jsx("p",{className:"mt-6 text-lg leading-relaxed text-oai-gray-400",children:t("landing.v2.compare.subtitle")}),O.jsx("p",{className:"mt-6 text-base leading-relaxed text-oai-gray-500",children:t("landing.v2.distill.body")})]}),O.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-10",children:[O.jsxs("div",{className:"space-y-4",children:[O.jsx("h3",{className:"text-sm font-semibold uppercase tracking-wider text-white border-b border-oai-gray-800 pb-3",children:t("landing.v2.compare.with.title")}),O.jsxs("ul",{className:"space-y-3 text-sm text-oai-gray-400",children:[O.jsxs("li",{className:"flex gap-2",children:[O.jsx("span",{className:"text-oai-brand-500 shrink-0",children:"✦"}),O.jsx("span",{children:t("landing.v2.compare.with.p1")})]}),O.jsxs("li",{className:"flex gap-2",children:[O.jsx("span",{className:"text-oai-brand-500 shrink-0",children:"✦"}),O.jsx("span",{children:t("landing.v2.compare.with.p2")})]}),O.jsxs("li",{className:"flex gap-2",children:[O.jsx("span",{className:"text-oai-brand-500 shrink-0",children:"✦"}),O.jsx("span",{children:t("landing.v2.compare.with.p3")})]})]})]}),O.jsxs("div",{className:"space-y-4",children:[O.jsx("h3",{className:"text-sm font-semibold uppercase tracking-wider text-oai-gray-500 border-b border-oai-gray-800/50 pb-3",children:t("landing.v2.compare.without.title")}),O.jsxs("ul",{className:"space-y-3 text-sm text-oai-gray-500",children:[O.jsxs("li",{className:"flex gap-2",children:[O.jsx("span",{className:"opacity-50 shrink-0",children:"✕"}),O.jsx("span",{children:t("landing.v2.compare.without.p1")})]}),O.jsxs("li",{className:"flex gap-2",children:[O.jsx("span",{className:"opacity-50 shrink-0",children:"✕"}),O.jsx("span",{children:t("landing.v2.compare.without.p2")})]}),O.jsxs("li",{className:"flex gap-2",children:[O.jsx("span",{className:"opacity-50 shrink-0",children:"✕"}),O.jsx("span",{children:t("landing.v2.compare.without.p3")})]})]})]})]})]})})]}),O.jsx("footer",{className:"border-t border-oai-gray-900 bg-oai-gray-950 py-12",children:O.jsxs("div",{className:"mx-auto flex max-w-6xl flex-col items-center justify-between gap-6 px-4 sm:px-6 text-sm text-oai-gray-400 sm:flex-row",children:[O.jsx("p",{children:t("landing.v2.footer.line")}),O.jsxs("div",{className:"flex items-center gap-6",children:[O.jsx("a",{href:R1,className:"font-medium text-oai-gray-400 hover:text-white transition-colors",target:"_blank",rel:"noopener noreferrer",children:t("landing.v2.nav.github")}),f&&O.jsxs(po,{to:e,className:"font-medium text-oai-brand-500 hover:text-oai-brand-400 transition-colors",children:[t("landing.cta.primary")," →"]})]})]})})]})}function V7({prefersReducedMotion:t,screenshotMode:e}){return!(e||t)}function H7(){return k.useMemo(()=>typeof window>"u"||!window.matchMedia?!1:window.matchMedia("(prefers-reduced-motion: reduce)").matches,[])}function G7(t=0,e=!0){const[n,i]=k.useState(()=>!e);return k.useEffect(()=>{if(!e){i(!0);return}let r=null,s=null;const o=()=>i(!0);return typeof window<"u"&&"requestIdleCallback"in window?(s=window.requestIdleCallback(o,{timeout:t||200}),()=>{typeof window.cancelIdleCallback=="function"&&s!=null&&window.cancelIdleCallback(s)}):(r=window.setTimeout(o,t),()=>{r!=null&&window.clearTimeout(r)})},[t,e]),n}function j7({signInUrl:t,signUpUrl:e}){const n=qt("landing.handle.special"),i=qt("landing.handle.default");qt("landing.nav.login"),qt("landing.nav.signup");const[r,s]=k.useState(i),o=H7(),c=k.useMemo(()=>typeof window>"u"?!1:UC(window.location.search),[]),u=V7({prefersReducedMotion:o,screenshotMode:c});G7(250,u);const f="tokentracker.dashboard.from_landing.v1";k.useEffect(()=>{if(!(typeof window>"u"))try{window.sessionStorage.setItem(f,"1")}catch{}},[f]),k.useMemo(()=>qt("landing.handle.placeholder",{handle:n}),[n]),k.useMemo(()=>{const _=qt(r===n?"landing.rank.singularity":"landing.rank.unranked");return qt("landing.rank.expectation",{rank:_})},[r,n]);const h=qt("landing.install.command"),[p,m]=k.useState(!1),v=async()=>{await IV(h)&&(m(!0),window.setTimeout(()=>m(!1),2e3))};return O.jsx(z7,{copy:qt,reduceMotion:o,signInUrl:t,signUpUrl:e,installCommand:h,installCopied:p,onCopyInstallCommand:v})}function W7(t){const e=new URLSearchParams(t).get("next");return typeof e!="string"||e.length===0||!e.startsWith("/")||e.startsWith("//")?"/dashboard":e}const P1={google:"Google",github:"GitHub",microsoft:"Microsoft",discord:"Discord",linkedin:"LinkedIn",facebook:"Facebook",instagram:"Instagram",tiktok:"TikTok",apple:"Apple",x:"X",spotify:"Spotify"};function k1(t){const e=String(t||"").trim();return P1[e]?P1[e]:e.replace(/-/g," ")}function $7(){const t=Eh(),[e,n]=DL(),{enabled:i,loading:r,signedIn:s,refreshUser:o,signInWithPassword:c,signUp:u,signInWithOAuth:f,getPublicAuthConfig:h}=Ro(),p=k.useMemo(()=>W7(e.toString()),[e]),[m,v]=k.useState("signin"),[_,w]=k.useState(""),[y,x]=k.useState(""),[M,A]=k.useState(""),[T,D]=k.useState(!1),[I,U]=k.useState(null),[S,R]=k.useState(null),[V,F]=k.useState(!0),[j,Z]=k.useState([]),[H,q]=k.useState([]),[J,Q]=k.useState(8);k.useEffect(()=>{const we=e.get("insforge_status"),ne=e.get("insforge_type"),_e=e.get("insforge_error");we==="success"&&ne==="verify_email"?R(qt("login.verify_email_success")):we==="error"&&ne==="verify_email"&&_e&&R(qt("shared.error.prefix",{error:_e}))},[e]),k.useEffect(()=>{if(!i){F(!1);return}let we=!0;return(async()=>{const{data:ne,error:_e}=await h();we&&(_e||!ne?(Z(["google","github"]),q([])):(Z(Array.isArray(ne.oAuthProviders)?ne.oAuthProviders:[]),q(Array.isArray(ne.customOAuthProviders)?ne.customOAuthProviders:[]),typeof ne.passwordMinLength=="number"&&ne.passwordMinLength>0&&Q(ne.passwordMinLength)),F(!1))})(),()=>{we=!1}},[i,h]),k.useEffect(()=>{if(!(!i||r)&&s){if(W){window.location.href="/auth/native-callback";return}t(p,{replace:!0})}},[i,r,s,t,p,W]),k.useEffect(()=>{i&&o()},[i,o]);const W=k.useMemo(()=>e.get("native")==="1",[e]),X=k.useMemo(()=>e.get("provider")||null,[e]),K=k.useMemo(()=>typeof window>"u"||W?"":`${window.location.origin}/`,[W]),B=k.useMemo(()=>typeof window>"u"?"":`${window.location.origin}/`,[]),ie=k.useCallback(async we=>{we.preventDefault(),U(null),D(!0);try{if(m==="signup"){const{data:_e,error:Se}=await u({email:_.trim(),password:y,name:M.trim()||void 0,redirectTo:B});if(Se){U(Se.message||String(Se));return}if(_e?.requireEmailVerification){R(qt("login.verify_email_pending")),v("signin");return}t(p,{replace:!0});return}const{error:ne}=await c({email:_.trim(),password:y});if(ne){U(ne.message||String(ne));return}t(p,{replace:!0})}finally{D(!1)}},[m,_,y,M,u,c,t,p,B]),ve=k.useCallback(async we=>{U(null),D(!0);try{const{error:ne}=await f(we,K);ne&&U(ne.message||String(ne))}finally{D(!1)}},[f,K]);k.useEffect(()=>{if(W&&typeof window<"u")try{window.sessionStorage.setItem("tokentracker_native_login","1")}catch{}},[W]),k.useEffect(()=>{if(!i||r||s||V||!W||!X)return;[...j,...H].includes(X)&&ve(X)},[i,r,s,V,W,X,j,H,ve]);const Ce=k.useCallback(()=>{n(we=>{const ne=new URLSearchParams(we);return ne.delete("insforge_status"),ne.delete("insforge_type"),ne.delete("insforge_error"),ne},{replace:!0}),R(null)},[n]);return i?O.jsxs("div",{className:"min-h-screen bg-oai-gray-950 text-oai-white font-oai antialiased dark flex flex-col",children:[O.jsx("header",{className:"border-b border-oai-gray-900 px-4 sm:px-6 h-16 flex items-center justify-between",children:O.jsx(po,{to:"/",className:"text-sm font-medium text-oai-gray-400 hover:text-white no-underline focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-oai-brand-500 rounded",children:qt("login.back_home")})}),O.jsx("main",{className:"flex-1 flex items-center justify-center px-4 py-12",children:O.jsxs("div",{className:"w-full max-w-md space-y-8",children:[O.jsxs("div",{className:"text-center",children:[O.jsx("h1",{className:"text-2xl font-semibold text-white tracking-tight",children:qt("login.title")}),O.jsx("p",{className:"mt-2 text-sm text-oai-gray-500",children:qt("login.subtitle")})]}),S?O.jsxs("div",{className:"rounded-lg border border-oai-gray-800 bg-oai-gray-900/50 px-4 py-3 text-sm text-oai-gray-300 flex justify-between gap-3 items-start",role:"status",children:[O.jsx("span",{children:S}),O.jsx("button",{type:"button",onClick:Ce,className:"shrink-0 text-oai-gray-500 hover:text-white text-xs",children:qt("login.dismiss")})]}):null,I?O.jsx("p",{className:"text-sm text-red-400",role:"alert",children:qt("shared.error.prefix",{error:I})}):null,O.jsx("div",{className:"space-y-3",children:V?O.jsx("div",{className:"h-11 rounded-lg bg-oai-gray-900 animate-pulse","aria-hidden":!0}):O.jsxs(O.Fragment,{children:[j.map(we=>O.jsx("button",{type:"button",disabled:T,onClick:()=>ve(we),className:Si("w-full h-11 rounded-lg border border-oai-gray-700 bg-oai-gray-900 text-sm font-medium text-white","hover:bg-oai-gray-800 transition-colors disabled:opacity-50"),children:qt("login.oauth.continue",{provider:k1(we)})},we)),H.map(we=>O.jsx("button",{type:"button",disabled:T,onClick:()=>ve(we),className:Si("w-full h-11 rounded-lg border border-oai-gray-700 bg-oai-gray-900 text-sm font-medium text-white","hover:bg-oai-gray-800 transition-colors disabled:opacity-50"),children:qt("login.oauth.continue",{provider:k1(we)})},we))]})}),O.jsxs("div",{className:"relative",children:[O.jsx("div",{className:"absolute inset-0 flex items-center","aria-hidden":!0,children:O.jsx("span",{className:"w-full border-t border-oai-gray-800"})}),O.jsx("div",{className:"relative flex justify-center text-xs uppercase tracking-wider",children:O.jsx("span",{className:"bg-oai-gray-950 px-3 text-oai-gray-600",children:qt("login.divider")})})]}),O.jsxs("div",{className:"flex rounded-lg border border-oai-gray-800 p-0.5 bg-oai-gray-900/50",children:[O.jsx("button",{type:"button",className:Si("flex-1 py-2 text-sm font-medium rounded-md transition-colors",m==="signin"?"bg-oai-gray-800 text-white":"text-oai-gray-500 hover:text-oai-gray-300"),onClick:()=>{v("signin"),U(null)},children:qt("login.tab.sign_in")}),O.jsx("button",{type:"button",className:Si("flex-1 py-2 text-sm font-medium rounded-md transition-colors",m==="signup"?"bg-oai-gray-800 text-white":"text-oai-gray-500 hover:text-oai-gray-300"),onClick:()=>{v("signup"),U(null)},children:qt("login.tab.sign_up")})]}),O.jsxs("form",{onSubmit:ie,className:"space-y-4",children:[m==="signup"?O.jsxs("div",{children:[O.jsx("label",{htmlFor:"login-name",className:"block text-xs font-medium text-oai-gray-500 mb-1",children:qt("login.field.name")}),O.jsx("input",{id:"login-name",type:"text",autoComplete:"name",value:M,onChange:we=>A(we.target.value),className:"w-full h-11 rounded-lg border border-oai-gray-800 bg-oai-gray-900 px-3 text-sm text-white placeholder-oai-gray-600 focus:outline-none focus:ring-2 focus:ring-oai-brand-500",placeholder:qt("login.field.name_placeholder")})]}):null,O.jsxs("div",{children:[O.jsx("label",{htmlFor:"login-email",className:"block text-xs font-medium text-oai-gray-500 mb-1",children:qt("login.field.email")}),O.jsx("input",{id:"login-email",type:"email",autoComplete:"email",required:!0,value:_,onChange:we=>w(we.target.value),className:"w-full h-11 rounded-lg border border-oai-gray-800 bg-oai-gray-900 px-3 text-sm text-white placeholder-oai-gray-600 focus:outline-none focus:ring-2 focus:ring-oai-brand-500"})]}),O.jsxs("div",{children:[O.jsx("label",{htmlFor:"login-password",className:"block text-xs font-medium text-oai-gray-500 mb-1",children:qt("login.field.password")}),O.jsx("input",{id:"login-password",type:"password",autoComplete:m==="signup"?"new-password":"current-password",required:!0,minLength:m==="signup"?J:void 0,value:y,onChange:we=>x(we.target.value),className:"w-full h-11 rounded-lg border border-oai-gray-800 bg-oai-gray-900 px-3 text-sm text-white placeholder-oai-gray-600 focus:outline-none focus:ring-2 focus:ring-oai-brand-500"}),m==="signup"?O.jsx("p",{className:"mt-1 text-xs text-oai-gray-600",children:qt("login.password_hint",{min:String(J)})}):null]}),O.jsx("button",{type:"submit",disabled:T||r,className:"w-full h-11 rounded-lg bg-white text-oai-gray-950 text-sm font-semibold hover:bg-oai-gray-100 transition-colors disabled:opacity-50",children:qt(m==="signup"?"login.submit.sign_up":"login.submit.sign_in")})]})]})})]}):O.jsxs("div",{className:"min-h-screen bg-oai-gray-950 text-oai-white font-oai antialiased dark flex flex-col",children:[O.jsx("header",{className:"border-b border-oai-gray-900 px-4 sm:px-6 py-4",children:O.jsx(po,{to:"/",className:"text-sm font-medium text-oai-gray-400 hover:text-white no-underline",children:qt("login.back_home")})}),O.jsx("main",{className:"flex-1 flex items-center justify-center px-4",children:O.jsx("p",{className:"text-oai-gray-400 text-center max-w-md",children:qt("login.cloud_only")})})]})}const X7=typeof window<"u"?window.location.search:"",L1=new URLSearchParams(X7),xf=L1.get("insforge_code")||L1.get("code")||null;function q7(){const{loading:t,signedIn:e}=Ro(),n=Eh(),[i,r]=k.useState("processing"),[s,o]=k.useState(null),c=k.useRef(!1);return k.useEffect(()=>{!xf||c.current||(c.current=!0,(async()=>{try{const f=await(await fetch("/api/auth-bridge/verifier")).json();o(!!f?.native)}catch{o(!1)}})())},[]),k.useEffect(()=>{if(s!==!0||!xf)return;r("redirecting");const u=setTimeout(()=>{window.location.href=`tokentracker://auth/callback?insforge_code=${encodeURIComponent(xf)}`},200);return()=>clearTimeout(u)},[s]),k.useEffect(()=>{if(s!==!1||t)return;if(e){n("/dashboard",{replace:!0});return}const u=setTimeout(()=>{e||r("failed")},5e3);return()=>clearTimeout(u)},[s,t,e,n]),k.useEffect(()=>{if(!xf&&s===null){const u=setTimeout(()=>r("failed"),3e3);return()=>clearTimeout(u)}},[s]),i==="processing"&&s!==!0&&(s===null||s===!1&&t)?O.jsx("div",{className:"min-h-screen bg-oai-gray-950"}):O.jsx("div",{className:"min-h-screen bg-oai-gray-950 text-white font-oai antialiased dark flex items-center justify-center",children:O.jsxs("div",{className:"text-center space-y-4 max-w-sm px-4",children:[i==="processing"&&O.jsxs(O.Fragment,{children:[O.jsx("div",{className:"w-8 h-8 border-2 border-oai-gray-600 border-t-white rounded-full animate-spin mx-auto"}),O.jsx("p",{className:"text-oai-gray-400 text-sm",children:"Processing…"})]}),i==="redirecting"&&O.jsxs(O.Fragment,{children:[O.jsx("div",{className:"w-12 h-12 mx-auto rounded-full bg-green-500/15 flex items-center justify-center",children:O.jsx("svg",{className:"w-6 h-6 text-green-400",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2.5",strokeLinecap:"round",strokeLinejoin:"round",children:O.jsx("path",{d:"M20 6 9 17l-5-5"})})}),O.jsx("p",{className:"text-white text-sm font-medium",children:"Signed in successfully"}),O.jsx("p",{className:"text-oai-gray-500 text-xs",children:"Returning to TokenTracker…"})]}),i==="failed"&&O.jsxs("div",{className:"space-y-3",children:[O.jsx("p",{className:"text-oai-gray-300 text-sm",children:"Sign-in incomplete. Please try again."}),O.jsx("button",{type:"button",onClick:()=>window.close(),className:"px-4 py-2 rounded-lg bg-oai-gray-800 text-sm text-white hover:bg-oai-gray-700 transition-colors",children:"Close this page"})]})]})})}const Y7=jl.lazy(()=>ly(()=>import("./DashboardPage-vIxKP44Z.js"),__vite__mapDeps([0,1])).then(t=>({default:t.DashboardPage}))),K7=jl.lazy(()=>ly(()=>import("./LeaderboardPage-VXJBiwkB.js"),__vite__mapDeps([2,3,1])).then(t=>({default:t.LeaderboardPage}))),Z7=jl.lazy(()=>ly(()=>import("./LeaderboardProfilePage-DPeOBsNk.js"),__vite__mapDeps([4,3,1])).then(t=>({default:t.LeaderboardProfilePage})));function J7(){const t=zr(),e=Ro();DV();const n=_r(),i=k.useMemo(()=>typeof window>"u"?!1:UC(window.location.search),[]),r=t?.pathname||"/",s=new URL(window.location.href),o=s.pathname.replace(/\/+$/,"")||"/",u=o.match(/^\/share\/([^/?#]+)$/i)?.[1]||null,f=s.searchParams.get("token")||null,h=u||f,p=o==="/share"||o==="/share.html"||o.startsWith("/share/"),m=typeof window<"u"&&(window.location.hostname==="localhost"||window.location.hostname==="127.0.0.1"),v=r.replace(/\/+$/,"")||"/",_=v.match(/^\/leaderboard\/u\/([^/]+)$/i),w=_?_[1]:null,y=v==="/leaderboard"||!!w,x=!!(e.enabled&&e.signedIn),M=m||x,A=!1,T=Qz(),D=k.useMemo(()=>!e.enabled||!x?null:{getAccessToken:()=>e.getAccessToken()},[e,x]);let I=m||n||i?"dashboard":"landing";v==="/landing"&&(I="landing"),v==="/dashboard"&&(I="dashboard"),y&&(I="dashboard");const U=w?Z7:v==="/leaderboard"?K7:Y7,S=O.jsx("div",{className:"min-h-screen bg-oai-white dark:bg-[#050505]"});let R=null;return v==="/auth/callback"||v==="/auth/native-callback"?R=O.jsx(q7,{}):v==="/login"?R=O.jsx($7,{}):I==="landing"?R=O.jsx(j7,{signInUrl:"/login",signUpUrl:"/login"}):R=O.jsx(k.Suspense,{fallback:S,children:O.jsx(U,{baseUrl:T,auth:D,signedIn:M,sessionSoftExpired:A,signOut:()=>e.enabled?e.signOut():Promise.resolve(),publicMode:p,publicToken:h,userId:w,signInUrl:"/login",signUpUrl:"/login"})}),O.jsx(OU,{children:O.jsx(HU,{children:O.jsxs(GU,{children:[R,O.jsx(Zz,{}),O.jsx(OI,{}),O.jsx(YI,{})]})})})}const Q7=TL([{path:"*",element:O.jsx(J7,{})}]);p2.createRoot(document.getElementById("root")).render(O.jsx(jl.StrictMode,{children:O.jsx(EI,{children:O.jsx(zL,{router:Q7})})}));export{nU as $,k$ as A,kC as B,qt as C,O as D,fy as E,oU as F,wT as G,Nv as H,SU as I,ch as J,OS as K,IS as L,zy as M,u$ as N,dy as O,Sl as P,uy as Q,N1 as R,BL as S,pT as T,TU as U,BS as V,Xl as W,yT as X,US as Y,mT as Z,KI as _,hi as a,tU as a0,ZI as a1,c0 as a2,vT as a3,o$ as a4,eU as a5,l$ as a6,gT as a7,c$ as a8,WV as a9,zr as aA,Eh as aB,f$ as aC,aT as aD,Hd as aE,T$ as aF,BV as aG,FV as aH,PV as aI,A$ as aJ,vI as aK,C$ as aL,BU as aM,po as aa,OV as ab,V5 as ac,Is as ad,gU as ae,jl as af,b$ as ag,x$ as ah,AT as ai,Ro as aj,I0 as ak,UC as al,ro as am,R$ as an,h$ as ao,p$ as ap,S$ as aq,sV as ar,m$ as as,g$ as at,P$ as au,_$ as av,ly as aw,w$ as ax,IV as ay,Si as az,CT as b,ka as c,iw as d,Fh as e,Tn as f,LC as g,_r as h,BF as i,a$ as j,SI as k,U$ as l,Ol as m,lV as n,cV as o,L$ as p,y$ as q,k as r,M$ as s,D$ as t,py as u,N$ as v,v$ as w,kn as x,E$ as y,I$ as z};
@@ -0,0 +1 @@
1
+ <svg height="1em" style="flex:none;line-height:1" viewBox="0 0 24 24" width="1em" xmlns="http://www.w3.org/2000/svg"><title>Antigravity</title><mask height="23" id="lobe-icons-antigravity-fill-0" maskUnits="userSpaceOnUse" width="24" x="0" y="1"><path d="M21.751 22.607c1.34 1.005 3.35.335 1.508-1.508C17.73 15.74 18.904 1 12.037 1 5.17 1 6.342 15.74.815 21.1c-2.01 2.009.167 2.511 1.507 1.506 5.192-3.517 4.857-9.714 9.715-9.714 4.857 0 4.522 6.197 9.714 9.715z" fill="#fff"></path></mask><g mask="url(#lobe-icons-antigravity-fill-0)"><g filter="url(#lobe-icons-antigravity-fill-1)"><path d="M-1.018-3.992c-.408 3.591 2.686 6.89 6.91 7.37 4.225.48 7.98-2.043 8.387-5.633.408-3.59-2.686-6.89-6.91-7.37-4.225-.479-7.98 2.043-8.387 5.633z" fill="#FFE432"></path></g><g filter="url(#lobe-icons-antigravity-fill-2)"><path d="M15.269 7.747c1.058 4.557 5.691 7.374 10.348 6.293 4.657-1.082 7.575-5.653 6.516-10.21-1.058-4.556-5.691-7.374-10.348-6.292-4.657 1.082-7.575 5.653-6.516 10.21z" fill="#FC413D"></path></g><g filter="url(#lobe-icons-antigravity-fill-3)"><path d="M-12.443 10.804c1.338 4.703 7.36 7.11 13.453 5.378 6.092-1.733 9.947-6.95 8.61-11.652C8.282-.173 2.26-2.58-3.833-.848-9.925.884-13.78 6.1-12.443 10.804z" fill="#00B95C"></path></g><g filter="url(#lobe-icons-antigravity-fill-4)"><path d="M-12.443 10.804c1.338 4.703 7.36 7.11 13.453 5.378 6.092-1.733 9.947-6.95 8.61-11.652C8.282-.173 2.26-2.58-3.833-.848-9.925.884-13.78 6.1-12.443 10.804z" fill="#00B95C"></path></g><g filter="url(#lobe-icons-antigravity-fill-5)"><path d="M-7.608 14.703c3.352 3.424 9.126 3.208 12.896-.483 3.77-3.69 4.108-9.459.756-12.883C2.69-2.087-3.083-1.871-6.853 1.82c-3.77 3.69-4.108 9.458-.755 12.883z" fill="#00B95C"></path></g><g filter="url(#lobe-icons-antigravity-fill-6)"><path d="M9.932 27.617c1.04 4.482 5.384 7.303 9.7 6.3 4.316-1.002 6.971-5.448 5.93-9.93-1.04-4.483-5.384-7.304-9.7-6.301-4.316 1.002-6.971 5.448-5.93 9.93z" fill="#3186FF"></path></g><g filter="url(#lobe-icons-antigravity-fill-7)"><path d="M2.572-8.185C.392-3.329 2.778 2.472 7.9 4.771c5.122 2.3 11.042.227 13.222-4.63 2.18-4.855-.205-10.656-5.327-12.955-5.122-2.3-11.042-.227-13.222 4.63z" fill="#FBBC04"></path></g><g filter="url(#lobe-icons-antigravity-fill-8)"><path d="M-3.267 38.686c-5.277-2.072 3.742-19.117 5.984-24.83 2.243-5.712 8.34-8.664 13.616-6.592 5.278 2.071 11.533 13.482 9.29 19.195-2.242 5.713-23.613 14.298-28.89 12.227z" fill="#3186FF"></path></g><g filter="url(#lobe-icons-antigravity-fill-9)"><path d="M28.71 17.471c-1.413 1.649-5.1.808-8.236-1.878-3.135-2.687-4.531-6.201-3.118-7.85 1.412-1.649 5.1-.808 8.235 1.878s4.532 6.2 3.119 7.85z" fill="#749BFF"></path></g><g filter="url(#lobe-icons-antigravity-fill-10)"><path d="M18.163 9.077c5.81 3.93 12.502 4.19 14.946.577 2.443-3.612-.287-9.727-6.098-13.658-5.81-3.931-12.502-4.19-14.946-.577-2.443 3.612.287 9.727 6.098 13.658z" fill="#FC413D"></path></g><g filter="url(#lobe-icons-antigravity-fill-11)"><path d="M-.915 2.684c-1.44 3.473-.97 6.967 1.05 7.804 2.02.837 4.824-1.3 6.264-4.772 1.44-3.473.97-6.967-1.05-7.804-2.02-.837-4.824 1.3-6.264 4.772z" fill="#FFEE48"></path></g></g><defs><filter color-interpolation-filters="sRGB" filterUnits="userSpaceOnUse" height="17.587" id="lobe-icons-antigravity-fill-1" width="19.838" x="-3.288" y="-11.917"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"></feBlend><feGaussianBlur result="effect1_foregroundBlur_977_115" stdDeviation="1.117"></feGaussianBlur></filter><filter color-interpolation-filters="sRGB" filterUnits="userSpaceOnUse" height="38.565" id="lobe-icons-antigravity-fill-2" width="38.9" x="4.251" y="-13.493"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"></feBlend><feGaussianBlur result="effect1_foregroundBlur_977_115" stdDeviation="5.4"></feGaussianBlur></filter><filter color-interpolation-filters="sRGB" filterUnits="userSpaceOnUse" height="36.517" id="lobe-icons-antigravity-fill-3" width="40.955" x="-21.889" y="-10.592"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"></feBlend><feGaussianBlur result="effect1_foregroundBlur_977_115" stdDeviation="4.591"></feGaussianBlur></filter><filter color-interpolation-filters="sRGB" filterUnits="userSpaceOnUse" height="36.517" id="lobe-icons-antigravity-fill-4" width="40.955" x="-21.889" y="-10.592"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"></feBlend><feGaussianBlur result="effect1_foregroundBlur_977_115" stdDeviation="4.591"></feGaussianBlur></filter><filter color-interpolation-filters="sRGB" filterUnits="userSpaceOnUse" height="36.595" id="lobe-icons-antigravity-fill-5" width="36.632" x="-19.099" y="-10.278"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"></feBlend><feGaussianBlur result="effect1_foregroundBlur_977_115" stdDeviation="4.591"></feGaussianBlur></filter><filter color-interpolation-filters="sRGB" filterUnits="userSpaceOnUse" height="34.087" id="lobe-icons-antigravity-fill-6" width="33.533" x=".981" y="8.758"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"></feBlend><feGaussianBlur result="effect1_foregroundBlur_977_115" stdDeviation="4.363"></feGaussianBlur></filter><filter color-interpolation-filters="sRGB" filterUnits="userSpaceOnUse" height="35.276" id="lobe-icons-antigravity-fill-7" width="35.978" x="-6.143" y="-21.659"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"></feBlend><feGaussianBlur result="effect1_foregroundBlur_977_115" stdDeviation="3.954"></feGaussianBlur></filter><filter color-interpolation-filters="sRGB" filterUnits="userSpaceOnUse" height="46.523" id="lobe-icons-antigravity-fill-8" width="45.114" x="-11.96" y="-.46"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"></feBlend><feGaussianBlur result="effect1_foregroundBlur_977_115" stdDeviation="3.531"></feGaussianBlur></filter><filter color-interpolation-filters="sRGB" filterUnits="userSpaceOnUse" height="24.054" id="lobe-icons-antigravity-fill-9" width="25.094" x="10.485" y=".58"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"></feBlend><feGaussianBlur result="effect1_foregroundBlur_977_115" stdDeviation="3.159"></feGaussianBlur></filter><filter color-interpolation-filters="sRGB" filterUnits="userSpaceOnUse" height="30.007" id="lobe-icons-antigravity-fill-10" width="33.508" x="5.833" y="-12.467"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"></feBlend><feGaussianBlur result="effect1_foregroundBlur_977_115" stdDeviation="2.669"></feGaussianBlur></filter><filter color-interpolation-filters="sRGB" filterUnits="userSpaceOnUse" height="26.151" id="lobe-icons-antigravity-fill-11" width="22.194" x="-8.355" y="-8.876"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"></feBlend><feGaussianBlur result="effect1_foregroundBlur_977_115" stdDeviation="3.303"></feGaussianBlur></filter></defs></svg>
@@ -1,3 +1 @@
1
- <svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
2
- <path fill="#3B82F6" d="M11.503.131 1.891 5.678a.84.84 0 0 0-.42.726v11.188c0 .3.162.575.42.724l9.609 5.55a1 1 0 0 0 .998 0l9.61-5.55a.84.84 0 0 0 .42-.724V6.404a.84.84 0 0 0-.42-.726L12.497.131a1.01 1.01 0 0 0-.996 0M2.657 6.338h18.55c.263 0 .43.287.297.515L12.23 22.918c-.062.107-.229.064-.229-.06V12.335a.59.59 0 0 0-.295-.51l-9.11-5.257c-.109-.063-.064-.23.061-.23"/>
3
- </svg>
1
+ <svg fill="currentColor" fill-rule="evenodd" height="1em" style="flex:none;line-height:1" viewBox="0 0 24 24" width="1em" xmlns="http://www.w3.org/2000/svg"><title>Cursor</title><path d="M22.106 5.68L12.5.135a.998.998 0 00-.998 0L1.893 5.68a.84.84 0 00-.419.726v11.186c0 .3.16.577.42.727l9.607 5.547a.999.999 0 00.998 0l9.608-5.547a.84.84 0 00.42-.727V6.407a.84.84 0 00-.42-.726zm-.603 1.176L12.228 22.92c-.063.108-.228.064-.228-.061V12.34a.59.59 0 00-.295-.51l-9.11-5.26c-.107-.062-.063-.228.062-.228h18.55c.264 0 .428.286.296.514z"></path></svg>
@@ -1,20 +1 @@
1
- <svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
2
- <path d="M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z" fill="#3186FF" />
3
- <path d="M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z" fill="url(#gemini-a)" />
4
- <path d="M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z" fill="url(#gemini-b)" />
5
- <path d="M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z" fill="url(#gemini-c)" />
6
- <defs>
7
- <linearGradient gradientUnits="userSpaceOnUse" id="gemini-a" x1="7" x2="11" y1="15.5" y2="12">
8
- <stop stop-color="#08B962" />
9
- <stop offset="1" stop-color="#08B962" stop-opacity="0" />
10
- </linearGradient>
11
- <linearGradient gradientUnits="userSpaceOnUse" id="gemini-b" x1="8" x2="11.5" y1="5.5" y2="11">
12
- <stop stop-color="#F94543" />
13
- <stop offset="1" stop-color="#F94543" stop-opacity="0" />
14
- </linearGradient>
15
- <linearGradient gradientUnits="userSpaceOnUse" id="gemini-c" x1="3.5" x2="17.5" y1="13.5" y2="12">
16
- <stop stop-color="#FABC12" />
17
- <stop offset=".46" stop-color="#FABC12" stop-opacity="0" />
18
- </linearGradient>
19
- </defs>
20
- </svg>
1
+ <svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 65 65"><mask id="maskme" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="0" y="0" width="65" height="65"><path d="M32.447 0c.68 0 1.273.465 1.439 1.125a38.904 38.904 0 001.999 5.905c2.152 5 5.105 9.376 8.854 13.125 3.751 3.75 8.126 6.703 13.125 8.855a38.98 38.98 0 005.906 1.999c.66.166 1.124.758 1.124 1.438 0 .68-.464 1.273-1.125 1.439a38.902 38.902 0 00-5.905 1.999c-5 2.152-9.375 5.105-13.125 8.854-3.749 3.751-6.702 8.126-8.854 13.125a38.973 38.973 0 00-2 5.906 1.485 1.485 0 01-1.438 1.124c-.68 0-1.272-.464-1.438-1.125a38.913 38.913 0 00-2-5.905c-2.151-5-5.103-9.375-8.854-13.125-3.75-3.749-8.125-6.702-13.125-8.854a38.973 38.973 0 00-5.905-2A1.485 1.485 0 010 32.448c0-.68.465-1.272 1.125-1.438a38.903 38.903 0 005.905-2c5-2.151 9.376-5.104 13.125-8.854 3.75-3.749 6.703-8.125 8.855-13.125a38.972 38.972 0 001.999-5.905A1.485 1.485 0 0132.447 0z" fill="#000"/><path d="M32.447 0c.68 0 1.273.465 1.439 1.125a38.904 38.904 0 001.999 5.905c2.152 5 5.105 9.376 8.854 13.125 3.751 3.75 8.126 6.703 13.125 8.855a38.98 38.98 0 005.906 1.999c.66.166 1.124.758 1.124 1.438 0 .68-.464 1.273-1.125 1.439a38.902 38.902 0 00-5.905 1.999c-5 2.152-9.375 5.105-13.125 8.854-3.749 3.751-6.702 8.126-8.854 13.125a38.973 38.973 0 00-2 5.906 1.485 1.485 0 01-1.438 1.124c-.68 0-1.272-.464-1.438-1.125a38.913 38.913 0 00-2-5.905c-2.151-5-5.103-9.375-8.854-13.125-3.75-3.749-8.125-6.702-13.125-8.854a38.973 38.973 0 00-5.905-2A1.485 1.485 0 010 32.448c0-.68.465-1.272 1.125-1.438a38.903 38.903 0 005.905-2c5-2.151 9.376-5.104 13.125-8.854 3.75-3.749 6.703-8.125 8.855-13.125a38.972 38.972 0 001.999-5.905A1.485 1.485 0 0132.447 0z" fill="url(#prefix__paint0_linear_2001_67)"/></mask><g mask="url(#maskme)"><g filter="url(#prefix__filter0_f_2001_67)"><path d="M-5.859 50.734c7.498 2.663 16.116-2.33 19.249-11.152 3.133-8.821-.406-18.131-7.904-20.794-7.498-2.663-16.116 2.33-19.25 11.151-3.132 8.822.407 18.132 7.905 20.795z" fill="#FFE432"/></g><g filter="url(#prefix__filter1_f_2001_67)"><path d="M27.433 21.649c10.3 0 18.651-8.535 18.651-19.062 0-10.528-8.35-19.062-18.651-19.062S8.78-7.94 8.78 2.587c0 10.527 8.35 19.062 18.652 19.062z" fill="#FC413D"/></g><g filter="url(#prefix__filter2_f_2001_67)"><path d="M20.184 82.608c10.753-.525 18.918-12.244 18.237-26.174-.68-13.93-9.95-24.797-20.703-24.271C6.965 32.689-1.2 44.407-.519 58.337c.681 13.93 9.95 24.797 20.703 24.271z" fill="#00B95C"/></g><g filter="url(#prefix__filter3_f_2001_67)"><path d="M20.184 82.608c10.753-.525 18.918-12.244 18.237-26.174-.68-13.93-9.95-24.797-20.703-24.271C6.965 32.689-1.2 44.407-.519 58.337c.681 13.93 9.95 24.797 20.703 24.271z" fill="#00B95C"/></g><g filter="url(#prefix__filter4_f_2001_67)"><path d="M30.954 74.181c9.014-5.485 11.427-17.976 5.389-27.9-6.038-9.925-18.241-13.524-27.256-8.04-9.015 5.486-11.428 17.977-5.39 27.902 6.04 9.924 18.242 13.523 27.257 8.038z" fill="#00B95C"/></g><g filter="url(#prefix__filter5_f_2001_67)"><path d="M67.391 42.993c10.132 0 18.346-7.91 18.346-17.666 0-9.757-8.214-17.667-18.346-17.667s-18.346 7.91-18.346 17.667c0 9.757 8.214 17.666 18.346 17.666z" fill="#3186FF"/></g><g filter="url(#prefix__filter6_f_2001_67)"><path d="M-13.065 40.944c9.33 7.094 22.959 4.869 30.442-4.972 7.483-9.84 5.987-23.569-3.343-30.663C4.704-1.786-8.924.439-16.408 10.28c-7.483 9.84-5.986 23.57 3.343 30.664z" fill="#FBBC04"/></g><g filter="url(#prefix__filter7_f_2001_67)"><path d="M34.74 51.43c11.135 7.656 25.896 5.524 32.968-4.764 7.073-10.287 3.779-24.832-7.357-32.488C49.215 6.52 34.455 8.654 27.382 18.94c-7.072 10.288-3.779 24.833 7.357 32.49z" fill="#3186FF"/></g><g filter="url(#prefix__filter8_f_2001_67)"><path d="M54.984-2.336c2.833 3.852-.808 11.34-8.131 16.727-7.324 5.387-15.557 6.631-18.39 2.78-2.833-3.853.807-11.342 8.13-16.728 7.324-5.387 15.558-6.631 18.39-2.78z" fill="#749BFF"/></g><g filter="url(#prefix__filter9_f_2001_67)"><path d="M31.727 16.104C43.053 5.598 46.94-8.626 40.41-15.666c-6.53-7.04-21.006-4.232-32.332 6.274s-15.214 24.73-8.683 31.77c6.53 7.04 21.006 4.232 32.332-6.274z" fill="#FC413D"/></g><g filter="url(#prefix__filter10_f_2001_67)"><path d="M8.51 53.838c6.732 4.818 14.46 5.55 17.262 1.636 2.802-3.915-.384-10.994-7.116-15.812-6.731-4.818-14.46-5.55-17.261-1.636-2.802 3.915.383 10.994 7.115 15.812z" fill="#FFEE48"/></g></g><defs><filter id="prefix__filter0_f_2001_67" x="-19.824" y="13.152" width="39.274" height="43.217" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"/><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"/><feGaussianBlur stdDeviation="2.46" result="effect1_foregroundBlur_2001_67"/></filter><filter id="prefix__filter1_f_2001_67" x="-15.001" y="-40.257" width="84.868" height="85.688" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"/><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"/><feGaussianBlur stdDeviation="11.891" result="effect1_foregroundBlur_2001_67"/></filter><filter id="prefix__filter2_f_2001_67" x="-20.776" y="11.927" width="79.454" height="90.916" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"/><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"/><feGaussianBlur stdDeviation="10.109" result="effect1_foregroundBlur_2001_67"/></filter><filter id="prefix__filter3_f_2001_67" x="-20.776" y="11.927" width="79.454" height="90.916" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"/><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"/><feGaussianBlur stdDeviation="10.109" result="effect1_foregroundBlur_2001_67"/></filter><filter id="prefix__filter4_f_2001_67" x="-19.845" y="15.459" width="79.731" height="81.505" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"/><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"/><feGaussianBlur stdDeviation="10.109" result="effect1_foregroundBlur_2001_67"/></filter><filter id="prefix__filter5_f_2001_67" x="29.832" y="-11.552" width="75.117" height="73.758" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"/><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"/><feGaussianBlur stdDeviation="9.606" result="effect1_foregroundBlur_2001_67"/></filter><filter id="prefix__filter6_f_2001_67" x="-38.583" y="-16.253" width="78.135" height="78.758" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"/><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"/><feGaussianBlur stdDeviation="8.706" result="effect1_foregroundBlur_2001_67"/></filter><filter id="prefix__filter7_f_2001_67" x="8.107" y="-5.966" width="78.877" height="77.539" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"/><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"/><feGaussianBlur stdDeviation="7.775" result="effect1_foregroundBlur_2001_67"/></filter><filter id="prefix__filter8_f_2001_67" x="13.587" y="-18.488" width="56.272" height="51.81" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"/><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"/><feGaussianBlur stdDeviation="6.957" result="effect1_foregroundBlur_2001_67"/></filter><filter id="prefix__filter9_f_2001_67" x="-15.526" y="-31.297" width="70.856" height="69.306" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"/><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"/><feGaussianBlur stdDeviation="5.876" result="effect1_foregroundBlur_2001_67"/></filter><filter id="prefix__filter10_f_2001_67" x="-14.168" y="20.964" width="55.501" height="51.571" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"/><feBlend in="SourceGraphic" in2="BackgroundImageFix" result="shape"/><feGaussianBlur stdDeviation="7.273" result="effect1_foregroundBlur_2001_67"/></filter><linearGradient id="prefix__paint0_linear_2001_67" x1="18.447" y1="43.42" x2="52.153" y2="15.004" gradientUnits="userSpaceOnUse"><stop stop-color="#4893FC"/><stop offset=".27" stop-color="#4893FC"/><stop offset=".777" stop-color="#969DFF"/><stop offset="1" stop-color="#BD99FE"/></linearGradient></defs></svg>
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 -1 22 28" fill="currentColor" fill-rule="evenodd"><path d="M4.125 20.149c-2.69 5.959 3.036 7.453 7.26 3.966 1.24 3.91 5.898.993 7.569-2.036 3.682-6.678 2.195-13.49 1.813-14.895-2.617-9.582-15.699-9.592-17.95.049-.526 1.687-.535 3.606-.833 5.598-.15 1.005-.256 1.646-.645 2.703-.223.607-.53 1.147-1.014 2.056-.75 1.412-.434 4.138 3.434 2.724v.001ZM11.895 11.332c-1.073 0-1.234-1.283-1.234-2.048 0-.69.124-1.239.358-1.586a1 1 0 0 1 .876-.462c.375 0 .697.158.924.47.259.354.395.9.395 1.578 0 1.283-.493 2.048-1.319 2.048Zm4.416 0c-1.073 0-1.234-1.283-1.234-2.048 0-.69.124-1.239.358-1.586a1 1 0 0 1 .876-.462c.375 0 .697.158.924.47.259.354.396.9.396 1.578 0 1.283-.494 2.048-1.32 2.048Z"/></svg>
@@ -119,8 +119,8 @@
119
119
  ]
120
120
  }
121
121
  </script>
122
- <script type="module" crossorigin src="/assets/main-DFuYMEVg.js"></script>
123
- <link rel="stylesheet" crossorigin href="/assets/main-y3ZJfQaO.css">
122
+ <script type="module" crossorigin src="/assets/main-uLnyEwnj.js"></script>
123
+ <link rel="stylesheet" crossorigin href="/assets/main-BcV-6wVR.css">
124
124
  </head>
125
125
  <body>
126
126
  <main class="aeo-seed-content" aria-label="Token Tracker AI-readable summary">
@@ -51,8 +51,8 @@
51
51
  "description": "Shareable Token Tracker dashboard snapshot."
52
52
  }
53
53
  </script>
54
- <script type="module" crossorigin src="/assets/main-DFuYMEVg.js"></script>
55
- <link rel="stylesheet" crossorigin href="/assets/main-y3ZJfQaO.css">
54
+ <script type="module" crossorigin src="/assets/main-uLnyEwnj.js"></script>
55
+ <link rel="stylesheet" crossorigin href="/assets/main-BcV-6wVR.css">
56
56
  </head>
57
57
  <body>
58
58
  <main class="aeo-seed-content" aria-label="Token Tracker share page summary">
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tokentracker-cli",
3
- "version": "0.5.22",
3
+ "version": "0.5.24",
4
4
  "description": "Token usage tracker for AI agent CLIs (Claude Code, Codex, Cursor, Kiro, Gemini, OpenCode, OpenClaw)",
5
5
  "main": "src/cli.js",
6
6
  "bin": {
@@ -149,6 +149,33 @@ function fetchCursorUsageCsv({ cookie, timeoutMs = 30000 }) {
149
149
  });
150
150
  }
151
151
 
152
+ /**
153
+ * Fetch Cursor usage summary JSON.
154
+ * Returns parsed JSON body or throws on error.
155
+ */
156
+ function fetchCursorUsageSummary({ cookie, timeoutMs = 30000, fetchImpl = fetch }) {
157
+ return fetchImpl(CURSOR_SUMMARY_URL, {
158
+ method: "GET",
159
+ headers: {
160
+ Accept: "application/json",
161
+ Cookie: cookie,
162
+ Referer: "https://www.cursor.com/settings",
163
+ "User-Agent":
164
+ "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
165
+ },
166
+ redirect: "follow",
167
+ signal: AbortSignal.timeout(timeoutMs),
168
+ }).then(async (res) => {
169
+ if (res.status === 401 || res.status === 403) {
170
+ throw new Error("session_expired");
171
+ }
172
+ if (!res.ok) {
173
+ throw new Error(`Cursor API returned ${res.status}`);
174
+ }
175
+ return res.json();
176
+ });
177
+ }
178
+
152
179
  function fetchUrlRaw({ urlStr, cookie, timeoutMs }) {
153
180
  return new Promise((resolve, reject) => {
154
181
  const url = new URL(urlStr);
@@ -323,6 +350,7 @@ module.exports = {
323
350
  isCursorInstalled,
324
351
  extractCursorSessionToken,
325
352
  fetchCursorUsageCsv,
353
+ fetchCursorUsageSummary,
326
354
  parseCursorCsv,
327
355
  normalizeCursorUsage,
328
356
  };