@riverbankcms/sdk 0.159.0 → 0.160.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 +4 -4
- package/dist/_dts/{BlocksIslandsHydrator-Cj1i1Yhh.d.ts → BlocksIslandsHydrator-CoqeotCL.d.ts} +1 -1
- package/dist/_dts/{Page-Cgzbv22M.d.ts → Page-C0ENVLCF.d.ts} +13 -6
- package/dist/_dts/{SdkPreviewMode-BC_FGc6b.d.ts → SdkPreviewMode-jZK0A49V.d.ts} +54 -126
- package/dist/_dts/{client-BOK-YHVJ.d.ts → client-uMMuPq9V.d.ts} +1 -1
- package/dist/_dts/{content-types-CsrYWxq_.d.ts → content-types-D6nXGqdQ.d.ts} +18 -18
- package/dist/_dts/{contracts-ClgMD-9g.d.ts → contracts-Bnmj1nxu.d.ts} +6 -5
- package/dist/_dts/{footerPageOutline-C_IDuELl.d.ts → footerPageOutline-CeLjFX8b.d.ts} +6 -6
- package/dist/_dts/{generatePageMetadata-B7bhYSWx.d.ts → generatePageMetadata-nyU8q02J.d.ts} +2 -2
- package/dist/_dts/{index-DzUdUaJ-.d.ts → index-BaaGBY1v.d.ts} +2 -2
- package/dist/_dts/{index-CcaG6O13.d.ts → index-Bg64CkV-.d.ts} +4 -4
- package/dist/_dts/index-Blwl7yl6.d.ts +13 -0
- package/dist/_dts/{index-DMOfW1A7.d.ts → index-C5xslEBn.d.ts} +2 -2
- package/dist/_dts/{index-Dt3XSGzY.d.ts → index-CEaKil7G.d.ts} +2 -2
- package/dist/_dts/{index-BZ4fb2zz.d.ts → index-DahMwisK.d.ts} +3 -3
- package/dist/_dts/index-lkpjIg5i.d.ts +66 -0
- package/dist/_dts/{index-Ci1PEk82.d.ts → index-nVoi_74l.d.ts} +2 -2
- package/dist/_dts/{loadContent-C1JI2pG0.d.ts → loadContent-CYLmzvLq.d.ts} +16 -7
- package/dist/_dts/{resolvePageContent-BtRUtrJa.d.ts → resolvePageContent-DqnxChOs.d.ts} +2 -2
- package/dist/_dts/{constants-DkcKHMX-.d.ts → runtime-BY8DQBbT.d.ts} +10 -16
- package/dist/_dts/{hosted-booking-appearance-ChGCQYdQ.d.ts → schema-D0bNcPWK.d.ts} +6907 -6762
- package/dist/_dts/sdk/src/bookings/index.d.ts +2 -2
- package/dist/_dts/sdk/src/client/types.d.ts +2 -2
- package/dist/_dts/sdk/src/client.d.ts +12 -6
- package/dist/_dts/sdk/src/config/index.d.ts +6 -6
- package/dist/_dts/sdk/src/config/template-validation.d.ts +1 -1
- package/dist/_dts/sdk/src/config/validation.d.ts +1 -1
- package/dist/_dts/sdk/src/index.d.ts +8 -8
- package/dist/_dts/sdk/src/manifest/index.d.ts +6 -6
- package/dist/_dts/sdk/src/metadata/index.d.ts +1 -1
- package/dist/_dts/sdk/src/navigation/index.d.ts +2 -2
- package/dist/_dts/sdk/src/next/index.d.ts +7 -7
- package/dist/_dts/sdk/src/next/middleware.d.ts +2 -2
- package/dist/_dts/sdk/src/page-converter/index.d.ts +10 -28
- package/dist/_dts/sdk/src/portal/client.d.ts +1 -1
- package/dist/_dts/sdk/src/prebuild/index.d.ts +1 -1
- package/dist/_dts/sdk/src/preview-next/before-render.d.ts +2 -2
- package/dist/_dts/sdk/src/preview-next/client/index.d.ts +2 -2
- package/dist/_dts/sdk/src/preview-next/client/runtime.d.ts +1 -1
- package/dist/_dts/sdk/src/rendering/client.d.ts +2 -2
- package/dist/_dts/sdk/src/rendering/index.d.ts +6 -6
- package/dist/_dts/sdk/src/rendering/islands/client.d.ts +1 -1
- package/dist/_dts/sdk/src/rendering/server.d.ts +2 -2
- package/dist/_dts/sdk/src/routing/index.d.ts +5 -5
- package/dist/_dts/sdk/src/server.d.ts +5 -5
- package/dist/_dts/sdk/src/theme/index.d.ts +1 -1
- package/dist/_dts/{types-CI9dYWJ8.d.ts → types-CFrYuXYP.d.ts} +2 -2
- package/dist/_dts/{navigation-BnV_hOZy.d.ts → types-D8czmbQF.d.ts} +15911 -17318
- package/dist/_dts/{types--oWXIfyz.d.ts → types-DSgmJ15W.d.ts} +7 -7
- package/dist/_dts/{types-CMFIZGUI.d.ts → types-Dm-KW7nj.d.ts} +10 -13
- package/dist/_dts/{validation-Ct-GL0eA.d.ts → validation-Bmb4WnHg.d.ts} +4 -4
- package/dist/client/{BlocksIslandsHydrator-DKS8Ba30.mjs → BlocksIslandsHydrator-DZRKi6tT.mjs} +17 -17
- package/dist/client/{BookingMailingListNote-Cg9v6d7Y.mjs → BookingMailingListNote-C00sLLdL.mjs} +2 -2
- package/dist/client/{CalendarNavigationChevron-BoVCTUXy.mjs → CalendarNavigationChevron-CHSi9b3E.mjs} +6 -6
- package/dist/client/{CheckboxChoice-BF9eCNno.mjs → CheckboxChoice-Bhm6RAUL.mjs} +1 -1
- package/dist/client/{DemoBookingPortalAccess-BxRVCJG3.mjs → DemoBookingPortalAccess-CaN-7ui7.mjs} +6 -6
- package/dist/client/{DemoPortalSignInLink-DHxYgkT6.mjs → DemoPortalSignInLink-ClxN5_xZ.mjs} +1 -1
- package/dist/client/{EventCalendar.client-BI-kvwXf.mjs → EventCalendar.client-BncvSa1n.mjs} +10 -9
- package/dist/client/{EventCombined.client-DIvnoN5l.mjs → EventCombined.client-DluBxVVu.mjs} +8 -8
- package/dist/client/{EventEmbeddedCheckoutStep-B3XUyNY9.mjs → EventEmbeddedCheckoutStep-BiJrMtfp.mjs} +1 -1
- package/dist/client/{EventItem-BRMtEaa6.mjs → EventItem-CXhnT9pF.mjs} +11 -6
- package/dist/client/{EventListWeekNavigation-B8DzAUDa.mjs → EventListWeekNavigation-V-dtoDlD.mjs} +1 -1
- package/dist/client/{EventListing.client-Bo4qzQi0.mjs → EventListing.client-DPO6SZbx.mjs} +3 -3
- package/dist/client/{EventListing.view-D2vemnCx.mjs → EventListing.view-B-Yi5JZS.mjs} +7 -7
- package/dist/client/{EventRegistrationPayment-e5XWtygG.mjs → EventRegistrationPayment-Dc3Fnlnw.mjs} +77 -96
- package/dist/client/{LeafletStaticMap-dlapZ6mi.mjs → LeafletStaticMap-ClZCCzAm.mjs} +1 -1
- package/dist/client/{Page-Dqpv9Ggi.mjs → Page-7PkzO04N.mjs} +1941 -2069
- package/dist/client/{StepIndicator-BrvKa_8H.mjs → StepIndicator-DiD6euZ8.mjs} +3 -3
- package/dist/client/{TabBarFragment-DvzIV75f.mjs → TabBarFragment-BHd8GN8y.mjs} +1 -1
- package/dist/client/{ThemedButton-DVBC_pS9.mjs → ThemedButton-C22C9cCF.mjs} +174 -93
- package/dist/client/{accordion-ByLpb4Dz.mjs → accordion-2m27DsIk.mjs} +1 -1
- package/dist/client/{booking-form.client-BLndwxpx.mjs → booking-form.client-BddWV5w1.mjs} +12 -12
- package/dist/client/{bookingForm-CTxTEgHX.mjs → bookingForm-bcdXQjmw.mjs} +4 -4
- package/dist/client/bookings.mjs +6 -6
- package/dist/client/{carousel-C8ef0vnT.mjs → carousel-D7nj9I0y.mjs} +2 -2
- package/dist/client/{carousel.client-BJGoJVtg.mjs → carousel.client-AffDJo_s.mjs} +1 -1
- package/dist/client/{cart-BpH6jkUO.mjs → cart-PN6yCw1H.mjs} +3 -3
- package/dist/client/{cart.client-DV78Td13.mjs → cart.client-D4t1f0cJ.mjs} +1 -1
- package/dist/client/{checkout-BJVb2RpL.mjs → checkout-CsTwXVSb.mjs} +3 -3
- package/dist/client/{checkout.client-CqGPXPSm.mjs → checkout.client-BhQE3zY7.mjs} +1 -1
- package/dist/client/client.mjs +25 -13
- package/dist/client/{context-BRgBWthI.mjs → context-BLAvalAa.mjs} +1 -1
- package/dist/client/{cta-D8ucLsvX.mjs → cta-CUXhX_D7.mjs} +2 -1
- package/dist/client/{dateFormatting-LeKNQ-iX.mjs → dateFormatting-BHIHxNuo.mjs} +1 -1
- package/dist/client/{demoPortalMagicLink-CjstiFPh.mjs → demoPortalMagicLink-R-awbk_0.mjs} +1 -1
- package/dist/client/{enhanceHeaderSection-BaQJyI9x.mjs → enhanceHeaderSection-9Q93uvTo.mjs} +3 -3
- package/dist/client/{event-details.client-CYNQYOsP.mjs → event-details.client-BS1WtG-a.mjs} +2 -2
- package/dist/client/{event-registration.client-DDqSpN36.mjs → event-registration.client-BXndwsET.mjs} +14 -14
- package/dist/client/{eventCalendar-3vQtuC9X.mjs → eventCalendar-HyoOt1Qz.mjs} +4 -4
- package/dist/client/{eventCombined-CEJFMjqV.mjs → eventCombined-sdG5oEaH.mjs} +4 -4
- package/dist/client/{eventDetails-nGh47jef.mjs → eventDetails-FFAknE4w.mjs} +2 -2
- package/dist/client/{eventListing-BL3Ptb83.mjs → eventListing-CGK6urk3.mjs} +4 -4
- package/dist/client/{eventRegistration-DDSO6KB2.mjs → eventRegistration-VhrvCs4l.mjs} +4 -4
- package/dist/client/{form-DjNLfy2Z.mjs → form-C-B5O_ko.mjs} +3 -3
- package/dist/client/{form.client-Cj0By6ot.mjs → form.client-DoZVcl8d.mjs} +5 -5
- package/dist/client/{form.parts-DyA9C5Hy.mjs → form.parts-mttKpgif.mjs} +3 -3
- package/dist/client/{formatDate-CZo0MPTA.mjs → formatDate-xUSCknEO.mjs} +1 -1
- package/dist/client/gifting/client.mjs +3 -3
- package/dist/client/{headerSection-JjSq6Mzp.mjs → headerSection-BHUEXsaI.mjs} +2 -2
- package/dist/client/{location-map.client-DRN1JePj.mjs → location-map.client-Cylb_MHw.mjs} +2 -2
- package/dist/client/{location-map.view-CuCvQdvp.mjs → location-map.view-Cx4Bl7ij.mjs} +69 -6
- package/dist/client/{locationMap-B9srHHzZ.mjs → locationMap-QnKJi-nZ.mjs} +2 -2
- package/dist/client/{newsletter-form.client-C2EgEBP1.mjs → newsletter-form.client-D_n0rftg.mjs} +8 -8
- package/dist/client/{newsletter-form.parts-CaldoFmi.mjs → newsletter-form.parts-DKHye4IE.mjs} +2 -2
- package/dist/client/{newsletterForm-hm7L17LM.mjs → newsletterForm-tEaYelzx.mjs} +3 -3
- package/dist/client/{noop-M8FTSgm2.mjs → noop-B610YKEx.mjs} +10 -3
- package/dist/client/portal/client.mjs +4559 -114
- package/dist/client/{product-detail.client-y86uwzEI.mjs → product-detail.client-DUf5x5Jt.mjs} +1 -1
- package/dist/client/{product-list.client-_JBndYZT.mjs → product-list.client-Cqp1BPTV.mjs} +1 -1
- package/dist/client/{productDetail-D-9fb2cW.mjs → productDetail-B8bBiogP.mjs} +3 -3
- package/dist/client/{productList-BSRlnwBW.mjs → productList-BKN4D-1z.mjs} +3 -3
- package/dist/client/{propsDecoder-DhbGL302.mjs → propsDecoder-2nNZh2Oe.mjs} +3 -3
- package/dist/client/{registry.server-BaX0hxf5.mjs → registry.server-BAm4RPNJ.mjs} +819 -855
- package/dist/client/rendering/client.mjs +27 -26
- package/dist/client/rendering/islands.mjs +1 -1
- package/dist/client/rendering.mjs +47 -28
- package/dist/client/{richText-coerce-Cny2Ukb6.mjs → richText-coerce-Cv-qomNB.mjs} +1 -1
- package/dist/client/{routeIslandApiConfig-96er7pIx.mjs → routeIslandApiConfig-C5u8MbAA.mjs} +1 -1
- package/dist/client/{shop-CnIJfdZA.mjs → shop-DZNC0VKk.mjs} +3 -3
- package/dist/client/{shop-commerce-CsLwzq5O.mjs → shop-commerce-DdX4LSa3.mjs} +12 -12
- package/dist/client/{shop-commerce-store--O8GRBwr.mjs → shop-commerce-store-BJtrZov9.mjs} +1 -1
- package/dist/client/{shop.client-BcaJ-acA.mjs → shop.client-DmDd-igg.mjs} +15 -15
- package/dist/client/{shop.interactive-BxL_bshW.mjs → shop.interactive-5SnnDHz3.mjs} +368 -35
- package/dist/client/{shopShared-VZjPOfCX.mjs → shopShared-CPqUlAh9.mjs} +2 -2
- package/dist/client/{src-7cXhT0G_.mjs → src-VIsPY-kw.mjs} +6 -1
- package/dist/client/timetableModel-C19rcHEw.mjs +960 -0
- package/dist/client/{useAvailableSlots-pTXuY3jV.mjs → useAvailableSlots-BjbJXotk.mjs} +3 -3
- package/dist/client/{useBookingNowIso-D14J-EhJ.mjs → useBookingNowIso-CMgfL7YJ.mjs} +1 -1
- package/dist/client/{useDiscountApply-o5sIVZ2u.mjs → useDiscountApply-KG8jB7WC.mjs} +2 -2
- package/dist/client/{useDiscountCodeUi-DJhFP_rg.mjs → useDiscountCodeUi-DK2w_i0a.mjs} +1 -1
- package/dist/client/{useEventPagination-DMmNf2FP.mjs → useEventPagination-DW6MCirb.mjs} +11 -10
- package/dist/client/uuid-BETKW8rS.mjs +12 -0
- package/dist/client/{view-BgPql2yH2.mjs → view-CkUn3Y0Y.mjs} +4 -4
- package/dist/client/{view-D1R3Lk05.mjs → view-CseyBW07.mjs} +6 -5
- package/dist/client/{wizardSteps-C0TsNqJc.mjs → wizardSteps-zgq10lN1.mjs} +162 -30
- package/dist/preview-next/before-render.mjs +1 -1
- package/dist/preview-next/client/{EventEmbeddedCheckoutStep-BFlBqSu4.mjs → EventEmbeddedCheckoutStep-lUHBrzHv.mjs} +1 -1
- package/dist/preview-next/client/{PreviewEditorSidebar-DADCj_ET.mjs → PreviewEditorSidebar-DWyUGCAG.mjs} +1281 -171
- package/dist/preview-next/client/{PreviewEditorUI-La40Dmmh.mjs → PreviewEditorUI-Wq0b3Daw.mjs} +52 -79
- package/dist/preview-next/client/{SdkPreviewModeRuntime-CWN44I_B.mjs → SdkPreviewModeRuntime-BtZPcwYV.mjs} +1 -1
- package/dist/preview-next/client/{SdkPreviewModeRuntime-406Hw9zY.mjs → SdkPreviewModeRuntime-wSI_R361.mjs} +856 -2171
- package/dist/preview-next/client/{SiteChromeCustomizeContext-BdwEZoo9.mjs → SiteChromeCustomizeContext-Hc4pYnNe.mjs} +115951 -110090
- package/dist/preview-next/client/{ThemedButton-BEOPss9H.mjs → ThemedButton-DzeycIlD.mjs} +204 -93
- package/dist/preview-next/client/{previewChromeSurface-BVUKIYG0.mjs → previewChromeSurface-Corq4AG7.mjs} +3 -8
- package/dist/preview-next/client/runtime.mjs +3 -3
- package/dist/preview-next/client/{sdk-runtime-Cy9AKPy5.mjs → sdk-runtime-CWymRWhK.mjs} +1 -1
- package/dist/preview-next/client/siteStyleAccess-QZkJRHl5.mjs +1359 -0
- package/dist/preview-next/client/{spinner-Bhpzz2vO.mjs → spinner-C4If5Y-O.mjs} +1 -1
- package/dist/preview-next/editor-base.css +62 -0
- package/dist/preview-next/editor-chrome.css +85 -0
- package/dist/preview-next/keepAlive.mjs +1 -1
- package/dist/preview-next/middleware.mjs +1 -1
- package/dist/preview-next/{route-contract-DM22uOXM.mjs → route-contract-8csADeIT.mjs} +149 -112
- package/dist/server/{Block.shared-DB6fb1pR.mjs → Block.shared-D1_gonwM.mjs} +6 -6
- package/dist/server/{bindings-z2daXp-2.mjs → bindings-CFmJg5lm.mjs} +2 -2
- package/dist/server/{client-Cv-osXoU.mjs → client-DPsi0Dai.mjs} +9 -7
- package/dist/server/config-template-validation.mjs +50 -10
- package/dist/server/config-validation.mjs +1 -1
- package/dist/server/config.mjs +2 -2
- package/dist/server/index.mjs +2 -2
- package/dist/server/{loadContent-BNMDYCm8.mjs → loadContent-RMCcuVU_.mjs} +33 -20
- package/dist/server/loadPage-DUPP51C-.mjs +2 -0
- package/dist/server/{loadPage-CjA_F_AF.mjs → loadPage-DhDGzj7t.mjs} +8 -5
- package/dist/server/manifest.mjs +1 -1
- package/dist/server/next.mjs +9 -9
- package/dist/server/{overrideResolution-CGodrtqi.mjs → overrideResolution-OxY5FMuy.mjs} +1 -1
- package/dist/server/{overrides-DxRC724a.mjs → overrides-Bz_A6sB9.mjs} +651 -542
- package/dist/server/page-converter.mjs +8 -10
- package/dist/server/{prebuild-C6bhjRKT.mjs → prebuild-B_1vrSru.mjs} +1 -1
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/{prefetchBlockData-DZ5Fq_-r.mjs → prefetchBlockData-B7ukYXXR.mjs} +841 -887
- package/dist/server/{publicProducts-C3meXS2o.mjs → publicProducts-Djbpc81A.mjs} +166 -129
- package/dist/server/{blocks-BaG8Qpaa.mjs → registry-eFjKtEhF.mjs} +2049 -1451
- package/dist/server/rendering/server.mjs +4 -4
- package/dist/server/rendering.mjs +7 -7
- package/dist/server/{resolveBlockData-CbGDakvp.mjs → resolveBlockData-DYvEa9c5.mjs} +6 -3
- package/dist/server/routing.mjs +1 -1
- package/dist/server/{schema-Bs735S27.mjs → schema-C3dJ5UkL.mjs} +148 -88
- package/dist/server/server.mjs +3 -3
- package/dist/server/{siteChromeOverlayClearance-BangtD8A.mjs → siteChromeOverlayClearance-DALIAMwo.mjs} +108 -11
- package/dist/server/{src-B935_bzN.mjs → src-C5Mu-z0F.mjs} +268 -189
- package/dist/server/theme-bridge.mjs +1 -1
- package/dist/server/theme.mjs +1 -1
- package/dist/server/{themeAdmission-DK2YBNqy.mjs → themeAdmission-ruoyXb_0.mjs} +2 -2
- package/dist/server/{three-pass-converter-CmmchOFC.mjs → three-pass-converter-Chnb1XD-.mjs} +2 -58
- package/dist/server/{validation-BtHE2S_D.mjs → validation-B-Xar8QS.mjs} +22 -63
- package/dist/server/{version-CNCdL6id.mjs → version-Bg7VHK3i.mjs} +1 -1
- package/dist/styles/index.css +78 -0
- package/package.json +8 -3
- package/dist/_dts/index-CXsnaCGe.d.ts +0 -10
- package/dist/_dts/index-cnymEAZY.d.ts +0 -1
- package/dist/client/timetableModel-D09jPdue.mjs +0 -480
- package/dist/preview-next/client/siteStyleAccess-CFMmoMZb.mjs +0 -1326
- package/dist/server/loadPage-jade28Xh.mjs +0 -2
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { D as ok, E as err, s as runtimeMediaSchema, u as renderableMediaAssetSchema } from "./media-CcHwZkdJ.mjs";
|
|
2
2
|
import { t as assertNever$1 } from "./assert-never-ku-PUn9U.mjs";
|
|
3
|
-
import { $
|
|
4
|
-
import { g as validateManifestDraft, h as compileManifestContentContract, u as readSdkPreviewPublishedPlacement } from "./themeAdmission-
|
|
5
|
-
import { C as resolvePageRouteTarget, D as parseStoredVariant, E as
|
|
6
|
-
import { E as ICON_CONFIG, En as defaultThemeTokens, Jn as parseThemeColorToken, Jt as testimonialsCompositionTreatmentValues, Ln as getTextColorForBackground, N as generateDefaultButtonSystem, P as parseThemeButtonVariantId, R as parseThemeForPersistence, Rt as featureCardCompositionTreatmentValues, Vt as introCompositionTreatmentValues, Wt as offeringsPreviewCompositionTreatmentValues, cn as rgbColorValue, gn as resolveOnColorForThemeToken, hn as isCssColorLiteral, in as backgroundColorStyle, ln as textColorStyle, sn as mergeStyles, vn as resolveTokenOrCssColorValue } from "./schema-
|
|
7
|
-
import { A as arrangementLookHooks } from "./siteChromeOverlayClearance-
|
|
3
|
+
import { $ as ImagePresets, $n as createInteractiveIslandCodec, $r as parseBlockIconValue, $t as formatEventHourLabel, A as buildOfferingsCatalogueListing, Aa as isPublicEventPricingOptionDisplayable, An as FEATURE_CARD_ICON_TREATMENTS, At as resolveOfferingsPreviewGroupCta, B as eventCollectionDisplaySchemaShape, Bn as resolveDateRuntimeContext, Br as el, Bt as buildEventListWeek, C as buildShopInteractiveIslandProps, Ca as parseBookingLocalDate, Cn as isEventFull, Cr as ctaCopyFragment, D as passCardListContent, Da as toScheduledBookingDateTime, Dn as blockBookingConsentSchema, Dr as heroCopyFragment, Dt as buildOfferingsPreviewListing, E as membershipClassesLabel, Ea as toBookingTimeZone, En as publicEventsArraySchema, Er as isBlockButtonRole, Et as OFFERINGS_PREVIEW_EVENT_PRESET_DEFINITIONS, F as eventListingBlockDefinition, Fa as resolvePricingOptionsPriceDisplay, Fn as composeHeaderSectionWrapperClassName, Ft as ThemedButton, G as catalogueEventCardProps, Gn as staticHeaderChromeRuntime, H as eventCollectionSourceSchemaShape, Hi as arrangementManifestFromVariants, Ht as formatEventPriceAmount, I as buildEventListingInteractiveIslandProps, Ia as formatCurrencyAmount, In as markEditableSurfaceForwarding, It as ThemedButtonLink, J as CardListLeadDate, Jt as formatCalendarTitle, K as listingEventCardProps, Kt as eventDateOptions, L as buildEventCollectionDisplay, La as parseCurrencyCode, Ln as splitPositioningClasses, Lt as ThemedDownloadLink, M as buildEventCalendarInteractiveIslandProps, Ma as publicEventPricingDisplay, Mi as PUBLIC_DOWNLOAD_MEDIA_TYPES, Mn as shouldReserveFeatureCardIconZone, Mr as normalizeBoxStylesBorder, Mt as resolveOfferingsPreviewRunPath, N as buildEventCalendarListingDisplay, Na as publicEventPricingType, Nr as resolveCardRoleForBoxStyles, Nt as resolveOfferingsRenderInput, O as offeringsPreviewBlockDefinition, Oa as toUtcIsoDateTimeString, On as bookingConsentCarrierSchema, Or as bodyCopyFragment, Ot as normalizeOfferingsPreviewItemLimit, Pa as resolveExactOrFreePriceDisplay, Pt as ThemedAuthoredButton, Q as RichText, Qn as buildInteractiveIslandProps, Qr as buildGeneratedBlockIconRenderAssetLookupFromUnknown, Qt as formatEventDateParts, R as buildEventCollectionHydration, Rr as resolveBackgroundColorValue, Rt as getIconComponent, S as buildProductListInteractiveIslandProps, Sa as getLocalScheduleDate, Sn as getEventAvailabilityStatus, Sr as testimonialsHeadingFragment, St as resolveEventRegistrationScopedEvents, T as membershipCardListContent, Ta as resolveBookingBusinessTimeZone, Tn as groupPublicEventsByRun, Tr as ctaRowFragment, Ut as formatEventPriceDisplay, V as eventCollectionHydrationSchema, Vr as when, Vt as formatEventPrice, Wi as resolveEffectiveArrangement, Wt as buildCalendarViewport, X as selectCardListPresentation, Xn as formBlockDefinition, Xt as formatEventClockLabel, Y as resolveCardListSchedule, Yt as formatDate, Z as MediaNodeServer, Zn as buildFormInteractiveIslandProps, Zr as runTransforms, Zt as formatEventCompactDateRail, _ as productListBlockDefinition, _a as formatDateTimeRange, _n as browserReadAuthoritySchema, _r as blogFeaturedPostFragment, a as normalizeLocationMapProps, aa as unavailableReadinessFact, ai as ClockIcon, an as getLocalDateKey, ar as listLookControl, at as resolvePublicMediaUrl, b as buildCheckoutInteractiveIslandProps, ba as formatBookingCompactEnglishTime, bn as formatTotalCapacity, br as formCopyFragment, ca as orderedLiveRunSessions, ci as FileSpreadsheetIcon, cn as formatDateKey, cr as itemRole, ct as setContextResolveImageUrlContext, d as newsletterBlockSubmissionMessage, da as parseMailingListRuntimeContext, di as PlusIcon, dn as getWeekCalendarDayTuple, dr as clsx, dt as getContainerClass, ei as resolveBlockIconRenderValue, en as formatEventNextDateFact, er as defineInteractiveIslandMetaKeys, et as MediaPlaceholder, f as giftingBlockDefinition, fi as inlineTextToPlainText, fn as getWeekCalendarDays, fr as richTextFragment, g as productDetailBlockDefinition, ga as formatDateRange, gn as formatBookingSchedulePresentation, gr as faqHeadingFragment, gt as previewStageSchema, h as cartBlockDefinition, ha as formatDate$1, hn as resolveRuntimeEventDestination, hr as faqAccordionFragment, ht as bookingNowSchema, i as buildGoogleMapsDirectionsUrl, ia as pageTemplateFromEntry, ii as CirclePlusIcon, in as resolveEventTimeZone, ir as listItemPresentation, j as eventCalendarBlockDefinition, ja as publicEventPricingCurrency, jn as resolveFeatureCardGeneratedIconSizePx, jr as boxStyleClassNames, jt as resolveOfferingsPreviewGroups, k as publicRouteCandidatesSchema, ka as formatBookingPriceDisplay, ki as bindingSchema, kn as blockBookingPaymentTermsSchema, kr as defineFragment, kt as offeringsListingFor, l as NEWSLETTER_SIGNUPS_PAUSED_MESSAGE, la as resolveWholeSeriesBookingPhase, li as FileTextIcon, ln as getDayOfWeek, lt as sanitizeHref, m as checkoutBlockDefinition, ma as sameMailingListPlacementTargeting, mi as parseInlineTextFromUnknown, mn as isToday, mr as cardFragment, mt as buildEventRegistrationInteractiveIslandProps, na as admitReadinessFacts, ni as ChevronDownIcon, nn as formatTime, nr as defineClientOwnedBlockRuntime, o as toLocationMapHydrationProps, oa as CANCELLED_SESSION_STATUS, oi as FileArchiveIcon, on as getLocalMinuteOfDay, or as listLookSlot, ot as buildResolveImageUrlContext, p as buildGiftingInteractiveIslandProps, pa as parseMailingListPlacementTargeting, pi as isInlineTextEmpty, pn as isSameCalendarDay, pr as headingFragment, pt as eventRegistrationBlockDefinition, q as CardListContentPart, qt as eventLocalDateKey, r as normalizeBlockContent, ra as loadedReadinessFact, ri as CircleMinusIcon, rn as groupEventsByDate, rr as defineProgressiveBlockRuntime, s as newsletterSignupBlockDefinition, sa as nextLiveRunSessionStartMs, si as FileAudioIcon, sn as addDays, sr as resolvedItemSurfaceProps, st as getCurrentResolveImageUrlContext, t as getBlockDefinition, ta as chosenString, ti as ArrowDownIcon, tn as formatEventTimeRange, tr as createZodCodec, u as buildNewsletterFormInteractiveIslandProps, ua as buildMailingListSignupBlockSourceRef, ui as MinusIcon, un as getOrderedDayNames, ur as Grid, ut as getCardOrientation, v as shopBlockDefinition, vn as canJoinEventWaitlistOnAnyMode, vr as singleButtonFragment, w as shopProductPresentation, wa as parseLocalScheduleTime, wi as parseFieldDefinitions, wn as blockSiteTermsSchema, wr as heroCtaRowFragment, x as buildProductDetailInteractiveIslandProps, xa as getBookingLocalDateKey, xn as getEventAvailability, xr as testimonialsCarouselFragment, xt as normalizeEventRegistrationPageSurfaceSubject, y as buildCartInteractiveIslandProps, ya as compareLocalScheduleDates, yn as formatEventRemainingPlaces, yr as formEmbedFragment, z as buildEventCollectionListingDisplay, zn as readRuntimeNow, zr as ctaButton, zt as SpinnerNode } from "./registry-eFjKtEhF.mjs";
|
|
4
|
+
import { g as validateManifestDraft, h as compileManifestContentContract, u as readSdkPreviewPublishedPlacement } from "./themeAdmission-ruoyXb_0.mjs";
|
|
5
|
+
import { C as resolvePageRouteTarget, D as parseStoredVariant, E as toPresentationPage, S as resolveEntryRouteTarget, T as toEditorPresentationPage, _ as buildLinkedContentEditTarget, b as defaultTransforms, f as buildPageRenderPlan, g as retargetJoinsAcrossOmissions, h as renderedJoinLayout, m as joinSlotKey, p as composePageJoins, v as resolveLinkedEntryInlineFieldEligibility, w as resolveRouteTarget } from "./prefetchBlockData-B7ukYXXR.mjs";
|
|
6
|
+
import { E as ICON_CONFIG, En as defaultThemeTokens, Jn as parseThemeColorToken, Jt as testimonialsCompositionTreatmentValues, Ln as getTextColorForBackground, N as generateDefaultButtonSystem, P as parseThemeButtonVariantId, R as parseThemeForPersistence, Rt as featureCardCompositionTreatmentValues, Vt as introCompositionTreatmentValues, Wt as offeringsPreviewCompositionTreatmentValues, cn as rgbColorValue, gn as resolveOnColorForThemeToken, hn as isCssColorLiteral, in as backgroundColorStyle, ln as textColorStyle, sn as mergeStyles, vn as resolveTokenOrCssColorValue } from "./schema-C3dJ5UkL.mjs";
|
|
7
|
+
import { A as arrangementLookHooks } from "./siteChromeOverlayClearance-DALIAMwo.mjs";
|
|
8
8
|
import { a as isRecord$4, i as isObjectRecord, t as RichTextDocSchema } from "./richTextSchema-YYc85FX4.mjs";
|
|
9
|
-
import { a as buildThemeRuntime$1, n as ResponsiveScope, o as mergeContentWithBlockStyleOverrides, r as ThemeScope$1, s as generateDefaultAccordionSystem } from "./src-
|
|
9
|
+
import { a as buildThemeRuntime$1, n as ResponsiveScope, o as mergeContentWithBlockStyleOverrides, r as ThemeScope$1, s as generateDefaultAccordionSystem } from "./src-C5Mu-z0F.mjs";
|
|
10
10
|
import { t as getAtPath } from "./src-Cxucn-1P.mjs";
|
|
11
11
|
import { z } from "zod";
|
|
12
12
|
import * as React$1 from "react";
|
|
@@ -1171,6 +1171,7 @@ const eventItemParts = {
|
|
|
1171
1171
|
"action"
|
|
1172
1172
|
],
|
|
1173
1173
|
grid: [
|
|
1174
|
+
"image",
|
|
1174
1175
|
"date",
|
|
1175
1176
|
"title",
|
|
1176
1177
|
"meta",
|
|
@@ -1197,7 +1198,11 @@ function eventItemFacts(props) {
|
|
|
1197
1198
|
date: formatEventCompactDateRail(props.event.startsAt, options, "as-written"),
|
|
1198
1199
|
time: formatEventTimeRange(props.event, options),
|
|
1199
1200
|
price: formatEventPrice(props.event),
|
|
1200
|
-
meta:
|
|
1201
|
+
meta: [
|
|
1202
|
+
...(props.parts ?? eventItemParts[props.arrangement]).includes("time") ? [] : [formatEventTimeRange(props.event, options)],
|
|
1203
|
+
formatEventTeacherLine(props.event),
|
|
1204
|
+
props.showVenue !== false ? props.event.venue?.name : null
|
|
1205
|
+
].filter(Boolean).join(" · "),
|
|
1201
1206
|
places: props.showCapacity ? formatEventRemainingPlaces(props.event, { full: "Sold out" }) : null,
|
|
1202
1207
|
availability: availability.isFull ? "full" : availability.status === "filling" ? "low" : "available",
|
|
1203
1208
|
description: props.event.presentation?.summary ?? props.event.description
|
|
@@ -1213,7 +1218,7 @@ function EventItem(props) {
|
|
|
1213
1218
|
return "item" in props ? renderCardItem(props) : renderCalendarItem(props);
|
|
1214
1219
|
}
|
|
1215
1220
|
function renderCalendarItem(props) {
|
|
1216
|
-
const parts = props.parts ?? eventItemParts[props.arrangement];
|
|
1221
|
+
const parts = (props.parts ?? eventItemParts[props.arrangement]).filter((part) => part !== "image" || props.showPhotos !== false);
|
|
1217
1222
|
const facts = eventItemFacts(props);
|
|
1218
1223
|
const Tag = props.as ?? eventItemTag(props.arrangement);
|
|
1219
1224
|
const root = props.arrangement === "grid" ? "item" : props.continued ? "row-continued" : "row";
|
|
@@ -1907,7 +1912,7 @@ const EventCompactRow = (props) => props.lookSlots === void 0 ? /* @__PURE__ */
|
|
|
1907
1912
|
buttonText: props.buttonText ?? "Book",
|
|
1908
1913
|
as: "article"
|
|
1909
1914
|
});
|
|
1910
|
-
const LegacyEventCompactRow = ({ event, buttonVariant = "primary", buttonText }) => {
|
|
1915
|
+
const LegacyEventCompactRow = ({ event, buttonVariant = "primary", buttonText, showVenue = true }) => {
|
|
1911
1916
|
event.timeZone;
|
|
1912
1917
|
const dateRail = formatEventCompactDateRail(event.startsAt, eventDateOptions(event));
|
|
1913
1918
|
const formattedTime = formatEventTimeRange(event, eventDateOptions(event));
|
|
@@ -1948,7 +1953,7 @@ const LegacyEventCompactRow = ({ event, buttonVariant = "primary", buttonText })
|
|
|
1948
1953
|
}), /* @__PURE__ */ jsxs("div", {
|
|
1949
1954
|
className: "event-compact-row-meta",
|
|
1950
1955
|
children: [
|
|
1951
|
-
event.venue && /* @__PURE__ */ jsxs("span", {
|
|
1956
|
+
showVenue && event.venue && /* @__PURE__ */ jsxs("span", {
|
|
1952
1957
|
className: "event-compact-row-venue",
|
|
1953
1958
|
children: [/* @__PURE__ */ jsx(MapPinIcon, { className: "rb-shrink-0" }), event.venue.name]
|
|
1954
1959
|
}),
|
|
@@ -2151,43 +2156,64 @@ function OfferingTitle({ className, path, title }) {
|
|
|
2151
2156
|
});
|
|
2152
2157
|
}
|
|
2153
2158
|
//#endregion
|
|
2154
|
-
//#region ../blocks/src/system/
|
|
2155
|
-
const
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
};
|
|
2161
|
-
|
|
2162
|
-
|
|
2163
|
-
|
|
2164
|
-
|
|
2165
|
-
|
|
2166
|
-
|
|
2167
|
-
|
|
2168
|
-
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
return
|
|
2172
|
-
|
|
2173
|
-
|
|
2174
|
-
};
|
|
2159
|
+
//#region ../blocks/src/system/data/readinessFacts.ts
|
|
2160
|
+
const countSchema = z.array(z.unknown()).transform((entries) => entries.length);
|
|
2161
|
+
const formSchema = z.union([z.null(), z.object({
|
|
2162
|
+
id: z.string(),
|
|
2163
|
+
slug: z.string().optional()
|
|
2164
|
+
})]).transform((form) => form !== null);
|
|
2165
|
+
const productsSchema = z.object({ products: z.array(z.object({ slug: z.string() })) });
|
|
2166
|
+
/** Both producers pass raw facts through the same stage admission. */
|
|
2167
|
+
function readinessFactsFromLoaders(stage, input) {
|
|
2168
|
+
const facts = {
|
|
2169
|
+
mailingList: loaderFactProducers.mailingList(input),
|
|
2170
|
+
testimonials: loaderFactProducers.testimonials(input),
|
|
2171
|
+
team: loaderFactProducers.team(input),
|
|
2172
|
+
forms: loaderFactProducers.forms(input),
|
|
2173
|
+
products: loaderFactProducers.products(input),
|
|
2174
|
+
template: loaderFactProducers.template(input)
|
|
2175
|
+
};
|
|
2176
|
+
return admitReadinessFacts(stage, {
|
|
2177
|
+
stage: input.prefetched?.loaderSnapshot?.stage ?? (input.previewStage === "preview" ? "draft" : "published"),
|
|
2178
|
+
facts
|
|
2179
|
+
});
|
|
2175
2180
|
}
|
|
2176
|
-
|
|
2177
|
-
|
|
2178
|
-
|
|
2179
|
-
|
|
2181
|
+
const loaderFactProducers = {
|
|
2182
|
+
mailingList: (input) => input.mailingList === void 0 ? unavailableReadinessFact : loadedReadinessFact(input.mailingList),
|
|
2183
|
+
testimonials: (input) => mapFact(firstLoaderFact(input, "testimonials", "entries", countSchema), (count) => ({
|
|
2184
|
+
count,
|
|
2185
|
+
total: "unknown"
|
|
2186
|
+
})),
|
|
2187
|
+
team: (input) => firstLoaderFact(input, "team", "members", countSchema),
|
|
2188
|
+
forms: (input) => new Map(projections(input, "forms").flatMap(({ id, block }) => {
|
|
2189
|
+
const selection = chosenString(block.requests.form?.params.formSlug ?? block.requests.form?.params.formId);
|
|
2190
|
+
return selection ? [[selection, loaderFact(input, id, "form", formSchema)]] : [];
|
|
2191
|
+
})),
|
|
2192
|
+
products: (input) => new Map(projections(input, "products").flatMap(({ id, block }) => {
|
|
2193
|
+
const selection = chosenString(block.content.productSlug);
|
|
2194
|
+
return selection ? [[selection, mapFact(loaderFact(input, id, "products", productsSchema), ({ products }) => products.some((product) => product.slug === selection))]] : [];
|
|
2195
|
+
})),
|
|
2196
|
+
template: (input) => loadedReadinessFact(input.template)
|
|
2197
|
+
};
|
|
2198
|
+
function projections(input, need) {
|
|
2199
|
+
return Object.entries(input.prefetched?.loaderSnapshot?.blocks ?? {}).flatMap(([id, block]) => getBlockDefinition(block.kind)?.readiness?.needs.includes(need) ? [{
|
|
2200
|
+
id,
|
|
2201
|
+
block
|
|
2202
|
+
}] : []);
|
|
2180
2203
|
}
|
|
2181
|
-
function
|
|
2182
|
-
|
|
2204
|
+
function firstLoaderFact(input, need, key, schema) {
|
|
2205
|
+
const source = projections(input, need)[0];
|
|
2206
|
+
return source ? loaderFact(input, source.id, key, schema) : unavailableReadinessFact;
|
|
2183
2207
|
}
|
|
2184
|
-
function
|
|
2185
|
-
const
|
|
2186
|
-
if (
|
|
2187
|
-
|
|
2208
|
+
function loaderFact(input, id, key, schema) {
|
|
2209
|
+
const prefetched = input.prefetched;
|
|
2210
|
+
if (!prefetched) return unavailableReadinessFact;
|
|
2211
|
+
if (!prefetched.loaderSnapshot.blocks[id]?.requests[key] || prefetched.loaderFailures[id]?.[key]) return unavailableReadinessFact;
|
|
2212
|
+
const parsed = schema.safeParse(prefetched.resolvedData[id]?.[key]);
|
|
2213
|
+
return parsed.success ? loadedReadinessFact(parsed.data) : unavailableReadinessFact;
|
|
2188
2214
|
}
|
|
2189
|
-
function
|
|
2190
|
-
return
|
|
2215
|
+
function mapFact(fact, project) {
|
|
2216
|
+
return fact.kind === "Loaded" ? loadedReadinessFact(project(fact.value)) : fact;
|
|
2191
2217
|
}
|
|
2192
2218
|
//#endregion
|
|
2193
2219
|
//#region ../blocks/src/system/runtime/nodes/carousel.shared.ts
|
|
@@ -2417,11 +2443,32 @@ function truncate(input, maxLength) {
|
|
|
2417
2443
|
if (input.length <= maxLength) return input;
|
|
2418
2444
|
return input.slice(0, maxLength) + "…";
|
|
2419
2445
|
}
|
|
2446
|
+
const PRIVATE_LOG_KEYS = /* @__PURE__ */ new Set([
|
|
2447
|
+
"requestbodyvalues",
|
|
2448
|
+
"provideroptions",
|
|
2449
|
+
"byok",
|
|
2450
|
+
"apikey"
|
|
2451
|
+
]);
|
|
2452
|
+
function logJsonValue(key, value, seen) {
|
|
2453
|
+
if (PRIVATE_LOG_KEYS.has(key.toLowerCase())) return void 0;
|
|
2454
|
+
if (typeof value === "bigint") return String(value);
|
|
2455
|
+
if (value === null || typeof value !== "object") return value;
|
|
2456
|
+
if (seen.has(value)) return "[circular]";
|
|
2457
|
+
seen.add(value);
|
|
2458
|
+
return value instanceof Error ? {
|
|
2459
|
+
...value,
|
|
2460
|
+
name: value.name,
|
|
2461
|
+
message: value.message,
|
|
2462
|
+
stack: value.stack,
|
|
2463
|
+
cause: "cause" in value ? value.cause : void 0
|
|
2464
|
+
} : value;
|
|
2465
|
+
}
|
|
2420
2466
|
function safeStringify(value, maxLength) {
|
|
2421
2467
|
try {
|
|
2422
|
-
|
|
2468
|
+
const seen = /* @__PURE__ */ new WeakSet();
|
|
2469
|
+
return truncate(JSON.stringify(value, (key, nested) => logJsonValue(key, nested, seen)), maxLength);
|
|
2423
2470
|
} catch {
|
|
2424
|
-
return
|
|
2471
|
+
return "[unserializable]";
|
|
2425
2472
|
}
|
|
2426
2473
|
}
|
|
2427
2474
|
function toScalar(value, maxLength) {
|
|
@@ -2437,7 +2484,7 @@ function sanitizeV2(fields, maxStringLength) {
|
|
|
2437
2484
|
const allowed = {};
|
|
2438
2485
|
const extra = {};
|
|
2439
2486
|
for (const [key, value] of Object.entries(fields)) {
|
|
2440
|
-
if (value === void 0) continue;
|
|
2487
|
+
if (value === void 0 || PRIVATE_LOG_KEYS.has(key.toLowerCase())) continue;
|
|
2441
2488
|
if (STRUCTURED_KEYS.has(key)) {
|
|
2442
2489
|
allowed[key] = toScalar(value, maxStringLength);
|
|
2443
2490
|
continue;
|
|
@@ -3928,7 +3975,7 @@ function teamMemberCardContent(member, index, biographySource) {
|
|
|
3928
3975
|
}
|
|
3929
3976
|
function TeamMembersNode(props) {
|
|
3930
3977
|
const parsed = z.array(teamMemberCardSchema).safeParse(props.source === "site_staff" ? props.siteMembers : props.members);
|
|
3931
|
-
if (!parsed.success
|
|
3978
|
+
if (!parsed.success) return null;
|
|
3932
3979
|
return /* @__PURE__ */ jsx(CardListItems, {
|
|
3933
3980
|
Carousel: props.Carousel,
|
|
3934
3981
|
items: parsed.data.map((member, index) => teamMemberCardContent(member, index, props.biographySource)),
|
|
@@ -3956,12 +4003,12 @@ function toTrimmedString(value) {
|
|
|
3956
4003
|
return trimmed ? trimmed : void 0;
|
|
3957
4004
|
}
|
|
3958
4005
|
function normalizeBookingFormConfig(form) {
|
|
3959
|
-
if (!isRecord$
|
|
4006
|
+
if (!isRecord$3(form)) return null;
|
|
3960
4007
|
const id = readNonEmptyString(form.id);
|
|
3961
4008
|
const name = readNonEmptyString(form.name);
|
|
3962
4009
|
if (!id || !name) return null;
|
|
3963
|
-
const schemaSource = isRecord$
|
|
3964
|
-
const settingsSource = isRecord$
|
|
4010
|
+
const schemaSource = isRecord$3(form.schema) ? form.schema : isRecord$3(form.schemaJson) ? form.schemaJson : null;
|
|
4011
|
+
const settingsSource = isRecord$3(form.settings) ? form.settings : isRecord$3(form.settingsJson) ? form.settingsJson : null;
|
|
3965
4012
|
return {
|
|
3966
4013
|
id,
|
|
3967
4014
|
name,
|
|
@@ -3981,8 +4028,8 @@ function normalizeBookingServices(services) {
|
|
|
3981
4028
|
};
|
|
3982
4029
|
if (!services) return [];
|
|
3983
4030
|
if (Array.isArray(services)) return services.filter(isBookingFormService).map(normalizeService);
|
|
3984
|
-
if (isRecord$
|
|
3985
|
-
return isRecord$
|
|
4031
|
+
if (isRecord$3(services) && "services" in services) return Array.isArray(services.services) ? services.services.filter(isBookingFormService).map(normalizeService) : [];
|
|
4032
|
+
return isRecord$3(services) ? Object.values(services).filter(isBookingFormService).map(normalizeService) : [];
|
|
3986
4033
|
}
|
|
3987
4034
|
function normalizeBookingSchema(value) {
|
|
3988
4035
|
if (!value) return void 0;
|
|
@@ -3993,7 +4040,7 @@ function normalizeBookingSchema(value) {
|
|
|
3993
4040
|
};
|
|
3994
4041
|
}
|
|
3995
4042
|
function readBookingFormField(value) {
|
|
3996
|
-
if (!isRecord$
|
|
4043
|
+
if (!isRecord$3(value)) return null;
|
|
3997
4044
|
const id = readNonEmptyString(value.id);
|
|
3998
4045
|
const label = readNonEmptyString(value.label);
|
|
3999
4046
|
const type = readBookingFieldType(value.type);
|
|
@@ -4036,7 +4083,7 @@ function readBookingFieldOptions(value) {
|
|
|
4036
4083
|
return options.length > 0 ? options : void 0;
|
|
4037
4084
|
}
|
|
4038
4085
|
function readBookingFieldOption(value) {
|
|
4039
|
-
if (!isRecord$
|
|
4086
|
+
if (!isRecord$3(value)) return null;
|
|
4040
4087
|
const optionValue = readNonEmptyString(value.value);
|
|
4041
4088
|
const label = readNonEmptyString(value.label);
|
|
4042
4089
|
return optionValue && label ? {
|
|
@@ -4056,7 +4103,7 @@ function normalizeBookingSettings(value) {
|
|
|
4056
4103
|
};
|
|
4057
4104
|
}
|
|
4058
4105
|
function isBookingFormService(value) {
|
|
4059
|
-
return isRecord$
|
|
4106
|
+
return isRecord$3(value) && typeof value.id === "string" && typeof value.siteId === "string" && typeof value.title === "string" && (value.asksSiteTerms === void 0 || typeof value.asksSiteTerms === "boolean") && (value.consent === void 0 || blockBookingConsentSchema.safeParse(value.consent).success);
|
|
4060
4107
|
}
|
|
4061
4108
|
function readNonEmptyString(value) {
|
|
4062
4109
|
if (typeof value !== "string") return null;
|
|
@@ -4074,16 +4121,16 @@ function readStringArray(value) {
|
|
|
4074
4121
|
const strings = value.filter((item) => typeof item === "string");
|
|
4075
4122
|
return strings.length > 0 ? strings : void 0;
|
|
4076
4123
|
}
|
|
4077
|
-
function isRecord$
|
|
4124
|
+
function isRecord$3(value) {
|
|
4078
4125
|
return typeof value === "object" && value !== null;
|
|
4079
4126
|
}
|
|
4080
4127
|
//#endregion
|
|
4081
4128
|
//#region ../blocks/src/system/runtime/nodes/booking-form.service-categories.ts
|
|
4082
|
-
function isRecord$
|
|
4129
|
+
function isRecord$2(value) {
|
|
4083
4130
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
4084
4131
|
}
|
|
4085
4132
|
function readCategory(value) {
|
|
4086
|
-
if (!isRecord$
|
|
4133
|
+
if (!isRecord$2(value)) return [];
|
|
4087
4134
|
const { id, name, description } = value;
|
|
4088
4135
|
if (typeof id !== "string" || id.trim() === "" || typeof name !== "string") return [];
|
|
4089
4136
|
return [{
|
|
@@ -4099,7 +4146,7 @@ function readCategory(value) {
|
|
|
4099
4146
|
* it.
|
|
4100
4147
|
*/
|
|
4101
4148
|
function normalizeBookingServiceCategories(services) {
|
|
4102
|
-
if (!isRecord$
|
|
4149
|
+
if (!isRecord$2(services) || !Array.isArray(services.categories)) return [];
|
|
4103
4150
|
return services.categories.flatMap(readCategory);
|
|
4104
4151
|
}
|
|
4105
4152
|
//#endregion
|
|
@@ -5649,6 +5696,7 @@ function renderEventListItem(event, source) {
|
|
|
5649
5696
|
lookSlots: display.lookSlots,
|
|
5650
5697
|
itemSurfaces: display.itemSurfaces,
|
|
5651
5698
|
showCapacity: display.showCapacity,
|
|
5699
|
+
showVenue: display.showVenue,
|
|
5652
5700
|
buttonVariant: display.buttonVariant,
|
|
5653
5701
|
buttonText: display.buttonText
|
|
5654
5702
|
}, event.occurrenceId || event.id);
|
|
@@ -6694,7 +6742,8 @@ function RecurringSchedule({ dateContext = resolveDateRuntimeContext(void 0), sc
|
|
|
6694
6742
|
function RecurringScheduleRow({ item, locale, buttonText, buttonVariant, showVenue }) {
|
|
6695
6743
|
const startLabel = formatEventClockLabel(item.cadence.startTime, locale);
|
|
6696
6744
|
const endLabel = formatEventClockLabel(item.cadence.endTime, locale);
|
|
6697
|
-
const
|
|
6745
|
+
const weekdays = item.cadence.weekdays?.join(", ") ?? item.cadence.weekday;
|
|
6746
|
+
const description = `${item.title}, ${weekdays} at ${startLabel}`;
|
|
6698
6747
|
return /* @__PURE__ */ jsxs("article", {
|
|
6699
6748
|
className: "recurring-schedule-row",
|
|
6700
6749
|
role: "listitem",
|
|
@@ -6702,7 +6751,7 @@ function RecurringScheduleRow({ item, locale, buttonText, buttonVariant, showVen
|
|
|
6702
6751
|
children: [
|
|
6703
6752
|
/* @__PURE__ */ jsx("p", {
|
|
6704
6753
|
className: "recurring-schedule-day",
|
|
6705
|
-
children:
|
|
6754
|
+
children: weekdays
|
|
6706
6755
|
}),
|
|
6707
6756
|
/* @__PURE__ */ jsxs("p", {
|
|
6708
6757
|
className: "recurring-schedule-time",
|
|
@@ -7378,6 +7427,27 @@ function GiftingSSR({ blockId, ...rest }) {
|
|
|
7378
7427
|
});
|
|
7379
7428
|
}
|
|
7380
7429
|
//#endregion
|
|
7430
|
+
//#region ../blocks/src/system/runtime/nodes/events/shared/CalendarRecurringWeek.tsx
|
|
7431
|
+
/** Week mode keeps the series projection and booking destinations from issue 1586. */
|
|
7432
|
+
function CalendarRecurringWeek({ display }) {
|
|
7433
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
7434
|
+
className: "event-calendar event-calendar--recurring-week",
|
|
7435
|
+
children: [display.seeAllUrl ? /* @__PURE__ */ jsx(ThemedButtonLink, {
|
|
7436
|
+
href: display.seeAllUrl,
|
|
7437
|
+
variant: display.seeAllButtonVariant,
|
|
7438
|
+
size: "md",
|
|
7439
|
+
label: display.loadMoreText ?? "See all classes"
|
|
7440
|
+
}) : null, /* @__PURE__ */ jsx(RecurringSchedule, {
|
|
7441
|
+
schedule: display.schedule,
|
|
7442
|
+
dateContext: display.dateContext,
|
|
7443
|
+
buttonText: display.buttonText,
|
|
7444
|
+
buttonVariant: display.buttonVariant,
|
|
7445
|
+
showVenue: display.showVenue,
|
|
7446
|
+
emptyMessage: display.emptyMessage
|
|
7447
|
+
})]
|
|
7448
|
+
});
|
|
7449
|
+
}
|
|
7450
|
+
//#endregion
|
|
7381
7451
|
//#region ../blocks/src/system/runtime/nodes/events/shared/EventListWeekNavigation.tsx
|
|
7382
7452
|
function EventListWeekNavigation(props) {
|
|
7383
7453
|
return /* @__PURE__ */ jsxs("nav", {
|
|
@@ -8580,32 +8650,22 @@ function hourToTickPercent(hour, hours) {
|
|
|
8580
8650
|
const range = Math.max(1, endHour - startHour);
|
|
8581
8651
|
return (hour - startHour) / range * 100;
|
|
8582
8652
|
}
|
|
8583
|
-
|
|
8584
|
-
const islandProps = buildEventCalendarInteractiveIslandProps(props);
|
|
8585
|
-
const display = islandProps.render.display;
|
|
8586
|
-
const hydration = islandProps.render.hydration;
|
|
8587
|
-
let content;
|
|
8653
|
+
function renderEventCalendarMode(display, hydration) {
|
|
8588
8654
|
switch (display.displayMode) {
|
|
8589
|
-
case "
|
|
8590
|
-
|
|
8591
|
-
|
|
8592
|
-
case "
|
|
8593
|
-
|
|
8594
|
-
|
|
8595
|
-
|
|
8596
|
-
content = renderTimetableSsr(display, hydration);
|
|
8597
|
-
break;
|
|
8598
|
-
case "week-board":
|
|
8599
|
-
content = renderWeekBoardSsr(display, hydration);
|
|
8600
|
-
break;
|
|
8601
|
-
case "calendar":
|
|
8602
|
-
content = renderCalendarSsr(display, hydration);
|
|
8603
|
-
break;
|
|
8604
|
-
default: content = assertNeverDisplayMode(display.displayMode);
|
|
8655
|
+
case "week": return /* @__PURE__ */ jsx(CalendarRecurringWeek, { display });
|
|
8656
|
+
case "combined": return renderCombinedSsr(display, hydration.prefetchedEvents);
|
|
8657
|
+
case "list": return renderListSsr(display, hydration);
|
|
8658
|
+
case "timetable": return renderTimetableSsr(display, hydration);
|
|
8659
|
+
case "week-board": return renderWeekBoardSsr(display, hydration);
|
|
8660
|
+
case "calendar": return renderCalendarSsr(display, hydration);
|
|
8661
|
+
default: return assertNeverDisplayMode(display.displayMode);
|
|
8605
8662
|
}
|
|
8663
|
+
}
|
|
8664
|
+
const EventCalendarSSR = (props) => {
|
|
8665
|
+
const islandProps = buildEventCalendarInteractiveIslandProps(props);
|
|
8606
8666
|
return /* @__PURE__ */ jsxs("div", {
|
|
8607
8667
|
...getIslandRootProps("event-calendar", props.blockId),
|
|
8608
|
-
children: [/* @__PURE__ */ jsx(IslandPropsScript, { value: islandProps }),
|
|
8668
|
+
children: [/* @__PURE__ */ jsx(IslandPropsScript, { value: islandProps }), renderEventCalendarMode(islandProps.render.display, islandProps.render.hydration)]
|
|
8609
8669
|
});
|
|
8610
8670
|
};
|
|
8611
8671
|
//#endregion
|
|
@@ -9698,14 +9758,14 @@ function isDecoratedHeadingBlockKind(blockKind) {
|
|
|
9698
9758
|
return blockKind === "block.intro" || blockKind === "block.feature-cards" || blockKind === "block.testimonials" || blockKind === "block.faq";
|
|
9699
9759
|
}
|
|
9700
9760
|
function readVariant(blockContent) {
|
|
9701
|
-
if (!isRecord(blockContent)) return void 0;
|
|
9761
|
+
if (!isRecord$1(blockContent)) return void 0;
|
|
9702
9762
|
const variant = blockContent.variant;
|
|
9703
9763
|
return typeof variant === "string" ? variant : void 0;
|
|
9704
9764
|
}
|
|
9705
9765
|
function isFaqDecoratedVariant(variant) {
|
|
9706
9766
|
return variant === "default" || variant === "question-columns";
|
|
9707
9767
|
}
|
|
9708
|
-
function isRecord(value) {
|
|
9768
|
+
function isRecord$1(value) {
|
|
9709
9769
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
9710
9770
|
}
|
|
9711
9771
|
function buildHeadingDecorationWrapperClassName(className) {
|
|
@@ -10708,384 +10768,134 @@ function getDefaultComponentRegistry() {
|
|
|
10708
10768
|
return serverComponentRegistry;
|
|
10709
10769
|
}
|
|
10710
10770
|
//#endregion
|
|
10711
|
-
//#region ../blocks/src/
|
|
10712
|
-
|
|
10713
|
-
|
|
10714
|
-
|
|
10715
|
-
|
|
10716
|
-
|
|
10717
|
-
this.name = "MissingBlockOverrideError";
|
|
10718
|
-
}
|
|
10771
|
+
//#region ../blocks/src/system/runtime/blockComposition.ts
|
|
10772
|
+
const compositionTreatments = {
|
|
10773
|
+
intro: introCompositionTreatmentValues,
|
|
10774
|
+
"feature-cards": featureCardCompositionTreatmentValues,
|
|
10775
|
+
testimonials: testimonialsCompositionTreatmentValues,
|
|
10776
|
+
"offerings-preview": offeringsPreviewCompositionTreatmentValues
|
|
10719
10777
|
};
|
|
10720
|
-
function
|
|
10721
|
-
return
|
|
10722
|
-
}
|
|
10723
|
-
function isTokensOnlyResourceInput(props) {
|
|
10724
|
-
return props.rendering?.kind === "tokens-only";
|
|
10778
|
+
function isCompositionKind(value) {
|
|
10779
|
+
return Object.prototype.hasOwnProperty.call(compositionTreatments, value);
|
|
10725
10780
|
}
|
|
10726
|
-
|
|
10727
|
-
|
|
10728
|
-
|
|
10729
|
-
|
|
10730
|
-
|
|
10731
|
-
|
|
10732
|
-
|
|
10733
|
-
|
|
10734
|
-
|
|
10735
|
-
|
|
10781
|
+
/**
|
|
10782
|
+
* Narrow one kind's treatment. Written per-kind so the returned intent is a
|
|
10783
|
+
* real union member rather than a cast: `kind` and `treatment` are only known
|
|
10784
|
+
* to belong together inside a scope where `Kind` is a single kind.
|
|
10785
|
+
*/
|
|
10786
|
+
function readTreatment(kind, value) {
|
|
10787
|
+
const treatment = compositionTreatments[kind].find((candidate) => candidate === value);
|
|
10788
|
+
return treatment === void 0 ? null : {
|
|
10789
|
+
kind,
|
|
10790
|
+
treatment
|
|
10736
10791
|
};
|
|
10737
10792
|
}
|
|
10738
|
-
function
|
|
10739
|
-
if (
|
|
10740
|
-
|
|
10741
|
-
|
|
10742
|
-
return resources.kind === "available" ? {
|
|
10743
|
-
theme: resources.tokens,
|
|
10744
|
-
...resources.config ? { themeConfig: resources.config } : {}
|
|
10745
|
-
} : {};
|
|
10793
|
+
function readBlockComposition(value) {
|
|
10794
|
+
if (!isRecord(value) || typeof value.kind !== "string") return null;
|
|
10795
|
+
if (!isCompositionKind(value.kind)) return null;
|
|
10796
|
+
return readTreatment(value.kind, value.treatment);
|
|
10746
10797
|
}
|
|
10747
|
-
function
|
|
10748
|
-
|
|
10749
|
-
return resources;
|
|
10798
|
+
function isRecord(value) {
|
|
10799
|
+
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
10750
10800
|
}
|
|
10751
|
-
|
|
10752
|
-
|
|
10753
|
-
|
|
10754
|
-
return
|
|
10801
|
+
function arrangementHooksFromContent(content) {
|
|
10802
|
+
const value = content._lookHooks;
|
|
10803
|
+
if (typeof value !== "object" || value === null || Array.isArray(value)) return {};
|
|
10804
|
+
return Object.fromEntries(Object.entries(value).filter((entry) => typeof entry[1] === "string" && arrangementLookHooks.some((hook) => hook.endsWith("*") ? entry[0].startsWith(hook.slice(0, -1)) : entry[0] === hook)));
|
|
10755
10805
|
}
|
|
10756
|
-
function
|
|
10757
|
-
|
|
10758
|
-
return slots.get(joinSlotKey(previousBlockId, nextBlockId)) ?? null;
|
|
10806
|
+
function blockLookFromContent(content) {
|
|
10807
|
+
return typeof content.blockLook === "string" ? content.blockLook : void 0;
|
|
10759
10808
|
}
|
|
10809
|
+
//#endregion
|
|
10810
|
+
//#region ../blocks/src/system/componentFactory.ts
|
|
10760
10811
|
/**
|
|
10761
|
-
*
|
|
10762
|
-
*
|
|
10812
|
+
* Resolves the layout definition for a block based on its manifest and content.
|
|
10813
|
+
*
|
|
10814
|
+
* Fallback chain:
|
|
10815
|
+
* 1. content.variant (if manifest.variants exists and contains the key)
|
|
10816
|
+
* 2. content.layout (legacy blog listing support)
|
|
10817
|
+
* 3. manifest.defaultVariant (if manifest.variants exists)
|
|
10818
|
+
* 4. First key in manifest.variants
|
|
10819
|
+
* 5. manifest.layout
|
|
10820
|
+
*
|
|
10821
|
+
* @param manifest - The block manifest
|
|
10822
|
+
* @param content - The block content object
|
|
10823
|
+
* @returns The resolved NodeDefinition layout or null if none found
|
|
10763
10824
|
*/
|
|
10764
|
-
function
|
|
10765
|
-
const
|
|
10766
|
-
|
|
10767
|
-
|
|
10768
|
-
|
|
10769
|
-
|
|
10770
|
-
|
|
10771
|
-
|
|
10772
|
-
|
|
10773
|
-
|
|
10774
|
-
|
|
10775
|
-
|
|
10776
|
-
|
|
10777
|
-
|
|
10778
|
-
|
|
10779
|
-
|
|
10780
|
-
|
|
10781
|
-
|
|
10825
|
+
function resolveBlockVariantKey(manifest, content) {
|
|
10826
|
+
const runtimeLook = content._effectiveLook;
|
|
10827
|
+
const look = isObjectRecord(runtimeLook) && isObjectRecord(runtimeLook.look) && isObjectRecord(runtimeLook.look.structure) && runtimeLook.look.structure.kind === "arrangement" ? runtimeLook.look : null;
|
|
10828
|
+
return resolveEffectiveArrangement({
|
|
10829
|
+
manifest: arrangementManifestFromVariants(manifest),
|
|
10830
|
+
look,
|
|
10831
|
+
storedVariant: parseStoredVariant(manifest, content)
|
|
10832
|
+
}).key;
|
|
10833
|
+
}
|
|
10834
|
+
function resolveBlockLayout(manifest, effectiveKey) {
|
|
10835
|
+
if (!manifest.variants) return manifest.layout ?? null;
|
|
10836
|
+
const variantKey = effectiveKey;
|
|
10837
|
+
if (variantKey) {
|
|
10838
|
+
const variant = manifest.variants[variantKey];
|
|
10839
|
+
if (variant) return variant;
|
|
10840
|
+
}
|
|
10841
|
+
return manifest.layout ?? null;
|
|
10842
|
+
}
|
|
10843
|
+
function buildPreviewFieldConstraints(manifest) {
|
|
10844
|
+
const entries = collectPreviewFieldConstraintEntries(manifest.fields ?? []);
|
|
10845
|
+
if (entries.length === 0) return void 0;
|
|
10846
|
+
return Object.fromEntries(entries);
|
|
10847
|
+
}
|
|
10848
|
+
function collectPreviewFieldConstraintEntries(fields, prefix = "") {
|
|
10849
|
+
return fields.flatMap((field) => {
|
|
10850
|
+
const path = prefix ? `${prefix}.${field.id}` : field.id;
|
|
10851
|
+
return [...field.type === "text" && typeof field.maxLength === "number" ? [[path, { maxLength: field.maxLength }]] : [], ...collectNestedPreviewFieldConstraintEntries(field, path)];
|
|
10782
10852
|
});
|
|
10783
|
-
if (!painted && (extra === null || extra === void 0)) return null;
|
|
10784
|
-
return /* @__PURE__ */ jsxs(React.Fragment, { children: [painted, extra] }, `${input.blockKey}:join`);
|
|
10785
10853
|
}
|
|
10786
|
-
|
|
10787
|
-
|
|
10788
|
-
|
|
10789
|
-
|
|
10790
|
-
|
|
10854
|
+
function collectNestedPreviewFieldConstraintEntries(field, path) {
|
|
10855
|
+
switch (field.type) {
|
|
10856
|
+
case "group":
|
|
10857
|
+
case "modal": return collectPreviewFieldConstraintEntries(field.schema.fields, path);
|
|
10858
|
+
case "repeater": {
|
|
10859
|
+
const schemaEntries = field.schema ? collectPreviewFieldConstraintEntries(field.schema.fields, path) : [];
|
|
10860
|
+
const itemTypeEntries = Object.values(field.itemTypes ?? {}).flatMap((itemType) => collectPreviewFieldConstraintEntries(itemType.fields, path));
|
|
10861
|
+
return [...schemaEntries, ...itemTypeEntries];
|
|
10862
|
+
}
|
|
10863
|
+
case "tabGroup": return field.tabs.flatMap((tab) => collectPreviewFieldConstraintEntries(tab.fields, path));
|
|
10864
|
+
case "boolean":
|
|
10865
|
+
case "contentTypeSelect":
|
|
10866
|
+
case "date":
|
|
10867
|
+
case "datetime":
|
|
10868
|
+
case "entryPicker":
|
|
10869
|
+
case "file":
|
|
10870
|
+
case "inlineText":
|
|
10871
|
+
case "link":
|
|
10872
|
+
case "media":
|
|
10873
|
+
case "number":
|
|
10874
|
+
case "presetOrCustom":
|
|
10875
|
+
case "reference":
|
|
10876
|
+
case "richText":
|
|
10877
|
+
case "select":
|
|
10878
|
+
case "slug":
|
|
10879
|
+
case "text":
|
|
10880
|
+
case "time":
|
|
10881
|
+
case "url": return [];
|
|
10882
|
+
default: return assertNever$1(field);
|
|
10883
|
+
}
|
|
10791
10884
|
}
|
|
10792
|
-
|
|
10885
|
+
/** Share the supplied snapshot with transforms and manifest bindings, including standalone components. */
|
|
10886
|
+
function suppliedBlockRuntime(props) {
|
|
10887
|
+
const candidate = props.viewModelOverrides?.$root;
|
|
10888
|
+
const root = isObjectRecord(candidate) ? candidate : {};
|
|
10889
|
+
const dateContext = props.dateContext ?? runtimeDateContext(props.viewModelOverrides ?? {});
|
|
10890
|
+
const now = root.now === void 0 || root.now === props.now ? props.now : readRuntimeNow(root.now);
|
|
10793
10891
|
return {
|
|
10794
|
-
|
|
10795
|
-
|
|
10796
|
-
|
|
10797
|
-
|
|
10798
|
-
|
|
10799
|
-
|
|
10800
|
-
|
|
10801
|
-
* it pads the bottom of the block above the join; its `after` reserve pads the
|
|
10802
|
-
* top of the block below. Joins that do not draw reserve nothing.
|
|
10803
|
-
*/
|
|
10804
|
-
function blockBoundaryReserves(input) {
|
|
10805
|
-
const top = reserveOnSide(input.before, "after");
|
|
10806
|
-
const bottom = reserveOnSide(input.after, "before");
|
|
10807
|
-
const style = {
|
|
10808
|
-
...top ? { "--site-style-boundary-before-reserve": top.length } : {},
|
|
10809
|
-
...bottom ? { "--site-style-boundary-after-reserve": bottom.length } : {}
|
|
10810
|
-
};
|
|
10811
|
-
return {
|
|
10812
|
-
topPlacement: top?.placement,
|
|
10813
|
-
bottomPlacement: bottom?.placement,
|
|
10814
|
-
style: top || bottom ? style : void 0
|
|
10815
|
-
};
|
|
10816
|
-
}
|
|
10817
|
-
/** The reserve one join needs on one side of itself, if it draws at all. */
|
|
10818
|
-
function reserveOnSide(slot, side) {
|
|
10819
|
-
const layout = renderedJoinLayout(slot?.join ?? null);
|
|
10820
|
-
const length = layout?.reserves[side] ?? null;
|
|
10821
|
-
return layout && length ? {
|
|
10822
|
-
length,
|
|
10823
|
-
placement: layout.placement
|
|
10824
|
-
} : null;
|
|
10825
|
-
}
|
|
10826
|
-
function pageBlockPosition(index, blockCount) {
|
|
10827
|
-
if (blockCount <= 1) return "only";
|
|
10828
|
-
if (index === 0) return "first";
|
|
10829
|
-
if (index === blockCount - 1) return "last";
|
|
10830
|
-
return "middle";
|
|
10831
|
-
}
|
|
10832
|
-
//#endregion
|
|
10833
|
-
//#region ../blocks/src/pageRendererContracts.ts
|
|
10834
|
-
function buildPageRendererRootRuntime(dataContext) {
|
|
10835
|
-
const { siteId = null, siteName, pageId = null, pathname = null, bookingTimeZone, previewStage = "published", apiBaseUrl = null, portalToken = null, readAuthority, bookingOfferingPresets = [], appointmentServicePathPrefix = null, openingHours, siteTerms, mailingList = { tag: "not_configured" }, loaderFailures = {} } = dataContext ?? {};
|
|
10836
|
-
return {
|
|
10837
|
-
siteId,
|
|
10838
|
-
demoEmailSuppressed: resolveDemoEmailSuppression(dataContext),
|
|
10839
|
-
siteName,
|
|
10840
|
-
pageId,
|
|
10841
|
-
pathname,
|
|
10842
|
-
bookingTimeZone,
|
|
10843
|
-
...pageDateRuntime(dataContext),
|
|
10844
|
-
previewStage,
|
|
10845
|
-
apiBaseUrl,
|
|
10846
|
-
portalToken,
|
|
10847
|
-
readAuthority,
|
|
10848
|
-
bookingOfferingPresets,
|
|
10849
|
-
appointmentServicePathPrefix,
|
|
10850
|
-
openingHours,
|
|
10851
|
-
siteTerms,
|
|
10852
|
-
mailingList,
|
|
10853
|
-
loaderFailures
|
|
10854
|
-
};
|
|
10855
|
-
}
|
|
10856
|
-
function resolveDemoEmailSuppression(dataContext) {
|
|
10857
|
-
return dataContext?.demoEmailSuppressed === true;
|
|
10858
|
-
}
|
|
10859
|
-
function pageDateRuntime(dataContext) {
|
|
10860
|
-
return {
|
|
10861
|
-
dateContext: pageDateRuntimeContext(dataContext),
|
|
10862
|
-
now: dataContext?.now
|
|
10863
|
-
};
|
|
10864
|
-
}
|
|
10865
|
-
function pageDateRuntimeContext(dataContext) {
|
|
10866
|
-
return dataContext?.dateContext ?? resolveDateRuntimeContext(dataContext?.bookingTimeZone);
|
|
10867
|
-
}
|
|
10868
|
-
//#endregion
|
|
10869
|
-
//#region ../blocks/src/pageRenderAudience.tsx
|
|
10870
|
-
/**
|
|
10871
|
-
* The single policy for what a non-renderable block looks like.
|
|
10872
|
-
*
|
|
10873
|
-
* Public visitors never see renderer diagnostics, so every reason omits.
|
|
10874
|
-
* Authoring surfaces keep the wording they have always had — the strings below
|
|
10875
|
-
* are moved verbatim from the five former `fallback()` call sites.
|
|
10876
|
-
*/
|
|
10877
|
-
function presentNotRenderableBlock(reason, audience) {
|
|
10878
|
-
if (audience === "public") return null;
|
|
10879
|
-
return diagnostic(authoringMessage(reason));
|
|
10880
|
-
}
|
|
10881
|
-
function authoringMessage(reason) {
|
|
10882
|
-
switch (reason.kind) {
|
|
10883
|
-
case "invalid-admission": return `Invalid content for block kind "${reason.blockKind}".`;
|
|
10884
|
-
case "missing-definition": return reason.isCustom ? `No renderer available for block kind "${reason.blockKind}". The custom block definition was not found (missing manifest).` : `No renderer available for block kind "${reason.blockKind}".`;
|
|
10885
|
-
case "missing-layout": return reason.isCustom ? `No renderer available for block kind "${reason.blockKind}". This custom block has no layout/variants, so it must be rendered via blockOverrides["${reason.blockKind}"].` : `No renderer available for block kind "${reason.blockKind}".`;
|
|
10886
|
-
case "editor-unpreviewable":
|
|
10887
|
-
case "render-threw": return `Unable to render block kind "${reason.blockKind}".`;
|
|
10888
|
-
}
|
|
10889
|
-
}
|
|
10890
|
-
/**
|
|
10891
|
-
* The empty-page notice. Authoring-only for the same reason as the block
|
|
10892
|
-
* diagnostics: "No blocks found." is a message for whoever is building the
|
|
10893
|
-
* page, not for whoever is reading it.
|
|
10894
|
-
*/
|
|
10895
|
-
function presentEmptyPage(audience) {
|
|
10896
|
-
if (audience === "public") return null;
|
|
10897
|
-
return diagnostic("No blocks found.");
|
|
10898
|
-
}
|
|
10899
|
-
function diagnostic(message) {
|
|
10900
|
-
return /* @__PURE__ */ jsx("div", {
|
|
10901
|
-
className: "rb-p-6 rb-caption",
|
|
10902
|
-
style: textColorStyle("mutedText"),
|
|
10903
|
-
children: message
|
|
10904
|
-
});
|
|
10905
|
-
}
|
|
10906
|
-
//#endregion
|
|
10907
|
-
//#region ../blocks/src/pageRenderDiagnostics.ts
|
|
10908
|
-
/**
|
|
10909
|
-
* Emits one structured record per omitted block, per server render pass.
|
|
10910
|
-
*
|
|
10911
|
-
* Server-only by decision D3: public pages are server-rendered, and this is the
|
|
10912
|
-
* runtime whose logger transport reaches centralised collection. A browser-side
|
|
10913
|
-
* record would not, and re-render/hydration would multiply it. The cost is that
|
|
10914
|
-
* an omission only a client navigation can see goes unlogged.
|
|
10915
|
-
*
|
|
10916
|
-
* Deliberately *not* inside the plan's `useMemo` — React makes no promises about
|
|
10917
|
-
* when a memo recomputes, so a log placed there is neither reliable nor bounded.
|
|
10918
|
-
*/
|
|
10919
|
-
function logOmittedBlocks(plan, dataContext) {
|
|
10920
|
-
if (typeof window !== "undefined") return;
|
|
10921
|
-
if (plan.omitted.length === 0) return;
|
|
10922
|
-
const page = {
|
|
10923
|
-
siteId: dataContext?.siteId ?? null,
|
|
10924
|
-
pageId: dataContext?.pageId ?? null
|
|
10925
|
-
};
|
|
10926
|
-
if (plan.entries.length === 0) {
|
|
10927
|
-
logger.error("blocks.pageRenderer.pageFullyOmitted", {
|
|
10928
|
-
...page,
|
|
10929
|
-
omittedCount: plan.omitted.length,
|
|
10930
|
-
blocks: plan.omitted.map((omission) => ({
|
|
10931
|
-
blockId: omission.blockId,
|
|
10932
|
-
blockKind: omission.blockKind,
|
|
10933
|
-
reason: omission.reason.kind
|
|
10934
|
-
}))
|
|
10935
|
-
});
|
|
10936
|
-
debugOmittedCustomBlocks(plan);
|
|
10937
|
-
return;
|
|
10938
|
-
}
|
|
10939
|
-
for (const omission of plan.omitted) logger.warn("blocks.pageRenderer.blockOmitted", {
|
|
10940
|
-
...page,
|
|
10941
|
-
blockId: omission.blockId,
|
|
10942
|
-
blockKind: omission.blockKind,
|
|
10943
|
-
reason: omission.reason.kind,
|
|
10944
|
-
admissionError: omission.reason.kind === "invalid-admission" ? omission.reason.error.kind : null
|
|
10945
|
-
});
|
|
10946
|
-
debugOmittedCustomBlocks(plan);
|
|
10947
|
-
}
|
|
10948
|
-
/**
|
|
10949
|
-
* Unlike the plan-time omissions this one genuinely can fire per re-render —
|
|
10950
|
-
* it is raised where the failure happens, and no once-ness is claimed for it.
|
|
10951
|
-
*/
|
|
10952
|
-
function logRenderThrew(block, dataContext) {
|
|
10953
|
-
if (typeof window !== "undefined") return;
|
|
10954
|
-
logger.warn("blocks.pageRenderer.blockRenderThrew", {
|
|
10955
|
-
siteId: dataContext?.siteId ?? null,
|
|
10956
|
-
pageId: dataContext?.pageId ?? null,
|
|
10957
|
-
blockId: block.id ?? null,
|
|
10958
|
-
blockKind: block.kind
|
|
10959
|
-
});
|
|
10960
|
-
}
|
|
10961
|
-
/**
|
|
10962
|
-
* Opt-in developer affordance for tracking down custom-block resolution.
|
|
10963
|
-
*
|
|
10964
|
-
* Driven off the plan's omissions so it stays reachable on **public** renders —
|
|
10965
|
-
* "my custom block doesn't show up on the live site" is the exact situation it
|
|
10966
|
-
* exists for, and that is the render where the block is now silently absent.
|
|
10967
|
-
*/
|
|
10968
|
-
function debugOmittedCustomBlocks(plan) {
|
|
10969
|
-
if (!shouldDebugCustomBlocks()) return;
|
|
10970
|
-
for (const omission of plan.omitted) {
|
|
10971
|
-
if (!omission.blockKind.startsWith("custom.")) continue;
|
|
10972
|
-
debugCustomBlockResolution(omission.reason.kind, omission.blockId, omission.blockKind, omission.debug);
|
|
10973
|
-
}
|
|
10974
|
-
}
|
|
10975
|
-
/** The authoring-side equivalent, where the block stays in the entry list. */
|
|
10976
|
-
function debugCustomBlockDiagnostic(reason, block, debug) {
|
|
10977
|
-
if (!block.kind.startsWith("custom.") || !shouldDebugCustomBlocks()) return;
|
|
10978
|
-
debugCustomBlockResolution(reason.kind, block.id ?? null, block.kind, debug);
|
|
10979
|
-
}
|
|
10980
|
-
function debugCustomBlockResolution(reasonKind, blockId, blockKind, debug) {
|
|
10981
|
-
try {
|
|
10982
|
-
console.warn(reasonKind === "missing-definition" ? "[blocks:PageRenderer] custom block definition missing" : "[blocks:PageRenderer] custom block has no layout/variants and no override", {
|
|
10983
|
-
blockId,
|
|
10984
|
-
blockKind,
|
|
10985
|
-
hasOverride: debug.hasOverride,
|
|
10986
|
-
sdkCustomBlocksCount: debug.sdkCustomBlocksCount,
|
|
10987
|
-
dbCustomBlocksCount: debug.dbCustomBlocksCount,
|
|
10988
|
-
manifestKeys: debug.manifestKeys
|
|
10989
|
-
});
|
|
10990
|
-
} catch {}
|
|
10991
|
-
}
|
|
10992
|
-
function shouldDebugCustomBlocks() {
|
|
10993
|
-
try {
|
|
10994
|
-
return globalThis.process?.env?.DEBUG_CUSTOM_BLOCKS === "1";
|
|
10995
|
-
} catch {
|
|
10996
|
-
return false;
|
|
10997
|
-
}
|
|
10998
|
-
}
|
|
10999
|
-
//#endregion
|
|
11000
|
-
//#region ../blocks/src/system/componentFactory.ts
|
|
11001
|
-
/**
|
|
11002
|
-
* Resolves the layout definition for a block based on its manifest and content.
|
|
11003
|
-
*
|
|
11004
|
-
* Fallback chain:
|
|
11005
|
-
* 1. content.variant (if manifest.variants exists and contains the key)
|
|
11006
|
-
* 2. content.layout (legacy blog listing support)
|
|
11007
|
-
* 3. manifest.defaultVariant (if manifest.variants exists)
|
|
11008
|
-
* 4. First key in manifest.variants
|
|
11009
|
-
* 5. manifest.layout
|
|
11010
|
-
*
|
|
11011
|
-
* @param manifest - The block manifest
|
|
11012
|
-
* @param content - The block content object
|
|
11013
|
-
* @returns The resolved NodeDefinition layout or null if none found
|
|
11014
|
-
*/
|
|
11015
|
-
function resolveBlockVariantKey(manifest, content) {
|
|
11016
|
-
const runtimeLook = content._effectiveLook;
|
|
11017
|
-
const look = isObjectRecord(runtimeLook) && isObjectRecord(runtimeLook.look) && isObjectRecord(runtimeLook.look.structure) && runtimeLook.look.structure.kind === "arrangement" ? runtimeLook.look : null;
|
|
11018
|
-
return resolveEffectiveArrangement({
|
|
11019
|
-
manifest: arrangementManifestFromVariants(manifest),
|
|
11020
|
-
look,
|
|
11021
|
-
storedVariant: parseStoredVariant(manifest, content)
|
|
11022
|
-
}).key;
|
|
11023
|
-
}
|
|
11024
|
-
function resolveBlockLayout(manifest, effectiveKey) {
|
|
11025
|
-
if (!manifest.variants) return manifest.layout ?? null;
|
|
11026
|
-
const variantKey = effectiveKey;
|
|
11027
|
-
if (variantKey) {
|
|
11028
|
-
const variant = manifest.variants[variantKey];
|
|
11029
|
-
if (variant) return variant;
|
|
11030
|
-
}
|
|
11031
|
-
return manifest.layout ?? null;
|
|
11032
|
-
}
|
|
11033
|
-
function buildPreviewFieldConstraints(manifest) {
|
|
11034
|
-
const entries = collectPreviewFieldConstraintEntries(manifest.fields ?? []);
|
|
11035
|
-
if (entries.length === 0) return void 0;
|
|
11036
|
-
return Object.fromEntries(entries);
|
|
11037
|
-
}
|
|
11038
|
-
function collectPreviewFieldConstraintEntries(fields, prefix = "") {
|
|
11039
|
-
return fields.flatMap((field) => {
|
|
11040
|
-
const path = prefix ? `${prefix}.${field.id}` : field.id;
|
|
11041
|
-
return [...field.type === "text" && typeof field.maxLength === "number" ? [[path, { maxLength: field.maxLength }]] : [], ...collectNestedPreviewFieldConstraintEntries(field, path)];
|
|
11042
|
-
});
|
|
11043
|
-
}
|
|
11044
|
-
function collectNestedPreviewFieldConstraintEntries(field, path) {
|
|
11045
|
-
switch (field.type) {
|
|
11046
|
-
case "group":
|
|
11047
|
-
case "modal": return collectPreviewFieldConstraintEntries(field.schema.fields, path);
|
|
11048
|
-
case "repeater": {
|
|
11049
|
-
const schemaEntries = field.schema ? collectPreviewFieldConstraintEntries(field.schema.fields, path) : [];
|
|
11050
|
-
const itemTypeEntries = Object.values(field.itemTypes ?? {}).flatMap((itemType) => collectPreviewFieldConstraintEntries(itemType.fields, path));
|
|
11051
|
-
return [...schemaEntries, ...itemTypeEntries];
|
|
11052
|
-
}
|
|
11053
|
-
case "tabGroup": return field.tabs.flatMap((tab) => collectPreviewFieldConstraintEntries(tab.fields, path));
|
|
11054
|
-
case "boolean":
|
|
11055
|
-
case "contentTypeSelect":
|
|
11056
|
-
case "date":
|
|
11057
|
-
case "datetime":
|
|
11058
|
-
case "entryPicker":
|
|
11059
|
-
case "file":
|
|
11060
|
-
case "inlineText":
|
|
11061
|
-
case "link":
|
|
11062
|
-
case "media":
|
|
11063
|
-
case "number":
|
|
11064
|
-
case "presetOrCustom":
|
|
11065
|
-
case "reference":
|
|
11066
|
-
case "richText":
|
|
11067
|
-
case "select":
|
|
11068
|
-
case "slug":
|
|
11069
|
-
case "text":
|
|
11070
|
-
case "time":
|
|
11071
|
-
case "url": return [];
|
|
11072
|
-
default: return assertNever$1(field);
|
|
11073
|
-
}
|
|
11074
|
-
}
|
|
11075
|
-
/** Share the supplied snapshot with transforms and manifest bindings, including standalone components. */
|
|
11076
|
-
function suppliedBlockRuntime(props) {
|
|
11077
|
-
const candidate = props.viewModelOverrides?.$root;
|
|
11078
|
-
const root = isObjectRecord(candidate) ? candidate : {};
|
|
11079
|
-
const dateContext = props.dateContext ?? runtimeDateContext(props.viewModelOverrides ?? {});
|
|
11080
|
-
const now = root.now === void 0 || root.now === props.now ? props.now : readRuntimeNow(root.now);
|
|
11081
|
-
return {
|
|
11082
|
-
dateContext,
|
|
11083
|
-
now,
|
|
11084
|
-
root: {
|
|
11085
|
-
dateContext,
|
|
11086
|
-
...root,
|
|
11087
|
-
now
|
|
11088
|
-
}
|
|
10892
|
+
dateContext,
|
|
10893
|
+
now,
|
|
10894
|
+
root: {
|
|
10895
|
+
dateContext,
|
|
10896
|
+
...root,
|
|
10897
|
+
now
|
|
10898
|
+
}
|
|
11089
10899
|
};
|
|
11090
10900
|
}
|
|
11091
10901
|
function prepareDefaultBlockRender(manifest, props) {
|
|
@@ -11181,102 +10991,392 @@ function buildBlockViewModel(input) {
|
|
|
11181
10991
|
}
|
|
11182
10992
|
};
|
|
11183
10993
|
}
|
|
11184
|
-
function withButtonSystem(theme, themeConfig) {
|
|
11185
|
-
if (!themeConfig) return theme;
|
|
10994
|
+
function withButtonSystem(theme, themeConfig) {
|
|
10995
|
+
if (!themeConfig) return theme;
|
|
10996
|
+
return {
|
|
10997
|
+
...theme,
|
|
10998
|
+
buttons: themeConfig.buttons ?? generateDefaultButtonSystem(themeConfig)
|
|
10999
|
+
};
|
|
11000
|
+
}
|
|
11001
|
+
function beginBlockRenderMeasurement() {
|
|
11002
|
+
const perfEnv = globalThis.process?.env;
|
|
11003
|
+
if (perfEnv?.DEBUG_PERF !== "1" || typeof window !== "undefined") return null;
|
|
11004
|
+
const parsedThreshold = Number.parseInt(perfEnv.DEBUG_PERF_BLOCK_MS ?? "", 10);
|
|
11005
|
+
return {
|
|
11006
|
+
startedAt: Date.now(),
|
|
11007
|
+
thresholdMs: Number.isFinite(parsedThreshold) && parsedThreshold > 0 ? parsedThreshold : 25
|
|
11008
|
+
};
|
|
11009
|
+
}
|
|
11010
|
+
function reportSlowBlockRender(measurement, input) {
|
|
11011
|
+
if (!measurement) return;
|
|
11012
|
+
const durationMs = Date.now() - measurement.startedAt;
|
|
11013
|
+
if (durationMs < measurement.thresholdMs) return;
|
|
11014
|
+
const content = typeof input.content === "object" && input.content !== null ? input.content : null;
|
|
11015
|
+
const variant = typeof content?.variant === "string" ? content.variant : typeof content?.layout === "string" ? content.layout : null;
|
|
11016
|
+
console.log("perf.blocks.resolveTree", {
|
|
11017
|
+
blockId: input.blockId ?? null,
|
|
11018
|
+
blockKind: input.blockKind,
|
|
11019
|
+
manifest: input.manifestName,
|
|
11020
|
+
variant,
|
|
11021
|
+
durationMs
|
|
11022
|
+
});
|
|
11023
|
+
}
|
|
11024
|
+
function resolveThemeConfigForBindings(themeConfig) {
|
|
11025
|
+
if (!themeConfig || themeConfig.accordions) return themeConfig;
|
|
11026
|
+
assertThemeConfigCanGenerateAccordionSystem(themeConfig);
|
|
11027
|
+
return {
|
|
11028
|
+
...themeConfig,
|
|
11029
|
+
accordions: generateDefaultAccordionSystem(themeConfig)
|
|
11030
|
+
};
|
|
11031
|
+
}
|
|
11032
|
+
function assertThemeConfigCanGenerateAccordionSystem(themeConfig) {
|
|
11033
|
+
const missingPaths = [
|
|
11034
|
+
["axes.tone", themeConfig.axes?.tone],
|
|
11035
|
+
["axes.density", themeConfig.axes?.density],
|
|
11036
|
+
["axes.conversionBias", themeConfig.axes?.conversionBias],
|
|
11037
|
+
["space", themeConfig.space],
|
|
11038
|
+
["border.width", themeConfig.border?.width],
|
|
11039
|
+
["shadow.elevation", themeConfig.shadow?.elevation],
|
|
11040
|
+
["shadow.position", themeConfig.shadow?.position]
|
|
11041
|
+
].flatMap(([path, value]) => value == null ? [path] : []);
|
|
11042
|
+
if (missingPaths.length > 0) throw new Error(`Cannot generate accordion defaults from incomplete themeConfig; missing ${missingPaths.join(", ")}`);
|
|
11043
|
+
}
|
|
11044
|
+
function renderBlock(manifest, content, options = {}) {
|
|
11045
|
+
const variantKey = resolveBlockVariantKey(manifest, content);
|
|
11046
|
+
if (!resolveBlockLayout(manifest, variantKey)) throw new Error(`Block manifest "${manifest.name}" requires a layout definition`);
|
|
11047
|
+
const Component = makeDefaultBlockComponent({ manifest });
|
|
11048
|
+
const resolvedRegistry = options.registry ?? getDefaultComponentRegistry();
|
|
11049
|
+
const resolvedTheme = options.theme ?? defaultThemeTokens;
|
|
11050
|
+
const cleanKind = manifest.name.replace(/^block\./, "");
|
|
11051
|
+
const componentElement = React.createElement(Component, {
|
|
11052
|
+
now: options.now,
|
|
11053
|
+
dateContext: options.dateContext,
|
|
11054
|
+
content,
|
|
11055
|
+
data: options.data,
|
|
11056
|
+
registry: resolvedRegistry,
|
|
11057
|
+
theme: resolvedTheme,
|
|
11058
|
+
themeConfig: options.themeConfig,
|
|
11059
|
+
transforms: options.transforms,
|
|
11060
|
+
viewModelOverrides: options.viewModelOverrides,
|
|
11061
|
+
pathBase: options.pathBase,
|
|
11062
|
+
blockId: null,
|
|
11063
|
+
blockKind: manifest.name
|
|
11064
|
+
});
|
|
11065
|
+
if (manifest.behaviours?.managesOwnWrapper) return componentElement;
|
|
11066
|
+
const styleGroup = typeof content.styleGroup === "string" ? content.styleGroup : void 0;
|
|
11067
|
+
const blockLook = typeof content.blockLook === "string" ? content.blockLook : void 0;
|
|
11068
|
+
const blockComposition = readBlockComposition(content.blockComposition);
|
|
11069
|
+
return React.createElement("div", {
|
|
11070
|
+
className: `block-${cleanKind}`,
|
|
11071
|
+
"data-block": cleanKind,
|
|
11072
|
+
"data-block-kind": manifest.name,
|
|
11073
|
+
...variantKey ? {
|
|
11074
|
+
"data-block-variant": variantKey,
|
|
11075
|
+
"data-variant": variantKey
|
|
11076
|
+
} : {},
|
|
11077
|
+
...blockLook ? { "data-block-look": blockLook } : {},
|
|
11078
|
+
...arrangementHooksFromContent(content),
|
|
11079
|
+
...blockComposition ? {
|
|
11080
|
+
"data-block-composition": blockComposition.treatment,
|
|
11081
|
+
"data-block-composition-kind": blockComposition.kind
|
|
11082
|
+
} : {},
|
|
11083
|
+
...styleGroup ? { "data-style-group": styleGroup } : {}
|
|
11084
|
+
}, componentElement);
|
|
11085
|
+
}
|
|
11086
|
+
/** Standalone blocks are a wire boundary; page roots already hold admitted context. */
|
|
11087
|
+
function runtimeDateContext(viewModel) {
|
|
11088
|
+
const root = isObjectRecord(viewModel.$root) ? viewModel.$root : {};
|
|
11089
|
+
return resolveDateRuntimeContext(typeof root.bookingTimeZone === "string" ? root.bookingTimeZone : void 0);
|
|
11090
|
+
}
|
|
11091
|
+
//#endregion
|
|
11092
|
+
//#region ../blocks/src/pageRenderingMode.ts
|
|
11093
|
+
var MissingBlockOverrideError$1 = class extends Error {
|
|
11094
|
+
constructor(blockKind) {
|
|
11095
|
+
super(`Override-only rendering requires an override for block kind "${blockKind}".`);
|
|
11096
|
+
this.blockKind = blockKind;
|
|
11097
|
+
this.code = "missing_block_override";
|
|
11098
|
+
this.name = "MissingBlockOverrideError";
|
|
11099
|
+
}
|
|
11100
|
+
};
|
|
11101
|
+
function isOverrideOnlyResourceInput(props) {
|
|
11102
|
+
return props.rendering?.kind === "overrides-only";
|
|
11103
|
+
}
|
|
11104
|
+
function isTokensOnlyResourceInput(props) {
|
|
11105
|
+
return props.rendering?.kind === "tokens-only";
|
|
11106
|
+
}
|
|
11107
|
+
function resolvePageThemeResources(props) {
|
|
11108
|
+
if (isOverrideOnlyResourceInput(props)) return { kind: "unavailable" };
|
|
11109
|
+
if (isTokensOnlyResourceInput(props)) return {
|
|
11110
|
+
kind: "available",
|
|
11111
|
+
tokens: props.themeTokens
|
|
11112
|
+
};
|
|
11113
|
+
return {
|
|
11114
|
+
kind: "available",
|
|
11115
|
+
tokens: props.themeTokens ?? buildThemeRuntime$1(props.theme).tokens,
|
|
11116
|
+
config: props.theme
|
|
11117
|
+
};
|
|
11118
|
+
}
|
|
11119
|
+
function requireBlockOverride(resources, override, blockKind) {
|
|
11120
|
+
if (resources.kind === "unavailable" && !override) throw new MissingBlockOverrideError$1(blockKind);
|
|
11121
|
+
}
|
|
11122
|
+
function overrideThemeProps(resources) {
|
|
11123
|
+
return resources.kind === "available" ? {
|
|
11124
|
+
theme: resources.tokens,
|
|
11125
|
+
...resources.config ? { themeConfig: resources.config } : {}
|
|
11126
|
+
} : {};
|
|
11127
|
+
}
|
|
11128
|
+
function requireThemeResources(resources, blockKind) {
|
|
11129
|
+
if (resources.kind === "unavailable") throw new MissingBlockOverrideError$1(blockKind);
|
|
11130
|
+
return resources;
|
|
11131
|
+
}
|
|
11132
|
+
//#endregion
|
|
11133
|
+
//#region ../blocks/src/pageRendererBoundaries.tsx
|
|
11134
|
+
function joinSlotsByPair(slots) {
|
|
11135
|
+
return new Map(slots.map((slot) => [joinSlotKey(slot.previousBlockId, slot.nextBlockId), slot]));
|
|
11136
|
+
}
|
|
11137
|
+
function joinSlotBetween(previousBlockId, nextBlockId, slots) {
|
|
11138
|
+
if (!previousBlockId || !nextBlockId) return null;
|
|
11139
|
+
return slots.get(joinSlotKey(previousBlockId, nextBlockId)) ?? null;
|
|
11140
|
+
}
|
|
11141
|
+
/**
|
|
11142
|
+
* The markup at one join: the painted boundary element when the join draws,
|
|
11143
|
+
* then whatever `renderJoin` adds. Null when there is nothing to render.
|
|
11144
|
+
*/
|
|
11145
|
+
function renderJoinSlot(input) {
|
|
11146
|
+
const { slot } = input;
|
|
11147
|
+
if (!slot) return null;
|
|
11148
|
+
const layout = renderedJoinLayout(slot.join);
|
|
11149
|
+
const painted = slot.join && layout ? /* @__PURE__ */ jsx("div", {
|
|
11150
|
+
"aria-hidden": "true",
|
|
11151
|
+
"data-block-boundary": "",
|
|
11152
|
+
"data-boundary-id": slot.join.boundaryId,
|
|
11153
|
+
"data-boundary-previous-block-id": slot.previousBlockId,
|
|
11154
|
+
"data-boundary-next-block-id": slot.nextBlockId,
|
|
11155
|
+
"data-boundary-treatment": slot.join.treatment,
|
|
11156
|
+
"data-boundary-placement": layout.placement,
|
|
11157
|
+
style: boundaryPaintStyle(layout.paint)
|
|
11158
|
+
}, `${input.blockKey}:boundary`) : null;
|
|
11159
|
+
const extra = input.renderJoin?.({
|
|
11160
|
+
previousBlockId: slot.previousBlockId,
|
|
11161
|
+
nextBlockId: slot.nextBlockId,
|
|
11162
|
+
join: slot.join
|
|
11163
|
+
});
|
|
11164
|
+
if (!painted && (extra === null || extra === void 0)) return null;
|
|
11165
|
+
return /* @__PURE__ */ jsxs(React.Fragment, { children: [painted, extra] }, `${input.blockKey}:join`);
|
|
11166
|
+
}
|
|
11167
|
+
/**
|
|
11168
|
+
* The one render-edge place a theme token becomes CSS.
|
|
11169
|
+
*/
|
|
11170
|
+
function themeTokenCss(token) {
|
|
11171
|
+
return `rgb(var(--tb-${token}))`;
|
|
11172
|
+
}
|
|
11173
|
+
function boundaryPaintStyle(paint) {
|
|
11174
|
+
return {
|
|
11175
|
+
"--boundary-shape-paint": themeTokenCss(paint.shape),
|
|
11176
|
+
...paint.band ? { "--boundary-band-paint": themeTokenCss(paint.band) } : {}
|
|
11177
|
+
};
|
|
11178
|
+
}
|
|
11179
|
+
/**
|
|
11180
|
+
* Reserve attributes and variables for a block wrapper, from the joins on
|
|
11181
|
+
* either side. A join's `before` reserve sits inside its previous section, so
|
|
11182
|
+
* it pads the bottom of the block above the join; its `after` reserve pads the
|
|
11183
|
+
* top of the block below. Joins that do not draw reserve nothing.
|
|
11184
|
+
*/
|
|
11185
|
+
function blockBoundaryReserves(input) {
|
|
11186
|
+
const top = reserveOnSide(input.before, "after");
|
|
11187
|
+
const bottom = reserveOnSide(input.after, "before");
|
|
11188
|
+
const style = {
|
|
11189
|
+
...top ? { "--site-style-boundary-before-reserve": top.length } : {},
|
|
11190
|
+
...bottom ? { "--site-style-boundary-after-reserve": bottom.length } : {}
|
|
11191
|
+
};
|
|
11192
|
+
return {
|
|
11193
|
+
topPlacement: top?.placement,
|
|
11194
|
+
bottomPlacement: bottom?.placement,
|
|
11195
|
+
style: top || bottom ? style : void 0
|
|
11196
|
+
};
|
|
11197
|
+
}
|
|
11198
|
+
/** The reserve one join needs on one side of itself, if it draws at all. */
|
|
11199
|
+
function reserveOnSide(slot, side) {
|
|
11200
|
+
const layout = renderedJoinLayout(slot?.join ?? null);
|
|
11201
|
+
const length = layout?.reserves[side] ?? null;
|
|
11202
|
+
return layout && length ? {
|
|
11203
|
+
length,
|
|
11204
|
+
placement: layout.placement
|
|
11205
|
+
} : null;
|
|
11206
|
+
}
|
|
11207
|
+
function pageBlockPosition(index, blockCount) {
|
|
11208
|
+
if (blockCount <= 1) return "only";
|
|
11209
|
+
if (index === 0) return "first";
|
|
11210
|
+
if (index === blockCount - 1) return "last";
|
|
11211
|
+
return "middle";
|
|
11212
|
+
}
|
|
11213
|
+
//#endregion
|
|
11214
|
+
//#region ../blocks/src/pageRendererContracts.ts
|
|
11215
|
+
function buildPageRendererRootRuntime(dataContext) {
|
|
11216
|
+
const { siteId = null, siteName, pageId = null, pathname = null, bookingTimeZone, previewStage = "published", apiBaseUrl = null, portalToken = null, readAuthority, bookingOfferingPresets = [], appointmentServicePathPrefix = null, openingHours, siteTerms, mailingList = { tag: "not_configured" }, loaderFailures = {} } = dataContext ?? {};
|
|
11186
11217
|
return {
|
|
11187
|
-
|
|
11188
|
-
|
|
11218
|
+
siteId,
|
|
11219
|
+
demoEmailSuppressed: resolveDemoEmailSuppression(dataContext),
|
|
11220
|
+
siteName,
|
|
11221
|
+
pageId,
|
|
11222
|
+
pathname,
|
|
11223
|
+
bookingTimeZone,
|
|
11224
|
+
...pageRuntimeContext(dataContext),
|
|
11225
|
+
previewStage,
|
|
11226
|
+
apiBaseUrl,
|
|
11227
|
+
portalToken,
|
|
11228
|
+
readAuthority,
|
|
11229
|
+
bookingOfferingPresets,
|
|
11230
|
+
appointmentServicePathPrefix,
|
|
11231
|
+
openingHours,
|
|
11232
|
+
siteTerms,
|
|
11233
|
+
mailingList,
|
|
11234
|
+
loaderFailures
|
|
11189
11235
|
};
|
|
11190
11236
|
}
|
|
11191
|
-
function
|
|
11192
|
-
|
|
11193
|
-
|
|
11194
|
-
|
|
11237
|
+
function resolveDemoEmailSuppression(dataContext) {
|
|
11238
|
+
return dataContext?.demoEmailSuppressed === true;
|
|
11239
|
+
}
|
|
11240
|
+
function pageRuntimeContext(dataContext) {
|
|
11195
11241
|
return {
|
|
11196
|
-
|
|
11197
|
-
|
|
11242
|
+
dateContext: pageDateRuntimeContext(dataContext),
|
|
11243
|
+
now: dataContext?.now,
|
|
11244
|
+
template: dataContext?.template ?? { kind: "page" }
|
|
11198
11245
|
};
|
|
11199
11246
|
}
|
|
11200
|
-
function
|
|
11201
|
-
|
|
11202
|
-
|
|
11203
|
-
|
|
11204
|
-
|
|
11205
|
-
|
|
11206
|
-
|
|
11207
|
-
|
|
11208
|
-
|
|
11209
|
-
|
|
11210
|
-
|
|
11211
|
-
|
|
11247
|
+
function pageDateRuntimeContext(dataContext) {
|
|
11248
|
+
return dataContext?.dateContext ?? resolveDateRuntimeContext(dataContext?.bookingTimeZone);
|
|
11249
|
+
}
|
|
11250
|
+
//#endregion
|
|
11251
|
+
//#region ../blocks/src/pageRenderAudience.tsx
|
|
11252
|
+
/**
|
|
11253
|
+
* The single policy for what a non-renderable block looks like.
|
|
11254
|
+
*
|
|
11255
|
+
* Public visitors never see renderer diagnostics, so every reason omits.
|
|
11256
|
+
* Authoring surfaces keep the wording they have always had — the strings below
|
|
11257
|
+
* are moved verbatim from the five former `fallback()` call sites.
|
|
11258
|
+
*/
|
|
11259
|
+
function presentNotRenderableBlock(reason, audience) {
|
|
11260
|
+
if (audience === "public") return null;
|
|
11261
|
+
return diagnostic(authoringMessage(reason));
|
|
11262
|
+
}
|
|
11263
|
+
function authoringMessage(reason) {
|
|
11264
|
+
switch (reason.kind) {
|
|
11265
|
+
case "invalid-admission": return `Invalid content for block kind "${reason.blockKind}".`;
|
|
11266
|
+
case "missing-definition": return reason.isCustom ? `No renderer available for block kind "${reason.blockKind}". The custom block definition was not found (missing manifest).` : `No renderer available for block kind "${reason.blockKind}".`;
|
|
11267
|
+
case "missing-layout": return reason.isCustom ? `No renderer available for block kind "${reason.blockKind}". This custom block has no layout/variants, so it must be rendered via blockOverrides["${reason.blockKind}"].` : `No renderer available for block kind "${reason.blockKind}".`;
|
|
11268
|
+
case "editor-unpreviewable":
|
|
11269
|
+
case "render-threw": return `Unable to render block kind "${reason.blockKind}".`;
|
|
11270
|
+
}
|
|
11271
|
+
}
|
|
11272
|
+
/**
|
|
11273
|
+
* The empty-page notice. Authoring-only for the same reason as the block
|
|
11274
|
+
* diagnostics: "No blocks found." is a message for whoever is building the
|
|
11275
|
+
* page, not for whoever is reading it.
|
|
11276
|
+
*/
|
|
11277
|
+
function presentEmptyPage(audience) {
|
|
11278
|
+
if (audience === "public") return null;
|
|
11279
|
+
return diagnostic("No blocks found.");
|
|
11280
|
+
}
|
|
11281
|
+
function diagnostic(message) {
|
|
11282
|
+
return /* @__PURE__ */ jsx("div", {
|
|
11283
|
+
className: "rb-p-6 rb-caption",
|
|
11284
|
+
style: textColorStyle("mutedText"),
|
|
11285
|
+
children: message
|
|
11212
11286
|
});
|
|
11213
11287
|
}
|
|
11214
|
-
|
|
11215
|
-
|
|
11216
|
-
|
|
11217
|
-
|
|
11218
|
-
|
|
11219
|
-
|
|
11288
|
+
//#endregion
|
|
11289
|
+
//#region ../blocks/src/pageRenderDiagnostics.ts
|
|
11290
|
+
/**
|
|
11291
|
+
* Emits one structured record per omitted block, per server render pass.
|
|
11292
|
+
*
|
|
11293
|
+
* Server-only by decision D3: public pages are server-rendered, and this is the
|
|
11294
|
+
* runtime whose logger transport reaches centralised collection. A browser-side
|
|
11295
|
+
* record would not, and re-render/hydration would multiply it. The cost is that
|
|
11296
|
+
* an omission only a client navigation can see goes unlogged.
|
|
11297
|
+
*
|
|
11298
|
+
* Deliberately *not* inside the plan's `useMemo` — React makes no promises about
|
|
11299
|
+
* when a memo recomputes, so a log placed there is neither reliable nor bounded.
|
|
11300
|
+
*/
|
|
11301
|
+
function logOmittedBlocks(plan, dataContext) {
|
|
11302
|
+
if (typeof window !== "undefined") return;
|
|
11303
|
+
if (plan.omitted.length === 0) return;
|
|
11304
|
+
const page = {
|
|
11305
|
+
siteId: dataContext?.siteId ?? null,
|
|
11306
|
+
pageId: dataContext?.pageId ?? null
|
|
11220
11307
|
};
|
|
11308
|
+
if (plan.entries.length === 0) {
|
|
11309
|
+
logger.error("blocks.pageRenderer.pageFullyOmitted", {
|
|
11310
|
+
...page,
|
|
11311
|
+
omittedCount: plan.omitted.length,
|
|
11312
|
+
blocks: plan.omitted.map((omission) => ({
|
|
11313
|
+
blockId: omission.blockId,
|
|
11314
|
+
blockKind: omission.blockKind,
|
|
11315
|
+
reason: omission.reason.kind
|
|
11316
|
+
}))
|
|
11317
|
+
});
|
|
11318
|
+
debugOmittedCustomBlocks(plan);
|
|
11319
|
+
return;
|
|
11320
|
+
}
|
|
11321
|
+
for (const omission of plan.omitted) logger.warn("blocks.pageRenderer.blockOmitted", {
|
|
11322
|
+
...page,
|
|
11323
|
+
blockId: omission.blockId,
|
|
11324
|
+
blockKind: omission.blockKind,
|
|
11325
|
+
reason: omission.reason.kind,
|
|
11326
|
+
admissionError: omission.reason.kind === "invalid-admission" ? omission.reason.error.kind : null
|
|
11327
|
+
});
|
|
11328
|
+
debugOmittedCustomBlocks(plan);
|
|
11221
11329
|
}
|
|
11222
|
-
|
|
11223
|
-
|
|
11224
|
-
|
|
11225
|
-
|
|
11226
|
-
|
|
11227
|
-
|
|
11228
|
-
|
|
11229
|
-
|
|
11230
|
-
|
|
11231
|
-
|
|
11232
|
-
|
|
11233
|
-
}
|
|
11234
|
-
function renderBlock(manifest, content, options = {}) {
|
|
11235
|
-
const variantKey = resolveBlockVariantKey(manifest, content);
|
|
11236
|
-
if (!resolveBlockLayout(manifest, variantKey)) throw new Error(`Block manifest "${manifest.name}" requires a layout definition`);
|
|
11237
|
-
const Component = makeDefaultBlockComponent({ manifest });
|
|
11238
|
-
const resolvedRegistry = options.registry ?? getDefaultComponentRegistry();
|
|
11239
|
-
const resolvedTheme = options.theme ?? defaultThemeTokens;
|
|
11240
|
-
const cleanKind = manifest.name.replace(/^block\./, "");
|
|
11241
|
-
const componentElement = React.createElement(Component, {
|
|
11242
|
-
now: options.now,
|
|
11243
|
-
dateContext: options.dateContext,
|
|
11244
|
-
content,
|
|
11245
|
-
data: options.data,
|
|
11246
|
-
registry: resolvedRegistry,
|
|
11247
|
-
theme: resolvedTheme,
|
|
11248
|
-
themeConfig: options.themeConfig,
|
|
11249
|
-
transforms: options.transforms,
|
|
11250
|
-
viewModelOverrides: options.viewModelOverrides,
|
|
11251
|
-
pathBase: options.pathBase,
|
|
11252
|
-
blockId: null,
|
|
11253
|
-
blockKind: manifest.name
|
|
11330
|
+
/**
|
|
11331
|
+
* Unlike the plan-time omissions this one genuinely can fire per re-render —
|
|
11332
|
+
* it is raised where the failure happens, and no once-ness is claimed for it.
|
|
11333
|
+
*/
|
|
11334
|
+
function logRenderThrew(block, dataContext) {
|
|
11335
|
+
if (typeof window !== "undefined") return;
|
|
11336
|
+
logger.warn("blocks.pageRenderer.blockRenderThrew", {
|
|
11337
|
+
siteId: dataContext?.siteId ?? null,
|
|
11338
|
+
pageId: dataContext?.pageId ?? null,
|
|
11339
|
+
blockId: block.id ?? null,
|
|
11340
|
+
blockKind: block.kind
|
|
11254
11341
|
});
|
|
11255
|
-
if (manifest.behaviours?.managesOwnWrapper) return componentElement;
|
|
11256
|
-
const styleGroup = typeof content.styleGroup === "string" ? content.styleGroup : void 0;
|
|
11257
|
-
const blockLook = typeof content.blockLook === "string" ? content.blockLook : void 0;
|
|
11258
|
-
const blockComposition = readBlockComposition(content.blockComposition);
|
|
11259
|
-
return React.createElement("div", {
|
|
11260
|
-
className: `block-${cleanKind}`,
|
|
11261
|
-
"data-block": cleanKind,
|
|
11262
|
-
"data-block-kind": manifest.name,
|
|
11263
|
-
...variantKey ? {
|
|
11264
|
-
"data-block-variant": variantKey,
|
|
11265
|
-
"data-variant": variantKey
|
|
11266
|
-
} : {},
|
|
11267
|
-
...blockLook ? { "data-block-look": blockLook } : {},
|
|
11268
|
-
...arrangementHooksFromContent(content),
|
|
11269
|
-
...blockComposition ? {
|
|
11270
|
-
"data-block-composition": blockComposition.treatment,
|
|
11271
|
-
"data-block-composition-kind": blockComposition.kind
|
|
11272
|
-
} : {},
|
|
11273
|
-
...styleGroup ? { "data-style-group": styleGroup } : {}
|
|
11274
|
-
}, componentElement);
|
|
11275
11342
|
}
|
|
11276
|
-
/**
|
|
11277
|
-
|
|
11278
|
-
|
|
11279
|
-
|
|
11343
|
+
/**
|
|
11344
|
+
* Opt-in developer affordance for tracking down custom-block resolution.
|
|
11345
|
+
*
|
|
11346
|
+
* Driven off the plan's omissions so it stays reachable on **public** renders —
|
|
11347
|
+
* "my custom block doesn't show up on the live site" is the exact situation it
|
|
11348
|
+
* exists for, and that is the render where the block is now silently absent.
|
|
11349
|
+
*/
|
|
11350
|
+
function debugOmittedCustomBlocks(plan) {
|
|
11351
|
+
if (!shouldDebugCustomBlocks()) return;
|
|
11352
|
+
for (const omission of plan.omitted) {
|
|
11353
|
+
if (!omission.blockKind.startsWith("custom.")) continue;
|
|
11354
|
+
debugCustomBlockResolution(omission.reason.kind, omission.blockId, omission.blockKind, omission.debug);
|
|
11355
|
+
}
|
|
11356
|
+
}
|
|
11357
|
+
/** The authoring-side equivalent, where the block stays in the entry list. */
|
|
11358
|
+
function debugCustomBlockDiagnostic(reason, block, debug) {
|
|
11359
|
+
if (!block.kind.startsWith("custom.") || !shouldDebugCustomBlocks()) return;
|
|
11360
|
+
debugCustomBlockResolution(reason.kind, block.id ?? null, block.kind, debug);
|
|
11361
|
+
}
|
|
11362
|
+
function debugCustomBlockResolution(reasonKind, blockId, blockKind, debug) {
|
|
11363
|
+
try {
|
|
11364
|
+
console.warn(reasonKind === "missing-definition" ? "[blocks:PageRenderer] custom block definition missing" : "[blocks:PageRenderer] custom block has no layout/variants and no override", {
|
|
11365
|
+
blockId,
|
|
11366
|
+
blockKind,
|
|
11367
|
+
hasOverride: debug.hasOverride,
|
|
11368
|
+
sdkCustomBlocksCount: debug.sdkCustomBlocksCount,
|
|
11369
|
+
dbCustomBlocksCount: debug.dbCustomBlocksCount,
|
|
11370
|
+
manifestKeys: debug.manifestKeys
|
|
11371
|
+
});
|
|
11372
|
+
} catch {}
|
|
11373
|
+
}
|
|
11374
|
+
function shouldDebugCustomBlocks() {
|
|
11375
|
+
try {
|
|
11376
|
+
return globalThis.process?.env?.DEBUG_CUSTOM_BLOCKS === "1";
|
|
11377
|
+
} catch {
|
|
11378
|
+
return false;
|
|
11379
|
+
}
|
|
11280
11380
|
}
|
|
11281
11381
|
//#endregion
|
|
11282
11382
|
//#region ../blocks/src/system/blocks/offerings-preview/photoCount.ts
|
|
@@ -11485,13 +11585,14 @@ function planNewsletterPreviewSubmission(placement) {
|
|
|
11485
11585
|
* stays at the edge (decision D3), matching `buildPageRenderPlan`.
|
|
11486
11586
|
*/
|
|
11487
11587
|
function preparePageRender(input) {
|
|
11488
|
-
const
|
|
11489
|
-
|
|
11490
|
-
|
|
11491
|
-
|
|
11492
|
-
|
|
11493
|
-
|
|
11494
|
-
|
|
11588
|
+
const facts = readinessFactsFromLoaders("published", {
|
|
11589
|
+
prefetched: input.dataContext?.prefetchedBlockData,
|
|
11590
|
+
previewStage: input.dataContext?.previewStage,
|
|
11591
|
+
mailingList: input.dataContext?.mailingList,
|
|
11592
|
+
template: input.dataContext?.template ?? pageTemplateFromEntry(input.dataContext?.contentEntry)
|
|
11593
|
+
});
|
|
11594
|
+
const entries = input.plan.entries.filter((entry) => input.audience === "authoring" || !entryNeedsSetup(entry, facts)).map((entry) => preparedPlanEntry(entry, prepareEntry(entry, input)));
|
|
11595
|
+
const constructionFailures = entries.filter(({ prepared }) => prepared.kind === "render-threw").map(({ entry }) => entry);
|
|
11495
11596
|
const survivors = input.audience === "authoring" ? entries : entries.filter((candidate) => candidate.prepared.kind !== "render-threw");
|
|
11496
11597
|
return {
|
|
11497
11598
|
entries: survivors,
|
|
@@ -11505,6 +11606,9 @@ function preparePageRender(input) {
|
|
|
11505
11606
|
* same primitive, so `[A, B, C]` losing B still gets an A→C join. Each
|
|
11506
11607
|
* survivor is then classified from its final content.
|
|
11507
11608
|
*/
|
|
11609
|
+
function entryNeedsSetup(entry, facts) {
|
|
11610
|
+
return entry.kind === "renderable" && entry.definition.readiness?.assess(entry.renderableContent, facts).kind === "NeedsSetup";
|
|
11611
|
+
}
|
|
11508
11612
|
function composeSurvivorJoins(plan, survivors, themeResources) {
|
|
11509
11613
|
return composePageJoins({
|
|
11510
11614
|
joins: retargetJoinsAcrossOmissions({
|
|
@@ -12213,7 +12317,8 @@ function usePageDateRuntime(props) {
|
|
|
12213
12317
|
const dateContext = React$1.useMemo(() => supplied ?? resolveDateRuntimeContext(zone), [supplied, zone]);
|
|
12214
12318
|
const dataContext = React$1.useMemo(() => props.dataContext ? {
|
|
12215
12319
|
...props.dataContext,
|
|
12216
|
-
dateContext
|
|
12320
|
+
dateContext,
|
|
12321
|
+
template: props.dataContext.template ?? pageTemplateFromEntry(props.dataContext.contentEntry)
|
|
12217
12322
|
} : void 0, [props.dataContext, dateContext]);
|
|
12218
12323
|
return {
|
|
12219
12324
|
...props,
|
|
@@ -12417,7 +12522,11 @@ function buildPageRouteRenderContext(dataContext) {
|
|
|
12417
12522
|
pageSurface: dataContext.pageSurface ?? null,
|
|
12418
12523
|
subject: dataContext.subject ?? null,
|
|
12419
12524
|
editableRouteMetadataFieldIds: dataContext.editableRouteMetadataFieldIds ?? null,
|
|
12420
|
-
previewStage: dataContext.previewStage
|
|
12525
|
+
previewStage: dataContext.previewStage,
|
|
12526
|
+
prefetchedBlockData: dataContext.prefetchedBlockData,
|
|
12527
|
+
loaderSnapshot: dataContext.loaderSnapshot,
|
|
12528
|
+
loaderFailures: dataContext.loaderFailures,
|
|
12529
|
+
template: pageTemplateFromEntry(dataContext.contentEntry)
|
|
12421
12530
|
};
|
|
12422
12531
|
}
|
|
12423
12532
|
function buildPageIdentityRenderContext(dataContext) {
|