@parallelworks/tandem-web 0.178.0 → 0.179.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -11,46 +11,46 @@ import { useTermRefs as g } from "../lib/knowledge.js";
11
11
  import { copyItem as _, useLinkItems as v } from "../lib/menus.js";
12
12
  import { useNewIssue as y } from "../lib/newIssue.js";
13
13
  import { usePeople as b } from "../lib/people.js";
14
- import { usePermissionModeName as ee } from "../lib/permissionModes.js";
15
- import { Link as x, useNavigate as te } from "../lib/router.js";
16
- import { useTime as S } from "../lib/time.js";
17
- import { AgentPage as C } from "./AgentPage.js";
18
- import { Editor as w } from "./Editor.js";
14
+ import { runnerModeCommand as ee, usePermissionModeName as x } from "../lib/permissionModes.js";
15
+ import { Link as S, useNavigate as te } from "../lib/router.js";
16
+ import { useTime as C } from "../lib/time.js";
17
+ import { AgentPage as w } from "./AgentPage.js";
18
+ import { Editor as T } from "./Editor.js";
19
19
  import { pullRequestNumber as ne } from "./IssueCode.js";
20
- import { AreaIcon as T, CodeHostIcon as re, FileTextIcon as ie, LibraryIcon as ae, PullRequestIcon as oe } from "./icons.js";
20
+ import { AreaIcon as E, CodeHostIcon as re, FileTextIcon as ie, LibraryIcon as ae, PullRequestIcon as oe } from "./icons.js";
21
21
  import { RunnerBadge as se } from "./RunnerBadge.js";
22
- import { Avatar as ce, Button as E, Card as le, CopyCodeBlock as D, Disclosure as O, ErrorText as ue, NumberInput as k, RelativeTime as A, Tooltip as j, menuDivider as de, useOpenMenu as fe } from "@parallelworks/ui";
23
- import { useParams as M } from "@tanstack/react-router";
24
- import { useCallback as N, useEffect as P, useRef as F, useState as I } from "react";
25
- import { useErrorMessage as pe } from "@parallelworks/problem/react";
26
- import { useFormatter as L, useTranslations as R } from "use-intl";
27
- import { Fragment as z, jsx as B, jsxs as V } from "react/jsx-runtime";
28
- import { useMutation as me, useQuery as H, useQueryClient as he, useSuspenseQuery as U } from "@tanstack/react-query";
29
- import { MoreButton as ge } from "@parallelworks/ui/list";
22
+ import { Avatar as ce, Button as D, Card as le, CopyCodeBlock as O, Disclosure as k, ErrorText as ue, NumberInput as A, RelativeTime as de, Tooltip as fe, menuDivider as pe, useOpenMenu as me } from "@parallelworks/ui";
23
+ import { useParams as j } from "@tanstack/react-router";
24
+ import { useCallback as M, useEffect as N, useRef as P, useState as F } from "react";
25
+ import { useErrorMessage as he } from "@parallelworks/problem/react";
26
+ import { useFormatter as I, useTranslations as L } from "use-intl";
27
+ import { Fragment as R, jsx as z, jsxs as B } from "react/jsx-runtime";
28
+ import { useMutation as ge, useQuery as V, useQueryClient as _e, useSuspenseQuery as H } from "@tanstack/react-query";
29
+ import { MoreButton as ve } from "@parallelworks/ui/list";
30
30
  // src/components/AgentWork.tsx
