@burdenoff/microfe-vibecontrols 2026.520.1 → 2026.520.2

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.
@@ -3,32 +3,34 @@ import { useVibeControls as oe, useVibeNavigate as se } from "../providers/VibeC
3
3
  import ce from "../hooks/useCachedInitialData.js";
4
4
  import { PageHeader as le } from "../components/shared/PageHeader.js";
5
5
  import { LoadingState as ue } from "../components/shared/LoadingState.js";
6
- import { ConfirmDialog as de } from "../components/shared/ConfirmDialog.js";
7
- import { getQuotaDialogContent as fe, isQuotaExhaustedError as pe } from "../utils/quotaUtils.js";
8
- import { isNative as me, nativeNotify as he } from "../utils/nativeBridge.js";
9
- import { EmptyState as ge } from "../components/shared/EmptyState.js";
10
- import { SearchInput as _e } from "../components/shared/SearchInput.js";
11
- import { FilterDropdown as ve } from "../components/shared/FilterDropdown.js";
12
- import { AgentSetupBanner as ye } from "../components/shared/AgentSetupBanner.js";
13
- import { GetHelpButton as be } from "../components/shared/GetHelpButton.js";
14
- import { SearchableSelect as xe } from "../components/shared/SearchableSelect.js";
6
+ import { ConfirmDialog as r } from "../components/shared/ConfirmDialog.js";
7
+ import { getQuotaDialogContent as de, isQuotaExhaustedError as fe } from "../utils/quotaUtils.js";
8
+ import { EntityTagPicker as pe } from "../components/shared/EntityTagPicker.js";
9
+ import { useDraftEntityTags as me } from "../hooks/useDraftEntityTags.js";
10
+ import { isNative as he, nativeNotify as ge } from "../utils/nativeBridge.js";
11
+ import { EmptyState as _e } from "../components/shared/EmptyState.js";
12
+ import { SearchInput as ve } from "../components/shared/SearchInput.js";
13
+ import { FilterDropdown as ye } from "../components/shared/FilterDropdown.js";
14
+ import { AgentSetupBanner as be } from "../components/shared/AgentSetupBanner.js";
15
+ import { GetHelpButton as xe } from "../components/shared/GetHelpButton.js";
16
+ import { SearchableSelect as Se } from "../components/shared/SearchableSelect.js";
15
17
  import "../components/shared/index.js";
16
- import { VIBE_PERMISSIONS as Se } from "../constants/permissions.js";
17
- import { TargetCard as Ce } from "../components/targets/TargetCard.js";
18
+ import { VIBE_PERMISSIONS as Ce } from "../constants/permissions.js";
19
+ import { TargetCard as we } from "../components/targets/TargetCard.js";
18
20
  import "../components/targets/index.js";
19
- import { useCallback as r, useEffect as we, useMemo as i, useState as a } from "react";
20
- import { useI18n as Te } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
21
- import { Check as Ee, CheckCircle as De, CheckSquare as Oe, Grid as ke, List as Ae, Loader2 as je, Pencil as Me, Plus as Ne, RefreshCw as Pe, Server as Fe, Trash2 as Ie, X as o, XCircle as Le, XSquare as Re } from "lucide-react";
22
- import { useSearchParams as ze } from "react-router-dom";
23
- import { usePermissions as Be } from "@burdenoff/fe-libs/shared/providers/shell";
24
- import { AnimatePresence as Ve } from "framer-motion";
25
- import { Fragment as s, jsx as c, jsxs as l } from "react/jsx-runtime";
26
- import { MotionItem as He, MotionList as Ue, MotionPage as We } from "@burdenoff/fe-libs/shared/motion";
21
+ import { useCallback as i, useEffect as Te, useMemo as a, useState as o } from "react";
22
+ import { useI18n as Ee } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
23
+ import { Check as De, CheckCircle as Oe, CheckSquare as ke, Grid as Ae, List as je, Loader2 as Me, Pencil as Ne, Plus as Pe, RefreshCw as Fe, Server as Ie, Trash2 as Le, X as s, XCircle as Re, XSquare as ze } from "lucide-react";
24
+ import { useSearchParams as Be } from "react-router-dom";
25
+ import { usePermissions as Ve } from "@burdenoff/fe-libs/shared/providers/shell";
26
+ import { AnimatePresence as He } from "framer-motion";
27
+ import { Fragment as c, jsx as l, jsxs as u } from "react/jsx-runtime";
28
+ import { MotionItem as Ue, MotionList as We, MotionPage as Ge } from "@burdenoff/fe-libs/shared/motion";
27
29
  //#region src/pages/TargetsPage.tsx
