commandmate 0.45.0 → 0.46.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 (322) hide show
  1. package/.next/BUILD_ID +1 -1
  2. package/.next/app-build-manifest.json +333 -328
  3. package/.next/app-path-routes-manifest.json +24 -24
  4. package/.next/build-manifest.json +5 -5
  5. package/.next/prerender-manifest.json +3 -3
  6. package/.next/react-loadable-manifest.json +6 -6
  7. package/.next/required-server-files.json +1 -1
  8. package/.next/server/app/_not-found/page.js +1 -1
  9. package/.next/server/app/_not-found/page.js.nft.json +1 -1
  10. package/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  11. package/.next/server/app/api/agents/update/route_client-reference-manifest.js +1 -1
  12. package/.next/server/app/api/agents/versions/route_client-reference-manifest.js +1 -1
  13. package/.next/server/app/api/app/release-notes/route_client-reference-manifest.js +1 -1
  14. package/.next/server/app/api/app/update/route_client-reference-manifest.js +1 -1
  15. package/.next/server/app/api/app/update-check/route_client-reference-manifest.js +1 -1
  16. package/.next/server/app/api/auth/login/route_client-reference-manifest.js +1 -1
  17. package/.next/server/app/api/auth/logout/route_client-reference-manifest.js +1 -1
  18. package/.next/server/app/api/auth/status/route_client-reference-manifest.js +1 -1
  19. package/.next/server/app/api/capabilities/route.js +1 -1
  20. package/.next/server/app/api/capabilities/route_client-reference-manifest.js +1 -1
  21. package/.next/server/app/api/daily-summary/route_client-reference-manifest.js +1 -1
  22. package/.next/server/app/api/daily-summary/status/route_client-reference-manifest.js +1 -1
  23. package/.next/server/app/api/external-apps/[id]/health/route_client-reference-manifest.js +1 -1
  24. package/.next/server/app/api/external-apps/[id]/route_client-reference-manifest.js +1 -1
  25. package/.next/server/app/api/external-apps/route_client-reference-manifest.js +1 -1
  26. package/.next/server/app/api/fs/browse/route_client-reference-manifest.js +1 -1
  27. package/.next/server/app/api/fs/recent-paths/route_client-reference-manifest.js +1 -1
  28. package/.next/server/app/api/hooks/agent-event/route_client-reference-manifest.js +1 -1
  29. package/.next/server/app/api/hooks/claude-done/route_client-reference-manifest.js +1 -1
  30. package/.next/server/app/api/hooks/permission-request/route_client-reference-manifest.js +1 -1
  31. package/.next/server/app/api/metrics/vibe/route_client-reference-manifest.js +1 -1
  32. package/.next/server/app/api/ollama/models/route_client-reference-manifest.js +1 -1
  33. package/.next/server/app/api/push/escalation/route_client-reference-manifest.js +1 -1
  34. package/.next/server/app/api/push/subscriptions/route_client-reference-manifest.js +1 -1
  35. package/.next/server/app/api/push/vapid/route_client-reference-manifest.js +1 -1
  36. package/.next/server/app/api/relays/[relayId]/cancel/route_client-reference-manifest.js +1 -1
  37. package/.next/server/app/api/relays/route_client-reference-manifest.js +1 -1
  38. package/.next/server/app/api/remote/pair/route_client-reference-manifest.js +1 -1
  39. package/.next/server/app/api/repositories/[id]/route_client-reference-manifest.js +1 -1
  40. package/.next/server/app/api/repositories/clone/[jobId]/route_client-reference-manifest.js +1 -1
  41. package/.next/server/app/api/repositories/clone/route_client-reference-manifest.js +1 -1
  42. package/.next/server/app/api/repositories/excluded/route_client-reference-manifest.js +1 -1
  43. package/.next/server/app/api/repositories/restore/route_client-reference-manifest.js +1 -1
  44. package/.next/server/app/api/repositories/route_client-reference-manifest.js +1 -1
  45. package/.next/server/app/api/repositories/scan/route_client-reference-manifest.js +1 -1
  46. package/.next/server/app/api/repositories/sync/route_client-reference-manifest.js +1 -1
  47. package/.next/server/app/api/repositories/validate-path/route_client-reference-manifest.js +1 -1
  48. package/.next/server/app/api/settings/default-agents/route_client-reference-manifest.js +1 -1
  49. package/.next/server/app/api/settings/default-surface-mode/route_client-reference-manifest.js +1 -1
  50. package/.next/server/app/api/sidebar/group-order/route_client-reference-manifest.js +1 -1
  51. package/.next/server/app/api/skills/[id]/route_client-reference-manifest.js +1 -1
  52. package/.next/server/app/api/skills/installations/route_client-reference-manifest.js +1 -1
  53. package/.next/server/app/api/skills/operations/route_client-reference-manifest.js +1 -1
  54. package/.next/server/app/api/skills/reindex/route_client-reference-manifest.js +1 -1
  55. package/.next/server/app/api/skills/route_client-reference-manifest.js +1 -1
  56. package/.next/server/app/api/slash-commands/route_client-reference-manifest.js +1 -1
  57. package/.next/server/app/api/tasks/[taskId]/cancel/route_client-reference-manifest.js +1 -1
  58. package/.next/server/app/api/tasks/[taskId]/route_client-reference-manifest.js +1 -1
  59. package/.next/server/app/api/templates/[id]/route_client-reference-manifest.js +1 -1
  60. package/.next/server/app/api/templates/route_client-reference-manifest.js +1 -1
  61. package/.next/server/app/api/verification/runs/[runId]/route_client-reference-manifest.js +1 -1
  62. package/.next/server/app/api/verification/runs/route_client-reference-manifest.js +1 -1
  63. package/.next/server/app/api/worktrees/[id]/auto-yes/route.js +1 -1
  64. package/.next/server/app/api/worktrees/[id]/auto-yes/route_client-reference-manifest.js +1 -1
  65. package/.next/server/app/api/worktrees/[id]/capture/route_client-reference-manifest.js +1 -1
  66. package/.next/server/app/api/worktrees/[id]/clear-composer/route_client-reference-manifest.js +1 -1
  67. package/.next/server/app/api/worktrees/[id]/cli-reference/route_client-reference-manifest.js +1 -1
  68. package/.next/server/app/api/worktrees/[id]/cli-tool/route_client-reference-manifest.js +1 -1
  69. package/.next/server/app/api/worktrees/[id]/cmate/schedules/route.js +3 -3
  70. package/.next/server/app/api/worktrees/[id]/cmate/schedules/route_client-reference-manifest.js +1 -1
  71. package/.next/server/app/api/worktrees/[id]/current-output/route_client-reference-manifest.js +1 -1
  72. package/.next/server/app/api/worktrees/[id]/direct-input/route_client-reference-manifest.js +1 -1
  73. package/.next/server/app/api/worktrees/[id]/env/route_client-reference-manifest.js +1 -1
  74. package/.next/server/app/api/worktrees/[id]/execution-logs/[logId]/route_client-reference-manifest.js +1 -1
  75. package/.next/server/app/api/worktrees/[id]/execution-logs/route.js +3 -3
  76. package/.next/server/app/api/worktrees/[id]/execution-logs/route_client-reference-manifest.js +1 -1
  77. package/.next/server/app/api/worktrees/[id]/files/[...path]/route_client-reference-manifest.js +1 -1
  78. package/.next/server/app/api/worktrees/[id]/git/branch/create/route_client-reference-manifest.js +1 -1
  79. package/.next/server/app/api/worktrees/[id]/git/branch/delete/route_client-reference-manifest.js +1 -1
  80. package/.next/server/app/api/worktrees/[id]/git/branches/route_client-reference-manifest.js +1 -1
  81. package/.next/server/app/api/worktrees/[id]/git/checkout/route_client-reference-manifest.js +1 -1
  82. package/.next/server/app/api/worktrees/[id]/git/commit/route_client-reference-manifest.js +1 -1
  83. package/.next/server/app/api/worktrees/[id]/git/diff/route_client-reference-manifest.js +1 -1
  84. package/.next/server/app/api/worktrees/[id]/git/fetch/route_client-reference-manifest.js +1 -1
  85. package/.next/server/app/api/worktrees/[id]/git/log/route_client-reference-manifest.js +1 -1
  86. package/.next/server/app/api/worktrees/[id]/git/pull/route_client-reference-manifest.js +1 -1
  87. package/.next/server/app/api/worktrees/[id]/git/push/route_client-reference-manifest.js +1 -1
  88. package/.next/server/app/api/worktrees/[id]/git/reset/route_client-reference-manifest.js +1 -1
  89. package/.next/server/app/api/worktrees/[id]/git/revert/route_client-reference-manifest.js +1 -1
  90. package/.next/server/app/api/worktrees/[id]/git/show/[commitHash]/route_client-reference-manifest.js +1 -1
  91. package/.next/server/app/api/worktrees/[id]/git/stage/route_client-reference-manifest.js +1 -1
  92. package/.next/server/app/api/worktrees/[id]/git/staged/route_client-reference-manifest.js +1 -1
  93. package/.next/server/app/api/worktrees/[id]/git/stash/[index]/route_client-reference-manifest.js +1 -1
  94. package/.next/server/app/api/worktrees/[id]/git/stash/apply/route_client-reference-manifest.js +1 -1
  95. package/.next/server/app/api/worktrees/[id]/git/stash/pop/route_client-reference-manifest.js +1 -1
  96. package/.next/server/app/api/worktrees/[id]/git/stash/push/route_client-reference-manifest.js +1 -1
  97. package/.next/server/app/api/worktrees/[id]/git/stash/route_client-reference-manifest.js +1 -1
  98. package/.next/server/app/api/worktrees/[id]/git/status/route_client-reference-manifest.js +1 -1
  99. package/.next/server/app/api/worktrees/[id]/git/unstage/route_client-reference-manifest.js +1 -1
  100. package/.next/server/app/api/worktrees/[id]/git/working-diff/route_client-reference-manifest.js +1 -1
  101. package/.next/server/app/api/worktrees/[id]/instances/notes/route_client-reference-manifest.js +1 -1
  102. package/.next/server/app/api/worktrees/[id]/instances/opencode/route_client-reference-manifest.js +1 -1
  103. package/.next/server/app/api/worktrees/[id]/interrupt/route_client-reference-manifest.js +1 -1
  104. package/.next/server/app/api/worktrees/[id]/kill-session/route.js +1 -1
  105. package/.next/server/app/api/worktrees/[id]/kill-session/route_client-reference-manifest.js +1 -1
  106. package/.next/server/app/api/worktrees/[id]/logs/[filename]/route_client-reference-manifest.js +1 -1
  107. package/.next/server/app/api/worktrees/[id]/logs/route_client-reference-manifest.js +1 -1
  108. package/.next/server/app/api/worktrees/[id]/marp-render/route_client-reference-manifest.js +1 -1
  109. package/.next/server/app/api/worktrees/[id]/memos/[memoId]/route_client-reference-manifest.js +1 -1
  110. package/.next/server/app/api/worktrees/[id]/memos/route_client-reference-manifest.js +1 -1
  111. package/.next/server/app/api/worktrees/[id]/messages/route_client-reference-manifest.js +1 -1
  112. package/.next/server/app/api/worktrees/[id]/opencode/diff/route_client-reference-manifest.js +1 -1
  113. package/.next/server/app/api/worktrees/[id]/opencode/session/route_client-reference-manifest.js +1 -1
  114. package/.next/server/app/api/worktrees/[id]/opencode/share/route_client-reference-manifest.js +1 -1
  115. package/.next/server/app/api/worktrees/[id]/prompt-response/route_client-reference-manifest.js +1 -1
  116. package/.next/server/app/api/worktrees/[id]/resolve-target/route_client-reference-manifest.js +1 -1
  117. package/.next/server/app/api/worktrees/[id]/respond/route_client-reference-manifest.js +1 -1
  118. package/.next/server/app/api/worktrees/[id]/route.js +1 -1
  119. package/.next/server/app/api/worktrees/[id]/route_client-reference-manifest.js +1 -1
  120. package/.next/server/app/api/worktrees/[id]/schedules/[scheduleId]/route.js +3 -3
  121. package/.next/server/app/api/worktrees/[id]/schedules/[scheduleId]/route_client-reference-manifest.js +1 -1
  122. package/.next/server/app/api/worktrees/[id]/schedules/active/route.js +3 -3
  123. package/.next/server/app/api/worktrees/[id]/schedules/active/route_client-reference-manifest.js +1 -1
  124. package/.next/server/app/api/worktrees/[id]/schedules/route.js +3 -3
  125. package/.next/server/app/api/worktrees/[id]/schedules/route_client-reference-manifest.js +1 -1
  126. package/.next/server/app/api/worktrees/[id]/search/route_client-reference-manifest.js +1 -1
  127. package/.next/server/app/api/worktrees/[id]/send/route_client-reference-manifest.js +1 -1
  128. package/.next/server/app/api/worktrees/[id]/skills/[skillId]/git-workflow/route_client-reference-manifest.js +1 -1
  129. package/.next/server/app/api/worktrees/[id]/skills/[skillId]/install/route_client-reference-manifest.js +1 -1
  130. package/.next/server/app/api/worktrees/[id]/skills/[skillId]/plan/route_client-reference-manifest.js +1 -1
  131. package/.next/server/app/api/worktrees/[id]/skills/[skillId]/uninstall/route_client-reference-manifest.js +1 -1
  132. package/.next/server/app/api/worktrees/[id]/skills/[skillId]/uninstall-plan/route_client-reference-manifest.js +1 -1
  133. package/.next/server/app/api/worktrees/[id]/skills/[skillId]/update/route_client-reference-manifest.js +1 -1
  134. package/.next/server/app/api/worktrees/[id]/skills/[skillId]/update-plan/route_client-reference-manifest.js +1 -1
  135. package/.next/server/app/api/worktrees/[id]/skills/route_client-reference-manifest.js +1 -1
  136. package/.next/server/app/api/worktrees/[id]/slash-commands/route_client-reference-manifest.js +1 -1
  137. package/.next/server/app/api/worktrees/[id]/special-keys/route_client-reference-manifest.js +1 -1
  138. package/.next/server/app/api/worktrees/[id]/tasks/route_client-reference-manifest.js +1 -1
  139. package/.next/server/app/api/worktrees/[id]/terminal/route_client-reference-manifest.js +1 -1
  140. package/.next/server/app/api/worktrees/[id]/timers/history/route_client-reference-manifest.js +1 -1
  141. package/.next/server/app/api/worktrees/[id]/timers/route_client-reference-manifest.js +1 -1
  142. package/.next/server/app/api/worktrees/[id]/todos/[todoId]/route_client-reference-manifest.js +1 -1
  143. package/.next/server/app/api/worktrees/[id]/todos/route_client-reference-manifest.js +1 -1
  144. package/.next/server/app/api/worktrees/[id]/tree/[...path]/route_client-reference-manifest.js +1 -1
  145. package/.next/server/app/api/worktrees/[id]/tree/route_client-reference-manifest.js +1 -1
  146. package/.next/server/app/api/worktrees/[id]/upload/[...path]/route_client-reference-manifest.js +1 -1
  147. package/.next/server/app/api/worktrees/[id]/verify/config/route_client-reference-manifest.js +1 -1
  148. package/.next/server/app/api/worktrees/[id]/verify/route_client-reference-manifest.js +1 -1
  149. package/.next/server/app/api/worktrees/[id]/verify/runs/[runId]/cancel/route_client-reference-manifest.js +1 -1
  150. package/.next/server/app/api/worktrees/[id]/verify/runs/[runId]/route_client-reference-manifest.js +1 -1
  151. package/.next/server/app/api/worktrees/[id]/verify/runs/route_client-reference-manifest.js +1 -1
  152. package/.next/server/app/api/worktrees/[id]/viewed/route_client-reference-manifest.js +1 -1
  153. package/.next/server/app/api/worktrees/apply-default-agents/route_client-reference-manifest.js +1 -1
  154. package/.next/server/app/api/worktrees/route.js +1 -1
  155. package/.next/server/app/api/worktrees/route_client-reference-manifest.js +1 -1
  156. package/.next/server/app/login/page.js +1 -1
  157. package/.next/server/app/login/page.js.nft.json +1 -1
  158. package/.next/server/app/login/page_client-reference-manifest.js +1 -1
  159. package/.next/server/app/manifest.webmanifest/route_client-reference-manifest.js +1 -1
  160. package/.next/server/app/more/page.js +1 -1
  161. package/.next/server/app/more/page.js.nft.json +1 -1
  162. package/.next/server/app/more/page_client-reference-manifest.js +1 -1
  163. package/.next/server/app/offline/page.js +1 -1
  164. package/.next/server/app/offline/page.js.nft.json +1 -1
  165. package/.next/server/app/offline/page_client-reference-manifest.js +1 -1
  166. package/.next/server/app/page.js +1 -1
  167. package/.next/server/app/page.js.nft.json +1 -1
  168. package/.next/server/app/page_client-reference-manifest.js +1 -1
  169. package/.next/server/app/proxy/[...path]/route_client-reference-manifest.js +1 -1
  170. package/.next/server/app/repositories/page.js +2 -2
  171. package/.next/server/app/repositories/page.js.nft.json +1 -1
  172. package/.next/server/app/repositories/page_client-reference-manifest.js +1 -1
  173. package/.next/server/app/review/page.js +1 -1
  174. package/.next/server/app/review/page.js.nft.json +1 -1
  175. package/.next/server/app/review/page_client-reference-manifest.js +1 -1
  176. package/.next/server/app/sessions/page.js +1 -1
  177. package/.next/server/app/sessions/page.js.nft.json +1 -1
  178. package/.next/server/app/sessions/page_client-reference-manifest.js +1 -1
  179. package/.next/server/app/skills/[skillId]/page.js +2 -2
  180. package/.next/server/app/skills/[skillId]/page.js.nft.json +1 -1
  181. package/.next/server/app/skills/[skillId]/page_client-reference-manifest.js +1 -1
  182. package/.next/server/app/skills/installed/page.js +1 -1
  183. package/.next/server/app/skills/installed/page.js.nft.json +1 -1
  184. package/.next/server/app/skills/installed/page_client-reference-manifest.js +1 -1
  185. package/.next/server/app/skills/page.js +1 -1
  186. package/.next/server/app/skills/page.js.nft.json +1 -1
  187. package/.next/server/app/skills/page_client-reference-manifest.js +1 -1
  188. package/.next/server/app/worktrees/[id]/files/[...path]/page.js +1 -1
  189. package/.next/server/app/worktrees/[id]/files/[...path]/page.js.nft.json +1 -1
  190. package/.next/server/app/worktrees/[id]/files/[...path]/page_client-reference-manifest.js +1 -1
  191. package/.next/server/app/worktrees/[id]/page.js +12 -9
  192. package/.next/server/app/worktrees/[id]/page.js.nft.json +1 -1
  193. package/.next/server/app/worktrees/[id]/page_client-reference-manifest.js +1 -1
  194. package/.next/server/app/worktrees/[id]/terminal/page.js +1 -1
  195. package/.next/server/app/worktrees/[id]/terminal/page.js.nft.json +1 -1
  196. package/.next/server/app/worktrees/[id]/terminal/page_client-reference-manifest.js +1 -1
  197. package/.next/server/app-paths-manifest.json +24 -24
  198. package/.next/server/chunks/1341.js +1 -1
  199. package/.next/server/chunks/1501.js +2 -2
  200. package/.next/server/chunks/2119.js +1 -1
  201. package/.next/server/chunks/2283.js +15 -13
  202. package/.next/server/chunks/2335.js +1 -0
  203. package/.next/server/chunks/2404.js +4 -4
  204. package/.next/server/chunks/2445.js +1 -1
  205. package/.next/server/chunks/2460.js +1 -1
  206. package/.next/server/chunks/2560.js +1 -1
  207. package/.next/server/chunks/3543.js +1 -1
  208. package/.next/server/chunks/3945.js +1 -1
  209. package/.next/server/chunks/4072.js +15 -0
  210. package/.next/server/chunks/4207.js +1 -1
  211. package/.next/server/chunks/{4802.js → 4243.js} +1 -1
  212. package/.next/server/chunks/4718.js +3 -3
  213. package/.next/server/chunks/4837.js +3 -3
  214. package/.next/server/chunks/5209.js +1 -1
  215. package/.next/server/chunks/5625.js +2 -2
  216. package/.next/server/chunks/6130.js +1 -1
  217. package/.next/server/chunks/6345.js +1 -0
  218. package/.next/server/chunks/6401.js +1 -1
  219. package/.next/server/chunks/6722.js +1 -0
  220. package/.next/server/chunks/8098.js +1 -1
  221. package/.next/server/chunks/8356.js +1 -1
  222. package/.next/server/chunks/8581.js +25 -29
  223. package/.next/server/chunks/8728.js +1 -1
  224. package/.next/server/chunks/8800.js +4 -4
  225. package/.next/server/chunks/9731.js +1 -1
  226. package/.next/server/chunks/9862.js +1 -0
  227. package/.next/server/middleware-build-manifest.js +1 -1
  228. package/.next/server/middleware-manifest.json +5 -5
  229. package/.next/server/middleware-react-loadable-manifest.js +1 -1
  230. package/.next/server/pages/500.html +1 -1
  231. package/.next/server/pages/_error.js +2 -2
  232. package/.next/server/server-reference-manifest.json +1 -1
  233. package/.next/static/chunks/{7485.8a2a9d7c5396aa26.js → 1111.5ab4f0ffb0d944e5.js} +2 -2
  234. package/.next/static/chunks/{2407-dd4a0f04f1349221.js → 2407-acb644c5487e1720.js} +1 -1
  235. package/.next/static/chunks/{2619-a305ad4810f1393a.js → 2619-04bc32f026a0d946.js} +1 -1
  236. package/.next/static/chunks/2717.21abf5b6bbd45520.js +1 -0
  237. package/.next/static/chunks/2770-db80aedf6384d594.js +1 -0
  238. package/.next/static/chunks/2863-6a07ec82fb52f4dd.js +1 -0
  239. package/.next/static/chunks/3201-c01f1feed69020e6.js +1 -0
  240. package/.next/static/chunks/3662-5a27ee39a3ecba49.js +1 -0
  241. package/.next/static/chunks/4541-b0ce0bf829ae79b7.js +1 -0
  242. package/.next/static/chunks/4768-ad6f82f034f21eae.js +1 -0
  243. package/.next/static/chunks/5371-a94ed618148287a0.js +1 -0
  244. package/.next/static/chunks/5794-947fb4934d8be193.js +1 -0
  245. package/.next/static/chunks/5927-54315d21f323e204.js +1 -0
  246. package/.next/static/chunks/602-25e45a2422d2a3ea.js +1 -0
  247. package/.next/static/chunks/6288-09feba367cc2c65e.js +1 -0
  248. package/.next/static/chunks/6606-02ddc006686a6b7d.js +1 -0
  249. package/.next/static/chunks/6654-f3534f35f16644bc.js +1 -0
  250. package/.next/static/chunks/7730-011e137be64403ae.js +1 -0
  251. package/.next/static/chunks/8165-263172c17ae8e8c3.js +1 -0
  252. package/.next/static/chunks/8606-cf6bdbff44a764cf.js +1 -0
  253. package/.next/static/chunks/934-a37509667baa86ee.js +1 -0
  254. package/.next/static/chunks/9465-e5a351baa941f31b.js +1 -0
  255. package/.next/static/chunks/953.31c52a251deda22d.js +1 -0
  256. package/.next/static/chunks/app/layout-ae30ce63569c22be.js +1 -0
  257. package/.next/static/chunks/app/repositories/page-71f5a5ac29b0370d.js +1 -0
  258. package/.next/static/chunks/app/review/page-e2fd4a590646a2d8.js +1 -0
  259. package/.next/static/chunks/app/sessions/page-9859ed61e93e6890.js +1 -0
  260. package/.next/static/chunks/app/skills/[skillId]/page-52ba58712faf3378.js +1 -0
  261. package/.next/static/chunks/app/worktrees/[id]/files/[...path]/page-9cf1ecc59e36a004.js +1 -0
  262. package/.next/static/chunks/app/worktrees/[id]/page-2eb1d0fd0a077b7e.js +1 -0
  263. package/.next/static/chunks/app/worktrees/[id]/terminal/{page-c601f3b3ece6557e.js → page-373ea37b16d930c7.js} +1 -1
  264. package/.next/static/chunks/{webpack-165d8df9acd1c5d4.js → webpack-c0b821f340afdebf.js} +1 -1
  265. package/.next/static/css/743f79ff19ab91e9.css +1 -0
  266. package/.next/trace +13 -13
  267. package/dist/server/locales/en/worktree.json +48 -17
  268. package/dist/server/locales/ja/worktree.json +48 -17
  269. package/dist/server/src/config/activity-bar-config.js +56 -9
  270. package/dist/server/src/lib/auto-yes-poller.js +16 -163
  271. package/dist/server/src/lib/polling/auto-yes-enter-fallback-state.js +1 -1
  272. package/dist/server/src/lib/polling/auto-yes-poller-state.js +52 -0
  273. package/dist/server/src/lib/polling/auto-yes-prompt-suppression.js +125 -0
  274. package/dist/server/src/lib/polling/prompt-dedup-state.js +26 -7
  275. package/dist/server/src/lib/polling/prompt-dedup.js +125 -6
  276. package/dist/server/src/lib/polling/response-checker.js +53 -2
  277. package/dist/server/src/lib/polling/response-dedup.js +159 -14
  278. package/dist/server/src/lib/polling/response-poller-core.js +47 -26
  279. package/dist/server/src/lib/session/next-action-helper.js +2 -15
  280. package/dist/server/src/lib/verification/env-clean-gate.js +14 -1
  281. package/dist/server/src/lib/verification/gate-runner.js +17 -11
  282. package/dist/server/src/lib/verification/scope-gate.js +169 -3
  283. package/dist/server/src/types/sidebar.js +1 -0
  284. package/docs/en/architecture.md +26 -14
  285. package/docs/en/user-guide/webapp-guide.md +31 -18
  286. package/package.json +1 -1
  287. package/release-notes/0.45.1.json +38 -0
  288. package/release-notes/0.46.0.json +110 -0
  289. package/.next/server/chunks/1674.js +0 -15
  290. package/.next/server/chunks/364.js +0 -1
  291. package/.next/server/chunks/488.js +0 -1
  292. package/.next/server/chunks/5326.js +0 -1
  293. package/.next/server/chunks/6927.js +0 -1
  294. package/.next/static/chunks/1642-767aed8e7c61ef7f.js +0 -1
  295. package/.next/static/chunks/2053-390e77fce43b555c.js +0 -1
  296. package/.next/static/chunks/2770-827a64760bab8a3a.js +0 -1
  297. package/.next/static/chunks/3922.f45dcfc1e7da552a.js +0 -1
  298. package/.next/static/chunks/4727-5d695d71e3fdf97b.js +0 -1
  299. package/.next/static/chunks/4768-fc0aa1d0891cac08.js +0 -1
  300. package/.next/static/chunks/5521-c358c31f60e5e689.js +0 -1
  301. package/.next/static/chunks/6192-a67df090838b9aad.js +0 -1
  302. package/.next/static/chunks/6322-f1b30ed0ee43518f.js +0 -1
  303. package/.next/static/chunks/6654-ac431270fac1a283.js +0 -1
  304. package/.next/static/chunks/8165-3525fb42f1b4976e.js +0 -1
  305. package/.next/static/chunks/8283-26ad31a4670ea52d.js +0 -1
  306. package/.next/static/chunks/8318-01e7d1e5ad0a15a3.js +0 -1
  307. package/.next/static/chunks/8566-aeda747542072ace.js +0 -1
  308. package/.next/static/chunks/8606-79c36d4c204bbd38.js +0 -1
  309. package/.next/static/chunks/8811-29eaa24237f48558.js +0 -1
  310. package/.next/static/chunks/953.19e4c8178c9eac4c.js +0 -1
  311. package/.next/static/chunks/9619-6c17a271f7f98fbb.js +0 -1
  312. package/.next/static/chunks/998-2eb5883186abd0bd.js +0 -1
  313. package/.next/static/chunks/app/layout-07d040cb3d3ea657.js +0 -1
  314. package/.next/static/chunks/app/repositories/page-6f7511f4ac8449e2.js +0 -1
  315. package/.next/static/chunks/app/review/page-95f749caae382f46.js +0 -1
  316. package/.next/static/chunks/app/sessions/page-2af68c63211c751f.js +0 -1
  317. package/.next/static/chunks/app/skills/[skillId]/page-9ee7a381636e60cb.js +0 -1
  318. package/.next/static/chunks/app/worktrees/[id]/files/[...path]/page-5445205c8dd80109.js +0 -1
  319. package/.next/static/chunks/app/worktrees/[id]/page-35f0e31a725d1c89.js +0 -1
  320. package/.next/static/css/057f64a65726c439.css +0 -1
  321. /package/.next/static/{TPWbZB3zBp3Zv_eFEOlmt → zI2nQ6WKboSbFbMF4EtrJ}/_buildManifest.js +0 -0
  322. /package/.next/static/{TPWbZB3zBp3Zv_eFEOlmt → zI2nQ6WKboSbFbMF4EtrJ}/_ssgManifest.js +0 -0
