@sleep2agi/agent-network-dashboard 0.4.5-preview.47 → 0.4.5-preview.49

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 (147) hide show
  1. package/.next/BUILD_ID +1 -1
  2. package/.next/build-manifest.json +3 -3
  3. package/.next/diagnostics/route-bundle-stats.json +6 -6
  4. package/.next/fallback-build-manifest.json +3 -3
  5. package/.next/prerender-manifest.json +3 -3
  6. package/.next/server/app/_global-error.html +1 -1
  7. package/.next/server/app/_global-error.rsc +1 -1
  8. package/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  9. package/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  10. package/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  11. package/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  12. package/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  13. package/.next/server/app/_not-found.html +1 -1
  14. package/.next/server/app/_not-found.rsc +1 -1
  15. package/.next/server/app/_not-found.segments/_full.segment.rsc +1 -1
  16. package/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
  17. package/.next/server/app/_not-found.segments/_index.segment.rsc +1 -1
  18. package/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
  19. package/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
  20. package/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
  21. package/.next/server/app/admin.html +1 -1
  22. package/.next/server/app/admin.rsc +1 -1
  23. package/.next/server/app/admin.segments/_full.segment.rsc +1 -1
  24. package/.next/server/app/admin.segments/_head.segment.rsc +1 -1
  25. package/.next/server/app/admin.segments/_index.segment.rsc +1 -1
  26. package/.next/server/app/admin.segments/_tree.segment.rsc +1 -1
  27. package/.next/server/app/admin.segments/admin/__PAGE__.segment.rsc +1 -1
  28. package/.next/server/app/admin.segments/admin.segment.rsc +1 -1
  29. package/.next/server/app/index.html +2 -2
  30. package/.next/server/app/index.rsc +2 -2
  31. package/.next/server/app/index.segments/__PAGE__.segment.rsc +2 -2
  32. package/.next/server/app/index.segments/_full.segment.rsc +2 -2
  33. package/.next/server/app/index.segments/_head.segment.rsc +1 -1
  34. package/.next/server/app/index.segments/_index.segment.rsc +1 -1
  35. package/.next/server/app/index.segments/_tree.segment.rsc +1 -1
  36. package/.next/server/app/login/page_client-reference-manifest.js +1 -1
  37. package/.next/server/app/login.html +2 -2
  38. package/.next/server/app/login.rsc +2 -2
  39. package/.next/server/app/login.segments/_full.segment.rsc +2 -2
  40. package/.next/server/app/login.segments/_head.segment.rsc +1 -1
  41. package/.next/server/app/login.segments/_index.segment.rsc +1 -1
  42. package/.next/server/app/login.segments/_tree.segment.rsc +1 -1
  43. package/.next/server/app/login.segments/login/__PAGE__.segment.rsc +2 -2
  44. package/.next/server/app/login.segments/login.segment.rsc +1 -1
  45. package/.next/server/app/logs.html +1 -1
  46. package/.next/server/app/logs.rsc +1 -1
  47. package/.next/server/app/logs.segments/_full.segment.rsc +1 -1
  48. package/.next/server/app/logs.segments/_head.segment.rsc +1 -1
  49. package/.next/server/app/logs.segments/_index.segment.rsc +1 -1
  50. package/.next/server/app/logs.segments/_tree.segment.rsc +1 -1
  51. package/.next/server/app/logs.segments/logs/__PAGE__.segment.rsc +1 -1
  52. package/.next/server/app/logs.segments/logs.segment.rsc +1 -1
  53. package/.next/server/app/messages.html +1 -1
  54. package/.next/server/app/messages.rsc +1 -1
  55. package/.next/server/app/messages.segments/_full.segment.rsc +1 -1
  56. package/.next/server/app/messages.segments/_head.segment.rsc +1 -1
  57. package/.next/server/app/messages.segments/_index.segment.rsc +1 -1
  58. package/.next/server/app/messages.segments/_tree.segment.rsc +1 -1
  59. package/.next/server/app/messages.segments/messages/__PAGE__.segment.rsc +1 -1
  60. package/.next/server/app/messages.segments/messages.segment.rsc +1 -1
  61. package/.next/server/app/node.html +1 -1
  62. package/.next/server/app/node.rsc +1 -1
  63. package/.next/server/app/node.segments/_full.segment.rsc +1 -1
  64. package/.next/server/app/node.segments/_head.segment.rsc +1 -1
  65. package/.next/server/app/node.segments/_index.segment.rsc +1 -1
  66. package/.next/server/app/node.segments/_tree.segment.rsc +1 -1
  67. package/.next/server/app/node.segments/node/__PAGE__.segment.rsc +1 -1
  68. package/.next/server/app/node.segments/node.segment.rsc +1 -1
  69. package/.next/server/app/nodes.html +1 -1
  70. package/.next/server/app/nodes.rsc +1 -1
  71. package/.next/server/app/nodes.segments/_full.segment.rsc +1 -1
  72. package/.next/server/app/nodes.segments/_head.segment.rsc +1 -1
  73. package/.next/server/app/nodes.segments/_index.segment.rsc +1 -1
  74. package/.next/server/app/nodes.segments/_tree.segment.rsc +1 -1
  75. package/.next/server/app/nodes.segments/nodes/__PAGE__.segment.rsc +1 -1
  76. package/.next/server/app/nodes.segments/nodes.segment.rsc +1 -1
  77. package/.next/server/app/page_client-reference-manifest.js +1 -1
  78. package/.next/server/app/server-logs.html +1 -1
  79. package/.next/server/app/server-logs.rsc +1 -1
  80. package/.next/server/app/server-logs.segments/_full.segment.rsc +1 -1
  81. package/.next/server/app/server-logs.segments/_head.segment.rsc +1 -1
  82. package/.next/server/app/server-logs.segments/_index.segment.rsc +1 -1
  83. package/.next/server/app/server-logs.segments/_tree.segment.rsc +1 -1
  84. package/.next/server/app/server-logs.segments/server-logs/__PAGE__.segment.rsc +1 -1
  85. package/.next/server/app/server-logs.segments/server-logs.segment.rsc +1 -1
  86. package/.next/server/app/settings/networks.html +1 -1
  87. package/.next/server/app/settings/networks.rsc +1 -1
  88. package/.next/server/app/settings/networks.segments/_full.segment.rsc +1 -1
  89. package/.next/server/app/settings/networks.segments/_head.segment.rsc +1 -1
  90. package/.next/server/app/settings/networks.segments/_index.segment.rsc +1 -1
  91. package/.next/server/app/settings/networks.segments/_tree.segment.rsc +1 -1
  92. package/.next/server/app/settings/networks.segments/settings/networks/__PAGE__.segment.rsc +1 -1
  93. package/.next/server/app/settings/networks.segments/settings/networks.segment.rsc +1 -1
  94. package/.next/server/app/settings/networks.segments/settings.segment.rsc +1 -1
  95. package/.next/server/app/settings/page_client-reference-manifest.js +1 -1
  96. package/.next/server/app/settings/tokens.html +1 -1
  97. package/.next/server/app/settings/tokens.rsc +1 -1
  98. package/.next/server/app/settings/tokens.segments/_full.segment.rsc +1 -1
  99. package/.next/server/app/settings/tokens.segments/_head.segment.rsc +1 -1
  100. package/.next/server/app/settings/tokens.segments/_index.segment.rsc +1 -1
  101. package/.next/server/app/settings/tokens.segments/_tree.segment.rsc +1 -1
  102. package/.next/server/app/settings/tokens.segments/settings/tokens/__PAGE__.segment.rsc +1 -1
  103. package/.next/server/app/settings/tokens.segments/settings/tokens.segment.rsc +1 -1
  104. package/.next/server/app/settings/tokens.segments/settings.segment.rsc +1 -1
  105. package/.next/server/app/settings.html +2 -2
  106. package/.next/server/app/settings.rsc +2 -2
  107. package/.next/server/app/settings.segments/_full.segment.rsc +2 -2
  108. package/.next/server/app/settings.segments/_head.segment.rsc +1 -1
  109. package/.next/server/app/settings.segments/_index.segment.rsc +1 -1
  110. package/.next/server/app/settings.segments/_tree.segment.rsc +1 -1
  111. package/.next/server/app/settings.segments/settings/__PAGE__.segment.rsc +2 -2
  112. package/.next/server/app/settings.segments/settings.segment.rsc +1 -1
  113. package/.next/server/app/tasks/page_client-reference-manifest.js +1 -1
  114. package/.next/server/app/tasks.html +2 -2
  115. package/.next/server/app/tasks.rsc +2 -2
  116. package/.next/server/app/tasks.segments/_full.segment.rsc +2 -2
  117. package/.next/server/app/tasks.segments/_head.segment.rsc +1 -1
  118. package/.next/server/app/tasks.segments/_index.segment.rsc +1 -1
  119. package/.next/server/app/tasks.segments/_tree.segment.rsc +1 -1
  120. package/.next/server/app/tasks.segments/tasks/__PAGE__.segment.rsc +2 -2
  121. package/.next/server/app/tasks.segments/tasks.segment.rsc +1 -1
  122. package/.next/server/chunks/ssr/_0nne7mz._.js +1 -1
  123. package/.next/server/chunks/ssr/_0nne7mz._.js.map +1 -1
  124. package/.next/server/chunks/ssr/app_0aum_g5._.js +1 -1
  125. package/.next/server/chunks/ssr/app_0aum_g5._.js.map +1 -1
  126. package/.next/server/chunks/ssr/app_0esuljp._.js +1 -1
  127. package/.next/server/chunks/ssr/app_0esuljp._.js.map +1 -1
  128. package/.next/server/chunks/ssr/app_tasks_page_tsx_0z-d6mp._.js +1 -1
  129. package/.next/server/chunks/ssr/app_tasks_page_tsx_0z-d6mp._.js.map +1 -1
  130. package/.next/server/middleware-build-manifest.js +3 -3
  131. package/.next/server/pages/404.html +1 -1
  132. package/.next/server/pages/500.html +1 -1
  133. package/.next/server/server-reference-manifest.js +1 -1
  134. package/.next/server/server-reference-manifest.json +1 -1
  135. package/.next/static/chunks/{0g394kqz_d5.x.js → 0.wzhq18qxm-w.js} +1 -1
  136. package/.next/static/chunks/{01b7jccy489m9.js → 06xte7baw6rdl.js} +1 -1
  137. package/.next/static/chunks/{0p04wc_hbme45.js → 0rirja6g.ixyp.js} +1 -1
  138. package/.next/static/chunks/{0ad_inb_djtqp.js → 0~eyez47uqr~6.js} +1 -1
  139. package/.next/trace +2 -2
  140. package/.next/trace-build +1 -1
  141. package/app/lib/status.ts +63 -0
  142. package/app/page.tsx +6 -4
  143. package/app/tasks/page.tsx +10 -9
  144. package/package.json +1 -1
  145. /package/.next/static/{9VsW1EX145Y-r_sS0or56 → G7GAy-2maF5UanqZzAohm}/_buildManifest.js +0 -0
  146. /package/.next/static/{9VsW1EX145Y-r_sS0or56 → G7GAy-2maF5UanqZzAohm}/_clientMiddlewareManifest.js +0 -0
  147. /package/.next/static/{9VsW1EX145Y-r_sS0or56 → G7GAy-2maF5UanqZzAohm}/_ssgManifest.js +0 -0
