@riverbankcms/sdk 0.74.0 → 0.75.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{PreviewEditorSidebar-5XL7M3OM.mjs → PreviewEditorSidebar-U2IHCBYN.mjs} +3 -3
- package/dist/{PreviewEditorUI-ZDFRDJID.mjs → PreviewEditorUI-ZGH2RQNP.mjs} +3 -3
- package/dist/SdkPreviewModeRuntime-MTUGBTLQ.mjs +8 -0
- package/dist/_dts/api/src/cache-tags.d.ts +22 -0
- package/dist/_dts/api/src/contentRuntime.d.ts +1 -0
- package/dist/_dts/api/src/endpoints.d.ts +24 -24
- package/dist/_dts/api/src/publicExperienceEndpoints.d.ts +2 -1
- package/dist/_dts/block-form/src/blockDraftSaveability.d.ts +4 -1
- package/dist/_dts/blocks/src/client/booking-form.d.ts +2 -0
- package/dist/_dts/blocks/src/client/carousel.d.ts +1 -0
- package/dist/_dts/blocks/src/client/course-registration.d.ts +2 -0
- package/dist/_dts/blocks/src/client/events.d.ts +4 -0
- package/dist/_dts/blocks/src/client/form.d.ts +2 -0
- package/dist/_dts/blocks/src/client/header.d.ts +1 -0
- package/dist/_dts/blocks/src/client/location-map.d.ts +1 -0
- package/dist/_dts/blocks/src/client/newsletter-form.d.ts +2 -0
- package/dist/_dts/blocks/src/client/shop.d.ts +6 -0
- package/dist/_dts/blocks/src/lib/video.d.ts +2 -0
- package/dist/_dts/blocks/src/system/manifest/fieldValidation/index.d.ts +21 -1
- package/dist/_dts/blocks/src/system/runtime/components/registry.client.d.ts +1 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/booking-form.headless.state.d.ts +3 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/events/index.d.ts +3 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/header-section.client.d.ts +1 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/header-section.server.d.ts +1 -0
- package/dist/_dts/content-editor/src/hooks/validateBlocksForPublish.d.ts +5 -0
- package/dist/_dts/preview-next/src/client/preview/SiteChromeEditableSurface.d.ts +12 -2
- package/dist/_dts/sdk/src/public-api/contracts.d.ts +1 -0
- package/dist/_dts/sdk/src/rendering/islands/deferredVideoEmbeds.d.ts +2 -0
- package/dist/_dts/sdk/src/rendering/server.d.ts +3 -0
- package/dist/_dts/sdk/src/version.d.ts +1 -1
- package/dist/_dts/theme-core/src/generated/containerResponsiveThemeCss.d.ts +1 -1
- package/dist/{chunk-YY7K3QD2.mjs → chunk-BGMNDF6T.mjs} +7 -7
- package/dist/{chunk-2MIWNFJM.mjs → chunk-GFE74WRD.mjs} +309 -84
- package/dist/{chunk-CEQBBLMJ.mjs → chunk-RWXQBRQZ.mjs} +1 -1
- package/dist/{chunk-7RX72SK2.mjs → chunk-VX7B5VAC.mjs} +36 -25
- package/dist/{chunk-YRJKZEQ3.mjs → chunk-Z7JLNTJR.mjs} +1 -1
- package/dist/{chunk-CBD47MTM.mjs → chunk-ZSHFGFUG.mjs} +2 -2
- package/dist/cli/index.mjs +3395 -3753
- package/dist/client/{accordion-ZZVXWV3N.mjs → accordion-T2UD2ZTH.mjs} +1 -1
- package/dist/client/bookingForm-GUP75FKN.mjs +3022 -0
- package/dist/client/bookings.mjs +19 -10
- package/dist/client/{carousel-25WK2H7G.mjs → carousel-2NQA6V57.mjs} +3 -2
- package/dist/client/cart-5TFIAFDS.mjs +18 -0
- package/dist/client/checkout-TP4WAHZE.mjs +18 -0
- package/dist/client/chunk-2PHQZ666.mjs +383 -0
- package/dist/client/chunk-3DCJ45Z2.mjs +36 -0
- package/dist/client/chunk-3PEDD5KJ.mjs +146 -0
- package/dist/client/chunk-CY2ZTSE5.mjs +204 -0
- package/dist/client/chunk-F7LHOKEH.mjs +146 -0
- package/dist/client/{chunk-6VGXRE34.mjs → chunk-FU2QRZMX.mjs} +6 -6
- package/dist/client/chunk-I2MMZO53.mjs +6 -0
- package/dist/client/chunk-II7O4XN3.mjs +2206 -0
- package/dist/client/chunk-M3L3KYYR.mjs +1181 -0
- package/dist/client/chunk-NWOUL6JY.mjs +1378 -0
- package/dist/client/chunk-OJPZEZU2.mjs +31 -0
- package/dist/client/chunk-RTZ3JKKX.mjs +178 -0
- package/dist/client/chunk-TQ5MSPDX.mjs +74 -0
- package/dist/client/chunk-VUAOE3AG.mjs +5592 -0
- package/dist/client/chunk-WJXXNDSE.mjs +245 -0
- package/dist/client/chunk-YLMKMCSJ.mjs +86 -0
- package/dist/client/chunk-ZLMS67RR.mjs +106 -0
- package/dist/client/client.mjs +51626 -52074
- package/dist/client/courseRegistration-5DPU6PDY.mjs +1737 -0
- package/dist/client/{eventCalendar-X6GIPYFM.mjs → eventCalendar-F3GZGTEF.mjs} +13 -2
- package/dist/client/{eventCombined-EZUOPM3G.mjs → eventCombined-BQOB6QMY.mjs} +13 -2
- package/dist/client/eventDetails-PEM2EJWE.mjs +25 -0
- package/dist/client/{eventListing-HEFGAETC.mjs → eventListing-YMIQPVME.mjs} +13 -2
- package/dist/client/{eventRegistration-3LCP2V3P.mjs → eventRegistration-4I6ZNDUF.mjs} +13 -2
- package/dist/client/form-ZJVAYZ6G.mjs +300 -0
- package/dist/client/headerSection-TOT5MGTF.mjs +729 -0
- package/dist/client/hooks.mjs +49 -33
- package/dist/client/locationMap-J66NZREU.mjs +227 -0
- package/dist/client/newsletterForm-ET2XUMRO.mjs +208 -0
- package/dist/client/productDetail-C2XIH7C5.mjs +18 -0
- package/dist/client/productList-T2AZLFTP.mjs +18 -0
- package/dist/client/rendering/client.mjs +11763 -12445
- package/dist/client/rendering/islands.mjs +98 -21
- package/dist/client/rendering.mjs +46778 -47229
- package/dist/client/shop-UZ6IUZXD.mjs +20 -0
- package/dist/preview-next/before-render.mjs +37 -25
- package/dist/preview-next/client/runtime.mjs +5 -5
- package/dist/preview-next/middleware.mjs +37 -25
- package/dist/{sdk-runtime-OHNONZ5U.mjs → sdk-runtime-JCUQM63Y.mjs} +6 -6
- package/dist/server/components.mjs +409 -266
- package/dist/server/config-validation.mjs +49 -33
- package/dist/server/config.mjs +49 -33
- package/dist/server/data.mjs +49 -33
- package/dist/server/index.mjs +45 -33
- package/dist/server/next.mjs +405 -262
- package/dist/server/page-converter.mjs +12 -8
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/rendering/server.mjs +493 -265
- package/dist/server/rendering.mjs +411 -268
- package/dist/server/routing.mjs +49 -33
- package/dist/server/server.mjs +50 -34
- package/dist/server/theme-bridge.mjs +5 -0
- package/dist/styles/index.css +5 -0
- package/package.json +2 -1
- package/dist/SdkPreviewModeRuntime-CRYNDSPL.mjs +0 -8
- package/dist/client/bookingForm-4X77HKDS.mjs +0 -34
- package/dist/client/cart-JWD2VRFU.mjs +0 -11
- package/dist/client/checkout-V7KYGWL7.mjs +0 -11
- package/dist/client/chunk-5IYGMTUE.mjs +0 -18614
- package/dist/client/chunk-RKCFVIMS.mjs +0 -26
- package/dist/client/courseRegistration-O6ZPK4YT.mjs +0 -29
- package/dist/client/eventDetails-3WODIXET.mjs +0 -14
- package/dist/client/form-AKXQMY6Z.mjs +0 -85
- package/dist/client/headerSection-5KHCMU6B.mjs +0 -12
- package/dist/client/locationMap-7HIADW76.mjs +0 -14
- package/dist/client/newsletterForm-5N4YTMU3.mjs +0 -60
- package/dist/client/productDetail-IZUA7ZP3.mjs +0 -11
- package/dist/client/productList-KWIIJE6I.mjs +0 -11
- package/dist/client/shop-XZQFRQWZ.mjs +0 -13
package/dist/client/hooks.mjs
CHANGED
|
@@ -37,6 +37,18 @@ var TAG_TEMPLATES = {
|
|
|
37
37
|
siteForms: "riverbank:site:{siteId}:forms",
|
|
38
38
|
formById: "riverbank:form:{formId}",
|
|
39
39
|
formSubmissionsBySlug: "riverbank:form-submissions:{slug}",
|
|
40
|
+
// Public data loaders
|
|
41
|
+
publicEvents: "riverbank:site:{siteId}:public-events",
|
|
42
|
+
publicEventFilters: "riverbank:site:{siteId}:public-event-filters",
|
|
43
|
+
publicCourses: "riverbank:site:{siteId}:public-courses",
|
|
44
|
+
publicTeamMembers: "riverbank:site:{siteId}:public-team-members",
|
|
45
|
+
publicProducts: "riverbank:site:{siteId}:public-products",
|
|
46
|
+
publicPasses: "riverbank:site:{siteId}:public-passes",
|
|
47
|
+
publicMemberships: "riverbank:site:{siteId}:public-memberships",
|
|
48
|
+
publicGifting: "riverbank:site:{siteId}:public-gifting",
|
|
49
|
+
publicShop: "riverbank:site:{siteId}:public-shop",
|
|
50
|
+
publicCheckout: "riverbank:site:{siteId}:public-checkout",
|
|
51
|
+
publicBookingServices: "riverbank:site:{siteId}:public-booking-services",
|
|
40
52
|
// Navigation
|
|
41
53
|
siteNavigation: "riverbank:site:{siteId}:navigation",
|
|
42
54
|
navigationMenuById: "riverbank:navigation-menu:{menuId}",
|
|
@@ -3723,7 +3735,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3723
3735
|
path: "/public/sites/{siteId}/events",
|
|
3724
3736
|
method: "GET",
|
|
3725
3737
|
revalidate: 60,
|
|
3726
|
-
tags: [
|
|
3738
|
+
tags: [TAG_TEMPLATES.publicEvents],
|
|
3727
3739
|
auth: "public",
|
|
3728
3740
|
responseKind: "json"
|
|
3729
3741
|
},
|
|
@@ -3732,7 +3744,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3732
3744
|
path: "/public/sites/{siteId}/events/filters",
|
|
3733
3745
|
method: "GET",
|
|
3734
3746
|
revalidate: 60,
|
|
3735
|
-
tags: [
|
|
3747
|
+
tags: [TAG_TEMPLATES.publicEventFilters],
|
|
3736
3748
|
auth: "public",
|
|
3737
3749
|
responseKind: "json"
|
|
3738
3750
|
},
|
|
@@ -3741,7 +3753,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3741
3753
|
path: "/public/sites/{siteId}/courses",
|
|
3742
3754
|
method: "GET",
|
|
3743
3755
|
revalidate: 60,
|
|
3744
|
-
tags: [
|
|
3756
|
+
tags: [TAG_TEMPLATES.publicCourses],
|
|
3745
3757
|
auth: "public",
|
|
3746
3758
|
responseKind: "json"
|
|
3747
3759
|
},
|
|
@@ -3749,7 +3761,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3749
3761
|
path: "/public/sites/{siteId}/team-members",
|
|
3750
3762
|
method: "GET",
|
|
3751
3763
|
revalidate: 60,
|
|
3752
|
-
tags: [
|
|
3764
|
+
tags: [TAG_TEMPLATES.publicTeamMembers],
|
|
3753
3765
|
errors: [],
|
|
3754
3766
|
auth: "public",
|
|
3755
3767
|
responseKind: "json"
|
|
@@ -3758,21 +3770,21 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3758
3770
|
path: "/public/sites/{siteId}/courses/{courseId}",
|
|
3759
3771
|
method: "GET",
|
|
3760
3772
|
revalidate: 60,
|
|
3761
|
-
tags: [
|
|
3773
|
+
tags: [TAG_TEMPLATES.publicCourses],
|
|
3762
3774
|
auth: "public",
|
|
3763
3775
|
responseKind: "json"
|
|
3764
3776
|
},
|
|
3765
3777
|
enrollInCourse: {
|
|
3766
3778
|
path: "/public/sites/{siteId}/courses/enroll",
|
|
3767
3779
|
method: "POST",
|
|
3768
|
-
tags: [
|
|
3780
|
+
tags: [TAG_TEMPLATES.publicCourses, "course-enrollment"],
|
|
3769
3781
|
auth: "public",
|
|
3770
3782
|
responseKind: "json"
|
|
3771
3783
|
},
|
|
3772
3784
|
checkCourseEligibility: {
|
|
3773
3785
|
path: "/public/sites/{siteId}/courses/check-eligibility",
|
|
3774
3786
|
method: "POST",
|
|
3775
|
-
tags: [
|
|
3787
|
+
tags: [TAG_TEMPLATES.publicCourses, "course-enrollment"],
|
|
3776
3788
|
auth: "public",
|
|
3777
3789
|
responseKind: "json"
|
|
3778
3790
|
},
|
|
@@ -3780,8 +3792,8 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3780
3792
|
path: "/public/sites/{siteId}/waitlists/claim/resolve",
|
|
3781
3793
|
method: "POST",
|
|
3782
3794
|
tags: [
|
|
3783
|
-
|
|
3784
|
-
|
|
3795
|
+
TAG_TEMPLATES.publicCourses,
|
|
3796
|
+
TAG_TEMPLATES.publicEvents,
|
|
3785
3797
|
"waitlist-claims"
|
|
3786
3798
|
],
|
|
3787
3799
|
auth: "public",
|
|
@@ -3796,7 +3808,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3796
3808
|
createCourseCheckout: {
|
|
3797
3809
|
path: "/public/sites/{siteId}/courses/checkout",
|
|
3798
3810
|
method: "POST",
|
|
3799
|
-
tags: [
|
|
3811
|
+
tags: [TAG_TEMPLATES.publicCourses, "course-checkout"],
|
|
3800
3812
|
auth: "public",
|
|
3801
3813
|
responseKind: "json",
|
|
3802
3814
|
errors: [
|
|
@@ -3810,7 +3822,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3810
3822
|
getCourseRegistrationStatus: {
|
|
3811
3823
|
path: "/public/sites/{siteId}/courses/registration-status",
|
|
3812
3824
|
method: "GET",
|
|
3813
|
-
tags: [
|
|
3825
|
+
tags: [TAG_TEMPLATES.publicCourses, "course-checkout"],
|
|
3814
3826
|
auth: "public",
|
|
3815
3827
|
responseKind: "json"
|
|
3816
3828
|
},
|
|
@@ -3819,7 +3831,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3819
3831
|
path: "/public/sites/{siteId}/bookings/products/passes",
|
|
3820
3832
|
method: "GET",
|
|
3821
3833
|
revalidate: 300,
|
|
3822
|
-
tags: [
|
|
3834
|
+
tags: [TAG_TEMPLATES.publicPasses],
|
|
3823
3835
|
auth: "public",
|
|
3824
3836
|
responseKind: "json"
|
|
3825
3837
|
},
|
|
@@ -3828,7 +3840,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3828
3840
|
path: "/public/sites/{siteId}/bookings/products/memberships",
|
|
3829
3841
|
method: "GET",
|
|
3830
3842
|
revalidate: 300,
|
|
3831
|
-
tags: [
|
|
3843
|
+
tags: [TAG_TEMPLATES.publicMemberships],
|
|
3832
3844
|
auth: "public",
|
|
3833
3845
|
responseKind: "json"
|
|
3834
3846
|
},
|
|
@@ -3837,7 +3849,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3837
3849
|
path: "/public/sites/{siteId}/products",
|
|
3838
3850
|
method: "GET",
|
|
3839
3851
|
revalidate: 300,
|
|
3840
|
-
tags: [
|
|
3852
|
+
tags: [TAG_TEMPLATES.publicProducts],
|
|
3841
3853
|
errors: [],
|
|
3842
3854
|
auth: "public",
|
|
3843
3855
|
responseKind: "json"
|
|
@@ -3846,7 +3858,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3846
3858
|
path: "/public/sites/{siteId}/gifting/offers",
|
|
3847
3859
|
method: "GET",
|
|
3848
3860
|
revalidate: 300,
|
|
3849
|
-
tags: [
|
|
3861
|
+
tags: [TAG_TEMPLATES.publicGifting],
|
|
3850
3862
|
errors: [],
|
|
3851
3863
|
auth: "public",
|
|
3852
3864
|
responseKind: "json"
|
|
@@ -3854,7 +3866,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3854
3866
|
createPublicGiftingCheckout: {
|
|
3855
3867
|
path: "/public/sites/{siteId}/gifting/checkout",
|
|
3856
3868
|
method: "POST",
|
|
3857
|
-
tags: [
|
|
3869
|
+
tags: [TAG_TEMPLATES.publicGifting],
|
|
3858
3870
|
errors: [],
|
|
3859
3871
|
auth: "public",
|
|
3860
3872
|
responseKind: "json"
|
|
@@ -3862,7 +3874,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3862
3874
|
claimGiftCardPublic: {
|
|
3863
3875
|
path: "/public/sites/{siteId}/gifting/claim",
|
|
3864
3876
|
method: "POST",
|
|
3865
|
-
tags: [
|
|
3877
|
+
tags: [TAG_TEMPLATES.publicGifting],
|
|
3866
3878
|
errors: [],
|
|
3867
3879
|
auth: "public",
|
|
3868
3880
|
responseKind: "json"
|
|
@@ -3870,14 +3882,14 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3870
3882
|
createShopCheckout: {
|
|
3871
3883
|
path: "/public/sites/{siteId}/bookings/checkout",
|
|
3872
3884
|
method: "POST",
|
|
3873
|
-
tags: [
|
|
3885
|
+
tags: [TAG_TEMPLATES.publicShop, "shop-checkout"],
|
|
3874
3886
|
auth: "public",
|
|
3875
3887
|
responseKind: "json"
|
|
3876
3888
|
},
|
|
3877
3889
|
createUnifiedCheckout: {
|
|
3878
3890
|
path: "/public/sites/{siteId}/checkout",
|
|
3879
3891
|
method: "POST",
|
|
3880
|
-
tags: [
|
|
3892
|
+
tags: [TAG_TEMPLATES.publicCheckout],
|
|
3881
3893
|
auth: "public",
|
|
3882
3894
|
responseKind: "json",
|
|
3883
3895
|
errors: [
|
|
@@ -3916,7 +3928,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3916
3928
|
path: "/public/sites/{siteId}/events/occurrences/resolve",
|
|
3917
3929
|
method: "GET",
|
|
3918
3930
|
revalidate: 60,
|
|
3919
|
-
tags: [
|
|
3931
|
+
tags: [TAG_TEMPLATES.publicEvents, "event-occurrence"],
|
|
3920
3932
|
auth: "public",
|
|
3921
3933
|
responseKind: "json"
|
|
3922
3934
|
},
|
|
@@ -3924,7 +3936,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3924
3936
|
registerForEvent: {
|
|
3925
3937
|
path: "/public/sites/{siteId}/events/register",
|
|
3926
3938
|
method: "POST",
|
|
3927
|
-
tags: [
|
|
3939
|
+
tags: [TAG_TEMPLATES.publicEvents, "event-registration"],
|
|
3928
3940
|
auth: "public",
|
|
3929
3941
|
responseKind: "json"
|
|
3930
3942
|
},
|
|
@@ -3932,7 +3944,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3932
3944
|
createPublicEventCheckout: {
|
|
3933
3945
|
path: "/public/sites/{siteId}/events/checkout",
|
|
3934
3946
|
method: "POST",
|
|
3935
|
-
tags: [
|
|
3947
|
+
tags: [TAG_TEMPLATES.publicEvents, "event-checkout"],
|
|
3936
3948
|
auth: "public",
|
|
3937
3949
|
responseKind: "json"
|
|
3938
3950
|
},
|
|
@@ -3940,7 +3952,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3940
3952
|
checkPublicEventEligibility: {
|
|
3941
3953
|
path: "/public/sites/{siteId}/events/check-eligibility",
|
|
3942
3954
|
method: "POST",
|
|
3943
|
-
tags: [
|
|
3955
|
+
tags: [TAG_TEMPLATES.publicEvents, "event-eligibility"],
|
|
3944
3956
|
auth: "public",
|
|
3945
3957
|
responseKind: "json"
|
|
3946
3958
|
},
|
|
@@ -3948,7 +3960,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3948
3960
|
getPublicEventRegistrationStatus: {
|
|
3949
3961
|
path: "/public/sites/{siteId}/events/registration-status",
|
|
3950
3962
|
method: "GET",
|
|
3951
|
-
tags: [
|
|
3963
|
+
tags: [TAG_TEMPLATES.publicEvents, "event-registration"],
|
|
3952
3964
|
auth: "public",
|
|
3953
3965
|
responseKind: "json"
|
|
3954
3966
|
},
|
|
@@ -3956,7 +3968,7 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
3956
3968
|
getPublicEventTicketQrSvg: {
|
|
3957
3969
|
path: "/public/sites/{siteId}/events/tickets/qr",
|
|
3958
3970
|
method: "GET",
|
|
3959
|
-
tags: [
|
|
3971
|
+
tags: [TAG_TEMPLATES.publicEvents, "event-ticket-qr"],
|
|
3960
3972
|
auth: "public",
|
|
3961
3973
|
responseKind: "text"
|
|
3962
3974
|
},
|
|
@@ -21142,7 +21154,7 @@ var cardStylingFields = [
|
|
|
21142
21154
|
description: "Text for the event action button",
|
|
21143
21155
|
required: false,
|
|
21144
21156
|
multiline: false,
|
|
21145
|
-
defaultValue: "
|
|
21157
|
+
defaultValue: "Book now",
|
|
21146
21158
|
maxLength: 40
|
|
21147
21159
|
}
|
|
21148
21160
|
];
|
|
@@ -21641,6 +21653,7 @@ var eventRegistrationBlockDefinition = {
|
|
|
21641
21653
|
limit: "50",
|
|
21642
21654
|
// Get more events for selection
|
|
21643
21655
|
stage: { $bind: { from: "$root.previewStage", fallback: "published" } },
|
|
21656
|
+
readProfile: "registration",
|
|
21644
21657
|
// When rendering on an event content entry page, scope the list to that entry so
|
|
21645
21658
|
// the wizard always includes the current event (and avoids stale cached "all events" responses).
|
|
21646
21659
|
entryId: { $bind: { from: "$root.contentEntry._entryId", fallback: "" } }
|
|
@@ -22441,7 +22454,7 @@ var eventSpotlightLayout = [
|
|
|
22441
22454
|
columns: { $bind: { from: "content.columns", fallback: "3" } },
|
|
22442
22455
|
cardVariant: { $bind: { from: "content.cardVariant", fallback: "default" } },
|
|
22443
22456
|
buttonVariant: { $bind: { from: "content.buttonVariant", fallback: "primary" } },
|
|
22444
|
-
buttonText: { $bind: { from: "content.buttonText", fallback: "
|
|
22457
|
+
buttonText: { $bind: { from: "content.buttonText", fallback: "Book now" } },
|
|
22445
22458
|
ctaLabel: { $bind: { from: "content.ctaLabel" } },
|
|
22446
22459
|
ctaUrl: { $bind: { from: "content.ctaUrl", transforms: [{ id: "links.resolve" }] } },
|
|
22447
22460
|
showVenue: { $bind: { from: "content.showVenue" } },
|
|
@@ -22485,7 +22498,8 @@ var eventSpotlightBlockDefinition = {
|
|
|
22485
22498
|
siteId: { $bind: { from: "$root.siteId" } },
|
|
22486
22499
|
limit: { $bind: { from: "content.maxEvents", fallback: "3" } },
|
|
22487
22500
|
stage: { $bind: { from: "$root.previewStage", fallback: "published" } },
|
|
22488
|
-
detailLevel: "listing"
|
|
22501
|
+
detailLevel: "listing",
|
|
22502
|
+
readProfile: "spotlight"
|
|
22489
22503
|
},
|
|
22490
22504
|
mode: "server"
|
|
22491
22505
|
}
|
|
@@ -22503,7 +22517,7 @@ var COLUMN_CLASSES = {
|
|
|
22503
22517
|
};
|
|
22504
22518
|
function getContainerClass(layout, columns) {
|
|
22505
22519
|
if (layout === "compact") {
|
|
22506
|
-
return "rb-flex rb-flex-col rb-gap-2";
|
|
22520
|
+
return "event-listing-compact-container rb-flex rb-flex-col rb-gap-2";
|
|
22507
22521
|
}
|
|
22508
22522
|
if (layout === "stack") {
|
|
22509
22523
|
return "rb-flex rb-flex-col rb-gap-6";
|
|
@@ -22707,7 +22721,7 @@ var eventListingBlockRuntime = defineProgressiveBlockRuntime({
|
|
|
22707
22721
|
containerClass: getContainerClass(layout, source.columns ?? "3"),
|
|
22708
22722
|
cardVariant: source.cardVariant ?? "default",
|
|
22709
22723
|
buttonVariant: source.buttonVariant ?? "primary",
|
|
22710
|
-
buttonText: source.buttonText ?? "
|
|
22724
|
+
buttonText: source.buttonText ?? "Book now",
|
|
22711
22725
|
showVenue: source.showVenue ?? true,
|
|
22712
22726
|
showMap: source.showMap ?? true,
|
|
22713
22727
|
showCapacity: source.showCapacity ?? true,
|
|
@@ -22942,7 +22956,7 @@ var eventListingLayout = [
|
|
|
22942
22956
|
loadMoreText: { $bind: { from: "content.loadMoreText", fallback: "Load more events" } },
|
|
22943
22957
|
cardVariant: { $bind: { from: "content.cardVariant", fallback: "default" } },
|
|
22944
22958
|
buttonVariant: { $bind: { from: "content.buttonVariant", fallback: "primary" } },
|
|
22945
|
-
buttonText: { $bind: { from: "content.buttonText", fallback: "
|
|
22959
|
+
buttonText: { $bind: { from: "content.buttonText", fallback: "Book now" } },
|
|
22946
22960
|
showVenue: { $bind: { from: "content.showVenue" } },
|
|
22947
22961
|
showMap: { $bind: { from: "content.showMap" } },
|
|
22948
22962
|
showCapacity: { $bind: { from: "content.showCapacity" } },
|
|
@@ -23020,6 +23034,7 @@ var eventListingBlockDefinition = {
|
|
|
23020
23034
|
limit: { $bind: { from: "content.eventsPerPage", fallback: "12" } },
|
|
23021
23035
|
stage: { $bind: { from: "$root.previewStage", fallback: "published" } },
|
|
23022
23036
|
detailLevel: "listing",
|
|
23037
|
+
readProfile: { $bind: { from: "content.layout", fallback: "listing-card" } },
|
|
23023
23038
|
kind: { $bind: { from: "content.kind" } },
|
|
23024
23039
|
eventSurface: { $bind: { from: "content.eventSurface" } },
|
|
23025
23040
|
eventPresets: {
|
|
@@ -23159,7 +23174,7 @@ function buildEventCalendarDisplay(source) {
|
|
|
23159
23174
|
),
|
|
23160
23175
|
filterVenueId: normalizeEventVenueId(source.filterVenueId),
|
|
23161
23176
|
buttonVariant: source.buttonVariant ?? "primary",
|
|
23162
|
-
buttonText: source.buttonText ?? "
|
|
23177
|
+
buttonText: source.buttonText ?? "Book now",
|
|
23163
23178
|
showVenue: source.showVenue ?? true,
|
|
23164
23179
|
showMap: source.showMap ?? true,
|
|
23165
23180
|
showCapacity: source.showCapacity ?? true,
|
|
@@ -23315,7 +23330,7 @@ var eventCalendarLayout = [
|
|
|
23315
23330
|
$bind: { from: "content.buttonVariant", fallback: "primary" }
|
|
23316
23331
|
},
|
|
23317
23332
|
buttonText: {
|
|
23318
|
-
$bind: { from: "content.buttonText", fallback: "
|
|
23333
|
+
$bind: { from: "content.buttonText", fallback: "Book now" }
|
|
23319
23334
|
},
|
|
23320
23335
|
emptyMessage: { $bind: { from: "content.emptyMessage" } }
|
|
23321
23336
|
})
|
|
@@ -23776,6 +23791,7 @@ var eventCalendarBlockDefinition = {
|
|
|
23776
23791
|
limit: 100,
|
|
23777
23792
|
stage: { $bind: { from: "$root.previewStage", fallback: "published" } },
|
|
23778
23793
|
detailLevel: "listing",
|
|
23794
|
+
readProfile: { $bind: { from: "content.variant", fallback: "listing-card" } },
|
|
23779
23795
|
// Pass filter params if configured
|
|
23780
23796
|
kind: { $bind: { from: "content.kind" } },
|
|
23781
23797
|
eventSurface: { $bind: { from: "content.eventSurface" } },
|
|
@@ -0,0 +1,227 @@
|
|
|
1
|
+
import { LeafletStaticMap } from './chunk-F7LHOKEH.mjs';
|
|
2
|
+
import './chunk-I2MMZO53.mjs';
|
|
3
|
+
import { mountReactIsland } from './chunk-N7PBWBWQ.mjs';
|
|
4
|
+
import { defineIslandPropsDecoder } from './chunk-FU2QRZMX.mjs';
|
|
5
|
+
import { normalizeLocationAddressText, toLocationCoordinates, textColorStyle, mergeStyles, borderColorStyle, backgroundColorStyle } from './chunk-PMAIXMAB.mjs';
|
|
6
|
+
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
7
|
+
|
|
8
|
+
// ../blocks/src/system/runtime/nodes/location-map.shared.ts
|
|
9
|
+
var LOCATION_MAP_DEFAULTS = {
|
|
10
|
+
zoom: 15,
|
|
11
|
+
heightPx: 320,
|
|
12
|
+
showAddressText: true,
|
|
13
|
+
showDirections: true,
|
|
14
|
+
directionsLabel: "Get directions"
|
|
15
|
+
};
|
|
16
|
+
var LOCATION_MAP_LIMITS = {
|
|
17
|
+
zoom: { min: 3, max: 18 },
|
|
18
|
+
heightPx: { min: 200, max: 600 }
|
|
19
|
+
};
|
|
20
|
+
function normalizeNumber(value, fallback) {
|
|
21
|
+
if (typeof value === "number" && Number.isFinite(value)) {
|
|
22
|
+
return value;
|
|
23
|
+
}
|
|
24
|
+
if (typeof value === "string") {
|
|
25
|
+
const parsed = Number.parseFloat(value);
|
|
26
|
+
if (Number.isFinite(parsed)) {
|
|
27
|
+
return parsed;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
return fallback;
|
|
31
|
+
}
|
|
32
|
+
function normalizeOptionalNumber(value) {
|
|
33
|
+
if (typeof value === "number" && Number.isFinite(value)) {
|
|
34
|
+
return value;
|
|
35
|
+
}
|
|
36
|
+
if (typeof value === "string") {
|
|
37
|
+
const parsed = Number.parseFloat(value);
|
|
38
|
+
if (Number.isFinite(parsed)) {
|
|
39
|
+
return parsed;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
return null;
|
|
43
|
+
}
|
|
44
|
+
function normalizeBoolean(value, fallback) {
|
|
45
|
+
if (typeof value === "boolean") {
|
|
46
|
+
return value;
|
|
47
|
+
}
|
|
48
|
+
if (typeof value === "string") {
|
|
49
|
+
if (value === "true") return true;
|
|
50
|
+
if (value === "false") return false;
|
|
51
|
+
}
|
|
52
|
+
return fallback;
|
|
53
|
+
}
|
|
54
|
+
function normalizeLocationMapValueRecord(record) {
|
|
55
|
+
const addressText = typeof record.addressText === "string" ? record.addressText : typeof record.displayAddress === "string" ? record.displayAddress : null;
|
|
56
|
+
const normalized = {
|
|
57
|
+
addressText: normalizeLocationAddressText(addressText),
|
|
58
|
+
lat: normalizeOptionalNumber(record.lat),
|
|
59
|
+
lng: normalizeOptionalNumber(record.lng)
|
|
60
|
+
};
|
|
61
|
+
if (normalized.addressText === null && normalized.lat === null && normalized.lng === null) {
|
|
62
|
+
return null;
|
|
63
|
+
}
|
|
64
|
+
return normalized;
|
|
65
|
+
}
|
|
66
|
+
function normalizeLocationMapValue(value) {
|
|
67
|
+
if (typeof value !== "object" || value === null) {
|
|
68
|
+
return null;
|
|
69
|
+
}
|
|
70
|
+
return normalizeLocationMapValueRecord(value);
|
|
71
|
+
}
|
|
72
|
+
function normalizeLocationMapSource(value) {
|
|
73
|
+
return value === "business_address" || value === "venue" ? value : "custom";
|
|
74
|
+
}
|
|
75
|
+
function resolveLocationMapLocation(input) {
|
|
76
|
+
const source = normalizeLocationMapSource(input.locationSource);
|
|
77
|
+
if (source === "business_address") {
|
|
78
|
+
const locationValue2 = normalizeLocationMapValue(input.businessAddress ?? input.location);
|
|
79
|
+
return locationValue2 ? { kind: "business_address", locationValue: locationValue2 } : { kind: "unresolved", source, reason: "missing_business_address" };
|
|
80
|
+
}
|
|
81
|
+
if (source === "venue") {
|
|
82
|
+
const venueId = typeof input.venueId === "string" && input.venueId.trim() ? input.venueId.trim() : null;
|
|
83
|
+
if (!venueId) {
|
|
84
|
+
return { kind: "unresolved", source, reason: "missing_venue_id" };
|
|
85
|
+
}
|
|
86
|
+
const locationValue2 = input.venuesById ? normalizeLocationMapValue(input.venuesById[venueId] ?? null) : null;
|
|
87
|
+
return locationValue2 ? { kind: "venue", venueId, locationValue: locationValue2 } : { kind: "unresolved", source, reason: "missing_venue_location" };
|
|
88
|
+
}
|
|
89
|
+
const locationValue = normalizeLocationMapValue(input.location);
|
|
90
|
+
return locationValue ? { kind: "custom", locationValue } : { kind: "unresolved", source, reason: "missing_custom_location" };
|
|
91
|
+
}
|
|
92
|
+
function describeUnresolvedLocationMapLocation(resolvedLocation) {
|
|
93
|
+
if (resolvedLocation.kind !== "unresolved") {
|
|
94
|
+
return null;
|
|
95
|
+
}
|
|
96
|
+
switch (resolvedLocation.reason) {
|
|
97
|
+
case "missing_business_address":
|
|
98
|
+
return "Business address details are not configured yet.";
|
|
99
|
+
case "missing_venue_id":
|
|
100
|
+
return "Choose a venue to show this map.";
|
|
101
|
+
case "missing_venue_location":
|
|
102
|
+
return "The selected venue does not have location details yet.";
|
|
103
|
+
case "missing_custom_location":
|
|
104
|
+
return "Location details coming soon.";
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
function normalizeLocationMapProps(input) {
|
|
108
|
+
const resolvedLocation = resolveLocationMapLocation(input);
|
|
109
|
+
const locationValue = resolvedLocation.kind === "unresolved" ? null : resolvedLocation.locationValue;
|
|
110
|
+
const directionsLabel = normalizeLocationAddressText(input.directionsLabel) ?? LOCATION_MAP_DEFAULTS.directionsLabel;
|
|
111
|
+
return {
|
|
112
|
+
resolvedLocation,
|
|
113
|
+
locationValue,
|
|
114
|
+
unresolvedMessage: describeUnresolvedLocationMapLocation(resolvedLocation),
|
|
115
|
+
addressText: locationValue?.addressText ?? null,
|
|
116
|
+
location: toLocationCoordinates(locationValue),
|
|
117
|
+
zoom: Math.min(
|
|
118
|
+
LOCATION_MAP_LIMITS.zoom.max,
|
|
119
|
+
Math.max(
|
|
120
|
+
LOCATION_MAP_LIMITS.zoom.min,
|
|
121
|
+
Math.round(normalizeNumber(input.zoom, LOCATION_MAP_DEFAULTS.zoom))
|
|
122
|
+
)
|
|
123
|
+
),
|
|
124
|
+
heightPx: Math.min(
|
|
125
|
+
LOCATION_MAP_LIMITS.heightPx.max,
|
|
126
|
+
Math.max(
|
|
127
|
+
LOCATION_MAP_LIMITS.heightPx.min,
|
|
128
|
+
Math.round(normalizeNumber(input.heightPx, LOCATION_MAP_DEFAULTS.heightPx))
|
|
129
|
+
)
|
|
130
|
+
),
|
|
131
|
+
showAddressText: normalizeBoolean(input.showAddressText, LOCATION_MAP_DEFAULTS.showAddressText),
|
|
132
|
+
showDirections: normalizeBoolean(input.showDirections, LOCATION_MAP_DEFAULTS.showDirections),
|
|
133
|
+
directionsLabel,
|
|
134
|
+
className: typeof input.className === "string" ? input.className : null
|
|
135
|
+
};
|
|
136
|
+
}
|
|
137
|
+
function buildGoogleMapsDirectionsUrl(input) {
|
|
138
|
+
const destination = input.location ? `${input.location.lat},${input.location.lng}` : normalizeLocationAddressText(input.addressText);
|
|
139
|
+
if (!destination) {
|
|
140
|
+
return null;
|
|
141
|
+
}
|
|
142
|
+
const url = new URL("https://www.google.com/maps/dir/");
|
|
143
|
+
url.searchParams.set("api", "1");
|
|
144
|
+
url.searchParams.set("destination", destination);
|
|
145
|
+
return url.toString();
|
|
146
|
+
}
|
|
147
|
+
function LocationMapView({
|
|
148
|
+
addressText,
|
|
149
|
+
location,
|
|
150
|
+
zoom,
|
|
151
|
+
heightPx,
|
|
152
|
+
showAddressText,
|
|
153
|
+
showDirections,
|
|
154
|
+
directionsLabel,
|
|
155
|
+
unresolvedMessage,
|
|
156
|
+
renderMap
|
|
157
|
+
}) {
|
|
158
|
+
const directionsUrl = buildGoogleMapsDirectionsUrl({ addressText, location });
|
|
159
|
+
if (!location && !addressText && !directionsUrl) {
|
|
160
|
+
return /* @__PURE__ */ jsx("p", { className: "rb-caption", style: textColorStyle("mutedText"), children: unresolvedMessage ?? "Location details coming soon." });
|
|
161
|
+
}
|
|
162
|
+
return /* @__PURE__ */ jsxs("div", { className: "rb-flex rb-flex-col rb-gap-4 rb-text-left", children: [
|
|
163
|
+
location && renderMap ? renderMap({
|
|
164
|
+
addressText,
|
|
165
|
+
location,
|
|
166
|
+
className: "rb-location-map-canvas",
|
|
167
|
+
height: heightPx,
|
|
168
|
+
zoom
|
|
169
|
+
}) : null,
|
|
170
|
+
showAddressText && addressText ? /* @__PURE__ */ jsx("p", { className: "rb-caption", style: textColorStyle("mutedText"), children: addressText }) : null,
|
|
171
|
+
showDirections && directionsUrl ? /* @__PURE__ */ jsx(
|
|
172
|
+
"a",
|
|
173
|
+
{
|
|
174
|
+
href: directionsUrl,
|
|
175
|
+
target: "_blank",
|
|
176
|
+
rel: "noreferrer",
|
|
177
|
+
className: "rb-inline-flex rb-w-fit rb-items-center rb-justify-center rb-rounded-md rb-border rb-px-4 rb-py-2 rb-text-sm rb-font-medium rb-no-underline transition-theme-standard rb-hover-opacity-90",
|
|
178
|
+
style: mergeStyles(
|
|
179
|
+
borderColorStyle("border"),
|
|
180
|
+
backgroundColorStyle("surface"),
|
|
181
|
+
textColorStyle("text")
|
|
182
|
+
),
|
|
183
|
+
children: directionsLabel
|
|
184
|
+
}
|
|
185
|
+
) : null
|
|
186
|
+
] });
|
|
187
|
+
}
|
|
188
|
+
function LocationMapClient(props) {
|
|
189
|
+
const normalized = normalizeLocationMapProps(props);
|
|
190
|
+
return /* @__PURE__ */ jsxs("div", { className: `location-map ${normalized.className ?? ""}`.trim(), "data-block": "location-map", children: [
|
|
191
|
+
/* @__PURE__ */ jsx(
|
|
192
|
+
LocationMapView,
|
|
193
|
+
{
|
|
194
|
+
addressText: normalized.addressText,
|
|
195
|
+
location: normalized.location,
|
|
196
|
+
zoom: normalized.zoom,
|
|
197
|
+
heightPx: normalized.heightPx,
|
|
198
|
+
showAddressText: normalized.showAddressText,
|
|
199
|
+
showDirections: normalized.showDirections,
|
|
200
|
+
directionsLabel: normalized.directionsLabel,
|
|
201
|
+
unresolvedMessage: normalized.unresolvedMessage,
|
|
202
|
+
renderMap: ({ addressText, className, height, location, zoom }) => /* @__PURE__ */ jsx(
|
|
203
|
+
LeafletStaticMap,
|
|
204
|
+
{
|
|
205
|
+
location,
|
|
206
|
+
label: addressText ?? void 0,
|
|
207
|
+
className,
|
|
208
|
+
height,
|
|
209
|
+
zoom
|
|
210
|
+
}
|
|
211
|
+
)
|
|
212
|
+
}
|
|
213
|
+
),
|
|
214
|
+
props.children
|
|
215
|
+
] });
|
|
216
|
+
}
|
|
217
|
+
function LocationMapIslandClient(props) {
|
|
218
|
+
return /* @__PURE__ */ jsx(LocationMapClient, { ...props });
|
|
219
|
+
}
|
|
220
|
+
var decode = defineIslandPropsDecoder("location-map");
|
|
221
|
+
var enhance = (root, props) => {
|
|
222
|
+
return mountReactIsland(root, ({ root: reactRoot }) => {
|
|
223
|
+
reactRoot.render(/* @__PURE__ */ jsx(LocationMapIslandClient, { ...props }));
|
|
224
|
+
});
|
|
225
|
+
};
|
|
226
|
+
|
|
227
|
+
export { decode, enhance };
|