31
- var _e = "var(--agent-tone)";
32
- function ve() {
33
- let e = L();
31
+ var ye = "var(--agent-tone)";
32
+ function be() {
33
+ let e = I();
34
34
  return (t) => e.number(t / 1e6, {
35
35
  style: "currency",
36
36
  currency: "USD"
37
37
  });
38
38
  }
39
- function ye({ workspace: e, identifier: t }) {
40
- let { data: n } = U(l(e, t)), { data: r } = U(a(e, t)), i = r.filter((e) => !e.answer && !e.canceled), o = r.filter((e) => e.answer && !e.canceled), s = n.filter((e, t) => t === 0 || !["closed", "stopped"].includes(e.state)), c = R("agentWork");
41
- return n.length === 0 ? null : /* @__PURE__ */ V("section", {
39
+ function xe({ workspace: e, identifier: t }) {
40
+ let { data: n } = H(l(e, t)), { data: r } = H(a(e, t)), i = r.filter((e) => !e.answer && !e.canceled), o = r.filter((e) => e.answer && !e.canceled), s = n.filter((e, t) => t === 0 || !["closed", "stopped"].includes(e.state)), c = L("agentWork");
41
+ return n.length === 0 ? null : /* @__PURE__ */ B("section", {
42
42
  className: "mt-8 space-y-3",
43
43
  "aria-label": c("label"),
44
44
  children: [
45
- i.map((t) => /* @__PURE__ */ B(X, {
45
+ i.map((t) => /* @__PURE__ */ z(X, {
46
46
  workspace: e,
47
47
  decision: t
48
48
  }, t.id)),
49
- o.length > 0 && /* @__PURE__ */ B($, {
49
+ o.length > 0 && /* @__PURE__ */ z($, {
50
50
  workspace: e,
51
51
  decisions: o
52
52
  }),
53
- s.map((n) => /* @__PURE__ */ B(be, {
53
+ s.map((n) => /* @__PURE__ */ z(Se, {
54
54
  workspace: e,
55
55
  identifier: t,
56
56
  run: n
@@ -58,10 +58,10 @@ function ye({ workspace: e, identifier: t }) {
58
58
  ]
59
59
  });
60
60
  }
61
- function be({ workspace: i, identifier: a, run: s }) {
62
- let c = R("agentWork"), d = R("common"), f = pe(), p = ee(), g = S(), v = ve(), y = (e) => c(`state.${e}`), { nameOf: x } = b(i), C = he(), [T, ie] = I(s.state === "working"), ae = () => {
63
- C.invalidateQueries({ queryKey: l(i, a).queryKey }), n(C, i, a);
64
- }, D = me({
61
+ function Se({ workspace: i, identifier: a, run: s }) {
62
+ let c = L("agentWork"), d = L("common"), f = he(), p = x(), g = C(), v = be(), y = (e) => c(`state.${e}`), { nameOf: S } = b(i), w = _e(), [E, ie] = F(s.state === "working"), ae = () => {
63
+ w.invalidateQueries({ queryKey: l(i, a).queryKey }), n(w, i, a);
64
+ }, O = ge({
65
65
  mutationFn: async (n) => t(await e.POST("/api/v1/workspaces/{workspace}/runs/{runId}/move", {
66
66
  params: { path: {
67
67
  workspace: i,
@@ -70,13 +70,13 @@ function be({ workspace: i, identifier: a, run: s }) {
70
70
  body: n
71
71
  })),
72
72
  onSettled: ae
73
- }), [O, k] = I(!1), [A, j] = I(""), M = me({
73
+ }), [k, A] = F(!1), [de, fe] = F(""), j = ge({
74
74
  mutationFn: async () => (t(await e.POST("/api/v1/workspaces/{workspace}/issues/{identifier}/comments", {
75
75
  params: { path: {
76
76
  workspace: i,
77
77
  identifier: a
78
78
  } },
79
- body: { body: A }
79
+ body: { body: de }
80
80
  })), t(await e.POST("/api/v1/workspaces/{workspace}/runs/{runId}/move", {
81
81
  params: { path: {
82
82
  workspace: i,
@@ -88,10 +88,10 @@ function be({ workspace: i, identifier: a, run: s }) {
88
88
  }
89
89
  }))),
90
90
  onSuccess: () => {
91
- k(!1), j("");
91
+ A(!1), fe("");
92
92
  },
93
93
  onSettled: ae
94
- }), N = D.isPending || M.isPending, P = Se(s), [F, L] = I(!1), U = () => P ? L(!0) : D.mutate({ state: "queued" }), ye = P && {
94
+ }), M = O.isPending || j.isPending, N = we(s), [P, I] = F(!1), H = () => N ? I(!0) : O.mutate({ state: "queued" }), xe = N && {
95
95
  turns: {
96
96
  used: s.turns,
97
97
  allowed: s.budget.maxTurns
@@ -104,116 +104,116 @@ function be({ workspace: i, identifier: a, run: s }) {
104
104
  used: v(s.costMicros),
105
105
  allowed: v(s.budget.maxCostMicros)
106
106
  }
107
- }[P], be = !["closed", "stopped"].includes(s.state), W = s.state === "done_pending_verification", K = fe(), Te = te(), { data: Ee = [] } = H(r(i)), q = Ee.find((e) => e.id === s.agentId), { data: De = [] } = H(o(i, a)), J = De.find((e) => e.runId === s.id), Y = R("code"), Oe = q?.slug, X = h(), Z = X && (s.harnessSession || s.runnerName) ? {
107
+ }[N], Se = !["closed", "stopped"].includes(s.state), U = s.state === "done_pending_verification", G = me(), De = te(), { data: Oe = [] } = V(r(i)), K = Oe.find((e) => e.id === s.agentId), { data: ke = [] } = V(o(i, a)), q = ke.find((e) => e.runId === s.id), J = L("code"), Y = K?.slug, X = h(), Z = X && (s.harnessSession || s.runnerName) ? {
108
108
  label: c("openRunIn", { name: X.action.label }),
109
109
  onClick: () => X.open(s)
110
110
  } : void 0, Q = () => [
111
111
  ...Z ? [Z] : [],
112
- ...W ? [{
112
+ ...U ? [{
113
113
  label: c("accept"),
114
- onClick: () => D.mutate({ state: "closed" })
114
+ onClick: () => O.mutate({ state: "closed" })
115
115
  }, {
116
116
  label: c("requestChanges"),
117
- onClick: () => k(!0)
117
+ onClick: () => A(!0)
118
118
  }] : [],
119
119
  ...s.state === "stopped" || s.state === "blocked_external" ? [{
120
120
  label: c("resume"),
121
- onClick: () => U()
121
+ onClick: () => H()
122
122
  }] : [],
123
- ...be ? [{
123
+ ...Se ? [{
124
124
  label: c("stop"),
125
125
  destructive: !0,
126
- onClick: () => D.mutate({ state: "stopped" })
126
+ onClick: () => O.mutate({ state: "stopped" })
127
127
  }] : [],
128
- de,
129
- ...Oe ? [{
128
+ pe,
129
+ ...Y ? [{
130
130
  label: c("openAgent"),
131
- onClick: () => Te({
131
+ onClick: () => De({
132
132
  to: "/$workspace/agents/$slug",
133
133
  params: {
134
134
  workspace: i,
135
- slug: Oe
135
+ slug: Y
136
136
  }
137
137
  })
138
138
  }] : [],
139
139
  _(c("copyRunId"), s.id)
140
140
  ], $ = s.state === "working" || s.state === "queued";
141
- return s.state === "closed" ? /* @__PURE__ */ V("div", {
142
- onContextMenu: (e) => K(e, Q()),
141
+ return s.state === "closed" ? /* @__PURE__ */ B("div", {
142
+ onContextMenu: (e) => G(e, Q()),
143
143
  className: "group flex items-center gap-2 px-1 text-xs text-muted-foreground",
144
144
  children: [
145
- /* @__PURE__ */ B(ce, {
145
+ /* @__PURE__ */ z(ce, {
146
146
  kind: "agent",
147
147
  name: s.agentName,
148
148
  size: "xs",
149
149
  decorative: !0
150
150
  }),
151
- /* @__PURE__ */ B("span", { children: c.rich("accepted", {
151
+ /* @__PURE__ */ z("span", { children: c.rich("accepted", {
152
152
  agent: s.agentName,
153
153
  when: g.relative(s.updatedAt),
154
- name: (e) => /* @__PURE__ */ B("span", {
154
+ name: (e) => /* @__PURE__ */ z("span", {
155
155
  className: "font-medium text-foreground",
156
156
  children: e
157
157
  })
158
158
  }) }),
159
- /* @__PURE__ */ B(ge, {
159
+ /* @__PURE__ */ z(ve, {
160
160
  items: Q,
161
161
  label: d("moreActionsFor", { name: s.agentName }),
162
162
  className: "ml-auto"
163
163
  })
164
164
  ]
165
- }) : /* @__PURE__ */ V(le, {
165
+ }) : /* @__PURE__ */ B(le, {
166
166
  size: "fill",
167
167
  padding: "none",
168
- tone: W ? _e : void 0,
168
+ tone: U ? ye : void 0,
169
169
  interactive: !1,
170
170
  className: "text-sm",
171
- render: /* @__PURE__ */ B("section", {
171
+ render: /* @__PURE__ */ z("section", {
172
172
  "aria-label": c("runLabel", {
173
173
  agent: s.agentName,
174
174
  state: y(s.state)
175
175
  }),
176
176
  onContextMenu: (e) => {
177
- e.target.closest(".ProseMirror[contenteditable=\"true\"]") || K(e, Q());
177
+ e.target.closest(".ProseMirror[contenteditable=\"true\"]") || G(e, Q());
178
178
  }
179
179
  }),
180
180
  children: [
181
- /* @__PURE__ */ V("header", {
181
+ /* @__PURE__ */ B("header", {
182
182
  className: "flex items-center gap-2 px-3 pt-2.5",
183
183
  children: [
184
- /* @__PURE__ */ B(ce, {
184
+ /* @__PURE__ */ z(ce, {
185
185
  kind: "agent",
186
186
  name: s.agentName,
187
187
  size: "xs",
188
188
  decorative: !0
189
189
  }),
190
- /* @__PURE__ */ B("span", {
190
+ /* @__PURE__ */ z("span", {
191
191
  className: "font-medium",
192
192
  children: s.agentName
193
193
  }),
194
- /* @__PURE__ */ B("span", {
194
+ /* @__PURE__ */ z("span", {
195
195
  className: "truncate text-muted-foreground",
196
- children: c("assignedBy", { name: x("user", s.assignedBy) })
196
+ children: c("assignedBy", { name: S("user", s.assignedBy) })
197
197
  }),
198
- /* @__PURE__ */ V("span", {
199
- className: G("ml-auto inline-flex shrink-0 items-center gap-1.5 text-xs font-medium", W || $ ? "text-agent" : "text-muted-foreground"),
198
+ /* @__PURE__ */ B("span", {
199
+ className: W("ml-auto inline-flex shrink-0 items-center gap-1.5 text-xs font-medium", U || $ ? "text-agent" : "text-muted-foreground"),
200
200
  children: [
201
- $ && /* @__PURE__ */ V("span", {
201
+ $ && /* @__PURE__ */ B("span", {
202
202
  className: "relative flex size-1.5",
203
203
  "aria-hidden": "true",
204
- children: [s.state === "working" && /* @__PURE__ */ B("span", { className: "absolute inline-flex size-full animate-ping rounded-full bg-agent opacity-60 motion-reduce:hidden" }), /* @__PURE__ */ B("span", { className: "relative inline-flex size-1.5 rounded-full bg-agent" })]
204
+ children: [s.state === "working" && /* @__PURE__ */ z("span", { className: "absolute inline-flex size-full animate-ping rounded-full bg-agent opacity-60 motion-reduce:hidden" }), /* @__PURE__ */ z("span", { className: "relative inline-flex size-1.5 rounded-full bg-agent" })]
205
205
  }),
206
206
  y(s.state),
207
- s.state === "working" && s.runnerName ? /* @__PURE__ */ B("span", {
207
+ s.state === "working" && s.runnerName ? /* @__PURE__ */ z("span", {
208
208
  className: "inline-flex items-center gap-1 font-normal text-muted-foreground",
209
- children: c.rich("onRunner", { runner: () => /* @__PURE__ */ B(se, {
209
+ children: c.rich("onRunner", { runner: () => /* @__PURE__ */ z(se, {
210
210
  workspace: i,
211
211
  name: s.runnerName ?? "",
212
212
  kind: s.runnerKind
213
213
  }) })
214
- }) : s.state !== "queued" && s.lastRunnerName && /* @__PURE__ */ B("span", {
214
+ }) : s.state !== "queued" && s.lastRunnerName && /* @__PURE__ */ z("span", {
215
215
  className: "inline-flex items-center gap-1 font-normal text-muted-foreground",
216
- children: c.rich("ranOnRunner", { runner: () => /* @__PURE__ */ B(se, {
216
+ children: c.rich("ranOnRunner", { runner: () => /* @__PURE__ */ z(se, {
217
217
  workspace: i,
218
218
  name: s.lastRunnerName ?? "",
219
219
  kind: s.runnerKind
@@ -221,14 +221,14 @@ function be({ workspace: i, identifier: a, run: s }) {
221
221
  })
222
222
  ]
223
223
  }),
224
- Z && s.state === "working" && /* @__PURE__ */ B(E, {
224
+ Z && s.state === "working" && /* @__PURE__ */ z(D, {
225
225
  size: "sm",
226
226
  variant: "ghost",
227
227
  onClick: Z.onClick,
228
228
  className: "-my-1",
229
229
  children: Z.label
230
230
  }),
231
- /* @__PURE__ */ B(ge, {
231
+ /* @__PURE__ */ z(ve, {
232
232
  items: Q,
233
233
  label: d("moreActionsFor", { name: s.agentName }),
234
234
  visible: !0,
@@ -236,138 +236,143 @@ function be({ workspace: i, identifier: a, run: s }) {
236
236
  })
237
237
  ]
238
238
  }),
239
- s.state === "queued" && q && !q.runnable ? /* @__PURE__ */ B("p", {
239
+ s.state === "queued" && K && !K.runnable ? /* @__PURE__ */ z("p", {
240
240
  className: "px-3 pt-1.5 text-pretty text-muted-foreground",
241
- children: c("noRunnerForHarness", { harness: u[q.harness] ?? q.harness })
242
- }) : s.state === "queued" && s.waiting && /* @__PURE__ */ B("p", {
241
+ children: c("noRunnerForHarness", { harness: u[K.harness] ?? K.harness })
242
+ }) : s.state === "queued" && s.waiting && /* @__PURE__ */ z("p", {
243
243
  className: "px-3 pt-1.5 text-pretty text-muted-foreground",
244
- children: c(`waiting.${s.waiting}`, { name: x("user", s.assignedBy) })
244
+ children: c(`waiting.${s.waiting}`, { name: S("user", s.assignedBy) })
245
245
  }),
246
- s.permissionMode && s.permissionMode !== s.agentPermissionMode && /* @__PURE__ */ B("p", {
246
+ s.permissionMode && s.permissionMode !== s.agentPermissionMode && /* @__PURE__ */ z("p", {
247
247
  className: "px-3 pt-1.5 text-pretty text-muted-foreground",
248
- children: c("modeLowered", {
248
+ children: s.runnerName ? c.rich("modeLoweredBy", {
249
+ runner: s.runnerName,
250
+ got: p(s.permissionMode),
251
+ asked: p(s.agentPermissionMode),
252
+ code: () => /* @__PURE__ */ z("code", { children: ee(s.agentPermissionMode) })
253
+ }) : c("modeLowered", {
249
254
  got: p(s.permissionMode),
250
255
  asked: p(s.agentPermissionMode)
251
256
  })
252
257
  }),
253
- s.state === "stopped" && P && ye ? /* @__PURE__ */ B("p", {
258
+ s.state === "stopped" && N && xe ? /* @__PURE__ */ z("p", {
254
259
  className: "px-3 pt-1.5 text-pretty",
255
- children: c(`spent.${P}`, ye)
256
- }) : s.stopReason && s.state !== "working" && s.state !== "queued" && /* @__PURE__ */ B("p", {
260
+ children: c(`spent.${N}`, xe)
261
+ }) : s.stopReason && s.state !== "working" && s.state !== "queued" && /* @__PURE__ */ z("p", {
257
262
  className: "px-3 pt-1.5 text-pretty",
258
263
  children: s.stopReason
259
264
  }),
260
- W && s.verification && /* @__PURE__ */ V("p", {
265
+ U && s.verification && /* @__PURE__ */ B("p", {
261
266
  className: "flex flex-wrap items-center gap-x-3 px-3 pt-1.5 text-xs",
262
- children: [/* @__PURE__ */ B("span", {
263
- className: G(s.verification.checks === "passing" && "text-success", s.verification.checks === "failing" && "text-danger", (s.verification.checks === "pending" || s.verification.checks === "none") && "text-muted-foreground"),
267
+ children: [/* @__PURE__ */ z("span", {
268
+ className: W(s.verification.checks === "passing" && "text-success", s.verification.checks === "failing" && "text-danger", (s.verification.checks === "pending" || s.verification.checks === "none") && "text-muted-foreground"),
264
269
  children: c(`verifyChecks.${s.verification.checks}`)
265
- }), /* @__PURE__ */ B("span", {
270
+ }), /* @__PURE__ */ z("span", {
266
271
  className: s.verification.objections ? "text-warning" : "text-success",
267
272
  children: c(s.verification.objections ? "verifyObjections" : "verifyNoObjections")
268
273
  })]
269
274
  }),
270
- J && /* @__PURE__ */ V("p", {
275
+ q && /* @__PURE__ */ B("p", {
271
276
  className: "flex flex-wrap items-center gap-x-2 px-3 pt-1.5",
272
277
  children: [
273
- /* @__PURE__ */ B(oe, { className: "size-3.5 text-muted-foreground" }),
274
- /* @__PURE__ */ B(re, {
275
- provider: J.provider,
278
+ /* @__PURE__ */ z(oe, { className: "size-3.5 text-muted-foreground" }),
279
+ /* @__PURE__ */ z(re, {
280
+ provider: q.provider,
276
281
  className: "size-3.5 text-muted-foreground"
277
282
  }),
278
- /* @__PURE__ */ B("a", {
279
- href: m(J.url),
283
+ /* @__PURE__ */ z("a", {
284
+ href: m(q.url),
280
285
  target: "_blank",
281
286
  rel: "noopener noreferrer",
282
287
  className: "hover:underline",
283
- children: Y("pullRequestRef", {
284
- repository: J.repository,
285
- number: ne(J)
288
+ children: J("pullRequestRef", {
289
+ repository: q.repository,
290
+ number: ne(q)
286
291
  })
287
292
  }),
288
- /* @__PURE__ */ B("span", {
293
+ /* @__PURE__ */ z("span", {
289
294
  className: "text-xs text-muted-foreground",
290
- children: Y(`state.${J.state === "open" && J.draft ? "draft" : J.state}`)
295
+ children: J(`state.${q.state === "open" && q.draft ? "draft" : q.state}`)
291
296
  })
292
297
  ]
293
298
  }),
294
- /* @__PURE__ */ B(we, {
299
+ /* @__PURE__ */ z(Ee, {
295
300
  workspace: i,
296
301
  run: s
297
302
  }),
298
- F && /* @__PURE__ */ B(Ce, {
303
+ P && /* @__PURE__ */ z(Te, {
299
304
  run: s,
300
- busy: N,
301
- onCancel: () => L(!1),
302
- onSubmit: (e) => D.mutate({
305
+ busy: M,
306
+ onCancel: () => I(!1),
307
+ onSubmit: (e) => O.mutate({
303
308
  state: "queued",
304
309
  budget: e
305
- }, { onSuccess: () => L(!1) })
310
+ }, { onSuccess: () => I(!1) })
306
311
  }),
307
- O && /* @__PURE__ */ B("div", {
312
+ k && /* @__PURE__ */ z("div", {
308
313
  className: "mx-3 mt-2.5 rounded-md border border-border px-2.5 py-1.5 focus-within:border-primary/60",
309
- children: /* @__PURE__ */ B(w, {
314
+ children: /* @__PURE__ */ z(T, {
310
315
  value: "",
311
- onChange: j,
312
- onSubmit: () => A.trim() && M.mutate(),
316
+ onChange: fe,
317
+ onSubmit: () => de.trim() && j.mutate(),
313
318
  placeholder: c("changesPlaceholder"),
314
319
  label: c("changesLabel"),
315
320
  className: "min-h-12",
316
321
  autofocus: !0
317
322
  })
318
323
  }),
319
- /* @__PURE__ */ V("footer", {
324
+ /* @__PURE__ */ B("footer", {
320
325
  className: "flex flex-wrap items-center gap-2 px-3 pt-2.5 pb-2.5",
321
326
  children: [
322
- W && !O && /* @__PURE__ */ V(z, { children: [/* @__PURE__ */ B(E, {
327
+ U && !k && /* @__PURE__ */ B(R, { children: [/* @__PURE__ */ z(D, {
323
328
  variant: "primary",
324
329
  size: "sm",
325
330
  type: "button",
326
- disabled: N,
327
- onClick: () => D.mutate({ state: "closed" }),
331
+ disabled: M,
332
+ onClick: () => O.mutate({ state: "closed" }),
328
333
  children: c("accept")
329
- }), /* @__PURE__ */ B(E, {
334
+ }), /* @__PURE__ */ z(D, {
330
335
  size: "sm",
331
336
  type: "button",
332
- disabled: N,
333
- onClick: () => k(!0),
337
+ disabled: M,
338
+ onClick: () => A(!0),
334
339
  children: c("requestChanges")
335
340
  })] }),
336
- O && /* @__PURE__ */ V(z, { children: [/* @__PURE__ */ B(E, {
341
+ k && /* @__PURE__ */ B(R, { children: [/* @__PURE__ */ z(D, {
337
342
  variant: "primary",
338
343
  size: "sm",
339
344
  type: "button",
340
- disabled: N || !A.trim(),
341
- onClick: () => M.mutate(),
345
+ disabled: M || !de.trim(),
346
+ onClick: () => j.mutate(),
342
347
  children: c("sendBack")
343
- }), /* @__PURE__ */ B(E, {
348
+ }), /* @__PURE__ */ z(D, {
344
349
  size: "sm",
345
350
  type: "button",
346
- disabled: N,
347
- onClick: () => k(!1),
351
+ disabled: M,
352
+ onClick: () => A(!1),
348
353
  children: d("cancel")
349
354
  })] }),
350
- (s.state === "stopped" || s.state === "blocked_external") && !F && /* @__PURE__ */ B(E, {
355
+ (s.state === "stopped" || s.state === "blocked_external") && !P && /* @__PURE__ */ z(D, {
351
356
  size: "sm",
352
- disabled: N,
353
- onClick: () => U(),
357
+ disabled: M,
358
+ onClick: () => H(),
354
359
  children: c("resume")
355
360
  }),
356
- $ && /* @__PURE__ */ B(E, {
361
+ $ && /* @__PURE__ */ z(D, {
357
362
  size: "sm",
358
363
  type: "button",
359
- disabled: N,
360
- onClick: () => D.mutate({ state: "stopped" }),
364
+ disabled: M,
365
+ onClick: () => O.mutate({ state: "stopped" }),
361
366
  children: c("stop")
362
367
  }),
363
- s.state !== "queued" && /* @__PURE__ */ B(E, {
368
+ s.state !== "queued" && /* @__PURE__ */ z(D, {
364
369
  size: "sm",
365
370
  type: "button",
366
- "aria-expanded": T,
371
+ "aria-expanded": E,
367
372
  onClick: () => ie((e) => !e),
368
- children: c(T ? "activity.hide" : "activity.show")
373
+ children: c(E ? "activity.hide" : "activity.show")
369
374
  }),
370
- /* @__PURE__ */ B("span", {
375
+ /* @__PURE__ */ z("span", {
371
376
  className: "ml-auto text-xs text-muted-foreground tabular-nums",
372
377
  children: c("usage", {
373
378
  turns: s.turns,
@@ -379,43 +384,43 @@ function be({ workspace: i, identifier: a, run: s }) {
379
384
  when: g.relative(s.updatedAt)
380
385
  })
381
386
  }),
382
- (D.isError || M.isError) && /* @__PURE__ */ B(ue, {
387
+ (O.isError || j.isError) && /* @__PURE__ */ z(ue, {
383
388
  className: "w-full",
384
- children: f(D.error ?? M.error)
389
+ children: f(O.error ?? j.error)
385
390
  })
386
391
  ]
387
392
  }),
388
- T && s.state !== "queued" && /* @__PURE__ */ B(xe, {
393
+ E && s.state !== "queued" && /* @__PURE__ */ z(Ce, {
389
394
  workspace: i,
390
395
  run: s
391
396
  })
392
397
  ]
393
398
  });
394
399
  }
395
- function xe({ workspace: e, run: t }) {
396
- let n = R("agentWork.activity"), r = S(), i = t.state === "working", { data: a, isPending: o, isError: c } = H(s(e, t.id, i)), l = F(null), u = F(!0), d = a?.length ?? 0;
397
- return P(() => {
400
+ function Ce({ workspace: e, run: t }) {
401
+ let n = L("agentWork.activity"), r = C(), i = t.state === "working", { data: a, isPending: o, isError: c } = V(s(e, t.id, i)), l = P(null), u = P(!0), d = a?.length ?? 0;
402
+ return N(() => {
398
403
  let e = l.current;
399
404
  e && u.current && d > 0 && (e.scrollTop = e.scrollHeight);
400
- }, [d]), /* @__PURE__ */ V("div", {
405
+ }, [d]), /* @__PURE__ */ B("div", {
401
406
  className: "border-t border-border",
402
- children: [/* @__PURE__ */ V("p", {
407
+ children: [/* @__PURE__ */ B("p", {
403
408
  className: "flex items-center gap-2 px-3 pt-2 text-xs text-muted-foreground",
404
- children: [i && /* @__PURE__ */ V("span", {
409
+ children: [i && /* @__PURE__ */ B("span", {
405
410
  className: "inline-flex items-center gap-1.5 font-medium text-agent",
406
- children: [/* @__PURE__ */ V("span", {
411
+ children: [/* @__PURE__ */ B("span", {
407
412
  className: "relative flex size-1.5",
408
413
  "aria-hidden": "true",
409
- children: [/* @__PURE__ */ B("span", { className: "absolute inline-flex size-full animate-ping rounded-full bg-agent opacity-60 motion-reduce:hidden" }), /* @__PURE__ */ B("span", { className: "relative inline-flex size-1.5 rounded-full bg-agent" })]
414
+ children: [/* @__PURE__ */ z("span", { className: "absolute inline-flex size-full animate-ping rounded-full bg-agent opacity-60 motion-reduce:hidden" }), /* @__PURE__ */ z("span", { className: "relative inline-flex size-1.5 rounded-full bg-agent" })]
410
415
  }), n("live")]
411
416
  }), n("count", { count: d })]
412
- }), c ? /* @__PURE__ */ B(ue, {
417
+ }), c ? /* @__PURE__ */ z(ue, {
413
418
  className: "px-3 py-2",
414
419
  children: n("failedToLoad")
415
- }) : !o && d === 0 ? /* @__PURE__ */ B("p", {
420
+ }) : !o && d === 0 ? /* @__PURE__ */ z("p", {
416
421
  className: "px-3 py-2 text-xs text-muted-foreground",
417
422
  children: n(i ? "emptyLive" : "empty")
418
- }) : /* @__PURE__ */ B("ol", {
423
+ }) : /* @__PURE__ */ z("ol", {
419
424
  ref: l,
420
425
  "aria-live": i ? "polite" : "off",
421
426
  "aria-label": n("label"),
@@ -424,65 +429,65 @@ function xe({ workspace: e, run: t }) {
424
429
  u.current = t.scrollHeight - t.scrollTop - t.clientHeight < 24;
425
430
  },
426
431
  className: "mx-3 mt-1.5 mb-2.5 max-h-96 space-y-1 overflow-y-auto rounded-md border border-border bg-muted/40 p-2 font-mono text-[11.5px] leading-relaxed",
427
- children: a?.map((e) => /* @__PURE__ */ B(W, {
432
+ children: a?.map((e) => /* @__PURE__ */ z(U, {
428
433
  entry: e,
429
434
  at: r.clock(e.at)
430
435
  }, e.seq))
431
436
  })]
432
437
  });
433
438
  }
434
- function W({ entry: e, at: t }) {
435
- let n = R("agentWork.activity"), r = /* @__PURE__ */ B("span", {
439
+ function U({ entry: e, at: t }) {
440
+ let n = L("agentWork.activity"), r = /* @__PURE__ */ z("span", {
436
441
  className: "shrink-0 text-muted-foreground/70 tabular-nums",
437
442
  children: t
438
443
  });
439
444
  if (e.kind === "output" || e.kind === "failed") {
440
445
  let t = e.kind === "failed", i = e.text.split("\n", 1)[0] ?? "";
441
- return e.tool ? /* @__PURE__ */ V("li", {
446
+ return e.tool ? /* @__PURE__ */ B("li", {
442
447
  className: "flex gap-2",
443
- children: [r, /* @__PURE__ */ B(O, {
448
+ children: [r, /* @__PURE__ */ z(k, {
444
449
  className: "min-w-0 flex-1",
445
450
  summaryClassName: t ? "text-danger" : "text-muted-foreground",
446
- summary: /* @__PURE__ */ V("span", {
451
+ summary: /* @__PURE__ */ B("span", {
447
452
  className: "truncate",
448
- children: [n(t ? "toolFailed" : "toolOutput", { tool: e.tool }), i && /* @__PURE__ */ B("span", {
453
+ children: [n(t ? "toolFailed" : "toolOutput", { tool: e.tool }), i && /* @__PURE__ */ z("span", {
449
454
  className: "ml-1.5 opacity-80",
450
455
  children: i
451
456
  })]
452
457
  }),
453
- children: /* @__PURE__ */ B("pre", {
458
+ children: /* @__PURE__ */ z("pre", {
454
459
  className: "mt-1 max-h-60 overflow-auto rounded bg-card p-1.5 whitespace-pre-wrap break-words",
455
460
  children: e.text
456
461
  })
457
462
  })]
458
- }) : /* @__PURE__ */ V("li", {
463
+ }) : /* @__PURE__ */ B("li", {
459
464
  className: "flex gap-2",
460
- children: [r, /* @__PURE__ */ B("span", {
461
- className: G("min-w-0 whitespace-pre-wrap break-words", t && "text-danger"),
465
+ children: [r, /* @__PURE__ */ z("span", {
466
+ className: W("min-w-0 whitespace-pre-wrap break-words", t && "text-danger"),
462
467
  children: e.text
463
468
  })]
464
469
  });
465
470
  }
466
- return /* @__PURE__ */ V("li", {
471
+ return /* @__PURE__ */ B("li", {
467
472
  className: "flex gap-2",
468
- children: [r, /* @__PURE__ */ B("span", {
469
- className: G("min-w-0 whitespace-pre-wrap break-words", e.kind === "thinking" && "text-muted-foreground italic", e.kind === "status" && "text-muted-foreground", e.kind === "tool" && "text-foreground"),
470
- children: e.kind === "tool" ? /* @__PURE__ */ V(z, { children: [/* @__PURE__ */ B("span", {
473
+ children: [r, /* @__PURE__ */ z("span", {
474
+ className: W("min-w-0 whitespace-pre-wrap break-words", e.kind === "thinking" && "text-muted-foreground italic", e.kind === "status" && "text-muted-foreground", e.kind === "tool" && "text-foreground"),
475
+ children: e.kind === "tool" ? /* @__PURE__ */ B(R, { children: [/* @__PURE__ */ z("span", {
471
476
  className: "font-semibold text-agent",
472
477
  children: e.tool
473
- }), e.text && /* @__PURE__ */ B("span", {
478
+ }), e.text && /* @__PURE__ */ z("span", {
474
479
  className: "ml-1.5 text-muted-foreground",
475
480
  children: e.text
476
481
  })] }) : e.text
477
482
  })]
478
483
  });
479
484
  }
480
- function Se(e) {
485
+ function we(e) {
481
486
  return e.turns >= e.budget.maxTurns ? "turns" : e.seconds >= e.budget.maxMinutes * 60 ? "minutes" : e.costMicros >= e.budget.maxCostMicros ? "cost" : null;
482
487
  }
483
- function Ce({ run: e, busy: t, onSubmit: n, onCancel: r }) {
484
- let i = R("agentWork"), a = R("common"), o = Math.ceil(e.seconds / 60), [s, c] = I(Math.max(e.budget.maxTurns * 2, e.turns + 1)), [l, u] = I(Math.max(e.budget.maxMinutes * 2, o + 1)), [d, f] = I(Math.max(e.budget.maxCostMicros * 2, e.costMicros + 1e6) / 1e6);
485
- return /* @__PURE__ */ V("form", {
488
+ function Te({ run: e, busy: t, onSubmit: n, onCancel: r }) {
489
+ let i = L("agentWork"), a = L("common"), o = Math.ceil(e.seconds / 60), [s, c] = F(Math.max(e.budget.maxTurns * 2, e.turns + 1)), [l, u] = F(Math.max(e.budget.maxMinutes * 2, o + 1)), [d, f] = F(Math.max(e.budget.maxCostMicros * 2, e.costMicros + 1e6) / 1e6);
490
+ return /* @__PURE__ */ B("form", {
486
491
  className: "mx-3 mt-2.5 space-y-2 rounded-md border border-border px-2.5 py-2",
487
492
  onSubmit: (e) => {
488
493
  e.preventDefault(), n({
@@ -492,16 +497,16 @@ function Ce({ run: e, busy: t, onSubmit: n, onCancel: r }) {
492
497
  });
493
498
  },
494
499
  children: [
495
- /* @__PURE__ */ B("p", {
500
+ /* @__PURE__ */ z("p", {
496
501
  className: "text-sm font-medium",
497
502
  children: i("raiseBudget")
498
503
  }),
499
- /* @__PURE__ */ V("div", {
504
+ /* @__PURE__ */ B("div", {
500
505
  className: "flex flex-wrap gap-3 text-xs text-muted-foreground",
501
506
  children: [
502
- /* @__PURE__ */ V("label", {
507
+ /* @__PURE__ */ B("label", {
503
508
  className: "flex flex-col gap-1",
504
- children: [i("maxTurns"), /* @__PURE__ */ B(k, {
509
+ children: [i("maxTurns"), /* @__PURE__ */ z(A, {
505
510
  required: !0,
506
511
  min: e.turns + 1,
507
512
  value: s,
@@ -510,9 +515,9 @@ function Ce({ run: e, busy: t, onSubmit: n, onCancel: r }) {
510
515
  className: "w-28"
511
516
  })]
512
517
  }),
513
- /* @__PURE__ */ V("label", {
518
+ /* @__PURE__ */ B("label", {
514
519
  className: "flex flex-col gap-1",
515
- children: [i("maxMinutes"), /* @__PURE__ */ B(k, {
520
+ children: [i("maxMinutes"), /* @__PURE__ */ z(A, {
516
521
  required: !0,
517
522
  min: o + 1,
518
523
  value: l,
@@ -521,9 +526,9 @@ function Ce({ run: e, busy: t, onSubmit: n, onCancel: r }) {
521
526
  className: "w-28"
522
527
  })]
523
528
  }),
524
- /* @__PURE__ */ V("label", {
529
+ /* @__PURE__ */ B("label", {
525
530
  className: "flex flex-col gap-1",
526
- children: [i("maxCost"), /* @__PURE__ */ B(k, {
531
+ children: [i("maxCost"), /* @__PURE__ */ z(A, {
527
532
  required: !0,
528
533
  step: .01,
529
534
  min: (e.costMicros + 1e4) / 1e6,
@@ -539,15 +544,15 @@ function Ce({ run: e, busy: t, onSubmit: n, onCancel: r }) {
539
544
  })
540
545
  ]
541
546
  }),
542
- /* @__PURE__ */ V("div", {
547
+ /* @__PURE__ */ B("div", {
543
548
  className: "flex gap-2",
544
- children: [/* @__PURE__ */ B(E, {
549
+ children: [/* @__PURE__ */ z(D, {
545
550
  variant: "primary",
546
551
  size: "sm",
547
552
  type: "submit",
548
553
  disabled: t,
549
554
  children: i("resume")
550
- }), /* @__PURE__ */ B(E, {
555
+ }), /* @__PURE__ */ z(D, {
551
556
  size: "sm",
552
557
  disabled: t,
553
558
  onClick: r,
@@ -557,62 +562,62 @@ function Ce({ run: e, busy: t, onSubmit: n, onCancel: r }) {
557
562
  ]
558
563
  });
559
564
  }
560
- var G = (...e) => e.filter(Boolean).join(" ");
561
- function we({ workspace: e, run: t }) {
562
- let n = g(e), r = R("agentWork"), [i, a] = I(!1), { data: o } = H({
565
+ var W = (...e) => e.filter(Boolean).join(" ");
566
+ function Ee({ workspace: e, run: t }) {
567
+ let n = g(e), r = L("agentWork"), [i, a] = F(!1), { data: o } = V({
563
568
  ...c(e, t.id),
564
569
  enabled: i
565
570
  });
566
- return /* @__PURE__ */ B(O, {
571
+ return /* @__PURE__ */ z(k, {
567
572
  className: "px-3 pt-1.5 text-xs",
568
573
  summaryClassName: "text-muted-foreground hover:text-foreground",
569
574
  summary: r("reads"),
570
575
  open: i,
571
576
  onOpenChange: a,
572
- children: o && (o.docs.length + o.entries.length === 0 ? /* @__PURE__ */ B("p", {
577
+ children: o && (o.docs.length + o.entries.length === 0 ? /* @__PURE__ */ z("p", {
573
578
  className: "mt-1 text-muted-foreground",
574
579
  children: r("readNothing")
575
- }) : /* @__PURE__ */ V("ul", {
580
+ }) : /* @__PURE__ */ B("ul", {
576
581
  className: "mt-1 flex flex-wrap gap-x-3 gap-y-1",
577
- children: [o.docs.map((t) => /* @__PURE__ */ B("li", { children: /* @__PURE__ */ V(x, {
582
+ children: [o.docs.map((t) => /* @__PURE__ */ z("li", { children: /* @__PURE__ */ B(S, {
578
583
  to: "/$workspace/docs/$doc",
579
584
  params: {
580
585
  workspace: e,
581
586
  doc: p(t)
582
587
  },
583
588
  className: "inline-flex items-center gap-1 hover:underline",
584
- children: [/* @__PURE__ */ B(ie, { className: "size-3.5 text-muted-foreground" }), t.title]
585
- }) }, t.id)), o.entries.map((t) => /* @__PURE__ */ B("li", { children: /* @__PURE__ */ V(x, {
589
+ children: [/* @__PURE__ */ z(ie, { className: "size-3.5 text-muted-foreground" }), t.title]
590
+ }) }, t.id)), o.entries.map((t) => /* @__PURE__ */ z("li", { children: /* @__PURE__ */ B(S, {
586
591
  to: "/$workspace/knowledge/$term",
587
592
  params: {
588
593
  workspace: e,
589
594
  term: n(t.id)
590
595
  },
591
596
  className: "inline-flex items-center gap-1 hover:underline",
592
- children: [/* @__PURE__ */ B(ae, { className: "size-3.5 text-muted-foreground" }), t.name]
597
+ children: [/* @__PURE__ */ z(ae, { className: "size-3.5 text-muted-foreground" }), t.name]
593
598
  }) }, t.id))]
594
599
  }))
595
600
  });
596
601
  }
597
- function K() {
598
- let e = R("agentWork");
602
+ function G() {
603
+ let e = L("agentWork");
599
604
  return (t, n) => t.merge ? e(n.id === "merge" ? "mergeApprove" : "mergeWait") : t.release ? e(n.id === "release" ? "releaseApprove" : "releaseWait") : t.breakdown?.length ? e(n.id === "approve" ? "breakdownApprove" : "breakdownRevise") : n.label;
600
605
  }
601
- function Te({ decision: e, className: t }) {
602
- let n = R("agentWork"), r = e.merge, i = e.release;
603
- return i ? /* @__PURE__ */ V("p", {
604
- className: G("text-sm", t),
606
+ function De({ decision: e, className: t }) {
607
+ let n = L("agentWork"), r = e.merge, i = e.release;
608
+ return i ? /* @__PURE__ */ B("p", {
609
+ className: W("text-sm", t),
605
610
  children: [n.rich("releasePrompt", {
606
611
  repository: i.repository,
607
612
  sha: i.sha.slice(0, 7),
608
613
  targets: i.targets.join(", "),
609
- code: (e) => /* @__PURE__ */ B("code", {
614
+ code: (e) => /* @__PURE__ */ z("code", {
610
615
  className: "rounded bg-muted px-1 font-mono text-xs",
611
616
  children: e
612
617
  })
613
- }), i.deploymentId && /* @__PURE__ */ B("span", {
618
+ }), i.deploymentId && /* @__PURE__ */ z("span", {
614
619
  className: "mt-1 block text-xs text-muted-foreground",
615
- children: i.deploymentUrl ? /* @__PURE__ */ B("a", {
620
+ children: i.deploymentUrl ? /* @__PURE__ */ z("a", {
616
621
  href: m(i.deploymentUrl),
617
622
  target: "_blank",
618
623
  rel: "noopener noreferrer",
@@ -620,11 +625,11 @@ function Te({ decision: e, className: t }) {
620
625
  children: n("deployment", { id: i.deploymentId })
621
626
  }) : n("deployment", { id: i.deploymentId })
622
627
  })]
623
- }) : r ? /* @__PURE__ */ B("p", {
624
- className: G("text-sm", t),
628
+ }) : r ? /* @__PURE__ */ z("p", {
629
+ className: W("text-sm", t),
625
630
  children: n.rich("mergePrompt", {
626
631
  sha: r.sha.slice(0, 7),
627
- pr: () => /* @__PURE__ */ V("a", {
632
+ pr: () => /* @__PURE__ */ B("a", {
628
633
  href: m(r.url),
629
634
  target: "_blank",
630
635
  rel: "noopener noreferrer",
@@ -635,27 +640,27 @@ function Te({ decision: e, className: t }) {
635
640
  r.number
636
641
  ]
637
642
  }),
638
- code: (e) => /* @__PURE__ */ B("code", {
643
+ code: (e) => /* @__PURE__ */ z("code", {
639
644
  className: "rounded bg-muted px-1 font-mono text-xs",
640
645
  children: e
641
646
  })
642
647
  })
643
- }) : /* @__PURE__ */ B(w, {
648
+ }) : /* @__PURE__ */ z(T, {
644
649
  value: e.prompt,
645
650
  editable: !1,
646
651
  ...t && { className: t }
647
652
  });
648
653
  }
649
- function Ee({ workspace: e, decision: t }) {
650
- let n = R("agentWork");
651
- return t.subIssues.length > 0 ? /* @__PURE__ */ V("div", {
654
+ function Oe({ workspace: e, decision: t }) {
655
+ let n = L("agentWork");
656
+ return t.subIssues.length > 0 ? /* @__PURE__ */ B("div", {
652
657
  className: "mt-2 text-sm",
653
- children: [/* @__PURE__ */ B("p", {
658
+ children: [/* @__PURE__ */ z("p", {
654
659
  className: "text-xs text-muted-foreground",
655
660
  children: n("subIssuesCreated")
656
- }), /* @__PURE__ */ B("ul", {
661
+ }), /* @__PURE__ */ z("ul", {
657
662
  className: "mt-1 space-y-0.5",
658
- children: t.subIssues.map((t) => /* @__PURE__ */ B("li", { children: /* @__PURE__ */ V(x, {
663
+ children: t.subIssues.map((t) => /* @__PURE__ */ z("li", { children: /* @__PURE__ */ B(S, {
659
664
  to: "/$workspace/issues/$identifier",
660
665
  params: {
661
666
  workspace: e,
@@ -663,7 +668,7 @@ function Ee({ workspace: e, decision: t }) {
663
668
  },
664
669
  className: "hover:underline",
665
670
  children: [
666
- /* @__PURE__ */ B("span", {
671
+ /* @__PURE__ */ z("span", {
667
672
  className: "text-muted-foreground",
668
673
  children: t.identifier
669
674
  }),
@@ -672,19 +677,19 @@ function Ee({ workspace: e, decision: t }) {
672
677
  ]
673
678
  }) }, t.id))
674
679
  })]
675
- }) : t.breakdown?.length ? /* @__PURE__ */ B("ol", {
680
+ }) : t.breakdown?.length ? /* @__PURE__ */ z("ol", {
676
681
  className: "mt-2 divide-y divide-border rounded-md border border-border text-sm",
677
- children: t.breakdown.map((e, t) => /* @__PURE__ */ V("li", {
682
+ children: t.breakdown.map((e, t) => /* @__PURE__ */ B("li", {
678
683
  className: "flex gap-2 px-3 py-2",
679
- children: [/* @__PURE__ */ B("span", {
684
+ children: [/* @__PURE__ */ z("span", {
680
685
  className: "w-4 shrink-0 text-right text-xs text-muted-foreground tabular-nums",
681
686
  children: t + 1
682
- }), /* @__PURE__ */ V("span", {
687
+ }), /* @__PURE__ */ B("span", {
683
688
  className: "min-w-0",
684
- children: [/* @__PURE__ */ B("span", {
689
+ children: [/* @__PURE__ */ z("span", {
685
690
  className: "font-medium",
686
691
  children: e.title
687
- }), e.body && /* @__PURE__ */ B("span", {
692
+ }), e.body && /* @__PURE__ */ z("span", {
688
693
  className: "mt-0.5 block text-xs text-muted-foreground",
689
694
  children: e.body
690
695
  })]
@@ -692,22 +697,22 @@ function Ee({ workspace: e, decision: t }) {
692
697
  }, t))
693
698
  }) : null;
694
699
  }
695
- function q({ workspace: e, decision: t, onAnswer: n, busy: r }) {
696
- let a = R("agentPage"), o = K(), { data: s = [] } = H(i(e, t.identifier)), [c, l] = I(null), u = N((e) => {
700
+ function K({ workspace: e, decision: t, onAnswer: n, busy: r }) {
701
+ let a = L("agentPage"), o = G(), { data: s = [] } = V(i(e, t.identifier)), [c, l] = F(null), u = M((e) => {
697
702
  t.options.some((t) => t.id === e) && l(e);
698
703
  }, [t.options]), d = s.find((e) => e.id === t.pageId), f = t.options.find((e) => e.id === c);
699
- return /* @__PURE__ */ V("div", {
704
+ return /* @__PURE__ */ B("div", {
700
705
  className: "mt-3 space-y-2",
701
- children: [/* @__PURE__ */ B(C, {
706
+ children: [/* @__PURE__ */ z(w, {
702
707
  attachmentId: t.pageId ?? "",
703
708
  name: d?.name ?? "",
704
709
  agent: t.agentName,
705
710
  onChoose: u
706
- }), f && /* @__PURE__ */ V("div", {
711
+ }), f && /* @__PURE__ */ B("div", {
707
712
  className: "flex flex-wrap items-center gap-2 rounded-md border border-agent/50 bg-agent-soft/40 px-3 py-2 text-sm",
708
713
  children: [
709
- /* @__PURE__ */ B("span", { children: a("chose", { option: o(t, f) }) }),
710
- /* @__PURE__ */ B(E, {
714
+ /* @__PURE__ */ z("span", { children: a("chose", { option: o(t, f) }) }),
715
+ /* @__PURE__ */ z(D, {
711
716
  variant: "primary",
712
717
  size: "sm",
713
718
  disabled: r,
@@ -715,7 +720,7 @@ function q({ workspace: e, decision: t, onAnswer: n, busy: r }) {
715
720
  className: "ml-auto",
716
721
  children: a("answerWith")
717
722
  }),
718
- /* @__PURE__ */ B(E, {
723
+ /* @__PURE__ */ z(D, {
719
724
  size: "sm",
720
725
  onClick: () => l(null),
721
726
  children: a("dismiss")
@@ -724,8 +729,8 @@ function q({ workspace: e, decision: t, onAnswer: n, busy: r }) {
724
729
  })]
725
730
  });
726
731
  }
727
- function De(e) {
728
- let t = R("agentWork"), n = K(), r = y(), { workspace: i } = M({ strict: !1 });
732
+ function ke(e) {
733
+ let t = L("agentWork"), n = G(), r = y(), { workspace: i } = j({ strict: !1 });
729
734
  if (i !== e.workspace) return [];
730
735
  let a = e.options.find((t) => t.id === e.answer?.optionId), o = [a && n(e, a), e.answer?.text].filter(Boolean).join(". "), s = e.prompt.split("\n").map((e) => `> ${e}`).join("\n");
731
736
  return [{
@@ -738,23 +743,23 @@ function De(e) {
738
743
  })
739
744
  }];
740
745
  }
741
- function J(e) {
746
+ function q(e) {
742
747
  return e.merge || e.release || !e.options.some((e) => e.id === "allow") ? null : d(e.prompt);
743
748
  }
744
- var Y = (e) => ({
749
+ var J = (e) => ({
745
750
  allow: 0,
746
751
  "allow-run": 1,
747
752
  deny: 2
748
753
  })[e] ?? 1;
749
- function Oe() {
750
- let e = R("agentWork");
751
- return /* @__PURE__ */ B("span", {
754
+ function Y() {
755
+ let e = L("agentWork");
756
+ return /* @__PURE__ */ z("span", {
752
757
  className: "rounded bg-agent-soft px-1.5 text-[10px] font-medium text-agent",
753
758
  children: e("suggested")
754
759
  });
755
760
  }
756
761
  function X({ workspace: n, decision: r, showIssue: i = !1 }) {
757
- let a = pe(), o = R("agentWork"), s = K(), c = v(), l = he(), u = R("common"), [d, p] = I(""), [m, h] = I(0), [g, _] = I(!1), y = J(r), b = !y && r.options.some((e) => e.description), ee = y ? [...r.options].sort((e, t) => Y(e.id) - Y(t.id)) : r.options, x = me({
762
+ let a = he(), o = L("agentWork"), s = G(), c = v(), l = _e(), u = L("common"), [d, p] = F(""), [m, h] = F(0), [g, _] = F(!1), y = q(r), b = !y && r.options.some((e) => e.description), ee = y ? [...r.options].sort((e, t) => J(e.id) - J(t.id)) : r.options, x = ge({
758
763
  mutationFn: async (i) => t(await e.POST("/api/v1/workspaces/{workspace}/decisions/{decisionId}/answer", {
759
764
  params: { path: {
760
765
  workspace: n,
@@ -777,14 +782,14 @@ function X({ workspace: n, decision: r, showIssue: i = !1 }) {
777
782
  r.identifier.toUpperCase()
778
783
  ] });
779
784
  }
780
- }), S = fe(), C = te(), ne = De(r), T = () => [
785
+ }), S = me(), C = te(), w = ke(r), ne = () => [
781
786
  ...r.options.length > 0 ? [{
782
787
  label: o("answer"),
783
788
  items: r.options.map((e) => ({
784
789
  label: e.id === r.recommendation ? o("suggestedOption", { option: s(r, e) }) : s(r, e),
785
790
  onClick: () => x.mutate(e.id)
786
791
  }))
787
- }, de] : [],
792
+ }, pe] : [],
788
793
  {
789
794
  label: o("openIssue"),
790
795
  onClick: () => C({
@@ -795,129 +800,129 @@ function X({ workspace: n, decision: r, showIssue: i = !1 }) {
795
800
  }
796
801
  })
797
802
  },
798
- ...ne,
803
+ ...w,
799
804
  ...c(f(n, r.identifier))
800
805
  ];
801
- return /* @__PURE__ */ V(le, {
806
+ return /* @__PURE__ */ B(le, {
802
807
  size: "fill",
803
808
  padding: "none",
804
- tone: _e,
809
+ tone: ye,
805
810
  interactive: !1,
806
- render: /* @__PURE__ */ B("article", {
811
+ render: /* @__PURE__ */ z("article", {
807
812
  onContextMenu: (e) => {
808
- e.target.closest(".ProseMirror[contenteditable=\"true\"]") || S(e, T());
813
+ e.target.closest(".ProseMirror[contenteditable=\"true\"]") || S(e, ne());
809
814
  },
810
815
  "aria-label": o("asking", { agent: r.agentName })
811
816
  }),
812
- children: [/* @__PURE__ */ V("header", {
817
+ children: [/* @__PURE__ */ B("header", {
813
818
  className: "flex items-center gap-2 border-b border-border px-3 py-2 text-xs",
814
819
  children: [
815
- /* @__PURE__ */ B(ce, {
820
+ /* @__PURE__ */ z(ce, {
816
821
  kind: "agent",
817
822
  name: r.agentName,
818
823
  size: "xs",
819
824
  decorative: !0
820
825
  }),
821
- /* @__PURE__ */ B("span", {
826
+ /* @__PURE__ */ z("span", {
822
827
  className: "font-medium",
823
828
  children: r.agentName
824
829
  }),
825
- /* @__PURE__ */ B("span", {
830
+ /* @__PURE__ */ z("span", {
826
831
  className: `shrink-0 text-muted-foreground ${i ? "max-sm:hidden" : ""}`,
827
832
  children: o("needsDecision")
828
833
  }),
829
- i && /* @__PURE__ */ B("span", {
834
+ i && /* @__PURE__ */ z("span", {
830
835
  className: "min-w-0 truncate text-muted-foreground",
831
836
  children: o("onIssue", {
832
837
  identifier: r.identifier,
833
838
  title: r.issueTitle
834
839
  })
835
840
  }),
836
- /* @__PURE__ */ B(A, {
841
+ /* @__PURE__ */ z(de, {
837
842
  value: r.createdAt,
838
843
  exact: "medium",
839
844
  className: "ml-auto shrink-0 whitespace-nowrap text-muted-foreground"
840
845
  })
841
846
  ]
842
- }), /* @__PURE__ */ V("div", {
847
+ }), /* @__PURE__ */ B("div", {
843
848
  className: "px-3 py-2.5",
844
849
  children: [
845
- y ? /* @__PURE__ */ V("div", { children: [
846
- /* @__PURE__ */ B("p", {
850
+ y ? /* @__PURE__ */ B("div", { children: [
851
+ /* @__PURE__ */ z("p", {
847
852
  className: "text-sm font-medium",
848
853
  children: y.agent ? o("approveCommandFor", { agent: y.agent }) : o("approveCommand")
849
854
  }),
850
- /* @__PURE__ */ B(D, {
855
+ /* @__PURE__ */ z(O, {
851
856
  text: y.command,
852
857
  label: o("command"),
853
858
  wrap: !0,
854
859
  className: "mt-2 [&_pre]:px-3 [&_pre]:py-2 [&_pre]:pr-10 [&_pre]:text-xs [&_pre]:leading-5"
855
860
  }),
856
- y.reason && /* @__PURE__ */ B("p", {
861
+ y.reason && /* @__PURE__ */ z("p", {
857
862
  className: "mt-1.5 text-xs text-muted-foreground",
858
863
  children: y.reason
859
864
  })
860
- ] }) : /* @__PURE__ */ B("div", {
865
+ ] }) : /* @__PURE__ */ z("div", {
861
866
  className: "[&_.ProseMirror>:first-child]:mt-0",
862
- children: /* @__PURE__ */ B(Te, { decision: r })
867
+ children: /* @__PURE__ */ z(De, { decision: r })
863
868
  }),
864
- /* @__PURE__ */ B(Z, {
869
+ /* @__PURE__ */ z(Z, {
865
870
  workspace: n,
866
871
  decision: r
867
872
  }),
868
- r.pageId && /* @__PURE__ */ B(q, {
873
+ r.pageId && /* @__PURE__ */ z(K, {
869
874
  workspace: n,
870
875
  decision: r,
871
876
  onAnswer: (e) => x.mutate(e),
872
877
  busy: x.isPending
873
878
  }),
874
- /* @__PURE__ */ B(Ee, {
879
+ /* @__PURE__ */ z(Oe, {
875
880
  workspace: n,
876
881
  decision: r
877
882
  }),
878
- r.options.length > 0 && (b ? /* @__PURE__ */ B("div", {
883
+ r.options.length > 0 && (b ? /* @__PURE__ */ z("div", {
879
884
  className: "mt-3 grid gap-1.5 sm:grid-cols-2",
880
885
  children: r.options.map((e) => {
881
886
  let t = e.id === r.recommendation;
882
- return /* @__PURE__ */ V("button", {
887
+ return /* @__PURE__ */ B("button", {
883
888
  type: "button",
884
889
  disabled: x.isPending,
885
890
  onClick: () => x.mutate(e.id),
886
891
  className: `rounded-md border px-3 py-2 text-left text-sm hover:bg-muted disabled:opacity-50 ${t ? "border-agent" : "border-border"}`,
887
- children: [/* @__PURE__ */ V("span", {
892
+ children: [/* @__PURE__ */ B("span", {
888
893
  className: "flex items-center gap-2 font-medium",
889
- children: [s(r, e), t && /* @__PURE__ */ B(Oe, {})]
890
- }), e.description && /* @__PURE__ */ B("span", {
894
+ children: [s(r, e), t && /* @__PURE__ */ z(Y, {})]
895
+ }), e.description && /* @__PURE__ */ z("span", {
891
896
  className: "mt-0.5 block text-xs text-muted-foreground",
892
897
  children: e.description
893
898
  })]
894
899
  }, e.id);
895
900
  })
896
- }) : /* @__PURE__ */ V("div", {
901
+ }) : /* @__PURE__ */ B("div", {
897
902
  className: "mt-3 flex flex-wrap items-center gap-2",
898
903
  children: [ee.map((e, t) => {
899
- let n = e.id === r.recommendation, i = /* @__PURE__ */ V(E, {
904
+ let n = e.id === r.recommendation, i = /* @__PURE__ */ B(D, {
900
905
  size: "sm",
901
906
  variant: y && t === 0 ? "primary" : "secondary",
902
907
  disabled: x.isPending,
903
908
  onClick: () => x.mutate(e.id),
904
909
  className: n && !(y && t === 0) ? "border-agent" : void 0,
905
- children: [s(r, e), n && /* @__PURE__ */ B(Oe, {})]
910
+ children: [s(r, e), n && /* @__PURE__ */ z(Y, {})]
906
911
  }, e.id);
907
- return e.description ? /* @__PURE__ */ B(j, {
912
+ return e.description ? /* @__PURE__ */ z(fe, {
908
913
  content: e.description,
909
914
  children: i
910
915
  }, e.id) : i;
911
- }), r.allowText && !g && /* @__PURE__ */ B("button", {
916
+ }), r.allowText && !g && /* @__PURE__ */ z("button", {
912
917
  type: "button",
913
918
  onClick: () => _(!0),
914
919
  className: "ml-1 text-xs text-muted-foreground hover:text-foreground",
915
920
  children: o("answerOwnWordsShort")
916
921
  })]
917
922
  })),
918
- r.allowText && (g || r.options.length === 0 || b) && /* @__PURE__ */ V("div", {
923
+ r.allowText && (g || r.options.length === 0 || b) && /* @__PURE__ */ B("div", {
919
924
  className: "mt-3 rounded-md border border-border px-2.5 py-1.5 focus-within:border-primary/60",
920
- children: [/* @__PURE__ */ B(w, {
925
+ children: [/* @__PURE__ */ z(T, {
921
926
  value: "",
922
927
  onChange: p,
923
928
  onSubmit: () => d.trim() && x.mutate(void 0),
@@ -925,14 +930,14 @@ function X({ workspace: n, decision: r, showIssue: i = !1 }) {
925
930
  label: o("answer"),
926
931
  className: "min-h-8",
927
932
  autofocus: g
928
- }, m), /* @__PURE__ */ V("div", {
933
+ }, m), /* @__PURE__ */ B("div", {
929
934
  className: "flex justify-end gap-2",
930
- children: [g && !b && /* @__PURE__ */ B(E, {
935
+ children: [g && !b && /* @__PURE__ */ z(D, {
931
936
  size: "sm",
932
937
  variant: "ghost",
933
938
  onClick: () => _(!1),
934
939
  children: u("cancel")
935
- }), /* @__PURE__ */ B(E, {
940
+ }), /* @__PURE__ */ z(D, {
936
941
  variant: "primary",
937
942
  size: "sm",
938
943
  disabled: !d.trim(),
@@ -942,7 +947,7 @@ function X({ workspace: n, decision: r, showIssue: i = !1 }) {
942
947
  })]
943
948
  })]
944
949
  }),
945
- x.isError && /* @__PURE__ */ B(ue, {
950
+ x.isError && /* @__PURE__ */ z(ue, {
946
951
  className: "mt-2",
947
952
  children: a(x.error)
948
953
  })
@@ -951,29 +956,29 @@ function X({ workspace: n, decision: r, showIssue: i = !1 }) {
951
956
  });
952
957
  }
953
958
  function Z({ workspace: e, decision: t }) {
954
- let n = R("agentWork"), { area: r, doc: i, section: a, cites: o, checked: s, context: c, unknownTerms: l } = t;
955
- return /* @__PURE__ */ V(z, { children: [
956
- c && /* @__PURE__ */ B("p", {
959
+ let n = L("agentWork"), { area: r, doc: i, section: a, cites: o, checked: s, context: c, unknownTerms: l } = t;
960
+ return /* @__PURE__ */ B(R, { children: [
961
+ c && /* @__PURE__ */ z("p", {
957
962
  className: "mt-1.5 text-sm text-muted-foreground",
958
963
  children: c
959
964
  }),
960
- l.length > 0 && /* @__PURE__ */ B("p", {
965
+ l.length > 0 && /* @__PURE__ */ z("p", {
961
966
  className: "mt-2 text-xs text-warning",
962
967
  children: n("unknownTerms", { names: l.join(", ") })
963
968
  }),
964
- (r || i) && /* @__PURE__ */ V("p", {
969
+ (r || i) && /* @__PURE__ */ B("p", {
965
970
  className: "mt-2 flex flex-wrap items-center gap-x-3 gap-y-1 text-xs text-muted-foreground",
966
- children: [r && /* @__PURE__ */ V("span", {
971
+ children: [r && /* @__PURE__ */ B("span", {
967
972
  className: "flex items-center gap-1",
968
- children: [/* @__PURE__ */ B(T, { className: "size-3.5" }), r.title]
969
- }), i && /* @__PURE__ */ V(x, {
973
+ children: [/* @__PURE__ */ z(E, { className: "size-3.5" }), r.title]
974
+ }), i && /* @__PURE__ */ B(S, {
970
975
  to: "/$workspace/docs/$doc",
971
976
  params: {
972
977
  workspace: e,
973
978
  doc: p(i)
974
979
  },
975
980
  className: "flex min-w-0 items-center gap-1 hover:text-foreground",
976
- children: [/* @__PURE__ */ B(ie, { className: "size-3.5 shrink-0" }), /* @__PURE__ */ B("span", {
981
+ children: [/* @__PURE__ */ z(ie, { className: "size-3.5 shrink-0" }), /* @__PURE__ */ z("span", {
977
982
  className: "truncate",
978
983
  children: a ? n("docSection", {
979
984
  doc: i.title,
@@ -982,16 +987,16 @@ function Z({ workspace: e, decision: t }) {
982
987
  })]
983
988
  })]
984
989
  }),
985
- o.length > 0 && /* @__PURE__ */ V("div", {
990
+ o.length > 0 && /* @__PURE__ */ B("div", {
986
991
  className: "mt-2 text-xs",
987
- children: [/* @__PURE__ */ B("p", {
992
+ children: [/* @__PURE__ */ z("p", {
988
993
  className: "text-muted-foreground",
989
994
  children: n("buildsOn")
990
- }), /* @__PURE__ */ B("ul", {
995
+ }), /* @__PURE__ */ z("ul", {
991
996
  className: "mt-1 space-y-0.5",
992
- children: o.map((t) => /* @__PURE__ */ V("li", {
997
+ children: o.map((t) => /* @__PURE__ */ B("li", {
993
998
  className: "flex min-w-0 gap-1.5",
994
- children: [/* @__PURE__ */ B(x, {
999
+ children: [/* @__PURE__ */ z(S, {
995
1000
  to: "/$workspace/issues/$identifier",
996
1001
  params: {
997
1002
  workspace: e,
@@ -999,20 +1004,20 @@ function Z({ workspace: e, decision: t }) {
999
1004
  },
1000
1005
  className: "shrink-0 text-muted-foreground hover:text-foreground",
1001
1006
  children: t.identifier
1002
- }), /* @__PURE__ */ B("span", {
1007
+ }), /* @__PURE__ */ z("span", {
1003
1008
  className: "truncate",
1004
1009
  children: t.prompt
1005
1010
  })]
1006
1011
  }, t.id))
1007
1012
  })]
1008
1013
  }),
1009
- s && /* @__PURE__ */ B(O, {
1014
+ s && /* @__PURE__ */ z(k, {
1010
1015
  className: "mt-2 text-xs",
1011
1016
  summaryClassName: "text-muted-foreground hover:text-foreground",
1012
1017
  summary: n("checked"),
1013
- children: /* @__PURE__ */ B("div", {
1018
+ children: /* @__PURE__ */ z("div", {
1014
1019
  className: "mt-1 text-sm",
1015
- children: /* @__PURE__ */ B(w, {
1020
+ children: /* @__PURE__ */ z(T, {
1016
1021
  value: s,
1017
1022
  editable: !1
1018
1023
  })
@@ -1031,42 +1036,42 @@ function Q(e) {
1031
1036
  };
1032
1037
  }
1033
1038
  function $({ workspace: e, decisions: t }) {
1034
- let n = R("agentWork"), r = S(), i = K();
1035
- return /* @__PURE__ */ B(O, {
1039
+ let n = L("agentWork"), r = C(), i = G();
1040
+ return /* @__PURE__ */ z(k, {
1036
1041
  defaultOpen: !0,
1037
1042
  className: "rounded-lg border border-border text-sm",
1038
1043
  summaryClassName: "px-3 py-2 text-xs font-medium text-muted-foreground hover:text-foreground",
1039
1044
  summary: n("answeredCount", { count: t.length }),
1040
- children: /* @__PURE__ */ B("ul", {
1045
+ children: /* @__PURE__ */ z("ul", {
1041
1046
  className: "divide-y divide-border border-t border-border",
1042
1047
  children: t.map((t) => {
1043
1048
  let a = t.options.find((e) => e.id === t.answer?.optionId), o = a && i(t, a) || t.answer?.text || "", s = t.merge || t.release ? {
1044
1049
  text: n("answeredLabel"),
1045
1050
  code: !1
1046
1051
  } : Q(t.prompt);
1047
- return /* @__PURE__ */ B("li", { children: /* @__PURE__ */ B(O, {
1052
+ return /* @__PURE__ */ z("li", { children: /* @__PURE__ */ z(k, {
1048
1053
  summaryClassName: "w-full min-w-0 px-3 py-2 hover:bg-muted/50",
1049
- summary: /* @__PURE__ */ V("span", {
1054
+ summary: /* @__PURE__ */ B("span", {
1050
1055
  className: "flex min-w-0 flex-1 items-center gap-2",
1051
1056
  children: [
1052
- /* @__PURE__ */ B("span", {
1057
+ /* @__PURE__ */ z("span", {
1053
1058
  className: "shrink-0 font-medium",
1054
1059
  children: o
1055
1060
  }),
1056
- /* @__PURE__ */ B("span", {
1057
- className: G("min-w-0 flex-1 truncate text-muted-foreground", s.code && "font-mono text-xs"),
1061
+ /* @__PURE__ */ z("span", {
1062
+ className: W("min-w-0 flex-1 truncate text-muted-foreground", s.code && "font-mono text-xs"),
1058
1063
  children: s.text
1059
1064
  }),
1060
- t.answer && /* @__PURE__ */ B("time", {
1065
+ t.answer && /* @__PURE__ */ z("time", {
1061
1066
  dateTime: t.answer.at,
1062
1067
  className: "shrink-0 text-xs text-muted-foreground",
1063
1068
  children: r.relative(t.answer.at)
1064
1069
  })
1065
1070
  ]
1066
1071
  }),
1067
- children: /* @__PURE__ */ B("div", {
1072
+ children: /* @__PURE__ */ z("div", {
1068
1073
  className: "px-3 pb-3 pl-8",
1069
- children: /* @__PURE__ */ B(ke, {
1074
+ children: /* @__PURE__ */ z(Ae, {
1070
1075
  workspace: e,
1071
1076
  decision: t,
1072
1077
  bare: !0
@@ -1077,27 +1082,27 @@ function $({ workspace: e, decisions: t }) {
1077
1082
  })
1078
1083
  });
1079
1084
  }
1080
- function ke({ workspace: e, decision: t, showIssue: n = !1, showWorkspace: r = !1, bare: i = !1 }) {
1081
- let a = R("agentWork"), o = S(), { person: s } = b(e), c = fe(), l = v(), u = K(), d = t.options.find((e) => e.id === t.answer?.optionId), p = [d && u(t, d), t.answer?.text].filter(Boolean).join(". "), m = De(t), h = (n) => c(n, [
1085
+ function Ae({ workspace: e, decision: t, showIssue: n = !1, showWorkspace: r = !1, bare: i = !1 }) {
1086
+ let a = L("agentWork"), o = C(), { person: s } = b(e), c = me(), l = v(), u = G(), d = t.options.find((e) => e.id === t.answer?.optionId), p = [d && u(t, d), t.answer?.text].filter(Boolean).join(". "), m = ke(t), h = (n) => c(n, [
1082
1087
  ...m,
1083
- de,
1088
+ pe,
1084
1089
  ...l(f(e, t.identifier))
1085
- ]), g = /* @__PURE__ */ V(z, { children: [
1086
- /* @__PURE__ */ V("p", {
1090
+ ]), g = /* @__PURE__ */ B(R, { children: [
1091
+ /* @__PURE__ */ B("p", {
1087
1092
  className: "flex flex-wrap items-center gap-x-2 text-xs text-muted-foreground",
1088
1093
  children: [
1089
- r && /* @__PURE__ */ B("span", {
1094
+ r && /* @__PURE__ */ z("span", {
1090
1095
  className: "rounded bg-muted px-1.5 py-0.5 font-medium text-foreground",
1091
1096
  children: t.workspaceName
1092
1097
  }),
1093
- n && /* @__PURE__ */ B("span", {
1098
+ n && /* @__PURE__ */ z("span", {
1094
1099
  className: "font-medium text-foreground",
1095
1100
  children: t.identifier
1096
1101
  }),
1097
- /* @__PURE__ */ B("span", { children: a("askedBy", { agent: t.agentName }) }),
1098
- t.answer && /* @__PURE__ */ B(j, {
1102
+ /* @__PURE__ */ z("span", { children: a("askedBy", { agent: t.agentName }) }),
1103
+ t.answer && /* @__PURE__ */ z(fe, {
1099
1104
  content: o.full(t.answer.at),
1100
- children: /* @__PURE__ */ B("time", {
1105
+ children: /* @__PURE__ */ z("time", {
1101
1106
  dateTime: t.answer.at,
1102
1107
  children: a("answeredBy", {
1103
1108
  name: s(t.answer.by ?? "").name,
@@ -1107,35 +1112,35 @@ function ke({ workspace: e, decision: t, showIssue: n = !1, showWorkspace: r = !
1107
1112
  })
1108
1113
  ]
1109
1114
  }),
1110
- /* @__PURE__ */ B("div", {
1115
+ /* @__PURE__ */ z("div", {
1111
1116
  className: "mt-1.5",
1112
- children: /* @__PURE__ */ B(Te, {
1117
+ children: /* @__PURE__ */ z(De, {
1113
1118
  decision: t,
1114
1119
  className: "text-sm"
1115
1120
  })
1116
1121
  }),
1117
- /* @__PURE__ */ B("p", {
1122
+ /* @__PURE__ */ z("p", {
1118
1123
  className: "mt-1 font-medium",
1119
1124
  children: p
1120
1125
  }),
1121
- /* @__PURE__ */ B(Ee, {
1126
+ /* @__PURE__ */ z(Oe, {
1122
1127
  workspace: e,
1123
1128
  decision: t
1124
1129
  })
1125
1130
  ] });
1126
- return i ? /* @__PURE__ */ B("article", {
1131
+ return i ? /* @__PURE__ */ z("article", {
1127
1132
  onContextMenu: h,
1128
1133
  "aria-label": a("answeredLabel"),
1129
1134
  className: "text-sm",
1130
1135
  children: g
1131
- }) : /* @__PURE__ */ B(le, {
1136
+ }) : /* @__PURE__ */ z(le, {
1132
1137
  size: "fill",
1133
1138
  className: "text-sm",
1134
- render: /* @__PURE__ */ B("article", {
1139
+ render: /* @__PURE__ */ z("article", {
1135
1140
  onContextMenu: h,
1136
1141
  "aria-label": a("answeredLabel")
1137
1142
  }),
1138
1143
  children: g
1139
1144
  });
1140
1145
  }
1141
- export { ye as AgentWork, ke as AnsweredDecision, X as DecisionCard, ve as useMoney, K as useOptionLabel };
1146
+ export { xe as AgentWork, Ae as AnsweredDecision, X as DecisionCard, be as useMoney, G as useOptionLabel };