@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,29 +1,30 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { d as formatDateKey, h as getWeekCalendarDayTuple, m as getOrderedDayNames } from "./src-1PJxc8KO.mjs";
|
|
3
3
|
import { T as ok, w as err } from "./renderableMediaAssetAdmission-DGjBr_e-.mjs";
|
|
4
|
-
import {
|
|
4
|
+
import { $n as backgroundColorStyle, C as clsx, Dr as runtimeMediaSchema, Kt as cardVariantRoleValues, Mn as resolveThemeColorReferenceValue, S as PlusIcon, _ as FileArchiveIcon, a as ThemedDownloadLink, b as FileTextIcon, c as ICON_PICKER_PRESETS, ct as ICON_CONFIG, d as ArrowDownIcon, f as ChevronDownIcon, i as ThemedButtonLink, ir as textColorStyle, l as isSemanticIconId, m as CirclePlusIcon, nr as mergeStyles, p as CircleMinusIcon, r as ThemedButton, rr as rgbColorValue, s as getIconComponent, u as SpinnerNode, v as FileAudioIcon, x as MinusIcon, y as FileSpreadsheetIcon } from "./ThemedButton-C22C9cCF.mjs";
|
|
5
5
|
import { t as formatEventDuration } from "./duration-Q6_QNgiv.mjs";
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
6
|
+
import { c as assertNever$1 } from "./src-VIsPY-kw.mjs";
|
|
7
|
+
import { Ai as orderedLiveRunSessions, An as isEventFull, Cn as canJoinEventWaitlistOnAnyMode, Dn as getEventAvailability, Dr as resolveEventRegistrationScopedEvents, Ei as parseAspectRatioValue, Er as normalizeEventRegistrationPageSurfaceSubject, Fn as buildBookingFormInteractiveIslandProps, Ji as resolveExactOrFreePriceDisplay, Kt as RichText, Mr as listItemPresentation, Nn as groupPublicEventsByRun, On as getEventAvailabilityStatus, Pr as listLookSlot, Vi as formatBookingPriceDisplay, Xr as compiledRuntimeStyleFieldNames, Yi as resolvePricingOptionsPriceDisplay, _n as formatEventTimeRange, _r as BLOCK_BUTTON_ROLE_OPTIONS, an as buildCalendarViewport, cn as eventDateOptions, hn as formatEventHourLabel, in as sanitizeHref, ji as resolveWholeSeriesBookingPhase, ki as nextLiveRunSessionStartMs, oi as arrangementSlotNames, pn as formatEventCompactDateRail, rn as resolvePublicMediaUrl, un as formatCalendarTitle, vn as formatTime, xn as resolveRuntimeEventDestination, yn as groupEventsByDate, yr as isBlockButtonRole } from "./wizardSteps-zgq10lN1.mjs";
|
|
8
|
+
import { C as eventCalendarVariantMeaning, Ct as toUtcIsoDateTimeString, D as isEventCalendarListLayout, E as isEventCalendarDisplayMode, F as normalizeEventStaffMemberId, I as normalizeEventSurfacePresets, M as normalizeEventCategoryIds, O as normalizeEventCalendarDisplayMode$1, P as normalizeEventScheduleScope, R as normalizeEventSurfaceScope, T as isEventCalendarDefaultView, W as publicEventsArraySchema, X as RichTextDocSchema, p as calendarWindowPageSchema, tt as formatDate, x as eventCalendarListLayoutOptions, yt as resolveBookingBusinessTimeZone, z as normalizeEventVenueId } from "./noop-B610YKEx.mjs";
|
|
8
9
|
import { n as selectCategoryView } from "./appointment-service-categories-Cl2pqw-z.mjs";
|
|
9
|
-
import { i as normalizeLocationMapProps, o as toLocationMapHydrationProps, t as LocationMapView } from "./location-map.view-
|
|
10
|
-
import { At as
|
|
11
|
-
import { n as resolveEventLinkProps, t as resolveEventCta } from "./cta-
|
|
12
|
-
import { a as buildMonthDay, i as CalendarDayHeaders, n as WeekAgendaView, o as resolveMonthSelectedDay, s as formatEventLocation } from "./CalendarNavigationChevron-
|
|
13
|
-
import { n as CardListItems, r as EventItem } from "./EventItem-
|
|
14
|
-
import { S as asPartialObject, d as resolveCardRoleForBoxStyles, g as DEFAULT_SECTION_SPACING, i as EventCard, n as EmptyState, r as EventCompactRow, s as boxStyleClassNames, t as EventListingFrameView, u as normalizeBoxStylesBorder } from "./EventListing.view-
|
|
10
|
+
import { i as normalizeLocationMapProps, o as toLocationMapHydrationProps, t as LocationMapView } from "./location-map.view-Cx4Bl7ij.mjs";
|
|
11
|
+
import { At as recurringScheduleProjectionSchema, B as giftingBlockRuntime, Bt as listingEventCardProps, Dt as eventCalendarBlockRuntime, F as buildNewsletterFormInteractiveIslandProps, Gt as MediaNodeServer, H as publicGiftingOffersResponseSchema, I as newsletterBlockSubmissionMessage, Jt as Grid, Kt as getCardOrientation, L as newsletterFormBlockRuntime, Mt as eventListingBlockRuntime, N as publicProductsResponseSchema, P as NEWSLETTER_SIGNUPS_PAUSED_MESSAGE, Qt as formatEventPriceDisplay, St as eventCombinedBlockRuntime, Tt as buildEventCalendarListingDisplay, U as buildFormInteractiveIslandProps, W as formBlockRuntime, Xt as formatEventPrice, Y as eventRegistrationBlockRuntime, Yt as buildEventListWeek, _ as shopProductPresentation, a as buildShopInteractiveIslandProps, bt as buildEventCombinedInteractiveIslandProps, c as checkoutBlockRuntime, cn as publicPassProductCollectionSchema, ct as resolveOfferingsPreviewGroupCta, d as productDetailBlockRuntime, dn as parseMailingListPlacementTargeting, dt as resolveOfferingsRenderInput, h as shopBlockRuntime, i as buildProductListInteractiveIslandProps, jt as buildEventListingInteractiveIslandProps, lt as resolveOfferingsPreviewGroups, n as buildCheckoutInteractiveIslandProps, nt as OFFERINGS_PREVIEW_EVENT_PRESET_DEFINITIONS, o as cartBlockRuntime, on as splitSiteChromePlacementClasses, ot as normalizeOfferingsPreviewItemLimit, p as productListBlockRuntime, pn as DEFAULT_MAILING_LIST_TARGETING, q as buildEventRegistrationInteractiveIslandProps, qt as getContainerClass, r as buildProductDetailInteractiveIslandProps, rn as staticHeaderChromeRuntime, rt as buildOfferingsPreviewListing, sn as publicMembershipProductCollectionSchema, st as offeringsListingFor, t as buildCartInteractiveIslandProps, un as assessMailingListTargeting, ut as resolveOfferingsPreviewRunPath, wt as buildEventCalendarInteractiveIslandProps, xt as buildEventCombinedListingDisplay, yt as occurrenceContextSchema, z as buildGiftingInteractiveIslandProps, zt as catalogueEventCardProps } from "./shop.interactive-5SnnDHz3.mjs";
|
|
12
|
+
import { n as resolveEventLinkProps, t as resolveEventCta } from "./cta-CUXhX_D7.mjs";
|
|
13
|
+
import { a as buildMonthDay, i as CalendarDayHeaders, n as WeekAgendaView, o as resolveMonthSelectedDay, s as formatEventLocation } from "./CalendarNavigationChevron-CHSi9b3E.mjs";
|
|
14
|
+
import { n as CardListItems, r as EventItem } from "./EventItem-CXhnT9pF.mjs";
|
|
15
|
+
import { S as asPartialObject, d as resolveCardRoleForBoxStyles, g as DEFAULT_SECTION_SPACING, i as EventCard, n as EmptyState, r as EventCompactRow, s as boxStyleClassNames, t as EventListingFrameView, u as normalizeBoxStylesBorder } from "./EventListing.view-B-Yi5JZS.mjs";
|
|
15
16
|
import { t as resolveDedicatedBookingHref } from "./bookingRoute-Bqlyu5Vb.mjs";
|
|
16
|
-
import { a as resolveEventDetailsPresentation, i as derivePreviewRunSchedule, n as eventCardListContent, r as deriveEventScheduleSummary, t as EventDetailsView } from "./view-
|
|
17
|
+
import { a as resolveEventDetailsPresentation, i as derivePreviewRunSchedule, n as eventCardListContent, r as deriveEventScheduleSummary, t as EventDetailsView } from "./view-CseyBW07.mjs";
|
|
17
18
|
import { t as FeedbackMessage } from "./FeedbackMessage-CSJrAuXH.mjs";
|
|
19
|
+
import { a as MonthLookView, c as ButtonNode, d as TextNode, i as buildWeekBoardViewProps, l as LinkNode, n as WeekBoardView, o as CalendarRecurringWeek, r as buildWeekBoardNavigationState, s as RecurringSchedule, t as buildTimetableModel, u as RichTextNode } from "./timetableModel-C19rcHEw.mjs";
|
|
18
20
|
import { a as carouselShape, c as getCarouselSlidesToShowCssVars, i as carouselRegionAttributes, l as normalizeSlidesToShow, n as arrangementCarouselSettings, r as carouselContents, t as CarouselSlideContent, u as resolveSlidesToShowMobile } from "./carousel.shared-DBnWEJzo.mjs";
|
|
19
|
-
import { t as coerceRichTextDoc } from "./richText-coerce-
|
|
21
|
+
import { t as coerceRichTextDoc } from "./richText-coerce-Cv-qomNB.mjs";
|
|
20
22
|
import { t as EVENT_REGISTRATION_ANCHOR_ID } from "./constants-4o4_hl34.mjs";
|
|
21
|
-
import { a as PassPurchaseUnavailable, c as ProductDetailView, d as ShopPurchaseAction, f as VariantSelectView, i as PassCardView, l as ProductGalleryFrameView, n as CheckoutShellView, o as PassesMembershipsSectionView, r as MembershipCardView, s as ProductCardView, t as CartShellView, u as ProductListSectionView } from "./view-
|
|
22
|
-
import { n as EventListWeekNavigation, t as EventListWeekEmptyState } from "./EventListWeekNavigation-
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import { n as
|
|
26
|
-
import { a as partitionNewsletterFields, n as NewsletterSubmitRow, r as NewsletterTopicChips, t as NewsletterExtraField } from "./newsletter-form.parts-CaldoFmi.mjs";
|
|
23
|
+
import { a as PassPurchaseUnavailable, c as ProductDetailView, d as ShopPurchaseAction, f as VariantSelectView, i as PassCardView, l as ProductGalleryFrameView, n as CheckoutShellView, o as PassesMembershipsSectionView, r as MembershipCardView, s as ProductCardView, t as CartShellView, u as ProductListSectionView } from "./view-CkUn3Y0Y.mjs";
|
|
24
|
+
import { n as EventListWeekNavigation, t as EventListWeekEmptyState } from "./EventListWeekNavigation-V-dtoDlD.mjs";
|
|
25
|
+
import { i as RegistrationClosedState, r as BookingEntryCard, t as StepIndicator } from "./StepIndicator-DiD6euZ8.mjs";
|
|
26
|
+
import { n as FormSubmitAction, t as FormFieldGroups } from "./form.parts-mttKpgif.mjs";
|
|
27
|
+
import { a as partitionNewsletterFields, n as NewsletterSubmitRow, r as NewsletterTopicChips, t as NewsletterExtraField } from "./newsletter-form.parts-DKHye4IE.mjs";
|
|
27
28
|
import React, { forwardRef } from "react";
|
|
28
29
|
import { z } from "zod";
|
|
29
30
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -96,7 +97,7 @@ function createButtonGroup(options = {}) {
|
|
|
96
97
|
},
|
|
97
98
|
{
|
|
98
99
|
value: "xl",
|
|
99
|
-
label: "Extra
|
|
100
|
+
label: "Extra large"
|
|
100
101
|
}
|
|
101
102
|
],
|
|
102
103
|
required: false,
|
|
@@ -158,7 +159,7 @@ function createButtonGroup(options = {}) {
|
|
|
158
159
|
const BACKGROUND_POSITION_PRESETS = [
|
|
159
160
|
{
|
|
160
161
|
value: "center",
|
|
161
|
-
label: "
|
|
162
|
+
label: "Centre"
|
|
162
163
|
},
|
|
163
164
|
{
|
|
164
165
|
value: "top",
|
|
@@ -629,7 +630,7 @@ function createBoxStylesFieldWithDepth(type, options = {}) {
|
|
|
629
630
|
id: "spacing",
|
|
630
631
|
type: "select",
|
|
631
632
|
label: "Inner spacing",
|
|
632
|
-
description: `
|
|
633
|
+
description: `Space inside the ${contextName}, around its content.`,
|
|
633
634
|
required: false,
|
|
634
635
|
multiple: false,
|
|
635
636
|
options: [
|
|
@@ -643,7 +644,7 @@ function createBoxStylesFieldWithDepth(type, options = {}) {
|
|
|
643
644
|
},
|
|
644
645
|
{
|
|
645
646
|
value: "cozy",
|
|
646
|
-
label: "
|
|
647
|
+
label: "Cosy"
|
|
647
648
|
},
|
|
648
649
|
{
|
|
649
650
|
value: "medium",
|
|
@@ -669,7 +670,7 @@ function createBoxStylesFieldWithDepth(type, options = {}) {
|
|
|
669
670
|
id: "enabled",
|
|
670
671
|
type: "boolean",
|
|
671
672
|
label: "Show border",
|
|
672
|
-
description: "
|
|
673
|
+
description: "If you don't set this, the card uses your site style's border.",
|
|
673
674
|
required: false
|
|
674
675
|
},
|
|
675
676
|
{
|
|
@@ -704,8 +705,8 @@ function createBoxStylesFieldWithDepth(type, options = {}) {
|
|
|
704
705
|
{
|
|
705
706
|
id: "colorToken",
|
|
706
707
|
type: "text",
|
|
707
|
-
label: "Border
|
|
708
|
-
description: "
|
|
708
|
+
label: "Border colour",
|
|
709
|
+
description: "A colour name from your site style, such as border or primary.",
|
|
709
710
|
required: false,
|
|
710
711
|
multiline: false,
|
|
711
712
|
defaultValue: "border",
|
|
@@ -720,14 +721,14 @@ function createBoxStylesFieldWithDepth(type, options = {}) {
|
|
|
720
721
|
id: "raised",
|
|
721
722
|
type: "boolean",
|
|
722
723
|
label: "Raised",
|
|
723
|
-
description: `
|
|
724
|
+
description: `Adds a soft shadow so the ${contextName} lifts off the page.`,
|
|
724
725
|
required: false
|
|
725
726
|
});
|
|
726
727
|
fields.push({
|
|
727
728
|
id: "rounded",
|
|
728
729
|
type: "select",
|
|
729
730
|
label: "Rounded corners",
|
|
730
|
-
description: "
|
|
731
|
+
description: "How rounded the corners are.",
|
|
731
732
|
required: false,
|
|
732
733
|
multiple: false,
|
|
733
734
|
options: [
|
|
@@ -749,15 +750,15 @@ function createBoxStylesFieldWithDepth(type, options = {}) {
|
|
|
749
750
|
},
|
|
750
751
|
{
|
|
751
752
|
value: "xl",
|
|
752
|
-
label: "Extra
|
|
753
|
+
label: "Extra large"
|
|
753
754
|
},
|
|
754
755
|
{
|
|
755
756
|
value: "2xl",
|
|
756
|
-
label: "Extra
|
|
757
|
+
label: "Extra extra large"
|
|
757
758
|
},
|
|
758
759
|
{
|
|
759
760
|
value: "full",
|
|
760
|
-
label: "Fully
|
|
761
|
+
label: "Fully rounded"
|
|
761
762
|
}
|
|
762
763
|
]
|
|
763
764
|
});
|
|
@@ -765,7 +766,7 @@ function createBoxStylesFieldWithDepth(type, options = {}) {
|
|
|
765
766
|
id: "fullWidth",
|
|
766
767
|
type: "boolean",
|
|
767
768
|
label: "Full width",
|
|
768
|
-
description: "
|
|
769
|
+
description: "Stretches the content right to the edges of the screen.",
|
|
769
770
|
required: false,
|
|
770
771
|
defaultValue: false
|
|
771
772
|
});
|
|
@@ -802,7 +803,7 @@ function sectionStylesField(options = {}) {
|
|
|
802
803
|
id: "spacing",
|
|
803
804
|
type: "select",
|
|
804
805
|
label: "Inner spacing",
|
|
805
|
-
description: "
|
|
806
|
+
description: "Space above and below the section.",
|
|
806
807
|
required: false,
|
|
807
808
|
multiple: false,
|
|
808
809
|
options: [
|
|
@@ -816,7 +817,7 @@ function sectionStylesField(options = {}) {
|
|
|
816
817
|
},
|
|
817
818
|
{
|
|
818
819
|
value: "cozy",
|
|
819
|
-
label: "
|
|
820
|
+
label: "Cosy"
|
|
820
821
|
},
|
|
821
822
|
{
|
|
822
823
|
value: "medium",
|
|
@@ -907,7 +908,7 @@ const cardStylingFields = [
|
|
|
907
908
|
id: "buttonText",
|
|
908
909
|
type: "text",
|
|
909
910
|
label: "Button text",
|
|
910
|
-
description: "
|
|
911
|
+
description: "The text on each event's button.",
|
|
911
912
|
required: false,
|
|
912
913
|
multiline: false,
|
|
913
914
|
defaultValue: "Book",
|
|
@@ -922,7 +923,7 @@ const eventDisplayFields = [
|
|
|
922
923
|
id: "showVenue",
|
|
923
924
|
type: "boolean",
|
|
924
925
|
label: "Show venue",
|
|
925
|
-
description: "
|
|
926
|
+
description: "Shows the venue's name and address.",
|
|
926
927
|
required: false,
|
|
927
928
|
defaultValue: true,
|
|
928
929
|
ui: { intent: "display" }
|
|
@@ -931,7 +932,7 @@ const eventDisplayFields = [
|
|
|
931
932
|
id: "showMap",
|
|
932
933
|
type: "boolean",
|
|
933
934
|
label: "Show venue map",
|
|
934
|
-
description: "
|
|
935
|
+
description: "Shows a map when the event's venue has a location set.",
|
|
935
936
|
required: false,
|
|
936
937
|
defaultValue: true,
|
|
937
938
|
ui: { intent: "display" }
|
|
@@ -940,7 +941,7 @@ const eventDisplayFields = [
|
|
|
940
941
|
id: "showCapacity",
|
|
941
942
|
type: "boolean",
|
|
942
943
|
label: "Show available places",
|
|
943
|
-
description: "
|
|
944
|
+
description: "Shows how many places are left.",
|
|
944
945
|
required: false,
|
|
945
946
|
defaultValue: true,
|
|
946
947
|
ui: { intent: "display" }
|
|
@@ -952,8 +953,8 @@ const eventDisplayFields = [
|
|
|
952
953
|
const emptyStateField = {
|
|
953
954
|
id: "emptyMessage",
|
|
954
955
|
type: "text",
|
|
955
|
-
label: "
|
|
956
|
-
description: "
|
|
956
|
+
label: "If there's nothing to show",
|
|
957
|
+
description: "What visitors see when there are no upcoming events.",
|
|
957
958
|
required: false,
|
|
958
959
|
multiline: false,
|
|
959
960
|
defaultValue: "No upcoming events scheduled.",
|
|
@@ -1284,6 +1285,51 @@ const nodeSchema = z.object({
|
|
|
1284
1285
|
const nodeTreeSchema = nodeSchema.array().or(nodeSchema);
|
|
1285
1286
|
const NodeSchema = nodeSchema;
|
|
1286
1287
|
const NodeTreeSchema = nodeTreeSchema;
|
|
1288
|
+
const SYSTEM_BLOCK_KINDS = [
|
|
1289
|
+
"block.hero",
|
|
1290
|
+
"block.intro",
|
|
1291
|
+
"block.columns",
|
|
1292
|
+
"block.collection",
|
|
1293
|
+
"block.feature-cards",
|
|
1294
|
+
"block.media-text",
|
|
1295
|
+
"block.cta-full",
|
|
1296
|
+
"block.single-button",
|
|
1297
|
+
"block.body-text",
|
|
1298
|
+
"block.location-map",
|
|
1299
|
+
"block.faq",
|
|
1300
|
+
"block.testimonials",
|
|
1301
|
+
"block.team-members",
|
|
1302
|
+
"block.embed",
|
|
1303
|
+
"block.blog-post",
|
|
1304
|
+
"block.blog-listing",
|
|
1305
|
+
"block.site-header",
|
|
1306
|
+
"block.site-footer",
|
|
1307
|
+
"block.form",
|
|
1308
|
+
"block.contact-newsletter",
|
|
1309
|
+
"block.appointment-booking",
|
|
1310
|
+
"block.appointment-services",
|
|
1311
|
+
"block.weekly-slot-availability",
|
|
1312
|
+
"block.event-registration",
|
|
1313
|
+
...[
|
|
1314
|
+
"block.event-details",
|
|
1315
|
+
"block.event-spotlight",
|
|
1316
|
+
"block.event-listing",
|
|
1317
|
+
"block.event-calendar",
|
|
1318
|
+
"block.recurring-schedule",
|
|
1319
|
+
"block.offerings-preview"
|
|
1320
|
+
],
|
|
1321
|
+
"block.shop",
|
|
1322
|
+
"block.product-list",
|
|
1323
|
+
"block.product-detail",
|
|
1324
|
+
"block.cart",
|
|
1325
|
+
"block.checkout",
|
|
1326
|
+
"block.gifting",
|
|
1327
|
+
"block.newsletter-signup",
|
|
1328
|
+
"block.image-gallery",
|
|
1329
|
+
"block.video-grid",
|
|
1330
|
+
"block.audio-player",
|
|
1331
|
+
"block.file-download"
|
|
1332
|
+
];
|
|
1287
1333
|
const MIN_COLUMNS = 1;
|
|
1288
1334
|
const MAX_COLUMNS = 6;
|
|
1289
1335
|
function normalizeInteger(value) {
|
|
@@ -1632,6 +1678,55 @@ function validateLayoutGridConfiguration(data, ctx) {
|
|
|
1632
1678
|
});
|
|
1633
1679
|
}
|
|
1634
1680
|
//#endregion
|
|
1681
|
+
//#region ../blocks/src/system/manifest/sdkBlockPresentationSchema.ts
|
|
1682
|
+
const sdkBlockPresentationShape = {
|
|
1683
|
+
variants: z.record(z.string().min(1), NodeSchema).optional(),
|
|
1684
|
+
defaultVariant: z.string().min(1).optional(),
|
|
1685
|
+
variantOptions: z.record(z.string().min(1), z.object({
|
|
1686
|
+
label: z.string().min(1).optional(),
|
|
1687
|
+
description: z.string().min(1).optional(),
|
|
1688
|
+
icon: z.string().min(1).optional()
|
|
1689
|
+
})).optional()
|
|
1690
|
+
};
|
|
1691
|
+
function validateSdkBlockDeclaration(data, ctx) {
|
|
1692
|
+
validateTitleSource(data, ctx);
|
|
1693
|
+
if (data.layout && data.variants) ctx.addIssue({
|
|
1694
|
+
code: z.ZodIssueCode.custom,
|
|
1695
|
+
message: "Custom block must define either `layout` or `variants`, not both",
|
|
1696
|
+
path: ["variants"]
|
|
1697
|
+
});
|
|
1698
|
+
if (data.variants) validateVariantKeys(data, ctx);
|
|
1699
|
+
}
|
|
1700
|
+
function validateTitleSource(data, ctx) {
|
|
1701
|
+
if (!data.titleSource) return;
|
|
1702
|
+
(Array.isArray(data.titleSource) ? data.titleSource : [data.titleSource]).forEach((source, index) => {
|
|
1703
|
+
if (data.fields.some((field) => field !== null && typeof field === "object" && "id" in field && field.id === source)) return;
|
|
1704
|
+
ctx.addIssue({
|
|
1705
|
+
code: z.ZodIssueCode.custom,
|
|
1706
|
+
message: `titleSource must reference a valid field ID (got "${source}")`,
|
|
1707
|
+
path: Array.isArray(data.titleSource) ? ["titleSource", index] : ["titleSource"]
|
|
1708
|
+
});
|
|
1709
|
+
});
|
|
1710
|
+
}
|
|
1711
|
+
function validateVariantKeys(data, ctx) {
|
|
1712
|
+
const variants = data.variants ?? {};
|
|
1713
|
+
if (Object.keys(variants).length === 0) ctx.addIssue({
|
|
1714
|
+
code: z.ZodIssueCode.custom,
|
|
1715
|
+
message: "`variants` must contain at least one variant key",
|
|
1716
|
+
path: ["variants"]
|
|
1717
|
+
});
|
|
1718
|
+
if (data.defaultVariant && !Object.prototype.hasOwnProperty.call(variants, data.defaultVariant)) ctx.addIssue({
|
|
1719
|
+
code: z.ZodIssueCode.custom,
|
|
1720
|
+
message: "`defaultVariant` must be a key present in `variants`",
|
|
1721
|
+
path: ["defaultVariant"]
|
|
1722
|
+
});
|
|
1723
|
+
Object.keys(data.variantOptions ?? {}).filter((key) => !Object.prototype.hasOwnProperty.call(variants, key)).forEach((key) => ctx.addIssue({
|
|
1724
|
+
code: z.ZodIssueCode.custom,
|
|
1725
|
+
message: "`variantOptions` key must exist in `variants`",
|
|
1726
|
+
path: ["variantOptions", key]
|
|
1727
|
+
}));
|
|
1728
|
+
}
|
|
1729
|
+
//#endregion
|
|
1635
1730
|
//#region ../blocks/src/system/manifest/schema.ts
|
|
1636
1731
|
const visibilityLevels = [
|
|
1637
1732
|
"admin",
|
|
@@ -2248,19 +2343,21 @@ const behaviourSchema = z.object({
|
|
|
2248
2343
|
paletteHidden: z.boolean().default(false),
|
|
2249
2344
|
managesOwnWrapper: z.boolean().optional()
|
|
2250
2345
|
});
|
|
2251
|
-
const
|
|
2252
|
-
|
|
2253
|
-
|
|
2254
|
-
|
|
2255
|
-
|
|
2256
|
-
|
|
2257
|
-
|
|
2258
|
-
|
|
2259
|
-
seenFieldIds.add(fieldId);
|
|
2260
|
-
}
|
|
2261
|
-
});
|
|
2262
|
-
const previewCustomizeManifestCurationSchema = z.object({ quickFieldPriority: quickFieldPrioritySchema });
|
|
2346
|
+
const builtInBlockKindsSchema = z.array(z.enum(SYSTEM_BLOCK_KINDS)).readonly();
|
|
2347
|
+
const blockRequiredFeatureSchema = z.enum([
|
|
2348
|
+
"bookings.appointments",
|
|
2349
|
+
"bookings.events",
|
|
2350
|
+
"shop",
|
|
2351
|
+
"newsletter",
|
|
2352
|
+
"analytics"
|
|
2353
|
+
]);
|
|
2263
2354
|
const blockCategoryEnum = z.enum([
|
|
2355
|
+
"text-and-images",
|
|
2356
|
+
"photos",
|
|
2357
|
+
"people",
|
|
2358
|
+
"events-and-bookings",
|
|
2359
|
+
"shop",
|
|
2360
|
+
"forms-and-sign-ups",
|
|
2264
2361
|
"marketing",
|
|
2265
2362
|
"content",
|
|
2266
2363
|
"blog",
|
|
@@ -2293,7 +2390,6 @@ z.object({
|
|
|
2293
2390
|
slots: slotSchema.array().default([]),
|
|
2294
2391
|
styleTokens: styleTokenSchema.optional(),
|
|
2295
2392
|
behaviours: behaviourSchema.optional(),
|
|
2296
|
-
previewCustomize: previewCustomizeManifestCurationSchema.optional(),
|
|
2297
2393
|
layout: NodeTreeSchema.optional(),
|
|
2298
2394
|
/**
|
|
2299
2395
|
* Optional list of nested field paths that should be surfaced in the main form body
|
|
@@ -2302,6 +2398,19 @@ z.object({
|
|
|
2302
2398
|
*
|
|
2303
2399
|
* The original fields remain available in settings for power users.
|
|
2304
2400
|
*/
|
|
2401
|
+
lookField: z.string().min(1).optional(),
|
|
2402
|
+
sourceLine: z.object({
|
|
2403
|
+
text: z.string(),
|
|
2404
|
+
target: z.enum([
|
|
2405
|
+
"testimonials",
|
|
2406
|
+
"team",
|
|
2407
|
+
"mailing-lists"
|
|
2408
|
+
]),
|
|
2409
|
+
when: z.object({
|
|
2410
|
+
field: z.string(),
|
|
2411
|
+
equals: z.string()
|
|
2412
|
+
}).optional()
|
|
2413
|
+
}).optional(),
|
|
2305
2414
|
promotedFields: z.array(z.string().min(1)).optional(),
|
|
2306
2415
|
variantMeaning: z.discriminatedUnion("kind", [z.object({
|
|
2307
2416
|
kind: z.literal("arrangement"),
|
|
@@ -2323,6 +2432,7 @@ z.object({
|
|
|
2323
2432
|
}).optional()).optional(),
|
|
2324
2433
|
category: blockCategoryEnum.optional(),
|
|
2325
2434
|
contentTypes: z.array(z.string()).optional(),
|
|
2435
|
+
requiredFeatures: z.array(blockRequiredFeatureSchema).optional(),
|
|
2326
2436
|
/**
|
|
2327
2437
|
* Explicit content-source classification (inline / entries / mixed). Optional at the
|
|
2328
2438
|
* schema level for backward compatibility with SDK-defined custom blocks, but every
|
|
@@ -2332,141 +2442,139 @@ z.object({
|
|
|
2332
2442
|
tags: z.array(z.string()).optional(),
|
|
2333
2443
|
icon: z.string().optional()
|
|
2334
2444
|
});
|
|
2335
|
-
|
|
2336
|
-
|
|
2337
|
-
|
|
2338
|
-
|
|
2339
|
-
|
|
2340
|
-
|
|
2341
|
-
|
|
2342
|
-
|
|
2343
|
-
"contrast"
|
|
2344
|
-
])
|
|
2345
|
-
}),
|
|
2346
|
-
z.object({
|
|
2347
|
-
kind: z.literal("highlight"),
|
|
2348
|
-
tone: z.enum([
|
|
2349
|
-
"soft",
|
|
2350
|
-
"accent",
|
|
2351
|
-
"brand"
|
|
2352
|
-
])
|
|
2353
|
-
})
|
|
2354
|
-
]);
|
|
2355
|
-
const inlineTextRunSchema = z.object({
|
|
2356
|
-
text: z.string(),
|
|
2357
|
-
marks: z.array(inlineTextMarkSchema).optional()
|
|
2358
|
-
});
|
|
2359
|
-
z.array(inlineTextRunSchema);
|
|
2360
|
-
const MARK_ORDER = {
|
|
2361
|
-
strong: 0,
|
|
2362
|
-
emphasis: 1,
|
|
2363
|
-
accent: 2,
|
|
2364
|
-
highlight: 3
|
|
2365
|
-
};
|
|
2366
|
-
function plainTextToInlineText(value) {
|
|
2367
|
-
return normalizeInlineText(value.length > 0 ? [{ text: value }] : []);
|
|
2368
|
-
}
|
|
2369
|
-
function inlineTextToPlainText(value) {
|
|
2370
|
-
return value.map((run) => run.text).join("");
|
|
2445
|
+
/** SDK Looks name a single top-level select owned by this definition. */
|
|
2446
|
+
function validateManifestLookField(data, ctx) {
|
|
2447
|
+
if (!data.lookField) return;
|
|
2448
|
+
if (!data.fields.some((field) => field !== null && typeof field === "object" && "id" in field && field.id === data.lookField && "type" in field && field.type === "select" && (!("multiple" in field) || field.multiple !== true))) ctx.addIssue({
|
|
2449
|
+
code: z.ZodIssueCode.custom,
|
|
2450
|
+
path: ["lookField"],
|
|
2451
|
+
message: "lookField must name an existing single select field"
|
|
2452
|
+
});
|
|
2371
2453
|
}
|
|
2372
|
-
|
|
2373
|
-
|
|
2454
|
+
const blockSectionDeclarationShape = {
|
|
2455
|
+
promotedFields: z.array(z.string().min(1)).optional(),
|
|
2456
|
+
lookField: z.string().min(1).optional()
|
|
2457
|
+
};
|
|
2458
|
+
//#endregion
|
|
2459
|
+
//#region ../blocks/src/system/readiness.ts
|
|
2460
|
+
const ready = { kind: "Ready" };
|
|
2461
|
+
const unknownReadiness = { kind: "Unknown" };
|
|
2462
|
+
const loadedReadinessFact = (value) => ({
|
|
2463
|
+
kind: "Loaded",
|
|
2464
|
+
value
|
|
2465
|
+
});
|
|
2466
|
+
const unavailableReadinessFact = { kind: "Unavailable" };
|
|
2467
|
+
function needsSetup(reason, repair) {
|
|
2468
|
+
return {
|
|
2469
|
+
kind: "NeedsSetup",
|
|
2470
|
+
reason,
|
|
2471
|
+
repair
|
|
2472
|
+
};
|
|
2374
2473
|
}
|
|
2375
|
-
|
|
2376
|
-
|
|
2377
|
-
|
|
2378
|
-
if (fallbackPlainText && fallbackPlainText.length > 0) return plainTextToInlineText(fallbackPlainText);
|
|
2379
|
-
return parsed.ok ? parsed.value : [];
|
|
2474
|
+
/** One boundary owns runtime stage checking and the resulting phantom proof. */
|
|
2475
|
+
function admitReadinessFacts(stage, input) {
|
|
2476
|
+
return input.stage === stage ? input.facts : unavailableReadinessFacts();
|
|
2380
2477
|
}
|
|
2381
|
-
function
|
|
2382
|
-
if (!Array.isArray(value)) return {
|
|
2383
|
-
ok: false,
|
|
2384
|
-
error: { kind: "not-array" }
|
|
2385
|
-
};
|
|
2386
|
-
const runs = [];
|
|
2387
|
-
for (let index = 0; index < value.length; index += 1) {
|
|
2388
|
-
const parsed = inlineTextRunSchema.safeParse(value[index]);
|
|
2389
|
-
if (!parsed.success) return {
|
|
2390
|
-
ok: false,
|
|
2391
|
-
error: {
|
|
2392
|
-
kind: "invalid-run",
|
|
2393
|
-
index
|
|
2394
|
-
}
|
|
2395
|
-
};
|
|
2396
|
-
runs.push(parsed.data);
|
|
2397
|
-
}
|
|
2478
|
+
function unavailableReadinessFacts() {
|
|
2398
2479
|
return {
|
|
2399
|
-
|
|
2400
|
-
|
|
2480
|
+
mailingList: unavailableReadinessFact,
|
|
2481
|
+
testimonials: unavailableReadinessFact,
|
|
2482
|
+
team: unavailableReadinessFact,
|
|
2483
|
+
forms: /* @__PURE__ */ new Map(),
|
|
2484
|
+
products: /* @__PURE__ */ new Map(),
|
|
2485
|
+
template: unavailableReadinessFact
|
|
2401
2486
|
};
|
|
2402
2487
|
}
|
|
2403
|
-
function
|
|
2404
|
-
|
|
2405
|
-
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
|
|
2409
|
-
|
|
2410
|
-
|
|
2411
|
-
|
|
2412
|
-
const
|
|
2413
|
-
if (
|
|
2414
|
-
|
|
2415
|
-
|
|
2416
|
-
|
|
2417
|
-
|
|
2418
|
-
|
|
2419
|
-
|
|
2420
|
-
|
|
2488
|
+
function pageTemplateFromEntry(entry) {
|
|
2489
|
+
return entry?._contentTypeSlug === "product" ? { kind: "product" } : { kind: "page" };
|
|
2490
|
+
}
|
|
2491
|
+
//#endregion
|
|
2492
|
+
//#region ../blocks/src/system/blocks/readiness.ts
|
|
2493
|
+
const newsletterReadiness = {
|
|
2494
|
+
needs: ["mailingList"],
|
|
2495
|
+
assess: (content, facts) => {
|
|
2496
|
+
if (facts.mailingList.kind === "Unavailable") return unknownReadiness;
|
|
2497
|
+
const targeting = parseMailingListPlacementTargeting(content.targeting ?? { mode: "default" });
|
|
2498
|
+
if (!targeting.ok) return unknownReadiness;
|
|
2499
|
+
const assessment = assessMailingListTargeting(facts.mailingList.value, targeting.value);
|
|
2500
|
+
return assessment.tag === "available" ? ready : assessment.reason === "setup_missing" ? needsSetup("mailing_setup", {
|
|
2501
|
+
kind: "manage",
|
|
2502
|
+
target: "mailingLists"
|
|
2503
|
+
}) : needsSetup("mailing_destination", {
|
|
2504
|
+
kind: "field",
|
|
2505
|
+
path: "targeting"
|
|
2506
|
+
});
|
|
2421
2507
|
}
|
|
2422
|
-
|
|
2423
|
-
|
|
2424
|
-
|
|
2425
|
-
|
|
2426
|
-
|
|
2427
|
-
|
|
2428
|
-
|
|
2429
|
-
|
|
2430
|
-
|
|
2431
|
-
|
|
2432
|
-
|
|
2433
|
-
|
|
2434
|
-
|
|
2435
|
-
|
|
2436
|
-
|
|
2437
|
-
accent = {
|
|
2438
|
-
kind: "accent",
|
|
2439
|
-
tone: mark.tone
|
|
2440
|
-
};
|
|
2441
|
-
break;
|
|
2442
|
-
case "highlight":
|
|
2443
|
-
highlight = {
|
|
2444
|
-
kind: "highlight",
|
|
2445
|
-
tone: mark.tone
|
|
2446
|
-
};
|
|
2447
|
-
break;
|
|
2508
|
+
};
|
|
2509
|
+
const formReadiness = {
|
|
2510
|
+
needs: ["forms"],
|
|
2511
|
+
assess: (content, facts) => {
|
|
2512
|
+
const selection = chosenString(content.formSlug);
|
|
2513
|
+
if (!selection) return needsSetup("form_not_chosen", {
|
|
2514
|
+
kind: "field",
|
|
2515
|
+
path: "formSlug"
|
|
2516
|
+
});
|
|
2517
|
+
const form = facts.forms.get(selection);
|
|
2518
|
+
if (!form || form.kind === "Unavailable") return unknownReadiness;
|
|
2519
|
+
return form.value ? ready : needsSetup("form_deleted", {
|
|
2520
|
+
kind: "field",
|
|
2521
|
+
path: "formSlug"
|
|
2522
|
+
});
|
|
2448
2523
|
}
|
|
2449
|
-
|
|
2450
|
-
|
|
2451
|
-
|
|
2452
|
-
|
|
2453
|
-
|
|
2454
|
-
|
|
2455
|
-
|
|
2456
|
-
|
|
2457
|
-
|
|
2458
|
-
|
|
2459
|
-
|
|
2460
|
-
|
|
2461
|
-
}
|
|
2462
|
-
|
|
2463
|
-
|
|
2464
|
-
|
|
2465
|
-
|
|
2466
|
-
|
|
2467
|
-
|
|
2468
|
-
|
|
2524
|
+
};
|
|
2525
|
+
const testimonialsReadiness = {
|
|
2526
|
+
needs: ["testimonials"],
|
|
2527
|
+
assess: (_content, facts) => {
|
|
2528
|
+
if (facts.testimonials.kind === "Unavailable") return unknownReadiness;
|
|
2529
|
+
const { count, total } = facts.testimonials.value;
|
|
2530
|
+
if (count > 0) return ready;
|
|
2531
|
+
return needsSetup(total === "unknown" ? "testimonials_empty" : total > 0 ? "testimonials_unpublished" : "testimonials_none", {
|
|
2532
|
+
kind: "manage",
|
|
2533
|
+
target: "testimonials"
|
|
2534
|
+
});
|
|
2535
|
+
}
|
|
2536
|
+
};
|
|
2537
|
+
const teamReadiness = {
|
|
2538
|
+
needs: ["team"],
|
|
2539
|
+
assess: (content, facts) => {
|
|
2540
|
+
if (content.source !== "site_staff") return Array.isArray(content.members) && content.members.length > 0 ? ready : needsSetup("members_empty", {
|
|
2541
|
+
kind: "field",
|
|
2542
|
+
path: "members"
|
|
2543
|
+
});
|
|
2544
|
+
if (facts.team.kind === "Unavailable") return unknownReadiness;
|
|
2545
|
+
return facts.team.value > 0 ? ready : needsSetup("team_empty", {
|
|
2546
|
+
kind: "manage",
|
|
2547
|
+
target: "team"
|
|
2548
|
+
});
|
|
2549
|
+
}
|
|
2550
|
+
};
|
|
2551
|
+
const productReadiness = {
|
|
2552
|
+
needs: ["template", "products"],
|
|
2553
|
+
assess: (content, facts) => {
|
|
2554
|
+
if (facts.template.kind === "Unavailable") return unknownReadiness;
|
|
2555
|
+
if (facts.template.value.kind === "product") return ready;
|
|
2556
|
+
const selection = chosenString(content.productSlug);
|
|
2557
|
+
if (!selection) return needsSetup("product_not_chosen", {
|
|
2558
|
+
kind: "field",
|
|
2559
|
+
path: "productSlug"
|
|
2560
|
+
});
|
|
2561
|
+
const product = facts.products.get(selection);
|
|
2562
|
+
if (!product || product.kind === "Unavailable") return unknownReadiness;
|
|
2563
|
+
return product.value ? ready : needsSetup("product_gone", {
|
|
2564
|
+
kind: "field",
|
|
2565
|
+
path: "productSlug"
|
|
2566
|
+
});
|
|
2469
2567
|
}
|
|
2568
|
+
};
|
|
2569
|
+
const galleryReadiness = {
|
|
2570
|
+
needs: [],
|
|
2571
|
+
assess: (content) => Array.isArray(content.images) && content.images.length > 0 ? ready : needsSetup("gallery_empty", {
|
|
2572
|
+
kind: "field",
|
|
2573
|
+
path: "images"
|
|
2574
|
+
})
|
|
2575
|
+
};
|
|
2576
|
+
function chosenString(value) {
|
|
2577
|
+
return typeof value === "string" && value.trim() ? value.trim() : null;
|
|
2470
2578
|
}
|
|
2471
2579
|
//#endregion
|
|
2472
2580
|
//#region ../blocks/src/system/manifest/augmentManifest.ts
|
|
@@ -2502,7 +2610,7 @@ function createVariantField(manifest) {
|
|
|
2502
2610
|
id: "variant",
|
|
2503
2611
|
type: "select",
|
|
2504
2612
|
label: "Variant",
|
|
2505
|
-
description: "Choose
|
|
2613
|
+
description: "Choose how this block is laid out.",
|
|
2506
2614
|
ui: { intent: "display" },
|
|
2507
2615
|
required: false,
|
|
2508
2616
|
defaultValue: manifest.defaultVariant ?? variantKeys[0],
|
|
@@ -2574,7 +2682,7 @@ function parseSiteIconStyleGuideVersionId(value) {
|
|
|
2574
2682
|
//#endregion
|
|
2575
2683
|
//#region ../blocks/src/system/icons/value.ts
|
|
2576
2684
|
const NO_BLOCK_ICON_VALUE = { kind: "none" };
|
|
2577
|
-
function isRecord
|
|
2685
|
+
function isRecord(value) {
|
|
2578
2686
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
2579
2687
|
}
|
|
2580
2688
|
function parseBlockIconValue(value) {
|
|
@@ -2582,7 +2690,7 @@ function parseBlockIconValue(value) {
|
|
|
2582
2690
|
kind: "semantic",
|
|
2583
2691
|
iconId: value
|
|
2584
2692
|
};
|
|
2585
|
-
if (!isRecord
|
|
2693
|
+
if (!isRecord(value)) return NO_BLOCK_ICON_VALUE;
|
|
2586
2694
|
switch (value.kind) {
|
|
2587
2695
|
case "none": return NO_BLOCK_ICON_VALUE;
|
|
2588
2696
|
case "semantic": return isSemanticIconId(value.iconId) ? {
|
|
@@ -2655,7 +2763,7 @@ function buildGeneratedBlockIconRenderAssetLookupFromUnknown(value) {
|
|
|
2655
2763
|
if (!Array.isArray(value)) return { kind: "invalid_asset_list" };
|
|
2656
2764
|
const inputs = [];
|
|
2657
2765
|
for (const [index, item] of value.entries()) {
|
|
2658
|
-
if (!isRecord
|
|
2766
|
+
if (!isRecord(item)) return {
|
|
2659
2767
|
kind: "invalid_asset_entry",
|
|
2660
2768
|
index,
|
|
2661
2769
|
reason: "not_object"
|
|
@@ -3653,7 +3761,7 @@ const formEmbedFragment = defineFragment({
|
|
|
3653
3761
|
id: "formSlug",
|
|
3654
3762
|
type: "reference",
|
|
3655
3763
|
label: "Form",
|
|
3656
|
-
description: "
|
|
3764
|
+
description: "Choose which of your forms to show.",
|
|
3657
3765
|
required: true,
|
|
3658
3766
|
referenceKind: "form",
|
|
3659
3767
|
allowManualEntry: false,
|
|
@@ -3669,7 +3777,7 @@ const formEmbedFragment = defineFragment({
|
|
|
3669
3777
|
id: "successMessage",
|
|
3670
3778
|
type: "text",
|
|
3671
3779
|
label: "Success message",
|
|
3672
|
-
description: "
|
|
3780
|
+
description: "What visitors see after they've sent the form."
|
|
3673
3781
|
}
|
|
3674
3782
|
],
|
|
3675
3783
|
layout: [form(withApiBindings({
|
|
@@ -3737,7 +3845,7 @@ const newsletterFormFragment = defineFragment({
|
|
|
3737
3845
|
{
|
|
3738
3846
|
id: "targeting",
|
|
3739
3847
|
type: "group",
|
|
3740
|
-
label: "
|
|
3848
|
+
label: "Where sign-ups go",
|
|
3741
3849
|
description: "Choose what kind of emails people signing up here will receive.",
|
|
3742
3850
|
defaultValue: { mode: "default" },
|
|
3743
3851
|
required: true,
|
|
@@ -3853,9 +3961,9 @@ function createBlockManifest(config) {
|
|
|
3853
3961
|
slots: [],
|
|
3854
3962
|
styleTokens: config.styleTokens,
|
|
3855
3963
|
behaviours,
|
|
3856
|
-
previewCustomize: config.previewCustomize,
|
|
3857
3964
|
category: config.category,
|
|
3858
3965
|
contentTypes: config.contentTypes ? [...config.contentTypes] : void 0,
|
|
3966
|
+
requiredFeatures: config.requiredFeatures ? [...config.requiredFeatures] : void 0,
|
|
3859
3967
|
contentSource: config.contentSource,
|
|
3860
3968
|
tags: config.tags ? [...config.tags] : [],
|
|
3861
3969
|
icon: config.icon ?? "Box",
|
|
@@ -3864,6 +3972,8 @@ function createBlockManifest(config) {
|
|
|
3864
3972
|
variantMeaning: config.variantMeaning,
|
|
3865
3973
|
defaultVariant: config.defaultVariant,
|
|
3866
3974
|
variantOptions: config.variantOptions,
|
|
3975
|
+
lookField: config.lookField,
|
|
3976
|
+
sourceLine: config.sourceLine,
|
|
3867
3977
|
promotedFields: config.promotedFields ? [...config.promotedFields] : void 0
|
|
3868
3978
|
});
|
|
3869
3979
|
}
|
|
@@ -3919,7 +4029,14 @@ function blockBehaviours(config) {
|
|
|
3919
4029
|
}
|
|
3920
4030
|
//#endregion
|
|
3921
4031
|
//#region ../blocks/src/system/blocks/form.tsx
|
|
3922
|
-
const
|
|
4032
|
+
const setupFormEmbedFragment = {
|
|
4033
|
+
...formEmbedFragment,
|
|
4034
|
+
fields: formEmbedFragment.fields.map((field) => field.id === "formSlug" ? {
|
|
4035
|
+
...field,
|
|
4036
|
+
required: false
|
|
4037
|
+
} : field)
|
|
4038
|
+
};
|
|
4039
|
+
const formComposition = composeFragments([{ fragment: formCopyFragment }, { fragment: setupFormEmbedFragment }]);
|
|
3923
4040
|
function fragmentLayoutNode(layout) {
|
|
3924
4041
|
return isNodeDefinitionArray(layout) ? el("div", {}, [...layout]) : layout;
|
|
3925
4042
|
}
|
|
@@ -3968,15 +4085,20 @@ const formLayout = styledSection({
|
|
|
3968
4085
|
spacing: "medium",
|
|
3969
4086
|
background: "surface"
|
|
3970
4087
|
});
|
|
3971
|
-
const
|
|
4088
|
+
const fragmentDataLoaders = buildFragmentDataLoaders(formComposition);
|
|
4089
|
+
const dataLoaders = Object.fromEntries(Object.entries(fragmentDataLoaders).map(([key, loader]) => [key, key === "form" ? {
|
|
4090
|
+
...loader,
|
|
4091
|
+
requiredParams: ["formSlug"]
|
|
4092
|
+
} : loader]));
|
|
3972
4093
|
const formManifest = createBlockManifest({
|
|
3973
4094
|
variantMeaning: { kind: "arrangement" },
|
|
3974
4095
|
id: "block.form",
|
|
4096
|
+
promotedFields: ["formSlug"],
|
|
3975
4097
|
title: "Form",
|
|
3976
4098
|
titleSource: "title",
|
|
3977
|
-
description: "
|
|
4099
|
+
description: "Shows one of your forms so visitors can get in touch.",
|
|
3978
4100
|
includeContainerStyles: true,
|
|
3979
|
-
fragments: [{ fragment: formCopyFragment }, { fragment:
|
|
4101
|
+
fragments: [{ fragment: formCopyFragment }, { fragment: setupFormEmbedFragment }],
|
|
3980
4102
|
additionalFields: [{
|
|
3981
4103
|
id: "archFrame",
|
|
3982
4104
|
type: "boolean",
|
|
@@ -4015,7 +4137,7 @@ const formManifest = createBlockManifest({
|
|
|
4015
4137
|
animation: false,
|
|
4016
4138
|
paletteHidden: false
|
|
4017
4139
|
},
|
|
4018
|
-
category: "
|
|
4140
|
+
category: "forms-and-sign-ups",
|
|
4019
4141
|
contentSource: { kind: "inline" },
|
|
4020
4142
|
tags: [
|
|
4021
4143
|
"form",
|
|
@@ -4041,6 +4163,7 @@ const formDataSchema = z.object({
|
|
|
4041
4163
|
});
|
|
4042
4164
|
const formBlockDefinition = {
|
|
4043
4165
|
manifest: formManifest,
|
|
4166
|
+
readiness: formReadiness,
|
|
4044
4167
|
dataSchemas: { form: formDataSchema.optional() },
|
|
4045
4168
|
dataLoaders,
|
|
4046
4169
|
runtime: formBlockRuntime
|
|
@@ -4311,10 +4434,11 @@ const eventRegistrationManifest = createBlockManifest({
|
|
|
4311
4434
|
variantMeaning: { kind: "arrangement" },
|
|
4312
4435
|
id: "block.event-registration",
|
|
4313
4436
|
version: "1.0.0",
|
|
4314
|
-
title: "Event
|
|
4437
|
+
title: "Event registration",
|
|
4315
4438
|
titleSource: "heading",
|
|
4316
|
-
description: "
|
|
4317
|
-
category: "
|
|
4439
|
+
description: "The booking form for an event, where people choose their tickets.",
|
|
4440
|
+
category: "events-and-bookings",
|
|
4441
|
+
requiredFeatures: ["bookings.events"],
|
|
4318
4442
|
contentSource: { kind: "inline" },
|
|
4319
4443
|
tags: [
|
|
4320
4444
|
"events",
|
|
@@ -4340,7 +4464,7 @@ const eventRegistrationManifest = createBlockManifest({
|
|
|
4340
4464
|
id: "heading",
|
|
4341
4465
|
type: "text",
|
|
4342
4466
|
label: "Heading",
|
|
4343
|
-
description: "
|
|
4467
|
+
description: "The heading above the booking form.",
|
|
4344
4468
|
required: false,
|
|
4345
4469
|
multiline: false,
|
|
4346
4470
|
defaultValue: ""
|
|
@@ -4355,8 +4479,8 @@ const eventRegistrationManifest = createBlockManifest({
|
|
|
4355
4479
|
{
|
|
4356
4480
|
id: "maxTickets",
|
|
4357
4481
|
type: "select",
|
|
4358
|
-
label: "
|
|
4359
|
-
description: "
|
|
4482
|
+
label: "Most tickets per booking",
|
|
4483
|
+
description: "The most tickets one person can book at once.",
|
|
4360
4484
|
required: false,
|
|
4361
4485
|
multiple: false,
|
|
4362
4486
|
defaultValue: "5",
|
|
@@ -4388,7 +4512,7 @@ const eventRegistrationManifest = createBlockManifest({
|
|
|
4388
4512
|
id: "showVenue",
|
|
4389
4513
|
type: "boolean",
|
|
4390
4514
|
label: "Show venue",
|
|
4391
|
-
description: "
|
|
4515
|
+
description: "Shows where the event is.",
|
|
4392
4516
|
required: false,
|
|
4393
4517
|
defaultValue: true,
|
|
4394
4518
|
ui: { intent: "display" }
|
|
@@ -4397,7 +4521,7 @@ const eventRegistrationManifest = createBlockManifest({
|
|
|
4397
4521
|
id: "showCapacity",
|
|
4398
4522
|
type: "boolean",
|
|
4399
4523
|
label: "Show available places",
|
|
4400
|
-
description: "
|
|
4524
|
+
description: "Shows how many places are left.",
|
|
4401
4525
|
required: false,
|
|
4402
4526
|
defaultValue: true,
|
|
4403
4527
|
ui: { intent: "display" }
|
|
@@ -4406,7 +4530,7 @@ const eventRegistrationManifest = createBlockManifest({
|
|
|
4406
4530
|
id: "successMessage",
|
|
4407
4531
|
type: "text",
|
|
4408
4532
|
label: "Success message",
|
|
4409
|
-
description: "
|
|
4533
|
+
description: "What people see once they've booked.",
|
|
4410
4534
|
required: false,
|
|
4411
4535
|
multiline: true,
|
|
4412
4536
|
maxLength: 500,
|
|
@@ -4560,9 +4684,9 @@ const eventListingBlockDefinition = {
|
|
|
4560
4684
|
variantMeaning: { kind: "arrangement" },
|
|
4561
4685
|
id: "block.event-listing",
|
|
4562
4686
|
version: "1.1.0",
|
|
4563
|
-
title: "Event
|
|
4687
|
+
title: "Event listing",
|
|
4564
4688
|
titleSource: "heading",
|
|
4565
|
-
description: "
|
|
4689
|
+
description: "All your upcoming events in one list.",
|
|
4566
4690
|
skipSectionStyles: true,
|
|
4567
4691
|
additionalFields: [
|
|
4568
4692
|
...sectionHeaderFields("All Events"),
|
|
@@ -4589,27 +4713,26 @@ const eventListingBlockDefinition = {
|
|
|
4589
4713
|
{
|
|
4590
4714
|
id: "eventsPerPage",
|
|
4591
4715
|
type: "select",
|
|
4592
|
-
label: "
|
|
4593
|
-
description: "Number of events to load at a time",
|
|
4716
|
+
label: "How many",
|
|
4594
4717
|
required: false,
|
|
4595
4718
|
multiple: false,
|
|
4596
4719
|
defaultValue: "12",
|
|
4597
4720
|
options: [
|
|
4598
4721
|
{
|
|
4599
4722
|
value: "3",
|
|
4600
|
-
label: "3
|
|
4723
|
+
label: "Show the first 3"
|
|
4601
4724
|
},
|
|
4602
4725
|
{
|
|
4603
4726
|
value: "6",
|
|
4604
|
-
label: "6
|
|
4727
|
+
label: "Show the first 6"
|
|
4605
4728
|
},
|
|
4606
4729
|
{
|
|
4607
4730
|
value: "12",
|
|
4608
|
-
label: "12
|
|
4731
|
+
label: "Show the first 12"
|
|
4609
4732
|
},
|
|
4610
4733
|
{
|
|
4611
4734
|
value: "24",
|
|
4612
|
-
label: "24
|
|
4735
|
+
label: "Show the first 24"
|
|
4613
4736
|
}
|
|
4614
4737
|
],
|
|
4615
4738
|
ui: { intent: "display" }
|
|
@@ -4618,7 +4741,7 @@ const eventListingBlockDefinition = {
|
|
|
4618
4741
|
id: "paginationMode",
|
|
4619
4742
|
type: "select",
|
|
4620
4743
|
label: "More events",
|
|
4621
|
-
description: "How
|
|
4744
|
+
description: "How visitors can see the rest of your events.",
|
|
4622
4745
|
required: false,
|
|
4623
4746
|
multiple: false,
|
|
4624
4747
|
defaultValue: "loadMore",
|
|
@@ -4634,7 +4757,7 @@ const eventListingBlockDefinition = {
|
|
|
4634
4757
|
{
|
|
4635
4758
|
id: "seeAllUrl",
|
|
4636
4759
|
type: "link",
|
|
4637
|
-
label: "
|
|
4760
|
+
label: "Link to the full list",
|
|
4638
4761
|
required: false,
|
|
4639
4762
|
ui: {
|
|
4640
4763
|
intent: "display",
|
|
@@ -4647,8 +4770,8 @@ const eventListingBlockDefinition = {
|
|
|
4647
4770
|
{
|
|
4648
4771
|
id: "loadMoreText",
|
|
4649
4772
|
type: "text",
|
|
4650
|
-
label: "
|
|
4651
|
-
description: "
|
|
4773
|
+
label: "More events button text",
|
|
4774
|
+
description: "The text on the button or link that shows more events.",
|
|
4652
4775
|
required: false,
|
|
4653
4776
|
multiline: false,
|
|
4654
4777
|
defaultValue: "Load more events",
|
|
@@ -4699,8 +4822,8 @@ const eventListingBlockDefinition = {
|
|
|
4699
4822
|
{
|
|
4700
4823
|
id: "filterEventPresets",
|
|
4701
4824
|
type: "select",
|
|
4702
|
-
label: "
|
|
4703
|
-
description: "
|
|
4825
|
+
label: "Only show these event types",
|
|
4826
|
+
description: "Pick the types of event this block shows.",
|
|
4704
4827
|
required: false,
|
|
4705
4828
|
multiple: true,
|
|
4706
4829
|
defaultValue: [],
|
|
@@ -4737,23 +4860,23 @@ const eventListingBlockDefinition = {
|
|
|
4737
4860
|
{
|
|
4738
4861
|
id: "scheduleScope",
|
|
4739
4862
|
type: "select",
|
|
4740
|
-
label: "
|
|
4741
|
-
description: "
|
|
4863
|
+
label: "Regular or one-off",
|
|
4864
|
+
description: "Show regular events, one-off events or both.",
|
|
4742
4865
|
required: false,
|
|
4743
4866
|
multiple: false,
|
|
4744
4867
|
defaultValue: "any",
|
|
4745
4868
|
options: [
|
|
4746
4869
|
{
|
|
4747
4870
|
value: "any",
|
|
4748
|
-
label: "
|
|
4871
|
+
label: "Both"
|
|
4749
4872
|
},
|
|
4750
4873
|
{
|
|
4751
4874
|
value: "recurring",
|
|
4752
|
-
label: "
|
|
4875
|
+
label: "Regular events only"
|
|
4753
4876
|
},
|
|
4754
4877
|
{
|
|
4755
4878
|
value: "oneOff",
|
|
4756
|
-
label: "One-off only"
|
|
4879
|
+
label: "One-off events only"
|
|
4757
4880
|
}
|
|
4758
4881
|
],
|
|
4759
4882
|
ui: {
|
|
@@ -4804,12 +4927,6 @@ const eventListingBlockDefinition = {
|
|
|
4804
4927
|
"all-events"
|
|
4805
4928
|
],
|
|
4806
4929
|
icon: "List",
|
|
4807
|
-
previewCustomize: { quickFieldPriority: [
|
|
4808
|
-
"layout",
|
|
4809
|
-
"columns",
|
|
4810
|
-
"eventsPerPage",
|
|
4811
|
-
"eventSurface"
|
|
4812
|
-
] },
|
|
4813
4930
|
layout: [styledSection({
|
|
4814
4931
|
children: styledContainer({
|
|
4815
4932
|
rootType: "stack",
|
|
@@ -4941,7 +5058,7 @@ const eventSelectionFields = [{
|
|
|
4941
5058
|
}, createSiteOptionSelectField({
|
|
4942
5059
|
id: "selectedEventSeriesIds",
|
|
4943
5060
|
label: "Selected events",
|
|
4944
|
-
description: "
|
|
5061
|
+
description: "Shows upcoming dates for just these events. The other filters don't apply.",
|
|
4945
5062
|
required: false,
|
|
4946
5063
|
multiple: true,
|
|
4947
5064
|
defaultValue: [],
|
|
@@ -5040,6 +5157,27 @@ const scopeParams = {
|
|
|
5040
5157
|
};
|
|
5041
5158
|
/** Combined renders two jobs; calendar-only variants never pay for the list seed. */
|
|
5042
5159
|
const eventCalendarDataLoaders = {
|
|
5160
|
+
schedule: {
|
|
5161
|
+
endpoint: "listPublicRecurringSchedule",
|
|
5162
|
+
when: { $bind: {
|
|
5163
|
+
from: "content",
|
|
5164
|
+
transforms: [{
|
|
5165
|
+
id: "events.calendarReadEnabled",
|
|
5166
|
+
options: { job: "schedule" }
|
|
5167
|
+
}]
|
|
5168
|
+
} },
|
|
5169
|
+
params: {
|
|
5170
|
+
siteId: scopeParams.siteId,
|
|
5171
|
+
stage: scopeParams.stage,
|
|
5172
|
+
limit: "100",
|
|
5173
|
+
detailLevel: "listing",
|
|
5174
|
+
readProfile: "compact-list",
|
|
5175
|
+
eventSurface: "custom",
|
|
5176
|
+
eventPresets: "class",
|
|
5177
|
+
scheduleScope: "any"
|
|
5178
|
+
},
|
|
5179
|
+
mode: "server"
|
|
5180
|
+
},
|
|
5043
5181
|
events: {
|
|
5044
5182
|
endpoint: "listPublicEvents",
|
|
5045
5183
|
when: { $bind: {
|
|
@@ -5144,153 +5282,190 @@ const eventCalendarLayout = [styledSection({
|
|
|
5144
5282
|
gap: "lg",
|
|
5145
5283
|
...lookSlot("layout")
|
|
5146
5284
|
},
|
|
5147
|
-
children: [
|
|
5148
|
-
|
|
5149
|
-
|
|
5150
|
-
|
|
5151
|
-
|
|
5152
|
-
|
|
5153
|
-
|
|
5154
|
-
|
|
5155
|
-
|
|
5156
|
-
|
|
5157
|
-
|
|
5158
|
-
|
|
5159
|
-
|
|
5160
|
-
|
|
5161
|
-
|
|
5162
|
-
|
|
5163
|
-
|
|
5164
|
-
|
|
5165
|
-
|
|
5166
|
-
|
|
5167
|
-
|
|
5168
|
-
|
|
5169
|
-
|
|
5170
|
-
|
|
5171
|
-
|
|
5172
|
-
|
|
5173
|
-
from: "content.
|
|
5174
|
-
|
|
5175
|
-
|
|
5176
|
-
|
|
5177
|
-
from: "content.
|
|
5178
|
-
|
|
5179
|
-
|
|
5180
|
-
|
|
5181
|
-
|
|
5182
|
-
from: "content.
|
|
5183
|
-
|
|
5184
|
-
|
|
5185
|
-
|
|
5186
|
-
|
|
5187
|
-
|
|
5188
|
-
|
|
5189
|
-
|
|
5190
|
-
|
|
5191
|
-
|
|
5192
|
-
|
|
5193
|
-
|
|
5194
|
-
|
|
5195
|
-
|
|
5196
|
-
|
|
5197
|
-
|
|
5198
|
-
|
|
5199
|
-
|
|
5200
|
-
|
|
5201
|
-
|
|
5202
|
-
|
|
5203
|
-
|
|
5204
|
-
|
|
5205
|
-
|
|
5206
|
-
|
|
5207
|
-
|
|
5208
|
-
|
|
5209
|
-
|
|
5210
|
-
|
|
5211
|
-
|
|
5212
|
-
|
|
5213
|
-
|
|
5214
|
-
|
|
5215
|
-
|
|
5216
|
-
|
|
5217
|
-
|
|
5218
|
-
|
|
5219
|
-
|
|
5220
|
-
|
|
5221
|
-
|
|
5222
|
-
|
|
5223
|
-
|
|
5224
|
-
|
|
5225
|
-
|
|
5226
|
-
|
|
5227
|
-
|
|
5228
|
-
|
|
5229
|
-
|
|
5230
|
-
|
|
5231
|
-
|
|
5232
|
-
|
|
5233
|
-
}
|
|
5234
|
-
|
|
5235
|
-
|
|
5236
|
-
|
|
5237
|
-
|
|
5238
|
-
|
|
5239
|
-
|
|
5240
|
-
|
|
5241
|
-
|
|
5242
|
-
|
|
5243
|
-
|
|
5244
|
-
|
|
5245
|
-
|
|
5246
|
-
|
|
5247
|
-
|
|
5248
|
-
|
|
5249
|
-
|
|
5250
|
-
|
|
5251
|
-
|
|
5252
|
-
|
|
5253
|
-
|
|
5254
|
-
|
|
5255
|
-
|
|
5256
|
-
|
|
5257
|
-
|
|
5258
|
-
|
|
5259
|
-
|
|
5260
|
-
|
|
5261
|
-
|
|
5262
|
-
|
|
5263
|
-
|
|
5264
|
-
|
|
5265
|
-
|
|
5266
|
-
|
|
5267
|
-
|
|
5268
|
-
|
|
5269
|
-
|
|
5270
|
-
|
|
5271
|
-
|
|
5272
|
-
|
|
5273
|
-
|
|
5274
|
-
|
|
5275
|
-
|
|
5276
|
-
|
|
5277
|
-
|
|
5278
|
-
|
|
5279
|
-
|
|
5280
|
-
|
|
5281
|
-
|
|
5282
|
-
|
|
5283
|
-
|
|
5284
|
-
|
|
5285
|
-
|
|
5286
|
-
|
|
5287
|
-
|
|
5285
|
+
children: [
|
|
5286
|
+
text({
|
|
5287
|
+
as: "p",
|
|
5288
|
+
...lookSlot("eyebrow")
|
|
5289
|
+
}, bind("content.eyebrow"), when("content.eyebrow")),
|
|
5290
|
+
...sectionHeaderLayoutNodes({ splitClassName: "event-section-head event-section-head--split" }),
|
|
5291
|
+
el("event-calendar", withApiBindings({
|
|
5292
|
+
readAuthority: { $bind: { from: "$root.readAuthority" } },
|
|
5293
|
+
schedule: { $bind: { from: "data.schedule" } },
|
|
5294
|
+
seeAllButtonVariant: { $bind: {
|
|
5295
|
+
from: "content.seeAllButtonVariant",
|
|
5296
|
+
fallback: "secondary"
|
|
5297
|
+
} },
|
|
5298
|
+
events: { $bind: { from: "data.events" } },
|
|
5299
|
+
effectiveListArrangementKey: { $bind: { from: "$root.effectiveListArrangementKey" } },
|
|
5300
|
+
calendarWindow: { $bind: { from: "data.calendarWindow" } },
|
|
5301
|
+
stage: { $bind: {
|
|
5302
|
+
from: "$root.previewStage",
|
|
5303
|
+
fallback: "published"
|
|
5304
|
+
} },
|
|
5305
|
+
variant: { $bind: { from: "content.variant" } },
|
|
5306
|
+
displayMode: { $bind: { from: "content.displayMode" } },
|
|
5307
|
+
listLayout: { $bind: { from: "content.listLayout" } },
|
|
5308
|
+
listBy: { $bind: { from: "content.listBy" } },
|
|
5309
|
+
bookingTimeZone: { $bind: { from: "$root.dateContext.timeZone" } },
|
|
5310
|
+
dateContext: { $bind: { from: "$root.dateContext" } },
|
|
5311
|
+
monthArrangement: { $bind: { from: "content._lookMonthArrangement" } },
|
|
5312
|
+
lookSlots: { $bind: { from: "content._lookSlots" } },
|
|
5313
|
+
itemActionStyle: { $bind: { from: "content._effectiveKnobs.actionStyle.value" } },
|
|
5314
|
+
showPhotos: { $bind: { from: "content.showPhotos" } },
|
|
5315
|
+
panelHeading: { $bind: { from: "content._lookPanelHeading" } },
|
|
5316
|
+
itemRoles: { $bind: { from: "content._effectiveLook.itemRoles" } },
|
|
5317
|
+
roleSurfaces: { $bind: { from: "content._effectiveLook.roleSurfaces" } },
|
|
5318
|
+
itemSurfaces: { $bind: { from: "content._effectiveLook.itemSurfaces" } },
|
|
5319
|
+
listColumns: { $bind: { from: "content.listColumns" } },
|
|
5320
|
+
layout: { $bind: { from: "content.layout" } },
|
|
5321
|
+
columns: { $bind: { from: "content.columns" } },
|
|
5322
|
+
eventsPerPage: { $bind: { from: "content.eventsPerPage" } },
|
|
5323
|
+
paginationMode: { $bind: {
|
|
5324
|
+
from: "content.paginationMode",
|
|
5325
|
+
fallback: "loadMore"
|
|
5326
|
+
} },
|
|
5327
|
+
seeAllUrl: { $bind: {
|
|
5328
|
+
from: "content.seeAllUrl",
|
|
5329
|
+
fallback: "",
|
|
5330
|
+
transforms: [{ id: "links.resolve" }]
|
|
5331
|
+
} },
|
|
5332
|
+
loadMoreText: { $bind: {
|
|
5333
|
+
from: "content.loadMoreText",
|
|
5334
|
+
fallback: "Load more events"
|
|
5335
|
+
} },
|
|
5336
|
+
startOfWeek: { $bind: { from: "content.startOfWeek" } },
|
|
5337
|
+
calendarTabViews: { $bind: {
|
|
5338
|
+
from: "content.calendarTabViews",
|
|
5339
|
+
fallback: "both"
|
|
5340
|
+
} },
|
|
5341
|
+
defaultCalendarView: { $bind: {
|
|
5342
|
+
from: "content.defaultCalendarView",
|
|
5343
|
+
fallback: "month"
|
|
5344
|
+
} },
|
|
5345
|
+
seriesIds: { $bind: {
|
|
5346
|
+
from: "content",
|
|
5347
|
+
transforms: [{
|
|
5348
|
+
id: "events.calendarSelectionParam",
|
|
5349
|
+
options: { key: "seriesIds" }
|
|
5350
|
+
}]
|
|
5351
|
+
} },
|
|
5352
|
+
showFilters: { $bind: {
|
|
5353
|
+
from: "content.showFilters",
|
|
5354
|
+
fallback: true
|
|
5355
|
+
} },
|
|
5356
|
+
showCategoryFilter: { $bind: {
|
|
5357
|
+
from: "content.showCategoryFilter",
|
|
5358
|
+
fallback: "auto"
|
|
5359
|
+
} },
|
|
5360
|
+
showVenueFilter: { $bind: {
|
|
5361
|
+
from: "content.showVenueFilter",
|
|
5362
|
+
fallback: false
|
|
5363
|
+
} },
|
|
5364
|
+
showStaffFilter: { $bind: {
|
|
5365
|
+
from: "content.showStaffFilter",
|
|
5366
|
+
fallback: true
|
|
5367
|
+
} },
|
|
5368
|
+
showVenue: { $bind: {
|
|
5369
|
+
from: "content.showVenue",
|
|
5370
|
+
fallback: true
|
|
5371
|
+
} },
|
|
5372
|
+
showMap: { $bind: {
|
|
5373
|
+
from: "content.showMap",
|
|
5374
|
+
fallback: true
|
|
5375
|
+
} },
|
|
5376
|
+
showCapacity: { $bind: {
|
|
5377
|
+
from: "content.showCapacity",
|
|
5378
|
+
fallback: true
|
|
5379
|
+
} },
|
|
5380
|
+
eventSurface: { $bind: {
|
|
5381
|
+
from: "content",
|
|
5382
|
+
transforms: [{
|
|
5383
|
+
id: "events.calendarSelectionParam",
|
|
5384
|
+
options: { key: "eventSurface" }
|
|
5385
|
+
}]
|
|
5386
|
+
} },
|
|
5387
|
+
filterEventPresets: { $bind: {
|
|
5388
|
+
from: "content",
|
|
5389
|
+
transforms: [{
|
|
5390
|
+
id: "events.calendarSelectionParam",
|
|
5391
|
+
options: { key: "filterEventPresets" }
|
|
5392
|
+
}]
|
|
5393
|
+
} },
|
|
5394
|
+
scheduleScope: { $bind: {
|
|
5395
|
+
from: "content",
|
|
5396
|
+
transforms: [{
|
|
5397
|
+
id: "events.calendarSelectionParam",
|
|
5398
|
+
options: { key: "scheduleScope" }
|
|
5399
|
+
}]
|
|
5400
|
+
} },
|
|
5401
|
+
filterCategoryIds: { $bind: {
|
|
5402
|
+
from: "content",
|
|
5403
|
+
transforms: [{
|
|
5404
|
+
id: "events.calendarSelectionParam",
|
|
5405
|
+
options: { key: "filterCategoryIds" }
|
|
5406
|
+
}]
|
|
5407
|
+
} },
|
|
5408
|
+
filterStaffMemberId: { $bind: {
|
|
5409
|
+
from: "content",
|
|
5410
|
+
transforms: [{
|
|
5411
|
+
id: "events.calendarSelectionParam",
|
|
5412
|
+
options: { key: "filterStaffMemberId" }
|
|
5413
|
+
}]
|
|
5414
|
+
} },
|
|
5415
|
+
filterVenueId: { $bind: {
|
|
5416
|
+
from: "content",
|
|
5417
|
+
transforms: [{
|
|
5418
|
+
id: "events.calendarSelectionParam",
|
|
5419
|
+
options: { key: "filterVenueId" }
|
|
5420
|
+
}]
|
|
5421
|
+
} },
|
|
5422
|
+
cardRole: { $bind: {
|
|
5423
|
+
from: "content._cardStyles.role",
|
|
5424
|
+
fallback: "default"
|
|
5425
|
+
} },
|
|
5426
|
+
buttonVariant: { $bind: {
|
|
5427
|
+
from: "content.buttonVariant",
|
|
5428
|
+
fallback: "primary"
|
|
5429
|
+
} },
|
|
5430
|
+
buttonText: { $bind: {
|
|
5431
|
+
from: "content.buttonText",
|
|
5432
|
+
fallback: "Book"
|
|
5433
|
+
} },
|
|
5434
|
+
emptyMessage: { $bind: { from: "content.emptyMessage" } },
|
|
5435
|
+
boardTitle: { $bind: { from: "content.boardTitle" } },
|
|
5436
|
+
footerNote: { $bind: { from: "content.footerNote" } },
|
|
5437
|
+
elevated: { $bind: {
|
|
5438
|
+
from: "content.elevated",
|
|
5439
|
+
fallback: false
|
|
5440
|
+
} },
|
|
5441
|
+
banded: { $bind: {
|
|
5442
|
+
from: "content",
|
|
5443
|
+
transforms: [{ id: "events.calendarBanded" }],
|
|
5444
|
+
fallback: false
|
|
5445
|
+
} }
|
|
5446
|
+
}))
|
|
5447
|
+
]
|
|
5288
5448
|
}),
|
|
5289
5449
|
baseClass: "",
|
|
5290
5450
|
spacing: "comfortable"
|
|
5291
5451
|
})];
|
|
5292
5452
|
const eventCalendarAdditionalFields = [
|
|
5293
5453
|
...cardListKnobFields,
|
|
5454
|
+
...cardListPhotoNumberFields.filter((field) => field.id === "showPhotos"),
|
|
5455
|
+
...eventDisplayFields.filter((field) => field.id === "showVenue"),
|
|
5456
|
+
{
|
|
5457
|
+
id: "eyebrow",
|
|
5458
|
+
type: "text",
|
|
5459
|
+
label: "Eyebrow",
|
|
5460
|
+
required: false,
|
|
5461
|
+
multiline: false,
|
|
5462
|
+
maxLength: 80
|
|
5463
|
+
},
|
|
5464
|
+
createButtonVariantField({
|
|
5465
|
+
id: "seeAllButtonVariant",
|
|
5466
|
+
label: "See all button style",
|
|
5467
|
+
defaultValue: "secondary"
|
|
5468
|
+
}),
|
|
5294
5469
|
...sectionHeaderFields("Event Calendar"),
|
|
5295
5470
|
{
|
|
5296
5471
|
id: "displayMode",
|
|
@@ -5303,7 +5478,7 @@ const eventCalendarAdditionalFields = [
|
|
|
5303
5478
|
options: [
|
|
5304
5479
|
{
|
|
5305
5480
|
value: "combined",
|
|
5306
|
-
label: "
|
|
5481
|
+
label: "List and calendar, with tabs"
|
|
5307
5482
|
},
|
|
5308
5483
|
{
|
|
5309
5484
|
value: "calendar",
|
|
@@ -5320,6 +5495,10 @@ const eventCalendarAdditionalFields = [
|
|
|
5320
5495
|
{
|
|
5321
5496
|
value: "list",
|
|
5322
5497
|
label: "List"
|
|
5498
|
+
},
|
|
5499
|
+
{
|
|
5500
|
+
value: "week",
|
|
5501
|
+
label: "Week"
|
|
5323
5502
|
}
|
|
5324
5503
|
],
|
|
5325
5504
|
ui: {
|
|
@@ -5336,7 +5515,7 @@ const eventCalendarAdditionalFields = [
|
|
|
5336
5515
|
defaultValue: "upcoming",
|
|
5337
5516
|
options: [{
|
|
5338
5517
|
value: "upcoming",
|
|
5339
|
-
label: "Upcoming
|
|
5518
|
+
label: "Upcoming events"
|
|
5340
5519
|
}, {
|
|
5341
5520
|
value: "week",
|
|
5342
5521
|
label: "Week"
|
|
@@ -5353,7 +5532,7 @@ const eventCalendarAdditionalFields = [
|
|
|
5353
5532
|
id: "listLayout",
|
|
5354
5533
|
type: "select",
|
|
5355
5534
|
label: "List layout",
|
|
5356
|
-
description: "
|
|
5535
|
+
description: "How the list is laid out.",
|
|
5357
5536
|
required: false,
|
|
5358
5537
|
multiple: false,
|
|
5359
5538
|
defaultValue: "stack",
|
|
@@ -5405,35 +5584,54 @@ const eventCalendarAdditionalFields = [
|
|
|
5405
5584
|
{
|
|
5406
5585
|
id: "eventsPerPage",
|
|
5407
5586
|
type: "select",
|
|
5408
|
-
label: "
|
|
5409
|
-
description: "Number of events to load initially",
|
|
5587
|
+
label: "How many",
|
|
5410
5588
|
required: false,
|
|
5411
5589
|
multiple: false,
|
|
5412
5590
|
defaultValue: "12",
|
|
5413
5591
|
options: [
|
|
5592
|
+
{
|
|
5593
|
+
value: "1",
|
|
5594
|
+
label: "Show just one"
|
|
5595
|
+
},
|
|
5596
|
+
{
|
|
5597
|
+
value: "2",
|
|
5598
|
+
label: "Show the first 2"
|
|
5599
|
+
},
|
|
5600
|
+
{
|
|
5601
|
+
value: "3",
|
|
5602
|
+
label: "Show the first 3"
|
|
5603
|
+
},
|
|
5604
|
+
{
|
|
5605
|
+
value: "4",
|
|
5606
|
+
label: "Show the first 4"
|
|
5607
|
+
},
|
|
5608
|
+
{
|
|
5609
|
+
value: "5",
|
|
5610
|
+
label: "Show the first 5"
|
|
5611
|
+
},
|
|
5414
5612
|
{
|
|
5415
5613
|
value: "6",
|
|
5416
|
-
label: "6"
|
|
5614
|
+
label: "Show the first 6"
|
|
5417
5615
|
},
|
|
5418
5616
|
{
|
|
5419
5617
|
value: "10",
|
|
5420
|
-
label: "10"
|
|
5618
|
+
label: "Show the first 10"
|
|
5421
5619
|
},
|
|
5422
5620
|
{
|
|
5423
5621
|
value: "12",
|
|
5424
|
-
label: "12"
|
|
5622
|
+
label: "Show the first 12"
|
|
5425
5623
|
},
|
|
5426
5624
|
{
|
|
5427
5625
|
value: "20",
|
|
5428
|
-
label: "20"
|
|
5626
|
+
label: "Show the first 20"
|
|
5429
5627
|
},
|
|
5430
5628
|
{
|
|
5431
5629
|
value: "24",
|
|
5432
|
-
label: "24"
|
|
5630
|
+
label: "Show the first 24"
|
|
5433
5631
|
},
|
|
5434
5632
|
{
|
|
5435
5633
|
value: "30",
|
|
5436
|
-
label: "30"
|
|
5634
|
+
label: "Show the first 30"
|
|
5437
5635
|
}
|
|
5438
5636
|
],
|
|
5439
5637
|
ui: {
|
|
@@ -5448,17 +5646,24 @@ const eventCalendarAdditionalFields = [
|
|
|
5448
5646
|
id: "paginationMode",
|
|
5449
5647
|
type: "select",
|
|
5450
5648
|
label: "More events",
|
|
5451
|
-
description: "How
|
|
5649
|
+
description: "How visitors can see the rest of your events.",
|
|
5452
5650
|
required: false,
|
|
5453
5651
|
multiple: false,
|
|
5454
5652
|
defaultValue: "loadMore",
|
|
5455
|
-
options: [
|
|
5456
|
-
|
|
5457
|
-
|
|
5458
|
-
|
|
5459
|
-
|
|
5460
|
-
|
|
5461
|
-
|
|
5653
|
+
options: [
|
|
5654
|
+
{
|
|
5655
|
+
value: "none",
|
|
5656
|
+
label: "No link or button"
|
|
5657
|
+
},
|
|
5658
|
+
{
|
|
5659
|
+
value: "loadMore",
|
|
5660
|
+
label: "Load more button"
|
|
5661
|
+
},
|
|
5662
|
+
{
|
|
5663
|
+
value: "seeAllLink",
|
|
5664
|
+
label: "Link to another page"
|
|
5665
|
+
}
|
|
5666
|
+
],
|
|
5462
5667
|
ui: {
|
|
5463
5668
|
intent: "display",
|
|
5464
5669
|
visibleWhen: {
|
|
@@ -5470,25 +5675,27 @@ const eventCalendarAdditionalFields = [
|
|
|
5470
5675
|
{
|
|
5471
5676
|
id: "seeAllUrl",
|
|
5472
5677
|
type: "link",
|
|
5473
|
-
label: "
|
|
5678
|
+
label: "Link to the full list",
|
|
5474
5679
|
required: false,
|
|
5475
5680
|
ui: {
|
|
5476
5681
|
intent: "display",
|
|
5477
|
-
visibleWhen: {
|
|
5682
|
+
visibleWhen: { anyOf: [{ allOf: [{
|
|
5478
5683
|
field: "variant",
|
|
5479
|
-
oneOf: [
|
|
5480
|
-
|
|
5481
|
-
|
|
5482
|
-
|
|
5483
|
-
|
|
5484
|
-
|
|
5684
|
+
oneOf: ["combined", "list"]
|
|
5685
|
+
}, {
|
|
5686
|
+
field: "paginationMode",
|
|
5687
|
+
equals: "seeAllLink"
|
|
5688
|
+
}] }, {
|
|
5689
|
+
field: "variant",
|
|
5690
|
+
oneOf: ["week-board", "week"]
|
|
5691
|
+
}] }
|
|
5485
5692
|
}
|
|
5486
5693
|
},
|
|
5487
5694
|
{
|
|
5488
5695
|
id: "loadMoreText",
|
|
5489
5696
|
type: "text",
|
|
5490
|
-
label: "
|
|
5491
|
-
description: "
|
|
5697
|
+
label: "More events button text",
|
|
5698
|
+
description: "The text on the button or link that shows more events.",
|
|
5492
5699
|
required: false,
|
|
5493
5700
|
multiline: false,
|
|
5494
5701
|
defaultValue: "Load more events",
|
|
@@ -5499,7 +5706,8 @@ const eventCalendarAdditionalFields = [
|
|
|
5499
5706
|
oneOf: [
|
|
5500
5707
|
"combined",
|
|
5501
5708
|
"list",
|
|
5502
|
-
"week-board"
|
|
5709
|
+
"week-board",
|
|
5710
|
+
"week"
|
|
5503
5711
|
]
|
|
5504
5712
|
}
|
|
5505
5713
|
}
|
|
@@ -5535,15 +5743,15 @@ const eventCalendarAdditionalFields = [
|
|
|
5535
5743
|
{
|
|
5536
5744
|
id: "calendarTabViews",
|
|
5537
5745
|
type: "select",
|
|
5538
|
-
label: "Calendar
|
|
5539
|
-
description: "Which
|
|
5746
|
+
label: "Calendar views",
|
|
5747
|
+
description: "Which views visitors can switch between in the calendar.",
|
|
5540
5748
|
required: false,
|
|
5541
5749
|
multiple: false,
|
|
5542
5750
|
defaultValue: "both",
|
|
5543
5751
|
options: [
|
|
5544
5752
|
{
|
|
5545
5753
|
value: "both",
|
|
5546
|
-
label: "Month
|
|
5754
|
+
label: "Month and week"
|
|
5547
5755
|
},
|
|
5548
5756
|
{
|
|
5549
5757
|
value: "month",
|
|
@@ -5566,7 +5774,7 @@ const eventCalendarAdditionalFields = [
|
|
|
5566
5774
|
id: "defaultCalendarView",
|
|
5567
5775
|
type: "select",
|
|
5568
5776
|
label: "Calendar view",
|
|
5569
|
-
description: "
|
|
5777
|
+
description: "Which view visitors see first.",
|
|
5570
5778
|
required: false,
|
|
5571
5779
|
multiple: false,
|
|
5572
5780
|
defaultValue: "month",
|
|
@@ -5595,7 +5803,7 @@ const eventCalendarAdditionalFields = [
|
|
|
5595
5803
|
id: "showFilters",
|
|
5596
5804
|
type: "boolean",
|
|
5597
5805
|
label: "Show filters",
|
|
5598
|
-
description: "
|
|
5806
|
+
description: "Lets visitors filter by category, team member or venue.",
|
|
5599
5807
|
required: false,
|
|
5600
5808
|
defaultValue: true,
|
|
5601
5809
|
ui: {
|
|
@@ -5616,14 +5824,14 @@ const eventCalendarAdditionalFields = [
|
|
|
5616
5824
|
id: "showCategoryFilter",
|
|
5617
5825
|
type: "select",
|
|
5618
5826
|
label: "Show category filter",
|
|
5619
|
-
description: "When to show the category
|
|
5827
|
+
description: "When to show the category menu.",
|
|
5620
5828
|
required: false,
|
|
5621
5829
|
multiple: false,
|
|
5622
5830
|
defaultValue: "auto",
|
|
5623
5831
|
options: [
|
|
5624
5832
|
{
|
|
5625
5833
|
value: "auto",
|
|
5626
|
-
label: "
|
|
5834
|
+
label: "When more than one category has events"
|
|
5627
5835
|
},
|
|
5628
5836
|
{
|
|
5629
5837
|
value: "always",
|
|
@@ -5655,7 +5863,7 @@ const eventCalendarAdditionalFields = [
|
|
|
5655
5863
|
id: "showVenueFilter",
|
|
5656
5864
|
type: "boolean",
|
|
5657
5865
|
label: "Show venue filter",
|
|
5658
|
-
description: "
|
|
5866
|
+
description: "Lets visitors pick a venue.",
|
|
5659
5867
|
required: false,
|
|
5660
5868
|
defaultValue: false,
|
|
5661
5869
|
ui: {
|
|
@@ -5678,8 +5886,8 @@ const eventCalendarAdditionalFields = [
|
|
|
5678
5886
|
{
|
|
5679
5887
|
id: "showStaffFilter",
|
|
5680
5888
|
type: "boolean",
|
|
5681
|
-
label: "Show
|
|
5682
|
-
description: "
|
|
5889
|
+
label: "Show team filter",
|
|
5890
|
+
description: "Lets visitors pick someone from your team.",
|
|
5683
5891
|
required: false,
|
|
5684
5892
|
defaultValue: true,
|
|
5685
5893
|
ui: {
|
|
@@ -5703,7 +5911,7 @@ const eventCalendarAdditionalFields = [
|
|
|
5703
5911
|
id: "showCapacity",
|
|
5704
5912
|
type: "boolean",
|
|
5705
5913
|
label: "Show available places",
|
|
5706
|
-
description: "
|
|
5914
|
+
description: "Shows how many places are left on each event.",
|
|
5707
5915
|
required: false,
|
|
5708
5916
|
defaultValue: true,
|
|
5709
5917
|
ui: {
|
|
@@ -5729,7 +5937,7 @@ const eventCalendarAdditionalFields = [
|
|
|
5729
5937
|
id: "boardTitle",
|
|
5730
5938
|
type: "text",
|
|
5731
5939
|
label: "Board title",
|
|
5732
|
-
description: "
|
|
5940
|
+
description: "An optional label along the top of the board.",
|
|
5733
5941
|
required: false,
|
|
5734
5942
|
multiline: false,
|
|
5735
5943
|
ui: {
|
|
@@ -5744,7 +5952,7 @@ const eventCalendarAdditionalFields = [
|
|
|
5744
5952
|
id: "footerNote",
|
|
5745
5953
|
type: "text",
|
|
5746
5954
|
label: "Footer note",
|
|
5747
|
-
description: "
|
|
5955
|
+
description: "An optional note along the bottom of the board.",
|
|
5748
5956
|
required: false,
|
|
5749
5957
|
multiline: true,
|
|
5750
5958
|
ui: {
|
|
@@ -5774,7 +5982,7 @@ const eventCalendarAdditionalFields = [
|
|
|
5774
5982
|
id: "banded",
|
|
5775
5983
|
type: "boolean",
|
|
5776
5984
|
label: "Section band",
|
|
5777
|
-
description: "
|
|
5985
|
+
description: "Puts the board on its own band of colour.",
|
|
5778
5986
|
required: false,
|
|
5779
5987
|
defaultValue: false,
|
|
5780
5988
|
ui: {
|
|
@@ -5817,8 +6025,8 @@ const eventCalendarAdditionalFields = [
|
|
|
5817
6025
|
{
|
|
5818
6026
|
id: "filterEventPresets",
|
|
5819
6027
|
type: "select",
|
|
5820
|
-
label: "
|
|
5821
|
-
description: "
|
|
6028
|
+
label: "Only show these event types",
|
|
6029
|
+
description: "Pick the types of event this block shows.",
|
|
5822
6030
|
required: false,
|
|
5823
6031
|
multiple: true,
|
|
5824
6032
|
defaultValue: [],
|
|
@@ -5855,23 +6063,23 @@ const eventCalendarAdditionalFields = [
|
|
|
5855
6063
|
{
|
|
5856
6064
|
id: "scheduleScope",
|
|
5857
6065
|
type: "select",
|
|
5858
|
-
label: "
|
|
5859
|
-
description: "
|
|
6066
|
+
label: "Regular or one-off",
|
|
6067
|
+
description: "Show regular events, one-off events or both.",
|
|
5860
6068
|
required: false,
|
|
5861
6069
|
multiple: false,
|
|
5862
6070
|
defaultValue: "any",
|
|
5863
6071
|
options: [
|
|
5864
6072
|
{
|
|
5865
6073
|
value: "any",
|
|
5866
|
-
label: "
|
|
6074
|
+
label: "Both"
|
|
5867
6075
|
},
|
|
5868
6076
|
{
|
|
5869
6077
|
value: "recurring",
|
|
5870
|
-
label: "
|
|
6078
|
+
label: "Regular events only"
|
|
5871
6079
|
},
|
|
5872
6080
|
{
|
|
5873
6081
|
value: "oneOff",
|
|
5874
|
-
label: "One-off only"
|
|
6082
|
+
label: "One-off events only"
|
|
5875
6083
|
}
|
|
5876
6084
|
],
|
|
5877
6085
|
ui: {
|
|
@@ -5884,8 +6092,8 @@ const eventCalendarAdditionalFields = [
|
|
|
5884
6092
|
},
|
|
5885
6093
|
createSiteOptionSelectField({
|
|
5886
6094
|
id: "filterCategoryIds",
|
|
5887
|
-
label: "
|
|
5888
|
-
description: "
|
|
6095
|
+
label: "Only show these categories",
|
|
6096
|
+
description: "Pick the categories this block shows.",
|
|
5889
6097
|
required: false,
|
|
5890
6098
|
multiple: true,
|
|
5891
6099
|
defaultValue: [],
|
|
@@ -5897,8 +6105,8 @@ const eventCalendarAdditionalFields = [
|
|
|
5897
6105
|
}),
|
|
5898
6106
|
createSiteOptionSelectField({
|
|
5899
6107
|
id: "filterStaffMemberId",
|
|
5900
|
-
label: "
|
|
5901
|
-
description: "
|
|
6108
|
+
label: "Only show one team member",
|
|
6109
|
+
description: "Pick someone from your team to show only their events.",
|
|
5902
6110
|
required: false,
|
|
5903
6111
|
multiple: false,
|
|
5904
6112
|
optionSource: "staffMembers",
|
|
@@ -5909,8 +6117,8 @@ const eventCalendarAdditionalFields = [
|
|
|
5909
6117
|
}),
|
|
5910
6118
|
createSiteOptionSelectField({
|
|
5911
6119
|
id: "filterVenueId",
|
|
5912
|
-
label: "
|
|
5913
|
-
description: "
|
|
6120
|
+
label: "Only show one venue",
|
|
6121
|
+
description: "Pick a venue to show only the events held there.",
|
|
5914
6122
|
required: false,
|
|
5915
6123
|
multiple: false,
|
|
5916
6124
|
optionSource: "venues",
|
|
@@ -5948,6 +6156,7 @@ const eventCalendarAdditionalFields = [
|
|
|
5948
6156
|
})
|
|
5949
6157
|
];
|
|
5950
6158
|
const eventCalendarVariants = {
|
|
6159
|
+
week: eventCalendarLayout[0],
|
|
5951
6160
|
combined: eventCalendarLayout[0],
|
|
5952
6161
|
calendar: eventCalendarLayout[0],
|
|
5953
6162
|
timetable: eventCalendarLayout[0],
|
|
@@ -5966,7 +6175,8 @@ const eventCalendarContentShape = {
|
|
|
5966
6175
|
{ value: "calendar" },
|
|
5967
6176
|
{ value: "timetable" },
|
|
5968
6177
|
{ value: "week-board" },
|
|
5969
|
-
{ value: "list" }
|
|
6178
|
+
{ value: "list" },
|
|
6179
|
+
{ value: "week" }
|
|
5970
6180
|
]
|
|
5971
6181
|
},
|
|
5972
6182
|
{
|
|
@@ -5987,57 +6197,119 @@ const eventCalendarContentShape = {
|
|
|
5987
6197
|
variants: eventCalendarVariants,
|
|
5988
6198
|
skipSectionStyles: true
|
|
5989
6199
|
};
|
|
5990
|
-
|
|
5991
|
-
|
|
5992
|
-
|
|
5993
|
-
|
|
5994
|
-
|
|
5995
|
-
|
|
5996
|
-
|
|
5997
|
-
|
|
5998
|
-
|
|
5999
|
-
|
|
6000
|
-
|
|
6001
|
-
|
|
6002
|
-
|
|
6003
|
-
|
|
6004
|
-
|
|
6005
|
-
|
|
6006
|
-
|
|
6007
|
-
|
|
6008
|
-
|
|
6009
|
-
|
|
6010
|
-
|
|
6011
|
-
|
|
6012
|
-
|
|
6013
|
-
|
|
6014
|
-
|
|
6015
|
-
|
|
6016
|
-
|
|
6017
|
-
|
|
6018
|
-
|
|
6019
|
-
|
|
6020
|
-
|
|
6021
|
-
|
|
6022
|
-
|
|
6023
|
-
|
|
6024
|
-
|
|
6025
|
-
|
|
6026
|
-
|
|
6027
|
-
|
|
6028
|
-
|
|
6029
|
-
|
|
6030
|
-
|
|
6031
|
-
|
|
6032
|
-
|
|
6033
|
-
|
|
6034
|
-
|
|
6035
|
-
calendar: { label: "Calendar" },
|
|
6036
|
-
timetable: { label: "Timetable" },
|
|
6037
|
-
"week-board": { label: "Week board" },
|
|
6038
|
-
list: { label: "List" }
|
|
6200
|
+
/** Week rows use their fixed recurring-series read, without occurrence filters. */
|
|
6201
|
+
function withCalendarModeVisibility(field) {
|
|
6202
|
+
const selected = withEventSelectionVisibility(field);
|
|
6203
|
+
if (field.id === "showVenue") return {
|
|
6204
|
+
...selected,
|
|
6205
|
+
ui: {
|
|
6206
|
+
...selected.ui,
|
|
6207
|
+
visibleWhen: {
|
|
6208
|
+
field: "variant",
|
|
6209
|
+
oneOf: [
|
|
6210
|
+
"week",
|
|
6211
|
+
"list",
|
|
6212
|
+
"combined"
|
|
6213
|
+
]
|
|
6214
|
+
}
|
|
6215
|
+
}
|
|
6216
|
+
};
|
|
6217
|
+
if (field.id === "seeAllButtonVariant") return {
|
|
6218
|
+
...selected,
|
|
6219
|
+
ui: {
|
|
6220
|
+
...selected.ui,
|
|
6221
|
+
visibleWhen: {
|
|
6222
|
+
field: "variant",
|
|
6223
|
+
equals: "week"
|
|
6224
|
+
}
|
|
6225
|
+
}
|
|
6226
|
+
};
|
|
6227
|
+
if (![
|
|
6228
|
+
"eventSelection",
|
|
6229
|
+
"selectedEventSeriesIds",
|
|
6230
|
+
"eventSurface",
|
|
6231
|
+
"filterEventPresets",
|
|
6232
|
+
"scheduleScope",
|
|
6233
|
+
"filterCategoryIds",
|
|
6234
|
+
"filterStaffMemberId",
|
|
6235
|
+
"filterVenueId"
|
|
6236
|
+
].includes(field.id)) return selected;
|
|
6237
|
+
return {
|
|
6238
|
+
...selected,
|
|
6239
|
+
ui: {
|
|
6240
|
+
...selected.ui,
|
|
6241
|
+
visibleWhen: { allOf: [{
|
|
6242
|
+
field: "variant",
|
|
6243
|
+
notEquals: "week"
|
|
6244
|
+
}, ...selected.ui?.visibleWhen ? [selected.ui.visibleWhen] : []] }
|
|
6039
6245
|
}
|
|
6040
|
-
}
|
|
6246
|
+
};
|
|
6247
|
+
}
|
|
6248
|
+
const generatedEventCalendarManifest = createBlockManifestWithContentShape({
|
|
6249
|
+
id: "block.event-calendar",
|
|
6250
|
+
promotedFields: [
|
|
6251
|
+
"variant",
|
|
6252
|
+
"listBy",
|
|
6253
|
+
"eventSurface",
|
|
6254
|
+
"filterEventPresets",
|
|
6255
|
+
"scheduleScope",
|
|
6256
|
+
"eventsPerPage",
|
|
6257
|
+
"paginationMode",
|
|
6258
|
+
"seeAllUrl"
|
|
6259
|
+
],
|
|
6260
|
+
version: "3.6.0",
|
|
6261
|
+
title: "Event calendar",
|
|
6262
|
+
titleSource: "heading",
|
|
6263
|
+
description: "Your classes and events, as a list, a calendar or a weekly timetable.",
|
|
6264
|
+
skipSectionStyles: true,
|
|
6265
|
+
additionalFields: eventCalendarAdditionalFields.map(withCalendarModeVisibility),
|
|
6266
|
+
styleTokens: {
|
|
6267
|
+
background: "surface",
|
|
6268
|
+
typography: "body",
|
|
6269
|
+
spacing: "md"
|
|
6270
|
+
},
|
|
6271
|
+
behaviours: {
|
|
6272
|
+
supportsThemeSwitching: true,
|
|
6273
|
+
inlineEditing: false,
|
|
6274
|
+
animation: false,
|
|
6275
|
+
paletteHidden: false
|
|
6276
|
+
},
|
|
6277
|
+
category: "events-and-bookings",
|
|
6278
|
+
requiredFeatures: ["bookings.events"],
|
|
6279
|
+
contentSource: { kind: "entries" },
|
|
6280
|
+
tags: [
|
|
6281
|
+
"events",
|
|
6282
|
+
"calendar",
|
|
6283
|
+
"month",
|
|
6284
|
+
"week",
|
|
6285
|
+
"schedule",
|
|
6286
|
+
"interactive",
|
|
6287
|
+
"list",
|
|
6288
|
+
"filter"
|
|
6289
|
+
],
|
|
6290
|
+
icon: "CalendarDays",
|
|
6291
|
+
layout: eventCalendarLayout,
|
|
6292
|
+
variants: eventCalendarVariants,
|
|
6293
|
+
variantMeaning: eventCalendarVariantMeaning,
|
|
6294
|
+
defaultVariant: "combined",
|
|
6295
|
+
variantOptions: {
|
|
6296
|
+
week: { label: "Week" },
|
|
6297
|
+
combined: { label: "Combined" },
|
|
6298
|
+
calendar: { label: "Calendar" },
|
|
6299
|
+
timetable: { label: "Timetable" },
|
|
6300
|
+
"week-board": { label: "Week board" },
|
|
6301
|
+
list: { label: "List" }
|
|
6302
|
+
}
|
|
6303
|
+
}, eventCalendarContentShape);
|
|
6304
|
+
const eventCalendarBlockDefinition = {
|
|
6305
|
+
manifest: {
|
|
6306
|
+
...generatedEventCalendarManifest,
|
|
6307
|
+
fields: generatedEventCalendarManifest.fields?.map((field) => field.id === "variant" ? {
|
|
6308
|
+
...field,
|
|
6309
|
+
label: "Show events as",
|
|
6310
|
+
description: void 0
|
|
6311
|
+
} : field)
|
|
6312
|
+
},
|
|
6041
6313
|
contentNormalizer: {
|
|
6042
6314
|
fieldIds: [
|
|
6043
6315
|
"variant",
|
|
@@ -6054,6 +6326,7 @@ const eventCalendarBlockDefinition = {
|
|
|
6054
6326
|
normalize: normalizeEventCalendarContent
|
|
6055
6327
|
},
|
|
6056
6328
|
dataSchemas: {
|
|
6329
|
+
schedule: recurringScheduleProjectionSchema.optional(),
|
|
6057
6330
|
events: publicEventsArraySchema.optional(),
|
|
6058
6331
|
calendarWindow: calendarWindowPageSchema.optional()
|
|
6059
6332
|
},
|
|
@@ -6112,10 +6385,11 @@ const shopBlockDefinition = {
|
|
|
6112
6385
|
]
|
|
6113
6386
|
},
|
|
6114
6387
|
id: "block.shop",
|
|
6388
|
+
promotedFields: ["showPasses", "showMemberships"],
|
|
6115
6389
|
version: "1.0.0",
|
|
6116
|
-
title: "Passes &
|
|
6390
|
+
title: "Passes & memberships",
|
|
6117
6391
|
titleSource: "passesHeading",
|
|
6118
|
-
description: "
|
|
6392
|
+
description: "Your class passes and memberships, ready for people to buy.",
|
|
6119
6393
|
skipSectionStyles: true,
|
|
6120
6394
|
additionalFields: [
|
|
6121
6395
|
...cardListKnobFields,
|
|
@@ -6136,7 +6410,7 @@ const shopBlockDefinition = {
|
|
|
6136
6410
|
id: "showPasses",
|
|
6137
6411
|
type: "boolean",
|
|
6138
6412
|
label: "Show passes",
|
|
6139
|
-
description: "
|
|
6413
|
+
description: "Lets visitors buy your class passes.",
|
|
6140
6414
|
required: false,
|
|
6141
6415
|
defaultValue: true,
|
|
6142
6416
|
ui: { intent: "display" }
|
|
@@ -6145,7 +6419,7 @@ const shopBlockDefinition = {
|
|
|
6145
6419
|
id: "showMemberships",
|
|
6146
6420
|
type: "boolean",
|
|
6147
6421
|
label: "Show memberships",
|
|
6148
|
-
description: "
|
|
6422
|
+
description: "Lets visitors buy your memberships.",
|
|
6149
6423
|
required: false,
|
|
6150
6424
|
defaultValue: true,
|
|
6151
6425
|
ui: { intent: "display" }
|
|
@@ -6154,7 +6428,7 @@ const shopBlockDefinition = {
|
|
|
6154
6428
|
id: "layout",
|
|
6155
6429
|
type: "select",
|
|
6156
6430
|
label: "Layout",
|
|
6157
|
-
description: "How
|
|
6431
|
+
description: "How the passes and memberships are laid out.",
|
|
6158
6432
|
required: false,
|
|
6159
6433
|
multiple: false,
|
|
6160
6434
|
defaultValue: "grid",
|
|
@@ -6206,7 +6480,7 @@ const shopBlockDefinition = {
|
|
|
6206
6480
|
id: "showDescriptions",
|
|
6207
6481
|
type: "boolean",
|
|
6208
6482
|
label: "Show descriptions",
|
|
6209
|
-
description: "
|
|
6483
|
+
description: "Shows the description under each one.",
|
|
6210
6484
|
required: false,
|
|
6211
6485
|
defaultValue: true,
|
|
6212
6486
|
ui: { intent: "display" }
|
|
@@ -6215,7 +6489,7 @@ const shopBlockDefinition = {
|
|
|
6215
6489
|
id: "showValidityPeriod",
|
|
6216
6490
|
type: "boolean",
|
|
6217
6491
|
label: "Show validity period",
|
|
6218
|
-
description: "
|
|
6492
|
+
description: "Shows how long each pass lasts, like 'Valid for 30 days'.",
|
|
6219
6493
|
required: false,
|
|
6220
6494
|
defaultValue: true,
|
|
6221
6495
|
ui: { intent: "display" }
|
|
@@ -6224,21 +6498,21 @@ const shopBlockDefinition = {
|
|
|
6224
6498
|
id: "showPricePerCredit",
|
|
6225
6499
|
type: "boolean",
|
|
6226
6500
|
label: "Show price per credit",
|
|
6227
|
-
description: "
|
|
6501
|
+
description: "Shows what each credit works out at, for passes and packs.",
|
|
6228
6502
|
required: false,
|
|
6229
6503
|
defaultValue: true,
|
|
6230
6504
|
ui: { intent: "display" }
|
|
6231
6505
|
},
|
|
6232
6506
|
createButtonVariantField({
|
|
6233
|
-
label: "
|
|
6234
|
-
description: "
|
|
6507
|
+
label: "Button style",
|
|
6508
|
+
description: "The style of the buy buttons.",
|
|
6235
6509
|
defaultValue: "primary"
|
|
6236
6510
|
}),
|
|
6237
6511
|
{
|
|
6238
6512
|
id: "passesHeading",
|
|
6239
6513
|
type: "text",
|
|
6240
|
-
label: "
|
|
6241
|
-
description: "
|
|
6514
|
+
label: "Passes heading",
|
|
6515
|
+
description: "An optional heading above your passes.",
|
|
6242
6516
|
required: false,
|
|
6243
6517
|
multiline: false,
|
|
6244
6518
|
defaultValue: "",
|
|
@@ -6258,7 +6532,7 @@ const shopBlockDefinition = {
|
|
|
6258
6532
|
id: "buyButtonText",
|
|
6259
6533
|
type: "text",
|
|
6260
6534
|
label: "Pass button text",
|
|
6261
|
-
description: "
|
|
6535
|
+
description: "The text on the button to buy a pass.",
|
|
6262
6536
|
required: false,
|
|
6263
6537
|
multiline: false,
|
|
6264
6538
|
defaultValue: "Add to cart",
|
|
@@ -6267,8 +6541,8 @@ const shopBlockDefinition = {
|
|
|
6267
6541
|
{
|
|
6268
6542
|
id: "passPurchaseMode",
|
|
6269
6543
|
type: "select",
|
|
6270
|
-
label: "
|
|
6271
|
-
description: "
|
|
6544
|
+
label: "When someone buys a pass",
|
|
6545
|
+
description: "Add the pass to their cart, or take them straight to checkout.",
|
|
6272
6546
|
required: false,
|
|
6273
6547
|
multiple: false,
|
|
6274
6548
|
defaultValue: "add_to_cart",
|
|
@@ -6294,8 +6568,8 @@ const shopBlockDefinition = {
|
|
|
6294
6568
|
{
|
|
6295
6569
|
id: "emptyStateText",
|
|
6296
6570
|
type: "text",
|
|
6297
|
-
label: "
|
|
6298
|
-
description: "
|
|
6571
|
+
label: "If there's nothing to show",
|
|
6572
|
+
description: "What visitors see when there's nothing for sale.",
|
|
6299
6573
|
required: false,
|
|
6300
6574
|
multiline: false,
|
|
6301
6575
|
defaultValue: "No products available at this time.",
|
|
@@ -6430,9 +6704,9 @@ const productListBlockDefinition = {
|
|
|
6430
6704
|
variantMeaning: { kind: "arrangement" },
|
|
6431
6705
|
id: "block.product-list",
|
|
6432
6706
|
version: "1.0.0",
|
|
6433
|
-
title: "Product
|
|
6707
|
+
title: "Product list",
|
|
6434
6708
|
titleSource: "heading",
|
|
6435
|
-
description: "
|
|
6709
|
+
description: "Your products, each with a button to add it to the cart.",
|
|
6436
6710
|
skipSectionStyles: true,
|
|
6437
6711
|
additionalFields: [
|
|
6438
6712
|
{
|
|
@@ -6513,7 +6787,7 @@ const productListBlockDefinition = {
|
|
|
6513
6787
|
{
|
|
6514
6788
|
id: "emptyStateText",
|
|
6515
6789
|
type: "text",
|
|
6516
|
-
label: "
|
|
6790
|
+
label: "If there's nothing to show",
|
|
6517
6791
|
multiline: false,
|
|
6518
6792
|
required: false,
|
|
6519
6793
|
defaultValue: "No products available right now."
|
|
@@ -6534,7 +6808,8 @@ const productListBlockDefinition = {
|
|
|
6534
6808
|
animation: false,
|
|
6535
6809
|
paletteHidden: false
|
|
6536
6810
|
},
|
|
6537
|
-
category: "
|
|
6811
|
+
category: "shop",
|
|
6812
|
+
requiredFeatures: ["shop"],
|
|
6538
6813
|
contentSource: { kind: "entries" },
|
|
6539
6814
|
tags: [
|
|
6540
6815
|
"shop",
|
|
@@ -6607,10 +6882,11 @@ const productDetailBlockDefinition = {
|
|
|
6607
6882
|
manifest: createBlockManifest({
|
|
6608
6883
|
variantMeaning: { kind: "arrangement" },
|
|
6609
6884
|
id: "block.product-detail",
|
|
6885
|
+
promotedFields: ["productSlug"],
|
|
6610
6886
|
version: "1.0.0",
|
|
6611
|
-
title: "Product
|
|
6887
|
+
title: "Product detail",
|
|
6612
6888
|
titleSource: "heading",
|
|
6613
|
-
description: "
|
|
6889
|
+
description: "One product with its photos and an add-to-cart button.",
|
|
6614
6890
|
skipSectionStyles: true,
|
|
6615
6891
|
additionalFields: [
|
|
6616
6892
|
{
|
|
@@ -6626,7 +6902,7 @@ const productDetailBlockDefinition = {
|
|
|
6626
6902
|
type: "text",
|
|
6627
6903
|
label: "Product slug",
|
|
6628
6904
|
multiline: false,
|
|
6629
|
-
description: "
|
|
6905
|
+
description: "Only needed if this block isn't on a product page. Use the last part of the product's web address.",
|
|
6630
6906
|
required: false,
|
|
6631
6907
|
ui: { intent: "behavior" }
|
|
6632
6908
|
},
|
|
@@ -6641,7 +6917,7 @@ const productDetailBlockDefinition = {
|
|
|
6641
6917
|
{
|
|
6642
6918
|
id: "showBody",
|
|
6643
6919
|
type: "boolean",
|
|
6644
|
-
label: "Show
|
|
6920
|
+
label: "Show full description",
|
|
6645
6921
|
required: false,
|
|
6646
6922
|
defaultValue: true,
|
|
6647
6923
|
ui: { intent: "display" }
|
|
@@ -6657,7 +6933,7 @@ const productDetailBlockDefinition = {
|
|
|
6657
6933
|
{
|
|
6658
6934
|
id: "emptyStateText",
|
|
6659
6935
|
type: "text",
|
|
6660
|
-
label: "
|
|
6936
|
+
label: "If there's nothing to show",
|
|
6661
6937
|
multiline: false,
|
|
6662
6938
|
required: false,
|
|
6663
6939
|
defaultValue: "Product unavailable."
|
|
@@ -6678,7 +6954,8 @@ const productDetailBlockDefinition = {
|
|
|
6678
6954
|
animation: false,
|
|
6679
6955
|
paletteHidden: false
|
|
6680
6956
|
},
|
|
6681
|
-
category: "
|
|
6957
|
+
category: "shop",
|
|
6958
|
+
requiredFeatures: ["shop"],
|
|
6682
6959
|
contentSource: { kind: "entries" },
|
|
6683
6960
|
tags: [
|
|
6684
6961
|
"shop",
|
|
@@ -6717,6 +6994,10 @@ const productDetailBlockDefinition = {
|
|
|
6717
6994
|
from: "content.emptyStateText",
|
|
6718
6995
|
fallback: "Product unavailable."
|
|
6719
6996
|
} },
|
|
6997
|
+
template: { $bind: {
|
|
6998
|
+
from: "$root.template",
|
|
6999
|
+
fallback: { kind: "page" }
|
|
7000
|
+
} },
|
|
6720
7001
|
contentEntry: { $bind: {
|
|
6721
7002
|
from: "$root.contentEntry",
|
|
6722
7003
|
fallback: null
|
|
@@ -6725,6 +7006,7 @@ const productDetailBlockDefinition = {
|
|
|
6725
7006
|
}))], { gap: "lg" })
|
|
6726
7007
|
})]
|
|
6727
7008
|
}),
|
|
7009
|
+
readiness: productReadiness,
|
|
6728
7010
|
runtime: productDetailBlockRuntime,
|
|
6729
7011
|
dataSchemas: { products: publicProductsResponseSchema.optional() },
|
|
6730
7012
|
dataLoaders: { products: {
|
|
@@ -6746,7 +7028,7 @@ const cartBlockDefinition = {
|
|
|
6746
7028
|
version: "1.0.0",
|
|
6747
7029
|
title: "Cart",
|
|
6748
7030
|
titleSource: "heading",
|
|
6749
|
-
description: "
|
|
7031
|
+
description: "Shows what a visitor has in their cart.",
|
|
6750
7032
|
skipSectionStyles: true,
|
|
6751
7033
|
additionalFields: [
|
|
6752
7034
|
{
|
|
@@ -6760,7 +7042,7 @@ const cartBlockDefinition = {
|
|
|
6760
7042
|
{
|
|
6761
7043
|
id: "emptyStateText",
|
|
6762
7044
|
type: "text",
|
|
6763
|
-
label: "
|
|
7045
|
+
label: "If there's nothing to show",
|
|
6764
7046
|
multiline: false,
|
|
6765
7047
|
required: false,
|
|
6766
7048
|
defaultValue: "Your cart is empty."
|
|
@@ -6797,7 +7079,8 @@ const cartBlockDefinition = {
|
|
|
6797
7079
|
animation: false,
|
|
6798
7080
|
paletteHidden: false
|
|
6799
7081
|
},
|
|
6800
|
-
category: "
|
|
7082
|
+
category: "shop",
|
|
7083
|
+
requiredFeatures: ["shop"],
|
|
6801
7084
|
contentSource: { kind: "inline" },
|
|
6802
7085
|
tags: [
|
|
6803
7086
|
"shop",
|
|
@@ -6839,7 +7122,7 @@ const checkoutBlockDefinition = {
|
|
|
6839
7122
|
version: "1.0.0",
|
|
6840
7123
|
title: "Checkout",
|
|
6841
7124
|
titleSource: "heading",
|
|
6842
|
-
description: "
|
|
7125
|
+
description: "Where visitors enter their details and pay for what's in their cart.",
|
|
6843
7126
|
skipSectionStyles: true,
|
|
6844
7127
|
additionalFields: [
|
|
6845
7128
|
{
|
|
@@ -6861,7 +7144,7 @@ const checkoutBlockDefinition = {
|
|
|
6861
7144
|
{
|
|
6862
7145
|
id: "emptyStateText",
|
|
6863
7146
|
type: "text",
|
|
6864
|
-
label: "
|
|
7147
|
+
label: "If there's nothing to show",
|
|
6865
7148
|
multiline: false,
|
|
6866
7149
|
required: false,
|
|
6867
7150
|
defaultValue: "Add something to your cart to continue."
|
|
@@ -6882,7 +7165,8 @@ const checkoutBlockDefinition = {
|
|
|
6882
7165
|
animation: false,
|
|
6883
7166
|
paletteHidden: false
|
|
6884
7167
|
},
|
|
6885
|
-
category: "
|
|
7168
|
+
category: "shop",
|
|
7169
|
+
requiredFeatures: ["shop"],
|
|
6886
7170
|
contentSource: { kind: "inline" },
|
|
6887
7171
|
tags: [
|
|
6888
7172
|
"shop",
|
|
@@ -6924,7 +7208,7 @@ const giftingBlockDefinition = {
|
|
|
6924
7208
|
version: "1.0.0",
|
|
6925
7209
|
title: "Gift cards & vouchers",
|
|
6926
7210
|
titleSource: "heading",
|
|
6927
|
-
description: "
|
|
7211
|
+
description: "Lets people buy gift cards and vouchers for someone else.",
|
|
6928
7212
|
skipSectionStyles: true,
|
|
6929
7213
|
additionalFields: [
|
|
6930
7214
|
{
|
|
@@ -6962,7 +7246,7 @@ const giftingBlockDefinition = {
|
|
|
6962
7246
|
{
|
|
6963
7247
|
id: "emptyStateText",
|
|
6964
7248
|
type: "text",
|
|
6965
|
-
label: "
|
|
7249
|
+
label: "If there's nothing to show",
|
|
6966
7250
|
required: false,
|
|
6967
7251
|
multiline: false,
|
|
6968
7252
|
defaultValue: "Nothing is available right now."
|
|
@@ -6999,7 +7283,7 @@ const giftingBlockDefinition = {
|
|
|
6999
7283
|
animation: false,
|
|
7000
7284
|
paletteHidden: false
|
|
7001
7285
|
},
|
|
7002
|
-
category: "
|
|
7286
|
+
category: "shop",
|
|
7003
7287
|
contentSource: { kind: "entries" },
|
|
7004
7288
|
tags: [
|
|
7005
7289
|
"gifting",
|
|
@@ -7105,10 +7389,16 @@ const archLayout = styledSection({
|
|
|
7105
7389
|
});
|
|
7106
7390
|
const newsletterSignupManifest = createBlockManifest({
|
|
7107
7391
|
id: "block.newsletter-signup",
|
|
7108
|
-
|
|
7392
|
+
sourceLine: {
|
|
7393
|
+
text: "",
|
|
7394
|
+
target: "mailing-lists"
|
|
7395
|
+
},
|
|
7396
|
+
promotedFields: ["targeting"],
|
|
7397
|
+
title: "Newsletter signup",
|
|
7109
7398
|
titleSource: "title",
|
|
7110
|
-
description: "
|
|
7111
|
-
category: "
|
|
7399
|
+
description: "Lets people join one of your mailing lists.",
|
|
7400
|
+
category: "forms-and-sign-ups",
|
|
7401
|
+
requiredFeatures: ["newsletter"],
|
|
7112
7402
|
contentSource: { kind: "inline" },
|
|
7113
7403
|
fragments: [{
|
|
7114
7404
|
fragment: newsletterCopyFragment,
|
|
@@ -7183,6 +7473,7 @@ function sanitizeNewsletterSignupPublicContent(content) {
|
|
|
7183
7473
|
}
|
|
7184
7474
|
const newsletterSignupBlockDefinition = {
|
|
7185
7475
|
manifest: newsletterSignupManifest,
|
|
7476
|
+
readiness: newsletterReadiness,
|
|
7186
7477
|
contentNormalizer: {
|
|
7187
7478
|
fieldIds: ["targeting"],
|
|
7188
7479
|
normalize: normalizeMailingListBlockContent
|
|
@@ -7263,222 +7554,6 @@ const OrderedListNode = (props) => /* @__PURE__ */ jsx("ol", { ...props });
|
|
|
7263
7554
|
const ListItemNode = (props) => /* @__PURE__ */ jsx("li", { ...props });
|
|
7264
7555
|
const FigcaptionNode = (props) => /* @__PURE__ */ jsx("figcaption", { ...props });
|
|
7265
7556
|
//#endregion
|
|
7266
|
-
//#region ../path-utils/src/index.ts
|
|
7267
|
-
const PATH_SEPARATOR_REGEX = /\./g;
|
|
7268
|
-
const BRACKET_ACCESS_REGEX = /\[([^\]]+)\]/g;
|
|
7269
|
-
/**
|
|
7270
|
-
* Segments that would traverse or mutate the prototype chain.
|
|
7271
|
-
*
|
|
7272
|
-
* `setAtPath` creates nested objects along the path, so allowing these
|
|
7273
|
-
* segments is a prototype-pollution vector. They are rejected everywhere a
|
|
7274
|
-
* path is parsed (string or pre-parsed array form) — fail closed.
|
|
7275
|
-
*/
|
|
7276
|
-
const UNSAFE_PATH_SEGMENTS = /* @__PURE__ */ new Set([
|
|
7277
|
-
"__proto__",
|
|
7278
|
-
"constructor",
|
|
7279
|
-
"prototype"
|
|
7280
|
-
]);
|
|
7281
|
-
var UnsafePathSegmentError = class extends Error {
|
|
7282
|
-
constructor(segment) {
|
|
7283
|
-
super(`Unsafe path segment: "${segment}"`);
|
|
7284
|
-
this.name = "UnsafePathSegmentError";
|
|
7285
|
-
this.segment = segment;
|
|
7286
|
-
}
|
|
7287
|
-
};
|
|
7288
|
-
function assertSafePathSegments(segments) {
|
|
7289
|
-
for (const segment of segments) if (typeof segment === "string" && UNSAFE_PATH_SEGMENTS.has(segment)) throw new UnsafePathSegmentError(segment);
|
|
7290
|
-
}
|
|
7291
|
-
function isRecord(value) {
|
|
7292
|
-
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
7293
|
-
}
|
|
7294
|
-
function isPathContainer(value) {
|
|
7295
|
-
return Array.isArray(value) || isRecord(value);
|
|
7296
|
-
}
|
|
7297
|
-
function getContainerValue(container, segment) {
|
|
7298
|
-
if (typeof segment === "number") return Array.isArray(container) ? container[segment] : void 0;
|
|
7299
|
-
if (segment in container) return Reflect.get(container, segment);
|
|
7300
|
-
}
|
|
7301
|
-
function parsePath(path) {
|
|
7302
|
-
if (Array.isArray(path)) {
|
|
7303
|
-
assertSafePathSegments(path);
|
|
7304
|
-
return path;
|
|
7305
|
-
}
|
|
7306
|
-
const segments = [];
|
|
7307
|
-
const parts = path.split(PATH_SEPARATOR_REGEX);
|
|
7308
|
-
for (const raw of parts) {
|
|
7309
|
-
if (!raw) continue;
|
|
7310
|
-
const baseMatch = raw.match(/^[^\[]+/);
|
|
7311
|
-
if (baseMatch !== null) {
|
|
7312
|
-
const base = baseMatch[1] ?? baseMatch[0];
|
|
7313
|
-
if (/^\d+$/.test(base)) segments.push(Number(base));
|
|
7314
|
-
else segments.push(base);
|
|
7315
|
-
}
|
|
7316
|
-
const bracketMatches = raw.matchAll(BRACKET_ACCESS_REGEX);
|
|
7317
|
-
for (const match of bracketMatches) {
|
|
7318
|
-
const token = match[1] ?? "";
|
|
7319
|
-
if (token.startsWith("\"") || token.startsWith("'")) segments.push(token.slice(1, -1));
|
|
7320
|
-
else if (/^\d+$/.test(token)) segments.push(Number(token));
|
|
7321
|
-
else segments.push(token);
|
|
7322
|
-
}
|
|
7323
|
-
if (baseMatch === null && !raw.includes("[")) segments.push(raw);
|
|
7324
|
-
}
|
|
7325
|
-
assertSafePathSegments(segments);
|
|
7326
|
-
return segments;
|
|
7327
|
-
}
|
|
7328
|
-
function getAtPath(source, path) {
|
|
7329
|
-
return parsePath(path).reduce((current, segment) => {
|
|
7330
|
-
if (current === void 0 || current === null) return void 0;
|
|
7331
|
-
if (!isPathContainer(current)) return void 0;
|
|
7332
|
-
return getContainerValue(current, segment);
|
|
7333
|
-
}, source);
|
|
7334
|
-
}
|
|
7335
|
-
//#endregion
|
|
7336
|
-
//#region ../blocks/src/primitives/content/components/Text.tsx
|
|
7337
|
-
function Text({ as: Comp = "span", children, className = "", path, style, "data-slot": dataSlot, "data-surface": dataSurface, maxLength: _maxLength }) {
|
|
7338
|
-
return /* @__PURE__ */ jsx(Comp, {
|
|
7339
|
-
"data-slot": dataSlot,
|
|
7340
|
-
"data-surface": dataSurface,
|
|
7341
|
-
style: dataSlot === void 0 ? void 0 : style,
|
|
7342
|
-
className,
|
|
7343
|
-
...path ? { "data-builder-text": path } : void 0,
|
|
7344
|
-
children
|
|
7345
|
-
});
|
|
7346
|
-
}
|
|
7347
|
-
//#endregion
|
|
7348
|
-
//#region ../blocks/src/system/runtime/nodes/renderInlineText.tsx
|
|
7349
|
-
function renderInlineText(value) {
|
|
7350
|
-
return value.map((run, index) => renderRun(run, index));
|
|
7351
|
-
}
|
|
7352
|
-
function renderRun(run, key) {
|
|
7353
|
-
return (run.marks ?? []).reduceRight((child, mark, index) => renderMark(mark, `${String(key)}-${index}`, child), run.text);
|
|
7354
|
-
}
|
|
7355
|
-
function renderMark(mark, key, child) {
|
|
7356
|
-
switch (mark.kind) {
|
|
7357
|
-
case "strong": return /* @__PURE__ */ jsx("strong", { children: child }, key);
|
|
7358
|
-
case "emphasis": return /* @__PURE__ */ jsx("em", { children: child }, key);
|
|
7359
|
-
case "accent": return /* @__PURE__ */ jsx("span", {
|
|
7360
|
-
className: `rb-inline-text-accent rb-inline-text-accent-${mark.tone}`,
|
|
7361
|
-
children: child
|
|
7362
|
-
}, key);
|
|
7363
|
-
case "highlight": return /* @__PURE__ */ jsx("span", {
|
|
7364
|
-
className: `rb-inline-text-highlight rb-inline-text-highlight-${mark.tone}`,
|
|
7365
|
-
children: child
|
|
7366
|
-
}, key);
|
|
7367
|
-
}
|
|
7368
|
-
}
|
|
7369
|
-
//#endregion
|
|
7370
|
-
//#region ../blocks/src/system/runtime/nodes/basic.tsx
|
|
7371
|
-
const TextNode = ({ value, children, blockContent, inlineTextFallbackPath, ...rest }) => {
|
|
7372
|
-
const inlineText = parseInlineTextFromUnknown(value);
|
|
7373
|
-
if (inlineText.ok && !isInlineTextEmpty(inlineText.value)) return /* @__PURE__ */ jsx(Text, {
|
|
7374
|
-
...rest,
|
|
7375
|
-
children: renderInlineText(inlineText.value)
|
|
7376
|
-
});
|
|
7377
|
-
const fallbackValue = inlineTextFallbackPath ? readStringPath(blockContent, inlineTextFallbackPath) : null;
|
|
7378
|
-
return /* @__PURE__ */ jsx(Text, {
|
|
7379
|
-
...rest,
|
|
7380
|
-
children: fallbackValue ?? textNodeContent(value) ?? children
|
|
7381
|
-
});
|
|
7382
|
-
};
|
|
7383
|
-
function textNodeContent(value) {
|
|
7384
|
-
if (value === null || value === void 0) return null;
|
|
7385
|
-
if (typeof value === "string" || typeof value === "number") return value;
|
|
7386
|
-
return null;
|
|
7387
|
-
}
|
|
7388
|
-
function readStringPath(source, path) {
|
|
7389
|
-
const value = getAtPath(source, path);
|
|
7390
|
-
return typeof value === "string" ? value : null;
|
|
7391
|
-
}
|
|
7392
|
-
const RichTextNode = ({ value, blockKind, ...rest }) => {
|
|
7393
|
-
return /* @__PURE__ */ jsx(RichText, {
|
|
7394
|
-
doc: coerceRichTextDoc(value, `block-runtime:${blockKind ?? "unknown"}:${rest.path ?? "richText"}`) ?? void 0,
|
|
7395
|
-
...rest
|
|
7396
|
-
});
|
|
7397
|
-
};
|
|
7398
|
-
function isMissingRequiredLink(linkRequired, resolvedHref) {
|
|
7399
|
-
return linkRequired && resolvedHref.length === 0;
|
|
7400
|
-
}
|
|
7401
|
-
function authoredButtonDecision(props) {
|
|
7402
|
-
const content = props.value ?? props.children;
|
|
7403
|
-
if (!content) return { kind: "empty" };
|
|
7404
|
-
const href = typeof props.href === "string" ? props.href.trim() : "";
|
|
7405
|
-
if (isMissingRequiredLink(props.linkRequired ?? false, href)) return { kind: "missing-link" };
|
|
7406
|
-
const variant = parseThemeButtonVariantId(props.variantId ?? "primary");
|
|
7407
|
-
if (props.variantId && !variant) return { kind: "invalid-variant" };
|
|
7408
|
-
return {
|
|
7409
|
-
kind: "ready",
|
|
7410
|
-
content,
|
|
7411
|
-
href,
|
|
7412
|
-
variant
|
|
7413
|
-
};
|
|
7414
|
-
}
|
|
7415
|
-
const ButtonNode = (props) => {
|
|
7416
|
-
const decision = authoredButtonDecision(props);
|
|
7417
|
-
switch (decision.kind) {
|
|
7418
|
-
case "empty":
|
|
7419
|
-
console.warn("[ButtonNode] No content to render - value and children are both empty");
|
|
7420
|
-
return null;
|
|
7421
|
-
case "missing-link":
|
|
7422
|
-
console.warn("[ButtonNode] Missing href for link-required button");
|
|
7423
|
-
return null;
|
|
7424
|
-
case "invalid-variant":
|
|
7425
|
-
console.error("[ButtonNode] Invalid button variant", { variantId: props.variantId });
|
|
7426
|
-
return null;
|
|
7427
|
-
case "ready": return /* @__PURE__ */ jsx(AuthoredButtonContent, {
|
|
7428
|
-
props,
|
|
7429
|
-
decision
|
|
7430
|
-
});
|
|
7431
|
-
}
|
|
7432
|
-
};
|
|
7433
|
-
function AuthoredButtonContent({ props, decision }) {
|
|
7434
|
-
if (props.actionStyle === "link" && decision.href && !props.disabled) return /* @__PURE__ */ jsx("a", {
|
|
7435
|
-
href: decision.href,
|
|
7436
|
-
target: props.target,
|
|
7437
|
-
rel: props.rel,
|
|
7438
|
-
onClick: props.onClick,
|
|
7439
|
-
className: `rb-item-text-link btn-${props.size ?? "md"}`,
|
|
7440
|
-
"aria-label": props["aria-label"],
|
|
7441
|
-
"data-testid": props["data-testid"],
|
|
7442
|
-
children: decision.content
|
|
7443
|
-
});
|
|
7444
|
-
return /* @__PURE__ */ jsx(ThemedAuthoredButton, {
|
|
7445
|
-
label: decision.content,
|
|
7446
|
-
href: decision.href || void 0,
|
|
7447
|
-
target: props.target,
|
|
7448
|
-
rel: props.rel,
|
|
7449
|
-
variant: decision.variant,
|
|
7450
|
-
size: props.size ?? "md",
|
|
7451
|
-
disabled: props.disabled,
|
|
7452
|
-
type: props.type ?? "button",
|
|
7453
|
-
trailingIcon: props.trailingIcon,
|
|
7454
|
-
onClick: props.onClick,
|
|
7455
|
-
extraClassName: props.className,
|
|
7456
|
-
ariaLabel: props["aria-label"],
|
|
7457
|
-
dataTestId: props["data-testid"]
|
|
7458
|
-
});
|
|
7459
|
-
}
|
|
7460
|
-
const LinkNode = ({ href, children, className, target, rel, linkRequired = false, ...rest }) => {
|
|
7461
|
-
if (!children) return null;
|
|
7462
|
-
const resolvedHref = typeof href === "string" ? href.trim() : "";
|
|
7463
|
-
if (resolvedHref.length === 0) {
|
|
7464
|
-
if (linkRequired && true) console.warn("[LinkNode] Missing href for link-required link");
|
|
7465
|
-
if (linkRequired) return null;
|
|
7466
|
-
return /* @__PURE__ */ jsx("span", {
|
|
7467
|
-
className,
|
|
7468
|
-
...rest,
|
|
7469
|
-
children
|
|
7470
|
-
});
|
|
7471
|
-
}
|
|
7472
|
-
return /* @__PURE__ */ jsx("a", {
|
|
7473
|
-
href: resolvedHref,
|
|
7474
|
-
className,
|
|
7475
|
-
target,
|
|
7476
|
-
rel,
|
|
7477
|
-
...rest,
|
|
7478
|
-
children
|
|
7479
|
-
});
|
|
7480
|
-
};
|
|
7481
|
-
//#endregion
|
|
7482
7557
|
//#region ../blocks/src/system/runtime/nodes/icon.tsx
|
|
7483
7558
|
const IconNode = ({ value, title, className, blockId: _blockId, blockKind: _blockKind, blockContent: _blockContent, fragmentRegistry: _fragmentRegistry, pathBase: _pathBase, ...rest }) => {
|
|
7484
7559
|
const parsedValue = parseBlockIconValue(value);
|
|
@@ -8760,7 +8835,7 @@ function teamMemberCardContent(member, index, biographySource) {
|
|
|
8760
8835
|
}
|
|
8761
8836
|
function TeamMembersNode(props) {
|
|
8762
8837
|
const parsed = z.array(teamMemberCardSchema).safeParse(props.source === "site_staff" ? props.siteMembers : props.members);
|
|
8763
|
-
if (!parsed.success
|
|
8838
|
+
if (!parsed.success) return null;
|
|
8764
8839
|
return /* @__PURE__ */ jsx(CardListItems, {
|
|
8765
8840
|
Carousel: props.Carousel,
|
|
8766
8841
|
items: parsed.data.map((member, index) => teamMemberCardContent(member, index, props.biographySource)),
|
|
@@ -9035,6 +9110,7 @@ function renderEventListItem(event, source) {
|
|
|
9035
9110
|
lookSlots: display.lookSlots,
|
|
9036
9111
|
itemSurfaces: display.itemSurfaces,
|
|
9037
9112
|
showCapacity: display.showCapacity,
|
|
9113
|
+
showVenue: display.showVenue,
|
|
9038
9114
|
buttonVariant: display.buttonVariant,
|
|
9039
9115
|
buttonText: display.buttonText
|
|
9040
9116
|
}, event.occurrenceId || event.id);
|
|
@@ -10028,108 +10104,6 @@ function WeeklySlotAvailabilitySSR(props) {
|
|
|
10028
10104
|
return /* @__PURE__ */ jsx(WeeklySlotAvailabilityView, { ...props });
|
|
10029
10105
|
}
|
|
10030
10106
|
//#endregion
|
|
10031
|
-
//#region ../blocks/src/system/runtime/nodes/events/RecurringSchedule.tsx
|
|
10032
|
-
function destinationHref(destination) {
|
|
10033
|
-
return destination.kind === "external" ? destination.url : destination.path;
|
|
10034
|
-
}
|
|
10035
|
-
function bookingLinkProps(booking) {
|
|
10036
|
-
return booking.destination.kind === "external" ? {
|
|
10037
|
-
href: destinationHref(booking.destination),
|
|
10038
|
-
target: "_blank",
|
|
10039
|
-
rel: "noopener noreferrer"
|
|
10040
|
-
} : { href: destinationHref(booking.destination) };
|
|
10041
|
-
}
|
|
10042
|
-
function bookingActionContent(input) {
|
|
10043
|
-
switch (input.booking.kind) {
|
|
10044
|
-
case "available": return /* @__PURE__ */ jsx(ButtonNode, {
|
|
10045
|
-
...bookingLinkProps(input.booking),
|
|
10046
|
-
"aria-label": input.accessibleName,
|
|
10047
|
-
className: "recurring-schedule-book",
|
|
10048
|
-
linkRequired: true,
|
|
10049
|
-
variantId: input.buttonVariant,
|
|
10050
|
-
size: "sm",
|
|
10051
|
-
children: input.buttonText
|
|
10052
|
-
});
|
|
10053
|
-
case "unavailable": return null;
|
|
10054
|
-
default: return assertNever$1(input.booking);
|
|
10055
|
-
}
|
|
10056
|
-
}
|
|
10057
|
-
function RecurringSchedule({ dateContext = resolveDateRuntimeContext(void 0), schedule, buttonText = "Book", buttonVariant = "primary", showVenue = true, emptyMessage = "Regular schedule details will be added shortly." }) {
|
|
10058
|
-
const projection = schedule ?? {
|
|
10059
|
-
items: [],
|
|
10060
|
-
diagnostics: []
|
|
10061
|
-
};
|
|
10062
|
-
if (projection.items.length === 0) return /* @__PURE__ */ jsx("p", {
|
|
10063
|
-
className: "recurring-schedule-empty",
|
|
10064
|
-
"data-diagnostic-count": projection.diagnostics.length,
|
|
10065
|
-
children: emptyMessage
|
|
10066
|
-
});
|
|
10067
|
-
return /* @__PURE__ */ jsx("div", {
|
|
10068
|
-
className: "recurring-schedule",
|
|
10069
|
-
"data-diagnostic-count": projection.diagnostics.length,
|
|
10070
|
-
role: "list",
|
|
10071
|
-
children: projection.items.map((item) => /* @__PURE__ */ jsx(RecurringScheduleRow, {
|
|
10072
|
-
item,
|
|
10073
|
-
locale: dateContext.locale,
|
|
10074
|
-
buttonText: buttonText ?? "Book",
|
|
10075
|
-
buttonVariant: buttonVariant ?? "primary",
|
|
10076
|
-
showVenue: showVenue ?? true
|
|
10077
|
-
}, item.seriesId))
|
|
10078
|
-
});
|
|
10079
|
-
}
|
|
10080
|
-
function RecurringScheduleRow({ item, locale, buttonText, buttonVariant, showVenue }) {
|
|
10081
|
-
const startLabel = formatEventClockLabel(item.cadence.startTime, locale);
|
|
10082
|
-
const endLabel = formatEventClockLabel(item.cadence.endTime, locale);
|
|
10083
|
-
const description = `${item.title}, ${item.cadence.weekday} at ${startLabel}`;
|
|
10084
|
-
return /* @__PURE__ */ jsxs("article", {
|
|
10085
|
-
className: "recurring-schedule-row",
|
|
10086
|
-
role: "listitem",
|
|
10087
|
-
"aria-label": description,
|
|
10088
|
-
children: [
|
|
10089
|
-
/* @__PURE__ */ jsx("p", {
|
|
10090
|
-
className: "recurring-schedule-day",
|
|
10091
|
-
children: item.cadence.weekday
|
|
10092
|
-
}),
|
|
10093
|
-
/* @__PURE__ */ jsxs("p", {
|
|
10094
|
-
className: "recurring-schedule-time",
|
|
10095
|
-
children: [
|
|
10096
|
-
/* @__PURE__ */ jsx("time", {
|
|
10097
|
-
dateTime: item.cadence.startTime,
|
|
10098
|
-
children: startLabel
|
|
10099
|
-
}),
|
|
10100
|
-
/* @__PURE__ */ jsx("span", {
|
|
10101
|
-
"aria-hidden": "true",
|
|
10102
|
-
children: "–"
|
|
10103
|
-
}),
|
|
10104
|
-
/* @__PURE__ */ jsx("time", {
|
|
10105
|
-
dateTime: item.cadence.endTime,
|
|
10106
|
-
children: endLabel
|
|
10107
|
-
})
|
|
10108
|
-
]
|
|
10109
|
-
}),
|
|
10110
|
-
/* @__PURE__ */ jsxs("div", {
|
|
10111
|
-
className: "recurring-schedule-details",
|
|
10112
|
-
children: [/* @__PURE__ */ jsx("p", {
|
|
10113
|
-
className: "recurring-schedule-title",
|
|
10114
|
-
children: item.title
|
|
10115
|
-
}), showVenue && item.venueName ? /* @__PURE__ */ jsx("p", {
|
|
10116
|
-
className: "recurring-schedule-venue",
|
|
10117
|
-
children: item.venueName
|
|
10118
|
-
}) : null]
|
|
10119
|
-
}),
|
|
10120
|
-
/* @__PURE__ */ jsx("div", {
|
|
10121
|
-
className: "recurring-schedule-action",
|
|
10122
|
-
children: bookingActionContent({
|
|
10123
|
-
booking: item.booking,
|
|
10124
|
-
buttonVariant,
|
|
10125
|
-
buttonText,
|
|
10126
|
-
accessibleName: `${buttonText} ${description}`
|
|
10127
|
-
})
|
|
10128
|
-
})
|
|
10129
|
-
]
|
|
10130
|
-
});
|
|
10131
|
-
}
|
|
10132
|
-
//#endregion
|
|
10133
10107
|
//#region ../blocks/src/system/runtime/nodes/shop-commerce.server.tsx
|
|
10134
10108
|
function renderServerPendingAction(label, soldOut) {
|
|
10135
10109
|
return /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(ThemedButton, {
|
|
@@ -10692,32 +10666,22 @@ function hourToTickPercent(hour, hours) {
|
|
|
10692
10666
|
const range = Math.max(1, endHour - startHour);
|
|
10693
10667
|
return (hour - startHour) / range * 100;
|
|
10694
10668
|
}
|
|
10695
|
-
|
|
10696
|
-
const islandProps = buildEventCalendarInteractiveIslandProps(props);
|
|
10697
|
-
const display = islandProps.render.display;
|
|
10698
|
-
const hydration = islandProps.render.hydration;
|
|
10699
|
-
let content;
|
|
10669
|
+
function renderEventCalendarMode(display, hydration) {
|
|
10700
10670
|
switch (display.displayMode) {
|
|
10701
|
-
case "
|
|
10702
|
-
|
|
10703
|
-
|
|
10704
|
-
case "
|
|
10705
|
-
|
|
10706
|
-
|
|
10707
|
-
|
|
10708
|
-
content = renderTimetableSsr(display, hydration);
|
|
10709
|
-
break;
|
|
10710
|
-
case "week-board":
|
|
10711
|
-
content = renderWeekBoardSsr(display, hydration);
|
|
10712
|
-
break;
|
|
10713
|
-
case "calendar":
|
|
10714
|
-
content = renderCalendarSsr(display, hydration);
|
|
10715
|
-
break;
|
|
10716
|
-
default: content = assertNeverDisplayMode(display.displayMode);
|
|
10671
|
+
case "week": return /* @__PURE__ */ jsx(CalendarRecurringWeek, { display });
|
|
10672
|
+
case "combined": return renderCombinedSsr(display, hydration.prefetchedEvents);
|
|
10673
|
+
case "list": return renderListSsr(display, hydration);
|
|
10674
|
+
case "timetable": return renderTimetableSsr(display, hydration);
|
|
10675
|
+
case "week-board": return renderWeekBoardSsr(display, hydration);
|
|
10676
|
+
case "calendar": return renderCalendarSsr(display, hydration);
|
|
10677
|
+
default: return assertNeverDisplayMode(display.displayMode);
|
|
10717
10678
|
}
|
|
10679
|
+
}
|
|
10680
|
+
const EventCalendarSSR = (props) => {
|
|
10681
|
+
const islandProps = buildEventCalendarInteractiveIslandProps(props);
|
|
10718
10682
|
return /* @__PURE__ */ jsxs("div", {
|
|
10719
10683
|
...getIslandRootProps("event-calendar", props.blockId),
|
|
10720
|
-
children: [/* @__PURE__ */ jsx(IslandPropsScript, { value: islandProps }),
|
|
10684
|
+
children: [/* @__PURE__ */ jsx(IslandPropsScript, { value: islandProps }), renderEventCalendarMode(islandProps.render.display, islandProps.render.hydration)]
|
|
10721
10685
|
});
|
|
10722
10686
|
};
|
|
10723
10687
|
//#endregion
|
|
@@ -11173,4 +11137,4 @@ const serverComponentRegistry = {
|
|
|
11173
11137
|
...buildServerRegistryFromEntries(runtimeBackedBlockServerEntries)
|
|
11174
11138
|
};
|
|
11175
11139
|
//#endregion
|
|
11176
|
-
export {
|
|
11140
|
+
export { backgroundFrame as $, buildRepeaterGridLayout as $t, cardListSectionActionFields as A, galleryReadiness as At, createBlockManifest as B, blockSectionDeclarationShape as Bt, eventRegistrationBlockDefinition as C, lookQuoteLimitTransform as Ct, cardListKnobFields as D, PUBLIC_DOWNLOAD_MEDIA_TYPES as Dt, cardListSectionAction as E, parseBlockIconValue as Et, desktopOnlyDisplay as F, pageTemplateFromEntry as Ft, composeFragments as G, normalizeSelectSource as Gt, withApiBindings as H, createSdkSelectField as Ht, mobileOnlyDisplay as I, unavailableReadinessFact as It, sectionHeaderLayoutNodes as J, validateManifestLookField as Jt, defineFragment as K, parseFieldDefinition as Kt, normalizeMailingListBlockContent as L, DEFAULT_MEDIA_FIELD_KINDS as Lt, composeHeaderSectionWrapperClassName as M, testimonialsReadiness as Mt, markEditableSurfaceForwarding as N, admitReadinessFacts as Nt, cardListPhotoNumberFields as O, augmentManifest as Ot, splitPositioningClasses as P, loadedReadinessFact as Pt, sectionContainer as Q, projectRepeaterGridLayoutForRendering as Qt, formBlockDefinition as R, PUBLIC_FILE_FIELD_KINDS as Rt, eventListingBlockDefinition as S, lookLeadSlotTransform as St, FEATURE_CARD_ICON_TREATMENTS as T, lookSlot as Tt, formCopyFragment as U, createSiteOptionSelectField as Ut, formEmbedFragment as V, builtInBlockKindsSchema as Vt, buildFragmentDataLoaders as W, fieldSchema as Wt, styledSection as X, validateSdkBlockDeclaration as Xt, resolveBackgroundColorValue as Y, sdkBlockPresentationShape as Yt, styledContainer as Z, projectRepeaterGridLayout as Zt, cartBlockDefinition as _, BACKGROUND_POSITION_PRESET_VALUES as _n, stack as _t, buildLoadedOfferingsPreviewListing as a, NodeSchema as an, el as at, shopBlockDefinition as b, createButtonVariantField as bn, when as bt, accordionItemPartSlots as c, linkSchema as cn, headerSection as ct, resolveAccordionIconStyle as d, emptyStateField as dn, link as dt, parseRepeaterGridInteger as en, accordionList as et, SectionNode as f, eventDisplayFields as fn, media as ft, checkoutBlockDefinition as g, sectionStylesField as gn, section as gt, giftingBlockDefinition as h, containerStylesField as hn, richText as ht, WeeklySlotAvailabilityView as i, resolveRepeaterGridSpanFieldId as in, carousel as it, normalizeCardListContent as j, teamReadiness as jt, cardListPresentationBindings as k, chosenString as kt, accordionLookAttributes as l, cardStylingFields as ln, icon as lt, sanitizeNewsletterSignupPublicContent as m, cardStylesField as mn, repeat as mt, runtimeBackedBlockModes as n, resolveRepeaterGridColumnsForBreakpoint as nn, bookingForm as nt, buildAppointmentServicesView as o, bindingSchema as on, fileDownload as ot, newsletterSignupBlockDefinition as p, layoutField as pn, props as pt, sectionHeaderFields as q, parseFieldDefinitions as qt, runtimeBackedBlockServerEntries as r, resolveRepeaterGridRowFieldId as rn, button as rt, HeaderSectionFrame as s, RESOLVED_INTERNAL_LINK_ENTITY_TYPES as sn, form as st, serverComponentRegistry as t, resolveRepeaterGridColumnFieldId as tn, bind as tt, accordionIconColorStyle as u, columnsField as un, inline as ut, productDetailBlockDefinition as v, getAnchorClasses as vn, text as vt, FEATURE_CARD_GENERATED_ICON_SIZE_PX as w, lookSkinSlotTransform as wt, eventCalendarBlockDefinition as x, lookCarouselRegionTransform as xt, productListBlockDefinition as y, createButtonGroup as yn, videoEmbed as yt, formDataSchema as z, blockCategoryEnum as zt };
|