@burdenoff/microfe-botmanor 2026.1127.7 → 2026.1201.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 (29) hide show
  1. package/dist/botlit/BotlitRoutes.js +40 -36
  2. package/dist/botlit/BotlitRoutes.js.map +1 -1
  3. package/dist/botlit/components/AiOperationsPanel.js +215 -140
  4. package/dist/botlit/components/AiOperationsPanel.js.map +1 -1
  5. package/dist/botlit/components/ToolApprovalPolicyFields.d.ts +15 -0
  6. package/dist/botlit/components/ToolApprovalPolicyFields.js +152 -0
  7. package/dist/botlit/components/ToolApprovalPolicyFields.js.map +1 -0
  8. package/dist/botlit/hooks/useToolApprovals.d.ts +44 -0
  9. package/dist/botlit/hooks/useToolApprovals.js +98 -0
  10. package/dist/botlit/hooks/useToolApprovals.js.map +1 -0
  11. package/dist/botlit/pages/PoliciesPage.js +16 -7
  12. package/dist/botlit/pages/PoliciesPage.js.map +1 -1
  13. package/dist/botlit/pages/PolicyDetailPage.js +438 -429
  14. package/dist/botlit/pages/PolicyDetailPage.js.map +1 -1
  15. package/dist/botlit/pages/ToolApprovalsPage.d.ts +4 -0
  16. package/dist/botlit/pages/ToolApprovalsPage.js +274 -0
  17. package/dist/botlit/pages/ToolApprovalsPage.js.map +1 -0
  18. package/dist/botlit/permissions/index.js +3 -3
  19. package/dist/botlit/providers/BotlitProvider.js +39 -31
  20. package/dist/botlit/providers/BotlitProvider.js.map +1 -1
  21. package/dist/botlit/providers/SupervisorActionScope.d.ts +20 -0
  22. package/dist/botlit/providers/SupervisorActionScope.js +61 -0
  23. package/dist/botlit/providers/SupervisorActionScope.js.map +1 -0
  24. package/dist/botlit/utils/policyConfig.d.ts +12 -0
  25. package/dist/botlit/utils/policyConfig.js +134 -76
  26. package/dist/botlit/utils/policyConfig.js.map +1 -1
  27. package/dist/generated/wspace-types.js +13 -11
  28. package/dist/generated/wspace-types.js.map +1 -1
  29. package/package.json +1 -1
@@ -5,22 +5,23 @@ import { isNative as r, nativeImpact as i, nativeNotify as a } from "../../utils
5
5
  import { BOTMANOR_PERMISSIONS as o } from "../permissions/botmanorPermissions.js";
6
6
  import { BotmanorPermissionGate as s } from "../permissions/useBotmanorPermissions.js";
7
7
  import { PageLayout as c } from "../components/PageLayout.js";
8
- import { EmptyState as ee } from "../components/EmptyState.js";
9
- import { Card as l, CardContent as u, CardDescription as d, CardHeader as f, CardTitle as p } from "../components/Card.js";
10
- import { Button as m } from "../components/Button.js";
11
- import { FormField as h, Input as g, Textarea as _ } from "../components/Input.js";
12
- import { Badge as te, StatusBadge as ne } from "../components/Badge.js";
8
+ import { PromptInjectionField as ee, ToolApprovalPolicyFields as l } from "../components/ToolApprovalPolicyFields.js";
9
+ import { EmptyState as te } from "../components/EmptyState.js";
10
+ import { Card as u, CardContent as d, CardDescription as f, CardHeader as p, CardTitle as m } from "../components/Card.js";
11
+ import { Button as h } from "../components/Button.js";
12
+ import { FormField as g, Input as _, Textarea as v } from "../components/Input.js";
13
+ import { Badge as ne, StatusBadge as re } from "../components/Badge.js";
13
14
  import "../hooks/index.js";
14
- import { formatRelativeTime as v } from "../utils/formatters.js";
15
- import { useCreatePolicy as re, useDeletePolicy as ie, usePolicy as ae, useUpdatePolicy as oe } from "../hooks/usePolicies.js";
16
- import { toUnion as y } from "../utils/unions.js";
17
- import { A2A_TRUST_LEVELS as se, CITATION_MODES as ce, CREATABLE_POLICY_TYPES as le, EMPTY_POLICY_FORM as ue, KNOWLEDGE_CLASSIFICATIONS as de, PII_MASK_TYPES as fe, RESPONSE_FORMALITY_LEVELS as pe, RESPONSE_STRUCTURES as me, TOOL_RISK_LEVELS as he, buildPolicyConfig as ge, isCreatablePolicyType as b, policyFormFromConfig as _e, unenforcedConfigKeys as ve } from "../utils/policyConfig.js";
15
+ import { useCreatePolicy as ie, useDeletePolicy as ae, usePolicy as oe, useUpdatePolicy as se } from "../hooks/usePolicies.js";
16
+ import { formatRelativeTime as y } from "../utils/formatters.js";
17
+ import { toUnion as b } from "../utils/unions.js";
18
+ import { A2A_TRUST_LEVELS as ce, CITATION_MODES as le, CREATABLE_POLICY_TYPES as ue, EMPTY_POLICY_FORM as de, KNOWLEDGE_CLASSIFICATIONS as fe, PII_MASK_TYPES as pe, RESPONSE_FORMALITY_LEVELS as me, RESPONSE_STRUCTURES as he, TOOL_RISK_LEVELS as ge, buildPolicyConfig as _e, isCreatablePolicyType as x, policyFormFromConfig as ve, unenforcedConfigKeys as ye } from "../utils/policyConfig.js";
18
19
  import "../permissions/index.js";
19
- import { useState as x } from "react";
20
- import { PagePurpose as ye, ThemedSelect as S } from "@burdenoff/fe-libs/ui";
21
- import { Fragment as C, jsx as w, jsxs as T } from "react/jsx-runtime";
22
- import { useParams as be } from "react-router";
23
- import { AlertTriangle as E, ArrowLeft as xe, Clock as Se, Database as Ce, DollarSign as D, Edit as we, FileText as O, Power as Te, Save as Ee, Settings as De, Shield as Oe, Trash2 as k, Wrench as ke } from "lucide-react";
20
+ import { useState as S } from "react";
21
+ import { PagePurpose as be, ThemedSelect as C } from "@burdenoff/fe-libs/ui";
22
+ import { Fragment as w, jsx as T, jsxs as E } from "react/jsx-runtime";
23
+ import { useParams as xe } from "react-router";
24
+ import { AlertTriangle as D, ArrowLeft as Se, Clock as Ce, Database as we, DollarSign as Te, Edit as Ee, FileText as O, Power as De, Save as Oe, Settings as ke, Shield as Ae, Trash2 as k, Wrench as je } from "lucide-react";
24
25
  import { toast as A } from "sonner";
25
26
  // src/botlit/pages/PolicyDetailPage.tsx
26
27
  var j = [
@@ -31,66 +32,66 @@ var j = [
31
32
  "BUDGET",
32
33
  "RATE_LIMIT",
33
34
  "RETENTION"
34
- ], Ae = [
35
+ ], Me = [
35
36
  "PRIVATE",
36
37
  "WORKSPACE",
37
38
  "PUBLIC"
38
- ], M = "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm", je = ({ type: e }) => ({
39
- CONTENT: /* @__PURE__ */ w(E, { size: 18 }),
40
- TOOL: /* @__PURE__ */ w(ke, { size: 18 }),
41
- DATA: /* @__PURE__ */ w(Ce, { size: 18 }),
42
- RESPONSE: /* @__PURE__ */ w(O, { size: 18 }),
43
- BUDGET: /* @__PURE__ */ w(D, { size: 18 }),
44
- RATE_LIMIT: /* @__PURE__ */ w(Se, { size: 18 }),
45
- RETENTION: /* @__PURE__ */ w(k, { size: 18 })
46
- })[e] || /* @__PURE__ */ w(Oe, { size: 18 });
39
+ ], M = "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm", Ne = ({ type: e }) => ({
40
+ CONTENT: /* @__PURE__ */ T(D, { size: 18 }),
41
+ TOOL: /* @__PURE__ */ T(je, { size: 18 }),
42
+ DATA: /* @__PURE__ */ T(we, { size: 18 }),
43
+ RESPONSE: /* @__PURE__ */ T(O, { size: 18 }),
44
+ BUDGET: /* @__PURE__ */ T(Te, { size: 18 }),
45
+ RATE_LIMIT: /* @__PURE__ */ T(Ce, { size: 18 }),
46
+ RETENTION: /* @__PURE__ */ T(k, { size: 18 })
47
+ })[e] || /* @__PURE__ */ T(Ae, { size: 18 });
47
48
  function N(e, t, n) {
48
49
  return n ? [...e.filter((e) => e !== t), t] : e.filter((e) => e !== t);
49
50
  }
