@burdenoff/microfe-store 2026.525.2 → 2026.527.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.
Files changed (120) hide show
  1. package/dist/StoreAdminRoutes.js +10 -9
  2. package/dist/StoreAdminRoutes.js.map +1 -1
  3. package/dist/StoreRoutes.js +2 -1
  4. package/dist/StoreRoutes.js.map +1 -1
  5. package/dist/components/AccessDenied.js +23 -0
  6. package/dist/components/AccessDenied.js.map +1 -0
  7. package/dist/components/InstallAppModal.js +183 -129
  8. package/dist/components/InstallAppModal.js.map +1 -1
  9. package/dist/components/PermissionGuard.js +8 -0
  10. package/dist/components/PermissionGuard.js.map +1 -0
  11. package/dist/components/RouteGuards.js +7 -21
  12. package/dist/components/RouteGuards.js.map +1 -1
  13. package/dist/components/cart/CartDrawer.js +20 -14
  14. package/dist/components/cart/CartDrawer.js.map +1 -1
  15. package/dist/hooks/useStoreGraphQL.js +22 -20
  16. package/dist/hooks/useStoreGraphQL.js.map +1 -1
  17. package/dist/hooks/useStoreGraphQLWithContext.js.map +1 -1
  18. package/dist/hooks/useStorePermissions.js +4 -1
  19. package/dist/hooks/useStorePermissions.js.map +1 -1
  20. package/dist/index.js +4 -4
  21. package/dist/pages/AdminDashboardPage.js +182 -183
  22. package/dist/pages/AdminDashboardPage.js.map +1 -1
  23. package/dist/pages/AdminReviewModerationPage.js +7 -6
  24. package/dist/pages/AdminReviewModerationPage.js.map +1 -1
  25. package/dist/pages/AdminStoresPage.js +193 -185
  26. package/dist/pages/AdminStoresPage.js.map +1 -1
  27. package/dist/pages/AdminSubmissionsQueuePage.js +140 -142
  28. package/dist/pages/AdminSubmissionsQueuePage.js.map +1 -1
  29. package/dist/pages/AppDetailPage.js +6 -3
  30. package/dist/pages/AppDetailPage.js.map +1 -1
  31. package/dist/pages/AppSettingsPage.js +6 -3
  32. package/dist/pages/AppSettingsPage.js.map +1 -1
  33. package/dist/pages/CartPage.js +23 -15
  34. package/dist/pages/CartPage.js.map +1 -1
  35. package/dist/pages/InstalledAppsPage.js +26 -15
  36. package/dist/pages/InstalledAppsPage.js.map +1 -1
  37. package/dist/pages/MarketplaceHomePage.js +275 -247
  38. package/dist/pages/MarketplaceHomePage.js.map +1 -1
  39. package/dist/pages/MyLicensesPage.js +10 -8
  40. package/dist/pages/MyLicensesPage.js.map +1 -1
  41. package/dist/pages/OrderConfirmationPage.js +72 -75
  42. package/dist/pages/OrderConfirmationPage.js.map +1 -1
  43. package/dist/pages/OrdersPage.js +22 -20
  44. package/dist/pages/OrdersPage.js.map +1 -1
  45. package/dist/pages/ProductCategoryPage.js +3 -1
  46. package/dist/pages/ProductCategoryPage.js.map +1 -1
  47. package/dist/pages/ProductDetailPage.js +458 -443
  48. package/dist/pages/ProductDetailPage.js.map +1 -1
  49. package/dist/pages/ProductReviewsPage.js +4 -3
  50. package/dist/pages/ProductReviewsPage.js.map +1 -1
  51. package/dist/pages/PublisherDashboardPage.js +13 -7
  52. package/dist/pages/PublisherDashboardPage.js.map +1 -1
  53. package/dist/pages/PublisherRevenuePage.js +7 -5
  54. package/dist/pages/PublisherRevenuePage.js.map +1 -1
  55. package/dist/pages/PublisherSubmissionsPage.js +12 -7
  56. package/dist/pages/PublisherSubmissionsPage.js.map +1 -1
  57. package/dist/pages/PublisherSubmitPage.js +6 -0
  58. package/dist/pages/PublisherSubmitPage.js.map +1 -1
  59. package/dist/pages/SearchResultsPage.js +6 -3
  60. package/dist/pages/SearchResultsPage.js.map +1 -1
  61. package/dist/pages/StoresPage.js +73 -74
  62. package/dist/pages/StoresPage.js.map +1 -1
  63. package/dist/providers/StoreProvider.js +25 -25
  64. package/dist/providers/StoreProvider.js.map +1 -1
  65. package/dist/utils/index.js +29 -19
  66. package/dist/utils/index.js.map +1 -1
  67. package/package.json +1 -1
  68. package/dist/StoreAdminRoot.d.ts +0 -22
  69. package/dist/StoreAdminRoutes.d.ts +0 -9
  70. package/dist/StoreRoot.d.ts +0 -31
  71. package/dist/StoreRoutes.d.ts +0 -12
  72. package/dist/components/InstallAppModal.d.ts +0 -26
  73. package/dist/components/RouteGuards.d.ts +0 -17
  74. package/dist/components/cart/CartDrawer.d.ts +0 -35
  75. package/dist/components/index.d.ts +0 -9
  76. package/dist/components/index.js +0 -3
  77. package/dist/components/marketplace/ProductCard.d.ts +0 -18
  78. package/dist/components/marketplace/ProductCard.js +0 -2
  79. package/dist/dev/main.d.ts +0 -1
  80. package/dist/generated/global-operations.d.ts +0 -2012
  81. package/dist/generated/global-types.d.ts +0 -23526
  82. package/dist/generated/wspace-operations.d.ts +0 -1
  83. package/dist/generated/wspace-types.d.ts +0 -57850
  84. package/dist/hooks/index.d.ts +0 -12
  85. package/dist/hooks/useBackendCart.d.ts +0 -73
  86. package/dist/hooks/useCart.d.ts +0 -62
  87. package/dist/hooks/useInstallations.d.ts +0 -43
  88. package/dist/hooks/useOrders.d.ts +0 -40
  89. package/dist/hooks/useProductSearch.d.ts +0 -22
  90. package/dist/hooks/useStoreGraphQL.d.ts +0 -475
  91. package/dist/hooks/useStoreGraphQLWithContext.d.ts +0 -48
  92. package/dist/hooks/useStorePermissions.d.ts +0 -63
  93. package/dist/index.d.ts +0 -44
  94. package/dist/pages/AdminDashboardPage.d.ts +0 -3
  95. package/dist/pages/AdminReviewModerationPage.d.ts +0 -3
  96. package/dist/pages/AdminStoresPage.d.ts +0 -3
  97. package/dist/pages/AdminSubmissionsQueuePage.d.ts +0 -3
  98. package/dist/pages/AppDetailPage.d.ts +0 -3
  99. package/dist/pages/AppSettingsPage.d.ts +0 -3
  100. package/dist/pages/CartPage.d.ts +0 -8
  101. package/dist/pages/InstalledAppsPage.d.ts +0 -8
  102. package/dist/pages/MarketplaceHomePage.d.ts +0 -3
  103. package/dist/pages/MyLicensesPage.d.ts +0 -3
  104. package/dist/pages/OrderConfirmationPage.d.ts +0 -3
  105. package/dist/pages/OrdersPage.d.ts +0 -8
  106. package/dist/pages/ProductCategoryPage.d.ts +0 -3
  107. package/dist/pages/ProductDetailPage.d.ts +0 -8
  108. package/dist/pages/ProductReviewsPage.d.ts +0 -3
  109. package/dist/pages/PublisherDashboardPage.d.ts +0 -3
  110. package/dist/pages/PublisherRevenuePage.d.ts +0 -3
  111. package/dist/pages/PublisherSubmissionsPage.d.ts +0 -3
  112. package/dist/pages/PublisherSubmitPage.d.ts +0 -3
  113. package/dist/pages/SearchResultsPage.d.ts +0 -3
  114. package/dist/pages/StoresPage.d.ts +0 -3
  115. package/dist/providers/StoreProvider.d.ts +0 -38
  116. package/dist/store/storeStore.d.ts +0 -69
  117. package/dist/translations/en.d.ts +0 -518
  118. package/dist/types/index.d.ts +0 -575
  119. package/dist/utils/index.d.ts +0 -67
  120. package/dist/utils/nativeBridge.d.ts +0 -2