@@ -1,4 +1,4 @@
1
- "use strict";exports.id=4207,exports.ids=[4207],exports.modules={20137:(a,b,c)=>{c.d(b,{Ar:()=>d,Cb:()=>v,En:()=>k,Fs:()=>q,Hf:()=>t,Tp:()=>j,Ww:()=>e,XI:()=>w,dq:()=>l,eb:()=>i,iI:()=>y,kd:()=>f,o1:()=>g,oN:()=>h,u7:()=>r});let d=100,e=1e4,f=["default","acceptEdits","plan","dontAsk","bypassPermissions"],g=["read-only","workspace-write","danger-full-access"],h=["allow-all-tools","yolo"],i=["--dangerously-skip-permissions"],j=["default","standard","plan","auto-accept","dont-ask"],k="yolo",l=[k,...j],m=[],n=[],o=[],p="default",q="auto",r=[p,q],s=[],t={claude:"acceptEdits",codex:"workspace-write",gemini:"","vibe-local":"",opencode:"",copilot:"allow-all-tools",antigravity:"--dangerously-skip-permissions","command-code":k,"opencode-v2":p},u=[];function v(a){return!u.includes(a)}function w(a){switch(a){case"claude":return f;case"codex":return g;case"copilot":return h;case"antigravity":return i;case"command-code":return l;case"gemini":return m;case"vibe-local":return n;case"opencode":return o;case"opencode-v2":return r;default:return s}}let x=/^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i;function y(a){return x.test(a)}},34207:(a,b,c)=>{c.d(b,{$2:()=>u,$g:()=>y,To:()=>t,V$:()=>B,iv:()=>m,uv:()=>l});var d=c(79646),e=c(67548),f=c(73434),g=c(61789),h=c(15194),i=c(20137),j=c(95759),k=c(36925);let l=1e4,m=new Set(h.XH);function n(a){return 102400>=Buffer.byteLength(a,"utf-8")?a:Buffer.from(a,"utf-8").subarray(0,102400).toString("utf-8")+"\n\n--- Output truncated (exceeded 100KB limit) ---"}function o(a){let b=[],c=null;for(let d of a.split("\n")){let a,e=d.trim();if(!e.startsWith("{"))continue;try{a=JSON.parse(e)}catch{continue}if("object"!=typeof a||null===a)continue;let f=a,g="object"==typeof f.part&&null!==f.part?f.part:null;if("text"===f.type&&g&&"string"==typeof g.text){b.push({messageId:"string"==typeof g.messageID?g.messageID:null,text:g.text});continue}"error"===f.type&&(c=p(f))}if(b.length>0){let a=b[b.length-1].messageId;return(null===a?[b[b.length-1]]:b.filter(b=>b.messageId===a)).map(a=>a.text).join("\n\n")}return c}function p(a){let b="object"==typeof a.error&&null!==a.error?a.error:{},c="string"==typeof b.name?b.name:"string"==typeof b.type?b.type:"error",d="object"==typeof b.data&&null!==b.data?b.data:{},e="string"==typeof d.message?d.message:"string"==typeof b.message?b.message:"";return e?`opencode error: ${c}: ${e}`:`opencode error: ${c}`}function q(a){let b=null;for(let c of a.split("\n")){let a=c.trim();if(a.startsWith("{"))try{let c=JSON.parse(a);"object"==typeof c&&null!==c&&(b=c)}catch{continue}}return b&&"error"===b.type?p(b):null}let r={1:"error",3:"authentication failed",4:"permission denied",5:"rate limited",6:"connection error",7:"server error",8:"max turns reached",9:"no response",10:"insufficient credits",130:"interrupted"};function s(a){let b=null,c=[],d=0;for(let e of a.split("\n")){let a,f=e.trim();if(!f.startsWith("{"))continue;try{a=JSON.parse(f)}catch{continue}if("object"!=typeof a||null===a)continue;let g=a;if("result"===g.type){if("string"!=typeof g.subtype)continue;b={subtype:g.subtype,finalText:"string"==typeof g.finalText?g.finalText:"",..."string"==typeof g.error?{error:g.error}:{}};continue}if("event"!==g.type||"object"!=typeof g.event||null===g.event)continue;let h=g.event;if("tool_running"===h.type){d+=1;continue}"tool_hook_blocked"===h.type&&c.push({toolCallId:"string"==typeof h.toolCallId?h.toolCallId:null,toolName:"string"==typeof h.toolName&&""!==h.toolName?h.toolName:"(unnamed tool)",hookOutput:"string"==typeof h.hookOutput?h.hookOutput:""})}return{result:b,blockedToolCalls:c,startedToolCalls:d}}let t="Warning: command-code blocked ",u=1024,v=/^Warning: command-code blocked \d+ tool call\(s\) \(tool_hook_blocked\): /;function w(a,b){let c=(0,g.aJ)(a).replace(/[\x00-\x1f\x7f\s]+/g," ").trim();return c.length>b?`${c.slice(0,b)}…`:c}function x(a){let{blockedToolCalls:b,startedToolCalls:c}=a;if(0===b.length)return null;let d=new Map,e=new Map;for(let a of b){let b=w(a.toolName,80);d.set(b,(d.get(b)??0)+1);let c=w(a.hookOutput,300)||"(no hook output)",f=JSON.stringify([b,c]);e.has(f)||e.set(f,`Blocked ${b}: ${c}`)}let f=[...d].slice(0,5).map(([a,b])=>`${a} (${b})`);d.size>5&&f.push(`+${d.size-5} more`);let g=`${t}${b.length} tool call(s) (tool_hook_blocked): ${f.join(", ")}; ${c} tool call(s) ran`,h=[...e.values()].slice(0,5);return e.size>5&&h.push(`Blocked: +${e.size-5} more distinct reason(s)`),[g,...h]}function y(a){if("string"!=typeof a)return null;let b=a.indexOf("\n"),c=-1===b?a:a.slice(0,b);return v.test(c)?c:null}function z(a,b){let c=null!==b&&"success"!==b.subtype;if((null===a||0===a)&&!c)return null;let d=[];if(null!==a&&0!==a){let b=r[a];d.push(b?`exit ${a} (${b})`:`exit ${a}`)}return b&&(d.push(`subtype=${b.subtype}`),b.error&&d.push(b.error)),`Reason: command-code ${d.join(" / ")}`}let A={codex:"$CODEX_HOME/hooks.json",antigravity:"~/.gemini/config/hooks.json"};async function B(a,b,c="claude",h,p){if(!m.has(c))return{output:"",exitCode:null,status:"failed",error:`Invalid CLI tool: ${c}`};let r=function(a){if(!(0,e.WM)())return null;let b=A[a];return b?new e.ci(`a headless ${a} run`,`it reads the shared ${b} and its hooks post to the relay's default port (the production server); see docs/user-guide/uat-isolation.md`,"Headless codex / antigravity runs (Schedules, daily summary) cannot be isolated; skip those scenarios in a UAT.").message:null}(c);if(r)return{output:r,exitCode:null,status:"failed",error:r};let t=function(a,b,c,d){switch(b){case"codex":return["exec",a,"--sandbox",c??"workspace-write"];case"gemini":return["-p",a];case"vibe-local":if(d?.model)return["--model",d.model,"-p",a,"-y"];return["-p",a,"-y"];case"opencode":{let b=["run","--format","json"];return d?.model&&b.push("-m",d.model),d?.agent&&b.push("--agent",d.agent),d?.variant&&b.push("--variant",d.variant),d?.continueSession&&b.push("-c"),d?.title&&b.push("--title",d.title),b.push(a),b}case"opencode-v2":{let b=["run","--standalone","--format","json"];return c===i.Fs&&b.push("--auto"),d?.model&&b.push("-m",d.variant?`${d.model}#${d.variant}`:d.model),d?.agent&&b.push("--agent",d.agent),d?.continueSession&&b.push("-c"),d?.title&&b.push("--title",d.title),b.push("--",a),b}case"command-code":{let b=["-p",a,"--output-format","json"];return c===i.En?b.push("--yolo"):i.Tp.includes(c)?b.push("--permission-mode",c):b.push("--yolo"),b.push("--no-auto-update"),b}case"antigravity":return["-p",a,"--dangerously-skip-permissions"];case"copilot":{let b=i.oN.includes(c)?c:"allow-all-tools",e=["copilot"];return d?.model&&e.push("--model",d.model),e.push("-p",a,`--${b}`),e}default:{let b=["-p",a,"--output-format","text","--permission-mode",c??"acceptEdits"];return(0,e.WM)()&&b.push("--setting-sources",e.mc),b}}}(a.length>l?a.substring(0,l):a,c,h,p),u=function(a){switch(a){case"copilot":return"gh";case"antigravity":return"agy";case"command-code":return"commandcode";case"opencode-v2":return j.b6;default:return a}}(c);if("opencode-v2"===c){let a=await (0,j.Qq)();if(!a.executable){let a="OpenCode V2 not found: no `opencode2` (or `opencode` reporting v2) on PATH";return{output:a,exitCode:null,status:"failed",error:a}}u=a.executable.path}let v="opencode-v2"===c?{...(0,f.hh)(),PWD:b}:(0,f.hh)();return new Promise(a=>{let e=(0,d.execFile)(u,t,{cwd:b,env:v,maxBuffer:0xa00000,timeout:p?.timeoutMs??18e5},(b,d,e)=>{if(b){let f=b.code,h="ERR_CHILD_PROCESS_STDIO_MAXBUFFER"===f,i=b.killed||"ETIMEDOUT"===f,j="command-code"===c?s(d||""):null,k=j?j.result:null,l=j?x(j):null,m="number"==typeof f?f:null,p="opencode-v2"===c,r=[...l??[],`Error: ${b.message}`,`Code: ${f??"unknown"}`,`Signal: ${b.signal??"none"}`,h?"Reason: stdout exceeded execFile maxBuffer (output_limit)":null,"command-code"===c?z(m,k):null,p?function(a,b){if(/permission requested: .*auto-rejecting/.test((0,g.aJ)(b)))return"Reason: opencode-v2 auto-rejected a permission request (an `ask` rule); set the schedule's Permission to `auto` to approve it unattended";let c=q(a);return c?`Reason: ${c}`:null}(d||"",e||""):null].filter(a=>null!==a).join("\n"),t=k?k.finalText:p?o(d||"")??(d||""):d||"";a({output:n((0,g.aJ)([r,t?`
1
+ "use strict";exports.id=4207,exports.ids=[4207],exports.modules={20137:(a,b,c)=>{c.d(b,{Ar:()=>d,Cb:()=>v,En:()=>k,Fs:()=>q,Hf:()=>t,Tp:()=>j,Ww:()=>e,XI:()=>w,dq:()=>l,eb:()=>i,iI:()=>y,kd:()=>f,o1:()=>g,oN:()=>h,u7:()=>r});let d=100,e=1e4,f=["default","acceptEdits","plan","dontAsk","bypassPermissions"],g=["read-only","workspace-write","danger-full-access"],h=["allow-all-tools","yolo"],i=["--dangerously-skip-permissions"],j=["default","standard","plan","auto-accept","dont-ask"],k="yolo",l=[k,...j],m=[],n=[],o=[],p="default",q="auto",r=[p,q],s=[],t={claude:"acceptEdits",codex:"workspace-write",gemini:"","vibe-local":"",opencode:"",copilot:"allow-all-tools",antigravity:"--dangerously-skip-permissions","command-code":k,"opencode-v2":p},u=[];function v(a){return!u.includes(a)}function w(a){switch(a){case"claude":return f;case"codex":return g;case"copilot":return h;case"antigravity":return i;case"command-code":return l;case"gemini":return m;case"vibe-local":return n;case"opencode":return o;case"opencode-v2":return r;default:return s}}let x=/^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i;function y(a){return x.test(a)}},34207:(a,b,c)=>{c.d(b,{$2:()=>u,$g:()=>y,To:()=>t,V$:()=>B,iv:()=>m,uv:()=>l});var d=c(79646),e=c(67548),f=c(73434),g=c(61789),h=c(15194),i=c(20137),j=c(18140),k=c(36925);let l=1e4,m=new Set(h.XH);function n(a){return 102400>=Buffer.byteLength(a,"utf-8")?a:Buffer.from(a,"utf-8").subarray(0,102400).toString("utf-8")+"\n\n--- Output truncated (exceeded 100KB limit) ---"}function o(a){let b=[],c=null;for(let d of a.split("\n")){let a,e=d.trim();if(!e.startsWith("{"))continue;try{a=JSON.parse(e)}catch{continue}if("object"!=typeof a||null===a)continue;let f=a,g="object"==typeof f.part&&null!==f.part?f.part:null;if("text"===f.type&&g&&"string"==typeof g.text){b.push({messageId:"string"==typeof g.messageID?g.messageID:null,text:g.text});continue}"error"===f.type&&(c=p(f))}if(b.length>0){let a=b[b.length-1].messageId;return(null===a?[b[b.length-1]]:b.filter(b=>b.messageId===a)).map(a=>a.text).join("\n\n")}return c}function p(a){let b="object"==typeof a.error&&null!==a.error?a.error:{},c="string"==typeof b.name?b.name:"string"==typeof b.type?b.type:"error",d="object"==typeof b.data&&null!==b.data?b.data:{},e="string"==typeof d.message?d.message:"string"==typeof b.message?b.message:"";return e?`opencode error: ${c}: ${e}`:`opencode error: ${c}`}function q(a){let b=null;for(let c of a.split("\n")){let a=c.trim();if(a.startsWith("{"))try{let c=JSON.parse(a);"object"==typeof c&&null!==c&&(b=c)}catch{continue}}return b&&"error"===b.type?p(b):null}let r={1:"error",3:"authentication failed",4:"permission denied",5:"rate limited",6:"connection error",7:"server error",8:"max turns reached",9:"no response",10:"insufficient credits",130:"interrupted"};function s(a){let b=null,c=[],d=0;for(let e of a.split("\n")){let a,f=e.trim();if(!f.startsWith("{"))continue;try{a=JSON.parse(f)}catch{continue}if("object"!=typeof a||null===a)continue;let g=a;if("result"===g.type){if("string"!=typeof g.subtype)continue;b={subtype:g.subtype,finalText:"string"==typeof g.finalText?g.finalText:"",..."string"==typeof g.error?{error:g.error}:{}};continue}if("event"!==g.type||"object"!=typeof g.event||null===g.event)continue;let h=g.event;if("tool_running"===h.type){d+=1;continue}"tool_hook_blocked"===h.type&&c.push({toolCallId:"string"==typeof h.toolCallId?h.toolCallId:null,toolName:"string"==typeof h.toolName&&""!==h.toolName?h.toolName:"(unnamed tool)",hookOutput:"string"==typeof h.hookOutput?h.hookOutput:""})}return{result:b,blockedToolCalls:c,startedToolCalls:d}}let t="Warning: command-code blocked ",u=1024,v=/^Warning: command-code blocked \d+ tool call\(s\) \(tool_hook_blocked\): /;function w(a,b){let c=(0,g.aJ)(a).replace(/[\x00-\x1f\x7f\s]+/g," ").trim();return c.length>b?`${c.slice(0,b)}…`:c}function x(a){let{blockedToolCalls:b,startedToolCalls:c}=a;if(0===b.length)return null;let d=new Map,e=new Map;for(let a of b){let b=w(a.toolName,80);d.set(b,(d.get(b)??0)+1);let c=w(a.hookOutput,300)||"(no hook output)",f=JSON.stringify([b,c]);e.has(f)||e.set(f,`Blocked ${b}: ${c}`)}let f=[...d].slice(0,5).map(([a,b])=>`${a} (${b})`);d.size>5&&f.push(`+${d.size-5} more`);let g=`${t}${b.length} tool call(s) (tool_hook_blocked): ${f.join(", ")}; ${c} tool call(s) ran`,h=[...e.values()].slice(0,5);return e.size>5&&h.push(`Blocked: +${e.size-5} more distinct reason(s)`),[g,...h]}function y(a){if("string"!=typeof a)return null;let b=a.indexOf("\n"),c=-1===b?a:a.slice(0,b);return v.test(c)?c:null}function z(a,b){let c=null!==b&&"success"!==b.subtype;if((null===a||0===a)&&!c)return null;let d=[];if(null!==a&&0!==a){let b=r[a];d.push(b?`exit ${a} (${b})`:`exit ${a}`)}return b&&(d.push(`subtype=${b.subtype}`),b.error&&d.push(b.error)),`Reason: command-code ${d.join(" / ")}`}let A={codex:"$CODEX_HOME/hooks.json",antigravity:"~/.gemini/config/hooks.json"};async function B(a,b,c="claude",h,p){if(!m.has(c))return{output:"",exitCode:null,status:"failed",error:`Invalid CLI tool: ${c}`};let r=function(a){if(!(0,e.WM)())return null;let b=A[a];return b?new e.ci(`a headless ${a} run`,`it reads the shared ${b} and its hooks post to the relay's default port (the production server); see docs/user-guide/uat-isolation.md`,"Headless codex / antigravity runs (Schedules, daily summary) cannot be isolated; skip those scenarios in a UAT.").message:null}(c);if(r)return{output:r,exitCode:null,status:"failed",error:r};let t=function(a,b,c,d){switch(b){case"codex":return["exec",a,"--sandbox",c??"workspace-write"];case"gemini":return["-p",a];case"vibe-local":if(d?.model)return["--model",d.model,"-p",a,"-y"];return["-p",a,"-y"];case"opencode":{let b=["run","--format","json"];return d?.model&&b.push("-m",d.model),d?.agent&&b.push("--agent",d.agent),d?.variant&&b.push("--variant",d.variant),d?.continueSession&&b.push("-c"),d?.title&&b.push("--title",d.title),b.push(a),b}case"opencode-v2":{let b=["run","--standalone","--format","json"];return c===i.Fs&&b.push("--auto"),d?.model&&b.push("-m",d.variant?`${d.model}#${d.variant}`:d.model),d?.agent&&b.push("--agent",d.agent),d?.continueSession&&b.push("-c"),d?.title&&b.push("--title",d.title),b.push("--",a),b}case"command-code":{let b=["-p",a,"--output-format","json"];return c===i.En?b.push("--yolo"):i.Tp.includes(c)?b.push("--permission-mode",c):b.push("--yolo"),b.push("--no-auto-update"),b}case"antigravity":return["-p",a,"--dangerously-skip-permissions"];case"copilot":{let b=i.oN.includes(c)?c:"allow-all-tools",e=["copilot"];return d?.model&&e.push("--model",d.model),e.push("-p",a,`--${b}`),e}default:{let b=["-p",a,"--output-format","text","--permission-mode",c??"acceptEdits"];return(0,e.WM)()&&b.push("--setting-sources",e.mc),b}}}(a.length>l?a.substring(0,l):a,c,h,p),u=function(a){switch(a){case"copilot":return"gh";case"antigravity":return"agy";case"command-code":return"commandcode";case"opencode-v2":return j.b6;default:return a}}(c);if("opencode-v2"===c){let a=await (0,j.Qq)();if(!a.executable){let a="OpenCode V2 not found: no `opencode2` (or `opencode` reporting v2) on PATH";return{output:a,exitCode:null,status:"failed",error:a}}u=a.executable.path}let v="opencode-v2"===c?{...(0,f.hh)(),PWD:b}:(0,f.hh)();return new Promise(a=>{let e=(0,d.execFile)(u,t,{cwd:b,env:v,maxBuffer:0xa00000,timeout:p?.timeoutMs??18e5},(b,d,e)=>{if(b){let f=b.code,h="ERR_CHILD_PROCESS_STDIO_MAXBUFFER"===f,i=b.killed||"ETIMEDOUT"===f,j="command-code"===c?s(d||""):null,k=j?j.result:null,l=j?x(j):null,m="number"==typeof f?f:null,p="opencode-v2"===c,r=[...l??[],`Error: ${b.message}`,`Code: ${f??"unknown"}`,`Signal: ${b.signal??"none"}`,h?"Reason: stdout exceeded execFile maxBuffer (output_limit)":null,"command-code"===c?z(m,k):null,p?function(a,b){if(/permission requested: .*auto-rejecting/.test((0,g.aJ)(b)))return"Reason: opencode-v2 auto-rejected a permission request (an `ask` rule); set the schedule's Permission to `auto` to approve it unattended";let c=q(a);return c?`Reason: ${c}`:null}(d||"",e||""):null].filter(a=>null!==a).join("\n"),t=k?k.finalText:p?o(d||"")??(d||""):d||"";a({output:n((0,g.aJ)([r,t?`
2
2
  --- stdout ---
3
3
  ${t}`:"",e?`
4
4
  --- stderr ---
@@ -1 +1 @@
1
- "use strict";exports.id=4802,exports.ids=[4802],exports.modules={9758:(a,b,c)=>{c.d(b,{Ck:()=>h});var d=c(21124),e=c(38301),f=c.n(e),g=c(62484);function h({children:a,as:b="div",className:c=""}){let e=function a(b){return null==b||"boolean"==typeof b?"":"string"==typeof b?b:"number"==typeof b?String(b):Array.isArray(b)?b.map(a).join(""):f().isValidElement(b)?a(b.props.children):""}(a);if(!e||0===e.trim().length)return(0,d.jsx)(b,{className:c||void 0,children:a});let h=`relative group ${"span"===b?"block ":""}${c}`.trim();return(0,d.jsxs)(b,{className:h,"data-testid":"code-block-with-copy",children:[a,(0,d.jsx)(g.i,{text:e,className:"absolute right-2 top-2 z-10 opacity-100 md:opacity-0 md:group-hover:opacity-100 md:group-focus-within:opacity-100 focus:opacity-100"})]})}},9815:(a,b,c)=>{c.d(b,{B:()=>B});var d=c(21124),e=c(38301),f=c(20481),g=c(85866),h=c(17252),i=c(90349),j=c(85389),k=c(3805);let l={status:"loading",options:[]};function m({selectedWorktreeId:a,onSelect:b,disabled:c=!1}){let h=(0,f.c)("skills"),[i,j]=(0,e.useState)(l),[m,o]=(0,e.useState)(0),p=(0,e.useCallback)(()=>o(a=>a+1),[]);return"loading"===i.status?(0,d.jsxs)("div",{className:"space-y-2","data-testid":"skill-target-loading",children:[(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:h("target.loading")}),(0,d.jsx)(g.EA,{className:"h-24 w-full rounded-lg"})]}):"error"===i.status?(0,d.jsxs)(g.Zp,{className:"space-y-3","data-testid":"skill-target-error",children:[(0,d.jsx)(k.u,{tone:"danger",children:h("target.errorNotice")}),(0,d.jsx)(g.$n,{variant:"secondary",size:"sm",onClick:p,"data-testid":"skill-target-retry",children:h("target.retry")})]}):0===i.options.length?(0,d.jsx)(g.Zp,{"data-testid":"skill-target-empty",children:(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:h("target.empty")})}):(0,d.jsxs)("div",{className:"space-y-3","data-testid":"skill-target-selector",children:[(0,d.jsx)("div",{role:"radiogroup","aria-label":h("target.heading"),className:"space-y-2",children:i.options.map(e=>(0,d.jsx)(n,{option:e,selected:e.id===a,disabled:c,onSelect:b},e.id))}),(0,d.jsx)(k.u,{tone:"neutral","data-testid":"skill-target-branch-notice",children:h("target.branchFreshnessNotice")})]})}function n({option:a,selected:b,disabled:c,onSelect:e}){let h=(0,f.c)("skills"),i=a.liveBranch??a.syncedBranch;return(0,d.jsxs)("button",{type:"button",role:"radio","aria-checked":b,disabled:c,onClick:()=>e(a.id),"data-testid":`skill-target-option-${a.id}`,className:`w-full rounded-lg border px-3 py-2.5 text-left transition-colors disabled:cursor-not-allowed disabled:opacity-60 ${b?"border-accent-500 bg-accent-50 dark:bg-accent-950/40":"border-border bg-card hover:bg-muted"}`,children:[(0,d.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,d.jsx)("span",{className:"text-sm font-semibold text-foreground break-all",children:a.name}),b&&(0,d.jsx)(g.Ex,{variant:"info",children:h("target.selected")})]}),(0,d.jsxs)("dl",{className:"mt-1.5 grid grid-cols-1 gap-x-4 gap-y-1 sm:grid-cols-2",children:[(0,d.jsx)(o,{label:h("target.repository"),children:a.repositoryName}),(0,d.jsx)(o,{label:h("target.branch"),children:i??h("target.branchUnknown")}),(0,d.jsx)(o,{label:h("target.agents"),children:a.agents.length>0?a.agents.join(", "):h("target.agentsNone")}),(0,d.jsx)(o,{label:h("target.workingTree"),children:h(null===a.dirty?"target.workingTreeUnknown":a.dirty?"target.workingTreeDirty":"target.workingTreeClean")})]}),a.sessionRunning&&(0,d.jsx)("p",{className:"mt-1.5 text-xs text-muted-foreground","data-testid":`skill-target-session-${a.id}`,children:h("target.sessionRunning")})]})}function o({label:a,children:b}){return(0,d.jsxs)("div",{className:"min-w-0",children:[(0,d.jsx)("dt",{className:"text-xs font-medium text-muted-foreground",children:a}),(0,d.jsx)("dd",{className:"text-xs text-foreground break-words",children:b})]})}var p=c(27884);function q({label:a,children:b}){return(0,d.jsxs)("div",{className:"min-w-0",children:[(0,d.jsx)("dt",{className:"text-xs font-medium text-muted-foreground",children:a}),(0,d.jsx)("dd",{className:"mt-0.5 break-words text-sm text-foreground",children:b})]})}function r({level:a,kind:b,label:c}){let e=(0,f.c)("skills");return(0,d.jsxs)(g.Ex,{variant:p.eK[a],"data-testid":`skill-plan-risk-${b}-${a}`,children:[c,": ",e(p.pP[a])]})}function s({entry:a}){let b=(0,f.c)("skills"),c=p.KL[a.reason];return(0,d.jsxs)("li",{className:"space-y-1.5 rounded-md border border-border px-3 py-2","data-testid":`skill-plan-file-${a.path}`,children:[(0,d.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,d.jsx)(g.Ex,{variant:p.tC[a.change],children:b(p.AS[a.change])}),(0,d.jsx)("span",{className:"break-all font-mono text-xs text-foreground",children:a.path}),a.generated&&(0,d.jsx)(g.Ex,{variant:"gray",children:b("plan.fileGenerated")})]}),c&&(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:b(c)}),a.gitIgnored&&(0,d.jsx)("p",{className:"text-xs text-warning-foreground",children:b("plan.gitIgnored")}),a.binary?(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:b("plan.diffBinary")}):a.diff?(0,d.jsxs)("details",{children:[(0,d.jsx)("summary",{className:"cursor-pointer text-xs text-accent-600 dark:text-accent-400",children:b("plan.diffToggle",{additions:a.additions,deletions:a.deletions})}),(0,d.jsx)("pre",{className:"mt-1 overflow-x-auto rounded bg-muted p-2 font-mono text-[11px] leading-snug text-foreground",children:a.diff}),a.diffTruncated&&(0,d.jsx)("p",{className:"mt-1 text-xs text-muted-foreground",children:b("plan.diffTruncated")})]}):null]})}function t({plan:a}){let b=(0,f.c)("skills"),{target:c,skill:e}=a,h=e.compatibility.commandmate;return(0,d.jsxs)(g.Zp,{className:"space-y-4","data-testid":"skill-install-plan",children:[(0,d.jsxs)("div",{className:"space-y-1",children:[(0,d.jsx)("h3",{className:"text-sm font-semibold text-foreground",children:b("plan.heading")}),(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:b("plan.expiresAt",{timestamp:a.expiresAt})})]}),(0,d.jsxs)("section",{className:"space-y-2",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("plan.targetHeading")}),(0,d.jsxs)("dl",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[(0,d.jsx)(q,{label:b("target.repository"),children:c.repositoryName}),(0,d.jsx)(q,{label:b("target.heading"),children:c.worktreeName}),(0,d.jsx)(q,{label:b("target.branch"),children:c.branch??b("target.branchUnknown")}),(0,d.jsx)(q,{label:b("plan.headStateLabel"),children:b(p.kF[c.headState]??"plan.headState.unknown")}),(0,d.jsx)(q,{label:b("target.workingTree"),children:c.workingTreeUnknown?b("target.workingTreeStatusUnknown"):c.workingTreeDirty?b("target.workingTreeDirty"):b("target.workingTreeClean")}),(0,d.jsx)(q,{label:b("plan.installRoot"),children:(0,d.jsx)("span",{className:"break-all font-mono text-xs",children:(c.installRoots&&c.installRoots.length>0?c.installRoots:[c.installRoot]).map(a=>(0,d.jsx)("span",{className:"block",children:a},a))})}),(0,d.jsx)(q,{label:b("plan.existingInstall"),children:c.existingInstall?b("plan.existingInstallVersion",{version:c.existingInstall.version}):b("plan.existingInstallNone")}),(0,d.jsx)(q,{label:b("detail.recommendedVersion"),children:(0,d.jsx)("span",{className:"font-mono text-xs",children:e.version})})]})]}),(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-plan-risk-section",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("plan.riskHeading")}),(0,d.jsxs)("div",{className:"flex flex-wrap gap-1.5",children:[(0,d.jsx)(r,{level:e.declaredRisk,kind:"declared",label:b("plan.riskDeclared")}),(0,d.jsx)(r,{level:e.computedRisk,kind:"computed",label:b("plan.riskComputed")}),(0,d.jsx)(r,{level:e.effectiveRisk,kind:"effective",label:b("plan.riskEffective")})]}),(0,d.jsx)("p",{className:"break-words text-sm text-foreground",children:e.riskRationale}),(0,d.jsx)(k.u,{tone:"neutral",children:b("plan.riskNotice")})]}),(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-plan-permissions",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("permissions.heading")}),e.declaredPermissions.length>0?(0,d.jsx)("div",{className:"flex flex-wrap gap-1.5",children:e.declaredPermissions.map(a=>(0,d.jsx)(g.Ex,{variant:"warning",children:p.z2[a]?b(p.z2[a]):a},a))}):(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:b("plan.permissionsNone")}),(0,d.jsx)(k.u,{tone:"warning",children:b("permissions.declarationOnlyNotice")})]}),(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-plan-requirements",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("requirements.heading")}),0===e.requirements.commands.length&&0===e.requirements.networkHosts.length?(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:b("plan.requirementsNone")}):(0,d.jsxs)("dl",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[e.requirements.commands.length>0&&(0,d.jsx)(q,{label:b("plan.requirementsCommands"),children:e.requirements.commands.map(a=>`${a.name} ${a.versionRange??b("plan.commandAnyVersion")}`).join(", ")}),e.requirements.networkHosts.length>0&&(0,d.jsx)(q,{label:b("plan.requirementsHosts"),children:e.requirements.networkHosts.join(", ")})]})]}),(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-plan-scripts",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("plan.scriptsHeading")}),0===e.executablePaths.length&&0===e.scriptPaths.length?(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:b("plan.scriptsNone")}):(0,d.jsx)("ul",{className:"space-y-1",children:[...new Set([...e.scriptPaths,...e.executablePaths])].map(a=>(0,d.jsx)("li",{className:"break-all font-mono text-xs text-foreground",children:a},a))})]}),"compatible"!==h.status&&(0,d.jsx)(k.u,{tone:"warning","data-testid":"skill-plan-compatibility-notice",children:b((0,p.e5)(h.messageKey),{range:h.requiredRange,currentVersion:h.currentVersion??""})}),a.warnings.length>0&&(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-plan-warnings",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("plan.warningsHeading")}),(0,d.jsx)("ul",{className:"space-y-1",children:a.warnings.map(a=>(0,d.jsx)("li",{className:"text-xs text-warning-foreground",children:p.RO[a]?b(p.RO[a]):a},a))})]}),(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-plan-files",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("plan.filesHeading")}),(0,d.jsx)("p",{className:"text-xs text-muted-foreground","data-testid":"skill-plan-stats",children:b("plan.stats",{added:a.stats.added,modified:a.stats.modified,unchanged:a.stats.unchanged,conflicted:a.stats.conflicted,unmanaged:a.stats.unmanaged})}),0===a.files.length?(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:b("plan.filesEmpty")}):(0,d.jsx)("ul",{className:"space-y-2",children:a.files.map(a=>(0,d.jsx)(s,{entry:a},a.path))})]}),a.blockers.length>0&&(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-install-blockers",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-danger-foreground",children:b("plan.blockersHeading")}),(0,d.jsx)("ul",{className:"space-y-1",children:a.blockers.map(a=>(0,d.jsxs)("li",{className:"text-xs text-danger-foreground",children:[a.path&&(0,d.jsx)("span",{className:"mr-1 break-all font-mono",children:a.path}),a.code.startsWith("skills.")?b((0,p.e5)(a.code),{range:h.requiredRange,currentVersion:h.currentVersion??""}):p.KL[a.code]?b(p.KL[a.code]):a.code]},`${a.code}:${a.path??""}`))}),(0,d.jsx)(k.u,{tone:"danger",children:b("plan.blockedNotice")})]})]})}function u({entry:a}){let b=(0,f.c)("skills"),c=p.Mj[a.disposition],e=p.hJ[a.reason];return(0,d.jsxs)("li",{className:"flex flex-wrap items-center gap-2","data-testid":`skill-uninstall-file-${a.path}`,children:[(0,d.jsx)(g.Ex,{variant:"remove"===a.disposition?"info":"warning",children:c?b(c):a.disposition}),(0,d.jsx)("span",{className:"break-all font-mono text-xs text-foreground",children:a.path}),e&&(0,d.jsx)("span",{className:"text-xs text-muted-foreground",children:b(e)})]})}function v({plan:a}){let b=(0,f.c)("skills"),{target:c,skill:e}=a;return(0,d.jsxs)(g.Zp,{className:"space-y-4","data-testid":"skill-uninstall-plan",children:[(0,d.jsxs)("div",{className:"space-y-1",children:[(0,d.jsx)("h3",{className:"text-sm font-semibold text-foreground",children:b("uninstall.heading")}),(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:b("uninstall.expiresAt",{timestamp:a.expiresAt})})]}),(0,d.jsxs)("dl",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[(0,d.jsx)(q,{label:b("target.repository"),children:c.repositoryName}),(0,d.jsx)(q,{label:b("target.heading"),children:c.worktreeName}),(0,d.jsx)(q,{label:b("target.branch"),children:c.branch??b("target.branchUnknown")}),(0,d.jsx)(q,{label:b("uninstall.installedVersion"),children:(0,d.jsx)("span",{className:"font-mono text-xs",children:e.version||b("uninstall.versionUnknown")})}),(0,d.jsx)(q,{label:b("plan.installRoot"),children:(0,d.jsx)("span",{className:"break-all font-mono text-xs",children:c.installRoot})}),(0,d.jsx)(q,{label:b("target.workingTree"),children:c.workingTreeUnknown?b("target.workingTreeStatusUnknown"):c.workingTreeDirty?b("target.workingTreeDirty"):b("target.workingTreeClean")})]}),(0,d.jsx)("p",{className:"text-xs text-muted-foreground","data-testid":"skill-uninstall-stats",children:b("uninstall.stats",{removable:a.stats.removable,modified:a.stats.modified,missing:a.stats.missing,unknown:a.stats.unknown,irregular:a.stats.irregular})}),(0,d.jsxs)("section",{className:"space-y-2",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("uninstall.removalsHeading")}),0===a.removals.length?(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:b("uninstall.removalsEmpty")}):(0,d.jsx)("ul",{className:"space-y-1.5",children:a.removals.map(a=>(0,d.jsx)(u,{entry:a},a.path))})]}),(0,d.jsxs)("section",{className:"space-y-2",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("uninstall.retainedHeading")}),0===a.retained.length?(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:b("uninstall.retainedEmpty")}):(0,d.jsx)("ul",{className:"space-y-1.5",children:a.retained.map(a=>(0,d.jsx)(u,{entry:a},a.path))})]}),(0,d.jsxs)("div",{className:"space-y-2",children:[a.skill.agents.length>0&&(0,d.jsx)("div",{className:"flex flex-wrap gap-1.5","data-testid":"skill-uninstall-agents",children:a.skill.agents.map(a=>(0,d.jsx)(g.Ex,{variant:"gray",children:(0,h.f_)(a.agent)},a.agent))}),(0,d.jsx)(k.u,{tone:"neutral",children:b((0,p.e5)(a.nextActionKey))})]}),a.blockers.length>0&&(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-uninstall-blockers",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-danger-foreground",children:b("uninstall.blockersHeading")}),(0,d.jsx)("ul",{className:"space-y-1",children:a.blockers.map(a=>(0,d.jsxs)("li",{className:"text-xs text-danger-foreground",children:[a.path&&(0,d.jsx)("span",{className:"mr-1 break-all font-mono",children:a.path}),b((0,p.e5)(a.messageKey))]},`${a.code}:${a.path??""}`))})]})]})}var w=c(30156);let x={worktreeId:null,busy:null,installPlan:null,uninstallPlan:null,installResult:null,uninstallResult:null,riskAcknowledged:!1,failure:null};function y(a){return{...a,installPlan:null,uninstallPlan:null,installResult:null,uninstallResult:null,riskAcknowledged:!1,failure:null}}function z({failure:a}){let b=(0,f.c)("skills");return(0,d.jsxs)("div",{className:"space-y-2","data-testid":"skill-operation-error",children:[(0,d.jsxs)(k.u,{tone:"danger",children:[(0,d.jsx)("p",{className:"font-medium",children:b("operation.errorHeading")}),(0,d.jsx)("p",{className:"mt-1",children:b((0,p.FW)(a.code))}),(0,d.jsx)("p",{className:"mt-1 break-words",children:b("state.errorCode",{code:a.code})})]}),a.nextActionKey&&(0,d.jsx)(k.u,{tone:"warning",children:b((0,p.e5)(a.nextActionKey))}),a.blockers&&a.blockers.length>0&&(0,d.jsx)("ul",{className:"space-y-1","data-testid":"skill-operation-error-blockers",children:a.blockers.map(a=>(0,d.jsxs)("li",{className:"text-xs text-danger-foreground",children:[a.path&&(0,d.jsx)("span",{className:"mr-1 break-all font-mono",children:a.path}),b((0,p.e5)(a.messageKey))]},`${a.code}:${a.path??""}`))})]})}function A({agents:a,skillId:b,version:c}){let e=(0,f.c)("skills");return 0===a.length?null:(0,d.jsxs)("div",{className:"space-y-1","data-testid":"skill-operation-reload",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:e("operation.reloadHeading")}),(0,d.jsx)("ul",{className:"space-y-1",children:a.map(a=>(0,d.jsx)("li",{className:"text-xs text-muted-foreground",children:e((0,p.e5)(a.messageKey),{agent:(0,h.f_)(a.agent),skillId:b,version:c})},a.agent))})]})}function B({skillId:a,version:b,blockedReason:c,worktreeId:h,agents:l=[]}){let n=(0,f.c)("skills"),[o,q]=(0,e.useState)(()=>h?{...x,worktreeId:h}:x),r=(0,e.useCallback)(a=>{q(b=>b.worktreeId===a?b:y({...b,worktreeId:a,busy:null}))},[]),s=(0,e.useCallback)(async()=>{let c=o.worktreeId;if(!c)return;q(a=>({...y(a),busy:"install-plan"}));let d=await (0,w.Q6)(c,a,{version:b??void 0});q(a=>({...a,busy:null,installPlan:d.ok?d.data.plan:null,failure:d.ok?null:d.failure}))},[a,o.worktreeId,b]),u=(0,e.useCallback)(async()=>{var b;let c=o.worktreeId,d=o.installPlan;if(!c||!d||d.requiresRiskAcknowledgement&&!o.riskAcknowledged)return;q(a=>({...a,busy:"install-apply",failure:null}));let e=await (0,w.Xi)(c,a,{planToken:d.token,version:d.skill.version,acknowledgeRisk:!!d.requiresRiskAcknowledgement||void 0,idempotencyKey:(b=d.token,`skill-install-${b}`)});e.ok&&(0,i.k)(c),q(a=>({...a,busy:null,installPlan:e.ok?null:a.installPlan,installResult:e.ok?e.data:null,failure:e.ok?null:e.failure}))},[a,o.installPlan,o.riskAcknowledged,o.worktreeId]),B=(0,e.useCallback)(async()=>{let b=o.worktreeId;if(!b)return;q(a=>({...y(a),busy:"uninstall-plan"}));let c=await (0,w.hN)(b,a);q(a=>({...a,busy:null,uninstallPlan:c.ok?c.data.plan:null,failure:c.ok?null:c.failure}))},[a,o.worktreeId]),C=(0,e.useCallback)(async()=>{var b;let c=o.worktreeId,d=o.uninstallPlan;if(!c||!d)return;q(a=>({...a,busy:"uninstall-apply",failure:null}));let e=await (0,w.E)(c,a,{planToken:d.token,idempotencyKey:(b=d.token,`skill-uninstall-${b}`)});q(a=>({...a,busy:null,uninstallPlan:e.ok?null:a.uninstallPlan,uninstallResult:e.ok?e.data:null,failure:e.ok?null:e.failure}))},[a,o.uninstallPlan,o.worktreeId]),D=(0,e.useCallback)(()=>{q(a=>y(a))},[]),E=null!==o.busy,F=o.installPlan,G=o.uninstallPlan,H=c??n(o.worktreeId?"plan.ready":"plan.chooseTarget"),I=null!==F&&F.requiresRiskAcknowledgement&&!o.riskAcknowledged;return(0,d.jsxs)("div",{className:"space-y-3","data-testid":"skill-install-panel",children:[!h&&(0,d.jsx)(m,{selectedWorktreeId:o.worktreeId,onSelect:r,disabled:E}),(0,d.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,d.jsx)(g.$n,{variant:"primary",disabled:E||null!==c||!o.worktreeId,onClick:s,"data-testid":"skill-install-action","aria-describedby":"skill-install-reason",children:n("install-plan"===o.busy?"plan.building":"plan.build")}),(0,d.jsx)(g.$n,{variant:"secondary",disabled:E||!o.worktreeId,onClick:B,"data-testid":"skill-uninstall-action",children:n("uninstall-plan"===o.busy?"uninstall.building":"uninstall.build")})]}),(0,d.jsx)("p",{id:"skill-install-reason",className:"text-sm text-muted-foreground","data-testid":"skill-install-reason",children:H}),l.length>0&&(0,d.jsxs)("div",{className:"space-y-1","data-testid":"skill-install-reload-preview",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:n("operation.reloadHeading")}),(0,d.jsx)("ul",{className:"space-y-1",children:l.map(a=>(0,d.jsx)(j.m,{agent:a,variant:"reload"},a.agent))})]}),o.failure&&(0,d.jsx)(z,{failure:o.failure}),F&&(0,d.jsxs)("div",{className:"space-y-3",children:[(0,d.jsx)(t,{plan:F}),F.requiresRiskAcknowledgement&&(0,d.jsxs)(g.Zp,{className:"space-y-3","data-testid":"skill-install-risk-acknowledgement",children:[(0,d.jsx)(k.u,{tone:"danger",children:n((0,p.e5)(F.riskAcknowledgementMessageKey??"skills.plan.highRiskAcknowledgement"))}),(0,d.jsxs)("label",{className:"flex items-start gap-2 text-sm text-foreground",children:[(0,d.jsx)(g.Sc,{checked:o.riskAcknowledged,onCheckedChange:a=>q(b=>({...b,riskAcknowledged:!0===a})),disabled:E,"data-testid":"skill-install-risk-checkbox",className:"mt-0.5"}),(0,d.jsx)("span",{children:n("plan.acknowledgeLabel")})]})]}),(0,d.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,d.jsx)(g.$n,{variant:F.requiresRiskAcknowledgement?"danger":"primary",disabled:E||!F.installable||I,onClick:u,"data-testid":"skill-install-confirm",children:n("install-apply"===o.busy?"plan.confirming":"plan.confirm")}),(0,d.jsx)(g.$n,{variant:"ghost",disabled:E,onClick:D,"data-testid":"skill-install-discard",children:n("plan.discard")})]})]}),G&&(0,d.jsxs)("div",{className:"space-y-3",children:[(0,d.jsx)(v,{plan:G}),(0,d.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,d.jsx)(g.$n,{variant:"danger",disabled:E||!G.removable,onClick:C,"data-testid":"skill-uninstall-confirm",children:n("uninstall-apply"===o.busy?"uninstall.confirming":"uninstall.confirm")}),(0,d.jsx)(g.$n,{variant:"ghost",disabled:E,onClick:D,"data-testid":"skill-uninstall-discard",children:n("plan.discard")})]})]}),o.installResult&&(0,d.jsxs)(g.Zp,{className:"space-y-3","data-testid":"skill-install-result",children:[(0,d.jsx)("h3",{className:"text-sm font-semibold text-foreground",children:n("operation.installedHeading")}),(0,d.jsx)(k.u,{tone:"info",children:n((0,p.e5)(o.installResult.operation.nextActionKey))}),o.installResult.operation.replayed&&(0,d.jsx)(k.u,{tone:"neutral","data-testid":"skill-operation-replayed",children:n("operation.replayNotice")}),o.installResult.install&&"files"in o.installResult.install&&(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:n("operation.filesWritten",{count:o.installResult.install.files.length})}),"reload"in o.installResult&&(0,d.jsx)(A,{agents:o.installResult.reload.agents,skillId:o.installResult.reload.skillId,version:o.installResult.reload.version}),(0,d.jsx)(g.$n,{variant:"secondary",size:"sm",onClick:D,"data-testid":"skill-operation-reset",children:n("operation.startOver")})]}),o.uninstallResult&&(0,d.jsxs)(g.Zp,{className:"space-y-3","data-testid":"skill-uninstall-result",children:[(0,d.jsx)("h3",{className:"text-sm font-semibold text-foreground",children:n("operation.uninstalledHeading")}),(0,d.jsx)(k.u,{tone:"info",children:n((0,p.e5)(o.uninstallResult.operation.nextActionKey))}),o.uninstallResult.operation.replayed&&(0,d.jsx)(k.u,{tone:"neutral","data-testid":"skill-operation-replayed",children:n("operation.replayNotice")}),o.uninstallResult.uninstall&&"removedFiles"in o.uninstallResult.uninstall&&(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:n("operation.filesRemoved",{count:o.uninstallResult.uninstall.removedFiles.length})}),"reload"in o.uninstallResult&&(0,d.jsx)(A,{agents:o.uninstallResult.reload.agents,skillId:o.uninstallResult.reload.skillId,version:o.uninstallResult.reload.version}),(0,d.jsx)(g.$n,{variant:"secondary",size:"sm",onClick:D,"data-testid":"skill-operation-reset",children:n("operation.startOver")})]})]})}},28593:(a,b,c)=>{c.d(b,{Xz:()=>j,qW:()=>k,uE:()=>l});var d=c(21124);c(38301);var e=c(20481),f=c(93983),g=c(85866),h=c(17252),i=c(27884);function j({status:a,className:b}){let c=(0,e.c)("skills");return(0,d.jsx)(g.Ex,{variant:i.H$[a],className:b,"data-testid":`skill-compatibility-${a}`,children:c(i.OV[a])})}function k({risk:a,className:b}){let c=(0,e.c)("skills");return(0,d.jsxs)(g.Ex,{variant:i.eK[a],className:b,"data-testid":`skill-declared-risk-${a}`,children:["high"===a&&(0,d.jsx)(f.A,{size:12,"aria-hidden":"true",className:"mr-1 shrink-0"}),c("risk.declaredLabel",{level:c(i.pP[a])})]})}function l({agent:a}){let b=(0,e.c)("skills");return(0,d.jsxs)(g.Ex,{variant:i.Et[a.support],"data-testid":`skill-agent-${a.agent}-${a.support}`,children:[(0,h.f_)(a.agent),": ",b((0,i.e5)(a.labelKey))]})}},60741:(a,b,c)=>{c.d(b,{G8:()=>v});var d=c(21124),e=c(38301),f=c.n(e),g=c(79206),h=c(26295),i=c(29701),j=c(28752),k=c(37950);c(31230);var l=c(13973),m=c(20481),n=c(17793);let o=(0,l.default)(async()=>{},{loadableGenerated:{modules:["components/worktree/MermaidCodeBlock.tsx -> ./MermaidDiagram"]},ssr:!1,loading:function(){let a=(0,m.c)("worktree");return(0,d.jsxs)("div",{className:"mermaid-loading flex items-center gap-2 text-muted-foreground p-4",children:[(0,d.jsx)(n.y,{size:"sm"}),(0,d.jsx)("span",{children:a("mermaid.loading")})]})}});function p({className:a,children:b}){if(a&&a.split(" ").includes("language-mermaid")){let a=null==b?"":"string"==typeof b?b:Array.isArray(b)?b.map(a=>"string"==typeof a?a:"").join(""):String(b);return(0,d.jsx)(o,{code:a})}return(0,d.jsx)("code",{className:a,children:b})}var q=c(9758),r=c(30917),s=c(82620),t=c(12894),u=c(88033);let v=(0,e.memo)(function({content:a,onOpenFile:b,currentFilePath:c,worktreeId:l}){let m=(0,e.useRef)(b);m.current=b;let n=(0,e.useRef)(c);n.current=c;let o=(0,e.useRef)(l);o.current=l;let v=(0,e.useCallback)((a,b)=>{let c=(0,s.d3)(b);if(c)switch((0,s.dj)(c)){case"anchor":break;case"external":a.preventDefault(),window.open(c,"_blank","noopener,noreferrer");break;case"relative":{a.preventDefault();let b=n.current,d=m.current;if(b&&d){let a=(0,s.WU)(b,c);a&&d(a)}}}},[]),w=(0,e.useMemo)(()=>({code:p,pre:({children:a})=>!function(a){let b=f().Children.toArray(a)[0];if(!f().isValidElement(b))return!1;let c=b.props.className;return"string"==typeof c&&c.split(" ").includes("language-mermaid")}(a)?(0,d.jsx)(q.Ck,{children:(0,d.jsx)("pre",{className:"overflow-x-auto",children:a})}):(0,d.jsx)("pre",{children:a}),img:({src:a,alt:b,width:c,height:e,...f})=>{let g=c??f.node?.properties?.width,h=e??f.node?.properties?.height;if("string"==typeof a&&!a.startsWith("http://")&&!a.startsWith("https://")&&!a.startsWith("data:")){let c=n.current,e=o.current;if(c&&e){let f=(0,s.WU)(c,a);if(f){let a=`/api/worktrees/${e}/files/${(0,t.o)(f)}`;return(0,d.jsx)(r.n,{apiUrl:a,alt:b??"",width:g,height:h})}}}return(0,d.jsx)("img",{src:a,alt:b??"",width:g,height:h,style:{maxWidth:g||"100%"}})},a:({href:a,children:b,...c})=>a?(0,d.jsx)("a",{...c,href:a,onClick:b=>v(b,a),children:b}):(0,d.jsx)("a",{...c,children:b})}),[v]),x=(0,e.useMemo)(()=>[h.A,[i.A,s.uO],j.A,k.A],[]);return(0,d.jsx)(g.oz,{remarkPlugins:u.eT,rehypePlugins:x,components:w,children:a})})},62484:(a,b,c)=>{c.d(b,{i:()=>j});var d=c(21124),e=c(38301),f=c(63156),g=c(58970);function h(){return(0,d.jsx)("svg",{className:"h-3.5 w-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,d.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M8 16H6a2 2 0 01-2-2V6a2 2 0 012-2h8a2 2 0 012 2v2m-6 12h8a2 2 0 002-2v-8a2 2 0 00-2-2h-8a2 2 0 00-2 2v8a2 2 0 002 2z"})})}function i(){return(0,d.jsx)("svg",{className:"h-3.5 w-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,d.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M5 13l4 4L19 7"})})}function j({text:a,className:b="",label:c="Copy"}){let[j,k]=(0,e.useState)(!1),l=(0,e.useRef)(null),m=(0,e.useCallback)(async()=>{try{await (0,f.l)(a),k(!0),l.current&&clearTimeout(l.current),l.current=setTimeout(()=>k(!1),g.s7)}catch{}},[a]);return(0,d.jsxs)("button",{type:"button",onClick:m,className:`inline-flex items-center gap-1 rounded border border-border bg-surface px-2 py-0.5 text-[11px] font-medium text-foreground transition-colors hover:bg-muted ${b}`,"aria-label":j?"Copied":c,title:j?"Copied!":c,children:[j?(0,d.jsx)(i,{}):(0,d.jsx)(h,{}),(0,d.jsx)("span",{children:j?"Copied":c})]})}},81136:(a,b,c)=>{c.d(b,{Co:()=>d,Ms:()=>f,td:()=>e});let d=".agents/skills",e=".claude/skills",f="skills.permissions.declarationOnlyNotice"},85389:(a,b,c)=>{c.d(b,{m:()=>j});var d=c(21124);c(38301);var e=c(20481),f=c(17252),g=c(3805),h=c(27884);function i({axis:a,agentName:b}){let c=(0,e.c)("skills");return(0,d.jsxs)("li",{className:"text-xs text-muted-foreground","data-testid":`skill-agent-axis-${a.axis}`,children:[(0,d.jsx)("span",{className:"font-medium text-foreground",children:c((0,h.e5)(a.axisKey))}),": ",(0,d.jsx)("span",{"data-testid":`skill-agent-axis-${a.axis}-${a.outcome}`,children:c((0,h.e5)(a.outcomeKey))})," — ",c((0,h.e5)(a.evidenceKindKey)),a.limitationKey&&(0,d.jsx)("span",{className:"mt-0.5 block","data-testid":`skill-agent-axis-${a.axis}-limitation`,children:c((0,h.e5)(a.limitationKey),{agent:b})})]})}function j({agent:a,variant:b="full"}){let c=(0,e.c)("skills"),j=(0,f.f_)(a.agent),k=a.measured;return"reload"===b?(0,d.jsx)("li",{className:"text-xs text-muted-foreground","data-testid":`skill-agent-reload-${a.agent}`,children:c((0,h.e5)(a.reloadKey),{agent:j})}):(0,d.jsxs)("div",{className:"space-y-1","data-testid":`skill-agent-evidence-${a.agent}`,children:[(0,d.jsx)("p",{className:"text-xs font-medium text-foreground",children:j}),(0,d.jsx)("p",{className:"text-xs text-muted-foreground break-words",children:c("compatibility.declaredLabel",{support:c((0,h.e5)(a.declaredLabelKey))})}),(0,d.jsxs)("p",{className:"text-xs text-muted-foreground break-words",children:[c("compatibility.evidence"),": ",a.evidence]}),(0,d.jsx)("p",{className:"text-xs text-muted-foreground break-words","data-testid":`skill-agent-verification-${a.agent}`,children:c((0,h.e5)(a.verificationKey))}),k?(0,d.jsxs)("div",{className:"space-y-0.5 border-l-2 border-border pl-2",children:[(0,d.jsx)("p",{className:"text-xs font-medium text-foreground",children:c("compatibility.measuredHeading")}),(0,d.jsxs)("ul",{className:"space-y-0.5",children:[(0,d.jsx)(i,{axis:k.discovery,agentName:j}),(0,d.jsx)(i,{axis:k.invocation,agentName:j})]}),k.testedVersion&&(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:c("compatibility.testedVersion",{agent:j,version:k.testedVersion})}),k.testedDate&&(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:c("compatibility.testedDate",{date:k.testedDate})}),k.discoveryRoots.length>0&&(0,d.jsx)("p",{className:"text-xs text-muted-foreground break-all",children:c("compatibility.discoveryRoots",{roots:k.discoveryRoots.join(", ")})}),k.evidenceSource&&(0,d.jsxs)("p",{className:"text-xs text-muted-foreground break-all",children:[c("compatibility.evidenceSource"),": ",k.evidenceSource]}),k.stale&&(0,d.jsx)(g.u,{tone:"warning","data-testid":`skill-agent-evidence-stale-${a.agent}`,children:c("compatibility.evidenceStale",{days:k.ageDays??0})})]}):a.skipReasonKey&&(0,d.jsx)("p",{className:"text-xs text-muted-foreground break-words","data-testid":`skill-agent-skip-reason-${a.agent}`,children:c((0,h.e5)(a.skipReasonKey))}),(0,d.jsxs)("p",{className:"text-xs text-muted-foreground break-words",children:[(0,d.jsx)("span",{className:"font-medium text-foreground",children:c("compatibility.reloadHeading",{agent:j})}),": ",c((0,h.e5)(a.reloadKey),{agent:j})]})]})}}};
1
+ "use strict";exports.id=4243,exports.ids=[4243],exports.modules={9758:(a,b,c)=>{c.d(b,{Ck:()=>h});var d=c(21124),e=c(38301),f=c.n(e),g=c(62484);function h({children:a,as:b="div",className:c=""}){let e=function a(b){return null==b||"boolean"==typeof b?"":"string"==typeof b?b:"number"==typeof b?String(b):Array.isArray(b)?b.map(a).join(""):f().isValidElement(b)?a(b.props.children):""}(a);if(!e||0===e.trim().length)return(0,d.jsx)(b,{className:c||void 0,children:a});let h=`relative group ${"span"===b?"block ":""}${c}`.trim();return(0,d.jsxs)(b,{className:h,"data-testid":"code-block-with-copy",children:[a,(0,d.jsx)(g.i,{text:e,className:"absolute right-2 top-2 z-10 opacity-100 md:opacity-0 md:group-hover:opacity-100 md:group-focus-within:opacity-100 focus:opacity-100"})]})}},9815:(a,b,c)=>{c.d(b,{B:()=>B});var d=c(21124),e=c(38301),f=c(20481),g=c(85866),h=c(17252),i=c(90349),j=c(85389),k=c(3805);let l={status:"loading",options:[]};function m({selectedWorktreeId:a,onSelect:b,disabled:c=!1}){let h=(0,f.c)("skills"),[i,j]=(0,e.useState)(l),[m,o]=(0,e.useState)(0),p=(0,e.useCallback)(()=>o(a=>a+1),[]);return"loading"===i.status?(0,d.jsxs)("div",{className:"space-y-2","data-testid":"skill-target-loading",children:[(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:h("target.loading")}),(0,d.jsx)(g.EA,{className:"h-24 w-full rounded-lg"})]}):"error"===i.status?(0,d.jsxs)(g.Zp,{className:"space-y-3","data-testid":"skill-target-error",children:[(0,d.jsx)(k.u,{tone:"danger",children:h("target.errorNotice")}),(0,d.jsx)(g.$n,{variant:"secondary",size:"sm",onClick:p,"data-testid":"skill-target-retry",children:h("target.retry")})]}):0===i.options.length?(0,d.jsx)(g.Zp,{"data-testid":"skill-target-empty",children:(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:h("target.empty")})}):(0,d.jsxs)("div",{className:"space-y-3","data-testid":"skill-target-selector",children:[(0,d.jsx)("div",{role:"radiogroup","aria-label":h("target.heading"),className:"space-y-2",children:i.options.map(e=>(0,d.jsx)(n,{option:e,selected:e.id===a,disabled:c,onSelect:b},e.id))}),(0,d.jsx)(k.u,{tone:"neutral","data-testid":"skill-target-branch-notice",children:h("target.branchFreshnessNotice")})]})}function n({option:a,selected:b,disabled:c,onSelect:e}){let h=(0,f.c)("skills"),i=a.liveBranch??a.syncedBranch;return(0,d.jsxs)("button",{type:"button",role:"radio","aria-checked":b,disabled:c,onClick:()=>e(a.id),"data-testid":`skill-target-option-${a.id}`,className:`w-full rounded-lg border px-3 py-2.5 text-left transition-colors disabled:cursor-not-allowed disabled:opacity-60 ${b?"border-accent-500 bg-accent-50 dark:bg-accent-950/40":"border-border bg-card hover:bg-muted"}`,children:[(0,d.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,d.jsx)("span",{className:"text-sm font-semibold text-foreground break-all",children:a.name}),b&&(0,d.jsx)(g.Ex,{variant:"info",children:h("target.selected")})]}),(0,d.jsxs)("dl",{className:"mt-1.5 grid grid-cols-1 gap-x-4 gap-y-1 sm:grid-cols-2",children:[(0,d.jsx)(o,{label:h("target.repository"),children:a.repositoryName}),(0,d.jsx)(o,{label:h("target.branch"),children:i??h("target.branchUnknown")}),(0,d.jsx)(o,{label:h("target.agents"),children:a.agents.length>0?a.agents.join(", "):h("target.agentsNone")}),(0,d.jsx)(o,{label:h("target.workingTree"),children:h(null===a.dirty?"target.workingTreeUnknown":a.dirty?"target.workingTreeDirty":"target.workingTreeClean")})]}),a.sessionRunning&&(0,d.jsx)("p",{className:"mt-1.5 text-xs text-muted-foreground","data-testid":`skill-target-session-${a.id}`,children:h("target.sessionRunning")})]})}function o({label:a,children:b}){return(0,d.jsxs)("div",{className:"min-w-0",children:[(0,d.jsx)("dt",{className:"text-xs font-medium text-muted-foreground",children:a}),(0,d.jsx)("dd",{className:"text-xs text-foreground break-words",children:b})]})}var p=c(27884);function q({label:a,children:b}){return(0,d.jsxs)("div",{className:"min-w-0",children:[(0,d.jsx)("dt",{className:"text-xs font-medium text-muted-foreground",children:a}),(0,d.jsx)("dd",{className:"mt-0.5 break-words text-sm text-foreground",children:b})]})}function r({level:a,kind:b,label:c}){let e=(0,f.c)("skills");return(0,d.jsxs)(g.Ex,{variant:p.eK[a],"data-testid":`skill-plan-risk-${b}-${a}`,children:[c,": ",e(p.pP[a])]})}function s({entry:a}){let b=(0,f.c)("skills"),c=p.KL[a.reason];return(0,d.jsxs)("li",{className:"space-y-1.5 rounded-md border border-border px-3 py-2","data-testid":`skill-plan-file-${a.path}`,children:[(0,d.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,d.jsx)(g.Ex,{variant:p.tC[a.change],children:b(p.AS[a.change])}),(0,d.jsx)("span",{className:"break-all font-mono text-xs text-foreground",children:a.path}),a.generated&&(0,d.jsx)(g.Ex,{variant:"gray",children:b("plan.fileGenerated")})]}),c&&(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:b(c)}),a.gitIgnored&&(0,d.jsx)("p",{className:"text-xs text-warning-foreground",children:b("plan.gitIgnored")}),a.binary?(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:b("plan.diffBinary")}):a.diff?(0,d.jsxs)("details",{children:[(0,d.jsx)("summary",{className:"cursor-pointer text-xs text-accent-600 dark:text-accent-400",children:b("plan.diffToggle",{additions:a.additions,deletions:a.deletions})}),(0,d.jsx)("pre",{className:"mt-1 overflow-x-auto rounded bg-muted p-2 font-mono text-[11px] leading-snug text-foreground",children:a.diff}),a.diffTruncated&&(0,d.jsx)("p",{className:"mt-1 text-xs text-muted-foreground",children:b("plan.diffTruncated")})]}):null]})}function t({plan:a}){let b=(0,f.c)("skills"),{target:c,skill:e}=a,h=e.compatibility.commandmate;return(0,d.jsxs)(g.Zp,{className:"space-y-4","data-testid":"skill-install-plan",children:[(0,d.jsxs)("div",{className:"space-y-1",children:[(0,d.jsx)("h3",{className:"text-sm font-semibold text-foreground",children:b("plan.heading")}),(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:b("plan.expiresAt",{timestamp:a.expiresAt})})]}),(0,d.jsxs)("section",{className:"space-y-2",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("plan.targetHeading")}),(0,d.jsxs)("dl",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[(0,d.jsx)(q,{label:b("target.repository"),children:c.repositoryName}),(0,d.jsx)(q,{label:b("target.heading"),children:c.worktreeName}),(0,d.jsx)(q,{label:b("target.branch"),children:c.branch??b("target.branchUnknown")}),(0,d.jsx)(q,{label:b("plan.headStateLabel"),children:b(p.kF[c.headState]??"plan.headState.unknown")}),(0,d.jsx)(q,{label:b("target.workingTree"),children:c.workingTreeUnknown?b("target.workingTreeStatusUnknown"):c.workingTreeDirty?b("target.workingTreeDirty"):b("target.workingTreeClean")}),(0,d.jsx)(q,{label:b("plan.installRoot"),children:(0,d.jsx)("span",{className:"break-all font-mono text-xs",children:(c.installRoots&&c.installRoots.length>0?c.installRoots:[c.installRoot]).map(a=>(0,d.jsx)("span",{className:"block",children:a},a))})}),(0,d.jsx)(q,{label:b("plan.existingInstall"),children:c.existingInstall?b("plan.existingInstallVersion",{version:c.existingInstall.version}):b("plan.existingInstallNone")}),(0,d.jsx)(q,{label:b("detail.recommendedVersion"),children:(0,d.jsx)("span",{className:"font-mono text-xs",children:e.version})})]})]}),(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-plan-risk-section",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("plan.riskHeading")}),(0,d.jsxs)("div",{className:"flex flex-wrap gap-1.5",children:[(0,d.jsx)(r,{level:e.declaredRisk,kind:"declared",label:b("plan.riskDeclared")}),(0,d.jsx)(r,{level:e.computedRisk,kind:"computed",label:b("plan.riskComputed")}),(0,d.jsx)(r,{level:e.effectiveRisk,kind:"effective",label:b("plan.riskEffective")})]}),(0,d.jsx)("p",{className:"break-words text-sm text-foreground",children:e.riskRationale}),(0,d.jsx)(k.u,{tone:"neutral",children:b("plan.riskNotice")})]}),(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-plan-permissions",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("permissions.heading")}),e.declaredPermissions.length>0?(0,d.jsx)("div",{className:"flex flex-wrap gap-1.5",children:e.declaredPermissions.map(a=>(0,d.jsx)(g.Ex,{variant:"warning",children:p.z2[a]?b(p.z2[a]):a},a))}):(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:b("plan.permissionsNone")}),(0,d.jsx)(k.u,{tone:"warning",children:b("permissions.declarationOnlyNotice")})]}),(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-plan-requirements",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("requirements.heading")}),0===e.requirements.commands.length&&0===e.requirements.networkHosts.length?(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:b("plan.requirementsNone")}):(0,d.jsxs)("dl",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[e.requirements.commands.length>0&&(0,d.jsx)(q,{label:b("plan.requirementsCommands"),children:e.requirements.commands.map(a=>`${a.name} ${a.versionRange??b("plan.commandAnyVersion")}`).join(", ")}),e.requirements.networkHosts.length>0&&(0,d.jsx)(q,{label:b("plan.requirementsHosts"),children:e.requirements.networkHosts.join(", ")})]})]}),(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-plan-scripts",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("plan.scriptsHeading")}),0===e.executablePaths.length&&0===e.scriptPaths.length?(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:b("plan.scriptsNone")}):(0,d.jsx)("ul",{className:"space-y-1",children:[...new Set([...e.scriptPaths,...e.executablePaths])].map(a=>(0,d.jsx)("li",{className:"break-all font-mono text-xs text-foreground",children:a},a))})]}),"compatible"!==h.status&&(0,d.jsx)(k.u,{tone:"warning","data-testid":"skill-plan-compatibility-notice",children:b((0,p.e5)(h.messageKey),{range:h.requiredRange,currentVersion:h.currentVersion??""})}),a.warnings.length>0&&(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-plan-warnings",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("plan.warningsHeading")}),(0,d.jsx)("ul",{className:"space-y-1",children:a.warnings.map(a=>(0,d.jsx)("li",{className:"text-xs text-warning-foreground",children:p.RO[a]?b(p.RO[a]):a},a))})]}),(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-plan-files",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("plan.filesHeading")}),(0,d.jsx)("p",{className:"text-xs text-muted-foreground","data-testid":"skill-plan-stats",children:b("plan.stats",{added:a.stats.added,modified:a.stats.modified,unchanged:a.stats.unchanged,conflicted:a.stats.conflicted,unmanaged:a.stats.unmanaged})}),0===a.files.length?(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:b("plan.filesEmpty")}):(0,d.jsx)("ul",{className:"space-y-2",children:a.files.map(a=>(0,d.jsx)(s,{entry:a},a.path))})]}),a.blockers.length>0&&(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-install-blockers",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-danger-foreground",children:b("plan.blockersHeading")}),(0,d.jsx)("ul",{className:"space-y-1",children:a.blockers.map(a=>(0,d.jsxs)("li",{className:"text-xs text-danger-foreground",children:[a.path&&(0,d.jsx)("span",{className:"mr-1 break-all font-mono",children:a.path}),a.code.startsWith("skills.")?b((0,p.e5)(a.code),{range:h.requiredRange,currentVersion:h.currentVersion??""}):p.KL[a.code]?b(p.KL[a.code]):a.code]},`${a.code}:${a.path??""}`))}),(0,d.jsx)(k.u,{tone:"danger",children:b("plan.blockedNotice")})]})]})}function u({entry:a}){let b=(0,f.c)("skills"),c=p.Mj[a.disposition],e=p.hJ[a.reason];return(0,d.jsxs)("li",{className:"flex flex-wrap items-center gap-2","data-testid":`skill-uninstall-file-${a.path}`,children:[(0,d.jsx)(g.Ex,{variant:"remove"===a.disposition?"info":"warning",children:c?b(c):a.disposition}),(0,d.jsx)("span",{className:"break-all font-mono text-xs text-foreground",children:a.path}),e&&(0,d.jsx)("span",{className:"text-xs text-muted-foreground",children:b(e)})]})}function v({plan:a}){let b=(0,f.c)("skills"),{target:c,skill:e}=a;return(0,d.jsxs)(g.Zp,{className:"space-y-4","data-testid":"skill-uninstall-plan",children:[(0,d.jsxs)("div",{className:"space-y-1",children:[(0,d.jsx)("h3",{className:"text-sm font-semibold text-foreground",children:b("uninstall.heading")}),(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:b("uninstall.expiresAt",{timestamp:a.expiresAt})})]}),(0,d.jsxs)("dl",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[(0,d.jsx)(q,{label:b("target.repository"),children:c.repositoryName}),(0,d.jsx)(q,{label:b("target.heading"),children:c.worktreeName}),(0,d.jsx)(q,{label:b("target.branch"),children:c.branch??b("target.branchUnknown")}),(0,d.jsx)(q,{label:b("uninstall.installedVersion"),children:(0,d.jsx)("span",{className:"font-mono text-xs",children:e.version||b("uninstall.versionUnknown")})}),(0,d.jsx)(q,{label:b("plan.installRoot"),children:(0,d.jsx)("span",{className:"break-all font-mono text-xs",children:c.installRoot})}),(0,d.jsx)(q,{label:b("target.workingTree"),children:c.workingTreeUnknown?b("target.workingTreeStatusUnknown"):c.workingTreeDirty?b("target.workingTreeDirty"):b("target.workingTreeClean")})]}),(0,d.jsx)("p",{className:"text-xs text-muted-foreground","data-testid":"skill-uninstall-stats",children:b("uninstall.stats",{removable:a.stats.removable,modified:a.stats.modified,missing:a.stats.missing,unknown:a.stats.unknown,irregular:a.stats.irregular})}),(0,d.jsxs)("section",{className:"space-y-2",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("uninstall.removalsHeading")}),0===a.removals.length?(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:b("uninstall.removalsEmpty")}):(0,d.jsx)("ul",{className:"space-y-1.5",children:a.removals.map(a=>(0,d.jsx)(u,{entry:a},a.path))})]}),(0,d.jsxs)("section",{className:"space-y-2",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:b("uninstall.retainedHeading")}),0===a.retained.length?(0,d.jsx)("p",{className:"text-sm text-muted-foreground",children:b("uninstall.retainedEmpty")}):(0,d.jsx)("ul",{className:"space-y-1.5",children:a.retained.map(a=>(0,d.jsx)(u,{entry:a},a.path))})]}),(0,d.jsxs)("div",{className:"space-y-2",children:[a.skill.agents.length>0&&(0,d.jsx)("div",{className:"flex flex-wrap gap-1.5","data-testid":"skill-uninstall-agents",children:a.skill.agents.map(a=>(0,d.jsx)(g.Ex,{variant:"gray",children:(0,h.f_)(a.agent)},a.agent))}),(0,d.jsx)(k.u,{tone:"neutral",children:b((0,p.e5)(a.nextActionKey))})]}),a.blockers.length>0&&(0,d.jsxs)("section",{className:"space-y-2","data-testid":"skill-uninstall-blockers",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-danger-foreground",children:b("uninstall.blockersHeading")}),(0,d.jsx)("ul",{className:"space-y-1",children:a.blockers.map(a=>(0,d.jsxs)("li",{className:"text-xs text-danger-foreground",children:[a.path&&(0,d.jsx)("span",{className:"mr-1 break-all font-mono",children:a.path}),b((0,p.e5)(a.messageKey))]},`${a.code}:${a.path??""}`))})]})]})}var w=c(30156);let x={worktreeId:null,busy:null,installPlan:null,uninstallPlan:null,installResult:null,uninstallResult:null,riskAcknowledged:!1,failure:null};function y(a){return{...a,installPlan:null,uninstallPlan:null,installResult:null,uninstallResult:null,riskAcknowledged:!1,failure:null}}function z({failure:a}){let b=(0,f.c)("skills");return(0,d.jsxs)("div",{className:"space-y-2","data-testid":"skill-operation-error",children:[(0,d.jsxs)(k.u,{tone:"danger",children:[(0,d.jsx)("p",{className:"font-medium",children:b("operation.errorHeading")}),(0,d.jsx)("p",{className:"mt-1",children:b((0,p.FW)(a.code))}),(0,d.jsx)("p",{className:"mt-1 break-words",children:b("state.errorCode",{code:a.code})})]}),a.nextActionKey&&(0,d.jsx)(k.u,{tone:"warning",children:b((0,p.e5)(a.nextActionKey))}),a.blockers&&a.blockers.length>0&&(0,d.jsx)("ul",{className:"space-y-1","data-testid":"skill-operation-error-blockers",children:a.blockers.map(a=>(0,d.jsxs)("li",{className:"text-xs text-danger-foreground",children:[a.path&&(0,d.jsx)("span",{className:"mr-1 break-all font-mono",children:a.path}),b((0,p.e5)(a.messageKey))]},`${a.code}:${a.path??""}`))})]})}function A({agents:a,skillId:b,version:c}){let e=(0,f.c)("skills");return 0===a.length?null:(0,d.jsxs)("div",{className:"space-y-1","data-testid":"skill-operation-reload",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:e("operation.reloadHeading")}),(0,d.jsx)("ul",{className:"space-y-1",children:a.map(a=>(0,d.jsx)("li",{className:"text-xs text-muted-foreground",children:e((0,p.e5)(a.messageKey),{agent:(0,h.f_)(a.agent),skillId:b,version:c})},a.agent))})]})}function B({skillId:a,version:b,blockedReason:c,worktreeId:h,agents:l=[]}){let n=(0,f.c)("skills"),[o,q]=(0,e.useState)(()=>h?{...x,worktreeId:h}:x),r=(0,e.useCallback)(a=>{q(b=>b.worktreeId===a?b:y({...b,worktreeId:a,busy:null}))},[]),s=(0,e.useCallback)(async()=>{let c=o.worktreeId;if(!c)return;q(a=>({...y(a),busy:"install-plan"}));let d=await (0,w.Q6)(c,a,{version:b??void 0});q(a=>({...a,busy:null,installPlan:d.ok?d.data.plan:null,failure:d.ok?null:d.failure}))},[a,o.worktreeId,b]),u=(0,e.useCallback)(async()=>{var b;let c=o.worktreeId,d=o.installPlan;if(!c||!d||d.requiresRiskAcknowledgement&&!o.riskAcknowledged)return;q(a=>({...a,busy:"install-apply",failure:null}));let e=await (0,w.Xi)(c,a,{planToken:d.token,version:d.skill.version,acknowledgeRisk:!!d.requiresRiskAcknowledgement||void 0,idempotencyKey:(b=d.token,`skill-install-${b}`)});e.ok&&(0,i.k)(c),q(a=>({...a,busy:null,installPlan:e.ok?null:a.installPlan,installResult:e.ok?e.data:null,failure:e.ok?null:e.failure}))},[a,o.installPlan,o.riskAcknowledged,o.worktreeId]),B=(0,e.useCallback)(async()=>{let b=o.worktreeId;if(!b)return;q(a=>({...y(a),busy:"uninstall-plan"}));let c=await (0,w.hN)(b,a);q(a=>({...a,busy:null,uninstallPlan:c.ok?c.data.plan:null,failure:c.ok?null:c.failure}))},[a,o.worktreeId]),C=(0,e.useCallback)(async()=>{var b;let c=o.worktreeId,d=o.uninstallPlan;if(!c||!d)return;q(a=>({...a,busy:"uninstall-apply",failure:null}));let e=await (0,w.E)(c,a,{planToken:d.token,idempotencyKey:(b=d.token,`skill-uninstall-${b}`)});q(a=>({...a,busy:null,uninstallPlan:e.ok?null:a.uninstallPlan,uninstallResult:e.ok?e.data:null,failure:e.ok?null:e.failure}))},[a,o.uninstallPlan,o.worktreeId]),D=(0,e.useCallback)(()=>{q(a=>y(a))},[]),E=null!==o.busy,F=o.installPlan,G=o.uninstallPlan,H=c??n(o.worktreeId?"plan.ready":"plan.chooseTarget"),I=null!==F&&F.requiresRiskAcknowledgement&&!o.riskAcknowledged;return(0,d.jsxs)("div",{className:"space-y-3","data-testid":"skill-install-panel",children:[!h&&(0,d.jsx)(m,{selectedWorktreeId:o.worktreeId,onSelect:r,disabled:E}),(0,d.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,d.jsx)(g.$n,{variant:"primary",disabled:E||null!==c||!o.worktreeId,onClick:s,"data-testid":"skill-install-action","aria-describedby":"skill-install-reason",children:n("install-plan"===o.busy?"plan.building":"plan.build")}),(0,d.jsx)(g.$n,{variant:"secondary",disabled:E||!o.worktreeId,onClick:B,"data-testid":"skill-uninstall-action",children:n("uninstall-plan"===o.busy?"uninstall.building":"uninstall.build")})]}),(0,d.jsx)("p",{id:"skill-install-reason",className:"text-sm text-muted-foreground","data-testid":"skill-install-reason",children:H}),l.length>0&&(0,d.jsxs)("div",{className:"space-y-1","data-testid":"skill-install-reload-preview",children:[(0,d.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:n("operation.reloadHeading")}),(0,d.jsx)("ul",{className:"space-y-1",children:l.map(a=>(0,d.jsx)(j.m,{agent:a,variant:"reload"},a.agent))})]}),o.failure&&(0,d.jsx)(z,{failure:o.failure}),F&&(0,d.jsxs)("div",{className:"space-y-3",children:[(0,d.jsx)(t,{plan:F}),F.requiresRiskAcknowledgement&&(0,d.jsxs)(g.Zp,{className:"space-y-3","data-testid":"skill-install-risk-acknowledgement",children:[(0,d.jsx)(k.u,{tone:"danger",children:n((0,p.e5)(F.riskAcknowledgementMessageKey??"skills.plan.highRiskAcknowledgement"))}),(0,d.jsxs)("label",{className:"flex items-start gap-2 text-sm text-foreground",children:[(0,d.jsx)(g.Sc,{checked:o.riskAcknowledged,onCheckedChange:a=>q(b=>({...b,riskAcknowledged:!0===a})),disabled:E,"data-testid":"skill-install-risk-checkbox",className:"mt-0.5"}),(0,d.jsx)("span",{children:n("plan.acknowledgeLabel")})]})]}),(0,d.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,d.jsx)(g.$n,{variant:F.requiresRiskAcknowledgement?"danger":"primary",disabled:E||!F.installable||I,onClick:u,"data-testid":"skill-install-confirm",children:n("install-apply"===o.busy?"plan.confirming":"plan.confirm")}),(0,d.jsx)(g.$n,{variant:"ghost",disabled:E,onClick:D,"data-testid":"skill-install-discard",children:n("plan.discard")})]})]}),G&&(0,d.jsxs)("div",{className:"space-y-3",children:[(0,d.jsx)(v,{plan:G}),(0,d.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,d.jsx)(g.$n,{variant:"danger",disabled:E||!G.removable,onClick:C,"data-testid":"skill-uninstall-confirm",children:n("uninstall-apply"===o.busy?"uninstall.confirming":"uninstall.confirm")}),(0,d.jsx)(g.$n,{variant:"ghost",disabled:E,onClick:D,"data-testid":"skill-uninstall-discard",children:n("plan.discard")})]})]}),o.installResult&&(0,d.jsxs)(g.Zp,{className:"space-y-3","data-testid":"skill-install-result",children:[(0,d.jsx)("h3",{className:"text-sm font-semibold text-foreground",children:n("operation.installedHeading")}),(0,d.jsx)(k.u,{tone:"info",children:n((0,p.e5)(o.installResult.operation.nextActionKey))}),o.installResult.operation.replayed&&(0,d.jsx)(k.u,{tone:"neutral","data-testid":"skill-operation-replayed",children:n("operation.replayNotice")}),o.installResult.install&&"files"in o.installResult.install&&(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:n("operation.filesWritten",{count:o.installResult.install.files.length})}),"reload"in o.installResult&&(0,d.jsx)(A,{agents:o.installResult.reload.agents,skillId:o.installResult.reload.skillId,version:o.installResult.reload.version}),(0,d.jsx)(g.$n,{variant:"secondary",size:"sm",onClick:D,"data-testid":"skill-operation-reset",children:n("operation.startOver")})]}),o.uninstallResult&&(0,d.jsxs)(g.Zp,{className:"space-y-3","data-testid":"skill-uninstall-result",children:[(0,d.jsx)("h3",{className:"text-sm font-semibold text-foreground",children:n("operation.uninstalledHeading")}),(0,d.jsx)(k.u,{tone:"info",children:n((0,p.e5)(o.uninstallResult.operation.nextActionKey))}),o.uninstallResult.operation.replayed&&(0,d.jsx)(k.u,{tone:"neutral","data-testid":"skill-operation-replayed",children:n("operation.replayNotice")}),o.uninstallResult.uninstall&&"removedFiles"in o.uninstallResult.uninstall&&(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:n("operation.filesRemoved",{count:o.uninstallResult.uninstall.removedFiles.length})}),"reload"in o.uninstallResult&&(0,d.jsx)(A,{agents:o.uninstallResult.reload.agents,skillId:o.uninstallResult.reload.skillId,version:o.uninstallResult.reload.version}),(0,d.jsx)(g.$n,{variant:"secondary",size:"sm",onClick:D,"data-testid":"skill-operation-reset",children:n("operation.startOver")})]})]})}},28593:(a,b,c)=>{c.d(b,{Xz:()=>j,qW:()=>k,uE:()=>l});var d=c(21124);c(38301);var e=c(20481),f=c(93983),g=c(85866),h=c(17252),i=c(27884);function j({status:a,className:b}){let c=(0,e.c)("skills");return(0,d.jsx)(g.Ex,{variant:i.H$[a],className:b,"data-testid":`skill-compatibility-${a}`,children:c(i.OV[a])})}function k({risk:a,className:b}){let c=(0,e.c)("skills");return(0,d.jsxs)(g.Ex,{variant:i.eK[a],className:b,"data-testid":`skill-declared-risk-${a}`,children:["high"===a&&(0,d.jsx)(f.A,{size:12,"aria-hidden":"true",className:"mr-1 shrink-0"}),c("risk.declaredLabel",{level:c(i.pP[a])})]})}function l({agent:a}){let b=(0,e.c)("skills");return(0,d.jsxs)(g.Ex,{variant:i.Et[a.support],"data-testid":`skill-agent-${a.agent}-${a.support}`,children:[(0,h.f_)(a.agent),": ",b((0,i.e5)(a.labelKey))]})}},34126:(a,b,c)=>{c.d(b,{G8:()=>r});var d=c(21124),e=c(38301),f=c(27867),g=c(26295),h=c(29701),i=c(28752),j=c(37950);c(31230);var k=c(56722),l=c(45538),m=c(9758),n=c(30917),o=c(82620),p=c(12894),q=c(88033);let r=(0,e.memo)(function({content:a,onOpenFile:b,currentFilePath:c,worktreeId:r}){let s=(0,e.useRef)(b);s.current=b;let t=(0,e.useRef)(c);t.current=c;let u=(0,e.useRef)(r);u.current=r;let v=(0,e.useCallback)((a,b)=>{let c=(0,o.d3)(b);if(c)switch((0,o.dj)(c)){case"anchor":break;case"external":a.preventDefault(),window.open(c,"_blank","noopener,noreferrer");break;case"relative":{a.preventDefault();let b=t.current,d=s.current;if(b&&d){let a=(0,o.WU)(b,c);a&&d(a)}}}},[]),w=(0,e.useMemo)(()=>({code:k.AY,pre:({children:a})=>(0,l.D)(a)?(0,d.jsx)(d.Fragment,{children:a}):(0,d.jsx)(m.Ck,{children:(0,d.jsx)("pre",{className:"overflow-x-auto",children:a})}),img:({src:a,alt:b,width:c,height:e,...f})=>{let g=c??f.node?.properties?.width,h=e??f.node?.properties?.height;if("string"==typeof a&&!a.startsWith("http://")&&!a.startsWith("https://")&&!a.startsWith("data:")){let c=t.current,e=u.current;if(c&&e){let f=(0,o.WU)(c,a);if(f){let a=`/api/worktrees/${e}/files/${(0,p.o)(f)}`;return(0,d.jsx)(n.n,{apiUrl:a,alt:b??"",width:g,height:h})}}}return(0,d.jsx)("img",{src:a,alt:b??"",width:g,height:h,style:{maxWidth:g||"100%"}})},a:({href:a,children:b,...c})=>a?(0,d.jsx)("a",{...c,href:a,onClick:b=>v(b,a),children:b}):(0,d.jsx)("a",{...c,children:b})}),[v]),x=(0,e.useMemo)(()=>[g.A,[h.A,o.uO],i.A,j.A],[]);return(0,d.jsx)(f.oz,{remarkPlugins:q.eT,rehypePlugins:x,components:w,children:a})})},62484:(a,b,c)=>{c.d(b,{i:()=>j});var d=c(21124),e=c(38301),f=c(63156),g=c(58970);function h(){return(0,d.jsx)("svg",{className:"h-3.5 w-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,d.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M8 16H6a2 2 0 01-2-2V6a2 2 0 012-2h8a2 2 0 012 2v2m-6 12h8a2 2 0 002-2v-8a2 2 0 00-2-2h-8a2 2 0 00-2 2v8a2 2 0 002 2z"})})}function i(){return(0,d.jsx)("svg",{className:"h-3.5 w-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,d.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M5 13l4 4L19 7"})})}function j({text:a,className:b="",label:c="Copy"}){let[j,k]=(0,e.useState)(!1),l=(0,e.useRef)(null),m=(0,e.useCallback)(async()=>{try{await (0,f.l)(a),k(!0),l.current&&clearTimeout(l.current),l.current=setTimeout(()=>k(!1),g.s7)}catch{}},[a]);return(0,d.jsxs)("button",{type:"button",onClick:m,className:`inline-flex items-center gap-1 rounded border border-border bg-surface px-2 py-0.5 text-[11px] font-medium text-foreground transition-colors hover:bg-muted ${b}`,"aria-label":j?"Copied":c,title:j?"Copied!":c,children:[j?(0,d.jsx)(i,{}):(0,d.jsx)(h,{}),(0,d.jsx)("span",{children:j?"Copied":c})]})}},81136:(a,b,c)=>{c.d(b,{Co:()=>d,Ms:()=>f,td:()=>e});let d=".agents/skills",e=".claude/skills",f="skills.permissions.declarationOnlyNotice"},85389:(a,b,c)=>{c.d(b,{m:()=>j});var d=c(21124);c(38301);var e=c(20481),f=c(17252),g=c(3805),h=c(27884);function i({axis:a,agentName:b}){let c=(0,e.c)("skills");return(0,d.jsxs)("li",{className:"text-xs text-muted-foreground","data-testid":`skill-agent-axis-${a.axis}`,children:[(0,d.jsx)("span",{className:"font-medium text-foreground",children:c((0,h.e5)(a.axisKey))}),": ",(0,d.jsx)("span",{"data-testid":`skill-agent-axis-${a.axis}-${a.outcome}`,children:c((0,h.e5)(a.outcomeKey))})," — ",c((0,h.e5)(a.evidenceKindKey)),a.limitationKey&&(0,d.jsx)("span",{className:"mt-0.5 block","data-testid":`skill-agent-axis-${a.axis}-limitation`,children:c((0,h.e5)(a.limitationKey),{agent:b})})]})}function j({agent:a,variant:b="full"}){let c=(0,e.c)("skills"),j=(0,f.f_)(a.agent),k=a.measured;return"reload"===b?(0,d.jsx)("li",{className:"text-xs text-muted-foreground","data-testid":`skill-agent-reload-${a.agent}`,children:c((0,h.e5)(a.reloadKey),{agent:j})}):(0,d.jsxs)("div",{className:"space-y-1","data-testid":`skill-agent-evidence-${a.agent}`,children:[(0,d.jsx)("p",{className:"text-xs font-medium text-foreground",children:j}),(0,d.jsx)("p",{className:"text-xs text-muted-foreground break-words",children:c("compatibility.declaredLabel",{support:c((0,h.e5)(a.declaredLabelKey))})}),(0,d.jsxs)("p",{className:"text-xs text-muted-foreground break-words",children:[c("compatibility.evidence"),": ",a.evidence]}),(0,d.jsx)("p",{className:"text-xs text-muted-foreground break-words","data-testid":`skill-agent-verification-${a.agent}`,children:c((0,h.e5)(a.verificationKey))}),k?(0,d.jsxs)("div",{className:"space-y-0.5 border-l-2 border-border pl-2",children:[(0,d.jsx)("p",{className:"text-xs font-medium text-foreground",children:c("compatibility.measuredHeading")}),(0,d.jsxs)("ul",{className:"space-y-0.5",children:[(0,d.jsx)(i,{axis:k.discovery,agentName:j}),(0,d.jsx)(i,{axis:k.invocation,agentName:j})]}),k.testedVersion&&(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:c("compatibility.testedVersion",{agent:j,version:k.testedVersion})}),k.testedDate&&(0,d.jsx)("p",{className:"text-xs text-muted-foreground",children:c("compatibility.testedDate",{date:k.testedDate})}),k.discoveryRoots.length>0&&(0,d.jsx)("p",{className:"text-xs text-muted-foreground break-all",children:c("compatibility.discoveryRoots",{roots:k.discoveryRoots.join(", ")})}),k.evidenceSource&&(0,d.jsxs)("p",{className:"text-xs text-muted-foreground break-all",children:[c("compatibility.evidenceSource"),": ",k.evidenceSource]}),k.stale&&(0,d.jsx)(g.u,{tone:"warning","data-testid":`skill-agent-evidence-stale-${a.agent}`,children:c("compatibility.evidenceStale",{days:k.ageDays??0})})]}):a.skipReasonKey&&(0,d.jsx)("p",{className:"text-xs text-muted-foreground break-words","data-testid":`skill-agent-skip-reason-${a.agent}`,children:c((0,h.e5)(a.skipReasonKey))}),(0,d.jsxs)("p",{className:"text-xs text-muted-foreground break-words",children:[(0,d.jsx)("span",{className:"font-medium text-foreground",children:c("compatibility.reloadHeading",{agent:j})}),": ",c((0,h.e5)(a.reloadKey),{agent:j})]})]})}}};
@@ -1,4 +1,5 @@
1
- "use strict";exports.id=4718,exports.ids=[4718],exports.modules={21586:(a,b,c)=>{c.d(b,{$h:()=>h,Cy:()=>s,DE:()=>t,F5:()=>k,IH:()=>f,JK:()=>d,Nb:()=>i,R7:()=>e,RP:()=>n,VU:()=>r,W9:()=>o,Xb:()=>m,bO:()=>q,bm:()=>j,iU:()=>p,qw:()=>l,t7:()=>g});let d=3e5,e=6e4,f=["claude","codex","copilot","antigravity","opencode"],g=1e3,h=5,i=100,j=1e3,k=3e3,l=15e3,m=15e3,n=6e3,o=3e3,p=800,q=500,r=20,s=1e4,t=15e3},40663:(a,b,c)=>{c.d(b,{GI:()=>M,qw:()=>N,xF:()=>J,Hw:()=>O,T5:()=>S,sZ:()=>L,XT:()=>K});var d=c(79646),e=c(29021),f=c(33873),g=c(72626),h=c(34207),i=c(21586);let j=i.RP,k=["user_data","commit_log","issue_context","verification_metrics"];function l(a){let b=a.replace(/[\x00-\x08\x0b\x0c\x0e-\x1f\x7f]/g,"");for(let a of k){let c=RegExp(`</?${a}>`,"gi");b=b.replace(c,a=>a.replace(/</g,"&lt;").replace(/>/g,"&gt;"))}return b.slice(0,h.uv)}function m(a){return null===a?"n/a":`${(100*a).toFixed(1)}%`}var n=c(20137),o=c(52660),p=c(4868),q=c(73753),r=c(14552),s=c(93636),t=c(10406),u=c(79051),v=c(28354);let w=(0,g.h)("github-api"),x=(0,v.promisify)(d.execFile);async function y(){try{return await x("gh",["--version"],{timeout:5e3}),!0}catch{return!1}}async function z(a,b,c){try{if(!await y())return w.debug("gh-cli-unavailable",{issueNumber:a}),null;let{stdout:d}=await x("gh",["issue","view",String(a),"--json","number,title,body,labels,state"],{cwd:b,timeout:i.Cy}),e=JSON.parse(d),f=e.labels.map(a=>"string"==typeof a?a:a.name),g=(e.body??"").slice(0,i.bO);return{repositoryName:c,number:e.number,title:e.title,labels:f,state:e.state,bodySummary:g}}catch(b){return w.debug("get-issue-info-failed",{issueNumber:a,repositoryName:c,error:String(b)}),null}}async function A(a,b){let c=(0,u.Pt)(b).slice(0,i.VU);if(0===c.length||0===a.length)return[];let d=[];for(let b of a)for(let a of c)d.push(z(a,b.path,b.name));let e=await Promise.allSettled(d),f=[];for(let a of e)"fulfilled"===a.status&&null!==a.value&&f.push(a.value);return f}var B=c(58400),C=c(70673),D=c(85322);let E=["directory","title","cwd","root","text","snapshot","output","input","metadata"];function F(a,b){let c=a[b];return"number"==typeof c&&Number.isFinite(c)?c:null}function G(a,b){let c=a[b];return"string"==typeof c&&""!==c?c:null}function H(a){return"object"!=typeof a||null===a||Array.isArray(a)?null:a}let I=(0,g.h)("daily-summary"),J=2*h.uv;function K(){let a=globalThis.__dailySummaryGenerating;return!!a?.active&&(!(Date.now()-a.startedAt>i.R7+1e4)||(I.warn("failsafe-reset",{startedAt:a.startedAt}),globalThis.__dailySummaryGenerating=void 0,!1))}function L(){return K()?globalThis.__dailySummaryGenerating??null:null}class M extends Error{constructor(){super("Summary generation is already in progress"),this.name="ConcurrentGenerationError"}}class N extends Error{constructor(){super("Summary generation timed out"),this.name="GenerationTimeoutError"}}class O extends Error{constructor(a){super(a),this.name="OutputValidationError"}}function P(a,b=0){return null===a?"-":b>0?a.toFixed(b):String(a)}async function Q(a,b){let c,e;try{c=await new Promise((c,e)=>{(0,d.execFile)("opencode",["export","--sanitize",a],{cwd:b,timeout:3e4,maxBuffer:4194304,encoding:"utf8"},(a,b)=>a?e(a):c(b))})}catch(b){return I.debug("opencode-export-failed",{sessionId:a,error:b instanceof Error?b.message:String(b)}),null}try{e=JSON.parse(c)}catch{return I.warn("opencode-export-unparsable",{sessionId:a,bytes:c.length}),null}let f=function(a){let b=[],c=new Set(E),d=(a,e)=>{if(Array.isArray(a))return void a.forEach((a,b)=>d(a,`${e}[${b}]`));if("object"==typeof a&&null!==a)for(let[f,g]of Object.entries(a)){let a=""===e?f:`${e}.${f}`;if(c.has(f)){if(null==g||""===g||"string"==typeof g&&g.startsWith("[redacted:")||function(a){if("object"!=typeof a||null===a||Array.isArray(a))return!1;let b=Object.keys(a);return 1===b.length&&"redacted"===b[0]}(g)||"number"==typeof g||"boolean"==typeof g)continue;b.push({path:a,kind:"string"==typeof g?"plaintext":"unredacted-object"});continue}d(g,a)}};return d(a,""),b}(e);return f.length>0?(I.warn("opencode-export-redaction-audit-failed",{sessionId:a,leaks:f.length,paths:f.slice(0,5).map(a=>a.path)}),null):function(a){let b=H(a);if(null===b)return null;let c=H(b.info);if(null===c)return null;let d=H(c.model),e=null===d?null:G(d,"providerID"),f=null===d?null:G(d,"id"),g=H(c.time),h=0,i=0,j=0,k=new Set;for(let a of Array.isArray(b.messages)?b.messages:[]){let b=H(a);if(null===b)continue;let c=H(b.info),d=null===c?null:G(c,"role");for(let a of("user"===d?h+=1:"assistant"===d&&(i+=1),Array.isArray(b.parts)?b.parts:[])){let b=H(a);if(null===b||"tool"!==G(b,"type"))continue;j+=1;let c=G(b,"tool");null!==c&&k.add(c)}}return{sessionId:G(c,"id"),agent:G(c,"agent"),model:null!==e&&null!==f?`${e}/${f}`:f,version:G(c,"version"),cost:F(c,"cost"),userMessages:h,assistantMessages:i,tools:[...k].sort(),toolCalls:j,createdAt:null===g?null:F(g,"created"),updatedAt:null===g?null:F(g,"updated")}}(e)}async function R(a,b){let c=(0,r.PY)(a,b).filter(a=>a.cliToolId===D.k),d=c.slice(0,20),e=c.length-d.length,f=[],g=Date.now()+9e4,h=0;for(let[a,c]of d.entries()){if(Date.now()>=g){h=d.length-a,I.warn("opencode-export-budget-exhausted",{date:b,abandoned:h});break}let e=await Q(c.sessionId);null!==e&&f.push({worktreeId:c.worktreeId,summary:e})}return{entries:f,skipped:e+h}}async function S(a,b){let{date:c,tool:d,model:g,userInstruction:k}=b;if(K())throw I.warn("concurrent-rejected",{date:c}),new M;globalThis.__dailySummaryGenerating={active:!0,startedAt:Date.now(),date:c,tool:d};try{I.info("generation-started",{date:c,tool:d});try{(0,s.Yc)(a)}catch(a){I.warn("cost-sample-failed",{error:a instanceof Error?a.message:String(a)})}let b=new Date(c+"T00:00:00"),v=new Date(c+"T23:59:59.999"),w=(0,o.getMessagesByDateRange)(a,{after:b,before:v});if(0===w.length)throw new O("No messages found for the specified date");let x=(0,q.vi)(a),y=new Map;for(let a of x)y.set(a.id,a.name);let z=(0,t.Yg)(a),D=z.filter(a=>!!a.enabled&&!!(0,e.existsSync)(a.path)&&!!(0,e.existsSync)((0,f.join)(a.path,".git")));D.length<z.length&&I.info("repositories-filtered",{total:z.length,valid:D.length,skipped:z.length-D.length});let E=b.toISOString(),F=v.toISOString(),G=await (0,C.wj)((0,u.z0)(D,E,F),i.qw,new Map),H=Array.from(G.values()).flatMap(({commits:a})=>a.map(a=>a.message)),K=await (0,C.wj)(A(D,H).catch(()=>[]),i.DE,[]),L=(0,B.hh)(a,{days:1,until:b.getTime()+B.ec}),M=function(a,b,c,d,e,f){let g=`You are a technical report generator. Summarize the following work logs into a concise daily report in Japanese Markdown format.
1
+ "use strict";exports.id=4718,exports.ids=[4718],exports.modules={18140:(a,b,c)=>{c.d(b,{$s:()=>m,Qq:()=>n,b6:()=>h,mV:()=>o});var d=c(79646),e=c(81776),f=c(73434);let g="opencode",h="opencode2",i=/^opencode v(\d+)\.(\d+)\.(\d+)((?:[-+][0-9A-Za-z.-]+)?)$/,j=/^v?(\d+)\.(\d+)\.(\d+)((?:[-+][0-9A-Za-z.-]+)?)$/,k=new Map;async function l(a,b){let c=[];for(let g of a)for(let a of(0,e.n$)(g,4)){if(c.some(b=>b.path===a))continue;let e=await function(a){let b=Date.now(),c=k.get(a);if(c&&c.expiresAt>b)return c.info;let e=new Promise(b=>{try{(0,d.execFile)(a,["--version"],{timeout:5e3,maxBuffer:65536,env:(0,f.hh)()},(a,c,d)=>{if(a)return void b(null);b(function(a){for(let b of a.split(/\r?\n/)){let a=b.trim();if(!a)continue;let c=i.exec(a)??j.exec(a);if(!c)continue;let d=Number(c[1]),e=`${c[1]}.${c[2]}.${c[3]}${c[4]??""}`;if(1===d)return{generation:"v1",version:e};if(d>=2)return{generation:"v2",version:e};break}return null}(`${c??""}
2
+ ${d??""}`))})}catch{b(null)}});return k.set(a,{expiresAt:b+3e4,info:e}),e}(a);if(c.push({path:a,info:e}),e?.generation===b)return{executable:{path:a,version:e.version,generation:b},probed:c}}return{executable:null,probed:c}}function m(){return l([g],"v1")}function n(){return l([h,g],"v2")}function o(a){if(a.executable)return null;let b=a.probed.find(a=>a.info?.generation==="v2");if(b?.info)return`\`opencode\` at ${b.path} is OpenCode V2 ${b.info.version}, not OpenCode 1.x (npm \`@opencode/cli\` registers both \`opencode\` and \`opencode2\`). Use the OpenCode V2 agent, or put an OpenCode 1.x \`opencode\` on PATH.`;let c=a.probed[0];return c?`\`opencode\` at ${c.path} did not report an OpenCode 1.x version (\`opencode --version\`).`:null}},21586:(a,b,c)=>{c.d(b,{$h:()=>h,Cy:()=>s,DE:()=>t,F5:()=>k,IH:()=>f,JK:()=>d,Nb:()=>i,R7:()=>e,RP:()=>n,VU:()=>r,W9:()=>o,Xb:()=>m,bO:()=>q,bm:()=>j,iU:()=>p,qw:()=>l,t7:()=>g});let d=3e5,e=6e4,f=["claude","codex","copilot","antigravity","opencode"],g=1e3,h=5,i=100,j=1e3,k=3e3,l=15e3,m=15e3,n=6e3,o=3e3,p=800,q=500,r=20,s=1e4,t=15e3},40663:(a,b,c)=>{c.d(b,{GI:()=>M,qw:()=>N,xF:()=>J,Hw:()=>O,T5:()=>S,sZ:()=>L,XT:()=>K});var d=c(79646),e=c(29021),f=c(33873),g=c(72626),h=c(34207),i=c(21586);let j=i.RP,k=["user_data","commit_log","issue_context","verification_metrics"];function l(a){let b=a.replace(/[\x00-\x08\x0b\x0c\x0e-\x1f\x7f]/g,"");for(let a of k){let c=RegExp(`</?${a}>`,"gi");b=b.replace(c,a=>a.replace(/</g,"&lt;").replace(/>/g,"&gt;"))}return b.slice(0,h.uv)}function m(a){return null===a?"n/a":`${(100*a).toFixed(1)}%`}var n=c(20137),o=c(52660),p=c(4868),q=c(73753),r=c(14552),s=c(93636),t=c(10406),u=c(79051),v=c(28354);let w=(0,g.h)("github-api"),x=(0,v.promisify)(d.execFile);async function y(){try{return await x("gh",["--version"],{timeout:5e3}),!0}catch{return!1}}async function z(a,b,c){try{if(!await y())return w.debug("gh-cli-unavailable",{issueNumber:a}),null;let{stdout:d}=await x("gh",["issue","view",String(a),"--json","number,title,body,labels,state"],{cwd:b,timeout:i.Cy}),e=JSON.parse(d),f=e.labels.map(a=>"string"==typeof a?a:a.name),g=(e.body??"").slice(0,i.bO);return{repositoryName:c,number:e.number,title:e.title,labels:f,state:e.state,bodySummary:g}}catch(b){return w.debug("get-issue-info-failed",{issueNumber:a,repositoryName:c,error:String(b)}),null}}async function A(a,b){let c=(0,u.Pt)(b).slice(0,i.VU);if(0===c.length||0===a.length)return[];let d=[];for(let b of a)for(let a of c)d.push(z(a,b.path,b.name));let e=await Promise.allSettled(d),f=[];for(let a of e)"fulfilled"===a.status&&null!==a.value&&f.push(a.value);return f}var B=c(58400),C=c(70673),D=c(85322);let E=["directory","title","cwd","root","text","snapshot","output","input","metadata"];function F(a,b){let c=a[b];return"number"==typeof c&&Number.isFinite(c)?c:null}function G(a,b){let c=a[b];return"string"==typeof c&&""!==c?c:null}function H(a){return"object"!=typeof a||null===a||Array.isArray(a)?null:a}let I=(0,g.h)("daily-summary"),J=2*h.uv;function K(){let a=globalThis.__dailySummaryGenerating;return!!a?.active&&(!(Date.now()-a.startedAt>i.R7+1e4)||(I.warn("failsafe-reset",{startedAt:a.startedAt}),globalThis.__dailySummaryGenerating=void 0,!1))}function L(){return K()?globalThis.__dailySummaryGenerating??null:null}class M extends Error{constructor(){super("Summary generation is already in progress"),this.name="ConcurrentGenerationError"}}class N extends Error{constructor(){super("Summary generation timed out"),this.name="GenerationTimeoutError"}}class O extends Error{constructor(a){super(a),this.name="OutputValidationError"}}function P(a,b=0){return null===a?"-":b>0?a.toFixed(b):String(a)}async function Q(a,b){let c,e;try{c=await new Promise((c,e)=>{(0,d.execFile)("opencode",["export","--sanitize",a],{cwd:b,timeout:3e4,maxBuffer:4194304,encoding:"utf8"},(a,b)=>a?e(a):c(b))})}catch(b){return I.debug("opencode-export-failed",{sessionId:a,error:b instanceof Error?b.message:String(b)}),null}try{e=JSON.parse(c)}catch{return I.warn("opencode-export-unparsable",{sessionId:a,bytes:c.length}),null}let f=function(a){let b=[],c=new Set(E),d=(a,e)=>{if(Array.isArray(a))return void a.forEach((a,b)=>d(a,`${e}[${b}]`));if("object"==typeof a&&null!==a)for(let[f,g]of Object.entries(a)){let a=""===e?f:`${e}.${f}`;if(c.has(f)){if(null==g||""===g||"string"==typeof g&&g.startsWith("[redacted:")||function(a){if("object"!=typeof a||null===a||Array.isArray(a))return!1;let b=Object.keys(a);return 1===b.length&&"redacted"===b[0]}(g)||"number"==typeof g||"boolean"==typeof g)continue;b.push({path:a,kind:"string"==typeof g?"plaintext":"unredacted-object"});continue}d(g,a)}};return d(a,""),b}(e);return f.length>0?(I.warn("opencode-export-redaction-audit-failed",{sessionId:a,leaks:f.length,paths:f.slice(0,5).map(a=>a.path)}),null):function(a){let b=H(a);if(null===b)return null;let c=H(b.info);if(null===c)return null;let d=H(c.model),e=null===d?null:G(d,"providerID"),f=null===d?null:G(d,"id"),g=H(c.time),h=0,i=0,j=0,k=new Set;for(let a of Array.isArray(b.messages)?b.messages:[]){let b=H(a);if(null===b)continue;let c=H(b.info),d=null===c?null:G(c,"role");for(let a of("user"===d?h+=1:"assistant"===d&&(i+=1),Array.isArray(b.parts)?b.parts:[])){let b=H(a);if(null===b||"tool"!==G(b,"type"))continue;j+=1;let c=G(b,"tool");null!==c&&k.add(c)}}return{sessionId:G(c,"id"),agent:G(c,"agent"),model:null!==e&&null!==f?`${e}/${f}`:f,version:G(c,"version"),cost:F(c,"cost"),userMessages:h,assistantMessages:i,tools:[...k].sort(),toolCalls:j,createdAt:null===g?null:F(g,"created"),updatedAt:null===g?null:F(g,"updated")}}(e)}async function R(a,b){let c=(0,r.PY)(a,b).filter(a=>a.cliToolId===D.k),d=c.slice(0,20),e=c.length-d.length,f=[],g=Date.now()+9e4,h=0;for(let[a,c]of d.entries()){if(Date.now()>=g){h=d.length-a,I.warn("opencode-export-budget-exhausted",{date:b,abandoned:h});break}let e=await Q(c.sessionId);null!==e&&f.push({worktreeId:c.worktreeId,summary:e})}return{entries:f,skipped:e+h}}async function S(a,b){let{date:c,tool:d,model:g,userInstruction:k}=b;if(K())throw I.warn("concurrent-rejected",{date:c}),new M;globalThis.__dailySummaryGenerating={active:!0,startedAt:Date.now(),date:c,tool:d};try{I.info("generation-started",{date:c,tool:d});try{(0,s.Yc)(a)}catch(a){I.warn("cost-sample-failed",{error:a instanceof Error?a.message:String(a)})}let b=new Date(c+"T00:00:00"),v=new Date(c+"T23:59:59.999"),w=(0,o.getMessagesByDateRange)(a,{after:b,before:v});if(0===w.length)throw new O("No messages found for the specified date");let x=(0,q.vi)(a),y=new Map;for(let a of x)y.set(a.id,a.name);let z=(0,t.Yg)(a),D=z.filter(a=>!!a.enabled&&!!(0,e.existsSync)(a.path)&&!!(0,e.existsSync)((0,f.join)(a.path,".git")));D.length<z.length&&I.info("repositories-filtered",{total:z.length,valid:D.length,skipped:z.length-D.length});let E=b.toISOString(),F=v.toISOString(),G=await (0,C.wj)((0,u.z0)(D,E,F),i.qw,new Map),H=Array.from(G.values()).flatMap(({commits:a})=>a.map(a=>a.message)),K=await (0,C.wj)(A(D,H).catch(()=>[]),i.DE,[]),L=(0,B.hh)(a,{days:1,until:b.getTime()+B.ec}),M=function(a,b,c,d,e,f){let g=`You are a technical report generator. Summarize the following work logs into a concise daily report in Japanese Markdown format.
2
3
 
3
4
  Rules:
4
5
  - Summarize by worktree/branch
@@ -72,5 +73,4 @@ ${e}`)}catch(a){I.warn("opencode-export-section-failed",{date:c,error:a instance
72
73
  AND event IN ('prompt_answered_human', 'prompt_answered_auto')
73
74
  GROUP BY event
74
75
  `).all(b,c));return{humanResponds:d.get("prompt_answered_human")??0,autoAnswered:d.get("prompt_answered_auto")??0}}(a,l,k):{humanResponds:0,autoAnswered:0},suppressedByPolicy:null}}}},67548:(a,b,c)=>{c.d(b,{Hx:()=>s,WM:()=>o,ci:()=>p,f0:()=>q,mc:()=>m,ox:()=>t,y3:()=>n});var d=c(29021),e=c.n(d),f=c(21820),g=c.n(f),h=c(33873),i=c.n(h);let j="CM_UAT_ISOLATION",k="own-home",l="CM_UAT_DEDICATED_USER",m="project,local";function n(a=process.env){let b=a[j];return"1"===b?"shared-read-only":b===k?"own-home":"off"}function o(a=process.env){return"off"!==n(a)}class p extends Error{constructor(a,b,c){super("own-home"===n()?`${j}=${k}: refusing to start ${a}: ${b}. This server writes the hook config only inside the dedicated user's own HOME, and ${a} would otherwise start with hooks this server did not prepare. ${c}`:`${j}=1: refusing to start ${a}: ${b}. This server does not write the shared hook config in UAT isolation, and ${a} would read it anyway and run the production hooks. ${c}`),this.name="UatIsolationLaunchRefusedError"}}let q="Run the UAT with the same CommandMate build as the production server, so the shared file already matches what this build writes.",r=`Run ${j}=${k} as the user named by ${l}, with HOME set to that user's home and every hook config path (CODEX_HOME, CM_AGENT_HOOKS_DIR, ...) inside it.`;function s(a,b,c=process.env){if("own-home"!==n(c))return;let d=function(a,b=process.env,c=function(){let a=g().userInfo();return{username:a.username,uid:a.uid,homedir:a.homedir}}()){let d,f,h=b[l];if(!h)return`${l} is not set`;if(c.username!==h)return`this process runs as ${c.username}, not as the dedicated user ${h}`;let j=b.HOME;if(!j||!i().isAbsolute(j))return"HOME is not set to an absolute path";try{d=e().realpathSync(j),f=e().realpathSync(c.homedir)}catch{return`HOME (${j}) or ${h}'s home directory (${c.homedir}) does not exist`}if(d!==f)return`HOME (${j}) is not ${h}'s home directory (${c.homedir})`;if(e().statSync(d).uid!==c.uid)return`HOME (${j}) is not owned by ${h}`;for(let b of a){let a=function(a){let b,c=i().resolve(a),d=[];for(;;){let b=!1;try{e().lstatSync(c),b=!0}catch{b=!1}if(b)break;let f=i().dirname(c);if(f===c)return`${a} has no existing ancestor`;d.unshift(i().basename(c)),c=f}try{b=e().realpathSync(c)}catch{return`${c} is a symlink that points nowhere`}return{real:i().join(b,...d),owner:e().statSync(b).uid}}(b);if("string"==typeof a)return a;if(a.real!==d&&!a.real.startsWith(`${d}${i().sep}`))return`${b} resolves to ${a.real}, outside ${h}'s HOME (${d})`;if(a.owner!==c.uid)return`${b} (${a.real}) is not owned by ${h}`}return null}(b,c);if(d)throw new p(a,d,r)}function t(a,b,c=process.env){return"shared-read-only"===n(c)?"read-only":(s(a,b,c),"write")}},70673:(a,b,c)=>{function d(a){return a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function e(a,b=30){return a.length<=b?a:`${a.substring(0,b-3)}...`}c.d(b,{Nt:()=>d,W5:()=>e,wj:()=>g});class f extends Error{constructor(a){super(a),this.name="TimeoutError"}}function g(a,b,c){return new Promise((d,e)=>{let g=setTimeout(()=>{void 0!==c?d(c):e(new f(`Operation timed out after ${b}ms`))},b);a.then(a=>{clearTimeout(g),d(a)},a=>{clearTimeout(g),e(a)})})}},73434:(a,b,c)=>{c.d(b,{hh:()=>f});let d=["CLAUDECODE","CM_AUTH_TOKEN","CM_AUTH_TOKEN_HASH","CM_AUTH_EXPIRE","CM_HTTPS_KEY","CM_HTTPS_CERT","CM_ALLOWED_IPS","CM_TRUST_PROXY","CM_DB_PATH","GH_DEBUG"],e=["CM_AGENT_INSTANCE_ID","CM_AGENT_TOOL","CM_AGENT_WORKTREE_ID","CM_HOOK_PORT","CM_HOOK_URL","CM_PERMISSION_HOOK_URL"];function f(){let a={...process.env};for(let b of Object.keys(a))(d.includes(b)||e.includes(b)||b.startsWith("CM_HOOK_"))&&delete a[b];return a}},81776:(a,b,c)=>{c.d(b,{B0:()=>o,En:()=>l,n$:()=>m});var d=c(79646),e=c(29021),f=c(21820),g=c(33873),h=c(73434);let i="copilot",j=/(\d+\.\d+\.\d+(?:[-+][0-9A-Za-z.-]+)?)/;function k(a){try{if(!(0,e.statSync)(a).isFile())return!1;return(0,e.accessSync)(a,e.constants.X_OK),!0}catch{return!1}}function l(a){return m(a,1)[0]??null}function m(a,b=1/0){let c=process.env.PATH;if(!c||b<=0)return[];let d=[];for(let e of c.split(g.delimiter)){if(!e)continue;let c=(0,g.join)(e,a);if(!d.includes(c)&&k(c)&&(d.push(c),d.length>=b))break}return d}function n(a){return new Promise(b=>{(0,d.execFile)(a,["--version"],{timeout:5e3,maxBuffer:65536,env:(0,h.hh)()},(a,c,d)=>{if(a)return void b(null);let e=j.exec(`${c??""}
75
- ${d??""}`);b(e?e[1]:null)})})}async function o(){let a=l(i);if(a){let b=await n(a);if(b)return{path:a,version:b,source:"path"}}if(!l("gh"))return null;for(let a of function(){let a=process.env.XDG_DATA_HOME||(0,g.join)((0,f.homedir)(),".local","share"),b=(0,g.join)(a,"gh",i);return[b,(0,g.join)(b,i)]}()){if(!k(a))continue;let b=await n(a);if(b)return{path:a,version:b,source:"gh-managed"}}return null}},85322:(a,b,c)=>{c.d(b,{k:()=>d});let d="opencode"},95759:(a,b,c)=>{c.d(b,{$s:()=>m,Qq:()=>n,b6:()=>h,mV:()=>o});var d=c(79646),e=c(81776),f=c(73434);let g="opencode",h="opencode2",i=/^opencode v(\d+)\.(\d+)\.(\d+)((?:[-+][0-9A-Za-z.-]+)?)$/,j=/^v?(\d+)\.(\d+)\.(\d+)((?:[-+][0-9A-Za-z.-]+)?)$/,k=new Map;async function l(a,b){let c=[];for(let g of a)for(let a of(0,e.n$)(g,4)){if(c.some(b=>b.path===a))continue;let e=await function(a){let b=Date.now(),c=k.get(a);if(c&&c.expiresAt>b)return c.info;let e=new Promise(b=>{try{(0,d.execFile)(a,["--version"],{timeout:5e3,maxBuffer:65536,env:(0,f.hh)()},(a,c,d)=>{if(a)return void b(null);b(function(a){for(let b of a.split(/\r?\n/)){let a=b.trim();if(!a)continue;let c=i.exec(a)??j.exec(a);if(!c)continue;let d=Number(c[1]),e=`${c[1]}.${c[2]}.${c[3]}${c[4]??""}`;if(1===d)return{generation:"v1",version:e};if(d>=2)return{generation:"v2",version:e};break}return null}(`${c??""}
76
- ${d??""}`))})}catch{b(null)}});return k.set(a,{expiresAt:b+3e4,info:e}),e}(a);if(c.push({path:a,info:e}),e?.generation===b)return{executable:{path:a,version:e.version,generation:b},probed:c}}return{executable:null,probed:c}}function m(){return l([g],"v1")}function n(){return l([h,g],"v2")}function o(a){if(a.executable)return null;let b=a.probed.find(a=>a.info?.generation==="v2");if(b?.info)return`\`opencode\` at ${b.path} is OpenCode V2 ${b.info.version}, not OpenCode 1.x (npm \`@opencode/cli\` registers both \`opencode\` and \`opencode2\`). Use the OpenCode V2 agent, or put an OpenCode 1.x \`opencode\` on PATH.`;let c=a.probed[0];return c?`\`opencode\` at ${c.path} did not report an OpenCode 1.x version (\`opencode --version\`).`:null}}};
76
+ ${d??""}`);b(e?e[1]:null)})})}async function o(){let a=l(i);if(a){let b=await n(a);if(b)return{path:a,version:b,source:"path"}}if(!l("gh"))return null;for(let a of function(){let a=process.env.XDG_DATA_HOME||(0,g.join)((0,f.homedir)(),".local","share"),b=(0,g.join)(a,"gh",i);return[b,(0,g.join)(b,i)]}()){if(!k(a))continue;let b=await n(a);if(b)return{path:a,version:b,source:"gh-managed"}}return null}},85322:(a,b,c)=>{c.d(b,{k:()=>d});let d="opencode"}};