@minimalcorp/tsunagi 0.3.3 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (144) hide show
  1. package/.next/standalone/apps/web/.next/BUILD_ID +1 -1
  2. package/.next/standalone/apps/web/.next/build-manifest.json +3 -3
  3. package/.next/standalone/apps/web/.next/prerender-manifest.json +3 -3
  4. package/.next/standalone/apps/web/.next/server/app/_global-error.html +1 -1
  5. package/.next/standalone/apps/web/.next/server/app/_global-error.rsc +1 -1
  6. package/.next/standalone/apps/web/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  7. package/.next/standalone/apps/web/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  8. package/.next/standalone/apps/web/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  9. package/.next/standalone/apps/web/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  10. package/.next/standalone/apps/web/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  11. package/.next/standalone/apps/web/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  12. package/.next/standalone/apps/web/.next/server/app/_not-found.html +1 -1
  13. package/.next/standalone/apps/web/.next/server/app/_not-found.rsc +2 -2
  14. package/.next/standalone/apps/web/.next/server/app/_not-found.segments/_full.segment.rsc +2 -2
  15. package/.next/standalone/apps/web/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
  16. package/.next/standalone/apps/web/.next/server/app/_not-found.segments/_index.segment.rsc +2 -2
  17. package/.next/standalone/apps/web/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
  18. package/.next/standalone/apps/web/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
  19. package/.next/standalone/apps/web/.next/server/app/_not-found.segments/_tree.segment.rsc +2 -2
  20. package/.next/standalone/apps/web/.next/server/app/index.html +1 -1
  21. package/.next/standalone/apps/web/.next/server/app/index.rsc +3 -3
  22. package/.next/standalone/apps/web/.next/server/app/index.segments/__PAGE__.segment.rsc +2 -2
  23. package/.next/standalone/apps/web/.next/server/app/index.segments/_full.segment.rsc +3 -3
  24. package/.next/standalone/apps/web/.next/server/app/index.segments/_head.segment.rsc +1 -1
  25. package/.next/standalone/apps/web/.next/server/app/index.segments/_index.segment.rsc +2 -2
  26. package/.next/standalone/apps/web/.next/server/app/index.segments/_tree.segment.rsc +2 -2
  27. package/.next/standalone/apps/web/.next/server/app/page.js.nft.json +1 -1
  28. package/.next/standalone/apps/web/.next/server/app/page_client-reference-manifest.js +1 -1
  29. package/.next/standalone/apps/web/.next/server/app/settings/page.js.nft.json +1 -1
  30. package/.next/standalone/apps/web/.next/server/app/settings/page_client-reference-manifest.js +1 -1
  31. package/.next/standalone/apps/web/.next/server/app/settings.html +1 -1
  32. package/.next/standalone/apps/web/.next/server/app/settings.rsc +3 -3
  33. package/.next/standalone/apps/web/.next/server/app/settings.segments/_full.segment.rsc +3 -3
  34. package/.next/standalone/apps/web/.next/server/app/settings.segments/_head.segment.rsc +1 -1
  35. package/.next/standalone/apps/web/.next/server/app/settings.segments/_index.segment.rsc +2 -2
  36. package/.next/standalone/apps/web/.next/server/app/settings.segments/_tree.segment.rsc +2 -2
  37. package/.next/standalone/apps/web/.next/server/app/settings.segments/settings/__PAGE__.segment.rsc +2 -2
  38. package/.next/standalone/apps/web/.next/server/app/settings.segments/settings.segment.rsc +1 -1
  39. package/.next/standalone/apps/web/.next/server/app/tasks/[id]/page.js.nft.json +1 -1
  40. package/.next/standalone/apps/web/.next/server/app/tasks/[id]/page_client-reference-manifest.js +1 -1
  41. package/.next/standalone/apps/web/.next/server/chunks/ssr/_05n88to._.js +3 -0
  42. package/.next/standalone/apps/web/.next/server/chunks/ssr/_0g.cd6a._.js +2 -2
  43. package/.next/standalone/apps/web/.next/server/chunks/ssr/{_0kflgfj._.js → _0pw3_r_._.js} +3 -3
  44. package/.next/standalone/apps/web/.next/server/chunks/ssr/{_0g79jqo._.js → _0rb6-mo._.js} +3 -3
  45. package/.next/standalone/apps/web/.next/server/chunks/ssr/_0ts4rpp._.js +3 -0
  46. package/.next/standalone/apps/web/.next/server/chunks/ssr/apps_web_src_app_settings_page_tsx_0i6itlb._.js +2 -2
  47. package/.next/standalone/apps/web/.next/server/chunks/ssr/apps_web_src_app_tasks_[id]_page_tsx_0jshsm2._.js +3 -3
  48. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_04pfam-._.js → node_modules_03-rvdo._.js} +1 -1
  49. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_0cv326~._.js → node_modules_06jdmu~._.js} +1 -1
  50. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_0a57phw._.js → node_modules_0925te2._.js} +2 -2
  51. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_0_huoqd._.js → node_modules_0e8uni7._.js} +1 -1
  52. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_0tod6y8._.js → node_modules_0h4h_aw._.js} +1 -1
  53. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_0h.vgyn._.js → node_modules_0nzbb9~._.js} +1 -1
  54. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_0oip5a1._.js → node_modules_0q8yuvq._.js} +1 -1
  55. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_11-z65a._.js → node_modules_0r6t2tu._.js} +1 -1
  56. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_09d2oqj._.js → node_modules_0t6ysh_._.js} +1 -1
  57. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_0krwgny._.js → node_modules_0vj~e_v._.js} +1 -1
  58. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_0sn0lqb._.js → node_modules_0vq~hzy._.js} +1 -1
  59. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_0l23gkf._.js → node_modules_0xzmx-x._.js} +1 -1
  60. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_0npujym._.js → node_modules_0yb2sh9._.js} +1 -1
  61. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_0q_5qo~._.js → node_modules_0yc~s8p._.js} +1 -1
  62. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_0q_xfyl._.js → node_modules_0zi-gfw._.js} +1 -1
  63. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_0ak_3rk._.js → node_modules_0zzdoud._.js} +1 -1
  64. package/.next/standalone/apps/web/.next/server/chunks/ssr/{node_modules_0xp9nhx._.js → node_modules_0~aiu12._.js} +1 -1
  65. package/.next/standalone/apps/web/.next/server/middleware-build-manifest.js +3 -3
  66. package/.next/standalone/apps/web/.next/server/pages/404.html +1 -1
  67. package/.next/standalone/apps/web/.next/server/pages/500.html +1 -1
  68. package/.next/standalone/apps/web/.next/server/server-reference-manifest.js +1 -1
  69. package/.next/standalone/apps/web/.next/server/server-reference-manifest.json +1 -1
  70. package/.next/standalone/apps/web/.next/static/chunks/09b_3duxnyfto.js +7 -0
  71. package/.next/standalone/apps/web/.next/static/chunks/{0z60ewb40i2ce.js → 0gxhy80~c0gvp.js} +1 -1
  72. package/.next/standalone/apps/web/.next/static/chunks/0i9h-39w91ybd.js +6 -0
  73. package/.next/standalone/apps/web/.next/static/chunks/{0b90ys7wq-p.4.css → 0pm0knaijueoc.css} +1 -1
  74. package/.next/standalone/apps/web/.next/static/chunks/{0oricprxoxb_d.js → 0smdykrt42e.5.js} +10 -10
  75. package/.next/standalone/apps/web/.next/static/chunks/{149sia28cskw9.js → 0yp~t_.pozr-d.js} +6 -6
  76. package/.next/standalone/apps/web/.next/static/chunks/{0o6ggm7jrim25.js → 14zh2vf8ljbxo.js} +1 -1
  77. package/.next/standalone/apps/web/.next/static/chunks/{053h220fng_68.js → 1624992q-gpj2.js} +10 -10
  78. package/.next/standalone/apps/web/package.json +1 -0
  79. package/README.md +1 -1
  80. package/dist/app.js +3 -3
  81. package/dist/plugin-lifecycle.d.ts +5 -3
  82. package/dist/plugin-lifecycle.js +40 -16
  83. package/dist/prisma/migrations/20261011000000_add_codex_support/migration.sql +20 -0
  84. package/dist/prisma/schema.prisma +9 -5
  85. package/dist/server/generated/prisma/browser.d.ts +2 -2
  86. package/dist/server/generated/prisma/client.d.ts +2 -2
  87. package/dist/server/generated/prisma/internal/class.d.ts +4 -4
  88. package/dist/server/generated/prisma/internal/class.js +4 -4
  89. package/dist/server/generated/prisma/internal/prismaNamespace.d.ts +41 -39
  90. package/dist/server/generated/prisma/internal/prismaNamespace.js +4 -2
  91. package/dist/server/generated/prisma/internal/prismaNamespaceBrowser.d.ts +5 -3
  92. package/dist/server/generated/prisma/internal/prismaNamespaceBrowser.js +4 -2
  93. package/dist/server/generated/prisma/models/AgentProfile.d.ts +972 -0
  94. package/dist/server/generated/prisma/models/Tab.d.ts +36 -1
  95. package/dist/server/generated/prisma/models.d.ts +1 -1
  96. package/dist/server/index.js +2 -2
  97. package/dist/server/lib/agent-profiles.d.ts +43 -0
  98. package/dist/server/lib/agent-profiles.js +127 -0
  99. package/dist/server/lib/agents/claude.d.ts +2 -0
  100. package/dist/server/lib/agents/claude.js +130 -0
  101. package/dist/server/lib/agents/cli.d.ts +14 -0
  102. package/dist/server/lib/agents/cli.js +57 -0
  103. package/dist/server/lib/agents/codex.d.ts +2 -0
  104. package/dist/server/lib/agents/codex.js +285 -0
  105. package/dist/server/lib/agents/index.d.ts +11 -0
  106. package/dist/server/lib/agents/index.js +19 -0
  107. package/dist/server/lib/agents/login-callback.d.ts +11 -0
  108. package/dist/server/lib/agents/login-callback.js +47 -0
  109. package/dist/server/lib/agents/types.d.ts +77 -0
  110. package/dist/server/lib/agents/types.js +8 -0
  111. package/dist/server/lib/pty-env-sync.js +1 -1
  112. package/dist/server/lib/pty-launch.d.ts +8 -10
  113. package/dist/server/lib/pty-launch.js +20 -58
  114. package/dist/server/lib/repositories/task.js +1 -0
  115. package/dist/server/lib/tab-todos.d.ts +5 -0
  116. package/dist/server/lib/tab-todos.js +13 -0
  117. package/dist/server/pty-manager.d.ts +7 -2
  118. package/dist/server/pty-manager.js +13 -0
  119. package/dist/server/routes/agent-profiles.d.ts +2 -0
  120. package/dist/server/routes/agent-profiles.js +193 -0
  121. package/dist/server/routes/env.js +2 -2
  122. package/dist/server/routes/hooks.d.ts +4 -19
  123. package/dist/server/routes/hooks.js +83 -73
  124. package/dist/server/routes/mcp.js +2 -2
  125. package/dist/server/routes/onboarding.js +19 -10
  126. package/dist/server/routes/tasks.js +4 -4
  127. package/dist/server/routes/terminal.js +47 -34
  128. package/dist/with-plugin.js +3 -3
  129. package/npm-shrinkwrap.json +12 -12
  130. package/package.json +1 -1
  131. package/tsunagi-marketplace/codex/tsunagi-task.md +120 -0
  132. package/.next/standalone/apps/web/.next/server/chunks/ssr/_0hnxatt._.js +0 -3
  133. package/.next/standalone/apps/web/.next/server/chunks/ssr/_10gk93.._.js +0 -3
  134. package/.next/standalone/apps/web/.next/static/chunks/0crn03y2tj0lu.js +0 -6
  135. package/.next/standalone/apps/web/.next/static/chunks/0lvl3ec93cab_.js +0 -7
  136. package/dist/server/generated/prisma/models/ClaudeProfile.d.ts +0 -939
  137. package/dist/server/lib/claude-profiles.d.ts +0 -49
  138. package/dist/server/lib/claude-profiles.js +0 -168
  139. package/dist/server/routes/claude-profiles.d.ts +0 -2
  140. package/dist/server/routes/claude-profiles.js +0 -138
  141. /package/.next/standalone/apps/web/.next/static/{7x81GlNKt9yqIkeI7U1BX → ZcOuTrikuO_ZLaERk7FsW}/_buildManifest.js +0 -0
  142. /package/.next/standalone/apps/web/.next/static/{7x81GlNKt9yqIkeI7U1BX → ZcOuTrikuO_ZLaERk7FsW}/_clientMiddlewareManifest.js +0 -0
  143. /package/.next/standalone/apps/web/.next/static/{7x81GlNKt9yqIkeI7U1BX → ZcOuTrikuO_ZLaERk7FsW}/_ssgManifest.js +0 -0
  144. /package/dist/server/generated/prisma/models/{ClaudeProfile.js → AgentProfile.js} +0 -0
@@ -1,3 +1,3 @@
1
1
  module.exports=[86618,a=>{"use strict";var b=a.i(73160),c=a.i(14562),d=a.i(34603),e=a.i(38673),f={parse:(0,d.__name)(async a=>{let b=await (0,e.parse)("info",a);d.log.debug(b)},"parse")},g=(0,d.__name)(()=>"11.14.0","getVersion"),h=(0,d.__name)((a,e,f)=>{d.log.debug("rendering info diagram\n"+a);let g=(0,b.selectSvgElement)(e);(0,c.configureSvgSize)(g,100,400,!0),g.append("g").append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size",32).style("text-anchor","middle").text(`v${f}`)},"draw");a.s(["diagram",0,{parser:f,db:{getVersion:g},renderer:{draw:h}}])},29250,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0mhr-tu._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(38362)))},72847,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__13fmof_._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(97253)))},24590,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0ico9~m._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(16311)))},15431,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0zb._6y._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46792)))},89536,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0a09w3z._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(18975)))},77468,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__00xeq7r._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46595)))},43960,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__10s~ptn._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(48026)))},31415,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0tlibqy._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(36952)))},1864,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__03zxnl6._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(6890)))}];
2
2
 
3
- //# sourceMappingURL=node_modules_11-z65a._.js.map
3
+ //# sourceMappingURL=node_modules_0r6t2tu._.js.map
@@ -23,4 +23,4 @@ module.exports=[91160,a=>{"use strict";function b(a,b){a.accDescr&&b.setAccDescr
23
23
  }
24
24
  `},"styles");a.s(["diagram",0,{parser:l,get db(){return new i},renderer:{draw:m},styles:p}])},29250,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0mhr-tu._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(38362)))},72847,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__13fmof_._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(97253)))},24590,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0ico9~m._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(16311)))},15431,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0zb._6y._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46792)))},89536,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0a09w3z._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(18975)))},77468,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__00xeq7r._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46595)))},43960,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__10s~ptn._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(48026)))},31415,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0tlibqy._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(36952)))},1864,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__03zxnl6._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(6890)))}];
25
25
 
26
- //# sourceMappingURL=node_modules_09d2oqj._.js.map
26
+ //# sourceMappingURL=node_modules_0t6ysh_._.js.map
@@ -1,3 +1,3 @@
1
1
  module.exports=[91160,a=>{"use strict";function b(a,b){a.accDescr&&b.setAccDescription?.(a.accDescr),a.accTitle&&b.setAccTitle?.(a.accTitle),a.title&&b.setDiagramTitle?.(a.title)}(0,a.i(34603).__name)(b,"populateCommonDb"),a.s(["populateCommonDb",0,b])},29250,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0mhr-tu._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(38362)))},72847,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__13fmof_._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(97253)))},24590,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0ico9~m._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(16311)))},15431,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0zb._6y._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46792)))},89536,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0a09w3z._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(18975)))},77468,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__00xeq7r._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46595)))},43960,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__10s~ptn._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(48026)))},31415,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0tlibqy._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(36952)))},1864,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__03zxnl6._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(6890)))}];
2
2
 
3
- //# sourceMappingURL=node_modules_0krwgny._.js.map
3
+ //# sourceMappingURL=node_modules_0vj~e_v._.js.map
@@ -1,3 +1,3 @@
1
1
  module.exports=[91160,a=>{"use strict";function b(a,b){a.accDescr&&b.setAccDescription?.(a.accDescr),a.accTitle&&b.setAccTitle?.(a.accTitle),a.title&&b.setDiagramTitle?.(a.title)}(0,a.i(34603).__name)(b,"populateCommonDb"),a.s(["populateCommonDb",0,b])},20718,a=>{"use strict";var b=a.i(34603),c=class{constructor(a){this.init=a,this.records=this.init()}static{(0,b.__name)(this,"ImperativeState")}reset(){this.records=this.init()}};a.s(["ImperativeState",0,c])},29250,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0mhr-tu._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(38362)))},72847,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__13fmof_._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(97253)))},24590,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0ico9~m._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(16311)))},15431,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0zb._6y._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46792)))},89536,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0a09w3z._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(18975)))},77468,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__00xeq7r._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46595)))},43960,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__10s~ptn._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(48026)))},31415,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0tlibqy._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(36952)))},1864,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__03zxnl6._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(6890)))}];
2
2
 
3
- //# sourceMappingURL=node_modules_0sn0lqb._.js.map
3
+ //# sourceMappingURL=node_modules_0vq~hzy._.js.map
@@ -23,4 +23,4 @@ module.exports=[91160,a=>{"use strict";function b(a,b){a.accDescr&&b.setAccDescr
23
23
  }
24
24
  `},"styles");a.s(["diagram",0,{parser:l,get db(){return new i},renderer:{draw:m},styles:p}])},29250,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0mhr-tu._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(38362)))},72847,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__13fmof_._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(97253)))},24590,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0ico9~m._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(16311)))},15431,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0zb._6y._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46792)))},89536,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0a09w3z._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(18975)))},77468,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__00xeq7r._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46595)))},43960,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__10s~ptn._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(48026)))},31415,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0tlibqy._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(36952)))},1864,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__03zxnl6._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(6890)))}];
25
25
 
