ccgauge 1.1.5 → 1.2.0

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.
Files changed (80) hide show
  1. package/.next/standalone/.next/BUILD_ID +1 -1
  2. package/.next/standalone/.next/app-build-manifest.json +47 -31
  3. package/.next/standalone/.next/app-path-routes-manifest.json +4 -3
  4. package/.next/standalone/.next/build-manifest.json +2 -2
  5. package/.next/standalone/.next/prerender-manifest.json +3 -3
  6. package/.next/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  7. package/.next/standalone/.next/server/app/api/blocks/route.js +1 -1
  8. package/.next/standalone/.next/server/app/api/blocks/route_client-reference-manifest.js +1 -1
  9. package/.next/standalone/.next/server/app/api/export/usage/route.js +1 -1
  10. package/.next/standalone/.next/server/app/api/export/usage/route_client-reference-manifest.js +1 -1
  11. package/.next/standalone/.next/server/app/api/pricing/route_client-reference-manifest.js +1 -1
  12. package/.next/standalone/.next/server/app/api/projects/route_client-reference-manifest.js +1 -1
  13. package/.next/standalone/.next/server/app/api/scan/route_client-reference-manifest.js +1 -1
  14. package/.next/standalone/.next/server/app/api/sessions/route_client-reference-manifest.js +1 -1
  15. package/.next/standalone/.next/server/app/api/turns/route.js +1 -0
  16. package/.next/standalone/.next/server/app/api/turns/route.js.nft.json +1 -0
  17. package/.next/standalone/.next/server/app/api/turns/route_client-reference-manifest.js +1 -0
  18. package/.next/standalone/.next/server/app/api/usage/route_client-reference-manifest.js +1 -1
  19. package/.next/standalone/.next/server/app/models/page_client-reference-manifest.js +1 -1
  20. package/.next/standalone/.next/server/app/page.js +1 -1
  21. package/.next/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
  22. package/.next/standalone/.next/server/app/projects/[id]/page.js +1 -1
  23. package/.next/standalone/.next/server/app/projects/[id]/page.js.nft.json +1 -1
  24. package/.next/standalone/.next/server/app/projects/[id]/page_client-reference-manifest.js +1 -1
  25. package/.next/standalone/.next/server/app/projects/page_client-reference-manifest.js +1 -1
  26. package/.next/standalone/.next/server/app/sessions/[id]/page.js +1 -1
  27. package/.next/standalone/.next/server/app/sessions/[id]/page.js.nft.json +1 -1
  28. package/.next/standalone/.next/server/app/sessions/[id]/page_client-reference-manifest.js +1 -1
  29. package/.next/standalone/.next/server/app/sessions/page_client-reference-manifest.js +1 -1
  30. package/.next/standalone/.next/server/app/settings/page.js +1 -1
  31. package/.next/standalone/.next/server/app/settings/page_client-reference-manifest.js +1 -1
  32. package/.next/standalone/.next/server/app/usage/page.js +3 -3
  33. package/.next/standalone/.next/server/app/usage/page.js.nft.json +1 -1
  34. package/.next/standalone/.next/server/app/usage/page_client-reference-manifest.js +1 -1
  35. package/.next/standalone/.next/server/app-paths-manifest.json +4 -3
  36. package/.next/standalone/.next/server/chunks/567.js +2 -2
  37. package/.next/standalone/.next/server/chunks/{125.js → 697.js} +1 -1
  38. package/.next/standalone/.next/server/chunks/716.js +1 -1
  39. package/.next/standalone/.next/server/chunks/730.js +1 -1
  40. package/.next/standalone/.next/server/functions-config-manifest.json +3 -2
  41. package/.next/standalone/.next/server/middleware-manifest.json +5 -5
  42. package/.next/standalone/.next/server/pages/500.html +1 -1
  43. package/.next/standalone/.next/server/server-reference-manifest.json +1 -1
  44. package/.next/standalone/.next/static/KYCxLofmJUzQwVpdBlibl/_buildManifest.js +1 -0
  45. package/.next/standalone/.next/static/chunks/148-1212b038580a0433.js +1 -0
  46. package/.next/standalone/.next/static/chunks/567-72a086fabc9bacfe.js +1 -0
  47. package/.next/standalone/.next/static/chunks/app/api/blocks/route-c50a1245d93c020a.js +1 -0
  48. package/.next/standalone/.next/static/chunks/app/api/export/usage/route-c50a1245d93c020a.js +1 -0
  49. package/.next/standalone/.next/static/chunks/app/api/pricing/route-c50a1245d93c020a.js +1 -0
  50. package/.next/standalone/.next/static/chunks/app/api/projects/route-c50a1245d93c020a.js +1 -0
  51. package/.next/standalone/.next/static/chunks/app/api/scan/route-c50a1245d93c020a.js +1 -0
  52. package/.next/standalone/.next/static/chunks/app/api/sessions/route-c50a1245d93c020a.js +1 -0
  53. package/.next/standalone/.next/static/chunks/app/api/turns/route-c50a1245d93c020a.js +1 -0
  54. package/.next/standalone/.next/static/chunks/app/api/usage/route-c50a1245d93c020a.js +1 -0
  55. package/.next/standalone/.next/static/chunks/app/layout-6eefa1ce02863d7b.js +1 -0
  56. package/.next/standalone/.next/static/chunks/app/loading-c50a1245d93c020a.js +1 -0
  57. package/.next/standalone/.next/static/chunks/app/page-0816ef0cd3e872d8.js +1 -0
  58. package/.next/standalone/.next/static/chunks/app/usage/loading-c50a1245d93c020a.js +1 -0
  59. package/.next/standalone/.next/static/chunks/app/usage/page-1ffeadfacd55c9f0.js +1 -0
  60. package/.next/standalone/.next/static/css/169dd00e280f7237.css +5 -0
  61. package/.next/standalone/package.json +3 -2
  62. package/CHANGELOG.md +143 -0
  63. package/dist/mcp/server.mjs +15 -15
  64. package/dist/report/index.mjs +30 -30
  65. package/package.json +3 -2
  66. package/.next/standalone/.next/static/GtWVWyG8mgmjwPOWjfTMr/_buildManifest.js +0 -1
  67. package/.next/standalone/.next/static/chunks/148-59989feca70944f2.js +0 -1
  68. package/.next/standalone/.next/static/chunks/app/api/blocks/route-33a382d58df5da76.js +0 -1
  69. package/.next/standalone/.next/static/chunks/app/api/export/usage/route-33a382d58df5da76.js +0 -1
  70. package/.next/standalone/.next/static/chunks/app/api/pricing/route-33a382d58df5da76.js +0 -1
  71. package/.next/standalone/.next/static/chunks/app/api/projects/route-33a382d58df5da76.js +0 -1
  72. package/.next/standalone/.next/static/chunks/app/api/scan/route-33a382d58df5da76.js +0 -1
  73. package/.next/standalone/.next/static/chunks/app/api/sessions/route-33a382d58df5da76.js +0 -1
  74. package/.next/standalone/.next/static/chunks/app/api/usage/route-33a382d58df5da76.js +0 -1
  75. package/.next/standalone/.next/static/chunks/app/layout-af71188a257674b5.js +0 -1
  76. package/.next/standalone/.next/static/chunks/app/loading-33a382d58df5da76.js +0 -1
  77. package/.next/standalone/.next/static/chunks/app/page-1a147d12fca0b184.js +0 -1
  78. package/.next/standalone/.next/static/chunks/app/usage/page-8af23d9f5420c824.js +0 -1
  79. package/.next/standalone/.next/static/css/fabb40b2545c70dd.css +0 -5
  80. /package/.next/standalone/.next/static/{GtWVWyG8mgmjwPOWjfTMr → KYCxLofmJUzQwVpdBlibl}/_ssgManifest.js +0 -0
