@burdenoff/microfe-store 2026.1028.1 → 2026.1102.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 (31) hide show
  1. package/dist/StoreAdminRoutes.js +22 -12
  2. package/dist/StoreAdminRoutes.js.map +1 -1
  3. package/dist/StoreRoot.js +47 -36
  4. package/dist/StoreRoot.js.map +1 -1
  5. package/dist/StoreRoutes.js +72 -59
  6. package/dist/StoreRoutes.js.map +1 -1
  7. package/dist/components/TemplateRevisionsQueue.d.ts +10 -0
  8. package/dist/components/TemplateRevisionsQueue.js +300 -0
  9. package/dist/components/TemplateRevisionsQueue.js.map +1 -0
  10. package/dist/components/WorkflowTemplatePreviewPanel.d.ts +50 -0
  11. package/dist/components/WorkflowTemplatePreviewPanel.js +221 -0
  12. package/dist/components/WorkflowTemplatePreviewPanel.js.map +1 -0
  13. package/dist/components/governance/ReportListingCard.d.ts +11 -0
  14. package/dist/components/governance/ReportListingCard.js +100 -0
  15. package/dist/components/governance/ReportListingCard.js.map +1 -0
  16. package/dist/pages/AdminDashboardPage.js +48 -27
  17. package/dist/pages/AdminDashboardPage.js.map +1 -1
  18. package/dist/pages/AdminGovernancePage.d.ts +3 -0
  19. package/dist/pages/AdminGovernancePage.js +883 -0
  20. package/dist/pages/AdminGovernancePage.js.map +1 -0
  21. package/dist/pages/AdminSubmissionsQueuePage.js +468 -335
  22. package/dist/pages/AdminSubmissionsQueuePage.js.map +1 -1
  23. package/dist/pages/ProductDetailPage.js +220 -215
  24. package/dist/pages/ProductDetailPage.js.map +1 -1
  25. package/dist/pages/PublisherGovernancePage.d.ts +3 -0
  26. package/dist/pages/PublisherGovernancePage.js +230 -0
  27. package/dist/pages/PublisherGovernancePage.js.map +1 -0
  28. package/dist/utils/governance.d.ts +158 -0
  29. package/dist/utils/governance.js +129 -0
  30. package/dist/utils/governance.js.map +1 -0
  31. package/package.json +1 -1
@@ -8,14 +8,15 @@ import { InstallAppModal as oe } from "../components/InstallAppModal.js";
8
8
  import { useInstallations as se } from "../hooks/useInstallations.js";
9
9
  import { getExternalListing as ce, isSoldExternally as le } from "../utils/externalListing.js";
10
10
  import { nativeConfirm as ue, nativeImpact as de, nativeNotify as fe } from "../utils/nativeBridge.js";
11
- import { useCallback as a, useEffect as pe, useMemo as me, useRef as he, useState as o } from "react";
12
- import { useLocation as ge, useNavigate as _e, useParams as ve } from "react-router";
13
- import { AlertCircle as s, ArrowLeft as ye, Check as be, ExternalLink as xe, Loader2 as Se, Package as c, ShieldCheck as l, ShoppingCart as Ce, Star as u, ThumbsUp as d } from "lucide-react";
11
+ import { ReportListingCard as pe } from "../components/governance/ReportListingCard.js";
12
+ import { useCallback as a, useEffect as me, useMemo as he, useRef as ge, useState as o } from "react";
13
+ import { useLocation as _e, useNavigate as ve, useParams as ye } from "react-router";
14
+ import { AlertCircle as s, ArrowLeft as be, Check as xe, ExternalLink as Se, Loader2 as Ce, Package as c, ShieldCheck as l, ShoppingCart as we, Star as u, ThumbsUp as d } from "lucide-react";
14
15
  import { Fragment as f, jsx as p, jsxs as m } from "react/jsx-runtime";
15
- import { EmphasisPanel as we, GlassCard as h, IllustratedEmptyState as Te, NextSteps as Ee, PagePurpose as De } from "@burdenoff/fe-libs/ui";
16
- import { useEventBus as Oe } from "@burdenoff/fe-libs/shared/events";
16
+ import { EmphasisPanel as Te, GlassCard as h, IllustratedEmptyState as Ee, NextSteps as De, PagePurpose as Oe } from "@burdenoff/fe-libs/ui";
17
+ import { useEventBus as ke } from "@burdenoff/fe-libs/shared/events";
17
18
  //#region src/pages/ProductDetailPage.tsx
