@burdenoff/microfe-stewards 2026.1203.1 → 2026.1204.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.
- package/dist/generated/wspace-operations.d.ts +3 -3
- package/dist/generated/wspace-operations.js.map +1 -1
- package/dist/generated/wspace-types.js.map +1 -1
- package/dist/node_modules/zustand/esm/vanilla.js.map +1 -1
- package/dist/stewards/StewardsRoot.js +15 -15
- package/dist/stewards/StewardsRoot.js.map +1 -1
- package/dist/stewards/StewardsRoutes.js +35 -35
- package/dist/stewards/StewardsRoutes.js.map +1 -1
- package/dist/stewards/components/CharterControls.js.map +1 -1
- package/dist/stewards/components/ControlBanner.js.map +1 -1
- package/dist/stewards/components/DutyEditor.js +44 -44
- package/dist/stewards/components/DutyEditor.js.map +1 -1
- package/dist/stewards/components/FormField.js.map +1 -1
- package/dist/stewards/components/LinesField.js +11 -11
- package/dist/stewards/components/LinesField.js.map +1 -1
- package/dist/stewards/components/LiveDeskPanel.js +57 -57
- package/dist/stewards/components/LiveDeskPanel.js.map +1 -1
- package/dist/stewards/components/MemoryDiffView.js.map +1 -1
- package/dist/stewards/components/ProposalsQueue.js.map +1 -1
- package/dist/stewards/components/RunsTable.js.map +1 -1
- package/dist/stewards/components/StewardsTable.js.map +1 -1
- package/dist/stewards/components/TeachRecorder.js +84 -84
- package/dist/stewards/components/TeachRecorder.js.map +1 -1
- package/dist/stewards/components/run/RunHeader.js +63 -63
- package/dist/stewards/components/run/RunHeader.js.map +1 -1
- package/dist/stewards/components/run/RunStepsSection.js +58 -58
- package/dist/stewards/components/run/RunStepsSection.js.map +1 -1
- package/dist/stewards/components/run/RunSummaryCards.js.map +1 -1
- package/dist/stewards/components/run/StepDetail.js +59 -59
- package/dist/stewards/components/run/StepDetail.js.map +1 -1
- package/dist/stewards/components/stewardLabels.js.map +1 -1
- package/dist/stewards/components/ui.js.map +1 -1
- package/dist/stewards/hooks/useStewards.js.map +1 -1
- package/dist/stewards/i18n/en.js.map +1 -1
- package/dist/stewards/i18n/useStewardsT.js +11 -11
- package/dist/stewards/i18n/useStewardsT.js.map +1 -1
- package/dist/stewards/live/DeskCanvas.js +35 -35
- package/dist/stewards/live/DeskCanvas.js.map +1 -1
- package/dist/stewards/live/DeskStreamConnection.js.map +1 -1
- package/dist/stewards/live/backoff.js.map +1 -1
- package/dist/stewards/live/browserConnection.js +6 -6
- package/dist/stewards/live/browserConnection.js.map +1 -1
- package/dist/stewards/live/describeStream.js.map +1 -1
- package/dist/stewards/live/mintPass.js +19 -19
- package/dist/stewards/live/mintPass.js.map +1 -1
- package/dist/stewards/live/protocol.js.map +1 -1
- package/dist/stewards/live/useDeskStream.js +11 -11
- package/dist/stewards/live/useDeskStream.js.map +1 -1
- package/dist/stewards/pages/StewardCharterPage.js +166 -166
- package/dist/stewards/pages/StewardCharterPage.js.map +1 -1
- package/dist/stewards/pages/StewardDaybookPage.js +101 -101
- package/dist/stewards/pages/StewardDaybookPage.js.map +1 -1
- package/dist/stewards/pages/StewardDutiesPage.js +89 -89
- package/dist/stewards/pages/StewardDutiesPage.js.map +1 -1
- package/dist/stewards/pages/StewardLayout.js +103 -103
- package/dist/stewards/pages/StewardLayout.js.map +1 -1
- package/dist/stewards/pages/StewardMemoryPage.js +135 -135
- package/dist/stewards/pages/StewardMemoryPage.js.map +1 -1
- package/dist/stewards/pages/StewardNewPage.js +172 -172
- package/dist/stewards/pages/StewardNewPage.js.map +1 -1
- package/dist/stewards/pages/StewardOverviewPage.js.map +1 -1
- package/dist/stewards/pages/StewardPlaybooksPage.js +151 -151
- package/dist/stewards/pages/StewardPlaybooksPage.js.map +1 -1
- package/dist/stewards/pages/StewardRunPage.js +65 -65
- package/dist/stewards/pages/StewardRunPage.js.map +1 -1
- package/dist/stewards/pages/StewardsListPage.js.map +1 -1
- package/dist/stewards/permissions/useStewardPermissions.js +7 -7
- package/dist/stewards/permissions/useStewardPermissions.js.map +1 -1
- package/dist/stewards/providers/StewardsProvider.js +18 -18
- package/dist/stewards/providers/StewardsProvider.js.map +1 -1
- package/dist/stewards/store/stewardsStore.js.map +1 -1
- package/dist/stewards/utils/charterForm.js.map +1 -1
- package/dist/stewards/utils/dates.js.map +1 -1
- package/dist/stewards/utils/daybook.js.map +1 -1
- package/dist/stewards/utils/dutyForm.js.map +1 -1
- package/dist/stewards/utils/errors.js.map +1 -1
- package/dist/stewards/utils/memory.js.map +1 -1
- package/dist/stewards/utils/playbookForm.js.map +1 -1
- package/dist/stewards/utils/recorder.js.map +1 -1
- package/dist/stewards/utils/wizard.js.map +1 -1
- package/package.json +5 -5
|
@@ -1,51 +1,51 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
1
|
+
import { useMemo as e, useState as t } from "react";
|
|
2
|
+
import { useBotmanorStewardWorkspaceControlsQuery as n, useCreateBotmanorStewardMutation as ee, useCreateStewardBaseAgentMutation as te, useListStewardAgentCandidatesQuery as r } from "../../generated/wspace-operations.js";
|
|
3
|
+
import { BotmanorAgentCapability as i, BotmanorAgentStatus as a, BotmanorAgentType as ne, BotmanorStewardAutonomy as re, BotmanorStewardDeskEgressMode as o, BotmanorStewardDeskKind as s } from "../../generated/wspace-types.js";
|
|
4
|
+
import { AutonomyPicker as ie, BudgetTable as ae, FixedDefaultsCard as oe, ToolSwitches as se } from "../components/CharterControls.js";
|
|
5
|
+
import { enumLabel as c } from "../components/stewardLabels.js";
|
|
6
|
+
import { Alert as l, Button as u, Card as d, StateMessage as f } from "../components/ui.js";
|
|
6
7
|
import "../components/fieldClasses.js";
|
|
7
|
-
import { useStewardsT as
|
|
8
|
-
import { useStewardAbilities as
|
|
9
|
-
import { useStewardsContext as
|
|
10
|
-
import { BUDGET_KEYS as
|
|
11
|
-
import { agentSlug as ue, buildCreateInput as de, capabilityForDesk as
|
|
12
|
-
import { jsx as
|
|
13
|
-
import { useMemo as fe, useState as y } from "react";
|
|
8
|
+
import { useStewardsT as p } from "../i18n/useStewardsT.js";
|
|
9
|
+
import { useStewardAbilities as m } from "../permissions/useStewardPermissions.js";
|
|
10
|
+
import { useStewardsContext as h } from "../providers/StewardsProvider.js";
|
|
11
|
+
import { BUDGET_KEYS as g, emptyBudgetsForm as _, mergeToolKeys as ce, splitLines as le } from "../utils/charterForm.js";
|
|
12
|
+
import { agentSlug as ue, buildCreateInput as de, capabilityForDesk as fe } from "../utils/wizard.js";
|
|
13
|
+
import { jsx as v, jsxs as y } from "react/jsx-runtime";
|
|
14
14
|
// src/stewards/pages/StewardNewPage.tsx
|
|
15
15
|
var b = [
|
|
16
16
|
"agent",
|
|
17
17
|
"charter",
|
|
18
18
|
"desk",
|
|
19
19
|
"review"
|
|
20
|
-
], pe =
|
|
20
|
+
], pe = g.filter((e) => e === "credits" || e === "deskMinutes" || e === "steps");
|
|
21
21
|
function x() {
|
|
22
|
-
let
|
|
22
|
+
let g = p(), { navigate: x, pathTo: S, workspaceId: C } = h(), { canCreate: me, ready: he } = m(), [w, T] = t("agent"), [E, D] = t("existing"), [O, ge] = t(""), [k, A] = t(null), [j, M] = t(""), [N, P] = t(""), [F, I] = t(!1), [L, R] = t(!1), [_e, ve] = t(null), [z, ye] = t({
|
|
23
23
|
charterText: "",
|
|
24
|
-
autonomyLevel:
|
|
24
|
+
autonomyLevel: re.Ask,
|
|
25
25
|
switches: [],
|
|
26
26
|
customToolText: "",
|
|
27
|
-
budgets:
|
|
27
|
+
budgets: _(),
|
|
28
28
|
deskKind: s.None,
|
|
29
29
|
egress: o.Public,
|
|
30
30
|
hostsText: ""
|
|
31
|
-
}), [B, V] =
|
|
31
|
+
}), [B, V] = t(null), [H, U] = t(null), W = r({
|
|
32
32
|
variables: { filters: {
|
|
33
|
-
status:
|
|
33
|
+
status: a.Active,
|
|
34
34
|
search: O || void 0
|
|
35
35
|
} },
|
|
36
36
|
skip: E !== "existing"
|
|
37
|
-
}), G = W.data?.listBotmanorAgents ?? [], be =
|
|
37
|
+
}), G = W.data?.listBotmanorAgents ?? [], be = n({ errorPolicy: "ignore" }), [xe, Se] = te(), [Ce, we] = ee(), K = E === "existing" ? k : _e, Te = j.trim() !== "" && N.trim() !== "" && !!C, q = e(() => E === "existing" ? k?.capabilities ?? [] : [...F ? [i.WebBrowsing] : [], ...L ? [i.ComputerUse] : []], [
|
|
38
38
|
E,
|
|
39
39
|
k,
|
|
40
40
|
F,
|
|
41
41
|
L
|
|
42
|
-
]), J =
|
|
43
|
-
if (he && !me) return /* @__PURE__ */
|
|
42
|
+
]), J = fe(z.deskKind), Y = Se.loading || we.loading;
|
|
43
|
+
if (he && !me) return /* @__PURE__ */ v("div", {
|
|
44
44
|
className: "p-6",
|
|
45
|
-
children: /* @__PURE__ */
|
|
45
|
+
children: /* @__PURE__ */ v(f, {
|
|
46
46
|
kind: "forbidden",
|
|
47
|
-
title:
|
|
48
|
-
body:
|
|
47
|
+
title: g("stewards.common.forbiddenTitle"),
|
|
48
|
+
body: g("stewards.common.forbiddenBody")
|
|
49
49
|
})
|
|
50
50
|
});
|
|
51
51
|
let X = (e) => ye((t) => ({
|
|
@@ -61,11 +61,11 @@ function x() {
|
|
|
61
61
|
name: j.trim(),
|
|
62
62
|
slug: ue(j, Date.now().toString(36)),
|
|
63
63
|
systemPrompt: N.trim(),
|
|
64
|
-
type:
|
|
65
|
-
status:
|
|
64
|
+
type: ne.Assistant,
|
|
65
|
+
status: a.Draft,
|
|
66
66
|
capabilities: q
|
|
67
67
|
} } }), n = t?.createBotmanorAgent;
|
|
68
|
-
if (!n) throw Error(
|
|
68
|
+
if (!n) throw Error(g("stewards.wizard.newAgentError"));
|
|
69
69
|
e = {
|
|
70
70
|
id: n.id,
|
|
71
71
|
name: n.name,
|
|
@@ -81,84 +81,84 @@ function x() {
|
|
|
81
81
|
let { data: n } = await Ce({ variables: { input: t.input } });
|
|
82
82
|
n?.createBotmanorSteward.id && x(S(n.createBotmanorSteward.id));
|
|
83
83
|
} catch (e) {
|
|
84
|
-
U(e instanceof Error ? e.message :
|
|
84
|
+
U(e instanceof Error ? e.message : g("stewards.wizard.createError"));
|
|
85
85
|
}
|
|
86
|
-
}, Q = be.data?.botmanorStewardWorkspaceControls.maxAutonomyLevel ?? null, $ =
|
|
87
|
-
return /* @__PURE__ */
|
|
86
|
+
}, Q = be.data?.botmanorStewardWorkspaceControls.maxAutonomyLevel ?? null, $ = ce(z.switches, le(z.customToolText)).length;
|
|
87
|
+
return /* @__PURE__ */ y("section", {
|
|
88
88
|
className: "flex flex-col gap-4 p-6",
|
|
89
89
|
children: [
|
|
90
|
-
/* @__PURE__ */
|
|
90
|
+
/* @__PURE__ */ y("header", {
|
|
91
91
|
className: "flex flex-wrap items-start justify-between gap-3",
|
|
92
|
-
children: [/* @__PURE__ */
|
|
92
|
+
children: [/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("h1", {
|
|
93
93
|
className: "text-xl font-semibold text-(color:--color-text-primary)",
|
|
94
|
-
children:
|
|
95
|
-
}), /* @__PURE__ */
|
|
94
|
+
children: g("stewards.wizard.title")
|
|
95
|
+
}), /* @__PURE__ */ y("p", {
|
|
96
96
|
className: "text-sm text-(color:--color-text-secondary)",
|
|
97
|
-
children: [K && `${K.name} · `,
|
|
97
|
+
children: [K && `${K.name} · `, g("stewards.wizard.stepOf", {
|
|
98
98
|
step: Z + 1,
|
|
99
99
|
total: b.length
|
|
100
100
|
})]
|
|
101
|
-
})] }), /* @__PURE__ */
|
|
101
|
+
})] }), /* @__PURE__ */ v(u, {
|
|
102
102
|
onClick: () => x(S()),
|
|
103
|
-
children:
|
|
103
|
+
children: g("stewards.common.cancel")
|
|
104
104
|
})]
|
|
105
105
|
}),
|
|
106
|
-
/* @__PURE__ */
|
|
106
|
+
/* @__PURE__ */ v("ol", {
|
|
107
107
|
className: "flex flex-wrap gap-2 rounded-lg border border-(color:--color-border-seam) bg-(--color-bg-surface) p-3 text-sm",
|
|
108
|
-
children: b.map((e, t) => /* @__PURE__ */
|
|
108
|
+
children: b.map((e, t) => /* @__PURE__ */ y("li", {
|
|
109
109
|
"aria-current": e === w ? "step" : void 0,
|
|
110
110
|
className: `flex items-center gap-2 ${e === w ? "font-medium text-(color:--color-text-primary)" : "text-(color:--color-text-secondary)"}`,
|
|
111
|
-
children: [/* @__PURE__ */
|
|
111
|
+
children: [/* @__PURE__ */ v("span", {
|
|
112
112
|
className: `inline-flex h-5 w-5 items-center justify-center rounded-full text-xs ${t < Z ? "bg-(--color-status-success-subtle) text-(color:--color-status-success-text)" : e === w ? "bg-(--color-action-primary-bg) text-(color:--color-action-primary-text)" : "bg-(--color-bg-muted)"}`,
|
|
113
113
|
children: t + 1
|
|
114
|
-
}),
|
|
114
|
+
}), g(`stewards.wizard.steps.${e}`)]
|
|
115
115
|
}, e))
|
|
116
116
|
}),
|
|
117
|
-
w === "agent" && /* @__PURE__ */
|
|
118
|
-
title:
|
|
119
|
-
hint:
|
|
120
|
-
children: [/* @__PURE__ */
|
|
117
|
+
w === "agent" && /* @__PURE__ */ y(d, {
|
|
118
|
+
title: g("stewards.wizard.agentTitle"),
|
|
119
|
+
hint: g("stewards.wizard.agentHelp"),
|
|
120
|
+
children: [/* @__PURE__ */ y("div", {
|
|
121
121
|
className: "mb-3 flex gap-4 text-sm text-(color:--color-text-primary)",
|
|
122
|
-
children: [/* @__PURE__ */
|
|
122
|
+
children: [/* @__PURE__ */ y("label", {
|
|
123
123
|
className: "flex items-center gap-2",
|
|
124
|
-
children: [/* @__PURE__ */
|
|
124
|
+
children: [/* @__PURE__ */ v("input", {
|
|
125
125
|
type: "radio",
|
|
126
126
|
name: "agent-mode",
|
|
127
127
|
checked: E === "existing",
|
|
128
128
|
onChange: () => D("existing")
|
|
129
|
-
}),
|
|
130
|
-
}), /* @__PURE__ */
|
|
129
|
+
}), g("stewards.wizard.pickExisting")]
|
|
130
|
+
}), /* @__PURE__ */ y("label", {
|
|
131
131
|
className: "flex items-center gap-2",
|
|
132
|
-
children: [/* @__PURE__ */
|
|
132
|
+
children: [/* @__PURE__ */ v("input", {
|
|
133
133
|
type: "radio",
|
|
134
134
|
name: "agent-mode",
|
|
135
135
|
checked: E === "new",
|
|
136
136
|
onChange: () => D("new")
|
|
137
|
-
}),
|
|
137
|
+
}), g("stewards.wizard.createNew")]
|
|
138
138
|
})]
|
|
139
|
-
}), E === "existing" ? /* @__PURE__ */
|
|
139
|
+
}), E === "existing" ? /* @__PURE__ */ y("div", {
|
|
140
140
|
className: "flex flex-col gap-2",
|
|
141
|
-
children: [/* @__PURE__ */
|
|
141
|
+
children: [/* @__PURE__ */ v("input", {
|
|
142
142
|
className: "w-full rounded-md border border-(color:--color-border-seam) bg-(--color-bg-surface) px-2 py-1.5 text-sm text-(color:--color-text-primary) placeholder:text-(color:--color-text-placeholder) focus-visible:outline-2 focus-visible:outline-(color:--color-focus-ring)",
|
|
143
143
|
type: "search",
|
|
144
|
-
"aria-label":
|
|
145
|
-
placeholder:
|
|
144
|
+
"aria-label": g("stewards.wizard.agentSearch"),
|
|
145
|
+
placeholder: g("stewards.wizard.agentSearch"),
|
|
146
146
|
value: O,
|
|
147
147
|
onChange: (e) => ge(e.target.value)
|
|
148
|
-
}), W.error ? /* @__PURE__ */
|
|
148
|
+
}), W.error ? /* @__PURE__ */ v(l, { children: W.error.message }) : W.loading ? /* @__PURE__ */ v(f, {
|
|
149
149
|
kind: "loading",
|
|
150
|
-
title:
|
|
151
|
-
}) : G.length === 0 ? /* @__PURE__ */
|
|
150
|
+
title: g("stewards.common.loading")
|
|
151
|
+
}) : G.length === 0 ? /* @__PURE__ */ v(f, {
|
|
152
152
|
kind: "empty",
|
|
153
|
-
title:
|
|
154
|
-
}) : /* @__PURE__ */
|
|
153
|
+
title: g("stewards.wizard.noAgents")
|
|
154
|
+
}) : /* @__PURE__ */ v("ul", {
|
|
155
155
|
className: "flex flex-col gap-1",
|
|
156
|
-
"aria-label":
|
|
157
|
-
children: G.map((e) => /* @__PURE__ */
|
|
156
|
+
"aria-label": g("stewards.wizard.agentTitle"),
|
|
157
|
+
children: G.map((e) => /* @__PURE__ */ v("li", { children: /* @__PURE__ */ y("label", {
|
|
158
158
|
className: `flex cursor-pointer flex-col rounded-md border p-2 text-sm ${k?.id === e.id ? "border-(color:--color-accent-primary) bg-(--color-accent-soft)" : "border-(color:--color-border-seam)"}`,
|
|
159
|
-
children: [/* @__PURE__ */
|
|
159
|
+
children: [/* @__PURE__ */ y("span", {
|
|
160
160
|
className: "flex items-center gap-2 font-medium text-(color:--color-text-primary)",
|
|
161
|
-
children: [/* @__PURE__ */
|
|
161
|
+
children: [/* @__PURE__ */ v("input", {
|
|
162
162
|
type: "radio",
|
|
163
163
|
name: "agent",
|
|
164
164
|
checked: k?.id === e.id,
|
|
@@ -168,104 +168,104 @@ function x() {
|
|
|
168
168
|
capabilities: e.capabilities
|
|
169
169
|
})
|
|
170
170
|
}), e.name]
|
|
171
|
-
}), e.description && /* @__PURE__ */
|
|
171
|
+
}), e.description && /* @__PURE__ */ v("span", {
|
|
172
172
|
className: "pl-6 text-xs text-(color:--color-text-secondary)",
|
|
173
173
|
children: e.description
|
|
174
174
|
})]
|
|
175
175
|
}) }, e.id))
|
|
176
176
|
})]
|
|
177
|
-
}) : /* @__PURE__ */
|
|
177
|
+
}) : /* @__PURE__ */ y("div", {
|
|
178
178
|
className: "flex flex-col gap-3",
|
|
179
179
|
children: [
|
|
180
|
-
!C && /* @__PURE__ */
|
|
181
|
-
/* @__PURE__ */
|
|
180
|
+
!C && /* @__PURE__ */ v(l, { children: g("stewards.wizard.newAgentError") }),
|
|
181
|
+
/* @__PURE__ */ y("label", {
|
|
182
182
|
className: "flex flex-col gap-1 text-sm text-(color:--color-text-secondary)",
|
|
183
|
-
children: [
|
|
183
|
+
children: [g("stewards.wizard.agentName"), /* @__PURE__ */ v("input", {
|
|
184
184
|
className: "w-full rounded-md border border-(color:--color-border-seam) bg-(--color-bg-surface) px-2 py-1.5 text-sm text-(color:--color-text-primary) placeholder:text-(color:--color-text-placeholder) focus-visible:outline-2 focus-visible:outline-(color:--color-focus-ring)",
|
|
185
185
|
maxLength: 120,
|
|
186
186
|
value: j,
|
|
187
187
|
onChange: (e) => M(e.target.value)
|
|
188
188
|
})]
|
|
189
189
|
}),
|
|
190
|
-
/* @__PURE__ */
|
|
190
|
+
/* @__PURE__ */ y("label", {
|
|
191
191
|
className: "flex flex-col gap-1 text-sm text-(color:--color-text-secondary)",
|
|
192
192
|
children: [
|
|
193
|
-
|
|
194
|
-
/* @__PURE__ */
|
|
193
|
+
g("stewards.wizard.agentPrompt"),
|
|
194
|
+
/* @__PURE__ */ v("textarea", {
|
|
195
195
|
className: "w-full rounded-md border border-(color:--color-border-seam) bg-(--color-bg-surface) px-2 py-1.5 text-sm text-(color:--color-text-primary) placeholder:text-(color:--color-text-placeholder) focus-visible:outline-2 focus-visible:outline-(color:--color-focus-ring) min-h-24",
|
|
196
196
|
value: N,
|
|
197
197
|
onChange: (e) => P(e.target.value)
|
|
198
198
|
}),
|
|
199
|
-
/* @__PURE__ */
|
|
199
|
+
/* @__PURE__ */ v("span", {
|
|
200
200
|
className: "text-xs",
|
|
201
|
-
children:
|
|
201
|
+
children: g("stewards.wizard.agentPromptHelp")
|
|
202
202
|
})
|
|
203
203
|
]
|
|
204
204
|
}),
|
|
205
|
-
/* @__PURE__ */
|
|
205
|
+
/* @__PURE__ */ y("fieldset", {
|
|
206
206
|
className: "flex flex-col gap-1 text-sm text-(color:--color-text-primary)",
|
|
207
207
|
children: [
|
|
208
|
-
/* @__PURE__ */
|
|
208
|
+
/* @__PURE__ */ y("legend", {
|
|
209
209
|
className: "mb-1 text-xs text-(color:--color-text-secondary)",
|
|
210
210
|
children: [
|
|
211
|
-
|
|
211
|
+
g("stewards.wizard.capabilities"),
|
|
212
212
|
" — ",
|
|
213
|
-
|
|
213
|
+
g("stewards.wizard.capabilityHelp")
|
|
214
214
|
]
|
|
215
215
|
}),
|
|
216
|
-
/* @__PURE__ */
|
|
216
|
+
/* @__PURE__ */ y("label", {
|
|
217
217
|
className: "flex items-center gap-2",
|
|
218
|
-
children: [/* @__PURE__ */
|
|
218
|
+
children: [/* @__PURE__ */ v("input", {
|
|
219
219
|
type: "checkbox",
|
|
220
220
|
checked: F,
|
|
221
221
|
onChange: (e) => I(e.target.checked)
|
|
222
|
-
}),
|
|
222
|
+
}), g("stewards.wizard.capWeb")]
|
|
223
223
|
}),
|
|
224
|
-
/* @__PURE__ */
|
|
224
|
+
/* @__PURE__ */ y("label", {
|
|
225
225
|
className: "flex items-center gap-2",
|
|
226
|
-
children: [/* @__PURE__ */
|
|
226
|
+
children: [/* @__PURE__ */ v("input", {
|
|
227
227
|
type: "checkbox",
|
|
228
228
|
checked: L,
|
|
229
229
|
onChange: (e) => R(e.target.checked)
|
|
230
|
-
}),
|
|
230
|
+
}), g("stewards.wizard.capComputer")]
|
|
231
231
|
})
|
|
232
232
|
]
|
|
233
233
|
})
|
|
234
234
|
]
|
|
235
235
|
})]
|
|
236
236
|
}),
|
|
237
|
-
w === "charter" && /* @__PURE__ */
|
|
237
|
+
w === "charter" && /* @__PURE__ */ y("div", {
|
|
238
238
|
className: "grid grid-cols-1 gap-4 lg:grid-cols-3",
|
|
239
|
-
children: [/* @__PURE__ */
|
|
239
|
+
children: [/* @__PURE__ */ y("div", {
|
|
240
240
|
className: "flex flex-col gap-4 lg:col-span-2",
|
|
241
241
|
children: [
|
|
242
|
-
/* @__PURE__ */
|
|
243
|
-
title:
|
|
244
|
-
hint:
|
|
245
|
-
children: [/* @__PURE__ */
|
|
242
|
+
/* @__PURE__ */ y(d, {
|
|
243
|
+
title: g("stewards.wizard.charterTitle"),
|
|
244
|
+
hint: g("stewards.wizard.charterHelp"),
|
|
245
|
+
children: [/* @__PURE__ */ v("textarea", {
|
|
246
246
|
className: "w-full rounded-md border border-(color:--color-border-seam) bg-(--color-bg-surface) px-2 py-1.5 text-sm text-(color:--color-text-primary) placeholder:text-(color:--color-text-placeholder) focus-visible:outline-2 focus-visible:outline-(color:--color-focus-ring) min-h-32",
|
|
247
|
-
"aria-label":
|
|
247
|
+
"aria-label": g("stewards.wizard.charterLabel"),
|
|
248
248
|
"aria-invalid": B?.kind === "charterText",
|
|
249
|
-
placeholder:
|
|
249
|
+
placeholder: g("stewards.wizard.charterPlaceholder"),
|
|
250
250
|
value: z.charterText,
|
|
251
251
|
onChange: (e) => X({ charterText: e.target.value })
|
|
252
|
-
}), B?.kind === "charterText" && /* @__PURE__ */
|
|
252
|
+
}), B?.kind === "charterText" && /* @__PURE__ */ v(l, { children: g("stewards.wizard.charterRequired") })]
|
|
253
253
|
}),
|
|
254
|
-
/* @__PURE__ */
|
|
255
|
-
title:
|
|
256
|
-
hint:
|
|
257
|
-
children: [/* @__PURE__ */
|
|
254
|
+
/* @__PURE__ */ y(d, {
|
|
255
|
+
title: g("stewards.wizard.autonomyTitle"),
|
|
256
|
+
hint: g("stewards.wizard.autonomyHint"),
|
|
257
|
+
children: [/* @__PURE__ */ v(ie, {
|
|
258
258
|
value: z.autonomyLevel,
|
|
259
259
|
maxLevel: Q,
|
|
260
260
|
onChange: (e) => X({ autonomyLevel: e })
|
|
261
|
-
}), Q && /* @__PURE__ */
|
|
261
|
+
}), Q && /* @__PURE__ */ v("p", {
|
|
262
262
|
className: "mt-2 text-xs text-(color:--color-text-secondary)",
|
|
263
|
-
children:
|
|
263
|
+
children: g("stewards.wizard.autonomyLockedByAdmin", { level: c(g, "autonomy", Q) })
|
|
264
264
|
})]
|
|
265
265
|
}),
|
|
266
|
-
/* @__PURE__ */
|
|
267
|
-
title:
|
|
268
|
-
children: [B?.kind === "budget" && /* @__PURE__ */
|
|
266
|
+
/* @__PURE__ */ y(d, {
|
|
267
|
+
title: g("stewards.charter.autonomyTitle"),
|
|
268
|
+
children: [B?.kind === "budget" && /* @__PURE__ */ v(l, { children: g("stewards.budget.invalid", { name: g(`stewards.budget.${B.key}`) }) }), /* @__PURE__ */ v(ae, {
|
|
269
269
|
budgets: z.budgets,
|
|
270
270
|
keys: pe,
|
|
271
271
|
errorAt: B?.kind === "budget" ? B : null,
|
|
@@ -279,172 +279,172 @@ function x() {
|
|
|
279
279
|
})]
|
|
280
280
|
})
|
|
281
281
|
]
|
|
282
|
-
}), /* @__PURE__ */
|
|
282
|
+
}), /* @__PURE__ */ y("div", {
|
|
283
283
|
className: "flex flex-col gap-4",
|
|
284
|
-
children: [/* @__PURE__ */
|
|
285
|
-
title:
|
|
286
|
-
hint:
|
|
284
|
+
children: [/* @__PURE__ */ y(d, {
|
|
285
|
+
title: g("stewards.wizard.toolsTitle"),
|
|
286
|
+
hint: g("stewards.wizard.toolsCount", { count: $ }),
|
|
287
287
|
children: [
|
|
288
|
-
/* @__PURE__ */
|
|
288
|
+
/* @__PURE__ */ v(se, {
|
|
289
289
|
allowed: z.switches,
|
|
290
290
|
onToggle: (e, t) => X({ switches: t ? [...z.switches, e] : z.switches.filter((t) => t !== e) })
|
|
291
291
|
}),
|
|
292
|
-
/* @__PURE__ */
|
|
292
|
+
/* @__PURE__ */ y("label", {
|
|
293
293
|
className: "mt-3 flex flex-col gap-1 text-xs text-(color:--color-text-secondary)",
|
|
294
294
|
children: [
|
|
295
|
-
|
|
296
|
-
/* @__PURE__ */
|
|
295
|
+
g("stewards.charter.customTitle"),
|
|
296
|
+
/* @__PURE__ */ v("textarea", {
|
|
297
297
|
className: "w-full rounded-md border border-(color:--color-border-seam) bg-(--color-bg-surface) px-2 py-1.5 text-sm text-(color:--color-text-primary) placeholder:text-(color:--color-text-placeholder) focus-visible:outline-2 focus-visible:outline-(color:--color-focus-ring) min-h-16 font-mono",
|
|
298
298
|
value: z.customToolText,
|
|
299
299
|
"aria-invalid": B?.kind === "toolKey",
|
|
300
300
|
onChange: (e) => X({ customToolText: e.target.value })
|
|
301
301
|
}),
|
|
302
|
-
|
|
302
|
+
g("stewards.charter.customHint")
|
|
303
303
|
]
|
|
304
304
|
}),
|
|
305
|
-
B?.kind === "toolKey" && /* @__PURE__ */
|
|
305
|
+
B?.kind === "toolKey" && /* @__PURE__ */ v(l, { children: g("stewards.charter.customInvalid", { key: B.key }) })
|
|
306
306
|
]
|
|
307
|
-
}), /* @__PURE__ */
|
|
307
|
+
}), /* @__PURE__ */ v(oe, {})]
|
|
308
308
|
})]
|
|
309
309
|
}),
|
|
310
|
-
w === "desk" && /* @__PURE__ */
|
|
311
|
-
title:
|
|
312
|
-
hint:
|
|
310
|
+
w === "desk" && /* @__PURE__ */ y(d, {
|
|
311
|
+
title: g("stewards.wizard.deskTitle"),
|
|
312
|
+
hint: g("stewards.wizard.deskHelp"),
|
|
313
313
|
children: [
|
|
314
|
-
/* @__PURE__ */
|
|
314
|
+
/* @__PURE__ */ y("fieldset", {
|
|
315
315
|
className: "grid grid-cols-1 gap-2 sm:grid-cols-2 lg:grid-cols-4",
|
|
316
|
-
children: [/* @__PURE__ */
|
|
316
|
+
children: [/* @__PURE__ */ v("legend", {
|
|
317
317
|
className: "sr-only",
|
|
318
|
-
children:
|
|
319
|
-
}), Object.values(s).map((e) => /* @__PURE__ */
|
|
318
|
+
children: g("stewards.wizard.deskTitle")
|
|
319
|
+
}), Object.values(s).map((e) => /* @__PURE__ */ y("label", {
|
|
320
320
|
className: `flex cursor-pointer flex-col gap-1 rounded-md border p-3 text-sm ${z.deskKind === e ? "border-(color:--color-accent-primary) bg-(--color-accent-soft)" : "border-(color:--color-border-seam)"}`,
|
|
321
|
-
children: [/* @__PURE__ */
|
|
321
|
+
children: [/* @__PURE__ */ y("span", {
|
|
322
322
|
className: "flex items-center gap-2 font-medium text-(color:--color-text-primary)",
|
|
323
|
-
children: [/* @__PURE__ */
|
|
323
|
+
children: [/* @__PURE__ */ v("input", {
|
|
324
324
|
type: "radio",
|
|
325
325
|
name: "desk",
|
|
326
326
|
checked: z.deskKind === e,
|
|
327
327
|
onChange: () => X({ deskKind: e })
|
|
328
|
-
}),
|
|
329
|
-
}), /* @__PURE__ */
|
|
328
|
+
}), c(g, "desk", e)]
|
|
329
|
+
}), /* @__PURE__ */ v("span", {
|
|
330
330
|
className: "text-xs text-(color:--color-text-secondary)",
|
|
331
|
-
children:
|
|
331
|
+
children: c(g, "deskHelp", e)
|
|
332
332
|
})]
|
|
333
333
|
}, e))]
|
|
334
334
|
}),
|
|
335
|
-
J && !q.includes(J) && /* @__PURE__ */
|
|
335
|
+
J && !q.includes(J) && /* @__PURE__ */ v("div", {
|
|
336
336
|
className: "mt-3",
|
|
337
|
-
children: /* @__PURE__ */
|
|
337
|
+
children: /* @__PURE__ */ v(l, {
|
|
338
338
|
tone: "info",
|
|
339
|
-
children:
|
|
339
|
+
children: g("stewards.wizard.deskNeeds", { capability: J === i.WebBrowsing ? g("stewards.wizard.capWeb") : g("stewards.wizard.capComputer") })
|
|
340
340
|
})
|
|
341
341
|
}),
|
|
342
|
-
z.deskKind !== s.None && /* @__PURE__ */
|
|
342
|
+
z.deskKind !== s.None && /* @__PURE__ */ y("div", {
|
|
343
343
|
className: "mt-4 flex flex-col gap-3",
|
|
344
|
-
children: [/* @__PURE__ */
|
|
344
|
+
children: [/* @__PURE__ */ y("label", {
|
|
345
345
|
className: "flex flex-col gap-1 text-sm text-(color:--color-text-secondary)",
|
|
346
|
-
children: [
|
|
346
|
+
children: [g("stewards.wizard.egressTitle"), /* @__PURE__ */ v("select", {
|
|
347
347
|
className: "w-full rounded-md border border-(color:--color-border-seam) bg-(--color-bg-surface) px-2 py-1.5 text-sm text-(color:--color-text-primary) placeholder:text-(color:--color-text-placeholder) focus-visible:outline-2 focus-visible:outline-(color:--color-focus-ring)",
|
|
348
348
|
value: z.egress,
|
|
349
349
|
onChange: (e) => X({ egress: e.target.value }),
|
|
350
|
-
children: Object.values(o).map((e) => /* @__PURE__ */
|
|
350
|
+
children: Object.values(o).map((e) => /* @__PURE__ */ v("option", {
|
|
351
351
|
value: e,
|
|
352
|
-
children:
|
|
352
|
+
children: c(g, "egress", e)
|
|
353
353
|
}, e))
|
|
354
354
|
})]
|
|
355
|
-
}), z.egress === o.AllowList && /* @__PURE__ */
|
|
355
|
+
}), z.egress === o.AllowList && /* @__PURE__ */ y("label", {
|
|
356
356
|
className: "flex flex-col gap-1 text-sm text-(color:--color-text-secondary)",
|
|
357
357
|
children: [
|
|
358
|
-
|
|
359
|
-
/* @__PURE__ */
|
|
358
|
+
g("stewards.wizard.allowedHosts"),
|
|
359
|
+
/* @__PURE__ */ v("textarea", {
|
|
360
360
|
className: "w-full rounded-md border border-(color:--color-border-seam) bg-(--color-bg-surface) px-2 py-1.5 text-sm text-(color:--color-text-primary) placeholder:text-(color:--color-text-placeholder) focus-visible:outline-2 focus-visible:outline-(color:--color-focus-ring) min-h-20 font-mono",
|
|
361
361
|
value: z.hostsText,
|
|
362
362
|
onChange: (e) => X({ hostsText: e.target.value })
|
|
363
363
|
}),
|
|
364
|
-
/* @__PURE__ */
|
|
364
|
+
/* @__PURE__ */ v("span", {
|
|
365
365
|
className: "text-xs",
|
|
366
|
-
children:
|
|
366
|
+
children: g("stewards.wizard.allowedHostsHelp")
|
|
367
367
|
})
|
|
368
368
|
]
|
|
369
369
|
})]
|
|
370
370
|
})
|
|
371
371
|
]
|
|
372
372
|
}),
|
|
373
|
-
w === "review" && /* @__PURE__ */
|
|
374
|
-
title:
|
|
375
|
-
hint:
|
|
373
|
+
w === "review" && /* @__PURE__ */ y(d, {
|
|
374
|
+
title: g("stewards.wizard.reviewTitle"),
|
|
375
|
+
hint: g("stewards.wizard.reviewBody"),
|
|
376
376
|
children: [
|
|
377
|
-
/* @__PURE__ */
|
|
377
|
+
/* @__PURE__ */ y("dl", {
|
|
378
378
|
className: "grid grid-cols-1 gap-x-6 gap-y-2 text-sm sm:grid-cols-2",
|
|
379
379
|
children: [
|
|
380
|
-
/* @__PURE__ */
|
|
380
|
+
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("dt", {
|
|
381
381
|
className: "text-xs text-(color:--color-text-secondary)",
|
|
382
|
-
children:
|
|
383
|
-
}), /* @__PURE__ */
|
|
382
|
+
children: g("stewards.wizard.reviewAgent")
|
|
383
|
+
}), /* @__PURE__ */ v("dd", {
|
|
384
384
|
className: "text-(color:--color-text-primary)",
|
|
385
385
|
children: E === "existing" ? k?.name : j
|
|
386
386
|
})] }),
|
|
387
|
-
/* @__PURE__ */
|
|
387
|
+
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("dt", {
|
|
388
388
|
className: "text-xs text-(color:--color-text-secondary)",
|
|
389
|
-
children:
|
|
390
|
-
}), /* @__PURE__ */
|
|
389
|
+
children: g("stewards.wizard.reviewAutonomy")
|
|
390
|
+
}), /* @__PURE__ */ v("dd", {
|
|
391
391
|
className: "text-(color:--color-text-primary)",
|
|
392
|
-
children:
|
|
392
|
+
children: c(g, "autonomy", z.autonomyLevel)
|
|
393
393
|
})] }),
|
|
394
|
-
/* @__PURE__ */
|
|
394
|
+
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("dt", {
|
|
395
395
|
className: "text-xs text-(color:--color-text-secondary)",
|
|
396
|
-
children:
|
|
397
|
-
}), /* @__PURE__ */
|
|
396
|
+
children: g("stewards.wizard.reviewDesk")
|
|
397
|
+
}), /* @__PURE__ */ v("dd", {
|
|
398
398
|
className: "text-(color:--color-text-primary)",
|
|
399
|
-
children:
|
|
399
|
+
children: c(g, "desk", z.deskKind)
|
|
400
400
|
})] }),
|
|
401
|
-
/* @__PURE__ */
|
|
401
|
+
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("dt", {
|
|
402
402
|
className: "text-xs text-(color:--color-text-secondary)",
|
|
403
|
-
children:
|
|
404
|
-
}), /* @__PURE__ */
|
|
403
|
+
children: g("stewards.wizard.reviewTools")
|
|
404
|
+
}), /* @__PURE__ */ v("dd", {
|
|
405
405
|
className: "text-(color:--color-text-primary)",
|
|
406
406
|
children: $
|
|
407
407
|
})] }),
|
|
408
|
-
/* @__PURE__ */
|
|
408
|
+
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("dt", {
|
|
409
409
|
className: "text-xs text-(color:--color-text-secondary)",
|
|
410
|
-
children:
|
|
411
|
-
}), /* @__PURE__ */
|
|
410
|
+
children: g("stewards.wizard.reviewBudget")
|
|
411
|
+
}), /* @__PURE__ */ v("dd", {
|
|
412
412
|
className: "text-(color:--color-text-primary)",
|
|
413
|
-
children: z.budgets.perDay.credits ||
|
|
413
|
+
children: z.budgets.perDay.credits || g("stewards.common.noCap")
|
|
414
414
|
})] })
|
|
415
415
|
]
|
|
416
416
|
}),
|
|
417
|
-
/* @__PURE__ */
|
|
417
|
+
/* @__PURE__ */ v("p", {
|
|
418
418
|
className: "mt-3 whitespace-pre-wrap rounded-md bg-(--color-bg-muted) p-3 text-sm text-(color:--color-text-primary)",
|
|
419
419
|
children: z.charterText
|
|
420
420
|
}),
|
|
421
|
-
E === "new" && /* @__PURE__ */
|
|
421
|
+
E === "new" && /* @__PURE__ */ v("p", {
|
|
422
422
|
className: "mt-3 text-sm text-(color:--color-text-secondary)",
|
|
423
|
-
children:
|
|
423
|
+
children: g("stewards.wizard.reviewNewAgentDraft")
|
|
424
424
|
})
|
|
425
425
|
]
|
|
426
426
|
}),
|
|
427
|
-
H && /* @__PURE__ */
|
|
428
|
-
|
|
427
|
+
H && /* @__PURE__ */ y(l, { children: [
|
|
428
|
+
g("stewards.wizard.createError"),
|
|
429
429
|
" ",
|
|
430
430
|
H
|
|
431
431
|
] }),
|
|
432
|
-
/* @__PURE__ */
|
|
432
|
+
/* @__PURE__ */ y("footer", {
|
|
433
433
|
className: "flex justify-between gap-2",
|
|
434
|
-
children: [/* @__PURE__ */
|
|
434
|
+
children: [/* @__PURE__ */ v(u, {
|
|
435
435
|
disabled: Z === 0 || Y,
|
|
436
436
|
onClick: () => T(b[Math.max(0, Z - 1)] ?? "agent"),
|
|
437
|
-
children:
|
|
438
|
-
}), w === "review" ? /* @__PURE__ */
|
|
437
|
+
children: g("stewards.common.back")
|
|
438
|
+
}), w === "review" ? /* @__PURE__ */ v(u, {
|
|
439
439
|
variant: "primary",
|
|
440
440
|
disabled: Y,
|
|
441
441
|
onClick: () => void De(),
|
|
442
|
-
children:
|
|
443
|
-
}) : /* @__PURE__ */
|
|
442
|
+
children: g(Y ? "stewards.wizard.creating" : "stewards.wizard.create")
|
|
443
|
+
}) : /* @__PURE__ */ v(u, {
|
|
444
444
|
variant: "primary",
|
|
445
445
|
disabled: !Ee,
|
|
446
446
|
onClick: () => T(b[Z + 1] ?? "review"),
|
|
447
|
-
children:
|
|
447
|
+
children: g("stewards.wizard.next")
|
|
448
448
|
})]
|
|
449
449
|
})
|
|
450
450
|
]
|