26
- //# sourceMappingURL=node_modules_0l23gkf._.js.map
26
+ //# sourceMappingURL=node_modules_0xzmx-x._.js.map
@@ -28,4 +28,4 @@ module.exports=[91160,a=>{"use strict";function b(a,b){a.accDescr&&b.setAccDescr
28
28
  }
29
29
  `,"getStyles"),D=(0,f.__name)(a=>{let b=[...a.values()].reduce((a,b)=>a+b,0),c=[...a.entries()].map(([a,b])=>({label:a,value:b})).filter(a=>a.value/b*100>=1);return(function(){var a=l,b=k,c=null,d=(0,j.default)(0),e=(0,j.default)(m.tau),f=(0,j.default)(0);function g(g){var h,j,k,l,n,o=(g=(0,i.default)(g)).length,p=0,q=Array(o),r=Array(o),s=+d.apply(this,arguments),t=Math.min(m.tau,Math.max(-m.tau,e.apply(this,arguments)-s)),u=Math.min(Math.abs(t)/o,f.apply(this,arguments)),v=u*(t<0?-1:1);for(h=0;h<o;++h)(n=r[q[h]=h]=+a(g[h],h,g))>0&&(p+=n);for(null!=b?q.sort(function(a,c){return b(r[a],r[c])}):null!=c&&q.sort(function(a,b){return c(g[a],g[b])}),h=0,k=p?(t-o*v)/p:0;h<o;++h,s=l)l=s+((n=r[j=q[h]])>0?n*k:0)+v,r[j]={data:g[j],index:h,value:n,startAngle:s,endAngle:l,padAngle:u};return r}return g.value=function(b){return arguments.length?(a="function"==typeof b?b:(0,j.default)(+b),g):a},g.sortValues=function(a){return arguments.length?(b=a,c=null,g):b},g.sort=function(a){return arguments.length?(c=a,b=null,g):c},g.startAngle=function(a){return arguments.length?(d="function"==typeof a?a:(0,j.default)(+a),g):d},g.endAngle=function(a){return arguments.length?(e="function"==typeof a?a:(0,j.default)(+a),g):e},g.padAngle=function(a){return arguments.length?(f="function"==typeof a?a:(0,j.default)(+a),g):f},g})().value(a=>a.value).sort(null)(c)},"createPieArcs"),E=(0,f.__name)((a,c,g,i)=>{f.log.debug("rendering pie chart\n"+a);let j=i.db,k=(0,e.getConfig2)(),l=(0,d.cleanAndMerge)(j.getConfig(),k.pie),m=(0,b.selectSvgElement)(c),o=m.append("g");o.attr("transform","translate(225,225)");let{themeVariables:p}=k,[q]=(0,d.parseFontSize)(p.pieOuterStrokeWidth);q??=2;let r=l.textPosition,s=(0,h.arc)().innerRadius(0).outerRadius(185),t=(0,h.arc)().innerRadius(185*r).outerRadius(185*r);o.append("circle").attr("cx",0).attr("cy",0).attr("r",185+q/2).attr("class","pieOuterCircle");let u=j.getSections(),v=D(u),w=[p.pie1,p.pie2,p.pie3,p.pie4,p.pie5,p.pie6,p.pie7,p.pie8,p.pie9,p.pie10,p.pie11,p.pie12],x=0;u.forEach(a=>{x+=a});let y=v.filter(a=>"0"!==(a.data.value/x*100).toFixed(0)),z=(0,n.scaleOrdinal)(w).domain([...u.keys()]);o.selectAll("mySlices").data(y).enter().append("path").attr("d",s).attr("fill",a=>z(a.data.label)).attr("class","pieCircle"),o.selectAll("mySlices").data(y).enter().append("text").text(a=>(a.data.value/x*100).toFixed(0)+"%").attr("transform",a=>"translate("+t.centroid(a)+")").style("text-anchor","middle").attr("class","slice");let A=o.append("text").text(j.getDiagramTitle()).attr("x",0).attr("y",-200).attr("class","pieTitleText"),B=[...u.entries()].map(([a,b])=>({label:a,value:b})),C=o.selectAll(".legend").data(B).enter().append("g").attr("class","legend").attr("transform",(a,b)=>"translate(216,"+(22*b-22*B.length/2)+")");C.append("rect").attr("width",18).attr("height",18).style("fill",a=>z(a.label)).style("stroke",a=>z(a.label)),C.append("text").attr("x",22).attr("y",14).text(a=>j.getShowData()?`${a.label} [${a.value}]`:a.label);let E=Math.max(...C.selectAll("text").nodes().map(a=>a?.getBoundingClientRect().width??0)),F=A.node()?.getBoundingClientRect().width??0,G=Math.min(0,225-F/2),H=Math.max(512+E,225+F/2)-G;m.attr("viewBox",`${G} 0 ${H} 450`),(0,e.configureSvgSize)(m,450,H,l.useMaxWidth)},"draw");a.s(["diagram",0,{parser:B,db:z,renderer:{draw:E},styles:C}],28018)},29250,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0mhr-tu._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(38362)))},72847,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__13fmof_._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(97253)))},24590,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0ico9~m._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(16311)))},15431,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0zb._6y._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46792)))},89536,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0a09w3z._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(18975)))},77468,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__00xeq7r._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46595)))},43960,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__10s~ptn._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(48026)))},31415,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0tlibqy._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(36952)))},1864,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__03zxnl6._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(6890)))}];
30
30
 
31
- //# sourceMappingURL=node_modules_0npujym._.js.map
31
+ //# sourceMappingURL=node_modules_0yb2sh9._.js.map
@@ -8,4 +8,4 @@ module.exports=[91160,a=>{"use strict";function b(a,b){a.accDescr&&b.setAccDescr
8
8
  }
9
9
  `},"styles");a.s(["diagram",0,{db:o,renderer:{draw:u},parser:q,styles:w}])},29250,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0mhr-tu._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(38362)))},72847,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__13fmof_._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(97253)))},24590,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0ico9~m._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(16311)))},15431,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0zb._6y._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46792)))},89536,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0a09w3z._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(18975)))},77468,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__00xeq7r._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46595)))},43960,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__10s~ptn._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(48026)))},31415,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0tlibqy._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(36952)))},1864,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__03zxnl6._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(6890)))}];
10
10
 
11
- //# sourceMappingURL=node_modules_0q_5qo~._.js.map
11
+ //# sourceMappingURL=node_modules_0yc~s8p._.js.map
@@ -8,4 +8,4 @@ module.exports=[91160,a=>{"use strict";function b(a,b){a.accDescr&&b.setAccDescr
8
8
  }
9
9
  `},"styles");a.s(["diagram",0,{db:o,renderer:{draw:u},parser:q,styles:w}])},29250,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0mhr-tu._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(38362)))},72847,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__13fmof_._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(97253)))},24590,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0ico9~m._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(16311)))},15431,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0zb._6y._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46792)))},89536,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0a09w3z._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(18975)))},77468,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__00xeq7r._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46595)))},43960,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__10s~ptn._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(48026)))},31415,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0tlibqy._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(36952)))},1864,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__03zxnl6._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(6890)))}];
10
10
 
11
- //# sourceMappingURL=node_modules_0q_xfyl._.js.map
11
+ //# sourceMappingURL=node_modules_0zi-gfw._.js.map
@@ -42,4 +42,4 @@ module.exports=[91160,a=>{"use strict";function b(a,b){a.accDescr&&b.setAccDescr
42
42
  ${D(b,c)}
43
43
  `},"styles");a.s(["diagram",0,{parser:u,db:s,renderer:{draw:v},styles:F}])},29250,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0mhr-tu._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(38362)))},72847,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__13fmof_._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(97253)))},24590,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0ico9~m._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(16311)))},15431,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0zb._6y._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46792)))},89536,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0a09w3z._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(18975)))},77468,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__00xeq7r._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46595)))},43960,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__10s~ptn._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(48026)))},31415,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0tlibqy._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(36952)))},1864,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__03zxnl6._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(6890)))}];
44
44
 
