@burdenoff/microfe-devportal 2026.1026.3 → 2026.1031.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,27 +3,27 @@ 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, usePublishApplicationVersionToOrganizationMutation as ie, useRejectApplicationVersionMutation as ae, useUpdateApplicationVersionMutation as oe } from "../../generated/global-operations.js";
4
4
  import { PageLayout as se } from "../components/PageLayout.js";
5
5
  import { StatusBadge as ce } from "../components/StatusBadge.js";
6
- import { SelectionCheckbox as le } from "../components/SelectionCheckbox.js";
7
- import { DataTable as ue } from "../components/DataTable.js";
8
- import { InputField as de } from "../components/FormField.js";
9
- import { ConfirmDialog as i } from "../components/ConfirmDialog.js";
10
- import { PermissionGuard as fe } from "../components/PermissionGuard.js";
11
- import { MarkdownEditor as a } from "../components/MarkdownEditor.js";
12
- import { ManifestViewer as pe } from "../components/ManifestViewer.js";
13
- import { PackageValidationPanel as me, readPackageValidationState as o } from "../components/PackageValidationPanel.js";
6
+ import { SelectionCheckbox as i } from "../components/SelectionCheckbox.js";
7
+ import { DataTable as le } from "../components/DataTable.js";
8
+ import { InputField as ue } from "../components/FormField.js";
9
+ import { ConfirmDialog as a } from "../components/ConfirmDialog.js";
10
+ import { PermissionGuard as de } from "../components/PermissionGuard.js";
11
+ import { MarkdownEditor as o } from "../components/MarkdownEditor.js";
12
+ import { ManifestViewer as fe } from "../components/ManifestViewer.js";
13
+ import { PackageValidationPanel as pe, readPackageValidationState as s } from "../components/PackageValidationPanel.js";
14
14
  import "../components/index.js";
15
- import { useDevportalPermission as s } from "../hooks/usePermission.js";
15
+ import { useDevportalPermission as me } from "../hooks/usePermission.js";
16
16
  import "../hooks/index.js";
17
- import { DEVPORTAL_PERMISSIONS as c } from "../constants/permissions.js";
18
- import he from "../../node_modules/date-fns/format.js";
19
- import { usePackageUpload as ge } from "../hooks/usePackageUpload.js";
20
- import { useCallback as l, useEffect as _e, useMemo as u, useRef as d, useState as f } from "react";
21
- import { AlertCircle as p, Archive as ve, Building2 as ye, CheckCircle as be, Clock as xe, Loader2 as Se, Package as Ce, Plus as we, Send as m, Upload as h, XCircle as Te } from "lucide-react";
22
- import { useParams as Ee } from "react-router";
23
- import { Fragment as g, jsx as _, jsxs as v } from "react/jsx-runtime";
24
- import { useI18n as De } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
17
+ import { DEVPORTAL_PERMISSIONS as he } from "../constants/permissions.js";
18
+ import ge from "../../node_modules/date-fns/format.js";
19
+ import { usePackageUpload as _e } from "../hooks/usePackageUpload.js";
20
+ import { useCallback as c, useEffect as ve, useMemo as l, useRef as u, useState as d } from "react";
21
+ import { AlertCircle as f, Archive as ye, Building2 as be, CheckCircle as xe, Clock as Se, Loader2 as Ce, Package as we, Plus as Te, Rocket as Ee, Send as p, Upload as m, XCircle as De } from "lucide-react";
22
+ import { useParams as Oe } from "react-router";
23
+ import { Fragment as h, jsx as g, jsxs as _ } from "react/jsx-runtime";
24
+ import { useI18n as ke } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
25
25
  //#region src/devportal/pages/ApplicationVersionsPage.tsx
