@burdenoff/microfe-devportal 2026.720.6 → 2026.720.7

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.
@@ -5,13 +5,14 @@ import { useCreateApplicationMutation as r, useGetMyOrganizationsQuery as i } fr
5
5
  import { PageLayout as a, PageSection as o } from "../components/PageLayout.js";
6
6
  import { InputField as s, SelectField as c, TextareaField as l } from "../components/FormField.js";
7
7
  import { PermissionGuard as u } from "../components/PermissionGuard.js";
8
+ import { MarkdownEditor as d } from "../components/MarkdownEditor.js";
8
9
  import "../components/index.js";
9
- import { useRef as ee, useState as d } from "react";
10
- import { useI18n as te } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
11
- import { ArrowLeft as f, Box as p, Check as m, ChevronRight as h, GitFork as g, Info as _, Loader2 as v, Puzzle as y, Save as b, X as x } from "lucide-react";
12
- import { Fragment as S, jsx as C, jsxs as w } from "react/jsx-runtime";
10
+ import { useRef as f, useState as p } from "react";
11
+ import { useI18n as m } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
12
+ import { ArrowLeft as h, Box as g, Check as _, ChevronRight as v, GitFork as y, Info as b, Loader2 as x, Puzzle as S, Save as ee, X as te } from "lucide-react";
13
+ import { Fragment as C, jsx as w, jsxs as T } from "react/jsx-runtime";
13
14
  //#region src/devportal/pages/CreateApplicationPage.tsx