45
- //# sourceMappingURL=node_modules_0ak_3rk._.js.map
45
+ //# sourceMappingURL=node_modules_0zzdoud._.js.map
@@ -28,4 +28,4 @@ module.exports=[91160,a=>{"use strict";function b(a,b){a.accDescr&&b.setAccDescr
28
28
  }
29
29
  `,"getStyles"),D=(0,f.__name)(a=>{let b=[...a.values()].reduce((a,b)=>a+b,0),c=[...a.entries()].map(([a,b])=>({label:a,value:b})).filter(a=>a.value/b*100>=1);return(function(){var a=l,b=k,c=null,d=(0,j.default)(0),e=(0,j.default)(m.tau),f=(0,j.default)(0);function g(g){var h,j,k,l,n,o=(g=(0,i.default)(g)).length,p=0,q=Array(o),r=Array(o),s=+d.apply(this,arguments),t=Math.min(m.tau,Math.max(-m.tau,e.apply(this,arguments)-s)),u=Math.min(Math.abs(t)/o,f.apply(this,arguments)),v=u*(t<0?-1:1);for(h=0;h<o;++h)(n=r[q[h]=h]=+a(g[h],h,g))>0&&(p+=n);for(null!=b?q.sort(function(a,c){return b(r[a],r[c])}):null!=c&&q.sort(function(a,b){return c(g[a],g[b])}),h=0,k=p?(t-o*v)/p:0;h<o;++h,s=l)l=s+((n=r[j=q[h]])>0?n*k:0)+v,r[j]={data:g[j],index:h,value:n,startAngle:s,endAngle:l,padAngle:u};return r}return g.value=function(b){return arguments.length?(a="function"==typeof b?b:(0,j.default)(+b),g):a},g.sortValues=function(a){return arguments.length?(b=a,c=null,g):b},g.sort=function(a){return arguments.length?(c=a,b=null,g):c},g.startAngle=function(a){return arguments.length?(d="function"==typeof a?a:(0,j.default)(+a),g):d},g.endAngle=function(a){return arguments.length?(e="function"==typeof a?a:(0,j.default)(+a),g):e},g.padAngle=function(a){return arguments.length?(f="function"==typeof a?a:(0,j.default)(+a),g):f},g})().value(a=>a.value).sort(null)(c)},"createPieArcs"),E=(0,f.__name)((a,c,g,i)=>{f.log.debug("rendering pie chart\n"+a);let j=i.db,k=(0,e.getConfig2)(),l=(0,d.cleanAndMerge)(j.getConfig(),k.pie),m=(0,b.selectSvgElement)(c),o=m.append("g");o.attr("transform","translate(225,225)");let{themeVariables:p}=k,[q]=(0,d.parseFontSize)(p.pieOuterStrokeWidth);q??=2;let r=l.textPosition,s=(0,h.arc)().innerRadius(0).outerRadius(185),t=(0,h.arc)().innerRadius(185*r).outerRadius(185*r);o.append("circle").attr("cx",0).attr("cy",0).attr("r",185+q/2).attr("class","pieOuterCircle");let u=j.getSections(),v=D(u),w=[p.pie1,p.pie2,p.pie3,p.pie4,p.pie5,p.pie6,p.pie7,p.pie8,p.pie9,p.pie10,p.pie11,p.pie12],x=0;u.forEach(a=>{x+=a});let y=v.filter(a=>"0"!==(a.data.value/x*100).toFixed(0)),z=(0,n.scaleOrdinal)(w).domain([...u.keys()]);o.selectAll("mySlices").data(y).enter().append("path").attr("d",s).attr("fill",a=>z(a.data.label)).attr("class","pieCircle"),o.selectAll("mySlices").data(y).enter().append("text").text(a=>(a.data.value/x*100).toFixed(0)+"%").attr("transform",a=>"translate("+t.centroid(a)+")").style("text-anchor","middle").attr("class","slice");let A=o.append("text").text(j.getDiagramTitle()).attr("x",0).attr("y",-200).attr("class","pieTitleText"),B=[...u.entries()].map(([a,b])=>({label:a,value:b})),C=o.selectAll(".legend").data(B).enter().append("g").attr("class","legend").attr("transform",(a,b)=>"translate(216,"+(22*b-22*B.length/2)+")");C.append("rect").attr("width",18).attr("height",18).style("fill",a=>z(a.label)).style("stroke",a=>z(a.label)),C.append("text").attr("x",22).attr("y",14).text(a=>j.getShowData()?`${a.label} [${a.value}]`:a.label);let E=Math.max(...C.selectAll("text").nodes().map(a=>a?.getBoundingClientRect().width??0)),F=A.node()?.getBoundingClientRect().width??0,G=Math.min(0,225-F/2),H=Math.max(512+E,225+F/2)-G;m.attr("viewBox",`${G} 0 ${H} 450`),(0,e.configureSvgSize)(m,450,H,l.useMaxWidth)},"draw");a.s(["diagram",0,{parser:B,db:z,renderer:{draw:E},styles:C}],28018)},29250,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0mhr-tu._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(38362)))},72847,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__13fmof_._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(97253)))},24590,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0ico9~m._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(16311)))},15431,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0zb._6y._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46792)))},89536,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0a09w3z._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(18975)))},77468,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__00xeq7r._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(46595)))},43960,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__10s~ptn._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(48026)))},31415,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__0tlibqy._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(36952)))},1864,a=>{a.v(b=>Promise.all(["server/chunks/ssr/[root-of-the-server]__03zxnl6._.js","server/chunks/ssr/node_modules_0gvdioh._.js","server/chunks/ssr/node_modules_lodash-es_01jun1r._.js"].map(b=>a.l(b))).then(()=>b(6890)))}];
30
30
 
31
- //# sourceMappingURL=node_modules_0xp9nhx._.js.map
31
+ //# sourceMappingURL=node_modules_0~aiu12._.js.map
@@ -7,9 +7,9 @@ globalThis.__BUILD_MANIFEST = {
7
7
  "static/chunks/03~yq9q893hmn.js"
8
8
  ],
9
9
  "lowPriorityFiles": [
10
- "static/7x81GlNKt9yqIkeI7U1BX/_buildManifest.js",
11
- "static/7x81GlNKt9yqIkeI7U1BX/_ssgManifest.js",
12
- "static/7x81GlNKt9yqIkeI7U1BX/_clientMiddlewareManifest.js"
10
+ "static/ZcOuTrikuO_ZLaERk7FsW/_buildManifest.js",
11
+ "static/ZcOuTrikuO_ZLaERk7FsW/_ssgManifest.js",
12
+ "static/ZcOuTrikuO_ZLaERk7FsW/_clientMiddlewareManifest.js"
13
13
  ],
14
14
  "rootMainFiles": [
15
15
  "static/chunks/0mtq6r6l61k.f.js",
@@ -1 +1 @@
1
- <!DOCTYPE html><html lang="en" class="font-sans inter_b2991b2-module__9mH_6q__variable"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="/_next/static/chunks/0b90ys7wq-p.4.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/0mtq6r6l61k.f.js"/><script src="/_next/static/chunks/02i7dfk78~t~2.js" async=""></script><script src="/_next/static/chunks/0.76ju_ex-wmx.js" async=""></script><script src="/_next/static/chunks/11rs2-0jl1rzr.js" async=""></script><script src="/_next/static/chunks/turbopack-0s_.rdhg458.a.js" async=""></script><script src="/_next/static/chunks/0lxvbkhh7amha.js" async=""></script><script src="/_next/static/chunks/04ygsac3q3ar..js" async=""></script><script src="/_next/static/chunks/0rn1kcmsfzjmz.js" async=""></script><script src="/_next/static/chunks/026168y2bx0d~.js" async=""></script><meta name="robots" content="noindex"/><meta name="next-size-adjust" content=""/><title>404: This page could not be found.</title><title>繋</title><meta name="description" content="AI時代の統合開発マネージャー - Claude と人間のシームレスな協働開発を実現"/><link rel="icon" href="/icon.png?icon.0fkix7.hkmsz4.png" sizes="1024x1024" type="image/png"/><script src="/_next/static/chunks/03~yq9q893hmn.js" noModule=""></script></head><body class="geist_a71539c9-module__T19VSG__variable geist_mono_8d43a2aa-module__8Li5zG__variable antialiased"><div hidden=""><!--$--><!--/$--></div><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><!--$--><!--/$--><section aria-label="Notifications alt+T" tabindex="-1" aria-live="polite" aria-relevant="additions text" aria-atomic="false"></section><script src="/_next/static/chunks/0mtq6r6l61k.f.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[627,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"ThemeProvider\"]\n3:I[44142,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"UpdateStatusProvider\"]\n4:I[39756,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"default\"]\n5:I[37457,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"default\"]\n6:I[57787,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"ConnectionStatus\"]\n7:I[29024,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"ToastProvider\"]\n8:I[67570,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"EditorSessionProvider\"]\n9:I[97367,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"OutletBoundary\"]\na:\"$Sreact.suspense\"\nd:I[97367,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"ViewportBoundary\"]\nf:I[97367,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"MetadataBoundary\"]\n11:I[68027,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"default\",1]\n:HL[\"/_next/static/chunks/0b90ys7wq-p.4.css\",\"style\"]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"c\":[\"\",\"_not-found\"],\"q\":\"\",\"i\":false,\"f\":[[[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",16],[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/chunks/0b90ys7wq-p.4.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-0\",{\"src\":\"/_next/static/chunks/0lxvbkhh7amha.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-1\",{\"src\":\"/_next/static/chunks/04ygsac3q3ar..js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-2\",{\"src\":\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-3\",{\"src\":\"/_next/static/chunks/026168y2bx0d~.js\",\"async\":true,\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"en\",\"className\":\"font-sans inter_b2991b2-module__9mH_6q__variable\",\"children\":[\"$\",\"body\",null,{\"className\":\"geist_a71539c9-module__T19VSG__variable geist_mono_8d43a2aa-module__8Li5zG__variable antialiased\",\"children\":[\"$\",\"$L2\",null,{\"children\":[\"$\",\"$L3\",null,{\"children\":[[\"$\",\"$L4\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L5\",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\"}],[\"$\",\"$L6\",null,{}],[\"$\",\"$L7\",null,{}],[\"$\",\"$L8\",null,{}]]}]}]}]}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L4\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L5\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:0:props:children:1:props:children:props:children:props:children:props:children:0: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:0:props:children:1:props:children:props:children:props:children:props:children:0:props:notFound:0:1:props:children:props:children:1:props:style\",\"children\":404}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:0:props:children:1:props:children:props:children:props:children:props:children:0:props:notFound:0:1:props:children:props:children:2:props:style\",\"children\":[\"$\",\"h2\",null,{\"style\":\"$0:f:0:1:0:props:children:1:props:children:props:children:props:children:props:children:0:props:notFound:0:1:props:children:props:children:2:props:children:props:style\",\"children\":\"This page could not be found.\"}]}]]}]}]],null,[\"$\",\"$L9\",null,{\"children\":[\"$\",\"$a\",null,{\"name\":\"Next.MetadataOutlet\",\"children\":\"$@b\"}]}]]}],{},null,false,null]},null,false,\"$@c\"]},null,false,null],[\"$\",\"$1\",\"h\",{\"children\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],[\"$\",\"$Ld\",null,{\"children\":\"$Le\"}],[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$Lf\",null,{\"children\":[\"$\",\"$a\",null,{\"name\":\"Next.Metadata\",\"children\":\"$L10\"}]}]}],[\"$\",\"meta\",null,{\"name\":\"next-size-adjust\",\"content\":\"\"}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$11\",[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/chunks/0b90ys7wq-p.4.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}]]],\"S\":true,\"h\":null,\"s\":\"$undefined\",\"l\":\"$undefined\",\"p\":\"$undefined\",\"d\":\"$undefined\",\"b\":\"7x81GlNKt9yqIkeI7U1BX\"}\n"])</script><script>self.__next_f.push([1,"12:[]\nc:\"$W12\"\n"])</script><script>self.__next_f.push([1,"e:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\n"])</script><script>self.__next_f.push([1,"13:I[27201,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"IconMark\"]\nb:null\n10:[[\"$\",\"title\",\"0\",{\"children\":\"繋\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"AI時代の統合開発マネージャー - Claude と人間のシームレスな協働開発を実現\"}],[\"$\",\"link\",\"2\",{\"rel\":\"icon\",\"href\":\"/icon.png?icon.0fkix7.hkmsz4.png\",\"sizes\":\"1024x1024\",\"type\":\"image/png\"}],[\"$\",\"$L13\",\"3\",{}]]\n"])</script></body></html>
1
+ <!DOCTYPE html><html lang="en" class="font-sans inter_b2991b2-module__9mH_6q__variable"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="/_next/static/chunks/0pm0knaijueoc.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/0mtq6r6l61k.f.js"/><script src="/_next/static/chunks/02i7dfk78~t~2.js" async=""></script><script src="/_next/static/chunks/0.76ju_ex-wmx.js" async=""></script><script src="/_next/static/chunks/11rs2-0jl1rzr.js" async=""></script><script src="/_next/static/chunks/turbopack-0s_.rdhg458.a.js" async=""></script><script src="/_next/static/chunks/0lxvbkhh7amha.js" async=""></script><script src="/_next/static/chunks/04ygsac3q3ar..js" async=""></script><script src="/_next/static/chunks/0rn1kcmsfzjmz.js" async=""></script><script src="/_next/static/chunks/026168y2bx0d~.js" async=""></script><meta name="robots" content="noindex"/><meta name="next-size-adjust" content=""/><title>404: This page could not be found.</title><title>繋</title><meta name="description" content="AI時代の統合開発マネージャー - Claude と人間のシームレスな協働開発を実現"/><link rel="icon" href="/icon.png?icon.0fkix7.hkmsz4.png" sizes="1024x1024" type="image/png"/><script src="/_next/static/chunks/03~yq9q893hmn.js" noModule=""></script></head><body class="geist_a71539c9-module__T19VSG__variable geist_mono_8d43a2aa-module__8Li5zG__variable antialiased"><div hidden=""><!--$--><!--/$--></div><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><!--$--><!--/$--><section aria-label="Notifications alt+T" tabindex="-1" aria-live="polite" aria-relevant="additions text" aria-atomic="false"></section><script src="/_next/static/chunks/0mtq6r6l61k.f.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[627,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"ThemeProvider\"]\n3:I[44142,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"UpdateStatusProvider\"]\n4:I[39756,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"default\"]\n5:I[37457,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"default\"]\n6:I[57787,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"ConnectionStatus\"]\n7:I[29024,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"ToastProvider\"]\n8:I[67570,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"EditorSessionProvider\"]\n9:I[97367,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"OutletBoundary\"]\na:\"$Sreact.suspense\"\nd:I[97367,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"ViewportBoundary\"]\nf:I[97367,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"MetadataBoundary\"]\n11:I[68027,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"default\",1]\n:HL[\"/_next/static/chunks/0pm0knaijueoc.css\",\"style\"]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"c\":[\"\",\"_not-found\"],\"q\":\"\",\"i\":false,\"f\":[[[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",16],[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/chunks/0pm0knaijueoc.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-0\",{\"src\":\"/_next/static/chunks/0lxvbkhh7amha.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-1\",{\"src\":\"/_next/static/chunks/04ygsac3q3ar..js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-2\",{\"src\":\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-3\",{\"src\":\"/_next/static/chunks/026168y2bx0d~.js\",\"async\":true,\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"en\",\"className\":\"font-sans inter_b2991b2-module__9mH_6q__variable\",\"children\":[\"$\",\"body\",null,{\"className\":\"geist_a71539c9-module__T19VSG__variable geist_mono_8d43a2aa-module__8Li5zG__variable antialiased\",\"children\":[\"$\",\"$L2\",null,{\"children\":[\"$\",\"$L3\",null,{\"children\":[[\"$\",\"$L4\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L5\",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\"}],[\"$\",\"$L6\",null,{}],[\"$\",\"$L7\",null,{}],[\"$\",\"$L8\",null,{}]]}]}]}]}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L4\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L5\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:0:props:children:1:props:children:props:children:props:children:props:children:0: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:0:props:children:1:props:children:props:children:props:children:props:children:0:props:notFound:0:1:props:children:props:children:1:props:style\",\"children\":404}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:0:props:children:1:props:children:props:children:props:children:props:children:0:props:notFound:0:1:props:children:props:children:2:props:style\",\"children\":[\"$\",\"h2\",null,{\"style\":\"$0:f:0:1:0:props:children:1:props:children:props:children:props:children:props:children:0:props:notFound:0:1:props:children:props:children:2:props:children:props:style\",\"children\":\"This page could not be found.\"}]}]]}]}]],null,[\"$\",\"$L9\",null,{\"children\":[\"$\",\"$a\",null,{\"name\":\"Next.MetadataOutlet\",\"children\":\"$@b\"}]}]]}],{},null,false,null]},null,false,\"$@c\"]},null,false,null],[\"$\",\"$1\",\"h\",{\"children\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],[\"$\",\"$Ld\",null,{\"children\":\"$Le\"}],[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$Lf\",null,{\"children\":[\"$\",\"$a\",null,{\"name\":\"Next.Metadata\",\"children\":\"$L10\"}]}]}],[\"$\",\"meta\",null,{\"name\":\"next-size-adjust\",\"content\":\"\"}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$11\",[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/chunks/0pm0knaijueoc.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}]]],\"S\":true,\"h\":null,\"s\":\"$undefined\",\"l\":\"$undefined\",\"p\":\"$undefined\",\"d\":\"$undefined\",\"b\":\"ZcOuTrikuO_ZLaERk7FsW\"}\n"])</script><script>self.__next_f.push([1,"12:[]\nc:\"$W12\"\n"])</script><script>self.__next_f.push([1,"e:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\n"])</script><script>self.__next_f.push([1,"13:I[27201,[\"/_next/static/chunks/0lxvbkhh7amha.js\",\"/_next/static/chunks/04ygsac3q3ar..js\",\"/_next/static/chunks/0rn1kcmsfzjmz.js\",\"/_next/static/chunks/026168y2bx0d~.js\"],\"IconMark\"]\nb:null\n10:[[\"$\",\"title\",\"0\",{\"children\":\"繋\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"AI時代の統合開発マネージャー - Claude と人間のシームレスな協働開発を実現\"}],[\"$\",\"link\",\"2\",{\"rel\":\"icon\",\"href\":\"/icon.png?icon.0fkix7.hkmsz4.png\",\"sizes\":\"1024x1024\",\"type\":\"image/png\"}],[\"$\",\"$L13\",\"3\",{}]]\n"])</script></body></html>
@@ -1 +1 @@
1
- <!DOCTYPE html><html id="__next_error__"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/0mtq6r6l61k.f.js"/><script src="/_next/static/chunks/02i7dfk78~t~2.js" async=""></script><script src="/_next/static/chunks/0.76ju_ex-wmx.js" async=""></script><script src="/_next/static/chunks/11rs2-0jl1rzr.js" async=""></script><script src="/_next/static/chunks/turbopack-0s_.rdhg458.a.js" async=""></script><script src="/_next/static/chunks/0fsi8lw5utejl.js" async=""></script><script src="/_next/static/chunks/04ygsac3q3ar..js" async=""></script><meta name="next-size-adjust" content=""/><title>500: This page couldn’t load</title><style>:root {--next-error-bg: #fff;--next-error-text: #171717;--next-error-title: #171717;--next-error-message: #171717;--next-error-digest: #666666;--next-error-btn-text: #fff;--next-error-btn-bg: #171717;--next-error-btn-border: none;--next-error-btn-secondary-text: #171717;--next-error-btn-secondary-bg: transparent;--next-error-btn-secondary-border: 1px solid rgba(0,0,0,0.08);}@media (prefers-color-scheme: dark) {:root {--next-error-bg: #0a0a0a;--next-error-text: #ededed;--next-error-title: #ededed;--next-error-message: #ededed;--next-error-digest: #a0a0a0;--next-error-btn-text: #0a0a0a;--next-error-btn-bg: #ededed;--next-error-btn-border: none;--next-error-btn-secondary-text: #ededed;--next-error-btn-secondary-bg: transparent;--next-error-btn-secondary-border: 1px solid rgba(255,255,255,0.14);}}body { margin: 0; color: var(--next-error-text); background: var(--next-error-bg); }</style><script src="/_next/static/chunks/03~yq9q893hmn.js" noModule=""></script></head><body><div hidden=""><!--$--><!--/$--></div><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;display:flex;align-items:center;justify-content:center"><div style="margin-top:-32px;max-width:325px;padding:32px 28px;text-align:left"><svg width="32" height="32" viewBox="-0.2 -1.5 32 32" fill="none" style="margin-bottom:24px"><path d="M16.9328 0C18.0839 0.000116771 19.1334 0.658832 19.634 1.69531L31.4299 26.1309C32.0708 27.4588 31.1036 28.9999 29.6291 29H2.00215C0.527541 29 -0.439628 27.4588 0.201371 26.1309L11.9973 1.69531C12.4979 0.658823 13.5474 7.75066e-05 14.6984 0H16.9328ZM3.59493 26H28.0363L16.9328 3H14.6984L3.59493 26ZM15.8156 19C16.9202 19.0001 17.8156 19.8955 17.8156 21C17.8156 22.1045 16.9202 22.9999 15.8156 23C14.7111 23 13.8156 22.1046 13.8156 21C13.8156 19.8954 14.7111 19 15.8156 19ZM17.3156 16.5H14.3156V8.5H17.3156V16.5Z" fill="var(--next-error-title)"></path></svg><h1 style="font-size:24px;font-weight:500;letter-spacing:-0.02em;line-height:32px;margin:0 0 12px 0;color:var(--next-error-title)">This page couldn’t load</h1><p style="font-size:14px;font-weight:400;line-height:21px;margin:0 0 20px 0;color:var(--next-error-message)">A server error occurred. Reload to try again.</p><form style="margin:0"><button type="submit" style="display:inline-flex;align-items:center;justify-content:center;height:32px;padding:0 12px;font-size:14px;font-weight:500;line-height:20px;border-radius:6px;cursor:pointer;color:var(--next-error-btn-text);background:var(--next-error-btn-bg);border:var(--next-error-btn-border)">Reload</button></form></div></div><!--$--><!--/$--><script src="/_next/static/chunks/0mtq6r6l61k.f.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[39756,[\"/_next/static/chunks/0fsi8lw5utejl.js\",\"/_next/static/chunks/04ygsac3q3ar..js\"],\"default\"]\n3:I[37457,[\"/_next/static/chunks/0fsi8lw5utejl.js\",\"/_next/static/chunks/04ygsac3q3ar..js\"],\"default\"]\n4:I[97367,[\"/_next/static/chunks/0fsi8lw5utejl.js\",\"/_next/static/chunks/04ygsac3q3ar..js\"],\"OutletBoundary\"]\n5:\"$Sreact.suspense\"\n8:I[97367,[\"/_next/static/chunks/0fsi8lw5utejl.js\",\"/_next/static/chunks/04ygsac3q3ar..js\"],\"ViewportBoundary\"]\na:I[97367,[\"/_next/static/chunks/0fsi8lw5utejl.js\",\"/_next/static/chunks/04ygsac3q3ar..js\"],\"MetadataBoundary\"]\nc:I[68027,[\"/_next/static/chunks/0fsi8lw5utejl.js\",\"/_next/static/chunks/04ygsac3q3ar..js\"],\"default\",1]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"c\":[\"\",\"_global-error\"],\"q\":\"\",\"i\":false,\"f\":[[[\"\",{\"children\":[\"__PAGE__\",{}]}],[[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L2\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L3\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[[\"$\",\"html\",null,{\"id\":\"__next_error__\",\"children\":[[\"$\",\"head\",null,{\"children\":[[\"$\",\"title\",null,{\"children\":\"500: This page couldn’t load\"}],[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\":root {--next-error-bg: #fff;--next-error-text: #171717;--next-error-title: #171717;--next-error-message: #171717;--next-error-digest: #666666;--next-error-btn-text: #fff;--next-error-btn-bg: #171717;--next-error-btn-border: none;--next-error-btn-secondary-text: #171717;--next-error-btn-secondary-bg: transparent;--next-error-btn-secondary-border: 1px solid rgba(0,0,0,0.08);}@media (prefers-color-scheme: dark) {:root {--next-error-bg: #0a0a0a;--next-error-text: #ededed;--next-error-title: #ededed;--next-error-message: #ededed;--next-error-digest: #a0a0a0;--next-error-btn-text: #0a0a0a;--next-error-btn-bg: #ededed;--next-error-btn-border: none;--next-error-btn-secondary-text: #ededed;--next-error-btn-secondary-bg: transparent;--next-error-btn-secondary-border: 1px solid rgba(255,255,255,0.14);}}body { margin: 0; color: var(--next-error-text); background: var(--next-error-bg); }\"}}]]}],[\"$\",\"body\",null,{\"children\":[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"display\":\"flex\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"style\":{\"marginTop\":\"-32px\",\"maxWidth\":\"325px\",\"padding\":\"32px 28px\",\"textAlign\":\"left\"},\"children\":[[\"$\",\"svg\",null,{\"width\":\"32\",\"height\":\"32\",\"viewBox\":\"-0.2 -1.5 32 32\",\"fill\":\"none\",\"style\":{\"marginBottom\":\"24px\"},\"children\":[\"$\",\"path\",null,{\"d\":\"M16.9328 0C18.0839 0.000116771 19.1334 0.658832 19.634 1.69531L31.4299 26.1309C32.0708 27.4588 31.1036 28.9999 29.6291 29H2.00215C0.527541 29 -0.439628 27.4588 0.201371 26.1309L11.9973 1.69531C12.4979 0.658823 13.5474 7.75066e-05 14.6984 0H16.9328ZM3.59493 26H28.0363L16.9328 3H14.6984L3.59493 26ZM15.8156 19C16.9202 19.0001 17.8156 19.8955 17.8156 21C17.8156 22.1045 16.9202 22.9999 15.8156 23C14.7111 23 13.8156 22.1046 13.8156 21C13.8156 19.8954 14.7111 19 15.8156 19ZM17.3156 16.5H14.3156V8.5H17.3156V16.5Z\",\"fill\":\"var(--next-error-title)\"}]}],[\"$\",\"h1\",null,{\"style\":{\"fontSize\":\"24px\",\"fontWeight\":500,\"letterSpacing\":\"-0.02em\",\"lineHeight\":\"32px\",\"margin\":\"0 0 12px 0\",\"color\":\"var(--next-error-title)\"},\"children\":\"This page couldn’t load\"}],[\"$\",\"p\",null,{\"style\":{\"fontSize\":\"14px\",\"fontWeight\":400,\"lineHeight\":\"21px\",\"margin\":\"0 0 20px 0\",\"color\":\"var(--next-error-message)\"},\"children\":\"A server error occurred. Reload to try again.\"}],[\"$\",\"form\",null,{\"style\":{\"margin\":0},\"children\":[\"$\",\"button\",null,{\"type\":\"submit\",\"style\":{\"display\":\"inline-flex\",\"alignItems\":\"center\",\"justifyContent\":\"center\",\"height\":\"32px\",\"padding\":\"0 12px\",\"fontSize\":\"14px\",\"fontWeight\":500,\"lineHeight\":\"20px\",\"borderRadius\":\"6px\",\"cursor\":\"pointer\",\"color\":\"var(--next-error-btn-text)\",\"background\":\"var(--next-error-btn-bg)\",\"border\":\"var(--next-error-btn-border)\"},\"children\":\"Reload\"}]}]]}]}]}]]}],null,[\"$\",\"$L4\",null,{\"children\":[\"$\",\"$5\",null,{\"name\":\"Next.MetadataOutlet\",\"children\":\"$@6\"}]}]]}],{},null,false,null]},null,false,\"$@7\"],[\"$\",\"$1\",\"h\",{\"children\":[null,[\"$\",\"$L8\",null,{\"children\":\"$L9\"}],[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$La\",null,{\"children\":[\"$\",\"$5\",null,{\"name\":\"Next.Metadata\",\"children\":\"$Lb\"}]}]}],[\"$\",\"meta\",null,{\"name\":\"next-size-adjust\",\"content\":\"\"}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$c\",[]],\"S\":true,\"h\":null,\"s\":\"$undefined\",\"l\":\"$undefined\",\"p\":\"$undefined\",\"d\":\"$undefined\",\"b\":\"7x81GlNKt9yqIkeI7U1BX\"}\n"])</script><script>self.__next_f.push([1,"d:[]\n7:\"$Wd\"\n"])</script><script>self.__next_f.push([1,"9:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\n"])</script><script>self.__next_f.push([1,"6:null\nb:[]\n"])</script></body></html>
1
+ <!DOCTYPE html><html id="__next_error__"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/0mtq6r6l61k.f.js"/><script src="/_next/static/chunks/02i7dfk78~t~2.js" async=""></script><script src="/_next/static/chunks/0.76ju_ex-wmx.js" async=""></script><script src="/_next/static/chunks/11rs2-0jl1rzr.js" async=""></script><script src="/_next/static/chunks/turbopack-0s_.rdhg458.a.js" async=""></script><script src="/_next/static/chunks/0fsi8lw5utejl.js" async=""></script><script src="/_next/static/chunks/04ygsac3q3ar..js" async=""></script><meta name="next-size-adjust" content=""/><title>500: This page couldn’t load</title><style>:root {--next-error-bg: #fff;--next-error-text: #171717;--next-error-title: #171717;--next-error-message: #171717;--next-error-digest: #666666;--next-error-btn-text: #fff;--next-error-btn-bg: #171717;--next-error-btn-border: none;--next-error-btn-secondary-text: #171717;--next-error-btn-secondary-bg: transparent;--next-error-btn-secondary-border: 1px solid rgba(0,0,0,0.08);}@media (prefers-color-scheme: dark) {:root {--next-error-bg: #0a0a0a;--next-error-text: #ededed;--next-error-title: #ededed;--next-error-message: #ededed;--next-error-digest: #a0a0a0;--next-error-btn-text: #0a0a0a;--next-error-btn-bg: #ededed;--next-error-btn-border: none;--next-error-btn-secondary-text: #ededed;--next-error-btn-secondary-bg: transparent;--next-error-btn-secondary-border: 1px solid rgba(255,255,255,0.14);}}body { margin: 0; color: var(--next-error-text); background: var(--next-error-bg); }</style><script src="/_next/static/chunks/03~yq9q893hmn.js" noModule=""></script></head><body><div hidden=""><!--$--><!--/$--></div><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;display:flex;align-items:center;justify-content:center"><div style="margin-top:-32px;max-width:325px;padding:32px 28px;text-align:left"><svg width="32" height="32" viewBox="-0.2 -1.5 32 32" fill="none" style="margin-bottom:24px"><path d="M16.9328 0C18.0839 0.000116771 19.1334 0.658832 19.634 1.69531L31.4299 26.1309C32.0708 27.4588 31.1036 28.9999 29.6291 29H2.00215C0.527541 29 -0.439628 27.4588 0.201371 26.1309L11.9973 1.69531C12.4979 0.658823 13.5474 7.75066e-05 14.6984 0H16.9328ZM3.59493 26H28.0363L16.9328 3H14.6984L3.59493 26ZM15.8156 19C16.9202 19.0001 17.8156 19.8955 17.8156 21C17.8156 22.1045 16.9202 22.9999 15.8156 23C14.7111 23 13.8156 22.1046 13.8156 21C13.8156 19.8954 14.7111 19 15.8156 19ZM17.3156 16.5H14.3156V8.5H17.3156V16.5Z" fill="var(--next-error-title)"></path></svg><h1 style="font-size:24px;font-weight:500;letter-spacing:-0.02em;line-height:32px;margin:0 0 12px 0;color:var(--next-error-title)">This page couldn’t load</h1><p style="font-size:14px;font-weight:400;line-height:21px;margin:0 0 20px 0;color:var(--next-error-message)">A server error occurred. Reload to try again.</p><form style="margin:0"><button type="submit" style="display:inline-flex;align-items:center;justify-content:center;height:32px;padding:0 12px;font-size:14px;font-weight:500;line-height:20px;border-radius:6px;cursor:pointer;color:var(--next-error-btn-text);background:var(--next-error-btn-bg);border:var(--next-error-btn-border)">Reload</button></form></div></div><!--$--><!--/$--><script src="/_next/static/chunks/0mtq6r6l61k.f.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[39756,[\"/_next/static/chunks/0fsi8lw5utejl.js\",\"/_next/static/chunks/04ygsac3q3ar..js\"],\"default\"]\n3:I[37457,[\"/_next/static/chunks/0fsi8lw5utejl.js\",\"/_next/static/chunks/04ygsac3q3ar..js\"],\"default\"]\n4:I[97367,[\"/_next/static/chunks/0fsi8lw5utejl.js\",\"/_next/static/chunks/04ygsac3q3ar..js\"],\"OutletBoundary\"]\n5:\"$Sreact.suspense\"\n8:I[97367,[\"/_next/static/chunks/0fsi8lw5utejl.js\",\"/_next/static/chunks/04ygsac3q3ar..js\"],\"ViewportBoundary\"]\na:I[97367,[\"/_next/static/chunks/0fsi8lw5utejl.js\",\"/_next/static/chunks/04ygsac3q3ar..js\"],\"MetadataBoundary\"]\nc:I[68027,[\"/_next/static/chunks/0fsi8lw5utejl.js\",\"/_next/static/chunks/04ygsac3q3ar..js\"],\"default\",1]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"c\":[\"\",\"_global-error\"],\"q\":\"\",\"i\":false,\"f\":[[[\"\",{\"children\":[\"__PAGE__\",{}]}],[[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L2\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L3\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[[\"$\",\"html\",null,{\"id\":\"__next_error__\",\"children\":[[\"$\",\"head\",null,{\"children\":[[\"$\",\"title\",null,{\"children\":\"500: This page couldn’t load\"}],[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\":root {--next-error-bg: #fff;--next-error-text: #171717;--next-error-title: #171717;--next-error-message: #171717;--next-error-digest: #666666;--next-error-btn-text: #fff;--next-error-btn-bg: #171717;--next-error-btn-border: none;--next-error-btn-secondary-text: #171717;--next-error-btn-secondary-bg: transparent;--next-error-btn-secondary-border: 1px solid rgba(0,0,0,0.08);}@media (prefers-color-scheme: dark) {:root {--next-error-bg: #0a0a0a;--next-error-text: #ededed;--next-error-title: #ededed;--next-error-message: #ededed;--next-error-digest: #a0a0a0;--next-error-btn-text: #0a0a0a;--next-error-btn-bg: #ededed;--next-error-btn-border: none;--next-error-btn-secondary-text: #ededed;--next-error-btn-secondary-bg: transparent;--next-error-btn-secondary-border: 1px solid rgba(255,255,255,0.14);}}body { margin: 0; color: var(--next-error-text); background: var(--next-error-bg); }\"}}]]}],[\"$\",\"body\",null,{\"children\":[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"display\":\"flex\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"style\":{\"marginTop\":\"-32px\",\"maxWidth\":\"325px\",\"padding\":\"32px 28px\",\"textAlign\":\"left\"},\"children\":[[\"$\",\"svg\",null,{\"width\":\"32\",\"height\":\"32\",\"viewBox\":\"-0.2 -1.5 32 32\",\"fill\":\"none\",\"style\":{\"marginBottom\":\"24px\"},\"children\":[\"$\",\"path\",null,{\"d\":\"M16.9328 0C18.0839 0.000116771 19.1334 0.658832 19.634 1.69531L31.4299 26.1309C32.0708 27.4588 31.1036 28.9999 29.6291 29H2.00215C0.527541 29 -0.439628 27.4588 0.201371 26.1309L11.9973 1.69531C12.4979 0.658823 13.5474 7.75066e-05 14.6984 0H16.9328ZM3.59493 26H28.0363L16.9328 3H14.6984L3.59493 26ZM15.8156 19C16.9202 19.0001 17.8156 19.8955 17.8156 21C17.8156 22.1045 16.9202 22.9999 15.8156 23C14.7111 23 13.8156 22.1046 13.8156 21C13.8156 19.8954 14.7111 19 15.8156 19ZM17.3156 16.5H14.3156V8.5H17.3156V16.5Z\",\"fill\":\"var(--next-error-title)\"}]}],[\"$\",\"h1\",null,{\"style\":{\"fontSize\":\"24px\",\"fontWeight\":500,\"letterSpacing\":\"-0.02em\",\"lineHeight\":\"32px\",\"margin\":\"0 0 12px 0\",\"color\":\"var(--next-error-title)\"},\"children\":\"This page couldn’t load\"}],[\"$\",\"p\",null,{\"style\":{\"fontSize\":\"14px\",\"fontWeight\":400,\"lineHeight\":\"21px\",\"margin\":\"0 0 20px 0\",\"color\":\"var(--next-error-message)\"},\"children\":\"A server error occurred. Reload to try again.\"}],[\"$\",\"form\",null,{\"style\":{\"margin\":0},\"children\":[\"$\",\"button\",null,{\"type\":\"submit\",\"style\":{\"display\":\"inline-flex\",\"alignItems\":\"center\",\"justifyContent\":\"center\",\"height\":\"32px\",\"padding\":\"0 12px\",\"fontSize\":\"14px\",\"fontWeight\":500,\"lineHeight\":\"20px\",\"borderRadius\":\"6px\",\"cursor\":\"pointer\",\"color\":\"var(--next-error-btn-text)\",\"background\":\"var(--next-error-btn-bg)\",\"border\":\"var(--next-error-btn-border)\"},\"children\":\"Reload\"}]}]]}]}]}]]}],null,[\"$\",\"$L4\",null,{\"children\":[\"$\",\"$5\",null,{\"name\":\"Next.MetadataOutlet\",\"children\":\"$@6\"}]}]]}],{},null,false,null]},null,false,\"$@7\"],[\"$\",\"$1\",\"h\",{\"children\":[null,[\"$\",\"$L8\",null,{\"children\":\"$L9\"}],[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$La\",null,{\"children\":[\"$\",\"$5\",null,{\"name\":\"Next.Metadata\",\"children\":\"$Lb\"}]}]}],[\"$\",\"meta\",null,{\"name\":\"next-size-adjust\",\"content\":\"\"}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$c\",[]],\"S\":true,\"h\":null,\"s\":\"$undefined\",\"l\":\"$undefined\",\"p\":\"$undefined\",\"d\":\"$undefined\",\"b\":\"ZcOuTrikuO_ZLaERk7FsW\"}\n"])</script><script>self.__next_f.push([1,"d:[]\n7:\"$Wd\"\n"])</script><script>self.__next_f.push([1,"9:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\n"])</script><script>self.__next_f.push([1,"6:null\nb:[]\n"])</script></body></html>
@@ -1 +1 @@
1
- self.__RSC_SERVER_MANIFEST="{\n \"node\": {},\n \"edge\": {},\n \"encryptionKey\": \"4Mchz+Q2vJ5m3cy7jRDdv+WoQEVDWXaSQOApq29jQs8=\"\n}"
1
+ self.__RSC_SERVER_MANIFEST="{\n \"node\": {},\n \"edge\": {},\n \"encryptionKey\": \"cW3CQPpB4yU/R4bY8JSjweiupJO6DzTZ9Yc76X+RnmA=\"\n}"
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "node": {},
3
3
  "edge": {},
4
- "encryptionKey": "4Mchz+Q2vJ5m3cy7jRDdv+WoQEVDWXaSQOApq29jQs8="
4
+ "encryptionKey": "cW3CQPpB4yU/R4bY8JSjweiupJO6DzTZ9Yc76X+RnmA="
5
5
  }
@@ -0,0 +1,7 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,82341,e=>{"use strict";var t=e.i(18050),s=e.i(71645),a=e.i(18566),r=e.i(471),l=e.i(75254);let n=(0,l.default)("flask-conical",[["path",{d:"M14 2v6a2 2 0 0 0 .245.96l5.51 10.08A2 2 0 0 1 18 22H6a2 2 0 0 1-1.755-2.96l5.51-10.08A2 2 0 0 0 10 8V2",key:"18mbvz"}],["path",{d:"M6.453 15h11.094",key:"3shlmq"}],["path",{d:"M8.5 2h7",key:"csnxdl"}]]);var i=e.i(70935);let o=(0,l.default)("globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]),c=(0,l.default)("folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]);var d=e.i(55716),u=e.i(46349),u=u;let x=(0,l.default)("chevron-down",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);var m=e.i(85902);function h({node:e,isSelected:s,isExpanded:a,depth:r,onSelect:l,onToggle:n}){let i=e.children&&e.children.length>0;return(0,t.jsxs)("div",{onClick:()=>{l(),i&&n&&!a&&n()},className:`
2
+ flex items-center gap-2 px-2 py-1.5 rounded cursor-pointer
3
+ transition-colors
4
+ ${s?"bg-accent":"hover:bg-accent"}
5
+ `,style:{paddingLeft:`${16*r+8}px`},children:[i&&(0,t.jsx)(m.Button,{variant:"ghost",size:"icon-xs",onClick:e=>{e.stopPropagation(),n&&n()},className:"size-4",children:a?(0,t.jsx)(x,{className:"w-3 h-3 text-muted-foreground"}):(0,t.jsx)(u.default,{className:"w-3 h-3 text-muted-foreground"})}),!i&&(0,t.jsx)("div",{className:"w-3"}),(0,t.jsx)("div",{className:"text-foreground",children:(()=>{switch(e.type){case"global":return(0,t.jsx)(o,{className:"w-4 h-4"});case"owner":return(0,t.jsx)(c,{className:"w-4 h-4"});case"repo":return(0,t.jsx)(d.GitBranch,{className:"w-4 h-4"})}})()}),(0,t.jsx)("span",{className:"text-sm text-foreground truncate",children:e.label})]})}function p({selectedNode:e,onNodeSelect:a,refreshKey:r}){let[l,n]=(0,s.useState)([]),[o,c]=(0,s.useState)(new Set),[d,u]=(0,s.useState)(!0);(0,s.useEffect)(()=>{let e=localStorage.getItem("tsunagi:env-tree-expanded");if(e)try{let t=JSON.parse(e);c(new Set(t))}catch(e){console.error("Failed to parse expanded owners:",e)}},[]),(0,s.useEffect)(()=>{localStorage.setItem("tsunagi:env-tree-expanded",JSON.stringify([...o]))},[o]),(0,s.useEffect)(()=>{(async()=>{u(!0);try{let e=await fetch((0,i.apiUrl)("/api/owners"));if(!e.ok)throw Error("Failed to fetch owners");let t=((await e.json()).data.owners||[]).map(e=>({id:`owner:${e.name}`,type:"owner",label:e.name,scope:"owner",owner:e.name,children:e.repositories.map(e=>({id:`repo:${e.owner}/${e.repo}`,type:"repo",label:e.repo,scope:"repo",owner:e.owner,repo:e.repo}))}));n([{id:"global",type:"global",label:"Global",scope:"global"},...t])}catch(e){console.error("Failed to load tree:",e)}finally{u(!1)}})()},[r]);let x=(s,r=0)=>{let l=e?.scope===s.scope&&e?.owner===s.owner&&e?.repo===s.repo,n=o.has(s.id);return(0,t.jsxs)("div",{children:[(0,t.jsx)(h,{node:s,isSelected:l,isExpanded:n,depth:r,onSelect:()=>{a({scope:s.scope,owner:s.owner,repo:s.repo,label:s.label})},onToggle:()=>{var e;return e=s.id,void c(t=>{let s=new Set(t);return s.has(e)?s.delete(e):s.add(e),s})}}),n&&s.children?.map(e=>x(e,r+1))]},s.id)};return d?(0,t.jsx)("div",{className:"p-4 text-muted-foreground text-sm",children:"Loading..."}):0===l.length?(0,t.jsx)("div",{className:"p-4 text-muted-foreground text-sm",children:"No repositories found"}):(0,t.jsx)("div",{className:"h-full overflow-y-auto",children:(0,t.jsx)("div",{className:"p-2",children:l.map(e=>x(e))})})}var g=e.i(7233),f=e.i(37727),j=e.i(43531),v=e.i(86536);let N=(0,l.default)("eye-off",[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]]);var b=e.i(27612),y=e.i(88699),k=e.i(10012);function w({variable:e,onToggle:a,onDelete:r,onUpdate:l,isDeletable:n=!0}){let[i,o]=(0,s.useState)(!1),[c,d]=(0,s.useState)(!1),[u,x]=(0,s.useState)(!1),[h,p]=(0,s.useState)(e.value),g=async t=>{d(!0);try{await a(e.key,t.target.checked)}finally{d(!1)}},C=async()=>{await r(e.key)},S=async()=>{try{await l(e.key,h),x(!1)}catch(e){console.error("Failed to update variable:",e),alert("Failed to update variable")}};return(0,t.jsxs)("div",{className:"border border-border rounded p-3 space-y-2",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between",children:[(0,t.jsx)("span",{className:"text-sm font-mono text-foreground",children:e.key}),!u&&(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsxs)("label",{className:"flex items-center gap-2 cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",checked:e.enabled,onChange:g,disabled:c,className:"w-4 h-4 cursor-pointer"}),(0,t.jsx)("span",{className:"text-xs text-muted-foreground",children:"Enabled"})]}),(0,t.jsx)(m.Button,{variant:"ghost",size:"icon-lg",onClick:()=>o(!i),title:i?"Hide value":"Show value",children:i?(0,t.jsx)(N,{className:"w-4 h-4 text-muted-foreground"}):(0,t.jsx)(v.Eye,{className:"w-4 h-4 text-muted-foreground"})}),(0,t.jsx)(m.Button,{variant:"ghost",size:"icon-lg",onClick:()=>{x(!0),p(e.value)},title:"Edit",children:(0,t.jsx)(y.Pencil,{className:"w-4 h-4 text-muted-foreground"})}),n&&(0,t.jsx)(m.Button,{variant:"ghost",size:"icon-lg",onClick:C,title:"Delete",children:(0,t.jsx)(b.Trash2,{className:"w-4 h-4 text-destructive"})})]})]}),u?(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)(k.Input,{type:"password",value:h,onChange:e=>p(e.target.value),className:"w-full font-mono",autoFocus:!0}),(0,t.jsxs)("div",{className:"flex justify-end gap-2",children:[(0,t.jsx)(m.Button,{variant:"outline",size:"sm",onClick:()=>{x(!1),p(e.value)},className:"active:scale-95",children:(0,t.jsx)(f.X,{className:"w-4 h-4"})}),(0,t.jsx)(m.Button,{size:"sm",onClick:S,className:"active:scale-95",children:(0,t.jsx)(j.Check,{className:"w-4 h-4"})})]})]}):(0,t.jsx)("div",{children:(0,t.jsx)(k.Input,{type:i?"text":"password",value:e.value,readOnly:!0,className:"w-full font-mono"})})]})}var C=e.i(37870);let S=["ANTHROPIC_API_KEY","CLAUDE_CODE_OAUTH_TOKEN","CLAUDE_CONFIG_DIR","TSUNAGI_CLAUDE_PROFILE","CODEX_API_KEY","CODEX_ACCESS_TOKEN","CODEX_HOME","TSUNAGI_CODEX_PROFILE"];function L({selectedNode:e}){let[a,r]=(0,s.useState)([]),[l,n]=(0,s.useState)(!0),[o,c]=(0,s.useState)(null),[d,u]=(0,s.useState)(!1),[x,h]=(0,s.useState)(""),[p,v]=(0,s.useState)(""),[N,b]=(0,s.useState)("");(0,s.useEffect)(()=>{(async()=>{n(!0),c(null);try{let t=new URLSearchParams({scope:e.scope});e.owner&&t.set("owner",e.owner),e.repo&&t.set("repo",e.repo);let s=await fetch((0,i.apiUrl)(`/api/env/list?${t}`));if(!s.ok)throw Error("Failed to fetch environment variables");let a=await s.json();r(a.data.envVars||[])}catch(e){console.error("Failed to load environment variables:",e),c("Failed to load environment variables")}finally{n(!1)}})()},[e]);let y=async(t,s)=>{try{if(!(await fetch((0,i.apiUrl)("/api/env/toggle"),{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({key:t,scope:e.scope,owner:e.owner,repo:e.repo,enabled:s})})).ok)throw Error("Failed to toggle environment variable");r(e=>e.map(e=>e.key===t?{...e,enabled:s}:e))}catch(e){console.error("Failed to toggle environment variable:",e),r(e=>e.map(e=>e.key===t?{...e,enabled:!s}:e))}},E=async t=>{if(confirm(`Delete ${t}?`))try{let s=new URLSearchParams({key:t,scope:e.scope});if(e.owner&&s.set("owner",e.owner),e.repo&&s.set("repo",e.repo),!(await fetch((0,i.apiUrl)(`/api/env?${s}`),{method:"DELETE"})).ok)throw Error("Failed to delete environment variable");r(e=>e.filter(e=>e.key!==t))}catch(e){console.error("Failed to delete environment variable:",e),alert("Failed to delete environment variable")}},z=async(t,s)=>{try{if(!(await fetch((0,i.apiUrl)("/api/env"),{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({key:t,value:s,scope:e.scope,owner:e.owner,repo:e.repo})})).ok)throw Error("Failed to update environment variable");r(e=>e.map(e=>e.key===t?{...e,value:s}:e))}catch(e){throw console.error("Failed to update environment variable:",e),e}},M=async()=>{var t;if(b(""),!x.trim())return void b("Key is required");if(!p.trim())return void b("Value is required");if(t=x.trim(),/^[A-Z0-9_]+$/.test(t)?S.includes(t)?(b("エージェントの認証は Claude Profile / Codex Profile で設定してください"),!1):!a.some(e=>e.key===t)||(b(`Key "${t}" already exists in this scope`),!1):(b("Key must contain only uppercase letters, numbers, and underscores"),!1))try{if(!(await fetch((0,i.apiUrl)("/api/env"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({key:x.trim(),value:p.trim(),scope:e.scope,owner:e.owner,repo:e.repo})})).ok)throw Error("Failed to add environment variable");let t=new URLSearchParams({scope:e.scope});e.owner&&t.set("owner",e.owner),e.repo&&t.set("repo",e.repo);let s=await fetch((0,i.apiUrl)(`/api/env/list?${t}`));if(s.ok){let e=await s.json();r(e.data.envVars||[])}u(!1),h(""),v("")}catch(e){console.error("Failed to add environment variable:",e),b("Failed to add environment variable")}};return l?(0,t.jsx)("div",{className:"h-full flex items-center justify-center",children:(0,t.jsx)(C.LoadingSpinner,{size:"md",message:"Loading variables..."})}):o?(0,t.jsx)("div",{className:"h-full flex items-center justify-center",children:(0,t.jsx)("div",{className:"text-destructive text-sm",children:o})}):(0,t.jsxs)("div",{className:"h-full flex flex-col",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,t.jsx)("h2",{className:"text-lg font-bold text-foreground",children:"Environment Variables"}),!d&&(0,t.jsxs)(m.Button,{size:"sm",onClick:()=>u(!0),className:"active:scale-95",children:[(0,t.jsx)(g.Plus,{className:"w-4 h-4"}),"Add Variable"]})]}),(0,t.jsxs)("div",{className:"flex-1 overflow-y-auto space-y-3",children:[d&&(0,t.jsxs)("div",{className:"border border-border rounded p-3 bg-accent space-y-2",children:[(0,t.jsx)("div",{className:"text-sm font-medium text-foreground",children:"New Variable"}),(0,t.jsx)(k.Input,{type:"text",value:x,onChange:e=>h(e.target.value.toUpperCase()),placeholder:"VARIABLE_NAME",className:"w-full font-mono",autoFocus:!0}),(0,t.jsx)(k.Input,{type:"password",value:p,onChange:e=>v(e.target.value),placeholder:"value",className:"w-full font-mono"}),N&&(0,t.jsx)("div",{className:"text-xs text-destructive",children:N}),(0,t.jsxs)("div",{className:"flex justify-end gap-2",children:[(0,t.jsx)(m.Button,{variant:"outline",size:"sm",onClick:()=>{u(!1),h(""),v(""),b("")},className:"active:scale-95",children:(0,t.jsx)(f.X,{className:"w-4 h-4"})}),(0,t.jsx)(m.Button,{size:"sm",onClick:M,className:"active:scale-95",children:(0,t.jsx)(j.Check,{className:"w-4 h-4"})})]})]}),0!==a.length||d?a.map(e=>(0,t.jsx)(w,{variable:e,onToggle:y,onDelete:E,onUpdate:z,isDeletable:!0},e.key)):(0,t.jsx)("div",{className:"text-center text-muted-foreground text-sm py-4",children:"No environment variables"})]})]})}var E=e.i(61653),E=E;let z=(0,l.default)("log-in",[["path",{d:"m10 17 5-5-5-5",key:"1bsop3"}],["path",{d:"M15 12H3",key:"6jk70r"}],["path",{d:"M15 3h4a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-4",key:"u53s6r"}]]),M=(0,l.default)("user-round",[["circle",{cx:"12",cy:"8",r:"5",key:"1hypcn"}],["path",{d:"M20 21a8 8 0 0 0-16 0",key:"rfgkzh"}]]);var $=e.i(57024),O=e.i(68995),P=e.i(1048),I=e.i(67211),u=u;async function T(e,t){let s=await fetch((0,i.apiUrl)(e),t),a=await s.json().catch(()=>null);if(!s.ok||a?.data===void 0)throw Error(a?.error||`HTTPエラー: ${s.status}`);return a.data}function B(e,t){return T(e,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)})}function D(e){return e instanceof Error?e.message:String(e)}function U({children:e}){return(0,t.jsx)("div",{className:"flex flex-wrap items-center gap-2 rounded-md border border-border bg-muted/30 px-3 py-2 text-sm",children:e})}function _({label:e,hint:s,children:a}){return(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"mb-1 block text-xs font-medium text-muted-foreground",children:e}),a,s&&(0,t.jsx)("p",{className:"mt-1 text-[0.65rem] text-muted-foreground",children:s})]})}function A({children:e}){let[a,r]=(0,s.useState)(!1);return(0,t.jsxs)("div",{children:[(0,t.jsxs)("button",{type:"button",onClick:()=>r(e=>!e),className:"flex items-center gap-1 text-xs font-medium text-muted-foreground transition-colors hover:text-foreground",children:[(0,t.jsx)(u.default,{className:`size-3.5 transition-transform ${a?"rotate-90":""}`}),"詳細設定"]}),a&&(0,t.jsx)("div",{className:"mt-3 flex flex-col gap-3 border-l border-border pl-3",children:e})]})}function F({children:e}){return(0,t.jsx)("code",{className:"rounded bg-muted px-1",children:e})}let R={claude:"ブラウザで認証してください。ブラウザが開かない場合は表示された URL を開き、表示されたコードをこのターミナルに貼り付けます。",codex:"ブラウザで認証してください。ブラウザが開かない場合は表示された URL を開きます。ログイン済みの場合、今のログインはこの時点で解除されています。"};function G({sessionId:e}){let[a,r]=(0,s.useState)(""),[l,n]=(0,s.useState)(!1),[i,o]=(0,s.useState)(null);return(0,t.jsxs)("form",{onSubmit:t=>{t.preventDefault(),n(!0),o(null),T(`/api/agent-profiles/login/${e}/callback`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({url:a})}).then(()=>r("")).catch(e=>o(D(e))).finally(()=>n(!1))},className:"space-y-1",children:[(0,t.jsx)("p",{className:"text-xs text-muted-foreground",children:"認証後にブラウザが 127.0.0.1 のページを開けなかったら、そのアドレスバーの URL を貼り付けてください。"}),(0,t.jsxs)("div",{className:"flex gap-2",children:[(0,t.jsx)(k.Input,{value:a,onChange:e=>r(e.target.value),placeholder:"http://127.0.0.1:1455/auth/callback?code=...","aria-label":"Callback URL"}),(0,t.jsx)(m.Button,{type:"submit",disabled:!a.trim()||l,children:"Submit"})]}),i&&(0,t.jsx)("p",{className:"text-xs text-destructive",children:i})]})}function X({profile:e,onClose:a}){let[r,l]=(0,s.useState)(null),n=r?.sessionId??null,[o,c]=(0,s.useState)(null),[d,u]=(0,s.useState)(null);(0,s.useEffect)(()=>{let t=null,s=!1;return T(`/api/agent-profiles/${e.agent}/${e.slug}/login`,{method:"POST"}).then(e=>{(t=e.sessionId,s)?fetch((0,i.apiUrl)(`/api/agent-profiles/login/${t}`),{method:"DELETE"}):l(e)}).catch(e=>c(D(e))),()=>{s=!0,t&&fetch((0,i.apiUrl)(`/api/agent-profiles/login/${t}`),{method:"DELETE"})}},[e.agent,e.slug]);let x=d?.loggedIn??!1;return(0,s.useEffect)(()=>{if(!n||x)return;let t=setInterval(()=>{T(`/api/agent-profiles/${e.agent}/${e.slug}/status`).then(t=>{t.status.loggedIn&&!e.status.loggedIn&&u(t.status)}).catch(()=>void 0)},2e3);return()=>clearInterval(t)},[n,x,e.agent,e.slug,e.status.loggedIn]),(0,t.jsx)(O.Dialog,{open:!0,onOpenChange:e=>{e.open||a()},title:`Login: ${e.name}`,maxWidth:"4xl",children:(0,t.jsxs)("div",{className:"space-y-3",children:[x&&d?(0,t.jsxs)("div",{className:"flex items-center gap-2 rounded-md border border-success/30 bg-success/10 px-3 py-2 text-sm text-success",children:[(0,t.jsx)(P.CircleCheck,{className:"size-4"}),(0,t.jsxs)("span",{className:"flex-1",children:["Logged in",d.email?` as ${d.email}`:"",d.orgName?` (${d.orgName})`:""]}),(0,t.jsx)(m.Button,{size:"sm",onClick:a,children:"Done"})]}):(0,t.jsxs)("p",{className:"text-xs text-muted-foreground",children:[R[e.agent],e.status.loggedIn&&" 再ログインが終わったら閉じてください。"]}),!x&&r?.callbackPaste&&(0,t.jsx)(G,{sessionId:r.sessionId}),(0,t.jsx)("div",{className:"h-[420px] overflow-hidden rounded-md border border-border",children:o?(0,t.jsx)("div",{className:"flex h-full items-center justify-center text-sm text-destructive",children:o}):n?(0,t.jsx)(I.TerminalView,{tabId:n,hideToolbar:!0,isActive:!0}):(0,t.jsx)("div",{className:"flex h-full items-center justify-center",children:(0,t.jsx)(C.LoadingSpinner,{size:"sm",message:"Starting..."})})})]})})}let H="default",V={claude:{label:"Claude",configDirEnv:"CLAUDE_CONFIG_DIR",defaultConfigDir:"~/.claude",loginCommand:"claude auth login"},codex:{label:"Codex",configDirEnv:"CODEX_HOME",defaultConfigDir:"~/.codex",loginCommand:"codex login"}},q=/^[A-Za-z0-9 _-]+$/;function W(e){return e.trim().replace(/\s+/g,"-").toLowerCase()}function K({agent:e,selectedNode:a}){let r,l=V[e],n=`${l.label} Profile`,[o,c]=(0,s.useState)(null),[d,u]=(0,s.useState)(null),[x,h]=(0,s.useState)(null),[p,v]=(0,s.useState)(!1),[N,y]=(0,s.useState)(""),[w,S]=(0,s.useState)(null),[L,P]=(0,s.useState)(null),I="global"===a.scope,B=(0,s.useCallback)(async()=>{try{let t=await T(`/api/agent-profiles/${e}`);c(t.profiles)}catch(e){h(D(e))}},[e]),U=(0,s.useCallback)(async()=>{try{let t,s=await T(`/api/agent-profiles/${e}/assignment?${(t=new URLSearchParams({scope:a.scope}),a.owner&&t.set("owner",a.owner),a.repo&&t.set("repo",a.repo),t.toString())}`);u(s.assignment)}catch(e){h(D(e))}},[e,a]);(0,s.useEffect)(()=>{B()},[B]),(0,s.useEffect)(()=>{u(null),U()},[U]);let A=async t=>{try{let s=await T(`/api/agent-profiles/${e}/assignment`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({scope:a.scope,owner:a.owner,repo:a.repo,slug:""===t?null:t})});u(s.assignment)}catch(e){$.toaster.create({type:"error",title:"プロファイルを変更できません",description:D(e)})}},R=async()=>{try{let t=await T(`/api/agent-profiles/${e}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:N.trim()})});v(!1),y(""),await B(),S(t.profile.slug)}catch(e){$.toaster.create({type:"error",title:"プロファイルを追加できません",description:D(e)})}},G=async t=>{try{let s=await fetch((0,i.apiUrl)(`/api/agent-profiles/${e}/${t.slug}`),{method:"DELETE"});if(!s.ok)throw Error(`HTTPエラー: ${s.status}`);await Promise.all([B(),U()])}catch(e){$.toaster.create({type:"error",title:"プロファイルを削除できません",description:D(e)})}};if(x)return(0,t.jsxs)("section",{className:"space-y-3",children:[(0,t.jsx)("h2",{className:"text-lg font-bold text-foreground",children:n}),(0,t.jsx)("p",{className:"text-sm text-destructive",children:x})]});if(!o||!d)return(0,t.jsxs)("section",{className:"space-y-3",children:[(0,t.jsx)("h2",{className:"text-lg font-bold text-foreground",children:n}),(0,t.jsx)(C.LoadingSpinner,{size:"sm",message:"Loading profiles..."})]});let J=function(e,t){let s=e.trim();if(!s)return null;if(!q.test(s))return'Use only letters, numbers, spaces, "-" and "_"';let a=W(s);return t.some(e=>e.slug===a)?`"${a}" already exists`:null}(N,o),Y=o.find(e=>e.slug===w);return(0,t.jsxs)("section",{className:"space-y-3",children:[(0,t.jsx)("h2",{className:"text-lg font-bold text-foreground",children:n}),(0,t.jsx)(_,{label:I?"Default profile":"Profile for this scope",hint:`このスコープのタスクのターミナル・${l.label} で使うアカウント。変更は開いているタブにも自動で反映されます`,children:(0,t.jsxs)("select",{value:d.assigned??"",onChange:e=>void A(e.target.value),className:"h-9 w-full rounded-md border border-input bg-transparent pl-3 pr-10 text-sm text-foreground shadow-xs",children:[!I&&(0,t.jsxs)("option",{value:"",children:["Inherit (",(r=d.effective,o.find(e=>e.slug===r)?.name??r),")"]}),o.map(e=>(0,t.jsx)("option",{value:I&&e.slug===H?"":e.slug,children:e.name},e.slug))]})}),I&&(0,t.jsxs)("div",{className:"space-y-2",children:[o.map(e=>{var s;return(0,t.jsxs)("div",{className:"flex items-center justify-between gap-2 rounded-md border border-border p-3",children:[(0,t.jsxs)("div",{className:"flex min-w-0 items-center gap-3",children:[(0,t.jsx)(M,{className:"size-4 shrink-0 text-muted-foreground"}),(0,t.jsxs)("div",{className:"min-w-0",children:[(0,t.jsx)("div",{className:"text-sm font-medium text-foreground",children:e.name}),(0,t.jsxs)("div",{className:"flex items-center gap-1 truncate text-xs text-muted-foreground",children:[e.status.loggedIn?(0,t.jsx)(j.Check,{className:"size-3 shrink-0 text-success"}):(0,t.jsx)(E.default,{className:"size-3 shrink-0 text-warning"}),(0,t.jsx)("span",{className:"truncate",children:(s=e.status).loggedIn?[s.email,s.orgName??s.subscriptionType].filter(Boolean).join(" · ")||s.authMethod||"Logged in":"Not logged in"})]}),(0,t.jsx)("div",{className:"truncate text-[0.65rem] text-muted-foreground",children:(0,t.jsx)(F,{children:e.configDir??`${l.configDirEnv} 未指定(${l.defaultConfigDir})`})})]})]}),(0,t.jsxs)("div",{className:"flex shrink-0 items-center gap-1",children:[(0,t.jsxs)(m.Button,{variant:e.status.loggedIn?"ghost":"default",size:"sm",onClick:()=>S(e.slug),title:l.loginCommand,children:[(0,t.jsx)(z,{className:"size-4"}),e.status.loggedIn?"Re-login":"Login"]}),e.slug!==H&&(0,t.jsx)(m.Button,{variant:"ghost",size:"icon",onClick:()=>P(e),className:"hover:bg-destructive/10",title:"Delete",children:(0,t.jsx)(b.Trash2,{className:"size-4 text-destructive"})})]})]},e.slug)}),p?(0,t.jsxs)("div",{className:"space-y-2 rounded-md border border-border bg-accent p-3",children:[(0,t.jsx)(k.Input,{value:N,onChange:e=>y(e.target.value),onKeyDown:e=>{"Enter"===e.key&&N.trim()&&!J&&R()},placeholder:"Profile name (e.g. work)",autoFocus:!0}),J?(0,t.jsx)("p",{className:"text-xs text-destructive",children:J}):N.trim()&&(0,t.jsx)("p",{className:"text-xs text-muted-foreground",children:(0,t.jsxs)(F,{children:["~/.tsunagi/",e,"-profiles/",W(N)]})}),(0,t.jsxs)("div",{className:"flex justify-end gap-2",children:[(0,t.jsx)(m.Button,{variant:"outline",size:"sm",onClick:()=>{v(!1),y("")},children:(0,t.jsx)(f.X,{className:"size-4"})}),(0,t.jsx)(m.Button,{size:"sm",onClick:()=>void R(),disabled:!N.trim()||!!J,children:(0,t.jsx)(j.Check,{className:"size-4"})})]})]}):(0,t.jsxs)(m.Button,{variant:"outline",size:"sm",onClick:()=>v(!0),children:[(0,t.jsx)(g.Plus,{className:"size-4"}),"Add Profile"]})]}),Y&&(0,t.jsx)(X,{profile:Y,onClose:()=>{S(null),B()}}),(0,t.jsx)(O.ConfirmDialog,{open:null!==L,onOpenChange:e=>{e.open||P(null)},title:"Delete Profile",message:L?`${L.name} からログアウトし、${L.configDir} を削除します。このプロファイルを使っているスコープは親の設定を継承します。`:"",confirmLabel:"Delete",variant:"danger",onConfirm:()=>{L&&G(L)}})]})}let J=(0,l.default)("chevron-up",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);var Y=e.i(5352);function Z(){let[e,a]=(0,s.useState)([]),[r,l]=(0,s.useState)({}),[n,o]=(0,s.useState)(null),[c,d]=(0,s.useState)(!1),[u,h]=(0,s.useState)(!1),p=(0,s.useCallback)(async()=>{try{let[e,t]=await Promise.all([fetch((0,i.apiUrl)("/api/repos")).then(e=>e.json()),fetch((0,i.apiUrl)("/api/tasks")).then(e=>e.json())]);a(e.data??[]);let s={};for(let e of t.data?.tasks??[]){let t=`${e.owner}/${e.repo}`;s[t]=(s[t]??0)+1}l(s)}catch(e){console.error("Failed to load repositories:",e)}},[]);(0,s.useEffect)(()=>{p()},[p]);let g=async()=>{if(n){d(!0);try{if(!(await fetch((0,i.apiUrl)(`/api/repos/${n.owner}/${n.repo}`),{method:"DELETE"})).ok)throw Error("Failed to delete repository");await p()}catch(e){console.error("Failed to delete repository:",e)}finally{d(!1),o(null)}}},f=(0,s.useCallback)(async(t,s)=>{let r=t+s;if(r<0||r>=e.length)return;let l=[...e];[l[t],l[r]]=[l[r],l[t]],a(l.map((e,t)=>({...e,order:t}))),h(!0);try{if(!(await fetch((0,i.apiUrl)("/api/repos/reorder"),{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({repoIds:l.map(e=>e.id)})})).ok)throw Error("Failed to reorder repositories")}catch(e){console.error("Failed to reorder repositories:",e),await p()}finally{h(!1)}},[e,p]);return 0===e.length?(0,t.jsx)("div",{className:"text-sm text-muted-foreground",children:"No repositories cloned yet."}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(O.ConfirmDialog,{open:null!==n,onOpenChange:e=>{e.open||o(null)},title:"Delete Repository",message:n?`Delete ${n.owner}/${n.repo}? This will also delete ${r[`${n.owner}/${n.repo}`]??0} associated task(s), all worktrees, and the bare repository. This action cannot be undone.`:"",confirmLabel:c?"Deleting...":"Delete",cancelLabel:"Cancel",onConfirm:g,variant:"danger"}),(0,t.jsx)("p",{className:"text-xs text-muted-foreground",children:"この並び順がトップページの列の並び順になります"}),(0,t.jsx)("div",{className:"space-y-2",children:e.map((s,a)=>{let l=`${s.owner}/${s.repo}`,n=(0,Y.getRepoColor)(s.owner,s.repo),i=r[l]??0;return(0,t.jsxs)("div",{className:"flex items-center justify-between gap-2 rounded-md border border-border p-3",children:[(0,t.jsxs)("div",{className:"flex min-w-0 items-center gap-3",children:[(0,t.jsx)("span",{className:`inline-flex items-center rounded-full px-2.5 py-0.5 text-xs font-medium ${n.bg} ${n.text}`,children:l}),(0,t.jsxs)("span",{className:"text-xs text-muted-foreground whitespace-nowrap",children:[i," task",1!==i?"s":""]})]}),(0,t.jsxs)("div",{className:"flex flex-shrink-0 items-center",children:[(0,t.jsx)(m.Button,{variant:"ghost",size:"icon",onClick:()=>f(a,-1),disabled:0===a||u,className:"text-muted-foreground",title:"Move up",children:(0,t.jsx)(J,{className:"size-4"})}),(0,t.jsx)(m.Button,{variant:"ghost",size:"icon",onClick:()=>f(a,1),disabled:a===e.length-1||u,className:"text-muted-foreground",title:"Move down",children:(0,t.jsx)(x,{className:"size-4"})}),(0,t.jsx)(m.Button,{variant:"ghost",size:"icon",onClick:()=>o(s),className:"text-muted-foreground hover:text-destructive",title:"Delete repository",children:(0,t.jsx)(b.Trash2,{className:"size-4"})})]})]},s.id)})})]})}var Q=e.i(69068);function ee({owner:e,repo:a,onDeleted:r}){let[l,n]=(0,s.useState)(!1),[o,c]=(0,s.useState)(""),[d,u]=(0,s.useState)(!1),x=`${e}/${a}`,h=o===x,p=async()=>{if(h){u(!0);try{if(!(await fetch((0,i.apiUrl)(`/api/repos/${e}/${a}`),{method:"DELETE"})).ok)throw Error("Failed to delete repository");r()}catch(e){console.error("Failed to delete repository:",e)}finally{u(!1),n(!1),c("")}}};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("div",{className:"rounded-md border border-destructive/30 p-4 space-y-3",children:[(0,t.jsxs)("div",{className:"space-y-1",children:[(0,t.jsx)("h3",{className:"text-sm font-semibold text-destructive",children:"Remove Repository"}),(0,t.jsx)("p",{className:"text-xs text-muted-foreground",children:"Remove this repository and all associated data including tasks, worktrees, and environment variables. This action cannot be undone."})]}),(0,t.jsxs)(m.Button,{variant:"destructive",size:"sm",onClick:()=>n(!0),children:[(0,t.jsx)(b.Trash2,{className:"size-4"}),"Remove Repository"]})]}),(0,t.jsx)(Q.Dialog,{open:l,onOpenChange:n,children:(0,t.jsxs)(Q.DialogContent,{showCloseButton:!1,children:[(0,t.jsxs)(Q.DialogHeader,{children:[(0,t.jsx)(Q.DialogTitle,{children:"Remove Repository"}),(0,t.jsxs)(Q.DialogDescription,{children:["This will permanently delete ",(0,t.jsx)("strong",{children:x})," and all associated tasks, worktrees, and environment variables."]})]}),(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsxs)("label",{className:"text-xs text-muted-foreground",children:["Type ",(0,t.jsx)("strong",{children:x})," to confirm"]}),(0,t.jsx)(k.Input,{value:o,onChange:e=>c(e.target.value),placeholder:x,autoComplete:"off"})]}),(0,t.jsxs)(Q.DialogFooter,{children:[(0,t.jsx)(m.Button,{variant:"outline",size:"sm",onClick:()=>{n(!1),c("")},disabled:d,children:"Cancel"}),(0,t.jsx)(m.Button,{variant:"destructive",size:"sm",onClick:p,disabled:!h||d,children:d?"Removing...":"Remove"})]})]})})]})}var et=e.i(63209),es=e.i(95468);let ea=(0,l.default)("circle-question-mark",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);var er=e.i(31278),el=e.i(87951);let en=(0,l.default)("square",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}]]);var ei=e.i(52088);function eo({className:e,size:s="default",...a}){return(0,t.jsx)("div",{"data-slot":"card","data-size":s,className:(0,ei.cn)("group/card flex flex-col gap-4 overflow-hidden rounded-lg bg-card py-4 text-xs/relaxed text-card-foreground ring-1 ring-foreground/10 has-[>img:first-child]:pt-0 data-[size=sm]:gap-3 data-[size=sm]:py-3 *:[img:first-child]:rounded-t-lg *:[img:last-child]:rounded-b-lg",e),...a})}function ec({className:e,...s}){return(0,t.jsx)("div",{"data-slot":"card-header",className:(0,ei.cn)("group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-lg px-4 group-data-[size=sm]/card:px-3 has-data-[slot=card-action]:grid-cols-[1fr_auto] has-data-[slot=card-description]:grid-rows-[auto_auto] [.border-b]:pb-4 group-data-[size=sm]/card:[.border-b]:pb-3",e),...s})}function ed({className:e,...s}){return(0,t.jsx)("div",{"data-slot":"card-title",className:(0,ei.cn)("font-heading text-sm font-medium",e),...s})}function eu({className:e,...s}){return(0,t.jsx)("div",{"data-slot":"card-description",className:(0,ei.cn)("text-xs/relaxed text-muted-foreground",e),...s})}function ex({className:e,...s}){return(0,t.jsx)("div",{"data-slot":"card-content",className:(0,ei.cn)("px-4 group-data-[size=sm]/card:px-3",e),...s})}var em=e.i(77814),eh=e.i(41247);let ep=(0,l.default)("download",[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]]);var eg=e.i(7347);let ef=["running","running_external"];function ej(e){return`${(e/0x40000000).toFixed(1)} GB`}async function ev(e,t){let s=await fetch((0,i.apiUrl)(e),t),a=await s.json().catch(()=>null);if(!s.ok||!a?.data)throw Error(a?.error||`HTTPエラー: ${s.status}`);return a.data}function eN({serverInfo:e,onServerChanged:a}){let[r,l]=(0,s.useState)(null),[n,i]=(0,s.useState)(null),o=(0,s.useCallback)(async()=>{try{l(await ev("/api/whisper/models"))}catch(e){console.error("Failed to fetch ASR models:",e)}},[]),c=e?.step;(0,s.useEffect)(()=>{o()},[o,c]);let d=(0,s.useCallback)(async(e,t,s,r)=>{i(e);try{l(await ev(t,s)),a()}catch(e){$.toaster.create({type:"error",title:r,description:e instanceof Error?e.message:String(e)})}finally{i(null)}},[a]),u=(0,s.useCallback)(e=>d(e.id,"/api/whisper/models/selected",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({modelId:e.id})},"モデルを切り替えられませんでした"),[d]),x=(0,s.useCallback)(e=>d(e.id,`/api/whisper/models/${encodeURIComponent(e.id)}`,{method:"DELETE"},"モデルを削除できませんでした"),[d]);if(!r)return(0,t.jsxs)("span",{className:"flex items-center gap-2 text-xs text-muted-foreground",children:[(0,t.jsx)(er.Loader2,{className:"size-4 animate-spin"}),"モデル一覧を読み込み中..."]});let h=null!==e&&!ef.includes(e.step),p=null!==n||e?.step==="downloading_model";return(0,t.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,t.jsx)("span",{className:"text-xs font-medium text-muted-foreground",children:"音声認識モデル"}),r.models.map(s=>{let a=s.id===r.selectedModelId,l=e?.modelId===s.id&&ef.includes(e.step),i=e?.modelId===s.id&&"downloading_model"===e.step,o=i?e?.downloadProgress:void 0,c=e?.modelId===s.id;return(0,t.jsxs)("div",{className:(0,ei.cn)("flex flex-col gap-2 rounded-md border p-3 transition-colors duration-[130ms]",a?"border-primary bg-accent/40":"border-border"),children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsxs)("button",{type:"button",className:"flex min-w-0 flex-1 items-center gap-2 text-left disabled:cursor-not-allowed",onClick:()=>void u(s),disabled:a||p,children:[(0,t.jsx)("span",{className:(0,ei.cn)("size-3.5 shrink-0 rounded-full border",a?"border-4 border-primary":"border-input")}),(0,t.jsx)("span",{className:"truncate text-sm font-medium",children:s.label})]}),(0,t.jsx)("span",{className:"text-muted-foreground",title:`${s.description}
6
+ ライセンス: ${s.license}
7
+ ${s.repo}`,children:(0,t.jsx)(ea,{className:"size-4"})}),(0,t.jsx)("span",{className:"text-xs text-muted-foreground",children:ej(s.expectedBytes)}),l?(0,t.jsxs)(eg.Badge,{variant:"default",children:[(0,t.jsx)(es.CheckCircle2,{}),"使用中"]}):s.installed?(0,t.jsx)(eg.Badge,{variant:"secondary",children:"取得済み"}):(0,t.jsxs)(eg.Badge,{variant:"outline",title:"選択して起動すると自動でダウンロードされます",children:[(0,t.jsx)(ep,{}),"未取得"]}),s.installed&&!c&&(0,t.jsx)(m.Button,{variant:"ghost",size:"icon-sm",onClick:()=>void x(s),disabled:p,title:"ダウンロード済みのモデルを削除",children:(0,t.jsx)(b.Trash2,{})}),n===s.id&&(0,t.jsx)(er.Loader2,{className:"size-4 animate-spin"})]}),o&&(0,t.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,t.jsx)(em.Progress,{value:o.downloadedBytes/o.totalBytes*100}),(0,t.jsxs)("span",{className:"text-[0.65rem] text-muted-foreground",children:[ej(o.downloadedBytes)," / ",ej(o.totalBytes)]})]}),a&&h&&e?.modelId===s.id&&!i&&(0,t.jsxs)("span",{className:"flex items-center gap-2 text-[0.65rem] text-muted-foreground",children:[(0,t.jsx)(er.Loader2,{className:"size-3 animate-spin"}),"準備中..."]})]},s.id)}),(0,t.jsx)("p",{className:"text-[0.65rem] text-muted-foreground",children:"サーバー起動中に切り替えると、選択したモデルで再起動します(未取得の場合はダウンロードから行います)。"})]})}var eb=e.i(19728);let ey={not_running:"停止中",installing_deps:"依存関係をインストール中...",downloading_model:"モデルをダウンロード中...",starting_server:"サーバーを起動中...",running:"実行中",running_external:"実行中 (tsunagi外で起動)",error:"エラー"},ek=["installing_deps","downloading_model","starting_server"],ew=["running","running_external"];function eC(e){let t=e/0x40000000;return t>=.1?`${t.toFixed(2)} GB`:`${(e/1048576).toFixed(0)} MB`}function eS(){let[e,a]=(0,s.useState)(!1),[r,l]=(0,s.useState)(!1),[n,o]=(0,s.useState)(null),[c,d]=(0,s.useState)(""),u=(0,s.useRef)(null),x=(0,s.useCallback)(e=>{a(e),localStorage.setItem(eb.VOICE_INPUT_ENABLED_STORAGE_KEY,String(e))},[]),h=(0,s.useCallback)(e=>{d(e),localStorage.setItem(eb.WHISPER_PROMPT_STORAGE_KEY,e)},[]),p=(0,s.useCallback)(async()=>{let e=await fetch((0,i.apiUrl)("/api/whisper/server/status")),t=await e.json();return o(t),t},[]);(0,s.useEffect)(()=>{a("true"===localStorage.getItem(eb.VOICE_INPUT_ENABLED_STORAGE_KEY)),d(localStorage.getItem(eb.WHISPER_PROMPT_STORAGE_KEY)??""),p()},[p]),(0,s.useEffect)(()=>{n&&ew.includes(n.step)&&!e&&(x(!0),$.toaster.create({type:"success",title:"音声入力が有効化されました"}))},[n,e,x]),(0,s.useEffect)(()=>(n&&ek.includes(n.step)&&!u.current&&(u.current=setInterval(()=>{p().then(e=>{!ek.includes(e.step)&&u.current&&(clearInterval(u.current),u.current=null)})},1e3)),()=>{u.current&&(clearInterval(u.current),u.current=null)}),[n,p]);let g=(0,s.useCallback)(()=>{p(),l(!0)},[p]),f=(0,s.useCallback)(async()=>{try{let e=await fetch((0,i.apiUrl)("/api/whisper/server/start"),{method:"POST"});if(!e.ok){let t=await e.json().catch(()=>null);throw Error(t?.error||`HTTPエラー: ${e.status}`)}o(await e.json())}catch(e){$.toaster.create({type:"error",title:"サーバーの起動に失敗しました",description:e instanceof Error?e.message:String(e)})}},[]),j=(0,s.useCallback)(async()=>{try{let e=await fetch((0,i.apiUrl)("/api/whisper/server/stop"),{method:"POST"});if(!e.ok){let t=await e.json().catch(()=>null);throw Error(t?.error||`HTTPエラー: ${e.status}`)}o(await e.json())}catch(e){$.toaster.create({type:"error",title:"サーバーの停止に失敗しました",description:e instanceof Error?e.message:String(e)})}},[]),v=(0,s.useCallback)(()=>{x(!1),n&&ew.includes(n.step)&&j()},[x,j,n]),N=n?.serverDir,b=n?.downloadProgress,y=b?b.downloadedBytes/b.totalBytes*100:0,k=null!==n,w=k&&ew.includes(n.step);return(0,t.jsxs)(eo,{children:[(0,t.jsxs)(ec,{children:[(0,t.jsxs)("div",{className:"flex items-center gap-1",children:[(0,t.jsx)(ed,{children:"音声入力"}),(0,t.jsx)(m.Button,{variant:"ghost",size:"icon-sm",onClick:g,title:"音声入力について",children:(0,t.jsx)(ea,{})})]}),(0,t.jsx)(eu,{children:"ローカルで動作する音声認識モデル(Whisper / Qwen3-ASR)を使って音声入力を行います。"})]}),(0,t.jsxs)(ex,{className:"flex flex-col gap-3",children:[(0,t.jsx)(eN,{serverInfo:n,onServerChanged:()=>void p()}),e?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[k?w?(0,t.jsxs)("span",{className:"flex items-center gap-2 text-success",children:[(0,t.jsx)(es.CheckCircle2,{className:"size-4"}),"音声入力: 有効"]}):(0,t.jsxs)("span",{className:"flex items-center gap-2 text-warning",children:[(0,t.jsx)(et.AlertCircle,{className:"size-4"}),"音声入力: 有効化済み(サーバー停止中)"]}):(0,t.jsxs)("span",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,t.jsx)(er.Loader2,{className:"size-4 animate-spin"}),"状態を確認中..."]}),n&&(0,t.jsxs)("span",{className:"text-xs/relaxed text-muted-foreground",children:["(",ey[n.step],")"]}),k&&!w&&(0,t.jsxs)(m.Button,{size:"default",onClick:g,children:[(0,t.jsx)(el.Mic,{}),"サーバーを起動"]}),(0,t.jsx)(m.Button,{size:"default",variant:"outline",onClick:v,children:"無効にする"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"mb-1 block text-xs font-medium text-muted-foreground",children:"文字起こしプロンプト (任意)"}),(0,t.jsx)(eh.Textarea,{value:c,onChange:e=>h(e.target.value),placeholder:"例: 誤字、句読点、音声入力、Whisper、固有名詞や専門用語など",className:"min-h-16 text-xs"}),(0,t.jsx)("p",{className:"mt-1 text-[0.65rem] text-muted-foreground",children:"よく使う単語(固有名詞・専門用語・同音異義語で誤変換されやすい単語など)を列挙すると、 その表記が優先されやすくなり誤変換が減ります。Qwen3-ASRではスペース区切りの単語の羅列を推奨。空でも可。"})]})]}):(0,t.jsxs)(m.Button,{size:"default",onClick:g,children:[(0,t.jsx)(el.Mic,{}),"音声入力を有効化する"]})]}),(0,t.jsx)(O.Dialog,{open:r,onOpenChange:({open:e})=>l(e),title:"音声入力について",maxWidth:"2xl",children:(0,t.jsxs)("div",{className:"space-y-4 text-sm",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("p",{className:"font-medium text-foreground",children:"実験的機能です"}),(0,t.jsx)("p",{className:"text-muted-foreground",children:"音声入力はローカルで動作する音声認識モデル (mlx-whisper / mlx-qwen3-asr) を利用します。精度・速度は環境に依存し、今後変更される可能性があります。"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("p",{className:"font-medium text-foreground",children:"対応環境"}),(0,t.jsx)("p",{className:"text-muted-foreground",children:"Apple Silicon Mac (M1/M2/M3/M4) のみ対応。Windows/Linuxでは利用できません。"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("p",{className:"font-medium text-foreground",children:"必要なもの(事前に手動でインストール)"}),(0,t.jsx)("ul",{className:"list-disc pl-5 text-muted-foreground",children:(0,t.jsx)("li",{children:"Python 3.9以降(Xcode Command Line Tools または Homebrew経由で入手可能)"})})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("p",{className:"mb-1 font-medium text-foreground",children:"セットアップ・起動"}),(0,t.jsx)("p",{className:"text-muted-foreground",children:"下のボタンから、依存関係のインストール・モデルのダウンロード・サーバー起動まで自動で行われます(初回は数分かかります)。"}),n&&!N&&(0,t.jsx)("p",{className:"mt-1 text-destructive",children:"音声認識サーバー(whisper-server)が見つかりませんでした。インストールが壊れている可能性があります。"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("p",{className:"mb-1 font-medium text-foreground",children:"アンインストール"}),(0,t.jsxs)("p",{className:"text-muted-foreground",children:["音声入力のためにダウンロードされるもの(Pythonの依存関係・選択したモデル、モデルは1つあたり約1.6〜4.1GB)は全て",(0,t.jsx)("code",{className:"rounded bg-muted px-1",children:"~/.tsunagi/whisper"}),"に保存されます。不要になった場合はこのディレクトリを削除するだけで、関連リソースを完全に削除できます。"]})]}),(0,t.jsxs)("div",{className:"border-t border-border pt-4",children:[(!n||"not_running"===n.step||"error"===n.step)&&(0,t.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,t.jsxs)(m.Button,{size:"default",onClick:()=>void f(),disabled:!n,children:[n?(0,t.jsx)(el.Mic,{}):(0,t.jsx)(er.Loader2,{className:"animate-spin"}),"音声認識サーバーを起動"]}),n?.step==="error"&&n.error&&(0,t.jsx)("p",{className:"text-xs/relaxed text-destructive",children:n.error})]}),n?.step==="installing_deps"&&(0,t.jsxs)(m.Button,{size:"default",disabled:!0,children:[(0,t.jsx)(er.Loader2,{className:"animate-spin"}),"依存関係をインストール中... (数分かかる場合があります)"]}),n?.step==="downloading_model"&&(0,t.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2 text-xs/relaxed text-muted-foreground",children:[(0,t.jsx)(er.Loader2,{className:"size-4 animate-spin"}),"モデルをダウンロード中..."]}),b&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(em.Progress,{value:y}),(0,t.jsxs)("p",{className:"text-xs/relaxed text-muted-foreground",children:[eC(b.downloadedBytes)," / ",eC(b.totalBytes)," (",y.toFixed(0),"%) ・ ",function(e){if(null===e)return"残り時間を計算中...";if(e<60)return`残り約${e}秒`;let t=Math.floor(e/60);return`残り約${t}分${e%60}秒`}(b.etaSeconds)]})]})]}),n?.step==="starting_server"&&(0,t.jsxs)(m.Button,{size:"default",disabled:!0,children:[(0,t.jsx)(er.Loader2,{className:"animate-spin"}),"サーバーを起動中..."]}),n&&ew.includes(n.step)&&(0,t.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,t.jsxs)("span",{className:"flex items-center gap-2 text-success",children:[(0,t.jsx)(es.CheckCircle2,{className:"size-4"}),"サーバーは起動しています"]}),(0,t.jsxs)(m.Button,{size:"default",variant:"outline",onClick:()=>void j(),children:[(0,t.jsx)(en,{}),"サーバーを停止"]})]})]})]})})]})}var eL=e.i(66992);let eE=(0,l.default)("memory-stick",[["path",{d:"M12 12v-2",key:"fwoke6"}],["path",{d:"M12 18v-2",key:"qj6yno"}],["path",{d:"M16 12v-2",key:"heuere"}],["path",{d:"M16 18v-2",key:"s1ct0w"}],["path",{d:"M2 11h1.5",key:"15p63e"}],["path",{d:"M20 18v-2",key:"12ehxp"}],["path",{d:"M20.5 11H22",key:"khsy7a"}],["path",{d:"M4 18v-2",key:"1c3oqr"}],["path",{d:"M8 12v-2",key:"1mwtfd"}],["path",{d:"M8 18v-2",key:"qcmpov"}],["rect",{x:"2",y:"6",width:"20",height:"10",rx:"2",key:"1qcswk"}]]);var ez=e.i(31343);let eM=(0,l.default)("power-off",[["path",{d:"M18.36 6.64A9 9 0 0 1 20.77 15",key:"dxknvb"}],["path",{d:"M6.16 6.16a9 9 0 1 0 12.68 12.68",key:"1x7qb5"}],["path",{d:"M12 2v4",key:"3427ic"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]]);var e$=e.i(16715),eO=e.i(47161),eP=e.i(93355),eI=e.i(38078);let eT={k:1024,m:1048576},eB=[32768,65536,131072,262144];function eD(e){let t=e.trim().replace(/[,_\s]/g,"").toLowerCase().match(/^(\d+(?:\.\d+)?)([km]?)$/);if(!t)return null;let s=Number(t[1])*(t[2]?eT[t[2]]:1);return Number.isInteger(s)&&s>0?s:null}function eU(e){return e>=eT.m&&e%eT.m==0?`${e/eT.m}m`:e>=eT.k&&e%eT.k==0?`${e/eT.k}k`:String(e)}var e_=e.i(64691);function eA({value:e,onChange:a,max:r}){let l=(0,s.useId)(),n=eD(e),i=null!==n&&void 0!==r&&r>0&&n>r,o=eB.filter(e=>!r||e<=r);return(0,t.jsxs)("div",{children:[(0,t.jsx)(k.Input,{value:e,onChange:e=>a(e.target.value),placeholder:"64k",list:l,"aria-invalid":null===n||i,className:"font-mono"}),(0,t.jsx)("datalist",{id:l,children:o.map(e=>(0,t.jsx)("option",{value:eU(e)},e))}),(0,t.jsx)("p",{className:`mt-1 text-[0.65rem] ${null===n||i?"text-destructive":"text-muted-foreground"}`,children:null===n?"64k / 128k / 1m または整数で入力してください(k = 1024)":i?`このモデルの最大値(${eU(r)})を超えています`:`${n.toLocaleString()} tokens`})]})}function eF(e,t){return`${e}:${t}`}function eR(e){let t=e.indexOf(":");if(t<0)return null;let s=e.slice(0,t);return"ollama"!==s&&"lmstudio"!==s?null:{provider:s,model:e.slice(t+1)}}function eG({status:e}){let s=e.active?`${e.active.model}(${e_.LOCAL_LLM_PROVIDER_LABEL[e.active.provider]}・${eU(e.active.contextTokens)})`:"";switch(e.state){case"unconfigured":return(0,t.jsx)("span",{className:"text-muted-foreground",children:"使用するモデルが未設定です"});case"loading":return(0,t.jsxs)("span",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,t.jsx)(er.Loader2,{className:"size-4 animate-spin"}),"読み込み中: ",s]});case"loaded":return(0,t.jsxs)("span",{className:"flex items-center gap-2 text-success",children:[(0,t.jsx)(es.CheckCircle2,{className:"size-4"}),"読み込み済み: ",s]});case"unloaded":return(0,t.jsxs)("span",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,t.jsx)(eE,{className:"size-4"}),"解放済み: ",s,"(次の発言で読み込みます)"]});case"error":return(0,t.jsxs)("span",{className:"flex items-center gap-2 text-destructive",children:[(0,t.jsx)(et.AlertCircle,{className:"size-4"}),e.error]})}}function eX(){var e;let a,{settings:r,setSettings:l}=(0,eI.useLocalLlmSettings)(),[n,i]=(0,s.useState)(null),[o,c]=(0,s.useState)(null),[d,u]=(0,s.useState)(null),[x,h]=(0,s.useState)(!1),[p,g]=(0,s.useState)(null),[f,j]=(0,s.useState)(!1),[v,N]=(0,s.useState)(!1),[b,y]=(0,s.useState)(!1);(0,s.useEffect)(()=>{var e;r&&i({selection:(e=r).active?eF(e.active.provider,e.active.model):"",context:eU(e.active?.contextTokens??65536),idleUnloadMinutes:String(e.idleUnloadMinutes),unloadOnExit:e.unloadOnExit,webSearch:e.webSearch,extraEnvText:Object.entries(e.extraEnv).map(([e,t])=>`${e}=${t}`).join("\n")})},[r]);let w=(0,s.useCallback)(async()=>{try{c(await T("/api/settings/local-llm/status"))}catch(e){console.error("Failed to fetch local LLM status:",e)}},[]),C=(0,s.useCallback)(async()=>{h(!0);try{u(await T("/api/settings/local-llm/models"))}catch(e){$.toaster.create({type:"error",title:"モデル一覧を取得できません",description:D(e)})}finally{h(!1)}},[]);(0,s.useEffect)(()=>{w(),C();let e=setInterval(()=>void w(),3e3);return()=>clearInterval(e)},[w,C]);let S=n?eR(n.selection):null,L=(0,s.useMemo)(()=>d?.models.find(e=>e.provider===S?.provider&&e.model===S?.model),[d,S?.provider,S?.model]),E=L?.maxContextLength??void 0,z=S?.provider==="lmstudio"?S.model:"",M=n?eD(n.context):null;(0,s.useEffect)(()=>{if(g(null),!z||!M)return;let e=new AbortController,t=setTimeout(()=>{let t=new URLSearchParams({model:z,contextTokens:String(M)});T(`/api/settings/local-llm/estimate?${t}`,{signal:e.signal}).then(g).catch(()=>g(null))},600);return()=>{clearTimeout(t),e.abort()}},[z,M]);let P=Number(n?.idleUnloadMinutes),I=null!==n&&(e=n.context,null!==(a=eD(e))&&(!E||a<=E))&&Number.isInteger(P)&&P>=0,R=(0,s.useCallback)(async()=>{if(!n||!I)return;let e=eR(n.selection),t={active:e?{...e,contextTokens:eD(n.context)??65536}:null,idleUnloadMinutes:Number(n.idleUnloadMinutes),unloadOnExit:n.unloadOnExit,webSearch:n.webSearch,extraEnv:function(e){let t={};for(let s of e.split("\n")){let e=s.trim();if(!e||e.startsWith("#"))continue;let a=e.indexOf("=");a<=0||(t[e.slice(0,a).trim()]=e.slice(a+1).trim())}return t}(n.extraEnvText)},s=JSON.stringify(r?.active)!==JSON.stringify(t.active);j(!0);try{l(await B("/api/settings/local-llm",t)),$.toaster.create({type:"success",title:s?"使用するモデルを切り替えました(他のモデルは解放します)":"ローカルLLMの設定を保存しました"}),w()}catch(e){$.toaster.create({type:"error",title:"ローカルLLMの設定を保存できませんでした",description:D(e)})}finally{j(!1)}},[n,I,r?.active,l,w]),G=(0,s.useCallback)(async(e,t)=>{N(!0);try{c(await T(e,{method:"POST"}))}catch(e){$.toaster.create({type:"error",title:t,description:D(e)})}finally{N(!1)}},[]),X=e=>i(t=>t?{...t,...e}:t),H=(d?.models??[]).map(e=>{var t;return{value:eF(e.provider,e.model),label:[e.displayName,e.format.toUpperCase(),e.sizeBytes?(t=e.sizeBytes)>=0x40000000?`${(t/0x40000000).toFixed(1)} GB`:`${Math.round(t/1048576)} MB`:null,e.maxContextLength?`最大 ${eU(e.maxContextLength)}`:null].filter(Boolean).join(" · "),group:e_.LOCAL_LLM_PROVIDER_LABEL[e.provider]}}),V=r?.active;V&&!H.some(e=>e.value===eF(V.provider,V.model))&&H.unshift({value:eF(V.provider,V.model),label:`${V.model}(一覧にありません)`,group:e_.LOCAL_LLM_PROVIDER_LABEL[V.provider]});let q=null!==d&&0===d.models.length&&0===d.errors.length;return(0,t.jsxs)(eo,{children:[(0,t.jsxs)(ec,{children:[(0,t.jsxs)("div",{className:"flex items-center gap-1",children:[(0,t.jsx)(ed,{children:"Claude Code のローカルLLM"}),(0,t.jsx)(m.Button,{variant:"ghost",size:"icon-sm",onClick:()=>y(!0),title:"ローカルLLMについて",children:(0,t.jsx)(ea,{})})]}),(0,t.jsxs)(eu,{children:["Ollama / LM Studio のローカルLLMで Claude Code を起動します。",(0,t.jsx)("strong",{className:"font-medium text-foreground",children:"使用するモデルは1つだけで、全てのローカルLLMタブで共有します"}),"。切り替えると他のモデルはメモリから解放されます。"]})]}),(0,t.jsx)(ex,{className:"flex flex-col gap-3",children:r&&n?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(U,{children:[o?(0,t.jsx)(eG,{status:o}):(0,t.jsx)(er.Loader2,{className:"size-4 animate-spin"}),(0,t.jsxs)("div",{className:"ml-auto flex items-center gap-2",children:[o?.state==="unloaded"&&(0,t.jsxs)(m.Button,{variant:"outline",size:"sm",onClick:()=>void G("/api/settings/local-llm/load","モデルを読み込めません"),disabled:v,children:[(0,t.jsx)(ez.Play,{}),"読み込む"]}),(o?.state==="loaded"||o?.state==="error")&&(0,t.jsxs)(m.Button,{variant:"outline",size:"sm",onClick:()=>void G("/api/settings/local-llm/unload","モデルを解放できません"),disabled:v||(o?.inflight??0)>0,title:"メモリから外す(次の発言で自動で読み込み直します)",children:[v?(0,t.jsx)(er.Loader2,{className:"animate-spin"}):(0,t.jsx)(eM,{}),"解放"]})]})]}),o&&o.inflight>0&&(0,t.jsxs)("p",{className:"text-[0.65rem] text-muted-foreground",children:["応答を生成中のタブがあります(",o.inflight,"件)。完了するまでモデルは切り替えられません。"]}),q?(0,t.jsx)("p",{className:"text-xs text-warning",children:"下の Ollama / LM Studio のどちらかを有効にすると、モデルを選べるようになります。"}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(_,{label:"使用するモデル",hint:d?.errors.length?(0,t.jsx)("span",{className:"text-destructive",children:d.errors.map(e=>`${e_.LOCAL_LLM_PROVIDER_LABEL[e.provider]}: ${e.message}`).join(" / ")}):`有効なプロバイダーにダウンロード済みのモデル(${d?.models.length??0}件)`,children:(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)(eO.Combobox,{options:H,value:n.selection,onChange:e=>X({selection:String(e)}),placeholder:"モデルを選択",className:"flex-1"}),(0,t.jsx)(m.Button,{variant:"outline",size:"icon",onClick:()=>void C(),disabled:x,title:"モデル一覧を再取得",children:(0,t.jsx)(e$.RefreshCw,{className:x?"animate-spin":void 0})})]})}),(0,t.jsxs)(_,{label:"コンテキスト長",children:[(0,t.jsx)(eA,{value:n.context,onChange:e=>X({context:e}),max:E}),S?.provider==="lmstudio"&&(0,t.jsxs)("p",{className:"mt-1 flex items-center gap-1 text-[0.65rem] text-muted-foreground",children:[(0,t.jsx)(eL.Cpu,{className:"size-3"}),"必要メモリ(見積もり): ",p?.totalMemory??"-",L?.format==="mlx"&&"。MLX はモデルの最大値で読み込まれ、メモリは使った分だけ増えます"]}),S?.provider==="ollama"&&(0,t.jsxs)("p",{className:"mt-1 text-[0.65rem] text-muted-foreground",children:["このコンテキスト長を固定した派生モデル(",(0,t.jsx)(F,{children:"<モデル>-tsunagi-ctx<長さ>"}),")を作成して使います(重みは共有されます)。"]})]})]}),(0,t.jsx)(_,{label:"自動解放(分)",hint:"最後のリクエストからこの時間がたったらモデルをメモリから外します(0 で無効)。次の発言で自動で読み込み直します",children:(0,t.jsx)(k.Input,{type:"number",min:0,value:n.idleUnloadMinutes,onChange:e=>X({idleUnloadMinutes:e.target.value}),className:"w-32 font-mono"})}),(0,t.jsxs)("label",{className:"flex items-center gap-2 text-sm",children:[(0,t.jsx)("input",{type:"checkbox",checked:n.unloadOnExit,onChange:e=>X({unloadOnExit:e.target.checked}),className:"size-4 accent-primary"}),"tsunagi の終了時にモデルを解放する"]}),(0,t.jsxs)(_,{label:"WebSearch",children:[(0,t.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,t.jsx)(m.Button,{size:"sm",variant:"local"===n.webSearch?"default":"outline",onClick:()=>X({webSearch:"local"}),children:"ローカル検索(SearXNG)"}),(0,t.jsx)(m.Button,{size:"sm",variant:"ollama"===n.webSearch?"default":"outline",onClick:()=>X({webSearch:"ollama"}),children:"ollama.com(Ollama のみ・要サインイン)"})]}),(0,t.jsxs)("p",{className:"mt-1 text-[0.65rem] text-muted-foreground",children:["local"===n.webSearch?"組み込みの WebSearch を無効化し、ローカル検索(SearXNG)の web_search ツールを使います。":"使用するモデルが Ollama のとき、Ollama が ollama.com の Web 検索 API で代行します(Ollama 欄でサインイン状態を確認できます)。LM Studio のときはローカル検索になります。","設定はこの後に作成・起動したタブから反映されます。"]})]}),(0,t.jsx)(A,{children:(0,t.jsx)(_,{label:"追加の環境変数 (任意)",hint:"ローカルLLMタブにのみ適用されます。同名の既定値より優先されます",children:(0,t.jsx)(eh.Textarea,{value:n.extraEnvText,onChange:e=>X({extraEnvText:e.target.value}),placeholder:"KEY=VALUE(1行に1つ)",className:"min-h-16 font-mono text-xs"})})}),(0,t.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,t.jsxs)(m.Button,{size:"default",onClick:()=>void R(),disabled:f||!I,children:[f?(0,t.jsx)(er.Loader2,{className:"animate-spin"}):S&&(0,t.jsx)(eP.LocalLlmIcon,{provider:S.provider,className:"size-4"}),"保存"]}),(0,t.jsx)("span",{className:"text-[0.65rem] text-muted-foreground",children:"モデルを変えて保存すると、他のモデルを解放して読み込みを始めます"})]})]}):(0,t.jsxs)("span",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,t.jsx)(er.Loader2,{className:"size-4 animate-spin"}),"読み込み中..."]})}),(0,t.jsx)(O.Dialog,{open:b,onOpenChange:({open:e})=>y(e),title:"ローカルLLMについて",maxWidth:"2xl",children:(0,t.jsxs)("div",{className:"space-y-4 text-sm",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("p",{className:"font-medium text-foreground",children:"実験的機能です"}),(0,t.jsx)("p",{className:"text-muted-foreground",children:"Claude Code の接続先を tsunagi の中継口に切り替え、tsunagi が Ollama / LM Studio の Anthropic 互換 API に転送します。Anthropic はClaude以外のモデルへの接続をサポートしていないため、動作は保証されません。"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("p",{className:"font-medium text-foreground",children:"モデルは1つだけ"}),(0,t.jsx)("p",{className:"text-muted-foreground",children:"20〜30GB 級のモデルを2つ同時にメモリへ載せられるマシンは少ないため、使用するモデルは1つにし、全てのローカルLLMタブで共有します。切り替えると他のモデルは解放され、各タブは次の発言で会話全体を新しいモデルで読み直します(数十秒〜数分)。"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("p",{className:"font-medium text-foreground",children:"/model について"}),(0,t.jsxs)("p",{className:"text-muted-foreground",children:["ローカルLLMタブでは ",(0,t.jsx)(F,{children:"/model"})," ","によるモデルの切り替えを無効にしています(Claude Code が切り替えたモデルを通常の Claude タブの既定値として保存してしまうため)。切り替えはここで行ってください。"]})]})]})})]})}var eH=e.i(78917),eV=e.i(82458),eV=eV;function eq(){let{settings:e,setSettings:a}=(0,eI.useOllamaSettings)(),[r,l]=(0,s.useState)(""),[n,i]=(0,s.useState)(!1),[c,d]=(0,s.useState)(null),[u,x]=(0,s.useState)(null),[h,p]=(0,s.useState)(!1),[g,f]=(0,s.useState)(null);(0,s.useEffect)(()=>{e&&l(e.baseUrl)},[e]);let j=(0,s.useCallback)(async e=>{i(!0);try{return a(await B("/api/settings/ollama",e)),!0}catch(e){return $.toaster.create({type:"error",title:"Ollama の設定を保存できませんでした",description:D(e)}),!1}finally{i(!1)}},[a]),v=(0,s.useCallback)(async e=>{try{d(await T(`/api/settings/ollama/status?baseUrl=${encodeURIComponent(e)}`))}catch(e){console.error("Failed to fetch Ollama status:",e)}},[]),N=(0,s.useCallback)(async e=>{p(!0),f(null);try{x(await T(`/api/settings/ollama/account?baseUrl=${encodeURIComponent(e)}`))}catch(e){x(null),f(D(e))}finally{p(!1)}},[]),b=e?.enabled===!0,y=e?.baseUrl;(0,s.useEffect)(()=>{if(!b||!y)return;v(y),N(y);let e=setInterval(()=>void v(y),5e3);return()=>clearInterval(e)},[b,y,v,N]);let w=(0,s.useCallback)(async()=>{e&&await j({...e,baseUrl:r})&&$.toaster.create({type:"success",title:"Ollama の設定を保存しました"})},[e,r,j]);return(0,t.jsxs)(eo,{children:[(0,t.jsxs)(ec,{children:[(0,t.jsx)(ed,{children:"Ollama"}),(0,t.jsxs)(eu,{children:["ローカルLLMのプロバイダーとして Ollama を使います。Ollama のインストール・モデルの pull・起動はご自身で行ってください(例:"," ",(0,t.jsx)(F,{children:"ollama pull qwen3.6:35b-a3b-coding-nvfp4"}),")。"]})]}),(0,t.jsx)(ex,{className:"flex flex-col gap-3",children:e?b?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(U,{children:[c?c.reachable?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("span",{className:"flex items-center gap-2 text-success",children:[(0,t.jsx)(es.CheckCircle2,{className:"size-4"}),"接続中",c.version&&` (v${c.version})`]}),(0,t.jsx)("span",{className:"text-xs text-muted-foreground",children:c.loaded.length>0?`読み込み中: ${c.loaded.map(e=>`${e.name}${e.contextLength?` (${eU(e.contextLength)})`:""}`).join(", ")}`:"読み込み中のモデルなし"})]}):(0,t.jsxs)("span",{className:"flex items-center gap-2 text-warning",children:[(0,t.jsx)(eV.default,{className:"size-4"}),"Ollama に接続できません。Ollama アプリを起動してください"]}):(0,t.jsxs)("span",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,t.jsx)(er.Loader2,{className:"size-4 animate-spin"}),"確認中..."]}),(0,t.jsx)(m.Button,{variant:"outline",size:"sm",className:"ml-auto",onClick:()=>void j({...e,enabled:!1}),disabled:n,children:"無効にする"})]}),(0,t.jsx)(_,{label:"ollama.com(WebSearch を Ollama に代行させる場合)",hint:(0,t.jsxs)(t.Fragment,{children:["「Claude Code のローカルLLM」欄の WebSearch を「ollama.com」にした場合のみ必要です。Ollama を動かしているマシンで"," ",(0,t.jsx)(F,{children:"ollama signin"})," を実行してください(検索クエリは ollama.com に送信されます)。"]}),children:(0,t.jsxs)("div",{className:"flex flex-wrap items-center gap-2 text-sm",children:[h?(0,t.jsxs)("span",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,t.jsx)(er.Loader2,{className:"size-4 animate-spin"}),"確認中..."]}):u?.signedIn?(0,t.jsxs)("span",{className:"flex items-center gap-2 text-success",children:[(0,t.jsx)(o,{className:"size-4"}),"サインイン済み(",u.name,")"]}):u?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("span",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,t.jsx)(eV.default,{className:"size-4"}),"未サインイン"]}),u.signinUrl&&(0,t.jsxs)("a",{href:u.signinUrl,target:"_blank",rel:"noreferrer",className:(0,m.buttonVariants)({variant:"outline",size:"sm"}),children:[(0,t.jsx)(eH.ExternalLink,{}),"サインイン"]})]}):(0,t.jsx)("span",{className:"text-xs text-destructive",children:g}),(0,t.jsx)(m.Button,{variant:"outline",size:"icon",onClick:()=>void N(e.baseUrl),disabled:h,title:"サインイン状態を再確認",children:(0,t.jsx)(e$.RefreshCw,{className:h?"animate-spin":void 0})})]})}),(0,t.jsx)(A,{children:(0,t.jsx)(_,{label:"Base URL",hint:(0,t.jsxs)(t.Fragment,{children:["Docker で tsunagi を動かしている場合は"," ",(0,t.jsx)(F,{children:"http://host.docker.internal:11434"})]}),children:(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)(k.Input,{value:r,onChange:e=>l(e.target.value),placeholder:"http://localhost:11434"}),(0,t.jsx)(m.Button,{size:"default",onClick:()=>void w(),disabled:n||r===e.baseUrl,children:"保存"})]})})})]}):(0,t.jsxs)(m.Button,{size:"default",onClick:()=>void j({...e,enabled:!0}),disabled:n,children:[(0,t.jsx)(eP.OllamaIcon,{className:"size-4"}),"Ollama を有効化する"]}):(0,t.jsxs)("span",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,t.jsx)(er.Loader2,{className:"size-4 animate-spin"}),"読み込み中..."]})})]})}var eV=eV;function eW(){let{settings:e,setSettings:a}=(0,eI.useLmStudioSettings)(),[r,l]=(0,s.useState)(null),[n,i]=(0,s.useState)(!1),[o,c]=(0,s.useState)(null),[d,u]=(0,s.useState)(!1);(0,s.useEffect)(()=>{e&&l({baseUrl:e.baseUrl,apiToken:e.apiToken,lmsPath:e.lmsPath})},[e]);let x=e?.enabled===!0,h=(0,s.useCallback)(async()=>{try{c(await T("/api/settings/lmstudio/status"))}catch(e){console.error("Failed to fetch LM Studio status:",e)}},[]);(0,s.useEffect)(()=>{if(!x)return;h();let e=setInterval(()=>void h(),5e3);return()=>clearInterval(e)},[x,h]);let p=(0,s.useCallback)(async e=>{i(!0);try{return a(await B("/api/settings/lmstudio",e)),!0}catch(e){return $.toaster.create({type:"error",title:"LM Studio の設定を保存できませんでした",description:D(e)}),!1}finally{i(!1)}},[a]),g=(0,s.useCallback)(async e=>{u(!0);try{c(await T(`/api/settings/lmstudio/server/${e}`,{method:"POST"}))}catch(t){$.toaster.create({type:"error",title:"start"===e?"サーバーを起動できません":"サーバーを停止できません",description:D(t)})}finally{u(!1)}},[]),f=(0,s.useCallback)(async()=>{e&&r&&await p({...e,...r})&&($.toaster.create({type:"success",title:"LM Studio の設定を保存しました"}),h())},[e,r,p,h]),j=e=>l(t=>t?{...t,...e}:t);return(0,t.jsxs)(eo,{children:[(0,t.jsxs)(ec,{children:[(0,t.jsx)(ed,{children:"LM Studio"}),(0,t.jsxs)(eu,{children:["ローカルLLMのプロバイダーとして LM Studio(0.4.1 以降)を使います。",(0,t.jsx)("a",{href:"https://lmstudio.ai/download",target:"_blank",rel:"noreferrer",className:"underline",children:"LM Studio"}),"のインストールとモデルのダウンロードはご自身で行ってください(例:"," ",(0,t.jsx)(F,{children:"mlx-community/Qwen3.6-35B-A3B-4bit"}),")。一度起動すると lms CLI が入ります。"]})]}),(0,t.jsx)(ex,{className:"flex flex-col gap-3",children:e&&r?x?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(U,{children:[o?o.serverRunning?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("span",{className:"flex items-center gap-2 text-success",children:[(0,t.jsx)(es.CheckCircle2,{className:"size-4"}),"サーバー起動中"]}),(0,t.jsx)("span",{className:"text-xs text-muted-foreground",children:o.loaded.length>0?`読み込み中: ${o.loaded.map(e=>`${e.key} (${eU(e.contextLength)})`).join(", ")}`:"読み込み中のモデルなし"})]}):(0,t.jsxs)("span",{className:"flex items-center gap-2 text-warning",children:[(0,t.jsx)(eV.default,{className:"size-4"}),"サーバー停止中"]}):(0,t.jsxs)("span",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,t.jsx)(er.Loader2,{className:"size-4 animate-spin"}),"確認中..."]}),(0,t.jsxs)("div",{className:"ml-auto flex items-center gap-2",children:[o&&o.lmsPath?o.serverRunning?(0,t.jsxs)(m.Button,{variant:"outline",size:"sm",onClick:()=>void g("stop"),disabled:d,children:[d?(0,t.jsx)(er.Loader2,{className:"animate-spin"}):(0,t.jsx)(en,{}),"停止"]}):(0,t.jsxs)(m.Button,{size:"sm",onClick:()=>void g("start"),disabled:d,children:[d?(0,t.jsx)(er.Loader2,{className:"animate-spin"}):(0,t.jsx)(ez.Play,{}),"起動"]}):null,(0,t.jsx)(m.Button,{variant:"outline",size:"sm",onClick:()=>void p({...e,enabled:!1}),disabled:n,children:"無効にする"})]})]}),o&&!o.lmsPath&&!o.serverRunning&&(0,t.jsxs)("p",{className:"text-xs text-muted-foreground",children:["tsunagi から LM Studio のサーバーを起動するための lms CLI が見つかりません(tsunagi を Docker で動かしている場合も同様です)。LM Studio アプリの Developer タブでサーバーを起動するか、LM Studio を動かしているマシンで"," ",(0,t.jsx)(F,{children:"lms server start"})," を実行してください。lms がある場合は詳細設定でパスを指定できます。"]}),(0,t.jsxs)(A,{children:[(0,t.jsx)(_,{label:"Base URL",children:(0,t.jsx)(k.Input,{value:r.baseUrl,onChange:e=>j({baseUrl:e.target.value}),placeholder:"http://localhost:1234"})}),(0,t.jsx)(_,{label:"API トークン (任意)",hint:"LM Studio で「Require Authentication」を有効にしている場合のみ",children:(0,t.jsx)(k.Input,{type:"password",value:r.apiToken,onChange:e=>j({apiToken:e.target.value})})}),(0,t.jsx)(_,{label:"lms のパス (任意)",hint:"空欄なら ~/.lmstudio/bin/lms → PATH の順で探します",children:(0,t.jsx)(k.Input,{value:r.lmsPath,onChange:e=>j({lmsPath:e.target.value}),placeholder:o?.lmsPath??"~/.lmstudio/bin/lms",className:"font-mono"})}),(0,t.jsx)("div",{children:(0,t.jsxs)(m.Button,{size:"default",onClick:()=>void f(),disabled:n,children:[n&&(0,t.jsx)(er.Loader2,{className:"animate-spin"}),"保存"]})})]})]}):(0,t.jsxs)(m.Button,{size:"default",onClick:()=>void p({...e,enabled:!0}),disabled:n,children:[(0,t.jsx)(eP.LmStudioIcon,{className:"size-4"}),"LM Studio を有効化する"]}):(0,t.jsxs)("span",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,t.jsx)(er.Loader2,{className:"size-4 animate-spin"}),"読み込み中..."]})})]})}let eK=(0,l.default)("container",[["path",{d:"M22 7.7c0-.6-.4-1.2-.8-1.5l-6.3-3.9a1.72 1.72 0 0 0-1.7 0l-10.3 6c-.5.2-.9.8-.9 1.4v6.6c0 .5.4 1.2.8 1.5l6.3 3.9a1.72 1.72 0 0 0 1.7 0l10.3-6c.5-.3.9-1 .9-1.5Z",key:"1t2lqe"}],["path",{d:"M10 21.9V14L2.1 9.1",key:"o7czzq"}],["path",{d:"m10 14 11.9-6.9",key:"zm5e20"}],["path",{d:"M14 19.8v-8.1",key:"159ecu"}],["path",{d:"M18 17.5V9.4",key:"11uown"}]]),eJ=(0,l.default)("package-x",[["path",{d:"M21 10V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l2-1.14",key:"e7tb2h"}],["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}],["polyline",{points:"3.29 7 12 12 20.71 7",key:"ousv84"}],["line",{x1:"12",x2:"12",y1:"22",y2:"12",key:"a4e8g8"}],["path",{d:"m17 13 5 5m-5 0 5-5",key:"im3w4b"}]]);var eY=e.i(91810);let eZ=(0,l.default)("square-terminal",[["path",{d:"m7 11 2-2-2-2",key:"1lz0vl"}],["path",{d:"M11 13h4",key:"1p7l4v"}],["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}]]),eQ={auto:"自動(searxng-run → Docker の順)",process:"searxng-run",docker:"Docker"};function e0({status:e}){let s,{state:a,runner:r,docker:l}=e;if("not-installed"===a)return null;let n=(0,t.jsx)(F,{children:l.container}),i=(0,t.jsx)(F,{children:e.binPath??"searxng-run"});return s="external"===a?"docker"===r?(0,t.jsxs)(t.Fragment,{children:["Docker コンテナ ",n,"(tsunagi 外で起動したため、tsunagi は停止しません)"]}):(0,t.jsx)(t.Fragment,{children:"tsunagi 外で起動した SearXNG(起動方法は不明。tsunagi は停止しません)"}):"running"===a?"docker"===r?(0,t.jsxs)(t.Fragment,{children:["Docker コンテナ ",n," を tsunagi が起動しました(停止時・終了時に停止します)"]}):(0,t.jsxs)(t.Fragment,{children:[i," を tsunagi が起動しました(停止時・終了時に停止します)"]}):"docker"===r?null===l.containerExists?(0,t.jsxs)(t.Fragment,{children:["Docker コンテナ ",n," を起動します(Docker が応答しません。Docker Desktop を起動してください)"]}):l.containerExists?(0,t.jsxs)(t.Fragment,{children:["Docker コンテナ ",n," を起動します"]}):(0,t.jsxs)(t.Fragment,{children:["Docker コンテナ ",n," を作成して起動します(初回はイメージの取得に数分かかります)"]}):(0,t.jsxs)(t.Fragment,{children:[i," を起動します"]}),(0,t.jsxs)("p",{className:"flex items-start gap-1.5 text-xs text-muted-foreground",children:[(0,t.jsx)("docker"===r?eK:eZ,{className:"mt-px size-3.5 shrink-0","aria-label":"起動方法"}),(0,t.jsx)("span",{children:s})]})}function e1(){let[e,a]=(0,s.useState)(null),[r,l]=(0,s.useState)(null),[n,i]=(0,s.useState)(null),[o,c]=(0,s.useState)(!1),[d,u]=(0,s.useState)(!1),x=(0,s.useCallback)(async()=>{try{a(await T("/api/settings/searxng/status"))}catch(e){console.error("Failed to fetch SearXNG status:",e)}},[]);(0,s.useEffect)(()=>{x(),T("/api/settings/searxng").then(l).catch(e=>console.error("Failed to fetch SearXNG settings:",e));let e=setInterval(()=>void x(),3e3);return()=>clearInterval(e)},[x]),(0,s.useEffect)(()=>{r&&i({port:String(r.port),method:r.method,binPath:r.binPath,settingsPath:r.settingsPath,dockerContainer:r.dockerContainer})},[r]);let h=(0,s.useCallback)(async(e,t)=>{c(!0);try{a(await T(e,{method:"POST"}))}catch(e){$.toaster.create({type:"error",title:t,description:D(e)})}finally{c(!1)}},[]),p=(0,s.useCallback)(async()=>{if(n){c(!0);try{l(await B("/api/settings/searxng",{port:Number(n.port),method:n.method,binPath:n.binPath,settingsPath:n.settingsPath,dockerContainer:n.dockerContainer}))}catch(e){$.toaster.create({type:"error",title:"SearXNG の設定を保存できませんでした",description:D(e)}),c(!1);return}c(!1),await h("/api/settings/searxng/restart","SearXNG を再起動できません")}},[n,h]);if(!e?.required)return null;let g=e=>i(t=>t?{...t,...e}:t);return(0,t.jsxs)(eo,{children:[(0,t.jsxs)(ec,{children:[(0,t.jsxs)("div",{className:"flex items-center gap-1",children:[(0,t.jsx)(ed,{children:"ローカル検索 (SearXNG)"}),(0,t.jsx)(m.Button,{variant:"ghost",size:"icon-sm",onClick:()=>u(!0),title:"ローカル検索について",children:(0,t.jsx)(ea,{})})]}),(0,t.jsxs)(eu,{children:["Ollama / LM Studio タブの WebSearch をローカルの SearXNG で行います。",(0,t.jsx)("strong",{className:"font-medium text-foreground",children:"Ollama か LM Studio が有効な間、tsunagi が自動で起動・停止します"}),"。searxng-run が無ければ Docker で起動します(コンテナが無ければ作成します)。"]})]}),(0,t.jsxs)(ex,{className:"flex flex-col gap-3",children:[(0,t.jsxs)(U,{children:["running"===e.state||"external"===e.state?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("span",{className:"flex items-center gap-2 text-success",children:[(0,t.jsx)(es.CheckCircle2,{className:"size-4"}),"running"===e.state?"起動中":"起動中(tsunagi 外で起動)"]}),(0,t.jsx)("span",{className:"font-mono text-xs text-muted-foreground",children:e.url})]}):"starting"===e.state?(0,t.jsxs)("span",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,t.jsx)(er.Loader2,{className:"size-4 animate-spin"}),e.message??"起動中","..."]}):"not-installed"===e.state?(0,t.jsxs)("span",{className:"flex items-center gap-2 text-warning",children:[(0,t.jsx)(eJ,{className:"size-4"}),"SearXNG を起動できません(",(0,t.jsx)(F,{children:"searxng-run"})," も ",(0,t.jsx)(F,{children:"docker"})," ","も見つかりません)"]}):"error"===e.state?(0,t.jsxs)("span",{className:"flex items-center gap-2 text-destructive",children:[(0,t.jsx)(et.AlertCircle,{className:"size-4"}),"エラー"]}):(0,t.jsx)("span",{className:"text-muted-foreground",children:"停止中"}),(0,t.jsxs)("div",{className:"ml-auto flex items-center gap-2",children:["external"!==e.state&&"starting"!==e.state&&(0,t.jsxs)(m.Button,{variant:"outline",size:"sm",onClick:()=>void h("/api/settings/searxng/restart","SearXNG を起動できません"),disabled:o,children:[(0,t.jsx)(eY.RotateCw,{}),"running"===e.state?"再起動":"起動"]}),"running"===e.state&&(0,t.jsxs)(m.Button,{variant:"outline",size:"sm",onClick:()=>void h("/api/settings/searxng/stop","SearXNG を停止できません"),disabled:o,children:[(0,t.jsx)(en,{}),"停止"]})]})]}),(0,t.jsx)(e0,{status:e}),"error"===e.state&&e.error&&(0,t.jsx)("pre",{className:"max-h-40 overflow-auto rounded-md bg-muted p-2 text-[0.65rem] whitespace-pre-wrap text-destructive",children:e.error}),"not-installed"===e.state&&(0,t.jsxs)("p",{className:"text-xs text-muted-foreground",children:["Docker Desktop を入れると、tsunagi がコンテナを作成して起動します(",(0,t.jsx)("a",{href:"https://minimalcorp.github.io/tsunagi/ja/features/local-search/",target:"_blank",rel:"noreferrer",className:"underline",children:"手順"}),")。Docker を使わない場合は、nix なら ",(0,t.jsx)(F,{children:"nix profile install nixpkgs#searxng"})," ","などで ",(0,t.jsx)(F,{children:"searxng-run"})," を PATH に入れてください(",(0,t.jsx)("a",{href:"https://docs.searxng.org/admin/installation.html",target:"_blank",rel:"noreferrer",className:"underline",children:"インストール方法"}),")。PATH にない場合は詳細設定でパスを指定できます。起動方法を固定したい場合も詳細設定で選べます。"]}),n&&(0,t.jsxs)(A,{children:[(0,t.jsx)(_,{label:"ポート",hint:"既定は 7964(キーパッドで sxng)",children:(0,t.jsx)(k.Input,{type:"number",min:1,max:65535,value:n.port,onChange:e=>g({port:e.target.value}),className:"font-mono"})}),(0,t.jsx)(_,{label:"起動方法",children:(0,t.jsx)("select",{value:n.method,onChange:e=>g({method:e.target.value}),className:"h-9 w-full rounded-md border border-input bg-transparent pl-3 pr-10 text-sm text-foreground shadow-xs",children:Object.keys(eQ).map(e=>(0,t.jsx)("option",{value:e,children:eQ[e]},e))})}),(0,t.jsx)(_,{label:"Docker のコンテナ名",hint:"無ければ tsunagi が公式イメージで作成します(設定は ~/.tsunagi/searxng/docker/<コンテナ名>/)",children:(0,t.jsx)(k.Input,{value:n.dockerContainer,onChange:e=>g({dockerContainer:e.target.value}),placeholder:"searxng",className:"font-mono"})}),(0,t.jsx)(_,{label:"searxng-run のパス (任意)",hint:"空欄なら PATH から探します",children:(0,t.jsx)(k.Input,{value:n.binPath,onChange:e=>g({binPath:e.target.value}),placeholder:e.binPath??"searxng-run",className:"font-mono"})}),(0,t.jsx)(_,{label:"settings.yml のパス (任意)",hint:"searxng-run で起動するときのみ。空欄なら tsunagi が生成したもの(~/.tsunagi/searxng/settings.yml)を使います。独自のものを使う場合は search.formats に json を含めてください",children:(0,t.jsx)(k.Input,{value:n.settingsPath,onChange:e=>g({settingsPath:e.target.value}),className:"font-mono"})}),(0,t.jsx)("div",{children:(0,t.jsxs)(m.Button,{size:"default",onClick:()=>void p(),disabled:o,children:[o&&(0,t.jsx)(er.Loader2,{className:"animate-spin"}),"保存して再起動"]})})]})]}),(0,t.jsx)(O.Dialog,{open:d,onOpenChange:({open:e})=>u(e),title:"ローカル検索について",maxWidth:"2xl",children:(0,t.jsxs)("div",{className:"space-y-4 text-sm",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("p",{className:"font-medium text-foreground",children:"仕組み"}),(0,t.jsxs)("p",{className:"text-muted-foreground",children:["Claude Code の WebSearch は Anthropic のサーバーツールのため、ローカルLLMでは使えません(LM Studio は無視し、Ollama は ollama.com のサインインが必要)。ローカル検索を使うタブでは WebSearch を無効化し、tsunagi の MCP が提供する ",(0,t.jsx)(F,{children:"web_search"})," ツールで SearXNG に検索させます。"]})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("p",{className:"font-medium text-foreground",children:"自動起動・停止"}),(0,t.jsxs)("p",{className:"text-muted-foreground",children:["Ollama か LM Studio が有効なら、tsunagi の起動時・有効化時に SearXNG を起動し、両方を無効にしたときと tsunagi の終了時に停止します。起動方法は"," ",(0,t.jsx)(F,{children:"searxng-run"})," があればそれを、なければ Docker(コンテナが無ければ作成)を使います。既にポートで SearXNG が動いていればそれを使います(tsunagi は止めません)。SearXNG がなくても tsunagi 自体は通常どおり動きます。"]})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("p",{className:"font-medium text-foreground",children:"注意"}),(0,t.jsx)("p",{className:"text-muted-foreground",children:"SearXNG は Google / Bing / DuckDuckGo などの検索エンジンに問い合わせます。短時間に大量に検索すると、検索エンジン側で一時的にブロックされることがあります。"})]})]})})]})}var e2=e.i(43034),e4=e.i(37837),e3=e.i(99059),e5=e.i(44142);function e6(){let e=(0,e5.useUpdateStatus)(),a=(0,e5.useCheckForUpdate)(),[r,l]=(0,s.useState)(!1),n=async()=>{l(!0);try{await a()}catch(e){$.toaster.create({type:"error",title:"Failed to check for updates",description:e instanceof Error?e.message:String(e)})}finally{l(!1)}};return(0,t.jsxs)("div",{className:"border-t border-border p-3 space-y-1 text-xs",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between gap-1",children:[(0,t.jsxs)("span",{className:"font-medium text-foreground",children:["tsunagi ",e?.current?`v${e.current}`:"dev"]}),e?.current&&(0,t.jsx)(m.Button,{variant:"ghost",size:"icon-sm",onClick:()=>void n(),disabled:r,title:"Check for updates","aria-label":"Check for updates",children:(0,t.jsx)(e$.RefreshCw,{className:(0,ei.cn)(r&&"animate-spin")})})]}),e?.updateAvailable?(0,t.jsxs)(e4.Popover,{children:[(0,t.jsx)(e4.PopoverTrigger,{className:"flex items-center gap-1 rounded-sm text-info hover:underline cursor-pointer outline-none focus-visible:ring-[3px] focus-visible:ring-ring/50",children:"ready"===e.autoUpdate.state?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(eY.RotateCw,{className:"size-3.5"}),"Restart to update to v",e.autoUpdate.version]}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(e2.ArrowUpCircle,{className:"size-3.5"}),"v",e.latest," available"]})}),(0,t.jsx)(e3.UpdatePopoverContent,{status:e})]}):e?.checkedAt?(0,t.jsxs)("div",{className:"flex items-center gap-1 text-success",children:[(0,t.jsx)(es.CheckCircle2,{className:"size-3.5"}),"Up to date"]}):(0,t.jsxs)("div",{className:"flex items-center gap-1 text-muted-foreground",children:[(0,t.jsx)(ea,{className:"size-3.5"}),"Not checked"]}),e?.entryOutdated&&!e.updateAvailable&&(0,t.jsxs)(e4.Popover,{children:[(0,t.jsxs)(e4.PopoverTrigger,{className:"flex items-center gap-1 rounded-sm text-warning hover:underline cursor-pointer outline-none focus-visible:ring-[3px] focus-visible:ring-ring/50",children:[(0,t.jsx)(et.AlertCircle,{className:"size-3.5"}),"Reinstall recommended"]}),(0,t.jsx)(e3.UpdatePopoverContent,{status:e})]}),e?.checkedAt&&(0,t.jsxs)("div",{className:"text-muted-foreground",children:["Last checked: ",new Date(e.checkedAt).toLocaleString()]})]})}var e7=e.i(51846),e8=e.i(81671);e.s(["default",0,function(){let e=(0,a.useRouter)();(0,e7.useDocumentTitle)("settings");let l=(0,e8.useAgentAvailability)(),o=()=>{{let e=localStorage.getItem("tsunagi:env-selected-node");if(e)try{return JSON.parse(e)}catch(e){console.error("Failed to parse selected node:",e)}}return{scope:"global",label:"Global"}},[c,d]=(0,s.useState)(null),[u,x]=(0,s.useState)(0);return(0,s.useEffect)(()=>{fetch((0,i.apiUrl)("/api/onboarding/status")).then(e=>e.json()).then(e=>{e.data?.completed?d(o()):d({scope:"global",label:"Global"})}).catch(e=>{console.error("Failed to fetch onboarding status:",e),d(o())})},[]),(0,s.useEffect)(()=>{c&&localStorage.setItem("tsunagi:env-selected-node",JSON.stringify(c))},[c]),(0,t.jsxs)("div",{className:"h-screen flex flex-col bg-background",children:[(0,t.jsx)("div",{className:"sticky top-0 z-50 p-4 border-b border-border bg-card",children:(0,t.jsxs)("div",{className:"flex items-center justify-between",children:[(0,t.jsxs)(m.Button,{variant:"ghost",onClick:()=>e.push("/"),className:"text-primary font-medium hover:bg-primary/10 hover:text-foreground",children:[(0,t.jsx)(r.ArrowLeft,{className:"w-4 h-4"}),"Back to Board"]}),(0,t.jsx)("h1",{className:"text-xl font-bold text-foreground absolute left-1/2 -translate-x-1/2",children:"Settings"}),(0,t.jsx)(e3.UpdateIndicator,{})]})}),(0,t.jsxs)("div",{className:"flex-1 flex min-h-0",children:[(0,t.jsxs)("div",{className:"w-64 border-r border-border bg-card flex flex-col",children:[(0,t.jsx)("div",{className:"flex-1 min-h-0",children:(0,t.jsx)(p,{selectedNode:c,onNodeSelect:e=>{d(e)},refreshKey:u})}),(0,t.jsx)(e6,{})]}),(0,t.jsx)("div",{className:"flex-1 bg-card p-4 overflow-y-auto",children:c?(0,t.jsxs)("div",{className:"space-y-6",children:[l?.filter(e=>e.installed).map(e=>(0,t.jsx)(K,{agent:e.agent,selectedNode:c},e.agent)),(0,t.jsx)(L,{selectedNode:c}),"global"===c.scope&&(0,t.jsxs)("div",{className:"space-y-3",children:[(0,t.jsx)("h2",{className:"text-sm font-semibold text-foreground",children:"Repositories"}),(0,t.jsx)(Z,{})]}),"global"===c.scope&&(0,t.jsxs)("div",{className:"space-y-6",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2 pt-2 text-muted-foreground",children:[(0,t.jsx)(n,{className:"size-4"}),(0,t.jsx)("span",{className:"text-sm font-semibold",children:"Experimental"}),(0,t.jsx)("div",{className:"h-px flex-1 bg-border"})]}),(0,t.jsx)(eS,{}),(0,t.jsx)(eX,{}),(0,t.jsx)(eq,{}),(0,t.jsx)(eW,{}),(0,t.jsx)(e1,{})]}),"repo"===c.scope&&c.owner&&c.repo&&(0,t.jsx)(ee,{owner:c.owner,repo:c.repo,onDeleted:()=>{d({scope:"global",label:"Global"}),x(e=>e+1)}})]}):(0,t.jsx)("div",{className:"h-full flex items-center justify-center text-muted-foreground text-sm",children:"Select a node from the left panel"})})]})]})}],82341)}]);