@burdenoff/microfe-botmanor 2026.813.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 (160) hide show
  1. package/README.md +12 -0
  2. package/dist/botlit/BotlitRoutes.js +357 -0
  3. package/dist/botlit/BotlitRoutes.js.map +1 -0
  4. package/dist/botlit/BotmanorRoot.js +12 -0
  5. package/dist/botlit/BotmanorRoot.js.map +1 -0
  6. package/dist/botlit/BotmanorRootInner.js +101 -0
  7. package/dist/botlit/BotmanorRootInner.js.map +1 -0
  8. package/dist/botlit/components/Badge.js +39 -0
  9. package/dist/botlit/components/Badge.js.map +1 -0
  10. package/dist/botlit/components/Button.js +46 -0
  11. package/dist/botlit/components/Button.js.map +1 -0
  12. package/dist/botlit/components/Card.js +31 -0
  13. package/dist/botlit/components/Card.js.map +1 -0
  14. package/dist/botlit/components/ChannelSelectorSheet.js +130 -0
  15. package/dist/botlit/components/ChannelSelectorSheet.js.map +1 -0
  16. package/dist/botlit/components/EmptyState.js +35 -0
  17. package/dist/botlit/components/EmptyState.js.map +1 -0
  18. package/dist/botlit/components/ErrorState.js +33 -0
  19. package/dist/botlit/components/ErrorState.js.map +1 -0
  20. package/dist/botlit/components/Input.js +59 -0
  21. package/dist/botlit/components/Input.js.map +1 -0
  22. package/dist/botlit/components/PageLayout.js +34 -0
  23. package/dist/botlit/components/PageLayout.js.map +1 -0
  24. package/dist/botlit/components/QuotaExhaustedDialog.js +20 -0
  25. package/dist/botlit/components/QuotaExhaustedDialog.js.map +1 -0
  26. package/dist/botlit/components/RouteLoader.js +52 -0
  27. package/dist/botlit/components/RouteLoader.js.map +1 -0
  28. package/dist/botlit/components/VersionHistoryPanel.js +144 -0
  29. package/dist/botlit/components/VersionHistoryPanel.js.map +1 -0
  30. package/dist/botlit/components/WorkspaceRequired.js +70 -0
  31. package/dist/botlit/components/WorkspaceRequired.js.map +1 -0
  32. package/dist/botlit/hooks/index.js +16 -0
  33. package/dist/botlit/hooks/internal/mutationInput.js +16 -0
  34. package/dist/botlit/hooks/internal/mutationInput.js.map +1 -0
  35. package/dist/botlit/hooks/internal/workspaceGateway.js +99 -0
  36. package/dist/botlit/hooks/internal/workspaceGateway.js.map +1 -0
  37. package/dist/botlit/hooks/useA2A.js +184 -0
  38. package/dist/botlit/hooks/useA2A.js.map +1 -0
  39. package/dist/botlit/hooks/useAgents.js +469 -0
  40. package/dist/botlit/hooks/useAgents.js.map +1 -0
  41. package/dist/botlit/hooks/useBots.js +306 -0
  42. package/dist/botlit/hooks/useBots.js.map +1 -0
  43. package/dist/botlit/hooks/useBuckets.js +119 -0
  44. package/dist/botlit/hooks/useBuckets.js.map +1 -0
  45. package/dist/botlit/hooks/useChannels.js +213 -0
  46. package/dist/botlit/hooks/useChannels.js.map +1 -0
  47. package/dist/botlit/hooks/useConversations.js +64 -0
  48. package/dist/botlit/hooks/useConversations.js.map +1 -0
  49. package/dist/botlit/hooks/useExecutions.js +86 -0
  50. package/dist/botlit/hooks/useExecutions.js.map +1 -0
  51. package/dist/botlit/hooks/useKnowledgeBases.js +113 -0
  52. package/dist/botlit/hooks/useKnowledgeBases.js.map +1 -0
  53. package/dist/botlit/hooks/useLLMProviders.js +83 -0
  54. package/dist/botlit/hooks/useLLMProviders.js.map +1 -0
  55. package/dist/botlit/hooks/useMCPServers.js +134 -0
  56. package/dist/botlit/hooks/useMCPServers.js.map +1 -0
  57. package/dist/botlit/hooks/usePolicies.js +120 -0
  58. package/dist/botlit/hooks/usePolicies.js.map +1 -0
  59. package/dist/botlit/hooks/usePromptTemplates.js +161 -0
  60. package/dist/botlit/hooks/usePromptTemplates.js.map +1 -0
  61. package/dist/botlit/hooks/useRetrievalProfiles.js +146 -0
  62. package/dist/botlit/hooks/useRetrievalProfiles.js.map +1 -0
  63. package/dist/botlit/hooks/useSkills.js +132 -0
  64. package/dist/botlit/hooks/useSkills.js.map +1 -0
  65. package/dist/botlit/hooks/useStore.js +167 -0
  66. package/dist/botlit/hooks/useStore.js.map +1 -0
  67. package/dist/botlit/hooks/useUserPlatformConnection.js +172 -0
  68. package/dist/botlit/hooks/useUserPlatformConnection.js.map +1 -0
  69. package/dist/botlit/index.js +11 -0
  70. package/dist/botlit/pages/A2AAgentDetailPage.js +589 -0
  71. package/dist/botlit/pages/A2AAgentDetailPage.js.map +1 -0
  72. package/dist/botlit/pages/A2ARegistryPage.js +240 -0
  73. package/dist/botlit/pages/A2ARegistryPage.js.map +1 -0
  74. package/dist/botlit/pages/AgentBuilderPage.js +486 -0
  75. package/dist/botlit/pages/AgentBuilderPage.js.map +1 -0
  76. package/dist/botlit/pages/AgentDetailPage.js +517 -0
  77. package/dist/botlit/pages/AgentDetailPage.js.map +1 -0
  78. package/dist/botlit/pages/AgentsListPage.js +294 -0
  79. package/dist/botlit/pages/AgentsListPage.js.map +1 -0
  80. package/dist/botlit/pages/BotChannelsTab.js +530 -0
  81. package/dist/botlit/pages/BotChannelsTab.js.map +1 -0
  82. package/dist/botlit/pages/BotDetailPage.js +872 -0
  83. package/dist/botlit/pages/BotDetailPage.js.map +1 -0
  84. package/dist/botlit/pages/BotWorkflowTab.js +229 -0
  85. package/dist/botlit/pages/BotWorkflowTab.js.map +1 -0
  86. package/dist/botlit/pages/BotsListPage.js +313 -0
  87. package/dist/botlit/pages/BotsListPage.js.map +1 -0
  88. package/dist/botlit/pages/BucketsPage.js +604 -0
  89. package/dist/botlit/pages/BucketsPage.js.map +1 -0
  90. package/dist/botlit/pages/ChannelDetailPage.js +955 -0
  91. package/dist/botlit/pages/ChannelDetailPage.js.map +1 -0
  92. package/dist/botlit/pages/ChannelRoutesPage.js +218 -0
  93. package/dist/botlit/pages/ChannelRoutesPage.js.map +1 -0
  94. package/dist/botlit/pages/ChannelsPage.js +304 -0
  95. package/dist/botlit/pages/ChannelsPage.js.map +1 -0
  96. package/dist/botlit/pages/ChatPage.js +247 -0
  97. package/dist/botlit/pages/ChatPage.js.map +1 -0
  98. package/dist/botlit/pages/DashboardPage.js +318 -0
  99. package/dist/botlit/pages/DashboardPage.js.map +1 -0
  100. package/dist/botlit/pages/ExecutionDetailPage.js +313 -0
  101. package/dist/botlit/pages/ExecutionDetailPage.js.map +1 -0
  102. package/dist/botlit/pages/ExecutionsPage.js +294 -0
  103. package/dist/botlit/pages/ExecutionsPage.js.map +1 -0
  104. package/dist/botlit/pages/InstalledPackagesPage.js +619 -0
  105. package/dist/botlit/pages/InstalledPackagesPage.js.map +1 -0
  106. package/dist/botlit/pages/KnowledgeBaseDetailPage.js +473 -0
  107. package/dist/botlit/pages/KnowledgeBaseDetailPage.js.map +1 -0
  108. package/dist/botlit/pages/KnowledgeBasesPage.js +150 -0
  109. package/dist/botlit/pages/KnowledgeBasesPage.js.map +1 -0
  110. package/dist/botlit/pages/MCPServerDetailPage.js +550 -0
  111. package/dist/botlit/pages/MCPServerDetailPage.js.map +1 -0
  112. package/dist/botlit/pages/MCPServersPage.js +321 -0
  113. package/dist/botlit/pages/MCPServersPage.js.map +1 -0
  114. package/dist/botlit/pages/PoliciesPage.js +224 -0
  115. package/dist/botlit/pages/PoliciesPage.js.map +1 -0
  116. package/dist/botlit/pages/PolicyDetailPage.js +861 -0
  117. package/dist/botlit/pages/PolicyDetailPage.js.map +1 -0
  118. package/dist/botlit/pages/PromptStudioPage.js +236 -0
  119. package/dist/botlit/pages/PromptStudioPage.js.map +1 -0
  120. package/dist/botlit/pages/PromptTemplateDetailPage.js +812 -0
  121. package/dist/botlit/pages/PromptTemplateDetailPage.js.map +1 -0
  122. package/dist/botlit/pages/PromptTemplatesPage.js +269 -0
  123. package/dist/botlit/pages/PromptTemplatesPage.js.map +1 -0
  124. package/dist/botlit/pages/RetrievalProfileDetailPage.js +559 -0
  125. package/dist/botlit/pages/RetrievalProfileDetailPage.js.map +1 -0
  126. package/dist/botlit/pages/RetrievalProfilesPage.js +219 -0
  127. package/dist/botlit/pages/RetrievalProfilesPage.js.map +1 -0
  128. package/dist/botlit/pages/SettingsPage.js +655 -0
  129. package/dist/botlit/pages/SettingsPage.js.map +1 -0
  130. package/dist/botlit/pages/SkillDetailPage.js +778 -0
  131. package/dist/botlit/pages/SkillDetailPage.js.map +1 -0
  132. package/dist/botlit/pages/SkillsPage.js +206 -0
  133. package/dist/botlit/pages/SkillsPage.js.map +1 -0
  134. package/dist/botlit/pages/StorePackageDetailPage.js +462 -0
  135. package/dist/botlit/pages/StorePackageDetailPage.js.map +1 -0
  136. package/dist/botlit/pages/StorePage.js +315 -0
  137. package/dist/botlit/pages/StorePage.js.map +1 -0
  138. package/dist/botlit/providers/BotlitProvider.js +93 -0
  139. package/dist/botlit/providers/BotlitProvider.js.map +1 -0
  140. package/dist/botlit/store/botlitStore.js +101 -0
  141. package/dist/botlit/store/botlitStore.js.map +1 -0
  142. package/dist/botlit/utils/cn.js +10 -0
  143. package/dist/botlit/utils/cn.js.map +1 -0
  144. package/dist/botlit/utils/formatters.js +37 -0
  145. package/dist/botlit/utils/formatters.js.map +1 -0
  146. package/dist/botlit/utils/navigation.js +9 -0
  147. package/dist/botlit/utils/navigation.js.map +1 -0
  148. package/dist/botlit/utils/unions.js +14 -0
  149. package/dist/botlit/utils/unions.js.map +1 -0
  150. package/dist/generated/global-operations.js +66 -0
  151. package/dist/generated/global-operations.js.map +1 -0
  152. package/dist/generated/global-types.js +8 -0
  153. package/dist/generated/global-types.js.map +1 -0
  154. package/dist/generated/wspace-operations.js +1591 -0
  155. package/dist/generated/wspace-operations.js.map +1 -0
  156. package/dist/generated/wspace-types.js +12 -0
  157. package/dist/generated/wspace-types.js.map +1 -0
  158. package/dist/index.js +13 -0
  159. package/dist/utils/nativeBridge.js +2 -0
  160. package/package.json +133 -0