50
- var Me = ({ value: t, onChange: r }) => {
51
- let i = e(), { data: a, loading: o, error: s, refetch: c, hasMore: ee, loadingMore: l, loadMore: u } = n();
52
- return /* @__PURE__ */ w(h, {
51
+ var Pe = ({ value: t, onChange: r }) => {
52
+ let i = e(), { data: a, loading: o, error: s, refetch: c, hasMore: ee, loadingMore: l, loadMore: te } = n();
53
+ return /* @__PURE__ */ T(g, {
53
54
  label: i("botlit.policyDetail.applyToAgents", "Apply To Agents"),
54
55
  description: i("botlit.policyDetail.leaveAllUncheckedToApply", "Leave all unchecked to apply this policy to every agent in the workspace."),
55
- children: /* @__PURE__ */ T("div", {
56
+ children: /* @__PURE__ */ E("div", {
56
57
  className: "max-h-48 overflow-auto rounded-md border border-border-default p-2 space-y-1",
57
58
  children: [
58
- s && a.length === 0 ? /* @__PURE__ */ T("div", {
59
+ s && a.length === 0 ? /* @__PURE__ */ E("div", {
59
60
  className: "space-y-2",
60
61
  role: "alert",
61
- children: [/* @__PURE__ */ w("p", {
62
+ children: [/* @__PURE__ */ T("p", {
62
63
  className: "text-sm text-status-error-text",
63
64
  children: i("botlit.policyDetail.agentsCouldNotBeLoaded", "Agents could not be loaded, so this policy cannot be limited to agents right now. Saving it as is applies it to every agent in the workspace.")
64
- }), /* @__PURE__ */ w(m, {
65
+ }), /* @__PURE__ */ T(h, {
65
66
  variant: "outline",
66
67
  size: "sm",
67
68
  onClick: () => void c(),
68
69
  children: i("botlit.policyDetail.retry", "Retry")
69
70
  })]
70
- }) : o && a.length === 0 ? /* @__PURE__ */ w("p", {
71
+ }) : o && a.length === 0 ? /* @__PURE__ */ T("p", {
71
72
  className: "text-sm text-text-secondary",
72
73
  children: i("botlit.policyDetail.loadingAgents", "Loading agents…")
73
- }) : a.length === 0 ? /* @__PURE__ */ w("p", {
74
+ }) : a.length === 0 ? /* @__PURE__ */ T("p", {
74
75
  className: "text-sm text-text-secondary",
75
76
  children: i("botlit.policyDetail.noAgentsInThisWorkspace", "No agents in this workspace yet.")
76
- }) : a.map((e) => /* @__PURE__ */ T("label", {
77
+ }) : a.map((e) => /* @__PURE__ */ E("label", {
77
78
  className: "flex items-center gap-2 text-sm",
78
- children: [/* @__PURE__ */ w("input", {
79
+ children: [/* @__PURE__ */ T("input", {
79
80
  type: "checkbox",
80
81
  className: "h-4 w-4",
81
82
  checked: t.includes(e.id),
82
83
  onChange: (n) => r(N(t, e.id, n.target.checked))
83
- }), /* @__PURE__ */ w("span", { children: e.name })]
84
+ }), /* @__PURE__ */ T("span", { children: e.name })]
84
85
  }, e.id)),
85
- s && a.length > 0 && /* @__PURE__ */ w("p", {
86
+ s && a.length > 0 && /* @__PURE__ */ T("p", {
86
87
  className: "text-sm text-status-error-text",
87
88
  role: "alert",
88
89
  children: i("botlit.policyDetail.moreAgentsCouldNotBe", "More agents could not be loaded; the list above is incomplete.")
89
90
  }),
90
- ee && /* @__PURE__ */ w(m, {
91
+ ee && /* @__PURE__ */ T(h, {
91
92
  variant: "ghost",
92
93
  size: "sm",
93
- onClick: () => void u(),
94
+ onClick: () => void te(),
94
95
  isLoading: l,
95
96
  disabled: l,
96
97
  children: s ? i("botlit.policyDetail.retryLoadingMoreAgents", "Retry loading more agents") : i("botlit.policyDetail.loadMoreAgents", "Load more agents")
@@ -107,75 +108,75 @@ var Me = ({ value: t, onChange: r }) => {
107
108
  BUDGET: P("botlit.policyDetail.budgetPolicy", "Budget Policy"),
108
109
  RATE_LIMIT: P("botlit.policyDetail.rateLimitPolicy", "Rate Limit Policy"),
109
110
  RETENTION: P("botlit.policyDetail.retentionPolicy", "Retention Policy")
110
- }, Ne = {
111
+ }, Fe = {
111
112
  EMAIL: P("botlit.policyDetail.maskEmail", "Email addresses"),
112
113
  PHONE: P("botlit.policyDetail.maskPhone", "Phone numbers"),
113
114
  CREDIT_CARD: P("botlit.policyDetail.maskCard", "Card numbers"),
114
115
  SSN: P("botlit.policyDetail.maskSsn", "US social security numbers"),
115
116
  IP_ADDRESS: P("botlit.policyDetail.maskIp", "IP addresses")
116
- }, Pe = {
117
+ }, Ie = {
117
118
  LOW: P("botlit.policyDetail.toolRiskLow", "low"),
118
119
  MEDIUM: P("botlit.policyDetail.toolRiskMedium", "medium"),
119
120
  HIGH: P("botlit.policyDetail.toolRiskHigh", "high")
120
- }, Fe = {
121
+ }, Le = {
121
122
  UNVERIFIED: P("botlit.policyDetail.unverifiedTrust", "Unverified"),
122
123
  VERIFIED_PUBLISHER: P("botlit.policyDetail.verifiedPublisher", "Verified publisher"),
123
124
  INTERNAL: P("botlit.policyDetail.internalTrust", "Internal")
124
- }, { policyId: I } = be(), { navigateTo: L } = t(), { data: R, loading: Ie, refetch: Le } = ae(n ? void 0 : I), { create: Re, loading: ze } = re(), { update: Be, loading: Ve } = oe(), { remove: He, loading: Ue } = ie(), [z, B] = x(!1), [We, Ge] = x(!1), [V, H] = x({
125
+ }, { policyId: I } = xe(), { navigateTo: L } = t(), { data: R, loading: Re, refetch: ze } = oe(n ? void 0 : I), { create: Be, loading: Ve } = ie(), { update: He, loading: Ue } = se(), { remove: We, loading: Ge } = ae(), [z, B] = S(!1), [Ke, V] = S(!1), [H, U] = S({
125
126
  name: "",
126
127
  description: "",
127
128
  type: "CONTENT",
128
129
  visibility: "PRIVATE"
129
- }), [U, W] = x({
130
+ }), [W, G] = S({
130
131
  name: "",
131
132
  description: "",
132
133
  visibility: "PRIVATE"
133
- }), [G, K] = x(ue), [q, J] = x(null), [Ke, qe] = x(null), Y = (e, t) => {
134
- J(null), K((n) => ({
134
+ }), [K, q] = S(de), [J, Y] = S(null), [qe, Je] = S(null), X = (e, t) => {
135
+ Y(null), q((n) => ({
135
136
  ...n,
136
137
  [e]: {
137
138
  ...n[e],
138
139
  ...t
139
140
  }
140
141
  }));
141
- }, [X, Je] = x(!1), Ye = async () => {
142
- if (!V.name) return;
143
- let e = ge(V.type, G);
144
- if (!e.ok) J(e.error), A.error(e.error);
142
+ }, [Ye, Xe] = S(!1), Ze = async () => {
143
+ if (!H.name) return;
144
+ let e = _e(H.type, K);
145
+ if (!e.ok) Y(e.error), A.error(e.error);
145
146
  else {
146
147
  try {
147
- await Re({
148
- name: V.name,
149
- description: V.description,
150
- type: V.type,
151
- visibility: V.visibility,
152
- status: X ? "ACTIVE" : "DRAFT",
148
+ await Be({
149
+ name: H.name,
150
+ description: H.description,
151
+ type: H.type,
152
+ visibility: H.visibility,
153
+ status: Ye ? "ACTIVE" : "DRAFT",
153
154
  config: e.config
154
155
  });
155
156
  } catch (e) {
156
157
  A.error(e instanceof Error ? e.message : P("botlit.policyDetail.failedToCreatePolicy", "Failed to create policy"));
157
158
  return;
158
159
  }
159
- A.success(P("botlit.policyDetail.policyNameCreated", "Policy \"{{name}}\" created", { name: V.name })), L("policies");
160
+ A.success(P("botlit.policyDetail.policyNameCreated", "Policy \"{{name}}\" created", { name: H.name })), L("policies");
160
161
  }
161
- }, Xe = async () => {
162
- if (!I || !R || !U.name) return;
163
- let e = j.find((e) => e === R.type), t, n = JSON.stringify(G) !== JSON.stringify(Ke);
164
- if (e && b(e) && n) {
165
- let n = ge(e, G);
162
+ }, Qe = async () => {
163
+ if (!I || !R || !W.name) return;
164
+ let e = j.find((e) => e === R.type), t, n = JSON.stringify(K) !== JSON.stringify(qe);
165
+ if (e && x(e) && n) {
166
+ let n = _e(e, K);
166
167
  if (!n.ok) {
167
- J(n.error), A.error(n.error);
168
+ Y(n.error), A.error(n.error);
168
169
  return;
169
170
  }
170
171
  t = n.config;
171
172
  }
172
173
  try {
173
- await Be({
174
+ await He({
174
175
  policyId: I,
175
176
  input: {
176
- name: U.name,
177
- description: U.description,
178
- visibility: U.visibility,
177
+ name: W.name,
178
+ description: W.description,
179
+ visibility: W.visibility,
179
180
  ...t ? { config: t } : {}
180
181
  }
181
182
  });
@@ -183,18 +184,18 @@ var Me = ({ value: t, onChange: r }) => {
183
184
  A.error(e instanceof Error ? e.message : P("botlit.policyDetail.failedToUpdatePolicy", "Failed to update policy"));
184
185
  return;
185
186
  }
186
- await Le(), A.success(P("botlit.policyDetail.policyUpdated", "Policy updated")), B(!1);
187
- }, Ze = async () => {
187
+ await ze(), A.success(P("botlit.policyDetail.policyUpdated", "Policy updated")), B(!1);
188
+ }, $e = async () => {
188
189
  if (I) try {
189
- await He(I), r() && a("success"), L("policies");
190
+ await We(I), r() && a("success"), L("policies");
190
191
  } catch (e) {
191
192
  throw r() && a("error"), e;
192
193
  }
193
- }, Z = R?.status === "ACTIVE", Qe = async () => {
194
+ }, Z = R?.status === "ACTIVE", et = async () => {
194
195
  if (!I) return;
195
196
  let e = Z ? "DRAFT" : "ACTIVE";
196
197
  try {
197
- await Be({
198
+ await He({
198
199
  policyId: I,
199
200
  input: { status: e }
200
201
  });
@@ -202,285 +203,293 @@ var Me = ({ value: t, onChange: r }) => {
202
203
  A.error(e instanceof Error ? e.message : P("botlit.policyDetail.failedToUpdatePolicy", "Failed to update policy"));
203
204
  return;
204
205
  }
205
- await Le(), A.success(e === "ACTIVE" ? P("botlit.policyDetail.policyIsNowEnforced", "Policy is now enforced") : P("botlit.policyDetail.policyIsNoLongerEnforced", "Policy is no longer enforced"));
206
- }, $e = (e) => /* @__PURE__ */ T(C, { children: [
207
- e === "CONTENT" && /* @__PURE__ */ T(l, { children: [/* @__PURE__ */ T(f, { children: [/* @__PURE__ */ T(p, {
206
+ await ze(), A.success(e === "ACTIVE" ? P("botlit.policyDetail.policyIsNowEnforced", "Policy is now enforced") : P("botlit.policyDetail.policyIsNoLongerEnforced", "Policy is no longer enforced"));
207
+ }, tt = (e) => /* @__PURE__ */ E(w, { children: [
208
+ e === "CONTENT" && /* @__PURE__ */ E(u, { children: [/* @__PURE__ */ E(p, { children: [/* @__PURE__ */ E(m, {
208
209
  className: "flex items-center gap-2",
209
- children: [/* @__PURE__ */ w(E, { size: 18 }), P("botlit.policyDetail.contentPolicyConfiguration", "Content Policy Configuration")]
210
- }), /* @__PURE__ */ w(d, { children: P("botlit.policyDetail.checkedAgainstEveryMessageSent", "Checked against every message sent to an agent and every response it gives. A blocked message is refused; a blocked response is replaced with a refusal.") })] }), /* @__PURE__ */ T(u, {
210
+ children: [/* @__PURE__ */ T(D, { size: 18 }), P("botlit.policyDetail.contentPolicyConfiguration", "Content Policy Configuration")]
211
+ }), /* @__PURE__ */ T(f, { children: P("botlit.policyDetail.checkedAgainstEveryMessageSent", "Checked against every message sent to an agent and every response it gives. A blocked message is refused; a blocked response is replaced with a refusal.") })] }), /* @__PURE__ */ E(d, {
211
212
  className: "space-y-4",
212
213
  children: [
213
- /* @__PURE__ */ T("div", {
214
+ /* @__PURE__ */ E("div", {
214
215
  className: "flex items-start gap-2",
215
- children: [/* @__PURE__ */ w("input", {
216
+ children: [/* @__PURE__ */ T("input", {
216
217
  type: "checkbox",
217
218
  id: "pii",
218
- checked: G.content.piiDetection,
219
- onChange: (e) => Y("content", { piiDetection: e.target.checked }),
219
+ checked: K.content.piiDetection,
220
+ onChange: (e) => X("content", { piiDetection: e.target.checked }),
220
221
  className: "mt-1 h-4 w-4"
221
- }), /* @__PURE__ */ T("label", {
222
+ }), /* @__PURE__ */ E("label", {
222
223
  htmlFor: "pii",
223
224
  className: "text-sm",
224
- children: [/* @__PURE__ */ w("span", {
225
+ children: [/* @__PURE__ */ T("span", {
225
226
  className: "font-medium",
226
227
  children: P("botlit.policyDetail.piiDetection", "PII Detection")
227
- }), /* @__PURE__ */ w("span", {
228
+ }), /* @__PURE__ */ T("span", {
228
229
  className: "block text-text-secondary",
229
230
  children: P("botlit.policyDetail.blocksTextContainingAnEmail", "Blocks text containing an email address, a US SSN or a card-number shaped digit run.")
230
231
  })]
231
232
  })]
232
233
  }),
233
- /* @__PURE__ */ w(h, {
234
+ /* @__PURE__ */ T(ee, {
235
+ checked: K.content.promptInjectionDetection,
236
+ onChange: (e) => X("content", { promptInjectionDetection: e })
237
+ }),
238
+ /* @__PURE__ */ T(g, {
234
239
  label: P("botlit.policyDetail.blockedKeywords", "Blocked Keywords"),
235
240
  description: P("botlit.policyDetail.commaSeparatedCaseInsensitiveAny", "Comma-separated. Case-insensitive; any occurrence blocks the text."),
236
- children: /* @__PURE__ */ w(g, {
241
+ children: /* @__PURE__ */ T(_, {
237
242
  placeholder: P("botlit.policyDetail.exampleInternalOnlyProjectX", "e.g., internal-only, project-x"),
238
- value: G.content.blockedKeywords,
239
- onChange: (e) => Y("content", { blockedKeywords: e.target.value })
243
+ value: K.content.blockedKeywords,
244
+ onChange: (e) => X("content", { blockedKeywords: e.target.value })
240
245
  })
241
246
  }),
242
- /* @__PURE__ */ w(h, {
247
+ /* @__PURE__ */ T(g, {
243
248
  label: P("botlit.policyDetail.blockedPatterns", "Blocked Patterns"),
244
249
  description: P("botlit.policyDetail.oneRegularExpressionPerLine", "One regular expression per line, matched case-insensitively."),
245
- children: /* @__PURE__ */ w(_, {
250
+ children: /* @__PURE__ */ T(v, {
246
251
  placeholder: P("botlit.policyDetail.exampleBlockedPattern", "e.g., \\bACME-\\d{6}\\b"),
247
- value: G.content.blockedPatterns,
248
- onChange: (e) => Y("content", { blockedPatterns: e.target.value }),
252
+ value: K.content.blockedPatterns,
253
+ onChange: (e) => X("content", { blockedPatterns: e.target.value }),
249
254
  rows: 3
250
255
  })
251
256
  })
252
257
  ]
253
258
  })] }),
254
- e === "TOOL" && /* @__PURE__ */ T(l, { children: [/* @__PURE__ */ T(f, { children: [/* @__PURE__ */ T(p, {
259
+ e === "TOOL" && /* @__PURE__ */ E(u, { children: [/* @__PURE__ */ E(p, { children: [/* @__PURE__ */ E(m, {
255
260
  className: "flex items-center gap-2",
256
- children: [/* @__PURE__ */ w(ke, { size: 18 }), P("botlit.policyDetail.toolPolicyConfiguration", "Tool Policy Configuration")]
257
- }), /* @__PURE__ */ w(d, { children: P("botlit.policyDetail.appliesToMcpToolCalls", "Applies to MCP tool calls made by agents and through Call Tool, and to agent delegation. Leave a field empty to not restrict it.") })] }), /* @__PURE__ */ T(u, {
261
+ children: [/* @__PURE__ */ T(je, { size: 18 }), P("botlit.policyDetail.toolPolicyConfiguration", "Tool Policy Configuration")]
262
+ }), /* @__PURE__ */ T(f, { children: P("botlit.policyDetail.appliesToMcpToolCalls", "Applies to MCP tool calls made by agents and through Call Tool, and to agent delegation. Leave a field empty to not restrict it.") })] }), /* @__PURE__ */ E(d, {
258
263
  className: "space-y-4",
259
264
  children: [
260
- /* @__PURE__ */ w(h, {
265
+ /* @__PURE__ */ T(g, {
261
266
  label: P("botlit.policyDetail.allowedTools", "Allowed Tools"),
262
267
  description: P("botlit.policyDetail.commaSeparatedMcpToolNames", "Comma-separated MCP tool names. End an entry with * to allow a prefix. Empty allows every tool."),
263
- children: /* @__PURE__ */ w(g, {
268
+ children: /* @__PURE__ */ T(_, {
264
269
  placeholder: P("botlit.policyDetail.exampleSearchRead", "e.g., search, read_*"),
265
- value: G.tool.allowedTools,
266
- onChange: (e) => Y("tool", { allowedTools: e.target.value })
270
+ value: K.tool.allowedTools,
271
+ onChange: (e) => X("tool", { allowedTools: e.target.value })
267
272
  })
268
273
  }),
269
- /* @__PURE__ */ w(h, {
274
+ /* @__PURE__ */ T(g, {
270
275
  label: P("botlit.policyDetail.deniedTools", "Denied Tools"),
271
276
  description: P("botlit.policyDetail.commaSeparatedMcpToolNames2", "Comma-separated MCP tool names that may never run. A deny always wins."),
272
- children: /* @__PURE__ */ w(g, {
277
+ children: /* @__PURE__ */ T(_, {
273
278
  placeholder: P("botlit.policyDetail.exampleDeleteExecuteCode", "e.g., delete_*, execute_code"),
274
- value: G.tool.deniedTools,
275
- onChange: (e) => Y("tool", { deniedTools: e.target.value })
279
+ value: K.tool.deniedTools,
280
+ onChange: (e) => X("tool", { deniedTools: e.target.value })
276
281
  })
277
282
  }),
278
- /* @__PURE__ */ T("div", {
283
+ /* @__PURE__ */ E("div", {
279
284
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
280
- children: [/* @__PURE__ */ w(h, {
285
+ children: [/* @__PURE__ */ T(g, {
281
286
  label: P("botlit.policyDetail.maxToolRiskLevel", "Max Tool Risk Level"),
282
- children: /* @__PURE__ */ T(S, {
287
+ children: /* @__PURE__ */ E(C, {
283
288
  className: M,
284
- value: G.tool.maxToolRiskLevel,
285
- onChange: (e) => Y("tool", { maxToolRiskLevel: e.target.value }),
286
- children: [/* @__PURE__ */ w("option", {
289
+ value: K.tool.maxToolRiskLevel,
290
+ onChange: (e) => X("tool", { maxToolRiskLevel: e.target.value }),
291
+ children: [/* @__PURE__ */ T("option", {
287
292
  value: "",
288
293
  children: P("botlit.policyDetail.anyRiskLevel", "Any risk level")
289
- }), he.map((e) => /* @__PURE__ */ w("option", {
294
+ }), ge.map((e) => /* @__PURE__ */ T("option", {
290
295
  value: e,
291
- children: P("botlit.policyDetail.upToLevel", "Up to {{level}}", { level: Pe[e] })
296
+ children: P("botlit.policyDetail.upToLevel", "Up to {{level}}", { level: Ie[e] })
292
297
  }, e))]
293
298
  })
294
- }), /* @__PURE__ */ w(h, {
299
+ }), /* @__PURE__ */ T(g, {
295
300
  label: P("botlit.policyDetail.minimumA2aTrustLevel", "Minimum A2A Trust Level"),
296
301
  description: P("botlit.policyDetail.forDelegationToExternalRegistry", "For delegation to external registry agents."),
297
- children: /* @__PURE__ */ T(S, {
302
+ children: /* @__PURE__ */ E(C, {
298
303
  className: M,
299
- value: G.tool.a2aMinTrustLevel,
300
- onChange: (e) => Y("tool", { a2aMinTrustLevel: e.target.value }),
301
- children: [/* @__PURE__ */ w("option", {
304
+ value: K.tool.a2aMinTrustLevel,
305
+ onChange: (e) => X("tool", { a2aMinTrustLevel: e.target.value }),
306
+ children: [/* @__PURE__ */ T("option", {
302
307
  value: "",
303
308
  children: P("botlit.policyDetail.defaultVerifiedPublisher", "Default (verified publisher)")
304
- }), se.map((e) => /* @__PURE__ */ w("option", {
309
+ }), ce.map((e) => /* @__PURE__ */ T("option", {
305
310
  value: e,
306
- children: Fe[e]
311
+ children: Le[e]
307
312
  }, e))]
308
313
  })
309
314
  })]
310
315
  }),
311
- /* @__PURE__ */ T("div", {
316
+ /* @__PURE__ */ E("div", {
312
317
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
313
- children: [/* @__PURE__ */ w(h, {
318
+ children: [/* @__PURE__ */ T(g, {
314
319
  label: P("botlit.policyDetail.maxToolCallsPerExecution", "Max Tool Calls Per Execution"),
315
320
  description: P("botlit.policyDetail.toolCallsAllowedInOne", "Tool calls allowed in one agent turn."),
316
- children: /* @__PURE__ */ w(g, {
321
+ children: /* @__PURE__ */ T(_, {
317
322
  type: "number",
318
323
  min: 1,
319
324
  placeholder: P("botlit.policyDetail.noLimit", "No limit"),
320
- value: G.tool.maxCallsPerExecution,
321
- onChange: (e) => Y("tool", { maxCallsPerExecution: e.target.value })
325
+ value: K.tool.maxCallsPerExecution,
326
+ onChange: (e) => X("tool", { maxCallsPerExecution: e.target.value })
322
327
  })
323
- }), /* @__PURE__ */ w(h, {
328
+ }), /* @__PURE__ */ T(g, {
324
329
  label: P("botlit.policyDetail.toolCallTimeoutSeconds", "Tool Call Timeout (seconds)"),
325
330
  description: P("botlit.policyDetail.canOnlyShortenThePlatform", "Can only shorten the platform's own timeout."),
326
- children: /* @__PURE__ */ w(g, {
331
+ children: /* @__PURE__ */ T(_, {
327
332
  type: "number",
328
333
  min: 1,
329
334
  placeholder: P("botlit.policyDetail.platformDefault", "Platform default"),
330
- value: G.tool.timeoutSeconds,
331
- onChange: (e) => Y("tool", { timeoutSeconds: e.target.value })
335
+ value: K.tool.timeoutSeconds,
336
+ onChange: (e) => X("tool", { timeoutSeconds: e.target.value })
332
337
  })
333
338
  })]
339
+ }),
340
+ /* @__PURE__ */ T(l, {
341
+ value: K.tool,
342
+ onChange: (e) => X("tool", e)
334
343
  })
335
344
  ]
336
345
  })] }),
337
- e === "BUDGET" && /* @__PURE__ */ T(l, { children: [/* @__PURE__ */ T(f, { children: [/* @__PURE__ */ T(p, {
346
+ e === "BUDGET" && /* @__PURE__ */ E(u, { children: [/* @__PURE__ */ E(p, { children: [/* @__PURE__ */ E(m, {
338
347
  className: "flex items-center gap-2",
339
- children: [/* @__PURE__ */ w(D, { size: 18 }), P("botlit.policyDetail.budgetPolicyConfiguration", "Budget Policy Configuration")]
340
- }), /* @__PURE__ */ w(d, { children: P("botlit.policyDetail.tokenBudgetsApplyPerAgent", "Token budgets apply per agent. Leave a field empty to not restrict it.") })] }), /* @__PURE__ */ w(u, {
348
+ children: [/* @__PURE__ */ T(Te, { size: 18 }), P("botlit.policyDetail.budgetPolicyConfiguration", "Budget Policy Configuration")]
349
+ }), /* @__PURE__ */ T(f, { children: P("botlit.policyDetail.tokenBudgetsApplyPerAgent", "Token budgets apply per agent. Leave a field empty to not restrict it.") })] }), /* @__PURE__ */ T(d, {
341
350
  className: "space-y-4",
342
- children: /* @__PURE__ */ T("div", {
351
+ children: /* @__PURE__ */ E("div", {
343
352
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
344
- children: [/* @__PURE__ */ w(h, {
353
+ children: [/* @__PURE__ */ T(g, {
345
354
  label: P("botlit.policyDetail.maxTokensPerDay", "Max Tokens Per Day"),
346
355
  description: P("botlit.policyDetail.anAgentThatHasUsed", "An agent that has used this many tokens today (UTC) is refused."),
347
- children: /* @__PURE__ */ w(g, {
356
+ children: /* @__PURE__ */ T(_, {
348
357
  type: "number",
349
358
  min: 1,
350
359
  placeholder: P("botlit.policyDetail.noLimit", "No limit"),
351
- value: G.budget.maxTokensPerDay,
352
- onChange: (e) => Y("budget", { maxTokensPerDay: e.target.value })
360
+ value: K.budget.maxTokensPerDay,
361
+ onChange: (e) => X("budget", { maxTokensPerDay: e.target.value })
353
362
  })
354
- }), /* @__PURE__ */ w(h, {
363
+ }), /* @__PURE__ */ T(g, {
355
364
  label: P("botlit.policyDetail.maxOutputTokensPerModel", "Max Output Tokens Per Model Call"),
356
365
  description: P("botlit.policyDetail.lowersTheAgentSOwn", "Lowers the agent's own max-tokens setting when it is higher."),
357
- children: /* @__PURE__ */ w(g, {
366
+ children: /* @__PURE__ */ T(_, {
358
367
  type: "number",
359
368
  min: 1,
360
369
  placeholder: P("botlit.policyDetail.noLimit", "No limit"),
361
- value: G.budget.maxTokensPerExecution,
362
- onChange: (e) => Y("budget", { maxTokensPerExecution: e.target.value })
370
+ value: K.budget.maxTokensPerExecution,
371
+ onChange: (e) => X("budget", { maxTokensPerExecution: e.target.value })
363
372
  })
364
373
  })]
365
374
  })
366
375
  })] }),
367
- e === "RATE_LIMIT" && /* @__PURE__ */ T(l, { children: [/* @__PURE__ */ T(f, { children: [/* @__PURE__ */ T(p, {
376
+ e === "RATE_LIMIT" && /* @__PURE__ */ E(u, { children: [/* @__PURE__ */ E(p, { children: [/* @__PURE__ */ E(m, {
368
377
  className: "flex items-center gap-2",
369
- children: [/* @__PURE__ */ w(Se, { size: 18 }), P("botlit.policyDetail.rateLimitConfiguration", "Rate Limit Configuration")]
370
- }), /* @__PURE__ */ w(d, { children: P("botlit.policyDetail.everyLimitIsCountedPer", "Every limit is counted per agent. Leave a field empty to not restrict it.") })] }), /* @__PURE__ */ w(u, {
378
+ children: [/* @__PURE__ */ T(Ce, { size: 18 }), P("botlit.policyDetail.rateLimitConfiguration", "Rate Limit Configuration")]
379
+ }), /* @__PURE__ */ T(f, { children: P("botlit.policyDetail.everyLimitIsCountedPer", "Every limit is counted per agent. Leave a field empty to not restrict it.") })] }), /* @__PURE__ */ T(d, {
371
380
  className: "space-y-4",
372
- children: /* @__PURE__ */ T("div", {
381
+ children: /* @__PURE__ */ E("div", {
373
382
  className: "grid grid-cols-1 sm:grid-cols-3 gap-4",
374
383
  children: [
375
- /* @__PURE__ */ w(h, {
384
+ /* @__PURE__ */ T(g, {
376
385
  label: P("botlit.policyDetail.requestsMinute", "Requests / Minute"),
377
- children: /* @__PURE__ */ w(g, {
386
+ children: /* @__PURE__ */ T(_, {
378
387
  type: "number",
379
388
  min: 1,
380
389
  placeholder: P("botlit.policyDetail.noLimit", "No limit"),
381
- value: G.rateLimit.requestsPerMinute,
382
- onChange: (e) => Y("rateLimit", { requestsPerMinute: e.target.value })
390
+ value: K.rateLimit.requestsPerMinute,
391
+ onChange: (e) => X("rateLimit", { requestsPerMinute: e.target.value })
383
392
  })
384
393
  }),
385
- /* @__PURE__ */ w(h, {
394
+ /* @__PURE__ */ T(g, {
386
395
  label: P("botlit.policyDetail.requestsHour", "Requests / Hour"),
387
- children: /* @__PURE__ */ w(g, {
396
+ children: /* @__PURE__ */ T(_, {
388
397
  type: "number",
389
398
  min: 1,
390
399
  placeholder: P("botlit.policyDetail.noLimit", "No limit"),
391
- value: G.rateLimit.requestsPerHour,
392
- onChange: (e) => Y("rateLimit", { requestsPerHour: e.target.value })
400
+ value: K.rateLimit.requestsPerHour,
401
+ onChange: (e) => X("rateLimit", { requestsPerHour: e.target.value })
393
402
  })
394
403
  }),
395
- /* @__PURE__ */ w(h, {
404
+ /* @__PURE__ */ T(g, {
396
405
  label: P("botlit.policyDetail.tokensMinute", "Tokens / Minute"),
397
- children: /* @__PURE__ */ w(g, {
406
+ children: /* @__PURE__ */ T(_, {
398
407
  type: "number",
399
408
  min: 1,
400
409
  placeholder: P("botlit.policyDetail.noLimit", "No limit"),
401
- value: G.rateLimit.tokensPerMinute,
402
- onChange: (e) => Y("rateLimit", { tokensPerMinute: e.target.value })
410
+ value: K.rateLimit.tokensPerMinute,
411
+ onChange: (e) => X("rateLimit", { tokensPerMinute: e.target.value })
403
412
  })
404
413
  })
405
414
  ]
406
415
  })
407
416
  })] }),
408
- e === "RESPONSE" && /* @__PURE__ */ T(l, { children: [/* @__PURE__ */ T(f, { children: [/* @__PURE__ */ T(p, {
417
+ e === "RESPONSE" && /* @__PURE__ */ E(u, { children: [/* @__PURE__ */ E(p, { children: [/* @__PURE__ */ E(m, {
409
418
  className: "flex items-center gap-2",
410
- children: [/* @__PURE__ */ w(O, { size: 18 }), P("botlit.policyDetail.modelUsageAllowlist", "Model Usage Allowlist")]
411
- }), /* @__PURE__ */ w(d, { children: P("botlit.policyDetail.agentsInThisWorkspaceMay", "Agents in this workspace may only answer with models that match every active model policy. Leave both fields empty to allow all models.") })] }), /* @__PURE__ */ T(u, {
419
+ children: [/* @__PURE__ */ T(O, { size: 18 }), P("botlit.policyDetail.modelUsageAllowlist", "Model Usage Allowlist")]
420
+ }), /* @__PURE__ */ T(f, { children: P("botlit.policyDetail.agentsInThisWorkspaceMay", "Agents in this workspace may only answer with models that match every active model policy. Leave both fields empty to allow all models.") })] }), /* @__PURE__ */ E(d, {
412
421
  className: "space-y-4",
413
- children: [/* @__PURE__ */ w(h, {
422
+ children: [/* @__PURE__ */ T(g, {
414
423
  label: P("botlit.policyDetail.allowedModels", "Allowed Models"),
415
424
  description: P("botlit.policyDetail.commaSeparatedModelIdsEnd", "Comma-separated model IDs. End an entry with * to allow a prefix."),
416
- children: /* @__PURE__ */ w(g, {
425
+ children: /* @__PURE__ */ T(_, {
417
426
  placeholder: P("botlit.policyDetail.exampleGpt4oMiniAnthropic", "e.g., gpt-4o-mini, anthropic.claude-*"),
418
- value: G.response.allowedModels,
419
- onChange: (e) => Y("response", { allowedModels: e.target.value })
427
+ value: K.response.allowedModels,
428
+ onChange: (e) => X("response", { allowedModels: e.target.value })
420
429
  })
421
- }), /* @__PURE__ */ w(h, {
430
+ }), /* @__PURE__ */ T(g, {
422
431
  label: P("botlit.policyDetail.allowedProviders", "Allowed Providers"),
423
432
  description: P("botlit.policyDetail.commaSeparatedProviderTypesE", "Comma-separated provider types, e.g. OPENAI, ANTHROPIC, AWS_BEDROCK."),
424
- children: /* @__PURE__ */ w(g, {
433
+ children: /* @__PURE__ */ T(_, {
425
434
  placeholder: P("botlit.policyDetail.exampleAwsBedrockAnthropic", "e.g., AWS_BEDROCK, ANTHROPIC"),
426
- value: G.response.allowedProviders,
427
- onChange: (e) => Y("response", { allowedProviders: e.target.value })
435
+ value: K.response.allowedProviders,
436
+ onChange: (e) => X("response", { allowedProviders: e.target.value })
428
437
  })
429
438
  })]
430
439
  })] }),
431
- e === "RESPONSE" && /* @__PURE__ */ T(l, { children: [/* @__PURE__ */ T(f, { children: [/* @__PURE__ */ T(p, {
440
+ e === "RESPONSE" && /* @__PURE__ */ E(u, { children: [/* @__PURE__ */ E(p, { children: [/* @__PURE__ */ E(m, {
432
441
  className: "flex items-center gap-2",
433
- children: [/* @__PURE__ */ w(O, { size: 18 }), P("botlit.policyDetail.responseStyleLengthAndCitations", "Response Style, Length And Citations")]
434
- }), /* @__PURE__ */ w(d, { children: P("botlit.policyDetail.personaToneFormalityStructureAnd", "Persona, tone, formality, structure and formatting are given to the model as instructions. The token limit caps every model call and longer answers are cut to the length limit. Leave a field empty to not set it.") })] }), /* @__PURE__ */ T(u, {
442
+ children: [/* @__PURE__ */ T(O, { size: 18 }), P("botlit.policyDetail.responseStyleLengthAndCitations", "Response Style, Length And Citations")]
443
+ }), /* @__PURE__ */ T(f, { children: P("botlit.policyDetail.personaToneFormalityStructureAnd", "Persona, tone, formality, structure and formatting are given to the model as instructions. The token limit caps every model call and longer answers are cut to the length limit. Leave a field empty to not set it.") })] }), /* @__PURE__ */ E(d, {
435
444
  className: "space-y-4",
436
445
  children: [
437
- /* @__PURE__ */ w(h, {
446
+ /* @__PURE__ */ T(g, {
438
447
  label: P("botlit.policyDetail.persona", "Persona"),
439
448
  description: P("botlit.policyDetail.whoTheAgentSpeaksAs", "Who the agent speaks as. Up to {{count}} characters.", { count: 2e3 }),
440
- children: /* @__PURE__ */ w(_, {
449
+ children: /* @__PURE__ */ T(v, {
441
450
  rows: 3,
442
451
  maxLength: 2e3,
443
452
  placeholder: P("botlit.policyDetail.exampleAPatientSupportSpecialist", "e.g., A patient support specialist for Acme Cloud"),
444
- value: G.response.persona,
445
- onChange: (e) => Y("response", { persona: e.target.value })
453
+ value: K.response.persona,
454
+ onChange: (e) => X("response", { persona: e.target.value })
446
455
  })
447
456
  }),
448
- /* @__PURE__ */ T("div", {
457
+ /* @__PURE__ */ E("div", {
449
458
  className: "grid grid-cols-1 sm:grid-cols-3 gap-4",
450
459
  children: [
451
- /* @__PURE__ */ w(h, {
460
+ /* @__PURE__ */ T(g, {
452
461
  label: P("botlit.policyDetail.tone", "Tone"),
453
- children: /* @__PURE__ */ w(g, {
462
+ children: /* @__PURE__ */ T(_, {
454
463
  placeholder: P("botlit.policyDetail.exampleFriendlyCalm", "e.g., friendly, calm"),
455
- value: G.response.tone,
456
- onChange: (e) => Y("response", { tone: e.target.value })
464
+ value: K.response.tone,
465
+ onChange: (e) => X("response", { tone: e.target.value })
457
466
  })
458
467
  }),
459
- /* @__PURE__ */ w(h, {
468
+ /* @__PURE__ */ T(g, {
460
469
  label: P("botlit.policyDetail.formality", "Formality"),
461
- children: /* @__PURE__ */ T(S, {
470
+ children: /* @__PURE__ */ E(C, {
462
471
  className: M,
463
- value: G.response.formality,
464
- onChange: (e) => Y("response", { formality: e.target.value }),
465
- children: [/* @__PURE__ */ w("option", {
472
+ value: K.response.formality,
473
+ onChange: (e) => X("response", { formality: e.target.value }),
474
+ children: [/* @__PURE__ */ T("option", {
466
475
  value: "",
467
476
  children: P("botlit.policyDetail.notSet", "Not set")
468
- }), pe.map((e) => /* @__PURE__ */ w("option", {
477
+ }), me.map((e) => /* @__PURE__ */ T("option", {
469
478
  value: e,
470
479
  children: e.charAt(0) + e.slice(1).toLowerCase()
471
480
  }, e))]
472
481
  })
473
482
  }),
474
- /* @__PURE__ */ w(h, {
483
+ /* @__PURE__ */ T(g, {
475
484
  label: P("botlit.policyDetail.structure", "Structure"),
476
- children: /* @__PURE__ */ T(S, {
485
+ children: /* @__PURE__ */ E(C, {
477
486
  className: M,
478
- value: G.response.structure,
479
- onChange: (e) => Y("response", { structure: e.target.value }),
480
- children: [/* @__PURE__ */ w("option", {
487
+ value: K.response.structure,
488
+ onChange: (e) => X("response", { structure: e.target.value }),
489
+ children: [/* @__PURE__ */ T("option", {
481
490
  value: "",
482
491
  children: P("botlit.policyDetail.notSet", "Not set")
483
- }), me.map((e) => /* @__PURE__ */ w("option", {
492
+ }), he.map((e) => /* @__PURE__ */ T("option", {
484
493
  value: e,
485
494
  children: e.split("_").map((e) => e.charAt(0) + e.slice(1).toLowerCase()).join(" ")
486
495
  }, e))]
@@ -488,74 +497,74 @@ var Me = ({ value: t, onChange: r }) => {
488
497
  })
489
498
  ]
490
499
  }),
491
- /* @__PURE__ */ w(h, {
500
+ /* @__PURE__ */ T(g, {
492
501
  label: P("botlit.policyDetail.formattingInstructions", "Formatting Instructions"),
493
- children: /* @__PURE__ */ w(g, {
502
+ children: /* @__PURE__ */ T(_, {
494
503
  placeholder: P("botlit.policyDetail.exampleEndEveryAnswerWith", "e.g., End every answer with a one-line summary"),
495
- value: G.response.formattingInstructions,
496
- onChange: (e) => Y("response", { formattingInstructions: e.target.value })
504
+ value: K.response.formattingInstructions,
505
+ onChange: (e) => X("response", { formattingInstructions: e.target.value })
497
506
  })
498
507
  }),
499
- /* @__PURE__ */ T("div", {
508
+ /* @__PURE__ */ E("div", {
500
509
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
501
- children: [/* @__PURE__ */ w(h, {
510
+ children: [/* @__PURE__ */ T(g, {
502
511
  label: P("botlit.policyDetail.maxResponseTokens", "Max Response Tokens"),
503
512
  description: P("botlit.policyDetail.capsTheOutputTokensOf", "Caps the output tokens of every model call."),
504
- children: /* @__PURE__ */ w(g, {
513
+ children: /* @__PURE__ */ T(_, {
505
514
  type: "number",
506
515
  min: 1,
507
516
  placeholder: P("botlit.policyDetail.noLimit", "No limit"),
508
- value: G.response.maxResponseTokens,
509
- onChange: (e) => Y("response", { maxResponseTokens: e.target.value })
517
+ value: K.response.maxResponseTokens,
518
+ onChange: (e) => X("response", { maxResponseTokens: e.target.value })
510
519
  })
511
- }), /* @__PURE__ */ w(h, {
520
+ }), /* @__PURE__ */ T(g, {
512
521
  label: P("botlit.policyDetail.maxResponseLengthCharacters", "Max Response Length (characters)"),
513
522
  description: P("botlit.policyDetail.longerAnswersAreCutAt", "Longer answers are cut at a word boundary."),
514
- children: /* @__PURE__ */ w(g, {
523
+ children: /* @__PURE__ */ T(_, {
515
524
  type: "number",
516
525
  min: 1,
517
526
  placeholder: P("botlit.policyDetail.noLimit", "No limit"),
518
- value: G.response.maxResponseLength,
519
- onChange: (e) => Y("response", { maxResponseLength: e.target.value })
527
+ value: K.response.maxResponseLength,
528
+ onChange: (e) => X("response", { maxResponseLength: e.target.value })
520
529
  })
521
530
  })]
522
531
  }),
523
- /* @__PURE__ */ T("div", {
532
+ /* @__PURE__ */ E("div", {
524
533
  className: "flex items-start gap-2",
525
- children: [/* @__PURE__ */ w("input", {
534
+ children: [/* @__PURE__ */ T("input", {
526
535
  type: "checkbox",
527
536
  id: "require-citations",
528
- checked: G.response.requireCitations,
529
- onChange: (e) => Y("response", { requireCitations: e.target.checked }),
537
+ checked: K.response.requireCitations,
538
+ onChange: (e) => X("response", { requireCitations: e.target.checked }),
530
539
  className: "mt-1 h-4 w-4"
531
- }), /* @__PURE__ */ T("label", {
540
+ }), /* @__PURE__ */ E("label", {
532
541
  htmlFor: "require-citations",
533
542
  className: "text-sm",
534
- children: [/* @__PURE__ */ w("span", {
543
+ children: [/* @__PURE__ */ T("span", {
535
544
  className: "font-medium",
536
545
  children: P("botlit.policyDetail.requireCitations", "Require citations")
537
- }), /* @__PURE__ */ w("span", {
546
+ }), /* @__PURE__ */ T("span", {
538
547
  className: "block text-text-secondary",
539
548
  children: P("botlit.policyDetail.whenKnowledgeBasePassagesGround", "When knowledge-base passages ground an answer and the answer cites none of them, either add the passage references or refuse the answer.")
540
549
  })]
541
550
  })]
542
551
  }),
543
- G.response.requireCitations && /* @__PURE__ */ w(h, {
552
+ K.response.requireCitations && /* @__PURE__ */ T(g, {
544
553
  label: P("botlit.policyDetail.whenCitationsAreMissing", "When Citations Are Missing"),
545
- children: /* @__PURE__ */ w(S, {
554
+ children: /* @__PURE__ */ T(C, {
546
555
  className: M,
547
- value: G.response.citationMode,
548
- onChange: (e) => Y("response", { citationMode: e.target.value }),
549
- children: ce.map((e) => /* @__PURE__ */ w("option", {
556
+ value: K.response.citationMode,
557
+ onChange: (e) => X("response", { citationMode: e.target.value }),
558
+ children: le.map((e) => /* @__PURE__ */ T("option", {
550
559
  value: e,
551
560
  children: e === "APPEND" ? P("botlit.policyDetail.addTheSourceReferences", "Add the source references") : P("botlit.policyDetail.refuseTheAnswer", "Refuse the answer")
552
561
  }, e))
553
562
  })
554
563
  }),
555
- /* @__PURE__ */ w(Me, {
556
- value: G.appliesToAgentIds,
564
+ /* @__PURE__ */ T(Pe, {
565
+ value: K.appliesToAgentIds,
557
566
  onChange: (e) => {
558
- J(null), K((t) => ({
567
+ Y(null), q((t) => ({
559
568
  ...t,
560
569
  appliesToAgentIds: e
561
570
  }));
@@ -563,44 +572,44 @@ var Me = ({ value: t, onChange: r }) => {
563
572
  })
564
573
  ]
565
574
  })] }),
566
- e === "DATA" && /* @__PURE__ */ T(l, { children: [/* @__PURE__ */ T(f, { children: [/* @__PURE__ */ T(p, {
575
+ e === "DATA" && /* @__PURE__ */ E(u, { children: [/* @__PURE__ */ E(p, { children: [/* @__PURE__ */ E(m, {
567
576
  className: "flex items-center gap-2",
568
- children: [/* @__PURE__ */ w(Ce, { size: 18 }), P("botlit.policyDetail.dataPolicyConfiguration", "Data Policy Configuration")]
569
- }), /* @__PURE__ */ w(d, { children: P("botlit.policyDetail.maskedValuesAreReplacedBefore", "Masked values are replaced before any model, tool or log sees them. Provider, region, tool and agent rules refuse a turn that would share data outside them.") })] }), /* @__PURE__ */ T(u, {
577
+ children: [/* @__PURE__ */ T(we, { size: 18 }), P("botlit.policyDetail.dataPolicyConfiguration", "Data Policy Configuration")]
578
+ }), /* @__PURE__ */ T(f, { children: P("botlit.policyDetail.maskedValuesAreReplacedBefore", "Masked values are replaced before any model, tool or log sees them. Provider, region, tool and agent rules refuse a turn that would share data outside them.") })] }), /* @__PURE__ */ E(d, {
570
579
  className: "space-y-4",
571
580
  children: [
572
- /* @__PURE__ */ w(h, {
581
+ /* @__PURE__ */ T(g, {
573
582
  label: P("botlit.policyDetail.mask", "Mask"),
574
- children: /* @__PURE__ */ w("div", {
583
+ children: /* @__PURE__ */ T("div", {
575
584
  className: "grid grid-cols-1 sm:grid-cols-2 gap-1",
576
- children: fe.map((e) => /* @__PURE__ */ T("label", {
585
+ children: pe.map((e) => /* @__PURE__ */ E("label", {
577
586
  className: "flex items-center gap-2 text-sm",
578
- children: [/* @__PURE__ */ w("input", {
587
+ children: [/* @__PURE__ */ T("input", {
579
588
  type: "checkbox",
580
589
  className: "h-4 w-4",
581
- checked: G.data.maskPii.includes(e),
582
- onChange: (t) => Y("data", { maskPii: N(G.data.maskPii, e, t.target.checked) })
583
- }), /* @__PURE__ */ w("span", { children: Ne[e] })]
590
+ checked: K.data.maskPii.includes(e),
591
+ onChange: (t) => X("data", { maskPii: N(K.data.maskPii, e, t.target.checked) })
592
+ }), /* @__PURE__ */ T("span", { children: Fe[e] })]
584
593
  }, e))
585
594
  })
586
595
  }),
587
- /* @__PURE__ */ w(h, {
596
+ /* @__PURE__ */ T(g, {
588
597
  label: P("botlit.policyDetail.customMaskingPatterns", "Custom Masking Patterns"),
589
598
  description: P("botlit.policyDetail.oneRegularExpressionPerLine2", "One regular expression per line; matches are replaced with [REDACTED]."),
590
- children: /* @__PURE__ */ w(_, {
599
+ children: /* @__PURE__ */ T(v, {
591
600
  rows: 3,
592
601
  placeholder: P("botlit.policyDetail.exampleMaskPattern", "e.g., EMP-\\d{5}"),
593
- value: G.data.maskPatterns,
594
- onChange: (e) => Y("data", { maskPatterns: e.target.value })
602
+ value: K.data.maskPatterns,
603
+ onChange: (e) => X("data", { maskPatterns: e.target.value })
595
604
  })
596
605
  }),
597
- /* @__PURE__ */ w(h, {
606
+ /* @__PURE__ */ T(g, {
598
607
  label: P("botlit.policyDetail.allowedRegions", "Allowed Regions"),
599
608
  description: P("botlit.policyDetail.commaSeparatedRegionsAModel", "Comma-separated regions a model provider may process data in; end an entry with * for a prefix. A provider whose region is not recorded is refused."),
600
- children: /* @__PURE__ */ w(g, {
609
+ children: /* @__PURE__ */ T(_, {
601
610
  placeholder: P("botlit.policyDetail.exampleApSouth1Eu", "e.g., ap-south-1, eu-*"),
602
- value: G.data.allowedRegions,
603
- onChange: (e) => Y("data", { allowedRegions: e.target.value })
611
+ value: K.data.allowedRegions,
612
+ onChange: (e) => X("data", { allowedRegions: e.target.value })
604
613
  })
605
614
  }),
606
615
  [
@@ -625,55 +634,55 @@ var Me = ({ value: t, onChange: r }) => {
625
634
  P("botlit.policyDetail.allowedDelegates", "Allowed agents to delegate to"),
626
635
  P("botlit.policyDetail.exampleDelegateRestriction", "Agent name or id; comma-separated, empty = none")
627
636
  ]
628
- ].map(([e, t, n, r, i]) => /* @__PURE__ */ T("div", {
637
+ ].map(([e, t, n, r, i]) => /* @__PURE__ */ E("div", {
629
638
  className: "space-y-2",
630
- children: [/* @__PURE__ */ T("label", {
639
+ children: [/* @__PURE__ */ E("label", {
631
640
  className: "flex items-center gap-2 text-sm",
632
- children: [/* @__PURE__ */ w("input", {
641
+ children: [/* @__PURE__ */ T("input", {
633
642
  type: "checkbox",
634
643
  className: "h-4 w-4",
635
- checked: G.data[e],
636
- onChange: (t) => Y("data", { [e]: t.target.checked })
637
- }), /* @__PURE__ */ w("span", {
644
+ checked: K.data[e],
645
+ onChange: (t) => X("data", { [e]: t.target.checked })
646
+ }), /* @__PURE__ */ T("span", {
638
647
  className: "font-medium",
639
648
  children: n
640
649
  })]
641
- }), G.data[e] && /* @__PURE__ */ w(g, {
650
+ }), K.data[e] && /* @__PURE__ */ T(_, {
642
651
  "aria-label": r,
643
652
  placeholder: i,
644
- value: G.data[t],
645
- onChange: (e) => Y("data", { [t]: e.target.value })
653
+ value: K.data[t],
654
+ onChange: (e) => X("data", { [t]: e.target.value })
646
655
  })]
647
656
  }, e)),
648
- /* @__PURE__ */ w(h, {
657
+ /* @__PURE__ */ T(g, {
649
658
  label: P("botlit.policyDetail.allowedKnowledgeClassifications", "Allowed Knowledge Classifications"),
650
659
  description: P("botlit.policyDetail.knowledgeBasesAreClassifiedBy", "Knowledge bases are classified by metadata.classification. Leave all unchecked to not restrict retrieval."),
651
- children: /* @__PURE__ */ w("div", {
660
+ children: /* @__PURE__ */ T("div", {
652
661
  className: "grid grid-cols-1 sm:grid-cols-3 gap-1",
653
- children: de.map((e) => /* @__PURE__ */ T("label", {
662
+ children: fe.map((e) => /* @__PURE__ */ E("label", {
654
663
  className: "flex items-center gap-2 text-sm",
655
- children: [/* @__PURE__ */ w("input", {
664
+ children: [/* @__PURE__ */ T("input", {
656
665
  type: "checkbox",
657
666
  className: "h-4 w-4",
658
- checked: G.data.allowedClassifications.includes(e),
659
- onChange: (t) => Y("data", { allowedClassifications: N(G.data.allowedClassifications, e, t.target.checked) })
660
- }), /* @__PURE__ */ w("span", { children: e.charAt(0) + e.slice(1).toLowerCase() })]
667
+ checked: K.data.allowedClassifications.includes(e),
668
+ onChange: (t) => X("data", { allowedClassifications: N(K.data.allowedClassifications, e, t.target.checked) })
669
+ }), /* @__PURE__ */ T("span", { children: e.charAt(0) + e.slice(1).toLowerCase() })]
661
670
  }, e))
662
671
  })
663
672
  }),
664
- /* @__PURE__ */ w(h, {
673
+ /* @__PURE__ */ T(g, {
665
674
  label: P("botlit.policyDetail.blockedKnowledgeLabels", "Blocked Knowledge Labels"),
666
675
  description: P("botlit.policyDetail.commaSeparatedKnowledgeBasesWith", "Comma-separated; knowledge bases with any of these labels (metadata.labels) are never retrieved."),
667
- children: /* @__PURE__ */ w(g, {
676
+ children: /* @__PURE__ */ T(_, {
668
677
  placeholder: P("botlit.policyDetail.exampleHrLegal", "e.g., hr, legal"),
669
- value: G.data.blockedLabels,
670
- onChange: (e) => Y("data", { blockedLabels: e.target.value })
678
+ value: K.data.blockedLabels,
679
+ onChange: (e) => X("data", { blockedLabels: e.target.value })
671
680
  })
672
681
  }),
673
- /* @__PURE__ */ w(Me, {
674
- value: G.appliesToAgentIds,
682
+ /* @__PURE__ */ T(Pe, {
683
+ value: K.appliesToAgentIds,
675
684
  onChange: (e) => {
676
- J(null), K((t) => ({
685
+ Y(null), q((t) => ({
677
686
  ...t,
678
687
  appliesToAgentIds: e
679
688
  }));
@@ -681,134 +690,134 @@ var Me = ({ value: t, onChange: r }) => {
681
690
  })
682
691
  ]
683
692
  })] }),
684
- e === "RETENTION" && /* @__PURE__ */ T(l, { children: [/* @__PURE__ */ T(f, { children: [/* @__PURE__ */ T(p, {
693
+ e === "RETENTION" && /* @__PURE__ */ E(u, { children: [/* @__PURE__ */ E(p, { children: [/* @__PURE__ */ E(m, {
685
694
  className: "flex items-center gap-2",
686
- children: [/* @__PURE__ */ w(k, { size: 18 }), P("botlit.policyDetail.retentionPolicyConfiguration", "Retention Policy Configuration")]
687
- }), /* @__PURE__ */ w(d, { children: P("botlit.policyDetail.aScheduledJobErasesContent", "A scheduled job erases content older than these periods every hour. With several active retention policies the shortest period applies. Leave a field empty to keep that content for the life of the workspace.") })] }), /* @__PURE__ */ w(u, {
695
+ children: [/* @__PURE__ */ T(k, { size: 18 }), P("botlit.policyDetail.retentionPolicyConfiguration", "Retention Policy Configuration")]
696
+ }), /* @__PURE__ */ T(f, { children: P("botlit.policyDetail.aScheduledJobErasesContent", "A scheduled job erases content older than these periods every hour. With several active retention policies the shortest period applies. Leave a field empty to keep that content for the life of the workspace.") })] }), /* @__PURE__ */ T(d, {
688
697
  className: "space-y-4",
689
- children: /* @__PURE__ */ T("div", {
698
+ children: /* @__PURE__ */ E("div", {
690
699
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
691
- children: [/* @__PURE__ */ w(h, {
700
+ children: [/* @__PURE__ */ T(g, {
692
701
  label: P("botlit.policyDetail.executionDataRetentionDays", "Execution Data Retention (days)"),
693
702
  description: P("botlit.policyDetail.inputsOutputsAndErrorsOf", "Inputs, outputs and errors of finished runs and agent-to-agent messages are erased this many days after the run ended; 0 keeps none. Run metrics stay."),
694
- children: /* @__PURE__ */ w(g, {
703
+ children: /* @__PURE__ */ T(_, {
695
704
  type: "number",
696
705
  min: 0,
697
706
  max: 3650,
698
707
  placeholder: P("botlit.policyDetail.keep", "Keep"),
699
- value: G.retention.executionDataRetentionDays,
700
- onChange: (e) => Y("retention", { executionDataRetentionDays: e.target.value })
708
+ value: K.retention.executionDataRetentionDays,
709
+ onChange: (e) => X("retention", { executionDataRetentionDays: e.target.value })
701
710
  })
702
- }), /* @__PURE__ */ w(h, {
711
+ }), /* @__PURE__ */ T(g, {
703
712
  label: P("botlit.policyDetail.conversationRetentionDays", "Conversation Retention (days)"),
704
713
  description: P("botlit.policyDetail.assistantConversationsOlderThanThis", "Assistant conversations older than this are retired and erased."),
705
- children: /* @__PURE__ */ w(g, {
714
+ children: /* @__PURE__ */ T(_, {
706
715
  type: "number",
707
716
  min: 1,
708
717
  max: 3650,
709
718
  placeholder: P("botlit.policyDetail.keep", "Keep"),
710
- value: G.retention.conversationRetentionDays,
711
- onChange: (e) => Y("retention", { conversationRetentionDays: e.target.value })
719
+ value: K.retention.conversationRetentionDays,
720
+ onChange: (e) => X("retention", { conversationRetentionDays: e.target.value })
712
721
  })
713
722
  })]
714
723
  })
715
724
  })] })
716
- ] }), et = () => {
725
+ ] }), nt = () => {
717
726
  if (!R) return;
718
- W({
727
+ G({
719
728
  name: R.name,
720
729
  description: R.description || "",
721
- visibility: y(R.visibility, Ae, "PRIVATE")
730
+ visibility: b(R.visibility, Me, "PRIVATE")
722
731
  });
723
- let e = _e(y(R.type, j, "CONTENT"), R.config);
724
- K(e), qe(e), J(null), B(!0);
732
+ let e = ve(b(R.type, j, "CONTENT"), R.config);
733
+ q(e), Je(e), Y(null), B(!0);
725
734
  };
726
- if (n) return /* @__PURE__ */ w(c, {
735
+ if (n) return /* @__PURE__ */ T(c, {
727
736
  title: P("botlit.policyDetail.createPolicy", "Create Policy"),
728
737
  description: P("botlit.policyDetail.defineGuardrailsAndConstraintsFor", "Define guardrails and constraints for your AI agents"),
729
- actions: /* @__PURE__ */ T("div", {
738
+ actions: /* @__PURE__ */ E("div", {
730
739
  className: "flex gap-2",
731
- children: [/* @__PURE__ */ w(m, {
740
+ children: [/* @__PURE__ */ T(h, {
732
741
  variant: "outline",
733
742
  onClick: () => L("policies"),
734
743
  children: P("botlit.policyDetail.cancel", "Cancel")
735
- }), /* @__PURE__ */ w(m, {
736
- leftIcon: /* @__PURE__ */ w(Ee, { size: 16 }),
737
- onClick: Ye,
738
- isLoading: ze,
739
- disabled: !V.name,
744
+ }), /* @__PURE__ */ T(h, {
745
+ leftIcon: /* @__PURE__ */ T(Oe, { size: 16 }),
746
+ onClick: Ze,
747
+ isLoading: Ve,
748
+ disabled: !H.name,
740
749
  children: P("botlit.policyDetail.create", "Create")
741
750
  })]
742
751
  }),
743
- children: /* @__PURE__ */ T("div", {
752
+ children: /* @__PURE__ */ E("div", {
744
753
  className: "max-w-2xl space-y-6",
745
754
  children: [
746
- /* @__PURE__ */ T(l, { children: [/* @__PURE__ */ w(f, { children: /* @__PURE__ */ w(p, { children: P("botlit.policyDetail.basicInformation", "Basic Information") }) }), /* @__PURE__ */ T(u, {
755
+ /* @__PURE__ */ E(u, { children: [/* @__PURE__ */ T(p, { children: /* @__PURE__ */ T(m, { children: P("botlit.policyDetail.basicInformation", "Basic Information") }) }), /* @__PURE__ */ E(d, {
747
756
  className: "space-y-4",
748
757
  children: [
749
- /* @__PURE__ */ w(h, {
758
+ /* @__PURE__ */ T(g, {
750
759
  label: P("botlit.policyDetail.policyName", "Policy Name"),
751
760
  required: !0,
752
- children: /* @__PURE__ */ w(g, {
761
+ children: /* @__PURE__ */ T(_, {
753
762
  placeholder: P("botlit.policyDetail.exampleProductionContentPolicy", "e.g., Production Content Policy"),
754
- value: V.name,
755
- onChange: (e) => H({
756
- ...V,
763
+ value: H.name,
764
+ onChange: (e) => U({
765
+ ...H,
757
766
  name: e.target.value
758
767
  })
759
768
  })
760
769
  }),
761
- /* @__PURE__ */ w(h, {
770
+ /* @__PURE__ */ T(g, {
762
771
  label: P("botlit.policyDetail.description", "Description"),
763
- children: /* @__PURE__ */ w(_, {
772
+ children: /* @__PURE__ */ T(v, {
764
773
  placeholder: P("botlit.policyDetail.whatDoesThisPolicyEnforce", "What does this policy enforce?"),
765
- value: V.description,
766
- onChange: (e) => H({
767
- ...V,
774
+ value: H.description,
775
+ onChange: (e) => U({
776
+ ...H,
768
777
  description: e.target.value
769
778
  }),
770
779
  rows: 3
771
780
  })
772
781
  }),
773
- /* @__PURE__ */ T("div", {
782
+ /* @__PURE__ */ E("div", {
774
783
  className: "grid grid-cols-2 gap-4",
775
- children: [/* @__PURE__ */ w(h, {
784
+ children: [/* @__PURE__ */ T(g, {
776
785
  label: P("botlit.policyDetail.policyType", "Policy Type"),
777
786
  required: !0,
778
- children: /* @__PURE__ */ w(S, {
787
+ children: /* @__PURE__ */ T(C, {
779
788
  className: M,
780
- value: V.type,
789
+ value: H.type,
781
790
  onChange: (e) => {
782
791
  let t = e.target.value;
783
- b(t) && (J(null), H({
784
- ...V,
792
+ x(t) && (Y(null), U({
793
+ ...H,
785
794
  type: t
786
795
  }));
787
796
  },
788
- children: le.map((e) => /* @__PURE__ */ w("option", {
797
+ children: ue.map((e) => /* @__PURE__ */ T("option", {
789
798
  value: e,
790
799
  children: F[e]
791
800
  }, e))
792
801
  })
793
- }), /* @__PURE__ */ w(h, {
802
+ }), /* @__PURE__ */ T(g, {
794
803
  label: P("botlit.policyDetail.visibility", "Visibility"),
795
- children: /* @__PURE__ */ T(S, {
804
+ children: /* @__PURE__ */ E(C, {
796
805
  className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
797
- value: V.visibility,
798
- onChange: (e) => H({
799
- ...V,
806
+ value: H.visibility,
807
+ onChange: (e) => U({
808
+ ...H,
800
809
  visibility: e.target.value
801
810
  }),
802
811
  children: [
803
- /* @__PURE__ */ w("option", {
812
+ /* @__PURE__ */ T("option", {
804
813
  value: "PRIVATE",
805
814
  children: P("botlit.policyDetail.private", "Private")
806
815
  }),
807
- /* @__PURE__ */ w("option", {
816
+ /* @__PURE__ */ T("option", {
808
817
  value: "WORKSPACE",
809
818
  children: P("botlit.policyDetail.workspace", "Workspace")
810
819
  }),
811
- /* @__PURE__ */ w("option", {
820
+ /* @__PURE__ */ T("option", {
812
821
  value: "PUBLIC",
813
822
  children: P("botlit.policyDetail.public", "Public")
814
823
  })
@@ -818,29 +827,29 @@ var Me = ({ value: t, onChange: r }) => {
818
827
  })
819
828
  ]
820
829
  })] }),
821
- $e(V.type),
822
- q && /* @__PURE__ */ w("p", {
830
+ tt(H.type),
831
+ J && /* @__PURE__ */ T("p", {
823
832
  className: "text-sm text-status-error-text",
824
833
  role: "alert",
825
- children: q
834
+ children: J
826
835
  }),
827
- /* @__PURE__ */ w(l, { children: /* @__PURE__ */ w(u, {
836
+ /* @__PURE__ */ T(u, { children: /* @__PURE__ */ T(d, {
828
837
  className: "pt-6",
829
- children: /* @__PURE__ */ T("div", {
838
+ children: /* @__PURE__ */ E("div", {
830
839
  className: "flex items-start gap-2",
831
- children: [/* @__PURE__ */ w("input", {
840
+ children: [/* @__PURE__ */ T("input", {
832
841
  type: "checkbox",
833
842
  id: "activate-on-create",
834
- checked: X,
835
- onChange: (e) => Je(e.target.checked),
843
+ checked: Ye,
844
+ onChange: (e) => Xe(e.target.checked),
836
845
  className: "mt-1 h-4 w-4"
837
- }), /* @__PURE__ */ T("label", {
846
+ }), /* @__PURE__ */ E("label", {
838
847
  htmlFor: "activate-on-create",
839
848
  className: "text-sm",
840
- children: [/* @__PURE__ */ w("span", {
849
+ children: [/* @__PURE__ */ T("span", {
841
850
  className: "font-medium",
842
851
  children: P("botlit.policyDetail.enforceImmediately", "Enforce immediately")
843
- }), /* @__PURE__ */ w("span", {
852
+ }), /* @__PURE__ */ T("span", {
844
853
  className: "block text-text-secondary",
845
854
  children: P("botlit.policyDetail.onlyActivePoliciesAreEnforced", "Only active policies are enforced. Leave unchecked to save this policy as a draft and activate it later.")
846
855
  })]
@@ -850,282 +859,282 @@ var Me = ({ value: t, onChange: r }) => {
850
859
  ]
851
860
  })
852
861
  });
853
- if (Ie) return /* @__PURE__ */ w(c, {
862
+ if (Re) return /* @__PURE__ */ T(c, {
854
863
  title: P("botlit.policyDetail.loading", "Loading..."),
855
- children: /* @__PURE__ */ w("div", { className: "h-96 bg-bg-sunken motion-safe:animate-vc-shimmer rounded-lg" })
864
+ children: /* @__PURE__ */ T("div", { className: "h-96 bg-bg-sunken motion-safe:animate-vc-shimmer rounded-lg" })
856
865
  });
857
- if (!R) return /* @__PURE__ */ w(c, {
866
+ if (!R) return /* @__PURE__ */ T(c, {
858
867
  title: P("botlit.policyDetail.policyNotFound", "Policy Not Found"),
859
- children: /* @__PURE__ */ w(ee, {
868
+ children: /* @__PURE__ */ T(te, {
860
869
  kind: "not-found",
861
870
  illustration: "empty-generic",
862
871
  title: P("botlit.policyDetail.policyNotFound", "Policy Not Found"),
863
872
  description: P("botlit.policyDetail.thisPolicyDoesnTExist", "This policy doesn't exist."),
864
- action: /* @__PURE__ */ w(m, {
873
+ action: /* @__PURE__ */ T(h, {
865
874
  onClick: () => L("policies"),
866
875
  children: P("botlit.policyDetail.backToPolicies", "Back to Policies")
867
876
  })
868
877
  })
869
878
  });
870
- let Q = y(R.type, j, "CONTENT"), $ = ve(Q, R.config);
871
- return /* @__PURE__ */ w(c, {
872
- title: /* @__PURE__ */ T("div", {
879
+ let Q = b(R.type, j, "CONTENT"), $ = ye(Q, R.config);
880
+ return /* @__PURE__ */ T(c, {
881
+ title: /* @__PURE__ */ E("div", {
873
882
  className: "flex items-center gap-3",
874
883
  children: [
875
- /* @__PURE__ */ w(m, {
884
+ /* @__PURE__ */ T(h, {
876
885
  variant: "ghost",
877
886
  size: "icon",
878
887
  onClick: () => L("policies"),
879
- children: /* @__PURE__ */ w(xe, { size: 20 })
888
+ children: /* @__PURE__ */ T(Se, { size: 20 })
880
889
  }),
881
- /* @__PURE__ */ w("div", {
890
+ /* @__PURE__ */ T("div", {
882
891
  className: "p-2 rounded-lg bg-action-primary-bg/10",
883
- children: /* @__PURE__ */ w(je, { type: Q })
892
+ children: /* @__PURE__ */ T(Ne, { type: Q })
884
893
  }),
885
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ T("div", {
894
+ /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ E("div", {
886
895
  className: "flex items-center gap-2",
887
- children: [/* @__PURE__ */ w("span", { children: R.name }), /* @__PURE__ */ w(ne, { status: R.status })]
888
- }), /* @__PURE__ */ w("p", {
896
+ children: [/* @__PURE__ */ T("span", { children: R.name }), /* @__PURE__ */ T(re, { status: R.status })]
897
+ }), /* @__PURE__ */ T("p", {
889
898
  className: "text-sm font-normal text-text-secondary",
890
899
  children: R.description
891
900
  })] })
892
901
  ]
893
902
  }),
894
- actions: /* @__PURE__ */ w("div", {
903
+ actions: /* @__PURE__ */ T("div", {
895
904
  className: "flex gap-2",
896
- children: z ? /* @__PURE__ */ T(C, { children: [/* @__PURE__ */ w(m, {
905
+ children: z ? /* @__PURE__ */ E(w, { children: [/* @__PURE__ */ T(h, {
897
906
  variant: "outline",
898
907
  onClick: () => B(!1),
899
908
  children: P("botlit.policyDetail.cancel", "Cancel")
900
- }), /* @__PURE__ */ w(m, {
901
- leftIcon: /* @__PURE__ */ w(Ee, { size: 16 }),
902
- onClick: Xe,
903
- isLoading: Ve,
904
- disabled: !U.name,
909
+ }), /* @__PURE__ */ T(h, {
910
+ leftIcon: /* @__PURE__ */ T(Oe, { size: 16 }),
911
+ onClick: Qe,
912
+ isLoading: Ue,
913
+ disabled: !W.name,
905
914
  children: P("botlit.policyDetail.saveChanges", "Save Changes")
906
- })] }) : /* @__PURE__ */ T(C, { children: [
907
- /* @__PURE__ */ w(s, {
915
+ })] }) : /* @__PURE__ */ E(w, { children: [
916
+ /* @__PURE__ */ T(s, {
908
917
  permission: o.POLICY_UPDATE,
909
- children: /* @__PURE__ */ w(m, {
918
+ children: /* @__PURE__ */ T(h, {
910
919
  variant: Z ? "outline" : "default",
911
- leftIcon: /* @__PURE__ */ w(Te, { size: 16 }),
912
- onClick: () => void Qe(),
913
- isLoading: Ve,
920
+ leftIcon: /* @__PURE__ */ T(De, { size: 16 }),
921
+ onClick: () => void et(),
922
+ isLoading: Ue,
914
923
  children: Z ? P("botlit.policyDetail.deactivate", "Deactivate") : P("botlit.policyDetail.activate", "Activate")
915
924
  })
916
925
  }),
917
- /* @__PURE__ */ w(s, {
926
+ /* @__PURE__ */ T(s, {
918
927
  permission: o.POLICY_UPDATE,
919
- children: /* @__PURE__ */ w(m, {
928
+ children: /* @__PURE__ */ T(h, {
920
929
  variant: "outline",
921
- leftIcon: /* @__PURE__ */ w(we, { size: 16 }),
922
- onClick: et,
930
+ leftIcon: /* @__PURE__ */ T(Ee, { size: 16 }),
931
+ onClick: nt,
923
932
  children: P("botlit.policyDetail.edit", "Edit")
924
933
  })
925
934
  }),
926
- We ? /* @__PURE__ */ T("div", {
935
+ Ke ? /* @__PURE__ */ E("div", {
927
936
  className: "flex gap-2",
928
- children: [/* @__PURE__ */ w(m, {
937
+ children: [/* @__PURE__ */ T(h, {
929
938
  variant: "outline",
930
939
  size: "sm",
931
- onClick: () => Ge(!1),
940
+ onClick: () => V(!1),
932
941
  children: P("botlit.policyDetail.cancel", "Cancel")
933
- }), /* @__PURE__ */ w(m, {
942
+ }), /* @__PURE__ */ T(h, {
934
943
  variant: "destructive",
935
944
  size: "sm",
936
945
  onClick: () => {
937
- i("medium"), Ze();
946
+ i("medium"), $e();
938
947
  },
939
- isLoading: Ue,
948
+ isLoading: Ge,
940
949
  children: P("botlit.policyDetail.confirmDelete", "Confirm Delete")
941
950
  })]
942
- }) : /* @__PURE__ */ w(s, {
951
+ }) : /* @__PURE__ */ T(s, {
943
952
  permission: o.POLICY_DELETE,
944
- children: /* @__PURE__ */ w(m, {
953
+ children: /* @__PURE__ */ T(h, {
945
954
  variant: "destructive",
946
- leftIcon: /* @__PURE__ */ w(k, { size: 16 }),
947
- onClick: () => Ge(!0),
955
+ leftIcon: /* @__PURE__ */ T(k, { size: 16 }),
956
+ onClick: () => V(!0),
948
957
  children: P("botlit.policyDetail.delete", "Delete")
949
958
  })
950
959
  })
951
960
  ] })
952
961
  }),
953
- children: /* @__PURE__ */ T("div", {
962
+ children: /* @__PURE__ */ E("div", {
954
963
  className: "space-y-6",
955
964
  children: [
956
- /* @__PURE__ */ w(ye, {
957
- icon: /* @__PURE__ */ w(Oe, { size: 18 }),
965
+ /* @__PURE__ */ T(be, {
966
+ icon: /* @__PURE__ */ T(Ae, { size: 18 }),
958
967
  children: P("botlit.policyDetail.thisIsASingleGuardrail", "This is a single guardrail and its rules. Review and tune exactly what it enforces — what content to block, which tools are allowed, the spend or rate limits it applies — then attach it to the agents and bots that should obey it. Policies are how you keep agents safe, compliant and within budget.")
959
968
  }),
960
- z && /* @__PURE__ */ T(l, { children: [/* @__PURE__ */ w(f, { children: /* @__PURE__ */ w(p, { children: P("botlit.policyDetail.editPolicy", "Edit Policy") }) }), /* @__PURE__ */ T(u, {
969
+ z && /* @__PURE__ */ E(u, { children: [/* @__PURE__ */ T(p, { children: /* @__PURE__ */ T(m, { children: P("botlit.policyDetail.editPolicy", "Edit Policy") }) }), /* @__PURE__ */ E(d, {
961
970
  className: "space-y-4",
962
971
  children: [
963
- /* @__PURE__ */ w(h, {
972
+ /* @__PURE__ */ T(g, {
964
973
  label: P("botlit.policyDetail.policyName", "Policy Name"),
965
974
  required: !0,
966
- children: /* @__PURE__ */ w(g, {
967
- value: U.name,
968
- onChange: (e) => W({
969
- ...U,
975
+ children: /* @__PURE__ */ T(_, {
976
+ value: W.name,
977
+ onChange: (e) => G({
978
+ ...W,
970
979
  name: e.target.value
971
980
  })
972
981
  })
973
982
  }),
974
- /* @__PURE__ */ w(h, {
983
+ /* @__PURE__ */ T(g, {
975
984
  label: P("botlit.policyDetail.description", "Description"),
976
- children: /* @__PURE__ */ w(_, {
977
- value: U.description,
978
- onChange: (e) => W({
979
- ...U,
985
+ children: /* @__PURE__ */ T(v, {
986
+ value: W.description,
987
+ onChange: (e) => G({
988
+ ...W,
980
989
  description: e.target.value
981
990
  }),
982
991
  rows: 3
983
992
  })
984
993
  }),
985
- /* @__PURE__ */ w(h, {
994
+ /* @__PURE__ */ T(g, {
986
995
  label: P("botlit.policyDetail.visibility", "Visibility"),
987
- children: /* @__PURE__ */ T(S, {
996
+ children: /* @__PURE__ */ E(C, {
988
997
  className: M,
989
- value: U.visibility,
990
- onChange: (e) => W({
991
- ...U,
998
+ value: W.visibility,
999
+ onChange: (e) => G({
1000
+ ...W,
992
1001
  visibility: e.target.value
993
1002
  }),
994
1003
  children: [
995
- /* @__PURE__ */ w("option", {
1004
+ /* @__PURE__ */ T("option", {
996
1005
  value: "PRIVATE",
997
1006
  children: P("botlit.policyDetail.private", "Private")
998
1007
  }),
999
- /* @__PURE__ */ w("option", {
1008
+ /* @__PURE__ */ T("option", {
1000
1009
  value: "WORKSPACE",
1001
1010
  children: P("botlit.policyDetail.workspace", "Workspace")
1002
1011
  }),
1003
- /* @__PURE__ */ w("option", {
1012
+ /* @__PURE__ */ T("option", {
1004
1013
  value: "PUBLIC",
1005
1014
  children: P("botlit.policyDetail.public", "Public")
1006
1015
  })
1007
1016
  ]
1008
1017
  })
1009
1018
  }),
1010
- /* @__PURE__ */ w("p", {
1019
+ /* @__PURE__ */ T("p", {
1011
1020
  className: "text-sm text-text-secondary",
1012
1021
  children: P("botlit.policyDetail.thePolicyTypeCannotBe", "The policy type cannot be changed after creation; its rules can be edited below.")
1013
1022
  })
1014
1023
  ]
1015
1024
  })] }),
1016
- z && R.type === Q && b(Q) && $e(Q),
1017
- z && q && /* @__PURE__ */ w("p", {
1025
+ z && R.type === Q && x(Q) && tt(Q),
1026
+ z && J && /* @__PURE__ */ T("p", {
1018
1027
  className: "text-sm text-status-error-text",
1019
1028
  role: "alert",
1020
- children: q
1029
+ children: J
1021
1030
  }),
1022
- /* @__PURE__ */ T("div", {
1031
+ /* @__PURE__ */ E("div", {
1023
1032
  className: "grid grid-cols-2 md:grid-cols-4 gap-4",
1024
1033
  children: [
1025
- /* @__PURE__ */ w(l, {
1034
+ /* @__PURE__ */ T(u, {
1026
1035
  treatment: "glass",
1027
1036
  glow: !0,
1028
- children: /* @__PURE__ */ T(u, {
1037
+ children: /* @__PURE__ */ E(d, {
1029
1038
  className: "pt-6 text-center",
1030
1039
  children: [
1031
- /* @__PURE__ */ w("div", {
1040
+ /* @__PURE__ */ T("div", {
1032
1041
  className: "p-3 rounded-full bg-action-primary-bg/10 w-fit mx-auto mb-2",
1033
- children: /* @__PURE__ */ w(je, { type: Q })
1042
+ children: /* @__PURE__ */ T(Ne, { type: Q })
1034
1043
  }),
1035
- /* @__PURE__ */ w("p", {
1044
+ /* @__PURE__ */ T("p", {
1036
1045
  className: "text-lg font-bold",
1037
1046
  children: F[Q]
1038
1047
  }),
1039
- /* @__PURE__ */ w("p", {
1048
+ /* @__PURE__ */ T("p", {
1040
1049
  className: "text-sm text-text-secondary",
1041
1050
  children: P("botlit.policyDetail.policyType", "Policy Type")
1042
1051
  })
1043
1052
  ]
1044
1053
  })
1045
1054
  }),
1046
- /* @__PURE__ */ w(l, { children: /* @__PURE__ */ T(u, {
1055
+ /* @__PURE__ */ T(u, { children: /* @__PURE__ */ E(d, {
1047
1056
  className: "pt-6 text-center",
1048
- children: [/* @__PURE__ */ w("p", {
1057
+ children: [/* @__PURE__ */ T("p", {
1049
1058
  className: "text-3xl font-bold text-text-primary capitalize",
1050
1059
  children: R.visibility.toLowerCase()
1051
- }), /* @__PURE__ */ w("p", {
1060
+ }), /* @__PURE__ */ T("p", {
1052
1061
  className: "text-sm text-text-secondary",
1053
1062
  children: P("botlit.policyDetail.visibility", "Visibility")
1054
1063
  })]
1055
1064
  }) }),
1056
- /* @__PURE__ */ w(l, { children: /* @__PURE__ */ T(u, {
1065
+ /* @__PURE__ */ T(u, { children: /* @__PURE__ */ E(d, {
1057
1066
  className: "pt-6 text-center",
1058
- children: [/* @__PURE__ */ w("p", {
1067
+ children: [/* @__PURE__ */ T("p", {
1059
1068
  className: "text-3xl font-bold text-text-primary",
1060
1069
  children: R.revision
1061
- }), /* @__PURE__ */ w("p", {
1070
+ }), /* @__PURE__ */ T("p", {
1062
1071
  className: "text-sm text-text-secondary",
1063
1072
  children: P("botlit.policyDetail.revision", "Revision")
1064
1073
  })]
1065
1074
  }) }),
1066
- /* @__PURE__ */ w(l, { children: /* @__PURE__ */ T(u, {
1075
+ /* @__PURE__ */ T(u, { children: /* @__PURE__ */ E(d, {
1067
1076
  className: "pt-6 text-center",
1068
- children: [/* @__PURE__ */ w("p", {
1077
+ children: [/* @__PURE__ */ T("p", {
1069
1078
  className: "text-lg font-bold text-text-primary",
1070
- children: v(R.updatedAt)
1071
- }), /* @__PURE__ */ w("p", {
1079
+ children: y(R.updatedAt)
1080
+ }), /* @__PURE__ */ T("p", {
1072
1081
  className: "text-sm text-text-secondary",
1073
1082
  children: P("botlit.policyDetail.lastUpdated", "Last Updated")
1074
1083
  })]
1075
1084
  }) })
1076
1085
  ]
1077
1086
  }),
1078
- /* @__PURE__ */ T(l, { children: [/* @__PURE__ */ T(f, { children: [/* @__PURE__ */ w(p, { children: P("botlit.policyDetail.configuration", "Configuration") }), /* @__PURE__ */ w(d, { children: P("botlit.policyDetail.currentPolicyConfiguration", "Current policy configuration") })] }), /* @__PURE__ */ T(u, {
1087
+ /* @__PURE__ */ E(u, { children: [/* @__PURE__ */ E(p, { children: [/* @__PURE__ */ T(m, { children: P("botlit.policyDetail.configuration", "Configuration") }), /* @__PURE__ */ T(f, { children: P("botlit.policyDetail.currentPolicyConfiguration", "Current policy configuration") })] }), /* @__PURE__ */ E(d, {
1079
1088
  className: "space-y-4",
1080
- children: [$ === null ? /* @__PURE__ */ T("div", {
1089
+ children: [$ === null ? /* @__PURE__ */ E("div", {
1081
1090
  className: "flex items-start gap-2 p-3 bg-status-warning-bg-subtle rounded-lg text-sm",
1082
1091
  "data-testid": "policy-not-enforced",
1083
- children: [/* @__PURE__ */ w(E, {
1092
+ children: [/* @__PURE__ */ T(D, {
1084
1093
  size: 16,
1085
1094
  className: "mt-0.5 shrink-0 text-status-warning-text"
1086
- }), /* @__PURE__ */ w("p", { children: P("botlit.policyDetail.legacyPolicyNotEnforced", "{{policyType}} settings are not enforced at runtime. This policy is kept for reference only and does not restrict any agent.", { policyType: F[Q] }) })]
1087
- }) : $.length > 0 ? /* @__PURE__ */ T("div", {
1095
+ }), /* @__PURE__ */ T("p", { children: P("botlit.policyDetail.legacyPolicyNotEnforced", "{{policyType}} settings are not enforced at runtime. This policy is kept for reference only and does not restrict any agent.", { policyType: F[Q] }) })]
1096
+ }) : $.length > 0 ? /* @__PURE__ */ E("div", {
1088
1097
  className: "flex items-start gap-2 p-3 bg-status-warning-bg-subtle rounded-lg text-sm",
1089
1098
  "data-testid": "policy-ignored-keys",
1090
- children: [/* @__PURE__ */ w(E, {
1099
+ children: [/* @__PURE__ */ T(D, {
1091
1100
  size: 16,
1092
1101
  className: "mt-0.5 shrink-0 text-status-warning-text"
1093
- }), /* @__PURE__ */ w("p", { children: P("botlit.policyDetail.ignoredSettingsWarning", "These settings are not enforced at runtime and have no effect: {{fields}}. Create a new policy to use the enforced settings.", { fields: $.join(", ") }) })]
1094
- }) : null, /* @__PURE__ */ w("div", {
1102
+ }), /* @__PURE__ */ T("p", { children: P("botlit.policyDetail.ignoredSettingsWarning", "These settings are not enforced at runtime and have no effect: {{fields}}. Create a new policy to use the enforced settings.", { fields: $.join(", ") }) })]
1103
+ }) : null, /* @__PURE__ */ T("div", {
1095
1104
  className: "p-4 bg-bg-sunken rounded-lg font-mono text-sm overflow-auto",
1096
- children: /* @__PURE__ */ w("pre", { children: JSON.stringify(R.config, null, 2) })
1105
+ children: /* @__PURE__ */ T("pre", { children: JSON.stringify(R.config, null, 2) })
1097
1106
  })]
1098
1107
  })] }),
1099
- /* @__PURE__ */ T(l, { children: [/* @__PURE__ */ w(f, { children: /* @__PURE__ */ T(p, {
1108
+ /* @__PURE__ */ E(u, { children: [/* @__PURE__ */ T(p, { children: /* @__PURE__ */ E(m, {
1100
1109
  className: "flex items-center gap-2",
1101
- children: [/* @__PURE__ */ w(De, { size: 18 }), P("botlit.policyDetail.metadata", "Metadata")]
1102
- }) }), /* @__PURE__ */ w(u, { children: /* @__PURE__ */ T("div", {
1110
+ children: [/* @__PURE__ */ T(ke, { size: 18 }), P("botlit.policyDetail.metadata", "Metadata")]
1111
+ }) }), /* @__PURE__ */ T(d, { children: /* @__PURE__ */ E("div", {
1103
1112
  className: "grid grid-cols-2 md:grid-cols-4 gap-6 text-sm",
1104
1113
  children: [
1105
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
1114
+ /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T("p", {
1106
1115
  className: "text-text-secondary",
1107
1116
  children: P("botlit.policyDetail.created", "Created")
1108
- }), /* @__PURE__ */ w("p", {
1117
+ }), /* @__PURE__ */ T("p", {
1109
1118
  className: "font-medium",
1110
- children: v(R.createdAt)
1119
+ children: y(R.createdAt)
1111
1120
  })] }),
1112
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
1121
+ /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T("p", {
1113
1122
  className: "text-text-secondary",
1114
1123
  children: P("botlit.policyDetail.updated", "Updated")
1115
- }), /* @__PURE__ */ w("p", {
1124
+ }), /* @__PURE__ */ T("p", {
1116
1125
  className: "font-medium",
1117
- children: v(R.updatedAt)
1126
+ children: y(R.updatedAt)
1118
1127
  })] }),
1119
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
1128
+ /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T("p", {
1120
1129
  className: "text-text-secondary",
1121
1130
  children: P("botlit.policyDetail.tags", "Tags")
1122
- }), /* @__PURE__ */ w("div", {
1131
+ }), /* @__PURE__ */ T("div", {
1123
1132
  className: "flex gap-1",
1124
- children: R.tags.length > 0 ? R.tags.map((e) => /* @__PURE__ */ w(te, {
1133
+ children: R.tags.length > 0 ? R.tags.map((e) => /* @__PURE__ */ T(ne, {
1125
1134
  variant: "secondary",
1126
1135
  className: "text-xs",
1127
1136
  children: e
1128
- }, e)) : /* @__PURE__ */ w("span", {
1137
+ }, e)) : /* @__PURE__ */ T("span", {
1129
1138
  className: "text-text-secondary",
1130
1139
  children: P("botlit.policyDetail.none", "None")
1131
1140
  })