@@ -1 +1 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,18150,e=>{"use strict";e.s(["formatUptime",0,function(e){let t=Math.floor(e/3600),a=Math.floor(e%3600/60);return t>0?`${t}h ${a}m`:`${a}m`},"timeAgo",0,function(e){if(!e)return"--";let t=Math.floor((Date.now()-new Date(e.replace(" ","T")+"Z").getTime())/1e3);return t<60?`${t}s ago`:t<3600?`${Math.floor(t/60)}m ago`:t<86400?`${Math.floor(t/3600)}h ago`:`${Math.floor(t/86400)}d ago`}])},69874,e=>{"use strict";var t=e.i(18050);let a=[180,200,220,270,300,330,30,90];e.s(["AliasAvatar",0,function({alias:e,size:s=28,className:r=""}){let n=function(e){let t=0;for(let a=0;a<e.length;a++)t=31*t+e.charCodeAt(a)>>>0;let s=a[t%a.length];return{bg:`hsl(${s} 55% 22%)`,ring:`hsl(${s} 60% 45%)`,text:`hsl(${s} 80% 78%)`}}(e),i=Math.max(9,Math.round(.42*s));return(0,t.jsx)("span",{className:`anet-alias-avatar inline-flex items-center justify-center rounded-full border shrink-0 font-semibold ${r}`,style:{width:s,height:s,fontSize:i,backgroundColor:n.bg,borderColor:n.ring,color:n.text},title:e,"aria-hidden":!0,children:e?(e.trim().match(/[\p{L}\p{N}]/u)?.[0]||e.trim()[0]||"·").toUpperCase():"·"})}])},95356,e=>{"use strict";var t=e.i(18050),a=e.i(71645),s=e.i(22016);let r={nodes:{title:"No agents in this network",sub:"Agent sessions will appear here once they connect to the CommHub."},tasks:{title:"No tasks yet",sub:"Tasks will appear here when agents send them via CommHub."},messages:{title:"No messages",sub:"Messages between agents will appear here."},logs:{title:"No audit logs",sub:"Events will appear here when users register, login, or perform actions."},tokens:{title:"No API tokens",sub:"Create one to authenticate CLI tools and external integrations."},networks:{title:"No networks found",sub:"Create one or sign in with V3 auth to see your networks."},generic:{title:"Nothing here yet",sub:"Data will appear here once available."}};function n({variant:e,size:a}){let s={width:a,height:a},r={fill:"none",stroke:"currentColor",strokeWidth:1.25,strokeLinecap:"round",strokeLinejoin:"round"};switch(e){case"nodes":return(0,t.jsx)("svg",{viewBox:"0 0 64 64",...s,children:(0,t.jsxs)("g",{...r,children:[(0,t.jsx)("circle",{cx:"32",cy:"14",r:"4"}),(0,t.jsx)("circle",{cx:"14",cy:"44",r:"4"}),(0,t.jsx)("circle",{cx:"50",cy:"44",r:"4"}),(0,t.jsx)("line",{x1:"32",y1:"18",x2:"14",y2:"40",strokeDasharray:"3 3",opacity:"0.6"}),(0,t.jsx)("line",{x1:"32",y1:"18",x2:"50",y2:"40",strokeDasharray:"3 3",opacity:"0.6"}),(0,t.jsx)("line",{x1:"18",y1:"44",x2:"46",y2:"44",strokeDasharray:"3 3",opacity:"0.6"})]})});case"tasks":return(0,t.jsx)("svg",{viewBox:"0 0 64 64",...s,children:(0,t.jsxs)("g",{...r,children:[(0,t.jsx)("rect",{x:"14",y:"14",width:"36",height:"6",rx:"1.5"}),(0,t.jsx)("rect",{x:"14",y:"26",width:"36",height:"6",rx:"1.5",opacity:"0.6"}),(0,t.jsx)("rect",{x:"14",y:"38",width:"36",height:"6",rx:"1.5",opacity:"0.35"})]})});case"messages":return(0,t.jsx)("svg",{viewBox:"0 0 64 64",...s,children:(0,t.jsxs)("g",{...r,children:[(0,t.jsx)("path",{d:"M14 18 h36 a3 3 0 0 1 3 3 v18 a3 3 0 0 1 -3 3 h-18 l-8 6 v-6 h-10 a3 3 0 0 1 -3 -3 v-18 a3 3 0 0 1 3 -3 z"}),(0,t.jsx)("line",{x1:"22",y1:"28",x2:"42",y2:"28",opacity:"0.5"}),(0,t.jsx)("line",{x1:"22",y1:"34",x2:"36",y2:"34",opacity:"0.5"})]})});case"logs":return(0,t.jsx)("svg",{viewBox:"0 0 64 64",...s,children:(0,t.jsxs)("g",{...r,children:[(0,t.jsx)("path",{d:"M18 12 h22 l8 8 v32 a2 2 0 0 1 -2 2 h-28 a2 2 0 0 1 -2 -2 v-38 a2 2 0 0 1 2 -2 z"}),(0,t.jsx)("path",{d:"M40 12 v8 h8",opacity:"0.6"}),(0,t.jsx)("line",{x1:"24",y1:"32",x2:"40",y2:"32",opacity:"0.55"}),(0,t.jsx)("line",{x1:"24",y1:"38",x2:"40",y2:"38",opacity:"0.4"}),(0,t.jsx)("line",{x1:"24",y1:"44",x2:"34",y2:"44",opacity:"0.25"})]})});case"tokens":return(0,t.jsx)("svg",{viewBox:"0 0 64 64",...s,children:(0,t.jsxs)("g",{...r,children:[(0,t.jsx)("circle",{cx:"22",cy:"32",r:"8"}),(0,t.jsx)("line",{x1:"30",y1:"32",x2:"54",y2:"32"}),(0,t.jsx)("line",{x1:"44",y1:"32",x2:"44",y2:"38"}),(0,t.jsx)("line",{x1:"50",y1:"32",x2:"50",y2:"40"})]})});case"networks":return(0,t.jsx)("svg",{viewBox:"0 0 64 64",...s,children:(0,t.jsxs)("g",{...r,children:[(0,t.jsx)("circle",{cx:"32",cy:"32",r:"18"}),(0,t.jsx)("ellipse",{cx:"32",cy:"32",rx:"18",ry:"9",opacity:"0.55"}),(0,t.jsx)("line",{x1:"14",y1:"32",x2:"50",y2:"32",opacity:"0.55"}),(0,t.jsx)("line",{x1:"32",y1:"14",x2:"32",y2:"50",opacity:"0.55"})]})});default:return(0,t.jsx)("svg",{viewBox:"0 0 64 64",...s,children:(0,t.jsxs)("g",{...r,children:[(0,t.jsx)("circle",{cx:"32",cy:"32",r:"14",strokeDasharray:"3 3",opacity:"0.6"}),(0,t.jsx)("circle",{cx:"32",cy:"32",r:"3"})]})})}}function i({variant:e="generic",title:a,sub:l,cta:d,compact:o=!1}){let c=r[e],x=a??c.title,h=l??c.sub;return(0,t.jsxs)("div",{className:`text-center ${o?"py-8":"py-16"} px-4`,role:"status",children:[(0,t.jsx)("div",{className:"anet-empty-glyph inline-flex items-center justify-center mb-4 text-gray-500","aria-hidden":!0,children:(0,t.jsx)(n,{variant:e,size:o?40:56})}),(0,t.jsx)("h3",{className:`font-medium text-gray-300 ${o?"text-sm":"text-base"}`,children:x}),h&&(0,t.jsx)("p",{className:`text-gray-500 ${o?"text-xs mt-1.5":"text-sm mt-2"} max-w-md mx-auto leading-relaxed`,children:h}),d&&(0,t.jsx)("div",{className:"mt-4",children:d.href?(0,t.jsxs)(s.default,{href:d.href,className:"inline-flex items-center gap-1.5 text-sm font-medium text-cyan-400 hover:text-cyan-300",children:[d.label,(0,t.jsx)("span",{"aria-hidden":!0,children:"→"})]}):(0,t.jsxs)("button",{onClick:d.onClick,className:"inline-flex items-center gap-1.5 text-sm font-medium text-cyan-400 hover:text-cyan-300",children:[d.label,(0,t.jsx)("span",{"aria-hidden":!0,children:"→"})]})})]})}function l({cmd:e}){let[s,r]=(0,a.useState)(!1),n=async()=>{try{await navigator.clipboard.writeText(e),r(!0),setTimeout(()=>r(!1),1800)}catch{}};return(0,t.jsxs)("div",{className:"anet-empty-cmd flex items-center gap-2 bg-[#0a0a15] border border-[#2a2a4a] rounded-lg pl-4 pr-1.5 py-1.5 text-xs sm:text-sm",children:[(0,t.jsx)("code",{className:"text-cyan-300 font-mono select-all",children:e}),(0,t.jsx)("button",{type:"button",onClick:n,"aria-label":s?"Copied":"Copy command",className:"shrink-0 rounded-md px-2 py-1.5 text-[11px] text-gray-500 hover:text-gray-200 hover:bg-[#1a1a2a] transition-colors",children:s?(0,t.jsxs)("span",{className:"flex items-center gap-1 text-green-400",children:[(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,t.jsx)("path",{d:"M20 6 9 17l-5-5"})}),"Copied"]}):(0,t.jsxs)("span",{className:"flex items-center gap-1",children:[(0,t.jsxs)("svg",{width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,t.jsx)("rect",{x:"9",y:"9",width:"13",height:"13",rx:"2",ry:"2"}),(0,t.jsx)("path",{d:"M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"})]}),"Copy"]})})]})}e.s(["EmptyState",0,i,"NodesEmptyState",0,function({hint:e}){return e?.global_count?(0,t.jsx)(i,{variant:"nodes",title:"No agents in this network",sub:`Server has ${e.global_count} nodes globally, but none are registered to the current network. Switch network or contact admin.`}):(0,t.jsxs)("div",{className:"text-center py-16 px-4",role:"status",children:[(0,t.jsx)("div",{className:"anet-empty-glyph inline-flex items-center justify-center mb-4 text-gray-500","aria-hidden":!0,children:(0,t.jsx)("svg",{viewBox:"0 0 64 64",width:56,height:56,children:(0,t.jsxs)("g",{stroke:"currentColor",strokeWidth:"1.5",fill:"none",children:[(0,t.jsx)("rect",{x:"10",y:"20",width:"44",height:"28",rx:"2"}),(0,t.jsx)("rect",{x:"20",y:"32",width:"6",height:"8",opacity:"0.5"}),(0,t.jsx)("rect",{x:"32",y:"32",width:"6",height:"8",opacity:"0.5"}),(0,t.jsx)("rect",{x:"44",y:"32",width:"4",height:"8",opacity:"0.5"}),(0,t.jsx)("line",{x1:"10",y1:"26",x2:"54",y2:"26",opacity:"0.4"}),(0,t.jsx)("circle",{cx:"14",cy:"23",r:"0.8",fill:"currentColor"})]})})}),(0,t.jsx)("h3",{className:"font-medium text-gray-300 text-base",children:"Spin up your first agent"}),(0,t.jsx)("p",{className:"text-gray-500 text-sm mt-2 max-w-md mx-auto leading-relaxed",children:"Run this in a fresh terminal to register an agent with this CommHub:"}),(0,t.jsx)("div",{className:"mt-4 inline-block",children:(0,t.jsx)(l,{cmd:"npx --yes @sleep2agi/agent-network init"})}),(0,t.jsx)("div",{className:"mt-3",children:(0,t.jsxs)("a",{href:"https://anet.sh",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 text-xs font-medium text-gray-500 hover:text-cyan-300",children:["Full quickstart guide",(0,t.jsx)("span",{"aria-hidden":!0,children:"→"})]})})]})}])},96527,e=>{"use strict";var t=e.i(18050),a=e.i(71645),s=e.i(18566),r=e.i(58963),n=e.i(18150),i=e.i(69874);let l={created:"text-gray-400",delivered:"text-blue-400",running:"text-green-400",replied:"text-purple-400",failed:"text-red-400",closed:"text-gray-500"};function d({taskId:e,onClose:s}){let[r,o]=(0,a.useState)(null),[c,x]=(0,a.useState)([]),[h,m]=(0,a.useState)(!0);(0,a.useEffect)(()=>{(async()=>{try{let[t,a]=await Promise.all([fetch(`/api/hub/tasks?task_id=${encodeURIComponent(e)}`),fetch(`/api/hub/task-events?task_id=${encodeURIComponent(e)}&limit=50`)]),s=await t.json(),r=await a.json();s.tasks?.[0]&&o(s.tasks[0]),x(r.events||[])}catch{}finally{m(!1)}})()},[e]);let p=r?[{key:"created",label:"Created",time:r.created_at,color:"bg-gray-400"},{key:"delivered",label:"Delivered",time:r.delivered_at,color:"bg-blue-400"},{key:"started",label:"Started",time:r.started_at,color:"bg-green-400"},{key:"completed",label:"Completed",time:r.completed_at,color:"bg-purple-400"}].map(e=>({...e,done:!!e.time})):[],g=p.findIndex(e=>!e.done),u=r&&"completed"!==r.status&&"failed"!==r.status&&"expired"!==r.status&&"cancelled"!==r.status,y=r?.started_at&&r?.completed_at?Math.round((new Date(r.completed_at).getTime()-new Date(r.started_at).getTime())/1e3):null;return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"fixed inset-0 bg-black/30 z-40 anet-fade-in",onClick:s}),(0,t.jsxs)("div",{className:"fixed top-0 right-0 h-full w-full lg:w-[500px] bg-[#0a0a1a] border-l border-[#2a2a4a] z-50 flex flex-col shadow-2xl shadow-black/60 overflow-y-auto animate-slide-in",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between px-5 py-4 border-b border-[#2a2a4a] bg-[#0d0d1a] sticky top-0",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("div",{className:"text-sm font-semibold text-white",children:"Task Detail"}),(0,t.jsxs)("div",{className:"text-[10px] text-gray-500 mt-0.5",children:[e.slice(0,16),"..."]})]}),(0,t.jsx)("button",{onClick:s,className:"text-gray-500 hover:text-white p-1.5 rounded-lg hover:bg-[#1a1a2a]",children:(0,t.jsx)("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:(0,t.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 18L18 6M6 6l12 12"})})})]}),h?(0,t.jsx)("div",{className:"flex justify-center py-16",children:(0,t.jsx)("div",{className:"w-6 h-6 border-2 border-cyan-500/30 border-t-cyan-500 rounded-full animate-spin"})}):r?(0,t.jsxs)("div",{className:"px-5 py-5 space-y-5",children:[(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)("span",{className:`text-lg font-bold ${l[r.status]||"text-gray-400"}`,children:r.status}),"normal"!==r.priority&&(0,t.jsx)("span",{className:`text-xs px-2 py-0.5 rounded border ${"high"===r.priority?"text-red-300 border-red-500/20":"text-gray-400 border-gray-600/20"}`,children:r.priority}),null!==y&&(0,t.jsxs)("span",{className:"text-xs text-gray-500",children:["⏱ ",y<60?`${y}s`:`${Math.floor(y/60)}m ${y%60}s`]})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 text-sm flex-wrap",children:[r.from_name&&(0,t.jsx)(i.AliasAvatar,{alias:r.from_name,size:18}),(0,t.jsx)("span",{className:"text-gray-200 font-medium",children:r.from_name||"--"}),(0,t.jsx)("span",{className:"text-gray-600",children:"→"}),r.to_name&&(0,t.jsx)(i.AliasAvatar,{alias:r.to_name,size:18}),(0,t.jsx)("span",{className:"text-gray-200 font-medium",children:r.to_name||"--"})]}),(0,t.jsxs)("div",{className:"bg-[#111128] border border-[#2a2a4a] rounded-xl p-4",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between mb-3",children:[(0,t.jsx)("div",{className:"text-xs text-gray-500 uppercase tracking-wide",children:"Timeline"}),null!==y&&(0,t.jsxs)("div",{className:"text-[10px] text-gray-600",children:[y<60?`${y}s`:`${Math.floor(y/60)}m ${y%60}s`," runtime"]})]}),(0,t.jsx)("div",{className:"space-y-3",children:p.map((e,a)=>{let s=u&&a===g,r=!!p[a+1]?.done;return(0,t.jsxs)("div",{className:"flex items-start gap-3",children:[(0,t.jsxs)("div",{className:"flex flex-col items-center pt-0.5",children:[(0,t.jsx)("span",{className:`relative w-3 h-3 rounded-full shrink-0 ${e.done?e.color:"bg-gray-700"}`,children:s&&(0,t.jsx)("span",{"aria-hidden":!0,className:"absolute -inset-1 rounded-full border border-current opacity-60 anet-current-step-pulse",style:{borderColor:"currentColor"}})}),a<p.length-1&&(0,t.jsx)("div",{className:`w-0.5 h-5 mt-1 ${e.done&&r?"bg-gray-500":e.done?"bg-gradient-to-b from-gray-500 to-gray-800":"bg-gray-800"}`})]}),(0,t.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,t.jsxs)("div",{className:`text-xs font-medium flex items-center gap-2 ${e.done?"text-gray-200":s?"text-cyan-300":"text-gray-600"}`,children:[(0,t.jsx)("span",{children:e.label}),s&&(0,t.jsx)("span",{className:"text-[9px] uppercase tracking-wide text-cyan-400",children:"in progress"})]}),(0,t.jsx)("div",{className:"text-[10px] text-gray-500",title:e.time||void 0,children:e.time?(0,n.timeAgo)(e.time):s?"—":"Pending"})]})]},e.key)})})]}),(0,t.jsxs)("div",{className:"bg-[#111128] border border-[#2a2a4a] rounded-xl p-4",children:[(0,t.jsx)("div",{className:"text-xs text-gray-500 uppercase mb-2",children:"Input"}),(0,t.jsx)("div",{className:"text-sm text-gray-300 whitespace-pre-wrap",children:r.content||"--"})]}),r.result&&(0,t.jsxs)("div",{className:"bg-[#111128] border border-[#2a2a4a] rounded-xl p-4",children:[(0,t.jsx)("div",{className:"text-xs text-gray-500 uppercase mb-2",children:"Output"}),(0,t.jsx)("div",{className:"text-sm text-gray-300 whitespace-pre-wrap max-h-64 overflow-y-auto",children:r.result})]}),c.length>0&&(0,t.jsxs)("div",{className:"bg-[#111128] border border-[#2a2a4a] rounded-xl p-4",children:[(0,t.jsxs)("div",{className:"text-xs text-gray-500 uppercase mb-2",children:["Events (",c.length,")"]}),(0,t.jsx)("div",{className:"space-y-1.5 max-h-40 overflow-y-auto",children:c.map(e=>(0,t.jsxs)("div",{className:"flex items-center gap-2 text-[11px]",children:[(0,t.jsx)("span",{className:`w-1.5 h-1.5 rounded-full shrink-0 ${"running"===e.to_status?"bg-green-400":"replied"===e.to_status?"bg-purple-400":"failed"===e.to_status?"bg-red-400":"bg-blue-400"}`}),(0,t.jsx)("span",{className:"text-gray-400",children:e.event_type}),e.from_status&&(0,t.jsxs)("span",{className:"text-gray-600",children:[e.from_status,"→",e.to_status]}),(0,t.jsx)("span",{className:"text-gray-600 ml-auto",children:(0,n.timeAgo)(e.created_at)})]},e.id))})]}),(0,t.jsxs)("div",{className:"text-[10px] text-gray-600 space-y-1",children:[(0,t.jsxs)("div",{children:["Task ID: ",r.task_id]}),r.expires_at&&(0,t.jsxs)("div",{children:["Expires: ",r.expires_at]})]})]}):(0,t.jsx)("div",{className:"text-center py-16 text-gray-500",children:"Task not found"})]})]})}var o=e.i(95356);let c=["","created","delivered","acked","running","replied","closed","failed","cancelled","expired"],x={created:"bg-gray-500/10 text-gray-400 border-gray-500/20",delivered:"bg-blue-500/10 text-blue-300 border-blue-500/20",acked:"bg-cyan-500/10 text-cyan-300 border-cyan-500/20",running:"bg-green-500/10 text-green-300 border-green-500/20",replied:"bg-purple-500/10 text-purple-300 border-purple-500/20",closed:"bg-gray-500/10 text-gray-500 border-gray-500/20",failed:"bg-red-500/10 text-red-300 border-red-500/20",cancelled:"bg-yellow-500/10 text-yellow-300 border-yellow-500/20",expired:"bg-orange-500/10 text-orange-300 border-orange-500/20"},h={created:"#9ca3af",delivered:"#60a5fa",acked:"#22d3ee",running:"#4ade80",replied:"#a78bfa",closed:"#6b7280",failed:"#f87171",cancelled:"#facc15",expired:"#fb923c"};function m(e){let t=x[e]||"bg-gray-500/10 text-gray-400 border-gray-500/20";return`text-xs px-2 py-0.5 rounded-md border ${t}`}function p(e){return"high"===e?"text-red-400":"low"===e?"text-gray-600":"text-gray-400"}function g(e){if(!e)return"--";let t=Math.floor((Date.now()-new Date(e.replace(" ","T")+"Z").getTime())/1e3);return t<60?`${t}s ago`:t<3600?`${Math.floor(t/60)}m ago`:t<86400?`${Math.floor(t/3600)}h ago`:`${Math.floor(t/86400)}d ago`}function u(){let e,n,l,u,y=(0,s.useSearchParams)(),{networkId:j}=(0,r.useNetworkId)(),[b,v]=(0,a.useState)([]),[f,N]=(0,a.useState)(0),[w,k]=(0,a.useState)(!0),[_,C]=(0,a.useState)(""),[$,S]=(0,a.useState)(new Set),[M,T]=(0,a.useState)(y.get("status")||""),[A,D]=(0,a.useState)(""),[L,B]=(0,a.useState)(""),[E,I]=(0,a.useState)(null),z=e=>{S(t=>{let a=new Set(t);return a.has(e)?a.delete(e):a.add(e),a})},P=(0,a.useCallback)(async()=>{try{let e=new URLSearchParams;j&&e.set("network_id",j),M&&e.set("status",M),A&&e.set("from_name",A),L&&e.set("to_name",L),e.set("limit","100");let t=await fetch(`/api/hub/tasks?${e.toString()}`);if(401===t.status)return void window.location.assign("/login");let a=await t.json();v(a.tasks||[]),N(a.count??(a.tasks?.length||0)),C("")}catch(e){C(e instanceof Error?e.message:"fetch failed")}finally{k(!1)}},[M,A,L,j]);return(0,a.useEffect)(()=>{k(!0),P();let e=setInterval(P,5e3);return()=>clearInterval(e)},[P]),(0,t.jsxs)("div",{className:"min-h-screen bg-[#0a0a1a] text-gray-100 p-4 sm:p-6 font-mono",children:[(0,t.jsxs)("div",{className:"flex items-center gap-4 mb-6",children:[(0,t.jsx)("h1",{className:"text-2xl font-bold text-white lg:ml-0 ml-10",children:"Tasks"}),(0,t.jsx)("span",{className:"text-xs bg-blue-900/30 text-blue-400 px-2 py-0.5 rounded-full border border-blue-800/30",children:f})]}),(0,t.jsx)("div",{className:"anet-tabstrip-wrap mb-4",children:(0,t.jsx)("div",{className:"anet-tabstrip flex sm:flex-wrap gap-1 bg-[#111128] rounded-lg border border-[#2a2a4a] p-1 overflow-x-auto sm:overflow-x-visible scrollbar-thin",children:(e={},b.forEach(t=>{e[t.status]=(e[t.status]||0)+1}),["",...c.filter(Boolean)].map(a=>{let s=""===a?b.length:e[a]||0,r=M===a;return(0,t.jsxs)("button",{onClick:()=>T(a),disabled:0===s&&""!==a&&!r,className:`px-3 py-1.5 rounded-md text-xs transition-colors flex items-center gap-1.5 shrink-0 whitespace-nowrap disabled:opacity-30 disabled:cursor-not-allowed ${r?`${x[a]||"bg-cyan-500/10 text-cyan-300 border-cyan-500/20"} border`:"text-gray-500 hover:text-gray-300 hover:bg-[#1a1a2a]/40"}`,children:[a&&(0,t.jsx)("span",{"aria-hidden":!0,className:"inline-block w-1.5 h-1.5 rounded-full shrink-0",style:{backgroundColor:h[a]||"#6b7280"}}),(0,t.jsx)("span",{children:a||"All"}),(0,t.jsx)("span",{className:`text-[10px] tabular-nums ${r?"opacity-80":"text-gray-600"}`,children:s})]},a)}))})}),(0,t.jsxs)("div",{className:"flex flex-wrap items-center gap-2 mb-6",children:[(0,t.jsxs)("div",{className:"flex items-center gap-1.5 rounded-lg border border-[#2a2a4a] bg-[#111128] px-2.5 py-1.5 focus-within:border-blue-500/40",children:[(0,t.jsx)("span",{className:"text-[10px] uppercase tracking-wide text-gray-600",children:"From"}),(0,t.jsx)("input",{type:"text",value:A,onChange:e=>D(e.target.value),placeholder:"any node",className:"w-28 bg-transparent text-sm text-white placeholder-gray-700 focus:outline-none"})]}),(0,t.jsxs)("div",{className:"flex items-center gap-1.5 rounded-lg border border-[#2a2a4a] bg-[#111128] px-2.5 py-1.5 focus-within:border-blue-500/40",children:[(0,t.jsx)("span",{className:"text-[10px] uppercase tracking-wide text-gray-600",children:"To"}),(0,t.jsx)("input",{type:"text",value:L,onChange:e=>B(e.target.value),placeholder:"any node",className:"w-28 bg-transparent text-sm text-white placeholder-gray-700 focus:outline-none"})]}),(M||A||L)&&(0,t.jsx)("button",{type:"button",onClick:()=>{T(""),D(""),B("")},className:"rounded-lg border border-gray-700 px-2.5 py-1.5 text-[11px] text-gray-500 hover:text-gray-200 hover:border-gray-600",children:"Clear filters"})]}),b.length>0&&!M&&(n={},b.forEach(e=>{n[e.status]=(n[e.status]||0)+1}),l=b.length||1,(u=[{key:"created",color:"bg-gray-500"},{key:"delivered",color:"bg-blue-500"},{key:"acked",color:"bg-cyan-500"},{key:"running",color:"bg-green-500"},{key:"replied",color:"bg-purple-500"},{key:"failed",color:"bg-red-500"},{key:"cancelled",color:"bg-yellow-500"},{key:"expired",color:"bg-orange-500"}].filter(e=>n[e.key])).length?(0,t.jsx)("div",{className:"mb-6",children:(0,t.jsx)("div",{className:"flex h-2 rounded-full overflow-hidden bg-gray-800",children:u.map(e=>(0,t.jsx)("div",{className:e.color,style:{width:`${n[e.key]/l*100}%`},title:`${e.key}: ${n[e.key]}`},e.key))})}):null),_&&(0,t.jsx)("div",{className:"bg-red-900/20 border border-red-800/40 text-red-300 px-4 py-2 rounded-lg mb-6 text-sm",children:_}),w?(0,t.jsx)("div",{className:"animate-pulse space-y-3",children:[1,2,3,4,5].map(e=>(0,t.jsx)("div",{className:"h-20 bg-gray-800/20 rounded-lg border border-gray-800/40"},e))}):0===b.length?(0,t.jsx)(o.EmptyState,{variant:"tasks",sub:M||A||L?"No tasks match the current filters. Try clearing them.":"Tasks will appear here when agents send them via CommHub."}):(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsxs)("div",{className:"hidden sm:grid sm:grid-cols-12 gap-2 px-4 py-2 text-xs text-gray-600 uppercase",children:[(0,t.jsx)("div",{className:"col-span-1",children:"Status"}),(0,t.jsx)("div",{className:"col-span-2",children:"From"}),(0,t.jsx)("div",{className:"col-span-2",children:"To"}),(0,t.jsx)("div",{className:"col-span-4",children:"Content"}),(0,t.jsx)("div",{className:"col-span-1",children:"Priority"}),(0,t.jsx)("div",{className:"col-span-2",children:"Time"})]}),b.map(e=>{let a=$.has(e.task_id);return(0,t.jsxs)("div",{className:`anet-task-row group bg-[#111128] border rounded-lg px-4 py-3 transition-all duration-200 cursor-pointer ${a?"border-[#3a3a5a] shadow-lg shadow-black/20":"border-[#2a2a4a] hover:border-[#3a3a5a] hover:bg-[#15152e]"}`,onClick:()=>z(e.task_id),role:"button",tabIndex:0,"aria-expanded":a,onKeyDown:t=>{("Enter"===t.key||" "===t.key)&&(t.preventDefault(),z(e.task_id))},children:[(0,t.jsxs)("div",{className:"hidden sm:grid sm:grid-cols-12 gap-2 items-center",children:[(0,t.jsx)("div",{className:"col-span-1",children:(0,t.jsx)("span",{className:m(e.status),children:e.status})}),(0,t.jsxs)("div",{className:"col-span-2 flex items-center gap-1.5 min-w-0",title:e.from_name,children:[e.from_name&&(0,t.jsx)(i.AliasAvatar,{alias:e.from_name,size:18}),(0,t.jsx)("span",{className:"truncate text-sm text-gray-200",children:e.from_name||"--"})]}),(0,t.jsxs)("div",{className:"col-span-2 flex items-center gap-1.5 min-w-0",title:e.to_name,children:[e.to_name&&(0,t.jsx)(i.AliasAvatar,{alias:e.to_name,size:18}),(0,t.jsx)("span",{className:"truncate text-sm text-gray-200",children:e.to_name||"--"})]}),(0,t.jsx)("div",{className:"col-span-4 text-xs text-gray-400 truncate",title:e.content,children:e.content||"--"}),(0,t.jsx)("div",{className:"col-span-1",children:(0,t.jsx)("span",{className:`text-xs ${p(e.priority)}`,children:e.priority||"normal"})}),(0,t.jsxs)("div",{className:"col-span-2 text-xs text-gray-500 flex items-center justify-between gap-2",title:e.created_at,children:[(0,t.jsx)("span",{className:"truncate",children:g(e.created_at)}),(0,t.jsx)("svg",{"aria-hidden":!0,className:`shrink-0 text-gray-600 group-hover:text-gray-400 transition-transform duration-200 ${a?"rotate-180":""}`,width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",children:(0,t.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 9l6 6 6-6"})})]})]}),(0,t.jsxs)("div",{className:"sm:hidden space-y-2",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between",children:[(0,t.jsx)("span",{className:m(e.status),children:e.status}),(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)("span",{className:`text-xs ${p(e.priority)}`,children:e.priority||"normal"}),(0,t.jsx)("svg",{"aria-hidden":!0,className:`text-gray-600 transition-transform duration-200 ${a?"rotate-180":""}`,width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",children:(0,t.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 9l6 6 6-6"})})]})]}),(0,t.jsxs)("div",{className:"flex items-center gap-1.5 text-xs text-gray-300 min-w-0",children:[e.from_name&&(0,t.jsx)(i.AliasAvatar,{alias:e.from_name,size:16}),(0,t.jsx)("span",{className:"truncate max-w-[40%]",children:e.from_name||"--"}),(0,t.jsx)("span",{className:"text-gray-600",children:"→"}),e.to_name&&(0,t.jsx)(i.AliasAvatar,{alias:e.to_name,size:16}),(0,t.jsx)("span",{className:"truncate max-w-[40%]",children:e.to_name||"--"})]}),(0,t.jsx)("div",{className:"text-xs text-gray-400 line-clamp-1",children:e.content||"--"}),(0,t.jsx)("div",{className:"text-xs text-gray-600",children:g(e.created_at)})]}),(0,t.jsx)("div",{className:`grid transition-all duration-300 ease-out ${a?"grid-rows-[1fr] opacity-100 mt-3":"grid-rows-[0fr] opacity-0"}`,"aria-hidden":!a,children:(0,t.jsx)("div",{className:"overflow-hidden",children:(0,t.jsxs)("div",{className:"pt-3 border-t border-[#2a2a4a] space-y-3",children:[e.content&&(0,t.jsxs)("div",{children:[(0,t.jsx)("div",{className:"text-xs text-gray-600 mb-1",children:"Content"}),(0,t.jsx)("div",{className:"text-xs text-gray-300 whitespace-pre-wrap bg-[#0a0a15] rounded-lg px-3 py-2 border border-[#1a1a2a]",children:e.content})]}),e.result&&(0,t.jsxs)("div",{children:[(0,t.jsx)("div",{className:"text-xs text-gray-600 mb-1",children:"Result"}),(0,t.jsx)("div",{className:"text-xs text-gray-300 whitespace-pre-wrap bg-[#0a0a15] rounded-lg px-3 py-2 border border-[#1a1a2a] max-h-48 overflow-y-auto",children:e.result})]}),(0,t.jsx)("div",{className:"grid grid-cols-2 sm:grid-cols-4 gap-2 text-xs",children:[["Created",e.created_at],["Delivered",e.delivered_at],["Started",e.started_at],["Completed",e.completed_at]].map(([e,a])=>(0,t.jsxs)("div",{children:[(0,t.jsxs)("span",{className:"text-gray-600",children:[e,": "]}),(0,t.jsx)("span",{className:"text-gray-400",children:a?g(a):"--"})]},e))}),e.expires_at&&(0,t.jsxs)("div",{className:"text-xs",children:[(0,t.jsx)("span",{className:"text-gray-600",children:"Expires: "}),(0,t.jsx)("span",{className:"text-orange-400",children:e.expires_at})]}),(0,t.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,t.jsxs)("div",{className:"text-xs text-gray-600 truncate",title:e.task_id,children:["ID: ",e.task_id]}),(0,t.jsxs)("div",{className:"flex gap-2 shrink-0",children:[("failed"===e.status||"expired"===e.status)&&(0,t.jsx)("button",{onClick:async t=>{t.stopPropagation(),await fetch("/api/hub/send",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({alias:e.to_name,task:e.content,priority:e.priority})}),P()},className:"text-xs text-orange-400 hover:text-orange-300 px-2 py-0.5 rounded border border-orange-500/20 hover:bg-orange-500/10",children:"Retry"}),(0,t.jsx)("button",{onClick:t=>{t.stopPropagation(),I(e.task_id)},className:"text-xs text-cyan-400 hover:text-cyan-300",children:"Detail →"})]})]})]})})})]},e.task_id)})]}),E&&(0,t.jsx)(d,{taskId:E,onClose:()=>I(null)})]})}e.s(["default",0,function(){return(0,t.jsx)(a.Suspense,{fallback:(0,t.jsx)("div",{className:"min-h-screen bg-[#0a0a1a] text-gray-100 p-6 font-mono",children:"Loading tasks..."}),children:(0,t.jsx)(u,{})})}],96527)}]);
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,18150,e=>{"use strict";e.s(["formatUptime",0,function(e){let t=Math.floor(e/3600),a=Math.floor(e%3600/60);return t>0?`${t}h ${a}m`:`${a}m`},"timeAgo",0,function(e){if(!e)return"--";let t=Math.floor((Date.now()-new Date(e.replace(" ","T")+"Z").getTime())/1e3);return t<60?`${t}s ago`:t<3600?`${Math.floor(t/60)}m ago`:t<86400?`${Math.floor(t/3600)}h ago`:`${Math.floor(t/86400)}d ago`}])},69874,e=>{"use strict";var t=e.i(18050);let a=[180,200,220,270,300,330,30,90];e.s(["AliasAvatar",0,function({alias:e,size:s=28,className:r=""}){let n=function(e){let t=0;for(let a=0;a<e.length;a++)t=31*t+e.charCodeAt(a)>>>0;let s=a[t%a.length];return{bg:`hsl(${s} 55% 22%)`,ring:`hsl(${s} 60% 45%)`,text:`hsl(${s} 80% 78%)`}}(e),i=Math.max(9,Math.round(.42*s));return(0,t.jsx)("span",{className:`anet-alias-avatar inline-flex items-center justify-center rounded-full border shrink-0 font-semibold ${r}`,style:{width:s,height:s,fontSize:i,backgroundColor:n.bg,borderColor:n.ring,color:n.text},title:e,"aria-hidden":!0,children:e?(e.trim().match(/[\p{L}\p{N}]/u)?.[0]||e.trim()[0]||"·").toUpperCase():"·"})}])},95356,e=>{"use strict";var t=e.i(18050),a=e.i(71645),s=e.i(22016);let r={nodes:{title:"No agents in this network",sub:"Agent sessions will appear here once they connect to the CommHub."},tasks:{title:"No tasks yet",sub:"Tasks will appear here when agents send them via CommHub."},messages:{title:"No messages",sub:"Messages between agents will appear here."},logs:{title:"No audit logs",sub:"Events will appear here when users register, login, or perform actions."},tokens:{title:"No API tokens",sub:"Create one to authenticate CLI tools and external integrations."},networks:{title:"No networks found",sub:"Create one or sign in with V3 auth to see your networks."},generic:{title:"Nothing here yet",sub:"Data will appear here once available."}};function n({variant:e,size:a}){let s={width:a,height:a},r={fill:"none",stroke:"currentColor",strokeWidth:1.25,strokeLinecap:"round",strokeLinejoin:"round"};switch(e){case"nodes":return(0,t.jsx)("svg",{viewBox:"0 0 64 64",...s,children:(0,t.jsxs)("g",{...r,children:[(0,t.jsx)("circle",{cx:"32",cy:"14",r:"4"}),(0,t.jsx)("circle",{cx:"14",cy:"44",r:"4"}),(0,t.jsx)("circle",{cx:"50",cy:"44",r:"4"}),(0,t.jsx)("line",{x1:"32",y1:"18",x2:"14",y2:"40",strokeDasharray:"3 3",opacity:"0.6"}),(0,t.jsx)("line",{x1:"32",y1:"18",x2:"50",y2:"40",strokeDasharray:"3 3",opacity:"0.6"}),(0,t.jsx)("line",{x1:"18",y1:"44",x2:"46",y2:"44",strokeDasharray:"3 3",opacity:"0.6"})]})});case"tasks":return(0,t.jsx)("svg",{viewBox:"0 0 64 64",...s,children:(0,t.jsxs)("g",{...r,children:[(0,t.jsx)("rect",{x:"14",y:"14",width:"36",height:"6",rx:"1.5"}),(0,t.jsx)("rect",{x:"14",y:"26",width:"36",height:"6",rx:"1.5",opacity:"0.6"}),(0,t.jsx)("rect",{x:"14",y:"38",width:"36",height:"6",rx:"1.5",opacity:"0.35"})]})});case"messages":return(0,t.jsx)("svg",{viewBox:"0 0 64 64",...s,children:(0,t.jsxs)("g",{...r,children:[(0,t.jsx)("path",{d:"M14 18 h36 a3 3 0 0 1 3 3 v18 a3 3 0 0 1 -3 3 h-18 l-8 6 v-6 h-10 a3 3 0 0 1 -3 -3 v-18 a3 3 0 0 1 3 -3 z"}),(0,t.jsx)("line",{x1:"22",y1:"28",x2:"42",y2:"28",opacity:"0.5"}),(0,t.jsx)("line",{x1:"22",y1:"34",x2:"36",y2:"34",opacity:"0.5"})]})});case"logs":return(0,t.jsx)("svg",{viewBox:"0 0 64 64",...s,children:(0,t.jsxs)("g",{...r,children:[(0,t.jsx)("path",{d:"M18 12 h22 l8 8 v32 a2 2 0 0 1 -2 2 h-28 a2 2 0 0 1 -2 -2 v-38 a2 2 0 0 1 2 -2 z"}),(0,t.jsx)("path",{d:"M40 12 v8 h8",opacity:"0.6"}),(0,t.jsx)("line",{x1:"24",y1:"32",x2:"40",y2:"32",opacity:"0.55"}),(0,t.jsx)("line",{x1:"24",y1:"38",x2:"40",y2:"38",opacity:"0.4"}),(0,t.jsx)("line",{x1:"24",y1:"44",x2:"34",y2:"44",opacity:"0.25"})]})});case"tokens":return(0,t.jsx)("svg",{viewBox:"0 0 64 64",...s,children:(0,t.jsxs)("g",{...r,children:[(0,t.jsx)("circle",{cx:"22",cy:"32",r:"8"}),(0,t.jsx)("line",{x1:"30",y1:"32",x2:"54",y2:"32"}),(0,t.jsx)("line",{x1:"44",y1:"32",x2:"44",y2:"38"}),(0,t.jsx)("line",{x1:"50",y1:"32",x2:"50",y2:"40"})]})});case"networks":return(0,t.jsx)("svg",{viewBox:"0 0 64 64",...s,children:(0,t.jsxs)("g",{...r,children:[(0,t.jsx)("circle",{cx:"32",cy:"32",r:"18"}),(0,t.jsx)("ellipse",{cx:"32",cy:"32",rx:"18",ry:"9",opacity:"0.55"}),(0,t.jsx)("line",{x1:"14",y1:"32",x2:"50",y2:"32",opacity:"0.55"}),(0,t.jsx)("line",{x1:"32",y1:"14",x2:"32",y2:"50",opacity:"0.55"})]})});default:return(0,t.jsx)("svg",{viewBox:"0 0 64 64",...s,children:(0,t.jsxs)("g",{...r,children:[(0,t.jsx)("circle",{cx:"32",cy:"32",r:"14",strokeDasharray:"3 3",opacity:"0.6"}),(0,t.jsx)("circle",{cx:"32",cy:"32",r:"3"})]})})}}function i({variant:e="generic",title:a,sub:l,cta:d,compact:o=!1}){let c=r[e],x=a??c.title,h=l??c.sub;return(0,t.jsxs)("div",{className:`text-center ${o?"py-8":"py-16"} px-4`,role:"status",children:[(0,t.jsx)("div",{className:"anet-empty-glyph inline-flex items-center justify-center mb-4 text-gray-500","aria-hidden":!0,children:(0,t.jsx)(n,{variant:e,size:o?40:56})}),(0,t.jsx)("h3",{className:`font-medium text-gray-300 ${o?"text-sm":"text-base"}`,children:x}),h&&(0,t.jsx)("p",{className:`text-gray-500 ${o?"text-xs mt-1.5":"text-sm mt-2"} max-w-md mx-auto leading-relaxed`,children:h}),d&&(0,t.jsx)("div",{className:"mt-4",children:d.href?(0,t.jsxs)(s.default,{href:d.href,className:"inline-flex items-center gap-1.5 text-sm font-medium text-cyan-400 hover:text-cyan-300",children:[d.label,(0,t.jsx)("span",{"aria-hidden":!0,children:"→"})]}):(0,t.jsxs)("button",{onClick:d.onClick,className:"inline-flex items-center gap-1.5 text-sm font-medium text-cyan-400 hover:text-cyan-300",children:[d.label,(0,t.jsx)("span",{"aria-hidden":!0,children:"→"})]})})]})}function l({cmd:e}){let[s,r]=(0,a.useState)(!1),n=async()=>{try{await navigator.clipboard.writeText(e),r(!0),setTimeout(()=>r(!1),1800)}catch{}};return(0,t.jsxs)("div",{className:"anet-empty-cmd flex items-center gap-2 bg-[#0a0a15] border border-[#2a2a4a] rounded-lg pl-4 pr-1.5 py-1.5 text-xs sm:text-sm",children:[(0,t.jsx)("code",{className:"text-cyan-300 font-mono select-all",children:e}),(0,t.jsx)("button",{type:"button",onClick:n,"aria-label":s?"Copied":"Copy command",className:"shrink-0 rounded-md px-2 py-1.5 text-[11px] text-gray-500 hover:text-gray-200 hover:bg-[#1a1a2a] transition-colors",children:s?(0,t.jsxs)("span",{className:"flex items-center gap-1 text-green-400",children:[(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,t.jsx)("path",{d:"M20 6 9 17l-5-5"})}),"Copied"]}):(0,t.jsxs)("span",{className:"flex items-center gap-1",children:[(0,t.jsxs)("svg",{width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,t.jsx)("rect",{x:"9",y:"9",width:"13",height:"13",rx:"2",ry:"2"}),(0,t.jsx)("path",{d:"M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"})]}),"Copy"]})})]})}e.s(["EmptyState",0,i,"NodesEmptyState",0,function({hint:e}){return e?.global_count?(0,t.jsx)(i,{variant:"nodes",title:"No agents in this network",sub:`Server has ${e.global_count} nodes globally, but none are registered to the current network. Switch network or contact admin.`}):(0,t.jsxs)("div",{className:"text-center py-16 px-4",role:"status",children:[(0,t.jsx)("div",{className:"anet-empty-glyph inline-flex items-center justify-center mb-4 text-gray-500","aria-hidden":!0,children:(0,t.jsx)("svg",{viewBox:"0 0 64 64",width:56,height:56,children:(0,t.jsxs)("g",{stroke:"currentColor",strokeWidth:"1.5",fill:"none",children:[(0,t.jsx)("rect",{x:"10",y:"20",width:"44",height:"28",rx:"2"}),(0,t.jsx)("rect",{x:"20",y:"32",width:"6",height:"8",opacity:"0.5"}),(0,t.jsx)("rect",{x:"32",y:"32",width:"6",height:"8",opacity:"0.5"}),(0,t.jsx)("rect",{x:"44",y:"32",width:"4",height:"8",opacity:"0.5"}),(0,t.jsx)("line",{x1:"10",y1:"26",x2:"54",y2:"26",opacity:"0.4"}),(0,t.jsx)("circle",{cx:"14",cy:"23",r:"0.8",fill:"currentColor"})]})})}),(0,t.jsx)("h3",{className:"font-medium text-gray-300 text-base",children:"Spin up your first agent"}),(0,t.jsx)("p",{className:"text-gray-500 text-sm mt-2 max-w-md mx-auto leading-relaxed",children:"Run this in a fresh terminal to register an agent with this CommHub:"}),(0,t.jsx)("div",{className:"mt-4 inline-block",children:(0,t.jsx)(l,{cmd:"npx --yes @sleep2agi/agent-network init"})}),(0,t.jsx)("div",{className:"mt-3",children:(0,t.jsxs)("a",{href:"https://anet.sh",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 text-xs font-medium text-gray-500 hover:text-cyan-300",children:["Full quickstart guide",(0,t.jsx)("span",{"aria-hidden":!0,children:"→"})]})})]})}])},96527,e=>{"use strict";var t=e.i(18050),a=e.i(71645),s=e.i(18566),r=e.i(58963),n=e.i(18150),i=e.i(69874);let l={created:"text-gray-400",delivered:"text-blue-400",running:"text-green-400",replied:"text-purple-400",failed:"text-red-400",closed:"text-gray-500"};function d({taskId:e,onClose:s}){let[r,o]=(0,a.useState)(null),[c,x]=(0,a.useState)([]),[h,m]=(0,a.useState)(!0);(0,a.useEffect)(()=>{(async()=>{try{let[t,a]=await Promise.all([fetch(`/api/hub/tasks?task_id=${encodeURIComponent(e)}`),fetch(`/api/hub/task-events?task_id=${encodeURIComponent(e)}&limit=50`)]),s=await t.json(),r=await a.json();s.tasks?.[0]&&o(s.tasks[0]),x(r.events||[])}catch{}finally{m(!1)}})()},[e]);let p=r?[{key:"created",label:"Created",time:r.created_at,color:"bg-gray-400"},{key:"delivered",label:"Delivered",time:r.delivered_at,color:"bg-blue-400"},{key:"started",label:"Started",time:r.started_at,color:"bg-green-400"},{key:"completed",label:"Completed",time:r.completed_at,color:"bg-purple-400"}].map(e=>({...e,done:!!e.time})):[],g=p.findIndex(e=>!e.done),u=r&&"completed"!==r.status&&"failed"!==r.status&&"expired"!==r.status&&"cancelled"!==r.status,y=r?.started_at&&r?.completed_at?Math.round((new Date(r.completed_at).getTime()-new Date(r.started_at).getTime())/1e3):null;return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"fixed inset-0 bg-black/30 z-40 anet-fade-in",onClick:s}),(0,t.jsxs)("div",{className:"fixed top-0 right-0 h-full w-full lg:w-[500px] bg-[#0a0a1a] border-l border-[#2a2a4a] z-50 flex flex-col shadow-2xl shadow-black/60 overflow-y-auto animate-slide-in",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between px-5 py-4 border-b border-[#2a2a4a] bg-[#0d0d1a] sticky top-0",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("div",{className:"text-sm font-semibold text-white",children:"Task Detail"}),(0,t.jsxs)("div",{className:"text-[10px] text-gray-500 mt-0.5",children:[e.slice(0,16),"..."]})]}),(0,t.jsx)("button",{onClick:s,className:"text-gray-500 hover:text-white p-1.5 rounded-lg hover:bg-[#1a1a2a]",children:(0,t.jsx)("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:(0,t.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 18L18 6M6 6l12 12"})})})]}),h?(0,t.jsx)("div",{className:"flex justify-center py-16",children:(0,t.jsx)("div",{className:"w-6 h-6 border-2 border-cyan-500/30 border-t-cyan-500 rounded-full animate-spin"})}):r?(0,t.jsxs)("div",{className:"px-5 py-5 space-y-5",children:[(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)("span",{className:`text-lg font-bold ${l[r.status]||"text-gray-400"}`,children:r.status}),"normal"!==r.priority&&(0,t.jsx)("span",{className:`text-xs px-2 py-0.5 rounded border ${"high"===r.priority?"text-red-300 border-red-500/20":"text-gray-400 border-gray-600/20"}`,children:r.priority}),null!==y&&(0,t.jsxs)("span",{className:"text-xs text-gray-500",children:["⏱ ",y<60?`${y}s`:`${Math.floor(y/60)}m ${y%60}s`]})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 text-sm flex-wrap",children:[r.from_name&&(0,t.jsx)(i.AliasAvatar,{alias:r.from_name,size:18}),(0,t.jsx)("span",{className:"text-gray-200 font-medium",children:r.from_name||"--"}),(0,t.jsx)("span",{className:"text-gray-600",children:"→"}),r.to_name&&(0,t.jsx)(i.AliasAvatar,{alias:r.to_name,size:18}),(0,t.jsx)("span",{className:"text-gray-200 font-medium",children:r.to_name||"--"})]}),(0,t.jsxs)("div",{className:"bg-[#111128] border border-[#2a2a4a] rounded-xl p-4",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between mb-3",children:[(0,t.jsx)("div",{className:"text-xs text-gray-500 uppercase tracking-wide",children:"Timeline"}),null!==y&&(0,t.jsxs)("div",{className:"text-[10px] text-gray-600",children:[y<60?`${y}s`:`${Math.floor(y/60)}m ${y%60}s`," runtime"]})]}),(0,t.jsx)("div",{className:"space-y-3",children:p.map((e,a)=>{let s=u&&a===g,r=!!p[a+1]?.done;return(0,t.jsxs)("div",{className:"flex items-start gap-3",children:[(0,t.jsxs)("div",{className:"flex flex-col items-center pt-0.5",children:[(0,t.jsx)("span",{className:`relative w-3 h-3 rounded-full shrink-0 ${e.done?e.color:"bg-gray-700"}`,children:s&&(0,t.jsx)("span",{"aria-hidden":!0,className:"absolute -inset-1 rounded-full border border-current opacity-60 anet-current-step-pulse",style:{borderColor:"currentColor"}})}),a<p.length-1&&(0,t.jsx)("div",{className:`w-0.5 h-5 mt-1 ${e.done&&r?"bg-gray-500":e.done?"bg-gradient-to-b from-gray-500 to-gray-800":"bg-gray-800"}`})]}),(0,t.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,t.jsxs)("div",{className:`text-xs font-medium flex items-center gap-2 ${e.done?"text-gray-200":s?"text-cyan-300":"text-gray-600"}`,children:[(0,t.jsx)("span",{children:e.label}),s&&(0,t.jsx)("span",{className:"text-[9px] uppercase tracking-wide text-cyan-400",children:"in progress"})]}),(0,t.jsx)("div",{className:"text-[10px] text-gray-500",title:e.time||void 0,children:e.time?(0,n.timeAgo)(e.time):s?"—":"Pending"})]})]},e.key)})})]}),(0,t.jsxs)("div",{className:"bg-[#111128] border border-[#2a2a4a] rounded-xl p-4",children:[(0,t.jsx)("div",{className:"text-xs text-gray-500 uppercase mb-2",children:"Input"}),(0,t.jsx)("div",{className:"text-sm text-gray-300 whitespace-pre-wrap",children:r.content||"--"})]}),r.result&&(0,t.jsxs)("div",{className:"bg-[#111128] border border-[#2a2a4a] rounded-xl p-4",children:[(0,t.jsx)("div",{className:"text-xs text-gray-500 uppercase mb-2",children:"Output"}),(0,t.jsx)("div",{className:"text-sm text-gray-300 whitespace-pre-wrap max-h-64 overflow-y-auto",children:r.result})]}),c.length>0&&(0,t.jsxs)("div",{className:"bg-[#111128] border border-[#2a2a4a] rounded-xl p-4",children:[(0,t.jsxs)("div",{className:"text-xs text-gray-500 uppercase mb-2",children:["Events (",c.length,")"]}),(0,t.jsx)("div",{className:"space-y-1.5 max-h-40 overflow-y-auto",children:c.map(e=>(0,t.jsxs)("div",{className:"flex items-center gap-2 text-[11px]",children:[(0,t.jsx)("span",{className:`w-1.5 h-1.5 rounded-full shrink-0 ${"running"===e.to_status?"bg-green-400":"replied"===e.to_status?"bg-purple-400":"failed"===e.to_status?"bg-red-400":"bg-blue-400"}`}),(0,t.jsx)("span",{className:"text-gray-400",children:e.event_type}),e.from_status&&(0,t.jsxs)("span",{className:"text-gray-600",children:[e.from_status,"→",e.to_status]}),(0,t.jsx)("span",{className:"text-gray-600 ml-auto",children:(0,n.timeAgo)(e.created_at)})]},e.id))})]}),(0,t.jsxs)("div",{className:"text-[10px] text-gray-600 space-y-1",children:[(0,t.jsxs)("div",{children:["Task ID: ",r.task_id]}),r.expires_at&&(0,t.jsxs)("div",{children:["Expires: ",r.expires_at]})]})]}):(0,t.jsx)("div",{className:"text-center py-16 text-gray-500",children:"Task not found"})]})]})}var o=e.i(95356);let c=["","created","delivered","acked","running","replied","closed","failed","cancelled","expired"],x={created:"bg-gray-500/10 text-gray-400 border-gray-500/20",delivered:"bg-blue-500/10 text-blue-300 border-blue-500/20",acked:"bg-cyan-500/10 text-cyan-300 border-cyan-500/20",running:"bg-green-500/10 text-green-300 border-green-500/20",replied:"bg-purple-500/10 text-purple-300 border-purple-500/20",closed:"bg-gray-500/10 text-gray-500 border-gray-500/20",failed:"bg-red-500/10 text-red-300 border-red-500/20",cancelled:"bg-yellow-500/10 text-yellow-300 border-yellow-500/20",expired:"bg-orange-500/10 text-orange-300 border-orange-500/20"},h={created:"#9ca3af",delivered:"#60a5fa",acked:"#22d3ee",running:"#4ade80",replied:"#a78bfa",closed:"#6b7280",failed:"#f87171",cancelled:"#facc15",expired:"#fb923c"};function m(e){let t=x[e]||"bg-gray-500/10 text-gray-400 border-gray-500/20";return`text-xs px-2 py-0.5 rounded-md border ${t}`}function p(e){return"high"===e?"text-red-400":"low"===e?"text-gray-600":"text-gray-400"}function g(e){if(!e)return"--";let t=Math.floor((Date.now()-new Date(e.replace(" ","T")+"Z").getTime())/1e3);return t<60?`${t}s ago`:t<3600?`${Math.floor(t/60)}m ago`:t<86400?`${Math.floor(t/3600)}h ago`:`${Math.floor(t/86400)}d ago`}function u(){let e,n,l,u,y=(0,s.useSearchParams)(),{networkId:j}=(0,r.useNetworkId)(),[b,v]=(0,a.useState)([]),[f,N]=(0,a.useState)(0),[w,k]=(0,a.useState)(!0),[_,C]=(0,a.useState)(""),[$,S]=(0,a.useState)(new Set),[M,T]=(0,a.useState)(y.get("status")||""),[A,D]=(0,a.useState)(""),[L,B]=(0,a.useState)(""),[E,I]=(0,a.useState)(null),z=e=>{S(t=>{let a=new Set(t);return a.has(e)?a.delete(e):a.add(e),a})},P=(0,a.useCallback)(async()=>{try{let e=new URLSearchParams;j&&e.set("network_id",j),M&&e.set("status",M),A&&e.set("from_name",A),L&&e.set("to_name",L),e.set("limit","100");let t=await fetch(`/api/hub/tasks?${e.toString()}`);if(401===t.status)return void window.location.assign("/login");let a=await t.json();v(a.tasks||[]),N(a.count??(a.tasks?.length||0)),C("")}catch(e){C(e instanceof Error?e.message:"fetch failed")}finally{k(!1)}},[M,A,L,j]);return(0,a.useEffect)(()=>{k(!0),P();let e=setInterval(P,5e3);return()=>clearInterval(e)},[P]),(0,t.jsxs)("div",{className:"min-h-screen bg-[#0a0a1a] text-gray-100 p-4 sm:p-6 font-mono",children:[(0,t.jsxs)("div",{className:"flex items-center gap-4 mb-6",children:[(0,t.jsx)("h1",{className:"text-2xl font-bold text-white lg:ml-0 ml-10",children:"Tasks"}),(0,t.jsx)("span",{className:"text-xs bg-blue-900/30 text-blue-400 px-2 py-0.5 rounded-full border border-blue-800/30",children:f})]}),(0,t.jsx)("div",{className:"anet-tabstrip-wrap mb-4",children:(0,t.jsx)("div",{className:"anet-tabstrip flex sm:flex-wrap gap-1 bg-[#111128] rounded-lg border border-[#2a2a4a] p-1 overflow-x-auto sm:overflow-x-visible scrollbar-thin",children:(e={},b.forEach(t=>{e[t.status]=(e[t.status]||0)+1}),["",...c.filter(Boolean)].map(a=>{let s=""===a?b.length:e[a]||0,r=M===a;return(0,t.jsxs)("button",{onClick:()=>T(a),disabled:0===s&&""!==a&&!r,className:`px-3 py-1.5 rounded-md text-xs transition-colors flex items-center gap-1.5 shrink-0 whitespace-nowrap disabled:opacity-30 disabled:cursor-not-allowed ${r?`${x[a]||"bg-cyan-500/10 text-cyan-300 border-cyan-500/20"} border`:"text-gray-500 hover:text-gray-300 hover:bg-[#1a1a2a]/40"}`,children:[a&&(0,t.jsx)("span",{"aria-hidden":!0,className:"inline-block w-1.5 h-1.5 rounded-full shrink-0",style:{backgroundColor:h[a]||"#6b7280"}}),(0,t.jsx)("span",{children:a||"All"}),(0,t.jsx)("span",{className:`text-[10px] tabular-nums ${r?"opacity-80":"text-gray-600"}`,children:s})]},a)}))})}),(0,t.jsxs)("div",{className:"flex flex-wrap items-center gap-2 mb-6",children:[(0,t.jsxs)("div",{className:"flex items-center gap-1.5 rounded-lg border border-[#2a2a4a] bg-[#111128] px-2.5 py-1.5 focus-within:border-blue-500/40",children:[(0,t.jsx)("span",{className:"text-[10px] uppercase tracking-wide text-gray-600",children:"From"}),(0,t.jsx)("input",{type:"text",value:A,onChange:e=>D(e.target.value),placeholder:"any node",className:"w-28 bg-transparent text-sm text-white placeholder-gray-700 focus:outline-none"})]}),(0,t.jsxs)("div",{className:"flex items-center gap-1.5 rounded-lg border border-[#2a2a4a] bg-[#111128] px-2.5 py-1.5 focus-within:border-blue-500/40",children:[(0,t.jsx)("span",{className:"text-[10px] uppercase tracking-wide text-gray-600",children:"To"}),(0,t.jsx)("input",{type:"text",value:L,onChange:e=>B(e.target.value),placeholder:"any node",className:"w-28 bg-transparent text-sm text-white placeholder-gray-700 focus:outline-none"})]}),(M||A||L)&&(0,t.jsx)("button",{type:"button",onClick:()=>{T(""),D(""),B("")},className:"rounded-lg border border-gray-700 px-2.5 py-1.5 text-[11px] text-gray-500 hover:text-gray-200 hover:border-gray-600",children:"Clear filters"})]}),b.length>0&&!M&&(n={},b.forEach(e=>{n[e.status]=(n[e.status]||0)+1}),l=b.length||1,(u=[{key:"created",color:"bg-gray-500"},{key:"delivered",color:"bg-blue-500"},{key:"acked",color:"bg-cyan-500"},{key:"running",color:"bg-green-500"},{key:"replied",color:"bg-purple-500"},{key:"closed",color:"bg-gray-600"},{key:"failed",color:"bg-red-500"},{key:"cancelled",color:"bg-yellow-500"},{key:"expired",color:"bg-orange-500"}].filter(e=>n[e.key])).length?(0,t.jsx)("div",{className:"mb-6",children:(0,t.jsx)("div",{className:"flex h-2 rounded-full overflow-hidden bg-gray-800",children:u.map(e=>(0,t.jsx)("div",{className:e.color,style:{width:`${n[e.key]/l*100}%`},title:`${e.key}: ${n[e.key]}`},e.key))})}):null),_&&(0,t.jsx)("div",{className:"bg-red-900/20 border border-red-800/40 text-red-300 px-4 py-2 rounded-lg mb-6 text-sm",children:_}),w?(0,t.jsx)("div",{className:"animate-pulse space-y-3",children:[1,2,3,4,5].map(e=>(0,t.jsx)("div",{className:"h-20 bg-gray-800/20 rounded-lg border border-gray-800/40"},e))}):0===b.length?(0,t.jsx)(o.EmptyState,{variant:"tasks",sub:M||A||L?"No tasks match the current filters. Try clearing them.":"Tasks will appear here when agents send them via CommHub."}):(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsxs)("div",{className:"hidden sm:grid sm:grid-cols-12 gap-2 px-4 py-2 text-xs text-gray-600 uppercase",children:[(0,t.jsx)("div",{className:"col-span-1",children:"Status"}),(0,t.jsx)("div",{className:"col-span-2",children:"From"}),(0,t.jsx)("div",{className:"col-span-2",children:"To"}),(0,t.jsx)("div",{className:"col-span-4",children:"Content"}),(0,t.jsx)("div",{className:"col-span-1",children:"Priority"}),(0,t.jsx)("div",{className:"col-span-2",children:"Time"})]}),b.map(e=>{let a=$.has(e.task_id);return(0,t.jsxs)("div",{className:`anet-task-row group bg-[#111128] border rounded-lg px-4 py-3 transition-all duration-200 cursor-pointer ${a?"border-[#3a3a5a] shadow-lg shadow-black/20":"border-[#2a2a4a] hover:border-[#3a3a5a] hover:bg-[#15152e]"}`,onClick:()=>z(e.task_id),role:"button",tabIndex:0,"aria-expanded":a,onKeyDown:t=>{("Enter"===t.key||" "===t.key)&&(t.preventDefault(),z(e.task_id))},children:[(0,t.jsxs)("div",{className:"hidden sm:grid sm:grid-cols-12 gap-2 items-center",children:[(0,t.jsx)("div",{className:"col-span-1",children:(0,t.jsx)("span",{className:m(e.status),children:e.status})}),(0,t.jsxs)("div",{className:"col-span-2 flex items-center gap-1.5 min-w-0",title:e.from_name,children:[e.from_name&&(0,t.jsx)(i.AliasAvatar,{alias:e.from_name,size:18}),(0,t.jsx)("span",{className:"truncate text-sm text-gray-200",children:e.from_name||"--"})]}),(0,t.jsxs)("div",{className:"col-span-2 flex items-center gap-1.5 min-w-0",title:e.to_name,children:[e.to_name&&(0,t.jsx)(i.AliasAvatar,{alias:e.to_name,size:18}),(0,t.jsx)("span",{className:"truncate text-sm text-gray-200",children:e.to_name||"--"})]}),(0,t.jsx)("div",{className:"col-span-4 text-xs text-gray-400 truncate",title:e.content,children:e.content||"--"}),(0,t.jsx)("div",{className:"col-span-1",children:(0,t.jsx)("span",{className:`text-xs ${p(e.priority)}`,children:e.priority||"normal"})}),(0,t.jsxs)("div",{className:"col-span-2 text-xs text-gray-500 flex items-center justify-between gap-2",title:e.created_at,children:[(0,t.jsx)("span",{className:"truncate",children:g(e.created_at)}),(0,t.jsx)("svg",{"aria-hidden":!0,className:`shrink-0 text-gray-600 group-hover:text-gray-400 transition-transform duration-200 ${a?"rotate-180":""}`,width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",children:(0,t.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 9l6 6 6-6"})})]})]}),(0,t.jsxs)("div",{className:"sm:hidden space-y-2",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between",children:[(0,t.jsx)("span",{className:m(e.status),children:e.status}),(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)("span",{className:`text-xs ${p(e.priority)}`,children:e.priority||"normal"}),(0,t.jsx)("svg",{"aria-hidden":!0,className:`text-gray-600 transition-transform duration-200 ${a?"rotate-180":""}`,width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",children:(0,t.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 9l6 6 6-6"})})]})]}),(0,t.jsxs)("div",{className:"flex items-center gap-1.5 text-xs text-gray-300 min-w-0",children:[e.from_name&&(0,t.jsx)(i.AliasAvatar,{alias:e.from_name,size:16}),(0,t.jsx)("span",{className:"truncate max-w-[40%]",children:e.from_name||"--"}),(0,t.jsx)("span",{className:"text-gray-600",children:"→"}),e.to_name&&(0,t.jsx)(i.AliasAvatar,{alias:e.to_name,size:16}),(0,t.jsx)("span",{className:"truncate max-w-[40%]",children:e.to_name||"--"})]}),(0,t.jsx)("div",{className:"text-xs text-gray-400 line-clamp-1",children:e.content||"--"}),(0,t.jsx)("div",{className:"text-xs text-gray-600",children:g(e.created_at)})]}),(0,t.jsx)("div",{className:`grid transition-all duration-300 ease-out ${a?"grid-rows-[1fr] opacity-100 mt-3":"grid-rows-[0fr] opacity-0"}`,"aria-hidden":!a,children:(0,t.jsx)("div",{className:"overflow-hidden",children:(0,t.jsxs)("div",{className:"pt-3 border-t border-[#2a2a4a] space-y-3",children:[e.content&&(0,t.jsxs)("div",{children:[(0,t.jsx)("div",{className:"text-xs text-gray-600 mb-1",children:"Content"}),(0,t.jsx)("div",{className:"text-xs text-gray-300 whitespace-pre-wrap bg-[#0a0a15] rounded-lg px-3 py-2 border border-[#1a1a2a]",children:e.content})]}),e.result&&(0,t.jsxs)("div",{children:[(0,t.jsx)("div",{className:"text-xs text-gray-600 mb-1",children:"Result"}),(0,t.jsx)("div",{className:"text-xs text-gray-300 whitespace-pre-wrap bg-[#0a0a15] rounded-lg px-3 py-2 border border-[#1a1a2a] max-h-48 overflow-y-auto",children:e.result})]}),(0,t.jsx)("div",{className:"grid grid-cols-2 sm:grid-cols-4 gap-2 text-xs",children:[["Created",e.created_at],["Delivered",e.delivered_at],["Started",e.started_at],["Completed",e.completed_at]].map(([e,a])=>(0,t.jsxs)("div",{children:[(0,t.jsxs)("span",{className:"text-gray-600",children:[e,": "]}),(0,t.jsx)("span",{className:"text-gray-400",children:a?g(a):"--"})]},e))}),e.expires_at&&(0,t.jsxs)("div",{className:"text-xs",children:[(0,t.jsx)("span",{className:"text-gray-600",children:"Expires: "}),(0,t.jsx)("span",{className:"text-orange-400",children:e.expires_at})]}),(0,t.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,t.jsxs)("div",{className:"text-xs text-gray-600 truncate",title:e.task_id,children:["ID: ",e.task_id]}),(0,t.jsxs)("div",{className:"flex gap-2 shrink-0",children:[("failed"===e.status||"expired"===e.status)&&(0,t.jsx)("button",{onClick:async t=>{t.stopPropagation(),await fetch("/api/hub/send",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({alias:e.to_name,task:e.content,priority:e.priority})}),P()},className:"text-xs text-orange-400 hover:text-orange-300 px-2 py-0.5 rounded border border-orange-500/20 hover:bg-orange-500/10",children:"Retry"}),(0,t.jsx)("button",{onClick:t=>{t.stopPropagation(),I(e.task_id)},className:"text-xs text-cyan-400 hover:text-cyan-300",children:"Detail →"})]})]})]})})})]},e.task_id)})]}),E&&(0,t.jsx)(d,{taskId:E,onClose:()=>I(null)})]})}e.s(["default",0,function(){return(0,t.jsx)(a.Suspense,{fallback:(0,t.jsx)("div",{className:"min-h-screen bg-[#0a0a1a] text-gray-100 p-6 font-mono",children:"Loading tasks..."}),children:(0,t.jsx)(u,{})})}],96527)}]);
package/.next/trace CHANGED
@@ -1,2 +1,2 @@
1
- [{"name":"generate-buildid","duration":345,"timestamp":215579865194,"id":4,"parentId":1,"tags":{},"startTime":1778587065690,"traceId":"a7df17184a8179e3"},{"name":"load-custom-routes","duration":534,"timestamp":215579865693,"id":5,"parentId":1,"tags":{},"startTime":1778587065690,"traceId":"a7df17184a8179e3"},{"name":"create-dist-dir","duration":1090,"timestamp":215579866286,"id":6,"parentId":1,"tags":{},"startTime":1778587065691,"traceId":"a7df17184a8179e3"},{"name":"clean","duration":555,"timestamp":215579868569,"id":7,"parentId":1,"tags":{},"startTime":1778587065693,"traceId":"a7df17184a8179e3"},{"name":"discover-routes","duration":10311,"timestamp":215579966521,"id":8,"parentId":1,"tags":{},"startTime":1778587065791,"traceId":"a7df17184a8179e3"},{"name":"create-root-mapping","duration":150,"timestamp":215579976908,"id":9,"parentId":1,"tags":{},"startTime":1778587065802,"traceId":"a7df17184a8179e3"},{"name":"generate-route-types","duration":35165,"timestamp":215579979652,"id":10,"parentId":1,"tags":{},"startTime":1778587065804,"traceId":"a7df17184a8179e3"},{"name":"public-dir-conflict-check","duration":140,"timestamp":215580015094,"id":11,"parentId":1,"tags":{},"startTime":1778587065840,"traceId":"a7df17184a8179e3"},{"name":"generate-routes-manifest","duration":6388,"timestamp":215580015429,"id":12,"parentId":1,"tags":{},"startTime":1778587065840,"traceId":"a7df17184a8179e3"},{"name":"run-turbopack","duration":14241265,"timestamp":215580029394,"id":14,"parentId":1,"tags":{},"startTime":1778587065854,"traceId":"a7df17184a8179e3"},{"name":"turbopack-build-events","duration":132,"timestamp":215580400165,"id":15,"parentId":1,"tags":{},"startTime":1778587066225,"traceId":"a7df17184a8179e3"},{"name":"run-typescript","duration":10909059,"timestamp":215594283255,"id":16,"parentId":1,"tags":{},"startTime":1778587080108,"traceId":"a7df17184a8179e3"},{"name":"generate-required-server-files","duration":2508,"timestamp":215605193432,"id":18,"parentId":1,"tags":{},"startTime":1778587091018,"traceId":"a7df17184a8179e3"},{"name":"check-static-error-page","duration":32591,"timestamp":215605291082,"id":20,"parentId":19,"tags":{},"startTime":1778587091116,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":615700,"timestamp":215605326844,"id":62,"parentId":22,"tags":{},"startTime":1778587091152,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":645949,"timestamp":215605296718,"id":22,"parentId":19,"tags":{"page":"/_global-error"},"startTime":1778587091121,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":771638,"timestamp":215605326922,"id":63,"parentId":25,"tags":{},"startTime":1778587091152,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":796282,"timestamp":215605302359,"id":25,"parentId":19,"tags":{"page":"/api/auth/login"},"startTime":1778587091127,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":782978,"timestamp":215605336095,"id":64,"parentId":26,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":816051,"timestamp":215605303102,"id":26,"parentId":19,"tags":{"page":"/api/auth/logout"},"startTime":1778587091128,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":790255,"timestamp":215605336259,"id":66,"parentId":28,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":821889,"timestamp":215605304696,"id":28,"parentId":19,"tags":{"page":"/api/hub/audit-log"},"startTime":1778587091129,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":798929,"timestamp":215605336218,"id":65,"parentId":27,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":832067,"timestamp":215605303266,"id":27,"parentId":19,"tags":{"page":"/api/auth/v3"},"startTime":1778587091128,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":807056,"timestamp":215605336301,"id":67,"parentId":29,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":838585,"timestamp":215605304836,"id":29,"parentId":19,"tags":{"page":"/api/hub/auth"},"startTime":1778587091130,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":812053,"timestamp":215605336340,"id":68,"parentId":30,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":843022,"timestamp":215605305433,"id":30,"parentId":19,"tags":{"page":"/api/hub/broadcast"},"startTime":1778587091130,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":819769,"timestamp":215605336399,"id":69,"parentId":32,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":849791,"timestamp":215605306453,"id":32,"parentId":19,"tags":{"page":"/api/hub/health"},"startTime":1778587091131,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":820024,"timestamp":215605336532,"id":70,"parentId":33,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":849487,"timestamp":215605307107,"id":33,"parentId":19,"tags":{"page":"/api/hub/inbox"},"startTime":1778587091132,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":825057,"timestamp":215605336581,"id":71,"parentId":34,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":852014,"timestamp":215605309678,"id":34,"parentId":19,"tags":{"page":"/api/hub/license"},"startTime":1778587091134,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":826312,"timestamp":215605336597,"id":72,"parentId":35,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":853133,"timestamp":215605309839,"id":35,"parentId":19,"tags":{"page":"/api/hub/messages"},"startTime":1778587091135,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":829663,"timestamp":215605336663,"id":73,"parentId":36,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":856129,"timestamp":215605310244,"id":36,"parentId":19,"tags":{"page":"/api/hub/networks"},"startTime":1778587091135,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":830413,"timestamp":215605336683,"id":74,"parentId":37,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":856743,"timestamp":215605310390,"id":37,"parentId":19,"tags":{"page":"/api/hub/nodes"},"startTime":1778587091135,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":835655,"timestamp":215605336692,"id":75,"parentId":38,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":861930,"timestamp":215605310502,"id":38,"parentId":19,"tags":{"page":"/api/hub/register"},"startTime":1778587091135,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":836856,"timestamp":215605336698,"id":76,"parentId":39,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":863012,"timestamp":215605310580,"id":39,"parentId":19,"tags":{"page":"/api/hub/send"},"startTime":1778587091135,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":848128,"timestamp":215605326528,"id":61,"parentId":21,"tags":{},"startTime":1778587091151,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":881809,"timestamp":215605292879,"id":21,"parentId":19,"tags":{"page":"/_not-found"},"startTime":1778587091118,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":840366,"timestamp":215605336704,"id":77,"parentId":40,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":866460,"timestamp":215605310663,"id":40,"parentId":19,"tags":{"page":"/api/hub/server-logs"},"startTime":1778587091135,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":844401,"timestamp":215605336721,"id":80,"parentId":43,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":870280,"timestamp":215605310886,"id":43,"parentId":19,"tags":{"page":"/api/hub/status"},"startTime":1778587091136,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":845665,"timestamp":215605336709,"id":78,"parentId":41,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":871674,"timestamp":215605310740,"id":41,"parentId":19,"tags":{"page":"/api/hub/session"},"startTime":1778587091135,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":849602,"timestamp":215605336726,"id":81,"parentId":44,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":875404,"timestamp":215605310970,"id":44,"parentId":19,"tags":{"page":"/api/hub/task-events"},"startTime":1778587091136,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":853833,"timestamp":215605336731,"id":82,"parentId":45,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":876499,"timestamp":215605314114,"id":45,"parentId":19,"tags":{"page":"/api/hub/tasks"},"startTime":1778587091139,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":854671,"timestamp":215605336736,"id":83,"parentId":46,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":877168,"timestamp":215605314278,"id":46,"parentId":19,"tags":{"page":"/api/hub/tmux"},"startTime":1778587091139,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":858175,"timestamp":215605336747,"id":85,"parentId":48,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":880712,"timestamp":215605314460,"id":48,"parentId":19,"tags":{"page":"/favicon.ico"},"startTime":1778587091139,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":860663,"timestamp":215605336742,"id":84,"parentId":47,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":883092,"timestamp":215605314376,"id":47,"parentId":19,"tags":{"page":"/api/hub/tokens"},"startTime":1778587091139,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":858366,"timestamp":215605341835,"id":86,"parentId":24,"tags":{},"startTime":1778587091167,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":903038,"timestamp":215605297216,"id":24,"parentId":19,"tags":{"page":"/api/anet/config"},"startTime":1778587091122,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":864197,"timestamp":215605345211,"id":87,"parentId":31,"tags":{},"startTime":1778587091170,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":903884,"timestamp":215605305585,"id":31,"parentId":19,"tags":{"page":"/api/hub/events"},"startTime":1778587091130,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":916544,"timestamp":215605347303,"id":89,"parentId":49,"tags":{},"startTime":1778587091172,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":947478,"timestamp":215605316430,"id":49,"parentId":19,"tags":{"page":"/login"},"startTime":1778587091141,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":927946,"timestamp":215605336715,"id":79,"parentId":42,"tags":{},"startTime":1778587091161,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":953889,"timestamp":215605310817,"id":42,"parentId":19,"tags":{"page":"/api/hub/stats"},"startTime":1778587091136,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":919653,"timestamp":215605347269,"id":88,"parentId":23,"tags":{},"startTime":1778587091172,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":969986,"timestamp":215605296981,"id":23,"parentId":19,"tags":{"page":"/admin"},"startTime":1778587091122,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":926135,"timestamp":215605347319,"id":91,"parentId":51,"tags":{},"startTime":1778587091172,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":956777,"timestamp":215605316733,"id":51,"parentId":19,"tags":{"page":"/messages"},"startTime":1778587091141,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":928190,"timestamp":215605347313,"id":90,"parentId":50,"tags":{},"startTime":1778587091172,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":958965,"timestamp":215605316601,"id":50,"parentId":19,"tags":{"page":"/logs"},"startTime":1778587091141,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":933379,"timestamp":215605347325,"id":92,"parentId":52,"tags":{},"startTime":1778587091172,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":963860,"timestamp":215605316895,"id":52,"parentId":19,"tags":{"page":"/node"},"startTime":1778587091142,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":945954,"timestamp":215605347330,"id":93,"parentId":53,"tags":{},"startTime":1778587091172,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":976267,"timestamp":215605317098,"id":53,"parentId":19,"tags":{"page":"/nodes"},"startTime":1778587091142,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":946133,"timestamp":215605347341,"id":95,"parentId":56,"tags":{},"startTime":1778587091172,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":975559,"timestamp":215605317936,"id":56,"parentId":19,"tags":{"page":"/settings/networks"},"startTime":1778587091143,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":946237,"timestamp":215605347336,"id":94,"parentId":55,"tags":{},"startTime":1778587091172,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":975839,"timestamp":215605317752,"id":55,"parentId":19,"tags":{"page":"/server-logs"},"startTime":1778587091142,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":959993,"timestamp":215605347360,"id":98,"parentId":60,"tags":{},"startTime":1778587091172,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":983950,"timestamp":215605323462,"id":60,"parentId":19,"tags":{"page":"/tasks"},"startTime":1778587091148,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":962572,"timestamp":215605347347,"id":96,"parentId":58,"tags":{},"startTime":1778587091172,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":986838,"timestamp":215605323131,"id":58,"parentId":19,"tags":{"page":"/settings/tokens"},"startTime":1778587091148,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":965363,"timestamp":215605347352,"id":97,"parentId":59,"tags":{},"startTime":1778587091172,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":989447,"timestamp":215605323328,"id":59,"parentId":19,"tags":{"page":"/tasks/[id]"},"startTime":1778587091148,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":949798,"timestamp":215605372405,"id":99,"parentId":54,"tags":{},"startTime":1778587091197,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":1004979,"timestamp":215605317283,"id":54,"parentId":19,"tags":{"page":"/"},"startTime":1778587091142,"traceId":"a7df17184a8179e3"},{"name":"is-page-static","duration":936548,"timestamp":215605388545,"id":100,"parentId":57,"tags":{},"startTime":1778587091213,"traceId":"a7df17184a8179e3"},{"name":"check-page","duration":1007036,"timestamp":215605318113,"id":57,"parentId":19,"tags":{"page":"/settings"},"startTime":1778587091143,"traceId":"a7df17184a8179e3"},{"name":"static-check","duration":1038518,"timestamp":215605286681,"id":19,"parentId":1,"tags":{},"startTime":1778587091112,"traceId":"a7df17184a8179e3"},{"name":"write-routes-manifest","duration":569,"timestamp":215606333110,"id":102,"parentId":1,"tags":{},"startTime":1778587092158,"traceId":"a7df17184a8179e3"},{"name":"load-dotenv","duration":53,"timestamp":215606347601,"id":105,"parentId":104,"tags":{},"startTime":1778587092172,"traceId":"a7df17184a8179e3"},{"name":"run-export-path-map","duration":640,"timestamp":215606350861,"id":106,"parentId":104,"tags":{},"startTime":1778587092176,"traceId":"a7df17184a8179e3"},{"name":"next-export","duration":761177,"timestamp":215606346175,"id":104,"parentId":1,"tags":{},"startTime":1778587092171,"traceId":"a7df17184a8179e3"},{"name":"move-exported-app-not-found-","duration":2202,"timestamp":215607114820,"id":107,"parentId":103,"tags":{},"startTime":1778587092940,"traceId":"a7df17184a8179e3"},{"name":"move-exported-app-global-error-","duration":423,"timestamp":215607117148,"id":108,"parentId":103,"tags":{},"startTime":1778587092942,"traceId":"a7df17184a8179e3"}]
2
- [{"name":"static-generation","duration":785894,"timestamp":215606337715,"id":103,"parentId":1,"tags":{},"startTime":1778587092162,"traceId":"a7df17184a8179e3"},{"name":"write-routes-manifest","duration":442,"timestamp":215607123891,"id":109,"parentId":1,"tags":{},"startTime":1778587092949,"traceId":"a7df17184a8179e3"},{"name":"print-tree-view","duration":4698,"timestamp":215607137192,"id":110,"parentId":1,"tags":{},"startTime":1778587092962,"traceId":"a7df17184a8179e3"},{"name":"write-route-bundle-stats","duration":17250,"timestamp":215607141993,"id":111,"parentId":1,"tags":{},"startTime":1778587092967,"traceId":"a7df17184a8179e3"},{"name":"telemetry-flush","duration":26142,"timestamp":215607159282,"id":112,"parentId":1,"tags":{},"startTime":1778587092984,"traceId":"a7df17184a8179e3"},{"name":"next-build","duration":27388200,"timestamp":215579797273,"id":1,"tags":{"buildMode":"default","version":"16.2.3","bundler":"turbopack","has-custom-webpack-config":"false","use-build-worker":"true"},"startTime":1778587065622,"traceId":"a7df17184a8179e3"}]
1
+ [{"name":"generate-buildid","duration":363,"timestamp":216669743416,"id":4,"parentId":1,"tags":{},"startTime":1778588155568,"traceId":"6f2c7d271fd68d74"},{"name":"load-custom-routes","duration":569,"timestamp":216669743935,"id":5,"parentId":1,"tags":{},"startTime":1778588155569,"traceId":"6f2c7d271fd68d74"},{"name":"create-dist-dir","duration":494,"timestamp":216669744554,"id":6,"parentId":1,"tags":{},"startTime":1778588155569,"traceId":"6f2c7d271fd68d74"},{"name":"clean","duration":516,"timestamp":216669746365,"id":7,"parentId":1,"tags":{},"startTime":1778588155571,"traceId":"6f2c7d271fd68d74"},{"name":"discover-routes","duration":12552,"timestamp":216669858940,"id":8,"parentId":1,"tags":{},"startTime":1778588155684,"traceId":"6f2c7d271fd68d74"},{"name":"create-root-mapping","duration":121,"timestamp":216669871564,"id":9,"parentId":1,"tags":{},"startTime":1778588155696,"traceId":"6f2c7d271fd68d74"},{"name":"generate-route-types","duration":37036,"timestamp":216669874318,"id":10,"parentId":1,"tags":{},"startTime":1778588155699,"traceId":"6f2c7d271fd68d74"},{"name":"public-dir-conflict-check","duration":102,"timestamp":216669911523,"id":11,"parentId":1,"tags":{},"startTime":1778588155736,"traceId":"6f2c7d271fd68d74"},{"name":"generate-routes-manifest","duration":4189,"timestamp":216669911739,"id":12,"parentId":1,"tags":{},"startTime":1778588155736,"traceId":"6f2c7d271fd68d74"},{"name":"run-turbopack","duration":9584091,"timestamp":216669925544,"id":14,"parentId":1,"tags":{},"startTime":1778588155750,"traceId":"6f2c7d271fd68d74"},{"name":"turbopack-build-events","duration":87,"timestamp":216670357603,"id":15,"parentId":1,"tags":{},"startTime":1778588156182,"traceId":"6f2c7d271fd68d74"},{"name":"run-typescript","duration":8628977,"timestamp":216679516753,"id":16,"parentId":1,"tags":{},"startTime":1778588165341,"traceId":"6f2c7d271fd68d74"},{"name":"generate-required-server-files","duration":2512,"timestamp":216688146533,"id":18,"parentId":1,"tags":{},"startTime":1778588173971,"traceId":"6f2c7d271fd68d74"},{"name":"check-static-error-page","duration":15982,"timestamp":216688239694,"id":20,"parentId":19,"tags":{},"startTime":1778588174064,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":421404,"timestamp":216688258306,"id":62,"parentId":22,"tags":{},"startTime":1778588174083,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":437648,"timestamp":216688242216,"id":22,"parentId":19,"tags":{"page":"/_global-error"},"startTime":1778588174067,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":541385,"timestamp":216688258556,"id":64,"parentId":26,"tags":{},"startTime":1778588174083,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":551543,"timestamp":216688248511,"id":26,"parentId":19,"tags":{"page":"/api/auth/logout"},"startTime":1778588174073,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":579456,"timestamp":216688257974,"id":61,"parentId":21,"tags":{},"startTime":1778588174083,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":596619,"timestamp":216688240893,"id":21,"parentId":19,"tags":{"page":"/_not-found"},"startTime":1778588174066,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":583874,"timestamp":216688258604,"id":65,"parentId":27,"tags":{},"startTime":1778588174083,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":593929,"timestamp":216688248630,"id":27,"parentId":19,"tags":{"page":"/api/auth/v3"},"startTime":1778588174073,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":607959,"timestamp":216688258684,"id":67,"parentId":29,"tags":{},"startTime":1778588174083,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":617853,"timestamp":216688248890,"id":29,"parentId":19,"tags":{"page":"/api/hub/auth"},"startTime":1778588174074,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":613240,"timestamp":216688258728,"id":68,"parentId":30,"tags":{},"startTime":1778588174083,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":622942,"timestamp":216688249148,"id":30,"parentId":19,"tags":{"page":"/api/hub/broadcast"},"startTime":1778588174074,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":620259,"timestamp":216688258775,"id":69,"parentId":32,"tags":{},"startTime":1778588174083,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":629560,"timestamp":216688249592,"id":32,"parentId":19,"tags":{"page":"/api/hub/health"},"startTime":1778588174074,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":624099,"timestamp":216688258880,"id":70,"parentId":33,"tags":{},"startTime":1778588174084,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":633323,"timestamp":216688249753,"id":33,"parentId":19,"tags":{"page":"/api/hub/inbox"},"startTime":1778588174074,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":629319,"timestamp":216688258930,"id":71,"parentId":34,"tags":{},"startTime":1778588174084,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":638459,"timestamp":216688249867,"id":34,"parentId":19,"tags":{"page":"/api/hub/license"},"startTime":1778588174075,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":635246,"timestamp":216688258950,"id":72,"parentId":35,"tags":{},"startTime":1778588174084,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":644314,"timestamp":216688249969,"id":35,"parentId":19,"tags":{"page":"/api/hub/messages"},"startTime":1778588174075,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":640289,"timestamp":216688260390,"id":73,"parentId":36,"tags":{},"startTime":1778588174085,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":650388,"timestamp":216688250380,"id":36,"parentId":19,"tags":{"page":"/api/hub/networks"},"startTime":1778588174075,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":647370,"timestamp":216688260451,"id":74,"parentId":37,"tags":{},"startTime":1778588174085,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":657374,"timestamp":216688250519,"id":37,"parentId":19,"tags":{"page":"/api/hub/nodes"},"startTime":1778588174075,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":652404,"timestamp":216688260470,"id":75,"parentId":38,"tags":{},"startTime":1778588174085,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":662335,"timestamp":216688250624,"id":38,"parentId":19,"tags":{"page":"/api/hub/register"},"startTime":1778588174075,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":659385,"timestamp":216688258393,"id":63,"parentId":25,"tags":{},"startTime":1778588174083,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":669553,"timestamp":216688248289,"id":25,"parentId":19,"tags":{"page":"/api/auth/login"},"startTime":1778588174073,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":657515,"timestamp":216688260480,"id":76,"parentId":39,"tags":{},"startTime":1778588174085,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":667344,"timestamp":216688250704,"id":39,"parentId":19,"tags":{"page":"/api/hub/send"},"startTime":1778588174075,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":661077,"timestamp":216688260504,"id":78,"parentId":41,"tags":{},"startTime":1778588174085,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":670760,"timestamp":216688250870,"id":41,"parentId":19,"tags":{"page":"/api/hub/session"},"startTime":1778588174076,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":667603,"timestamp":216688260512,"id":79,"parentId":42,"tags":{},"startTime":1778588174085,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":677250,"timestamp":216688250945,"id":42,"parentId":19,"tags":{"page":"/api/hub/stats"},"startTime":1778588174076,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":668244,"timestamp":216688260525,"id":80,"parentId":43,"tags":{},"startTime":1778588174085,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":677775,"timestamp":216688251043,"id":43,"parentId":19,"tags":{"page":"/api/hub/status"},"startTime":1778588174076,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":671196,"timestamp":216688258644,"id":66,"parentId":28,"tags":{},"startTime":1778588174083,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":681138,"timestamp":216688248751,"id":28,"parentId":19,"tags":{"page":"/api/hub/audit-log"},"startTime":1778588174073,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":671588,"timestamp":216688260538,"id":81,"parentId":44,"tags":{},"startTime":1778588174085,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":681033,"timestamp":216688251140,"id":44,"parentId":19,"tags":{"page":"/api/hub/task-events"},"startTime":1778588174076,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":674489,"timestamp":216688260543,"id":82,"parentId":45,"tags":{},"startTime":1778588174085,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":683895,"timestamp":216688251213,"id":45,"parentId":19,"tags":{"page":"/api/hub/tasks"},"startTime":1778588174076,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":674721,"timestamp":216688260552,"id":83,"parentId":46,"tags":{},"startTime":1778588174085,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":683998,"timestamp":216688251310,"id":46,"parentId":19,"tags":{"page":"/api/hub/tmux"},"startTime":1778588174076,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":679957,"timestamp":216688260561,"id":84,"parentId":47,"tags":{},"startTime":1778588174085,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":689200,"timestamp":216688251385,"id":47,"parentId":19,"tags":{"page":"/api/hub/tokens"},"startTime":1778588174076,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":680425,"timestamp":216688260568,"id":85,"parentId":48,"tags":{},"startTime":1778588174085,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":689597,"timestamp":216688251464,"id":48,"parentId":19,"tags":{"page":"/favicon.ico"},"startTime":1778588174076,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":687199,"timestamp":216688262896,"id":86,"parentId":24,"tags":{},"startTime":1778588174088,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":707553,"timestamp":216688242616,"id":24,"parentId":19,"tags":{"page":"/api/anet/config"},"startTime":1778588174067,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":687414,"timestamp":216688264533,"id":87,"parentId":31,"tags":{},"startTime":1778588174089,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":702750,"timestamp":216688249267,"id":31,"parentId":19,"tags":{"page":"/api/hub/events"},"startTime":1778588174074,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":704612,"timestamp":216688260492,"id":77,"parentId":40,"tags":{},"startTime":1778588174085,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":714431,"timestamp":216688250792,"id":40,"parentId":19,"tags":{"page":"/api/hub/server-logs"},"startTime":1778588174075,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":699023,"timestamp":216688272552,"id":88,"parentId":23,"tags":{},"startTime":1778588174097,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":729192,"timestamp":216688242453,"id":23,"parentId":19,"tags":{"page":"/admin"},"startTime":1778588174067,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":708871,"timestamp":216688272606,"id":91,"parentId":51,"tags":{},"startTime":1778588174097,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":729337,"timestamp":216688252208,"id":51,"parentId":19,"tags":{"page":"/messages"},"startTime":1778588174077,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":719117,"timestamp":216688272615,"id":92,"parentId":52,"tags":{},"startTime":1778588174097,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":739393,"timestamp":216688252395,"id":52,"parentId":19,"tags":{"page":"/node"},"startTime":1778588174077,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":730597,"timestamp":216688272620,"id":93,"parentId":53,"tags":{},"startTime":1778588174097,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":750715,"timestamp":216688252590,"id":53,"parentId":19,"tags":{"page":"/nodes"},"startTime":1778588174077,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":736916,"timestamp":216688272629,"id":94,"parentId":55,"tags":{},"startTime":1778588174097,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":756325,"timestamp":216688253295,"id":55,"parentId":19,"tags":{"page":"/server-logs"},"startTime":1778588174078,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":745212,"timestamp":216688272637,"id":95,"parentId":56,"tags":{},"startTime":1778588174097,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":764456,"timestamp":216688253492,"id":56,"parentId":19,"tags":{"page":"/settings/networks"},"startTime":1778588174078,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":749306,"timestamp":216688272589,"id":89,"parentId":49,"tags":{},"startTime":1778588174097,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":770114,"timestamp":216688251849,"id":49,"parentId":19,"tags":{"page":"/login"},"startTime":1778588174077,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":751832,"timestamp":216688272596,"id":90,"parentId":50,"tags":{},"startTime":1778588174097,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":772454,"timestamp":216688252028,"id":50,"parentId":19,"tags":{"page":"/logs"},"startTime":1778588174077,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":752860,"timestamp":216688272643,"id":96,"parentId":58,"tags":{},"startTime":1778588174097,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":771096,"timestamp":216688254464,"id":58,"parentId":19,"tags":{"page":"/settings/tokens"},"startTime":1778588174079,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":758364,"timestamp":216688272665,"id":98,"parentId":60,"tags":{},"startTime":1778588174097,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":775655,"timestamp":216688255437,"id":60,"parentId":19,"tags":{"page":"/tasks"},"startTime":1778588174080,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":761489,"timestamp":216688272673,"id":99,"parentId":57,"tags":{},"startTime":1778588174097,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":780171,"timestamp":216688254048,"id":57,"parentId":19,"tags":{"page":"/settings"},"startTime":1778588174079,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":752515,"timestamp":216688283334,"id":100,"parentId":54,"tags":{},"startTime":1778588174108,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":783102,"timestamp":216688252807,"id":54,"parentId":19,"tags":{"page":"/"},"startTime":1778588174077,"traceId":"6f2c7d271fd68d74"},{"name":"is-page-static","duration":766707,"timestamp":216688272651,"id":97,"parentId":59,"tags":{},"startTime":1778588174097,"traceId":"6f2c7d271fd68d74"},{"name":"check-page","duration":784149,"timestamp":216688255296,"id":59,"parentId":19,"tags":{"page":"/tasks/[id]"},"startTime":1778588174080,"traceId":"6f2c7d271fd68d74"},{"name":"static-check","duration":800598,"timestamp":216688238922,"id":19,"parentId":1,"tags":{},"startTime":1778588174064,"traceId":"6f2c7d271fd68d74"},{"name":"write-routes-manifest","duration":517,"timestamp":216689046807,"id":102,"parentId":1,"tags":{},"startTime":1778588174872,"traceId":"6f2c7d271fd68d74"},{"name":"load-dotenv","duration":83,"timestamp":216689061449,"id":105,"parentId":104,"tags":{},"startTime":1778588174886,"traceId":"6f2c7d271fd68d74"},{"name":"run-export-path-map","duration":756,"timestamp":216689064996,"id":106,"parentId":104,"tags":{},"startTime":1778588174890,"traceId":"6f2c7d271fd68d74"},{"name":"next-export","duration":679145,"timestamp":216689060188,"id":104,"parentId":1,"tags":{},"startTime":1778588174885,"traceId":"6f2c7d271fd68d74"},{"name":"move-exported-app-not-found-","duration":1447,"timestamp":216689745576,"id":107,"parentId":103,"tags":{},"startTime":1778588175570,"traceId":"6f2c7d271fd68d74"},{"name":"move-exported-app-global-error-","duration":371,"timestamp":216689747154,"id":108,"parentId":103,"tags":{},"startTime":1778588175572,"traceId":"6f2c7d271fd68d74"}]
2
+ [{"name":"static-generation","duration":704920,"timestamp":216689052795,"id":103,"parentId":1,"tags":{},"startTime":1778588174877,"traceId":"6f2c7d271fd68d74"},{"name":"write-routes-manifest","duration":844,"timestamp":216689758115,"id":109,"parentId":1,"tags":{},"startTime":1778588175583,"traceId":"6f2c7d271fd68d74"},{"name":"print-tree-view","duration":8659,"timestamp":216689787319,"id":110,"parentId":1,"tags":{},"startTime":1778588175612,"traceId":"6f2c7d271fd68d74"},{"name":"write-route-bundle-stats","duration":49048,"timestamp":216689796049,"id":111,"parentId":1,"tags":{},"startTime":1778588175621,"traceId":"6f2c7d271fd68d74"},{"name":"telemetry-flush","duration":117,"timestamp":216689845137,"id":112,"parentId":1,"tags":{},"startTime":1778588175670,"traceId":"6f2c7d271fd68d74"},{"name":"next-build","duration":20196186,"timestamp":216669649086,"id":1,"tags":{"buildMode":"default","version":"16.2.3","bundler":"turbopack","has-custom-webpack-config":"false","use-build-worker":"true"},"startTime":1778588155474,"traceId":"6f2c7d271fd68d74"}]
package/.next/trace-build CHANGED
@@ -1 +1 @@
1
- [{"name":"run-turbopack","duration":14241265,"timestamp":215580029394,"id":14,"parentId":1,"tags":{},"startTime":1778587065854,"traceId":"a7df17184a8179e3"},{"name":"turbopack-build-events","duration":132,"timestamp":215580400165,"id":15,"parentId":1,"tags":{},"startTime":1778587066225,"traceId":"a7df17184a8179e3"},{"name":"run-typescript","duration":10909059,"timestamp":215594283255,"id":16,"parentId":1,"tags":{},"startTime":1778587080108,"traceId":"a7df17184a8179e3"},{"name":"static-check","duration":1038518,"timestamp":215605286681,"id":19,"parentId":1,"tags":{},"startTime":1778587091112,"traceId":"a7df17184a8179e3"},{"name":"static-generation","duration":785894,"timestamp":215606337715,"id":103,"parentId":1,"tags":{},"startTime":1778587092162,"traceId":"a7df17184a8179e3"},{"name":"telemetry-flush","duration":26142,"timestamp":215607159282,"id":112,"parentId":1,"tags":{},"startTime":1778587092984,"traceId":"a7df17184a8179e3"},{"name":"next-build","duration":27388200,"timestamp":215579797273,"id":1,"tags":{"buildMode":"default","version":"16.2.3","bundler":"turbopack","has-custom-webpack-config":"false","use-build-worker":"true"},"startTime":1778587065622,"traceId":"a7df17184a8179e3"}]
1
+ [{"name":"run-turbopack","duration":9584091,"timestamp":216669925544,"id":14,"parentId":1,"tags":{},"startTime":1778588155750,"traceId":"6f2c7d271fd68d74"},{"name":"turbopack-build-events","duration":87,"timestamp":216670357603,"id":15,"parentId":1,"tags":{},"startTime":1778588156182,"traceId":"6f2c7d271fd68d74"},{"name":"run-typescript","duration":8628977,"timestamp":216679516753,"id":16,"parentId":1,"tags":{},"startTime":1778588165341,"traceId":"6f2c7d271fd68d74"},{"name":"static-check","duration":800598,"timestamp":216688238922,"id":19,"parentId":1,"tags":{},"startTime":1778588174064,"traceId":"6f2c7d271fd68d74"},{"name":"static-generation","duration":704920,"timestamp":216689052795,"id":103,"parentId":1,"tags":{},"startTime":1778588174877,"traceId":"6f2c7d271fd68d74"},{"name":"telemetry-flush","duration":117,"timestamp":216689845137,"id":112,"parentId":1,"tags":{},"startTime":1778588175670,"traceId":"6f2c7d271fd68d74"},{"name":"next-build","duration":20196186,"timestamp":216669649086,"id":1,"tags":{"buildMode":"default","version":"16.2.3","bundler":"turbopack","has-custom-webpack-config":"false","use-build-worker":"true"},"startTime":1778588155474,"traceId":"6f2c7d271fd68d74"}]
@@ -0,0 +1,63 @@
1
+ /** Single source of truth for task status colors. Both `/tasks` (chip
2
+ * strip, badge, distribution bar) and the Overview Recent Activity row
3
+ * used to ship their own incomplete maps; round 66 consolidates them
4
+ * here so adding a new status updates every consumer at once.
5
+ *
6
+ * Order in `TASK_STATUSES` is chronological-ish: lifecycle progress on
7
+ * the left, terminal-good (`closed`) in the middle, terminal-bad
8
+ * (`failed`/`cancelled`/`expired`) on the right. */
9
+
10
+ export const TASK_STATUSES = [
11
+ 'created',
12
+ 'delivered',
13
+ 'acked',
14
+ 'running',
15
+ 'replied',
16
+ 'closed',
17
+ 'failed',
18
+ 'cancelled',
19
+ 'expired',
20
+ ] as const;
21
+
22
+ export type TaskStatus = typeof TASK_STATUSES[number];
23
+
24
+ /** Pill / chip background+text+border. Tailwind classes, not inlined hex,
25
+ * because chips are static class names safe from purge. */
26
+ export const STATUS_CHIP_CLASS: Record<string, string> = {
27
+ created: 'bg-gray-500/10 text-gray-400 border-gray-500/20',
28
+ delivered: 'bg-blue-500/10 text-blue-300 border-blue-500/20',
29
+ acked: 'bg-cyan-500/10 text-cyan-300 border-cyan-500/20',
30
+ running: 'bg-green-500/10 text-green-300 border-green-500/20',
31
+ replied: 'bg-purple-500/10 text-purple-300 border-purple-500/20',
32
+ closed: 'bg-gray-500/10 text-gray-500 border-gray-500/20',
33
+ failed: 'bg-red-500/10 text-red-300 border-red-500/20',
34
+ cancelled: 'bg-yellow-500/10 text-yellow-300 border-yellow-500/20',
35
+ expired: 'bg-orange-500/10 text-orange-300 border-orange-500/20',
36
+ };
37
+
38
+ /** Inline hex dots — used wherever Tailwind would purge dynamic class
39
+ * names (`bg-${family}-400`). Style attribute carries the color. */
40
+ export const STATUS_DOT_HEX: Record<string, string> = {
41
+ created: '#9ca3af',
42
+ delivered: '#60a5fa',
43
+ acked: '#22d3ee',
44
+ running: '#4ade80',
45
+ replied: '#a78bfa',
46
+ closed: '#6b7280',
47
+ failed: '#f87171',
48
+ cancelled: '#facc15',
49
+ expired: '#fb923c',
50
+ };
51
+
52
+ /** Solid bar segment background for the Tasks distribution bar. */
53
+ export const STATUS_BAR_CLASS: Record<string, string> = {
54
+ created: 'bg-gray-500',
55
+ delivered: 'bg-blue-500',
56
+ acked: 'bg-cyan-500',
57
+ running: 'bg-green-500',
58
+ replied: 'bg-purple-500',
59
+ closed: 'bg-gray-600',
60
+ failed: 'bg-red-500',
61
+ cancelled: 'bg-yellow-500',
62
+ expired: 'bg-orange-500',
63
+ };
package/app/page.tsx CHANGED
@@ -11,6 +11,7 @@ import { InboxPanel } from './components/InboxPanel';
11
11
  import { LoadingSkeleton } from './components/LoadingSkeleton';
12
12
  import { NodesEmptyState as EmptyState } from './components/EmptyState';
13
13
  import { AliasAvatar } from './components/AliasAvatar';
14
+ import { STATUS_DOT_HEX, STATUS_CHIP_CLASS } from './lib/status';
14
15
  import { UserBar } from './components/UserBar';
15
16
  import { CommandCenter, useCommandCenter } from './components/CommandCenter';
16
17
  import { DispatchPanel } from './components/DispatchPanel';
@@ -313,9 +314,10 @@ export default function Dashboard() {
313
314
  <div className="space-y-2 max-h-40 overflow-y-auto">
314
315
  {tasks.slice(0, 5).map((t: { task_id: string; from_name: string; to_name: string; status: string; content: string; created_at: string }) => (
315
316
  <div key={t.task_id} className="flex items-center gap-2 text-xs">
316
- <span className={`w-1.5 h-1.5 rounded-full shrink-0 ${
317
- t.status === 'replied' ? 'bg-purple-400' : t.status === 'running' ? 'bg-green-400' : t.status === 'failed' ? 'bg-red-400' : 'bg-blue-400'
318
- }`} />
317
+ <span
318
+ className="w-1.5 h-1.5 rounded-full shrink-0"
319
+ style={{ backgroundColor: STATUS_DOT_HEX[t.status] || '#6b7280' }}
320
+ />
319
321
  {t.from_name && <AliasAvatar alias={t.from_name} size={14} />}
320
322
  <span className="text-gray-300 shrink-0 max-w-[20%] truncate">{t.from_name || '?'}</span>
321
323
  <span className="text-gray-600">&rarr;</span>
@@ -323,7 +325,7 @@ export default function Dashboard() {
323
325
  <span className="text-gray-300 shrink-0 max-w-[20%] truncate">{t.to_name || '?'}</span>
324
326
  <span className="text-gray-500 truncate flex-1">{t.content?.slice(0, 40) || '--'}</span>
325
327
  <span className={`shrink-0 px-1.5 py-0.5 rounded text-[10px] border ${
326
- t.status === 'replied' ? 'text-purple-300 border-purple-500/20' : t.status === 'failed' ? 'text-red-300 border-red-500/20' : 'text-gray-500 border-gray-700/30'
328
+ STATUS_CHIP_CLASS[t.status] || 'text-gray-500 border-gray-700/30'
327
329
  }`}>{t.status}</span>
328
330
  </div>
329
331
  ))}
@@ -233,17 +233,18 @@ function TasksContent() {
233
233
  const stats: Record<string, number> = {};
234
234
  tasks.forEach(t => { stats[t.status] = (stats[t.status] || 0) + 1; });
235
235
  const total = tasks.length || 1;
236
- // Round 64: full status coverage `acked` was missing, which in
237
- // production is by far the most common state (e.g. 52/83 tasks).
238
- // The proportional bar appeared half-empty without it. Now lists
239
- // every task lifecycle state in chronological-ish order.
236
+ // Round 64-65: full coverage of all 9 task lifecycle states.
237
+ // Chronological-ish order: created delivered acked running
238
+ // replied closed (archived) failed / cancelled / expired
239
+ // (terminal-bad). Matches STATUS_OPTIONS exactly.
240
240
  const bars = [
241
- { key: 'created', color: 'bg-gray-500' },
242
- { key: 'delivered', color: 'bg-blue-500' },
243
- { key: 'acked', color: 'bg-cyan-500' },
244
- { key: 'running', color: 'bg-green-500' },
241
+ { key: 'created', color: 'bg-gray-500' },
242
+ { key: 'delivered', color: 'bg-blue-500' },
243
+ { key: 'acked', color: 'bg-cyan-500' },
244
+ { key: 'running', color: 'bg-green-500' },
245
245
  { key: 'replied', color: 'bg-purple-500' },
246
- { key: 'failed', color: 'bg-red-500' },
246
+ { key: 'closed', color: 'bg-gray-600' },
247
+ { key: 'failed', color: 'bg-red-500' },
247
248
  { key: 'cancelled', color: 'bg-yellow-500' },
248
249
  { key: 'expired', color: 'bg-orange-500' },
249
250
  ].filter(b => stats[b.key]);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sleep2agi/agent-network-dashboard",
3
- "version": "0.4.5-preview.47",
3
+ "version": "0.4.5-preview.49",
4
4
  "description": "Agent Network Dashboard — Web UI for managing AI Agent networks",
5
5
  "scripts": {
6
6
  "dev": "next dev",