@burdenoff/microfe-devportal 2026.724.1 → 2026.728.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.
@@ -3,29 +3,29 @@ import { EmptyState as t } from "../components/EmptyState.js";
3
3
  import { useApproveApplicationVersionMutation as n, useCreateApplicationVersionMutation as r, useDeprecateApplicationVersionMutation as ee, useGetApplicationQuery as te, useGetApplicationVersionsQuery as ne, usePublishApplicationVersionMutation as re, useRejectApplicationVersionMutation as ie, useUpdateApplicationVersionMutation as ae } from "../../generated/global-operations.js";
4
4
  import { PageLayout as i } from "../components/PageLayout.js";
5
5
  import { StatusBadge as oe } from "../components/StatusBadge.js";
6
- import { SelectionCheckbox as a } from "../components/SelectionCheckbox.js";
7
- import { DataTable as se } from "../components/DataTable.js";
8
- import { InputField as ce } from "../components/FormField.js";
9
- import { ConfirmDialog as o } from "../components/ConfirmDialog.js";
10
- import { PermissionGuard as le } from "../components/PermissionGuard.js";
11
- import { MarkdownEditor as s } from "../components/MarkdownEditor.js";
6
+ import { SelectionCheckbox as se } from "../components/SelectionCheckbox.js";
7
+ import { DataTable as ce } from "../components/DataTable.js";
8
+ import { InputField as le } from "../components/FormField.js";
9
+ import { ConfirmDialog as a } from "../components/ConfirmDialog.js";
10
+ import { PermissionGuard as ue } from "../components/PermissionGuard.js";
11
+ import { MarkdownEditor as o } from "../components/MarkdownEditor.js";
12
12
  import "../components/index.js";
13
- import { useDevportalPermission as c } from "../hooks/usePermission.js";
13
+ import { useDevportalPermission as de } from "../hooks/usePermission.js";
14
14
  import "../hooks/index.js";
15
- import { DEVPORTAL_PERMISSIONS as ue } from "../constants/permissions.js";
16
- import de from "../../node_modules/date-fns/format.js";
17
- import { usePackageUpload as fe } from "../hooks/usePackageUpload.js";
18
- import { useCallback as l, useEffect as pe, useMemo as u, useRef as d, useState as f } from "react";
19
- import { useI18n as me } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
20
- import { AlertCircle as p, Archive as he, CheckCircle as ge, Clock as _e, Loader2 as m, Package as ve, Plus as ye, Send as be, Upload as h, XCircle as xe } from "lucide-react";
15
+ import { DEVPORTAL_PERMISSIONS as s } from "../constants/permissions.js";
16
+ import fe from "../../node_modules/date-fns/format.js";
17
+ import { usePackageUpload as pe } from "../hooks/usePackageUpload.js";
18
+ import { useCallback as c, useEffect as me, useMemo as l, useRef as u, useState as d } from "react";
19
+ import { useI18n as he } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
20
+ import { AlertCircle as f, Archive as ge, CheckCircle as _e, Clock as ve, Loader2 as p, Package as ye, Plus as be, Send as m, Upload as h, XCircle as xe } from "lucide-react";
21
21
  import { useParams as Se } from "react-router-dom";
22
22
  import { Fragment as g, jsx as _, jsxs as v } from "react/jsx-runtime";
23
23
  //#region src/devportal/pages/ApplicationVersionsPage.tsx
