@riverbankcms/sdk 0.167.0 → 0.168.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/dist/_dts/{BlocksIslandsHydrator-Dgb-ptph.d.ts → BlocksIslandsHydrator-CiD_VVGM.d.ts} +1 -1
- package/dist/_dts/{Page-Bs3WxFgr.d.ts → Page-Bj6VJRS5.d.ts} +7 -6
- package/dist/_dts/{SdkPreviewMode-DtUCsaHY.d.ts → SdkPreviewMode-ChpsnwDX.d.ts} +2 -2
- package/dist/_dts/{client-CwsI23pj.d.ts → client-C8mfUxrJ.d.ts} +65 -35
- package/dist/_dts/{content-types-CAeP_-cV.d.ts → content-types-_vXZyR4H.d.ts} +2 -2
- package/dist/_dts/{contracts-BXHCiF-b.d.ts → contracts-CJFfrVKU.d.ts} +5 -4
- package/dist/_dts/{footerPageOutline-Bb2gbppW.d.ts → footerPageOutline-CMegb23G.d.ts} +6 -6
- package/dist/_dts/{generatePageMetadata-DaBBDx7M.d.ts → generatePageMetadata-D9YdAIMh.d.ts} +2 -2
- package/dist/_dts/{index-CS6b1B-c.d.ts → index-BQXaZ7aY.d.ts} +4 -4
- package/dist/_dts/{index-5_jf52sZ.d.ts → index-Bpr-wT5k.d.ts} +2 -2
- package/dist/_dts/{index-DeHDwMfu.d.ts → index-C7_Rz8EY.d.ts} +3 -3
- package/dist/_dts/{index-D7EbliE3.d.ts → index-Cx2BQlHL.d.ts} +3 -3
- package/dist/_dts/{index-C20yUyob.d.ts → index-Dgz6yhsy.d.ts} +1 -1
- package/dist/_dts/index-Vh8B9FSa.d.ts +14 -0
- package/dist/_dts/{index-bDln38Hm.d.ts → index-vR3p9Bu-.d.ts} +2 -2
- package/dist/_dts/{loadContent-CTqcL7CS.d.ts → loadContent-dhWSgLeS.d.ts} +7 -7
- package/dist/_dts/previewCompiler-BVVgDSdq.d.ts +1 -0
- package/dist/_dts/{index-ChpjHK0U.d.ts → request-BrYhNV9Z.d.ts} +80718 -47665
- package/dist/_dts/{resolveBlockData-C3s9WMPs.d.ts → resolveBlockData-BfSHm8Ms.d.ts} +5 -5
- package/dist/_dts/{resolvePageContent-JPwgRxwh.d.ts → resolvePageContent-gZJ4i1wN.d.ts} +2 -2
- 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 +7 -7
- 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/data/dataLoaderContext.d.ts +2 -2
- package/dist/_dts/sdk/src/data/resolveBlockData.d.ts +1 -1
- package/dist/_dts/sdk/src/data/types.d.ts +2 -2
- package/dist/_dts/sdk/src/index.d.ts +8 -8
- package/dist/_dts/sdk/src/manifest/index.d.ts +3 -3
- 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 +3 -3
- 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/components/pageShared.d.ts +1 -1
- package/dist/_dts/sdk/src/rendering/helpers/loadPage.d.ts +1 -1
- package/dist/_dts/sdk/src/rendering/helpers/pageRuntimeSupport.d.ts +4 -5
- 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/rendering/themeAdmission.d.ts +1 -1
- 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/spam-protection/index.d.ts +2 -2
- package/dist/_dts/sdk/src/theme/index.d.ts +1 -1
- package/dist/_dts/{types-CwtTcaQP.d.ts → types-BB33-Spd.d.ts} +3 -3
- package/dist/_dts/{types-D-WElMCy.d.ts → types-BVFXYtRg.d.ts} +7 -7
- package/dist/_dts/{types-BlaCuPLr.d.ts → types-FOsJ-KYb.d.ts} +4 -2
- package/dist/_dts/{validation-Y5wD9fGK.d.ts → validation-DckTc6TQ.d.ts} +4 -4
- package/dist/client/{BlocksIslandsHydrator-DFqkx158.mjs → BlocksIslandsHydrator-DcwEaliO.mjs} +21 -21
- package/dist/client/BookingMailingListNote-Dsugoe-n.mjs +946 -0
- package/dist/client/BookingQuestionFields-Bhh0cvsl.mjs +359 -0
- package/dist/client/{CalendarNavigationChevron-DQwJ7BPx.mjs → CalendarNavigationChevron-CNe3ZjdC.mjs} +7 -7
- package/dist/client/{CheckboxChoice-CZ-anOqV.mjs → CheckboxChoice-W_uiRgDK.mjs} +1 -1
- package/dist/client/{DemoBookingPortalAccess-DdkY86qI.mjs → DemoBookingPortalAccess-BeiZxEUJ.mjs} +7 -7
- package/dist/client/{EventCalendar.client-DAeQPV76.mjs → EventCalendar.client-BL943-tl.mjs} +9 -9
- package/dist/client/{EventCombined.client-Bus9R0bj.mjs → EventCombined.client-BFVxECTp.mjs} +8 -8
- package/dist/client/{EventEmbeddedCheckoutStep-D_14yqAU.mjs → EventEmbeddedCheckoutStep-Cf-HRHtb.mjs} +1 -1
- package/dist/client/{EventItem-DPBLjGwj.mjs → EventItem-BIc4gjiD.mjs} +37 -15
- package/dist/client/{EventListWeekNavigation-D6cwU82_.mjs → EventListWeekNavigation-a0QEIEf0.mjs} +1 -1
- package/dist/client/{EventListing.client-Bogi_SnJ.mjs → EventListing.client-CEFTC3jH.mjs} +3 -3
- package/dist/client/{EventListing.view-CEumpN7i.mjs → EventListing.view-Bt2sBBms.mjs} +34 -16
- package/dist/client/{EventRegistrationPayment-CIQw6vNy.mjs → EventRegistrationPayment-D9YBNb_E.mjs} +250 -40
- package/dist/client/{LocationMapActions-BVO-qx4q.mjs → LocationMapActions-gqzt5gkW.mjs} +2 -2
- package/dist/client/{MapDrawingSvg-CcGaFawl.mjs → MapDrawingSvg-13JQI7_z.mjs} +1 -1
- package/dist/client/{Page-D4_H_u9V.mjs → Page-D_M2Vxz3.mjs} +4471 -1601
- package/dist/client/{ProtectedSubmitButton-8DuDw2ag.mjs → ProtectedSubmitButton-C3H26pN9.mjs} +1 -1
- package/dist/client/{StepIndicator-Dptantmg.mjs → StepIndicator-CaN8snZ8.mjs} +3 -3
- package/dist/client/{TabBarFragment-BxEGsKUx.mjs → TabBarFragment-DkVKtK5a.mjs} +1 -1
- package/dist/client/{ThemedButton-8jUc02mZ.mjs → ThemedButton-BdnEwA38.mjs} +2 -5
- package/dist/client/accessibleSurfaces-chpD4C2c.mjs +4278 -0
- package/dist/client/{accordion--EUHmEGa.mjs → accordion-DE7OG--d.mjs} +1 -1
- package/dist/client/{booking-form.client-BCXwOnhc.mjs → booking-form.client-CS1PPjw7.mjs} +842 -374
- package/dist/client/{bookingForm-sHHcdism.mjs → bookingForm-DE2CwIU9.mjs} +5 -4
- package/dist/client/{src-DjnxOjXG.mjs → bookingQuestionValues-BjcyCru5.mjs} +88 -1
- package/dist/client/bookingQuestions-BHq83mzS.mjs +13 -0
- package/dist/client/bookings.mjs +18 -13
- package/dist/client/{carousel-Cp9xPBFZ.mjs → carousel-DZyUdnFh.mjs} +3 -3
- package/dist/client/{carousel.client-BO7sCEpH.mjs → carousel.client-BD4DXMtI.mjs} +62 -16
- package/dist/client/{carousel.shared-DBnWEJzo.mjs → carousel.shared-BFQ3kBEw.mjs} +6 -3
- package/dist/client/{cart-CCZZC-Lq.mjs → cart-D7HkkNwe.mjs} +3 -3
- package/dist/client/{cart.client-B7JfA19I.mjs → cart.client-H4sv2TpD.mjs} +1 -1
- package/dist/client/{checkout-CipmYL4A.mjs → checkout-2qVyG-Sh.mjs} +3 -3
- package/dist/client/{checkout.client-DraalWdH.mjs → checkout.client-DAjrBZ74.mjs} +1 -1
- package/dist/client/client.mjs +240 -63
- package/dist/client/{context-Cv3QHjAF.mjs → context-DXmIbXCK.mjs} +297 -3
- package/dist/client/{cta-P2vJVTEn.mjs → cta-DP_IBnq3.mjs} +2 -2
- package/dist/client/{dateFormatting-D8D47VT4.mjs → dateFormatting-CwrkFZTr.mjs} +1 -1
- package/dist/client/{demoPortalMagicLink-CXWZoV-d.mjs → demoPortalMagicLink-DQXK-Fh6.mjs} +1 -1
- package/dist/client/{enhanceHeaderSection-BkAro1DJ.mjs → enhanceHeaderSection-DheQj7rg.mjs} +3 -3
- package/dist/client/{event-details.client-dLmyuPap.mjs → event-details.client-C5UufcRp.mjs} +1 -1
- package/dist/client/{event-registration.client-BEhC2_-Y.mjs → event-registration.client-CMGg63IU.mjs} +72 -235
- package/dist/client/{eventCalendar-FBMS2Cpb.mjs → eventCalendar-DlD0GCEy.mjs} +4 -4
- package/dist/client/{eventCombined-BrBhUvGe.mjs → eventCombined-DoSi8p_l.mjs} +4 -4
- package/dist/client/{eventDetails-C7WUrbZ2.mjs → eventDetails-DzuQYgmO.mjs} +2 -2
- package/dist/client/{eventListing-Bih-BgQM.mjs → eventListing-CkiMjl0g.mjs} +4 -4
- package/dist/client/{eventRegistration-DfTlqGbl.mjs → eventRegistration-CjS3Zpjp.mjs} +4 -4
- package/dist/client/{form-Bw1uuiUs.mjs → form-DgQqm7T2.mjs} +3 -3
- package/dist/client/{form.client-pZ-9gN33.mjs → form.client-BI9Dcsq5.mjs} +5 -5
- package/dist/client/{form.parts-PXlu6XQO.mjs → form.parts-DevF0L_A.mjs} +3 -3
- package/dist/client/{formatDate-DI3DP48e.mjs → formatDate-DDyURjoe.mjs} +1 -1
- package/dist/client/gifting/client.mjs +3 -3
- package/dist/client/{headerSection-BpJYUMd6.mjs → headerSection-DYIG6Pwb.mjs} +2 -2
- package/dist/client/{mediaAssets-DpPauppt.mjs → mediaAssets-B99AP7ai.mjs} +1 -1
- package/dist/client/{mediaContext-BLo4NtjP.mjs → mediaContext-Fusweriw.mjs} +1 -1
- package/dist/client/{newsletter-form.client-CSoP0cGR.mjs → newsletter-form.client-BWp7Y1e1.mjs} +6 -6
- package/dist/client/{newsletter-form.parts-DDbX_Sj0.mjs → newsletter-form.parts-Dg8s9NwJ.mjs} +2 -2
- package/dist/client/{newsletterForm-vCxYRar_.mjs → newsletterForm-DnPraMzx.mjs} +3 -3
- package/dist/client/{noop-ByVtIWf4.mjs → noop-ByFRHYQ2.mjs} +437 -496
- package/dist/client/portal/client.mjs +76 -229
- package/dist/client/{product-detail.client-7Pi6avM-.mjs → product-detail.client-BFAgHrdg.mjs} +1 -1
- package/dist/client/{product-list.client-DEad-Pma.mjs → product-list.client-DVrs_DyY.mjs} +1 -1
- package/dist/client/{productDetail-G1SMXG13.mjs → productDetail-D4rvl6Xg.mjs} +3 -3
- package/dist/client/{productList-B21TGdpT.mjs → productList-B8o5AOMX.mjs} +3 -3
- package/dist/client/{propsDecoder-B3vIBkex.mjs → propsDecoder-hhotPP6P.mjs} +5 -4
- package/dist/client/{registry.server-B8aQhJpO.mjs → registry.server-Ch3EpupA.mjs} +2213 -2433
- package/dist/client/{surfaceTransportMarker-BXepAVF6.mjs → renderableMediaAssetAdmission-BlfqYLJW.mjs} +1 -18
- package/dist/client/rendering/client.mjs +30 -30
- package/dist/client/rendering/islands.mjs +1 -1
- package/dist/client/rendering.mjs +10 -9
- package/dist/client/{richText-coerce-DHkBtO0G.mjs → richText-coerce-C3LabQ1O.mjs} +1 -1
- package/dist/client/{routeIslandApiConfig-DbHX4JOS.mjs → routeIslandApiConfig-CQGlxId8.mjs} +1 -1
- package/dist/client/runtimeResponse-BP-L6exS.mjs +3 -0
- package/dist/client/runtimeResponse-Dg4XFsuM.mjs +9 -0
- package/dist/client/{shop-commerce-B2UmrQg_.mjs → shop-commerce-VDbVaKY-.mjs} +12 -12
- package/dist/client/{shop-commerce-store-B7n-Z7nY.mjs → shop-commerce-store-DqdgJ8Zw.mjs} +1 -1
- package/dist/client/{shop-mqyoOvOK.mjs → shop-rRXplPGZ.mjs} +3 -3
- package/dist/client/{shop.client-BH-BBnA9.mjs → shop.client-DdwvMvaK.mjs} +13 -13
- package/dist/client/{shop.interactive-mdM3UMWG.mjs → shop.interactive-C8OvFY06.mjs} +141 -66
- package/dist/client/{shopShared-CXF5wxdg.mjs → shopShared-BeuJiGPU.mjs} +2 -2
- package/dist/client/spam-protection.mjs +1 -1
- package/dist/client/surfaceTransportMarker-BuwkYxsI.mjs +19 -0
- package/dist/client/{timetableModel-CrC80EOG.mjs → timetableModel-Cko9LRKy.mjs} +11 -11
- package/dist/client/{types-sF-IrGQr.mjs → types-5fOsPIpL.mjs} +248 -111
- package/dist/client/{useAvailableSlots-C4LOaI_Z.mjs → useAvailableSlots-M6QIEiWf.mjs} +3 -3
- package/dist/client/{useDiscountApply-6Q0nToVA.mjs → useDiscountApply-BJSnyO0f.mjs} +3 -3
- package/dist/client/{useDiscountCodeUi-CM-DTX5X.mjs → useDiscountCodeUi-D3XnOSCi.mjs} +1 -1
- package/dist/client/{useEventPagination-Bcs89BR5.mjs → useEventPagination-PhTIoFVX.mjs} +7 -7
- package/dist/client/{view-BN-fxyfq.mjs → view-448wvvEY.mjs} +11 -7
- package/dist/client/{view-Dh2tGoS0.mjs → view-L_mkgtnk.mjs} +4 -4
- package/dist/client/{site-styles-D56hT2u1.mjs → wizardSteps-CFulHWnT.mjs} +19660 -18565
- package/dist/preview-next/client/{ArrangementLookControls-D4VjPs-r.mjs → ArrangementLookControls-BpvnOGlN.mjs} +26 -17
- package/dist/preview-next/client/{EventEmbeddedCheckoutStep-C_h1cMYm.mjs → EventEmbeddedCheckoutStep-8-qtHjpb.mjs} +1 -1
- package/dist/preview-next/client/{LocationPickerEnvironment-D56RD3e_.mjs → LocationPickerEnvironment-CZQ4vkRe.mjs} +1 -1
- package/dist/preview-next/client/{MapLibreEditMap-DFnyCckr.mjs → MapLibreEditMap-CP4w7T_0.mjs} +2 -2
- package/dist/preview-next/client/{PreviewEditorSidebar-Ckr2zk_L.mjs → PreviewEditorSidebar-C0OtdWu_.mjs} +128 -21
- package/dist/preview-next/client/{PreviewEditorUI-KOZgw_gS.mjs → PreviewEditorUI-Csc5vH5k.mjs} +6 -6
- package/dist/preview-next/client/{PreviewShell-CyO2V4kB.mjs → PreviewShell-BOLH_pm-.mjs} +199 -155
- package/dist/preview-next/client/{SdkPreviewModeRuntime-DW3uKvNF.mjs → SdkPreviewModeRuntime-CKodLReY.mjs} +31 -32
- package/dist/preview-next/client/{SiteChromeCustomizeButton-CU9VD-7O.mjs → SiteChromeCustomizeButton-BeEZpeKn.mjs} +3780 -3436
- package/dist/preview-next/client/{ThemedButton-C0dgGJ5k.mjs → ThemedButton-BQU45t-E.mjs} +260 -121
- package/dist/preview-next/client/{lucide-react-CPBCf6QT.mjs → lucide-react-DkZ8fO-G.mjs} +1 -1
- package/dist/preview-next/client/{previewAssistantSlot-DBi-WybM.mjs → previewAssistantSlot-BBdN5kfY.mjs} +18697 -15557
- package/dist/preview-next/client/{previewChromeSurface-BhkUJst9.mjs → previewChromeSurface-VZtGwPuH.mjs} +1 -1
- package/dist/preview-next/client/runtime.mjs +3 -3
- package/dist/preview-next/client/{sdk-runtime-BjCb6lOn.mjs → sdk-runtime-kiZkMcuR.mjs} +2 -2
- package/dist/preview-next/client/{useAutosaveStatus-CKxTaC3j.mjs → useAutosaveStatus-BiIHEeE0.mjs} +2 -2
- package/dist/preview-next/client/{useBlockCustomizeControls-B7MLTjBX.mjs → useBlockCustomizeControls-BuFLIpmX.mjs} +2 -2
- package/dist/preview-next/client/{useOpenBlockForSetup-BTUc0g9X.mjs → useOpenBlockForSetup-DlxYgmh_.mjs} +1 -1
- package/dist/preview-next/keepAlive.mjs +1 -1
- package/dist/preview-next/middleware.mjs +1 -1
- package/dist/preview-next/{route-contract-Bv3nkdpV.mjs → route-contract-C0sCvCYL.mjs} +165 -0
- package/dist/server/{Block.shared-4fMqzltx.mjs → Block.shared-Dnhc0Wu5.mjs} +5 -5
- package/dist/server/{ThemeScopeCore-C72VC_lR.mjs → ThemeScopeCore-NAQ_zsFu.mjs} +461 -128
- package/dist/server/{accessibleSurfaces-B_Y_dA20.mjs → accessibleSurfaces-108nxyGc.mjs} +319 -131
- package/dist/server/{bindings-ConMYJ2U.mjs → bindings-DLoZYUxG.mjs} +2 -2
- package/dist/server/{client-Cot-H5fQ.mjs → client-Bc8jI8zN.mjs} +261 -61
- package/dist/server/config-validation.mjs +1 -1
- package/dist/server/config.mjs +1 -1
- package/dist/server/{validation-CDd6m8Ry.mjs → customCss-QymcmOZ-.mjs} +12 -55
- package/dist/server/data/resolveBlockData.mjs +1 -1
- package/dist/server/headerVariant-BwR9NV4b.mjs +463 -0
- package/dist/server/{identity-Bn9OQiT1.mjs → identity-20XHqyuO.mjs} +1 -1
- package/dist/server/index.mjs +3 -3
- package/dist/server/{loadContent-BkaWYEwt.mjs → loadContent-D61gpqHB.mjs} +4 -5
- package/dist/server/{loadPage-kviUdH8c.mjs → loadPage-B4ZYpIcd.mjs} +2 -2
- package/dist/server/manifest.mjs +1 -1
- package/dist/server/{media-DnlczCMA.mjs → media-Brn9FW5s.mjs} +15 -1
- package/dist/server/{mode-Cv_TG9gP.mjs → mode-bkFS8glh.mjs} +4 -2
- package/dist/server/next.mjs +6 -6
- package/dist/server/{opaqueSurface-BTnS09GS.mjs → opaqueSurface-BawlEAd_.mjs} +6 -6
- package/dist/server/{overrideResolution-itXZCXs7.mjs → overrideResolution-CDReKy2P.mjs} +1 -1
- package/dist/server/page-converter.mjs +3 -3
- package/dist/server/{pageRenderPlan-CDyn7iLy.mjs → pageRenderPlan-ByVTA7-4.mjs} +255 -158
- package/dist/server/{pageRuntimeSupport-DZ6cLxrM.mjs → pageRuntimeSupport-Dzz_Dze6.mjs} +291 -5
- package/dist/server/{pageShared-Q_Vij87H.mjs → pageShared-Dk5Ku6hs.mjs} +1285 -897
- package/dist/server/{schema-DEizlyi4.mjs → parseThemeForPersistence-pJPGfMrf.mjs} +593 -1592
- package/dist/server/{prebuild-DOG4MkOy.mjs → prebuild-CW4M0WEZ.mjs} +1 -1
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/{prefetchBlockData-DlprLLsc.mjs → prefetchBlockData-Bvx0SiIM.mjs} +5 -4
- package/dist/server/{registry-BPFcpn6k.mjs → registry-Bh0Y25zH.mjs} +4399 -4065
- package/dist/server/rendering/components/pageShared.mjs +1 -1
- package/dist/server/rendering/helpers/loadPage.mjs +1 -1
- package/dist/server/rendering/helpers/pageRuntimeSupport.mjs +1 -1
- package/dist/server/rendering/server.mjs +3 -3
- package/dist/server/rendering.mjs +8 -8
- package/dist/server/{resolveBlockData-BHvfGD4y.mjs → resolveBlockData-CnHHst9r.mjs} +1 -1
- package/dist/server/{resolveButtonColourStates-OXFRGn5M.mjs → resolveButtonColourStates-Cn6j8Ee0.mjs} +399 -518
- package/dist/server/{responseMedia-D8J3VAFs.mjs → responseMedia-t6gs0cB7.mjs} +2 -2
- package/dist/server/{richTextSchema-Euhuj-7V.mjs → richTextSchema-DQ2NBP0n.mjs} +5 -16
- package/dist/server/server.mjs +3 -3
- package/dist/server/theme-bridge.mjs +2 -3
- package/dist/server/theme.mjs +1 -2
- package/dist/server/{three-pass-converter-_j2UE2tR.mjs → three-pass-converter-CQWdnfjV.mjs} +1 -1
- package/dist/server/{validation-bl6WcAi_.mjs → validation-D2bHWSxJ.mjs} +57 -8
- package/dist/server/{version-BLXZ31S-.mjs → version-DkM1eAxG.mjs} +1 -1
- package/dist/styles/index.css +340 -68
- package/package.json +4 -3
- package/dist/_dts/index-CXsnaCGe.d.ts +0 -10
- package/dist/_dts/index-RugyUnqR.d.ts +0 -31535
- package/dist/client/BookingMailingListNote-CCVXX1LN.mjs +0 -331
- package/dist/client/DemoPortalSignInLink-B9YrzZt2.mjs +0 -19
- package/dist/client/site-styles-CMCUxsIM.mjs +0 -3
- package/dist/client/useBookingNowIso-BDmWkYUW.mjs +0 -58
- package/dist/client/wizardSteps-DtkhwKXK.mjs +0 -6933
- package/dist/server/parseThemeForPersistence-CDrF51tJ.mjs +0 -52
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import { Ar as arrangementModes, Ia as runtimeMediaSchema } from "./site-styles-D56hT2u1.mjs";
|
|
2
|
+
import { a as mediaIdentifierSchema, d as parseUuidBrand, f as err, n as renderableMediaAssetSchema, p as ok } from "./renderableMediaAssetAdmission-BlfqYLJW.mjs";
|
|
4
3
|
import { c as addMonths } from "./src-1PJxc8KO.mjs";
|
|
5
4
|
import { z } from "zod";
|
|
6
5
|
//#region ../core/src/branded/customers.ts
|
|
@@ -1005,25 +1004,250 @@ const SURFACE_EVENT_PRESET_VALUES = [
|
|
|
1005
1004
|
"performance"
|
|
1006
1005
|
];
|
|
1007
1006
|
//#endregion
|
|
1008
|
-
//#region ../
|
|
1009
|
-
/**
|
|
1010
|
-
* Strict record guard: excludes null, primitives, and arrays.
|
|
1011
|
-
*/
|
|
1007
|
+
//#region ../core/src/record-guards.ts
|
|
1012
1008
|
function isRecord(value) {
|
|
1013
1009
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
1014
1010
|
}
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1011
|
+
//#endregion
|
|
1012
|
+
//#region ../site-contracts/src/siteData/eventQueries.ts
|
|
1013
|
+
const eventSurfacePresetValues = SURFACE_EVENT_PRESET_VALUES;
|
|
1014
|
+
const eventSurfaceScopeValues = [
|
|
1015
|
+
"all",
|
|
1016
|
+
"regularClassSchedule",
|
|
1017
|
+
"specialDatedEvents",
|
|
1018
|
+
"custom"
|
|
1019
|
+
];
|
|
1020
|
+
const eventScheduleScopeValues = [
|
|
1021
|
+
"any",
|
|
1022
|
+
"recurring",
|
|
1023
|
+
"oneOff"
|
|
1024
|
+
];
|
|
1025
|
+
/** Runtime picker sentinels and bound loader IDs must describe the same query. */
|
|
1026
|
+
function normalizeCalendarFilterId(value) {
|
|
1027
|
+
const id = value?.trim();
|
|
1028
|
+
return !id || id === "all" ? void 0 : id;
|
|
1029
|
+
}
|
|
1030
|
+
const calendarMonthSchema = z.string().regex(/^\d{4}-(0[1-9]|1[0-2])$/).refine((month) => Number(month.slice(0, 4)) > 0, "Invalid calendar year");
|
|
1031
|
+
function calendarMonthDate(month) {
|
|
1032
|
+
return {
|
|
1033
|
+
year: Number(month.slice(0, 4)),
|
|
1034
|
+
month: Number(month.slice(5, 7)),
|
|
1035
|
+
day: 1
|
|
1036
|
+
};
|
|
1024
1037
|
}
|
|
1038
|
+
const monthNumber = (month) => {
|
|
1039
|
+
const date = calendarMonthDate(month);
|
|
1040
|
+
return date.year * 12 + date.month - 1;
|
|
1041
|
+
};
|
|
1042
|
+
const calendarMonthWindowSchema = z.object({
|
|
1043
|
+
startMonth: calendarMonthSchema,
|
|
1044
|
+
endMonthExclusive: calendarMonthSchema
|
|
1045
|
+
}).refine((window) => {
|
|
1046
|
+
const width = monthNumber(window.endMonthExclusive) - monthNumber(window.startMonth);
|
|
1047
|
+
return width > 0 && width <= 3;
|
|
1048
|
+
}, "Calendar windows must cover one to three months");
|
|
1049
|
+
const calendarWindowQuerySchema = z.object({
|
|
1050
|
+
startMonth: calendarMonthSchema.optional(),
|
|
1051
|
+
endMonthExclusive: calendarMonthSchema.optional(),
|
|
1052
|
+
afterStartsAt: z.string().datetime({ offset: true }).optional(),
|
|
1053
|
+
afterId: z.string().uuid().optional(),
|
|
1054
|
+
limit: z.coerce.number().int().min(1).max(200).default(100),
|
|
1055
|
+
stage: z.enum(["published", "preview"]).default("published"),
|
|
1056
|
+
readProfile: z.enum(["listing-card", "timetable"]).optional(),
|
|
1057
|
+
eventSurface: z.enum(eventSurfaceScopeValues).optional(),
|
|
1058
|
+
eventPresets: z.string().optional(),
|
|
1059
|
+
scheduleScope: z.enum(eventScheduleScopeValues).optional(),
|
|
1060
|
+
seriesIds: z.string().optional(),
|
|
1061
|
+
categoryIds: z.string().optional(),
|
|
1062
|
+
venueId: z.string().transform(normalizeCalendarFilterId).optional(),
|
|
1063
|
+
staffMemberId: z.string().transform(normalizeCalendarFilterId).optional()
|
|
1064
|
+
}).superRefine((query, ctx) => {
|
|
1065
|
+
if (Boolean(query.startMonth) !== Boolean(query.endMonthExclusive)) ctx.addIssue({
|
|
1066
|
+
code: "custom",
|
|
1067
|
+
message: "Both month bounds are required"
|
|
1068
|
+
});
|
|
1069
|
+
if (query.startMonth && query.endMonthExclusive && !calendarMonthWindowSchema.safeParse(query).success) ctx.addIssue({
|
|
1070
|
+
code: "custom",
|
|
1071
|
+
message: "Invalid calendar window"
|
|
1072
|
+
});
|
|
1073
|
+
if (Boolean(query.afterStartsAt) !== Boolean(query.afterId)) ctx.addIssue({
|
|
1074
|
+
code: "custom",
|
|
1075
|
+
message: "Both cursor fields are required"
|
|
1076
|
+
});
|
|
1077
|
+
if (query.afterStartsAt && !query.startMonth) ctx.addIssue({
|
|
1078
|
+
code: "custom",
|
|
1079
|
+
message: "A continuation requires explicit month bounds"
|
|
1080
|
+
});
|
|
1081
|
+
});
|
|
1082
|
+
const calendarSourceCursorSchema = z.object({
|
|
1083
|
+
startsAt: z.string().datetime({ offset: true }),
|
|
1084
|
+
occurrenceId: z.string().uuid()
|
|
1085
|
+
});
|
|
1086
|
+
z.discriminatedUnion("kind", [z.object({ kind: z.literal("complete") }), z.object({
|
|
1087
|
+
kind: z.literal("partial"),
|
|
1088
|
+
nextCursor: calendarSourceCursorSchema
|
|
1089
|
+
})]);
|
|
1090
|
+
const publicEventLoaderQuerySchemaShape = {
|
|
1091
|
+
limit: z.string().optional(),
|
|
1092
|
+
from: z.string().optional(),
|
|
1093
|
+
to: z.string().optional(),
|
|
1094
|
+
afterStartsAt: z.string().optional(),
|
|
1095
|
+
afterId: z.string().optional(),
|
|
1096
|
+
categoryIds: z.string().optional(),
|
|
1097
|
+
venueId: z.string().optional(),
|
|
1098
|
+
staffMemberId: z.string().optional(),
|
|
1099
|
+
eventSurface: z.string().optional(),
|
|
1100
|
+
eventPresets: z.string().optional(),
|
|
1101
|
+
scheduleScope: z.string().optional(),
|
|
1102
|
+
seriesId: z.string().optional(),
|
|
1103
|
+
seriesIds: z.string().optional(),
|
|
1104
|
+
runSeriesId: z.string().optional(),
|
|
1105
|
+
seriesSlug: z.string().optional(),
|
|
1106
|
+
occurrenceIds: z.string().max(4e3).optional(),
|
|
1107
|
+
includeOccurrenceId: z.string().optional(),
|
|
1108
|
+
readIntent: z.string().optional(),
|
|
1109
|
+
detailAdmission: z.string().optional(),
|
|
1110
|
+
detailLevel: z.string().optional(),
|
|
1111
|
+
readProfile: z.string().optional()
|
|
1112
|
+
};
|
|
1113
|
+
z.object(publicEventLoaderQuerySchemaShape);
|
|
1025
1114
|
//#endregion
|
|
1026
|
-
//#region ../
|
|
1115
|
+
//#region ../site-contracts/src/siteData/eventVocabulary.ts
|
|
1116
|
+
const eventCalendarDisplayModeValues = [
|
|
1117
|
+
"combined",
|
|
1118
|
+
"calendar",
|
|
1119
|
+
"list",
|
|
1120
|
+
"timetable",
|
|
1121
|
+
"week-board",
|
|
1122
|
+
"week"
|
|
1123
|
+
];
|
|
1124
|
+
const eventCalendarDefaultViewValues = ["month", "week"];
|
|
1125
|
+
const eventCalendarListLayoutValues = [
|
|
1126
|
+
"stack",
|
|
1127
|
+
"grid",
|
|
1128
|
+
"compact"
|
|
1129
|
+
];
|
|
1130
|
+
const eventCalendarListLayoutCompatibleDisplayModeValues = ["combined", "list"];
|
|
1131
|
+
//#endregion
|
|
1132
|
+
//#region ../commerce/src/purchase/settlement.ts
|
|
1133
|
+
function normalizeCurrencyCode(raw) {
|
|
1134
|
+
const normalized = raw.trim().toUpperCase();
|
|
1135
|
+
if (!/^[A-Z]{3}$/.test(normalized)) throw new Error(`Invalid currency code: ${raw}`);
|
|
1136
|
+
return normalized;
|
|
1137
|
+
}
|
|
1138
|
+
//#endregion
|
|
1139
|
+
//#region ../media-core/src/mediaKinds.ts
|
|
1140
|
+
const mediaTypeDiscriminants = [
|
|
1141
|
+
"image",
|
|
1142
|
+
"video",
|
|
1143
|
+
"audio",
|
|
1144
|
+
"document",
|
|
1145
|
+
"spreadsheet",
|
|
1146
|
+
"archive"
|
|
1147
|
+
];
|
|
1148
|
+
const DISPLAY_MEDIA_KINDS = [
|
|
1149
|
+
"image",
|
|
1150
|
+
"video",
|
|
1151
|
+
"audio"
|
|
1152
|
+
];
|
|
1153
|
+
const PUBLIC_FILE_FIELD_KINDS = [
|
|
1154
|
+
"document",
|
|
1155
|
+
"spreadsheet",
|
|
1156
|
+
"archive",
|
|
1157
|
+
"audio"
|
|
1158
|
+
];
|
|
1159
|
+
function isDisplayMediaKind(kind) {
|
|
1160
|
+
return DISPLAY_MEDIA_KINDS.includes(kind);
|
|
1161
|
+
}
|
|
1162
|
+
//#endregion
|
|
1163
|
+
//#region ../media-core/src/media.ts
|
|
1164
|
+
const hotspotSchema = z.object({
|
|
1165
|
+
x: z.number().min(0).max(1),
|
|
1166
|
+
y: z.number().min(0).max(1),
|
|
1167
|
+
radius: z.number().optional()
|
|
1168
|
+
});
|
|
1169
|
+
const rotationSchema = z.union([
|
|
1170
|
+
z.literal(0),
|
|
1171
|
+
z.literal(90),
|
|
1172
|
+
z.literal(180),
|
|
1173
|
+
z.literal(270)
|
|
1174
|
+
]);
|
|
1175
|
+
const rectSchema = z.tuple([
|
|
1176
|
+
z.number(),
|
|
1177
|
+
z.number(),
|
|
1178
|
+
z.number(),
|
|
1179
|
+
z.number()
|
|
1180
|
+
]);
|
|
1181
|
+
const aspectCropSchema = z.object({
|
|
1182
|
+
aspect: z.preprocess((value) => value == null ? void 0 : value, z.string().optional()),
|
|
1183
|
+
rect: z.preprocess((value) => value == null ? void 0 : value, rectSchema.optional()),
|
|
1184
|
+
hotspot: z.preprocess((value) => value == null ? void 0 : value, hotspotSchema.optional()),
|
|
1185
|
+
rotation: z.preprocess((value) => value == null ? void 0 : value, rotationSchema.optional())
|
|
1186
|
+
});
|
|
1187
|
+
const transformSchema = z.object({
|
|
1188
|
+
aspectCrops: z.preprocess((value) => {
|
|
1189
|
+
if (!value || typeof value !== "object" || Array.isArray(value)) return;
|
|
1190
|
+
return value;
|
|
1191
|
+
}, z.record(z.string(), aspectCropSchema.catch({}))).optional(),
|
|
1192
|
+
rect: rectSchema.optional(),
|
|
1193
|
+
hotspot: hotspotSchema.optional(),
|
|
1194
|
+
rotation: rotationSchema.optional()
|
|
1195
|
+
});
|
|
1196
|
+
const mediaPosterSchema = z.discriminatedUnion("tag", [z.object({
|
|
1197
|
+
tag: z.literal("media"),
|
|
1198
|
+
identifier: mediaIdentifierSchema
|
|
1199
|
+
}).strict(), z.object({
|
|
1200
|
+
tag: z.literal("external-src"),
|
|
1201
|
+
src: z.string().url()
|
|
1202
|
+
}).strict()]);
|
|
1203
|
+
const mediaUsageShape = {
|
|
1204
|
+
purpose: z.string().optional(),
|
|
1205
|
+
placeholder: z.boolean().default(true).optional(),
|
|
1206
|
+
alt: z.string().optional(),
|
|
1207
|
+
filename: z.string().optional(),
|
|
1208
|
+
width: z.number().optional(),
|
|
1209
|
+
height: z.number().optional(),
|
|
1210
|
+
poster: mediaPosterSchema.optional(),
|
|
1211
|
+
transform: transformSchema.optional()
|
|
1212
|
+
};
|
|
1213
|
+
const environmentExclusions = {
|
|
1214
|
+
assetId: z.never().optional(),
|
|
1215
|
+
id: z.never().optional(),
|
|
1216
|
+
src: z.never().optional(),
|
|
1217
|
+
storageBucket: z.never().optional(),
|
|
1218
|
+
storagePath: z.never().optional(),
|
|
1219
|
+
mimeType: z.never().optional()
|
|
1220
|
+
};
|
|
1221
|
+
const mediaBaseSchema = z.object({
|
|
1222
|
+
...mediaUsageShape,
|
|
1223
|
+
...environmentExclusions,
|
|
1224
|
+
identifier: mediaIdentifierSchema
|
|
1225
|
+
}).strict();
|
|
1226
|
+
const imageMediaSchema = mediaBaseSchema.extend({ type: z.literal("image") });
|
|
1227
|
+
const videoMediaSchema = mediaBaseSchema.extend({ type: z.literal("video") });
|
|
1228
|
+
const mediaSchema = mediaBaseSchema.extend({ type: z.enum(mediaTypeDiscriminants) });
|
|
1229
|
+
const persistableMediaSchema = mediaSchema;
|
|
1230
|
+
const externalMediaSchema = z.object({
|
|
1231
|
+
...mediaUsageShape,
|
|
1232
|
+
...environmentExclusions,
|
|
1233
|
+
type: z.enum(mediaTypeDiscriminants),
|
|
1234
|
+
src: z.string().min(1),
|
|
1235
|
+
identifier: z.never().optional()
|
|
1236
|
+
}).strict();
|
|
1237
|
+
const assetMediaSchema = z.object({
|
|
1238
|
+
...mediaUsageShape,
|
|
1239
|
+
...environmentExclusions,
|
|
1240
|
+
type: z.enum(mediaTypeDiscriminants),
|
|
1241
|
+
asset: renderableMediaAssetSchema,
|
|
1242
|
+
identifier: z.never().optional()
|
|
1243
|
+
}).strict();
|
|
1244
|
+
const runtimeMediaSchema = z.union([
|
|
1245
|
+
mediaSchema,
|
|
1246
|
+
externalMediaSchema,
|
|
1247
|
+
assetMediaSchema
|
|
1248
|
+
]);
|
|
1249
|
+
//#endregion
|
|
1250
|
+
//#region ../core/src/rich-text-schema.ts
|
|
1027
1251
|
/**
|
|
1028
1252
|
* Shared Rich Text Schema
|
|
1029
1253
|
*
|
|
@@ -1102,6 +1326,144 @@ function isRichTextDoc(value) {
|
|
|
1102
1326
|
return RichTextDocSchema.safeParse(value).success;
|
|
1103
1327
|
}
|
|
1104
1328
|
//#endregion
|
|
1329
|
+
//#region ../blocks/src/system/runtime/api/schemas/bookingQuestions.ts
|
|
1330
|
+
const optionSchema = z.object({
|
|
1331
|
+
value: z.string(),
|
|
1332
|
+
label: z.string()
|
|
1333
|
+
});
|
|
1334
|
+
/** Everything a scalar question may carry besides its identity; all of it is optional. */
|
|
1335
|
+
const scalarFieldDetails = z.object({
|
|
1336
|
+
required: z.boolean(),
|
|
1337
|
+
placeholder: z.string(),
|
|
1338
|
+
helpText: z.string(),
|
|
1339
|
+
options: z.array(optionSchema),
|
|
1340
|
+
multiple: z.boolean(),
|
|
1341
|
+
minLength: z.number(),
|
|
1342
|
+
maxLength: z.number(),
|
|
1343
|
+
pattern: z.string(),
|
|
1344
|
+
min: z.number(),
|
|
1345
|
+
max: z.number()
|
|
1346
|
+
}).partial();
|
|
1347
|
+
const scalarFieldSchema = z.object({
|
|
1348
|
+
id: z.string().min(1),
|
|
1349
|
+
label: z.string(),
|
|
1350
|
+
type: z.enum([
|
|
1351
|
+
"text",
|
|
1352
|
+
"email",
|
|
1353
|
+
"textarea",
|
|
1354
|
+
"select",
|
|
1355
|
+
"radio",
|
|
1356
|
+
"checkbox",
|
|
1357
|
+
"tel",
|
|
1358
|
+
"url",
|
|
1359
|
+
"number",
|
|
1360
|
+
"date",
|
|
1361
|
+
"time"
|
|
1362
|
+
]),
|
|
1363
|
+
...scalarFieldDetails.shape
|
|
1364
|
+
});
|
|
1365
|
+
const documentFieldSchema = z.object({
|
|
1366
|
+
id: z.string().min(1),
|
|
1367
|
+
label: z.string(),
|
|
1368
|
+
type: z.literal("document_upload"),
|
|
1369
|
+
required: z.boolean().optional(),
|
|
1370
|
+
placeholder: z.string().optional(),
|
|
1371
|
+
helpText: z.string().optional(),
|
|
1372
|
+
allowedFileTypes: z.array(z.enum([
|
|
1373
|
+
"pdf",
|
|
1374
|
+
"image",
|
|
1375
|
+
"docx"
|
|
1376
|
+
])),
|
|
1377
|
+
maxBytes: z.number()
|
|
1378
|
+
});
|
|
1379
|
+
const fieldSchema = z.union([scalarFieldSchema, documentFieldSchema]);
|
|
1380
|
+
const sectionSchema = z.object({
|
|
1381
|
+
id: z.string(),
|
|
1382
|
+
title: z.string(),
|
|
1383
|
+
description: z.string().optional(),
|
|
1384
|
+
items: z.array(fieldSchema)
|
|
1385
|
+
});
|
|
1386
|
+
/** One answer as a booking flow holds it; also what drafts kept across a sign-in or payment return parse. */
|
|
1387
|
+
const bookingQuestionsAnswerValueSchema = z.union([
|
|
1388
|
+
z.string(),
|
|
1389
|
+
z.number(),
|
|
1390
|
+
z.boolean(),
|
|
1391
|
+
z.null(),
|
|
1392
|
+
z.array(z.string()),
|
|
1393
|
+
z.object({
|
|
1394
|
+
kind: z.literal("document_upload"),
|
|
1395
|
+
fileName: z.string(),
|
|
1396
|
+
mimeType: z.string(),
|
|
1397
|
+
bytes: z.number(),
|
|
1398
|
+
uploadId: z.string().optional()
|
|
1399
|
+
})
|
|
1400
|
+
]);
|
|
1401
|
+
const setSchema = z.object({
|
|
1402
|
+
requirementId: z.string().min(1),
|
|
1403
|
+
title: z.string(),
|
|
1404
|
+
sections: z.array(sectionSchema)
|
|
1405
|
+
});
|
|
1406
|
+
z.array(sectionSchema);
|
|
1407
|
+
const bookingQuestionAnswersSchema = z.record(z.string(), bookingQuestionsAnswerValueSchema);
|
|
1408
|
+
/** The presentation a public catalogue or the authenticated read hands the booking flows. */
|
|
1409
|
+
const beforeBookingQuestionsPresentationSchema = z.discriminatedUnion("kind", [
|
|
1410
|
+
z.object({ kind: z.literal("none") }),
|
|
1411
|
+
z.object({
|
|
1412
|
+
kind: z.literal("unavailable"),
|
|
1413
|
+
message: z.string()
|
|
1414
|
+
}),
|
|
1415
|
+
z.object({
|
|
1416
|
+
kind: z.literal("ask"),
|
|
1417
|
+
set: setSchema,
|
|
1418
|
+
signIn: z.enum(["offered", "not_offered"])
|
|
1419
|
+
}),
|
|
1420
|
+
z.object({
|
|
1421
|
+
kind: z.literal("prefill"),
|
|
1422
|
+
set: setSchema,
|
|
1423
|
+
answers: bookingQuestionAnswersSchema
|
|
1424
|
+
}),
|
|
1425
|
+
z.object({
|
|
1426
|
+
kind: z.literal("already_answered"),
|
|
1427
|
+
set: setSchema,
|
|
1428
|
+
answers: bookingQuestionAnswersSchema
|
|
1429
|
+
})
|
|
1430
|
+
]);
|
|
1431
|
+
//#endregion
|
|
1432
|
+
//#region ../blocks/src/system/blocks/shared/bookingConsent.ts
|
|
1433
|
+
const BOOKING_REQUIREMENT_CONSENT_FIELD_PREFIX = "booking_requirement_consent_";
|
|
1434
|
+
function toBookingRequirementConsentFieldId(requirementId) {
|
|
1435
|
+
return `${BOOKING_REQUIREMENT_CONSENT_FIELD_PREFIX}${requirementId}`;
|
|
1436
|
+
}
|
|
1437
|
+
function isBookingRequirementConsentFieldId(value) {
|
|
1438
|
+
return value.startsWith(BOOKING_REQUIREMENT_CONSENT_FIELD_PREFIX);
|
|
1439
|
+
}
|
|
1440
|
+
function toBookingRequirementConsentField(consent) {
|
|
1441
|
+
return {
|
|
1442
|
+
id: toBookingRequirementConsentFieldId(consent.requirementId),
|
|
1443
|
+
label: consent.title,
|
|
1444
|
+
type: "booking_requirement_consent",
|
|
1445
|
+
required: true,
|
|
1446
|
+
agreement: consent.agreement,
|
|
1447
|
+
checkboxLabel: consent.checkboxLabel
|
|
1448
|
+
};
|
|
1449
|
+
}
|
|
1450
|
+
const blockBookingConsentSchema = z.object({
|
|
1451
|
+
requirementId: z.string(),
|
|
1452
|
+
title: z.string(),
|
|
1453
|
+
agreement: RichTextDocSchema,
|
|
1454
|
+
checkboxLabel: z.string()
|
|
1455
|
+
});
|
|
1456
|
+
const bookingRequirementConsentFieldSchema = z.object({
|
|
1457
|
+
id: z.string(),
|
|
1458
|
+
label: z.string(),
|
|
1459
|
+
type: z.literal("booking_requirement_consent"),
|
|
1460
|
+
required: z.literal(true),
|
|
1461
|
+
agreement: RichTextDocSchema,
|
|
1462
|
+
checkboxLabel: z.string().min(1)
|
|
1463
|
+
});
|
|
1464
|
+
/** The two live public carriers for consent copy: Event data and appointment fields. */
|
|
1465
|
+
const bookingConsentCarrierSchema = z.union([blockBookingConsentSchema, bookingRequirementConsentFieldSchema]);
|
|
1466
|
+
//#endregion
|
|
1105
1467
|
//#region ../core/src/booking-payment-schemas.ts
|
|
1106
1468
|
const bookingCourseInstalmentDeadlineSchema = z.enum(BOOKING_COURSE_INSTALMENT_DEADLINES);
|
|
1107
1469
|
const stripObject = (shape) => z.object(shape);
|
|
@@ -1222,66 +1584,7 @@ z.strictObject({
|
|
|
1222
1584
|
//#region ../blocks/src/system/blocks/shared/bookingPaymentTerms.ts
|
|
1223
1585
|
const blockBookingPaymentTermsSchema = bookingPaymentTermsSchema;
|
|
1224
1586
|
//#endregion
|
|
1225
|
-
//#region ../blocks/src/system/blocks/shared/bookingConsent.ts
|
|
1226
|
-
const BOOKING_REQUIREMENT_CONSENT_FIELD_PREFIX = "booking_requirement_consent_";
|
|
1227
|
-
function toBookingRequirementConsentFieldId(requirementId) {
|
|
1228
|
-
return `${BOOKING_REQUIREMENT_CONSENT_FIELD_PREFIX}${requirementId}`;
|
|
1229
|
-
}
|
|
1230
|
-
function isBookingRequirementConsentFieldId(value) {
|
|
1231
|
-
return value.startsWith(BOOKING_REQUIREMENT_CONSENT_FIELD_PREFIX);
|
|
1232
|
-
}
|
|
1233
|
-
function toBookingRequirementConsentField(consent) {
|
|
1234
|
-
return {
|
|
1235
|
-
id: toBookingRequirementConsentFieldId(consent.requirementId),
|
|
1236
|
-
label: consent.title,
|
|
1237
|
-
type: "booking_requirement_consent",
|
|
1238
|
-
required: true,
|
|
1239
|
-
agreement: consent.agreement,
|
|
1240
|
-
checkboxLabel: consent.checkboxLabel
|
|
1241
|
-
};
|
|
1242
|
-
}
|
|
1243
|
-
const blockBookingConsentSchema = z.object({
|
|
1244
|
-
requirementId: z.string(),
|
|
1245
|
-
title: z.string(),
|
|
1246
|
-
agreement: RichTextDocSchema,
|
|
1247
|
-
checkboxLabel: z.string()
|
|
1248
|
-
});
|
|
1249
|
-
const bookingRequirementConsentFieldSchema = z.object({
|
|
1250
|
-
id: z.string(),
|
|
1251
|
-
label: z.string(),
|
|
1252
|
-
type: z.literal("booking_requirement_consent"),
|
|
1253
|
-
required: z.literal(true),
|
|
1254
|
-
agreement: RichTextDocSchema,
|
|
1255
|
-
checkboxLabel: z.string().min(1)
|
|
1256
|
-
});
|
|
1257
|
-
/** The two live public carriers for consent copy: Event data and appointment fields. */
|
|
1258
|
-
const bookingConsentCarrierSchema = z.union([blockBookingConsentSchema, bookingRequirementConsentFieldSchema]);
|
|
1259
|
-
//#endregion
|
|
1260
1587
|
//#region ../blocks/src/system/blocks/events/shared/schemas.ts
|
|
1261
|
-
const publicEventLoaderQuerySchemaShape = {
|
|
1262
|
-
limit: z.string().optional(),
|
|
1263
|
-
from: z.string().optional(),
|
|
1264
|
-
to: z.string().optional(),
|
|
1265
|
-
afterStartsAt: z.string().optional(),
|
|
1266
|
-
afterId: z.string().optional(),
|
|
1267
|
-
categoryIds: z.string().optional(),
|
|
1268
|
-
venueId: z.string().optional(),
|
|
1269
|
-
staffMemberId: z.string().optional(),
|
|
1270
|
-
eventSurface: z.string().optional(),
|
|
1271
|
-
eventPresets: z.string().optional(),
|
|
1272
|
-
scheduleScope: z.string().optional(),
|
|
1273
|
-
seriesId: z.string().optional(),
|
|
1274
|
-
seriesIds: z.string().optional(),
|
|
1275
|
-
runSeriesId: z.string().optional(),
|
|
1276
|
-
seriesSlug: z.string().optional(),
|
|
1277
|
-
occurrenceIds: z.string().max(4e3).optional(),
|
|
1278
|
-
includeOccurrenceId: z.string().optional(),
|
|
1279
|
-
readIntent: z.string().optional(),
|
|
1280
|
-
detailAdmission: z.string().optional(),
|
|
1281
|
-
detailLevel: z.string().optional(),
|
|
1282
|
-
readProfile: z.string().optional()
|
|
1283
|
-
};
|
|
1284
|
-
z.object(publicEventLoaderQuerySchemaShape);
|
|
1285
1588
|
const eventPresetSchema = z.enum([
|
|
1286
1589
|
"event",
|
|
1287
1590
|
"class",
|
|
@@ -1545,6 +1848,7 @@ const publicEventBaseSchema = z.object({
|
|
|
1545
1848
|
}) }),
|
|
1546
1849
|
asksSiteTerms: z.boolean(),
|
|
1547
1850
|
consent: blockBookingConsentSchema.nullable(),
|
|
1851
|
+
bookingQuestions: beforeBookingQuestionsPresentationSchema,
|
|
1548
1852
|
accessRestriction: accessRestrictionSchema,
|
|
1549
1853
|
allowedCategoryIds: z.array(z.string()),
|
|
1550
1854
|
requireGuestDetails: z.boolean().optional(),
|
|
@@ -1569,70 +1873,65 @@ const publicEventSchema = z.union([publicEventBaseSchema.extend({
|
|
|
1569
1873
|
*/
|
|
1570
1874
|
const publicEventsArraySchema = z.array(publicEventSchema);
|
|
1571
1875
|
//#endregion
|
|
1572
|
-
//#region ../
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1580
|
-
|
|
1581
|
-
}
|
|
1582
|
-
return normalized.sort();
|
|
1876
|
+
//#region ../site-contracts/src/identity/presentationVocabulary.ts
|
|
1877
|
+
const arrangementModes = [
|
|
1878
|
+
"list",
|
|
1879
|
+
"calendar",
|
|
1880
|
+
"week",
|
|
1881
|
+
"combined"
|
|
1882
|
+
];
|
|
1883
|
+
function isArrangementMode(value) {
|
|
1884
|
+
return value === "list" || value === "calendar" || value === "week" || value === "combined";
|
|
1583
1885
|
}
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
"all",
|
|
1589
|
-
"regularClassSchedule",
|
|
1590
|
-
"specialDatedEvents",
|
|
1591
|
-
"custom"
|
|
1886
|
+
const tileTreatmentValues = [
|
|
1887
|
+
"default",
|
|
1888
|
+
"quiet",
|
|
1889
|
+
"brand-depth"
|
|
1592
1890
|
];
|
|
1593
|
-
const
|
|
1594
|
-
"
|
|
1595
|
-
"
|
|
1596
|
-
"
|
|
1891
|
+
const eventListTreatmentValues = [
|
|
1892
|
+
"plain",
|
|
1893
|
+
"lined-panel",
|
|
1894
|
+
"ruled-register",
|
|
1895
|
+
"editorial-register",
|
|
1896
|
+
"dense-index"
|
|
1897
|
+
];
|
|
1898
|
+
const eyebrowTreatmentValues = [
|
|
1899
|
+
"plain",
|
|
1900
|
+
"accent",
|
|
1901
|
+
"pill",
|
|
1902
|
+
"accent-pill",
|
|
1903
|
+
"pill-bounce",
|
|
1904
|
+
"accent-pill-bounce"
|
|
1905
|
+
];
|
|
1906
|
+
const visibleHeadingDecorationFamilyValues = ["organic-squiggle", "short-center-rule"];
|
|
1907
|
+
const headingDecorationOverrideValues = ["site-default", "off"];
|
|
1908
|
+
const headingDecorationColorTokenValues = [
|
|
1909
|
+
"text",
|
|
1910
|
+
"primary",
|
|
1911
|
+
"secondary",
|
|
1912
|
+
"accent",
|
|
1913
|
+
"border",
|
|
1914
|
+
"muted"
|
|
1915
|
+
];
|
|
1916
|
+
const accordionIconSetValues = [
|
|
1917
|
+
"plus",
|
|
1918
|
+
"chevron",
|
|
1919
|
+
"caret",
|
|
1920
|
+
"minimal-cross"
|
|
1921
|
+
];
|
|
1922
|
+
const accordionIconColorTokenValues = [
|
|
1923
|
+
"text",
|
|
1924
|
+
"muted",
|
|
1925
|
+
"primary",
|
|
1926
|
+
"secondary",
|
|
1927
|
+
"accent",
|
|
1928
|
+
"current"
|
|
1929
|
+
];
|
|
1930
|
+
const accordionIconMotionValues = [
|
|
1931
|
+
"none",
|
|
1932
|
+
"rotate",
|
|
1933
|
+
"swap"
|
|
1597
1934
|
];
|
|
1598
|
-
const unsafeAsEventCategoryId = (value) => value;
|
|
1599
|
-
const unsafeAsVenueId = (value) => value;
|
|
1600
|
-
function normalizeEventSurfaceScope(value) {
|
|
1601
|
-
return value === "regularClassSchedule" || value === "specialDatedEvents" || value === "custom" ? value : "all";
|
|
1602
|
-
}
|
|
1603
|
-
function normalizeEventScheduleScope(value) {
|
|
1604
|
-
return value === "recurring" || value === "oneOff" ? value : "any";
|
|
1605
|
-
}
|
|
1606
|
-
function isEventSurfacePreset(value) {
|
|
1607
|
-
return eventSurfacePresetValues.some((preset) => preset === value);
|
|
1608
|
-
}
|
|
1609
|
-
function normalizeEventSurfacePresets(value) {
|
|
1610
|
-
const normalized = (Array.isArray(value) ? value : typeof value === "string" ? value.split(",") : []).filter((entry) => typeof entry === "string").map((entry) => entry.trim()).filter(isEventSurfacePreset);
|
|
1611
|
-
return Array.from(new Set(normalized));
|
|
1612
|
-
}
|
|
1613
|
-
function normalizeEventSurfacePresetsCsv(value) {
|
|
1614
|
-
const normalized = normalizeEventSurfacePresets(value);
|
|
1615
|
-
return normalized.length > 0 ? normalized.join(",") : null;
|
|
1616
|
-
}
|
|
1617
|
-
function normalizeEventCategoryIds(value) {
|
|
1618
|
-
if (Array.isArray(value)) return normalizeIdList(value.filter((entry) => typeof entry === "string")).map(unsafeAsEventCategoryId);
|
|
1619
|
-
if (typeof value === "string") return normalizeIdList(value.split(",")).map(unsafeAsEventCategoryId);
|
|
1620
|
-
return [];
|
|
1621
|
-
}
|
|
1622
|
-
function normalizeEventCategoryIdsCsv(value) {
|
|
1623
|
-
const normalized = normalizeEventCategoryIds(value);
|
|
1624
|
-
return normalized.length > 0 ? normalized.join(",") : null;
|
|
1625
|
-
}
|
|
1626
|
-
function normalizeEventVenueId(value) {
|
|
1627
|
-
if (typeof value !== "string") return null;
|
|
1628
|
-
const trimmed = value.trim();
|
|
1629
|
-
return trimmed ? unsafeAsVenueId(trimmed) : null;
|
|
1630
|
-
}
|
|
1631
|
-
function normalizeEventStaffMemberId(value) {
|
|
1632
|
-
if (typeof value !== "string") return null;
|
|
1633
|
-
const trimmed = value.trim();
|
|
1634
|
-
return trimmed ? trimmed : null;
|
|
1635
|
-
}
|
|
1636
1935
|
//#endregion
|
|
1637
1936
|
//#region ../blocks/src/system/constants/events.ts
|
|
1638
1937
|
/**
|
|
@@ -1640,22 +1939,9 @@ function normalizeEventStaffMemberId(value) {
|
|
|
1640
1939
|
*
|
|
1641
1940
|
* Shared constants for event content types and booking system integration.
|
|
1642
1941
|
*/
|
|
1643
|
-
const eventCalendarDisplayModeValues = [
|
|
1644
|
-
"combined",
|
|
1645
|
-
"calendar",
|
|
1646
|
-
"list",
|
|
1647
|
-
"timetable",
|
|
1648
|
-
"week-board",
|
|
1649
|
-
"week"
|
|
1650
|
-
];
|
|
1651
|
-
const eventCalendarDefaultViewValues = ["month", "week"];
|
|
1652
|
-
const eventCalendarListLayoutValues = [
|
|
1653
|
-
"stack",
|
|
1654
|
-
"grid",
|
|
1655
|
-
"compact"
|
|
1656
|
-
];
|
|
1657
1942
|
const arrangementOnlyListLayouts = [
|
|
1658
1943
|
"ledger",
|
|
1944
|
+
"timetable-rows",
|
|
1659
1945
|
"day-groups",
|
|
1660
1946
|
"week-columns"
|
|
1661
1947
|
];
|
|
@@ -1674,7 +1960,6 @@ const eventCalendarListLayoutOptions = [
|
|
|
1674
1960
|
label: "Compact"
|
|
1675
1961
|
}
|
|
1676
1962
|
];
|
|
1677
|
-
const eventCalendarListLayoutCompatibleDisplayModeValues = ["combined", "list"];
|
|
1678
1963
|
function isEventCalendarDisplayMode(value) {
|
|
1679
1964
|
return typeof value === "string" && eventCalendarDisplayModeValues.includes(value);
|
|
1680
1965
|
}
|
|
@@ -1755,66 +2040,9 @@ function eventCalendarListGroupingDecision(input) {
|
|
|
1755
2040
|
function resolveCalendarReadProfile(content) {
|
|
1756
2041
|
return resolveEventCalendarReadPlan(content).readProfile;
|
|
1757
2042
|
}
|
|
1758
|
-
/** Runtime picker sentinels and bound loader IDs must describe the same query. */
|
|
1759
|
-
function normalizeCalendarFilterId(value) {
|
|
1760
|
-
const id = value?.trim();
|
|
1761
|
-
return !id || id === "all" ? void 0 : id;
|
|
1762
|
-
}
|
|
1763
|
-
const calendarMonthSchema = z.string().regex(/^\d{4}-(0[1-9]|1[0-2])$/).refine((month) => Number(month.slice(0, 4)) > 0, "Invalid calendar year");
|
|
1764
|
-
function calendarMonthDate(month) {
|
|
1765
|
-
return {
|
|
1766
|
-
year: Number(month.slice(0, 4)),
|
|
1767
|
-
month: Number(month.slice(5, 7)),
|
|
1768
|
-
day: 1
|
|
1769
|
-
};
|
|
1770
|
-
}
|
|
1771
2043
|
function calendarMonthKey(date) {
|
|
1772
2044
|
return `${String(date.year).padStart(4, "0")}-${String(date.month).padStart(2, "0")}`;
|
|
1773
2045
|
}
|
|
1774
|
-
const monthNumber = (month) => {
|
|
1775
|
-
const date = calendarMonthDate(month);
|
|
1776
|
-
return date.year * 12 + date.month - 1;
|
|
1777
|
-
};
|
|
1778
|
-
const calendarMonthWindowSchema = z.object({
|
|
1779
|
-
startMonth: calendarMonthSchema,
|
|
1780
|
-
endMonthExclusive: calendarMonthSchema
|
|
1781
|
-
}).refine((window) => {
|
|
1782
|
-
const width = monthNumber(window.endMonthExclusive) - monthNumber(window.startMonth);
|
|
1783
|
-
return width > 0 && width <= 3;
|
|
1784
|
-
}, "Calendar windows must cover one to three months");
|
|
1785
|
-
const calendarWindowQuerySchema = z.object({
|
|
1786
|
-
startMonth: calendarMonthSchema.optional(),
|
|
1787
|
-
endMonthExclusive: calendarMonthSchema.optional(),
|
|
1788
|
-
afterStartsAt: z.string().datetime({ offset: true }).optional(),
|
|
1789
|
-
afterId: z.string().uuid().optional(),
|
|
1790
|
-
limit: z.coerce.number().int().min(1).max(200).default(100),
|
|
1791
|
-
stage: z.enum(["published", "preview"]).default("published"),
|
|
1792
|
-
readProfile: z.enum(["listing-card", "timetable"]).optional(),
|
|
1793
|
-
eventSurface: z.enum(eventSurfaceScopeValues).optional(),
|
|
1794
|
-
eventPresets: z.string().optional(),
|
|
1795
|
-
scheduleScope: z.enum(eventScheduleScopeValues).optional(),
|
|
1796
|
-
seriesIds: z.string().optional(),
|
|
1797
|
-
categoryIds: z.string().optional(),
|
|
1798
|
-
venueId: z.string().transform(normalizeCalendarFilterId).optional(),
|
|
1799
|
-
staffMemberId: z.string().transform(normalizeCalendarFilterId).optional()
|
|
1800
|
-
}).superRefine((query, ctx) => {
|
|
1801
|
-
if (Boolean(query.startMonth) !== Boolean(query.endMonthExclusive)) ctx.addIssue({
|
|
1802
|
-
code: "custom",
|
|
1803
|
-
message: "Both month bounds are required"
|
|
1804
|
-
});
|
|
1805
|
-
if (query.startMonth && query.endMonthExclusive && !calendarMonthWindowSchema.safeParse(query).success) ctx.addIssue({
|
|
1806
|
-
code: "custom",
|
|
1807
|
-
message: "Invalid calendar window"
|
|
1808
|
-
});
|
|
1809
|
-
if (Boolean(query.afterStartsAt) !== Boolean(query.afterId)) ctx.addIssue({
|
|
1810
|
-
code: "custom",
|
|
1811
|
-
message: "Both cursor fields are required"
|
|
1812
|
-
});
|
|
1813
|
-
if (query.afterStartsAt && !query.startMonth) ctx.addIssue({
|
|
1814
|
-
code: "custom",
|
|
1815
|
-
message: "A continuation requires explicit month bounds"
|
|
1816
|
-
});
|
|
1817
|
-
});
|
|
1818
2046
|
function normalizedCsv(value) {
|
|
1819
2047
|
return [...new Set((value ?? "").split(",").map((part) => part.trim()).filter(Boolean))].sort().join(",");
|
|
1820
2048
|
}
|
|
@@ -1853,14 +2081,6 @@ function calendarWindowBounds(window, timeZone) {
|
|
|
1853
2081
|
endExclusive: end.startAt.toISOString()
|
|
1854
2082
|
};
|
|
1855
2083
|
}
|
|
1856
|
-
const calendarSourceCursorSchema = z.object({
|
|
1857
|
-
startsAt: z.string().datetime({ offset: true }),
|
|
1858
|
-
occurrenceId: z.string().uuid()
|
|
1859
|
-
});
|
|
1860
|
-
z.discriminatedUnion("kind", [z.object({ kind: z.literal("complete") }), z.object({
|
|
1861
|
-
kind: z.literal("partial"),
|
|
1862
|
-
nextCursor: calendarSourceCursorSchema
|
|
1863
|
-
})]);
|
|
1864
2084
|
const pageFields = {
|
|
1865
2085
|
scope: z.object({
|
|
1866
2086
|
key: z.string(),
|
|
@@ -1904,285 +2124,6 @@ function planCalendarMonthRanges(months) {
|
|
|
1904
2124
|
return ranges;
|
|
1905
2125
|
}
|
|
1906
2126
|
//#endregion
|
|
1907
|
-
//#region ../commerce/src/purchase/settlement.ts
|
|
1908
|
-
function normalizeCurrencyCode(raw) {
|
|
1909
|
-
const normalized = raw.trim().toUpperCase();
|
|
1910
|
-
if (!/^[A-Z]{3}$/.test(normalized)) throw new Error(`Invalid currency code: ${raw}`);
|
|
1911
|
-
return normalized;
|
|
1912
|
-
}
|
|
1913
|
-
//#endregion
|
|
1914
|
-
//#region ../commerce/src/purchase/confirmationPaymentSchema.ts
|
|
1915
|
-
const settledBalanceSchema = z.strictObject({ kind: z.literal("settled") });
|
|
1916
|
-
const dueBalanceSchema = z.strictObject({
|
|
1917
|
-
kind: z.literal("due"),
|
|
1918
|
-
amountCents: z.number().int().positive().transform((value, ctx) => {
|
|
1919
|
-
const cents = parsePositiveCents(value);
|
|
1920
|
-
if (cents.ok) return cents.value;
|
|
1921
|
-
ctx.addIssue({
|
|
1922
|
-
code: "custom",
|
|
1923
|
-
message: "Expected positive whole cents"
|
|
1924
|
-
});
|
|
1925
|
-
return z.NEVER;
|
|
1926
|
-
}),
|
|
1927
|
-
dueAt: z.string().nullable()
|
|
1928
|
-
});
|
|
1929
|
-
const paymentBalanceSchema = z.discriminatedUnion("kind", [settledBalanceSchema, dueBalanceSchema]);
|
|
1930
|
-
const currencySchema = z.string().regex(/^[A-Z]{3}$/).transform(normalizeCurrencyCode);
|
|
1931
|
-
const moneyFields = {
|
|
1932
|
-
amountPaidCents: z.number().int().nonnegative().transform(toNonNegativeCents),
|
|
1933
|
-
currency: currencySchema
|
|
1934
|
-
};
|
|
1935
|
-
const confirmationPaymentSchema = z.discriminatedUnion("kind", [
|
|
1936
|
-
z.strictObject({
|
|
1937
|
-
kind: z.literal("free"),
|
|
1938
|
-
balance: settledBalanceSchema
|
|
1939
|
-
}),
|
|
1940
|
-
z.strictObject({
|
|
1941
|
-
kind: z.literal("waived"),
|
|
1942
|
-
balance: settledBalanceSchema
|
|
1943
|
-
}),
|
|
1944
|
-
z.strictObject({
|
|
1945
|
-
kind: z.literal("pass"),
|
|
1946
|
-
passName: z.string().nullable(),
|
|
1947
|
-
passCreditsUsed: z.number().int().positive().nullable(),
|
|
1948
|
-
balance: settledBalanceSchema
|
|
1949
|
-
}),
|
|
1950
|
-
z.strictObject({
|
|
1951
|
-
kind: z.literal("membership"),
|
|
1952
|
-
membershipName: z.string().nullable(),
|
|
1953
|
-
balance: settledBalanceSchema
|
|
1954
|
-
}),
|
|
1955
|
-
z.strictObject({
|
|
1956
|
-
kind: z.literal("manual_due"),
|
|
1957
|
-
currency: currencySchema,
|
|
1958
|
-
balance: dueBalanceSchema
|
|
1959
|
-
}),
|
|
1960
|
-
z.strictObject({
|
|
1961
|
-
kind: z.literal("managed_balance_due"),
|
|
1962
|
-
...moneyFields,
|
|
1963
|
-
balance: dueBalanceSchema
|
|
1964
|
-
}),
|
|
1965
|
-
z.strictObject({
|
|
1966
|
-
kind: z.literal("monetary"),
|
|
1967
|
-
...moneyFields,
|
|
1968
|
-
paymentMethod: z.enum([
|
|
1969
|
-
"stripe",
|
|
1970
|
-
"store_credit",
|
|
1971
|
-
"mixed",
|
|
1972
|
-
"manual"
|
|
1973
|
-
]),
|
|
1974
|
-
balance: paymentBalanceSchema
|
|
1975
|
-
})
|
|
1976
|
-
]);
|
|
1977
|
-
//#endregion
|
|
1978
|
-
//#region ../blocks/src/system/runtime/api/schemas/events.ts
|
|
1979
|
-
const uuid = z.string().uuid();
|
|
1980
|
-
const eventRegistrationStatusReferenceSchema = z.discriminatedUnion("scope", [z.object({
|
|
1981
|
-
scope: z.literal("occurrence"),
|
|
1982
|
-
attendeeId: uuid
|
|
1983
|
-
}).strict(), z.object({
|
|
1984
|
-
scope: z.literal("wholeSeries"),
|
|
1985
|
-
registrationId: uuid
|
|
1986
|
-
}).strict()]);
|
|
1987
|
-
const eventRegistrationPaymentSubjectSchema = z.discriminatedUnion("scope", [z.object({
|
|
1988
|
-
scope: z.literal("occurrence"),
|
|
1989
|
-
submissionId: uuid,
|
|
1990
|
-
attendeeId: uuid
|
|
1991
|
-
}).strict(), z.object({
|
|
1992
|
-
scope: z.literal("wholeSeries"),
|
|
1993
|
-
submissionId: uuid
|
|
1994
|
-
}).strict()]);
|
|
1995
|
-
const identityFields = {
|
|
1996
|
-
submissionId: uuid,
|
|
1997
|
-
seriesId: uuid,
|
|
1998
|
-
attendanceMode: z.enum(["in_person", "online"])
|
|
1999
|
-
};
|
|
2000
|
-
const confirmedBookingIdentitySchema = z.discriminatedUnion("scope", [z.object({
|
|
2001
|
-
scope: z.literal("occurrence"),
|
|
2002
|
-
attendeeId: uuid,
|
|
2003
|
-
occurrenceId: uuid,
|
|
2004
|
-
...identityFields
|
|
2005
|
-
}).strict(), z.object({
|
|
2006
|
-
scope: z.literal("wholeSeries"),
|
|
2007
|
-
registrationId: uuid,
|
|
2008
|
-
...identityFields
|
|
2009
|
-
}).strict()]);
|
|
2010
|
-
const bookedTicketLineSchema = z.object({
|
|
2011
|
-
label: z.string().min(1),
|
|
2012
|
-
quantity: z.number().int().positive()
|
|
2013
|
-
}).strict();
|
|
2014
|
-
const arrivalFields = { arrivalVenues: z.record(uuid, z.string()).optional() };
|
|
2015
|
-
const eventBookingOutcomeSchema = z.discriminatedUnion("kind", [z.object({
|
|
2016
|
-
kind: z.literal("detailsAvailable"),
|
|
2017
|
-
identity: confirmedBookingIdentitySchema,
|
|
2018
|
-
ticketLines: z.tuple([bookedTicketLineSchema]).rest(bookedTicketLineSchema).readonly(),
|
|
2019
|
-
payment: confirmationPaymentSchema,
|
|
2020
|
-
...arrivalFields
|
|
2021
|
-
}).strict(), z.object({
|
|
2022
|
-
kind: z.literal("detailsUnavailable"),
|
|
2023
|
-
identity: confirmedBookingIdentitySchema,
|
|
2024
|
-
...arrivalFields
|
|
2025
|
-
}).strict()]);
|
|
2026
|
-
const eventEmbeddedCheckoutSchema = z.object({
|
|
2027
|
-
kind: z.literal("embedded"),
|
|
2028
|
-
sessionId: z.string().min(1),
|
|
2029
|
-
clientSecret: z.string().min(1),
|
|
2030
|
-
livemode: z.boolean(),
|
|
2031
|
-
expiresAt: z.string().datetime({ offset: true }),
|
|
2032
|
-
browser: z.discriminatedUnion("kind", [z.object({
|
|
2033
|
-
kind: z.literal("connect"),
|
|
2034
|
-
publishableKey: z.string().min(1),
|
|
2035
|
-
accountId: z.string().min(1)
|
|
2036
|
-
}).strict(), z.object({
|
|
2037
|
-
kind: z.literal("direct"),
|
|
2038
|
-
publishableKey: z.string().min(1)
|
|
2039
|
-
}).strict()])
|
|
2040
|
-
}).strict();
|
|
2041
|
-
const decorations = {
|
|
2042
|
-
mailingListSignupNote: z.enum(["confirmation_required", "not_confirmed"]).optional(),
|
|
2043
|
-
demoBookingPass: z.string().optional()
|
|
2044
|
-
};
|
|
2045
|
-
const eventRegistrationSummarySchema = z.object({
|
|
2046
|
-
message: z.string(),
|
|
2047
|
-
passCreditsRemaining: z.number().int().nonnegative().optional()
|
|
2048
|
-
}).strict();
|
|
2049
|
-
const eventRegisterResponseSchema = z.discriminatedUnion("kind", [
|
|
2050
|
-
z.object({
|
|
2051
|
-
kind: z.literal("bookingComplete"),
|
|
2052
|
-
outcome: eventBookingOutcomeSchema,
|
|
2053
|
-
summary: eventRegistrationSummarySchema,
|
|
2054
|
-
...decorations
|
|
2055
|
-
}).strict(),
|
|
2056
|
-
z.object({
|
|
2057
|
-
kind: z.literal("checkoutRequired"),
|
|
2058
|
-
reference: eventRegistrationStatusReferenceSchema,
|
|
2059
|
-
checkout: eventEmbeddedCheckoutSchema,
|
|
2060
|
-
submissionId: uuid,
|
|
2061
|
-
...decorations
|
|
2062
|
-
}).strict(),
|
|
2063
|
-
z.object({
|
|
2064
|
-
kind: z.literal("paymentStatusRequired"),
|
|
2065
|
-
subject: eventRegistrationPaymentSubjectSchema,
|
|
2066
|
-
...decorations
|
|
2067
|
-
}).strict(),
|
|
2068
|
-
z.object({
|
|
2069
|
-
kind: z.literal("waitlisted"),
|
|
2070
|
-
waitlist: z.object({
|
|
2071
|
-
reference: z.union([z.object({
|
|
2072
|
-
scope: z.literal("occurrence"),
|
|
2073
|
-
attendeeId: uuid
|
|
2074
|
-
}).strict(), z.object({
|
|
2075
|
-
scope: z.enum(["occurrence", "wholeSeries"]),
|
|
2076
|
-
waitlistEntryId: uuid
|
|
2077
|
-
}).strict()]),
|
|
2078
|
-
position: z.number().int().nonnegative().nullable(),
|
|
2079
|
-
message: z.string(),
|
|
2080
|
-
emailFollowupMessage: z.string().optional()
|
|
2081
|
-
}).strict(),
|
|
2082
|
-
...decorations
|
|
2083
|
-
}).strict()
|
|
2084
|
-
]);
|
|
2085
|
-
const checkoutStatusArms = [
|
|
2086
|
-
z.object({
|
|
2087
|
-
kind: z.literal("resolved"),
|
|
2088
|
-
outcome: eventBookingOutcomeSchema
|
|
2089
|
-
}).strict(),
|
|
2090
|
-
z.object({ kind: z.literal("abandoned") }).strict(),
|
|
2091
|
-
z.object({ kind: z.literal("reconciliationRequired") }).strict(),
|
|
2092
|
-
z.object({
|
|
2093
|
-
kind: z.literal("paymentProcessing"),
|
|
2094
|
-
recoverableUntil: z.string().optional()
|
|
2095
|
-
}).strict(),
|
|
2096
|
-
z.object({
|
|
2097
|
-
kind: z.literal("paymentAvailable"),
|
|
2098
|
-
checkout: eventEmbeddedCheckoutSchema,
|
|
2099
|
-
recoverableUntil: z.string().optional()
|
|
2100
|
-
}).strict(),
|
|
2101
|
-
z.object({
|
|
2102
|
-
kind: z.literal("paymentRetryAvailable"),
|
|
2103
|
-
place: z.enum(["held", "released"])
|
|
2104
|
-
}).strict(),
|
|
2105
|
-
z.object({
|
|
2106
|
-
kind: z.literal("paymentCheckUnavailable"),
|
|
2107
|
-
recoverableUntil: z.string().optional()
|
|
2108
|
-
}).strict(),
|
|
2109
|
-
z.object({ kind: z.literal("paymentAssistanceRequired") }).strict()
|
|
2110
|
-
];
|
|
2111
|
-
z.discriminatedUnion("kind", [...checkoutStatusArms, z.object({ kind: z.literal("notFound") }).strict()]);
|
|
2112
|
-
const eventCheckoutReturnResponseSchema = z.discriminatedUnion("kind", [
|
|
2113
|
-
z.object({
|
|
2114
|
-
kind: z.literal("checkout"),
|
|
2115
|
-
subject: eventRegistrationPaymentSubjectSchema,
|
|
2116
|
-
outcome: z.discriminatedUnion("kind", checkoutStatusArms)
|
|
2117
|
-
}).strict(),
|
|
2118
|
-
z.object({ kind: z.literal("notFound") }).strict(),
|
|
2119
|
-
z.object({ kind: z.literal("reconciliationRequired") }).strict()
|
|
2120
|
-
]).superRefine((response, ctx) => {
|
|
2121
|
-
if (response.kind !== "checkout" || response.outcome.kind !== "resolved") return;
|
|
2122
|
-
const identity = response.outcome.outcome.identity;
|
|
2123
|
-
if (identity.scope !== response.subject.scope || identity.submissionId !== response.subject.submissionId || identity.scope === "occurrence" && response.subject.scope === "occurrence" && identity.attendeeId !== response.subject.attendeeId) ctx.addIssue({
|
|
2124
|
-
code: "custom",
|
|
2125
|
-
message: "Confirmed booking does not match checkout subject",
|
|
2126
|
-
path: ["outcome"]
|
|
2127
|
-
});
|
|
2128
|
-
});
|
|
2129
|
-
const checkoutDecorations = { mailingListSignupNote: decorations.mailingListSignupNote };
|
|
2130
|
-
const eventCheckoutResponseSchema = z.union([
|
|
2131
|
-
z.object({
|
|
2132
|
-
kind: z.literal("completed"),
|
|
2133
|
-
scope: z.literal("occurrence"),
|
|
2134
|
-
outcome: eventBookingOutcomeSchema,
|
|
2135
|
-
...checkoutDecorations
|
|
2136
|
-
}).strict(),
|
|
2137
|
-
z.object({
|
|
2138
|
-
kind: z.literal("completed"),
|
|
2139
|
-
scope: z.literal("wholeSeries"),
|
|
2140
|
-
outcome: eventBookingOutcomeSchema,
|
|
2141
|
-
...checkoutDecorations
|
|
2142
|
-
}).strict(),
|
|
2143
|
-
z.object({
|
|
2144
|
-
kind: z.literal("checkoutRequired"),
|
|
2145
|
-
scope: z.literal("occurrence"),
|
|
2146
|
-
attendeeId: uuid,
|
|
2147
|
-
checkout: eventEmbeddedCheckoutSchema,
|
|
2148
|
-
...checkoutDecorations
|
|
2149
|
-
}).strict(),
|
|
2150
|
-
z.object({
|
|
2151
|
-
kind: z.literal("checkoutRequired"),
|
|
2152
|
-
scope: z.literal("wholeSeries"),
|
|
2153
|
-
registrationId: uuid,
|
|
2154
|
-
checkoutAttemptId: uuid,
|
|
2155
|
-
checkout: eventEmbeddedCheckoutSchema,
|
|
2156
|
-
recoverableUntil: z.string().optional(),
|
|
2157
|
-
...checkoutDecorations
|
|
2158
|
-
}).strict(),
|
|
2159
|
-
z.object({
|
|
2160
|
-
scope: z.literal("wholeSeries"),
|
|
2161
|
-
status: z.literal("paymentStatusRequired"),
|
|
2162
|
-
checkoutAttemptId: uuid,
|
|
2163
|
-
recoverableUntil: z.string().optional(),
|
|
2164
|
-
...checkoutDecorations
|
|
2165
|
-
}).strict(),
|
|
2166
|
-
z.object({
|
|
2167
|
-
scope: z.literal("wholeSeries"),
|
|
2168
|
-
status: z.literal("waitlist"),
|
|
2169
|
-
waitlistEntryId: uuid,
|
|
2170
|
-
waitlistPosition: z.number().int().nonnegative().nullable(),
|
|
2171
|
-
alreadyRegistered: z.boolean().optional(),
|
|
2172
|
-
...checkoutDecorations
|
|
2173
|
-
}).strict()
|
|
2174
|
-
]).superRefine((response, ctx) => {
|
|
2175
|
-
if ("kind" in response && response.kind === "completed" && response.scope !== response.outcome.identity.scope) ctx.addIssue({
|
|
2176
|
-
code: "custom",
|
|
2177
|
-
message: "Confirmed booking scope mismatch",
|
|
2178
|
-
path: [
|
|
2179
|
-
"outcome",
|
|
2180
|
-
"identity",
|
|
2181
|
-
"scope"
|
|
2182
|
-
]
|
|
2183
|
-
});
|
|
2184
|
-
});
|
|
2185
|
-
//#endregion
|
|
2186
2127
|
//#region ../blocks/src/contracts/events.ts
|
|
2187
2128
|
/** Release 1: older SDKs reject additional confirmed-outcome fields. */
|
|
2188
2129
|
const EVENT_BOOKING_ARRIVAL_QUERY = "bookingArrival";
|
|
@@ -2237,4 +2178,4 @@ const logger = {
|
|
|
2237
2178
|
withFields: (_) => logger
|
|
2238
2179
|
};
|
|
2239
2180
|
//#endregion
|
|
2240
|
-
export {
|
|
2181
|
+
export { videoMediaSchema as $, formatCurrencyAmount as $t, headingDecorationOverrideValues as A, formatTimeRange as At, bookingConsentCarrierSchema as B, getBookingLocalDateKey as Bt, accordionIconColorTokenValues as C, trimmedStringOrNull as Ct, eventListTreatmentValues as D, formatDateTime as Dt, arrangementModes as E, formatDateRange as Et, publicEventDestinationSchema as F, toScheduledBookingDateTime as Ft, RichTextDocSchema as G, resolveBookingTimeZoneId as Gt, toBookingRequirementConsentField as H, parseBookingLocalDate as Ht, publicEventSchema as I, buildBookingUtcDateWindow as It, externalMediaSchema as J, toUtcIsoDateTimeString as Jt, isRichTextDoc as K, toBookingTimeZone as Kt, publicEventsArraySchema as L, addLocalScheduleDays as Lt, tileTreatmentValues as M, inferSiteDateLocale as Mt, visibleHeadingDecorationFamilyValues as N, resolveBookingDisplayContext as Nt, eyebrowTreatmentValues as O, formatDateTimeRange as Ot, eventVenueDrawingSchema as P, formatBookingCompactEnglishTime as Pt, runtimeMediaSchema as Q, toNonNegativeCents as Qt, blockBookingPaymentTermsSchema as R, compareLocalScheduleDates as Rt, resolveEventCalendarReadPlan as S, toLocationCoordinates as St, accordionIconSetValues as T, formatDate as Tt, beforeBookingQuestionsPresentationSchema as U, parseLocalScheduleTime as Ut, isBookingRequirementConsentFieldId as V, getLocalScheduleDate as Vt, bookingQuestionsAnswerValueSchema as W, resolveBookingBusinessTimeZone as Wt, mediaSchema as X, parsePositiveCents as Xt, imageMediaSchema as Y, validateBookingPaymentOptionKinds as Yt, persistableMediaSchema as Z, parsePositiveMoneyInputToCents as Zt, eventListArrangementValues as _, locationValueSchema as _t, eventAutoApplyDiscountPreviewSchema as a, eventCalendarDisplayModeValues as at, isEventCalendarListLayout as b, projectPublicLocation as bt, calendarQueryKey as c, calendarMonthDate as ct, calendarWindowPageSchema as d, eventSurfacePresetValues as dt, formatGiftCardAmountLabel as en, PUBLIC_FILE_FIELD_KINDS as et, planCalendarMonthRanges as f, eventSurfaceScopeValues as ft, eventCalendarVariantMeaning as g, decideLocationSourcePermission as gt, eventCalendarListLayoutOptions as h, WHOLE_SERIES_EVENT_PRESET_VALUES as ht, EVENT_BOOKING_ARRIVAL_QUERY as i, eventCalendarDefaultViewValues as it, isArrangementMode as j, formatTimeZoneCityLabel as jt, headingDecorationColorTokenValues as k, formatTime as kt, calendarWindowBounds as l, calendarWindowQuerySchema as lt, eventCalendarListGroupingDecision as m, isRecord as mt, blockSiteTermsSchema as n, mediaTypeDiscriminants as nt, calendarMonthKey as o, eventCalendarListLayoutCompatibleDisplayModeValues as ot, resolveCalendarReadProfile as p, publicEventLoaderQuerySchemaShape as pt, assetMediaSchema as q, parseUtcIsoDateTimeString as qt, verifiedSiteTermsAcceptanceSchema as r, normalizeCurrencyCode as rt, calendarPageResponseError as s, eventCalendarListLayoutValues as st, logger as t, isDisplayMediaKind as tt, calendarWindowMonths as u, eventScheduleScopeValues as ut, isEventCalendarDefaultView as v, normalizeLocationAddressText as vt, accordionIconMotionValues as w, mapDrawingSchema as wt, normalizeEventCalendarDisplayMode as x, publicLocationSchema as xt, isEventCalendarDisplayMode as y, parseLocationValue as yt, blockBookingConsentSchema as z, formatLocalScheduleDate as zt };
|