@burdenoff/microfe-devportal 2026.917.2 → 2026.918.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/devportal/components/MultiSelectCombobox.d.ts +38 -0
- package/dist/devportal/components/MultiSelectCombobox.d.ts.map +1 -0
- package/dist/devportal/components/MultiSelectCombobox.js +80 -0
- package/dist/devportal/components/MultiSelectCombobox.js.map +1 -0
- package/dist/devportal/components/ReportOrderIssueModal.d.ts.map +1 -1
- package/dist/devportal/components/ReportOrderIssueModal.js.map +1 -1
- package/dist/devportal/hooks/usePackageUpload.d.ts.map +1 -1
- package/dist/devportal/hooks/usePackageUpload.js.map +1 -1
- package/dist/devportal/pages/ApplicationDetailPage.d.ts.map +1 -1
- package/dist/devportal/pages/ApplicationDetailPage.js.map +1 -1
- package/dist/devportal/pages/CreateApplicationPage.d.ts.map +1 -1
- package/dist/devportal/pages/CreateApplicationPage.js +204 -217
- package/dist/devportal/pages/CreateApplicationPage.js.map +1 -1
- package/dist/devportal/pages/CreatePhysicalItemPage.d.ts.map +1 -1
- package/dist/devportal/pages/CreatePhysicalItemPage.js.map +1 -1
- package/dist/devportal/pages/EditApplicationPage.d.ts.map +1 -1
- package/dist/devportal/pages/EditApplicationPage.js +142 -154
- package/dist/devportal/pages/EditApplicationPage.js.map +1 -1
- package/dist/devportal/pages/EditPhysicalItemPage.d.ts.map +1 -1
- package/dist/devportal/pages/EditPhysicalItemPage.js.map +1 -1
- package/dist/devportal/pages/PublishPage.d.ts.map +1 -1
- package/dist/devportal/pages/PublishPage.js.map +1 -1
- package/dist/devportal/pages/SellerDashboardPage.d.ts.map +1 -1
- package/dist/devportal/pages/SellerDashboardPage.js.map +1 -1
- package/dist/devportal/pages/SellerItemsPage.d.ts.map +1 -1
- package/dist/devportal/pages/SellerItemsPage.js.map +1 -1
- package/dist/devportal/types/index.d.ts.map +1 -1
- package/dist/devportal/types/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -9,15 +9,16 @@ import { MarkdownEditor as u } from "../components/MarkdownEditor.js";
|
|
|
9
9
|
import "../components/index.js";
|
|
10
10
|
import { useProducts as ee } from "../hooks/useProducts.js";
|
|
11
11
|
import "../hooks/index.js";
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
12
|
+
import { MultiSelectCombobox as te } from "../components/MultiSelectCombobox.js";
|
|
13
|
+
import { useRef as d, useState as f } from "react";
|
|
14
|
+
import { ArrowLeft as p, Box as m, Check as h, ChevronRight as g, FileCode2 as _, GitFork as v, Info as y, LayoutDashboard as b, LayoutGrid as x, Loader2 as ne, Puzzle as S, Save as re, X as C } from "lucide-react";
|
|
15
|
+
import { Fragment as w, jsx as T, jsxs as E } from "react/jsx-runtime";
|
|
16
|
+
import { useI18n as D } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
16
17
|
//#region src/devportal/pages/CreateApplicationPage.tsx
|
|
17
|
-
var
|
|
18
|
+
var O = {
|
|
18
19
|
app: {
|
|
19
20
|
appType: "API_INTEGRATION",
|
|
20
|
-
icon:
|
|
21
|
+
icon: m,
|
|
21
22
|
label: "App",
|
|
22
23
|
pageDescription: "Register a new app integration with OAuth permissions",
|
|
23
24
|
purpose: "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.",
|
|
@@ -47,7 +48,7 @@ var k = {
|
|
|
47
48
|
},
|
|
48
49
|
workflow: {
|
|
49
50
|
appType: "WORKFLOW",
|
|
50
|
-
icon:
|
|
51
|
+
icon: v,
|
|
51
52
|
label: "Workflow",
|
|
52
53
|
pageDescription: "Register a new reusable automation workflow",
|
|
53
54
|
purpose: "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.",
|
|
@@ -62,7 +63,7 @@ var k = {
|
|
|
62
63
|
},
|
|
63
64
|
parser: {
|
|
64
65
|
appType: "PARSER",
|
|
65
|
-
icon:
|
|
66
|
+
icon: _,
|
|
66
67
|
label: "Parser",
|
|
67
68
|
pageDescription: "Register a new data parser",
|
|
68
69
|
purpose: "Give your parser a name and description. Once created you can upload its manifest in the Versions tab, then publish it to the store when it is ready for users.",
|
|
@@ -77,7 +78,7 @@ var k = {
|
|
|
77
78
|
},
|
|
78
79
|
widget: {
|
|
79
80
|
appType: "WIDGET",
|
|
80
|
-
icon:
|
|
81
|
+
icon: x,
|
|
81
82
|
label: "Widget",
|
|
82
83
|
pageDescription: "Register a new embeddable widget",
|
|
83
84
|
purpose: "Give your widget a name and description. Once created you can upload its manifest in the Versions tab, then publish it to the store when it is ready for users.",
|
|
@@ -92,7 +93,7 @@ var k = {
|
|
|
92
93
|
},
|
|
93
94
|
dashboard: {
|
|
94
95
|
appType: "DASHBOARD",
|
|
95
|
-
icon:
|
|
96
|
+
icon: b,
|
|
96
97
|
label: "Dashboard Template",
|
|
97
98
|
pageDescription: "Register a new dashboard template",
|
|
98
99
|
purpose: "Give your dashboard template a name and description. Once created you can upload its manifest in the Versions tab, then publish it to the store when it is ready for users.",
|
|
@@ -105,7 +106,7 @@ var k = {
|
|
|
105
106
|
"Publish to store"
|
|
106
107
|
]
|
|
107
108
|
}
|
|
108
|
-
},
|
|
109
|
+
}, k = [
|
|
109
110
|
{
|
|
110
111
|
id: "auth",
|
|
111
112
|
label: "Authentication",
|
|
@@ -177,16 +178,16 @@ var k = {
|
|
|
177
178
|
description: "Access control configuration"
|
|
178
179
|
}
|
|
179
180
|
];
|
|
180
|
-
function
|
|
181
|
-
return Object.fromEntries(
|
|
181
|
+
function A() {
|
|
182
|
+
return Object.fromEntries(k.map((e) => [e.id, "none"]));
|
|
182
183
|
}
|
|
183
|
-
function
|
|
184
|
+
function j(e) {
|
|
184
185
|
return Object.entries(e).filter(([, e]) => e !== "none").map(([e, t]) => ({
|
|
185
186
|
resource: e,
|
|
186
187
|
level: t
|
|
187
188
|
}));
|
|
188
189
|
}
|
|
189
|
-
var
|
|
190
|
+
var M = [
|
|
190
191
|
{
|
|
191
192
|
value: "PUBLIC",
|
|
192
193
|
label: "Public — listed in the marketplace after review"
|
|
@@ -199,10 +200,10 @@ var N = [
|
|
|
199
200
|
value: "INTERNAL",
|
|
200
201
|
label: "Internal — visible to your entire dev org"
|
|
201
202
|
}
|
|
202
|
-
],
|
|
203
|
+
], N = [...M, {
|
|
203
204
|
value: "UNLISTED",
|
|
204
205
|
label: "Unlisted — shareable via link, not listed in store"
|
|
205
|
-
}],
|
|
206
|
+
}], P = [
|
|
206
207
|
{
|
|
207
208
|
value: "ai",
|
|
208
209
|
label: "AI & Automation"
|
|
@@ -231,41 +232,41 @@ var N = [
|
|
|
231
232
|
value: "trigger",
|
|
232
233
|
label: "Triggers"
|
|
233
234
|
}
|
|
234
|
-
],
|
|
235
|
+
], F = ({ icon: e, title: n, description: r, bullets: i, selected: a, onClick: o }) => /* @__PURE__ */ E("button", {
|
|
235
236
|
type: "button",
|
|
236
237
|
onClick: o,
|
|
237
238
|
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"),
|
|
238
239
|
children: [
|
|
239
|
-
a && /* @__PURE__ */
|
|
240
|
+
a && /* @__PURE__ */ T("span", {
|
|
240
241
|
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",
|
|
241
|
-
children: /* @__PURE__ */
|
|
242
|
+
children: /* @__PURE__ */ T(h, { size: 12 })
|
|
242
243
|
}),
|
|
243
|
-
/* @__PURE__ */
|
|
244
|
+
/* @__PURE__ */ T("div", {
|
|
244
245
|
className: "flex h-10 w-10 items-center justify-center rounded-lg bg-bg-sunken",
|
|
245
|
-
children: /* @__PURE__ */
|
|
246
|
+
children: /* @__PURE__ */ T(e, {
|
|
246
247
|
size: 22,
|
|
247
248
|
className: "text-text-primary"
|
|
248
249
|
})
|
|
249
250
|
}),
|
|
250
|
-
/* @__PURE__ */
|
|
251
|
+
/* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T("p", {
|
|
251
252
|
className: "font-semibold text-text-primary",
|
|
252
253
|
children: n
|
|
253
|
-
}), /* @__PURE__ */
|
|
254
|
+
}), /* @__PURE__ */ T("p", {
|
|
254
255
|
className: "mt-1 text-sm text-text-secondary",
|
|
255
256
|
children: r
|
|
256
257
|
})] }),
|
|
257
|
-
/* @__PURE__ */
|
|
258
|
+
/* @__PURE__ */ T("ul", {
|
|
258
259
|
className: "mt-1 space-y-1",
|
|
259
|
-
children: i.map((e) => /* @__PURE__ */
|
|
260
|
+
children: i.map((e) => /* @__PURE__ */ E("li", {
|
|
260
261
|
className: "flex items-center gap-2 text-xs text-text-secondary",
|
|
261
|
-
children: [/* @__PURE__ */
|
|
262
|
+
children: [/* @__PURE__ */ T(g, {
|
|
262
263
|
size: 12,
|
|
263
264
|
className: "flex-shrink-0 text-primary"
|
|
264
265
|
}), e]
|
|
265
266
|
}, e))
|
|
266
267
|
})
|
|
267
268
|
]
|
|
268
|
-
}),
|
|
269
|
+
}), I = ({ permissions: e, onChange: t }) => {
|
|
269
270
|
let n = [
|
|
270
271
|
"none",
|
|
271
272
|
"read",
|
|
@@ -275,35 +276,35 @@ var N = [
|
|
|
275
276
|
read: "Read",
|
|
276
277
|
write: "Read & Write"
|
|
277
278
|
};
|
|
278
|
-
return /* @__PURE__ */
|
|
279
|
+
return /* @__PURE__ */ T("div", {
|
|
279
280
|
className: "overflow-x-auto rounded-lg border border-border-subtle",
|
|
280
|
-
children: /* @__PURE__ */
|
|
281
|
+
children: /* @__PURE__ */ E("table", {
|
|
281
282
|
className: "w-full text-sm",
|
|
282
|
-
children: [/* @__PURE__ */
|
|
283
|
+
children: [/* @__PURE__ */ T("thead", { children: /* @__PURE__ */ E("tr", {
|
|
283
284
|
className: "border-b border-border-subtle bg-bg-sunken/50",
|
|
284
|
-
children: [/* @__PURE__ */
|
|
285
|
+
children: [/* @__PURE__ */ T("th", {
|
|
285
286
|
className: "px-4 py-3 text-left font-medium text-text-secondary w-1/2",
|
|
286
287
|
children: "Resource"
|
|
287
|
-
}), n.map((e) => /* @__PURE__ */
|
|
288
|
+
}), n.map((e) => /* @__PURE__ */ T("th", {
|
|
288
289
|
className: "px-4 py-3 text-center font-medium text-text-secondary",
|
|
289
290
|
children: r[e]
|
|
290
291
|
}, e))]
|
|
291
|
-
}) }), /* @__PURE__ */
|
|
292
|
+
}) }), /* @__PURE__ */ T("tbody", {
|
|
292
293
|
className: "divide-y divide-border",
|
|
293
|
-
children:
|
|
294
|
+
children: k.map((r) => /* @__PURE__ */ E("tr", {
|
|
294
295
|
className: "hover:bg-bg-sunken/30 transition-colors",
|
|
295
|
-
children: [/* @__PURE__ */
|
|
296
|
+
children: [/* @__PURE__ */ E("td", {
|
|
296
297
|
className: "px-4 py-3",
|
|
297
|
-
children: [/* @__PURE__ */
|
|
298
|
+
children: [/* @__PURE__ */ T("p", {
|
|
298
299
|
className: "font-medium text-text-primary",
|
|
299
300
|
children: r.label
|
|
300
|
-
}), /* @__PURE__ */
|
|
301
|
+
}), /* @__PURE__ */ T("p", {
|
|
301
302
|
className: "text-xs text-text-secondary",
|
|
302
303
|
children: r.description
|
|
303
304
|
})]
|
|
304
|
-
}), n.map((n) => /* @__PURE__ */
|
|
305
|
+
}), n.map((n) => /* @__PURE__ */ T("td", {
|
|
305
306
|
className: "px-4 py-3 text-center",
|
|
306
|
-
children: /* @__PURE__ */
|
|
307
|
+
children: /* @__PURE__ */ T("input", {
|
|
307
308
|
type: "radio",
|
|
308
309
|
name: `permission-${r.id}`,
|
|
309
310
|
value: n,
|
|
@@ -316,18 +317,18 @@ var N = [
|
|
|
316
317
|
})]
|
|
317
318
|
})
|
|
318
319
|
});
|
|
319
|
-
},
|
|
320
|
-
let { navigate:
|
|
321
|
-
let n =
|
|
320
|
+
}, L = () => {
|
|
321
|
+
let { navigate: t, basePath: m, activeOrgId: h } = e(), { t: g } = D(), _ = (e, t) => {
|
|
322
|
+
let n = g(e);
|
|
322
323
|
return n === e ? t : n;
|
|
323
|
-
},
|
|
324
|
+
}, v = n(), { products: b } = ee(), [x, S] = f(null), [k, L] = f([]), [R, z] = f(A()), B = d(!1), [V, H] = f({
|
|
324
325
|
name: "",
|
|
325
326
|
slug: "",
|
|
326
327
|
shortDescription: "",
|
|
327
328
|
description: "",
|
|
328
329
|
category: "",
|
|
329
330
|
visibility: "PUBLIC",
|
|
330
|
-
developerOrganizationId:
|
|
331
|
+
developerOrganizationId: h ?? "",
|
|
331
332
|
websiteUrl: "",
|
|
332
333
|
githubUrl: "",
|
|
333
334
|
documentationUrl: "",
|
|
@@ -335,104 +336,104 @@ var N = [
|
|
|
335
336
|
oauthAuthUrl: "",
|
|
336
337
|
oauthTokenUrl: "",
|
|
337
338
|
oauthRevokeUrl: ""
|
|
338
|
-
}), [
|
|
339
|
+
}), [U, W] = f({}), [G, { loading: K }] = r(), { data: q } = i({ fetchPolicy: "cache-and-network" }), J = [{
|
|
339
340
|
value: "",
|
|
340
341
|
label: "No organization (personal)"
|
|
341
|
-
}, ...(
|
|
342
|
+
}, ...(q?.myDeveloperOrganizations ?? []).filter((e) => e.kind !== "PHYSICAL").map((e) => ({
|
|
342
343
|
value: e.id,
|
|
343
344
|
label: e.name
|
|
344
|
-
}))],
|
|
345
|
+
}))], Y = (e) => t?.(`${m}${e}`), ie = (e) => e.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-|-$/g, ""), ae = (e) => {
|
|
345
346
|
let t = e.target.value;
|
|
346
|
-
|
|
347
|
+
H((e) => ({
|
|
347
348
|
...e,
|
|
348
349
|
name: t,
|
|
349
|
-
slug:
|
|
350
|
-
})),
|
|
350
|
+
slug: B.current ? e.slug : ie(t)
|
|
351
|
+
})), U.name && W((e) => ({
|
|
351
352
|
...e,
|
|
352
353
|
name: void 0
|
|
353
354
|
}));
|
|
354
|
-
},
|
|
355
|
-
|
|
355
|
+
}, oe = (e) => {
|
|
356
|
+
B.current = !0;
|
|
356
357
|
let t = e.target.value.toLowerCase().replace(/[^a-z0-9-]/g, "");
|
|
357
|
-
|
|
358
|
+
H((e) => ({
|
|
358
359
|
...e,
|
|
359
360
|
slug: t
|
|
360
|
-
})),
|
|
361
|
+
})), U.slug && W((e) => ({
|
|
361
362
|
...e,
|
|
362
363
|
slug: void 0
|
|
363
364
|
}));
|
|
364
|
-
},
|
|
365
|
-
|
|
365
|
+
}, X = (e, t) => {
|
|
366
|
+
H((n) => ({
|
|
366
367
|
...n,
|
|
367
368
|
[e]: t
|
|
368
|
-
})), (
|
|
369
|
+
})), (U[e] || U._submit) && W((t) => ({
|
|
369
370
|
...t,
|
|
370
371
|
[e]: void 0,
|
|
371
372
|
_submit: void 0
|
|
372
373
|
}));
|
|
373
|
-
},
|
|
374
|
-
|
|
374
|
+
}, se = (e, t) => {
|
|
375
|
+
z((n) => ({
|
|
375
376
|
...n,
|
|
376
377
|
[e]: t
|
|
377
378
|
}));
|
|
378
|
-
},
|
|
379
|
+
}, ce = () => {
|
|
379
380
|
let e = {};
|
|
380
|
-
return
|
|
381
|
-
}, Z = () =>
|
|
382
|
-
if (e.preventDefault(), !
|
|
383
|
-
let t =
|
|
381
|
+
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"), x !== "app" && k.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;
|
|
382
|
+
}, Z = () => O[x ?? "app"].appType, le = async (e) => {
|
|
383
|
+
if (e.preventDefault(), !ce() || !x) return;
|
|
384
|
+
let t = x === "app" ? { permissions: j(R) } : null;
|
|
384
385
|
try {
|
|
385
|
-
let e = await
|
|
386
|
-
name:
|
|
387
|
-
slug:
|
|
388
|
-
shortDescription:
|
|
389
|
-
description:
|
|
390
|
-
category:
|
|
386
|
+
let e = await G({ variables: { input: {
|
|
387
|
+
name: V.name,
|
|
388
|
+
slug: V.slug || void 0,
|
|
389
|
+
shortDescription: V.shortDescription || void 0,
|
|
390
|
+
description: V.description || void 0,
|
|
391
|
+
category: V.category || void 0,
|
|
391
392
|
appType: Z(),
|
|
392
|
-
visibility:
|
|
393
|
-
developerOrganizationId:
|
|
394
|
-
websiteUrl:
|
|
395
|
-
githubUrl:
|
|
396
|
-
documentationUrl:
|
|
397
|
-
supportUrl:
|
|
393
|
+
visibility: V.visibility,
|
|
394
|
+
developerOrganizationId: V.developerOrganizationId || void 0,
|
|
395
|
+
websiteUrl: V.websiteUrl || void 0,
|
|
396
|
+
githubUrl: V.githubUrl || void 0,
|
|
397
|
+
documentationUrl: V.documentationUrl || void 0,
|
|
398
|
+
supportUrl: V.supportUrl || void 0,
|
|
398
399
|
manifest: t ?? void 0,
|
|
399
|
-
compatibleProducts:
|
|
400
|
-
...
|
|
401
|
-
oauthAuthUrl:
|
|
402
|
-
oauthTokenUrl:
|
|
403
|
-
oauthRevokeUrl:
|
|
400
|
+
compatibleProducts: k.length > 0 ? k : void 0,
|
|
401
|
+
...x === "app" && {
|
|
402
|
+
oauthAuthUrl: V.oauthAuthUrl || void 0,
|
|
403
|
+
oauthTokenUrl: V.oauthTokenUrl || void 0,
|
|
404
|
+
oauthRevokeUrl: V.oauthRevokeUrl || void 0
|
|
404
405
|
}
|
|
405
406
|
} } });
|
|
406
|
-
e.data?.createApplication?.id && (
|
|
407
|
+
e.data?.createApplication?.id && (v.emit("devportal.app.created", {
|
|
407
408
|
appId: e.data.createApplication.id,
|
|
408
|
-
name:
|
|
409
|
+
name: V.name,
|
|
409
410
|
appType: Z(),
|
|
410
|
-
organizationId:
|
|
411
|
-
}),
|
|
411
|
+
organizationId: V.developerOrganizationId || null
|
|
412
|
+
}), Y(`/apps/${e.data.createApplication.id}`));
|
|
412
413
|
} catch (e) {
|
|
413
414
|
let t = [];
|
|
414
415
|
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);
|
|
415
416
|
let n = t.join(" ").toLowerCase();
|
|
416
|
-
n.includes("slug") || n.includes("already exist") || n.includes("unique") || n.includes("conflict") || n.includes("duplicate") ?
|
|
417
|
+
n.includes("slug") || n.includes("already exist") || n.includes("unique") || n.includes("conflict") || n.includes("duplicate") ? W((e) => ({
|
|
417
418
|
...e,
|
|
418
419
|
slug: "This slug is already taken — choose a different one"
|
|
419
|
-
})) :
|
|
420
|
+
})) : W((e) => ({
|
|
420
421
|
...e,
|
|
421
422
|
_submit: t[0] ?? "Something went wrong. Please try again."
|
|
422
423
|
}));
|
|
423
424
|
}
|
|
424
425
|
};
|
|
425
|
-
if (!
|
|
426
|
+
if (!x) return /* @__PURE__ */ T(l, {
|
|
426
427
|
authOnly: !0,
|
|
427
|
-
children: /* @__PURE__ */
|
|
428
|
+
children: /* @__PURE__ */ T(a, {
|
|
428
429
|
title: "What do you want to build?",
|
|
429
430
|
description: "Choose a builder type to get started",
|
|
430
431
|
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.",
|
|
431
|
-
backLink: `${
|
|
432
|
+
backLink: `${m}/apps`,
|
|
432
433
|
backLabel: "Back to Applications",
|
|
433
|
-
children: /* @__PURE__ */
|
|
434
|
+
children: /* @__PURE__ */ E("div", {
|
|
434
435
|
className: "max-w-3xl space-y-6",
|
|
435
|
-
children: [/* @__PURE__ */
|
|
436
|
+
children: [/* @__PURE__ */ T("div", {
|
|
436
437
|
className: "grid gap-4 sm:grid-cols-3",
|
|
437
438
|
children: [
|
|
438
439
|
"app",
|
|
@@ -442,162 +443,148 @@ var N = [
|
|
|
442
443
|
"widget",
|
|
443
444
|
"dashboard"
|
|
444
445
|
].map((e) => {
|
|
445
|
-
let t =
|
|
446
|
-
return /* @__PURE__ */
|
|
446
|
+
let t = O[e];
|
|
447
|
+
return /* @__PURE__ */ T(F, {
|
|
447
448
|
icon: t.icon,
|
|
448
449
|
title: t.label,
|
|
449
450
|
description: t.cardDescription,
|
|
450
451
|
bullets: t.cardBullets,
|
|
451
|
-
selected:
|
|
452
|
-
onClick: () =>
|
|
452
|
+
selected: x === e,
|
|
453
|
+
onClick: () => S(e)
|
|
453
454
|
}, e);
|
|
454
455
|
})
|
|
455
|
-
}), /* @__PURE__ */
|
|
456
|
+
}), /* @__PURE__ */ E("div", {
|
|
456
457
|
className: "rounded-lg border border-border-subtle bg-bg-sunken/30 p-4 flex gap-3 text-sm text-text-secondary",
|
|
457
|
-
children: [/* @__PURE__ */
|
|
458
|
+
children: [/* @__PURE__ */ T(y, {
|
|
458
459
|
size: 16,
|
|
459
460
|
className: "flex-shrink-0 mt-0.5"
|
|
460
|
-
}), /* @__PURE__ */
|
|
461
|
+
}), /* @__PURE__ */ T("p", { children: "Apps use OAuth to interact with platform data. Nodes and Workflows are packaged files you upload after creation." })]
|
|
461
462
|
})]
|
|
462
463
|
})
|
|
463
464
|
})
|
|
464
465
|
});
|
|
465
|
-
let Q =
|
|
466
|
-
return /* @__PURE__ */
|
|
466
|
+
let Q = O[x ?? "app"], $ = Q.label, ue = Q.icon, de = /* @__PURE__ */ T(ue, { size: 16 });
|
|
467
|
+
return /* @__PURE__ */ T(l, {
|
|
467
468
|
authOnly: !0,
|
|
468
|
-
children: /* @__PURE__ */
|
|
469
|
+
children: /* @__PURE__ */ T(a, {
|
|
469
470
|
title: `Create ${$}`,
|
|
470
471
|
description: Q.pageDescription,
|
|
471
472
|
purpose: Q.purpose,
|
|
472
|
-
backLink: `${
|
|
473
|
+
backLink: `${m}/apps`,
|
|
473
474
|
backLabel: "Back to Applications",
|
|
474
|
-
children: /* @__PURE__ */
|
|
475
|
-
onSubmit:
|
|
475
|
+
children: /* @__PURE__ */ E("form", {
|
|
476
|
+
onSubmit: le,
|
|
476
477
|
className: "space-y-8 max-w-3xl",
|
|
477
478
|
children: [
|
|
478
|
-
/* @__PURE__ */
|
|
479
|
+
/* @__PURE__ */ E("div", {
|
|
479
480
|
className: "flex items-center gap-3",
|
|
480
|
-
children: [/* @__PURE__ */
|
|
481
|
+
children: [/* @__PURE__ */ E("button", {
|
|
481
482
|
type: "button",
|
|
482
|
-
onClick: () =>
|
|
483
|
+
onClick: () => S(null),
|
|
483
484
|
className: "flex items-center gap-1.5 text-sm text-text-secondary hover:text-text-primary transition-colors",
|
|
484
|
-
children: [/* @__PURE__ */
|
|
485
|
-
}), /* @__PURE__ */
|
|
485
|
+
children: [/* @__PURE__ */ T(p, { size: 14 }), "Change type"]
|
|
486
|
+
}), /* @__PURE__ */ E("span", {
|
|
486
487
|
className: "flex items-center gap-1.5 rounded-full border border-border-subtle bg-bg-sunken px-3 py-1 text-xs font-medium",
|
|
487
|
-
children: [
|
|
488
|
+
children: [de, $]
|
|
488
489
|
})]
|
|
489
490
|
}),
|
|
490
|
-
/* @__PURE__ */
|
|
491
|
+
/* @__PURE__ */ T(o, {
|
|
491
492
|
title: "Basic Information",
|
|
492
493
|
description: "Core details about your application",
|
|
493
|
-
children: /* @__PURE__ */
|
|
494
|
+
children: /* @__PURE__ */ E("div", {
|
|
494
495
|
className: "space-y-4",
|
|
495
496
|
children: [
|
|
496
|
-
/* @__PURE__ */
|
|
497
|
+
/* @__PURE__ */ T(s, {
|
|
497
498
|
label: "Name",
|
|
498
|
-
value:
|
|
499
|
-
onChange:
|
|
499
|
+
value: V.name,
|
|
500
|
+
onChange: ae,
|
|
500
501
|
placeholder: Q.namePlaceholder,
|
|
501
502
|
required: !0,
|
|
502
|
-
error:
|
|
503
|
+
error: U.name
|
|
503
504
|
}),
|
|
504
|
-
/* @__PURE__ */
|
|
505
|
+
/* @__PURE__ */ T(s, {
|
|
505
506
|
label: "Slug",
|
|
506
|
-
value:
|
|
507
|
-
onChange:
|
|
507
|
+
value: V.slug,
|
|
508
|
+
onChange: oe,
|
|
508
509
|
placeholder: "my-integration",
|
|
509
510
|
required: !0,
|
|
510
|
-
error:
|
|
511
|
-
hint:
|
|
511
|
+
error: U.slug,
|
|
512
|
+
hint: B.current ? "Only lowercase letters, numbers, and hyphens" : "Auto-generated from name — edit to customise"
|
|
512
513
|
}),
|
|
513
|
-
/* @__PURE__ */
|
|
514
|
+
/* @__PURE__ */ T(u, {
|
|
514
515
|
label: "Short Description",
|
|
515
|
-
value:
|
|
516
|
-
onChange: (e) =>
|
|
516
|
+
value: V.shortDescription,
|
|
517
|
+
onChange: (e) => X("shortDescription", e),
|
|
517
518
|
placeholder: "Briefly describe what this does",
|
|
518
519
|
required: !0,
|
|
519
|
-
error:
|
|
520
|
-
hint: `${
|
|
520
|
+
error: U.shortDescription,
|
|
521
|
+
hint: `${V.shortDescription.length}/200 characters`,
|
|
521
522
|
rows: 2,
|
|
522
523
|
maxLength: 200
|
|
523
524
|
}),
|
|
524
|
-
/* @__PURE__ */
|
|
525
|
+
/* @__PURE__ */ E("div", {
|
|
525
526
|
className: "grid gap-4 sm:grid-cols-2",
|
|
526
|
-
children: [/* @__PURE__ */
|
|
527
|
+
children: [/* @__PURE__ */ T(c, {
|
|
527
528
|
label: "Category",
|
|
528
|
-
value:
|
|
529
|
-
onChange: (e) =>
|
|
530
|
-
options:
|
|
529
|
+
value: V.category,
|
|
530
|
+
onChange: (e) => X("category", e.target.value),
|
|
531
|
+
options: P,
|
|
531
532
|
placeholder: "Select a category…",
|
|
532
533
|
required: !0,
|
|
533
|
-
error:
|
|
534
|
+
error: U.category,
|
|
534
535
|
hint: "Helps users discover your item in the store"
|
|
535
|
-
}), /* @__PURE__ */
|
|
536
|
+
}), /* @__PURE__ */ T(c, {
|
|
536
537
|
label: "Visibility",
|
|
537
|
-
value:
|
|
538
|
-
onChange: (e) =>
|
|
539
|
-
options:
|
|
538
|
+
value: V.visibility,
|
|
539
|
+
onChange: (e) => X("visibility", e.target.value),
|
|
540
|
+
options: x === "workflow" ? N : M,
|
|
540
541
|
required: !0,
|
|
541
|
-
hint:
|
|
542
|
+
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"
|
|
542
543
|
})]
|
|
543
544
|
}),
|
|
544
|
-
|
|
545
|
+
x !== "app" && /* @__PURE__ */ E("div", {
|
|
545
546
|
className: "space-y-2",
|
|
546
547
|
children: [
|
|
547
|
-
/* @__PURE__ */
|
|
548
|
+
/* @__PURE__ */ E("div", { children: [/* @__PURE__ */ E("label", {
|
|
548
549
|
className: "block text-sm font-medium text-text-primary",
|
|
549
|
-
children: ["Compatible Products", /* @__PURE__ */
|
|
550
|
+
children: ["Compatible Products", /* @__PURE__ */ T("span", {
|
|
550
551
|
className: "text-status-error-text ml-1",
|
|
551
552
|
children: "*"
|
|
552
553
|
})]
|
|
553
|
-
}), /* @__PURE__ */
|
|
554
|
+
}), /* @__PURE__ */ E("p", {
|
|
554
555
|
className: "text-xs text-text-secondary mt-0.5",
|
|
555
556
|
children: [
|
|
556
557
|
"Select which products this ",
|
|
557
|
-
|
|
558
|
+
x,
|
|
558
559
|
" works with. Users will see it in those products' node stores."
|
|
559
560
|
]
|
|
560
561
|
})] }),
|
|
561
|
-
/* @__PURE__ */
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
...e,
|
|
577
|
-
compatibleProducts: void 0
|
|
578
|
-
})), r;
|
|
579
|
-
});
|
|
580
|
-
}
|
|
581
|
-
}),
|
|
582
|
-
n && /* @__PURE__ */ E(m, {
|
|
583
|
-
size: 14,
|
|
584
|
-
className: "text-primary flex-shrink-0"
|
|
585
|
-
}),
|
|
586
|
-
e.name
|
|
587
|
-
]
|
|
588
|
-
}, e.id);
|
|
589
|
-
})
|
|
562
|
+
/* @__PURE__ */ T(te, {
|
|
563
|
+
options: b.map((e) => ({
|
|
564
|
+
value: e.slug,
|
|
565
|
+
label: e.name
|
|
566
|
+
})),
|
|
567
|
+
selected: k,
|
|
568
|
+
onChange: (e) => {
|
|
569
|
+
L(e), e.length > 0 && W((e) => ({
|
|
570
|
+
...e,
|
|
571
|
+
compatibleProducts: void 0
|
|
572
|
+
}));
|
|
573
|
+
},
|
|
574
|
+
placeholder: "Select products…",
|
|
575
|
+
searchPlaceholder: "Search products…",
|
|
576
|
+
error: !!U.compatibleProducts
|
|
590
577
|
}),
|
|
591
|
-
|
|
578
|
+
U.compatibleProducts && /* @__PURE__ */ T("p", {
|
|
592
579
|
className: "text-xs text-status-error-text",
|
|
593
|
-
children:
|
|
580
|
+
children: U.compatibleProducts
|
|
594
581
|
})
|
|
595
582
|
]
|
|
596
583
|
}),
|
|
597
|
-
/* @__PURE__ */
|
|
584
|
+
/* @__PURE__ */ T(u, {
|
|
598
585
|
label: "Full Description",
|
|
599
|
-
value:
|
|
600
|
-
onChange: (e) =>
|
|
586
|
+
value: V.description,
|
|
587
|
+
onChange: (e) => X("description", e),
|
|
601
588
|
placeholder: "Detailed description, features, and use cases...",
|
|
602
589
|
rows: 5,
|
|
603
590
|
hint: "Markdown supported"
|
|
@@ -605,89 +592,89 @@ var N = [
|
|
|
605
592
|
]
|
|
606
593
|
})
|
|
607
594
|
}),
|
|
608
|
-
|
|
595
|
+
J.length > 2 && /* @__PURE__ */ T(o, {
|
|
609
596
|
title: "Organization",
|
|
610
597
|
description: "Which developer organization owns this?",
|
|
611
|
-
children: /* @__PURE__ */
|
|
598
|
+
children: /* @__PURE__ */ T(c, {
|
|
612
599
|
label: "Developer Organization",
|
|
613
|
-
value:
|
|
614
|
-
onChange: (e) =>
|
|
615
|
-
options:
|
|
600
|
+
value: V.developerOrganizationId,
|
|
601
|
+
onChange: (e) => X("developerOrganizationId", e.target.value),
|
|
602
|
+
options: J
|
|
616
603
|
})
|
|
617
604
|
}),
|
|
618
|
-
|
|
605
|
+
x === "app" && /* @__PURE__ */ E(o, {
|
|
619
606
|
title: "Permissions",
|
|
620
607
|
description: "Choose what data your app can access. Users will see these permissions when authorizing your app — like GitHub Apps.",
|
|
621
|
-
children: [/* @__PURE__ */
|
|
622
|
-
permissions:
|
|
623
|
-
onChange:
|
|
624
|
-
}), /* @__PURE__ */
|
|
608
|
+
children: [/* @__PURE__ */ T(I, {
|
|
609
|
+
permissions: R,
|
|
610
|
+
onChange: se
|
|
611
|
+
}), /* @__PURE__ */ E("div", {
|
|
625
612
|
className: "mt-3 flex gap-2 rounded-lg border border-border-subtle bg-bg-sunken/30 p-3 text-xs text-text-secondary",
|
|
626
|
-
children: [/* @__PURE__ */
|
|
613
|
+
children: [/* @__PURE__ */ T(y, {
|
|
627
614
|
size: 14,
|
|
628
615
|
className: "flex-shrink-0 mt-0.5"
|
|
629
|
-
}), /* @__PURE__ */
|
|
616
|
+
}), /* @__PURE__ */ E("span", { children: [/* @__PURE__ */ T("strong", { children: "Read & Write" }), " implies Read. Select only what your app genuinely needs — fewer permissions build more user trust."] })]
|
|
630
617
|
})]
|
|
631
618
|
}),
|
|
632
|
-
|
|
619
|
+
x === "app" && /* @__PURE__ */ T(o, {
|
|
633
620
|
title: "Integration Setup",
|
|
634
621
|
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.",
|
|
635
|
-
children: /* @__PURE__ */
|
|
622
|
+
children: /* @__PURE__ */ E("div", {
|
|
636
623
|
className: "space-y-4",
|
|
637
|
-
children: [/* @__PURE__ */
|
|
624
|
+
children: [/* @__PURE__ */ T(s, {
|
|
638
625
|
label: "Post-install Callback URL",
|
|
639
626
|
type: "url",
|
|
640
|
-
value:
|
|
641
|
-
onChange: (e) =>
|
|
627
|
+
value: V.oauthAuthUrl,
|
|
628
|
+
onChange: (e) => X("oauthAuthUrl", e.target.value),
|
|
642
629
|
placeholder: "https://yourapp.com/callback",
|
|
643
630
|
hint: "Users land here after install with ?installation_id=xxx appended"
|
|
644
|
-
}), /* @__PURE__ */
|
|
631
|
+
}), /* @__PURE__ */ T(s, {
|
|
645
632
|
label: "Revoke URL",
|
|
646
633
|
type: "url",
|
|
647
|
-
value:
|
|
648
|
-
onChange: (e) =>
|
|
634
|
+
value: V.oauthRevokeUrl,
|
|
635
|
+
onChange: (e) => X("oauthRevokeUrl", e.target.value),
|
|
649
636
|
placeholder: "https://yourapp.com/oauth/revoke",
|
|
650
637
|
hint: "We POST to this URL when a user uninstalls your integration"
|
|
651
638
|
})]
|
|
652
639
|
})
|
|
653
640
|
}),
|
|
654
|
-
|
|
641
|
+
x !== "app" && /* @__PURE__ */ E("div", {
|
|
655
642
|
className: "rounded-lg border border-border-subtle bg-bg-sunken/30 p-4 flex gap-3 text-sm text-text-secondary",
|
|
656
|
-
children: [/* @__PURE__ */
|
|
643
|
+
children: [/* @__PURE__ */ T(y, {
|
|
657
644
|
size: 16,
|
|
658
645
|
className: "flex-shrink-0 mt-0.5"
|
|
659
|
-
}), /* @__PURE__ */
|
|
646
|
+
}), /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T("p", {
|
|
660
647
|
className: "font-medium text-text-primary",
|
|
661
648
|
children: "File uploads"
|
|
662
|
-
}), /* @__PURE__ */
|
|
649
|
+
}), /* @__PURE__ */ T("p", {
|
|
663
650
|
className: "mt-1",
|
|
664
|
-
children:
|
|
651
|
+
children: x === "node" ? "After creating your Node, go to the Versions tab to upload your ZIP bundle and manifest.json." : `After creating your ${$}, go to the Versions tab to upload its manifest JSON.`
|
|
665
652
|
})] })]
|
|
666
653
|
}),
|
|
667
|
-
|
|
654
|
+
U._submit && /* @__PURE__ */ E("div", {
|
|
668
655
|
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",
|
|
669
|
-
children: [/* @__PURE__ */
|
|
656
|
+
children: [/* @__PURE__ */ T(y, {
|
|
670
657
|
size: 16,
|
|
671
658
|
className: "flex-shrink-0 mt-0.5"
|
|
672
|
-
}), /* @__PURE__ */
|
|
659
|
+
}), /* @__PURE__ */ T("span", { children: U._submit })]
|
|
673
660
|
}),
|
|
674
|
-
/* @__PURE__ */
|
|
661
|
+
/* @__PURE__ */ E("div", {
|
|
675
662
|
className: "flex items-center justify-end gap-3 border-t pt-6",
|
|
676
|
-
children: [/* @__PURE__ */
|
|
663
|
+
children: [/* @__PURE__ */ E("button", {
|
|
677
664
|
type: "button",
|
|
678
|
-
onClick: () =>
|
|
679
|
-
disabled:
|
|
665
|
+
onClick: () => Y("/apps"),
|
|
666
|
+
disabled: K,
|
|
680
667
|
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",
|
|
681
|
-
children: [/* @__PURE__ */
|
|
682
|
-
}), /* @__PURE__ */
|
|
668
|
+
children: [/* @__PURE__ */ T(C, { size: 16 }), _("devportal.cancel", "Cancel")]
|
|
669
|
+
}), /* @__PURE__ */ T("button", {
|
|
683
670
|
type: "submit",
|
|
684
|
-
disabled:
|
|
671
|
+
disabled: K,
|
|
685
672
|
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",
|
|
686
|
-
children:
|
|
673
|
+
children: K ? /* @__PURE__ */ E(w, { children: [/* @__PURE__ */ T(ne, {
|
|
687
674
|
size: 16,
|
|
688
675
|
className: "animate-spin"
|
|
689
|
-
}), "Creating…"] }) : /* @__PURE__ */
|
|
690
|
-
/* @__PURE__ */
|
|
676
|
+
}), "Creating…"] }) : /* @__PURE__ */ E(w, { children: [
|
|
677
|
+
/* @__PURE__ */ T(re, { size: 16 }),
|
|
691
678
|
"Create ",
|
|
692
679
|
$
|
|
693
680
|
] })
|
|
@@ -699,6 +686,6 @@ var N = [
|
|
|
699
686
|
});
|
|
700
687
|
};
|
|
701
688
|
//#endregion
|
|
702
|
-
export {
|
|
689
|
+
export { L as CreateApplicationPage };
|
|
703
690
|
|
|
704
691
|
//# sourceMappingURL=CreateApplicationPage.js.map
|