@burdenoff/microfe-devportal 2026.625.4 → 2026.625.6
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.
|
@@ -18,13 +18,13 @@ import { useDevportalPermission as se } from "../hooks/usePermission.js";
|
|
|
18
18
|
import { usePackageUpload as k } from "../hooks/usePackageUpload.js";
|
|
19
19
|
import { useCallback as A, useEffect as ce, useMemo as j, useRef as M, useState as N } from "react";
|
|
20
20
|
import { useI18n as P } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
21
|
-
import { AlertCircle as le, AppWindow as
|
|
22
|
-
import { useParams as
|
|
23
|
-
import { Fragment as
|
|
24
|
-
import { gql as
|
|
25
|
-
import { useMutation as
|
|
21
|
+
import { AlertCircle as le, AppWindow as ue, BarChart3 as F, CheckCircle as I, CheckCircle2 as de, Clock as fe, Download as pe, Edit as me, ExternalLink as L, FlaskConical as he, Info as ge, Key as _e, Loader2 as R, MoreHorizontal as ve, Plus as z, Power as ye, RefreshCw as be, SendHorizontal as xe, Shield as B, Store as Se, Upload as V, Users as H, Webhook as Ce, X as we, XCircle as Te } from "lucide-react";
|
|
22
|
+
import { useParams as Ee, useSearchParams as De } from "react-router-dom";
|
|
23
|
+
import { Fragment as U, jsx as W, jsxs as G } from "react/jsx-runtime";
|
|
24
|
+
import { gql as K } from "@apollo/client";
|
|
25
|
+
import { useMutation as q, useQuery as J } from "@apollo/client/react";
|
|
26
26
|
//#region src/devportal/pages/ApplicationDetailPage.tsx
|
|
27
|
-
function
|
|
27
|
+
function Oe(e) {
|
|
28
28
|
return e ? {
|
|
29
29
|
id: e.id,
|
|
30
30
|
name: e.name,
|
|
@@ -80,7 +80,7 @@ function De(e) {
|
|
|
80
80
|
updatedAt: e.updatedAt
|
|
81
81
|
} : null;
|
|
82
82
|
}
|
|
83
|
-
function
|
|
83
|
+
function ke(e) {
|
|
84
84
|
return {
|
|
85
85
|
id: e.id,
|
|
86
86
|
applicationId: e.applicationId,
|
|
@@ -104,7 +104,7 @@ function Oe(e) {
|
|
|
104
104
|
updatedAt: e.updatedAt
|
|
105
105
|
};
|
|
106
106
|
}
|
|
107
|
-
function
|
|
107
|
+
function Ae(e) {
|
|
108
108
|
return {
|
|
109
109
|
id: e.id,
|
|
110
110
|
applicationId: e.applicationId,
|
|
@@ -120,7 +120,7 @@ function ke(e) {
|
|
|
120
120
|
createdAt: e.createdAt
|
|
121
121
|
};
|
|
122
122
|
}
|
|
123
|
-
function
|
|
123
|
+
function je(e) {
|
|
124
124
|
return {
|
|
125
125
|
id: e.id,
|
|
126
126
|
appId: e.appId,
|
|
@@ -142,61 +142,61 @@ function Ae(e) {
|
|
|
142
142
|
revokedBy: e.revokedBy || void 0
|
|
143
143
|
};
|
|
144
144
|
}
|
|
145
|
-
var
|
|
145
|
+
var Me = [
|
|
146
146
|
{
|
|
147
147
|
id: "overview",
|
|
148
148
|
label: "Overview",
|
|
149
|
-
icon:
|
|
149
|
+
icon: ue
|
|
150
150
|
},
|
|
151
151
|
{
|
|
152
152
|
id: "permissions",
|
|
153
153
|
label: "Permissions",
|
|
154
|
-
icon:
|
|
154
|
+
icon: B
|
|
155
155
|
},
|
|
156
156
|
{
|
|
157
157
|
id: "webhooks",
|
|
158
158
|
label: "Webhooks",
|
|
159
|
-
icon:
|
|
159
|
+
icon: Ce
|
|
160
160
|
},
|
|
161
161
|
{
|
|
162
162
|
id: "delegations",
|
|
163
163
|
label: "Delegations",
|
|
164
|
-
icon:
|
|
164
|
+
icon: H
|
|
165
165
|
},
|
|
166
166
|
{
|
|
167
167
|
id: "analytics",
|
|
168
168
|
label: "Analytics",
|
|
169
|
-
icon:
|
|
169
|
+
icon: F
|
|
170
170
|
},
|
|
171
171
|
{
|
|
172
172
|
id: "playground",
|
|
173
173
|
label: "API Playground",
|
|
174
|
-
icon:
|
|
174
|
+
icon: L
|
|
175
175
|
},
|
|
176
176
|
{
|
|
177
177
|
id: "store-listing",
|
|
178
178
|
label: "Marketplace Listing",
|
|
179
|
-
icon:
|
|
179
|
+
icon: Se
|
|
180
180
|
}
|
|
181
|
-
],
|
|
181
|
+
], Y = {
|
|
182
182
|
ACTIVE: "bg-status-success-bg-subtle text-status-success-text",
|
|
183
183
|
REVOKED: "bg-status-error-bg-subtle text-status-error-text",
|
|
184
184
|
EXPIRED: "bg-bg-sunken text-text-secondary"
|
|
185
|
-
}, X = ({ message: e = "Loading..." }) => /* @__PURE__ */
|
|
185
|
+
}, X = ({ message: e = "Loading..." }) => /* @__PURE__ */ G("div", {
|
|
186
186
|
className: "flex items-center justify-center gap-3 py-12",
|
|
187
|
-
children: [/* @__PURE__ */
|
|
187
|
+
children: [/* @__PURE__ */ W(R, {
|
|
188
188
|
size: 20,
|
|
189
189
|
className: "animate-spin text-muted-foreground"
|
|
190
|
-
}), /* @__PURE__ */
|
|
190
|
+
}), /* @__PURE__ */ W("p", {
|
|
191
191
|
className: "text-sm text-muted-foreground",
|
|
192
192
|
children: e
|
|
193
193
|
})]
|
|
194
|
-
}), Z = ({ message: e }) => /* @__PURE__ */
|
|
194
|
+
}), Z = ({ message: e }) => /* @__PURE__ */ G("div", {
|
|
195
195
|
className: "flex flex-col items-center justify-center gap-2 py-12 text-center",
|
|
196
|
-
children: [/* @__PURE__ */
|
|
196
|
+
children: [/* @__PURE__ */ W(le, {
|
|
197
197
|
size: 32,
|
|
198
198
|
className: "text-destructive"
|
|
199
|
-
}), /* @__PURE__ */
|
|
199
|
+
}), /* @__PURE__ */ W("p", {
|
|
200
200
|
className: "text-sm text-muted-foreground",
|
|
201
201
|
children: e
|
|
202
202
|
})]
|
|
@@ -204,7 +204,7 @@ var je = [
|
|
|
204
204
|
let { navigate: i, basePath: o, workspaceId: c } = e(), { t: l } = P(), u = (e, t) => {
|
|
205
205
|
let n = l(e);
|
|
206
206
|
return n === e ? t : n;
|
|
207
|
-
}, { allowed: d } = se(oe.APP_UPDATE), { allowed: m } = se(oe.APP_DELETE), { appId: g } =
|
|
207
|
+
}, { allowed: d } = se(oe.APP_UPDATE), { allowed: m } = se(oe.APP_DELETE), { appId: g } = Ee(), [v, b] = De(), C = [
|
|
208
208
|
"overview",
|
|
209
209
|
"permissions",
|
|
210
210
|
"webhooks",
|
|
@@ -218,278 +218,278 @@ var je = [
|
|
|
218
218
|
}, [T]);
|
|
219
219
|
let re = (e) => {
|
|
220
220
|
D(e), b((t) => (t.set("tab", e), t), { replace: !0 });
|
|
221
|
-
}, [ie, k] = N(!1), [j, M] = N(!1), [
|
|
221
|
+
}, [ie, k] = N(!1), [j, M] = N(!1), [F, I] = N(null), [de, pe] = N(!1), { data: L, loading: ge, error: _e } = s({
|
|
222
222
|
variables: { id: g },
|
|
223
223
|
skip: !g
|
|
224
|
-
}), [
|
|
224
|
+
}), [ve, { loading: z }] = h(), [B, { loading: Se }] = a(), [V, { loading: H }] = p(), [Ce, { loading: we }] = _(), { data: U, refetch: K } = f({
|
|
225
225
|
variables: {
|
|
226
226
|
applicationId: g,
|
|
227
227
|
workspaceId: c ?? void 0
|
|
228
228
|
},
|
|
229
229
|
skip: !c || !g,
|
|
230
230
|
fetchPolicy: "cache-and-network"
|
|
231
|
-
}),
|
|
231
|
+
}), q = U?.appInstallations?.edges?.[0]?.node ?? null, J = A((e) => {
|
|
232
232
|
i?.(`${o}${e}`);
|
|
233
|
-
}, [i, o]),
|
|
234
|
-
let e =
|
|
233
|
+
}, [i, o]), ke = A(async () => {
|
|
234
|
+
let e = L?.application?.appId;
|
|
235
235
|
if (e) try {
|
|
236
|
-
let t = (await
|
|
237
|
-
t &&
|
|
236
|
+
let t = (await ve({ variables: { id: e } })).data?.rotateAppSecret.clientSecret;
|
|
237
|
+
t && I(t), k(!1);
|
|
238
238
|
} catch {}
|
|
239
|
-
}, [
|
|
239
|
+
}, [L?.application?.appId, ve]), Ae = A(async () => {
|
|
240
240
|
if (g) try {
|
|
241
|
-
await
|
|
241
|
+
await B({ variables: { id: g } }), M(!1), J("/apps");
|
|
242
242
|
} catch {}
|
|
243
243
|
}, [
|
|
244
244
|
g,
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
]),
|
|
245
|
+
B,
|
|
246
|
+
J
|
|
247
|
+
]), je = A(async () => {
|
|
248
248
|
if (!(!g || !c)) try {
|
|
249
|
-
await
|
|
249
|
+
await V({ variables: { input: {
|
|
250
250
|
applicationId: g,
|
|
251
251
|
scope: "WORKSPACE",
|
|
252
252
|
workspaceId: c,
|
|
253
253
|
autoUpdate: !1
|
|
254
|
-
} } }),
|
|
254
|
+
} } }), K(), w("success");
|
|
255
255
|
} catch (e) {
|
|
256
256
|
console.error("[DevPortal] Test in Workspace failed:", e), w("error");
|
|
257
257
|
}
|
|
258
258
|
}, [
|
|
259
259
|
g,
|
|
260
260
|
c,
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
]),
|
|
261
|
+
V,
|
|
262
|
+
K
|
|
263
|
+
]), Y = A(async () => {
|
|
264
264
|
if (!(!g || !c)) try {
|
|
265
|
-
|
|
265
|
+
q || (await V({ variables: { input: {
|
|
266
266
|
applicationId: g,
|
|
267
267
|
scope: "WORKSPACE",
|
|
268
268
|
workspaceId: c,
|
|
269
269
|
autoUpdate: !1
|
|
270
|
-
} } }), await
|
|
270
|
+
} } }), await K()), i?.("/workflows/new");
|
|
271
271
|
} catch (e) {
|
|
272
272
|
console.error("[DevPortal] Test in Workflow Builder failed:", e), w("error");
|
|
273
273
|
}
|
|
274
274
|
}, [
|
|
275
275
|
g,
|
|
276
276
|
c,
|
|
277
|
-
|
|
278
|
-
J,
|
|
277
|
+
V,
|
|
279
278
|
q,
|
|
279
|
+
K,
|
|
280
280
|
i
|
|
281
281
|
]), X = A(async (e) => {
|
|
282
282
|
try {
|
|
283
|
-
await
|
|
283
|
+
await Ce({ variables: { id: e } }), K(), w("success");
|
|
284
284
|
} catch {
|
|
285
285
|
w("error");
|
|
286
286
|
}
|
|
287
|
-
}, [
|
|
288
|
-
if (
|
|
289
|
-
if (
|
|
287
|
+
}, [Ce, K]);
|
|
288
|
+
if (ge && !L) return /* @__PURE__ */ W(n, { message: u("devportal.loadingApplication", "Loading application...") });
|
|
289
|
+
if (_e) return /* @__PURE__ */ W(y, {
|
|
290
290
|
title: u("devportal.error", "Error"),
|
|
291
291
|
backLink: `${o}/apps`,
|
|
292
292
|
backLabel: u("devportal.backToApplications", "Back to Applications"),
|
|
293
|
-
children: /* @__PURE__ */
|
|
293
|
+
children: /* @__PURE__ */ G("div", {
|
|
294
294
|
className: "flex flex-col items-center justify-center py-12 text-center",
|
|
295
295
|
children: [
|
|
296
|
-
/* @__PURE__ */
|
|
296
|
+
/* @__PURE__ */ W(le, {
|
|
297
297
|
size: 48,
|
|
298
298
|
className: "text-destructive mb-4"
|
|
299
299
|
}),
|
|
300
|
-
/* @__PURE__ */
|
|
300
|
+
/* @__PURE__ */ W("h3", {
|
|
301
301
|
className: "text-lg font-semibold mb-2",
|
|
302
302
|
children: u("devportal.failedToLoadApplication", "Failed to load application")
|
|
303
303
|
}),
|
|
304
|
-
/* @__PURE__ */
|
|
304
|
+
/* @__PURE__ */ W("p", {
|
|
305
305
|
className: "text-sm text-muted-foreground",
|
|
306
|
-
children:
|
|
306
|
+
children: _e.message
|
|
307
307
|
})
|
|
308
308
|
]
|
|
309
309
|
})
|
|
310
310
|
});
|
|
311
|
-
let Z =
|
|
312
|
-
return Z ? /* @__PURE__ */
|
|
311
|
+
let Z = Oe(L?.application);
|
|
312
|
+
return Z ? /* @__PURE__ */ G(y, {
|
|
313
313
|
title: Z.name,
|
|
314
314
|
description: Z.shortDescription,
|
|
315
315
|
backLink: `${o}/apps`,
|
|
316
316
|
backLabel: u("devportal.backToApplications", "Back to Applications"),
|
|
317
|
-
actions: /* @__PURE__ */
|
|
317
|
+
actions: /* @__PURE__ */ G("div", {
|
|
318
318
|
className: "flex items-center gap-2",
|
|
319
319
|
children: [
|
|
320
|
-
Z.appType !== "NODE" && Z.appType !== "WORKFLOW" && /* @__PURE__ */
|
|
320
|
+
Z.appType !== "NODE" && Z.appType !== "WORKFLOW" && /* @__PURE__ */ G("button", {
|
|
321
321
|
onClick: () => k(!0),
|
|
322
322
|
disabled: !Z.appId,
|
|
323
323
|
title: Z.appId ? u("devportal.rotateSecretHint", "Generate a new client secret") : u("devportal.rotateSecretNoClient", "Create an OAuth client first to enable secret rotation"),
|
|
324
324
|
className: "inline-flex items-center gap-2 rounded-md border px-4 py-2 text-sm font-medium hover:bg-muted transition-colors disabled:opacity-50 disabled:cursor-not-allowed",
|
|
325
|
-
children: [/* @__PURE__ */
|
|
325
|
+
children: [/* @__PURE__ */ W(be, { size: 16 }), u("devportal.rotateSecret", "Rotate Secret")]
|
|
326
326
|
}),
|
|
327
|
-
/* @__PURE__ */
|
|
328
|
-
onClick: () =>
|
|
327
|
+
/* @__PURE__ */ G("button", {
|
|
328
|
+
onClick: () => J(`/apps/${Z.id}/versions`),
|
|
329
329
|
className: "inline-flex items-center gap-2 rounded-md border px-4 py-2 text-sm font-medium hover:bg-muted transition-colors",
|
|
330
|
-
children: [/* @__PURE__ */
|
|
330
|
+
children: [/* @__PURE__ */ W(fe, { size: 16 }), u("devportal.versions", "Versions")]
|
|
331
331
|
}),
|
|
332
|
-
Z.status !== "PUBLISHED" && /* @__PURE__ */
|
|
333
|
-
onClick: () =>
|
|
332
|
+
Z.status !== "PUBLISHED" && /* @__PURE__ */ G("button", {
|
|
333
|
+
onClick: () => J(`/apps/${Z.id}/publish`),
|
|
334
334
|
className: "inline-flex items-center gap-2 rounded-md border border-primary/40 px-4 py-2 text-sm font-medium text-primary hover:bg-primary/10 transition-colors",
|
|
335
|
-
children: [/* @__PURE__ */
|
|
335
|
+
children: [/* @__PURE__ */ W(xe, { size: 16 }), u("devportal.submitForReview", "Submit for Review")]
|
|
336
336
|
}),
|
|
337
|
-
Z.appType !== "NODE" && Z.appType !== "WORKFLOW" && (
|
|
338
|
-
onClick: () => void X(
|
|
339
|
-
disabled:
|
|
337
|
+
Z.appType !== "NODE" && Z.appType !== "WORKFLOW" && (q ? /* @__PURE__ */ G("button", {
|
|
338
|
+
onClick: () => void X(q.id),
|
|
339
|
+
disabled: we || !c,
|
|
340
340
|
title: u("devportal.uninstallFromWorkspace", "Uninstall this app from your current workspace"),
|
|
341
341
|
className: "inline-flex items-center gap-2 rounded-md border border-destructive/50 px-4 py-2 text-sm font-medium text-destructive hover:bg-destructive/10 transition-colors disabled:opacity-50",
|
|
342
|
-
children: [
|
|
342
|
+
children: [we ? /* @__PURE__ */ W(R, {
|
|
343
343
|
size: 16,
|
|
344
344
|
className: "animate-spin"
|
|
345
|
-
}) : /* @__PURE__ */
|
|
346
|
-
}) : /* @__PURE__ */
|
|
347
|
-
onClick: () => void
|
|
348
|
-
disabled:
|
|
345
|
+
}) : /* @__PURE__ */ W(Te, { size: 16 }), u("devportal.uninstallFromWorkspace", "Uninstall from Workspace")]
|
|
346
|
+
}) : /* @__PURE__ */ G("button", {
|
|
347
|
+
onClick: () => void je(),
|
|
348
|
+
disabled: H || !c,
|
|
349
349
|
"aria-disabled": !c,
|
|
350
350
|
title: c ? u("devportal.testInWorkspaceHint", "Install this app into your current workspace to test it") : u("devportal.noWorkspaceContext", "No workspace context available"),
|
|
351
351
|
className: "inline-flex items-center gap-2 rounded-md border px-4 py-2 text-sm font-medium hover:bg-muted transition-colors disabled:opacity-50",
|
|
352
|
-
children: [
|
|
352
|
+
children: [H ? /* @__PURE__ */ W(R, {
|
|
353
353
|
size: 16,
|
|
354
354
|
className: "animate-spin"
|
|
355
|
-
}) : /* @__PURE__ */
|
|
355
|
+
}) : /* @__PURE__ */ W(he, { size: 16 }), u("devportal.testInWorkspace", "Test in Workspace")]
|
|
356
356
|
})),
|
|
357
|
-
Z.appType === "NODE" && /* @__PURE__ */
|
|
358
|
-
onClick: () => void
|
|
359
|
-
disabled:
|
|
357
|
+
Z.appType === "NODE" && /* @__PURE__ */ G("button", {
|
|
358
|
+
onClick: () => void Y(),
|
|
359
|
+
disabled: H || !c,
|
|
360
360
|
"aria-disabled": !c,
|
|
361
|
-
title: c ?
|
|
361
|
+
title: c ? q ? u("devportal.testInWorkflowBuilderHint", "Open the workflow builder (already installed in workspace)") : u("devportal.testInWorkflowBuilderInstallHint", "Install this node in your workspace and open the workflow builder") : u("devportal.noWorkspaceContext", "No workspace context available"),
|
|
362
362
|
className: "inline-flex items-center gap-2 rounded-md border px-4 py-2 text-sm font-medium hover:bg-muted transition-colors disabled:opacity-50",
|
|
363
|
-
children: [
|
|
363
|
+
children: [H ? /* @__PURE__ */ W(R, {
|
|
364
364
|
size: 16,
|
|
365
365
|
className: "animate-spin"
|
|
366
|
-
}) : /* @__PURE__ */
|
|
366
|
+
}) : /* @__PURE__ */ W(he, { size: 16 }), u("devportal.testInWorkflowBuilder", "Test in Workflow Builder")]
|
|
367
367
|
}),
|
|
368
|
-
/* @__PURE__ */
|
|
369
|
-
onClick: () =>
|
|
368
|
+
/* @__PURE__ */ G("button", {
|
|
369
|
+
onClick: () => J(`/apps/${Z.id}/edit`),
|
|
370
370
|
disabled: !d,
|
|
371
371
|
"aria-disabled": !d,
|
|
372
372
|
className: "inline-flex items-center gap-2 rounded-md bg-primary px-4 py-2 text-sm font-medium text-primary-foreground hover:bg-primary/90 transition-colors disabled:opacity-50",
|
|
373
|
-
children: [/* @__PURE__ */
|
|
373
|
+
children: [/* @__PURE__ */ W(me, { size: 16 }), u("devportal.editApp", "Edit App")]
|
|
374
374
|
}),
|
|
375
|
-
/* @__PURE__ */
|
|
375
|
+
/* @__PURE__ */ G("button", {
|
|
376
376
|
onClick: () => M(!0),
|
|
377
377
|
disabled: !m,
|
|
378
378
|
"aria-disabled": !m,
|
|
379
379
|
className: "inline-flex items-center gap-2 rounded-md border border-border-subtle px-4 py-2 text-sm font-medium text-status-error-text hover:bg-status-error-bg-subtle transition-colors disabled:opacity-50",
|
|
380
|
-
children: [/* @__PURE__ */
|
|
380
|
+
children: [/* @__PURE__ */ W(ye, { size: 16 }), u("devportal.deactivate", "Deactivate")]
|
|
381
381
|
})
|
|
382
382
|
]
|
|
383
383
|
}),
|
|
384
384
|
children: [
|
|
385
|
-
|
|
385
|
+
F && /* @__PURE__ */ W(ne, {
|
|
386
386
|
title: u("devportal.newAppSecretGenerated", "New App Secret Generated"),
|
|
387
|
-
secret:
|
|
387
|
+
secret: F,
|
|
388
388
|
description: u("devportal.appSecretRotatedDescription", "Your app secret has been rotated. The old secret is no longer valid."),
|
|
389
|
-
onDismiss: () =>
|
|
389
|
+
onDismiss: () => I(null)
|
|
390
390
|
}),
|
|
391
|
-
/* @__PURE__ */
|
|
391
|
+
/* @__PURE__ */ G("div", {
|
|
392
392
|
className: "flex flex-wrap items-center gap-2",
|
|
393
393
|
children: [
|
|
394
|
-
/* @__PURE__ */
|
|
394
|
+
/* @__PURE__ */ W(S, {
|
|
395
395
|
status: Z.status,
|
|
396
396
|
type: "app"
|
|
397
397
|
}),
|
|
398
|
-
/* @__PURE__ */
|
|
398
|
+
/* @__PURE__ */ W(S, {
|
|
399
399
|
status: Z.visibility,
|
|
400
400
|
type: "app"
|
|
401
401
|
}),
|
|
402
|
-
Z.isVerified && /* @__PURE__ */
|
|
403
|
-
Z.isFeatured && /* @__PURE__ */
|
|
404
|
-
/* @__PURE__ */
|
|
402
|
+
Z.isVerified && /* @__PURE__ */ W(te, { verified: !0 }),
|
|
403
|
+
Z.isFeatured && /* @__PURE__ */ W(x, {}),
|
|
404
|
+
/* @__PURE__ */ W("span", {
|
|
405
405
|
className: "text-sm text-muted-foreground",
|
|
406
406
|
children: ee[Z.appType] || Z.appType
|
|
407
407
|
})
|
|
408
408
|
]
|
|
409
409
|
}),
|
|
410
|
-
/* @__PURE__ */
|
|
410
|
+
/* @__PURE__ */ W("div", {
|
|
411
411
|
className: "border-b",
|
|
412
|
-
children: /* @__PURE__ */
|
|
412
|
+
children: /* @__PURE__ */ W("nav", {
|
|
413
413
|
className: "-mb-px flex gap-4 overflow-x-auto",
|
|
414
414
|
role: "tablist",
|
|
415
415
|
"aria-label": u("devportal.applicationSections", "Application sections"),
|
|
416
|
-
children:
|
|
416
|
+
children: Me.filter((e) => !((Z.appType === "NODE" || Z.appType === "WORKFLOW") && (e.id === "permissions" || e.id === "webhooks" || e.id === "delegations" || e.id === "playground"))).map((e) => {
|
|
417
417
|
let n = e.icon;
|
|
418
|
-
return /* @__PURE__ */
|
|
418
|
+
return /* @__PURE__ */ G("button", {
|
|
419
419
|
id: `application-tab-${e.id}`,
|
|
420
420
|
role: "tab",
|
|
421
421
|
"aria-selected": E === e.id,
|
|
422
422
|
"aria-controls": `application-panel-${e.id}`,
|
|
423
423
|
onClick: () => re(e.id),
|
|
424
424
|
className: t("flex items-center gap-2 border-b-2 px-1 py-3 text-sm font-medium transition-colors", E === e.id ? "border-primary text-primary" : "border-transparent text-muted-foreground hover:text-foreground hover:border-muted-foreground"),
|
|
425
|
-
children: [/* @__PURE__ */
|
|
425
|
+
children: [/* @__PURE__ */ W(n, { size: 16 }), e.label]
|
|
426
426
|
}, e.id);
|
|
427
427
|
})
|
|
428
428
|
})
|
|
429
429
|
}),
|
|
430
|
-
/* @__PURE__ */
|
|
430
|
+
/* @__PURE__ */ G("div", {
|
|
431
431
|
className: "mt-6",
|
|
432
432
|
id: `application-panel-${E}`,
|
|
433
433
|
role: "tabpanel",
|
|
434
434
|
"aria-labelledby": `application-tab-${E}`,
|
|
435
435
|
tabIndex: 0,
|
|
436
436
|
children: [
|
|
437
|
-
E === "overview" && /* @__PURE__ */
|
|
438
|
-
E === "permissions" && /* @__PURE__ */
|
|
439
|
-
E === "webhooks" && /* @__PURE__ */
|
|
437
|
+
E === "overview" && /* @__PURE__ */ W(Le, { app: Z }),
|
|
438
|
+
E === "permissions" && /* @__PURE__ */ W(tt, { app: Z }),
|
|
439
|
+
E === "webhooks" && /* @__PURE__ */ W(Pe, {
|
|
440
440
|
appId: Z.id,
|
|
441
|
-
onNavigate:
|
|
441
|
+
onNavigate: J
|
|
442
442
|
}),
|
|
443
|
-
E === "delegations" && /* @__PURE__ */
|
|
443
|
+
E === "delegations" && /* @__PURE__ */ W(Fe, {
|
|
444
444
|
authAppId: Z.appId || void 0,
|
|
445
445
|
appName: Z.name,
|
|
446
|
-
onGrantDelegation: () =>
|
|
447
|
-
onNavigate:
|
|
446
|
+
onGrantDelegation: () => pe(!0),
|
|
447
|
+
onNavigate: J
|
|
448
448
|
}),
|
|
449
|
-
E === "analytics" && /* @__PURE__ */
|
|
450
|
-
E === "playground" && /* @__PURE__ */
|
|
451
|
-
E === "store-listing" && /* @__PURE__ */
|
|
449
|
+
E === "analytics" && /* @__PURE__ */ W(Ie, { app: Z }),
|
|
450
|
+
E === "playground" && /* @__PURE__ */ W(He, { app: Z }),
|
|
451
|
+
E === "store-listing" && /* @__PURE__ */ W(Qe, { app: Z })
|
|
452
452
|
]
|
|
453
453
|
}),
|
|
454
|
-
/* @__PURE__ */
|
|
454
|
+
/* @__PURE__ */ W(O, {
|
|
455
455
|
open: ie,
|
|
456
456
|
onOpenChange: k,
|
|
457
|
-
onConfirm:
|
|
457
|
+
onConfirm: ke,
|
|
458
458
|
title: u("devportal.rotateAppSecret", "Rotate App Secret"),
|
|
459
459
|
description: u("devportal.rotateAppSecretDescription", "This will generate a new client secret and invalidate the current one. All existing integrations using the old secret will stop working immediately."),
|
|
460
460
|
confirmLabel: u("devportal.rotateSecret", "Rotate Secret"),
|
|
461
461
|
cancelLabel: u("devportal.cancel", "Cancel"),
|
|
462
462
|
variant: "warning",
|
|
463
|
-
loading:
|
|
463
|
+
loading: z
|
|
464
464
|
}),
|
|
465
|
-
/* @__PURE__ */
|
|
465
|
+
/* @__PURE__ */ W(O, {
|
|
466
466
|
open: j,
|
|
467
467
|
onOpenChange: M,
|
|
468
|
-
onConfirm:
|
|
468
|
+
onConfirm: Ae,
|
|
469
469
|
title: u("devportal.deactivateApplication", "Deactivate Application"),
|
|
470
470
|
description: u("devportal.deactivateApplicationDescription", "This will deactivate the application. All OAuth clients, API keys, and webhooks associated with this app will stop functioning. This action can be reversed by reactivating the app."),
|
|
471
471
|
confirmLabel: u("devportal.deactivate", "Deactivate"),
|
|
472
472
|
cancelLabel: u("devportal.cancel", "Cancel"),
|
|
473
473
|
variant: "destructive",
|
|
474
|
-
loading:
|
|
474
|
+
loading: Se
|
|
475
475
|
}),
|
|
476
|
-
/* @__PURE__ */
|
|
477
|
-
open:
|
|
478
|
-
onOpenChange:
|
|
476
|
+
/* @__PURE__ */ W(ae, {
|
|
477
|
+
open: de,
|
|
478
|
+
onOpenChange: pe,
|
|
479
479
|
appId: Z.appId || "",
|
|
480
480
|
appName: Z.name,
|
|
481
481
|
appScopes: Z.scopes?.map((e) => e.scope) ?? [],
|
|
482
482
|
onSuccess: () => {
|
|
483
|
-
|
|
483
|
+
pe(!1);
|
|
484
484
|
}
|
|
485
485
|
})
|
|
486
486
|
]
|
|
487
|
-
}) : /* @__PURE__ */
|
|
487
|
+
}) : /* @__PURE__ */ W(y, {
|
|
488
488
|
title: u("devportal.notFound", "Not Found"),
|
|
489
489
|
backLink: `${o}/apps`,
|
|
490
490
|
backLabel: u("devportal.backToApplications", "Back to Applications"),
|
|
491
|
-
children: /* @__PURE__ */
|
|
492
|
-
icon: /* @__PURE__ */
|
|
491
|
+
children: /* @__PURE__ */ W(r, {
|
|
492
|
+
icon: /* @__PURE__ */ W(ue, { size: 48 }),
|
|
493
493
|
title: u("devportal.applicationNotFound", "Application not found"),
|
|
494
494
|
description: u("devportal.applicationNotFoundDescription", "The application you're looking for doesn't exist or you don't have access to it.")
|
|
495
495
|
})
|
|
@@ -499,16 +499,16 @@ var je = [
|
|
|
499
499
|
let r = n(e);
|
|
500
500
|
return r === e ? t : r;
|
|
501
501
|
}, { data: i, loading: a, error: o } = d({ variables: { applicationId: e } });
|
|
502
|
-
return a ? /* @__PURE__ */
|
|
502
|
+
return a ? /* @__PURE__ */ W(X, { message: r("devportal.loadingWebhooks", "Loading webhooks...") }) : o ? /* @__PURE__ */ W(Z, { message: o.message }) : /* @__PURE__ */ W(Re, {
|
|
503
503
|
appId: e,
|
|
504
|
-
webhooks: (i?.webhooks ?? []).map(
|
|
504
|
+
webhooks: (i?.webhooks ?? []).map(ke),
|
|
505
505
|
onNavigate: t
|
|
506
506
|
});
|
|
507
507
|
}, Fe = ({ authAppId: e, appName: t, onGrantDelegation: n, onNavigate: a }) => {
|
|
508
508
|
let { t: o } = P(), s = (e, t) => {
|
|
509
509
|
let n = o(e);
|
|
510
510
|
return n === e ? t : n;
|
|
511
|
-
}, { data: c, loading: l, error: u, refetch: d } = i(), [f] = m(), [p, h] = N([]), [g, _] = N(!1), [v, y] = N(/* @__PURE__ */ new Set()), [b, ee] = N(null), x = j(() => c?.currentUserDelegations?.delegations ? c.currentUserDelegations.delegations.filter((t) => t.appId === e).map(
|
|
511
|
+
}, { data: c, loading: l, error: u, refetch: d } = i(), [f] = m(), [p, h] = N([]), [g, _] = N(!1), [v, y] = N(/* @__PURE__ */ new Set()), [b, ee] = N(null), x = j(() => c?.currentUserDelegations?.delegations ? c.currentUserDelegations.delegations.filter((t) => t.appId === e).map(je) : [], [e, c]), S = j(() => x.filter((e) => e.status === "ACTIVE"), [x]), te = j(() => S.filter((e) => v.has(e.id)), [S, v]), C = S.length > 0 && S.every((e) => v.has(e.id)), w = S.some((e) => v.has(e.id)) && !C, ne = A((e, t) => {
|
|
512
512
|
y((n) => {
|
|
513
513
|
let r = new Set(n);
|
|
514
514
|
return t ? r.add(e) : r.delete(e), r;
|
|
@@ -534,19 +534,19 @@ var je = [
|
|
|
534
534
|
_(!1);
|
|
535
535
|
}
|
|
536
536
|
}, [f, d]);
|
|
537
|
-
return e ? l ? /* @__PURE__ */
|
|
538
|
-
b && /* @__PURE__ */
|
|
537
|
+
return e ? l ? /* @__PURE__ */ W(X, { message: s("devportal.loadingDelegations", "Loading delegations...") }) : u ? /* @__PURE__ */ W(Z, { message: u.message }) : /* @__PURE__ */ G(U, { children: [
|
|
538
|
+
b && /* @__PURE__ */ W("div", {
|
|
539
539
|
className: "rounded-lg border border-border-subtle bg-status-success-bg-subtle p-3 text-sm text-status-success-text",
|
|
540
|
-
children: /* @__PURE__ */
|
|
540
|
+
children: /* @__PURE__ */ G("div", {
|
|
541
541
|
className: "flex items-center justify-between gap-3",
|
|
542
|
-
children: [/* @__PURE__ */
|
|
542
|
+
children: [/* @__PURE__ */ W("span", { children: b }), /* @__PURE__ */ W("button", {
|
|
543
543
|
onClick: () => ee(null),
|
|
544
544
|
className: "text-status-success-text hover:text-status-success-text",
|
|
545
545
|
children: s("devportal.dismiss", "Dismiss")
|
|
546
546
|
})]
|
|
547
547
|
})
|
|
548
548
|
}),
|
|
549
|
-
/* @__PURE__ */
|
|
549
|
+
/* @__PURE__ */ W(ze, {
|
|
550
550
|
appName: t,
|
|
551
551
|
delegations: x,
|
|
552
552
|
onGrantDelegation: n,
|
|
@@ -559,7 +559,7 @@ var je = [
|
|
|
559
559
|
allVisibleSelected: C,
|
|
560
560
|
partiallySelected: w
|
|
561
561
|
}),
|
|
562
|
-
/* @__PURE__ */
|
|
562
|
+
/* @__PURE__ */ W(O, {
|
|
563
563
|
open: p.length > 0,
|
|
564
564
|
onOpenChange: (e) => {
|
|
565
565
|
e || h([]);
|
|
@@ -574,14 +574,14 @@ var je = [
|
|
|
574
574
|
variant: "destructive",
|
|
575
575
|
loading: g
|
|
576
576
|
})
|
|
577
|
-
] }) : /* @__PURE__ */
|
|
578
|
-
icon: /* @__PURE__ */
|
|
577
|
+
] }) : /* @__PURE__ */ W(r, {
|
|
578
|
+
icon: /* @__PURE__ */ W(B, { size: 32 }),
|
|
579
579
|
title: s("devportal.linkAuthAppFirst", "Link an auth app first"),
|
|
580
580
|
description: s("devportal.linkAuthAppFirstDescription", "Delegations are managed through auth apps. Create or link an auth app before granting app-as-user access."),
|
|
581
|
-
action: /* @__PURE__ */
|
|
581
|
+
action: /* @__PURE__ */ G("button", {
|
|
582
582
|
onClick: () => a("/oauth"),
|
|
583
583
|
className: "inline-flex items-center gap-2 rounded-md bg-primary px-4 py-2 text-sm font-medium text-primary-foreground hover:bg-primary/90",
|
|
584
|
-
children: [/* @__PURE__ */
|
|
584
|
+
children: [/* @__PURE__ */ W(L, { size: 16 }), s("devportal.manageOAuthApps", "Manage OAuth Apps")]
|
|
585
585
|
})
|
|
586
586
|
});
|
|
587
587
|
}, Ie = ({ app: e }) => {
|
|
@@ -613,31 +613,31 @@ var je = [
|
|
|
613
613
|
});
|
|
614
614
|
if (r) {
|
|
615
615
|
let t = m?.productInstallations?.items ?? [], r = m?.productInstallations?.total ?? 0, i = t.filter((e) => e.status === "ACTIVE").length;
|
|
616
|
-
return h && !m ? /* @__PURE__ */
|
|
616
|
+
return h && !m ? /* @__PURE__ */ W(X, { message: n("devportal.loadingAnalytics", "Loading analytics...") }) : /* @__PURE__ */ G("div", {
|
|
617
617
|
className: "space-y-6",
|
|
618
|
-
children: [/* @__PURE__ */
|
|
618
|
+
children: [/* @__PURE__ */ G("div", {
|
|
619
619
|
className: "grid gap-4 sm:grid-cols-4",
|
|
620
620
|
children: [
|
|
621
|
-
/* @__PURE__ */
|
|
621
|
+
/* @__PURE__ */ W(Q, {
|
|
622
622
|
label: n("devportal.totalInstalls", "Total Installs"),
|
|
623
623
|
value: r.toLocaleString()
|
|
624
624
|
}),
|
|
625
|
-
/* @__PURE__ */
|
|
625
|
+
/* @__PURE__ */ W(Q, {
|
|
626
626
|
label: n("devportal.activeInstalls", "Active Installs"),
|
|
627
627
|
value: i.toLocaleString()
|
|
628
628
|
}),
|
|
629
|
-
/* @__PURE__ */
|
|
629
|
+
/* @__PURE__ */ W(Q, {
|
|
630
630
|
label: n("devportal.averageRating", "Average Rating"),
|
|
631
631
|
value: e.averageRating ? `${e.averageRating.toFixed(1)} ★` : n("devportal.notAvailable", "N/A")
|
|
632
632
|
}),
|
|
633
|
-
/* @__PURE__ */
|
|
633
|
+
/* @__PURE__ */ W(Q, {
|
|
634
634
|
label: n("devportal.reviews", "Reviews"),
|
|
635
635
|
value: e.reviewCount.toString()
|
|
636
636
|
})
|
|
637
637
|
]
|
|
638
|
-
}), t.length > 0 && /* @__PURE__ */
|
|
638
|
+
}), t.length > 0 && /* @__PURE__ */ W(b, {
|
|
639
639
|
title: n("devportal.installBreakdown", "Install Breakdown"),
|
|
640
|
-
children: /* @__PURE__ */
|
|
640
|
+
children: /* @__PURE__ */ W(T, {
|
|
641
641
|
data: t,
|
|
642
642
|
keyField: "id",
|
|
643
643
|
columns: [
|
|
@@ -670,7 +670,7 @@ var je = [
|
|
|
670
670
|
})]
|
|
671
671
|
});
|
|
672
672
|
}
|
|
673
|
-
return _ ? /* @__PURE__ */
|
|
673
|
+
return _ ? /* @__PURE__ */ W(X, { message: n("devportal.loadingAnalytics", "Loading analytics...") }) : v ? /* @__PURE__ */ W(Z, { message: v.message }) : /* @__PURE__ */ W(Be, { analytics: (g?.applicationAnalytics ?? []).map(Ae) });
|
|
674
674
|
}, Le = ({ app: t }) => {
|
|
675
675
|
let { t: n } = P(), r = (e, t) => {
|
|
676
676
|
let r = n(e);
|
|
@@ -701,16 +701,16 @@ var je = [
|
|
|
701
701
|
cta: "Submit for review →"
|
|
702
702
|
}
|
|
703
703
|
] : [], l = c.filter((e) => !e.done)[0];
|
|
704
|
-
return /* @__PURE__ */
|
|
704
|
+
return /* @__PURE__ */ G("div", {
|
|
705
705
|
className: "grid gap-6 lg:grid-cols-3",
|
|
706
|
-
children: [/* @__PURE__ */
|
|
706
|
+
children: [/* @__PURE__ */ G("div", {
|
|
707
707
|
className: "lg:col-span-2 space-y-6",
|
|
708
708
|
children: [
|
|
709
|
-
s && l && /* @__PURE__ */
|
|
709
|
+
s && l && /* @__PURE__ */ G("div", {
|
|
710
710
|
className: "rounded-lg border border-primary/30 bg-primary/5 p-4 space-y-3",
|
|
711
|
-
children: [/* @__PURE__ */
|
|
711
|
+
children: [/* @__PURE__ */ G("div", {
|
|
712
712
|
className: "flex items-center justify-between",
|
|
713
|
-
children: [/* @__PURE__ */
|
|
713
|
+
children: [/* @__PURE__ */ G("p", {
|
|
714
714
|
className: "font-semibold text-sm text-primary",
|
|
715
715
|
children: [
|
|
716
716
|
r("devportal.setupProgress", "Setup Progress"),
|
|
@@ -720,25 +720,25 @@ var je = [
|
|
|
720
720
|
c.length,
|
|
721
721
|
" complete"
|
|
722
722
|
]
|
|
723
|
-
}), /* @__PURE__ */
|
|
723
|
+
}), /* @__PURE__ */ W("button", {
|
|
724
724
|
onClick: () => i?.(`${a}/apps/${t.id}/publish`),
|
|
725
725
|
className: "text-xs text-primary hover:underline font-medium",
|
|
726
726
|
children: r("devportal.viewChecklist", "View full checklist →")
|
|
727
727
|
})]
|
|
728
|
-
}), /* @__PURE__ */
|
|
728
|
+
}), /* @__PURE__ */ W("div", {
|
|
729
729
|
className: "space-y-1.5",
|
|
730
|
-
children: c.map((e, t) => /* @__PURE__ */
|
|
730
|
+
children: c.map((e, t) => /* @__PURE__ */ G("div", {
|
|
731
731
|
className: "flex items-center gap-2 text-sm",
|
|
732
732
|
children: [
|
|
733
|
-
e.done ? /* @__PURE__ */
|
|
733
|
+
e.done ? /* @__PURE__ */ W(de, {
|
|
734
734
|
size: 14,
|
|
735
735
|
className: "text-status-success-text shrink-0"
|
|
736
|
-
}) : /* @__PURE__ */
|
|
737
|
-
/* @__PURE__ */
|
|
736
|
+
}) : /* @__PURE__ */ W("div", { className: "h-3.5 w-3.5 rounded-full border-2 border-muted-foreground/40 shrink-0" }),
|
|
737
|
+
/* @__PURE__ */ W("span", {
|
|
738
738
|
className: e.done ? "line-through text-muted-foreground" : "text-foreground",
|
|
739
739
|
children: e.label
|
|
740
740
|
}),
|
|
741
|
-
!e.done && t === c.indexOf(l) && /* @__PURE__ */
|
|
741
|
+
!e.done && t === c.indexOf(l) && /* @__PURE__ */ W("button", {
|
|
742
742
|
onClick: () => i?.(e.path),
|
|
743
743
|
className: "ml-auto text-xs text-primary hover:underline font-medium shrink-0",
|
|
744
744
|
children: e.cta
|
|
@@ -747,56 +747,56 @@ var je = [
|
|
|
747
747
|
}, t))
|
|
748
748
|
})]
|
|
749
749
|
}),
|
|
750
|
-
/* @__PURE__ */
|
|
750
|
+
/* @__PURE__ */ G("div", {
|
|
751
751
|
className: "grid gap-4 sm:grid-cols-4",
|
|
752
752
|
children: [
|
|
753
|
-
/* @__PURE__ */
|
|
753
|
+
/* @__PURE__ */ W(Q, {
|
|
754
754
|
label: r("devportal.totalInstalls", "Total Installs"),
|
|
755
755
|
value: t.installCount.toLocaleString()
|
|
756
756
|
}),
|
|
757
|
-
/* @__PURE__ */
|
|
757
|
+
/* @__PURE__ */ W(Q, {
|
|
758
758
|
label: r("devportal.activeInstalls", "Active Installs"),
|
|
759
759
|
value: t.activeInstallCount.toLocaleString()
|
|
760
760
|
}),
|
|
761
|
-
/* @__PURE__ */
|
|
761
|
+
/* @__PURE__ */ W(Q, {
|
|
762
762
|
label: r("devportal.averageRating", "Average Rating"),
|
|
763
763
|
value: t.averageRating ? `${t.averageRating.toFixed(1)} ★` : r("devportal.notAvailable", "N/A")
|
|
764
764
|
}),
|
|
765
|
-
/* @__PURE__ */
|
|
765
|
+
/* @__PURE__ */ W(Q, {
|
|
766
766
|
label: r("devportal.reviews", "Reviews"),
|
|
767
767
|
value: t.reviewCount.toString()
|
|
768
768
|
})
|
|
769
769
|
]
|
|
770
770
|
}),
|
|
771
|
-
/* @__PURE__ */
|
|
771
|
+
/* @__PURE__ */ W(b, {
|
|
772
772
|
title: r("devportal.description", "Description"),
|
|
773
|
-
children: /* @__PURE__ */
|
|
773
|
+
children: /* @__PURE__ */ W("div", {
|
|
774
774
|
className: "prose prose-sm max-w-none",
|
|
775
|
-
children: /* @__PURE__ */
|
|
775
|
+
children: /* @__PURE__ */ W("pre", {
|
|
776
776
|
className: "whitespace-pre-wrap font-sans text-sm text-foreground bg-transparent p-0 m-0",
|
|
777
777
|
children: t.description || r("devportal.noDescriptionProvided", "No description provided.")
|
|
778
778
|
})
|
|
779
779
|
})
|
|
780
780
|
}),
|
|
781
|
-
/* @__PURE__ */
|
|
781
|
+
/* @__PURE__ */ W(b, {
|
|
782
782
|
title: r("devportal.tagsAndKeywords", "Tags & Keywords"),
|
|
783
|
-
children: /* @__PURE__ */
|
|
783
|
+
children: /* @__PURE__ */ G("div", {
|
|
784
784
|
className: "space-y-3",
|
|
785
|
-
children: [t.tags.length > 0 && /* @__PURE__ */
|
|
785
|
+
children: [t.tags.length > 0 && /* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("p", {
|
|
786
786
|
className: "text-xs text-muted-foreground mb-2",
|
|
787
787
|
children: r("devportal.tags", "Tags")
|
|
788
|
-
}), /* @__PURE__ */
|
|
788
|
+
}), /* @__PURE__ */ W("div", {
|
|
789
789
|
className: "flex flex-wrap gap-2",
|
|
790
|
-
children: t.tags.map((e) => /* @__PURE__ */
|
|
790
|
+
children: t.tags.map((e) => /* @__PURE__ */ W("span", {
|
|
791
791
|
className: "rounded-full bg-primary/10 px-3 py-1 text-xs font-medium text-primary",
|
|
792
792
|
children: e
|
|
793
793
|
}, e))
|
|
794
|
-
})] }), t.keywords.length > 0 && /* @__PURE__ */
|
|
794
|
+
})] }), t.keywords.length > 0 && /* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("p", {
|
|
795
795
|
className: "text-xs text-muted-foreground mb-2",
|
|
796
796
|
children: r("devportal.keywords", "Keywords")
|
|
797
|
-
}), /* @__PURE__ */
|
|
797
|
+
}), /* @__PURE__ */ W("div", {
|
|
798
798
|
className: "flex flex-wrap gap-2",
|
|
799
|
-
children: t.keywords.map((e) => /* @__PURE__ */
|
|
799
|
+
children: t.keywords.map((e) => /* @__PURE__ */ W("span", {
|
|
800
800
|
className: "rounded-full bg-muted px-3 py-1 text-xs",
|
|
801
801
|
children: e
|
|
802
802
|
}, e))
|
|
@@ -804,14 +804,14 @@ var je = [
|
|
|
804
804
|
})
|
|
805
805
|
})
|
|
806
806
|
]
|
|
807
|
-
}), /* @__PURE__ */
|
|
807
|
+
}), /* @__PURE__ */ G("div", {
|
|
808
808
|
className: "space-y-6",
|
|
809
|
-
children: [/* @__PURE__ */
|
|
809
|
+
children: [/* @__PURE__ */ W(b, {
|
|
810
810
|
title: r("devportal.details", "Details"),
|
|
811
|
-
children: /* @__PURE__ */
|
|
811
|
+
children: /* @__PURE__ */ W(E, { items: [
|
|
812
812
|
{
|
|
813
813
|
label: r("devportal.appId", "App ID"),
|
|
814
|
-
value: /* @__PURE__ */
|
|
814
|
+
value: /* @__PURE__ */ W("code", {
|
|
815
815
|
className: "text-xs",
|
|
816
816
|
children: t.id
|
|
817
817
|
})
|
|
@@ -841,32 +841,32 @@ var je = [
|
|
|
841
841
|
value: t.publishedAt ? new Date(t.publishedAt).toLocaleDateString() : r("devportal.notPublished", "Not published")
|
|
842
842
|
}
|
|
843
843
|
] })
|
|
844
|
-
}), /* @__PURE__ */
|
|
844
|
+
}), /* @__PURE__ */ W(b, {
|
|
845
845
|
title: r("devportal.links", "Links"),
|
|
846
|
-
children: /* @__PURE__ */
|
|
846
|
+
children: /* @__PURE__ */ G("div", {
|
|
847
847
|
className: "space-y-2",
|
|
848
848
|
children: [
|
|
849
|
-
t.websiteUrl && /* @__PURE__ */
|
|
849
|
+
t.websiteUrl && /* @__PURE__ */ W($, {
|
|
850
850
|
label: r("devportal.website", "Website"),
|
|
851
851
|
url: t.websiteUrl
|
|
852
852
|
}),
|
|
853
|
-
t.documentationUrl && /* @__PURE__ */
|
|
853
|
+
t.documentationUrl && /* @__PURE__ */ W($, {
|
|
854
854
|
label: r("devportal.documentation", "Documentation"),
|
|
855
855
|
url: t.documentationUrl
|
|
856
856
|
}),
|
|
857
|
-
t.supportUrl && /* @__PURE__ */
|
|
857
|
+
t.supportUrl && /* @__PURE__ */ W($, {
|
|
858
858
|
label: r("devportal.support", "Support"),
|
|
859
859
|
url: t.supportUrl
|
|
860
860
|
}),
|
|
861
|
-
t.githubUrl && /* @__PURE__ */
|
|
861
|
+
t.githubUrl && /* @__PURE__ */ W($, {
|
|
862
862
|
label: r("devportal.github", "GitHub"),
|
|
863
863
|
url: t.githubUrl
|
|
864
864
|
}),
|
|
865
|
-
t.privacyPolicyUrl && /* @__PURE__ */
|
|
865
|
+
t.privacyPolicyUrl && /* @__PURE__ */ W($, {
|
|
866
866
|
label: r("devportal.privacyPolicy", "Privacy Policy"),
|
|
867
867
|
url: t.privacyPolicyUrl
|
|
868
868
|
}),
|
|
869
|
-
t.termsOfServiceUrl && /* @__PURE__ */
|
|
869
|
+
t.termsOfServiceUrl && /* @__PURE__ */ W($, {
|
|
870
870
|
label: r("devportal.termsOfService", "Terms of Service"),
|
|
871
871
|
url: t.termsOfServiceUrl
|
|
872
872
|
})
|
|
@@ -880,11 +880,11 @@ var je = [
|
|
|
880
880
|
let n = i(e);
|
|
881
881
|
return n === e ? t : n;
|
|
882
882
|
};
|
|
883
|
-
return /* @__PURE__ */
|
|
883
|
+
return /* @__PURE__ */ G("div", {
|
|
884
884
|
className: "space-y-6",
|
|
885
|
-
children: [/* @__PURE__ */
|
|
885
|
+
children: [/* @__PURE__ */ G("div", {
|
|
886
886
|
className: "flex items-center justify-between",
|
|
887
|
-
children: [/* @__PURE__ */
|
|
887
|
+
children: [/* @__PURE__ */ G("p", {
|
|
888
888
|
className: "text-sm text-muted-foreground",
|
|
889
889
|
children: [
|
|
890
890
|
t.length,
|
|
@@ -893,81 +893,81 @@ var je = [
|
|
|
893
893
|
" ",
|
|
894
894
|
a("devportal.configured", "configured")
|
|
895
895
|
]
|
|
896
|
-
}), /* @__PURE__ */
|
|
896
|
+
}), /* @__PURE__ */ G("button", {
|
|
897
897
|
onClick: () => n(`/apps/${e}/webhooks/new`),
|
|
898
898
|
className: "inline-flex items-center gap-2 rounded-md bg-primary px-4 py-2 text-sm font-medium text-primary-foreground hover:bg-primary/90 transition-colors",
|
|
899
|
-
children: [/* @__PURE__ */
|
|
899
|
+
children: [/* @__PURE__ */ W(z, { size: 16 }), a("devportal.addWebhook", "Add Webhook")]
|
|
900
900
|
})]
|
|
901
|
-
}), t.length > 0 ? /* @__PURE__ */
|
|
901
|
+
}), t.length > 0 ? /* @__PURE__ */ W("div", {
|
|
902
902
|
className: "space-y-4",
|
|
903
|
-
children: t.map((t) => /* @__PURE__ */
|
|
903
|
+
children: t.map((t) => /* @__PURE__ */ G("div", {
|
|
904
904
|
className: "rounded-lg border bg-card p-4 space-y-4",
|
|
905
905
|
children: [
|
|
906
|
-
/* @__PURE__ */
|
|
906
|
+
/* @__PURE__ */ G("div", {
|
|
907
907
|
className: "flex items-start justify-between",
|
|
908
|
-
children: [/* @__PURE__ */
|
|
908
|
+
children: [/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ G("div", {
|
|
909
909
|
className: "flex items-center gap-2",
|
|
910
|
-
children: [/* @__PURE__ */
|
|
910
|
+
children: [/* @__PURE__ */ W("h3", {
|
|
911
911
|
className: "font-medium",
|
|
912
912
|
children: t.name
|
|
913
|
-
}), /* @__PURE__ */
|
|
913
|
+
}), /* @__PURE__ */ W(S, {
|
|
914
914
|
status: t.status,
|
|
915
915
|
type: "webhook"
|
|
916
916
|
})]
|
|
917
|
-
}), t.description && /* @__PURE__ */
|
|
917
|
+
}), t.description && /* @__PURE__ */ W("p", {
|
|
918
918
|
className: "text-sm text-muted-foreground mt-1",
|
|
919
919
|
children: t.description
|
|
920
|
-
})] }), /* @__PURE__ */
|
|
920
|
+
})] }), /* @__PURE__ */ W("button", {
|
|
921
921
|
onClick: () => n(`/apps/${e}/webhooks/${t.id}`),
|
|
922
922
|
className: "rounded-md p-1 hover:bg-muted",
|
|
923
|
-
children: /* @__PURE__ */
|
|
923
|
+
children: /* @__PURE__ */ W(ve, { size: 20 })
|
|
924
924
|
})]
|
|
925
925
|
}),
|
|
926
|
-
/* @__PURE__ */
|
|
926
|
+
/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("p", {
|
|
927
927
|
className: "text-xs text-muted-foreground mb-1",
|
|
928
928
|
children: a("devportal.endpointUrl", "Endpoint URL")
|
|
929
|
-
}), /* @__PURE__ */
|
|
929
|
+
}), /* @__PURE__ */ W("code", {
|
|
930
930
|
className: "text-sm bg-muted px-2 py-1 rounded block truncate",
|
|
931
931
|
children: t.url
|
|
932
932
|
})] }),
|
|
933
|
-
/* @__PURE__ */
|
|
933
|
+
/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("p", {
|
|
934
934
|
className: "text-xs text-muted-foreground mb-2",
|
|
935
935
|
children: a("devportal.events", "Events")
|
|
936
|
-
}), /* @__PURE__ */
|
|
936
|
+
}), /* @__PURE__ */ W("div", {
|
|
937
937
|
className: "flex flex-wrap gap-2",
|
|
938
|
-
children: t.events.map((e) => /* @__PURE__ */
|
|
938
|
+
children: t.events.map((e) => /* @__PURE__ */ W("span", {
|
|
939
939
|
className: "rounded-full bg-muted px-2 py-0.5 text-xs",
|
|
940
940
|
children: e
|
|
941
941
|
}, e))
|
|
942
942
|
})] }),
|
|
943
|
-
/* @__PURE__ */
|
|
943
|
+
/* @__PURE__ */ G("div", {
|
|
944
944
|
className: "grid gap-4 sm:grid-cols-4 text-sm",
|
|
945
945
|
children: [
|
|
946
|
-
/* @__PURE__ */
|
|
946
|
+
/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("p", {
|
|
947
947
|
className: "text-xs text-muted-foreground",
|
|
948
948
|
children: a("devportal.success", "Success")
|
|
949
|
-
}), /* @__PURE__ */
|
|
949
|
+
}), /* @__PURE__ */ W("p", {
|
|
950
950
|
className: "font-medium text-status-success-text",
|
|
951
951
|
children: t.successCount.toLocaleString()
|
|
952
952
|
})] }),
|
|
953
|
-
/* @__PURE__ */
|
|
953
|
+
/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("p", {
|
|
954
954
|
className: "text-xs text-muted-foreground",
|
|
955
955
|
children: a("devportal.failed", "Failed")
|
|
956
|
-
}), /* @__PURE__ */
|
|
956
|
+
}), /* @__PURE__ */ W("p", {
|
|
957
957
|
className: "font-medium text-status-error-text",
|
|
958
958
|
children: t.failureCount.toLocaleString()
|
|
959
959
|
})] }),
|
|
960
|
-
/* @__PURE__ */
|
|
960
|
+
/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("p", {
|
|
961
961
|
className: "text-xs text-muted-foreground",
|
|
962
962
|
children: a("devportal.successRate", "Success Rate")
|
|
963
|
-
}), /* @__PURE__ */
|
|
963
|
+
}), /* @__PURE__ */ G("p", {
|
|
964
964
|
className: "font-medium",
|
|
965
965
|
children: [t.successCount + t.failureCount > 0 ? (t.successCount / (t.successCount + t.failureCount) * 100).toFixed(1) : "0.0", "%"]
|
|
966
966
|
})] }),
|
|
967
|
-
/* @__PURE__ */
|
|
967
|
+
/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("p", {
|
|
968
968
|
className: "text-xs text-muted-foreground",
|
|
969
969
|
children: a("devportal.lastTriggered", "Last Triggered")
|
|
970
|
-
}), /* @__PURE__ */
|
|
970
|
+
}), /* @__PURE__ */ W("p", {
|
|
971
971
|
className: "font-medium",
|
|
972
972
|
children: t.lastTriggeredAt ? new Date(t.lastTriggeredAt).toLocaleString() : a("devportal.never", "Never")
|
|
973
973
|
})] })
|
|
@@ -975,14 +975,14 @@ var je = [
|
|
|
975
975
|
})
|
|
976
976
|
]
|
|
977
977
|
}, t.id))
|
|
978
|
-
}) : /* @__PURE__ */
|
|
979
|
-
icon: /* @__PURE__ */
|
|
978
|
+
}) : /* @__PURE__ */ W(r, {
|
|
979
|
+
icon: /* @__PURE__ */ W(Ce, { size: 32 }),
|
|
980
980
|
title: a("devportal.noWebhooks", "No webhooks"),
|
|
981
981
|
description: a("devportal.noWebhooksDescription", "Add a webhook to receive event notifications"),
|
|
982
|
-
action: /* @__PURE__ */
|
|
982
|
+
action: /* @__PURE__ */ G("button", {
|
|
983
983
|
onClick: () => n(`/apps/${e}/webhooks/new`),
|
|
984
984
|
className: "inline-flex items-center gap-2 rounded-md bg-primary px-4 py-2 text-sm font-medium text-primary-foreground hover:bg-primary/90",
|
|
985
|
-
children: [/* @__PURE__ */
|
|
985
|
+
children: [/* @__PURE__ */ W(z, { size: 16 }), a("devportal.addWebhook", "Add Webhook")]
|
|
986
986
|
})
|
|
987
987
|
})]
|
|
988
988
|
});
|
|
@@ -991,12 +991,12 @@ var je = [
|
|
|
991
991
|
let n = p(e);
|
|
992
992
|
return n === e ? t : n;
|
|
993
993
|
}, h = n.filter((e) => e.status === "ACTIVE"), g = n.filter((e) => e.status !== "ACTIVE");
|
|
994
|
-
return /* @__PURE__ */
|
|
994
|
+
return /* @__PURE__ */ G("div", {
|
|
995
995
|
className: "space-y-6",
|
|
996
996
|
children: [
|
|
997
|
-
/* @__PURE__ */
|
|
997
|
+
/* @__PURE__ */ G("div", {
|
|
998
998
|
className: "flex items-center justify-between",
|
|
999
|
-
children: [/* @__PURE__ */
|
|
999
|
+
children: [/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ G("p", {
|
|
1000
1000
|
className: "text-sm text-muted-foreground",
|
|
1001
1001
|
children: [
|
|
1002
1002
|
n.length,
|
|
@@ -1007,7 +1007,7 @@ var je = [
|
|
|
1007
1007
|
" ",
|
|
1008
1008
|
e
|
|
1009
1009
|
]
|
|
1010
|
-
}), h.length > 0 && /* @__PURE__ */
|
|
1010
|
+
}), h.length > 0 && /* @__PURE__ */ G("p", {
|
|
1011
1011
|
className: "text-xs text-muted-foreground mt-0.5",
|
|
1012
1012
|
children: [
|
|
1013
1013
|
h.length,
|
|
@@ -1019,44 +1019,44 @@ var je = [
|
|
|
1019
1019
|
" ",
|
|
1020
1020
|
m("devportal.revokedExpired", "revoked/expired")
|
|
1021
1021
|
]
|
|
1022
|
-
})] }), /* @__PURE__ */
|
|
1022
|
+
})] }), /* @__PURE__ */ G("button", {
|
|
1023
1023
|
onClick: i,
|
|
1024
1024
|
className: "inline-flex items-center gap-2 rounded-md bg-primary px-4 py-2 text-sm font-medium text-primary-foreground hover:bg-primary/90 transition-colors",
|
|
1025
|
-
children: [/* @__PURE__ */
|
|
1025
|
+
children: [/* @__PURE__ */ W(z, { size: 16 }), m("devportal.grantDelegation", "Grant Delegation")]
|
|
1026
1026
|
})]
|
|
1027
1027
|
}),
|
|
1028
|
-
h.length > 0 && /* @__PURE__ */
|
|
1028
|
+
h.length > 0 && /* @__PURE__ */ W("div", {
|
|
1029
1029
|
className: "rounded-lg border bg-card p-4",
|
|
1030
|
-
children: /* @__PURE__ */
|
|
1030
|
+
children: /* @__PURE__ */ G("div", {
|
|
1031
1031
|
className: "flex flex-col gap-3 lg:flex-row lg:items-center lg:justify-between",
|
|
1032
|
-
children: [/* @__PURE__ */
|
|
1032
|
+
children: [/* @__PURE__ */ G("div", {
|
|
1033
1033
|
className: "flex flex-wrap items-center gap-3",
|
|
1034
|
-
children: [/* @__PURE__ */
|
|
1034
|
+
children: [/* @__PURE__ */ G("div", {
|
|
1035
1035
|
className: "flex items-center gap-2",
|
|
1036
|
-
children: [/* @__PURE__ */
|
|
1036
|
+
children: [/* @__PURE__ */ W(C, {
|
|
1037
1037
|
checked: d,
|
|
1038
1038
|
indeterminate: f,
|
|
1039
1039
|
onChange: c,
|
|
1040
1040
|
ariaLabel: m("devportal.selectAllActiveDelegations", "Select all active app delegations")
|
|
1041
|
-
}), /* @__PURE__ */
|
|
1041
|
+
}), /* @__PURE__ */ W("span", {
|
|
1042
1042
|
className: "text-sm font-medium",
|
|
1043
1043
|
children: m("devportal.selectAllActive", "Select all active")
|
|
1044
1044
|
})]
|
|
1045
|
-
}), o.size > 0 && /* @__PURE__ */
|
|
1045
|
+
}), o.size > 0 && /* @__PURE__ */ W("button", {
|
|
1046
1046
|
onClick: l,
|
|
1047
1047
|
className: "text-sm text-muted-foreground hover:text-foreground",
|
|
1048
1048
|
children: m("devportal.clearSelection", "Clear selection")
|
|
1049
1049
|
})]
|
|
1050
|
-
}), /* @__PURE__ */
|
|
1050
|
+
}), /* @__PURE__ */ G("div", {
|
|
1051
1051
|
className: "flex flex-wrap items-center gap-2",
|
|
1052
|
-
children: [/* @__PURE__ */
|
|
1052
|
+
children: [/* @__PURE__ */ G("span", {
|
|
1053
1053
|
className: "rounded-full bg-muted px-3 py-1 text-sm font-medium text-muted-foreground",
|
|
1054
1054
|
children: [
|
|
1055
1055
|
o.size,
|
|
1056
1056
|
" ",
|
|
1057
1057
|
m("devportal.selected", "selected")
|
|
1058
1058
|
]
|
|
1059
|
-
}), /* @__PURE__ */
|
|
1059
|
+
}), /* @__PURE__ */ G("button", {
|
|
1060
1060
|
onClick: u,
|
|
1061
1061
|
disabled: o.size === 0,
|
|
1062
1062
|
className: "rounded-md border border-status-error-bg px-3 py-2 text-sm font-medium text-status-error-text hover:bg-status-error-bg-subtle disabled:cursor-not-allowed disabled:opacity-50",
|
|
@@ -1065,33 +1065,33 @@ var je = [
|
|
|
1065
1065
|
})]
|
|
1066
1066
|
})
|
|
1067
1067
|
}),
|
|
1068
|
-
n.length > 0 ? /* @__PURE__ */
|
|
1068
|
+
n.length > 0 ? /* @__PURE__ */ W("div", {
|
|
1069
1069
|
className: "space-y-4",
|
|
1070
|
-
children: n.map((e) => /* @__PURE__ */
|
|
1070
|
+
children: n.map((e) => /* @__PURE__ */ G("div", {
|
|
1071
1071
|
className: "rounded-lg border bg-card p-4 space-y-4",
|
|
1072
1072
|
children: [
|
|
1073
|
-
/* @__PURE__ */
|
|
1073
|
+
/* @__PURE__ */ G("div", {
|
|
1074
1074
|
className: "flex items-start justify-between",
|
|
1075
|
-
children: [/* @__PURE__ */
|
|
1075
|
+
children: [/* @__PURE__ */ G("div", {
|
|
1076
1076
|
className: "flex items-start gap-3",
|
|
1077
|
-
children: [e.status === "ACTIVE" && /* @__PURE__ */
|
|
1077
|
+
children: [e.status === "ACTIVE" && /* @__PURE__ */ W("div", {
|
|
1078
1078
|
onClick: (e) => e.stopPropagation(),
|
|
1079
|
-
children: /* @__PURE__ */
|
|
1079
|
+
children: /* @__PURE__ */ W(C, {
|
|
1080
1080
|
checked: o.has(e.id),
|
|
1081
1081
|
onChange: (t) => s(e.id, t),
|
|
1082
1082
|
ariaLabel: `Select delegation ${e.id}`,
|
|
1083
1083
|
className: "mt-1"
|
|
1084
1084
|
})
|
|
1085
|
-
}), /* @__PURE__ */
|
|
1085
|
+
}), /* @__PURE__ */ G("div", { children: [/* @__PURE__ */ G("div", {
|
|
1086
1086
|
className: "flex items-center gap-2",
|
|
1087
|
-
children: [/* @__PURE__ */
|
|
1087
|
+
children: [/* @__PURE__ */ G("h3", {
|
|
1088
1088
|
className: "font-medium",
|
|
1089
1089
|
children: ["Delegation #", e.id.slice(0, 8)]
|
|
1090
|
-
}), /* @__PURE__ */
|
|
1091
|
-
className: t("rounded-full px-2 py-0.5 text-xs font-medium",
|
|
1090
|
+
}), /* @__PURE__ */ W("span", {
|
|
1091
|
+
className: t("rounded-full px-2 py-0.5 text-xs font-medium", Y[e.status]),
|
|
1092
1092
|
children: e.status
|
|
1093
1093
|
})]
|
|
1094
|
-
}), /* @__PURE__ */
|
|
1094
|
+
}), /* @__PURE__ */ G("p", {
|
|
1095
1095
|
className: "text-sm text-muted-foreground mt-1",
|
|
1096
1096
|
children: [
|
|
1097
1097
|
m("devportal.granted", "Granted"),
|
|
@@ -1103,55 +1103,55 @@ var je = [
|
|
|
1103
1103
|
e.grantedBy === e.userId ? m("devportal.you", "you") : e.grantedBy.slice(0, 8)
|
|
1104
1104
|
]
|
|
1105
1105
|
})] })]
|
|
1106
|
-
}), e.status === "ACTIVE" && /* @__PURE__ */
|
|
1106
|
+
}), e.status === "ACTIVE" && /* @__PURE__ */ G("button", {
|
|
1107
1107
|
onClick: () => a(e.id),
|
|
1108
1108
|
className: "inline-flex items-center gap-1.5 rounded-md border border-border-subtle px-3 py-1.5 text-xs font-medium text-status-error-text hover:bg-status-error-bg-subtle transition-colors",
|
|
1109
|
-
children: [/* @__PURE__ */
|
|
1109
|
+
children: [/* @__PURE__ */ W(Te, { size: 14 }), m("devportal.revoke", "Revoke")]
|
|
1110
1110
|
})]
|
|
1111
1111
|
}),
|
|
1112
|
-
/* @__PURE__ */
|
|
1112
|
+
/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("p", {
|
|
1113
1113
|
className: "text-xs text-muted-foreground mb-2",
|
|
1114
1114
|
children: m("devportal.grantedScopes", "Granted Scopes")
|
|
1115
|
-
}), /* @__PURE__ */
|
|
1115
|
+
}), /* @__PURE__ */ W("div", {
|
|
1116
1116
|
className: "flex flex-wrap gap-2",
|
|
1117
|
-
children: e.scopes.map((e) => /* @__PURE__ */
|
|
1117
|
+
children: e.scopes.map((e) => /* @__PURE__ */ W("span", {
|
|
1118
1118
|
className: "rounded-full bg-status-success-bg-subtle px-2 py-0.5 text-xs text-status-success-text",
|
|
1119
1119
|
children: e
|
|
1120
1120
|
}, e))
|
|
1121
1121
|
})] }),
|
|
1122
|
-
e.workspaceIds.length > 0 && /* @__PURE__ */
|
|
1122
|
+
e.workspaceIds.length > 0 && /* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("p", {
|
|
1123
1123
|
className: "text-xs text-muted-foreground mb-2",
|
|
1124
1124
|
children: m("devportal.workspaceScope", "Workspace Scope")
|
|
1125
|
-
}), /* @__PURE__ */
|
|
1125
|
+
}), /* @__PURE__ */ W("div", {
|
|
1126
1126
|
className: "flex flex-wrap gap-2",
|
|
1127
|
-
children: e.workspaceIds.map((e) => /* @__PURE__ */
|
|
1127
|
+
children: e.workspaceIds.map((e) => /* @__PURE__ */ W("code", {
|
|
1128
1128
|
className: "rounded bg-muted px-2 py-0.5 text-xs",
|
|
1129
1129
|
children: e
|
|
1130
1130
|
}, e))
|
|
1131
1131
|
})] }),
|
|
1132
|
-
/* @__PURE__ */
|
|
1132
|
+
/* @__PURE__ */ G("div", {
|
|
1133
1133
|
className: "flex items-center gap-4 text-xs text-muted-foreground",
|
|
1134
1134
|
children: [
|
|
1135
|
-
e.expiresAt && /* @__PURE__ */
|
|
1135
|
+
e.expiresAt && /* @__PURE__ */ G("span", {
|
|
1136
1136
|
className: "flex items-center gap-1",
|
|
1137
1137
|
children: [
|
|
1138
|
-
/* @__PURE__ */
|
|
1138
|
+
/* @__PURE__ */ W(fe, { size: 12 }),
|
|
1139
1139
|
m("devportal.expires", "Expires"),
|
|
1140
1140
|
" ",
|
|
1141
1141
|
new Date(e.expiresAt).toLocaleDateString()
|
|
1142
1142
|
]
|
|
1143
1143
|
}),
|
|
1144
|
-
!e.expiresAt && e.status === "ACTIVE" && /* @__PURE__ */
|
|
1144
|
+
!e.expiresAt && e.status === "ACTIVE" && /* @__PURE__ */ G("span", {
|
|
1145
1145
|
className: "flex items-center gap-1",
|
|
1146
|
-
children: [/* @__PURE__ */
|
|
1146
|
+
children: [/* @__PURE__ */ W(I, {
|
|
1147
1147
|
size: 12,
|
|
1148
1148
|
className: "text-status-success-text"
|
|
1149
1149
|
}), m("devportal.noExpiration", "No expiration")]
|
|
1150
1150
|
}),
|
|
1151
|
-
e.revokedAt && /* @__PURE__ */
|
|
1151
|
+
e.revokedAt && /* @__PURE__ */ G("span", {
|
|
1152
1152
|
className: "flex items-center gap-1",
|
|
1153
1153
|
children: [
|
|
1154
|
-
/* @__PURE__ */
|
|
1154
|
+
/* @__PURE__ */ W(Te, {
|
|
1155
1155
|
size: 12,
|
|
1156
1156
|
className: "text-status-error-text"
|
|
1157
1157
|
}),
|
|
@@ -1164,14 +1164,14 @@ var je = [
|
|
|
1164
1164
|
})
|
|
1165
1165
|
]
|
|
1166
1166
|
}, e.id))
|
|
1167
|
-
}) : /* @__PURE__ */
|
|
1168
|
-
icon: /* @__PURE__ */
|
|
1167
|
+
}) : /* @__PURE__ */ W(r, {
|
|
1168
|
+
icon: /* @__PURE__ */ W(H, { size: 32 }),
|
|
1169
1169
|
title: m("devportal.noDelegations", "No delegations"),
|
|
1170
1170
|
description: m("devportal.noDelegationsDescription", "Grant a delegation to allow this app to act on your behalf"),
|
|
1171
|
-
action: /* @__PURE__ */
|
|
1171
|
+
action: /* @__PURE__ */ G("button", {
|
|
1172
1172
|
onClick: i,
|
|
1173
1173
|
className: "inline-flex items-center gap-2 rounded-md bg-primary px-4 py-2 text-sm font-medium text-primary-foreground hover:bg-primary/90",
|
|
1174
|
-
children: [/* @__PURE__ */
|
|
1174
|
+
children: [/* @__PURE__ */ W(z, { size: 16 }), m("devportal.grantDelegation", "Grant Delegation")]
|
|
1175
1175
|
})
|
|
1176
1176
|
})
|
|
1177
1177
|
]
|
|
@@ -1181,35 +1181,35 @@ var je = [
|
|
|
1181
1181
|
let r = t(e);
|
|
1182
1182
|
return r === e ? n : r;
|
|
1183
1183
|
}, i = e[0], a = e[1], o = (e, t) => t ? (e - t) / t * 100 : 0;
|
|
1184
|
-
return /* @__PURE__ */
|
|
1184
|
+
return /* @__PURE__ */ G("div", {
|
|
1185
1185
|
className: "space-y-6",
|
|
1186
|
-
children: [/* @__PURE__ */
|
|
1186
|
+
children: [/* @__PURE__ */ G("div", {
|
|
1187
1187
|
className: "grid gap-4 sm:grid-cols-4",
|
|
1188
1188
|
children: [
|
|
1189
|
-
/* @__PURE__ */
|
|
1189
|
+
/* @__PURE__ */ W(Q, {
|
|
1190
1190
|
label: n("devportal.activeUsers", "Active Users"),
|
|
1191
1191
|
value: i?.activeUsers.toLocaleString() || "0",
|
|
1192
1192
|
trend: a ? o(i.activeUsers, a.activeUsers) : void 0
|
|
1193
1193
|
}),
|
|
1194
|
-
/* @__PURE__ */
|
|
1194
|
+
/* @__PURE__ */ W(Q, {
|
|
1195
1195
|
label: n("devportal.apiCalls", "API Calls"),
|
|
1196
1196
|
value: i ? `${(i.apiCalls / 1e3).toFixed(1)}K` : "0",
|
|
1197
1197
|
trend: a ? o(i.apiCalls, a.apiCalls) : void 0
|
|
1198
1198
|
}),
|
|
1199
|
-
/* @__PURE__ */
|
|
1199
|
+
/* @__PURE__ */ W(Q, {
|
|
1200
1200
|
label: n("devportal.avgResponseTime", "Avg Response Time"),
|
|
1201
1201
|
value: i?.avgResponseTime ? `${i.avgResponseTime}ms` : n("devportal.notAvailable", "N/A"),
|
|
1202
1202
|
trend: a && i?.avgResponseTime ? -o(i.avgResponseTime, a.avgResponseTime || 1) : void 0
|
|
1203
1203
|
}),
|
|
1204
|
-
/* @__PURE__ */
|
|
1204
|
+
/* @__PURE__ */ W(Q, {
|
|
1205
1205
|
label: n("devportal.errorRate", "Error Rate"),
|
|
1206
1206
|
value: i && i.apiCalls > 0 ? `${(i.errors / i.apiCalls * 100).toFixed(2)}%` : "0%",
|
|
1207
1207
|
trend: a && i && i.apiCalls > 0 && a.apiCalls > 0 ? -o(i.errors / i.apiCalls, a.errors / a.apiCalls) : void 0
|
|
1208
1208
|
})
|
|
1209
1209
|
]
|
|
1210
|
-
}), /* @__PURE__ */
|
|
1210
|
+
}), /* @__PURE__ */ W(b, {
|
|
1211
1211
|
title: n("devportal.dailyBreakdown", "Daily Breakdown"),
|
|
1212
|
-
children: e.length > 0 ? /* @__PURE__ */
|
|
1212
|
+
children: e.length > 0 ? /* @__PURE__ */ W(T, {
|
|
1213
1213
|
data: e,
|
|
1214
1214
|
keyField: "id",
|
|
1215
1215
|
columns: [
|
|
@@ -1249,8 +1249,8 @@ var je = [
|
|
|
1249
1249
|
render: (e) => e.sessions.toLocaleString()
|
|
1250
1250
|
}
|
|
1251
1251
|
]
|
|
1252
|
-
}) : /* @__PURE__ */
|
|
1253
|
-
icon: /* @__PURE__ */
|
|
1252
|
+
}) : /* @__PURE__ */ W(r, {
|
|
1253
|
+
icon: /* @__PURE__ */ W(F, { size: 32 }),
|
|
1254
1254
|
title: n("devportal.noAnalyticsData", "No analytics data"),
|
|
1255
1255
|
description: n("devportal.noAnalyticsDataDescription", "Analytics data will appear here once the application starts receiving traffic.")
|
|
1256
1256
|
})
|
|
@@ -1294,21 +1294,21 @@ var je = [
|
|
|
1294
1294
|
]), x = A(() => {
|
|
1295
1295
|
i && v(i), b(!0);
|
|
1296
1296
|
}, [i]);
|
|
1297
|
-
return /* @__PURE__ */
|
|
1297
|
+
return /* @__PURE__ */ G("div", {
|
|
1298
1298
|
className: "space-y-4",
|
|
1299
1299
|
children: [
|
|
1300
|
-
/* @__PURE__ */
|
|
1300
|
+
/* @__PURE__ */ G("div", {
|
|
1301
1301
|
className: "flex items-center justify-between",
|
|
1302
|
-
children: [/* @__PURE__ */
|
|
1302
|
+
children: [/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("h3", {
|
|
1303
1303
|
className: "text-lg font-semibold",
|
|
1304
1304
|
children: o("devportal.apiPlayground", "API Playground")
|
|
1305
|
-
}), /* @__PURE__ */
|
|
1305
|
+
}), /* @__PURE__ */ G("p", {
|
|
1306
1306
|
className: "text-sm text-muted-foreground",
|
|
1307
1307
|
children: [
|
|
1308
1308
|
o("devportal.apiPlaygroundDescription", "Test GraphQL APIs in the context of"),
|
|
1309
1309
|
" ",
|
|
1310
|
-
/* @__PURE__ */
|
|
1311
|
-
t.appId && /* @__PURE__ */
|
|
1310
|
+
/* @__PURE__ */ W("strong", { children: t.name }),
|
|
1311
|
+
t.appId && /* @__PURE__ */ G("span", {
|
|
1312
1312
|
className: "ml-1 text-xs text-muted-foreground",
|
|
1313
1313
|
children: [
|
|
1314
1314
|
"(OAuth App: ",
|
|
@@ -1317,39 +1317,39 @@ var je = [
|
|
|
1317
1317
|
]
|
|
1318
1318
|
})
|
|
1319
1319
|
]
|
|
1320
|
-
})] }), /* @__PURE__ */
|
|
1320
|
+
})] }), /* @__PURE__ */ G("button", {
|
|
1321
1321
|
onClick: x,
|
|
1322
1322
|
className: "flex items-center gap-2 rounded-md border px-3 py-1.5 text-sm font-medium hover:bg-accent transition-colors",
|
|
1323
|
-
children: [/* @__PURE__ */
|
|
1323
|
+
children: [/* @__PURE__ */ W(_e, { size: 14 }), o("devportal.autoFillCredentials", "Auto-fill Credentials")]
|
|
1324
1324
|
})]
|
|
1325
1325
|
}),
|
|
1326
|
-
y && /* @__PURE__ */
|
|
1326
|
+
y && /* @__PURE__ */ G("div", {
|
|
1327
1327
|
className: "rounded-lg border bg-status-info-bg-subtle p-4 text-sm space-y-2",
|
|
1328
1328
|
children: [
|
|
1329
|
-
/* @__PURE__ */
|
|
1329
|
+
/* @__PURE__ */ W("p", {
|
|
1330
1330
|
className: "font-medium text-status-info-text",
|
|
1331
1331
|
children: o("devportal.authenticationGuide", "Authentication Guide")
|
|
1332
1332
|
}),
|
|
1333
|
-
/* @__PURE__ */
|
|
1333
|
+
/* @__PURE__ */ G("p", {
|
|
1334
1334
|
className: "text-status-info-text",
|
|
1335
1335
|
children: [
|
|
1336
1336
|
o("devportal.authenticationGuideText", "Your current session token has been filled in. For app-level authentication (Client Credentials flow), use the"),
|
|
1337
1337
|
" ",
|
|
1338
|
-
/* @__PURE__ */
|
|
1338
|
+
/* @__PURE__ */ W("strong", { children: o("devportal.oauthClientsTab", "OAuth Clients") }),
|
|
1339
1339
|
" ",
|
|
1340
1340
|
o("devportal.authenticationGuideText2", "tab to get the app's clientId and clientSecret, then call:")
|
|
1341
1341
|
]
|
|
1342
1342
|
}),
|
|
1343
|
-
/* @__PURE__ */
|
|
1343
|
+
/* @__PURE__ */ W("pre", {
|
|
1344
1344
|
className: "rounded bg-status-info-bg-subtle p-2 text-xs overflow-x-auto text-status-info-text",
|
|
1345
1345
|
children: "mutation {\n authenticateApp(input: {\n clientId: \"<your-client-id>\"\n clientSecret: \"<your-client-secret>\"\n scopes: []\n }) {\n accessToken\n tokenType\n expiresIn\n }\n}"
|
|
1346
1346
|
}),
|
|
1347
|
-
/* @__PURE__ */
|
|
1347
|
+
/* @__PURE__ */ G("p", {
|
|
1348
1348
|
className: "text-status-info-text",
|
|
1349
1349
|
children: [
|
|
1350
1350
|
o("devportal.useReturnedAccessToken", "Use the returned"),
|
|
1351
1351
|
" ",
|
|
1352
|
-
/* @__PURE__ */
|
|
1352
|
+
/* @__PURE__ */ W("code", {
|
|
1353
1353
|
className: "bg-status-info-bg-subtle px-1 rounded",
|
|
1354
1354
|
children: "accessToken"
|
|
1355
1355
|
}),
|
|
@@ -1357,79 +1357,79 @@ var je = [
|
|
|
1357
1357
|
o("devportal.asBearerToken", "as the Bearer token below.")
|
|
1358
1358
|
]
|
|
1359
1359
|
}),
|
|
1360
|
-
/* @__PURE__ */
|
|
1360
|
+
/* @__PURE__ */ W("button", {
|
|
1361
1361
|
onClick: () => b(!1),
|
|
1362
1362
|
className: "text-xs text-accent-blue hover:underline",
|
|
1363
1363
|
children: o("devportal.dismiss", "Dismiss")
|
|
1364
1364
|
})
|
|
1365
1365
|
]
|
|
1366
1366
|
}),
|
|
1367
|
-
/* @__PURE__ */
|
|
1367
|
+
/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("label", {
|
|
1368
1368
|
className: "block text-sm font-medium mb-1",
|
|
1369
1369
|
children: o("devportal.gatewayEndpoint", "Gateway Endpoint")
|
|
1370
|
-
}), /* @__PURE__ */
|
|
1370
|
+
}), /* @__PURE__ */ G("div", {
|
|
1371
1371
|
className: "flex gap-2",
|
|
1372
|
-
children: [/* @__PURE__ */
|
|
1372
|
+
children: [/* @__PURE__ */ W("input", {
|
|
1373
1373
|
type: "text",
|
|
1374
1374
|
value: h,
|
|
1375
1375
|
onChange: (e) => g(e.target.value),
|
|
1376
1376
|
className: "flex-1 rounded-md border px-3 py-2 text-sm font-mono bg-background"
|
|
1377
|
-
}), /* @__PURE__ */
|
|
1377
|
+
}), /* @__PURE__ */ G("select", {
|
|
1378
1378
|
onChange: (e) => g(e.target.value),
|
|
1379
1379
|
className: "rounded-md border px-3 py-2 text-sm bg-background",
|
|
1380
1380
|
value: h,
|
|
1381
|
-
children: [/* @__PURE__ */
|
|
1381
|
+
children: [/* @__PURE__ */ W("option", {
|
|
1382
1382
|
value: `${n || "https://gw-global.local.burdenoff.com"}/global/graphql`,
|
|
1383
1383
|
children: o("devportal.globalGateway", "Global Gateway")
|
|
1384
|
-
}), /* @__PURE__ */
|
|
1384
|
+
}), /* @__PURE__ */ W("option", {
|
|
1385
1385
|
value: `${r || "https://gw-wspace.local.burdenoff.com"}/workspaces/graphql`,
|
|
1386
1386
|
children: o("devportal.workspaceGateway", "Workspace Gateway")
|
|
1387
1387
|
})]
|
|
1388
1388
|
})]
|
|
1389
1389
|
})] }),
|
|
1390
|
-
/* @__PURE__ */
|
|
1390
|
+
/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("label", {
|
|
1391
1391
|
className: "block text-sm font-medium mb-1",
|
|
1392
1392
|
children: o("devportal.bearerToken", "Bearer Token")
|
|
1393
|
-
}), /* @__PURE__ */
|
|
1393
|
+
}), /* @__PURE__ */ W("input", {
|
|
1394
1394
|
type: "password",
|
|
1395
1395
|
value: _,
|
|
1396
1396
|
onChange: (e) => v(e.target.value),
|
|
1397
1397
|
placeholder: o("devportal.pasteAccessToken", "Paste access token here..."),
|
|
1398
1398
|
className: "w-full rounded-md border px-3 py-2 text-sm font-mono bg-background"
|
|
1399
1399
|
})] }),
|
|
1400
|
-
/* @__PURE__ */
|
|
1400
|
+
/* @__PURE__ */ G("div", {
|
|
1401
1401
|
className: "grid grid-cols-1 lg:grid-cols-2 gap-4",
|
|
1402
|
-
children: [/* @__PURE__ */
|
|
1402
|
+
children: [/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("label", {
|
|
1403
1403
|
className: "block text-sm font-medium mb-1",
|
|
1404
1404
|
children: o("devportal.query", "Query")
|
|
1405
|
-
}), /* @__PURE__ */
|
|
1405
|
+
}), /* @__PURE__ */ W("textarea", {
|
|
1406
1406
|
value: s,
|
|
1407
1407
|
onChange: (e) => c(e.target.value),
|
|
1408
1408
|
className: "w-full h-64 rounded-md border px-3 py-2 text-sm font-mono bg-background resize-y",
|
|
1409
1409
|
spellCheck: !1
|
|
1410
|
-
})] }), /* @__PURE__ */
|
|
1410
|
+
})] }), /* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("label", {
|
|
1411
1411
|
className: "block text-sm font-medium mb-1",
|
|
1412
1412
|
children: o("devportal.variablesJson", "Variables (JSON)")
|
|
1413
|
-
}), /* @__PURE__ */
|
|
1413
|
+
}), /* @__PURE__ */ W("textarea", {
|
|
1414
1414
|
value: l,
|
|
1415
1415
|
onChange: (e) => u(e.target.value),
|
|
1416
1416
|
className: "w-full h-64 rounded-md border px-3 py-2 text-sm font-mono bg-background resize-y",
|
|
1417
1417
|
spellCheck: !1
|
|
1418
1418
|
})] })]
|
|
1419
1419
|
}),
|
|
1420
|
-
/* @__PURE__ */
|
|
1420
|
+
/* @__PURE__ */ G("button", {
|
|
1421
1421
|
onClick: ee,
|
|
1422
1422
|
disabled: p,
|
|
1423
1423
|
className: "flex items-center gap-2 rounded-md bg-primary px-4 py-2 text-sm font-medium text-primary-foreground hover:bg-primary/90 transition-colors disabled:opacity-50",
|
|
1424
|
-
children: [p ? /* @__PURE__ */
|
|
1424
|
+
children: [p ? /* @__PURE__ */ W(R, {
|
|
1425
1425
|
size: 16,
|
|
1426
1426
|
className: "animate-spin"
|
|
1427
|
-
}) : /* @__PURE__ */
|
|
1427
|
+
}) : /* @__PURE__ */ W(L, { size: 16 }), p ? o("devportal.executing", "Executing...") : o("devportal.executeQuery", "Execute Query")]
|
|
1428
1428
|
}),
|
|
1429
|
-
d && /* @__PURE__ */
|
|
1429
|
+
d && /* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("label", {
|
|
1430
1430
|
className: "block text-sm font-medium mb-1",
|
|
1431
1431
|
children: o("devportal.response", "Response")
|
|
1432
|
-
}), /* @__PURE__ */
|
|
1432
|
+
}), /* @__PURE__ */ W("pre", {
|
|
1433
1433
|
className: "w-full max-h-96 overflow-auto rounded-md border bg-muted p-4 text-xs font-mono",
|
|
1434
1434
|
children: d
|
|
1435
1435
|
})] })
|
|
@@ -1441,45 +1441,45 @@ var je = [
|
|
|
1441
1441
|
r((await s(e)).downloadUrl);
|
|
1442
1442
|
} catch {}
|
|
1443
1443
|
}, [s, r]);
|
|
1444
|
-
return /* @__PURE__ */
|
|
1444
|
+
return /* @__PURE__ */ G("div", {
|
|
1445
1445
|
className: "space-y-1.5",
|
|
1446
1446
|
children: [
|
|
1447
|
-
/* @__PURE__ */
|
|
1447
|
+
/* @__PURE__ */ W("label", {
|
|
1448
1448
|
className: "text-sm font-medium",
|
|
1449
1449
|
children: e
|
|
1450
1450
|
}),
|
|
1451
|
-
/* @__PURE__ */
|
|
1451
|
+
/* @__PURE__ */ G("div", {
|
|
1452
1452
|
className: "flex gap-3 items-start",
|
|
1453
|
-
children: [/* @__PURE__ */
|
|
1453
|
+
children: [/* @__PURE__ */ G("div", {
|
|
1454
1454
|
className: t("relative shrink-0 w-20 rounded-lg border border-border bg-bg-sunken overflow-hidden flex items-center justify-center", o),
|
|
1455
|
-
children: [n ? /* @__PURE__ */
|
|
1455
|
+
children: [n ? /* @__PURE__ */ W("img", {
|
|
1456
1456
|
src: n,
|
|
1457
1457
|
alt: e,
|
|
1458
1458
|
className: "w-full h-full object-cover"
|
|
1459
|
-
}) : /* @__PURE__ */
|
|
1459
|
+
}) : /* @__PURE__ */ W(V, {
|
|
1460
1460
|
size: 18,
|
|
1461
1461
|
className: "text-text-secondary opacity-40"
|
|
1462
|
-
}), c && /* @__PURE__ */
|
|
1462
|
+
}), c && /* @__PURE__ */ G("div", {
|
|
1463
1463
|
className: "absolute inset-0 bg-black/40 flex flex-col items-center justify-center gap-1",
|
|
1464
|
-
children: [/* @__PURE__ */
|
|
1464
|
+
children: [/* @__PURE__ */ W(R, {
|
|
1465
1465
|
size: 14,
|
|
1466
1466
|
className: "animate-spin text-white"
|
|
1467
|
-
}), /* @__PURE__ */
|
|
1467
|
+
}), /* @__PURE__ */ G("span", {
|
|
1468
1468
|
className: "text-white text-xs",
|
|
1469
1469
|
children: [l, "%"]
|
|
1470
1470
|
})]
|
|
1471
1471
|
})]
|
|
1472
|
-
}), /* @__PURE__ */
|
|
1472
|
+
}), /* @__PURE__ */ G("div", {
|
|
1473
1473
|
className: "flex-1 space-y-1.5",
|
|
1474
1474
|
children: [
|
|
1475
|
-
/* @__PURE__ */
|
|
1475
|
+
/* @__PURE__ */ W("input", {
|
|
1476
1476
|
type: "url",
|
|
1477
1477
|
value: n,
|
|
1478
1478
|
onChange: (e) => r(e.target.value),
|
|
1479
1479
|
placeholder: "https://...",
|
|
1480
1480
|
className: "w-full rounded-md border border-border bg-bg-input px-3 py-1.5 text-sm placeholder:text-text-placeholder focus:outline-none focus:ring-2 focus:ring-primary/30"
|
|
1481
1481
|
}),
|
|
1482
|
-
/* @__PURE__ */
|
|
1482
|
+
/* @__PURE__ */ W("input", {
|
|
1483
1483
|
ref: d,
|
|
1484
1484
|
type: "file",
|
|
1485
1485
|
accept: a,
|
|
@@ -1489,21 +1489,21 @@ var je = [
|
|
|
1489
1489
|
t && f(t), e.target.value = "";
|
|
1490
1490
|
}
|
|
1491
1491
|
}),
|
|
1492
|
-
/* @__PURE__ */
|
|
1492
|
+
/* @__PURE__ */ G("button", {
|
|
1493
1493
|
type: "button",
|
|
1494
1494
|
disabled: c,
|
|
1495
1495
|
onClick: () => d.current?.click(),
|
|
1496
1496
|
className: "inline-flex items-center gap-1.5 rounded-md border px-2.5 py-1 text-xs font-medium hover:bg-muted transition-colors disabled:opacity-50",
|
|
1497
|
-
children: [/* @__PURE__ */
|
|
1497
|
+
children: [/* @__PURE__ */ W(V, { size: 11 }), c ? `Uploading… ${l}%` : "Upload image"]
|
|
1498
1498
|
}),
|
|
1499
|
-
u && /* @__PURE__ */
|
|
1499
|
+
u && /* @__PURE__ */ W("p", {
|
|
1500
1500
|
className: "text-xs text-status-error-text",
|
|
1501
1501
|
children: u
|
|
1502
1502
|
})
|
|
1503
1503
|
]
|
|
1504
1504
|
})]
|
|
1505
1505
|
}),
|
|
1506
|
-
i && /* @__PURE__ */
|
|
1506
|
+
i && /* @__PURE__ */ W("p", {
|
|
1507
1507
|
className: "text-xs text-text-secondary",
|
|
1508
1508
|
children: i
|
|
1509
1509
|
})
|
|
@@ -1522,45 +1522,45 @@ var je = [
|
|
|
1522
1522
|
]), l = (t) => {
|
|
1523
1523
|
n(e.filter((e, n) => n !== t));
|
|
1524
1524
|
};
|
|
1525
|
-
return /* @__PURE__ */
|
|
1525
|
+
return /* @__PURE__ */ G("div", {
|
|
1526
1526
|
className: "space-y-2",
|
|
1527
1527
|
children: [
|
|
1528
|
-
/* @__PURE__ */
|
|
1528
|
+
/* @__PURE__ */ W("label", {
|
|
1529
1529
|
className: "text-sm font-medium",
|
|
1530
1530
|
children: "Screenshots"
|
|
1531
1531
|
}),
|
|
1532
|
-
/* @__PURE__ */
|
|
1532
|
+
/* @__PURE__ */ G("div", {
|
|
1533
1533
|
className: "flex flex-wrap gap-3",
|
|
1534
|
-
children: [e.map((e, t) => /* @__PURE__ */
|
|
1534
|
+
children: [e.map((e, t) => /* @__PURE__ */ G("div", {
|
|
1535
1535
|
className: "relative group w-36 aspect-video rounded-lg border border-border overflow-hidden bg-bg-sunken",
|
|
1536
|
-
children: [/* @__PURE__ */
|
|
1536
|
+
children: [/* @__PURE__ */ W("img", {
|
|
1537
1537
|
src: e,
|
|
1538
1538
|
alt: `Screenshot ${t + 1}`,
|
|
1539
1539
|
className: "w-full h-full object-cover"
|
|
1540
|
-
}), /* @__PURE__ */
|
|
1540
|
+
}), /* @__PURE__ */ W("button", {
|
|
1541
1541
|
type: "button",
|
|
1542
1542
|
onClick: () => l(t),
|
|
1543
1543
|
className: "absolute top-1 right-1 rounded-full bg-black/60 text-white p-0.5 opacity-0 group-hover:opacity-100 transition-opacity",
|
|
1544
|
-
children: /* @__PURE__ */
|
|
1544
|
+
children: /* @__PURE__ */ W(we, { size: 12 })
|
|
1545
1545
|
})]
|
|
1546
|
-
}, t)), /* @__PURE__ */
|
|
1546
|
+
}, t)), /* @__PURE__ */ W("button", {
|
|
1547
1547
|
type: "button",
|
|
1548
1548
|
disabled: i,
|
|
1549
1549
|
onClick: () => s.current?.click(),
|
|
1550
1550
|
className: t("w-36 aspect-video rounded-lg border-2 border-dashed border-border flex flex-col items-center justify-center gap-1.5 text-text-secondary hover:border-border-strong hover:bg-bg-sunken transition-colors disabled:opacity-50"),
|
|
1551
|
-
children: i ? /* @__PURE__ */
|
|
1551
|
+
children: i ? /* @__PURE__ */ G(U, { children: [/* @__PURE__ */ W(R, {
|
|
1552
1552
|
size: 18,
|
|
1553
1553
|
className: "animate-spin text-primary"
|
|
1554
|
-
}), /* @__PURE__ */
|
|
1554
|
+
}), /* @__PURE__ */ G("span", {
|
|
1555
1555
|
className: "text-xs",
|
|
1556
1556
|
children: [a, "%"]
|
|
1557
|
-
})] }) : /* @__PURE__ */
|
|
1557
|
+
})] }) : /* @__PURE__ */ G(U, { children: [/* @__PURE__ */ W(V, { size: 18 }), /* @__PURE__ */ W("span", {
|
|
1558
1558
|
className: "text-xs",
|
|
1559
1559
|
children: "Add screenshot"
|
|
1560
1560
|
})] })
|
|
1561
1561
|
})]
|
|
1562
1562
|
}),
|
|
1563
|
-
/* @__PURE__ */
|
|
1563
|
+
/* @__PURE__ */ W("input", {
|
|
1564
1564
|
ref: s,
|
|
1565
1565
|
type: "file",
|
|
1566
1566
|
accept: "image/png,image/jpeg,image/webp,image/gif",
|
|
@@ -1570,7 +1570,7 @@ var je = [
|
|
|
1570
1570
|
t && c(t), e.target.value = "";
|
|
1571
1571
|
}
|
|
1572
1572
|
}),
|
|
1573
|
-
o && /* @__PURE__ */
|
|
1573
|
+
o && /* @__PURE__ */ W("p", {
|
|
1574
1574
|
className: "text-xs text-status-error-text",
|
|
1575
1575
|
children: o
|
|
1576
1576
|
})
|
|
@@ -1681,15 +1681,15 @@ function Je(e) {
|
|
|
1681
1681
|
manifestJsonContent: typeof t.jsonContent == "string" ? t.jsonContent : typeof t.content == "string" ? t.content : ""
|
|
1682
1682
|
};
|
|
1683
1683
|
}
|
|
1684
|
-
var Ye =
|
|
1684
|
+
var Ye = K`
|
|
1685
1685
|
query MyPublisherForListing {
|
|
1686
1686
|
myPublisher { id }
|
|
1687
1687
|
}
|
|
1688
|
-
`, Xe =
|
|
1688
|
+
`, Xe = K`
|
|
1689
1689
|
query PublisherProductsForListing($publisherId: String!) {
|
|
1690
1690
|
products(filter: { publisherId: $publisherId }) { id productId }
|
|
1691
1691
|
}
|
|
1692
|
-
`, Ze =
|
|
1692
|
+
`, Ze = K`
|
|
1693
1693
|
mutation UpdateStoreProduct($input: UpdateProductInput!) {
|
|
1694
1694
|
updateProduct(input: $input) { id name description }
|
|
1695
1695
|
}
|
|
@@ -1699,11 +1699,11 @@ var Ye = q`
|
|
|
1699
1699
|
return n === e ? t : n;
|
|
1700
1700
|
}, [d, f] = N(() => Je(n)), [p, m] = N(!1), [h, _] = N(!1), y = M(n);
|
|
1701
1701
|
y.current = n;
|
|
1702
|
-
let { data: ee } =
|
|
1702
|
+
let { data: ee } = J(Ye, { fetchPolicy: "cache-first" }), x = ee?.myPublisher?.id ?? null, { data: S } = J(Xe, {
|
|
1703
1703
|
variables: { publisherId: x ?? "" },
|
|
1704
1704
|
fetchPolicy: "cache-first",
|
|
1705
1705
|
skip: !x
|
|
1706
|
-
}), te = S?.products?.find((e) => e.productId === n.id)?.id ?? null, [C] =
|
|
1706
|
+
}), te = S?.products?.find((e) => e.productId === n.id)?.id ?? null, [C] = q(Ze), [ne] = v(), [T, { loading: E }] = g();
|
|
1707
1707
|
ce(() => {
|
|
1708
1708
|
f(Je(y.current));
|
|
1709
1709
|
}, [n.id]);
|
|
@@ -1767,35 +1767,29 @@ var Ye = q`
|
|
|
1767
1767
|
} finally {
|
|
1768
1768
|
m(!1);
|
|
1769
1769
|
}
|
|
1770
|
-
}, oe = async () => {
|
|
1771
|
-
try {
|
|
1772
|
-
await T({ variables: { id: n.id } }), w("success");
|
|
1773
|
-
} catch {
|
|
1774
|
-
w("error");
|
|
1775
|
-
}
|
|
1776
|
-
}, se = M(null), j = M(null), { upload: F, uploading: I, progress: ue, error: pe } = k(r, i, a, o), { upload: R, uploading: me, progress: ge, error: _e } = k(r, i, a, o, "/DevPortal/Assets"), { upload: B, uploading: ve, progress: ye, error: V } = k(r, i, a, o, "/DevPortal/Assets"), { upload: U, uploading: Se, progress: Ce, error: we } = k(r, i, a, o, "/DevPortal/Assets"), Te = A(async (e) => {
|
|
1770
|
+
}, oe = M(null), se = M(null), { upload: j, uploading: ue, progress: F, error: de } = k(r, i, a, o), { upload: me, uploading: L, progress: he, error: _e } = k(r, i, a, o, "/DevPortal/Assets"), { upload: ve, uploading: z, progress: ye, error: be } = k(r, i, a, o, "/DevPortal/Assets"), { upload: B, uploading: H, progress: Ce, error: we } = k(r, i, a, o, "/DevPortal/Assets"), Te = A(async (e) => {
|
|
1777
1771
|
let t = e.target.files?.[0];
|
|
1778
1772
|
if (t) {
|
|
1779
1773
|
e.target.value = "";
|
|
1780
1774
|
try {
|
|
1781
|
-
let e = await
|
|
1775
|
+
let e = await j(t);
|
|
1782
1776
|
f((t) => ({
|
|
1783
1777
|
...t,
|
|
1784
1778
|
manifestRegistryUrl: e.downloadUrl
|
|
1785
1779
|
}));
|
|
1786
1780
|
} catch {}
|
|
1787
1781
|
}
|
|
1788
|
-
}, [
|
|
1782
|
+
}, [j]), Ee = A(async (e) => {
|
|
1789
1783
|
e.preventDefault(), _(!1);
|
|
1790
1784
|
let t = e.dataTransfer.files?.[0];
|
|
1791
1785
|
if (t) try {
|
|
1792
|
-
let e = await
|
|
1786
|
+
let e = await j(t);
|
|
1793
1787
|
f((t) => ({
|
|
1794
1788
|
...t,
|
|
1795
1789
|
manifestRegistryUrl: e.downloadUrl
|
|
1796
1790
|
}));
|
|
1797
1791
|
} catch {}
|
|
1798
|
-
}, [
|
|
1792
|
+
}, [j]), De = A((e) => {
|
|
1799
1793
|
let t = e.target.files?.[0];
|
|
1800
1794
|
if (!t) return;
|
|
1801
1795
|
let n = new FileReader();
|
|
@@ -1814,7 +1808,7 @@ var Ye = q`
|
|
|
1814
1808
|
}));
|
|
1815
1809
|
} catch {}
|
|
1816
1810
|
}, n.readAsText(t), e.target.value = "";
|
|
1817
|
-
}, []),
|
|
1811
|
+
}, []), K = A(() => {
|
|
1818
1812
|
let e = d.manifestPermissionsText.split("\n").map((e) => e.trim()).filter(Boolean), t = Ge.has(d.manifestItemType), r = {
|
|
1819
1813
|
manifestVersion: "1.0",
|
|
1820
1814
|
itemType: d.manifestItemType || void 0,
|
|
@@ -1832,7 +1826,7 @@ var Ye = q`
|
|
|
1832
1826
|
o.href = a, o.download = `${n.slug}-manifest.json`, o.click(), URL.revokeObjectURL(a);
|
|
1833
1827
|
}, [n.slug, d]), Oe = Ge.has(d.manifestItemType), ke = d.manifestInstallType === "builtin", Ae = d.pricingType !== "FREE", je = d.manifestRegistryUrl ? d.manifestRegistryUrl.split("/").pop()?.split("?")[0] ?? "" : "";
|
|
1834
1828
|
n.status;
|
|
1835
|
-
let Me = n.status === "SUBMITTED",
|
|
1829
|
+
let Me = n.status === "SUBMITTED", Y = n.status === "PUBLISHED", X = n.appType === "NODE" || n.appType === "WORKFLOW", Z = n.appType === "API_INTEGRATION", Ne = [
|
|
1836
1830
|
{
|
|
1837
1831
|
label: "Short description",
|
|
1838
1832
|
done: !!d.shortDescription.trim()
|
|
@@ -1853,38 +1847,38 @@ var Ye = q`
|
|
|
1853
1847
|
label: "Terms of Service URL",
|
|
1854
1848
|
done: !!d.termsOfServiceUrl.trim()
|
|
1855
1849
|
}
|
|
1856
|
-
],
|
|
1857
|
-
return /* @__PURE__ */
|
|
1850
|
+
], Pe = Ne.filter((e) => e.done).length, Fe = Ne.length;
|
|
1851
|
+
return /* @__PURE__ */ G("div", {
|
|
1858
1852
|
className: "space-y-8 max-w-3xl",
|
|
1859
1853
|
children: [
|
|
1860
|
-
/* @__PURE__ */
|
|
1854
|
+
/* @__PURE__ */ G("div", {
|
|
1861
1855
|
className: "rounded-lg border border-primary/20 bg-primary/5 px-4 py-3 space-y-2",
|
|
1862
|
-
children: [/* @__PURE__ */
|
|
1856
|
+
children: [/* @__PURE__ */ W("p", {
|
|
1863
1857
|
className: "text-sm font-semibold text-primary",
|
|
1864
1858
|
children: u("devportal.listingTabPurpose", "What is this tab for?")
|
|
1865
|
-
}), /* @__PURE__ */
|
|
1859
|
+
}), /* @__PURE__ */ G("ul", {
|
|
1866
1860
|
className: "text-sm text-muted-foreground space-y-1 list-none pl-0",
|
|
1867
1861
|
children: [
|
|
1868
|
-
/* @__PURE__ */
|
|
1862
|
+
/* @__PURE__ */ G("li", {
|
|
1869
1863
|
className: "flex items-start gap-2",
|
|
1870
|
-
children: [/* @__PURE__ */
|
|
1864
|
+
children: [/* @__PURE__ */ W(Se, {
|
|
1871
1865
|
size: 14,
|
|
1872
1866
|
className: "mt-0.5 shrink-0 text-primary"
|
|
1873
|
-
}), /* @__PURE__ */
|
|
1874
|
-
/* @__PURE__ */
|
|
1867
|
+
}), /* @__PURE__ */ G("span", { children: [
|
|
1868
|
+
/* @__PURE__ */ W("strong", { children: u("devportal.thisTab", "This tab") }),
|
|
1875
1869
|
" ",
|
|
1876
1870
|
u("devportal.listingTabDesc", "controls your store card — the name, description, icon and screenshots users see in the marketplace. Save changes here any time without creating a new release.")
|
|
1877
1871
|
] })]
|
|
1878
1872
|
}),
|
|
1879
|
-
|
|
1873
|
+
X && /* @__PURE__ */ G("li", {
|
|
1880
1874
|
className: "flex items-start gap-2",
|
|
1881
|
-
children: [/* @__PURE__ */
|
|
1875
|
+
children: [/* @__PURE__ */ W(fe, {
|
|
1882
1876
|
size: 14,
|
|
1883
1877
|
className: "mt-0.5 shrink-0 text-primary"
|
|
1884
|
-
}), /* @__PURE__ */
|
|
1878
|
+
}), /* @__PURE__ */ G("span", { children: [
|
|
1885
1879
|
u("devportal.versionsTabDesc", "To release a new version (ZIP package + manifest), go to the"),
|
|
1886
1880
|
" ",
|
|
1887
|
-
/* @__PURE__ */
|
|
1881
|
+
/* @__PURE__ */ W("button", {
|
|
1888
1882
|
type: "button",
|
|
1889
1883
|
className: "underline text-primary hover:no-underline",
|
|
1890
1884
|
onClick: () => s?.(`${c}/apps/${n.id}/versions`),
|
|
@@ -1893,66 +1887,66 @@ var Ye = q`
|
|
|
1893
1887
|
"."
|
|
1894
1888
|
] })]
|
|
1895
1889
|
}),
|
|
1896
|
-
/* @__PURE__ */
|
|
1890
|
+
/* @__PURE__ */ G("li", {
|
|
1897
1891
|
className: "flex items-start gap-2",
|
|
1898
|
-
children: [/* @__PURE__ */
|
|
1892
|
+
children: [/* @__PURE__ */ W(xe, {
|
|
1899
1893
|
size: 14,
|
|
1900
1894
|
className: "mt-0.5 shrink-0 text-primary"
|
|
1901
|
-
}), /* @__PURE__ */
|
|
1895
|
+
}), /* @__PURE__ */ W("span", { children: u("devportal.submitTabDesc", "When your listing is ready, click \"Submit for Review\" to send it to the review team.") })]
|
|
1902
1896
|
})
|
|
1903
1897
|
]
|
|
1904
1898
|
})]
|
|
1905
1899
|
}),
|
|
1906
|
-
!
|
|
1900
|
+
!Y && /* @__PURE__ */ G("div", {
|
|
1907
1901
|
className: "rounded-lg border bg-card p-4 space-y-3",
|
|
1908
|
-
children: [/* @__PURE__ */
|
|
1902
|
+
children: [/* @__PURE__ */ G("div", {
|
|
1909
1903
|
className: "flex items-center justify-between",
|
|
1910
|
-
children: [/* @__PURE__ */
|
|
1904
|
+
children: [/* @__PURE__ */ G("p", {
|
|
1911
1905
|
className: "text-sm font-medium",
|
|
1912
1906
|
children: [
|
|
1913
1907
|
u("devportal.listingCompleteness", "Listing completeness"),
|
|
1914
1908
|
" ",
|
|
1915
|
-
/* @__PURE__ */
|
|
1916
|
-
className: t("ml-1 text-xs font-semibold",
|
|
1909
|
+
/* @__PURE__ */ G("span", {
|
|
1910
|
+
className: t("ml-1 text-xs font-semibold", Pe === Fe ? "text-status-success-text" : "text-status-warning-text"),
|
|
1917
1911
|
children: [
|
|
1918
|
-
|
|
1912
|
+
Pe,
|
|
1919
1913
|
"/",
|
|
1920
|
-
|
|
1914
|
+
Fe
|
|
1921
1915
|
]
|
|
1922
1916
|
})
|
|
1923
1917
|
]
|
|
1924
|
-
}),
|
|
1918
|
+
}), Pe === Fe && /* @__PURE__ */ G("span", {
|
|
1925
1919
|
className: "text-xs text-status-success-text flex items-center gap-1",
|
|
1926
|
-
children: [/* @__PURE__ */
|
|
1920
|
+
children: [/* @__PURE__ */ W(I, { size: 12 }), u("devportal.readyToSubmit", "Ready to submit")]
|
|
1927
1921
|
})]
|
|
1928
|
-
}), /* @__PURE__ */
|
|
1922
|
+
}), /* @__PURE__ */ W("div", {
|
|
1929
1923
|
className: "grid grid-cols-2 sm:grid-cols-3 gap-2",
|
|
1930
|
-
children:
|
|
1924
|
+
children: Ne.map((e) => /* @__PURE__ */ G("div", {
|
|
1931
1925
|
className: "flex items-center gap-1.5 text-xs",
|
|
1932
|
-
children: [e.done ? /* @__PURE__ */
|
|
1926
|
+
children: [e.done ? /* @__PURE__ */ W(I, {
|
|
1933
1927
|
size: 12,
|
|
1934
1928
|
className: "text-status-success-text shrink-0"
|
|
1935
|
-
}) : /* @__PURE__ */
|
|
1929
|
+
}) : /* @__PURE__ */ W(le, {
|
|
1936
1930
|
size: 12,
|
|
1937
1931
|
className: "text-status-warning-text shrink-0"
|
|
1938
|
-
}), /* @__PURE__ */
|
|
1932
|
+
}), /* @__PURE__ */ W("span", {
|
|
1939
1933
|
className: e.done ? "text-foreground" : "text-muted-foreground",
|
|
1940
1934
|
children: e.label
|
|
1941
1935
|
})]
|
|
1942
1936
|
}, e.label))
|
|
1943
1937
|
})]
|
|
1944
1938
|
}),
|
|
1945
|
-
|
|
1939
|
+
Y ? /* @__PURE__ */ G("div", {
|
|
1946
1940
|
className: "flex items-start gap-3 rounded-lg border border-success/30 bg-success/10 px-4 py-3",
|
|
1947
|
-
children: [/* @__PURE__ */
|
|
1941
|
+
children: [/* @__PURE__ */ W(I, {
|
|
1948
1942
|
size: 16,
|
|
1949
1943
|
className: "text-success mt-0.5 shrink-0"
|
|
1950
|
-
}), /* @__PURE__ */
|
|
1944
|
+
}), /* @__PURE__ */ G("div", {
|
|
1951
1945
|
className: "text-sm",
|
|
1952
|
-
children: [/* @__PURE__ */
|
|
1946
|
+
children: [/* @__PURE__ */ W("span", {
|
|
1953
1947
|
className: "font-medium text-success",
|
|
1954
1948
|
children: u("devportal.storeListing.published", "Published")
|
|
1955
|
-
}), n.publishedAt && /* @__PURE__ */
|
|
1949
|
+
}), n.publishedAt && /* @__PURE__ */ G("span", {
|
|
1956
1950
|
className: "text-muted-foreground ml-2",
|
|
1957
1951
|
children: [
|
|
1958
1952
|
u("devportal.storeListing.since", "since"),
|
|
@@ -1961,66 +1955,66 @@ var Ye = q`
|
|
|
1961
1955
|
]
|
|
1962
1956
|
})]
|
|
1963
1957
|
})]
|
|
1964
|
-
}) : Me ? /* @__PURE__ */
|
|
1958
|
+
}) : Me ? /* @__PURE__ */ G("div", {
|
|
1965
1959
|
className: "flex items-start gap-3 rounded-lg border border-primary/30 bg-primary/5 px-4 py-3",
|
|
1966
|
-
children: [/* @__PURE__ */
|
|
1960
|
+
children: [/* @__PURE__ */ W(fe, {
|
|
1967
1961
|
size: 16,
|
|
1968
1962
|
className: "text-primary mt-0.5 shrink-0"
|
|
1969
|
-
}), /* @__PURE__ */
|
|
1963
|
+
}), /* @__PURE__ */ G("div", {
|
|
1970
1964
|
className: "text-sm",
|
|
1971
1965
|
children: [
|
|
1972
|
-
/* @__PURE__ */
|
|
1966
|
+
/* @__PURE__ */ W("span", {
|
|
1973
1967
|
className: "font-medium text-primary",
|
|
1974
1968
|
children: u("devportal.storeListing.underReview", "Submitted for review")
|
|
1975
1969
|
}),
|
|
1976
|
-
n.submittedAt && /* @__PURE__ */
|
|
1970
|
+
n.submittedAt && /* @__PURE__ */ W("span", {
|
|
1977
1971
|
className: "text-muted-foreground ml-2",
|
|
1978
1972
|
children: new Date(n.submittedAt).toLocaleDateString()
|
|
1979
1973
|
}),
|
|
1980
|
-
n.reviewStatus && /* @__PURE__ */
|
|
1974
|
+
n.reviewStatus && /* @__PURE__ */ G("span", {
|
|
1981
1975
|
className: "text-muted-foreground ml-2",
|
|
1982
1976
|
children: ["· ", n.reviewStatus]
|
|
1983
1977
|
})
|
|
1984
1978
|
]
|
|
1985
1979
|
})]
|
|
1986
|
-
}) : /* @__PURE__ */
|
|
1980
|
+
}) : /* @__PURE__ */ G("div", {
|
|
1987
1981
|
className: "flex items-start gap-3 rounded-lg border border-warning/30 bg-warning/5 px-4 py-3",
|
|
1988
|
-
children: [/* @__PURE__ */
|
|
1982
|
+
children: [/* @__PURE__ */ W(le, {
|
|
1989
1983
|
size: 16,
|
|
1990
1984
|
className: "text-warning mt-0.5 shrink-0"
|
|
1991
|
-
}), /* @__PURE__ */
|
|
1985
|
+
}), /* @__PURE__ */ G("div", {
|
|
1992
1986
|
className: "text-sm",
|
|
1993
|
-
children: [/* @__PURE__ */
|
|
1987
|
+
children: [/* @__PURE__ */ W("span", {
|
|
1994
1988
|
className: "font-medium text-warning",
|
|
1995
1989
|
children: u("devportal.storeListing.draft", "Draft")
|
|
1996
|
-
}), /* @__PURE__ */
|
|
1990
|
+
}), /* @__PURE__ */ W("span", {
|
|
1997
1991
|
className: "text-muted-foreground ml-2",
|
|
1998
1992
|
children: u("devportal.storeListing.draftHint", "Complete your store listing and submit for review to publish.")
|
|
1999
1993
|
})]
|
|
2000
1994
|
})]
|
|
2001
1995
|
}),
|
|
2002
|
-
|
|
1996
|
+
X ? /* @__PURE__ */ G("div", {
|
|
2003
1997
|
className: "rounded-lg border border-border-subtle bg-bg-sunken px-4 py-4 flex items-start gap-3",
|
|
2004
|
-
children: [/* @__PURE__ */
|
|
1998
|
+
children: [/* @__PURE__ */ W(ge, {
|
|
2005
1999
|
size: 16,
|
|
2006
2000
|
className: "shrink-0 mt-0.5 text-muted-foreground"
|
|
2007
|
-
}), /* @__PURE__ */
|
|
2001
|
+
}), /* @__PURE__ */ G("div", {
|
|
2008
2002
|
className: "text-sm space-y-1",
|
|
2009
|
-
children: [/* @__PURE__ */
|
|
2003
|
+
children: [/* @__PURE__ */ W("p", {
|
|
2010
2004
|
className: "font-medium",
|
|
2011
2005
|
children: u("devportal.packageManagedInVersions", "ZIP package & manifest are managed in Versions")
|
|
2012
|
-
}), /* @__PURE__ */
|
|
2006
|
+
}), /* @__PURE__ */ W("p", {
|
|
2013
2007
|
className: "text-muted-foreground",
|
|
2014
2008
|
children: u("devportal.packageManagedInVersionsDesc", "For NODE and WORKFLOW types, each release is uploaded through the Versions page — including the ZIP archive and manifest.json. This keeps your code releases separate from your store card.")
|
|
2015
2009
|
})]
|
|
2016
2010
|
})]
|
|
2017
|
-
}) : !
|
|
2011
|
+
}) : !Z && /* @__PURE__ */ W(b, {
|
|
2018
2012
|
title: u("devportal.package", "Package"),
|
|
2019
2013
|
description: u("devportal.packageDescription", "Technical configuration — how FluidGrid installs and runs this item"),
|
|
2020
|
-
children: /* @__PURE__ */
|
|
2014
|
+
children: /* @__PURE__ */ G("div", {
|
|
2021
2015
|
className: "space-y-6",
|
|
2022
2016
|
children: [
|
|
2023
|
-
/* @__PURE__ */
|
|
2017
|
+
/* @__PURE__ */ W(re, {
|
|
2024
2018
|
label: u("devportal.storeItemType", "Item Type"),
|
|
2025
2019
|
value: d.manifestItemType,
|
|
2026
2020
|
onChange: (e) => {
|
|
@@ -2031,14 +2025,14 @@ var Ye = q`
|
|
|
2031
2025
|
placeholder: u("devportal.selectItemType", "Select item type…"),
|
|
2032
2026
|
hint: u("devportal.storeItemTypeHint", "Determines how this item is categorised and how the platform runs it")
|
|
2033
2027
|
}),
|
|
2034
|
-
/* @__PURE__ */
|
|
2028
|
+
/* @__PURE__ */ G("div", {
|
|
2035
2029
|
className: "grid gap-4 sm:grid-cols-2",
|
|
2036
|
-
children: [/* @__PURE__ */
|
|
2030
|
+
children: [/* @__PURE__ */ W(D, {
|
|
2037
2031
|
label: u("devportal.manifestDisplayName", "Display Name"),
|
|
2038
2032
|
value: d.manifestDisplayName,
|
|
2039
2033
|
onChange: (e) => O("manifestDisplayName", e.target.value),
|
|
2040
2034
|
placeholder: "My Awesome Node"
|
|
2041
|
-
}), /* @__PURE__ */
|
|
2035
|
+
}), /* @__PURE__ */ W(D, {
|
|
2042
2036
|
label: u("devportal.manifestVersion", "Version"),
|
|
2043
2037
|
value: d.manifestVersion,
|
|
2044
2038
|
onChange: (e) => O("manifestVersion", e.target.value),
|
|
@@ -2046,7 +2040,7 @@ var Ye = q`
|
|
|
2046
2040
|
hint: u("devportal.semverHint", "Semantic version (MAJOR.MINOR.PATCH)")
|
|
2047
2041
|
})]
|
|
2048
2042
|
}),
|
|
2049
|
-
Oe && /* @__PURE__ */
|
|
2043
|
+
Oe && /* @__PURE__ */ W(ie, {
|
|
2050
2044
|
label: u("devportal.jsonContent", d.manifestItemType === "workflow" ? "Workflow Definition (JSON)" : "Template Definition (JSON)"),
|
|
2051
2045
|
value: d.manifestJsonContent,
|
|
2052
2046
|
onChange: (e) => O("manifestJsonContent", e.target.value),
|
|
@@ -2054,141 +2048,141 @@ var Ye = q`
|
|
|
2054
2048
|
placeholder: "{\n \"nodes\": [],\n \"edges\": []\n}",
|
|
2055
2049
|
hint: u("devportal.jsonContentHint", "Paste the full JSON definition. Stored and applied directly — no zip needed.")
|
|
2056
2050
|
}),
|
|
2057
|
-
!Oe && /* @__PURE__ */
|
|
2051
|
+
!Oe && /* @__PURE__ */ G("div", {
|
|
2058
2052
|
className: "space-y-3",
|
|
2059
2053
|
children: [
|
|
2060
|
-
/* @__PURE__ */
|
|
2054
|
+
/* @__PURE__ */ G("div", {
|
|
2061
2055
|
className: "flex items-center justify-between flex-wrap gap-2",
|
|
2062
|
-
children: [/* @__PURE__ */
|
|
2056
|
+
children: [/* @__PURE__ */ W("label", {
|
|
2063
2057
|
className: "text-sm font-medium",
|
|
2064
2058
|
children: u("devportal.packageFile", "Package File")
|
|
2065
|
-
}), /* @__PURE__ */
|
|
2059
|
+
}), /* @__PURE__ */ G("label", {
|
|
2066
2060
|
className: "flex items-center gap-2 text-sm cursor-pointer select-none",
|
|
2067
|
-
children: [/* @__PURE__ */
|
|
2061
|
+
children: [/* @__PURE__ */ W("input", {
|
|
2068
2062
|
type: "checkbox",
|
|
2069
2063
|
checked: ke,
|
|
2070
2064
|
onChange: (e) => O("manifestInstallType", e.target.checked ? "builtin" : "zip"),
|
|
2071
2065
|
className: "h-4 w-4 rounded border-border accent-primary"
|
|
2072
|
-
}), /* @__PURE__ */
|
|
2066
|
+
}), /* @__PURE__ */ W("span", {
|
|
2073
2067
|
className: "text-text-secondary",
|
|
2074
2068
|
children: u("devportal.builtinToggle", "Built-in (pre-installed, no upload needed)")
|
|
2075
2069
|
})]
|
|
2076
2070
|
})]
|
|
2077
2071
|
}),
|
|
2078
|
-
!ke && /* @__PURE__ */
|
|
2079
|
-
/* @__PURE__ */
|
|
2072
|
+
!ke && /* @__PURE__ */ G(U, { children: [
|
|
2073
|
+
/* @__PURE__ */ G("div", {
|
|
2080
2074
|
className: "flex gap-3 rounded-lg border border-border-subtle bg-bg-sunken p-3 text-sm text-text-secondary",
|
|
2081
|
-
children: [/* @__PURE__ */
|
|
2075
|
+
children: [/* @__PURE__ */ W(ge, {
|
|
2082
2076
|
size: 15,
|
|
2083
2077
|
className: "mt-0.5 shrink-0"
|
|
2084
|
-
}), /* @__PURE__ */
|
|
2078
|
+
}), /* @__PURE__ */ G("span", { children: [
|
|
2085
2079
|
u("devportal.zipModelHint", "Package your code and a "),
|
|
2086
|
-
/* @__PURE__ */
|
|
2080
|
+
/* @__PURE__ */ W("code", {
|
|
2087
2081
|
className: "rounded bg-muted px-1 py-0.5 font-mono text-xs",
|
|
2088
2082
|
children: "manifest.json"
|
|
2089
2083
|
}),
|
|
2090
2084
|
u("devportal.zipModelHint2", " into a single zip — like a Chrome extension. Upload it below and FluidGrid handles the rest automatically.")
|
|
2091
2085
|
] })]
|
|
2092
2086
|
}),
|
|
2093
|
-
/* @__PURE__ */
|
|
2087
|
+
/* @__PURE__ */ G("div", {
|
|
2094
2088
|
onDragOver: (e) => {
|
|
2095
2089
|
e.preventDefault(), _(!0);
|
|
2096
2090
|
},
|
|
2097
2091
|
onDragLeave: () => _(!1),
|
|
2098
2092
|
onDrop: (e) => void Ee(e),
|
|
2099
|
-
onClick: () => !
|
|
2100
|
-
className: t("relative flex flex-col items-center justify-center gap-3 rounded-xl border-2 border-dashed px-6 py-10 text-center transition-colors cursor-pointer", h ? "border-primary bg-primary/5" : "border-border hover:border-border-strong hover:bg-bg-sunken",
|
|
2101
|
-
children: [/* @__PURE__ */
|
|
2102
|
-
ref:
|
|
2093
|
+
onClick: () => !ue && se.current?.click(),
|
|
2094
|
+
className: t("relative flex flex-col items-center justify-center gap-3 rounded-xl border-2 border-dashed px-6 py-10 text-center transition-colors cursor-pointer", h ? "border-primary bg-primary/5" : "border-border hover:border-border-strong hover:bg-bg-sunken", ue && "pointer-events-none opacity-75"),
|
|
2095
|
+
children: [/* @__PURE__ */ W("input", {
|
|
2096
|
+
ref: se,
|
|
2103
2097
|
type: "file",
|
|
2104
2098
|
accept: ".zip,application/zip,application/x-zip-compressed",
|
|
2105
2099
|
className: "hidden",
|
|
2106
2100
|
onChange: (e) => void Te(e)
|
|
2107
|
-
}),
|
|
2108
|
-
/* @__PURE__ */
|
|
2101
|
+
}), ue ? /* @__PURE__ */ G(U, { children: [
|
|
2102
|
+
/* @__PURE__ */ W(R, {
|
|
2109
2103
|
size: 28,
|
|
2110
2104
|
className: "animate-spin text-primary"
|
|
2111
2105
|
}),
|
|
2112
|
-
/* @__PURE__ */
|
|
2106
|
+
/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ G("p", {
|
|
2113
2107
|
className: "text-sm font-medium",
|
|
2114
2108
|
children: [
|
|
2115
2109
|
u("devportal.uploading", "Uploading…"),
|
|
2116
2110
|
" ",
|
|
2117
|
-
|
|
2111
|
+
F,
|
|
2118
2112
|
"%"
|
|
2119
2113
|
]
|
|
2120
|
-
}), /* @__PURE__ */
|
|
2114
|
+
}), /* @__PURE__ */ W("p", {
|
|
2121
2115
|
className: "text-xs text-text-secondary mt-0.5",
|
|
2122
2116
|
children: u("devportal.uploadingHint", "Stored securely in your workspace")
|
|
2123
2117
|
})] }),
|
|
2124
|
-
/* @__PURE__ */
|
|
2118
|
+
/* @__PURE__ */ W("div", {
|
|
2125
2119
|
className: "w-48 h-1.5 rounded-full bg-muted overflow-hidden",
|
|
2126
|
-
children: /* @__PURE__ */
|
|
2120
|
+
children: /* @__PURE__ */ W("div", {
|
|
2127
2121
|
className: "h-full bg-primary transition-all",
|
|
2128
|
-
style: { width: `${
|
|
2122
|
+
style: { width: `${F}%` }
|
|
2129
2123
|
})
|
|
2130
2124
|
})
|
|
2131
|
-
] }) : je ? /* @__PURE__ */
|
|
2125
|
+
] }) : je ? /* @__PURE__ */ G(U, { children: [/* @__PURE__ */ W(I, {
|
|
2132
2126
|
size: 28,
|
|
2133
2127
|
className: "text-status-success-text"
|
|
2134
|
-
}), /* @__PURE__ */
|
|
2128
|
+
}), /* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("p", {
|
|
2135
2129
|
className: "text-sm font-medium",
|
|
2136
2130
|
children: je
|
|
2137
|
-
}), /* @__PURE__ */
|
|
2131
|
+
}), /* @__PURE__ */ W("p", {
|
|
2138
2132
|
className: "text-xs text-text-secondary mt-0.5",
|
|
2139
2133
|
children: u("devportal.clickToReplace", "Click or drag to replace")
|
|
2140
|
-
})] })] }) : /* @__PURE__ */
|
|
2134
|
+
})] })] }) : /* @__PURE__ */ G(U, { children: [/* @__PURE__ */ W(V, {
|
|
2141
2135
|
size: 28,
|
|
2142
2136
|
className: "text-text-secondary"
|
|
2143
|
-
}), /* @__PURE__ */
|
|
2137
|
+
}), /* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("p", {
|
|
2144
2138
|
className: "text-sm font-medium",
|
|
2145
2139
|
children: u("devportal.dropZipHere", "Drop your .zip here")
|
|
2146
|
-
}), /* @__PURE__ */
|
|
2140
|
+
}), /* @__PURE__ */ W("p", {
|
|
2147
2141
|
className: "text-xs text-text-secondary mt-0.5",
|
|
2148
2142
|
children: u("devportal.orClickToBrowse", "or click to browse")
|
|
2149
2143
|
})] })] })]
|
|
2150
2144
|
}),
|
|
2151
|
-
|
|
2145
|
+
de && /* @__PURE__ */ W("p", {
|
|
2152
2146
|
className: "text-xs text-status-error-text",
|
|
2153
|
-
children:
|
|
2147
|
+
children: de
|
|
2154
2148
|
})
|
|
2155
2149
|
] }),
|
|
2156
|
-
ke && /* @__PURE__ */
|
|
2150
|
+
ke && /* @__PURE__ */ G("div", {
|
|
2157
2151
|
className: "flex gap-3 rounded-lg border border-border-subtle bg-bg-sunken p-3 text-sm text-text-secondary",
|
|
2158
|
-
children: [/* @__PURE__ */
|
|
2152
|
+
children: [/* @__PURE__ */ W(ge, {
|
|
2159
2153
|
size: 15,
|
|
2160
2154
|
className: "mt-0.5 shrink-0"
|
|
2161
|
-
}), /* @__PURE__ */
|
|
2155
|
+
}), /* @__PURE__ */ W("span", { children: u("devportal.builtinHint", "Built-in items are pre-installed by the platform. No package upload is needed.") })]
|
|
2162
2156
|
})
|
|
2163
2157
|
]
|
|
2164
2158
|
}),
|
|
2165
|
-
/* @__PURE__ */
|
|
2159
|
+
/* @__PURE__ */ G("div", {
|
|
2166
2160
|
className: "flex flex-wrap items-center gap-2 border-t pt-4",
|
|
2167
2161
|
children: [
|
|
2168
|
-
/* @__PURE__ */
|
|
2169
|
-
ref:
|
|
2162
|
+
/* @__PURE__ */ W("input", {
|
|
2163
|
+
ref: oe,
|
|
2170
2164
|
type: "file",
|
|
2171
2165
|
accept: ".json,application/json",
|
|
2172
2166
|
className: "hidden",
|
|
2173
|
-
onChange:
|
|
2167
|
+
onChange: De
|
|
2174
2168
|
}),
|
|
2175
|
-
/* @__PURE__ */
|
|
2169
|
+
/* @__PURE__ */ W("span", {
|
|
2176
2170
|
className: "text-xs text-text-secondary mr-1",
|
|
2177
2171
|
children: "manifest.json:"
|
|
2178
2172
|
}),
|
|
2179
|
-
/* @__PURE__ */
|
|
2173
|
+
/* @__PURE__ */ G("button", {
|
|
2180
2174
|
type: "button",
|
|
2181
|
-
onClick: () =>
|
|
2175
|
+
onClick: () => oe.current?.click(),
|
|
2182
2176
|
className: "inline-flex items-center gap-1.5 rounded-md border px-2.5 py-1 text-xs font-medium hover:bg-muted transition-colors",
|
|
2183
|
-
children: [/* @__PURE__ */
|
|
2177
|
+
children: [/* @__PURE__ */ W(V, { size: 12 }), u("devportal.importManifest", "Import")]
|
|
2184
2178
|
}),
|
|
2185
|
-
/* @__PURE__ */
|
|
2179
|
+
/* @__PURE__ */ G("button", {
|
|
2186
2180
|
type: "button",
|
|
2187
|
-
onClick:
|
|
2181
|
+
onClick: K,
|
|
2188
2182
|
className: "inline-flex items-center gap-1.5 rounded-md border px-2.5 py-1 text-xs font-medium hover:bg-muted transition-colors",
|
|
2189
|
-
children: [/* @__PURE__ */
|
|
2183
|
+
children: [/* @__PURE__ */ W(pe, { size: 12 }), u("devportal.exportManifest", "Export")]
|
|
2190
2184
|
}),
|
|
2191
|
-
/* @__PURE__ */
|
|
2185
|
+
/* @__PURE__ */ W("span", {
|
|
2192
2186
|
className: "text-xs text-text-secondary",
|
|
2193
2187
|
children: u("devportal.manifestTip", "— export to get a manifest.json to include inside your zip")
|
|
2194
2188
|
})
|
|
@@ -2197,44 +2191,44 @@ var Ye = q`
|
|
|
2197
2191
|
]
|
|
2198
2192
|
})
|
|
2199
2193
|
}),
|
|
2200
|
-
/* @__PURE__ */
|
|
2194
|
+
/* @__PURE__ */ W(b, {
|
|
2201
2195
|
title: u("devportal.storePresentation", "Store Presence"),
|
|
2202
2196
|
description: u("devportal.storePresentationDescription", "Visual assets and copy shown to users browsing the marketplace"),
|
|
2203
|
-
children: /* @__PURE__ */
|
|
2197
|
+
children: /* @__PURE__ */ G("div", {
|
|
2204
2198
|
className: "space-y-5",
|
|
2205
2199
|
children: [
|
|
2206
|
-
/* @__PURE__ */
|
|
2200
|
+
/* @__PURE__ */ G("div", {
|
|
2207
2201
|
className: "grid gap-5 sm:grid-cols-2",
|
|
2208
|
-
children: [/* @__PURE__ */
|
|
2202
|
+
children: [/* @__PURE__ */ W(Ue, {
|
|
2209
2203
|
label: u("devportal.iconUrl", "Icon"),
|
|
2210
2204
|
value: d.iconUrl,
|
|
2211
2205
|
onChange: (e) => O("iconUrl", e),
|
|
2212
2206
|
hint: u("devportal.iconUrlHint", "Square, 256×256 px recommended"),
|
|
2213
2207
|
aspectClass: "aspect-square",
|
|
2214
|
-
upload:
|
|
2215
|
-
uploading:
|
|
2216
|
-
progress:
|
|
2208
|
+
upload: me,
|
|
2209
|
+
uploading: L,
|
|
2210
|
+
progress: he,
|
|
2217
2211
|
error: _e
|
|
2218
|
-
}), /* @__PURE__ */
|
|
2212
|
+
}), /* @__PURE__ */ W(Ue, {
|
|
2219
2213
|
label: u("devportal.bannerUrl", "Banner"),
|
|
2220
2214
|
value: d.bannerUrl,
|
|
2221
2215
|
onChange: (e) => O("bannerUrl", e),
|
|
2222
2216
|
hint: u("devportal.bannerUrlHint", "1280×640 px recommended"),
|
|
2223
2217
|
aspectClass: "aspect-video",
|
|
2224
|
-
upload:
|
|
2225
|
-
uploading:
|
|
2218
|
+
upload: ve,
|
|
2219
|
+
uploading: z,
|
|
2226
2220
|
progress: ye,
|
|
2227
|
-
error:
|
|
2221
|
+
error: be
|
|
2228
2222
|
})]
|
|
2229
2223
|
}),
|
|
2230
|
-
/* @__PURE__ */
|
|
2224
|
+
/* @__PURE__ */ W(D, {
|
|
2231
2225
|
label: u("devportal.videoUrl", "Demo Video URL"),
|
|
2232
2226
|
value: d.videoUrl,
|
|
2233
2227
|
onChange: (e) => O("videoUrl", e.target.value),
|
|
2234
2228
|
placeholder: "https://...",
|
|
2235
2229
|
hint: u("devportal.videoUrlHint", "YouTube or Vimeo embed URL")
|
|
2236
2230
|
}),
|
|
2237
|
-
/* @__PURE__ */
|
|
2231
|
+
/* @__PURE__ */ W(ie, {
|
|
2238
2232
|
label: u("devportal.shortDescription", "Short Description"),
|
|
2239
2233
|
value: d.shortDescription,
|
|
2240
2234
|
onChange: (e) => O("shortDescription", e.target.value),
|
|
@@ -2242,62 +2236,62 @@ var Ye = q`
|
|
|
2242
2236
|
rows: 2,
|
|
2243
2237
|
hint: `${d.shortDescription.length}/200 · ${u("devportal.shortDescHint", "Shown in search results and cards")}`
|
|
2244
2238
|
}),
|
|
2245
|
-
/* @__PURE__ */
|
|
2239
|
+
/* @__PURE__ */ W(ie, {
|
|
2246
2240
|
label: u("devportal.longDescription", "Full Description"),
|
|
2247
2241
|
value: d.description,
|
|
2248
2242
|
onChange: (e) => O("description", e.target.value),
|
|
2249
2243
|
rows: 5,
|
|
2250
2244
|
hint: u("devportal.fullDescHint", "Markdown supported")
|
|
2251
2245
|
}),
|
|
2252
|
-
/* @__PURE__ */
|
|
2246
|
+
/* @__PURE__ */ W(We, {
|
|
2253
2247
|
urls: d.screenshotsText.split("\n").map((e) => e.trim()).filter(Boolean),
|
|
2254
2248
|
onChange: (e) => O("screenshotsText", e.join("\n")),
|
|
2255
|
-
upload:
|
|
2256
|
-
uploading:
|
|
2249
|
+
upload: B,
|
|
2250
|
+
uploading: H,
|
|
2257
2251
|
progress: Ce,
|
|
2258
2252
|
error: we
|
|
2259
2253
|
})
|
|
2260
2254
|
]
|
|
2261
2255
|
})
|
|
2262
2256
|
}),
|
|
2263
|
-
/* @__PURE__ */
|
|
2257
|
+
/* @__PURE__ */ W(b, {
|
|
2264
2258
|
title: u("devportal.linksPolicies", "Links & Policies"),
|
|
2265
2259
|
description: u("devportal.linksPoliciesDescription", "External resources and legal documents — privacy policy and terms are required for store submission"),
|
|
2266
|
-
children: /* @__PURE__ */
|
|
2260
|
+
children: /* @__PURE__ */ G("div", {
|
|
2267
2261
|
className: "grid gap-4 sm:grid-cols-2",
|
|
2268
2262
|
children: [
|
|
2269
|
-
/* @__PURE__ */
|
|
2263
|
+
/* @__PURE__ */ W(D, {
|
|
2270
2264
|
label: u("devportal.websiteUrl", "Website"),
|
|
2271
2265
|
value: d.websiteUrl,
|
|
2272
2266
|
onChange: (e) => O("websiteUrl", e.target.value),
|
|
2273
2267
|
placeholder: "https://..."
|
|
2274
2268
|
}),
|
|
2275
|
-
/* @__PURE__ */
|
|
2269
|
+
/* @__PURE__ */ W(D, {
|
|
2276
2270
|
label: u("devportal.documentationUrl", "Documentation"),
|
|
2277
2271
|
value: d.documentationUrl,
|
|
2278
2272
|
onChange: (e) => O("documentationUrl", e.target.value),
|
|
2279
2273
|
placeholder: "https://..."
|
|
2280
2274
|
}),
|
|
2281
|
-
/* @__PURE__ */
|
|
2275
|
+
/* @__PURE__ */ W(D, {
|
|
2282
2276
|
label: u("devportal.githubUrl", "GitHub"),
|
|
2283
2277
|
value: d.githubUrl,
|
|
2284
2278
|
onChange: (e) => O("githubUrl", e.target.value),
|
|
2285
2279
|
placeholder: "https://github.com/..."
|
|
2286
2280
|
}),
|
|
2287
|
-
/* @__PURE__ */
|
|
2281
|
+
/* @__PURE__ */ W(D, {
|
|
2288
2282
|
label: u("devportal.supportUrl", "Support"),
|
|
2289
2283
|
value: d.supportUrl,
|
|
2290
2284
|
onChange: (e) => O("supportUrl", e.target.value),
|
|
2291
2285
|
placeholder: "https://..."
|
|
2292
2286
|
}),
|
|
2293
|
-
/* @__PURE__ */
|
|
2287
|
+
/* @__PURE__ */ W(D, {
|
|
2294
2288
|
label: `${u("devportal.privacyPolicyUrl", "Privacy Policy")} *`,
|
|
2295
2289
|
value: d.privacyPolicyUrl,
|
|
2296
2290
|
onChange: (e) => O("privacyPolicyUrl", e.target.value),
|
|
2297
2291
|
placeholder: "https://...",
|
|
2298
2292
|
hint: u("devportal.requiredForStore", "Required for store submission")
|
|
2299
2293
|
}),
|
|
2300
|
-
/* @__PURE__ */
|
|
2294
|
+
/* @__PURE__ */ W(D, {
|
|
2301
2295
|
label: `${u("devportal.termsOfServiceUrl", "Terms of Service")} *`,
|
|
2302
2296
|
value: d.termsOfServiceUrl,
|
|
2303
2297
|
onChange: (e) => O("termsOfServiceUrl", e.target.value),
|
|
@@ -2307,31 +2301,31 @@ var Ye = q`
|
|
|
2307
2301
|
]
|
|
2308
2302
|
})
|
|
2309
2303
|
}),
|
|
2310
|
-
/* @__PURE__ */
|
|
2304
|
+
/* @__PURE__ */ W(b, {
|
|
2311
2305
|
title: u("devportal.pricing", "Pricing"),
|
|
2312
2306
|
description: u("devportal.pricingDescription", "How this item is priced in the marketplace"),
|
|
2313
|
-
children: /* @__PURE__ */
|
|
2307
|
+
children: /* @__PURE__ */ G("div", {
|
|
2314
2308
|
className: "space-y-4",
|
|
2315
|
-
children: [/* @__PURE__ */
|
|
2309
|
+
children: [/* @__PURE__ */ G("div", { children: [/* @__PURE__ */ W("label", {
|
|
2316
2310
|
className: "mb-2 block text-sm font-medium",
|
|
2317
2311
|
children: u("devportal.pricingType", "Pricing Type")
|
|
2318
|
-
}), /* @__PURE__ */
|
|
2312
|
+
}), /* @__PURE__ */ W("div", {
|
|
2319
2313
|
className: "flex flex-wrap gap-2",
|
|
2320
|
-
children: Ke.map((e) => /* @__PURE__ */
|
|
2314
|
+
children: Ke.map((e) => /* @__PURE__ */ W("button", {
|
|
2321
2315
|
type: "button",
|
|
2322
2316
|
onClick: () => O("pricingType", e.value),
|
|
2323
2317
|
className: t("rounded-md border px-3 py-1.5 text-sm font-medium transition-colors", d.pricingType === e.value ? "bg-primary text-primary-foreground border-primary" : "hover:bg-muted"),
|
|
2324
2318
|
children: e.label
|
|
2325
2319
|
}, e.value))
|
|
2326
|
-
})] }), Ae && /* @__PURE__ */
|
|
2320
|
+
})] }), Ae && /* @__PURE__ */ G("div", {
|
|
2327
2321
|
className: "grid gap-4 sm:grid-cols-2",
|
|
2328
|
-
children: [/* @__PURE__ */
|
|
2322
|
+
children: [/* @__PURE__ */ W(D, {
|
|
2329
2323
|
label: u("devportal.price", "Price"),
|
|
2330
2324
|
type: "number",
|
|
2331
2325
|
value: d.price,
|
|
2332
2326
|
onChange: (e) => O("price", e.target.value),
|
|
2333
2327
|
placeholder: "0.00"
|
|
2334
|
-
}), /* @__PURE__ */
|
|
2328
|
+
}), /* @__PURE__ */ W(D, {
|
|
2335
2329
|
label: u("devportal.currency", "Currency"),
|
|
2336
2330
|
value: d.currency,
|
|
2337
2331
|
onChange: (e) => O("currency", e.target.value),
|
|
@@ -2340,32 +2334,29 @@ var Ye = q`
|
|
|
2340
2334
|
})]
|
|
2341
2335
|
})
|
|
2342
2336
|
}),
|
|
2343
|
-
/* @__PURE__ */
|
|
2337
|
+
/* @__PURE__ */ G("div", {
|
|
2344
2338
|
className: "border-t pt-6 flex items-center gap-3 flex-wrap",
|
|
2345
2339
|
children: [
|
|
2346
|
-
/* @__PURE__ */
|
|
2340
|
+
/* @__PURE__ */ W("button", {
|
|
2347
2341
|
type: "button",
|
|
2348
2342
|
onClick: ae,
|
|
2349
2343
|
disabled: p,
|
|
2350
2344
|
className: "inline-flex items-center gap-2 rounded-md bg-primary px-4 py-2 text-sm font-medium text-primary-foreground hover:bg-primary/90 transition-colors disabled:opacity-50",
|
|
2351
|
-
children: p ? /* @__PURE__ */
|
|
2345
|
+
children: p ? /* @__PURE__ */ G(U, { children: [/* @__PURE__ */ W(R, {
|
|
2352
2346
|
size: 16,
|
|
2353
2347
|
className: "animate-spin"
|
|
2354
|
-
}), u("devportal.saving", "Saving…")] }) : /* @__PURE__ */
|
|
2348
|
+
}), u("devportal.saving", "Saving…")] }) : /* @__PURE__ */ G(U, { children: [/* @__PURE__ */ W(Se, { size: 16 }), u("devportal.saveMarketplaceListing", "Save Marketplace Listing")] })
|
|
2355
2349
|
}),
|
|
2356
|
-
!
|
|
2350
|
+
!Y && !Me && /* @__PURE__ */ G("button", {
|
|
2357
2351
|
type: "button",
|
|
2358
|
-
onClick: () =>
|
|
2359
|
-
disabled:
|
|
2352
|
+
onClick: () => s?.(`${c}/apps/${n.id}/publish`),
|
|
2353
|
+
disabled: p,
|
|
2360
2354
|
className: "inline-flex items-center gap-2 rounded-md border border-primary px-4 py-2 text-sm font-medium text-primary hover:bg-primary/5 transition-colors disabled:opacity-50",
|
|
2361
|
-
children:
|
|
2362
|
-
size: 16,
|
|
2363
|
-
className: "animate-spin"
|
|
2364
|
-
}), u("devportal.submitting", "Submitting…")] }) : /* @__PURE__ */ K(W, { children: [/* @__PURE__ */ G(be, { size: 16 }), u("devportal.submitForReview", "Submit for Review")] })
|
|
2355
|
+
children: [/* @__PURE__ */ W(xe, { size: 16 }), u("devportal.submitForReview", "Submit for Review")]
|
|
2365
2356
|
}),
|
|
2366
|
-
!
|
|
2357
|
+
!Y && Me && /* @__PURE__ */ G("p", {
|
|
2367
2358
|
className: "text-xs text-muted-foreground flex items-center gap-1.5",
|
|
2368
|
-
children: [/* @__PURE__ */
|
|
2359
|
+
children: [/* @__PURE__ */ W(fe, { size: 12 }), u("devportal.awaitingReview", "Your listing is under review. You can still update and save — changes take effect after approval.")]
|
|
2369
2360
|
})
|
|
2370
2361
|
]
|
|
2371
2362
|
})
|
|
@@ -2373,18 +2364,18 @@ var Ye = q`
|
|
|
2373
2364
|
});
|
|
2374
2365
|
}, Q = ({ label: e, value: n, trend: r }) => {
|
|
2375
2366
|
let { t: i } = P();
|
|
2376
|
-
return /* @__PURE__ */
|
|
2367
|
+
return /* @__PURE__ */ G("div", {
|
|
2377
2368
|
className: "rounded-lg border bg-card p-4",
|
|
2378
2369
|
children: [
|
|
2379
|
-
/* @__PURE__ */
|
|
2370
|
+
/* @__PURE__ */ W("p", {
|
|
2380
2371
|
className: "text-sm text-muted-foreground",
|
|
2381
2372
|
children: e
|
|
2382
2373
|
}),
|
|
2383
|
-
/* @__PURE__ */
|
|
2374
|
+
/* @__PURE__ */ W("p", {
|
|
2384
2375
|
className: "text-2xl font-bold",
|
|
2385
2376
|
children: n
|
|
2386
2377
|
}),
|
|
2387
|
-
r !== void 0 && /* @__PURE__ */
|
|
2378
|
+
r !== void 0 && /* @__PURE__ */ G("p", {
|
|
2388
2379
|
className: t("text-xs mt-1", r > 0 ? "text-status-success-text" : r < 0 ? "text-status-error-text" : "text-muted-foreground"),
|
|
2389
2380
|
children: [
|
|
2390
2381
|
r > 0 ? "+" : "",
|
|
@@ -2398,12 +2389,12 @@ var Ye = q`
|
|
|
2398
2389
|
})
|
|
2399
2390
|
]
|
|
2400
2391
|
});
|
|
2401
|
-
}, $ = ({ label: e, url: t }) => /* @__PURE__ */
|
|
2392
|
+
}, $ = ({ label: e, url: t }) => /* @__PURE__ */ G("a", {
|
|
2402
2393
|
href: t,
|
|
2403
2394
|
target: "_blank",
|
|
2404
2395
|
rel: "noopener noreferrer",
|
|
2405
2396
|
className: "flex items-center gap-2 text-sm text-primary hover:underline",
|
|
2406
|
-
children: [/* @__PURE__ */
|
|
2397
|
+
children: [/* @__PURE__ */ W(L, { size: 14 }), e]
|
|
2407
2398
|
}), $e = [
|
|
2408
2399
|
{
|
|
2409
2400
|
id: "auth",
|
|
@@ -2514,41 +2505,41 @@ var tt = ({ app: e }) => {
|
|
|
2514
2505
|
"read",
|
|
2515
2506
|
"write"
|
|
2516
2507
|
];
|
|
2517
|
-
return /* @__PURE__ */
|
|
2508
|
+
return /* @__PURE__ */ W(b, {
|
|
2518
2509
|
title: "Permissions",
|
|
2519
2510
|
description: "Define what platform data this app can request access to. Users see these when authorizing the app.",
|
|
2520
|
-
children: /* @__PURE__ */
|
|
2511
|
+
children: /* @__PURE__ */ G("div", {
|
|
2521
2512
|
className: "space-y-4",
|
|
2522
2513
|
children: [
|
|
2523
|
-
/* @__PURE__ */
|
|
2514
|
+
/* @__PURE__ */ W("div", {
|
|
2524
2515
|
className: "overflow-x-auto rounded-lg border border-border",
|
|
2525
|
-
children: /* @__PURE__ */
|
|
2516
|
+
children: /* @__PURE__ */ G("table", {
|
|
2526
2517
|
className: "w-full text-sm",
|
|
2527
|
-
children: [/* @__PURE__ */
|
|
2518
|
+
children: [/* @__PURE__ */ W("thead", { children: /* @__PURE__ */ G("tr", {
|
|
2528
2519
|
className: "border-b border-border bg-muted/50",
|
|
2529
|
-
children: [/* @__PURE__ */
|
|
2520
|
+
children: [/* @__PURE__ */ W("th", {
|
|
2530
2521
|
className: "px-4 py-3 text-left font-medium text-muted-foreground w-1/2",
|
|
2531
2522
|
children: "Resource"
|
|
2532
|
-
}), f.map((e) => /* @__PURE__ */
|
|
2523
|
+
}), f.map((e) => /* @__PURE__ */ W("th", {
|
|
2533
2524
|
className: "px-4 py-3 text-center font-medium text-muted-foreground",
|
|
2534
2525
|
children: d[e]
|
|
2535
2526
|
}, e))]
|
|
2536
|
-
}) }), /* @__PURE__ */
|
|
2527
|
+
}) }), /* @__PURE__ */ W("tbody", {
|
|
2537
2528
|
className: "divide-y divide-border",
|
|
2538
|
-
children: $e.map((e) => /* @__PURE__ */
|
|
2529
|
+
children: $e.map((e) => /* @__PURE__ */ G("tr", {
|
|
2539
2530
|
className: "hover:bg-muted/30 transition-colors",
|
|
2540
|
-
children: [/* @__PURE__ */
|
|
2531
|
+
children: [/* @__PURE__ */ G("td", {
|
|
2541
2532
|
className: "px-4 py-3",
|
|
2542
|
-
children: [/* @__PURE__ */
|
|
2533
|
+
children: [/* @__PURE__ */ W("p", {
|
|
2543
2534
|
className: "font-medium text-foreground",
|
|
2544
2535
|
children: e.label
|
|
2545
|
-
}), /* @__PURE__ */
|
|
2536
|
+
}), /* @__PURE__ */ W("p", {
|
|
2546
2537
|
className: "text-xs text-muted-foreground",
|
|
2547
2538
|
children: e.description
|
|
2548
2539
|
})]
|
|
2549
|
-
}), f.map((t) => /* @__PURE__ */
|
|
2540
|
+
}), f.map((t) => /* @__PURE__ */ W("td", {
|
|
2550
2541
|
className: "px-4 py-3 text-center",
|
|
2551
|
-
children: /* @__PURE__ */
|
|
2542
|
+
children: /* @__PURE__ */ W("input", {
|
|
2552
2543
|
type: "radio",
|
|
2553
2544
|
name: `perm-${e.id}`,
|
|
2554
2545
|
value: t,
|
|
@@ -2561,27 +2552,27 @@ var tt = ({ app: e }) => {
|
|
|
2561
2552
|
})]
|
|
2562
2553
|
})
|
|
2563
2554
|
}),
|
|
2564
|
-
/* @__PURE__ */
|
|
2555
|
+
/* @__PURE__ */ G("div", {
|
|
2565
2556
|
className: "rounded-lg border border-border-subtle bg-muted/30 p-3 flex gap-2 text-xs text-muted-foreground",
|
|
2566
|
-
children: [/* @__PURE__ */
|
|
2557
|
+
children: [/* @__PURE__ */ W(ge, {
|
|
2567
2558
|
size: 14,
|
|
2568
2559
|
className: "flex-shrink-0 mt-0.5"
|
|
2569
|
-
}), /* @__PURE__ */
|
|
2560
|
+
}), /* @__PURE__ */ G("span", { children: [/* @__PURE__ */ W("strong", { children: "Read & Write" }), " implies Read. Request only what your app genuinely needs — fewer permissions build more user trust."] })]
|
|
2570
2561
|
}),
|
|
2571
|
-
/* @__PURE__ */
|
|
2562
|
+
/* @__PURE__ */ G("div", {
|
|
2572
2563
|
className: "flex items-center justify-end gap-3",
|
|
2573
|
-
children: [o && /* @__PURE__ */
|
|
2564
|
+
children: [o && /* @__PURE__ */ G("span", {
|
|
2574
2565
|
className: "flex items-center gap-1.5 text-sm text-status-success-text",
|
|
2575
|
-
children: [/* @__PURE__ */
|
|
2576
|
-
}), /* @__PURE__ */
|
|
2566
|
+
children: [/* @__PURE__ */ W(I, { size: 14 }), "Saved"]
|
|
2567
|
+
}), /* @__PURE__ */ G("button", {
|
|
2577
2568
|
type: "button",
|
|
2578
2569
|
onClick: () => void u(),
|
|
2579
2570
|
disabled: i,
|
|
2580
2571
|
className: "inline-flex items-center gap-2 rounded-md bg-primary px-4 py-2 text-sm font-medium text-primary-foreground hover:bg-primary/90 transition-colors disabled:opacity-50",
|
|
2581
|
-
children: [i ? /* @__PURE__ */
|
|
2572
|
+
children: [i ? /* @__PURE__ */ W(R, {
|
|
2582
2573
|
size: 14,
|
|
2583
2574
|
className: "animate-spin"
|
|
2584
|
-
}) : /* @__PURE__ */
|
|
2575
|
+
}) : /* @__PURE__ */ W(B, { size: 14 }), "Save Permissions"]
|
|
2585
2576
|
})]
|
|
2586
2577
|
})
|
|
2587
2578
|
]
|