@auto-ai/agent 2.1.126 → 2.1.128

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 (55) hide show
  1. package/dist/404/index.html +1 -1
  2. package/dist/404.html +1 -1
  3. package/dist/_next/static/chunks/{9dc241c9b2aa0f91.js → 0bb72b120dc81a85.js} +1 -1
  4. package/dist/_next/static/chunks/{7a5fd448b280dd64.js → 11e6ca4bf89238c8.js} +1 -1
  5. package/dist/_next/static/chunks/1601f801b0efe2b7.js +1 -0
  6. package/dist/_next/static/chunks/{53977130ef33592f.js → 22d483db0dece6fa.js} +1 -1
  7. package/dist/_next/static/chunks/5817c66b26ce8538.css +1 -0
  8. package/dist/_next/static/chunks/{6f9a48a7f83e669a.js → 67bb401596b3c723.js} +1 -1
  9. package/dist/_next/static/chunks/{566e152e480b267a.js → 67ed23cd064b3759.js} +1 -1
  10. package/dist/_next/static/chunks/6f004c225e10839e.js +1 -0
  11. package/dist/_next/static/chunks/{f2bb685629307d4d.js → 848159b04d61ef38.js} +1 -1
  12. package/dist/_next/static/chunks/{33eeef286c328da0.js → 9724f0d9ea70a30f.js} +1 -1
  13. package/dist/_next/static/chunks/98a41a7efbe71682.js +1 -0
  14. package/dist/_next/static/chunks/{a38eccf0bb5ca1e9.js → bcefc2c679f3ada6.js} +1 -1
  15. package/dist/_next/static/chunks/{17e79ae7309781d6.js → cb4dec27441d471a.js} +1 -1
  16. package/dist/_next/static/chunks/d059ec9b9c0efd14.js +1 -0
  17. package/dist/_next/static/chunks/fb29f7b061918c67.js +1 -0
  18. package/dist/index.html +1 -1
  19. package/dist/index.txt +8 -8
  20. package/dist/manage/about/index.html +2 -2
  21. package/dist/manage/about/index.txt +9 -9
  22. package/dist/manage/add-account/basic/index.html +2 -2
  23. package/dist/manage/add-account/basic/index.txt +12 -13
  24. package/dist/manage/add-account/index.html +2 -2
  25. package/dist/manage/add-account/index.txt +13 -12
  26. package/dist/manage/agent-teams/index.html +2 -2
  27. package/dist/manage/agent-teams/index.txt +11 -11
  28. package/dist/manage/env/index.html +2 -2
  29. package/dist/manage/env/index.txt +11 -11
  30. package/dist/manage/general/index.html +2 -2
  31. package/dist/manage/general/index.txt +9 -9
  32. package/dist/manage/index.html +1 -1
  33. package/dist/manage/index.txt +6 -6
  34. package/dist/manage/mcp/index.html +2 -2
  35. package/dist/manage/mcp/index.txt +11 -11
  36. package/dist/manage/permissions/index.html +2 -2
  37. package/dist/manage/permissions/index.txt +9 -9
  38. package/dist/manage/skills/index.html +2 -2
  39. package/dist/manage/skills/index.txt +11 -11
  40. package/dist/manage/task/index.html +2 -2
  41. package/dist/manage/task/index.txt +9 -9
  42. package/dist/manage/teams/index.html +2 -2
  43. package/dist/manage/teams/index.txt +9 -9
  44. package/dist/manage/tools/index.html +2 -2
  45. package/dist/manage/tools/index.txt +11 -11
  46. package/package.json +6 -6
  47. package/dist/_next/static/chunks/19aa69c07b3642d5.js +0 -1
  48. package/dist/_next/static/chunks/24459c7365a2b28b.js +0 -1
  49. package/dist/_next/static/chunks/6ad4268160f361a6.js +0 -1
  50. package/dist/_next/static/chunks/7658b5b9c2865eb1.js +0 -1
  51. package/dist/_next/static/chunks/b29a354245bfc377.css +0 -1
  52. package/dist/_next/static/chunks/c5a4977aae6a008c.js +0 -1
  53. /package/dist/_next/static/{lNBSG0s2sztoG2gw766B8 → dOWHotWZcTuV50_vyRSGI}/_buildManifest.js +0 -0
  54. /package/dist/_next/static/{lNBSG0s2sztoG2gw766B8 → dOWHotWZcTuV50_vyRSGI}/_clientMiddlewareManifest.json +0 -0
  55. /package/dist/_next/static/{lNBSG0s2sztoG2gw766B8 → dOWHotWZcTuV50_vyRSGI}/_ssgManifest.js +0 -0