@@ -1,11 +1,12 @@
1
1
  import { useStore as e } from "../providers/StoreProvider.js";
2
- import { useEffect as t, useState as n } from "react";
3
- import { ArrowLeft as r, Check as i, ChevronDown as a, ChevronUp as o, PackageCheck as s, RefreshCw as c, X as l } from "lucide-react";
4
- import { jsx as u, jsxs as d } from "react/jsx-runtime";
5
- import { useNavigate as f } from "react-router-dom";
6
- import { graphqlFetch as p } from "@burdenoff/fe-libs/shared/graphql";
2
+ import { formatPriceForModel as t } from "../utils/index.js";
3
+ import { useCallback as n, useEffect as r, useState as i } from "react";
4
+ import { ArrowLeft as a, Check as o, ChevronDown as s, ChevronUp as c, PackageCheck as l, RefreshCw as u, X as d } from "lucide-react";
5
+ import { jsx as f, jsxs as p } from "react/jsx-runtime";
6
+ import { useNavigate as m } from "react-router-dom";
7
+ import { graphqlFetch as h } from "@burdenoff/fe-libs/shared/graphql";
7
8
  //#region src/pages/AdminSubmissionsQueuePage.tsx
8
- var m = "\n query PendingReviewProducts($limit: Int, $offset: Int) {\n pendingReviewProducts(limit: $limit, offset: $offset) {\n totalCount\n products {\n id\n slug\n name\n type\n nature\n status\n pricingModel\n price\n currency\n description\n submittedAt\n submittedBy\n category\n icon\n publisher {\n id\n name\n email\n }\n }\n }\n }\n", h = "\n query AdminProducts($limit: Int, $offset: Int, $status: ProductStatus) {\n products(filter: { status: $status }, limit: $limit, offset: $offset) {\n id\n slug\n name\n type\n nature\n status\n pricingModel\n price\n currency\n description\n submittedAt\n submittedBy\n category\n icon\n publisher {\n id\n name\n email\n }\n }\n }\n", g = "\n mutation ApproveProduct($id: ID!, $notes: String) {\n approveProduct(id: $id, notes: $notes) {\n id\n status\n publishedAt\n }\n }\n", _ = "\n mutation RejectProduct($id: ID!, $reason: String!) {\n rejectProduct(id: $id, reason: $reason) {\n id\n status\n rejectedReason\n }\n }\n", v = [
9
+ var g = "\n query PendingReviewProducts($limit: Int, $offset: Int) {\n pendingReviewProducts(limit: $limit, offset: $offset) {\n totalCount\n products {\n id\n slug\n name\n type\n nature\n status\n pricingModel\n price\n currency\n description\n submittedAt\n submittedBy\n category\n icon\n publisher {\n id\n name\n email\n }\n }\n }\n }\n", _ = "\n query AdminProducts($limit: Int, $offset: Int, $status: ProductStatus) {\n products(filter: { status: $status }, limit: $limit, offset: $offset) {\n id\n slug\n name\n type\n nature\n status\n pricingModel\n price\n currency\n description\n submittedAt\n submittedBy\n category\n icon\n publisher {\n id\n name\n email\n }\n }\n }\n", v = "\n mutation ApproveProduct($id: ID!, $notes: String) {\n approveProduct(id: $id, notes: $notes) {\n id\n status\n publishedAt\n }\n }\n", y = "\n mutation RejectProduct($id: ID!, $reason: String!) {\n rejectProduct(id: $id, reason: $reason) {\n id\n status\n rejectedReason\n }\n }\n", b = [
9
10
  {
10
11
  label: "Pending review",
11
12
  value: "PENDING_REVIEW"
@@ -22,276 +23,272 @@ var m = "\n query PendingReviewProducts($limit: Int, $offset: Int) {\n pendi
22
23
  label: "All",
23
24
  value: "ALL"
24
25
  }
25
- ], y = () => {
26
- let y = f(), { authToken: b, basePath: x } = e(), [S, C] = n([]), [w, T] = n(0), [E, D] = n(!1), [O, k] = n(null), [A, j] = n(null), [M, N] = n("PENDING_REVIEW"), [P, F] = n(null), [I, L] = n(""), [R, z] = n(null), B = async (e) => {
27
- D(!0), k(null);
26
+ ], x = () => {
27
+ let x = m(), { authToken: S, basePath: C } = e(), [w, T] = i([]), [E, D] = i(0), [O, k] = i(!1), [A, j] = i(null), [M, N] = i(null), [P, F] = i("PENDING_REVIEW"), [I, L] = i(null), [R, z] = i(""), [B, V] = i(null), H = n(async (e) => {
28
+ k(!0), j(null);
28
29
  try {
29
30
  if (e === "PENDING_REVIEW") {
30
- let e = await p({
31
+ let e = await h({
31
32
  gateway: "global",
32
- query: m,
33
+ query: g,
33
34
  variables: {
34
35
  limit: 100,
35
36
  offset: 0
36
37
  },
37
- authToken: b || void 0
38
+ authToken: S || void 0
38
39
  });
39
40
  if (e.errors?.length) throw Error(e.errors[0]?.message ?? "Failed to load pending products");
40
- C(e.data?.pendingReviewProducts.products ?? []), T(e.data?.pendingReviewProducts.totalCount ?? 0);
41
+ T(e.data?.pendingReviewProducts.products ?? []), D(e.data?.pendingReviewProducts.totalCount ?? 0);
41
42
  } else {
42
- let t = await p({
43
+ let t = await h({
43
44
  gateway: "global",
44
- query: h,
45
+ query: _,
45
46
  variables: {
46
47
  limit: 100,
47
48
  offset: 0,
48
49
  ...e !== "ALL" && { status: e }
49
50
  },
50
- authToken: b || void 0
51
+ authToken: S || void 0
51
52
  });
52
53
  if (t.errors?.length) throw Error(t.errors[0]?.message ?? "Failed to load products");
53
54
  let n = t.data?.products ?? [];
54
- C(n), T(n.length);
55
+ T(n), D(n.length);
55
56
  }
56
57
  } catch (e) {
57
- k(e instanceof Error ? e.message : "Failed to load products");
58
+ j(e instanceof Error ? e.message : "Failed to load products");
58
59
  } finally {
59
- D(!1);
60
+ k(!1);
60
61
  }
61
- };
62
- t(() => {
63
- B(M);
64
- }, [M]);
65
- let V = async (e) => {
66
- j(e), k(null);
62
+ }, [S]);
63
+ r(() => {
64
+ H(P);
65
+ }, [H, P]);
66
+ let U = async (e) => {
67
+ N(e), j(null);
67
68
  try {
68
- let t = await p({
69
+ let t = await h({
69
70
  gateway: "global",
70
- query: g,
71
+ query: v,
71
72
  variables: {
72
73
  id: e,
73
74
  notes: null
74
75
  },
75
- authToken: b || void 0
76
+ authToken: S || void 0
76
77
  });
77
78
  if (t.errors?.length) throw Error(t.errors[0]?.message ?? "Approval failed");
78
- await B(M);
79
+ await H(P);
79
80
  } catch (e) {
80
- k(e instanceof Error ? e.message : "Approval failed");
81
+ j(e instanceof Error ? e.message : "Approval failed");
81
82
  } finally {
82
- j(null);
83
+ N(null);
83
84
  }
84
- }, H = async (e) => {
85
- if (!I.trim()) {
86
- k("Rejection reason is required");
85
+ }, W = async (e) => {
86
+ if (!R.trim()) {
87
+ j("Rejection reason is required");
87
88
  return;
88
89
  }
89
- j(e), k(null);
90
+ N(e), j(null);
90
91
  try {
91
- let t = await p({
92
+ let t = await h({
92
93
  gateway: "global",
93
- query: _,
94
+ query: y,
94
95
  variables: {
95
96
  id: e,
96
- reason: I.trim()
97
+ reason: R.trim()
97
98
  },
98
- authToken: b || void 0
99
+ authToken: S || void 0
99
100
  });
100
101
  if (t.errors?.length) throw Error(t.errors[0]?.message ?? "Rejection failed");
101
- F(null), L(""), await B(M);
102
+ L(null), z(""), await H(P);
102
103
  } catch (e) {
103
- k(e instanceof Error ? e.message : "Rejection failed");
104
+ j(e instanceof Error ? e.message : "Rejection failed");
104
105
  } finally {
105
- j(null);
106
+ N(null);
106
107
  }
107
- }, U = (e, t, n) => n === "FREE" ? "Free" : new Intl.NumberFormat(void 0, {
108
- style: "currency",
109
- currency: t || "USD"
110
- }).format(e);
111
- return /* @__PURE__ */ d("div", {
108
+ };
109
+ return /* @__PURE__ */ p("div", {
112
110
  className: "min-h-screen bg-surface-default",
113
- children: [/* @__PURE__ */ u("header", {
111
+ children: [/* @__PURE__ */ f("header", {
114
112
  className: "border-b border-border-default bg-surface-raised",
115
- children: /* @__PURE__ */ d("div", {
113
+ children: /* @__PURE__ */ p("div", {
116
114
  className: "mx-auto max-w-7xl px-6 py-4",
117
- children: [/* @__PURE__ */ d("div", {
115
+ children: [/* @__PURE__ */ p("div", {
118
116
  className: "flex items-center justify-between",
119
- children: [/* @__PURE__ */ d("div", {
117
+ children: [/* @__PURE__ */ p("div", {
120
118
  className: "flex items-center gap-3",
121
- children: [/* @__PURE__ */ d("button", {
119
+ children: [/* @__PURE__ */ p("button", {
122
120
  type: "button",
123
- onClick: () => y(`${x}/dashboard`),
121
+ onClick: () => x(`${C}/dashboard`),
124
122
  className: "inline-flex items-center gap-2 rounded-md px-3 py-1.5 text-sm text-text-secondary hover:bg-surface-hover hover:text-text-primary",
125
- children: [/* @__PURE__ */ u(r, { className: "h-4 w-4" }), "Back"]
126
- }), /* @__PURE__ */ d("div", {
123
+ children: [/* @__PURE__ */ f(a, { className: "size-4" }), "Back"]
124
+ }), /* @__PURE__ */ p("div", {
127
125
  className: "flex items-center gap-2",
128
126
  children: [
129
- /* @__PURE__ */ u(s, { className: "h-5 w-5 text-text-primary" }),
130
- /* @__PURE__ */ u("h1", {
127
+ /* @__PURE__ */ f(l, { className: "size-5 text-text-primary" }),
128
+ /* @__PURE__ */ f("h1", {
131
129
  className: "text-xl font-semibold text-text-primary",
132
130
  children: "Submission queue"
133
131
  }),
134
- /* @__PURE__ */ u("span", {
132
+ /* @__PURE__ */ f("span", {
135
133
  className: "rounded-full bg-surface-accent-muted px-2 py-0.5 text-xs font-medium text-text-accent",
136
- children: w
134
+ children: E
137
135
  })
138
136
  ]
139
137
  })]
140
- }), /* @__PURE__ */ d("button", {
138
+ }), /* @__PURE__ */ p("button", {
141
139
  type: "button",
142
- onClick: () => void B(M),
140
+ onClick: () => void H(P),
143
141
  className: "inline-flex items-center gap-2 rounded-md border border-border-default bg-surface-default px-3 py-1.5 text-sm text-text-primary hover:bg-surface-hover",
144
- disabled: E,
145
- children: [/* @__PURE__ */ u(c, { className: `h-4 w-4 ${E ? "animate-spin" : ""}` }), "Refresh"]
142
+ disabled: O,
143
+ children: [/* @__PURE__ */ f(u, { className: `size-4 ${O ? "animate-spin" : ""}` }), "Refresh"]
146
144
  })]
147
- }), /* @__PURE__ */ u("div", {
145
+ }), /* @__PURE__ */ f("div", {
148
146
  className: "mt-4 flex gap-2",
149
- children: v.map((e) => /* @__PURE__ */ u("button", {
147
+ children: b.map((e) => /* @__PURE__ */ f("button", {
150
148
  type: "button",
151
- onClick: () => N(e.value),
152
- className: `rounded-full px-3 py-1 text-xs font-medium transition-colors ${M === e.value ? "bg-surface-accent text-text-on-accent" : "bg-surface-muted text-text-secondary hover:bg-surface-hover"}`,
149
+ onClick: () => F(e.value),
150
+ className: `rounded-full px-3 py-1 text-xs font-medium transition-colors ${P === e.value ? "bg-surface-accent text-text-on-accent" : "bg-surface-muted text-text-secondary hover:bg-surface-hover"}`,
153
151
  children: e.label
154
152
  }, e.value))
155
153
  })]
156
154
  })
157
- }), /* @__PURE__ */ d("main", {
158
- className: "mx-auto max-w-7xl px-6 py-6",
159
- children: [O && /* @__PURE__ */ u("div", {
155
+ }), /* @__PURE__ */ p("main", {
156
+ className: "mx-auto max-w-7xl p-6",
157
+ children: [A && /* @__PURE__ */ f("div", {
160
158
  role: "alert",
161
159
  className: "mb-4 rounded-md border border-border-danger bg-surface-danger-muted px-4 py-3 text-sm text-text-danger",
162
- children: O
163
- }), E && S.length === 0 ? /* @__PURE__ */ u("div", {
164
- role: "status",
165
- className: "py-16 text-center text-text-secondary",
160
+ children: A
161
+ }), O && w.length === 0 ? /* @__PURE__ */ f("output", {
162
+ className: "block py-16 text-center text-text-secondary",
166
163
  children: "Loading submissions…"
167
- }) : S.length === 0 ? /* @__PURE__ */ u("div", {
164
+ }) : w.length === 0 ? /* @__PURE__ */ f("div", {
168
165
  className: "py-16 text-center text-text-secondary",
169
166
  children: "No products matching the current filter."
170
- }) : /* @__PURE__ */ u("ul", {
167
+ }) : /* @__PURE__ */ f("ul", {
171
168
  className: "space-y-3",
172
- children: S.map((e) => /* @__PURE__ */ d("li", {
169
+ children: w.map((e) => /* @__PURE__ */ p("li", {
173
170
  className: "overflow-hidden rounded-lg border border-border-default bg-surface-raised",
174
171
  children: [
175
- /* @__PURE__ */ d("div", {
172
+ /* @__PURE__ */ p("div", {
176
173
  className: "flex items-start gap-4 p-4",
177
174
  children: [
178
- e.icon ? /* @__PURE__ */ u("img", {
175
+ e.icon ? /* @__PURE__ */ f("img", {
179
176
  src: e.icon,
180
177
  alt: "",
181
- className: "h-14 w-14 flex-shrink-0 rounded-md object-cover"
182
- }) : /* @__PURE__ */ u("div", {
183
- className: "flex h-14 w-14 flex-shrink-0 items-center justify-center rounded-md bg-surface-muted text-xs text-text-secondary",
178
+ className: "size-14 flex-shrink-0 rounded-md object-cover"
179
+ }) : /* @__PURE__ */ f("div", {
180
+ className: "flex size-14 flex-shrink-0 items-center justify-center rounded-md bg-surface-muted text-xs text-text-secondary",
184
181
  children: e.type
185
182
  }),
186
- /* @__PURE__ */ d("div", {
183
+ /* @__PURE__ */ p("div", {
187
184
  className: "min-w-0 flex-1",
188
185
  children: [
189
- /* @__PURE__ */ d("div", {
186
+ /* @__PURE__ */ p("div", {
190
187
  className: "flex items-center gap-2",
191
188
  children: [
192
- /* @__PURE__ */ u("h3", {
189
+ /* @__PURE__ */ f("h3", {
193
190
  className: "truncate text-base font-semibold text-text-primary",
194
191
  children: e.name
195
192
  }),
196
- /* @__PURE__ */ u("span", {
193
+ /* @__PURE__ */ f("span", {
197
194
  className: "rounded-full bg-surface-accent-muted px-2 py-0.5 text-xs font-medium text-text-accent",
198
195
  children: e.type
199
196
  }),
200
- /* @__PURE__ */ u("span", {
197
+ /* @__PURE__ */ f("span", {
201
198
  className: "rounded-full bg-surface-muted px-2 py-0.5 text-xs font-medium text-text-secondary",
202
199
  children: e.nature
203
200
  })
204
201
  ]
205
202
  }),
206
- /* @__PURE__ */ u("div", {
203
+ /* @__PURE__ */ f("div", {
207
204
  className: "mt-0.5 text-xs text-text-tertiary",
208
205
  children: e.slug
209
206
  }),
210
- /* @__PURE__ */ d("div", {
207
+ /* @__PURE__ */ p("div", {
211
208
  className: "mt-1 flex items-center gap-3 text-xs text-text-secondary",
212
209
  children: [
213
- /* @__PURE__ */ d("span", { children: ["Publisher: ", e.publisher?.name ?? "Unknown"] }),
214
- /* @__PURE__ */ d("span", { children: ["Price: ", U(e.price, e.currency, e.pricingModel)] }),
215
- e.submittedAt && /* @__PURE__ */ d("span", { children: ["Submitted ", new Date(e.submittedAt).toLocaleString()] })
210
+ /* @__PURE__ */ p("span", { children: ["Publisher: ", e.publisher?.name ?? "Unknown"] }),
211
+ /* @__PURE__ */ p("span", { children: ["Price: ", t(e.price, e.currency, e.pricingModel)] }),
212
+ e.submittedAt && /* @__PURE__ */ p("span", { children: ["Submitted ", new Date(e.submittedAt).toLocaleString()] })
216
213
  ]
217
214
  }),
218
- e.description && /* @__PURE__ */ u("p", {
215
+ e.description && /* @__PURE__ */ f("p", {
219
216
  className: "mt-2 line-clamp-2 text-sm text-text-secondary",
220
217
  children: e.description
221
218
  })
222
219
  ]
223
220
  }),
224
- /* @__PURE__ */ d("div", {
221
+ /* @__PURE__ */ p("div", {
225
222
  className: "flex flex-shrink-0 flex-col gap-2",
226
223
  children: [
227
- /* @__PURE__ */ d("button", {
224
+ /* @__PURE__ */ p("button", {
228
225
  type: "button",
229
- onClick: () => z(R === e.id ? null : e.id),
226
+ onClick: () => V(B === e.id ? null : e.id),
230
227
  className: "inline-flex items-center gap-1 rounded-md border border-border-default px-3 py-1.5 text-xs text-text-secondary hover:bg-surface-hover",
231
- children: [R === e.id ? /* @__PURE__ */ u(o, { className: "h-3.5 w-3.5" }) : /* @__PURE__ */ u(a, { className: "h-3.5 w-3.5" }), "Details"]
228
+ children: [B === e.id ? /* @__PURE__ */ f(c, { className: "size-3.5" }) : /* @__PURE__ */ f(s, { className: "size-3.5" }), "Details"]
232
229
  }),
233
- /* @__PURE__ */ d("button", {
230
+ /* @__PURE__ */ p("button", {
234
231
  type: "button",
235
- onClick: () => void V(e.id),
236
- disabled: A === e.id,
232
+ onClick: () => void U(e.id),
233
+ disabled: M === e.id,
237
234
  className: "inline-flex items-center gap-1 rounded-md bg-surface-success px-3 py-1.5 text-xs font-medium text-text-on-success hover:bg-surface-success-hover disabled:opacity-60",
238
- children: [/* @__PURE__ */ u(i, { className: "h-3.5 w-3.5" }), "Approve"]
235
+ children: [/* @__PURE__ */ f(o, { className: "size-3.5" }), "Approve"]
239
236
  }),
240
- /* @__PURE__ */ d("button", {
237
+ /* @__PURE__ */ p("button", {
241
238
  type: "button",
242
239
  onClick: () => {
243
- F(e.id), L("");
240
+ L(e.id), z("");
244
241
  },
245
- disabled: A === e.id,
242
+ disabled: M === e.id,
246
243
  className: "inline-flex items-center gap-1 rounded-md border border-border-danger bg-surface-danger-muted px-3 py-1.5 text-xs font-medium text-text-danger hover:bg-surface-danger hover:text-text-on-danger disabled:opacity-60",
247
- children: [/* @__PURE__ */ u(l, { className: "h-3.5 w-3.5" }), "Reject"]
244
+ children: [/* @__PURE__ */ f(d, { className: "size-3.5" }), "Reject"]
248
245
  })
249
246
  ]
250
247
  })
251
248
  ]
252
249
  }),
253
- R === e.id && /* @__PURE__ */ u("div", {
254
- className: "border-t border-border-default bg-surface-muted px-4 py-4",
255
- children: /* @__PURE__ */ d("dl", {
250
+ B === e.id && /* @__PURE__ */ f("div", {
251
+ className: "border-t border-border-default bg-surface-muted p-4",
252
+ children: /* @__PURE__ */ p("dl", {
256
253
  className: "grid grid-cols-2 gap-x-6 gap-y-3 text-xs sm:grid-cols-3",
257
254
  children: [
258
- /* @__PURE__ */ d("div", { children: [/* @__PURE__ */ u("dt", {
255
+ /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("dt", {
259
256
  className: "font-medium text-text-secondary",
260
257
  children: "Slug"
261
- }), /* @__PURE__ */ u("dd", {
258
+ }), /* @__PURE__ */ f("dd", {
262
259
  className: "mt-0.5 font-mono text-text-primary",
263
260
  children: e.slug
264
261
  })] }),
265
- /* @__PURE__ */ d("div", { children: [/* @__PURE__ */ u("dt", {
262
+ /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("dt", {
266
263
  className: "font-medium text-text-secondary",
267
264
  children: "Type"
268
- }), /* @__PURE__ */ u("dd", {
265
+ }), /* @__PURE__ */ f("dd", {
269
266
  className: "mt-0.5 text-text-primary",
270
267
  children: e.type
271
268
  })] }),
272
- /* @__PURE__ */ d("div", { children: [/* @__PURE__ */ u("dt", {
269
+ /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("dt", {
273
270
  className: "font-medium text-text-secondary",
274
271
  children: "Nature"
275
- }), /* @__PURE__ */ u("dd", {
272
+ }), /* @__PURE__ */ f("dd", {
276
273
  className: "mt-0.5 text-text-primary",
277
274
  children: e.nature
278
275
  })] }),
279
- e.category && /* @__PURE__ */ d("div", { children: [/* @__PURE__ */ u("dt", {
276
+ e.category && /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("dt", {
280
277
  className: "font-medium text-text-secondary",
281
278
  children: "Category"
282
- }), /* @__PURE__ */ u("dd", {
279
+ }), /* @__PURE__ */ f("dd", {
283
280
  className: "mt-0.5 text-text-primary",
284
281
  children: e.category
285
282
  })] }),
286
- /* @__PURE__ */ d("div", { children: [/* @__PURE__ */ u("dt", {
283
+ /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("dt", {
287
284
  className: "font-medium text-text-secondary",
288
285
  children: "Pricing"
289
- }), /* @__PURE__ */ d("dd", {
286
+ }), /* @__PURE__ */ p("dd", {
290
287
  className: "mt-0.5 text-text-primary",
291
288
  children: [
292
- U(e.price, e.currency, e.pricingModel),
289
+ t(e.price, e.currency, e.pricingModel),
293
290
  " ",
294
- /* @__PURE__ */ d("span", {
291
+ /* @__PURE__ */ p("span", {
295
292
  className: "text-text-tertiary",
296
293
  children: [
297
294
  "(",
@@ -301,36 +298,36 @@ var m = "\n query PendingReviewProducts($limit: Int, $offset: Int) {\n pendi
301
298
  })
302
299
  ]
303
300
  })] }),
304
- /* @__PURE__ */ d("div", { children: [/* @__PURE__ */ u("dt", {
301
+ /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("dt", {
305
302
  className: "font-medium text-text-secondary",
306
303
  children: "Publisher"
307
- }), /* @__PURE__ */ d("dd", {
304
+ }), /* @__PURE__ */ p("dd", {
308
305
  className: "mt-0.5 text-text-primary",
309
- children: [e.publisher?.name ?? "—", e.publisher?.email && /* @__PURE__ */ u("span", {
306
+ children: [e.publisher?.name ?? "—", e.publisher?.email && /* @__PURE__ */ f("span", {
310
307
  className: "block text-text-tertiary",
311
308
  children: e.publisher.email
312
309
  })]
313
310
  })] }),
314
- e.submittedBy && /* @__PURE__ */ d("div", { children: [/* @__PURE__ */ u("dt", {
311
+ e.submittedBy && /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("dt", {
315
312
  className: "font-medium text-text-secondary",
316
313
  children: "Submitted by"
317
- }), /* @__PURE__ */ u("dd", {
314
+ }), /* @__PURE__ */ f("dd", {
318
315
  className: "mt-0.5 font-mono text-text-primary",
319
316
  children: e.submittedBy
320
317
  })] }),
321
- e.submittedAt && /* @__PURE__ */ d("div", { children: [/* @__PURE__ */ u("dt", {
318
+ e.submittedAt && /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("dt", {
322
319
  className: "font-medium text-text-secondary",
323
320
  children: "Submitted at"
324
- }), /* @__PURE__ */ u("dd", {
321
+ }), /* @__PURE__ */ f("dd", {
325
322
  className: "mt-0.5 text-text-primary",
326
323
  children: new Date(e.submittedAt).toLocaleString()
327
324
  })] }),
328
- e.description && /* @__PURE__ */ d("div", {
325
+ e.description && /* @__PURE__ */ p("div", {
329
326
  className: "col-span-2 sm:col-span-3",
330
- children: [/* @__PURE__ */ u("dt", {
327
+ children: [/* @__PURE__ */ f("dt", {
331
328
  className: "font-medium text-text-secondary",
332
329
  children: "Description"
333
- }), /* @__PURE__ */ u("dd", {
330
+ }), /* @__PURE__ */ f("dd", {
334
331
  className: "mt-0.5 whitespace-pre-wrap text-text-primary",
335
332
  children: e.description
336
333
  })]
@@ -338,37 +335,38 @@ var m = "\n query PendingReviewProducts($limit: Int, $offset: Int) {\n pendi
338
335
  ]
339
336
  })
340
337
  }),
341
- P === e.id && /* @__PURE__ */ d("div", {
338
+ I === e.id && /* @__PURE__ */ p("div", {
342
339
  className: "border-t border-border-default bg-surface-muted px-4 py-3",
343
340
  children: [
344
- /* @__PURE__ */ u("label", {
341
+ /* @__PURE__ */ f("label", {
345
342
  htmlFor: `reject-reason-${e.id}`,
346
343
  className: "block text-xs font-medium text-text-secondary",
347
344
  children: "Rejection reason (required)"
348
345
  }),
349
- /* @__PURE__ */ u("textarea", {
346
+ /* @__PURE__ */ f("textarea", {
350
347
  id: `reject-reason-${e.id}`,
351
- value: I,
352
- onChange: (e) => L(e.target.value),
348
+ "aria-label": "Rejection reason",
349
+ value: R,
350
+ onChange: (e) => z(e.target.value),
353
351
  rows: 3,
354
352
  required: !0,
355
353
  "aria-required": "true",
356
354
  className: "mt-1 w-full rounded-md border border-border-default bg-surface-default px-3 py-2 text-sm text-text-primary focus:border-border-accent focus:outline-none",
357
355
  placeholder: "Explain why this submission is being rejected…"
358
356
  }),
359
- /* @__PURE__ */ d("div", {
357
+ /* @__PURE__ */ p("div", {
360
358
  className: "mt-2 flex justify-end gap-2",
361
- children: [/* @__PURE__ */ u("button", {
359
+ children: [/* @__PURE__ */ f("button", {
362
360
  type: "button",
363
361
  onClick: () => {
364
- F(null), L("");
362
+ L(null), z("");
365
363
  },
366
364
  className: "rounded-md border border-border-default bg-surface-default px-3 py-1 text-xs text-text-primary hover:bg-surface-hover",
367
365
  children: "Cancel"
368
- }), /* @__PURE__ */ u("button", {
366
+ }), /* @__PURE__ */ f("button", {
369
367
  type: "button",
370
- onClick: () => void H(e.id),
371
- disabled: !I.trim() || A === e.id,
368
+ onClick: () => void W(e.id),
369
+ disabled: !R.trim() || M === e.id,
372
370
  className: "rounded-md bg-surface-danger px-3 py-1 text-xs font-medium text-text-on-danger hover:bg-surface-danger-hover disabled:opacity-60",
373
371
  children: "Submit rejection"
374
372
  })]
@@ -382,6 +380,6 @@ var m = "\n query PendingReviewProducts($limit: Int, $offset: Int) {\n pendi
382
380
  });
383
381
  };
384
382
  //#endregion
385
- export { y as AdminSubmissionsQueuePage };
383
+ export { x as AdminSubmissionsQueuePage };
386
384
 
387
385
  //# sourceMappingURL=AdminSubmissionsQueuePage.js.map