@riverbankcms/sdk 0.127.0 → 0.129.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/README.md +33 -0
- package/dist/{PreviewEditorSidebar-BXtfF7tp.mjs → PreviewEditorSidebar-B43CJ0g_.mjs} +9 -33
- package/dist/{PreviewEditorUI-Dou73Q0K.mjs → PreviewEditorUI-DHirVkeM.mjs} +3 -3
- package/dist/{PreviewQueryProvider-DgFDIwvK.mjs → PreviewQueryProvider-B1kbhaJD.mjs} +1 -1
- package/dist/SdkPreviewModeRuntime-BJumZy1B.mjs +11209 -0
- package/dist/{SiteChromeCustomizeContext-DZiDBAYu.mjs → SiteChromeCustomizeContext-D9SlpwEj.mjs} +31757 -1621
- package/dist/_dts/ai/src/contracts/proposals.d.ts +288 -36
- package/dist/_dts/api/src/bookingClosures.d.ts +19 -3
- package/dist/_dts/api/src/bookingManagementEndpoints.d.ts +4 -3
- package/dist/_dts/api/src/bookingRecords.d.ts +0 -13
- package/dist/_dts/api/src/commercePortalEndpoints.d.ts +2 -2
- package/dist/_dts/api/src/communications.d.ts +2 -1
- package/dist/_dts/api/src/contactFormSummary.d.ts +15 -0
- package/dist/_dts/api/src/contentRuntime.d.ts +2 -5
- package/dist/_dts/api/src/endpoints.d.ts +1 -1
- package/dist/_dts/api/src/footerSettings.d.ts +11 -0
- package/dist/_dts/api/src/index.d.ts +2 -1
- package/dist/_dts/api/src/occurrenceScheduling.d.ts +48 -0
- package/dist/_dts/api/src/participantMessaging.d.ts +5 -3
- package/dist/_dts/api/src/publicExperience/siteEndpoints.d.ts +7 -0
- package/dist/_dts/api/src/sdkContracts.d.ts +7 -5
- package/dist/_dts/api/src/siteOperations.d.ts +12 -3
- package/dist/_dts/api/src/sitePlatformEndpoints.d.ts +3 -2
- package/dist/_dts/blocks/src/PageRenderer.d.ts +20 -10
- package/dist/_dts/blocks/src/client/form.d.ts +1 -0
- package/dist/_dts/blocks/src/client/newsletter-form.d.ts +1 -0
- package/dist/_dts/blocks/src/client/site-chrome.d.ts +1 -0
- package/dist/_dts/blocks/src/contracts/proof-block-islands.d.ts +4 -8
- package/dist/_dts/blocks/src/index.d.ts +2 -1
- package/dist/_dts/blocks/src/pageRendererBoundaries.d.ts +30 -0
- package/dist/_dts/blocks/src/pageRenderingMode.d.ts +37 -0
- package/dist/_dts/blocks/src/rendering/server.d.ts +1 -1
- package/dist/_dts/blocks/src/server.d.ts +1 -1
- package/dist/_dts/blocks/src/system/blocks/event-registration.d.ts +41 -0
- package/dist/_dts/blocks/src/system/blocks/newsletter-signup-destination.d.ts +14 -23
- package/dist/_dts/blocks/src/system/blocks/newsletter-signup.d.ts +1 -1
- package/dist/_dts/blocks/src/system/blocks/site-footer-runtime.d.ts +109 -23
- package/dist/_dts/blocks/src/system/data/loaderEndpoints.d.ts +1 -1
- package/dist/_dts/blocks/src/system/runtime/components/registry.client.d.ts +42 -108
- package/dist/_dts/blocks/src/system/runtime/components/runtime-backed-blocks.d.ts +21 -54
- package/dist/_dts/blocks/src/system/runtime/nodes/event-details/logic.d.ts +1 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/registrationSurface.d.ts +26 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/types.d.ts +8 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/event-registration.interactive.d.ts +21 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/newsletter-form.interactive.d.ts +29 -78
- package/dist/_dts/blocks/src/system/runtime/nodes/newsletter-form.server.d.ts +1 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/newsletter-form.submission.d.ts +3 -6
- package/dist/_dts/blocks/src/system/runtime/nodes/newsletter-form.types.d.ts +27 -8
- package/dist/_dts/content-editor/src/FooterComposerOverview.d.ts +21 -0
- package/dist/_dts/content-editor/src/FooterComposerPanel.d.ts +3 -1
- package/dist/_dts/content-editor/src/FooterEngagementEditorFields.d.ts +31 -0
- package/dist/_dts/content-editor/src/FooterEngagementEditorPanel.d.ts +17 -0
- package/dist/_dts/content-editor/src/footerComposer.d.ts +3 -0
- package/dist/_dts/content-editor/src/footerEngagementDraft.d.ts +57 -0
- package/dist/_dts/content-editor/src/footerEngagementEditor.d.ts +11 -0
- package/dist/_dts/content-editor/src/footerPreviewRuntime.d.ts +13 -0
- package/dist/_dts/content-editor/src/index.d.ts +1 -0
- package/dist/_dts/content-editor/src/useFooterComposerState.d.ts +35 -0
- package/dist/_dts/core/src/footer-arrangement.d.ts +2 -0
- package/dist/_dts/core/src/footer-composition-types.d.ts +118 -0
- package/dist/_dts/core/src/footer-composition.d.ts +7 -116
- package/dist/_dts/core/src/footer-engagement.d.ts +30 -0
- package/dist/_dts/core/src/index.d.ts +4 -0
- package/dist/_dts/core/src/newsletter-signup-destination.d.ts +38 -0
- package/dist/_dts/db/src/generated/supabase/database.types.d.ts +73 -6
- package/dist/_dts/db/src/index.d.ts +1 -0
- package/dist/_dts/db/src/schemas/forms.d.ts +72 -2
- package/dist/_dts/db/src/schemas/standard-contact.d.ts +114 -0
- package/dist/_dts/preview-next/src/client/blocks/pageDesignRuntimePreview.d.ts +2 -0
- package/dist/_dts/preview-next/src/client/blocks/previewBatchLoaderParams.d.ts +6 -0
- package/dist/_dts/preview-next/src/client/index.d.ts +47 -47
- package/dist/_dts/preview-next/src/client/preview/EntryEditorPanel.d.ts +2 -5
- package/dist/_dts/preview-next/src/client/preview/EntrySlotBlockEditorPanel.d.ts +2 -5
- package/dist/_dts/preview-next/src/client/preview/PageBlockEditorPanel.d.ts +2 -5
- package/dist/_dts/preview-next/src/client/preview/PreviewEditorSidebar.d.ts +2 -4
- package/dist/_dts/preview-next/src/client/preview/PreviewShell.d.ts +19 -7
- package/dist/_dts/preview-next/src/client/preview/PreviewShellLayout.d.ts +30 -23
- package/dist/_dts/preview-next/src/client/preview/PreviewThemedSiteDocument.d.ts +18 -5
- package/dist/_dts/preview-next/src/client/preview/themeRuntime.d.ts +9 -0
- package/dist/_dts/preview-next/src/client/sdk/SdkPreviewMode.d.ts +21 -6
- package/dist/_dts/preview-next/src/client/sdk-runtime.d.ts +8 -8
- package/dist/_dts/preview-next/src/client/widgets/widgetOverrides.d.ts +6 -5
- package/dist/_dts/sdk/src/cli/commands/push/execute/footer.d.ts +9 -0
- package/dist/_dts/sdk/src/cli/content/footerFile.d.ts +10 -0
- package/dist/_dts/sdk/src/cli/content/reader.d.ts +3 -5
- package/dist/_dts/sdk/src/cli/site-commands/footerCommands.d.ts +15 -3
- package/dist/_dts/sdk/src/client/combineAbortSignals.d.ts +2 -0
- package/dist/_dts/sdk/src/client/management/types.d.ts +6 -15
- package/dist/_dts/sdk/src/client/types.d.ts +10 -2
- package/dist/_dts/sdk/src/client/wholeSeriesReadOperations.d.ts +11 -0
- package/dist/_dts/sdk/src/config/types.d.ts +1 -1
- package/dist/_dts/sdk/src/config/validation.d.ts +3 -0
- package/dist/_dts/sdk/src/contracts/event-registration-content.d.ts +16 -0
- package/dist/_dts/sdk/src/contracts/system-block-content.d.ts +4 -15
- package/dist/_dts/sdk/src/next/catch-all.d.ts +6 -0
- package/dist/_dts/sdk/src/next/index.d.ts +2 -1
- package/dist/_dts/sdk/src/next/renderSdkContent.d.ts +33 -0
- package/dist/_dts/sdk/src/next/types.d.ts +23 -9
- package/dist/_dts/sdk/src/preview-next/before-render.d.ts +4 -6
- package/dist/_dts/sdk/src/preview-next/client/index.d.ts +3 -3
- package/dist/_dts/sdk/src/preview-next/client/runtime.d.ts +1 -1
- package/dist/_dts/sdk/src/public-api/contracts.d.ts +4 -18
- package/dist/_dts/sdk/src/public-api/teamMemberContracts.d.ts +17 -0
- package/dist/_dts/sdk/src/public-api/wholeSeriesContracts.d.ts +2 -0
- package/dist/_dts/sdk/src/rendering/blocks-page-renderer.d.ts +32 -3
- package/dist/_dts/sdk/src/rendering/components/Block.shared.d.ts +13 -2
- package/dist/_dts/sdk/src/rendering/components/Layout.d.ts +31 -18
- package/dist/_dts/sdk/src/rendering/components/pageShared.d.ts +20 -9
- package/dist/_dts/sdk/src/rendering/index.d.ts +8 -4
- package/dist/_dts/sdk/src/rendering/mediaAssets.d.ts +8 -2
- package/dist/_dts/sdk/src/rendering/renderingMode.d.ts +23 -0
- package/dist/_dts/sdk/src/rendering/server.d.ts +5 -3
- package/dist/_dts/sdk/src/rendering/themeRuntime.d.ts +6 -0
- package/dist/_dts/sdk/src/version.d.ts +1 -1
- package/dist/_dts/site-commands/src/commandContract.d.ts +8 -1
- package/dist/_dts/site-commands/src/commands.d.ts +16 -2
- package/dist/_dts/theme-core/src/header/paintTargets.d.ts +10 -4
- package/dist/_dts/theme-core/src/header/surfaceRules.d.ts +2 -3
- package/dist/cli/index.mjs +5535 -4835
- package/dist/cli/init-docs/content/workflow-preview-mode.md +24 -11
- package/dist/client/{courseRegistration-DTEYWL6Z.mjs → CourseRegistrationWizard-xRmA7REV.mjs} +329 -49
- package/dist/client/{DiscountCodeDisclosure-BDFRp8Y7.mjs → DiscountCodeDisclosure-B9vriL5C.mjs} +1 -1
- package/dist/client/{EventCombined.client-DJgF1_lf.mjs → EventCombined.client-BgVnVTlz.mjs} +2 -2
- package/dist/client/{EventListing.client-CnWGNjOr.mjs → EventListing.client-CqdsO7jO.mjs} +2 -2
- package/dist/client/{LeafletStaticMap-BISs9Bl7.mjs → LeafletStaticMap-CKPxot9M.mjs} +1 -1
- package/dist/client/{StepIndicator-D8gVYkK-.mjs → StepIndicator-DGCYuBJ1.mjs} +2 -2
- package/dist/client/{accordion-DFDajgDz.mjs → accordion-BfN5Eqd-.mjs} +1 -1
- package/dist/client/{bookingForm-Bdqj9-52.mjs → bookingForm-DOvCpBFP.mjs} +5 -5
- package/dist/client/{carousel-Cvqf-kN8.mjs → carousel-DPNmiH0f.mjs} +1 -1
- package/dist/client/{cart-CuH2TJXP.mjs → cart--egVXlrR.mjs} +3 -3
- package/dist/client/{checkout-CMNPpejZ.mjs → checkout-DywWtMcq.mjs} +3 -3
- package/dist/client/client.mjs +5324 -4942
- package/dist/client/courseRegistration-Dk9qFVwt.mjs +46 -0
- package/dist/client/{eventCalendar-BW-XoxZ0.mjs → eventCalendar-Bkz2HjlS.mjs} +4 -4
- package/dist/client/{eventCombined-Bpn7s0y9.mjs → eventCombined-D4kipYWg.mjs} +2 -2
- package/dist/client/{eventDetails-D2uUSTMH.mjs → eventDetails-Dz_5ix2Q.mjs} +56 -35
- package/dist/client/{eventListing-CVr1c094.mjs → eventListing-D0vm-zST.mjs} +2 -2
- package/dist/client/{eventRegistration-Dv4AvkMw.mjs → eventRegistration-Cw1E4Q4p.mjs} +58 -6
- package/dist/client/{form-DxdKf9fs.mjs → form-C2Zf1n3K.mjs} +1 -1
- package/dist/client/{headerSection-BaXI5Sro.mjs → headerSection-CP05gzdc.mjs} +2 -2
- package/dist/client/hooks.mjs +212 -61
- package/dist/client/{locationMap-BEtW2fKz.mjs → locationMap-Cl3x9PYJ.mjs} +2 -2
- package/dist/client/{newsletterForm-BKKs0S4R.mjs → newsletterForm-DyEJoClm.mjs} +26 -20
- package/dist/client/{pricing-ClkqcElA.mjs → pricing-DGuNR1W4.mjs} +1 -1
- package/dist/client/{productDetail-H-ru8dyy.mjs → productDetail-Cq-HrGew.mjs} +3 -3
- package/dist/client/{productList-Buyi5c0C.mjs → productList-DbB3jwqd.mjs} +3 -3
- package/dist/client/{propsDecoder-BF7i6Ijg.mjs → propsDecoder-CiTuhUwY.mjs} +130 -87
- package/dist/client/rendering/client.mjs +416 -208
- package/dist/client/rendering/islands.mjs +18 -18
- package/dist/client/rendering.mjs +6026 -5596
- package/dist/client/{scrollToBlock-D_7t8yWb.mjs → scrollToBlock-CShkRqab.mjs} +1 -1
- package/dist/client/{shop-CF7SZQNX.mjs → shop-Cu4Ib-ZA.mjs} +5 -5
- package/dist/client/{shop-commerce-DA7_Rq5p.mjs → shop-commerce-BzpsOdh7.mjs} +4 -4
- package/dist/client/{shop-commerce-store-BmLqW7Gh.mjs → shop-commerce-store-DaE7Fhj8.mjs} +1 -1
- package/dist/client/{shopShared-WL-E1znM.mjs → shopShared-cF0c20vB.mjs} +2 -2
- package/dist/client/{useEventFilters-rc8VLeLV.mjs → useEventFilters-QZ3HMgaJ.mjs} +2 -2
- package/dist/client/{usePolling-1ncrfd4S.mjs → usePolling-BKf0GcE-.mjs} +2 -2
- package/dist/preview-next/before-render.mjs +11 -4
- package/dist/preview-next/client/runtime.mjs +4 -4
- package/dist/preview-next/middleware.mjs +1 -1
- package/dist/{previewAuthStore-Dev9CdG9.mjs → previewAuthStore-BesgU5Xu.mjs} +1 -1
- package/dist/{sdk-runtime-BnrCCFJq.mjs → sdk-runtime-CfZd5pAm.mjs} +2 -2
- package/dist/{separator-CFvBx2yl.mjs → separator-DkTe68HE.mjs} +1 -1
- package/dist/server/components.mjs +950 -639
- package/dist/server/config-validation.mjs +209 -61
- package/dist/server/config.mjs +209 -61
- package/dist/server/data.mjs +212 -61
- package/dist/server/index.mjs +40 -16
- package/dist/server/next.mjs +1181 -835
- package/dist/server/page-converter.mjs +211 -64
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/rendering/server.mjs +974 -637
- package/dist/server/rendering.mjs +980 -644
- package/dist/server/routing.mjs +254 -80
- package/dist/server/server.mjs +252 -77
- package/package.json +1 -1
- package/dist/SdkPreviewModeRuntime-B0HPXr-l.mjs +0 -39546
- package/dist/client/MagicLinkForm-b5E_HoG9.mjs +0 -327
|
@@ -509,7 +509,7 @@ function encodePublicProductCategorySelector(selector) {
|
|
|
509
509
|
};
|
|
510
510
|
}
|
|
511
511
|
}
|
|
512
|
-
function isRecord$
|
|
512
|
+
function isRecord$27(value) {
|
|
513
513
|
return typeof value === "object" && value !== null;
|
|
514
514
|
}
|
|
515
515
|
function isJsonResponseContentType(contentType) {
|
|
@@ -533,8 +533,8 @@ async function parseJsonBody(response) {
|
|
|
533
533
|
}
|
|
534
534
|
}
|
|
535
535
|
function getBlockApiErrorDetails(data) {
|
|
536
|
-
if (!isRecord$
|
|
537
|
-
const nestedError = isRecord$
|
|
536
|
+
if (!isRecord$27(data)) return {};
|
|
537
|
+
const nestedError = isRecord$27(data.error) ? data.error : void 0;
|
|
538
538
|
return {
|
|
539
539
|
message: typeof nestedError?.message === "string" ? nestedError.message : typeof data.message === "string" ? data.message : void 0,
|
|
540
540
|
code: typeof nestedError?.code === "string" ? nestedError.code : typeof data.code === "string" ? data.code : void 0
|
|
@@ -3411,8 +3411,7 @@ var init_breakpoints = __esmMin((() => {
|
|
|
3411
3411
|
}));
|
|
3412
3412
|
var init_paintTargets = __esmMin((() => {
|
|
3413
3413
|
init_breakpoints();
|
|
3414
|
-
}));
|
|
3415
|
-
var headerScrollTreatmentSchema;
|
|
3414
|
+
})), headerScrollTreatmentSchema;
|
|
3416
3415
|
var init_scrollTreatment = __esmMin((() => {
|
|
3417
3416
|
init_paintTargets();
|
|
3418
3417
|
headerScrollTreatmentSchema = z$1.discriminatedUnion("kind", [z$1.object({
|
|
@@ -6281,11 +6280,11 @@ var UnsafePathSegmentError = class extends Error {
|
|
|
6281
6280
|
function assertSafePathSegments(segments) {
|
|
6282
6281
|
for (const segment of segments) if (typeof segment === "string" && UNSAFE_PATH_SEGMENTS.has(segment)) throw new UnsafePathSegmentError(segment);
|
|
6283
6282
|
}
|
|
6284
|
-
function isRecord$
|
|
6283
|
+
function isRecord$26(value) {
|
|
6285
6284
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
6286
6285
|
}
|
|
6287
6286
|
function isPathContainer(value) {
|
|
6288
|
-
return Array.isArray(value) || isRecord$
|
|
6287
|
+
return Array.isArray(value) || isRecord$26(value);
|
|
6289
6288
|
}
|
|
6290
6289
|
function getContainerValue(container, segment) {
|
|
6291
6290
|
if (typeof segment === "number") return Array.isArray(container) ? container[segment] : void 0;
|
|
@@ -6591,7 +6590,7 @@ var init_event_pricing = __esmMin((() => {
|
|
|
6591
6590
|
//#endregion
|
|
6592
6591
|
//#region ../core/src/event-page-surface-subject.ts
|
|
6593
6592
|
function parseEventPageSurfaceSubject(value) {
|
|
6594
|
-
if (!isRecord$
|
|
6593
|
+
if (!isRecord$25(value)) return err$2({ kind: "notObject" });
|
|
6595
6594
|
switch (value.kind) {
|
|
6596
6595
|
case "eventSeries": {
|
|
6597
6596
|
const eventSeriesId = parseEventSeriesId(value.eventSeriesId);
|
|
@@ -6634,7 +6633,7 @@ function parseEventPageSurfaceSubject(value) {
|
|
|
6634
6633
|
});
|
|
6635
6634
|
}
|
|
6636
6635
|
}
|
|
6637
|
-
function isRecord$
|
|
6636
|
+
function isRecord$25(value) {
|
|
6638
6637
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
6639
6638
|
}
|
|
6640
6639
|
var init_event_page_surface_subject = __esmMin((() => {
|
|
@@ -7051,7 +7050,7 @@ var init_public_profile = __esmMin((() => {
|
|
|
7051
7050
|
}));
|
|
7052
7051
|
//#endregion
|
|
7053
7052
|
//#region ../core/src/rich-text.ts
|
|
7054
|
-
function isRecord$
|
|
7053
|
+
function isRecord$23(value) {
|
|
7055
7054
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
7056
7055
|
}
|
|
7057
7056
|
function hasOnlyKeys(value, allowed) {
|
|
@@ -7062,10 +7061,10 @@ function isDenseArrayOf(value, predicate) {
|
|
|
7062
7061
|
return true;
|
|
7063
7062
|
}
|
|
7064
7063
|
function isTipTapMark(value) {
|
|
7065
|
-
return isRecord$
|
|
7064
|
+
return isRecord$23(value) && hasOnlyKeys(value, markKeys) && typeof value.type === "string" && value.type.length > 0 && (value.attrs === void 0 || isRecord$23(value.attrs));
|
|
7066
7065
|
}
|
|
7067
7066
|
function isTipTapNode(value) {
|
|
7068
|
-
if (!isRecord$
|
|
7067
|
+
if (!isRecord$23(value) || !hasOnlyKeys(value, nodeKeys) || typeof value.type !== "string" || value.type.length === 0 || value.type === "doc" || value.attrs !== void 0 && !isRecord$23(value.attrs) || value.marks !== void 0 && (!Array.isArray(value.marks) || !isDenseArrayOf(value.marks, isTipTapMark)) || value.content !== void 0 && (!Array.isArray(value.content) || !isDenseArrayOf(value.content, isTipTapNode))) return false;
|
|
7069
7068
|
if (value.type === "text") return typeof value.text === "string" && value.text.length > 0 && value.content === void 0;
|
|
7070
7069
|
return value.text === void 0;
|
|
7071
7070
|
}
|
|
@@ -7080,10 +7079,18 @@ var init_rich_text = __esmMin((() => {
|
|
|
7080
7079
|
]);
|
|
7081
7080
|
markKeys = /* @__PURE__ */ new Set(["type", "attrs"]);
|
|
7082
7081
|
}));
|
|
7083
|
-
|
|
7084
|
-
|
|
7085
|
-
|
|
7082
|
+
function parseNewsletterSignupDestinationProvider(value) {
|
|
7083
|
+
return value === "riverbank" || value === "mailchimp" ? value : null;
|
|
7084
|
+
}
|
|
7085
|
+
var init_newsletter_signup_destination$1 = __esmMin((() => {
|
|
7086
|
+
init_result();
|
|
7087
|
+
}));
|
|
7088
|
+
var init_footer_engagement = __esmMin((() => {
|
|
7089
|
+
init_branded();
|
|
7090
|
+
init_newsletter_signup_destination$1();
|
|
7086
7091
|
init_result();
|
|
7092
|
+
})), sectionKinds;
|
|
7093
|
+
var init_footer_arrangement = __esmMin((() => {
|
|
7087
7094
|
sectionKinds = [
|
|
7088
7095
|
"brand",
|
|
7089
7096
|
"supporting-text",
|
|
@@ -7092,11 +7099,21 @@ var init_footer_composition = __esmMin((() => {
|
|
|
7092
7099
|
"business-address",
|
|
7093
7100
|
"contact",
|
|
7094
7101
|
"opening-hours",
|
|
7102
|
+
"engagement",
|
|
7095
7103
|
"legal-navigation",
|
|
7096
7104
|
"legal"
|
|
7097
7105
|
];
|
|
7098
7106
|
new Map(sectionKinds.map((kind, index) => [kind, index]));
|
|
7099
7107
|
}));
|
|
7108
|
+
var init_footer_composition = __esmMin((() => {
|
|
7109
|
+
init_footer_engagement();
|
|
7110
|
+
init_rich_text();
|
|
7111
|
+
init_result();
|
|
7112
|
+
init_footer_arrangement();
|
|
7113
|
+
}));
|
|
7114
|
+
//#endregion
|
|
7115
|
+
//#region ../core/src/footer-composition-types.ts
|
|
7116
|
+
var init_footer_composition_types = __esmMin((() => {}));
|
|
7100
7117
|
var init_number_input = __esmMin((() => {}));
|
|
7101
7118
|
var init_field_errors = __esmMin((() => {})), init_form_submission_preview = __esmMin((() => {
|
|
7102
7119
|
init_string();
|
|
@@ -7197,6 +7214,10 @@ var init_src$3 = __esmMin((() => {
|
|
|
7197
7214
|
init_public_profile();
|
|
7198
7215
|
init_rich_text();
|
|
7199
7216
|
init_footer_composition();
|
|
7217
|
+
init_footer_arrangement();
|
|
7218
|
+
init_footer_composition_types();
|
|
7219
|
+
init_footer_engagement();
|
|
7220
|
+
init_newsletter_signup_destination$1();
|
|
7200
7221
|
init_number_input();
|
|
7201
7222
|
init_field_errors();
|
|
7202
7223
|
init_form_submission_preview();
|
|
@@ -7219,7 +7240,7 @@ var init_types$8 = __esmMin((() => {}));
|
|
|
7219
7240
|
//#endregion
|
|
7220
7241
|
//#region ../media-core/src/fileSafety.ts
|
|
7221
7242
|
function containsUnsafePathSegmentCharacter(value) {
|
|
7222
|
-
return value.includes("/") || value.includes("\\") || CONTROL_CHARACTER_PATTERN
|
|
7243
|
+
return value.includes("/") || value.includes("\\") || CONTROL_CHARACTER_PATTERN.test(value);
|
|
7223
7244
|
}
|
|
7224
7245
|
function isReservedPathSegment(value) {
|
|
7225
7246
|
return value === "." || value === "..";
|
|
@@ -7227,8 +7248,8 @@ function isReservedPathSegment(value) {
|
|
|
7227
7248
|
function isUnsafePathSegment(segment) {
|
|
7228
7249
|
return segment.trim().length === 0 || segment !== segment.trim() || isReservedPathSegment(segment) || containsUnsafePathSegmentCharacter(segment);
|
|
7229
7250
|
}
|
|
7230
|
-
var CONTROL_CHARACTER_PATTERN
|
|
7231
|
-
CONTROL_CHARACTER_PATTERN
|
|
7251
|
+
var CONTROL_CHARACTER_PATTERN, init_fileSafety = __esmMin((() => {
|
|
7252
|
+
CONTROL_CHARACTER_PATTERN = /[\u0000-\u001f\u007f]/u;
|
|
7232
7253
|
})), AMBIENT_BACKGROUND_ROLES;
|
|
7233
7254
|
var init_fileDomain = __esmMin((() => {
|
|
7234
7255
|
init_src$3();
|
|
@@ -13258,6 +13279,33 @@ function uniqByOccurrenceId(events) {
|
|
|
13258
13279
|
}
|
|
13259
13280
|
return out;
|
|
13260
13281
|
}
|
|
13282
|
+
function selectFromOccurrenceContext(events, occurrenceContext) {
|
|
13283
|
+
if (!occurrenceContext) return null;
|
|
13284
|
+
const byId = events.find((event) => event.occurrenceId === occurrenceContext.id || event.id === occurrenceContext.id);
|
|
13285
|
+
if (byId) return byId;
|
|
13286
|
+
const contextDate = getBookingLocalDateKey(toScheduledBookingDateTime({
|
|
13287
|
+
startsAt: occurrenceContext.startsAt,
|
|
13288
|
+
timeZone: occurrenceContext.timeZone
|
|
13289
|
+
}));
|
|
13290
|
+
return events.find((event) => getBookingLocalDateKey(toScheduledBookingDateTime({
|
|
13291
|
+
startsAt: event.startsAt,
|
|
13292
|
+
timeZone: event.timeZone
|
|
13293
|
+
})) === contextDate) ?? null;
|
|
13294
|
+
}
|
|
13295
|
+
function selectNextUpcoming(events, nowIso) {
|
|
13296
|
+
return [...events].filter((event) => isFutureOrNow(event.startsAt, nowIso)).sort((left, right) => Date.parse(left.startsAt) - Date.parse(right.startsAt))[0] ?? null;
|
|
13297
|
+
}
|
|
13298
|
+
function selectCompletedWholeSeries(events) {
|
|
13299
|
+
if (events.length === 0 || !events.every((event) => event.bookingScope === "whole_series")) return null;
|
|
13300
|
+
return [...events].sort((left, right) => Date.parse(right.startsAt) - Date.parse(left.startsAt))[0] ?? null;
|
|
13301
|
+
}
|
|
13302
|
+
function selectRelatedDates(input) {
|
|
13303
|
+
if (!input.seriesId) return [];
|
|
13304
|
+
const isWholeSeries = input.selected?.bookingScope === "whole_series";
|
|
13305
|
+
const selectedOccurrenceId = input.selected ? input.selected.occurrenceId || input.selected.id : null;
|
|
13306
|
+
const dates = input.events.filter((event) => event.seriesId === input.seriesId).filter((event) => isWholeSeries || isFutureOrNow(event.startsAt, input.nowIso)).filter((event) => !selectedOccurrenceId || (event.occurrenceId || event.id) !== selectedOccurrenceId).sort((left, right) => Date.parse(left.startsAt) - Date.parse(right.startsAt));
|
|
13307
|
+
return isWholeSeries ? dates : dates.slice(0, input.limit);
|
|
13308
|
+
}
|
|
13261
13309
|
function selectEventDetails(args) {
|
|
13262
13310
|
const all = uniqByOccurrenceId(resolveEventRegistrationScopedEvents((args.events ?? []).filter(Boolean), {
|
|
13263
13311
|
occurrenceContext: args.occurrenceContext,
|
|
@@ -13265,37 +13313,22 @@ function selectEventDetails(args) {
|
|
|
13265
13313
|
}));
|
|
13266
13314
|
const occurrenceContext = args.occurrenceContext ?? null;
|
|
13267
13315
|
const otherLimit = parseLimit$1(args.otherDatesLimit, 5);
|
|
13268
|
-
const selectedFromContext = (
|
|
13269
|
-
|
|
13270
|
-
|
|
13271
|
-
|
|
13272
|
-
|
|
13273
|
-
startsAt: occurrenceContext.startsAt,
|
|
13274
|
-
timeZone: occurrenceContext.timeZone
|
|
13275
|
-
}));
|
|
13276
|
-
return all.find((e) => getBookingLocalDateKey(toScheduledBookingDateTime({
|
|
13277
|
-
startsAt: e.startsAt,
|
|
13278
|
-
timeZone: e.timeZone
|
|
13279
|
-
})) === ctxDate) ?? null;
|
|
13280
|
-
})();
|
|
13281
|
-
const nextUpcoming = (() => {
|
|
13282
|
-
const upcoming = all.filter((e) => isFutureOrNow(e.startsAt, args.nowIso));
|
|
13283
|
-
upcoming.sort((a, b) => Date.parse(a.startsAt) - Date.parse(b.startsAt));
|
|
13284
|
-
return upcoming[0] ?? null;
|
|
13285
|
-
})();
|
|
13286
|
-
const mode = selectedFromContext ? "selected" : "next";
|
|
13287
|
-
const selected = selectedFromContext ?? nextUpcoming;
|
|
13316
|
+
const selectedFromContext = selectFromOccurrenceContext(all, occurrenceContext);
|
|
13317
|
+
const nextUpcoming = selectNextUpcoming(all, args.nowIso);
|
|
13318
|
+
const completedWholeSeries = selectCompletedWholeSeries(all);
|
|
13319
|
+
const selected = selectedFromContext ?? nextUpcoming ?? completedWholeSeries;
|
|
13320
|
+
const mode = selectedFromContext ? "selected" : nextUpcoming ? "next" : completedWholeSeries ? "completed" : "next";
|
|
13288
13321
|
const timeZone = toBookingTimeZone(selected?.timeZone ?? all[0]?.timeZone ?? null);
|
|
13289
|
-
const seriesId = occurrenceContext?.seriesId ?? selected?.seriesId ?? all[0]?.seriesId ?? null;
|
|
13290
|
-
const selectedOccurrenceId = selected?.occurrenceId ?? null;
|
|
13291
13322
|
return {
|
|
13292
13323
|
mode,
|
|
13293
13324
|
selected,
|
|
13294
|
-
otherDates:
|
|
13295
|
-
|
|
13296
|
-
|
|
13297
|
-
|
|
13298
|
-
|
|
13325
|
+
otherDates: selectRelatedDates({
|
|
13326
|
+
events: all,
|
|
13327
|
+
seriesId: occurrenceContext?.seriesId ?? selected?.seriesId ?? all[0]?.seriesId ?? null,
|
|
13328
|
+
selected,
|
|
13329
|
+
nowIso: args.nowIso,
|
|
13330
|
+
limit: otherLimit
|
|
13331
|
+
}),
|
|
13299
13332
|
timeZone
|
|
13300
13333
|
};
|
|
13301
13334
|
}
|
|
@@ -14718,7 +14751,7 @@ function EventFacts({ selection, selected, venue, teamMembers, pricing }) {
|
|
|
14718
14751
|
/* @__PURE__ */ jsxs("div", { children: [
|
|
14719
14752
|
/* @__PURE__ */ jsx("div", {
|
|
14720
14753
|
className: "rb-label rb-mb-2",
|
|
14721
|
-
children: selection.mode === "next" ? "Next date" : "Date"
|
|
14754
|
+
children: selected.bookingScope === "whole_series" ? selection.mode === "next" ? "Next session" : "Selected session" : selection.mode === "next" ? "Next date" : "Date"
|
|
14722
14755
|
}),
|
|
14723
14756
|
/* @__PURE__ */ jsx("p", { children: /* @__PURE__ */ jsx("strong", { children: date }) }),
|
|
14724
14757
|
/* @__PURE__ */ jsx("p", {
|
|
@@ -14756,18 +14789,27 @@ function EventFacts({ selection, selected, venue, teamMembers, pricing }) {
|
|
|
14756
14789
|
}) : null] }, member.id))
|
|
14757
14790
|
})]
|
|
14758
14791
|
}) : null,
|
|
14759
|
-
pricing
|
|
14792
|
+
pricing,
|
|
14793
|
+
selected.bookingScope === "whole_series" ? /* @__PURE__ */ jsxs("div", {
|
|
14794
|
+
className: "rb-mt-6",
|
|
14795
|
+
children: [/* @__PURE__ */ jsx("div", {
|
|
14796
|
+
className: "rb-label rb-mb-2",
|
|
14797
|
+
children: "Registration"
|
|
14798
|
+
}), /* @__PURE__ */ jsx("p", { children: /* @__PURE__ */ jsx("strong", { children: selected.wholeSeries?.enrollmentOpen ? "Open" : "Closed" }) })]
|
|
14799
|
+
}) : null
|
|
14760
14800
|
]
|
|
14761
14801
|
});
|
|
14762
14802
|
}
|
|
14763
14803
|
function OtherEventDates({ selection }) {
|
|
14764
|
-
|
|
14804
|
+
const isWholeSeries = selection.selected?.bookingScope === "whole_series";
|
|
14805
|
+
const dates = isWholeSeries && selection.selected ? [selection.selected, ...selection.otherDates].sort((left, right) => Date.parse(left.startsAt) - Date.parse(right.startsAt)) : selection.otherDates;
|
|
14806
|
+
if (dates.length === 0) return null;
|
|
14765
14807
|
return /* @__PURE__ */ jsxs("div", { children: [/* @__PURE__ */ jsx("div", {
|
|
14766
14808
|
className: "rb-label",
|
|
14767
|
-
children: "Other dates"
|
|
14809
|
+
children: isWholeSeries ? "Session schedule" : "Other dates"
|
|
14768
14810
|
}), /* @__PURE__ */ jsx("div", {
|
|
14769
14811
|
className: "rb-mt-2 rb-tiles-grid",
|
|
14770
|
-
children:
|
|
14812
|
+
children: dates.map((event) => /* @__PURE__ */ jsx("a", {
|
|
14771
14813
|
className: "rb-tile rb-tile--interactive",
|
|
14772
14814
|
...resolveEventLinkProps(event),
|
|
14773
14815
|
children: /* @__PURE__ */ jsx(DateTimeTile, {
|
|
@@ -31074,6 +31116,7 @@ var init_newsletterForm$1 = __esmMin((() => {
|
|
|
31074
31116
|
}
|
|
31075
31117
|
],
|
|
31076
31118
|
layout: [el("newsletter-form", withApiBindings({
|
|
31119
|
+
source: "block",
|
|
31077
31120
|
destinationProvider: { $bind: { from: "destinationProvider" } },
|
|
31078
31121
|
listId: { $bind: { from: "listId" } },
|
|
31079
31122
|
preset: { $bind: { from: "preset" } },
|
|
@@ -33051,9 +33094,9 @@ const giftingBlockDefinition = {
|
|
|
33051
33094
|
};
|
|
33052
33095
|
//#endregion
|
|
33053
33096
|
//#region ../blocks/src/system/blocks/event-registration.shared.ts
|
|
33054
|
-
var occurrenceContextSchema
|
|
33097
|
+
var occurrenceContextSchema;
|
|
33055
33098
|
var init_event_registration_shared = __esmMin((() => {
|
|
33056
|
-
occurrenceContextSchema
|
|
33099
|
+
occurrenceContextSchema = z$1.object({
|
|
33057
33100
|
id: z$1.string(),
|
|
33058
33101
|
seriesId: z$1.string(),
|
|
33059
33102
|
startsAt: z$1.string(),
|
|
@@ -33255,9 +33298,10 @@ function buildEventRegistrationInteractiveIslandProps(props) {
|
|
|
33255
33298
|
source: props
|
|
33256
33299
|
});
|
|
33257
33300
|
}
|
|
33258
|
-
var EVENT_REGISTRATION_GENERIC_SHELL_STEP_LABELS, EVENT_REGISTRATION_SHELL_STEP_LABELS, eventRegistrationPublicEventSchema, eventRegistrationSourceSchema, eventRegistrationDisplaySchema, eventRegistrationHydrationSchema, eventRegistrationRenderSchema, eventRegistrationIslandMetaCodec, eventRegistrationIslandMetaKeys, eventRegistrationBlockRuntime, eventRegistrationInteractiveIslandPropsCodec;
|
|
33301
|
+
var EVENT_REGISTRATION_GENERIC_SHELL_STEP_LABELS, EVENT_REGISTRATION_SHELL_STEP_LABELS, eventRegistrationPublicEventSchema, eventRegistrationHydrationSchemaShape, eventRegistrationSourceSchema, eventRegistrationDisplaySchema, eventRegistrationHydrationSchema, eventRegistrationRenderSchema, eventRegistrationIslandMetaCodec, eventRegistrationIslandMetaKeys, eventRegistrationBlockRuntime, eventRegistrationInteractiveIslandPropsCodec;
|
|
33259
33302
|
var init_event_registration_interactive = __esmMin((() => {
|
|
33260
33303
|
init_schemas();
|
|
33304
|
+
init_schemas$1();
|
|
33261
33305
|
init_shop_shared();
|
|
33262
33306
|
init_event_registration_shared();
|
|
33263
33307
|
init_eventScope();
|
|
@@ -33282,28 +33326,37 @@ var init_event_registration_interactive = __esmMin((() => {
|
|
|
33282
33326
|
"Payment"
|
|
33283
33327
|
];
|
|
33284
33328
|
eventRegistrationPublicEventSchema = z$1.preprocess(normalizeEventRegistrationEventInput, publicEventSchema);
|
|
33285
|
-
|
|
33286
|
-
|
|
33287
|
-
apiBaseUrl: z$1.string().optional(),
|
|
33288
|
-
portalToken: z$1.string().nullable().optional(),
|
|
33289
|
-
previewToken: z$1.string().nullable().optional(),
|
|
33290
|
-
occurrenceContext: occurrenceContextSchema$1.optional(),
|
|
33329
|
+
eventRegistrationHydrationSchemaShape = {
|
|
33330
|
+
occurrenceContext: occurrenceContextSchema.optional(),
|
|
33291
33331
|
subject: eventRegistrationPageSurfaceSubjectSchema.nullable().optional(),
|
|
33292
33332
|
events: z$1.array(eventRegistrationPublicEventSchema).nullable().optional(),
|
|
33293
|
-
|
|
33294
|
-
|
|
33295
|
-
maxTickets: z$1.string().
|
|
33333
|
+
wholeSeriesOfferings: publicCoursesArraySchema.nullable().optional(),
|
|
33334
|
+
wholeSeriesOffering: publicCourseSchema.nullable().optional(),
|
|
33335
|
+
maxTickets: z$1.string().optional(),
|
|
33296
33336
|
showVenue: z$1.boolean().optional(),
|
|
33297
33337
|
showCapacity: z$1.boolean().optional(),
|
|
33338
|
+
showSessions: z$1.boolean().optional(),
|
|
33339
|
+
showPrice: z$1.boolean().optional(),
|
|
33298
33340
|
successMessage: z$1.string().optional(),
|
|
33299
33341
|
waitlistMessage: z$1.string().optional(),
|
|
33342
|
+
membershipMessage: z$1.string().optional(),
|
|
33300
33343
|
buttonVariant: registrationButtonVariantSchema.optional(),
|
|
33301
33344
|
overlayEnabled: z$1.boolean().optional(),
|
|
33302
33345
|
spamProtectionEnabled: z$1.boolean().optional(),
|
|
33303
|
-
stage: previewStageSchema.optional(),
|
|
33304
33346
|
supportEmail: z$1.string().optional(),
|
|
33305
33347
|
sitePasses: publicPassProductCollectionSchema.nullable().optional(),
|
|
33306
33348
|
siteMemberships: publicMembershipProductCollectionSchema.nullable().optional()
|
|
33349
|
+
};
|
|
33350
|
+
eventRegistrationSourceSchema = z$1.object({
|
|
33351
|
+
siteId: z$1.string().optional(),
|
|
33352
|
+
apiBaseUrl: z$1.string().optional(),
|
|
33353
|
+
portalToken: z$1.string().nullable().optional(),
|
|
33354
|
+
previewToken: z$1.string().nullable().optional(),
|
|
33355
|
+
...eventRegistrationHydrationSchemaShape,
|
|
33356
|
+
className: z$1.string().nullable().optional(),
|
|
33357
|
+
buttonText: z$1.string().nullable().optional(),
|
|
33358
|
+
maxTickets: z$1.string().nullable().optional(),
|
|
33359
|
+
stage: previewStageSchema.optional()
|
|
33307
33360
|
});
|
|
33308
33361
|
eventRegistrationDisplaySchema = z$1.object({
|
|
33309
33362
|
kind: z$1.literal("event-registration"),
|
|
@@ -33314,22 +33367,7 @@ var init_event_registration_interactive = __esmMin((() => {
|
|
|
33314
33367
|
stepLabels: z$1.array(z$1.enum(EVENT_REGISTRATION_SHELL_STEP_LABELS)).min(1),
|
|
33315
33368
|
summaryButtonText: z$1.string()
|
|
33316
33369
|
});
|
|
33317
|
-
eventRegistrationHydrationSchema = z$1.object(
|
|
33318
|
-
occurrenceContext: occurrenceContextSchema$1.optional(),
|
|
33319
|
-
subject: eventRegistrationPageSurfaceSubjectSchema.nullable().optional(),
|
|
33320
|
-
events: z$1.array(eventRegistrationPublicEventSchema).nullable().optional(),
|
|
33321
|
-
maxTickets: z$1.string().optional(),
|
|
33322
|
-
showVenue: z$1.boolean().optional(),
|
|
33323
|
-
showCapacity: z$1.boolean().optional(),
|
|
33324
|
-
successMessage: z$1.string().optional(),
|
|
33325
|
-
waitlistMessage: z$1.string().optional(),
|
|
33326
|
-
buttonVariant: registrationButtonVariantSchema.optional(),
|
|
33327
|
-
overlayEnabled: z$1.boolean().optional(),
|
|
33328
|
-
spamProtectionEnabled: z$1.boolean().optional(),
|
|
33329
|
-
supportEmail: z$1.string().optional(),
|
|
33330
|
-
sitePasses: publicPassProductCollectionSchema.nullable().optional(),
|
|
33331
|
-
siteMemberships: publicMembershipProductCollectionSchema.nullable().optional()
|
|
33332
|
-
});
|
|
33370
|
+
eventRegistrationHydrationSchema = z$1.object(eventRegistrationHydrationSchemaShape);
|
|
33333
33371
|
eventRegistrationRenderSchema = z$1.object({
|
|
33334
33372
|
display: eventRegistrationDisplaySchema,
|
|
33335
33373
|
hydration: eventRegistrationHydrationSchema
|
|
@@ -33354,11 +33392,16 @@ var init_event_registration_interactive = __esmMin((() => {
|
|
|
33354
33392
|
occurrenceContext: source.occurrenceContext ?? null,
|
|
33355
33393
|
subject: source.subject ?? null,
|
|
33356
33394
|
events: source.events ?? null,
|
|
33395
|
+
wholeSeriesOfferings: source.wholeSeriesOfferings ?? null,
|
|
33396
|
+
wholeSeriesOffering: source.wholeSeriesOffering ?? null,
|
|
33357
33397
|
maxTickets: source.maxTickets ?? void 0,
|
|
33358
33398
|
showVenue: source.showVenue,
|
|
33359
33399
|
showCapacity: source.showCapacity,
|
|
33400
|
+
showSessions: source.showSessions,
|
|
33401
|
+
showPrice: source.showPrice,
|
|
33360
33402
|
successMessage: source.successMessage,
|
|
33361
33403
|
waitlistMessage: source.waitlistMessage,
|
|
33404
|
+
membershipMessage: source.membershipMessage,
|
|
33362
33405
|
buttonVariant: source.buttonVariant,
|
|
33363
33406
|
overlayEnabled: source.overlayEnabled,
|
|
33364
33407
|
spamProtectionEnabled: source.spamProtectionEnabled,
|
|
@@ -33394,6 +33437,7 @@ init_shop_shared();
|
|
|
33394
33437
|
init_defineBlock();
|
|
33395
33438
|
init_event_registration_shared();
|
|
33396
33439
|
init_event_registration_interactive();
|
|
33440
|
+
init_shared$4();
|
|
33397
33441
|
const eventRegistrationBlockDefinition = {
|
|
33398
33442
|
manifest: createBlockManifest({
|
|
33399
33443
|
id: "block.event-registration",
|
|
@@ -33489,6 +33533,24 @@ const eventRegistrationBlockDefinition = {
|
|
|
33489
33533
|
defaultValue: true,
|
|
33490
33534
|
ui: { intent: "display" }
|
|
33491
33535
|
},
|
|
33536
|
+
{
|
|
33537
|
+
id: "showSessions",
|
|
33538
|
+
type: "boolean",
|
|
33539
|
+
label: "Show complete schedule",
|
|
33540
|
+
description: "Display every session for whole-series registrations",
|
|
33541
|
+
required: false,
|
|
33542
|
+
defaultValue: true,
|
|
33543
|
+
ui: { intent: "display" }
|
|
33544
|
+
},
|
|
33545
|
+
{
|
|
33546
|
+
id: "showPrice",
|
|
33547
|
+
type: "boolean",
|
|
33548
|
+
label: "Show price",
|
|
33549
|
+
description: "Display the whole-series price",
|
|
33550
|
+
required: false,
|
|
33551
|
+
defaultValue: true,
|
|
33552
|
+
ui: { intent: "display" }
|
|
33553
|
+
},
|
|
33492
33554
|
{
|
|
33493
33555
|
id: "successMessage",
|
|
33494
33556
|
type: "text",
|
|
@@ -33499,6 +33561,26 @@ const eventRegistrationBlockDefinition = {
|
|
|
33499
33561
|
defaultValue: "Thank you for registering! Check your email for confirmation details.",
|
|
33500
33562
|
maxLength: 500
|
|
33501
33563
|
},
|
|
33564
|
+
{
|
|
33565
|
+
id: "waitlistMessage",
|
|
33566
|
+
type: "text",
|
|
33567
|
+
label: "Waitlist message",
|
|
33568
|
+
description: "Message shown after joining a whole-series waitlist",
|
|
33569
|
+
required: false,
|
|
33570
|
+
multiline: true,
|
|
33571
|
+
defaultValue: "You've been added to the waitlist. We'll email you if a place becomes available.",
|
|
33572
|
+
maxLength: 500
|
|
33573
|
+
},
|
|
33574
|
+
{
|
|
33575
|
+
id: "membershipMessage",
|
|
33576
|
+
type: "text",
|
|
33577
|
+
label: "Membership registration message",
|
|
33578
|
+
description: "Message shown when a whole-series place is covered by membership",
|
|
33579
|
+
required: false,
|
|
33580
|
+
multiline: true,
|
|
33581
|
+
defaultValue: "Registered using your membership. Check your email for session details.",
|
|
33582
|
+
maxLength: 500
|
|
33583
|
+
},
|
|
33502
33584
|
{
|
|
33503
33585
|
id: "buttonText",
|
|
33504
33586
|
type: "text",
|
|
@@ -33530,8 +33612,11 @@ const eventRegistrationBlockDefinition = {
|
|
|
33530
33612
|
} },
|
|
33531
33613
|
showVenue: { $bind: { from: "content.showVenue" } },
|
|
33532
33614
|
showCapacity: { $bind: { from: "content.showCapacity" } },
|
|
33615
|
+
showSessions: { $bind: { from: "content.showSessions" } },
|
|
33616
|
+
showPrice: { $bind: { from: "content.showPrice" } },
|
|
33533
33617
|
successMessage: { $bind: { from: "content.successMessage" } },
|
|
33534
33618
|
waitlistMessage: { $bind: { from: "content.waitlistMessage" } },
|
|
33619
|
+
membershipMessage: { $bind: { from: "content.membershipMessage" } },
|
|
33535
33620
|
buttonText: { $bind: {
|
|
33536
33621
|
from: "content.buttonText",
|
|
33537
33622
|
fallback: "Complete Registration"
|
|
@@ -33545,6 +33630,7 @@ const eventRegistrationBlockDefinition = {
|
|
|
33545
33630
|
fallback: false
|
|
33546
33631
|
} },
|
|
33547
33632
|
events: { $bind: { from: "data.events" } },
|
|
33633
|
+
wholeSeriesOffering: { $bind: { from: "data.wholeSeriesOffering.offering" } },
|
|
33548
33634
|
sitePasses: { $bind: { from: "data.sitePasses" } },
|
|
33549
33635
|
siteMemberships: { $bind: { from: "data.siteMemberships" } },
|
|
33550
33636
|
stage: { $bind: {
|
|
@@ -33558,9 +33644,10 @@ const eventRegistrationBlockDefinition = {
|
|
|
33558
33644
|
runtime: eventRegistrationBlockRuntime,
|
|
33559
33645
|
dataSchemas: {
|
|
33560
33646
|
events: publicEventsArraySchema.optional(),
|
|
33647
|
+
wholeSeriesOffering: z$1.object({ offering: publicCourseSchema }).optional(),
|
|
33561
33648
|
sitePasses: publicPassProductCollectionSchema.optional(),
|
|
33562
33649
|
siteMemberships: publicMembershipProductCollectionSchema.optional(),
|
|
33563
|
-
occurrenceContext: occurrenceContextSchema
|
|
33650
|
+
occurrenceContext: occurrenceContextSchema.optional()
|
|
33564
33651
|
},
|
|
33565
33652
|
dataLoaders: {
|
|
33566
33653
|
events: {
|
|
@@ -33573,11 +33660,23 @@ const eventRegistrationBlockDefinition = {
|
|
|
33573
33660
|
fallback: "published"
|
|
33574
33661
|
} },
|
|
33575
33662
|
readProfile: "registration",
|
|
33576
|
-
seriesId: { $bind: { from: "$root.
|
|
33663
|
+
seriesId: { $bind: { from: "$root.subject.eventSeriesId" } },
|
|
33577
33664
|
includeOccurrenceId: { $bind: { from: "$root.occurrenceContext.id" } }
|
|
33578
33665
|
},
|
|
33579
33666
|
mode: "server"
|
|
33580
33667
|
},
|
|
33668
|
+
wholeSeriesOffering: {
|
|
33669
|
+
endpoint: "getPublicWholeSeriesOffering",
|
|
33670
|
+
params: {
|
|
33671
|
+
siteId: { $bind: { from: "$root.siteId" } },
|
|
33672
|
+
eventSeriesId: { $bind: { from: "$root.subject.eventSeriesId" } },
|
|
33673
|
+
stage: { $bind: {
|
|
33674
|
+
from: "$root.previewStage",
|
|
33675
|
+
fallback: "published"
|
|
33676
|
+
} }
|
|
33677
|
+
},
|
|
33678
|
+
mode: "server"
|
|
33679
|
+
},
|
|
33581
33680
|
sitePasses: {
|
|
33582
33681
|
endpoint: "listPublicPasses",
|
|
33583
33682
|
params: { siteId: { $bind: { from: "$root.siteId" } } },
|
|
@@ -35441,9 +35540,6 @@ function parseSignedNewsletterDestinationRef(value) {
|
|
|
35441
35540
|
const trimmed = parseTrimmedString(value);
|
|
35442
35541
|
return trimmed && SIGNED_DESTINATION_REF_PATTERN.test(trimmed) ? trimmed : null;
|
|
35443
35542
|
}
|
|
35444
|
-
function parseNewsletterSignupDestinationProvider(value) {
|
|
35445
|
-
return value === "riverbank" || value === "mailchimp" ? value : null;
|
|
35446
|
-
}
|
|
35447
35543
|
function buildNewsletterSignupBlockRef(blockId) {
|
|
35448
35544
|
const parsed = parseNewsletterSignupBlockId(blockId);
|
|
35449
35545
|
return parsed ? {
|
|
@@ -35484,6 +35580,7 @@ function parseTrimmedString(value) {
|
|
|
35484
35580
|
}
|
|
35485
35581
|
var BLOCK_ID_PATTERN, SIGNED_DESTINATION_REF_PATTERN;
|
|
35486
35582
|
var init_newsletter_signup_destination = __esmMin((() => {
|
|
35583
|
+
init_src$3();
|
|
35487
35584
|
BLOCK_ID_PATTERN = /^[A-Za-z0-9._:-]{1,200}$/;
|
|
35488
35585
|
SIGNED_DESTINATION_REF_PATTERN = /^[A-Za-z0-9._~-]{16,1000}$/;
|
|
35489
35586
|
}));
|
|
@@ -35590,6 +35687,30 @@ function buildNewsletterDisplay(source) {
|
|
|
35590
35687
|
fields: getPresetFields(preset, { includePhone })
|
|
35591
35688
|
};
|
|
35592
35689
|
}
|
|
35690
|
+
function projectNewsletterFormHydrationTarget(source) {
|
|
35691
|
+
switch (source.source) {
|
|
35692
|
+
case "block": {
|
|
35693
|
+
const destinationRef = buildNewsletterSignupBlockRef(source.blockId);
|
|
35694
|
+
if (destinationRef?.tag === "block_ref") return {
|
|
35695
|
+
tag: "block-source",
|
|
35696
|
+
destinationRef
|
|
35697
|
+
};
|
|
35698
|
+
return {
|
|
35699
|
+
tag: "legacy-direct-list",
|
|
35700
|
+
listId: source.listId ?? null
|
|
35701
|
+
};
|
|
35702
|
+
}
|
|
35703
|
+
case "signed-footer": return {
|
|
35704
|
+
tag: "signed-footer-source",
|
|
35705
|
+
destinationRef: source.destinationRef
|
|
35706
|
+
};
|
|
35707
|
+
case "legacy-direct-list": return {
|
|
35708
|
+
tag: "legacy-direct-list",
|
|
35709
|
+
listId: source.listId
|
|
35710
|
+
};
|
|
35711
|
+
default: return assertNever$20(source);
|
|
35712
|
+
}
|
|
35713
|
+
}
|
|
35593
35714
|
function buildNewsletterFormInteractiveIslandProps(props) {
|
|
35594
35715
|
return buildInteractiveIslandProps({
|
|
35595
35716
|
runtime: newsletterFormBlockRuntime,
|
|
@@ -35611,8 +35732,9 @@ function parseRequiredSignedNewsletterDestinationRef(value) {
|
|
|
35611
35732
|
if (!parsed) throw new Error("Newsletter signup signed destination ref requires token");
|
|
35612
35733
|
return parsed;
|
|
35613
35734
|
}
|
|
35614
|
-
var newsletterPresetSchema, newsletterDestinationProviderSchema, newsletterButtonVariantSchema, newsletterFieldSchema, newsletterSignupBlockIdSchema, signedNewsletterDestinationRefSchema,
|
|
35735
|
+
var newsletterPresetSchema, newsletterDestinationProviderSchema, newsletterButtonVariantSchema, newsletterFieldSchema, newsletterSignupBlockIdSchema, signedNewsletterDestinationRefSchema, newsletterSourceCommonSchema, newsletterSourceSchema, newsletterDisplaySchema, newsletterHydrationSchema, newsletterRenderSchema, newsletterIslandMetaCodec, newsletterIslandMetaKeys, newsletterFormBlockRuntime, newsletterFormInteractiveIslandPropsCodec;
|
|
35615
35736
|
var init_newsletter_form_interactive = __esmMin((() => {
|
|
35737
|
+
init_src$3();
|
|
35616
35738
|
init_islands();
|
|
35617
35739
|
init_runtime();
|
|
35618
35740
|
init_newsletter_signup_destination();
|
|
@@ -35635,19 +35757,9 @@ var init_newsletter_form_interactive = __esmMin((() => {
|
|
|
35635
35757
|
});
|
|
35636
35758
|
newsletterSignupBlockIdSchema = z$1.string().trim().min(1).transform(parseRequiredNewsletterSignupBlockId);
|
|
35637
35759
|
signedNewsletterDestinationRefSchema = z$1.string().trim().min(1).transform(parseRequiredSignedNewsletterDestinationRef);
|
|
35638
|
-
|
|
35639
|
-
tag: z$1.literal("block_ref"),
|
|
35640
|
-
blockId: newsletterSignupBlockIdSchema
|
|
35641
|
-
}), z$1.object({
|
|
35642
|
-
tag: z$1.literal("signed_destination_ref"),
|
|
35643
|
-
token: signedNewsletterDestinationRefSchema
|
|
35644
|
-
})]);
|
|
35645
|
-
newsletterSourceSchema = z$1.object({
|
|
35646
|
-
blockId: z$1.string().nullable().optional(),
|
|
35760
|
+
newsletterSourceCommonSchema = z$1.object({
|
|
35647
35761
|
siteId: z$1.string().optional(),
|
|
35648
35762
|
apiBaseUrl: z$1.string().optional(),
|
|
35649
|
-
listId: z$1.string().nullable().optional(),
|
|
35650
|
-
destinationProvider: newsletterDestinationProviderSchema.nullable().optional(),
|
|
35651
35763
|
preset: newsletterPresetSchema.optional(),
|
|
35652
35764
|
includePhone: z$1.boolean().optional(),
|
|
35653
35765
|
buttonLabel: z$1.string().nullable().optional(),
|
|
@@ -35658,6 +35770,25 @@ var init_newsletter_form_interactive = __esmMin((() => {
|
|
|
35658
35770
|
spamProtectionEnabled: z$1.boolean().optional(),
|
|
35659
35771
|
className: z$1.string().nullable().optional()
|
|
35660
35772
|
});
|
|
35773
|
+
newsletterSourceSchema = z$1.discriminatedUnion("source", [
|
|
35774
|
+
newsletterSourceCommonSchema.extend({
|
|
35775
|
+
source: z$1.literal("block"),
|
|
35776
|
+
blockId: z$1.string().nullable().optional(),
|
|
35777
|
+
listId: z$1.string().nullable().optional(),
|
|
35778
|
+
destinationProvider: newsletterDestinationProviderSchema.nullable().optional()
|
|
35779
|
+
}),
|
|
35780
|
+
newsletterSourceCommonSchema.extend({
|
|
35781
|
+
source: z$1.literal("signed-footer"),
|
|
35782
|
+
destinationRef: z$1.object({
|
|
35783
|
+
tag: z$1.literal("signed_destination_ref"),
|
|
35784
|
+
token: signedNewsletterDestinationRefSchema
|
|
35785
|
+
})
|
|
35786
|
+
}),
|
|
35787
|
+
newsletterSourceCommonSchema.extend({
|
|
35788
|
+
source: z$1.literal("legacy-direct-list"),
|
|
35789
|
+
listId: z$1.string().nullable()
|
|
35790
|
+
})
|
|
35791
|
+
]);
|
|
35661
35792
|
newsletterDisplaySchema = z$1.object({
|
|
35662
35793
|
kind: z$1.literal("newsletter-form"),
|
|
35663
35794
|
className: z$1.string().nullable(),
|
|
@@ -35668,8 +35799,26 @@ var init_newsletter_form_interactive = __esmMin((() => {
|
|
|
35668
35799
|
fields: z$1.array(newsletterFieldSchema)
|
|
35669
35800
|
});
|
|
35670
35801
|
newsletterHydrationSchema = z$1.object({
|
|
35671
|
-
|
|
35672
|
-
|
|
35802
|
+
target: z$1.discriminatedUnion("tag", [
|
|
35803
|
+
z$1.object({
|
|
35804
|
+
tag: z$1.literal("block-source"),
|
|
35805
|
+
destinationRef: z$1.object({
|
|
35806
|
+
tag: z$1.literal("block_ref"),
|
|
35807
|
+
blockId: newsletterSignupBlockIdSchema
|
|
35808
|
+
}).nullable()
|
|
35809
|
+
}),
|
|
35810
|
+
z$1.object({
|
|
35811
|
+
tag: z$1.literal("signed-footer-source"),
|
|
35812
|
+
destinationRef: z$1.object({
|
|
35813
|
+
tag: z$1.literal("signed_destination_ref"),
|
|
35814
|
+
token: signedNewsletterDestinationRefSchema
|
|
35815
|
+
})
|
|
35816
|
+
}),
|
|
35817
|
+
z$1.object({
|
|
35818
|
+
tag: z$1.literal("legacy-direct-list"),
|
|
35819
|
+
listId: z$1.string().nullable()
|
|
35820
|
+
})
|
|
35821
|
+
]),
|
|
35673
35822
|
preset: newsletterPresetSchema,
|
|
35674
35823
|
includePhone: z$1.boolean(),
|
|
35675
35824
|
tags: z$1.string().nullable().optional(),
|
|
@@ -35691,15 +35840,14 @@ var init_newsletter_form_interactive = __esmMin((() => {
|
|
|
35691
35840
|
render: createZodCodec(newsletterRenderSchema)
|
|
35692
35841
|
},
|
|
35693
35842
|
buildRender: (source) => {
|
|
35694
|
-
const runtimeSource = deriveNewsletterSignupRuntimeSource(source);
|
|
35843
|
+
const runtimeSource = source.source === "block" ? deriveNewsletterSignupRuntimeSource(source) : null;
|
|
35695
35844
|
return {
|
|
35696
35845
|
display: buildNewsletterDisplay(source),
|
|
35697
35846
|
hydration: {
|
|
35698
|
-
|
|
35699
|
-
listId: runtimeSource.listId,
|
|
35847
|
+
target: projectNewsletterFormHydrationTarget(source),
|
|
35700
35848
|
preset: source.preset ?? "emailOnly",
|
|
35701
35849
|
includePhone: source.includePhone ?? false,
|
|
35702
|
-
tags: runtimeSource.tags,
|
|
35850
|
+
tags: runtimeSource ? runtimeSource.tags : source.tags,
|
|
35703
35851
|
spamProtectionEnabled: source.spamProtectionEnabled
|
|
35704
35852
|
}
|
|
35705
35853
|
};
|
|
@@ -38202,13 +38350,13 @@ init_newsletter_form_interactive();
|
|
|
38202
38350
|
* Renders the newsletter signup form for SSR with hydration support.
|
|
38203
38351
|
* Uses the islands architecture pattern to hydrate on the client.
|
|
38204
38352
|
*/
|
|
38205
|
-
function NewsletterFormSSR(
|
|
38353
|
+
function NewsletterFormSSR(props) {
|
|
38354
|
+
const { siteId, apiBaseUrl, preset = "emailOnly", includePhone, buttonLabel = "Subscribe", buttonVariant = "primary", successMessage, privacyNote, tags, spamProtectionEnabled, className } = props;
|
|
38355
|
+
const blockId = props.source === "block" ? props.blockId : null;
|
|
38206
38356
|
const islandProps = buildNewsletterFormInteractiveIslandProps({
|
|
38207
|
-
|
|
38357
|
+
...props,
|
|
38208
38358
|
siteId,
|
|
38209
38359
|
apiBaseUrl,
|
|
38210
|
-
listId,
|
|
38211
|
-
destinationProvider,
|
|
38212
38360
|
preset,
|
|
38213
38361
|
includePhone,
|
|
38214
38362
|
buttonLabel,
|
|
@@ -104130,78 +104278,6 @@ var init_EventRegistrationWizard = __esmMin((() => {
|
|
|
104130
104278
|
};
|
|
104131
104279
|
}));
|
|
104132
104280
|
//#endregion
|
|
104133
|
-
//#region ../blocks/src/system/runtime/nodes/event-registration/PastOccurrenceNotice.tsx
|
|
104134
|
-
function isPastOccurrence(startsAt) {
|
|
104135
|
-
if (!startsAt) return false;
|
|
104136
|
-
const startsAtTime = new Date(startsAt).getTime();
|
|
104137
|
-
if (!Number.isFinite(startsAtTime)) return false;
|
|
104138
|
-
return startsAtTime <= Date.now();
|
|
104139
|
-
}
|
|
104140
|
-
function getParentPathname(pathname) {
|
|
104141
|
-
const segments = pathname.split("/").filter(Boolean);
|
|
104142
|
-
if (segments.length < 2) return null;
|
|
104143
|
-
return `/${segments.slice(0, -1).join("/")}`;
|
|
104144
|
-
}
|
|
104145
|
-
function PastOccurrenceNotice(props) {
|
|
104146
|
-
const [parentPathname, setParentPathname] = useState(null);
|
|
104147
|
-
useEffect(() => {
|
|
104148
|
-
setParentPathname(getParentPathname(window.location.pathname));
|
|
104149
|
-
}, []);
|
|
104150
|
-
return /* @__PURE__ */ jsx("div", {
|
|
104151
|
-
id: props.anchorId,
|
|
104152
|
-
className: `event-registration ${props.className || ""}`,
|
|
104153
|
-
"data-block": "event-registration",
|
|
104154
|
-
children: /* @__PURE__ */ jsxs("div", {
|
|
104155
|
-
className: "er-empty",
|
|
104156
|
-
children: [/* @__PURE__ */ jsxs("p", {
|
|
104157
|
-
className: "er-empty__text",
|
|
104158
|
-
children: [
|
|
104159
|
-
"This event date (",
|
|
104160
|
-
formatEventDateTime(props.startsAt, { timeZone: props.timeZone ?? void 0 }),
|
|
104161
|
-
") has already started. Registration is closed."
|
|
104162
|
-
]
|
|
104163
|
-
}), parentPathname && /* @__PURE__ */ jsx("p", {
|
|
104164
|
-
className: "er-empty__text",
|
|
104165
|
-
children: /* @__PURE__ */ jsx("a", {
|
|
104166
|
-
href: parentPathname,
|
|
104167
|
-
className: "er-link",
|
|
104168
|
-
children: "View other dates for this event"
|
|
104169
|
-
})
|
|
104170
|
-
})]
|
|
104171
|
-
})
|
|
104172
|
-
});
|
|
104173
|
-
}
|
|
104174
|
-
var init_PastOccurrenceNotice = __esmMin((() => {
|
|
104175
|
-
init_utils$1();
|
|
104176
|
-
}));
|
|
104177
|
-
//#endregion
|
|
104178
|
-
//#region ../blocks/src/system/runtime/nodes/event-registration.client.tsx
|
|
104179
|
-
function toEventRegistrationClientProps(props) {
|
|
104180
|
-
return {
|
|
104181
|
-
...props.render.hydration,
|
|
104182
|
-
buttonText: props.render.display.summaryButtonText,
|
|
104183
|
-
className: props.render.display.className ?? void 0
|
|
104184
|
-
};
|
|
104185
|
-
}
|
|
104186
|
-
var EventRegistrationClient, EventRegistrationIslandClient;
|
|
104187
|
-
var init_event_registration_client = __esmMin((() => {
|
|
104188
|
-
init_EventRegistrationWizard();
|
|
104189
|
-
init_constants();
|
|
104190
|
-
init_PastOccurrenceNotice();
|
|
104191
|
-
EventRegistrationClient = (clientProps) => {
|
|
104192
|
-
if (isPastOccurrence(clientProps.occurrenceContext?.startsAt) && clientProps.occurrenceContext?.startsAt) return /* @__PURE__ */ jsx(PastOccurrenceNotice, {
|
|
104193
|
-
anchorId: EVENT_REGISTRATION_ANCHOR_ID,
|
|
104194
|
-
className: clientProps.className,
|
|
104195
|
-
startsAt: clientProps.occurrenceContext.startsAt,
|
|
104196
|
-
timeZone: clientProps.events?.[0]?.timeZone ?? null
|
|
104197
|
-
});
|
|
104198
|
-
return /* @__PURE__ */ jsx(EventRegistrationWizard, { ...clientProps });
|
|
104199
|
-
};
|
|
104200
|
-
EventRegistrationIslandClient = (props) => {
|
|
104201
|
-
return /* @__PURE__ */ jsx(EventRegistrationClient, { ...toEventRegistrationClientProps(props) });
|
|
104202
|
-
};
|
|
104203
|
-
}));
|
|
104204
|
-
//#endregion
|
|
104205
104281
|
//#region ../blocks/src/system/runtime/nodes/course-registration/utils.ts
|
|
104206
104282
|
/**
|
|
104207
104283
|
* Format a date string to a localized date.
|
|
@@ -106183,6 +106259,136 @@ var init_CourseRegistrationWizard = __esmMin((() => {
|
|
|
106183
106259
|
init_DiscountCodeDisclosure();
|
|
106184
106260
|
}));
|
|
106185
106261
|
//#endregion
|
|
106262
|
+
//#region ../blocks/src/system/runtime/nodes/event-registration/registrationSurface.ts
|
|
106263
|
+
function planEventRegistrationSurface(input) {
|
|
106264
|
+
const scopedEvents = resolveEventRegistrationScopedEvents(input.events, {
|
|
106265
|
+
occurrenceContext: input.occurrenceContext,
|
|
106266
|
+
subject: input.subject
|
|
106267
|
+
});
|
|
106268
|
+
const bookingScopes = new Set(scopedEvents.map((event) => event.bookingScope));
|
|
106269
|
+
if (!input.occurrenceContext && !input.subject && bookingScopes.has("single_occurrence")) return {
|
|
106270
|
+
kind: "occurrence",
|
|
106271
|
+
events: scopedEvents.filter((event) => event.bookingScope === "single_occurrence")
|
|
106272
|
+
};
|
|
106273
|
+
if (bookingScopes.size === 0 || bookingScopes.has("single_occurrence")) return bookingScopes.has("whole_series") ? { kind: "mixedBookingScopes" } : {
|
|
106274
|
+
kind: "occurrence",
|
|
106275
|
+
events: scopedEvents
|
|
106276
|
+
};
|
|
106277
|
+
const requiredSeriesIds = new Set(scopedEvents.map((event) => event.seriesId));
|
|
106278
|
+
const offerings = input.wholeSeriesOfferings.filter((offering) => requiredSeriesIds.has(offering.eventSeriesId));
|
|
106279
|
+
const loadedSeriesIds = new Set(offerings.map((offering) => offering.eventSeriesId));
|
|
106280
|
+
return [...requiredSeriesIds].every((seriesId) => loadedSeriesIds.has(seriesId)) && offerings.length > 0 ? {
|
|
106281
|
+
kind: "wholeSeries",
|
|
106282
|
+
offerings
|
|
106283
|
+
} : { kind: "unavailableWholeSeries" };
|
|
106284
|
+
}
|
|
106285
|
+
var init_registrationSurface = __esmMin((() => {
|
|
106286
|
+
init_eventScope();
|
|
106287
|
+
}));
|
|
106288
|
+
//#endregion
|
|
106289
|
+
//#region ../blocks/src/system/runtime/nodes/event-registration/PastOccurrenceNotice.tsx
|
|
106290
|
+
function isPastOccurrence(startsAt) {
|
|
106291
|
+
if (!startsAt) return false;
|
|
106292
|
+
const startsAtTime = new Date(startsAt).getTime();
|
|
106293
|
+
if (!Number.isFinite(startsAtTime)) return false;
|
|
106294
|
+
return startsAtTime <= Date.now();
|
|
106295
|
+
}
|
|
106296
|
+
function getParentPathname(pathname) {
|
|
106297
|
+
const segments = pathname.split("/").filter(Boolean);
|
|
106298
|
+
if (segments.length < 2) return null;
|
|
106299
|
+
return `/${segments.slice(0, -1).join("/")}`;
|
|
106300
|
+
}
|
|
106301
|
+
function PastOccurrenceNotice(props) {
|
|
106302
|
+
const [parentPathname, setParentPathname] = useState(null);
|
|
106303
|
+
useEffect(() => {
|
|
106304
|
+
setParentPathname(getParentPathname(window.location.pathname));
|
|
106305
|
+
}, []);
|
|
106306
|
+
return /* @__PURE__ */ jsx("div", {
|
|
106307
|
+
id: props.anchorId,
|
|
106308
|
+
className: `event-registration ${props.className || ""}`,
|
|
106309
|
+
"data-block": "event-registration",
|
|
106310
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
106311
|
+
className: "er-empty",
|
|
106312
|
+
children: [/* @__PURE__ */ jsxs("p", {
|
|
106313
|
+
className: "er-empty__text",
|
|
106314
|
+
children: [
|
|
106315
|
+
"This event date (",
|
|
106316
|
+
formatEventDateTime(props.startsAt, { timeZone: props.timeZone ?? void 0 }),
|
|
106317
|
+
") has already started. Registration is closed."
|
|
106318
|
+
]
|
|
106319
|
+
}), parentPathname && /* @__PURE__ */ jsx("p", {
|
|
106320
|
+
className: "er-empty__text",
|
|
106321
|
+
children: /* @__PURE__ */ jsx("a", {
|
|
106322
|
+
href: parentPathname,
|
|
106323
|
+
className: "er-link",
|
|
106324
|
+
children: "View other dates for this event"
|
|
106325
|
+
})
|
|
106326
|
+
})]
|
|
106327
|
+
})
|
|
106328
|
+
});
|
|
106329
|
+
}
|
|
106330
|
+
var init_PastOccurrenceNotice = __esmMin((() => {
|
|
106331
|
+
init_utils$1();
|
|
106332
|
+
}));
|
|
106333
|
+
//#endregion
|
|
106334
|
+
//#region ../blocks/src/system/runtime/nodes/event-registration.client.tsx
|
|
106335
|
+
function toEventRegistrationClientProps(props) {
|
|
106336
|
+
return {
|
|
106337
|
+
...props.render.hydration,
|
|
106338
|
+
buttonText: props.render.display.summaryButtonText,
|
|
106339
|
+
className: props.render.display.className ?? void 0
|
|
106340
|
+
};
|
|
106341
|
+
}
|
|
106342
|
+
var EventRegistrationClient, EventRegistrationIslandClient;
|
|
106343
|
+
var init_event_registration_client = __esmMin((() => {
|
|
106344
|
+
init_EventRegistrationWizard();
|
|
106345
|
+
init_CourseRegistrationErrorBoundary();
|
|
106346
|
+
init_CourseRegistrationWizard();
|
|
106347
|
+
init_registrationSurface();
|
|
106348
|
+
init_constants();
|
|
106349
|
+
init_PastOccurrenceNotice();
|
|
106350
|
+
EventRegistrationClient = (clientProps) => {
|
|
106351
|
+
const surface = planEventRegistrationSurface({
|
|
106352
|
+
events: clientProps.events ?? [],
|
|
106353
|
+
wholeSeriesOfferings: clientProps.wholeSeriesOffering ? [clientProps.wholeSeriesOffering] : clientProps.wholeSeriesOfferings ?? [],
|
|
106354
|
+
occurrenceContext: clientProps.occurrenceContext,
|
|
106355
|
+
subject: clientProps.subject
|
|
106356
|
+
});
|
|
106357
|
+
if (surface.kind === "wholeSeries") return /* @__PURE__ */ jsx(CourseRegistrationErrorBoundary, {
|
|
106358
|
+
className: clientProps.className,
|
|
106359
|
+
children: /* @__PURE__ */ jsx(CourseRegistrationWizard, {
|
|
106360
|
+
subject: clientProps.subject,
|
|
106361
|
+
courses: [...surface.offerings],
|
|
106362
|
+
showSessions: clientProps.showSessions,
|
|
106363
|
+
showPrice: clientProps.showPrice,
|
|
106364
|
+
showCapacity: clientProps.showCapacity,
|
|
106365
|
+
showVenue: clientProps.showVenue,
|
|
106366
|
+
successMessage: clientProps.successMessage,
|
|
106367
|
+
waitlistMessage: clientProps.waitlistMessage,
|
|
106368
|
+
membershipMessage: clientProps.membershipMessage,
|
|
106369
|
+
buttonText: clientProps.buttonText,
|
|
106370
|
+
buttonVariant: clientProps.buttonVariant,
|
|
106371
|
+
className: clientProps.className
|
|
106372
|
+
})
|
|
106373
|
+
});
|
|
106374
|
+
if (surface.kind === "unavailableWholeSeries" || surface.kind === "mixedBookingScopes") return /* @__PURE__ */ jsx("div", {
|
|
106375
|
+
className: clientProps.className,
|
|
106376
|
+
role: "status",
|
|
106377
|
+
children: "Registration is temporarily unavailable. Please refresh the page or try again shortly."
|
|
106378
|
+
});
|
|
106379
|
+
if (isPastOccurrence(clientProps.occurrenceContext?.startsAt) && clientProps.occurrenceContext?.startsAt) return /* @__PURE__ */ jsx(PastOccurrenceNotice, {
|
|
106380
|
+
anchorId: EVENT_REGISTRATION_ANCHOR_ID,
|
|
106381
|
+
className: clientProps.className,
|
|
106382
|
+
startsAt: clientProps.occurrenceContext.startsAt,
|
|
106383
|
+
timeZone: clientProps.events?.[0]?.timeZone ?? null
|
|
106384
|
+
});
|
|
106385
|
+
return /* @__PURE__ */ jsx(EventRegistrationWizard, { ...clientProps });
|
|
106386
|
+
};
|
|
106387
|
+
EventRegistrationIslandClient = (props) => {
|
|
106388
|
+
return /* @__PURE__ */ jsx(EventRegistrationClient, { ...toEventRegistrationClientProps(props) });
|
|
106389
|
+
};
|
|
106390
|
+
}));
|
|
106391
|
+
//#endregion
|
|
106186
106392
|
//#region ../blocks/src/system/runtime/nodes/course-registration.client.tsx
|
|
106187
106393
|
function toCourseRegistrationClientProps(props) {
|
|
106188
106394
|
return {
|
|
@@ -114635,24 +114841,34 @@ function mapNewsletterFormFieldsToSubscriberInput(fields) {
|
|
|
114635
114841
|
};
|
|
114636
114842
|
}
|
|
114637
114843
|
function resolveNewsletterSubmitTarget(input) {
|
|
114638
|
-
|
|
114639
|
-
|
|
114640
|
-
|
|
114641
|
-
|
|
114642
|
-
|
|
114643
|
-
|
|
114844
|
+
switch (input.tag) {
|
|
114845
|
+
case "block-source": return input.destinationRef ? publishedDestinationTarget(input.destinationRef) : {
|
|
114846
|
+
tag: "unavailable",
|
|
114847
|
+
reason: "missing_block_source"
|
|
114848
|
+
};
|
|
114849
|
+
case "signed-footer-source": return publishedDestinationTarget(input.destinationRef);
|
|
114850
|
+
case "legacy-direct-list": {
|
|
114851
|
+
const listId = input.listId?.trim();
|
|
114852
|
+
return listId ? {
|
|
114853
|
+
tag: "ready",
|
|
114854
|
+
target: {
|
|
114855
|
+
tag: "legacy_riverbank_list",
|
|
114856
|
+
listId
|
|
114857
|
+
}
|
|
114858
|
+
} : {
|
|
114859
|
+
tag: "unavailable",
|
|
114860
|
+
reason: "missing_legacy_list"
|
|
114861
|
+
};
|
|
114644
114862
|
}
|
|
114645
|
-
|
|
114646
|
-
|
|
114647
|
-
|
|
114648
|
-
|
|
114649
|
-
};
|
|
114863
|
+
default: return assertNever$20(input);
|
|
114864
|
+
}
|
|
114865
|
+
}
|
|
114866
|
+
function publishedDestinationTarget(destinationRef) {
|
|
114650
114867
|
return {
|
|
114651
114868
|
tag: "ready",
|
|
114652
114869
|
target: {
|
|
114653
|
-
tag: "
|
|
114654
|
-
|
|
114655
|
-
destinationRef: input.destinationRef ?? void 0
|
|
114870
|
+
tag: "published_block_ref",
|
|
114871
|
+
destinationRef
|
|
114656
114872
|
}
|
|
114657
114873
|
};
|
|
114658
114874
|
}
|
|
@@ -114663,7 +114879,9 @@ function readOptionalSubmittedText(value) {
|
|
|
114663
114879
|
function readSubmittedText(value) {
|
|
114664
114880
|
return typeof value === "string" ? value.trim() : "";
|
|
114665
114881
|
}
|
|
114666
|
-
var init_newsletter_form_submission = __esmMin((() => {
|
|
114882
|
+
var init_newsletter_form_submission = __esmMin((() => {
|
|
114883
|
+
init_src$3();
|
|
114884
|
+
}));
|
|
114667
114885
|
//#endregion
|
|
114668
114886
|
//#region ../blocks/src/system/runtime/nodes/newsletter-form.client.tsx
|
|
114669
114887
|
function NewsletterFormClient({ render }) {
|
|
@@ -114696,10 +114914,7 @@ function NewsletterFormClient({ render }) {
|
|
|
114696
114914
|
});
|
|
114697
114915
|
return;
|
|
114698
114916
|
}
|
|
114699
|
-
const submitTarget = resolveNewsletterSubmitTarget(
|
|
114700
|
-
listId: render.hydration.listId,
|
|
114701
|
-
destinationRef: render.hydration.destinationRef
|
|
114702
|
-
});
|
|
114917
|
+
const submitTarget = resolveNewsletterSubmitTarget(render.hydration.target);
|
|
114703
114918
|
if (submitTarget.tag === "unavailable") {
|
|
114704
114919
|
dispatchSubmission({
|
|
114705
114920
|
type: "failed",
|
|
@@ -115964,7 +116179,7 @@ function isSafeHttpsUrl(value) {
|
|
|
115964
116179
|
}
|
|
115965
116180
|
//#endregion
|
|
115966
116181
|
//#region ../blocks/src/system/blocks/event-details.ts
|
|
115967
|
-
var
|
|
116182
|
+
var eventAutoApplyDiscountPreviewBaseSchema, eventAutoApplyDiscountPreviewSchema;
|
|
115968
116183
|
var init_event_details = __esmMin((() => {
|
|
115969
116184
|
init_builder$2();
|
|
115970
116185
|
init_styledSection();
|
|
@@ -115972,6 +116187,7 @@ var init_event_details = __esmMin((() => {
|
|
|
115972
116187
|
init_shared$2();
|
|
115973
116188
|
init_shop_shared();
|
|
115974
116189
|
init_defineBlock();
|
|
116190
|
+
init_event_registration_shared();
|
|
115975
116191
|
createBlockManifest({
|
|
115976
116192
|
id: "block.event-details",
|
|
115977
116193
|
version: "1.0.0",
|
|
@@ -116126,15 +116342,6 @@ var init_event_details = __esmMin((() => {
|
|
|
116126
116342
|
})], { gap: "lg" })
|
|
116127
116343
|
})]
|
|
116128
116344
|
});
|
|
116129
|
-
occurrenceContextSchema = z$1.object({
|
|
116130
|
-
id: z$1.string(),
|
|
116131
|
-
seriesId: z$1.string(),
|
|
116132
|
-
startsAt: z$1.string(),
|
|
116133
|
-
endsAt: z$1.string(),
|
|
116134
|
-
timeZone: z$1.string(),
|
|
116135
|
-
capacityOverride: z$1.number().nullable().optional(),
|
|
116136
|
-
overrides: z$1.record(z$1.string(), z$1.unknown()).nullable().optional()
|
|
116137
|
-
}).nullable();
|
|
116138
116345
|
eventAutoApplyDiscountPreviewBaseSchema = z$1.object({
|
|
116139
116346
|
id: z$1.string(),
|
|
116140
116347
|
publicLabel: z$1.string(),
|
|
@@ -116538,6 +116745,7 @@ var init_carousel = __esmMin((() => {
|
|
|
116538
116745
|
var init_form$1 = __esmMin((() => {
|
|
116539
116746
|
init_api();
|
|
116540
116747
|
init_form_client();
|
|
116748
|
+
init_form_interactive();
|
|
116541
116749
|
}));
|
|
116542
116750
|
//#endregion
|
|
116543
116751
|
//#region src/rendering/islands/enhancers/form.tsx
|
|
@@ -117008,6 +117216,7 @@ var init_shop = __esmMin((() => {
|
|
|
117008
117216
|
var init_newsletter_form = __esmMin((() => {
|
|
117009
117217
|
init_api();
|
|
117010
117218
|
init_newsletter_form_client();
|
|
117219
|
+
init_newsletter_form_interactive();
|
|
117011
117220
|
}));
|
|
117012
117221
|
//#endregion
|
|
117013
117222
|
//#region src/rendering/islands/enhancers/newsletterForm.tsx
|
|
@@ -117047,7 +117256,6 @@ var init_newsletterForm = __esmMin((() => {
|
|
|
117047
117256
|
const { siteId, apiBaseUrl, render } = props;
|
|
117048
117257
|
if (!siteId) throw new Error("[sdk:islands] newsletter-form requires siteId");
|
|
117049
117258
|
if (!apiBaseUrl) throw new Error("[sdk:islands] newsletter-form requires apiBaseUrl");
|
|
117050
|
-
if (!render.hydration.listId) throw new Error("[sdk:islands] newsletter-form requires listId");
|
|
117051
117259
|
const apiConfig = {
|
|
117052
117260
|
baseUrl: apiBaseUrl,
|
|
117053
117261
|
auth: { type: "none" },
|