14
- var T = [
15
+ var E = [
15
16
  {
16
17
  id: "auth",
17
18
  label: "Authentication",
@@ -83,10 +84,10 @@ var T = [
83
84
  description: "Access control configuration"
84
85
  }
85
86
  ];
86
- function E() {
87
- return Object.fromEntries(T.map((e) => [e.id, "none"]));
87
+ function D() {
88
+ return Object.fromEntries(E.map((e) => [e.id, "none"]));
88
89
  }
89
- function D(e) {
90
+ function ne(e) {
90
91
  return Object.entries(e).filter(([, e]) => e !== "none").map(([e, t]) => ({
91
92
  resource: e,
92
93
  level: t
@@ -137,34 +138,34 @@ var O = [
137
138
  value: "trigger",
138
139
  label: "Triggers"
139
140
  }
140
- ], j = ({ icon: e, title: n, description: r, bullets: i, selected: a, onClick: o }) => /* @__PURE__ */ w("button", {
141
+ ], j = ({ icon: e, title: n, description: r, bullets: i, selected: a, onClick: o }) => /* @__PURE__ */ T("button", {
141
142
  type: "button",
142
143
  onClick: o,
143
144
  className: t("relative flex flex-col gap-3 rounded-xl border-2 p-6 text-left transition-all hover:border-primary/50 hover:shadow-sm", a ? "border-primary bg-action-primary-bg/5 shadow-sm" : "border-border-subtle bg-bg-surface"),
144
145
  children: [
145
- a && /* @__PURE__ */ C("span", {
146
+ a && /* @__PURE__ */ w("span", {
146
147
  className: "absolute top-4 right-4 flex h-5 w-5 items-center justify-center rounded-full bg-action-primary-bg text-action-primary-text",
147
- children: /* @__PURE__ */ C(m, { size: 12 })
148
+ children: /* @__PURE__ */ w(_, { size: 12 })
148
149
  }),
149
- /* @__PURE__ */ C("div", {
150
+ /* @__PURE__ */ w("div", {
150
151
  className: "flex h-10 w-10 items-center justify-center rounded-lg bg-bg-sunken",
151
- children: /* @__PURE__ */ C(e, {
152
+ children: /* @__PURE__ */ w(e, {
152
153
  size: 22,
153
154
  className: "text-text-primary"
154
155
  })
155
156
  }),
156
- /* @__PURE__ */ w("div", { children: [/* @__PURE__ */ C("p", {
157
+ /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
157
158
  className: "font-semibold text-text-primary",
158
159
  children: n
159
- }), /* @__PURE__ */ C("p", {
160
+ }), /* @__PURE__ */ w("p", {
160
161
  className: "mt-1 text-sm text-text-secondary",
161
162
  children: r
162
163
  })] }),
163
- /* @__PURE__ */ C("ul", {
164
+ /* @__PURE__ */ w("ul", {
164
165
  className: "mt-1 space-y-1",
165
- children: i.map((e) => /* @__PURE__ */ w("li", {
166
+ children: i.map((e) => /* @__PURE__ */ T("li", {
166
167
  className: "flex items-center gap-2 text-xs text-text-secondary",
167
- children: [/* @__PURE__ */ C(h, {
168
+ children: [/* @__PURE__ */ w(v, {
168
169
  size: 12,
169
170
  className: "flex-shrink-0 text-primary"
170
171
  }), e]
@@ -181,35 +182,35 @@ var O = [
181
182
  read: "Read",
182
183
  write: "Read & Write"
183
184
  };
184
- return /* @__PURE__ */ C("div", {
185
+ return /* @__PURE__ */ w("div", {
185
186
  className: "overflow-x-auto rounded-lg border border-border-subtle",
186
- children: /* @__PURE__ */ w("table", {
187
+ children: /* @__PURE__ */ T("table", {
187
188
  className: "w-full text-sm",
188
- children: [/* @__PURE__ */ C("thead", { children: /* @__PURE__ */ w("tr", {
189
+ children: [/* @__PURE__ */ w("thead", { children: /* @__PURE__ */ T("tr", {
189
190
  className: "border-b border-border-subtle bg-bg-sunken/50",
190
- children: [/* @__PURE__ */ C("th", {
191
+ children: [/* @__PURE__ */ w("th", {
191
192
  className: "px-4 py-3 text-left font-medium text-text-secondary w-1/2",
192
193
  children: "Resource"
193
- }), n.map((e) => /* @__PURE__ */ C("th", {
194
+ }), n.map((e) => /* @__PURE__ */ w("th", {
194
195
  className: "px-4 py-3 text-center font-medium text-text-secondary",
195
196
  children: r[e]
196
197
  }, e))]
197
- }) }), /* @__PURE__ */ C("tbody", {
198
+ }) }), /* @__PURE__ */ w("tbody", {
198
199
  className: "divide-y divide-border",
199
- children: T.map((r) => /* @__PURE__ */ w("tr", {
200
+ children: E.map((r) => /* @__PURE__ */ T("tr", {
200
201
  className: "hover:bg-bg-sunken/30 transition-colors",
201
- children: [/* @__PURE__ */ w("td", {
202
+ children: [/* @__PURE__ */ T("td", {
202
203
  className: "px-4 py-3",
203
- children: [/* @__PURE__ */ C("p", {
204
+ children: [/* @__PURE__ */ w("p", {
204
205
  className: "font-medium text-text-primary",
205
206
  children: r.label
206
- }), /* @__PURE__ */ C("p", {
207
+ }), /* @__PURE__ */ w("p", {
207
208
  className: "text-xs text-text-secondary",
208
209
  children: r.description
209
210
  })]
210
- }), n.map((n) => /* @__PURE__ */ C("td", {
211
+ }), n.map((n) => /* @__PURE__ */ w("td", {
211
212
  className: "px-4 py-3 text-center",
212
- children: /* @__PURE__ */ C("input", {
213
+ children: /* @__PURE__ */ w("input", {
213
214
  type: "radio",
214
215
  name: `permission-${r.id}`,
215
216
  value: n,
@@ -222,7 +223,7 @@ var O = [
222
223
  })]
223
224
  })
224
225
  });
225
- }, ne = [
226
+ }, N = [
226
227
  {
227
228
  value: "fluidgrids",
228
229
  label: "FluidGrids"
@@ -239,18 +240,18 @@ var O = [
239
240
  value: "botlit",
240
241
  label: "Botlit"
241
242
  }
242
- ], N = () => {
243
- let { navigate: h, basePath: T, activeOrgId: N } = e(), { t: re } = te(), ie = (e, t) => {
243
+ ], P = () => {
244
+ let { navigate: v, basePath: E, activeOrgId: P } = e(), { t: re } = m(), ie = (e, t) => {
244
245
  let n = re(e);
245
246
  return n === e ? t : n;
246
- }, ae = n(), [P, F] = d(null), [I, L] = d([]), [R, z] = d(E()), B = ee(!1), [V, H] = d({
247
+ }, ae = n(), [F, I] = p(null), [L, R] = p([]), [z, B] = p(D()), V = f(!1), [H, U] = p({
247
248
  name: "",
248
249
  slug: "",
249
250
  shortDescription: "",
250
251
  description: "",
251
252
  category: "",
252
253
  visibility: "PUBLIC",
253
- developerOrganizationId: N ?? "",
254
+ developerOrganizationId: P ?? "",
254
255
  websiteUrl: "",
255
256
  githubUrl: "",
256
257
  documentationUrl: "",
@@ -258,108 +259,108 @@ var O = [
258
259
  oauthAuthUrl: "",
259
260
  oauthTokenUrl: "",
260
261
  oauthRevokeUrl: ""
261
- }), [U, W] = d({}), [G, { loading: K }] = r(), { data: q } = i({ fetchPolicy: "cache-and-network" }), J = [{
262
+ }), [W, G] = p({}), [K, { loading: q }] = r(), { data: oe } = i({ fetchPolicy: "cache-and-network" }), J = [{
262
263
  value: "",
263
264
  label: "No organization (personal)"
264
- }, ...(q?.myDeveloperOrganizations ?? []).map((e) => ({
265
+ }, ...(oe?.myDeveloperOrganizations ?? []).map((e) => ({
265
266
  value: e.id,
266
267
  label: e.name
267
- }))], Y = (e) => h?.(`${T}${e}`), oe = (e) => e.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-|-$/g, ""), se = (e) => {
268
+ }))], Y = (e) => v?.(`${E}${e}`), se = (e) => e.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-|-$/g, ""), ce = (e) => {
268
269
  let t = e.target.value;
269
- H((e) => ({
270
+ U((e) => ({
270
271
  ...e,
271
272
  name: t,
272
- slug: B.current ? e.slug : oe(t)
273
- })), U.name && W((e) => ({
273
+ slug: V.current ? e.slug : se(t)
274
+ })), W.name && G((e) => ({
274
275
  ...e,
275
276
  name: void 0
276
277
  }));
277
- }, ce = (e) => {
278
- B.current = !0;
278
+ }, le = (e) => {
279
+ V.current = !0;
279
280
  let t = e.target.value.toLowerCase().replace(/[^a-z0-9-]/g, "");
280
- H((e) => ({
281
+ U((e) => ({
281
282
  ...e,
282
283
  slug: t
283
- })), U.slug && W((e) => ({
284
+ })), W.slug && G((e) => ({
284
285
  ...e,
285
286
  slug: void 0
286
287
  }));
287
288
  }, X = (e, t) => {
288
- H((n) => ({
289
+ U((n) => ({
289
290
  ...n,
290
291
  [e]: t
291
- })), (U[e] || U._submit) && W((t) => ({
292
+ })), (W[e] || W._submit) && G((t) => ({
292
293
  ...t,
293
294
  [e]: void 0,
294
295
  _submit: void 0
295
296
  }));
296
297
  }, Z = (e, t) => {
297
- z((n) => ({
298
+ B((n) => ({
298
299
  ...n,
299
300
  [e]: t
300
301
  }));
301
- }, le = () => {
302
+ }, ue = () => {
302
303
  let e = {};
303
- return V.name.trim() ? V.name.length < 3 ? e.name = "Name must be at least 3 characters" : V.name.length > 100 && (e.name = "Name must be less than 100 characters") : e.name = "Name is required", V.slug.trim() ? /^[a-z0-9-]+$/.test(V.slug) || (e.slug = "Slug can only contain lowercase letters, numbers, and hyphens") : e.slug = "Slug is required", V.shortDescription.trim() ? V.shortDescription.length > 200 && (e.shortDescription = "Short description must be less than 200 characters") : e.shortDescription = "Short description is required", V.category || (e.category = "Category is required"), P !== "app" && I.length === 0 && (e.compatibleProducts = "Select at least one compatible product so users can find this in the right store"), W(e), Object.keys(e).length === 0;
304
- }, Q = () => P === "node" ? "NODE" : P === "workflow" ? "WORKFLOW" : "API_INTEGRATION", ue = async (e) => {
305
- if (e.preventDefault(), !le() || !P) return;
306
- let t = P === "app" ? { permissions: D(R) } : null;
304
+ return H.name.trim() ? H.name.length < 3 ? e.name = "Name must be at least 3 characters" : H.name.length > 100 && (e.name = "Name must be less than 100 characters") : e.name = "Name is required", H.slug.trim() ? /^[a-z0-9-]+$/.test(H.slug) || (e.slug = "Slug can only contain lowercase letters, numbers, and hyphens") : e.slug = "Slug is required", H.shortDescription.trim() ? H.shortDescription.length > 200 && (e.shortDescription = "Short description must be less than 200 characters") : e.shortDescription = "Short description is required", H.category || (e.category = "Category is required"), F !== "app" && L.length === 0 && (e.compatibleProducts = "Select at least one compatible product so users can find this in the right store"), G(e), Object.keys(e).length === 0;
305
+ }, Q = () => F === "node" ? "NODE" : F === "workflow" ? "WORKFLOW" : "API_INTEGRATION", de = async (e) => {
306
+ if (e.preventDefault(), !ue() || !F) return;
307
+ let t = F === "app" ? { permissions: ne(z) } : null;
307
308
  try {
308
- let e = await G({ variables: { input: {
309
- name: V.name,
310
- slug: V.slug || void 0,
311
- shortDescription: V.shortDescription || void 0,
312
- description: V.description || void 0,
313
- category: V.category || void 0,
309
+ let e = await K({ variables: { input: {
310
+ name: H.name,
311
+ slug: H.slug || void 0,
312
+ shortDescription: H.shortDescription || void 0,
313
+ description: H.description || void 0,
314
+ category: H.category || void 0,
314
315
  appType: Q(),
315
- visibility: V.visibility,
316
- developerOrganizationId: V.developerOrganizationId || void 0,
317
- websiteUrl: V.websiteUrl || void 0,
318
- githubUrl: V.githubUrl || void 0,
319
- documentationUrl: V.documentationUrl || void 0,
320
- supportUrl: V.supportUrl || void 0,
316
+ visibility: H.visibility,
317
+ developerOrganizationId: H.developerOrganizationId || void 0,
318
+ websiteUrl: H.websiteUrl || void 0,
319
+ githubUrl: H.githubUrl || void 0,
320
+ documentationUrl: H.documentationUrl || void 0,
321
+ supportUrl: H.supportUrl || void 0,
321
322
  manifest: t ?? void 0,
322
- compatibleProducts: I.length > 0 ? I : void 0,
323
- ...P === "app" && {
324
- oauthAuthUrl: V.oauthAuthUrl || void 0,
325
- oauthTokenUrl: V.oauthTokenUrl || void 0,
326
- oauthRevokeUrl: V.oauthRevokeUrl || void 0
323
+ compatibleProducts: L.length > 0 ? L : void 0,
324
+ ...F === "app" && {
325
+ oauthAuthUrl: H.oauthAuthUrl || void 0,
326
+ oauthTokenUrl: H.oauthTokenUrl || void 0,
327
+ oauthRevokeUrl: H.oauthRevokeUrl || void 0
327
328
  }
328
329
  } } });
329
330
  e.data?.createApplication?.id && (ae.emit("devportal.app.created", {
330
331
  appId: e.data.createApplication.id,
331
- name: V.name,
332
+ name: H.name,
332
333
  appType: Q(),
333
- organizationId: V.developerOrganizationId || null
334
+ organizationId: H.developerOrganizationId || null
334
335
  }), Y(`/apps/${e.data.createApplication.id}`));
335
336
  } catch (e) {
336
337
  let t = [];
337
338
  e && typeof e == "object" && "graphQLErrors" in e && Array.isArray(e.graphQLErrors) && e.graphQLErrors.forEach((e) => t.push(e.message)), e instanceof Error && t.push(e.message);
338
339
  let n = t.join(" ").toLowerCase();
339
- n.includes("slug") || n.includes("already exist") || n.includes("unique") || n.includes("conflict") || n.includes("duplicate") ? W((e) => ({
340
+ n.includes("slug") || n.includes("already exist") || n.includes("unique") || n.includes("conflict") || n.includes("duplicate") ? G((e) => ({
340
341
  ...e,
341
342
  slug: "This slug is already taken — choose a different one"
342
- })) : W((e) => ({
343
+ })) : G((e) => ({
343
344
  ...e,
344
345
  _submit: t[0] ?? "Something went wrong. Please try again."
345
346
  }));
346
347
  }
347
348
  };
348
- if (!P) return /* @__PURE__ */ C(u, {
349
+ if (!F) return /* @__PURE__ */ w(u, {
349
350
  authOnly: !0,
350
- children: /* @__PURE__ */ C(a, {
351
+ children: /* @__PURE__ */ w(a, {
351
352
  title: "What do you want to build?",
352
353
  description: "Choose a builder type to get started",
353
354
  purpose: "Pick the kind of integration you are creating — a standard app, a Node package, or a workflow. Your choice sets up the right defaults (credentials, permissions, and where it can be installed) so you only fill in what that type actually needs.",
354
- backLink: `${T}/apps`,
355
+ backLink: `${E}/apps`,
355
356
  backLabel: "Back to Applications",
356
- children: /* @__PURE__ */ w("div", {
357
+ children: /* @__PURE__ */ T("div", {
357
358
  className: "max-w-3xl space-y-6",
358
- children: [/* @__PURE__ */ w("div", {
359
+ children: [/* @__PURE__ */ T("div", {
359
360
  className: "grid gap-4 sm:grid-cols-3",
360
361
  children: [
361
- /* @__PURE__ */ C(j, {
362
- icon: p,
362
+ /* @__PURE__ */ w(j, {
363
+ icon: g,
363
364
  title: "App",
364
365
  description: "Build integrations that connect your service to the platform using OAuth tokens.",
365
366
  bullets: [
@@ -368,11 +369,11 @@ var O = [
368
369
  "Webhook events",
369
370
  "Publish to app store"
370
371
  ],
371
- selected: P === "app",
372
- onClick: () => F("app")
372
+ selected: F === "app",
373
+ onClick: () => I("app")
373
374
  }),
374
- /* @__PURE__ */ C(j, {
375
- icon: y,
375
+ /* @__PURE__ */ w(j, {
376
+ icon: S,
376
377
  title: "Node",
377
378
  description: "Build custom FluidGrids nodes that users can drag into their visual workflows.",
378
379
  bullets: [
@@ -381,11 +382,11 @@ var O = [
381
382
  "Versioned releases",
382
383
  "Publish to node store"
383
384
  ],
384
- selected: P === "node",
385
- onClick: () => F("node")
385
+ selected: F === "node",
386
+ onClick: () => I("node")
386
387
  }),
387
- /* @__PURE__ */ C(j, {
388
- icon: g,
388
+ /* @__PURE__ */ w(j, {
389
+ icon: y,
389
390
  title: "Workflow",
390
391
  description: "Build reusable automation workflows that users can import and customize.",
391
392
  bullets: [
@@ -394,137 +395,137 @@ var O = [
394
395
  "Versioned releases",
395
396
  "Publish to workflow store"
396
397
  ],
397
- selected: P === "workflow",
398
- onClick: () => F("workflow")
398
+ selected: F === "workflow",
399
+ onClick: () => I("workflow")
399
400
  })
400
401
  ]
401
- }), /* @__PURE__ */ w("div", {
402
+ }), /* @__PURE__ */ T("div", {
402
403
  className: "rounded-lg border border-border-subtle bg-bg-sunken/30 p-4 flex gap-3 text-sm text-text-secondary",
403
- children: [/* @__PURE__ */ C(_, {
404
+ children: [/* @__PURE__ */ w(b, {
404
405
  size: 16,
405
406
  className: "flex-shrink-0 mt-0.5"
406
- }), /* @__PURE__ */ C("p", { children: "Apps use OAuth to interact with platform data. Nodes and Workflows are packaged files you upload after creation." })]
407
+ }), /* @__PURE__ */ w("p", { children: "Apps use OAuth to interact with platform data. Nodes and Workflows are packaged files you upload after creation." })]
407
408
  })]
408
409
  })
409
410
  })
410
411
  });
411
- let $ = P === "app" ? "App" : P === "node" ? "Node" : "Workflow", de = C(P === "app" ? p : P === "node" ? y : g, { size: 16 });
412
- return /* @__PURE__ */ C(u, {
412
+ let $ = F === "app" ? "App" : F === "node" ? "Node" : "Workflow", fe = w(F === "app" ? g : F === "node" ? S : y, { size: 16 });
413
+ return /* @__PURE__ */ w(u, {
413
414
  authOnly: !0,
414
- children: /* @__PURE__ */ C(a, {
415
+ children: /* @__PURE__ */ w(a, {
415
416
  title: `Create ${$}`,
416
- description: P === "app" ? "Register a new app integration with OAuth permissions" : P === "node" ? "Register a new FluidGrids node package" : "Register a new reusable automation workflow",
417
- purpose: P === "workflow" ? "Give your workflow a name and description. Once created you can upload your workflow definition in the Versions tab, then publish it to the store or generate a shareable public link." : P === "node" ? "Give your node a name and description. Once created you can upload your ZIP bundle and manifest in the Versions tab, then publish it to the node store when it is ready for users." : "Give your integration a name, description, and the permissions it will request. Once created you will get credentials and can configure webhooks, then publish it to the marketplace when it is ready for users.",
418
- backLink: `${T}/apps`,
417
+ description: F === "app" ? "Register a new app integration with OAuth permissions" : F === "node" ? "Register a new FluidGrids node package" : "Register a new reusable automation workflow",
418
+ purpose: F === "workflow" ? "Give your workflow a name and description. Once created you can upload your workflow definition in the Versions tab, then publish it to the store or generate a shareable public link." : F === "node" ? "Give your node a name and description. Once created you can upload your ZIP bundle and manifest in the Versions tab, then publish it to the node store when it is ready for users." : "Give your integration a name, description, and the permissions it will request. Once created you will get credentials and can configure webhooks, then publish it to the marketplace when it is ready for users.",
419
+ backLink: `${E}/apps`,
419
420
  backLabel: "Back to Applications",
420
- children: /* @__PURE__ */ w("form", {
421
- onSubmit: ue,
421
+ children: /* @__PURE__ */ T("form", {
422
+ onSubmit: de,
422
423
  className: "space-y-8 max-w-3xl",
423
424
  children: [
424
- /* @__PURE__ */ w("div", {
425
+ /* @__PURE__ */ T("div", {
425
426
  className: "flex items-center gap-3",
426
- children: [/* @__PURE__ */ w("button", {
427
+ children: [/* @__PURE__ */ T("button", {
427
428
  type: "button",
428
- onClick: () => F(null),
429
+ onClick: () => I(null),
429
430
  className: "flex items-center gap-1.5 text-sm text-text-secondary hover:text-text-primary transition-colors",
430
- children: [/* @__PURE__ */ C(f, { size: 14 }), "Change type"]
431
- }), /* @__PURE__ */ w("span", {
431
+ children: [/* @__PURE__ */ w(h, { size: 14 }), "Change type"]
432
+ }), /* @__PURE__ */ T("span", {
432
433
  className: "flex items-center gap-1.5 rounded-full border border-border-subtle bg-bg-sunken px-3 py-1 text-xs font-medium",
433
- children: [de, $]
434
+ children: [fe, $]
434
435
  })]
435
436
  }),
436
- /* @__PURE__ */ C(o, {
437
+ /* @__PURE__ */ w(o, {
437
438
  title: "Basic Information",
438
439
  description: "Core details about your application",
439
- children: /* @__PURE__ */ w("div", {
440
+ children: /* @__PURE__ */ T("div", {
440
441
  className: "space-y-4",
441
442
  children: [
442
- /* @__PURE__ */ C(s, {
443
+ /* @__PURE__ */ w(s, {
443
444
  label: "Name",
444
- value: V.name,
445
- onChange: se,
446
- placeholder: P === "app" ? "My Integration" : P === "node" ? "HTTP Request" : "Onboarding Flow",
445
+ value: H.name,
446
+ onChange: ce,
447
+ placeholder: F === "app" ? "My Integration" : F === "node" ? "HTTP Request" : "Onboarding Flow",
447
448
  required: !0,
448
- error: U.name
449
+ error: W.name
449
450
  }),
450
- /* @__PURE__ */ C(s, {
451
+ /* @__PURE__ */ w(s, {
451
452
  label: "Slug",
452
- value: V.slug,
453
- onChange: ce,
453
+ value: H.slug,
454
+ onChange: le,
454
455
  placeholder: "my-integration",
455
456
  required: !0,
456
- error: U.slug,
457
- hint: B.current ? "Only lowercase letters, numbers, and hyphens" : "Auto-generated from name — edit to customise"
457
+ error: W.slug,
458
+ hint: V.current ? "Only lowercase letters, numbers, and hyphens" : "Auto-generated from name — edit to customise"
458
459
  }),
459
- /* @__PURE__ */ C(l, {
460
+ /* @__PURE__ */ w(l, {
460
461
  label: "Short Description",
461
- value: V.shortDescription,
462
+ value: H.shortDescription,
462
463
  onChange: (e) => X("shortDescription", e.target.value),
463
464
  placeholder: "Briefly describe what this does",
464
465
  required: !0,
465
- error: U.shortDescription,
466
- hint: `${V.shortDescription.length}/200 characters`,
466
+ error: W.shortDescription,
467
+ hint: `${H.shortDescription.length}/200 characters`,
467
468
  rows: 2
468
469
  }),
469
- /* @__PURE__ */ w("div", {
470
+ /* @__PURE__ */ T("div", {
470
471
  className: "grid gap-4 sm:grid-cols-2",
471
- children: [/* @__PURE__ */ C(c, {
472
+ children: [/* @__PURE__ */ w(c, {
472
473
  label: "Category",
473
- value: V.category,
474
+ value: H.category,
474
475
  onChange: (e) => X("category", e.target.value),
475
476
  options: A,
476
477
  placeholder: "Select a category…",
477
478
  required: !0,
478
- error: U.category,
479
+ error: W.category,
479
480
  hint: "Helps users discover your item in the store"
480
- }), /* @__PURE__ */ C(c, {
481
+ }), /* @__PURE__ */ w(c, {
481
482
  label: "Visibility",
482
- value: V.visibility,
483
+ value: H.visibility,
483
484
  onChange: (e) => X("visibility", e.target.value),
484
- options: P === "workflow" ? k : O,
485
+ options: F === "workflow" ? k : O,
485
486
  required: !0,
486
- hint: V.visibility === "PUBLIC" ? "Listed in the marketplace after review approval — anyone can discover and install it" : V.visibility === "UNLISTED" ? "Not in the store, but share with anyone via a direct link. You can still submit for marketplace review later" : V.visibility === "INTERNAL" ? "Visible to all members of your developer organization — no one outside can access it" : "Only you (the creator) can see this — other org members cannot access it"
487
+ hint: H.visibility === "PUBLIC" ? "Listed in the marketplace after review approval — anyone can discover and install it" : H.visibility === "UNLISTED" ? "Not in the store, but share with anyone via a direct link. You can still submit for marketplace review later" : H.visibility === "INTERNAL" ? "Visible to all members of your developer organization — no one outside can access it" : "Only you (the creator) can see this — other org members cannot access it"
487
488
  })]
488
489
  }),
489
- P !== "app" && /* @__PURE__ */ w("div", {
490
+ F !== "app" && /* @__PURE__ */ T("div", {
490
491
  className: "space-y-2",
491
492
  children: [
492
- /* @__PURE__ */ w("div", { children: [/* @__PURE__ */ w("label", {
493
+ /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ T("label", {
493
494
  className: "block text-sm font-medium text-text-primary",
494
- children: ["Compatible Products", /* @__PURE__ */ C("span", {
495
+ children: ["Compatible Products", /* @__PURE__ */ w("span", {
495
496
  className: "text-status-error-text ml-1",
496
497
  children: "*"
497
498
  })]
498
- }), /* @__PURE__ */ w("p", {
499
+ }), /* @__PURE__ */ T("p", {
499
500
  className: "text-xs text-text-secondary mt-0.5",
500
501
  children: [
501
502
  "Select which products this ",
502
- P,
503
+ F,
503
504
  " works with. Users will see it in those products' node stores."
504
505
  ]
505
506
  })] }),
506
- /* @__PURE__ */ C("div", {
507
+ /* @__PURE__ */ w("div", {
507
508
  className: "flex flex-wrap gap-3",
508
- children: ne.map((e) => {
509
- let n = I.includes(e.value);
510
- return /* @__PURE__ */ w("label", {
511
- className: t("flex items-center gap-2 cursor-pointer rounded-md border px-3 py-2 text-sm transition-colors", n ? "border-primary bg-primary/10 text-text-primary" : "border-border-subtle hover:border-border text-text-secondary hover:text-text-primary", U.compatibleProducts && !n && "border-status-error-bg/50"),
509
+ children: N.map((e) => {
510
+ let n = L.includes(e.value);
511
+ return /* @__PURE__ */ T("label", {
512
+ className: t("flex items-center gap-2 cursor-pointer rounded-md border px-3 py-2 text-sm transition-colors", n ? "border-primary bg-primary/10 text-text-primary" : "border-border-subtle hover:border-border text-text-secondary hover:text-text-primary", W.compatibleProducts && !n && "border-status-error-bg/50"),
512
513
  children: [
513
- /* @__PURE__ */ C("input", {
514
+ /* @__PURE__ */ w("input", {
514
515
  type: "checkbox",
515
516
  className: "sr-only",
516
517
  checked: n,
517
518
  onChange: () => {
518
- L((t) => {
519
+ R((t) => {
519
520
  let r = n ? t.filter((t) => t !== e.value) : [...t, e.value];
520
- return r.length > 0 && W((e) => ({
521
+ return r.length > 0 && G((e) => ({
521
522
  ...e,
522
523
  compatibleProducts: void 0
523
524
  })), r;
524
525
  });
525
526
  }
526
527
  }),
527
- n && /* @__PURE__ */ C(m, {
528
+ n && /* @__PURE__ */ w(_, {
528
529
  size: 14,
529
530
  className: "text-primary flex-shrink-0"
530
531
  }),
@@ -533,16 +534,16 @@ var O = [
533
534
  }, e.value);
534
535
  })
535
536
  }),
536
- U.compatibleProducts && /* @__PURE__ */ C("p", {
537
+ W.compatibleProducts && /* @__PURE__ */ w("p", {
537
538
  className: "text-xs text-status-error-text",
538
- children: U.compatibleProducts
539
+ children: W.compatibleProducts
539
540
  })
540
541
  ]
541
542
  }),
542
- /* @__PURE__ */ C(l, {
543
+ /* @__PURE__ */ w(d, {
543
544
  label: "Full Description",
544
- value: V.description,
545
- onChange: (e) => X("description", e.target.value),
545
+ value: H.description,
546
+ onChange: (e) => X("description", e),
546
547
  placeholder: "Detailed description, features, and use cases...",
547
548
  rows: 5,
548
549
  hint: "Markdown supported"
@@ -550,89 +551,89 @@ var O = [
550
551
  ]
551
552
  })
552
553
  }),
553
- J.length > 2 && /* @__PURE__ */ C(o, {
554
+ J.length > 2 && /* @__PURE__ */ w(o, {
554
555
  title: "Organization",
555
556
  description: "Which developer organization owns this?",
556
- children: /* @__PURE__ */ C(c, {
557
+ children: /* @__PURE__ */ w(c, {
557
558
  label: "Developer Organization",
558
- value: V.developerOrganizationId,
559
+ value: H.developerOrganizationId,
559
560
  onChange: (e) => X("developerOrganizationId", e.target.value),
560
561
  options: J
561
562
  })
562
563
  }),
563
- P === "app" && /* @__PURE__ */ w(o, {
564
+ F === "app" && /* @__PURE__ */ T(o, {
564
565
  title: "Permissions",
565
566
  description: "Choose what data your app can access. Users will see these permissions when authorizing your app — like GitHub Apps.",
566
- children: [/* @__PURE__ */ C(M, {
567
- permissions: R,
567
+ children: [/* @__PURE__ */ w(M, {
568
+ permissions: z,
568
569
  onChange: Z
569
- }), /* @__PURE__ */ w("div", {
570
+ }), /* @__PURE__ */ T("div", {
570
571
  className: "mt-3 flex gap-2 rounded-lg border border-border-subtle bg-bg-sunken/30 p-3 text-xs text-text-secondary",
571
- children: [/* @__PURE__ */ C(_, {
572
+ children: [/* @__PURE__ */ w(b, {
572
573
  size: 14,
573
574
  className: "flex-shrink-0 mt-0.5"
574
- }), /* @__PURE__ */ w("span", { children: [/* @__PURE__ */ C("strong", { children: "Read & Write" }), " implies Read. Select only what your app genuinely needs — fewer permissions build more user trust."] })]
575
+ }), /* @__PURE__ */ T("span", { children: [/* @__PURE__ */ w("strong", { children: "Read & Write" }), " implies Read. Select only what your app genuinely needs — fewer permissions build more user trust."] })]
575
576
  })]
576
577
  }),
577
- P === "app" && /* @__PURE__ */ C(o, {
578
+ F === "app" && /* @__PURE__ */ w(o, {
578
579
  title: "Integration Setup",
579
580
  description: "Configure the endpoints for your integration. After a user installs, we redirect them to your callback URL so your server can complete the connection.",
580
- children: /* @__PURE__ */ w("div", {
581
+ children: /* @__PURE__ */ T("div", {
581
582
  className: "space-y-4",
582
- children: [/* @__PURE__ */ C(s, {
583
+ children: [/* @__PURE__ */ w(s, {
583
584
  label: "Post-install Callback URL",
584
585
  type: "url",
585
- value: V.oauthAuthUrl,
586
+ value: H.oauthAuthUrl,
586
587
  onChange: (e) => X("oauthAuthUrl", e.target.value),
587
588
  placeholder: "https://yourapp.com/callback",
588
589
  hint: "Users land here after install with ?installation_id=xxx appended"
589
- }), /* @__PURE__ */ C(s, {
590
+ }), /* @__PURE__ */ w(s, {
590
591
  label: "Revoke URL",
591
592
  type: "url",
592
- value: V.oauthRevokeUrl,
593
+ value: H.oauthRevokeUrl,
593
594
  onChange: (e) => X("oauthRevokeUrl", e.target.value),
594
595
  placeholder: "https://yourapp.com/oauth/revoke",
595
596
  hint: "We POST to this URL when a user uninstalls your integration"
596
597
  })]
597
598
  })
598
599
  }),
599
- P !== "app" && /* @__PURE__ */ w("div", {
600
+ F !== "app" && /* @__PURE__ */ T("div", {
600
601
  className: "rounded-lg border border-border-subtle bg-bg-sunken/30 p-4 flex gap-3 text-sm text-text-secondary",
601
- children: [/* @__PURE__ */ C(_, {
602
+ children: [/* @__PURE__ */ w(b, {
602
603
  size: 16,
603
604
  className: "flex-shrink-0 mt-0.5"
604
- }), /* @__PURE__ */ w("div", { children: [/* @__PURE__ */ C("p", {
605
+ }), /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
605
606
  className: "font-medium text-text-primary",
606
607
  children: "File uploads"
607
- }), /* @__PURE__ */ C("p", {
608
+ }), /* @__PURE__ */ w("p", {
608
609
  className: "mt-1",
609
- children: P === "node" ? "After creating your Node, go to the Versions tab to upload your ZIP bundle and manifest.json." : "After creating your Workflow, go to the Versions tab to upload your manifest and workflow JSON definition."
610
+ children: F === "node" ? "After creating your Node, go to the Versions tab to upload your ZIP bundle and manifest.json." : "After creating your Workflow, go to the Versions tab to upload your manifest and workflow JSON definition."
610
611
  })] })]
611
612
  }),
612
- U._submit && /* @__PURE__ */ w("div", {
613
+ W._submit && /* @__PURE__ */ T("div", {
613
614
  className: "flex items-start gap-3 rounded-lg border border-status-error-bg bg-status-error-bg/10 px-4 py-3 text-sm text-status-error-text",
614
- children: [/* @__PURE__ */ C(_, {
615
+ children: [/* @__PURE__ */ w(b, {
615
616
  size: 16,
616
617
  className: "flex-shrink-0 mt-0.5"
617
- }), /* @__PURE__ */ C("span", { children: U._submit })]
618
+ }), /* @__PURE__ */ w("span", { children: W._submit })]
618
619
  }),
619
- /* @__PURE__ */ w("div", {
620
+ /* @__PURE__ */ T("div", {
620
621
  className: "flex items-center justify-end gap-3 border-t pt-6",
621
- children: [/* @__PURE__ */ w("button", {
622
+ children: [/* @__PURE__ */ T("button", {
622
623
  type: "button",
623
624
  onClick: () => Y("/apps"),
624
- disabled: K,
625
+ disabled: q,
625
626
  className: "inline-flex items-center gap-2 rounded-md border px-4 py-2 text-sm font-medium hover:bg-bg-sunken transition-colors disabled:opacity-50",
626
- children: [/* @__PURE__ */ C(x, { size: 16 }), ie("devportal.cancel", "Cancel")]
627
- }), /* @__PURE__ */ C("button", {
627
+ children: [/* @__PURE__ */ w(te, { size: 16 }), ie("devportal.cancel", "Cancel")]
628
+ }), /* @__PURE__ */ w("button", {
628
629
  type: "submit",
629
- disabled: K,
630
+ disabled: q,
630
631
  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 transition-colors disabled:opacity-50",
631
- children: K ? /* @__PURE__ */ w(S, { children: [/* @__PURE__ */ C(v, {
632
+ children: q ? /* @__PURE__ */ T(C, { children: [/* @__PURE__ */ w(x, {
632
633
  size: 16,
633
634
  className: "animate-spin"
634
- }), "Creating…"] }) : /* @__PURE__ */ w(S, { children: [
635
- /* @__PURE__ */ C(b, { size: 16 }),
635
+ }), "Creating…"] }) : /* @__PURE__ */ T(C, { children: [
636
+ /* @__PURE__ */ w(ee, { size: 16 }),
636
637
  "Create ",
637
638
  $
638
639
  ] })
@@ -644,6 +645,6 @@ var O = [
644
645
  });
645
646
  };
646
647
  //#endregion
647
- export { N as CreateApplicationPage };
648
+ export { P as CreateApplicationPage };
648
649
 
649
650
  //# sourceMappingURL=CreateApplicationPage.js.map