18
- var ke = (e, t, n) => ({
19
+ var Ae = (e, t, n) => ({
19
20
  id: e.id,
20
21
  publisherId: t?.id || "",
21
22
  publisher: {
@@ -90,7 +91,7 @@ var ke = (e, t, n) => ({
90
91
  createdAt: e.createdAt,
91
92
  updatedAt: e.updatedAt,
92
93
  publishedAt: e.publishedAt
93
- }), Ae = ({ stars: e, percentage: t, count: r }) => /* @__PURE__ */ m("div", {
94
+ }), je = ({ stars: e, percentage: t, count: r }) => /* @__PURE__ */ m("div", {
94
95
  className: "flex items-center gap-2",
95
96
  children: [
96
97
  /* @__PURE__ */ p("span", {
@@ -109,7 +110,7 @@ var ke = (e, t, n) => ({
109
110
  children: n(r)
110
111
  })
111
112
  ]
112
- }), je = ({ review: e, onMarkHelpful: t, markingHelpful: n }) => {
113
+ }), Me = ({ review: e, onMarkHelpful: t, markingHelpful: n }) => {
113
114
  let r = ae();
114
115
  return /* @__PURE__ */ m("div", {
115
116
  className: "rounded-lg border border-border-seam bg-bg-surface p-4 transition-[box-shadow,border-color] hover:border-border-strong hover:shadow-[var(--shadow-pop)]",
@@ -173,7 +174,7 @@ var ke = (e, t, n) => ({
173
174
  })
174
175
  ]
175
176
  });
176
- }, Me = () => /* @__PURE__ */ m("div", {
177
+ }, Ne = () => /* @__PURE__ */ m("div", {
177
178
  className: "h-full overflow-y-auto",
178
179
  children: [/* @__PURE__ */ p("div", {
179
180
  className: "sticky top-0 z-10 border-b border-border-default bg-bg-surface px-6 py-4",
@@ -427,7 +428,7 @@ var ke = (e, t, n) => ({
427
428
  })
428
429
  ]
429
430
  })]
430
- }), Ne = ({ error: e, onRetry: t, onBack: n }) => {
431
+ }), Pe = ({ error: e, onRetry: t, onBack: n }) => {
431
432
  let r = ae();
432
433
  return /* @__PURE__ */ p("div", {
433
434
  className: "flex h-full items-center justify-center",
@@ -460,14 +461,14 @@ var ke = (e, t, n) => ({
460
461
  ]
461
462
  })
462
463
  });
463
- }, Pe = () => {
464
- let { productId: s } = ve(), d = _e(), Pe = ge(), { basePath: g, workspaceId: _ } = e(), v = ae(), { addProduct: Fe, cartItems: Ie, addingToCart: Le, createOrder: Re, checkingOut: ze } = t(), { installations: Be, refetch: Ve } = se({
465
- filter: me(() => s && _ ? {
464
+ }, g = () => {
465
+ let { productId: s } = ye(), d = ve(), g = _e(), { basePath: _, workspaceId: v } = e(), y = ae(), { addProduct: Fe, cartItems: Ie, addingToCart: Le, createOrder: Re, checkingOut: ze } = t(), { installations: Be, refetch: Ve } = se({
466
+ filter: he(() => s && v ? {
466
467
  productId: s,
467
- workspaceId: _
468
- } : void 0, [s, _]),
468
+ workspaceId: v
469
+ } : void 0, [s, v]),
469
470
  limit: 1
470
- }), He = Be.find((e) => e.productId === s && e.workspaceId === _ && e.status === "ACTIVE"), y = !!He, b = He?.version ?? null, { createReview: Ue, loading: We } = i(), { updateReview: Ge, loading: Ke } = re(), { deleteReview: qe, loading: Je } = ee(), { markHelpful: Ye, loading: Xe } = te(), x = Oe(), [Ze, Qe] = o(!1), [$e, et] = o(!1), [tt, nt] = o(!1), [S, rt] = o(1), [it, C] = o(null), [at, w] = o(null), [ot, T] = o("success"), [E, D] = o(!1), [O, k] = o(""), [A, j] = o(""), [M, N] = o(5), [st, ct] = o(null), [lt, ut] = o(!1), { data: dt, loading: ft, error: pt, refetch: P } = ne({
471
+ }), He = Be.find((e) => e.productId === s && e.workspaceId === v && e.status === "ACTIVE"), b = !!He, x = He?.version ?? null, { createReview: Ue, loading: We } = i(), { updateReview: Ge, loading: Ke } = re(), { deleteReview: qe, loading: Je } = ee(), { markHelpful: Ye, loading: Xe } = te(), S = ke(), [Ze, Qe] = o(!1), [C, $e] = o(!1), [et, w] = o(!1), [T, tt] = o(1), [nt, E] = o(null), [rt, D] = o(null), [it, O] = o("success"), [k, A] = o(!1), [j, M] = o(""), [at, ot] = o(""), [N, st] = o(5), [ct, lt] = o(null), [ut, dt] = o(!1), { data: ft, loading: pt, error: mt, refetch: P } = ne({
471
472
  id: s,
472
473
  slug: s,
473
474
  includeReviews: !0,
@@ -475,20 +476,20 @@ var ke = (e, t, n) => ({
475
476
  includeRelated: !0,
476
477
  relatedLimit: 4,
477
478
  includeVersions: !0
478
- }), F = dt, I = F?.product, L = F?.publisher, R = Ie.some((e) => e.productId === I?.id), mt = (e) => {
479
+ }), F = ft, I = F?.product, L = F?.publisher, R = Ie.some((e) => e.productId === I?.id), ht = (e) => {
479
480
  let t = e.split(".");
480
481
  for (; t.length < 3;) t.push("0");
481
482
  return t.join(".");
482
- }, ht = I?.manifestVersion ?? null, gt = !!(y && b && ht && mt(b) !== mt(ht)), _t = a(async () => {
483
+ }, gt = I?.manifestVersion ?? null, _t = !!(b && x && gt && ht(x) !== ht(gt)), vt = a(async () => {
483
484
  if (I) {
484
- if (C(null), R) {
485
- d(`${g}/cart`);
485
+ if (E(null), R) {
486
+ d(`${_}/cart`);
486
487
  return;
487
488
  }
488
489
  try {
489
- await Fe(ke(I, L, v), void 0, S);
490
+ await Fe(Ae(I, L, y), void 0, T);
490
491
  } catch (e) {
491
- console.error("Failed to add product to cart:", e), C(v("pages.productDetail.addToCartError", "Failed to add this product to cart. Please try again."));
492
+ console.error("Failed to add product to cart:", e), E(y("pages.productDetail.addToCartError", "Failed to add this product to cart. Please try again."));
492
493
  }
493
494
  }
494
495
  }, [
@@ -497,76 +498,76 @@ var ke = (e, t, n) => ({
497
498
  Fe,
498
499
  R,
499
500
  d,
500
- g,
501
- S,
502
- v
503
- ]), vt = a(async () => {
501
+ _,
502
+ T,
503
+ y
504
+ ]), yt = a(async () => {
504
505
  if (I) {
505
- C(null), nt(!0);
506
+ E(null), w(!0);
506
507
  try {
507
508
  let e = I.price || 0, t = {
508
509
  productId: I.id,
509
510
  name: I.name,
510
- quantity: S,
511
+ quantity: T,
511
512
  unitPrice: e,
512
- subtotal: e * S,
513
+ subtotal: e * T,
513
514
  itemType: I.nature?.toLowerCase() || "digital",
514
515
  pricingModel: I.pricingModel || "PAID_ONETIME"
515
516
  }, n = await Re({
516
- total: e * S,
517
+ total: e * T,
517
518
  lineItems: [t],
518
519
  billingAccountId: ""
519
520
  });
520
- n?.id ? d(`/billing/checkout/store/${n.id}${Pe.search}`) : (console.error("Failed to create order"), C(v("pages.productDetail.createOrderError", "Failed to create order. Please try again.")), nt(!1));
521
+ n?.id ? d(`/billing/checkout/store/${n.id}${g.search}`) : (console.error("Failed to create order"), E(y("pages.productDetail.createOrderError", "Failed to create order. Please try again.")), w(!1));
521
522
  } catch (e) {
522
- console.error("Buy Now error:", e), C(e instanceof Error ? e.message : v("pages.productDetail.checkoutError", "Failed to start checkout")), nt(!1);
523
+ console.error("Buy Now error:", e), E(e instanceof Error ? e.message : y("pages.productDetail.checkoutError", "Failed to start checkout")), w(!1);
523
524
  }
524
525
  }
525
526
  }, [
526
527
  I,
527
- S,
528
+ T,
528
529
  Re,
529
530
  d,
530
- Pe.search,
531
- v
531
+ g.search,
532
+ y
532
533
  ]), z = a(() => {
533
- I && ut(!0);
534
- }, [I]), yt = he(I);
535
- yt.current = I;
536
- let bt = he(x);
537
- bt.current = x, pe(() => {
538
- let e = yt.current;
539
- e && bt.current.emit("store.product.viewed", {
534
+ I && dt(!0);
535
+ }, [I]), bt = ge(I);
536
+ bt.current = I;
537
+ let xt = ge(S);
538
+ xt.current = S, me(() => {
539
+ let e = bt.current;
540
+ e && xt.current.emit("store.product.viewed", {
540
541
  productId: e.id,
541
542
  productSlug: e.slug,
542
543
  productType: e.type,
543
544
  pricingModel: e.pricingModel
544
545
  });
545
546
  }, [I?.id]);
546
- let xt = a((e, t) => {
547
- I && (x.emit("store.product.installed", {
547
+ let St = a((e, t) => {
548
+ I && (S.emit("store.product.installed", {
548
549
  productId: I.id,
549
550
  workspaceId: e
550
551
  }), console.log(`Successfully installed ${I.name} to workspace ${t} (${e})`), Ve());
551
552
  }, [
552
553
  I,
553
- x,
554
+ S,
554
555
  Ve
555
- ]), St = a((e) => {
556
+ ]), Ct = a((e) => {
556
557
  console.error("Installation failed:", e.message);
557
- }, []), Ct = a(() => {
558
- k(F?.userReview?.title ?? ""), j(F?.userReview?.comment ?? ""), N(F?.userReview?.rating ?? 5), w(null), T("success"), D(!0);
559
- }, [F?.userReview]), wt = a(async () => {
558
+ }, []), wt = a(() => {
559
+ M(F?.userReview?.title ?? ""), ot(F?.userReview?.comment ?? ""), st(F?.userReview?.rating ?? 5), D(null), O("success"), A(!0);
560
+ }, [F?.userReview]), Tt = a(async () => {
560
561
  if (!I) return;
561
- if (M < 1 || M > 5) {
562
- T("error"), w(v("pages.productDetail.ratingRequired", "Choose a rating from 1 to 5 stars."));
562
+ if (N < 1 || N > 5) {
563
+ O("error"), D(y("pages.productDetail.ratingRequired", "Choose a rating from 1 to 5 stars."));
563
564
  return;
564
565
  }
565
566
  let e = {
566
567
  productId: I.id,
567
- rating: M,
568
- title: O.trim() || void 0,
569
- comment: A.trim() || void 0
568
+ rating: N,
569
+ title: j.trim() || void 0,
570
+ comment: at.trim() || void 0
570
571
  }, t = F?.userReview ? {
571
572
  data: await Ge(F.userReview.id, {
572
573
  rating: e.rating,
@@ -576,66 +577,66 @@ var ke = (e, t, n) => ({
576
577
  errorMessage: null
577
578
  } : await Ue(e);
578
579
  if (!t?.data) {
579
- T("error"), w(t?.errorMessage ?? v("pages.productDetail.reviewSaveError", "We could not save your review. Please try again."));
580
+ O("error"), D(t?.errorMessage ?? y("pages.productDetail.reviewSaveError", "We could not save your review. Please try again."));
580
581
  return;
581
582
  }
582
- T("success"), w(F?.userReview ? v("pages.productDetail.reviewUpdated", "Your review was updated.") : v("pages.productDetail.reviewSubmitted", "Your review was submitted.")), D(!1), x.emit("store.review.submitted", {
583
+ O("success"), D(F?.userReview ? y("pages.productDetail.reviewUpdated", "Your review was updated.") : y("pages.productDetail.reviewSubmitted", "Your review was submitted.")), A(!1), S.emit("store.review.submitted", {
583
584
  productId: I.id,
584
- rating: M
585
+ rating: N
585
586
  }), await P();
586
587
  }, [
587
- x,
588
+ S,
588
589
  Ue,
589
590
  I,
590
591
  F?.userReview,
591
592
  P,
592
- A,
593
- M,
594
- O,
593
+ at,
594
+ N,
595
+ j,
595
596
  Ge,
596
- v
597
- ]), Tt = a(async () => {
597
+ y
598
+ ]), Et = a(async () => {
598
599
  if (F?.userReview && (de("medium"), await ue({
599
- title: v("pages.productDetail.deleteReviewTitle", "Delete review"),
600
- message: v("pages.productDetail.deleteReviewMessage", "Are you sure you want to remove your review?"),
601
- okButtonTitle: v("common.delete", "Delete"),
602
- cancelButtonTitle: v("common.cancel", "Cancel")
600
+ title: y("pages.productDetail.deleteReviewTitle", "Delete review"),
601
+ message: y("pages.productDetail.deleteReviewMessage", "Are you sure you want to remove your review?"),
602
+ okButtonTitle: y("common.delete", "Delete"),
603
+ cancelButtonTitle: y("common.cancel", "Cancel")
603
604
  }) !== !1)) {
604
605
  if (!await qe(F.userReview.id)) {
605
- T("error"), w(v("pages.productDetail.reviewDeleteError", "We could not remove your review. Please try again.")), fe("error");
606
+ O("error"), D(y("pages.productDetail.reviewDeleteError", "We could not remove your review. Please try again.")), fe("error");
606
607
  return;
607
608
  }
608
- T("success"), w(v("pages.productDetail.reviewRemoved", "Your review was removed.")), D(!1), k(""), j(""), N(5), fe("success"), await P();
609
+ O("success"), D(y("pages.productDetail.reviewRemoved", "Your review was removed.")), A(!1), M(""), ot(""), st(5), fe("success"), await P();
609
610
  }
610
611
  }, [
611
612
  qe,
612
613
  F?.userReview,
613
614
  P,
614
- v
615
- ]), Et = a(async (e) => {
616
- ct(e), await Ye(e) && await P(), ct(null);
615
+ y
616
+ ]), Dt = a(async (e) => {
617
+ lt(e), await Ye(e) && await P(), lt(null);
617
618
  }, [Ye, P]);
618
- if (ft) return /* @__PURE__ */ p(Me, {});
619
- if (pt) return /* @__PURE__ */ p(Ne, {
620
- error: pt,
619
+ if (pt) return /* @__PURE__ */ p(Ne, {});
620
+ if (mt) return /* @__PURE__ */ p(Pe, {
621
+ error: mt,
621
622
  onRetry: P,
622
- onBack: () => d(`${g}/marketplace`)
623
+ onBack: () => d(`${_}/marketplace`)
623
624
  });
624
625
  if (!F?.product) return /* @__PURE__ */ p("div", {
625
626
  className: "flex h-full items-center justify-center p-6",
626
- children: /* @__PURE__ */ p(Te, {
627
+ children: /* @__PURE__ */ p(Ee, {
627
628
  illustration: "empty-search",
628
- title: v("pages.productDetail.notFoundTitle", "Product not found"),
629
- description: v("pages.productDetail.notFoundDetail", "The product you are looking for does not exist or has been removed."),
629
+ title: y("pages.productDetail.notFoundTitle", "Product not found"),
630
+ description: y("pages.productDetail.notFoundDetail", "The product you are looking for does not exist or has been removed."),
630
631
  action: /* @__PURE__ */ p("button", {
631
632
  type: "button",
632
- onClick: () => d(`${g}/marketplace`),
633
+ onClick: () => d(`${_}/marketplace`),
633
634
  className: "rounded-lg bg-action-primary-bg px-4 py-2 text-action-primary-text transition-opacity hover:opacity-90",
634
- children: v("pages.productDetail.backToMarketplace", "Back to Marketplace")
635
+ children: y("pages.productDetail.backToMarketplace", "Back to Marketplace")
635
636
  })
636
637
  })
637
638
  });
638
- let { reviews: B, reviewsCount: Dt, relatedProducts: Ot, ratingDistribution: V, isPurchased: H, userEntitlement: U } = F, W = I, G = V ? V.fiveStars + V.fourStars + V.threeStars + V.twoStars + V.oneStar : 0, kt = V ? [
639
+ let { reviews: B, reviewsCount: Ot, relatedProducts: kt, ratingDistribution: V, isPurchased: H, userEntitlement: U } = F, W = I, G = V ? V.fiveStars + V.fourStars + V.threeStars + V.twoStars + V.oneStar : 0, At = V ? [
639
640
  {
640
641
  stars: 5,
641
642
  count: V.fiveStars,
@@ -661,8 +662,8 @@ var ke = (e, t, n) => ({
661
662
  count: V.oneStar,
662
663
  percentage: G > 0 ? V.oneStar / G * 100 : 0
663
664
  }
664
- ] : [], K = W.requiredPermissions || [], At = W.integrationDeps || [], jt = () => W.pricingModel === "FREE" ? v("pages.marketplace.free", "Free") : W.pricingModel === "SUBSCRIPTION" ? v("pages.productDetail.subscriptionPrice", "{{price}}/mo", { price: r(W.price, W.currency) }) : r(W.price, W.currency), q = W.pricingModel === "FREE" || W.price === 0, J = W.nature === "PHYSICAL", Y = J && W.trackInventory === !0, X = W.stockQuantity ?? 0, Z = Y && X <= 0, Q = le(W), $ = ce(W), Mt = $ !== null && new URL($.url).origin === window.location.origin, Nt = () => {
665
- $ && (Mt ? window.location.assign($.url) : window.open($.url, "_blank", "noopener,noreferrer"));
665
+ ] : [], K = W.requiredPermissions || [], jt = W.integrationDeps || [], Mt = () => W.pricingModel === "FREE" ? y("pages.marketplace.free", "Free") : W.pricingModel === "SUBSCRIPTION" ? y("pages.productDetail.subscriptionPrice", "{{price}}/mo", { price: r(W.price, W.currency) }) : r(W.price, W.currency), q = W.pricingModel === "FREE" || W.price === 0, J = W.nature === "PHYSICAL", Y = J && W.trackInventory === !0, X = W.stockQuantity ?? 0, Z = Y && X <= 0, Q = le(W), $ = ce(W), Nt = $ !== null && new URL($.url).origin === window.location.origin, Pt = () => {
666
+ $ && (Nt ? window.location.assign($.url) : window.open($.url, "_blank", "noopener,noreferrer"));
666
667
  };
667
668
  return /* @__PURE__ */ m("div", {
668
669
  className: "h-full overflow-y-auto bg-bg-base",
@@ -680,13 +681,13 @@ var ke = (e, t, n) => ({
680
681
  type: "button",
681
682
  onClick: () => d(-1),
682
683
  className: "mb-6 cursor-pointer inline-flex items-center gap-2 text-sm text-text-muted transition-colors hover:text-text-primary",
683
- children: [/* @__PURE__ */ p(ye, { className: "size-4" }), v("common.back", "Back")]
684
+ children: [/* @__PURE__ */ p(be, { className: "size-4" }), y("common.back", "Back")]
684
685
  }),
685
686
  /* @__PURE__ */ p("h1", {
686
687
  className: "mb-3 text-4xl font-normal leading-tight text-text-primary lg:text-5xl",
687
688
  children: W.name
688
689
  }),
689
- y && /* @__PURE__ */ m("div", {
690
+ b && /* @__PURE__ */ m("div", {
690
691
  className: "mb-4 inline-flex items-center gap-1.5 rounded-full bg-status-success-bg-subtle px-3 py-1 text-sm font-medium text-status-success-text",
691
692
  children: [/* @__PURE__ */ p("svg", {
692
693
  className: "size-3.5",
@@ -698,12 +699,12 @@ var ke = (e, t, n) => ({
698
699
  strokeLinejoin: "round",
699
700
  "aria-hidden": "true",
700
701
  children: /* @__PURE__ */ p("polyline", { points: "2,8 6,12 14,4" })
701
- }), b ? v("pages.productDetail.installedVersion", "Installed v{{version}}", { version: b }) : v("pages.productDetail.installed", "Installed")]
702
+ }), x ? y("pages.productDetail.installedVersion", "Installed v{{version}}", { version: x }) : y("pages.productDetail.installed", "Installed")]
702
703
  }),
703
704
  /* @__PURE__ */ p("div", {
704
705
  className: "mb-2",
705
706
  children: (() => {
706
- let e = L?.developerOrganization, t = e?.name || L?.name || W.authorName || v("common.unknownPublisher", "Unknown Publisher"), n = e?.logoUrl || L?.logoUrl, r = e?.isVerified || L?.isVerified, i = L?.websiteUrl;
707
+ let e = L?.developerOrganization, t = e?.name || L?.name || W.authorName || y("common.unknownPublisher", "Unknown Publisher"), n = e?.logoUrl || L?.logoUrl, r = e?.isVerified || L?.isVerified, i = L?.websiteUrl;
707
708
  return /* @__PURE__ */ m("div", {
708
709
  className: "flex items-center gap-2",
709
710
  children: [
@@ -732,10 +733,10 @@ var ke = (e, t, n) => ({
732
733
  children: [
733
734
  W.category && /* @__PURE__ */ p("span", { children: W.category }),
734
735
  W.category && " · ",
735
- J ? v("pages.productDetail.purchasesCount", "{{count}}+ purchases", { count: n(W.purchaseCount) }) : v("pages.productDetail.downloadsCount", "{{count}}+ downloads", { count: n(W.downloads) })
736
+ J ? y("pages.productDetail.purchasesCount", "{{count}}+ purchases", { count: n(W.purchaseCount) }) : y("pages.productDetail.downloadsCount", "{{count}}+ downloads", { count: n(W.downloads) })
736
737
  ]
737
738
  }),
738
- /* @__PURE__ */ m(we, {
739
+ /* @__PURE__ */ m(Te, {
739
740
  className: "mb-6 p-5",
740
741
  children: [
741
742
  /* @__PURE__ */ m("div", {
@@ -762,7 +763,7 @@ var ke = (e, t, n) => ({
762
763
  /* @__PURE__ */ p(u, { className: "size-4 fill-current text-status-warning-text" }),
763
764
  /* @__PURE__ */ p("span", {
764
765
  className: "ml-1 text-xs text-text-muted",
765
- children: v("pages.productDetail.reviews_count", "{{count}} reviews", { count: n(Dt || W.reviewCount) })
766
+ children: y("pages.productDetail.reviews_count", "{{count}} reviews", { count: n(Ot || W.reviewCount) })
766
767
  })
767
768
  ]
768
769
  }),
@@ -773,7 +774,7 @@ var ke = (e, t, n) => ({
773
774
  children: [n(W.purchaseCount), "+"]
774
775
  }), /* @__PURE__ */ p("p", {
775
776
  className: "text-xs text-text-muted",
776
- children: v("pages.productDetail.purchasesLabel", "Purchases")
777
+ children: y("pages.productDetail.purchasesLabel", "Purchases")
777
778
  })]
778
779
  }) : /* @__PURE__ */ m("div", {
779
780
  className: "border-l border-border-default pl-4",
@@ -782,7 +783,7 @@ var ke = (e, t, n) => ({
782
783
  children: [n(W.downloads), "+"]
783
784
  }), /* @__PURE__ */ p("p", {
784
785
  className: "text-xs text-text-muted",
785
- children: v("pages.productDetail.downloadsLabel", "Downloads")
786
+ children: y("pages.productDetail.downloadsLabel", "Downloads")
786
787
  })]
787
788
  }),
788
789
  /* @__PURE__ */ m("div", {
@@ -792,49 +793,49 @@ var ke = (e, t, n) => ({
792
793
  children: W.type
793
794
  }), /* @__PURE__ */ p("p", {
794
795
  className: "mt-0.5 text-xs text-text-muted",
795
- children: v("pages.productDetail.typeLabel", "Type")
796
+ children: y("pages.productDetail.typeLabel", "Type")
796
797
  })]
797
798
  })
798
799
  ]
799
800
  }),
800
- it && /* @__PURE__ */ p("div", {
801
+ nt && /* @__PURE__ */ p("div", {
801
802
  role: "alert",
802
803
  className: "mb-4 rounded-lg border border-status-error-bg bg-status-error-bg-subtle px-4 py-3 text-sm text-status-error-text",
803
- children: it
804
+ children: nt
804
805
  }),
805
806
  J && !Q && /* @__PURE__ */ m("div", {
806
807
  className: "mb-4 flex flex-wrap items-center gap-4",
807
808
  children: [Y && (Z ? /* @__PURE__ */ m("span", {
808
809
  className: "inline-flex items-center gap-1.5 rounded-full bg-status-error-bg-subtle px-3 py-1 text-sm font-medium text-status-error-text",
809
- children: [/* @__PURE__ */ p(c, { className: "size-4" }), v("pages.productDetail.outOfStock", "Out of stock")]
810
+ children: [/* @__PURE__ */ p(c, { className: "size-4" }), y("pages.productDetail.outOfStock", "Out of stock")]
810
811
  }) : /* @__PURE__ */ m("span", {
811
812
  className: "inline-flex items-center gap-1.5 rounded-full bg-status-success-bg-subtle px-3 py-1 text-sm font-medium text-status-success-text",
812
- children: [/* @__PURE__ */ p(c, { className: "size-4" }), v("pages.productDetail.inStock", "{{count}} in stock", { count: n(X) })]
813
+ children: [/* @__PURE__ */ p(c, { className: "size-4" }), y("pages.productDetail.inStock", "{{count}} in stock", { count: n(X) })]
813
814
  })), !Z && /* @__PURE__ */ m("div", {
814
815
  className: "flex items-center gap-2",
815
816
  children: [/* @__PURE__ */ p("span", {
816
817
  className: "text-sm text-text-muted",
817
- children: v("pages.productDetail.quantity", "Qty")
818
+ children: y("pages.productDetail.quantity", "Qty")
818
819
  }), /* @__PURE__ */ m("div", {
819
820
  className: "flex items-center rounded-full border border-border-default",
820
821
  children: [
821
822
  /* @__PURE__ */ p("button", {
822
823
  type: "button",
823
- onClick: () => rt((e) => Math.max(1, e - 1)),
824
- disabled: S <= 1,
825
- "aria-label": v("pages.productDetail.decreaseQuantity", "Decrease quantity"),
824
+ onClick: () => tt((e) => Math.max(1, e - 1)),
825
+ disabled: T <= 1,
826
+ "aria-label": y("pages.productDetail.decreaseQuantity", "Decrease quantity"),
826
827
  className: "cursor-pointer px-3 py-1.5 text-text-primary transition-colors hover:bg-bg-sunken disabled:cursor-not-allowed disabled:opacity-40",
827
828
  children: "−"
828
829
  }),
829
830
  /* @__PURE__ */ p("span", {
830
831
  className: "min-w-8 px-2 text-center text-sm font-medium tabular-nums text-text-primary",
831
- children: S
832
+ children: T
832
833
  }),
833
834
  /* @__PURE__ */ p("button", {
834
835
  type: "button",
835
- onClick: () => rt((e) => Y ? Math.min(X, e + 1) : e + 1),
836
- disabled: Y && S >= X,
837
- "aria-label": v("pages.productDetail.increaseQuantity", "Increase quantity"),
836
+ onClick: () => tt((e) => Y ? Math.min(X, e + 1) : e + 1),
837
+ disabled: Y && T >= X,
838
+ "aria-label": y("pages.productDetail.increaseQuantity", "Increase quantity"),
838
839
  className: "cursor-pointer px-3 py-1.5 text-text-primary transition-colors hover:bg-bg-sunken disabled:cursor-not-allowed disabled:opacity-40",
839
840
  children: "+"
840
841
  })
@@ -846,20 +847,20 @@ var ke = (e, t, n) => ({
846
847
  className: "mb-6 flex items-center gap-3",
847
848
  children: [Q ? $ ? /* @__PURE__ */ m("a", {
848
849
  href: $.url,
849
- ...Mt ? {} : {
850
+ ...Nt ? {} : {
850
851
  target: "_blank",
851
852
  rel: "noopener noreferrer"
852
853
  },
853
854
  "data-testid": "store-view-external-listing",
854
855
  className: "cursor-pointer flex items-center gap-2 rounded-full bg-action-primary-bg px-8 py-3 font-medium text-action-primary-text transition-opacity hover:opacity-90",
855
- children: [/* @__PURE__ */ p(xe, {
856
+ children: [/* @__PURE__ */ p(Se, {
856
857
  className: "size-4",
857
858
  "aria-hidden": "true"
858
- }), v("pages.productDetail.viewOnProduct", "View on {{product}}", { product: $.productName })]
859
+ }), y("pages.productDetail.viewOnProduct", "View on {{product}}", { product: $.productName })]
859
860
  }) : /* @__PURE__ */ p("p", {
860
861
  className: "text-sm text-text-muted",
861
- children: v("pages.productDetail.soldElsewhereUnavailable", "This item is sold outside the store and is not available right now.")
862
- }) : y ? /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ m("button", {
862
+ children: y("pages.productDetail.soldElsewhereUnavailable", "This item is sold outside the store and is not available right now.")
863
+ }) : b ? /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ m("button", {
863
864
  type: "button",
864
865
  disabled: !0,
865
866
  className: "flex items-center gap-2 rounded-full bg-status-success-bg-subtle px-8 py-3 font-medium text-status-success-text cursor-default",
@@ -873,60 +874,60 @@ var ke = (e, t, n) => ({
873
874
  strokeLinejoin: "round",
874
875
  "aria-hidden": "true",
875
876
  children: /* @__PURE__ */ p("polyline", { points: "2,8 6,12 14,4" })
876
- }), v("pages.productDetail.installed", "Installed")]
877
- }), gt && /* @__PURE__ */ p("button", {
877
+ }), y("pages.productDetail.installed", "Installed")]
878
+ }), _t && /* @__PURE__ */ p("button", {
878
879
  type: "button",
879
880
  onClick: z,
880
881
  className: "cursor-pointer rounded-full bg-action-primary-bg px-8 py-3 font-medium text-action-primary-text transition-opacity hover:opacity-90",
881
- children: v("pages.productDetail.updateToVersion", "Update to v{{version}}", { version: W.manifestVersion ?? "" })
882
+ children: y("pages.productDetail.updateToVersion", "Update to v{{version}}", { version: W.manifestVersion ?? "" })
882
883
  })] }) : !J && H && !q ? /* @__PURE__ */ p("button", {
883
884
  type: "button",
884
885
  onClick: z,
885
886
  className: "cursor-pointer rounded-full bg-action-primary-bg px-8 py-3 font-medium text-action-primary-text transition-opacity hover:opacity-90",
886
- children: v("pages.productDetail.installToWorkspace", "Install to Workspace")
887
+ children: y("pages.productDetail.installToWorkspace", "Install to Workspace")
887
888
  }) : !J && q ? /* @__PURE__ */ p("button", {
888
889
  type: "button",
889
890
  onClick: z,
890
891
  className: "cursor-pointer rounded-full bg-action-primary-bg px-8 py-3 font-medium text-action-primary-text transition-opacity hover:opacity-90",
891
- children: v("pages.productDetail.install", "Install")
892
+ children: y("pages.productDetail.install", "Install")
892
893
  }) : /* @__PURE__ */ p("button", {
893
894
  type: "button",
894
- onClick: vt,
895
- disabled: tt || ze || Z,
895
+ onClick: yt,
896
+ disabled: et || ze || Z,
896
897
  className: "cursor-pointer flex items-center gap-2 rounded-full bg-action-primary-bg px-8 py-3 font-medium text-action-primary-text transition-opacity hover:opacity-90 disabled:opacity-70",
897
- children: tt || ze ? /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p(Se, { className: "size-4 animate-spin" }), v("pages.productDetail.processing", "Processing…")] }) : Z ? v("pages.productDetail.outOfStock", "Out of stock") : v("pages.productDetail.buyNow", "Buy {{price}}", { price: jt() })
898
+ children: et || ze ? /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p(Ce, { className: "size-4 animate-spin" }), y("pages.productDetail.processing", "Processing…")] }) : Z ? y("pages.productDetail.outOfStock", "Out of stock") : y("pages.productDetail.buyNow", "Buy {{price}}", { price: Mt() })
898
899
  }), !Q && !q && (!H || J) && /* @__PURE__ */ m("button", {
899
900
  type: "button",
900
- onClick: _t,
901
+ onClick: vt,
901
902
  disabled: Le || Z,
902
903
  className: "cursor-pointer flex items-center gap-2 rounded-full border border-border-default px-4 py-3 text-sm text-text-primary transition-colors hover:bg-bg-sunken disabled:opacity-50",
903
- children: [Le ? /* @__PURE__ */ p(Se, { className: "size-4 animate-spin" }) : R ? /* @__PURE__ */ p(be, { className: "size-4 text-status-success-text" }) : /* @__PURE__ */ p(Ce, { className: "size-4" }), R ? v("pages.productDetail.inCart", "In Cart") : v("pages.productDetail.addToCart", "Add to Cart")]
904
+ children: [Le ? /* @__PURE__ */ p(Ce, { className: "size-4 animate-spin" }) : R ? /* @__PURE__ */ p(xe, { className: "size-4 text-status-success-text" }) : /* @__PURE__ */ p(we, { className: "size-4" }), R ? y("pages.productDetail.inCart", "In Cart") : y("pages.productDetail.addToCart", "Add to Cart")]
904
905
  })]
905
906
  }),
906
907
  Q ? $ && /* @__PURE__ */ m("p", {
907
908
  className: "flex items-center gap-2 text-xs text-text-muted",
908
- children: [/* @__PURE__ */ p(c, { className: "size-4" }), v("pages.productDetail.soldOnProductNotice", "Sold by {{product}}. Checkout, delivery and returns are handled there.", { product: $.productName })]
909
+ children: [/* @__PURE__ */ p(c, { className: "size-4" }), y("pages.productDetail.soldOnProductNotice", "Sold by {{product}}. Checkout, delivery and returns are handled there.", { product: $.productName })]
909
910
  }) : J ? /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ m("p", {
910
911
  className: "flex items-center gap-2 text-xs text-text-muted",
911
- children: [/* @__PURE__ */ p(c, { className: "size-4" }), W.requiresShipping === !1 ? v("pages.productDetail.pickupAvailable", "Available for pickup — no shipping required") : v("pages.productDetail.shipsToAddress", "Ships to your delivery address")]
912
+ children: [/* @__PURE__ */ p(c, { className: "size-4" }), W.requiresShipping === !1 ? y("pages.productDetail.pickupAvailable", "Available for pickup — no shipping required") : y("pages.productDetail.shipsToAddress", "Ships to your delivery address")]
912
913
  }), !q && /* @__PURE__ */ p("p", {
913
914
  className: "text-xs text-text-tertiary",
914
- children: v("pages.productDetail.sellerReturnsPolicy", "Returns and refunds are handled by {{seller}} per their store policy.", { seller: L?.name || v("pages.productDetail.theSeller", "the seller") })
915
+ children: y("pages.productDetail.sellerReturnsPolicy", "Returns and refunds are handled by {{seller}} per their store policy.", { seller: L?.name || y("pages.productDetail.theSeller", "the seller") })
915
916
  })] }) : /* @__PURE__ */ m(f, { children: [
916
917
  /* @__PURE__ */ m("p", {
917
918
  className: "flex items-center gap-2 text-xs text-text-muted",
918
- children: [/* @__PURE__ */ p(c, { className: "size-4" }), v("pages.productDetail.availableForWorkspace", "This app is available for your workspace")]
919
+ children: [/* @__PURE__ */ p(c, { className: "size-4" }), y("pages.productDetail.availableForWorkspace", "This app is available for your workspace")]
919
920
  }),
920
921
  !q && !H && /* @__PURE__ */ p("p", {
921
922
  className: "text-xs text-text-tertiary",
922
- children: v("pages.productDetail.purchaseFinalNotice", "All purchases are final. Digital app orders cannot be cancelled or refunded once completed.")
923
+ children: y("pages.productDetail.purchaseFinalNotice", "All purchases are final. Digital app orders cannot be cancelled or refunded once completed.")
923
924
  }),
924
925
  U && /* @__PURE__ */ m("p", {
925
926
  className: "mt-2 flex items-center gap-2 text-xs text-text-muted",
926
927
  children: [
927
928
  /* @__PURE__ */ p(l, { className: "size-4 text-status-success-text" }),
928
- v("pages.productDetail.licenseStatus", "License: {{status}}", { status: U.status }),
929
- U.expiresAt && v("pages.productDetail.licenseExpires", " (Expires: {{date}})", { date: new Date(U.expiresAt).toLocaleDateString() })
929
+ y("pages.productDetail.licenseStatus", "License: {{status}}", { status: U.status }),
930
+ U.expiresAt && y("pages.productDetail.licenseExpires", " (Expires: {{date}})", { date: new Date(U.expiresAt).toLocaleDateString() })
930
931
  ]
931
932
  })
932
933
  ] })
@@ -957,11 +958,11 @@ var ke = (e, t, n) => ({
957
958
  }),
958
959
  /* @__PURE__ */ p("p", {
959
960
  className: "text-sm text-text-muted",
960
- children: v("pages.productDetail.noPreview", "No preview available")
961
+ children: y("pages.productDetail.noPreview", "No preview available")
961
962
  }),
962
963
  /* @__PURE__ */ p("p", {
963
964
  className: "max-w-[200px] text-xs text-text-muted opacity-60",
964
- children: v("pages.productDetail.noPreviewHint", "Upload screenshots in the Store Listing tab to show a preview here")
965
+ children: y("pages.productDetail.noPreviewHint", "Upload screenshots in the Store Listing tab to show a preview here")
965
966
  })
966
967
  ]
967
968
  })
@@ -975,7 +976,7 @@ var ke = (e, t, n) => ({
975
976
  className: "px-6 py-6",
976
977
  children: [/* @__PURE__ */ p("h2", {
977
978
  className: "mb-4 text-sm font-semibold uppercase tracking-wider text-text-muted",
978
- children: v("pages.productDetail.previewTitle", "Preview")
979
+ children: y("pages.productDetail.previewTitle", "Preview")
979
980
  }), /* @__PURE__ */ m("div", {
980
981
  className: "flex gap-4 overflow-x-auto pb-2",
981
982
  style: { scrollSnapType: "x mandatory" },
@@ -1000,43 +1001,43 @@ var ke = (e, t, n) => ({
1000
1001
  /* @__PURE__ */ m("main", {
1001
1002
  className: "mx-auto max-w-7xl px-6 py-8",
1002
1003
  children: [
1003
- /* @__PURE__ */ p(De, {
1004
+ /* @__PURE__ */ p(Oe, {
1004
1005
  className: "mb-6",
1005
- children: v("pages.productDetail.pagePurpose", "Everything you need to decide whether to install {{name}}: what it does, screenshots, pricing, the permissions and integrations it needs, and real customer reviews. When you are ready, install it (free apps) or buy it, then add it to a workspace — and leave a review once you have used it.", { name: W.name })
1006
+ children: y("pages.productDetail.pagePurpose", "Everything you need to decide whether to install {{name}}: what it does, screenshots, pricing, the permissions and integrations it needs, and real customer reviews. When you are ready, install it (free apps) or buy it, then add it to a workspace — and leave a review once you have used it.", { name: W.name })
1006
1007
  }),
1007
- /* @__PURE__ */ p(Ee, {
1008
+ /* @__PURE__ */ p(De, {
1008
1009
  className: "mb-8",
1009
1010
  storageKey: "store-product-detail",
1010
1011
  steps: [
1011
1012
  Q ? {
1012
1013
  id: "buy",
1013
- label: $ ? v("pages.productDetail.viewOnProduct", "View on {{product}}", { product: $.productName }) : v("pages.productDetail.nextStepSoldElsewhereLabel", "Sold outside the store"),
1014
- description: v("pages.productDetail.nextStepSoldElsewhereDescription", "This item is bought in the product that sells it, not through the store cart."),
1015
- onClick: Nt,
1014
+ label: $ ? y("pages.productDetail.viewOnProduct", "View on {{product}}", { product: $.productName }) : y("pages.productDetail.nextStepSoldElsewhereLabel", "Sold outside the store"),
1015
+ description: y("pages.productDetail.nextStepSoldElsewhereDescription", "This item is bought in the product that sells it, not through the store cart."),
1016
+ onClick: Pt,
1016
1017
  done: !1
1017
1018
  } : q ? {
1018
1019
  id: "install",
1019
- label: v("pages.productDetail.nextStepInstallLabel", "Install this app"),
1020
- description: v("pages.productDetail.nextStepInstallDescription", "It’s free — add it to a workspace in a couple of clicks."),
1020
+ label: y("pages.productDetail.nextStepInstallLabel", "Install this app"),
1021
+ description: y("pages.productDetail.nextStepInstallDescription", "It’s free — add it to a workspace in a couple of clicks."),
1021
1022
  onClick: z,
1022
- done: y
1023
+ done: b
1023
1024
  } : {
1024
1025
  id: "buy",
1025
- label: H ? v("pages.productDetail.nextStepInstallLabel", "Install to a workspace") : v("pages.productDetail.nextStepBuyLabel", "Buy or add to cart"),
1026
- description: H ? v("pages.productDetail.nextStepOwnedDescription", "You already own this — install it where you need it.") : v("pages.productDetail.nextStepBuyDescription", "Purchase now, or add it to your cart to check out later."),
1027
- onClick: H ? z : vt,
1028
- done: y
1026
+ label: H ? y("pages.productDetail.nextStepInstallLabel", "Install to a workspace") : y("pages.productDetail.nextStepBuyLabel", "Buy or add to cart"),
1027
+ description: H ? y("pages.productDetail.nextStepOwnedDescription", "You already own this — install it where you need it.") : y("pages.productDetail.nextStepBuyDescription", "Purchase now, or add it to your cart to check out later."),
1028
+ onClick: H ? z : yt,
1029
+ done: b
1029
1030
  },
1030
1031
  ...K.length > 0 ? [{
1031
1032
  id: "permissions",
1032
- label: v("pages.productDetail.nextStepPermissionsLabel", "Review what it can access"),
1033
- description: v("pages.productDetail.nextStepPermissionsDescription", "Check the permissions this app requires before installing."),
1033
+ label: y("pages.productDetail.nextStepPermissionsLabel", "Review what it can access"),
1034
+ description: y("pages.productDetail.nextStepPermissionsDescription", "Check the permissions this app requires before installing."),
1034
1035
  href: "#about-permissions"
1035
1036
  }] : [],
1036
1037
  {
1037
1038
  id: "reviews",
1038
- label: v("pages.productDetail.nextStepReviewsLabel", "Read the reviews"),
1039
- description: v("pages.productDetail.nextStepReviewsDescription", "See what other customers think before committing."),
1039
+ label: y("pages.productDetail.nextStepReviewsLabel", "Read the reviews"),
1040
+ description: y("pages.productDetail.nextStepReviewsDescription", "See what other customers think before committing."),
1040
1041
  href: "#ratings-reviews"
1041
1042
  }
1042
1043
  ]
@@ -1053,19 +1054,19 @@ var ke = (e, t, n) => ({
1053
1054
  className: "mb-4 flex items-center justify-between text-left",
1054
1055
  children: /* @__PURE__ */ p("h2", {
1055
1056
  className: "text-lg font-medium text-text-primary",
1056
- children: v("pages.productDetail.aboutThisApp", "About this app")
1057
+ children: y("pages.productDetail.aboutThisApp", "About this app")
1057
1058
  })
1058
1059
  }),
1059
1060
  /* @__PURE__ */ m("div", {
1060
1061
  className: "text-sm leading-relaxed text-text-secondary",
1061
1062
  children: [/* @__PURE__ */ p("div", {
1062
1063
  className: Ze ? "" : "line-clamp-4",
1063
- children: /* @__PURE__ */ p(ie, { children: W.longDescription || W.description || v("pages.productDetail.noDescription", "No description available.") })
1064
+ children: /* @__PURE__ */ p(ie, { children: W.longDescription || W.description || y("pages.productDetail.noDescription", "No description available.") })
1064
1065
  }), ((W.longDescription || W.description)?.length ?? 0) > 200 && /* @__PURE__ */ p("button", {
1065
1066
  type: "button",
1066
1067
  onClick: () => Qe(!Ze),
1067
1068
  className: "cursor-pointer mt-3 text-sm font-medium text-text-link",
1068
- children: Ze ? v("pages.productDetail.showLess", "Show less") : v("pages.productDetail.showMore", "Show more")
1069
+ children: Ze ? y("pages.productDetail.showLess", "Show less") : y("pages.productDetail.showMore", "Show more")
1069
1070
  })]
1070
1071
  }),
1071
1072
  W.tags && W.tags.length > 0 && /* @__PURE__ */ p("div", {
@@ -1085,7 +1086,7 @@ var ke = (e, t, n) => ({
1085
1086
  className: "mb-4 flex items-center justify-between text-left",
1086
1087
  children: /* @__PURE__ */ p("h2", {
1087
1088
  className: "text-lg font-medium text-text-primary",
1088
- children: v("pages.productDetail.ratingsAndReviews", "Ratings & Reviews")
1089
+ children: y("pages.productDetail.ratingsAndReviews", "Ratings & Reviews")
1089
1090
  })
1090
1091
  }),
1091
1092
  /* @__PURE__ */ m(h, {
@@ -1112,12 +1113,12 @@ var ke = (e, t, n) => ({
1112
1113
  }),
1113
1114
  /* @__PURE__ */ p("p", {
1114
1115
  className: "text-sm text-text-muted",
1115
- children: v("pages.productDetail.reviews_count", "{{count}} reviews", { count: n(Dt || W.reviewCount) })
1116
+ children: y("pages.productDetail.reviews_count", "{{count}} reviews", { count: n(Ot || W.reviewCount) })
1116
1117
  })
1117
1118
  ]
1118
- }), kt.length > 0 && /* @__PURE__ */ p("div", {
1119
+ }), At.length > 0 && /* @__PURE__ */ p("div", {
1119
1120
  className: "flex-1 space-y-1.5",
1120
- children: kt.map((e) => /* @__PURE__ */ p(Ae, { ...e }, e.stars))
1121
+ children: At.map((e) => /* @__PURE__ */ p(je, { ...e }, e.stars))
1121
1122
  })]
1122
1123
  }) : /* @__PURE__ */ m("div", {
1123
1124
  className: "flex flex-col items-center justify-center py-6 text-center",
@@ -1134,32 +1135,32 @@ var ke = (e, t, n) => ({
1134
1135
  }),
1135
1136
  /* @__PURE__ */ p("p", {
1136
1137
  className: "font-medium text-text-primary",
1137
- children: v("pages.productDetail.noReviews", "No reviews yet")
1138
+ children: y("pages.productDetail.noReviews", "No reviews yet")
1138
1139
  }),
1139
1140
  /* @__PURE__ */ p("p", {
1140
1141
  className: "mt-1 text-sm text-text-muted",
1141
- children: v("pages.productDetail.beFirstToReview", "Be the first to share your experience with this app.")
1142
+ children: y("pages.productDetail.beFirstToReview", "Be the first to share your experience with this app.")
1142
1143
  })
1143
1144
  ]
1144
1145
  }), /* @__PURE__ */ m("div", {
1145
1146
  className: "mt-6 border-t border-border-seam pt-4",
1146
- children: [at && /* @__PURE__ */ p("p", {
1147
- role: ot === "success" ? "status" : "alert",
1148
- className: `mb-3 rounded-lg px-3 py-2 text-sm ${ot === "success" ? "bg-status-success-bg-subtle text-status-success-text" : "bg-status-error-bg-subtle text-status-error-text"}`,
1149
- children: at
1150
- }), y || F?.isPurchased || F?.userReview ? /* @__PURE__ */ m("div", {
1147
+ children: [rt && /* @__PURE__ */ p("p", {
1148
+ role: it === "success" ? "status" : "alert",
1149
+ className: `mb-3 rounded-lg px-3 py-2 text-sm ${it === "success" ? "bg-status-success-bg-subtle text-status-success-text" : "bg-status-error-bg-subtle text-status-error-text"}`,
1150
+ children: rt
1151
+ }), b || F?.isPurchased || F?.userReview ? /* @__PURE__ */ m("div", {
1151
1152
  className: "space-y-4",
1152
1153
  children: [/* @__PURE__ */ p("button", {
1153
1154
  type: "button",
1154
- onClick: () => E ? D(!1) : Ct(),
1155
+ onClick: () => k ? A(!1) : wt(),
1155
1156
  className: "w-full cursor-pointer py-2 text-center text-sm font-medium text-text-primary transition-colors hover:text-text-link",
1156
- children: F?.userReview ? E ? v("pages.productDetail.cancelReviewEditing", "Cancel review editing") : v("pages.productDetail.editYourReview", "Edit your review") : E ? v("pages.productDetail.cancelReview", "Cancel review") : v("pages.productDetail.writeReview", "Write a Review")
1157
- }), E && /* @__PURE__ */ m("div", {
1157
+ children: F?.userReview ? k ? y("pages.productDetail.cancelReviewEditing", "Cancel review editing") : y("pages.productDetail.editYourReview", "Edit your review") : k ? y("pages.productDetail.cancelReview", "Cancel review") : y("pages.productDetail.writeReview", "Write a Review")
1158
+ }), k && /* @__PURE__ */ m("div", {
1158
1159
  className: "rounded-xl border border-border-seam bg-bg-sunken p-4",
1159
1160
  children: [
1160
1161
  /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p("p", {
1161
1162
  className: "text-sm font-medium text-text-primary",
1162
- children: v("pages.productDetail.yourRatingLabel", "Your rating")
1163
+ children: y("pages.productDetail.yourRatingLabel", "Your rating")
1163
1164
  }), /* @__PURE__ */ p("div", {
1164
1165
  className: "mt-2 flex flex-wrap gap-2",
1165
1166
  children: [
@@ -1170,55 +1171,55 @@ var ke = (e, t, n) => ({
1170
1171
  5
1171
1172
  ].map((e) => /* @__PURE__ */ m("button", {
1172
1173
  type: "button",
1173
- onClick: () => N(e),
1174
- className: `cursor-pointer rounded-full border px-3 py-1.5 text-sm transition-colors ${M === e ? "border-action-primary-border bg-action-primary-bg text-action-primary-text" : "border-border-default bg-bg-surface text-text-primary hover:bg-bg-surface"}`,
1174
+ onClick: () => st(e),
1175
+ className: `cursor-pointer rounded-full border px-3 py-1.5 text-sm transition-colors ${N === e ? "border-action-primary-border bg-action-primary-bg text-action-primary-text" : "border-border-default bg-bg-surface text-text-primary hover:bg-bg-surface"}`,
1175
1176
  children: [e, " ★"]
1176
1177
  }, e))
1177
1178
  })] }),
1178
1179
  /* @__PURE__ */ m("label", {
1179
1180
  className: "mt-4 block text-sm font-medium text-text-primary",
1180
- children: [v("pages.productDetail.reviewTitleLabel", "Title"), /* @__PURE__ */ p("input", {
1181
- "aria-label": v("pages.productDetail.reviewTitleLabel", "Review title"),
1182
- value: O,
1183
- onChange: (e) => k(e.target.value),
1181
+ children: [y("pages.productDetail.reviewTitleLabel", "Title"), /* @__PURE__ */ p("input", {
1182
+ "aria-label": y("pages.productDetail.reviewTitleLabel", "Review title"),
1183
+ value: j,
1184
+ onChange: (e) => M(e.target.value),
1184
1185
  className: "mt-2 w-full rounded-lg border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary outline-none focus:border-action-primary-border",
1185
- placeholder: v("pages.productDetail.reviewTitlePlaceholder", "Summarize your experience")
1186
+ placeholder: y("pages.productDetail.reviewTitlePlaceholder", "Summarize your experience")
1186
1187
  })]
1187
1188
  }),
1188
1189
  /* @__PURE__ */ m("label", {
1189
1190
  className: "mt-4 block text-sm font-medium text-text-primary",
1190
- children: [v("pages.productDetail.reviewBodyLabel", "Review"), /* @__PURE__ */ p("textarea", {
1191
- "aria-label": v("pages.productDetail.reviewBodyLabel", "Review body"),
1192
- value: A,
1193
- onChange: (e) => j(e.target.value),
1191
+ children: [y("pages.productDetail.reviewBodyLabel", "Review"), /* @__PURE__ */ p("textarea", {
1192
+ "aria-label": y("pages.productDetail.reviewBodyLabel", "Review body"),
1193
+ value: at,
1194
+ onChange: (e) => ot(e.target.value),
1194
1195
  rows: 4,
1195
1196
  required: !0,
1196
1197
  "aria-required": "true",
1197
1198
  className: "mt-2 w-full rounded-lg border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary outline-none focus:border-action-primary-border",
1198
- placeholder: v("pages.productDetail.reviewBodyPlaceholder", "What worked well? What should improve?")
1199
+ placeholder: y("pages.productDetail.reviewBodyPlaceholder", "What worked well? What should improve?")
1199
1200
  })]
1200
1201
  }),
1201
1202
  /* @__PURE__ */ m("div", {
1202
1203
  className: "mt-4 flex flex-wrap gap-3",
1203
1204
  children: [/* @__PURE__ */ p("button", {
1204
1205
  type: "button",
1205
- onClick: wt,
1206
+ onClick: Tt,
1206
1207
  disabled: We || Ke,
1207
1208
  className: "cursor-pointer rounded-lg bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:opacity-90 disabled:cursor-not-allowed disabled:opacity-60",
1208
- children: We || Ke ? v("pages.productDetail.savingReview", "Saving...") : F?.userReview ? v("pages.productDetail.updateReview", "Update Review") : v("pages.productDetail.submitReview", "Submit Review")
1209
+ children: We || Ke ? y("pages.productDetail.savingReview", "Saving...") : F?.userReview ? y("pages.productDetail.updateReview", "Update Review") : y("pages.productDetail.submitReview", "Submit Review")
1209
1210
  }), F?.userReview && /* @__PURE__ */ p("button", {
1210
1211
  type: "button",
1211
- onClick: Tt,
1212
+ onClick: Et,
1212
1213
  disabled: Je,
1213
1214
  className: "cursor-pointer rounded-lg border border-status-error-border px-4 py-2 text-sm font-medium text-status-error-text hover:bg-status-error-bg-subtle disabled:cursor-not-allowed disabled:opacity-60",
1214
- children: Je ? v("pages.productDetail.removingReview", "Removing...") : v("pages.productDetail.deleteReview", "Delete Review")
1215
+ children: Je ? y("pages.productDetail.removingReview", "Removing...") : y("pages.productDetail.deleteReview", "Delete Review")
1215
1216
  })]
1216
1217
  })
1217
1218
  ]
1218
1219
  })]
1219
1220
  }) : /* @__PURE__ */ p("p", {
1220
1221
  className: "text-center text-sm text-text-muted",
1221
- children: v("pages.productDetail.installToReview", "Install this app to leave a review.")
1222
+ children: y("pages.productDetail.installToReview", "Install this app to leave a review.")
1222
1223
  })]
1223
1224
  })]
1224
1225
  }),
@@ -1226,21 +1227,21 @@ var ke = (e, t, n) => ({
1226
1227
  className: "mt-4 space-y-3",
1227
1228
  children: [/* @__PURE__ */ p("ul", {
1228
1229
  className: "space-y-3",
1229
- children: ($e ? B : B.slice(0, 2)).map((e) => /* @__PURE__ */ p("li", { children: /* @__PURE__ */ p(je, {
1230
+ children: (C ? B : B.slice(0, 2)).map((e) => /* @__PURE__ */ p("li", { children: /* @__PURE__ */ p(Me, {
1230
1231
  review: e,
1231
- onMarkHelpful: Et,
1232
- markingHelpful: Xe && st === e.id
1232
+ onMarkHelpful: Dt,
1233
+ markingHelpful: Xe && ct === e.id
1233
1234
  }) }, e.id))
1234
1235
  }), B.length > 2 && /* @__PURE__ */ p("button", {
1235
1236
  type: "button",
1236
- onClick: () => et(!$e),
1237
+ onClick: () => $e(!C),
1237
1238
  className: "cursor-pointer text-sm font-medium text-text-link",
1238
- children: $e ? v("pages.productDetail.showLess", "Show less") : v("pages.productDetail.showAllReviews", "Show all {{count}} reviews", { count: B.length })
1239
+ children: C ? y("pages.productDetail.showLess", "Show less") : y("pages.productDetail.showAllReviews", "Show all {{count}} reviews", { count: B.length })
1239
1240
  })]
1240
1241
  }),
1241
1242
  (!B || B.length === 0) && /* @__PURE__ */ p("p", {
1242
1243
  className: "mt-4 text-sm text-text-muted",
1243
- children: v("pages.productDetail.beFirstToReviewShort", "No reviews yet. Be the first to review!")
1244
+ children: y("pages.productDetail.beFirstToReviewShort", "No reviews yet. Be the first to review!")
1244
1245
  })
1245
1246
  ]
1246
1247
  }),
@@ -1249,7 +1250,7 @@ var ke = (e, t, n) => ({
1249
1250
  className: "mb-8 scroll-mt-6",
1250
1251
  children: [/* @__PURE__ */ p("h2", {
1251
1252
  className: "mb-4 text-lg font-medium text-text-primary",
1252
- children: v("pages.productDetail.requiredPermissions", "Required Permissions")
1253
+ children: y("pages.productDetail.requiredPermissions", "Required Permissions")
1253
1254
  }), /* @__PURE__ */ p("div", {
1254
1255
  className: "space-y-2",
1255
1256
  children: K.map((e) => /* @__PURE__ */ m("div", {
@@ -1261,14 +1262,14 @@ var ke = (e, t, n) => ({
1261
1262
  }, e))
1262
1263
  })]
1263
1264
  }),
1264
- At.length > 0 && /* @__PURE__ */ m("section", {
1265
+ jt.length > 0 && /* @__PURE__ */ m("section", {
1265
1266
  className: "mb-8",
1266
1267
  children: [/* @__PURE__ */ p("h2", {
1267
1268
  className: "mb-4 text-lg font-medium text-text-primary",
1268
- children: v("pages.productDetail.integrations", "Integrations")
1269
+ children: y("pages.productDetail.integrations", "Integrations")
1269
1270
  }), /* @__PURE__ */ p("div", {
1270
1271
  className: "flex flex-wrap gap-2",
1271
- children: At.map((e) => /* @__PURE__ */ p("span", {
1272
+ children: jt.map((e) => /* @__PURE__ */ p("span", {
1272
1273
  className: "rounded-lg bg-bg-surface px-4 py-2 text-sm font-medium text-text-primary",
1273
1274
  children: e
1274
1275
  }, e))
@@ -1278,49 +1279,49 @@ var ke = (e, t, n) => ({
1278
1279
  className: "mb-8",
1279
1280
  children: [/* @__PURE__ */ p("h2", {
1280
1281
  className: "mb-4 text-lg font-medium text-text-primary",
1281
- children: v("pages.productDetail.additionalInformation", "Additional Information")
1282
+ children: y("pages.productDetail.additionalInformation", "Additional Information")
1282
1283
  }), /* @__PURE__ */ m(h, {
1283
1284
  treatment: "metric",
1284
1285
  className: "grid grid-cols-2 gap-6 p-5 md:grid-cols-3",
1285
1286
  children: [
1286
1287
  W.manifestVersion && /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p("p", {
1287
1288
  className: "text-xs text-text-muted",
1288
- children: v("pages.productDetail.versionLabel", "Version")
1289
+ children: y("pages.productDetail.versionLabel", "Version")
1289
1290
  }), /* @__PURE__ */ p("p", {
1290
1291
  className: "mt-1 text-sm font-medium text-text-primary",
1291
1292
  children: W.manifestVersion
1292
1293
  })] }),
1293
1294
  /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p("p", {
1294
1295
  className: "text-xs text-text-muted",
1295
- children: v("pages.productDetail.typeLabel", "Type")
1296
+ children: y("pages.productDetail.typeLabel", "Type")
1296
1297
  }), /* @__PURE__ */ p("p", {
1297
1298
  className: "mt-1 text-sm font-medium text-text-primary",
1298
1299
  children: W.type
1299
1300
  })] }),
1300
1301
  W.publishedAt && /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p("p", {
1301
1302
  className: "text-xs text-text-muted",
1302
- children: v("pages.productDetail.publishedLabel", "Published")
1303
+ children: y("pages.productDetail.publishedLabel", "Published")
1303
1304
  }), /* @__PURE__ */ p("p", {
1304
1305
  className: "mt-1 text-sm font-medium text-text-primary",
1305
1306
  children: new Date(W.publishedAt).toLocaleDateString()
1306
1307
  })] }),
1307
1308
  /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p("p", {
1308
1309
  className: "text-xs text-text-muted",
1309
- children: v("pages.productDetail.updatedLabel", "Updated")
1310
+ children: y("pages.productDetail.updatedLabel", "Updated")
1310
1311
  }), /* @__PURE__ */ p("p", {
1311
1312
  className: "mt-1 text-sm font-medium text-text-primary",
1312
1313
  children: new Date(W.updatedAt).toLocaleDateString()
1313
1314
  })] }),
1314
1315
  W.license && /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p("p", {
1315
1316
  className: "text-xs text-text-muted",
1316
- children: v("pages.productDetail.licenseLabel", "License")
1317
+ children: y("pages.productDetail.licenseLabel", "License")
1317
1318
  }), /* @__PURE__ */ p("p", {
1318
1319
  className: "mt-1 text-sm font-medium text-text-primary",
1319
1320
  children: W.license
1320
1321
  })] }),
1321
1322
  W.minPlatformVersion && /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p("p", {
1322
1323
  className: "text-xs text-text-muted",
1323
- children: v("pages.productDetail.minPlatformVersionLabel", "Min Platform Version")
1324
+ children: y("pages.productDetail.minPlatformVersionLabel", "Min Platform Version")
1324
1325
  }), /* @__PURE__ */ p("p", {
1325
1326
  className: "mt-1 text-sm font-medium text-text-primary",
1326
1327
  children: W.minPlatformVersion
@@ -1336,7 +1337,7 @@ var ke = (e, t, n) => ({
1336
1337
  className: "mb-6 p-4",
1337
1338
  children: [/* @__PURE__ */ p("h3", {
1338
1339
  className: "font-medium text-text-primary",
1339
- children: v("pages.productDetail.appSupport", "App support")
1340
+ children: y("pages.productDetail.appSupport", "App support")
1340
1341
  }), /* @__PURE__ */ m("div", {
1341
1342
  className: "mt-3 space-y-2 text-sm",
1342
1343
  children: [
@@ -1345,23 +1346,27 @@ var ke = (e, t, n) => ({
1345
1346
  target: "_blank",
1346
1347
  rel: "noreferrer",
1347
1348
  className: "block text-text-link hover:underline",
1348
- children: v("pages.productDetail.documentation", "Documentation")
1349
+ children: y("pages.productDetail.documentation", "Documentation")
1349
1350
  }),
1350
1351
  W.repositoryUrl && /* @__PURE__ */ p("a", {
1351
1352
  href: W.repositoryUrl,
1352
1353
  target: "_blank",
1353
1354
  rel: "noreferrer",
1354
1355
  className: "block text-text-link hover:underline",
1355
- children: v("pages.productDetail.sourceRepository", "Source repository")
1356
+ children: y("pages.productDetail.sourceRepository", "Source repository")
1356
1357
  }),
1357
1358
  L?.email && /* @__PURE__ */ p("a", {
1358
1359
  href: `mailto:${L.email}`,
1359
1360
  className: "block text-text-link hover:underline",
1360
- children: v("pages.productDetail.contactPublisher", "Contact publisher")
1361
+ children: y("pages.productDetail.contactPublisher", "Contact publisher")
1361
1362
  })
1362
1363
  ]
1363
1364
  })]
1364
1365
  }),
1366
+ W.id && /* @__PURE__ */ p(pe, {
1367
+ productId: W.id,
1368
+ productName: W.name
1369
+ }),
1365
1370
  L && /* @__PURE__ */ p(h, {
1366
1371
  className: "mb-6 p-4",
1367
1372
  children: (() => {
@@ -1396,22 +1401,22 @@ var ke = (e, t, n) => ({
1396
1401
  target: "_blank",
1397
1402
  rel: "noreferrer",
1398
1403
  className: "mt-3 inline-block text-sm text-text-link hover:underline",
1399
- children: v("pages.productDetail.visitWebsite", "Visit website")
1404
+ children: y("pages.productDetail.visitWebsite", "Visit website")
1400
1405
  })
1401
1406
  ] });
1402
1407
  })()
1403
1408
  }),
1404
- Ot && Ot.length > 0 && /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p("div", {
1409
+ kt && kt.length > 0 && /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p("div", {
1405
1410
  className: "mb-4 flex items-center justify-between text-left",
1406
1411
  children: /* @__PURE__ */ p("span", {
1407
1412
  className: "font-medium text-text-primary",
1408
- children: v("pages.productDetail.similarApps", "Similar apps")
1413
+ children: y("pages.productDetail.similarApps", "Similar apps")
1409
1414
  })
1410
1415
  }), /* @__PURE__ */ p("div", {
1411
1416
  className: "space-y-3",
1412
- children: Ot.slice(0, 4).map((e) => /* @__PURE__ */ m("button", {
1417
+ children: kt.slice(0, 4).map((e) => /* @__PURE__ */ m("button", {
1413
1418
  type: "button",
1414
- onClick: () => d(`${g}/marketplace/product/${e.id}`),
1419
+ onClick: () => d(`${_}/marketplace/product/${e.id}`),
1415
1420
  className: "flex w-full cursor-pointer items-center gap-3 rounded-lg p-2 text-left transition-colors hover:bg-bg-sunken",
1416
1421
  children: [e.icon ? /* @__PURE__ */ p("img", {
1417
1422
  src: e.icon,
@@ -1429,7 +1434,7 @@ var ke = (e, t, n) => ({
1429
1434
  }),
1430
1435
  /* @__PURE__ */ p("p", {
1431
1436
  className: "text-xs text-text-muted",
1432
- children: L?.name || v("common.unknown", "Unknown")
1437
+ children: L?.name || y("common.unknown", "Unknown")
1433
1438
  }),
1434
1439
  (e.reviewCount ?? 0) > 0 && /* @__PURE__ */ m("div", {
1435
1440
  className: "flex items-center gap-1",
@@ -1448,8 +1453,8 @@ var ke = (e, t, n) => ({
1448
1453
  ]
1449
1454
  }),
1450
1455
  W && /* @__PURE__ */ p(oe, {
1451
- isOpen: lt,
1452
- onClose: () => ut(!1),
1456
+ isOpen: ut,
1457
+ onClose: () => dt(!1),
1453
1458
  app: {
1454
1459
  id: W.id,
1455
1460
  applicationId: W.productId,
@@ -1461,13 +1466,13 @@ var ke = (e, t, n) => ({
1461
1466
  permissions: K.length > 0 ? K : void 0
1462
1467
  },
1463
1468
  purchaseState: H && !q ? "purchased" : "free",
1464
- onInstallSuccess: xt,
1465
- onInstallError: St
1469
+ onInstallSuccess: St,
1470
+ onInstallError: Ct
1466
1471
  })
1467
1472
  ]
1468
1473
  });
1469
1474
  };
1470
1475
  //#endregion
1471
- export { Pe as ProductDetailPage };
1476
+ export { g as ProductDetailPage };
1472
1477
 
1473
1478
  //# sourceMappingURL=ProductDetailPage.js.map