@stigmer/react 0.0.36 → 0.0.40

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 (934) hide show
  1. package/README.md +4 -88
  2. package/__tests__/hooks.test.d.ts +2 -0
  3. package/__tests__/hooks.test.d.ts.map +1 -0
  4. package/__tests__/hooks.test.js +18 -0
  5. package/__tests__/hooks.test.js.map +1 -0
  6. package/agent/AgentDetailView.d.ts +80 -0
  7. package/agent/AgentDetailView.d.ts.map +1 -0
  8. package/agent/AgentDetailView.js +184 -0
  9. package/agent/AgentDetailView.js.map +1 -0
  10. package/agent/AgentEnvForm.d.ts +83 -0
  11. package/agent/AgentEnvForm.d.ts.map +1 -0
  12. package/agent/AgentEnvForm.js +31 -0
  13. package/agent/AgentEnvForm.js.map +1 -0
  14. package/agent/AgentPicker.d.ts +44 -0
  15. package/agent/AgentPicker.d.ts.map +1 -0
  16. package/agent/AgentPicker.js +121 -0
  17. package/agent/AgentPicker.js.map +1 -0
  18. package/agent/agentSetupReducer.d.ts +123 -0
  19. package/agent/agentSetupReducer.d.ts.map +1 -0
  20. package/agent/agentSetupReducer.js +86 -0
  21. package/agent/agentSetupReducer.js.map +1 -0
  22. package/agent/index.d.ts +19 -8
  23. package/agent/index.d.ts.map +1 -1
  24. package/agent/index.js +10 -6
  25. package/agent/index.js.map +1 -1
  26. package/agent/useAgent.d.ts +48 -0
  27. package/agent/useAgent.d.ts.map +1 -0
  28. package/agent/useAgent.js +82 -0
  29. package/agent/useAgent.js.map +1 -0
  30. package/agent/useAgentCount.d.ts +49 -0
  31. package/agent/useAgentCount.d.ts.map +1 -0
  32. package/agent/useAgentCount.js +32 -0
  33. package/agent/useAgentCount.js.map +1 -0
  34. package/agent/useAgentList.d.ts +62 -0
  35. package/agent/useAgentList.d.ts.map +1 -0
  36. package/agent/useAgentList.js +38 -0
  37. package/agent/useAgentList.js.map +1 -0
  38. package/agent/useAgentSearch.d.ts +23 -0
  39. package/agent/useAgentSearch.d.ts.map +1 -0
  40. package/agent/useAgentSearch.js +28 -0
  41. package/agent/useAgentSearch.js.map +1 -0
  42. package/agent/useAgentSetup.d.ts +115 -0
  43. package/agent/useAgentSetup.d.ts.map +1 -0
  44. package/agent/useAgentSetup.js +279 -0
  45. package/agent/useAgentSetup.js.map +1 -0
  46. package/agent/useDefaultAgent.d.ts +29 -0
  47. package/agent/useDefaultAgent.d.ts.map +1 -0
  48. package/agent/useDefaultAgent.js +60 -0
  49. package/agent/useDefaultAgent.js.map +1 -0
  50. package/agent-instance/buildPersonalInstanceInput.d.ts +20 -0
  51. package/agent-instance/buildPersonalInstanceInput.d.ts.map +1 -0
  52. package/agent-instance/buildPersonalInstanceInput.js +29 -0
  53. package/agent-instance/buildPersonalInstanceInput.js.map +1 -0
  54. package/agent-instance/index.d.ts +9 -0
  55. package/agent-instance/index.d.ts.map +1 -0
  56. package/agent-instance/index.js +5 -0
  57. package/agent-instance/index.js.map +1 -0
  58. package/agent-instance/useAgentInstance.d.ts +35 -0
  59. package/agent-instance/useAgentInstance.d.ts.map +1 -0
  60. package/agent-instance/useAgentInstance.js +67 -0
  61. package/agent-instance/useAgentInstance.js.map +1 -0
  62. package/agent-instance/useAgentInstanceList.d.ts +29 -0
  63. package/agent-instance/useAgentInstanceList.d.ts.map +1 -0
  64. package/agent-instance/useAgentInstanceList.js +74 -0
  65. package/agent-instance/useAgentInstanceList.js.map +1 -0
  66. package/agent-instance/useCreateAgentInstance.d.ts +44 -0
  67. package/agent-instance/useCreateAgentInstance.d.ts.map +1 -0
  68. package/agent-instance/useCreateAgentInstance.js +60 -0
  69. package/agent-instance/useCreateAgentInstance.js.map +1 -0
  70. package/agent-instance/usePersonalAgentInstance.d.ts +93 -0
  71. package/agent-instance/usePersonalAgentInstance.d.ts.map +1 -0
  72. package/agent-instance/usePersonalAgentInstance.js +103 -0
  73. package/agent-instance/usePersonalAgentInstance.js.map +1 -0
  74. package/api-key/ApiKeyCreatedAlert.d.ts +33 -0
  75. package/api-key/ApiKeyCreatedAlert.d.ts.map +1 -0
  76. package/api-key/ApiKeyCreatedAlert.js +61 -0
  77. package/api-key/ApiKeyCreatedAlert.js.map +1 -0
  78. package/api-key/ApiKeyListPanel.d.ts +30 -0
  79. package/api-key/ApiKeyListPanel.d.ts.map +1 -0
  80. package/api-key/ApiKeyListPanel.js +126 -0
  81. package/api-key/ApiKeyListPanel.js.map +1 -0
  82. package/api-key/CreateApiKeyForm.d.ts +35 -0
  83. package/api-key/CreateApiKeyForm.d.ts.map +1 -0
  84. package/api-key/CreateApiKeyForm.js +81 -0
  85. package/api-key/CreateApiKeyForm.js.map +1 -0
  86. package/api-key/index.d.ts +13 -0
  87. package/api-key/index.d.ts.map +1 -0
  88. package/api-key/index.js +7 -0
  89. package/api-key/index.js.map +1 -0
  90. package/api-key/useApiKeyList.d.ts +28 -0
  91. package/api-key/useApiKeyList.d.ts.map +1 -0
  92. package/api-key/useApiKeyList.js +52 -0
  93. package/api-key/useApiKeyList.js.map +1 -0
  94. package/api-key/useCreateApiKey.d.ts +40 -0
  95. package/api-key/useCreateApiKey.d.ts.map +1 -0
  96. package/api-key/useCreateApiKey.js +56 -0
  97. package/api-key/useCreateApiKey.js.map +1 -0
  98. package/api-key/useDeleteApiKey.d.ts +26 -0
  99. package/api-key/useDeleteApiKey.d.ts.map +1 -0
  100. package/api-key/useDeleteApiKey.js +43 -0
  101. package/api-key/useDeleteApiKey.js.map +1 -0
  102. package/attachment/AttachmentChipList.d.ts +24 -0
  103. package/attachment/AttachmentChipList.d.ts.map +1 -0
  104. package/attachment/AttachmentChipList.js +45 -0
  105. package/attachment/AttachmentChipList.js.map +1 -0
  106. package/attachment/attachment-utils.d.ts +32 -0
  107. package/attachment/attachment-utils.d.ts.map +1 -0
  108. package/attachment/attachment-utils.js +104 -0
  109. package/attachment/attachment-utils.js.map +1 -0
  110. package/attachment/index.d.ts +6 -0
  111. package/attachment/index.d.ts.map +1 -0
  112. package/attachment/index.js +4 -0
  113. package/attachment/index.js.map +1 -0
  114. package/attachment/useAttachments.d.ts +113 -0
  115. package/attachment/useAttachments.d.ts.map +1 -0
  116. package/attachment/useAttachments.js +175 -0
  117. package/attachment/useAttachments.js.map +1 -0
  118. package/composer/ComposerToolbar.d.ts +37 -0
  119. package/composer/ComposerToolbar.d.ts.map +1 -0
  120. package/composer/ComposerToolbar.js +24 -0
  121. package/composer/ComposerToolbar.js.map +1 -0
  122. package/composer/ConfigureMenu.d.ts +37 -0
  123. package/composer/ConfigureMenu.d.ts.map +1 -0
  124. package/composer/ConfigureMenu.js +53 -0
  125. package/composer/ConfigureMenu.js.map +1 -0
  126. package/composer/ContextChip.d.ts +22 -0
  127. package/composer/ContextChip.d.ts.map +1 -0
  128. package/composer/ContextChip.js +19 -0
  129. package/composer/ContextChip.js.map +1 -0
  130. package/composer/ContextPopover.d.ts +10 -0
  131. package/composer/ContextPopover.d.ts.map +1 -0
  132. package/composer/ContextPopover.js +11 -0
  133. package/composer/ContextPopover.js.map +1 -0
  134. package/composer/SessionComposer.d.ts +269 -0
  135. package/composer/SessionComposer.d.ts.map +1 -0
  136. package/composer/SessionComposer.js +580 -0
  137. package/composer/SessionComposer.js.map +1 -0
  138. package/composer/icons.d.ts +15 -0
  139. package/composer/icons.d.ts.map +1 -0
  140. package/composer/icons.js +42 -0
  141. package/composer/icons.js.map +1 -0
  142. package/composer/index.d.ts +5 -0
  143. package/composer/index.d.ts.map +1 -0
  144. package/composer/index.js +3 -0
  145. package/composer/index.js.map +1 -0
  146. package/composer/useComposer.d.ts +74 -0
  147. package/composer/useComposer.d.ts.map +1 -0
  148. package/composer/useComposer.js +94 -0
  149. package/composer/useComposer.js.map +1 -0
  150. package/environment/CreateEnvironmentForm.d.ts +31 -0
  151. package/environment/CreateEnvironmentForm.d.ts.map +1 -0
  152. package/environment/CreateEnvironmentForm.js +57 -0
  153. package/environment/CreateEnvironmentForm.js.map +1 -0
  154. package/environment/EnvVarForm.d.ts +134 -0
  155. package/environment/EnvVarForm.d.ts.map +1 -0
  156. package/environment/EnvVarForm.js +122 -0
  157. package/environment/EnvVarForm.js.map +1 -0
  158. package/environment/EnvironmentListPanel.d.ts +51 -0
  159. package/environment/EnvironmentListPanel.d.ts.map +1 -0
  160. package/environment/EnvironmentListPanel.js +96 -0
  161. package/environment/EnvironmentListPanel.js.map +1 -0
  162. package/environment/EnvironmentVariableEditor.d.ts +43 -0
  163. package/environment/EnvironmentVariableEditor.d.ts.map +1 -0
  164. package/environment/EnvironmentVariableEditor.js +269 -0
  165. package/environment/EnvironmentVariableEditor.js.map +1 -0
  166. package/environment/diffEnvSpec.d.ts +34 -0
  167. package/environment/diffEnvSpec.d.ts.map +1 -0
  168. package/environment/diffEnvSpec.js +44 -0
  169. package/environment/diffEnvSpec.js.map +1 -0
  170. package/environment/index.d.ts +28 -0
  171. package/environment/index.d.ts.map +1 -0
  172. package/environment/index.js +15 -0
  173. package/environment/index.js.map +1 -0
  174. package/environment/useCreateEnvironment.d.ts +43 -0
  175. package/environment/useCreateEnvironment.d.ts.map +1 -0
  176. package/environment/useCreateEnvironment.js +59 -0
  177. package/environment/useCreateEnvironment.js.map +1 -0
  178. package/environment/useEnvironment.d.ts +37 -0
  179. package/environment/useEnvironment.d.ts.map +1 -0
  180. package/environment/useEnvironment.js +69 -0
  181. package/environment/useEnvironment.js.map +1 -0
  182. package/environment/useEnvironmentList.d.ts +31 -0
  183. package/environment/useEnvironmentList.d.ts.map +1 -0
  184. package/environment/useEnvironmentList.js +88 -0
  185. package/environment/useEnvironmentList.js.map +1 -0
  186. package/environment/usePersonalEnvironment.d.ts +100 -0
  187. package/environment/usePersonalEnvironment.d.ts.map +1 -0
  188. package/environment/usePersonalEnvironment.js +168 -0
  189. package/environment/usePersonalEnvironment.js.map +1 -0
  190. package/environment/useRemoveEnvironmentVariables.d.ts +45 -0
  191. package/environment/useRemoveEnvironmentVariables.d.ts.map +1 -0
  192. package/environment/useRemoveEnvironmentVariables.js +57 -0
  193. package/environment/useRemoveEnvironmentVariables.js.map +1 -0
  194. package/environment/useRevealSecretValue.d.ts +66 -0
  195. package/environment/useRevealSecretValue.d.ts.map +1 -0
  196. package/environment/useRevealSecretValue.js +92 -0
  197. package/environment/useRevealSecretValue.js.map +1 -0
  198. package/environment/useSessionEnvPool.d.ts +80 -0
  199. package/environment/useSessionEnvPool.d.ts.map +1 -0
  200. package/environment/useSessionEnvPool.js +72 -0
  201. package/environment/useSessionEnvPool.js.map +1 -0
  202. package/environment/useUpdateEnvironment.d.ts +43 -0
  203. package/environment/useUpdateEnvironment.d.ts.map +1 -0
  204. package/environment/useUpdateEnvironment.js +59 -0
  205. package/environment/useUpdateEnvironment.js.map +1 -0
  206. package/environment/useUpdateEnvironmentVariables.d.ts +53 -0
  207. package/environment/useUpdateEnvironmentVariables.d.ts.map +1 -0
  208. package/environment/useUpdateEnvironmentVariables.js +71 -0
  209. package/environment/useUpdateEnvironmentVariables.js.map +1 -0
  210. package/error/ErrorMessage.d.ts +33 -0
  211. package/error/ErrorMessage.d.ts.map +1 -0
  212. package/error/ErrorMessage.js +60 -0
  213. package/error/ErrorMessage.js.map +1 -0
  214. package/error/SecretFlowErrorGuide.d.ts +41 -0
  215. package/error/SecretFlowErrorGuide.d.ts.map +1 -0
  216. package/error/SecretFlowErrorGuide.js +87 -0
  217. package/error/SecretFlowErrorGuide.js.map +1 -0
  218. package/error/index.d.ts +5 -0
  219. package/error/index.d.ts.map +1 -0
  220. package/error/index.js +3 -0
  221. package/error/index.js.map +1 -0
  222. package/execution/ApprovalCard.d.ts +35 -0
  223. package/execution/ApprovalCard.d.ts.map +1 -0
  224. package/execution/ApprovalCard.js +192 -0
  225. package/execution/ApprovalCard.js.map +1 -0
  226. package/execution/ArtifactCard.d.ts +70 -0
  227. package/execution/ArtifactCard.d.ts.map +1 -0
  228. package/execution/ArtifactCard.js +109 -0
  229. package/execution/ArtifactCard.js.map +1 -0
  230. package/execution/ArtifactPreviewModal.d.ts +77 -0
  231. package/execution/ArtifactPreviewModal.d.ts.map +1 -0
  232. package/execution/ArtifactPreviewModal.js +310 -0
  233. package/execution/ArtifactPreviewModal.js.map +1 -0
  234. package/execution/ArtifactsWidget.d.ts +63 -0
  235. package/execution/ArtifactsWidget.d.ts.map +1 -0
  236. package/execution/ArtifactsWidget.js +61 -0
  237. package/execution/ArtifactsWidget.js.map +1 -0
  238. package/execution/ExecutionCostSummary.d.ts +47 -0
  239. package/execution/ExecutionCostSummary.d.ts.map +1 -0
  240. package/execution/ExecutionCostSummary.js +77 -0
  241. package/execution/ExecutionCostSummary.js.map +1 -0
  242. package/execution/ExecutionPhaseBadge.d.ts +20 -0
  243. package/execution/ExecutionPhaseBadge.d.ts.map +1 -0
  244. package/execution/ExecutionPhaseBadge.js +112 -0
  245. package/execution/ExecutionPhaseBadge.js.map +1 -0
  246. package/execution/ExecutionProgress.d.ts +32 -0
  247. package/execution/ExecutionProgress.d.ts.map +1 -0
  248. package/execution/ExecutionProgress.js +96 -0
  249. package/execution/ExecutionProgress.js.map +1 -0
  250. package/execution/FilePathContext.d.ts +22 -0
  251. package/execution/FilePathContext.d.ts.map +1 -0
  252. package/execution/FilePathContext.js +6 -0
  253. package/execution/FilePathContext.js.map +1 -0
  254. package/execution/FilePathLink.d.ts +26 -0
  255. package/execution/FilePathLink.d.ts.map +1 -0
  256. package/execution/FilePathLink.js +64 -0
  257. package/execution/FilePathLink.js.map +1 -0
  258. package/execution/FollowUpInput.d.ts +55 -0
  259. package/execution/FollowUpInput.d.ts.map +1 -0
  260. package/execution/FollowUpInput.js +95 -0
  261. package/execution/FollowUpInput.js.map +1 -0
  262. package/execution/MessageEntry.d.ts +25 -0
  263. package/execution/MessageEntry.d.ts.map +1 -0
  264. package/execution/MessageEntry.js +46 -0
  265. package/execution/MessageEntry.js.map +1 -0
  266. package/execution/MessageThread.d.ts +88 -0
  267. package/execution/MessageThread.d.ts.map +1 -0
  268. package/execution/MessageThread.js +157 -0
  269. package/execution/MessageThread.js.map +1 -0
  270. package/execution/SessionVariablesInput.d.ts +47 -0
  271. package/execution/SessionVariablesInput.d.ts.map +1 -0
  272. package/execution/SessionVariablesInput.js +80 -0
  273. package/execution/SessionVariablesInput.js.map +1 -0
  274. package/execution/SubAgentSection.d.ts +23 -0
  275. package/execution/SubAgentSection.d.ts.map +1 -0
  276. package/execution/SubAgentSection.js +103 -0
  277. package/execution/SubAgentSection.js.map +1 -0
  278. package/execution/ToolCallDetail.d.ts +32 -0
  279. package/execution/ToolCallDetail.d.ts.map +1 -0
  280. package/execution/ToolCallDetail.js +204 -0
  281. package/execution/ToolCallDetail.js.map +1 -0
  282. package/execution/ToolCallGroup.d.ts +45 -0
  283. package/execution/ToolCallGroup.d.ts.map +1 -0
  284. package/execution/ToolCallGroup.js +160 -0
  285. package/execution/ToolCallGroup.js.map +1 -0
  286. package/execution/ToolCallItem.d.ts +39 -0
  287. package/execution/ToolCallItem.d.ts.map +1 -0
  288. package/execution/ToolCallItem.js +164 -0
  289. package/execution/ToolCallItem.js.map +1 -0
  290. package/execution/__tests__/ExecutionCostSummary.test.d.ts +2 -0
  291. package/execution/__tests__/ExecutionCostSummary.test.d.ts.map +1 -0
  292. package/execution/__tests__/ExecutionCostSummary.test.js +255 -0
  293. package/execution/__tests__/ExecutionCostSummary.test.js.map +1 -0
  294. package/execution/__tests__/execution-phases.test.d.ts +2 -0
  295. package/execution/__tests__/execution-phases.test.d.ts.map +1 -0
  296. package/execution/__tests__/execution-phases.test.js +25 -0
  297. package/execution/__tests__/execution-phases.test.js.map +1 -0
  298. package/execution/__tests__/useExecutionStream.test.d.ts +2 -0
  299. package/execution/__tests__/useExecutionStream.test.d.ts.map +1 -0
  300. package/execution/__tests__/useExecutionStream.test.js +190 -0
  301. package/execution/__tests__/useExecutionStream.test.js.map +1 -0
  302. package/execution/__tests__/useExecutionUsage.test.d.ts +2 -0
  303. package/execution/__tests__/useExecutionUsage.test.d.ts.map +1 -0
  304. package/execution/__tests__/useExecutionUsage.test.js +303 -0
  305. package/execution/__tests__/useExecutionUsage.test.js.map +1 -0
  306. package/execution/artifact-utils.d.ts +58 -0
  307. package/execution/artifact-utils.d.ts.map +1 -0
  308. package/execution/artifact-utils.js +123 -0
  309. package/execution/artifact-utils.js.map +1 -0
  310. package/execution/execution-phases.d.ts +7 -0
  311. package/execution/execution-phases.d.ts.map +1 -0
  312. package/execution/execution-phases.js +15 -0
  313. package/execution/execution-phases.js.map +1 -0
  314. package/execution/file-path-resolver.d.ts +63 -0
  315. package/execution/file-path-resolver.d.ts.map +1 -0
  316. package/execution/file-path-resolver.js +121 -0
  317. package/execution/file-path-resolver.js.map +1 -0
  318. package/execution/index.d.ts +55 -0
  319. package/execution/index.d.ts.map +1 -0
  320. package/execution/index.js +29 -0
  321. package/execution/index.js.map +1 -0
  322. package/execution/tool-categories.d.ts +36 -0
  323. package/execution/tool-categories.d.ts.map +1 -0
  324. package/execution/tool-categories.js +110 -0
  325. package/execution/tool-categories.js.map +1 -0
  326. package/execution/useArtifactContent.d.ts +75 -0
  327. package/execution/useArtifactContent.d.ts.map +1 -0
  328. package/execution/useArtifactContent.js +102 -0
  329. package/execution/useArtifactContent.js.map +1 -0
  330. package/execution/useCreateAgentExecution.d.ts +84 -0
  331. package/execution/useCreateAgentExecution.d.ts.map +1 -0
  332. package/execution/useCreateAgentExecution.js +79 -0
  333. package/execution/useCreateAgentExecution.js.map +1 -0
  334. package/execution/useExecutionArtifacts.d.ts +42 -0
  335. package/execution/useExecutionArtifacts.d.ts.map +1 -0
  336. package/execution/useExecutionArtifacts.js +43 -0
  337. package/execution/useExecutionArtifacts.js.map +1 -0
  338. package/execution/useExecutionStream.d.ts +62 -0
  339. package/execution/useExecutionStream.d.ts.map +1 -0
  340. package/execution/useExecutionStream.js +99 -0
  341. package/execution/useExecutionStream.js.map +1 -0
  342. package/execution/useExecutionUsage.d.ts +45 -0
  343. package/execution/useExecutionUsage.d.ts.map +1 -0
  344. package/execution/useExecutionUsage.js +157 -0
  345. package/execution/useExecutionUsage.js.map +1 -0
  346. package/execution/useSessionVariables.d.ts +102 -0
  347. package/execution/useSessionVariables.d.ts.map +1 -0
  348. package/execution/useSessionVariables.js +102 -0
  349. package/execution/useSessionVariables.js.map +1 -0
  350. package/execution/useSubmitApproval.d.ts +39 -0
  351. package/execution/useSubmitApproval.d.ts.map +1 -0
  352. package/execution/useSubmitApproval.js +62 -0
  353. package/execution/useSubmitApproval.js.map +1 -0
  354. package/github/GitHubRepoPicker.d.ts +24 -0
  355. package/github/GitHubRepoPicker.d.ts.map +1 -0
  356. package/github/GitHubRepoPicker.js +248 -0
  357. package/github/GitHubRepoPicker.js.map +1 -0
  358. package/github/index.d.ts +4 -0
  359. package/github/index.d.ts.map +1 -0
  360. package/github/index.js +4 -0
  361. package/github/index.js.map +1 -0
  362. package/github/useGitHubConnection.d.ts +72 -0
  363. package/github/useGitHubConnection.d.ts.map +1 -0
  364. package/github/useGitHubConnection.js +268 -0
  365. package/github/useGitHubConnection.js.map +1 -0
  366. package/github/useGitHubRepos.d.ts +39 -0
  367. package/github/useGitHubRepos.d.ts.map +1 -0
  368. package/github/useGitHubRepos.js +135 -0
  369. package/github/useGitHubRepos.js.map +1 -0
  370. package/index.d.ts +34 -0
  371. package/index.d.ts.map +1 -1
  372. package/index.js +33 -0
  373. package/index.js.map +1 -1
  374. package/internal/ScrollFade.d.ts +15 -0
  375. package/internal/ScrollFade.d.ts.map +1 -0
  376. package/internal/ScrollFade.js +24 -0
  377. package/internal/ScrollFade.js.map +1 -0
  378. package/internal/markdown-components.d.ts +18 -0
  379. package/internal/markdown-components.d.ts.map +1 -0
  380. package/internal/markdown-components.js +78 -0
  381. package/internal/markdown-components.js.map +1 -0
  382. package/internal/slug.d.ts +32 -0
  383. package/internal/slug.d.ts.map +1 -0
  384. package/internal/slug.js +41 -0
  385. package/internal/slug.js.map +1 -0
  386. package/internal/toError.d.ts +16 -0
  387. package/internal/toError.d.ts.map +1 -0
  388. package/internal/toError.js +22 -0
  389. package/internal/toError.js.map +1 -0
  390. package/internal/useScrollShadows.d.ts +22 -0
  391. package/internal/useScrollShadows.d.ts.map +1 -0
  392. package/internal/useScrollShadows.js +40 -0
  393. package/internal/useScrollShadows.js.map +1 -0
  394. package/library/ResourceCountCard.d.ts +104 -0
  395. package/library/ResourceCountCard.d.ts.map +1 -0
  396. package/library/ResourceCountCard.js +80 -0
  397. package/library/ResourceCountCard.js.map +1 -0
  398. package/library/ResourceListView.d.ts +123 -0
  399. package/library/ResourceListView.d.ts.map +1 -0
  400. package/library/ResourceListView.js +208 -0
  401. package/library/ResourceListView.js.map +1 -0
  402. package/library/ScopeToggle.d.ts +38 -0
  403. package/library/ScopeToggle.d.ts.map +1 -0
  404. package/library/ScopeToggle.js +61 -0
  405. package/library/ScopeToggle.js.map +1 -0
  406. package/library/VisibilityToggle.d.ts +41 -0
  407. package/library/VisibilityToggle.d.ts.map +1 -0
  408. package/library/VisibilityToggle.js +80 -0
  409. package/library/VisibilityToggle.js.map +1 -0
  410. package/library/detect-skill-package.d.ts +79 -0
  411. package/library/detect-skill-package.d.ts.map +1 -0
  412. package/library/detect-skill-package.js +113 -0
  413. package/library/detect-skill-package.js.map +1 -0
  414. package/library/detect-stigmer-resource.d.ts +66 -0
  415. package/library/detect-stigmer-resource.d.ts.map +1 -0
  416. package/library/detect-stigmer-resource.js +77 -0
  417. package/library/detect-stigmer-resource.js.map +1 -0
  418. package/library/index.d.ts +24 -0
  419. package/library/index.d.ts.map +1 -0
  420. package/library/index.js +13 -0
  421. package/library/index.js.map +1 -0
  422. package/library/parse-resource-yaml.d.ts +59 -0
  423. package/library/parse-resource-yaml.d.ts.map +1 -0
  424. package/library/parse-resource-yaml.js +397 -0
  425. package/library/parse-resource-yaml.js.map +1 -0
  426. package/library/serialize-resource-yaml.d.ts +50 -0
  427. package/library/serialize-resource-yaml.d.ts.map +1 -0
  428. package/library/serialize-resource-yaml.js +294 -0
  429. package/library/serialize-resource-yaml.js.map +1 -0
  430. package/library/useApplyResource.d.ts +115 -0
  431. package/library/useApplyResource.d.ts.map +1 -0
  432. package/library/useApplyResource.js +124 -0
  433. package/library/useApplyResource.js.map +1 -0
  434. package/library/useDetectSkillPackage.d.ts +54 -0
  435. package/library/useDetectSkillPackage.d.ts.map +1 -0
  436. package/library/useDetectSkillPackage.js +59 -0
  437. package/library/useDetectSkillPackage.js.map +1 -0
  438. package/library/useDetectStigmerResource.d.ts +30 -0
  439. package/library/useDetectStigmerResource.d.ts.map +1 -0
  440. package/library/useDetectStigmerResource.js +35 -0
  441. package/library/useDetectStigmerResource.js.map +1 -0
  442. package/library/useUpdateVisibility.d.ts +40 -0
  443. package/library/useUpdateVisibility.d.ts.map +1 -0
  444. package/library/useUpdateVisibility.js +67 -0
  445. package/library/useUpdateVisibility.js.map +1 -0
  446. package/mcp-server/McpServerConfigPanel.d.ts +116 -0
  447. package/mcp-server/McpServerConfigPanel.d.ts.map +1 -0
  448. package/mcp-server/McpServerConfigPanel.js +72 -0
  449. package/mcp-server/McpServerConfigPanel.js.map +1 -0
  450. package/mcp-server/McpServerDetailView.d.ts +54 -0
  451. package/mcp-server/McpServerDetailView.d.ts.map +1 -0
  452. package/mcp-server/McpServerDetailView.js +138 -0
  453. package/mcp-server/McpServerDetailView.js.map +1 -0
  454. package/mcp-server/McpServerPicker.d.ts +158 -0
  455. package/mcp-server/McpServerPicker.d.ts.map +1 -0
  456. package/mcp-server/McpServerPicker.js +265 -0
  457. package/mcp-server/McpServerPicker.js.map +1 -0
  458. package/mcp-server/McpToolSelector.d.ts +44 -0
  459. package/mcp-server/McpToolSelector.d.ts.map +1 -0
  460. package/mcp-server/McpToolSelector.js +75 -0
  461. package/mcp-server/McpToolSelector.js.map +1 -0
  462. package/mcp-server/index.d.ts +18 -2
  463. package/mcp-server/index.d.ts.map +1 -1
  464. package/mcp-server/index.js +9 -2
  465. package/mcp-server/index.js.map +1 -1
  466. package/mcp-server/mcpServerSetupReducer.d.ts +138 -0
  467. package/mcp-server/mcpServerSetupReducer.d.ts.map +1 -0
  468. package/mcp-server/mcpServerSetupReducer.js +163 -0
  469. package/mcp-server/mcpServerSetupReducer.js.map +1 -0
  470. package/mcp-server/useMcpServer.d.ts +48 -0
  471. package/mcp-server/useMcpServer.d.ts.map +1 -0
  472. package/mcp-server/useMcpServer.js +82 -0
  473. package/mcp-server/useMcpServer.js.map +1 -0
  474. package/mcp-server/useMcpServerCount.d.ts +49 -0
  475. package/mcp-server/useMcpServerCount.d.ts.map +1 -0
  476. package/mcp-server/useMcpServerCount.js +32 -0
  477. package/mcp-server/useMcpServerCount.js.map +1 -0
  478. package/mcp-server/useMcpServerList.d.ts +62 -0
  479. package/mcp-server/useMcpServerList.d.ts.map +1 -0
  480. package/mcp-server/useMcpServerList.js +38 -0
  481. package/mcp-server/useMcpServerList.js.map +1 -0
  482. package/mcp-server/useMcpServerSearch.d.ts +18 -0
  483. package/mcp-server/useMcpServerSearch.d.ts.map +1 -0
  484. package/mcp-server/useMcpServerSearch.js +23 -0
  485. package/mcp-server/useMcpServerSearch.js.map +1 -0
  486. package/mcp-server/useMcpServerSetup.d.ts +162 -0
  487. package/mcp-server/useMcpServerSetup.d.ts.map +1 -0
  488. package/mcp-server/useMcpServerSetup.js +269 -0
  489. package/mcp-server/useMcpServerSetup.js.map +1 -0
  490. package/models/ModelSelector.d.ts +22 -0
  491. package/models/ModelSelector.d.ts.map +1 -0
  492. package/models/ModelSelector.js +59 -0
  493. package/models/ModelSelector.js.map +1 -0
  494. package/models/index.d.ts +7 -0
  495. package/models/index.d.ts.map +1 -0
  496. package/models/index.js +4 -0
  497. package/models/index.js.map +1 -0
  498. package/models/registry.d.ts +22 -0
  499. package/models/registry.d.ts.map +1 -0
  500. package/models/registry.js +43 -0
  501. package/models/registry.js.map +1 -0
  502. package/models/useModelRegistry.d.ts +18 -0
  503. package/models/useModelRegistry.d.ts.map +1 -0
  504. package/models/useModelRegistry.js +40 -0
  505. package/models/useModelRegistry.js.map +1 -0
  506. package/organization/CreateOrganizationForm.d.ts +28 -0
  507. package/organization/CreateOrganizationForm.d.ts.map +1 -0
  508. package/organization/CreateOrganizationForm.js +91 -0
  509. package/organization/CreateOrganizationForm.js.map +1 -0
  510. package/organization/index.d.ts +5 -0
  511. package/organization/index.d.ts.map +1 -0
  512. package/organization/index.js +3 -0
  513. package/organization/index.js.map +1 -0
  514. package/organization/useCreateOrganization.d.ts +34 -0
  515. package/organization/useCreateOrganization.d.ts.map +1 -0
  516. package/organization/useCreateOrganization.js +50 -0
  517. package/organization/useCreateOrganization.js.map +1 -0
  518. package/package.json +12 -40
  519. package/search/index.d.ts +7 -0
  520. package/search/index.d.ts.map +1 -0
  521. package/search/index.js +4 -0
  522. package/search/index.js.map +1 -0
  523. package/search/useResourceCount.d.ts +42 -0
  524. package/search/useResourceCount.d.ts.map +1 -0
  525. package/search/useResourceCount.js +58 -0
  526. package/search/useResourceCount.js.map +1 -0
  527. package/search/useResourceList.d.ts +48 -0
  528. package/search/useResourceList.d.ts.map +1 -0
  529. package/search/useResourceList.js +73 -0
  530. package/search/useResourceList.js.map +1 -0
  531. package/search/useResourceSearch.d.ts +27 -0
  532. package/search/useResourceSearch.d.ts.map +1 -0
  533. package/search/useResourceSearch.js +55 -0
  534. package/search/useResourceSearch.js.map +1 -0
  535. package/session/__tests__/group-sessions.test.d.ts +2 -0
  536. package/session/__tests__/group-sessions.test.d.ts.map +1 -0
  537. package/session/__tests__/group-sessions.test.js +91 -0
  538. package/session/__tests__/group-sessions.test.js.map +1 -0
  539. package/session/__tests__/useSessionConversation.test.d.ts +2 -0
  540. package/session/__tests__/useSessionConversation.test.d.ts.map +1 -0
  541. package/session/__tests__/useSessionConversation.test.js +209 -0
  542. package/session/__tests__/useSessionConversation.test.js.map +1 -0
  543. package/session/group-sessions.d.ts +20 -0
  544. package/session/group-sessions.d.ts.map +1 -0
  545. package/session/group-sessions.js +61 -0
  546. package/session/group-sessions.js.map +1 -0
  547. package/session/index.d.ts +17 -6
  548. package/session/index.d.ts.map +1 -1
  549. package/session/index.js +10 -5
  550. package/session/index.js.map +1 -1
  551. package/session/useAgentRefFromSession.d.ts +28 -0
  552. package/session/useAgentRefFromSession.d.ts.map +1 -0
  553. package/session/useAgentRefFromSession.js +73 -0
  554. package/session/useAgentRefFromSession.js.map +1 -0
  555. package/session/useCreateSession.d.ts +73 -0
  556. package/session/useCreateSession.d.ts.map +1 -0
  557. package/session/useCreateSession.js +87 -0
  558. package/session/useCreateSession.js.map +1 -0
  559. package/session/useSession.d.ts +17 -0
  560. package/session/useSession.d.ts.map +1 -0
  561. package/session/useSession.js +46 -0
  562. package/session/useSession.js.map +1 -0
  563. package/session/useSessionConversation.d.ts +151 -0
  564. package/session/useSessionConversation.d.ts.map +1 -0
  565. package/session/useSessionConversation.js +282 -0
  566. package/session/useSessionConversation.js.map +1 -0
  567. package/session/useSessionExecutions.d.ts +20 -0
  568. package/session/useSessionExecutions.d.ts.map +1 -0
  569. package/session/useSessionExecutions.js +57 -0
  570. package/session/useSessionExecutions.js.map +1 -0
  571. package/session/useSessionList.d.ts +25 -0
  572. package/session/useSessionList.d.ts.map +1 -0
  573. package/session/useSessionList.js +57 -0
  574. package/session/useSessionList.js.map +1 -0
  575. package/session/useUpdateSession.d.ts +22 -0
  576. package/session/useUpdateSession.d.ts.map +1 -0
  577. package/session/useUpdateSession.js +38 -0
  578. package/session/useUpdateSession.js.map +1 -0
  579. package/skill/SkillDetailView.d.ts +62 -0
  580. package/skill/SkillDetailView.d.ts.map +1 -0
  581. package/skill/SkillDetailView.js +157 -0
  582. package/skill/SkillDetailView.js.map +1 -0
  583. package/skill/SkillPicker.d.ts +26 -0
  584. package/skill/SkillPicker.d.ts.map +1 -0
  585. package/skill/SkillPicker.js +102 -0
  586. package/skill/SkillPicker.js.map +1 -0
  587. package/skill/index.d.ts +12 -2
  588. package/skill/index.d.ts.map +1 -1
  589. package/skill/index.js +6 -2
  590. package/skill/index.js.map +1 -1
  591. package/skill/useSkill.d.ts +49 -0
  592. package/skill/useSkill.d.ts.map +1 -0
  593. package/skill/useSkill.js +83 -0
  594. package/skill/useSkill.js.map +1 -0
  595. package/skill/useSkillCount.d.ts +49 -0
  596. package/skill/useSkillCount.d.ts.map +1 -0
  597. package/skill/useSkillCount.js +32 -0
  598. package/skill/useSkillCount.js.map +1 -0
  599. package/skill/useSkillList.d.ts +62 -0
  600. package/skill/useSkillList.d.ts.map +1 -0
  601. package/skill/useSkillList.js +38 -0
  602. package/skill/useSkillList.js.map +1 -0
  603. package/skill/useSkillSearch.d.ts +18 -0
  604. package/skill/useSkillSearch.d.ts.map +1 -0
  605. package/skill/useSkillSearch.js +23 -0
  606. package/skill/useSkillSearch.js.map +1 -0
  607. package/src/__tests__/hooks.test.tsx +28 -0
  608. package/src/agent/AgentDetailView.tsx +738 -0
  609. package/src/agent/AgentEnvForm.tsx +113 -0
  610. package/src/agent/AgentPicker.tsx +342 -0
  611. package/src/agent/agentSetupReducer.ts +234 -0
  612. package/src/agent/index.ts +43 -11
  613. package/src/agent/useAgent.ts +103 -0
  614. package/src/agent/useAgentCount.ts +68 -0
  615. package/src/agent/useAgentList.ts +84 -0
  616. package/src/agent/useAgentSearch.ts +43 -0
  617. package/src/agent/useAgentSetup.ts +434 -0
  618. package/src/agent/useDefaultAgent.ts +77 -0
  619. package/src/agent-instance/buildPersonalInstanceInput.ts +40 -0
  620. package/src/agent-instance/index.ts +11 -0
  621. package/src/agent-instance/useAgentInstance.ts +87 -0
  622. package/src/agent-instance/useAgentInstanceList.ts +99 -0
  623. package/src/agent-instance/useCreateAgentInstance.ts +75 -0
  624. package/src/agent-instance/usePersonalAgentInstance.ts +185 -0
  625. package/src/api-key/ApiKeyCreatedAlert.tsx +184 -0
  626. package/src/api-key/ApiKeyListPanel.tsx +359 -0
  627. package/src/api-key/CreateApiKeyForm.tsx +250 -0
  628. package/src/api-key/index.ts +12 -0
  629. package/src/api-key/useApiKeyList.ts +68 -0
  630. package/src/api-key/useCreateApiKey.ts +71 -0
  631. package/src/api-key/useDeleteApiKey.ts +57 -0
  632. package/src/attachment/AttachmentChipList.tsx +189 -0
  633. package/src/attachment/attachment-utils.ts +114 -0
  634. package/src/attachment/index.ts +17 -0
  635. package/src/attachment/useAttachments.ts +293 -0
  636. package/src/composer/ComposerToolbar.tsx +169 -0
  637. package/src/composer/ConfigureMenu.tsx +237 -0
  638. package/src/composer/ContextChip.tsx +104 -0
  639. package/src/composer/ContextPopover.tsx +54 -0
  640. package/src/composer/SessionComposer.tsx +1188 -0
  641. package/src/composer/icons.tsx +253 -0
  642. package/src/composer/index.ts +8 -0
  643. package/src/composer/useComposer.ts +163 -0
  644. package/src/environment/CreateEnvironmentForm.tsx +188 -0
  645. package/src/environment/EnvVarForm.tsx +475 -0
  646. package/src/environment/EnvironmentListPanel.tsx +258 -0
  647. package/src/environment/EnvironmentVariableEditor.tsx +811 -0
  648. package/src/environment/diffEnvSpec.ts +50 -0
  649. package/src/environment/index.ts +43 -0
  650. package/src/environment/useCreateEnvironment.ts +74 -0
  651. package/src/environment/useEnvironment.ts +89 -0
  652. package/src/environment/useEnvironmentList.ts +112 -0
  653. package/src/environment/usePersonalEnvironment.ts +285 -0
  654. package/src/environment/useRemoveEnvironmentVariables.ts +86 -0
  655. package/src/environment/useRevealSecretValue.ts +141 -0
  656. package/src/environment/useSessionEnvPool.ts +151 -0
  657. package/src/environment/useUpdateEnvironment.ts +74 -0
  658. package/src/environment/useUpdateEnvironmentVariables.ts +106 -0
  659. package/src/error/ErrorMessage.tsx +225 -0
  660. package/src/error/SecretFlowErrorGuide.tsx +189 -0
  661. package/src/error/index.ts +5 -0
  662. package/src/execution/ApprovalCard.tsx +499 -0
  663. package/src/execution/ArtifactCard.tsx +275 -0
  664. package/src/execution/ArtifactPreviewModal.tsx +942 -0
  665. package/src/execution/ArtifactsWidget.tsx +128 -0
  666. package/src/execution/ExecutionCostSummary.tsx +172 -0
  667. package/src/execution/ExecutionPhaseBadge.tsx +223 -0
  668. package/src/execution/ExecutionProgress.tsx +191 -0
  669. package/src/execution/FilePathContext.tsx +32 -0
  670. package/src/execution/FilePathLink.tsx +147 -0
  671. package/src/execution/FollowUpInput.tsx +220 -0
  672. package/src/execution/MessageEntry.tsx +120 -0
  673. package/src/execution/MessageThread.tsx +343 -0
  674. package/src/execution/SessionVariablesInput.tsx +374 -0
  675. package/src/execution/SubAgentSection.tsx +243 -0
  676. package/src/execution/ToolCallDetail.tsx +452 -0
  677. package/src/execution/ToolCallGroup.tsx +342 -0
  678. package/src/execution/ToolCallItem.tsx +426 -0
  679. package/src/execution/__tests__/ExecutionCostSummary.test.tsx +416 -0
  680. package/src/execution/__tests__/execution-phases.test.ts +31 -0
  681. package/src/execution/__tests__/useExecutionStream.test.tsx +242 -0
  682. package/src/execution/__tests__/useExecutionUsage.test.tsx +408 -0
  683. package/src/execution/artifact-utils.ts +136 -0
  684. package/src/execution/execution-phases.ts +16 -0
  685. package/src/execution/file-path-resolver.ts +171 -0
  686. package/src/execution/index.ts +97 -0
  687. package/src/execution/tool-categories.ts +171 -0
  688. package/src/execution/useArtifactContent.ts +156 -0
  689. package/src/execution/useCreateAgentExecution.ts +137 -0
  690. package/src/execution/useExecutionArtifacts.ts +58 -0
  691. package/src/execution/useExecutionStream.ts +149 -0
  692. package/src/execution/useExecutionUsage.ts +213 -0
  693. package/src/execution/useSessionVariables.ts +189 -0
  694. package/src/execution/useSubmitApproval.ts +98 -0
  695. package/src/github/GitHubRepoPicker.tsx +568 -0
  696. package/src/github/index.ts +19 -0
  697. package/src/github/useGitHubConnection.ts +368 -0
  698. package/src/github/useGitHubRepos.ts +197 -0
  699. package/src/index.ts +392 -0
  700. package/src/internal/ScrollFade.tsx +29 -0
  701. package/src/internal/markdown-components.tsx +197 -0
  702. package/src/internal/slug.ts +41 -0
  703. package/src/internal/toError.ts +19 -0
  704. package/src/internal/useScrollShadows.ts +54 -0
  705. package/src/library/ResourceCountCard.tsx +187 -0
  706. package/src/library/ResourceListView.tsx +698 -0
  707. package/src/library/ScopeToggle.tsx +121 -0
  708. package/src/library/VisibilityToggle.tsx +205 -0
  709. package/src/library/detect-skill-package.ts +162 -0
  710. package/src/library/detect-stigmer-resource.ts +130 -0
  711. package/src/library/index.ts +51 -0
  712. package/src/library/parse-resource-yaml.ts +611 -0
  713. package/src/library/serialize-resource-yaml.ts +407 -0
  714. package/src/library/useApplyResource.ts +211 -0
  715. package/src/library/useDetectSkillPackage.ts +91 -0
  716. package/src/library/useDetectStigmerResource.ts +45 -0
  717. package/src/library/useUpdateVisibility.ts +94 -0
  718. package/src/mcp-server/McpServerConfigPanel.tsx +265 -0
  719. package/src/mcp-server/McpServerDetailView.tsx +606 -0
  720. package/src/mcp-server/McpServerPicker.tsx +857 -0
  721. package/src/mcp-server/McpToolSelector.tsx +243 -0
  722. package/src/mcp-server/index.ts +44 -3
  723. package/src/mcp-server/mcpServerSetupReducer.ts +308 -0
  724. package/src/mcp-server/useMcpServer.ts +103 -0
  725. package/src/mcp-server/useMcpServerCount.ts +68 -0
  726. package/src/mcp-server/useMcpServerList.ts +84 -0
  727. package/src/mcp-server/useMcpServerSearch.ts +38 -0
  728. package/src/mcp-server/useMcpServerSetup.ts +487 -0
  729. package/src/models/ModelSelector.tsx +132 -0
  730. package/src/models/index.ts +6 -0
  731. package/src/models/registry.ts +60 -0
  732. package/src/models/useModelRegistry.ts +58 -0
  733. package/src/organization/CreateOrganizationForm.tsx +269 -0
  734. package/src/organization/index.ts +4 -0
  735. package/src/organization/useCreateOrganization.ts +65 -0
  736. package/src/search/index.ts +18 -0
  737. package/src/search/useResourceCount.ts +102 -0
  738. package/src/search/useResourceList.ts +128 -0
  739. package/src/search/useResourceSearch.ts +90 -0
  740. package/src/session/__tests__/group-sessions.test.ts +113 -0
  741. package/src/session/__tests__/useSessionConversation.test.tsx +305 -0
  742. package/src/session/group-sessions.ts +80 -0
  743. package/src/session/index.ts +33 -10
  744. package/src/session/useAgentRefFromSession.ts +94 -0
  745. package/src/session/useCreateSession.ts +142 -0
  746. package/src/session/useSession.ts +60 -0
  747. package/src/session/useSessionConversation.ts +515 -0
  748. package/src/session/useSessionExecutions.ts +77 -0
  749. package/src/session/useSessionList.ts +90 -0
  750. package/src/session/useUpdateSession.ts +54 -0
  751. package/src/skill/SkillDetailView.tsx +503 -0
  752. package/src/skill/SkillPicker.tsx +331 -0
  753. package/src/skill/index.ts +23 -3
  754. package/src/skill/useSkill.ts +105 -0
  755. package/src/skill/useSkillCount.ts +68 -0
  756. package/src/skill/useSkillList.ts +84 -0
  757. package/src/skill/useSkillSearch.ts +38 -0
  758. package/src/styles.css +2 -0
  759. package/src/workspace/FolderBrowser.tsx +568 -0
  760. package/src/workspace/WorkspaceEditor.tsx +480 -0
  761. package/src/workspace/WorkspaceSummary.tsx +109 -0
  762. package/src/workspace/index.ts +17 -0
  763. package/src/workspace/useFolderListing.ts +126 -0
  764. package/src/workspace/useWorkspaceEntries.ts +98 -0
  765. package/styles.css +1 -1
  766. package/workspace/FolderBrowser.d.ts +26 -0
  767. package/workspace/FolderBrowser.d.ts.map +1 -0
  768. package/workspace/FolderBrowser.js +179 -0
  769. package/workspace/FolderBrowser.js.map +1 -0
  770. package/workspace/WorkspaceEditor.d.ts +30 -0
  771. package/workspace/WorkspaceEditor.d.ts.map +1 -0
  772. package/workspace/WorkspaceEditor.js +116 -0
  773. package/workspace/WorkspaceEditor.js.map +1 -0
  774. package/workspace/WorkspaceSummary.d.ts +30 -0
  775. package/workspace/WorkspaceSummary.d.ts.map +1 -0
  776. package/workspace/WorkspaceSummary.js +53 -0
  777. package/workspace/WorkspaceSummary.js.map +1 -0
  778. package/workspace/index.d.ts +11 -0
  779. package/workspace/index.d.ts.map +1 -0
  780. package/workspace/index.js +6 -0
  781. package/workspace/index.js.map +1 -0
  782. package/workspace/useFolderListing.d.ts +35 -0
  783. package/workspace/useFolderListing.d.ts.map +1 -0
  784. package/workspace/useFolderListing.js +86 -0
  785. package/workspace/useFolderListing.js.map +1 -0
  786. package/workspace/useWorkspaceEntries.d.ts +28 -0
  787. package/workspace/useWorkspaceEntries.d.ts.map +1 -0
  788. package/workspace/useWorkspaceEntries.js +66 -0
  789. package/workspace/useWorkspaceEntries.js.map +1 -0
  790. package/agent/components/AgentCard.d.ts +0 -9
  791. package/agent/components/AgentCard.d.ts.map +0 -1
  792. package/agent/components/AgentCard.js +0 -26
  793. package/agent/components/AgentCard.js.map +0 -1
  794. package/agent/components/AgentOverview.d.ts +0 -7
  795. package/agent/components/AgentOverview.d.ts.map +0 -1
  796. package/agent/components/AgentOverview.js +0 -36
  797. package/agent/components/AgentOverview.js.map +0 -1
  798. package/agent/components/AgentPicker.d.ts +0 -17
  799. package/agent/components/AgentPicker.d.ts.map +0 -1
  800. package/agent/components/AgentPicker.js +0 -86
  801. package/agent/components/AgentPicker.js.map +0 -1
  802. package/agent/hooks/useAgentSearch.d.ts +0 -28
  803. package/agent/hooks/useAgentSearch.d.ts.map +0 -1
  804. package/agent/hooks/useAgentSearch.js +0 -63
  805. package/agent/hooks/useAgentSearch.js.map +0 -1
  806. package/agent-execution/components/ApprovalControls.d.ts +0 -10
  807. package/agent-execution/components/ApprovalControls.d.ts.map +0 -1
  808. package/agent-execution/components/ApprovalControls.js +0 -19
  809. package/agent-execution/components/ApprovalControls.js.map +0 -1
  810. package/agent-execution/components/ExecutionStatus.d.ts +0 -8
  811. package/agent-execution/components/ExecutionStatus.d.ts.map +0 -1
  812. package/agent-execution/components/ExecutionStatus.js +0 -14
  813. package/agent-execution/components/ExecutionStatus.js.map +0 -1
  814. package/agent-execution/components/ExecutionStream.d.ts +0 -16
  815. package/agent-execution/components/ExecutionStream.d.ts.map +0 -1
  816. package/agent-execution/components/ExecutionStream.js +0 -39
  817. package/agent-execution/components/ExecutionStream.js.map +0 -1
  818. package/agent-execution/components/MessageEntry.d.ts +0 -17
  819. package/agent-execution/components/MessageEntry.d.ts.map +0 -1
  820. package/agent-execution/components/MessageEntry.js +0 -36
  821. package/agent-execution/components/MessageEntry.js.map +0 -1
  822. package/agent-execution/components/MessageInput.d.ts +0 -10
  823. package/agent-execution/components/MessageInput.d.ts.map +0 -1
  824. package/agent-execution/components/MessageInput.js +0 -27
  825. package/agent-execution/components/MessageInput.js.map +0 -1
  826. package/agent-execution/components/OutputBlock.d.ts +0 -9
  827. package/agent-execution/components/OutputBlock.d.ts.map +0 -1
  828. package/agent-execution/components/OutputBlock.js +0 -15
  829. package/agent-execution/components/OutputBlock.js.map +0 -1
  830. package/agent-execution/components/SubAgentCard.d.ts +0 -11
  831. package/agent-execution/components/SubAgentCard.d.ts.map +0 -1
  832. package/agent-execution/components/SubAgentCard.js +0 -19
  833. package/agent-execution/components/SubAgentCard.js.map +0 -1
  834. package/agent-execution/components/ToolCallCard.d.ts +0 -11
  835. package/agent-execution/components/ToolCallCard.d.ts.map +0 -1
  836. package/agent-execution/components/ToolCallCard.js +0 -25
  837. package/agent-execution/components/ToolCallCard.js.map +0 -1
  838. package/agent-execution/helpers.d.ts +0 -35
  839. package/agent-execution/helpers.d.ts.map +0 -1
  840. package/agent-execution/helpers.js +0 -157
  841. package/agent-execution/helpers.js.map +0 -1
  842. package/agent-execution/hooks/useAgentExecution.d.ts +0 -21
  843. package/agent-execution/hooks/useAgentExecution.d.ts.map +0 -1
  844. package/agent-execution/hooks/useAgentExecution.js +0 -99
  845. package/agent-execution/hooks/useAgentExecution.js.map +0 -1
  846. package/agent-execution/hooks/useApproval.d.ts +0 -12
  847. package/agent-execution/hooks/useApproval.d.ts.map +0 -1
  848. package/agent-execution/hooks/useApproval.js +0 -32
  849. package/agent-execution/hooks/useApproval.js.map +0 -1
  850. package/agent-execution/index.d.ts +0 -14
  851. package/agent-execution/index.d.ts.map +0 -1
  852. package/agent-execution/index.js +0 -15
  853. package/agent-execution/index.js.map +0 -1
  854. package/catalog/components/ResourceSearchCard.d.ts +0 -23
  855. package/catalog/components/ResourceSearchCard.d.ts.map +0 -1
  856. package/catalog/components/ResourceSearchCard.js +0 -36
  857. package/catalog/components/ResourceSearchCard.js.map +0 -1
  858. package/catalog/index.d.ts +0 -4
  859. package/catalog/index.d.ts.map +0 -1
  860. package/catalog/index.js +0 -5
  861. package/catalog/index.js.map +0 -1
  862. package/catalog/internal/time.d.ts +0 -13
  863. package/catalog/internal/time.d.ts.map +0 -1
  864. package/catalog/internal/time.js +0 -41
  865. package/catalog/internal/time.js.map +0 -1
  866. package/internal/badge.d.ts +0 -8
  867. package/internal/badge.d.ts.map +0 -1
  868. package/internal/badge.js +0 -34
  869. package/internal/badge.js.map +0 -1
  870. package/internal/button.d.ts +0 -9
  871. package/internal/button.d.ts.map +0 -1
  872. package/internal/button.js +0 -36
  873. package/internal/button.js.map +0 -1
  874. package/internal/collapsible.d.ts +0 -6
  875. package/internal/collapsible.d.ts.map +0 -1
  876. package/internal/collapsible.js +0 -14
  877. package/internal/collapsible.js.map +0 -1
  878. package/internal/section.d.ts +0 -8
  879. package/internal/section.d.ts.map +0 -1
  880. package/internal/section.js +0 -6
  881. package/internal/section.js.map +0 -1
  882. package/internal/textarea.d.ts +0 -4
  883. package/internal/textarea.d.ts.map +0 -1
  884. package/internal/textarea.js +0 -9
  885. package/internal/textarea.js.map +0 -1
  886. package/mcp-server/hooks/useMcpServerSearch.d.ts +0 -25
  887. package/mcp-server/hooks/useMcpServerSearch.d.ts.map +0 -1
  888. package/mcp-server/hooks/useMcpServerSearch.js +0 -57
  889. package/mcp-server/hooks/useMcpServerSearch.js.map +0 -1
  890. package/session/components/AgentSessionHistory.d.ts +0 -8
  891. package/session/components/AgentSessionHistory.d.ts.map +0 -1
  892. package/session/components/AgentSessionHistory.js +0 -11
  893. package/session/components/AgentSessionHistory.js.map +0 -1
  894. package/session/components/SessionCard.d.ts +0 -8
  895. package/session/components/SessionCard.d.ts.map +0 -1
  896. package/session/components/SessionCard.js +0 -57
  897. package/session/components/SessionCard.js.map +0 -1
  898. package/session/hooks/useAgentSessionList.d.ts +0 -21
  899. package/session/hooks/useAgentSessionList.d.ts.map +0 -1
  900. package/session/hooks/useAgentSessionList.js +0 -90
  901. package/session/hooks/useAgentSessionList.js.map +0 -1
  902. package/skill/hooks/useSkillSearch.d.ts +0 -25
  903. package/skill/hooks/useSkillSearch.d.ts.map +0 -1
  904. package/skill/hooks/useSkillSearch.js +0 -57
  905. package/skill/hooks/useSkillSearch.js.map +0 -1
  906. package/src/agent/components/AgentCard.tsx +0 -125
  907. package/src/agent/components/AgentOverview.tsx +0 -209
  908. package/src/agent/components/AgentPicker.tsx +0 -255
  909. package/src/agent/hooks/useAgentSearch.ts +0 -94
  910. package/src/agent-execution/components/ApprovalControls.tsx +0 -99
  911. package/src/agent-execution/components/ExecutionStatus.tsx +0 -33
  912. package/src/agent-execution/components/ExecutionStream.tsx +0 -148
  913. package/src/agent-execution/components/MessageEntry.tsx +0 -125
  914. package/src/agent-execution/components/MessageInput.tsx +0 -70
  915. package/src/agent-execution/components/OutputBlock.tsx +0 -43
  916. package/src/agent-execution/components/SubAgentCard.tsx +0 -138
  917. package/src/agent-execution/components/ToolCallCard.tsx +0 -153
  918. package/src/agent-execution/helpers.ts +0 -193
  919. package/src/agent-execution/hooks/useAgentExecution.ts +0 -147
  920. package/src/agent-execution/hooks/useApproval.ts +0 -56
  921. package/src/agent-execution/index.ts +0 -46
  922. package/src/catalog/components/ResourceSearchCard.tsx +0 -137
  923. package/src/catalog/index.ts +0 -6
  924. package/src/catalog/internal/time.ts +0 -40
  925. package/src/internal/badge.tsx +0 -52
  926. package/src/internal/button.tsx +0 -60
  927. package/src/internal/collapsible.tsx +0 -21
  928. package/src/internal/section.tsx +0 -18
  929. package/src/internal/textarea.tsx +0 -23
  930. package/src/mcp-server/hooks/useMcpServerSearch.ts +0 -79
  931. package/src/session/components/AgentSessionHistory.tsx +0 -109
  932. package/src/session/components/SessionCard.tsx +0 -113
  933. package/src/session/hooks/useAgentSessionList.ts +0 -117
  934. package/src/skill/hooks/useSkillSearch.ts +0 -79