@@ -0,0 +1,778 @@
1
+ import { useBotlit as e } from "../providers/BotlitProvider.js";
2
+ import { formatRelativeTime as t } from "../utils/formatters.js";
3
+ import { PageLayout as n } from "../components/PageLayout.js";
4
+ import { Card as r, CardContent as i, CardDescription as a, CardHeader as o, CardTitle as s } from "../components/Card.js";
5
+ import { Button as c } from "../components/Button.js";
6
+ import { Badge as l, StatusBadge as u } from "../components/Badge.js";
7
+ import { isNative as d, nativeImpact as ee, nativeNotify as f } from "../../utils/nativeBridge.js";
8
+ import { EmptyState as p } from "../components/EmptyState.js";
9
+ import { FormField as m, Input as h, Textarea as g } from "../components/Input.js";
10
+ import { useRetrievalProfiles as _ } from "../hooks/useRetrievalProfiles.js";
11
+ import { usePolicies as v } from "../hooks/usePolicies.js";
12
+ import { useCreateSkill as y, useDeleteSkill as b, useSkill as x, useUpdateSkill as te } from "../hooks/useSkills.js";
13
+ import { jsonBoolean as S, toUnion as C } from "../utils/unions.js";
14
+ import { usePromptTemplates as ne } from "../hooks/usePromptTemplates.js";
15
+ import "../hooks/index.js";
16
+ import { useState as w } from "react";
17
+ import { PagePurpose as re } from "@burdenoff/fe-libs/ui";
18
+ import { Fragment as T, jsx as E, jsxs as D } from "react/jsx-runtime";
19
+ import { Link as O, useParams as ie } from "react-router";
20
+ import { ArrowLeft as ae, CheckCircle as oe, Database as k, Edit as A, ExternalLink as j, FileText as M, Save as N, Settings as se, Shield as P, Trash2 as ce, Wrench as F, XCircle as I, Zap as L } from "lucide-react";
21
+ import { toast as R } from "sonner";
22
+ //#region src/botlit/pages/SkillDetailPage.tsx
23
+ var z = [
24
+ "PRIVATE",
25
+ "WORKSPACE",
26
+ "PUBLIC"
27
+ ], B = ({ isNew: B }) => {
28
+ let { skillId: V } = ie(), { navigateTo: H, getPath: U } = e(), { data: W, loading: G } = x(B ? void 0 : V), { data: K } = ne(), { data: le } = v(), { data: q } = _(), { create: ue, loading: de } = y(), { update: fe, loading: pe } = te(), { remove: me, loading: he } = b(), [J, Y] = w(!1), [ge, X] = w(!1), [Z, Q] = w({
29
+ name: "",
30
+ description: "",
31
+ visibility: "PRIVATE",
32
+ promptTemplateId: "",
33
+ toolPolicyId: "",
34
+ retrievalProfileId: "",
35
+ toolPackDeps: "",
36
+ recommendedPolicies: "",
37
+ requiresTools: !1,
38
+ requiresKnowledge: !1,
39
+ requiresA2A: !1
40
+ }), _e = async () => {
41
+ if (Z.name) try {
42
+ await ve();
43
+ } catch (e) {
44
+ R.error(e instanceof Error ? e.message : "Failed to create skill");
45
+ }
46
+ }, ve = async () => {
47
+ await ue({
48
+ name: Z.name,
49
+ description: Z.description,
50
+ visibility: Z.visibility,
51
+ promptTemplateId: Z.promptTemplateId || void 0,
52
+ toolPolicyId: Z.toolPolicyId || void 0,
53
+ retrievalProfileId: Z.retrievalProfileId || void 0,
54
+ toolPackDeps: Z.toolPackDeps.split(",").map((e) => e.trim()).filter(Boolean),
55
+ recommendedPolicies: Z.recommendedPolicies.split(",").map((e) => e.trim()).filter(Boolean),
56
+ capabilityFlags: {
57
+ requiresTools: Z.requiresTools,
58
+ requiresKnowledge: Z.requiresKnowledge,
59
+ requiresA2A: Z.requiresA2A
60
+ }
61
+ }), R.success(`Skill "${Z.name}" created`), H("skills");
62
+ }, ye = async () => {
63
+ if (!(!V || !Z.name)) try {
64
+ await be();
65
+ } catch (e) {
66
+ R.error(e instanceof Error ? e.message : "Failed to update skill");
67
+ }
68
+ }, be = async () => {
69
+ V && (await fe({
70
+ skillId: V,
71
+ input: {
72
+ name: Z.name,
73
+ description: Z.description,
74
+ visibility: Z.visibility,
75
+ promptTemplateId: Z.promptTemplateId || void 0,
76
+ toolPolicyId: Z.toolPolicyId || void 0,
77
+ retrievalProfileId: Z.retrievalProfileId || void 0,
78
+ toolPackDeps: Z.toolPackDeps.split(",").map((e) => e.trim()).filter(Boolean),
79
+ recommendedPolicies: Z.recommendedPolicies.split(",").map((e) => e.trim()).filter(Boolean),
80
+ capabilityFlags: {
81
+ requiresTools: Z.requiresTools,
82
+ requiresKnowledge: Z.requiresKnowledge,
83
+ requiresA2A: Z.requiresA2A
84
+ }
85
+ }
86
+ }), R.success("Skill updated"), Y(!1));
87
+ }, xe = async () => {
88
+ if (V) try {
89
+ await me(V), d() && f("success"), R.success("Skill deleted"), H("skills");
90
+ } catch (e) {
91
+ d() && f("error"), R.error(e instanceof Error ? e.message : "Failed to delete skill");
92
+ }
93
+ }, Se = () => {
94
+ W && (Q({
95
+ name: W.name,
96
+ description: W.description || "",
97
+ visibility: C(W.visibility, z, "PRIVATE"),
98
+ promptTemplateId: W.promptTemplateId || "",
99
+ toolPolicyId: W.toolPolicyId || "",
100
+ retrievalProfileId: W.retrievalProfileId || "",
101
+ toolPackDeps: W.toolPackDeps.join(", "),
102
+ recommendedPolicies: W.recommendedPolicies.join(", "),
103
+ requiresTools: S(W.capabilityFlags, "requiresTools"),
104
+ requiresKnowledge: S(W.capabilityFlags, "requiresKnowledge"),
105
+ requiresA2A: S(W.capabilityFlags, "requiresA2A")
106
+ }), Y(!0));
107
+ }, Ce = le?.filter((e) => e.type === "TOOL") || [];
108
+ if (B) return /* @__PURE__ */ E(n, {
109
+ title: "Create Skill",
110
+ description: "Bundle prompts, tools, and policies into a reusable skill",
111
+ actions: /* @__PURE__ */ D("div", {
112
+ className: "flex gap-2",
113
+ children: [/* @__PURE__ */ E(c, {
114
+ variant: "outline",
115
+ onClick: () => H("skills"),
116
+ children: "Cancel"
117
+ }), /* @__PURE__ */ E(c, {
118
+ leftIcon: /* @__PURE__ */ E(N, { size: 16 }),
119
+ onClick: _e,
120
+ isLoading: de,
121
+ disabled: !Z.name,
122
+ children: "Create"
123
+ })]
124
+ }),
125
+ children: /* @__PURE__ */ D("div", {
126
+ className: "max-w-2xl space-y-6",
127
+ children: [
128
+ /* @__PURE__ */ D(r, { children: [/* @__PURE__ */ E(o, { children: /* @__PURE__ */ E(s, { children: "Basic Information" }) }), /* @__PURE__ */ D(i, {
129
+ className: "space-y-4",
130
+ children: [
131
+ /* @__PURE__ */ E(m, {
132
+ label: "Skill Name",
133
+ required: !0,
134
+ children: /* @__PURE__ */ E(h, {
135
+ placeholder: "e.g., Code Review Skill",
136
+ value: Z.name,
137
+ onChange: (e) => Q({
138
+ ...Z,
139
+ name: e.target.value
140
+ })
141
+ })
142
+ }),
143
+ /* @__PURE__ */ E(m, {
144
+ label: "Description",
145
+ children: /* @__PURE__ */ E(g, {
146
+ placeholder: "What does this skill enable agents to do?",
147
+ value: Z.description,
148
+ onChange: (e) => Q({
149
+ ...Z,
150
+ description: e.target.value
151
+ }),
152
+ rows: 3
153
+ })
154
+ }),
155
+ /* @__PURE__ */ E(m, {
156
+ label: "Visibility",
157
+ children: /* @__PURE__ */ D("select", {
158
+ className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
159
+ value: Z.visibility,
160
+ onChange: (e) => Q({
161
+ ...Z,
162
+ visibility: e.target.value
163
+ }),
164
+ children: [
165
+ /* @__PURE__ */ E("option", {
166
+ value: "PRIVATE",
167
+ children: "Private"
168
+ }),
169
+ /* @__PURE__ */ E("option", {
170
+ value: "WORKSPACE",
171
+ children: "Workspace"
172
+ }),
173
+ /* @__PURE__ */ E("option", {
174
+ value: "PUBLIC",
175
+ children: "Public"
176
+ })
177
+ ]
178
+ })
179
+ })
180
+ ]
181
+ })] }),
182
+ /* @__PURE__ */ D(r, { children: [/* @__PURE__ */ D(o, { children: [/* @__PURE__ */ D(s, {
183
+ className: "flex items-center gap-2",
184
+ children: [/* @__PURE__ */ E(M, { size: 18 }), "Prompt Template"]
185
+ }), /* @__PURE__ */ E(a, { children: "Associate a prompt template with this skill" })] }), /* @__PURE__ */ E(i, { children: /* @__PURE__ */ E(m, {
186
+ label: "Prompt Template",
187
+ children: /* @__PURE__ */ D("select", {
188
+ className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
189
+ value: Z.promptTemplateId,
190
+ onChange: (e) => Q({
191
+ ...Z,
192
+ promptTemplateId: e.target.value
193
+ }),
194
+ children: [/* @__PURE__ */ E("option", {
195
+ value: "",
196
+ children: "None"
197
+ }), K?.map((e) => /* @__PURE__ */ D("option", {
198
+ value: e.id,
199
+ children: [
200
+ e.name,
201
+ " (v",
202
+ e.version,
203
+ ")"
204
+ ]
205
+ }, e.id))]
206
+ })
207
+ }) })] }),
208
+ /* @__PURE__ */ D(r, { children: [/* @__PURE__ */ D(o, { children: [/* @__PURE__ */ D(s, {
209
+ className: "flex items-center gap-2",
210
+ children: [/* @__PURE__ */ E(F, { size: 18 }), "Tools Configuration"]
211
+ }), /* @__PURE__ */ E(a, { children: "Configure tool access for this skill" })] }), /* @__PURE__ */ D(i, {
212
+ className: "space-y-4",
213
+ children: [/* @__PURE__ */ E(m, {
214
+ label: "Tool Policy",
215
+ children: /* @__PURE__ */ D("select", {
216
+ className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
217
+ value: Z.toolPolicyId,
218
+ onChange: (e) => Q({
219
+ ...Z,
220
+ toolPolicyId: e.target.value
221
+ }),
222
+ children: [/* @__PURE__ */ E("option", {
223
+ value: "",
224
+ children: "None"
225
+ }), Ce.map((e) => /* @__PURE__ */ E("option", {
226
+ value: e.id,
227
+ children: e.name
228
+ }, e.id))]
229
+ })
230
+ }), /* @__PURE__ */ E(m, {
231
+ label: "Tool Pack Dependencies",
232
+ description: "Comma-separated package slugs",
233
+ children: /* @__PURE__ */ E(h, {
234
+ placeholder: "e.g., @botlit/github-tools, @botlit/web-browser",
235
+ value: Z.toolPackDeps,
236
+ onChange: (e) => Q({
237
+ ...Z,
238
+ toolPackDeps: e.target.value
239
+ })
240
+ })
241
+ })]
242
+ })] }),
243
+ /* @__PURE__ */ D(r, { children: [/* @__PURE__ */ D(o, { children: [/* @__PURE__ */ D(s, {
244
+ className: "flex items-center gap-2",
245
+ children: [/* @__PURE__ */ E(k, { size: 18 }), "Knowledge Configuration"]
246
+ }), /* @__PURE__ */ E(a, { children: "Configure knowledge retrieval for this skill" })] }), /* @__PURE__ */ E(i, { children: /* @__PURE__ */ E(m, {
247
+ label: "Retrieval Profile",
248
+ children: /* @__PURE__ */ D("select", {
249
+ className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
250
+ value: Z.retrievalProfileId,
251
+ onChange: (e) => Q({
252
+ ...Z,
253
+ retrievalProfileId: e.target.value
254
+ }),
255
+ children: [/* @__PURE__ */ E("option", {
256
+ value: "",
257
+ children: "None"
258
+ }), q?.map((e) => /* @__PURE__ */ E("option", {
259
+ value: e.id,
260
+ children: e.name
261
+ }, e.id))]
262
+ })
263
+ }) })] }),
264
+ /* @__PURE__ */ D(r, { children: [/* @__PURE__ */ E(o, { children: /* @__PURE__ */ D(s, {
265
+ className: "flex items-center gap-2",
266
+ children: [/* @__PURE__ */ E(P, { size: 18 }), "Policies & Capabilities"]
267
+ }) }), /* @__PURE__ */ D(i, {
268
+ className: "space-y-4",
269
+ children: [/* @__PURE__ */ E(m, {
270
+ label: "Recommended Policies",
271
+ description: "Comma-separated policy IDs",
272
+ children: /* @__PURE__ */ E(h, {
273
+ placeholder: "e.g., content-policy-1, budget-policy-1",
274
+ value: Z.recommendedPolicies,
275
+ onChange: (e) => Q({
276
+ ...Z,
277
+ recommendedPolicies: e.target.value
278
+ })
279
+ })
280
+ }), /* @__PURE__ */ D("div", {
281
+ className: "space-y-2",
282
+ children: [/* @__PURE__ */ E("p", {
283
+ className: "text-sm font-medium",
284
+ children: "Capability Requirements"
285
+ }), /* @__PURE__ */ D("div", {
286
+ className: "flex flex-wrap gap-4",
287
+ children: [
288
+ /* @__PURE__ */ D("label", {
289
+ className: "flex items-center gap-2",
290
+ children: [/* @__PURE__ */ E("input", {
291
+ type: "checkbox",
292
+ checked: Z.requiresTools,
293
+ onChange: (e) => Q({
294
+ ...Z,
295
+ requiresTools: e.target.checked
296
+ }),
297
+ className: "h-4 w-4"
298
+ }), /* @__PURE__ */ E("span", {
299
+ className: "text-sm",
300
+ children: "Requires Tools"
301
+ })]
302
+ }),
303
+ /* @__PURE__ */ D("label", {
304
+ className: "flex items-center gap-2",
305
+ children: [/* @__PURE__ */ E("input", {
306
+ type: "checkbox",
307
+ checked: Z.requiresKnowledge,
308
+ onChange: (e) => Q({
309
+ ...Z,
310
+ requiresKnowledge: e.target.checked
311
+ }),
312
+ className: "h-4 w-4"
313
+ }), /* @__PURE__ */ E("span", {
314
+ className: "text-sm",
315
+ children: "Requires Knowledge"
316
+ })]
317
+ }),
318
+ /* @__PURE__ */ D("label", {
319
+ className: "flex items-center gap-2",
320
+ children: [/* @__PURE__ */ E("input", {
321
+ type: "checkbox",
322
+ checked: Z.requiresA2A,
323
+ onChange: (e) => Q({
324
+ ...Z,
325
+ requiresA2A: e.target.checked
326
+ }),
327
+ className: "h-4 w-4"
328
+ }), /* @__PURE__ */ E("span", {
329
+ className: "text-sm",
330
+ children: "Requires A2A"
331
+ })]
332
+ })
333
+ ]
334
+ })]
335
+ })]
336
+ })] })
337
+ ]
338
+ })
339
+ });
340
+ if (G) return /* @__PURE__ */ E(n, {
341
+ title: "Loading...",
342
+ children: /* @__PURE__ */ E("div", { className: "h-96 bg-bg-sunken motion-safe:animate-vc-shimmer rounded-lg" })
343
+ });
344
+ if (!W) return /* @__PURE__ */ E(n, {
345
+ title: "Skill Not Found",
346
+ children: /* @__PURE__ */ E(p, {
347
+ illustration: "empty-generic",
348
+ title: "Skill Not Found",
349
+ description: "This skill doesn't exist.",
350
+ action: /* @__PURE__ */ E(c, {
351
+ onClick: () => H("skills"),
352
+ children: "Back to Skills"
353
+ })
354
+ })
355
+ });
356
+ let $ = ({ label: e, enabled: t }) => /* @__PURE__ */ D("div", {
357
+ className: "flex items-center gap-2",
358
+ children: [t ? /* @__PURE__ */ E(oe, { className: "h-4 w-4 text-green-500" }) : /* @__PURE__ */ E(I, { className: "h-4 w-4 text-text-secondary" }), /* @__PURE__ */ E("span", {
359
+ className: t ? "text-text-primary" : "text-text-secondary",
360
+ children: e
361
+ })]
362
+ });
363
+ return /* @__PURE__ */ E(n, {
364
+ title: /* @__PURE__ */ D("div", {
365
+ className: "flex items-center gap-3",
366
+ children: [
367
+ /* @__PURE__ */ E(c, {
368
+ variant: "ghost",
369
+ size: "icon",
370
+ onClick: () => H("skills"),
371
+ children: /* @__PURE__ */ E(ae, { size: 20 })
372
+ }),
373
+ /* @__PURE__ */ E("div", {
374
+ className: "p-2 rounded-lg bg-action-primary-bg/10",
375
+ children: /* @__PURE__ */ E(L, { className: "h-6 w-6 text-primary" })
376
+ }),
377
+ /* @__PURE__ */ D("div", { children: [/* @__PURE__ */ D("div", {
378
+ className: "flex items-center gap-2",
379
+ children: [/* @__PURE__ */ E("span", { children: W.name }), /* @__PURE__ */ E(u, { status: W.status })]
380
+ }), /* @__PURE__ */ E("p", {
381
+ className: "text-sm font-normal text-text-secondary",
382
+ children: W.description
383
+ })] })
384
+ ]
385
+ }),
386
+ actions: /* @__PURE__ */ E("div", {
387
+ className: "flex gap-2",
388
+ children: J ? /* @__PURE__ */ D(T, { children: [/* @__PURE__ */ E(c, {
389
+ variant: "outline",
390
+ onClick: () => Y(!1),
391
+ children: "Cancel"
392
+ }), /* @__PURE__ */ E(c, {
393
+ leftIcon: /* @__PURE__ */ E(N, { size: 16 }),
394
+ onClick: ye,
395
+ isLoading: pe,
396
+ disabled: !Z.name,
397
+ children: "Save Changes"
398
+ })] }) : /* @__PURE__ */ D(T, { children: [/* @__PURE__ */ E(c, {
399
+ variant: "outline",
400
+ leftIcon: /* @__PURE__ */ E(A, { size: 16 }),
401
+ onClick: Se,
402
+ children: "Edit"
403
+ }), ge ? /* @__PURE__ */ D("div", {
404
+ className: "flex gap-2",
405
+ children: [/* @__PURE__ */ E(c, {
406
+ variant: "outline",
407
+ size: "sm",
408
+ onClick: () => X(!1),
409
+ children: "Cancel"
410
+ }), /* @__PURE__ */ E(c, {
411
+ variant: "destructive",
412
+ size: "sm",
413
+ onClick: () => {
414
+ ee("medium"), xe();
415
+ },
416
+ isLoading: he,
417
+ children: "Confirm Delete"
418
+ })]
419
+ }) : /* @__PURE__ */ E(c, {
420
+ variant: "destructive",
421
+ leftIcon: /* @__PURE__ */ E(ce, { size: 16 }),
422
+ onClick: () => X(!0),
423
+ children: "Delete"
424
+ })] })
425
+ }),
426
+ children: /* @__PURE__ */ D("div", {
427
+ className: "space-y-6",
428
+ children: [
429
+ /* @__PURE__ */ E(re, {
430
+ icon: /* @__PURE__ */ E(L, { size: 18 }),
431
+ children: "This skill bundles a prompt, a set of tools and a knowledge profile into one reusable capability. Review what it includes and the policies it recommends, then attach it to any agent to grant all of those abilities at once — keeping your agents consistent without re-wiring the same pieces every time."
432
+ }),
433
+ J && /* @__PURE__ */ D(r, { children: [/* @__PURE__ */ E(o, { children: /* @__PURE__ */ E(s, { children: "Edit Skill" }) }), /* @__PURE__ */ D(i, {
434
+ className: "space-y-4",
435
+ children: [
436
+ /* @__PURE__ */ D("div", {
437
+ className: "grid grid-cols-2 gap-4",
438
+ children: [/* @__PURE__ */ E(m, {
439
+ label: "Skill Name",
440
+ required: !0,
441
+ children: /* @__PURE__ */ E(h, {
442
+ value: Z.name,
443
+ onChange: (e) => Q({
444
+ ...Z,
445
+ name: e.target.value
446
+ })
447
+ })
448
+ }), /* @__PURE__ */ E(m, {
449
+ label: "Visibility",
450
+ children: /* @__PURE__ */ D("select", {
451
+ className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
452
+ value: Z.visibility,
453
+ onChange: (e) => Q({
454
+ ...Z,
455
+ visibility: e.target.value
456
+ }),
457
+ children: [
458
+ /* @__PURE__ */ E("option", {
459
+ value: "PRIVATE",
460
+ children: "Private"
461
+ }),
462
+ /* @__PURE__ */ E("option", {
463
+ value: "WORKSPACE",
464
+ children: "Workspace"
465
+ }),
466
+ /* @__PURE__ */ E("option", {
467
+ value: "PUBLIC",
468
+ children: "Public"
469
+ })
470
+ ]
471
+ })
472
+ })]
473
+ }),
474
+ /* @__PURE__ */ E(m, {
475
+ label: "Description",
476
+ children: /* @__PURE__ */ E(g, {
477
+ value: Z.description,
478
+ onChange: (e) => Q({
479
+ ...Z,
480
+ description: e.target.value
481
+ }),
482
+ rows: 2
483
+ })
484
+ }),
485
+ /* @__PURE__ */ D("div", {
486
+ className: "grid grid-cols-2 gap-4",
487
+ children: [/* @__PURE__ */ E(m, {
488
+ label: "Prompt Template",
489
+ children: /* @__PURE__ */ D("select", {
490
+ className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
491
+ value: Z.promptTemplateId,
492
+ onChange: (e) => Q({
493
+ ...Z,
494
+ promptTemplateId: e.target.value
495
+ }),
496
+ children: [/* @__PURE__ */ E("option", {
497
+ value: "",
498
+ children: "None"
499
+ }), K?.map((e) => /* @__PURE__ */ E("option", {
500
+ value: e.id,
501
+ children: e.name
502
+ }, e.id))]
503
+ })
504
+ }), /* @__PURE__ */ E(m, {
505
+ label: "Retrieval Profile",
506
+ children: /* @__PURE__ */ D("select", {
507
+ className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
508
+ value: Z.retrievalProfileId,
509
+ onChange: (e) => Q({
510
+ ...Z,
511
+ retrievalProfileId: e.target.value
512
+ }),
513
+ children: [/* @__PURE__ */ E("option", {
514
+ value: "",
515
+ children: "None"
516
+ }), q?.map((e) => /* @__PURE__ */ E("option", {
517
+ value: e.id,
518
+ children: e.name
519
+ }, e.id))]
520
+ })
521
+ })]
522
+ }),
523
+ /* @__PURE__ */ E(m, {
524
+ label: "Tool Pack Dependencies",
525
+ description: "Comma-separated",
526
+ children: /* @__PURE__ */ E(h, {
527
+ value: Z.toolPackDeps,
528
+ onChange: (e) => Q({
529
+ ...Z,
530
+ toolPackDeps: e.target.value
531
+ }),
532
+ placeholder: "e.g., @botlit/github-tools, @botlit/web-browser"
533
+ })
534
+ }),
535
+ /* @__PURE__ */ D("div", {
536
+ className: "flex gap-4",
537
+ children: [
538
+ /* @__PURE__ */ D("label", {
539
+ className: "flex items-center gap-2",
540
+ children: [/* @__PURE__ */ E("input", {
541
+ type: "checkbox",
542
+ checked: Z.requiresTools,
543
+ onChange: (e) => Q({
544
+ ...Z,
545
+ requiresTools: e.target.checked
546
+ }),
547
+ className: "h-4 w-4"
548
+ }), /* @__PURE__ */ E("span", {
549
+ className: "text-sm",
550
+ children: "Requires Tools"
551
+ })]
552
+ }),
553
+ /* @__PURE__ */ D("label", {
554
+ className: "flex items-center gap-2",
555
+ children: [/* @__PURE__ */ E("input", {
556
+ type: "checkbox",
557
+ checked: Z.requiresKnowledge,
558
+ onChange: (e) => Q({
559
+ ...Z,
560
+ requiresKnowledge: e.target.checked
561
+ }),
562
+ className: "h-4 w-4"
563
+ }), /* @__PURE__ */ E("span", {
564
+ className: "text-sm",
565
+ children: "Requires Knowledge"
566
+ })]
567
+ }),
568
+ /* @__PURE__ */ D("label", {
569
+ className: "flex items-center gap-2",
570
+ children: [/* @__PURE__ */ E("input", {
571
+ type: "checkbox",
572
+ checked: Z.requiresA2A,
573
+ onChange: (e) => Q({
574
+ ...Z,
575
+ requiresA2A: e.target.checked
576
+ }),
577
+ className: "h-4 w-4"
578
+ }), /* @__PURE__ */ E("span", {
579
+ className: "text-sm",
580
+ children: "Requires A2A"
581
+ })]
582
+ })
583
+ ]
584
+ })
585
+ ]
586
+ })] }),
587
+ /* @__PURE__ */ D("div", {
588
+ className: "grid grid-cols-2 md:grid-cols-4 gap-4",
589
+ children: [
590
+ /* @__PURE__ */ E(r, {
591
+ treatment: "glass",
592
+ glow: !0,
593
+ children: /* @__PURE__ */ D(i, {
594
+ className: "pt-6 text-center",
595
+ children: [
596
+ /* @__PURE__ */ E("div", {
597
+ className: "p-3 rounded-full bg-action-primary-bg/10 w-fit mx-auto mb-2",
598
+ children: /* @__PURE__ */ E(L, { className: "h-5 w-5 text-primary" })
599
+ }),
600
+ /* @__PURE__ */ E("p", {
601
+ className: "text-lg font-bold capitalize",
602
+ children: W.visibility.toLowerCase()
603
+ }),
604
+ /* @__PURE__ */ E("p", {
605
+ className: "text-sm text-text-secondary",
606
+ children: "Visibility"
607
+ })
608
+ ]
609
+ })
610
+ }),
611
+ /* @__PURE__ */ E(r, { children: /* @__PURE__ */ D(i, {
612
+ className: "pt-6 text-center",
613
+ children: [/* @__PURE__ */ E("p", {
614
+ className: "text-3xl font-bold text-text-primary",
615
+ children: W.toolPackDeps.length
616
+ }), /* @__PURE__ */ E("p", {
617
+ className: "text-sm text-text-secondary",
618
+ children: "Tool Packs"
619
+ })]
620
+ }) }),
621
+ /* @__PURE__ */ E(r, { children: /* @__PURE__ */ D(i, {
622
+ className: "pt-6 text-center",
623
+ children: [/* @__PURE__ */ E("p", {
624
+ className: "text-3xl font-bold text-text-primary",
625
+ children: W.recommendedPolicies.length
626
+ }), /* @__PURE__ */ E("p", {
627
+ className: "text-sm text-text-secondary",
628
+ children: "Policies"
629
+ })]
630
+ }) }),
631
+ /* @__PURE__ */ E(r, { children: /* @__PURE__ */ D(i, {
632
+ className: "pt-6 text-center",
633
+ children: [/* @__PURE__ */ E("p", {
634
+ className: "text-3xl font-bold text-text-primary",
635
+ children: W.revision
636
+ }), /* @__PURE__ */ E("p", {
637
+ className: "text-sm text-text-secondary",
638
+ children: "Revision"
639
+ })]
640
+ }) })
641
+ ]
642
+ }),
643
+ /* @__PURE__ */ D(r, { children: [/* @__PURE__ */ D(o, { children: [/* @__PURE__ */ E(s, { children: "Capability Requirements" }), /* @__PURE__ */ E(a, { children: "What this skill requires from agents" })] }), /* @__PURE__ */ E(i, { children: /* @__PURE__ */ D("div", {
644
+ className: "flex gap-8",
645
+ children: [
646
+ /* @__PURE__ */ E($, {
647
+ label: "Tools",
648
+ enabled: S(W.capabilityFlags, "requiresTools")
649
+ }),
650
+ /* @__PURE__ */ E($, {
651
+ label: "Knowledge",
652
+ enabled: S(W.capabilityFlags, "requiresKnowledge")
653
+ }),
654
+ /* @__PURE__ */ E($, {
655
+ label: "A2A",
656
+ enabled: S(W.capabilityFlags, "requiresA2A")
657
+ })
658
+ ]
659
+ }) })] }),
660
+ /* @__PURE__ */ D("div", {
661
+ className: "grid grid-cols-1 md:grid-cols-2 gap-6",
662
+ children: [/* @__PURE__ */ D(r, { children: [/* @__PURE__ */ E(o, { children: /* @__PURE__ */ D(s, {
663
+ className: "flex items-center gap-2",
664
+ children: [/* @__PURE__ */ E(M, { size: 18 }), "Prompt Template"]
665
+ }) }), /* @__PURE__ */ E(i, { children: W.promptTemplateId ? /* @__PURE__ */ E("div", {
666
+ className: "p-4 bg-bg-sunken rounded-lg",
667
+ children: /* @__PURE__ */ D("div", {
668
+ className: "flex items-center justify-between",
669
+ children: [/* @__PURE__ */ E("span", {
670
+ className: "font-medium",
671
+ children: W.promptTemplateId
672
+ }), /* @__PURE__ */ E(O, {
673
+ to: U(`prompt-templates/${W.promptTemplateId}`),
674
+ children: /* @__PURE__ */ E(c, {
675
+ variant: "ghost",
676
+ size: "sm",
677
+ children: /* @__PURE__ */ E(j, { size: 14 })
678
+ })
679
+ })]
680
+ })
681
+ }) : /* @__PURE__ */ E("p", {
682
+ className: "text-text-secondary",
683
+ children: "No prompt template associated"
684
+ }) })] }), /* @__PURE__ */ D(r, { children: [/* @__PURE__ */ E(o, { children: /* @__PURE__ */ D(s, {
685
+ className: "flex items-center gap-2",
686
+ children: [/* @__PURE__ */ E(k, { size: 18 }), "Retrieval Profile"]
687
+ }) }), /* @__PURE__ */ E(i, { children: W.retrievalProfileId ? /* @__PURE__ */ E("div", {
688
+ className: "p-4 bg-bg-sunken rounded-lg",
689
+ children: /* @__PURE__ */ D("div", {
690
+ className: "flex items-center justify-between",
691
+ children: [/* @__PURE__ */ E("span", {
692
+ className: "font-medium",
693
+ children: W.retrievalProfileId
694
+ }), /* @__PURE__ */ E(O, {
695
+ to: U(`retrieval-profiles/${W.retrievalProfileId}`),
696
+ children: /* @__PURE__ */ E(c, {
697
+ variant: "ghost",
698
+ size: "sm",
699
+ children: /* @__PURE__ */ E(j, { size: 14 })
700
+ })
701
+ })]
702
+ })
703
+ }) : /* @__PURE__ */ E("p", {
704
+ className: "text-text-secondary",
705
+ children: "No retrieval profile associated"
706
+ }) })] })]
707
+ }),
708
+ /* @__PURE__ */ D(r, { children: [/* @__PURE__ */ E(o, { children: /* @__PURE__ */ D(s, {
709
+ className: "flex items-center gap-2",
710
+ children: [/* @__PURE__ */ E(F, { size: 18 }), "Tool Pack Dependencies"]
711
+ }) }), /* @__PURE__ */ E(i, { children: W.toolPackDeps.length > 0 ? /* @__PURE__ */ E("div", {
712
+ className: "flex flex-wrap gap-2",
713
+ children: W.toolPackDeps.map((e) => /* @__PURE__ */ E(l, {
714
+ variant: "secondary",
715
+ className: "font-mono",
716
+ children: e
717
+ }, e))
718
+ }) : /* @__PURE__ */ E("p", {
719
+ className: "text-text-secondary",
720
+ children: "No tool pack dependencies"
721
+ }) })] }),
722
+ /* @__PURE__ */ D(r, { children: [/* @__PURE__ */ E(o, { children: /* @__PURE__ */ D(s, {
723
+ className: "flex items-center gap-2",
724
+ children: [/* @__PURE__ */ E(P, { size: 18 }), "Recommended Policies"]
725
+ }) }), /* @__PURE__ */ E(i, { children: W.recommendedPolicies.length > 0 ? /* @__PURE__ */ E("div", {
726
+ className: "flex flex-wrap gap-2",
727
+ children: W.recommendedPolicies.map((e) => /* @__PURE__ */ E(l, {
728
+ variant: "outline",
729
+ children: e
730
+ }, e))
731
+ }) : /* @__PURE__ */ E("p", {
732
+ className: "text-text-secondary",
733
+ children: "No recommended policies"
734
+ }) })] }),
735
+ /* @__PURE__ */ D(r, { children: [/* @__PURE__ */ E(o, { children: /* @__PURE__ */ D(s, {
736
+ className: "flex items-center gap-2",
737
+ children: [/* @__PURE__ */ E(se, { size: 18 }), "Metadata"]
738
+ }) }), /* @__PURE__ */ E(i, { children: /* @__PURE__ */ D("div", {
739
+ className: "grid grid-cols-2 md:grid-cols-4 gap-6 text-sm",
740
+ children: [
741
+ /* @__PURE__ */ D("div", { children: [/* @__PURE__ */ E("p", {
742
+ className: "text-text-secondary",
743
+ children: "Created"
744
+ }), /* @__PURE__ */ E("p", {
745
+ className: "font-medium",
746
+ children: t(W.createdAt)
747
+ })] }),
748
+ /* @__PURE__ */ D("div", { children: [/* @__PURE__ */ E("p", {
749
+ className: "text-text-secondary",
750
+ children: "Updated"
751
+ }), /* @__PURE__ */ E("p", {
752
+ className: "font-medium",
753
+ children: t(W.updatedAt)
754
+ })] }),
755
+ /* @__PURE__ */ D("div", { children: [/* @__PURE__ */ E("p", {
756
+ className: "text-text-secondary",
757
+ children: "Tags"
758
+ }), /* @__PURE__ */ E("div", {
759
+ className: "flex gap-1",
760
+ children: W.tags.length > 0 ? W.tags.map((e) => /* @__PURE__ */ E(l, {
761
+ variant: "secondary",
762
+ className: "text-xs",
763
+ children: e
764
+ }, e)) : /* @__PURE__ */ E("span", {
765
+ className: "text-text-secondary",
766
+ children: "None"
767
+ })
768
+ })] })
769
+ ]
770
+ }) })] })
771
+ ]
772
+ })
773
+ });
774
+ };
775
+ //#endregion
776
+ export { B as SkillDetailPage };
777
+
778
+ //# sourceMappingURL=SkillDetailPage.js.map