@burdenoff/microfe-devportal 2026.915.8 → 2026.915.10
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/RegisterPickupLocationModal.d.ts.map +1 -1
- package/dist/devportal/components/RegisterPickupLocationModal.js +83 -83
- package/dist/devportal/components/RegisterPickupLocationModal.js.map +1 -1
- package/dist/devportal/pages/OrganizationDetailPage.d.ts.map +1 -1
- package/dist/devportal/pages/OrganizationDetailPage.js +278 -275
- package/dist/devportal/pages/OrganizationDetailPage.js.map +1 -1
- package/package.json +1 -1
|
@@ -16,14 +16,14 @@ import { capitalizeCarrierName as b, useCarrierPickupLocations as re } from "../
|
|
|
16
16
|
import { DEVPORTAL_PERMISSIONS as x } from "../constants/permissions.js";
|
|
17
17
|
import { useOrganizationPickupAddresses as S } from "../hooks/useOrganizationPickupAddresses.js";
|
|
18
18
|
import { useEffect as C, useState as w } from "react";
|
|
19
|
-
import { AlertCircle as ie, AppWindow as T, ArrowRight as E, BarChart3 as D, Building2 as O, CheckCircle as k, DollarSign as A, ExternalLink as j, Loader2 as M, Plus as N, Settings as ae, Shield as
|
|
20
|
-
import { useParams as
|
|
21
|
-
import { Fragment as
|
|
22
|
-
import { useI18n as
|
|
23
|
-
import { EmphasisPanel as
|
|
24
|
-
import { graphqlFetch as W } from "@burdenoff/fe-libs/shared/graphql";
|
|
19
|
+
import { AlertCircle as ie, AppWindow as T, ArrowRight as E, BarChart3 as D, Building2 as O, CheckCircle as k, DollarSign as A, ExternalLink as j, Loader2 as M, Plus as N, Settings as ae, Shield as oe, Trash2 as P, TrendingUp as F, Users as I } from "lucide-react";
|
|
20
|
+
import { useParams as L } from "react-router";
|
|
21
|
+
import { Fragment as R, jsx as z, jsxs as B } from "react/jsx-runtime";
|
|
22
|
+
import { useI18n as V } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
23
|
+
import { EmphasisPanel as H, NextSteps as U } from "@burdenoff/fe-libs/ui";
|
|
24
|
+
import { clearGraphqlFetchResponseCache as se, graphqlFetch as W } from "@burdenoff/fe-libs/shared/graphql";
|
|
25
25
|
//#region src/devportal/pages/OrganizationDetailPage.tsx
|
|
26
|
-
var
|
|
26
|
+
var ce = "\n query OrganizationVerificationDetails($id: ID!) {\n developerOrganization(id: $id) {\n id\n verificationMethod\n verificationRequestedAt\n verificationStatus\n verificationRequestNotes\n verificationEvidenceUrl\n verificationDomain\n verificationRequestedBy\n verificationReviewedAt\n verificationReviewedBy\n verificationReviewNotes\n verificationRejectedReason\n }\n }\n", le = "\n mutation RequestOrgVerificationExtended(\n $id: ID!\n $method: String!\n $notes: String\n $evidenceUrl: String\n $domain: String\n ) {\n requestOrgVerification(\n id: $id\n method: $method\n notes: $notes\n evidenceUrl: $evidenceUrl\n domain: $domain\n ) {\n id\n verificationMethod\n verificationRequestedAt\n verificationStatus\n verificationRequestNotes\n verificationEvidenceUrl\n verificationDomain\n verificationRejectedReason\n }\n }\n";
|
|
27
27
|
function G(e) {
|
|
28
28
|
let t = e;
|
|
29
29
|
return {
|
|
@@ -100,11 +100,11 @@ function K(e) {
|
|
|
100
100
|
updatedAt: e.updatedAt
|
|
101
101
|
};
|
|
102
102
|
}
|
|
103
|
-
function
|
|
103
|
+
function ue(e) {
|
|
104
104
|
let t = e.trim().toLowerCase();
|
|
105
105
|
return /^[a-z0-9.-]+\.[a-z]{2,}$/i.test(t) && !t.includes("@");
|
|
106
106
|
}
|
|
107
|
-
function
|
|
107
|
+
function de(e) {
|
|
108
108
|
try {
|
|
109
109
|
let t = new URL(e.trim());
|
|
110
110
|
return t.protocol === "http:" || t.protocol === "https:";
|
|
@@ -112,17 +112,17 @@ function q(e) {
|
|
|
112
112
|
return !1;
|
|
113
113
|
}
|
|
114
114
|
}
|
|
115
|
-
function
|
|
115
|
+
function fe(e) {
|
|
116
116
|
let t = e.trim();
|
|
117
117
|
return /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(t);
|
|
118
118
|
}
|
|
119
|
-
var
|
|
119
|
+
var q = {
|
|
120
120
|
VIEWER: 0,
|
|
121
121
|
DEVELOPER: 1,
|
|
122
122
|
ADMIN: 2,
|
|
123
123
|
OWNER: 3
|
|
124
|
-
},
|
|
125
|
-
let { navigate: n, basePath: s, setActiveOrgId: c, setActivePhysicalOrgId: l, currentUser: d } = e(), f = i(), { orgId: p } =
|
|
124
|
+
}, J = () => {
|
|
125
|
+
let { navigate: n, basePath: s, setActiveOrgId: c, setActivePhysicalOrgId: l, currentUser: d } = e(), f = i(), { orgId: p } = L(), { t: m } = V(), h = (e, t) => {
|
|
126
126
|
let n = m(e);
|
|
127
127
|
return n === e ? t : n;
|
|
128
128
|
}, [g, _] = w("overview"), v = [
|
|
@@ -139,7 +139,7 @@ var J = {
|
|
|
139
139
|
{
|
|
140
140
|
id: "members",
|
|
141
141
|
label: h("devportal.members", "Members"),
|
|
142
|
-
icon:
|
|
142
|
+
icon: I
|
|
143
143
|
},
|
|
144
144
|
{
|
|
145
145
|
id: "settings",
|
|
@@ -156,7 +156,7 @@ var J = {
|
|
|
156
156
|
},
|
|
157
157
|
skip: !p,
|
|
158
158
|
fetchPolicy: "cache-and-network"
|
|
159
|
-
}), x = (b?.developerOrganization?.members ?? []).map(K), S = (d ? x.find((e) => e.userId === d.id) : void 0)?.role, E = S !== void 0 &&
|
|
159
|
+
}), x = (b?.developerOrganization?.members ?? []).map(K), S = (d ? x.find((e) => e.userId === d.id) : void 0)?.role, E = S !== void 0 && q[S] >= q.DEVELOPER, D = S !== void 0 && q[S] >= q.ADMIN, k = D, j = D, oe = v.filter((e) => e.id !== "settings" || D), P = (e) => {
|
|
160
160
|
n?.(`${s}${e}`);
|
|
161
161
|
};
|
|
162
162
|
if (C(() => {
|
|
@@ -173,211 +173,211 @@ var J = {
|
|
|
173
173
|
if (!p || !e) return;
|
|
174
174
|
let t = window.__breadcrumbRegistry;
|
|
175
175
|
return t?.register(p, e), () => t?.unregister(p);
|
|
176
|
-
}, [p, y?.developerOrganization?.name]), te && !b) return /* @__PURE__ */
|
|
176
|
+
}, [p, y?.developerOrganization?.name]), te && !b) return /* @__PURE__ */ z(u, {
|
|
177
177
|
title: h("devportal.loadingDots", "Loading..."),
|
|
178
178
|
backLink: `${s}${r(f)}`,
|
|
179
179
|
backLabel: h("devportal.backToOrganizations", "Back to Organizations"),
|
|
180
|
-
children: /* @__PURE__ */
|
|
180
|
+
children: /* @__PURE__ */ z("div", {
|
|
181
181
|
className: "flex items-center justify-center py-12",
|
|
182
|
-
children: /* @__PURE__ */
|
|
182
|
+
children: /* @__PURE__ */ z(M, { className: "h-8 w-8 animate-spin text-text-secondary" })
|
|
183
183
|
})
|
|
184
184
|
});
|
|
185
|
-
if (ne || !b?.developerOrganization) return /* @__PURE__ */
|
|
185
|
+
if (ne || !b?.developerOrganization) return /* @__PURE__ */ z(u, {
|
|
186
186
|
title: h("devportal.organizationNotFound", "Organization Not Found"),
|
|
187
187
|
backLink: `${s}${r(f)}`,
|
|
188
188
|
backLabel: h("devportal.backToOrganizations", "Back to Organizations"),
|
|
189
|
-
children: /* @__PURE__ */
|
|
189
|
+
children: /* @__PURE__ */ B("div", {
|
|
190
190
|
className: "flex flex-col items-center justify-center py-12 gap-4",
|
|
191
191
|
children: [
|
|
192
|
-
/* @__PURE__ */
|
|
193
|
-
/* @__PURE__ */
|
|
192
|
+
/* @__PURE__ */ z(ie, { className: "h-12 w-12 text-status-error-text" }),
|
|
193
|
+
/* @__PURE__ */ z("h2", {
|
|
194
194
|
className: "text-lg font-semibold",
|
|
195
195
|
children: h("devportal.organizationNotFoundLower", "Organization not found")
|
|
196
196
|
}),
|
|
197
|
-
/* @__PURE__ */
|
|
197
|
+
/* @__PURE__ */ z("p", {
|
|
198
198
|
className: "text-text-secondary",
|
|
199
199
|
children: ne?.message || h("devportal.organizationNotFoundDescription", "The organization you're looking for doesn't exist or you don't have access to it.")
|
|
200
200
|
}),
|
|
201
|
-
/* @__PURE__ */
|
|
202
|
-
onClick: () =>
|
|
201
|
+
/* @__PURE__ */ z("button", {
|
|
202
|
+
onClick: () => P(r(f)),
|
|
203
203
|
className: "mt-4 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",
|
|
204
204
|
children: h("devportal.backToOrganizations", "Back to Organizations")
|
|
205
205
|
})
|
|
206
206
|
]
|
|
207
207
|
})
|
|
208
208
|
});
|
|
209
|
-
let
|
|
210
|
-
return /* @__PURE__ */
|
|
211
|
-
title:
|
|
212
|
-
description:
|
|
209
|
+
let F = G(b.developerOrganization), R = x, H = re?.applications?.edges?.map((e) => e.node) ?? [];
|
|
210
|
+
return /* @__PURE__ */ B(u, {
|
|
211
|
+
title: F.name,
|
|
212
|
+
description: F.description,
|
|
213
213
|
purpose: h("devportal.orgDetailPurpose", "This is the home for one organization — the apps it owns, the people who can work on them, and its store and billing settings. Invite teammates, add apps, and verify the org so your published listings look trustworthy."),
|
|
214
214
|
backLink: `${s}${r(f)}`,
|
|
215
215
|
backLabel: h("devportal.backToOrganizations", "Back to Organizations"),
|
|
216
|
-
actions: /* @__PURE__ */
|
|
216
|
+
actions: /* @__PURE__ */ z("div", {
|
|
217
217
|
className: "flex items-center gap-2",
|
|
218
|
-
children: k ? /* @__PURE__ */
|
|
219
|
-
onClick: () => n?.(`/billing/earnings?developerOrgId=${encodeURIComponent(
|
|
218
|
+
children: k ? /* @__PURE__ */ B("button", {
|
|
219
|
+
onClick: () => n?.(`/billing/earnings?developerOrgId=${encodeURIComponent(F.id)}&developerOrgName=${encodeURIComponent(F.name)}`),
|
|
220
220
|
className: "inline-flex items-center gap-2 rounded-md border px-4 py-2 text-sm font-medium hover:bg-bg-sunken transition-colors",
|
|
221
|
-
children: [/* @__PURE__ */
|
|
221
|
+
children: [/* @__PURE__ */ z(A, { size: 16 }), h("devportal.revenue", "Revenue")]
|
|
222
222
|
}) : null
|
|
223
223
|
}),
|
|
224
224
|
children: [
|
|
225
|
-
/* @__PURE__ */
|
|
225
|
+
/* @__PURE__ */ z("div", {
|
|
226
226
|
className: "border-b",
|
|
227
|
-
children: /* @__PURE__ */
|
|
227
|
+
children: /* @__PURE__ */ z("nav", {
|
|
228
228
|
className: "-mb-px flex gap-4 overflow-x-auto",
|
|
229
229
|
role: "tablist",
|
|
230
230
|
"aria-label": h("devportal.organizationSections", "Organization sections"),
|
|
231
|
-
children:
|
|
231
|
+
children: oe.map((e) => {
|
|
232
232
|
let n = e.icon;
|
|
233
|
-
return /* @__PURE__ */
|
|
233
|
+
return /* @__PURE__ */ B("button", {
|
|
234
234
|
id: `organization-tab-${e.id}`,
|
|
235
235
|
role: "tab",
|
|
236
236
|
"aria-selected": g === e.id,
|
|
237
237
|
"aria-controls": `organization-panel-${e.id}`,
|
|
238
238
|
onClick: () => _(e.id),
|
|
239
239
|
className: t("flex items-center gap-2 border-b-2 px-1 py-3 text-sm font-medium transition-colors", g === e.id ? "border-primary text-primary" : "border-transparent text-text-secondary hover:text-text-primary hover:border-muted-foreground"),
|
|
240
|
-
children: [/* @__PURE__ */
|
|
240
|
+
children: [/* @__PURE__ */ z(n, { size: 16 }), e.label]
|
|
241
241
|
}, e.id);
|
|
242
242
|
})
|
|
243
243
|
})
|
|
244
244
|
}),
|
|
245
|
-
/* @__PURE__ */
|
|
245
|
+
/* @__PURE__ */ z(U, {
|
|
246
246
|
className: "mt-6",
|
|
247
|
-
storageKey: `devportal-org-${
|
|
247
|
+
storageKey: `devportal-org-${F.id}`,
|
|
248
248
|
steps: [
|
|
249
249
|
...j ? [{
|
|
250
250
|
id: "invite-members",
|
|
251
251
|
label: h("devportal.inviteMembers", "Invite members"),
|
|
252
252
|
description: h("devportal.orgStepInvite", "Add teammates so they can build alongside you"),
|
|
253
|
-
icon: /* @__PURE__ */
|
|
253
|
+
icon: /* @__PURE__ */ z(I, { size: 16 }),
|
|
254
254
|
onClick: () => _("members")
|
|
255
255
|
}] : [],
|
|
256
256
|
...E && !f ? [{
|
|
257
257
|
id: "create-app",
|
|
258
258
|
label: h("devportal.createApp", "Create App"),
|
|
259
259
|
description: h("devportal.orgStepCreateApp", "Build a new application under this organization"),
|
|
260
|
-
icon: /* @__PURE__ */
|
|
261
|
-
onClick: () =>
|
|
260
|
+
icon: /* @__PURE__ */ z(T, { size: 16 }),
|
|
261
|
+
onClick: () => P("/apps/new")
|
|
262
262
|
}] : [],
|
|
263
263
|
...E && f ? [{
|
|
264
264
|
id: "list-item",
|
|
265
265
|
label: h("devportal.listAnItem", "List an Item"),
|
|
266
266
|
description: h("devportal.orgStepListItem", "List a physical product for sale under this organization"),
|
|
267
|
-
icon: /* @__PURE__ */
|
|
268
|
-
onClick: () =>
|
|
267
|
+
icon: /* @__PURE__ */ z(N, { size: 16 }),
|
|
268
|
+
onClick: () => P("/seller/items/new")
|
|
269
269
|
}] : [],
|
|
270
270
|
...D ? [{
|
|
271
271
|
id: "settings",
|
|
272
272
|
label: h("devportal.orgStepVerify", "Complete organization profile"),
|
|
273
273
|
description: h("devportal.orgStepVerifyDesc", "Add a logo and details, then request verification"),
|
|
274
|
-
icon: /* @__PURE__ */
|
|
274
|
+
icon: /* @__PURE__ */ z(ae, { size: 16 }),
|
|
275
275
|
onClick: () => _("settings"),
|
|
276
|
-
done: !!
|
|
276
|
+
done: !!F.isVerified
|
|
277
277
|
}] : []
|
|
278
278
|
]
|
|
279
279
|
}),
|
|
280
|
-
/* @__PURE__ */
|
|
280
|
+
/* @__PURE__ */ B("div", {
|
|
281
281
|
className: "mt-6",
|
|
282
282
|
id: `organization-panel-${g}`,
|
|
283
283
|
role: "tabpanel",
|
|
284
284
|
"aria-labelledby": `organization-tab-${g}`,
|
|
285
285
|
tabIndex: 0,
|
|
286
286
|
children: [
|
|
287
|
-
g === "overview" && /* @__PURE__ */
|
|
288
|
-
org:
|
|
289
|
-
apps:
|
|
290
|
-
members:
|
|
287
|
+
g === "overview" && /* @__PURE__ */ z(Y, {
|
|
288
|
+
org: F,
|
|
289
|
+
apps: H,
|
|
290
|
+
members: R,
|
|
291
291
|
canCreateApps: E,
|
|
292
292
|
canViewRevenue: k,
|
|
293
|
-
onNavigate:
|
|
293
|
+
onNavigate: P,
|
|
294
294
|
onShowApps: () => _("apps")
|
|
295
295
|
}),
|
|
296
|
-
g === "apps" && /* @__PURE__ */
|
|
297
|
-
org:
|
|
298
|
-
apps:
|
|
299
|
-
onNavigate:
|
|
296
|
+
g === "apps" && /* @__PURE__ */ z(pe, {
|
|
297
|
+
org: F,
|
|
298
|
+
apps: H,
|
|
299
|
+
onNavigate: P,
|
|
300
300
|
canCreateApps: E
|
|
301
301
|
}),
|
|
302
|
-
g === "members" && /* @__PURE__ */
|
|
303
|
-
members:
|
|
304
|
-
onNavigate:
|
|
305
|
-
orgId:
|
|
302
|
+
g === "members" && /* @__PURE__ */ z(me, {
|
|
303
|
+
members: R,
|
|
304
|
+
onNavigate: P,
|
|
305
|
+
orgId: F.id,
|
|
306
306
|
canInviteMembers: j
|
|
307
307
|
}),
|
|
308
|
-
g === "settings" && D && /* @__PURE__ */
|
|
308
|
+
g === "settings" && D && /* @__PURE__ */ z(he, { org: F })
|
|
309
309
|
]
|
|
310
310
|
})
|
|
311
311
|
]
|
|
312
312
|
});
|
|
313
|
-
},
|
|
314
|
-
let { t: c } =
|
|
313
|
+
}, Y = ({ org: e, apps: t, members: r, canCreateApps: i, canViewRevenue: a, onNavigate: o, onShowApps: s }) => {
|
|
314
|
+
let { t: c } = V(), l = (e, t) => {
|
|
315
315
|
let n = c(e);
|
|
316
316
|
return n === e ? t : n;
|
|
317
317
|
};
|
|
318
|
-
return /* @__PURE__ */
|
|
318
|
+
return /* @__PURE__ */ B("div", {
|
|
319
319
|
className: "grid gap-6 lg:grid-cols-3",
|
|
320
|
-
children: [/* @__PURE__ */
|
|
320
|
+
children: [/* @__PURE__ */ B("div", {
|
|
321
321
|
className: "lg:col-span-2 space-y-6",
|
|
322
|
-
children: [/* @__PURE__ */
|
|
322
|
+
children: [/* @__PURE__ */ z(H, { children: /* @__PURE__ */ B(h, {
|
|
323
323
|
columns: a ? 4 : 3,
|
|
324
324
|
children: [
|
|
325
|
-
/* @__PURE__ */
|
|
325
|
+
/* @__PURE__ */ z(m, {
|
|
326
326
|
title: l("devportal.publishedApps", "Published Apps"),
|
|
327
327
|
value: `${e.publishedApps}/${e.totalApps}`,
|
|
328
|
-
icon: /* @__PURE__ */
|
|
328
|
+
icon: /* @__PURE__ */ z(T, { size: 20 })
|
|
329
329
|
}),
|
|
330
|
-
/* @__PURE__ */
|
|
330
|
+
/* @__PURE__ */ z(m, {
|
|
331
331
|
title: l("devportal.totalInstalls", "Total Installs"),
|
|
332
332
|
value: e.totalInstalls.toLocaleString(),
|
|
333
|
-
icon: /* @__PURE__ */
|
|
333
|
+
icon: /* @__PURE__ */ z(F, { size: 20 })
|
|
334
334
|
}),
|
|
335
|
-
a ? /* @__PURE__ */
|
|
335
|
+
a ? /* @__PURE__ */ z(m, {
|
|
336
336
|
title: l("devportal.totalRevenue", "Total Revenue"),
|
|
337
337
|
value: `$${e.totalRevenue.toLocaleString()}`,
|
|
338
|
-
icon: /* @__PURE__ */
|
|
338
|
+
icon: /* @__PURE__ */ z(A, { size: 20 })
|
|
339
339
|
}) : null,
|
|
340
|
-
/* @__PURE__ */
|
|
340
|
+
/* @__PURE__ */ z(m, {
|
|
341
341
|
title: l("devportal.avgRating", "Avg Rating"),
|
|
342
342
|
value: e.averageRating ? `${e.averageRating.toFixed(1)} ★` : l("devportal.notAvailable", "N/A"),
|
|
343
|
-
icon: /* @__PURE__ */
|
|
343
|
+
icon: /* @__PURE__ */ z(D, { size: 20 })
|
|
344
344
|
})
|
|
345
345
|
]
|
|
346
|
-
}) }), /* @__PURE__ */
|
|
346
|
+
}) }), /* @__PURE__ */ z(d, {
|
|
347
347
|
title: l("devportal.recentApplications", "Recent Applications"),
|
|
348
|
-
actions: /* @__PURE__ */
|
|
348
|
+
actions: /* @__PURE__ */ B("button", {
|
|
349
349
|
onClick: s,
|
|
350
350
|
className: "text-sm text-primary hover:underline flex items-center gap-1",
|
|
351
351
|
children: [
|
|
352
352
|
l("devportal.viewAll", "View all"),
|
|
353
353
|
" ",
|
|
354
|
-
/* @__PURE__ */
|
|
354
|
+
/* @__PURE__ */ z(E, { size: 14 })
|
|
355
355
|
]
|
|
356
356
|
}),
|
|
357
|
-
children: t.length > 0 ? /* @__PURE__ */
|
|
357
|
+
children: t.length > 0 ? /* @__PURE__ */ z("div", {
|
|
358
358
|
className: "space-y-2",
|
|
359
|
-
children: t.slice(0, 3).map((e) => /* @__PURE__ */
|
|
359
|
+
children: t.slice(0, 3).map((e) => /* @__PURE__ */ z(p, {
|
|
360
360
|
app: e,
|
|
361
361
|
onClick: () => o(`/apps/${e.id}`)
|
|
362
362
|
}, e.id))
|
|
363
|
-
}) : /* @__PURE__ */
|
|
363
|
+
}) : /* @__PURE__ */ z(n, {
|
|
364
364
|
illustration: "empty-data",
|
|
365
|
-
icon: /* @__PURE__ */
|
|
365
|
+
icon: /* @__PURE__ */ z(T, { size: 24 }),
|
|
366
366
|
title: l("devportal.noApplications", "No applications"),
|
|
367
367
|
description: e.kind === "PHYSICAL" ? l("devportal.createYourFirstItem", "List your first physical item") : l("devportal.createYourFirstApplication", "Create your first application"),
|
|
368
|
-
action: i ? /* @__PURE__ */
|
|
368
|
+
action: i ? /* @__PURE__ */ B("button", {
|
|
369
369
|
onClick: () => o(e.kind === "PHYSICAL" ? "/seller/items/new" : "/apps/new"),
|
|
370
370
|
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",
|
|
371
|
-
children: [/* @__PURE__ */
|
|
371
|
+
children: [/* @__PURE__ */ z(N, { size: 16 }), e.kind === "PHYSICAL" ? l("devportal.createItem", "Create Item") : l("devportal.createApp", "Create App")]
|
|
372
372
|
}) : void 0
|
|
373
373
|
})
|
|
374
374
|
})]
|
|
375
|
-
}), /* @__PURE__ */
|
|
375
|
+
}), /* @__PURE__ */ B("div", {
|
|
376
376
|
className: "space-y-6",
|
|
377
377
|
children: [
|
|
378
|
-
a ? /* @__PURE__ */
|
|
378
|
+
a ? /* @__PURE__ */ z(d, {
|
|
379
379
|
title: l("devportal.revenueSummary", "Revenue Summary"),
|
|
380
|
-
children: /* @__PURE__ */
|
|
380
|
+
children: /* @__PURE__ */ z(_, { items: [
|
|
381
381
|
{
|
|
382
382
|
label: l("devportal.totalRevenue", "Total Revenue"),
|
|
383
383
|
value: `$${e.totalRevenue.toLocaleString()}`
|
|
@@ -400,31 +400,31 @@ var J = {
|
|
|
400
400
|
}
|
|
401
401
|
] })
|
|
402
402
|
}) : null,
|
|
403
|
-
/* @__PURE__ */
|
|
403
|
+
/* @__PURE__ */ z(d, {
|
|
404
404
|
title: l("devportal.teamMembers", "Team Members"),
|
|
405
|
-
actions: /* @__PURE__ */
|
|
405
|
+
actions: /* @__PURE__ */ z("button", {
|
|
406
406
|
onClick: () => o(`/organizations/${e.id}/members`),
|
|
407
407
|
className: "text-sm text-primary hover:underline",
|
|
408
408
|
children: l("devportal.manage", "Manage")
|
|
409
409
|
}),
|
|
410
|
-
children: /* @__PURE__ */
|
|
410
|
+
children: /* @__PURE__ */ B("div", {
|
|
411
411
|
className: "space-y-2",
|
|
412
|
-
children: [r.slice(0, 3).map((e) => /* @__PURE__ */
|
|
412
|
+
children: [r.slice(0, 3).map((e) => /* @__PURE__ */ z("div", {
|
|
413
413
|
className: "flex items-center justify-between py-2",
|
|
414
|
-
children: /* @__PURE__ */
|
|
414
|
+
children: /* @__PURE__ */ B("div", {
|
|
415
415
|
className: "flex items-center gap-3",
|
|
416
|
-
children: [/* @__PURE__ */
|
|
416
|
+
children: [/* @__PURE__ */ z("div", {
|
|
417
417
|
className: "h-8 w-8 rounded-full bg-action-primary-bg/10 flex items-center justify-center text-sm font-medium text-primary",
|
|
418
418
|
children: e.email?.charAt(0).toUpperCase() || "U"
|
|
419
|
-
}), /* @__PURE__ */
|
|
419
|
+
}), /* @__PURE__ */ B("div", { children: [/* @__PURE__ */ z("p", {
|
|
420
420
|
className: "text-sm font-medium",
|
|
421
421
|
children: e.email
|
|
422
|
-
}), /* @__PURE__ */
|
|
422
|
+
}), /* @__PURE__ */ z("p", {
|
|
423
423
|
className: "text-xs text-text-secondary",
|
|
424
424
|
children: f[e.role]
|
|
425
425
|
})] })]
|
|
426
426
|
})
|
|
427
|
-
}, e.id)), r.length > 3 && /* @__PURE__ */
|
|
427
|
+
}, e.id)), r.length > 3 && /* @__PURE__ */ B("p", {
|
|
428
428
|
className: "text-xs text-text-secondary",
|
|
429
429
|
children: [
|
|
430
430
|
"+",
|
|
@@ -435,99 +435,99 @@ var J = {
|
|
|
435
435
|
})]
|
|
436
436
|
})
|
|
437
437
|
}),
|
|
438
|
-
/* @__PURE__ */
|
|
438
|
+
/* @__PURE__ */ z(d, {
|
|
439
439
|
title: l("devportal.links", "Links"),
|
|
440
|
-
children: /* @__PURE__ */
|
|
440
|
+
children: /* @__PURE__ */ B("div", {
|
|
441
441
|
className: "space-y-2",
|
|
442
|
-
children: [e.websiteUrl && /* @__PURE__ */
|
|
442
|
+
children: [e.websiteUrl && /* @__PURE__ */ B("a", {
|
|
443
443
|
href: e.websiteUrl,
|
|
444
444
|
target: "_blank",
|
|
445
445
|
rel: "noopener noreferrer",
|
|
446
446
|
className: "flex items-center gap-2 text-sm text-primary hover:underline",
|
|
447
|
-
children: [/* @__PURE__ */
|
|
448
|
-
}), e.contactEmail && /* @__PURE__ */
|
|
447
|
+
children: [/* @__PURE__ */ z(j, { size: 14 }), l("devportal.website", "Website")]
|
|
448
|
+
}), e.contactEmail && /* @__PURE__ */ B("a", {
|
|
449
449
|
href: `mailto:${e.contactEmail}`,
|
|
450
450
|
className: "flex items-center gap-2 text-sm text-primary hover:underline",
|
|
451
|
-
children: [/* @__PURE__ */
|
|
451
|
+
children: [/* @__PURE__ */ z(j, { size: 14 }), e.contactEmail]
|
|
452
452
|
})]
|
|
453
453
|
})
|
|
454
454
|
})
|
|
455
455
|
]
|
|
456
456
|
})]
|
|
457
457
|
});
|
|
458
|
-
},
|
|
459
|
-
let { t: a } =
|
|
458
|
+
}, pe = ({ org: e, apps: t, onNavigate: r, canCreateApps: i }) => {
|
|
459
|
+
let { t: a } = V(), o = (e, t) => {
|
|
460
460
|
let n = a(e);
|
|
461
461
|
return n === e ? t : n;
|
|
462
462
|
}, s = e.kind === "PHYSICAL", c = s ? "/seller/items/new" : "/apps/new", l = s ? o("devportal.createItem", "Create Item") : o("devportal.createApp", "Create App");
|
|
463
|
-
return /* @__PURE__ */
|
|
463
|
+
return /* @__PURE__ */ B("div", {
|
|
464
464
|
className: "space-y-6",
|
|
465
|
-
children: [/* @__PURE__ */
|
|
465
|
+
children: [/* @__PURE__ */ B("div", {
|
|
466
466
|
className: "flex items-center justify-between",
|
|
467
|
-
children: [/* @__PURE__ */
|
|
467
|
+
children: [/* @__PURE__ */ B("p", {
|
|
468
468
|
className: "text-sm text-text-secondary",
|
|
469
469
|
children: [
|
|
470
470
|
t.length,
|
|
471
471
|
" ",
|
|
472
472
|
t.length === 1 ? o("devportal.application", "application") : o("devportal.applications", "applications")
|
|
473
473
|
]
|
|
474
|
-
}), i ? /* @__PURE__ */
|
|
474
|
+
}), i ? /* @__PURE__ */ B("button", {
|
|
475
475
|
onClick: () => r(c),
|
|
476
476
|
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",
|
|
477
|
-
children: [/* @__PURE__ */
|
|
477
|
+
children: [/* @__PURE__ */ z(N, { size: 16 }), l]
|
|
478
478
|
}) : null]
|
|
479
|
-
}), t.length > 0 ? /* @__PURE__ */
|
|
479
|
+
}), t.length > 0 ? /* @__PURE__ */ z("div", {
|
|
480
480
|
className: "space-y-2",
|
|
481
|
-
children: t.map((e) => /* @__PURE__ */
|
|
481
|
+
children: t.map((e) => /* @__PURE__ */ z(p, {
|
|
482
482
|
app: e,
|
|
483
483
|
onClick: () => r(`/apps/${e.id}`)
|
|
484
484
|
}, e.id))
|
|
485
|
-
}) : /* @__PURE__ */
|
|
485
|
+
}) : /* @__PURE__ */ z(n, {
|
|
486
486
|
illustration: "empty-data",
|
|
487
|
-
icon: /* @__PURE__ */
|
|
487
|
+
icon: /* @__PURE__ */ z(T, { size: 32 }),
|
|
488
488
|
title: o("devportal.noApplications", "No applications"),
|
|
489
489
|
description: s ? o("devportal.createFirstItemForOrg", "List your first physical item for this organization") : o("devportal.createFirstAppForOrg", "Create your first application for this organization"),
|
|
490
|
-
action: i ? /* @__PURE__ */
|
|
490
|
+
action: i ? /* @__PURE__ */ B("button", {
|
|
491
491
|
onClick: () => r(c),
|
|
492
492
|
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",
|
|
493
|
-
children: [/* @__PURE__ */
|
|
493
|
+
children: [/* @__PURE__ */ z(N, { size: 16 }), l]
|
|
494
494
|
}) : void 0
|
|
495
495
|
})]
|
|
496
496
|
});
|
|
497
|
-
},
|
|
498
|
-
let { t: a } =
|
|
497
|
+
}, me = ({ members: e, onNavigate: n, orgId: r, canInviteMembers: i }) => {
|
|
498
|
+
let { t: a } = V(), o = (e, t) => {
|
|
499
499
|
let n = a(e);
|
|
500
500
|
return n === e ? t : n;
|
|
501
501
|
};
|
|
502
|
-
return /* @__PURE__ */
|
|
502
|
+
return /* @__PURE__ */ B("div", {
|
|
503
503
|
className: "space-y-6",
|
|
504
|
-
children: [/* @__PURE__ */
|
|
504
|
+
children: [/* @__PURE__ */ B("div", {
|
|
505
505
|
className: "flex items-center justify-between",
|
|
506
|
-
children: [/* @__PURE__ */
|
|
506
|
+
children: [/* @__PURE__ */ B("p", {
|
|
507
507
|
className: "text-sm text-text-secondary",
|
|
508
508
|
children: [
|
|
509
509
|
e.length,
|
|
510
510
|
" ",
|
|
511
511
|
e.length === 1 ? o("devportal.memberLower", "member") : o("devportal.membersLower", "members")
|
|
512
512
|
]
|
|
513
|
-
}), i ? /* @__PURE__ */
|
|
513
|
+
}), i ? /* @__PURE__ */ B("button", {
|
|
514
514
|
onClick: () => n(`/organizations/${r}/members`),
|
|
515
515
|
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",
|
|
516
|
-
children: [/* @__PURE__ */
|
|
516
|
+
children: [/* @__PURE__ */ z(N, { size: 16 }), o("devportal.inviteMember", "Invite Member")]
|
|
517
517
|
}) : null]
|
|
518
|
-
}), /* @__PURE__ */
|
|
518
|
+
}), /* @__PURE__ */ z(g, {
|
|
519
519
|
data: e,
|
|
520
520
|
keyField: "id",
|
|
521
521
|
columns: [
|
|
522
522
|
{
|
|
523
523
|
key: "email",
|
|
524
524
|
header: o("devportal.memberColumn", "Member"),
|
|
525
|
-
render: (e) => /* @__PURE__ */
|
|
525
|
+
render: (e) => /* @__PURE__ */ B("div", {
|
|
526
526
|
className: "flex items-center gap-3",
|
|
527
|
-
children: [/* @__PURE__ */
|
|
527
|
+
children: [/* @__PURE__ */ z("div", {
|
|
528
528
|
className: "h-8 w-8 rounded-full bg-action-primary-bg/10 flex items-center justify-center text-sm font-medium text-primary",
|
|
529
529
|
children: e.email?.charAt(0).toUpperCase() || "U"
|
|
530
|
-
}), /* @__PURE__ */
|
|
530
|
+
}), /* @__PURE__ */ z("span", {
|
|
531
531
|
className: "font-medium",
|
|
532
532
|
children: e.email
|
|
533
533
|
})]
|
|
@@ -536,7 +536,7 @@ var J = {
|
|
|
536
536
|
{
|
|
537
537
|
key: "role",
|
|
538
538
|
header: o("devportal.roleColumn", "Role"),
|
|
539
|
-
render: (e) => /* @__PURE__ */
|
|
539
|
+
render: (e) => /* @__PURE__ */ z("span", {
|
|
540
540
|
className: t("inline-flex items-center rounded-full px-2 py-0.5 text-xs font-medium", e.role === "OWNER" ? "bg-accent-purple-subtle text-accent-purple" : e.role === "ADMIN" ? "bg-status-info-bg-subtle text-status-info-text" : e.role === "DEVELOPER" ? "bg-status-success-bg-subtle text-status-success-text" : "bg-bg-sunken text-text-primary"),
|
|
541
541
|
children: f[e.role]
|
|
542
542
|
})
|
|
@@ -549,8 +549,8 @@ var J = {
|
|
|
549
549
|
]
|
|
550
550
|
})]
|
|
551
551
|
});
|
|
552
|
-
},
|
|
553
|
-
let { t: n } =
|
|
552
|
+
}, he = ({ org: e }) => {
|
|
553
|
+
let { t: n } = V(), { allowed: r } = ne(x.ORG_UPDATE), i = (e, t) => {
|
|
554
554
|
let r = n(e);
|
|
555
555
|
return r === e ? t : r;
|
|
556
556
|
}, [a, o] = w({
|
|
@@ -567,17 +567,17 @@ var J = {
|
|
|
567
567
|
}), [p, m] = w({
|
|
568
568
|
taxId: e.taxId ?? "",
|
|
569
569
|
taxCountry: e.taxCountry ?? ""
|
|
570
|
-
}), { locations: h } = re(), { addresses: g, loading: ie, refetch: T } = S(e.id), [E, D] = w(!1), [O, A] = w(null), [j,
|
|
570
|
+
}), { locations: h } = re(), { addresses: g, loading: ie, refetch: T } = S(e.id), [E, D] = w(!1), [O, A] = w(null), [j, F] = w(null), [I, L] = w(null), [H, U] = w(null), [G, K] = w(null), [q, J] = w(null), [Y, pe] = w("manual"), [me, he] = w(!1), [ge, _e] = w(""), [ve, ye] = w(""), [be, xe] = w(""), [Se, X] = w(null), [Ce, we] = w(!1), Z = Se ?? {
|
|
571
571
|
verificationMethod: e.verificationMethod,
|
|
572
572
|
verificationRequestedAt: e.verificationRequestedAt,
|
|
573
573
|
verificationStatus: e.verificationStatus,
|
|
574
574
|
verificationRequestNotes: e.verificationRequestNotes,
|
|
575
575
|
verificationRejectedReason: e.verificationRejectedReason
|
|
576
576
|
}, Q = [];
|
|
577
|
-
a.contactEmail.trim() ?
|
|
577
|
+
a.contactEmail.trim() ? fe(a.contactEmail) || Q.push(i("devportal.contactEmailInvalid", "Contact email must be valid")) : Q.push(i("devportal.contactEmailRequired", "Contact email is required")), a.supportEmail.trim() && !fe(a.supportEmail) && Q.push(i("devportal.supportEmailInvalid", "Support email must be valid")), a.websiteUrl.trim() ? de(a.websiteUrl) || Q.push(i("devportal.websiteInvalid", "Website URL must be valid")) : Q.push(i("devportal.websiteRequired", "Website URL is required")), u.legalEntityName.trim() || Q.push(i("devportal.legalEntityNameRequired", "Legal entity name is required")), u.legalEntityType.trim() || Q.push(i("devportal.legalEntityTypeRequired", "Entity type is required")), p.taxId.trim() || Q.push(i("devportal.taxIdRequired", "Tax ID is required")), p.taxCountry.trim() ? /^[A-Za-z]{2}$/.test(p.taxCountry.trim()) || Q.push(i("devportal.taxCountryInvalid", "Tax country must be a 2-letter code")) : Q.push(i("devportal.taxCountryRequired", "Tax country is required"));
|
|
578
578
|
let $ = [];
|
|
579
|
-
Y === "domain" && !
|
|
580
|
-
let
|
|
579
|
+
Y === "domain" && !ue(be.trim()) && $.push(i("devportal.verification.errors.domainRequired", "Enter a valid domain like burdenoff.com")), Y === "document" && !de(ve.trim()) && $.push(i("devportal.verification.errors.evidenceUrlRequired", "Enter a valid evidence URL starting with http:// or https://")), Y === "manual" && !ge.trim() && $.push(i("devportal.verification.errors.notesRequired", "Add notes so the reviewer knows what to verify"));
|
|
580
|
+
let Te = Q.length === 0 && $.length === 0 && !Ce && r, [Ee, { loading: De }] = l({ refetchQueries: ["GetOrganization"] }), [Oe, { loading: ke }] = s({ refetchQueries: ["GetOrganization"] }), [Ae, { loading: je }] = c({ refetchQueries: ["GetOrganization"] });
|
|
581
581
|
C(() => {
|
|
582
582
|
o({
|
|
583
583
|
name: e.name,
|
|
@@ -597,14 +597,14 @@ var J = {
|
|
|
597
597
|
}, [e.id]), C(() => {
|
|
598
598
|
e.id && W({
|
|
599
599
|
gateway: "global",
|
|
600
|
-
query:
|
|
600
|
+
query: ce,
|
|
601
601
|
variables: { id: e.id }
|
|
602
|
-
}).then((e) =>
|
|
603
|
-
}, [e.id,
|
|
604
|
-
let
|
|
605
|
-
J(null),
|
|
602
|
+
}).then((e) => X(e.data?.developerOrganization ?? null)).catch(() => X(null));
|
|
603
|
+
}, [e.id, me]);
|
|
604
|
+
let Me = async () => {
|
|
605
|
+
J(null), K(null);
|
|
606
606
|
try {
|
|
607
|
-
await
|
|
607
|
+
await Ee({ variables: {
|
|
608
608
|
id: e.id,
|
|
609
609
|
input: {
|
|
610
610
|
name: a.name.trim() || void 0,
|
|
@@ -615,38 +615,38 @@ var J = {
|
|
|
615
615
|
logoUrl: a.logoUrl.trim() || null,
|
|
616
616
|
bannerUrl: a.bannerUrl.trim() || null
|
|
617
617
|
}
|
|
618
|
-
} }),
|
|
618
|
+
} }), K(i("devportal.organizationUpdated", "Organization details updated"));
|
|
619
619
|
} catch (e) {
|
|
620
620
|
J(e instanceof Error ? e.message : i("devportal.failedToUpdateOrganization", "Failed to update organization"));
|
|
621
621
|
}
|
|
622
|
-
},
|
|
623
|
-
J(null),
|
|
622
|
+
}, Ne = async () => {
|
|
623
|
+
J(null), K(null);
|
|
624
624
|
try {
|
|
625
|
-
await
|
|
625
|
+
await Oe({ variables: {
|
|
626
626
|
id: e.id,
|
|
627
627
|
input: {
|
|
628
628
|
legalEntityName: u.legalEntityName.trim() || null,
|
|
629
629
|
legalEntityType: u.legalEntityType.trim() || null
|
|
630
630
|
}
|
|
631
|
-
} }),
|
|
631
|
+
} }), K(i("devportal.legalInfoUpdated", "Legal information updated"));
|
|
632
632
|
} catch (e) {
|
|
633
633
|
J(e instanceof Error ? e.message : i("devportal.failedToUpdateLegalInfo", "Failed to update legal information"));
|
|
634
634
|
}
|
|
635
|
-
},
|
|
636
|
-
J(null),
|
|
635
|
+
}, Pe = async () => {
|
|
636
|
+
J(null), K(null);
|
|
637
637
|
try {
|
|
638
|
-
await
|
|
638
|
+
await Ae({ variables: {
|
|
639
639
|
id: e.id,
|
|
640
640
|
input: {
|
|
641
641
|
taxId: p.taxId.trim() || null,
|
|
642
642
|
taxCountry: p.taxCountry.trim() || null
|
|
643
643
|
}
|
|
644
|
-
} }),
|
|
644
|
+
} }), K(i("devportal.taxInfoUpdated", "Tax information updated"));
|
|
645
645
|
} catch (e) {
|
|
646
646
|
J(e instanceof Error ? e.message : i("devportal.failedToUpdateTaxInfo", "Failed to update tax information"));
|
|
647
647
|
}
|
|
648
|
-
},
|
|
649
|
-
U(null), L(null),
|
|
648
|
+
}, Fe = async (e) => {
|
|
649
|
+
U(null), L(null), F(e);
|
|
650
650
|
try {
|
|
651
651
|
let t = await W({
|
|
652
652
|
gateway: "global",
|
|
@@ -654,14 +654,14 @@ var J = {
|
|
|
654
654
|
variables: { id: e }
|
|
655
655
|
});
|
|
656
656
|
if (t.errors?.length) throw Error(t.errors[0]?.message ?? "Failed to switch pickup address");
|
|
657
|
-
T(), L(i("devportal.pickupAddressSetActive", "Pickup address updated"));
|
|
657
|
+
se(), T(), L(i("devportal.pickupAddressSetActive", "Pickup address updated"));
|
|
658
658
|
} catch (e) {
|
|
659
659
|
U(e instanceof Error ? e.message : i("devportal.failedToSwitchPickupAddress", "Failed to switch pickup address"));
|
|
660
660
|
} finally {
|
|
661
|
-
|
|
661
|
+
F(null);
|
|
662
662
|
}
|
|
663
|
-
},
|
|
664
|
-
U(null), L(null),
|
|
663
|
+
}, Ie = async (e) => {
|
|
664
|
+
U(null), L(null), F(e);
|
|
665
665
|
try {
|
|
666
666
|
let t = await W({
|
|
667
667
|
gateway: "global",
|
|
@@ -669,32 +669,32 @@ var J = {
|
|
|
669
669
|
variables: { id: e }
|
|
670
670
|
});
|
|
671
671
|
if (t.errors?.length) throw Error(t.errors[0]?.message ?? "Failed to remove pickup address");
|
|
672
|
-
T(), L(i("devportal.pickupAddressRemoved", "Pickup address removed"));
|
|
672
|
+
se(), T(), L(i("devportal.pickupAddressRemoved", "Pickup address removed"));
|
|
673
673
|
} catch (e) {
|
|
674
674
|
U(e instanceof Error ? e.message : i("devportal.failedToRemovePickupAddress", "Failed to remove pickup address"));
|
|
675
675
|
} finally {
|
|
676
|
-
|
|
676
|
+
F(null), A(null);
|
|
677
677
|
}
|
|
678
678
|
};
|
|
679
|
-
return /* @__PURE__ */
|
|
679
|
+
return /* @__PURE__ */ B("div", {
|
|
680
680
|
className: "space-y-6 max-w-2xl",
|
|
681
681
|
children: [
|
|
682
|
-
|
|
682
|
+
q && /* @__PURE__ */ z("div", {
|
|
683
683
|
className: "rounded-md border border-status-error-bg bg-status-error-bg-subtle px-4 py-3 text-sm text-status-error-text",
|
|
684
|
-
children:
|
|
684
|
+
children: q
|
|
685
685
|
}),
|
|
686
|
-
|
|
686
|
+
G && /* @__PURE__ */ z("div", {
|
|
687
687
|
className: "rounded-md border border-status-success-bg bg-status-success-bg-subtle px-4 py-3 text-sm text-status-success-text",
|
|
688
|
-
children:
|
|
688
|
+
children: G
|
|
689
689
|
}),
|
|
690
|
-
/* @__PURE__ */
|
|
690
|
+
/* @__PURE__ */ z(d, {
|
|
691
691
|
title: i("devportal.organizationDetails", "Organization Details"),
|
|
692
|
-
children: /* @__PURE__ */
|
|
692
|
+
children: /* @__PURE__ */ B("div", {
|
|
693
693
|
className: "space-y-4",
|
|
694
694
|
children: [
|
|
695
|
-
/* @__PURE__ */
|
|
695
|
+
/* @__PURE__ */ B("div", {
|
|
696
696
|
className: "grid gap-4 sm:grid-cols-2",
|
|
697
|
-
children: [/* @__PURE__ */
|
|
697
|
+
children: [/* @__PURE__ */ z(v, {
|
|
698
698
|
label: i("devportal.organizationName", "Organization Name"),
|
|
699
699
|
value: a.name,
|
|
700
700
|
onChange: (e) => o((t) => ({
|
|
@@ -703,14 +703,14 @@ var J = {
|
|
|
703
703
|
})),
|
|
704
704
|
disabled: !r,
|
|
705
705
|
required: !0
|
|
706
|
-
}), /* @__PURE__ */
|
|
706
|
+
}), /* @__PURE__ */ z(v, {
|
|
707
707
|
label: i("devportal.slug", "Slug"),
|
|
708
708
|
value: e.slug,
|
|
709
709
|
disabled: !0,
|
|
710
710
|
hint: i("devportal.slugReadOnly", "Slug cannot be changed here")
|
|
711
711
|
})]
|
|
712
712
|
}),
|
|
713
|
-
/* @__PURE__ */
|
|
713
|
+
/* @__PURE__ */ z(y, {
|
|
714
714
|
label: i("devportal.description", "Description"),
|
|
715
715
|
value: a.description,
|
|
716
716
|
onChange: (e) => o((t) => ({
|
|
@@ -720,10 +720,10 @@ var J = {
|
|
|
720
720
|
disabled: !r,
|
|
721
721
|
rows: 4
|
|
722
722
|
}),
|
|
723
|
-
/* @__PURE__ */
|
|
723
|
+
/* @__PURE__ */ B("div", {
|
|
724
724
|
className: "grid gap-4 sm:grid-cols-2",
|
|
725
725
|
children: [
|
|
726
|
-
/* @__PURE__ */
|
|
726
|
+
/* @__PURE__ */ z(v, {
|
|
727
727
|
label: i("devportal.website", "Website"),
|
|
728
728
|
type: "url",
|
|
729
729
|
value: a.websiteUrl,
|
|
@@ -733,7 +733,7 @@ var J = {
|
|
|
733
733
|
})),
|
|
734
734
|
disabled: !r
|
|
735
735
|
}),
|
|
736
|
-
/* @__PURE__ */
|
|
736
|
+
/* @__PURE__ */ z(v, {
|
|
737
737
|
label: i("devportal.contactEmail", "Contact Email"),
|
|
738
738
|
type: "email",
|
|
739
739
|
value: a.contactEmail,
|
|
@@ -743,7 +743,7 @@ var J = {
|
|
|
743
743
|
})),
|
|
744
744
|
disabled: !r
|
|
745
745
|
}),
|
|
746
|
-
/* @__PURE__ */
|
|
746
|
+
/* @__PURE__ */ z(v, {
|
|
747
747
|
label: i("devportal.supportEmail", "Support Email"),
|
|
748
748
|
type: "email",
|
|
749
749
|
value: a.supportEmail,
|
|
@@ -753,7 +753,7 @@ var J = {
|
|
|
753
753
|
})),
|
|
754
754
|
disabled: !r
|
|
755
755
|
}),
|
|
756
|
-
/* @__PURE__ */
|
|
756
|
+
/* @__PURE__ */ z(v, {
|
|
757
757
|
label: i("devportal.logoUrl", "Logo URL"),
|
|
758
758
|
type: "url",
|
|
759
759
|
value: a.logoUrl,
|
|
@@ -765,7 +765,7 @@ var J = {
|
|
|
765
765
|
})
|
|
766
766
|
]
|
|
767
767
|
}),
|
|
768
|
-
/* @__PURE__ */
|
|
768
|
+
/* @__PURE__ */ z(v, {
|
|
769
769
|
label: i("devportal.bannerUrl", "Banner URL"),
|
|
770
770
|
type: "url",
|
|
771
771
|
value: a.bannerUrl,
|
|
@@ -775,10 +775,10 @@ var J = {
|
|
|
775
775
|
})),
|
|
776
776
|
disabled: !r
|
|
777
777
|
}),
|
|
778
|
-
/* @__PURE__ */
|
|
778
|
+
/* @__PURE__ */ z(_, { items: [
|
|
779
779
|
{
|
|
780
780
|
label: i("devportal.organizationId", "Organization ID"),
|
|
781
|
-
value: /* @__PURE__ */
|
|
781
|
+
value: /* @__PURE__ */ z("code", {
|
|
782
782
|
className: "text-xs",
|
|
783
783
|
children: e.id
|
|
784
784
|
})
|
|
@@ -800,31 +800,31 @@ var J = {
|
|
|
800
800
|
value: `${(e.platformFeeRate * 100).toFixed(0)}%`
|
|
801
801
|
}
|
|
802
802
|
] }),
|
|
803
|
-
/* @__PURE__ */
|
|
803
|
+
/* @__PURE__ */ z("div", {
|
|
804
804
|
className: "flex justify-end",
|
|
805
|
-
children: /* @__PURE__ */
|
|
805
|
+
children: /* @__PURE__ */ B("button", {
|
|
806
806
|
type: "button",
|
|
807
|
-
disabled: !r ||
|
|
808
|
-
onClick: () => void
|
|
807
|
+
disabled: !r || De,
|
|
808
|
+
onClick: () => void Me(),
|
|
809
809
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 disabled:opacity-50",
|
|
810
|
-
children: [
|
|
810
|
+
children: [De ? /* @__PURE__ */ z(M, {
|
|
811
811
|
size: 14,
|
|
812
812
|
className: "animate-spin"
|
|
813
|
-
}) : /* @__PURE__ */
|
|
813
|
+
}) : /* @__PURE__ */ z(ae, { size: 14 }), i("devportal.saveChanges", "Save Changes")]
|
|
814
814
|
})
|
|
815
815
|
})
|
|
816
816
|
]
|
|
817
817
|
})
|
|
818
818
|
}),
|
|
819
|
-
/* @__PURE__ */
|
|
819
|
+
/* @__PURE__ */ z(d, {
|
|
820
820
|
title: i("devportal.legalInformation", "Legal Information"),
|
|
821
|
-
children: /* @__PURE__ */
|
|
821
|
+
children: /* @__PURE__ */ B("div", {
|
|
822
822
|
className: "space-y-4",
|
|
823
823
|
children: [
|
|
824
|
-
/* @__PURE__ */
|
|
824
|
+
/* @__PURE__ */ B("div", {
|
|
825
825
|
className: "grid gap-4 sm:grid-cols-2",
|
|
826
826
|
children: [
|
|
827
|
-
/* @__PURE__ */
|
|
827
|
+
/* @__PURE__ */ z(v, {
|
|
828
828
|
label: i("devportal.legalEntityName", "Legal Entity Name"),
|
|
829
829
|
value: u.legalEntityName,
|
|
830
830
|
onChange: (e) => f((t) => ({
|
|
@@ -833,7 +833,7 @@ var J = {
|
|
|
833
833
|
})),
|
|
834
834
|
disabled: !r
|
|
835
835
|
}),
|
|
836
|
-
/* @__PURE__ */
|
|
836
|
+
/* @__PURE__ */ z(v, {
|
|
837
837
|
label: i("devportal.entityType", "Entity Type"),
|
|
838
838
|
value: u.legalEntityType,
|
|
839
839
|
onChange: (e) => f((t) => ({
|
|
@@ -842,7 +842,7 @@ var J = {
|
|
|
842
842
|
})),
|
|
843
843
|
disabled: !r
|
|
844
844
|
}),
|
|
845
|
-
/* @__PURE__ */
|
|
845
|
+
/* @__PURE__ */ z(v, {
|
|
846
846
|
label: i("devportal.taxId", "Tax ID"),
|
|
847
847
|
value: p.taxId,
|
|
848
848
|
onChange: (e) => m((t) => ({
|
|
@@ -851,7 +851,7 @@ var J = {
|
|
|
851
851
|
})),
|
|
852
852
|
disabled: !r
|
|
853
853
|
}),
|
|
854
|
-
/* @__PURE__ */
|
|
854
|
+
/* @__PURE__ */ z(v, {
|
|
855
855
|
label: i("devportal.taxCountry", "Tax Country"),
|
|
856
856
|
value: p.taxCountry,
|
|
857
857
|
onChange: (e) => m((t) => ({
|
|
@@ -862,37 +862,37 @@ var J = {
|
|
|
862
862
|
})
|
|
863
863
|
]
|
|
864
864
|
}),
|
|
865
|
-
/* @__PURE__ */
|
|
865
|
+
/* @__PURE__ */ z(_, { items: [{
|
|
866
866
|
label: i("devportal.taxForm", "Tax Form"),
|
|
867
867
|
value: e.taxFormType || i("devportal.notSubmitted", "Not submitted")
|
|
868
868
|
}, {
|
|
869
869
|
label: i("devportal.taxFormStatus", "Tax Form Status"),
|
|
870
|
-
value: e.taxFormType ? e.taxFormVerified ? /* @__PURE__ */
|
|
870
|
+
value: e.taxFormType ? e.taxFormVerified ? /* @__PURE__ */ B("span", {
|
|
871
871
|
className: "text-status-success-text flex items-center gap-1",
|
|
872
872
|
children: [
|
|
873
|
-
/* @__PURE__ */
|
|
873
|
+
/* @__PURE__ */ z(k, { size: 14 }),
|
|
874
874
|
" ",
|
|
875
875
|
i("devportal.verified", "Verified")
|
|
876
876
|
]
|
|
877
877
|
}) : i("devportal.pendingVerification", "Pending verification") : i("devportal.notSubmitted", "Not submitted")
|
|
878
878
|
}] }),
|
|
879
|
-
/* @__PURE__ */
|
|
879
|
+
/* @__PURE__ */ B("div", {
|
|
880
880
|
className: "flex justify-end gap-2",
|
|
881
|
-
children: [/* @__PURE__ */
|
|
881
|
+
children: [/* @__PURE__ */ B("button", {
|
|
882
882
|
type: "button",
|
|
883
|
-
disabled: !r ||
|
|
884
|
-
onClick: () => void
|
|
883
|
+
disabled: !r || ke,
|
|
884
|
+
onClick: () => void Ne(),
|
|
885
885
|
className: "inline-flex items-center gap-2 rounded-md border border-border-seam px-4 py-2 text-sm font-medium hover:bg-bg-sunken disabled:opacity-50",
|
|
886
|
-
children: [
|
|
886
|
+
children: [ke ? /* @__PURE__ */ z(M, {
|
|
887
887
|
size: 14,
|
|
888
888
|
className: "animate-spin"
|
|
889
889
|
}) : null, i("devportal.saveLegalInfo", "Save Legal Info")]
|
|
890
|
-
}), /* @__PURE__ */
|
|
890
|
+
}), /* @__PURE__ */ B("button", {
|
|
891
891
|
type: "button",
|
|
892
|
-
disabled: !r ||
|
|
893
|
-
onClick: () => void
|
|
892
|
+
disabled: !r || je,
|
|
893
|
+
onClick: () => void Pe(),
|
|
894
894
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 disabled:opacity-50",
|
|
895
|
-
children: [
|
|
895
|
+
children: [je ? /* @__PURE__ */ z(M, {
|
|
896
896
|
size: 14,
|
|
897
897
|
className: "animate-spin"
|
|
898
898
|
}) : null, i("devportal.saveTaxInfo", "Save Tax Info")]
|
|
@@ -901,47 +901,47 @@ var J = {
|
|
|
901
901
|
]
|
|
902
902
|
})
|
|
903
903
|
}),
|
|
904
|
-
e.kind === "PHYSICAL" && /* @__PURE__ */
|
|
904
|
+
e.kind === "PHYSICAL" && /* @__PURE__ */ z(d, {
|
|
905
905
|
title: i("devportal.fulfillment", "Fulfillment"),
|
|
906
|
-
children: /* @__PURE__ */
|
|
906
|
+
children: /* @__PURE__ */ B("div", {
|
|
907
907
|
className: "space-y-3",
|
|
908
908
|
children: [
|
|
909
|
-
|
|
909
|
+
H && /* @__PURE__ */ z("div", {
|
|
910
910
|
className: "rounded-md border border-status-error-bg bg-status-error-bg-subtle px-4 py-3 text-sm text-status-error-text",
|
|
911
|
-
children:
|
|
911
|
+
children: H
|
|
912
912
|
}),
|
|
913
|
-
I && /* @__PURE__ */
|
|
913
|
+
I && /* @__PURE__ */ z("div", {
|
|
914
914
|
className: "rounded-md border border-status-success-bg bg-status-success-bg-subtle px-4 py-3 text-sm text-status-success-text",
|
|
915
915
|
children: I
|
|
916
916
|
}),
|
|
917
|
-
!ie && g.length === 0 && /* @__PURE__ */
|
|
917
|
+
!ie && g.length === 0 && /* @__PURE__ */ B("div", {
|
|
918
918
|
className: "rounded-md border border-border-seam bg-bg-sunken p-4",
|
|
919
|
-
children: [/* @__PURE__ */
|
|
919
|
+
children: [/* @__PURE__ */ z("p", {
|
|
920
920
|
className: "text-sm font-medium",
|
|
921
921
|
children: i("devportal.noPickupAddress", "No pickup address set up yet")
|
|
922
|
-
}), /* @__PURE__ */
|
|
922
|
+
}), /* @__PURE__ */ z("p", {
|
|
923
923
|
className: "mt-1 text-sm text-text-secondary",
|
|
924
924
|
children: i("devportal.noPickupAddressHint", "Buyers need to know where your physical orders actually ship from — a bare pincode isn't enough, two sellers can share one. Add your real pickup address and we'll register it with our shipping carrier for you, free of charge.")
|
|
925
925
|
})]
|
|
926
926
|
}),
|
|
927
|
-
g.length > 0 && /* @__PURE__ */
|
|
927
|
+
g.length > 0 && /* @__PURE__ */ z("div", {
|
|
928
928
|
className: "grid grid-cols-1 gap-3 sm:grid-cols-2",
|
|
929
929
|
children: g.map((e) => {
|
|
930
930
|
let n = h.some((t) => t.carrier === e.carrier && t.postalCode === e.postalCode), a = j === e.id;
|
|
931
|
-
return /* @__PURE__ */
|
|
931
|
+
return /* @__PURE__ */ B("div", {
|
|
932
932
|
className: t("rounded-md border p-4", e.isDefault ? "border-status-success-border bg-status-success-bg-subtle" : "border-border-seam bg-bg-sunken"),
|
|
933
933
|
children: [
|
|
934
|
-
/* @__PURE__ */
|
|
934
|
+
/* @__PURE__ */ B("div", {
|
|
935
935
|
className: "flex items-start justify-between gap-2",
|
|
936
|
-
children: [/* @__PURE__ */
|
|
936
|
+
children: [/* @__PURE__ */ z("p", {
|
|
937
937
|
className: "text-sm font-medium",
|
|
938
938
|
children: e.carrierLocationLabel
|
|
939
|
-
}), e.isDefault && /* @__PURE__ */
|
|
939
|
+
}), e.isDefault && /* @__PURE__ */ z("span", {
|
|
940
940
|
className: "rounded-full bg-status-success-bg px-2 py-0.5 text-xs font-medium text-white",
|
|
941
941
|
children: i("devportal.active", "Active")
|
|
942
942
|
})]
|
|
943
943
|
}),
|
|
944
|
-
/* @__PURE__ */
|
|
944
|
+
/* @__PURE__ */ B("p", {
|
|
945
945
|
className: "mt-1 text-sm text-text-secondary",
|
|
946
946
|
children: [
|
|
947
947
|
e.address,
|
|
@@ -956,41 +956,44 @@ var J = {
|
|
|
956
956
|
e.country
|
|
957
957
|
]
|
|
958
958
|
}),
|
|
959
|
-
/* @__PURE__ */
|
|
959
|
+
/* @__PURE__ */ z("p", {
|
|
960
960
|
className: "mt-1 text-xs text-text-secondary",
|
|
961
961
|
children: b(e.carrier)
|
|
962
962
|
}),
|
|
963
|
-
!n && /* @__PURE__ */
|
|
963
|
+
!n && /* @__PURE__ */ z("p", {
|
|
964
964
|
className: "mt-2 text-xs text-status-error-text",
|
|
965
965
|
children: i("devportal.pickupAddressNotRegisteredHint", "Not currently registered with the carrier — physical orders can't auto-ship from this address right now.")
|
|
966
966
|
}),
|
|
967
|
-
r && /* @__PURE__ */
|
|
967
|
+
r && /* @__PURE__ */ B("div", {
|
|
968
968
|
className: "mt-3 flex items-center gap-4",
|
|
969
|
-
children: [!e.isDefault && /* @__PURE__ */
|
|
969
|
+
children: [!e.isDefault && /* @__PURE__ */ z("button", {
|
|
970
970
|
type: "button",
|
|
971
971
|
disabled: a,
|
|
972
|
-
onClick: () => void
|
|
972
|
+
onClick: () => void Fe(e.id),
|
|
973
973
|
className: "text-sm font-medium text-action-primary-text hover:underline disabled:opacity-50",
|
|
974
974
|
children: i("devportal.setPickupAddressActiveCta", "Set as active")
|
|
975
|
-
}), /* @__PURE__ */
|
|
975
|
+
}), /* @__PURE__ */ B("button", {
|
|
976
976
|
type: "button",
|
|
977
977
|
disabled: a,
|
|
978
978
|
onClick: () => A(e.id),
|
|
979
979
|
className: "flex items-center gap-1.5 text-sm text-status-error-text hover:underline disabled:opacity-50",
|
|
980
|
-
children: [/* @__PURE__ */
|
|
980
|
+
children: [/* @__PURE__ */ z(P, { className: "h-3.5 w-3.5" }), i("devportal.removePickupAddressCta", "Remove")]
|
|
981
981
|
})]
|
|
982
982
|
})
|
|
983
983
|
]
|
|
984
984
|
}, e.id);
|
|
985
985
|
})
|
|
986
986
|
}),
|
|
987
|
-
r && /* @__PURE__ */
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
987
|
+
r && /* @__PURE__ */ z("div", {
|
|
988
|
+
className: "flex justify-end",
|
|
989
|
+
children: /* @__PURE__ */ B("button", {
|
|
990
|
+
type: "button",
|
|
991
|
+
onClick: () => D(!0),
|
|
992
|
+
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",
|
|
993
|
+
children: [/* @__PURE__ */ z(N, { size: 14 }), i("devportal.addPickupAddressCta", "Add pickup address")]
|
|
994
|
+
})
|
|
992
995
|
}),
|
|
993
|
-
E && /* @__PURE__ */
|
|
996
|
+
E && /* @__PURE__ */ z(te, {
|
|
994
997
|
open: E,
|
|
995
998
|
onOpenChange: D,
|
|
996
999
|
organizationId: e.id,
|
|
@@ -999,7 +1002,7 @@ var J = {
|
|
|
999
1002
|
T(), L(i("devportal.pickupAddressAdded", "Pickup address added"));
|
|
1000
1003
|
}
|
|
1001
1004
|
}),
|
|
1002
|
-
/* @__PURE__ */
|
|
1005
|
+
/* @__PURE__ */ z(ee, {
|
|
1003
1006
|
open: O !== null,
|
|
1004
1007
|
onOpenChange: (e) => {
|
|
1005
1008
|
e || A(null);
|
|
@@ -1011,20 +1014,20 @@ var J = {
|
|
|
1011
1014
|
confirmLabel: i("devportal.remove", "Remove"),
|
|
1012
1015
|
cancelLabel: i("devportal.cancel", "Cancel"),
|
|
1013
1016
|
onConfirm: async () => {
|
|
1014
|
-
O && await
|
|
1017
|
+
O && await Ie(O);
|
|
1015
1018
|
}
|
|
1016
1019
|
})
|
|
1017
1020
|
]
|
|
1018
1021
|
})
|
|
1019
1022
|
}),
|
|
1020
|
-
/* @__PURE__ */
|
|
1023
|
+
/* @__PURE__ */ B(d, {
|
|
1021
1024
|
title: i("devportal.verificationStatus", "Verification Status"),
|
|
1022
|
-
children: [/* @__PURE__ */
|
|
1025
|
+
children: [/* @__PURE__ */ z(_, { items: [{
|
|
1023
1026
|
label: i("devportal.verifiedLabel", "Verified"),
|
|
1024
|
-
value: Z.verificationStatus === "VERIFIED" ? /* @__PURE__ */
|
|
1027
|
+
value: Z.verificationStatus === "VERIFIED" ? /* @__PURE__ */ B("span", {
|
|
1025
1028
|
className: "text-status-success-text flex items-center gap-1",
|
|
1026
1029
|
children: [
|
|
1027
|
-
/* @__PURE__ */
|
|
1030
|
+
/* @__PURE__ */ z(k, { size: 14 }),
|
|
1028
1031
|
" ",
|
|
1029
1032
|
i("devportal.verifiedVia", "Verified via"),
|
|
1030
1033
|
" ",
|
|
@@ -1033,27 +1036,27 @@ var J = {
|
|
|
1033
1036
|
}) : Z.verificationStatus === "PENDING" ? i("devportal.pendingVerification", "Pending verification") : Z.verificationStatus === "REJECTED" ? i("devportal.verificationRejected", "Rejected") : i("devportal.notVerified", "Not verified")
|
|
1034
1037
|
}, {
|
|
1035
1038
|
label: i("devportal.certifiedLabel", "Certified"),
|
|
1036
|
-
value: e.isCertified ? /* @__PURE__ */
|
|
1039
|
+
value: e.isCertified ? /* @__PURE__ */ B("span", {
|
|
1037
1040
|
className: "text-accent-blue flex items-center gap-1",
|
|
1038
1041
|
children: [
|
|
1039
|
-
/* @__PURE__ */
|
|
1042
|
+
/* @__PURE__ */ z(oe, { size: 14 }),
|
|
1040
1043
|
" ",
|
|
1041
1044
|
i("devportal.certifiedUntil", "Certified until"),
|
|
1042
1045
|
" ",
|
|
1043
1046
|
e.certificationExpiry ? new Date(e.certificationExpiry).toLocaleDateString() : "N/A"
|
|
1044
1047
|
]
|
|
1045
1048
|
}) : i("devportal.notCertified", "Not certified")
|
|
1046
|
-
}] }), Z.verificationStatus !== "VERIFIED" && /* @__PURE__ */
|
|
1049
|
+
}] }), Z.verificationStatus !== "VERIFIED" && /* @__PURE__ */ z("div", {
|
|
1047
1050
|
className: "mt-4 rounded-md border border-border-subtle p-4 space-y-3",
|
|
1048
|
-
children:
|
|
1051
|
+
children: me ? /* @__PURE__ */ B("p", {
|
|
1049
1052
|
className: "text-sm text-status-success-text flex items-center gap-2",
|
|
1050
|
-
children: [/* @__PURE__ */
|
|
1051
|
-
}) : /* @__PURE__ */
|
|
1052
|
-
/* @__PURE__ */
|
|
1053
|
+
children: [/* @__PURE__ */ z(k, { size: 14 }), i("devportal.verificationRequested", "Verification request submitted. Our team will review and contact you.")]
|
|
1054
|
+
}) : /* @__PURE__ */ B(R, { children: [
|
|
1055
|
+
/* @__PURE__ */ z("p", {
|
|
1053
1056
|
className: "text-sm text-text-secondary",
|
|
1054
1057
|
children: i("devportal.requestVerificationHint", "Get your organization verified to build trust with users. Choose a verification method:")
|
|
1055
1058
|
}),
|
|
1056
|
-
Z.verificationStatus === "PENDING" && /* @__PURE__ */
|
|
1059
|
+
Z.verificationStatus === "PENDING" && /* @__PURE__ */ B("div", {
|
|
1057
1060
|
className: "rounded-md border border-border-subtle bg-bg-sunken/40 p-3 text-sm text-text-secondary",
|
|
1058
1061
|
children: [
|
|
1059
1062
|
i("devportal.pendingVerification", "Pending verification"),
|
|
@@ -1061,61 +1064,61 @@ var J = {
|
|
|
1061
1064
|
Z.verificationRequestNotes ? ` · ${Z.verificationRequestNotes}` : ""
|
|
1062
1065
|
]
|
|
1063
1066
|
}),
|
|
1064
|
-
Z.verificationStatus === "REJECTED" && Z.verificationRejectedReason && /* @__PURE__ */
|
|
1067
|
+
Z.verificationStatus === "REJECTED" && Z.verificationRejectedReason && /* @__PURE__ */ z("div", {
|
|
1065
1068
|
className: "rounded-md border border-status-error-border bg-status-error-bg-subtle p-3 text-sm text-status-error-text",
|
|
1066
1069
|
children: Z.verificationRejectedReason
|
|
1067
1070
|
}),
|
|
1068
|
-
Q.length > 0 && /* @__PURE__ */
|
|
1071
|
+
Q.length > 0 && /* @__PURE__ */ B("div", {
|
|
1069
1072
|
className: "rounded-md border border-border-subtle bg-bg-sunken/40 p-3 text-sm text-text-secondary",
|
|
1070
|
-
children: [/* @__PURE__ */
|
|
1073
|
+
children: [/* @__PURE__ */ z("div", {
|
|
1071
1074
|
className: "font-medium text-text-primary",
|
|
1072
1075
|
children: i("devportal.completeBeforeVerification", "Complete these details before submitting for review")
|
|
1073
|
-
}), /* @__PURE__ */
|
|
1076
|
+
}), /* @__PURE__ */ z("ul", {
|
|
1074
1077
|
className: "mt-2 list-disc pl-5 space-y-1",
|
|
1075
|
-
children: Q.map((e) => /* @__PURE__ */
|
|
1078
|
+
children: Q.map((e) => /* @__PURE__ */ z("li", { children: e }, e))
|
|
1076
1079
|
})]
|
|
1077
1080
|
}),
|
|
1078
|
-
Z.verificationStatus !== "PENDING" && /* @__PURE__ */
|
|
1079
|
-
/* @__PURE__ */
|
|
1081
|
+
Z.verificationStatus !== "PENDING" && /* @__PURE__ */ B(R, { children: [
|
|
1082
|
+
/* @__PURE__ */ z("div", {
|
|
1080
1083
|
className: "flex gap-2 flex-wrap",
|
|
1081
1084
|
children: [
|
|
1082
1085
|
"domain",
|
|
1083
1086
|
"document",
|
|
1084
1087
|
"manual"
|
|
1085
|
-
].map((e) => /* @__PURE__ */
|
|
1088
|
+
].map((e) => /* @__PURE__ */ z("button", {
|
|
1086
1089
|
type: "button",
|
|
1087
|
-
onClick: () =>
|
|
1090
|
+
onClick: () => pe(e),
|
|
1088
1091
|
className: `rounded-md border px-3 py-1 text-xs font-medium transition-colors ${Y === e ? "bg-action-primary-bg text-action-primary-text border-primary" : "border-border-subtle hover:bg-bg-sunken"}`,
|
|
1089
1092
|
children: e === "domain" ? i("devportal.domainVerification", "Domain") : e === "document" ? i("devportal.documentVerification", "Document") : i("devportal.manualVerification", "Manual review")
|
|
1090
1093
|
}, e))
|
|
1091
1094
|
}),
|
|
1092
|
-
Y === "domain" ? /* @__PURE__ */
|
|
1095
|
+
Y === "domain" ? /* @__PURE__ */ z(v, {
|
|
1093
1096
|
label: i("devportal.domainVerification", "Domain"),
|
|
1094
|
-
value:
|
|
1095
|
-
onChange: (e) =>
|
|
1097
|
+
value: be,
|
|
1098
|
+
onChange: (e) => xe(e.target.value),
|
|
1096
1099
|
placeholder: "example.com"
|
|
1097
|
-
}) : Y === "document" ? /* @__PURE__ */
|
|
1100
|
+
}) : Y === "document" ? /* @__PURE__ */ z(v, {
|
|
1098
1101
|
label: i("devportal.evidenceUrl", "Evidence URL"),
|
|
1099
|
-
value:
|
|
1100
|
-
onChange: (e) =>
|
|
1102
|
+
value: ve,
|
|
1103
|
+
onChange: (e) => ye(e.target.value),
|
|
1101
1104
|
placeholder: "https://..."
|
|
1102
1105
|
}) : null,
|
|
1103
|
-
/* @__PURE__ */
|
|
1106
|
+
/* @__PURE__ */ z(y, {
|
|
1104
1107
|
label: i("devportal.notes", "Notes"),
|
|
1105
|
-
value:
|
|
1106
|
-
onChange: (e) =>
|
|
1108
|
+
value: ge,
|
|
1109
|
+
onChange: (e) => _e(e.target.value),
|
|
1107
1110
|
placeholder: "What should reviewers validate?"
|
|
1108
1111
|
}),
|
|
1109
|
-
/* @__PURE__ */
|
|
1112
|
+
/* @__PURE__ */ B("button", {
|
|
1110
1113
|
type: "button",
|
|
1111
|
-
disabled: !
|
|
1114
|
+
disabled: !Te,
|
|
1112
1115
|
onClick: () => void (async () => {
|
|
1113
|
-
let t =
|
|
1114
|
-
if (Y === "domain" && !
|
|
1116
|
+
let t = be.trim(), n = ve.trim(), r = ge.trim();
|
|
1117
|
+
if (Y === "domain" && !ue(t)) {
|
|
1115
1118
|
J(i("devportal.verification.errors.domainRequired", "Enter a valid domain like burdenoff.com"));
|
|
1116
1119
|
return;
|
|
1117
1120
|
}
|
|
1118
|
-
if (Y === "document" && !
|
|
1121
|
+
if (Y === "document" && !de(n)) {
|
|
1119
1122
|
J(i("devportal.verification.errors.evidenceUrlRequired", "Enter a valid evidence URL starting with http:// or https://"));
|
|
1120
1123
|
return;
|
|
1121
1124
|
}
|
|
@@ -1123,9 +1126,9 @@ var J = {
|
|
|
1123
1126
|
J(i("devportal.verification.errors.notesRequired", "Add notes so the reviewer knows what to verify"));
|
|
1124
1127
|
return;
|
|
1125
1128
|
}
|
|
1126
|
-
J(null),
|
|
1129
|
+
J(null), K(null), we(!0);
|
|
1127
1130
|
try {
|
|
1128
|
-
await
|
|
1131
|
+
await Ee({ variables: {
|
|
1129
1132
|
id: e.id,
|
|
1130
1133
|
input: {
|
|
1131
1134
|
name: a.name.trim() || void 0,
|
|
@@ -1136,13 +1139,13 @@ var J = {
|
|
|
1136
1139
|
logoUrl: a.logoUrl.trim() || null,
|
|
1137
1140
|
bannerUrl: a.bannerUrl.trim() || null
|
|
1138
1141
|
}
|
|
1139
|
-
} }), await
|
|
1142
|
+
} }), await Oe({ variables: {
|
|
1140
1143
|
id: e.id,
|
|
1141
1144
|
input: {
|
|
1142
1145
|
legalEntityName: u.legalEntityName.trim() || null,
|
|
1143
1146
|
legalEntityType: u.legalEntityType.trim() || null
|
|
1144
1147
|
}
|
|
1145
|
-
} }), await
|
|
1148
|
+
} }), await Ae({ variables: {
|
|
1146
1149
|
id: e.id,
|
|
1147
1150
|
input: {
|
|
1148
1151
|
taxId: p.taxId.trim() || null,
|
|
@@ -1151,7 +1154,7 @@ var J = {
|
|
|
1151
1154
|
} });
|
|
1152
1155
|
let o = await W({
|
|
1153
1156
|
gateway: "global",
|
|
1154
|
-
query:
|
|
1157
|
+
query: le,
|
|
1155
1158
|
variables: {
|
|
1156
1159
|
id: e.id,
|
|
1157
1160
|
method: Y,
|
|
@@ -1161,22 +1164,22 @@ var J = {
|
|
|
1161
1164
|
}
|
|
1162
1165
|
});
|
|
1163
1166
|
if (o.errors?.length) throw Error(o.errors[0]?.message || "Verification request failed");
|
|
1164
|
-
|
|
1167
|
+
he(!0), K(i("devportal.verificationRequested", "Verification request submitted. Our team will review and contact you.")), X((await W({
|
|
1165
1168
|
gateway: "global",
|
|
1166
|
-
query:
|
|
1169
|
+
query: ce,
|
|
1167
1170
|
variables: { id: e.id }
|
|
1168
1171
|
})).data?.developerOrganization ?? null);
|
|
1169
1172
|
} catch (e) {
|
|
1170
1173
|
J(e instanceof Error ? e.message : i("devportal.verificationRequestFailed", "Verification request failed"));
|
|
1171
1174
|
} finally {
|
|
1172
|
-
|
|
1175
|
+
we(!1);
|
|
1173
1176
|
}
|
|
1174
1177
|
})(),
|
|
1175
1178
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 disabled:opacity-50",
|
|
1176
|
-
children: [
|
|
1179
|
+
children: [Ce ? /* @__PURE__ */ z(M, {
|
|
1177
1180
|
size: 14,
|
|
1178
1181
|
className: "animate-spin"
|
|
1179
|
-
}) : /* @__PURE__ */
|
|
1182
|
+
}) : /* @__PURE__ */ z(oe, { size: 14 }), i("devportal.requestVerification", "Request Verification")]
|
|
1180
1183
|
})
|
|
1181
1184
|
] })
|
|
1182
1185
|
] })
|
|
@@ -1186,6 +1189,6 @@ var J = {
|
|
|
1186
1189
|
});
|
|
1187
1190
|
};
|
|
1188
1191
|
//#endregion
|
|
1189
|
-
export {
|
|
1192
|
+
export { J as OrganizationDetailPage };
|
|
1190
1193
|
|
|
1191
1194
|
//# sourceMappingURL=OrganizationDetailPage.js.map
|