@@ -0,0 +1,38 @@
1
+ import type { ResourceListScope } from "../search";
2
+ export interface ScopeToggleProps {
3
+ /** The currently selected scope. */
4
+ readonly value: ResourceListScope;
5
+ /** Called when the user selects a different scope. */
6
+ readonly onChange: (scope: ResourceListScope) => void;
7
+ /** Disables all interaction. */
8
+ readonly disabled?: boolean;
9
+ /** Additional CSS classes applied to the root element. */
10
+ readonly className?: string;
11
+ }
12
+ /**
13
+ * Segmented control for toggling resource scope between "Org"
14
+ * (only the current organization's resources) and "All"
15
+ * (including public and platform resources).
16
+ *
17
+ * Designed for use in Library list headers alongside a search input.
18
+ * The component is controlled — the consumer owns the `value` state
19
+ * and handles persistence (e.g., localStorage).
20
+ *
21
+ * Implements the WAI-ARIA Radio Group pattern with roving tabindex
22
+ * for keyboard navigation: Arrow Left/Right moves focus and selects,
23
+ * Tab enters/exits the group.
24
+ *
25
+ * All visual properties flow through `--stgm-*` tokens.
26
+ *
27
+ * @example
28
+ * ```tsx
29
+ * const [scope, setScope] = useState<ResourceListScope>("org");
30
+ *
31
+ * <ScopeToggle value={scope} onChange={setScope} />
32
+ * ```
33
+ *
34
+ * @see {@link ResourceListScope} for the type used by data hooks
35
+ * @see {@link useAgentList}, {@link useSkillList}, {@link useMcpServerList}
36
+ */
37
+ export declare function ScopeToggle({ value, onChange, disabled, className, }: ScopeToggleProps): import("react/jsx-runtime").JSX.Element;
38
+ //# sourceMappingURL=ScopeToggle.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ScopeToggle.d.ts","sourceRoot":"","sources":["../../src/library/ScopeToggle.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAC;AAEnD,MAAM,WAAW,gBAAgB;IAC/B,oCAAoC;IACpC,QAAQ,CAAC,KAAK,EAAE,iBAAiB,CAAC;IAClC,sDAAsD;IACtD,QAAQ,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE,iBAAiB,KAAK,IAAI,CAAC;IACtD,gCAAgC;IAChC,QAAQ,CAAC,QAAQ,CAAC,EAAE,OAAO,CAAC;IAC5B,0DAA0D;IAC1D,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;CAC7B;AAUD;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,wBAAgB,WAAW,CAAC,EAC1B,KAAK,EACL,QAAQ,EACR,QAAgB,EAChB,SAAS,GACV,EAAE,gBAAgB,2CAiElB"}
@@ -0,0 +1,61 @@
1
+ "use client";
2
+ import { jsx as _jsx } from "react/jsx-runtime";
3
+ import { useCallback, useRef } from "react";
4
+ import { cn } from "@stigmer/theme";
5
+ const SCOPE_OPTIONS = [
6
+ { value: "org", label: "Org" },
7
+ { value: "all", label: "All" },
8
+ ];
9
+ /**
10
+ * Segmented control for toggling resource scope between "Org"
11
+ * (only the current organization's resources) and "All"
12
+ * (including public and platform resources).
13
+ *
14
+ * Designed for use in Library list headers alongside a search input.
15
+ * The component is controlled — the consumer owns the `value` state
16
+ * and handles persistence (e.g., localStorage).
17
+ *
18
+ * Implements the WAI-ARIA Radio Group pattern with roving tabindex
19
+ * for keyboard navigation: Arrow Left/Right moves focus and selects,
20
+ * Tab enters/exits the group.
21
+ *
22
+ * All visual properties flow through `--stgm-*` tokens.
23
+ *
24
+ * @example
25
+ * ```tsx
26
+ * const [scope, setScope] = useState<ResourceListScope>("org");
27
+ *
28
+ * <ScopeToggle value={scope} onChange={setScope} />
29
+ * ```
30
+ *
31
+ * @see {@link ResourceListScope} for the type used by data hooks
32
+ * @see {@link useAgentList}, {@link useSkillList}, {@link useMcpServerList}
33
+ */
34
+ export function ScopeToggle({ value, onChange, disabled = false, className, }) {
35
+ const optionRefs = useRef([]);
36
+ const handleKeyDown = useCallback((e, index) => {
37
+ let nextIndex = null;
38
+ if (e.key === "ArrowRight" || e.key === "ArrowDown") {
39
+ e.preventDefault();
40
+ nextIndex = (index + 1) % SCOPE_OPTIONS.length;
41
+ }
42
+ else if (e.key === "ArrowLeft" || e.key === "ArrowUp") {
43
+ e.preventDefault();
44
+ nextIndex =
45
+ (index - 1 + SCOPE_OPTIONS.length) % SCOPE_OPTIONS.length;
46
+ }
47
+ if (nextIndex !== null) {
48
+ optionRefs.current[nextIndex]?.focus();
49
+ onChange(SCOPE_OPTIONS[nextIndex].value);
50
+ }
51
+ }, [onChange]);
52
+ return (_jsx("div", { role: "radiogroup", "aria-label": "Resource scope", "aria-disabled": disabled || undefined, className: cn("inline-flex rounded-md bg-muted p-0.5", disabled && "pointer-events-none opacity-50", className), children: SCOPE_OPTIONS.map((option, index) => {
53
+ const isSelected = value === option.value;
54
+ return (_jsx("button", { ref: (el) => {
55
+ optionRefs.current[index] = el;
56
+ }, type: "button", role: "radio", "aria-checked": isSelected, tabIndex: isSelected ? 0 : -1, disabled: disabled, onClick: () => onChange(option.value), onKeyDown: (e) => handleKeyDown(e, index), className: cn("cursor-pointer rounded-sm px-3 py-1 text-xs font-medium transition-colors", "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring", isSelected
57
+ ? "bg-background text-foreground shadow-sm"
58
+ : "text-muted-foreground hover:text-foreground"), children: option.label }, option.value));
59
+ }) }));
60
+ }
61
+ //# sourceMappingURL=ScopeToggle.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ScopeToggle.js","sourceRoot":"","sources":["../../src/library/ScopeToggle.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAEb,OAAO,EAAE,WAAW,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,EAAE,EAAE,EAAE,MAAM,gBAAgB,CAAC;AAcpC,MAAM,aAAa,GAGb;IACJ,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE;IAC9B,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE;CAC/B,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,MAAM,UAAU,WAAW,CAAC,EAC1B,KAAK,EACL,QAAQ,EACR,QAAQ,GAAG,KAAK,EAChB,SAAS,GACQ;IACjB,MAAM,UAAU,GAAG,MAAM,CAA+B,EAAE,CAAC,CAAC;IAE5D,MA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,EAAC,QAAQ,EACb,IAAI,EAAC,OAAO,kBACE,UAAU,EACxB,QAAQ,EAAE,UAAU,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EAC7B,QAAQ,EAAE,QAAQ,EAClB,OAAO,EAAE,GAAG,EAAE,CAAC,QAAQ,CAAC,MAAM,CAAC,KAAK,CAAC,EACrC,SAAS,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,aAAa,CAAC,CAAC,EAAE,KAAK,CAAC,EACzC,SAAS,EAAE,EAAE,CACX,2EAA2E,EAC3E,yEAAyE,EACzE,UAAU;oBACR,CAAC,CAAC,yCAAyC;oBAC3C,CAAC,CAAC,6CAA6C,CAClD,YAEA,MAAM,CAAC,KAAK,IAnBR,MAAM,CAAC,KAAK,CAoBV,CACV,CAAC;QACJ,CAAC,CAAC,GACE,CACP,CAAC;AACJ,CAAC"}
@@ -0,0 +1,41 @@
1
+ import { ApiResourceVisibility } from "@stigmer/protos/ai/stigmer/commons/apiresource/enum_pb";
2
+ export interface VisibilityToggleProps {
3
+ /** Current visibility of the resource. */
4
+ readonly visibility: ApiResourceVisibility;
5
+ /**
6
+ * Called when the user confirms a visibility change.
7
+ * The toggle shows an inline confirmation before invoking this
8
+ * callback when switching to PUBLIC.
9
+ */
10
+ readonly onVisibilityChange: (v: ApiResourceVisibility) => void;
11
+ /** Shows a spinner/disabled state while the RPC is in flight. */
12
+ readonly isPending?: boolean;
13
+ /** Disables all interaction (e.g., when the user lacks can_edit). */
14
+ readonly disabled?: boolean;
15
+ /** Additional CSS classes applied to the root element. */
16
+ readonly className?: string;
17
+ }
18
+ /**
19
+ * Segmented control for toggling resource visibility between
20
+ * Private and Public.
21
+ *
22
+ * Switching to PUBLIC shows a brief inline confirmation prompt
23
+ * since making a resource publicly visible is a consequential
24
+ * action. Switching to PRIVATE applies immediately without
25
+ * confirmation (revoking access is always safe).
26
+ *
27
+ * Follows the same visual pattern as {@link ScopeToggle} —
28
+ * WAI-ARIA Radio Group with roving tabindex. All visual
29
+ * properties flow through `--stgm-*` design tokens.
30
+ *
31
+ * @example
32
+ * ```tsx
33
+ * <VisibilityToggle
34
+ * visibility={skill.metadata.visibility}
35
+ * onVisibilityChange={handleVisibilityChange}
36
+ * isPending={isPending}
37
+ * />
38
+ * ```
39
+ */
40
+ export declare function VisibilityToggle({ visibility, onVisibilityChange, isPending, disabled, className, }: VisibilityToggleProps): import("react/jsx-runtime").JSX.Element;
41
+ //# sourceMappingURL=VisibilityToggle.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VisibilityToggle.d.ts","sourceRoot":"","sources":["../../src/library/VisibilityToggle.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,qBAAqB,EAAE,MAAM,wDAAwD,CAAC;AAE/F,MAAM,WAAW,qBAAqB;IACpC,0CAA0C;IAC1C,QAAQ,CAAC,UAAU,EAAE,qBAAqB,CAAC;IAC3C;;;;OAIG;IACH,QAAQ,CAAC,kBAAkB,EAAE,CAAC,CAAC,EAAE,qBAAqB,KAAK,IAAI,CAAC;IAChE,iEAAiE;IACjE,QAAQ,CAAC,SAAS,CAAC,EAAE,OAAO,CAAC;IAC7B,qEAAqE;IACrE,QAAQ,CAAC,QAAQ,CAAC,EAAE,OAAO,CAAC;IAC5B,0DAA0D;IAC1D,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;CAC7B;AAUD;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,gBAAgB,CAAC,EAC/B,UAAU,EACV,kBAAkB,EAClB,SAAiB,EACjB,QAAgB,EAChB,SAAS,GACV,EAAE,qBAAqB,2CAiJvB"}
@@ -0,0 +1,80 @@
1
+ "use client";
2
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
+ import { useCallback, useRef, useState } from "react";
4
+ import { cn } from "@stigmer/theme";
5
+ import { ApiResourceVisibility } from "@stigmer/protos/ai/stigmer/commons/apiresource/enum_pb";
6
+ const OPTIONS = [
7
+ { value: ApiResourceVisibility.visibility_private, label: "Private" },
8
+ { value: ApiResourceVisibility.visibility_public, label: "Public" },
9
+ ];
10
+ /**
11
+ * Segmented control for toggling resource visibility between
12
+ * Private and Public.
13
+ *
14
+ * Switching to PUBLIC shows a brief inline confirmation prompt
15
+ * since making a resource publicly visible is a consequential
16
+ * action. Switching to PRIVATE applies immediately without
17
+ * confirmation (revoking access is always safe).
18
+ *
19
+ * Follows the same visual pattern as {@link ScopeToggle} —
20
+ * WAI-ARIA Radio Group with roving tabindex. All visual
21
+ * properties flow through `--stgm-*` design tokens.
22
+ *
23
+ * @example
24
+ * ```tsx
25
+ * <VisibilityToggle
26
+ * visibility={skill.metadata.visibility}
27
+ * onVisibilityChange={handleVisibilityChange}
28
+ * isPending={isPending}
29
+ * />
30
+ * ```
31
+ */
32
+ export function VisibilityToggle({ visibility, onVisibilityChange, isPending = false, disabled = false, className, }) {
33
+ const [confirming, setConfirming] = useState(false);
34
+ const optionRefs = useRef([]);
35
+ const isPublic = visibility === ApiResourceVisibility.visibility_public;
36
+ const effectivelyDisabled = disabled || isPending;
37
+ const handleSelect = useCallback((value) => {
38
+ if (value === visibility)
39
+ return;
40
+ if (value === ApiResourceVisibility.visibility_public) {
41
+ setConfirming(true);
42
+ return;
43
+ }
44
+ onVisibilityChange(value);
45
+ }, [visibility, onVisibilityChange]);
46
+ const confirmPublic = useCallback(() => {
47
+ setConfirming(false);
48
+ onVisibilityChange(ApiResourceVisibility.visibility_public);
49
+ }, [onVisibilityChange]);
50
+ const cancelConfirm = useCallback(() => {
51
+ setConfirming(false);
52
+ }, []);
53
+ const handleKeyDown = useCallback((e, index) => {
54
+ let nextIndex = null;
55
+ if (e.key === "ArrowRight" || e.key === "ArrowDown") {
56
+ e.preventDefault();
57
+ nextIndex = (index + 1) % OPTIONS.length;
58
+ }
59
+ else if (e.key === "ArrowLeft" || e.key === "ArrowUp") {
60
+ e.preventDefault();
61
+ nextIndex = (index - 1 + OPTIONS.length) % OPTIONS.length;
62
+ }
63
+ if (nextIndex !== null) {
64
+ optionRefs.current[nextIndex]?.focus();
65
+ handleSelect(OPTIONS[nextIndex].value);
66
+ }
67
+ }, [handleSelect]);
68
+ const currentIndex = OPTIONS.findIndex((o) => o.value === visibility);
69
+ return (_jsxs("div", { className: cn("inline-flex flex-col gap-1.5", className), children: [_jsx("div", { role: "radiogroup", "aria-label": "Resource visibility", "aria-disabled": effectivelyDisabled || undefined, className: cn("inline-flex rounded-md bg-muted p-0.5", effectivelyDisabled && "pointer-events-none opacity-50"), children: OPTIONS.map((option, index) => {
70
+ const isSelected = visibility === option.value;
71
+ return (_jsx("button", { ref: (el) => {
72
+ optionRefs.current[index] = el;
73
+ }, type: "button", role: "radio", "aria-checked": isSelected, tabIndex: isSelected ? 0 : -1, disabled: effectivelyDisabled, onClick: () => handleSelect(option.value), onKeyDown: (e) => handleKeyDown(e, index), className: cn("cursor-pointer rounded-sm px-3 py-1 text-xs font-medium transition-colors", "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring", isSelected && option.value === ApiResourceVisibility.visibility_public
74
+ ? "bg-emerald-100 text-emerald-800 shadow-sm dark:bg-emerald-900/40 dark:text-emerald-300"
75
+ : isSelected
76
+ ? "bg-background text-foreground shadow-sm"
77
+ : "text-muted-foreground hover:text-foreground"), children: isPending && isSelected ? (_jsxs("span", { className: "inline-flex items-center gap-1", children: [_jsx("span", { className: "inline-block h-3 w-3 animate-spin rounded-full border-2 border-current border-t-transparent", "aria-hidden": "true" }), option.label] })) : (option.label) }, option.value));
78
+ }) }), confirming && (_jsxs("div", { className: cn("flex items-center gap-2 rounded-md border border-amber-200 bg-amber-50 px-3 py-1.5 text-xs", "dark:border-amber-800/50 dark:bg-amber-950/30"), role: "alert", children: [_jsx("span", { className: "text-amber-800 dark:text-amber-200", children: "Make visible to all users?" }), _jsx("button", { type: "button", onClick: confirmPublic, className: cn("rounded px-2 py-0.5 text-xs font-medium", "bg-amber-600 text-white hover:bg-amber-700", "dark:bg-amber-600 dark:hover:bg-amber-500", "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"), children: "Confirm" }), _jsx("button", { type: "button", onClick: cancelConfirm, className: cn("rounded px-2 py-0.5 text-xs font-medium", "text-amber-700 hover:text-amber-900", "dark:text-amber-300 dark:hover:text-amber-100", "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"), children: "Cancel" })] }))] }));
79
+ }
80
+ //# sourceMappingURL=VisibilityToggle.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VisibilityToggle.js","sourceRoot":"","sources":["../../src/library/VisibilityToggle.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAEb,OAAO,EAAE,WAAW,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACtD,OAAO,EAAE,EAAE,EAAE,MAAM,gBAAgB,CAAC;AACpC,OAAO,EAAE,qBAAqB,EAAE,MAAM,wDAAwD,CAAC;AAmB/F,MAAM,OAAO,GAGP;IACJ,EAAE,KAAK,EAAE,qBAAqB,CAAC,kBAAkB,EAAE,KAAK,EAAE,SAAS,EAAE;IACrE,EAAE,KAAK,EAAE,qBAAqB,CAAC,iBAAiB,EAAE,KAAK,EAAE,QAAQ,EAAE;CACpE,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAM,UAAU,gBAAgB,CAAC,EAC/B,UAAU,EACV,kBAAkB,EAClB,SAAS,GAAG,KAAK,EACjB,QAAQ,GAAG,KAAK,EAChB,SAAS,GACa;IACtB,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC;IACpD,MAAM,UAAU,GAAG,MAAM,CAA+B,EAAE,CAAC,CAAC;IAE5D,MAAM,QAAQ,GACZ,UAAU,KAAK,qBAAqB,CAAC,iBAAiB,CAAC;IACzD,MAAM,mBAAmB,GAAG,QAAQ,IAAI,SAAS,CAAC;IAElD,MAAM,YAAY,GAAG,WAAW,CA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CAAC,CAAC,wFAAwF;4BAC1F,CAAC,CAAC,UAAU;gCACV,CAAC,CAAC,yCAAyC;gCAC3C,CAAC,CAAC,6CAA6C,CACpD,YAEA,SAAS,IAAI,UAAU,CAAC,CAAC,CAAC,CACzB,gBAAM,SAAS,EAAC,gCAAgC,aAC9C,eACE,SAAS,EAAC,6FAA6F,iBAC3F,MAAM,GAClB,EACD,MAAM,CAAC,KAAK,IACR,CACR,CAAC,CAAC,CAAC,CACF,MAAM,CAAC,KAAK,CACb,IA/BI,MAAM,CAAC,KAAK,CAgCV,CACV,CAAC;gBACJ,CAAC,CAAC,GACE,EAEL,UAAU,IAAI,CACb,eACE,SAAS,EAAE,EAAE,CACX,4FAA4F,EAC5F,+CAA+C,CAChD,EACD,IAAI,EAAC,OAAO,aAEZ,eAAM,SAAS,EAAC,oCAAoC,2CAE7C,EACP,iBACE,IAAI,EAAC,QAAQ,EACb,OAAO,EAAE,aAAa,EACtB,SAAS,EAAE,EAAE,CACX,yCAAyC,EACzC,4CAA4C,EAC5C,2CAA2C,EAC3C,yEAAyE,CAC1E,wBAGM,EACT,iBACE,IAAI,EAAC,QAAQ,EACb,OAAO,EAAE,aAAa,EACtB,SAAS,EAAE,EAAE,CACX,yCAAyC,EACzC,qCAAqC,EACrC,+CAA+C,EAC/C,yEAAyE,CAC1E,uBAGM,IACL,CACP,IACG,CACP,CAAC;AACJ,CAAC"}
@@ -0,0 +1,79 @@
1
+ import type { ExecutionArtifact } from "@stigmer/protos/ai/stigmer/agentic/agentexecution/v1/artifact_pb";
2
+ /**
3
+ * Result of detecting whether an execution artifact is a pushable skill package.
4
+ *
5
+ * Uses a discriminated union on the `detected` field — identical pattern
6
+ * to {@link StigmerResourceDetection} — so consumers can narrow with a
7
+ * simple `if (result.detected)` check.
8
+ *
9
+ * Skill detection is a **parallel** path to YAML resource detection:
10
+ *
11
+ * - **YAML detection** (`detectStigmerResource`): Agents, MCP Servers — applied via `apply()`
12
+ * - **Package detection** (`detectSkillPackage`): Skill packages (directory with SKILL.md) — pushed via `pushFromExecutionArtifact()`
13
+ */
14
+ export type SkillPackageDetection = {
15
+ readonly detected: false;
16
+ } | {
17
+ /** Discriminant — always `true` when a skill package was detected. */
18
+ readonly detected: true;
19
+ /** Skill name extracted from SKILL.md YAML frontmatter. */
20
+ readonly skillName: string;
21
+ /** Optional description from SKILL.md frontmatter. */
22
+ readonly skillDescription: string | undefined;
23
+ /** Number of files in the package archive. */
24
+ readonly fileCount: number;
25
+ /** Relative file paths within the archive (from `ExecutionArtifact.entries`). */
26
+ readonly entries: readonly string[];
27
+ };
28
+ /**
29
+ * Checks whether an execution artifact is a skill package (directory
30
+ * artifact whose archive contains `SKILL.md`).
31
+ *
32
+ * This is a pure, synchronous check that requires no network call — it
33
+ * inspects the `entries` field populated by the agent runner at ZIP
34
+ * creation time.
35
+ *
36
+ * Returns `false` for:
37
+ * - FILE artifacts (regardless of name)
38
+ * - DIRECTORY artifacts without `entries` (older artifacts before this field was added)
39
+ * - DIRECTORY artifacts whose entries do not include `SKILL.md`
40
+ *
41
+ * @param artifact - Artifact from `execution.status.artifacts`.
42
+ *
43
+ * @example
44
+ * ```ts
45
+ * if (isSkillPackage(artifact)) {
46
+ * // Show "Push Skill" CTA
47
+ * }
48
+ * ```
49
+ */
50
+ export declare function isSkillPackage(artifact: ExecutionArtifact): boolean;
51
+ /**
52
+ * Detects a skill package and extracts metadata from its SKILL.md content.
53
+ *
54
+ * Call this after fetching the SKILL.md content from the ZIP via
55
+ * `useArtifactContent(executionId, storageKey, "SKILL.md")`. The function
56
+ * parses the YAML frontmatter to extract `name` and `description`.
57
+ *
58
+ * **Resilient by design** — any parse failure, missing field, or unexpected
59
+ * structure returns `{ detected: false }`. This function never throws.
60
+ *
61
+ * @param artifact - The execution artifact (must be a DIRECTORY with SKILL.md in entries).
62
+ * @param skillMdContent - Raw text content of SKILL.md fetched from the archive.
63
+ * @returns A discriminated union with skill metadata when detection succeeds.
64
+ *
65
+ * @example
66
+ * ```ts
67
+ * const { content } = useArtifactContent(executionId, storageKey, "SKILL.md");
68
+ * const detection = detectSkillPackage(artifact, content);
69
+ *
70
+ * if (detection.detected) {
71
+ * console.log(`Skill: ${detection.skillName} (${detection.fileCount} files)`);
72
+ * }
73
+ * ```
74
+ *
75
+ * @see {@link isSkillPackage} for the lightweight check (no content needed)
76
+ * @see {@link useDetectSkillPackage} for the React hook that automates the full flow
77
+ */
78
+ export declare function detectSkillPackage(artifact: ExecutionArtifact, skillMdContent: string): SkillPackageDetection;
79
+ //# sourceMappingURL=detect-skill-package.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"detect-skill-package.d.ts","sourceRoot":"","sources":["../../src/library/detect-skill-package.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,kEAAkE,CAAC;AAI1G;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,qBAAqB,GAC7B;IAAE,QAAQ,CAAC,QAAQ,EAAE,KAAK,CAAA;CAAE,GAC5B;IACE,sEAAsE;IACtE,QAAQ,CAAC,QAAQ,EAAE,IAAI,CAAC;IACxB,2DAA2D;IAC3D,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,sDAAsD;IACtD,QAAQ,CAAC,gBAAgB,EAAE,MAAM,GAAG,SAAS,CAAC;IAC9C,8CAA8C;IAC9C,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,iFAAiF;IACjF,QAAQ,CAAC,OAAO,EAAE,SAAS,MAAM,EAAE,CAAC;CACrC,CAAC;AAMN;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,cAAc,CAAC,QAAQ,EAAE,iBAAiB,GAAG,OAAO,CAKnE;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,wBAAgB,kBAAkB,CAChC,QAAQ,EAAE,iBAAiB,EAC3B,cAAc,EAAE,MAAM,GACrB,qBAAqB,CAiBvB"}
@@ -0,0 +1,113 @@
1
+ import { ExecutionArtifactKind } from "@stigmer/protos/ai/stigmer/agentic/agentexecution/v1/enum_pb";
2
+ import { parse as parseYaml } from "yaml";
3
+ const NOT_DETECTED = { detected: false };
4
+ const SKILL_MD_ENTRY = "SKILL.md";
5
+ /**
6
+ * Checks whether an execution artifact is a skill package (directory
7
+ * artifact whose archive contains `SKILL.md`).
8
+ *
9
+ * This is a pure, synchronous check that requires no network call — it
10
+ * inspects the `entries` field populated by the agent runner at ZIP
11
+ * creation time.
12
+ *
13
+ * Returns `false` for:
14
+ * - FILE artifacts (regardless of name)
15
+ * - DIRECTORY artifacts without `entries` (older artifacts before this field was added)
16
+ * - DIRECTORY artifacts whose entries do not include `SKILL.md`
17
+ *
18
+ * @param artifact - Artifact from `execution.status.artifacts`.
19
+ *
20
+ * @example
21
+ * ```ts
22
+ * if (isSkillPackage(artifact)) {
23
+ * // Show "Push Skill" CTA
24
+ * }
25
+ * ```
26
+ */
27
+ export function isSkillPackage(artifact) {
28
+ return (artifact.kind === ExecutionArtifactKind.DIRECTORY &&
29
+ artifact.entries.includes(SKILL_MD_ENTRY));
30
+ }
31
+ /**
32
+ * Detects a skill package and extracts metadata from its SKILL.md content.
33
+ *
34
+ * Call this after fetching the SKILL.md content from the ZIP via
35
+ * `useArtifactContent(executionId, storageKey, "SKILL.md")`. The function
36
+ * parses the YAML frontmatter to extract `name` and `description`.
37
+ *
38
+ * **Resilient by design** — any parse failure, missing field, or unexpected
39
+ * structure returns `{ detected: false }`. This function never throws.
40
+ *
41
+ * @param artifact - The execution artifact (must be a DIRECTORY with SKILL.md in entries).
42
+ * @param skillMdContent - Raw text content of SKILL.md fetched from the archive.
43
+ * @returns A discriminated union with skill metadata when detection succeeds.
44
+ *
45
+ * @example
46
+ * ```ts
47
+ * const { content } = useArtifactContent(executionId, storageKey, "SKILL.md");
48
+ * const detection = detectSkillPackage(artifact, content);
49
+ *
50
+ * if (detection.detected) {
51
+ * console.log(`Skill: ${detection.skillName} (${detection.fileCount} files)`);
52
+ * }
53
+ * ```
54
+ *
55
+ * @see {@link isSkillPackage} for the lightweight check (no content needed)
56
+ * @see {@link useDetectSkillPackage} for the React hook that automates the full flow
57
+ */
58
+ export function detectSkillPackage(artifact, skillMdContent) {
59
+ if (!isSkillPackage(artifact)) {
60
+ return NOT_DETECTED;
61
+ }
62
+ const frontmatter = parseSkillFrontmatter(skillMdContent);
63
+ if (!frontmatter) {
64
+ return NOT_DETECTED;
65
+ }
66
+ return {
67
+ detected: true,
68
+ skillName: frontmatter.name,
69
+ skillDescription: frontmatter.description,
70
+ fileCount: artifact.entries.length,
71
+ entries: artifact.entries,
72
+ };
73
+ }
74
+ /**
75
+ * Parses YAML frontmatter from a SKILL.md file.
76
+ *
77
+ * Expects the standard frontmatter format:
78
+ * ```markdown
79
+ * ---
80
+ * name: my-skill-name
81
+ * description: Optional description
82
+ * ---
83
+ * ```
84
+ *
85
+ * Returns `null` when the content has no valid frontmatter or the `name`
86
+ * field is missing/empty.
87
+ */
88
+ function parseSkillFrontmatter(content) {
89
+ const fenceMatch = content.match(/^---\r?\n([\s\S]*?)\r?\n---/);
90
+ if (!fenceMatch) {
91
+ return null;
92
+ }
93
+ let parsed;
94
+ try {
95
+ parsed = parseYaml(fenceMatch[1]);
96
+ }
97
+ catch {
98
+ return null;
99
+ }
100
+ if (typeof parsed !== "object" || parsed === null || Array.isArray(parsed)) {
101
+ return null;
102
+ }
103
+ const obj = parsed;
104
+ const name = obj.name;
105
+ if (typeof name !== "string" || name.length === 0) {
106
+ return null;
107
+ }
108
+ const description = typeof obj.description === "string" && obj.description.length > 0
109
+ ? obj.description
110
+ : undefined;
111
+ return { name, description };
112
+ }
113
+ //# sourceMappingURL=detect-skill-package.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"detect-skill-package.js","sourceRoot":"","sources":["../../src/library/detect-skill-package.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,qBAAqB,EAAE,MAAM,8DAA8D,CAAC;AACrG,OAAO,EAAE,KAAK,IAAI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AO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,OAAO,MAAM,KAAK,QAAQ,IAAI,MAAM,KAAK,IAAI,IAAI,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE,CAAC;QAC3E,OAAO,IAAI,CAAC;IACd,CAAC;IAED,MAAM,GAAG,GAAG,MAAiC,CAAC;IAE9C,MAAM,IAAI,GAAG,GAAG,CAAC,IAAI,CAAC;IACtB,IAAI,OAAO,IAAI,KAAK,QAAQ,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QAClD,OAAO,IAAI,CAAC;IACd,CAAC;IAED,MAAM,WAAW,GAAG,OAAO,GAAG,CAAC,WAAW,KAAK,QAAQ,IAAI,GAAG,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC;QACnF,CAAC,CAAC,GAAG,CAAC,WAAW;QACjB,CAAC,CAAC,SAAS,CAAC;IAEd,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,CAAC;AAC/B,CAAC"}
@@ -0,0 +1,66 @@
1
+ /**
2
+ * Resource kinds that the YAML detection logic recognizes.
3
+ *
4
+ * These correspond to the Stigmer resource types that can appear as
5
+ * YAML file artifacts and be applied to an organization via `apply()`:
6
+ *
7
+ * - `"Agent"` — agent blueprint (`apiVersion: agentic.stigmer.ai/v1`, `kind: Agent`)
8
+ * - `"McpServer"` — MCP server definition (`kind: McpServer`)
9
+ *
10
+ * Skills are **not** included here — they are package-based (directory
11
+ * artifacts with SKILL.md) and use a separate detection path via
12
+ * {@link isSkillPackage} / {@link detectSkillPackage}.
13
+ */
14
+ export type StigmerResourceKind = "Agent" | "McpServer";
15
+ /**
16
+ * Result of detecting a Stigmer resource in a YAML content string.
17
+ *
18
+ * Uses a discriminated union on the `detected` field so consumers
19
+ * can narrow the type with a simple `if (result.detected)` check.
20
+ */
21
+ export type StigmerResourceDetection = {
22
+ readonly detected: false;
23
+ } | {
24
+ /** Discriminant — always `true` when a resource was found. */
25
+ readonly detected: true;
26
+ /** The `apiVersion` field from the YAML (e.g. `"agentic.stigmer.ai/v1"`). */
27
+ readonly apiVersion: string;
28
+ /** The resource kind as it appears in the YAML. */
29
+ readonly kind: StigmerResourceKind;
30
+ /** Human-readable label for the resource kind (e.g. `"MCP Server"`). */
31
+ readonly displayName: string;
32
+ /** The `metadata.name` field from the YAML. */
33
+ readonly resourceName: string;
34
+ /** The `metadata.org` field from the YAML, if present. */
35
+ readonly resourceOrg: string | undefined;
36
+ };
37
+ /**
38
+ * Detects whether a YAML content string represents a Stigmer platform resource.
39
+ *
40
+ * Performs a best-effort structural check against the Stigmer resource
41
+ * convention: a YAML document with `apiVersion` matching `*.stigmer.ai/*`,
42
+ * a recognized `kind`, and `metadata.name`.
43
+ *
44
+ * **Resilient by design** — any parse failure, missing field, or unexpected
45
+ * structure returns `{ detected: false }`. This function never throws.
46
+ *
47
+ * Only the first YAML document is inspected when the content contains
48
+ * multiple documents separated by `---`.
49
+ *
50
+ * @param content - Raw YAML content string (typically from {@link useArtifactContent}).
51
+ * @returns A discriminated union: `{ detected: true, kind, ... }` when a
52
+ * recognized Stigmer resource is found, `{ detected: false }` otherwise.
53
+ *
54
+ * @example
55
+ * ```ts
56
+ * const result = detectStigmerResource(yamlString);
57
+ * if (result.detected) {
58
+ * console.log(`Found ${result.displayName}: ${result.resourceName}`);
59
+ * }
60
+ * ```
61
+ *
62
+ * @see {@link useDetectStigmerResource} for the React hook wrapper
63
+ * @see {@link StigmerResourceKind} for recognized resource kinds
64
+ */
65
+ export declare function detectStigmerResource(content: string): StigmerResourceDetection;
66
+ //# sourceMappingURL=detect-stigmer-resource.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"detect-stigmer-resource.d.ts","sourceRoot":"","sources":["../../src/library/detect-stigmer-resource.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;GAYG;AACH,MAAM,MAAM,mBAAmB,GAAG,OAAO,GAAG,WAAW,CAAC;AAExD;;;;;GAKG;AACH,MAAM,MAAM,wBAAwB,GAChC;IAAE,QAAQ,CAAC,QAAQ,EAAE,KAAK,CAAA;CAAE,GAC5B;IACE,8DAA8D;IAC9D,QAAQ,CAAC,QAAQ,EAAE,IAAI,CAAC;IACxB,6EAA6E;IAC7E,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,mDAAmD;IACnD,QAAQ,CAAC,IAAI,EAAE,mBAAmB,CAAC;IACnC,wEAAwE;IACxE,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,+CAA+C;IAC/C,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAC9B,0DAA0D;IAC1D,QAAQ,CAAC,WAAW,EAAE,MAAM,GAAG,SAAS,CAAC;CAC1C,CAAC;AAiBN;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,wBAAgB,qBAAqB,CACnC,OAAO,EAAE,MAAM,GACd,wBAAwB,CA4C1B"}
@@ -0,0 +1,77 @@
1
+ import { parse as parseYaml } from "yaml";
2
+ const NOT_DETECTED = { detected: false };
3
+ const KIND_DISPLAY_NAMES = {
4
+ Agent: "Agent",
5
+ McpServer: "MCP Server",
6
+ };
7
+ const KNOWN_KINDS = new Set(Object.keys(KIND_DISPLAY_NAMES));
8
+ const STIGMER_API_VERSION_PATTERN = /^[a-z]+\.stigmer\.ai\/v\d+$/;
9
+ function isPlainObject(value) {
10
+ return typeof value === "object" && value !== null && !Array.isArray(value);
11
+ }
12
+ /**
13
+ * Detects whether a YAML content string represents a Stigmer platform resource.
14
+ *
15
+ * Performs a best-effort structural check against the Stigmer resource
16
+ * convention: a YAML document with `apiVersion` matching `*.stigmer.ai/*`,
17
+ * a recognized `kind`, and `metadata.name`.
18
+ *
19
+ * **Resilient by design** — any parse failure, missing field, or unexpected
20
+ * structure returns `{ detected: false }`. This function never throws.
21
+ *
22
+ * Only the first YAML document is inspected when the content contains
23
+ * multiple documents separated by `---`.
24
+ *
25
+ * @param content - Raw YAML content string (typically from {@link useArtifactContent}).
26
+ * @returns A discriminated union: `{ detected: true, kind, ... }` when a
27
+ * recognized Stigmer resource is found, `{ detected: false }` otherwise.
28
+ *
29
+ * @example
30
+ * ```ts
31
+ * const result = detectStigmerResource(yamlString);
32
+ * if (result.detected) {
33
+ * console.log(`Found ${result.displayName}: ${result.resourceName}`);
34
+ * }
35
+ * ```
36
+ *
37
+ * @see {@link useDetectStigmerResource} for the React hook wrapper
38
+ * @see {@link StigmerResourceKind} for recognized resource kinds
39
+ */
40
+ export function detectStigmerResource(content) {
41
+ let parsed;
42
+ try {
43
+ parsed = parseYaml(content);
44
+ }
45
+ catch {
46
+ return NOT_DETECTED;
47
+ }
48
+ if (!isPlainObject(parsed)) {
49
+ return NOT_DETECTED;
50
+ }
51
+ const { apiVersion, kind, metadata } = parsed;
52
+ if (typeof apiVersion !== "string" || !STIGMER_API_VERSION_PATTERN.test(apiVersion)) {
53
+ return NOT_DETECTED;
54
+ }
55
+ if (typeof kind !== "string" || !KNOWN_KINDS.has(kind)) {
56
+ return NOT_DETECTED;
57
+ }
58
+ if (!isPlainObject(metadata)) {
59
+ return NOT_DETECTED;
60
+ }
61
+ const name = metadata.name;
62
+ if (typeof name !== "string" || name.length === 0) {
63
+ return NOT_DETECTED;
64
+ }
65
+ const resourceKind = kind;
66
+ return {
67
+ detected: true,
68
+ apiVersion,
69
+ kind: resourceKind,
70
+ displayName: KIND_DISPLAY_NAMES[resourceKind],
71
+ resourceName: name,
72
+ resourceOrg: typeof metadata.org === "string" && metadata.org.length > 0
73
+ ? metadata.org
74
+ : undefined,
75
+ };
76
+ }
77
+ //# sourceMappingURL=detect-stigmer-resource.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"detect-stigmer-resource.js","sourceRoot":"","sources":["../../src/library/detect-stigmer-resource.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,IAAI,SAAS,EAAE,MAAM,MAAM,CAAC;AAwC1C,MAAM,YAAY,GAA6B,EAAE,QAAQ,EAAE,KAAK,EAAW,CAAC;AA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AAI,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QAClD,OAAO,YAAY,CAAC;IACtB,CAAC;IAED,MAAM,YAAY,GAAG,IAA2B,CAAC;IAEjD,OAAO;QACL,QAAQ,EAAE,IAAI;QACd,UAAU;QACV,IAAI,EAAE,YAAY;QAClB,WAAW,EAAE,kBAAkB,CAAC,YAAY,CAAC;QAC7C,YAAY,EAAE,IAAI;QAClB,WAAW,EACT,OAAO,QAAQ,CAAC,GAAG,KAAK,QAAQ,IAAI,QAAQ,CAAC,GAAG,CAAC,MAAM,GAAG,CAAC;YACzD,CAAC,CAAC,QAAQ,CAAC,GAAG;YACd,CAAC,CAAC,SAAS;KAChB,CAAC;AACJ,CAAC"}
@@ -0,0 +1,24 @@
1
+ export { ScopeToggle } from "./ScopeToggle";
2
+ export type { ScopeToggleProps } from "./ScopeToggle";
3
+ export { ResourceListView } from "./ResourceListView";
4
+ export type { ResourceListViewProps } from "./ResourceListView";
5
+ export { ResourceCountCard } from "./ResourceCountCard";
6
+ export type { ResourceCountCardProps } from "./ResourceCountCard";
7
+ export { detectStigmerResource } from "./detect-stigmer-resource";
8
+ export type { StigmerResourceKind, StigmerResourceDetection, } from "./detect-stigmer-resource";
9
+ export { useDetectStigmerResource } from "./useDetectStigmerResource";
10
+ export { isSkillPackage, detectSkillPackage, } from "./detect-skill-package";
11
+ export type { SkillPackageDetection } from "./detect-skill-package";
12
+ export { useDetectSkillPackage } from "./useDetectSkillPackage";
13
+ export type { UseDetectSkillPackageReturn } from "./useDetectSkillPackage";
14
+ export { parseResourceYaml } from "./parse-resource-yaml";
15
+ export type { ParsedResource } from "./parse-resource-yaml";
16
+ export { serializeAgentYaml, serializeMcpServerYaml, } from "./serialize-resource-yaml";
17
+ export { useApplyResource } from "./useApplyResource";
18
+ export type { UseApplyResourceReturn, ApplyResourceResult, PushSkillParams, } from "./useApplyResource";
19
+ export { VisibilityToggle } from "./VisibilityToggle";
20
+ export type { VisibilityToggleProps } from "./VisibilityToggle";
21
+ export { useUpdateVisibility } from "./useUpdateVisibility";
22
+ export type { VisibilityResourceKind, UseUpdateVisibilityReturn, } from "./useUpdateVisibility";
23
+ export type { ResourceListScope } from "../search";
24
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/library/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,YAAY,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAEtD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,YAAY,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAEhE,OAAO,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AACxD,YAAY,EAAE,sBAAsB,EAAE,MAAM,qBAAqB,CAAC;AAElE,OAAO,EAAE,qBAAqB,EAAE,MAAM,2BAA2B,CAAC;AAClE,YAAY,EACV,mBAAmB,EACnB,wBAAwB,GACzB,MAAM,2BAA2B,CAAC;AAEnC,OAAO,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAC;AAEtE,OAAO,EACL,cAAc,EACd,kBAAkB,GACnB,MAAM,wBAAwB,CAAC;AAChC,YAAY,EAAE,qBAAqB,EAAE,MAAM,wBAAwB,CAAC;AAEpE,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAChE,YAAY,EAAE,2BAA2B,EAAE,MAAM,yBAAyB,CAAC;AAE3E,OAAO,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAC1D,YAAY,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAE5D,OAAO,EACL,kBAAkB,EAClB,sBAAsB,GACvB,MAAM,2BAA2B,CAAC;AAEnC,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,YAAY,EACV,sBAAsB,EACtB,mBAAmB,EACnB,eAAe,GAChB,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,YAAY,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAEhE,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC5D,YAAY,EACV,sBAAsB,EACtB,yBAAyB,GAC1B,MAAM,uBAAuB,CAAC;AAE/B,YAAY,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAC"}
@@ -0,0 +1,13 @@
1
+ export { ScopeToggle } from "./ScopeToggle";
2
+ export { ResourceListView } from "./ResourceListView";
3
+ export { ResourceCountCard } from "./ResourceCountCard";
4
+ export { detectStigmerResource } from "./detect-stigmer-resource";
5
+ export { useDetectStigmerResource } from "./useDetectStigmerResource";
6
+ export { isSkillPackage, detectSkillPackage, } from "./detect-skill-package";
7
+ export { useDetectSkillPackage } from "./useDetectSkillPackage";
8
+ export { parseResourceYaml } from "./parse-resource-yaml";
9
+ export { serializeAgentYaml, serializeMcpServerYaml, } from "./serialize-resource-yaml";
10
+ export { useApplyResource } from "./useApplyResource";
11
+ export { VisibilityToggle } from "./VisibilityToggle";
12
+ export { useUpdateVisibility } from "./useUpdateVisibility";
13
+ //# sourceMappingURL=index.js.map