@riverbankcms/sdk 0.182.0 → 0.184.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +79 -0
- package/README.md +83 -4
- package/dist/_dts/{BlocksIslandsHydrator-Bvw2bUif.d.ts → BlocksIslandsHydrator-DjBTJYiF.d.ts} +1 -1
- package/dist/_dts/{Page-B2EAT-bE.d.ts → Page-BpXEM2ET.d.ts} +7 -7
- package/dist/_dts/{SdkPreviewMode-D0vww6rh.d.ts → SdkPreviewMode-Bb3h7KRE.d.ts} +2 -2
- package/dist/_dts/{client-D6T430bk.d.ts → client-DgTRRtl_.d.ts} +14 -1
- package/dist/_dts/{content-types-wZVWccC6.d.ts → content-types-DZQJp_ak.d.ts} +9 -16
- package/dist/_dts/{contracts-B-vtOcr8.d.ts → contracts-Ww1fmd-c.d.ts} +3 -3
- package/dist/_dts/{generatePageMetadata-CxfwHE6z.d.ts → generatePageMetadata-BGc7dju6.d.ts} +2 -2
- package/dist/_dts/{index-CciRW_w1.d.ts → index-BECaUNYs.d.ts} +2 -2
- package/dist/_dts/{index-CEyYMhLJ.d.ts → index-Cc85KVLW.d.ts} +3 -3
- package/dist/_dts/{index-CQrb3Ccc.d.ts → index-Cni4jykw.d.ts} +4 -4
- package/dist/_dts/{index-DIU-wL1M.d.ts → index-DxxTQ_0V.d.ts} +2 -2
- package/dist/_dts/{index-Cqxis-nv.d.ts → index-W9-7djG3.d.ts} +1 -1
- package/dist/_dts/{index-DqPKdeTk.d.ts → index-ukS-Ffem.d.ts} +1 -1
- package/dist/_dts/{loadContent-D0wrxiSp.d.ts → loadContent-BlSWTlbD.d.ts} +7 -7
- package/dist/_dts/{request-DEwxUSw8.d.ts → request-CZz2BoXJ.d.ts} +89478 -88093
- package/dist/_dts/{resolveBlockData-VaG_MYbN.d.ts → resolveBlockData-D12HXnS3.d.ts} +5 -5
- package/dist/_dts/{resolvePageContent-DTwklC_v.d.ts → resolvePageContent-BteMsSGP.d.ts} +1 -1
- package/dist/_dts/sdk/src/bookings/index.d.ts +2 -2
- package/dist/_dts/sdk/src/client/types.d.ts +2 -2
- package/dist/_dts/sdk/src/client.d.ts +7 -7
- package/dist/_dts/sdk/src/config/index.d.ts +7 -7
- package/dist/_dts/sdk/src/config/template-validation.d.ts +1 -1
- package/dist/_dts/sdk/src/config/validation.d.ts +1 -1
- package/dist/_dts/sdk/src/data/dataLoaderContext.d.ts +2 -2
- package/dist/_dts/sdk/src/data/resolveBlockData.d.ts +1 -1
- package/dist/_dts/sdk/src/data/types.d.ts +2 -2
- package/dist/_dts/sdk/src/gifting/client.d.ts +1 -1
- package/dist/_dts/sdk/src/index.d.ts +8 -8
- package/dist/_dts/sdk/src/manifest/index.d.ts +3 -3
- package/dist/_dts/sdk/src/metadata/index.d.ts +1 -1
- package/dist/_dts/sdk/src/navigation/index.d.ts +3 -3
- package/dist/_dts/sdk/src/next/index.d.ts +7 -7
- package/dist/_dts/sdk/src/next/middleware.d.ts +2 -2
- package/dist/_dts/sdk/src/page-converter/index.d.ts +3 -3
- package/dist/_dts/sdk/src/portal/client.d.ts +1 -1
- package/dist/_dts/sdk/src/portal/index.d.ts +10 -2
- package/dist/_dts/sdk/src/prebuild/index.d.ts +1 -1
- package/dist/_dts/sdk/src/preview-next/before-render.d.ts +2 -2
- package/dist/_dts/sdk/src/preview-next/client/index.d.ts +2 -2
- package/dist/_dts/sdk/src/preview-next/client/runtime.d.ts +1 -1
- package/dist/_dts/sdk/src/rendering/client.d.ts +2 -2
- package/dist/_dts/sdk/src/rendering/components/pageShared.d.ts +1 -1
- package/dist/_dts/sdk/src/rendering/helpers/loadPage.d.ts +1 -1
- package/dist/_dts/sdk/src/rendering/helpers/pageRuntimeSupport.d.ts +4 -4
- package/dist/_dts/sdk/src/rendering/index.d.ts +6 -6
- package/dist/_dts/sdk/src/rendering/islands/client.d.ts +1 -1
- package/dist/_dts/sdk/src/rendering/server.d.ts +2 -2
- package/dist/_dts/sdk/src/rendering/themeAdmission.d.ts +1 -1
- package/dist/_dts/sdk/src/routing/index.d.ts +6 -6
- package/dist/_dts/sdk/src/server.d.ts +5 -5
- package/dist/_dts/sdk/src/spam-protection/index.d.ts +2 -2
- package/dist/_dts/sdk/src/theme/index.d.ts +126 -2
- package/dist/_dts/{serviceBookingOutline-DtQuFlID.d.ts → serviceBookingOutline-aTlOvO3U.d.ts} +16 -8
- package/dist/_dts/{types-B3RjeBLV.d.ts → types-Bi7R07RX.d.ts} +45 -4
- package/dist/_dts/{types-BvUSGQrw.d.ts → types-CCcQlRBi.d.ts} +22 -12
- package/dist/_dts/{types-CkRFtBqd.d.ts → types-Du4aMnWC.d.ts} +13 -15
- package/dist/_dts/{validation-BZA3DhcV.d.ts → validation-CjCWVmwe.d.ts} +4 -4
- package/dist/client/{BlocksIslandsHydrator-CQMf0HdN.mjs → BlocksIslandsHydrator-CFLWxjxR.mjs} +22 -18
- package/dist/client/{BookingMailingListNote-7kdvuPow.mjs → BookingMailingListNote-C4LcfwyA.mjs} +8 -8
- package/dist/client/{BookingQuestionFields-BJI7mZuV.mjs → BookingQuestionFields-DdcmoHqQ.mjs} +2 -2
- package/dist/client/{CalendarAction-D_Glwvz2.mjs → CalendarAction-DYGewmvh.mjs} +1 -1
- package/dist/client/{CalendarNavigationChevron-DPUD6wjy.mjs → CalendarNavigationChevron-ZfrUiiiI.mjs} +25 -8
- package/dist/client/{CheckboxChoice-C8i4NraK.mjs → CheckboxChoice-CTMIII37.mjs} +1 -1
- package/dist/client/{DemoBookingPortalAccess-8kwNF9HN.mjs → DemoBookingPortalAccess-pzkGVkgG.mjs} +7 -5
- package/dist/client/{EventCalendar.client-Dhb14bcC.mjs → EventCalendar.client-Ct1B3xI4.mjs} +10 -10
- package/dist/client/{EventCombined.client-C1jEZBN9.mjs → EventCombined.client-DgfNtcgW.mjs} +9 -9
- package/dist/client/{EventEmbeddedCheckoutStep-BGkbUhuw.mjs → EventEmbeddedCheckoutStep-CjoaG1zy.mjs} +1 -1
- package/dist/client/{EventItem-Bb0ppG2N.mjs → EventItem-KGKkK19N.mjs} +29 -14
- package/dist/client/{EventListWeekNavigation-DMryCaNV.mjs → EventListWeekNavigation-Ba9ezxuC.mjs} +1 -1
- package/dist/client/{EventListing.client-BuH5kKA3.mjs → EventListing.client-xFKRDLwC.mjs} +3 -3
- package/dist/client/{EventListing.view-DsqvuulZ.mjs → EventListing.view-Dy36vWHi.mjs} +84 -7
- package/dist/client/{EventRegistrationPayment-D4FvQSFF.mjs → EventRegistrationPayment-Dth9L00x.mjs} +118 -76
- package/dist/client/{Page-sV6BJkXX.mjs → Page-DB5KODiu.mjs} +4491 -1398
- package/dist/client/{ProtectedSubmitButton-BNnKuir8.mjs → ProtectedSubmitButton-CY6u5sQa.mjs} +1 -1
- package/dist/client/{SiteTermsAgreementField-VfSd6JU-.mjs → SiteTermsAgreementField-BDVP_HeK.mjs} +3 -3
- package/dist/client/{StepIndicator-B6o5B7g3.mjs → StepIndicator-CLgDVzCs.mjs} +1 -1
- package/dist/client/{StepIndicator-BTqO7cJl.mjs → StepIndicator-DRyZ8igu.mjs} +7 -7
- package/dist/client/{ThemedButton-PFOhXktM.mjs → ThemedButton-C4rCsPCt.mjs} +52 -10
- package/dist/client/{accessibleSurfaces-BogaGutk.mjs → accessibleSurfaces-CqroimVQ.mjs} +1024 -619
- package/dist/client/{accordion-6cuswD_s.mjs → accordion-BQYRP5xV.mjs} +1 -1
- package/dist/client/{booking-form.client-BOMe_SKi.mjs → booking-form.client-B7ckDuOC.mjs} +191 -71
- package/dist/client/{bookingForm-DSCH-VHo.mjs → bookingForm-BeD4650p.mjs} +7 -6
- package/dist/client/bookings.mjs +5 -5
- package/dist/client/{boxStyleClassNames-BFuqZCfz.mjs → boxStyleClassNames-CA7FirMH.mjs} +2 -2
- package/dist/client/buttonParts-C39GC0kz.mjs +1518 -0
- package/dist/client/{carousel-CGyQVV1M.mjs → carousel-DJ9Aa1m3.mjs} +2 -2
- package/dist/client/{carousel.client-BtLwHefX.mjs → carousel.client-DKWqVHHh.mjs} +1 -1
- package/dist/client/{cart-BYOe7MCh.mjs → cart-DdCenbTy.mjs} +3 -3
- package/dist/client/{cart.client-BKFkaXdV.mjs → cart.client-BQm06qNw.mjs} +1 -1
- package/dist/client/{checkout-Dwd7Di77.mjs → checkout-45wPQULN.mjs} +3 -3
- package/dist/client/{checkout.client-C25hpi-z.mjs → checkout.client-bSv4cc5z.mjs} +1 -1
- package/dist/client/{checkoutUrls-tG788sw0.mjs → checkoutUrls-CwlaMl3W.mjs} +1 -1
- package/dist/client/client.mjs +460 -119
- package/dist/client/{constants-DdxFG3Ic.mjs → constants-DXV4KR7l.mjs} +1 -1
- package/dist/client/{context-Hi1RuYEM.mjs → context-lCPfX-xe.mjs} +15 -5
- package/dist/client/{dateFormatting-C8vBCHuo.mjs → dateFormatting-HvfmS_cH.mjs} +1 -1
- package/dist/client/{demoPortalMagicLink-BAL5UIDG.mjs → demoPortalMagicLink-Ce3Gyin_.mjs} +1 -1
- package/dist/client/{enhanceHeaderSection-Dv1Lr9kJ.mjs → enhanceHeaderSection-CGcDE9aE.mjs} +4 -4
- package/dist/client/{event-registration.client-dB_Z7bb-.mjs → event-registration.client-DlPfn4YG.mjs} +52 -29
- package/dist/client/{eventCalendar-CQnRA4Ww.mjs → eventCalendar-CioAdryV.mjs} +4 -4
- package/dist/client/{eventCombined-BDOG1hVp.mjs → eventCombined-Dwt0G6ez.mjs} +4 -4
- package/dist/client/{eventListing-DSVmhy9n.mjs → eventListing-B3H9ifOC.mjs} +4 -4
- package/dist/client/{eventRegistration-CD5mRtEH.mjs → eventRegistration-Do7cAhXb.mjs} +7 -6
- package/dist/client/{form-DWnlEVSK.mjs → form-CsqzgC6v.mjs} +3 -3
- package/dist/client/{form.client-D7zmeqNI.mjs → form.client-DVDB7hY6.mjs} +5 -5
- package/dist/client/{form.parts-C-G6N_MK.mjs → form.parts-1q2rzSYt.mjs} +3 -3
- package/dist/client/gifting/client.mjs +16 -9
- package/dist/client/{gifting-Cn0jidP5.mjs → gifting-BrXQGX-k.mjs} +4 -4
- package/dist/client/{gifting.client-DVo1YFLs.mjs → gifting.client--zAjnY5N.mjs} +155 -85
- package/dist/client/gifting.interactive-CrwHpUJG.mjs +207 -0
- package/dist/client/gifting.parts-CcKdDaQq.mjs +124 -0
- package/dist/client/{headerSection-DjQuj_6v.mjs → headerSection-DlcDH4bi.mjs} +2 -2
- package/dist/client/{noop-jesvJXEE.mjs → islands-dMh0Oxli.mjs} +16103 -7965
- package/dist/client/{newsletter-form.client-rIYPziZC.mjs → newsletter-form.client-BxA1PsdS.mjs} +6 -6
- package/dist/client/{newsletter-form.interactive-DVt3enLr.mjs → newsletter-form.interactive-D0iRg7p2.mjs} +229 -197
- package/dist/client/{newsletter-form.parts-CH6dGfdn.mjs → newsletter-form.parts-Dmuklz0r.mjs} +2 -2
- package/dist/client/{newsletterForm-Cg8cBDHd.mjs → newsletterForm-CBzvgIfg.mjs} +3 -3
- package/dist/client/portal/client.mjs +51 -35
- package/dist/client/{portalOrders-oEoTvzkW.mjs → portalOrders-tCxS04g0.mjs} +3 -2
- package/dist/client/{portalRoutes-ByyVZfVq.mjs → portalRoutes-DiGibcZI.mjs} +31 -9
- package/dist/client/portalSession-0XhXyTxT.mjs +41 -0
- package/dist/client/{product-detail.client-5aHq-vuu.mjs → product-detail.client-D9MP8hvH.mjs} +1 -1
- package/dist/client/{product-list.client-CyAk5rnC.mjs → product-list.client-wCz1qcUY.mjs} +1 -1
- package/dist/client/{productDetail-B8aZ2mqY.mjs → productDetail-D9-fCY6c.mjs} +3 -3
- package/dist/client/{productList-BuLemmod.mjs → productList-PJyxXSac.mjs} +3 -3
- package/dist/client/{propsDecoder-0Unsqn3R.mjs → propsDecoder-B8lrKGPw.mjs} +4 -2
- package/dist/client/{registry.server-DzvtVVD0.mjs → registry.server-CI63JVHW.mjs} +2444 -1078
- package/dist/client/rendering/client.mjs +32 -28
- package/dist/client/rendering/islands.mjs +1 -1
- package/dist/client/rendering.mjs +5 -5
- package/dist/client/{richText-coerce-Bnng7JFA.mjs → richText-coerce-Jt9hDHdh.mjs} +2 -2
- package/dist/client/{routeIslandApiConfig-BGfcc9sk.mjs → routeIslandApiConfig-ZSPcJWx1.mjs} +1 -1
- package/dist/client/runtimeResponse-DlPBWBd9.mjs +3 -0
- package/dist/client/{runtimeResponse-DAPVRToN.mjs → runtimeResponse-_iW9oEYc.mjs} +1 -1
- package/dist/client/{shop-GuMqnDL-.mjs → shop-CbdJlWOw.mjs} +3 -3
- package/dist/client/{shop-commerce-D5bDY1o1.mjs → shop-commerce-BqLbzUUn.mjs} +47 -28
- package/dist/client/{shop-commerce-store-B7sHnLwI.mjs → shop-commerce-store-BT0-zRqN.mjs} +1 -1
- package/dist/client/{shop-discount-apply.state-Dos2zdC2.mjs → shop-discount-apply.state-Cws0lnSb.mjs} +2 -2
- package/dist/client/{shop.client-uvj5GDZb.mjs → shop.client-0cNErhJT.mjs} +54 -24
- package/dist/client/{shopShared-3giNWE3H.mjs → shopShared-COuQ2MhQ.mjs} +2 -2
- package/dist/client/spam-protection.mjs +1 -1
- package/dist/client/{src-CmXh3JWs.mjs → src-Do_s2lqH.mjs} +11 -18
- package/dist/client/{timetableModel-GA-hn1qM.mjs → timetableModel-DqI6U1BS.mjs} +11 -8
- package/dist/client/{urlParams-C2QHo1Pa.mjs → useAutomaticDiscountPreview-CeVUVzGf.mjs} +44 -1
- package/dist/client/{useAvailableSlots-CBneCxbG.mjs → useAvailableSlots-B0mjVhZr.mjs} +2 -2
- package/dist/client/{useDiscountCodeUi-D0kGF0C7.mjs → useDiscountCodeUi-B_hfgdAP.mjs} +6 -2
- package/dist/client/{useEventPagination-xX8n_Tuu.mjs → useEventPagination-Ct4A6iR1.mjs} +14 -16
- package/dist/client/{view-DOyZc-DF.mjs → view-Cj151w4m.mjs} +24 -9
- package/dist/client/{wizardSteps-B952ify5.mjs → wizardSteps-B3gsXNnb.mjs} +283 -222
- package/dist/preview-next/client/{EventEmbeddedCheckoutStep-aRJjq4x8.mjs → EventEmbeddedCheckoutStep-CVy9oapv.mjs} +1 -1
- package/dist/preview-next/client/{LocationPickerEnvironment-BW3dRFIv.mjs → LocationPickerEnvironment-DuRUwUrK.mjs} +1 -1
- package/dist/preview-next/client/{MapLibreEditMap-Db9BHyXh.mjs → MapLibreEditMap-CdSDYBq9.mjs} +2 -2
- package/dist/preview-next/client/{PageSectionToolbar-BI3UCdpu.mjs → PageSectionToolbar-Dv4CW0AQ.mjs} +952 -138
- package/dist/preview-next/client/{PreviewEditorSidebar-jkfLVOgY.mjs → PreviewEditorSidebar-B7WW58uE.mjs} +4774 -2040
- package/dist/preview-next/client/{PreviewEditorUI-DwJQs4hM.mjs → PreviewEditorUI-BnJ1ughv.mjs} +71 -47
- package/dist/preview-next/client/{PreviewShell-BAxAkuz8.mjs → PreviewShell-C7qWzAe4.mjs} +72 -40
- package/dist/preview-next/client/{SdkPreviewModeRuntime-0UVB-39f.mjs → SdkPreviewModeRuntime-CYi4UHtG.mjs} +135 -30
- package/dist/preview-next/client/{ThemedButton-CVYz7h68.mjs → ThemedButton-CRgbU75r.mjs} +799 -17
- package/dist/preview-next/client/{lucide-react-00FF_oar.mjs → lucide-react-B4c6U3ZU.mjs} +11 -1
- package/dist/preview-next/client/{previewAssistantSlot-BgiYk3PB.mjs → previewAssistantSlot-DrUoRNu9.mjs} +24203 -9291
- package/dist/preview-next/client/{previewChromeRoot-tieNdF3E.mjs → previewChromeRoot-CEYp90mM.mjs} +3 -90
- package/dist/preview-next/client/runtime.mjs +3 -3
- package/dist/preview-next/client/{sdk-runtime-DXb_Evl0.mjs → sdk-runtime-DnO2_c0A.mjs} +2 -2
- package/dist/preview-next/client/{siteStyleAccess-BlN0jt2c.mjs → siteStyleAccess-B3PwHw2z.mjs} +46 -11
- package/dist/preview-next/client/{useAutosaveStatus-BUEPA4oL.mjs → useAutosaveStatus-DrdQ4ier.mjs} +49 -3
- package/dist/preview-next/client/{useOpenBlockForSetup-BVfr5P--.mjs → useOpenBlockForSetup-kuGRKaRL.mjs} +2008 -448
- package/dist/preview-next/container-responsive.css +469 -2
- package/dist/preview-next/editor-chrome.css +23 -2
- package/dist/preview-next/keepAlive.mjs +1 -1
- package/dist/preview-next/middleware.mjs +1 -1
- package/dist/preview-next/{route-contract-BHTBA48n.mjs → route-contract-CwrXkLT3.mjs} +177 -43
- package/dist/server/{Block.shared-hGoyEdjJ.mjs → Block.shared-C5ucphCJ.mjs} +5 -5
- package/dist/server/{ThemeScopeCore-BfUCTOwj.mjs → ThemeScopeCore-DvbqYXdK.mjs} +46 -10
- package/dist/server/{accessibleSurfaces-Dskni4Xj.mjs → accessibleSurfaces-CAcf1lHT.mjs} +732 -176
- package/dist/server/{accordions-By_0Ykks.mjs → accordions-DjcsqjCK.mjs} +1 -1
- package/dist/server/{bindings-DMJH4bvo.mjs → bindings-CFw4M-gZ.mjs} +69 -248
- package/dist/server/{client-DrwlRNAH.mjs → client-D0XCgITW.mjs} +488 -119
- package/dist/server/config-validation.mjs +1 -1
- package/dist/server/config.mjs +2 -2
- package/dist/server/{constants-CeMywaiD.mjs → constants-BZduY8jG.mjs} +31 -8
- package/dist/server/data/resolveBlockData.mjs +1 -1
- package/dist/server/index.mjs +4 -4
- package/dist/server/{loadContent-D0prFflT.mjs → loadContent-C-qyB8Tq.mjs} +11 -10
- package/dist/server/{loadPage-CBLke9pJ.mjs → loadPage-BpKKmi8E.mjs} +3 -3
- package/dist/server/lookMediaFrame-EFws7tAj.mjs +31835 -0
- package/dist/server/manifest.mjs +2 -2
- package/dist/server/{navigation-wrcuWmgp.mjs → navigation-DYkuiNXa.mjs} +1 -1
- package/dist/server/navigation.mjs +1 -1
- package/dist/server/next.mjs +9 -9
- package/dist/server/{overrideResolution-DUgCEH8z.mjs → overrideResolution-DmZn4xUE.mjs} +1 -1
- package/dist/server/page-converter.mjs +18 -5
- package/dist/server/{pageRenderPlan-BHrmogsW.mjs → pageRenderPlan-DRB7cUZ0.mjs} +674 -298
- package/dist/server/{pageRuntimeSupport-D2-YMRei.mjs → pageRuntimeSupport-Uv1xDieJ.mjs} +13 -6
- package/dist/server/{pageShared-CG8O31Eo.mjs → pageShared-BdQF875z.mjs} +911 -516
- package/dist/server/{parseThemeForPersistence-CrPlbJEN.mjs → parseThemeForPersistence-CwcWZL7u.mjs} +3 -3
- package/dist/server/{portal-pG_uhsI2.mjs → portal-BQ8qiQnk.mjs} +22 -2
- package/dist/server/portal.mjs +3 -3
- package/dist/server/{prebuild-C8Amvzce.mjs → prebuild-B51QZVNe.mjs} +1 -1
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/{prefetchBlockData-BxUETRIZ.mjs → prefetchBlockData-CppDAfJW.mjs} +4 -4
- package/dist/server/{registry-Cc88-23f.mjs → registry-Bf4W8Qa7.mjs} +7585 -24378
- package/dist/server/rendering/components/pageShared.mjs +1 -1
- package/dist/server/rendering/helpers/loadPage.mjs +1 -1
- package/dist/server/rendering/helpers/pageRuntimeSupport.mjs +1 -1
- package/dist/server/rendering/server.mjs +4 -4
- package/dist/server/rendering.mjs +10 -10
- package/dist/server/{resolveBlockData-OG3KOkig.mjs → resolveBlockData-DMHAZooQ.mjs} +2 -2
- package/dist/server/{expandPalette-ehuW8r2g.mjs → resolveButtonColourStates-BMtAAPzp.mjs} +1670 -1346
- package/dist/server/{responseMedia-IfH65QAH.mjs → responseMedia-DKYfR518.mjs} +1 -1
- package/dist/server/{schema-CwfxQjc4.mjs → schema-DGaihVwp.mjs} +300 -29
- package/dist/server/server.mjs +3 -3
- package/dist/server/{servicePageContent-BcFuhhD7.mjs → servicePageContent-CRvmreX7.mjs} +40 -16
- package/dist/server/theme-bridge.mjs +5 -4
- package/dist/server/theme.mjs +2 -2
- package/dist/server/{three-pass-converter-DPaUPTfl.mjs → three-pass-converter-mcy2E1Yd.mjs} +2 -2
- package/dist/server/{titleSourceSchema-NhK6azFS.mjs → titleSourceSchema-B2qFOUwZ.mjs} +4 -5
- package/dist/server/{typeGuards-CTW_9AXq.mjs → typeGuards-DZOaGTEv.mjs} +126 -126
- package/dist/server/{types-BKaBZFjD.mjs → types-C_S0pWbR.mjs} +487 -9
- package/dist/server/{validation-BovmbS8N.mjs → validation-CUtNT_EZ.mjs} +14 -10
- package/dist/server/{version-hws4hgyX.mjs → version-DebJQ4zn.mjs} +1 -1
- package/dist/server/{video-Cdr3wh-q.mjs → video-DBaeSawZ.mjs} +1 -1
- package/dist/styles/index.css +2987 -168
- package/package.json +1 -1
- package/dist/client/gifting.parts-Bak93gD2.mjs +0 -86
- package/dist/client/runtimeResponse-nXT8VAMl.mjs +0 -3
- package/dist/client/types-BEaKfam_.mjs +0 -778
- package/dist/server/customCss-C9kgPHvr.mjs +0 -247
- package/dist/server/lookMediaFrame-H0fi4bJk.mjs +0 -2701
- package/dist/server/media-gvfIw3z8.mjs +0 -216
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import { f as assertNever$1, n as resolveLookMediaFrame } from "./lookMediaFrame-H0fi4bJk.mjs";
|
|
1
|
+
import { K as hexColorSchema, et as parseThemeColorToken } from "./types-C_S0pWbR.mjs";
|
|
2
|
+
import { H as resolveConcreteColorHex, L as pickBlackOrWhiteTextColor, _ as runtimeMediaSchema, ct as hexToRgb, dt as oklabToSrgb, ft as oklchToHexGamut, ht as srgbToOklab, mt as rgbToHex, tt as contrastRatio, ut as oklabToOklch } from "./resolveButtonColourStates-BMtAAPzp.mjs";
|
|
3
|
+
import { F as resolveTokenOrCssColorValue, M as isCssColorLiteral, N as resolveOnColorForThemeToken, r as parseSurfaceTree, t as certifyFinishedGround } from "./accessibleSurfaces-CAcf1lHT.mjs";
|
|
4
|
+
import { $r as heroMorePhotoCount, Ai as boxStylesTransforms, Ar as headerRuntimeTransforms, B as combinedLookSchema, Ba as resolveEventCalendarReadPlan, Co as eventScopeQueryKeys, Cr as contentTransforms, Dn as formatTime, Dr as readRuntimeNow, Ds as toUtcIsoDateTimeString, En as formatEventWeekdayTime, Fi as parseBackgroundOverlay, Fr as formattingTransforms, Ga as lookPresentationOnPalette, Gi as lookCarouselRegionTransform, Gn as isDropInPublicEvent, Gr as listItemPresentation, Hi as isSemanticSpacing, Ia as resolveEventCalendarRead, Ii as parseRuntimeBackgroundContent, Is as resolveExactOrFreePriceDisplay, Ja as groundPaint, Ji as lookSkinSlotTransform, Ka as resolveLookSurfacePresentation, Ki as lookLeadSlotTransform, La as resolveEventScopeRead, Li as resolveSectionSurfaceForeground, Ls as resolvePricingOptionsPriceDisplay, Ma as eventReadinessLoaderKey, Mr as layoutTransforms, Na as eventReadinessQuery, Nn as formatDateKey, On as groupEventsByDate, Os as resolveBookingBusinessTimeZone, Pa as eventReadinessQueryKeys, Pi as parseBackgroundContent, Pr as uiTransforms, Q as CardListLeadDate, Qt as formatBookingSchedulePresentation, Ra as eventCalendarListGroupingDecision, Ri as resolveSurfaceForegroundStyles, So as eventScopeLoaderParam, Tn as formatEventTimeRange, Ts as parseBookingLocalDate, Ut as ThemedButtonLink, Vo as placedEditingPaths, Vs as arrangementSlotNames, Xa as boundaryGeometryStyle, Xi as createTransformRegistry, Xt as groupEventsByWeek, Ya as pageGround, Yi as asPartialObject, Z as CardListContentPart, Zt as weekColumnDays, _o as sectionForegroundBackground, ai as resolveClassPriceItems, ar as resolveEventPageLink, bn as formatEventCompactDateRail, bt as lookPartShown, ca as ClockIcon, ci as formatEventPrice, co as siteStyleEdges, di as formatEventStartingPrice, do as deriveSectionGround, dr as getEventAvailability, dt as resolveArrangementKnobs, et as resolveCardListSchedule, fi as BACKGROUND_POSITION_PRESET_VALUES, fo as parseCanonicalRuntimeBackground, fr as getEventAvailabilityStatus, ft as systemCustomizeFacetDefinitionsForBlock, gn as eventLocalDateKey, go as sectionDecisionFromContent, gs as formatDateTimeRange, gt as EventQuickFacts, hn as eventDateOptions, ho as resolveSectionPhotoPlacement, hs as formatDateRange, ii as classPricesDataSchema, in as formatEventLocation, ir as resolveEventCta, is as orderedLiveRunSessions, it as ImagePresets, ja as blockChecksForEvents, jr as chromeLogoTransforms, js as formatBookingPriceDisplay, jt as groupOfferingRunsByCourse, ka as augmentManifest, kn as resolveEventTimeZone, kr as mediaTransforms, ln as closedRunCopy, lr as formatEventRemainingPlaces, mn as eventCalendarWeekStart, mo as resolveSectionForeground, ms as formatDate, no as sectionPhotoPath, nt as MediaNodeServer, oi as formatCoursePrice, ot as computeMediaTransformStyle, pi as getAnchorClasses, po as resolveSectionBackground, qi as lookQuoteLimitTransform, qr as listLookSlot, qt as buildEventListWeek, ri as classPricesCopySchema, ro as storedSectionPhoto, rr as resolveEventCardBooking, rs as nextLiveRunSessionStartMs, si as formatEventDepositNote, sr as isBookableEvent, t as getBlockDefinition, to as heroPhotoPaintsGround, tt as selectCardListPresentation, ui as formatEventPriceDisplay, uo as applyLookPhotoTreatment, ur as formatTotalCapacity, wn as formatEventRunDates, wo as resolveEventScope, ws as getLocalScheduleDate, xn as formatEventDateParts, xo as eventDiscoveryFilterKeys, xs as compareLocalScheduleDates, yt as resolveCalendarReadProfile, za as eventCalendarLookViews, zi as resolveBackgroundColorValue, zn as isToday } from "./registry-Bf4W8Qa7.mjs";
|
|
5
|
+
import { Dt as transitionCatalogueEntryForIntent, It as assertNever, L as sectionShapeForGround, R as sectionShapeFromContent, at as themeV2CompilerOwnedFieldNames, b as deriveSiteStyleBlockPolicy, ct as resolveGroundPaint, f as arrangementManifestFromVariants, g as resolvePublishedLook, h as resolveModeArrangement, it as stripStaleTransitionStyleGroup, lt as resolveSectionTreatment, m as resolveEffectiveArrangement, n as resolveLookMediaFrame, ot as groundFlatZone, p as readStoredMode, r as arrangementAppearancePresets, rt as sectionOwnerStyleChoices, st as mixGroundColour, ut as groundTextureDataUri, yt as boundaryRuntimeMetricsForDecorativeTransition, z as sectionShapeHook } from "./lookMediaFrame-EFws7tAj.mjs";
|
|
6
|
+
import { B as makeBoundaryId, L as asLayoutVariantKey, P as asDesignBlockId, z as asSiteStyleId } from "./schema-DGaihVwp.mjs";
|
|
7
|
+
import { t as assertNever$1 } from "./assert-never-ku-PUn9U.mjs";
|
|
8
|
+
import { h as isRecord$2, t as isObjectRecord } from "./typeGuards-DZOaGTEv.mjs";
|
|
10
9
|
import { i as outlineRegions, n as mapOutlineBlocks } from "./pageRegions-BaeEF2MU.mjs";
|
|
11
10
|
import { i as resolveRouteTargetForStage$1 } from "./dist-Xevqwf1U.mjs";
|
|
12
11
|
import React from "react";
|
|
@@ -495,6 +494,333 @@ function mapDrawingStyle(input) {
|
|
|
495
494
|
};
|
|
496
495
|
}
|
|
497
496
|
//#endregion
|
|
497
|
+
//#region ../theme-core/src/site-styles/runtimeSectionResolution.ts
|
|
498
|
+
/**
|
|
499
|
+
* The one owner of the facts `whenMissing` rules read from block content.
|
|
500
|
+
* Content facts also become `data-has-*` hooks; setting facts never do.
|
|
501
|
+
*/
|
|
502
|
+
function arrangementContentFacts(content) {
|
|
503
|
+
const photoCount = arrangementPhotoCount(content);
|
|
504
|
+
const featured = typeof content.featured === "string" ? content.featured.trim().length > 0 : content.featured !== void 0 && content.featured !== null;
|
|
505
|
+
return {
|
|
506
|
+
photoCount,
|
|
507
|
+
facts: {
|
|
508
|
+
content: {
|
|
509
|
+
photo: photoCount > 0,
|
|
510
|
+
facts: Array.isArray(content.facts) && content.facts.length > 0,
|
|
511
|
+
featured,
|
|
512
|
+
outcome: typeof content.outcome === "string" && content.outcome.length > 0,
|
|
513
|
+
figure: typeof content.figure === "string" && content.figure.trim().length > 0,
|
|
514
|
+
entrance: isRecord$2(content.entrancePhoto)
|
|
515
|
+
},
|
|
516
|
+
settings: { "listed-by-week": content.listBy === "week" }
|
|
517
|
+
}
|
|
518
|
+
};
|
|
519
|
+
}
|
|
520
|
+
/** What an automatic Look choice weighs, read by the same owner as the `whenMissing` facts. */
|
|
521
|
+
function lookFillPartsFromContent(content) {
|
|
522
|
+
return {
|
|
523
|
+
photo: arrangementPhotoCount(content) > 0,
|
|
524
|
+
statement: typeof content.title === "string" && content.title.trim().length > 0
|
|
525
|
+
};
|
|
526
|
+
}
|
|
527
|
+
/** The content stage owns media presence for every arrangement consumer. */
|
|
528
|
+
function arrangementPhotoCount(content) {
|
|
529
|
+
if (Array.isArray(content.cards)) return content.cards.filter((card) => isRecord$2(card) && isRecord$2(card.media)).length;
|
|
530
|
+
if (Array.isArray(content.members)) return content.members.filter((member) => isRecord$2(member) && isRecord$2(member.photo)).length;
|
|
531
|
+
if (Array.isArray(content.images)) return content.images.filter((item) => isRecord$2(item) && isRecord$2(item.image)).length;
|
|
532
|
+
if (isRecord$2(content.media) || isRecord$2(content.entrancePhoto)) return 1;
|
|
533
|
+
return storedSectionPhoto(content) === null ? 0 : 1;
|
|
534
|
+
}
|
|
535
|
+
/** Both rendering and join matching ask the publication-fallback owner. */
|
|
536
|
+
function resolveArrangementContentLook(runtime, mode, content, audience) {
|
|
537
|
+
const selected = runtime.byMode[mode ?? "default"];
|
|
538
|
+
if (!selected) return null;
|
|
539
|
+
const published = resolvePublishedLook({
|
|
540
|
+
look: selected.look,
|
|
541
|
+
facts: arrangementContentFacts(content).facts,
|
|
542
|
+
audience,
|
|
543
|
+
catalogue: runtime.available.map((entry) => entry.look)
|
|
544
|
+
});
|
|
545
|
+
return runtime.available.find((entry) => entry.look.id === published.id) ?? selected;
|
|
546
|
+
}
|
|
547
|
+
function resolveRuntimeSection(rawInput) {
|
|
548
|
+
const input = {
|
|
549
|
+
...rawInput,
|
|
550
|
+
choices: sectionOwnerStyleChoices(rawInput.content)
|
|
551
|
+
};
|
|
552
|
+
const automatic = automaticSectionGround(input);
|
|
553
|
+
const authored = input.placement === "column" ? { kind: "none" } : parseCanonicalRuntimeBackground(input.content);
|
|
554
|
+
const photo = arrangementHeroGround(input);
|
|
555
|
+
const ownerGround = ownerSectionGround(input, authored);
|
|
556
|
+
const background = resolveSectionBackground(ownerGroundSource(authored, namedOwnerGround(input), input, photo), null, input.runtime && input.look ? automatic?.paint ?? null : void 0, photo);
|
|
557
|
+
return sectionDecision(background, resolvedNamedGround(background, ownerGround, automatic, input.runtime), automatic, input, photo);
|
|
558
|
+
}
|
|
559
|
+
function automaticSectionGround(input) {
|
|
560
|
+
if (!input.runtime || !input.look || input.placement === "column") return void 0;
|
|
561
|
+
const span = input.rhythmSpan;
|
|
562
|
+
const index = input.runtime.progression === "deepen" ? span && span.count > 1 ? Math.round(span.position * (input.runtime.rhythm.length - 1) / (span.count - 1)) : 0 : input.position % input.runtime.rhythm.length;
|
|
563
|
+
return input.look.sectionGround ?? input.runtime.rhythm[index];
|
|
564
|
+
}
|
|
565
|
+
/**
|
|
566
|
+
* A stored name is authoritative, including when two grounds share the same paint. `ground: null`
|
|
567
|
+
* records a plain palette colour. Content saved before names existed (`ground` absent) keeps the
|
|
568
|
+
* identity its colour has always given it, so rendering doesn't change before the data migration.
|
|
569
|
+
*/
|
|
570
|
+
function ownerSectionGround(input, source) {
|
|
571
|
+
if (input.choices.ground !== void 0) return namedOwnerGround(input);
|
|
572
|
+
if (input.placement === "column" || source.kind === "none" || source.background.type !== "color" || !input.runtime) return void 0;
|
|
573
|
+
const colour = source.background.color;
|
|
574
|
+
return input.runtime.grounds.find((candidate) => candidate.paint.color === colour);
|
|
575
|
+
}
|
|
576
|
+
function namedOwnerGround(input) {
|
|
577
|
+
if (input.placement === "column") return void 0;
|
|
578
|
+
const choice = input.choices.ground;
|
|
579
|
+
return choice ? input.runtime?.grounds.find((ground) => ground.name === choice.name) : void 0;
|
|
580
|
+
}
|
|
581
|
+
function ownerGroundSource(source, ground, input, photo) {
|
|
582
|
+
const photoBehind = photo?.paintsGround !== false;
|
|
583
|
+
if (source.kind !== "none" && source.background.type === "image" && photoBehind) return source;
|
|
584
|
+
if (ground) return {
|
|
585
|
+
kind: "page-design-override",
|
|
586
|
+
background: namedGroundPaint(ground, authoredInks(source))
|
|
587
|
+
};
|
|
588
|
+
if (input.choices.ground && !hasPaletteFallback(source, input.palette)) return { kind: "none" };
|
|
589
|
+
return paletteColourSource(source, input.runtime);
|
|
590
|
+
}
|
|
591
|
+
/** Owner-set inks replace the ground's inks wholesale, exactly as an unnamed matching colour always has. */
|
|
592
|
+
function namedGroundPaint(ground, inks) {
|
|
593
|
+
return Object.keys(inks).length === 0 ? ground.paint : {
|
|
594
|
+
type: "color",
|
|
595
|
+
color: ground.paint.color,
|
|
596
|
+
...inks
|
|
597
|
+
};
|
|
598
|
+
}
|
|
599
|
+
/** Inks the owner set explicitly survive naming the ground, as they did before names existed. */
|
|
600
|
+
function authoredInks(source) {
|
|
601
|
+
if (source.kind === "none" || source.background.type !== "color") return {};
|
|
602
|
+
const { textColor, headingColor, linkColor, supportingColor } = source.background;
|
|
603
|
+
return {
|
|
604
|
+
...textColor ? { textColor } : {},
|
|
605
|
+
...headingColor ? { headingColor } : {},
|
|
606
|
+
...linkColor ? { linkColor } : {},
|
|
607
|
+
...supportingColor ? { supportingColor } : {}
|
|
608
|
+
};
|
|
609
|
+
}
|
|
610
|
+
function hasPaletteFallback(source, palette) {
|
|
611
|
+
return source.kind !== "none" && source.background.type === "color" && !!source.background.color && !!palette[source.background.color];
|
|
612
|
+
}
|
|
613
|
+
/** Authored palette colours retain the style's established inks; identity comes from `ownerSectionGround`. */
|
|
614
|
+
function paletteColourSource(source, runtime) {
|
|
615
|
+
if (source.kind === "none" || source.background.type !== "color") return source;
|
|
616
|
+
if ([
|
|
617
|
+
source.background.textColor,
|
|
618
|
+
source.background.headingColor,
|
|
619
|
+
source.background.linkColor,
|
|
620
|
+
source.background.supportingColor
|
|
621
|
+
].some((ink) => ink !== void 0)) return source;
|
|
622
|
+
const colour = source.background.color;
|
|
623
|
+
const paint = runtime?.grounds.find((ground) => ground.paint.color === colour)?.paint;
|
|
624
|
+
return paint ? {
|
|
625
|
+
...source,
|
|
626
|
+
background: {
|
|
627
|
+
...paint,
|
|
628
|
+
...source.background
|
|
629
|
+
}
|
|
630
|
+
} : source;
|
|
631
|
+
}
|
|
632
|
+
function arrangementHeroGround(input) {
|
|
633
|
+
return input.blockKind === "block.hero" ? { paintsGround: heroPhotoPaintsGround(input.arrangementKey) } : void 0;
|
|
634
|
+
}
|
|
635
|
+
function resolvedNamedGround(background, owner, automatic, runtime) {
|
|
636
|
+
switch (background.kind) {
|
|
637
|
+
case "base": return runtime?.grounds.find((ground) => ground.name === "base");
|
|
638
|
+
case "rhythm": return automatic;
|
|
639
|
+
case "override":
|
|
640
|
+
case "authored-colour": return background.background.type === "color" ? owner : void 0;
|
|
641
|
+
case "authored-media":
|
|
642
|
+
case "content-media":
|
|
643
|
+
case "look-surface": return;
|
|
644
|
+
}
|
|
645
|
+
}
|
|
646
|
+
function sectionDecision(background, named, automatic, input, photo) {
|
|
647
|
+
const identity = named ? {
|
|
648
|
+
groundName: named.name,
|
|
649
|
+
ground: named.ground
|
|
650
|
+
} : { ground: deriveSectionGround(background, input.palette) };
|
|
651
|
+
const finished = finishedSectionPaint(background, named, input);
|
|
652
|
+
return {
|
|
653
|
+
source: sectionSource(background, named, input.look),
|
|
654
|
+
...identity,
|
|
655
|
+
paint: sectionBackgroundPaint(background),
|
|
656
|
+
paintKind: sectionPaint(background),
|
|
657
|
+
inks: finished?.kind === "certified" ? finished.foreground : resolveSectionForeground(background, input.palette),
|
|
658
|
+
foregroundBackground: finishedForegroundPaint(background, finished, input.palette),
|
|
659
|
+
certifiedBackdrop: finished?.kind === "certified" ? {
|
|
660
|
+
kind: "measured",
|
|
661
|
+
token: finished.finish.paint.base,
|
|
662
|
+
samples: finished.finish.samples
|
|
663
|
+
} : certifiedSectionBackdrop(background, input.palette),
|
|
664
|
+
background,
|
|
665
|
+
...sectionFinishFacts(background, finished),
|
|
666
|
+
shape: input.runtime ? sectionShapeForGround(input.runtime.surfaces, named?.name) : "edge-to-edge",
|
|
667
|
+
surfaceToken: sectionGroundToken(background),
|
|
668
|
+
...sectionEditorFacts(automatic, input),
|
|
669
|
+
openingPhotoBehindText: resolveSectionPhotoPlacement(background, photo) === "behind-text",
|
|
670
|
+
placement: input.placement
|
|
671
|
+
};
|
|
672
|
+
}
|
|
673
|
+
function sectionEditorFacts(automatic, input) {
|
|
674
|
+
return {
|
|
675
|
+
...input.runtime ? { styleGroundName: automatic?.name ?? "base" } : {},
|
|
676
|
+
ownerGroundFallback: input.choices.ground != null && !namedOwnerGround(input)
|
|
677
|
+
};
|
|
678
|
+
}
|
|
679
|
+
function sectionSource(background, named, look) {
|
|
680
|
+
switch (background.kind) {
|
|
681
|
+
case "base": return "base";
|
|
682
|
+
case "rhythm": return look?.sectionGround ? "offer" : "rhythm";
|
|
683
|
+
case "look-surface": return "offer";
|
|
684
|
+
case "authored-media": return "owner-photo";
|
|
685
|
+
case "authored-colour":
|
|
686
|
+
case "content-media":
|
|
687
|
+
case "override": return ownerSectionSource(background.background, named);
|
|
688
|
+
}
|
|
689
|
+
}
|
|
690
|
+
function ownerSectionSource(background, named) {
|
|
691
|
+
if (background.type === "image" || background.type === "video") return "owner-photo";
|
|
692
|
+
return named ? "owner-ground" : "owner-colour";
|
|
693
|
+
}
|
|
694
|
+
function sectionBackgroundPaint(background) {
|
|
695
|
+
switch (background.kind) {
|
|
696
|
+
case "base": return null;
|
|
697
|
+
case "content-media": return background.ground;
|
|
698
|
+
case "authored-colour":
|
|
699
|
+
case "authored-media":
|
|
700
|
+
case "look-surface":
|
|
701
|
+
case "override":
|
|
702
|
+
case "rhythm": return background.background;
|
|
703
|
+
}
|
|
704
|
+
}
|
|
705
|
+
function sectionPaint(resolved) {
|
|
706
|
+
if (resolved.kind === "base" || resolved.kind === "content-media") return "paint";
|
|
707
|
+
const background = resolved.background;
|
|
708
|
+
if (background.type === "color") return "paint";
|
|
709
|
+
return background.type === "image" && background.image != null ? "photo" : "other";
|
|
710
|
+
}
|
|
711
|
+
function sectionGroundToken(resolved) {
|
|
712
|
+
if (resolved.kind === "base") return "background";
|
|
713
|
+
switch (resolved.background.type) {
|
|
714
|
+
case "image":
|
|
715
|
+
case "video": return "media";
|
|
716
|
+
case "color": return resolved.background.color ?? "background";
|
|
717
|
+
case "gradient": return "gradient";
|
|
718
|
+
}
|
|
719
|
+
}
|
|
720
|
+
/** Content media sits beside the text, so its slots sit on the colour ground, as deriveSectionGround reads it. */
|
|
721
|
+
function certifiedSectionBackdrop(resolved, palette) {
|
|
722
|
+
if (resolved.kind === "base") return {
|
|
723
|
+
kind: "measured",
|
|
724
|
+
token: "background"
|
|
725
|
+
};
|
|
726
|
+
const background = resolved.kind === "content-media" ? resolved.ground : resolved.background;
|
|
727
|
+
switch (background.type) {
|
|
728
|
+
case "image":
|
|
729
|
+
case "video": return {
|
|
730
|
+
kind: "unmeasured",
|
|
731
|
+
paint: "media"
|
|
732
|
+
};
|
|
733
|
+
case "gradient": return {
|
|
734
|
+
kind: "unmeasured",
|
|
735
|
+
paint: "gradient"
|
|
736
|
+
};
|
|
737
|
+
case "color": {
|
|
738
|
+
const colour = background.color ?? "background";
|
|
739
|
+
return resolveConcreteColorHex(colour, palette) ? {
|
|
740
|
+
kind: "measured",
|
|
741
|
+
token: colour
|
|
742
|
+
} : {
|
|
743
|
+
kind: "unmeasured",
|
|
744
|
+
paint: "colour"
|
|
745
|
+
};
|
|
746
|
+
}
|
|
747
|
+
}
|
|
748
|
+
}
|
|
749
|
+
function finishedSectionPaint(background, named, input) {
|
|
750
|
+
if (!input.runtime?.finishes || input.placement === "column" || sectionPaint(background) !== "paint") return void 0;
|
|
751
|
+
const choices = input.choices.treatment;
|
|
752
|
+
const paint = resolveSectionTreatment({
|
|
753
|
+
base: sectionGroundToken(background),
|
|
754
|
+
...named?.groundPaint
|
|
755
|
+
}, choices, input.runtime.finishes);
|
|
756
|
+
if (!paint.texture && !paint.tone) return void 0;
|
|
757
|
+
const finish = resolveGroundPaint(paint, input.runtime.finishes, input.palette);
|
|
758
|
+
return finish ? certifyFinishedGround(finish, resolveSectionForeground(background, input.palette), input.runtime.surfaceContext) : {
|
|
759
|
+
kind: "dropped",
|
|
760
|
+
reason: "unmeasurable-finish"
|
|
761
|
+
};
|
|
762
|
+
}
|
|
763
|
+
function sectionFinishFacts(background, finished) {
|
|
764
|
+
if (finished?.kind === "certified") return {
|
|
765
|
+
topPaint: finished.finish.topPaint,
|
|
766
|
+
footPaint: finished.finish.footPaint,
|
|
767
|
+
finishedPaint: finished.finish
|
|
768
|
+
};
|
|
769
|
+
const paint = sectionBackgroundPaint(background);
|
|
770
|
+
const colour = sectionPaint(background) === "paint" ? paint?.type === "color" ? paint.color ?? "background" : "background" : null;
|
|
771
|
+
return {
|
|
772
|
+
topPaint: colour,
|
|
773
|
+
footPaint: colour,
|
|
774
|
+
...finished ? { finishDropped: finished.reason } : {}
|
|
775
|
+
};
|
|
776
|
+
}
|
|
777
|
+
/** Even an automatically inherited base becomes an explicit measurable paint when finished. */
|
|
778
|
+
function finishedForegroundPaint(background, finished, palette) {
|
|
779
|
+
return finished?.kind === "certified" ? {
|
|
780
|
+
type: "color",
|
|
781
|
+
color: finished.finish.paint.base
|
|
782
|
+
} : sectionForegroundBackground(background, palette);
|
|
783
|
+
}
|
|
784
|
+
//#endregion
|
|
785
|
+
//#region ../theme-core/src/site-styles/boundaryLayers.ts
|
|
786
|
+
/** Back paints are palette roles, never another section's inherited texture. Fade repeats its own ground. */
|
|
787
|
+
function boundaryBackPaints(intent, pin, front, previous, palette = {}) {
|
|
788
|
+
const edge = pin ?? transitionCatalogueEntryForIntent(intent).treatment;
|
|
789
|
+
return Array.from({ length: edge.layers - 1 }, (_, index) => {
|
|
790
|
+
if (edge.colourPreset === "fade") return front;
|
|
791
|
+
const blended = edge.colourPreset === "blend" ? blendedGround(front, previous, palette, (edge.layers - index - 1) / edge.layers) : null;
|
|
792
|
+
if (blended) return blended;
|
|
793
|
+
const roles = edge.colourPreset === "accent" ? [
|
|
794
|
+
"accent",
|
|
795
|
+
"primary",
|
|
796
|
+
"secondary",
|
|
797
|
+
"text"
|
|
798
|
+
] : edge.colourPreset === "main" ? [
|
|
799
|
+
"primary",
|
|
800
|
+
"secondary",
|
|
801
|
+
"accent",
|
|
802
|
+
"text"
|
|
803
|
+
] : [
|
|
804
|
+
"secondary",
|
|
805
|
+
"primary",
|
|
806
|
+
"accent",
|
|
807
|
+
"text"
|
|
808
|
+
];
|
|
809
|
+
const shows = roles.filter((role) => visibleRole(role, front, previous, palette));
|
|
810
|
+
return { colour: parseThemeColorToken(shows[index % shows.length] ?? roles[index % roles.length] ?? "primary") ?? front.colour };
|
|
811
|
+
});
|
|
812
|
+
}
|
|
813
|
+
function visibleRole(role, front, previous, palette) {
|
|
814
|
+
const colour = resolveConcreteColorHex(role, palette) ?? role;
|
|
815
|
+
return colour !== (resolveConcreteColorHex(front.colour, palette) ?? front.colour) && colour !== (previous ? resolveConcreteColorHex(previous.colour, palette) ?? previous.colour : "");
|
|
816
|
+
}
|
|
817
|
+
function blendedGround(front, previous, palette, amount) {
|
|
818
|
+
const from = previous ? resolveConcreteColorHex(previous.colour, palette) : null;
|
|
819
|
+
const to = resolveConcreteColorHex(front.colour, palette);
|
|
820
|
+
if (!from || !to || from === to) return null;
|
|
821
|
+
return { colour: hexColorSchema.parse(mixGroundColour(from, to, amount)) };
|
|
822
|
+
}
|
|
823
|
+
//#endregion
|
|
498
824
|
//#region ../theme-core/src/site-styles/sectionBoundaryComposition.ts
|
|
499
825
|
/**
|
|
500
826
|
* Classifies a section from its final render content. `_sectionStyles`
|
|
@@ -504,9 +830,12 @@ function mapDrawingStyle(input) {
|
|
|
504
830
|
* `groundPaint`, the same decision the background layer paints from, given
|
|
505
831
|
* the ground the section declares for when its content sets no colour.
|
|
506
832
|
*/
|
|
507
|
-
function boundaryEndpointForSectionContent(content, ground) {
|
|
508
|
-
const
|
|
509
|
-
const
|
|
833
|
+
function boundaryEndpointForSectionContent(content, ground, side = "top") {
|
|
834
|
+
const decision = sectionDecisionFromContent(content);
|
|
835
|
+
const finished = decidedBoundaryEndpoint(decision, side);
|
|
836
|
+
if (finished) return finished;
|
|
837
|
+
const background = decision?.background ?? parseCanonicalRuntimeBackground(content);
|
|
838
|
+
const paint = groundPaint(background.kind === "none" || background.kind === "base" ? null : background.background, ground.fallback);
|
|
510
839
|
switch (paint.kind) {
|
|
511
840
|
case "fill": {
|
|
512
841
|
const token = parseThemeColorToken(paint.colour);
|
|
@@ -530,7 +859,7 @@ function boundaryEndpointForSectionContent(content, ground) {
|
|
|
530
859
|
kind: "paint",
|
|
531
860
|
token: pageGround.fallback
|
|
532
861
|
};
|
|
533
|
-
default: return assertNever
|
|
862
|
+
default: return assertNever(paint, "Unhandled ground paint");
|
|
534
863
|
}
|
|
535
864
|
}
|
|
536
865
|
/**
|
|
@@ -542,6 +871,14 @@ function boundaryEndpointForSectionContent(content, ground) {
|
|
|
542
871
|
function sectionFactsForContent(content, ground) {
|
|
543
872
|
const photoGround = isLookPhotoGround(content);
|
|
544
873
|
return {
|
|
874
|
+
...sectionDecisionFromContent(content)?.groundName ? { groundName: sectionDecisionFromContent(content)?.groundName } : {},
|
|
875
|
+
...sectionDecisionFromContent(content)?.finishedPaint ? {
|
|
876
|
+
finished: true,
|
|
877
|
+
footEndpoint: photoGround ? {
|
|
878
|
+
kind: "unpainted",
|
|
879
|
+
reason: "media"
|
|
880
|
+
} : boundaryEndpointForSectionContent(content, ground, "foot")
|
|
881
|
+
} : {},
|
|
545
882
|
endpoint: photoGround ? {
|
|
546
883
|
kind: "unpainted",
|
|
547
884
|
reason: "media"
|
|
@@ -594,34 +931,20 @@ function composeBoundary(previous, next, treatment) {
|
|
|
594
931
|
kind: "not-shown",
|
|
595
932
|
reason: frameReason
|
|
596
933
|
};
|
|
597
|
-
const
|
|
934
|
+
const touching = touchingFoot(previous);
|
|
935
|
+
const paintReason = paintNotShownReason(touching, next, treatment);
|
|
598
936
|
if (paintReason) return {
|
|
599
937
|
kind: "not-shown",
|
|
600
938
|
reason: paintReason
|
|
601
939
|
};
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
} : {
|
|
611
|
-
kind: "paint-to-unpainted",
|
|
612
|
-
from: from.token
|
|
613
|
-
}
|
|
614
|
-
};
|
|
615
|
-
return to.kind === "paint" ? {
|
|
616
|
-
kind: "shown",
|
|
617
|
-
composition: {
|
|
618
|
-
kind: "unpainted-to-paint",
|
|
619
|
-
to: to.token
|
|
620
|
-
}
|
|
621
|
-
} : {
|
|
622
|
-
kind: "not-shown",
|
|
623
|
-
reason: "both-unpainted"
|
|
624
|
-
};
|
|
940
|
+
return composeEndpoints(touching.endpoint, next.endpoint);
|
|
941
|
+
}
|
|
942
|
+
/** The previous section as it meets the next: a finished ground's foot, not its top. */
|
|
943
|
+
function touchingFoot(previous) {
|
|
944
|
+
return previous.footEndpoint ? {
|
|
945
|
+
...previous,
|
|
946
|
+
endpoint: previous.footEndpoint
|
|
947
|
+
} : previous;
|
|
625
948
|
}
|
|
626
949
|
/**
|
|
627
950
|
* Decides the seam between two adjacent sections from the same facts that
|
|
@@ -633,173 +956,167 @@ function composeBoundary(previous, next, treatment) {
|
|
|
633
956
|
*/
|
|
634
957
|
function sectionSeam(previous, next) {
|
|
635
958
|
if (previous.facts.shape === "field" && next.facts.shape === "field") return "fields";
|
|
636
|
-
return mergesGround(previous) && mergesGround(next) &&
|
|
959
|
+
return mergesGround(previous) && mergesGround(next) && sameGroundPaint(touchingFoot(previous.facts), next.facts) ? "shared-ground" : "none";
|
|
637
960
|
}
|
|
638
961
|
/** A side can share its ground only when the platform paints it edge to edge, with no flush panel or photo. */
|
|
639
962
|
function mergesGround(side) {
|
|
640
963
|
const { facts } = side;
|
|
641
964
|
return side.section === "platform" && facts.shape !== "field" && facts.frame !== "flush-panel" && !facts.photo;
|
|
642
965
|
}
|
|
643
|
-
function samePaint(previous, next) {
|
|
644
|
-
return previous.kind === "paint" && next.kind === "paint" && previous.token === next.token;
|
|
645
|
-
}
|
|
646
966
|
/** Treatment-specific placement and indistinguishable paint are composition decisions. */
|
|
647
967
|
function paintNotShownReason(previous, next, treatment) {
|
|
648
968
|
if (treatment === "wave-edge-echo" && (!previous.photo || next.endpoint.kind !== "paint")) return "photo-required";
|
|
649
|
-
return previous
|
|
969
|
+
return sameGroundPaint(previous, next) ? "same-paint" : null;
|
|
650
970
|
}
|
|
651
971
|
/**
|
|
652
972
|
* Placement, reserves and paint for a shown boundary, derived from the
|
|
653
973
|
* composition and the catalogue's metrics for the treatment.
|
|
654
974
|
*/
|
|
655
|
-
function boundaryLayout(intent, composition) {
|
|
975
|
+
function boundaryLayout(intent, composition, options = {}) {
|
|
656
976
|
const metrics = boundaryRuntimeMetricsForDecorativeTransition(intent);
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
},
|
|
664
|
-
paint: {
|
|
665
|
-
band: composition.from,
|
|
666
|
-
shape: composition.to
|
|
667
|
-
}
|
|
668
|
-
};
|
|
669
|
-
case "unpainted-to-paint": return {
|
|
670
|
-
placement: "previous",
|
|
671
|
-
reserves: {
|
|
672
|
-
before: metrics.heightCss,
|
|
673
|
-
after: null
|
|
674
|
-
},
|
|
675
|
-
paint: {
|
|
676
|
-
band: null,
|
|
677
|
-
shape: composition.to
|
|
678
|
-
}
|
|
679
|
-
};
|
|
680
|
-
case "paint-to-unpainted": return {
|
|
681
|
-
placement: "next",
|
|
682
|
-
reserves: {
|
|
683
|
-
before: null,
|
|
684
|
-
after: metrics.heightCss
|
|
685
|
-
},
|
|
686
|
-
paint: {
|
|
687
|
-
band: null,
|
|
688
|
-
shape: composition.from
|
|
689
|
-
}
|
|
690
|
-
};
|
|
691
|
-
default: return assertNever$1(composition, "Unhandled boundary composition");
|
|
692
|
-
}
|
|
693
|
-
}
|
|
694
|
-
//#endregion
|
|
695
|
-
//#region ../theme-core/src/site-styles/sectionPhoto.ts
|
|
696
|
-
/** The photo a section keeps, wherever its background `type` points. */
|
|
697
|
-
function storedSectionPhoto(content) {
|
|
698
|
-
return readRecord(readRecord(readRecord(content._sectionStyles)?.background)?.image);
|
|
699
|
-
}
|
|
700
|
-
function readRecord(value) {
|
|
701
|
-
return typeof value === "object" && value !== null && !Array.isArray(value) ? value : null;
|
|
702
|
-
}
|
|
703
|
-
//#endregion
|
|
704
|
-
//#region ../theme-core/src/site-styles/runtimeSectionResolution.ts
|
|
705
|
-
/**
|
|
706
|
-
* The one owner of the facts `whenMissing` rules read from block content.
|
|
707
|
-
* Content facts also become `data-has-*` hooks; setting facts never do.
|
|
708
|
-
*/
|
|
709
|
-
function arrangementContentFacts(content) {
|
|
710
|
-
const photoCount = arrangementPhotoCount(content);
|
|
711
|
-
const featured = typeof content.featured === "string" ? content.featured.trim().length > 0 : content.featured !== void 0 && content.featured !== null;
|
|
977
|
+
const placement = composition.kind === "paint-to-paint" ? "centred" : composition.kind === "unpainted-to-paint" ? "previous" : "next";
|
|
978
|
+
const front = frontGround(composition);
|
|
979
|
+
const underlay = composition.kind === "paint-to-paint" ? {
|
|
980
|
+
colour: composition.from,
|
|
981
|
+
...composition.fromTexture ? { texture: composition.fromTexture } : {}
|
|
982
|
+
} : null;
|
|
712
983
|
return {
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
984
|
+
placement,
|
|
985
|
+
underlay,
|
|
986
|
+
geometry: boundaryGeometryStyle(intent, options.seed ?? "boundary", placement, options.tuning),
|
|
987
|
+
reserves: placement === "centred" ? {
|
|
988
|
+
before: metrics.reserveCss,
|
|
989
|
+
after: metrics.reserveCss
|
|
990
|
+
} : placement === "previous" ? {
|
|
991
|
+
before: metrics.heightCss,
|
|
992
|
+
after: null
|
|
993
|
+
} : {
|
|
994
|
+
before: null,
|
|
995
|
+
after: metrics.heightCss
|
|
996
|
+
},
|
|
997
|
+
paint: {
|
|
998
|
+
front,
|
|
999
|
+
back: boundaryBackPaints(intent, options.edge, front, underlay, options.palette)
|
|
724
1000
|
}
|
|
725
1001
|
};
|
|
726
1002
|
}
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
1003
|
+
function frontGround(composition) {
|
|
1004
|
+
return composition.kind === "paint-to-unpainted" ? {
|
|
1005
|
+
colour: composition.from,
|
|
1006
|
+
...composition.fromTexture ? { texture: composition.fromTexture } : {}
|
|
1007
|
+
} : {
|
|
1008
|
+
colour: composition.to,
|
|
1009
|
+
...composition.toTexture ? { texture: composition.toTexture } : {}
|
|
732
1010
|
};
|
|
733
1011
|
}
|
|
734
|
-
/**
|
|
735
|
-
function
|
|
736
|
-
if (
|
|
737
|
-
|
|
738
|
-
if (
|
|
739
|
-
|
|
740
|
-
|
|
1012
|
+
/** Read the single flat colour the section owner decided for this side. */
|
|
1013
|
+
function decidedBoundaryEndpoint(decision, side) {
|
|
1014
|
+
if (!decision) return null;
|
|
1015
|
+
const paint = side === "top" ? decision.topPaint : decision.footPaint;
|
|
1016
|
+
if (!paint) return null;
|
|
1017
|
+
const token = parseThemeColorToken(paint) ?? (decision.finishedPaint ? hexColorSchema.safeParse(paint).data : void 0);
|
|
1018
|
+
if (!token) return null;
|
|
1019
|
+
const texture = decision.finishedPaint?.texture;
|
|
1020
|
+
return {
|
|
1021
|
+
kind: "paint",
|
|
1022
|
+
token,
|
|
1023
|
+
...texture ? { texture } : {}
|
|
1024
|
+
};
|
|
741
1025
|
}
|
|
742
|
-
/**
|
|
743
|
-
function
|
|
744
|
-
|
|
745
|
-
if (
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
facts: arrangementContentFacts(content).facts,
|
|
749
|
-
audience,
|
|
750
|
-
catalogue: runtime.available.map((entry) => entry.look)
|
|
751
|
-
});
|
|
752
|
-
return runtime.available.find((entry) => entry.look.id === published.id) ?? selected;
|
|
1026
|
+
/** A texture change is a paint change; untouched named grounds retain their established identity rule. */
|
|
1027
|
+
function sameGroundPaint(previous, next) {
|
|
1028
|
+
if (previous.endpoint.kind !== "paint" || next.endpoint.kind !== "paint") return false;
|
|
1029
|
+
if (JSON.stringify(previous.endpoint.texture) !== JSON.stringify(next.endpoint.texture)) return false;
|
|
1030
|
+
if (!previous.finished && !next.finished && previous.groundName !== void 0 && next.groundName !== void 0) return previous.groundName === next.groundName;
|
|
1031
|
+
return previous.endpoint.token === next.endpoint.token;
|
|
753
1032
|
}
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
1033
|
+
function composeEndpoints(from, to) {
|
|
1034
|
+
if (from.kind === "unpainted" && to.kind === "unpainted") return {
|
|
1035
|
+
kind: "not-shown",
|
|
1036
|
+
reason: "both-unpainted"
|
|
1037
|
+
};
|
|
1038
|
+
if (to.kind === "unpainted") return from.kind === "paint" ? {
|
|
1039
|
+
kind: "shown",
|
|
1040
|
+
composition: {
|
|
1041
|
+
kind: "paint-to-unpainted",
|
|
1042
|
+
from: from.token,
|
|
1043
|
+
...from.texture ? { fromTexture: from.texture } : {}
|
|
1044
|
+
}
|
|
1045
|
+
} : {
|
|
1046
|
+
kind: "not-shown",
|
|
1047
|
+
reason: "both-unpainted"
|
|
1048
|
+
};
|
|
1049
|
+
const texture = to.texture ? { toTexture: to.texture } : {};
|
|
759
1050
|
return {
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
1051
|
+
kind: "shown",
|
|
1052
|
+
composition: from.kind === "paint" ? {
|
|
1053
|
+
kind: "paint-to-paint",
|
|
1054
|
+
from: from.token,
|
|
1055
|
+
to: to.token,
|
|
1056
|
+
...from.texture ? { fromTexture: from.texture } : {},
|
|
1057
|
+
...texture
|
|
1058
|
+
} : {
|
|
1059
|
+
kind: "unpainted-to-paint",
|
|
1060
|
+
to: to.token,
|
|
1061
|
+
...texture
|
|
1062
|
+
}
|
|
764
1063
|
};
|
|
765
1064
|
}
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
textColor,
|
|
776
|
-
headingColor,
|
|
777
|
-
linkColor,
|
|
778
|
-
supportingColor
|
|
779
|
-
].some((ink) => ink !== void 0)) return source;
|
|
780
|
-
const style = styleSectionBackgroundForColour(runtime, source.background.color);
|
|
781
|
-
return style ? {
|
|
782
|
-
...source,
|
|
783
|
-
background: {
|
|
784
|
-
...style,
|
|
785
|
-
...source.background
|
|
786
|
-
}
|
|
787
|
-
} : source;
|
|
1065
|
+
//#endregion
|
|
1066
|
+
//#region ../theme-core/src/site-styles/groundPaintCss.ts
|
|
1067
|
+
function groundTextureStyle(texture) {
|
|
1068
|
+
return {
|
|
1069
|
+
"--rb-ground-texture-content": "''",
|
|
1070
|
+
"--rb-ground-texture": `var(--rb-texture-${texture.kind})`,
|
|
1071
|
+
"--rb-ground-texture-opacity": String(texture.strength),
|
|
1072
|
+
"--rb-ground-texture-blend": texture.blend
|
|
1073
|
+
};
|
|
788
1074
|
}
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
1075
|
+
/** Only the section's existing background layer receives these properties. */
|
|
1076
|
+
function finishedGroundStyle(finish) {
|
|
1077
|
+
return {
|
|
1078
|
+
background: finish.background,
|
|
1079
|
+
...finish.texture ? groundTextureStyle(finish.texture) : {}
|
|
1080
|
+
};
|
|
794
1081
|
}
|
|
795
|
-
function
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
1082
|
+
function generateGroundPaintCss(selector) {
|
|
1083
|
+
return `${selector} {\n ${[
|
|
1084
|
+
"paper-grain",
|
|
1085
|
+
"handmade-paper",
|
|
1086
|
+
"plaster"
|
|
1087
|
+
].map((kind) => `--rb-texture-${kind}: ${groundTextureDataUri(kind)};`).join("\n ")}\n}
|
|
1088
|
+
${selector} [data-ground-tone] > :where([data-slot='section'], [data-slot='schedule-section'], [data-slot='shop-section']) {
|
|
1089
|
+
min-height: calc(2 * ${groundFlatZone} + 1px);
|
|
1090
|
+
}
|
|
1091
|
+
${selector} .background-style::before {
|
|
1092
|
+
content: var(--rb-ground-texture-content, none); position: absolute; inset: 0; pointer-events: none;
|
|
1093
|
+
background-image: var(--rb-ground-texture); background-position: 0 0; opacity: var(--rb-ground-texture-opacity);
|
|
1094
|
+
mix-blend-mode: var(--rb-ground-texture-blend);
|
|
1095
|
+
}
|
|
1096
|
+
${selector} [data-section-edge-paint] {
|
|
1097
|
+
position: absolute; inset-inline: 0; z-index: 4; pointer-events: none;
|
|
1098
|
+
mask-image: var(--boundary-section-mask-wide, var(--boundary-texture-mask-wide));
|
|
1099
|
+
-webkit-mask-image: var(--boundary-section-mask-wide, var(--boundary-texture-mask-wide));
|
|
1100
|
+
mask-size: var(--boundary-mask-tile-width, 100%) var(--section-edge-height); -webkit-mask-size: var(--boundary-mask-tile-width, 100%) var(--section-edge-height);
|
|
1101
|
+
mask-repeat: var(--boundary-mask-repeat, no-repeat); -webkit-mask-repeat: var(--boundary-mask-repeat, no-repeat);
|
|
1102
|
+
}
|
|
1103
|
+
${selector} [data-section-edge-paint][data-section-edge-paint='underlay'] {
|
|
1104
|
+
mask-image: linear-gradient(black, black); -webkit-mask-image: linear-gradient(black, black);
|
|
1105
|
+
}
|
|
1106
|
+
${selector} [data-section-edge-paint]::before {
|
|
1107
|
+
content: var(--rb-ground-texture-content, none); position: absolute; inset: 0; pointer-events: none;
|
|
1108
|
+
background-image: var(--rb-ground-texture); background-position: 0 var(--section-texture-y);
|
|
1109
|
+
opacity: var(--rb-ground-texture-opacity); mix-blend-mode: var(--rb-ground-texture-blend);
|
|
1110
|
+
}
|
|
1111
|
+
@supports (color: color-mix(in srgb, black, white)) {
|
|
1112
|
+
${selector} [data-section-edge-fade] {
|
|
1113
|
+
mask-image: var(--boundary-texture-mask-wide); -webkit-mask-image: var(--boundary-texture-mask-wide);
|
|
1114
|
+
}
|
|
1115
|
+
}`;
|
|
1116
|
+
}
|
|
1117
|
+
/** A tone needs space for both flat edge zones and its ramp; texture alone does not. */
|
|
1118
|
+
function groundFinishHooks(finish) {
|
|
1119
|
+
return finish?.paint.tone ? { "data-ground-tone": "true" } : {};
|
|
803
1120
|
}
|
|
804
1121
|
//#endregion
|
|
805
1122
|
//#region ../blocks/src/system/data/selectBlockContent.ts
|
|
@@ -1146,7 +1463,7 @@ function eventItemFacts(props) {
|
|
|
1146
1463
|
time,
|
|
1147
1464
|
price,
|
|
1148
1465
|
link: resolveEventPageLink(props.event),
|
|
1149
|
-
|
|
1466
|
+
metaParts: eventItemMetaParts(props, {
|
|
1150
1467
|
time,
|
|
1151
1468
|
price
|
|
1152
1469
|
}),
|
|
@@ -1161,7 +1478,7 @@ function eventItemFacts(props) {
|
|
|
1161
1478
|
};
|
|
1162
1479
|
}
|
|
1163
1480
|
/** Rows with a rail keep pricing in the details and time in the action rail. */
|
|
1164
|
-
function
|
|
1481
|
+
function eventItemMetaParts(props, formatted) {
|
|
1165
1482
|
const parts = props.parts ?? eventItemParts[props.arrangement];
|
|
1166
1483
|
const venue = props.showVenue !== false ? props.event.venue?.name : null;
|
|
1167
1484
|
const teacher = formatEventTeacherLine(props.event);
|
|
@@ -1176,8 +1493,9 @@ function eventItemMeta(props, formatted) {
|
|
|
1176
1493
|
time,
|
|
1177
1494
|
teacher,
|
|
1178
1495
|
venue
|
|
1179
|
-
]).filter(
|
|
1496
|
+
]).filter((part) => Boolean(part));
|
|
1180
1497
|
}
|
|
1498
|
+
const META_SEPARATOR = " · ";
|
|
1181
1499
|
/**
|
|
1182
1500
|
* Keep one RSC component boundary per item. Re-forwarding shared presentation
|
|
1183
1501
|
* props through layout/part components multiplies React's development debug
|
|
@@ -1311,20 +1629,34 @@ function renderEventItemContentPart({ part, props, facts }) {
|
|
|
1311
1629
|
case "action": return renderEventItemAction(props, facts);
|
|
1312
1630
|
}
|
|
1313
1631
|
}
|
|
1632
|
+
/**
|
|
1633
|
+
* Without the part slots the line is one run of text, as it always was. With them, each part and each
|
|
1634
|
+
* separator is an element, so a skin can put a part on its own line or drop a separator that would dangle.
|
|
1635
|
+
*/
|
|
1314
1636
|
function renderEventItemMeta({ props, facts }) {
|
|
1315
1637
|
const places = (props.parts ?? eventItemParts[props.arrangement]).includes("places") ? null : facts.places;
|
|
1316
|
-
|
|
1638
|
+
const { metaParts } = facts;
|
|
1639
|
+
if (metaParts.length === 0 && !places) return null;
|
|
1640
|
+
const slotted = props.lookSlots?.separator !== void 0;
|
|
1641
|
+
const separator = (key) => slotted ? /* @__PURE__ */ jsx("span", {
|
|
1642
|
+
...listLookSlot(props, "separator"),
|
|
1643
|
+
children: META_SEPARATOR
|
|
1644
|
+
}, key) : META_SEPARATOR;
|
|
1645
|
+
const line = slotted ? metaParts.map((part, index) => /* @__PURE__ */ jsxs(React.Fragment, { children: [index > 0 ? separator(`separator-${index}`) : null, /* @__PURE__ */ jsx("span", {
|
|
1646
|
+
...listLookSlot(props, "meta-part"),
|
|
1647
|
+
children: part
|
|
1648
|
+
})] }, `part-${index}`)) : metaParts.join(META_SEPARATOR);
|
|
1649
|
+
return /* @__PURE__ */ jsxs("p", {
|
|
1317
1650
|
...listLookSlot(props, "item-meta"),
|
|
1318
1651
|
children: [
|
|
1319
1652
|
facts.venueIcon ? /* @__PURE__ */ jsx(MapPinIcon, {}) : null,
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
places ? /* @__PURE__ */ jsx("span", {
|
|
1653
|
+
line,
|
|
1654
|
+
places ? /* @__PURE__ */ jsxs(Fragment, { children: [metaParts.length > 0 ? separator("separator-places") : null, /* @__PURE__ */ jsx("span", {
|
|
1323
1655
|
"data-event-places": true,
|
|
1324
1656
|
children: places
|
|
1325
|
-
}) : null
|
|
1657
|
+
})] }) : null
|
|
1326
1658
|
]
|
|
1327
|
-
})
|
|
1659
|
+
});
|
|
1328
1660
|
}
|
|
1329
1661
|
function renderEventItemImage(props, link) {
|
|
1330
1662
|
return /* @__PURE__ */ jsx(CardListContentPart, {
|
|
@@ -1750,7 +2082,7 @@ function eventCardListContent(event, context, buttonText) {
|
|
|
1750
2082
|
...offeringSchedule(event, context.now),
|
|
1751
2083
|
...event.bookingScope === "whole_series" ? offeringRunDates(event, context.now) : {}
|
|
1752
2084
|
};
|
|
1753
|
-
default: return assertNever(context);
|
|
2085
|
+
default: return assertNever$1(context);
|
|
1754
2086
|
}
|
|
1755
2087
|
}
|
|
1756
2088
|
function cardProjectionBase(event, buttonText, context) {
|
|
@@ -1781,7 +2113,7 @@ function cardBooking(event, buttonText, context) {
|
|
|
1781
2113
|
now: context.now,
|
|
1782
2114
|
count: context.count
|
|
1783
2115
|
});
|
|
1784
|
-
default: return assertNever(context);
|
|
2116
|
+
default: return assertNever$1(context);
|
|
1785
2117
|
}
|
|
1786
2118
|
}
|
|
1787
2119
|
function offeringLeadDate(event, startMs) {
|
|
@@ -2328,10 +2660,12 @@ function DaySchedule({ display }) {
|
|
|
2328
2660
|
}
|
|
2329
2661
|
//#endregion
|
|
2330
2662
|
//#region ../blocks/src/system/runtime/nodes/events/shared/MonthLookView.tsx
|
|
2331
|
-
function MonthEvent({ event, timeZone, locale, presentation }) {
|
|
2663
|
+
function MonthEvent({ event, timeZone, locale, presentation, showCapacity }) {
|
|
2664
|
+
const places = showCapacity ? formatEventRemainingPlaces(event, { full: "Sold out" }) : null;
|
|
2332
2665
|
return /* @__PURE__ */ jsxs("a", {
|
|
2333
2666
|
...resolveEventPageLink(event),
|
|
2334
2667
|
...listLookSlot(presentation, "item"),
|
|
2668
|
+
"data-availability": monthEventAvailability(event),
|
|
2335
2669
|
children: [
|
|
2336
2670
|
/* @__PURE__ */ jsx("span", {
|
|
2337
2671
|
...listLookSlot(presentation, "time"),
|
|
@@ -2347,10 +2681,23 @@ function MonthEvent({ event, timeZone, locale, presentation }) {
|
|
|
2347
2681
|
/* @__PURE__ */ jsx("span", {
|
|
2348
2682
|
...listLookSlot(presentation, "what"),
|
|
2349
2683
|
children: eventDisplayTitleText(event)
|
|
2350
|
-
})
|
|
2684
|
+
}),
|
|
2685
|
+
places ? /* @__PURE__ */ jsxs(Fragment, { children: [" ", /* @__PURE__ */ jsx("span", {
|
|
2686
|
+
...listLookSlot(presentation, "places"),
|
|
2687
|
+
children: places
|
|
2688
|
+
})] }) : null
|
|
2351
2689
|
]
|
|
2352
2690
|
});
|
|
2353
2691
|
}
|
|
2692
|
+
/** The same three states a list row carries, so a skin marks a full session the same way in both. */
|
|
2693
|
+
function monthEventAvailability(event) {
|
|
2694
|
+
const availability = getEventAvailabilityStatus(event);
|
|
2695
|
+
return availability.isFull ? "full" : availability.status === "filling" ? "low" : "available";
|
|
2696
|
+
}
|
|
2697
|
+
/** A day before today, by the calendar's own today, so the server and the client agree. */
|
|
2698
|
+
function isPastDay(day, today) {
|
|
2699
|
+
return formatDateKey(day) < formatDateKey(today);
|
|
2700
|
+
}
|
|
2354
2701
|
function dateLabel(key, timeZone, date = "short") {
|
|
2355
2702
|
return formatDate({
|
|
2356
2703
|
kind: "civil",
|
|
@@ -2371,6 +2718,7 @@ function MonthDay(props) {
|
|
|
2371
2718
|
...listLookSlot(selection, "date"),
|
|
2372
2719
|
"data-current": String(selected),
|
|
2373
2720
|
"data-today": String(day.isToday),
|
|
2721
|
+
"data-past": String(isPastDay(day.date, selection.today)),
|
|
2374
2722
|
"data-other-month": String(!day.isCurrentMonth),
|
|
2375
2723
|
children: [selection.arrangement === "month-day" ? /* @__PURE__ */ jsx("button", {
|
|
2376
2724
|
type: "button",
|
|
@@ -2383,6 +2731,7 @@ function MonthDay(props) {
|
|
|
2383
2731
|
...listLookSlot(selection, "date-label"),
|
|
2384
2732
|
children: day.date.day
|
|
2385
2733
|
}), selection.arrangement === "month-grid" ? /* @__PURE__ */ jsxs(Fragment, { children: [day.visibleEntries.map(({ event, timeZone }, index, entries) => /* @__PURE__ */ jsx(MonthEvent, {
|
|
2734
|
+
showCapacity: selection.showCapacity,
|
|
2386
2735
|
presentation: listItemPresentation(selection, index, entries.length),
|
|
2387
2736
|
event,
|
|
2388
2737
|
timeZone,
|
|
@@ -2567,7 +2916,7 @@ function bookedElsewhereAction(booking) {
|
|
|
2567
2916
|
bookingClosed: label
|
|
2568
2917
|
};
|
|
2569
2918
|
}
|
|
2570
|
-
default: return assertNever(booking);
|
|
2919
|
+
default: return assertNever$1(booking);
|
|
2571
2920
|
}
|
|
2572
2921
|
}
|
|
2573
2922
|
/**
|
|
@@ -2600,7 +2949,7 @@ function bookedElsewhereClosedLabel(closure) {
|
|
|
2600
2949
|
case "run": return closedRunCopy(closure.reason).titleText;
|
|
2601
2950
|
case "datesCutOff":
|
|
2602
2951
|
case "unavailable": return "Registration closed";
|
|
2603
|
-
default: return assertNever(closure);
|
|
2952
|
+
default: return assertNever$1(closure);
|
|
2604
2953
|
}
|
|
2605
2954
|
}
|
|
2606
2955
|
/** A closed run says why here, at the top of the page, so the panel below doesn't repeat it. */
|
|
@@ -2656,8 +3005,10 @@ function EventHeader({ selection, presentation, showCost, showCapacity }) {
|
|
|
2656
3005
|
"aria-label": "At a glance",
|
|
2657
3006
|
children: part("facts")
|
|
2658
3007
|
}),
|
|
2659
|
-
|
|
2660
|
-
|
|
3008
|
+
item.availability || item.action ? /* @__PURE__ */ jsxs("div", {
|
|
3009
|
+
...listLookSlot(presentation, "booking"),
|
|
3010
|
+
children: [part("availability"), part("action")]
|
|
3011
|
+
}) : null
|
|
2661
3012
|
]
|
|
2662
3013
|
}),
|
|
2663
3014
|
part("numeral")
|
|
@@ -2667,7 +3018,8 @@ function EventHeader({ selection, presentation, showCost, showCapacity }) {
|
|
|
2667
3018
|
const eventHeaderSlotParents = {
|
|
2668
3019
|
frame: null,
|
|
2669
3020
|
copy: "frame",
|
|
2670
|
-
|
|
3021
|
+
booking: "copy",
|
|
3022
|
+
availability: "booking",
|
|
2671
3023
|
"item-media": "frame"
|
|
2672
3024
|
};
|
|
2673
3025
|
//#endregion
|
|
@@ -2705,7 +3057,8 @@ function arrangementSlotParents(input) {
|
|
|
2705
3057
|
...derived,
|
|
2706
3058
|
...eventListSlotParents(arrangement, "layout" in derived ? "layout" : null, input.eventRows),
|
|
2707
3059
|
...eventItemSlotParents(arrangement),
|
|
2708
|
-
...arrangement === "month-grid" || arrangement === "month-day" ? monthSlotParents(arrangement) : {}
|
|
3060
|
+
...arrangement === "month-grid" || arrangement === "month-day" ? monthSlotParents(arrangement) : {},
|
|
3061
|
+
...arrangement === "event-header" ? eventHeaderSlotParents : {}
|
|
2709
3062
|
};
|
|
2710
3063
|
if (arrangement === "event-header") return {
|
|
2711
3064
|
...derived,
|
|
@@ -2846,53 +3199,6 @@ function childFields(field) {
|
|
|
2846
3199
|
return [];
|
|
2847
3200
|
}
|
|
2848
3201
|
//#endregion
|
|
2849
|
-
//#region ../blocks/src/system/customize/lookParts.ts
|
|
2850
|
-
const lookParts = {
|
|
2851
|
-
"block.hero": [{
|
|
2852
|
-
part: "more photos",
|
|
2853
|
-
fields: ["morePhotos"],
|
|
2854
|
-
shownIn: ["photo-trio"]
|
|
2855
|
-
}],
|
|
2856
|
-
"block.cta-full": [{
|
|
2857
|
-
part: "figure",
|
|
2858
|
-
fields: ["figure", "figureNote"],
|
|
2859
|
-
shownIn: ["figure"]
|
|
2860
|
-
}],
|
|
2861
|
-
"block.location-map": [{
|
|
2862
|
-
part: "entrance photo",
|
|
2863
|
-
fields: ["entrancePhoto"],
|
|
2864
|
-
shownIn: ["photo-and-details"]
|
|
2865
|
-
}],
|
|
2866
|
-
"block.feature-cards": [{
|
|
2867
|
-
part: "eyebrow",
|
|
2868
|
-
fields: ["eyebrow"],
|
|
2869
|
-
shownIn: [
|
|
2870
|
-
"lead-support",
|
|
2871
|
-
"index",
|
|
2872
|
-
"sequence",
|
|
2873
|
-
"slides",
|
|
2874
|
-
"track"
|
|
2875
|
-
]
|
|
2876
|
-
}],
|
|
2877
|
-
"block.event-details": [{
|
|
2878
|
-
part: "title",
|
|
2879
|
-
fields: ["showTitle"],
|
|
2880
|
-
shownIn: ["details-panel"]
|
|
2881
|
-
}, {
|
|
2882
|
-
part: "description",
|
|
2883
|
-
fields: ["showDescription"],
|
|
2884
|
-
shownIn: ["details-panel"]
|
|
2885
|
-
}]
|
|
2886
|
-
};
|
|
2887
|
-
/** Fields the arrangement leaves out. Nothing on an older style, where no arrangement Look shows the block. */
|
|
2888
|
-
function fieldsNotShownIn(blockKind, arrangement) {
|
|
2889
|
-
if (arrangement === null) return [];
|
|
2890
|
-
return (lookParts[blockKind] ?? []).flatMap((part) => part.shownIn.includes(arrangement) ? [] : part.fields);
|
|
2891
|
-
}
|
|
2892
|
-
function lookPartShown(blockKind, field, arrangement) {
|
|
2893
|
-
return !fieldsNotShownIn(blockKind, arrangement).includes(field);
|
|
2894
|
-
}
|
|
2895
|
-
//#endregion
|
|
2896
3202
|
//#region ../blocks/src/system/transforms/registry/classPrices.ts
|
|
2897
3203
|
const classPriceItemsTransform = {
|
|
2898
3204
|
id: "events.classPriceItems",
|
|
@@ -2976,7 +3282,8 @@ const backgroundTransforms = [
|
|
|
2976
3282
|
summary: "Resolve inline styles for background color/gradient layers",
|
|
2977
3283
|
run: (value, options, context) => {
|
|
2978
3284
|
const fallbackToken = options?.fallbackToken;
|
|
2979
|
-
|
|
3285
|
+
const finish = asPartialObject(options)?.sectionGround ? sectionDecisionFromContent(context.data)?.finishedPaint : void 0;
|
|
3286
|
+
return finish ? finishedGroundStyle(finish) : resolveBackgroundLayerStyle(value, fallbackToken, context);
|
|
2980
3287
|
}
|
|
2981
3288
|
},
|
|
2982
3289
|
{
|
|
@@ -3312,7 +3619,7 @@ function formatAppointmentLocation(location) {
|
|
|
3312
3619
|
const venue = formatVenue(location.venue);
|
|
3313
3620
|
return venue ? `${venue} or online` : "In person or online";
|
|
3314
3621
|
}
|
|
3315
|
-
default: return assertNever(location);
|
|
3622
|
+
default: return assertNever$1(location);
|
|
3316
3623
|
}
|
|
3317
3624
|
}
|
|
3318
3625
|
function formatVenue(venue) {
|
|
@@ -3358,7 +3665,7 @@ function appointmentPricingDisplay(pricing) {
|
|
|
3358
3665
|
maxAmount: pricing.slidingMaxAmount,
|
|
3359
3666
|
currency: pricing.currency
|
|
3360
3667
|
};
|
|
3361
|
-
default: return assertNever(pricing.pricingStrategy);
|
|
3668
|
+
default: return assertNever$1(pricing.pricingStrategy);
|
|
3362
3669
|
}
|
|
3363
3670
|
}
|
|
3364
3671
|
//#endregion
|
|
@@ -3414,7 +3721,7 @@ function serviceDetailsFacts(service) {
|
|
|
3414
3721
|
value: location
|
|
3415
3722
|
}] : [],
|
|
3416
3723
|
{
|
|
3417
|
-
label: "
|
|
3724
|
+
label: "Cancellation policy",
|
|
3418
3725
|
value: describePublicRefundPolicy(service.cancellationPolicy.refunds)
|
|
3419
3726
|
},
|
|
3420
3727
|
...practitioners.length ? [{
|
|
@@ -3756,7 +4063,7 @@ function resolveLinkedContentEditSupport(contentType) {
|
|
|
3756
4063
|
kind: "unsupported-domain-backed",
|
|
3757
4064
|
reason: metadata.reason
|
|
3758
4065
|
};
|
|
3759
|
-
default: return assertNever(metadata);
|
|
4066
|
+
default: return assertNever$1(metadata);
|
|
3760
4067
|
}
|
|
3761
4068
|
}
|
|
3762
4069
|
function contentTypeKeyToLabel(key) {
|
|
@@ -3884,8 +4191,9 @@ function transformSdkBlockToManifest(sdkBlock) {
|
|
|
3884
4191
|
variants: sdkBlock.variants,
|
|
3885
4192
|
defaultVariant: sdkBlock.defaultVariant,
|
|
3886
4193
|
variantOptions: sdkBlock.variantOptions,
|
|
3887
|
-
|
|
4194
|
+
...sdkBlock.editing && placedEditingPaths(sdkBlock.editing).includes("_sectionStyles.background.image") ? { sectionPhoto: { path: sectionPhotoPath } } : {},
|
|
3888
4195
|
lookField: sdkBlock.lookField,
|
|
4196
|
+
editing: sdkBlock.editing,
|
|
3889
4197
|
behaviours: {
|
|
3890
4198
|
supportsThemeSwitching: true,
|
|
3891
4199
|
inlineEditing: hasLayout,
|
|
@@ -3935,27 +4243,35 @@ function toResolvedCustomBlock(manifest, source) {
|
|
|
3935
4243
|
function planCustomBlockRegistryResolution({ sdkConfig, customBlocks = [], policy = defaultCustomBlockSourcePolicy }) {
|
|
3936
4244
|
switch (policy.kind) {
|
|
3937
4245
|
case "canonical-db-fallback-sdk": {
|
|
3938
|
-
const
|
|
3939
|
-
|
|
3940
|
-
|
|
3941
|
-
|
|
3942
|
-
|
|
3943
|
-
|
|
3944
|
-
|
|
4246
|
+
const initial = {
|
|
4247
|
+
entriesByKind: new Map(customBlocks.map((entry) => [entry.manifest ? entry.manifest.id : entry.blockKind, entry])),
|
|
4248
|
+
conflicts: []
|
|
4249
|
+
};
|
|
4250
|
+
const resolution = (sdkConfig?.customBlocks ?? []).reduce((current, sdkBlock) => {
|
|
4251
|
+
const existing = current.entriesByKind.get(sdkBlock.id);
|
|
4252
|
+
if (existing) return {
|
|
4253
|
+
...current,
|
|
4254
|
+
conflicts: [...current.conflicts, {
|
|
3945
4255
|
kind: "conflict",
|
|
3946
|
-
blockKind:
|
|
4256
|
+
blockKind: sdkBlock.id,
|
|
3947
4257
|
winner: existing.source,
|
|
3948
4258
|
loser: { kind: "sdk-config" },
|
|
3949
4259
|
reason: "db-canonical-sdk-fallback"
|
|
3950
|
-
}
|
|
3951
|
-
|
|
3952
|
-
|
|
3953
|
-
|
|
3954
|
-
|
|
4260
|
+
}]
|
|
4261
|
+
};
|
|
4262
|
+
const entry = {
|
|
4263
|
+
manifest: sdkBlock,
|
|
4264
|
+
source: { kind: "sdk-config" }
|
|
4265
|
+
};
|
|
4266
|
+
return {
|
|
4267
|
+
...current,
|
|
4268
|
+
entriesByKind: new Map([...current.entriesByKind, [sdkBlock.id, entry]])
|
|
4269
|
+
};
|
|
4270
|
+
}, initial);
|
|
3955
4271
|
return {
|
|
3956
4272
|
policy,
|
|
3957
|
-
entries:
|
|
3958
|
-
conflicts
|
|
4273
|
+
entries: [...resolution.entriesByKind.values()].flatMap((entry) => entry.manifest ? [toResolvedCustomBlock(entry.manifest, entry.source)] : []),
|
|
4274
|
+
conflicts: [...resolution.conflicts]
|
|
3959
4275
|
};
|
|
3960
4276
|
}
|
|
3961
4277
|
}
|
|
@@ -3967,7 +4283,7 @@ function createCustomBlockRegistry({ sdkConfig, customBlocks = [], policy = defa
|
|
|
3967
4283
|
policy
|
|
3968
4284
|
});
|
|
3969
4285
|
const entriesByKind = new Map(plan.entries.map((entry) => [entry.blockKind, entry]));
|
|
3970
|
-
for (const conflict of plan.conflicts) onConflict?.(`
|
|
4286
|
+
for (const conflict of plan.conflicts) onConflict?.(`Canonical ${sourceLabel(conflict.winner)} definition for "${conflict.blockKind}" takes precedence; ${sourceLabel(conflict.loser)} fallback ignored`);
|
|
3971
4287
|
return {
|
|
3972
4288
|
entries: plan.entries,
|
|
3973
4289
|
conflicts: plan.conflicts,
|
|
@@ -3982,7 +4298,7 @@ function sourceLabel(source) {
|
|
|
3982
4298
|
case "managed-database": return "DB";
|
|
3983
4299
|
case "sdk-synced": return "SDK-synced DB";
|
|
3984
4300
|
case "sdk-config": return "SDK config";
|
|
3985
|
-
default: return assertNever(source);
|
|
4301
|
+
default: return assertNever$1(source);
|
|
3986
4302
|
}
|
|
3987
4303
|
}
|
|
3988
4304
|
//#endregion
|
|
@@ -4029,9 +4345,9 @@ function joinAcrossRun(byPair, previousBlockId, nextBlockId, run) {
|
|
|
4029
4345
|
const exiting = lastOmittedId ? byPair.get(pairKey(lastOmittedId, nextBlockId)) : void 0;
|
|
4030
4346
|
const donor = entering ?? exiting;
|
|
4031
4347
|
return donor ? {
|
|
4348
|
+
...donor,
|
|
4032
4349
|
previousBlockId,
|
|
4033
|
-
nextBlockId
|
|
4034
|
-
treatment: donor.treatment
|
|
4350
|
+
nextBlockId
|
|
4035
4351
|
} : void 0;
|
|
4036
4352
|
}
|
|
4037
4353
|
/**
|
|
@@ -4055,24 +4371,39 @@ function composePageJoins(input) {
|
|
|
4055
4371
|
return [{
|
|
4056
4372
|
previousBlockId: previous.id,
|
|
4057
4373
|
nextBlockId: next.id,
|
|
4058
|
-
join: join ? composeJoin(join, before.facts, after.facts) : null,
|
|
4374
|
+
join: join ? composeJoin(join, before.facts, after.facts, input.context) : null,
|
|
4059
4375
|
seam: sectionSeam(before, after)
|
|
4060
4376
|
}];
|
|
4061
4377
|
});
|
|
4062
4378
|
}
|
|
4063
|
-
function composeJoin(join, previous, next) {
|
|
4064
|
-
|
|
4065
|
-
|
|
4379
|
+
function composeJoin(join, previous, next, context) {
|
|
4380
|
+
const boundaryId = pairKey(join.previousBlockId, join.nextBlockId);
|
|
4381
|
+
const outcome = composeBoundary(previous, next, join.treatment);
|
|
4382
|
+
const family = transitionCatalogueEntryForIntent(join.treatment).family;
|
|
4383
|
+
const tuning = context?.siteStyleId ? siteStyleEdges(asSiteStyleId(context.siteStyleId)).supported.find((support) => support.family === family)?.tuning : void 0;
|
|
4384
|
+
const identity = {
|
|
4385
|
+
boundaryId,
|
|
4066
4386
|
previousBlockId: join.previousBlockId,
|
|
4067
4387
|
nextBlockId: join.nextBlockId,
|
|
4068
|
-
treatment: join.treatment
|
|
4069
|
-
|
|
4388
|
+
treatment: join.treatment
|
|
4389
|
+
};
|
|
4390
|
+
return outcome.kind === "shown" ? {
|
|
4391
|
+
...identity,
|
|
4392
|
+
outcome,
|
|
4393
|
+
layout: boundaryLayout(join.treatment, outcome.composition, {
|
|
4394
|
+
edge: join.edge,
|
|
4395
|
+
palette: context?.palette,
|
|
4396
|
+
tuning,
|
|
4397
|
+
seed: boundaryId
|
|
4398
|
+
})
|
|
4399
|
+
} : {
|
|
4400
|
+
...identity,
|
|
4401
|
+
outcome
|
|
4070
4402
|
};
|
|
4071
4403
|
}
|
|
4072
4404
|
/** Placement, reserves and paint for a join that draws; null otherwise. */
|
|
4073
4405
|
function renderedJoinLayout(join) {
|
|
4074
|
-
|
|
4075
|
-
return boundaryLayout(join.treatment, join.outcome.composition);
|
|
4406
|
+
return join?.layout ?? null;
|
|
4076
4407
|
}
|
|
4077
4408
|
/** Joins with a missing id on either side cannot sit between two blocks. */
|
|
4078
4409
|
function joinsByPair(joins) {
|
|
@@ -4128,14 +4459,14 @@ function planPageRender(input, previous = null) {
|
|
|
4128
4459
|
return [entry, {
|
|
4129
4460
|
position,
|
|
4130
4461
|
placement,
|
|
4131
|
-
entry: cached?.position === position && cached.placement === placement ? cached.entry : applyArrangementRhythm(entry, position, placement)
|
|
4462
|
+
entry: cached?.position === position && cached.placement === placement ? cached.entry : applyArrangementRhythm(entry, position, placement, input.palette)
|
|
4132
4463
|
}];
|
|
4133
4464
|
});
|
|
4134
4465
|
return {
|
|
4135
4466
|
region,
|
|
4136
4467
|
planned,
|
|
4137
4468
|
rhythmic,
|
|
4138
|
-
entries: rhythmic
|
|
4469
|
+
entries: deepenArrangementRhythm(rhythmic, placement, input.palette).filter(shown)
|
|
4139
4470
|
};
|
|
4140
4471
|
});
|
|
4141
4472
|
const regions = {
|
|
@@ -4162,7 +4493,7 @@ function planPageRender(input, previous = null) {
|
|
|
4162
4493
|
};
|
|
4163
4494
|
}
|
|
4164
4495
|
function samePlanSettings(previous, current) {
|
|
4165
|
-
return previous.siteStyleId === current.siteStyleId && previous.audience === current.audience && previous.previewStage === current.previewStage && previous.sdkConfig === current.sdkConfig && previous.customBlocks === current.customBlocks && previous.blockOverrides === current.blockOverrides;
|
|
4496
|
+
return previous.siteStyleId === current.siteStyleId && previous.palette === current.palette && previous.audience === current.audience && previous.previewStage === current.previewStage && previous.sdkConfig === current.sdkConfig && previous.customBlocks === current.customBlocks && previous.blockOverrides === current.blockOverrides;
|
|
4166
4497
|
}
|
|
4167
4498
|
/**
|
|
4168
4499
|
* Mirrors the order of the checks `MemoBlockSection` used to make inline, so no
|
|
@@ -4314,11 +4645,8 @@ function restoreCompiledLook(look) {
|
|
|
4314
4645
|
};
|
|
4315
4646
|
}
|
|
4316
4647
|
function restoreArrangementRuntime(runtime) {
|
|
4317
|
-
const transported = runtime;
|
|
4318
|
-
const fieldGrounds = Array.isArray(transported.fieldGrounds) ? transported.fieldGrounds.filter((token) => typeof token === "string") : [];
|
|
4319
4648
|
return {
|
|
4320
4649
|
...runtime,
|
|
4321
|
-
fieldGrounds,
|
|
4322
4650
|
available: runtime.available.map(restoreCompiledLook),
|
|
4323
4651
|
byMode: Object.fromEntries(Object.entries(runtime.byMode).map(([mode, look]) => [mode, restoreCompiledLook(look)]))
|
|
4324
4652
|
};
|
|
@@ -4329,7 +4657,27 @@ function effectiveLookFromContent(content) {
|
|
|
4329
4657
|
return isObjectRecord(value) && isObjectRecord(value.look) ? restoreCompiledLook(value) : null;
|
|
4330
4658
|
}
|
|
4331
4659
|
function planArrangementContent(blockKind, manifest, authored, audience) {
|
|
4332
|
-
|
|
4660
|
+
const content = withoutSectionDecision(planArrangementBlockContent(blockKind, manifest, authored, audience).renderableContent);
|
|
4661
|
+
const runtime = arrangementRuntime(content);
|
|
4662
|
+
const look = effectiveLookFromContent(content);
|
|
4663
|
+
if (!runtime || !look) return content;
|
|
4664
|
+
const section = resolveRuntimeSection({
|
|
4665
|
+
content,
|
|
4666
|
+
runtime,
|
|
4667
|
+
look,
|
|
4668
|
+
blockKind,
|
|
4669
|
+
arrangementKey: look.look.structure.byMode[readStoredMode({
|
|
4670
|
+
...arrangementManifestFromVariants(manifest),
|
|
4671
|
+
variantMeaning: manifest.variantMeaning
|
|
4672
|
+
}, content) ?? "default"],
|
|
4673
|
+
position: 0,
|
|
4674
|
+
placement: "page-wide",
|
|
4675
|
+
palette: runtime.surfaceContext.palette
|
|
4676
|
+
});
|
|
4677
|
+
return {
|
|
4678
|
+
...content,
|
|
4679
|
+
_sectionDecision: section
|
|
4680
|
+
};
|
|
4333
4681
|
}
|
|
4334
4682
|
function planArrangementBlockContent(blockKind, manifest, authored, audience) {
|
|
4335
4683
|
const runtime = arrangementRuntime(authored);
|
|
@@ -4453,7 +4801,7 @@ function arrangementQuoteContent(blockKind, effective, values) {
|
|
|
4453
4801
|
function arrangementPanelContent(content, effective, mode) {
|
|
4454
4802
|
if (mode === "calendar") return {
|
|
4455
4803
|
_lookMonthArrangement: effective.look.structure.byMode.calendar,
|
|
4456
|
-
defaultCalendarView:
|
|
4804
|
+
defaultCalendarView: eventCalendarLookViews.defaultCalendarView
|
|
4457
4805
|
};
|
|
4458
4806
|
const arrangement = effective.look.structure.byMode[mode ?? "default"];
|
|
4459
4807
|
if (arrangement === "event-header") return { heading: void 0 };
|
|
@@ -4497,47 +4845,73 @@ function arrangementContentHooks(effective, mode, length, facts, values, photoCo
|
|
|
4497
4845
|
...Object.fromEntries(Object.entries(values).map(([key, value]) => [`data-knob-${key === "titleSize" ? "headline" : key.replace(/[A-Z]/g, (letter) => `-${letter.toLowerCase()}`)}`, value]))
|
|
4498
4846
|
};
|
|
4499
4847
|
}
|
|
4500
|
-
|
|
4848
|
+
/** Read participation from the section owner; the planner supplies composition, never grounds. */
|
|
4849
|
+
function deepenArrangementRhythm(rhythmic, placement, palette) {
|
|
4850
|
+
const driven = rhythmic.filter(([, value]) => value.entry.sectionDecision?.source === "rhythm").map(([entry]) => entry);
|
|
4851
|
+
return rhythmic.map(([original, value]) => {
|
|
4852
|
+
if (arrangementRuntime(original.renderableContent)?.progression !== "deepen") return value.entry;
|
|
4853
|
+
const position = driven.indexOf(original);
|
|
4854
|
+
return position < 0 ? value.entry : applyArrangementRhythm(original, value.position, placement, palette, {
|
|
4855
|
+
position,
|
|
4856
|
+
count: driven.length
|
|
4857
|
+
});
|
|
4858
|
+
});
|
|
4859
|
+
}
|
|
4860
|
+
function applyArrangementRhythm(entry, position, placement, palette = {}, rhythmSpan) {
|
|
4501
4861
|
const runtime = arrangementRuntime(entry.renderableContent);
|
|
4502
4862
|
const look = effectiveLookFromContent(entry.renderableContent);
|
|
4503
|
-
|
|
4504
|
-
const content = entry.renderableContent;
|
|
4863
|
+
const content = withoutSectionDecision(entry.renderableContent);
|
|
4505
4864
|
const section = resolveRuntimeSection({
|
|
4506
4865
|
content,
|
|
4507
4866
|
runtime,
|
|
4508
4867
|
look,
|
|
4509
4868
|
position,
|
|
4510
4869
|
placement,
|
|
4870
|
+
rhythmSpan,
|
|
4511
4871
|
blockKind: entry.block.kind,
|
|
4512
4872
|
arrangementKey: entry.kind === "renderable" ? entry.effectiveArrangementKey ?? void 0 : void 0,
|
|
4513
|
-
palette: runtime
|
|
4873
|
+
palette: runtime?.surfaceContext.palette ?? palette
|
|
4514
4874
|
});
|
|
4515
4875
|
const resolved = section.background;
|
|
4516
4876
|
const updated = applyResolvedArrangementBackground(content, resolved);
|
|
4517
|
-
|
|
4877
|
+
if (!runtime || !look) return {
|
|
4878
|
+
...entry,
|
|
4879
|
+
renderableContent: content,
|
|
4880
|
+
sectionDecision: {
|
|
4881
|
+
...section,
|
|
4882
|
+
lookId: null
|
|
4883
|
+
}
|
|
4884
|
+
};
|
|
4885
|
+
const surface = section.surfaceToken;
|
|
4518
4886
|
const grounded = resolveArrangementSurfaces(entry, look, runtime, section, updated);
|
|
4519
|
-
const shape = sectionShapeHook(
|
|
4887
|
+
const shape = sectionShapeHook(section.shape);
|
|
4520
4888
|
const combined = resolveCombinedLook(entry, grounded, runtime, section, updated);
|
|
4521
4889
|
return {
|
|
4522
4890
|
...entry,
|
|
4523
4891
|
sectionDecision: {
|
|
4524
|
-
|
|
4525
|
-
|
|
4526
|
-
paint: section.paint
|
|
4892
|
+
...section,
|
|
4893
|
+
lookId: look.look.id
|
|
4527
4894
|
},
|
|
4528
|
-
styleBackground: section.styleBackground,
|
|
4529
4895
|
renderableContent: {
|
|
4530
4896
|
...updated,
|
|
4897
|
+
_sectionDecision: section,
|
|
4531
4898
|
...combined ? { _combinedLook: combined } : {},
|
|
4532
4899
|
_effectiveLook: grounded,
|
|
4533
4900
|
_lookHooks: {
|
|
4534
4901
|
...isObjectRecord(updated._lookHooks) ? updated._lookHooks : {},
|
|
4535
4902
|
"data-surface": surface,
|
|
4536
|
-
...shape
|
|
4903
|
+
...shape,
|
|
4904
|
+
...groundFinishHooks(section.finishedPaint)
|
|
4537
4905
|
}
|
|
4538
4906
|
}
|
|
4539
4907
|
};
|
|
4540
4908
|
}
|
|
4909
|
+
/** Only the planner mints `_sectionDecision`; one arriving with content (an import, an SDK payload, an earlier plan) is dropped. */
|
|
4910
|
+
function withoutSectionDecision(content) {
|
|
4911
|
+
if (!("_sectionDecision" in content)) return content;
|
|
4912
|
+
const { _sectionDecision: _stale, ...rest } = content;
|
|
4913
|
+
return rest;
|
|
4914
|
+
}
|
|
4541
4915
|
function applyResolvedArrangementBackground(content, resolved) {
|
|
4542
4916
|
const section = isObjectRecord(content._sectionStyles) ? content._sectionStyles : {};
|
|
4543
4917
|
const photo = isObjectRecord(section.background) ? section.background.image : void 0;
|
|
@@ -4597,11 +4971,13 @@ function resolveArrangementSurfaces(entry, look, runtime, section, content) {
|
|
|
4597
4971
|
surfaces: runtime.surfaces,
|
|
4598
4972
|
context: runtime.surfaceContext
|
|
4599
4973
|
};
|
|
4974
|
+
const parents = plannedSlotParents(entry, look);
|
|
4975
|
+
const base = section.certifiedBackdrop;
|
|
4600
4976
|
const surfacePresentation = resolveLookSurfacePresentation({
|
|
4601
4977
|
look,
|
|
4602
|
-
parents
|
|
4978
|
+
parents,
|
|
4603
4979
|
ground,
|
|
4604
|
-
base
|
|
4980
|
+
base,
|
|
4605
4981
|
style,
|
|
4606
4982
|
content
|
|
4607
4983
|
});
|
|
@@ -4624,7 +5000,7 @@ function resolveCombinedLook(entry, list, runtime, section, content) {
|
|
|
4624
5000
|
look: month,
|
|
4625
5001
|
parents: arrangementSlotParentsForManifest(entry.kind === "renderable" ? entry.definition.manifest : void 0, month.look.target, arrangement),
|
|
4626
5002
|
ground,
|
|
4627
|
-
base:
|
|
5003
|
+
base: section.certifiedBackdrop,
|
|
4628
5004
|
content,
|
|
4629
5005
|
style: {
|
|
4630
5006
|
roleMap: month.roleMap,
|
|
@@ -4667,4 +5043,4 @@ function plannedSlotParents(entry, look) {
|
|
|
4667
5043
|
return arrangementSlotParentsForManifest(entry.definition.manifest, look.look.target, arrangement, look.look.structure.eventRows);
|
|
4668
5044
|
}
|
|
4669
5045
|
//#endregion
|
|
4670
|
-
export {
|
|
5046
|
+
export { parseStoredVariant as $, eventCardListContent as A, eventCategoryBadge as B, resolvePageRouteTarget as C, MonthLookView as D, EVENT_REGISTRATION_ANCHOR_ID as E, createPresentationPageReader as F, formatCourseDatesAfter as G, MapPinIcon as H, EmptyState as I, resolveMonthSelectedDay as J, formatCourseSessions as K, CardListCollection as L, deriveEventScheduleSummary as M, derivePreviewRunSchedule as N, EventListingFrameView as O, createEditorPresentationPageReader as P, formatEventDuration as Q, CardListItems as R, resolveEntryRouteTarget as S, EventHeader as T, eventDisplayTitle as U, CalendarIcon as V, eventDisplayTitleText as W, selectQuickDateEvents as X, formatEventQuickDate as Y, formatEventTeacherLine as Z, publicAppointmentLocationSchema as _, joinSlotKey as a, buildThemeTokens as at, describePublicRefundPolicy as b, createCustomBlockRegistry as c, resolveLinkedEntryInlineFieldEligibility as d, selectBlockContent as et, builtinTransformDefinitions as f, formatAppointmentPrice as g, formatAppointmentLocation as h, composePageJoins as i, lookFillPartsFromContent as it, offeringDatesBySeries as j, OfferingCourseCards as k, buildLinkedContentEditTarget as l, formatAppointmentDuration as m, createPageRenderPlanReader as n, groundTextureStyle as nt, renderedJoinLayout as o, defaultThemeTokens as ot, defaultTransforms as p, buildMonthDay as q, planArrangementContent as r, arrangementContentFacts as rt, retargetJoinsAcrossOmissions as s, buildPageRenderPlan as t, generateGroundPaintCss as tt, coerceLinkedContentEntriesPayload as u, publicAppointmentPricingSchema as v, resolveRouteTarget as w, resolveAuthoredLinkHref as x, PUBLIC_FREE_CANCELLATION as y, EventItem as z };
|