24
24
  var Ce = () => {
25
- let { t: Ce } = me(), y = (e, t) => {
25
+ let { t: Ce } = he(), y = (e, t) => {
26
26
  let n = Ce(e);
27
27
  return n === e ? t : n;
28
- }, { allowed: b } = c(ue.APP_VERSION_CREATE), { allowed: x } = c(ue.APP_VERSION_PUBLISH), { allowed: S } = c(ue.APP_VERSION_DEPRECATE), { appId: C } = Se(), { workspacesGatewayUrl: we, authToken: Te, workspaceId: Ee, getWorkspaceToken: De } = e(), { upload: w, uploading: T, progress: Oe, error: E } = fe(we, Te, Ee, De), ke = d(null), Ae = d(null), je = d(null), Me = d(null), [Ne, D] = f(null), [Pe, O] = f(null), [Fe, k] = f(!1), [A, j] = f(null), [M, N] = f({
28
+ }, { allowed: we } = de(s.APP_VERSION_CREATE), { allowed: b } = de(s.APP_VERSION_PUBLISH), { allowed: x } = de(s.APP_VERSION_DEPRECATE), { appId: S } = Se(), { workspacesGatewayUrl: Te, authToken: Ee, workspaceId: De, getWorkspaceToken: Oe } = e(), { upload: C, uploading: w, progress: ke, error: T } = pe(Te, Ee, De, Oe), Ae = u(null), je = u(null), Me = u(null), Ne = u(null), [Pe, E] = d(null), [Fe, D] = d(null), [Ie, O] = d(!1), [k, A] = d(null), [j, M] = d({
29
29
  version: "",
30
30
  releaseNotes: "",
31
31
  changelog: "",
@@ -33,82 +33,87 @@ var Ce = () => {
33
33
  packageSize: "",
34
34
  manifestJson: "",
35
35
  requiredScopes: ""
36
- }), [Ie, P] = f(null), [Le, F] = f(null), [Re, I] = f(null), [ze, L] = f(null), [R, z] = f(/* @__PURE__ */ new Set()), [B, Be] = f(null), [V, Ve] = f(""), He = l((e) => {
36
+ }), [Le, N] = d(null), [Re, P] = d(null), [ze, F] = d(null), [Be, I] = d(null), [L, R] = d(/* @__PURE__ */ new Set()), [z, Ve] = d(null), [B, V] = d(""), He = c((e) => {
37
37
  let t = e.target.files?.[0];
38
38
  if (!t) return;
39
39
  let n = new FileReader();
40
40
  n.onload = (e) => {
41
41
  let n = e.target?.result;
42
- typeof n == "string" && (N((e) => ({
42
+ typeof n == "string" && (M((e) => ({
43
43
  ...e,
44
44
  manifestJson: n
45
- })), D(t.name));
45
+ })), E(t.name));
46
46
  }, n.readAsText(t), e.target.value = "";
47
- }, []), [Ue, H] = f(null), { data: U } = te({
48
- variables: { id: C ?? "" },
49
- skip: !C,
47
+ }, []), [Ue, H] = d(null), { data: U } = te({
48
+ variables: { id: S ?? "" },
49
+ skip: !S,
50
50
  fetchPolicy: "cache-first"
51
- }), W = U?.application?.appType === "WORKFLOW", G = U?.application?.appType === "NODE", We = !W && !G, K = U?.application, Ge = K?.pricingDetails ?? {}, Ke = K?.pricingType === "FREE" || K?.pricingType === "PAID" && typeof Ge.price == "number" && Ge.price > 0, qe = !!K?.shortDescription?.trim() && !!K?.privacyPolicyUrl?.trim() && !!K?.termsOfServiceUrl?.trim(), q = Ke && qe, J = [...qe ? [] : ["Complete your store listing (short description, privacy policy, terms of service)"], ...Ke ? [] : ["Set pricing in the Pricing tab"]];
52
- pe(() => {
51
+ }), W = U?.application?.appType === "WORKFLOW", G = U?.application?.appType === "NODE", K = [
52
+ "WORKFLOW",
53
+ "PARSER",
54
+ "WIDGET",
55
+ "DASHBOARD"
56
+ ].includes(U?.application?.appType ?? ""), We = !K && !G, q = U?.application, Ge = q?.pricingDetails ?? {}, Ke = q?.pricingType === "FREE" || q?.pricingType === "PAID" && typeof Ge.price == "number" && Ge.price > 0, qe = !!q?.shortDescription?.trim() && !!q?.privacyPolicyUrl?.trim() && !!q?.termsOfServiceUrl?.trim(), J = Ke && qe, Je = [...qe ? [] : ["Complete your store listing (short description, privacy policy, terms of service)"], ...Ke ? [] : ["Set pricing in the Pricing tab"]];
57
+ me(() => {
53
58
  let e = U?.application?.name;
54
- if (!C || !e) return;
59
+ if (!S || !e) return;
55
60
  let t = window.__breadcrumbRegistry;
56
- return t?.register(C, e), () => t?.unregister(C);
57
- }, [C, U?.application?.name]);
58
- let { data: Y, loading: Je, error: Ye } = ne({
59
- variables: { applicationId: C },
60
- skip: !C,
61
+ return t?.register(S, e), () => t?.unregister(S);
62
+ }, [S, U?.application?.name]);
63
+ let { data: Y, loading: Ye, error: Xe } = ne({
64
+ variables: { applicationId: S },
65
+ skip: !S,
61
66
  fetchPolicy: "cache-and-network"
62
- }), [Xe, { loading: Ze }] = r({ refetchQueries: ["GetApplicationVersions"] }), [Qe, { loading: $e }] = ae({ refetchQueries: ["GetApplicationVersions"] }), [et] = re({ refetchQueries: ["GetApplicationVersions"] }), [tt] = ee({ refetchQueries: ["GetApplicationVersions"] }), [nt] = n({ refetchQueries: ["GetApplicationVersions"] }), [rt] = ie({ refetchQueries: ["GetApplicationVersions"] }), X = u(() => Y?.application?.versions?.edges?.map((e) => e.node) ?? [], [Y?.application?.versions]), Z = u(() => X.filter((e) => R.has(e.id)), [X, R]), Q = u(() => Z.filter((e) => e.status === "draft" || e.status === "rejected"), [Z]), $ = u(() => Z.filter((e) => e.status?.toUpperCase() === "PUBLISHED" && !e.isLatest), [Z]), it = X.length > 0 && X.every((e) => R.has(e.id)), at = X.some((e) => R.has(e.id)) && !it, ot = async () => {
63
- if (!C || !M.version.trim()) return;
64
- I(null);
67
+ }), [Ze, { loading: Qe }] = r({ refetchQueries: ["GetApplicationVersions"] }), [$e, { loading: et }] = ae({ refetchQueries: ["GetApplicationVersions"] }), [tt] = re({ refetchQueries: ["GetApplicationVersions"] }), [nt] = ee({ refetchQueries: ["GetApplicationVersions"] }), [rt] = n({ refetchQueries: ["GetApplicationVersions"] }), [it] = ie({ refetchQueries: ["GetApplicationVersions"] }), X = l(() => Y?.application?.versions?.edges?.map((e) => e.node) ?? [], [Y?.application?.versions]), Z = l(() => X.filter((e) => L.has(e.id)), [X, L]), Q = l(() => Z.filter((e) => e.status === "draft" || e.status === "rejected"), [Z]), $ = l(() => Z.filter((e) => e.status?.toUpperCase() === "PUBLISHED" && !e.isLatest), [Z]), at = X.length > 0 && X.every((e) => L.has(e.id)), ot = X.some((e) => L.has(e.id)) && !at, st = async () => {
68
+ if (!S || !j.version.trim()) return;
69
+ F(null);
65
70
  let e;
66
- if (W) {
67
- if (!M.manifestJson.trim()) {
68
- I("Workflow Definition (JSON) is required — paste the {nodes, edges} object.");
71
+ if (K) {
72
+ if (!j.manifestJson.trim()) {
73
+ F(W ? "Workflow Definition (JSON) is required — paste the {nodes, edges} object." : "Manifest (JSON) is required.");
69
74
  return;
70
75
  }
71
76
  try {
72
- e = JSON.parse(M.manifestJson);
77
+ e = JSON.parse(j.manifestJson);
73
78
  } catch {
74
- I("Invalid JSON in Workflow Definition — please check your input.");
79
+ F(W ? "Invalid JSON in Workflow Definition — please check your input." : "Invalid JSON in Manifest — please check your input.");
75
80
  return;
76
81
  }
77
82
  } else if (G) {
78
- if (!M.packageUrl) {
79
- I("Package zip is required for Node versions — upload a .zip file before creating.");
83
+ if (!j.packageUrl) {
84
+ F("Package zip is required for Node versions — upload a .zip file before creating.");
80
85
  return;
81
86
  }
82
- if (!M.manifestJson.trim()) {
83
- I("manifest.json is required for Node versions — upload or paste your manifest before creating.");
87
+ if (!j.manifestJson.trim()) {
88
+ F("manifest.json is required for Node versions — upload or paste your manifest before creating.");
84
89
  return;
85
90
  }
86
91
  try {
87
- e = JSON.parse(M.manifestJson);
92
+ e = JSON.parse(j.manifestJson);
88
93
  } catch {
89
- I("Invalid JSON in manifest — please check your input.");
94
+ F("Invalid JSON in manifest — please check your input.");
90
95
  return;
91
96
  }
92
- } else if (M.manifestJson.trim()) try {
93
- e = JSON.parse(M.manifestJson);
97
+ } else if (j.manifestJson.trim()) try {
98
+ e = JSON.parse(j.manifestJson);
94
99
  } catch {
95
- I("Invalid JSON in manifest — please check your input.");
100
+ F("Invalid JSON in manifest — please check your input.");
96
101
  return;
97
102
  }
98
- let t = We && M.requiredScopes.trim() ? M.requiredScopes.split(",").map((e) => e.trim()).filter(Boolean) : void 0;
103
+ let t = We && j.requiredScopes.trim() ? j.requiredScopes.split(",").map((e) => e.trim()).filter(Boolean) : void 0;
99
104
  try {
100
- await Xe({ variables: {
101
- applicationId: C,
105
+ await Ze({ variables: {
106
+ applicationId: S,
102
107
  input: {
103
- version: M.version,
104
- releaseNotes: M.releaseNotes || void 0,
105
- changelog: M.changelog || void 0,
106
- packageUrl: M.packageUrl || void 0,
107
- packageSize: M.packageSize || void 0,
108
+ version: j.version,
109
+ releaseNotes: j.releaseNotes || void 0,
110
+ changelog: j.changelog || void 0,
111
+ packageUrl: j.packageUrl || void 0,
112
+ packageSize: j.packageSize || void 0,
108
113
  manifest: e,
109
114
  requiredScopes: t
110
115
  }
111
- } }), k(!1), D(null), N({
116
+ } }), O(!1), E(null), M({
112
117
  version: "",
113
118
  releaseNotes: "",
114
119
  changelog: "",
@@ -116,197 +121,197 @@ var Ce = () => {
116
121
  packageSize: "",
117
122
  manifestJson: "",
118
123
  requiredScopes: ""
119
- }), F(y("devportal.versionCreatedSuccess", "Version created successfully"));
124
+ }), P(y("devportal.versionCreatedSuccess", "Version created successfully"));
120
125
  } catch (e) {
121
- P(e instanceof Error ? e.message : y("devportal.versionCreateFailed", "Failed to create version"));
126
+ N(e instanceof Error ? e.message : y("devportal.versionCreateFailed", "Failed to create version"));
122
127
  }
123
- }, st = l(async (e) => {
128
+ }, ct = c(async (e) => {
124
129
  let t = e.target.files?.[0];
125
130
  if (t) {
126
131
  e.target.value = "";
127
132
  try {
128
- let e = await w(t);
129
- N((n) => ({
133
+ let e = await C(t);
134
+ M((n) => ({
130
135
  ...n,
131
136
  packageUrl: e.downloadUrl,
132
137
  packageSize: String(t.size)
133
138
  }));
134
139
  } catch {}
135
140
  }
136
- }, [w]), ct = l(async (e) => {
141
+ }, [C]), lt = c(async (e) => {
137
142
  let t = e.target.files?.[0];
138
143
  if (t) {
139
144
  e.target.value = "";
140
145
  try {
141
- let e = await w(t);
142
- j((n) => n && {
146
+ let e = await C(t);
147
+ A((n) => n && {
143
148
  ...n,
144
149
  newPackageUrl: e.downloadUrl,
145
150
  newPackageSize: String(t.size)
146
151
  });
147
152
  } catch {}
148
153
  }
149
- }, [w]), lt = l((e) => {
154
+ }, [C]), ut = c((e) => {
150
155
  let t = e.target.files?.[0];
151
156
  if (!t) return;
152
157
  let n = new FileReader();
153
158
  n.onload = (e) => {
154
159
  let n = e.target?.result;
155
- typeof n == "string" && (j((e) => e && {
160
+ typeof n == "string" && (A((e) => e && {
156
161
  ...e,
157
162
  manifestJson: n
158
- }), O(t.name));
163
+ }), D(t.name));
159
164
  }, n.readAsText(t), e.target.value = "";
160
- }, []), ut = async () => {
161
- if (!A) return;
162
- L(null);
163
- let e = A.manifestJson.trim() !== A.originalManifestJson.trim(), t;
164
- if (e && A.manifestJson.trim()) try {
165
- t = JSON.parse(A.manifestJson);
165
+ }, []), dt = async () => {
166
+ if (!k) return;
167
+ I(null);
168
+ let e = k.manifestJson.trim() !== k.originalManifestJson.trim(), t;
169
+ if (e && k.manifestJson.trim()) try {
170
+ t = JSON.parse(k.manifestJson);
166
171
  } catch {
167
- L("Invalid JSON in manifest — please check your input.");
172
+ I("Invalid JSON in manifest — please check your input.");
168
173
  return;
169
174
  }
170
175
  let n = {};
171
- A.releaseNotes.trim() && (n.releaseNotes = A.releaseNotes), A.changelog.trim() && (n.changelog = A.changelog), A.newPackageUrl && (n.packageUrl = A.newPackageUrl, n.packageSize = A.newPackageSize), t && (n.manifest = t);
176
+ k.releaseNotes.trim() && (n.releaseNotes = k.releaseNotes), k.changelog.trim() && (n.changelog = k.changelog), k.newPackageUrl && (n.packageUrl = k.newPackageUrl, n.packageSize = k.newPackageSize), t && (n.manifest = t);
172
177
  try {
173
- await Qe({ variables: {
174
- id: A.versionId,
178
+ await $e({ variables: {
179
+ id: k.versionId,
175
180
  input: n
176
- } }), j(null), O(null), F(y("devportal.versionUpdatedSuccess", "Version updated successfully"));
181
+ } }), A(null), D(null), P(y("devportal.versionUpdatedSuccess", "Version updated successfully"));
177
182
  } catch (e) {
178
- P(e instanceof Error ? e.message : y("devportal.versionUpdateFailed", "Failed to update version"));
183
+ N(e instanceof Error ? e.message : y("devportal.versionUpdateFailed", "Failed to update version"));
179
184
  }
180
- }, dt = async (e) => {
181
- P(null), F(null);
185
+ }, ft = async (e) => {
186
+ N(null), P(null);
182
187
  try {
183
- await et({ variables: { id: e } }), F(y("devportal.versionSubmittedSuccess", "Version submitted for review — you'll be notified when approved"));
188
+ await tt({ variables: { id: e } }), P(y("devportal.versionSubmittedSuccess", "Version submitted for review — you'll be notified when approved"));
184
189
  } catch (e) {
185
- P(e instanceof Error ? e.message : y("devportal.versionPublishFailed", "Failed to submit version for review"));
190
+ N(e instanceof Error ? e.message : y("devportal.versionPublishFailed", "Failed to submit version for review"));
186
191
  }
187
- }, ft = async (e) => {
188
- P(null), F(null);
192
+ }, pt = async (e) => {
193
+ N(null), P(null);
189
194
  try {
190
- await tt({ variables: { id: e } }), F(y("devportal.versionDeprecatedSuccess", "Version deprecated successfully"));
195
+ await nt({ variables: { id: e } }), P(y("devportal.versionDeprecatedSuccess", "Version deprecated successfully"));
191
196
  } catch (e) {
192
- P(e instanceof Error ? e.message : y("devportal.versionDeprecateFailed", "Failed to deprecate version"));
197
+ N(e instanceof Error ? e.message : y("devportal.versionDeprecateFailed", "Failed to deprecate version"));
193
198
  }
194
- }, pt = async () => {
195
- if (!(!B || !V.trim())) {
196
- P(null), F(null);
199
+ }, mt = async () => {
200
+ if (!(!z || !B.trim())) {
201
+ N(null), P(null);
197
202
  try {
198
- await rt({ variables: {
199
- id: B.versionId,
200
- reason: V
201
- } }), F(y("devportal.versionRejectedSuccess", "Version rejected — developer has been notified")), Be(null), Ve("");
203
+ await it({ variables: {
204
+ id: z.versionId,
205
+ reason: B
206
+ } }), P(y("devportal.versionRejectedSuccess", "Version rejected — developer has been notified")), Ve(null), V("");
202
207
  } catch (e) {
203
- P(e instanceof Error ? e.message : y("devportal.versionRejectFailed", "Failed to reject version"));
208
+ N(e instanceof Error ? e.message : y("devportal.versionRejectFailed", "Failed to reject version"));
204
209
  }
205
210
  }
206
- }, mt = (e) => e.status === "published" && e.isLatest ? /* @__PURE__ */ _(ge, {
211
+ }, ht = (e) => e.status === "published" && e.isLatest ? /* @__PURE__ */ _(_e, {
207
212
  size: 16,
208
213
  className: "text-status-success-text"
209
- }) : e.status === "pending_review" ? /* @__PURE__ */ _(be, {
214
+ }) : e.status === "pending_review" ? /* @__PURE__ */ _(m, {
210
215
  size: 16,
211
216
  className: "text-status-info-text"
212
217
  }) : e.status === "rejected" ? /* @__PURE__ */ _(xe, {
213
218
  size: 16,
214
219
  className: "text-status-error-text"
215
- }) : e.status === "draft" ? /* @__PURE__ */ _(_e, {
220
+ }) : e.status === "draft" ? /* @__PURE__ */ _(ve, {
216
221
  size: 16,
217
222
  className: "text-status-warning-text"
218
- }) : e.status === "deprecated" ? /* @__PURE__ */ _(he, {
223
+ }) : e.status === "deprecated" ? /* @__PURE__ */ _(ge, {
219
224
  size: 16,
220
225
  className: "text-text-secondary"
221
- }) : /* @__PURE__ */ _(ve, {
226
+ }) : /* @__PURE__ */ _(ye, {
222
227
  size: 16,
223
228
  className: "text-accent-blue"
224
- }), ht = (e, t) => {
225
- z((n) => {
229
+ }), gt = (e, t) => {
230
+ R((n) => {
226
231
  let r = new Set(n);
227
232
  return t ? r.add(e) : r.delete(e), r;
228
233
  });
229
- }, gt = (e) => {
230
- z((t) => {
234
+ }, _t = (e) => {
235
+ R((t) => {
231
236
  let n = new Set(t);
232
237
  return X.forEach((t) => {
233
238
  e ? n.add(t.id) : n.delete(t.id);
234
239
  }), n;
235
240
  });
236
- }, _t = () => z(/* @__PURE__ */ new Set());
237
- return Je && !Y ? /* @__PURE__ */ _(i, {
241
+ }, vt = () => R(/* @__PURE__ */ new Set());
242
+ return Ye && !Y ? /* @__PURE__ */ _(i, {
238
243
  title: y("devportal.versionManagement", "Version Management"),
239
244
  description: y("devportal.versionManagementDescription", "Manage your application versions"),
240
- backLink: `/apps/${C}`,
245
+ backLink: `/apps/${S}`,
241
246
  backLabel: y("devportal.backToApplication", "Back to Application"),
242
247
  children: /* @__PURE__ */ _("div", {
243
248
  className: "flex items-center justify-center py-16",
244
- children: /* @__PURE__ */ _(m, { className: "h-8 w-8 animate-spin text-text-secondary" })
249
+ children: /* @__PURE__ */ _(p, { className: "h-8 w-8 animate-spin text-text-secondary" })
245
250
  })
246
- }) : Ye && !Y ? /* @__PURE__ */ _(i, {
251
+ }) : Xe && !Y ? /* @__PURE__ */ _(i, {
247
252
  title: y("devportal.versionManagement", "Version Management"),
248
253
  description: y("devportal.versionManagementDescription", "Manage your application versions"),
249
- backLink: `/apps/${C}`,
254
+ backLink: `/apps/${S}`,
250
255
  backLabel: y("devportal.backToApplication", "Back to Application"),
251
256
  children: /* @__PURE__ */ _(t, {
252
- icon: /* @__PURE__ */ _(p, {
257
+ icon: /* @__PURE__ */ _(f, {
253
258
  size: 32,
254
259
  className: "text-status-error-text"
255
260
  }),
256
261
  title: y("devportal.failedToLoadVersions", "Failed to load versions"),
257
- description: Ye.message || y("devportal.versionsLoadError", "An error occurred while loading versions")
262
+ description: Xe.message || y("devportal.versionsLoadError", "An error occurred while loading versions")
258
263
  })
259
- }) : /* @__PURE__ */ _(le, {
264
+ }) : /* @__PURE__ */ _(ue, {
260
265
  authOnly: !0,
261
266
  children: /* @__PURE__ */ v(i, {
262
267
  title: y("devportal.versionManagement", "Version Management"),
263
268
  description: y("devportal.versionManagementDescription", "Manage your application versions"),
264
- purpose: W ? y("devportal.versionManagementPurposeWorkflow", "Versions track releases of your workflow. Create a version for each significant change and paste the workflow definition JSON. No zip is needed — the manifest is the workflow.") : G ? y("devportal.versionManagementPurposeNode", "Versions are the releases of your node that users install. Upload a new zip whenever the node implementation changes, and update the manifest if the node's inputs, outputs, or operations change. Bump the version for any change users will see.") : y("devportal.versionManagementPurposeIntegration", "Versions track permission and webhook changes for your integration. No zip or manifest is needed — create a new version whenever you add or change required scopes so users can review and accept the updated permissions."),
265
- backLink: `/apps/${C}`,
269
+ purpose: W ? y("devportal.versionManagementPurposeWorkflow", "Versions track releases of your workflow. Create a version for each significant change and paste the workflow definition JSON. No zip is needed — the manifest is the workflow.") : G ? y("devportal.versionManagementPurposeNode", "Versions are the releases of your node that users install. Upload a new zip whenever the node implementation changes, and update the manifest if the node's inputs, outputs, or operations change. Bump the version for any change users will see.") : K ? y("devportal.versionManagementPurposeManifestOnly", "Versions track releases of this item. Create a version for each significant change and paste the manifest JSON. No zip is needed.") : y("devportal.versionManagementPurposeIntegration", "Versions track permission and webhook changes for your integration. No zip or manifest is needed — create a new version whenever you add or change required scopes so users can review and accept the updated permissions."),
270
+ backLink: `/apps/${S}`,
266
271
  backLabel: y("devportal.backToApplication", "Back to Application"),
267
272
  actions: /* @__PURE__ */ v("button", {
268
273
  onClick: () => {
269
- I(null), k(!0);
274
+ F(null), O(!0);
270
275
  },
271
- disabled: !b,
272
- "aria-disabled": !b,
276
+ disabled: !we,
277
+ "aria-disabled": !we,
273
278
  className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 disabled:opacity-50",
274
- children: [/* @__PURE__ */ _(ye, { size: 16 }), y("devportal.newVersion", "New Version")]
279
+ children: [/* @__PURE__ */ _(be, { size: 16 }), y("devportal.newVersion", "New Version")]
275
280
  }),
276
281
  children: [
277
- Ie && /* @__PURE__ */ v("div", {
282
+ Le && /* @__PURE__ */ v("div", {
278
283
  className: "rounded-lg border border-border-subtle bg-status-error-bg-subtle p-3 flex items-center gap-2 text-sm text-status-error-text",
279
284
  children: [
280
- /* @__PURE__ */ _(p, {
285
+ /* @__PURE__ */ _(f, {
281
286
  size: 16,
282
287
  className: "flex-shrink-0"
283
288
  }),
284
- Ie,
289
+ Le,
285
290
  /* @__PURE__ */ _("button", {
286
- onClick: () => P(null),
291
+ onClick: () => N(null),
287
292
  className: "ml-auto text-status-error-text hover:text-status-error-text",
288
293
  children: y("devportal.dismiss", "Dismiss")
289
294
  })
290
295
  ]
291
296
  }),
292
- Le && /* @__PURE__ */ v("div", {
297
+ Re && /* @__PURE__ */ v("div", {
293
298
  className: "rounded-lg border border-border-subtle bg-status-success-bg-subtle p-3 flex items-center gap-2 text-sm text-status-success-text",
294
299
  children: [
295
- /* @__PURE__ */ _(ge, {
300
+ /* @__PURE__ */ _(_e, {
296
301
  size: 16,
297
302
  className: "flex-shrink-0"
298
303
  }),
299
- Le,
304
+ Re,
300
305
  /* @__PURE__ */ _("button", {
301
- onClick: () => F(null),
306
+ onClick: () => P(null),
302
307
  className: "ml-auto text-status-success-text hover:text-status-success-text",
303
308
  children: y("devportal.dismiss", "Dismiss")
304
309
  })
305
310
  ]
306
311
  }),
307
- K && !q && /* @__PURE__ */ v("div", {
312
+ q && !J && /* @__PURE__ */ v("div", {
308
313
  className: "flex items-start gap-3 rounded-lg border border-status-warning-bg bg-status-warning-bg-subtle px-4 py-3 text-sm text-status-warning-text",
309
- children: [/* @__PURE__ */ _(p, {
314
+ children: [/* @__PURE__ */ _(f, {
310
315
  size: 16,
311
316
  className: "mt-0.5 shrink-0"
312
317
  }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("p", {
@@ -314,12 +319,12 @@ var Ce = () => {
314
319
  children: "Complete your app setup before submitting for review"
315
320
  }), /* @__PURE__ */ _("ul", {
316
321
  className: "mt-1 list-disc pl-4 text-xs opacity-80",
317
- children: J.map((e) => /* @__PURE__ */ _("li", { children: e }, e))
322
+ children: Je.map((e) => /* @__PURE__ */ _("li", { children: e }, e))
318
323
  })] })]
319
324
  }),
320
- K && K.status !== "PUBLISHED" && X.some((e) => e.status === "draft") && /* @__PURE__ */ v("div", {
325
+ q && q.status !== "PUBLISHED" && X.some((e) => e.status === "draft") && /* @__PURE__ */ v("div", {
321
326
  className: "flex items-start gap-3 rounded-lg border border-status-info-bg bg-status-info-bg-subtle px-4 py-3 text-sm text-status-info-text",
322
- children: [/* @__PURE__ */ _(be, {
327
+ children: [/* @__PURE__ */ _(m, {
323
328
  size: 16,
324
329
  className: "mt-0.5 shrink-0"
325
330
  }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("p", {
@@ -342,17 +347,17 @@ var Ce = () => {
342
347
  className: "flex flex-wrap items-center gap-3",
343
348
  children: [/* @__PURE__ */ v("div", {
344
349
  className: "flex items-center gap-2",
345
- children: [/* @__PURE__ */ _(a, {
346
- checked: it,
347
- indeterminate: at,
348
- onChange: gt,
350
+ children: [/* @__PURE__ */ _(se, {
351
+ checked: at,
352
+ indeterminate: ot,
353
+ onChange: _t,
349
354
  ariaLabel: "Select all visible versions"
350
355
  }), /* @__PURE__ */ _("span", {
351
356
  className: "text-sm font-medium",
352
357
  children: y("devportal.selectAllVisible", "Select all visible")
353
358
  })]
354
- }), R.size > 0 && /* @__PURE__ */ _("button", {
355
- onClick: _t,
359
+ }), L.size > 0 && /* @__PURE__ */ _("button", {
360
+ onClick: vt,
356
361
  className: "text-sm text-text-secondary hover:text-text-primary",
357
362
  children: y("devportal.clearSelection", "Clear selection")
358
363
  })]
@@ -361,20 +366,20 @@ var Ce = () => {
361
366
  children: [
362
367
  /* @__PURE__ */ v("span", {
363
368
  className: "rounded-full bg-bg-sunken px-3 py-1 text-sm font-medium text-text-secondary",
364
- children: [R.size, " selected"]
369
+ children: [L.size, " selected"]
365
370
  }),
366
371
  /* @__PURE__ */ v("button", {
367
372
  onClick: () => H("publish"),
368
- disabled: Q.length === 0 || !x || !q,
369
- "aria-disabled": !x || !q,
370
- title: q ? void 0 : J.join(" · "),
373
+ disabled: Q.length === 0 || !b || !J,
374
+ "aria-disabled": !b || !J,
375
+ title: J ? void 0 : Je.join(" · "),
371
376
  className: "rounded-md border border-status-success-bg px-3 py-2 text-sm font-medium text-status-success-text hover:bg-status-success-bg-subtle disabled:cursor-not-allowed disabled:opacity-50",
372
377
  children: [y("devportal.submitForReview", "Submit for Review"), Q.length > 0 ? ` (${Q.length})` : ""]
373
378
  }),
374
379
  /* @__PURE__ */ v("button", {
375
380
  onClick: () => H("deprecate"),
376
- disabled: $.length === 0 || !S,
377
- "aria-disabled": !S,
381
+ disabled: $.length === 0 || !x,
382
+ "aria-disabled": !x,
378
383
  className: "rounded-md border border-status-warning-bg px-3 py-2 text-sm font-medium text-status-warning-text hover:bg-status-warning-bg-subtle disabled:cursor-not-allowed disabled:opacity-50",
379
384
  children: [y("devportal.deprecateSelected", "Deprecate Selected"), $.length > 0 ? ` (${$.length})` : ""]
380
385
  })
@@ -382,24 +387,24 @@ var Ce = () => {
382
387
  })]
383
388
  })
384
389
  }),
385
- X.length > 0 ? /* @__PURE__ */ _(se, {
390
+ X.length > 0 ? /* @__PURE__ */ _(ce, {
386
391
  data: X,
387
392
  keyField: "id",
388
393
  columns: [
389
394
  {
390
395
  key: "select",
391
- header: /* @__PURE__ */ _(a, {
392
- checked: it,
393
- indeterminate: at,
394
- onChange: gt,
396
+ header: /* @__PURE__ */ _(se, {
397
+ checked: at,
398
+ indeterminate: ot,
399
+ onChange: _t,
395
400
  ariaLabel: "Select all visible versions"
396
401
  }),
397
402
  className: "w-12",
398
403
  render: (e) => /* @__PURE__ */ _("div", {
399
404
  onClick: (e) => e.stopPropagation(),
400
- children: /* @__PURE__ */ _(a, {
401
- checked: R.has(e.id),
402
- onChange: (t) => ht(e.id, t),
405
+ children: /* @__PURE__ */ _(se, {
406
+ checked: L.has(e.id),
407
+ onChange: (t) => gt(e.id, t),
403
408
  ariaLabel: `Select version ${e.version}`
404
409
  })
405
410
  })
@@ -410,7 +415,7 @@ var Ce = () => {
410
415
  render: (e) => /* @__PURE__ */ v("div", {
411
416
  className: "flex items-center gap-2",
412
417
  children: [
413
- mt(e),
418
+ ht(e),
414
419
  /* @__PURE__ */ _("span", {
415
420
  className: "font-mono font-medium",
416
421
  children: e.version
@@ -455,7 +460,7 @@ var Ce = () => {
455
460
  {
456
461
  key: "publishedAt",
457
462
  header: y("devportal.published", "Published"),
458
- render: (e) => e.publishedAt ? de(new Date(e.publishedAt), "MMM d, yyyy") : "-"
463
+ render: (e) => e.publishedAt ? fe(new Date(e.publishedAt), "MMM d, yyyy") : "-"
459
464
  },
460
465
  {
461
466
  key: "actions",
@@ -464,11 +469,11 @@ var Ce = () => {
464
469
  render: (e) => /* @__PURE__ */ v("div", {
465
470
  className: "flex flex-wrap gap-2",
466
471
  children: [
467
- (e.status === "draft" || e.status === "rejected") && b && /* @__PURE__ */ _("button", {
472
+ (e.status === "draft" || e.status === "rejected") && we && /* @__PURE__ */ _("button", {
468
473
  className: "inline-flex items-center gap-1 text-xs text-text-secondary hover:text-text-primary hover:underline",
469
474
  onClick: () => {
470
475
  let t = e.manifest ? JSON.stringify(e.manifest, null, 2) : "";
471
- j({
476
+ A({
472
477
  versionId: e.id,
473
478
  version: e.version,
474
479
  hasExistingZip: !!e.packageUrl,
@@ -478,23 +483,23 @@ var Ce = () => {
478
483
  originalManifestJson: t,
479
484
  releaseNotes: e.releaseNotes ?? "",
480
485
  changelog: e.changelog ?? ""
481
- }), O(null), L(null);
486
+ }), D(null), I(null);
482
487
  },
483
488
  children: "Edit"
484
489
  }),
485
- (e.status === "draft" || e.status === "rejected") && K?.status === "PUBLISHED" && /* @__PURE__ */ v("button", {
490
+ (e.status === "draft" || e.status === "rejected") && q?.status === "PUBLISHED" && /* @__PURE__ */ v("button", {
486
491
  className: "inline-flex items-center gap-1 text-xs text-primary hover:underline disabled:opacity-50 disabled:cursor-not-allowed",
487
- disabled: !x || !q,
488
- "aria-disabled": !x || !q,
489
- title: q ? void 0 : J.join(" · "),
490
- onClick: () => dt(e.id),
491
- children: [/* @__PURE__ */ _(be, { size: 11 }), y("devportal.submitForReview", "Submit for Review")]
492
+ disabled: !b || !J,
493
+ "aria-disabled": !b || !J,
494
+ title: J ? void 0 : Je.join(" · "),
495
+ onClick: () => ft(e.id),
496
+ children: [/* @__PURE__ */ _(m, { size: 11 }), y("devportal.submitForReview", "Submit for Review")]
492
497
  }),
493
498
  e.status === "published" && !e.isLatest && /* @__PURE__ */ _("button", {
494
499
  className: "text-xs text-status-warning-text hover:underline disabled:opacity-50",
495
- disabled: !S,
496
- "aria-disabled": !S,
497
- onClick: () => ft(e.id),
500
+ disabled: !x,
501
+ "aria-disabled": !x,
502
+ onClick: () => pt(e.id),
498
503
  children: y("devportal.deprecate", "Deprecate")
499
504
  })
500
505
  ]
@@ -507,48 +512,48 @@ var Ce = () => {
507
512
  description: y("devportal.noVersionsYetDescription", "Create your first version to start distributing your app"),
508
513
  action: /* @__PURE__ */ v("button", {
509
514
  onClick: () => {
510
- I(null), k(!0);
515
+ F(null), O(!0);
511
516
  },
512
517
  className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90",
513
- children: [/* @__PURE__ */ _(ye, { size: 16 }), y("devportal.createVersion", "Create Version")]
518
+ children: [/* @__PURE__ */ _(be, { size: 16 }), y("devportal.createVersion", "Create Version")]
514
519
  })
515
520
  }),
516
- Fe && /* @__PURE__ */ _(o, {
517
- open: Fe,
521
+ Ie && /* @__PURE__ */ _(a, {
522
+ open: Ie,
518
523
  onOpenChange: (e) => {
519
- k(e), e || I(null);
524
+ O(e), e || F(null);
520
525
  },
521
- onConfirm: ot,
526
+ onConfirm: st,
522
527
  title: y("devportal.createNewVersion", "Create New Version"),
523
- confirmLabel: Ze ? y("devportal.creating", "Creating...") : y("devportal.createVersion", "Create Version"),
528
+ confirmLabel: Qe ? y("devportal.creating", "Creating...") : y("devportal.createVersion", "Create Version"),
524
529
  children: /* @__PURE__ */ v("div", {
525
530
  className: "space-y-4",
526
531
  children: [
527
- Re && /* @__PURE__ */ v("div", {
532
+ ze && /* @__PURE__ */ v("div", {
528
533
  className: "rounded-lg border border-status-error-bg bg-status-error-bg-subtle p-3 flex items-center gap-2 text-sm text-status-error-text",
529
- children: [/* @__PURE__ */ _(p, {
534
+ children: [/* @__PURE__ */ _(f, {
530
535
  size: 14,
531
536
  className: "flex-shrink-0"
532
- }), Re]
537
+ }), ze]
533
538
  }),
534
- /* @__PURE__ */ _(ce, {
539
+ /* @__PURE__ */ _(le, {
535
540
  label: y("devportal.versionNumber", "Version Number"),
536
- value: M.version,
537
- onChange: (e) => N({
538
- ...M,
541
+ value: j.version,
542
+ onChange: (e) => M({
543
+ ...j,
539
544
  version: e.target.value
540
545
  }),
541
546
  placeholder: "e.g., 2.2.0",
542
547
  hint: y("devportal.versionHint", "Use semantic versioning (major.minor.patch)"),
543
548
  required: !0
544
549
  }),
545
- W && /* @__PURE__ */ v("div", {
550
+ K && /* @__PURE__ */ v("div", {
546
551
  className: "space-y-1",
547
552
  children: [
548
553
  /* @__PURE__ */ v("label", {
549
554
  className: "text-sm font-medium",
550
555
  children: [
551
- "Workflow Definition (JSON)",
556
+ W ? "Workflow Definition (JSON)" : "Manifest (JSON)",
552
557
  " ",
553
558
  /* @__PURE__ */ _("span", {
554
559
  className: "text-status-error-text",
@@ -559,21 +564,21 @@ var Ce = () => {
559
564
  /* @__PURE__ */ _("textarea", {
560
565
  rows: 10,
561
566
  required: !0,
562
- placeholder: "{\n \"nodes\": [],\n \"edges\": []\n}",
563
- value: M.manifestJson,
564
- onChange: (e) => N({
565
- ...M,
567
+ placeholder: W ? "{\n \"nodes\": [],\n \"edges\": []\n}" : "{\n \"manifestVersion\": \"1.0\",\n \"identity\": { \"name\": \"My Item\", \"version\": \"1.0.0\" }\n}",
568
+ value: j.manifestJson,
569
+ onChange: (e) => M({
570
+ ...j,
566
571
  manifestJson: e.target.value
567
572
  }),
568
573
  className: "w-full rounded-md border bg-transparent px-3 py-2 text-xs font-mono resize-y placeholder:text-text-secondary focus:outline-none focus:ring-1 focus:ring-[var(--color-focus-ring)]"
569
574
  }),
570
- /* @__PURE__ */ v("p", {
575
+ /* @__PURE__ */ _("p", {
571
576
  className: "text-xs text-text-secondary",
572
- children: [
577
+ children: W ? /* @__PURE__ */ v(g, { children: [
573
578
  "Paste the full ",
574
579
  /* @__PURE__ */ _("code", { children: "{nodes, edges}" }),
575
580
  " JSON. Saved as this version's manifest — no zip needed."
576
- ]
581
+ ] }) : "Paste the manifest JSON for this version. No zip needed."
577
582
  })
578
583
  ]
579
584
  }),
@@ -595,41 +600,41 @@ var Ce = () => {
595
600
  className: "flex gap-2 items-center",
596
601
  children: [
597
602
  /* @__PURE__ */ _("input", {
598
- ref: ke,
603
+ ref: Ae,
599
604
  type: "file",
600
605
  accept: ".zip",
601
606
  className: "hidden",
602
- onChange: st
607
+ onChange: ct
603
608
  }),
604
609
  /* @__PURE__ */ _("button", {
605
610
  type: "button",
606
- disabled: T,
607
- onClick: () => ke.current?.click(),
611
+ disabled: w,
612
+ onClick: () => Ae.current?.click(),
608
613
  className: "inline-flex items-center gap-1.5 rounded-md border px-3 py-1.5 text-sm font-medium hover:bg-bg-sunken transition-colors disabled:opacity-50",
609
- children: T ? /* @__PURE__ */ v(g, { children: [
610
- /* @__PURE__ */ _(m, {
614
+ children: w ? /* @__PURE__ */ v(g, { children: [
615
+ /* @__PURE__ */ _(p, {
611
616
  size: 14,
612
617
  className: "animate-spin"
613
618
  }),
614
619
  " ",
615
620
  "Uploading… ",
616
- Oe,
621
+ ke,
617
622
  "%"
618
623
  ] }) : /* @__PURE__ */ v(g, { children: [
619
624
  /* @__PURE__ */ _(h, { size: 14 }),
620
625
  " ",
621
- M.packageUrl ? "Replace zip" : "Upload zip"
626
+ j.packageUrl ? "Replace zip" : "Upload zip"
622
627
  ] })
623
628
  }),
624
- M.packageUrl && !T && /* @__PURE__ */ _("span", {
629
+ j.packageUrl && !w && /* @__PURE__ */ _("span", {
625
630
  className: "text-xs text-status-success-text",
626
631
  children: "✓ Uploaded"
627
632
  })
628
633
  ]
629
634
  }),
630
- E && /* @__PURE__ */ _("p", {
635
+ T && /* @__PURE__ */ _("p", {
631
636
  className: "text-xs text-status-error-text",
632
- children: E
637
+ children: T
633
638
  }),
634
639
  /* @__PURE__ */ _("p", {
635
640
  className: "text-xs text-text-tertiary",
@@ -655,12 +660,12 @@ var Ce = () => {
655
660
  }), /* @__PURE__ */ v("div", {
656
661
  className: "flex items-center gap-2",
657
662
  children: [
658
- Ne && /* @__PURE__ */ v("span", {
663
+ Pe && /* @__PURE__ */ v("span", {
659
664
  className: "text-xs text-status-success-text",
660
- children: ["✓ ", Ne]
665
+ children: ["✓ ", Pe]
661
666
  }),
662
667
  /* @__PURE__ */ _("input", {
663
- ref: Ae,
668
+ ref: je,
664
669
  type: "file",
665
670
  accept: ".json,application/json",
666
671
  className: "hidden",
@@ -668,7 +673,7 @@ var Ce = () => {
668
673
  }),
669
674
  /* @__PURE__ */ v("button", {
670
675
  type: "button",
671
- onClick: () => Ae.current?.click(),
676
+ onClick: () => je.current?.click(),
672
677
  className: "inline-flex items-center gap-1.5 rounded-md border border-border-subtle px-2.5 py-1 text-xs font-medium hover:bg-bg-sunken transition-colors",
673
678
  children: [/* @__PURE__ */ _(h, { size: 12 }), "Upload manifest.json"]
674
679
  })
@@ -678,10 +683,10 @@ var Ce = () => {
678
683
  /* @__PURE__ */ _("textarea", {
679
684
  rows: 5,
680
685
  placeholder: "{\n \"manifestVersion\": \"1.0\",\n \"itemType\": \"node\",\n \"identity\": { \"version\": \"1.0.0\", \"displayName\": \"My Node\" }\n}",
681
- value: M.manifestJson,
686
+ value: j.manifestJson,
682
687
  onChange: (e) => {
683
- D(null), N({
684
- ...M,
688
+ E(null), M({
689
+ ...j,
685
690
  manifestJson: e.target.value
686
691
  });
687
692
  },
@@ -713,9 +718,9 @@ var Ce = () => {
713
718
  }),
714
719
  /* @__PURE__ */ _("input", {
715
720
  type: "text",
716
- value: M.requiredScopes,
717
- onChange: (e) => N({
718
- ...M,
721
+ value: j.requiredScopes,
722
+ onChange: (e) => M({
723
+ ...j,
719
724
  requiredScopes: e.target.value
720
725
  }),
721
726
  placeholder: "e.g. read:contacts, write:messages",
@@ -727,21 +732,21 @@ var Ce = () => {
727
732
  })
728
733
  ]
729
734
  }),
730
- /* @__PURE__ */ _(s, {
735
+ /* @__PURE__ */ _(o, {
731
736
  label: y("devportal.releaseNotes", "Release Notes"),
732
- value: M.releaseNotes,
733
- onChange: (e) => N({
734
- ...M,
737
+ value: j.releaseNotes,
738
+ onChange: (e) => M({
739
+ ...j,
735
740
  releaseNotes: e
736
741
  }),
737
742
  placeholder: y("devportal.releaseNotesPlaceholder", "What changed in this release?"),
738
743
  rows: 3
739
744
  }),
740
- /* @__PURE__ */ _(s, {
745
+ /* @__PURE__ */ _(o, {
741
746
  label: y("devportal.changelog", "Changelog"),
742
- value: M.changelog,
743
- onChange: (e) => N({
744
- ...M,
747
+ value: j.changelog,
748
+ onChange: (e) => M({
749
+ ...j,
745
750
  changelog: e
746
751
  }),
747
752
  placeholder: y("devportal.changelogPlaceholder", "Detailed changelog for this version..."),
@@ -750,13 +755,13 @@ var Ce = () => {
750
755
  ]
751
756
  })
752
757
  }),
753
- B && /* @__PURE__ */ _(o, {
754
- open: !!B,
758
+ z && /* @__PURE__ */ _(a, {
759
+ open: !!z,
755
760
  onOpenChange: (e) => {
756
- e || (Be(null), Ve(""));
761
+ e || (Ve(null), V(""));
757
762
  },
758
- onConfirm: pt,
759
- title: `Reject version ${B.version}`,
763
+ onConfirm: mt,
764
+ title: `Reject version ${z.version}`,
760
765
  confirmLabel: "Reject Version",
761
766
  cancelLabel: y("devportal.cancel", "Cancel"),
762
767
  variant: "danger",
@@ -779,31 +784,31 @@ var Ce = () => {
779
784
  ]
780
785
  }), /* @__PURE__ */ _("textarea", {
781
786
  rows: 3,
782
- value: V,
783
- onChange: (e) => Ve(e.target.value),
787
+ value: B,
788
+ onChange: (e) => V(e.target.value),
784
789
  placeholder: "e.g. Manifest contains disallowed network calls to external domains...",
785
790
  className: "w-full rounded-md border bg-transparent px-3 py-2 text-sm placeholder:text-text-secondary focus:outline-none focus:ring-1 focus:ring-[var(--color-focus-ring)]"
786
791
  })]
787
792
  })]
788
793
  })
789
794
  }),
790
- A && /* @__PURE__ */ _(o, {
791
- open: !!A,
795
+ k && /* @__PURE__ */ _(a, {
796
+ open: !!k,
792
797
  onOpenChange: (e) => {
793
- e || (j(null), O(null), L(null));
798
+ e || (A(null), D(null), I(null));
794
799
  },
795
- onConfirm: ut,
796
- title: `Edit Version ${A.version}`,
797
- confirmLabel: $e ? "Saving…" : "Save Changes",
800
+ onConfirm: dt,
801
+ title: `Edit Version ${k.version}`,
802
+ confirmLabel: et ? "Saving…" : "Save Changes",
798
803
  children: /* @__PURE__ */ v("div", {
799
804
  className: "space-y-4",
800
805
  children: [
801
- ze && /* @__PURE__ */ v("div", {
806
+ Be && /* @__PURE__ */ v("div", {
802
807
  className: "rounded-lg border border-status-error-bg bg-status-error-bg-subtle p-3 flex items-center gap-2 text-sm text-status-error-text",
803
- children: [/* @__PURE__ */ _(p, {
808
+ children: [/* @__PURE__ */ _(f, {
804
809
  size: 14,
805
810
  className: "flex-shrink-0"
806
- }), ze]
811
+ }), Be]
807
812
  }),
808
813
  /* @__PURE__ */ _("div", {
809
814
  className: "rounded-lg border border-status-info-bg bg-status-info-bg-subtle px-3 py-2 text-xs text-status-info-text",
@@ -820,41 +825,41 @@ var Ce = () => {
820
825
  className: "flex gap-2 items-center",
821
826
  children: [
822
827
  /* @__PURE__ */ _("input", {
823
- ref: je,
828
+ ref: Me,
824
829
  type: "file",
825
830
  accept: ".zip",
826
831
  className: "hidden",
827
- onChange: ct
832
+ onChange: lt
828
833
  }),
829
834
  /* @__PURE__ */ _("button", {
830
835
  type: "button",
831
- disabled: T,
832
- onClick: () => je.current?.click(),
836
+ disabled: w,
837
+ onClick: () => Me.current?.click(),
833
838
  className: "inline-flex items-center gap-1.5 rounded-md border px-3 py-1.5 text-sm font-medium hover:bg-bg-sunken transition-colors disabled:opacity-50",
834
- children: T ? /* @__PURE__ */ v(g, { children: [
835
- /* @__PURE__ */ _(m, {
839
+ children: w ? /* @__PURE__ */ v(g, { children: [
840
+ /* @__PURE__ */ _(p, {
836
841
  size: 14,
837
842
  className: "animate-spin"
838
843
  }),
839
844
  " ",
840
845
  "Uploading… ",
841
- Oe,
846
+ ke,
842
847
  "%"
843
- ] }) : /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _(h, { size: 14 }), A.newPackageUrl ? "Replace zip again" : A.hasExistingZip ? "Replace zip" : "Upload zip"] })
848
+ ] }) : /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _(h, { size: 14 }), k.newPackageUrl ? "Replace zip again" : k.hasExistingZip ? "Replace zip" : "Upload zip"] })
844
849
  }),
845
- A.newPackageUrl && !T && /* @__PURE__ */ _("span", {
850
+ k.newPackageUrl && !w && /* @__PURE__ */ _("span", {
846
851
  className: "text-xs text-status-success-text",
847
852
  children: "✓ New zip ready"
848
853
  }),
849
- !A.newPackageUrl && A.hasExistingZip && /* @__PURE__ */ _("span", {
854
+ !k.newPackageUrl && k.hasExistingZip && /* @__PURE__ */ _("span", {
850
855
  className: "text-xs text-text-secondary",
851
856
  children: "Current zip kept"
852
857
  })
853
858
  ]
854
859
  }),
855
- E && /* @__PURE__ */ _("p", {
860
+ T && /* @__PURE__ */ _("p", {
856
861
  className: "text-xs text-status-error-text",
857
- children: E
862
+ children: T
858
863
  })
859
864
  ]
860
865
  }),
@@ -875,20 +880,20 @@ var Ce = () => {
875
880
  }), /* @__PURE__ */ v("div", {
876
881
  className: "flex items-center gap-2",
877
882
  children: [
878
- Pe && /* @__PURE__ */ v("span", {
883
+ Fe && /* @__PURE__ */ v("span", {
879
884
  className: "text-xs text-status-success-text",
880
- children: ["✓ ", Pe]
885
+ children: ["✓ ", Fe]
881
886
  }),
882
887
  /* @__PURE__ */ _("input", {
883
- ref: Me,
888
+ ref: Ne,
884
889
  type: "file",
885
890
  accept: ".json,application/json",
886
891
  className: "hidden",
887
- onChange: lt
892
+ onChange: ut
888
893
  }),
889
894
  /* @__PURE__ */ v("button", {
890
895
  type: "button",
891
- onClick: () => Me.current?.click(),
896
+ onClick: () => Ne.current?.click(),
892
897
  className: "inline-flex items-center gap-1.5 rounded-md border border-border-subtle px-2.5 py-1 text-xs font-medium hover:bg-bg-sunken transition-colors",
893
898
  children: [/* @__PURE__ */ _(h, { size: 12 }), " Upload manifest.json"]
894
899
  })
@@ -897,9 +902,9 @@ var Ce = () => {
897
902
  }), /* @__PURE__ */ _("textarea", {
898
903
  rows: 5,
899
904
  placeholder: "{\n \"manifestVersion\": \"1.0\",\n \"itemType\": \"node\",\n \"identity\": { \"version\": \"1.0.0\", \"displayName\": \"My Node\" }\n}",
900
- value: A.manifestJson,
905
+ value: k.manifestJson,
901
906
  onChange: (e) => {
902
- O(null), j((t) => t && {
907
+ D(null), A((t) => t && {
903
908
  ...t,
904
909
  manifestJson: e.target.value
905
910
  });
@@ -907,12 +912,12 @@ var Ce = () => {
907
912
  className: "w-full rounded-md border bg-transparent px-3 py-2 text-xs font-mono resize-y placeholder:text-text-secondary focus:outline-none focus:ring-1 focus:ring-[var(--color-focus-ring)]"
908
913
  })]
909
914
  }),
910
- W && /* @__PURE__ */ v("div", {
915
+ K && /* @__PURE__ */ v("div", {
911
916
  className: "space-y-1",
912
917
  children: [/* @__PURE__ */ v("label", {
913
918
  className: "text-sm font-medium",
914
919
  children: [
915
- "Workflow Definition (JSON)",
920
+ W ? "Workflow Definition (JSON)" : "Manifest (JSON)",
916
921
  " ",
917
922
  /* @__PURE__ */ _("span", {
918
923
  className: "text-xs font-normal text-text-secondary",
@@ -921,29 +926,29 @@ var Ce = () => {
921
926
  ]
922
927
  }), /* @__PURE__ */ _("textarea", {
923
928
  rows: 10,
924
- placeholder: "{\n \"nodes\": [],\n \"edges\": []\n}",
925
- value: A.manifestJson,
926
- onChange: (e) => j((t) => t && {
929
+ placeholder: W ? "{\n \"nodes\": [],\n \"edges\": []\n}" : "{\n \"manifestVersion\": \"1.0\",\n \"identity\": { \"name\": \"My Item\", \"version\": \"1.0.0\" }\n}",
930
+ value: k.manifestJson,
931
+ onChange: (e) => A((t) => t && {
927
932
  ...t,
928
933
  manifestJson: e.target.value
929
934
  }),
930
935
  className: "w-full rounded-md border bg-transparent px-3 py-2 text-xs font-mono resize-y placeholder:text-text-secondary focus:outline-none focus:ring-1 focus:ring-[var(--color-focus-ring)]"
931
936
  })]
932
937
  }),
933
- /* @__PURE__ */ _(s, {
938
+ /* @__PURE__ */ _(o, {
934
939
  label: y("devportal.releaseNotes", "Release Notes"),
935
- value: A.releaseNotes,
936
- onChange: (e) => j((t) => t && {
940
+ value: k.releaseNotes,
941
+ onChange: (e) => A((t) => t && {
937
942
  ...t,
938
943
  releaseNotes: e
939
944
  }),
940
945
  placeholder: y("devportal.releaseNotesPlaceholder", "What changed in this release?"),
941
946
  rows: 3
942
947
  }),
943
- /* @__PURE__ */ _(s, {
948
+ /* @__PURE__ */ _(o, {
944
949
  label: y("devportal.changelog", "Changelog"),
945
- value: A.changelog,
946
- onChange: (e) => j((t) => t && {
950
+ value: k.changelog,
951
+ onChange: (e) => A((t) => t && {
947
952
  ...t,
948
953
  changelog: e
949
954
  }),
@@ -953,16 +958,16 @@ var Ce = () => {
953
958
  ]
954
959
  })
955
960
  }),
956
- /* @__PURE__ */ _(o, {
961
+ /* @__PURE__ */ _(a, {
957
962
  open: Ue === "publish",
958
963
  onOpenChange: (e) => {
959
964
  e || H(null);
960
965
  },
961
966
  onConfirm: async () => {
962
967
  if (Q.length === 0) return;
963
- P(null);
964
- let e = await Promise.allSettled(Q.map((e) => et({ variables: { id: e.id } }))), t = e.filter((e) => e.status === "fulfilled").length, n = e.length - t;
965
- F(`Published ${t} version${t === 1 ? "" : "s"}${n > 0 ? ` • ${n} failed` : ""}`), _t(), H(null);
968
+ N(null);
969
+ let e = await Promise.allSettled(Q.map((e) => tt({ variables: { id: e.id } }))), t = e.filter((e) => e.status === "fulfilled").length, n = e.length - t;
970
+ P(`Published ${t} version${t === 1 ? "" : "s"}${n > 0 ? ` • ${n} failed` : ""}`), vt(), H(null);
966
971
  },
967
972
  title: y("devportal.submitSelectedVersions", "Submit selected versions for review"),
968
973
  description: `Submit ${Q.length} selected version${Q.length === 1 ? "" : "s"} for platform review?`,
@@ -970,16 +975,16 @@ var Ce = () => {
970
975
  cancelLabel: y("devportal.cancel", "Cancel"),
971
976
  variant: "success"
972
977
  }),
973
- /* @__PURE__ */ _(o, {
978
+ /* @__PURE__ */ _(a, {
974
979
  open: Ue === "deprecate",
975
980
  onOpenChange: (e) => {
976
981
  e || H(null);
977
982
  },
978
983
  onConfirm: async () => {
979
984
  if ($.length === 0) return;
980
- P(null);
981
- let e = await Promise.allSettled($.map((e) => tt({ variables: { id: e.id } }))), t = e.filter((e) => e.status === "fulfilled").length, n = e.length - t;
982
- F(`Deprecated ${t} version${t === 1 ? "" : "s"}${n > 0 ? ` • ${n} failed` : ""}`), _t(), H(null);
985
+ N(null);
986
+ let e = await Promise.allSettled($.map((e) => nt({ variables: { id: e.id } }))), t = e.filter((e) => e.status === "fulfilled").length, n = e.length - t;
987
+ P(`Deprecated ${t} version${t === 1 ? "" : "s"}${n > 0 ? ` • ${n} failed` : ""}`), vt(), H(null);
983
988
  },
984
989
  title: y("devportal.deprecateSelectedVersions", "Deprecate selected versions"),
985
990
  description: `${y("devportal.deprecate", "Deprecate")} ${$.length} selected version${$.length === 1 ? "" : "s"}? ${y("devportal.deprecateVersionsWarning", "Deprecated versions remain visible but should no longer be promoted.")}`,