26
- var y = (e) => {
26
+ var v = (e) => {
27
27
  if (e.trim()) try {
28
28
  let t = JSON.parse(e);
29
29
  if (typeof t.nodeVersion == "string" && t.nodeVersion.trim()) return t.nodeVersion.trim();
@@ -32,16 +32,16 @@ var y = (e) => {
32
32
  if (typeof t.version == "string" && t.version.trim()) return t.version.trim();
33
33
  } catch {}
34
34
  };
35
- function Oe(e) {
35
+ function Ae(e) {
36
36
  if (typeof e != "object" || !e) return !1;
37
37
  let t = e.organizationPublish;
38
38
  return typeof t == "object" && !!t;
39
39
  }
40
- var ke = () => {
41
- let { t: ke } = De(), b = (e, t) => {
42
- let n = ke(e);
40
+ var je = () => {
41
+ let { t: je } = ke(), y = (e, t) => {
42
+ let n = je(e);
43
43
  return n === e ? t : n;
44
- }, { allowed: Ae } = s(c.APP_VERSION_CREATE), { allowed: x } = s(c.APP_VERSION_PUBLISH), { allowed: S } = s(c.APP_VERSION_DEPRECATE), { appId: C } = Ee(), { workspacesGatewayUrl: je, authToken: Me, workspaceId: w, getWorkspaceToken: Ne } = e(), { upload: T, uploading: E, progress: Pe, error: D } = ge(je, Me, w, Ne), Fe = d(null), Ie = d(null), Le = d(null), Re = d(null), [ze, Be] = f(null), [Ve, O] = f(null), [He, k] = f(!1), [A, j] = f(null), [M, N] = f({
44
+ }, { allowed: Me } = me(he.APP_VERSION_CREATE), { allowed: b } = me(he.APP_VERSION_PUBLISH), { allowed: x } = me(he.APP_VERSION_DEPRECATE), { appId: S } = Oe(), { workspacesGatewayUrl: Ne, authToken: Pe, workspaceId: C, getWorkspaceToken: Fe, navigate: Ie, basePath: Le } = e(), { upload: w, uploading: T, progress: Re, error: E } = _e(Ne, Pe, C, Fe), ze = u(null), Be = u(null), Ve = u(null), He = u(null), [Ue, We] = d(null), [Ge, D] = d(null), [Ke, O] = d(!1), [k, A] = d(null), [j, M] = d({
45
45
  version: "",
46
46
  releaseNotes: "",
47
47
  changelog: "",
@@ -49,91 +49,94 @@ var ke = () => {
49
49
  packageSize: "",
50
50
  manifestJson: "",
51
51
  requiredScopes: ""
52
- }), [Ue, P] = f(null), [We, F] = f(null), [Ge, I] = f(null), [Ke, L] = f(null), [R, qe] = f(/* @__PURE__ */ new Set()), [z, Je] = f(null), [Ye, Xe] = f(""), Ze = l((e) => {
52
+ }), [qe, N] = d(null), [Je, P] = d(null), [Ye, F] = d(null), [Xe, I] = d(null), [L, R] = d(/* @__PURE__ */ new Set()), [z, Ze] = d(null), [Qe, $e] = d(""), et = c((e) => {
53
53
  let t = e.target.files?.[0];
54
54
  if (!t) return;
55
55
  let n = new FileReader();
56
56
  n.onload = (e) => {
57
57
  let n = e.target?.result;
58
58
  if (typeof n == "string") {
59
- let e = y(n);
60
- N((t) => ({
59
+ let e = v(n);
60
+ M((t) => ({
61
61
  ...t,
62
62
  manifestJson: n,
63
63
  ...e ? { version: e } : {}
64
- })), Be(t.name);
64
+ })), We(t.name);
65
65
  }
66
66
  }, n.readAsText(t), e.target.value = "";
67
- }, []), [Qe, B] = f(null), [$e, et] = f(null), { data: V } = te({
68
- variables: { id: C ?? "" },
69
- skip: !C,
67
+ }, []), [tt, B] = d(null), [nt, rt] = d(null), { data: V } = te({
68
+ variables: { id: S ?? "" },
69
+ skip: !S,
70
70
  fetchPolicy: "cache-first"
71
71
  }), H = V?.application?.appType === "WORKFLOW", U = V?.application?.appType === "NODE", W = [
72
72
  "WORKFLOW",
73
73
  "PARSER",
74
74
  "WIDGET",
75
75
  "DASHBOARD"
76
- ].includes(V?.application?.appType ?? ""), tt = !W && !U, nt = U && V?.application?.visibility === "PRIVATE", G = V?.application, rt = G?.pricingDetails ?? {}, it = G?.pricingType === "FREE" || G?.pricingType === "PAID" && typeof rt.price == "number" && rt.price > 0, at = !!G?.shortDescription?.trim() && !!G?.privacyPolicyUrl?.trim() && !!G?.termsOfServiceUrl?.trim(), K = it && at, ot = [...at ? [] : ["Complete your store listing (short description, privacy policy, terms of service)"], ...it ? [] : ["Set pricing in the Pricing tab"]];
77
- _e(() => {
76
+ ].includes(V?.application?.appType ?? ""), it = !W && !U, at = U && V?.application?.visibility === "PRIVATE", G = V?.application, ot = G?.pricingDetails ?? {}, st = G?.pricingType === "FREE" || G?.pricingType === "PAID" && typeof ot.price == "number" && ot.price > 0, ct = !!G?.shortDescription?.trim() && !!G?.privacyPolicyUrl?.trim() && !!G?.termsOfServiceUrl?.trim(), K = st && ct, lt = [...ct ? [] : ["Complete your store listing (short description, privacy policy, terms of service)"], ...st ? [] : ["Set pricing in the Pricing tab"]];
77
+ ve(() => {
78
78
  let e = V?.application?.name;
79
- if (!C || !e) return;
79
+ if (!S || !e) return;
80
80
  let t = window.__breadcrumbRegistry;
81
- return t?.register(C, e), () => t?.unregister(C);
82
- }, [C, V?.application?.name]);
83
- let { data: q, loading: st, error: ct } = ne({
84
- variables: { applicationId: C },
85
- skip: !C,
81
+ return t?.register(S, e), () => t?.unregister(S);
82
+ }, [S, V?.application?.name]);
83
+ let { data: q, loading: ut, error: dt } = ne({
84
+ variables: { applicationId: S },
85
+ skip: !S,
86
86
  fetchPolicy: "cache-and-network"
87
- }), [lt, { loading: ut }] = r({ refetchQueries: ["GetApplicationVersions"] }), [dt, { loading: ft }] = oe({ refetchQueries: ["GetApplicationVersions"] }), [pt] = re({ refetchQueries: ["GetApplicationVersions"] }), [mt, { loading: ht }] = ie({ refetchQueries: ["GetApplicationVersions", "GetApplication"] }), [gt] = ee({ refetchQueries: ["GetApplicationVersions"] }), [_t] = n({ refetchQueries: ["GetApplicationVersions"] }), [vt] = ae({ refetchQueries: ["GetApplicationVersions"] }), J = u(() => q?.application?.versions?.edges?.map((e) => e.node) ?? [], [q?.application?.versions]), Y = u(() => J.filter((e) => R.has(e.id)), [J, R]), X = u(() => Y.filter((e) => e.status === "draft" || e.status === "rejected"), [Y]), Z = u(() => J.some((e) => e.status === "pending_review"), [J]), Q = u(() => Y.filter((e) => e.status?.toUpperCase() === "PUBLISHED" && !e.isLatest), [Y]), $ = J.length > 0 && J.every((e) => R.has(e.id)), yt = J.some((e) => R.has(e.id)) && !$, bt = async () => {
88
- if (!C || !M.version.trim()) return;
89
- I(null);
87
+ }), [ft, { loading: pt }] = r({ refetchQueries: ["GetApplicationVersions"] }), [mt, { loading: ht }] = oe({ refetchQueries: ["GetApplicationVersions"] }), [gt] = re({ refetchQueries: ["GetApplicationVersions"] }), [_t, { loading: vt }] = ie({ refetchQueries: ["GetApplicationVersions", "GetApplication"] }), [yt] = ee({ refetchQueries: ["GetApplicationVersions"] }), [bt] = n({ refetchQueries: ["GetApplicationVersions"] }), [xt] = ae({ refetchQueries: ["GetApplicationVersions"] }), J = l(() => q?.application?.versions?.edges?.map((e) => e.node) ?? [], [q?.application?.versions]), Y = l(() => J.filter((e) => L.has(e.id)), [J, L]), X = l(() => Y.filter((e) => e.status === "draft" || e.status === "rejected"), [Y]), Z = l(() => J.some((e) => e.status === "pending_review"), [J]), Q = l(() => Y.filter((e) => e.status?.toUpperCase() === "PUBLISHED" && !e.isLatest), [Y]), St = J.length > 0 && J.every((e) => L.has(e.id)), Ct = J.some((e) => L.has(e.id)) && !St, wt = (e) => {
88
+ Ie?.(`${Le}/apps/${S}/versions/${e}/lifecycle`);
89
+ }, Tt = async () => {
90
+ if (!S || !j.version.trim()) return;
91
+ F(null);
90
92
  let e;
91
93
  if (W) {
92
- if (!M.manifestJson.trim()) {
93
- I(H ? "Workflow Definition (JSON) is required — paste the {nodes, edges} object." : "Manifest (JSON) is required.");
94
+ if (!j.manifestJson.trim()) {
95
+ F(H ? "Workflow Definition (JSON) is required — paste the {nodes, edges} object." : "Manifest (JSON) is required.");
94
96
  return;
95
97
  }
96
98
  try {
97
- e = JSON.parse(M.manifestJson);
99
+ e = JSON.parse(j.manifestJson);
98
100
  } catch {
99
- I(H ? "Invalid JSON in Workflow Definition — please check your input." : "Invalid JSON in Manifest — please check your input.");
101
+ F(H ? "Invalid JSON in Workflow Definition — please check your input." : "Invalid JSON in Manifest — please check your input.");
100
102
  return;
101
103
  }
102
104
  } else if (U) {
103
- if (!M.packageUrl) {
104
- I("Package zip is required for Node versions — upload a .zip file before creating.");
105
+ if (!j.packageUrl) {
106
+ F("Package zip is required for Node versions — upload a .zip file before creating.");
105
107
  return;
106
108
  }
107
- if (!M.manifestJson.trim()) {
108
- I("manifest.json is required for Node versions — upload or paste your manifest before creating.");
109
+ if (!j.manifestJson.trim()) {
110
+ F("manifest.json is required for Node versions — upload or paste your manifest before creating.");
109
111
  return;
110
112
  }
111
113
  try {
112
- e = JSON.parse(M.manifestJson);
114
+ e = JSON.parse(j.manifestJson);
113
115
  } catch {
114
- I("Invalid JSON in manifest — please check your input.");
116
+ F("Invalid JSON in manifest — please check your input.");
115
117
  return;
116
118
  }
117
- } else if (M.manifestJson.trim()) try {
118
- e = JSON.parse(M.manifestJson);
119
+ } else if (j.manifestJson.trim()) try {
120
+ e = JSON.parse(j.manifestJson);
119
121
  } catch {
120
- I("Invalid JSON in manifest — please check your input.");
122
+ F("Invalid JSON in manifest — please check your input.");
121
123
  return;
122
124
  }
123
- let t = tt && M.requiredScopes.trim() ? M.requiredScopes.split(",").map((e) => e.trim()).filter(Boolean) : void 0;
125
+ let t = it && j.requiredScopes.trim() ? j.requiredScopes.split(",").map((e) => e.trim()).filter(Boolean) : void 0;
124
126
  try {
125
- await lt({ variables: {
126
- applicationId: C,
127
+ let n = await ft({ variables: {
128
+ applicationId: S,
127
129
  input: {
128
- version: M.version,
129
- releaseNotes: M.releaseNotes || void 0,
130
- changelog: M.changelog || void 0,
131
- packageUrl: M.packageUrl || void 0,
132
- packageSize: M.packageSize || void 0,
130
+ version: j.version,
131
+ releaseNotes: j.releaseNotes || void 0,
132
+ changelog: j.changelog || void 0,
133
+ packageUrl: j.packageUrl || void 0,
134
+ packageSize: j.packageSize || void 0,
133
135
  manifest: e,
134
136
  requiredScopes: t
135
137
  }
136
- } }), k(!1), Be(null), N({
138
+ } });
139
+ O(!1), We(null), M({
137
140
  version: "",
138
141
  releaseNotes: "",
139
142
  changelog: "",
@@ -141,411 +144,423 @@ var ke = () => {
141
144
  packageSize: "",
142
145
  manifestJson: "",
143
146
  requiredScopes: ""
144
- }), F(b("devportal.versionCreatedSuccess", "Version created successfully"));
147
+ }), P(y("devportal.versionCreatedSuccess", "Version created successfully"));
148
+ let r = n.data?.createApplicationVersion?.id;
149
+ U && r && wt(r);
145
150
  } catch (e) {
146
- P(e instanceof Error ? e.message : b("devportal.versionCreateFailed", "Failed to create version"));
151
+ N(e instanceof Error ? e.message : y("devportal.versionCreateFailed", "Failed to create version"));
147
152
  }
148
- }, xt = l(async (e) => {
153
+ }, Et = c(async (e) => {
149
154
  let t = e.target.files?.[0];
150
155
  if (t) {
151
156
  e.target.value = "";
152
157
  try {
153
- let e = await T(t);
154
- N((n) => ({
158
+ let e = await w(t);
159
+ M((n) => ({
155
160
  ...n,
156
161
  packageUrl: e.downloadUrl,
157
162
  packageSize: String(t.size)
158
163
  }));
159
164
  } catch {}
160
165
  }
161
- }, [T]), St = l(async (e) => {
166
+ }, [w]), Dt = c(async (e) => {
162
167
  let t = e.target.files?.[0];
163
168
  if (t) {
164
169
  e.target.value = "";
165
170
  try {
166
- let e = await T(t);
167
- j((n) => n && {
171
+ let e = await w(t);
172
+ A((n) => n && {
168
173
  ...n,
169
174
  newPackageUrl: e.downloadUrl,
170
175
  newPackageSize: String(t.size)
171
176
  });
172
177
  } catch {}
173
178
  }
174
- }, [T]), Ct = l((e) => {
179
+ }, [w]), Ot = c((e) => {
175
180
  let t = e.target.files?.[0];
176
181
  if (!t) return;
177
182
  let n = new FileReader();
178
183
  n.onload = (e) => {
179
184
  let n = e.target?.result;
180
- typeof n == "string" && (j((e) => e && {
185
+ typeof n == "string" && (A((e) => e && {
181
186
  ...e,
182
187
  manifestJson: n
183
- }), O(t.name));
188
+ }), D(t.name));
184
189
  }, n.readAsText(t), e.target.value = "";
185
- }, []), wt = async () => {
186
- if (!A) return;
187
- L(null);
188
- let e = A.manifestJson.trim() !== A.originalManifestJson.trim(), t;
189
- if (e && A.manifestJson.trim()) try {
190
- t = JSON.parse(A.manifestJson);
190
+ }, []), kt = async () => {
191
+ if (!k) return;
192
+ I(null);
193
+ let e = k.manifestJson.trim() !== k.originalManifestJson.trim(), t;
194
+ if (e && k.manifestJson.trim()) try {
195
+ t = JSON.parse(k.manifestJson);
191
196
  } catch {
192
- L("Invalid JSON in manifest — please check your input.");
197
+ I("Invalid JSON in manifest — please check your input.");
193
198
  return;
194
199
  }
195
200
  let n = {};
196
- 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);
201
+ 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);
197
202
  try {
198
- await dt({ variables: {
199
- id: A.versionId,
203
+ await mt({ variables: {
204
+ id: k.versionId,
200
205
  input: n
201
- } }), j(null), O(null), F(b("devportal.versionUpdatedSuccess", "Version updated successfully"));
206
+ } }), A(null), D(null), P(y("devportal.versionUpdatedSuccess", "Version updated successfully"));
202
207
  } catch (e) {
203
- P(e instanceof Error ? e.message : b("devportal.versionUpdateFailed", "Failed to update version"));
208
+ N(e instanceof Error ? e.message : y("devportal.versionUpdateFailed", "Failed to update version"));
204
209
  }
205
- }, Tt = async (e) => {
206
- P(null), F(null);
210
+ }, At = async (e) => {
211
+ N(null), P(null);
207
212
  try {
208
- await pt({ variables: { id: e } }), F(b("devportal.versionSubmittedSuccess", "Version submitted for review — you'll be notified when approved"));
213
+ let t = await gt({ variables: { id: e } });
214
+ if (t.error || !t.data?.publishApplicationVersion) throw t.error ?? Error(y("devportal.versionPublishFailed", "Failed to submit version for review"));
215
+ P(y("devportal.versionSubmittedSuccess", "Version submitted for review — you'll be notified when approved"));
209
216
  } catch (e) {
210
- P(e instanceof Error ? e.message : b("devportal.versionPublishFailed", "Failed to submit version for review"));
217
+ N(e instanceof Error ? e.message : y("devportal.versionPublishFailed", "Failed to submit version for review"));
211
218
  }
212
- }, Et = async () => {
213
- let e = $e;
214
- if (et(null), !(!e || !w)) {
215
- P(null), F(null);
219
+ }, jt = async () => {
220
+ let e = nt;
221
+ if (rt(null), !(!e || !C)) {
222
+ N(null), P(null);
216
223
  try {
217
- await mt({ variables: {
224
+ let t = await _t({ variables: {
218
225
  id: e.id,
219
- workspaceId: w
220
- } }), F(b("devportal.versionPublishedToOrganizationSuccess", "Version published to your organization. Workspace admins in your organization can now install it."));
226
+ workspaceId: C
227
+ } });
228
+ if (t.error || !t.data?.publishApplicationVersionToOrganization) throw t.error ?? Error(y("devportal.versionPublishToOrganizationFailed", "Failed to publish the version to your organization"));
229
+ P(y("devportal.versionPublishedToOrganizationSuccess", "Version published to your organization. Workspace admins in your organization can now install it."));
221
230
  } catch (e) {
222
- P(e instanceof Error ? e.message : b("devportal.versionPublishToOrganizationFailed", "Failed to publish the version to your organization"));
231
+ N(e instanceof Error ? e.message : y("devportal.versionPublishToOrganizationFailed", "Failed to publish the version to your organization"));
223
232
  }
224
233
  }
225
- }, Dt = async (e) => {
226
- P(null), F(null);
234
+ }, Mt = async (e) => {
235
+ N(null), P(null);
227
236
  try {
228
- await gt({ variables: { id: e } }), F(b("devportal.versionDeprecatedSuccess", "Version deprecated successfully"));
237
+ await yt({ variables: { id: e } }), P(y("devportal.versionDeprecatedSuccess", "Version deprecated successfully"));
229
238
  } catch (e) {
230
- P(e instanceof Error ? e.message : b("devportal.versionDeprecateFailed", "Failed to deprecate version"));
239
+ N(e instanceof Error ? e.message : y("devportal.versionDeprecateFailed", "Failed to deprecate version"));
231
240
  }
232
- }, Ot = async () => {
233
- if (!(!z || !Ye.trim())) {
234
- P(null), F(null);
241
+ }, Nt = async () => {
242
+ if (!(!z || !Qe.trim())) {
243
+ N(null), P(null);
235
244
  try {
236
- await vt({ variables: {
245
+ await xt({ variables: {
237
246
  id: z.versionId,
238
- reason: Ye
239
- } }), F(b("devportal.versionRejectedSuccess", "Version rejected — developer has been notified")), Je(null), Xe("");
247
+ reason: Qe
248
+ } }), P(y("devportal.versionRejectedSuccess", "Version rejected — developer has been notified")), Ze(null), $e("");
240
249
  } catch (e) {
241
- P(e instanceof Error ? e.message : b("devportal.versionRejectFailed", "Failed to reject version"));
250
+ N(e instanceof Error ? e.message : y("devportal.versionRejectFailed", "Failed to reject version"));
242
251
  }
243
252
  }
244
- }, kt = (e) => e.status === "published" && e.isLatest ? /* @__PURE__ */ _(be, {
253
+ }, Pt = (e) => e.status === "published" && e.isLatest ? /* @__PURE__ */ g(xe, {
245
254
  size: 16,
246
255
  className: "text-status-success-text"
247
- }) : e.status === "pending_review" ? /* @__PURE__ */ _(m, {
256
+ }) : e.status === "pending_review" ? /* @__PURE__ */ g(p, {
248
257
  size: 16,
249
258
  className: "text-status-info-text"
250
- }) : e.status === "rejected" ? /* @__PURE__ */ _(Te, {
259
+ }) : e.status === "rejected" ? /* @__PURE__ */ g(De, {
251
260
  size: 16,
252
261
  className: "text-status-error-text"
253
- }) : e.status === "draft" ? /* @__PURE__ */ _(xe, {
262
+ }) : e.status === "draft" ? /* @__PURE__ */ g(Se, {
254
263
  size: 16,
255
264
  className: "text-status-warning-text"
256
- }) : e.status === "deprecated" ? /* @__PURE__ */ _(ve, {
265
+ }) : e.status === "deprecated" ? /* @__PURE__ */ g(ye, {
257
266
  size: 16,
258
267
  className: "text-text-secondary"
259
- }) : /* @__PURE__ */ _(Ce, {
268
+ }) : /* @__PURE__ */ g(we, {
260
269
  size: 16,
261
270
  className: "text-accent-blue"
262
- }), At = (e, t) => {
263
- qe((n) => {
271
+ }), Ft = (e, t) => {
272
+ R((n) => {
264
273
  let r = new Set(n);
265
274
  return t ? r.add(e) : r.delete(e), r;
266
275
  });
267
- }, jt = (e) => {
268
- qe((t) => {
276
+ }, It = (e) => {
277
+ R((t) => {
269
278
  let n = new Set(t);
270
279
  return J.forEach((t) => {
271
280
  e ? n.add(t.id) : n.delete(t.id);
272
281
  }), n;
273
282
  });
274
- }, Mt = () => qe(/* @__PURE__ */ new Set()), Nt = async () => {
283
+ }, $ = () => R(/* @__PURE__ */ new Set()), Lt = async () => {
275
284
  if (X.length === 0) return;
276
- P(null);
277
- let e = await Promise.allSettled(X.map((e) => pt({ variables: { id: e.id } }))), t = e.filter((e) => e.status === "fulfilled").length, n = e.length - t;
278
- F(`Published ${t} version${t === 1 ? "" : "s"}${n > 0 ? ` • ${n} failed` : ""}`), Mt(), B(null);
279
- }, Pt = async () => {
285
+ N(null);
286
+ let e = await Promise.allSettled(X.map((e) => gt({ variables: { id: e.id } }))), t = e.filter((e) => e.status === "fulfilled").length, n = e.length - t;
287
+ P(`Published ${t} version${t === 1 ? "" : "s"}${n > 0 ? ` • ${n} failed` : ""}`), $(), B(null);
288
+ }, Rt = async () => {
280
289
  if (Q.length === 0) return;
281
- P(null);
282
- let e = await Promise.allSettled(Q.map((e) => gt({ variables: { id: e.id } }))), t = e.filter((e) => e.status === "fulfilled").length, n = e.length - t;
283
- F(`Deprecated ${t} version${t === 1 ? "" : "s"}${n > 0 ? ` • ${n} failed` : ""}`), Mt(), B(null);
284
- }, Ft = y(M.manifestJson);
285
- return st && !q ? /* @__PURE__ */ _(se, {
286
- title: b("devportal.versionManagement", "Version Management"),
287
- description: b("devportal.versionManagementDescription", "Manage your application versions"),
288
- backLink: `/apps/${C}`,
289
- backLabel: b("devportal.backToApplication", "Back to Application"),
290
- children: /* @__PURE__ */ _("div", {
290
+ N(null);
291
+ let e = await Promise.allSettled(Q.map((e) => yt({ variables: { id: e.id } }))), t = e.filter((e) => e.status === "fulfilled").length, n = e.length - t;
292
+ P(`Deprecated ${t} version${t === 1 ? "" : "s"}${n > 0 ? ` • ${n} failed` : ""}`), $(), B(null);
293
+ }, zt = v(j.manifestJson);
294
+ return ut && !q ? /* @__PURE__ */ g(se, {
295
+ title: y("devportal.versionManagement", "Version Management"),
296
+ description: y("devportal.versionManagementDescription", "Manage your application versions"),
297
+ backLink: `/apps/${S}`,
298
+ backLabel: y("devportal.backToApplication", "Back to Application"),
299
+ children: /* @__PURE__ */ g("div", {
291
300
  className: "flex items-center justify-center py-16",
292
- children: /* @__PURE__ */ _(Se, { className: "h-8 w-8 animate-spin text-text-secondary" })
301
+ children: /* @__PURE__ */ g(Ce, { className: "h-8 w-8 animate-spin text-text-secondary" })
293
302
  })
294
- }) : ct && !q ? /* @__PURE__ */ _(se, {
295
- title: b("devportal.versionManagement", "Version Management"),
296
- description: b("devportal.versionManagementDescription", "Manage your application versions"),
297
- backLink: `/apps/${C}`,
298
- backLabel: b("devportal.backToApplication", "Back to Application"),
299
- children: /* @__PURE__ */ _(t, {
300
- icon: /* @__PURE__ */ _(p, {
303
+ }) : dt && !q ? /* @__PURE__ */ g(se, {
304
+ title: y("devportal.versionManagement", "Version Management"),
305
+ description: y("devportal.versionManagementDescription", "Manage your application versions"),
306
+ backLink: `/apps/${S}`,
307
+ backLabel: y("devportal.backToApplication", "Back to Application"),
308
+ children: /* @__PURE__ */ g(t, {
309
+ icon: /* @__PURE__ */ g(f, {
301
310
  size: 32,
302
311
  className: "text-status-error-text"
303
312
  }),
304
- title: b("devportal.failedToLoadVersions", "Failed to load versions"),
305
- description: ct.message || b("devportal.versionsLoadError", "An error occurred while loading versions")
313
+ title: y("devportal.failedToLoadVersions", "Failed to load versions"),
314
+ description: dt.message || y("devportal.versionsLoadError", "An error occurred while loading versions")
306
315
  })
307
- }) : /* @__PURE__ */ _(fe, {
316
+ }) : /* @__PURE__ */ g(de, {
308
317
  authOnly: !0,
309
- children: /* @__PURE__ */ v(se, {
310
- title: b("devportal.versionManagement", "Version Management"),
311
- description: b("devportal.versionManagementDescription", "Manage your application versions"),
312
- purpose: H ? b("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.") : U ? b("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.") : W ? b("devportal.versionManagementPurposeManifestOnly", "Versions track releases of this item. Create a version for each significant change and paste the manifest JSON. No zip is needed.") : b("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."),
313
- backLink: `/apps/${C}`,
314
- backLabel: b("devportal.backToApplication", "Back to Application"),
315
- actions: /* @__PURE__ */ v("button", {
318
+ children: /* @__PURE__ */ _(se, {
319
+ title: y("devportal.versionManagement", "Version Management"),
320
+ description: y("devportal.versionManagementDescription", "Manage your application versions"),
321
+ purpose: H ? 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.") : U ? 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.") : W ? 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."),
322
+ backLink: `/apps/${S}`,
323
+ backLabel: y("devportal.backToApplication", "Back to Application"),
324
+ actions: /* @__PURE__ */ _("button", {
316
325
  onClick: () => {
317
- I(null), k(!0);
326
+ F(null), O(!0);
318
327
  },
319
- disabled: !Ae,
320
- "aria-disabled": !Ae,
328
+ disabled: !Me,
329
+ "aria-disabled": !Me,
321
330
  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",
322
- children: [/* @__PURE__ */ _(we, { size: 16 }), b("devportal.newVersion", "New Version")]
331
+ children: [/* @__PURE__ */ g(Te, { size: 16 }), y("devportal.newVersion", "New Version")]
323
332
  }),
324
333
  children: [
325
- Ue && /* @__PURE__ */ v("div", {
334
+ qe && /* @__PURE__ */ _("div", {
326
335
  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",
327
336
  children: [
328
- /* @__PURE__ */ _(p, {
337
+ /* @__PURE__ */ g(f, {
329
338
  size: 16,
330
339
  className: "flex-shrink-0"
331
340
  }),
332
- Ue,
333
- /* @__PURE__ */ _("button", {
334
- onClick: () => P(null),
341
+ qe,
342
+ /* @__PURE__ */ g("button", {
343
+ onClick: () => N(null),
335
344
  className: "ml-auto text-status-error-text hover:text-status-error-text",
336
- children: b("devportal.dismiss", "Dismiss")
345
+ children: y("devportal.dismiss", "Dismiss")
337
346
  })
338
347
  ]
339
348
  }),
340
- We && /* @__PURE__ */ v("div", {
349
+ Je && /* @__PURE__ */ _("div", {
341
350
  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",
342
351
  children: [
343
- /* @__PURE__ */ _(be, {
352
+ /* @__PURE__ */ g(xe, {
344
353
  size: 16,
345
354
  className: "flex-shrink-0"
346
355
  }),
347
- We,
348
- /* @__PURE__ */ _("button", {
349
- onClick: () => F(null),
356
+ Je,
357
+ /* @__PURE__ */ g("button", {
358
+ onClick: () => P(null),
350
359
  className: "ml-auto text-status-success-text hover:text-status-success-text",
351
- children: b("devportal.dismiss", "Dismiss")
360
+ children: y("devportal.dismiss", "Dismiss")
352
361
  })
353
362
  ]
354
363
  }),
355
- G && !K && /* @__PURE__ */ v("div", {
364
+ G && !K && /* @__PURE__ */ _("div", {
356
365
  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",
357
- children: [/* @__PURE__ */ _(p, {
366
+ children: [/* @__PURE__ */ g(f, {
358
367
  size: 16,
359
368
  className: "mt-0.5 shrink-0"
360
- }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("p", {
369
+ }), /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("p", {
361
370
  className: "font-medium",
362
371
  children: "Complete your app setup before submitting for review"
363
- }), /* @__PURE__ */ _("ul", {
372
+ }), /* @__PURE__ */ g("ul", {
364
373
  className: "mt-1 list-disc pl-4 text-xs opacity-80",
365
- children: ot.map((e) => /* @__PURE__ */ _("li", { children: e }, e))
374
+ children: lt.map((e) => /* @__PURE__ */ g("li", { children: e }, e))
366
375
  })] })]
367
376
  }),
368
- G && G.status !== "PUBLISHED" && J.some((e) => e.status === "draft") && /* @__PURE__ */ v("div", {
377
+ G && G.status !== "PUBLISHED" && J.some((e) => e.status === "draft") && /* @__PURE__ */ _("div", {
369
378
  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",
370
- children: [/* @__PURE__ */ _(m, {
379
+ children: [/* @__PURE__ */ g(p, {
371
380
  size: 16,
372
381
  className: "mt-0.5 shrink-0"
373
- }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("p", {
382
+ }), /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("p", {
374
383
  className: "font-medium",
375
384
  children: "Ready to submit? Go to the Submit tab"
376
- }), /* @__PURE__ */ v("p", {
385
+ }), /* @__PURE__ */ _("p", {
377
386
  className: "mt-1 text-xs opacity-80",
378
387
  children: [
379
388
  "For your first submission the app and its version are reviewed together. Head to the ",
380
- /* @__PURE__ */ _("strong", { children: "Submit" }),
389
+ /* @__PURE__ */ g("strong", { children: "Submit" }),
381
390
  " tab — your draft version will be included automatically. The per-version \"Submit for Review\" button is only for new versions after the app is already live in the marketplace."
382
391
  ]
383
392
  })] })]
384
393
  }),
385
- G && Z && /* @__PURE__ */ v("div", {
394
+ G && Z && /* @__PURE__ */ _("div", {
386
395
  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",
387
- children: [/* @__PURE__ */ _(m, {
396
+ children: [/* @__PURE__ */ g(p, {
388
397
  size: 16,
389
398
  className: "mt-0.5 shrink-0"
390
- }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("p", {
399
+ }), /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("p", {
391
400
  className: "font-medium",
392
- children: b("devportal.versionAlreadyPending", "A version is already pending review")
393
- }), /* @__PURE__ */ _("p", {
401
+ children: y("devportal.versionAlreadyPending", "A version is already pending review")
402
+ }), /* @__PURE__ */ g("p", {
394
403
  className: "mt-1 text-xs opacity-80",
395
- children: b("devportal.versionAlreadyPendingDetail", "Submitting another version is disabled until it's approved or rejected.")
404
+ children: y("devportal.versionAlreadyPendingDetail", "Submitting another version is disabled until it's approved or rejected.")
396
405
  })] })]
397
406
  }),
398
- J.length > 0 && /* @__PURE__ */ _("div", {
407
+ J.length > 0 && /* @__PURE__ */ g("div", {
399
408
  className: "rounded-card border border-border-seam bg-bg-surface p-4",
400
- children: /* @__PURE__ */ v("div", {
409
+ children: /* @__PURE__ */ _("div", {
401
410
  className: "flex flex-col gap-3 lg:flex-row lg:items-center lg:justify-between",
402
- children: [/* @__PURE__ */ v("div", {
411
+ children: [/* @__PURE__ */ _("div", {
403
412
  className: "flex flex-wrap items-center gap-3",
404
- children: [/* @__PURE__ */ v("div", {
413
+ children: [/* @__PURE__ */ _("div", {
405
414
  className: "flex items-center gap-2",
406
- children: [/* @__PURE__ */ _(le, {
407
- checked: $,
408
- indeterminate: yt,
409
- onChange: jt,
415
+ children: [/* @__PURE__ */ g(i, {
416
+ checked: St,
417
+ indeterminate: Ct,
418
+ onChange: It,
410
419
  ariaLabel: "Select all visible versions"
411
- }), /* @__PURE__ */ _("span", {
420
+ }), /* @__PURE__ */ g("span", {
412
421
  className: "text-sm font-medium",
413
- children: b("devportal.selectAllVisible", "Select all visible")
422
+ children: y("devportal.selectAllVisible", "Select all visible")
414
423
  })]
415
- }), R.size > 0 && /* @__PURE__ */ _("button", {
416
- onClick: Mt,
424
+ }), L.size > 0 && /* @__PURE__ */ g("button", {
425
+ onClick: $,
417
426
  className: "text-sm text-text-secondary hover:text-text-primary",
418
- children: b("devportal.clearSelection", "Clear selection")
427
+ children: y("devportal.clearSelection", "Clear selection")
419
428
  })]
420
- }), /* @__PURE__ */ v("div", {
429
+ }), /* @__PURE__ */ _("div", {
421
430
  className: "flex flex-wrap items-center gap-2",
422
431
  children: [
423
- /* @__PURE__ */ v("span", {
432
+ /* @__PURE__ */ _("span", {
424
433
  className: "rounded-full bg-bg-sunken px-3 py-1 text-sm font-medium text-text-secondary",
425
- children: [R.size, " selected"]
434
+ children: [L.size, " selected"]
426
435
  }),
427
- /* @__PURE__ */ v("button", {
436
+ /* @__PURE__ */ _("button", {
428
437
  onClick: () => B("publish"),
429
- disabled: X.length === 0 || !x || !K || Z,
430
- "aria-disabled": !x || !K || Z,
431
- title: Z ? b("devportal.versionAlreadyPending", "A version is already pending review") : K ? void 0 : ot.join(" · "),
438
+ disabled: X.length === 0 || !b || !K || Z,
439
+ "aria-disabled": !b || !K || Z,
440
+ title: Z ? y("devportal.versionAlreadyPending", "A version is already pending review") : K ? void 0 : lt.join(" · "),
432
441
  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",
433
- children: [b("devportal.submitForReview", "Submit for Review"), X.length > 0 ? ` (${X.length})` : ""]
442
+ children: [y("devportal.submitForReview", "Submit for Review"), X.length > 0 ? ` (${X.length})` : ""]
434
443
  }),
435
- /* @__PURE__ */ v("button", {
444
+ /* @__PURE__ */ _("button", {
436
445
  onClick: () => B("deprecate"),
437
- disabled: Q.length === 0 || !S,
438
- "aria-disabled": !S,
446
+ disabled: Q.length === 0 || !x,
447
+ "aria-disabled": !x,
439
448
  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",
440
- children: [b("devportal.deprecateSelected", "Deprecate Selected"), Q.length > 0 ? ` (${Q.length})` : ""]
449
+ children: [y("devportal.deprecateSelected", "Deprecate Selected"), Q.length > 0 ? ` (${Q.length})` : ""]
441
450
  })
442
451
  ]
443
452
  })]
444
453
  })
445
454
  }),
446
- J.length > 0 ? /* @__PURE__ */ _(ue, {
455
+ J.length > 0 ? /* @__PURE__ */ g(le, {
447
456
  data: J,
448
457
  keyField: "id",
449
458
  columns: [
450
459
  {
451
460
  key: "select",
452
- header: /* @__PURE__ */ _(le, {
453
- checked: $,
454
- indeterminate: yt,
455
- onChange: jt,
461
+ header: /* @__PURE__ */ g(i, {
462
+ checked: St,
463
+ indeterminate: Ct,
464
+ onChange: It,
456
465
  ariaLabel: "Select all visible versions"
457
466
  }),
458
467
  className: "w-12",
459
- render: (e) => /* @__PURE__ */ _("div", {
468
+ render: (e) => /* @__PURE__ */ g("div", {
460
469
  onClick: (e) => e.stopPropagation(),
461
- children: /* @__PURE__ */ _(le, {
462
- checked: R.has(e.id),
463
- onChange: (t) => At(e.id, t),
470
+ children: /* @__PURE__ */ g(i, {
471
+ checked: L.has(e.id),
472
+ onChange: (t) => Ft(e.id, t),
464
473
  ariaLabel: `Select version ${e.version}`
465
474
  })
466
475
  })
467
476
  },
468
477
  {
469
478
  key: "version",
470
- header: b("devportal.version", "Version"),
471
- render: (e) => /* @__PURE__ */ v("div", {
479
+ header: y("devportal.version", "Version"),
480
+ render: (e) => /* @__PURE__ */ _("div", {
472
481
  className: "flex items-center gap-2",
473
482
  children: [
474
- kt(e),
475
- /* @__PURE__ */ _("span", {
483
+ Pt(e),
484
+ /* @__PURE__ */ g("span", {
476
485
  className: "font-mono font-medium",
477
486
  children: e.version
478
487
  }),
479
- e.isLatest && /* @__PURE__ */ _("span", {
488
+ e.isLatest && /* @__PURE__ */ g("span", {
480
489
  className: "rounded-full bg-status-success-bg-subtle px-2 py-0.5 text-xs text-status-success-text",
481
- children: b("devportal.latest", "Latest")
490
+ children: y("devportal.latest", "Latest")
482
491
  }),
483
- !e.isStable && /* @__PURE__ */ _("span", {
492
+ !e.isStable && /* @__PURE__ */ g("span", {
484
493
  className: "rounded-full bg-status-warning-bg-subtle px-2 py-0.5 text-xs text-status-warning-text",
485
- children: b("devportal.beta", "Beta")
494
+ children: y("devportal.beta", "Beta")
486
495
  })
487
496
  ]
488
497
  })
489
498
  },
490
499
  {
491
500
  key: "releaseNotes",
492
- header: b("devportal.releaseNotes", "Release Notes"),
493
- render: (e) => /* @__PURE__ */ _("p", {
501
+ header: y("devportal.releaseNotes", "Release Notes"),
502
+ render: (e) => /* @__PURE__ */ g("p", {
494
503
  className: "max-w-md truncate text-sm text-text-secondary",
495
- children: e.releaseNotes || b("devportal.noReleaseNotes", "No release notes")
504
+ children: e.releaseNotes || y("devportal.noReleaseNotes", "No release notes")
496
505
  })
497
506
  },
498
507
  {
499
508
  key: "status",
500
- header: b("devportal.status", "Status"),
501
- render: (e) => /* @__PURE__ */ v("div", {
509
+ header: y("devportal.status", "Status"),
510
+ render: (e) => /* @__PURE__ */ _("div", {
502
511
  className: "space-y-1",
503
512
  children: [
504
- /* @__PURE__ */ _(ce, { status: e.status === "pending_review" ? "In Review" : e.status }),
505
- e.status === "pending_review" && /* @__PURE__ */ _("p", {
513
+ /* @__PURE__ */ g(ce, { status: e.status === "pending_review" ? "In Review" : e.status }),
514
+ e.status === "pending_review" && /* @__PURE__ */ g("p", {
506
515
  className: "text-xs text-status-info-text",
507
516
  children: "Awaiting platform review"
508
517
  }),
509
- e.status === "rejected" && e.reviewNotes && /* @__PURE__ */ _("p", {
518
+ e.status === "rejected" && e.reviewNotes && /* @__PURE__ */ g("p", {
510
519
  className: "text-xs text-status-error-text max-w-xs",
511
520
  children: e.reviewNotes
512
521
  }),
513
- U && e.packageUrl && /* @__PURE__ */ _(me, { metadata: e.metadata }),
514
- nt && Oe(e.metadata) && /* @__PURE__ */ v("p", {
522
+ U && e.packageUrl && /* @__PURE__ */ g(pe, { metadata: e.metadata }),
523
+ at && Ae(e.metadata) && /* @__PURE__ */ _("p", {
515
524
  className: "inline-flex items-center gap-1 text-xs text-status-success-text",
516
- children: [/* @__PURE__ */ _(ye, { size: 11 }), b("devportal.publishedToOrganization", "Published to your organization")]
525
+ children: [/* @__PURE__ */ g(be, { size: 11 }), y("devportal.publishedToOrganization", "Published to your organization")]
517
526
  })
518
527
  ]
519
528
  })
520
529
  },
521
530
  {
522
531
  key: "publishedAt",
523
- header: b("devportal.published", "Published"),
524
- render: (e) => e.publishedAt ? he(new Date(e.publishedAt), "MMM d, yyyy") : "-"
532
+ header: y("devportal.published", "Published"),
533
+ render: (e) => e.publishedAt ? ge(new Date(e.publishedAt), "MMM d, yyyy") : "-"
525
534
  },
526
535
  {
527
536
  key: "manifest",
528
- header: b("devportal.manifest", "Manifest"),
529
- render: (e) => e.manifest ? /* @__PURE__ */ _(pe, {
537
+ header: y("devportal.manifest", "Manifest"),
538
+ render: (e) => e.manifest ? /* @__PURE__ */ g(fe, {
530
539
  manifest: e.manifest,
531
- tr: b
532
- }) : /* @__PURE__ */ _("span", {
540
+ tr: y
541
+ }) : /* @__PURE__ */ g("span", {
533
542
  className: "text-xs text-text-secondary",
534
- children: b("devportal.noManifest", "No manifest")
543
+ children: y("devportal.noManifest", "No manifest")
535
544
  })
536
545
  },
537
546
  {
538
547
  key: "actions",
539
548
  header: "",
540
549
  className: "w-48",
541
- render: (e) => /* @__PURE__ */ v("div", {
550
+ render: (e) => /* @__PURE__ */ _("div", {
542
551
  className: "flex flex-wrap gap-2",
543
552
  children: [
544
- (e.status === "draft" || e.status === "rejected") && Ae && /* @__PURE__ */ _("button", {
553
+ U && /* @__PURE__ */ _("button", {
554
+ className: "inline-flex items-center gap-1 text-xs text-primary hover:underline",
555
+ "data-testid": `version-lifecycle-${e.id}`,
556
+ onClick: () => wt(e.id),
557
+ children: [/* @__PURE__ */ g(Ee, { size: 11 }), y("devportal.nodeLifecycle.open", "Lifecycle")]
558
+ }),
559
+ (e.status === "draft" || e.status === "rejected") && Me && /* @__PURE__ */ g("button", {
545
560
  className: "inline-flex items-center gap-1 text-xs text-text-secondary hover:text-text-primary hover:underline",
546
561
  onClick: () => {
547
562
  let t = e.manifest ? JSON.stringify(e.manifest, null, 2) : "";
548
- j({
563
+ A({
549
564
  versionId: e.id,
550
565
  version: e.version,
551
566
  hasExistingZip: !!e.packageUrl,
@@ -555,444 +570,444 @@ var ke = () => {
555
570
  originalManifestJson: t,
556
571
  releaseNotes: e.releaseNotes ?? "",
557
572
  changelog: e.changelog ?? ""
558
- }), O(null), L(null);
573
+ }), D(null), I(null);
559
574
  },
560
575
  children: "Edit"
561
576
  }),
562
- (e.status === "draft" || e.status === "rejected") && G?.status === "PUBLISHED" && /* @__PURE__ */ v("button", {
577
+ (e.status === "draft" || e.status === "rejected") && G?.status === "PUBLISHED" && /* @__PURE__ */ _("button", {
563
578
  className: "inline-flex items-center gap-1 text-xs text-primary hover:underline disabled:opacity-50 disabled:cursor-not-allowed",
564
- disabled: !x || !K || Z,
565
- "aria-disabled": !x || !K || Z,
566
- title: Z ? b("devportal.versionAlreadyPending", "A version is already pending review") : K ? void 0 : ot.join(" · "),
567
- onClick: () => Tt(e.id),
568
- children: [/* @__PURE__ */ _(m, { size: 11 }), b("devportal.submitForReview", "Submit for Review")]
579
+ disabled: !b || !K || Z,
580
+ "aria-disabled": !b || !K || Z,
581
+ title: Z ? y("devportal.versionAlreadyPending", "A version is already pending review") : K ? void 0 : lt.join(" · "),
582
+ onClick: () => At(e.id),
583
+ children: [/* @__PURE__ */ g(p, { size: 11 }), y("devportal.submitForReview", "Submit for Review")]
569
584
  }),
570
- nt && (e.status === "draft" || e.status === "rejected") && /* @__PURE__ */ v("button", {
585
+ at && (e.status === "draft" || e.status === "rejected") && /* @__PURE__ */ _("button", {
571
586
  className: "inline-flex items-center gap-1 text-xs text-primary hover:underline disabled:opacity-50 disabled:cursor-not-allowed",
572
- disabled: !x || !w || ht || o(e.metadata).kind !== "passed",
573
- "aria-disabled": !x || !w || ht || o(e.metadata).kind !== "passed",
574
- title: o(e.metadata).kind === "passed" ? void 0 : b("devportal.publishToOrganizationNeedsValidation", "Upload a package that passes validation first"),
575
- onClick: () => et(e),
576
- children: [/* @__PURE__ */ _(ye, { size: 11 }), b("devportal.publishToOrganization", "Publish to my organization")]
587
+ disabled: !b || !C || vt || s(e.metadata).kind !== "passed",
588
+ "aria-disabled": !b || !C || vt || s(e.metadata).kind !== "passed",
589
+ title: s(e.metadata).kind === "passed" ? void 0 : y("devportal.publishToOrganizationNeedsValidation", "Upload a package that passes validation first"),
590
+ onClick: () => rt(e),
591
+ children: [/* @__PURE__ */ g(be, { size: 11 }), y("devportal.publishToOrganization", "Publish to my organization")]
577
592
  }),
578
- e.status === "published" && !e.isLatest && /* @__PURE__ */ _("button", {
593
+ e.status === "published" && !e.isLatest && /* @__PURE__ */ g("button", {
579
594
  className: "text-xs text-status-warning-text hover:underline disabled:opacity-50",
580
- disabled: !S,
581
- "aria-disabled": !S,
582
- onClick: () => Dt(e.id),
583
- children: b("devportal.deprecate", "Deprecate")
595
+ disabled: !x,
596
+ "aria-disabled": !x,
597
+ onClick: () => Mt(e.id),
598
+ children: y("devportal.deprecate", "Deprecate")
584
599
  })
585
600
  ]
586
601
  })
587
602
  }
588
603
  ]
589
- }) : /* @__PURE__ */ _(t, {
604
+ }) : /* @__PURE__ */ g(t, {
590
605
  illustration: "empty-data",
591
- title: b("devportal.noVersionsYet", "No versions yet"),
592
- description: b("devportal.noVersionsYetDescription", "Create your first version to start distributing your app"),
593
- action: /* @__PURE__ */ v("button", {
606
+ title: y("devportal.noVersionsYet", "No versions yet"),
607
+ description: y("devportal.noVersionsYetDescription", "Create your first version to start distributing your app"),
608
+ action: /* @__PURE__ */ _("button", {
594
609
  onClick: () => {
595
- I(null), k(!0);
610
+ F(null), O(!0);
596
611
  },
597
612
  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",
598
- children: [/* @__PURE__ */ _(we, { size: 16 }), b("devportal.createVersion", "Create Version")]
613
+ children: [/* @__PURE__ */ g(Te, { size: 16 }), y("devportal.createVersion", "Create Version")]
599
614
  })
600
615
  }),
601
- He && /* @__PURE__ */ _(i, {
602
- open: He,
616
+ Ke && /* @__PURE__ */ g(a, {
617
+ open: Ke,
603
618
  onOpenChange: (e) => {
604
- k(e), e || I(null);
619
+ O(e), e || F(null);
605
620
  },
606
- onConfirm: bt,
607
- title: b("devportal.createNewVersion", "Create New Version"),
608
- confirmLabel: ut ? b("devportal.creating", "Creating...") : b("devportal.createVersion", "Create Version"),
609
- children: /* @__PURE__ */ v("div", {
621
+ onConfirm: Tt,
622
+ title: y("devportal.createNewVersion", "Create New Version"),
623
+ confirmLabel: pt ? y("devportal.creating", "Creating...") : y("devportal.createVersion", "Create Version"),
624
+ children: /* @__PURE__ */ _("div", {
610
625
  className: "space-y-4",
611
626
  children: [
612
- Ge && /* @__PURE__ */ v("div", {
627
+ Ye && /* @__PURE__ */ _("div", {
613
628
  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",
614
- children: [/* @__PURE__ */ _(p, {
629
+ children: [/* @__PURE__ */ g(f, {
615
630
  size: 14,
616
631
  className: "flex-shrink-0"
617
- }), Ge]
632
+ }), Ye]
618
633
  }),
619
- /* @__PURE__ */ _(de, {
620
- label: b("devportal.versionNumber", "Version Number"),
621
- value: M.version,
622
- onChange: (e) => N({
623
- ...M,
634
+ /* @__PURE__ */ g(ue, {
635
+ label: y("devportal.versionNumber", "Version Number"),
636
+ value: j.version,
637
+ onChange: (e) => M({
638
+ ...j,
624
639
  version: e.target.value
625
640
  }),
626
641
  placeholder: "e.g., 2.2.0",
627
- hint: Ft ? b("devportal.versionHintAutoFilled", "Filled in from the manifest's version — edit it there if this is wrong.") : b("devportal.versionHint", "Use semantic versioning (major.minor.patch). Upload a manifest.json/manifest with a version to fill this in automatically."),
628
- readOnly: !!Ft,
642
+ hint: zt ? y("devportal.versionHintAutoFilled", "Filled in from the manifest's version — edit it there if this is wrong.") : y("devportal.versionHint", "Use semantic versioning (major.minor.patch). Upload a manifest.json/manifest with a version to fill this in automatically."),
643
+ readOnly: !!zt,
629
644
  required: !0
630
645
  }),
631
- W && /* @__PURE__ */ v("div", {
646
+ W && /* @__PURE__ */ _("div", {
632
647
  className: "space-y-1",
633
648
  children: [
634
- /* @__PURE__ */ v("label", {
649
+ /* @__PURE__ */ _("label", {
635
650
  className: "text-sm font-medium",
636
651
  children: [
637
652
  H ? "Workflow Definition (JSON)" : "Manifest (JSON)",
638
653
  " ",
639
- /* @__PURE__ */ _("span", {
654
+ /* @__PURE__ */ g("span", {
640
655
  className: "text-status-error-text",
641
656
  children: "*"
642
657
  })
643
658
  ]
644
659
  }),
645
- /* @__PURE__ */ _("textarea", {
660
+ /* @__PURE__ */ g("textarea", {
646
661
  rows: 10,
647
662
  required: !0,
648
663
  placeholder: H ? "{\n \"nodes\": [],\n \"edges\": []\n}" : "{\n \"manifestVersion\": \"1.0\",\n \"identity\": { \"name\": \"My Item\", \"version\": \"1.0.0\" }\n}",
649
- value: M.manifestJson,
664
+ value: j.manifestJson,
650
665
  onChange: (e) => {
651
- let t = y(e.target.value);
652
- N({
653
- ...M,
666
+ let t = v(e.target.value);
667
+ M({
668
+ ...j,
654
669
  manifestJson: e.target.value,
655
670
  ...t ? { version: t } : {}
656
671
  });
657
672
  },
658
673
  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)]"
659
674
  }),
660
- /* @__PURE__ */ _("p", {
675
+ /* @__PURE__ */ g("p", {
661
676
  className: "text-xs text-text-secondary",
662
- children: H ? /* @__PURE__ */ v(g, { children: [
677
+ children: H ? /* @__PURE__ */ _(h, { children: [
663
678
  "Paste the full ",
664
- /* @__PURE__ */ _("code", { children: "{nodes, edges}" }),
679
+ /* @__PURE__ */ g("code", { children: "{nodes, edges}" }),
665
680
  " JSON. Saved as this version's manifest — no zip needed."
666
681
  ] }) : "Paste the manifest JSON for this version. No zip needed."
667
682
  })
668
683
  ]
669
684
  }),
670
- U && /* @__PURE__ */ v("div", {
685
+ U && /* @__PURE__ */ _("div", {
671
686
  className: "space-y-1",
672
687
  children: [
673
- /* @__PURE__ */ v("label", {
688
+ /* @__PURE__ */ _("label", {
674
689
  className: "text-sm font-medium",
675
690
  children: [
676
691
  "Package (.zip)",
677
692
  " ",
678
- /* @__PURE__ */ _("span", {
693
+ /* @__PURE__ */ g("span", {
679
694
  className: "text-status-error-text",
680
695
  children: "*"
681
696
  })
682
697
  ]
683
698
  }),
684
- /* @__PURE__ */ v("div", {
699
+ /* @__PURE__ */ _("div", {
685
700
  className: "flex gap-2 items-center",
686
701
  children: [
687
- /* @__PURE__ */ _("input", {
688
- ref: Fe,
702
+ /* @__PURE__ */ g("input", {
703
+ ref: ze,
689
704
  type: "file",
690
705
  accept: ".zip",
691
706
  className: "hidden",
692
- onChange: xt
707
+ onChange: Et
693
708
  }),
694
- /* @__PURE__ */ _("button", {
709
+ /* @__PURE__ */ g("button", {
695
710
  type: "button",
696
- disabled: E,
697
- onClick: () => Fe.current?.click(),
711
+ disabled: T,
712
+ onClick: () => ze.current?.click(),
698
713
  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",
699
- children: E ? /* @__PURE__ */ v(g, { children: [
700
- /* @__PURE__ */ _(Se, {
714
+ children: T ? /* @__PURE__ */ _(h, { children: [
715
+ /* @__PURE__ */ g(Ce, {
701
716
  size: 14,
702
717
  className: "animate-spin"
703
718
  }),
704
719
  " ",
705
720
  "Uploading… ",
706
- Pe,
721
+ Re,
707
722
  "%"
708
- ] }) : /* @__PURE__ */ v(g, { children: [
709
- /* @__PURE__ */ _(h, { size: 14 }),
723
+ ] }) : /* @__PURE__ */ _(h, { children: [
724
+ /* @__PURE__ */ g(m, { size: 14 }),
710
725
  " ",
711
- M.packageUrl ? "Replace zip" : "Upload zip"
726
+ j.packageUrl ? "Replace zip" : "Upload zip"
712
727
  ] })
713
728
  }),
714
- M.packageUrl && !E && /* @__PURE__ */ _("span", {
729
+ j.packageUrl && !T && /* @__PURE__ */ g("span", {
715
730
  className: "text-xs text-status-success-text",
716
731
  children: "✓ Uploaded"
717
732
  })
718
733
  ]
719
734
  }),
720
- D && /* @__PURE__ */ _("p", {
735
+ E && /* @__PURE__ */ g("p", {
721
736
  className: "text-xs text-status-error-text",
722
- children: D
737
+ children: E
723
738
  }),
724
- /* @__PURE__ */ _("p", {
739
+ /* @__PURE__ */ g("p", {
725
740
  className: "text-xs text-text-tertiary",
726
741
  children: "The zip is the node executable. Upload it before publishing — users install exactly this artifact."
727
742
  })
728
743
  ]
729
744
  }),
730
- U && /* @__PURE__ */ v("div", {
745
+ U && /* @__PURE__ */ _("div", {
731
746
  className: "space-y-2",
732
747
  children: [
733
- /* @__PURE__ */ v("div", {
748
+ /* @__PURE__ */ _("div", {
734
749
  className: "flex items-center justify-between gap-2 flex-wrap",
735
- children: [/* @__PURE__ */ v("label", {
750
+ children: [/* @__PURE__ */ _("label", {
736
751
  className: "text-sm font-medium",
737
752
  children: [
738
753
  "manifest.json",
739
754
  " ",
740
- /* @__PURE__ */ _("span", {
755
+ /* @__PURE__ */ g("span", {
741
756
  className: "text-status-error-text",
742
757
  children: "*"
743
758
  })
744
759
  ]
745
- }), /* @__PURE__ */ v("div", {
760
+ }), /* @__PURE__ */ _("div", {
746
761
  className: "flex items-center gap-2",
747
762
  children: [
748
- ze && /* @__PURE__ */ v("span", {
763
+ Ue && /* @__PURE__ */ _("span", {
749
764
  className: "text-xs text-status-success-text",
750
- children: ["✓ ", ze]
765
+ children: ["✓ ", Ue]
751
766
  }),
752
- /* @__PURE__ */ _("input", {
753
- ref: Ie,
767
+ /* @__PURE__ */ g("input", {
768
+ ref: Be,
754
769
  type: "file",
755
770
  accept: ".json,application/json",
756
771
  className: "hidden",
757
- onChange: Ze
772
+ onChange: et
758
773
  }),
759
- /* @__PURE__ */ v("button", {
774
+ /* @__PURE__ */ _("button", {
760
775
  type: "button",
761
- onClick: () => Ie.current?.click(),
776
+ onClick: () => Be.current?.click(),
762
777
  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",
763
- children: [/* @__PURE__ */ _(h, { size: 12 }), "Upload manifest.json"]
778
+ children: [/* @__PURE__ */ g(m, { size: 12 }), "Upload manifest.json"]
764
779
  })
765
780
  ]
766
781
  })]
767
782
  }),
768
- /* @__PURE__ */ _("textarea", {
783
+ /* @__PURE__ */ g("textarea", {
769
784
  rows: 5,
770
785
  placeholder: "{\n \"manifestVersion\": \"1.0\",\n \"itemType\": \"node\",\n \"identity\": { \"version\": \"1.0.0\", \"displayName\": \"My Node\" }\n}",
771
- value: M.manifestJson,
786
+ value: j.manifestJson,
772
787
  onChange: (e) => {
773
- Be(null);
774
- let t = y(e.target.value);
775
- N({
776
- ...M,
788
+ We(null);
789
+ let t = v(e.target.value);
790
+ M({
791
+ ...j,
777
792
  manifestJson: e.target.value,
778
793
  ...t ? { version: t } : {}
779
794
  });
780
795
  },
781
796
  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)]"
782
797
  }),
783
- /* @__PURE__ */ v("p", {
798
+ /* @__PURE__ */ _("p", {
784
799
  className: "text-xs text-text-tertiary",
785
800
  children: [
786
801
  "Upload or paste your ",
787
- /* @__PURE__ */ _("code", { children: "manifest.json" }),
802
+ /* @__PURE__ */ g("code", { children: "manifest.json" }),
788
803
  " — required so the platform knows your node's inputs, outputs, and operations. Not extracted from the zip automatically."
789
804
  ]
790
805
  })
791
806
  ]
792
807
  }),
793
- tt && /* @__PURE__ */ v("div", {
808
+ it && /* @__PURE__ */ _("div", {
794
809
  className: "space-y-1",
795
810
  children: [
796
- /* @__PURE__ */ v("label", {
811
+ /* @__PURE__ */ _("label", {
797
812
  className: "text-sm font-medium",
798
813
  children: [
799
814
  "Required scopes",
800
815
  " ",
801
- /* @__PURE__ */ _("span", {
816
+ /* @__PURE__ */ g("span", {
802
817
  className: "text-xs font-normal text-text-secondary",
803
818
  children: "(optional)"
804
819
  })
805
820
  ]
806
821
  }),
807
- /* @__PURE__ */ _("input", {
822
+ /* @__PURE__ */ g("input", {
808
823
  type: "text",
809
- value: M.requiredScopes,
810
- onChange: (e) => N({
811
- ...M,
824
+ value: j.requiredScopes,
825
+ onChange: (e) => M({
826
+ ...j,
812
827
  requiredScopes: e.target.value
813
828
  }),
814
829
  placeholder: "e.g. read:contacts, write:messages",
815
830
  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)]"
816
831
  }),
817
- /* @__PURE__ */ _("p", {
832
+ /* @__PURE__ */ g("p", {
818
833
  className: "text-xs text-text-tertiary",
819
834
  children: "Comma-separated. List every permission this version needs — users will be prompted to accept any new or changed scopes on update."
820
835
  })
821
836
  ]
822
837
  }),
823
- /* @__PURE__ */ _(a, {
824
- label: b("devportal.releaseNotes", "Release Notes"),
825
- value: M.releaseNotes,
826
- onChange: (e) => N({
827
- ...M,
838
+ /* @__PURE__ */ g(o, {
839
+ label: y("devportal.releaseNotes", "Release Notes"),
840
+ value: j.releaseNotes,
841
+ onChange: (e) => M({
842
+ ...j,
828
843
  releaseNotes: e
829
844
  }),
830
- placeholder: b("devportal.releaseNotesPlaceholder", "What changed in this release?"),
845
+ placeholder: y("devportal.releaseNotesPlaceholder", "What changed in this release?"),
831
846
  rows: 3
832
847
  }),
833
- /* @__PURE__ */ _(a, {
834
- label: b("devportal.changelog", "Changelog"),
835
- value: M.changelog,
836
- onChange: (e) => N({
837
- ...M,
848
+ /* @__PURE__ */ g(o, {
849
+ label: y("devportal.changelog", "Changelog"),
850
+ value: j.changelog,
851
+ onChange: (e) => M({
852
+ ...j,
838
853
  changelog: e
839
854
  }),
840
- placeholder: b("devportal.changelogPlaceholder", "Detailed changelog for this version..."),
855
+ placeholder: y("devportal.changelogPlaceholder", "Detailed changelog for this version..."),
841
856
  rows: 3
842
857
  })
843
858
  ]
844
859
  })
845
860
  }),
846
- z && /* @__PURE__ */ _(i, {
861
+ z && /* @__PURE__ */ g(a, {
847
862
  open: !!z,
848
863
  onOpenChange: (e) => {
849
- e || (Je(null), Xe(""));
864
+ e || (Ze(null), $e(""));
850
865
  },
851
- onConfirm: Ot,
866
+ onConfirm: Nt,
852
867
  title: `Reject version ${z.version}`,
853
868
  confirmLabel: "Reject Version",
854
- cancelLabel: b("devportal.cancel", "Cancel"),
869
+ cancelLabel: y("devportal.cancel", "Cancel"),
855
870
  variant: "danger",
856
- children: /* @__PURE__ */ v("div", {
871
+ children: /* @__PURE__ */ _("div", {
857
872
  className: "space-y-3",
858
- children: [/* @__PURE__ */ _("p", {
873
+ children: [/* @__PURE__ */ g("p", {
859
874
  className: "text-sm text-text-secondary",
860
875
  children: "The developer will be notified and can fix and resubmit. Please provide a clear reason."
861
- }), /* @__PURE__ */ v("div", {
876
+ }), /* @__PURE__ */ _("div", {
862
877
  className: "space-y-1",
863
- children: [/* @__PURE__ */ v("label", {
878
+ children: [/* @__PURE__ */ _("label", {
864
879
  className: "text-sm font-medium",
865
880
  children: [
866
881
  "Rejection reason",
867
882
  " ",
868
- /* @__PURE__ */ _("span", {
883
+ /* @__PURE__ */ g("span", {
869
884
  className: "text-status-error-text",
870
885
  children: "*"
871
886
  })
872
887
  ]
873
- }), /* @__PURE__ */ _("textarea", {
888
+ }), /* @__PURE__ */ g("textarea", {
874
889
  rows: 3,
875
- value: Ye,
876
- onChange: (e) => Xe(e.target.value),
890
+ value: Qe,
891
+ onChange: (e) => $e(e.target.value),
877
892
  placeholder: "e.g. Manifest contains disallowed network calls to external domains...",
878
893
  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)]"
879
894
  })]
880
895
  })]
881
896
  })
882
897
  }),
883
- A && /* @__PURE__ */ _(i, {
884
- open: !!A,
898
+ k && /* @__PURE__ */ g(a, {
899
+ open: !!k,
885
900
  onOpenChange: (e) => {
886
- e || (j(null), O(null), L(null));
901
+ e || (A(null), D(null), I(null));
887
902
  },
888
- onConfirm: wt,
889
- title: `Edit Version ${A.version}`,
890
- confirmLabel: ft ? "Saving…" : "Save Changes",
891
- children: /* @__PURE__ */ v("div", {
903
+ onConfirm: kt,
904
+ title: `Edit Version ${k.version}`,
905
+ confirmLabel: ht ? "Saving…" : "Save Changes",
906
+ children: /* @__PURE__ */ _("div", {
892
907
  className: "space-y-4",
893
908
  children: [
894
- Ke && /* @__PURE__ */ v("div", {
909
+ Xe && /* @__PURE__ */ _("div", {
895
910
  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",
896
- children: [/* @__PURE__ */ _(p, {
911
+ children: [/* @__PURE__ */ g(f, {
897
912
  size: 14,
898
913
  className: "flex-shrink-0"
899
- }), Ke]
914
+ }), Xe]
900
915
  }),
901
- /* @__PURE__ */ _("div", {
916
+ /* @__PURE__ */ g("div", {
902
917
  className: "rounded-lg border border-status-info-bg bg-status-info-bg-subtle px-3 py-2 text-xs text-status-info-text",
903
918
  children: "You can fix the zip, manifest, or release notes before submitting for review. Once submitted for review these fields are locked."
904
919
  }),
905
- U && /* @__PURE__ */ v("div", {
920
+ U && /* @__PURE__ */ _("div", {
906
921
  className: "space-y-1",
907
922
  children: [
908
- /* @__PURE__ */ _("label", {
923
+ /* @__PURE__ */ g("label", {
909
924
  className: "text-sm font-medium",
910
925
  children: "Package (.zip)"
911
926
  }),
912
- /* @__PURE__ */ v("div", {
927
+ /* @__PURE__ */ _("div", {
913
928
  className: "flex gap-2 items-center",
914
929
  children: [
915
- /* @__PURE__ */ _("input", {
916
- ref: Le,
930
+ /* @__PURE__ */ g("input", {
931
+ ref: Ve,
917
932
  type: "file",
918
933
  accept: ".zip",
919
934
  className: "hidden",
920
- onChange: St
935
+ onChange: Dt
921
936
  }),
922
- /* @__PURE__ */ _("button", {
937
+ /* @__PURE__ */ g("button", {
923
938
  type: "button",
924
- disabled: E,
925
- onClick: () => Le.current?.click(),
939
+ disabled: T,
940
+ onClick: () => Ve.current?.click(),
926
941
  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",
927
- children: E ? /* @__PURE__ */ v(g, { children: [
928
- /* @__PURE__ */ _(Se, {
942
+ children: T ? /* @__PURE__ */ _(h, { children: [
943
+ /* @__PURE__ */ g(Ce, {
929
944
  size: 14,
930
945
  className: "animate-spin"
931
946
  }),
932
947
  " ",
933
948
  "Uploading… ",
934
- Pe,
949
+ Re,
935
950
  "%"
936
- ] }) : /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _(h, { size: 14 }), A.newPackageUrl ? "Replace zip again" : A.hasExistingZip ? "Replace zip" : "Upload zip"] })
951
+ ] }) : /* @__PURE__ */ _(h, { children: [/* @__PURE__ */ g(m, { size: 14 }), k.newPackageUrl ? "Replace zip again" : k.hasExistingZip ? "Replace zip" : "Upload zip"] })
937
952
  }),
938
- A.newPackageUrl && !E && /* @__PURE__ */ _("span", {
953
+ k.newPackageUrl && !T && /* @__PURE__ */ g("span", {
939
954
  className: "text-xs text-status-success-text",
940
955
  children: "✓ New zip ready"
941
956
  }),
942
- !A.newPackageUrl && A.hasExistingZip && /* @__PURE__ */ _("span", {
957
+ !k.newPackageUrl && k.hasExistingZip && /* @__PURE__ */ g("span", {
943
958
  className: "text-xs text-text-secondary",
944
959
  children: "Current zip kept"
945
960
  })
946
961
  ]
947
962
  }),
948
- D && /* @__PURE__ */ _("p", {
963
+ E && /* @__PURE__ */ g("p", {
949
964
  className: "text-xs text-status-error-text",
950
- children: D
965
+ children: E
951
966
  })
952
967
  ]
953
968
  }),
954
- U && /* @__PURE__ */ v("div", {
969
+ U && /* @__PURE__ */ _("div", {
955
970
  className: "space-y-2",
956
- children: [/* @__PURE__ */ v("div", {
971
+ children: [/* @__PURE__ */ _("div", {
957
972
  className: "flex items-center justify-between gap-2 flex-wrap",
958
- children: [/* @__PURE__ */ v("label", {
973
+ children: [/* @__PURE__ */ _("label", {
959
974
  className: "text-sm font-medium",
960
975
  children: [
961
976
  "manifest.json",
962
977
  " ",
963
- /* @__PURE__ */ _("span", {
978
+ /* @__PURE__ */ g("span", {
964
979
  className: "text-xs font-normal text-text-secondary",
965
980
  children: "(edit below or upload a new file)"
966
981
  })
967
982
  ]
968
- }), /* @__PURE__ */ v("div", {
983
+ }), /* @__PURE__ */ _("div", {
969
984
  className: "flex items-center gap-2",
970
985
  children: [
971
- Ve && /* @__PURE__ */ v("span", {
986
+ Ge && /* @__PURE__ */ _("span", {
972
987
  className: "text-xs text-status-success-text",
973
- children: ["✓ ", Ve]
988
+ children: ["✓ ", Ge]
974
989
  }),
975
- /* @__PURE__ */ _("input", {
976
- ref: Re,
990
+ /* @__PURE__ */ g("input", {
991
+ ref: He,
977
992
  type: "file",
978
993
  accept: ".json,application/json",
979
994
  className: "hidden",
980
- onChange: Ct
995
+ onChange: Ot
981
996
  }),
982
- /* @__PURE__ */ v("button", {
997
+ /* @__PURE__ */ _("button", {
983
998
  type: "button",
984
- onClick: () => Re.current?.click(),
999
+ onClick: () => He.current?.click(),
985
1000
  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",
986
- children: [/* @__PURE__ */ _(h, { size: 12 }), " Upload manifest.json"]
1001
+ children: [/* @__PURE__ */ g(m, { size: 12 }), " Upload manifest.json"]
987
1002
  })
988
1003
  ]
989
1004
  })]
990
- }), /* @__PURE__ */ _("textarea", {
1005
+ }), /* @__PURE__ */ g("textarea", {
991
1006
  rows: 5,
992
1007
  placeholder: "{\n \"manifestVersion\": \"1.0\",\n \"itemType\": \"node\",\n \"identity\": { \"version\": \"1.0.0\", \"displayName\": \"My Node\" }\n}",
993
- value: A.manifestJson,
1008
+ value: k.manifestJson,
994
1009
  onChange: (e) => {
995
- O(null), j((t) => t && {
1010
+ D(null), A((t) => t && {
996
1011
  ...t,
997
1012
  manifestJson: e.target.value
998
1013
  });
@@ -1000,86 +1015,86 @@ var ke = () => {
1000
1015
  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)]"
1001
1016
  })]
1002
1017
  }),
1003
- W && /* @__PURE__ */ v("div", {
1018
+ W && /* @__PURE__ */ _("div", {
1004
1019
  className: "space-y-1",
1005
- children: [/* @__PURE__ */ v("label", {
1020
+ children: [/* @__PURE__ */ _("label", {
1006
1021
  className: "text-sm font-medium",
1007
1022
  children: [
1008
1023
  H ? "Workflow Definition (JSON)" : "Manifest (JSON)",
1009
1024
  " ",
1010
- /* @__PURE__ */ _("span", {
1025
+ /* @__PURE__ */ g("span", {
1011
1026
  className: "text-xs font-normal text-text-secondary",
1012
1027
  children: "(leave empty to keep existing)"
1013
1028
  })
1014
1029
  ]
1015
- }), /* @__PURE__ */ _("textarea", {
1030
+ }), /* @__PURE__ */ g("textarea", {
1016
1031
  rows: 10,
1017
1032
  placeholder: H ? "{\n \"nodes\": [],\n \"edges\": []\n}" : "{\n \"manifestVersion\": \"1.0\",\n \"identity\": { \"name\": \"My Item\", \"version\": \"1.0.0\" }\n}",
1018
- value: A.manifestJson,
1019
- onChange: (e) => j((t) => t && {
1033
+ value: k.manifestJson,
1034
+ onChange: (e) => A((t) => t && {
1020
1035
  ...t,
1021
1036
  manifestJson: e.target.value
1022
1037
  }),
1023
1038
  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)]"
1024
1039
  })]
1025
1040
  }),
1026
- /* @__PURE__ */ _(a, {
1027
- label: b("devportal.releaseNotes", "Release Notes"),
1028
- value: A.releaseNotes,
1029
- onChange: (e) => j((t) => t && {
1041
+ /* @__PURE__ */ g(o, {
1042
+ label: y("devportal.releaseNotes", "Release Notes"),
1043
+ value: k.releaseNotes,
1044
+ onChange: (e) => A((t) => t && {
1030
1045
  ...t,
1031
1046
  releaseNotes: e
1032
1047
  }),
1033
- placeholder: b("devportal.releaseNotesPlaceholder", "What changed in this release?"),
1048
+ placeholder: y("devportal.releaseNotesPlaceholder", "What changed in this release?"),
1034
1049
  rows: 3
1035
1050
  }),
1036
- /* @__PURE__ */ _(a, {
1037
- label: b("devportal.changelog", "Changelog"),
1038
- value: A.changelog,
1039
- onChange: (e) => j((t) => t && {
1051
+ /* @__PURE__ */ g(o, {
1052
+ label: y("devportal.changelog", "Changelog"),
1053
+ value: k.changelog,
1054
+ onChange: (e) => A((t) => t && {
1040
1055
  ...t,
1041
1056
  changelog: e
1042
1057
  }),
1043
- placeholder: b("devportal.changelogPlaceholder", "Detailed changelog for this version..."),
1058
+ placeholder: y("devportal.changelogPlaceholder", "Detailed changelog for this version..."),
1044
1059
  rows: 3
1045
1060
  })
1046
1061
  ]
1047
1062
  })
1048
1063
  }),
1049
- /* @__PURE__ */ _(i, {
1050
- open: Qe === "publish",
1064
+ /* @__PURE__ */ g(a, {
1065
+ open: tt === "publish",
1051
1066
  onOpenChange: (e) => {
1052
1067
  e || B(null);
1053
1068
  },
1054
- onConfirm: Nt,
1055
- title: b("devportal.submitSelectedVersions", "Submit selected versions for review"),
1069
+ onConfirm: Lt,
1070
+ title: y("devportal.submitSelectedVersions", "Submit selected versions for review"),
1056
1071
  description: `Submit ${X.length} selected version${X.length === 1 ? "" : "s"} for platform review?`,
1057
- confirmLabel: b("devportal.submitForReview", "Submit for Review"),
1058
- cancelLabel: b("devportal.cancel", "Cancel"),
1072
+ confirmLabel: y("devportal.submitForReview", "Submit for Review"),
1073
+ cancelLabel: y("devportal.cancel", "Cancel"),
1059
1074
  variant: "success"
1060
1075
  }),
1061
- /* @__PURE__ */ _(i, {
1062
- open: $e !== null,
1076
+ /* @__PURE__ */ g(a, {
1077
+ open: nt !== null,
1063
1078
  onOpenChange: (e) => {
1064
- e || et(null);
1079
+ e || rt(null);
1065
1080
  },
1066
- onConfirm: Et,
1067
- title: b("devportal.publishToOrganizationTitle", "Publish to my organization"),
1068
- description: `${b("devportal.publishToOrganizationDescription", "Version {version} goes live for the workspaces of your organization without platform review. It is never listed in the public Node Store. Workspace admins in your organization can install it from this app.").replace("{version}", $e?.version ?? "")}`,
1069
- confirmLabel: b("devportal.publishToOrganization", "Publish to my organization"),
1070
- cancelLabel: b("devportal.cancel", "Cancel"),
1081
+ onConfirm: jt,
1082
+ title: y("devportal.publishToOrganizationTitle", "Publish to my organization"),
1083
+ description: `${y("devportal.publishToOrganizationDescription", "Version {version} goes live for the workspaces of your organization without platform review. It is never listed in the public Node Store. Workspace admins in your organization can install it from this app.").replace("{version}", nt?.version ?? "")}`,
1084
+ confirmLabel: y("devportal.publishToOrganization", "Publish to my organization"),
1085
+ cancelLabel: y("devportal.cancel", "Cancel"),
1071
1086
  variant: "success"
1072
1087
  }),
1073
- /* @__PURE__ */ _(i, {
1074
- open: Qe === "deprecate",
1088
+ /* @__PURE__ */ g(a, {
1089
+ open: tt === "deprecate",
1075
1090
  onOpenChange: (e) => {
1076
1091
  e || B(null);
1077
1092
  },
1078
- onConfirm: Pt,
1079
- title: b("devportal.deprecateSelectedVersions", "Deprecate selected versions"),
1080
- description: `${b("devportal.deprecate", "Deprecate")} ${Q.length} selected version${Q.length === 1 ? "" : "s"}? ${b("devportal.deprecateVersionsWarning", "Deprecated versions remain visible but should no longer be promoted.")}`,
1081
- confirmLabel: b("devportal.deprecate", "Deprecate"),
1082
- cancelLabel: b("devportal.cancel", "Cancel"),
1093
+ onConfirm: Rt,
1094
+ title: y("devportal.deprecateSelectedVersions", "Deprecate selected versions"),
1095
+ description: `${y("devportal.deprecate", "Deprecate")} ${Q.length} selected version${Q.length === 1 ? "" : "s"}? ${y("devportal.deprecateVersionsWarning", "Deprecated versions remain visible but should no longer be promoted.")}`,
1096
+ confirmLabel: y("devportal.deprecate", "Deprecate"),
1097
+ cancelLabel: y("devportal.cancel", "Cancel"),
1083
1098
  variant: "warning"
1084
1099
  })
1085
1100
  ]
@@ -1087,6 +1102,6 @@ var ke = () => {
1087
1102
  });
1088
1103
  };
1089
1104
  //#endregion
1090
- export { ke as ApplicationVersionsPage };
1105
+ export { je as ApplicationVersionsPage };
1091
1106
 
1092
1107
  //# sourceMappingURL=ApplicationVersionsPage.js.map