commandmate 0.35.0 → 0.36.1

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 (234) hide show
  1. package/.next/BUILD_ID +1 -1
  2. package/.next/app-build-manifest.json +333 -324
  3. package/.next/app-path-routes-manifest.json +25 -25
  4. package/.next/build-manifest.json +5 -5
  5. package/.next/prerender-manifest.json +9 -9
  6. package/.next/required-server-files.json +1 -1
  7. package/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  8. package/.next/server/app/api/agents/update/route_client-reference-manifest.js +1 -1
  9. package/.next/server/app/api/agents/versions/route_client-reference-manifest.js +1 -1
  10. package/.next/server/app/api/app/update/route_client-reference-manifest.js +1 -1
  11. package/.next/server/app/api/app/update-check/route.js +1 -1
  12. package/.next/server/app/api/app/update-check/route_client-reference-manifest.js +1 -1
  13. package/.next/server/app/api/assistant/conversation/route_client-reference-manifest.js +1 -1
  14. package/.next/server/app/api/assistant/current-output/route_client-reference-manifest.js +1 -1
  15. package/.next/server/app/api/assistant/messages/route_client-reference-manifest.js +1 -1
  16. package/.next/server/app/api/assistant/session/route_client-reference-manifest.js +1 -1
  17. package/.next/server/app/api/assistant/start/route_client-reference-manifest.js +1 -1
  18. package/.next/server/app/api/assistant/terminal/route_client-reference-manifest.js +1 -1
  19. package/.next/server/app/api/assistant/tools/route_client-reference-manifest.js +1 -1
  20. package/.next/server/app/api/auth/login/route_client-reference-manifest.js +1 -1
  21. package/.next/server/app/api/auth/logout/route_client-reference-manifest.js +1 -1
  22. package/.next/server/app/api/auth/status/route_client-reference-manifest.js +1 -1
  23. package/.next/server/app/api/capabilities/route.js +1 -1
  24. package/.next/server/app/api/capabilities/route_client-reference-manifest.js +1 -1
  25. package/.next/server/app/api/daily-summary/route_client-reference-manifest.js +1 -1
  26. package/.next/server/app/api/daily-summary/status/route_client-reference-manifest.js +1 -1
  27. package/.next/server/app/api/external-apps/[id]/health/route_client-reference-manifest.js +1 -1
  28. package/.next/server/app/api/external-apps/[id]/route_client-reference-manifest.js +1 -1
  29. package/.next/server/app/api/external-apps/route_client-reference-manifest.js +1 -1
  30. package/.next/server/app/api/fs/browse/route_client-reference-manifest.js +1 -1
  31. package/.next/server/app/api/fs/recent-paths/route_client-reference-manifest.js +1 -1
  32. package/.next/server/app/api/hooks/agent-event/route_client-reference-manifest.js +1 -1
  33. package/.next/server/app/api/hooks/claude-done/route_client-reference-manifest.js +1 -1
  34. package/.next/server/app/api/hooks/permission-request/route_client-reference-manifest.js +1 -1
  35. package/.next/server/app/api/metrics/vibe/route_client-reference-manifest.js +1 -1
  36. package/.next/server/app/api/ollama/models/route_client-reference-manifest.js +1 -1
  37. package/.next/server/app/api/push/escalation/route_client-reference-manifest.js +1 -1
  38. package/.next/server/app/api/push/subscriptions/route_client-reference-manifest.js +1 -1
  39. package/.next/server/app/api/push/vapid/route_client-reference-manifest.js +1 -1
  40. package/.next/server/app/api/relays/[relayId]/cancel/route_client-reference-manifest.js +1 -1
  41. package/.next/server/app/api/relays/route_client-reference-manifest.js +1 -1
  42. package/.next/server/app/api/remote/pair/route_client-reference-manifest.js +1 -1
  43. package/.next/server/app/api/repositories/[id]/route_client-reference-manifest.js +1 -1
  44. package/.next/server/app/api/repositories/[id]/todos/[todoId]/route_client-reference-manifest.js +1 -1
  45. package/.next/server/app/api/repositories/[id]/todos/route_client-reference-manifest.js +1 -1
  46. package/.next/server/app/api/repositories/clone/[jobId]/route_client-reference-manifest.js +1 -1
  47. package/.next/server/app/api/repositories/clone/route_client-reference-manifest.js +1 -1
  48. package/.next/server/app/api/repositories/excluded/route_client-reference-manifest.js +1 -1
  49. package/.next/server/app/api/repositories/restore/route_client-reference-manifest.js +1 -1
  50. package/.next/server/app/api/repositories/route_client-reference-manifest.js +1 -1
  51. package/.next/server/app/api/repositories/scan/route_client-reference-manifest.js +1 -1
  52. package/.next/server/app/api/repositories/sync/route_client-reference-manifest.js +1 -1
  53. package/.next/server/app/api/repositories/validate-path/route_client-reference-manifest.js +1 -1
  54. package/.next/server/app/api/settings/default-agents/route_client-reference-manifest.js +1 -1
  55. package/.next/server/app/api/settings/default-surface-mode/route_client-reference-manifest.js +1 -1
  56. package/.next/server/app/api/sidebar/group-order/route_client-reference-manifest.js +1 -1
  57. package/.next/server/app/api/skills/[id]/route_client-reference-manifest.js +1 -1
  58. package/.next/server/app/api/skills/installations/route_client-reference-manifest.js +1 -1
  59. package/.next/server/app/api/skills/operations/route_client-reference-manifest.js +1 -1
  60. package/.next/server/app/api/skills/reindex/route_client-reference-manifest.js +1 -1
  61. package/.next/server/app/api/skills/route_client-reference-manifest.js +1 -1
  62. package/.next/server/app/api/slash-commands/route_client-reference-manifest.js +1 -1
  63. package/.next/server/app/api/tasks/[taskId]/cancel/route_client-reference-manifest.js +1 -1
  64. package/.next/server/app/api/tasks/[taskId]/route_client-reference-manifest.js +1 -1
  65. package/.next/server/app/api/templates/[id]/route_client-reference-manifest.js +1 -1
  66. package/.next/server/app/api/templates/route_client-reference-manifest.js +1 -1
  67. package/.next/server/app/api/todos/route_client-reference-manifest.js +1 -1
  68. package/.next/server/app/api/verification/runs/[runId]/route_client-reference-manifest.js +1 -1
  69. package/.next/server/app/api/verification/runs/route_client-reference-manifest.js +1 -1
  70. package/.next/server/app/api/worktrees/[id]/auto-yes/route_client-reference-manifest.js +1 -1
  71. package/.next/server/app/api/worktrees/[id]/capture/route_client-reference-manifest.js +1 -1
  72. package/.next/server/app/api/worktrees/[id]/clear-composer/route_client-reference-manifest.js +1 -1
  73. package/.next/server/app/api/worktrees/[id]/cli-reference/route_client-reference-manifest.js +1 -1
  74. package/.next/server/app/api/worktrees/[id]/cli-tool/route_client-reference-manifest.js +1 -1
  75. package/.next/server/app/api/worktrees/[id]/cmate/schedules/route_client-reference-manifest.js +1 -1
  76. package/.next/server/app/api/worktrees/[id]/current-output/route_client-reference-manifest.js +1 -1
  77. package/.next/server/app/api/worktrees/[id]/env/route_client-reference-manifest.js +1 -1
  78. package/.next/server/app/api/worktrees/[id]/execution-logs/[logId]/route_client-reference-manifest.js +1 -1
  79. package/.next/server/app/api/worktrees/[id]/execution-logs/route_client-reference-manifest.js +1 -1
  80. package/.next/server/app/api/worktrees/[id]/files/[...path]/route_client-reference-manifest.js +1 -1
  81. package/.next/server/app/api/worktrees/[id]/git/branch/create/route_client-reference-manifest.js +1 -1
  82. package/.next/server/app/api/worktrees/[id]/git/branch/delete/route_client-reference-manifest.js +1 -1
  83. package/.next/server/app/api/worktrees/[id]/git/branches/route_client-reference-manifest.js +1 -1
  84. package/.next/server/app/api/worktrees/[id]/git/checkout/route_client-reference-manifest.js +1 -1
  85. package/.next/server/app/api/worktrees/[id]/git/commit/route_client-reference-manifest.js +1 -1
  86. package/.next/server/app/api/worktrees/[id]/git/diff/route_client-reference-manifest.js +1 -1
  87. package/.next/server/app/api/worktrees/[id]/git/fetch/route_client-reference-manifest.js +1 -1
  88. package/.next/server/app/api/worktrees/[id]/git/log/route_client-reference-manifest.js +1 -1
  89. package/.next/server/app/api/worktrees/[id]/git/pull/route_client-reference-manifest.js +1 -1
  90. package/.next/server/app/api/worktrees/[id]/git/push/route_client-reference-manifest.js +1 -1
  91. package/.next/server/app/api/worktrees/[id]/git/reset/route_client-reference-manifest.js +1 -1
  92. package/.next/server/app/api/worktrees/[id]/git/revert/route_client-reference-manifest.js +1 -1
  93. package/.next/server/app/api/worktrees/[id]/git/show/[commitHash]/route_client-reference-manifest.js +1 -1
  94. package/.next/server/app/api/worktrees/[id]/git/stage/route_client-reference-manifest.js +1 -1
  95. package/.next/server/app/api/worktrees/[id]/git/staged/route_client-reference-manifest.js +1 -1
  96. package/.next/server/app/api/worktrees/[id]/git/stash/[index]/route_client-reference-manifest.js +1 -1
  97. package/.next/server/app/api/worktrees/[id]/git/stash/apply/route_client-reference-manifest.js +1 -1
  98. package/.next/server/app/api/worktrees/[id]/git/stash/pop/route_client-reference-manifest.js +1 -1
  99. package/.next/server/app/api/worktrees/[id]/git/stash/push/route_client-reference-manifest.js +1 -1
  100. package/.next/server/app/api/worktrees/[id]/git/stash/route_client-reference-manifest.js +1 -1
  101. package/.next/server/app/api/worktrees/[id]/git/status/route_client-reference-manifest.js +1 -1
  102. package/.next/server/app/api/worktrees/[id]/git/unstage/route_client-reference-manifest.js +1 -1
  103. package/.next/server/app/api/worktrees/[id]/git/working-diff/route_client-reference-manifest.js +1 -1
  104. package/.next/server/app/api/worktrees/[id]/instances/notes/route_client-reference-manifest.js +1 -1
  105. package/.next/server/app/api/worktrees/[id]/instances/opencode/route_client-reference-manifest.js +1 -1
  106. package/.next/server/app/api/worktrees/[id]/interrupt/route_client-reference-manifest.js +1 -1
  107. package/.next/server/app/api/worktrees/[id]/kill-session/route_client-reference-manifest.js +1 -1
  108. package/.next/server/app/api/worktrees/[id]/logs/[filename]/route_client-reference-manifest.js +1 -1
  109. package/.next/server/app/api/worktrees/[id]/logs/route_client-reference-manifest.js +1 -1
  110. package/.next/server/app/api/worktrees/[id]/marp-render/route_client-reference-manifest.js +1 -1
  111. package/.next/server/app/api/worktrees/[id]/memos/[memoId]/route_client-reference-manifest.js +1 -1
  112. package/.next/server/app/api/worktrees/[id]/memos/route_client-reference-manifest.js +1 -1
  113. package/.next/server/app/api/worktrees/[id]/messages/route_client-reference-manifest.js +1 -1
  114. package/.next/server/app/api/worktrees/[id]/opencode/diff/route_client-reference-manifest.js +1 -1
  115. package/.next/server/app/api/worktrees/[id]/opencode/session/route_client-reference-manifest.js +1 -1
  116. package/.next/server/app/api/worktrees/[id]/opencode/share/route_client-reference-manifest.js +1 -1
  117. package/.next/server/app/api/worktrees/[id]/prompt-response/route_client-reference-manifest.js +1 -1
  118. package/.next/server/app/api/worktrees/[id]/resolve-target/route_client-reference-manifest.js +1 -1
  119. package/.next/server/app/api/worktrees/[id]/respond/route_client-reference-manifest.js +1 -1
  120. package/.next/server/app/api/worktrees/[id]/route_client-reference-manifest.js +1 -1
  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_client-reference-manifest.js +1 -1
  123. package/.next/server/app/api/worktrees/[id]/schedules/route_client-reference-manifest.js +1 -1
  124. package/.next/server/app/api/worktrees/[id]/search/route_client-reference-manifest.js +1 -1
  125. package/.next/server/app/api/worktrees/[id]/send/route_client-reference-manifest.js +1 -1
  126. package/.next/server/app/api/worktrees/[id]/skills/[skillId]/git-workflow/route_client-reference-manifest.js +1 -1
  127. package/.next/server/app/api/worktrees/[id]/skills/[skillId]/install/route_client-reference-manifest.js +1 -1
  128. package/.next/server/app/api/worktrees/[id]/skills/[skillId]/plan/route_client-reference-manifest.js +1 -1
  129. package/.next/server/app/api/worktrees/[id]/skills/[skillId]/uninstall/route_client-reference-manifest.js +1 -1
  130. package/.next/server/app/api/worktrees/[id]/skills/[skillId]/uninstall-plan/route_client-reference-manifest.js +1 -1
  131. package/.next/server/app/api/worktrees/[id]/skills/[skillId]/update/route_client-reference-manifest.js +1 -1
  132. package/.next/server/app/api/worktrees/[id]/skills/[skillId]/update-plan/route_client-reference-manifest.js +1 -1
  133. package/.next/server/app/api/worktrees/[id]/skills/route_client-reference-manifest.js +1 -1
  134. package/.next/server/app/api/worktrees/[id]/slash-commands/route_client-reference-manifest.js +1 -1
  135. package/.next/server/app/api/worktrees/[id]/special-keys/route_client-reference-manifest.js +1 -1
  136. package/.next/server/app/api/worktrees/[id]/tasks/route_client-reference-manifest.js +1 -1
  137. package/.next/server/app/api/worktrees/[id]/terminal/route_client-reference-manifest.js +1 -1
  138. package/.next/server/app/api/worktrees/[id]/timers/history/route_client-reference-manifest.js +1 -1
  139. package/.next/server/app/api/worktrees/[id]/timers/route_client-reference-manifest.js +1 -1
  140. package/.next/server/app/api/worktrees/[id]/todos/[todoId]/route_client-reference-manifest.js +1 -1
  141. package/.next/server/app/api/worktrees/[id]/todos/route_client-reference-manifest.js +1 -1
  142. package/.next/server/app/api/worktrees/[id]/tree/[...path]/route_client-reference-manifest.js +1 -1
  143. package/.next/server/app/api/worktrees/[id]/tree/route_client-reference-manifest.js +1 -1
  144. package/.next/server/app/api/worktrees/[id]/upload/[...path]/route_client-reference-manifest.js +1 -1
  145. package/.next/server/app/api/worktrees/[id]/verify/config/route_client-reference-manifest.js +1 -1
  146. package/.next/server/app/api/worktrees/[id]/verify/route_client-reference-manifest.js +1 -1
  147. package/.next/server/app/api/worktrees/[id]/verify/runs/[runId]/cancel/route_client-reference-manifest.js +1 -1
  148. package/.next/server/app/api/worktrees/[id]/verify/runs/[runId]/route_client-reference-manifest.js +1 -1
  149. package/.next/server/app/api/worktrees/[id]/verify/runs/route_client-reference-manifest.js +1 -1
  150. package/.next/server/app/api/worktrees/[id]/viewed/route_client-reference-manifest.js +1 -1
  151. package/.next/server/app/api/worktrees/apply-default-agents/route_client-reference-manifest.js +1 -1
  152. package/.next/server/app/api/worktrees/route.js +1 -1
  153. package/.next/server/app/api/worktrees/route_client-reference-manifest.js +1 -1
  154. package/.next/server/app/chat/page.js +2 -2
  155. package/.next/server/app/chat/page.js.nft.json +1 -1
  156. package/.next/server/app/chat/page_client-reference-manifest.js +1 -1
  157. package/.next/server/app/login/page_client-reference-manifest.js +1 -1
  158. package/.next/server/app/manifest.webmanifest/route_client-reference-manifest.js +1 -1
  159. package/.next/server/app/more/page.js +2 -2
  160. package/.next/server/app/more/page_client-reference-manifest.js +1 -1
  161. package/.next/server/app/offline/page_client-reference-manifest.js +1 -1
  162. package/.next/server/app/page_client-reference-manifest.js +1 -1
  163. package/.next/server/app/proxy/[...path]/route_client-reference-manifest.js +1 -1
  164. package/.next/server/app/repositories/page_client-reference-manifest.js +1 -1
  165. package/.next/server/app/review/page_client-reference-manifest.js +1 -1
  166. package/.next/server/app/sessions/page.js +2 -2
  167. package/.next/server/app/sessions/page.js.nft.json +1 -1
  168. package/.next/server/app/sessions/page_client-reference-manifest.js +1 -1
  169. package/.next/server/app/skills/[skillId]/page.js +1 -1
  170. package/.next/server/app/skills/[skillId]/page.js.nft.json +1 -1
  171. package/.next/server/app/skills/[skillId]/page_client-reference-manifest.js +1 -1
  172. package/.next/server/app/skills/installed/page_client-reference-manifest.js +1 -1
  173. package/.next/server/app/skills/page_client-reference-manifest.js +1 -1
  174. package/.next/server/app/worktrees/[id]/files/[...path]/page.js +2 -2
  175. package/.next/server/app/worktrees/[id]/files/[...path]/page_client-reference-manifest.js +1 -1
  176. package/.next/server/app/worktrees/[id]/page.js +9 -22
  177. package/.next/server/app/worktrees/[id]/page.js.nft.json +1 -1
  178. package/.next/server/app/worktrees/[id]/page_client-reference-manifest.js +1 -1
  179. package/.next/server/app/worktrees/[id]/terminal/page_client-reference-manifest.js +1 -1
  180. package/.next/server/app-paths-manifest.json +25 -25
  181. package/.next/server/chunks/1707.js +14 -0
  182. package/.next/server/chunks/2119.js +1 -1
  183. package/.next/server/chunks/2445.js +1 -1
  184. package/.next/server/chunks/3123.js +1 -1
  185. package/.next/server/chunks/3543.js +1 -1
  186. package/.next/server/chunks/364.js +1 -0
  187. package/.next/server/chunks/3945.js +1 -1
  188. package/.next/server/chunks/4802.js +1 -1
  189. package/.next/server/chunks/5364.js +1 -0
  190. package/.next/server/chunks/6130.js +1 -1
  191. package/.next/server/chunks/7004.js +1 -0
  192. package/.next/server/chunks/8728.js +1 -1
  193. package/.next/server/chunks/9123.js +1 -1
  194. package/.next/server/chunks/9627.js +1 -1
  195. package/.next/server/chunks/9701.js +1 -0
  196. package/.next/server/middleware-build-manifest.js +1 -1
  197. package/.next/server/middleware-manifest.json +5 -5
  198. package/.next/server/pages/500.html +1 -1
  199. package/.next/server/server-reference-manifest.json +1 -1
  200. package/.next/static/chunks/2039-117a361f795ddc4b.js +1 -0
  201. package/.next/static/chunks/2053-ce3fe896ad45e50f.js +1 -0
  202. package/.next/static/chunks/2407-e738634dab84534c.js +1 -0
  203. package/.next/static/chunks/3160-79d24ca264a528b9.js +1 -0
  204. package/.next/static/chunks/4949-f547605bd6078157.js +1 -0
  205. package/.next/static/chunks/5520-8bde9501846ae660.js +1 -0
  206. package/.next/static/chunks/{6022-7a7d1760fc9814c7.js → 6022-d2d7bd9373ff3ae9.js} +1 -1
  207. package/.next/static/chunks/6983-3ed2099251793bdf.js +1 -0
  208. package/.next/static/chunks/934-a37509667baa86ee.js +1 -0
  209. package/.next/static/chunks/app/chat/page-bfc1f5bb17bd771d.js +1 -0
  210. package/.next/static/chunks/app/more/page-400ffa825f8f150e.js +1 -0
  211. package/.next/static/chunks/app/sessions/page-b8651c3f17c36800.js +1 -0
  212. package/.next/static/chunks/app/skills/[skillId]/{page-844872df04f52943.js → page-ce8f6fd9e4356580.js} +1 -1
  213. package/.next/static/chunks/app/worktrees/[id]/page-3d147d6dd2fdc101.js +1 -0
  214. package/.next/static/chunks/{webpack-1dc9eb5ebb4fa5ff.js → webpack-0281b30457d46ebc.js} +1 -1
  215. package/.next/static/css/c511ecdf1e7f18a0.css +1 -0
  216. package/.next/trace +14 -14
  217. package/dist/server/locales/en/worktree.json +5 -0
  218. package/dist/server/locales/ja/worktree.json +5 -0
  219. package/dist/server/src/lib/auto-yes-state.js +36 -0
  220. package/package.json +1 -1
  221. package/.next/server/chunks/120.js +0 -1
  222. package/.next/server/chunks/7593.js +0 -1
  223. package/.next/static/chunks/1191-b7dfdfe86b1d31d1.js +0 -1
  224. package/.next/static/chunks/2053-9ac860ab4e92ac89.js +0 -1
  225. package/.next/static/chunks/2407-b9001cc6041876e1.js +0 -1
  226. package/.next/static/chunks/4809-145884b958e7d9a6.js +0 -1
  227. package/.next/static/chunks/5542-b6457f305d724a6b.js +0 -1
  228. package/.next/static/chunks/app/chat/page-609c9a0f5ce44799.js +0 -1
  229. package/.next/static/chunks/app/more/page-7c5380e4a7561935.js +0 -1
  230. package/.next/static/chunks/app/sessions/page-6486d9a643c1dc6f.js +0 -1
  231. package/.next/static/chunks/app/worktrees/[id]/page-3a58ae66e203f935.js +0 -1
  232. package/.next/static/css/b09bede85744e1cf.css +0 -1
  233. /package/.next/static/{0vChXhzA5YWj3f0D6A-Cn → OjmwYkJmQbLPFMjXdrB1R}/_buildManifest.js +0 -0
  234. /package/.next/static/{0vChXhzA5YWj3f0D6A-Cn → OjmwYkJmQbLPFMjXdrB1R}/_ssgManifest.js +0 -0
