@burdenoff/microfe-devportal 2026.720.6 → 2026.724.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/devportal/components/ConfirmDialog.d.ts.map +1 -1
- package/dist/devportal/components/ConfirmDialog.js +12 -14
- package/dist/devportal/components/ConfirmDialog.js.map +1 -1
- package/dist/devportal/components/MarkdownEditor.d.ts +24 -0
- package/dist/devportal/components/MarkdownEditor.d.ts.map +1 -0
- package/dist/devportal/components/MarkdownEditor.js +136 -0
- package/dist/devportal/components/MarkdownEditor.js.map +1 -0
- package/dist/devportal/components/index.d.ts +1 -0
- package/dist/devportal/components/index.d.ts.map +1 -1
- package/dist/devportal/components/index.js +1 -0
- package/dist/devportal/pages/ApplicationDetailPage.d.ts.map +1 -1
- package/dist/devportal/pages/ApplicationDetailPage.js +749 -747
- package/dist/devportal/pages/ApplicationDetailPage.js.map +1 -1
- package/dist/devportal/pages/ApplicationVersionsPage.d.ts.map +1 -1
- package/dist/devportal/pages/ApplicationVersionsPage.js +390 -374
- package/dist/devportal/pages/ApplicationVersionsPage.js.map +1 -1
- package/dist/devportal/pages/CreateApplicationPage.d.ts.map +1 -1
- package/dist/devportal/pages/CreateApplicationPage.js +11 -9
- package/dist/devportal/pages/CreateApplicationPage.js.map +1 -1
- package/dist/devportal/pages/EditApplicationPage.d.ts.map +1 -1
- package/dist/devportal/pages/EditApplicationPage.js +284 -283
- package/dist/devportal/pages/EditApplicationPage.js.map +1 -1
- package/dist/devportal/pages/ListingPreviewPage.d.ts.map +1 -1
- package/dist/devportal/pages/ListingPreviewPage.js +162 -158
- package/dist/devportal/pages/ListingPreviewPage.js.map +1 -1
- package/package.json +2 -2
|
@@ -13,17 +13,19 @@ import { DataTable as te, DetailList as ne } from "../components/DataTable.js";
|
|
|
13
13
|
import { InputField as k, SelectField as re, TextareaField as ie } from "../components/FormField.js";
|
|
14
14
|
import { ConfirmDialog as ae } from "../components/ConfirmDialog.js";
|
|
15
15
|
import { GrantDelegationModal as oe } from "../components/GrantDelegationModal.js";
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
16
|
+
import { MarkdownEditor as se } from "../components/MarkdownEditor.js";
|
|
17
|
+
import { useDevportalPermission as ce } from "../hooks/usePermission.js";
|
|
18
|
+
import { DEVPORTAL_PERMISSIONS as le } from "../constants/permissions.js";
|
|
19
|
+
import { usePackageUpload as ue } from "../hooks/usePackageUpload.js";
|
|
20
|
+
import { useCallback as A, useEffect as de, useMemo as j, useRef as M, useState as N } from "react";
|
|
21
|
+
import { Markdown as fe } from "@burdenoff/fe-libs/shared/components";
|
|
20
22
|
import { useI18n as P } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
21
|
-
import { AlertCircle as
|
|
22
|
-
import { useParams as
|
|
23
|
-
import { Fragment as
|
|
24
|
-
import { CTAOverflowMenu as
|
|
23
|
+
import { AlertCircle as pe, AppWindow as me, BarChart3 as he, Check as F, CheckCircle as ge, ChevronRight as _e, CircleDollarSign as I, Clock as ve, Copy as ye, Edit as be, ExternalLink as L, FlaskConical as xe, Gift as Se, Info as Ce, Key as we, Link as Te, Loader2 as R, Lock as Ee, MoreHorizontal as De, Package as Oe, Plus as ke, Power as Ae, RefreshCw as je, SendHorizontal as Me, Shield as z, Store as Ne, TrendingUp as Pe, Upload as B, Users as Fe, Wallet as V, Webhook as Ie, X as Le, XCircle as Re } from "lucide-react";
|
|
24
|
+
import { useParams as ze } from "react-router-dom";
|
|
25
|
+
import { Fragment as H, jsx as U, jsxs as W } from "react/jsx-runtime";
|
|
26
|
+
import { CTAOverflowMenu as Be, EmphasisPanel as Ve, GlassCard as He } from "@burdenoff/fe-libs/ui";
|
|
25
27
|
//#region src/devportal/pages/ApplicationDetailPage.tsx
|
|
26
|
-
function
|
|
28
|
+
function Ue(e) {
|
|
27
29
|
return e ? {
|
|
28
30
|
id: e.id,
|
|
29
31
|
name: e.name,
|
|
@@ -77,7 +79,7 @@ function ze(e) {
|
|
|
77
79
|
updatedAt: e.updatedAt
|
|
78
80
|
} : null;
|
|
79
81
|
}
|
|
80
|
-
function
|
|
82
|
+
function We(e) {
|
|
81
83
|
return {
|
|
82
84
|
id: e.id,
|
|
83
85
|
applicationId: e.applicationId,
|
|
@@ -101,7 +103,7 @@ function Be(e) {
|
|
|
101
103
|
updatedAt: e.updatedAt
|
|
102
104
|
};
|
|
103
105
|
}
|
|
104
|
-
function
|
|
106
|
+
function G(e) {
|
|
105
107
|
return {
|
|
106
108
|
id: e.id,
|
|
107
109
|
applicationId: e.applicationId,
|
|
@@ -117,7 +119,7 @@ function Ve(e) {
|
|
|
117
119
|
createdAt: e.createdAt
|
|
118
120
|
};
|
|
119
121
|
}
|
|
120
|
-
function
|
|
122
|
+
function K(e) {
|
|
121
123
|
return {
|
|
122
124
|
id: e.id,
|
|
123
125
|
appId: e.appId,
|
|
@@ -139,26 +141,26 @@ function He(e) {
|
|
|
139
141
|
revokedBy: e.revokedBy || void 0
|
|
140
142
|
};
|
|
141
143
|
}
|
|
142
|
-
var
|
|
144
|
+
var Ge = [
|
|
143
145
|
{
|
|
144
146
|
id: "overview",
|
|
145
147
|
label: "Overview",
|
|
146
|
-
icon:
|
|
148
|
+
icon: me
|
|
147
149
|
},
|
|
148
150
|
{
|
|
149
151
|
id: "analytics",
|
|
150
152
|
label: "Analytics",
|
|
151
|
-
icon:
|
|
153
|
+
icon: he
|
|
152
154
|
},
|
|
153
155
|
{
|
|
154
156
|
id: "store-listing",
|
|
155
157
|
label: "Store Listing",
|
|
156
|
-
icon:
|
|
158
|
+
icon: Ne
|
|
157
159
|
},
|
|
158
160
|
{
|
|
159
161
|
id: "versions",
|
|
160
162
|
label: "Versions",
|
|
161
|
-
icon:
|
|
163
|
+
icon: Oe
|
|
162
164
|
},
|
|
163
165
|
{
|
|
164
166
|
id: "pricing",
|
|
@@ -168,17 +170,17 @@ var Ue = [
|
|
|
168
170
|
{
|
|
169
171
|
id: "permissions",
|
|
170
172
|
label: "Permissions",
|
|
171
|
-
icon:
|
|
173
|
+
icon: z
|
|
172
174
|
},
|
|
173
175
|
{
|
|
174
176
|
id: "webhooks",
|
|
175
177
|
label: "Webhooks",
|
|
176
|
-
icon:
|
|
178
|
+
icon: Ie
|
|
177
179
|
},
|
|
178
180
|
{
|
|
179
181
|
id: "delegations",
|
|
180
182
|
label: "Delegations",
|
|
181
|
-
icon:
|
|
183
|
+
icon: Fe
|
|
182
184
|
},
|
|
183
185
|
{
|
|
184
186
|
id: "playground",
|
|
@@ -188,77 +190,77 @@ var Ue = [
|
|
|
188
190
|
{
|
|
189
191
|
id: "oauth",
|
|
190
192
|
label: "OAuth",
|
|
191
|
-
icon:
|
|
193
|
+
icon: Ee
|
|
192
194
|
},
|
|
193
195
|
{
|
|
194
196
|
id: "api-keys",
|
|
195
197
|
label: "API Keys",
|
|
196
|
-
icon:
|
|
198
|
+
icon: we
|
|
197
199
|
}
|
|
198
200
|
], q = {
|
|
199
201
|
ACTIVE: "bg-status-success-bg-subtle text-status-success-text",
|
|
200
202
|
REVOKED: "bg-status-error-bg-subtle text-status-error-text",
|
|
201
203
|
EXPIRED: "bg-bg-sunken text-text-secondary"
|
|
202
|
-
}, J = ({ message: e = "Loading..." }) => /* @__PURE__ */
|
|
204
|
+
}, J = ({ message: e = "Loading..." }) => /* @__PURE__ */ W("div", {
|
|
203
205
|
className: "flex items-center justify-center gap-3 py-12",
|
|
204
|
-
children: [/* @__PURE__ */
|
|
206
|
+
children: [/* @__PURE__ */ U(R, {
|
|
205
207
|
size: 20,
|
|
206
208
|
className: "animate-spin text-text-secondary"
|
|
207
|
-
}), /* @__PURE__ */
|
|
209
|
+
}), /* @__PURE__ */ U("p", {
|
|
208
210
|
className: "text-sm text-text-secondary",
|
|
209
211
|
children: e
|
|
210
212
|
})]
|
|
211
|
-
}), Y = ({ message: e }) => /* @__PURE__ */
|
|
213
|
+
}), Y = ({ message: e }) => /* @__PURE__ */ W("div", {
|
|
212
214
|
className: "flex flex-col items-center justify-center gap-2 py-12 text-center",
|
|
213
|
-
children: [/* @__PURE__ */
|
|
215
|
+
children: [/* @__PURE__ */ U(pe, {
|
|
214
216
|
size: 32,
|
|
215
217
|
className: "text-status-error-text"
|
|
216
|
-
}), /* @__PURE__ */
|
|
218
|
+
}), /* @__PURE__ */ U("p", {
|
|
217
219
|
className: "text-sm text-text-secondary",
|
|
218
220
|
children: e
|
|
219
221
|
})]
|
|
220
|
-
}),
|
|
222
|
+
}), Ke = () => {
|
|
221
223
|
let { navigate: i, basePath: o, workspaceId: c } = e(), { t: u } = P(), m = (e, t) => {
|
|
222
224
|
let n = u(e);
|
|
223
225
|
return n === e ? t : n;
|
|
224
|
-
}, { allowed: g } =
|
|
226
|
+
}, { allowed: g } = ce(le.APP_UPDATE), { allowed: y } = ce(le.APP_DELETE), { appId: b } = ze(), [S, D] = N("overview"), [te, ne] = N(!1), [k, re] = N(!1), [ie, se] = N(null), [ue, de] = N(!1), { data: j, loading: M, error: fe, refetch: he } = s({
|
|
225
227
|
variables: { id: b },
|
|
226
228
|
skip: !b
|
|
227
|
-
}), [
|
|
229
|
+
}), [I, { loading: ye }] = h(), [L, { loading: Se }] = a(), [Ce, { loading: we }] = _(), [Te] = p(), [Ee, { loading: De }] = f(), [Oe, { loading: ke }] = v(), { data: z, refetch: Pe } = d({
|
|
228
230
|
variables: {
|
|
229
231
|
applicationId: b,
|
|
230
232
|
workspaceId: c ?? void 0
|
|
231
233
|
},
|
|
232
234
|
skip: !c || !b,
|
|
233
235
|
fetchPolicy: "cache-and-network"
|
|
234
|
-
}),
|
|
235
|
-
variables: { id:
|
|
236
|
-
skip: !
|
|
236
|
+
}), B = z?.appInstallations?.edges?.[0]?.node ?? null, { data: Fe } = l({
|
|
237
|
+
variables: { id: j?.application?.developerOrganizationId ?? "" },
|
|
238
|
+
skip: !j?.application?.developerOrganizationId,
|
|
237
239
|
fetchPolicy: "cache-first"
|
|
238
|
-
}),
|
|
240
|
+
}), V = A((e) => {
|
|
239
241
|
i?.(`${o}${e}`);
|
|
240
|
-
}, [i, o]),
|
|
241
|
-
let e =
|
|
242
|
+
}, [i, o]), Ie = A(async () => {
|
|
243
|
+
let e = j?.application?.appId;
|
|
242
244
|
if (e) try {
|
|
243
|
-
let t = (await
|
|
244
|
-
t &&
|
|
245
|
+
let t = (await I({ variables: { id: e } })).data?.rotateAppSecret.clientSecret;
|
|
246
|
+
t && se(t), ne(!1);
|
|
245
247
|
} catch {}
|
|
246
|
-
}, [
|
|
248
|
+
}, [j?.application?.appId, I]), Le = A(async () => {
|
|
247
249
|
if (b) try {
|
|
248
|
-
await
|
|
250
|
+
await L({ variables: { id: b } }), re(!1), V("/apps");
|
|
249
251
|
} catch {}
|
|
250
252
|
}, [
|
|
251
253
|
b,
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
]),
|
|
254
|
+
L,
|
|
255
|
+
V
|
|
256
|
+
]), Ve = A(async () => {
|
|
255
257
|
if (!(!b || !c)) try {
|
|
256
258
|
await Ee({ variables: { input: {
|
|
257
259
|
applicationId: b,
|
|
258
260
|
scope: "WORKSPACE",
|
|
259
261
|
workspaceId: c,
|
|
260
262
|
autoUpdate: !1
|
|
261
|
-
} } }),
|
|
263
|
+
} } }), Pe(), O("success");
|
|
262
264
|
} catch (e) {
|
|
263
265
|
console.error("[DevPortal] Test in Workspace failed:", e), O("error");
|
|
264
266
|
}
|
|
@@ -266,256 +268,256 @@ var Ue = [
|
|
|
266
268
|
b,
|
|
267
269
|
c,
|
|
268
270
|
Ee,
|
|
269
|
-
|
|
270
|
-
]),
|
|
271
|
+
Pe
|
|
272
|
+
]), He = A(async (e) => {
|
|
271
273
|
try {
|
|
272
|
-
await
|
|
274
|
+
await Oe({ variables: { id: e } }), Pe(), O("success");
|
|
273
275
|
} catch {
|
|
274
276
|
O("error");
|
|
275
277
|
}
|
|
276
|
-
}, [
|
|
278
|
+
}, [Oe, Pe]), We = A(async () => {
|
|
277
279
|
if (b) try {
|
|
278
|
-
let e = (
|
|
280
|
+
let e = (j?.application?.versions?.edges ?? []).map((e) => e.node).filter((e) => e.status === "draft");
|
|
279
281
|
for (let t of e) await Te({ variables: { id: t.id } });
|
|
280
282
|
await Ce({ variables: { id: b } }), O("success");
|
|
281
283
|
} catch (e) {
|
|
282
284
|
console.error("[DevPortal] Submit failed:", e), O("error");
|
|
283
285
|
} finally {
|
|
284
|
-
|
|
286
|
+
he();
|
|
285
287
|
}
|
|
286
288
|
}, [
|
|
287
289
|
b,
|
|
288
|
-
|
|
290
|
+
j?.application?.versions?.edges,
|
|
289
291
|
Te,
|
|
290
292
|
Ce,
|
|
291
|
-
|
|
293
|
+
he
|
|
292
294
|
]);
|
|
293
|
-
if (
|
|
294
|
-
if (
|
|
295
|
+
if (M && !j) return /* @__PURE__ */ U(n, { message: m("devportal.loadingApplication", "Loading application...") });
|
|
296
|
+
if (fe) return /* @__PURE__ */ U(x, {
|
|
295
297
|
title: m("devportal.error", "Error"),
|
|
296
298
|
backLink: `${o}/apps`,
|
|
297
299
|
backLabel: m("devportal.backToApplications", "Back to Applications"),
|
|
298
|
-
children: /* @__PURE__ */
|
|
300
|
+
children: /* @__PURE__ */ W("div", {
|
|
299
301
|
className: "flex flex-col items-center justify-center py-12 text-center",
|
|
300
302
|
children: [
|
|
301
|
-
/* @__PURE__ */
|
|
303
|
+
/* @__PURE__ */ U(pe, {
|
|
302
304
|
size: 48,
|
|
303
305
|
className: "text-status-error-text mb-4"
|
|
304
306
|
}),
|
|
305
|
-
/* @__PURE__ */
|
|
307
|
+
/* @__PURE__ */ U("h3", {
|
|
306
308
|
className: "text-lg font-semibold mb-2",
|
|
307
309
|
children: m("devportal.failedToLoadApplication", "Failed to load application")
|
|
308
310
|
}),
|
|
309
|
-
/* @__PURE__ */
|
|
311
|
+
/* @__PURE__ */ U("p", {
|
|
310
312
|
className: "text-sm text-text-secondary",
|
|
311
|
-
children:
|
|
313
|
+
children: fe.message
|
|
312
314
|
})
|
|
313
315
|
]
|
|
314
316
|
})
|
|
315
317
|
});
|
|
316
|
-
let
|
|
317
|
-
if (!
|
|
318
|
+
let G = Ue(j?.application);
|
|
319
|
+
if (!G) return /* @__PURE__ */ U(x, {
|
|
318
320
|
title: m("devportal.notFound", "Not Found"),
|
|
319
321
|
backLink: `${o}/apps`,
|
|
320
322
|
backLabel: m("devportal.backToApplications", "Back to Applications"),
|
|
321
|
-
children: /* @__PURE__ */
|
|
323
|
+
children: /* @__PURE__ */ U(r, {
|
|
322
324
|
illustration: "empty-generic",
|
|
323
|
-
icon: /* @__PURE__ */
|
|
325
|
+
icon: /* @__PURE__ */ U(me, { size: 48 }),
|
|
324
326
|
title: m("devportal.applicationNotFound", "Application not found"),
|
|
325
327
|
description: m("devportal.applicationNotFoundDescription", "The application you're looking for doesn't exist or you don't have access to it.")
|
|
326
328
|
})
|
|
327
329
|
});
|
|
328
|
-
let
|
|
329
|
-
...
|
|
330
|
+
let K = G.appType === "NODE" || G.appType === "WORKFLOW", q = G.appType === "API_INTEGRATION", J = j?.application?.versions?.totalCount ?? 0, Y = G.pricingType === "PAID", Ke = Fe?.developerOrganization, Ye = Ke?.platformFeeRate ?? .3, X = !!Ke?.billingAccountId, Xe = G.pricingDetails ?? {}, Z = G.pricingType === "FREE" || G.pricingType === "PAID" && typeof Xe.price == "number" && Xe.price > 0, rt = !!G.description?.trim() && !!G.category && !!G.iconUrl && (G.visibility === "PUBLIC" || G.visibility === "UNLISTED") && (!K && !q || J > 0) && (!Y || X) && Z, it = rt && G.status !== "PUBLISHED" && G.status !== "SUBMITTED" && G.status !== "INACTIVE" && G.status !== "REVOKED", at = [
|
|
331
|
+
...K ? [] : [{
|
|
330
332
|
label: m("devportal.rotateSecret", "Rotate Secret"),
|
|
331
|
-
icon: /* @__PURE__ */
|
|
332
|
-
disabled: !
|
|
333
|
+
icon: /* @__PURE__ */ U(je, { size: 16 }),
|
|
334
|
+
disabled: !G.appId,
|
|
333
335
|
onSelect: () => ne(!0)
|
|
334
336
|
}],
|
|
335
|
-
...
|
|
337
|
+
...K ? [] : B ? [{
|
|
336
338
|
label: m("devportal.uninstallFromWorkspace", "Uninstall from Workspace"),
|
|
337
|
-
icon: /* @__PURE__ */
|
|
338
|
-
disabled:
|
|
339
|
-
onSelect: () => void
|
|
339
|
+
icon: /* @__PURE__ */ U(Re, { size: 16 }),
|
|
340
|
+
disabled: ke || !c,
|
|
341
|
+
onSelect: () => void He(B.id)
|
|
340
342
|
}] : [{
|
|
341
343
|
label: m("devportal.testInWorkspace", "Test in Workspace"),
|
|
342
|
-
icon: /* @__PURE__ */
|
|
343
|
-
disabled:
|
|
344
|
-
onSelect: () => void
|
|
344
|
+
icon: /* @__PURE__ */ U(xe, { size: 16 }),
|
|
345
|
+
disabled: De || !c,
|
|
346
|
+
onSelect: () => void Ve()
|
|
345
347
|
}],
|
|
346
348
|
{
|
|
347
349
|
label: m("devportal.deactivate", "Deactivate"),
|
|
348
|
-
icon: /* @__PURE__ */
|
|
350
|
+
icon: /* @__PURE__ */ U(Ae, { size: 16 }),
|
|
349
351
|
intent: "destructive",
|
|
350
352
|
disabled: !y,
|
|
351
353
|
onSelect: () => re(!0)
|
|
352
354
|
}
|
|
353
355
|
];
|
|
354
|
-
return /* @__PURE__ */
|
|
355
|
-
title:
|
|
356
|
-
description:
|
|
356
|
+
return /* @__PURE__ */ W(x, {
|
|
357
|
+
title: G.name,
|
|
358
|
+
description: G.shortDescription,
|
|
357
359
|
purpose: m("devportal.appDetailPurpose", "Everything about this application in one place — its credentials, the permissions and webhooks it uses, its analytics, and its store listing. Use the tabs to configure each area, then edit or publish when it is ready."),
|
|
358
360
|
backLink: `${o}/apps`,
|
|
359
361
|
backLabel: m("devportal.backToApplications", "Back to Applications"),
|
|
360
|
-
actions: /* @__PURE__ */
|
|
362
|
+
actions: /* @__PURE__ */ W("div", {
|
|
361
363
|
className: "flex items-center gap-2",
|
|
362
|
-
children: [
|
|
364
|
+
children: [G.status === "SUBMITTED" ? /* @__PURE__ */ W("div", {
|
|
363
365
|
className: "flex items-center gap-1.5 rounded-full border border-status-warning-bg bg-status-warning-bg-subtle px-3 py-1.5 text-xs font-medium text-status-warning-text",
|
|
364
|
-
children: [/* @__PURE__ */
|
|
365
|
-
}) :
|
|
366
|
+
children: [/* @__PURE__ */ U(ve, { size: 13 }), m("devportal.underReview", "Under Review")]
|
|
367
|
+
}) : G.status !== "PUBLISHED" && G.status !== "INACTIVE" && G.status !== "REVOKED" ? /* @__PURE__ */ U("button", {
|
|
366
368
|
type: "button",
|
|
367
|
-
onClick: () => void
|
|
369
|
+
onClick: () => void We(),
|
|
368
370
|
disabled: !it || we,
|
|
369
|
-
title:
|
|
370
|
-
!
|
|
371
|
-
!
|
|
372
|
-
!
|
|
373
|
-
(
|
|
374
|
-
|
|
375
|
-
!
|
|
376
|
-
|
|
371
|
+
title: rt ? void 0 : [
|
|
372
|
+
!G.description?.trim() && "Add full description",
|
|
373
|
+
!G.category && "Select a category",
|
|
374
|
+
!G.iconUrl && "Upload an app icon",
|
|
375
|
+
(G.visibility === "PRIVATE" || G.visibility === "INTERNAL") && "Set visibility to Public (marketplace) or Unlisted (link sharing) — Private and Internal cannot be submitted for review",
|
|
376
|
+
K && J === 0 && "Upload at least one version",
|
|
377
|
+
!Z && "Set pricing (choose Free or Paid in the Pricing tab)",
|
|
378
|
+
Y && !X && "Link a billing account to receive payments"
|
|
377
379
|
].filter(Boolean).join(" · "),
|
|
378
380
|
className: t("inline-flex items-center gap-2 rounded-md px-5 py-2 text-sm font-medium whitespace-nowrap transition-colors", it && !we ? "bg-action-primary-bg text-action-primary-text hover:bg-action-primary-bg/90 cursor-pointer" : "cursor-not-allowed bg-bg-muted text-text-tertiary ring-1 ring-border-subtle"),
|
|
379
|
-
children: we ? /* @__PURE__ */
|
|
381
|
+
children: we ? /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(R, {
|
|
380
382
|
size: 15,
|
|
381
383
|
className: "animate-spin"
|
|
382
|
-
}), m("devportal.submitting", "Submitting…")] }) : /* @__PURE__ */
|
|
383
|
-
}) : null, /* @__PURE__ */
|
|
384
|
+
}), m("devportal.submitting", "Submitting…")] }) : /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(Me, { size: 15 }), m("devportal.submitForReview", "Submit for Review")] })
|
|
385
|
+
}) : null, /* @__PURE__ */ U(Be, {
|
|
384
386
|
primary: {
|
|
385
387
|
label: m("devportal.editApp", "Edit App"),
|
|
386
|
-
icon: /* @__PURE__ */
|
|
388
|
+
icon: /* @__PURE__ */ U(be, { size: 16 }),
|
|
387
389
|
disabled: !g,
|
|
388
|
-
onSelect: () =>
|
|
390
|
+
onSelect: () => V(`/apps/${G.id}/edit`)
|
|
389
391
|
},
|
|
390
392
|
actions: at
|
|
391
393
|
})]
|
|
392
394
|
}),
|
|
393
395
|
children: [
|
|
394
|
-
ie && /* @__PURE__ */
|
|
396
|
+
ie && /* @__PURE__ */ U(ee, {
|
|
395
397
|
title: m("devportal.newAppSecretGenerated", "New App Secret Generated"),
|
|
396
398
|
secret: ie,
|
|
397
399
|
description: m("devportal.appSecretRotatedDescription", "Your app secret has been rotated. The old secret is no longer valid."),
|
|
398
|
-
onDismiss: () =>
|
|
400
|
+
onDismiss: () => se(null)
|
|
399
401
|
}),
|
|
400
|
-
/* @__PURE__ */
|
|
402
|
+
/* @__PURE__ */ W("div", {
|
|
401
403
|
className: "flex flex-wrap items-center gap-2",
|
|
402
404
|
children: [
|
|
403
|
-
/* @__PURE__ */
|
|
404
|
-
status:
|
|
405
|
+
/* @__PURE__ */ U(T, {
|
|
406
|
+
status: G.status,
|
|
405
407
|
type: "app"
|
|
406
408
|
}),
|
|
407
|
-
/* @__PURE__ */
|
|
408
|
-
title:
|
|
409
|
-
children: /* @__PURE__ */
|
|
410
|
-
status:
|
|
409
|
+
/* @__PURE__ */ U("span", {
|
|
410
|
+
title: G.visibility === "PUBLIC" ? "Public — discoverable in the marketplace. Requires review approval before going live." : G.visibility === "UNLISTED" ? "Unlisted — not in the store, but accessible via a direct share link. You can still submit for marketplace review." : G.visibility === "INTERNAL" ? "Internal — visible to all members of your developer organization, but not to anyone outside." : "Private — only you (the creator) can see this. Other org members cannot access it.",
|
|
411
|
+
children: /* @__PURE__ */ U(T, {
|
|
412
|
+
status: G.visibility,
|
|
411
413
|
type: "app"
|
|
412
414
|
})
|
|
413
415
|
}),
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
/* @__PURE__ */
|
|
416
|
+
G.isVerified && /* @__PURE__ */ U(E, { verified: !0 }),
|
|
417
|
+
G.isFeatured && /* @__PURE__ */ U(w, {}),
|
|
418
|
+
/* @__PURE__ */ U("span", {
|
|
417
419
|
className: "text-sm text-text-secondary",
|
|
418
|
-
children: C[
|
|
420
|
+
children: C[G.appType] || G.appType
|
|
419
421
|
})
|
|
420
422
|
]
|
|
421
423
|
}),
|
|
422
|
-
|
|
424
|
+
G.status === "SUBMITTED" && /* @__PURE__ */ W("div", {
|
|
423
425
|
className: "flex items-start gap-3 rounded-lg border border-border-subtle bg-status-warning-bg-subtle p-4",
|
|
424
|
-
children: [/* @__PURE__ */
|
|
426
|
+
children: [/* @__PURE__ */ U(ve, {
|
|
425
427
|
size: 18,
|
|
426
428
|
className: "text-status-warning-text mt-0.5 flex-shrink-0"
|
|
427
|
-
}), /* @__PURE__ */
|
|
429
|
+
}), /* @__PURE__ */ W("div", {
|
|
428
430
|
className: "text-sm",
|
|
429
|
-
children: [/* @__PURE__ */
|
|
431
|
+
children: [/* @__PURE__ */ U("p", {
|
|
430
432
|
className: "font-medium text-status-warning-text",
|
|
431
433
|
children: m("devportal.underReview", "Under Review")
|
|
432
|
-
}), /* @__PURE__ */
|
|
434
|
+
}), /* @__PURE__ */ W("p", {
|
|
433
435
|
className: "mt-0.5 text-text-secondary",
|
|
434
|
-
children: [m("devportal.underReviewDesc", "Your submission is being reviewed by our team. You'll be notified of the outcome."),
|
|
436
|
+
children: [m("devportal.underReviewDesc", "Your submission is being reviewed by our team. You'll be notified of the outcome."), G.submittedAt && /* @__PURE__ */ W("span", {
|
|
435
437
|
className: "ml-1",
|
|
436
438
|
children: [
|
|
437
439
|
"Submitted ",
|
|
438
|
-
new Date(
|
|
440
|
+
new Date(G.submittedAt).toLocaleDateString(),
|
|
439
441
|
"."
|
|
440
442
|
]
|
|
441
443
|
})]
|
|
442
444
|
})]
|
|
443
445
|
})]
|
|
444
446
|
}),
|
|
445
|
-
|
|
447
|
+
G.status === "REJECTED" && /* @__PURE__ */ W("div", {
|
|
446
448
|
className: "flex items-start gap-3 rounded-lg border border-status-error-bg bg-status-error-bg-subtle p-4",
|
|
447
|
-
children: [/* @__PURE__ */
|
|
449
|
+
children: [/* @__PURE__ */ U(Re, {
|
|
448
450
|
size: 18,
|
|
449
451
|
className: "text-status-error-text mt-0.5 flex-shrink-0"
|
|
450
|
-
}), /* @__PURE__ */
|
|
452
|
+
}), /* @__PURE__ */ W("div", {
|
|
451
453
|
className: "text-sm",
|
|
452
454
|
children: [
|
|
453
|
-
/* @__PURE__ */
|
|
455
|
+
/* @__PURE__ */ U("p", {
|
|
454
456
|
className: "font-medium text-status-error-text",
|
|
455
457
|
children: m("devportal.reviewRejected", "Review Rejected")
|
|
456
458
|
}),
|
|
457
|
-
/* @__PURE__ */
|
|
459
|
+
/* @__PURE__ */ U("p", {
|
|
458
460
|
className: "mt-0.5 text-text-secondary",
|
|
459
|
-
children:
|
|
461
|
+
children: G.reviewNotes || m("devportal.reviewRejectedDesc", "Your submission was not approved. Please review the feedback, update your app, and re-submit.")
|
|
460
462
|
}),
|
|
461
|
-
/* @__PURE__ */
|
|
463
|
+
/* @__PURE__ */ U("button", {
|
|
462
464
|
type: "button",
|
|
463
|
-
onClick: () =>
|
|
465
|
+
onClick: () => V(`/apps/${G.id}/edit`),
|
|
464
466
|
className: "mt-2 inline-flex items-center gap-1 text-xs font-medium text-primary underline",
|
|
465
467
|
children: m("devportal.editAndResubmit", "Edit app and re-submit →")
|
|
466
468
|
})
|
|
467
469
|
]
|
|
468
470
|
})]
|
|
469
471
|
}),
|
|
470
|
-
|
|
472
|
+
G.status === "PUBLISHED" && /* @__PURE__ */ W("div", {
|
|
471
473
|
className: "flex items-start gap-3 rounded-lg border border-status-success-bg bg-status-success-bg-subtle p-4",
|
|
472
|
-
children: [/* @__PURE__ */
|
|
474
|
+
children: [/* @__PURE__ */ U(ge, {
|
|
473
475
|
size: 18,
|
|
474
476
|
className: "text-status-success-text mt-0.5 flex-shrink-0"
|
|
475
|
-
}), /* @__PURE__ */
|
|
477
|
+
}), /* @__PURE__ */ W("div", {
|
|
476
478
|
className: "text-sm",
|
|
477
|
-
children: [/* @__PURE__ */
|
|
479
|
+
children: [/* @__PURE__ */ U("p", {
|
|
478
480
|
className: "font-medium text-status-success-text",
|
|
479
481
|
children: m("devportal.liveInStore", "Live in the Store")
|
|
480
|
-
}), /* @__PURE__ */
|
|
482
|
+
}), /* @__PURE__ */ U("p", {
|
|
481
483
|
className: "mt-0.5 text-text-secondary",
|
|
482
484
|
children: m("devportal.liveInStoreDesc", "Your app is published and visible to users in the marketplace.")
|
|
483
485
|
})]
|
|
484
486
|
})]
|
|
485
487
|
}),
|
|
486
|
-
|
|
488
|
+
G.status === "UNLISTED" && /* @__PURE__ */ W("div", {
|
|
487
489
|
className: "flex items-start gap-3 rounded-lg border border-status-warning-bg bg-status-warning-bg-subtle p-4",
|
|
488
|
-
children: [/* @__PURE__ */
|
|
490
|
+
children: [/* @__PURE__ */ U(pe, {
|
|
489
491
|
size: 18,
|
|
490
492
|
className: "text-status-warning-text mt-0.5 flex-shrink-0"
|
|
491
|
-
}), /* @__PURE__ */
|
|
493
|
+
}), /* @__PURE__ */ W("div", {
|
|
492
494
|
className: "text-sm",
|
|
493
495
|
children: [
|
|
494
|
-
/* @__PURE__ */
|
|
496
|
+
/* @__PURE__ */ U("p", {
|
|
495
497
|
className: "font-medium text-status-warning-text",
|
|
496
498
|
children: m("devportal.delistedFromStore", "Delisted from the Store")
|
|
497
499
|
}),
|
|
498
|
-
/* @__PURE__ */
|
|
500
|
+
/* @__PURE__ */ U("p", {
|
|
499
501
|
className: "mt-0.5 text-text-secondary",
|
|
500
502
|
children: m("devportal.delistedFromStoreDesc", "Your app has been removed from the marketplace and is no longer visible to new users. Existing installs continue to work.")
|
|
501
503
|
}),
|
|
502
|
-
|
|
504
|
+
G.reviewNotes && /* @__PURE__ */ W("p", {
|
|
503
505
|
className: "mt-2 rounded-md bg-status-warning-bg px-3 py-2 font-mono text-xs text-status-warning-text",
|
|
504
506
|
children: [
|
|
505
507
|
m("devportal.delistReason", "Reason"),
|
|
506
508
|
": ",
|
|
507
|
-
|
|
509
|
+
G.reviewNotes
|
|
508
510
|
]
|
|
509
511
|
})
|
|
510
512
|
]
|
|
511
513
|
})]
|
|
512
514
|
}),
|
|
513
|
-
(
|
|
514
|
-
let e = !!
|
|
515
|
-
!
|
|
516
|
-
!
|
|
517
|
-
!
|
|
518
|
-
(
|
|
515
|
+
(G.status === "DRAFT" || G.status === "REJECTED") && !rt && (() => {
|
|
516
|
+
let e = !!G.description?.trim() && !!G.category && !!G.iconUrl && (G.visibility === "PUBLIC" || G.visibility === "UNLISTED"), n = !K && !q || J > 0, r = [
|
|
517
|
+
!G.description?.trim() && "Add a full description",
|
|
518
|
+
!G.category && "Select a category",
|
|
519
|
+
!G.iconUrl && "Upload an app icon",
|
|
520
|
+
(G.visibility === "PRIVATE" || G.visibility === "INTERNAL") && "Set to Public (marketplace) or Unlisted (share via link) — Private and Internal block review submission"
|
|
519
521
|
].filter(Boolean), i = [
|
|
520
522
|
{
|
|
521
523
|
id: "store",
|
|
@@ -524,14 +526,14 @@ var Ue = [
|
|
|
524
526
|
done: e,
|
|
525
527
|
onClick: () => D("store-listing")
|
|
526
528
|
},
|
|
527
|
-
...
|
|
529
|
+
...K ? [{
|
|
528
530
|
id: "version",
|
|
529
531
|
label: m("devportal.setupVersionStep", "Upload a Version"),
|
|
530
532
|
hint: n ? m("devportal.done", "Done") : m("devportal.uploadVersionHint", "Upload your ZIP bundle and manifest"),
|
|
531
533
|
done: n,
|
|
532
534
|
onClick: () => D("versions")
|
|
533
535
|
}] : [],
|
|
534
|
-
...
|
|
536
|
+
...q ? [{
|
|
535
537
|
id: "version",
|
|
536
538
|
label: m("devportal.setupIntegrationVersionStep", "Publish a Version"),
|
|
537
539
|
hint: n ? m("devportal.done", "Done") : m("devportal.integrationVersionHint", "Define required scopes and publish your first API version"),
|
|
@@ -547,41 +549,41 @@ var Ue = [
|
|
|
547
549
|
{
|
|
548
550
|
id: "pricing",
|
|
549
551
|
label: m("devportal.setupPricingStep", "Set Pricing"),
|
|
550
|
-
hint:
|
|
551
|
-
done:
|
|
552
|
+
hint: Z ? m("devportal.done", "Done") : m("devportal.pricingHint", "Choose Free or set a credit price in the Pricing tab"),
|
|
553
|
+
done: Z,
|
|
552
554
|
onClick: () => D("pricing")
|
|
553
555
|
},
|
|
554
|
-
...
|
|
556
|
+
...Y ? [{
|
|
555
557
|
id: "billing",
|
|
556
558
|
label: m("devportal.setupBillingStep", "Link Billing Account"),
|
|
557
|
-
hint:
|
|
558
|
-
done:
|
|
559
|
+
hint: X ? m("devportal.done", "Done") : m("devportal.billingAccountHint", "Link a billing account to receive payouts — required for paid apps"),
|
|
560
|
+
done: X,
|
|
559
561
|
onClick: () => D("pricing")
|
|
560
562
|
}] : [],
|
|
561
563
|
{
|
|
562
564
|
id: "submit",
|
|
563
565
|
label: m("devportal.submitForReview", "Submit for Review"),
|
|
564
|
-
hint:
|
|
566
|
+
hint: rt ? m("devportal.readyToSubmit", "Ready — click Submit for Review above") : G.description?.trim() ? G.category ? G.iconUrl ? G.visibility === "PRIVATE" || G.visibility === "INTERNAL" ? m("devportal.hintPrivateVisibility", "Set visibility to Public (marketplace) or Unlisted (share via link) — Private and Internal cannot be submitted") : (K || q) && J === 0 ? m("devportal.hintMissingVersion", "Upload at least one version") : Z ? Y && !X ? m("devportal.hintMissingBilling", "Link a billing account in the Pricing tab to receive payouts") : m("devportal.completeStepsFirst", "Complete the steps above first") : m("devportal.hintMissingPricing", "Choose Free or set a credit price in the Pricing tab") : m("devportal.hintMissingIcon", "Upload an app icon on the Store Listing tab") : m("devportal.hintMissingCategory", "Select a category on the Store Listing tab") : m("devportal.hintMissingDescription", "Add a full description on the Store Listing tab"),
|
|
565
567
|
done: !1,
|
|
566
568
|
onClick: void 0
|
|
567
569
|
}
|
|
568
570
|
], a = i.filter((e) => e.done).length;
|
|
569
|
-
return /* @__PURE__ */
|
|
571
|
+
return /* @__PURE__ */ W("div", {
|
|
570
572
|
className: "rounded-xl border border-border-subtle bg-bg-surface shadow-sm",
|
|
571
|
-
children: [/* @__PURE__ */
|
|
573
|
+
children: [/* @__PURE__ */ U("div", {
|
|
572
574
|
className: "flex items-center justify-between border-b border-border-subtle px-5 py-4",
|
|
573
|
-
children: /* @__PURE__ */
|
|
575
|
+
children: /* @__PURE__ */ W("div", {
|
|
574
576
|
className: "flex items-center gap-3",
|
|
575
|
-
children: [/* @__PURE__ */
|
|
577
|
+
children: [/* @__PURE__ */ U("div", {
|
|
576
578
|
className: "flex h-8 w-8 items-center justify-center rounded-full bg-action-primary-bg/10",
|
|
577
|
-
children: /* @__PURE__ */
|
|
579
|
+
children: /* @__PURE__ */ U(Ne, {
|
|
578
580
|
size: 16,
|
|
579
581
|
className: "text-primary"
|
|
580
582
|
})
|
|
581
|
-
}), /* @__PURE__ */
|
|
583
|
+
}), /* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("p", {
|
|
582
584
|
className: "text-sm font-semibold text-text-primary",
|
|
583
585
|
children: m("devportal.completeSetup", "Complete your app setup")
|
|
584
|
-
}), /* @__PURE__ */
|
|
586
|
+
}), /* @__PURE__ */ W("p", {
|
|
585
587
|
className: "text-xs text-text-secondary",
|
|
586
588
|
children: [
|
|
587
589
|
a,
|
|
@@ -593,29 +595,29 @@ var Ue = [
|
|
|
593
595
|
]
|
|
594
596
|
})] })]
|
|
595
597
|
})
|
|
596
|
-
}), /* @__PURE__ */
|
|
598
|
+
}), /* @__PURE__ */ U("div", {
|
|
597
599
|
className: "divide-y divide-border-subtle",
|
|
598
|
-
children: i.map((e, n) => /* @__PURE__ */
|
|
600
|
+
children: i.map((e, n) => /* @__PURE__ */ W("button", {
|
|
599
601
|
type: "button",
|
|
600
602
|
onClick: e.onClick,
|
|
601
603
|
disabled: !e.onClick,
|
|
602
604
|
className: t("w-full flex items-center gap-4 px-5 py-4 text-left transition-colors", e.onClick ? "hover:bg-bg-sunken/40 cursor-pointer" : "cursor-default opacity-60"),
|
|
603
605
|
children: [
|
|
604
|
-
/* @__PURE__ */
|
|
606
|
+
/* @__PURE__ */ U("div", {
|
|
605
607
|
className: t("flex h-7 w-7 flex-shrink-0 items-center justify-center rounded-full text-xs font-bold", e.done ? "bg-status-success-bg text-status-success-text" : "border-2 border-border-subtle bg-bg-sunken text-text-secondary"),
|
|
606
|
-
children: e.done ? /* @__PURE__ */
|
|
608
|
+
children: e.done ? /* @__PURE__ */ U(F, { size: 13 }) : n + 1
|
|
607
609
|
}),
|
|
608
|
-
/* @__PURE__ */
|
|
610
|
+
/* @__PURE__ */ W("div", {
|
|
609
611
|
className: "flex-1 min-w-0",
|
|
610
|
-
children: [/* @__PURE__ */
|
|
612
|
+
children: [/* @__PURE__ */ U("p", {
|
|
611
613
|
className: t("text-sm font-medium", e.done ? "text-text-secondary line-through" : "text-text-primary"),
|
|
612
614
|
children: e.label
|
|
613
|
-
}), e.hint && !e.done && /* @__PURE__ */
|
|
615
|
+
}), e.hint && !e.done && /* @__PURE__ */ U("p", {
|
|
614
616
|
className: "mt-0.5 text-xs text-text-secondary truncate",
|
|
615
617
|
children: e.hint
|
|
616
618
|
})]
|
|
617
619
|
}),
|
|
618
|
-
e.onClick && !e.done && /* @__PURE__ */
|
|
620
|
+
e.onClick && !e.done && /* @__PURE__ */ U(_e, {
|
|
619
621
|
size: 16,
|
|
620
622
|
className: "flex-shrink-0 text-text-secondary"
|
|
621
623
|
})
|
|
@@ -624,103 +626,103 @@ var Ue = [
|
|
|
624
626
|
})]
|
|
625
627
|
});
|
|
626
628
|
})(),
|
|
627
|
-
/* @__PURE__ */
|
|
629
|
+
/* @__PURE__ */ U("div", {
|
|
628
630
|
className: "border-b",
|
|
629
|
-
children: /* @__PURE__ */
|
|
631
|
+
children: /* @__PURE__ */ U("nav", {
|
|
630
632
|
className: "-mb-px flex gap-4 overflow-x-auto",
|
|
631
633
|
role: "tablist",
|
|
632
634
|
"aria-label": m("devportal.applicationSections", "Application sections"),
|
|
633
|
-
children:
|
|
635
|
+
children: Ge.filter((e) => !(K && (e.id === "permissions" || e.id === "webhooks" || e.id === "delegations" || e.id === "playground" || e.id === "oauth" || e.id === "api-keys") || !K && !q && e.id === "versions" || !q && (e.id === "oauth" || e.id === "api-keys"))).map((e) => {
|
|
634
636
|
let n = e.icon;
|
|
635
|
-
return /* @__PURE__ */
|
|
637
|
+
return /* @__PURE__ */ W("button", {
|
|
636
638
|
id: `application-tab-${e.id}`,
|
|
637
639
|
role: "tab",
|
|
638
640
|
"aria-selected": S === e.id,
|
|
639
641
|
"aria-controls": `application-panel-${e.id}`,
|
|
640
642
|
onClick: () => D(e.id),
|
|
641
643
|
className: t("flex items-center gap-2 border-b-2 px-1 py-3 text-sm font-medium transition-colors", S === e.id ? "border-primary text-primary" : "border-transparent text-text-secondary hover:text-text-primary hover:border-muted-foreground"),
|
|
642
|
-
children: [/* @__PURE__ */
|
|
644
|
+
children: [/* @__PURE__ */ U(n, { size: 16 }), e.label]
|
|
643
645
|
}, e.id);
|
|
644
646
|
})
|
|
645
647
|
})
|
|
646
648
|
}),
|
|
647
|
-
/* @__PURE__ */
|
|
649
|
+
/* @__PURE__ */ W("div", {
|
|
648
650
|
className: "mt-6",
|
|
649
651
|
id: `application-panel-${S}`,
|
|
650
652
|
role: "tabpanel",
|
|
651
653
|
"aria-labelledby": `application-tab-${S}`,
|
|
652
654
|
tabIndex: 0,
|
|
653
655
|
children: [
|
|
654
|
-
S === "overview" && /* @__PURE__ */
|
|
655
|
-
app:
|
|
656
|
+
S === "overview" && /* @__PURE__ */ U(nt, {
|
|
657
|
+
app: G,
|
|
656
658
|
appId: b,
|
|
657
|
-
refetch: () => void
|
|
659
|
+
refetch: () => void he()
|
|
658
660
|
}),
|
|
659
|
-
S === "permissions" && /* @__PURE__ */
|
|
660
|
-
app:
|
|
661
|
-
versionScopes:
|
|
662
|
-
locked:
|
|
661
|
+
S === "permissions" && /* @__PURE__ */ U(xt, {
|
|
662
|
+
app: G,
|
|
663
|
+
versionScopes: j?.application?.versions?.edges?.[0]?.node?.requiredScopes ?? [],
|
|
664
|
+
locked: G.status === "PUBLISHED" || G.status === "APPROVED" || G.status === "ACTIVE",
|
|
663
665
|
onNavigateToVersions: () => D("versions")
|
|
664
666
|
}),
|
|
665
|
-
S === "webhooks" && /* @__PURE__ */
|
|
666
|
-
appId:
|
|
667
|
-
onNavigate:
|
|
667
|
+
S === "webhooks" && /* @__PURE__ */ U($e, {
|
|
668
|
+
appId: G.id,
|
|
669
|
+
onNavigate: V
|
|
668
670
|
}),
|
|
669
|
-
S === "delegations" && /* @__PURE__ */
|
|
670
|
-
authAppId:
|
|
671
|
-
appName:
|
|
672
|
-
onGrantDelegation: () =>
|
|
673
|
-
onNavigate:
|
|
671
|
+
S === "delegations" && /* @__PURE__ */ U(et, {
|
|
672
|
+
authAppId: G.appId || void 0,
|
|
673
|
+
appName: G.name,
|
|
674
|
+
onGrantDelegation: () => de(!0),
|
|
675
|
+
onNavigate: V
|
|
674
676
|
}),
|
|
675
|
-
S === "analytics" && /* @__PURE__ */
|
|
676
|
-
S === "playground" && /* @__PURE__ */
|
|
677
|
-
S === "oauth" && /* @__PURE__ */
|
|
678
|
-
appId:
|
|
679
|
-
onNavigate:
|
|
677
|
+
S === "analytics" && /* @__PURE__ */ U(tt, { appId: G.id }),
|
|
678
|
+
S === "playground" && /* @__PURE__ */ U(ot, { app: G }),
|
|
679
|
+
S === "oauth" && /* @__PURE__ */ U(qe, {
|
|
680
|
+
appId: G.id,
|
|
681
|
+
onNavigate: V
|
|
680
682
|
}),
|
|
681
|
-
S === "api-keys" && /* @__PURE__ */
|
|
682
|
-
appId:
|
|
683
|
-
onNavigate:
|
|
683
|
+
S === "api-keys" && /* @__PURE__ */ U(Je, {
|
|
684
|
+
appId: G.id,
|
|
685
|
+
onNavigate: V
|
|
684
686
|
}),
|
|
685
|
-
S === "store-listing" && /* @__PURE__ */
|
|
686
|
-
app:
|
|
687
|
-
versionCount:
|
|
688
|
-
isPackageApp:
|
|
689
|
-
pricingDone:
|
|
690
|
-
onNavigateToVersions:
|
|
687
|
+
S === "store-listing" && /* @__PURE__ */ U(mt, {
|
|
688
|
+
app: G,
|
|
689
|
+
versionCount: j?.application?.versions?.totalCount ?? 0,
|
|
690
|
+
isPackageApp: K,
|
|
691
|
+
pricingDone: Z,
|
|
692
|
+
onNavigateToVersions: K || q ? () => D("versions") : void 0,
|
|
691
693
|
onNavigateToPricing: () => D("pricing"),
|
|
692
|
-
onNavigateToSubmission: () =>
|
|
694
|
+
onNavigateToSubmission: () => V(`/apps/${G.id}/store-submission`)
|
|
693
695
|
}),
|
|
694
|
-
S === "pricing" && /* @__PURE__ */
|
|
695
|
-
app:
|
|
696
|
-
platformFeeRate:
|
|
697
|
-
billingAccountLinked:
|
|
698
|
-
onNavigateToRevenue: () =>
|
|
699
|
-
isReadyToSubmit:
|
|
696
|
+
S === "pricing" && /* @__PURE__ */ U(Ze, {
|
|
697
|
+
app: G,
|
|
698
|
+
platformFeeRate: Ye,
|
|
699
|
+
billingAccountLinked: X,
|
|
700
|
+
onNavigateToRevenue: () => V("/revenue"),
|
|
701
|
+
isReadyToSubmit: rt
|
|
700
702
|
}),
|
|
701
|
-
S === "versions" && /* @__PURE__ */
|
|
702
|
-
appId:
|
|
703
|
-
onNavigate:
|
|
704
|
-
pricingDone:
|
|
703
|
+
S === "versions" && /* @__PURE__ */ U(Qe, {
|
|
704
|
+
appId: G.id,
|
|
705
|
+
onNavigate: V,
|
|
706
|
+
pricingDone: Z,
|
|
705
707
|
onNavigateToPricing: () => D("pricing")
|
|
706
708
|
})
|
|
707
709
|
]
|
|
708
710
|
}),
|
|
709
|
-
/* @__PURE__ */
|
|
711
|
+
/* @__PURE__ */ U(ae, {
|
|
710
712
|
open: te,
|
|
711
713
|
onOpenChange: ne,
|
|
712
|
-
onConfirm:
|
|
714
|
+
onConfirm: Ie,
|
|
713
715
|
title: m("devportal.rotateAppSecret", "Rotate App Secret"),
|
|
714
716
|
description: m("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."),
|
|
715
717
|
confirmLabel: m("devportal.rotateSecret", "Rotate Secret"),
|
|
716
718
|
cancelLabel: m("devportal.cancel", "Cancel"),
|
|
717
719
|
variant: "warning",
|
|
718
|
-
loading:
|
|
720
|
+
loading: ye
|
|
719
721
|
}),
|
|
720
|
-
/* @__PURE__ */
|
|
722
|
+
/* @__PURE__ */ U(ae, {
|
|
721
723
|
open: k,
|
|
722
724
|
onOpenChange: re,
|
|
723
|
-
onConfirm:
|
|
725
|
+
onConfirm: Le,
|
|
724
726
|
title: m("devportal.deactivateApplication", "Deactivate Application"),
|
|
725
727
|
description: m("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."),
|
|
726
728
|
confirmLabel: m("devportal.deactivate", "Deactivate"),
|
|
@@ -728,67 +730,67 @@ var Ue = [
|
|
|
728
730
|
variant: "destructive",
|
|
729
731
|
loading: Se
|
|
730
732
|
}),
|
|
731
|
-
/* @__PURE__ */
|
|
733
|
+
/* @__PURE__ */ U(oe, {
|
|
732
734
|
open: ue,
|
|
733
|
-
onOpenChange:
|
|
734
|
-
appId:
|
|
735
|
-
appName:
|
|
736
|
-
appScopes:
|
|
735
|
+
onOpenChange: de,
|
|
736
|
+
appId: G.appId || "",
|
|
737
|
+
appName: G.name,
|
|
738
|
+
appScopes: G.scopes?.map((e) => e.scope) ?? [],
|
|
737
739
|
onSuccess: () => {
|
|
738
|
-
|
|
740
|
+
de(!1);
|
|
739
741
|
}
|
|
740
742
|
})
|
|
741
743
|
]
|
|
742
744
|
});
|
|
743
|
-
},
|
|
745
|
+
}, qe = ({ onNavigate: e }) => {
|
|
744
746
|
let { t } = P(), n = (e, n) => {
|
|
745
747
|
let r = t(e);
|
|
746
748
|
return r === e ? n : r;
|
|
747
749
|
};
|
|
748
|
-
return /* @__PURE__ */
|
|
750
|
+
return /* @__PURE__ */ W("div", {
|
|
749
751
|
className: "space-y-4 py-4 text-center",
|
|
750
752
|
children: [
|
|
751
|
-
/* @__PURE__ */
|
|
752
|
-
/* @__PURE__ */
|
|
753
|
+
/* @__PURE__ */ U(z, { className: "mx-auto h-10 w-10 text-text-secondary" }),
|
|
754
|
+
/* @__PURE__ */ U("h3", {
|
|
753
755
|
className: "font-medium",
|
|
754
756
|
children: n("devportal.oauthApps", "OAuth Apps")
|
|
755
757
|
}),
|
|
756
|
-
/* @__PURE__ */
|
|
758
|
+
/* @__PURE__ */ U("p", {
|
|
757
759
|
className: "text-sm text-text-secondary",
|
|
758
760
|
children: n("devportal.oauthAppsManagedCentrally", "OAuth apps are now managed centrally. Visit the OAuth Apps page to create and manage your apps.")
|
|
759
761
|
}),
|
|
760
|
-
/* @__PURE__ */
|
|
762
|
+
/* @__PURE__ */ W("button", {
|
|
761
763
|
onClick: () => e("/oauth"),
|
|
762
764
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 transition-colors",
|
|
763
|
-
children: [/* @__PURE__ */
|
|
765
|
+
children: [/* @__PURE__ */ U(L, { size: 16 }), n("devportal.manageOAuthApps", "Manage OAuth Apps")]
|
|
764
766
|
})
|
|
765
767
|
]
|
|
766
768
|
});
|
|
767
|
-
},
|
|
769
|
+
}, Je = ({ onNavigate: e }) => {
|
|
768
770
|
let { t } = P(), n = (e, n) => {
|
|
769
771
|
let r = t(e);
|
|
770
772
|
return r === e ? n : r;
|
|
771
773
|
};
|
|
772
|
-
return /* @__PURE__ */
|
|
774
|
+
return /* @__PURE__ */ W("div", {
|
|
773
775
|
className: "space-y-4 py-4 text-center",
|
|
774
776
|
children: [
|
|
775
|
-
/* @__PURE__ */
|
|
776
|
-
/* @__PURE__ */
|
|
777
|
+
/* @__PURE__ */ U(we, { className: "mx-auto h-10 w-10 text-text-secondary" }),
|
|
778
|
+
/* @__PURE__ */ U("h3", {
|
|
777
779
|
className: "font-medium",
|
|
778
780
|
children: n("devportal.apiKeys", "API Keys")
|
|
779
781
|
}),
|
|
780
|
-
/* @__PURE__ */
|
|
782
|
+
/* @__PURE__ */ U("p", {
|
|
781
783
|
className: "text-sm text-text-secondary",
|
|
782
784
|
children: n("devportal.apiKeysManagedCentrally", "API keys are now managed centrally. Visit the API Keys page to generate and manage your keys.")
|
|
783
785
|
}),
|
|
784
|
-
/* @__PURE__ */
|
|
786
|
+
/* @__PURE__ */ W("button", {
|
|
785
787
|
onClick: () => e("/api-keys"),
|
|
786
788
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 transition-colors",
|
|
787
|
-
children: [/* @__PURE__ */
|
|
789
|
+
children: [/* @__PURE__ */ U(L, { size: 16 }), n("devportal.manageApiKeys", "Manage API Keys")]
|
|
788
790
|
})
|
|
789
791
|
]
|
|
790
792
|
});
|
|
791
|
-
},
|
|
793
|
+
}, Ye = .01, X = (e) => e * Ye, Xe = (e) => Math.round(e / Ye), Ze = ({ app: e, platformFeeRate: n, billingAccountLinked: r, onNavigateToRevenue: i, isReadyToSubmit: a = !1 }) => {
|
|
792
794
|
let { t: o } = P(), s = (e, t) => {
|
|
793
795
|
let n = o(e);
|
|
794
796
|
return n === e ? t : n;
|
|
@@ -796,7 +798,7 @@ var Ue = [
|
|
|
796
798
|
pricingType: e.pricingType ?? "FREE",
|
|
797
799
|
price: typeof c.price == "number" ? String(c.price) : ""
|
|
798
800
|
}), [d, f] = N(!1), [p] = b(), m = M(e);
|
|
799
|
-
m.current = e,
|
|
801
|
+
m.current = e, de(() => {
|
|
800
802
|
let e = m.current.pricingDetails ?? {};
|
|
801
803
|
u({
|
|
802
804
|
pricingType: m.current.pricingType ?? "FREE",
|
|
@@ -828,33 +830,33 @@ var Ue = [
|
|
|
828
830
|
} finally {
|
|
829
831
|
f(!1);
|
|
830
832
|
}
|
|
831
|
-
}, _ = l.pricingType !== "FREE", v = parseInt(l.price, 10), y = _ && !isNaN(v) && v > 0, x = y ?
|
|
833
|
+
}, _ = l.pricingType !== "FREE", v = parseInt(l.price, 10), y = _ && !isNaN(v) && v > 0, x = y ? X(v) : 0, S = y ? Math.round(v * n) : 0, C = X(S), w = y ? v - S : 0, T = X(w), E = (e) => "$" + e.toLocaleString("en-US", {
|
|
832
834
|
minimumFractionDigits: 2,
|
|
833
835
|
maximumFractionDigits: 2
|
|
834
836
|
}), D = (e) => e.toLocaleString("en-US") + " cr";
|
|
835
|
-
return /* @__PURE__ */
|
|
837
|
+
return /* @__PURE__ */ W("div", {
|
|
836
838
|
className: "space-y-8",
|
|
837
839
|
children: [
|
|
838
|
-
/* @__PURE__ */
|
|
840
|
+
/* @__PURE__ */ W("div", {
|
|
839
841
|
className: "flex items-start gap-3 rounded-lg border border-border-subtle bg-bg-sunken px-4 py-3",
|
|
840
|
-
children: [/* @__PURE__ */
|
|
842
|
+
children: [/* @__PURE__ */ U(I, {
|
|
841
843
|
size: 16,
|
|
842
844
|
className: "mt-0.5 shrink-0 text-primary"
|
|
843
|
-
}), /* @__PURE__ */
|
|
845
|
+
}), /* @__PURE__ */ W("p", {
|
|
844
846
|
className: "text-sm text-text-secondary",
|
|
845
847
|
children: [
|
|
846
|
-
/* @__PURE__ */
|
|
848
|
+
/* @__PURE__ */ U("span", {
|
|
847
849
|
className: "font-medium text-text-primary",
|
|
848
850
|
children: "Platform credits"
|
|
849
851
|
}),
|
|
850
852
|
" ",
|
|
851
853
|
"are the currency of the Burdenoff marketplace.",
|
|
852
854
|
" ",
|
|
853
|
-
/* @__PURE__ */
|
|
855
|
+
/* @__PURE__ */ W("span", {
|
|
854
856
|
className: "font-medium",
|
|
855
857
|
children: [
|
|
856
858
|
"1 credit = ",
|
|
857
|
-
E(
|
|
859
|
+
E(Ye),
|
|
858
860
|
" USD."
|
|
859
861
|
]
|
|
860
862
|
}),
|
|
@@ -863,41 +865,41 @@ var Ue = [
|
|
|
863
865
|
]
|
|
864
866
|
})]
|
|
865
867
|
}),
|
|
866
|
-
/* @__PURE__ */
|
|
868
|
+
/* @__PURE__ */ W("div", {
|
|
867
869
|
className: "space-y-3",
|
|
868
|
-
children: [/* @__PURE__ */
|
|
870
|
+
children: [/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("h2", {
|
|
869
871
|
className: "text-lg font-semibold",
|
|
870
872
|
children: s("devportal.howMonetizationWorks", "How App Monetization Works")
|
|
871
|
-
}), /* @__PURE__ */
|
|
873
|
+
}), /* @__PURE__ */ U("p", {
|
|
872
874
|
className: "mt-1 text-sm text-text-secondary",
|
|
873
875
|
children: s("devportal.monetizationDesc", "Earn revenue when users install or purchase your app. Here's exactly how the money flows.")
|
|
874
|
-
})] }), /* @__PURE__ */
|
|
876
|
+
})] }), /* @__PURE__ */ W("div", {
|
|
875
877
|
className: "grid gap-4 sm:grid-cols-3",
|
|
876
878
|
children: [
|
|
877
|
-
/* @__PURE__ */
|
|
879
|
+
/* @__PURE__ */ W("div", {
|
|
878
880
|
className: "rounded-xl border border-border-subtle bg-bg-surface p-5 space-y-3",
|
|
879
|
-
children: [/* @__PURE__ */
|
|
881
|
+
children: [/* @__PURE__ */ U("div", {
|
|
880
882
|
className: "flex h-9 w-9 items-center justify-center rounded-lg bg-status-success-bg-subtle",
|
|
881
|
-
children: /* @__PURE__ */
|
|
883
|
+
children: /* @__PURE__ */ U(Pe, {
|
|
882
884
|
size: 18,
|
|
883
885
|
className: "text-status-success-text"
|
|
884
886
|
})
|
|
885
|
-
}), /* @__PURE__ */
|
|
887
|
+
}), /* @__PURE__ */ W("div", { children: [/* @__PURE__ */ W("p", {
|
|
886
888
|
className: "font-semibold",
|
|
887
889
|
children: [(100 - n * 100).toFixed(0), "% revenue share"]
|
|
888
|
-
}), /* @__PURE__ */
|
|
890
|
+
}), /* @__PURE__ */ W("p", {
|
|
889
891
|
className: "mt-1 text-sm text-text-secondary",
|
|
890
892
|
children: [
|
|
891
893
|
"You keep",
|
|
892
894
|
" ",
|
|
893
|
-
/* @__PURE__ */
|
|
895
|
+
/* @__PURE__ */ W("span", {
|
|
894
896
|
className: "font-medium text-status-success-text",
|
|
895
897
|
children: [(100 - n * 100).toFixed(0), "%"]
|
|
896
898
|
}),
|
|
897
899
|
" ",
|
|
898
900
|
"of every sale in credits. The platform retains a",
|
|
899
901
|
" ",
|
|
900
|
-
/* @__PURE__ */
|
|
902
|
+
/* @__PURE__ */ W("span", {
|
|
901
903
|
className: "font-medium",
|
|
902
904
|
children: [(n * 100).toFixed(0), "%"]
|
|
903
905
|
}),
|
|
@@ -906,28 +908,28 @@ var Ue = [
|
|
|
906
908
|
]
|
|
907
909
|
})] })]
|
|
908
910
|
}),
|
|
909
|
-
/* @__PURE__ */
|
|
911
|
+
/* @__PURE__ */ W("div", {
|
|
910
912
|
className: "rounded-xl border border-border-subtle bg-bg-surface p-5 space-y-3",
|
|
911
|
-
children: [/* @__PURE__ */
|
|
913
|
+
children: [/* @__PURE__ */ U("div", {
|
|
912
914
|
className: "flex h-9 w-9 items-center justify-center rounded-lg bg-action-primary-bg/10",
|
|
913
|
-
children: /* @__PURE__ */
|
|
915
|
+
children: /* @__PURE__ */ U(V, {
|
|
914
916
|
size: 18,
|
|
915
917
|
className: "text-primary"
|
|
916
918
|
})
|
|
917
|
-
}), /* @__PURE__ */
|
|
919
|
+
}), /* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("p", {
|
|
918
920
|
className: "font-semibold",
|
|
919
921
|
children: "Credits → cash via billing"
|
|
920
|
-
}), /* @__PURE__ */
|
|
922
|
+
}), /* @__PURE__ */ W("p", {
|
|
921
923
|
className: "mt-1 text-sm text-text-secondary",
|
|
922
924
|
children: [
|
|
923
925
|
"Every sale instantly deposits your earned credits into your linked billing account. You can spend them on platform services or request a cash withdrawal. Track everything on the",
|
|
924
926
|
" ",
|
|
925
|
-
i ? /* @__PURE__ */
|
|
927
|
+
i ? /* @__PURE__ */ U("button", {
|
|
926
928
|
type: "button",
|
|
927
929
|
onClick: i,
|
|
928
930
|
className: "font-medium text-primary underline-offset-2 hover:underline",
|
|
929
931
|
children: "Revenue page"
|
|
930
|
-
}) : /* @__PURE__ */
|
|
932
|
+
}) : /* @__PURE__ */ U("span", {
|
|
931
933
|
className: "font-medium text-primary",
|
|
932
934
|
children: "Revenue page"
|
|
933
935
|
}),
|
|
@@ -935,18 +937,18 @@ var Ue = [
|
|
|
935
937
|
]
|
|
936
938
|
})] })]
|
|
937
939
|
}),
|
|
938
|
-
/* @__PURE__ */
|
|
940
|
+
/* @__PURE__ */ W("div", {
|
|
939
941
|
className: "rounded-xl border border-border-subtle bg-bg-surface p-5 space-y-3",
|
|
940
|
-
children: [/* @__PURE__ */
|
|
942
|
+
children: [/* @__PURE__ */ U("div", {
|
|
941
943
|
className: "flex h-9 w-9 items-center justify-center rounded-lg bg-status-warning-bg-subtle",
|
|
942
|
-
children: /* @__PURE__ */
|
|
944
|
+
children: /* @__PURE__ */ U(Se, {
|
|
943
945
|
size: 18,
|
|
944
946
|
className: "text-status-warning-text"
|
|
945
947
|
})
|
|
946
|
-
}), /* @__PURE__ */
|
|
948
|
+
}), /* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("p", {
|
|
947
949
|
className: "font-semibold",
|
|
948
950
|
children: "Reach the full marketplace"
|
|
949
|
-
}), /* @__PURE__ */
|
|
951
|
+
}), /* @__PURE__ */ U("p", {
|
|
950
952
|
className: "mt-1 text-sm text-text-secondary",
|
|
951
953
|
children: "Any user with platform credits can discover and install your app directly from the marketplace. Free apps maximise reach; paid apps let you monetise your work."
|
|
952
954
|
})] })]
|
|
@@ -954,52 +956,52 @@ var Ue = [
|
|
|
954
956
|
]
|
|
955
957
|
})]
|
|
956
958
|
}),
|
|
957
|
-
/* @__PURE__ */
|
|
959
|
+
/* @__PURE__ */ W("div", {
|
|
958
960
|
className: "space-y-4",
|
|
959
961
|
children: [
|
|
960
|
-
/* @__PURE__ */
|
|
962
|
+
/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("h3", {
|
|
961
963
|
className: "text-base font-semibold",
|
|
962
964
|
children: s("devportal.setPricingTitle", "Set Your Price")
|
|
963
|
-
}), /* @__PURE__ */
|
|
965
|
+
}), /* @__PURE__ */ W("p", {
|
|
964
966
|
className: "mt-0.5 text-sm text-text-secondary",
|
|
965
967
|
children: [
|
|
966
968
|
"Choose ",
|
|
967
|
-
/* @__PURE__ */
|
|
969
|
+
/* @__PURE__ */ U("strong", { children: "Free" }),
|
|
968
970
|
" to maximise installs, or",
|
|
969
971
|
" ",
|
|
970
|
-
/* @__PURE__ */
|
|
972
|
+
/* @__PURE__ */ U("strong", { children: "Paid" }),
|
|
971
973
|
" to earn credits on every install. Paid apps require a linked billing account before publishing."
|
|
972
974
|
]
|
|
973
975
|
})] }),
|
|
974
|
-
/* @__PURE__ */
|
|
976
|
+
/* @__PURE__ */ U("div", {
|
|
975
977
|
className: "flex flex-wrap gap-2",
|
|
976
|
-
children:
|
|
978
|
+
children: ut.map((e) => /* @__PURE__ */ U("button", {
|
|
977
979
|
type: "button",
|
|
978
980
|
onClick: () => h("pricingType", e.value),
|
|
979
981
|
className: t("rounded-md border px-4 py-2 text-sm font-medium transition-colors", l.pricingType === e.value ? "bg-action-primary-bg text-action-primary-text border-primary" : "hover:bg-bg-sunken border-border-subtle"),
|
|
980
982
|
children: e.label
|
|
981
983
|
}, e.value))
|
|
982
984
|
}),
|
|
983
|
-
_ && /* @__PURE__ */
|
|
985
|
+
_ && /* @__PURE__ */ W("div", {
|
|
984
986
|
className: "space-y-4",
|
|
985
987
|
children: [
|
|
986
|
-
/* @__PURE__ */
|
|
988
|
+
/* @__PURE__ */ W("div", {
|
|
987
989
|
className: "max-w-xs",
|
|
988
990
|
children: [
|
|
989
|
-
/* @__PURE__ */
|
|
991
|
+
/* @__PURE__ */ W("label", {
|
|
990
992
|
className: "mb-1.5 block text-sm font-medium",
|
|
991
993
|
children: [
|
|
992
994
|
"Listing price",
|
|
993
995
|
" ",
|
|
994
|
-
/* @__PURE__ */
|
|
996
|
+
/* @__PURE__ */ U("span", {
|
|
995
997
|
className: "text-text-tertiary font-normal",
|
|
996
998
|
children: "(credits)"
|
|
997
999
|
})
|
|
998
1000
|
]
|
|
999
1001
|
}),
|
|
1000
|
-
/* @__PURE__ */
|
|
1002
|
+
/* @__PURE__ */ W("div", {
|
|
1001
1003
|
className: "relative flex items-center",
|
|
1002
|
-
children: [/* @__PURE__ */
|
|
1004
|
+
children: [/* @__PURE__ */ U("input", {
|
|
1003
1005
|
type: "number",
|
|
1004
1006
|
min: 1,
|
|
1005
1007
|
step: 1,
|
|
@@ -1007,69 +1009,69 @@ var Ue = [
|
|
|
1007
1009
|
onChange: (e) => h("price", e.target.value),
|
|
1008
1010
|
placeholder: "e.g. 1000",
|
|
1009
1011
|
className: "w-full rounded-md border border-border-subtle bg-bg-input px-3 py-2 pr-20 text-sm focus:outline-none focus:ring-2 focus:ring-primary/50"
|
|
1010
|
-
}), /* @__PURE__ */
|
|
1012
|
+
}), /* @__PURE__ */ U("span", {
|
|
1011
1013
|
className: "pointer-events-none absolute right-3 text-xs text-text-tertiary",
|
|
1012
1014
|
children: "credits"
|
|
1013
1015
|
})]
|
|
1014
1016
|
}),
|
|
1015
|
-
y && /* @__PURE__ */
|
|
1017
|
+
y && /* @__PURE__ */ W("p", {
|
|
1016
1018
|
className: "mt-1.5 text-xs text-text-secondary",
|
|
1017
1019
|
children: [
|
|
1018
1020
|
"≈ ",
|
|
1019
1021
|
E(x),
|
|
1020
1022
|
" USD at the current credit rate (1 cr =",
|
|
1021
1023
|
" ",
|
|
1022
|
-
E(
|
|
1024
|
+
E(Ye),
|
|
1023
1025
|
")"
|
|
1024
1026
|
]
|
|
1025
1027
|
}),
|
|
1026
|
-
/* @__PURE__ */
|
|
1028
|
+
/* @__PURE__ */ U("p", {
|
|
1027
1029
|
className: "mt-1 text-xs text-text-tertiary",
|
|
1028
1030
|
children: s("devportal.priceHint", "Set the number of credits a buyer spends to install your app")
|
|
1029
1031
|
})
|
|
1030
1032
|
]
|
|
1031
1033
|
}),
|
|
1032
|
-
/* @__PURE__ */
|
|
1034
|
+
/* @__PURE__ */ W("div", {
|
|
1033
1035
|
className: "flex items-center gap-2 text-xs text-text-secondary",
|
|
1034
|
-
children: [/* @__PURE__ */
|
|
1036
|
+
children: [/* @__PURE__ */ U("span", { children: "Quick convert:" }), [
|
|
1035
1037
|
5,
|
|
1036
1038
|
10,
|
|
1037
1039
|
25,
|
|
1038
1040
|
50
|
|
1039
|
-
].map((e) => /* @__PURE__ */
|
|
1041
|
+
].map((e) => /* @__PURE__ */ W("button", {
|
|
1040
1042
|
type: "button",
|
|
1041
|
-
onClick: () => h("price", String(
|
|
1043
|
+
onClick: () => h("price", String(Xe(e))),
|
|
1042
1044
|
className: "rounded border border-border-subtle px-2 py-0.5 hover:bg-bg-sunken transition-colors",
|
|
1043
1045
|
children: [
|
|
1044
1046
|
"$",
|
|
1045
1047
|
e,
|
|
1046
1048
|
" = ",
|
|
1047
|
-
|
|
1049
|
+
Xe(e).toLocaleString(),
|
|
1048
1050
|
" cr"
|
|
1049
1051
|
]
|
|
1050
1052
|
}, e))]
|
|
1051
1053
|
}),
|
|
1052
|
-
y && /* @__PURE__ */
|
|
1054
|
+
y && /* @__PURE__ */ W("div", {
|
|
1053
1055
|
className: "rounded-lg border border-border-subtle bg-bg-sunken p-4 space-y-3",
|
|
1054
1056
|
children: [
|
|
1055
|
-
/* @__PURE__ */
|
|
1057
|
+
/* @__PURE__ */ U("p", {
|
|
1056
1058
|
className: "text-xs font-semibold uppercase tracking-wide text-text-secondary",
|
|
1057
1059
|
children: s("devportal.revenueBreakdown", "Revenue Breakdown per Sale")
|
|
1058
1060
|
}),
|
|
1059
|
-
/* @__PURE__ */
|
|
1061
|
+
/* @__PURE__ */ W("div", {
|
|
1060
1062
|
className: "space-y-2 text-sm",
|
|
1061
1063
|
children: [
|
|
1062
|
-
/* @__PURE__ */
|
|
1064
|
+
/* @__PURE__ */ W("div", {
|
|
1063
1065
|
className: "flex items-center justify-between",
|
|
1064
|
-
children: [/* @__PURE__ */
|
|
1066
|
+
children: [/* @__PURE__ */ U("span", {
|
|
1065
1067
|
className: "text-text-secondary",
|
|
1066
1068
|
children: "Buyer pays"
|
|
1067
|
-
}), /* @__PURE__ */
|
|
1069
|
+
}), /* @__PURE__ */ W("span", {
|
|
1068
1070
|
className: "font-medium tabular-nums",
|
|
1069
1071
|
children: [
|
|
1070
1072
|
D(v),
|
|
1071
1073
|
" ",
|
|
1072
|
-
/* @__PURE__ */
|
|
1074
|
+
/* @__PURE__ */ W("span", {
|
|
1073
1075
|
className: "text-text-tertiary text-xs",
|
|
1074
1076
|
children: [
|
|
1075
1077
|
"(",
|
|
@@ -1080,12 +1082,12 @@ var Ue = [
|
|
|
1080
1082
|
]
|
|
1081
1083
|
})]
|
|
1082
1084
|
}),
|
|
1083
|
-
/* @__PURE__ */
|
|
1085
|
+
/* @__PURE__ */ W("div", {
|
|
1084
1086
|
className: "flex items-center justify-between text-status-error-text",
|
|
1085
|
-
children: [/* @__PURE__ */
|
|
1087
|
+
children: [/* @__PURE__ */ W("span", { children: [
|
|
1086
1088
|
"Platform fee",
|
|
1087
1089
|
" ",
|
|
1088
|
-
/* @__PURE__ */
|
|
1090
|
+
/* @__PURE__ */ W("span", {
|
|
1089
1091
|
className: "opacity-70",
|
|
1090
1092
|
children: [
|
|
1091
1093
|
"(",
|
|
@@ -1093,13 +1095,13 @@ var Ue = [
|
|
|
1093
1095
|
"%)"
|
|
1094
1096
|
]
|
|
1095
1097
|
})
|
|
1096
|
-
] }), /* @__PURE__ */
|
|
1098
|
+
] }), /* @__PURE__ */ W("span", {
|
|
1097
1099
|
className: "tabular-nums",
|
|
1098
1100
|
children: [
|
|
1099
1101
|
"− ",
|
|
1100
1102
|
D(S),
|
|
1101
1103
|
" ",
|
|
1102
|
-
/* @__PURE__ */
|
|
1104
|
+
/* @__PURE__ */ W("span", {
|
|
1103
1105
|
className: "text-xs opacity-70",
|
|
1104
1106
|
children: [
|
|
1105
1107
|
"(",
|
|
@@ -1110,14 +1112,14 @@ var Ue = [
|
|
|
1110
1112
|
]
|
|
1111
1113
|
})]
|
|
1112
1114
|
}),
|
|
1113
|
-
/* @__PURE__ */
|
|
1115
|
+
/* @__PURE__ */ W("div", {
|
|
1114
1116
|
className: "flex items-center justify-between border-t border-border-subtle pt-2 font-semibold text-status-success-text",
|
|
1115
|
-
children: [/* @__PURE__ */
|
|
1117
|
+
children: [/* @__PURE__ */ U("span", { children: "You earn" }), /* @__PURE__ */ W("span", {
|
|
1116
1118
|
className: "tabular-nums",
|
|
1117
1119
|
children: [
|
|
1118
1120
|
D(w),
|
|
1119
1121
|
" ",
|
|
1120
|
-
/* @__PURE__ */
|
|
1122
|
+
/* @__PURE__ */ W("span", {
|
|
1121
1123
|
className: "text-sm font-normal",
|
|
1122
1124
|
children: ["≈ ", E(T)]
|
|
1123
1125
|
})
|
|
@@ -1126,29 +1128,29 @@ var Ue = [
|
|
|
1126
1128
|
})
|
|
1127
1129
|
]
|
|
1128
1130
|
}),
|
|
1129
|
-
/* @__PURE__ */
|
|
1131
|
+
/* @__PURE__ */ U("p", {
|
|
1130
1132
|
className: "text-xs text-text-tertiary",
|
|
1131
1133
|
children: "Credits are deposited to your billing account on each sale. Cash withdrawal is subject to platform terms and minimum payout thresholds."
|
|
1132
1134
|
})
|
|
1133
1135
|
]
|
|
1134
1136
|
}),
|
|
1135
|
-
!r && /* @__PURE__ */
|
|
1137
|
+
!r && /* @__PURE__ */ W("div", {
|
|
1136
1138
|
className: "flex items-start gap-3 rounded-lg border border-status-warning-bg bg-status-warning-bg-subtle p-4",
|
|
1137
|
-
children: [/* @__PURE__ */
|
|
1139
|
+
children: [/* @__PURE__ */ U(pe, {
|
|
1138
1140
|
size: 16,
|
|
1139
1141
|
className: "mt-0.5 shrink-0 text-status-warning-text"
|
|
1140
|
-
}), /* @__PURE__ */
|
|
1142
|
+
}), /* @__PURE__ */ W("div", {
|
|
1141
1143
|
className: "flex-1 min-w-0",
|
|
1142
1144
|
children: [
|
|
1143
|
-
/* @__PURE__ */
|
|
1145
|
+
/* @__PURE__ */ U("p", {
|
|
1144
1146
|
className: "text-sm font-medium text-status-warning-text",
|
|
1145
1147
|
children: s("devportal.billingAccountRequired", "Billing account required to publish")
|
|
1146
1148
|
}),
|
|
1147
|
-
/* @__PURE__ */
|
|
1149
|
+
/* @__PURE__ */ U("p", {
|
|
1148
1150
|
className: "mt-0.5 text-xs text-text-secondary",
|
|
1149
1151
|
children: "Paid apps must have a billing account linked to your developer organization before you can submit for review. This is where your earned credits and cash withdrawals will be managed."
|
|
1150
1152
|
}),
|
|
1151
|
-
i && /* @__PURE__ */
|
|
1153
|
+
i && /* @__PURE__ */ U("button", {
|
|
1152
1154
|
type: "button",
|
|
1153
1155
|
onClick: i,
|
|
1154
1156
|
className: "mt-2 text-xs font-medium text-primary hover:underline underline-offset-2",
|
|
@@ -1161,23 +1163,23 @@ var Ue = [
|
|
|
1161
1163
|
})
|
|
1162
1164
|
]
|
|
1163
1165
|
}),
|
|
1164
|
-
/* @__PURE__ */
|
|
1166
|
+
/* @__PURE__ */ W("div", {
|
|
1165
1167
|
className: "rounded-xl border border-border-subtle bg-bg-surface p-5 space-y-3",
|
|
1166
|
-
children: [/* @__PURE__ */
|
|
1168
|
+
children: [/* @__PURE__ */ U("h3", {
|
|
1167
1169
|
className: "text-sm font-semibold",
|
|
1168
1170
|
children: s("devportal.termsTitle", "Developer & Marketplace Terms")
|
|
1169
|
-
}), /* @__PURE__ */
|
|
1171
|
+
}), /* @__PURE__ */ W("ul", {
|
|
1170
1172
|
className: "space-y-2 text-sm text-text-secondary",
|
|
1171
1173
|
children: [
|
|
1172
|
-
/* @__PURE__ */
|
|
1174
|
+
/* @__PURE__ */ W("li", {
|
|
1173
1175
|
className: "flex items-start gap-2",
|
|
1174
|
-
children: [/* @__PURE__ */
|
|
1176
|
+
children: [/* @__PURE__ */ U(F, {
|
|
1175
1177
|
size: 14,
|
|
1176
1178
|
className: "mt-0.5 shrink-0 text-status-success-text"
|
|
1177
|
-
}), /* @__PURE__ */
|
|
1179
|
+
}), /* @__PURE__ */ W("span", { children: [
|
|
1178
1180
|
"By publishing to the marketplace you agree to the",
|
|
1179
1181
|
" ",
|
|
1180
|
-
/* @__PURE__ */
|
|
1182
|
+
/* @__PURE__ */ U("a", {
|
|
1181
1183
|
href: "/legal/developer-terms",
|
|
1182
1184
|
target: "_blank",
|
|
1183
1185
|
rel: "noopener noreferrer",
|
|
@@ -1187,29 +1189,29 @@ var Ue = [
|
|
|
1187
1189
|
"."
|
|
1188
1190
|
] })]
|
|
1189
1191
|
}),
|
|
1190
|
-
/* @__PURE__ */
|
|
1192
|
+
/* @__PURE__ */ W("li", {
|
|
1191
1193
|
className: "flex items-start gap-2",
|
|
1192
|
-
children: [/* @__PURE__ */
|
|
1194
|
+
children: [/* @__PURE__ */ U(F, {
|
|
1193
1195
|
size: 14,
|
|
1194
1196
|
className: "mt-0.5 shrink-0 text-status-success-text"
|
|
1195
|
-
}), /* @__PURE__ */
|
|
1197
|
+
}), /* @__PURE__ */ U("span", { children: "All prices are in platform credits. The USD equivalent is indicative only and may vary with the current credit rate." })]
|
|
1196
1198
|
}),
|
|
1197
|
-
/* @__PURE__ */
|
|
1199
|
+
/* @__PURE__ */ W("li", {
|
|
1198
1200
|
className: "flex items-start gap-2",
|
|
1199
|
-
children: [/* @__PURE__ */
|
|
1201
|
+
children: [/* @__PURE__ */ U(F, {
|
|
1200
1202
|
size: 14,
|
|
1201
1203
|
className: "mt-0.5 shrink-0 text-status-success-text"
|
|
1202
|
-
}), /* @__PURE__ */
|
|
1204
|
+
}), /* @__PURE__ */ U("span", { children: "Earnings are credited to your billing account per-sale. Cash withdrawals are subject to a minimum threshold and applicable taxes in your jurisdiction." })]
|
|
1203
1205
|
}),
|
|
1204
|
-
/* @__PURE__ */
|
|
1206
|
+
/* @__PURE__ */ W("li", {
|
|
1205
1207
|
className: "flex items-start gap-2",
|
|
1206
|
-
children: [/* @__PURE__ */
|
|
1208
|
+
children: [/* @__PURE__ */ U(F, {
|
|
1207
1209
|
size: 14,
|
|
1208
1210
|
className: "mt-0.5 shrink-0 text-status-success-text"
|
|
1209
|
-
}), /* @__PURE__ */
|
|
1211
|
+
}), /* @__PURE__ */ W("span", { children: [
|
|
1210
1212
|
"The platform reserves the right to adjust the credit rate, fee structure, or payout schedule with 30 days notice. See the",
|
|
1211
1213
|
" ",
|
|
1212
|
-
/* @__PURE__ */
|
|
1214
|
+
/* @__PURE__ */ U("a", {
|
|
1213
1215
|
href: "/legal/marketplace-terms",
|
|
1214
1216
|
target: "_blank",
|
|
1215
1217
|
rel: "noopener noreferrer",
|
|
@@ -1223,26 +1225,26 @@ var Ue = [
|
|
|
1223
1225
|
]
|
|
1224
1226
|
})]
|
|
1225
1227
|
}),
|
|
1226
|
-
/* @__PURE__ */
|
|
1228
|
+
/* @__PURE__ */ W("div", {
|
|
1227
1229
|
className: "border-t border-border-subtle pt-6 space-y-4",
|
|
1228
|
-
children: [/* @__PURE__ */
|
|
1230
|
+
children: [/* @__PURE__ */ U("button", {
|
|
1229
1231
|
type: "button",
|
|
1230
1232
|
onClick: () => void g(),
|
|
1231
1233
|
disabled: d,
|
|
1232
1234
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 transition-colors disabled:opacity-50",
|
|
1233
|
-
children: d ? /* @__PURE__ */
|
|
1235
|
+
children: d ? /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(R, {
|
|
1234
1236
|
size: 16,
|
|
1235
1237
|
className: "animate-spin"
|
|
1236
|
-
}), s("devportal.saving", "Saving…")] }) : /* @__PURE__ */
|
|
1237
|
-
}), a && /* @__PURE__ */
|
|
1238
|
+
}), s("devportal.saving", "Saving…")] }) : /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(I, { size: 16 }), s("devportal.savePricing", "Save Pricing")] })
|
|
1239
|
+
}), a && /* @__PURE__ */ W("div", {
|
|
1238
1240
|
className: "flex items-start gap-3 rounded-lg border border-status-success-bg bg-status-success-bg-subtle px-4 py-3",
|
|
1239
|
-
children: [/* @__PURE__ */
|
|
1241
|
+
children: [/* @__PURE__ */ U(F, {
|
|
1240
1242
|
size: 16,
|
|
1241
1243
|
className: "mt-0.5 shrink-0 text-status-success-text"
|
|
1242
|
-
}), /* @__PURE__ */
|
|
1244
|
+
}), /* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("p", {
|
|
1243
1245
|
className: "text-sm font-medium text-status-success-text",
|
|
1244
1246
|
children: s("devportal.allSetToSubmit", "You're all set!")
|
|
1245
|
-
}), /* @__PURE__ */
|
|
1247
|
+
}), /* @__PURE__ */ U("p", {
|
|
1246
1248
|
className: "mt-0.5 text-xs text-text-secondary",
|
|
1247
1249
|
children: s("devportal.allSetDesc", "Store listing, versions, and pricing are complete. Head to the top of the page and click Submit for Review.")
|
|
1248
1250
|
})] })]
|
|
@@ -1250,7 +1252,7 @@ var Ue = [
|
|
|
1250
1252
|
})
|
|
1251
1253
|
]
|
|
1252
1254
|
});
|
|
1253
|
-
},
|
|
1255
|
+
}, Qe = ({ appId: e, onNavigate: n, pricingDone: i = !1, onNavigateToPricing: a }) => {
|
|
1254
1256
|
let { t: o } = P(), s = (e, t) => {
|
|
1255
1257
|
let n = o(e);
|
|
1256
1258
|
return n === e ? t : n;
|
|
@@ -1258,80 +1260,80 @@ var Ue = [
|
|
|
1258
1260
|
variables: { applicationId: e },
|
|
1259
1261
|
fetchPolicy: "cache-and-network"
|
|
1260
1262
|
});
|
|
1261
|
-
if (u) return /* @__PURE__ */
|
|
1262
|
-
if (d) return /* @__PURE__ */
|
|
1263
|
+
if (u) return /* @__PURE__ */ U(J, { message: s("devportal.loadingVersions", "Loading versions…") });
|
|
1264
|
+
if (d) return /* @__PURE__ */ U(Y, { message: d.message });
|
|
1263
1265
|
let f = (l?.application?.versions?.edges ?? []).map((e) => e.node);
|
|
1264
|
-
return /* @__PURE__ */
|
|
1266
|
+
return /* @__PURE__ */ W("div", {
|
|
1265
1267
|
className: "space-y-4",
|
|
1266
1268
|
children: [
|
|
1267
|
-
/* @__PURE__ */
|
|
1269
|
+
/* @__PURE__ */ W("div", {
|
|
1268
1270
|
className: "flex items-center justify-between",
|
|
1269
|
-
children: [/* @__PURE__ */
|
|
1271
|
+
children: [/* @__PURE__ */ W("p", {
|
|
1270
1272
|
className: "text-sm text-text-secondary",
|
|
1271
1273
|
children: [
|
|
1272
1274
|
f.length,
|
|
1273
1275
|
" ",
|
|
1274
1276
|
f.length === 1 ? s("devportal.version", "version") : s("devportal.versions", "versions")
|
|
1275
1277
|
]
|
|
1276
|
-
}), /* @__PURE__ */
|
|
1278
|
+
}), /* @__PURE__ */ W("button", {
|
|
1277
1279
|
onClick: () => n(`/apps/${e}/versions`),
|
|
1278
1280
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 transition-colors",
|
|
1279
|
-
children: [/* @__PURE__ */
|
|
1281
|
+
children: [/* @__PURE__ */ U(B, { size: 16 }), s("devportal.uploadVersion", "Upload Version")]
|
|
1280
1282
|
})]
|
|
1281
1283
|
}),
|
|
1282
|
-
f.length > 0 ? /* @__PURE__ */
|
|
1284
|
+
f.length > 0 ? /* @__PURE__ */ U("div", {
|
|
1283
1285
|
className: "overflow-hidden rounded-lg border border-border-subtle",
|
|
1284
|
-
children: /* @__PURE__ */
|
|
1286
|
+
children: /* @__PURE__ */ W("table", {
|
|
1285
1287
|
className: "w-full text-sm",
|
|
1286
|
-
children: [/* @__PURE__ */
|
|
1288
|
+
children: [/* @__PURE__ */ U("thead", { children: /* @__PURE__ */ W("tr", {
|
|
1287
1289
|
className: "border-b border-border-subtle bg-bg-sunken/50",
|
|
1288
1290
|
children: [
|
|
1289
|
-
/* @__PURE__ */
|
|
1291
|
+
/* @__PURE__ */ U("th", {
|
|
1290
1292
|
className: "px-4 py-3 text-left font-medium text-text-secondary",
|
|
1291
1293
|
children: s("devportal.version", "Version")
|
|
1292
1294
|
}),
|
|
1293
|
-
/* @__PURE__ */
|
|
1295
|
+
/* @__PURE__ */ U("th", {
|
|
1294
1296
|
className: "px-4 py-3 text-left font-medium text-text-secondary",
|
|
1295
1297
|
children: s("devportal.status", "Status")
|
|
1296
1298
|
}),
|
|
1297
|
-
/* @__PURE__ */
|
|
1299
|
+
/* @__PURE__ */ U("th", {
|
|
1298
1300
|
className: "px-4 py-3 text-left font-medium text-text-secondary",
|
|
1299
1301
|
children: s("devportal.released", "Released")
|
|
1300
1302
|
}),
|
|
1301
|
-
/* @__PURE__ */
|
|
1303
|
+
/* @__PURE__ */ U("th", {
|
|
1302
1304
|
className: "px-4 py-3 text-left font-medium text-text-secondary",
|
|
1303
1305
|
children: s("devportal.flags", "Flags")
|
|
1304
1306
|
})
|
|
1305
1307
|
]
|
|
1306
|
-
}) }), /* @__PURE__ */
|
|
1308
|
+
}) }), /* @__PURE__ */ U("tbody", {
|
|
1307
1309
|
className: "divide-y divide-border-subtle",
|
|
1308
|
-
children: f.map((e) => /* @__PURE__ */
|
|
1309
|
-
/* @__PURE__ */
|
|
1310
|
+
children: f.map((e) => /* @__PURE__ */ W(H, { children: [
|
|
1311
|
+
/* @__PURE__ */ W("tr", {
|
|
1310
1312
|
className: "hover:bg-bg-sunken/30 transition-colors",
|
|
1311
1313
|
children: [
|
|
1312
|
-
/* @__PURE__ */
|
|
1314
|
+
/* @__PURE__ */ U("td", {
|
|
1313
1315
|
className: "px-4 py-3 font-mono font-medium",
|
|
1314
1316
|
children: e.version
|
|
1315
1317
|
}),
|
|
1316
|
-
/* @__PURE__ */
|
|
1318
|
+
/* @__PURE__ */ U("td", {
|
|
1317
1319
|
className: "px-4 py-3",
|
|
1318
|
-
children: /* @__PURE__ */
|
|
1320
|
+
children: /* @__PURE__ */ U("span", {
|
|
1319
1321
|
className: t("inline-flex rounded-full px-2 py-0.5 text-xs font-medium", e.status === "published" ? "bg-status-success-bg-subtle text-status-success-text" : e.status === "pending_review" ? "bg-status-info-bg-subtle text-status-info-text" : e.status === "rejected" ? "bg-status-error-bg-subtle text-status-error-text" : e.status === "deprecated" ? "bg-bg-sunken text-text-secondary" : "bg-status-warning-bg-subtle text-status-warning-text"),
|
|
1320
1322
|
children: e.status === "pending_review" ? "In Review" : e.status
|
|
1321
1323
|
})
|
|
1322
1324
|
}),
|
|
1323
|
-
/* @__PURE__ */
|
|
1325
|
+
/* @__PURE__ */ U("td", {
|
|
1324
1326
|
className: "px-4 py-3 text-text-secondary",
|
|
1325
1327
|
children: e.publishedAt ? new Date(e.publishedAt).toLocaleDateString() : new Date(e.createdAt).toLocaleDateString()
|
|
1326
1328
|
}),
|
|
1327
|
-
/* @__PURE__ */
|
|
1329
|
+
/* @__PURE__ */ U("td", {
|
|
1328
1330
|
className: "px-4 py-3",
|
|
1329
|
-
children: /* @__PURE__ */
|
|
1331
|
+
children: /* @__PURE__ */ W("div", {
|
|
1330
1332
|
className: "flex gap-1.5",
|
|
1331
|
-
children: [e.isLatest && /* @__PURE__ */
|
|
1333
|
+
children: [e.isLatest && /* @__PURE__ */ U("span", {
|
|
1332
1334
|
className: "rounded-full bg-action-primary-bg/10 px-2 py-0.5 text-xs text-primary font-medium",
|
|
1333
1335
|
children: "latest"
|
|
1334
|
-
}), e.isStable && /* @__PURE__ */
|
|
1336
|
+
}), e.isStable && /* @__PURE__ */ U("span", {
|
|
1335
1337
|
className: "rounded-full bg-status-success-bg-subtle px-2 py-0.5 text-xs text-status-success-text font-medium",
|
|
1336
1338
|
children: "stable"
|
|
1337
1339
|
})]
|
|
@@ -1339,26 +1341,26 @@ var Ue = [
|
|
|
1339
1341
|
})
|
|
1340
1342
|
]
|
|
1341
1343
|
}, e.id),
|
|
1342
|
-
e.status === "rejected" && e.reviewNotes && /* @__PURE__ */
|
|
1344
|
+
e.status === "rejected" && e.reviewNotes && /* @__PURE__ */ U("tr", {
|
|
1343
1345
|
className: "bg-status-error-bg-subtle/40",
|
|
1344
|
-
children: /* @__PURE__ */
|
|
1346
|
+
children: /* @__PURE__ */ U("td", {
|
|
1345
1347
|
colSpan: 4,
|
|
1346
1348
|
className: "px-4 py-2",
|
|
1347
|
-
children: /* @__PURE__ */
|
|
1349
|
+
children: /* @__PURE__ */ W("p", {
|
|
1348
1350
|
className: "text-xs text-status-error-text",
|
|
1349
|
-
children: [/* @__PURE__ */
|
|
1351
|
+
children: [/* @__PURE__ */ W("span", {
|
|
1350
1352
|
className: "font-semibold",
|
|
1351
1353
|
children: ["Review feedback:", " "]
|
|
1352
1354
|
}), e.reviewNotes]
|
|
1353
1355
|
})
|
|
1354
1356
|
})
|
|
1355
1357
|
}, `${e.id}-notes`),
|
|
1356
|
-
e.status === "pending_review" && /* @__PURE__ */
|
|
1358
|
+
e.status === "pending_review" && /* @__PURE__ */ U("tr", {
|
|
1357
1359
|
className: "bg-status-info-bg-subtle/30",
|
|
1358
|
-
children: /* @__PURE__ */
|
|
1360
|
+
children: /* @__PURE__ */ U("td", {
|
|
1359
1361
|
colSpan: 4,
|
|
1360
1362
|
className: "px-4 py-2",
|
|
1361
|
-
children: /* @__PURE__ */
|
|
1363
|
+
children: /* @__PURE__ */ U("p", {
|
|
1362
1364
|
className: "text-xs text-status-info-text",
|
|
1363
1365
|
children: "Submitted for platform review — you will be notified once approved or if changes are needed."
|
|
1364
1366
|
})
|
|
@@ -1367,53 +1369,53 @@ var Ue = [
|
|
|
1367
1369
|
] }))
|
|
1368
1370
|
})]
|
|
1369
1371
|
})
|
|
1370
|
-
}) : /* @__PURE__ */
|
|
1372
|
+
}) : /* @__PURE__ */ U(r, {
|
|
1371
1373
|
illustration: "empty-generic",
|
|
1372
|
-
icon: /* @__PURE__ */
|
|
1374
|
+
icon: /* @__PURE__ */ U(Oe, { size: 32 }),
|
|
1373
1375
|
title: s("devportal.noVersions", "No versions yet"),
|
|
1374
1376
|
description: s("devportal.noVersionsDescription", "Upload your first version to make this item available for review and distribution."),
|
|
1375
|
-
action: /* @__PURE__ */
|
|
1377
|
+
action: /* @__PURE__ */ W("button", {
|
|
1376
1378
|
onClick: () => n(`/apps/${e}/versions`),
|
|
1377
1379
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90",
|
|
1378
|
-
children: [/* @__PURE__ */
|
|
1380
|
+
children: [/* @__PURE__ */ U(B, { size: 16 }), s("devportal.uploadVersion", "Upload Version")]
|
|
1379
1381
|
})
|
|
1380
1382
|
}),
|
|
1381
|
-
f.length > 0 && !i && a && /* @__PURE__ */
|
|
1383
|
+
f.length > 0 && !i && a && /* @__PURE__ */ W("div", {
|
|
1382
1384
|
className: "mt-4 flex items-center gap-3 rounded-lg border border-border-subtle bg-bg-sunken px-4 py-3",
|
|
1383
1385
|
children: [
|
|
1384
|
-
/* @__PURE__ */
|
|
1386
|
+
/* @__PURE__ */ U(I, {
|
|
1385
1387
|
size: 16,
|
|
1386
1388
|
className: "shrink-0 text-primary"
|
|
1387
1389
|
}),
|
|
1388
|
-
/* @__PURE__ */
|
|
1390
|
+
/* @__PURE__ */ U("p", {
|
|
1389
1391
|
className: "flex-1 text-sm text-text-secondary",
|
|
1390
1392
|
children: s("devportal.versionsNextPricing", "You've got versions covered. Now set your pricing before you can submit.")
|
|
1391
1393
|
}),
|
|
1392
|
-
/* @__PURE__ */
|
|
1394
|
+
/* @__PURE__ */ W("button", {
|
|
1393
1395
|
type: "button",
|
|
1394
1396
|
onClick: a,
|
|
1395
1397
|
className: "inline-flex items-center gap-1 text-sm font-medium text-primary hover:underline underline-offset-2 whitespace-nowrap",
|
|
1396
|
-
children: [s("devportal.nextSetPricing", "Set Pricing"), /* @__PURE__ */
|
|
1398
|
+
children: [s("devportal.nextSetPricing", "Set Pricing"), /* @__PURE__ */ U(_e, { size: 15 })]
|
|
1397
1399
|
})
|
|
1398
1400
|
]
|
|
1399
1401
|
})
|
|
1400
1402
|
]
|
|
1401
1403
|
});
|
|
1402
|
-
},
|
|
1404
|
+
}, $e = ({ appId: e, onNavigate: t }) => {
|
|
1403
1405
|
let { t: n } = P(), r = (e, t) => {
|
|
1404
1406
|
let r = n(e);
|
|
1405
1407
|
return r === e ? t : r;
|
|
1406
1408
|
}, { data: i, loading: a, error: o } = u({ variables: { applicationId: e } });
|
|
1407
|
-
return a ? /* @__PURE__ */
|
|
1409
|
+
return a ? /* @__PURE__ */ U(J, { message: r("devportal.loadingWebhooks", "Loading webhooks...") }) : o ? /* @__PURE__ */ U(Y, { message: o.message }) : /* @__PURE__ */ U(Z, {
|
|
1408
1410
|
appId: e,
|
|
1409
|
-
webhooks: (i?.webhooks ?? []).map(
|
|
1411
|
+
webhooks: (i?.webhooks ?? []).map(We),
|
|
1410
1412
|
onNavigate: t
|
|
1411
1413
|
});
|
|
1412
|
-
},
|
|
1414
|
+
}, et = ({ authAppId: e, appName: t, onGrantDelegation: n, onNavigate: a }) => {
|
|
1413
1415
|
let { t: o } = P(), s = (e, t) => {
|
|
1414
1416
|
let n = o(e);
|
|
1415
1417
|
return n === e ? t : n;
|
|
1416
|
-
}, { data: c, loading: l, error: u, refetch: d } = i(), [f] = m(), [p, h] = N([]), [g, _] = N(!1), [v, y] = N(/* @__PURE__ */ new Set()), [b, x] = N(null), S = j(() => c?.currentUserDelegations?.delegations ? c.currentUserDelegations.delegations.filter((t) => t.appId === e).map(
|
|
1418
|
+
}, { data: c, loading: l, error: u, refetch: d } = i(), [f] = m(), [p, h] = N([]), [g, _] = N(!1), [v, y] = N(/* @__PURE__ */ new Set()), [b, x] = N(null), S = j(() => c?.currentUserDelegations?.delegations ? c.currentUserDelegations.delegations.filter((t) => t.appId === e).map(K) : [], [e, c]), C = j(() => S.filter((e) => e.status === "ACTIVE"), [S]), w = j(() => C.filter((e) => v.has(e.id)), [C, v]), T = C.length > 0 && C.every((e) => v.has(e.id)), E = C.some((e) => v.has(e.id)) && !T, D = A((e, t) => {
|
|
1417
1419
|
y((n) => {
|
|
1418
1420
|
let r = new Set(n);
|
|
1419
1421
|
return t ? r.add(e) : r.delete(e), r;
|
|
@@ -1439,19 +1441,19 @@ var Ue = [
|
|
|
1439
1441
|
_(!1);
|
|
1440
1442
|
}
|
|
1441
1443
|
}, [f, d]);
|
|
1442
|
-
return e ? l ? /* @__PURE__ */
|
|
1443
|
-
b && /* @__PURE__ */
|
|
1444
|
+
return e ? l ? /* @__PURE__ */ U(J, { message: s("devportal.loadingDelegations", "Loading delegations...") }) : u ? /* @__PURE__ */ U(Y, { message: u.message }) : /* @__PURE__ */ W(H, { children: [
|
|
1445
|
+
b && /* @__PURE__ */ U("div", {
|
|
1444
1446
|
className: "rounded-lg border border-border-subtle bg-status-success-bg-subtle p-3 text-sm text-status-success-text",
|
|
1445
|
-
children: /* @__PURE__ */
|
|
1447
|
+
children: /* @__PURE__ */ W("div", {
|
|
1446
1448
|
className: "flex items-center justify-between gap-3",
|
|
1447
|
-
children: [/* @__PURE__ */
|
|
1449
|
+
children: [/* @__PURE__ */ U("span", { children: b }), /* @__PURE__ */ U("button", {
|
|
1448
1450
|
onClick: () => x(null),
|
|
1449
1451
|
className: "text-status-success-text hover:text-status-success-text",
|
|
1450
1452
|
children: s("devportal.dismiss", "Dismiss")
|
|
1451
1453
|
})]
|
|
1452
1454
|
})
|
|
1453
1455
|
}),
|
|
1454
|
-
/* @__PURE__ */
|
|
1456
|
+
/* @__PURE__ */ U(rt, {
|
|
1455
1457
|
appName: t,
|
|
1456
1458
|
delegations: S,
|
|
1457
1459
|
onGrantDelegation: n,
|
|
@@ -1464,7 +1466,7 @@ var Ue = [
|
|
|
1464
1466
|
allVisibleSelected: T,
|
|
1465
1467
|
partiallySelected: E
|
|
1466
1468
|
}),
|
|
1467
|
-
/* @__PURE__ */
|
|
1469
|
+
/* @__PURE__ */ U(ae, {
|
|
1468
1470
|
open: p.length > 0,
|
|
1469
1471
|
onOpenChange: (e) => {
|
|
1470
1472
|
e || h([]);
|
|
@@ -1479,18 +1481,18 @@ var Ue = [
|
|
|
1479
1481
|
variant: "destructive",
|
|
1480
1482
|
loading: g
|
|
1481
1483
|
})
|
|
1482
|
-
] }) : /* @__PURE__ */
|
|
1484
|
+
] }) : /* @__PURE__ */ U(r, {
|
|
1483
1485
|
illustration: "empty-generic",
|
|
1484
|
-
icon: /* @__PURE__ */
|
|
1486
|
+
icon: /* @__PURE__ */ U(z, { size: 32 }),
|
|
1485
1487
|
title: s("devportal.linkAuthAppFirst", "Link an auth app first"),
|
|
1486
1488
|
description: s("devportal.linkAuthAppFirstDescription", "Delegations are managed through auth apps. Create or link an auth app before granting app-as-user access."),
|
|
1487
|
-
action: /* @__PURE__ */
|
|
1489
|
+
action: /* @__PURE__ */ W("button", {
|
|
1488
1490
|
onClick: () => a("/oauth"),
|
|
1489
1491
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90",
|
|
1490
|
-
children: [/* @__PURE__ */
|
|
1492
|
+
children: [/* @__PURE__ */ U(L, { size: 16 }), s("devportal.manageOAuthApps", "Manage OAuth Apps")]
|
|
1491
1493
|
})
|
|
1492
1494
|
});
|
|
1493
|
-
},
|
|
1495
|
+
}, tt = ({ appId: e }) => {
|
|
1494
1496
|
let { t } = P(), n = (e, n) => {
|
|
1495
1497
|
let r = t(e);
|
|
1496
1498
|
return r === e ? n : r;
|
|
@@ -1503,45 +1505,45 @@ var Ue = [
|
|
|
1503
1505
|
}, [r]).toISOString(),
|
|
1504
1506
|
endDate: r.toISOString()
|
|
1505
1507
|
} });
|
|
1506
|
-
return a ? /* @__PURE__ */
|
|
1507
|
-
},
|
|
1508
|
+
return a ? /* @__PURE__ */ U(J, { message: n("devportal.loadingAnalytics", "Loading analytics...") }) : s ? /* @__PURE__ */ U(Y, { message: s.message }) : /* @__PURE__ */ U(it, { analytics: (i?.applicationAnalytics ?? []).map(G) });
|
|
1509
|
+
}, nt = ({ app: e, appId: t, refetch: n }) => {
|
|
1508
1510
|
let { t: r } = P(), i = (e, t) => {
|
|
1509
1511
|
let n = r(e);
|
|
1510
1512
|
return n === e ? t : n;
|
|
1511
1513
|
}, [a, { loading: o }] = g(), [s, { loading: c }] = y(), [l, u] = N(!1);
|
|
1512
|
-
return /* @__PURE__ */
|
|
1514
|
+
return /* @__PURE__ */ W("div", {
|
|
1513
1515
|
className: "space-y-6",
|
|
1514
|
-
children: [e.appType === "WORKFLOW" && /* @__PURE__ */
|
|
1516
|
+
children: [e.appType === "WORKFLOW" && /* @__PURE__ */ U("div", {
|
|
1515
1517
|
className: "rounded-lg border border-border-subtle bg-bg-elevated p-4",
|
|
1516
|
-
children: /* @__PURE__ */
|
|
1518
|
+
children: /* @__PURE__ */ W("div", {
|
|
1517
1519
|
className: "flex items-start justify-between gap-4",
|
|
1518
|
-
children: [/* @__PURE__ */
|
|
1520
|
+
children: [/* @__PURE__ */ W("div", {
|
|
1519
1521
|
className: "flex items-start gap-3",
|
|
1520
|
-
children: [/* @__PURE__ */
|
|
1522
|
+
children: [/* @__PURE__ */ U("div", {
|
|
1521
1523
|
className: "mt-0.5 flex h-8 w-8 flex-shrink-0 items-center justify-center rounded-full bg-action-primary-bg-subtle",
|
|
1522
|
-
children: /* @__PURE__ */
|
|
1524
|
+
children: /* @__PURE__ */ U(Te, {
|
|
1523
1525
|
size: 15,
|
|
1524
1526
|
className: "text-action-primary-text"
|
|
1525
1527
|
})
|
|
1526
|
-
}), /* @__PURE__ */
|
|
1527
|
-
/* @__PURE__ */
|
|
1528
|
+
}), /* @__PURE__ */ W("div", { children: [
|
|
1529
|
+
/* @__PURE__ */ U("p", {
|
|
1528
1530
|
className: "text-sm font-medium text-text-primary",
|
|
1529
1531
|
children: i("devportal.shareWorkflow.title", "Share as Public Link")
|
|
1530
1532
|
}),
|
|
1531
|
-
/* @__PURE__ */
|
|
1533
|
+
/* @__PURE__ */ U("p", {
|
|
1532
1534
|
className: "mt-0.5 text-xs text-text-secondary",
|
|
1533
1535
|
children: e.visibility === "UNLISTED" ? i("devportal.shareWorkflow.activeDesc", "Anyone with the link can preview and copy this workflow into their FluidGrids workspace.") : i("devportal.shareWorkflow.inactiveDesc", "Generate a public link anyone can use to copy this workflow into their own FluidGrids workspace — no store review needed.")
|
|
1534
1536
|
}),
|
|
1535
|
-
e.visibility === "UNLISTED" && (e.status === "PUBLISHED" || e.status === "SUBMITTED") && /* @__PURE__ */
|
|
1537
|
+
e.visibility === "UNLISTED" && (e.status === "PUBLISHED" || e.status === "SUBMITTED") && /* @__PURE__ */ U("p", {
|
|
1536
1538
|
className: "mt-1.5 text-xs text-status-warning-text",
|
|
1537
1539
|
children: i("devportal.shareWorkflow.stopSharingPublishedNote", "This app is in the marketplace. Stopping the share link will keep it there — visibility will switch to Public so the store listing is preserved.")
|
|
1538
1540
|
}),
|
|
1539
|
-
e.visibility === "UNLISTED" && /* @__PURE__ */
|
|
1541
|
+
e.visibility === "UNLISTED" && /* @__PURE__ */ W("div", {
|
|
1540
1542
|
className: "mt-2 flex items-center gap-2",
|
|
1541
|
-
children: [/* @__PURE__ */
|
|
1543
|
+
children: [/* @__PURE__ */ U("code", {
|
|
1542
1544
|
className: "rounded bg-bg-canvas px-2 py-1 text-xs text-text-secondary",
|
|
1543
1545
|
children: `${window.location.protocol}//${window.location.host}/shared/${t}`
|
|
1544
|
-
}), /* @__PURE__ */
|
|
1546
|
+
}), /* @__PURE__ */ W("button", {
|
|
1545
1547
|
type: "button",
|
|
1546
1548
|
className: "flex items-center gap-1 rounded px-2 py-1 text-xs text-action-primary-text hover:bg-action-primary-bg-subtle transition-colors",
|
|
1547
1549
|
onClick: () => {
|
|
@@ -1550,11 +1552,11 @@ var Ue = [
|
|
|
1550
1552
|
u(!0), setTimeout(() => u(!1), 2e3);
|
|
1551
1553
|
});
|
|
1552
1554
|
},
|
|
1553
|
-
children: [
|
|
1555
|
+
children: [U(l ? F : ye, { size: 12 }), l ? i("devportal.copied", "Copied!") : i("devportal.copyLink", "Copy Link")]
|
|
1554
1556
|
})]
|
|
1555
1557
|
})
|
|
1556
1558
|
] })]
|
|
1557
|
-
}), /* @__PURE__ */
|
|
1559
|
+
}), /* @__PURE__ */ U("button", {
|
|
1558
1560
|
type: "button",
|
|
1559
1561
|
disabled: o || c || !e.manifest,
|
|
1560
1562
|
title: e.manifest ? void 0 : i("devportal.shareWorkflow.noManifestHint", "Add a workflow manifest before sharing"),
|
|
@@ -1562,67 +1564,67 @@ var Ue = [
|
|
|
1562
1564
|
e.visibility === "UNLISTED" ? s({ variables: { id: t } }).then(() => n()) : a({ variables: { id: t } }).then(() => n());
|
|
1563
1565
|
},
|
|
1564
1566
|
className: `flex-shrink-0 rounded-full px-3 py-1.5 text-xs font-medium transition-colors ${e.visibility === "UNLISTED" ? "border border-status-error-bg text-status-error-text hover:bg-status-error-bg-subtle" : "bg-action-primary-bg text-text-on-action hover:opacity-90 disabled:opacity-50"}`,
|
|
1565
|
-
children: o || c ? /* @__PURE__ */
|
|
1567
|
+
children: o || c ? /* @__PURE__ */ U(R, {
|
|
1566
1568
|
size: 12,
|
|
1567
1569
|
className: "animate-spin"
|
|
1568
1570
|
}) : e.visibility === "UNLISTED" ? i("devportal.shareWorkflow.stopSharing", "Stop Sharing") : i("devportal.shareWorkflow.share", "Share Link")
|
|
1569
1571
|
})]
|
|
1570
1572
|
})
|
|
1571
|
-
}), /* @__PURE__ */
|
|
1573
|
+
}), /* @__PURE__ */ W("div", {
|
|
1572
1574
|
className: "grid gap-6 lg:grid-cols-3",
|
|
1573
|
-
children: [/* @__PURE__ */
|
|
1575
|
+
children: [/* @__PURE__ */ W("div", {
|
|
1574
1576
|
className: "lg:col-span-2 space-y-6",
|
|
1575
1577
|
children: [
|
|
1576
|
-
/* @__PURE__ */
|
|
1578
|
+
/* @__PURE__ */ U(Ve, { children: /* @__PURE__ */ W("div", {
|
|
1577
1579
|
className: "grid gap-4 sm:grid-cols-4",
|
|
1578
1580
|
children: [
|
|
1579
|
-
/* @__PURE__ */
|
|
1581
|
+
/* @__PURE__ */ U(Q, {
|
|
1580
1582
|
label: i("devportal.totalInstalls", "Total Installs"),
|
|
1581
1583
|
value: e.installCount.toLocaleString()
|
|
1582
1584
|
}),
|
|
1583
|
-
/* @__PURE__ */
|
|
1585
|
+
/* @__PURE__ */ U(Q, {
|
|
1584
1586
|
label: i("devportal.activeInstalls", "Active Installs"),
|
|
1585
1587
|
value: e.activeInstallCount.toLocaleString()
|
|
1586
1588
|
}),
|
|
1587
|
-
/* @__PURE__ */
|
|
1589
|
+
/* @__PURE__ */ U(Q, {
|
|
1588
1590
|
label: i("devportal.averageRating", "Average Rating"),
|
|
1589
1591
|
value: e.averageRating ? `${e.averageRating.toFixed(1)} ★` : i("devportal.notAvailable", "N/A")
|
|
1590
1592
|
}),
|
|
1591
|
-
/* @__PURE__ */
|
|
1593
|
+
/* @__PURE__ */ U(Q, {
|
|
1592
1594
|
label: i("devportal.reviews", "Reviews"),
|
|
1593
1595
|
value: e.reviewCount.toString()
|
|
1594
1596
|
})
|
|
1595
1597
|
]
|
|
1596
1598
|
}) }),
|
|
1597
|
-
/* @__PURE__ */
|
|
1599
|
+
/* @__PURE__ */ U(S, {
|
|
1598
1600
|
title: i("devportal.description", "Description"),
|
|
1599
|
-
children: /* @__PURE__ */
|
|
1601
|
+
children: e.description ? /* @__PURE__ */ U(fe, {
|
|
1600
1602
|
className: "prose prose-sm max-w-none",
|
|
1601
|
-
children:
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1603
|
+
children: e.description
|
|
1604
|
+
}) : /* @__PURE__ */ U("p", {
|
|
1605
|
+
className: "text-sm text-text-secondary",
|
|
1606
|
+
children: i("devportal.noDescriptionProvided", "No description provided.")
|
|
1605
1607
|
})
|
|
1606
1608
|
}),
|
|
1607
|
-
/* @__PURE__ */
|
|
1609
|
+
/* @__PURE__ */ U(S, {
|
|
1608
1610
|
title: i("devportal.tagsAndKeywords", "Tags & Keywords"),
|
|
1609
|
-
children: /* @__PURE__ */
|
|
1611
|
+
children: /* @__PURE__ */ W("div", {
|
|
1610
1612
|
className: "space-y-3",
|
|
1611
|
-
children: [e.tags.length > 0 && /* @__PURE__ */
|
|
1613
|
+
children: [e.tags.length > 0 && /* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("p", {
|
|
1612
1614
|
className: "text-xs text-text-secondary mb-2",
|
|
1613
1615
|
children: i("devportal.tags", "Tags")
|
|
1614
|
-
}), /* @__PURE__ */
|
|
1616
|
+
}), /* @__PURE__ */ U("div", {
|
|
1615
1617
|
className: "flex flex-wrap gap-2",
|
|
1616
|
-
children: e.tags.map((e) => /* @__PURE__ */
|
|
1618
|
+
children: e.tags.map((e) => /* @__PURE__ */ U("span", {
|
|
1617
1619
|
className: "rounded-full bg-action-primary-bg/10 px-3 py-1 text-xs font-medium text-primary",
|
|
1618
1620
|
children: e
|
|
1619
1621
|
}, e))
|
|
1620
|
-
})] }), e.keywords.length > 0 && /* @__PURE__ */
|
|
1622
|
+
})] }), e.keywords.length > 0 && /* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("p", {
|
|
1621
1623
|
className: "text-xs text-text-secondary mb-2",
|
|
1622
1624
|
children: i("devportal.keywords", "Keywords")
|
|
1623
|
-
}), /* @__PURE__ */
|
|
1625
|
+
}), /* @__PURE__ */ U("div", {
|
|
1624
1626
|
className: "flex flex-wrap gap-2",
|
|
1625
|
-
children: e.keywords.map((e) => /* @__PURE__ */
|
|
1627
|
+
children: e.keywords.map((e) => /* @__PURE__ */ U("span", {
|
|
1626
1628
|
className: "rounded-full bg-bg-sunken px-3 py-1 text-xs",
|
|
1627
1629
|
children: e
|
|
1628
1630
|
}, e))
|
|
@@ -1630,14 +1632,14 @@ var Ue = [
|
|
|
1630
1632
|
})
|
|
1631
1633
|
})
|
|
1632
1634
|
]
|
|
1633
|
-
}), /* @__PURE__ */
|
|
1635
|
+
}), /* @__PURE__ */ W("div", {
|
|
1634
1636
|
className: "space-y-6",
|
|
1635
|
-
children: [/* @__PURE__ */
|
|
1637
|
+
children: [/* @__PURE__ */ U(S, {
|
|
1636
1638
|
title: i("devportal.details", "Details"),
|
|
1637
|
-
children: /* @__PURE__ */
|
|
1639
|
+
children: /* @__PURE__ */ U(ne, { items: [
|
|
1638
1640
|
{
|
|
1639
1641
|
label: i("devportal.appId", "App ID"),
|
|
1640
|
-
value: /* @__PURE__ */
|
|
1642
|
+
value: /* @__PURE__ */ U("code", {
|
|
1641
1643
|
className: "text-xs",
|
|
1642
1644
|
children: e.id
|
|
1643
1645
|
})
|
|
@@ -1673,32 +1675,32 @@ var Ue = [
|
|
|
1673
1675
|
value: e.publishedAt ? new Date(e.publishedAt).toLocaleDateString() : i("devportal.notPublished", "Not published")
|
|
1674
1676
|
}
|
|
1675
1677
|
] })
|
|
1676
|
-
}), /* @__PURE__ */
|
|
1678
|
+
}), /* @__PURE__ */ U(S, {
|
|
1677
1679
|
title: i("devportal.links", "Links"),
|
|
1678
|
-
children: /* @__PURE__ */
|
|
1680
|
+
children: /* @__PURE__ */ W("div", {
|
|
1679
1681
|
className: "space-y-2",
|
|
1680
1682
|
children: [
|
|
1681
|
-
e.websiteUrl && /* @__PURE__ */
|
|
1683
|
+
e.websiteUrl && /* @__PURE__ */ U($, {
|
|
1682
1684
|
label: i("devportal.website", "Website"),
|
|
1683
1685
|
url: e.websiteUrl
|
|
1684
1686
|
}),
|
|
1685
|
-
e.documentationUrl && /* @__PURE__ */
|
|
1687
|
+
e.documentationUrl && /* @__PURE__ */ U($, {
|
|
1686
1688
|
label: i("devportal.documentation", "Documentation"),
|
|
1687
1689
|
url: e.documentationUrl
|
|
1688
1690
|
}),
|
|
1689
|
-
e.supportUrl && /* @__PURE__ */
|
|
1691
|
+
e.supportUrl && /* @__PURE__ */ U($, {
|
|
1690
1692
|
label: i("devportal.support", "Support"),
|
|
1691
1693
|
url: e.supportUrl
|
|
1692
1694
|
}),
|
|
1693
|
-
e.githubUrl && /* @__PURE__ */
|
|
1695
|
+
e.githubUrl && /* @__PURE__ */ U($, {
|
|
1694
1696
|
label: i("devportal.github", "GitHub"),
|
|
1695
1697
|
url: e.githubUrl
|
|
1696
1698
|
}),
|
|
1697
|
-
e.privacyPolicyUrl && /* @__PURE__ */
|
|
1699
|
+
e.privacyPolicyUrl && /* @__PURE__ */ U($, {
|
|
1698
1700
|
label: i("devportal.privacyPolicy", "Privacy Policy"),
|
|
1699
1701
|
url: e.privacyPolicyUrl
|
|
1700
1702
|
}),
|
|
1701
|
-
e.termsOfServiceUrl && /* @__PURE__ */
|
|
1703
|
+
e.termsOfServiceUrl && /* @__PURE__ */ U($, {
|
|
1702
1704
|
label: i("devportal.termsOfService", "Terms of Service"),
|
|
1703
1705
|
url: e.termsOfServiceUrl
|
|
1704
1706
|
})
|
|
@@ -1713,11 +1715,11 @@ var Ue = [
|
|
|
1713
1715
|
let n = i(e);
|
|
1714
1716
|
return n === e ? t : n;
|
|
1715
1717
|
};
|
|
1716
|
-
return /* @__PURE__ */
|
|
1718
|
+
return /* @__PURE__ */ W("div", {
|
|
1717
1719
|
className: "space-y-6",
|
|
1718
|
-
children: [/* @__PURE__ */
|
|
1720
|
+
children: [/* @__PURE__ */ W("div", {
|
|
1719
1721
|
className: "flex items-center justify-between",
|
|
1720
|
-
children: [/* @__PURE__ */
|
|
1722
|
+
children: [/* @__PURE__ */ W("p", {
|
|
1721
1723
|
className: "text-sm text-text-secondary",
|
|
1722
1724
|
children: [
|
|
1723
1725
|
t.length,
|
|
@@ -1726,81 +1728,81 @@ var Ue = [
|
|
|
1726
1728
|
" ",
|
|
1727
1729
|
a("devportal.configured", "configured")
|
|
1728
1730
|
]
|
|
1729
|
-
}), /* @__PURE__ */
|
|
1731
|
+
}), /* @__PURE__ */ W("button", {
|
|
1730
1732
|
onClick: () => n(`/apps/${e}/webhooks/new`),
|
|
1731
1733
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 transition-colors",
|
|
1732
|
-
children: [/* @__PURE__ */
|
|
1734
|
+
children: [/* @__PURE__ */ U(ke, { size: 16 }), a("devportal.addWebhook", "Add Webhook")]
|
|
1733
1735
|
})]
|
|
1734
|
-
}), t.length > 0 ? /* @__PURE__ */
|
|
1736
|
+
}), t.length > 0 ? /* @__PURE__ */ U("div", {
|
|
1735
1737
|
className: "space-y-4",
|
|
1736
|
-
children: t.map((t) => /* @__PURE__ */
|
|
1738
|
+
children: t.map((t) => /* @__PURE__ */ W("div", {
|
|
1737
1739
|
className: "rounded-card border border-border-seam bg-bg-surface p-4 space-y-4 shadow-[var(--shadow-pop)]",
|
|
1738
1740
|
children: [
|
|
1739
|
-
/* @__PURE__ */
|
|
1741
|
+
/* @__PURE__ */ W("div", {
|
|
1740
1742
|
className: "flex items-start justify-between",
|
|
1741
|
-
children: [/* @__PURE__ */
|
|
1743
|
+
children: [/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ W("div", {
|
|
1742
1744
|
className: "flex items-center gap-2",
|
|
1743
|
-
children: [/* @__PURE__ */
|
|
1745
|
+
children: [/* @__PURE__ */ U("h3", {
|
|
1744
1746
|
className: "font-medium",
|
|
1745
1747
|
children: t.name
|
|
1746
|
-
}), /* @__PURE__ */
|
|
1748
|
+
}), /* @__PURE__ */ U(T, {
|
|
1747
1749
|
status: t.status,
|
|
1748
1750
|
type: "webhook"
|
|
1749
1751
|
})]
|
|
1750
|
-
}), t.description && /* @__PURE__ */
|
|
1752
|
+
}), t.description && /* @__PURE__ */ U("p", {
|
|
1751
1753
|
className: "text-sm text-text-secondary mt-1",
|
|
1752
1754
|
children: t.description
|
|
1753
|
-
})] }), /* @__PURE__ */
|
|
1755
|
+
})] }), /* @__PURE__ */ U("button", {
|
|
1754
1756
|
onClick: () => n(`/apps/${e}/webhooks/${t.id}`),
|
|
1755
1757
|
className: "rounded-md p-1 hover:bg-bg-sunken",
|
|
1756
|
-
children: /* @__PURE__ */
|
|
1758
|
+
children: /* @__PURE__ */ U(De, { size: 20 })
|
|
1757
1759
|
})]
|
|
1758
1760
|
}),
|
|
1759
|
-
/* @__PURE__ */
|
|
1761
|
+
/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("p", {
|
|
1760
1762
|
className: "text-xs text-text-secondary mb-1",
|
|
1761
1763
|
children: a("devportal.endpointUrl", "Endpoint URL")
|
|
1762
|
-
}), /* @__PURE__ */
|
|
1764
|
+
}), /* @__PURE__ */ U("code", {
|
|
1763
1765
|
className: "text-sm bg-bg-sunken px-2 py-1 rounded block truncate",
|
|
1764
1766
|
children: t.url
|
|
1765
1767
|
})] }),
|
|
1766
|
-
/* @__PURE__ */
|
|
1768
|
+
/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("p", {
|
|
1767
1769
|
className: "text-xs text-text-secondary mb-2",
|
|
1768
1770
|
children: a("devportal.events", "Events")
|
|
1769
|
-
}), /* @__PURE__ */
|
|
1771
|
+
}), /* @__PURE__ */ U("div", {
|
|
1770
1772
|
className: "flex flex-wrap gap-2",
|
|
1771
|
-
children: t.events.map((e) => /* @__PURE__ */
|
|
1773
|
+
children: t.events.map((e) => /* @__PURE__ */ U("span", {
|
|
1772
1774
|
className: "rounded-full bg-bg-sunken px-2 py-0.5 text-xs",
|
|
1773
1775
|
children: e
|
|
1774
1776
|
}, e))
|
|
1775
1777
|
})] }),
|
|
1776
|
-
/* @__PURE__ */
|
|
1778
|
+
/* @__PURE__ */ W("div", {
|
|
1777
1779
|
className: "grid gap-4 sm:grid-cols-4 text-sm",
|
|
1778
1780
|
children: [
|
|
1779
|
-
/* @__PURE__ */
|
|
1781
|
+
/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("p", {
|
|
1780
1782
|
className: "text-xs text-text-secondary",
|
|
1781
1783
|
children: a("devportal.success", "Success")
|
|
1782
|
-
}), /* @__PURE__ */
|
|
1784
|
+
}), /* @__PURE__ */ U("p", {
|
|
1783
1785
|
className: "font-medium text-status-success-text",
|
|
1784
1786
|
children: t.successCount.toLocaleString()
|
|
1785
1787
|
})] }),
|
|
1786
|
-
/* @__PURE__ */
|
|
1788
|
+
/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("p", {
|
|
1787
1789
|
className: "text-xs text-text-secondary",
|
|
1788
1790
|
children: a("devportal.failed", "Failed")
|
|
1789
|
-
}), /* @__PURE__ */
|
|
1791
|
+
}), /* @__PURE__ */ U("p", {
|
|
1790
1792
|
className: "font-medium text-status-error-text",
|
|
1791
1793
|
children: t.failureCount.toLocaleString()
|
|
1792
1794
|
})] }),
|
|
1793
|
-
/* @__PURE__ */
|
|
1795
|
+
/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("p", {
|
|
1794
1796
|
className: "text-xs text-text-secondary",
|
|
1795
1797
|
children: a("devportal.successRate", "Success Rate")
|
|
1796
|
-
}), /* @__PURE__ */
|
|
1798
|
+
}), /* @__PURE__ */ W("p", {
|
|
1797
1799
|
className: "font-medium",
|
|
1798
1800
|
children: [t.successCount + t.failureCount > 0 ? (t.successCount / (t.successCount + t.failureCount) * 100).toFixed(1) : "0.0", "%"]
|
|
1799
1801
|
})] }),
|
|
1800
|
-
/* @__PURE__ */
|
|
1802
|
+
/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("p", {
|
|
1801
1803
|
className: "text-xs text-text-secondary",
|
|
1802
1804
|
children: a("devportal.lastTriggered", "Last Triggered")
|
|
1803
|
-
}), /* @__PURE__ */
|
|
1805
|
+
}), /* @__PURE__ */ U("p", {
|
|
1804
1806
|
className: "font-medium",
|
|
1805
1807
|
children: t.lastTriggeredAt ? new Date(t.lastTriggeredAt).toLocaleString() : a("devportal.never", "Never")
|
|
1806
1808
|
})] })
|
|
@@ -1808,29 +1810,29 @@ var Ue = [
|
|
|
1808
1810
|
})
|
|
1809
1811
|
]
|
|
1810
1812
|
}, t.id))
|
|
1811
|
-
}) : /* @__PURE__ */
|
|
1813
|
+
}) : /* @__PURE__ */ U(r, {
|
|
1812
1814
|
illustration: "empty-notifications",
|
|
1813
|
-
icon: /* @__PURE__ */
|
|
1815
|
+
icon: /* @__PURE__ */ U(Ie, { size: 32 }),
|
|
1814
1816
|
title: a("devportal.noWebhooks", "No webhooks"),
|
|
1815
1817
|
description: a("devportal.noWebhooksDescription", "Add a webhook to receive event notifications"),
|
|
1816
|
-
action: /* @__PURE__ */
|
|
1818
|
+
action: /* @__PURE__ */ W("button", {
|
|
1817
1819
|
onClick: () => n(`/apps/${e}/webhooks/new`),
|
|
1818
1820
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90",
|
|
1819
|
-
children: [/* @__PURE__ */
|
|
1821
|
+
children: [/* @__PURE__ */ U(ke, { size: 16 }), a("devportal.addWebhook", "Add Webhook")]
|
|
1820
1822
|
})
|
|
1821
1823
|
})]
|
|
1822
1824
|
});
|
|
1823
|
-
},
|
|
1825
|
+
}, rt = ({ appName: e, delegations: n, onGrantDelegation: i, onRevokeDelegation: a, selectedDelegationIds: o, onToggleSelectDelegation: s, onToggleAllDelegations: c, onClearSelection: l, onRevokeSelected: u, allVisibleSelected: d, partiallySelected: f }) => {
|
|
1824
1826
|
let { t: p } = P(), m = (e, t) => {
|
|
1825
1827
|
let n = p(e);
|
|
1826
1828
|
return n === e ? t : n;
|
|
1827
1829
|
}, h = n.filter((e) => e.status === "ACTIVE"), g = n.filter((e) => e.status !== "ACTIVE");
|
|
1828
|
-
return /* @__PURE__ */
|
|
1830
|
+
return /* @__PURE__ */ W("div", {
|
|
1829
1831
|
className: "space-y-6",
|
|
1830
1832
|
children: [
|
|
1831
|
-
/* @__PURE__ */
|
|
1833
|
+
/* @__PURE__ */ W("div", {
|
|
1832
1834
|
className: "flex items-center justify-between",
|
|
1833
|
-
children: [/* @__PURE__ */
|
|
1835
|
+
children: [/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ W("p", {
|
|
1834
1836
|
className: "text-sm text-text-secondary",
|
|
1835
1837
|
children: [
|
|
1836
1838
|
n.length,
|
|
@@ -1841,7 +1843,7 @@ var Ue = [
|
|
|
1841
1843
|
" ",
|
|
1842
1844
|
e
|
|
1843
1845
|
]
|
|
1844
|
-
}), h.length > 0 && /* @__PURE__ */
|
|
1846
|
+
}), h.length > 0 && /* @__PURE__ */ W("p", {
|
|
1845
1847
|
className: "text-xs text-text-secondary mt-0.5",
|
|
1846
1848
|
children: [
|
|
1847
1849
|
h.length,
|
|
@@ -1853,44 +1855,44 @@ var Ue = [
|
|
|
1853
1855
|
" ",
|
|
1854
1856
|
m("devportal.revokedExpired", "revoked/expired")
|
|
1855
1857
|
]
|
|
1856
|
-
})] }), /* @__PURE__ */
|
|
1858
|
+
})] }), /* @__PURE__ */ W("button", {
|
|
1857
1859
|
onClick: i,
|
|
1858
1860
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 transition-colors",
|
|
1859
|
-
children: [/* @__PURE__ */
|
|
1861
|
+
children: [/* @__PURE__ */ U(ke, { size: 16 }), m("devportal.grantDelegation", "Grant Delegation")]
|
|
1860
1862
|
})]
|
|
1861
1863
|
}),
|
|
1862
|
-
h.length > 0 && /* @__PURE__ */
|
|
1864
|
+
h.length > 0 && /* @__PURE__ */ U("div", {
|
|
1863
1865
|
className: "rounded-card border border-border-seam bg-bg-surface p-4",
|
|
1864
|
-
children: /* @__PURE__ */
|
|
1866
|
+
children: /* @__PURE__ */ W("div", {
|
|
1865
1867
|
className: "flex flex-col gap-3 lg:flex-row lg:items-center lg:justify-between",
|
|
1866
|
-
children: [/* @__PURE__ */
|
|
1868
|
+
children: [/* @__PURE__ */ W("div", {
|
|
1867
1869
|
className: "flex flex-wrap items-center gap-3",
|
|
1868
|
-
children: [/* @__PURE__ */
|
|
1870
|
+
children: [/* @__PURE__ */ W("div", {
|
|
1869
1871
|
className: "flex items-center gap-2",
|
|
1870
|
-
children: [/* @__PURE__ */
|
|
1872
|
+
children: [/* @__PURE__ */ U(D, {
|
|
1871
1873
|
checked: d,
|
|
1872
1874
|
indeterminate: f,
|
|
1873
1875
|
onChange: c,
|
|
1874
1876
|
ariaLabel: m("devportal.selectAllActiveDelegations", "Select all active app delegations")
|
|
1875
|
-
}), /* @__PURE__ */
|
|
1877
|
+
}), /* @__PURE__ */ U("span", {
|
|
1876
1878
|
className: "text-sm font-medium",
|
|
1877
1879
|
children: m("devportal.selectAllActive", "Select all active")
|
|
1878
1880
|
})]
|
|
1879
|
-
}), o.size > 0 && /* @__PURE__ */
|
|
1881
|
+
}), o.size > 0 && /* @__PURE__ */ U("button", {
|
|
1880
1882
|
onClick: l,
|
|
1881
1883
|
className: "text-sm text-text-secondary hover:text-text-primary",
|
|
1882
1884
|
children: m("devportal.clearSelection", "Clear selection")
|
|
1883
1885
|
})]
|
|
1884
|
-
}), /* @__PURE__ */
|
|
1886
|
+
}), /* @__PURE__ */ W("div", {
|
|
1885
1887
|
className: "flex flex-wrap items-center gap-2",
|
|
1886
|
-
children: [/* @__PURE__ */
|
|
1888
|
+
children: [/* @__PURE__ */ W("span", {
|
|
1887
1889
|
className: "rounded-full bg-bg-sunken px-3 py-1 text-sm font-medium text-text-secondary",
|
|
1888
1890
|
children: [
|
|
1889
1891
|
o.size,
|
|
1890
1892
|
" ",
|
|
1891
1893
|
m("devportal.selected", "selected")
|
|
1892
1894
|
]
|
|
1893
|
-
}), /* @__PURE__ */
|
|
1895
|
+
}), /* @__PURE__ */ W("button", {
|
|
1894
1896
|
onClick: u,
|
|
1895
1897
|
disabled: o.size === 0,
|
|
1896
1898
|
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",
|
|
@@ -1899,33 +1901,33 @@ var Ue = [
|
|
|
1899
1901
|
})]
|
|
1900
1902
|
})
|
|
1901
1903
|
}),
|
|
1902
|
-
n.length > 0 ? /* @__PURE__ */
|
|
1904
|
+
n.length > 0 ? /* @__PURE__ */ U("div", {
|
|
1903
1905
|
className: "space-y-4",
|
|
1904
|
-
children: n.map((e) => /* @__PURE__ */
|
|
1906
|
+
children: n.map((e) => /* @__PURE__ */ W("div", {
|
|
1905
1907
|
className: "rounded-card border border-border-seam bg-bg-surface p-4 space-y-4 shadow-[var(--shadow-pop)]",
|
|
1906
1908
|
children: [
|
|
1907
|
-
/* @__PURE__ */
|
|
1909
|
+
/* @__PURE__ */ W("div", {
|
|
1908
1910
|
className: "flex items-start justify-between",
|
|
1909
|
-
children: [/* @__PURE__ */
|
|
1911
|
+
children: [/* @__PURE__ */ W("div", {
|
|
1910
1912
|
className: "flex items-start gap-3",
|
|
1911
|
-
children: [e.status === "ACTIVE" && /* @__PURE__ */
|
|
1913
|
+
children: [e.status === "ACTIVE" && /* @__PURE__ */ U("div", {
|
|
1912
1914
|
onClick: (e) => e.stopPropagation(),
|
|
1913
|
-
children: /* @__PURE__ */
|
|
1915
|
+
children: /* @__PURE__ */ U(D, {
|
|
1914
1916
|
checked: o.has(e.id),
|
|
1915
1917
|
onChange: (t) => s(e.id, t),
|
|
1916
1918
|
ariaLabel: `Select delegation ${e.id}`,
|
|
1917
1919
|
className: "mt-1"
|
|
1918
1920
|
})
|
|
1919
|
-
}), /* @__PURE__ */
|
|
1921
|
+
}), /* @__PURE__ */ W("div", { children: [/* @__PURE__ */ W("div", {
|
|
1920
1922
|
className: "flex items-center gap-2",
|
|
1921
|
-
children: [/* @__PURE__ */
|
|
1923
|
+
children: [/* @__PURE__ */ W("h3", {
|
|
1922
1924
|
className: "font-medium",
|
|
1923
1925
|
children: ["Delegation #", e.id.slice(0, 8)]
|
|
1924
|
-
}), /* @__PURE__ */
|
|
1926
|
+
}), /* @__PURE__ */ U("span", {
|
|
1925
1927
|
className: t("rounded-full px-2 py-0.5 text-xs font-medium", q[e.status]),
|
|
1926
1928
|
children: e.status
|
|
1927
1929
|
})]
|
|
1928
|
-
}), /* @__PURE__ */
|
|
1930
|
+
}), /* @__PURE__ */ W("p", {
|
|
1929
1931
|
className: "text-sm text-text-secondary mt-1",
|
|
1930
1932
|
children: [
|
|
1931
1933
|
m("devportal.granted", "Granted"),
|
|
@@ -1937,55 +1939,55 @@ var Ue = [
|
|
|
1937
1939
|
e.grantedBy === e.userId ? m("devportal.you", "you") : e.grantedBy.slice(0, 8)
|
|
1938
1940
|
]
|
|
1939
1941
|
})] })]
|
|
1940
|
-
}), e.status === "ACTIVE" && /* @__PURE__ */
|
|
1942
|
+
}), e.status === "ACTIVE" && /* @__PURE__ */ W("button", {
|
|
1941
1943
|
onClick: () => a(e.id),
|
|
1942
1944
|
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",
|
|
1943
|
-
children: [/* @__PURE__ */
|
|
1945
|
+
children: [/* @__PURE__ */ U(Re, { size: 14 }), m("devportal.revoke", "Revoke")]
|
|
1944
1946
|
})]
|
|
1945
1947
|
}),
|
|
1946
|
-
/* @__PURE__ */
|
|
1948
|
+
/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("p", {
|
|
1947
1949
|
className: "text-xs text-text-secondary mb-2",
|
|
1948
1950
|
children: m("devportal.grantedScopes", "Granted Scopes")
|
|
1949
|
-
}), /* @__PURE__ */
|
|
1951
|
+
}), /* @__PURE__ */ U("div", {
|
|
1950
1952
|
className: "flex flex-wrap gap-2",
|
|
1951
|
-
children: e.scopes.map((e) => /* @__PURE__ */
|
|
1953
|
+
children: e.scopes.map((e) => /* @__PURE__ */ U("span", {
|
|
1952
1954
|
className: "rounded-full bg-status-success-bg-subtle px-2 py-0.5 text-xs text-status-success-text",
|
|
1953
1955
|
children: e
|
|
1954
1956
|
}, e))
|
|
1955
1957
|
})] }),
|
|
1956
|
-
e.workspaceIds.length > 0 && /* @__PURE__ */
|
|
1958
|
+
e.workspaceIds.length > 0 && /* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("p", {
|
|
1957
1959
|
className: "text-xs text-text-secondary mb-2",
|
|
1958
1960
|
children: m("devportal.workspaceScope", "Workspace Scope")
|
|
1959
|
-
}), /* @__PURE__ */
|
|
1961
|
+
}), /* @__PURE__ */ U("div", {
|
|
1960
1962
|
className: "flex flex-wrap gap-2",
|
|
1961
|
-
children: e.workspaceIds.map((e) => /* @__PURE__ */
|
|
1963
|
+
children: e.workspaceIds.map((e) => /* @__PURE__ */ U("code", {
|
|
1962
1964
|
className: "rounded bg-bg-sunken px-2 py-0.5 text-xs",
|
|
1963
1965
|
children: e
|
|
1964
1966
|
}, e))
|
|
1965
1967
|
})] }),
|
|
1966
|
-
/* @__PURE__ */
|
|
1968
|
+
/* @__PURE__ */ W("div", {
|
|
1967
1969
|
className: "flex items-center gap-4 text-xs text-text-secondary",
|
|
1968
1970
|
children: [
|
|
1969
|
-
e.expiresAt && /* @__PURE__ */
|
|
1971
|
+
e.expiresAt && /* @__PURE__ */ W("span", {
|
|
1970
1972
|
className: "flex items-center gap-1",
|
|
1971
1973
|
children: [
|
|
1972
|
-
/* @__PURE__ */
|
|
1974
|
+
/* @__PURE__ */ U(ve, { size: 12 }),
|
|
1973
1975
|
m("devportal.expires", "Expires"),
|
|
1974
1976
|
" ",
|
|
1975
1977
|
new Date(e.expiresAt).toLocaleDateString()
|
|
1976
1978
|
]
|
|
1977
1979
|
}),
|
|
1978
|
-
!e.expiresAt && e.status === "ACTIVE" && /* @__PURE__ */
|
|
1980
|
+
!e.expiresAt && e.status === "ACTIVE" && /* @__PURE__ */ W("span", {
|
|
1979
1981
|
className: "flex items-center gap-1",
|
|
1980
|
-
children: [/* @__PURE__ */
|
|
1982
|
+
children: [/* @__PURE__ */ U(ge, {
|
|
1981
1983
|
size: 12,
|
|
1982
1984
|
className: "text-status-success-text"
|
|
1983
1985
|
}), m("devportal.noExpiration", "No expiration")]
|
|
1984
1986
|
}),
|
|
1985
|
-
e.revokedAt && /* @__PURE__ */
|
|
1987
|
+
e.revokedAt && /* @__PURE__ */ W("span", {
|
|
1986
1988
|
className: "flex items-center gap-1",
|
|
1987
1989
|
children: [
|
|
1988
|
-
/* @__PURE__ */
|
|
1990
|
+
/* @__PURE__ */ U(Re, {
|
|
1989
1991
|
size: 12,
|
|
1990
1992
|
className: "text-status-error-text"
|
|
1991
1993
|
}),
|
|
@@ -1998,53 +2000,53 @@ var Ue = [
|
|
|
1998
2000
|
})
|
|
1999
2001
|
]
|
|
2000
2002
|
}, e.id))
|
|
2001
|
-
}) : /* @__PURE__ */
|
|
2003
|
+
}) : /* @__PURE__ */ U(r, {
|
|
2002
2004
|
illustration: "empty-people",
|
|
2003
|
-
icon: /* @__PURE__ */
|
|
2005
|
+
icon: /* @__PURE__ */ U(Fe, { size: 32 }),
|
|
2004
2006
|
title: m("devportal.noDelegations", "No delegations"),
|
|
2005
2007
|
description: m("devportal.noDelegationsDescription", "Grant a delegation to allow this app to act on your behalf"),
|
|
2006
|
-
action: /* @__PURE__ */
|
|
2008
|
+
action: /* @__PURE__ */ W("button", {
|
|
2007
2009
|
onClick: i,
|
|
2008
2010
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90",
|
|
2009
|
-
children: [/* @__PURE__ */
|
|
2011
|
+
children: [/* @__PURE__ */ U(ke, { size: 16 }), m("devportal.grantDelegation", "Grant Delegation")]
|
|
2010
2012
|
})
|
|
2011
2013
|
})
|
|
2012
2014
|
]
|
|
2013
2015
|
});
|
|
2014
|
-
},
|
|
2016
|
+
}, it = ({ analytics: e }) => {
|
|
2015
2017
|
let { t } = P(), n = (e, n) => {
|
|
2016
2018
|
let r = t(e);
|
|
2017
2019
|
return r === e ? n : r;
|
|
2018
2020
|
}, i = e[0], a = e[1], o = (e, t) => t ? (e - t) / t * 100 : 0;
|
|
2019
|
-
return /* @__PURE__ */
|
|
2021
|
+
return /* @__PURE__ */ W("div", {
|
|
2020
2022
|
className: "space-y-6",
|
|
2021
|
-
children: [/* @__PURE__ */
|
|
2023
|
+
children: [/* @__PURE__ */ W("div", {
|
|
2022
2024
|
className: "grid gap-4 sm:grid-cols-4",
|
|
2023
2025
|
children: [
|
|
2024
|
-
/* @__PURE__ */
|
|
2026
|
+
/* @__PURE__ */ U(Q, {
|
|
2025
2027
|
label: n("devportal.activeUsers", "Active Users"),
|
|
2026
2028
|
value: i?.activeUsers.toLocaleString() || "0",
|
|
2027
2029
|
trend: a ? o(i.activeUsers, a.activeUsers) : void 0
|
|
2028
2030
|
}),
|
|
2029
|
-
/* @__PURE__ */
|
|
2031
|
+
/* @__PURE__ */ U(Q, {
|
|
2030
2032
|
label: n("devportal.apiCalls", "API Calls"),
|
|
2031
2033
|
value: i ? `${(i.apiCalls / 1e3).toFixed(1)}K` : "0",
|
|
2032
2034
|
trend: a ? o(i.apiCalls, a.apiCalls) : void 0
|
|
2033
2035
|
}),
|
|
2034
|
-
/* @__PURE__ */
|
|
2036
|
+
/* @__PURE__ */ U(Q, {
|
|
2035
2037
|
label: n("devportal.avgResponseTime", "Avg Response Time"),
|
|
2036
2038
|
value: i?.avgResponseTime ? `${i.avgResponseTime}ms` : n("devportal.notAvailable", "N/A"),
|
|
2037
2039
|
trend: a && i?.avgResponseTime ? -o(i.avgResponseTime, a.avgResponseTime || 1) : void 0
|
|
2038
2040
|
}),
|
|
2039
|
-
/* @__PURE__ */
|
|
2041
|
+
/* @__PURE__ */ U(Q, {
|
|
2040
2042
|
label: n("devportal.errorRate", "Error Rate"),
|
|
2041
2043
|
value: i && i.apiCalls > 0 ? `${(i.errors / i.apiCalls * 100).toFixed(2)}%` : "0%",
|
|
2042
2044
|
trend: a && i && i.apiCalls > 0 && a.apiCalls > 0 ? -o(i.errors / i.apiCalls, a.errors / a.apiCalls) : void 0
|
|
2043
2045
|
})
|
|
2044
2046
|
]
|
|
2045
|
-
}), /* @__PURE__ */
|
|
2047
|
+
}), /* @__PURE__ */ U(S, {
|
|
2046
2048
|
title: n("devportal.dailyBreakdown", "Daily Breakdown"),
|
|
2047
|
-
children: e.length > 0 ? /* @__PURE__ */
|
|
2049
|
+
children: e.length > 0 ? /* @__PURE__ */ U(te, {
|
|
2048
2050
|
data: e,
|
|
2049
2051
|
keyField: "id",
|
|
2050
2052
|
columns: [
|
|
@@ -2084,19 +2086,19 @@ var Ue = [
|
|
|
2084
2086
|
render: (e) => e.sessions.toLocaleString()
|
|
2085
2087
|
}
|
|
2086
2088
|
]
|
|
2087
|
-
}) : /* @__PURE__ */
|
|
2089
|
+
}) : /* @__PURE__ */ U(r, {
|
|
2088
2090
|
illustration: "empty-data",
|
|
2089
|
-
icon: /* @__PURE__ */
|
|
2091
|
+
icon: /* @__PURE__ */ U(he, { size: 32 }),
|
|
2090
2092
|
title: n("devportal.noAnalyticsData", "No analytics data"),
|
|
2091
2093
|
description: n("devportal.noAnalyticsDataDescription", "Analytics data will appear here once the application starts receiving traffic.")
|
|
2092
2094
|
})
|
|
2093
2095
|
})]
|
|
2094
2096
|
});
|
|
2095
|
-
},
|
|
2097
|
+
}, at = "# Sample query — replace with your own\n# Note: introspection is disabled on this gateway for security.\n# Use a real query from your app's API schema instead.\nquery GetCurrentUser {\n currentUser {\n id\n email\n }\n}", ot = ({ app: t }) => {
|
|
2096
2098
|
let { apiGatewayUrl: n, workspacesGatewayUrl: r, authToken: i } = e(), { t: a } = P(), o = (e, t) => {
|
|
2097
2099
|
let n = a(e);
|
|
2098
2100
|
return n === e ? t : n;
|
|
2099
|
-
}, [s, c] = N(
|
|
2101
|
+
}, [s, c] = N(at), [l, u] = N("{}"), [d, f] = N(""), [p, m] = N(!1), [h, g] = N(`${n || "https://gw-global.local.burdenoff.com"}/global/graphql`), [_, v] = N(i || ""), [y, b] = N(!1), x = A(async () => {
|
|
2100
2102
|
m(!0), f("");
|
|
2101
2103
|
try {
|
|
2102
2104
|
let e = {};
|
|
@@ -2130,21 +2132,21 @@ var Ue = [
|
|
|
2130
2132
|
]), S = A(() => {
|
|
2131
2133
|
i && v(i), b(!0);
|
|
2132
2134
|
}, [i]);
|
|
2133
|
-
return /* @__PURE__ */
|
|
2135
|
+
return /* @__PURE__ */ W("div", {
|
|
2134
2136
|
className: "space-y-4",
|
|
2135
2137
|
children: [
|
|
2136
|
-
/* @__PURE__ */
|
|
2138
|
+
/* @__PURE__ */ W("div", {
|
|
2137
2139
|
className: "flex items-center justify-between",
|
|
2138
|
-
children: [/* @__PURE__ */
|
|
2140
|
+
children: [/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("h3", {
|
|
2139
2141
|
className: "text-lg font-semibold",
|
|
2140
2142
|
children: o("devportal.apiPlayground", "API Playground")
|
|
2141
|
-
}), /* @__PURE__ */
|
|
2143
|
+
}), /* @__PURE__ */ W("p", {
|
|
2142
2144
|
className: "text-sm text-text-secondary",
|
|
2143
2145
|
children: [
|
|
2144
2146
|
o("devportal.apiPlaygroundDescription", "Test GraphQL APIs in the context of"),
|
|
2145
2147
|
" ",
|
|
2146
|
-
/* @__PURE__ */
|
|
2147
|
-
t.appId && /* @__PURE__ */
|
|
2148
|
+
/* @__PURE__ */ U("strong", { children: t.name }),
|
|
2149
|
+
t.appId && /* @__PURE__ */ W("span", {
|
|
2148
2150
|
className: "ml-1 text-xs text-text-secondary",
|
|
2149
2151
|
children: [
|
|
2150
2152
|
"(OAuth App: ",
|
|
@@ -2153,39 +2155,39 @@ var Ue = [
|
|
|
2153
2155
|
]
|
|
2154
2156
|
})
|
|
2155
2157
|
]
|
|
2156
|
-
})] }), /* @__PURE__ */
|
|
2158
|
+
})] }), /* @__PURE__ */ W("button", {
|
|
2157
2159
|
onClick: S,
|
|
2158
2160
|
className: "flex items-center gap-2 rounded-md border px-3 py-1.5 text-sm font-medium hover:bg-accent transition-colors",
|
|
2159
|
-
children: [/* @__PURE__ */
|
|
2161
|
+
children: [/* @__PURE__ */ U(we, { size: 14 }), o("devportal.autoFillCredentials", "Auto-fill Credentials")]
|
|
2160
2162
|
})]
|
|
2161
2163
|
}),
|
|
2162
|
-
y && /* @__PURE__ */
|
|
2164
|
+
y && /* @__PURE__ */ W("div", {
|
|
2163
2165
|
className: "rounded-lg border bg-status-info-bg-subtle p-4 text-sm space-y-2",
|
|
2164
2166
|
children: [
|
|
2165
|
-
/* @__PURE__ */
|
|
2167
|
+
/* @__PURE__ */ U("p", {
|
|
2166
2168
|
className: "font-medium text-status-info-text",
|
|
2167
2169
|
children: o("devportal.authenticationGuide", "Authentication Guide")
|
|
2168
2170
|
}),
|
|
2169
|
-
/* @__PURE__ */
|
|
2171
|
+
/* @__PURE__ */ W("p", {
|
|
2170
2172
|
className: "text-status-info-text",
|
|
2171
2173
|
children: [
|
|
2172
2174
|
o("devportal.authenticationGuideText", "Your current session token has been filled in. For app-level authentication (Client Credentials flow), use the"),
|
|
2173
2175
|
" ",
|
|
2174
|
-
/* @__PURE__ */
|
|
2176
|
+
/* @__PURE__ */ U("strong", { children: o("devportal.oauthClientsTab", "OAuth Clients") }),
|
|
2175
2177
|
" ",
|
|
2176
2178
|
o("devportal.authenticationGuideText2", "tab to get the app's clientId and clientSecret, then call:")
|
|
2177
2179
|
]
|
|
2178
2180
|
}),
|
|
2179
|
-
/* @__PURE__ */
|
|
2181
|
+
/* @__PURE__ */ U("pre", {
|
|
2180
2182
|
className: "rounded bg-status-info-bg-subtle p-2 text-xs overflow-x-auto text-status-info-text",
|
|
2181
2183
|
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}"
|
|
2182
2184
|
}),
|
|
2183
|
-
/* @__PURE__ */
|
|
2185
|
+
/* @__PURE__ */ W("p", {
|
|
2184
2186
|
className: "text-status-info-text",
|
|
2185
2187
|
children: [
|
|
2186
2188
|
o("devportal.useReturnedAccessToken", "Use the returned"),
|
|
2187
2189
|
" ",
|
|
2188
|
-
/* @__PURE__ */
|
|
2190
|
+
/* @__PURE__ */ U("code", {
|
|
2189
2191
|
className: "bg-status-info-bg-subtle px-1 rounded",
|
|
2190
2192
|
children: "accessToken"
|
|
2191
2193
|
}),
|
|
@@ -2193,85 +2195,85 @@ var Ue = [
|
|
|
2193
2195
|
o("devportal.asBearerToken", "as the Bearer token below.")
|
|
2194
2196
|
]
|
|
2195
2197
|
}),
|
|
2196
|
-
/* @__PURE__ */
|
|
2198
|
+
/* @__PURE__ */ U("button", {
|
|
2197
2199
|
onClick: () => b(!1),
|
|
2198
2200
|
className: "text-xs text-accent-blue hover:underline",
|
|
2199
2201
|
children: o("devportal.dismiss", "Dismiss")
|
|
2200
2202
|
})
|
|
2201
2203
|
]
|
|
2202
2204
|
}),
|
|
2203
|
-
/* @__PURE__ */
|
|
2205
|
+
/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("label", {
|
|
2204
2206
|
className: "block text-sm font-medium mb-1",
|
|
2205
2207
|
children: o("devportal.gatewayEndpoint", "Gateway Endpoint")
|
|
2206
|
-
}), /* @__PURE__ */
|
|
2208
|
+
}), /* @__PURE__ */ W("div", {
|
|
2207
2209
|
className: "flex gap-2",
|
|
2208
|
-
children: [/* @__PURE__ */
|
|
2210
|
+
children: [/* @__PURE__ */ U("input", {
|
|
2209
2211
|
type: "text",
|
|
2210
2212
|
value: h,
|
|
2211
2213
|
onChange: (e) => g(e.target.value),
|
|
2212
2214
|
className: "flex-1 rounded-md border px-3 py-2 text-sm font-mono bg-bg-surface"
|
|
2213
|
-
}), /* @__PURE__ */
|
|
2215
|
+
}), /* @__PURE__ */ W("select", {
|
|
2214
2216
|
onChange: (e) => g(e.target.value),
|
|
2215
2217
|
className: "rounded-md border px-3 py-2 text-sm bg-bg-surface",
|
|
2216
2218
|
value: h,
|
|
2217
|
-
children: [/* @__PURE__ */
|
|
2219
|
+
children: [/* @__PURE__ */ U("option", {
|
|
2218
2220
|
value: `${n || "https://gw-global.local.burdenoff.com"}/global/graphql`,
|
|
2219
2221
|
children: o("devportal.globalGateway", "Global Gateway")
|
|
2220
|
-
}), /* @__PURE__ */
|
|
2222
|
+
}), /* @__PURE__ */ U("option", {
|
|
2221
2223
|
value: `${r || "https://gw-wspace.local.burdenoff.com"}/workspaces/graphql`,
|
|
2222
2224
|
children: o("devportal.workspaceGateway", "Workspace Gateway")
|
|
2223
2225
|
})]
|
|
2224
2226
|
})]
|
|
2225
2227
|
})] }),
|
|
2226
|
-
/* @__PURE__ */
|
|
2228
|
+
/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("label", {
|
|
2227
2229
|
className: "block text-sm font-medium mb-1",
|
|
2228
2230
|
children: o("devportal.bearerToken", "Bearer Token")
|
|
2229
|
-
}), /* @__PURE__ */
|
|
2231
|
+
}), /* @__PURE__ */ U("input", {
|
|
2230
2232
|
type: "password",
|
|
2231
2233
|
value: _,
|
|
2232
2234
|
onChange: (e) => v(e.target.value),
|
|
2233
2235
|
placeholder: o("devportal.pasteAccessToken", "Paste access token here..."),
|
|
2234
2236
|
className: "w-full rounded-md border px-3 py-2 text-sm font-mono bg-bg-surface"
|
|
2235
2237
|
})] }),
|
|
2236
|
-
/* @__PURE__ */
|
|
2238
|
+
/* @__PURE__ */ W("div", {
|
|
2237
2239
|
className: "grid grid-cols-1 lg:grid-cols-2 gap-4",
|
|
2238
|
-
children: [/* @__PURE__ */
|
|
2240
|
+
children: [/* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("label", {
|
|
2239
2241
|
className: "block text-sm font-medium mb-1",
|
|
2240
2242
|
children: o("devportal.query", "Query")
|
|
2241
|
-
}), /* @__PURE__ */
|
|
2243
|
+
}), /* @__PURE__ */ U("textarea", {
|
|
2242
2244
|
value: s,
|
|
2243
2245
|
onChange: (e) => c(e.target.value),
|
|
2244
2246
|
className: "w-full h-64 rounded-md border px-3 py-2 text-sm font-mono bg-bg-surface resize-y",
|
|
2245
2247
|
spellCheck: !1
|
|
2246
|
-
})] }), /* @__PURE__ */
|
|
2248
|
+
})] }), /* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("label", {
|
|
2247
2249
|
className: "block text-sm font-medium mb-1",
|
|
2248
2250
|
children: o("devportal.variablesJson", "Variables (JSON)")
|
|
2249
|
-
}), /* @__PURE__ */
|
|
2251
|
+
}), /* @__PURE__ */ U("textarea", {
|
|
2250
2252
|
value: l,
|
|
2251
2253
|
onChange: (e) => u(e.target.value),
|
|
2252
2254
|
className: "w-full h-64 rounded-md border px-3 py-2 text-sm font-mono bg-bg-surface resize-y",
|
|
2253
2255
|
spellCheck: !1
|
|
2254
2256
|
})] })]
|
|
2255
2257
|
}),
|
|
2256
|
-
/* @__PURE__ */
|
|
2258
|
+
/* @__PURE__ */ W("button", {
|
|
2257
2259
|
onClick: x,
|
|
2258
2260
|
disabled: p,
|
|
2259
2261
|
className: "flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 transition-colors disabled:opacity-50",
|
|
2260
|
-
children: [p ? /* @__PURE__ */
|
|
2262
|
+
children: [p ? /* @__PURE__ */ U(R, {
|
|
2261
2263
|
size: 16,
|
|
2262
2264
|
className: "animate-spin"
|
|
2263
|
-
}) : /* @__PURE__ */
|
|
2265
|
+
}) : /* @__PURE__ */ U(L, { size: 16 }), p ? o("devportal.executing", "Executing...") : o("devportal.executeQuery", "Execute Query")]
|
|
2264
2266
|
}),
|
|
2265
|
-
d && /* @__PURE__ */
|
|
2267
|
+
d && /* @__PURE__ */ W("div", { children: [/* @__PURE__ */ U("label", {
|
|
2266
2268
|
className: "block text-sm font-medium mb-1",
|
|
2267
2269
|
children: o("devportal.response", "Response")
|
|
2268
|
-
}), /* @__PURE__ */
|
|
2270
|
+
}), /* @__PURE__ */ U("pre", {
|
|
2269
2271
|
className: "w-full max-h-96 overflow-auto rounded-md border bg-bg-sunken p-4 text-xs font-mono",
|
|
2270
2272
|
children: d
|
|
2271
2273
|
})] })
|
|
2272
2274
|
]
|
|
2273
2275
|
});
|
|
2274
|
-
},
|
|
2276
|
+
}, st = ({ label: e, value: n, onChange: r, hint: i, accept: a = "image/png,image/jpeg,image/webp,image/gif,image/svg+xml", aspectClass: o = "aspect-square", upload: s, uploading: c, progress: l, error: u }) => {
|
|
2275
2277
|
let d = M(null), [f, p] = N(!1), m = M(n);
|
|
2276
2278
|
m.current !== n && (m.current = n, f && p(!1));
|
|
2277
2279
|
let h = A(async (e) => {
|
|
@@ -2279,46 +2281,46 @@ var Ue = [
|
|
|
2279
2281
|
r((await s(e)).downloadUrl);
|
|
2280
2282
|
} catch {}
|
|
2281
2283
|
}, [s, r]);
|
|
2282
|
-
return /* @__PURE__ */
|
|
2284
|
+
return /* @__PURE__ */ W("div", {
|
|
2283
2285
|
className: "space-y-1.5",
|
|
2284
2286
|
children: [
|
|
2285
|
-
/* @__PURE__ */
|
|
2287
|
+
/* @__PURE__ */ U("label", {
|
|
2286
2288
|
className: "text-sm font-medium",
|
|
2287
2289
|
children: e
|
|
2288
2290
|
}),
|
|
2289
|
-
/* @__PURE__ */
|
|
2291
|
+
/* @__PURE__ */ W("div", {
|
|
2290
2292
|
className: "flex gap-3 items-start",
|
|
2291
|
-
children: [/* @__PURE__ */
|
|
2293
|
+
children: [/* @__PURE__ */ W("div", {
|
|
2292
2294
|
className: t("relative shrink-0 w-20 rounded-lg border border-border-subtle bg-bg-sunken overflow-hidden flex items-center justify-center", o),
|
|
2293
|
-
children: [n && !f ? /* @__PURE__ */
|
|
2295
|
+
children: [n && !f ? /* @__PURE__ */ U("img", {
|
|
2294
2296
|
src: n,
|
|
2295
2297
|
alt: e,
|
|
2296
2298
|
className: "w-full h-full object-cover",
|
|
2297
2299
|
onError: () => p(!0)
|
|
2298
|
-
}) : /* @__PURE__ */
|
|
2300
|
+
}) : /* @__PURE__ */ U(B, {
|
|
2299
2301
|
size: 18,
|
|
2300
2302
|
className: "text-text-secondary opacity-40"
|
|
2301
|
-
}), c && /* @__PURE__ */
|
|
2303
|
+
}), c && /* @__PURE__ */ W("div", {
|
|
2302
2304
|
className: "absolute inset-0 bg-bg-overlay flex flex-col items-center justify-center gap-1",
|
|
2303
|
-
children: [/* @__PURE__ */
|
|
2305
|
+
children: [/* @__PURE__ */ U(R, {
|
|
2304
2306
|
size: 14,
|
|
2305
2307
|
className: "animate-spin text-white"
|
|
2306
|
-
}), /* @__PURE__ */
|
|
2308
|
+
}), /* @__PURE__ */ W("span", {
|
|
2307
2309
|
className: "text-white text-xs",
|
|
2308
2310
|
children: [l, "%"]
|
|
2309
2311
|
})]
|
|
2310
2312
|
})]
|
|
2311
|
-
}), /* @__PURE__ */
|
|
2313
|
+
}), /* @__PURE__ */ W("div", {
|
|
2312
2314
|
className: "flex-1 space-y-1.5",
|
|
2313
2315
|
children: [
|
|
2314
|
-
/* @__PURE__ */
|
|
2316
|
+
/* @__PURE__ */ U("input", {
|
|
2315
2317
|
type: "url",
|
|
2316
2318
|
value: n,
|
|
2317
2319
|
onChange: (e) => r(e.target.value),
|
|
2318
2320
|
placeholder: "https://...",
|
|
2319
2321
|
className: "w-full rounded-md border border-border-subtle bg-bg-input px-3 py-1.5 text-sm placeholder:text-text-placeholder focus:outline-none focus:ring-2 focus:ring-primary/30"
|
|
2320
2322
|
}),
|
|
2321
|
-
/* @__PURE__ */
|
|
2323
|
+
/* @__PURE__ */ U("input", {
|
|
2322
2324
|
ref: d,
|
|
2323
2325
|
type: "file",
|
|
2324
2326
|
accept: a,
|
|
@@ -2328,27 +2330,27 @@ var Ue = [
|
|
|
2328
2330
|
t && h(t), e.target.value = "";
|
|
2329
2331
|
}
|
|
2330
2332
|
}),
|
|
2331
|
-
/* @__PURE__ */
|
|
2333
|
+
/* @__PURE__ */ W("button", {
|
|
2332
2334
|
type: "button",
|
|
2333
2335
|
disabled: c,
|
|
2334
2336
|
onClick: () => d.current?.click(),
|
|
2335
2337
|
className: "inline-flex items-center gap-1.5 rounded-md border px-2.5 py-1 text-xs font-medium hover:bg-bg-sunken transition-colors disabled:opacity-50",
|
|
2336
|
-
children: [/* @__PURE__ */
|
|
2338
|
+
children: [/* @__PURE__ */ U(B, { size: 11 }), c ? `Uploading… ${l}%` : "Upload image"]
|
|
2337
2339
|
}),
|
|
2338
|
-
u && /* @__PURE__ */
|
|
2340
|
+
u && /* @__PURE__ */ U("p", {
|
|
2339
2341
|
className: "text-xs text-status-error-text",
|
|
2340
2342
|
children: u
|
|
2341
2343
|
})
|
|
2342
2344
|
]
|
|
2343
2345
|
})]
|
|
2344
2346
|
}),
|
|
2345
|
-
i && /* @__PURE__ */
|
|
2347
|
+
i && /* @__PURE__ */ U("p", {
|
|
2346
2348
|
className: "text-xs text-text-secondary",
|
|
2347
2349
|
children: i
|
|
2348
2350
|
})
|
|
2349
2351
|
]
|
|
2350
2352
|
});
|
|
2351
|
-
},
|
|
2353
|
+
}, ct = ({ urls: e, onChange: n, upload: r, uploading: i, progress: a, error: o }) => {
|
|
2352
2354
|
let s = M(null), [c, l] = N(""), u = A(async (t) => {
|
|
2353
2355
|
try {
|
|
2354
2356
|
let i = await r(t);
|
|
@@ -2364,53 +2366,53 @@ var Ue = [
|
|
|
2364
2366
|
}, f = (t) => {
|
|
2365
2367
|
n(e.filter((e, n) => n !== t));
|
|
2366
2368
|
};
|
|
2367
|
-
return /* @__PURE__ */
|
|
2369
|
+
return /* @__PURE__ */ W("div", {
|
|
2368
2370
|
className: "space-y-2",
|
|
2369
2371
|
children: [
|
|
2370
|
-
/* @__PURE__ */
|
|
2372
|
+
/* @__PURE__ */ W("div", {
|
|
2371
2373
|
className: "flex flex-col gap-0.5",
|
|
2372
|
-
children: [/* @__PURE__ */
|
|
2374
|
+
children: [/* @__PURE__ */ U("label", {
|
|
2373
2375
|
className: "text-sm font-medium",
|
|
2374
2376
|
children: "Screenshots"
|
|
2375
|
-
}), /* @__PURE__ */
|
|
2377
|
+
}), /* @__PURE__ */ U("p", {
|
|
2376
2378
|
className: "text-xs text-text-muted",
|
|
2377
2379
|
children: "Shown in the horizontal preview strip below the hero — wide landscape proportions work best (16:9)"
|
|
2378
2380
|
})]
|
|
2379
2381
|
}),
|
|
2380
|
-
/* @__PURE__ */
|
|
2382
|
+
/* @__PURE__ */ W("div", {
|
|
2381
2383
|
className: "flex flex-wrap gap-3",
|
|
2382
|
-
children: [e.map((e, t) => /* @__PURE__ */
|
|
2384
|
+
children: [e.map((e, t) => /* @__PURE__ */ W("div", {
|
|
2383
2385
|
className: "relative group w-36 aspect-video rounded-lg border border-border-subtle overflow-hidden bg-bg-sunken",
|
|
2384
|
-
children: [/* @__PURE__ */
|
|
2386
|
+
children: [/* @__PURE__ */ U("img", {
|
|
2385
2387
|
src: e,
|
|
2386
2388
|
alt: `Screenshot ${t + 1}`,
|
|
2387
2389
|
className: "w-full h-full object-cover"
|
|
2388
|
-
}), /* @__PURE__ */
|
|
2390
|
+
}), /* @__PURE__ */ U("button", {
|
|
2389
2391
|
type: "button",
|
|
2390
2392
|
onClick: () => f(t),
|
|
2391
2393
|
className: "absolute top-1 right-1 rounded-full bg-bg-overlay text-white p-0.5 opacity-0 group-hover:opacity-100 transition-opacity",
|
|
2392
|
-
children: /* @__PURE__ */
|
|
2394
|
+
children: /* @__PURE__ */ U(Le, { size: 12 })
|
|
2393
2395
|
})]
|
|
2394
|
-
}, t)), /* @__PURE__ */
|
|
2396
|
+
}, t)), /* @__PURE__ */ U("button", {
|
|
2395
2397
|
type: "button",
|
|
2396
2398
|
disabled: i,
|
|
2397
2399
|
onClick: () => s.current?.click(),
|
|
2398
2400
|
className: t("w-36 aspect-video rounded-lg border-2 border-dashed border-border-subtle 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"),
|
|
2399
|
-
children: i ? /* @__PURE__ */
|
|
2401
|
+
children: i ? /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(R, {
|
|
2400
2402
|
size: 18,
|
|
2401
2403
|
className: "animate-spin text-primary"
|
|
2402
|
-
}), /* @__PURE__ */
|
|
2404
|
+
}), /* @__PURE__ */ W("span", {
|
|
2403
2405
|
className: "text-xs",
|
|
2404
2406
|
children: [a, "%"]
|
|
2405
|
-
})] }) : /* @__PURE__ */
|
|
2407
|
+
})] }) : /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(B, { size: 18 }), /* @__PURE__ */ U("span", {
|
|
2406
2408
|
className: "text-xs",
|
|
2407
2409
|
children: "Add screenshot"
|
|
2408
2410
|
})] })
|
|
2409
2411
|
})]
|
|
2410
2412
|
}),
|
|
2411
|
-
/* @__PURE__ */
|
|
2413
|
+
/* @__PURE__ */ W("div", {
|
|
2412
2414
|
className: "flex gap-2",
|
|
2413
|
-
children: [/* @__PURE__ */
|
|
2415
|
+
children: [/* @__PURE__ */ U("input", {
|
|
2414
2416
|
type: "url",
|
|
2415
2417
|
value: c,
|
|
2416
2418
|
onChange: (e) => l(e.target.value),
|
|
@@ -2419,7 +2421,7 @@ var Ue = [
|
|
|
2419
2421
|
},
|
|
2420
2422
|
placeholder: "https://... paste a screenshot URL",
|
|
2421
2423
|
className: "flex-1 rounded-md border border-border-subtle bg-bg-input px-3 py-1.5 text-sm placeholder:text-text-placeholder focus:outline-none focus:ring-2 focus:ring-primary/30"
|
|
2422
|
-
}), /* @__PURE__ */
|
|
2424
|
+
}), /* @__PURE__ */ U("button", {
|
|
2423
2425
|
type: "button",
|
|
2424
2426
|
onClick: d,
|
|
2425
2427
|
disabled: !c.trim(),
|
|
@@ -2427,7 +2429,7 @@ var Ue = [
|
|
|
2427
2429
|
children: "Add"
|
|
2428
2430
|
})]
|
|
2429
2431
|
}),
|
|
2430
|
-
/* @__PURE__ */
|
|
2432
|
+
/* @__PURE__ */ U("input", {
|
|
2431
2433
|
ref: s,
|
|
2432
2434
|
type: "file",
|
|
2433
2435
|
accept: "image/png,image/jpeg,image/webp,image/gif",
|
|
@@ -2437,19 +2439,19 @@ var Ue = [
|
|
|
2437
2439
|
t && u(t), e.target.value = "";
|
|
2438
2440
|
}
|
|
2439
2441
|
}),
|
|
2440
|
-
o && /* @__PURE__ */
|
|
2442
|
+
o && /* @__PURE__ */ U("p", {
|
|
2441
2443
|
className: "text-xs text-status-error-text",
|
|
2442
2444
|
children: o
|
|
2443
2445
|
})
|
|
2444
2446
|
]
|
|
2445
2447
|
});
|
|
2446
|
-
},
|
|
2448
|
+
}, lt = new Set(["workflow", "template"]), ut = [{
|
|
2447
2449
|
value: "FREE",
|
|
2448
2450
|
label: "Free"
|
|
2449
2451
|
}, {
|
|
2450
2452
|
value: "PAID",
|
|
2451
2453
|
label: "Paid"
|
|
2452
|
-
}],
|
|
2454
|
+
}], dt = {
|
|
2453
2455
|
NODE: [
|
|
2454
2456
|
{
|
|
2455
2457
|
value: "node",
|
|
@@ -2521,12 +2523,12 @@ var Ue = [
|
|
|
2521
2523
|
label: "Plugin"
|
|
2522
2524
|
}
|
|
2523
2525
|
]
|
|
2524
|
-
},
|
|
2526
|
+
}, ft = {
|
|
2525
2527
|
NODE: "node",
|
|
2526
2528
|
WORKFLOW: "workflow",
|
|
2527
2529
|
APP: "app"
|
|
2528
2530
|
};
|
|
2529
|
-
function
|
|
2531
|
+
function pt(e) {
|
|
2530
2532
|
let t = e.manifest ?? {}, n = t.identity ?? {}, r = (t.digital ?? {}).install ?? {}, i = t.compatibility ?? {}, a = Array.isArray(t.permissions) ? t.permissions : [], o = Array.isArray(e.screenshots) ? e.screenshots.join("\n") : "";
|
|
2531
2533
|
return {
|
|
2532
2534
|
iconUrl: e.iconUrl ?? "",
|
|
@@ -2541,7 +2543,7 @@ function ut(e) {
|
|
|
2541
2543
|
supportUrl: e.supportUrl ?? "",
|
|
2542
2544
|
privacyPolicyUrl: e.privacyPolicyUrl ?? "",
|
|
2543
2545
|
termsOfServiceUrl: e.termsOfServiceUrl ?? "",
|
|
2544
|
-
manifestItemType: typeof t.itemType == "string" ? t.itemType :
|
|
2546
|
+
manifestItemType: typeof t.itemType == "string" ? t.itemType : ft[e.appType] ?? "",
|
|
2545
2547
|
manifestDisplayName: typeof n.displayName == "string" ? n.displayName : e.name ?? "",
|
|
2546
2548
|
manifestVersion: typeof n.version == "string" ? n.version : "",
|
|
2547
2549
|
manifestInstallType: typeof r.type == "string" ? r.type : "zip",
|
|
@@ -2552,15 +2554,15 @@ function ut(e) {
|
|
|
2552
2554
|
manifestJsonContent: typeof t.jsonContent == "string" ? t.jsonContent : typeof t.content == "string" ? t.content : ""
|
|
2553
2555
|
};
|
|
2554
2556
|
}
|
|
2555
|
-
var
|
|
2557
|
+
var mt = ({ app: t, versionCount: n = 0, isPackageApp: r = !1, pricingDone: i = !1, onNavigateToVersions: a, onNavigateToPricing: o, onNavigateToSubmission: s }) => {
|
|
2556
2558
|
let { workspacesGatewayUrl: c, authToken: l, workspaceId: u, getWorkspaceToken: d } = e(), { t: f } = P(), p = (e, t) => {
|
|
2557
2559
|
let n = f(e);
|
|
2558
2560
|
return n === e ? t : n;
|
|
2559
|
-
}, [m, h] = N(() =>
|
|
2561
|
+
}, [m, h] = N(() => pt(t)), [g, _] = N(!1), [v, y] = N(null), x = M(pt(t)), C = M(t);
|
|
2560
2562
|
C.current = t;
|
|
2561
2563
|
let w = JSON.stringify(m) !== JSON.stringify(x.current), [T] = b();
|
|
2562
|
-
|
|
2563
|
-
let e =
|
|
2564
|
+
de(() => {
|
|
2565
|
+
let e = pt(C.current);
|
|
2564
2566
|
h(e), x.current = e, y(null);
|
|
2565
2567
|
}, [t.id]);
|
|
2566
2568
|
let E = (e, t) => {
|
|
@@ -2571,7 +2573,7 @@ var dt = ({ app: t, versionCount: n = 0, isPackageApp: r = !1, pricingDone: i =
|
|
|
2571
2573
|
}, D = m.shortDescription.trim().length > 0 && m.privacyPolicyUrl.trim().length > 0 && m.termsOfServiceUrl.trim().length > 0, ee = async () => {
|
|
2572
2574
|
_(!0), y(null);
|
|
2573
2575
|
try {
|
|
2574
|
-
let e = m.screenshotsText.split("\n").map((e) => e.trim()).filter(Boolean), n = m.manifestPermissionsText.split("\n").map((e) => e.trim()).filter(Boolean), r =
|
|
2576
|
+
let e = m.screenshotsText.split("\n").map((e) => e.trim()).filter(Boolean), n = m.manifestPermissionsText.split("\n").map((e) => e.trim()).filter(Boolean), r = lt.has(m.manifestItemType), i = t.manifest ?? {}, a = {
|
|
2575
2577
|
manifestVersion: typeof i.manifestVersion == "string" ? i.manifestVersion : "1.0",
|
|
2576
2578
|
itemType: m.manifestItemType || void 0,
|
|
2577
2579
|
identity: {
|
|
@@ -2608,21 +2610,21 @@ var dt = ({ app: t, versionCount: n = 0, isPackageApp: r = !1, pricingDone: i =
|
|
|
2608
2610
|
} finally {
|
|
2609
2611
|
_(!1);
|
|
2610
2612
|
}
|
|
2611
|
-
}, { upload: te, uploading: ne, progress: ae, error: oe } =
|
|
2612
|
-
return /* @__PURE__ */
|
|
2613
|
+
}, { upload: te, uploading: ne, progress: ae, error: oe } = ue(c, l, u, d, "/DevPortal/Assets"), { upload: ce, uploading: le, progress: A, error: j } = ue(c, l, u, d, "/DevPortal/Assets"), { upload: fe, uploading: me, progress: he, error: I } = ue(c, l, u, d, "/DevPortal/Assets"), ye = lt.has(m.manifestItemType), be = t.status === "SUBMITTED";
|
|
2614
|
+
return /* @__PURE__ */ W("div", {
|
|
2613
2615
|
className: "space-y-8 max-w-3xl",
|
|
2614
2616
|
children: [
|
|
2615
|
-
t.status === "PUBLISHED" ? /* @__PURE__ */
|
|
2617
|
+
t.status === "PUBLISHED" ? /* @__PURE__ */ W("div", {
|
|
2616
2618
|
className: "flex items-start gap-3 rounded-lg border border-success/30 bg-success/10 px-4 py-3",
|
|
2617
|
-
children: [/* @__PURE__ */
|
|
2619
|
+
children: [/* @__PURE__ */ U(ge, {
|
|
2618
2620
|
size: 16,
|
|
2619
2621
|
className: "text-success mt-0.5 shrink-0"
|
|
2620
|
-
}), /* @__PURE__ */
|
|
2622
|
+
}), /* @__PURE__ */ W("div", {
|
|
2621
2623
|
className: "text-sm",
|
|
2622
|
-
children: [/* @__PURE__ */
|
|
2624
|
+
children: [/* @__PURE__ */ U("span", {
|
|
2623
2625
|
className: "font-medium text-success",
|
|
2624
2626
|
children: p("devportal.storeListing.published", "Published")
|
|
2625
|
-
}), t.publishedAt && /* @__PURE__ */
|
|
2627
|
+
}), t.publishedAt && /* @__PURE__ */ W("span", {
|
|
2626
2628
|
className: "text-text-secondary ml-2",
|
|
2627
2629
|
children: [
|
|
2628
2630
|
p("devportal.storeListing.since", "since"),
|
|
@@ -2631,76 +2633,76 @@ var dt = ({ app: t, versionCount: n = 0, isPackageApp: r = !1, pricingDone: i =
|
|
|
2631
2633
|
]
|
|
2632
2634
|
})]
|
|
2633
2635
|
})]
|
|
2634
|
-
}) :
|
|
2636
|
+
}) : be ? /* @__PURE__ */ W("div", {
|
|
2635
2637
|
className: "flex items-center justify-between gap-3 rounded-lg border border-primary/30 bg-action-primary-bg/5 px-4 py-3",
|
|
2636
|
-
children: [/* @__PURE__ */
|
|
2638
|
+
children: [/* @__PURE__ */ W("div", {
|
|
2637
2639
|
className: "flex items-start gap-3",
|
|
2638
|
-
children: [/* @__PURE__ */
|
|
2640
|
+
children: [/* @__PURE__ */ U(ve, {
|
|
2639
2641
|
size: 16,
|
|
2640
2642
|
className: "text-primary mt-0.5 shrink-0"
|
|
2641
|
-
}), /* @__PURE__ */
|
|
2643
|
+
}), /* @__PURE__ */ W("div", {
|
|
2642
2644
|
className: "text-sm",
|
|
2643
2645
|
children: [
|
|
2644
|
-
/* @__PURE__ */
|
|
2646
|
+
/* @__PURE__ */ U("span", {
|
|
2645
2647
|
className: "font-medium text-primary",
|
|
2646
2648
|
children: p("devportal.storeListing.underReview", "Submitted for review")
|
|
2647
2649
|
}),
|
|
2648
|
-
t.submittedAt && /* @__PURE__ */
|
|
2650
|
+
t.submittedAt && /* @__PURE__ */ U("span", {
|
|
2649
2651
|
className: "text-text-secondary ml-2",
|
|
2650
2652
|
children: new Date(t.submittedAt).toLocaleDateString()
|
|
2651
2653
|
}),
|
|
2652
|
-
t.reviewStatus && /* @__PURE__ */
|
|
2654
|
+
t.reviewStatus && /* @__PURE__ */ W("span", {
|
|
2653
2655
|
className: "text-text-secondary ml-2",
|
|
2654
2656
|
children: ["· ", t.reviewStatus]
|
|
2655
2657
|
})
|
|
2656
2658
|
]
|
|
2657
2659
|
})]
|
|
2658
|
-
}), s && /* @__PURE__ */
|
|
2660
|
+
}), s && /* @__PURE__ */ W("button", {
|
|
2659
2661
|
type: "button",
|
|
2660
2662
|
onClick: s,
|
|
2661
2663
|
className: "shrink-0 text-xs text-primary hover:underline font-medium flex items-center gap-1",
|
|
2662
|
-
children: [p("devportal.viewStatus", "View Status"), /* @__PURE__ */
|
|
2664
|
+
children: [p("devportal.viewStatus", "View Status"), /* @__PURE__ */ U(L, { size: 12 })]
|
|
2663
2665
|
})]
|
|
2664
|
-
}) : /* @__PURE__ */
|
|
2666
|
+
}) : /* @__PURE__ */ W("div", {
|
|
2665
2667
|
className: "flex items-start gap-3 rounded-lg border border-warning/30 bg-warning/5 px-4 py-3",
|
|
2666
|
-
children: [/* @__PURE__ */
|
|
2668
|
+
children: [/* @__PURE__ */ U(pe, {
|
|
2667
2669
|
size: 16,
|
|
2668
2670
|
className: "text-warning mt-0.5 shrink-0"
|
|
2669
|
-
}), /* @__PURE__ */
|
|
2671
|
+
}), /* @__PURE__ */ W("div", {
|
|
2670
2672
|
className: "text-sm",
|
|
2671
|
-
children: [/* @__PURE__ */
|
|
2673
|
+
children: [/* @__PURE__ */ U("span", {
|
|
2672
2674
|
className: "font-medium text-warning",
|
|
2673
2675
|
children: p("devportal.storeListing.draft", "Draft")
|
|
2674
|
-
}), /* @__PURE__ */
|
|
2676
|
+
}), /* @__PURE__ */ U("span", {
|
|
2675
2677
|
className: "text-text-secondary ml-2",
|
|
2676
2678
|
children: p("devportal.storeListing.draftHint", "Complete your store listing and submit for review to publish.")
|
|
2677
2679
|
})]
|
|
2678
2680
|
})]
|
|
2679
2681
|
}),
|
|
2680
|
-
/* @__PURE__ */
|
|
2682
|
+
/* @__PURE__ */ U(S, {
|
|
2681
2683
|
title: p("devportal.package", "Package"),
|
|
2682
2684
|
description: p("devportal.packageDescription", "Technical configuration — how FluidGrid installs and runs this item"),
|
|
2683
|
-
children: /* @__PURE__ */
|
|
2685
|
+
children: /* @__PURE__ */ W("div", {
|
|
2684
2686
|
className: "space-y-6",
|
|
2685
2687
|
children: [
|
|
2686
|
-
/* @__PURE__ */
|
|
2688
|
+
/* @__PURE__ */ U(re, {
|
|
2687
2689
|
label: p("devportal.storeItemType", "Item Type"),
|
|
2688
2690
|
value: m.manifestItemType,
|
|
2689
2691
|
onChange: (e) => {
|
|
2690
2692
|
let t = e.target.value;
|
|
2691
|
-
E("manifestItemType", t),
|
|
2693
|
+
E("manifestItemType", t), lt.has(t) ? E("manifestInstallType", "json") : m.manifestInstallType === "json" && E("manifestInstallType", "zip");
|
|
2692
2694
|
},
|
|
2693
|
-
options:
|
|
2695
|
+
options: dt[t.appType] ?? dt.APP,
|
|
2694
2696
|
placeholder: p("devportal.selectItemType", "Select item type…"),
|
|
2695
2697
|
hint: p("devportal.storeItemTypeHint", "Sub-category shown in the marketplace (e.g. Node vs Agent vs Parser)")
|
|
2696
2698
|
}),
|
|
2697
|
-
/* @__PURE__ */
|
|
2699
|
+
/* @__PURE__ */ U(k, {
|
|
2698
2700
|
label: p("devportal.manifestDisplayName", "Display Name"),
|
|
2699
2701
|
value: m.manifestDisplayName,
|
|
2700
2702
|
onChange: (e) => E("manifestDisplayName", e.target.value),
|
|
2701
2703
|
placeholder: "My Awesome Node"
|
|
2702
2704
|
}),
|
|
2703
|
-
|
|
2705
|
+
ye && /* @__PURE__ */ U(ie, {
|
|
2704
2706
|
label: t.appType === "WORKFLOW" ? p("devportal.workflowJsonContent", "Workflow Canvas Definition (JSON)") : p("devportal.jsonContent", "Template Definition (JSON)"),
|
|
2705
2707
|
value: m.manifestJsonContent,
|
|
2706
2708
|
onChange: (e) => E("manifestJsonContent", e.target.value),
|
|
@@ -2711,15 +2713,15 @@ var dt = ({ app: t, versionCount: n = 0, isPackageApp: r = !1, pricingDone: i =
|
|
|
2711
2713
|
]
|
|
2712
2714
|
})
|
|
2713
2715
|
}),
|
|
2714
|
-
/* @__PURE__ */
|
|
2716
|
+
/* @__PURE__ */ U(S, {
|
|
2715
2717
|
title: p("devportal.storePresentation", "Store Presence"),
|
|
2716
2718
|
description: p("devportal.storePresentationDescription", "Visual assets and copy shown to users browsing the marketplace"),
|
|
2717
|
-
children: /* @__PURE__ */
|
|
2719
|
+
children: /* @__PURE__ */ W("div", {
|
|
2718
2720
|
className: "space-y-5",
|
|
2719
2721
|
children: [
|
|
2720
|
-
/* @__PURE__ */
|
|
2722
|
+
/* @__PURE__ */ W("div", {
|
|
2721
2723
|
className: "grid gap-5 sm:grid-cols-2",
|
|
2722
|
-
children: [/* @__PURE__ */
|
|
2724
|
+
children: [/* @__PURE__ */ U(st, {
|
|
2723
2725
|
label: p("devportal.iconUrl", "Icon"),
|
|
2724
2726
|
value: m.iconUrl,
|
|
2725
2727
|
onChange: (e) => E("iconUrl", e),
|
|
@@ -2729,89 +2731,89 @@ var dt = ({ app: t, versionCount: n = 0, isPackageApp: r = !1, pricingDone: i =
|
|
|
2729
2731
|
uploading: ne,
|
|
2730
2732
|
progress: ae,
|
|
2731
2733
|
error: oe
|
|
2732
|
-
}), /* @__PURE__ */
|
|
2734
|
+
}), /* @__PURE__ */ U(st, {
|
|
2733
2735
|
label: p("devportal.bannerUrl", "Banner"),
|
|
2734
2736
|
value: m.bannerUrl,
|
|
2735
2737
|
onChange: (e) => E("bannerUrl", e),
|
|
2736
2738
|
hint: p("devportal.bannerUrlHint", "Fills the right panel on the product page — square or portrait works best on all screen sizes (1:1)"),
|
|
2737
2739
|
aspectClass: "aspect-square",
|
|
2738
|
-
upload:
|
|
2739
|
-
uploading:
|
|
2740
|
+
upload: ce,
|
|
2741
|
+
uploading: le,
|
|
2740
2742
|
progress: A,
|
|
2741
2743
|
error: j
|
|
2742
2744
|
})]
|
|
2743
2745
|
}),
|
|
2744
|
-
/* @__PURE__ */
|
|
2746
|
+
/* @__PURE__ */ U(k, {
|
|
2745
2747
|
label: p("devportal.videoUrl", "Demo Video URL"),
|
|
2746
2748
|
value: m.videoUrl,
|
|
2747
2749
|
onChange: (e) => E("videoUrl", e.target.value),
|
|
2748
2750
|
placeholder: "https://...",
|
|
2749
2751
|
hint: p("devportal.videoUrlHint", "YouTube or Vimeo embed URL")
|
|
2750
2752
|
}),
|
|
2751
|
-
/* @__PURE__ */
|
|
2753
|
+
/* @__PURE__ */ U(se, {
|
|
2752
2754
|
label: p("devportal.shortDescription", "Short Description"),
|
|
2753
2755
|
value: m.shortDescription,
|
|
2754
|
-
onChange: (e) => E("shortDescription", e
|
|
2756
|
+
onChange: (e) => E("shortDescription", e),
|
|
2755
2757
|
maxLength: 200,
|
|
2756
2758
|
rows: 2,
|
|
2757
2759
|
hint: `${m.shortDescription.length}/200 · ${p("devportal.shortDescHint", "Shown in search results and cards")}`
|
|
2758
2760
|
}),
|
|
2759
|
-
/* @__PURE__ */
|
|
2761
|
+
/* @__PURE__ */ U(se, {
|
|
2760
2762
|
label: p("devportal.longDescription", "Full Description"),
|
|
2761
2763
|
value: m.description,
|
|
2762
|
-
onChange: (e) => E("description", e
|
|
2764
|
+
onChange: (e) => E("description", e),
|
|
2763
2765
|
rows: 5,
|
|
2764
2766
|
hint: p("devportal.fullDescHint", "Markdown supported")
|
|
2765
2767
|
}),
|
|
2766
|
-
/* @__PURE__ */
|
|
2768
|
+
/* @__PURE__ */ U(ct, {
|
|
2767
2769
|
urls: m.screenshotsText.split("\n").map((e) => e.trim()).filter(Boolean),
|
|
2768
2770
|
onChange: (e) => E("screenshotsText", e.join("\n")),
|
|
2769
2771
|
upload: fe,
|
|
2770
|
-
uploading:
|
|
2771
|
-
progress:
|
|
2772
|
-
error:
|
|
2772
|
+
uploading: me,
|
|
2773
|
+
progress: he,
|
|
2774
|
+
error: I
|
|
2773
2775
|
})
|
|
2774
2776
|
]
|
|
2775
2777
|
})
|
|
2776
2778
|
}),
|
|
2777
|
-
/* @__PURE__ */
|
|
2779
|
+
/* @__PURE__ */ U(S, {
|
|
2778
2780
|
title: p("devportal.linksPolicies", "Links & Policies"),
|
|
2779
2781
|
description: p("devportal.linksPoliciesDescription", "External resources and legal documents — privacy policy and terms are required for store submission"),
|
|
2780
|
-
children: /* @__PURE__ */
|
|
2782
|
+
children: /* @__PURE__ */ W("div", {
|
|
2781
2783
|
className: "grid gap-4 sm:grid-cols-2",
|
|
2782
2784
|
children: [
|
|
2783
|
-
/* @__PURE__ */
|
|
2785
|
+
/* @__PURE__ */ U(k, {
|
|
2784
2786
|
label: p("devportal.websiteUrl", "Website"),
|
|
2785
2787
|
value: m.websiteUrl,
|
|
2786
2788
|
onChange: (e) => E("websiteUrl", e.target.value),
|
|
2787
2789
|
placeholder: "https://..."
|
|
2788
2790
|
}),
|
|
2789
|
-
/* @__PURE__ */
|
|
2791
|
+
/* @__PURE__ */ U(k, {
|
|
2790
2792
|
label: p("devportal.documentationUrl", "Documentation"),
|
|
2791
2793
|
value: m.documentationUrl,
|
|
2792
2794
|
onChange: (e) => E("documentationUrl", e.target.value),
|
|
2793
2795
|
placeholder: "https://..."
|
|
2794
2796
|
}),
|
|
2795
|
-
/* @__PURE__ */
|
|
2797
|
+
/* @__PURE__ */ U(k, {
|
|
2796
2798
|
label: p("devportal.githubUrl", "GitHub"),
|
|
2797
2799
|
value: m.githubUrl,
|
|
2798
2800
|
onChange: (e) => E("githubUrl", e.target.value),
|
|
2799
2801
|
placeholder: "https://github.com/..."
|
|
2800
2802
|
}),
|
|
2801
|
-
/* @__PURE__ */
|
|
2803
|
+
/* @__PURE__ */ U(k, {
|
|
2802
2804
|
label: p("devportal.supportUrl", "Support"),
|
|
2803
2805
|
value: m.supportUrl,
|
|
2804
2806
|
onChange: (e) => E("supportUrl", e.target.value),
|
|
2805
2807
|
placeholder: "https://..."
|
|
2806
2808
|
}),
|
|
2807
|
-
/* @__PURE__ */
|
|
2809
|
+
/* @__PURE__ */ U(k, {
|
|
2808
2810
|
label: `${p("devportal.privacyPolicyUrl", "Privacy Policy")} *`,
|
|
2809
2811
|
value: m.privacyPolicyUrl,
|
|
2810
2812
|
onChange: (e) => E("privacyPolicyUrl", e.target.value),
|
|
2811
2813
|
placeholder: "https://...",
|
|
2812
2814
|
hint: p("devportal.requiredForStore", "Required for store submission")
|
|
2813
2815
|
}),
|
|
2814
|
-
/* @__PURE__ */
|
|
2816
|
+
/* @__PURE__ */ U(k, {
|
|
2815
2817
|
label: `${p("devportal.termsOfServiceUrl", "Terms of Service")} *`,
|
|
2816
2818
|
value: m.termsOfServiceUrl,
|
|
2817
2819
|
onChange: (e) => E("termsOfServiceUrl", e.target.value),
|
|
@@ -2821,52 +2823,52 @@ var dt = ({ app: t, versionCount: n = 0, isPackageApp: r = !1, pricingDone: i =
|
|
|
2821
2823
|
]
|
|
2822
2824
|
})
|
|
2823
2825
|
}),
|
|
2824
|
-
/* @__PURE__ */
|
|
2826
|
+
/* @__PURE__ */ W("div", {
|
|
2825
2827
|
className: "border-t pt-6 space-y-3",
|
|
2826
2828
|
children: [
|
|
2827
|
-
v === "success" && /* @__PURE__ */
|
|
2829
|
+
v === "success" && /* @__PURE__ */ W("div", {
|
|
2828
2830
|
className: "flex items-center gap-2 rounded-md border border-success/30 bg-success/10 px-3 py-2 text-sm text-success",
|
|
2829
|
-
children: [/* @__PURE__ */
|
|
2831
|
+
children: [/* @__PURE__ */ U(ge, {
|
|
2830
2832
|
size: 15,
|
|
2831
2833
|
className: "shrink-0"
|
|
2832
2834
|
}), p("devportal.storeListing.savedSuccess", "Store listing saved successfully.")]
|
|
2833
2835
|
}),
|
|
2834
|
-
v === "error" && /* @__PURE__ */
|
|
2836
|
+
v === "error" && /* @__PURE__ */ W("div", {
|
|
2835
2837
|
className: "flex items-center gap-2 rounded-md border border-destructive/30 bg-destructive/10 px-3 py-2 text-sm text-destructive",
|
|
2836
|
-
children: [/* @__PURE__ */
|
|
2838
|
+
children: [/* @__PURE__ */ U(pe, {
|
|
2837
2839
|
size: 15,
|
|
2838
2840
|
className: "shrink-0"
|
|
2839
2841
|
}), p("devportal.storeListing.savedError", "Failed to save. Please try again.")]
|
|
2840
2842
|
}),
|
|
2841
|
-
/* @__PURE__ */
|
|
2843
|
+
/* @__PURE__ */ W("div", {
|
|
2842
2844
|
className: "flex flex-wrap items-center gap-3",
|
|
2843
2845
|
children: [
|
|
2844
|
-
/* @__PURE__ */
|
|
2846
|
+
/* @__PURE__ */ U("button", {
|
|
2845
2847
|
type: "button",
|
|
2846
2848
|
onClick: ee,
|
|
2847
2849
|
disabled: g || !D || !w,
|
|
2848
2850
|
title: D ? w ? void 0 : p("devportal.storeListing.noChanges", "All changes saved — edit any field to save again") : p("devportal.storeListing.requiredFieldsHint", "Fill in Short Description, Privacy Policy URL, and Terms of Service URL to save"),
|
|
2849
2851
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 transition-colors disabled:opacity-50 disabled:cursor-not-allowed",
|
|
2850
|
-
children: g ? /* @__PURE__ */
|
|
2852
|
+
children: g ? /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(R, {
|
|
2851
2853
|
size: 16,
|
|
2852
2854
|
className: "animate-spin"
|
|
2853
|
-
}), p("devportal.saving", "Saving…")] }) : w ? /* @__PURE__ */
|
|
2855
|
+
}), p("devportal.saving", "Saving…")] }) : w ? /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(Ne, { size: 16 }), p("devportal.saveStoreListing", "Save Store Listing")] }) : /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(F, { size: 16 }), p("devportal.saved", "Saved")] })
|
|
2854
2856
|
}),
|
|
2855
|
-
!D && /* @__PURE__ */
|
|
2857
|
+
!D && /* @__PURE__ */ U("p", {
|
|
2856
2858
|
className: "text-xs text-text-secondary",
|
|
2857
2859
|
children: p("devportal.storeListing.requiredFieldsLabel", "Short Description, Privacy Policy URL, and Terms of Service URL are required")
|
|
2858
2860
|
}),
|
|
2859
|
-
r && n === 0 && a && /* @__PURE__ */
|
|
2861
|
+
r && n === 0 && a && /* @__PURE__ */ W("button", {
|
|
2860
2862
|
type: "button",
|
|
2861
2863
|
onClick: a,
|
|
2862
2864
|
className: "inline-flex items-center gap-1.5 text-sm font-medium text-primary hover:underline underline-offset-2",
|
|
2863
|
-
children: [p("devportal.nextUploadVersion", "Next: Upload a Version"), /* @__PURE__ */
|
|
2865
|
+
children: [p("devportal.nextUploadVersion", "Next: Upload a Version"), /* @__PURE__ */ U(_e, { size: 15 })]
|
|
2864
2866
|
}),
|
|
2865
|
-
(!r || n > 0) && !i && o && /* @__PURE__ */
|
|
2867
|
+
(!r || n > 0) && !i && o && /* @__PURE__ */ W("button", {
|
|
2866
2868
|
type: "button",
|
|
2867
2869
|
onClick: o,
|
|
2868
2870
|
className: "inline-flex items-center gap-1.5 text-sm font-medium text-primary hover:underline underline-offset-2",
|
|
2869
|
-
children: [p("devportal.nextSetPricing", "Next: Set Pricing"), /* @__PURE__ */
|
|
2871
|
+
children: [p("devportal.nextSetPricing", "Next: Set Pricing"), /* @__PURE__ */ U(_e, { size: 15 })]
|
|
2870
2872
|
})
|
|
2871
2873
|
]
|
|
2872
2874
|
})
|
|
@@ -2874,21 +2876,21 @@ var dt = ({ app: t, versionCount: n = 0, isPackageApp: r = !1, pricingDone: i =
|
|
|
2874
2876
|
})
|
|
2875
2877
|
]
|
|
2876
2878
|
});
|
|
2877
|
-
},
|
|
2879
|
+
}, Q = ({ label: e, value: n, trend: r }) => {
|
|
2878
2880
|
let { t: i } = P();
|
|
2879
|
-
return /* @__PURE__ */
|
|
2881
|
+
return /* @__PURE__ */ W(He, {
|
|
2880
2882
|
treatment: "metric",
|
|
2881
2883
|
className: "p-4",
|
|
2882
2884
|
children: [
|
|
2883
|
-
/* @__PURE__ */
|
|
2885
|
+
/* @__PURE__ */ U("p", {
|
|
2884
2886
|
className: "text-sm text-text-secondary",
|
|
2885
2887
|
children: e
|
|
2886
2888
|
}),
|
|
2887
|
-
/* @__PURE__ */
|
|
2889
|
+
/* @__PURE__ */ U("p", {
|
|
2888
2890
|
className: "text-2xl font-bold tabular-nums",
|
|
2889
2891
|
children: n
|
|
2890
2892
|
}),
|
|
2891
|
-
r !== void 0 && /* @__PURE__ */
|
|
2893
|
+
r !== void 0 && /* @__PURE__ */ W("p", {
|
|
2892
2894
|
className: t("text-xs mt-1 tabular-nums", r > 0 ? "text-status-success-text" : r < 0 ? "text-status-error-text" : "text-text-secondary"),
|
|
2893
2895
|
children: [
|
|
2894
2896
|
r > 0 ? "+" : "",
|
|
@@ -2902,13 +2904,13 @@ var dt = ({ app: t, versionCount: n = 0, isPackageApp: r = !1, pricingDone: i =
|
|
|
2902
2904
|
})
|
|
2903
2905
|
]
|
|
2904
2906
|
});
|
|
2905
|
-
},
|
|
2907
|
+
}, $ = ({ label: e, url: t }) => /* @__PURE__ */ W("a", {
|
|
2906
2908
|
href: t,
|
|
2907
2909
|
target: "_blank",
|
|
2908
2910
|
rel: "noopener noreferrer",
|
|
2909
2911
|
className: "flex items-center gap-2 text-sm text-primary hover:underline",
|
|
2910
|
-
children: [/* @__PURE__ */
|
|
2911
|
-
}),
|
|
2912
|
+
children: [/* @__PURE__ */ U(L, { size: 14 }), e]
|
|
2913
|
+
}), ht = {
|
|
2912
2914
|
auth: {
|
|
2913
2915
|
label: "Authentication",
|
|
2914
2916
|
description: "User identity and session management"
|
|
@@ -2965,8 +2967,8 @@ var dt = ({ app: t, versionCount: n = 0, isPackageApp: r = !1, pricingDone: i =
|
|
|
2965
2967
|
label: "Roles & Permissions",
|
|
2966
2968
|
description: "Access control configuration"
|
|
2967
2969
|
}
|
|
2968
|
-
},
|
|
2969
|
-
function
|
|
2970
|
+
}, gt = Object.keys(ht);
|
|
2971
|
+
function _t(e) {
|
|
2970
2972
|
if (!e || !Array.isArray(e.permissions)) return [];
|
|
2971
2973
|
let t = [];
|
|
2972
2974
|
for (let n of e.permissions) n && typeof n == "object" && typeof n.resource == "string" && n.resource && t.push({
|
|
@@ -2975,7 +2977,7 @@ function ht(e) {
|
|
|
2975
2977
|
});
|
|
2976
2978
|
return t;
|
|
2977
2979
|
}
|
|
2978
|
-
function
|
|
2980
|
+
function vt(e) {
|
|
2979
2981
|
let t = [];
|
|
2980
2982
|
for (let n of e) {
|
|
2981
2983
|
let e = n.indexOf(":");
|
|
@@ -2988,21 +2990,21 @@ function gt(e) {
|
|
|
2988
2990
|
}
|
|
2989
2991
|
return t;
|
|
2990
2992
|
}
|
|
2991
|
-
function
|
|
2993
|
+
function yt(e, t) {
|
|
2992
2994
|
if (e.length > 0) return e;
|
|
2993
2995
|
let n = /* @__PURE__ */ new Set();
|
|
2994
2996
|
return t.filter((e) => n.has(e.resource) ? !1 : (n.add(e.resource), !0));
|
|
2995
2997
|
}
|
|
2996
|
-
var
|
|
2998
|
+
var bt = ({ level: e, onChange: t }) => /* @__PURE__ */ U("div", {
|
|
2997
2999
|
className: "flex items-center gap-0.5 rounded-md border border-border-subtle bg-bg-sunken/50 p-0.5",
|
|
2998
|
-
children: ["read", "write"].map((n) => /* @__PURE__ */
|
|
3000
|
+
children: ["read", "write"].map((n) => /* @__PURE__ */ U("button", {
|
|
2999
3001
|
type: "button",
|
|
3000
3002
|
onClick: () => t(n),
|
|
3001
3003
|
className: `rounded px-2.5 py-1 text-xs font-medium transition-colors whitespace-nowrap ${e === n ? "bg-bg-base text-text-primary shadow-sm" : "text-text-secondary hover:text-text-primary"}`,
|
|
3002
3004
|
children: n === "read" ? "Read" : "Read & Write"
|
|
3003
3005
|
}, n))
|
|
3004
|
-
}),
|
|
3005
|
-
let i = e.manifest ?? {}, [a, o] = N(() => _t(
|
|
3006
|
+
}), xt = ({ app: e, versionScopes: t, locked: n = !1, onNavigateToVersions: r }) => {
|
|
3007
|
+
let i = e.manifest ?? {}, [a, o] = N(() => yt(_t(i), vt(t ?? []))), [s, c] = N(!1), [l, u] = N(""), [d, f] = N("read"), [p, m] = N(!1), [h, g] = N(!1), [_] = b(), v = (e, t) => {
|
|
3006
3008
|
g(!1), o((n) => n.map((n) => n.resource === e ? {
|
|
3007
3009
|
...n,
|
|
3008
3010
|
level: t
|
|
@@ -3031,58 +3033,58 @@ var vt = ({ level: e, onChange: t }) => /* @__PURE__ */ G("div", {
|
|
|
3031
3033
|
} finally {
|
|
3032
3034
|
m(!1);
|
|
3033
3035
|
}
|
|
3034
|
-
}, w = /* @__PURE__ */
|
|
3036
|
+
}, w = /* @__PURE__ */ U("div", {
|
|
3035
3037
|
className: "rounded-lg border border-border-subtle divide-y divide-border-subtle",
|
|
3036
|
-
children: a.map((e) => /* @__PURE__ */
|
|
3038
|
+
children: a.map((e) => /* @__PURE__ */ W("div", {
|
|
3037
3039
|
className: "flex items-center gap-3 px-4 py-3 hover:bg-bg-sunken/30 transition-colors",
|
|
3038
|
-
children: [/* @__PURE__ */
|
|
3040
|
+
children: [/* @__PURE__ */ W("div", {
|
|
3039
3041
|
className: "flex-1 min-w-0",
|
|
3040
3042
|
children: [
|
|
3041
|
-
/* @__PURE__ */
|
|
3043
|
+
/* @__PURE__ */ U("p", {
|
|
3042
3044
|
className: "text-sm font-medium text-text-primary",
|
|
3043
|
-
children:
|
|
3045
|
+
children: ht[e.resource]?.label ?? e.resource
|
|
3044
3046
|
}),
|
|
3045
|
-
|
|
3047
|
+
ht[e.resource]?.description && /* @__PURE__ */ U("p", {
|
|
3046
3048
|
className: "text-xs text-text-secondary",
|
|
3047
|
-
children:
|
|
3049
|
+
children: ht[e.resource].description
|
|
3048
3050
|
}),
|
|
3049
|
-
!
|
|
3051
|
+
!ht[e.resource] && /* @__PURE__ */ U("p", {
|
|
3050
3052
|
className: "text-xs text-text-tertiary font-mono",
|
|
3051
3053
|
children: "custom scope"
|
|
3052
3054
|
})
|
|
3053
3055
|
]
|
|
3054
|
-
}), n ? /* @__PURE__ */
|
|
3056
|
+
}), n ? /* @__PURE__ */ U("span", {
|
|
3055
3057
|
className: `rounded-full px-2.5 py-0.5 text-xs font-medium ${e.level === "write" ? "bg-status-warning-bg text-status-warning-text" : "bg-bg-sunken text-text-secondary"}`,
|
|
3056
3058
|
children: e.level === "write" ? "Read & Write" : "Read"
|
|
3057
|
-
}) : /* @__PURE__ */
|
|
3059
|
+
}) : /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(bt, {
|
|
3058
3060
|
level: e.level,
|
|
3059
3061
|
onChange: (t) => v(e.resource, t)
|
|
3060
|
-
}), /* @__PURE__ */
|
|
3062
|
+
}), /* @__PURE__ */ U("button", {
|
|
3061
3063
|
type: "button",
|
|
3062
3064
|
onClick: () => y(e.resource),
|
|
3063
3065
|
title: "Remove permission",
|
|
3064
3066
|
className: "p-1.5 rounded text-text-tertiary hover:text-status-error-text hover:bg-status-error-bg-subtle transition-colors",
|
|
3065
|
-
children: /* @__PURE__ */
|
|
3067
|
+
children: /* @__PURE__ */ U(Le, { size: 14 })
|
|
3066
3068
|
})] })]
|
|
3067
3069
|
}, e.resource))
|
|
3068
3070
|
});
|
|
3069
|
-
return /* @__PURE__ */
|
|
3071
|
+
return /* @__PURE__ */ U(S, {
|
|
3070
3072
|
title: "Permissions",
|
|
3071
3073
|
description: "These are the permissions your app requests from users. Users see exactly this list when authorizing your app.",
|
|
3072
|
-
children: /* @__PURE__ */
|
|
3074
|
+
children: /* @__PURE__ */ U("div", {
|
|
3073
3075
|
className: "space-y-4",
|
|
3074
|
-
children: n ? /* @__PURE__ */
|
|
3076
|
+
children: n ? /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ W("div", {
|
|
3075
3077
|
className: "rounded-lg border border-status-warning-bg bg-status-warning-bg-subtle p-3 flex gap-2 text-sm",
|
|
3076
|
-
children: [/* @__PURE__ */
|
|
3078
|
+
children: [/* @__PURE__ */ U(Ce, {
|
|
3077
3079
|
size: 15,
|
|
3078
3080
|
className: "flex-shrink-0 mt-0.5 text-status-warning-text"
|
|
3079
|
-
}), /* @__PURE__ */
|
|
3081
|
+
}), /* @__PURE__ */ W("span", {
|
|
3080
3082
|
className: "text-status-warning-text",
|
|
3081
3083
|
children: [
|
|
3082
|
-
/* @__PURE__ */
|
|
3084
|
+
/* @__PURE__ */ U("strong", { children: "Permission changes require a new version." }),
|
|
3083
3085
|
" Your app is live and users have already consented to the permissions below. To request new or fewer permissions, publish a new version — existing users will be shown what changed and asked to re-consent before the new version takes effect.",
|
|
3084
3086
|
" ",
|
|
3085
|
-
r && /* @__PURE__ */
|
|
3087
|
+
r && /* @__PURE__ */ U("button", {
|
|
3086
3088
|
type: "button",
|
|
3087
3089
|
onClick: r,
|
|
3088
3090
|
className: "underline font-medium hover:opacity-80 transition-opacity",
|
|
@@ -3090,31 +3092,31 @@ var vt = ({ level: e, onChange: t }) => /* @__PURE__ */ G("div", {
|
|
|
3090
3092
|
})
|
|
3091
3093
|
]
|
|
3092
3094
|
})]
|
|
3093
|
-
}), a.length === 0 ? /* @__PURE__ */
|
|
3095
|
+
}), a.length === 0 ? /* @__PURE__ */ U("div", {
|
|
3094
3096
|
className: "rounded-lg border border-border-subtle border-dashed p-6 text-center text-sm text-text-secondary",
|
|
3095
3097
|
children: "No permissions configured for this version."
|
|
3096
|
-
}) : w] }) : /* @__PURE__ */
|
|
3097
|
-
a.length === 0 ? /* @__PURE__ */
|
|
3098
|
+
}) : w] }) : /* @__PURE__ */ W(H, { children: [
|
|
3099
|
+
a.length === 0 ? /* @__PURE__ */ W("div", {
|
|
3098
3100
|
className: "rounded-lg border border-border-subtle border-dashed p-8 flex flex-col items-center gap-2 text-center text-text-secondary",
|
|
3099
3101
|
children: [
|
|
3100
|
-
/* @__PURE__ */
|
|
3102
|
+
/* @__PURE__ */ U(z, {
|
|
3101
3103
|
size: 28,
|
|
3102
3104
|
className: "opacity-25"
|
|
3103
3105
|
}),
|
|
3104
|
-
/* @__PURE__ */
|
|
3106
|
+
/* @__PURE__ */ U("p", {
|
|
3105
3107
|
className: "text-sm font-medium text-text-primary",
|
|
3106
3108
|
children: "No permissions configured"
|
|
3107
3109
|
}),
|
|
3108
|
-
/* @__PURE__ */
|
|
3110
|
+
/* @__PURE__ */ U("p", {
|
|
3109
3111
|
className: "text-xs",
|
|
3110
3112
|
children: "Add the permissions your app needs to request from users."
|
|
3111
3113
|
})
|
|
3112
3114
|
]
|
|
3113
3115
|
}) : w,
|
|
3114
|
-
s ? /* @__PURE__ */
|
|
3116
|
+
s ? /* @__PURE__ */ W("div", {
|
|
3115
3117
|
className: "rounded-lg border border-border-subtle p-3 flex items-center gap-2 flex-wrap",
|
|
3116
3118
|
children: [
|
|
3117
|
-
/* @__PURE__ */
|
|
3119
|
+
/* @__PURE__ */ U("input", {
|
|
3118
3120
|
type: "text",
|
|
3119
3121
|
value: l,
|
|
3120
3122
|
onChange: (e) => u(e.target.value),
|
|
@@ -3126,60 +3128,60 @@ var vt = ({ level: e, onChange: t }) => /* @__PURE__ */ G("div", {
|
|
|
3126
3128
|
autoFocus: !0,
|
|
3127
3129
|
className: "flex-1 min-w-40 rounded-md border border-border-subtle bg-bg-base px-3 py-1.5 text-sm focus:outline-none focus:ring-1 focus:ring-primary"
|
|
3128
3130
|
}),
|
|
3129
|
-
/* @__PURE__ */
|
|
3131
|
+
/* @__PURE__ */ U("datalist", {
|
|
3130
3132
|
id: "perm-resource-suggestions",
|
|
3131
|
-
children:
|
|
3133
|
+
children: gt.filter((e) => !a.some((t) => t.resource === e)).map((e) => /* @__PURE__ */ U("option", {
|
|
3132
3134
|
value: e,
|
|
3133
|
-
children:
|
|
3135
|
+
children: ht[e].label
|
|
3134
3136
|
}, e))
|
|
3135
3137
|
}),
|
|
3136
|
-
/* @__PURE__ */
|
|
3138
|
+
/* @__PURE__ */ U(bt, {
|
|
3137
3139
|
level: d,
|
|
3138
3140
|
onChange: f
|
|
3139
3141
|
}),
|
|
3140
|
-
/* @__PURE__ */
|
|
3142
|
+
/* @__PURE__ */ U("button", {
|
|
3141
3143
|
type: "button",
|
|
3142
3144
|
onClick: x,
|
|
3143
3145
|
disabled: !l.trim(),
|
|
3144
3146
|
className: "px-3 py-1.5 rounded-md bg-action-primary-bg text-action-primary-text text-xs font-medium hover:bg-action-primary-bg/90 disabled:opacity-50 transition-colors",
|
|
3145
3147
|
children: "Add"
|
|
3146
3148
|
}),
|
|
3147
|
-
/* @__PURE__ */
|
|
3149
|
+
/* @__PURE__ */ U("button", {
|
|
3148
3150
|
type: "button",
|
|
3149
3151
|
onClick: () => {
|
|
3150
3152
|
c(!1), u("");
|
|
3151
3153
|
},
|
|
3152
3154
|
className: "p-1.5 rounded text-text-secondary hover:text-text-primary transition-colors",
|
|
3153
|
-
children: /* @__PURE__ */
|
|
3155
|
+
children: /* @__PURE__ */ U(Le, { size: 14 })
|
|
3154
3156
|
})
|
|
3155
3157
|
]
|
|
3156
|
-
}) : /* @__PURE__ */
|
|
3158
|
+
}) : /* @__PURE__ */ W("button", {
|
|
3157
3159
|
type: "button",
|
|
3158
3160
|
onClick: () => c(!0),
|
|
3159
3161
|
className: "flex items-center gap-1.5 text-sm text-text-secondary hover:text-text-primary transition-colors",
|
|
3160
|
-
children: [/* @__PURE__ */
|
|
3162
|
+
children: [/* @__PURE__ */ U(ke, { size: 14 }), "Add permission"]
|
|
3161
3163
|
}),
|
|
3162
|
-
/* @__PURE__ */
|
|
3164
|
+
/* @__PURE__ */ W("div", {
|
|
3163
3165
|
className: "rounded-lg border border-border-subtle bg-bg-sunken/30 p-3 flex gap-2 text-xs text-text-secondary",
|
|
3164
|
-
children: [/* @__PURE__ */
|
|
3166
|
+
children: [/* @__PURE__ */ U(Ce, {
|
|
3165
3167
|
size: 14,
|
|
3166
3168
|
className: "flex-shrink-0 mt-0.5"
|
|
3167
|
-
}), /* @__PURE__ */
|
|
3169
|
+
}), /* @__PURE__ */ W("span", { children: [/* @__PURE__ */ U("strong", { children: "Read & Write" }), " implies Read. Request only what your app genuinely needs — fewer permissions build more user trust."] })]
|
|
3168
3170
|
}),
|
|
3169
|
-
/* @__PURE__ */
|
|
3171
|
+
/* @__PURE__ */ W("div", {
|
|
3170
3172
|
className: "flex items-center justify-end gap-3",
|
|
3171
|
-
children: [h && /* @__PURE__ */
|
|
3173
|
+
children: [h && /* @__PURE__ */ W("span", {
|
|
3172
3174
|
className: "flex items-center gap-1.5 text-sm text-status-success-text",
|
|
3173
|
-
children: [/* @__PURE__ */
|
|
3174
|
-
}), /* @__PURE__ */
|
|
3175
|
+
children: [/* @__PURE__ */ U(ge, { size: 14 }), "Saved"]
|
|
3176
|
+
}), /* @__PURE__ */ W("button", {
|
|
3175
3177
|
type: "button",
|
|
3176
3178
|
onClick: () => void C(),
|
|
3177
3179
|
disabled: p,
|
|
3178
3180
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 transition-colors disabled:opacity-50",
|
|
3179
|
-
children: [p ? /* @__PURE__ */
|
|
3181
|
+
children: [p ? /* @__PURE__ */ U(R, {
|
|
3180
3182
|
size: 14,
|
|
3181
3183
|
className: "animate-spin"
|
|
3182
|
-
}) : /* @__PURE__ */
|
|
3184
|
+
}) : /* @__PURE__ */ U(z, { size: 14 }), "Save Permissions"]
|
|
3183
3185
|
})]
|
|
3184
3186
|
})
|
|
3185
3187
|
] })
|
|
@@ -3187,6 +3189,6 @@ var vt = ({ level: e, onChange: t }) => /* @__PURE__ */ G("div", {
|
|
|
3187
3189
|
});
|
|
3188
3190
|
};
|
|
3189
3191
|
//#endregion
|
|
3190
|
-
export {
|
|
3192
|
+
export { Ke as ApplicationDetailPage };
|
|
3191
3193
|
|
|
3192
3194
|
//# sourceMappingURL=ApplicationDetailPage.js.map
|