28
- function Ge(e) {
30
+ function Ke(e) {
29
31
  return e === "connected" ? "connected" : e === "disconnected" ? "disconnected" : "unknown";
30
32
  }
31
- var Ke = {
33
+ var qe = {
32
34
  connect: "Connecting to server",
33
35
  detect_os: "Detecting OS",
34
36
  install_bun: "Installing Bun runtime",
@@ -38,37 +40,37 @@ var Ke = {
38
40
  verify: "Verifying health",
39
41
  retrieve: "Retrieving agent details",
40
42
  register: "Registering with backend"
41
- }, qe = {
43
+ }, Je = {
42
44
  connected: { label: "Connected" },
43
45
  disconnected: { label: "Disconnected" },
44
46
  unknown: { label: "Unknown" }
45
- }, Je = {
47
+ }, Ye = {
46
48
  DIRECT: "bg-action-primary-bg/10 text-action-primary-bg",
47
49
  SSH: "bg-status-success-bg-subtle text-status-success-text"
48
- }, Ye = {
50
+ }, Xe = {
49
51
  connected: "bg-status-success-bg-subtle text-status-success-text",
50
52
  disconnected: "bg-status-error-bg-subtle text-status-error-text",
51
53
  unknown: "bg-bg-sunken text-text-secondary"
52
54
  };
53
- function Xe(e) {
55
+ function Ze(e) {
54
56
  return e.agents.length > 0;
55
57
  }
56
- function u() {
57
- let { t: u } = Te(), { workspaceId: d } = oe(), f = se(), { hasPermission: Ze, isLoading: Qe } = Be(), [$e] = ze(), p = $e.get("selectedTargetId"), [m, et] = a(""), [h, tt] = a(null), [g, nt] = a("all"), [_, rt] = a("all"), [it, at] = a("grid"), [ot, v] = a(!1), [y, b] = a(null), [st, ct] = a(!1), [x, S] = a(/* @__PURE__ */ new Set()), [C, lt] = a(null), [ut, w] = a(!1), T = r((e, t) => {
58
- let n = u(e);
58
+ function d() {
59
+ let { t: d } = Ee(), { workspaceId: f } = oe(), p = se(), { hasPermission: Qe, isLoading: $e } = Ve(), [et] = Be(), m = et.get("selectedTargetId"), [h, tt] = o(""), [g, nt] = o(null), [_, rt] = o("all"), [v, it] = o("all"), [at, ot] = o("grid"), [st, y] = o(!1), [b, x] = o(null), [ct, lt] = o(!1), [S, C] = o(/* @__PURE__ */ new Set()), [w, ut] = o(null), [dt, T] = o(!1), E = i((e, t) => {
60
+ let n = d(e);
59
61
  return n === e ? t : n;
60
- }, [u]), [E, dt] = a(null), [D, ft] = a(null), [pt, O] = a(null), [k, A] = a(null), [j, mt] = a(!1), [ht, M] = a(null), [N, gt] = a(""), [_t, vt] = a(""), [yt, bt] = a(""), [xt, St] = a(22), [Ct, wt] = a(""), [P, Tt] = a("key"), [F, Et] = a(""), [I, Dt] = a(""), [L, Ot] = a(""), [R, kt] = a("DIRECT"), [z, At] = a(""), [B, jt] = a(""), [V, Mt] = a(""), [H, Nt] = a(""), [Pt, Ft] = a(22), [U, It] = a(""), [W, Lt] = a("key"), [Rt, zt] = a(""), [Bt, Vt] = a(""), [Ht, Ut] = a(""), [G, Wt] = a(""), { data: Gt, loading: K, refetch: q } = te({
62
+ }, [d]), [D, ft] = o(null), [O, pt] = o(null), [mt, ht] = o(null), [k, A] = o(null), [j, gt] = o(!1), [_t, M] = o(null), [N, vt] = o(""), [yt, bt] = o(""), [xt, St] = o(""), [Ct, wt] = o(22), [Tt, Et] = o(""), [P, Dt] = o("key"), [F, Ot] = o(""), [I, kt] = o(""), [L, At] = o(""), [R, jt] = o("DIRECT"), [z, Mt] = o(""), [B, Nt] = o(""), [V, Pt] = o(""), [H, Ft] = o(""), [It, Lt] = o(22), [U, Rt] = o(""), [W, zt] = o("key"), [Bt, Vt] = o(""), [Ht, Ut] = o(""), [Wt, Gt] = o(""), [G, Kt] = o(""), { data: qt, loading: K, refetch: q } = te({
61
63
  variables: {
62
- workspaceId: d || "",
64
+ workspaceId: f || "",
63
65
  limit: 50,
64
66
  offset: 0
65
67
  },
66
- skip: !d,
68
+ skip: !f,
67
69
  fetchPolicy: "cache-first"
68
- }), { agents: Kt, refetch: qt } = ce(), [Jt] = e({
70
+ }), { agents: Jt, refetch: Yt } = ce(), [Xt] = e({
69
71
  refetchQueries: ["VibeControlsInitialData", "ListTargets"],
70
72
  awaitRefetchQueries: !0
71
- }), [Yt] = ae(), [Xt] = re(), [Zt] = ne(), [J] = t(), [Qt] = ee(), [$t] = ie(), [en] = n({ fetchPolicy: "network-only" }), Y = i(() => (Gt?.targets?.items ?? []).map((e) => ({
73
+ }), { setDraftTagIds: Zt, flushTags: Qt } = me("VIBECONTROLS_TARGET"), [$t] = ae(), [en] = re(), [tn] = ne(), [J] = t(), [nn] = ee(), [rn] = ie(), [an] = n({ fetchPolicy: "network-only" }), Y = a(() => (qt?.targets?.items ?? []).map((e) => ({
72
74
  id: e.id,
73
75
  type: e.type || "DIRECT",
74
76
  name: e.name,
@@ -76,7 +78,7 @@ function u() {
76
78
  host: e.host || null,
77
79
  port: e.port || null,
78
80
  username: e.username || null,
79
- status: Ge(e.status),
81
+ status: Ke(e.status),
80
82
  connectionId: e.connectionId || null,
81
83
  tags: e.tags,
82
84
  metadata: e.metadata ?? null,
@@ -87,47 +89,47 @@ function u() {
87
89
  version: e.version,
88
90
  isActive: e.isActive
89
91
  }))
90
- })), [Gt]), X = i(() => Kt.map((e) => ({
92
+ })), [qt]), X = a(() => Jt.map((e) => ({
91
93
  id: e.id,
92
94
  name: e.name,
93
95
  isActive: e.isActive,
94
96
  tunnelUrl: e.tunnelUrl ?? null,
95
97
  agentApiKey: null
96
- })), [Kt]), Z = i(() => {
98
+ })), [Jt]), Z = a(() => {
97
99
  let e = Y;
98
- if (m) {
99
- let t = m.toLowerCase();
100
+ if (h) {
101
+ let t = h.toLowerCase();
100
102
  e = e.filter((e) => e.name.toLowerCase().includes(t) || e.host?.toLowerCase().includes(t) || e.label?.toLowerCase().includes(t));
101
103
  }
102
- return h && (e = e.filter((e) => e.agents.some((e) => e.id === h))), g !== "all" && (e = e.filter((e) => e.type === g)), _ !== "all" && (e = e.filter((e) => e.status === _)), e;
104
+ return g && (e = e.filter((e) => e.agents.some((e) => e.id === g))), _ !== "all" && (e = e.filter((e) => e.type === _)), v !== "all" && (e = e.filter((e) => e.status === v)), e;
103
105
  }, [
104
106
  Y,
105
- m,
106
107
  h,
107
108
  g,
108
- _
109
+ _,
110
+ v
109
111
  ]);
110
- we(() => {
111
- if (!p || !Z.find((e) => e.id === p)) return;
112
+ Te(() => {
113
+ if (!m || !Z.find((e) => e.id === m)) return;
112
114
  let e = window.setTimeout(() => {
113
- document.getElementById(`target-row-${p}`)?.scrollIntoView({
115
+ document.getElementById(`target-row-${m}`)?.scrollIntoView({
114
116
  behavior: "smooth",
115
117
  block: "center"
116
118
  });
117
119
  }, 150);
118
120
  return () => window.clearTimeout(e);
119
- }, [Z, p]);
120
- let tn = Y.filter((e) => e.status === "connected").length, Q = Z.length > 0 && Z.every((e) => x.has(e.id)), nn = x.size > 0;
121
- we(() => {
122
- if (!pt || !E) return;
121
+ }, [Z, m]);
122
+ let on = Y.filter((e) => e.status === "connected").length, Q = Z.length > 0 && Z.every((e) => S.has(e.id)), sn = S.size > 0;
123
+ Te(() => {
124
+ if (!mt || !D) return;
123
125
  let e = !1, t = () => {
124
- en({ variables: {
125
- targetId: E.id,
126
- jobId: pt
126
+ an({ variables: {
127
+ targetId: D.id,
128
+ jobId: mt
127
129
  } }).then((t) => {
128
130
  if (e) return;
129
131
  let n = t.data?.installAgentJobStatus;
130
- n && (n.steps ||= [], ft({
132
+ n && (n.steps ||= [], pt({
131
133
  id: n.jobId,
132
134
  status: n.status,
133
135
  currentStep: n.currentStep ?? 0,
@@ -143,32 +145,33 @@ function u() {
143
145
  e = !0, clearInterval(n);
144
146
  };
145
147
  }, [
146
- pt,
147
- E,
148
- en,
148
+ mt,
149
+ D,
150
+ an,
149
151
  q
150
152
  ]);
151
- let rn = r(async () => {
152
- if (!(!z || !d) && !(R !== "DIRECT" && (!V || !H || !U))) try {
153
- await Jt({ variables: {
154
- workspaceId: d,
153
+ let cn = i(async () => {
154
+ if (!(!z || !f) && !(R !== "DIRECT" && (!V || !H || !U))) try {
155
+ let e = (await Xt({ variables: {
156
+ workspaceId: f,
155
157
  input: {
156
158
  type: R,
157
159
  name: z,
158
160
  sourceAgentId: R === "DIRECT" ? void 0 : V,
159
161
  host: R === "DIRECT" ? void 0 : H,
160
- port: R === "DIRECT" ? void 0 : Pt,
162
+ port: R === "DIRECT" ? void 0 : It,
161
163
  username: R === "DIRECT" ? void 0 : U,
162
- password: R === "SSH" && W === "password" ? Rt : void 0,
163
- privateKeyPath: R === "SSH" && W === "key" ? Bt : void 0,
164
- label: Ht || void 0,
164
+ password: R === "SSH" && W === "password" ? Bt : void 0,
165
+ privateKeyPath: R === "SSH" && W === "key" ? Ht : void 0,
166
+ label: Wt || void 0,
165
167
  tags: G ? G.split(",").map((e) => e.trim()) : void 0,
166
168
  metadata: B ? { description: B } : void 0
167
169
  }
168
- } }), v(!1), At(""), Nt(""), It(""), zt(""), Vt(""), Ut(""), Wt(""), q(), qt();
170
+ } })).data?.createTarget?.id;
171
+ e && await Qt(e), y(!1), Mt(""), Ft(""), Rt(""), Vt(""), Ut(""), Gt(""), Kt(""), q(), Yt();
169
172
  } catch (e) {
170
- if (pe(e)) {
171
- v(!1), w(!0);
173
+ if (fe(e)) {
174
+ y(!1), T(!0);
172
175
  return;
173
176
  }
174
177
  throw e;
@@ -177,93 +180,94 @@ function u() {
177
180
  z,
178
181
  V,
179
182
  H,
180
- Pt,
183
+ It,
181
184
  U,
182
185
  W,
183
- Rt,
184
186
  Bt,
185
187
  Ht,
188
+ Wt,
186
189
  G,
187
190
  B,
188
191
  R,
189
- d,
190
- Jt,
192
+ f,
193
+ Xt,
194
+ Qt,
191
195
  q
192
- ]), an = r(async (e) => {
193
- let t = (await Xt({ variables: { id: e } })).data?.testTarget;
194
- t && (lt({
196
+ ]), ln = i(async (e) => {
197
+ let t = (await en({ variables: { id: e } })).data?.testTarget;
198
+ t && (ut({
195
199
  id: e,
196
200
  success: t.success,
197
201
  message: t.message || ""
198
- }), setTimeout(() => lt(null), 5e3), q());
199
- }, [Xt, q]), on = r(async (e) => {
202
+ }), setTimeout(() => ut(null), 5e3), q());
203
+ }, [en, q]), un = i(async (e) => {
200
204
  try {
201
- let t = await Zt({ variables: { targetId: e } });
202
- if (t.error && pe(t.error)) {
203
- w(!0);
205
+ let t = await tn({ variables: { targetId: e } });
206
+ if (t.error && fe(t.error)) {
207
+ T(!0);
204
208
  return;
205
209
  }
206
210
  let n = t.data?.startTerminal;
207
- n?.sessionId && f(`/sessions/${n.sessionId}`);
211
+ n?.sessionId && p(`/sessions/${n.sessionId}`);
208
212
  } catch (e) {
209
- if (pe(e)) {
210
- w(!0);
213
+ if (fe(e)) {
214
+ T(!0);
211
215
  return;
212
216
  }
213
217
  throw e;
214
218
  }
215
- }, [Zt, f]), sn = r(async () => {
216
- if (y) {
219
+ }, [tn, p]), dn = i(async () => {
220
+ if (b) {
217
221
  try {
218
- await J({ variables: { id: y } }), me() && he("success");
222
+ await J({ variables: { id: b } }), he() && ge("success");
219
223
  } catch (e) {
220
- throw me() && he("error"), e;
224
+ throw he() && ge("error"), e;
221
225
  }
222
- b(null), S((e) => {
226
+ x(null), C((e) => {
223
227
  let t = new Set(e);
224
- return t.delete(y), t;
228
+ return t.delete(b), t;
225
229
  }), q();
226
230
  }
227
231
  }, [
228
- y,
232
+ b,
229
233
  J,
230
234
  q
231
- ]), cn = r(async () => {
232
- let e = Array.from(x);
233
- await Promise.all(e.map((e) => J({ variables: { id: e } }))), S(/* @__PURE__ */ new Set()), ct(!1), q();
235
+ ]), fn = i(async () => {
236
+ let e = Array.from(S);
237
+ await Promise.all(e.map((e) => J({ variables: { id: e } }))), C(/* @__PURE__ */ new Set()), lt(!1), q();
234
238
  }, [
235
- x,
239
+ S,
236
240
  J,
237
241
  q
238
- ]), ln = r(async (e) => {
239
- dt(e), ft(null), O(null);
242
+ ]), pn = i(async (e) => {
243
+ ft(e), pt(null), ht(null);
240
244
  let t = X.find((e) => e.isActive);
241
245
  if (!t) return;
242
- let n = (await Qt({ variables: {
246
+ let n = (await nn({ variables: {
243
247
  targetId: e.id,
244
248
  sourceAgentId: t.id
245
249
  } })).data?.installAgentOnTarget;
246
- n?.jobId && O(n.jobId);
247
- }, [Qt, X]), un = r(async (e) => {
248
- await $t({ variables: { targetId: e.id } }), q();
249
- }, [$t, q]), dn = r((e) => {
250
- A(e), gt(e.name), vt(e.label ?? ""), bt(e.host ?? ""), St(e.port ?? 22), wt(e.username ?? ""), Tt("key"), Et(""), Dt(""), Ot(e.tags.join(", ")), M(null);
251
- }, []), fn = r(async () => {
250
+ n?.jobId && ht(n.jobId);
251
+ }, [nn, X]), mn = i(async (e) => {
252
+ await rn({ variables: { targetId: e.id } }), q();
253
+ }, [rn, q]), hn = i((e) => {
254
+ A(e), vt(e.name), bt(e.label ?? ""), St(e.host ?? ""), wt(e.port ?? 22), Et(e.username ?? ""), Dt("key"), Ot(""), kt(""), At(e.tags.join(", ")), M(null);
255
+ }, []), gn = i(async () => {
252
256
  if (k) {
253
257
  if (!N.trim()) {
254
258
  M("Name is required");
255
259
  return;
256
260
  }
257
- mt(!0), M(null);
261
+ gt(!0), M(null);
258
262
  try {
259
- await Yt({ variables: {
263
+ await $t({ variables: {
260
264
  id: k.id,
261
265
  input: {
262
266
  name: N.trim(),
263
- label: _t.trim() || null,
264
- host: yt.trim() || void 0,
265
- port: xt || void 0,
266
- username: Ct.trim() || void 0,
267
+ label: yt.trim() || null,
268
+ host: xt.trim() || void 0,
269
+ port: Ct || void 0,
270
+ username: Tt.trim() || void 0,
267
271
  password: k.type === "SSH" && P === "password" && F ? F : void 0,
268
272
  privateKeyPath: k.type === "SSH" && P === "key" && I ? I : void 0,
269
273
  tags: L ? L.split(",").map((e) => e.trim()).filter(Boolean) : []
@@ -272,162 +276,162 @@ function u() {
272
276
  } catch (e) {
273
277
  M(e instanceof Error ? e.message : "Failed to update target");
274
278
  } finally {
275
- mt(!1);
279
+ gt(!1);
276
280
  }
277
281
  }
278
282
  }, [
279
283
  k,
280
284
  N,
281
- _t,
282
285
  yt,
283
286
  xt,
284
287
  Ct,
288
+ Tt,
285
289
  P,
286
290
  F,
287
291
  I,
288
292
  L,
289
- Yt,
293
+ $t,
290
294
  q
291
- ]), pn = r(() => {
292
- dt(null), ft(null), O(null);
293
- }, []), mn = r(() => {
294
- S(Q ? (e) => {
295
+ ]), _n = i(() => {
296
+ ft(null), pt(null), ht(null);
297
+ }, []), vn = i(() => {
298
+ C(Q ? (e) => {
295
299
  let t = new Set(e);
296
300
  return Z.forEach((e) => t.delete(e.id)), t;
297
301
  } : (e) => {
298
302
  let t = new Set(e);
299
303
  return Z.forEach((e) => t.add(e.id)), t;
300
304
  });
301
- }, [Q, Z]), hn = r((e) => {
302
- S((t) => {
305
+ }, [Q, Z]), yn = i((e) => {
306
+ C((t) => {
303
307
  let n = new Set(t);
304
308
  return n.has(e) ? n.delete(e) : n.add(e), n;
305
309
  });
306
- }, []), gn = {
310
+ }, []), bn = {
307
311
  total: Y.length,
308
- connected: tn
309
- }, _n = i(() => [
312
+ connected: on
313
+ }, xn = a(() => [
310
314
  {
311
315
  value: "all",
312
- label: T("targets.filterTypeAll", "All Types")
316
+ label: E("targets.filterTypeAll", "All Types")
313
317
  },
314
318
  {
315
319
  value: "DIRECT",
316
- label: T("targets.typeDirect", "Direct")
320
+ label: E("targets.typeDirect", "Direct")
317
321
  },
318
322
  {
319
323
  value: "SSH",
320
324
  label: "SSH"
321
325
  }
322
- ], [T]), vn = i(() => [
326
+ ], [E]), Sn = a(() => [
323
327
  {
324
328
  value: "all",
325
- label: T("targets.filterStatusAll", "All Statuses")
329
+ label: E("targets.filterStatusAll", "All Statuses")
326
330
  },
327
331
  {
328
332
  value: "connected",
329
- label: T("targets.connected", "Connected")
333
+ label: E("targets.connected", "Connected")
330
334
  },
331
335
  {
332
336
  value: "disconnected",
333
- label: T("targets.disconnected", "Disconnected")
337
+ label: E("targets.disconnected", "Disconnected")
334
338
  },
335
339
  {
336
340
  value: "unknown",
337
- label: T("targets.unknown", "Unknown")
341
+ label: E("targets.unknown", "Unknown")
338
342
  }
339
- ], [T]), $ = m || h || g !== "all" || _ !== "all";
340
- return Qe ? /* @__PURE__ */ c("div", {
343
+ ], [E]), $ = h || g || _ !== "all" || v !== "all";
344
+ return $e ? /* @__PURE__ */ l("div", {
341
345
  className: "flex items-center justify-center min-h-[400px]",
342
- children: /* @__PURE__ */ c("p", {
346
+ children: /* @__PURE__ */ l("p", {
343
347
  className: "text-text-secondary",
344
348
  children: "Loading permissions..."
345
349
  })
346
- }) : Ze(Se.TARGET_LIST) ? K && Y.length === 0 ? /* @__PURE__ */ l(We, {
350
+ }) : Qe(Ce.TARGET_LIST) ? K && Y.length === 0 ? /* @__PURE__ */ u(Ge, {
347
351
  className: "space-y-6 p-4 sm:p-6 bg-bg-surface min-h-screen",
348
- children: [/* @__PURE__ */ c(le, {
349
- title: T("nav.targets", "Targets"),
350
- description: T("targets.description", "Manage your servers, workstations, and environments.")
351
- }), /* @__PURE__ */ c(ue, { message: T("targets.loading", "Loading targets...") })]
352
- }) : /* @__PURE__ */ l(We, {
352
+ children: [/* @__PURE__ */ l(le, {
353
+ title: E("nav.targets", "Targets"),
354
+ description: E("targets.description", "Manage your servers, workstations, and environments.")
355
+ }), /* @__PURE__ */ l(ue, { message: E("targets.loading", "Loading targets...") })]
356
+ }) : /* @__PURE__ */ u(Ge, {
353
357
  className: "space-y-6 p-4 sm:p-6 bg-bg-surface min-h-screen",
354
358
  children: [
355
- C && /* @__PURE__ */ l("div", {
356
- className: `fixed top-4 right-4 z-[10000] rounded-md px-4 py-3 shadow-lg text-sm ${C.success ? "bg-status-success-bg text-status-success-text" : "bg-status-error-bg text-status-error-text"}`,
359
+ w && /* @__PURE__ */ u("div", {
360
+ className: `fixed top-4 right-4 z-[10000] rounded-md px-4 py-3 shadow-lg text-sm ${w.success ? "bg-status-success-bg text-status-success-text" : "bg-status-error-bg text-status-error-text"}`,
357
361
  children: [
358
- C.success ? T("targets.connectionSuccessful", "Connection successful") : T("targets.connectionFailed", "Connection failed"),
362
+ w.success ? E("targets.connectionSuccessful", "Connection successful") : E("targets.connectionFailed", "Connection failed"),
359
363
  ": ",
360
- C.message
364
+ w.message
361
365
  ]
362
366
  }),
363
- /* @__PURE__ */ c(le, {
364
- title: T("nav.targets", "Targets"),
365
- description: `${gn.connected} of ${gn.total} targets online`,
366
- actions: /* @__PURE__ */ l("div", {
367
+ /* @__PURE__ */ l(le, {
368
+ title: E("nav.targets", "Targets"),
369
+ description: `${bn.connected} of ${bn.total} targets online`,
370
+ actions: /* @__PURE__ */ u("div", {
367
371
  className: "flex flex-col sm:flex-row items-stretch sm:items-center gap-2",
368
- children: [/* @__PURE__ */ c("button", {
372
+ children: [/* @__PURE__ */ l("button", {
369
373
  onClick: () => void q(),
370
374
  disabled: K,
371
375
  className: "flex items-center justify-center gap-2 px-3 py-2 text-text-secondary hover:bg-bg-sunken rounded-md transition-colors disabled:opacity-50",
372
- title: T("targets.refreshTitle", "Refresh targets"),
373
- children: /* @__PURE__ */ c(Pe, { className: `w-4 h-4 ${K ? "animate-spin" : ""}` })
374
- }), /* @__PURE__ */ l("button", {
375
- onClick: () => v(!0),
376
+ title: E("targets.refreshTitle", "Refresh targets"),
377
+ children: /* @__PURE__ */ l(Fe, { className: `w-4 h-4 ${K ? "animate-spin" : ""}` })
378
+ }), /* @__PURE__ */ u("button", {
379
+ onClick: () => y(!0),
376
380
  className: "flex items-center gap-2 px-4 py-2 bg-action-primary-bg text-action-primary-text rounded-md hover:bg-action-primary-bg-hover transition-colors",
377
- children: [/* @__PURE__ */ c(Ne, { className: "w-4 h-4" }), T("targets.addTarget", "Add Target")]
381
+ children: [/* @__PURE__ */ l(Pe, { className: "w-4 h-4" }), E("targets.addTarget", "Add Target")]
378
382
  })]
379
383
  })
380
384
  }),
381
- X.length === 0 && !K && /* @__PURE__ */ c(ye, {
385
+ X.length === 0 && !K && /* @__PURE__ */ l(be, {
382
386
  variant: "full",
383
387
  dismissKey: "vibecontrols-targets-setup-banner"
384
388
  }),
385
- /* @__PURE__ */ l("div", {
389
+ /* @__PURE__ */ u("div", {
386
390
  className: "space-y-3",
387
- children: [/* @__PURE__ */ l("div", {
391
+ children: [/* @__PURE__ */ u("div", {
388
392
  className: "flex items-center gap-2",
389
- children: [/* @__PURE__ */ c(_e, {
390
- value: m,
391
- onChange: et,
392
- placeholder: T("targets.searchPlaceholder", "Search targets..."),
393
+ children: [/* @__PURE__ */ l(ve, {
394
+ value: h,
395
+ onChange: tt,
396
+ placeholder: E("targets.searchPlaceholder", "Search targets..."),
393
397
  className: "flex-1 sm:w-64 sm:flex-none"
394
- }), /* @__PURE__ */ l("div", {
398
+ }), /* @__PURE__ */ u("div", {
395
399
  className: "flex items-center gap-1 bg-bg-sunken rounded-md p-1 flex-shrink-0",
396
- children: [/* @__PURE__ */ c("button", {
397
- onClick: () => at("grid"),
398
- className: `p-1.5 sm:p-2 rounded ${it === "grid" ? "bg-bg-surface shadow-sm" : "hover:bg-bg-surface/50"}`,
399
- title: T("targets.gridViewTitle", "Grid view"),
400
- children: /* @__PURE__ */ c(ke, { className: "w-4 h-4 text-text-secondary" })
401
- }), /* @__PURE__ */ c("button", {
402
- onClick: () => at("list"),
403
- className: `p-1.5 sm:p-2 rounded ${it === "list" ? "bg-bg-surface shadow-sm" : "hover:bg-bg-surface/50"}`,
404
- title: T("targets.listViewTitle", "List view"),
405
- children: /* @__PURE__ */ c(Ae, { className: "w-4 h-4 text-text-secondary" })
400
+ children: [/* @__PURE__ */ l("button", {
401
+ onClick: () => ot("grid"),
402
+ className: `p-1.5 sm:p-2 rounded ${at === "grid" ? "bg-bg-surface shadow-sm" : "hover:bg-bg-surface/50"}`,
403
+ title: E("targets.gridViewTitle", "Grid view"),
404
+ children: /* @__PURE__ */ l(Ae, { className: "w-4 h-4 text-text-secondary" })
405
+ }), /* @__PURE__ */ l("button", {
406
+ onClick: () => ot("list"),
407
+ className: `p-1.5 sm:p-2 rounded ${at === "list" ? "bg-bg-surface shadow-sm" : "hover:bg-bg-surface/50"}`,
408
+ title: E("targets.listViewTitle", "List view"),
409
+ children: /* @__PURE__ */ l(je, { className: "w-4 h-4 text-text-secondary" })
406
410
  })]
407
411
  })]
408
- }), /* @__PURE__ */ l("div", {
412
+ }), /* @__PURE__ */ u("div", {
409
413
  className: "flex items-center gap-2 sm:gap-3 flex-wrap",
410
414
  children: [
411
- /* @__PURE__ */ c(ve, {
412
- label: T("sessions.filterType", "Type"),
413
- value: g,
414
- options: _n,
415
- onChange: nt
416
- }),
417
- /* @__PURE__ */ c(ve, {
418
- label: T("sessions.filterStatus", "Status"),
415
+ /* @__PURE__ */ l(ye, {
416
+ label: E("sessions.filterType", "Type"),
419
417
  value: _,
420
- options: vn,
418
+ options: xn,
421
419
  onChange: rt
422
420
  }),
423
- /* @__PURE__ */ c(xe, {
424
- value: h ?? "",
425
- onChange: (e) => tt(e || null),
421
+ /* @__PURE__ */ l(ye, {
422
+ label: E("sessions.filterStatus", "Status"),
423
+ value: v,
424
+ options: Sn,
425
+ onChange: it
426
+ }),
427
+ /* @__PURE__ */ l(Se, {
428
+ value: g ?? "",
429
+ onChange: (e) => nt(e || null),
426
430
  options: X.map((e) => ({
427
431
  value: e.id,
428
432
  label: e.name
429
433
  })),
430
- placeholder: T("targets.allAgents", "All agents"),
434
+ placeholder: E("targets.allAgents", "All agents"),
431
435
  className: "w-full sm:min-w-[180px] sm:w-auto",
432
436
  dropdownAlign: "left",
433
437
  clearable: !0
@@ -435,148 +439,148 @@ function u() {
435
439
  ]
436
440
  })]
437
441
  }),
438
- Z.length > 0 && /* @__PURE__ */ c("div", {
442
+ Z.length > 0 && /* @__PURE__ */ l("div", {
439
443
  className: "flex items-center gap-2 flex-wrap",
440
- children: /* @__PURE__ */ c("div", {
444
+ children: /* @__PURE__ */ l("div", {
441
445
  className: "ml-auto flex items-center gap-2",
442
- children: /* @__PURE__ */ l("button", {
443
- onClick: mn,
446
+ children: /* @__PURE__ */ u("button", {
447
+ onClick: vn,
444
448
  className: "flex items-center gap-1.5 px-3 py-1.5 text-xs text-text-secondary hover:text-text-primary transition-colors",
445
- children: [/* @__PURE__ */ c(Oe, { className: "w-3.5 h-3.5" }), Q ? T("targets.deselectAll", "Deselect All") : T("targets.selectAll", "Select All")]
449
+ children: [/* @__PURE__ */ l(ke, { className: "w-3.5 h-3.5" }), Q ? E("targets.deselectAll", "Deselect All") : E("targets.selectAll", "Select All")]
446
450
  })
447
451
  })
448
452
  }),
449
- nn && /* @__PURE__ */ l("div", {
453
+ sn && /* @__PURE__ */ u("div", {
450
454
  className: "flex flex-col sm:flex-row items-start sm:items-center gap-3 px-4 py-2 bg-action-primary-bg/10 border border-action-primary-bg/20 rounded-lg",
451
- children: [/* @__PURE__ */ l("span", {
455
+ children: [/* @__PURE__ */ u("span", {
452
456
  className: "text-sm font-medium text-text-primary",
453
457
  children: [
454
- x.size,
458
+ S.size,
455
459
  " ",
456
- T("nav.targets", "target"),
457
- x.size === 1 ? "" : "s",
460
+ E("nav.targets", "target"),
461
+ S.size === 1 ? "" : "s",
458
462
  " ",
459
- T("sessions.selected", "selected")
463
+ E("sessions.selected", "selected")
460
464
  ]
461
- }), /* @__PURE__ */ l("div", {
465
+ }), /* @__PURE__ */ u("div", {
462
466
  className: "flex items-center gap-1.5 sm:ml-auto",
463
- children: [/* @__PURE__ */ l("button", {
464
- onClick: () => ct(!0),
467
+ children: [/* @__PURE__ */ u("button", {
468
+ onClick: () => lt(!0),
465
469
  className: "flex items-center gap-1.5 px-3 py-1.5 text-xs font-medium text-status-error-text bg-status-error-bg border border-status-error-text/20 rounded-md hover:bg-status-error-bg/80 transition-colors",
466
470
  children: [
467
- /* @__PURE__ */ c(Ie, { className: "w-3 h-3" }),
471
+ /* @__PURE__ */ l(Le, { className: "w-3 h-3" }),
468
472
  " ",
469
- T("common.delete", "Delete")
473
+ E("common.delete", "Delete")
470
474
  ]
471
- }), /* @__PURE__ */ l("button", {
472
- onClick: () => S(/* @__PURE__ */ new Set()),
475
+ }), /* @__PURE__ */ u("button", {
476
+ onClick: () => C(/* @__PURE__ */ new Set()),
473
477
  className: "flex items-center gap-1.5 px-3 py-1.5 text-xs text-text-secondary hover:text-text-primary transition-colors",
474
478
  children: [
475
- /* @__PURE__ */ c(Re, { className: "w-3 h-3" }),
479
+ /* @__PURE__ */ l(ze, { className: "w-3 h-3" }),
476
480
  " ",
477
- T("sessions.deselect", "Deselect")
481
+ E("sessions.deselect", "Deselect")
478
482
  ]
479
483
  })]
480
484
  })]
481
485
  }),
482
- $ ? /* @__PURE__ */ l("p", {
486
+ $ ? /* @__PURE__ */ u("p", {
483
487
  className: "text-sm text-text-secondary",
484
- children: [T("targets.showingResults", "Showing {{filtered}} of {{total}} targets").replace("{{filtered}}", String(Z.length)).replace("{{total}}", String(Y.length)), K && /* @__PURE__ */ l("span", {
488
+ children: [E("targets.showingResults", "Showing {{filtered}} of {{total}} targets").replace("{{filtered}}", String(Z.length)).replace("{{total}}", String(Y.length)), K && /* @__PURE__ */ u("span", {
485
489
  className: "ml-2 text-text-muted",
486
490
  children: [
487
491
  "(",
488
- T("sessions.refreshing", "refreshing..."),
492
+ E("sessions.refreshing", "refreshing..."),
489
493
  ")"
490
494
  ]
491
495
  })]
492
496
  }) : null,
493
- Z.length > 0 ? /* @__PURE__ */ c(Ve, {
497
+ Z.length > 0 ? /* @__PURE__ */ l(He, {
494
498
  mode: "wait",
495
- children: it === "grid" ? /* @__PURE__ */ c(Ue, {
499
+ children: at === "grid" ? /* @__PURE__ */ l(We, {
496
500
  stagger: .04,
497
501
  className: "grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-4",
498
- children: Z.map((e) => /* @__PURE__ */ c(He, { children: /* @__PURE__ */ c(Ce, {
502
+ children: Z.map((e) => /* @__PURE__ */ l(Ue, { children: /* @__PURE__ */ l(we, {
499
503
  target: e,
500
- onTest: (e) => void an(e),
501
- onTerminal: (e) => void on(e),
502
- onOpenDetail: (e) => f(`/targets/${e}`),
503
- onEdit: (e) => dn(e),
504
- onInstallAgent: (e) => void ln(e),
505
- onUninstallAgent: (e) => void un(e),
506
- onDelete: (e) => b(e),
507
- selected: x.has(e.id),
508
- onToggleSelect: () => hn(e.id),
509
- highlighted: p === e.id
504
+ onTest: (e) => void ln(e),
505
+ onTerminal: (e) => void un(e),
506
+ onOpenDetail: (e) => p(`/targets/${e}`),
507
+ onEdit: (e) => hn(e),
508
+ onInstallAgent: (e) => void pn(e),
509
+ onUninstallAgent: (e) => void mn(e),
510
+ onDelete: (e) => x(e),
511
+ selected: S.has(e.id),
512
+ onToggleSelect: () => yn(e.id),
513
+ highlighted: m === e.id
510
514
  }) }, e.id))
511
- }, "grid-view") : /* @__PURE__ */ c(Ue, {
515
+ }, "grid-view") : /* @__PURE__ */ l(We, {
512
516
  stagger: .04,
513
517
  className: "space-y-2",
514
518
  children: Z.map((e) => {
515
- let t = Xe(e), n = p === e.id;
516
- return /* @__PURE__ */ c(He, {
519
+ let t = Ze(e), n = m === e.id;
520
+ return /* @__PURE__ */ l(Ue, {
517
521
  variant: "fadeRight",
518
- children: /* @__PURE__ */ l("div", {
522
+ children: /* @__PURE__ */ u("div", {
519
523
  id: `target-row-${e.id}`,
520
524
  className: `p-4 rounded-lg border transition-colors ${n ? "border-action-primary-bg bg-action-primary-bg/5 shadow-sm" : "border-border-default hover:bg-bg-sunken/30"}`,
521
- children: [/* @__PURE__ */ l("div", {
525
+ children: [/* @__PURE__ */ u("div", {
522
526
  className: "flex items-start gap-3",
523
- children: [/* @__PURE__ */ c("input", {
527
+ children: [/* @__PURE__ */ l("input", {
524
528
  type: "checkbox",
525
- checked: x.has(e.id),
526
- onChange: () => hn(e.id),
529
+ checked: S.has(e.id),
530
+ onChange: () => yn(e.id),
527
531
  className: "rounded border-border-default mt-1"
528
- }), /* @__PURE__ */ l("div", {
532
+ }), /* @__PURE__ */ u("div", {
529
533
  className: "flex min-w-0 flex-1 flex-wrap items-start gap-2",
530
534
  children: [
531
- /* @__PURE__ */ c("span", {
532
- className: `inline-flex items-center px-2 py-0.5 text-xs font-semibold rounded ${Je[e.type]}`,
535
+ /* @__PURE__ */ l("span", {
536
+ className: `inline-flex items-center px-2 py-0.5 text-xs font-semibold rounded ${Ye[e.type]}`,
533
537
  children: e.type
534
538
  }),
535
- /* @__PURE__ */ c("span", {
536
- className: `inline-flex items-center px-2 py-0.5 text-xs font-semibold rounded ${Ye[e.status]}`,
537
- children: T(`targets.status.${e.status}`, qe[e.status].label)
539
+ /* @__PURE__ */ l("span", {
540
+ className: `inline-flex items-center px-2 py-0.5 text-xs font-semibold rounded ${Xe[e.status]}`,
541
+ children: E(`targets.status.${e.status}`, Je[e.status].label)
538
542
  }),
539
- /* @__PURE__ */ l("div", {
543
+ /* @__PURE__ */ u("div", {
540
544
  className: "min-w-0 basis-full",
541
545
  children: [
542
- /* @__PURE__ */ l("div", {
546
+ /* @__PURE__ */ u("div", {
543
547
  className: "flex items-center gap-2 flex-wrap",
544
548
  children: [
545
- /* @__PURE__ */ c("span", {
549
+ /* @__PURE__ */ l("span", {
546
550
  className: "font-medium",
547
551
  children: e.name
548
552
  }),
549
- e.label && /* @__PURE__ */ c("span", {
553
+ e.label && /* @__PURE__ */ l("span", {
550
554
  className: "text-text-secondary text-sm",
551
555
  children: e.label
552
556
  }),
553
- t && /* @__PURE__ */ l("span", {
557
+ t && /* @__PURE__ */ u("span", {
554
558
  className: "inline-flex items-center gap-1 rounded-full border border-status-success-border px-2 py-0.5 text-xs bg-status-success-bg-subtle text-status-success-text",
555
- children: [/* @__PURE__ */ c(De, { size: 10 }), T("targets.agentInstalled", "Agent Installed")]
559
+ children: [/* @__PURE__ */ l(Oe, { size: 10 }), E("targets.agentInstalled", "Agent Installed")]
556
560
  })
557
561
  ]
558
562
  }),
559
- /* @__PURE__ */ l("div", {
563
+ /* @__PURE__ */ u("div", {
560
564
  className: "mt-1 flex flex-wrap items-center gap-2 text-sm text-text-secondary sm:gap-3",
561
- children: [e.host && /* @__PURE__ */ l("code", {
565
+ children: [e.host && /* @__PURE__ */ u("code", {
562
566
  className: "text-xs",
563
567
  children: [
564
568
  e.username ? `${e.username}@` : "",
565
569
  e.host,
566
570
  e.port ? `:${e.port}` : ""
567
571
  ]
568
- }), e.agents.length > 0 && /* @__PURE__ */ l("span", {
572
+ }), e.agents.length > 0 && /* @__PURE__ */ u("span", {
569
573
  className: "text-text-tertiary",
570
574
  children: [
571
- T("targets.via", "via"),
575
+ E("targets.via", "via"),
572
576
  " ",
573
577
  e.agents[0].name
574
578
  ]
575
579
  })]
576
580
  }),
577
- e.tags.length > 0 && /* @__PURE__ */ c("div", {
581
+ e.tags.length > 0 && /* @__PURE__ */ l("div", {
578
582
  className: "mt-1.5 flex flex-wrap gap-1",
579
- children: e.tags.map((e) => /* @__PURE__ */ c("span", {
583
+ children: e.tags.map((e) => /* @__PURE__ */ l("span", {
580
584
  className: "px-1.5 py-0.5 text-xs bg-bg-sunken text-text-secondary rounded",
581
585
  children: e
582
586
  }, e))
@@ -585,45 +589,45 @@ function u() {
585
589
  })
586
590
  ]
587
591
  })]
588
- }), /* @__PURE__ */ l("div", {
592
+ }), /* @__PURE__ */ u("div", {
589
593
  className: "mt-3 flex flex-wrap items-center gap-2 pl-0 sm:pl-7",
590
594
  children: [
591
- /* @__PURE__ */ c("button", {
592
- onClick: () => void an(e.id),
593
- title: T("targets.testConnectivity", "Test connectivity"),
595
+ /* @__PURE__ */ l("button", {
596
+ onClick: () => void ln(e.id),
597
+ title: E("targets.testConnectivity", "Test connectivity"),
594
598
  className: "flex items-center gap-1.5 px-3 py-1.5 text-xs font-medium rounded-md border border-border-default bg-bg-surface hover:bg-bg-sunken transition-colors",
595
- children: T("targets.test", "Test")
599
+ children: E("targets.test", "Test")
596
600
  }),
597
- /* @__PURE__ */ c("button", {
598
- onClick: () => void on(e.id),
599
- title: T("targets.openTerminal", "Open terminal"),
601
+ /* @__PURE__ */ l("button", {
602
+ onClick: () => void un(e.id),
603
+ title: E("targets.openTerminal", "Open terminal"),
600
604
  className: "flex items-center gap-1.5 px-3 py-1.5 text-xs font-medium rounded-md border border-border-default bg-bg-surface hover:bg-bg-sunken transition-colors",
601
- children: T("targets.terminal", "Terminal")
605
+ children: E("targets.terminal", "Terminal")
602
606
  }),
603
- /* @__PURE__ */ l("button", {
604
- onClick: () => dn(e),
607
+ /* @__PURE__ */ u("button", {
608
+ onClick: () => hn(e),
605
609
  title: "Edit target configuration",
606
610
  className: "flex items-center gap-1.5 px-3 py-1.5 text-xs font-medium rounded-md border border-border-default bg-bg-surface hover:bg-bg-sunken transition-colors",
607
- children: [/* @__PURE__ */ c(Me, { size: 14 }), "Edit"]
611
+ children: [/* @__PURE__ */ l(Ne, { size: 14 }), "Edit"]
608
612
  }),
609
- e.type !== "DIRECT" && !t && /* @__PURE__ */ c("button", {
610
- onClick: () => void ln(e),
611
- title: T("targets.installAgent", "Install agent"),
613
+ e.type !== "DIRECT" && !t && /* @__PURE__ */ l("button", {
614
+ onClick: () => void pn(e),
615
+ title: E("targets.installAgent", "Install agent"),
612
616
  className: "flex items-center gap-1.5 rounded-md px-3 py-1.5 text-xs font-medium bg-action-primary-bg text-action-primary-text hover:bg-action-primary-bg-hover transition-colors",
613
- children: T("targets.installAgent", "Install Agent")
617
+ children: E("targets.installAgent", "Install Agent")
614
618
  }),
615
- e.type !== "DIRECT" && t && /* @__PURE__ */ c("button", {
616
- onClick: () => void un(e),
617
- title: T("targets.uninstallAgent", "Uninstall agent"),
619
+ e.type !== "DIRECT" && t && /* @__PURE__ */ l("button", {
620
+ onClick: () => void mn(e),
621
+ title: E("targets.uninstallAgent", "Uninstall agent"),
618
622
  className: "flex items-center gap-1.5 rounded-md border border-status-error-text/20 px-3 py-1.5 text-xs font-medium text-status-error-text hover:bg-status-error-bg/80 transition-colors",
619
- children: T("targets.uninstall", "Uninstall")
623
+ children: E("targets.uninstall", "Uninstall")
620
624
  }),
621
- /* @__PURE__ */ c("div", { className: "hidden flex-1 sm:block" }),
622
- /* @__PURE__ */ l("button", {
623
- onClick: () => b(e.id),
624
- title: T("targets.deleteTarget", "Delete target"),
625
+ /* @__PURE__ */ l("div", { className: "hidden flex-1 sm:block" }),
626
+ /* @__PURE__ */ u("button", {
627
+ onClick: () => x(e.id),
628
+ title: E("targets.deleteTarget", "Delete target"),
625
629
  className: "flex items-center gap-1.5 rounded-md border border-status-error-border px-3 py-1.5 text-xs font-medium text-status-error-text hover:bg-status-error-bg/80 transition-colors",
626
- children: [/* @__PURE__ */ c(o, { size: 14 }), T("common.delete", "Delete")]
630
+ children: [/* @__PURE__ */ l(s, { size: 14 }), E("common.delete", "Delete")]
627
631
  })
628
632
  ]
629
633
  })]
@@ -631,354 +635,364 @@ function u() {
631
635
  }, e.id);
632
636
  })
633
637
  }, "list-view")
634
- }) : /* @__PURE__ */ c(ge, {
635
- icon: /* @__PURE__ */ c(Fe, { className: "w-8 h-8 text-text-secondary" }),
636
- title: $ ? T("targets.emptyNoTargetsFound", "No targets found") : T("targets.emptyNoTargetsConfigured", "No targets configured"),
637
- description: $ ? T("targets.emptyAdjustSearch", "Try adjusting your search or filters") : T("targets.emptyDescription", "Add a target to start managing servers, workstations, and environments."),
638
- action: $ ? void 0 : /* @__PURE__ */ l("div", {
638
+ }) : /* @__PURE__ */ l(_e, {
639
+ icon: /* @__PURE__ */ l(Ie, { className: "w-8 h-8 text-text-secondary" }),
640
+ title: $ ? E("targets.emptyNoTargetsFound", "No targets found") : E("targets.emptyNoTargetsConfigured", "No targets configured"),
641
+ description: $ ? E("targets.emptyAdjustSearch", "Try adjusting your search or filters") : E("targets.emptyDescription", "Add a target to start managing servers, workstations, and environments."),
642
+ action: $ ? void 0 : /* @__PURE__ */ u("div", {
639
643
  className: "flex items-center gap-2",
640
- children: [/* @__PURE__ */ l("button", {
641
- onClick: () => v(!0),
644
+ children: [/* @__PURE__ */ u("button", {
645
+ onClick: () => y(!0),
642
646
  className: "flex items-center gap-2 px-4 py-2 bg-action-primary-bg text-action-primary-text rounded-md hover:bg-action-primary-bg-hover transition-colors",
643
- children: [/* @__PURE__ */ c(Ne, { className: "w-4 h-4" }), T("targets.addTarget", "Add Target")]
644
- }), /* @__PURE__ */ c(be, { prompt: "What is a Target in VibeControls and how do I create one?" })]
647
+ children: [/* @__PURE__ */ l(Pe, { className: "w-4 h-4" }), E("targets.addTarget", "Add Target")]
648
+ }), /* @__PURE__ */ l(xe, { prompt: "What is a Target in VibeControls and how do I create one?" })]
645
649
  })
646
650
  }),
647
- ot && /* @__PURE__ */ l("div", {
651
+ st && /* @__PURE__ */ u("div", {
648
652
  className: "fixed inset-0 z-50 flex items-start justify-center pt-16 overflow-y-auto",
649
- children: [/* @__PURE__ */ c("div", {
653
+ children: [/* @__PURE__ */ l("div", {
650
654
  className: "fixed inset-0 bg-bg-overlay backdrop-blur-sm",
651
- onClick: () => v(!1)
652
- }), /* @__PURE__ */ l("div", {
655
+ onClick: () => y(!1)
656
+ }), /* @__PURE__ */ u("div", {
653
657
  className: "relative bg-bg-elevated rounded-xl shadow-2xl border border-border-default max-w-lg w-full mx-4 p-6 space-y-4 mb-8",
654
658
  onClick: (e) => e.stopPropagation(),
655
659
  children: [
656
- /* @__PURE__ */ l("div", {
660
+ /* @__PURE__ */ u("div", {
657
661
  className: "flex items-start justify-between gap-3",
658
- children: [/* @__PURE__ */ c("h2", {
662
+ children: [/* @__PURE__ */ l("h2", {
659
663
  className: "text-lg font-semibold",
660
- children: T("targets.addTarget", "Add Target")
661
- }), /* @__PURE__ */ c("button", {
662
- onClick: () => v(!1),
664
+ children: E("targets.addTarget", "Add Target")
665
+ }), /* @__PURE__ */ l("button", {
666
+ onClick: () => y(!1),
663
667
  className: "p-1 rounded-lg hover:bg-bg-sunken transition-colors",
664
- children: /* @__PURE__ */ c(o, { size: 18 })
668
+ children: /* @__PURE__ */ l(s, { size: 18 })
665
669
  })]
666
670
  }),
667
- /* @__PURE__ */ l("div", {
671
+ /* @__PURE__ */ u("div", {
668
672
  className: "space-y-4",
669
673
  children: [
670
- /* @__PURE__ */ l("div", { children: [
671
- /* @__PURE__ */ c("label", {
674
+ /* @__PURE__ */ u("div", { children: [
675
+ /* @__PURE__ */ l("label", {
672
676
  className: "text-sm font-medium block mb-1.5",
673
- children: T("targets.targetType", "Target Type")
677
+ children: E("targets.targetType", "Target Type")
674
678
  }),
675
- /* @__PURE__ */ c("div", {
679
+ /* @__PURE__ */ l("div", {
676
680
  className: "grid grid-cols-2 gap-2",
677
- children: ["DIRECT", "SSH"].map((e) => /* @__PURE__ */ c("button", {
678
- onClick: () => kt(e),
681
+ children: ["DIRECT", "SSH"].map((e) => /* @__PURE__ */ l("button", {
682
+ onClick: () => jt(e),
679
683
  className: `px-3 py-2 text-sm font-medium rounded-lg border transition-colors ${R === e ? "border-action-primary-bg bg-action-primary-bg/10 text-action-primary-bg" : "border-border-default hover:bg-bg-sunken text-text-secondary"}`,
680
684
  children: e
681
685
  }, e))
682
686
  }),
683
- /* @__PURE__ */ c("p", {
687
+ /* @__PURE__ */ l("p", {
684
688
  className: "text-xs text-text-tertiary mt-1",
685
- children: R === "DIRECT" ? T("targets.targetTypeDirectHint", "A local machine where you will install the agent manually.") : T("targets.targetTypeSshHint", "A remote server accessible via SSH.")
689
+ children: R === "DIRECT" ? E("targets.targetTypeDirectHint", "A local machine where you will install the agent manually.") : E("targets.targetTypeSshHint", "A remote server accessible via SSH.")
686
690
  })
687
691
  ] }),
688
- /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
692
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
689
693
  className: "text-sm font-medium",
690
- children: T("webhooks.name", "Name")
691
- }), /* @__PURE__ */ c("input", {
694
+ children: E("webhooks.name", "Name")
695
+ }), /* @__PURE__ */ l("input", {
692
696
  value: z,
693
- onChange: (e) => At(e.target.value),
697
+ onChange: (e) => Mt(e.target.value),
694
698
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
695
- placeholder: R === "DIRECT" ? T("targets.namePlaceholderDirect", "My Laptop") : T("targets.namePlaceholderServer", "Production Server")
699
+ placeholder: R === "DIRECT" ? E("targets.namePlaceholderDirect", "My Laptop") : E("targets.namePlaceholderServer", "Production Server")
696
700
  })] }),
697
- /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
701
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
698
702
  className: "text-sm font-medium",
699
- children: T("targets.descriptionOptional", "Description (optional)")
700
- }), /* @__PURE__ */ c("input", {
703
+ children: E("targets.descriptionOptional", "Description (optional)")
704
+ }), /* @__PURE__ */ l("input", {
701
705
  value: B,
702
- onChange: (e) => jt(e.target.value),
706
+ onChange: (e) => Nt(e.target.value),
703
707
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
704
- placeholder: T("targets.descriptionPlaceholder", "Brief description of this target")
708
+ placeholder: E("targets.descriptionPlaceholder", "Brief description of this target")
705
709
  })] }),
706
- R !== "DIRECT" && /* @__PURE__ */ l(s, { children: [
707
- /* @__PURE__ */ l("div", { children: [
708
- /* @__PURE__ */ c("label", {
710
+ R !== "DIRECT" && /* @__PURE__ */ u(c, { children: [
711
+ /* @__PURE__ */ u("div", { children: [
712
+ /* @__PURE__ */ l("label", {
709
713
  className: "text-sm font-medium",
710
- children: T("targets.sourceAgent", "Source Agent")
714
+ children: E("targets.sourceAgent", "Source Agent")
711
715
  }),
712
- /* @__PURE__ */ l("select", {
716
+ /* @__PURE__ */ u("select", {
713
717
  value: V,
714
- onChange: (e) => Mt(e.target.value),
718
+ onChange: (e) => Pt(e.target.value),
715
719
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
716
- children: [/* @__PURE__ */ c("option", {
720
+ children: [/* @__PURE__ */ l("option", {
717
721
  value: "",
718
- children: T("targets.selectAgentConnectFrom", "Select an agent to connect from")
719
- }), X.map((e) => /* @__PURE__ */ c("option", {
722
+ children: E("targets.selectAgentConnectFrom", "Select an agent to connect from")
723
+ }), X.map((e) => /* @__PURE__ */ l("option", {
720
724
  value: e.id,
721
725
  children: e.name
722
726
  }, e.id))]
723
727
  }),
724
- /* @__PURE__ */ l("p", {
728
+ /* @__PURE__ */ u("p", {
725
729
  className: "text-xs text-text-tertiary mt-0.5",
726
730
  children: [
727
- T("targets.agentConnectionHintPrefix", "The agent that will establish the"),
731
+ E("targets.agentConnectionHintPrefix", "The agent that will establish the"),
728
732
  " ",
729
733
  R,
730
734
  " ",
731
- T("targets.agentConnectionHintSuffix", "connection to this target.")
735
+ E("targets.agentConnectionHintSuffix", "connection to this target.")
732
736
  ]
733
737
  })
734
738
  ] }),
735
- /* @__PURE__ */ l("div", {
739
+ /* @__PURE__ */ u("div", {
736
740
  className: "grid grid-cols-1 sm:grid-cols-2 gap-3",
737
- children: [/* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
741
+ children: [/* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
738
742
  className: "text-sm font-medium",
739
- children: T("targets.host", "Host")
740
- }), /* @__PURE__ */ c("input", {
743
+ children: E("targets.host", "Host")
744
+ }), /* @__PURE__ */ l("input", {
741
745
  value: H,
742
- onChange: (e) => Nt(e.target.value),
746
+ onChange: (e) => Ft(e.target.value),
743
747
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
744
- placeholder: T("targets.hostPlaceholder", "192.168.1.100")
745
- })] }), /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
748
+ placeholder: E("targets.hostPlaceholder", "192.168.1.100")
749
+ })] }), /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
746
750
  className: "text-sm font-medium",
747
- children: T("tunnels.port", "Port")
748
- }), /* @__PURE__ */ c("input", {
751
+ children: E("tunnels.port", "Port")
752
+ }), /* @__PURE__ */ l("input", {
749
753
  type: "number",
750
- value: Pt,
751
- onChange: (e) => Ft(Number(e.target.value)),
754
+ value: It,
755
+ onChange: (e) => Lt(Number(e.target.value)),
752
756
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm"
753
757
  })] })]
754
758
  }),
755
- /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
759
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
756
760
  className: "text-sm font-medium",
757
- children: T("targets.username", "Username")
758
- }), /* @__PURE__ */ c("input", {
761
+ children: E("targets.username", "Username")
762
+ }), /* @__PURE__ */ l("input", {
759
763
  value: U,
760
- onChange: (e) => It(e.target.value),
764
+ onChange: (e) => Rt(e.target.value),
761
765
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
762
- placeholder: T("targets.usernamePlaceholder", "root")
766
+ placeholder: E("targets.usernamePlaceholder", "root")
763
767
  })] }),
764
- R === "SSH" && /* @__PURE__ */ l(s, { children: [/* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
768
+ R === "SSH" && /* @__PURE__ */ u(c, { children: [/* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
765
769
  className: "text-sm font-medium",
766
- children: T("targets.authentication", "Authentication")
767
- }), /* @__PURE__ */ l("div", {
770
+ children: E("targets.authentication", "Authentication")
771
+ }), /* @__PURE__ */ u("div", {
768
772
  className: "flex gap-4 mt-1",
769
- children: [/* @__PURE__ */ l("label", {
773
+ children: [/* @__PURE__ */ u("label", {
770
774
  className: "flex items-center gap-2 cursor-pointer text-sm",
771
- children: [/* @__PURE__ */ c("input", {
775
+ children: [/* @__PURE__ */ l("input", {
772
776
  type: "radio",
773
777
  checked: W === "password",
774
- onChange: () => Lt("password")
775
- }), T("targets.password", "Password")]
776
- }), /* @__PURE__ */ l("label", {
778
+ onChange: () => zt("password")
779
+ }), E("targets.password", "Password")]
780
+ }), /* @__PURE__ */ u("label", {
777
781
  className: "flex items-center gap-2 cursor-pointer text-sm",
778
- children: [/* @__PURE__ */ c("input", {
782
+ children: [/* @__PURE__ */ l("input", {
779
783
  type: "radio",
780
784
  checked: W === "key",
781
- onChange: () => Lt("key")
782
- }), T("targets.privateKey", "Private Key")]
785
+ onChange: () => zt("key")
786
+ }), E("targets.privateKey", "Private Key")]
783
787
  })]
784
- })] }), W === "password" ? /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
788
+ })] }), W === "password" ? /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
785
789
  className: "text-sm font-medium",
786
- children: T("targets.password", "Password")
787
- }), /* @__PURE__ */ c("input", {
790
+ children: E("targets.password", "Password")
791
+ }), /* @__PURE__ */ l("input", {
788
792
  type: "password",
789
- value: Rt,
790
- onChange: (e) => zt(e.target.value),
791
- className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm"
792
- })] }) : /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
793
- className: "text-sm font-medium",
794
- children: T("targets.privateKeyPath", "Private Key Path")
795
- }), /* @__PURE__ */ c("input", {
796
793
  value: Bt,
797
794
  onChange: (e) => Vt(e.target.value),
795
+ className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm"
796
+ })] }) : /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
797
+ className: "text-sm font-medium",
798
+ children: E("targets.privateKeyPath", "Private Key Path")
799
+ }), /* @__PURE__ */ l("input", {
800
+ value: Ht,
801
+ onChange: (e) => Ut(e.target.value),
798
802
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
799
- placeholder: T("targets.privateKeyPathPlaceholder", "~/.ssh/id_rsa")
803
+ placeholder: E("targets.privateKeyPathPlaceholder", "~/.ssh/id_rsa")
800
804
  })] })] })
801
805
  ] }),
802
- /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
806
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
803
807
  className: "text-sm font-medium",
804
- children: T("targets.labelOptional", "Label (optional)")
805
- }), /* @__PURE__ */ c("input", {
806
- value: Ht,
807
- onChange: (e) => Ut(e.target.value),
808
+ children: E("targets.labelOptional", "Label (optional)")
809
+ }), /* @__PURE__ */ l("input", {
810
+ value: Wt,
811
+ onChange: (e) => Gt(e.target.value),
808
812
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
809
- placeholder: T("targets.labelPlaceholder", "web-server-01")
813
+ placeholder: E("targets.labelPlaceholder", "web-server-01")
810
814
  })] }),
811
- /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
815
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
812
816
  className: "text-sm font-medium",
813
- children: T("targets.tagsCommaSeparated", "Tags (comma-separated)")
814
- }), /* @__PURE__ */ c("input", {
817
+ children: E("targets.tagsCommaSeparated", "Tags (comma-separated)")
818
+ }), /* @__PURE__ */ l("input", {
815
819
  value: G,
816
- onChange: (e) => Wt(e.target.value),
820
+ onChange: (e) => Kt(e.target.value),
817
821
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
818
- placeholder: T("targets.tagsPlaceholder", "production, web")
822
+ placeholder: E("targets.tagsPlaceholder", "production, web")
819
823
  })] })
820
824
  ]
821
825
  }),
822
- /* @__PURE__ */ l("div", {
826
+ /* @__PURE__ */ u("div", {
827
+ className: "border-t border-border-default pt-3",
828
+ children: [/* @__PURE__ */ l("h3", {
829
+ className: "text-sm font-medium text-text-secondary mb-2",
830
+ children: E("targets.tags", "Tags")
831
+ }), /* @__PURE__ */ l(pe, {
832
+ entityType: "VIBECONTROLS_TARGET",
833
+ onDraftChange: Zt
834
+ })]
835
+ }),
836
+ /* @__PURE__ */ u("div", {
823
837
  className: "flex justify-end gap-2 pt-2 border-t border-border-default",
824
- children: [/* @__PURE__ */ c("button", {
825
- onClick: () => v(!1),
838
+ children: [/* @__PURE__ */ l("button", {
839
+ onClick: () => y(!1),
826
840
  className: "px-4 py-2 text-sm rounded-md border border-border-default hover:bg-bg-sunken transition-colors",
827
- children: T("common.cancel", "Cancel")
828
- }), /* @__PURE__ */ c("button", {
829
- onClick: () => void rn(),
841
+ children: E("common.cancel", "Cancel")
842
+ }), /* @__PURE__ */ l("button", {
843
+ onClick: () => void cn(),
830
844
  className: "px-4 py-2 text-sm rounded-md bg-action-primary-bg text-action-primary-text hover:bg-action-primary-bg-hover transition-colors",
831
- children: T("targets.addTarget", "Add Target")
845
+ children: E("targets.addTarget", "Add Target")
832
846
  })]
833
847
  })
834
848
  ]
835
849
  })]
836
850
  }),
837
- k && /* @__PURE__ */ l("div", {
851
+ k && /* @__PURE__ */ u("div", {
838
852
  className: "fixed inset-0 z-50 flex items-start justify-center pt-16 overflow-y-auto",
839
- children: [/* @__PURE__ */ c("div", {
853
+ children: [/* @__PURE__ */ l("div", {
840
854
  className: "fixed inset-0 bg-bg-overlay backdrop-blur-sm",
841
855
  onClick: () => !j && A(null)
842
- }), /* @__PURE__ */ l("div", {
856
+ }), /* @__PURE__ */ u("div", {
843
857
  className: "relative bg-bg-elevated rounded-xl shadow-2xl border border-border-default max-w-lg w-full mx-4 p-6 space-y-4 mb-8",
844
858
  onClick: (e) => e.stopPropagation(),
845
859
  children: [
846
- /* @__PURE__ */ l("div", {
860
+ /* @__PURE__ */ u("div", {
847
861
  className: "flex items-start justify-between gap-3",
848
- children: [/* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("h2", {
862
+ children: [/* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("h2", {
849
863
  className: "text-lg font-semibold",
850
864
  children: "Edit Target"
851
- }), /* @__PURE__ */ c("p", {
865
+ }), /* @__PURE__ */ l("p", {
852
866
  className: "text-sm text-text-secondary mt-0.5",
853
867
  children: k.name
854
- })] }), /* @__PURE__ */ c("button", {
868
+ })] }), /* @__PURE__ */ l("button", {
855
869
  onClick: () => A(null),
856
870
  disabled: j,
857
871
  className: "p-1 rounded-lg hover:bg-bg-sunken transition-colors disabled:opacity-50",
858
- children: /* @__PURE__ */ c(o, { size: 18 })
872
+ children: /* @__PURE__ */ l(s, { size: 18 })
859
873
  })]
860
874
  }),
861
- ht && /* @__PURE__ */ c("div", {
875
+ _t && /* @__PURE__ */ l("div", {
862
876
  className: "rounded-lg border border-status-error-border bg-status-error-bg-subtle p-3 text-sm text-status-error-text",
863
- children: ht
877
+ children: _t
864
878
  }),
865
- /* @__PURE__ */ l("div", {
879
+ /* @__PURE__ */ u("div", {
866
880
  className: "space-y-4",
867
881
  children: [
868
- /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
882
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
869
883
  className: "text-sm font-medium",
870
884
  children: "Name"
871
- }), /* @__PURE__ */ c("input", {
885
+ }), /* @__PURE__ */ l("input", {
872
886
  value: N,
873
- onChange: (e) => gt(e.target.value),
887
+ onChange: (e) => vt(e.target.value),
874
888
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
875
889
  placeholder: "Production Server"
876
890
  })] }),
877
- /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
891
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
878
892
  className: "text-sm font-medium",
879
893
  children: "Label (optional)"
880
- }), /* @__PURE__ */ c("input", {
881
- value: _t,
882
- onChange: (e) => vt(e.target.value),
894
+ }), /* @__PURE__ */ l("input", {
895
+ value: yt,
896
+ onChange: (e) => bt(e.target.value),
883
897
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
884
898
  placeholder: "web-server-01"
885
899
  })] }),
886
- k.type !== "DIRECT" && /* @__PURE__ */ l(s, { children: [
887
- /* @__PURE__ */ l("div", {
900
+ k.type !== "DIRECT" && /* @__PURE__ */ u(c, { children: [
901
+ /* @__PURE__ */ u("div", {
888
902
  className: "grid grid-cols-2 gap-3",
889
- children: [/* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
903
+ children: [/* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
890
904
  className: "text-sm font-medium",
891
905
  children: "Host"
892
- }), /* @__PURE__ */ c("input", {
893
- value: yt,
894
- onChange: (e) => bt(e.target.value),
906
+ }), /* @__PURE__ */ l("input", {
907
+ value: xt,
908
+ onChange: (e) => St(e.target.value),
895
909
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
896
910
  placeholder: "192.168.1.100"
897
- })] }), /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
911
+ })] }), /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
898
912
  className: "text-sm font-medium",
899
913
  children: "Port"
900
- }), /* @__PURE__ */ c("input", {
914
+ }), /* @__PURE__ */ l("input", {
901
915
  type: "number",
902
- value: xt,
903
- onChange: (e) => St(Number(e.target.value)),
916
+ value: Ct,
917
+ onChange: (e) => wt(Number(e.target.value)),
904
918
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm"
905
919
  })] })]
906
920
  }),
907
- /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
921
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
908
922
  className: "text-sm font-medium",
909
923
  children: "Username"
910
- }), /* @__PURE__ */ c("input", {
911
- value: Ct,
912
- onChange: (e) => wt(e.target.value),
924
+ }), /* @__PURE__ */ l("input", {
925
+ value: Tt,
926
+ onChange: (e) => Et(e.target.value),
913
927
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
914
928
  placeholder: "root"
915
929
  })] }),
916
- k.type === "SSH" && /* @__PURE__ */ l(s, { children: [/* @__PURE__ */ l("div", { children: [
917
- /* @__PURE__ */ c("label", {
930
+ k.type === "SSH" && /* @__PURE__ */ u(c, { children: [/* @__PURE__ */ u("div", { children: [
931
+ /* @__PURE__ */ l("label", {
918
932
  className: "text-sm font-medium",
919
933
  children: "Update credentials (optional)"
920
934
  }),
921
- /* @__PURE__ */ l("div", {
935
+ /* @__PURE__ */ u("div", {
922
936
  className: "flex gap-4 mt-1",
923
- children: [/* @__PURE__ */ l("label", {
937
+ children: [/* @__PURE__ */ u("label", {
924
938
  className: "flex items-center gap-2 cursor-pointer text-sm",
925
- children: [/* @__PURE__ */ c("input", {
939
+ children: [/* @__PURE__ */ l("input", {
926
940
  type: "radio",
927
941
  checked: P === "password",
928
- onChange: () => Tt("password")
942
+ onChange: () => Dt("password")
929
943
  }), "Password"]
930
- }), /* @__PURE__ */ l("label", {
944
+ }), /* @__PURE__ */ u("label", {
931
945
  className: "flex items-center gap-2 cursor-pointer text-sm",
932
- children: [/* @__PURE__ */ c("input", {
946
+ children: [/* @__PURE__ */ l("input", {
933
947
  type: "radio",
934
948
  checked: P === "key",
935
- onChange: () => Tt("key")
949
+ onChange: () => Dt("key")
936
950
  }), "Private Key"]
937
951
  })]
938
952
  }),
939
- /* @__PURE__ */ c("p", {
953
+ /* @__PURE__ */ l("p", {
940
954
  className: "text-xs text-text-tertiary mt-0.5",
941
955
  children: "Leave blank to keep existing credentials."
942
956
  })
943
- ] }), P === "password" ? /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
957
+ ] }), P === "password" ? /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
944
958
  className: "text-sm font-medium",
945
959
  children: "New Password"
946
- }), /* @__PURE__ */ c("input", {
960
+ }), /* @__PURE__ */ l("input", {
947
961
  type: "password",
948
962
  value: F,
949
- onChange: (e) => Et(e.target.value),
963
+ onChange: (e) => Ot(e.target.value),
950
964
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
951
965
  placeholder: "Leave blank to keep current"
952
- })] }) : /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
966
+ })] }) : /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
953
967
  className: "text-sm font-medium",
954
968
  children: "New Private Key Path"
955
- }), /* @__PURE__ */ c("input", {
969
+ }), /* @__PURE__ */ l("input", {
956
970
  value: I,
957
- onChange: (e) => Dt(e.target.value),
971
+ onChange: (e) => kt(e.target.value),
958
972
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
959
973
  placeholder: "Leave blank to keep current (~/.ssh/id_rsa)"
960
974
  })] })] })
961
975
  ] }),
962
- /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("label", {
976
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
963
977
  className: "text-sm font-medium",
964
978
  children: "Tags (comma-separated)"
965
- }), /* @__PURE__ */ c("input", {
979
+ }), /* @__PURE__ */ l("input", {
966
980
  value: L,
967
- onChange: (e) => Ot(e.target.value),
981
+ onChange: (e) => At(e.target.value),
968
982
  className: "w-full mt-1 px-3 py-2 rounded-lg border border-border-default bg-bg-elevated text-sm",
969
983
  placeholder: "production, web"
970
984
  })] })
971
985
  ]
972
986
  }),
973
- /* @__PURE__ */ l("div", {
987
+ /* @__PURE__ */ u("div", {
974
988
  className: "flex justify-end gap-2 pt-2 border-t border-border-default",
975
- children: [/* @__PURE__ */ c("button", {
989
+ children: [/* @__PURE__ */ l("button", {
976
990
  onClick: () => A(null),
977
991
  disabled: j,
978
992
  className: "px-4 py-2 text-sm rounded-lg border border-border-default hover:bg-bg-sunken transition-colors disabled:opacity-50",
979
993
  children: "Cancel"
980
- }), /* @__PURE__ */ c("button", {
981
- onClick: () => void fn(),
994
+ }), /* @__PURE__ */ l("button", {
995
+ onClick: () => void gn(),
982
996
  disabled: j,
983
997
  className: "rounded-lg bg-action-primary-bg px-4 py-2 text-sm text-action-primary-text transition-colors hover:bg-action-primary-bg-hover disabled:opacity-50",
984
998
  children: j ? "Saving..." : "Save Changes"
@@ -987,123 +1001,123 @@ function u() {
987
1001
  ]
988
1002
  })]
989
1003
  }),
990
- /* @__PURE__ */ c(de, {
991
- isOpen: !!y,
992
- onClose: () => b(null),
993
- onConfirm: () => void sn(),
994
- title: T("targets.deleteTarget", "Delete Target"),
995
- message: T("targets.deleteTargetMessage", "This will remove the target and its connection from the agent. Active terminals will be disconnected."),
996
- confirmLabel: T("common.delete", "Delete"),
1004
+ /* @__PURE__ */ l(r, {
1005
+ isOpen: !!b,
1006
+ onClose: () => x(null),
1007
+ onConfirm: () => void dn(),
1008
+ title: E("targets.deleteTarget", "Delete Target"),
1009
+ message: E("targets.deleteTargetMessage", "This will remove the target and its connection from the agent. Active terminals will be disconnected."),
1010
+ confirmLabel: E("common.delete", "Delete"),
997
1011
  variant: "danger"
998
1012
  }),
999
- /* @__PURE__ */ c(de, {
1000
- isOpen: st,
1001
- onClose: () => ct(!1),
1002
- onConfirm: () => void cn(),
1003
- title: T("targets.deleteSelectedTargets", "Delete Selected Targets"),
1004
- message: `${T("targets.confirmDeleteSelectedPrefix", "Are you sure you want to delete")} ${x.size} ${T("nav.targets", "target")}${x.size === 1 ? "" : "s"}? ${T("targets.confirmDeleteSelectedSuffix", "This action cannot be undone.")}`,
1005
- confirmLabel: T("targets.deleteAll", "Delete All"),
1013
+ /* @__PURE__ */ l(r, {
1014
+ isOpen: ct,
1015
+ onClose: () => lt(!1),
1016
+ onConfirm: () => void fn(),
1017
+ title: E("targets.deleteSelectedTargets", "Delete Selected Targets"),
1018
+ message: `${E("targets.confirmDeleteSelectedPrefix", "Are you sure you want to delete")} ${S.size} ${E("nav.targets", "target")}${S.size === 1 ? "" : "s"}? ${E("targets.confirmDeleteSelectedSuffix", "This action cannot be undone.")}`,
1019
+ confirmLabel: E("targets.deleteAll", "Delete All"),
1006
1020
  variant: "danger"
1007
1021
  }),
1008
- E && /* @__PURE__ */ c("div", {
1022
+ D && /* @__PURE__ */ l("div", {
1009
1023
  className: "fixed inset-0 bg-bg-overlay flex items-center justify-center z-50",
1010
- children: /* @__PURE__ */ l("div", {
1024
+ children: /* @__PURE__ */ u("div", {
1011
1025
  className: "bg-bg-elevated rounded-xl shadow-xl max-w-md w-full mx-4 p-6",
1012
1026
  children: [
1013
- /* @__PURE__ */ l("div", {
1027
+ /* @__PURE__ */ u("div", {
1014
1028
  className: "flex items-start justify-between gap-3",
1015
- children: [/* @__PURE__ */ l("h2", {
1029
+ children: [/* @__PURE__ */ u("h2", {
1016
1030
  className: "text-lg font-semibold break-words",
1017
1031
  children: [
1018
- T("targets.installingAgentOn", "Installing Agent on"),
1032
+ E("targets.installingAgentOn", "Installing Agent on"),
1019
1033
  " ",
1020
- E.name
1034
+ D.name
1021
1035
  ]
1022
- }), D?.status !== "running" && /* @__PURE__ */ c("button", {
1023
- onClick: pn,
1036
+ }), O?.status !== "running" && /* @__PURE__ */ l("button", {
1037
+ onClick: _n,
1024
1038
  className: "p-1 rounded hover:bg-bg-sunken",
1025
- children: /* @__PURE__ */ c(o, { size: 16 })
1039
+ children: /* @__PURE__ */ l(s, { size: 16 })
1026
1040
  })]
1027
1041
  }),
1028
- /* @__PURE__ */ c("div", {
1042
+ /* @__PURE__ */ l("div", {
1029
1043
  className: "space-y-2 mt-4",
1030
- children: D && D.steps ? D.steps.map((e, t) => /* @__PURE__ */ l("div", {
1044
+ children: O && O.steps ? O.steps.map((e, t) => /* @__PURE__ */ u("div", {
1031
1045
  className: "flex items-center gap-3",
1032
1046
  children: [
1033
- e.status === "running" && /* @__PURE__ */ c(je, {
1047
+ e.status === "running" && /* @__PURE__ */ l(Me, {
1034
1048
  className: "animate-spin text-action-primary-bg",
1035
1049
  size: 16
1036
1050
  }),
1037
- e.status === "completed" && /* @__PURE__ */ c(De, {
1051
+ e.status === "completed" && /* @__PURE__ */ l(Oe, {
1038
1052
  className: "text-status-success-text",
1039
1053
  size: 16
1040
1054
  }),
1041
- e.status === "failed" && /* @__PURE__ */ c(Le, {
1055
+ e.status === "failed" && /* @__PURE__ */ l(Re, {
1042
1056
  className: "text-status-error-text",
1043
1057
  size: 16
1044
1058
  }),
1045
- e.status === "skipped" && /* @__PURE__ */ c(Ee, {
1059
+ e.status === "skipped" && /* @__PURE__ */ l(De, {
1046
1060
  className: "text-text-tertiary",
1047
1061
  size: 16
1048
1062
  }),
1049
- e.status === "pending" && /* @__PURE__ */ c("div", { className: "w-4 h-4 rounded-full border-2 border-border-default" }),
1050
- /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("div", {
1063
+ e.status === "pending" && /* @__PURE__ */ l("div", { className: "w-4 h-4 rounded-full border-2 border-border-default" }),
1064
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("div", {
1051
1065
  className: "text-sm font-medium",
1052
- children: T(`targets.installStep.${e.name}`, Ke[e.name] ?? e.name)
1053
- }), e.message && /* @__PURE__ */ c("div", {
1066
+ children: E(`targets.installStep.${e.name}`, qe[e.name] ?? e.name)
1067
+ }), e.message && /* @__PURE__ */ l("div", {
1054
1068
  className: "text-xs text-text-tertiary",
1055
1069
  children: e.message
1056
1070
  })] })
1057
1071
  ]
1058
- }, t)) : /* @__PURE__ */ l("div", {
1072
+ }, t)) : /* @__PURE__ */ u("div", {
1059
1073
  className: "flex items-center gap-3",
1060
- children: [/* @__PURE__ */ c(je, {
1074
+ children: [/* @__PURE__ */ l(Me, {
1061
1075
  className: "animate-spin text-action-primary-bg",
1062
1076
  size: 16
1063
- }), /* @__PURE__ */ c("span", {
1077
+ }), /* @__PURE__ */ l("span", {
1064
1078
  className: "text-sm",
1065
- children: T("targets.startingInstallJob", "Starting install job...")
1079
+ children: E("targets.startingInstallJob", "Starting install job...")
1066
1080
  })]
1067
1081
  })
1068
1082
  }),
1069
- D?.status === "completed" && /* @__PURE__ */ c("div", {
1083
+ O?.status === "completed" && /* @__PURE__ */ l("div", {
1070
1084
  className: "mt-4 rounded-lg border border-status-success-border bg-status-success-bg-subtle p-3 text-sm text-status-success-text",
1071
- children: T("targets.agentInstalledSuccess", "Agent installed successfully!")
1085
+ children: E("targets.agentInstalledSuccess", "Agent installed successfully!")
1072
1086
  }),
1073
- D?.status === "failed" && /* @__PURE__ */ c("div", {
1087
+ O?.status === "failed" && /* @__PURE__ */ l("div", {
1074
1088
  className: "mt-4 rounded-lg border border-status-error-border bg-status-error-bg-subtle p-3 text-sm text-status-error-text",
1075
- children: D.error ?? T("targets.installationFailed", "Installation failed.")
1089
+ children: O.error ?? E("targets.installationFailed", "Installation failed.")
1076
1090
  }),
1077
- /* @__PURE__ */ c("button", {
1078
- onClick: pn,
1079
- disabled: D?.status === "running",
1091
+ /* @__PURE__ */ l("button", {
1092
+ onClick: _n,
1093
+ disabled: O?.status === "running",
1080
1094
  className: "mt-4 w-full px-4 py-2 rounded-md border border-border-default hover:bg-bg-sunken transition-colors disabled:opacity-50 disabled:cursor-not-allowed text-sm font-medium",
1081
- children: !D || D.status === "running" ? T("targets.installing", "Installing...") : T("common.close", "Close")
1095
+ children: !O || O.status === "running" ? E("targets.installing", "Installing...") : E("common.close", "Close")
1082
1096
  })
1083
1097
  ]
1084
1098
  })
1085
1099
  }),
1086
- /* @__PURE__ */ c(de, {
1087
- isOpen: ut,
1088
- onClose: () => w(!1),
1100
+ /* @__PURE__ */ l(r, {
1101
+ isOpen: dt,
1102
+ onClose: () => T(!1),
1089
1103
  onConfirm: () => {
1090
- w(!1), f("/billing");
1104
+ T(!1), p("/billing");
1091
1105
  },
1092
- title: fe("environment").title,
1093
- message: fe("environment").message,
1106
+ title: de("environment").title,
1107
+ message: de("environment").message,
1094
1108
  confirmLabel: "View Billing",
1095
1109
  cancelLabel: "Dismiss",
1096
1110
  variant: "warning"
1097
1111
  })
1098
1112
  ]
1099
- }) : /* @__PURE__ */ c("div", {
1113
+ }) : /* @__PURE__ */ l("div", {
1100
1114
  className: "flex items-center justify-center min-h-[400px]",
1101
- children: /* @__PURE__ */ l("div", {
1115
+ children: /* @__PURE__ */ u("div", {
1102
1116
  className: "text-center space-y-2",
1103
- children: [/* @__PURE__ */ c("h2", {
1117
+ children: [/* @__PURE__ */ l("h2", {
1104
1118
  className: "text-lg font-semibold text-foreground",
1105
1119
  children: "Access Denied"
1106
- }), /* @__PURE__ */ c("p", {
1120
+ }), /* @__PURE__ */ l("p", {
1107
1121
  className: "text-sm text-text-secondary",
1108
1122
  children: "You don't have permission to access this page."
1109
1123
  })]
@@ -1111,6 +1125,6 @@ function u() {
1111
1125
  });
1112
1126
  }
1113
1127
  //#endregion
1114
- export { u as TargetsPage };
1128
+ export { d as TargetsPage };
1115
1129
 
1116
1130
  //# sourceMappingURL=TargetsPage.js.map