@burdenoff/microfe-devportal 2026.1024.1 → 2026.1026.2

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.
Files changed (33) hide show
  1. package/dist/devportal/components/NodeSmokePanel.d.ts +34 -0
  2. package/dist/devportal/components/NodeSmokePanel.d.ts.map +1 -0
  3. package/dist/devportal/components/NodeSmokePanel.js +131 -0
  4. package/dist/devportal/components/NodeSmokePanel.js.map +1 -0
  5. package/dist/devportal/components/PackageValidationPanel.d.ts.map +1 -1
  6. package/dist/devportal/components/PackageValidationPanel.js +46 -36
  7. package/dist/devportal/components/PackageValidationPanel.js.map +1 -1
  8. package/dist/devportal/components/index.d.ts +1 -0
  9. package/dist/devportal/components/index.d.ts.map +1 -1
  10. package/dist/devportal/components/index.js +1 -0
  11. package/dist/devportal/hooks/useSellerOrganization.d.ts.map +1 -1
  12. package/dist/devportal/hooks/useSellerOrganization.js +23 -22
  13. package/dist/devportal/hooks/useSellerOrganization.js.map +1 -1
  14. package/dist/devportal/pages/CreatePhysicalItemPage.d.ts.map +1 -1
  15. package/dist/devportal/pages/CreatePhysicalItemPage.js +119 -118
  16. package/dist/devportal/pages/CreatePhysicalItemPage.js.map +1 -1
  17. package/dist/devportal/pages/EditPhysicalItemPage.d.ts.map +1 -1
  18. package/dist/devportal/pages/EditPhysicalItemPage.js +61 -60
  19. package/dist/devportal/pages/EditPhysicalItemPage.js.map +1 -1
  20. package/dist/devportal/pages/SellerDashboardPage.d.ts.map +1 -1
  21. package/dist/devportal/pages/SellerDashboardPage.js +142 -141
  22. package/dist/devportal/pages/SellerDashboardPage.js.map +1 -1
  23. package/dist/devportal/pages/SellerItemsPage.d.ts.map +1 -1
  24. package/dist/devportal/pages/SellerItemsPage.js +190 -189
  25. package/dist/devportal/pages/SellerItemsPage.js.map +1 -1
  26. package/dist/devportal/pages/SellerOrdersPage.d.ts.map +1 -1
  27. package/dist/devportal/pages/SellerOrdersPage.js +43 -42
  28. package/dist/devportal/pages/SellerOrdersPage.js.map +1 -1
  29. package/dist/devportal/utils/graphqlEndpoint.d.ts +6 -0
  30. package/dist/devportal/utils/graphqlEndpoint.d.ts.map +1 -0
  31. package/dist/devportal/utils/graphqlEndpoint.js +9 -0
  32. package/dist/devportal/utils/graphqlEndpoint.js.map +1 -0
  33. package/package.json +1 -1
@@ -4,12 +4,13 @@ import { PageLayout as n, PageSection as r } from "../components/PageLayout.js";
4
4
  import { CheckboxField as i, InputField as a, SelectField as o, TextareaField as s } from "../components/FormField.js";
5
5
  import { ImageUploadField as c, ScreenshotGallery as ee } from "../components/ImageUploadField.js";
6
6
  import { usePackageUpload as l } from "../hooks/usePackageUpload.js";
7
- import { useSellerOrganization as u } from "../hooks/useSellerOrganization.js";
8
- import { useState as d } from "react";
9
- import { Info as f, Loader2 as p } from "lucide-react";
10
- import { Fragment as m, jsx as h, jsxs as g } from "react/jsx-runtime";
7
+ import { resolveGlobalGraphqlEndpoint as te } from "../utils/graphqlEndpoint.js";
8
+ import { useSellerOrganization as ne } from "../hooks/useSellerOrganization.js";
9
+ import { useState as u } from "react";
10
+ import { Info as re, Loader2 as d } from "lucide-react";
11
+ import { Fragment as f, jsx as p, jsxs as m } from "react/jsx-runtime";
11
12
  //#region src/devportal/pages/CreatePhysicalItemPage.tsx
