@burdenoff/microfe-store 2026.625.4 → 2026.625.5

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.
@@ -454,7 +454,7 @@ var Se = (e, t) => ({
454
454
  workspaceId: m
455
455
  } : void 0, [s, m]),
456
456
  limit: 1
457
- }), Ne = Me.some((e) => e.productId === s && e.workspaceId === m && e.status === "ACTIVE"), { createReview: _, loading: v } = ee(), { updateReview: y, loading: Pe } = ie(), { deleteReview: b, loading: Fe } = te(), { markHelpful: Ie, loading: Le } = ne(), x = xe(), [S, Re] = o(!1), [C, ze] = o(!1), [Be, w] = o(!1), [T, E] = o(null), [D, O] = o(null), [Ve, k] = o("success"), [A, j] = o(!1), [M, N] = o(""), [P, F] = o(""), [I, L] = o(5), [He, R] = o(null), [Ue, z] = o(!1), { data: We, loading: Ge, error: B, refetch: V } = re({
457
+ }), Ne = Me.some((e) => e.productId === s && e.workspaceId === m && e.status === "ACTIVE"), { createReview: _, loading: v } = ee(), { updateReview: y, loading: Pe } = ie(), { deleteReview: b, loading: Fe } = te(), { markHelpful: Ie, loading: Le } = ne(), x = xe(), [S, Re] = o(!1), [C, ze] = o(!1), [Be, w] = o(!1), [Ve, T] = o(null), [E, D] = o(null), [He, O] = o("success"), [k, A] = o(!1), [j, M] = o(""), [N, P] = o(""), [F, I] = o(5), [Ue, L] = o(null), [We, R] = o(!1), { data: Ge, loading: Ke, error: z, refetch: B } = re({
458
458
  id: s,
459
459
  slug: s,
460
460
  includeReviews: !0,
@@ -462,139 +462,139 @@ var Se = (e, t) => ({
462
462
  includeRelated: !0,
463
463
  relatedLimit: 4,
464
464
  includeVersions: !0
465
- }), H = We, U = H?.product, W = H?.publisher, G = Oe.some((e) => e.productId === U?.id), Ke = a(async () => {
466
- if (U) {
467
- if (E(null), G) {
465
+ }), V = Ge, H = V?.product, U = V?.publisher, W = Oe.some((e) => e.productId === H?.id), qe = a(async () => {
466
+ if (H) {
467
+ if (T(null), W) {
468
468
  u(`${p}/cart`);
469
469
  return;
470
470
  }
471
471
  try {
472
- await h(Se(U, W), void 0, 1);
472
+ await h(Se(H, U), void 0, 1);
473
473
  } catch (e) {
474
- console.error("Failed to add product to cart:", e), E("Failed to add this product to cart. Please try again.");
474
+ console.error("Failed to add product to cart:", e), T("Failed to add this product to cart. Please try again.");
475
475
  }
476
476
  }
477
477
  }, [
478
+ H,
478
479
  U,
479
- W,
480
480
  h,
481
- G,
481
+ W,
482
482
  u,
483
483
  p
484
- ]), qe = a(async () => {
485
- if (U) {
486
- E(null), w(!0);
484
+ ]), Je = a(async () => {
485
+ if (H) {
486
+ T(null), w(!0);
487
487
  try {
488
- let e = U.price || 0, t = await Ae({
488
+ let e = H.price || 0, t = await Ae({
489
489
  total: e,
490
490
  lineItems: [{
491
- productId: U.id,
492
- name: U.name,
491
+ productId: H.id,
492
+ name: H.name,
493
493
  quantity: 1,
494
494
  unitPrice: e,
495
495
  subtotal: e,
496
- itemType: U.nature?.toLowerCase() || "digital",
497
- pricingModel: U.pricingModel || "PAID_ONETIME"
496
+ itemType: H.nature?.toLowerCase() || "digital",
497
+ pricingModel: H.pricingModel || "PAID_ONETIME"
498
498
  }],
499
499
  billingAccountId: ""
500
500
  });
501
- t?.id ? u(`/billing/checkout/store/${t.id}${De.search}`) : (console.error("Failed to create order"), E("Failed to create order. Please try again."), w(!1));
501
+ t?.id ? u(`/billing/checkout/store/${t.id}${De.search}`) : (console.error("Failed to create order"), T("Failed to create order. Please try again."), w(!1));
502
502
  } catch (e) {
503
- console.error("Buy Now error:", e), E(e instanceof Error ? e.message : "Failed to start checkout"), w(!1);
503
+ console.error("Buy Now error:", e), T(e instanceof Error ? e.message : "Failed to start checkout"), w(!1);
504
504
  }
505
505
  }
506
506
  }, [
507
- U,
507
+ H,
508
508
  Ae,
509
509
  u
510
- ]), Je = a(() => {
511
- U && z(!0);
512
- }, [U]), Ye = de(U);
513
- Ye.current = U;
514
- let Xe = de(x);
515
- Xe.current = x, le(() => {
516
- let e = Ye.current;
517
- e && Xe.current.emit("store.product.viewed", {
510
+ ]), Ye = a(() => {
511
+ H && R(!0);
512
+ }, [H]), Xe = de(H);
513
+ Xe.current = H;
514
+ let Ze = de(x);
515
+ Ze.current = x, le(() => {
516
+ let e = Xe.current;
517
+ e && Ze.current.emit("store.product.viewed", {
518
518
  productId: e.id,
519
519
  productSlug: e.slug,
520
520
  productType: e.type,
521
521
  pricingModel: e.pricingModel
522
522
  });
523
- }, [U?.id]);
524
- let Ze = a((e, t) => {
525
- U && (x.emit("store.product.installed", {
526
- productId: U.id,
523
+ }, [H?.id]);
524
+ let Qe = a((e, t) => {
525
+ H && (x.emit("store.product.installed", {
526
+ productId: H.id,
527
527
  workspaceId: e
528
- }), console.log(`Successfully installed ${U.name} to workspace ${t} (${e})`), g());
528
+ }), console.log(`Successfully installed ${H.name} to workspace ${t} (${e})`), g());
529
529
  }, [
530
- U,
530
+ H,
531
531
  x,
532
532
  g
533
- ]), Qe = a((e) => {
533
+ ]), $e = a((e) => {
534
534
  console.error("Installation failed:", e.message);
535
- }, []), $e = a(() => {
536
- N(H?.userReview?.title ?? ""), F(H?.userReview?.comment ?? ""), L(H?.userReview?.rating ?? 5), O(null), k("success"), j(!0);
537
- }, [H?.userReview]), et = a(async () => {
538
- if (!U) return;
539
- if (I < 1 || I > 5) {
540
- k("error"), O("Choose a rating from 1 to 5 stars.");
535
+ }, []), et = a(() => {
536
+ M(V?.userReview?.title ?? ""), P(V?.userReview?.comment ?? ""), I(V?.userReview?.rating ?? 5), D(null), O("success"), A(!0);
537
+ }, [V?.userReview]), tt = a(async () => {
538
+ if (!H) return;
539
+ if (F < 1 || F > 5) {
540
+ O("error"), D("Choose a rating from 1 to 5 stars.");
541
541
  return;
542
542
  }
543
543
  let e = {
544
- productId: U.id,
545
- rating: I,
546
- title: M.trim() || void 0,
547
- comment: P.trim() || void 0
544
+ productId: H.id,
545
+ rating: F,
546
+ title: j.trim() || void 0,
547
+ comment: N.trim() || void 0
548
548
  };
549
- if (!(H?.userReview ? await y(H.userReview.id, {
549
+ if (!(V?.userReview ? await y(V.userReview.id, {
550
550
  rating: e.rating,
551
551
  title: e.title,
552
552
  comment: e.comment
553
553
  }) : await _(e))) {
554
- k("error"), O("We could not save your review. Please try again.");
554
+ O("error"), D("We could not save your review. Please try again.");
555
555
  return;
556
556
  }
557
- k("success"), O(H?.userReview ? "Your review was updated." : "Your review was submitted."), j(!1), x.emit("store.review.submitted", {
558
- productId: U.id,
559
- rating: I
560
- }), await V();
557
+ O("success"), D(V?.userReview ? "Your review was updated." : "Your review was submitted."), A(!1), x.emit("store.review.submitted", {
558
+ productId: H.id,
559
+ rating: F
560
+ }), await B();
561
561
  }, [
562
562
  x,
563
563
  _,
564
- U,
565
- H?.userReview,
566
- V,
567
- P,
568
- I,
569
- M,
564
+ H,
565
+ V?.userReview,
566
+ B,
567
+ N,
568
+ F,
569
+ j,
570
570
  y
571
- ]), tt = a(async () => {
572
- if (H?.userReview && (se("medium"), await oe({
571
+ ]), nt = a(async () => {
572
+ if (V?.userReview && (se("medium"), await oe({
573
573
  title: "Delete review",
574
574
  message: "Are you sure you want to remove your review?",
575
575
  okButtonTitle: "Delete",
576
576
  cancelButtonTitle: "Cancel"
577
577
  }) !== !1)) {
578
- if (!await b(H.userReview.id)) {
579
- k("error"), O("We could not remove your review. Please try again."), i("error");
578
+ if (!await b(V.userReview.id)) {
579
+ O("error"), D("We could not remove your review. Please try again."), i("error");
580
580
  return;
581
581
  }
582
- k("success"), O("Your review was removed."), j(!1), N(""), F(""), L(5), i("success"), await V();
582
+ O("success"), D("Your review was removed."), A(!1), M(""), P(""), I(5), i("success"), await B();
583
583
  }
584
584
  }, [
585
585
  b,
586
- H?.userReview,
587
- V
588
- ]), nt = a(async (e) => {
589
- R(e), await Ie(e) && await V(), R(null);
590
- }, [Ie, V]);
591
- if (Ge) return /* @__PURE__ */ d(Te, {});
592
- if (B) return /* @__PURE__ */ d(Ee, {
593
- error: B,
594
- onRetry: V,
586
+ V?.userReview,
587
+ B
588
+ ]), rt = a(async (e) => {
589
+ L(e), await Ie(e) && await B(), L(null);
590
+ }, [Ie, B]);
591
+ if (Ke) return /* @__PURE__ */ d(Te, {});
592
+ if (z) return /* @__PURE__ */ d(Ee, {
593
+ error: z,
594
+ onRetry: B,
595
595
  onBack: () => u(`${p}/marketplace`)
596
596
  });
597
- if (!H?.product) return /* @__PURE__ */ d("div", {
597
+ if (!V?.product) return /* @__PURE__ */ d("div", {
598
598
  className: "flex h-full items-center justify-center",
599
599
  children: /* @__PURE__ */ f("div", {
600
600
  className: "text-center",
@@ -616,33 +616,33 @@ var Se = (e, t) => ({
616
616
  ]
617
617
  })
618
618
  });
619
- let { reviews: K, reviewsCount: rt, relatedProducts: q, ratingDistribution: J, isPurchased: Y, userEntitlement: X } = H, Z = U, Q = J ? J.fiveStars + J.fourStars + J.threeStars + J.twoStars + J.oneStar : 0, it = J ? [
619
+ let { reviews: G, reviewsCount: it, relatedProducts: K, ratingDistribution: q, isPurchased: J, userEntitlement: Y } = V, X = H, Z = q ? q.fiveStars + q.fourStars + q.threeStars + q.twoStars + q.oneStar : 0, at = q ? [
620
620
  {
621
621
  stars: 5,
622
- count: J.fiveStars,
623
- percentage: Q > 0 ? J.fiveStars / Q * 100 : 0
622
+ count: q.fiveStars,
623
+ percentage: Z > 0 ? q.fiveStars / Z * 100 : 0
624
624
  },
625
625
  {
626
626
  stars: 4,
627
- count: J.fourStars,
628
- percentage: Q > 0 ? J.fourStars / Q * 100 : 0
627
+ count: q.fourStars,
628
+ percentage: Z > 0 ? q.fourStars / Z * 100 : 0
629
629
  },
630
630
  {
631
631
  stars: 3,
632
- count: J.threeStars,
633
- percentage: Q > 0 ? J.threeStars / Q * 100 : 0
632
+ count: q.threeStars,
633
+ percentage: Z > 0 ? q.threeStars / Z * 100 : 0
634
634
  },
635
635
  {
636
636
  stars: 2,
637
- count: J.twoStars,
638
- percentage: Q > 0 ? J.twoStars / Q * 100 : 0
637
+ count: q.twoStars,
638
+ percentage: Z > 0 ? q.twoStars / Z * 100 : 0
639
639
  },
640
640
  {
641
641
  stars: 1,
642
- count: J.oneStar,
643
- percentage: Q > 0 ? J.oneStar / Q * 100 : 0
642
+ count: q.oneStar,
643
+ percentage: Z > 0 ? q.oneStar / Z * 100 : 0
644
644
  }
645
- ] : [], at = (Z.requiredPermissions || []).filter((e) => e && e !== "[object Object]"), ot = Z.integrationDeps || [], st = () => Z.pricingModel === "FREE" ? "Free" : Z.pricingModel === "SUBSCRIPTION" ? `${r(Z.price, Z.currency)}/mo` : r(Z.price, Z.currency), $ = Z.pricingModel === "FREE" || Z.price === 0;
645
+ ] : [], Q = (X.requiredPermissions || []).filter((e) => e && e !== "[object Object]"), ot = X.integrationDeps || [], st = () => X.pricingModel === "FREE" ? "Free" : X.pricingModel === "SUBSCRIPTION" ? `${r(X.price, X.currency)}/mo` : r(X.price, X.currency), $ = X.pricingModel === "FREE" || X.price === 0;
646
646
  return /* @__PURE__ */ f("div", {
647
647
  className: "h-full overflow-y-auto bg-bg-base",
648
648
  children: [
@@ -663,27 +663,27 @@ var Se = (e, t) => ({
663
663
  }),
664
664
  /* @__PURE__ */ d("h1", {
665
665
  className: "mb-4 text-4xl font-normal leading-tight text-text-primary lg:text-5xl",
666
- children: Z.name
666
+ children: X.name
667
667
  }),
668
668
  /* @__PURE__ */ f("div", {
669
669
  className: "mb-2",
670
- children: [W?.websiteUrl ? /* @__PURE__ */ d("a", {
671
- href: W.websiteUrl,
670
+ children: [U?.websiteUrl ? /* @__PURE__ */ d("a", {
671
+ href: U.websiteUrl,
672
672
  target: "_blank",
673
673
  rel: "noreferrer",
674
674
  className: "text-base font-medium text-text-link hover:underline",
675
- children: W.name
675
+ children: U.name
676
676
  }) : /* @__PURE__ */ d("span", {
677
677
  className: "text-base font-medium text-text-primary",
678
- children: W?.name || Z.authorName || "Unknown Publisher"
679
- }), W?.isVerified && /* @__PURE__ */ d(c, { className: "ml-1.5 inline size-4 text-status-success-text" })]
678
+ children: U?.name || X.authorName || "Unknown Publisher"
679
+ }), U?.isVerified && /* @__PURE__ */ d(c, { className: "ml-1.5 inline size-4 text-status-success-text" })]
680
680
  }),
681
681
  /* @__PURE__ */ f("p", {
682
682
  className: "mb-6 text-sm text-text-muted",
683
683
  children: [
684
- Z.category && /* @__PURE__ */ d("span", { children: Z.category }),
685
- Z.category && " · ",
686
- n(Z.downloads),
684
+ X.category && /* @__PURE__ */ d("span", { children: X.category }),
685
+ X.category && " · ",
686
+ n(X.downloads),
687
687
  "+ downloads"
688
688
  ]
689
689
  }),
@@ -692,13 +692,13 @@ var Se = (e, t) => ({
692
692
  children: [
693
693
  /* @__PURE__ */ d("div", {
694
694
  className: "flex size-12 items-center justify-center overflow-hidden rounded-xl bg-bg-sunken",
695
- children: Z.icon ? /* @__PURE__ */ d("img", {
696
- src: Z.icon,
695
+ children: X.icon ? /* @__PURE__ */ d("img", {
696
+ src: X.icon,
697
697
  alt: "",
698
698
  className: "size-full object-cover"
699
699
  }) : /* @__PURE__ */ d("span", {
700
700
  className: "text-lg font-bold text-text-muted",
701
- children: Z.name.charAt(0)
701
+ children: X.name.charAt(0)
702
702
  })
703
703
  }),
704
704
  /* @__PURE__ */ f("div", {
@@ -706,12 +706,12 @@ var Se = (e, t) => ({
706
706
  children: [
707
707
  /* @__PURE__ */ d("span", {
708
708
  className: "text-sm font-medium text-text-primary",
709
- children: (Z.rating || 0).toFixed(1)
709
+ children: (X.rating || 0).toFixed(1)
710
710
  }),
711
711
  /* @__PURE__ */ d(l, { className: "size-4 fill-current text-status-warning-text" }),
712
712
  /* @__PURE__ */ f("span", {
713
713
  className: "ml-1 text-xs text-text-muted",
714
- children: [n(rt || Z.reviewCount), " reviews"]
714
+ children: [n(it || X.reviewCount), " reviews"]
715
715
  })
716
716
  ]
717
717
  }),
@@ -719,7 +719,7 @@ var Se = (e, t) => ({
719
719
  className: "border-l border-border-default pl-4",
720
720
  children: [/* @__PURE__ */ f("span", {
721
721
  className: "text-sm font-medium text-text-primary",
722
- children: [n(Z.downloads), "+"]
722
+ children: [n(X.downloads), "+"]
723
723
  }), /* @__PURE__ */ d("p", {
724
724
  className: "text-xs text-text-muted",
725
725
  children: "Downloads"
@@ -729,7 +729,7 @@ var Se = (e, t) => ({
729
729
  className: "border-l border-border-default pl-4",
730
730
  children: [/* @__PURE__ */ d("span", {
731
731
  className: "rounded bg-bg-sunken px-2 py-1 text-xs font-medium text-text-primary",
732
- children: Z.type
732
+ children: X.type
733
733
  }), /* @__PURE__ */ d("p", {
734
734
  className: "mt-0.5 text-xs text-text-muted",
735
735
  children: "Type"
@@ -737,10 +737,10 @@ var Se = (e, t) => ({
737
737
  })
738
738
  ]
739
739
  }),
740
- T && /* @__PURE__ */ d("div", {
740
+ Ve && /* @__PURE__ */ d("div", {
741
741
  role: "alert",
742
742
  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",
743
- children: T
743
+ children: Ve
744
744
  }),
745
745
  /* @__PURE__ */ f("div", {
746
746
  className: "mb-6 flex items-center gap-3",
@@ -759,49 +759,49 @@ var Se = (e, t) => ({
759
759
  "aria-hidden": "true",
760
760
  children: /* @__PURE__ */ d("polyline", { points: "2,8 6,12 14,4" })
761
761
  }), "Installed"]
762
- }) : Y && !$ ? /* @__PURE__ */ d("button", {
762
+ }) : J && !$ ? /* @__PURE__ */ d("button", {
763
763
  type: "button",
764
- onClick: Je,
764
+ onClick: Ye,
765
765
  className: "cursor-pointer rounded-full bg-action-primary-bg px-8 py-3 font-medium text-action-primary-text transition-opacity hover:opacity-90",
766
766
  children: "Install to Workspace"
767
767
  }) : $ ? /* @__PURE__ */ d("button", {
768
768
  type: "button",
769
- onClick: Je,
769
+ onClick: Ye,
770
770
  className: "cursor-pointer rounded-full bg-action-primary-bg px-8 py-3 font-medium text-action-primary-text transition-opacity hover:opacity-90",
771
771
  children: "Install"
772
772
  }) : /* @__PURE__ */ d("button", {
773
773
  type: "button",
774
- onClick: qe,
774
+ onClick: Je,
775
775
  disabled: Be || je,
776
776
  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",
777
777
  children: Be || je ? /* @__PURE__ */ f(_e, { children: [/* @__PURE__ */ d(me, { className: "size-4 animate-spin" }), "Processing…"] }) : `Buy ${st()}`
778
- }), !$ && !Y && /* @__PURE__ */ f("button", {
778
+ }), !$ && !J && /* @__PURE__ */ f("button", {
779
779
  type: "button",
780
- onClick: Ke,
780
+ onClick: qe,
781
781
  disabled: ke,
782
782
  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",
783
- children: [ke ? /* @__PURE__ */ d(me, { className: "size-4 animate-spin" }) : G ? /* @__PURE__ */ d(pe, { className: "size-4 text-status-success-text" }) : /* @__PURE__ */ d(ge, { className: "size-4" }), G ? "In Cart" : "Add to Cart"]
783
+ children: [ke ? /* @__PURE__ */ d(me, { className: "size-4 animate-spin" }) : W ? /* @__PURE__ */ d(pe, { className: "size-4 text-status-success-text" }) : /* @__PURE__ */ d(ge, { className: "size-4" }), W ? "In Cart" : "Add to Cart"]
784
784
  })]
785
785
  }),
786
786
  /* @__PURE__ */ f("p", {
787
787
  className: "flex items-center gap-2 text-xs text-text-muted",
788
788
  children: [/* @__PURE__ */ d(he, { className: "size-4" }), "This app is available for your workspace"]
789
789
  }),
790
- X && /* @__PURE__ */ f("p", {
790
+ Y && /* @__PURE__ */ f("p", {
791
791
  className: "mt-2 flex items-center gap-2 text-xs text-text-muted",
792
792
  children: [
793
793
  /* @__PURE__ */ d(c, { className: "size-4 text-status-success-text" }),
794
794
  "License: ",
795
- X.status,
796
- X.expiresAt && ` (Expires: ${new Date(X.expiresAt).toLocaleDateString()})`
795
+ Y.status,
796
+ Y.expiresAt && ` (Expires: ${new Date(Y.expiresAt).toLocaleDateString()})`
797
797
  ]
798
798
  })
799
799
  ]
800
800
  }), /* @__PURE__ */ d("div", {
801
801
  className: "relative flex-1 bg-bg-sunken lg:min-h-[500px]",
802
- children: Z.screenshots && Z.screenshots.length > 0 ? /* @__PURE__ */ d("img", {
803
- src: Z.screenshots[0],
804
- alt: `${Z.name} screenshot`,
802
+ children: X.screenshots && X.screenshots.length > 0 ? /* @__PURE__ */ d("img", {
803
+ src: X.screenshots[0],
804
+ alt: `${X.name} screenshot`,
805
805
  className: "size-full object-cover"
806
806
  }) : /* @__PURE__ */ d("div", {
807
807
  className: "flex h-full min-h-[300px] items-center justify-center",
@@ -809,7 +809,7 @@ var Se = (e, t) => ({
809
809
  className: "text-center",
810
810
  children: [/* @__PURE__ */ d("div", {
811
811
  className: "mx-auto mb-4 flex size-24 items-center justify-center rounded-2xl bg-bg-surface text-4xl font-bold text-text-muted",
812
- children: Z.name.charAt(0)
812
+ children: X.name.charAt(0)
813
813
  }), /* @__PURE__ */ d("p", {
814
814
  className: "text-sm text-text-muted",
815
815
  children: "No preview available"
@@ -827,11 +827,11 @@ var Se = (e, t) => ({
827
827
  children: [/* @__PURE__ */ f("div", {
828
828
  className: "flex-1 lg:max-w-3xl",
829
829
  children: [
830
- Z.screenshots && Z.screenshots.length > 1 && /* @__PURE__ */ d("section", {
830
+ X.screenshots && X.screenshots.length > 1 && /* @__PURE__ */ d("section", {
831
831
  className: "mb-8",
832
832
  children: /* @__PURE__ */ d("div", {
833
833
  className: "flex gap-4 overflow-x-auto pb-4",
834
- children: Z.screenshots.map((e, t) => /* @__PURE__ */ d("div", {
834
+ children: X.screenshots.map((e, t) => /* @__PURE__ */ d("div", {
835
835
  className: "relative h-64 w-96 flex-shrink-0 overflow-hidden rounded-xl bg-bg-sunken",
836
836
  children: /* @__PURE__ */ d("img", {
837
837
  src: e,
@@ -855,17 +855,17 @@ var Se = (e, t) => ({
855
855
  className: "text-sm leading-relaxed text-text-secondary",
856
856
  children: [/* @__PURE__ */ d("p", {
857
857
  className: S ? "" : "line-clamp-4",
858
- children: Z.longDescription || Z.description || "No description available."
859
- }), ((Z.longDescription || Z.description)?.length ?? 0) > 200 && /* @__PURE__ */ d("button", {
858
+ children: X.longDescription || X.description || "No description available."
859
+ }), ((X.longDescription || X.description)?.length ?? 0) > 200 && /* @__PURE__ */ d("button", {
860
860
  type: "button",
861
861
  onClick: () => Re(!S),
862
862
  className: "cursor-pointer mt-3 text-sm font-medium text-text-link",
863
863
  children: S ? "Show less" : "Show more"
864
864
  })]
865
865
  }),
866
- Z.tags && Z.tags.length > 0 && /* @__PURE__ */ d("div", {
866
+ X.tags && X.tags.length > 0 && /* @__PURE__ */ d("div", {
867
867
  className: "mt-4 flex flex-wrap gap-2",
868
- children: Z.tags.map((e) => /* @__PURE__ */ d("span", {
868
+ children: X.tags.map((e) => /* @__PURE__ */ d("span", {
869
869
  className: "rounded-full border border-border-default px-3 py-1.5 text-xs text-text-muted transition-colors hover:bg-bg-sunken",
870
870
  children: e
871
871
  }, e))
@@ -884,14 +884,14 @@ var Se = (e, t) => ({
884
884
  }),
885
885
  /* @__PURE__ */ f("div", {
886
886
  className: "rounded-xl border border-border-default bg-bg-surface p-5",
887
- children: [K && K.length > 0 ? /* @__PURE__ */ f("div", {
887
+ children: [G && G.length > 0 ? /* @__PURE__ */ f("div", {
888
888
  className: "flex items-start gap-8",
889
889
  children: [/* @__PURE__ */ f("div", {
890
890
  className: "text-center",
891
891
  children: [
892
892
  /* @__PURE__ */ d("p", {
893
893
  className: "text-5xl font-light text-text-primary",
894
- children: (Z.rating || 0).toFixed(1)
894
+ children: (X.rating || 0).toFixed(1)
895
895
  }),
896
896
  /* @__PURE__ */ d("div", {
897
897
  className: "my-2 flex justify-center gap-0.5",
@@ -901,16 +901,16 @@ var Se = (e, t) => ({
901
901
  3,
902
902
  4,
903
903
  5
904
- ].map((e) => /* @__PURE__ */ d(l, { className: `size-4 ${e <= Math.round(Z.rating || 0) ? "fill-current text-status-warning-text" : "text-text-muted"}` }, e))
904
+ ].map((e) => /* @__PURE__ */ d(l, { className: `size-4 ${e <= Math.round(X.rating || 0) ? "fill-current text-status-warning-text" : "text-text-muted"}` }, e))
905
905
  }),
906
906
  /* @__PURE__ */ f("p", {
907
907
  className: "text-sm text-text-muted",
908
- children: [n(rt || Z.reviewCount), " reviews"]
908
+ children: [n(it || X.reviewCount), " reviews"]
909
909
  })
910
910
  ]
911
- }), it.length > 0 && /* @__PURE__ */ d("div", {
911
+ }), at.length > 0 && /* @__PURE__ */ d("div", {
912
912
  className: "flex-1 space-y-1.5",
913
- children: it.map((e) => /* @__PURE__ */ d(Ce, { ...e }, e.stars))
913
+ children: at.map((e) => /* @__PURE__ */ d(Ce, { ...e }, e.stars))
914
914
  })]
915
915
  }) : /* @__PURE__ */ f("div", {
916
916
  className: "flex flex-col items-center justify-center py-6 text-center",
@@ -936,18 +936,18 @@ var Se = (e, t) => ({
936
936
  ]
937
937
  }), /* @__PURE__ */ f("div", {
938
938
  className: "mt-6 border-t border-border-default pt-4",
939
- children: [D && /* @__PURE__ */ d("p", {
940
- role: Ve === "success" ? "status" : "alert",
941
- className: `mb-3 rounded-lg px-3 py-2 text-sm ${Ve === "success" ? "bg-status-success-bg-subtle text-status-success-text" : "bg-status-error-bg-subtle text-status-error-text"}`,
942
- children: D
943
- }), Y || H?.userReview ? /* @__PURE__ */ f("div", {
939
+ children: [E && /* @__PURE__ */ d("p", {
940
+ role: He === "success" ? "status" : "alert",
941
+ className: `mb-3 rounded-lg px-3 py-2 text-sm ${He === "success" ? "bg-status-success-bg-subtle text-status-success-text" : "bg-status-error-bg-subtle text-status-error-text"}`,
942
+ children: E
943
+ }), J || V?.userReview ? /* @__PURE__ */ f("div", {
944
944
  className: "space-y-4",
945
945
  children: [/* @__PURE__ */ d("button", {
946
946
  type: "button",
947
- onClick: () => A ? j(!1) : $e(),
947
+ onClick: () => k ? A(!1) : et(),
948
948
  className: "w-full cursor-pointer py-2 text-center text-sm font-medium text-text-primary transition-colors hover:text-text-link",
949
- children: H?.userReview ? A ? "Cancel review editing" : "Edit your review" : A ? "Cancel review" : "Write a Review"
950
- }), A && /* @__PURE__ */ f("div", {
949
+ children: V?.userReview ? k ? "Cancel review editing" : "Edit your review" : k ? "Cancel review" : "Write a Review"
950
+ }), k && /* @__PURE__ */ f("div", {
951
951
  className: "rounded-xl border border-border-default bg-bg-sunken p-4",
952
952
  children: [
953
953
  /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
@@ -963,8 +963,8 @@ var Se = (e, t) => ({
963
963
  5
964
964
  ].map((e) => /* @__PURE__ */ f("button", {
965
965
  type: "button",
966
- onClick: () => L(e),
967
- className: `cursor-pointer rounded-full border px-3 py-1.5 text-sm transition-colors ${I === 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"}`,
966
+ onClick: () => I(e),
967
+ className: `cursor-pointer rounded-full border px-3 py-1.5 text-sm transition-colors ${F === 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"}`,
968
968
  children: [e, " ★"]
969
969
  }, e))
970
970
  })] }),
@@ -972,8 +972,8 @@ var Se = (e, t) => ({
972
972
  className: "mt-4 block text-sm font-medium text-text-primary",
973
973
  children: ["Title", /* @__PURE__ */ d("input", {
974
974
  "aria-label": "Review title",
975
- value: M,
976
- onChange: (e) => N(e.target.value),
975
+ value: j,
976
+ onChange: (e) => M(e.target.value),
977
977
  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",
978
978
  placeholder: "Summarize your experience"
979
979
  })]
@@ -982,8 +982,8 @@ var Se = (e, t) => ({
982
982
  className: "mt-4 block text-sm font-medium text-text-primary",
983
983
  children: ["Review", /* @__PURE__ */ d("textarea", {
984
984
  "aria-label": "Review body",
985
- value: P,
986
- onChange: (e) => F(e.target.value),
985
+ value: N,
986
+ onChange: (e) => P(e.target.value),
987
987
  rows: 4,
988
988
  required: !0,
989
989
  "aria-required": "true",
@@ -995,13 +995,13 @@ var Se = (e, t) => ({
995
995
  className: "mt-4 flex flex-wrap gap-3",
996
996
  children: [/* @__PURE__ */ d("button", {
997
997
  type: "button",
998
- onClick: et,
998
+ onClick: tt,
999
999
  disabled: v || Pe,
1000
1000
  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",
1001
- children: v || Pe ? "Saving..." : H?.userReview ? "Update Review" : "Submit Review"
1002
- }), H?.userReview && /* @__PURE__ */ d("button", {
1001
+ children: v || Pe ? "Saving..." : V?.userReview ? "Update Review" : "Submit Review"
1002
+ }), V?.userReview && /* @__PURE__ */ d("button", {
1003
1003
  type: "button",
1004
- onClick: tt,
1004
+ onClick: nt,
1005
1005
  disabled: Fe,
1006
1006
  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",
1007
1007
  children: Fe ? "Removing..." : "Delete Review"
@@ -1015,36 +1015,36 @@ var Se = (e, t) => ({
1015
1015
  })]
1016
1016
  })]
1017
1017
  }),
1018
- K && K.length > 0 && /* @__PURE__ */ f("div", {
1018
+ G && G.length > 0 && /* @__PURE__ */ f("div", {
1019
1019
  className: "mt-4 space-y-3",
1020
1020
  children: [/* @__PURE__ */ d("ul", {
1021
1021
  className: "space-y-3",
1022
- children: (C ? K : K.slice(0, 2)).map((e) => /* @__PURE__ */ d("li", { children: /* @__PURE__ */ d(we, {
1022
+ children: (C ? G : G.slice(0, 2)).map((e) => /* @__PURE__ */ d("li", { children: /* @__PURE__ */ d(we, {
1023
1023
  review: e,
1024
- onMarkHelpful: nt,
1025
- markingHelpful: Le && He === e.id
1024
+ onMarkHelpful: rt,
1025
+ markingHelpful: Le && Ue === e.id
1026
1026
  }) }, e.id))
1027
- }), K.length > 2 && /* @__PURE__ */ d("button", {
1027
+ }), G.length > 2 && /* @__PURE__ */ d("button", {
1028
1028
  type: "button",
1029
1029
  onClick: () => ze(!C),
1030
1030
  className: "cursor-pointer text-sm font-medium text-text-link",
1031
- children: C ? "Show less" : `Show all ${K.length} reviews`
1031
+ children: C ? "Show less" : `Show all ${G.length} reviews`
1032
1032
  })]
1033
1033
  }),
1034
- (!K || K.length === 0) && /* @__PURE__ */ d("p", {
1034
+ (!G || G.length === 0) && /* @__PURE__ */ d("p", {
1035
1035
  className: "mt-4 text-sm text-text-muted",
1036
1036
  children: "No reviews yet. Be the first to review!"
1037
1037
  })
1038
1038
  ]
1039
1039
  }),
1040
- at.length > 0 && /* @__PURE__ */ f("section", {
1040
+ Q.length > 0 && /* @__PURE__ */ f("section", {
1041
1041
  className: "mb-8",
1042
1042
  children: [/* @__PURE__ */ d("h2", {
1043
1043
  className: "mb-4 text-lg font-medium text-text-primary",
1044
1044
  children: "Required Permissions"
1045
1045
  }), /* @__PURE__ */ d("div", {
1046
1046
  className: "space-y-2",
1047
- children: at.map((e) => /* @__PURE__ */ f("div", {
1047
+ children: Q.map((e) => /* @__PURE__ */ f("div", {
1048
1048
  className: "flex items-center gap-3 rounded-lg bg-bg-surface px-4 py-3",
1049
1049
  children: [/* @__PURE__ */ d(c, { className: "size-5 text-status-success-text" }), /* @__PURE__ */ d("span", {
1050
1050
  className: "text-sm text-text-primary",
@@ -1074,47 +1074,47 @@ var Se = (e, t) => ({
1074
1074
  }), /* @__PURE__ */ f("div", {
1075
1075
  className: "grid grid-cols-2 gap-6 md:grid-cols-3",
1076
1076
  children: [
1077
- Z.manifestVersion && /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
1077
+ X.manifestVersion && /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
1078
1078
  className: "text-xs text-text-muted",
1079
1079
  children: "Version"
1080
1080
  }), /* @__PURE__ */ d("p", {
1081
1081
  className: "mt-1 text-sm font-medium text-text-primary",
1082
- children: Z.manifestVersion
1082
+ children: X.manifestVersion
1083
1083
  })] }),
1084
1084
  /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
1085
1085
  className: "text-xs text-text-muted",
1086
1086
  children: "Type"
1087
1087
  }), /* @__PURE__ */ d("p", {
1088
1088
  className: "mt-1 text-sm font-medium text-text-primary",
1089
- children: Z.type
1089
+ children: X.type
1090
1090
  })] }),
1091
- Z.publishedAt && /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
1091
+ X.publishedAt && /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
1092
1092
  className: "text-xs text-text-muted",
1093
1093
  children: "Published"
1094
1094
  }), /* @__PURE__ */ d("p", {
1095
1095
  className: "mt-1 text-sm font-medium text-text-primary",
1096
- children: new Date(Z.publishedAt).toLocaleDateString()
1096
+ children: new Date(X.publishedAt).toLocaleDateString()
1097
1097
  })] }),
1098
1098
  /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
1099
1099
  className: "text-xs text-text-muted",
1100
1100
  children: "Updated"
1101
1101
  }), /* @__PURE__ */ d("p", {
1102
1102
  className: "mt-1 text-sm font-medium text-text-primary",
1103
- children: new Date(Z.updatedAt).toLocaleDateString()
1103
+ children: new Date(X.updatedAt).toLocaleDateString()
1104
1104
  })] }),
1105
- Z.license && /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
1105
+ X.license && /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
1106
1106
  className: "text-xs text-text-muted",
1107
1107
  children: "License"
1108
1108
  }), /* @__PURE__ */ d("p", {
1109
1109
  className: "mt-1 text-sm font-medium text-text-primary",
1110
- children: Z.license
1110
+ children: X.license
1111
1111
  })] }),
1112
- Z.minPlatformVersion && /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
1112
+ X.minPlatformVersion && /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
1113
1113
  className: "text-xs text-text-muted",
1114
1114
  children: "Min Platform Version"
1115
1115
  }), /* @__PURE__ */ d("p", {
1116
1116
  className: "mt-1 text-sm font-medium text-text-primary",
1117
- children: Z.minPlatformVersion
1117
+ children: X.minPlatformVersion
1118
1118
  })] })
1119
1119
  ]
1120
1120
  })]
@@ -1123,7 +1123,7 @@ var Se = (e, t) => ({
1123
1123
  }), /* @__PURE__ */ f("div", {
1124
1124
  className: "w-full lg:w-80",
1125
1125
  children: [
1126
- (Z.documentationUrl || Z.repositoryUrl || W?.email) && /* @__PURE__ */ f("div", {
1126
+ (X.documentationUrl || X.repositoryUrl || U?.email) && /* @__PURE__ */ f("div", {
1127
1127
  className: "mb-6 rounded-xl border border-border-default bg-bg-surface p-4",
1128
1128
  children: [/* @__PURE__ */ d("h3", {
1129
1129
  className: "font-medium text-text-primary",
@@ -1131,29 +1131,29 @@ var Se = (e, t) => ({
1131
1131
  }), /* @__PURE__ */ f("div", {
1132
1132
  className: "mt-3 space-y-2 text-sm",
1133
1133
  children: [
1134
- Z.documentationUrl && /* @__PURE__ */ d("a", {
1135
- href: Z.documentationUrl,
1134
+ X.documentationUrl && /* @__PURE__ */ d("a", {
1135
+ href: X.documentationUrl,
1136
1136
  target: "_blank",
1137
1137
  rel: "noreferrer",
1138
1138
  className: "block text-text-link hover:underline",
1139
1139
  children: "Documentation"
1140
1140
  }),
1141
- Z.repositoryUrl && /* @__PURE__ */ d("a", {
1142
- href: Z.repositoryUrl,
1141
+ X.repositoryUrl && /* @__PURE__ */ d("a", {
1142
+ href: X.repositoryUrl,
1143
1143
  target: "_blank",
1144
1144
  rel: "noreferrer",
1145
1145
  className: "block text-text-link hover:underline",
1146
1146
  children: "Source repository"
1147
1147
  }),
1148
- W?.email && /* @__PURE__ */ d("a", {
1149
- href: `mailto:${W.email}`,
1148
+ U?.email && /* @__PURE__ */ d("a", {
1149
+ href: `mailto:${U.email}`,
1150
1150
  className: "block text-text-link hover:underline",
1151
1151
  children: "Contact publisher"
1152
1152
  })
1153
1153
  ]
1154
1154
  })]
1155
1155
  }),
1156
- W && /* @__PURE__ */ f("div", {
1156
+ U && /* @__PURE__ */ f("div", {
1157
1157
  className: "mb-6 rounded-xl border border-border-default bg-bg-surface p-4",
1158
1158
  children: [
1159
1159
  /* @__PURE__ */ d("h3", {
@@ -1162,14 +1162,14 @@ var Se = (e, t) => ({
1162
1162
  }),
1163
1163
  /* @__PURE__ */ d("p", {
1164
1164
  className: "mt-2 text-sm text-text-primary",
1165
- children: W.name
1165
+ children: U.name
1166
1166
  }),
1167
- W.bio && /* @__PURE__ */ d("p", {
1167
+ U.bio && /* @__PURE__ */ d("p", {
1168
1168
  className: "mt-2 text-sm text-text-muted",
1169
- children: W.bio
1169
+ children: U.bio
1170
1170
  }),
1171
- W.websiteUrl && /* @__PURE__ */ d("a", {
1172
- href: W.websiteUrl,
1171
+ U.websiteUrl && /* @__PURE__ */ d("a", {
1172
+ href: U.websiteUrl,
1173
1173
  target: "_blank",
1174
1174
  rel: "noreferrer",
1175
1175
  className: "mt-3 inline-block text-sm text-text-link hover:underline",
@@ -1177,7 +1177,7 @@ var Se = (e, t) => ({
1177
1177
  })
1178
1178
  ]
1179
1179
  }),
1180
- q && q.length > 0 && /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("div", {
1180
+ K && K.length > 0 && /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("div", {
1181
1181
  className: "mb-4 flex items-center justify-between text-left",
1182
1182
  children: /* @__PURE__ */ d("span", {
1183
1183
  className: "font-medium text-text-primary",
@@ -1185,7 +1185,7 @@ var Se = (e, t) => ({
1185
1185
  })
1186
1186
  }), /* @__PURE__ */ d("div", {
1187
1187
  className: "space-y-3",
1188
- children: q.slice(0, 4).map((e) => /* @__PURE__ */ f("button", {
1188
+ children: K.slice(0, 4).map((e) => /* @__PURE__ */ f("button", {
1189
1189
  type: "button",
1190
1190
  onClick: () => u(`${p}/marketplace/product/${e.id}`),
1191
1191
  className: "flex w-full cursor-pointer items-center gap-3 rounded-lg p-2 text-left transition-colors hover:bg-bg-sunken",
@@ -1205,7 +1205,7 @@ var Se = (e, t) => ({
1205
1205
  }),
1206
1206
  /* @__PURE__ */ d("p", {
1207
1207
  className: "text-xs text-text-muted",
1208
- children: W?.name || "Unknown"
1208
+ children: U?.name || "Unknown"
1209
1209
  }),
1210
1210
  (e.reviewCount ?? 0) > 0 && /* @__PURE__ */ f("div", {
1211
1211
  className: "flex items-center gap-1",
@@ -1222,20 +1222,21 @@ var Se = (e, t) => ({
1222
1222
  })]
1223
1223
  })
1224
1224
  }),
1225
- Z && /* @__PURE__ */ d(ce, {
1226
- isOpen: Ue,
1227
- onClose: () => z(!1),
1225
+ X && /* @__PURE__ */ d(ce, {
1226
+ isOpen: We,
1227
+ onClose: () => R(!1),
1228
1228
  app: {
1229
- id: Z.id,
1230
- name: Z.name,
1231
- slug: Z.slug,
1232
- icon: Z.icon,
1233
- type: Z.type,
1234
- version: Z.manifestVersion
1229
+ id: X.id,
1230
+ name: X.name,
1231
+ slug: X.slug,
1232
+ icon: X.icon,
1233
+ type: X.type,
1234
+ version: X.manifestVersion,
1235
+ requiredPermissions: Q
1235
1236
  },
1236
- purchaseState: Y && !$ ? "purchased" : "free",
1237
- onInstallSuccess: Ze,
1238
- onInstallError: Qe
1237
+ purchaseState: J && !$ ? "purchased" : "free",
1238
+ onInstallSuccess: Qe,
1239
+ onInstallError: $e
1239
1240
  })
1240
1241
  ]
1241
1242
  });