@@ -1 +1 @@
1
- <!DOCTYPE html><!--lNBSG0s2sztoG2gw766B8--><html lang="zh-CN" class="sora_a6e0e515-module__NbNjtG__variable dm_sans_fa25cdfd-module__fB5nTW__variable jetbrains_mono_2b1eae20-module__XfFTLG__variable font-sans"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="/app/_next/static/chunks/fa361913d47fdc14.css" data-precedence="next"/><link rel="stylesheet" href="/app/_next/static/chunks/e7bd145455a541af.css" data-precedence="next"/><link rel="stylesheet" href="/app/_next/static/chunks/b29a354245bfc377.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/app/_next/static/chunks/76a71d344cc15a9f.js"/><script src="/app/_next/static/chunks/91adb7bdb9870c6a.js" async=""></script><script src="/app/_next/static/chunks/40268f8e3ff0314e.js" async=""></script><script src="/app/_next/static/chunks/32b4d63e10d31351.js" async=""></script><script src="/app/_next/static/chunks/66b30159915524db.js" async=""></script><script src="/app/_next/static/chunks/turbopack-030a42d60560a927.js" async=""></script><script src="/app/_next/static/chunks/e520aa06a5014225.js" async=""></script><script src="/app/_next/static/chunks/fc4be3bcf72559a0.js" async=""></script><script src="/app/_next/static/chunks/7988d5ea63356e10.js" async=""></script><meta name="robots" content="noindex"/><meta name="next-size-adjust" content=""/><title>404: This page could not be found.</title><title>Claude Code测试平台</title><meta name="description" content="Claude Code测试平台"/><script src="/app/_next/static/chunks/a6dad97d9634a72d.js" noModule=""></script></head><body><div hidden=""><!--$--><!--/$--></div><section aria-label="Notifications alt+T" tabindex="-1" aria-live="polite" aria-relevant="additions text" aria-atomic="false"></section><!--$--><div style="font-family:system-ui,&quot;Segoe UI&quot;,Roboto,Helvetica,Arial,sans-serif,&quot;Apple Color Emoji&quot;,&quot;Segoe UI Emoji&quot;;height:100vh;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center"><div><style>body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}</style><h1 class="next-error-h1" style="display:inline-block;margin:0 20px 0 0;padding:0 23px 0 0;font-size:24px;font-weight:500;vertical-align:top;line-height:49px">404</h1><div style="display:inline-block"><h2 style="font-size:14px;font-weight:400;line-height:49px;margin:0">This page could not be found.</h2></div></div></div><!--$--><!--/$--><!--/$--><script src="/app/_next/static/chunks/76a71d344cc15a9f.js" id="_R_" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:\"$Sreact.fragment\"\n2:I[13354,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"AppToaster\"]\n3:I[39756,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\n4:I[37457,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\n5:I[97367,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"OutletBoundary\"]\n7:I[11533,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"AsyncMetadataOutlet\"]\n9:I[58541,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\na:I[97367,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"ViewportBoundary\"]\nc:I[97367,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"MetadataBoundary\"]\nd:\"$Sreact.suspense\"\nf:I[68027,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\n:HL[\"/app/_next/static/chunks/fa361913d47fdc14.css\",\"style\"]\n:HL[\"/app/_next/static/chunks/e7bd145455a541af.css\",\"style\"]\n:HL[\"/app/_next/static/chunks/b29a354245bfc377.css\",\"style\"]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"b\":\"lNBSG0s2sztoG2gw766B8\",\"p\":\"/app\",\"c\":[\"\",\"_not-found\",\"\"],\"i\":false,\"f\":[[[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",true],[\"\",[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/app/_next/static/chunks/fa361913d47fdc14.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"link\",\"1\",{\"rel\":\"stylesheet\",\"href\":\"/app/_next/static/chunks/e7bd145455a541af.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"link\",\"2\",{\"rel\":\"stylesheet\",\"href\":\"/app/_next/static/chunks/b29a354245bfc377.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-0\",{\"src\":\"/app/_next/static/chunks/e520aa06a5014225.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-1\",{\"src\":\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-2\",{\"src\":\"/app/_next/static/chunks/7988d5ea63356e10.js\",\"async\":true,\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"zh-CN\",\"className\":\"sora_a6e0e515-module__NbNjtG__variable dm_sans_fa25cdfd-module__fB5nTW__variable jetbrains_mono_2b1eae20-module__XfFTLG__variable font-sans\",\"children\":[\"$\",\"body\",null,{\"children\":[[\"$\",\"$L2\",null,{}],[\"$\",\"$L3\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L4\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":404}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],[]],\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}]}]]}],{\"children\":[\"/_not-found\",[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L3\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L4\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[\"__PAGE__\",[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:style\",\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:children:props:children:1:props:style\",\"children\":404}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:children:props:children:2:props:style\",\"children\":[\"$\",\"h2\",null,{\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:children:props:children:2:props:children:props:style\",\"children\":\"This page could not be found.\"}]}]]}]}]],null,[\"$\",\"$L5\",null,{\"children\":[\"$L6\",[\"$\",\"$L7\",null,{\"promise\":\"$@8\"}]]}]]}],{},null,false]},null,false]},[[\"$\",\"div\",\"l\",{\"className\":\"flex min-h-[40vh] flex-1 items-center justify-center gap-2 text-sm text-zinc-500\",\"children\":[[\"$\",\"$L9\",null,{\"ref\":\"$undefined\",\"iconNode\":[[\"path\",{\"d\":\"M21 12a9 9 0 1 1-6.219-8.56\",\"key\":\"13zald\"}]],\"className\":\"lucide-loader-circle animate-spin text-muted-foreground\",\"size\":16,\"color\":\"currentColor\",\"strokeWidth\":2,\"aria-hidden\":\"true\"}],\" 加载中\"]}],[],[]],false],[\"$\",\"$1\",\"h\",{\"children\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],[[\"$\",\"$La\",null,{\"children\":\"$Lb\"}],[\"$\",\"meta\",null,{\"name\":\"next-size-adjust\",\"content\":\"\"}]],[\"$\",\"$Lc\",null,{\"children\":[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$d\",null,{\"fallback\":null,\"children\":\"$Le\"}]}]}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$f\",\"$undefined\"],\"s\":false,\"S\":true}\n"])</script><script>self.__next_f.push([1,"b:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\n6:null\n"])</script><script>self.__next_f.push([1,"8:{\"metadata\":[[\"$\",\"title\",\"0\",{\"children\":\"Claude Code测试平台\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"Claude Code测试平台\"}]],\"error\":null,\"digest\":\"$undefined\"}\n"])</script><script>self.__next_f.push([1,"e:\"$8:metadata\"\n"])</script></body></html>
1
+ <!DOCTYPE html><!--dOWHotWZcTuV50_vyRSGI--><html lang="zh-CN" class="sora_a6e0e515-module__NbNjtG__variable dm_sans_fa25cdfd-module__fB5nTW__variable jetbrains_mono_2b1eae20-module__XfFTLG__variable font-sans"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="/app/_next/static/chunks/fa361913d47fdc14.css" data-precedence="next"/><link rel="stylesheet" href="/app/_next/static/chunks/e7bd145455a541af.css" data-precedence="next"/><link rel="stylesheet" href="/app/_next/static/chunks/5817c66b26ce8538.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/app/_next/static/chunks/76a71d344cc15a9f.js"/><script src="/app/_next/static/chunks/91adb7bdb9870c6a.js" async=""></script><script src="/app/_next/static/chunks/40268f8e3ff0314e.js" async=""></script><script src="/app/_next/static/chunks/32b4d63e10d31351.js" async=""></script><script src="/app/_next/static/chunks/66b30159915524db.js" async=""></script><script src="/app/_next/static/chunks/turbopack-030a42d60560a927.js" async=""></script><script src="/app/_next/static/chunks/e520aa06a5014225.js" async=""></script><script src="/app/_next/static/chunks/fc4be3bcf72559a0.js" async=""></script><script src="/app/_next/static/chunks/7988d5ea63356e10.js" async=""></script><meta name="robots" content="noindex"/><meta name="next-size-adjust" content=""/><title>404: This page could not be found.</title><title>Claude Code测试平台</title><meta name="description" content="Claude Code测试平台"/><script src="/app/_next/static/chunks/a6dad97d9634a72d.js" noModule=""></script></head><body><div hidden=""><!--$--><!--/$--></div><section aria-label="Notifications alt+T" tabindex="-1" aria-live="polite" aria-relevant="additions text" aria-atomic="false"></section><!--$--><div style="font-family:system-ui,&quot;Segoe UI&quot;,Roboto,Helvetica,Arial,sans-serif,&quot;Apple Color Emoji&quot;,&quot;Segoe UI Emoji&quot;;height:100vh;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center"><div><style>body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}</style><h1 class="next-error-h1" style="display:inline-block;margin:0 20px 0 0;padding:0 23px 0 0;font-size:24px;font-weight:500;vertical-align:top;line-height:49px">404</h1><div style="display:inline-block"><h2 style="font-size:14px;font-weight:400;line-height:49px;margin:0">This page could not be found.</h2></div></div></div><!--$--><!--/$--><!--/$--><script src="/app/_next/static/chunks/76a71d344cc15a9f.js" id="_R_" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:\"$Sreact.fragment\"\n2:I[13354,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"AppToaster\"]\n3:I[39756,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\n4:I[37457,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\n5:I[97367,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"OutletBoundary\"]\n7:I[11533,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"AsyncMetadataOutlet\"]\n9:I[58541,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\na:I[97367,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"ViewportBoundary\"]\nc:I[97367,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"MetadataBoundary\"]\nd:\"$Sreact.suspense\"\nf:I[68027,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\n:HL[\"/app/_next/static/chunks/fa361913d47fdc14.css\",\"style\"]\n:HL[\"/app/_next/static/chunks/e7bd145455a541af.css\",\"style\"]\n:HL[\"/app/_next/static/chunks/5817c66b26ce8538.css\",\"style\"]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"b\":\"dOWHotWZcTuV50_vyRSGI\",\"p\":\"/app\",\"c\":[\"\",\"_not-found\",\"\"],\"i\":false,\"f\":[[[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",true],[\"\",[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/app/_next/static/chunks/fa361913d47fdc14.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"link\",\"1\",{\"rel\":\"stylesheet\",\"href\":\"/app/_next/static/chunks/e7bd145455a541af.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"link\",\"2\",{\"rel\":\"stylesheet\",\"href\":\"/app/_next/static/chunks/5817c66b26ce8538.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-0\",{\"src\":\"/app/_next/static/chunks/e520aa06a5014225.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-1\",{\"src\":\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-2\",{\"src\":\"/app/_next/static/chunks/7988d5ea63356e10.js\",\"async\":true,\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"zh-CN\",\"className\":\"sora_a6e0e515-module__NbNjtG__variable dm_sans_fa25cdfd-module__fB5nTW__variable jetbrains_mono_2b1eae20-module__XfFTLG__variable font-sans\",\"children\":[\"$\",\"body\",null,{\"children\":[[\"$\",\"$L2\",null,{}],[\"$\",\"$L3\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L4\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":404}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],[]],\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}]}]]}],{\"children\":[\"/_not-found\",[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L3\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L4\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[\"__PAGE__\",[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:style\",\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:children:props:children:1:props:style\",\"children\":404}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:children:props:children:2:props:style\",\"children\":[\"$\",\"h2\",null,{\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:children:props:children:2:props:children:props:style\",\"children\":\"This page could not be found.\"}]}]]}]}]],null,[\"$\",\"$L5\",null,{\"children\":[\"$L6\",[\"$\",\"$L7\",null,{\"promise\":\"$@8\"}]]}]]}],{},null,false]},null,false]},[[\"$\",\"div\",\"l\",{\"className\":\"flex min-h-[40vh] flex-1 items-center justify-center gap-2 text-sm text-zinc-500\",\"children\":[[\"$\",\"$L9\",null,{\"ref\":\"$undefined\",\"iconNode\":[[\"path\",{\"d\":\"M21 12a9 9 0 1 1-6.219-8.56\",\"key\":\"13zald\"}]],\"className\":\"lucide-loader-circle animate-spin text-muted-foreground\",\"size\":16,\"color\":\"currentColor\",\"strokeWidth\":2,\"aria-hidden\":\"true\"}],\" 加载中\"]}],[],[]],false],[\"$\",\"$1\",\"h\",{\"children\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],[[\"$\",\"$La\",null,{\"children\":\"$Lb\"}],[\"$\",\"meta\",null,{\"name\":\"next-size-adjust\",\"content\":\"\"}]],[\"$\",\"$Lc\",null,{\"children\":[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$d\",null,{\"fallback\":null,\"children\":\"$Le\"}]}]}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$f\",\"$undefined\"],\"s\":false,\"S\":true}\n"])</script><script>self.__next_f.push([1,"b:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\n6:null\n"])</script><script>self.__next_f.push([1,"8:{\"metadata\":[[\"$\",\"title\",\"0\",{\"children\":\"Claude Code测试平台\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"Claude Code测试平台\"}]],\"error\":null,\"digest\":\"$undefined\"}\n"])</script><script>self.__next_f.push([1,"e:\"$8:metadata\"\n"])</script></body></html>
package/dist/404.html CHANGED
@@ -1 +1 @@
1
- <!DOCTYPE html><!--lNBSG0s2sztoG2gw766B8--><html lang="zh-CN" class="sora_a6e0e515-module__NbNjtG__variable dm_sans_fa25cdfd-module__fB5nTW__variable jetbrains_mono_2b1eae20-module__XfFTLG__variable font-sans"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="/app/_next/static/chunks/fa361913d47fdc14.css" data-precedence="next"/><link rel="stylesheet" href="/app/_next/static/chunks/e7bd145455a541af.css" data-precedence="next"/><link rel="stylesheet" href="/app/_next/static/chunks/b29a354245bfc377.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/app/_next/static/chunks/76a71d344cc15a9f.js"/><script src="/app/_next/static/chunks/91adb7bdb9870c6a.js" async=""></script><script src="/app/_next/static/chunks/40268f8e3ff0314e.js" async=""></script><script src="/app/_next/static/chunks/32b4d63e10d31351.js" async=""></script><script src="/app/_next/static/chunks/66b30159915524db.js" async=""></script><script src="/app/_next/static/chunks/turbopack-030a42d60560a927.js" async=""></script><script src="/app/_next/static/chunks/e520aa06a5014225.js" async=""></script><script src="/app/_next/static/chunks/fc4be3bcf72559a0.js" async=""></script><script src="/app/_next/static/chunks/7988d5ea63356e10.js" async=""></script><meta name="robots" content="noindex"/><meta name="next-size-adjust" content=""/><title>404: This page could not be found.</title><title>Claude Code测试平台</title><meta name="description" content="Claude Code测试平台"/><script src="/app/_next/static/chunks/a6dad97d9634a72d.js" noModule=""></script></head><body><div hidden=""><!--$--><!--/$--></div><section aria-label="Notifications alt+T" tabindex="-1" aria-live="polite" aria-relevant="additions text" aria-atomic="false"></section><!--$--><div style="font-family:system-ui,&quot;Segoe UI&quot;,Roboto,Helvetica,Arial,sans-serif,&quot;Apple Color Emoji&quot;,&quot;Segoe UI Emoji&quot;;height:100vh;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center"><div><style>body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}</style><h1 class="next-error-h1" style="display:inline-block;margin:0 20px 0 0;padding:0 23px 0 0;font-size:24px;font-weight:500;vertical-align:top;line-height:49px">404</h1><div style="display:inline-block"><h2 style="font-size:14px;font-weight:400;line-height:49px;margin:0">This page could not be found.</h2></div></div></div><!--$--><!--/$--><!--/$--><script src="/app/_next/static/chunks/76a71d344cc15a9f.js" id="_R_" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:\"$Sreact.fragment\"\n2:I[13354,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"AppToaster\"]\n3:I[39756,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\n4:I[37457,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\n5:I[97367,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"OutletBoundary\"]\n7:I[11533,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"AsyncMetadataOutlet\"]\n9:I[58541,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\na:I[97367,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"ViewportBoundary\"]\nc:I[97367,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"MetadataBoundary\"]\nd:\"$Sreact.suspense\"\nf:I[68027,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\n:HL[\"/app/_next/static/chunks/fa361913d47fdc14.css\",\"style\"]\n:HL[\"/app/_next/static/chunks/e7bd145455a541af.css\",\"style\"]\n:HL[\"/app/_next/static/chunks/b29a354245bfc377.css\",\"style\"]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"b\":\"lNBSG0s2sztoG2gw766B8\",\"p\":\"/app\",\"c\":[\"\",\"_not-found\",\"\"],\"i\":false,\"f\":[[[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",true],[\"\",[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/app/_next/static/chunks/fa361913d47fdc14.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"link\",\"1\",{\"rel\":\"stylesheet\",\"href\":\"/app/_next/static/chunks/e7bd145455a541af.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"link\",\"2\",{\"rel\":\"stylesheet\",\"href\":\"/app/_next/static/chunks/b29a354245bfc377.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-0\",{\"src\":\"/app/_next/static/chunks/e520aa06a5014225.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-1\",{\"src\":\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-2\",{\"src\":\"/app/_next/static/chunks/7988d5ea63356e10.js\",\"async\":true,\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"zh-CN\",\"className\":\"sora_a6e0e515-module__NbNjtG__variable dm_sans_fa25cdfd-module__fB5nTW__variable jetbrains_mono_2b1eae20-module__XfFTLG__variable font-sans\",\"children\":[\"$\",\"body\",null,{\"children\":[[\"$\",\"$L2\",null,{}],[\"$\",\"$L3\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L4\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":404}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],[]],\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}]}]]}],{\"children\":[\"/_not-found\",[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L3\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L4\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[\"__PAGE__\",[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:style\",\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:children:props:children:1:props:style\",\"children\":404}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:children:props:children:2:props:style\",\"children\":[\"$\",\"h2\",null,{\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:children:props:children:2:props:children:props:style\",\"children\":\"This page could not be found.\"}]}]]}]}]],null,[\"$\",\"$L5\",null,{\"children\":[\"$L6\",[\"$\",\"$L7\",null,{\"promise\":\"$@8\"}]]}]]}],{},null,false]},null,false]},[[\"$\",\"div\",\"l\",{\"className\":\"flex min-h-[40vh] flex-1 items-center justify-center gap-2 text-sm text-zinc-500\",\"children\":[[\"$\",\"$L9\",null,{\"ref\":\"$undefined\",\"iconNode\":[[\"path\",{\"d\":\"M21 12a9 9 0 1 1-6.219-8.56\",\"key\":\"13zald\"}]],\"className\":\"lucide-loader-circle animate-spin text-muted-foreground\",\"size\":16,\"color\":\"currentColor\",\"strokeWidth\":2,\"aria-hidden\":\"true\"}],\" 加载中\"]}],[],[]],false],[\"$\",\"$1\",\"h\",{\"children\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],[[\"$\",\"$La\",null,{\"children\":\"$Lb\"}],[\"$\",\"meta\",null,{\"name\":\"next-size-adjust\",\"content\":\"\"}]],[\"$\",\"$Lc\",null,{\"children\":[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$d\",null,{\"fallback\":null,\"children\":\"$Le\"}]}]}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$f\",\"$undefined\"],\"s\":false,\"S\":true}\n"])</script><script>self.__next_f.push([1,"b:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\n6:null\n"])</script><script>self.__next_f.push([1,"8:{\"metadata\":[[\"$\",\"title\",\"0\",{\"children\":\"Claude Code测试平台\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"Claude Code测试平台\"}]],\"error\":null,\"digest\":\"$undefined\"}\n"])</script><script>self.__next_f.push([1,"e:\"$8:metadata\"\n"])</script></body></html>
1
+ <!DOCTYPE html><!--dOWHotWZcTuV50_vyRSGI--><html lang="zh-CN" class="sora_a6e0e515-module__NbNjtG__variable dm_sans_fa25cdfd-module__fB5nTW__variable jetbrains_mono_2b1eae20-module__XfFTLG__variable font-sans"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="/app/_next/static/chunks/fa361913d47fdc14.css" data-precedence="next"/><link rel="stylesheet" href="/app/_next/static/chunks/e7bd145455a541af.css" data-precedence="next"/><link rel="stylesheet" href="/app/_next/static/chunks/5817c66b26ce8538.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/app/_next/static/chunks/76a71d344cc15a9f.js"/><script src="/app/_next/static/chunks/91adb7bdb9870c6a.js" async=""></script><script src="/app/_next/static/chunks/40268f8e3ff0314e.js" async=""></script><script src="/app/_next/static/chunks/32b4d63e10d31351.js" async=""></script><script src="/app/_next/static/chunks/66b30159915524db.js" async=""></script><script src="/app/_next/static/chunks/turbopack-030a42d60560a927.js" async=""></script><script src="/app/_next/static/chunks/e520aa06a5014225.js" async=""></script><script src="/app/_next/static/chunks/fc4be3bcf72559a0.js" async=""></script><script src="/app/_next/static/chunks/7988d5ea63356e10.js" async=""></script><meta name="robots" content="noindex"/><meta name="next-size-adjust" content=""/><title>404: This page could not be found.</title><title>Claude Code测试平台</title><meta name="description" content="Claude Code测试平台"/><script src="/app/_next/static/chunks/a6dad97d9634a72d.js" noModule=""></script></head><body><div hidden=""><!--$--><!--/$--></div><section aria-label="Notifications alt+T" tabindex="-1" aria-live="polite" aria-relevant="additions text" aria-atomic="false"></section><!--$--><div style="font-family:system-ui,&quot;Segoe UI&quot;,Roboto,Helvetica,Arial,sans-serif,&quot;Apple Color Emoji&quot;,&quot;Segoe UI Emoji&quot;;height:100vh;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center"><div><style>body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}</style><h1 class="next-error-h1" style="display:inline-block;margin:0 20px 0 0;padding:0 23px 0 0;font-size:24px;font-weight:500;vertical-align:top;line-height:49px">404</h1><div style="display:inline-block"><h2 style="font-size:14px;font-weight:400;line-height:49px;margin:0">This page could not be found.</h2></div></div></div><!--$--><!--/$--><!--/$--><script src="/app/_next/static/chunks/76a71d344cc15a9f.js" id="_R_" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:\"$Sreact.fragment\"\n2:I[13354,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"AppToaster\"]\n3:I[39756,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\n4:I[37457,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\n5:I[97367,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"OutletBoundary\"]\n7:I[11533,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"AsyncMetadataOutlet\"]\n9:I[58541,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\na:I[97367,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"ViewportBoundary\"]\nc:I[97367,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"MetadataBoundary\"]\nd:\"$Sreact.suspense\"\nf:I[68027,[\"/app/_next/static/chunks/e520aa06a5014225.js\",\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"/app/_next/static/chunks/7988d5ea63356e10.js\"],\"default\"]\n:HL[\"/app/_next/static/chunks/fa361913d47fdc14.css\",\"style\"]\n:HL[\"/app/_next/static/chunks/e7bd145455a541af.css\",\"style\"]\n:HL[\"/app/_next/static/chunks/5817c66b26ce8538.css\",\"style\"]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"b\":\"dOWHotWZcTuV50_vyRSGI\",\"p\":\"/app\",\"c\":[\"\",\"_not-found\",\"\"],\"i\":false,\"f\":[[[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",true],[\"\",[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/app/_next/static/chunks/fa361913d47fdc14.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"link\",\"1\",{\"rel\":\"stylesheet\",\"href\":\"/app/_next/static/chunks/e7bd145455a541af.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"link\",\"2\",{\"rel\":\"stylesheet\",\"href\":\"/app/_next/static/chunks/5817c66b26ce8538.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-0\",{\"src\":\"/app/_next/static/chunks/e520aa06a5014225.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-1\",{\"src\":\"/app/_next/static/chunks/fc4be3bcf72559a0.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-2\",{\"src\":\"/app/_next/static/chunks/7988d5ea63356e10.js\",\"async\":true,\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"zh-CN\",\"className\":\"sora_a6e0e515-module__NbNjtG__variable dm_sans_fa25cdfd-module__fB5nTW__variable jetbrains_mono_2b1eae20-module__XfFTLG__variable font-sans\",\"children\":[\"$\",\"body\",null,{\"children\":[[\"$\",\"$L2\",null,{}],[\"$\",\"$L3\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L4\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":404}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],[]],\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}]}]]}],{\"children\":[\"/_not-found\",[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L3\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L4\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[\"__PAGE__\",[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:style\",\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:children:props:children:1:props:style\",\"children\":404}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:children:props:children:2:props:style\",\"children\":[\"$\",\"h2\",null,{\"style\":\"$0:f:0:1:1:props:children:1:props:children:props:children:1:props:notFound:0:1:props:children:props:children:2:props:children:props:style\",\"children\":\"This page could not be found.\"}]}]]}]}]],null,[\"$\",\"$L5\",null,{\"children\":[\"$L6\",[\"$\",\"$L7\",null,{\"promise\":\"$@8\"}]]}]]}],{},null,false]},null,false]},[[\"$\",\"div\",\"l\",{\"className\":\"flex min-h-[40vh] flex-1 items-center justify-center gap-2 text-sm text-zinc-500\",\"children\":[[\"$\",\"$L9\",null,{\"ref\":\"$undefined\",\"iconNode\":[[\"path\",{\"d\":\"M21 12a9 9 0 1 1-6.219-8.56\",\"key\":\"13zald\"}]],\"className\":\"lucide-loader-circle animate-spin text-muted-foreground\",\"size\":16,\"color\":\"currentColor\",\"strokeWidth\":2,\"aria-hidden\":\"true\"}],\" 加载中\"]}],[],[]],false],[\"$\",\"$1\",\"h\",{\"children\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],[[\"$\",\"$La\",null,{\"children\":\"$Lb\"}],[\"$\",\"meta\",null,{\"name\":\"next-size-adjust\",\"content\":\"\"}]],[\"$\",\"$Lc\",null,{\"children\":[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$d\",null,{\"fallback\":null,\"children\":\"$Le\"}]}]}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$f\",\"$undefined\"],\"s\":false,\"S\":true}\n"])</script><script>self.__next_f.push([1,"b:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\n6:null\n"])</script><script>self.__next_f.push([1,"8:{\"metadata\":[[\"$\",\"title\",\"0\",{\"children\":\"Claude Code测试平台\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"Claude Code测试平台\"}]],\"error\":null,\"digest\":\"$undefined\"}\n"])</script><script>self.__next_f.push([1,"e:\"$8:metadata\"\n"])</script></body></html>
@@ -1 +1 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,93479,e=>{"use strict";e.s(["Input",()=>t]);var o=e.i(18050),r=e.i(75157);function t(e){let{className:t,type:n="text",size:s="default",...a}=e;return(0,o.jsx)("input",{type:n,"data-slot":"input","data-size":s,className:(0,r.cn)("h-8 w-full appearance-none rounded-md border border-solid border-border bg-transparent px-3 text-base outline-none transition-[color,box-shadow,border-color] duration-150 ease-in-out placeholder:text-muted-foreground hover:border-[#e0e0e0] focus-visible:border-[var(--border-focus)] focus-visible:[box-shadow:var(--ring-focus-sm)] read-only:focus-visible:border-border read-only:focus-visible:[box-shadow:none] disabled:cursor-not-allowed disabled:opacity-50 disabled:focus-visible:border-border disabled:focus-visible:[box-shadow:none] data-[size=default]:h-8 data-[size=lg]:h-10 data-[size=sm]:h-7",t),...a})}},20783,e=>{"use strict";e.s(["composeRefs",()=>t,"useComposedRefs",()=>n]);var o=e.i(71645);function r(e,o){if("function"==typeof e)return e(o);null!=e&&(e.current=o)}function t(){for(var e=arguments.length,o=Array(e),t=0;t<e;t++)o[t]=arguments[t];return e=>{let t=!1,n=o.map(o=>{let n=r(o,e);return t||"function"!=typeof n||(t=!0),n});if(t)return()=>{for(let e=0;e<n.length;e++){let t=n[e];"function"==typeof t?t():r(o[e],null)}}}}function n(){for(var e=arguments.length,r=Array(e),n=0;n<e;n++)r[n]=arguments[n];return o.useCallback(t(...r),r)}}]);
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,93479,e=>{"use strict";e.s(["Input",()=>t]);var o=e.i(18050),r=e.i(75157);function t(e){let{className:t,type:n="text",size:s="default",...a}=e;return(0,o.jsx)("input",{type:n,"data-slot":"input","data-size":s,className:(0,r.cn)("h-9 w-full appearance-none rounded-md border border-solid border-border bg-transparent px-3 text-base outline-none transition-[color,box-shadow,border-color] duration-150 ease-in-out placeholder:text-muted-foreground hover:border-[#e0e0e0] focus-visible:border-[var(--border-focus)] focus-visible:[box-shadow:var(--ring-focus-sm)] read-only:focus-visible:border-border read-only:focus-visible:[box-shadow:none] disabled:cursor-not-allowed disabled:opacity-50 disabled:focus-visible:border-border disabled:focus-visible:[box-shadow:none] data-[size=default]:h-9 data-[size=lg]:h-10 data-[size=sm]:h-7",t),...a})}},20783,e=>{"use strict";e.s(["composeRefs",()=>t,"useComposedRefs",()=>n]);var o=e.i(71645);function r(e,o){if("function"==typeof e)return e(o);null!=e&&(e.current=o)}function t(){for(var e=arguments.length,o=Array(e),t=0;t<e;t++)o[t]=arguments[t];return e=>{let t=!1,n=o.map(o=>{let n=r(o,e);return t||"function"!=typeof n||(t=!0),n});if(t)return()=>{for(let e=0;e<n.length;e++){let t=n[e];"function"==typeof t?t():r(o[e],null)}}}}function n(){for(var e=arguments.length,r=Array(e),n=0;n<e;n++)r[n]=arguments[n];return o.useCallback(t(...r),r)}}]);
@@ -1 +1 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,93479,e=>{"use strict";e.s(["Input",()=>l]);var a=e.i(18050),t=e.i(75157);function l(e){let{className:l,type:s="text",size:i="default",...n}=e;return(0,a.jsx)("input",{type:s,"data-slot":"input","data-size":i,className:(0,t.cn)("h-8 w-full appearance-none rounded-md border border-solid border-border bg-transparent px-3 text-base outline-none transition-[color,box-shadow,border-color] duration-150 ease-in-out placeholder:text-muted-foreground hover:border-[#e0e0e0] focus-visible:border-[var(--border-focus)] focus-visible:[box-shadow:var(--ring-focus-sm)] read-only:focus-visible:border-border read-only:focus-visible:[box-shadow:none] disabled:cursor-not-allowed disabled:opacity-50 disabled:focus-visible:border-border disabled:focus-visible:[box-shadow:none] data-[size=default]:h-8 data-[size=lg]:h-10 data-[size=sm]:h-7",l),...n})}},55242,e=>{"use strict";e.s(["AppDialog",()=>i]);var a=e.i(18050),t=e.i(71645),l=e.i(76639),s=e.i(75157);function i(e){let{open:i,onOpenChange:n,title:r,children:o,footer:c,width:d="max-w-3xl",minHeight:u}=e,x=(0,t.useId)();return(0,a.jsx)(l.Dialog,{open:i,onOpenChange:n,children:(0,a.jsxs)(l.DialogContent,{"aria-labelledby":x,className:(0,s.cn)(d,u?"!min-h-[--min-h]":""),style:u?{"--min-h":u}:void 0,children:[(0,a.jsxs)(l.DialogHeader,{children:[(0,a.jsx)(l.DialogTitle,{id:x,children:r}),(0,a.jsx)(l.DialogClose,{"aria-label":"关闭"})]}),(0,a.jsx)(l.DialogBody,{className:"!px-4 !py-3",children:o}),c?(0,a.jsx)("div",{className:"flex flex-shrink-0 justify-end gap-2 border-t border-[var(--ds-border)] bg-[var(--ds-sidebar)] px-4 py-3",children:c}):null]})})}},47079,e=>{"use strict";e.s(["SkillsManageView",()=>I],47079);var a=e.i(18050),t=e.i(71645),l=e.i(65934),s=e.i(87243),i=e.i(13354),n=e.i(50711),r=e.i(51419),o=e.i(92715),c=e.i(19455),d=e.i(94055),u=e.i(94197),x=e.i(72064),p=e.i(93479),m=e.i(75157);function b(e){let{className:t,...l}=e;return(0,a.jsx)("nav",{role:"navigation","aria-label":"pagination","data-slot":"pagination",className:(0,m.cn)("flex w-full justify-end",t),...l})}let h=t.forwardRef((e,t)=>{let{className:l,...s}=e;return(0,a.jsx)("ul",{ref:t,"data-slot":"pagination-content",className:(0,m.cn)("flex flex-row flex-wrap items-center justify-end gap-1",l),...s})});h.displayName="PaginationContent";let g=t.forwardRef((e,t)=>{let{className:l,...s}=e;return(0,a.jsx)("li",{ref:t,"data-slot":"pagination-item",className:(0,m.cn)("",l),...s})});g.displayName="PaginationItem",t.forwardRef((e,t)=>{let{className:l,isActive:s,size:i="icon",...n}=e;return(0,a.jsx)("a",{ref:t,"aria-current":s?"page":void 0,"data-slot":"pagination-link","data-active":s?"true":void 0,className:(0,m.cn)((0,c.buttonVariants)({variant:s?"outline":"ghost",size:i}),l),...n})}).displayName="PaginationLink";var f=e.i(62427);function v(e){let{active:l,wsUrl:s,apiBase:n,agent:r,onAfterInstall:d,className:u}=e,[m,v]=(0,t.useState)(""),[y,k]=(0,t.useState)(1),[j,C]=(0,t.useState)(0),[N,w]=(0,t.useState)([]),[S,T]=(0,t.useState)(!1),[A,B]=(0,t.useState)(""),[I,z]=(0,t.useState)({}),R=(0,t.useRef)(0),E=(0,t.useCallback)(async()=>{let e=++R.current;T(!0),B("");try{let a=await (0,f.listCloudSkillCatalog)(s,n,r,m,y,10);if(e!==R.current)return;let t=Array.isArray(a.items)?a.items:[],l=[];for(let e of t)e&&"object"==typeof e&&e.id&&l.push({id:String(e.id),title:String(e.title||""),skillName:String(e.skillName||""),description:"string"==typeof e.description?e.description:"",installed:!!e.installed});w(l),C(a.totalPages)}catch(a){if(e!==R.current)return;w([]),C(0),B(a instanceof Error?a.message:String(a))}finally{e===R.current&&T(!1)}},[s,n,r,m,y]);(0,t.useEffect)(()=>{if(!l){v(""),k(1),C(0),w([]),B(""),z({}),R.current+=1;return}E()},[l,E]);let P=(0,t.useMemo)(()=>{if(S)return"加载中…";if(A)return"加载失败:".concat(A);let e=N.reduce((e,a)=>e+ +!!a.installed,0);return"已安装 ".concat(e," 项")},[S,A,N]),L=(0,t.useCallback)(async(e,a)=>{z(a=>({...a,[e]:!0}));try{await (0,f.installCloudSkill)(s,n,r,e),i.appToast.success("云端技能已安装:".concat(a)),await E(),null==d||d()}catch(e){i.appToast.error("安装失败:".concat(e instanceof Error?e.message:String(e)))}finally{z(a=>{let t={...a};return delete t[e],t})}},[s,n,r,E,d]),D=(0,t.useCallback)(e=>{k(1),v(e)},[]);if(!l)return null;let M=j>0?"第 ".concat(y,"/").concat(j," 页"):"第 0/0 页",U=S||y<=1,K=S||j<=0||y>=j,O=[{key:"name",title:"名称",headerClassName:"text-base",cellClassName:"text-base text-[var(--ds-text)]",render:e=>e.skillName?"".concat(e.skillName):e.id},{key:"description",title:"详情",headerClassName:"text-base",cellClassName:"text-base text-[var(--ds-text)]",render:e=>(0,a.jsxs)(a.Fragment,{children:[e.title,e.description?" — ".concat(e.description):""]})},{key:"status",title:"状态",headerClassName:"text-base",cellClassName:"whitespace-nowrap text-base text-[var(--ds-text)]",render:e=>e.installed?"已安装":"未安装"},{key:"actions",title:"操作",headerClassName:"w-[96px] text-right text-base",cellClassName:"w-[116px] text-right",render:e=>{let t=!!I[e.id],l=!!e.installed;return!t&&l?"-":(0,a.jsx)(c.Button,{type:"button",size:"sm",variant:"outline",disabled:t||l,onClick:()=>void L(e.id,e.title||e.skillName||e.id),children:t?"安装中…":l?"已安装":"安装"})}}];return(0,a.jsx)("div",{className:u,children:(0,a.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,a.jsx)(p.Input,{type:"search",value:m,onChange:e=>D(e.target.value),placeholder:"搜索云端技能…",className:"h-10 border-[var(--ds-border)] bg-[var(--ds-bg)] text-base"}),(0,a.jsx)("div",{className:"text-sm text-[var(--ds-muted)]",children:P}),(0,a.jsx)(o.AppTable,{rows:N,columns:O,getRowKey:e=>e.id,className:"min-h-0 flex-1 rounded-md",bodyProps:{viewportPaginationReserve:64},emptyNode:S?(0,a.jsx)("p",{className:"text-center text-base",children:"加载中…"}):void 0}),(0,a.jsx)(b,{className:"mx-0 w-full",children:(0,a.jsxs)(h,{className:"w-full flex-wrap justify-end gap-2",children:[(0,a.jsx)(g,{children:(0,a.jsxs)(c.Button,{type:"button",variant:"outline",size:"sm",disabled:U,className:"gap-1",onClick:()=>k(e=>Math.max(1,e-1)),"aria-label":"上一页",children:[(0,a.jsx)(x.default,{name:"ChevronLeft",size:16,className:"shrink-0"}),"上一页"]})}),(0,a.jsx)(g,{children:(0,a.jsx)("span",{className:"flex h-9 min-w-[6.5rem] items-center justify-center text-sm text-[var(--ds-muted)]",children:M})}),(0,a.jsx)(g,{children:(0,a.jsxs)(c.Button,{type:"button",variant:"outline",size:"sm",disabled:K,className:"gap-1",onClick:()=>k(e=>e+1),"aria-label":"下一页",children:["下一页",(0,a.jsx)(x.default,{name:"ChevronRight",size:16,className:"shrink-0",strokeWidth:1})]})})]})})]})})}var y=e.i(36845),k=e.i(53925);function j(e){let{open:t,onOpenChange:l,wsUrl:s,apiBase:i,agent:n}=e;return(0,a.jsx)(k.ResourceImportDialog,{open:t,onOpenChange:l,title:"导入 Skill zip",description:"选择一个 zip 文件并导入到 skills-runtime。",uploadUrl:(0,y.buildSkillsRuntimeImportUrl)(s,i,n),resetKey:n})}var C=e.i(55242);function N(e){let{open:l,onOpenChange:s,skillName:n,wsUrl:r,apiBase:o,agent:d,onSaved:u}=e,[x,p]=(0,t.useState)(""),[m,b]=(0,t.useState)(!1),[h,g]=(0,t.useState)(!1);(0,t.useEffect)(()=>{if(!l||!n.trim())return;let e=!1;return b(!0),p(""),(0,f.loadBaseSkillMd)(r,o,d,n).then(a=>{e||p("string"==typeof a.content?a.content:"")}).catch(a=>{e||(i.appToast.error("加载 SKILL.md 失败:".concat(a instanceof Error?a.message:String(a))),s(!1))}).finally(()=>{e||b(!1)}),()=>{e=!0}},[l,n,r,o,d,s]);let v=(0,t.useCallback)(async()=>{if(n.trim()){g(!0);try{await (0,f.saveBaseSkillMd)(r,o,d,n,x),i.appToast.success("SKILL.md 已保存"),s(!1),null==u||u()}catch(e){i.appToast.error("保存失败:".concat(e instanceof Error?e.message:String(e)))}finally{g(!1)}}},[n,r,o,d,x,s,u]);return(0,a.jsx)(C.AppDialog,{open:l,onOpenChange:s,title:"编辑 SKILL.md · /".concat(n),width:"max-w-4xl",minHeight:"420px",footer:(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(c.Button,{type:"button",variant:"plain-outline",size:"lg",disabled:m||h,onClick:()=>s(!1),children:"取消"}),(0,a.jsx)(c.Button,{type:"button",size:"lg",disabled:m||h,onClick:()=>void v(),children:"保存"})]}),children:m?(0,a.jsx)("p",{className:"py-6 text-center text-base text-[var(--ds-muted)]",children:"加载中…"}):(0,a.jsx)("textarea",{className:"focus-visible:ring-[var(--ds-accent)]/30 min-h-[320px] w-full resize-y rounded-md border border-[var(--ds-border)] bg-[var(--ds-bg)] p-3 text-base leading-6 text-[var(--ds-text)] outline-none focus-visible:ring-2",spellCheck:!1,value:x,placeholder:"Markdown 源码…",onChange:e=>p(e.target.value)})})}function w(e){let{items:t,saveBusy:l,onToggleEnabled:s,onExport:i,onRemove:n,className:r}=e,c=[{key:"name",title:"名称",headerClassName:"text-base",cellClassName:"text-base",render:e=>"/".concat(e.name)},{key:"description",title:"详情",headerClassName:"text-base",cellClassName:"text-base",render:e=>e.description||"-"},{key:"status",title:"状态",headerClassName:"w-[160px] text-base",cellClassName:"w-[160px] text-base text-[var(--ds-text)]",render:()=>"已安装"},{key:"enabled",title:"启用/未启用",headerClassName:"w-[160px] text-right text-base",cellClassName:"w-[160px] py-2 text-right align-middle",render:e=>(0,a.jsx)("span",{className:"inline-flex items-center justify-end gap-2",children:(0,a.jsx)(d.AccentSwitch,{checked:e.enabled,disabled:l,onCheckedChange:a=>s(e.name,a),"aria-label":"".concat(e.enabled?"禁用":"启用"," ").concat(e.name)})})},{key:"actions",title:"操作",headerClassName:"w-[128px] text-base",cellClassName:"w-[128px]",render:e=>(0,a.jsxs)("div",{className:"inline-flex items-center justify-end gap-1",children:[(0,a.jsx)(u.IconTooltipButton,{icon:"Download",label:"导出",ariaLabel:"导出 ".concat(e.name),disabled:l,onClick:()=>i(e.name)}),(0,a.jsx)(u.IconTooltipButton,{icon:"Trash2",label:"删除",tone:"danger",ariaLabel:"删除 ".concat(e.name),disabled:l,onClick:()=>{n(e.name)}})]})}];return(0,a.jsx)(o.AppTable,{rows:t,columns:c,getRowKey:e=>"skills:".concat(e.name),className:r})}var S=e.i(68499),T=e.i(56708);function A(e,a){var t,l,s;let i=(s=null!=(l=null!=(t=e.description)?t:e.whenToUse)?l:"")?s.length>100?s.slice(0,100):s:"";return{...e,id:e.name,label:"/".concat(e.name),description:i,isRuntime:a,canManage:e.canManage}}let B=[{value:"basic",label:"基础Skill"},{value:"installed",label:"已安装Skill"},{value:"cloud_catalog",label:"Skill商店"}];function I(){let e=(0,l.useAppStore)(e=>e.wsUrl),p=(0,l.useAppStore)(e=>e.apiBase),m=(0,l.useAppStore)(e=>e.agentConfig),b=(0,l.useAppStore)(e=>e.patchAgentConfig),{currentAgent:h,loadAgentConfig:g}=(0,s.useSession)(),y=(0,n.usePersistAgentConfigField)("skills"),k=m.skills,C=(0,t.useMemo)(()=>[...k].sort().join("\0"),[k]),[I,z]=(0,t.useState)([]),[R,E]=(0,t.useState)([]),[P,L]=(0,t.useState)([]),[D,M]=(0,t.useState)(!1),[U,K]=(0,t.useState)(!1),[O,F]=(0,t.useState)(!1),[_,H]=(0,t.useState)("basic"),[V,W]=(0,t.useState)(!1),[q,G]=(0,t.useState)(""),[J,Q]=(0,t.useState)(!1);(0,t.useEffect)(()=>{g()},[g]);let X=(0,t.useCallback)(async(e,a)=>{F(!0);try{await y(e,{silent:a})}finally{F(!1)}},[y]),Y=(0,t.useCallback)(async()=>{z([]),M(!0);try{var a;let t=await (0,f.listBaseSkills)(e,p,h());z((null!=(a=t.skills)?a:[]).map(e=>A(e,!1)))}catch(e){z([]),i.appToast.error("加载失败:".concat(e instanceof Error?e.message:String(e)))}finally{M(!1)}},[e,p,h]),Z=(0,t.useCallback)(async()=>{E([]),K(!0);try{var a;let t=await (0,f.listInstalledSkills)(e,p,h());E((null!=(a=t.skills)?a:[]).map(e=>A(e,!0)))}catch(e){E([]),i.appToast.error("加载失败:".concat(e instanceof Error?e.message:String(e)))}finally{K(!1)}},[e,p,h]),$=(0,t.useCallback)(async()=>{await Promise.all([Y(),Z()])},[Y,Z]),ee=(0,t.useCallback)(async a=>{if(await (0,S.confirmAlertDialog)({title:"确认删除 Skill 包?",description:"Skill:".concat(a),confirmText:"删除",cancelText:"取消"}))try{await (0,f.deleteRuntimeSkill)(e,p,h(),a);let t=k.filter(e=>e!==a);L(e=>e.filter(e=>e!==a)),b({skills:t}),await X(t,!0),await $()}catch(e){i.appToast.error("删除失败:".concat(e instanceof Error?e.message:String(e)))}},[e,p,h,k,b,X,$]);(0,t.useEffect)(()=>{"basic"===_&&Y(),"installed"===_&&Z()},[_,Y,Z]);let ea=(0,t.useCallback)(()=>{$()},[$]);(0,t.useEffect)(()=>{"basic"===_&&L([...k])},[_,k,C]);let et=(0,t.useCallback)(e=>{let a=[...new Set(e)].sort();b({skills:a}),X(a,!0)},[b,X]),el=(0,t.useMemo)(()=>R.slice().sort((e,a)=>e.label.localeCompare(a.label)).map(e=>({name:e.id,installed:!0,description:e.description||"",enabled:k.includes(e.id)})),[R,k]),es=(0,t.useCallback)((e,a)=>{let t=a?[...new Set([...k,e])].sort():k.filter(a=>a!==e);b({skills:t}),L(t),X(t,!0)},[k,b,X]),ei=(0,t.useCallback)(a=>{window.open((0,f.exportRuntimeSkillUrl)(e,p,h(),a),"_blank","noopener")},[e,p,h]),en=(0,t.useCallback)(e=>{G(e.id),Q(!0)},[]),er=[{key:"name",title:"名称",headerClassName:"text-base text-[var(--ds-muted)]",cellClassName:"text-base text-[var(--ds-text)]",render:e=>e.label},{key:"description",title:"详情",headerClassName:"text-base text-[var(--ds-muted)]",cellClassName:"text-base text-[var(--ds-text)]",render:e=>e.description||"-"},{key:"enabled",title:"启用/未启用",headerClassName:"w-[102px] text-right text-base text-[var(--ds-muted)]",cellClassName:"w-[102px] py-2 text-right align-middle",render:e=>(0,a.jsx)("span",{className:"inline-flex justify-end",children:(0,a.jsx)(d.AccentSwitch,{checked:P.includes(e.id),disabled:O,onCheckedChange:a=>{let t=a?[...new Set([...P,e.id])]:P.filter(a=>a!==e.id);L(t),et(t)},"aria-label":"选择 ".concat(e.label)})})},{key:"actions",title:"操作",headerClassName:"w-[104px] text-right text-base text-[var(--ds-muted)]",cellClassName:"w-[104px] py-2 text-right align-middle",render:e=>(0,a.jsxs)("span",{className:"inline-flex justify-end gap-1",children:[(0,a.jsx)(u.IconTooltipButton,{icon:"Edit",label:"编辑",disabled:O,ariaLabel:"编辑 ".concat(e.label),onClick:()=>en(e)}),(0,a.jsx)(u.IconTooltipButton,{icon:"Trash2",label:"系统技能不可删除",tone:"danger",disabled:!0,ariaLabel:"删除 ".concat(e.label)})]})}];return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(T.ManageChromeHeaderActions,{children:(0,a.jsxs)(c.Button,{id:"btnAgentImportSkill",type:"button",variant:"plain-outline",size:"lg",className:"inline-flex items-center justify-center gap-1.5",onClick:()=>W(!0),children:[(0,a.jsx)(x.default,{name:"Import",size:16,className:"align-middle"}),"导入Skill"]})}),(0,a.jsxs)(r.AppTabs,{tabs:B,value:_,listVariant:"line",onChange:e=>H(e),children:[(0,a.jsx)(r.AppTabsPanel,{value:"basic",children:(0,a.jsx)("div",{className:"flex min-h-0 flex-1 flex-col gap-3",children:(0,a.jsx)("div",{className:"min-h-0",children:D?(0,a.jsx)("p",{className:"px-3 py-6 text-center text-base text-[var(--ds-muted)]",children:"加载中…"}):(0,a.jsx)(o.AppTable,{rows:I,columns:er,getRowKey:e=>e.id})})})}),(0,a.jsx)(r.AppTabsPanel,{value:"installed",children:U?(0,a.jsx)("p",{className:"px-3 py-6 text-center text-base text-[var(--ds-muted)]",children:"加载中…"}):(0,a.jsx)(w,{items:el,saveBusy:O,onToggleEnabled:es,onExport:ei,onRemove:ee})}),(0,a.jsx)(r.AppTabsPanel,{value:"cloud_catalog",className:"flex min-h-0 flex-1 flex-col",children:(0,a.jsx)(v,{active:"cloud_catalog"===_,wsUrl:e,apiBase:p,agent:h(),onAfterInstall:ea,className:"min-h-0 flex-1"})})]}),(0,a.jsx)(j,{open:V,onOpenChange:e=>{W(e),e||$()},wsUrl:e,apiBase:p,agent:h()}),(0,a.jsx)(N,{open:J,onOpenChange:Q,skillName:q,wsUrl:e,apiBase:p,agent:h(),onSaved:()=>void $()})]})}}]);
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,93479,e=>{"use strict";e.s(["Input",()=>l]);var a=e.i(18050),t=e.i(75157);function l(e){let{className:l,type:s="text",size:i="default",...n}=e;return(0,a.jsx)("input",{type:s,"data-slot":"input","data-size":i,className:(0,t.cn)("h-9 w-full appearance-none rounded-md border border-solid border-border bg-transparent px-3 text-base outline-none transition-[color,box-shadow,border-color] duration-150 ease-in-out placeholder:text-muted-foreground hover:border-[#e0e0e0] focus-visible:border-[var(--border-focus)] focus-visible:[box-shadow:var(--ring-focus-sm)] read-only:focus-visible:border-border read-only:focus-visible:[box-shadow:none] disabled:cursor-not-allowed disabled:opacity-50 disabled:focus-visible:border-border disabled:focus-visible:[box-shadow:none] data-[size=default]:h-9 data-[size=lg]:h-10 data-[size=sm]:h-7",l),...n})}},55242,e=>{"use strict";e.s(["AppDialog",()=>i]);var a=e.i(18050),t=e.i(71645),l=e.i(76639),s=e.i(75157);function i(e){let{open:i,onOpenChange:n,title:r,children:o,footer:c,width:d="max-w-3xl",minHeight:u}=e,x=(0,t.useId)();return(0,a.jsx)(l.Dialog,{open:i,onOpenChange:n,children:(0,a.jsxs)(l.DialogContent,{"aria-labelledby":x,className:(0,s.cn)(d,u?"!min-h-[--min-h]":""),style:u?{"--min-h":u}:void 0,children:[(0,a.jsxs)(l.DialogHeader,{children:[(0,a.jsx)(l.DialogTitle,{id:x,children:r}),(0,a.jsx)(l.DialogClose,{"aria-label":"关闭"})]}),(0,a.jsx)(l.DialogBody,{className:"!px-4 !py-3",children:o}),c?(0,a.jsx)("div",{className:"flex flex-shrink-0 justify-end gap-2 border-t border-[var(--ds-border)] bg-[var(--ds-sidebar)] px-4 py-3",children:c}):null]})})}},47079,e=>{"use strict";e.s(["SkillsManageView",()=>I],47079);var a=e.i(18050),t=e.i(71645),l=e.i(65934),s=e.i(87243),i=e.i(13354),n=e.i(50711),r=e.i(51419),o=e.i(92715),c=e.i(19455),d=e.i(94055),u=e.i(94197),x=e.i(72064),p=e.i(93479),m=e.i(75157);function b(e){let{className:t,...l}=e;return(0,a.jsx)("nav",{role:"navigation","aria-label":"pagination","data-slot":"pagination",className:(0,m.cn)("flex w-full justify-end",t),...l})}let h=t.forwardRef((e,t)=>{let{className:l,...s}=e;return(0,a.jsx)("ul",{ref:t,"data-slot":"pagination-content",className:(0,m.cn)("flex flex-row flex-wrap items-center justify-end gap-1",l),...s})});h.displayName="PaginationContent";let g=t.forwardRef((e,t)=>{let{className:l,...s}=e;return(0,a.jsx)("li",{ref:t,"data-slot":"pagination-item",className:(0,m.cn)("",l),...s})});g.displayName="PaginationItem",t.forwardRef((e,t)=>{let{className:l,isActive:s,size:i="icon",...n}=e;return(0,a.jsx)("a",{ref:t,"aria-current":s?"page":void 0,"data-slot":"pagination-link","data-active":s?"true":void 0,className:(0,m.cn)((0,c.buttonVariants)({variant:s?"outline":"ghost",size:i}),l),...n})}).displayName="PaginationLink";var f=e.i(62427);function v(e){let{active:l,wsUrl:s,apiBase:n,agent:r,onAfterInstall:d,className:u}=e,[m,v]=(0,t.useState)(""),[y,k]=(0,t.useState)(1),[j,C]=(0,t.useState)(0),[N,w]=(0,t.useState)([]),[S,T]=(0,t.useState)(!1),[A,B]=(0,t.useState)(""),[I,z]=(0,t.useState)({}),R=(0,t.useRef)(0),E=(0,t.useCallback)(async()=>{let e=++R.current;T(!0),B("");try{let a=await (0,f.listCloudSkillCatalog)(s,n,r,m,y,10);if(e!==R.current)return;let t=Array.isArray(a.items)?a.items:[],l=[];for(let e of t)e&&"object"==typeof e&&e.id&&l.push({id:String(e.id),title:String(e.title||""),skillName:String(e.skillName||""),description:"string"==typeof e.description?e.description:"",installed:!!e.installed});w(l),C(a.totalPages)}catch(a){if(e!==R.current)return;w([]),C(0),B(a instanceof Error?a.message:String(a))}finally{e===R.current&&T(!1)}},[s,n,r,m,y]);(0,t.useEffect)(()=>{if(!l){v(""),k(1),C(0),w([]),B(""),z({}),R.current+=1;return}E()},[l,E]);let P=(0,t.useMemo)(()=>{if(S)return"加载中…";if(A)return"加载失败:".concat(A);let e=N.reduce((e,a)=>e+ +!!a.installed,0);return"已安装 ".concat(e," 项")},[S,A,N]),L=(0,t.useCallback)(async(e,a)=>{z(a=>({...a,[e]:!0}));try{await (0,f.installCloudSkill)(s,n,r,e),i.appToast.success("云端技能已安装:".concat(a)),await E(),null==d||d()}catch(e){i.appToast.error("安装失败:".concat(e instanceof Error?e.message:String(e)))}finally{z(a=>{let t={...a};return delete t[e],t})}},[s,n,r,E,d]),D=(0,t.useCallback)(e=>{k(1),v(e)},[]);if(!l)return null;let M=j>0?"第 ".concat(y,"/").concat(j," 页"):"第 0/0 页",U=S||y<=1,K=S||j<=0||y>=j,O=[{key:"name",title:"名称",headerClassName:"text-base",cellClassName:"text-base text-[var(--ds-text)]",render:e=>e.skillName?"".concat(e.skillName):e.id},{key:"description",title:"详情",headerClassName:"text-base",cellClassName:"text-base text-[var(--ds-text)]",render:e=>(0,a.jsxs)(a.Fragment,{children:[e.title,e.description?" — ".concat(e.description):""]})},{key:"status",title:"状态",headerClassName:"text-base",cellClassName:"whitespace-nowrap text-base text-[var(--ds-text)]",render:e=>e.installed?"已安装":"未安装"},{key:"actions",title:"操作",headerClassName:"w-[96px] text-right text-base",cellClassName:"w-[116px] text-right",render:e=>{let t=!!I[e.id],l=!!e.installed;return!t&&l?"-":(0,a.jsx)(c.Button,{type:"button",size:"sm",variant:"outline",disabled:t||l,onClick:()=>void L(e.id,e.title||e.skillName||e.id),children:t?"安装中…":l?"已安装":"安装"})}}];return(0,a.jsx)("div",{className:u,children:(0,a.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,a.jsx)(p.Input,{type:"search",value:m,onChange:e=>D(e.target.value),placeholder:"搜索云端技能…",className:"h-10 border-[var(--ds-border)] bg-[var(--ds-bg)] text-base"}),(0,a.jsx)("div",{className:"text-sm text-[var(--ds-muted)]",children:P}),(0,a.jsx)(o.AppTable,{rows:N,columns:O,getRowKey:e=>e.id,className:"min-h-0 flex-1 rounded-md",bodyProps:{viewportPaginationReserve:64},emptyNode:S?(0,a.jsx)("p",{className:"text-center text-base",children:"加载中…"}):void 0}),(0,a.jsx)(b,{className:"mx-0 w-full",children:(0,a.jsxs)(h,{className:"w-full flex-wrap justify-end gap-2",children:[(0,a.jsx)(g,{children:(0,a.jsxs)(c.Button,{type:"button",variant:"outline",size:"sm",disabled:U,className:"gap-1",onClick:()=>k(e=>Math.max(1,e-1)),"aria-label":"上一页",children:[(0,a.jsx)(x.default,{name:"ChevronLeft",size:16,className:"shrink-0"}),"上一页"]})}),(0,a.jsx)(g,{children:(0,a.jsx)("span",{className:"flex h-9 min-w-[6.5rem] items-center justify-center text-sm text-[var(--ds-muted)]",children:M})}),(0,a.jsx)(g,{children:(0,a.jsxs)(c.Button,{type:"button",variant:"outline",size:"sm",disabled:K,className:"gap-1",onClick:()=>k(e=>e+1),"aria-label":"下一页",children:["下一页",(0,a.jsx)(x.default,{name:"ChevronRight",size:16,className:"shrink-0",strokeWidth:1})]})})]})})]})})}var y=e.i(36845),k=e.i(53925);function j(e){let{open:t,onOpenChange:l,wsUrl:s,apiBase:i,agent:n}=e;return(0,a.jsx)(k.ResourceImportDialog,{open:t,onOpenChange:l,title:"导入 Skill zip",description:"选择一个 zip 文件并导入到 skills-runtime。",uploadUrl:(0,y.buildSkillsRuntimeImportUrl)(s,i,n),resetKey:n})}var C=e.i(55242);function N(e){let{open:l,onOpenChange:s,skillName:n,wsUrl:r,apiBase:o,agent:d,onSaved:u}=e,[x,p]=(0,t.useState)(""),[m,b]=(0,t.useState)(!1),[h,g]=(0,t.useState)(!1);(0,t.useEffect)(()=>{if(!l||!n.trim())return;let e=!1;return b(!0),p(""),(0,f.loadBaseSkillMd)(r,o,d,n).then(a=>{e||p("string"==typeof a.content?a.content:"")}).catch(a=>{e||(i.appToast.error("加载 SKILL.md 失败:".concat(a instanceof Error?a.message:String(a))),s(!1))}).finally(()=>{e||b(!1)}),()=>{e=!0}},[l,n,r,o,d,s]);let v=(0,t.useCallback)(async()=>{if(n.trim()){g(!0);try{await (0,f.saveBaseSkillMd)(r,o,d,n,x),i.appToast.success("SKILL.md 已保存"),s(!1),null==u||u()}catch(e){i.appToast.error("保存失败:".concat(e instanceof Error?e.message:String(e)))}finally{g(!1)}}},[n,r,o,d,x,s,u]);return(0,a.jsx)(C.AppDialog,{open:l,onOpenChange:s,title:"编辑 SKILL.md · /".concat(n),width:"max-w-4xl",minHeight:"420px",footer:(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(c.Button,{type:"button",variant:"plain-outline",size:"lg",disabled:m||h,onClick:()=>s(!1),children:"取消"}),(0,a.jsx)(c.Button,{type:"button",size:"lg",disabled:m||h,onClick:()=>void v(),children:"保存"})]}),children:m?(0,a.jsx)("p",{className:"py-6 text-center text-base text-[var(--ds-muted)]",children:"加载中…"}):(0,a.jsx)("textarea",{className:"focus-visible:ring-[var(--ds-accent)]/30 min-h-[320px] w-full resize-y rounded-md border border-[var(--ds-border)] bg-[var(--ds-bg)] p-3 text-base leading-6 text-[var(--ds-text)] outline-none focus-visible:ring-2",spellCheck:!1,value:x,placeholder:"Markdown 源码…",onChange:e=>p(e.target.value)})})}function w(e){let{items:t,saveBusy:l,onToggleEnabled:s,onExport:i,onRemove:n,className:r}=e,c=[{key:"name",title:"名称",headerClassName:"text-base",cellClassName:"text-base",render:e=>"/".concat(e.name)},{key:"description",title:"详情",headerClassName:"text-base",cellClassName:"text-base",render:e=>e.description||"-"},{key:"status",title:"状态",headerClassName:"w-[160px] text-base",cellClassName:"w-[160px] text-base text-[var(--ds-text)]",render:()=>"已安装"},{key:"enabled",title:"启用/未启用",headerClassName:"w-[160px] text-right text-base",cellClassName:"w-[160px] py-2 text-right align-middle",render:e=>(0,a.jsx)("span",{className:"inline-flex items-center justify-end gap-2",children:(0,a.jsx)(d.AccentSwitch,{checked:e.enabled,disabled:l,onCheckedChange:a=>s(e.name,a),"aria-label":"".concat(e.enabled?"禁用":"启用"," ").concat(e.name)})})},{key:"actions",title:"操作",headerClassName:"w-[128px] text-base",cellClassName:"w-[128px]",render:e=>(0,a.jsxs)("div",{className:"inline-flex items-center justify-end gap-1",children:[(0,a.jsx)(u.IconTooltipButton,{icon:"Download",label:"导出",ariaLabel:"导出 ".concat(e.name),disabled:l,onClick:()=>i(e.name)}),(0,a.jsx)(u.IconTooltipButton,{icon:"Trash2",label:"删除",tone:"danger",ariaLabel:"删除 ".concat(e.name),disabled:l,onClick:()=>{n(e.name)}})]})}];return(0,a.jsx)(o.AppTable,{rows:t,columns:c,getRowKey:e=>"skills:".concat(e.name),className:r})}var S=e.i(68499),T=e.i(56708);function A(e,a){var t,l,s;let i=(s=null!=(l=null!=(t=e.description)?t:e.whenToUse)?l:"")?s.length>100?s.slice(0,100):s:"";return{...e,id:e.name,label:"/".concat(e.name),description:i,isRuntime:a,canManage:e.canManage}}let B=[{value:"basic",label:"基础Skill"},{value:"installed",label:"已安装Skill"},{value:"cloud_catalog",label:"Skill商店"}];function I(){let e=(0,l.useAppStore)(e=>e.wsUrl),p=(0,l.useAppStore)(e=>e.apiBase),m=(0,l.useAppStore)(e=>e.agentConfig),b=(0,l.useAppStore)(e=>e.patchAgentConfig),{currentAgent:h,loadAgentConfig:g}=(0,s.useSession)(),y=(0,n.usePersistAgentConfigField)("skills"),k=m.skills,C=(0,t.useMemo)(()=>[...k].sort().join("\0"),[k]),[I,z]=(0,t.useState)([]),[R,E]=(0,t.useState)([]),[P,L]=(0,t.useState)([]),[D,M]=(0,t.useState)(!1),[U,K]=(0,t.useState)(!1),[O,F]=(0,t.useState)(!1),[_,H]=(0,t.useState)("basic"),[V,W]=(0,t.useState)(!1),[q,G]=(0,t.useState)(""),[J,Q]=(0,t.useState)(!1);(0,t.useEffect)(()=>{g()},[g]);let X=(0,t.useCallback)(async(e,a)=>{F(!0);try{await y(e,{silent:a})}finally{F(!1)}},[y]),Y=(0,t.useCallback)(async()=>{z([]),M(!0);try{var a;let t=await (0,f.listBaseSkills)(e,p,h());z((null!=(a=t.skills)?a:[]).map(e=>A(e,!1)))}catch(e){z([]),i.appToast.error("加载失败:".concat(e instanceof Error?e.message:String(e)))}finally{M(!1)}},[e,p,h]),Z=(0,t.useCallback)(async()=>{E([]),K(!0);try{var a;let t=await (0,f.listInstalledSkills)(e,p,h());E((null!=(a=t.skills)?a:[]).map(e=>A(e,!0)))}catch(e){E([]),i.appToast.error("加载失败:".concat(e instanceof Error?e.message:String(e)))}finally{K(!1)}},[e,p,h]),$=(0,t.useCallback)(async()=>{await Promise.all([Y(),Z()])},[Y,Z]),ee=(0,t.useCallback)(async a=>{if(await (0,S.confirmAlertDialog)({title:"确认删除 Skill 包?",description:"Skill:".concat(a),confirmText:"删除",cancelText:"取消"}))try{await (0,f.deleteRuntimeSkill)(e,p,h(),a);let t=k.filter(e=>e!==a);L(e=>e.filter(e=>e!==a)),b({skills:t}),await X(t,!0),await $()}catch(e){i.appToast.error("删除失败:".concat(e instanceof Error?e.message:String(e)))}},[e,p,h,k,b,X,$]);(0,t.useEffect)(()=>{"basic"===_&&Y(),"installed"===_&&Z()},[_,Y,Z]);let ea=(0,t.useCallback)(()=>{$()},[$]);(0,t.useEffect)(()=>{"basic"===_&&L([...k])},[_,k,C]);let et=(0,t.useCallback)(e=>{let a=[...new Set(e)].sort();b({skills:a}),X(a,!0)},[b,X]),el=(0,t.useMemo)(()=>R.slice().sort((e,a)=>e.label.localeCompare(a.label)).map(e=>({name:e.id,installed:!0,description:e.description||"",enabled:k.includes(e.id)})),[R,k]),es=(0,t.useCallback)((e,a)=>{let t=a?[...new Set([...k,e])].sort():k.filter(a=>a!==e);b({skills:t}),L(t),X(t,!0)},[k,b,X]),ei=(0,t.useCallback)(a=>{window.open((0,f.exportRuntimeSkillUrl)(e,p,h(),a),"_blank","noopener")},[e,p,h]),en=(0,t.useCallback)(e=>{G(e.id),Q(!0)},[]),er=[{key:"name",title:"名称",headerClassName:"text-base text-[var(--ds-muted)]",cellClassName:"text-base text-[var(--ds-text)]",render:e=>e.label},{key:"description",title:"详情",headerClassName:"text-base text-[var(--ds-muted)]",cellClassName:"text-base text-[var(--ds-text)]",render:e=>e.description||"-"},{key:"enabled",title:"启用/未启用",headerClassName:"w-[102px] text-right text-base text-[var(--ds-muted)]",cellClassName:"w-[102px] py-2 text-right align-middle",render:e=>(0,a.jsx)("span",{className:"inline-flex justify-end",children:(0,a.jsx)(d.AccentSwitch,{checked:P.includes(e.id),disabled:O,onCheckedChange:a=>{let t=a?[...new Set([...P,e.id])]:P.filter(a=>a!==e.id);L(t),et(t)},"aria-label":"选择 ".concat(e.label)})})},{key:"actions",title:"操作",headerClassName:"w-[104px] text-right text-base text-[var(--ds-muted)]",cellClassName:"w-[104px] py-2 text-right align-middle",render:e=>(0,a.jsxs)("span",{className:"inline-flex justify-end gap-1",children:[(0,a.jsx)(u.IconTooltipButton,{icon:"Edit",label:"编辑",disabled:O,ariaLabel:"编辑 ".concat(e.label),onClick:()=>en(e)}),(0,a.jsx)(u.IconTooltipButton,{icon:"Trash2",label:"系统技能不可删除",tone:"danger",disabled:!0,ariaLabel:"删除 ".concat(e.label)})]})}];return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(T.ManageChromeHeaderActions,{children:(0,a.jsxs)(c.Button,{id:"btnAgentImportSkill",type:"button",variant:"plain-outline",size:"lg",className:"inline-flex items-center justify-center gap-1.5",onClick:()=>W(!0),children:[(0,a.jsx)(x.default,{name:"Import",size:16,className:"align-middle"}),"导入Skill"]})}),(0,a.jsxs)(r.AppTabs,{tabs:B,value:_,listVariant:"line",onChange:e=>H(e),children:[(0,a.jsx)(r.AppTabsPanel,{value:"basic",children:(0,a.jsx)("div",{className:"flex min-h-0 flex-1 flex-col gap-3",children:(0,a.jsx)("div",{className:"min-h-0",children:D?(0,a.jsx)("p",{className:"px-3 py-6 text-center text-base text-[var(--ds-muted)]",children:"加载中…"}):(0,a.jsx)(o.AppTable,{rows:I,columns:er,getRowKey:e=>e.id})})})}),(0,a.jsx)(r.AppTabsPanel,{value:"installed",children:U?(0,a.jsx)("p",{className:"px-3 py-6 text-center text-base text-[var(--ds-muted)]",children:"加载中…"}):(0,a.jsx)(w,{items:el,saveBusy:O,onToggleEnabled:es,onExport:ei,onRemove:ee})}),(0,a.jsx)(r.AppTabsPanel,{value:"cloud_catalog",className:"flex min-h-0 flex-1 flex-col",children:(0,a.jsx)(v,{active:"cloud_catalog"===_,wsUrl:e,apiBase:p,agent:h(),onAfterInstall:ea,className:"min-h-0 flex-1"})})]}),(0,a.jsx)(j,{open:V,onOpenChange:e=>{W(e),e||$()},wsUrl:e,apiBase:p,agent:h()}),(0,a.jsx)(N,{open:J,onOpenChange:Q,skillName:q,wsUrl:e,apiBase:p,agent:h(),onSaved:()=>void $()})]})}}]);
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,18566,(e,t,n)=>{t.exports=e.r(76562)},85570,e=>{"use strict";e.s(["WorkspaceRuntimeContext",()=>n,"useWorkspaceRuntime",()=>r]);var t=e.i(71645);let n=(0,t.createContext)(null);function r(){let e=(0,t.useContext)(n);if(!e)throw Error("useWorkspaceRuntime must be used within WorkspaceShell");return e}},18253,e=>{"use strict";e.s(["useGuardedAppNavigation",()=>s]);var t=e.i(71645),n=e.i(18566),r=e.i(61196);function s(){let e=(0,n.useRouter)(),s=(0,r.useStageThreadFlyoutStore)(e=>e.confirmNavigateAway);return{push:(0,t.useCallback)(async t=>{await s(t)&&e.push(t)},[s,e]),router:e}}},67585,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"BailoutToCSR",{enumerable:!0,get:function(){return s}});let r=e.r(32061);function s(e){let{reason:t,children:n}=e;if("undefined"==typeof window)throw Object.defineProperty(new r.BailoutToCSRError(t),"__NEXT_ERROR_CODE",{value:"E394",enumerable:!1,configurable:!0});return n}},9885,(e,t,n)=>{"use strict";function r(e){return e.split("/").map(e=>encodeURIComponent(e)).join("/")}Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"encodeURIPath",{enumerable:!0,get:function(){return r}})},52157,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"PreloadChunks",{enumerable:!0,get:function(){return l}});let r=e.r(18050),s=e.r(74080),a=e.r(63599),i=e.r(9885);function l(e){let{moduleIds:t}=e;if("undefined"!=typeof window)return null;let n=a.workAsyncStorage.getStore();if(void 0===n)return null;let l=[];if(n.reactLoadableManifest&&t){let e=n.reactLoadableManifest;for(let n of t){if(!e[n])continue;let t=e[n].files;l.push(...t)}}return 0===l.length?null:(0,r.jsx)(r.Fragment,{children:l.map(e=>{let t=n.assetPrefix+"/_next/"+(0,i.encodeURIPath)(e);return e.endsWith(".css")?(0,r.jsx)("link",{precedence:"dynamic",href:t,rel:"stylesheet",as:"style"},e):((0,s.preload)(t,{as:"script",fetchPriority:"low"}),null)})})}},69093,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"default",{enumerable:!0,get:function(){return u}});let r=e.r(18050),s=e.r(71645),a=e.r(67585),i=e.r(52157);function l(e){return{default:e&&"default"in e?e.default:e}}let o={loader:()=>Promise.resolve(l(()=>null)),loading:null,ssr:!0},u=function(e){let t={...o,...e},n=(0,s.lazy)(()=>t.loader().then(l)),u=t.loading;function d(e){let l=u?(0,r.jsx)(u,{isLoading:!0,pastDelay:!0,error:null}):null,o=!t.ssr||!!t.loading,d=o?s.Suspense:s.Fragment,c=t.ssr?(0,r.jsxs)(r.Fragment,{children:["undefined"==typeof window?(0,r.jsx)(i.PreloadChunks,{moduleIds:t.modules}):null,(0,r.jsx)(n,{...e})]}):(0,r.jsx)(a.BailoutToCSR,{reason:"next/dynamic",children:(0,r.jsx)(n,{...e})});return(0,r.jsx)(d,{...o?{fallback:l}:{},children:c})}return d.displayName="LoadableComponent",d}},70703,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"default",{enumerable:!0,get:function(){return s}});let r=e.r(55682)._(e.r(69093));function s(e,t){var n;let s={};"function"==typeof e&&(s.loader=e);let a={...s,...t};return(0,r.default)({...a,modules:null==(n=a.loadableGenerated)?void 0:n.modules})}("function"==typeof n.default||"object"==typeof n.default&&null!==n.default)&&void 0===n.default.__esModule&&(Object.defineProperty(n.default,"__esModule",{value:!0}),Object.assign(n.default,n),t.exports=n.default)},82787,87968,e=>{"use strict";e.s(["MANAGE_DEFAULT_HREF",()=>f,"getBridgeSidebarManageRoutes",()=>m,"getManageRoute",()=>g,"isManageRouteEnabled",()=>h,"isManageSideNavPath",()=>v],82787);var t=e.i(70703),n=e.i(71645),r=e.i(18050);e.s(["Spinner",()=>i],87968);var s=e.i(72064),a=e.i(75157);function i(e){let{className:t}=e;return(0,r.jsx)(s.default,{name:"Loader2",size:16,className:(0,a.cn)("animate-spin text-muted-foreground",t)})}function l(e){let{className:t}=e;return(0,r.jsxs)("div",{className:(0,a.cn)("flex min-h-[40vh] flex-1 items-center justify-center gap-2 text-sm text-zinc-500",t),children:[(0,r.jsx)(i,{})," 加载中"]})}function o(){return(0,r.jsx)("div",{className:"flex min-h-0 min-w-0 flex-1 flex-col items-center justify-center text-[var(--ds-muted)]",children:"即将上线"})}var u=e.i(97249);function d(e){return(0,t.default)(e,{loading:()=>(0,n.createElement)(l)})}let c=[{key:"teams",slug:"teams",label:"agent / teams",title:"agent / teams 管理",description:"管理 Agent 团队与协作编排。",chrome:"feature",icon:"Teams",enabled:!0,visibleInNav:!1,headerIcon:"Agent2",visibleInBridgeSidebar:!0,Component:d(()=>e.A(2578).then(e=>({default:e.TeamsView})))},{key:"task",slug:"task",label:"定时任务",title:"定时任务",description:"管理计划执行的任务与触发记录。",chrome:"feature",icon:"Task",enabled:!0,headerIcon:"Calendar",visibleInNav:!1,visibleInBridgeSidebar:!0,Component:d(()=>e.A(94065).then(e=>({default:e.TaskView})))},{key:"add-account",slug:"add-account",label:"账户",title:"账户",description:"",chrome:"side-nav",icon:"Account",enabled:!0,visibleInNav:!0,children:[{key:"basic",slug:"basic",label:"基本信息",title:"基本信息",description:"",chrome:"side-nav",tabVariant:"pill",showTitle:!1,Component:d(()=>e.A(34116).then(e=>({default:e.AddAccountView})))}]},{key:"env",slug:"env",label:"服务商",title:"服务商",description:"管理 API 服务商以访问模型。",chrome:"side-nav",icon:"Server",enabled:!0,visibleInNav:!0,Component:d(()=>e.A(1861).then(e=>({default:e.EnvManageView})))},{key:"permissions",slug:"permissions",label:"权限",title:"权限",description:"管理平台访问权限与角色策略。",chrome:"side-nav",enabled:!1,visibleInNav:!1,Component:o},{key:"general",slug:"general",label:"通用",title:"通用",description:"平台通用配置与偏好设置。",chrome:"side-nav",enabled:!1,visibleInNav:!1,Component:o},{key:"mcp",slug:"mcp",label:"MCP",title:"MCP管理",description:"管理外部工具与数据源。可以导入、编辑、移除或禁用 MCP 服务。",chrome:"side-nav",icon:"Mcp",enabled:!0,visibleInNav:!0,Component:d(()=>e.A(18963).then(e=>({default:e.McpManageView})))},{key:"tools",slug:"tools",label:"工具",title:"工具管理",description:"管理当前 Agent 已挂载的工具列表",chrome:"side-nav",icon:"Tool",enabled:!0,visibleInNav:!0,Component:d(()=>e.A(9803).then(e=>({default:e.ToolsManageView})))},{key:"skills",slug:"skills",label:"技能",title:"技能管理",description:"管理当前 Agent 已挂载的技能",chrome:"side-nav",icon:"Skill",enabled:!0,visibleInNav:!0,Component:d(()=>e.A(69496).then(e=>({default:e.SkillsManageView})))},{key:"agent-teams",slug:"agent-teams",label:"agents",title:"Agent 团队管理",description:"管理当前 Agent 可调度的子 Agent 团队",chrome:"side-nav",icon:"Agent",enabled:!0,visibleInNav:!0,Component:d(()=>e.A(56149).then(e=>({default:e.AgentTeamsManageView})))},{key:"about",slug:"about",label:"关于",title:"关于",description:"版本信息与平台说明。",chrome:"side-nav",enabled:!0,visibleInNav:!1,Component:o}].map(e=>{var t,n;let{children:r,...s}=e;return{...s,href:(0,u.buildSettingsHref)(e.slug),...r?{children:(t=e.slug,n=e.chrome,r.map(e=>{var r,s;let a="".concat(t,"/").concat(e.slug);return{...e,slug:a,href:(0,u.buildSettingsHref)(a),chrome:null!=(r=e.chrome)?r:n,enabled:null==(s=e.enabled)||s,visibleInNav:!1}}))}:{}}});function p(e){return e.Component}let f=function(){var e,t,n,r,s,a;let i=null!=(n=null!=(t=null!=(e=c.find(e=>e.enabled&&e.visibleInNav&&"side-nav"===e.chrome))?e:c.find(e=>e.enabled&&"side-nav"===e.chrome))?t:c.find(e=>"side-nav"===e.chrome))?n:c[0],l=null!=(a=null==(r=i.children)?void 0:r.find(e=>e.enabled))?a:null==(s=i.children)?void 0:s[0];if(l)return l;if(p(i))return i;let o=c.find(e=>p(e));return o||c.flatMap(e=>{var t;return null!=(t=e.children)?t:[]})[0]}().href;function g(e){return c.find(t=>t.key===e)}function m(){return c.filter(e=>e.enabled&&!0===e.visibleInBridgeSidebar&&void 0!==e.icon).map(e=>{let{key:t,label:n,href:r,icon:s,headerIcon:a}=e;return{key:t,label:n,href:r,icon:s,headerIcon:null!=a?a:s}})}function h(e){var t;return(null===(t=(0,u.getSettingsRouteByPathname)(e,function(){let e=[];for(let n of c){var t;p(n)&&e.push(n),(null==(t=n.children)?void 0:t.length)&&e.push(...n.children)}return e}()))||void 0===t?void 0:t.enabled)!==!1}function v(e){if(!e)return!1;let t=c.filter(e=>"side-nav"===e.chrome);return(0,u.isSettingsRoutePath)(e,t)}},21199,41143,e=>{"use strict";e.s(["WorkspaceShell",()=>J],21199);var t=e.i(18050),n=e.i(71645),r=e.i(18566),s=e.i(65934),a=e.i(36845),i=e.i(20090);let l={EVENT:{SESSION_META:"session.meta",SESSION_READY:"session.ready",SESSION_ERROR:"session.error",QUERY_PROGRESS:"query.progress",CONVERSATION_DELTA:"conversation.delta",RUN_LIFECYCLE:"run.lifecycle",HISTORY_REPLAY:"history.replay",TURN_TERMINAL:"turn.terminal",PERMISSION_REQUEST:"permission.request"}};e.s(["SCHEDULE_TOOL_NAME",()=>o,"buildScheduledTaskIndex",()=>f,"parseScheduleToolResult",()=>p,"partitionScheduledSegments",()=>g,"retainScheduledTriggerFlag",()=>d,"withScheduledTriggerMeta",()=>u],41143);let o="ScheduleTool";function u(e,t,n){return e&&"object"==typeof e&&(t||n)?{...e,...t?{__scheduledTrigger:!0}:{},...n?{__turnId:n}:{}}:e}function d(e,t){if(!e||"object"!=typeof e)return t;let n=e.data,r=!!n&&"object"==typeof n&&!0===n.scheduledTrigger,s=!0===e.scheduledTrigger||!0===e.__scheduledTrigger,a="string"==typeof e.turnId?e.turnId:"",i="string"==typeof e.__turnId?e.__turnId:"";return r||s||a||i?{...t,...r||s?{__scheduledTrigger:!0}:{},...a||i?{__turnId:a||i}:{}}:t}function c(e){return!!e&&"object"==typeof e&&!0===e.__scheduledTrigger}function p(e,t){if("string"==typeof e)try{let t=JSON.parse(e);if(t&&"object"==typeof t)return t}catch(e){}if(e&&"object"==typeof e)return e;if(t&&"object"==typeof t){let e=t.toolUseResult;if(e&&"object"==typeof e)return e}return null}function f(e){let t=new Map,n=new Map;for(let c of e){let e=v(c);for(let m of function(e){if(!e||"object"!=typeof e)return[];let t=e.message,n=null==t?void 0:t.content;return Array.isArray(n)?n.filter(e=>!!e&&"object"==typeof e):[]}(c)){var r,s,a,i,l,u,d,f,g,b;if("tool_use"===m.type&&m.name===o){let t="string"==typeof m.id?m.id:"";if(!t)continue;let r=(b=m.input)&&"object"==typeof b?b:{},s=function(e){if(null==e||""===e)return;let t=Number(e);return Number.isFinite(t)?t:void 0}(r.delayMinutes);n.set(t,{toolUseId:t,id:r.id,prompt:null!=(a=r.prompt)?a:"",delayMinutes:s,createdAt:e,status:"cancel"===r.action?"cancelled":"scheduled"});continue}if("tool_result"!==m.type||"string"!=typeof m.tool_use_id)continue;let h=n.get(m.tool_use_id);if(!h)continue;let v=p(m.content,c);if(!v){n.delete(m.tool_use_id);continue}let y=v.id||h.id||"pending-".concat(m.tool_use_id),S={id:y,prompt:null!=(i=h.prompt)?i:"",fireAt:null!=(u=null!=(l=null==(r=v.scheduleClock)?void 0:r.utcIso)?l:null==(s=v.scheduleClock)?void 0:s.localDateTime)?u:"",createdAt:null!=(d=h.createdAt)?d:"",delayMinutes:null!=(f=v.delayMinutes)?f:h.delayMinutes,cron:v.cron,recurring:v.recurring,status:v.error?"failed":null!=(g=h.status)?g:"scheduled"};t.set(y,S),n.delete(m.tool_use_id)}}for(let n of e){if(!c(n)||"user"!==m(n))continue;let e=h(n);if(e){for(let r of t.values())if(r.prompt===e&&"scheduled"===r.status){r.status="fired",r.firedTurnId=function(e){if(!e||"object"!=typeof e)return"";let t=e.__turnId;return"string"==typeof t?t:""}(n);break}}}return t}function g(e,t){let n=new Map,r=new Set,s=0;for(;s<e.length;){var a;if(!c(e[s])){s+=1;continue}let i=s,l=[];for(;s<e.length&&c(e[s]);)l.push(e[s]),s+=1;let o=s-1,u=null!=(a=l.filter(e=>"user"===m(e)).map(e=>h(e)).find(e=>e.trim().length>0))?a:"",d=v(l[0]),p=l.filter(e=>"user"!==m(e)),f=function(e,t){if(e&&t.trim()){for(let n of e.values())if(n.prompt===t)return n.id}}(t,u);n.set(i,{kind:"scheduledTurn",startIndex:i,endIndex:o,dispatchedPrompt:u,triggeredAt:d,taskId:f,assistantMessages:p});for(let e=i+1;e<=o;e+=1)r.add(e)}return{scheduledStarts:n,consumed:r}}function m(e){if(!e||"object"!=typeof e)return"";let t=e.type;if("string"==typeof t)return t;let n=e.message;return"string"==typeof(null==n?void 0:n.role)?n.role:""}function h(e){if(!e||"object"!=typeof e)return"";let t=e.message,n=null==t?void 0:t.content;return"string"==typeof n?n:Array.isArray(n)?n.map(e=>e&&"object"==typeof e?"text"===e.type&&"string"==typeof e.text?e.text:"markdown"===e.type&&"string"==typeof e.content?e.content:"":"").filter(Boolean).join("\n").trim():""}function v(e){var t;if(!e||"object"!=typeof e)return"";let n=e.message,r=n&&"object"==typeof n?n.timestamp:void 0,s=null!=(t=null!=r?r:e.timestamp)?t:e.ts;return"string"==typeof s?s:""}var b=e.i(55227);function y(e){let t=Number(e);return Number.isFinite(t)?Math.max(0,Math.floor(t)):0}function S(e){let t=e&&"object"==typeof e?Number(e.protocolVersion):NaN;return"object"==typeof e&&null!==e&&"protocolVersion"in e&&Number.isFinite(t)&&3===t&&"string"==typeof e.type}let x=new Map;function A(e){if(!e||"object"!=typeof e)return"";if(("string"==typeof e.type?e.type:"unknown")===l.EVENT.TURN_TERMINAL){let t="string"==typeof e.resultText?e.resultText:"",n="string"==typeof e.reason?e.reason:"";return"resolved"==("resolved"===e.status?"resolved":"failed")?t:"turn.terminal failed: ".concat(n||"unknown")}try{return"```json\n".concat(JSON.stringify(e,null,2).slice(0,8e3),"\n```")}catch(t){return String(e)}}var j=e.i(87243),N=e.i(50711);async function k(e,t,n){var r;let a=String(e||"").trim();if(!a)return!1;let i=s.useAppStore.getState();if(a===(i.agentId.trim()||"qihoo"))return!1;let l=(null==n||null==(r=n.displayName)?void 0:r.trim())||a;i.startDraftSession(),i.resetAgentConfig(),i.setAgentId(a),i.setCurrentWorkspaceAgent({id:a,displayName:l});try{await t.loadSessions()}catch(e){}t.loadAgentConfig();let o=s.useAppStore.getState().sessionId.trim();return t.preferReconnect?t.reconnect():t.switchSession(o,a),!0}var w=e.i(92413),I=e.i(55146),C=e.i(72064),E=e.i(46798),T=e.i(85570),R=e.i(97249),_=e.i(75157),M=e.i(8279),P=e.i(52727),L=e.i(18253);function O(e){let{collapsed:r,onGoToSettings:a}=e,{push:i}=(0,L.useGuardedAppNavigation)(),l=(0,s.useAppStore)(e=>e.currentWorkspaceAgent),o=(0,s.useAppStore)(e=>e.agentId),u=(0,s.useAppStore)(e=>e.wsUrl),d=(0,s.useAppStore)(e=>e.apiBase),c=(0,s.useAppStore)(e=>e.setCurrentWorkspaceAgent),{switchWorkspaceAgent:p}=(0,T.useWorkspaceRuntime)(),f=o.trim()||"qihoo",g=(null==l?void 0:l.id)===f&&l.displayName.trim()||f,m=(0,M.initialsFromLabel)(g),[h,v]=(0,n.useState)(!1),[b,y]=(0,n.useState)([]),[S,x]=(0,n.useState)(!1),[A,j]=(0,n.useState)(null),N=(0,n.useRef)(null),k=(0,n.useCallback)(()=>{N.current&&(clearTimeout(N.current),N.current=null)},[]),w=(0,n.useCallback)(()=>{k(),v(!0)},[k]),I=(0,n.useCallback)(()=>{k(),N.current=setTimeout(()=>{v(!1),N.current=null},120)},[k]),O=(0,n.useCallback)(()=>{v(!1),null==a||a()},[a]),D=(0,n.useCallback)(async e=>{let t=e.id.trim();v(!1),t&&t!==f&&await p(t,e.displayName)&&i((0,R.buildAppNavHref)("/",{ensureAgent:!0,agent:t,preserveSessionId:!1}))},[f,i,p]);return(0,n.useEffect)(()=>{if(!h)return;let e=!1;return x(!0),j(null),y([]),(0,P.listAgents)(u,d).then(t=>{e||y(t)}).catch(t=>{e||j(String(t))}).finally(()=>{e||x(!1)}),()=>{e=!0}},[h,u,d]),(0,n.useEffect)(()=>{if(!b.length)return;let e=b.find(e=>e.id===f);e&&((null==l?void 0:l.id)!==e.id||l.displayName!==e.displayName)&&c(e)},[b,f,l,c]),(0,n.useEffect)(()=>()=>{N.current&&clearTimeout(N.current)},[]),(0,t.jsxs)("div",{className:(0,_.cn)("shrink-0 border-t border-solid border-[var(--ds-border)] transition",r?"flex w-full justify-center p-[1rem_.75rem]":"flex items-center gap-2 p-[1rem_.75rem]"),onClick:r?e=>e.stopPropagation():void 0,children:[(0,t.jsxs)("div",{className:(0,_.cn)("relative min-w-0",!r&&"flex-1"),onMouseEnter:w,onMouseLeave:I,children:[(0,t.jsxs)("div",{className:(0,_.cn)("flex min-w-0 cursor-pointer items-center gap-2 rounded-lg px-0.5 py-0.5",r&&"w-full justify-center"),children:[(0,t.jsx)("span",{className:"inline-flex h-7 w-7 shrink-0 items-center justify-center rounded-full text-xs font-semibold text-white",style:{background:"var(--avatar-bg)"},children:m}),r?null:(0,t.jsx)("span",{className:"min-w-0 truncate text-base text-[var(--ds-text)]",children:g})]}),h?(0,t.jsx)("div",{className:"absolute bottom-full left-0 z-50 pb-2 shadow-[var(--shadow-float)]",onMouseEnter:w,onMouseLeave:I,children:(0,t.jsx)("div",{className:(0,_.cn)("flex max-h-[300px] w-[260px] max-w-[min(100vw-24px,260px)] flex-col overflow-hidden rounded-[var(--ds-radius-sm)] border border-solid border-[var(--ds-border)] bg-[var(--ds-bg)]","shadow-[var(--shadow-float)]"),children:(0,t.jsx)("div",{className:"min-h-0 flex-1 overflow-y-auto p-1.5",role:"listbox","aria-label":"切换 Agent",children:S?(0,t.jsx)("div",{className:"px-2 py-3 text-sm text-[var(--ds-muted)]",children:"加载中…"}):A?(0,t.jsxs)("div",{className:"px-2 py-3 text-sm text-red-600",children:["加载失败: ",A]}):0===b.length?(0,t.jsx)("div",{className:"px-2 py-3 text-sm text-[var(--ds-muted)]",children:"暂无 agent"}):b.map(e=>{let n=e.id===f,r=(0,M.initialsFromLabel)(e.displayName);return(0,t.jsxs)("button",{type:"button",role:"option",className:"flex w-full cursor-pointer items-center gap-2 rounded-xl border-0 bg-transparent px-2 py-2 text-left text-base hover:bg-[var(--ds-item-hover)] focus-visible:outline-none","aria-selected":n,onClick:()=>D(e),children:[(0,t.jsx)("span",{className:"inline-flex h-8 w-8 shrink-0 items-center justify-center rounded-full text-xs font-semibold text-white",style:{background:"var(--avatar-bg)"},children:r}),(0,t.jsxs)("span",{className:"min-w-0 flex-1 leading-tight",children:[(0,t.jsx)("span",{className:"block truncate text-[var(--ds-text)]",children:e.displayName}),e.displayName!==e.id?(0,t.jsx)("span",{className:"block truncate text-xs text-[var(--ds-muted)]",children:e.id}):null]}),n?(0,t.jsx)("span",{className:"shrink-0","aria-label":"当前 Agent",children:(0,t.jsx)(C.default,{name:"Check",size:16,className:"text-[var(--ds-accent)]"})}):null]},e.id)})})})}):null]}),(0,t.jsx)(E.TooltipProvider,{delayDuration:150,children:(0,t.jsxs)(E.Tooltip,{children:[(0,t.jsx)(E.TooltipTrigger,{asChild:!0,children:(0,t.jsx)("button",{type:"button",className:"inline-flex h-7 w-7 shrink-0 cursor-pointer items-center justify-center rounded-md border-0 bg-transparent text-[var(--ds-muted)] hover:bg-[var(--ds-item-hover)] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--ds-accent)]","aria-label":"设置",onClick:O,children:(0,t.jsx)(C.default,{name:"More",size:16,className:"shrink-0"})})}),(0,t.jsx)(E.TooltipContent,{side:"top",children:(0,t.jsx)("p",{children:"设置"})})]})})]})}var D=e.i(82787);let W="bridge-sidebar-collapsed";function z(e){let{onNewSession:a,onSelectSession:i,deleteSessionById:l}=e,{push:o,router:u}=(0,L.useGuardedAppNavigation)(),d=(0,r.usePathname)(),c=(0,s.useAppStore)(e=>e.lastSessions),p=(0,s.useAppStore)(e=>e.sessionId),f=(0,s.useAppStore)(e=>e.brand),g=(0,s.useAppStore)(e=>e.agentId),[m,h]=(0,n.useState)(!1),v=(0,n.useRef)(!1),[b,y]=(0,n.useState)(null),[S,x]=(0,n.useState)(!0),A=(0,n.useMemo)(()=>(0,D.getBridgeSidebarManageRoutes)(),[]),j=(0,n.useCallback)((e,t)=>(0,R.buildAppNavHref)(e,{ensureAgent:null==t?void 0:t.ensureAgent,agent:g,preserveSessionId:"/"===e&&!(null==t?void 0:t.clearSessionId),sessionId:null==t?void 0:t.sessionId}),[g]),N=(0,n.useCallback)(e=>{let t=(0,R.normalizeAppPathname)(d),n=(0,R.normalizeAppPathname)(e);return t===n||t.startsWith("".concat(n,"/"))},[d]),k=(0,n.useCallback)(e=>{o(j(e,{ensureAgent:!0}))},[o,j]);(0,n.useEffect)(()=>{let e,t,n=[...["env","add-account"].flatMap(e=>{var t;let n=null==(t=(0,D.getManageRoute)(e))?void 0:t.href;return n?[j(n,{ensureAgent:!0})]:[]}),...A.map(e=>j(e.href,{ensureAgent:!0}))],r=()=>{for(let e of n)try{u.prefetch(e)}catch(e){}};return"requestIdleCallback"in window?e=window.requestIdleCallback(r,{timeout:2500}):t=setTimeout(r,200),()=>{void 0!==e&&window.cancelIdleCallback(e),void 0!==t&&clearTimeout(t)}},[u,j,A]),(0,n.useEffect)(()=>{try{let e=window.localStorage.getItem(W);"true"===e&&h(!0)}catch(e){}finally{v.current=!0}},[]),(0,n.useEffect)(()=>{if(v.current)try{window.localStorage.setItem(W,String(m))}catch(e){}},[m]),(0,n.useEffect)(()=>{if(!b)return;let e=e=>{let t=e.target;!(!(t instanceof Element)||t.closest("[data-session-menu-wrap]"))&&(t.closest('[data-slot="dropdown-menu-content"]')||y(null))};return document.addEventListener("pointerdown",e,!0),()=>document.removeEventListener("pointerdown",e,!0)},[b]);let T=(0,n.useCallback)(()=>{o(j(D.MANAGE_DEFAULT_HREF,{ensureAgent:!0}))},[o,j]);return(0,t.jsx)("aside",{className:"sidebar ".concat(m?"is-collapsed h-dvh max-h-dvh min-h-0 self-start":""),"data-region":"sidebar-panels",onClick:()=>{m&&h(!1)},children:m?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"flex min-h-0 flex-1 flex-col items-center gap-[10px] overflow-y-auto overscroll-contain pt-3",children:(0,t.jsxs)(E.TooltipProvider,{side:"right",children:[(0,t.jsx)("div",{className:"group relative flex h-8 w-8 shrink-0 cursor-pointer items-center justify-center",onClick:e=>e.stopPropagation(),children:(0,t.jsx)("div",{className:"pointer-events-none absolute inset-0 flex items-center justify-center transition-opacity group-hover:pointer-events-auto group-hover:opacity-100",children:(0,t.jsxs)(E.Tooltip,{children:[(0,t.jsx)(E.TooltipTrigger,{asChild:!0,children:(0,t.jsx)("button",{type:"button",className:"sidebar-collapsed-icon-btn",title:"展开侧边栏","aria-label":"展开侧边栏",onClick:e=>{e.preventDefault(),e.stopPropagation(),h(!1)},children:(0,t.jsx)(C.default,{name:"Layout",size:17,color:"#8f8f8f"})})}),(0,t.jsx)(E.TooltipContent,{children:(0,t.jsx)("p",{children:"展开侧边栏"})})]})})}),(0,t.jsxs)(E.Tooltip,{children:[(0,t.jsx)(E.TooltipTrigger,{asChild:!0,children:(0,t.jsx)("button",{type:"button",className:"sidebar-collapsed-icon-btn",title:"新聊天","aria-label":"新聊天",onClick:e=>{e.preventDefault(),e.stopPropagation(),a(),o(j("/",{clearSessionId:!0}))},children:(0,t.jsx)(C.default,{name:"Add",size:16,className:"text-zinc-700"})})}),(0,t.jsx)(E.TooltipContent,{children:(0,t.jsx)("p",{children:"新聊天"})})]}),A.map(e=>{let n=N(e.href);return(0,t.jsxs)(E.Tooltip,{children:[(0,t.jsx)(E.TooltipTrigger,{asChild:!0,children:(0,t.jsx)("button",{type:"button",className:"sidebar-collapsed-icon-btn ".concat(n?"bg-[var(--ds-item-active)] text-[var(--ds-accent)]":""),title:e.label,"aria-label":e.label,"aria-current":n?"page":void 0,onClick:t=>{t.preventDefault(),t.stopPropagation(),k(e.href)},children:(0,t.jsx)(C.default,{name:e.icon,size:16,className:n?"text-[var(--ds-accent)]":"text-zinc-700",strokeWidth:1.2})})}),(0,t.jsx)(E.TooltipContent,{children:(0,t.jsx)("p",{children:e.label})})]},e.key)})]})}),(0,t.jsx)("div",{className:"w-full shrink-0",onClick:e=>e.stopPropagation(),children:(0,t.jsx)(O,{collapsed:!0,onGoToSettings:T})})]}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"sidebar-brand",children:(0,t.jsxs)("div",{className:"sidebar-brand-title-row flex items-center justify-between",children:[(0,t.jsx)("div",{className:"logo flex min-w-0 items-center gap-2",children:(0,t.jsx)("span",{className:"truncate text-zinc-900",children:f})}),(0,t.jsx)(E.TooltipProvider,{side:"right",children:(0,t.jsxs)(E.Tooltip,{children:[(0,t.jsx)(E.TooltipTrigger,{asChild:!0,children:(0,t.jsx)("button",{type:"button",className:"sidebar-icon-btn",title:"收起侧边栏","aria-label":"收起侧边栏",onClick:e=>{e.preventDefault(),e.stopPropagation(),h(!0)},children:(0,t.jsx)(C.default,{name:"Layout",size:17,color:"#8f8f8f"})})}),(0,t.jsx)(E.TooltipContent,{children:(0,t.jsx)("p",{children:"收起侧边栏"})})]})})]})}),(0,t.jsx)("div",{className:"new-chat",children:(0,t.jsxs)("div",{className:"mb-4 ml-2 mr-2 mt-2 flex cursor-pointer items-center gap-2.5 rounded-2xl px-2 py-2 text-base text-zinc-700 transition-colors hover:bg-white/70",title:"开启新对话","aria-label":"开启新对话",onClick:e=>{e.preventDefault(),a(),o(j("/",{clearSessionId:!0}))},children:[(0,t.jsx)("span",{className:"flex h-8 w-8 shrink-0 items-center justify-center rounded-full bg-[var(--ds-item-active)] text-[var(--ds-accent)]","aria-hidden":!0,children:(0,t.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",children:(0,t.jsx)("path",{d:"M12 5v14M5 12h14"})})}),(0,t.jsx)("span",{className:"min-w-0 font-medium",children:"新会话"})]})}),(0,t.jsx)("div",{className:"sidebar-drawers",children:A.map(e=>{let n=N(e.href);return(0,t.jsxs)("div",{className:"m-[.35rem_.35rem_0] flex cursor-pointer items-center rounded-[var(--ds-radius-sm)] p-[.45rem_.75rem] ".concat(n?"bg-[var(--ds-item-active)] text-[var(--ds-accent)]":"hover:bg-[var(--ds-item-active)] hover:text-zinc-900"),role:"button",tabIndex:0,"aria-current":n?"page":void 0,onClick:t=>{t.preventDefault(),t.stopPropagation(),k(e.href)},onKeyDown:t=>{("Enter"===t.key||" "===t.key)&&k(e.href)},children:[(0,t.jsx)(C.default,{name:e.icon,size:16,className:"mr-3 text-zinc-700",strokeWidth:1.2}),(0,t.jsx)("span",{className:"text-base text-zinc-900",children:e.label})]},e.key)})}),(0,t.jsx)("div",{className:"sidebar-drawers",children:(0,t.jsxs)("div",{className:"sidebar-drawer m-[.35rem_.35rem_0] mt-4",children:[(0,t.jsxs)("button",{type:"button",className:"flex w-full cursor-pointer items-center !border-none !bg-transparent p-[.45rem_.75rem] text-left text-[12px] font-[600] text-zinc-400 hover:text-zinc-600 focus:outline-none focus-visible:ring-2 focus-visible:ring-[var(--ds-accent)] focus-visible:ring-offset-2","aria-expanded":S,"aria-controls":"sessionList","aria-label":S?"收起历史会话列表":"展开历史会话列表",onClick:()=>{x(e=>!e)},children:["历史会话",S?(0,t.jsx)(C.default,{name:"ChevronDown",size:12,strokeWidth:1,className:"ml-1 shrink-0 text-[var(--ds-muted)]"}):(0,t.jsx)(C.default,{name:"ChevronRight",size:12,strokeWidth:1,className:"ml-1 shrink-0 text-[var(--ds-muted)]"})]}),S?(0,t.jsx)("div",{className:"sidebar-drawer-body sidebar-drawer-body--sessions",children:(0,t.jsx)("div",{id:"sessionList",children:c.length?(0,w.groupSessionsByMonth)(c).map(e=>(0,t.jsx)("div",{children:e.items.map(e=>{let n=e.sessionId===p.trim();return(0,t.jsxs)("div",{className:"sidebar-drawer-item session-item ".concat(n?"active":""),children:[(0,t.jsx)("button",{type:"button",className:"session-item-main",onClick:t=>{t.stopPropagation(),i(e.sessionId),o(j("/",{sessionId:e.sessionId}))},children:(0,t.jsx)("div",{className:"session-item-title",children:(0,w.sessionTitle)(e)})}),(0,t.jsx)("div",{className:"session-menu-wrap","data-session-menu-wrap":"",onClick:t=>{t.stopPropagation(),t.target===t.currentTarget&&y(t=>t===e.sessionId?null:e.sessionId)},children:(0,t.jsxs)(I.DropdownMenu,{open:b===e.sessionId,onOpenChange:e=>{e||y(null)},children:[(0,t.jsx)(I.DropdownMenuTrigger,{type:"button",className:"session-menu-btn","aria-label":"更多",onClick:t=>{t.stopPropagation(),y(t=>t===e.sessionId?null:e.sessionId)},children:"···"}),(0,t.jsxs)(I.DropdownMenuContent,{align:"end",side:"bottom",sideOffset:6,className:"w-[172px] min-w-[172px] rounded-[var(--ds-radius-sm)] border border-[var(--ds-border)] bg-[var(--ds-bg)] p-1.5",children:[(0,t.jsxs)(I.DropdownMenuItem,{className:"h-9 rounded-xl px-2.5 text-base text-[var(--ds-text)] hover:bg-[var(--ds-item-active)] focus:bg-[var(--ds-item-hover)]",onClick:()=>{navigator.clipboard.writeText(e.sessionId)},children:[(0,t.jsx)(C.default,{name:"Clipboard",size:16,className:"text-[var(--ds-muted)]"}),"复制完整 ID"]}),(0,t.jsx)(I.DropdownMenuSeparator,{className:"mx-1 my-1 bg-[var(--ds-border)]"}),(0,t.jsxs)(I.DropdownMenuItem,{variant:"destructive",className:"h-9 rounded-xl px-2.5 text-base hover:bg-[#fff1f1] focus:bg-[#fff1f1]",onClick:()=>{(async()=>{let t=e.sessionId===p.trim(),n=await l(e.sessionId);t&&n&&o(j("/",{clearSessionId:!0}))})()},children:[(0,t.jsx)(C.default,{name:"Trash2",size:16}),"删除会话"]})]})]})})]},e.sessionId)})},e.key)):(0,t.jsx)("p",{className:"sidebar-drawer-empty",children:"(暂无会话)"})})}):null]})}),(0,t.jsx)(O,{collapsed:!1,onGoToSettings:T})]})})}var F=e.i(19455),B=e.i(61196);function U(){let e=(0,B.useStageThreadFlyoutStore)(e=>e.open),r=(0,B.useStageThreadFlyoutStore)(e=>e.title),s=(0,B.useStageThreadFlyoutStore)(e=>e.content),a=(0,B.useStageThreadFlyoutStore)(e=>e.width),i=(0,B.useStageThreadFlyoutStore)(e=>e.hideHeader),l=(0,B.useStageThreadFlyoutStore)(e=>e.bodyClassName),o=(0,B.useStageThreadFlyoutStore)(e=>e.requestCloseFlyout),[u,d]=(0,n.useState)(a),[c,p]=(0,n.useState)(!1);(0,n.useEffect)(()=>{if(!e)return;let t=e=>{"Escape"===e.key&&o()};return window.addEventListener("keydown",t),()=>{window.removeEventListener("keydown",t)}},[e,o]),(0,n.useEffect)(()=>{e&&d((0,B.clampStageThreadFlyoutWidth)(a))},[e,a]);let f=(0,n.useCallback)(e=>{e.preventDefault();let t=e.currentTarget;t.setPointerCapture(e.pointerId),p(!0);let n=e.clientX,r=e=>{let t=n-e.clientX;d((0,B.clampStageThreadFlyoutWidth)(u+t))},s=()=>{p(!1),t.removeEventListener("pointermove",r),t.removeEventListener("pointerup",s),t.removeEventListener("pointercancel",s),document.body.style.cursor="",document.body.style.userSelect=""};document.body.style.cursor="col-resize",document.body.style.userSelect="none",t.addEventListener("pointermove",r),t.addEventListener("pointerup",s),t.addEventListener("pointercancel",s)},[u]);return(0,t.jsx)("aside",{className:(0,_.cn)("stage-thread-flyout",e&&"is-open",c&&"is-resizing"),"data-region":"stage-thread-flyout","aria-hidden":!e,style:{"--stage-flyout-width":"".concat(u,"px")},children:e?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"stage-thread-flyout-resize",role:"separator","aria-orientation":"vertical","aria-valuenow":u,"aria-valuemin":B.STAGE_THREAD_FLYOUT_MIN_WIDTH,"aria-valuemax":B.STAGE_THREAD_FLYOUT_MAX_WIDTH,"aria-label":"调整面板宽度",onPointerDown:f,children:(0,t.jsx)("span",{className:"stage-thread-flyout-resize-bar","aria-hidden":!0})}),(0,t.jsxs)("div",{className:"stage-thread-flyout-inner",children:[i?null:(0,t.jsxs)("header",{className:"stage-thread-flyout-header",children:[r?(0,t.jsx)("h2",{className:"stage-thread-flyout-title",children:r}):(0,t.jsx)("span",{className:"stage-thread-flyout-title","aria-hidden":!0}),(0,t.jsx)(F.Button,{type:"button",variant:"ghost",size:"icon-sm",className:"stage-thread-flyout-close","aria-label":"关闭",onClick:()=>void o(),children:(0,t.jsx)(C.default,{name:"X",size:16})})]}),(0,t.jsx)("div",{className:(0,_.cn)("stage-thread-flyout-body",l),children:s})]})]}):null})}var V=e.i(94606);function G(){let e=(0,r.usePathname)(),t=(0,r.useRouter)(),s=(0,n.useRef)(null),a=(0,n.useRef)(!1);return(0,n.useEffect)(()=>{if(a.current)return;let n=s.current;if(s.current=e,!n||n===e)return;let{open:r,guardRoute:i,isDirty:l,closeFlyout:o}=B.useStageThreadFlyoutStore.getState();if(r&&(0,V.isLeavingFlyoutGuardRoute)(i,n,e)){if(!(0,V.shouldConfirmFlyoutRouteChange)(i,n,e,l))return void o();a.current=!0,t.replace(n),(0,V.confirmDiscardFlyoutChanges)().then(r=>{a.current=!1,r?(o(),t.push(e),s.current=e):s.current=n})}},[e,t]),null}function q(e){let{children:n,mainClassName:r,mainRegion:s,sidebar:a}=e;return(0,t.jsxs)("div",{className:"app","data-ui-layer":"presentation","data-topology":"local-first",children:[(0,t.jsx)(z,{onNewSession:a.onNewSession,onSelectSession:a.onSelectSession,onSaveAgentConfig:a.onSaveAgentConfig,deleteSessionById:a.deleteSessionById}),(0,t.jsx)("main",{className:(0,_.cn)("main overflow-x-auto",r),"data-region":s,children:(0,t.jsx)("div",{className:"main-content",children:n})}),(0,t.jsx)(U,{}),(0,t.jsx)(G,{})]})}function H(){let e=(0,s.useAppStore)(e=>e.wsUrl),t=(0,s.useAppStore)(e=>e.apiBase),r=(0,s.useAppStore)(e=>e.agentId),i=(0,s.useAppStore)(e=>e.agentSelectionResolved),l=(0,s.useAppStore)(e=>e.setWsUrl),o=(0,s.useAppStore)(e=>e.setAgentId),{loadSessions:u,loadAgentConfig:d}=(0,j.useSession)();return(0,n.useLayoutEffect)(()=>{s.useAppStore.getState().wsUrl.trim()||l((0,a.defaultWsUrl)())},[l]),(0,n.useLayoutEffect)(()=>{(0,R.syncRuntimeAgentWithUrl)(s.useAppStore.getState().agentId,o)},[r,o]),(0,n.useEffect)(()=>{if(!e.trim())return;let t=!1;return(async()=>{let e=s.useAppStore.getState();e.setAgentSelectionResolved(!1),e.setAgentSelectionError(null);let n=(0,R.readAgentFromLocationSearch)().trim()||e.agentId.trim()||"qihoo";try{var r;let s=await (0,P.listAgents)(e.wsUrl,e.apiBase);if(t)return;if(!s.length){e.setAgentSelectionError("暂无可用 Agent"),e.setAgentSelectionResolved(!1);return}let a=null!=(r=s.find(e=>e.id===n))?r:s[0];if(!a){e.setAgentSelectionError("暂无可用 Agent"),e.setAgentSelectionResolved(!1);return}e.agentId.trim()!==a.id&&e.setAgentId(a.id),e.setCurrentWorkspaceAgent(a),(0,R.replaceRuntimeAgentInUrl)(a.id),e.setAgentSelectionResolved(!0)}catch(n){if(t)return;e.setAgentSelectionError(n instanceof Error?n.message:String(n)),e.setAgentSelectionResolved(!1)}})(),()=>{t=!0}},[e,t,r]),(0,n.useEffect)(()=>{i&&(u(),d())},[i,r,e,t,u,d]),null}function Y(){let e=(0,r.useSearchParams)(),t=(0,s.useAppStore)(e=>e.setAgentId),a=(0,s.useAppStore)(e=>e.setAgentSelectionResolved);return(0,n.useLayoutEffect)(()=>{var n;let r=null==(n=e.get("agent"))?void 0:n.trim();r&&r!==s.useAppStore.getState().agentId.trim()&&(a(!1),t(r))},[e,t,a]),null}function Q(){return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(H,{}),(0,t.jsx)(n.Suspense,{fallback:null,children:(0,t.jsx)(Y,{})})]})}function J(e){let{children:o}=e,d=(0,r.usePathname)(),c=function(e){if(!e)return!1;let t=(0,R.normalizeAppPathname)(e);return"/manage"===t||t.startsWith("/manage/")}(d),p=(0,D.isManageSideNavPath)(d),f=(0,s.useAppStore)(e=>e.wsUrl),g=(0,s.useAppStore)(e=>e.apiBase),m=(0,s.useAppStore)(e=>e.agentId),h=(0,s.useAppStore)(e=>e.sessionId),v=(0,s.useAppStore)(e=>e.sessionViewMode),w=(0,s.useAppStore)(e=>e.setSessionId),I=(0,s.useAppStore)(e=>e.setSessionViewMode),C=(0,s.useAppStore)(e=>e.setPendingHistoryRefresh),{loadSessions:E,loadAgentConfig:_,loadSessionOverrides:M,deleteSessionById:P}=(0,j.useSession)(),L=(0,N.usePersistAgentConfig)(),{reconnect:O,switchSession:W,sendPrompt:z,sendAbort:F,sendReloadAgentConfig:B,sendPermissionResponse:U}=function(e){let t=(0,n.useRef)(null),r=(0,n.useRef)(""),o=(0,n.useRef)(0),d=(0,n.useRef)(0),c=(0,n.useRef)(0),p=(0,n.useRef)(new Map),f=(0,n.useRef)(null==e?void 0:e.onSession);f.current=null==e?void 0:e.onSession;let g=(0,s.useAppStore)(e=>e.wsUrl),m=(0,s.useAppStore)(e=>e.agentSelectionResolved),h=(0,n.useCallback)(()=>(o.current+=1,o.current),[]),v=(0,n.useCallback)(()=>{if(t.current){let e=t.current;t.current.close(),(0,i.clearActiveWebSocket)(e),t.current=null}let e=s.useAppStore.getState();e.setWsConnected(!1),e.setBridgeReady(!1),e.resetApiErrorState(),e.setAssistantGenerating(!1),p.current.clear()},[]),j=(0,n.useCallback)((e,t)=>{var n,a,i,o,c,g,m,v;let b=(null==t?void 0:t.httpReplay)===!0,y=s.useAppStore.getState(),S=(e.runId||"main").trim()||"main",N="string"==typeof e.agent_name?e.agent_name.trim():"";N&&p.current.set(S,N);let k=function(t,n){let r=!(arguments.length>2)||void 0===arguments[2]||arguments[2],s=r&&e.data&&"object"==typeof e.data&&"string"==typeof e.data.sourceAgent?e.data.sourceAgent.trim():"",a=p.current.get(S)||"";return t||s||a||n},w=String(null!=(n=e.sessionId)?n:"").trim()||r.current.trim()||y.sessionId.trim()||"unknown",I="".concat(d.current,":").concat(w);if(e.eventId&&function(e,t){var n;let r=t||"default",s=null!=(n=x.get(r))?n:new Set;if(s.has(e))return!0;if(s.add(e),s.size>4096)for(let e of Array.from(s).slice(0,2048))s.delete(e);return x.set(r,s),!1}(e.eventId,I))return void y.appendLog("dedup","eventId=".concat(e.eventId," 已忽略"));switch(y.appendLog(b?"← replay":"←",e),e.type){case l.EVENT.SESSION_META:{let t=e.data,n=String(null!=(i=null!=(a=t.sessionId)?a:e.sessionId)?i:""),s=y.sessionId.trim();if(r.current){if(n&&n!==s)return void y.appendLog("switchSession","忽略过期 session.meta incoming=".concat(n," current=").concat(s));r.current=""}t.agent&&y.setBrandAgent(String(t.agent)),n&&(y.setSessionId(n),null==(o=f.current)||o.call(f,n));break}case l.EVENT.SESSION_READY:{y.resetApiErrorState();let t=e.data;r.current&&y.sessionId.trim()===r.current&&(r.current=""),y.markReady(),t.agent&&y.setBrandAgent(String(t.agent));break}case l.EVENT.SESSION_ERROR:{let t=e.data,n=null!=(c=t.message)?c:JSON.stringify(t);y.setAssistantGenerating(!1),y.setStatus("错误: ".concat(String(n)),"err");break}case l.EVENT.QUERY_PROGRESS:{y.resetApiErrorState();let t=String(null!=(g=e.data.phase)?g:"");"idle"===t?(y.setQueryPhase(""),y.bridgeReady&&y.setStatus("已就绪","ready")):(y.setQueryPhase(t),y.setStatus("查询阶段: ".concat(t,"…"),""));break}case l.EVENT.CONVERSATION_DELTA:{y.resetApiErrorState();let t=e.data;if(!t.action)break;if("message_added"===t.action||"message_updated"===t.action||"message_removed"===t.action||"tool_call"===t.action||"tool_result"===t.action||"message_completed"===t.action){if(!b&&r.current){let t=String(null!=(m=e.sessionId)?m:"").trim(),n=r.current.trim(),s=y.sessionId.trim();if(t&&t!==n&&t!==s){y.appendLog("switchSession","忽略切换过程中的过期 conversation.delta incoming=".concat(t," pending=").concat(n," current=").concat(s));break}}let n={eventId:e.eventId,action:t.action,index:t.index,message:u(t.message,!0===t.scheduledTrigger||!0===e.scheduledTrigger,"string"==typeof e.turnId?e.turnId:"")},s=k("",S),a=h();y.applyRunMessageDelta({...n,runId:S,sourceAgent:s,ts:"string"==typeof e.ts?e.ts:"",arrivalSeq:a})}"message_completed"===t.action&&y.setStreamBuffer("");break}case l.EVENT.RUN_LIFECYCLE:{let t=e.data,n="string"==typeof t.event&&t.event||("string"==typeof t.state?t.state:"");if("replay.start"===n||"replay.end"===n)break;y.setRunLifecycleData({event:n,message:t.message});let r=k("string"==typeof t.sourceAgent?t.sourceAgent.trim():"","system",!1),s=A(t);s.trim()&&y.appendSourceAgentMessage({key:"string"==typeof e.eventId?e.eventId:"lc-".concat(Date.now()),source:r,runId:S,correlationId:"",status:"resolved",text:s,ts:"string"==typeof e.ts?e.ts:"",arrivalSeq:h()}),"configReloaded"===n&&y.setStatus("已重新加载 agent.md / agent.json",y.bridgeReady?"ready":"");break}case l.EVENT.HISTORY_REPLAY:{let n=e.data;if(Array.isArray(n.events))for(let e=0;e<n.events.length;e+=1){let r=n.events[e];r&&"object"==typeof r&&r.type!==l.EVENT.HISTORY_REPLAY&&j(r,t)}break}case l.EVENT.TURN_TERMINAL:{y.resetApiErrorState(),y.setStreamBuffer(""),y.setAssistantGenerating(!1),y.setQueryPhase("");let t=e.data;y.setTurnTerminalData({status:t.status,resultText:t.resultText,reason:t.reason});let n=s.useAppStore.getState();"resolved"===t.status?n.setStatus("本轮结束(可继续发送)",n.bridgeReady?"ready":""):"failed"===t.status?n.setStatus("本轮失败: ".concat(null!=(v=t.reason)?v:"未知错误"),"err"):"cancelled"===t.status?n.setStatus("本轮已取消",n.bridgeReady?"ready":""):n.setStatus("本轮结束(可继续发送)",n.bridgeReady?"ready":"");let r=k("string"==typeof t.sourceAgent?t.sourceAgent.trim():"","main"===S?"main":"unknown-agent",!1),a="string"==typeof t.correlationId?t.correlationId:"",i=A({type:l.EVENT.TURN_TERMINAL,status:t.status,reason:t.reason,resultText:t.resultText});n.appendSourceAgentMessage({key:"string"==typeof e.eventId?e.eventId:"terminal-".concat(Date.now()),source:r,runId:S,correlationId:a,status:"resolved"===t.status?"resolved":"failed",text:i,ts:"string"==typeof e.ts?e.ts:"",arrivalSeq:h()});break}case l.EVENT.PERMISSION_REQUEST:{let t=e.data,n="string"==typeof t.requestId?t.requestId.trim():"";if(!n)break;y.enqueuePermissionRequest({requestId:n,toolName:"string"==typeof t.toolName?t.toolName:"tool",description:"string"==typeof t.description?t.description:"",input:null!=t.input?t.input:{},runId:S})}}},[h]),N=(0,n.useCallback)(e=>{var t,n,a,i,l;let o=s.useAppStore.getState(),u=String(null!=(t=e.type)?t:"");if("system"===u&&"api_error"===e.subtype){let t=y(e.retryAttempt),n=y(e.maxRetries),r=y(e.retryInMs),s=Date.now()+r,a=n>0&&t>=n?"failed":r>=1e4?"retrying":"loading";o.setApiErrorState({phase:a,retryAttempt:t,maxRetries:n,retryInMs:r,retryUntilTs:s}),o.appendLog("api_error",{uuid:"string"==typeof e.uuid?e.uuid:"",retryAttempt:t,maxRetries:n,retryInMs:r});return}switch(u){case"messages":if(r.current)return void o.appendLog("switchSession","忽略切换过程中的 messages 回包");o.resetApiErrorState(),o.setMessages(Array.isArray(e.messages)?e.messages:[]),o.setStreamBuffer("");break;case"queryProgress":{o.resetApiErrorState();let t=String(null!=(n=e.phase)?n:"");"idle"===t?(o.setQueryPhase(""),o.bridgeReady&&o.setStatus("已就绪","ready")):(o.setQueryPhase(t),o.setStatus("查询阶段: ".concat(t,"…"),""));break}case"streamText":{o.resetApiErrorState();let t="string"==typeof e.text?e.text:"";o.setAssistantGenerating(!1),o.setStreamBuffer(t);let n=t.length>160?"".concat(t.slice(0,160),"…"):t;o.appendLog("←",{type:"streamText",len:t.length,preview:n||"(空)"});break}case"ready":o.resetApiErrorState(),r.current&&o.sessionId.trim()===r.current&&(r.current=""),o.markReady(),e.agent&&o.setBrandAgent(String(e.agent));break;case"session":{let t=String(null!=(a=e.sessionId)?a:""),n=o.sessionId.trim();if(r.current){if(t&&t!==n)return void o.appendLog("switchSession","忽略过期 session 回包 incoming=".concat(t," current=").concat(n));r.current=""}e.agent&&o.setBrandAgent(String(e.agent)),t&&(o.setSessionId(t),null==(i=f.current)||i.call(f,t));break}case"error":o.setAssistantGenerating(!1),o.setStatus("错误: ".concat(String(null!=(l=e.message)?l:JSON.stringify(e))),"err");break;case"turnComplete":{o.resetApiErrorState(),o.setStreamBuffer(""),o.setAssistantGenerating(!1),o.setQueryPhase("");let e=s.useAppStore.getState();e.setStatus("本轮结束(可继续发送)",e.bridgeReady?"ready":"");break}case"agentConfigReloaded":{let e=s.useAppStore.getState();e.setStatus("已重新加载 agent.md / agent.json",e.bridgeReady?"ready":"")}}},[]),k=(0,n.useCallback)(async(e,t)=>{let n=e.trim();if(!n)return;let r=s.useAppStore.getState(),a=r.agentId.trim()||"qihoo";try{let{envelopes:e,messageCount:s}=await (0,b.loadSessionReplay)(r.wsUrl,r.apiBase,a,n);if(t!==c.current)return;let i={httpReplay:!0};for(let t=0;t<e.length;t+=1){let n=e[t];n&&S(n)&&j(n,i)}r.appendLog("session-replay-http",{sessionId:n,messageCount:s,envelopeCount:e.length})}catch(e){if(t!==c.current)return;r.appendLog("session-replay-http",String(e)),r.setStatus("历史回放失败: ".concat(e),"err")}},[j]),w=(0,n.useCallback)(()=>{let e,n=s.useAppStore.getState();if(!n.agentSelectionResolved||t.current&&(0,i.isWebSocketOpen)(t.current)&&n.bridgeReady)return;if(t.current){let e=t.current;try{e.close()}catch(e){}(0,i.clearActiveWebSocket)(e),t.current=null}n.markConnecting(),n.resetApiErrorState(),n.resetChat(),n.clearLog(),o.current=0,p.current.clear(),d.current+=1,x.clear();let r=n.agentId.trim()||"qihoo",l=n.sessionId.trim();l&&k(l,++c.current);let u=(0,a.buildWsUrlWithQuery)(n.wsUrl,n.sessionId,r);n.appendLog("connect",u);try{t.current=e=new WebSocket(u),(0,i.setActiveWebSocket)(e)}catch(e){n.markConnectionError("连接失败: ".concat(e)),n.appendLog("error",String(e));return}e.onopen=function(){t.current===this&&s.useAppStore.getState().markConnected()},e.onclose=function(){(null==t.current||t.current===this)&&(s.useAppStore.getState().markDisconnected(),(0,i.clearActiveWebSocket)(this),t.current===this&&(t.current=null))},e.onerror=function(){t.current===this&&(s.useAppStore.getState().markConnectionError("WebSocket 错误"),s.useAppStore.getState().appendLog("error","websocket error"))},e.onmessage=function(e){let n,r=s.useAppStore.getState();try{n=JSON.parse(e.data)}catch(t){r.appendLog("raw",e.data);return}this===t.current&&(S(n)?j(n):null!==n&&"object"==typeof n&&(r.appendLog("←",n),N(n)))}},[j,N,k]),I=(0,n.useCallback)(()=>{v(),w()},[v,w]),C=(0,n.useCallback)((e,n)=>{let a=s.useAppStore.getState(),l=String(e||"").trim(),u=String(n||a.agentId||"").trim()||"qihoo",f=t.current,g=(0,i.isWebSocketOpen)(f);if(a.resetChat(),a.clearLog(),o.current=0,a.setBridgeReady(!1),a.resetApiErrorState(),a.setStatus("正在切换 session…",""),p.current.clear(),d.current+=1,l&&g&&k(l,++c.current),r.current=l,!g)return void I();try{let e={type:"switchSession",sessionId:l,agent:u};f.send(JSON.stringify(e)),a.appendLog("→",e)}catch(e){a.appendLog("error","switchSession 发送失败: ".concat(String(e))),I()}},[I,k]);(0,n.useEffect)(()=>m?(w(),()=>{v()}):void v(),[g,m,w,v]);let E=(0,n.useCallback)(e=>{let n=t.current;(0,i.isWebSocketOpen)(n)&&(n.send(JSON.stringify(e)),s.useAppStore.getState().appendLog("→",e))},[]),T=(0,n.useCallback)(e=>{String(null!=e?e:"").trim()&&s.useAppStore.getState().setAssistantGenerating(!0),E({type:"prompt",text:e})},[E]),R=(0,n.useCallback)(()=>{E({type:"abort"})},[E]),_=(0,n.useCallback)(()=>{E({type:"reloadAgentConfig"})},[E]),M=(0,n.useCallback)(()=>{E({type:"reloadAgentPrompt"})},[E]);return{wsRef:t,disconnectIfOpen:v,connectWebSocket:w,reconnect:I,switchSession:C,sendPrompt:T,sendAbort:R,sendReloadAgentConfig:_,sendReloadAgentPrompt:M,sendPermissionResponse:(0,n.useCallback)((e,t)=>{let n=String(e||"").trim();n&&E({type:"permission.response",requestId:n,behavior:t})},[E]),sendInit:(0,n.useCallback)(e=>{E({type:"init",...e})},[E])}}({onSession:e=>{E(),M(e)}}),V=(0,n.useCallback)((e,t)=>k(e,{switchSession:W,reconnect:O,loadSessions:E,loadAgentConfig:_,preferReconnect:c},{displayName:t}),[W,O,E,_,c]),G=(0,n.useMemo)(()=>({reconnect:O,switchSession:W,switchWorkspaceAgent:V,sendPrompt:z,sendAbort:F,sendReloadAgentConfig:B,sendPermissionResponse:U}),[O,W,V,z,F,B,U]),H=p?"settings-main":c?"manage-main":"draft"===v?"is-draft-session":void 0;return(0,t.jsxs)(T.WorkspaceRuntimeContext.Provider,{value:G,children:[(0,t.jsx)(Q,{}),(0,t.jsxs)("div",{className:"ws-config-hidden","aria-hidden":!0,children:[(0,t.jsx)("input",{readOnly:!0,hidden:!0,value:f}),(0,t.jsx)("input",{readOnly:!0,hidden:!0,value:g}),(0,t.jsx)("input",{readOnly:!0,hidden:!0,value:h}),(0,t.jsx)("input",{readOnly:!0,hidden:!0,value:m})]}),(0,t.jsx)(q,{mainClassName:H,mainRegion:p?"settings-shell":c?"manage-shell":"chat-shell",sidebar:{onNewSession:()=>{w(""),I("draft"),C(!1),c?O():W("",m)},onSelectSession:e=>{w(e),I("history"),C(!1),c?O():W(e,m)},onSaveAgentConfig:()=>void L({silent:!1}),deleteSessionById:async e=>{let t=await P(e);return t&&(c?O():W("",m)),t}},children:o})]})}},41796,e=>{"use strict";e.s(["SideNavShell",()=>d]);var t=e.i(18050),n=e.i(18566),r=e.i(72064),s=e.i(65934),a=e.i(75157),i=e.i(97249),l=e.i(51419),o=e.i(18253);function u(e,t){if(!t)return!1;let n=(0,i.normalizeAppPathname)(t),r=(0,i.normalizeAppPathname)(e);return n===r||n.startsWith("".concat(r,"/"))}function d(e){var d;let{title:c,navGroups:p,tabs:f,activeTabValue:g,tabVariant:m,bottomItems:h,children:v}=e,b=(0,n.usePathname)(),{push:y}=(0,o.useGuardedAppNavigation)(),S=(0,s.useAppStore)(e=>e.agentId),x=e=>{y((0,i.buildAppNavHref)(e,{ensureAgent:!0,agent:S}))},A=!!(m&&(null==f?void 0:f.length)),j=null!=g?g:null==f||null==(d=f[0])?void 0:d.value;return(0,t.jsxs)("div",{className:"side-nav-shell",children:[(0,t.jsxs)("nav",{className:"side-nav","aria-label":null!=c?c:"导航",children:[c?(0,t.jsx)("div",{className:"side-nav-title",children:c}):null,(0,t.jsx)("div",{className:"side-nav-groups",children:p.map((e,n)=>(0,t.jsx)("div",{className:"side-nav-group",children:e.items.map(e=>{let n=u(e.href,b);return(0,t.jsxs)("button",{type:"button",className:(0,a.cn)("side-nav-item",n&&"is-active"),"aria-current":n?"page":void 0,onClick:()=>x(e.href),children:[e.icon?(0,t.jsx)("span",{className:"side-nav-item-icon","aria-hidden":!0,children:(0,t.jsx)(r.default,{name:e.icon,size:16,className:"text-zinc-700",strokeWidth:1})}):null,(0,t.jsx)("span",{className:"side-nav-item-label",children:e.label})]},e.href)})},n))}),h&&h.length>0?(0,t.jsx)("div",{className:"side-nav-bottom",children:h.map(e=>{let n=u(e.href,b);return(0,t.jsxs)("button",{type:"button",className:(0,a.cn)("side-nav-item",n&&"is-active"),"aria-current":n?"page":void 0,onClick:()=>x(e.href),children:[e.icon?(0,t.jsx)("span",{className:"side-nav-item-icon","aria-hidden":!0,children:(0,t.jsx)(r.default,{name:e.icon,size:16,className:"text-zinc-700",strokeWidth:1})}):null,(0,t.jsx)("span",{className:"side-nav-item-label",children:e.label})]},e.href)})}):null]}),(0,t.jsx)("section",{className:"side-nav-content",children:A?(0,t.jsx)(l.AppTabs,{tabs:null!=f?f:[],value:j,onChange:x,listVariant:m,listClassName:"pill"===m?"mx-auto":void 0,contentClassName:"flex min-h-0 min-w-0 flex-1 flex-col",children:v}):v})]})}}]);