12
- var _ = [
13
+ var ie = [
13
14
  {
14
15
  value: "MERCHANDISE",
15
16
  label: "Merchandise"
@@ -42,7 +43,7 @@ var _ = [
42
43
  value: "CONSUMABLE",
43
44
  label: "Consumable"
44
45
  }
45
- ], v = [
46
+ ], h = [
46
47
  {
47
48
  value: "agri-seeds",
48
49
  label: "Agri-Inputs — Seeds"
@@ -63,7 +64,7 @@ var _ = [
63
64
  value: "agri-irrigation",
64
65
  label: "Agri-Inputs — Irrigation"
65
66
  }
66
- ], te = [
67
+ ], g = [
67
68
  {
68
69
  value: "USD",
69
70
  label: "USD — US Dollar"
@@ -88,7 +89,7 @@ var _ = [
88
89
  value: "AED",
89
90
  label: "AED — UAE Dirham"
90
91
  }
91
- ], ne = [
92
+ ], ae = [
92
93
  {
93
94
  value: "GRAM",
94
95
  label: "Grams (g)"
@@ -105,7 +106,7 @@ var _ = [
105
106
  value: "POUND",
106
107
  label: "Pounds (lb)"
107
108
  }
108
- ], re = [
109
+ ], oe = [
109
110
  {
110
111
  value: "CENTIMETER",
111
112
  label: "Centimeters (cm)"
@@ -118,7 +119,7 @@ var _ = [
118
119
  value: "METER",
119
120
  label: "Meters (m)"
120
121
  }
121
- ], y = [
122
+ ], _ = [
122
123
  "name",
123
124
  "slug",
124
125
  "type",
@@ -126,18 +127,18 @@ var _ = [
126
127
  "price",
127
128
  "currency",
128
129
  "stockQuantity"
129
- ], ie = "\n query SellerMyPublisher {\n myPublisher {\n id\n }\n }\n", ae = "\n mutation RegisterPublisher($input: RegisterPublisherInput!) {\n registerPublisher(input: $input) {\n id\n name\n email\n }\n }\n", oe = "\n mutation CreatePhysicalProduct($input: CreatePhysicalProductInput!) {\n createPhysicalProduct(input: $input) {\n id\n name\n slug\n status\n nature\n type\n price\n currency\n icon\n bannerUrl\n screenshots\n }\n }\n", se = "\n mutation SubmitProduct($id: ID!, $notes: String) {\n submitProduct(id: $id, notes: $notes) {\n id\n status\n }\n }\n";
130
- function ce(e) {
130
+ ], se = "\n query SellerMyPublisher {\n myPublisher {\n id\n }\n }\n", ce = "\n mutation RegisterPublisher($input: RegisterPublisherInput!) {\n registerPublisher(input: $input) {\n id\n name\n email\n }\n }\n", le = "\n mutation CreatePhysicalProduct($input: CreatePhysicalProductInput!) {\n createPhysicalProduct(input: $input) {\n id\n name\n slug\n status\n nature\n type\n price\n currency\n icon\n bannerUrl\n screenshots\n }\n }\n", v = "\n mutation SubmitProduct($id: ID!, $notes: String) {\n submitProduct(id: $id, notes: $notes) {\n id\n status\n }\n }\n";
131
+ function y(e) {
131
132
  return e.toLowerCase().replace(/[^a-z0-9]+/g, "-");
132
133
  }
133
134
  function b(e) {
134
- return y.every((t) => {
135
+ return _.every((t) => {
135
136
  let n = e[t];
136
137
  return typeof n == "boolean" ? !0 : n.trim() !== "";
137
138
  });
138
139
  }
139
140
  var x = () => {
140
- let { navigate: y, basePath: x, productId: S, apiGatewayUrl: C, authToken: w, workspacesGatewayUrl: T, workspaceId: E, getWorkspaceToken: D } = e(), { organization: O, organizations: k, loading: A, error: j, selectOrganization: le } = u(), [M, N] = d({
141
+ let { navigate: _, basePath: x, productId: S, apiGatewayUrl: ue, authToken: C, workspacesGatewayUrl: w, workspaceId: T, getWorkspaceToken: E } = e(), { organization: D, organizations: O, loading: k, error: A, selectOrganization: j } = ne(), [M, N] = u({
141
142
  name: "",
142
143
  slug: "",
143
144
  type: "",
@@ -164,27 +165,27 @@ var x = () => {
164
165
  countryOfOrigin: "",
165
166
  warrantyInfo: "",
166
167
  returnPolicy: ""
167
- }), [P, F] = d(""), [I, L] = d(""), [R, z] = d([]), { upload: B, uploading: V, progress: H, error: U } = l(T, w, E, D, "/DevPortal/Assets"), { upload: ue, uploading: W, progress: de, error: fe } = l(T, w, E, D, "/DevPortal/Assets"), { upload: pe, uploading: G, progress: me, error: he } = l(T, w, E, D, "/DevPortal/Assets"), [K, q] = d(!1), [J, Y] = d(null), [ge, _e] = d(!1), ve = V || W || G, X = b(M) && !!O && !ve, ye = `${C || ""}/global/graphql`, Z = (e, t) => {
168
+ }), [P, F] = u(""), [I, L] = u(""), [R, z] = u([]), { upload: B, uploading: V, progress: H, error: U } = l(w, C, T, E, "/DevPortal/Assets"), { upload: de, uploading: W, progress: fe, error: pe } = l(w, C, T, E, "/DevPortal/Assets"), { upload: me, uploading: G, progress: he, error: ge } = l(w, C, T, E, "/DevPortal/Assets"), [K, q] = u(!1), [J, Y] = u(null), [_e, ve] = u(!1), ye = V || W || G, X = b(M) && !!D && !ye, be = te(ue), Z = (e, t) => {
168
169
  N((n) => ({
169
170
  ...n,
170
171
  [e]: t
171
172
  }));
172
- }, be = (e) => {
173
+ }, xe = (e) => {
173
174
  let t = e.target.value;
174
175
  N((e) => ({
175
176
  ...e,
176
177
  name: t,
177
- slug: ce(t)
178
+ slug: y(t)
178
179
  }));
179
180
  }, Q = (e) => (t) => {
180
181
  Z(e, t.target.checked);
181
182
  };
182
183
  async function $(e, t) {
183
- let n = await (await fetch(ye, {
184
+ let n = await (await fetch(be, {
184
185
  method: "POST",
185
186
  headers: {
186
187
  "Content-Type": "application/json",
187
- ...w ? { Authorization: `Bearer ${w}` } : {}
188
+ ...C ? { Authorization: `Bearer ${C}` } : {}
188
189
  },
189
190
  credentials: "include",
190
191
  body: JSON.stringify({
@@ -195,61 +196,61 @@ var x = () => {
195
196
  if (n.errors?.length) throw Error(n.errors.map((e) => e.message).join("; "));
196
197
  return n.data;
197
198
  }
198
- return /* @__PURE__ */ h(n, {
199
+ return /* @__PURE__ */ p(n, {
199
200
  title: "List a Physical Item",
200
201
  description: "Fill in all required details. Your listing will be reviewed before it appears in the store.",
201
202
  backLink: "/seller/items",
202
203
  backLabel: "Back to My Items",
203
- children: /* @__PURE__ */ g("div", {
204
+ children: /* @__PURE__ */ m("div", {
204
205
  className: "space-y-8 max-w-3xl",
205
206
  children: [
206
- ge && /* @__PURE__ */ h("div", {
207
+ _e && /* @__PURE__ */ p("div", {
207
208
  className: "rounded-card border border-status-success-text/30 bg-status-success-bg-subtle px-4 py-3 text-sm text-status-success-text",
208
209
  children: "Your listing has been submitted for review! Redirecting..."
209
210
  }),
210
- J && /* @__PURE__ */ h("div", {
211
+ J && /* @__PURE__ */ p("div", {
211
212
  className: "rounded-card border border-status-error-text/30 bg-status-error-bg-subtle px-4 py-3 text-sm text-status-error-text",
212
213
  children: J
213
214
  }),
214
- j && /* @__PURE__ */ g("div", {
215
+ A && /* @__PURE__ */ m("div", {
215
216
  className: "rounded-card border border-status-error-text/30 bg-status-error-bg-subtle px-4 py-3 text-sm text-status-error-text",
216
- children: ["Couldn't set up your seller organization: ", j]
217
+ children: ["Couldn't set up your seller organization: ", A]
217
218
  }),
218
- /* @__PURE__ */ h(r, {
219
+ /* @__PURE__ */ p(r, {
219
220
  title: "Seller Organization",
220
221
  description: "The seller organization this item will be listed under.",
221
- children: /* @__PURE__ */ h("div", {
222
+ children: /* @__PURE__ */ p("div", {
222
223
  className: "rounded-card border border-border-seam bg-bg-surface p-6 space-y-3",
223
- children: /* @__PURE__ */ h(o, {
224
+ children: /* @__PURE__ */ p(o, {
224
225
  label: "Organization",
225
226
  required: !0,
226
- value: O?.id ?? "",
227
- onChange: (e) => le(e.target.value),
228
- options: k.map((e) => ({
227
+ value: D?.id ?? "",
228
+ onChange: (e) => j(e.target.value),
229
+ options: O.map((e) => ({
229
230
  value: e.id,
230
231
  label: e.name
231
232
  })),
232
- placeholder: A ? "Resolving your seller organization…" : "Select an organization",
233
- disabled: A || k.length <= 1,
234
- hint: k.length > 1 ? "You have more than one seller organization — pick the one this item belongs to." : O ? `Automatically set to your only seller organization, "${O.name}".` : void 0
233
+ placeholder: k ? "Resolving your seller organization…" : "Select an organization",
234
+ disabled: k || O.length <= 1,
235
+ hint: O.length > 1 ? "You have more than one seller organization — pick the one this item belongs to." : D ? `Automatically set to your only seller organization, "${D.name}".` : void 0
235
236
  })
236
237
  })
237
238
  }),
238
- /* @__PURE__ */ h(r, {
239
+ /* @__PURE__ */ p(r, {
239
240
  title: "Basic Information",
240
241
  description: "Core details shown in the store listing.",
241
- children: /* @__PURE__ */ g("div", {
242
+ children: /* @__PURE__ */ m("div", {
242
243
  className: "rounded-card border border-border-seam bg-bg-surface p-6 space-y-5",
243
244
  children: [
244
- /* @__PURE__ */ h(a, {
245
+ /* @__PURE__ */ p(a, {
245
246
  label: "Name",
246
247
  required: !0,
247
248
  value: M.name,
248
- onChange: be,
249
+ onChange: xe,
249
250
  placeholder: "e.g. Wireless Ergonomic Keyboard",
250
251
  maxLength: 120
251
252
  }),
252
- /* @__PURE__ */ h(a, {
253
+ /* @__PURE__ */ p(a, {
253
254
  label: "Slug",
254
255
  required: !0,
255
256
  value: M.slug,
@@ -257,23 +258,23 @@ var x = () => {
257
258
  placeholder: "auto-derived-from-name",
258
259
  hint: "URL-friendly identifier. Auto-derived from name; you can edit it."
259
260
  }),
260
- /* @__PURE__ */ h(o, {
261
+ /* @__PURE__ */ p(o, {
261
262
  label: "Product Type",
262
263
  required: !0,
263
264
  value: M.type,
264
265
  onChange: (e) => Z("type", e.target.value),
265
- options: _,
266
+ options: ie,
266
267
  placeholder: "Select a type"
267
268
  }),
268
- /* @__PURE__ */ h(o, {
269
+ /* @__PURE__ */ p(o, {
269
270
  label: "Store Category",
270
271
  value: M.category,
271
272
  onChange: (e) => Z("category", e.target.value),
272
- options: v,
273
+ options: h,
273
274
  placeholder: "General / uncategorised",
274
275
  hint: "Pick an Agri-Inputs category to list this item in the HealthyBowl Agri-Inputs Store. Leave blank for a general store listing."
275
276
  }),
276
- /* @__PURE__ */ h(a, {
277
+ /* @__PURE__ */ p(a, {
277
278
  label: "Short Description",
278
279
  required: !0,
279
280
  value: M.shortDescription,
@@ -282,7 +283,7 @@ var x = () => {
282
283
  maxLength: 160,
283
284
  hint: `${M.shortDescription.length}/160`
284
285
  }),
285
- /* @__PURE__ */ h(s, {
286
+ /* @__PURE__ */ p(s, {
286
287
  label: "Long Description",
287
288
  value: M.longDescription,
288
289
  onChange: (e) => Z("longDescription", e.target.value),
@@ -292,14 +293,14 @@ var x = () => {
292
293
  ]
293
294
  })
294
295
  }),
295
- /* @__PURE__ */ h(r, {
296
+ /* @__PURE__ */ p(r, {
296
297
  title: "Product Images",
297
298
  description: "Visual assets shown to buyers browsing the store.",
298
- children: /* @__PURE__ */ g("div", {
299
+ children: /* @__PURE__ */ m("div", {
299
300
  className: "rounded-card border border-border-seam bg-bg-surface p-6 space-y-5",
300
- children: [/* @__PURE__ */ g("div", {
301
+ children: [/* @__PURE__ */ m("div", {
301
302
  className: "grid gap-5 sm:grid-cols-2",
302
- children: [/* @__PURE__ */ h(c, {
303
+ children: [/* @__PURE__ */ p(c, {
303
304
  label: "Icon",
304
305
  value: P,
305
306
  onChange: F,
@@ -309,34 +310,34 @@ var x = () => {
309
310
  uploading: V,
310
311
  progress: H,
311
312
  error: U
312
- }), /* @__PURE__ */ h(c, {
313
+ }), /* @__PURE__ */ p(c, {
313
314
  label: "Banner",
314
315
  value: I,
315
316
  onChange: L,
316
317
  hint: "Fills the right panel on the product page — square or portrait works best on all screen sizes (1:1)",
317
318
  aspectClass: "aspect-square",
318
- upload: ue,
319
+ upload: de,
319
320
  uploading: W,
320
- progress: de,
321
- error: fe
321
+ progress: fe,
322
+ error: pe
322
323
  })]
323
- }), /* @__PURE__ */ h(ee, {
324
+ }), /* @__PURE__ */ p(ee, {
324
325
  urls: R,
325
326
  onChange: z,
326
- upload: pe,
327
+ upload: me,
327
328
  uploading: G,
328
- progress: me,
329
- error: he
329
+ progress: he,
330
+ error: ge
330
331
  })]
331
332
  })
332
333
  }),
333
- /* @__PURE__ */ h(r, {
334
+ /* @__PURE__ */ p(r, {
334
335
  title: "Pricing",
335
- children: /* @__PURE__ */ g("div", {
336
+ children: /* @__PURE__ */ m("div", {
336
337
  className: "rounded-card border border-border-seam bg-bg-surface p-6 space-y-5",
337
- children: [/* @__PURE__ */ g("div", {
338
+ children: [/* @__PURE__ */ m("div", {
338
339
  className: "grid grid-cols-1 gap-5 sm:grid-cols-2",
339
- children: [/* @__PURE__ */ h(a, {
340
+ children: [/* @__PURE__ */ p(a, {
340
341
  label: "Price",
341
342
  required: !0,
342
343
  type: "number",
@@ -345,15 +346,15 @@ var x = () => {
345
346
  placeholder: "0.00",
346
347
  min: .01,
347
348
  step: "0.01"
348
- }), /* @__PURE__ */ h(o, {
349
+ }), /* @__PURE__ */ p(o, {
349
350
  label: "Currency",
350
351
  required: !0,
351
352
  value: M.currency,
352
353
  onChange: (e) => Z("currency", e.target.value),
353
- options: te,
354
+ options: g,
354
355
  placeholder: "Select currency"
355
356
  })]
356
- }), /* @__PURE__ */ h(a, {
357
+ }), /* @__PURE__ */ p(a, {
357
358
  label: "Tags",
358
359
  value: M.tags,
359
360
  onChange: (e) => Z("tags", e.target.value),
@@ -362,14 +363,14 @@ var x = () => {
362
363
  })]
363
364
  })
364
365
  }),
365
- /* @__PURE__ */ h(r, {
366
+ /* @__PURE__ */ p(r, {
366
367
  title: "Inventory",
367
- children: /* @__PURE__ */ g("div", {
368
+ children: /* @__PURE__ */ m("div", {
368
369
  className: "rounded-card border border-border-seam bg-bg-surface p-6 space-y-5",
369
370
  children: [
370
- /* @__PURE__ */ g("div", {
371
+ /* @__PURE__ */ m("div", {
371
372
  className: "grid grid-cols-1 gap-5 sm:grid-cols-2",
372
- children: [/* @__PURE__ */ h(a, {
373
+ children: [/* @__PURE__ */ p(a, {
373
374
  label: "Stock Quantity",
374
375
  required: !0,
375
376
  type: "number",
@@ -377,7 +378,7 @@ var x = () => {
377
378
  onChange: (e) => Z("stockQuantity", e.target.value),
378
379
  min: 0,
379
380
  step: 1
380
- }), /* @__PURE__ */ h(a, {
381
+ }), /* @__PURE__ */ p(a, {
381
382
  label: "SKU",
382
383
  value: M.sku,
383
384
  onChange: (e) => Z("sku", e.target.value),
@@ -385,7 +386,7 @@ var x = () => {
385
386
  hint: "Your internal stock-keeping unit reference."
386
387
  })]
387
388
  }),
388
- /* @__PURE__ */ h(a, {
389
+ /* @__PURE__ */ p(a, {
389
390
  label: "Low Stock Threshold",
390
391
  type: "number",
391
392
  value: M.lowStockThreshold,
@@ -395,13 +396,13 @@ var x = () => {
395
396
  step: 1,
396
397
  hint: "Get flagged when stock falls to or below this number."
397
398
  }),
398
- /* @__PURE__ */ h(i, {
399
+ /* @__PURE__ */ p(i, {
399
400
  label: "Track Inventory",
400
401
  description: "Automatically reduce stock when orders are placed.",
401
402
  checked: M.trackInventory,
402
403
  onChange: Q("trackInventory")
403
404
  }),
404
- /* @__PURE__ */ h(i, {
405
+ /* @__PURE__ */ p(i, {
405
406
  label: "Allow Backorder",
406
407
  description: "Let buyers order even when stock quantity is zero.",
407
408
  checked: M.allowBackorder,
@@ -410,21 +411,21 @@ var x = () => {
410
411
  ]
411
412
  })
412
413
  }),
413
- /* @__PURE__ */ h(r, {
414
+ /* @__PURE__ */ p(r, {
414
415
  title: "Shipping",
415
- children: /* @__PURE__ */ g("div", {
416
+ children: /* @__PURE__ */ m("div", {
416
417
  className: "rounded-card border border-border-seam bg-bg-surface p-6 space-y-5",
417
418
  children: [
418
- /* @__PURE__ */ h(i, {
419
+ /* @__PURE__ */ p(i, {
419
420
  label: "Requires Shipping",
420
421
  description: "This item will be physically shipped to the buyer.",
421
422
  checked: M.requiresShipping,
422
423
  onChange: Q("requiresShipping")
423
424
  }),
424
- M.requiresShipping && /* @__PURE__ */ g(m, { children: [
425
- /* @__PURE__ */ g("div", {
425
+ M.requiresShipping && /* @__PURE__ */ m(f, { children: [
426
+ /* @__PURE__ */ m("div", {
426
427
  className: "grid grid-cols-1 gap-5 sm:grid-cols-2",
427
- children: [/* @__PURE__ */ h(a, {
428
+ children: [/* @__PURE__ */ p(a, {
428
429
  label: "Weight",
429
430
  type: "number",
430
431
  value: M.weightKg,
@@ -433,17 +434,17 @@ var x = () => {
433
434
  min: 0,
434
435
  step: "0.01",
435
436
  hint: "Used to calculate shipping costs."
436
- }), /* @__PURE__ */ h(o, {
437
+ }), /* @__PURE__ */ p(o, {
437
438
  label: "Weight Unit",
438
439
  value: M.weightUnit,
439
440
  onChange: (e) => Z("weightUnit", e.target.value),
440
- options: ne
441
+ options: ae
441
442
  })]
442
443
  }),
443
- /* @__PURE__ */ g("div", {
444
+ /* @__PURE__ */ m("div", {
444
445
  className: "grid grid-cols-1 gap-5 sm:grid-cols-3",
445
446
  children: [
446
- /* @__PURE__ */ h(a, {
447
+ /* @__PURE__ */ p(a, {
447
448
  label: "Length",
448
449
  type: "number",
449
450
  value: M.length,
@@ -452,7 +453,7 @@ var x = () => {
452
453
  min: 0,
453
454
  step: "0.01"
454
455
  }),
455
- /* @__PURE__ */ h(a, {
456
+ /* @__PURE__ */ p(a, {
456
457
  label: "Width",
457
458
  type: "number",
458
459
  value: M.width,
@@ -461,7 +462,7 @@ var x = () => {
461
462
  min: 0,
462
463
  step: "0.01"
463
464
  }),
464
- /* @__PURE__ */ h(a, {
465
+ /* @__PURE__ */ p(a, {
465
466
  label: "Height",
466
467
  type: "number",
467
468
  value: M.height,
@@ -472,17 +473,17 @@ var x = () => {
472
473
  })
473
474
  ]
474
475
  }),
475
- /* @__PURE__ */ h(o, {
476
+ /* @__PURE__ */ p(o, {
476
477
  label: "Dimension Unit",
477
478
  value: M.dimensionUnit,
478
479
  onChange: (e) => Z("dimensionUnit", e.target.value),
479
- options: re,
480
+ options: oe,
480
481
  hint: "Applies to length, width, and height above."
481
482
  })
482
483
  ] }),
483
- /* @__PURE__ */ g("p", {
484
+ /* @__PURE__ */ m("p", {
484
485
  className: "flex items-start gap-2 rounded-input border border-border-subtle bg-bg-sunken px-3 py-2 text-xs text-text-secondary",
485
- children: [/* @__PURE__ */ h(f, {
486
+ children: [/* @__PURE__ */ p(re, {
486
487
  size: 13,
487
488
  className: "mt-0.5 shrink-0 text-text-muted"
488
489
  }), "Delivery fees are configured at the organization level in store settings."]
@@ -490,39 +491,39 @@ var x = () => {
490
491
  ]
491
492
  })
492
493
  }),
493
- /* @__PURE__ */ h(r, {
494
+ /* @__PURE__ */ p(r, {
494
495
  title: "Product Details",
495
496
  description: "Optional supplemental information for buyers.",
496
- children: /* @__PURE__ */ g("div", {
497
+ children: /* @__PURE__ */ m("div", {
497
498
  className: "rounded-card border border-border-seam bg-bg-surface p-6 space-y-5",
498
499
  children: [
499
- /* @__PURE__ */ g("div", {
500
+ /* @__PURE__ */ m("div", {
500
501
  className: "grid grid-cols-1 gap-5 sm:grid-cols-2",
501
- children: [/* @__PURE__ */ h(a, {
502
+ children: [/* @__PURE__ */ p(a, {
502
503
  label: "Brand",
503
504
  value: M.brand,
504
505
  onChange: (e) => Z("brand", e.target.value),
505
506
  placeholder: "e.g. Logitech"
506
- }), /* @__PURE__ */ h(a, {
507
+ }), /* @__PURE__ */ p(a, {
507
508
  label: "Manufacturer",
508
509
  value: M.manufacturer,
509
510
  onChange: (e) => Z("manufacturer", e.target.value),
510
511
  placeholder: "e.g. Logitech Manufacturing Ltd."
511
512
  })]
512
513
  }),
513
- /* @__PURE__ */ h(a, {
514
+ /* @__PURE__ */ p(a, {
514
515
  label: "Country of Origin",
515
516
  value: M.countryOfOrigin,
516
517
  onChange: (e) => Z("countryOfOrigin", e.target.value),
517
518
  placeholder: "e.g. China"
518
519
  }),
519
- /* @__PURE__ */ h(a, {
520
+ /* @__PURE__ */ p(a, {
520
521
  label: "Warranty Info",
521
522
  value: M.warrantyInfo,
522
523
  onChange: (e) => Z("warrantyInfo", e.target.value),
523
524
  placeholder: "e.g. 1-year limited manufacturer warranty"
524
525
  }),
525
- /* @__PURE__ */ h(s, {
526
+ /* @__PURE__ */ p(s, {
526
527
  label: "Return Policy",
527
528
  value: M.returnPolicy,
528
529
  onChange: (e) => Z("returnPolicy", e.target.value),
@@ -532,31 +533,31 @@ var x = () => {
532
533
  ]
533
534
  })
534
535
  }),
535
- /* @__PURE__ */ g("div", {
536
+ /* @__PURE__ */ m("div", {
536
537
  className: "flex items-center gap-3 pb-8",
537
- children: [/* @__PURE__ */ h("button", {
538
+ children: [/* @__PURE__ */ p("button", {
538
539
  type: "button",
539
- onClick: () => y?.(`${x}/seller/items`),
540
+ onClick: () => _?.(`${x}/seller/items`),
540
541
  className: "rounded-button border border-border-strong px-4 py-2 text-sm font-medium text-text-primary hover:bg-bg-sunken transition-colors",
541
542
  children: "Cancel"
542
- }), /* @__PURE__ */ h("div", {
543
+ }), /* @__PURE__ */ p("div", {
543
544
  className: "relative",
544
- children: /* @__PURE__ */ h("button", {
545
+ children: /* @__PURE__ */ p("button", {
545
546
  type: "button",
546
547
  onClick: async () => {
547
- if (!(!X || K || !O)) {
548
+ if (!(!X || K || !D)) {
548
549
  q(!0), Y(null);
549
550
  try {
550
- let e = (await $(ie)).myPublisher?.id ?? null;
551
- e ||= (await $(ae, { input: {
552
- name: O.legalEntityName ?? O.name,
553
- email: O.contactEmail ?? "seller@burdenoff.com",
554
- websiteUrl: O.websiteUrl ?? null,
555
- legalName: O.legalEntityName ?? O.name,
556
- country: O.taxCountry ?? null,
557
- contactEmail: O.contactEmail ?? null
551
+ let e = (await $(se)).myPublisher?.id ?? null;
552
+ e ||= (await $(ce, { input: {
553
+ name: D.legalEntityName ?? D.name,
554
+ email: D.contactEmail ?? "seller@burdenoff.com",
555
+ websiteUrl: D.websiteUrl ?? null,
556
+ legalName: D.legalEntityName ?? D.name,
557
+ country: D.taxCountry ?? null,
558
+ contactEmail: D.contactEmail ?? null
558
559
  } })).registerPublisher.id;
559
- let t = M.tags.split(",").map((e) => e.trim()).filter(Boolean), n = M.length.trim() || M.width.trim() || M.height.trim(), r = (await $(oe, { input: {
560
+ let t = M.tags.split(",").map((e) => e.trim()).filter(Boolean), n = M.length.trim() || M.width.trim() || M.height.trim(), r = (await $(le, { input: {
560
561
  name: M.name.trim(),
561
562
  slug: M.slug.trim(),
562
563
  type: M.type,
@@ -587,13 +588,13 @@ var x = () => {
587
588
  bannerUrl: I || null,
588
589
  screenshots: R.length > 0 ? R : null,
589
590
  compatibleProducts: S ? [S] : null,
590
- organizationId: O.id
591
+ organizationId: D.id
591
592
  } })).createPhysicalProduct.id;
592
- await $(se, {
593
+ await $(v, {
593
594
  id: r,
594
595
  notes: "Submitted from seller portal"
595
- }), _e(!0), setTimeout(() => {
596
- y?.(`${x}/seller/items`);
596
+ }), ve(!0), setTimeout(() => {
597
+ _?.(`${x}/seller/items`);
597
598
  }, 2e3);
598
599
  } catch (e) {
599
600
  Y(e instanceof Error ? e.message : "Submission failed. Please try again.");
@@ -604,12 +605,12 @@ var x = () => {
604
605
  },
605
606
  disabled: !X || K,
606
607
  "aria-disabled": !X || K,
607
- title: A ? "Setting up your seller organization..." : X ? void 0 : "Fill in all required fields to continue",
608
+ title: k ? "Setting up your seller organization..." : X ? void 0 : "Fill in all required fields to continue",
608
609
  className: t("inline-flex items-center gap-2 rounded-button px-5 py-2 text-sm font-medium transition-colors", "bg-action-primary-bg text-action-primary-text", "hover:bg-action-primary-bg/90", "disabled:opacity-50 disabled:cursor-not-allowed", "focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2"),
609
- children: K ? /* @__PURE__ */ g(m, { children: [/* @__PURE__ */ h(p, {
610
+ children: K ? /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p(d, {
610
611
  size: 15,
611
612
  className: "animate-spin"
612
- }), "Submitting..."] }) : A ? /* @__PURE__ */ g(m, { children: [/* @__PURE__ */ h(p, {
613
+ }), "Submitting..."] }) : k ? /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p(d, {
613
614
  size: 15,
614
615
  className: "animate-spin"
615
616
  }), "Setting up your store..."] }) : "Create & Submit for Review"