@reblu/site-blocks 0.20.0 → 0.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +35 -0
- package/README.md +209 -14
- package/dist/client.cjs +218 -83
- package/dist/client.cjs.map +1 -1
- package/dist/client.d.cts +40 -13
- package/dist/client.d.ts +40 -13
- package/dist/client.js +221 -86
- package/dist/client.js.map +1 -1
- package/dist/index.cjs +620 -321
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +144 -2
- package/dist/index.d.ts +144 -2
- package/dist/index.js +614 -321
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
package/dist/index.cjs
CHANGED
|
@@ -27,9 +27,14 @@ __export(src_exports, {
|
|
|
27
27
|
CartSummary: () => CartSummary,
|
|
28
28
|
CheckoutForm: () => CheckoutForm,
|
|
29
29
|
CheckoutLoginPrompt: () => CheckoutLoginPrompt,
|
|
30
|
+
ContactInterestField: () => ContactInterestField,
|
|
31
|
+
CourseCatalogFilters: () => CourseCatalogFilters,
|
|
30
32
|
CourseDescription: () => CourseDescription,
|
|
31
33
|
DATA_REQUEST_TYPES: () => import_site_contracts.DATA_REQUEST_TYPES,
|
|
34
|
+
DEFAULT_COURSE_CATALOG_FILTERS_LABELS: () => DEFAULT_COURSE_CATALOG_FILTERS_LABELS,
|
|
35
|
+
DEFAULT_COURSE_PRICE_BANDS: () => DEFAULT_COURSE_PRICE_BANDS,
|
|
32
36
|
DEFAULT_INVOICE_COUNTRIES: () => DEFAULT_INVOICE_COUNTRIES,
|
|
37
|
+
DEFAULT_LESSON_PREVIEW_LABELS: () => DEFAULT_LESSON_PREVIEW_LABELS,
|
|
33
38
|
DEFAULT_SHOP_ERROR_FALLBACK_MESSAGE: () => DEFAULT_SHOP_ERROR_FALLBACK_MESSAGE,
|
|
34
39
|
DEFAULT_SHOP_ERROR_MESSAGES: () => DEFAULT_SHOP_ERROR_MESSAGES,
|
|
35
40
|
DEFAULT_SHOP_PRICE_BANDS: () => DEFAULT_SHOP_PRICE_BANDS,
|
|
@@ -39,6 +44,7 @@ __export(src_exports, {
|
|
|
39
44
|
EMPTY_FULL_INVOICE_VALUE: () => EMPTY_FULL_INVOICE_VALUE,
|
|
40
45
|
FaqAccordion: () => FaqAccordion,
|
|
41
46
|
FullInvoiceFields: () => FullInvoiceFields,
|
|
47
|
+
LessonPreview: () => LessonPreview,
|
|
42
48
|
MarkdownRenderer: () => MarkdownRenderer,
|
|
43
49
|
OrderConfirmation: () => OrderConfirmation,
|
|
44
50
|
OrderInvoiceLink: () => OrderInvoiceLink,
|
|
@@ -117,7 +123,9 @@ var DEFAULT_SHOP_ERROR_MESSAGES = {
|
|
|
117
123
|
// REB-73 — checkout refusals before any payment.
|
|
118
124
|
BILLING_DATA_REQUIRED: "Para emitir tu factura necesitamos tu NIF/NIE o un documento de identificaci\xF3n, tu nombre y tu direcci\xF3n de facturaci\xF3n.",
|
|
119
125
|
INVOICING_NOT_READY: "No se puede completar la compra en este momento. Int\xE9ntalo m\xE1s tarde.",
|
|
120
|
-
FULL_INVOICE_UNAVAILABLE: "Esta tienda no emite facturas completas: contin\xFAa sin solicitarla."
|
|
126
|
+
FULL_INVOICE_UNAVAILABLE: "Esta tienda no emite facturas completas: contin\xFAa sin solicitarla.",
|
|
127
|
+
// REB-912 — the code used up its total uses; refused before any payment.
|
|
128
|
+
DISCOUNT_LIMIT_REACHED: "Este c\xF3digo ya ha alcanzado su l\xEDmite de usos"
|
|
121
129
|
};
|
|
122
130
|
var DEFAULT_SHOP_ERROR_FALLBACK_MESSAGE = "No se ha podido completar la operaci\xF3n. Int\xE9ntalo de nuevo.";
|
|
123
131
|
function getShopErrorMessage(code, overrides, fallback = DEFAULT_SHOP_ERROR_FALLBACK_MESSAGE) {
|
|
@@ -13523,13 +13531,129 @@ function CourseDescription({
|
|
|
13523
13531
|
);
|
|
13524
13532
|
}
|
|
13525
13533
|
|
|
13534
|
+
// src/components/lesson-preview.tsx
|
|
13535
|
+
var import_jsx_runtime3 = require("react/jsx-runtime");
|
|
13536
|
+
var DEFAULT_LESSON_PREVIEW_LABELS = {
|
|
13537
|
+
badge: "Vista previa gratuita",
|
|
13538
|
+
player: "V\xEDdeo",
|
|
13539
|
+
duration: "Duraci\xF3n"
|
|
13540
|
+
};
|
|
13541
|
+
function isEmbeddable(url) {
|
|
13542
|
+
try {
|
|
13543
|
+
return new URL(url).protocol === "https:";
|
|
13544
|
+
} catch {
|
|
13545
|
+
return false;
|
|
13546
|
+
}
|
|
13547
|
+
}
|
|
13548
|
+
function clock(seconds) {
|
|
13549
|
+
const whole = Math.round(seconds);
|
|
13550
|
+
const h2 = Math.floor(whole / 3600);
|
|
13551
|
+
const m2 = Math.floor(whole % 3600 / 60);
|
|
13552
|
+
const s2 = whole % 60;
|
|
13553
|
+
const ss = String(s2).padStart(2, "0");
|
|
13554
|
+
return {
|
|
13555
|
+
text: h2 > 0 ? `${h2}:${String(m2).padStart(2, "0")}:${ss}` : `${m2}:${ss}`,
|
|
13556
|
+
iso: `PT${h2 > 0 ? `${h2}H` : ""}${m2}M${s2}S`
|
|
13557
|
+
};
|
|
13558
|
+
}
|
|
13559
|
+
function isVisiblyEmpty2(html5) {
|
|
13560
|
+
if (/<(img|iframe|hr)\b/i.test(html5)) return false;
|
|
13561
|
+
return html5.replace(/<[^>]*>/g, "").trim() === "";
|
|
13562
|
+
}
|
|
13563
|
+
function LessonPreview({
|
|
13564
|
+
lesson,
|
|
13565
|
+
labels: labelOverrides,
|
|
13566
|
+
headingLevel = 2,
|
|
13567
|
+
headingId = "lesson-preview-heading",
|
|
13568
|
+
headingClassName,
|
|
13569
|
+
contentClassName,
|
|
13570
|
+
className
|
|
13571
|
+
}) {
|
|
13572
|
+
const labels = { ...DEFAULT_LESSON_PREVIEW_LABELS, ...labelOverrides };
|
|
13573
|
+
const Tag = `h${headingLevel}`;
|
|
13574
|
+
const video = lesson.video && isEmbeddable(lesson.video.embedUrl) ? lesson.video : null;
|
|
13575
|
+
const html5 = markdownToSafeHtml(lesson.content);
|
|
13576
|
+
const hasBody = html5 !== null && html5 !== "" && !isVisiblyEmpty2(html5);
|
|
13577
|
+
const duration = typeof lesson.durationSeconds === "number" && lesson.durationSeconds > 0 ? clock(lesson.durationSeconds) : null;
|
|
13578
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
|
|
13579
|
+
"article",
|
|
13580
|
+
{
|
|
13581
|
+
"data-slot": "lesson-preview",
|
|
13582
|
+
"aria-labelledby": headingId,
|
|
13583
|
+
className: slotClassName("space-y-6", "", className),
|
|
13584
|
+
children: [
|
|
13585
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("header", { className: "space-y-2", children: [
|
|
13586
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
13587
|
+
"span",
|
|
13588
|
+
{
|
|
13589
|
+
"data-slot": "lesson-preview-badge",
|
|
13590
|
+
className: "inline-flex items-center rounded-full bg-primary/10 px-3 py-1 text-xs font-semibold text-primary",
|
|
13591
|
+
children: labels.badge
|
|
13592
|
+
}
|
|
13593
|
+
),
|
|
13594
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
13595
|
+
Tag,
|
|
13596
|
+
{
|
|
13597
|
+
id: headingId,
|
|
13598
|
+
className: slotClassName("", "text-2xl font-semibold leading-tight", headingClassName),
|
|
13599
|
+
children: lesson.title
|
|
13600
|
+
}
|
|
13601
|
+
),
|
|
13602
|
+
duration && /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("p", { className: "text-sm text-muted-foreground", children: [
|
|
13603
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("span", { className: "sr-only", children: [
|
|
13604
|
+
labels.duration,
|
|
13605
|
+
": "
|
|
13606
|
+
] }),
|
|
13607
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
13608
|
+
"time",
|
|
13609
|
+
{
|
|
13610
|
+
"data-slot": "lesson-preview-duration",
|
|
13611
|
+
dateTime: duration.iso,
|
|
13612
|
+
className: "tabular-nums",
|
|
13613
|
+
children: duration.text
|
|
13614
|
+
}
|
|
13615
|
+
)
|
|
13616
|
+
] })
|
|
13617
|
+
] }),
|
|
13618
|
+
video && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
13619
|
+
"div",
|
|
13620
|
+
{
|
|
13621
|
+
"data-slot": "lesson-preview-player",
|
|
13622
|
+
className: "aspect-video w-full overflow-hidden rounded-xl border border-border bg-black",
|
|
13623
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
13624
|
+
"iframe",
|
|
13625
|
+
{
|
|
13626
|
+
src: video.embedUrl,
|
|
13627
|
+
title: `${labels.player}: ${lesson.title}`,
|
|
13628
|
+
allow: "accelerometer; gyroscope; autoplay; encrypted-media; picture-in-picture; fullscreen",
|
|
13629
|
+
allowFullScreen: true,
|
|
13630
|
+
loading: "lazy",
|
|
13631
|
+
referrerPolicy: "strict-origin-when-cross-origin",
|
|
13632
|
+
className: "size-full border-0"
|
|
13633
|
+
}
|
|
13634
|
+
)
|
|
13635
|
+
}
|
|
13636
|
+
),
|
|
13637
|
+
hasBody && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { "data-slot": "lesson-preview-content", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
13638
|
+
SafeHtml,
|
|
13639
|
+
{
|
|
13640
|
+
html: html5,
|
|
13641
|
+
headingOffset: headingLevel,
|
|
13642
|
+
className: slotClassName("", "text-muted-foreground", contentClassName)
|
|
13643
|
+
}
|
|
13644
|
+
) })
|
|
13645
|
+
]
|
|
13646
|
+
}
|
|
13647
|
+
);
|
|
13648
|
+
}
|
|
13649
|
+
|
|
13526
13650
|
// src/components/treatment.tsx
|
|
13527
13651
|
var import_utils3 = require("@reblu/site-ui/utils");
|
|
13528
13652
|
|
|
13529
13653
|
// src/components/_page-parts.tsx
|
|
13530
13654
|
var import_utils2 = require("@reblu/site-ui/utils");
|
|
13531
13655
|
var import_button_variants = require("@reblu/site-ui/button-variants");
|
|
13532
|
-
var
|
|
13656
|
+
var import_jsx_runtime4 = require("react/jsx-runtime");
|
|
13533
13657
|
var KNOWN_BUTTON_VARIANTS = /* @__PURE__ */ new Set([
|
|
13534
13658
|
"default",
|
|
13535
13659
|
"destructive",
|
|
@@ -13542,11 +13666,11 @@ function toButtonVariant(variant) {
|
|
|
13542
13666
|
return variant && KNOWN_BUTTON_VARIANTS.has(variant) ? variant : "default";
|
|
13543
13667
|
}
|
|
13544
13668
|
function PageHero({ page }) {
|
|
13545
|
-
return /* @__PURE__ */ (0,
|
|
13546
|
-
page.category && /* @__PURE__ */ (0,
|
|
13547
|
-
/* @__PURE__ */ (0,
|
|
13548
|
-
page.subtitle && /* @__PURE__ */ (0,
|
|
13549
|
-
page.coverImageUrl && /* @__PURE__ */ (0,
|
|
13669
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("header", { className: "space-y-4", children: [
|
|
13670
|
+
page.category && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { className: "inline-flex items-center rounded-full bg-secondary px-3 py-1 text-sm font-medium text-secondary-foreground", children: page.category.name }),
|
|
13671
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("h1", { className: "text-4xl font-bold tracking-tight", children: page.title }),
|
|
13672
|
+
page.subtitle && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("p", { className: "text-lg text-muted-foreground", children: page.subtitle }),
|
|
13673
|
+
page.coverImageUrl && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { className: "relative aspect-[21/9] w-full overflow-hidden rounded-xl bg-muted", children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
13550
13674
|
"img",
|
|
13551
13675
|
{
|
|
13552
13676
|
src: page.coverImageUrl,
|
|
@@ -13560,7 +13684,7 @@ function PageHero({ page }) {
|
|
|
13560
13684
|
function SectionCta({ section }) {
|
|
13561
13685
|
if (!section.ctaLabel || !section.ctaUrl) return null;
|
|
13562
13686
|
const variant = toButtonVariant(section.ctaVariant);
|
|
13563
|
-
return /* @__PURE__ */ (0,
|
|
13687
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { className: "pt-2", children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
13564
13688
|
"a",
|
|
13565
13689
|
{
|
|
13566
13690
|
href: section.ctaUrl,
|
|
@@ -13575,46 +13699,46 @@ function SectionCta({ section }) {
|
|
|
13575
13699
|
}
|
|
13576
13700
|
function SectionImages({ section }) {
|
|
13577
13701
|
if (section.images.length === 0) return null;
|
|
13578
|
-
return /* @__PURE__ */ (0,
|
|
13579
|
-
/* @__PURE__ */ (0,
|
|
13580
|
-
img.caption && /* @__PURE__ */ (0,
|
|
13702
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { className: (0, import_utils2.cn)("grid gap-4", section.images.length > 1 ? "sm:grid-cols-2" : "grid-cols-1"), children: section.images.map((img) => /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("figure", { className: "space-y-1", children: [
|
|
13703
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { className: "relative aspect-video w-full overflow-hidden rounded-lg bg-muted", children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("img", { src: img.url, alt: img.alt, loading: "lazy", className: "h-full w-full object-cover" }) }),
|
|
13704
|
+
img.caption && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("figcaption", { className: "text-sm text-muted-foreground", children: img.caption })
|
|
13581
13705
|
] }, `${img.url}-${img.order}`)) });
|
|
13582
13706
|
}
|
|
13583
13707
|
function PageSectionBlock({ section }) {
|
|
13584
13708
|
const imageFirst = section.layout === "IMAGE_TEXT";
|
|
13585
13709
|
const sideBySide = section.layout === "TEXT_IMAGE" || section.layout === "IMAGE_TEXT";
|
|
13586
13710
|
const hasImages = section.images.length > 0;
|
|
13587
|
-
const body3 = /* @__PURE__ */ (0,
|
|
13588
|
-
section.heading && /* @__PURE__ */ (0,
|
|
13589
|
-
/* @__PURE__ */ (0,
|
|
13590
|
-
/* @__PURE__ */ (0,
|
|
13711
|
+
const body3 = /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("div", { className: "space-y-4", children: [
|
|
13712
|
+
section.heading && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("h2", { className: "text-2xl font-bold", children: section.heading }),
|
|
13713
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SafeHtml, { html: sanitizeHtml(section.contentHtml), headingOffset: 2 }),
|
|
13714
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SectionCta, { section })
|
|
13591
13715
|
] });
|
|
13592
13716
|
if (sideBySide && hasImages) {
|
|
13593
|
-
return /* @__PURE__ */ (0,
|
|
13594
|
-
/* @__PURE__ */ (0,
|
|
13717
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("section", { className: "grid items-center gap-8 md:grid-cols-2", children: imageFirst ? /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
|
|
13718
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SectionImages, { section }),
|
|
13595
13719
|
body3
|
|
13596
|
-
] }) : /* @__PURE__ */ (0,
|
|
13720
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
|
|
13597
13721
|
body3,
|
|
13598
|
-
/* @__PURE__ */ (0,
|
|
13722
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SectionImages, { section })
|
|
13599
13723
|
] }) });
|
|
13600
13724
|
}
|
|
13601
|
-
return /* @__PURE__ */ (0,
|
|
13725
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("section", { className: "space-y-4", children: [
|
|
13602
13726
|
body3,
|
|
13603
|
-
/* @__PURE__ */ (0,
|
|
13727
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SectionImages, { section })
|
|
13604
13728
|
] });
|
|
13605
13729
|
}
|
|
13606
13730
|
function PageSectionList({ sections }) {
|
|
13607
13731
|
if (sections.length === 0) return null;
|
|
13608
13732
|
const ordered = sections.slice().sort((a, b2) => a.order - b2.order);
|
|
13609
|
-
return /* @__PURE__ */ (0,
|
|
13733
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { className: "space-y-12", children: ordered.map((section) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(PageSectionBlock, { section }, section.id)) });
|
|
13610
13734
|
}
|
|
13611
13735
|
|
|
13612
13736
|
// src/components/treatment.tsx
|
|
13613
|
-
var
|
|
13737
|
+
var import_jsx_runtime5 = require("react/jsx-runtime");
|
|
13614
13738
|
function Treatment({ page, className }) {
|
|
13615
|
-
return /* @__PURE__ */ (0,
|
|
13616
|
-
/* @__PURE__ */ (0,
|
|
13617
|
-
/* @__PURE__ */ (0,
|
|
13739
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("article", { className: (0, import_utils3.cn)("space-y-12", className), "data-slot": "treatment", children: [
|
|
13740
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(PageHero, { page }),
|
|
13741
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(PageSectionList, { sections: page.sections })
|
|
13618
13742
|
] });
|
|
13619
13743
|
}
|
|
13620
13744
|
|
|
@@ -13623,11 +13747,11 @@ var import_utils5 = require("@reblu/site-ui/utils");
|
|
|
13623
13747
|
|
|
13624
13748
|
// src/components/page-card-grid.tsx
|
|
13625
13749
|
var import_utils4 = require("@reblu/site-ui/utils");
|
|
13626
|
-
var
|
|
13750
|
+
var import_jsx_runtime6 = require("react/jsx-runtime");
|
|
13627
13751
|
var defaultPageHref = (page) => `/${page.slug}`;
|
|
13628
13752
|
var pageKey = (page) => `${page.category?.slug ?? ""}/${page.slug}`;
|
|
13629
13753
|
function PageCardGrid(props) {
|
|
13630
|
-
return /* @__PURE__ */ (0,
|
|
13754
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(PageCardGridSection, { ...props });
|
|
13631
13755
|
}
|
|
13632
13756
|
function PageCardGridSection({
|
|
13633
13757
|
pages,
|
|
@@ -13638,15 +13762,15 @@ function PageCardGridSection({
|
|
|
13638
13762
|
}) {
|
|
13639
13763
|
if (pages.length === 0) return null;
|
|
13640
13764
|
const showHeading = keepEmptyHeading ? heading !== void 0 : !!heading;
|
|
13641
|
-
return /* @__PURE__ */ (0,
|
|
13642
|
-
showHeading && /* @__PURE__ */ (0,
|
|
13643
|
-
/* @__PURE__ */ (0,
|
|
13765
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("section", { className: (0, import_utils4.cn)("space-y-6", className), children: [
|
|
13766
|
+
showHeading && /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("h2", { className: "text-2xl font-bold", children: heading }),
|
|
13767
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("ul", { className: "grid list-none grid-cols-1 gap-6 p-0 sm:grid-cols-2 lg:grid-cols-3", children: pages.map((page) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("li", { children: /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
13644
13768
|
"a",
|
|
13645
13769
|
{
|
|
13646
13770
|
href: pageHref(page),
|
|
13647
13771
|
className: "group flex h-full flex-col overflow-hidden rounded-lg border bg-card transition-shadow hover:shadow-lg",
|
|
13648
13772
|
children: [
|
|
13649
|
-
page.coverImageUrl && /* @__PURE__ */ (0,
|
|
13773
|
+
page.coverImageUrl && /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "relative aspect-video overflow-hidden bg-muted", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
13650
13774
|
"img",
|
|
13651
13775
|
{
|
|
13652
13776
|
src: page.coverImageUrl,
|
|
@@ -13655,9 +13779,9 @@ function PageCardGridSection({
|
|
|
13655
13779
|
className: "h-full w-full object-cover transition-transform group-hover:scale-105"
|
|
13656
13780
|
}
|
|
13657
13781
|
) }),
|
|
13658
|
-
/* @__PURE__ */ (0,
|
|
13659
|
-
/* @__PURE__ */ (0,
|
|
13660
|
-
page.excerpt && /* @__PURE__ */ (0,
|
|
13782
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "flex flex-1 flex-col gap-2 p-4", children: [
|
|
13783
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("h3", { className: "font-semibold leading-tight transition-colors group-hover:text-primary", children: page.title }),
|
|
13784
|
+
page.excerpt && /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "line-clamp-2 text-sm text-muted-foreground", children: page.excerpt })
|
|
13661
13785
|
] })
|
|
13662
13786
|
]
|
|
13663
13787
|
}
|
|
@@ -13666,7 +13790,7 @@ function PageCardGridSection({
|
|
|
13666
13790
|
}
|
|
13667
13791
|
|
|
13668
13792
|
// src/components/parent-page.tsx
|
|
13669
|
-
var
|
|
13793
|
+
var import_jsx_runtime7 = require("react/jsx-runtime");
|
|
13670
13794
|
var defaultChildPageHref = (slug) => `/${slug}`;
|
|
13671
13795
|
function ParentPage({
|
|
13672
13796
|
page,
|
|
@@ -13681,10 +13805,10 @@ function ParentPage({
|
|
|
13681
13805
|
const pages = childPages ?? treatments ?? [];
|
|
13682
13806
|
const hrefFor = childPageHref ?? treatmentHref ?? defaultChildPageHref;
|
|
13683
13807
|
const label = childPagesLabel ?? treatmentsLabel ?? "Treatments";
|
|
13684
|
-
return /* @__PURE__ */ (0,
|
|
13685
|
-
/* @__PURE__ */ (0,
|
|
13686
|
-
/* @__PURE__ */ (0,
|
|
13687
|
-
/* @__PURE__ */ (0,
|
|
13808
|
+
return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("article", { className: (0, import_utils5.cn)("space-y-12", className), "data-slot": "specialty", children: [
|
|
13809
|
+
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(PageHero, { page }),
|
|
13810
|
+
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(PageSectionList, { sections: page.sections }),
|
|
13811
|
+
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
|
|
13688
13812
|
PageCardGridSection,
|
|
13689
13813
|
{
|
|
13690
13814
|
pages,
|
|
@@ -13704,7 +13828,7 @@ var import_utils7 = require("@reblu/site-ui/utils");
|
|
|
13704
13828
|
|
|
13705
13829
|
// src/components/professional-fields.tsx
|
|
13706
13830
|
var import_utils6 = require("@reblu/site-ui/utils");
|
|
13707
|
-
var
|
|
13831
|
+
var import_jsx_runtime8 = require("react/jsx-runtime");
|
|
13708
13832
|
function ProfessionalFields({
|
|
13709
13833
|
fields,
|
|
13710
13834
|
variant = "profile",
|
|
@@ -13712,7 +13836,7 @@ function ProfessionalFields({
|
|
|
13712
13836
|
}) {
|
|
13713
13837
|
const shown = (fields ?? []).filter((f) => variant !== "card" || f.showOnCard);
|
|
13714
13838
|
if (shown.length === 0) return null;
|
|
13715
|
-
return /* @__PURE__ */ (0,
|
|
13839
|
+
return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
|
|
13716
13840
|
"dl",
|
|
13717
13841
|
{
|
|
13718
13842
|
className: (0, import_utils6.cn)(
|
|
@@ -13722,13 +13846,13 @@ function ProfessionalFields({
|
|
|
13722
13846
|
),
|
|
13723
13847
|
"data-slot": "professional-fields",
|
|
13724
13848
|
"data-variant": variant,
|
|
13725
|
-
children: shown.map((field, index) => /* @__PURE__ */ (0,
|
|
13849
|
+
children: shown.map((field, index) => /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
|
|
13726
13850
|
"div",
|
|
13727
13851
|
{
|
|
13728
13852
|
className: variant === "card" ? "flex justify-center gap-1" : "contents",
|
|
13729
13853
|
children: [
|
|
13730
|
-
/* @__PURE__ */ (0,
|
|
13731
|
-
/* @__PURE__ */ (0,
|
|
13854
|
+
/* @__PURE__ */ (0, import_jsx_runtime8.jsx)("dt", { className: "text-muted-foreground", children: field.label }),
|
|
13855
|
+
/* @__PURE__ */ (0, import_jsx_runtime8.jsx)("dd", { className: "m-0 font-medium", children: field.value })
|
|
13732
13856
|
]
|
|
13733
13857
|
},
|
|
13734
13858
|
`${field.label}-${index}`
|
|
@@ -13738,7 +13862,7 @@ function ProfessionalFields({
|
|
|
13738
13862
|
}
|
|
13739
13863
|
|
|
13740
13864
|
// src/components/profile-card.tsx
|
|
13741
|
-
var
|
|
13865
|
+
var import_jsx_runtime9 = require("react/jsx-runtime");
|
|
13742
13866
|
function initials(name) {
|
|
13743
13867
|
return name.split(/\s+/).filter(Boolean).slice(0, 2).map((part) => part[0]?.toUpperCase() ?? "").join("");
|
|
13744
13868
|
}
|
|
@@ -13753,7 +13877,7 @@ function ProfileCard({
|
|
|
13753
13877
|
className
|
|
13754
13878
|
}) {
|
|
13755
13879
|
const NameTag = href ? "a" : "span";
|
|
13756
|
-
return /* @__PURE__ */ (0,
|
|
13880
|
+
return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
|
|
13757
13881
|
"article",
|
|
13758
13882
|
{
|
|
13759
13883
|
className: (0, import_utils7.cn)(
|
|
@@ -13762,7 +13886,7 @@ function ProfileCard({
|
|
|
13762
13886
|
),
|
|
13763
13887
|
"data-slot": "profile-card",
|
|
13764
13888
|
children: [
|
|
13765
|
-
/* @__PURE__ */ (0,
|
|
13889
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { className: "relative h-24 w-24 overflow-hidden rounded-full bg-muted", children: imageUrl ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("img", { src: imageUrl, alt: name, loading: "lazy", className: "h-full w-full object-cover" }) : /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
13766
13890
|
"span",
|
|
13767
13891
|
{
|
|
13768
13892
|
className: "flex h-full w-full items-center justify-center text-2xl font-semibold text-muted-foreground",
|
|
@@ -13770,12 +13894,12 @@ function ProfileCard({
|
|
|
13770
13894
|
children: initials(name)
|
|
13771
13895
|
}
|
|
13772
13896
|
) }),
|
|
13773
|
-
/* @__PURE__ */ (0,
|
|
13774
|
-
/* @__PURE__ */ (0,
|
|
13775
|
-
role && /* @__PURE__ */ (0,
|
|
13897
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("div", { className: "space-y-1", children: [
|
|
13898
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)("h3", { className: "text-lg font-semibold leading-tight", children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(NameTag, { ...href ? { href, className: "transition-colors hover:text-primary" } : {}, children: name }) }),
|
|
13899
|
+
role && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("p", { className: "text-sm text-muted-foreground", children: role })
|
|
13776
13900
|
] }),
|
|
13777
|
-
/* @__PURE__ */ (0,
|
|
13778
|
-
specialties.length > 0 && /* @__PURE__ */ (0,
|
|
13901
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ProfessionalFields, { fields, variant: "card" }),
|
|
13902
|
+
specialties.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("ul", { className: "flex flex-wrap justify-center gap-1.5 p-0", children: specialties.map((s2) => /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
13779
13903
|
"li",
|
|
13780
13904
|
{
|
|
13781
13905
|
className: "inline-flex items-center rounded-full bg-secondary px-2.5 py-0.5 text-xs font-medium text-secondary-foreground",
|
|
@@ -13783,7 +13907,7 @@ function ProfileCard({
|
|
|
13783
13907
|
},
|
|
13784
13908
|
s2
|
|
13785
13909
|
)) }),
|
|
13786
|
-
bio && /* @__PURE__ */ (0,
|
|
13910
|
+
bio && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("p", { className: "text-sm text-muted-foreground", children: bio })
|
|
13787
13911
|
]
|
|
13788
13912
|
}
|
|
13789
13913
|
);
|
|
@@ -13791,11 +13915,11 @@ function ProfileCard({
|
|
|
13791
13915
|
|
|
13792
13916
|
// src/components/product-card.tsx
|
|
13793
13917
|
var import_utils8 = require("@reblu/site-ui/utils");
|
|
13794
|
-
var
|
|
13918
|
+
var import_jsx_runtime10 = require("react/jsx-runtime");
|
|
13795
13919
|
function ProductCard({ product, href, currencyCode = "EUR", locale, className }) {
|
|
13796
13920
|
const image = product.images.find((i) => i.isPrimary) ?? product.images[0];
|
|
13797
13921
|
const hasDiscount = product.comparePrice != null && product.comparePrice > product.price;
|
|
13798
|
-
return /* @__PURE__ */ (0,
|
|
13922
|
+
return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
|
|
13799
13923
|
"article",
|
|
13800
13924
|
{
|
|
13801
13925
|
className: (0, import_utils8.cn)(
|
|
@@ -13804,7 +13928,7 @@ function ProductCard({ product, href, currencyCode = "EUR", locale, className })
|
|
|
13804
13928
|
),
|
|
13805
13929
|
"data-slot": "product-card",
|
|
13806
13930
|
children: [
|
|
13807
|
-
/* @__PURE__ */ (0,
|
|
13931
|
+
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "relative aspect-square overflow-hidden bg-muted", children: image ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
|
|
13808
13932
|
"img",
|
|
13809
13933
|
{
|
|
13810
13934
|
src: image.url,
|
|
@@ -13812,14 +13936,14 @@ function ProductCard({ product, href, currencyCode = "EUR", locale, className })
|
|
|
13812
13936
|
loading: "lazy",
|
|
13813
13937
|
className: "h-full w-full object-cover transition-transform group-hover:scale-105"
|
|
13814
13938
|
}
|
|
13815
|
-
) : /* @__PURE__ */ (0,
|
|
13816
|
-
/* @__PURE__ */ (0,
|
|
13817
|
-
product.category && /* @__PURE__ */ (0,
|
|
13818
|
-
/* @__PURE__ */ (0,
|
|
13819
|
-
product.shortDescription && /* @__PURE__ */ (0,
|
|
13820
|
-
/* @__PURE__ */ (0,
|
|
13821
|
-
/* @__PURE__ */ (0,
|
|
13822
|
-
hasDiscount && /* @__PURE__ */ (0,
|
|
13939
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "flex h-full items-center justify-center text-4xl text-muted-foreground/30", "aria-hidden": "true", children: "\u{1F6CD}\uFE0F" }) }),
|
|
13940
|
+
/* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "flex flex-1 flex-col gap-2 p-4", children: [
|
|
13941
|
+
product.category && /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { className: "inline-flex w-fit items-center rounded-full bg-secondary px-2.5 py-0.5 text-xs font-medium text-secondary-foreground", children: product.category.name }),
|
|
13942
|
+
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)("h3", { className: "text-base font-semibold leading-tight", children: href ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("a", { href, className: "transition-colors hover:text-primary", children: product.name }) : product.name }),
|
|
13943
|
+
product.shortDescription && /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("p", { className: "line-clamp-2 text-sm text-muted-foreground", children: product.shortDescription }),
|
|
13944
|
+
/* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "mt-auto flex items-baseline gap-2 pt-2", children: [
|
|
13945
|
+
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { className: "text-lg font-bold text-foreground", children: formatPrice(product.price, currencyCode, locale) }),
|
|
13946
|
+
hasDiscount && /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { className: "text-sm text-muted-foreground line-through", children: formatPrice(product.comparePrice, currencyCode, locale) })
|
|
13823
13947
|
] })
|
|
13824
13948
|
] })
|
|
13825
13949
|
]
|
|
@@ -14021,7 +14145,7 @@ var __iconNode8 = [
|
|
|
14021
14145
|
var Truck = createLucideIcon("truck", __iconNode8);
|
|
14022
14146
|
|
|
14023
14147
|
// src/components/product-trust-items.tsx
|
|
14024
|
-
var
|
|
14148
|
+
var import_jsx_runtime11 = require("react/jsx-runtime");
|
|
14025
14149
|
var DEFAULT_TRUST_ICONS = Object.freeze({
|
|
14026
14150
|
shipping: Truck,
|
|
14027
14151
|
returns: RotateCcw,
|
|
@@ -14055,9 +14179,9 @@ function ProductTrustItems({
|
|
|
14055
14179
|
return [{ key: `${index}-${icon}`, Icon: Icon2, text: text3 }];
|
|
14056
14180
|
});
|
|
14057
14181
|
if (rows.length === 0) return null;
|
|
14058
|
-
return /* @__PURE__ */ (0,
|
|
14059
|
-
/* @__PURE__ */ (0,
|
|
14060
|
-
/* @__PURE__ */ (0,
|
|
14182
|
+
return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(List, { "data-slot": "product-trust-items", className: slotClassName("space-y-2.5", "", className), children: rows.map(({ key: key2, Icon: Icon2, text: text3 }) => /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("li", { className: slotClassName("flex items-center gap-3", "text-sm text-muted-foreground", itemClassName), children: [
|
|
14183
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Icon2, { "aria-hidden": "true", className: "h-4 w-4 shrink-0 text-foreground/60" }),
|
|
14184
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("span", { children: text3 })
|
|
14061
14185
|
] }, key2)) });
|
|
14062
14186
|
}
|
|
14063
14187
|
|
|
@@ -14065,7 +14189,7 @@ function ProductTrustItems({
|
|
|
14065
14189
|
var import_utils11 = require("@reblu/site-ui/utils");
|
|
14066
14190
|
|
|
14067
14191
|
// src/components/_heading.tsx
|
|
14068
|
-
var
|
|
14192
|
+
var import_jsx_runtime12 = require("react/jsx-runtime");
|
|
14069
14193
|
function nextHeadingLevel(level) {
|
|
14070
14194
|
return Math.min(level + 1, 6);
|
|
14071
14195
|
}
|
|
@@ -14075,11 +14199,11 @@ function Heading({
|
|
|
14075
14199
|
children: children2
|
|
14076
14200
|
}) {
|
|
14077
14201
|
const Tag = `h${level}`;
|
|
14078
|
-
return /* @__PURE__ */ (0,
|
|
14202
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Tag, { className, children: children2 });
|
|
14079
14203
|
}
|
|
14080
14204
|
|
|
14081
14205
|
// src/components/faq-accordion.tsx
|
|
14082
|
-
var
|
|
14206
|
+
var import_jsx_runtime13 = require("react/jsx-runtime");
|
|
14083
14207
|
function FaqAccordion({
|
|
14084
14208
|
items,
|
|
14085
14209
|
heading,
|
|
@@ -14090,18 +14214,18 @@ function FaqAccordion({
|
|
|
14090
14214
|
}) {
|
|
14091
14215
|
const visible = items.map((item, index) => ({ item, index })).filter(({ item }) => item.q.trim() !== "");
|
|
14092
14216
|
if (visible.length === 0) return null;
|
|
14093
|
-
return /* @__PURE__ */ (0,
|
|
14094
|
-
heading && /* @__PURE__ */ (0,
|
|
14095
|
-
/* @__PURE__ */ (0,
|
|
14217
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("div", { className: (0, import_utils11.cn)("space-y-4", className), "data-slot": "faq-accordion", children: [
|
|
14218
|
+
heading && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Heading, { level: headingLevel, className: "text-2xl font-semibold tracking-tight", children: heading }),
|
|
14219
|
+
/* @__PURE__ */ (0, import_jsx_runtime13.jsx)("div", { className: "divide-y divide-border rounded-xl border border-border", children: visible.map(({ item, index }) => /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
|
|
14096
14220
|
"details",
|
|
14097
14221
|
{
|
|
14098
14222
|
className: "group px-4",
|
|
14099
14223
|
"data-slot": "faq-item",
|
|
14100
14224
|
...defaultOpen.includes(index) ? { open: true } : {},
|
|
14101
14225
|
children: [
|
|
14102
|
-
/* @__PURE__ */ (0,
|
|
14103
|
-
questionHeadingLevel ? /* @__PURE__ */ (0,
|
|
14104
|
-
/* @__PURE__ */ (0,
|
|
14226
|
+
/* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("summary", { className: "flex cursor-pointer list-none items-center justify-between gap-4 py-4 font-medium focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-ring [&::-webkit-details-marker]:hidden", children: [
|
|
14227
|
+
questionHeadingLevel ? /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Heading, { level: questionHeadingLevel, className: "text-base font-medium", children: item.q }) : /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("span", { children: item.q }),
|
|
14228
|
+
/* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
14105
14229
|
"span",
|
|
14106
14230
|
{
|
|
14107
14231
|
"aria-hidden": "true",
|
|
@@ -14110,7 +14234,7 @@ function FaqAccordion({
|
|
|
14110
14234
|
}
|
|
14111
14235
|
)
|
|
14112
14236
|
] }),
|
|
14113
|
-
/* @__PURE__ */ (0,
|
|
14237
|
+
/* @__PURE__ */ (0, import_jsx_runtime13.jsx)("p", { className: "whitespace-pre-line pb-4 text-muted-foreground", children: item.a })
|
|
14114
14238
|
]
|
|
14115
14239
|
},
|
|
14116
14240
|
index
|
|
@@ -14120,7 +14244,7 @@ function FaqAccordion({
|
|
|
14120
14244
|
|
|
14121
14245
|
// src/components/trust-badges.tsx
|
|
14122
14246
|
var import_utils12 = require("@reblu/site-ui/utils");
|
|
14123
|
-
var
|
|
14247
|
+
var import_jsx_runtime14 = (
|
|
14124
14248
|
// eslint-disable-next-line @next/next/no-img-element -- framework-agnostic SDK; the SITE owns image optimisation
|
|
14125
14249
|
require("react/jsx-runtime")
|
|
14126
14250
|
);
|
|
@@ -14163,7 +14287,7 @@ function safeLogoSrc(url) {
|
|
|
14163
14287
|
function BadgeContent({ badge, logoClassName }) {
|
|
14164
14288
|
const src = safeLogoSrc(badge.logoUrl);
|
|
14165
14289
|
if (src) {
|
|
14166
|
-
return /* @__PURE__ */ (0,
|
|
14290
|
+
return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
14167
14291
|
"img",
|
|
14168
14292
|
{
|
|
14169
14293
|
src,
|
|
@@ -14173,7 +14297,7 @@ function BadgeContent({ badge, logoClassName }) {
|
|
|
14173
14297
|
}
|
|
14174
14298
|
);
|
|
14175
14299
|
}
|
|
14176
|
-
return /* @__PURE__ */ (0,
|
|
14300
|
+
return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("span", { className: "text-sm font-medium", children: badge.name });
|
|
14177
14301
|
}
|
|
14178
14302
|
function TrustBadges({
|
|
14179
14303
|
badges,
|
|
@@ -14201,14 +14325,14 @@ function TrustBadges({
|
|
|
14201
14325
|
if (groups.length === 0) return null;
|
|
14202
14326
|
const hasHeading = heading !== void 0 && heading !== null && heading !== "";
|
|
14203
14327
|
const groupHeadingLevel = hasHeading ? nextHeadingLevel(headingLevel) : headingLevel;
|
|
14204
|
-
const content = groups.map(({ type, groupHeading, items }) => /* @__PURE__ */ (0,
|
|
14328
|
+
const content = groups.map(({ type, groupHeading, items }) => /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
|
|
14205
14329
|
"div",
|
|
14206
14330
|
{
|
|
14207
14331
|
"data-slot": "trust-badge-group",
|
|
14208
14332
|
"data-type": type,
|
|
14209
14333
|
className: (0, import_utils12.cn)("space-y-3", groupClassName),
|
|
14210
14334
|
children: [
|
|
14211
|
-
groupHeading ? /* @__PURE__ */ (0,
|
|
14335
|
+
groupHeading ? /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
14212
14336
|
Heading,
|
|
14213
14337
|
{
|
|
14214
14338
|
level: groupHeadingLevel,
|
|
@@ -14220,30 +14344,30 @@ function TrustBadges({
|
|
|
14220
14344
|
children: groupHeading
|
|
14221
14345
|
}
|
|
14222
14346
|
) : null,
|
|
14223
|
-
/* @__PURE__ */ (0,
|
|
14347
|
+
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)("ul", { className: (0, import_utils12.cn)("flex flex-wrap items-center gap-6", listClassName), children: items.map((badge) => {
|
|
14224
14348
|
const href = safeHref(badge.url);
|
|
14225
|
-
return /* @__PURE__ */ (0,
|
|
14226
|
-
/* @__PURE__ */ (0,
|
|
14349
|
+
return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("li", { children: href ? /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("a", { href, target: "_blank", rel: "noopener noreferrer", className: "inline-flex", children: [
|
|
14350
|
+
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)(BadgeContent, { badge, logoClassName }),
|
|
14227
14351
|
" ",
|
|
14228
|
-
/* @__PURE__ */ (0,
|
|
14229
|
-
] }) : /* @__PURE__ */ (0,
|
|
14352
|
+
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)("span", { className: "sr-only", children: newWindowLabel })
|
|
14353
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(BadgeContent, { badge, logoClassName }) }, badge.id);
|
|
14230
14354
|
}) })
|
|
14231
14355
|
]
|
|
14232
14356
|
},
|
|
14233
14357
|
type
|
|
14234
14358
|
));
|
|
14235
14359
|
if (!hasHeading) {
|
|
14236
|
-
return /* @__PURE__ */ (0,
|
|
14360
|
+
return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { "data-slot": "trust-badges", className: (0, import_utils12.cn)("space-y-6", className), children: content });
|
|
14237
14361
|
}
|
|
14238
14362
|
const Tag = `h${headingLevel}`;
|
|
14239
|
-
return /* @__PURE__ */ (0,
|
|
14363
|
+
return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
|
|
14240
14364
|
"section",
|
|
14241
14365
|
{
|
|
14242
14366
|
"data-slot": "trust-badges",
|
|
14243
14367
|
"aria-labelledby": headingId,
|
|
14244
14368
|
className: (0, import_utils12.cn)("space-y-6", className),
|
|
14245
14369
|
children: [
|
|
14246
|
-
/* @__PURE__ */ (0,
|
|
14370
|
+
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
14247
14371
|
Tag,
|
|
14248
14372
|
{
|
|
14249
14373
|
id: headingId,
|
|
@@ -14260,38 +14384,38 @@ function TrustBadges({
|
|
|
14260
14384
|
// src/components/page-blocks.tsx
|
|
14261
14385
|
var import_utils13 = require("@reblu/site-ui/utils");
|
|
14262
14386
|
var import_button_variants2 = require("@reblu/site-ui/button-variants");
|
|
14263
|
-
var
|
|
14387
|
+
var import_jsx_runtime15 = require("react/jsx-runtime");
|
|
14264
14388
|
var ALIASES = {
|
|
14265
14389
|
doctor_embed: "profile_embed",
|
|
14266
14390
|
specialty_embed: "page_embed"
|
|
14267
14391
|
};
|
|
14268
14392
|
function HeroBlock({ block, headingLevel }) {
|
|
14269
14393
|
const { title, subtitle, imageUrl } = block.data;
|
|
14270
|
-
return /* @__PURE__ */ (0,
|
|
14271
|
-
/* @__PURE__ */ (0,
|
|
14272
|
-
subtitle && /* @__PURE__ */ (0,
|
|
14273
|
-
imageUrl && /* @__PURE__ */ (0,
|
|
14394
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "space-y-4", children: [
|
|
14395
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Heading, { level: headingLevel, className: "text-3xl font-bold tracking-tight md:text-4xl", children: title }),
|
|
14396
|
+
subtitle && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("p", { className: "text-lg opacity-80", children: subtitle }),
|
|
14397
|
+
imageUrl && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "relative aspect-[21/9] w-full overflow-hidden rounded-xl bg-muted", children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("img", { src: imageUrl, alt: "", loading: "lazy", className: "h-full w-full object-cover" }) })
|
|
14274
14398
|
] });
|
|
14275
14399
|
}
|
|
14276
14400
|
function RichtextBlock({ block, headingLevel }) {
|
|
14277
|
-
return /* @__PURE__ */ (0,
|
|
14401
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(SafeHtml, { html: sanitizeHtml(block.data.html), headingOffset: headingLevel - 1 });
|
|
14278
14402
|
}
|
|
14279
14403
|
function FaqBlock({ block }) {
|
|
14280
|
-
return /* @__PURE__ */ (0,
|
|
14404
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(FaqAccordion, { items: block.data.items });
|
|
14281
14405
|
}
|
|
14282
14406
|
function StatsBlock({ block }) {
|
|
14283
|
-
return /* @__PURE__ */ (0,
|
|
14284
|
-
/* @__PURE__ */ (0,
|
|
14285
|
-
/* @__PURE__ */ (0,
|
|
14407
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("dl", { className: "grid gap-6 sm:grid-cols-2 lg:grid-cols-4", children: block.data.items.map((item, i) => /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "flex flex-col-reverse gap-1", children: [
|
|
14408
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)("dt", { className: "text-sm opacity-80", children: item.label }),
|
|
14409
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)("dd", { className: "text-3xl font-bold", children: item.value })
|
|
14286
14410
|
] }, i)) });
|
|
14287
14411
|
}
|
|
14288
14412
|
function TestimonialBlock({ block }) {
|
|
14289
14413
|
const { quote, author, role, avatarUrl } = block.data;
|
|
14290
|
-
return /* @__PURE__ */ (0,
|
|
14291
|
-
/* @__PURE__ */ (0,
|
|
14292
|
-
/* @__PURE__ */ (0,
|
|
14414
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("figure", { className: "space-y-4", children: [
|
|
14415
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)("blockquote", { className: "text-xl italic", children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("p", { children: quote }) }),
|
|
14416
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("figcaption", { className: "flex items-center gap-3", children: [
|
|
14293
14417
|
avatarUrl && // eslint-disable-next-line @next/next/no-img-element
|
|
14294
|
-
/* @__PURE__ */ (0,
|
|
14418
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
14295
14419
|
"img",
|
|
14296
14420
|
{
|
|
14297
14421
|
src: avatarUrl,
|
|
@@ -14300,9 +14424,9 @@ function TestimonialBlock({ block }) {
|
|
|
14300
14424
|
className: "h-10 w-10 rounded-full object-cover"
|
|
14301
14425
|
}
|
|
14302
14426
|
),
|
|
14303
|
-
/* @__PURE__ */ (0,
|
|
14304
|
-
/* @__PURE__ */ (0,
|
|
14305
|
-
role && /* @__PURE__ */ (0,
|
|
14427
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("span", { children: [
|
|
14428
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { className: "font-semibold", children: author }),
|
|
14429
|
+
role && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { className: "block text-sm opacity-80", children: role })
|
|
14306
14430
|
] })
|
|
14307
14431
|
] })
|
|
14308
14432
|
] });
|
|
@@ -14311,19 +14435,19 @@ function CtaSlotBlock(_props) {
|
|
|
14311
14435
|
return null;
|
|
14312
14436
|
}
|
|
14313
14437
|
function FeatureListBlock({ block }) {
|
|
14314
|
-
return /* @__PURE__ */ (0,
|
|
14438
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("ul", { className: "grid list-disc gap-2 pl-5 sm:grid-cols-2", children: block.data.items.map((item, i) => /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("li", { children: item.text }, i)) });
|
|
14315
14439
|
}
|
|
14316
14440
|
function GalleryBlock({ block }) {
|
|
14317
14441
|
const { images } = block.data;
|
|
14318
|
-
return /* @__PURE__ */ (0,
|
|
14442
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
14319
14443
|
"div",
|
|
14320
14444
|
{
|
|
14321
14445
|
className: (0, import_utils13.cn)(
|
|
14322
14446
|
"grid gap-4",
|
|
14323
14447
|
images.length > 1 ? "sm:grid-cols-2 lg:grid-cols-3" : "grid-cols-1"
|
|
14324
14448
|
),
|
|
14325
|
-
children: images.map((img, i) => /* @__PURE__ */ (0,
|
|
14326
|
-
/* @__PURE__ */ (0,
|
|
14449
|
+
children: images.map((img, i) => /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("figure", { className: "space-y-1", children: [
|
|
14450
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "relative aspect-video w-full overflow-hidden rounded-lg bg-muted", children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
14327
14451
|
"img",
|
|
14328
14452
|
{
|
|
14329
14453
|
src: img.url,
|
|
@@ -14332,7 +14456,7 @@ function GalleryBlock({ block }) {
|
|
|
14332
14456
|
className: "h-full w-full object-cover"
|
|
14333
14457
|
}
|
|
14334
14458
|
) }),
|
|
14335
|
-
img.caption && /* @__PURE__ */ (0,
|
|
14459
|
+
img.caption && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("figcaption", { className: "text-sm opacity-80", children: img.caption })
|
|
14336
14460
|
] }, `${img.url}-${i}`))
|
|
14337
14461
|
}
|
|
14338
14462
|
);
|
|
@@ -14342,13 +14466,13 @@ function EmbedCard({
|
|
|
14342
14466
|
headingLevel,
|
|
14343
14467
|
embedHref
|
|
14344
14468
|
}) {
|
|
14345
|
-
return /* @__PURE__ */ (0,
|
|
14469
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
|
|
14346
14470
|
"a",
|
|
14347
14471
|
{
|
|
14348
14472
|
href: embedHref(resolved),
|
|
14349
14473
|
className: "group block overflow-hidden rounded-xl border border-border bg-card text-card-foreground transition-shadow hover:shadow-md focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-ring",
|
|
14350
14474
|
children: [
|
|
14351
|
-
resolved.coverImageUrl && /* @__PURE__ */ (0,
|
|
14475
|
+
resolved.coverImageUrl && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "aspect-video w-full overflow-hidden bg-muted", children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
14352
14476
|
"img",
|
|
14353
14477
|
{
|
|
14354
14478
|
src: resolved.coverImageUrl,
|
|
@@ -14357,24 +14481,24 @@ function EmbedCard({
|
|
|
14357
14481
|
className: "h-full w-full object-cover"
|
|
14358
14482
|
}
|
|
14359
14483
|
) }),
|
|
14360
|
-
/* @__PURE__ */ (0,
|
|
14361
|
-
/* @__PURE__ */ (0,
|
|
14362
|
-
resolved.role && /* @__PURE__ */ (0,
|
|
14363
|
-
resolved.excerpt && /* @__PURE__ */ (0,
|
|
14484
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "space-y-1 p-4", children: [
|
|
14485
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Heading, { level: headingLevel, className: "text-lg font-semibold", children: resolved.title }),
|
|
14486
|
+
resolved.role && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("p", { className: "text-sm text-muted-foreground", children: resolved.role }),
|
|
14487
|
+
resolved.excerpt && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("p", { className: "text-muted-foreground", children: resolved.excerpt })
|
|
14364
14488
|
] })
|
|
14365
14489
|
]
|
|
14366
14490
|
}
|
|
14367
14491
|
);
|
|
14368
14492
|
}
|
|
14369
14493
|
function PageEmbedBlock({ block, headingLevel, embedHref }) {
|
|
14370
|
-
return /* @__PURE__ */ (0,
|
|
14494
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(EmbedCard, { resolved: block.resolved, headingLevel, embedHref });
|
|
14371
14495
|
}
|
|
14372
14496
|
function ProfileEmbedBlock({
|
|
14373
14497
|
block,
|
|
14374
14498
|
headingLevel,
|
|
14375
14499
|
embedHref
|
|
14376
14500
|
}) {
|
|
14377
|
-
return /* @__PURE__ */ (0,
|
|
14501
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(EmbedCard, { resolved: block.resolved, headingLevel, embedHref });
|
|
14378
14502
|
}
|
|
14379
14503
|
var DEFAULT_RENDERERS = {
|
|
14380
14504
|
hero: HeroBlock,
|
|
@@ -14431,7 +14555,7 @@ function toIdFragment(value) {
|
|
|
14431
14555
|
function SectionCta2({ cta }) {
|
|
14432
14556
|
if (!hasUsableCta(cta)) return null;
|
|
14433
14557
|
const variant = toButtonVariant(cta.variant);
|
|
14434
|
-
return /* @__PURE__ */ (0,
|
|
14558
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "pt-2", children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
14435
14559
|
"a",
|
|
14436
14560
|
{
|
|
14437
14561
|
href: cta.url,
|
|
@@ -14464,7 +14588,7 @@ function PageBlocks({
|
|
|
14464
14588
|
const headingId = block.heading ? `${safePrefix}-${toIdFragment(block.id)}-heading` : void 0;
|
|
14465
14589
|
const background = block.backgroundColor;
|
|
14466
14590
|
return [
|
|
14467
|
-
/* @__PURE__ */ (0,
|
|
14591
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
|
|
14468
14592
|
"section",
|
|
14469
14593
|
{
|
|
14470
14594
|
"data-slot": "page-block",
|
|
@@ -14473,8 +14597,8 @@ function PageBlocks({
|
|
|
14473
14597
|
style: surfaceStyle(background),
|
|
14474
14598
|
className: (0, import_utils13.cn)("space-y-6", background && "rounded-xl px-6 py-10", sectionClassName),
|
|
14475
14599
|
children: [
|
|
14476
|
-
block.heading && /* @__PURE__ */ (0,
|
|
14477
|
-
/* @__PURE__ */ (0,
|
|
14600
|
+
block.heading && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Heading, { level: headingLevel, className: "text-2xl font-bold tracking-tight", children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { id: headingId, children: block.heading }) }),
|
|
14601
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
14478
14602
|
Renderer,
|
|
14479
14603
|
{
|
|
14480
14604
|
block,
|
|
@@ -14482,7 +14606,7 @@ function PageBlocks({
|
|
|
14482
14606
|
embedHref
|
|
14483
14607
|
}
|
|
14484
14608
|
),
|
|
14485
|
-
/* @__PURE__ */ (0,
|
|
14609
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)(SectionCta2, { cta: block.cta })
|
|
14486
14610
|
]
|
|
14487
14611
|
},
|
|
14488
14612
|
block.id
|
|
@@ -14490,12 +14614,12 @@ function PageBlocks({
|
|
|
14490
14614
|
];
|
|
14491
14615
|
});
|
|
14492
14616
|
if (sections.length === 0) return null;
|
|
14493
|
-
return /* @__PURE__ */ (0,
|
|
14617
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: (0, import_utils13.cn)("space-y-12", className), "data-slot": "page-blocks", children: sections });
|
|
14494
14618
|
}
|
|
14495
14619
|
|
|
14496
14620
|
// src/components/shop-filters.tsx
|
|
14497
14621
|
var import_utils14 = require("@reblu/site-ui/utils");
|
|
14498
|
-
var
|
|
14622
|
+
var import_jsx_runtime16 = require("react/jsx-runtime");
|
|
14499
14623
|
var DEFAULT_SHOP_PRICE_BANDS = [
|
|
14500
14624
|
{ max: 2500 },
|
|
14501
14625
|
{ min: 2500, max: 5e3 },
|
|
@@ -14539,7 +14663,7 @@ function priceBandLabel(band, t, currencyCode, locale) {
|
|
|
14539
14663
|
return "";
|
|
14540
14664
|
}
|
|
14541
14665
|
function OptionLink({ href, active, label, onActivate }) {
|
|
14542
|
-
return /* @__PURE__ */ (0,
|
|
14666
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
14543
14667
|
"a",
|
|
14544
14668
|
{
|
|
14545
14669
|
href,
|
|
@@ -14557,9 +14681,9 @@ function OptionLink({ href, active, label, onActivate }) {
|
|
|
14557
14681
|
);
|
|
14558
14682
|
}
|
|
14559
14683
|
function FilterFieldset({ legend, children: children2 }) {
|
|
14560
|
-
return /* @__PURE__ */ (0,
|
|
14561
|
-
/* @__PURE__ */ (0,
|
|
14562
|
-
/* @__PURE__ */ (0,
|
|
14684
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("fieldset", { className: "space-y-2", children: [
|
|
14685
|
+
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)("legend", { className: "text-sm font-medium text-foreground", children: legend }),
|
|
14686
|
+
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)("div", { className: "flex flex-wrap gap-2", children: children2 })
|
|
14563
14687
|
] });
|
|
14564
14688
|
}
|
|
14565
14689
|
function ShopFilters({
|
|
@@ -14582,11 +14706,11 @@ function ShopFilters({
|
|
|
14582
14706
|
if (!shouldRenderShopFilters(facets, active)) {
|
|
14583
14707
|
return null;
|
|
14584
14708
|
}
|
|
14585
|
-
return /* @__PURE__ */ (0,
|
|
14709
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("div", { className: (0, import_utils14.cn)("space-y-6", className), "data-slot": "shop-filters", children: [
|
|
14586
14710
|
visibleTaxonomies.map((axis) => {
|
|
14587
14711
|
const activeSlug = active.taxonomy?.[axis.key];
|
|
14588
|
-
return /* @__PURE__ */ (0,
|
|
14589
|
-
/* @__PURE__ */ (0,
|
|
14712
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(FilterFieldset, { legend: axis.label, children: [
|
|
14713
|
+
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
14590
14714
|
OptionLink,
|
|
14591
14715
|
{
|
|
14592
14716
|
href: hrefs.taxonomy(axis.key, void 0),
|
|
@@ -14601,7 +14725,7 @@ function ShopFilters({
|
|
|
14601
14725
|
),
|
|
14602
14726
|
axis.terms.map((term) => {
|
|
14603
14727
|
const isActive = activeSlug === term.slug;
|
|
14604
|
-
return /* @__PURE__ */ (0,
|
|
14728
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
14605
14729
|
OptionLink,
|
|
14606
14730
|
{
|
|
14607
14731
|
href: hrefs.taxonomy(axis.key, isActive ? void 0 : term.slug),
|
|
@@ -14621,9 +14745,9 @@ function ShopFilters({
|
|
|
14621
14745
|
}),
|
|
14622
14746
|
visibleAttributes.map((attr) => {
|
|
14623
14747
|
const activeValues = toValueArray(active.attr?.[attr.key]);
|
|
14624
|
-
return /* @__PURE__ */ (0,
|
|
14748
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(FilterFieldset, { legend: attr.label, children: attr.options.map((opt) => {
|
|
14625
14749
|
const isActive = activeValues.includes(opt.value);
|
|
14626
|
-
return /* @__PURE__ */ (0,
|
|
14750
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
14627
14751
|
OptionLink,
|
|
14628
14752
|
{
|
|
14629
14753
|
href: hrefs.attr(attr.key, opt.value),
|
|
@@ -14641,11 +14765,11 @@ function ShopFilters({
|
|
|
14641
14765
|
);
|
|
14642
14766
|
}) }, attr.key);
|
|
14643
14767
|
}),
|
|
14644
|
-
showPriceGroup && /* @__PURE__ */ (0,
|
|
14768
|
+
showPriceGroup && /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(FilterFieldset, { legend: t.price, children: priceBands.map((band, i) => {
|
|
14645
14769
|
const isActive = active.priceMin === band.min && active.priceMax === band.max;
|
|
14646
14770
|
const nextMin = isActive ? void 0 : band.min;
|
|
14647
14771
|
const nextMax = isActive ? void 0 : band.max;
|
|
14648
|
-
return /* @__PURE__ */ (0,
|
|
14772
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
14649
14773
|
OptionLink,
|
|
14650
14774
|
{
|
|
14651
14775
|
href: hrefs.price(nextMin, nextMax),
|
|
@@ -14656,7 +14780,7 @@ function ShopFilters({
|
|
|
14656
14780
|
i
|
|
14657
14781
|
);
|
|
14658
14782
|
}) }),
|
|
14659
|
-
hasOnSale && /* @__PURE__ */ (0,
|
|
14783
|
+
hasOnSale && /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
14660
14784
|
OptionLink,
|
|
14661
14785
|
{
|
|
14662
14786
|
href: hrefs.onSale(!active.onSale),
|
|
@@ -14665,7 +14789,7 @@ function ShopFilters({
|
|
|
14665
14789
|
onActivate: onChange ? () => onChange({ onSale: !active.onSale }) : void 0
|
|
14666
14790
|
}
|
|
14667
14791
|
),
|
|
14668
|
-
/* @__PURE__ */ (0,
|
|
14792
|
+
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
14669
14793
|
"a",
|
|
14670
14794
|
{
|
|
14671
14795
|
href: hrefs.clearAll(),
|
|
@@ -14680,9 +14804,129 @@ function ShopFilters({
|
|
|
14680
14804
|
] });
|
|
14681
14805
|
}
|
|
14682
14806
|
|
|
14683
|
-
// src/components/
|
|
14807
|
+
// src/components/course-catalog-filters.tsx
|
|
14684
14808
|
var import_utils15 = require("@reblu/site-ui/utils");
|
|
14685
|
-
var
|
|
14809
|
+
var import_jsx_runtime17 = require("react/jsx-runtime");
|
|
14810
|
+
var DEFAULT_COURSE_PRICE_BANDS = [
|
|
14811
|
+
{ max: 5e3 },
|
|
14812
|
+
{ min: 5e3, max: 15e3 },
|
|
14813
|
+
{ min: 15e3, max: 3e4 },
|
|
14814
|
+
{ min: 3e4 }
|
|
14815
|
+
];
|
|
14816
|
+
var DEFAULT_COURSE_CATALOG_FILTERS_LABELS = {
|
|
14817
|
+
instructor: "Docente",
|
|
14818
|
+
allInstructors: "Todos",
|
|
14819
|
+
price: "Precio",
|
|
14820
|
+
free: "Gratis",
|
|
14821
|
+
clearAll: "Quitar filtros",
|
|
14822
|
+
priceUnder: (formattedMax) => `Hasta ${formattedMax}`,
|
|
14823
|
+
priceOver: (formattedMin) => `Desde ${formattedMin}`,
|
|
14824
|
+
priceRange: (formattedMin, formattedMax) => `${formattedMin} \u2013 ${formattedMax}`
|
|
14825
|
+
};
|
|
14826
|
+
function instructorName(instructor) {
|
|
14827
|
+
return [instructor.firstName, instructor.lastName].filter(Boolean).join(" ");
|
|
14828
|
+
}
|
|
14829
|
+
function bandLabel(band, t, currencyCode, locale) {
|
|
14830
|
+
if (band.label) return band.label;
|
|
14831
|
+
const fmt = (cents) => formatPrice(cents, currencyCode, locale);
|
|
14832
|
+
if (band.min !== void 0 && band.max !== void 0)
|
|
14833
|
+
return t.priceRange(fmt(band.min), fmt(band.max));
|
|
14834
|
+
if (band.max !== void 0) return t.priceUnder(fmt(band.max));
|
|
14835
|
+
if (band.min !== void 0) return t.priceOver(fmt(band.min));
|
|
14836
|
+
return "";
|
|
14837
|
+
}
|
|
14838
|
+
function CourseCatalogFilters({
|
|
14839
|
+
instructors,
|
|
14840
|
+
hrefs,
|
|
14841
|
+
active = {},
|
|
14842
|
+
onChange,
|
|
14843
|
+
priceBands = DEFAULT_COURSE_PRICE_BANDS,
|
|
14844
|
+
labels,
|
|
14845
|
+
currencyCode,
|
|
14846
|
+
locale,
|
|
14847
|
+
className
|
|
14848
|
+
}) {
|
|
14849
|
+
const t = { ...DEFAULT_COURSE_CATALOG_FILTERS_LABELS, ...labels };
|
|
14850
|
+
const named = instructors.filter((i) => instructorName(i) !== "");
|
|
14851
|
+
const showInstructors = named.length > 0 || active.instructor !== void 0;
|
|
14852
|
+
const isFree = Boolean(active.free);
|
|
14853
|
+
return /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)("div", { className: (0, import_utils15.cn)("space-y-6", className), "data-slot": "course-catalog-filters", children: [
|
|
14854
|
+
showInstructors && /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(FilterFieldset, { legend: t.instructor, children: [
|
|
14855
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
14856
|
+
OptionLink,
|
|
14857
|
+
{
|
|
14858
|
+
href: hrefs.instructor(void 0),
|
|
14859
|
+
active: active.instructor === void 0,
|
|
14860
|
+
label: t.allInstructors,
|
|
14861
|
+
onActivate: onChange ? () => onChange({ instructor: void 0 }) : void 0
|
|
14862
|
+
}
|
|
14863
|
+
),
|
|
14864
|
+
named.map((instructor) => {
|
|
14865
|
+
const isActive = active.instructor === instructor.id;
|
|
14866
|
+
const next2 = isActive ? void 0 : instructor.id;
|
|
14867
|
+
return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
14868
|
+
OptionLink,
|
|
14869
|
+
{
|
|
14870
|
+
href: hrefs.instructor(next2),
|
|
14871
|
+
active: isActive,
|
|
14872
|
+
label: instructorName(instructor),
|
|
14873
|
+
onActivate: onChange ? () => onChange({ instructor: next2 }) : void 0
|
|
14874
|
+
},
|
|
14875
|
+
instructor.id
|
|
14876
|
+
);
|
|
14877
|
+
})
|
|
14878
|
+
] }),
|
|
14879
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(FilterFieldset, { legend: t.price, children: [
|
|
14880
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
14881
|
+
OptionLink,
|
|
14882
|
+
{
|
|
14883
|
+
href: hrefs.free(!isFree),
|
|
14884
|
+
active: isFree,
|
|
14885
|
+
label: t.free,
|
|
14886
|
+
onActivate: onChange ? () => onChange(
|
|
14887
|
+
isFree ? { free: false } : { free: true, priceMin: void 0, priceMax: void 0 }
|
|
14888
|
+
) : void 0
|
|
14889
|
+
}
|
|
14890
|
+
),
|
|
14891
|
+
priceBands.map((band, i) => {
|
|
14892
|
+
const isActive = !isFree && active.priceMin === band.min && active.priceMax === band.max;
|
|
14893
|
+
const nextMin = isActive ? void 0 : band.min;
|
|
14894
|
+
const nextMax = isActive ? void 0 : band.max;
|
|
14895
|
+
return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
14896
|
+
OptionLink,
|
|
14897
|
+
{
|
|
14898
|
+
href: hrefs.price(nextMin, nextMax),
|
|
14899
|
+
active: isActive,
|
|
14900
|
+
label: bandLabel(band, t, currencyCode, locale),
|
|
14901
|
+
onActivate: onChange ? () => onChange({ priceMin: nextMin, priceMax: nextMax, free: false }) : void 0
|
|
14902
|
+
},
|
|
14903
|
+
i
|
|
14904
|
+
);
|
|
14905
|
+
})
|
|
14906
|
+
] }),
|
|
14907
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
14908
|
+
"a",
|
|
14909
|
+
{
|
|
14910
|
+
href: hrefs.clearAll(),
|
|
14911
|
+
onClick: onChange ? (event) => {
|
|
14912
|
+
event.preventDefault();
|
|
14913
|
+
onChange({
|
|
14914
|
+
instructor: void 0,
|
|
14915
|
+
priceMin: void 0,
|
|
14916
|
+
priceMax: void 0,
|
|
14917
|
+
free: false
|
|
14918
|
+
});
|
|
14919
|
+
} : void 0,
|
|
14920
|
+
className: "text-sm font-medium text-muted-foreground underline-offset-4 hover:text-foreground hover:underline",
|
|
14921
|
+
children: t.clearAll
|
|
14922
|
+
}
|
|
14923
|
+
)
|
|
14924
|
+
] });
|
|
14925
|
+
}
|
|
14926
|
+
|
|
14927
|
+
// src/components/cart-line-list.tsx
|
|
14928
|
+
var import_utils16 = require("@reblu/site-ui/utils");
|
|
14929
|
+
var import_jsx_runtime18 = require("react/jsx-runtime");
|
|
14686
14930
|
var DEFAULT_LABELS2 = {
|
|
14687
14931
|
quantityLabel: "Cantidad",
|
|
14688
14932
|
decrease: "Reducir cantidad",
|
|
@@ -14708,9 +14952,9 @@ function CartLineList({
|
|
|
14708
14952
|
}) {
|
|
14709
14953
|
const t = { ...DEFAULT_LABELS2, ...labels };
|
|
14710
14954
|
const noticeContent = notice === true ? t.cancelledNotice : notice;
|
|
14711
|
-
return /* @__PURE__ */ (0,
|
|
14712
|
-
/* @__PURE__ */ (0,
|
|
14713
|
-
noticeContent != null && noticeContent !== false && /* @__PURE__ */ (0,
|
|
14955
|
+
return /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: (0, import_utils16.cn)("space-y-4", className), "data-slot": "cart-line-list", children: [
|
|
14956
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { "aria-live": "polite", className: "sr-only", children: liveMessage }),
|
|
14957
|
+
noticeContent != null && noticeContent !== false && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
|
|
14714
14958
|
"div",
|
|
14715
14959
|
{
|
|
14716
14960
|
role: "status",
|
|
@@ -14719,33 +14963,33 @@ function CartLineList({
|
|
|
14719
14963
|
children: noticeContent
|
|
14720
14964
|
}
|
|
14721
14965
|
),
|
|
14722
|
-
/* @__PURE__ */ (0,
|
|
14966
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)("ul", { className: "space-y-4", children: items.map((item) => {
|
|
14723
14967
|
const maxQty = item.maxStock ?? Infinity;
|
|
14724
14968
|
const atMax = item.quantity >= maxQty;
|
|
14725
14969
|
const atMin = item.quantity <= 1;
|
|
14726
14970
|
const message = lineMessage?.(item);
|
|
14727
|
-
return /* @__PURE__ */ (0,
|
|
14971
|
+
return /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(
|
|
14728
14972
|
"li",
|
|
14729
14973
|
{
|
|
14730
14974
|
className: "flex gap-4 rounded-xl border border-border bg-card p-4",
|
|
14731
14975
|
children: [
|
|
14732
|
-
/* @__PURE__ */ (0,
|
|
14733
|
-
/* @__PURE__ */ (0,
|
|
14734
|
-
/* @__PURE__ */ (0,
|
|
14735
|
-
item.variantName && /* @__PURE__ */ (0,
|
|
14736
|
-
/* @__PURE__ */ (0,
|
|
14976
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { className: "h-20 w-20 flex-shrink-0 overflow-hidden rounded-lg bg-muted", children: item.imageUrl ? /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("img", { src: item.imageUrl, alt: item.name, className: "h-full w-full object-cover" }) : null }),
|
|
14977
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "min-w-0 flex-1", children: [
|
|
14978
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)("p", { className: "truncate text-sm font-semibold leading-tight", children: item.name }),
|
|
14979
|
+
item.variantName && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("p", { className: "mt-0.5 text-xs text-muted-foreground", children: item.variantName }),
|
|
14980
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("p", { className: "mt-1 text-sm text-muted-foreground", children: [
|
|
14737
14981
|
formatPrice(item.unitPrice, currencyCode, locale),
|
|
14738
14982
|
" ",
|
|
14739
14983
|
t.unitPriceSuffix
|
|
14740
14984
|
] }),
|
|
14741
|
-
/* @__PURE__ */ (0,
|
|
14985
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(
|
|
14742
14986
|
"div",
|
|
14743
14987
|
{
|
|
14744
14988
|
role: "group",
|
|
14745
14989
|
"aria-label": t.quantityLabel,
|
|
14746
14990
|
className: "mt-3 flex items-center gap-3",
|
|
14747
14991
|
children: [
|
|
14748
|
-
/* @__PURE__ */ (0,
|
|
14992
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
|
|
14749
14993
|
"button",
|
|
14750
14994
|
{
|
|
14751
14995
|
type: "button",
|
|
@@ -14756,8 +15000,8 @@ function CartLineList({
|
|
|
14756
15000
|
children: "\u2212"
|
|
14757
15001
|
}
|
|
14758
15002
|
),
|
|
14759
|
-
/* @__PURE__ */ (0,
|
|
14760
|
-
/* @__PURE__ */ (0,
|
|
15003
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)("span", { className: "w-8 text-center text-sm font-semibold tabular-nums", children: item.quantity }),
|
|
15004
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
|
|
14761
15005
|
"button",
|
|
14762
15006
|
{
|
|
14763
15007
|
type: "button",
|
|
@@ -14768,7 +15012,7 @@ function CartLineList({
|
|
|
14768
15012
|
children: "+"
|
|
14769
15013
|
}
|
|
14770
15014
|
),
|
|
14771
|
-
onRemove && /* @__PURE__ */ (0,
|
|
15015
|
+
onRemove && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
|
|
14772
15016
|
"button",
|
|
14773
15017
|
{
|
|
14774
15018
|
type: "button",
|
|
@@ -14781,7 +15025,7 @@ function CartLineList({
|
|
|
14781
15025
|
]
|
|
14782
15026
|
}
|
|
14783
15027
|
),
|
|
14784
|
-
message != null && message !== false && /* @__PURE__ */ (0,
|
|
15028
|
+
message != null && message !== false && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
|
|
14785
15029
|
"p",
|
|
14786
15030
|
{
|
|
14787
15031
|
className: "mt-2 text-sm text-destructive",
|
|
@@ -14790,7 +15034,7 @@ function CartLineList({
|
|
|
14790
15034
|
}
|
|
14791
15035
|
)
|
|
14792
15036
|
] }),
|
|
14793
|
-
/* @__PURE__ */ (0,
|
|
15037
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { className: "flex-shrink-0 text-right", children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("p", { className: "text-base font-bold", children: formatPrice(item.unitPrice * item.quantity, currencyCode, locale) }) })
|
|
14794
15038
|
]
|
|
14795
15039
|
},
|
|
14796
15040
|
lineKey(item.productId, item.variantId)
|
|
@@ -14800,8 +15044,8 @@ function CartLineList({
|
|
|
14800
15044
|
}
|
|
14801
15045
|
|
|
14802
15046
|
// src/components/cart-summary.tsx
|
|
14803
|
-
var
|
|
14804
|
-
var
|
|
15047
|
+
var import_utils17 = require("@reblu/site-ui/utils");
|
|
15048
|
+
var import_jsx_runtime19 = require("react/jsx-runtime");
|
|
14805
15049
|
var DEFAULT_LABELS3 = {
|
|
14806
15050
|
subtotal: "Subtotal",
|
|
14807
15051
|
discountPrefix: "Descuento",
|
|
@@ -14831,37 +15075,37 @@ function CartSummary({
|
|
|
14831
15075
|
const hasDiscount = Boolean(discountAmount && discountAmount > 0);
|
|
14832
15076
|
const noticeContent = notice === true ? t.cancelledNotice : notice;
|
|
14833
15077
|
const hasNotice = noticeContent != null && noticeContent !== false;
|
|
14834
|
-
const breakdown = /* @__PURE__ */ (0,
|
|
15078
|
+
const breakdown = /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(
|
|
14835
15079
|
"dl",
|
|
14836
15080
|
{
|
|
14837
|
-
className: (0,
|
|
15081
|
+
className: (0, import_utils17.cn)("space-y-2 text-sm", !hasNotice && className),
|
|
14838
15082
|
"data-slot": "cart-summary",
|
|
14839
15083
|
children: [
|
|
14840
|
-
/* @__PURE__ */ (0,
|
|
14841
|
-
/* @__PURE__ */ (0,
|
|
14842
|
-
/* @__PURE__ */ (0,
|
|
15084
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "flex justify-between text-muted-foreground", children: [
|
|
15085
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)("dt", { children: t.subtotal }),
|
|
15086
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)("dd", { children: formatPrice(subtotal, currencyCode, locale) })
|
|
14843
15087
|
] }),
|
|
14844
|
-
hasDiscount && /* @__PURE__ */ (0,
|
|
14845
|
-
/* @__PURE__ */ (0,
|
|
14846
|
-
/* @__PURE__ */ (0,
|
|
15088
|
+
hasDiscount && /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "flex justify-between text-green-600 dark:text-green-400", children: [
|
|
15089
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)("dt", { children: autoDiscount ? t.staffDiscountApplied : `${t.discountPrefix}${discountCode ? ` (${discountCode})` : ""}` }),
|
|
15090
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("dd", { children: [
|
|
14847
15091
|
"-",
|
|
14848
15092
|
formatPrice(discountAmount, currencyCode, locale)
|
|
14849
15093
|
] })
|
|
14850
15094
|
] }),
|
|
14851
|
-
shippingEnabled && /* @__PURE__ */ (0,
|
|
14852
|
-
/* @__PURE__ */ (0,
|
|
14853
|
-
/* @__PURE__ */ (0,
|
|
15095
|
+
shippingEnabled && /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "flex justify-between text-muted-foreground", children: [
|
|
15096
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)("dt", { children: t.shipping }),
|
|
15097
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)("dd", { children: shipping == null || !Number.isFinite(shipping) ? t.shippingCalculated : shipping === 0 ? t.freeShipping : formatPrice(shipping, currencyCode, locale) })
|
|
14854
15098
|
] }),
|
|
14855
|
-
/* @__PURE__ */ (0,
|
|
14856
|
-
/* @__PURE__ */ (0,
|
|
14857
|
-
/* @__PURE__ */ (0,
|
|
15099
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "flex justify-between border-t border-border pt-2 text-base font-bold", children: [
|
|
15100
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)("dt", { children: t.total }),
|
|
15101
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)("dd", { children: formatPrice(total, currencyCode, locale) })
|
|
14858
15102
|
] })
|
|
14859
15103
|
]
|
|
14860
15104
|
}
|
|
14861
15105
|
);
|
|
14862
15106
|
if (!hasNotice) return breakdown;
|
|
14863
|
-
return /* @__PURE__ */ (0,
|
|
14864
|
-
/* @__PURE__ */ (0,
|
|
15107
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: (0, import_utils17.cn)("space-y-3", className), "data-slot": "cart-summary-wrapper", children: [
|
|
15108
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
14865
15109
|
"div",
|
|
14866
15110
|
{
|
|
14867
15111
|
role: "status",
|
|
@@ -14875,8 +15119,8 @@ function CartSummary({
|
|
|
14875
15119
|
}
|
|
14876
15120
|
|
|
14877
15121
|
// src/components/cart-adjustments-notice.tsx
|
|
14878
|
-
var
|
|
14879
|
-
var
|
|
15122
|
+
var import_utils18 = require("@reblu/site-ui/utils");
|
|
15123
|
+
var import_jsx_runtime20 = require("react/jsx-runtime");
|
|
14880
15124
|
var DEFAULT_LABELS4 = {
|
|
14881
15125
|
removed: (names) => names.length === 1 ? `Hemos quitado del carrito: ${names[0]}, ya no est\xE1 disponible.` : `Hemos quitado del carrito: ${names.join(", ")}, ya no est\xE1n disponibles.`,
|
|
14882
15126
|
quantityChanged: (name, quantity) => `Hemos ajustado la cantidad de ${name} a ${quantity} por el stock disponible.`,
|
|
@@ -14910,20 +15154,20 @@ function CartAdjustmentsNotice({
|
|
|
14910
15154
|
);
|
|
14911
15155
|
}
|
|
14912
15156
|
if (messages.length === 0) return null;
|
|
14913
|
-
return /* @__PURE__ */ (0,
|
|
15157
|
+
return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
14914
15158
|
"div",
|
|
14915
15159
|
{
|
|
14916
15160
|
role: "status",
|
|
14917
|
-
className: (0,
|
|
15161
|
+
className: (0, import_utils18.cn)("rounded-lg border border-border bg-muted px-3 py-2 text-sm", className),
|
|
14918
15162
|
"data-slot": "cart-adjustments-notice",
|
|
14919
|
-
children: messages.length === 1 ? /* @__PURE__ */ (0,
|
|
15163
|
+
children: messages.length === 1 ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("p", { children: messages[0] }) : /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("ul", { className: "list-disc space-y-1 pl-4", children: messages.map((message, index) => /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("li", { children: message }, index)) })
|
|
14920
15164
|
}
|
|
14921
15165
|
);
|
|
14922
15166
|
}
|
|
14923
15167
|
|
|
14924
15168
|
// src/components/added-to-cart-toast.tsx
|
|
14925
|
-
var
|
|
14926
|
-
var
|
|
15169
|
+
var import_utils19 = require("@reblu/site-ui/utils");
|
|
15170
|
+
var import_jsx_runtime21 = (
|
|
14927
15171
|
// eslint-disable-next-line @next/next/no-img-element -- toast content, not a Next <Image> layout context
|
|
14928
15172
|
require("react/jsx-runtime")
|
|
14929
15173
|
);
|
|
@@ -14946,32 +15190,32 @@ function AddedToCartToast({
|
|
|
14946
15190
|
const message = status === "error" ? t.error : status === "outOfStock" ? t.outOfStock : t.success;
|
|
14947
15191
|
const hasThumbnail = Boolean(imageUrl && imageUrl.trim().length > 0);
|
|
14948
15192
|
const variant = status === "success" ? "success" : "error";
|
|
14949
|
-
return /* @__PURE__ */ (0,
|
|
15193
|
+
return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(
|
|
14950
15194
|
"div",
|
|
14951
15195
|
{
|
|
14952
15196
|
"data-slot": "added-to-cart-toast",
|
|
14953
15197
|
"data-variant": variant,
|
|
14954
|
-
className: (0,
|
|
15198
|
+
className: (0, import_utils19.cn)(
|
|
14955
15199
|
"flex items-center gap-3 rounded-xl border border-border bg-card p-3 text-sm shadow-lg",
|
|
14956
15200
|
variant === "success" && "border-green-600/30 dark:border-green-400/30",
|
|
14957
15201
|
variant === "error" && "border-destructive/30",
|
|
14958
15202
|
className
|
|
14959
15203
|
),
|
|
14960
15204
|
children: [
|
|
14961
|
-
hasThumbnail && /* @__PURE__ */ (0,
|
|
14962
|
-
/* @__PURE__ */ (0,
|
|
14963
|
-
/* @__PURE__ */ (0,
|
|
14964
|
-
/* @__PURE__ */ (0,
|
|
15205
|
+
hasThumbnail && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("img", { src: imageUrl, alt: productName, className: "h-10 w-10 flex-shrink-0 rounded-lg object-cover" }),
|
|
15206
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "min-w-0 flex-1", children: [
|
|
15207
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.jsx)("p", { className: "truncate font-semibold text-foreground", children: productName }),
|
|
15208
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.jsx)("p", { className: "truncate text-muted-foreground", children: quantity && quantity > 1 ? `${message} \xB7 x${quantity}` : message })
|
|
14965
15209
|
] }),
|
|
14966
|
-
/* @__PURE__ */ (0,
|
|
15210
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className: "flex-shrink-0", children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("a", { href: cartHref, className: "text-sm font-semibold text-primary underline-offset-2 hover:underline", children: t.viewCart }) })
|
|
14967
15211
|
]
|
|
14968
15212
|
}
|
|
14969
15213
|
);
|
|
14970
15214
|
}
|
|
14971
15215
|
|
|
14972
15216
|
// src/components/checkout-login-prompt.tsx
|
|
14973
|
-
var
|
|
14974
|
-
var
|
|
15217
|
+
var import_utils20 = require("@reblu/site-ui/utils");
|
|
15218
|
+
var import_jsx_runtime22 = require("react/jsx-runtime");
|
|
14975
15219
|
var DEFAULT_LABELS6 = {
|
|
14976
15220
|
title: "Identificaci\xF3n",
|
|
14977
15221
|
description: "Introduce tu email para agilizar el proceso o contin\xFAa como invitado.",
|
|
@@ -14998,26 +15242,26 @@ function CheckoutLoginPrompt({
|
|
|
14998
15242
|
if (!open) return null;
|
|
14999
15243
|
const t = { ...DEFAULT_LABELS6, ...labels };
|
|
15000
15244
|
const isValidEmail = EMAIL_PATTERN.test(email.trim());
|
|
15001
|
-
return /* @__PURE__ */ (0,
|
|
15002
|
-
/* @__PURE__ */ (0,
|
|
15003
|
-
/* @__PURE__ */ (0,
|
|
15245
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(import_jsx_runtime22.Fragment, { children: [
|
|
15246
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)("div", { className: "fixed inset-0 z-50 bg-black/50", onClick: onClose, "aria-hidden": "true" }),
|
|
15247
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(
|
|
15004
15248
|
"div",
|
|
15005
15249
|
{
|
|
15006
15250
|
role: "dialog",
|
|
15007
15251
|
"aria-modal": "true",
|
|
15008
15252
|
"aria-labelledby": "checkout-login-prompt-title",
|
|
15009
15253
|
"data-slot": "checkout-login-prompt",
|
|
15010
|
-
className: (0,
|
|
15254
|
+
className: (0, import_utils20.cn)(
|
|
15011
15255
|
"fixed left-1/2 top-1/2 z-50 w-full max-w-md -translate-x-1/2 -translate-y-1/2 space-y-5 rounded-2xl border border-border bg-background p-6 shadow-2xl",
|
|
15012
15256
|
className
|
|
15013
15257
|
),
|
|
15014
15258
|
children: [
|
|
15015
|
-
/* @__PURE__ */ (0,
|
|
15016
|
-
/* @__PURE__ */ (0,
|
|
15017
|
-
/* @__PURE__ */ (0,
|
|
15018
|
-
/* @__PURE__ */ (0,
|
|
15259
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "flex items-start justify-between gap-3", children: [
|
|
15260
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { children: [
|
|
15261
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)("h2", { id: "checkout-login-prompt-title", className: "text-xl font-bold", children: t.title }),
|
|
15262
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)("p", { className: "mt-1 text-sm text-muted-foreground", children: t.description })
|
|
15019
15263
|
] }),
|
|
15020
|
-
/* @__PURE__ */ (0,
|
|
15264
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
15021
15265
|
"button",
|
|
15022
15266
|
{
|
|
15023
15267
|
type: "button",
|
|
@@ -15028,9 +15272,9 @@ function CheckoutLoginPrompt({
|
|
|
15028
15272
|
}
|
|
15029
15273
|
)
|
|
15030
15274
|
] }),
|
|
15031
|
-
/* @__PURE__ */ (0,
|
|
15032
|
-
/* @__PURE__ */ (0,
|
|
15033
|
-
/* @__PURE__ */ (0,
|
|
15275
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "space-y-2", children: [
|
|
15276
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)("label", { htmlFor: "checkout-login-prompt-email", className: "text-sm font-medium", children: t.emailLabel }),
|
|
15277
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
15034
15278
|
"input",
|
|
15035
15279
|
{
|
|
15036
15280
|
id: "checkout-login-prompt-email",
|
|
@@ -15039,29 +15283,29 @@ function CheckoutLoginPrompt({
|
|
|
15039
15283
|
value: email,
|
|
15040
15284
|
onChange: (e) => onEmailChange(e.target.value),
|
|
15041
15285
|
placeholder: t.emailPlaceholder,
|
|
15042
|
-
className: (0,
|
|
15286
|
+
className: (0, import_utils20.cn)(
|
|
15043
15287
|
"w-full rounded-lg border bg-background px-3 py-2 text-sm transition focus:outline-none focus:ring-2 focus:ring-primary/20",
|
|
15044
15288
|
error ? "border-destructive" : "border-border focus:border-primary"
|
|
15045
15289
|
)
|
|
15046
15290
|
}
|
|
15047
15291
|
),
|
|
15048
|
-
error && /* @__PURE__ */ (0,
|
|
15292
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("p", { className: "text-xs text-destructive", children: error })
|
|
15049
15293
|
] }),
|
|
15050
|
-
/* @__PURE__ */ (0,
|
|
15051
|
-
/* @__PURE__ */ (0,
|
|
15294
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "space-y-2", children: [
|
|
15295
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
15052
15296
|
"button",
|
|
15053
15297
|
{
|
|
15054
15298
|
type: "button",
|
|
15055
15299
|
onClick: onSubmitEmail,
|
|
15056
15300
|
disabled: checking || !isValidEmail,
|
|
15057
|
-
className: (0,
|
|
15301
|
+
className: (0, import_utils20.cn)(
|
|
15058
15302
|
"flex w-full cursor-pointer items-center justify-center gap-2 rounded-xl px-4 py-2.5 text-sm font-semibold transition-all",
|
|
15059
15303
|
checking || !isValidEmail ? "cursor-not-allowed bg-muted text-muted-foreground" : "bg-primary text-primary-foreground hover:bg-primary/90"
|
|
15060
15304
|
),
|
|
15061
15305
|
children: checking ? t.checking : t.continueWithEmail
|
|
15062
15306
|
}
|
|
15063
15307
|
),
|
|
15064
|
-
/* @__PURE__ */ (0,
|
|
15308
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
15065
15309
|
"button",
|
|
15066
15310
|
{
|
|
15067
15311
|
type: "button",
|
|
@@ -15078,9 +15322,9 @@ function CheckoutLoginPrompt({
|
|
|
15078
15322
|
}
|
|
15079
15323
|
|
|
15080
15324
|
// src/components/checkout-form.tsx
|
|
15081
|
-
var
|
|
15325
|
+
var import_utils21 = require("@reblu/site-ui/utils");
|
|
15082
15326
|
var import_phone_input = require("@reblu/site-ui/phone-input");
|
|
15083
|
-
var
|
|
15327
|
+
var import_jsx_runtime23 = require("react/jsx-runtime");
|
|
15084
15328
|
var DEFAULT_LABELS7 = {
|
|
15085
15329
|
contactTitle: "Datos de contacto",
|
|
15086
15330
|
nameLabel: "Nombre completo",
|
|
@@ -15136,22 +15380,22 @@ function CheckoutForm({
|
|
|
15136
15380
|
event.preventDefault();
|
|
15137
15381
|
if (discountCode.trim() && !discountApplying) onApplyDiscount();
|
|
15138
15382
|
}
|
|
15139
|
-
return /* @__PURE__ */ (0,
|
|
15383
|
+
return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(import_jsx_runtime23.Fragment, { children: [
|
|
15140
15384
|
loginPrompt,
|
|
15141
|
-
/* @__PURE__ */ (0,
|
|
15385
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
|
|
15142
15386
|
"form",
|
|
15143
15387
|
{
|
|
15144
15388
|
"data-testid": "checkout-form",
|
|
15145
15389
|
onSubmit,
|
|
15146
|
-
className: (0,
|
|
15390
|
+
className: (0, import_utils21.cn)("space-y-8", className),
|
|
15147
15391
|
"data-slot": "checkout-form",
|
|
15148
15392
|
children: [
|
|
15149
|
-
/* @__PURE__ */ (0,
|
|
15150
|
-
/* @__PURE__ */ (0,
|
|
15151
|
-
/* @__PURE__ */ (0,
|
|
15152
|
-
/* @__PURE__ */ (0,
|
|
15153
|
-
/* @__PURE__ */ (0,
|
|
15154
|
-
/* @__PURE__ */ (0,
|
|
15393
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("section", { className: "space-y-4", children: [
|
|
15394
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)("h2", { className: "border-b border-border pb-2 text-lg font-semibold", children: t.contactTitle }),
|
|
15395
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("div", { className: "grid grid-cols-1 gap-4 sm:grid-cols-2", children: [
|
|
15396
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("div", { className: "space-y-1", children: [
|
|
15397
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)("label", { htmlFor: "checkout-form-name", className: "text-sm font-medium", children: t.nameLabel }),
|
|
15398
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
15155
15399
|
"input",
|
|
15156
15400
|
{
|
|
15157
15401
|
id: "checkout-form-name",
|
|
@@ -15160,17 +15404,17 @@ function CheckoutForm({
|
|
|
15160
15404
|
value: contact.name,
|
|
15161
15405
|
onChange: (e) => patchContact({ name: e.target.value }),
|
|
15162
15406
|
placeholder: t.namePlaceholder,
|
|
15163
|
-
className: (0,
|
|
15407
|
+
className: (0, import_utils21.cn)(
|
|
15164
15408
|
"w-full rounded-lg border bg-background px-3 py-2 text-sm transition focus:outline-none focus:ring-2 focus:ring-primary/20",
|
|
15165
15409
|
contactErrors?.name ? "border-destructive" : "border-border focus:border-primary"
|
|
15166
15410
|
)
|
|
15167
15411
|
}
|
|
15168
15412
|
),
|
|
15169
|
-
contactErrors?.name && /* @__PURE__ */ (0,
|
|
15413
|
+
contactErrors?.name && /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("p", { className: "text-xs text-destructive", children: contactErrors.name })
|
|
15170
15414
|
] }),
|
|
15171
|
-
/* @__PURE__ */ (0,
|
|
15172
|
-
/* @__PURE__ */ (0,
|
|
15173
|
-
/* @__PURE__ */ (0,
|
|
15415
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("div", { className: "space-y-1", children: [
|
|
15416
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)("label", { htmlFor: "checkout-form-email", className: "text-sm font-medium", children: t.emailLabel }),
|
|
15417
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
15174
15418
|
"input",
|
|
15175
15419
|
{
|
|
15176
15420
|
id: "checkout-form-email",
|
|
@@ -15179,15 +15423,15 @@ function CheckoutForm({
|
|
|
15179
15423
|
value: contact.email,
|
|
15180
15424
|
onChange: (e) => patchContact({ email: e.target.value }),
|
|
15181
15425
|
placeholder: t.emailPlaceholder,
|
|
15182
|
-
className: (0,
|
|
15426
|
+
className: (0, import_utils21.cn)(
|
|
15183
15427
|
"w-full rounded-lg border bg-background px-3 py-2 text-sm transition focus:outline-none focus:ring-2 focus:ring-primary/20",
|
|
15184
15428
|
contactErrors?.email ? "border-destructive" : "border-border focus:border-primary"
|
|
15185
15429
|
)
|
|
15186
15430
|
}
|
|
15187
15431
|
),
|
|
15188
|
-
contactErrors?.email && /* @__PURE__ */ (0,
|
|
15432
|
+
contactErrors?.email && /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("p", { className: "text-xs text-destructive", children: contactErrors.email })
|
|
15189
15433
|
] }),
|
|
15190
|
-
/* @__PURE__ */ (0,
|
|
15434
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)("div", { className: "space-y-1", children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
15191
15435
|
import_phone_input.PhoneInput,
|
|
15192
15436
|
{
|
|
15193
15437
|
id: "checkout-form-phone",
|
|
@@ -15201,26 +15445,26 @@ function CheckoutForm({
|
|
|
15201
15445
|
] })
|
|
15202
15446
|
] }),
|
|
15203
15447
|
children2,
|
|
15204
|
-
generalError ? /* @__PURE__ */ (0,
|
|
15205
|
-
/* @__PURE__ */ (0,
|
|
15206
|
-
/* @__PURE__ */ (0,
|
|
15207
|
-
autoDiscount ? /* @__PURE__ */ (0,
|
|
15448
|
+
generalError ? /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("p", { role: "alert", className: "text-sm text-destructive", children: generalError }) : null,
|
|
15449
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("section", { className: "space-y-3", children: [
|
|
15450
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)("h2", { className: "border-b border-border pb-2 text-lg font-semibold", children: t.discountTitle }),
|
|
15451
|
+
autoDiscount ? /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
|
|
15208
15452
|
"div",
|
|
15209
15453
|
{
|
|
15210
15454
|
className: "flex items-center gap-2 rounded-lg border border-green-200 bg-green-50 px-4 py-3 text-sm text-green-700 dark:border-green-800 dark:bg-green-900/20 dark:text-green-400",
|
|
15211
15455
|
"data-slot": "checkout-staff-discount",
|
|
15212
15456
|
children: [
|
|
15213
|
-
/* @__PURE__ */ (0,
|
|
15214
|
-
/* @__PURE__ */ (0,
|
|
15457
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { className: "font-semibold", children: t.staffDiscountApplied }),
|
|
15458
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { children: t.discountAppliedSuffix(formatPrice(autoDiscount.amount, currencyCode, locale)) })
|
|
15215
15459
|
]
|
|
15216
15460
|
}
|
|
15217
15461
|
) : null,
|
|
15218
|
-
appliedDiscount && !autoDiscount ? /* @__PURE__ */ (0,
|
|
15219
|
-
/* @__PURE__ */ (0,
|
|
15220
|
-
/* @__PURE__ */ (0,
|
|
15221
|
-
/* @__PURE__ */ (0,
|
|
15462
|
+
appliedDiscount && !autoDiscount ? /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("div", { className: "flex items-center justify-between rounded-lg border border-green-200 bg-green-50 px-4 py-3 dark:border-green-800 dark:bg-green-900/20", children: [
|
|
15463
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("div", { className: "flex items-center gap-2 text-sm text-green-700 dark:text-green-400", children: [
|
|
15464
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { className: "font-semibold", children: appliedDiscount.code }),
|
|
15465
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { children: t.discountAppliedSuffix(formatPrice(appliedDiscount.amount, currencyCode, locale)) })
|
|
15222
15466
|
] }),
|
|
15223
|
-
/* @__PURE__ */ (0,
|
|
15467
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
15224
15468
|
"button",
|
|
15225
15469
|
{
|
|
15226
15470
|
type: "button",
|
|
@@ -15230,9 +15474,9 @@ function CheckoutForm({
|
|
|
15230
15474
|
children: t.removeDiscount
|
|
15231
15475
|
}
|
|
15232
15476
|
)
|
|
15233
|
-
] }) : /* @__PURE__ */ (0,
|
|
15234
|
-
/* @__PURE__ */ (0,
|
|
15235
|
-
/* @__PURE__ */ (0,
|
|
15477
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("div", { className: "flex gap-2", children: [
|
|
15478
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)("label", { htmlFor: "checkout-form-discount-code", className: "sr-only", children: t.discountTitle }),
|
|
15479
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
15236
15480
|
"input",
|
|
15237
15481
|
{
|
|
15238
15482
|
id: "checkout-form-discount-code",
|
|
@@ -15244,7 +15488,7 @@ function CheckoutForm({
|
|
|
15244
15488
|
className: "flex-1 rounded-lg border border-border bg-background px-3 py-2 text-sm uppercase transition focus:border-primary focus:outline-none focus:ring-2 focus:ring-primary/20"
|
|
15245
15489
|
}
|
|
15246
15490
|
),
|
|
15247
|
-
/* @__PURE__ */ (0,
|
|
15491
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
15248
15492
|
"button",
|
|
15249
15493
|
{
|
|
15250
15494
|
type: "button",
|
|
@@ -15255,14 +15499,14 @@ function CheckoutForm({
|
|
|
15255
15499
|
}
|
|
15256
15500
|
)
|
|
15257
15501
|
] }),
|
|
15258
|
-
discountError && /* @__PURE__ */ (0,
|
|
15502
|
+
discountError && /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("p", { className: "text-xs text-destructive", children: discountError })
|
|
15259
15503
|
] }),
|
|
15260
|
-
/* @__PURE__ */ (0,
|
|
15504
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
15261
15505
|
"button",
|
|
15262
15506
|
{
|
|
15263
15507
|
type: "submit",
|
|
15264
15508
|
disabled: submitting || submitDisabled,
|
|
15265
|
-
className: (0,
|
|
15509
|
+
className: (0, import_utils21.cn)(
|
|
15266
15510
|
"flex w-full cursor-pointer items-center justify-center gap-2 rounded-xl px-4 py-3 font-semibold transition-all",
|
|
15267
15511
|
submitting || submitDisabled ? "cursor-not-allowed bg-muted text-muted-foreground" : "bg-primary text-primary-foreground hover:bg-primary/90"
|
|
15268
15512
|
),
|
|
@@ -15276,11 +15520,11 @@ function CheckoutForm({
|
|
|
15276
15520
|
}
|
|
15277
15521
|
|
|
15278
15522
|
// src/components/order-confirmation.tsx
|
|
15279
|
-
var
|
|
15523
|
+
var import_utils23 = require("@reblu/site-ui/utils");
|
|
15280
15524
|
|
|
15281
15525
|
// src/components/order-invoice-link.tsx
|
|
15282
|
-
var
|
|
15283
|
-
var
|
|
15526
|
+
var import_utils22 = require("@reblu/site-ui/utils");
|
|
15527
|
+
var import_jsx_runtime24 = require("react/jsx-runtime");
|
|
15284
15528
|
var DEFAULT_LABELS8 = {
|
|
15285
15529
|
linkLabel: "Descargar la factura {number}",
|
|
15286
15530
|
signInHint: "Te pediremos que inicies sesi\xF3n para abrirla."
|
|
@@ -15288,8 +15532,8 @@ var DEFAULT_LABELS8 = {
|
|
|
15288
15532
|
function OrderInvoiceLink({ invoice, labels, className }) {
|
|
15289
15533
|
if (!invoice) return null;
|
|
15290
15534
|
const t = { ...DEFAULT_LABELS8, ...labels };
|
|
15291
|
-
return /* @__PURE__ */ (0,
|
|
15292
|
-
/* @__PURE__ */ (0,
|
|
15535
|
+
return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("div", { className: (0, import_utils22.cn)("space-y-1 text-sm", className), "data-slot": "order-invoice-link", children: [
|
|
15536
|
+
/* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
|
|
15293
15537
|
"a",
|
|
15294
15538
|
{
|
|
15295
15539
|
href: invoice.url,
|
|
@@ -15297,12 +15541,12 @@ function OrderInvoiceLink({ invoice, labels, className }) {
|
|
|
15297
15541
|
children: t.linkLabel.replace("{number}", invoice.number)
|
|
15298
15542
|
}
|
|
15299
15543
|
),
|
|
15300
|
-
/* @__PURE__ */ (0,
|
|
15544
|
+
/* @__PURE__ */ (0, import_jsx_runtime24.jsx)("p", { className: "text-muted-foreground", children: t.signInHint })
|
|
15301
15545
|
] });
|
|
15302
15546
|
}
|
|
15303
15547
|
|
|
15304
15548
|
// src/components/order-confirmation.tsx
|
|
15305
|
-
var
|
|
15549
|
+
var import_jsx_runtime25 = require("react/jsx-runtime");
|
|
15306
15550
|
var DEFAULT_LABELS9 = {
|
|
15307
15551
|
pollingTitle: "Confirmando tu pedido\u2026",
|
|
15308
15552
|
pollingDescription: "Estamos procesando el pago, un momento\u2026",
|
|
@@ -15368,43 +15612,43 @@ function OrderConfirmation({
|
|
|
15368
15612
|
const showOrderReference = Boolean(order) && !showFullOrderSummary && (status === "refunded" || status === "partially_refunded" || status === "pending_timeout");
|
|
15369
15613
|
const showSessionReference = !order && sessionId && (status === "timeout" || status === "not_found" || status === "pending_timeout");
|
|
15370
15614
|
const showRecheck = (status === "pending_timeout" || status === "error") && onRecheck;
|
|
15371
|
-
return /* @__PURE__ */ (0,
|
|
15372
|
-
/* @__PURE__ */ (0,
|
|
15373
|
-
/* @__PURE__ */ (0,
|
|
15374
|
-
showFullOrderSummary && order && /* @__PURE__ */ (0,
|
|
15375
|
-
/* @__PURE__ */ (0,
|
|
15376
|
-
/* @__PURE__ */ (0,
|
|
15377
|
-
/* @__PURE__ */ (0,
|
|
15615
|
+
return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { className: (0, import_utils23.cn)("space-y-6 text-center", className), "data-slot": "order-confirmation", children: [
|
|
15616
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("h1", { className: "text-3xl font-bold", children: title }),
|
|
15617
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("p", { className: "text-lg text-muted-foreground", children: description }),
|
|
15618
|
+
showFullOrderSummary && order && /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { className: "space-y-6", children: [
|
|
15619
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { className: "inline-block rounded-xl bg-muted px-6 py-4", children: [
|
|
15620
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("p", { className: "mb-1 text-xs uppercase tracking-widest text-muted-foreground", children: t.orderNumberLabel }),
|
|
15621
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("p", { className: "font-mono text-lg font-semibold", children: order.orderNumber })
|
|
15378
15622
|
] }),
|
|
15379
|
-
/* @__PURE__ */ (0,
|
|
15380
|
-
order.items.map((item, idx) => /* @__PURE__ */ (0,
|
|
15623
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { className: "mx-auto max-w-sm space-y-3 rounded-xl border border-border bg-card p-5 text-left", children: [
|
|
15624
|
+
order.items.map((item, idx) => /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
|
|
15381
15625
|
"div",
|
|
15382
15626
|
{
|
|
15383
15627
|
className: "flex justify-between gap-4 text-sm",
|
|
15384
15628
|
children: [
|
|
15385
|
-
/* @__PURE__ */ (0,
|
|
15629
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("span", { className: "max-w-[60%] truncate text-muted-foreground", children: [
|
|
15386
15630
|
item.product.name,
|
|
15387
15631
|
item.variant ? ` (${item.variant.name})` : "",
|
|
15388
15632
|
" x",
|
|
15389
15633
|
item.quantity
|
|
15390
15634
|
] }),
|
|
15391
|
-
/* @__PURE__ */ (0,
|
|
15635
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", { children: formatPrice(item.total, currencyCode, locale) })
|
|
15392
15636
|
]
|
|
15393
15637
|
},
|
|
15394
15638
|
idx
|
|
15395
15639
|
)),
|
|
15396
|
-
/* @__PURE__ */ (0,
|
|
15397
|
-
/* @__PURE__ */ (0,
|
|
15398
|
-
/* @__PURE__ */ (0,
|
|
15640
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("div", { className: "space-y-1 border-t border-border pt-3 text-sm", children: /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { className: "flex justify-between pt-1 text-base font-bold", children: [
|
|
15641
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", { children: t.totalLabel }),
|
|
15642
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", { children: formatPrice(order.total, currencyCode, locale) })
|
|
15399
15643
|
] }) })
|
|
15400
15644
|
] }),
|
|
15401
|
-
/* @__PURE__ */ (0,
|
|
15645
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("p", { className: "mx-auto max-w-sm text-sm text-muted-foreground", children: [
|
|
15402
15646
|
t.confirmationEmailPrefix,
|
|
15403
15647
|
" ",
|
|
15404
|
-
/* @__PURE__ */ (0,
|
|
15648
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", { className: "font-medium text-foreground", children: order.customerEmail }),
|
|
15405
15649
|
"."
|
|
15406
15650
|
] }),
|
|
15407
|
-
/* @__PURE__ */ (0,
|
|
15651
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
15408
15652
|
OrderInvoiceLink,
|
|
15409
15653
|
{
|
|
15410
15654
|
invoice: order.invoice,
|
|
@@ -15412,11 +15656,11 @@ function OrderConfirmation({
|
|
|
15412
15656
|
}
|
|
15413
15657
|
)
|
|
15414
15658
|
] }),
|
|
15415
|
-
showOrderReference && order && /* @__PURE__ */ (0,
|
|
15416
|
-
/* @__PURE__ */ (0,
|
|
15417
|
-
/* @__PURE__ */ (0,
|
|
15659
|
+
showOrderReference && order && /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { className: "inline-block rounded-xl bg-muted px-6 py-4", children: [
|
|
15660
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("p", { className: "mb-1 text-xs uppercase tracking-widest text-muted-foreground", children: t.orderReferenceLabel }),
|
|
15661
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("p", { className: "font-mono text-lg font-semibold", children: order.orderNumber })
|
|
15418
15662
|
] }),
|
|
15419
|
-
status === "failed" && cartHref && /* @__PURE__ */ (0,
|
|
15663
|
+
status === "failed" && cartHref && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
15420
15664
|
"a",
|
|
15421
15665
|
{
|
|
15422
15666
|
href: cartHref,
|
|
@@ -15424,7 +15668,7 @@ function OrderConfirmation({
|
|
|
15424
15668
|
children: t.backToCartLabel
|
|
15425
15669
|
}
|
|
15426
15670
|
),
|
|
15427
|
-
showRecheck && /* @__PURE__ */ (0,
|
|
15671
|
+
showRecheck && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
15428
15672
|
"button",
|
|
15429
15673
|
{
|
|
15430
15674
|
type: "button",
|
|
@@ -15433,16 +15677,16 @@ function OrderConfirmation({
|
|
|
15433
15677
|
children: t.recheckLabel
|
|
15434
15678
|
}
|
|
15435
15679
|
),
|
|
15436
|
-
showSessionReference && /* @__PURE__ */ (0,
|
|
15437
|
-
/* @__PURE__ */ (0,
|
|
15438
|
-
/* @__PURE__ */ (0,
|
|
15680
|
+
showSessionReference && /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { className: "inline-block rounded-xl bg-muted px-6 py-4", children: [
|
|
15681
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("p", { className: "mb-1 text-xs uppercase tracking-widest text-muted-foreground", children: t.sessionReferenceLabel }),
|
|
15682
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("p", { className: "break-all font-mono text-sm font-semibold", children: sessionId })
|
|
15439
15683
|
] })
|
|
15440
15684
|
] });
|
|
15441
15685
|
}
|
|
15442
15686
|
|
|
15443
15687
|
// src/components/full-invoice-fields.tsx
|
|
15444
|
-
var
|
|
15445
|
-
var
|
|
15688
|
+
var import_utils24 = require("@reblu/site-ui/utils");
|
|
15689
|
+
var import_jsx_runtime26 = require("react/jsx-runtime");
|
|
15446
15690
|
var EMPTY_FULL_INVOICE_VALUE = {
|
|
15447
15691
|
wantsFullInvoice: false,
|
|
15448
15692
|
billingIdType: "NIF",
|
|
@@ -15559,12 +15803,12 @@ function FullInvoiceFields({
|
|
|
15559
15803
|
const showFields = value.wantsFullInvoice || overCap;
|
|
15560
15804
|
const isSpanishNif = value.billingIdType === "NIF";
|
|
15561
15805
|
const set = (key2, next2) => onChange({ ...value, [key2]: next2 });
|
|
15562
|
-
const error = (key2) => errors[key2] ? /* @__PURE__ */ (0,
|
|
15806
|
+
const error = (key2) => errors[key2] ? /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("p", { id: `full-invoice-${key2}-error`, className: "text-sm text-destructive", children: errors[key2] }) : null;
|
|
15563
15807
|
const invalid2 = (key2) => errors[key2] ? { "aria-invalid": true, "aria-describedby": `full-invoice-${key2}-error` } : {};
|
|
15564
|
-
return /* @__PURE__ */ (0,
|
|
15565
|
-
overCap ? /* @__PURE__ */ (0,
|
|
15566
|
-
/* @__PURE__ */ (0,
|
|
15567
|
-
/* @__PURE__ */ (0,
|
|
15808
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("section", { className: (0, import_utils24.cn)("space-y-4", className), "data-slot": "full-invoice-fields", children: [
|
|
15809
|
+
overCap ? /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("p", { role: "note", className: "rounded-lg border border-border p-4 text-sm", children: t.overCapNotice }) : /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "space-y-1", children: [
|
|
15810
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("label", { className: "flex items-center gap-2 text-sm font-medium", children: [
|
|
15811
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
15568
15812
|
"input",
|
|
15569
15813
|
{
|
|
15570
15814
|
type: "checkbox",
|
|
@@ -15574,12 +15818,12 @@ function FullInvoiceFields({
|
|
|
15574
15818
|
),
|
|
15575
15819
|
t.toggle
|
|
15576
15820
|
] }),
|
|
15577
|
-
/* @__PURE__ */ (0,
|
|
15821
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)("p", { className: "text-sm text-muted-foreground", children: t.underCapNotice })
|
|
15578
15822
|
] }),
|
|
15579
|
-
showFields && /* @__PURE__ */ (0,
|
|
15580
|
-
/* @__PURE__ */ (0,
|
|
15581
|
-
/* @__PURE__ */ (0,
|
|
15582
|
-
/* @__PURE__ */ (0,
|
|
15823
|
+
showFields && /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "grid grid-cols-1 gap-4 sm:grid-cols-2", children: [
|
|
15824
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "space-y-1", children: [
|
|
15825
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)("label", { htmlFor: "full-invoice-id-type", className: "text-sm font-medium", children: t.idType }),
|
|
15826
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
15583
15827
|
"select",
|
|
15584
15828
|
{
|
|
15585
15829
|
id: "full-invoice-id-type",
|
|
@@ -15588,14 +15832,14 @@ function FullInvoiceFields({
|
|
|
15588
15832
|
value: value.billingIdType,
|
|
15589
15833
|
onChange: (e) => set("billingIdType", e.target.value),
|
|
15590
15834
|
...invalid2("billingIdType"),
|
|
15591
|
-
children: ID_TYPES.map((type) => /* @__PURE__ */ (0,
|
|
15835
|
+
children: ID_TYPES.map((type) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("option", { value: type, children: t.idTypeOptions[type] }, type))
|
|
15592
15836
|
}
|
|
15593
15837
|
),
|
|
15594
15838
|
error("billingIdType")
|
|
15595
15839
|
] }),
|
|
15596
|
-
!isSpanishNif && /* @__PURE__ */ (0,
|
|
15597
|
-
/* @__PURE__ */ (0,
|
|
15598
|
-
/* @__PURE__ */ (0,
|
|
15840
|
+
!isSpanishNif && /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "space-y-1", children: [
|
|
15841
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)("label", { htmlFor: "full-invoice-id-country", className: "text-sm font-medium", children: t.idCountry }),
|
|
15842
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
|
|
15599
15843
|
"select",
|
|
15600
15844
|
{
|
|
15601
15845
|
id: "full-invoice-id-country",
|
|
@@ -15605,16 +15849,16 @@ function FullInvoiceFields({
|
|
|
15605
15849
|
onChange: (e) => set("billingIdCountry", e.target.value),
|
|
15606
15850
|
...invalid2("billingIdCountry"),
|
|
15607
15851
|
children: [
|
|
15608
|
-
/* @__PURE__ */ (0,
|
|
15609
|
-
countries.map((c) => /* @__PURE__ */ (0,
|
|
15852
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)("option", { value: "", disabled: true, children: t.chooseCountry }),
|
|
15853
|
+
countries.map((c) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("option", { value: c.code, children: c.name }, c.code))
|
|
15610
15854
|
]
|
|
15611
15855
|
}
|
|
15612
15856
|
),
|
|
15613
15857
|
error("billingIdCountry")
|
|
15614
15858
|
] }),
|
|
15615
|
-
/* @__PURE__ */ (0,
|
|
15616
|
-
/* @__PURE__ */ (0,
|
|
15617
|
-
/* @__PURE__ */ (0,
|
|
15859
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "space-y-1", children: [
|
|
15860
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)("label", { htmlFor: "full-invoice-nif", className: "text-sm font-medium", children: isSpanishNif ? t.spanishNif : t.documentNumber }),
|
|
15861
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
15618
15862
|
"input",
|
|
15619
15863
|
{
|
|
15620
15864
|
id: "full-invoice-nif",
|
|
@@ -15627,9 +15871,9 @@ function FullInvoiceFields({
|
|
|
15627
15871
|
),
|
|
15628
15872
|
error("billingNif")
|
|
15629
15873
|
] }),
|
|
15630
|
-
/* @__PURE__ */ (0,
|
|
15631
|
-
/* @__PURE__ */ (0,
|
|
15632
|
-
/* @__PURE__ */ (0,
|
|
15874
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "space-y-1", children: [
|
|
15875
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)("label", { htmlFor: "full-invoice-name", className: "text-sm font-medium", children: t.name }),
|
|
15876
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
15633
15877
|
"input",
|
|
15634
15878
|
{
|
|
15635
15879
|
id: "full-invoice-name",
|
|
@@ -15642,9 +15886,9 @@ function FullInvoiceFields({
|
|
|
15642
15886
|
),
|
|
15643
15887
|
error("billingName")
|
|
15644
15888
|
] }),
|
|
15645
|
-
/* @__PURE__ */ (0,
|
|
15646
|
-
/* @__PURE__ */ (0,
|
|
15647
|
-
/* @__PURE__ */ (0,
|
|
15889
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "space-y-1 sm:col-span-2", children: [
|
|
15890
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)("label", { htmlFor: "full-invoice-street", className: "text-sm font-medium", children: t.street }),
|
|
15891
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
15648
15892
|
"input",
|
|
15649
15893
|
{
|
|
15650
15894
|
id: "full-invoice-street",
|
|
@@ -15656,9 +15900,9 @@ function FullInvoiceFields({
|
|
|
15656
15900
|
}
|
|
15657
15901
|
)
|
|
15658
15902
|
] }),
|
|
15659
|
-
/* @__PURE__ */ (0,
|
|
15660
|
-
/* @__PURE__ */ (0,
|
|
15661
|
-
/* @__PURE__ */ (0,
|
|
15903
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "space-y-1", children: [
|
|
15904
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)("label", { htmlFor: "full-invoice-postal-code", className: "text-sm font-medium", children: t.postalCode }),
|
|
15905
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
15662
15906
|
"input",
|
|
15663
15907
|
{
|
|
15664
15908
|
id: "full-invoice-postal-code",
|
|
@@ -15669,9 +15913,9 @@ function FullInvoiceFields({
|
|
|
15669
15913
|
}
|
|
15670
15914
|
)
|
|
15671
15915
|
] }),
|
|
15672
|
-
/* @__PURE__ */ (0,
|
|
15673
|
-
/* @__PURE__ */ (0,
|
|
15674
|
-
/* @__PURE__ */ (0,
|
|
15916
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "space-y-1", children: [
|
|
15917
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)("label", { htmlFor: "full-invoice-city", className: "text-sm font-medium", children: t.city }),
|
|
15918
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
15675
15919
|
"input",
|
|
15676
15920
|
{
|
|
15677
15921
|
id: "full-invoice-city",
|
|
@@ -15682,9 +15926,9 @@ function FullInvoiceFields({
|
|
|
15682
15926
|
}
|
|
15683
15927
|
)
|
|
15684
15928
|
] }),
|
|
15685
|
-
/* @__PURE__ */ (0,
|
|
15686
|
-
/* @__PURE__ */ (0,
|
|
15687
|
-
/* @__PURE__ */ (0,
|
|
15929
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "space-y-1", children: [
|
|
15930
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)("label", { htmlFor: "full-invoice-country", className: "text-sm font-medium", children: t.country }),
|
|
15931
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
15688
15932
|
"select",
|
|
15689
15933
|
{
|
|
15690
15934
|
id: "full-invoice-country",
|
|
@@ -15692,15 +15936,64 @@ function FullInvoiceFields({
|
|
|
15692
15936
|
required: true,
|
|
15693
15937
|
value: value.country,
|
|
15694
15938
|
onChange: (e) => set("country", e.target.value),
|
|
15695
|
-
children: countries.map((c) => /* @__PURE__ */ (0,
|
|
15939
|
+
children: countries.map((c) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("option", { value: c.code, children: c.name }, c.code))
|
|
15696
15940
|
}
|
|
15697
15941
|
)
|
|
15698
15942
|
] }),
|
|
15699
|
-
/* @__PURE__ */ (0,
|
|
15943
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { className: "sm:col-span-2", children: error("address") })
|
|
15700
15944
|
] })
|
|
15701
15945
|
] });
|
|
15702
15946
|
}
|
|
15703
15947
|
|
|
15948
|
+
// src/components/contact-interest-field.tsx
|
|
15949
|
+
var import_utils25 = require("@reblu/site-ui/utils");
|
|
15950
|
+
var import_jsx_runtime27 = require("react/jsx-runtime");
|
|
15951
|
+
function ContactInterestField({
|
|
15952
|
+
interest,
|
|
15953
|
+
value,
|
|
15954
|
+
onChange,
|
|
15955
|
+
idPrefix = "contact-interest",
|
|
15956
|
+
disabled,
|
|
15957
|
+
className
|
|
15958
|
+
}) {
|
|
15959
|
+
if (!interest || interest.options.length === 0) return null;
|
|
15960
|
+
const chosen = new Set(value);
|
|
15961
|
+
const toggle = (option2, checked) => {
|
|
15962
|
+
const next2 = new Set(chosen);
|
|
15963
|
+
if (checked) next2.add(option2);
|
|
15964
|
+
else next2.delete(option2);
|
|
15965
|
+
onChange(interest.options.filter((candidate) => next2.has(candidate)));
|
|
15966
|
+
};
|
|
15967
|
+
return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("fieldset", { "data-slot": "contact-interest", className: (0, import_utils25.cn)("space-y-2", className), children: [
|
|
15968
|
+
/* @__PURE__ */ (0, import_jsx_runtime27.jsx)("legend", { className: "text-sm font-medium", children: interest.label }),
|
|
15969
|
+
/* @__PURE__ */ (0, import_jsx_runtime27.jsx)("div", { className: "flex flex-col gap-2", children: interest.options.map((option2, index) => {
|
|
15970
|
+
const id = `${idPrefix}-${index}`;
|
|
15971
|
+
return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
|
|
15972
|
+
"label",
|
|
15973
|
+
{
|
|
15974
|
+
htmlFor: id,
|
|
15975
|
+
"data-slot": "contact-interest-option",
|
|
15976
|
+
className: "flex items-center gap-2 text-sm",
|
|
15977
|
+
children: [
|
|
15978
|
+
/* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
|
|
15979
|
+
"input",
|
|
15980
|
+
{
|
|
15981
|
+
id,
|
|
15982
|
+
type: "checkbox",
|
|
15983
|
+
checked: chosen.has(option2),
|
|
15984
|
+
disabled,
|
|
15985
|
+
onChange: (event) => toggle(option2, event.target.checked)
|
|
15986
|
+
}
|
|
15987
|
+
),
|
|
15988
|
+
option2
|
|
15989
|
+
]
|
|
15990
|
+
},
|
|
15991
|
+
option2
|
|
15992
|
+
);
|
|
15993
|
+
}) })
|
|
15994
|
+
] });
|
|
15995
|
+
}
|
|
15996
|
+
|
|
15704
15997
|
// src/index.ts
|
|
15705
15998
|
var import_site_contracts = require("@reblu/site-contracts");
|
|
15706
15999
|
// Annotate the CommonJS export names for ESM import in node:
|
|
@@ -15712,9 +16005,14 @@ var import_site_contracts = require("@reblu/site-contracts");
|
|
|
15712
16005
|
CartSummary,
|
|
15713
16006
|
CheckoutForm,
|
|
15714
16007
|
CheckoutLoginPrompt,
|
|
16008
|
+
ContactInterestField,
|
|
16009
|
+
CourseCatalogFilters,
|
|
15715
16010
|
CourseDescription,
|
|
15716
16011
|
DATA_REQUEST_TYPES,
|
|
16012
|
+
DEFAULT_COURSE_CATALOG_FILTERS_LABELS,
|
|
16013
|
+
DEFAULT_COURSE_PRICE_BANDS,
|
|
15717
16014
|
DEFAULT_INVOICE_COUNTRIES,
|
|
16015
|
+
DEFAULT_LESSON_PREVIEW_LABELS,
|
|
15718
16016
|
DEFAULT_SHOP_ERROR_FALLBACK_MESSAGE,
|
|
15719
16017
|
DEFAULT_SHOP_ERROR_MESSAGES,
|
|
15720
16018
|
DEFAULT_SHOP_PRICE_BANDS,
|
|
@@ -15724,6 +16022,7 @@ var import_site_contracts = require("@reblu/site-contracts");
|
|
|
15724
16022
|
EMPTY_FULL_INVOICE_VALUE,
|
|
15725
16023
|
FaqAccordion,
|
|
15726
16024
|
FullInvoiceFields,
|
|
16025
|
+
LessonPreview,
|
|
15727
16026
|
MarkdownRenderer,
|
|
15728
16027
|
OrderConfirmation,
|
|
15729
16028
|
OrderInvoiceLink,
|