@@ -0,0 +1 @@
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[430],{1467:(e,t,r)=>{"use strict";r.d(t,{UsageDataIsland:()=>P});var n=r(95155),a=r(12115),s=r(20063),o=r(51148),l=r(79808),i=r(7331),c=r(25016);function d(e){var t;let{label:r,value:a,hint:s,delta:o,deltaTitle:l,progress:i,accent:d="default",className:h}=e;return(0,n.jsxs)("div",{className:(0,c.cn)("card card-pad relative flex flex-col gap-2 min-h-[132px] overflow-hidden","default"!==d&&"pt-[18px] sm:pt-[22px]",h),children:["default"!==d&&(0,n.jsx)(u,{tone:d}),(0,n.jsx)("div",{className:"label truncate",children:r}),(0,n.jsxs)("div",{className:"flex items-baseline gap-2 flex-wrap min-w-0",children:[(0,n.jsx)("div",{className:"num-hero min-w-0 max-w-full",children:a}),o&&"firstTime"in o&&o.firstTime&&(0,n.jsx)("span",{className:"pill text-[11px] font-medium whitespace-nowrap text-brand bg-brand/10 border border-brand/20",title:l,children:null!=(t=o.label)?t:"NEW"}),o&&"value"in o&&Number.isFinite(o.value)&&(0,n.jsx)(m,{value:o.value,positiveIsGood:o.positiveIsGood,title:l})]}),s&&(0,n.jsx)("div",{className:"text-xs text-text-secondary mt-auto leading-snug",children:s}),i&&(0,n.jsx)("div",{className:"mt-auto pt-2",children:(0,n.jsx)(x,{value:i.value,tone:i.tone})})]})}function u(e){let{tone:t}=e;return(0,n.jsx)("div",{"aria-hidden":!0,className:(0,c.cn)("absolute left-0 right-0 top-0 h-[3px] bg-gradient-to-r",{brand:"from-brand/0 via-brand/70 to-brand/0",success:"from-success/0 via-success/70 to-success/0",warning:"from-warning/0 via-warning/70 to-warning/0"}[t])})}function m(e){let{value:t,positiveIsGood:r=!0,title:a}=e,s=t>=0;return(0,n.jsxs)("span",{className:(0,c.cn)("pill text-[11px] font-medium whitespace-nowrap border",s===r?"text-success bg-success/10 border-success/20":"text-danger bg-danger/10 border-danger/20"),title:a,children:[s?"↑":"↓"," ",Math.abs(t).toFixed(0),"%"]})}function x(e){let{value:t,tone:r="brand"}=e,a=Math.max(0,Math.min(1,t));return(0,n.jsx)("div",{className:"h-1.5 w-full bg-bg-surface-hi rounded-full overflow-hidden",children:(0,n.jsx)("div",{className:(0,c.cn)("h-full rounded-full transition-all duration-500 ease-out-soft",{brand:"bg-brand",success:"bg-success",warning:"bg-warning",danger:"bg-danger"}[r]),style:{width:"".concat(100*a,"%")}})})}var h=r(38059),p=r(47650);function b(e){let{children:t,content:r,className:s,panelClassName:o,align:l="left",delay:i=100,maxWidth:d=360}=e,u=(0,a.useRef)(null),m=(0,a.useRef)(null),x=(0,a.useRef)(null),[h,b]=(0,a.useState)(null),[g,f]=(0,a.useState)(!1),[v,j]=(0,a.useState)(!1);function y(){x.current&&(window.clearTimeout(x.current),x.current=null),v||(m.current=window.setTimeout(()=>{let e=function(){let e,t=u.current;if(!t)return null;let r=t.getBoundingClientRect(),n=Math.min(d,window.innerWidth-16),a=window.innerHeight-r.bottom<200?"top":"bottom";return"right"===l?(e=Math.min(r.right,window.innerWidth-8))-n<8&&(e=n+8):(e=Math.max(r.left,8))+n>window.innerWidth-8&&(e=window.innerWidth-n-8),{x:e,y:"bottom"===a?r.bottom+8:r.top-8,placement:a,align:l}}();e&&(b(e),j(!0))},i))}function w(){m.current&&(window.clearTimeout(m.current),m.current=null),x.current=window.setTimeout(()=>j(!1),80)}return(0,a.useEffect)(()=>f(!0),[]),(0,a.useEffect)(()=>()=>{m.current&&window.clearTimeout(m.current),x.current&&window.clearTimeout(x.current)},[]),(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("span",{ref:u,onMouseEnter:y,onMouseLeave:w,onFocus:y,onBlur:w,className:(0,c.cn)("inline-block",s),children:t}),g&&h&&(0,p.createPortal)((0,n.jsx)("div",{onMouseEnter:()=>{x.current&&(window.clearTimeout(x.current),x.current=null)},onMouseLeave:w,style:{position:"fixed",left:"right"===h.align?void 0:h.x,right:"right"===h.align?window.innerWidth-h.x:void 0,top:"bottom"===h.placement?h.y:void 0,bottom:"top"===h.placement?window.innerHeight-h.y:void 0,maxWidth:d,transform:v?"translateY(0) scale(1)":"bottom"===h.placement?"translateY(-4px) scale(0.98)":"translateY(4px) scale(0.98)",opacity:+!!v,transitionProperty:"opacity, transform",transitionDuration:"120ms",transitionTimingFunction:"cubic-bezier(0.16, 1, 0.3, 1)",transformOrigin:"bottom"===h.placement?"top":"bottom",pointerEvents:v?"auto":"none"},className:(0,c.cn)("z-50 card border-border-hi shadow-xl rounded-button",o),children:r}),document.body)]})}var g=r(20857),f=r(40464);let v=[{id:"time",labelKey:"usage.col.time",sortKey:"timestamp",defaultVisible:!0},{id:"duration",labelKey:"usage.col.duration",align:"right",sortKey:"durationMs",defaultVisible:!1},{id:"prompt",labelKey:"usage.col.userMessage",defaultVisible:!0},{id:"model",labelKey:"usage.col.model",defaultVisible:!0},{id:"project",labelKey:"usage.col.project",defaultVisible:!0},{id:"session",labelKey:"usage.col.session",defaultVisible:!1},{id:"calls",labelKey:"usage.col.calls",align:"right",sortKey:"callCount",defaultVisible:!1},{id:"input",labelKey:"usage.col.input",align:"right",sortKey:"inputTokens",defaultVisible:!1},{id:"output",labelKey:"usage.col.output",align:"right",sortKey:"outputTokens",defaultVisible:!1},{id:"cacheRead",labelKey:"usage.col.cacheRead",align:"right",sortKey:"cacheReadTokens",defaultVisible:!1},{id:"cacheWrite",labelKey:"usage.col.cacheWrite",align:"right",sortKey:"cacheCreationTokens",defaultVisible:!1},{id:"total",labelKey:"usage.col.total",align:"right",sortKey:"totalTokens",defaultVisible:!0},{id:"cost",labelKey:"usage.col.cost",align:"right",sortKey:"cost",defaultVisible:!1},{id:"tools",labelKey:"usage.col.tools",defaultVisible:!1}],j="ccgauge.usage.cols.v4";function y(){return v.reduce((e,t)=>(e[t.id]=t.defaultVisible,e),{})}function w(e){let{rows:t,totalCount:r,page:l,pageCount:i,sort:d,query:u,codexFastActive:m}=e,x=(0,o.kj)(),{locale:h}=(0,o.s9)(),p=(0,s.usePathname)(),b=(0,s.useSearchParams)(),{pending:w,navigate:k}=(0,f.q)(),[T,C]=(0,a.useState)(new Set),[E,K]=(0,a.useState)(y),[R,L]=(0,a.useState)(!1),[P,M]=(0,a.useState)(u),A=(0,a.useRef)(null),I=(0,a.useRef)(null);function D(e){let t=new URLSearchParams(b.toString());for(let[r,n]of Object.entries(e))void 0===n||""===n?t.delete(r):t.set(r,n);let r=t.toString();k(r?"".concat(p,"?").concat(r):p)}function F(e){D({page:e>0?String(e+1):void 0})}(0,a.useEffect)(()=>{K(function(){try{let e=window.localStorage.getItem(j);if(!e)return y();let t=JSON.parse(e),r=y();for(let e of v)"boolean"==typeof t[e.id]&&(r[e.id]=t[e.id]);return r}catch(e){return y()}}())},[]),(0,a.useEffect)(()=>{window.localStorage.setItem(j,JSON.stringify(E))},[E]),(0,a.useEffect)(()=>{M(u)},[u]),(0,a.useEffect)(()=>{function e(e){A.current&&!A.current.contains(e.target)&&L(!1)}return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[]),(0,a.useEffect)(()=>()=>{I.current&&(window.clearTimeout(I.current),I.current=null)},[]);let W=v.filter(e=>E[e.id]),V=W.length+1,O=W.length;return(0,n.jsxs)("div",{children:[(0,n.jsxs)("div",{className:"flex items-center justify-between gap-3 mb-3 flex-wrap",children:[(0,n.jsx)("input",{value:P,onChange:e=>{var t;M(t=e.target.value),I.current&&window.clearTimeout(I.current),I.current=window.setTimeout(()=>{D({q:t.trim()||void 0,page:void 0})},300)},placeholder:x("common.searchPlaceholder"),className:"px-3 py-1.5 text-sm rounded-button border border-border bg-bg-surface focus:outline-none focus:border-border-hi w-72 placeholder:text-text-tertiary text-text-primary"}),(0,n.jsxs)("div",{className:"flex items-center gap-3",children:[(0,n.jsx)("span",{className:"text-xs text-text-tertiary tabular-nums",children:x("common.rows",{count:r.toLocaleString()})}),(0,n.jsxs)("div",{ref:A,className:"relative",children:[(0,n.jsxs)("button",{onClick:()=>L(e=>!e),className:"btn",children:[x("usage.columns.button"),(0,n.jsx)("span",{className:"ml-1 text-text-tertiary tabular-nums",children:O})]}),R&&(0,n.jsxs)("div",{className:"absolute right-0 mt-1 w-56 card border-border-hi shadow-lg p-2 z-30",children:[(0,n.jsxs)("div",{className:"flex items-center justify-between px-1.5 pb-1.5 mb-1 border-b border-border",children:[(0,n.jsx)("span",{className:"text-xs text-text-tertiary uppercase tracking-wide",children:x("usage.columns.title")}),(0,n.jsx)("button",{onClick:()=>K(y()),className:"text-xs text-text-tertiary hover:text-text-primary",children:x("usage.columns.reset")})]}),(0,n.jsx)("div",{className:"max-h-72 overflow-auto",children:v.map(e=>(0,n.jsxs)("label",{className:"flex items-center gap-2 px-1.5 py-1.5 text-sm rounded hover:bg-bg-surface-hi cursor-pointer",children:[(0,n.jsx)("input",{type:"checkbox",checked:!!E[e.id],onChange:t=>K(r=>({...r,[e.id]:t.target.checked})),className:"accent-brand"}),(0,n.jsx)("span",{className:"text-text-secondary",children:x(e.labelKey)})]},e.id))})]})]}),(0,n.jsx)("button",{onClick:function(){let e=new URLSearchParams(b.toString());window.location.href="/api/export/usage?".concat(e.toString())},className:"btn",children:x("common.exportCsv")})]})]}),(0,n.jsx)("div",{className:(0,c.cn)("card overflow-hidden transition-opacity",w&&"opacity-60 cursor-progress pointer-events-none"),"aria-busy":w,children:(0,n.jsx)(g.H,{children:(0,n.jsxs)("table",{className:"w-full text-sm",children:[(0,n.jsx)("thead",{children:(0,n.jsxs)("tr",{className:"border-b border-border bg-bg-surface-hi/30",children:[(0,n.jsx)(S,{children:(0,n.jsx)("span",{className:"sr-only",children:"expand"})}),W.map(e=>(0,n.jsx)(S,{align:e.align,sorted:!!e.sortKey&&d.key===e.sortKey,dir:d.dir,onClick:e.sortKey?()=>{var t;let r;return t=e.sortKey,r="desc",void(d.key===t&&(r="asc"===d.dir?"desc":"asc"),D({sort:"timestamp"===t?void 0:t,dir:"desc"===r?void 0:r,page:void 0}))}:void 0,children:x(e.labelKey)},e.id))]})}),(0,n.jsxs)("tbody",{children:[t.map(e=>{let t=T.has(e.turnId),r=e.userText.trim()||x("usage.turn.noPrompt");return(0,n.jsx)(N,{turn:e,isOpen:t,onToggle:()=>{var t;return t=e.turnId,void C(e=>{let r=new Set(e);return r.has(t)?r.delete(t):r.add(t),r})},userText:r,expandLabel:x("usage.turn.expand"),collapseLabel:x("usage.turn.collapse"),activeColumns:W,locale:h,t:x,codexFastActive:m},e.turnId)}),0===t.length&&(0,n.jsx)("tr",{children:(0,n.jsx)("td",{colSpan:V,className:"px-3 py-8 text-center text-text-tertiary text-sm",children:x("common.noMatchingRows")})})]})]})})}),i>1&&(0,n.jsxs)("div",{className:"flex items-center justify-between mt-3 text-xs text-text-secondary",children:[(0,n.jsx)("span",{children:x("common.pageOf",{page:l+1,total:i})}),(0,n.jsxs)("div",{className:"flex items-center gap-2",children:[(0,n.jsx)("button",{onClick:()=>F(0),disabled:0===l,className:"btn-ghost disabled:opacity-40",children:x("common.first")}),(0,n.jsx)("button",{onClick:()=>F(l-1),disabled:0===l,className:"btn-ghost disabled:opacity-40",children:x("common.prev")}),(0,n.jsx)("button",{onClick:()=>F(l+1),disabled:l>=i-1,className:"btn-ghost disabled:opacity-40",children:x("common.next")}),(0,n.jsx)("button",{onClick:()=>F(i-1),disabled:l>=i-1,className:"btn-ghost disabled:opacity-40",children:x("common.last")})]})]})]})}function N(e){let{turn:t,isOpen:r,onToggle:a,userText:s,expandLabel:o,collapseLabel:l,activeColumns:i,locale:d,t:u,codexFastActive:m}=e,x=(1===t.models.length?(0,c.P6)(t.models[0]):"".concat((0,c.P6)(t.models[0])," +").concat(t.models.length-1))+(t.efforts.length?1===t.efforts.length?" \xb7 ".concat(t.efforts[0]):" \xb7 ".concat(t.efforts[0],"+").concat(t.efforts.length-1):""),h=t.toolNames.length?t.toolNames.slice(0,3).join(", ")+(t.toolNames.length>3?"…":""):"—";return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("tr",{className:"border-b border-border last:border-b-0 hover:bg-bg-surface-hi/40 cursor-pointer",onClick:a,children:[(0,n.jsx)("td",{className:"px-2 py-2 text-text-tertiary w-6 text-center select-none",children:(0,n.jsx)("span",{title:r?l:o,className:"inline-block w-4",children:r?"▾":"▸"})}),i.map(e=>(0,n.jsx)("td",{className:(0,c.cn)("px-3 py-2","right"===e.align?"text-right":"text-left"),children:function(e,t,r,a,s,o,l,i){switch(e){case"time":return(0,n.jsx)("span",{className:"num-mono text-text-secondary whitespace-nowrap text-xs",title:"started ".concat((0,c.r6)(t.timestamp),"\nended ").concat((0,c.r6)(t.endTimestamp)),children:(0,c.r6)(t.timestamp)});case"duration":return(0,n.jsx)("span",{className:"num-mono text-text-secondary whitespace-nowrap text-xs",title:"".concat((0,c.r6)(t.timestamp)," → ").concat((0,c.r6)(t.endTimestamp)),children:(0,c.a3)(t.durationMs)});case"prompt":return(0,n.jsx)(b,{maxWidth:460,panelClassName:"p-3 text-sm text-text-secondary leading-relaxed",content:(0,n.jsx)("div",{className:"whitespace-pre-wrap break-words",children:s}),children:(0,n.jsx)("span",{className:"block text-text-secondary truncate max-w-[280px]",children:s})});case"model":return(0,n.jsxs)("span",{className:"inline-flex items-center gap-1.5 whitespace-nowrap",children:[(0,n.jsxs)("span",{className:"text-text-primary",children:[r,i&&"codex"===t.source&&(0,n.jsx)("span",{className:"font-semibold text-warning",title:l("usage.badge.fastHint"),children:"\xb7".concat(l("usage.badge.fast"))})]}),t.hasWorkflowSubagents&&(0,n.jsxs)("span",{className:"inline-flex items-center gap-0.5 px-1.5 py-0.5 rounded-full text-[10px] font-semibold leading-none bg-brand/10 text-brand border border-brand/20",title:l("usage.badge.workflowHint",{count:t.workflowSubagentCount}),children:[(0,n.jsx)("svg",{width:"9",height:"9",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":!0,children:(0,n.jsx)("path",{d:"M13 2 3 14h7l-1 8 10-12h-7z"})}),l("usage.badge.workflow"),t.workflowSubagentCount>1?" \xd7".concat(t.workflowSubagentCount):""]})]});case"project":return(0,n.jsx)("span",{className:"block text-text-secondary truncate max-w-[180px]",title:t.cwd,children:t.projectLabel||(0,c.PJ)(t.cwd)});case"session":return(0,n.jsx)("span",{className:"num-mono text-text-tertiary text-xs",title:t.sessionId,children:(0,c.BC)(t.sessionId)});case"calls":return(0,n.jsx)("span",{className:"num-mono text-text-secondary",children:t.callCount});case"input":return(0,n.jsx)("span",{className:"num-mono text-text-secondary",children:(0,c.jh)(t.inputTokens,o)});case"output":return(0,n.jsx)("span",{className:"num-mono text-text-secondary",children:(0,c.jh)(t.outputTokens,o)});case"cacheRead":return(0,n.jsx)("span",{className:"num-mono text-success",children:(0,c.jh)(t.cacheReadTokens,o)});case"cacheWrite":return(0,n.jsx)("span",{className:"num-mono text-text-secondary",children:(0,c.jh)(t.cacheCreationTokens,o)});case"total":return(0,n.jsx)(b,{align:"right",maxWidth:300,panelClassName:"p-0 overflow-hidden",content:(0,n.jsx)(k,{row:t,locale:o,t:l}),children:(0,n.jsx)("span",{className:"num-mono text-text-primary font-medium border-b border-dashed border-border hover:border-text-tertiary cursor-help",children:(0,c.jh)(t.totalTokens,o)})});case"cost":return(0,n.jsx)("span",{className:"num-mono text-text-primary font-medium",children:(0,c.l7)(t.cost)});case"tools":return(0,n.jsx)("span",{className:"block text-xs text-text-tertiary truncate max-w-[160px]",title:t.toolNames.join(", "),children:a})}}(e.id,t,x,h,s,d,u,m)},e.id))]}),r&&t.children.map(e=>(0,n.jsxs)("tr",{className:"border-b border-border last:border-b-0 bg-bg-surface-hi/20 text-text-tertiary",children:[(0,n.jsx)("td",{className:"px-2 py-1.5 w-6"}),i.map(r=>(0,n.jsx)("td",{className:(0,c.cn)("px-3 py-1.5","right"===r.align?"text-right":"text-left"),children:function(e,t,r,a,s,o){switch(e){case"time":return(0,n.jsx)("span",{className:"num-mono whitespace-nowrap text-xs inline-block translate-x-5",children:(0,c.r6)(t.timestamp)});case"duration":return(0,n.jsx)("span",{className:"text-xs text-text-tertiary",children:"—"});case"prompt":{var l;let e=(null!=(l=t.directPrompt)?l:"").trim();if(e&&e!==r.trim())return(0,n.jsx)("span",{className:"block text-xs text-text-secondary truncate max-w-[320px]",title:e,children:e});if(!t.toolNames.length)return(0,n.jsx)("span",{className:"text-xs text-text-tertiary",children:"—"});let a=t.toolNames.join(", "),s=t.toolNames.slice(0,3).join(", ")+(t.toolNames.length>3?"…":"");return(0,n.jsx)("span",{className:"block text-xs text-text-secondary truncate max-w-[280px]",title:a,children:s})}case"model":return(0,n.jsxs)("span",{className:"whitespace-nowrap",children:[(0,c.P6)(t.model),t.effort?" \xb7 ".concat(t.effort):"",o&&"codex"===t.source&&(0,n.jsx)("span",{className:"font-semibold text-warning",title:s("usage.badge.fastHint"),children:"\xb7".concat(s("usage.badge.fast"))})]});case"project":return(0,n.jsx)("span",{className:"block truncate max-w-[180px]",title:t.cwd,children:t.projectLabel||(0,c.PJ)(t.cwd)});case"session":return(0,n.jsx)("span",{className:"num-mono text-xs",title:t.sessionId,children:(0,c.BC)(t.sessionId)});case"calls":return(0,n.jsx)("span",{className:"num-mono",children:"1"});case"input":return(0,n.jsx)("span",{className:"num-mono",children:(0,c.jh)(t.inputTokens,a)});case"output":return(0,n.jsx)("span",{className:"num-mono",children:(0,c.jh)(t.outputTokens,a)});case"cacheRead":return(0,n.jsx)("span",{className:"num-mono text-success",children:(0,c.jh)(t.cacheReadTokens,a)});case"cacheWrite":return(0,n.jsx)("span",{className:"num-mono",children:(0,c.jh)(t.cacheCreationTokens,a)});case"total":return(0,n.jsx)(b,{align:"right",maxWidth:300,panelClassName:"p-0 overflow-hidden",content:(0,n.jsx)(k,{row:t,locale:a,t:s}),children:(0,n.jsx)("span",{className:"num-mono border-b border-dashed border-border/60 hover:border-text-tertiary cursor-help",children:(0,c.jh)(t.totalTokens,a)})});case"cost":return(0,n.jsx)("span",{className:"num-mono",children:(0,c.l7)(t.cost)});case"tools":return(0,n.jsx)("span",{className:"block text-xs truncate max-w-[160px]",title:t.toolNames.join(", "),children:t.toolNames.length?t.toolNames.join(", "):"—"})}}(r.id,e,t.userText,d,u,m)},r.id))]},e.uuid))]})}function k(e){let{row:t,locale:r,t:s}=e,o=[{key:"input",label:s("usage.col.input"),tokens:t.inputTokens,cost:t.costInput,tone:"text-text-primary",dot:"bg-chart-input"},{key:"output",label:s("usage.col.output"),tokens:t.outputTokens,cost:t.costOutput,tone:"text-text-primary",dot:"bg-chart-output"},{key:"cacheRead",label:s("usage.col.cacheRead"),tokens:t.cacheReadTokens,cost:t.costCacheRead,tone:"text-success",dot:"bg-chart-cache-read"},{key:"cacheWrite",label:s("usage.col.cacheWrite"),tokens:t.cacheCreationTokens,cost:t.costCacheWrite,tone:"text-text-primary",dot:"bg-chart-cache-create"}];return(0,n.jsxs)("div",{className:"text-xs",children:[(0,n.jsx)("div",{className:"px-3 py-2 border-b border-border bg-bg-surface-hi/40 text-text-tertiary uppercase tracking-wide font-medium",children:s("usage.breakdown.title")}),(0,n.jsxs)("div",{className:"px-3 py-2",children:[(0,n.jsxs)("div",{className:"grid grid-cols-[auto_1fr_auto] gap-x-3 gap-y-1.5 items-center",children:[(0,n.jsx)("span",{}),(0,n.jsx)("span",{className:"text-text-tertiary text-[10px] uppercase tracking-wide text-right",children:s("usage.breakdown.headerTokens")}),(0,n.jsx)("span",{className:"text-text-tertiary text-[10px] uppercase tracking-wide text-right",children:s("usage.breakdown.headerCost")}),o.map(e=>(0,n.jsxs)(a.Fragment,{children:[(0,n.jsxs)("span",{className:"inline-flex items-center gap-2 text-text-secondary",children:[(0,n.jsx)("span",{className:(0,c.cn)("w-2 h-2 rounded-sm",e.dot)}),e.label]}),(0,n.jsx)("span",{className:(0,c.cn)("num-mono text-right",e.tone),children:(0,c.jh)(e.tokens,r)}),(0,n.jsx)("span",{className:"num-mono text-right text-text-secondary",children:(0,c.l7)(e.cost)}),"output"===e.key&&t.reasoningTokens>0&&(0,n.jsxs)(a.Fragment,{children:[(0,n.jsxs)("span",{className:"inline-flex items-center gap-2 text-text-tertiary pl-4 text-[11px]",children:[(0,n.jsx)("span",{className:"text-text-tertiary",children:"↳"}),s("usage.breakdown.reasoning")]}),(0,n.jsx)("span",{className:"num-mono text-right text-text-tertiary text-[11px]",children:(0,c.jh)(t.reasoningTokens,r)}),(0,n.jsx)("span",{className:"text-right text-text-tertiary text-[11px]",children:s("usage.breakdown.reasoningNote")})]},"reasoning-detail")]},e.key))]}),(0,n.jsxs)("div",{className:"mt-2 pt-2 border-t border-border grid grid-cols-[auto_1fr_auto] gap-x-3 items-center",children:[(0,n.jsx)("span",{className:"text-text-secondary font-medium",children:s("usage.breakdown.total")}),(0,n.jsx)("span",{className:"num-mono text-right text-text-primary font-medium",children:(0,c.jh)(t.totalTokens,r)}),(0,n.jsx)("span",{className:"num-mono text-right text-text-primary font-medium",children:(0,c.l7)(t.cost)})]})]})]})}function S(e){let{children:t,align:r="left",sorted:a,dir:s,onClick:o}=e;return(0,n.jsx)("th",{className:(0,c.cn)("px-3 py-2 text-xs font-medium text-text-tertiary uppercase tracking-wide whitespace-nowrap","right"===r?"text-right":"text-left",o&&"cursor-pointer hover:text-text-primary select-none"),onClick:o,children:(0,n.jsxs)("span",{className:"inline-flex items-center gap-1",children:[t,a&&(0,n.jsx)("span",{className:"text-[10px]",children:"asc"===s?"▲":"▼"})]})})}var T=r(76669),C=r(63847);function E(e){let{paramKey:t,defaultValue:r,options:a,ariaLabel:l}=e,i=(0,s.usePathname)(),d=(0,s.useSearchParams)(),u=(0,o.kj)(),{pending:m,navigate:x}=(0,f.q)(),h=d.get(t)||r,p=a.some(e=>e.value===h)?h:r,{containerRef:b,rect:g}=(0,T.S)(p),v=null===g;function j(e){let r=new URLSearchParams(d.toString());r.set(t,e),x("".concat(i,"?").concat(r.toString()))}return(0,n.jsx)("div",{className:(0,c.cn)("inline-flex rounded-button border border-border bg-bg-surface p-0.5",m&&"opacity-60 cursor-progress"),"aria-busy":m,children:(0,n.jsxs)("div",{ref:b,role:"radiogroup","aria-label":l,onKeyDown:function(e){var t,r;if("ArrowLeft"!==e.key&&"ArrowRight"!==e.key)return;e.preventDefault();let n=(a.findIndex(e=>e.value===p)+("ArrowRight"===e.key?1:-1)+a.length)%a.length;j(a[n].value);let s=null==(t=b.current)?void 0:t.querySelectorAll('button[role="radio"]');null==s||null==(r=s[n])||r.focus()},className:"relative flex gap-0.5",children:[(0,n.jsx)(C.j,{rect:g,className:"ring-1 ring-brand/40"}),a.map(e=>{let t=p===e.value;return(0,n.jsx)("button",{role:"radio","data-tab":e.value,"aria-checked":t,tabIndex:t?0:-1,onClick:()=>j(e.value),className:(0,c.cn)("relative z-10 px-2.5 py-1 text-xs rounded transition-colors","focus:outline-none focus-visible:ring-2 focus-visible:ring-brand/40",t?(0,c.cn)("text-white font-semibold",v&&"bg-brand-strong shadow-sm ring-1 ring-brand/40"):"text-text-tertiary font-medium hover:text-text-primary hover:bg-bg-surface-hi"),children:u(e.tk)},e.value)})]})})}let K=[{value:"hour",tk:"gran.hour"},{value:"day",tk:"gran.day"},{value:"week",tk:"gran.week"},{value:"month",tk:"gran.month"}];function R(e){let{defaultValue:t="day"}=e,r=(0,o.kj)();return(0,n.jsx)(E,{paramKey:"gran",defaultValue:t,options:K,ariaLabel:r("gran.label")})}let L=new Map;function P(e){let{initial:t,costFootnote:r}=e,u=(0,o.kj)(),{locale:m}=(0,o.s9)(),x=(0,s.useSearchParams)();t&&!L.has(t.url)&&L.set(t.url,t.payload);let p=(0,a.useMemo)(()=>{var e;return(e=x.toString())?"/api/turns?".concat(e):"/api/turns"},[x]),[b,g]=(0,a.useState)(()=>{var e;return null!=(e=L.get(p))?e:null}),[f,v]=(0,a.useState)(!L.has(p)),[j,y]=(0,a.useState)(null),N=(0,a.useRef)(0);if((0,a.useEffect)(()=>{let e=++N.current,t=L.get(p);t?(g(t),v(!1)):v(!0),y(null),fetch(p,{cache:"no-store"}).then(e=>{if(!e.ok)throw Error("HTTP ".concat(e.status));return e.json()}).then(t=>{e===N.current&&(L.set(p,t),g(t),v(!1))}).catch(t=>{e===N.current&&(y(t.message),v(!1))})},[p]),(0,a.useEffect)(()=>{function e(){L.clear(),N.current++;let e=N.current;fetch(p,{cache:"no-store"}).then(e=>e.json()).then(t=>{e===N.current&&(L.set(p,t),g(t))}).catch(()=>{})}return window.addEventListener("ccgauge:refresh",e),()=>window.removeEventListener("ccgauge:refresh",e)},[p]),!b)return j?(0,n.jsxs)("div",{className:"card mt-4 p-6 text-sm text-warning",children:[u("common.empty.title"),": ",j]}):(0,n.jsx)(M,{});if(!b.hasAnyRecords)return(0,n.jsx)(i.pp,{title:u("common.empty.title"),desc:u("common.empty.desc")});let k=b.totals.totalTokens>0?b.totals.cacheReadTokens/Math.max(1,b.totals.cacheReadTokens+b.totals.inputTokens+b.totals.cacheCreationTokens):0;return(0,n.jsxs)("div",{className:f?"opacity-90":"","aria-busy":f,children:[(0,n.jsxs)("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-4 mt-4",children:[(0,n.jsx)(d,{label:u("usage.kpi.totalTokens"),value:(0,c.jh)(b.totals.totalTokens,m)}),(0,n.jsx)(d,{label:u("usage.kpi.totalCost"),value:(0,c.az)(b.totals.cost),hint:r||void 0}),(0,n.jsx)(d,{label:u("usage.kpi.cacheSaved"),value:(0,c.az)(b.totals.saved),accent:"success"}),(0,n.jsx)(d,{label:u("usage.kpi.cacheHit"),value:(0,c.R8)(k,0),accent:"success"})]}),(0,n.jsx)(i.wn,{title:u("usage.trend"),desc:u("usage.trend.gran",{gran:(0,l.nA)(m,"gran.".concat(b.gran))}),right:(0,n.jsx)(R,{defaultValue:b.gran}),className:"mt-4",children:(0,n.jsx)(h.TokenStackChart,{data:b.trend})}),(0,n.jsx)(i.wn,{title:u("usage.requests.title"),desc:u("usage.requests.desc"),children:(0,n.jsx)(w,{rows:b.turns,totalCount:b.totalCount,page:b.page,pageCount:b.pageCount,sort:b.sort,query:b.query,codexFastActive:b.codexFastActive})})]})}function M(){return(0,n.jsxs)("div",{children:[(0,n.jsx)("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-4 mt-4",children:Array.from({length:4}).map((e,t)=>(0,n.jsxs)("div",{className:"card p-4",children:[(0,n.jsx)("div",{className:"h-3 w-24 rounded bg-bg-surface-hi/40 animate-pulse"}),(0,n.jsx)("div",{className:"h-7 w-28 mt-3 rounded bg-bg-surface-hi/60 animate-pulse"})]},t))}),(0,n.jsx)("div",{className:"card mt-4 h-72 bg-bg-surface-hi/30 animate-pulse"}),(0,n.jsx)("div",{className:"card mt-4 p-4 space-y-2",children:Array.from({length:8}).map((e,t)=>(0,n.jsx)("div",{className:"h-7 rounded bg-bg-surface-hi/40 animate-pulse"},t))})]})}},8336:(e,t,r)=>{"use strict";r.d(t,{ModelFilter:()=>l});var n=r(95155),a=r(35850),s=r(25016),o=r(51148);function l(e){let{all:t,selected:r}=e,l=(0,o.kj)();return(0,n.jsx)(a.K,{paramKey:"models",all:t,selected:r,render:s.P6,labelAllKey:"filter.modelAll",labelSingleKey:"filter.modelSingle",labelMultiKey:"filter.modelMulti",ariaLabel:l("filter.modelLabel")})}},14920:(e,t,r)=>{"use strict";r.d(t,{ProjectFilter:()=>l});var n=r(95155),a=r(35850),s=r(25016),o=r(51148);function l(e){let{all:t,selected:r}=e,l=(0,o.kj)();return(0,n.jsx)(a.K,{paramKey:"projects",all:t,selected:r,render:s.PJ,labelAllKey:"filter.projectAll",labelSingleKey:"filter.projectSingle",labelMultiKey:"filter.projectMulti",ariaLabel:l("filter.projectLabel")})}},20857:(e,t,r)=>{"use strict";r.d(t,{H:()=>o});var n=r(95155),a=r(12115),s=r(25016);function o(e){let{children:t,className:r}=e,o=(0,a.useRef)(null),[l,i]=(0,a.useState)(!1),[c,d]=(0,a.useState)(!1);return(0,a.useEffect)(()=>{let e=o.current;if(!e)return;function t(){if(!e)return;let{scrollLeft:t,scrollWidth:r,clientWidth:n}=e;i(t>4),d(t+n<r-4)}t(),e.addEventListener("scroll",t,{passive:!0});let r=new ResizeObserver(t);return r.observe(e),()=>{e.removeEventListener("scroll",t),r.disconnect()}},[]),(0,n.jsxs)("div",{className:(0,s.cn)("relative",r),children:[(0,n.jsx)("div",{ref:o,className:"overflow-x-auto",children:t}),(0,n.jsx)("div",{"aria-hidden":!0,className:(0,s.cn)("pointer-events-none absolute left-0 top-0 bottom-0 w-8 bg-gradient-to-r from-bg-surface to-transparent transition-opacity duration-150",l?"opacity-100":"opacity-0")}),(0,n.jsx)("div",{"aria-hidden":!0,className:(0,s.cn)("pointer-events-none absolute right-0 top-0 bottom-0 w-8 bg-gradient-to-l from-bg-surface to-transparent transition-opacity duration-150",c?"opacity-100":"opacity-0")})]})}},35850:(e,t,r)=>{"use strict";r.d(t,{K:()=>c});var n=r(95155),a=r(20063),s=r(12115),o=r(25016),l=r(51148),i=r(40464);function c(e){let t,{paramKey:r,all:c,selected:d,render:u=e=>e,labelAllKey:m,labelSingleKey:x,labelMultiKey:h,ariaLabel:p,searchThreshold:b=6}=e,g=(0,a.usePathname)(),f=(0,a.useSearchParams)(),v=(0,l.kj)(),{pending:j,navigate:y}=(0,i.q)(),[w,N]=(0,s.useState)(!1),[k,S]=(0,s.useState)(""),[T,C]=(0,s.useState)(0),E=(0,s.useRef)(null),K=(0,s.useRef)(null),R=(0,s.useRef)(null),L=(0,s.useRef)(null),P=(0,s.useId)(),M=(0,s.useId)();(0,s.useEffect)(()=>{if(w)return document.addEventListener("mousedown",e),document.addEventListener("keydown",t),()=>{document.removeEventListener("mousedown",e),document.removeEventListener("keydown",t)};function e(e){E.current&&!E.current.contains(e.target)&&N(!1)}function t(e){if("Escape"===e.key){var t;N(!1),null==(t=K.current)||t.focus()}}},[w]),(0,s.useEffect)(()=>{w&&c.length>=b&&requestAnimationFrame(()=>{var e;return null==(e=R.current)?void 0:e.focus()}),w||(S(""),C(0))},[w,c.length,b]);let A=(0,s.useMemo)(()=>{let e=k.trim().toLowerCase();return e?c.filter(t=>u(t).toLowerCase().includes(e)||t.toLowerCase().includes(e)):c},[c,k,u]);function I(e){let t=new URLSearchParams(f.toString());0===e.size?t.delete(r):t.set(r,Array.from(e).join(","));let n=t.toString();y(n?"".concat(g,"?").concat(n):g)}function D(e){let t=new Set(d);t.has(e)?t.delete(e):t.add(e),I(t)}function F(e){if("ArrowDown"===e.key)e.preventDefault(),C(e=>Math.min(A.length-1,e+1));else if("ArrowUp"===e.key)e.preventDefault(),C(e=>Math.max(0,e-1));else if("Enter"===e.key){e.preventDefault();let t=A[T];t&&D(t)}else"Home"===e.key?(e.preventDefault(),C(0)):"End"===e.key&&(e.preventDefault(),C(A.length-1))}t=0===d.length?v(m):1===d.length?v(x,{value:u(d[0])}):v(h,{count:d.length});let W=c.length>=b;return(0,n.jsxs)("div",{ref:E,className:(0,o.cn)("relative",j&&"opacity-60 cursor-progress"),"aria-busy":j,children:[(0,n.jsxs)("button",{ref:K,id:P,onClick:()=>N(e=>!e),className:"btn focus:outline-none focus-visible:ring-2 focus-visible:ring-brand/40","aria-haspopup":"listbox","aria-expanded":w,"aria-controls":M,"aria-label":p,children:[t,(0,n.jsx)("span",{className:"text-text-tertiary ml-1","aria-hidden":!0,children:"▾"})]}),w&&(0,n.jsxs)("div",{id:M,role:"listbox","aria-multiselectable":"true","aria-labelledby":P,className:"absolute right-0 mt-1 w-72 card border-border-hi shadow-lg z-20 overflow-hidden",children:[d.length>0&&(0,n.jsxs)("div",{className:"px-2 pt-2 pb-1.5 border-b border-border flex flex-wrap gap-1 items-center",children:[d.slice(0,6).map(e=>(0,n.jsxs)("button",{onClick:()=>D(e),className:"inline-flex items-center gap-1 max-w-[160px] pl-2 pr-1.5 py-0.5 text-[11px] rounded-full bg-brand/10 text-brand border border-brand/20 hover:bg-brand/15","aria-label":"Remove ".concat(u(e)),title:u(e),children:[(0,n.jsx)("span",{className:"truncate",children:u(e)}),(0,n.jsx)("span",{"aria-hidden":!0,className:"text-brand/70",children:"\xd7"})]},e)),d.length>6&&(0,n.jsxs)("span",{className:"text-[11px] text-text-tertiary px-1",children:["+",d.length-6]}),(0,n.jsx)("button",{onClick:function(){I(new Set)},className:"ml-auto text-[11px] text-text-tertiary hover:text-text-primary px-1.5 py-0.5",children:v("filter.clearAll")})]}),W&&(0,n.jsx)("div",{className:"p-2 border-b border-border",children:(0,n.jsx)("input",{ref:R,value:k,onChange:e=>{S(e.target.value),C(0)},onKeyDown:e=>{("ArrowDown"===e.key||"ArrowUp"===e.key||"Enter"===e.key||"Home"===e.key||"End"===e.key)&&F(e)},placeholder:v("common.searchPlaceholder"),className:"w-full px-2 py-1 text-sm rounded border border-border bg-bg-surface focus:outline-none focus:border-border-hi placeholder:text-text-tertiary text-text-primary"})}),(0,n.jsxs)("div",{ref:L,onKeyDown:F,className:"max-h-64 overflow-y-auto p-1 outline-none",tabIndex:-1,children:[0===A.length&&(0,n.jsx)("div",{className:"text-xs text-text-tertiary px-2 py-3 text-center",children:v("filter.noOptions")}),A.map((e,t)=>{let r=d.includes(e),a=t===T;return(0,n.jsxs)("button",{role:"option","aria-selected":r,onMouseEnter:()=>C(t),onClick:()=>D(e),className:(0,o.cn)("w-full text-left text-sm px-2 py-1.5 rounded flex items-center gap-2 transition-colors",a?"bg-bg-surface-hi":"hover:bg-bg-surface-hi",r&&"text-text-primary"),children:[(0,n.jsx)("span",{className:(0,o.cn)("w-3.5 h-3.5 rounded-sm border flex items-center justify-center text-[10px] flex-shrink-0",r?"bg-brand border-brand text-white":"border-border-hi"),"aria-hidden":!0,children:r?"✓":""}),(0,n.jsx)("span",{className:"truncate",children:u(e)})]},e)})]})]})]})}},40464:(e,t,r)=>{"use strict";r.d(t,{q:()=>s});var n=r(12115),a=r(20063);function s(){let e=(0,a.useRouter)(),[t,r]=(0,n.useTransition)();return{pending:t,navigate:function(t){r(()=>{e.push(t)})}}}},44512:(e,t,r)=>{"use strict";r.d(t,{OverviewToggle:()=>c});var n=r(95155),a=r(12115),s=r(25016),o=r(51148);let l="data-usage-overview",i="hidden";function c(){let e=(0,o.kj)(),[t,r]=(0,a.useState)(!1);return(0,a.useEffect)(()=>{r(document.documentElement.getAttribute(l)===i)},[]),(0,n.jsxs)("button",{type:"button",onClick:function(){let e=!t;r(e);try{localStorage.setItem("ccgauge.usage.overview.hidden",e?"1":"0")}catch(e){}e?document.documentElement.setAttribute(l,i):document.documentElement.removeAttribute(l)},"aria-pressed":!t,title:e(t?"usage.overview.show":"usage.overview.hide"),className:(0,s.cn)("inline-flex items-center gap-1.5 px-2.5 py-1.5 rounded-button text-xs font-medium","border transition-colors duration-150",t?"border-border bg-bg-surface text-text-secondary hover:text-text-primary hover:bg-bg-surface-hi":"border-brand/40 bg-brand/12 text-brand hover:bg-brand/20 hover:border-brand/60"),children:[(0,n.jsx)(d,{open:!t}),(0,n.jsx)("span",{className:"hidden sm:inline",children:e("usage.overview.label")})]})}function d(e){let{open:t}=e;return(0,n.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":!0,children:t?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("path",{d:"M2 12s3.5-7 10-7 10 7 10 7-3.5 7-10 7-10-7-10-7Z"}),(0,n.jsx)("circle",{cx:"12",cy:"12",r:"3"})]}):(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("path",{d:"M9.88 9.88a3 3 0 0 0 4.24 4.24"}),(0,n.jsx)("path",{d:"M10.73 5.08A11 11 0 0 1 12 5c6.5 0 10 7 10 7a13.16 13.16 0 0 1-1.67 2.68"}),(0,n.jsx)("path",{d:"M6.61 6.61A13.526 13.526 0 0 0 2 12s3.5 7 10 7a9.74 9.74 0 0 0 5.39-1.61"}),(0,n.jsx)("line",{x1:"2",y1:"2",x2:"22",y2:"22"})]})})}},73896:(e,t,r)=>{"use strict";r.d(t,{RangePicker:()=>v});var n=r(95155),a=r(20063),s=r(12115),o=r(25016),l=r(51148),i=r(76243),c=r(76043),d=r(82006);function u(e){let{selected:t,onSelect:r,toDate:a}=e,{locale:s}=(0,l.s9)(),o="zh"===s?c.g:d.c,u=null!=a?a:new Date;return(0,n.jsx)(i.h,{mode:"range",locale:o,selected:t,onSelect:r,endMonth:u,disabled:{after:u},numberOfMonths:1})}var m=r(40464);let x=[{value:"1d",tk:"range.today"},{value:"7d",tk:"range.7d"},{value:"30d",tk:"range.30d"},{value:"90d",tk:"range.90d"},{value:"all",tk:"range.all"}],h=/^\d{4}-\d{2}-\d{2}$/;function p(e){if(!h.test(e)||!h.exec(e))return!1;let t=Number(e.slice(0,4)),r=Number(e.slice(5,7)),n=Number(e.slice(8,10)),a=new Date(t,r-1,n);return!Number.isNaN(a.getTime())&&a.getFullYear()===t&&a.getMonth()===r-1&&a.getDate()===n}function b(e){if(!p(e))return;let t=Number(e.slice(0,4));return new Date(t,Number(e.slice(5,7))-1,Number(e.slice(8,10)))}function g(e){let t=e.getFullYear(),r=String(e.getMonth()+1).padStart(2,"0"),n=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(r,"-").concat(n)}function f(e,t){if(!p(e))return e;let r=new Date(e+"T00:00:00");return new Intl.DateTimeFormat(t,{month:"short",day:"numeric"}).format(r)}function v(e){let{defaultValue:t="7d"}=e,r=(0,a.usePathname)(),i=(0,a.useSearchParams)(),{t:c,locale:d}=(0,l.s9)(),{pending:h,navigate:p}=(0,m.q)(),v=i.get("range")||t,j=x.some(e=>e.value===v),y="custom"===v,w=j?v:y?"custom":t,N=i.get("from")||"",k=i.get("to")||"",[S,T]=(0,s.useState)(!1),[C,E]=(0,s.useState)(()=>({from:b(N),to:b(k)})),K=(0,s.useRef)(null);(0,s.useEffect)(()=>{E({from:b(N),to:b(k)})},[N,k,S]),(0,s.useEffect)(()=>{if(S)return document.addEventListener("mousedown",e),document.addEventListener("keydown",t),()=>{document.removeEventListener("mousedown",e),document.removeEventListener("keydown",t)};function e(e){K.current&&!K.current.contains(e.target)&&T(!1)}function t(e){"Escape"===e.key&&T(!1)}},[S]);let R=y&&N?k?"".concat(f(N,d)," – ").concat(f(k,d)):"".concat(f(N,d)," →"):c("range.custom"),L=(null==C?void 0:C.from)?new Intl.DateTimeFormat(d,{year:"numeric",month:"short",day:"numeric"}).format(C.from):"",P=(null==C?void 0:C.to)?new Intl.DateTimeFormat(d,{year:"numeric",month:"short",day:"numeric"}).format(C.to):"";return(0,n.jsxs)("div",{ref:K,className:(0,o.cn)("flex items-center gap-1",h&&"opacity-60 cursor-progress"),"aria-busy":h,children:[(0,n.jsx)("div",{role:"radiogroup","aria-label":c("range.label"),className:"inline-flex rounded-button border border-border bg-bg-surface p-0.5 gap-0.5",children:x.map(e=>{let t=w===e.value;return(0,n.jsx)("button",{role:"radio","aria-checked":t,tabIndex:t?0:-1,onClick:()=>(function(e){let t=new URLSearchParams(i.toString());t.set("range",e),t.delete("from"),t.delete("to"),p("".concat(r,"?").concat(t.toString())),T(!1)})(e.value),className:(0,o.cn)("px-2.5 py-1 text-xs rounded transition-all","focus:outline-none focus-visible:ring-2 focus-visible:ring-brand/40",t?"bg-brand-strong text-white font-semibold shadow-sm ring-1 ring-brand/40":"text-text-tertiary font-medium hover:text-text-primary hover:bg-bg-surface-hi"),children:c(e.tk)},e.value)})}),(0,n.jsxs)("div",{className:"relative",children:[(0,n.jsxs)("button",{type:"button","aria-haspopup":"dialog","aria-expanded":S,onClick:()=>T(e=>!e),className:(0,o.cn)("px-2.5 py-1 text-xs rounded-button border transition-all inline-flex items-center gap-1","focus:outline-none focus-visible:ring-2 focus-visible:ring-brand/40",y?"bg-brand-strong text-white font-semibold shadow-sm ring-1 ring-brand/40 border-transparent":"border-border bg-bg-surface text-text-tertiary font-medium hover:text-text-primary hover:bg-bg-surface-hi"),children:[(0,n.jsx)("span",{children:R}),(0,n.jsx)("span",{"aria-hidden":!0,className:(0,o.cn)(y?"text-white/80":"text-text-tertiary"),children:"▾"})]}),S&&(0,n.jsxs)("div",{role:"dialog","aria-label":c("range.custom"),className:"absolute right-0 mt-1.5 z-20 w-[324px] rounded-card border border-border-hi bg-bg-elevated shadow-popover",children:[(0,n.jsxs)("div",{className:"grid grid-cols-2 gap-3 px-4 pt-4 pb-3",children:[(0,n.jsxs)("div",{className:"min-w-0",children:[(0,n.jsx)("div",{className:"label",children:c("range.from")}),(0,n.jsx)("div",{className:(0,o.cn)("mt-1 text-sm tabular-nums truncate",(null==C?void 0:C.from)?"text-text-primary font-semibold":"text-text-tertiary"),children:(null==C?void 0:C.from)?L:"—"})]}),(0,n.jsxs)("div",{className:"min-w-0",children:[(0,n.jsx)("div",{className:"label",children:c("range.to")}),(0,n.jsx)("div",{className:(0,o.cn)("mt-1 text-sm tabular-nums truncate",(null==C?void 0:C.to)?"text-text-primary font-semibold":"text-text-tertiary"),children:(null==C?void 0:C.to)?P:"—"})]})]}),(0,n.jsx)("div",{className:"divider-soft"}),(0,n.jsx)("div",{className:"px-3 pt-3 pb-2 flex justify-center",children:(0,n.jsx)(u,{selected:C,onSelect:E})}),(0,n.jsx)("div",{className:"divider-soft"}),(0,n.jsxs)("div",{className:"flex justify-end gap-2 px-4 py-3",children:[(0,n.jsx)("button",{type:"button",onClick:()=>T(!1),className:"btn-ghost text-sm focus:outline-none focus-visible:ring-2 focus-visible:ring-brand/40",children:c("range.cancel")}),(0,n.jsx)("button",{type:"button",onClick:function(){let e=null==C?void 0:C.from;if(!e)return;let t=null==C?void 0:C.to,n=new URLSearchParams(i.toString());n.set("range","custom"),n.set("from",g(e)),t?n.set("to",g(t)):n.delete("to"),p("".concat(r,"?").concat(n.toString())),T(!1)},disabled:!(null==C?void 0:C.from),className:(0,o.cn)("inline-flex items-center justify-center px-3 py-1.5 rounded-button text-sm font-semibold transition-colors","bg-brand-strong text-white","hover:bg-brand-hover","disabled:opacity-40 disabled:cursor-not-allowed disabled:hover:bg-brand-strong","focus:outline-none focus-visible:ring-2 focus-visible:ring-brand/40"),children:c("range.customApply")})]})]})]})]})}},78826:(e,t,r)=>{Promise.resolve().then(r.bind(r,77549)),Promise.resolve().then(r.bind(r,8336)),Promise.resolve().then(r.bind(r,44512)),Promise.resolve().then(r.bind(r,14920)),Promise.resolve().then(r.bind(r,73896)),Promise.resolve().then(r.bind(r,1467))}},e=>{e.O(0,[760,930,253,148,567,441,255,358],()=>e(e.s=78826)),_N_E=e.O()}]);
@@ -0,0 +1,5 @@
1
+ .rdp-root{--rdp-accent-color:blue;--rdp-accent-background-color:#f0f0ff;--rdp-day-height:44px;--rdp-day-width:44px;--rdp-day_button-border-radius:100%;--rdp-day_button-border:2px solid transparent;--rdp-day_button-height:42px;--rdp-day_button-width:42px;--rdp-selected-border:2px solid var(--rdp-accent-color);--rdp-disabled-opacity:0.5;--rdp-outside-opacity:0.75;--rdp-today-color:var(--rdp-accent-color);--rdp-dropdown-gap:0.5rem;--rdp-months-gap:2rem;--rdp-nav_button-disabled-opacity:0.5;--rdp-nav_button-height:2.25rem;--rdp-nav_button-width:2.25rem;--rdp-nav-height:2.75rem;--rdp-range_middle-background-color:var(--rdp-accent-background-color);--rdp-range_middle-color:inherit;--rdp-range_start-color:white;--rdp-range_start-background:linear-gradient(var(--rdp-gradient-direction),transparent 50%,var(--rdp-range_middle-background-color) 50%);--rdp-range_start-date-background-color:var(--rdp-accent-color);--rdp-range_end-background:linear-gradient(var(--rdp-gradient-direction),var(--rdp-range_middle-background-color) 50%,transparent 50%);--rdp-range_end-color:white;--rdp-range_end-date-background-color:var(--rdp-accent-color);--rdp-week_number-border-radius:100%;--rdp-week_number-border:2px solid transparent;--rdp-week_number-height:var(--rdp-day-height);--rdp-week_number-opacity:0.75;--rdp-week_number-width:var(--rdp-day-width);--rdp-weeknumber-text-align:center;--rdp-weekday-opacity:0.75;--rdp-weekday-padding:0.5rem 0rem;--rdp-weekday-text-align:center;--rdp-gradient-direction:90deg;--rdp-animation_duration:0.3s;--rdp-animation_timing:cubic-bezier(0.4,0,0.2,1)}.rdp-root[dir=rtl]{--rdp-gradient-direction:-90deg}.rdp-root[data-broadcast-calendar=true]{--rdp-outside-opacity:unset}.rdp-root{position:relative}.rdp-root,.rdp-root *{box-sizing:border-box}.rdp-day{width:var(--rdp-day-width);height:var(--rdp-day-height);text-align:center}.rdp-day_button{background:none;padding:0;margin:0;cursor:pointer;font:inherit;color:inherit;justify-content:center;align-items:center;display:flex;width:var(--rdp-day_button-width);height:var(--rdp-day_button-height);border:var(--rdp-day_button-border);border-radius:var(--rdp-day_button-border-radius)}.rdp-day_button:disabled{cursor:revert}.rdp-caption_label{z-index:1;position:relative;display:inline-flex;align-items:center;white-space:nowrap;border:0}.rdp-dropdown:focus-visible~.rdp-caption_label{outline:5px auto Highlight;outline:5px auto -webkit-focus-ring-color}.rdp-button_next,.rdp-button_previous{border:none;background:none;padding:0;margin:0;cursor:pointer;font:inherit;color:inherit;-moz-appearance:none;-webkit-appearance:none;display:inline-flex;align-items:center;justify-content:center;position:relative;appearance:none;width:var(--rdp-nav_button-width);height:var(--rdp-nav_button-height)}.rdp-button_next:disabled,.rdp-button_next[aria-disabled=true],.rdp-button_previous:disabled,.rdp-button_previous[aria-disabled=true]{cursor:revert;opacity:var(--rdp-nav_button-disabled-opacity)}.rdp-chevron{display:inline-block;fill:var(--rdp-accent-color)}.rdp-root[dir=rtl] .rdp-nav .rdp-chevron{transform:rotate(180deg);transform-origin:50%}.rdp-dropdowns{position:relative;display:inline-flex;align-items:center;gap:var(--rdp-dropdown-gap)}.rdp-dropdown{z-index:2;opacity:0;-webkit-appearance:none;-moz-appearance:none;appearance:none;position:absolute;inset-block-start:0;inset-block-end:0;inset-inline-start:0;width:100%;margin:0;padding:0;cursor:inherit;border:none;line-height:inherit}.rdp-dropdown_root{position:relative;display:inline-flex;align-items:center}.rdp-dropdown_root[data-disabled=true] .rdp-chevron{opacity:var(--rdp-disabled-opacity)}.rdp-month_caption{display:flex;align-content:center;height:var(--rdp-nav-height);font-weight:700;font-size:large}.rdp-root[data-nav-layout=after] .rdp-month,.rdp-root[data-nav-layout=around] .rdp-month{position:relative}.rdp-root[data-nav-layout=around] .rdp-month_caption{justify-content:center;margin-inline-start:var(--rdp-nav_button-width);margin-inline-end:var(--rdp-nav_button-width);position:relative}.rdp-root[data-nav-layout=around] .rdp-button_previous{position:absolute;inset-inline-start:0;top:0;height:var(--rdp-nav-height);display:inline-flex}.rdp-root[data-nav-layout=around] .rdp-button_next{position:absolute;inset-inline-end:0;top:0;height:var(--rdp-nav-height);display:inline-flex;justify-content:center}.rdp-months{position:relative;display:flex;flex-wrap:wrap;gap:var(--rdp-months-gap);max-width:-moz-fit-content;max-width:fit-content}.rdp-month_grid{border-collapse:collapse}.rdp-nav{position:absolute;inset-block-start:0;inset-inline-end:0;display:flex;align-items:center;height:var(--rdp-nav-height)}.rdp-weekday{opacity:var(--rdp-weekday-opacity);padding:var(--rdp-weekday-padding);font-weight:500;font-size:smaller;text-align:var(--rdp-weekday-text-align);text-transform:var(--rdp-weekday-text-transform)}.rdp-week_number{opacity:var(--rdp-week_number-opacity);font-weight:400;font-size:small;height:var(--rdp-week_number-height);width:var(--rdp-week_number-width);border:var(--rdp-week_number-border);border-radius:var(--rdp-week_number-border-radius);text-align:var(--rdp-weeknumber-text-align)}.rdp-today:not(.rdp-outside){color:var(--rdp-today-color)}.rdp-selected{font-weight:700;font-size:large}.rdp-selected .rdp-day_button{border:var(--rdp-selected-border)}.rdp-outside{opacity:var(--rdp-outside-opacity)}.rdp-disabled:not(.rdp-selected){opacity:var(--rdp-disabled-opacity)}.rdp-hidden{visibility:hidden;color:var(--rdp-range_start-color)}.rdp-range_start{background:var(--rdp-range_start-background)}.rdp-range_start .rdp-day_button{background-color:var(--rdp-range_start-date-background-color);color:var(--rdp-range_start-color)}.rdp-range_middle{background-color:var(--rdp-range_middle-background-color)}.rdp-range_middle .rdp-day_button{border:unset;border-radius:unset;color:var(--rdp-range_middle-color)}.rdp-range_end{background:var(--rdp-range_end-background);color:var(--rdp-range_end-color)}.rdp-range_end .rdp-day_button{color:var(--rdp-range_start-color);background-color:var(--rdp-range_end-date-background-color)}.rdp-range_start.rdp-range_end{background:revert}.rdp-focusable{cursor:pointer}@keyframes rdp-slide_in_left{0%{transform:translateX(-100%)}to{transform:translateX(0)}}@keyframes rdp-slide_in_right{0%{transform:translateX(100%)}to{transform:translateX(0)}}@keyframes rdp-slide_out_left{0%{transform:translateX(0)}to{transform:translateX(-100%)}}@keyframes rdp-slide_out_right{0%{transform:translateX(0)}to{transform:translateX(100%)}}.rdp-weeks_before_enter{animation:rdp-slide_in_left var(--rdp-animation_duration) var(--rdp-animation_timing) forwards}.rdp-weeks_before_exit{animation:rdp-slide_out_left var(--rdp-animation_duration) var(--rdp-animation_timing) forwards}.rdp-weeks_after_enter{animation:rdp-slide_in_right var(--rdp-animation_duration) var(--rdp-animation_timing) forwards}.rdp-weeks_after_exit{animation:rdp-slide_out_right var(--rdp-animation_duration) var(--rdp-animation_timing) forwards}.rdp-root[dir=rtl] .rdp-weeks_after_enter{animation:rdp-slide_in_left var(--rdp-animation_duration) var(--rdp-animation_timing) forwards}.rdp-root[dir=rtl] .rdp-weeks_before_exit{animation:rdp-slide_out_right var(--rdp-animation_duration) var(--rdp-animation_timing) forwards}.rdp-root[dir=rtl] .rdp-weeks_before_enter{animation:rdp-slide_in_right var(--rdp-animation_duration) var(--rdp-animation_timing) forwards}.rdp-root[dir=rtl] .rdp-weeks_after_exit{animation:rdp-slide_out_left var(--rdp-animation_duration) var(--rdp-animation_timing) forwards}@keyframes rdp-fade_in{0%{opacity:0}to{opacity:1}}@keyframes rdp-fade_out{0%{opacity:1}to{opacity:0}}.rdp-caption_after_enter{animation:rdp-fade_in var(--rdp-animation_duration) var(--rdp-animation_timing) forwards}.rdp-caption_after_exit{animation:rdp-fade_out var(--rdp-animation_duration) var(--rdp-animation_timing) forwards}.rdp-caption_before_enter{animation:rdp-fade_in var(--rdp-animation_duration) var(--rdp-animation_timing) forwards}.rdp-caption_before_exit{animation:rdp-fade_out var(--rdp-animation_duration) var(--rdp-animation_timing) forwards}*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgb(59 130 246/0.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgb(59 130 246/0.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }
2
+
3
+ /*
4
+ ! tailwindcss v3.4.19 | MIT License | https://tailwindcss.com
5
+ */*,:after,:before{box-sizing:border-box;border:0 solid #e5e7eb}:after,:before{--tw-content:""}:host,html{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:var(--font-sans),ui-sans-serif,system-ui,sans-serif;font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:var(--font-mono),ui-monospace,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}.card{border-radius:12px;border-width:1px;--tw-border-opacity:1;border-color:rgb(var(--border)/var(--tw-border-opacity,1));--tw-bg-opacity:1;background-color:rgb(var(--bg-surface)/var(--tw-bg-opacity,1));box-shadow:var(--shadow-card)}.card-elevated{background:rgb(var(--bg-elevated));box-shadow:var(--shadow-popover)}.card-pad{padding:1.25rem}@media (min-width:640px){.card-pad{padding:1.5rem}}.label{font-size:11px;font-weight:600;text-transform:uppercase;letter-spacing:.06em;--tw-text-opacity:1;color:rgb(var(--text-tertiary)/var(--tw-text-opacity,1))}.num-hero{overflow-wrap:break-word;font-size:1.875rem;line-height:2.25rem;font-weight:600;--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction);letter-spacing:-.025em;--tw-text-opacity:1;color:rgb(var(--text-primary)/var(--tw-text-opacity,1))}@media (min-width:640px){.num-hero{font-size:2rem;line-height:2.25rem}}.num-mid{font-size:1.5rem;line-height:2rem;font-weight:600;--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction);--tw-text-opacity:1;color:rgb(var(--text-primary)/var(--tw-text-opacity,1))}.num-mono{font-family:var(--font-mono),ui-monospace,monospace;--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.pill{display:inline-flex;align-items:center;border-radius:8px;padding:.125rem .5rem;font-size:.75rem;font-weight:500;line-height:1.25rem}.pill-muted{padding:.125rem .5rem;font-size:.75rem;background-color:rgb(var(--bg-surface-hi)/var(--tw-bg-opacity,1));color:rgb(var(--text-secondary)/var(--tw-text-opacity,1))}.btn,.pill-muted{display:inline-flex;align-items:center;border-radius:8px;font-weight:500;line-height:1.25rem;border-width:1px;--tw-border-opacity:1;border-color:rgb(var(--border)/var(--tw-border-opacity,1));--tw-bg-opacity:1;--tw-text-opacity:1}.btn{justify-content:center;gap:.375rem;background-color:rgb(var(--bg-surface)/var(--tw-bg-opacity,1));padding:.375rem .75rem;font-size:.875rem;color:rgb(var(--text-primary)/var(--tw-text-opacity,1));transition:background-color .15s,border-color .15s,color .15s,transform .1s,box-shadow .15s}.btn:hover:not(:disabled){background:rgb(var(--bg-surface-hi));border-color:rgb(var(--border-hi))}.btn:active:not(:disabled){transform:translateY(1px)}.btn:disabled{cursor:not-allowed;opacity:.5}.btn-ghost{display:inline-flex;align-items:center;justify-content:center;gap:.375rem;border-radius:8px;padding:.375rem .75rem;font-size:.875rem;line-height:1.25rem;font-weight:500;--tw-text-opacity:1;color:rgb(var(--text-secondary)/var(--tw-text-opacity,1));transition:background-color .15s,color .15s}.btn-ghost:hover:not(:disabled){color:rgb(var(--text-primary));background:rgb(var(--bg-surface-hi))}.btn-ghost:disabled{cursor:not-allowed;opacity:.4}.section-header{background:linear-gradient(to bottom,rgb(var(--bg-surface)) 0,rgb(var(--bg-surface-hi)/.4) 100%)}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.pointer-events-none{pointer-events:none}.\!visible{visibility:visible!important}.visible{visibility:visible}.collapse{visibility:collapse}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.inset-y-0{top:0;bottom:0}.-bottom-\[12px\]{bottom:-12px}.bottom-0{bottom:0}.left-0{left:0}.right-0{right:0}.top-0{top:0}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.z-50{z-index:50}.m-4{margin:1rem}.mx-auto{margin-left:auto;margin-right:auto}.mb-1{margin-bottom:.25rem}.mb-2{margin-bottom:.5rem}.mb-3{margin-bottom:.75rem}.ml-1{margin-left:.25rem}.ml-1\.5{margin-left:.375rem}.ml-auto{margin-left:auto}.mr-1{margin-right:.25rem}.mt-0\.5{margin-top:.125rem}.mt-1{margin-top:.25rem}.mt-1\.5{margin-top:.375rem}.mt-2{margin-top:.5rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.mt-auto{margin-top:auto}.\!block{display:block!important}.block{display:block}.inline-block{display:inline-block}.flex{display:flex}.inline-flex{display:inline-flex}.table{display:table}.grid{display:grid}.contents{display:contents}.\!hidden{display:none!important}.hidden{display:none}.aspect-square{aspect-ratio:1/1}.h-1{height:.25rem}.h-1\.5{height:.375rem}.h-12{height:3rem}.h-14{height:3.5rem}.h-2{height:.5rem}.h-2\.5{height:.625rem}.h-3{height:.75rem}.h-3\.5{height:.875rem}.h-4{height:1rem}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-64{height:16rem}.h-7{height:1.75rem}.h-72{height:18rem}.h-8{height:2rem}.h-\[2px\]{height:2px}.h-\[3px\]{height:3px}.h-full{height:100%}.max-h-48{max-height:12rem}.max-h-64{max-height:16rem}.max-h-72{max-height:18rem}.min-h-\[132px\]{min-height:132px}.min-h-\[160px\]{min-height:160px}.min-h-\[180px\]{min-height:180px}.min-h-\[232px\]{min-height:232px}.min-h-\[280px\]{min-height:280px}.min-h-\[64px\]{min-height:64px}.min-h-screen{min-height:100vh}.w-1\.5{width:.375rem}.w-12{width:3rem}.w-2{width:.5rem}.w-2\.5{width:.625rem}.w-20{width:5rem}.w-24{width:6rem}.w-28{width:7rem}.w-3\.5{width:.875rem}.w-32{width:8rem}.w-4{width:1rem}.w-48{width:12rem}.w-5{width:1.25rem}.w-56{width:14rem}.w-6{width:1.5rem}.w-7{width:1.75rem}.w-72{width:18rem}.w-8{width:2rem}.w-9{width:2.25rem}.w-\[26px\]{width:26px}.w-\[324px\]{width:324px}.w-full{width:100%}.min-w-0{min-width:0}.min-w-\[120px\]{min-width:120px}.min-w-\[180px\]{min-width:180px}.min-w-\[200px\]{min-width:200px}.min-w-\[80px\]{min-width:80px}.max-w-2xl{max-width:42rem}.max-w-7xl{max-width:80rem}.max-w-\[160px\]{max-width:160px}.max-w-\[180px\]{max-width:180px}.max-w-\[280px\]{max-width:280px}.max-w-\[320px\]{max-width:320px}.max-w-full{max-width:100%}.max-w-md{max-width:28rem}.flex-1{flex:1 1 0%}.flex-shrink-0,.shrink-0{flex-shrink:0}.translate-x-5{--tw-translate-x:1.25rem}.transform,.translate-x-5{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes pulse{50%{opacity:.5}}.animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}.cursor-help{cursor:help}.cursor-pointer{cursor:pointer}.cursor-progress{cursor:progress}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.resize{resize:both}.list-inside{list-style-position:inside}.list-disc{list-style-type:disc}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.grid-cols-\[auto_1fr\]{grid-template-columns:auto 1fr}.grid-cols-\[auto_1fr_auto\]{grid-template-columns:auto 1fr auto}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.items-start{align-items:flex-start}.items-center{align-items:center}.items-baseline{align-items:baseline}.items-stretch{align-items:stretch}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-0\.5{gap:.125rem}.gap-1{gap:.25rem}.gap-1\.5{gap:.375rem}.gap-2{gap:.5rem}.gap-2\.5{gap:.625rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-5{gap:1.25rem}.gap-\[3px\]{gap:3px}.gap-x-3{-moz-column-gap:.75rem;column-gap:.75rem}.gap-y-0\.5{row-gap:.125rem}.gap-y-1\.5{row-gap:.375rem}.gap-y-\[3px\]{row-gap:3px}.space-y-0\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-top:calc(.125rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.125rem * var(--tw-space-y-reverse))}.space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}.space-y-1\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-top:calc(.375rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.375rem * var(--tw-space-y-reverse))}.space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-top:calc(.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.5rem * var(--tw-space-y-reverse))}.space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-top:calc(.75rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.75rem * var(--tw-space-y-reverse))}.space-y-3\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-top:calc(.875rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.875rem * var(--tw-space-y-reverse))}.space-y-5>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-top:calc(1.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1.25rem * var(--tw-space-y-reverse))}.space-y-6>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-top:calc(1.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1.5rem * var(--tw-space-y-reverse))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.overflow-y-auto{overflow-y:auto}.truncate{overflow:hidden;text-overflow:ellipsis}.truncate,.whitespace-nowrap{white-space:nowrap}.whitespace-pre-wrap{white-space:pre-wrap}.break-words{overflow-wrap:break-word}.rounded{border-radius:.25rem}.rounded-\[3px\]{border-radius:3px}.rounded-\[4px\]{border-radius:4px}.rounded-button{border-radius:8px}.rounded-card{border-radius:12px}.rounded-full{border-radius:9999px}.rounded-md{border-radius:.375rem}.rounded-sm{border-radius:.125rem}.border{border-width:1px}.border-b{border-bottom-width:1px}.border-t{border-top-width:1px}.border-dashed{border-style:dashed}.border-border{--tw-border-opacity:1;border-color:rgb(var(--border)/var(--tw-border-opacity,1))}.border-border-hi{--tw-border-opacity:1;border-color:rgb(var(--border-hi)/var(--tw-border-opacity,1))}.border-border\/60{border-color:rgb(var(--border)/.6)}.border-brand{--tw-border-opacity:1;border-color:rgb(var(--brand)/var(--tw-border-opacity,1))}.border-brand\/20{border-color:rgb(var(--brand)/.2)}.border-brand\/40{border-color:rgb(var(--brand)/.4)}.border-danger\/20{border-color:rgb(var(--danger)/.2)}.border-success\/20{border-color:rgb(var(--success)/.2)}.border-transparent{border-color:transparent}.border-warning\/20{border-color:rgb(var(--warning)/.2)}.bg-bg{--tw-bg-opacity:1;background-color:rgb(var(--bg-base)/var(--tw-bg-opacity,1))}.bg-bg-elevated{--tw-bg-opacity:1;background-color:rgb(var(--bg-elevated)/var(--tw-bg-opacity,1))}.bg-bg-surface{--tw-bg-opacity:1;background-color:rgb(var(--bg-surface)/var(--tw-bg-opacity,1))}.bg-bg-surface-hi{--tw-bg-opacity:1;background-color:rgb(var(--bg-surface-hi)/var(--tw-bg-opacity,1))}.bg-bg-surface-hi\/20{background-color:rgb(var(--bg-surface-hi)/.2)}.bg-bg-surface-hi\/30{background-color:rgb(var(--bg-surface-hi)/.3)}.bg-bg-surface-hi\/40{background-color:rgb(var(--bg-surface-hi)/.4)}.bg-bg-surface-hi\/60{background-color:rgb(var(--bg-surface-hi)/.6)}.bg-brand{--tw-bg-opacity:1;background-color:rgb(var(--brand)/var(--tw-bg-opacity,1))}.bg-brand-strong{--tw-bg-opacity:1;background-color:rgb(var(--brand-strong)/var(--tw-bg-opacity,1))}.bg-brand\/10{background-color:rgb(var(--brand)/.1)}.bg-chart-cache-create{--tw-bg-opacity:1;background-color:rgb(var(--chart-cache-create)/var(--tw-bg-opacity,1))}.bg-chart-cache-create\/15{background-color:rgb(var(--chart-cache-create)/.15)}.bg-chart-cache-read{--tw-bg-opacity:1;background-color:rgb(var(--chart-cache-read)/var(--tw-bg-opacity,1))}.bg-chart-input{--tw-bg-opacity:1;background-color:rgb(var(--chart-input)/var(--tw-bg-opacity,1))}.bg-chart-output{--tw-bg-opacity:1;background-color:rgb(var(--chart-output)/var(--tw-bg-opacity,1))}.bg-danger{--tw-bg-opacity:1;background-color:rgb(var(--danger)/var(--tw-bg-opacity,1))}.bg-danger\/10{background-color:rgb(var(--danger)/.1)}.bg-success{--tw-bg-opacity:1;background-color:rgb(var(--success)/var(--tw-bg-opacity,1))}.bg-success\/10{background-color:rgb(var(--success)/.1)}.bg-warning{--tw-bg-opacity:1;background-color:rgb(var(--warning)/var(--tw-bg-opacity,1))}.bg-warning\/10{background-color:rgb(var(--warning)/.1)}.bg-gradient-to-l{background-image:linear-gradient(to left,var(--tw-gradient-stops))}.bg-gradient-to-r{background-image:linear-gradient(to right,var(--tw-gradient-stops))}.from-bg-surface{--tw-gradient-from:rgb(var(--bg-surface)/1) var(--tw-gradient-from-position);--tw-gradient-to:rgb(var(--bg-surface)/0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)}.from-brand{--tw-gradient-from:rgb(var(--brand)/1) var(--tw-gradient-from-position);--tw-gradient-to:rgb(var(--brand)/0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)}.from-brand\/0{--tw-gradient-from:rgb(var(--brand)/0) var(--tw-gradient-from-position);--tw-gradient-to:rgb(var(--brand)/0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)}.from-success\/0{--tw-gradient-from:rgb(var(--success)/0) var(--tw-gradient-from-position);--tw-gradient-to:rgb(var(--success)/0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)}.from-warning\/0{--tw-gradient-from:rgb(var(--warning)/0) var(--tw-gradient-from-position);--tw-gradient-to:rgb(var(--warning)/0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)}.via-brand\/70{--tw-gradient-to:rgb(var(--brand)/0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),rgb(var(--brand)/0.7) var(--tw-gradient-via-position),var(--tw-gradient-to)}.via-success\/70{--tw-gradient-to:rgb(var(--success)/0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),rgb(var(--success)/0.7) var(--tw-gradient-via-position),var(--tw-gradient-to)}.via-warning\/70{--tw-gradient-to:rgb(var(--warning)/0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),rgb(var(--warning)/0.7) var(--tw-gradient-via-position),var(--tw-gradient-to)}.to-brand-hover{--tw-gradient-to:rgb(var(--brand-hover)/1) var(--tw-gradient-to-position)}.to-brand\/0{--tw-gradient-to:rgb(var(--brand)/0) var(--tw-gradient-to-position)}.to-success\/0{--tw-gradient-to:rgb(var(--success)/0) var(--tw-gradient-to-position)}.to-transparent{--tw-gradient-to:transparent var(--tw-gradient-to-position)}.to-warning\/0{--tw-gradient-to:rgb(var(--warning)/0) var(--tw-gradient-to-position)}.object-contain{-o-object-fit:contain;object-fit:contain}.p-0{padding:0}.p-0\.5{padding:.125rem}.p-1{padding:.25rem}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-4{padding:1rem}.p-5{padding:1.25rem}.p-6{padding:1.5rem}.px-1{padding-left:.25rem;padding-right:.25rem}.px-1\.5{padding-left:.375rem;padding-right:.375rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-2\.5{padding-left:.625rem;padding-right:.625rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-3\.5{padding-left:.875rem;padding-right:.875rem}.px-4{padding-left:1rem;padding-right:1rem}.px-5{padding-left:1.25rem;padding-right:1.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.py-0\.5{padding-top:.125rem;padding-bottom:.125rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-1\.5{padding-top:.375rem;padding-bottom:.375rem}.py-12{padding-top:3rem;padding-bottom:3rem}.py-14{padding-top:3.5rem;padding-bottom:3.5rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-2\.5{padding-top:.625rem;padding-bottom:.625rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.py-4{padding-top:1rem;padding-bottom:1rem}.py-6{padding-top:1.5rem;padding-bottom:1.5rem}.py-8{padding-top:2rem;padding-bottom:2rem}.pb-1\.5{padding-bottom:.375rem}.pb-2{padding-bottom:.5rem}.pb-3{padding-bottom:.75rem}.pl-2{padding-left:.5rem}.pl-4{padding-left:1rem}.pr-1\.5{padding-right:.375rem}.pr-2{padding-right:.5rem}.pr-2\.5{padding-right:.625rem}.pt-1{padding-top:.25rem}.pt-2{padding-top:.5rem}.pt-3{padding-top:.75rem}.pt-4{padding-top:1rem}.pt-\[18px\]{padding-top:18px}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.text-2xl{font-size:1.5rem;line-height:2rem}.text-\[10px\]{font-size:10px}.text-\[11px\]{font-size:11px}.text-\[15px\]{font-size:15px}.text-\[9px\]{font-size:9px}.text-base{font-size:1rem;line-height:1.5rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-semibold{font-weight:600}.uppercase{text-transform:uppercase}.capitalize{text-transform:capitalize}.tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.leading-none{line-height:1}.leading-relaxed{line-height:1.625}.leading-snug{line-height:1.375}.leading-tight{line-height:1.25}.tracking-\[0\.06em\]{letter-spacing:.06em}.tracking-tight{letter-spacing:-.025em}.tracking-wide{letter-spacing:.025em}.text-brand{--tw-text-opacity:1;color:rgb(var(--brand)/var(--tw-text-opacity,1))}.text-brand\/70{color:rgb(var(--brand)/.7)}.text-chart-cache-create{--tw-text-opacity:1;color:rgb(var(--chart-cache-create)/var(--tw-text-opacity,1))}.text-danger{--tw-text-opacity:1;color:rgb(var(--danger)/var(--tw-text-opacity,1))}.text-success{--tw-text-opacity:1;color:rgb(var(--success)/var(--tw-text-opacity,1))}.text-text-primary{--tw-text-opacity:1;color:rgb(var(--text-primary)/var(--tw-text-opacity,1))}.text-text-secondary{--tw-text-opacity:1;color:rgb(var(--text-secondary)/var(--tw-text-opacity,1))}.text-text-tertiary{--tw-text-opacity:1;color:rgb(var(--text-tertiary)/var(--tw-text-opacity,1))}.text-warning{--tw-text-opacity:1;color:rgb(var(--warning)/var(--tw-text-opacity,1))}.text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity,1))}.text-white\/80{color:rgb(255 255 255/.8)}.underline{text-decoration-line:underline}.accent-brand{accent-color:rgb(var(--brand)/1)}.opacity-0{opacity:0}.opacity-100{opacity:1}.opacity-60{opacity:.6}.opacity-70{opacity:.7}.opacity-90{opacity:.9}.shadow-lg{--tw-shadow:0 10px 15px -3px rgb(0 0 0/0.1),0 4px 6px -4px rgb(0 0 0/0.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)}.shadow-lg,.shadow-popover{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.shadow-popover{--tw-shadow:var(--shadow-popover);--tw-shadow-colored:var(--shadow-popover)}.shadow-sm{--tw-shadow:0 1px 2px 0 rgb(0 0 0/0.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color)}.shadow-sm,.shadow-xl{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.shadow-xl{--tw-shadow:0 20px 25px -5px rgb(0 0 0/0.1),0 8px 10px -6px rgb(0 0 0/0.1);--tw-shadow-colored:0 20px 25px -5px var(--tw-shadow-color),0 8px 10px -6px var(--tw-shadow-color)}.outline-none{outline:2px solid transparent;outline-offset:2px}.ring-1{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.ring-brand\/40{--tw-ring-color:rgb(var(--brand)/0.4)}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.backdrop-blur-md{--tw-backdrop-blur:blur(12px)}.backdrop-blur-md,.backdrop-filter{backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.transition-\[transform\2c width\]{transition-property:transform,width;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-100{transition-duration:.1s}.duration-150{transition-duration:.15s}.duration-200{transition-duration:.2s}.duration-500{transition-duration:.5s}.ease-out-soft{transition-timing-function:var(--ease-out-soft)}.\[ccgauge\:api\]{ccgauge:api}.\[ccgauge\:indexer\]{ccgauge:indexer}.\[grid-template-columns\:auto_1fr\]{grid-template-columns:auto 1fr}.\[grid-template-columns\:repeat\(24\2c minmax\(0\2c 1fr\)\)\]{grid-template-columns:repeat(24,minmax(0,1fr))}.theme-dark,:root{--bg-base:10 10 10;--bg-surface:22 22 22;--bg-surface-hi:32 32 34;--bg-elevated:38 38 42;--border:38 38 42;--border-hi:64 64 70;--text-primary:250 250 250;--text-secondary:168 168 174;--text-tertiary:120 120 128;--brand:129 140 248;--brand-hover:165 180 252;--brand-strong:99 102 241;--success:34 197 94;--warning:250 204 21;--danger:248 113 113;--chart-input:96 165 250;--chart-output:251 146 60;--chart-cache-read:52 211 153;--chart-cache-create:167 139 250;--chart-grid:38 38 42;--chart-axis:120 120 128;--shadow-card:0 1px 0 0 rgb(255 255 255/0.02),0 4px 12px -4px rgb(0 0 0/0.4);--shadow-card-hover:0 1px 0 0 rgb(255 255 255/0.04),0 8px 24px -8px rgb(0 0 0/0.6);--shadow-popover:0 4px 12px -2px rgb(0 0 0/0.4),0 16px 48px -8px rgb(0 0 0/0.6);--ring-focus:129 140 248;--ease-out-soft:cubic-bezier(0.16,1,0.3,1)}.theme-light{--bg-base:252 252 253;--bg-surface:255 255 255;--bg-surface-hi:247 247 249;--bg-elevated:250 250 252;--border:226 226 232;--border-hi:200 200 208;--text-primary:17 17 23;--text-secondary:82 82 91;--text-tertiary:145 145 156;--brand:79 70 229;--brand-hover:67 56 202;--brand-strong:79 70 229;--success:22 163 74;--warning:217 119 6;--danger:220 38 38;--chart-input:37 99 235;--chart-output:234 88 12;--chart-cache-read:22 163 74;--chart-cache-create:124 58 237;--chart-grid:232 232 238;--chart-axis:113 113 122;--shadow-card:0 1px 2px 0 rgb(15 23 42/0.04),0 1px 3px 0 rgb(15 23 42/0.04);--shadow-card-hover:0 4px 12px -2px rgb(15 23 42/0.08),0 8px 32px -8px rgb(15 23 42/0.06);--shadow-popover:0 8px 24px -4px rgb(15 23 42/0.08),0 16px 48px -8px rgb(15 23 42/0.08);--ring-focus:79 70 229}:root{--font-sans:"Geist Sans","Inter",-apple-system,BlinkMacSystemFont,"Segoe UI",system-ui,"PingFang SC","Hiragino Sans GB","Microsoft YaHei",sans-serif;--font-mono:"Geist Mono","JetBrains Mono",ui-monospace,SFMono-Regular,Menlo,monospace}*{border-color:rgb(var(--border))}html{overflow-y:scroll;scrollbar-gutter:stable}body,html{background:rgb(var(--bg-base));color:rgb(var(--text-primary));font-family:var(--font-sans);font-feature-settings:"cv11","ss01","ss03";-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-rendering:optimizeLegibility}body{min-height:100vh}::-moz-selection{background:rgb(var(--brand)/.25);color:rgb(var(--text-primary))}::selection{background:rgb(var(--brand)/.25);color:rgb(var(--text-primary))}::-webkit-scrollbar{width:10px;height:10px}::-webkit-scrollbar-track{background:transparent}::-webkit-scrollbar-thumb{background:rgb(var(--border-hi)/.7);border:2px solid transparent;background-clip:padding-box;border-radius:6px}::-webkit-scrollbar-thumb:hover{background:rgb(var(--text-tertiary)/.7);background-clip:padding-box}.scrollbar-thin::-webkit-scrollbar{width:6px;height:6px}.scrollbar-thin::-webkit-scrollbar-thumb{background:rgb(var(--border-hi)/.5);border:0;border-radius:3px}.nav-scroller{scrollbar-width:none}.nav-scroller::-webkit-scrollbar{display:none;width:0;height:0}:where(button,a,input,select,textarea,[tabindex]):focus-visible{outline:2px solid rgb(var(--ring-focus)/.6);outline-offset:2px;border-radius:6px}@media (prefers-reduced-motion:reduce){*,:after,:before{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important;scroll-behavior:auto!important}}@keyframes dash-rise{0%{opacity:0;transform:translateY(8px)}to{opacity:1;transform:none}}@keyframes bar-grow{0%{transform:scaleX(0)}to{transform:scaleX(1)}}@keyframes shimmer{0%{background-position:-180% 0}to{background-position:180% 0}}.dash-stagger>*{animation:dash-rise .42s var(--ease-out-soft) both}.dash-stagger>:first-child{animation-delay:.02s}.dash-stagger>:nth-child(2){animation-delay:.07s}.dash-stagger>:nth-child(3){animation-delay:.12s}.dash-stagger>:nth-child(4){animation-delay:.17s}.dash-stagger>:nth-child(5){animation-delay:.22s}.dash-stagger>:nth-child(n+6){animation-delay:.26s}.bar-grow{transform-origin:left center;animation:bar-grow .6s var(--ease-out-soft) both}.skeleton-shimmer{background-color:rgb(var(--bg-surface-hi));background-image:linear-gradient(90deg,transparent 0,rgb(var(--text-tertiary)/.08) 50%,transparent 100%);background-size:180% 100%;background-repeat:no-repeat;animation:shimmer 1.5s ease-in-out infinite}@media (prefers-reduced-motion:reduce){.bar-grow,.dash-stagger>*{animation:none!important;transform:none!important;opacity:1!important}.skeleton-shimmer{animation:none!important;background-image:none!important}}.divider-soft{border-top:1px solid rgb(var(--border))}html[data-usage-overview=hidden] .usage-overview-block{display:none}.rdp-root{--rdp-accent-color:rgb(var(--brand-strong));--rdp-accent-background-color:rgb(var(--brand)/0.14);--rdp-today-color:rgb(var(--brand));--rdp-day-height:2.25rem;--rdp-day-width:2.25rem;--rdp-day_button-height:2.25rem;--rdp-day_button-width:2.25rem;--rdp-day_button-border-radius:8px;--rdp-day_button-border:1px solid transparent;--rdp-nav_button-height:1.75rem;--rdp-nav_button-width:1.75rem;--rdp-disabled-opacity:0.32;--rdp-outside-opacity:0.32;--rdp-selected-border:none;--rdp-weekday-opacity:1;--rdp-months-gap:0.75rem}.rdp-caption_label,.rdp-root{color:rgb(var(--text-primary))}.rdp-caption_label{font-weight:600;font-size:.875rem;letter-spacing:-.005em}.rdp-weekday{color:rgb(var(--text-tertiary));font-weight:600;font-size:.6875rem;letter-spacing:.04em;text-transform:uppercase;padding-bottom:.25rem}.rdp-day_button{font-weight:500;font-size:.8125rem;font-variant-numeric:tabular-nums;color:rgb(var(--text-primary));transition:background-color .15s,color .15s,box-shadow .15s}.rdp-day_button:hover:not([disabled]):not(.rdp-selected .rdp-day_button){background-color:rgb(var(--bg-surface-hi));color:rgb(var(--text-primary))}.rdp-day_button:focus-visible{outline:none;box-shadow:0 0 0 2px rgb(var(--brand)/.4);z-index:1}.rdp-selected .rdp-day_button{font-weight:600}.rdp-today:not(.rdp-selected) .rdp-day_button{color:rgb(var(--brand))}.rdp-today .rdp-day_button{position:relative}.rdp-today .rdp-day_button:after{content:"";position:absolute;left:50%;bottom:3px;width:3px;height:3px;margin-left:-1.5px;border-radius:999px;background:rgb(var(--brand))}.rdp-today.rdp-selected .rdp-day_button:after{background:rgb(255 255 255/.85)}.rdp-button_next,.rdp-button_previous{color:rgb(var(--text-tertiary));border-radius:8px;transition:background-color .15s,color .15s}.rdp-button_next:hover:not([disabled]),.rdp-button_previous:hover:not([disabled]){color:rgb(var(--text-primary));background-color:rgb(var(--bg-surface-hi))}.rdp-button_next:focus-visible,.rdp-button_previous:focus-visible{outline:none;box-shadow:0 0 0 2px rgb(var(--brand)/.4)}.rdp-button_next:disabled,.rdp-button_previous:disabled{opacity:.4;cursor:not-allowed}.rdp-range_middle .rdp-day_button{background-color:transparent;color:rgb(var(--text-primary));font-weight:500}.rdp-month_caption{padding:0 0 .5rem}.placeholder\:text-text-tertiary::-moz-placeholder{--tw-text-opacity:1;color:rgb(var(--text-tertiary)/var(--tw-text-opacity,1))}.placeholder\:text-text-tertiary::placeholder{--tw-text-opacity:1;color:rgb(var(--text-tertiary)/var(--tw-text-opacity,1))}.last\:border-b-0:last-child{border-bottom-width:0}.hover\:z-10:hover{z-index:10}.hover\:scale-125:hover{--tw-scale-x:1.25;--tw-scale-y:1.25;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\:border-border-hi:hover{--tw-border-opacity:1;border-color:rgb(var(--border-hi)/var(--tw-border-opacity,1))}.hover\:border-brand\/60:hover{border-color:rgb(var(--brand)/.6)}.hover\:border-text-tertiary:hover{--tw-border-opacity:1;border-color:rgb(var(--text-tertiary)/var(--tw-border-opacity,1))}.hover\:bg-bg-surface-hi:hover{--tw-bg-opacity:1;background-color:rgb(var(--bg-surface-hi)/var(--tw-bg-opacity,1))}.hover\:bg-bg-surface-hi\/30:hover{background-color:rgb(var(--bg-surface-hi)/.3)}.hover\:bg-bg-surface-hi\/40:hover{background-color:rgb(var(--bg-surface-hi)/.4)}.hover\:bg-bg-surface-hi\/60:hover{background-color:rgb(var(--bg-surface-hi)/.6)}.hover\:bg-brand-hover:hover{--tw-bg-opacity:1;background-color:rgb(var(--brand-hover)/var(--tw-bg-opacity,1))}.hover\:bg-brand\/15:hover{background-color:rgb(var(--brand)/.15)}.hover\:bg-brand\/20:hover{background-color:rgb(var(--brand)/.2)}.hover\:text-brand:hover{--tw-text-opacity:1;color:rgb(var(--brand)/var(--tw-text-opacity,1))}.hover\:text-text-primary:hover{--tw-text-opacity:1;color:rgb(var(--text-primary)/var(--tw-text-opacity,1))}.hover\:opacity-90:hover{opacity:.9}.hover\:ring-1:hover{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.hover\:ring-brand\/60:hover{--tw-ring-color:rgb(var(--brand)/0.6)}.focus\:border-border-hi:focus{--tw-border-opacity:1;border-color:rgb(var(--border-hi)/var(--tw-border-opacity,1))}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus-visible\:ring-2:focus-visible{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus-visible\:ring-brand\/40:focus-visible{--tw-ring-color:rgb(var(--brand)/0.4)}.disabled\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\:opacity-40:disabled{opacity:.4}.disabled\:hover\:bg-brand-strong:hover:disabled{--tw-bg-opacity:1;background-color:rgb(var(--brand-strong)/var(--tw-bg-opacity,1))}.group:hover .group-hover\:text-brand{--tw-text-opacity:1;color:rgb(var(--brand)/var(--tw-text-opacity,1))}.group:hover .group-hover\:brightness-110{--tw-brightness:brightness(1.1);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}@media (min-width:640px){.sm\:mt-0{margin-top:0}.sm\:inline{display:inline}.sm\:flex{display:flex}.sm\:flex-row{flex-direction:row}.sm\:items-start{align-items:flex-start}.sm\:items-end{align-items:flex-end}.sm\:items-baseline{align-items:baseline}.sm\:justify-between{justify-content:space-between}.sm\:gap-2\.5{gap:.625rem}.sm\:gap-4{gap:1rem}.sm\:space-y-6>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-top:calc(1.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1.5rem * var(--tw-space-y-reverse))}.sm\:p-6{padding:1.5rem}.sm\:px-3{padding-left:.75rem;padding-right:.75rem}.sm\:px-6{padding-left:1.5rem;padding-right:1.5rem}.sm\:py-16{padding-top:4rem;padding-bottom:4rem}.sm\:py-8{padding-top:2rem;padding-bottom:2rem}.sm\:pt-5{padding-top:1.25rem}.sm\:pt-\[22px\]{padding-top:22px}.sm\:text-\[1\.75rem\]{font-size:1.75rem}}@media (min-width:768px){.md\:flex{display:flex}.md\:w-\[170px\]{width:170px}.md\:shrink-0{flex-shrink:0}.md\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.md\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.md\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.md\:flex-row{flex-direction:row}.md\:flex-col{flex-direction:column}.md\:gap-8{gap:2rem}}@media (min-width:1024px){.lg\:col-span-2{grid-column:span 2/span 2}.lg\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.lg\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}}
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ccgauge",
3
- "version": "1.1.5",
3
+ "version": "1.2.0",
4
4
  "description": "Local web dashboard for Claude Code and OpenAI Codex CLI token usage and cost",
5
5
  "keywords": [
6
6
  "claude",
@@ -64,7 +64,8 @@
64
64
  "start:next": "next start -p 3737",
65
65
  "lint": "eslint .",
66
66
  "typecheck": "tsc --noEmit",
67
- "test": "node --experimental-strip-types --no-warnings scripts/test-codex-parser.mjs && node --experimental-strip-types --no-warnings scripts/test-turns.mjs && node --experimental-strip-types --no-warnings scripts/test-sidechain.mjs && node --experimental-strip-types --no-warnings scripts/test-source-merge.mjs && node --experimental-strip-types --no-warnings scripts/test-cost-from-usage.mjs && node --experimental-strip-types --no-warnings scripts/test-range.mjs && node scripts/check-parser-versions.mjs && node scripts/check-readme-images.mjs",
67
+ "update-pricing": "node scripts/update-pricing.mjs",
68
+ "test": "node --experimental-strip-types --no-warnings scripts/test-codex-parser.mjs && node --experimental-strip-types --no-warnings scripts/test-pricing-snapshot.mjs && node --experimental-strip-types --no-warnings scripts/test-turns.mjs && node --experimental-strip-types --no-warnings scripts/test-sidechain.mjs && node --experimental-strip-types --no-warnings scripts/test-source-merge.mjs && node --experimental-strip-types --no-warnings scripts/test-cost-from-usage.mjs && node --experimental-strip-types --no-warnings scripts/test-range.mjs && node scripts/check-parser-versions.mjs && node scripts/check-readme-images.mjs",
68
69
  "test:mcp": "node scripts/test-mcp-server.mjs",
69
70
  "clean": "node -e \"for (const p of ['.next','node_modules','tsconfig.tsbuildinfo']) require('node:fs').rmSync(p,{recursive:true,force:true})\"",
70
71
  "screenshots": "node scripts/screenshots.mjs",
package/CHANGELOG.md CHANGED
@@ -5,6 +5,149 @@ All notable changes to **ccgauge** are documented here.
5
5
  The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and
6
6
  this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [1.2.0] — 2026-06-17
9
+
10
+ Two big themes: **Codex billing accuracy** is back in line with
11
+ [ccusage](https://github.com/ccusage/ccusage) (the de-facto reference for
12
+ multi-agent token accounting), and the **usage page no longer freezes** when
13
+ you flip ranges or sources.
14
+
15
+ On the billing side: Codex transcripts had three independent issues that
16
+ combined to push numbers off by ~20% in either direction. Reasoning tokens
17
+ were being double-counted at the output rate (output already includes them in
18
+ Codex's raw payload — verified against real `~/.codex` rollouts: `input +
19
+ output == total`), the fast / priority service tier was billed at the
20
+ standard rate (it's 2× for most models, 2.5× for `gpt-5.5`), and the most
21
+ commonly used model strings (`gpt-5.2-codex`, `gpt-5.2` — together >65% of
22
+ local Codex requests on the maintainer's machine) had no entry in the price
23
+ table and silently fell back to the priciest gpt-5.5 tier. Costs now match
24
+ ccusage to the cent on identical data; on a high-volume Codex priority-tier
25
+ session the corrected total came in 2.4× higher than before — entirely from
26
+ adding the missing multiplier and pricing keys, not from new spend.
27
+
28
+ On the usage page: every filter change re-streamed ~300 KB of HTML and
29
+ fully re-hydrated a 25-row table with portal hovercards. Combined with no
30
+ visible click feedback, this looked like the UI was frozen. The page is now
31
+ a thin shell that boots in ~20 KB, and the chart / KPIs / table fetch from
32
+ a new `/api/turns` endpoint with stale-while-revalidate caching. Toggling
33
+ 7d ↔ 30d ↔ all is now ~30 ms after the first hit (was ~150 ms every time),
34
+ and every filter control flashes pending state on click so it's obvious
35
+ the input landed.
36
+
37
+ ### Fixed
38
+
39
+ - **Codex reasoning tokens were billed twice.** The parser added
40
+ `reasoning_output_tokens` on top of `output_tokens` before applying the
41
+ output rate, but Codex's raw payload already counts reasoning inside
42
+ `output_tokens` (every `total = input + output` invariant holds in real
43
+ rollouts). Output is now billed once; `reasoning_tokens` stays on the
44
+ record as a display-only subset, mirroring ccusage's
45
+ `reasoningOutputTokens` column. `parserVersion` bumps to
46
+ `codex-v6-output-excludes-readded-reasoning` so any indexed snapshot
47
+ rebuilds with the corrected totals.
48
+ - **Fast / priority service tier was missing.** When
49
+ `~/.codex/config.toml` sets `service_tier = "fast" | "priority"`, costs
50
+ scale per model (gpt-5.5 ×2.5, others ×2, ported from ccusage's
51
+ `fast-multiplier-overrides.json`). Standard-tier sessions are unchanged.
52
+ - **`gpt-5.2`, `gpt-5.2-codex`, `gpt-5.1`, `gpt-5.1-codex` had no pricing
53
+ rows** and resolved via family-fallback to the priciest gpt-5.5 tier
54
+ (5 / 30 per 1 M tokens). Real Codex logs use these strings constantly —
55
+ the maintainer's archive had ~1,600 requests on `gpt-5.2-codex` alone,
56
+ every one of which was over-billed by ~3×. Added with ccusage's values
57
+ (gpt-5.2-codex 1.75 / 14, gpt-5.1 1.25 / 10) so they resolve `exact`.
58
+
59
+ ### Added
60
+
61
+ - **`·fast` marker on the usage page model column** when the active Codex
62
+ config requests the fast / priority tier. Shows as `GPT-5.5·fast` in
63
+ amber with a tooltip explaining the 2×+ rate, on Codex rows only.
64
+ Source-aware: Claude rows stay clean even on mixed (`source=all`) views.
65
+ - **Build-time LiteLLM snapshot for builtin pricing.** New
66
+ `pnpm update-pricing` script fetches BerriAI/litellm's
67
+ `model_prices_and_context_window.json`, filters to Anthropic + OpenAI
68
+ chat models, transforms per-token costs into ccgauge's per-1 M
69
+ `Pricing` shape (Anthropic `cacheCreation1h = 2× input`, mirroring
70
+ ccusage's hard-coded multiplier; OpenAI keeps cache-write tiers at 0),
71
+ and writes a committed `lib/pricing/litellm-pricing.generated.{js,d.ts}`.
72
+ Runtime stays fully offline — the snapshot IS the pin. The hand-curated
73
+ layer shrinks to seven legacy Claude bare names that LiteLLM doesn't
74
+ carry; everything LiteLLM tracks is sourced from there.
75
+
76
+ ### Performance
77
+
78
+ - **Usage page page-load HTML cut from ~300 KB to ~34 KB**, constant
79
+ across filters. `force-dynamic` SSR no longer re-streams every record
80
+ inline as RSC payload; the page now ships a shell only.
81
+ - **Filter changes feed from a JSON endpoint with stale-while-revalidate.**
82
+ New `/api/turns` returns totals, trend buckets, the paginated turn
83
+ slice, and the filter dropdown contents (~30 KB). A client-side URL-keyed
84
+ cache renders the previous payload immediately on revisit, so 7d ↔ 30d
85
+ toggles drop from ~150 ms each to ~30 ms after the first hit.
86
+ - **Every filter nav now uses `useTransition`** with visible pending
87
+ feedback (control opacity-60 + `cursor-progress` + `aria-busy`, table
88
+ card additionally drops pointer events). Range picker, segmented
89
+ picker, multi-selects, table sort / page / search, source switcher —
90
+ all share the treatment. Eliminates the "did my click land?" gap.
91
+ - **Scan-derived data is cached on the indexer snapshot.**
92
+ `allModels` / `allProjects` use a WeakMap on the scan object; new
93
+ `recordsToTurnRowsCached` is an LRU sub-keyed on
94
+ `(source, range token, models, projects)`. Using the range *token*
95
+ instead of the resolved `fromIso/toIso` avoids `Date.now()` drift, so
96
+ the same scan + same filter combo hits the cache on every revisit.
97
+
98
+ ### Changed
99
+
100
+ - **GPT-5 base variants (`gpt-5`, `gpt-5-mini`, `gpt-5-nano`, `gpt-5-codex`)
101
+ now follow LiteLLM**: 1.25 / 10, 0.25 / 2, 0.05 / 0.4, 1.25 / 10
102
+ respectively (these are the same numbers ccusage uses). The 1.1.6
103
+ alignment chose openai.com values for them; this release picks one
104
+ source of truth for the whole table. No real-data impact for the
105
+ maintainer's transcripts — none of those four ids appears in local
106
+ Codex logs.
107
+ - **`AutoRefresh` now dispatches a `ccgauge:refresh` window event** so the
108
+ client-side data island can re-fetch alongside the existing
109
+ `router.refresh()`. Existing pages without an island are unaffected.
110
+
111
+ ## [1.1.6] — 2026-06-17
112
+
113
+ Brings GPT pricing back in line with [OpenAI's official rates](https://openai.com/api/pricing/)
114
+ and trims the settings page model table to the variants people actually run today.
115
+
116
+ ### Fixed
117
+
118
+ - **GPT-5 family prices were wrong across the board.** Every gpt-5\* entry was
119
+ carrying the old launch-window numbers (`$1.25 / $10` per 1 M tokens),
120
+ which under-reported cost on every Codex CLI session run since the
121
+ rate change. Updated to current official rates:
122
+ `gpt-5.5` $5 / $30 (cached $0.50), `gpt-5.4` $2.50 / $15 (cached $0.25),
123
+ and `gpt-5.3-codex` $1.75 / $14 (cached $0.175). The bare-name
124
+ Codex CLI aliases (`gpt-5`, `gpt-5-mini`, `gpt-5-nano`, `gpt-5-codex`)
125
+ are mapped to the matching `gpt-5.4` tier so existing transcripts cost
126
+ out correctly without manual remapping.
127
+
128
+ ### Added
129
+
130
+ - **`gpt-5.4-mini`, `gpt-5.4-nano`, `gpt-5.3-codex`, `gpt-5-codex`** as
131
+ first-class pricing entries, so Codex CLI runs on those exact ids get
132
+ an `exact` match instead of falling through to family-fallback.
133
+
134
+ ### Changed
135
+
136
+ - **Settings → Pricing table trimmed to the models in active use.**
137
+ Codex now shows `gpt-5*` only; the legacy `gpt-4.1`, `o3`, `o4-mini`
138
+ rows are hidden (their prices are still in the underlying table, so
139
+ any historical session involving them still costs out accurately).
140
+ Claude shows only `haiku-4-5`, `sonnet-4-6`, `opus-4-6` and newer,
141
+ plus the `fable-5` family — older snapshots are kept in the data for
142
+ the same backward-compat reason but no longer clutter the UI.
143
+
144
+ ### Removed
145
+
146
+ - **`gpt-5.5-mini` and `gpt-5.5-nano` pricing rows.** These ids never
147
+ shipped on the OpenAI pricing page; they were placeholder rows from
148
+ the initial 5.5 announcement and would have masked real usage of the
149
+ `gpt-5.4-mini` / `gpt-5.4-nano` ids that do exist.
150
+
8
151
  ## [1.1.5] — 2026-06-11
9
152
 
10
153
  Adds pricing support for Claude Fable 5 and fixes a turn-grouping regression