@@ -0,0 +1 @@
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3310],{6191:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(71847).A)("plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]])},8803:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(71847).A)("arrow-down",[["path",{d:"M12 5v14",key:"s699le"}],["path",{d:"m19 12-7 7-7-7",key:"1idqje"}]])},20562:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(71847).A)("arrow-up",[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]])},48314:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(71847).A)("rotate-ccw",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]])},68695:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(71847).A)("circle-arrow-up",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m16 12-4-4-4 4",key:"177agl"}],["path",{d:"M12 16V8",key:"1sbj14"}]])},75676:(e,t,s)=>{"use strict";s.d(t,{jg:()=>n,kQ:()=>i,mR:()=>o,mS:()=>d,wf:()=>a});let a="terminal",r=new Set(["terminal","chat"]);function n(e){return"string"==typeof e&&r.has(e)}let i={data:null,messageId:null,visible:!1,answering:!1},l={mode:"split",mobileActivePane:"terminal",leftPaneTab:"history",splitRatio:.5,leftPaneCollapsed:!1,activityBar:{active:"files"},historyPane:{visible:!0,width:25,collapsed:!1}},d={type:null,message:null,retryable:!1,retryCount:0};function o(){return{phase:"idle",prompt:{...i},layout:{...l},error:{...d},messages:[],wsConnected:!1}}},80867:(e,t,s)=>{Promise.resolve().then(s.bind(s,95775))},95775:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>T});var a=s(95155),r=s(52619),n=s.n(r),i=s(18955),l=s(54388),d=s(28019),o=s(12115);function c(e){var t;let{appId:s,pollInterval:r=3e4,showResponseTime:n=!1,compact:l=!1}=e,d=(0,i.c)("externalApps"),[c,m]=(0,o.useState)(null),[p,x]=(0,o.useState)(!0),u=(0,o.useCallback)(async()=>{try{let e=await fetch("/api/external-apps/".concat(s,"/health"));if(e.ok){let t=await e.json();m(t)}else m({id:s,healthy:!1,lastChecked:Date.now(),error:"Failed to check health"})}catch(e){m({id:s,healthy:!1,lastChecked:Date.now(),error:"Network error"})}finally{x(!1)}},[s]);if((0,o.useEffect)(()=>{u();let e=setInterval(u,r);return()=>clearInterval(e)},[u,r]),p)return(0,a.jsxs)("div",{className:"flex items-center gap-1.5",children:[(0,a.jsx)("span",{className:"inline-block h-2.5 w-2.5 rounded-full bg-muted-foreground animate-pulse"}),!l&&(0,a.jsx)("span",{className:"text-xs text-muted-foreground",children:d("status.checking")})]});let h=null!=(t=null==c?void 0:c.healthy)&&t,f=h?"bg-success":"bg-muted-foreground",g=d(h?"status.running":"status.stopped");return l?(0,a.jsx)("span",{className:"inline-block h-2.5 w-2.5 rounded-full ".concat(f),title:g}):(0,a.jsxs)("div",{className:"flex items-center gap-1.5",children:[(0,a.jsx)("span",{className:"inline-block h-2.5 w-2.5 rounded-full ".concat(f)}),(0,a.jsx)("span",{className:"text-xs ".concat(h?"text-success-foreground":"text-muted-foreground"),children:g}),n&&(null==c?void 0:c.responseTime)!==void 0&&(0,a.jsxs)("span",{className:"text-xs text-muted-foreground",children:["(",c.responseTime,"ms)"]})]})}function m(e){var t;let{app:s,onEdit:r,onDelete:n}=e,l=(0,i.c)("externalApps"),m=(0,i.c)("common"),[p,x]=(0,o.useState)(!1),[u,h]=(0,o.useState)(!1),f=async()=>{h(!0);try{await n(s.id)}finally{h(!1),x(!1)}},g="/proxy/".concat(s.pathPrefix,"/");return(0,a.jsxs)(d.Zp,{padding:"md",className:"relative",children:[(0,a.jsxs)("div",{className:"flex items-start justify-between mb-3",children:[(0,a.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,a.jsx)("h4",{className:"text-base font-semibold text-foreground truncate",children:s.displayName}),(0,a.jsx)("p",{className:"text-xs text-muted-foreground mt-0.5 font-mono truncate",children:s.name})]}),(0,a.jsx)(d.Ex,{variant:{sveltekit:"warning",streamlit:"error",nextjs:"info",other:"gray"}[s.appType]||"gray",children:{sveltekit:"SvelteKit",streamlit:"Streamlit",nextjs:"Next.js",other:"Other"}[t=s.appType]||t})]}),(0,a.jsxs)("div",{className:"space-y-2 mb-4",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsx)("span",{className:"text-sm text-muted-foreground",children:l("card.status")}),(0,a.jsx)(c,{appId:s.id,pollInterval:3e4})]}),(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsx)("span",{className:"text-sm text-muted-foreground",children:l("card.port")}),(0,a.jsxs)("span",{className:"text-sm font-mono text-foreground",children:[":",s.targetPort]})]}),(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsx)("span",{className:"text-sm text-muted-foreground",children:l("card.path")}),(0,a.jsxs)("span",{className:"text-sm font-mono text-foreground truncate max-w-[150px]",children:["/proxy/",s.pathPrefix,"/"]})]}),s.websocketEnabled&&(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsx)("span",{className:"text-sm text-muted-foreground",children:l("card.websocket")}),(0,a.jsx)(d.Ex,{variant:"info",children:l("card.enabled")})]}),!s.enabled&&(0,a.jsx)("div",{className:"mt-2 py-1 px-2 bg-warning-subtle border border-warning-border rounded text-xs text-warning-foreground",children:l("card.disabledNotice")})]}),p?(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:l("card.deleteConfirm",{name:s.displayName})}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(d.$n,{variant:"danger",size:"sm",onClick:f,disabled:u,loading:u,children:l("card.delete")}),(0,a.jsx)(d.$n,{variant:"ghost",size:"sm",onClick:()=>x(!1),disabled:u,children:m("cancel")})]})]}):(0,a.jsxs)("div",{className:"flex gap-2 flex-wrap",children:[(0,a.jsx)(d.$n,{variant:"primary",size:"sm",onClick:()=>window.open(g,"_blank"),disabled:!s.enabled,children:l("card.open")}),(0,a.jsx)(d.$n,{variant:"secondary",size:"sm",onClick:()=>r(s),children:l("card.settings")}),(0,a.jsx)(d.$n,{variant:"ghost",size:"sm",onClick:()=>x(!0),className:"text-danger-foreground hover:bg-danger-subtle",children:l("card.delete")})]})]})}var p=s(87531);let x={MIN:1024,MAX:65535},u=/^[a-zA-Z0-9-]+$/,h={sveltekit:"SvelteKit",streamlit:"Streamlit",nextjs:"Next.js",other:"Other"},f=["sveltekit","streamlit","nextjs","other"].map(e=>({value:e,label:h[e]}));function g(e){let{isOpen:t,onClose:s,editApp:r,onSave:n}=e,l=(0,i.c)("externalApps"),c=(0,i.c)("common"),m=!!r,[h,g]=(0,o.useState)(""),[b,j]=(0,o.useState)(""),[y,N]=(0,o.useState)(""),[v,k]=(0,o.useState)(""),[w,C]=(0,o.useState)(""),[S,P]=(0,o.useState)(!1),[A,T]=(0,o.useState)(""),[E,M]=(0,o.useState)(!0),[O,I]=(0,o.useState)({}),[$,F]=(0,o.useState)(!1),[D,z]=(0,o.useState)(null);(0,o.useEffect)(()=>{t&&(r?(g(r.displayName),j(r.name),N(r.pathPrefix),k(r.targetPort),C(r.appType),P(r.websocketEnabled),T(r.description||""),M(r.enabled)):(g(""),j(""),N(""),k(""),C(""),P(!1),T(""),M(!0)),I({}),z(null))},[t,r]);let Z=async e=>{e.preventDefault(),z(null);let t=function(e,t){var s,a,r,n;let i={};return((null==(s=e.displayName)?void 0:s.trim())||(i.displayName="Display name is required"),!t&&((null==(a=e.name)?void 0:a.trim())?u.test(e.name)||(i.name="Only alphanumeric characters and hyphens are allowed"):i.name="Identifier name is required",(null==(r=e.pathPrefix)?void 0:r.trim())?u.test(e.pathPrefix)||(i.pathPrefix="Only alphanumeric characters and hyphens are allowed"):i.pathPrefix="Path prefix is required"),e.targetPort)?"number"!=typeof e.targetPort||Number.isInteger(n=e.targetPort)&&n>=x.MIN&&n<=x.MAX||(i.targetPort="Port must be between ".concat(x.MIN," and ").concat(x.MAX)):i.targetPort="Port number is required",t||e.appType||(i.appType="App type is required"),i}({displayName:h,name:b,pathPrefix:y,targetPort:v,appType:w},m);if(Object.keys(t).length>0)return void I(t);I({}),F(!0);try{if(m&&r){let e=await fetch("/api/external-apps/".concat(r.id),{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({displayName:h,description:A||void 0,targetPort:v||void 0,websocketEnabled:S,enabled:E})});if(!e.ok){let t=await e.json();throw Error(t.error||l("form.updateFailed"))}}else{let e=await fetch("/api/external-apps",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({displayName:h,name:b,pathPrefix:y,targetPort:v,appType:w,websocketEnabled:S,description:A||void 0})});if(!e.ok){let t=await e.json();throw Error(t.error||l("form.createFailed"))}}n(),s()}catch(e){z(e instanceof Error?e.message:l("form.genericError"))}finally{F(!1)}};return(0,a.jsx)(d.Jh,{isOpen:t,onClose:s,title:m?l("form.editTitle"):l("form.addTitle"),size:"md",children:(0,a.jsxs)("form",{onSubmit:Z,className:"space-y-4",children:[(0,a.jsx)("div",{className:"rounded-md bg-warning-subtle p-3 mb-4 border border-warning-border",children:(0,a.jsx)("p",{className:"text-sm text-warning-foreground",children:l("form.securityWarning")})}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("label",{htmlFor:"displayName",className:"block text-sm font-medium text-foreground mb-1",children:[l("form.displayName")," ",(0,a.jsx)("span",{className:"text-danger",children:"*"})]}),(0,a.jsx)(d.pd,{id:"displayName",type:"text",value:h,onChange:e=>g(e.target.value),className:O.displayName?"border-danger":"",placeholder:l("form.displayNamePlaceholder"),disabled:$}),O.displayName&&(0,a.jsx)("p",{className:"mt-1 text-xs text-danger",children:O.displayName})]}),!m&&(0,a.jsxs)("div",{children:[(0,a.jsxs)("label",{htmlFor:"name",className:"block text-sm font-medium text-foreground mb-1",children:[l("form.identifierName")," ",(0,a.jsx)("span",{className:"text-danger",children:"*"})]}),(0,a.jsx)(d.pd,{id:"name",type:"text",value:b,onChange:e=>j(e.target.value),className:"font-mono ".concat(O.name?"border-danger":""),placeholder:l("form.identifierNamePlaceholder"),disabled:$}),(0,a.jsx)("p",{className:"mt-1 text-xs text-muted-foreground",children:l("form.identifierNameHelp")}),O.name&&(0,a.jsx)("p",{className:"mt-1 text-xs text-danger",children:O.name})]}),!m&&(0,a.jsxs)("div",{children:[(0,a.jsxs)("label",{htmlFor:"pathPrefix",className:"block text-sm font-medium text-foreground mb-1",children:[l("form.pathPrefix")," ",(0,a.jsx)("span",{className:"text-danger",children:"*"})]}),(0,a.jsxs)("div",{className:"flex items-center",children:[(0,a.jsx)("span",{className:"text-sm text-muted-foreground mr-1",children:"/proxy/"}),(0,a.jsx)(d.pd,{id:"pathPrefix",type:"text",value:y,onChange:e=>N(e.target.value),className:"w-auto flex-1 font-mono ".concat(O.pathPrefix?"border-danger":""),placeholder:l("form.pathPrefixPlaceholder"),disabled:$}),(0,a.jsx)("span",{className:"text-sm text-muted-foreground ml-1",children:"/"})]}),(0,a.jsx)("p",{className:"mt-1 text-xs text-muted-foreground",children:l("form.pathPrefixHelp")}),O.pathPrefix&&(0,a.jsx)("p",{className:"mt-1 text-xs text-danger",children:O.pathPrefix})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("label",{htmlFor:"targetPort",className:"block text-sm font-medium text-foreground mb-1",children:[l("form.portNumber")," ",(0,a.jsx)("span",{className:"text-danger",children:"*"})]}),(0,a.jsx)(d.pd,{id:"targetPort",type:"number",value:v,onChange:e=>k(e.target.value?parseInt(e.target.value,10):""),className:"font-mono ".concat(O.targetPort?"border-danger":""),placeholder:l("form.portNumberPlaceholder"),min:x.MIN,max:x.MAX,disabled:$}),(0,a.jsx)("p",{className:"mt-1 text-xs text-muted-foreground",children:l("form.portNumberHelp",{min:x.MIN,max:x.MAX})}),O.targetPort&&(0,a.jsx)("p",{className:"mt-1 text-xs text-danger",children:O.targetPort})]}),!m&&(0,a.jsxs)("div",{children:[(0,a.jsxs)("label",{htmlFor:"appType",className:"block text-sm font-medium text-foreground mb-1",children:[l("form.appType")," ",(0,a.jsx)("span",{className:"text-danger",children:"*"})]}),(0,a.jsxs)("select",{id:"appType",value:w,onChange:e=>C(e.target.value),className:(0,p.cn)((0,d.j1)(),O.appType&&"border-danger"),disabled:$,children:[(0,a.jsx)("option",{value:"",children:l("form.appTypePlaceholder")}),f.map(e=>(0,a.jsx)("option",{value:e.value,children:e.label},e.value))]}),O.appType&&(0,a.jsx)("p",{className:"mt-1 text-xs text-danger",children:O.appType})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{htmlFor:"description",className:"block text-sm font-medium text-foreground mb-1",children:l("form.description")}),(0,a.jsx)(d.k_,{id:"description",value:A,onChange:e=>T(e.target.value),placeholder:l("form.descriptionPlaceholder"),rows:2,disabled:$})]}),(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(d.dO,{id:"websocketEnabled",checked:S,onCheckedChange:P,disabled:$}),(0,a.jsx)("label",{htmlFor:"websocketEnabled",className:"text-sm text-foreground",children:l("form.websocketLabel")})]}),m&&(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(d.dO,{id:"enabled",checked:E,onCheckedChange:M,disabled:$}),(0,a.jsx)("label",{htmlFor:"enabled",className:"text-sm text-foreground",children:l("form.enabledLabel")})]}),D&&(0,a.jsx)("div",{className:"p-3 bg-danger-subtle border border-danger-border rounded text-sm text-danger-foreground",children:D}),(0,a.jsxs)("div",{className:"flex justify-end gap-2 pt-4 border-t border-border",children:[(0,a.jsx)(d.$n,{type:"button",variant:"ghost",onClick:s,disabled:$,children:c("cancel")}),(0,a.jsx)(d.$n,{type:"submit",variant:"primary",loading:$,children:m?l("form.save"):l("form.add")})]})]})})}function b(){let e=(0,i.c)("externalApps"),t=(0,i.c)("common"),[s,r]=(0,o.useState)([]),[n,l]=(0,o.useState)(!0),[c,p]=(0,o.useState)(null),[x,u]=(0,o.useState)(!1),[h,f]=(0,o.useState)(null),b=(0,o.useCallback)(async()=>{try{p(null);let e=await fetch("/api/external-apps");if(!e.ok)throw Error("Failed to fetch external apps");let t=await e.json();r(t.apps||[])}catch(e){p(e instanceof Error?e.message:"An error occurred")}finally{l(!1)}},[]);(0,o.useEffect)(()=>{b();let e=setInterval(b,6e4);return()=>clearInterval(e)},[b]);let j=(0,o.useCallback)(e=>{f(e),u(!0)},[]),y=(0,o.useCallback)(()=>{f(null),u(!0)},[]),N=(0,o.useCallback)(async e=>{try{let t=await fetch("/api/external-apps/".concat(e),{method:"DELETE"});if(!t.ok){let e=await t.json();throw Error(e.error||"Failed to delete app")}b()}catch(e){console.error("Failed to delete app:",e)}},[b]),v=(0,o.useCallback)(()=>{b()},[b]),k=(0,o.useCallback)(()=>{u(!1),f(null)},[]);return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)("div",{className:"flex items-center justify-end",children:(0,a.jsx)(d.$n,{variant:"primary",size:"sm",onClick:y,children:e("manager.addApp")})}),n?(0,a.jsx)(d.Zp,{padding:"lg",children:(0,a.jsxs)("div",{className:"flex items-center justify-center py-8",children:[(0,a.jsx)(d.y$,{size:"xl",variant:"accent"}),(0,a.jsx)("span",{className:"ml-3 text-muted-foreground",children:e("manager.loading")})]})}):c?(0,a.jsx)(d.Zp,{padding:"lg",children:(0,a.jsxs)("div",{className:"text-center py-8",children:[(0,a.jsx)("p",{className:"text-danger-foreground mb-4",children:e("manager.loadError")}),(0,a.jsx)(d.$n,{variant:"secondary",size:"sm",onClick:b,children:t("retry")})]})}):0===s.length?(0,a.jsx)(d.Zp,{padding:"lg",children:(0,a.jsxs)("div",{className:"text-center py-8",children:[(0,a.jsx)("p",{className:"text-muted-foreground mb-4",children:e("manager.empty")}),(0,a.jsx)("p",{className:"text-sm text-muted-foreground mb-4",children:e("manager.emptyHelp")}),(0,a.jsx)(d.$n,{variant:"primary",size:"sm",onClick:y,children:e("manager.addFirst")})]})}):(0,a.jsx)("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-4",children:s.map(e=>(0,a.jsx)(m,{app:e,onEdit:j,onDelete:N},e.id))}),(0,a.jsx)(g,{isOpen:x,onClose:k,editApp:h,onSave:v})]})}let j=(0,s(71847).A)("bell",[["path",{d:"M10.268 21a2 2 0 0 0 3.464 0",key:"vwvbt9"}],["path",{d:"M3.262 15.326A1 1 0 0 0 4 17h16a1 1 0 0 0 .74-1.673C19.41 13.956 18 12.499 18 8A6 6 0 0 0 6 8c0 4.499-1.411 5.956-2.738 7.326",key:"11g9vi"}]]);var y=s(94442),N=s(81978);function v(){return"undefined"!=typeof navigator&&"serviceWorker"in navigator&&"PushManager"in window&&"Notification"in window}let k={enabled:!0,thresholdMinutes:10},w=[5,10,30,60];function C(){let e=(0,i.c)("notifications"),{showToast:t}=(0,y.dj)(),[s,r]=(0,o.useState)(!0),[n,l]=(0,o.useState)(!1),[c,m]=(0,o.useState)(!0),[p,x]=(0,o.useState)(!1),[u,h]=(0,o.useState)(null),[f,g]=(0,o.useState)(null),[b,N]=(0,o.useState)(!1),[k,w]=(0,o.useState)(null),[C,A]=(0,o.useState)({prompt:!0,completion:!1}),[T,E]=(0,o.useState)(!1),[M,O]=(0,o.useState)(null),[I,$]=(0,o.useState)(null),F=null!==k&&!1!==I;(0,o.useEffect)(()=>{let e=!1;return(async()=>{let t=function(){var e,t;let s=v(),a="undefined"!=typeof navigator&&(!!/iPad|iPhone|iPod/.test(navigator.userAgent)||"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1)&&!(null!=(e=(t=window).matchMedia)&&e.call(t,"(display-mode: standalone)").matches||!0===navigator.standalone);return{supported:s&&!a,iosNeedsInstall:a}}();e||(m(v()),x(t.iosNeedsInstall),"undefined"!=typeof Notification&&"denied"===Notification.permission&&N(!0));try{let t=await fetch("/api/push/vapid"),s=await t.json();e||(h(s.configured),g(s.publicKey))}catch(t){e||h(!1)}if(v())try{let t=await navigator.serviceWorker.getRegistration(),a=t?await t.pushManager.getSubscription():null;if(a&&!e){w(a.endpoint);let t=await fetch("/api/push/subscriptions?endpoint=".concat(encodeURIComponent(a.endpoint))),r=await t.json();if(!e){var s;$(!0===r.subscribed),O(null!=(s=r.delivery)?s:null)}r.subscribed&&r.subscription&&!e&&(A(r.subscription.preferences),E(!0===r.subscription.defaultsNoticePending))}}catch(e){}e||r(!1)})(),()=>{e=!0}},[]);let D=(0,o.useCallback)(async()=>{if(f){l(!0);try{var s,a;let r=await Notification.requestPermission();if("granted"!==r){N("denied"===r),t(e("toast.error"),"error");return}if(!await navigator.serviceWorker.getRegistration())return void t(e("toast.error"),"error");let n=await navigator.serviceWorker.ready,i=await n.pushManager.subscribe({userVisibleOnly:!0,applicationServerKey:function(e){let t="=".repeat((4-e.length%4)%4),s=atob((e+t).replace(/-/g,"+").replace(/_/g,"/")),a=new Uint8Array(new ArrayBuffer(s.length));for(let e=0;e<s.length;e++)a[e]=s.charCodeAt(e);return a}(f)}),l=await fetch("/api/push/subscriptions",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({subscription:i.toJSON(),deviceLabel:navigator.userAgent.slice(0,120)})});if(!l.ok)throw Error("subscribe request failed");let d=await l.json();w(i.endpoint),$(!0),O(null),(null==(s=d.subscription)?void 0:s.preferences)&&A(d.subscription.preferences),E((null==(a=d.subscription)?void 0:a.defaultsNoticePending)===!0),N(!1),t(e("toast.enabled"),"success")}catch(s){t(e("toast.error"),"error")}finally{l(!1)}}},[f,t,e]),z=(0,o.useCallback)(async()=>{l(!0);try{var s;let a=await navigator.serviceWorker.getRegistration(),r=a?await a.pushManager.getSubscription():null,n=null!=(s=null==r?void 0:r.endpoint)?s:k;r&&await r.unsubscribe(),n&&await fetch("/api/push/subscriptions",{method:"DELETE",headers:{"Content-Type":"application/json"},body:JSON.stringify({endpoint:n})}),w(null),$(null),O(null),t(e("toast.disabled"),"info")}catch(s){t(e("toast.error"),"error")}finally{l(!1)}},[k,t,e]),Z=(0,o.useCallback)(async(s,a)=>{if(!k)return;let r={...C,[s]:a};A(r);try{if(!(await fetch("/api/push/subscriptions",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({endpoint:k,preferences:r})})).ok)throw Error("update failed");t(e("toast.updated"),"success")}catch(s){A(C),t(e("toast.error"),"error")}},[k,C,t,e]),q=(0,o.useCallback)(async s=>{if(!k)return;let a=s?{...C,completion:!1}:C;E(!1),s&&A(a),l(!0);try{if(!(await fetch("/api/push/subscriptions",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({endpoint:k,...s?{preferences:a}:{},acknowledgeDefaultsNotice:!0})})).ok)throw Error("acknowledge failed");t(e(s?"defaultsNotice.adopted":"defaultsNotice.kept"),"success")}catch(s){A(C),E(!0),t(e("toast.error"),"error")}finally{l(!1)}},[k,C,t,e]);return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)(d.Zp,{children:(0,a.jsx)(P,{})}),(0,a.jsx)(d.Zp,{children:s?(0,a.jsx)("div",{className:"flex items-center gap-2 text-sm text-muted-foreground",children:(0,a.jsx)(d.y$,{size:"sm"})}):c?p?(0,a.jsx)("p",{className:"text-sm text-muted-foreground","data-testid":"notifications-ios-guidance",children:e("ios.guidance")}):!1===u?(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:e("notConfigured")}):(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:e("description")}),b&&(0,a.jsx)("p",{className:"text-sm text-danger-foreground","data-testid":"notifications-permission-denied",children:e("permission.denied")}),(()=>{if(null===M)return null;let t="removed"===M.state,s=M.statusCode,r=t?null===s?e("delivery.removedUnknownStatus"):e("delivery.removed",{status:String(s)}):null===s?e("delivery.failingUnknownStatus",{count:M.failureCount}):e("delivery.failing",{count:M.failureCount,status:String(s)});return(0,a.jsxs)("div",{className:t?"space-y-2 rounded-lg border border-danger-border bg-danger-subtle p-3":"space-y-2 rounded-lg border border-warning-border bg-warning-subtle p-3","data-testid":"notifications-delivery-health","data-delivery-state":M.state,children:[(0,a.jsx)("p",{className:t?"text-sm font-semibold text-danger-foreground":"text-sm font-semibold text-warning-foreground",children:e(t?"delivery.headingRemoved":"delivery.headingFailing")}),(0,a.jsx)("p",{className:"text-xs text-foreground",children:r}),403===s&&(0,a.jsx)("p",{className:"text-xs text-muted-foreground","data-testid":"notifications-delivery-apns-hint",children:e("delivery.apnsHint")}),(0,a.jsx)("p",{className:"text-xs text-muted-foreground",children:e("delivery.since",{timestamp:new Date(M.firstFailureAt).toLocaleString()})})]})})(),F?(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)("p",{className:"text-sm font-medium text-foreground",children:e("enabledOnThisDevice")}),T&&(0,a.jsxs)("div",{className:"space-y-3 rounded-lg border border-info-border bg-info-subtle p-3","data-testid":"notifications-defaults-notice",children:[(0,a.jsx)("p",{className:"text-sm font-semibold text-info-foreground",children:e("defaultsNotice.heading")}),(0,a.jsx)("p",{className:"text-xs text-foreground",children:e("defaultsNotice.completionChanged")}),(0,a.jsx)("p",{className:"text-xs text-foreground",children:e("defaultsNotice.failuresAdded")}),(0,a.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,a.jsx)(d.$n,{variant:"primary",onClick:()=>q(!0),disabled:n,"data-testid":"notifications-defaults-notice-adopt",children:e("defaultsNotice.adopt")}),(0,a.jsx)(d.$n,{variant:"secondary",onClick:()=>q(!1),disabled:n,"data-testid":"notifications-defaults-notice-keep",children:e("defaultsNotice.keep")})]})]}),(0,a.jsxs)("div",{className:"space-y-3",children:[(0,a.jsx)("div",{className:"text-xs font-medium uppercase tracking-wide text-muted-foreground",children:e("types.heading")}),(0,a.jsxs)("label",{className:"flex items-center justify-between gap-4",children:[(0,a.jsxs)("span",{children:[(0,a.jsx)("span",{className:"block text-sm font-medium text-foreground",children:e("types.promptWaiting")}),(0,a.jsx)("span",{className:"block text-xs text-muted-foreground",children:e("types.promptWaitingDesc")})]}),(0,a.jsx)(d.dO,{checked:C.prompt,onCheckedChange:e=>Z("prompt",e),disabled:n,"aria-label":e("types.promptWaiting"),"data-testid":"notifications-toggle-prompt"})]}),(0,a.jsxs)("label",{className:"flex items-center justify-between gap-4",children:[(0,a.jsxs)("span",{children:[(0,a.jsx)("span",{className:"block text-sm font-medium text-foreground",children:e("types.completion")}),(0,a.jsx)("span",{className:"block text-xs text-muted-foreground",children:e("types.completionDesc")})]}),(0,a.jsx)(d.dO,{checked:C.completion,onCheckedChange:e=>Z("completion",e),disabled:n,"aria-label":e("types.completion"),"data-testid":"notifications-toggle-completion"})]})]}),(0,a.jsx)(d.$n,{variant:"secondary",onClick:z,disabled:n,"data-testid":"notifications-unsubscribe",children:e("unsubscribe")})]}):(0,a.jsxs)(d.$n,{variant:"primary",onClick:D,disabled:n||b||!f,"data-testid":"notifications-enable",children:[(0,a.jsx)(j,{className:"h-4 w-4"}),n?e("enabling"):e("enable")]})]}):(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:e("unsupported")})}),(0,a.jsx)(d.Zp,{children:(0,a.jsx)(S,{})})]})}function S(){let e=(0,i.c)("notifications"),{showToast:t}=(0,y.dj)(),[s,r]=(0,o.useState)(!0),[n,l]=(0,o.useState)(!1),[c,m]=(0,o.useState)(k),[p,x]=(0,o.useState)([...w]);(0,o.useEffect)(()=>{let e=!1;return(async()=>{try{let t=await fetch("/api/push/escalation"),s=await t.json();!e&&(s.settings&&m(s.settings),Array.isArray(s.choices)&&s.choices.length>0&&x(s.choices))}catch(e){}finally{e||r(!1)}})(),()=>{e=!0}},[]);let u=(0,o.useCallback)(async s=>{m(s),l(!0);try{if(!(await fetch("/api/push/escalation",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({settings:s})})).ok)throw Error("update failed");t(e("toast.updated"),"success")}catch(s){m(c),t(e("toast.error"),"error")}finally{l(!1)}},[c,t,e]);return(0,a.jsxs)("div",{className:"space-y-3",children:[(0,a.jsx)("div",{className:"text-xs font-medium uppercase tracking-wide text-muted-foreground",children:e("escalation.heading")}),(0,a.jsxs)("label",{className:"flex items-center justify-between gap-4",children:[(0,a.jsxs)("span",{children:[(0,a.jsx)("span",{className:"block text-sm font-medium text-foreground",children:e("escalation.toggle")}),(0,a.jsx)("span",{className:"block text-xs text-muted-foreground",children:e("escalation.toggleDesc")})]}),(0,a.jsx)(d.dO,{checked:c.enabled,onCheckedChange:e=>u({...c,enabled:e}),disabled:s||n,"aria-label":e("escalation.toggle"),"data-testid":"notifications-toggle-escalation"})]}),(0,a.jsxs)("label",{className:"flex items-center justify-between gap-4",children:[(0,a.jsx)("span",{className:"text-sm text-foreground",children:e("escalation.threshold")}),(0,a.jsx)("select",{className:"rounded-md border border-border bg-background px-2 py-1 text-sm text-foreground",value:String(c.thresholdMinutes),disabled:s||n||!c.enabled,"aria-label":e("escalation.threshold"),"data-testid":"notifications-escalation-threshold",onChange:e=>u({...c,thresholdMinutes:Number(e.target.value)}),children:p.map(t=>(0,a.jsx)("option",{value:String(t),children:e("escalation.minutes",{count:t})},t))})]})]})}function P(){let e=(0,i.c)("notifications"),{enabled:t,setEnabled:s}=(0,N.qG)(),{enabled:r,setEnabled:n}=(0,N.Ql)();return(0,a.jsxs)("div",{className:"space-y-3",children:[(0,a.jsx)("div",{className:"text-xs font-medium uppercase tracking-wide text-muted-foreground",children:e("inApp.heading")}),(0,a.jsxs)("label",{className:"flex items-center justify-between gap-4",children:[(0,a.jsxs)("span",{children:[(0,a.jsx)("span",{className:"block text-sm font-medium text-foreground",children:e("inApp.waitingToggle")}),(0,a.jsx)("span",{className:"block text-xs text-muted-foreground",children:e("inApp.waitingToggleDesc")})]}),(0,a.jsx)(d.dO,{checked:t,onCheckedChange:s,"aria-label":e("inApp.waitingToggle"),"data-testid":"notifications-toggle-inapp-waiting"})]}),(0,a.jsxs)("label",{className:"flex items-center justify-between gap-4",children:[(0,a.jsxs)("span",{children:[(0,a.jsx)("span",{className:"block text-sm font-medium text-foreground",children:e("inApp.soundToggle")}),(0,a.jsx)("span",{className:"block text-xs text-muted-foreground",children:e("inApp.soundToggleDesc")})]}),(0,a.jsx)(d.dO,{checked:r,onCheckedChange:n,"aria-label":e("inApp.soundToggle"),"data-testid":"notifications-toggle-inapp-sound"})]})]})}s(72604),s(95275),s(79832);var A=s(46022);function T(){let e=(0,i.c)("notifications"),t=(0,i.c)("common"),s=(0,i.c)("skills");return(0,a.jsx)(l.GV,{children:(0,a.jsxs)("div",{className:"container-custom py-8 overflow-auto h-full",children:[(0,a.jsxs)("div",{className:"mb-6",children:[(0,a.jsx)("h1",{className:"text-2xl font-bold text-foreground mb-2",children:"More"}),(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:"Settings, external apps, and more."})]}),(0,a.jsxs)("div",{className:"mb-8",children:[(0,a.jsx)("h2",{className:"text-lg font-semibold mb-4 text-foreground",children:"Quick Links"}),(0,a.jsxs)("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:[(0,a.jsx)(n(),{href:"/repositories",className:"block","data-testid":"more-link-repositories",children:(0,a.jsxs)(d.Zp,{hover:!0,className:"transition-colors hover:border-accent-300 dark:hover:border-accent-700",children:[(0,a.jsx)("div",{className:"text-sm font-medium text-foreground",children:"Repositories"}),(0,a.jsx)("div",{className:"text-xs text-muted-foreground",children:"Manage repositories and worktrees"})]})}),(0,a.jsx)(n(),{href:"/skills",className:"block","data-testid":"more-link-skills",children:(0,a.jsxs)(d.Zp,{hover:!0,className:"transition-colors hover:border-accent-300 dark:hover:border-accent-700",children:[(0,a.jsx)("div",{className:"text-sm font-medium text-foreground",children:t("nav.skills")}),(0,a.jsx)("div",{className:"text-xs text-muted-foreground",children:s("page.description")})]})}),(0,a.jsx)(n(),{href:"/skills/installed",className:"block","data-testid":"more-link-skills-installed",children:(0,a.jsxs)(d.Zp,{hover:!0,className:"transition-colors hover:border-accent-300 dark:hover:border-accent-700",children:[(0,a.jsx)("div",{className:"text-sm font-medium text-foreground",children:s("dashboard.title")}),(0,a.jsx)("div",{className:"text-xs text-muted-foreground",children:s("dashboard.description")})]})})]})]}),(0,a.jsxs)("div",{className:"mb-8",children:[(0,a.jsx)("h2",{className:"text-lg font-semibold mb-4 text-foreground",children:t("settings.title")}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)(A.he,{}),(0,a.jsx)(A.$8,{}),(0,a.jsx)(A.uN,{})]})]}),(0,a.jsxs)("div",{className:"mb-8",children:[(0,a.jsx)("h2",{className:"text-lg font-semibold mb-4 text-foreground",children:e("title")}),(0,a.jsx)(C,{})]}),(0,a.jsxs)("div",{className:"mb-8",children:[(0,a.jsx)("h2",{className:"text-lg font-semibold mb-4 text-foreground",children:"External Apps"}),(0,a.jsx)(b,{})]}),(0,a.jsxs)("div",{className:"mb-8",children:[(0,a.jsx)("h2",{className:"text-lg font-semibold mb-4 text-foreground",children:"About"}),(0,a.jsx)(d.Zp,{children:(0,a.jsx)("div",{className:"text-sm text-muted-foreground",children:"CommandMate - A local control plane for agent CLIs."})})]})]})})}}},e=>{e.O(0,[6809,4909,2770,790,5694,2407,6402,8019,4718,4388,6022,4322,8441,1255,7358],()=>e(e.s=80867)),_N_E=e.O()}]);
@@ -0,0 +1 @@
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8898],{6473:(e,t,s)=>{"use strict";s.d(t,{Lc:()=>a,qz:()=>n});let n="animate-in fade-in-0 slide-in-from-bottom-2 fill-mode-backwards duration-300";function a(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:40,s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:10;if(Number.isFinite(e)&&!(e<=0)&&!(e>=s))return"".concat(e*t,"ms")}},9219:(e,t,s)=>{"use strict";s.d(t,{k:()=>l});var n=s(95155),a=s(12115),r=s(28019),i=s(87531);function l(e){let{onRefresh:t,enabled:s=!0,className:l,children:o}=e,{containerRef:c,pullDistance:d,isRefreshing:u,isPulling:m}=function(e){let{onRefresh:t,enabled:s=!0,threshold:n=64,maxPull:r=96,resistance:i=.5}=e,l=(0,a.useRef)(null),[o,c]=(0,a.useState)(0),[d,u]=(0,a.useState)(!1),[m,x]=(0,a.useState)(!1),h=(0,a.useRef)(null),f=(0,a.useRef)(0),g=(0,a.useRef)(!1);g.current=d;let p=(0,a.useCallback)(()=>{h.current=null,f.current=0,c(0),x(!1)},[]),b=(0,a.useCallback)(e=>{if(!s||g.current)return;let t=l.current;t&&!(t.scrollTop>0)&&(h.current=e.touches[0].clientY,f.current=0)},[s]),v=(0,a.useCallback)(e=>{if(null===h.current)return;let t=l.current;if(!t)return;if(t.scrollTop>0)return void p();let s=e.touches[0].clientY-h.current;if(s<=0){0!==f.current&&(f.current=0,c(0),x(!1));return}e.cancelable&&e.preventDefault();let n=Math.min(s*i,r);f.current=n,c(n),x(!0)},[i,r,p]),y=(0,a.useCallback)(async()=>{u(!0),x(!1),c(n);try{await Promise.resolve(t())}finally{u(!1),c(0)}},[t,n]),w=(0,a.useCallback)(()=>{if(null===h.current)return;let e=f.current>=n&&!g.current;h.current=null,f.current=0,e?y():(c(0),x(!1))},[n,y]);return(0,a.useEffect)(()=>{let e=l.current;if(e)return e.addEventListener("touchstart",b,{passive:!0}),e.addEventListener("touchmove",v,{passive:!1}),e.addEventListener("touchend",w,{passive:!0}),e.addEventListener("touchcancel",w,{passive:!0}),()=>{e.removeEventListener("touchstart",b),e.removeEventListener("touchmove",v),e.removeEventListener("touchend",w),e.removeEventListener("touchcancel",w)}},[b,v,w]),{containerRef:l,pullDistance:o,isRefreshing:d,isPulling:m}}({onRefresh:t,enabled:s,threshold:64}),x=u||d>0,h=u?1:Math.min(d/64,1);return(0,n.jsxs)("div",{ref:c,className:(0,i.cn)("relative overflow-auto",l),style:{overscrollBehaviorY:"contain"},"data-testid":"pull-to-refresh",children:[(0,n.jsx)("div",{className:"pointer-events-none absolute inset-x-0 top-0 z-10 flex justify-center",style:{transform:"translateY(".concat(x?Math.max(d-24,8):-32,"px)"),opacity:h,transition:m?"none":"transform 0.2s ease-out, opacity 0.2s ease-out"},"data-testid":"pull-to-refresh-indicator",role:"status","aria-hidden":!u,children:(0,n.jsx)(r.y$,{size:"sm",variant:"accent"})}),(0,n.jsx)("div",{style:{transform:x?"translateY(".concat(d,"px)"):void 0,transition:m?"none":"transform 0.2s ease-out"},children:o})]})}},62147:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>eo});var n=s(95155),a=s(12115),r=s(52619),i=s.n(r),l=s(18955),o=s(20562),c=s(8803),d=s(54388),u=s(9219),m=s(37586),x=s(22479),h=s(54485),f=s(84228),g=s(83051),p=s(14006),b=s(73333),v=s(2954),y=s(28019),w=s(62560),j=s(308),k=s(80635),N=s(52407);function A(){let{signals:e}=(0,N.Fx)();return(0,a.useMemo)(()=>({offline:(0,N.sV)(e),reachable:(0,N._X)(e)}),[e])}var C=s(66966);let M=Object.freeze({enabled:!1,expiresAt:null});var S=s(81507),L=s(2317),I=s(75676),E=s(80344),P=s(38606),T=s(54014),R=s(55449),_=s(67149),z=s(68394);let D=[{mode:"chat",labelKey:"surfaceMode.showChat",icon:m.A},{mode:"terminal",labelKey:"surfaceMode.showTerminal",icon:x.A}];function F(e){return"flex h-7 w-7 shrink-0 items-center justify-center rounded transition-colors focus:outline-none focus-visible:ring-2 focus-visible:ring-ring ".concat(e?"bg-accent-500/15 text-accent-600 dark:text-accent-400":"text-muted-foreground hover:bg-muted hover:text-foreground")}let U=()=>{},K=(0,a.memo)(function(e){return e.connectivity?(0,n.jsx)(B,{...e,connectivity:e.connectivity}):(0,n.jsx)(O,{...e})});function O(e){let t=A();return(0,n.jsx)(B,{...e,connectivity:t})}function B(e){var t,s,r,o,c,d,u;let{worktree:m,enabled:x,connectivity:N,className:A=""}=e,K=(0,l.c)("common"),O=(0,l.c)("worktree"),B=(0,a.useMemo)(()=>{var e;return m.agentInstances&&m.agentInstances.length>0?m.agentInstances:(0,T.lu)(null!=(e=m.selectedAgents)?e:(0,R.sA)())},[m]),[V,Y]=(0,a.useState)(null),q=null!=(s=B.find(e=>e.id===V))?s:B[0],H=null==q?void 0:q.id,W=null!=(r=null==q?void 0:q.cliTool)?r:"claude",G=null!=H?H:W,{surfaceMode:J,setSurfaceMode:Q}=function(e){let{value:t,setValue:s}=(0,L.V)({key:"".concat("commandmate.sessions.tileSurfaceMode-").concat(e),defaultValue:"chat",validate:I.jg,serialize:e=>e,deserialize:e=>e});return{surfaceMode:t,setSurfaceMode:(0,a.useCallback)(e=>s(e),[s])}}(m.id),{visible:X,toggle:$}=(0,S.TG)(S.jt),Z="terminal"===J,ee=Z&&X,{terminal:et,prompt:es,refresh:en,setAutoScroll:ea}=(0,w.NK)({worktreeId:m.id,cliToolId:W,instanceId:H,enabled:x,cadence:_.sD}),{messages:er,isLoading:ei,refresh:el}=(0,j.Md)({worktreeId:m.id,cliToolId:W,instanceId:H,enabled:x&&(!Z||X),cadence:_.WT}),eo=(0,a.useCallback)((e,t)=>E.y.sendMessage(m.id,e,t),[m.id]),{messages:ec,sendOptimistic:ed,retry:eu,discard:em}=(0,k.v4)({worktreeId:m.id,serverMessages:er,sendFn:eo,onSent:el,connectivity:N}),ex=(0,a.useMemo)(()=>(function(e,t){let s=e=>{var s;return void 0!==e.optimisticState&&(null!=(s=e.instanceId)?s:e.cliToolId)!==t};return e.some(s)?e.filter(e=>!s(e)):e})(ec,G),[ec,G]),[eh,ef]=(0,a.useState)(null),eg=(0,a.useCallback)(()=>ef(null),[]),ep=(0,a.useCallback)(e=>{let t=em(e);t&&ef(t)},[em]),eb=(0,a.useCallback)(()=>{en()},[en]),ev=function(e){var t;let{worktree:s,cliToolId:n,instanceId:r}=e,i=null==(t=(0,C.rC)())?void 0:t.refresh,l=s.id,o=(0,a.useMemo)(()=>(function(e,t){var s;let n=null==(s=e.autoYesByInstance)?void 0:s[t];return n&&!0===n.enabled?{enabled:!0,expiresAt:"number"==typeof n.expiresAt?n.expiresAt:null}:M})(s,r),[s,r]),[c,d]=(0,a.useState)(null),u=(0,a.useRef)(s);u.current=s;let m=null===c||c.instanceId!==r||function(e,t,s){let n=t.enabled===e.value.enabled&&(!t.enabled||t.expiresAt===e.value.expiresAt),a=null!==e.settledRow&&s!==e.settledRow;return n||a}(c,o,s)?null:c;(0,a.useEffect)(()=>{null!==c&&null===m&&d(null)},[c,m]);let x=(0,a.useCallback)(async e=>{let t;try{let s=await fetch("/api/worktrees/".concat(encodeURIComponent(l),"/auto-yes"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({enabled:e.enabled,cliToolId:n,instanceId:r,duration:e.duration,stopPattern:e.stopPattern})});if(!s.ok)return;let a=await s.json(),i=!0===a.enabled;t={enabled:i,expiresAt:i&&"number"==typeof a.expiresAt?a.expiresAt:null}}catch(e){return}let s={instanceId:r,value:t,settledRow:null};d(s);try{await (null==i?void 0:i())}catch(e){}d(e=>e===s?{...s,settledRow:u.current}:e)},[l,n,r,i]),h=m?m.value:o;return{enabled:h.enabled,expiresAt:h.expiresAt,toggle:x}}({worktree:m,cliToolId:W,instanceId:G}),ey=(0,a.useMemo)(()=>({isRunning:et.isRunning,attaching:et.attaching,sessionStatus:et.sessionStatus,isThinking:et.isThinking,isPromptWaiting:es.visible,promptData:es.data,isSelectionListActive:et.isSelectionListActive,isPagerActive:et.isPagerActive,isDismissablePanelActive:et.isDismissablePanelActive,isUnclassifiedActive:et.isUnclassifiedActive}),[et.isRunning,et.attaching,et.sessionStatus,et.isThinking,et.isSelectionListActive,et.isPagerActive,et.isDismissablePanelActive,et.isUnclassifiedActive,es.visible,es.data]),ew=(0,a.useCallback)(e=>Q(e),[Q]),ej=(0,a.useMemo)(()=>({isLoading:ei,onRetryPending:eu,onDiscardPending:ep,onInsertToMessage:ef}),[ei,eu,ep]),{compactTuiLayoutPadding:ek,preservePaintedPanelRows:eN}=(0,a.useMemo)(()=>(0,z.EK)(W),[W]),eA="opencode"===W||"copilot"===W,eC=(u=m.id,"session-tile-history-".concat(u)),eM=(0,a.useCallback)(e=>{Y(e.target.value)},[]),eS=null!=(o=m.branch)?o:m.name,eL=null!=(c=m.repositoryDisplayName)?c:m.repositoryName,eI=(0,P.kA)(H?null==(t=m.sessionStatusByInstance)?void 0:t[H]:void 0);return(0,n.jsxs)("section",{className:"flex h-full min-w-0 flex-col overflow-hidden rounded-lg border border-border bg-surface shadow-sm ".concat(A),"data-testid":"session-tile-".concat(m.id),"data-enabled":x?"true":"false","aria-label":K("sessions.tileAriaLabel",{branch:eS}),children:[(0,n.jsxs)("header",{className:"flex shrink-0 items-center gap-2 border-b border-border px-3 py-2",children:[(0,n.jsx)(y.md,{status:eI,size:"sm",label:K("status.".concat(eI))}),(0,n.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,n.jsx)("div",{className:"truncate text-xs text-muted-foreground",children:eL}),(0,n.jsx)(i(),{href:"/worktrees/".concat(m.id),className:"block truncate text-sm font-medium text-foreground underline-offset-2 hover:text-accent-600 hover:underline focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring dark:hover:text-accent-400","data-testid":"session-tile-branch-".concat(m.id),title:eS,children:eS})]}),B.length>1&&(0,n.jsx)("select",{value:null!=(d=null==q?void 0:q.id)?d:"",onChange:eM,className:"max-w-[9rem] shrink-0 rounded-md border border-border bg-surface px-2 py-1 text-xs text-muted-foreground transition-colors hover:text-foreground focus:outline-none focus:ring-2 focus:ring-ring","data-testid":"session-tile-instance-".concat(m.id),"aria-label":K("sessions.tileInstanceAriaLabel"),children:B.map(e=>(0,n.jsx)("option",{value:e.id,children:(0,T.sw)(e)},e.id))}),Z&&(0,n.jsx)("button",{type:"button",onClick:$,"aria-pressed":X,"aria-expanded":X,"aria-controls":eC,"aria-label":X?O("terminal.hideHistory"):O("terminal.showHistory"),title:X?O("terminal.hideHistory"):O("terminal.showHistory"),className:F(X),"data-testid":"session-tile-history-toggle-".concat(m.id),children:(0,n.jsx)(h.A,{size:14,"aria-hidden":"true"})}),(0,n.jsx)("div",{role:"group","aria-label":O("surfaceMode.groupLabelMobile"),className:"flex shrink-0 items-center gap-0.5 rounded-md border border-border p-0.5","data-testid":"session-tile-surface-mode-".concat(m.id),children:D.map(e=>{let{mode:t,labelKey:s,icon:a}=e,r=J===t,i=O(s);return(0,n.jsx)("button",{type:"button",onClick:()=>Q(t),"aria-pressed":r,"aria-label":i,title:i,className:F(r),"data-testid":"session-tile-surface-".concat(t,"-").concat(m.id),children:(0,n.jsx)(a,{size:14,"aria-hidden":"true"})},t)})})]}),(0,n.jsx)("div",{className:"min-w-0 flex-1 overflow-hidden ".concat("min-h-[15rem]"),"data-testid":"session-tile-body-".concat(m.id),children:x&&Z?(0,n.jsxs)("div",{className:"flex h-full min-h-0 min-w-0 flex-col","data-testid":"session-tile-terminal-stack-".concat(m.id),children:[(0,n.jsx)("div",{className:"relative min-w-0 overflow-hidden ".concat(ee?"flex-[3_3_0%] min-h-[8.5rem]":"min-h-0 flex-1"),"data-testid":"session-tile-terminal-".concat(m.id),children:(0,n.jsx)(p.D,{output:et.output,isActive:et.isRunning,attaching:et.attaching,isThinking:et.isThinking,autoScroll:et.autoScroll,onScrollChange:ea,disableAutoFollow:eA,compactTuiLayoutPadding:ek,preservePaintedPanelRows:eN,wrapMode:z.Wq.wrapMode,density:z.Wq.density})}),ee&&(0,n.jsx)("div",{id:eC,className:"min-w-0 overflow-hidden border-t border-border ".concat("flex-[2_2_0%] min-h-[6.5rem]"),"data-testid":"session-tile-history-".concat(m.id),children:(0,n.jsx)(g.bl,{messages:ex,worktreeId:m.id,worktreePath:m.path,cliToolId:W,isLoading:ei,onFilePathClick:U,onInsertToMessage:ef,onRetryPending:eu,onDiscardPending:ep,className:"h-full"})})]}):x?(0,n.jsx)(f.wY,{messages:ex,worktreeId:m.id,worktreePath:m.path,cliToolId:W,instanceId:H,live:ey,frame:et.output,onKeysSent:en,onSurfaceModeChange:ew,compact:!0,history:ej}):(0,n.jsx)("div",{className:"h-full","data-testid":"session-tile-placeholder-".concat(m.id),"aria-hidden":"true"})}),x&&(0,n.jsx)("div",{className:"shrink-0 border-t border-border p-2","data-testid":"session-tile-composer-".concat(m.id),children:(0,n.jsx)(b.E,{worktreeId:m.id,cliToolId:W,instanceId:G,isSessionRunning:et.isRunning,onOptimisticSend:ed,onMessageSent:eb,pendingInsertText:eh,onInsertConsumed:eg,autoYesSlot:(0,n.jsx)(v.T,{enabled:ev.enabled,expiresAt:ev.expiresAt,onToggle:ev.toggle,lastAutoResponse:null,cliToolName:W,inline:!0})})})]})}let V=(0,a.memo)(function(e){let{worktree:t,connectivity:s}=e,{ref:r,inViewport:i}=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{rootMargin:t,threshold:s}=e,[n,r]=(0,a.useState)(!1),[i,l]=(0,a.useState)(null),o=(0,a.useCallback)(e=>{l(e)},[]);return(0,a.useEffect)(()=>{if("undefined"==typeof IntersectionObserver)return void r(!0);if(!i)return;let e=new IntersectionObserver(e=>{let t=e[e.length-1];t&&r(t.isIntersecting)},{rootMargin:t,threshold:s});return e.observe(i),()=>e.disconnect()},[i,t,s]),{ref:o,inViewport:n}}({rootMargin:"560px"});return(0,n.jsx)("div",{ref:r,className:"min-w-0 ".concat("h-[35rem]"),children:(0,n.jsx)(K,{worktree:t,enabled:i,connectivity:s})})}),Y=(0,a.memo)(function(e){let{worktrees:t}=e,s=A();return(0,n.jsx)("div",{className:"grid grid-cols-1 gap-4 xl:grid-cols-2","data-testid":"sessions-tile-grid",children:t.map(e=>(0,n.jsx)(V,{worktree:e,connectivity:s},e.id))})});var q=s(80003);let H=(0,s(71847).A)("layout-grid",[["rect",{width:"7",height:"7",x:"3",y:"3",rx:"1",key:"1g98yp"}],["rect",{width:"7",height:"7",x:"14",y:"3",rx:"1",key:"6d4xhi"}],["rect",{width:"7",height:"7",x:"14",y:"14",rx:"1",key:"nxv5o0"}],["rect",{width:"7",height:"7",x:"3",y:"14",rx:"1",key:"1bb6yr"}]]),W=["list","tile"];function G(e){return"string"==typeof e&&W.includes(e)}let J=[{mode:"list",labelKey:"sessions.viewMode.list",icon:q.A},{mode:"tile",labelKey:"sessions.viewMode.tile",icon:H}],Q=(0,a.memo)(function(e){let{value:t,onChange:s}=e,a=(0,l.c)("common");return(0,n.jsx)("div",{className:"flex shrink-0 items-center gap-1 rounded-md border border-input bg-surface p-0.5",role:"group","aria-label":a("sessions.viewMode.groupAriaLabel"),"data-testid":"sessions-view-mode",children:J.map(e=>{let{mode:r,labelKey:i,icon:l}=e,o=t===r;return(0,n.jsx)("button",{type:"button",onClick:()=>s(r),"aria-pressed":o,"aria-label":a(i),title:a(i),"data-testid":"sessions-view-mode-".concat(r),className:"rounded p-1.5 transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring ".concat(o?"bg-accent-100 text-accent-700 dark:bg-accent-900/30 dark:text-accent-400":"text-muted-foreground hover:text-foreground"),children:(0,n.jsx)(l,{size:16,"aria-hidden":"true"})},r)})})});var X=s(38218),$=s(50857),Z=s(7636),ee=s(83012),et=s(6473);let es=[{key:"repositoryName",labelKey:"sort.repositoryName"},{key:"status",labelKey:"sort.status"},{key:"lastSent",labelKey:"sort.lastSent"}],en={lastSent:"desc",updatedAt:"desc"},ea={ready:0,in_progress:1,in_review:2,done:3};function er(e){let{status:t,label:s}=e,a=(0,l.c)("common"),r="".concat(s,": ").concat(a("status.".concat(t)));return(0,n.jsx)(y.md,{status:t,size:"md",label:r})}let ei={ready:"worktreeStatus.ready",in_progress:"worktreeStatus.inProgress",in_review:"worktreeStatus.inReview",done:"worktreeStatus.done"},el={done:"bg-success-subtle text-success-foreground",in_review:"bg-info-subtle text-info-foreground",in_progress:"bg-accent-100 dark:bg-accent-900/30 text-accent-700 dark:text-accent-400"};function eo(){let e=(0,l.c)("common"),t=(0,l.c)("worktree"),s=(0,X.a)(),{worktrees:r,isLoading:m,error:x,refresh:h}=(0,C.Fn)(),f=r.length>0,[g,p]=(0,a.useState)(""),[b,v]=(0,a.useState)("lastSent"),[w,j]=(0,a.useState)("desc"),{viewMode:k,setViewMode:N}=function(){let{value:e,setValue:t}=(0,L.V)({key:"mcbd-sessions-view-mode",defaultValue:"list",validate:G,serialize:e=>e,deserialize:e=>e});return{viewMode:e,setViewMode:(0,a.useCallback)(e=>t(e),[t])}}(),A="tile"===k;(0,a.useEffect)(()=>{(0,R.qD)()},[]);let M=(0,a.useMemo)(()=>{let e=r;if(g){let t=g.toLowerCase();e=e.filter(e=>{var s,n;return e.name.toLowerCase().includes(t)||e.repositoryName.toLowerCase().includes(t)||null!=(n=null==(s=e.repositoryDisplayName)?void 0:s.toLowerCase().includes(t))&&n})}let t=[...e];return t.sort((e,t)=>{var s,n,a,r,i,l,o,c;let d=0;switch(b){case"lastSent":{let s=(0,Z.nO)(e.lastUserMessageAt,t.lastUserMessageAt);if(!e.lastUserMessageAt&&!t.lastUserMessageAt)return 0;if(!e.lastUserMessageAt)return 1;if(!t.lastUserMessageAt)return -1;d=s;break}case"repositoryName":{let a=(null!=(s=e.repositoryDisplayName)?s:e.repositoryName).toLowerCase(),r=(null!=(n=t.repositoryDisplayName)?n:t.repositoryName).toLowerCase();0===(d=a.localeCompare(r))&&(d=e.name.toLowerCase().localeCompare(t.name.toLowerCase()));break}case"status":if(0==(d=(null!=(r=ea[null!=(a=e.status)?a:""])?r:4)-(null!=(l=ea[null!=(i=t.status)?i:""])?l:4))){let s=(null!=(o=e.repositoryDisplayName)?o:e.repositoryName).toLowerCase(),n=(null!=(c=t.repositoryDisplayName)?c:t.repositoryName).toLowerCase();d=s.localeCompare(n)}break;default:d=0}return("lastSent"===b?"desc"===w:"asc"===w)?d:-d}),t},[r,g,b,w]),S=(0,a.useCallback)(e=>{p(e.target.value)},[]),I=(0,a.useCallback)(e=>{var t;v(e),j(null!=(t=en[e])?t:"asc")},[]),E=(0,a.useCallback)(()=>{j(e=>"asc"===e?"desc":"asc")},[]);return(0,n.jsx)(d.GV,{children:(0,n.jsxs)(u.k,{onRefresh:h,enabled:s,className:"".concat(A?"w-full px-4 sm:px-6 lg:px-8":"container-custom"," py-8 h-full"),children:[(0,n.jsxs)("div",{className:"mb-6",children:[(0,n.jsx)("h1",{className:"text-2xl font-bold text-foreground mb-2",children:e("sessions.title")}),(0,n.jsx)("p",{className:"text-sm text-muted-foreground",children:e("sessions.description")})]}),(0,n.jsxs)("div",{className:"mb-6 flex items-center gap-3",children:[(0,n.jsx)(y.pd,{type:"text",placeholder:e("sessions.filterPlaceholder"),value:g,onChange:S,className:"max-w-md flex-1","data-testid":"sessions-filter","aria-label":e("sessions.filterAriaLabel"),inputMode:"search",enterKeyHint:"search"}),(0,n.jsxs)(y.l6,{value:b,onValueChange:I,children:[(0,n.jsx)(y.bq,{className:"w-40","data-testid":"sessions-sort-select","aria-label":e("sessions.sortByAriaLabel"),children:(0,n.jsx)(y.yv,{})}),(0,n.jsx)(y.gC,{children:es.map(t=>(0,n.jsx)(y.eb,{value:t.key,children:e(t.labelKey)},t.key))})]}),(0,n.jsx)("button",{type:"button",onClick:E,"data-testid":"sessions-sort-direction","aria-label":"asc"===w?e("sessions.sortAscending"):e("sessions.sortDescending"),className:"rounded-md border border-input bg-surface p-2 text-muted-foreground transition-colors hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",children:"asc"===w?(0,n.jsx)(o.A,{size:16,"aria-hidden":"true"}):(0,n.jsx)(c.A,{size:16,"aria-hidden":"true"})}),(0,n.jsx)(Q,{value:k,onChange:N})]}),f?(0,n.jsxs)(n.Fragment,{children:[x&&(0,n.jsx)("div",{className:"mb-4 rounded-md border border-danger-border bg-danger-subtle px-3 py-2 text-sm text-danger-foreground",role:"status","data-testid":"sessions-error-banner",children:e("sessions.refreshError",{message:x.message})}),A?0===M.length?(0,n.jsx)("div",{className:"text-muted-foreground py-8 text-center","data-testid":"sessions-empty",children:e("sessions.noMatching")}):(0,n.jsx)(Y,{worktrees:M}):(0,n.jsx)("div",{className:"space-y-2","data-testid":"sessions-list",children:0===M.length?(0,n.jsx)("div",{className:"text-muted-foreground py-8 text-center","data-testid":"sessions-empty",children:e("sessions.noMatching")}):M.map((s,a)=>{var r,l,o,c;let d=null!=(r=s.selectedAgents)?r:(0,R.sA)(),u=s.lastUserMessage?s.lastUserMessage.replace(/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x9F]/g,"").replace(/[\u200B-\u200F\u2028-\u202F\uFEFF\u061C]/g,"").replace(/[\r\n\t]/g," ").replace(/\s+/g," ").trim():null,m=s.lastUserMessageAt?(0,ee.Fx)(String(s.lastUserMessageAt)):null,x=d.map(e=>{var t;return{agent:e,status:(0,P.kA)(null==(t=s.sessionStatusByCli)?void 0:t[e])}}),h=x.filter(e=>(0,$.Qo)(e.status)),f=x.length-h.length,g=d.some(e=>{var t;let n=(0,P.kA)(null==(t=s.sessionStatusByCli)?void 0:t[e]);return"running"===n||"generating"===n});return(0,n.jsxs)(i(),{href:"/worktrees/".concat(s.id),style:{animationDelay:(0,et.Lc)(a)},className:"block bg-surface rounded-lg p-4 border transition-colors ".concat(g?"border-accent-500/40 shadow-[0_0_16px_-4px_rgb(var(--accent-500)/0.45)] hover:border-accent-400":"border-border shadow-sm hover:border-accent-300 dark:hover:border-accent-700"," ").concat(et.qz),"data-testid":"session-item-".concat(s.id),children:[(0,n.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,n.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,n.jsx)("div",{className:"text-sm font-medium text-foreground truncate",children:null!=(l=s.repositoryDisplayName)?l:s.repositoryName}),(0,n.jsx)("div",{className:"text-xs text-muted-foreground truncate",children:s.name})]}),(0,n.jsxs)("div",{className:"flex items-center gap-2 ml-4 flex-shrink-0","data-testid":"session-agents-".concat(s.id),children:[h.map(e=>{let{agent:t,status:s}=e;return(0,n.jsxs)("div",{className:"flex items-center gap-1","data-testid":"session-agent-".concat(t),children:[(0,n.jsx)(er,{status:s,label:(0,T.oo)(t)}),(0,n.jsx)("span",{className:"text-xs text-muted-foreground",children:(0,T.oo)(t)})]},t)}),f>0&&(0,n.jsxs)("div",{className:"flex items-center gap-1","data-testid":"session-idle-cluster-".concat(s.id),"aria-label":e("sessions.idleAgents",{count:f}),children:[(0,n.jsx)(y.md,{status:"idle",size:"sm","aria-hidden":!0,title:void 0}),(0,n.jsxs)("span",{className:"text-xs text-muted-foreground tabular-nums",children:["+",f]})]})]})]}),s.description&&(0,n.jsx)("div",{className:"mt-2",children:(0,n.jsx)("p",{className:"text-xs text-muted-foreground line-clamp-2 whitespace-pre-wrap",children:s.description})}),s.status&&(0,n.jsx)("div",{className:"mt-2",children:(0,n.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium rounded ".concat(null!=(c=el[null!=(o=s.status)?o:""])?c:"bg-muted text-muted-foreground"),children:function(e,t){if(!e)return"";let s=ei[e];return s?t(s):e}(s.status,t)})}),u&&(0,n.jsxs)("div",{className:"mt-2 flex items-center gap-2","data-testid":"session-message-".concat(s.id),children:[(0,n.jsx)("span",{className:"text-xs text-muted-foreground truncate min-w-0 flex-1","data-testid":"session-message-text-".concat(s.id),title:u,children:u}),m&&(0,n.jsx)("span",{className:"text-xs text-muted-foreground flex-shrink-0 whitespace-nowrap tabular-nums","data-testid":"session-time-".concat(s.id),children:m})]})]},s.id)})})]}):(0,n.jsxs)(n.Fragment,{children:[m&&(0,n.jsx)("div",{className:"space-y-2","data-testid":"sessions-loading",role:"status","aria-label":e("sessions.loadingAriaLabel"),children:[0,1,2].map(e=>(0,n.jsxs)("div",{className:"block bg-surface rounded-lg p-4 border border-border shadow-sm",children:[(0,n.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,n.jsxs)("div",{className:"min-w-0 flex-1 space-y-1.5",children:[(0,n.jsx)(y.EA,{className:"h-4 w-40 max-w-full"}),(0,n.jsx)(y.EA,{className:"h-3 w-56 max-w-full"})]}),(0,n.jsx)(y.EA,{className:"ml-4 h-3 w-16 flex-shrink-0"})]}),(0,n.jsxs)("div",{className:"mt-3 flex items-center gap-2",children:[(0,n.jsx)(y.EA,{className:"h-3 min-w-0 flex-1"}),(0,n.jsx)(y.EA,{className:"h-3 w-10 flex-shrink-0"})]})]},e))}),!m&&x&&(0,n.jsx)("div",{className:"text-danger-foreground","data-testid":"sessions-error",children:e("sessions.loadError",{message:x.message})}),!m&&!x&&(0,n.jsx)("div",{className:"text-muted-foreground py-8 text-center","data-testid":"sessions-empty",children:g?e("sessions.noMatching"):e("sessions.empty")})]})]})})}},80003:(e,t,s)=>{"use strict";s.d(t,{A:()=>n});let n=(0,s(71847).A)("list",[["path",{d:"M3 5h.01",key:"18ugdj"}],["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 19h.01",key:"noohij"}],["path",{d:"M8 5h13",key:"1pao27"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 19h13",key:"m83p4d"}]])},87047:(e,t,s)=>{Promise.resolve().then(s.bind(s,62147))}},e=>{e.O(0,[6809,4909,2770,790,5694,8566,934,9948,5520,2407,6402,8019,4718,4388,2039,4949,8441,1255,7358],()=>e(e.s=87047)),_N_E=e.O()}]);
@@ -1 +1 @@
1
- (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9404],{68331:(e,s,t)=>{"use strict";t.d(s,{y:()=>n});var a=t(95155);t(12115);var l=t(18955),i=t(37381),r=t(95584);function n(e){let{catalog:s}=e,t=(0,l.c)("skills");return s.stale||s.offline?(0,a.jsx)(i.u,{tone:"warning","data-testid":"skill-catalog-stale",className:"flex-col sm:flex-row",children:(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("p",{className:"font-medium",children:t("catalog.staleHeading")}),(0,a.jsx)("p",{children:t("catalog.staleNotice")}),s.offline&&(0,a.jsx)("p",{children:t("catalog.offlineNotice")}),(0,a.jsx)("p",{children:t((0,r.pk)(s.staleReason))}),(0,a.jsxs)("p",{className:"break-words",children:[t("catalog.fetchedAt",{timestamp:s.fetchedAt})," \xb7"," ",t("catalog.revalidatedAt",{timestamp:s.revalidatedAt})]}),(0,a.jsx)("p",{className:"break-words",children:t("catalog.sourceLabel",{repository:s.source.repository,ref:s.source.ref})})]})}):(0,a.jsxs)("p",{"data-testid":"skill-catalog-fresh",className:"text-xs text-muted-foreground break-words",children:[t("catalog.freshLabel")," \xb7"," ",t("catalog.revalidatedAt",{timestamp:s.revalidatedAt})," \xb7"," ",t("catalog.sourceLabel",{repository:s.source.repository,ref:s.source.ref})]})}},89675:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>q});var a=t(95155),l=t(20063),i=t(54388),r=t(12115),n=t(52619),d=t.n(n),o=t(18955),c=t(35626),m=t(28019),x=t(99648),u=t(75333),h=t(68331),g=t(50825),p=t(24027),j=t(95584);function f(e){let{changelog:s}=e,t=(0,o.c)("skills"),l=(0,j.RG)(s).trim();return 0===l.length?(0,a.jsx)("p",{className:"text-sm text-muted-foreground","data-testid":"skill-changelog-empty",children:t("detail.changelogEmpty")}):(0,a.jsxs)("div",{"data-testid":"skill-changelog",children:[(0,a.jsx)("div",{className:"prose prose-sm max-w-none dark:prose-invert break-words",children:(0,a.jsx)(p.G8,{content:l})}),(0,a.jsx)("p",{className:"mt-2 text-xs text-muted-foreground",children:t("detail.mediaStripped")})]})}var k=t(34380),b=t(37381),v=t(80130);let N={status:"loading",catalog:null,skill:null,failure:null};function y(e){let{label:s,children:t,mono:l=!1}=e;return(0,a.jsxs)("div",{className:"min-w-0",children:[(0,a.jsx)("dt",{className:"text-xs font-medium text-muted-foreground",children:s}),(0,a.jsx)("dd",{className:"mt-0.5 text-sm text-foreground ".concat(l?"break-all font-mono text-xs":"break-words"),children:t})]})}function w(e){let{title:s,children:t,testId:l}=e;return(0,a.jsxs)(m.Zp,{"data-testid":l,className:"space-y-3",children:[(0,a.jsx)("h2",{className:"text-base font-semibold text-foreground",children:s}),t]})}function V(e){var s;let{compatibility:t}=e,l=(0,o.c)("skills");return(0,a.jsx)("p",{className:"text-sm text-foreground","data-testid":"skill-compatibility-reason",children:l((0,j.e5)(t.messageKey),{range:t.requiredRange,currentVersion:null!=(s=t.currentVersion)?s:""})})}function I(e){let{version:s}=e,t=(0,o.c)("skills");return(0,a.jsxs)(m.Zp,{"data-testid":"skill-version-".concat(s.version),className:"space-y-3",padding:"sm",children:[(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,a.jsx)("span",{className:"font-mono text-sm font-semibold text-foreground",children:s.version}),s.prerelease&&(0,a.jsx)(m.Ex,{variant:"warning",children:t("detail.prerelease")}),(0,a.jsx)(u.Xz,{status:s.compatibility.commandmate.status}),(0,a.jsx)(u.qW,{risk:s.declaredRisk})]}),(0,a.jsxs)("dl",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[(0,a.jsx)(y,{label:t("detail.publishedAt"),children:s.publishedAt}),(0,a.jsx)(y,{label:t("detail.requiredRangeLabel"),children:s.compatibility.commandmate.requiredRange}),(0,a.jsx)(y,{label:t("detail.sourceRepository"),children:s.source.repository}),(0,a.jsx)(y,{label:t("detail.sourceRef"),children:s.source.ref}),(0,a.jsx)(y,{label:t("detail.sourceCommit"),mono:!0,children:s.source.commit}),(0,a.jsx)(y,{label:t("detail.packageAsset"),mono:!0,children:s.artifact.assetName}),(0,a.jsx)(y,{label:t("detail.packageDigest"),mono:!0,children:s.artifact.sha256}),(0,a.jsx)(y,{label:t("detail.packageSize"),children:t("detail.packageBytes",{bytes:s.artifact.size})})]}),(0,a.jsx)("div",{className:"flex flex-wrap gap-1.5",children:s.compatibility.agents.length>0?s.compatibility.agents.map(e=>(0,a.jsx)(u.uE,{agent:e},e.agent)):(0,a.jsx)("p",{className:"text-xs text-muted-foreground",children:t("compatibility.agentsUnknown")})}),(0,a.jsxs)("div",{children:[(0,a.jsx)("h3",{className:"text-xs font-medium text-muted-foreground",children:t("detail.changelogHeading")}),(0,a.jsx)("div",{className:"mt-1",children:(0,a.jsx)(f,{changelog:s.changelog})})]})]})}function R(e){var s,t,l,i,n,p,f,R,q;let{skillId:A}=e,E=(0,o.c)("skills"),[C,H]=(0,r.useState)(N),[_,z]=(0,r.useState)(0);(0,r.useEffect)(()=>{let e=new AbortController;return H(N),(0,v.Db)(A,e.signal).then(s=>{e.signal.aborted||H(s.ok?{status:"loaded",catalog:s.data.catalog,skill:s.data.skill,failure:null}:{status:"error",catalog:null,skill:null,failure:s.failure})}).catch(()=>{}),()=>e.abort()},[A,_]);let U=(0,r.useCallback)(()=>z(e=>e+1),[]),F=(0,a.jsxs)(d(),{href:"/skills",className:"inline-flex items-center gap-1 text-sm text-accent-600 hover:underline dark:text-accent-400","data-testid":"skill-detail-back",children:[(0,a.jsx)(c.A,{size:14,"aria-hidden":"true"}),E("page.backToCatalog")]});if("loading"===C.status)return(0,a.jsxs)("div",{className:"space-y-4","data-testid":"skill-detail-loading",children:[F,(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:E("state.loading")}),(0,a.jsx)(m.EA,{className:"h-40 w-full rounded-lg"})]});if("error"===C.status||!C.skill){let e=(null==(t=C.failure)?void 0:t.status)===404;return(0,a.jsxs)("div",{className:"space-y-4",children:[F,(0,a.jsxs)(m.Zp,{"data-testid":e?"skill-detail-not-found":"skill-detail-error",className:"space-y-3",children:[(0,a.jsx)("h2",{className:"text-base font-semibold text-foreground",children:E(e?"state.notFoundHeading":"state.errorHeading")}),(0,a.jsxs)(b.u,{tone:"danger",children:[(0,a.jsx)("p",{children:E(e?"state.notFoundNotice":"state.errorNotice")}),(0,a.jsx)("p",{className:"mt-1 break-words",children:E("state.errorCode",{code:null!=(i=null==(l=C.failure)?void 0:l.code)?i:""})})]}),!e&&(0,a.jsx)(m.$n,{variant:"secondary",size:"sm",onClick:U,"data-testid":"skill-detail-retry",children:E("state.retry")})]})]})}let L=C.skill,S=L.compatibility,W=null!=(n=L.versions.find(e=>e.version===L.recommendedVersion))?n:null,Z=null!=(p=null==(s=null!=W?W:L.versions[0])?void 0:s.declaredRisk)?p:null,G=L.recommendedVersion?S&&"compatible"!==S.status?E("detail.install.blockedIncompatible",{reason:E((0,j.e5)(S.messageKey),{range:S.requiredRange,currentVersion:null!=(f=S.currentVersion)?f:""})}):null:E("detail.install.blockedNoVersion");return(0,a.jsxs)("div",{className:"space-y-4",children:[F,C.catalog&&(0,a.jsx)(h.y,{catalog:C.catalog}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)("h1",{className:"text-2xl font-bold text-foreground break-words",children:L.name}),(0,a.jsx)("p",{className:"text-sm text-muted-foreground break-words",children:L.summary}),(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-1.5",children:[S&&(0,a.jsx)(u.Xz,{status:S.status}),Z&&(0,a.jsx)(u.qW,{risk:Z})]})]}),(0,a.jsx)(w,{title:E("detail.install.action"),testId:"skill-install-section",children:(0,a.jsx)(k.B,{skillId:L.id,version:L.recommendedVersion,blockedReason:G,agents:null!=(R=null==W?void 0:W.compatibility.agents)?R:[]})}),(0,a.jsxs)(w,{title:E("capabilities.heading"),testId:"skill-capabilities-section",children:[(0,a.jsx)("p",{className:"text-sm text-foreground break-words",children:L.summary}),(0,a.jsx)(b.u,{tone:"neutral",children:E("capabilities.unavailable")})]}),(0,a.jsxs)(w,{title:E("detail.overview"),testId:"skill-overview-section",children:[(0,a.jsxs)("dl",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[(0,a.jsx)(y,{label:E("detail.skillId"),mono:!0,children:L.id}),(0,a.jsx)(y,{label:E("detail.provider"),children:L.provider.url?(0,a.jsx)("a",{href:L.provider.url,target:"_blank",rel:"noopener noreferrer",className:"text-accent-600 hover:underline dark:text-accent-400",children:L.provider.name}):L.provider.name}),L.provider.contact&&(0,a.jsx)(y,{label:E("detail.providerContact"),children:L.provider.contact}),(0,a.jsx)(y,{label:E("detail.license"),children:L.license}),L.homepage&&(0,a.jsx)(y,{label:E("detail.homepage"),children:(0,a.jsx)("a",{href:L.homepage,target:"_blank",rel:"noopener noreferrer",className:"break-all text-accent-600 hover:underline dark:text-accent-400",children:L.homepage})}),(0,a.jsx)(y,{label:E("detail.latestVersion"),mono:!0,children:L.latest}),(0,a.jsx)(y,{label:E("detail.recommendedVersion"),mono:!0,children:null!=(q=L.recommendedVersion)?q:E("detail.recommendedVersionNone")})]}),(0,a.jsx)("p",{className:"text-xs text-muted-foreground","data-testid":"skill-recommendation-reason",children:E(j.TE[L.recommendedReason])}),L.keywords.length>0&&(0,a.jsxs)("div",{children:[(0,a.jsx)("h3",{className:"text-xs font-medium text-muted-foreground",children:E("detail.keywords")}),(0,a.jsx)("div",{className:"mt-1 flex flex-wrap gap-1.5",children:L.keywords.map(e=>(0,a.jsx)(m.Ex,{variant:"gray",children:e},e))})]})]}),(0,a.jsxs)(w,{title:E("compatibility.label"),testId:"skill-compatibility-section",children:[S?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,a.jsx)(u.Xz,{status:S.status}),(0,a.jsx)("span",{className:"text-sm text-muted-foreground",children:E("compatibility.requiredRange",{range:S.requiredRange})})]}),(0,a.jsx)(V,{compatibility:S}),(0,a.jsx)("p",{className:"text-xs text-muted-foreground",children:S.currentVersion?E("compatibility.currentVersion",{version:S.currentVersion}):E("compatibility.currentVersionUnknown")}),"unknown"===S.status&&(0,a.jsx)(b.u,{tone:"warning","data-testid":"skill-compatibility-unknown-notice",children:E("compatibility.unverifiedNotice")})]}):(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:E("compatibility.currentVersionUnknown")}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)("h3",{className:"text-sm font-medium text-foreground",children:E("compatibility.agentsHeading")}),W&&W.compatibility.agents.length>0?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"flex flex-wrap gap-1.5",children:W.compatibility.agents.map(e=>(0,a.jsx)(u.uE,{agent:e},e.agent))}),(0,a.jsx)("div",{className:"space-y-3",children:W.compatibility.agents.map(e=>(0,a.jsx)(g.m,{agent:e},e.agent))})]}):(0,a.jsx)("p",{className:"text-xs text-muted-foreground",children:E("compatibility.agentsUnknown")}),(0,a.jsx)(b.u,{tone:"neutral",children:E("compatibility.agentsNotice")})]})]}),(0,a.jsxs)(w,{title:E("risk.declaredHeading"),testId:"skill-risk-section",children:[Z?(0,a.jsx)(u.qW,{risk:Z}):null,(0,a.jsx)(b.u,{tone:"neutral",children:E("risk.declaredNotice")}),"high"===Z&&(0,a.jsx)(b.u,{tone:"danger","data-testid":"skill-high-risk-warning",children:E("risk.highWarning")}),(0,a.jsxs)("div",{children:[(0,a.jsx)("h3",{className:"text-sm font-medium text-foreground",children:E("risk.computedHeading")}),(0,a.jsx)("p",{className:"mt-1 text-sm text-muted-foreground","data-testid":"skill-computed-risk-unavailable",children:E("risk.computedUnavailable")})]})]}),(0,a.jsxs)(w,{title:E("permissions.heading"),testId:"skill-permissions-section",children:[(0,a.jsx)(b.u,{tone:"warning","data-testid":"skill-permission-declaration-notice",children:E((0,j.e5)(x.Ms))}),(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:E("permissions.unavailable")})]}),(0,a.jsx)(w,{title:E("requirements.heading"),testId:"skill-requirements-section",children:(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:E("requirements.unavailable")})}),(0,a.jsx)(w,{title:E("contents.heading"),testId:"skill-contents-section",children:(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:E("contents.unavailable")})}),(0,a.jsxs)("section",{className:"space-y-3","data-testid":"skill-versions-section",children:[(0,a.jsx)("h2",{className:"text-base font-semibold text-foreground",children:E("detail.versionsHeading")}),0===L.versions.length?(0,a.jsx)(m.Zp,{children:(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:E("detail.versionsEmpty")})}):L.versions.map(e=>(0,a.jsx)(I,{version:e},e.version))]})]})}function q(){let e=(0,l.useParams)(),s="string"==typeof e.skillId?e.skillId:"";return(0,a.jsx)(i.GV,{children:(0,a.jsx)("div",{className:"container-custom py-8 overflow-auto h-full",children:(0,a.jsx)(R,{skillId:s})})})}},99027:(e,s,t)=>{Promise.resolve().then(t.bind(t,89675))}},e=>{e.O(0,[6481,6809,4909,2770,790,5694,8566,1191,5542,2407,6402,8019,4718,4388,2751,2053,8441,1255,7358],()=>e(e.s=99027)),_N_E=e.O()}]);
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9404],{68331:(e,s,t)=>{"use strict";t.d(s,{y:()=>n});var a=t(95155);t(12115);var l=t(18955),i=t(37381),r=t(95584);function n(e){let{catalog:s}=e,t=(0,l.c)("skills");return s.stale||s.offline?(0,a.jsx)(i.u,{tone:"warning","data-testid":"skill-catalog-stale",className:"flex-col sm:flex-row",children:(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("p",{className:"font-medium",children:t("catalog.staleHeading")}),(0,a.jsx)("p",{children:t("catalog.staleNotice")}),s.offline&&(0,a.jsx)("p",{children:t("catalog.offlineNotice")}),(0,a.jsx)("p",{children:t((0,r.pk)(s.staleReason))}),(0,a.jsxs)("p",{className:"break-words",children:[t("catalog.fetchedAt",{timestamp:s.fetchedAt})," \xb7"," ",t("catalog.revalidatedAt",{timestamp:s.revalidatedAt})]}),(0,a.jsx)("p",{className:"break-words",children:t("catalog.sourceLabel",{repository:s.source.repository,ref:s.source.ref})})]})}):(0,a.jsxs)("p",{"data-testid":"skill-catalog-fresh",className:"text-xs text-muted-foreground break-words",children:[t("catalog.freshLabel")," \xb7"," ",t("catalog.revalidatedAt",{timestamp:s.revalidatedAt})," \xb7"," ",t("catalog.sourceLabel",{repository:s.source.repository,ref:s.source.ref})]})}},89675:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>q});var a=t(95155),l=t(20063),i=t(54388),r=t(12115),n=t(52619),d=t.n(n),o=t(18955),c=t(35626),m=t(28019),x=t(99648),u=t(75333),h=t(68331),g=t(50825),p=t(24027),j=t(95584);function f(e){let{changelog:s}=e,t=(0,o.c)("skills"),l=(0,j.RG)(s).trim();return 0===l.length?(0,a.jsx)("p",{className:"text-sm text-muted-foreground","data-testid":"skill-changelog-empty",children:t("detail.changelogEmpty")}):(0,a.jsxs)("div",{"data-testid":"skill-changelog",children:[(0,a.jsx)("div",{className:"prose prose-sm max-w-none dark:prose-invert break-words",children:(0,a.jsx)(p.G8,{content:l})}),(0,a.jsx)("p",{className:"mt-2 text-xs text-muted-foreground",children:t("detail.mediaStripped")})]})}var k=t(34380),b=t(37381),v=t(80130);let N={status:"loading",catalog:null,skill:null,failure:null};function y(e){let{label:s,children:t,mono:l=!1}=e;return(0,a.jsxs)("div",{className:"min-w-0",children:[(0,a.jsx)("dt",{className:"text-xs font-medium text-muted-foreground",children:s}),(0,a.jsx)("dd",{className:"mt-0.5 text-sm text-foreground ".concat(l?"break-all font-mono text-xs":"break-words"),children:t})]})}function w(e){let{title:s,children:t,testId:l}=e;return(0,a.jsxs)(m.Zp,{"data-testid":l,className:"space-y-3",children:[(0,a.jsx)("h2",{className:"text-base font-semibold text-foreground",children:s}),t]})}function V(e){var s;let{compatibility:t}=e,l=(0,o.c)("skills");return(0,a.jsx)("p",{className:"text-sm text-foreground","data-testid":"skill-compatibility-reason",children:l((0,j.e5)(t.messageKey),{range:t.requiredRange,currentVersion:null!=(s=t.currentVersion)?s:""})})}function I(e){let{version:s}=e,t=(0,o.c)("skills");return(0,a.jsxs)(m.Zp,{"data-testid":"skill-version-".concat(s.version),className:"space-y-3",padding:"sm",children:[(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,a.jsx)("span",{className:"font-mono text-sm font-semibold text-foreground",children:s.version}),s.prerelease&&(0,a.jsx)(m.Ex,{variant:"warning",children:t("detail.prerelease")}),(0,a.jsx)(u.Xz,{status:s.compatibility.commandmate.status}),(0,a.jsx)(u.qW,{risk:s.declaredRisk})]}),(0,a.jsxs)("dl",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[(0,a.jsx)(y,{label:t("detail.publishedAt"),children:s.publishedAt}),(0,a.jsx)(y,{label:t("detail.requiredRangeLabel"),children:s.compatibility.commandmate.requiredRange}),(0,a.jsx)(y,{label:t("detail.sourceRepository"),children:s.source.repository}),(0,a.jsx)(y,{label:t("detail.sourceRef"),children:s.source.ref}),(0,a.jsx)(y,{label:t("detail.sourceCommit"),mono:!0,children:s.source.commit}),(0,a.jsx)(y,{label:t("detail.packageAsset"),mono:!0,children:s.artifact.assetName}),(0,a.jsx)(y,{label:t("detail.packageDigest"),mono:!0,children:s.artifact.sha256}),(0,a.jsx)(y,{label:t("detail.packageSize"),children:t("detail.packageBytes",{bytes:s.artifact.size})})]}),(0,a.jsx)("div",{className:"flex flex-wrap gap-1.5",children:s.compatibility.agents.length>0?s.compatibility.agents.map(e=>(0,a.jsx)(u.uE,{agent:e},e.agent)):(0,a.jsx)("p",{className:"text-xs text-muted-foreground",children:t("compatibility.agentsUnknown")})}),(0,a.jsxs)("div",{children:[(0,a.jsx)("h3",{className:"text-xs font-medium text-muted-foreground",children:t("detail.changelogHeading")}),(0,a.jsx)("div",{className:"mt-1",children:(0,a.jsx)(f,{changelog:s.changelog})})]})]})}function R(e){var s,t,l,i,n,p,f,R,q;let{skillId:A}=e,E=(0,o.c)("skills"),[C,H]=(0,r.useState)(N),[_,z]=(0,r.useState)(0);(0,r.useEffect)(()=>{let e=new AbortController;return H(N),(0,v.Db)(A,e.signal).then(s=>{e.signal.aborted||H(s.ok?{status:"loaded",catalog:s.data.catalog,skill:s.data.skill,failure:null}:{status:"error",catalog:null,skill:null,failure:s.failure})}).catch(()=>{}),()=>e.abort()},[A,_]);let U=(0,r.useCallback)(()=>z(e=>e+1),[]),F=(0,a.jsxs)(d(),{href:"/skills",className:"inline-flex items-center gap-1 text-sm text-accent-600 hover:underline dark:text-accent-400","data-testid":"skill-detail-back",children:[(0,a.jsx)(c.A,{size:14,"aria-hidden":"true"}),E("page.backToCatalog")]});if("loading"===C.status)return(0,a.jsxs)("div",{className:"space-y-4","data-testid":"skill-detail-loading",children:[F,(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:E("state.loading")}),(0,a.jsx)(m.EA,{className:"h-40 w-full rounded-lg"})]});if("error"===C.status||!C.skill){let e=(null==(t=C.failure)?void 0:t.status)===404;return(0,a.jsxs)("div",{className:"space-y-4",children:[F,(0,a.jsxs)(m.Zp,{"data-testid":e?"skill-detail-not-found":"skill-detail-error",className:"space-y-3",children:[(0,a.jsx)("h2",{className:"text-base font-semibold text-foreground",children:E(e?"state.notFoundHeading":"state.errorHeading")}),(0,a.jsxs)(b.u,{tone:"danger",children:[(0,a.jsx)("p",{children:E(e?"state.notFoundNotice":"state.errorNotice")}),(0,a.jsx)("p",{className:"mt-1 break-words",children:E("state.errorCode",{code:null!=(i=null==(l=C.failure)?void 0:l.code)?i:""})})]}),!e&&(0,a.jsx)(m.$n,{variant:"secondary",size:"sm",onClick:U,"data-testid":"skill-detail-retry",children:E("state.retry")})]})]})}let L=C.skill,S=L.compatibility,W=null!=(n=L.versions.find(e=>e.version===L.recommendedVersion))?n:null,Z=null!=(p=null==(s=null!=W?W:L.versions[0])?void 0:s.declaredRisk)?p:null,G=L.recommendedVersion?S&&"compatible"!==S.status?E("detail.install.blockedIncompatible",{reason:E((0,j.e5)(S.messageKey),{range:S.requiredRange,currentVersion:null!=(f=S.currentVersion)?f:""})}):null:E("detail.install.blockedNoVersion");return(0,a.jsxs)("div",{className:"space-y-4",children:[F,C.catalog&&(0,a.jsx)(h.y,{catalog:C.catalog}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)("h1",{className:"text-2xl font-bold text-foreground break-words",children:L.name}),(0,a.jsx)("p",{className:"text-sm text-muted-foreground break-words",children:L.summary}),(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-1.5",children:[S&&(0,a.jsx)(u.Xz,{status:S.status}),Z&&(0,a.jsx)(u.qW,{risk:Z})]})]}),(0,a.jsx)(w,{title:E("detail.install.action"),testId:"skill-install-section",children:(0,a.jsx)(k.B,{skillId:L.id,version:L.recommendedVersion,blockedReason:G,agents:null!=(R=null==W?void 0:W.compatibility.agents)?R:[]})}),(0,a.jsxs)(w,{title:E("capabilities.heading"),testId:"skill-capabilities-section",children:[(0,a.jsx)("p",{className:"text-sm text-foreground break-words",children:L.summary}),(0,a.jsx)(b.u,{tone:"neutral",children:E("capabilities.unavailable")})]}),(0,a.jsxs)(w,{title:E("detail.overview"),testId:"skill-overview-section",children:[(0,a.jsxs)("dl",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[(0,a.jsx)(y,{label:E("detail.skillId"),mono:!0,children:L.id}),(0,a.jsx)(y,{label:E("detail.provider"),children:L.provider.url?(0,a.jsx)("a",{href:L.provider.url,target:"_blank",rel:"noopener noreferrer",className:"text-accent-600 hover:underline dark:text-accent-400",children:L.provider.name}):L.provider.name}),L.provider.contact&&(0,a.jsx)(y,{label:E("detail.providerContact"),children:L.provider.contact}),(0,a.jsx)(y,{label:E("detail.license"),children:L.license}),L.homepage&&(0,a.jsx)(y,{label:E("detail.homepage"),children:(0,a.jsx)("a",{href:L.homepage,target:"_blank",rel:"noopener noreferrer",className:"break-all text-accent-600 hover:underline dark:text-accent-400",children:L.homepage})}),(0,a.jsx)(y,{label:E("detail.latestVersion"),mono:!0,children:L.latest}),(0,a.jsx)(y,{label:E("detail.recommendedVersion"),mono:!0,children:null!=(q=L.recommendedVersion)?q:E("detail.recommendedVersionNone")})]}),(0,a.jsx)("p",{className:"text-xs text-muted-foreground","data-testid":"skill-recommendation-reason",children:E(j.TE[L.recommendedReason])}),L.keywords.length>0&&(0,a.jsxs)("div",{children:[(0,a.jsx)("h3",{className:"text-xs font-medium text-muted-foreground",children:E("detail.keywords")}),(0,a.jsx)("div",{className:"mt-1 flex flex-wrap gap-1.5",children:L.keywords.map(e=>(0,a.jsx)(m.Ex,{variant:"gray",children:e},e))})]})]}),(0,a.jsxs)(w,{title:E("compatibility.label"),testId:"skill-compatibility-section",children:[S?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,a.jsx)(u.Xz,{status:S.status}),(0,a.jsx)("span",{className:"text-sm text-muted-foreground",children:E("compatibility.requiredRange",{range:S.requiredRange})})]}),(0,a.jsx)(V,{compatibility:S}),(0,a.jsx)("p",{className:"text-xs text-muted-foreground",children:S.currentVersion?E("compatibility.currentVersion",{version:S.currentVersion}):E("compatibility.currentVersionUnknown")}),"unknown"===S.status&&(0,a.jsx)(b.u,{tone:"warning","data-testid":"skill-compatibility-unknown-notice",children:E("compatibility.unverifiedNotice")})]}):(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:E("compatibility.currentVersionUnknown")}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)("h3",{className:"text-sm font-medium text-foreground",children:E("compatibility.agentsHeading")}),W&&W.compatibility.agents.length>0?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"flex flex-wrap gap-1.5",children:W.compatibility.agents.map(e=>(0,a.jsx)(u.uE,{agent:e},e.agent))}),(0,a.jsx)("div",{className:"space-y-3",children:W.compatibility.agents.map(e=>(0,a.jsx)(g.m,{agent:e},e.agent))})]}):(0,a.jsx)("p",{className:"text-xs text-muted-foreground",children:E("compatibility.agentsUnknown")}),(0,a.jsx)(b.u,{tone:"neutral",children:E("compatibility.agentsNotice")})]})]}),(0,a.jsxs)(w,{title:E("risk.declaredHeading"),testId:"skill-risk-section",children:[Z?(0,a.jsx)(u.qW,{risk:Z}):null,(0,a.jsx)(b.u,{tone:"neutral",children:E("risk.declaredNotice")}),"high"===Z&&(0,a.jsx)(b.u,{tone:"danger","data-testid":"skill-high-risk-warning",children:E("risk.highWarning")}),(0,a.jsxs)("div",{children:[(0,a.jsx)("h3",{className:"text-sm font-medium text-foreground",children:E("risk.computedHeading")}),(0,a.jsx)("p",{className:"mt-1 text-sm text-muted-foreground","data-testid":"skill-computed-risk-unavailable",children:E("risk.computedUnavailable")})]})]}),(0,a.jsxs)(w,{title:E("permissions.heading"),testId:"skill-permissions-section",children:[(0,a.jsx)(b.u,{tone:"warning","data-testid":"skill-permission-declaration-notice",children:E((0,j.e5)(x.Ms))}),(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:E("permissions.unavailable")})]}),(0,a.jsx)(w,{title:E("requirements.heading"),testId:"skill-requirements-section",children:(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:E("requirements.unavailable")})}),(0,a.jsx)(w,{title:E("contents.heading"),testId:"skill-contents-section",children:(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:E("contents.unavailable")})}),(0,a.jsxs)("section",{className:"space-y-3","data-testid":"skill-versions-section",children:[(0,a.jsx)("h2",{className:"text-base font-semibold text-foreground",children:E("detail.versionsHeading")}),0===L.versions.length?(0,a.jsx)(m.Zp,{children:(0,a.jsx)("p",{className:"text-sm text-muted-foreground",children:E("detail.versionsEmpty")})}):L.versions.map(e=>(0,a.jsx)(I,{version:e},e.version))]})]})}function q(){let e=(0,l.useParams)(),s="string"==typeof e.skillId?e.skillId:"";return(0,a.jsx)(i.GV,{children:(0,a.jsx)("div",{className:"container-custom py-8 overflow-auto h-full",children:(0,a.jsx)(R,{skillId:s})})})}},99027:(e,s,t)=>{Promise.resolve().then(t.bind(t,89675))}},e=>{e.O(0,[6481,6809,4909,2770,790,5694,8566,934,6983,2407,6402,8019,4718,4388,2751,2039,2053,8441,1255,7358],()=>e(e.s=99027)),_N_E=e.O()}]);