riverbankcms 0.23.0 → 0.24.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/acceptance/matrix.mjs +3 -3
- package/dist/cli/index.mjs +921 -539
- package/dist/cli/init-docs/content/content-management.md +31 -6
- package/dist/{entryCommands-BdN5YrqI.mjs → entryCommands-C0xbLW5L.mjs} +69 -6
- package/dist/{eventUpsertInputSchema-kp-U13TZ.mjs → eventUpsertInputSchema-C-cDv9vR.mjs} +6 -2
- package/dist/load-config-BGzlsmtt.mjs +4 -0
- package/dist/{load-config-D5DDfmv1.mjs → load-config-h2Ri_tDO.mjs} +2 -2
- package/dist/{plan-6m8gsGI8.mjs → plan-Dyv1rMTT.mjs} +1 -1
- package/dist/scaffold/index.mjs +2 -2
- package/dist/{sdk-event-upsert-BnBxyTR6.mjs → sdk-event-upsert-DmNSeHgP.mjs} +3714 -2745
- package/dist/{src-BPh_OivC.mjs → src-B03aw4Tv.mjs} +1034 -75
- package/dist/testing.mjs +4 -4
- package/package.json +1 -1
- package/dist/load-config-C7Rd822n.mjs +0 -4
package/dist/cli/index.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { $ as createFormRef, $n as
|
|
3
|
-
import { $ as
|
|
4
|
-
import { $ as normalizeMediaValueToIdentifierOnly, $t as bindRequestTimeout, A as formatDiffDetail, An as transportSuggestion, At as navigationIdentity, B as buildFieldChanges, Bn as sdkEventScheduleSchema, Bt as preparePushConfigTarget, C as reportFromOutcomes, Cn as parseEnvironmentSelection, Ct as fileExists, D as normalizeRemoteHomepageReference, Dn as withRiverbankEnv, Dt as writeJsonFileAtomic, E as createEmptySyncResult, En as requireEnvironmentWriteAuthorization, Et as writeJsonFile, F as calculatePullDiff, Fn as isLocalConfigured, Ft as navigationCommandItemToManagementInput, G as syncLocalMediaForPull, Gt as APPOINTMENT_SERVICE_VISIBILITY_VALUES, H as formatFieldPath, Hn as linkPayloadSchema, Ht as extractApiErrorMessage, I as buildJsonDiff, In as isRemoteConfigured, It as normalizeNavigationConfigItemForCommand, J as admitBinaryWriteDestination, Jt as ApiEnvelopeError, K as applyLocalMediaPush, Kt as ApiRequestError, L as hasPageOperations, Ln as loadSdkEnvironment, Lt as applyPushConfigPlan, M as hasPendingChanges, Mt as convertPulledFooterToLocal, N as findChangedFieldsWithValues, Nn as getEnvPrefix, Nt as convertPulledNavigationToLocal, O as calculateDiff, On as ErrorCodes, Ot as isMediaValue, P as formatHumanDiff, Pn as getEnvironmentDebugInfo, Pt as convertPulledPagesToLocal, Q as normalizeMediaIdentifierInput, Qt as mapEnvironmentExecutionOutcomesJson, R as pageMetadataForUpsert, Rn as createManagementClient, Rt as createPushConfigCommand, S as planCliCommandBatchForBindings, Sn as executeEnvironmentPlan, St as ensureDir, T as executeResidualSettingsSyncPlan, Tn as planEnvironmentWriteAuthorization, Tt as readJsonFile, U as revalidateLocalMediaPushPlan, Un as portablePageDesignSchema, Ut as normalizeApiError, V as formatFieldChange, Vn as sdkSettingsUpdateSchema, Vt as revalidatePushConfigPlan, Wn as sdkConfiguredBookingVerticalConfigSchema, Wt as isRecord$2, X as writeBinaryFileAtomic, Xt as deriveCmsApiUrlFromDashboardUrl, Y as readStableBinaryFile, Yt as unwrapResponse, Z as sha256, Zt as API_ENDPOINTS, _ as commandExecutionToReport, _n as runWithInvocation, _t as metadataFilePath, a as executeEntryCommandPlanAsReport, an as createOutputForCommand, at as readEntries, b as executeCompiledCliCommandPlanAsReport, bn as withErrorHandling, bt as writeMetadataFile, c as titleFromEntryData, cn as getOutputContext, ct as readEventsMeta, d as unsafeAsCliEntryIdentifier, dn as managementClientConfigFor, dt as readNavigationMeta, en as confirmAction, et as walkLocalContentMedia, f as unsafeAsCliFormSlug, fn as mapEntryForOutput, ft as readPagesMeta, g as commandCompileFailureToReport, gn as resolveCommandPath, gt as ensureMetadataDir, h as mutationCounterForEffect, hn as parsePaginationOptions, ht as writeMediaManifest, i as entrySiteCommandTypes, in as createListCommand, it as findLegacyEntryFiles, j as formatDiffSummary, jn as CliExit, jt as navigationIdentityMap, k as calculateFooterDiff, kn as formatError, kt as duplicateNavigationIdentityMessage, l as unsafeAsCliBlockIdentifier, ln as getOutputOnlyContext, lt as readFooterMeta, m as commandReportToSyncResult, mn as parseJsonData, mt as readVenuesMeta, n as entryCommandCompileErrorToReport, nn as createCommandContext, nt as downloadMedia, o as executeEntryCommandPlanAsSyncResult, on as currentInvocationEnvelope, ot as readAllMeta, p as unsafeAsCliPageIdentifier, pn as parseJsonArray, pt as readSettingsMeta, q as prepareLocalMediaForPush, qt as createBearerAPIClient, r as entryCommandReportToSyncResult, rn as createGetCommand, rt as extractMediaIdentifiers, s as syncResultForEntryCommandCompileError, sn as formatDateShort, st as readEventCategoriesMeta, t as compileEntryPushCommands, tn as createClientForEnv, tt as buildStorageUrl, u as unsafeAsCliContentTypeKey, un as handleCommandError, ut as readFormsMeta, v as commandReportHasFailures, vn as withCommandContext, vt as metadataTargetFromEnvironment, w as mergeManySyncResults, wn as planEnvironmentExecution, wt as listFiles, x as formatManagementError, xn as withOutputOnlyErrorHandling, xt as writeMetadataRecordMap, y as executeCliCommandPlan, yn as withConfirmation, yt as readMetadataFile, zn as ManagementApiError, zt as loadPushConfigTarget } from "../entryCommands-
|
|
5
|
-
import { r as CLI_VERSION, t as loadConfigFile } from "../load-config-
|
|
6
|
-
import { a as RichTextDocSchema, c as isRecord$18, i as findUnfilledSentinels, n as buildEntryScaffold, o as isRichTextDoc, r as validateEntryInstance, s as isObjectRecord, t as eventUpsertInputSchema } from "../eventUpsertInputSchema-
|
|
7
|
-
import { a as prepareScaffoldExecution, c as LOCAL_PACKAGE_VENDOR_DIR, d as loadGeneratedPackageRanges, i as preflightScaffoldTargets, n as createScaffoldCompletion, s as deriveScaffoldLocalManifest, t as deriveScaffoldPlan } from "../plan-
|
|
2
|
+
import { $ as createFormRef, $n as parseSafeDownloadFilename, $r as surfaceForegroundValue, An as mediaSchema, Ar as resolveSurface, At as generateMobileOverlayBackdropFilterFix, Br as mapDrawingStyle, Bt as getComponentShadowVar, C as sortRecord, Cn as isExplicitRectCrop, Cr as offeringsPreviewCompositionTreatmentValues, Ct as requireCuratedSiteStyle, D as mapEventCommandContent, Dn as getDirectImageUrlForSiteScopedPath, Dr as visibleHeadingDecorationFamilyValues, Dt as parseGradientPresetId, En as getDirectImageUrlForRelativePath, Er as toNonEmptyReadonlyArray, Et as getGradientPreset, F as pageIdentifierForBlockCommand, Fn as mediaTypeDiscriminants, Fr as backgroundColorStyle, Ft as BREAKPOINT_SM, G as ianaTimezoneSchema, Gn as getMimeType, Gr as resolveTokenOrCssColorValue, Gt as themeButtonSizeClassName, H as bookingPaymentTermsSchema, Hn as deriveVideoSlotPolicy, Hr as isCssColorLiteral, Ht as generateDefaultButtonSystem, I as pageIdentifierForCommand, In as mediaIdentifierSchema, Ir as borderColorStyle, It as BREAKPOINT_XL, J as createCommandRef, Jn as parseRelativeStoragePath, Jr as surfaceToneFromForegroundToken, K as createBlockRef, Kn as asRecord, Kr as PUBLIC_BUTTON_ROLES, Kt as themeButtonVariantClassNames, L as pagePathForCommand, Ln as buildMediaIdentifierFromFilename, Lr as mergeStyles, Lt as MQ_MD_DOWN, M as blockIdentifierForCommand, Mn as runtimeMediaSchema, Mr as surfaceDecorationColors, Mt as renderHeaderPaintTargetRules, N as blockOrderIdentifiersForCommand, Nn as buildRenderableMediaAssetIndex, Nr as resolveSurfaceForeground, Nt as BREAKPOINT_LG, On as getImageUrl, Or as parseResolvedSurface, Ot as themeSchema, P as entryIdentifierForCommand, Pn as resolveManagedMediaReference, Pr as TokenResolver, Pt as BREAKPOINT_MD, Q as createFooterRef, Qn as managementMediaLibraryUploadLimitForMimeType, Qr as surfaceForegroundStyle, R as hasConfiguredBookingVertical, Rn as parseCanonicalMediaIdentifier, Rr as rgbColorValue, Rt as headerVariantValues, S as venueManagementFields, Sn as normalizeWidthCandidates, Sr as makeBoundaryId, St as deriveSiteStyleBlockPolicy, Tn as resolveMediaTransformForAspect, Tr as tileTreatmentValues, Tt as gradientToCss, U as require_jsx_runtime, Un as resolveVideoSelectionIntentForMediaField, Ur as resolveOnColorForThemeToken, Ut as parseThemeButtonVariantId, V as bookingPaymentCollectionOptionSchema, Vr as opaqueSurfaceDeclarations, Vt as ICON_CONFIG, W as require_react, Wr as resolveThemeColorReferenceValue, Wt as themeButtonExtraClassesWithTrailingIcon, X as createEventCategoryRef, Xr as surfaceForegroundDeclarations, Xt as buildTextContrastShadow, Y as createContentEntryRef, Yn as FILE_SIZE_LIMITS, Yr as defaultThemeTokens, Yt as footerForegroundCandidates, Z as createEventSeriesRef, Zn as classifyKnownMimeType, Zr as surfaceForegroundInputFromResolved, Zt as generateNavLinkCSS, _n as summarizePortableMediaReferences, _r as eventListTreatmentValues, _t as arrangementManifestFromVariants, ai as __toESM, an as deriveSectionGround, ar as resolveEffectiveKnobs, b as isEventVisibility, bn as looksLikeUuid, br as headingDecorationColorTokenValues, bt as resolveModeArrangement, c as customLinkSchema$1, cn as resolveSectionBackground, ct as headerLeafTextColor, d as internalLinkSchema, dn as boxBackgroundOverlaySchema, dt as mergeHeaderNavTypographyPreference, ei as expandPalette, er as renderCssDeclarations, et as createNavigationRef, f as internalResolvedLinkSchema, fn as boxBackgroundSchema, fr as asSiteStyleId, ft as readHeaderNavFontSizePreference, g as linkSchema, gn as collectPortableMediaReferencesFromContent, gr as defineNoBlockDesignCapability, gt as resolveLookSlotSurfaces, h as isResolvedInternalLinkEntityType, hn as stripStaleTransitionStyleGroup, hr as defineFrameCapability, ht as resolveItemSurface, ii as __commonJSMin, in as sectionFactsForContent, ir as defineBlockDesignMetadata, it as refSlug, j as eventManagementTiming, jn as persistableMediaSchema, jr as serializeSurfaceTree, jt as getHeaderPaintTargets, kn as isSiteScopedDirectImageStoragePath, kr as parseSurfaceTree, kt as generateHeaderScrollTreatmentStyles, l as entryLinkSchema$1, ln as resolveSectionPhotoPlacement, lr as asDesignBlockId, lt as transparentHeaderForegroundInput, mn as siteChromeBackgroundOverrideOwner, mr as defineBlockDesignCapability, mt as arrangementSlotNames, ni as parseThemeColorToken, nn as boundaryLayout, nr as cardVariantRoleValues, o as classifySdkEventBookingOffer, on as heroPhotoPaintsGround, or as cardListFamilyBlocks, ot as effectiveHeaderNavLinkStyle, p as internalRouteOnlyLinkSchema, pn as runtimeBoxBackgroundSchema, pr as assertNever$11, pt as arrangementLookHooks, q as createBlocksRef, qr as selectLogoVariant, qt as parseThemeForPersistence, ri as parseBlockColorToken, rn as composeBoundary, rr as normalizeCardRole, rt as createVenueRef, s as RESOLVED_INTERNAL_LINK_ENTITY_TYPES, sn as parseCanonicalRuntimeBackground, sr as cardListKnobBlocks, st as headerForegroundCandidates, t as classifySdkEventTiming, ti as getTextColorForBackground, tn as headerRootPaint, tr as cardRoleSchema, tt as createPageRef, u as externalLinkSchema$1, un as sectionForegroundBackground, ur as asLayoutVariantKey, ut as readOpeningForegroundProjection, v as pageLinkSchema$1, vn as walkAndCollectImageAttrs, vr as eyebrowTreatmentValues, vt as readStoredMode, w as stableStringify, wn as parseAspectRatioValue, wr as testimonialsCompositionTreatmentValues, wt as compiledRuntimeStyleFieldNames, xn as rotateNormalizedPoint, xr as introCompositionTreatmentValues, xt as resolvePublishedLook, yn as deleteEnvSpecificKeys, yr as featureCardCompositionTreatmentValues, yt as resolveEffectiveArrangement, z as eventCommandScheduleSchema, zn as parseMediaIdentifier, zr as textColorStyle, zt as getComponentBorderWidthPx } from "../sdk-event-upsert-DmNSeHgP.mjs";
|
|
3
|
+
import { $ as selectCategoryView, $t as parseNonNegativeCents, A as DEFAULT_MAILING_LIST_SUCCESS_MESSAGE, At as clampConfiguredAmount, B as parseWeeklyOpeningHours, Bt as formatBookingPriceDisplay, C as parseManagementKey, Ct as toUtcIsoDateTimeString, D as parseMailingListSignedSourceToken, Dt as isSettleableFlexibleBalanceContractStatus, E as parseMailingListContentVersionId, En as unsafeAsDemoCapability, Et as isLiveOrderInstalmentPlanStatus, F as DEFAULT_MAILING_LIST_TARGETING, Ft as splitAmountWithRemainderInFirst, G as locationValueSchema, Gt as publicEventPricingOptions, H as decideLocationSave, Ht as isPublicEventPricingOptionDisplayable, I as planMailingListChoicePresentation, In as unsafeAsPassId, It as resolveFlexibleBalanceDueAt, J as projectPublicLocation, Jt as resolvePricingOptionsPriceDisplay, K as normalizeLocationAddressText, Kt as publicEventPricingType, L as isCanonicalRichTextDoc, Ln as unsafeAsPositiveByteCount, Lt as resolveFlexibleBalanceInitialPaymentCents, M as parseFooterCompositionV1, Mt as getBookingInstalmentPlanIntervalCount, Nn as unsafeAsMediaAssetId, Nt as getBookingInstalmentProtectedDepositAmountCents, O as parseMailingListRuntimeContext, Ot as isSettleableOrderInstalmentPlanStatus, P as parseMailingListPlacementTargeting, Pn as unsafeAsOccurrenceId, Pt as omitZeroAmountFutureRows, Q as mapDrawingSchema, Qt as isNonNegativeWholeCents$1, R as formatOpeningHoursRows, Rt as deriveTotalTicketQuantity, S as exposeSecret, St as toScheduledBookingDateTime, T as parseMailingListBlockId, Tt as validateBookingPaymentOptionKinds, Ut as publicEventPricingCurrency, V as assertAllowedPublicUrl, Vt as formatEventPricing, W as locationMapLinks, Wt as publicEventPricingDisplay, X as toLocationCoordinates, Xn as err, Y as publicLocationSchema$1, Yt as fromArray, Zn as ok, Zt as mapReadonlyNonEmptyArray, _ as nextLiveRunSessionStartMs, _n as parseRetiredCourseId, _t as parseLocalScheduleTime, an as formatCurrencyAmount, at as formatTimeRange, b as resolveWholeSeriesRunLifecycle, bn as parseUserId, bt as resolveBookingTimeZoneId, cn as formatDurationUnitLabel, ct as buildBookingUtcDateWindow, d as EVENT_PRESET_VALUES, dn as parseDatedOfferingCapacityHoldAuditRef, dt as formatLocalScheduleTime, en as parsePositiveCents, et as formatDate, fn as parseDatedOfferingCapacityHoldId, ft as getBookingLocalDateKey, g as CANCELLED_SESSION_STATUS, gt as parseBookingLocalDate, hn as parseMembershipId, i as NAVIGATION_LOCATIONS, in as unsafeAsPositiveCents, it as formatTime$1, j as parseMailingListProviderScope, jt as getBookingInstalmentDepositRefundability, k as assessMailingListTargeting, kn as unsafeAsEventInstanceId, kt as addIntervalPreservingMonthAnchor, l as resolveSiteVerticalBookingConfig, ln as parseApiKeyId, lt as compareLocalScheduleDates, m as WHOLE_SERIES_EVENT_PRESET_VALUES, mt as getLocalScheduleTime, nn as toNonNegativeCents, nt as formatDateTime, on as parseCurrencyCode, ot as inferSiteDateLocale, p as SURFACE_EVENT_PRESET_VALUES, pn as parseEventSeriesId, pt as getLocalScheduleDate, q as parseLocationValue, qt as resolveExactOrFreePriceDisplay, r as EVENT_PRESET_VOCABULARY, rn as unsafeAsNonNegativeCents, rt as formatDateTimeRange, sn as assertNever, st as resolveBookingDisplayContext, tn as toCents, tt as formatDateRange, un as parseCustomerId, ut as formatLocalScheduleDate, v as orderedLiveRunSessions, vn as parseSiteId, vt as parseUtcIsoDateTimeString, w as slugify, wn as unsafeAsCheckoutLineId, x as createSecret, xt as toBookingTimeZone, y as resolveWholeSeriesBookingPhase, yn as parseSiteTermsVersionId, yt as resolveBookingBusinessTimeZone, zn as unsafeAsPricingOptionId, zt as parseEventPageSurfaceSubject } from "../src-B03aw4Tv.mjs";
|
|
4
|
+
import { $ as normalizeMediaValueToIdentifierOnly, $t as bindRequestTimeout, A as formatDiffDetail, An as transportSuggestion, At as navigationIdentity, B as buildFieldChanges, Bn as sdkEventScheduleSchema, Bt as preparePushConfigTarget, C as reportFromOutcomes, Cn as parseEnvironmentSelection, Ct as fileExists, D as normalizeRemoteHomepageReference, Dn as withRiverbankEnv, Dt as writeJsonFileAtomic, E as createEmptySyncResult, En as requireEnvironmentWriteAuthorization, Et as writeJsonFile, F as calculatePullDiff, Fn as isLocalConfigured, Ft as navigationCommandItemToManagementInput, G as syncLocalMediaForPull, Gt as APPOINTMENT_SERVICE_VISIBILITY_VALUES, H as formatFieldPath, Hn as linkPayloadSchema, Ht as extractApiErrorMessage, I as buildJsonDiff, In as isRemoteConfigured, It as normalizeNavigationConfigItemForCommand, J as admitBinaryWriteDestination, Jt as ApiEnvelopeError, K as applyLocalMediaPush, Kt as ApiRequestError, L as hasPageOperations, Ln as loadSdkEnvironment, Lt as applyPushConfigPlan, M as hasPendingChanges, Mt as convertPulledFooterToLocal, N as findChangedFieldsWithValues, Nn as getEnvPrefix, Nt as convertPulledNavigationToLocal, O as calculateDiff, On as ErrorCodes, Ot as isMediaValue, P as formatHumanDiff, Pn as getEnvironmentDebugInfo, Pt as convertPulledPagesToLocal, Q as normalizeMediaIdentifierInput, Qt as mapEnvironmentExecutionOutcomesJson, R as pageMetadataForUpsert, Rn as createManagementClient, Rt as createPushConfigCommand, S as planCliCommandBatchForBindings, Sn as executeEnvironmentPlan, St as ensureDir, T as executeResidualSettingsSyncPlan, Tn as planEnvironmentWriteAuthorization, Tt as readJsonFile, U as revalidateLocalMediaPushPlan, Un as portablePageDesignSchema, Ut as normalizeApiError, V as formatFieldChange, Vn as sdkSettingsUpdateSchema, Vt as revalidatePushConfigPlan, Wn as sdkConfiguredBookingVerticalConfigSchema, Wt as isRecord$2, X as writeBinaryFileAtomic, Xt as deriveCmsApiUrlFromDashboardUrl, Y as readStableBinaryFile, Yt as unwrapResponse, Z as sha256, Zt as API_ENDPOINTS, _ as commandExecutionToReport, _n as runWithInvocation, _t as metadataFilePath, a as executeEntryCommandPlanAsReport, an as createOutputForCommand, at as readEntries, b as executeCompiledCliCommandPlanAsReport, bn as withErrorHandling, bt as writeMetadataFile, c as titleFromEntryData, cn as getOutputContext, ct as readEventsMeta, d as unsafeAsCliEntryIdentifier, dn as managementClientConfigFor, dt as readNavigationMeta, en as confirmAction, et as walkLocalContentMedia, f as unsafeAsCliFormSlug, fn as mapEntryForOutput, ft as readPagesMeta, g as commandCompileFailureToReport, gn as resolveCommandPath, gt as ensureMetadataDir, h as mutationCounterForEffect, hn as parsePaginationOptions, ht as writeMediaManifest, i as entrySiteCommandTypes, in as createListCommand, it as findLegacyEntryFiles, j as formatDiffSummary, jn as CliExit, jt as navigationIdentityMap, k as calculateFooterDiff, kn as formatError, kt as duplicateNavigationIdentityMessage, l as unsafeAsCliBlockIdentifier, ln as getOutputOnlyContext, lt as readFooterMeta, m as commandReportToSyncResult, mn as parseJsonData, mt as readVenuesMeta, n as entryCommandCompileErrorToReport, nn as createCommandContext, nt as downloadMedia, o as executeEntryCommandPlanAsSyncResult, on as currentInvocationEnvelope, ot as readAllMeta, p as unsafeAsCliPageIdentifier, pn as parseJsonArray, pt as readSettingsMeta, q as prepareLocalMediaForPush, qt as createBearerAPIClient, r as entryCommandReportToSyncResult, rn as createGetCommand, rt as extractMediaIdentifiers, s as syncResultForEntryCommandCompileError, sn as formatDateShort, st as readEventCategoriesMeta, t as compileEntryPushCommands, tn as createClientForEnv, tt as buildStorageUrl, u as unsafeAsCliContentTypeKey, un as handleCommandError, ut as readFormsMeta, v as commandReportHasFailures, vn as withCommandContext, vt as metadataTargetFromEnvironment, w as mergeManySyncResults, wn as planEnvironmentExecution, wt as listFiles, x as formatManagementError, xn as withOutputOnlyErrorHandling, xt as writeMetadataRecordMap, y as executeCliCommandPlan, yn as withConfirmation, yt as readMetadataFile, zn as ManagementApiError, zt as loadPushConfigTarget } from "../entryCommands-C0xbLW5L.mjs";
|
|
5
|
+
import { r as CLI_VERSION, t as loadConfigFile } from "../load-config-h2Ri_tDO.mjs";
|
|
6
|
+
import { a as RichTextDocSchema, c as isRecord$18, i as findUnfilledSentinels, n as buildEntryScaffold, o as isRichTextDoc, r as validateEntryInstance, s as isObjectRecord, t as eventUpsertInputSchema } from "../eventUpsertInputSchema-C-cDv9vR.mjs";
|
|
7
|
+
import { a as prepareScaffoldExecution, c as LOCAL_PACKAGE_VENDOR_DIR, d as loadGeneratedPackageRanges, i as preflightScaffoldTargets, n as createScaffoldCompletion, s as deriveScaffoldLocalManifest, t as deriveScaffoldPlan } from "../plan-Dyv1rMTT.mjs";
|
|
8
8
|
import { config } from "dotenv";
|
|
9
9
|
import { Command, CommanderError } from "commander";
|
|
10
10
|
import * as fs$2 from "fs/promises";
|
|
@@ -386,8 +386,10 @@ async function writeVenues(contentDir, pulledVenues, options) {
|
|
|
386
386
|
description: venue.description,
|
|
387
387
|
timezone: venue.timezone,
|
|
388
388
|
capacity: venue.capacity,
|
|
389
|
-
|
|
390
|
-
|
|
389
|
+
...venue.locationValue !== undefined ? { locationValue: venue.locationValue } : {
|
|
390
|
+
address: venue.address,
|
|
391
|
+
location: venue.location
|
|
392
|
+
},
|
|
391
393
|
mapEmbed: venue.mapEmbed
|
|
392
394
|
});
|
|
393
395
|
filePaths.push(filePath);
|
|
@@ -2132,18 +2134,7 @@ function calculateFooterPullDiff(args) {
|
|
|
2132
2134
|
}
|
|
2133
2135
|
return { type: "unchanged" };
|
|
2134
2136
|
}
|
|
2135
|
-
|
|
2136
|
-
return {
|
|
2137
|
-
slug: v$1.slug,
|
|
2138
|
-
title: v$1.title,
|
|
2139
|
-
description: v$1.description,
|
|
2140
|
-
timezone: v$1.timezone,
|
|
2141
|
-
capacity: v$1.capacity,
|
|
2142
|
-
address: v$1.address,
|
|
2143
|
-
location: v$1.location,
|
|
2144
|
-
mapEmbed: v$1.mapEmbed
|
|
2145
|
-
};
|
|
2146
|
-
}
|
|
2137
|
+
const mapRemoteVenueToLocalComparable = mapLocalVenueToComparable;
|
|
2147
2138
|
function mapLocalVenueToComparable(v$1) {
|
|
2148
2139
|
return {
|
|
2149
2140
|
slug: v$1.slug,
|
|
@@ -2151,8 +2142,10 @@ function mapLocalVenueToComparable(v$1) {
|
|
|
2151
2142
|
description: v$1.description,
|
|
2152
2143
|
timezone: v$1.timezone,
|
|
2153
2144
|
capacity: v$1.capacity,
|
|
2154
|
-
|
|
2155
|
-
|
|
2145
|
+
...v$1.locationValue !== undefined ? { locationValue: v$1.locationValue } : {
|
|
2146
|
+
address: v$1.address,
|
|
2147
|
+
location: v$1.location
|
|
2148
|
+
},
|
|
2156
2149
|
mapEmbed: v$1.mapEmbed
|
|
2157
2150
|
};
|
|
2158
2151
|
}
|
|
@@ -4773,6 +4766,7 @@ function venueCommand(venue) {
|
|
|
4773
4766
|
type: "upsertVenue",
|
|
4774
4767
|
ref: createVenueRef([venue.slug]),
|
|
4775
4768
|
input: {
|
|
4769
|
+
...venue.locationValue !== undefined ? { locationValue: venue.locationValue } : {},
|
|
4776
4770
|
slug: venue.slug,
|
|
4777
4771
|
title: venue.title,
|
|
4778
4772
|
description: venue.description ?? undefined,
|
|
@@ -4947,7 +4941,7 @@ function compileDatedOfferingPushCommands(input) {
|
|
|
4947
4941
|
}
|
|
4948
4942
|
/** One Event graph contains all its run commands, so write it only once. */
|
|
4949
4943
|
function uniqueDatedOfferingCommands(plan) {
|
|
4950
|
-
return plan.reportedCommands.filter((reported, index, commands) => reported.plannedCommand.command.type !== "upsertEventSeries" || commands.findIndex((candidate) => candidate.plannedCommand.command.type === "upsertEventSeries" && candidate.reportSubject.identifier === reported.reportSubject.identifier) === index);
|
|
4944
|
+
return plan.reportedCommands.filter((reported, index, commands$1) => reported.plannedCommand.command.type !== "upsertEventSeries" || commands$1.findIndex((candidate) => candidate.plannedCommand.command.type === "upsertEventSeries" && candidate.reportSubject.identifier === reported.reportSubject.identifier) === index);
|
|
4951
4945
|
}
|
|
4952
4946
|
async function executeDatedOfferingCommand(input, reported) {
|
|
4953
4947
|
const command = reported.plannedCommand.command;
|
|
@@ -5134,8 +5128,8 @@ function eventGraphCommands(compiledPlan, eventIdentifier) {
|
|
|
5134
5128
|
return candidate.reportSubject.identifier === eventIdentifier && command.type === "upsertEventSeries" ? [command] : [];
|
|
5135
5129
|
});
|
|
5136
5130
|
}
|
|
5137
|
-
function eventGraphUpsertInput(attendeeNotification, commands) {
|
|
5138
|
-
const [firstCommand, ...remainingCommands] = commands;
|
|
5131
|
+
function eventGraphUpsertInput(attendeeNotification, commands$1) {
|
|
5132
|
+
const [firstCommand, ...remainingCommands] = commands$1;
|
|
5139
5133
|
if (!firstCommand) throw new Error("Validated Event graph has no run commands");
|
|
5140
5134
|
const first = eventSeriesUpsertInput(firstCommand);
|
|
5141
5135
|
const additionalRuns = remainingCommands.map((command) => eventSeriesUpsertInput(command).runs[0]);
|
|
@@ -5641,8 +5635,8 @@ function findCompiledBookingSettingsPlan(compiled) {
|
|
|
5641
5635
|
return undefined;
|
|
5642
5636
|
}
|
|
5643
5637
|
function requireSingleBookingCommand(compiled) {
|
|
5644
|
-
const commands = compiled.plan.commands;
|
|
5645
|
-
return commands.length === 1 && commands[0] !== undefined ? ok(commands[0].command) : err(new Error(`Booking settings command compilation produced ${commands.length} commands; expected exactly one.`));
|
|
5638
|
+
const commands$1 = compiled.plan.commands;
|
|
5639
|
+
return commands$1.length === 1 && commands$1[0] !== undefined ? ok(commands$1[0].command) : err(new Error(`Booking settings command compilation produced ${commands$1.length} commands; expected exactly one.`));
|
|
5646
5640
|
}
|
|
5647
5641
|
function operationInputForMode(input, command) {
|
|
5648
5642
|
const { plan: _plan, ...operation } = input;
|
|
@@ -7082,7 +7076,7 @@ const uiSchema = z.object({
|
|
|
7082
7076
|
"behavior",
|
|
7083
7077
|
"style"
|
|
7084
7078
|
]).optional(),
|
|
7085
|
-
valueContract: z.enum(["boxBackground"]).optional()
|
|
7079
|
+
valueContract: z.enum(["boxBackground", "location"]).optional()
|
|
7086
7080
|
}).partial().superRefine((ui, ctx) => {
|
|
7087
7081
|
if (ui.layoutGridColumns !== undefined && ui.layoutGridColumnsFields !== undefined) {
|
|
7088
7082
|
ctx.addIssue({
|
|
@@ -7696,7 +7690,9 @@ function canonicalizeObjectForWrite(plans, value) {
|
|
|
7696
7690
|
function canonicalizeFieldValue(plan, value) {
|
|
7697
7691
|
switch (plan.kind) {
|
|
7698
7692
|
case "media": return canonicalizeMedia(value);
|
|
7699
|
-
case "group":
|
|
7693
|
+
case "group":
|
|
7694
|
+
if (plan.valueContract === "location") return value;
|
|
7695
|
+
return plan.childSelection.kind === "discriminatedTabs" ? canonicalizeDiscriminatedGroup(plan, value) : canonicalizeObjectForWrite(plan.childSelection.fields, value);
|
|
7700
7696
|
case "repeater": return canonicalizeRepeater(plan, value);
|
|
7701
7697
|
case "string":
|
|
7702
7698
|
case "number":
|
|
@@ -9427,7 +9423,7 @@ function pluralize(label, count) {
|
|
|
9427
9423
|
return label.endsWith("s") ? label : `${label}s`;
|
|
9428
9424
|
}
|
|
9429
9425
|
function valueContractForField(field) {
|
|
9430
|
-
return field.ui?.valueContract
|
|
9426
|
+
return field.ui?.valueContract !== undefined ? { valueContract: field.ui.valueContract } : {};
|
|
9431
9427
|
}
|
|
9432
9428
|
function deriveTabGroupValidationPlan(field, path$3, required) {
|
|
9433
9429
|
return {
|
|
@@ -9541,7 +9537,8 @@ function deriveFieldValidationPlan(field, path$3 = [field.id]) {
|
|
|
9541
9537
|
kind: "all",
|
|
9542
9538
|
fields: deriveNestedFieldPlans(field.schema?.fields ?? [], path$3)
|
|
9543
9539
|
},
|
|
9544
|
-
allowNullChildren: field.type === "group" && field.ui?.widget === "locationPicker"
|
|
9540
|
+
allowNullChildren: field.type === "group" && field.ui?.widget === "locationPicker",
|
|
9541
|
+
...valueContractForField(field)
|
|
9545
9542
|
};
|
|
9546
9543
|
case "tabGroup": return deriveTabGroupValidationPlan(field, path$3, required);
|
|
9547
9544
|
case "presetOrCustom":
|
|
@@ -9770,7 +9767,9 @@ function normalizeStoredFieldValueWithContext(plan, value, ctx) {
|
|
|
9770
9767
|
return undefined;
|
|
9771
9768
|
}
|
|
9772
9769
|
switch (plan.kind) {
|
|
9773
|
-
case "group":
|
|
9770
|
+
case "group":
|
|
9771
|
+
if (plan.valueContract === "location") return normalizeLocationContract(value, ctx.mode);
|
|
9772
|
+
return normalizeStoredObjectChildren(selectedGroupChildPlans(plan, value), value, childValidationContext(plan, ctx));
|
|
9774
9773
|
case "repeater": return normalizeStoredRepeaterItems(plan, value, ctx);
|
|
9775
9774
|
case "string":
|
|
9776
9775
|
case "number":
|
|
@@ -9821,7 +9820,9 @@ function normalizeFieldValue(plan, value, ctx) {
|
|
|
9821
9820
|
switch (plan.kind) {
|
|
9822
9821
|
case "number": return normalizeNumberInput(value, ctx.allowNull);
|
|
9823
9822
|
case "string": return acceptsOptionalBlankAsMissing(plan, value) ? undefined : value;
|
|
9824
|
-
case "group":
|
|
9823
|
+
case "group":
|
|
9824
|
+
if (plan.valueContract === "location") return normalizeLocationContract(value, ctx.mode);
|
|
9825
|
+
return normalizeObjectChildren(selectedGroupChildPlans(plan, value), value, childValidationContext(plan, ctx));
|
|
9825
9826
|
case "repeater": return normalizeRepeaterItems(plan, value, ctx);
|
|
9826
9827
|
case "link":
|
|
9827
9828
|
case "boolean":
|
|
@@ -9915,7 +9916,7 @@ function acceptsNullValue(plan, ctx) {
|
|
|
9915
9916
|
return ctx.mode === "storable" ? !plan.required : ctx.allowNull || acceptsOptionalNullValue(plan);
|
|
9916
9917
|
}
|
|
9917
9918
|
function acceptsOptionalNullValue(plan) {
|
|
9918
|
-
return !plan.required && (plan.kind === "media" || plan.kind === "number");
|
|
9919
|
+
return !plan.required && (plan.kind === "media" || plan.kind === "number" || plan.kind === "group" && plan.valueContract === "location");
|
|
9919
9920
|
}
|
|
9920
9921
|
function isMissingForPlan(plan, value, mode) {
|
|
9921
9922
|
if (value === undefined) return true;
|
|
@@ -10088,6 +10089,7 @@ function validateFlattenedGroupContainers(groupIds, item, plan, index, ctx) {
|
|
|
10088
10089
|
}] : []);
|
|
10089
10090
|
}
|
|
10090
10091
|
function validateGroupPlan(plan, value, ctx) {
|
|
10092
|
+
if (plan.valueContract === "location") return validateLocationGroupContract(plan, value, ctx);
|
|
10091
10093
|
if (!isPlainObject$6(value)) return [issue(plan, "wrongType", { expected: "an object" })];
|
|
10092
10094
|
if (plan.childSelection.kind === "discriminatedTabs") {
|
|
10093
10095
|
const selectedType = value[plan.childSelection.activeTabField];
|
|
@@ -10103,10 +10105,7 @@ function validateGroupPlan(plan, value, ctx) {
|
|
|
10103
10105
|
const childCtx = childValidationContext(plan, ctx);
|
|
10104
10106
|
const childIssues = selectedGroupChildPlans(plan, value).flatMap((childPlan) => validateNormalizedFieldValue(childPlan, value[childPlan.fieldId], childCtx));
|
|
10105
10107
|
if (childIssues.length > 0) return childIssues;
|
|
10106
|
-
|
|
10107
|
-
return [issue(plan, "invalidBoxBackground")];
|
|
10108
|
-
}
|
|
10109
|
-
return [];
|
|
10108
|
+
return validateGroupBackgroundContract(plan, value, ctx);
|
|
10110
10109
|
}
|
|
10111
10110
|
function childValidationContext(plan, ctx) {
|
|
10112
10111
|
return plan.allowNullChildren ? {
|
|
@@ -10225,7 +10224,8 @@ function fieldPlanToStrictObjectPropertyZod(plan, mode = "strict", layoutGridCoo
|
|
|
10225
10224
|
addFieldIssueToZodContext(zodCtx, validationIssue, plan.path);
|
|
10226
10225
|
});
|
|
10227
10226
|
});
|
|
10228
|
-
|
|
10227
|
+
const projected = schema.transform((value) => mode === "render" && plan.kind === "group" && plan.valueContract === "location" ? normalizeLocationContract(value, "render") : value);
|
|
10228
|
+
return plan.required ? projected : projected.optional();
|
|
10229
10229
|
}
|
|
10230
10230
|
function fieldIssueToZodDetail(issue$1) {
|
|
10231
10231
|
if (issue$1.kind === "required") return issue$1.emptyOrigin ? {
|
|
@@ -10418,6 +10418,32 @@ function isEmptyRichTextDoc(value) {
|
|
|
10418
10418
|
const first = content[0];
|
|
10419
10419
|
return first?.type === "paragraph" && (!Array.isArray(first.content) || first.content.length === 0);
|
|
10420
10420
|
}
|
|
10421
|
+
function normalizeLocationContract(value, mode) {
|
|
10422
|
+
const canonical$1 = locationValueSchema.safeParse(value);
|
|
10423
|
+
if (canonical$1.success) return mode === "render" ? projectPublicLocation(canonical$1.data) : canonical$1.data;
|
|
10424
|
+
const publicValue = mode === "render" ? publicLocationSchema$1.safeParse(value) : null;
|
|
10425
|
+
return publicValue?.success ? publicValue.data : value;
|
|
10426
|
+
}
|
|
10427
|
+
function validateLocationGroupContract(plan, value, ctx) {
|
|
10428
|
+
if (isRenderLocationRecovery(value, ctx.mode)) return [];
|
|
10429
|
+
const schema = ctx.mode === "render" || ctx.mode === "render-source" ? z.union([locationValueSchema, publicLocationSchema$1]) : locationValueSchema;
|
|
10430
|
+
const parsed = schema.safeParse(value);
|
|
10431
|
+
if (!parsed.success) return [issue(plan, "wrongType", { expected: "a valid location" })];
|
|
10432
|
+
if (ctx.mode === "storable" || ctx.mode === "strict") {
|
|
10433
|
+
const canonical$1 = locationValueSchema.safeParse(value);
|
|
10434
|
+
if (canonical$1.success && decideLocationSave(canonical$1.data, "idle").kind === "blocked") return [issue(plan, "wrongType", { expected: "a confirmed address and pin" })];
|
|
10435
|
+
}
|
|
10436
|
+
return [];
|
|
10437
|
+
}
|
|
10438
|
+
function validateGroupBackgroundContract(plan, value, ctx) {
|
|
10439
|
+
if (plan.valueContract === "boxBackground" && !(ctx.mode === "render" ? runtimeBoxBackgroundSchema : boxBackgroundSchema).safeParse(value).success) {
|
|
10440
|
+
return [issue(plan, "invalidBoxBackground")];
|
|
10441
|
+
}
|
|
10442
|
+
return [];
|
|
10443
|
+
}
|
|
10444
|
+
function isRenderLocationRecovery(value, mode) {
|
|
10445
|
+
return (mode === "render" || mode === "render-source") && z.strictObject({ kind: z.literal("needs_place") }).safeParse(value).success;
|
|
10446
|
+
}
|
|
10421
10447
|
|
|
10422
10448
|
//#endregion
|
|
10423
10449
|
//#region ../blocks/src/system/manifest/fieldValidation/layoutGridRendering.ts
|
|
@@ -10465,7 +10491,7 @@ function projectLayoutGridPlansForRendering(plans, value, rootValues = layoutGri
|
|
|
10465
10491
|
if (!values) return value;
|
|
10466
10492
|
return plans.reduce((projected, plan) => {
|
|
10467
10493
|
const fieldValue = projected[plan.fieldId];
|
|
10468
|
-
const next = plan.kind === "group" ? projectLayoutGridPlansForRendering(allGroupChildPlans(plan), fieldValue, rootValues) : plan.kind === "repeater" && Array.isArray(fieldValue) ? projectGrid(plan, fieldValue, rootValues).map((item) => {
|
|
10494
|
+
const next = plan.kind === "group" && plan.valueContract === "location" ? recoverUnreadableLocation(fieldValue) : plan.kind === "group" ? projectLayoutGridPlansForRendering(allGroupChildPlans(plan), fieldValue, rootValues) : plan.kind === "repeater" && Array.isArray(fieldValue) ? projectGrid(plan, fieldValue, rootValues).map((item) => {
|
|
10469
10495
|
const row$1 = layoutGridRecord(item);
|
|
10470
10496
|
return row$1 ? projectLayoutGridPlansForRendering(resolveLayoutGridItemPlans(plan, row$1), row$1, rootValues) : item;
|
|
10471
10497
|
}) : fieldValue;
|
|
@@ -10475,6 +10501,11 @@ function projectLayoutGridPlansForRendering(plans, value, rootValues = layoutGri
|
|
|
10475
10501
|
};
|
|
10476
10502
|
}, values);
|
|
10477
10503
|
}
|
|
10504
|
+
/** Render recovery drops unreadable meaning rather than interpreting obsolete coordinates. */
|
|
10505
|
+
function recoverUnreadableLocation(value) {
|
|
10506
|
+
if (value == null || locationValueSchema.safeParse(value).success || publicLocationSchema$1.safeParse(value).success) return value;
|
|
10507
|
+
return { kind: "needs_place" };
|
|
10508
|
+
}
|
|
10478
10509
|
|
|
10479
10510
|
//#endregion
|
|
10480
10511
|
//#region ../blocks/src/system/manifest/validation.ts
|
|
@@ -10539,7 +10570,7 @@ function unknownManifestFieldPaths(plans, value, parent = [], discriminator) {
|
|
|
10539
10570
|
}
|
|
10540
10571
|
function nestedUnknownManifestFieldPaths(plan, value, path$3) {
|
|
10541
10572
|
if (plan.kind === "group") {
|
|
10542
|
-
if (plan.valueContract
|
|
10573
|
+
if (plan.valueContract !== undefined) return [];
|
|
10543
10574
|
const selection = plan.childSelection;
|
|
10544
10575
|
return unknownManifestFieldPaths(allGroupChildPlans(plan), value, path$3, selection.kind === "discriminatedTabs" ? selection.activeTabField : undefined);
|
|
10545
10576
|
}
|
|
@@ -10699,7 +10730,7 @@ function deriveRenderableManifestContent(contract, stored, project) {
|
|
|
10699
10730
|
const parsed = state.renderSchema.safeParse(projected);
|
|
10700
10731
|
return parsed.success ? {
|
|
10701
10732
|
ok: true,
|
|
10702
|
-
value:
|
|
10733
|
+
value: parsed.data
|
|
10703
10734
|
} : {
|
|
10704
10735
|
ok: false,
|
|
10705
10736
|
error: zodAdmissionError(parsed.error)
|
|
@@ -10716,7 +10747,7 @@ function admitTransportedRenderableManifestContent(contract, content) {
|
|
|
10716
10747
|
const parsed = state.renderSchema.safeParse(projected);
|
|
10717
10748
|
return parsed.success ? {
|
|
10718
10749
|
ok: true,
|
|
10719
|
-
value:
|
|
10750
|
+
value: parsed.data
|
|
10720
10751
|
} : {
|
|
10721
10752
|
ok: false,
|
|
10722
10753
|
error: zodAdmissionError(parsed.error)
|
|
@@ -10744,7 +10775,7 @@ function deriveContentZodFromPlans(plans, options, validateLayoutGrids = true) {
|
|
|
10744
10775
|
});
|
|
10745
10776
|
}
|
|
10746
10777
|
function deriveStrictContentZodFromPlans(plans, mode = "strict") {
|
|
10747
|
-
const shape = Object.fromEntries(plans.map((plan) => [plan.fieldId, fieldPlanToStrictObjectPropertyZod(plan, mode
|
|
10778
|
+
const shape = Object.fromEntries(plans.map((plan) => [plan.fieldId, fieldPlanToStrictObjectPropertyZod(plan, mode, mode === "strict" ? "validate" : "projected")]));
|
|
10748
10779
|
return z.object(shape).catchall(z.unknown()).passthrough().superRefine((values, ctx) => {
|
|
10749
10780
|
if (mode !== "strict") return;
|
|
10750
10781
|
validateLayoutGridPlans(plans, values).forEach((issue$1) => {
|
|
@@ -10836,7 +10867,7 @@ function collectNonPortablePlannedMedia(plans, content, parentPath, paths) {
|
|
|
10836
10867
|
visitPlannedMedia(plans, content, parentPath, (value, path$3, kind) => {
|
|
10837
10868
|
if (kind === "richText") {
|
|
10838
10869
|
collectNonPortableRichTextImages(value, path$3, paths);
|
|
10839
|
-
} else if (
|
|
10870
|
+
} else if (value !== null && value !== undefined && !mediaSchema.safeParse(value).success) {
|
|
10840
10871
|
paths.add(formatFieldPath$1(path$3));
|
|
10841
10872
|
}
|
|
10842
10873
|
});
|
|
@@ -10857,10 +10888,6 @@ function isPlainRecord$1(value) {
|
|
|
10857
10888
|
function hasEnvironmentSpecificMediaField(value) {
|
|
10858
10889
|
return "assetId" in value || "storageBucket" in value || "storagePath" in value || "src" in value || "mimeType" in value || looksLikeUuid(value.id);
|
|
10859
10890
|
}
|
|
10860
|
-
function hasNonPortablePoster(value) {
|
|
10861
|
-
if (value.poster === undefined) return false;
|
|
10862
|
-
return !mediaPosterSchema.safeParse(value.poster).success;
|
|
10863
|
-
}
|
|
10864
10891
|
|
|
10865
10892
|
//#endregion
|
|
10866
10893
|
//#region src/sync/validation.ts
|
|
@@ -11076,11 +11103,12 @@ function createVariantField(manifest) {
|
|
|
11076
11103
|
return null;
|
|
11077
11104
|
}
|
|
11078
11105
|
const variantKeys = Object.keys(manifest.variants).filter((key) => !manifest.variantMeaning.lookOnlyKeys?.includes(key));
|
|
11106
|
+
if (variantKeys.length === 0) return null;
|
|
11079
11107
|
const field = {
|
|
11080
11108
|
id: "variant",
|
|
11081
11109
|
type: "select",
|
|
11082
|
-
label: "Variant",
|
|
11083
|
-
description: "Choose how this block is laid out.",
|
|
11110
|
+
label: manifest.variantMeaning.kind === "arrangement" ? "Layout" : "Variant",
|
|
11111
|
+
...manifest.variantMeaning.kind === "arrangement" ? {} : { description: "Choose how this block is laid out." },
|
|
11084
11112
|
ui: { intent: "display" },
|
|
11085
11113
|
required: false,
|
|
11086
11114
|
defaultValue: manifest.defaultVariant ?? variantKeys[0],
|
|
@@ -14285,6 +14313,20 @@ function resolveFooterRootForeground(footer, palette, proseHoverCandidate) {
|
|
|
14285
14313
|
}, palette, footerForegroundCandidates(footer, proseHoverCandidate), { compositeBase: "background" });
|
|
14286
14314
|
}
|
|
14287
14315
|
function resolveSurfaceForegroundStyles(value, context, options) {
|
|
14316
|
+
const resolved = cachedSectionSurface(value, context, options);
|
|
14317
|
+
const foreground = resolved.foreground;
|
|
14318
|
+
if (foreground.kind === "unknown") return { ...resolved.buttonStyles };
|
|
14319
|
+
return {
|
|
14320
|
+
...arrangementSurfaceInk(foreground, context),
|
|
14321
|
+
...resolved.buttonStyles,
|
|
14322
|
+
...surfaceForegroundStyle(surfaceForegroundInputFromResolved(foreground, (token) => resolveBackgroundColorValue(token, context)))
|
|
14323
|
+
};
|
|
14324
|
+
}
|
|
14325
|
+
/** The section ground's resolved foreground, for decorations drawn on that ground (maps). */
|
|
14326
|
+
function resolveSectionSurfaceForeground(value, context, options) {
|
|
14327
|
+
return cachedSectionSurface(value, context, options).foreground;
|
|
14328
|
+
}
|
|
14329
|
+
function cachedSectionSurface(value, context, options) {
|
|
14288
14330
|
const key = JSON.stringify([
|
|
14289
14331
|
value,
|
|
14290
14332
|
context.proseHoverCandidate,
|
|
@@ -14295,13 +14337,7 @@ function resolveSurfaceForegroundStyles(value, context, options) {
|
|
|
14295
14337
|
if (!sectionSurfaceCache.has(context.theme)) sectionSurfaceCache.set(context.theme, cache);
|
|
14296
14338
|
const resolved = cache.get(key) ?? resolveRuntimeSectionSurface(value, context, options);
|
|
14297
14339
|
cache.set(key, resolved);
|
|
14298
|
-
|
|
14299
|
-
if (foreground.kind === "unknown") return { ...resolved.buttonStyles };
|
|
14300
|
-
return {
|
|
14301
|
-
...arrangementSurfaceInk(foreground, context),
|
|
14302
|
-
...resolved.buttonStyles,
|
|
14303
|
-
...surfaceForegroundStyle(surfaceForegroundInputFromResolved(foreground, (token) => resolveBackgroundColorValue(token, context)))
|
|
14304
|
-
};
|
|
14340
|
+
return resolved;
|
|
14305
14341
|
}
|
|
14306
14342
|
/** Cache only the owner's result; no foreground or button rules live here. */
|
|
14307
14343
|
function resolveRuntimeSectionSurface(value, context, options) {
|
|
@@ -15835,7 +15871,7 @@ const heroCopyFragment = defineFragment({
|
|
|
15835
15871
|
{
|
|
15836
15872
|
id: "eyebrow",
|
|
15837
15873
|
type: "text",
|
|
15838
|
-
label: "
|
|
15874
|
+
label: "Small heading above the title",
|
|
15839
15875
|
description: "Optional short line above the headline",
|
|
15840
15876
|
visibleRoles: ["designer", "admin"]
|
|
15841
15877
|
},
|
|
@@ -16035,7 +16071,7 @@ function createButtonGroup(options = {}) {
|
|
|
16035
16071
|
//#endregion
|
|
16036
16072
|
//#region ../blocks/src/system/fields/ctas.ts
|
|
16037
16073
|
function createCtasRepeater(options = {}) {
|
|
16038
|
-
const { id = "ctas", label = "
|
|
16074
|
+
const { id = "ctas", label = "Buttons", itemLabel = "Button", minItems = 0, maxItems, button: button$1, defaultValue } = options;
|
|
16039
16075
|
const fieldId = id;
|
|
16040
16076
|
const buttonField = createButtonGroup({
|
|
16041
16077
|
showGroupLabel: false,
|
|
@@ -16065,8 +16101,8 @@ const ctaRowFragment = defineFragment({
|
|
|
16065
16101
|
title: "CTA Row",
|
|
16066
16102
|
description: "Repeatable calls to action rendered inline.",
|
|
16067
16103
|
fields: [createCtasRepeater({
|
|
16068
|
-
label: "
|
|
16069
|
-
itemLabel: "
|
|
16104
|
+
label: "Buttons",
|
|
16105
|
+
itemLabel: "Button",
|
|
16070
16106
|
maxItems: 3
|
|
16071
16107
|
})],
|
|
16072
16108
|
layout: [ctaRow({
|
|
@@ -16080,8 +16116,8 @@ const ctaRowFragment = defineFragment({
|
|
|
16080
16116
|
//#endregion
|
|
16081
16117
|
//#region ../blocks/src/system/fragments/library/heroCtaRow.ts
|
|
16082
16118
|
const heroCtaFields = [createCtasRepeater({
|
|
16083
|
-
label: "
|
|
16084
|
-
itemLabel: "
|
|
16119
|
+
label: "Buttons",
|
|
16120
|
+
itemLabel: "Button",
|
|
16085
16121
|
maxItems: 3,
|
|
16086
16122
|
defaultValue: [],
|
|
16087
16123
|
button: {
|
|
@@ -16149,7 +16185,7 @@ const ctaCopyFragment = defineFragment({
|
|
|
16149
16185
|
{
|
|
16150
16186
|
id: "eyebrow",
|
|
16151
16187
|
type: "text",
|
|
16152
|
-
label: "
|
|
16188
|
+
label: "Small heading above the title",
|
|
16153
16189
|
description: "Optional short line above the title",
|
|
16154
16190
|
visibleRoles: ["designer", "admin"]
|
|
16155
16191
|
},
|
|
@@ -17028,7 +17064,7 @@ const faqHeadingFragment = defineFragment({
|
|
|
17028
17064
|
{
|
|
17029
17065
|
id: "eyebrow",
|
|
17030
17066
|
type: "text",
|
|
17031
|
-
label: "
|
|
17067
|
+
label: "Small heading above the title",
|
|
17032
17068
|
description: "Short label displayed above the title.",
|
|
17033
17069
|
visibleRoles: ["designer", "admin"],
|
|
17034
17070
|
maxLength: 60
|
|
@@ -18778,6 +18814,11 @@ const heroConfig = {
|
|
|
18778
18814
|
]
|
|
18779
18815
|
},
|
|
18780
18816
|
defaultVariant: "classic",
|
|
18817
|
+
variantOptions: {
|
|
18818
|
+
micro: { label: "Compact" },
|
|
18819
|
+
split: { label: "Split, photo on the left" },
|
|
18820
|
+
splitReverse: { label: "Split, photo on the right" }
|
|
18821
|
+
},
|
|
18781
18822
|
description: "A big opening headline, with a short line underneath and buttons.",
|
|
18782
18823
|
tags: [
|
|
18783
18824
|
"header",
|
|
@@ -19226,8 +19267,8 @@ const introConfig = {
|
|
|
19226
19267
|
}
|
|
19227
19268
|
}),
|
|
19228
19269
|
createCtasRepeater({
|
|
19229
|
-
label: "
|
|
19230
|
-
itemLabel: "
|
|
19270
|
+
label: "Buttons",
|
|
19271
|
+
itemLabel: "Button",
|
|
19231
19272
|
maxItems: 2
|
|
19232
19273
|
})
|
|
19233
19274
|
],
|
|
@@ -19952,6 +19993,17 @@ function resolvedItemSurfaceProps(surface, slot, style = undefined) {
|
|
|
19952
19993
|
}
|
|
19953
19994
|
};
|
|
19954
19995
|
}
|
|
19996
|
+
const resolvedSurfaceSchema = z.unknown().transform((value, context) => {
|
|
19997
|
+
try {
|
|
19998
|
+
return parseResolvedSurface(value);
|
|
19999
|
+
} catch {
|
|
20000
|
+
context.addIssue({
|
|
20001
|
+
code: "custom",
|
|
20002
|
+
message: "Invalid surface inputs"
|
|
20003
|
+
});
|
|
20004
|
+
return z.NEVER;
|
|
20005
|
+
}
|
|
20006
|
+
});
|
|
19955
20007
|
const lookListPresentationSchemaShape = {
|
|
19956
20008
|
sectionAction: z.object({
|
|
19957
20009
|
label: z.string(),
|
|
@@ -19995,10 +20047,10 @@ const lookListPresentationSchemaShape = {
|
|
|
19995
20047
|
"card",
|
|
19996
20048
|
"statement",
|
|
19997
20049
|
"highlight"
|
|
19998
|
-
]),
|
|
20050
|
+
]), resolvedSurfaceSchema).optional(),
|
|
19999
20051
|
panelHeading: z.string().optional(),
|
|
20000
20052
|
lookSlots: z.partialRecord(z.enum(arrangementSlotNames), z.enum(arrangementSlotNames)).optional(),
|
|
20001
|
-
itemSurfaces: z.record(z.string(),
|
|
20053
|
+
itemSurfaces: z.record(z.string(), resolvedSurfaceSchema).optional()
|
|
20002
20054
|
};
|
|
20003
20055
|
function listLookSlot(presentation, slot) {
|
|
20004
20056
|
const name = presentation.lookSlots?.[slot];
|
|
@@ -23231,7 +23283,7 @@ const testimonialsManifest = createBlockManifest({
|
|
|
23231
23283
|
},
|
|
23232
23284
|
promotedFields: ["maxEntries"],
|
|
23233
23285
|
title: "Testimonials",
|
|
23234
|
-
category: "
|
|
23286
|
+
category: "people",
|
|
23235
23287
|
contentSource: { kind: "inline" },
|
|
23236
23288
|
includeContainerStyles: true,
|
|
23237
23289
|
layout: carouselLayout$1,
|
|
@@ -24183,7 +24235,7 @@ const featureCardsConfig = {
|
|
|
24183
24235
|
{
|
|
24184
24236
|
id: "eyebrow",
|
|
24185
24237
|
type: "text",
|
|
24186
|
-
label: "
|
|
24238
|
+
label: "Small heading above the title",
|
|
24187
24239
|
required: false,
|
|
24188
24240
|
multiline: false,
|
|
24189
24241
|
maxLength: 80
|
|
@@ -24281,8 +24333,8 @@ const featureCardsConfig = {
|
|
|
24281
24333
|
ui: { richTextVariant: "limited" }
|
|
24282
24334
|
},
|
|
24283
24335
|
createCtasRepeater({
|
|
24284
|
-
label: "
|
|
24285
|
-
itemLabel: "
|
|
24336
|
+
label: "Buttons",
|
|
24337
|
+
itemLabel: "Button",
|
|
24286
24338
|
maxItems: 1,
|
|
24287
24339
|
button: { defaultVariant: "ghost" }
|
|
24288
24340
|
})
|
|
@@ -24623,7 +24675,7 @@ const textCardStylesField = (() => {
|
|
|
24623
24675
|
const mediaTextManifest = createBlockManifest({
|
|
24624
24676
|
id: "block.media-text",
|
|
24625
24677
|
title: "Media and text",
|
|
24626
|
-
category: "
|
|
24678
|
+
category: "text-and-images",
|
|
24627
24679
|
contentSource: { kind: "inline" },
|
|
24628
24680
|
includeContainerStyles: true,
|
|
24629
24681
|
titleSource: "title",
|
|
@@ -24661,7 +24713,7 @@ const mediaTextManifest = createBlockManifest({
|
|
|
24661
24713
|
{
|
|
24662
24714
|
id: "eyebrow",
|
|
24663
24715
|
type: "text",
|
|
24664
|
-
label: "
|
|
24716
|
+
label: "Small heading above the title",
|
|
24665
24717
|
description: "Optional short label above the title",
|
|
24666
24718
|
required: false,
|
|
24667
24719
|
multiline: false,
|
|
@@ -25561,6 +25613,7 @@ const publicEventDestinationSchema = z.discriminatedUnion("kind", [z.object({
|
|
|
25561
25613
|
* Zod schema for venue data
|
|
25562
25614
|
*/
|
|
25563
25615
|
const eventVenueSchema = z.object({
|
|
25616
|
+
drawing: z.lazy(() => mapDrawingSchema).optional().catch(undefined),
|
|
25564
25617
|
id: z.string(),
|
|
25565
25618
|
name: z.string(),
|
|
25566
25619
|
address: z.string().nullable(),
|
|
@@ -30458,7 +30511,7 @@ function MembershipHero({ membershipName, classPrefix, onBookForSomeoneElse }) {
|
|
|
30458
30511
|
* LICENSE file in the root directory of this source tree.
|
|
30459
30512
|
*/
|
|
30460
30513
|
var require_react_dom_production = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
30461
|
-
var React$
|
|
30514
|
+
var React$81 = require_react();
|
|
30462
30515
|
function formatProdErrorMessage(code) {
|
|
30463
30516
|
var url = "https://react.dev/errors/" + code;
|
|
30464
30517
|
if (1 < arguments.length) {
|
|
@@ -30495,7 +30548,7 @@ var require_react_dom_production = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
30495
30548
|
implementation
|
|
30496
30549
|
};
|
|
30497
30550
|
}
|
|
30498
|
-
var ReactSharedInternals = React$
|
|
30551
|
+
var ReactSharedInternals = React$81.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;
|
|
30499
30552
|
function getCrossOriginStringAs(as, input) {
|
|
30500
30553
|
if ("font" === as) return "";
|
|
30501
30554
|
if ("string" === typeof input) return "use-credentials" === input ? input : "";
|
|
@@ -30638,7 +30691,7 @@ var require_react_dom_development = /* @__PURE__ */ __commonJSMin(((exports) =>
|
|
|
30638
30691
|
return dispatcher;
|
|
30639
30692
|
}
|
|
30640
30693
|
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
|
|
30641
|
-
var React$
|
|
30694
|
+
var React$90 = require_react(), Internals$1 = {
|
|
30642
30695
|
d: {
|
|
30643
30696
|
f: noop$2,
|
|
30644
30697
|
r: function() {
|
|
@@ -30654,7 +30707,7 @@ var require_react_dom_development = /* @__PURE__ */ __commonJSMin(((exports) =>
|
|
|
30654
30707
|
},
|
|
30655
30708
|
p: 0,
|
|
30656
30709
|
findDOMNode: null
|
|
30657
|
-
}, REACT_PORTAL_TYPE$1 = Symbol.for("react.portal"), ReactSharedInternals$1 = React$
|
|
30710
|
+
}, REACT_PORTAL_TYPE$1 = Symbol.for("react.portal"), ReactSharedInternals$1 = React$90.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;
|
|
30658
30711
|
"function" === typeof Map && null != Map.prototype && "function" === typeof Map.prototype.forEach && "function" === typeof Set && null != Set.prototype && "function" === typeof Set.prototype.clear && "function" === typeof Set.prototype.forEach || console.error("React depends on Map and Set built-in types. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills");
|
|
30659
30712
|
exports.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE = Internals$1;
|
|
30660
30713
|
exports.createPortal = function(children, container) {
|
|
@@ -38623,66 +38676,92 @@ function transitionOrderRefundStatusTo(from, to) {
|
|
|
38623
38676
|
const unfinishedBookingAssistanceMessage = "We couldn’t safely find your unfinished booking. Please contact the organiser before trying to book again.";
|
|
38624
38677
|
const eventRegistrationErrors = {
|
|
38625
38678
|
registrationClosed: {
|
|
38679
|
+
endsCommand: false,
|
|
38626
38680
|
message: "Booking is currently closed for this event. Please contact the organiser if you’d like to find out more.",
|
|
38627
38681
|
action: "none"
|
|
38628
38682
|
},
|
|
38629
38683
|
paymentInvestigationRequired: {
|
|
38684
|
+
endsCommand: false,
|
|
38630
38685
|
message: "We still can’t confirm your payment. Please don’t make another payment. Contact the organiser so they can check your booking.",
|
|
38631
38686
|
action: "none"
|
|
38632
38687
|
},
|
|
38633
38688
|
paymentProviderUnavailable: {
|
|
38689
|
+
endsCommand: false,
|
|
38634
38690
|
message: "We couldn’t reach the payment provider. Please try again in a minute.",
|
|
38635
38691
|
action: "retry"
|
|
38636
38692
|
},
|
|
38637
38693
|
paymentHostUnavailable: {
|
|
38694
|
+
endsCommand: false,
|
|
38638
38695
|
message: "Card payments aren’t available on this web address yet. Please contact the organiser to book.",
|
|
38639
38696
|
action: "none"
|
|
38640
38697
|
},
|
|
38641
38698
|
paymentPageUnavailable: {
|
|
38699
|
+
endsCommand: false,
|
|
38642
38700
|
message: "We couldn’t open the payment page. Please refresh this page and try again. If this keeps happening, contact the organiser for help.",
|
|
38643
38701
|
action: "retry"
|
|
38644
38702
|
},
|
|
38645
38703
|
paymentUnavailable: {
|
|
38704
|
+
endsCommand: false,
|
|
38646
38705
|
message: "Online payment is not available for this event right now. Please contact the organiser for help with booking.",
|
|
38647
38706
|
action: "none"
|
|
38648
38707
|
},
|
|
38649
38708
|
capacityChanged: {
|
|
38709
|
+
endsCommand: false,
|
|
38650
38710
|
message: "Sorry, there aren’t enough places left for your selection. Please check the available places and choose again.",
|
|
38651
38711
|
action: "places"
|
|
38652
38712
|
},
|
|
38653
38713
|
selectionChanged: {
|
|
38714
|
+
endsCommand: false,
|
|
38654
38715
|
message: "The booking options for this event have changed. Please check the latest options and choose your places again.",
|
|
38655
38716
|
action: "places"
|
|
38656
38717
|
},
|
|
38718
|
+
paymentSetupFailed: {
|
|
38719
|
+
endsCommand: true,
|
|
38720
|
+
message: "We couldn't set up payment for this booking, so your place hasn't been reserved and you haven't been charged. Please try again in a few minutes, or contact the organiser if it keeps happening.",
|
|
38721
|
+
action: "retry"
|
|
38722
|
+
},
|
|
38723
|
+
registrationAttemptEnded: {
|
|
38724
|
+
endsCommand: true,
|
|
38725
|
+
message: "That booking attempt has ended, so we couldn't finish it. You haven't been charged. Please start your booking again.",
|
|
38726
|
+
action: "start"
|
|
38727
|
+
},
|
|
38657
38728
|
registrationPreparationChanged: {
|
|
38729
|
+
endsCommand: true,
|
|
38658
38730
|
message: "The booking options for this event have changed. Please check the latest options and choose your places again.",
|
|
38659
38731
|
action: "places"
|
|
38660
38732
|
},
|
|
38661
38733
|
registrationAlreadyExists: {
|
|
38734
|
+
endsCommand: false,
|
|
38662
38735
|
message: "You already have a booking for this event. Please check your bookings to see its status. If you need help, contact the organiser.",
|
|
38663
38736
|
action: "portal"
|
|
38664
38737
|
},
|
|
38665
38738
|
holdExpired: {
|
|
38739
|
+
endsCommand: false,
|
|
38666
38740
|
message: "Your reservation has timed out. Please check availability and choose your places again.",
|
|
38667
38741
|
action: "start"
|
|
38668
38742
|
},
|
|
38669
38743
|
waitlistUnavailable: {
|
|
38744
|
+
endsCommand: false,
|
|
38670
38745
|
message: "Sorry, the waiting list place offered in this invitation is no longer available. Please check the event for available places or contact the organiser for help.",
|
|
38671
38746
|
action: "event"
|
|
38672
38747
|
},
|
|
38673
38748
|
paymentContextMismatch: {
|
|
38749
|
+
endsCommand: false,
|
|
38674
38750
|
message: "The payment options for this event have changed. Please check the latest options before continuing.",
|
|
38675
38751
|
action: "payment-options"
|
|
38676
38752
|
},
|
|
38677
38753
|
verificationFailed: {
|
|
38754
|
+
endsCommand: false,
|
|
38678
38755
|
message: "We couldn’t confirm this request came from a person. Please refresh the page and try again.",
|
|
38679
38756
|
action: "none"
|
|
38680
38757
|
},
|
|
38681
38758
|
idempotencyConflict: {
|
|
38759
|
+
endsCommand: false,
|
|
38682
38760
|
message: "You’ve already started booking this event. Please finish in the other tab if it’s still open, or check your booking status before starting again.",
|
|
38683
38761
|
action: "portal"
|
|
38684
38762
|
},
|
|
38685
38763
|
invalidCommitInput: {
|
|
38764
|
+
endsCommand: false,
|
|
38686
38765
|
message: "We couldn’t accept your booking details. Please check the information you entered and try again. If this keeps happening, contact the organiser for help.",
|
|
38687
38766
|
action: "details"
|
|
38688
38767
|
}
|
|
@@ -38690,6 +38769,11 @@ const eventRegistrationErrors = {
|
|
|
38690
38769
|
function parseEventRegistrationErrorReason(value) {
|
|
38691
38770
|
return typeof value === "string" && Object.prototype.hasOwnProperty.call(eventRegistrationErrors, value) ? value : null;
|
|
38692
38771
|
}
|
|
38772
|
+
/** Only a server-confirmed refusal ends an identity; transport uncertainty retains it. */
|
|
38773
|
+
function eventRegistrationErrorEndsCommand(value) {
|
|
38774
|
+
const reason = parseEventRegistrationErrorReason(value);
|
|
38775
|
+
return reason !== null && eventRegistrationErrors[reason].endsCommand;
|
|
38776
|
+
}
|
|
38693
38777
|
|
|
38694
38778
|
//#endregion
|
|
38695
38779
|
//#region ../commerce/src/purchase/eventCheckoutRecoveryWindow.ts
|
|
@@ -41950,6 +42034,17 @@ const eventRegistrationBlockDefinition = {
|
|
|
41950
42034
|
}
|
|
41951
42035
|
};
|
|
41952
42036
|
|
|
42037
|
+
//#endregion
|
|
42038
|
+
//#region ../blocks/src/system/node/fragments/mapDrawingStyle.ts
|
|
42039
|
+
/** Shared map token binding for the current section ground and site style. */
|
|
42040
|
+
const mapDrawingStyleBinding = { $bind: {
|
|
42041
|
+
from: "content._sectionStyles.background",
|
|
42042
|
+
transforms: [{
|
|
42043
|
+
id: "mapDrawing.resolveStyle",
|
|
42044
|
+
options: { fallbackToken: "background" }
|
|
42045
|
+
}]
|
|
42046
|
+
} };
|
|
42047
|
+
|
|
41953
42048
|
//#endregion
|
|
41954
42049
|
//#region ../blocks/src/system/runtime/api/schemas/events.ts
|
|
41955
42050
|
const uuid = z.string().uuid();
|
|
@@ -42337,7 +42432,7 @@ const eventDetailsManifest = createBlockManifest({
|
|
|
42337
42432
|
layout: [styledSection({
|
|
42338
42433
|
baseClass: "",
|
|
42339
42434
|
spacing: "spacious",
|
|
42340
|
-
children: sectionContainer([text({ as: "h2" }, bind("content.heading"), when("content.heading")), el("event-details", withApiBindings({
|
|
42435
|
+
children: sectionContainer([text({ as: "h2" }, bind("content.heading"), when("content.heading")), el("div", { style: mapDrawingStyleBinding }, [el("event-details", withApiBindings({
|
|
42341
42436
|
entryTitle: { $bind: {
|
|
42342
42437
|
from: "$root.contentEntry.title",
|
|
42343
42438
|
fallback: null
|
|
@@ -42387,7 +42482,7 @@ const eventDetailsManifest = createBlockManifest({
|
|
|
42387
42482
|
from: "data.eventDetailsData.autoApplyDiscount",
|
|
42388
42483
|
fallback: null
|
|
42389
42484
|
} }
|
|
42390
|
-
}, { includeApiBaseUrl: false }))], { gap: "lg" })
|
|
42485
|
+
}, { includeApiBaseUrl: false }))])], { gap: "lg" })
|
|
42391
42486
|
})]
|
|
42392
42487
|
});
|
|
42393
42488
|
const eventDetailsBlockDefinition = {
|
|
@@ -43820,14 +43915,21 @@ function resolveTargetAspectRatio(size) {
|
|
|
43820
43915
|
}
|
|
43821
43916
|
return undefined;
|
|
43822
43917
|
}
|
|
43918
|
+
/**
|
|
43919
|
+
* The editor's "Add a photo" sits on the section's ground, so it takes the ground's rule colour where
|
|
43920
|
+
* the surface publishes one (light on light grounds, dark on dark) and reads in the ground's text ink.
|
|
43921
|
+
* A fixed light surface under ground-following muted text vanished on dark sections. Published
|
|
43922
|
+
* "Image unavailable" keeps its existing styling.
|
|
43923
|
+
*/
|
|
43924
|
+
const AUTHORING_PLACEHOLDER_GROUND = { backgroundColor: "var(--rb-surface-line-color, rgb(var(--tb-surface)))" };
|
|
43823
43925
|
function MediaPlaceholder({ className, style, fieldPath, authoring }) {
|
|
43824
43926
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
43825
43927
|
"data-placeholder-field": authoring ? fieldPath : undefined,
|
|
43826
43928
|
className: clsx_default("rb-flex rb-h-48 rb-w-full rb-items-center rb-justify-center", className),
|
|
43827
|
-
style: mergeStyles(backgroundColorStyle("surface"), style),
|
|
43929
|
+
style: mergeStyles(authoring ? AUTHORING_PLACEHOLDER_GROUND : backgroundColorStyle("surface"), style),
|
|
43828
43930
|
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
43829
43931
|
className: "rb-caption",
|
|
43830
|
-
style: textColorStyle("mutedText"),
|
|
43932
|
+
style: textColorStyle(authoring ? "text" : "mutedText"),
|
|
43831
43933
|
children: authoring ? "Add a photo" : "Image unavailable"
|
|
43832
43934
|
})
|
|
43833
43935
|
});
|
|
@@ -44947,6 +45049,254 @@ function leadItemPresentation(presentation, index, count) {
|
|
|
44947
45049
|
};
|
|
44948
45050
|
}
|
|
44949
45051
|
|
|
45052
|
+
//#endregion
|
|
45053
|
+
//#region ../blocks/src/system/runtime/nodes/svg.tsx
|
|
45054
|
+
/**
|
|
45055
|
+
* Strict SVG-`transform` validator.
|
|
45056
|
+
*
|
|
45057
|
+
* Accepts only a whitespace/comma-separated list of the geometric transform
|
|
45058
|
+
* functions (`translate`/`rotate`/`scale`/`skewX`/`skewY`/`matrix`) whose
|
|
45059
|
+
* arguments are plain numbers. This deliberately rejects anything else —
|
|
45060
|
+
* `url(...)`, CSS functions, `javascript:`, angle/length units, stray letters —
|
|
45061
|
+
* so a persisted custom-block tree can't smuggle an executable or exfiltrating
|
|
45062
|
+
* value into the attribute.
|
|
45063
|
+
*/
|
|
45064
|
+
const TRANSFORM_NUMBER = String.raw`-?(?:\d+\.?\d*|\.\d+)(?:e-?\d+)?`;
|
|
45065
|
+
const TRANSFORM_ARGS = String.raw`${TRANSFORM_NUMBER}(?:[\s,]+${TRANSFORM_NUMBER})*`;
|
|
45066
|
+
const TRANSFORM_FN = String.raw`(?:translate|rotate|scale|skewX|skewY|matrix)\(\s*${TRANSFORM_ARGS}\s*\)`;
|
|
45067
|
+
const SAFE_TRANSFORM_RE = new RegExp(String.raw`^\s*${TRANSFORM_FN}(?:[\s,]*${TRANSFORM_FN})*\s*$`);
|
|
45068
|
+
function safeTransform(value) {
|
|
45069
|
+
if (typeof value !== "string") return undefined;
|
|
45070
|
+
const trimmed = value.trim();
|
|
45071
|
+
if (trimmed.length === 0) return undefined;
|
|
45072
|
+
return SAFE_TRANSFORM_RE.test(trimmed) ? trimmed : undefined;
|
|
45073
|
+
}
|
|
45074
|
+
/**
|
|
45075
|
+
* Turn paint props into a CSS style object. Colour values pass through as-is so
|
|
45076
|
+
* they may reference theme tokens via `var()`, which only resolves in a CSS
|
|
45077
|
+
* property context (not in a bare presentation attribute).
|
|
45078
|
+
*/
|
|
45079
|
+
function paintStyle(shape) {
|
|
45080
|
+
const style = {};
|
|
45081
|
+
if (shape.fill !== undefined) style.fill = shape.fill;
|
|
45082
|
+
if (shape.stroke !== undefined) style.stroke = shape.stroke;
|
|
45083
|
+
if (shape.strokeWidth !== undefined) style.strokeWidth = shape.strokeWidth;
|
|
45084
|
+
if (shape.fillOpacity !== undefined) style.fillOpacity = shape.fillOpacity;
|
|
45085
|
+
if (shape.strokeOpacity !== undefined) style.strokeOpacity = shape.strokeOpacity;
|
|
45086
|
+
if (shape.strokeLinecap !== undefined) style.strokeLinecap = shape.strokeLinecap;
|
|
45087
|
+
if (shape.strokeLinejoin !== undefined) style.strokeLinejoin = shape.strokeLinejoin;
|
|
45088
|
+
if (shape.strokeDasharray !== undefined) style.strokeDasharray = shape.strokeDasharray;
|
|
45089
|
+
return style;
|
|
45090
|
+
}
|
|
45091
|
+
function renderShape(shape, key) {
|
|
45092
|
+
const style = paintStyle(shape);
|
|
45093
|
+
const transform = safeTransform(shape.transform);
|
|
45094
|
+
switch (shape.kind) {
|
|
45095
|
+
case "text": return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("text", {
|
|
45096
|
+
className: shape.className,
|
|
45097
|
+
x: shape.x,
|
|
45098
|
+
y: shape.y,
|
|
45099
|
+
transform,
|
|
45100
|
+
children: shape.text
|
|
45101
|
+
}, key);
|
|
45102
|
+
case "path": return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", {
|
|
45103
|
+
d: shape.d,
|
|
45104
|
+
className: shape.className,
|
|
45105
|
+
fillRule: shape.fillRule,
|
|
45106
|
+
style,
|
|
45107
|
+
transform
|
|
45108
|
+
}, key);
|
|
45109
|
+
case "ellipse": return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("ellipse", {
|
|
45110
|
+
cx: shape.cx,
|
|
45111
|
+
cy: shape.cy,
|
|
45112
|
+
rx: shape.rx,
|
|
45113
|
+
ry: shape.ry,
|
|
45114
|
+
style,
|
|
45115
|
+
transform
|
|
45116
|
+
}, key);
|
|
45117
|
+
case "circle": return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("circle", {
|
|
45118
|
+
cx: shape.cx,
|
|
45119
|
+
cy: shape.cy,
|
|
45120
|
+
r: shape.r,
|
|
45121
|
+
style,
|
|
45122
|
+
transform
|
|
45123
|
+
}, key);
|
|
45124
|
+
case "rect": return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("rect", {
|
|
45125
|
+
x: shape.x,
|
|
45126
|
+
y: shape.y,
|
|
45127
|
+
className: shape.className,
|
|
45128
|
+
width: shape.width,
|
|
45129
|
+
height: shape.height,
|
|
45130
|
+
rx: shape.rx,
|
|
45131
|
+
ry: shape.ry,
|
|
45132
|
+
style,
|
|
45133
|
+
transform
|
|
45134
|
+
}, key);
|
|
45135
|
+
case "line": return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("line", {
|
|
45136
|
+
x1: shape.x1,
|
|
45137
|
+
y1: shape.y1,
|
|
45138
|
+
x2: shape.x2,
|
|
45139
|
+
y2: shape.y2,
|
|
45140
|
+
style,
|
|
45141
|
+
transform
|
|
45142
|
+
}, key);
|
|
45143
|
+
default: return null;
|
|
45144
|
+
}
|
|
45145
|
+
}
|
|
45146
|
+
const SvgNode = ({ blockId: _blockId, blockKind: _blockKind, blockContent: _blockContent, fragmentRegistry: _fragmentRegistry, pathBase: _pathBase, viewBox, width, height, className, style, ariaHidden = true, ariaLabel, shapes }) => {
|
|
45147
|
+
const safeShapes = Array.isArray(shapes) ? shapes : [];
|
|
45148
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
|
|
45149
|
+
viewBox,
|
|
45150
|
+
width,
|
|
45151
|
+
height,
|
|
45152
|
+
className,
|
|
45153
|
+
style,
|
|
45154
|
+
"aria-hidden": ariaHidden || undefined,
|
|
45155
|
+
role: ariaLabel ? "img" : undefined,
|
|
45156
|
+
"aria-label": ariaLabel,
|
|
45157
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
45158
|
+
fill: "none",
|
|
45159
|
+
children: safeShapes.map((shape, index) => renderShape(shape, index))
|
|
45160
|
+
});
|
|
45161
|
+
};
|
|
45162
|
+
|
|
45163
|
+
//#endregion
|
|
45164
|
+
//#region ../blocks/src/system/runtime/nodes/shared/MapDrawingSvg.tsx
|
|
45165
|
+
const PIN_PATH = "M0 0C-3.5-9-13-15-13-25A13 13 0 1 1 13-25C13-15 3.5-9 0 0ZM0-20.5A4.5 4.5 0 1 0 0-29.5A4.5 4.5 0 1 0 0-20.5Z";
|
|
45166
|
+
const commands = (points) => points.map(([x$1, y$1], index) => `${index ? "L" : "M"}${x$1} ${y$1}`).join(" ");
|
|
45167
|
+
function pathShape(path$3) {
|
|
45168
|
+
return path$3.kind === "polygon" ? {
|
|
45169
|
+
kind: "path",
|
|
45170
|
+
className: path$3.className,
|
|
45171
|
+
fillRule: path$3.fillRule,
|
|
45172
|
+
d: path$3.rings.map((ring) => `${commands(ring)} Z`).join(" ")
|
|
45173
|
+
} : {
|
|
45174
|
+
kind: "path",
|
|
45175
|
+
className: path$3.className,
|
|
45176
|
+
d: commands(path$3.points)
|
|
45177
|
+
};
|
|
45178
|
+
}
|
|
45179
|
+
function labelShapes(label) {
|
|
45180
|
+
const [x$1, y$1] = label.point, transform = `rotate(${label.angle} ${x$1} ${y$1})`;
|
|
45181
|
+
return [label.haloClassName, label.className].map((className) => ({
|
|
45182
|
+
kind: "text",
|
|
45183
|
+
className,
|
|
45184
|
+
x: x$1,
|
|
45185
|
+
y: y$1,
|
|
45186
|
+
transform,
|
|
45187
|
+
text: label.text
|
|
45188
|
+
}));
|
|
45189
|
+
}
|
|
45190
|
+
/** The drawing the renderer below would show, or null when there's nothing it can draw. */
|
|
45191
|
+
function readableMapDrawing(drawing) {
|
|
45192
|
+
const parsed = mapDrawingSchema.safeParse(drawing);
|
|
45193
|
+
return parsed.success ? parsed.data : null;
|
|
45194
|
+
}
|
|
45195
|
+
/** Untrusted standalone callers retain boundary admission. */
|
|
45196
|
+
function MapDrawingSvg(props$1) {
|
|
45197
|
+
const drawing = readableMapDrawing(props$1.drawing);
|
|
45198
|
+
return drawing ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AdmittedMapDrawingSvg, {
|
|
45199
|
+
...props$1,
|
|
45200
|
+
drawing
|
|
45201
|
+
}) : null;
|
|
45202
|
+
}
|
|
45203
|
+
/** Render an already admitted value without allocating another validation copy. */
|
|
45204
|
+
function AdmittedMapDrawingSvg(props$1) {
|
|
45205
|
+
const drawing = props$1.drawing;
|
|
45206
|
+
const name = props$1.wider ? "wider" : "neighbourhood", frame = drawing.frames[name];
|
|
45207
|
+
const shapes = [
|
|
45208
|
+
{
|
|
45209
|
+
kind: "rect",
|
|
45210
|
+
className: frame.backgroundClass,
|
|
45211
|
+
x: 0,
|
|
45212
|
+
y: 0,
|
|
45213
|
+
width: 800,
|
|
45214
|
+
height: 800
|
|
45215
|
+
},
|
|
45216
|
+
...frame.paths.map(pathShape),
|
|
45217
|
+
...frame.labels.flatMap(labelShapes),
|
|
45218
|
+
{
|
|
45219
|
+
kind: "path",
|
|
45220
|
+
className: frame.pin.className,
|
|
45221
|
+
fillRule: "evenodd",
|
|
45222
|
+
d: PIN_PATH,
|
|
45223
|
+
transform: `translate(${frame.pin.point.join(" ")})`
|
|
45224
|
+
}
|
|
45225
|
+
];
|
|
45226
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("figure", {
|
|
45227
|
+
className: `rb-map-drawing ${props$1.className ?? ""}`.trim(),
|
|
45228
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
45229
|
+
className: "rb-map-drawing-crop",
|
|
45230
|
+
style: cropHeightStyle(Math.max(255, props$1.height ?? 320), props$1.heightAs ?? "fixed"),
|
|
45231
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SvgNode, {
|
|
45232
|
+
className: `map-${name}`,
|
|
45233
|
+
viewBox: frame.viewBox.join(" "),
|
|
45234
|
+
shapes,
|
|
45235
|
+
ariaHidden: false,
|
|
45236
|
+
ariaLabel: props$1.label ? `Map showing ${props$1.label}` : "Map showing the arrival pin"
|
|
45237
|
+
})
|
|
45238
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("figcaption", { children: ["© ", /* @__PURE__ */ (0, import_jsx_runtime.jsx)("a", {
|
|
45239
|
+
href: "https://www.openstreetmap.org/copyright",
|
|
45240
|
+
target: "_blank",
|
|
45241
|
+
rel: "noreferrer",
|
|
45242
|
+
children: "OpenStreetMap contributors"
|
|
45243
|
+
})] })]
|
|
45244
|
+
});
|
|
45245
|
+
}
|
|
45246
|
+
function cropHeightStyle(height, heightAs) {
|
|
45247
|
+
return heightAs === "minimum" ? { minHeight: height } : { height };
|
|
45248
|
+
}
|
|
45249
|
+
|
|
45250
|
+
//#endregion
|
|
45251
|
+
//#region ../blocks/src/system/runtime/nodes/shared/LocationMapActions.tsx
|
|
45252
|
+
/**
|
|
45253
|
+
* `compact` (event details, cards and modals) keeps two small ghost buttons;
|
|
45254
|
+
* `block` (the map block) leads with a secondary directions button and keeps
|
|
45255
|
+
* Google Maps as a plain text link beside it.
|
|
45256
|
+
*/
|
|
45257
|
+
function LocationMapActions(props$1) {
|
|
45258
|
+
const links = locationMapLinks(props$1);
|
|
45259
|
+
const directionsLabel = props$1.directionsLabel ?? "Get directions";
|
|
45260
|
+
const googleMapsLabel = props$1.googleMapsLabel ?? "Open in Google Maps";
|
|
45261
|
+
if (props$1.layout === "block") {
|
|
45262
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
45263
|
+
className: "rb-location-map-actions",
|
|
45264
|
+
children: [links.directions ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ThemedButtonLink, {
|
|
45265
|
+
href: links.directions,
|
|
45266
|
+
target: "_blank",
|
|
45267
|
+
rel: "noreferrer",
|
|
45268
|
+
variant: "secondary",
|
|
45269
|
+
size: "sm",
|
|
45270
|
+
label: directionsLabel
|
|
45271
|
+
}) : null, links.googleMaps ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("a", {
|
|
45272
|
+
className: "rb-location-map-link",
|
|
45273
|
+
href: links.googleMaps,
|
|
45274
|
+
target: "_blank",
|
|
45275
|
+
rel: "noreferrer",
|
|
45276
|
+
children: googleMapsLabel
|
|
45277
|
+
}) : null]
|
|
45278
|
+
});
|
|
45279
|
+
}
|
|
45280
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
45281
|
+
className: "rb-flex rb-flex-wrap rb-gap-2",
|
|
45282
|
+
children: [links.directions ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ThemedButtonLink, {
|
|
45283
|
+
href: links.directions,
|
|
45284
|
+
target: "_blank",
|
|
45285
|
+
rel: "noreferrer",
|
|
45286
|
+
variant: "ghost",
|
|
45287
|
+
size: "sm",
|
|
45288
|
+
label: directionsLabel
|
|
45289
|
+
}) : null, links.googleMaps ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ThemedButtonLink, {
|
|
45290
|
+
href: links.googleMaps,
|
|
45291
|
+
target: "_blank",
|
|
45292
|
+
rel: "noreferrer",
|
|
45293
|
+
variant: "ghost",
|
|
45294
|
+
size: "sm",
|
|
45295
|
+
label: googleMapsLabel
|
|
45296
|
+
}) : null]
|
|
45297
|
+
});
|
|
45298
|
+
}
|
|
45299
|
+
|
|
44950
45300
|
//#endregion
|
|
44951
45301
|
//#region ../blocks/src/system/runtime/nodes/events/shared/EventCardIcons.tsx
|
|
44952
45302
|
function MapPinIcon({ className, size = 16, strokeWidth = 2 }) {
|
|
@@ -45059,7 +45409,7 @@ const EventCard = ({ event, cardRole = "default", buttonVariant = "primary", but
|
|
|
45059
45409
|
formattedTime,
|
|
45060
45410
|
hasImage,
|
|
45061
45411
|
headingLevel: cardHeadingLevel,
|
|
45062
|
-
mapSlot,
|
|
45412
|
+
mapSlot: resolveVenueMapSlot(event.venue, mapSlot),
|
|
45063
45413
|
priceText,
|
|
45064
45414
|
showMap,
|
|
45065
45415
|
showSummary,
|
|
@@ -45070,6 +45420,13 @@ const EventCard = ({ event, cardRole = "default", buttonVariant = "primary", but
|
|
|
45070
45420
|
})]
|
|
45071
45421
|
});
|
|
45072
45422
|
};
|
|
45423
|
+
function resolveVenueMapSlot(venue, override) {
|
|
45424
|
+
return override ?? (venue?.drawing ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(MapDrawingSvg, {
|
|
45425
|
+
drawing: venue.drawing,
|
|
45426
|
+
label: venue.name,
|
|
45427
|
+
height: 255
|
|
45428
|
+
}) : null);
|
|
45429
|
+
}
|
|
45073
45430
|
function EventCardMedia(props$1) {
|
|
45074
45431
|
if (props$1.lookPresentation.lookSlots !== undefined) return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(EventLookDate, {
|
|
45075
45432
|
event: props$1.event,
|
|
@@ -45176,13 +45533,20 @@ function EventCardVenue(props$1) {
|
|
|
45176
45533
|
if (!venue) return null;
|
|
45177
45534
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
45178
45535
|
className: "rb-mb-3",
|
|
45179
|
-
children: [
|
|
45180
|
-
|
|
45181
|
-
|
|
45182
|
-
|
|
45183
|
-
|
|
45184
|
-
|
|
45185
|
-
|
|
45536
|
+
children: [
|
|
45537
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
45538
|
+
className: "rb-flex rb-items-center rb-gap-2 rb-caption",
|
|
45539
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(MapPinIcon, { className: "rb-shrink-0" }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("strong", { children: venue.name }), venue.address ? ` · ${venue.address}` : null] })]
|
|
45540
|
+
}),
|
|
45541
|
+
props$1.allowMap ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(LocationMapActions, {
|
|
45542
|
+
location: venue.location,
|
|
45543
|
+
addressText: venue.address
|
|
45544
|
+
}) : null,
|
|
45545
|
+
props$1.showMap && props$1.allowMap && venue.location && props$1.mapSlot && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
45546
|
+
className: "rb-mt-2",
|
|
45547
|
+
children: props$1.mapSlot
|
|
45548
|
+
})
|
|
45549
|
+
]
|
|
45186
45550
|
});
|
|
45187
45551
|
}
|
|
45188
45552
|
function EventCardFooter(props$1) {
|
|
@@ -46550,7 +46914,7 @@ const eventListingLayout = [styledSection({
|
|
|
46550
46914
|
children: styledContainer({
|
|
46551
46915
|
rootType: "stack",
|
|
46552
46916
|
rootProps: { gap: "lg" },
|
|
46553
|
-
children: [...sectionHeaderLayoutNodes(), el("event-listing", withApiBindings({
|
|
46917
|
+
children: [...sectionHeaderLayoutNodes(), el("div", { style: mapDrawingStyleBinding }, [el("event-listing", withApiBindings({
|
|
46554
46918
|
readAuthority: { $bind: { from: "$root.readAuthority" } },
|
|
46555
46919
|
events: { $bind: { from: "data.events" } },
|
|
46556
46920
|
stage: { $bind: {
|
|
@@ -46607,7 +46971,7 @@ const eventListingLayout = [styledSection({
|
|
|
46607
46971
|
fallback: "any"
|
|
46608
46972
|
} },
|
|
46609
46973
|
emptyMessage: { $bind: { from: "content.emptyMessage" } }
|
|
46610
|
-
}))]
|
|
46974
|
+
}))])]
|
|
46611
46975
|
}),
|
|
46612
46976
|
baseClass: "",
|
|
46613
46977
|
spacing: "comfortable"
|
|
@@ -47597,7 +47961,7 @@ const eventCalendarAdditionalFields = [
|
|
|
47597
47961
|
{
|
|
47598
47962
|
id: "eyebrow",
|
|
47599
47963
|
type: "text",
|
|
47600
|
-
label: "
|
|
47964
|
+
label: "Small heading above the title",
|
|
47601
47965
|
required: false,
|
|
47602
47966
|
multiline: false,
|
|
47603
47967
|
maxLength: 80
|
|
@@ -48393,6 +48757,8 @@ const eventCalendarConfig = {
|
|
|
48393
48757
|
promotedFields: [
|
|
48394
48758
|
"variant",
|
|
48395
48759
|
"listBy",
|
|
48760
|
+
"calendarTabViews",
|
|
48761
|
+
"defaultCalendarView",
|
|
48396
48762
|
"eventSurface",
|
|
48397
48763
|
"filterEventPresets",
|
|
48398
48764
|
"scheduleScope",
|
|
@@ -48600,7 +48966,7 @@ const recurringScheduleConfig = {
|
|
|
48600
48966
|
{
|
|
48601
48967
|
id: "eyebrow",
|
|
48602
48968
|
type: "text",
|
|
48603
|
-
label: "
|
|
48969
|
+
label: "Small heading above the title",
|
|
48604
48970
|
required: false,
|
|
48605
48971
|
maxLength: 80
|
|
48606
48972
|
},
|
|
@@ -49669,6 +50035,7 @@ const imageGalleryFields = parseFieldDefinitions([
|
|
|
49669
50035
|
minItems: 0,
|
|
49670
50036
|
maxItems: 24,
|
|
49671
50037
|
ui: {
|
|
50038
|
+
intent: "behavior",
|
|
49672
50039
|
repeaterPreset: "thumbnailGrid",
|
|
49673
50040
|
thumbnailField: "image",
|
|
49674
50041
|
thumbnailAltField: "caption",
|
|
@@ -50462,7 +50829,7 @@ const baseImageGalleryManifest = createBlockManifest({
|
|
|
50462
50829
|
icon: "Columns"
|
|
50463
50830
|
},
|
|
50464
50831
|
marquee: {
|
|
50465
|
-
label: "
|
|
50832
|
+
label: "Scrolling strip",
|
|
50466
50833
|
description: "Infinite horizontal scrolling gallery",
|
|
50467
50834
|
icon: "Repeat"
|
|
50468
50835
|
}
|
|
@@ -50660,6 +51027,7 @@ const fields = parseFieldDefinitions([
|
|
|
50660
51027
|
type: "repeater",
|
|
50661
51028
|
label: "Videos",
|
|
50662
51029
|
itemLabel: "Video",
|
|
51030
|
+
ui: { intent: "behavior" },
|
|
50663
51031
|
minItems: 0,
|
|
50664
51032
|
maxItems: 12,
|
|
50665
51033
|
schema: { fields: [
|
|
@@ -50729,6 +51097,7 @@ const fields = parseFieldDefinitions([
|
|
|
50729
51097
|
const videoGridManifest = createBlockManifest({
|
|
50730
51098
|
variantMeaning: { kind: "arrangement" },
|
|
50731
51099
|
id: "block.video-grid",
|
|
51100
|
+
promotedFields: ["videos"],
|
|
50732
51101
|
title: "Video grid",
|
|
50733
51102
|
category: "photos",
|
|
50734
51103
|
contentSource: { kind: "inline" },
|
|
@@ -50890,7 +51259,7 @@ const fileDownloadManifest = createBlockManifest({
|
|
|
50890
51259
|
id: "block.file-download",
|
|
50891
51260
|
title: "File download",
|
|
50892
51261
|
titleSource: ["title", "file.filename"],
|
|
50893
|
-
category: "
|
|
51262
|
+
category: "text-and-images",
|
|
50894
51263
|
contentSource: { kind: "inline" },
|
|
50895
51264
|
description: "A link visitors can use to download a file, such as a PDF.",
|
|
50896
51265
|
tags: [
|
|
@@ -52312,7 +52681,7 @@ const shopManifest = createBlockManifest({
|
|
|
52312
52681
|
animation: false,
|
|
52313
52682
|
paletteHidden: false
|
|
52314
52683
|
},
|
|
52315
|
-
category: "
|
|
52684
|
+
category: "shop",
|
|
52316
52685
|
contentSource: { kind: "entries" },
|
|
52317
52686
|
tags: [
|
|
52318
52687
|
"shop",
|
|
@@ -54157,18 +54526,6 @@ function normalizeNumber(value, fallback) {
|
|
|
54157
54526
|
}
|
|
54158
54527
|
return fallback;
|
|
54159
54528
|
}
|
|
54160
|
-
function normalizeOptionalNumber(value) {
|
|
54161
|
-
if (typeof value === "number" && Number.isFinite(value)) {
|
|
54162
|
-
return value;
|
|
54163
|
-
}
|
|
54164
|
-
if (typeof value === "string") {
|
|
54165
|
-
const parsed = Number.parseFloat(value);
|
|
54166
|
-
if (Number.isFinite(parsed)) {
|
|
54167
|
-
return parsed;
|
|
54168
|
-
}
|
|
54169
|
-
}
|
|
54170
|
-
return null;
|
|
54171
|
-
}
|
|
54172
54529
|
function normalizeBoolean$1(value, fallback) {
|
|
54173
54530
|
if (typeof value === "boolean") {
|
|
54174
54531
|
return value;
|
|
@@ -54179,23 +54536,20 @@ function normalizeBoolean$1(value, fallback) {
|
|
|
54179
54536
|
}
|
|
54180
54537
|
return fallback;
|
|
54181
54538
|
}
|
|
54182
|
-
function
|
|
54183
|
-
const addressText = typeof record.addressText === "string" ? record.addressText : typeof record.displayAddress === "string" ? record.displayAddress : null;
|
|
54184
|
-
const normalized = {
|
|
54185
|
-
addressText: normalizeLocationAddressText(addressText),
|
|
54186
|
-
lat: normalizeOptionalNumber(record.lat),
|
|
54187
|
-
lng: normalizeOptionalNumber(record.lng)
|
|
54188
|
-
};
|
|
54189
|
-
if (normalized.addressText === null && normalized.lat === null && normalized.lng === null) {
|
|
54190
|
-
return null;
|
|
54191
|
-
}
|
|
54192
|
-
return normalized;
|
|
54193
|
-
}
|
|
54194
|
-
function normalizeLocationMapValue(value) {
|
|
54539
|
+
function normalizeLocationMapValue(value, siteCountry) {
|
|
54195
54540
|
if (typeof value !== "object" || value === null) {
|
|
54196
54541
|
return null;
|
|
54197
54542
|
}
|
|
54198
|
-
|
|
54543
|
+
const projected = readLocationMapProjection(value, siteCountry);
|
|
54544
|
+
return projected === null ? null : {
|
|
54545
|
+
addressText: projected.displayAddress,
|
|
54546
|
+
...projected.pin ?? {
|
|
54547
|
+
lat: null,
|
|
54548
|
+
lng: null
|
|
54549
|
+
},
|
|
54550
|
+
drawing: projected.drawing,
|
|
54551
|
+
doorNote: projected.doorNote
|
|
54552
|
+
};
|
|
54199
54553
|
}
|
|
54200
54554
|
function normalizeLocationMapSource(value) {
|
|
54201
54555
|
return value === "business_address" || value === "venue" ? value : "custom";
|
|
@@ -54203,7 +54557,7 @@ function normalizeLocationMapSource(value) {
|
|
|
54203
54557
|
function resolveLocationMapLocation(input) {
|
|
54204
54558
|
const source = normalizeLocationMapSource(input.locationSource);
|
|
54205
54559
|
if (source === "business_address") {
|
|
54206
|
-
const locationValue$1 = normalizeLocationMapValue(input.businessAddress
|
|
54560
|
+
const locationValue$1 = normalizeLocationMapValue(input.businessAddress, input.siteCountry);
|
|
54207
54561
|
return locationValue$1 ? {
|
|
54208
54562
|
kind: "business_address",
|
|
54209
54563
|
locationValue: locationValue$1
|
|
@@ -54222,7 +54576,7 @@ function resolveLocationMapLocation(input) {
|
|
|
54222
54576
|
reason: "missing_venue_id"
|
|
54223
54577
|
};
|
|
54224
54578
|
}
|
|
54225
|
-
const locationValue$1 = input.venuesById ? normalizeLocationMapValue(input.venuesById[venueId] ?? null) : null;
|
|
54579
|
+
const locationValue$1 = input.venuesById ? normalizeLocationMapValue(input.venuesById[venueId] ?? null, input.siteCountry) : null;
|
|
54226
54580
|
return locationValue$1 ? {
|
|
54227
54581
|
kind: "venue",
|
|
54228
54582
|
venueId,
|
|
@@ -54233,7 +54587,7 @@ function resolveLocationMapLocation(input) {
|
|
|
54233
54587
|
reason: "missing_venue_location"
|
|
54234
54588
|
};
|
|
54235
54589
|
}
|
|
54236
|
-
const locationValue = normalizeLocationMapValue(input.location);
|
|
54590
|
+
const locationValue = normalizeLocationMapValue(input.location, input.siteCountry);
|
|
54237
54591
|
return locationValue ? {
|
|
54238
54592
|
kind: "custom",
|
|
54239
54593
|
locationValue
|
|
@@ -54260,11 +54614,12 @@ function normalizeLocationMapProps(input) {
|
|
|
54260
54614
|
const locationValue = resolvedLocation.kind === "unresolved" ? null : resolvedLocation.locationValue;
|
|
54261
54615
|
const directionsLabel = normalizeLocationAddressText(input.directionsLabel) ?? LOCATION_MAP_DEFAULTS.directionsLabel;
|
|
54262
54616
|
return {
|
|
54617
|
+
...locationMapDetails(locationValue),
|
|
54618
|
+
wider: input.wider === true,
|
|
54619
|
+
googleMapsLabel: normalizedGoogleMapsLabel(input.googleMapsLabel),
|
|
54263
54620
|
resolvedLocation,
|
|
54264
54621
|
locationValue,
|
|
54265
54622
|
unresolvedMessage: describeUnresolvedLocationMapLocation(resolvedLocation),
|
|
54266
|
-
addressText: locationValue?.addressText ?? null,
|
|
54267
|
-
location: toLocationCoordinates(locationValue),
|
|
54268
54623
|
zoom: Math.min(LOCATION_MAP_LIMITS.zoom.max, Math.max(LOCATION_MAP_LIMITS.zoom.min, Math.round(normalizeNumber(input.zoom, LOCATION_MAP_DEFAULTS.zoom)))),
|
|
54269
54624
|
heightPx: Math.min(LOCATION_MAP_LIMITS.heightPx.max, Math.max(LOCATION_MAP_LIMITS.heightPx.min, Math.round(normalizeNumber(input.heightPx, LOCATION_MAP_DEFAULTS.heightPx)))),
|
|
54270
54625
|
openingHours: parsedHours.ok ? parsedHours.value : null,
|
|
@@ -54275,29 +54630,26 @@ function normalizeLocationMapProps(input) {
|
|
|
54275
54630
|
className: typeof input.className === "string" ? input.className : null
|
|
54276
54631
|
};
|
|
54277
54632
|
}
|
|
54278
|
-
|
|
54279
|
-
|
|
54633
|
+
/** All render-ready permitted details come from the same resolved source value. */
|
|
54634
|
+
function locationMapDetails(value) {
|
|
54280
54635
|
return {
|
|
54281
|
-
|
|
54282
|
-
|
|
54283
|
-
|
|
54284
|
-
|
|
54285
|
-
showOpeningHours: normalized.showOpeningHours,
|
|
54286
|
-
showAddressText: normalized.showAddressText,
|
|
54287
|
-
showDirections: normalized.showDirections,
|
|
54288
|
-
directionsLabel: normalized.directionsLabel,
|
|
54289
|
-
className: normalized.className
|
|
54636
|
+
drawing: value?.drawing ?? null,
|
|
54637
|
+
doorNote: value?.doorNote ?? null,
|
|
54638
|
+
addressText: value?.addressText ?? null,
|
|
54639
|
+
location: toLocationCoordinates(value)
|
|
54290
54640
|
};
|
|
54291
54641
|
}
|
|
54642
|
+
function normalizedGoogleMapsLabel(value) {
|
|
54643
|
+
return normalizeLocationAddressText(value) ?? "Open in Google Maps";
|
|
54644
|
+
}
|
|
54292
54645
|
function buildGoogleMapsDirectionsUrl(input) {
|
|
54293
|
-
|
|
54294
|
-
|
|
54295
|
-
|
|
54296
|
-
|
|
54297
|
-
|
|
54298
|
-
|
|
54299
|
-
|
|
54300
|
-
return url.toString();
|
|
54646
|
+
return locationMapLinks(input).directions;
|
|
54647
|
+
}
|
|
54648
|
+
function readLocationMapProjection(value, siteCountry) {
|
|
54649
|
+
const canonical$1 = parseLocationValue(value);
|
|
54650
|
+
if (canonical$1.ok && canonical$1.value !== null) return projectPublicLocation(canonical$1.value, siteCountry);
|
|
54651
|
+
const projected = publicLocationSchema$1.safeParse(value);
|
|
54652
|
+
return projected.success ? projected.data : null;
|
|
54301
54653
|
}
|
|
54302
54654
|
|
|
54303
54655
|
//#endregion
|
|
@@ -54317,9 +54669,11 @@ function normalizeLocationMapContent(content) {
|
|
|
54317
54669
|
const locationSource = normalizeLocationMapSource(record.locationSource);
|
|
54318
54670
|
const venueId = typeof record.venueId === "string" && record.venueId.trim() ? record.venueId.trim() : null;
|
|
54319
54671
|
return {
|
|
54672
|
+
wider: record.wider === true,
|
|
54673
|
+
googleMapsLabel: typeof record.googleMapsLabel === "string" ? record.googleMapsLabel : "Open in Google Maps",
|
|
54320
54674
|
heading: typeof record.heading === "string" ? record.heading : undefined,
|
|
54321
54675
|
locationSource,
|
|
54322
|
-
...authoredLocationMapSourceFields(locationSource, venueId,
|
|
54676
|
+
...authoredLocationMapSourceFields(locationSource, venueId, locationSource === "custom" ? parseAuthoredLocation(record.location) : null),
|
|
54323
54677
|
showOpeningHours: record.showOpeningHours !== false,
|
|
54324
54678
|
showAddressText: normalized.showAddressText,
|
|
54325
54679
|
showDirections: normalized.showDirections,
|
|
@@ -54345,8 +54699,90 @@ function authoredLocationMapSourceFields(source, venueId, location) {
|
|
|
54345
54699
|
};
|
|
54346
54700
|
}
|
|
54347
54701
|
}
|
|
54702
|
+
const locationMapNodeProps = {
|
|
54703
|
+
mapStyle: mapDrawingStyleBinding,
|
|
54704
|
+
siteCountry: { $bind: {
|
|
54705
|
+
from: "$root.site.siteCountry",
|
|
54706
|
+
fallback: null
|
|
54707
|
+
} },
|
|
54708
|
+
openingHours: { $bind: {
|
|
54709
|
+
from: "$root.openingHours",
|
|
54710
|
+
fallback: null
|
|
54711
|
+
} },
|
|
54712
|
+
showOpeningHours: { $bind: {
|
|
54713
|
+
from: "content.showOpeningHours",
|
|
54714
|
+
fallback: true
|
|
54715
|
+
} },
|
|
54716
|
+
location: { $bind: {
|
|
54717
|
+
from: "content.location",
|
|
54718
|
+
fallback: null
|
|
54719
|
+
} },
|
|
54720
|
+
businessAddress: { $bind: {
|
|
54721
|
+
from: "$root.site.businessAddress",
|
|
54722
|
+
fallback: null
|
|
54723
|
+
} },
|
|
54724
|
+
locationSource: { $bind: {
|
|
54725
|
+
from: "content.locationSource",
|
|
54726
|
+
fallback: "custom"
|
|
54727
|
+
} },
|
|
54728
|
+
venueId: { $bind: {
|
|
54729
|
+
from: "content.venueId",
|
|
54730
|
+
fallback: null
|
|
54731
|
+
} },
|
|
54732
|
+
venuesById: { $bind: {
|
|
54733
|
+
from: "$root.site.venuesById",
|
|
54734
|
+
fallback: null
|
|
54735
|
+
} },
|
|
54736
|
+
wider: { $bind: {
|
|
54737
|
+
from: "content.wider",
|
|
54738
|
+
fallback: false
|
|
54739
|
+
} },
|
|
54740
|
+
googleMapsLabel: { $bind: {
|
|
54741
|
+
from: "content.googleMapsLabel",
|
|
54742
|
+
fallback: "Open in Google Maps"
|
|
54743
|
+
} },
|
|
54744
|
+
zoom: { $bind: {
|
|
54745
|
+
from: "content.zoom",
|
|
54746
|
+
fallback: LOCATION_MAP_DEFAULTS.zoom
|
|
54747
|
+
} },
|
|
54748
|
+
heightPx: { $bind: {
|
|
54749
|
+
from: "content.heightPx",
|
|
54750
|
+
fallback: LOCATION_MAP_DEFAULTS.heightPx
|
|
54751
|
+
} },
|
|
54752
|
+
showAddressText: { $bind: {
|
|
54753
|
+
from: "content.showAddressText",
|
|
54754
|
+
fallback: LOCATION_MAP_DEFAULTS.showAddressText
|
|
54755
|
+
} },
|
|
54756
|
+
showDirections: { $bind: {
|
|
54757
|
+
from: "content.showDirections",
|
|
54758
|
+
fallback: LOCATION_MAP_DEFAULTS.showDirections
|
|
54759
|
+
} },
|
|
54760
|
+
directionsLabel: { $bind: {
|
|
54761
|
+
from: "content.directionsLabel",
|
|
54762
|
+
fallback: LOCATION_MAP_DEFAULTS.directionsLabel
|
|
54763
|
+
} }
|
|
54764
|
+
};
|
|
54765
|
+
/** Look-only layouts hand the details their compiler-resolved slot and surface (the wide map's sheet). */
|
|
54766
|
+
const lookPresentationProps = {
|
|
54767
|
+
lookSlots: { $bind: { from: "content._lookSlots" } },
|
|
54768
|
+
itemSurfaces: { $bind: { from: "content._effectiveLook.itemSurfaces" } }
|
|
54769
|
+
};
|
|
54770
|
+
const arrangedLayout = (body) => styledSection({
|
|
54771
|
+
baseClass: "",
|
|
54772
|
+
spacing: "comfortable",
|
|
54773
|
+
children: el("div", {
|
|
54774
|
+
className: "rb-container",
|
|
54775
|
+
...lookSlot("layout")
|
|
54776
|
+
}, [el("div", lookSlot("head"), [text({
|
|
54777
|
+
as: "h2",
|
|
54778
|
+
...lookSlot("heading")
|
|
54779
|
+
}, bind("content.heading"))], when("content.heading")), ...body])
|
|
54780
|
+
});
|
|
54348
54781
|
const locationMapManifest = createBlockManifest({
|
|
54349
|
-
variantMeaning: {
|
|
54782
|
+
variantMeaning: {
|
|
54783
|
+
kind: "arrangement",
|
|
54784
|
+
lookOnlyKeys: ["map-and-details", "photo-and-details"]
|
|
54785
|
+
},
|
|
54350
54786
|
id: "block.location-map",
|
|
54351
54787
|
title: "Map",
|
|
54352
54788
|
titleSource: "heading",
|
|
@@ -54376,20 +54812,20 @@ const locationMapManifest = createBlockManifest({
|
|
|
54376
54812
|
parseFieldDefinition({
|
|
54377
54813
|
id: "locationSource",
|
|
54378
54814
|
type: "select",
|
|
54379
|
-
label: "
|
|
54815
|
+
label: "Which place?",
|
|
54380
54816
|
defaultValue: "custom",
|
|
54381
54817
|
options: [
|
|
54382
54818
|
{
|
|
54383
54819
|
value: "business_address",
|
|
54384
|
-
label: "
|
|
54820
|
+
label: "Your business address"
|
|
54385
54821
|
},
|
|
54386
54822
|
{
|
|
54387
54823
|
value: "venue",
|
|
54388
|
-
label: "
|
|
54824
|
+
label: "One of your venues"
|
|
54389
54825
|
},
|
|
54390
54826
|
{
|
|
54391
54827
|
value: "custom",
|
|
54392
|
-
label: "
|
|
54828
|
+
label: "A different place"
|
|
54393
54829
|
}
|
|
54394
54830
|
],
|
|
54395
54831
|
ui: {
|
|
@@ -54419,6 +54855,7 @@ const locationMapManifest = createBlockManifest({
|
|
|
54419
54855
|
required: false,
|
|
54420
54856
|
ui: {
|
|
54421
54857
|
widget: "locationPicker",
|
|
54858
|
+
valueContract: "location",
|
|
54422
54859
|
intent: "content",
|
|
54423
54860
|
visibleWhen: {
|
|
54424
54861
|
field: "locationSource",
|
|
@@ -54454,6 +54891,15 @@ const locationMapManifest = createBlockManifest({
|
|
|
54454
54891
|
}
|
|
54455
54892
|
] }
|
|
54456
54893
|
}),
|
|
54894
|
+
parseFieldDefinition({
|
|
54895
|
+
id: "entrancePhoto",
|
|
54896
|
+
type: "media",
|
|
54897
|
+
label: "Entrance photo",
|
|
54898
|
+
description: "A photo of the door or the way in. It shows when this section uses the “Entrance photo beside the details” Look.",
|
|
54899
|
+
required: false,
|
|
54900
|
+
mediaKinds: ["image"],
|
|
54901
|
+
ui: { intent: "content" }
|
|
54902
|
+
}),
|
|
54457
54903
|
parseFieldDefinition({
|
|
54458
54904
|
id: "showOpeningHours",
|
|
54459
54905
|
type: "boolean",
|
|
@@ -54490,18 +54936,19 @@ const locationMapManifest = createBlockManifest({
|
|
|
54490
54936
|
}
|
|
54491
54937
|
}),
|
|
54492
54938
|
parseFieldDefinition({
|
|
54493
|
-
id: "
|
|
54494
|
-
type: "
|
|
54495
|
-
label: "
|
|
54496
|
-
defaultValue:
|
|
54497
|
-
|
|
54498
|
-
|
|
54499
|
-
|
|
54500
|
-
|
|
54501
|
-
|
|
54502
|
-
|
|
54503
|
-
|
|
54504
|
-
|
|
54939
|
+
id: "wider",
|
|
54940
|
+
type: "boolean",
|
|
54941
|
+
label: "Show a wider area",
|
|
54942
|
+
defaultValue: false,
|
|
54943
|
+
ui: { intent: "display" }
|
|
54944
|
+
}),
|
|
54945
|
+
parseFieldDefinition({
|
|
54946
|
+
id: "googleMapsLabel",
|
|
54947
|
+
type: "text",
|
|
54948
|
+
label: "Google Maps button label",
|
|
54949
|
+
defaultValue: "Open in Google Maps",
|
|
54950
|
+
maxLength: 60,
|
|
54951
|
+
ui: { intent: "display" }
|
|
54505
54952
|
}),
|
|
54506
54953
|
parseFieldDefinition({
|
|
54507
54954
|
id: "heightPx",
|
|
@@ -54514,64 +54961,27 @@ const locationMapManifest = createBlockManifest({
|
|
|
54514
54961
|
ui: {
|
|
54515
54962
|
intent: "display",
|
|
54516
54963
|
widget: "slider",
|
|
54517
|
-
showValue: true
|
|
54964
|
+
showValue: true,
|
|
54965
|
+
valueUnit: "pixels"
|
|
54518
54966
|
}
|
|
54519
54967
|
})
|
|
54520
54968
|
],
|
|
54521
54969
|
layout: styledSection({
|
|
54522
54970
|
baseClass: "",
|
|
54523
54971
|
spacing: "comfortable",
|
|
54524
|
-
children: sectionContainer([text({ as: "h2" }, bind("content.heading"), when("content.heading")), el("location-map", {
|
|
54525
|
-
|
|
54526
|
-
|
|
54527
|
-
|
|
54528
|
-
|
|
54529
|
-
|
|
54530
|
-
|
|
54531
|
-
|
|
54532
|
-
|
|
54533
|
-
|
|
54534
|
-
|
|
54535
|
-
|
|
54536
|
-
|
|
54537
|
-
businessAddress: { $bind: {
|
|
54538
|
-
from: "site.businessAddress",
|
|
54539
|
-
fallback: null
|
|
54540
|
-
} },
|
|
54541
|
-
locationSource: { $bind: {
|
|
54542
|
-
from: "content.locationSource",
|
|
54543
|
-
fallback: "custom"
|
|
54544
|
-
} },
|
|
54545
|
-
venueId: { $bind: {
|
|
54546
|
-
from: "content.venueId",
|
|
54547
|
-
fallback: null
|
|
54548
|
-
} },
|
|
54549
|
-
venuesById: { $bind: {
|
|
54550
|
-
from: "site.venuesById",
|
|
54551
|
-
fallback: null
|
|
54552
|
-
} },
|
|
54553
|
-
zoom: { $bind: {
|
|
54554
|
-
from: "content.zoom",
|
|
54555
|
-
fallback: LOCATION_MAP_DEFAULTS.zoom
|
|
54556
|
-
} },
|
|
54557
|
-
heightPx: { $bind: {
|
|
54558
|
-
from: "content.heightPx",
|
|
54559
|
-
fallback: LOCATION_MAP_DEFAULTS.heightPx
|
|
54560
|
-
} },
|
|
54561
|
-
showAddressText: { $bind: {
|
|
54562
|
-
from: "content.showAddressText",
|
|
54563
|
-
fallback: LOCATION_MAP_DEFAULTS.showAddressText
|
|
54564
|
-
} },
|
|
54565
|
-
showDirections: { $bind: {
|
|
54566
|
-
from: "content.showDirections",
|
|
54567
|
-
fallback: LOCATION_MAP_DEFAULTS.showDirections
|
|
54568
|
-
} },
|
|
54569
|
-
directionsLabel: { $bind: {
|
|
54570
|
-
from: "content.directionsLabel",
|
|
54571
|
-
fallback: LOCATION_MAP_DEFAULTS.directionsLabel
|
|
54572
|
-
} }
|
|
54573
|
-
})], { gap: "md" })
|
|
54574
|
-
})
|
|
54972
|
+
children: sectionContainer([text({ as: "h2" }, bind("content.heading"), when("content.heading")), el("location-map", locationMapNodeProps)], { gap: "md" })
|
|
54973
|
+
}),
|
|
54974
|
+
variants: {
|
|
54975
|
+
"map-and-details": arrangedLayout([el("location-map", {
|
|
54976
|
+
...locationMapNodeProps,
|
|
54977
|
+
...lookPresentationProps
|
|
54978
|
+
})]),
|
|
54979
|
+
"photo-and-details": arrangedLayout([el("div", lookSlot("frame"), [el("div", lookSlot("media"), [media(lookSlot("photo"), bind("content.entrancePhoto"), when("content.entrancePhoto"))], when("content.entrancePhoto")), el("location-map", {
|
|
54980
|
+
...locationMapNodeProps,
|
|
54981
|
+
...lookPresentationProps,
|
|
54982
|
+
showMap: false
|
|
54983
|
+
})])])
|
|
54984
|
+
}
|
|
54575
54985
|
});
|
|
54576
54986
|
const locationMapBlockDefinition = {
|
|
54577
54987
|
manifest: locationMapManifest,
|
|
@@ -54582,6 +54992,8 @@ const locationMapBlockDefinition = {
|
|
|
54582
54992
|
"venueId",
|
|
54583
54993
|
"location",
|
|
54584
54994
|
"showAddressText",
|
|
54995
|
+
"wider",
|
|
54996
|
+
"googleMapsLabel",
|
|
54585
54997
|
"showOpeningHours",
|
|
54586
54998
|
"showDirections",
|
|
54587
54999
|
"directionsLabel",
|
|
@@ -54591,6 +55003,14 @@ const locationMapBlockDefinition = {
|
|
|
54591
55003
|
normalize: normalizeLocationMapContent
|
|
54592
55004
|
}
|
|
54593
55005
|
};
|
|
55006
|
+
function parseAuthoredLocation(value) {
|
|
55007
|
+
if (value == null) return null;
|
|
55008
|
+
const canonical$1 = parseLocationValue(value);
|
|
55009
|
+
if (canonical$1.ok) return canonical$1.value;
|
|
55010
|
+
const projected = publicLocationSchema$1.safeParse(value);
|
|
55011
|
+
if (projected.success) return projected.data;
|
|
55012
|
+
return { kind: "needs_place" };
|
|
55013
|
+
}
|
|
54594
55014
|
|
|
54595
55015
|
//#endregion
|
|
54596
55016
|
//#region ../blocks/src/system/blocks/index.ts
|
|
@@ -54911,7 +55331,7 @@ const systemBlockDefinitionsRaw = [
|
|
|
54911
55331
|
})
|
|
54912
55332
|
]
|
|
54913
55333
|
})),
|
|
54914
|
-
withDesignCapability("block.location-map", locationMapBlockDefinition, sectionOnly(), defineBlockDesignMetadata({
|
|
55334
|
+
withDesignCapability("block.location-map", locationMapBlockDefinition, withLookCapability(sectionOnly()), defineBlockDesignMetadata({
|
|
54915
55335
|
flow: utilityFlow,
|
|
54916
55336
|
layoutProfiles: [layoutProfile({
|
|
54917
55337
|
variantKey: "default",
|
|
@@ -55626,6 +56046,87 @@ function toEditorPresentationPage(page) {
|
|
|
55626
56046
|
};
|
|
55627
56047
|
}
|
|
55628
56048
|
|
|
56049
|
+
//#endregion
|
|
56050
|
+
//#region ../blocks/src/system/customize/arrangementKnobs.ts
|
|
56051
|
+
/**
|
|
56052
|
+
* Content stage for knobs, shared by the renderer and the editor so what the
|
|
56053
|
+
* options show and what renders can't disagree. Knob buffets are the block's
|
|
56054
|
+
* customise facets; the Look exposes, forces or narrows them and the style's
|
|
56055
|
+
* offer can only remove or narrow further.
|
|
56056
|
+
*/
|
|
56057
|
+
function resolveArrangementKnobs(input) {
|
|
56058
|
+
const length = input.blockKind === "block.hero" ? resolveHeroTitleLength({ ...input.content }, "look") : null;
|
|
56059
|
+
const exposure = arrangementKnobExposure(input.blockKind, input.look, length);
|
|
56060
|
+
const knobs = resolveEffectiveKnobs({
|
|
56061
|
+
exposure,
|
|
56062
|
+
content: normalizedHeadlinePreference(input.content)
|
|
56063
|
+
});
|
|
56064
|
+
return {
|
|
56065
|
+
length,
|
|
56066
|
+
exposure,
|
|
56067
|
+
knobs
|
|
56068
|
+
};
|
|
56069
|
+
}
|
|
56070
|
+
/** The values an owner can choose for an exposed knob, before any length cap. */
|
|
56071
|
+
function arrangementKnobChoices(exposure) {
|
|
56072
|
+
return exposure.definition.values.filter((value) => (exposure.lookValues?.includes(value) ?? true) && (exposure.styleValues?.includes(value) ?? true));
|
|
56073
|
+
}
|
|
56074
|
+
function arrangementKnobExposure(blockKind, look, length) {
|
|
56075
|
+
return systemCustomizeFacetDefinitionsForBlock(blockKind).flatMap((facet) => {
|
|
56076
|
+
if (facet.knob === undefined || facet.target.kind !== "content-field") return [];
|
|
56077
|
+
const id = facet.target.field;
|
|
56078
|
+
const defaults = look.look.structure.knobDefaults ?? {};
|
|
56079
|
+
return [{
|
|
56080
|
+
definition: {
|
|
56081
|
+
id,
|
|
56082
|
+
defaultValue: defaults[id] ?? facet.defaultValue,
|
|
56083
|
+
values: facet.values.map((value) => value.value),
|
|
56084
|
+
...knobKindMetadata(facet.knob)
|
|
56085
|
+
},
|
|
56086
|
+
exposed: exposedKnobIds(look).includes(id),
|
|
56087
|
+
forced: look.look.structure.forcedKnobs?.[id],
|
|
56088
|
+
lookValues: look.look.structure.knobValues?.[id],
|
|
56089
|
+
styleValues: look.knobValues[id],
|
|
56090
|
+
lengthValues: id === "titleSize" ? headlineAllowedValues(length) : undefined
|
|
56091
|
+
}];
|
|
56092
|
+
});
|
|
56093
|
+
}
|
|
56094
|
+
function knobKindMetadata(knob) {
|
|
56095
|
+
return knob.kind === "fixed" ? { ordered: knob.ordered } : {
|
|
56096
|
+
ordered: false,
|
|
56097
|
+
textMaxLength: knob.maxLength
|
|
56098
|
+
};
|
|
56099
|
+
}
|
|
56100
|
+
function headlineAllowedValues(length) {
|
|
56101
|
+
switch (length) {
|
|
56102
|
+
case "long": return ["quiet"];
|
|
56103
|
+
case "medium": return ["quiet", "auto"];
|
|
56104
|
+
case "short": return [
|
|
56105
|
+
"quiet",
|
|
56106
|
+
"auto",
|
|
56107
|
+
"display"
|
|
56108
|
+
];
|
|
56109
|
+
case null: return undefined;
|
|
56110
|
+
}
|
|
56111
|
+
}
|
|
56112
|
+
/** `titleSize` keeps its five stored values; under a Look they read as three steps. */
|
|
56113
|
+
function normalizedHeadlinePreference(content) {
|
|
56114
|
+
switch (content.titleSize) {
|
|
56115
|
+
case "editorial": return {
|
|
56116
|
+
...content,
|
|
56117
|
+
titleSize: "auto"
|
|
56118
|
+
};
|
|
56119
|
+
case "poster": return {
|
|
56120
|
+
...content,
|
|
56121
|
+
titleSize: "display"
|
|
56122
|
+
};
|
|
56123
|
+
default: return content;
|
|
56124
|
+
}
|
|
56125
|
+
}
|
|
56126
|
+
function exposedKnobIds(look) {
|
|
56127
|
+
return [...look.look.structure.knobs, ...look.addKnobs ?? []].filter((id) => !look.removeKnobs.some((removed) => removed === id));
|
|
56128
|
+
}
|
|
56129
|
+
|
|
55629
56130
|
//#endregion
|
|
55630
56131
|
//#region ../blocks/src/system/customize/facets.ts
|
|
55631
56132
|
function defineCustomizeFacet(definition$1) {
|
|
@@ -55933,87 +56434,6 @@ function omitRecordKey(content, key) {
|
|
|
55933
56434
|
return Object.fromEntries(Object.entries(content).filter(([entryKey]) => entryKey !== key));
|
|
55934
56435
|
}
|
|
55935
56436
|
|
|
55936
|
-
//#endregion
|
|
55937
|
-
//#region ../blocks/src/system/customize/arrangementKnobs.ts
|
|
55938
|
-
/**
|
|
55939
|
-
* Content stage for knobs, shared by the renderer and the editor so what the
|
|
55940
|
-
* options show and what renders can't disagree. Knob buffets are the block's
|
|
55941
|
-
* customise facets; the Look exposes, forces or narrows them and the style's
|
|
55942
|
-
* offer can only remove or narrow further.
|
|
55943
|
-
*/
|
|
55944
|
-
function resolveArrangementKnobs(input) {
|
|
55945
|
-
const length = input.blockKind === "block.hero" ? resolveHeroTitleLength({ ...input.content }, "look") : null;
|
|
55946
|
-
const exposure = arrangementKnobExposure(input.blockKind, input.look, length);
|
|
55947
|
-
const knobs = resolveEffectiveKnobs({
|
|
55948
|
-
exposure,
|
|
55949
|
-
content: normalizedHeadlinePreference(input.content)
|
|
55950
|
-
});
|
|
55951
|
-
return {
|
|
55952
|
-
length,
|
|
55953
|
-
exposure,
|
|
55954
|
-
knobs
|
|
55955
|
-
};
|
|
55956
|
-
}
|
|
55957
|
-
/** The values an owner can choose for an exposed knob, before any length cap. */
|
|
55958
|
-
function arrangementKnobChoices(exposure) {
|
|
55959
|
-
return exposure.definition.values.filter((value) => (exposure.lookValues?.includes(value) ?? true) && (exposure.styleValues?.includes(value) ?? true));
|
|
55960
|
-
}
|
|
55961
|
-
function arrangementKnobExposure(blockKind, look, length) {
|
|
55962
|
-
return systemCustomizeFacetDefinitionsForBlock(blockKind).flatMap((facet) => {
|
|
55963
|
-
if (facet.knob === undefined || facet.target.kind !== "content-field") return [];
|
|
55964
|
-
const id = facet.target.field;
|
|
55965
|
-
const defaults = look.look.structure.knobDefaults ?? {};
|
|
55966
|
-
return [{
|
|
55967
|
-
definition: {
|
|
55968
|
-
id,
|
|
55969
|
-
defaultValue: defaults[id] ?? facet.defaultValue,
|
|
55970
|
-
values: facet.values.map((value) => value.value),
|
|
55971
|
-
...knobKindMetadata(facet.knob)
|
|
55972
|
-
},
|
|
55973
|
-
exposed: exposedKnobIds(look).includes(id),
|
|
55974
|
-
forced: look.look.structure.forcedKnobs?.[id],
|
|
55975
|
-
lookValues: look.look.structure.knobValues?.[id],
|
|
55976
|
-
styleValues: look.knobValues[id],
|
|
55977
|
-
lengthValues: id === "titleSize" ? headlineAllowedValues(length) : undefined
|
|
55978
|
-
}];
|
|
55979
|
-
});
|
|
55980
|
-
}
|
|
55981
|
-
function knobKindMetadata(knob) {
|
|
55982
|
-
return knob.kind === "fixed" ? { ordered: knob.ordered } : {
|
|
55983
|
-
ordered: false,
|
|
55984
|
-
textMaxLength: knob.maxLength
|
|
55985
|
-
};
|
|
55986
|
-
}
|
|
55987
|
-
function headlineAllowedValues(length) {
|
|
55988
|
-
switch (length) {
|
|
55989
|
-
case "long": return ["quiet"];
|
|
55990
|
-
case "medium": return ["quiet", "auto"];
|
|
55991
|
-
case "short": return [
|
|
55992
|
-
"quiet",
|
|
55993
|
-
"auto",
|
|
55994
|
-
"display"
|
|
55995
|
-
];
|
|
55996
|
-
case null: return undefined;
|
|
55997
|
-
}
|
|
55998
|
-
}
|
|
55999
|
-
/** `titleSize` keeps its five stored values; under a Look they read as three steps. */
|
|
56000
|
-
function normalizedHeadlinePreference(content) {
|
|
56001
|
-
switch (content.titleSize) {
|
|
56002
|
-
case "editorial": return {
|
|
56003
|
-
...content,
|
|
56004
|
-
titleSize: "auto"
|
|
56005
|
-
};
|
|
56006
|
-
case "poster": return {
|
|
56007
|
-
...content,
|
|
56008
|
-
titleSize: "display"
|
|
56009
|
-
};
|
|
56010
|
-
default: return content;
|
|
56011
|
-
}
|
|
56012
|
-
}
|
|
56013
|
-
function exposedKnobIds(look) {
|
|
56014
|
-
return [...look.look.structure.knobs, ...look.addKnobs ?? []].filter((id) => !look.removeKnobs.some((removed) => removed === id));
|
|
56015
|
-
}
|
|
56016
|
-
|
|
56017
56437
|
//#endregion
|
|
56018
56438
|
//#region ../blocks/src/system/transforms/registry/offeringsPreview.ts
|
|
56019
56439
|
/** Reuse the existing occurrence read for the date strip and card date rows. */
|
|
@@ -56477,6 +56897,30 @@ function resolvePreResolvedLink(link$2) {
|
|
|
56477
56897
|
return !kind && typeof link$2.href === "string" ? resolveExternalLink(link$2) : null;
|
|
56478
56898
|
}
|
|
56479
56899
|
|
|
56900
|
+
//#endregion
|
|
56901
|
+
//#region ../blocks/src/system/transforms/registry/mapDrawing.ts
|
|
56902
|
+
/**
|
|
56903
|
+
* Map tokens for the section ground a drawing sits on. The value is the
|
|
56904
|
+
* section's `_sectionStyles.background`, resolved by the same owner as the
|
|
56905
|
+
* section's own foreground; theme-core decides every map colour from it.
|
|
56906
|
+
*/
|
|
56907
|
+
const mapDrawingStyleTransform = {
|
|
56908
|
+
id: "mapDrawing.resolveStyle",
|
|
56909
|
+
kind: "formatter",
|
|
56910
|
+
summary: "Resolve map drawing tokens from the section ground and site style",
|
|
56911
|
+
run: (value, options, context) => mapDrawingStyle({
|
|
56912
|
+
foreground: resolveSectionSurfaceForeground(value ?? sectionFallbackBackground(options?.fallbackToken), context, { fallbackToken: options?.fallbackToken }),
|
|
56913
|
+
palette: context.theme.palette,
|
|
56914
|
+
skin: context.theme.skin
|
|
56915
|
+
})
|
|
56916
|
+
};
|
|
56917
|
+
function sectionFallbackBackground(token) {
|
|
56918
|
+
return token === undefined ? undefined : {
|
|
56919
|
+
type: "color",
|
|
56920
|
+
color: token
|
|
56921
|
+
};
|
|
56922
|
+
}
|
|
56923
|
+
|
|
56480
56924
|
//#endregion
|
|
56481
56925
|
//#region ../blocks/src/system/transforms/registry/eventCalendar.ts
|
|
56482
56926
|
const selectionParamSchema = z.object({ key: z.enum([
|
|
@@ -56581,7 +57025,8 @@ const builtinTransformDefinitions = [
|
|
|
56581
57025
|
...linksTransforms,
|
|
56582
57026
|
...boxStylesTransforms,
|
|
56583
57027
|
...contentTransforms,
|
|
56584
|
-
...headerRuntimeTransforms
|
|
57028
|
+
...headerRuntimeTransforms,
|
|
57029
|
+
mapDrawingStyleTransform
|
|
56585
57030
|
];
|
|
56586
57031
|
const defaultTransforms = createTransformRegistry(builtinTransformDefinitions);
|
|
56587
57032
|
|
|
@@ -57449,6 +57894,105 @@ function renderMark(mark, key, child) {
|
|
|
57449
57894
|
}
|
|
57450
57895
|
}
|
|
57451
57896
|
|
|
57897
|
+
//#endregion
|
|
57898
|
+
//#region ../blocks/src/system/runtime/nodes/location-map.view.tsx
|
|
57899
|
+
function OpeningHoursTable({ hours: hours$1, lookLayout }) {
|
|
57900
|
+
if (!hours$1) return null;
|
|
57901
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
57902
|
+
className: "rb-location-map-hours",
|
|
57903
|
+
"data-slot": lookLayout ? "schedule" : undefined,
|
|
57904
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("table", { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("caption", { children: "Opening hours" }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("tbody", { children: formatOpeningHoursRows(hours$1).map((row$1) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("tr", {
|
|
57905
|
+
"data-slot": lookLayout ? "row" : undefined,
|
|
57906
|
+
"data-closed": row$1.kind === "closed" ? true : undefined,
|
|
57907
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("th", {
|
|
57908
|
+
scope: "row",
|
|
57909
|
+
"data-slot": lookLayout ? "fact-label" : undefined,
|
|
57910
|
+
children: row$1.label
|
|
57911
|
+
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("td", {
|
|
57912
|
+
"data-slot": lookLayout ? "fact-value" : undefined,
|
|
57913
|
+
children: row$1.hours
|
|
57914
|
+
})]
|
|
57915
|
+
}, row$1.label)) })] }), hours$1.note ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { children: hours$1.note }) : null]
|
|
57916
|
+
});
|
|
57917
|
+
}
|
|
57918
|
+
function LocationMapView(props$1) {
|
|
57919
|
+
const { addressText, location } = props$1;
|
|
57920
|
+
const hours$1 = props$1.showOpeningHours === false ? null : props$1.openingHours ?? null;
|
|
57921
|
+
if (![
|
|
57922
|
+
location,
|
|
57923
|
+
addressText,
|
|
57924
|
+
hours$1
|
|
57925
|
+
].some(Boolean)) {
|
|
57926
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
|
|
57927
|
+
className: "rb-caption",
|
|
57928
|
+
style: textColorStyle("mutedText"),
|
|
57929
|
+
children: props$1.unresolvedMessage ?? "Location details coming soon."
|
|
57930
|
+
});
|
|
57931
|
+
}
|
|
57932
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(LocationMapDetails, {
|
|
57933
|
+
...props$1,
|
|
57934
|
+
openingHours: hours$1
|
|
57935
|
+
});
|
|
57936
|
+
}
|
|
57937
|
+
/** The entrance-photo Look leaves the drawing out; Look layouts treat the authored height as a minimum. */
|
|
57938
|
+
function LocationMapDrawing(props$1) {
|
|
57939
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AdmittedMapDrawingSvg, {
|
|
57940
|
+
drawing: props$1.drawing,
|
|
57941
|
+
wider: props$1.wider,
|
|
57942
|
+
label: props$1.addressText ?? undefined,
|
|
57943
|
+
height: props$1.heightPx,
|
|
57944
|
+
heightAs: props$1.lookLayout ? "minimum" : "fixed"
|
|
57945
|
+
});
|
|
57946
|
+
}
|
|
57947
|
+
/**
|
|
57948
|
+
* `data-map="none"` marks details shown without a drawing (none yet, or the entrance photo
|
|
57949
|
+
* takes its place), so map Looks lay the details out on their own instead of beside an empty space.
|
|
57950
|
+
*/
|
|
57951
|
+
function LocationMapDetails(props$1) {
|
|
57952
|
+
const drawing = props$1.showMap === false ? null : readableMapDrawing(props$1.drawing);
|
|
57953
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
57954
|
+
className: "rb-location-map",
|
|
57955
|
+
"data-map": drawing ? "drawing" : "none",
|
|
57956
|
+
children: [drawing ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(LocationMapDrawing, {
|
|
57957
|
+
...props$1,
|
|
57958
|
+
drawing
|
|
57959
|
+
}) : null, /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
57960
|
+
className: "rb-location-map-details",
|
|
57961
|
+
...props$1.detailsSlot,
|
|
57962
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(LocationMapPlace, { ...props$1 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(OpeningHoursTable, {
|
|
57963
|
+
lookLayout: props$1.lookLayout,
|
|
57964
|
+
hours: props$1.openingHours ?? null
|
|
57965
|
+
})]
|
|
57966
|
+
})]
|
|
57967
|
+
});
|
|
57968
|
+
}
|
|
57969
|
+
/** Address, door note and the directions actions. */
|
|
57970
|
+
function LocationMapPlace(props$1) {
|
|
57971
|
+
const address$1 = props$1.showAddressText && props$1.addressText ? props$1.addressText : null;
|
|
57972
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
57973
|
+
className: "rb-location-map-place",
|
|
57974
|
+
"data-slot": props$1.lookLayout ? "copy" : undefined,
|
|
57975
|
+
children: [
|
|
57976
|
+
address$1 ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
|
|
57977
|
+
className: "rb-location-map-address",
|
|
57978
|
+
"data-slot": props$1.lookLayout ? "headline" : undefined,
|
|
57979
|
+
children: address$1
|
|
57980
|
+
}) : null,
|
|
57981
|
+
props$1.doorNote ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
|
|
57982
|
+
className: "rb-location-map-door",
|
|
57983
|
+
children: props$1.doorNote
|
|
57984
|
+
}) : null,
|
|
57985
|
+
props$1.showDirections ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(LocationMapActions, {
|
|
57986
|
+
layout: "block",
|
|
57987
|
+
location: props$1.location,
|
|
57988
|
+
addressText: props$1.addressText,
|
|
57989
|
+
directionsLabel: props$1.directionsLabel,
|
|
57990
|
+
googleMapsLabel: props$1.googleMapsLabel
|
|
57991
|
+
}) : null
|
|
57992
|
+
]
|
|
57993
|
+
});
|
|
57994
|
+
}
|
|
57995
|
+
|
|
57452
57996
|
//#endregion
|
|
57453
57997
|
//#region ../blocks/src/system/runtime/nodes/basic.tsx
|
|
57454
57998
|
const TextNode = ({ value, children, blockContent, inlineTextFallbackPath, ...rest }) => {
|
|
@@ -58095,7 +58639,7 @@ function getIslandRootProps(kind, id) {
|
|
|
58095
58639
|
return resolved;
|
|
58096
58640
|
}
|
|
58097
58641
|
function serializeIslandProps(value) {
|
|
58098
|
-
return JSON.stringify(value).replace(/</g, "\\u003c");
|
|
58642
|
+
return JSON.stringify(serializeSurfaceTree(value)).replace(/</g, "\\u003c");
|
|
58099
58643
|
}
|
|
58100
58644
|
function IslandPropsScript({ value }) {
|
|
58101
58645
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("script", {
|
|
@@ -58449,105 +58993,6 @@ function HeaderControlNode({ className, children, "aria-label": label, "aria-exp
|
|
|
58449
58993
|
});
|
|
58450
58994
|
}
|
|
58451
58995
|
|
|
58452
|
-
//#endregion
|
|
58453
|
-
//#region ../blocks/src/system/runtime/nodes/svg.tsx
|
|
58454
|
-
/**
|
|
58455
|
-
* Strict SVG-`transform` validator.
|
|
58456
|
-
*
|
|
58457
|
-
* Accepts only a whitespace/comma-separated list of the geometric transform
|
|
58458
|
-
* functions (`translate`/`rotate`/`scale`/`skewX`/`skewY`/`matrix`) whose
|
|
58459
|
-
* arguments are plain numbers. This deliberately rejects anything else —
|
|
58460
|
-
* `url(...)`, CSS functions, `javascript:`, angle/length units, stray letters —
|
|
58461
|
-
* so a persisted custom-block tree can't smuggle an executable or exfiltrating
|
|
58462
|
-
* value into the attribute.
|
|
58463
|
-
*/
|
|
58464
|
-
const TRANSFORM_NUMBER = String.raw`-?(?:\d+\.?\d*|\.\d+)(?:e-?\d+)?`;
|
|
58465
|
-
const TRANSFORM_ARGS = String.raw`${TRANSFORM_NUMBER}(?:[\s,]+${TRANSFORM_NUMBER})*`;
|
|
58466
|
-
const TRANSFORM_FN = String.raw`(?:translate|rotate|scale|skewX|skewY|matrix)\(\s*${TRANSFORM_ARGS}\s*\)`;
|
|
58467
|
-
const SAFE_TRANSFORM_RE = new RegExp(String.raw`^\s*${TRANSFORM_FN}(?:[\s,]*${TRANSFORM_FN})*\s*$`);
|
|
58468
|
-
function safeTransform(value) {
|
|
58469
|
-
if (typeof value !== "string") return undefined;
|
|
58470
|
-
const trimmed = value.trim();
|
|
58471
|
-
if (trimmed.length === 0) return undefined;
|
|
58472
|
-
return SAFE_TRANSFORM_RE.test(trimmed) ? trimmed : undefined;
|
|
58473
|
-
}
|
|
58474
|
-
/**
|
|
58475
|
-
* Turn paint props into a CSS style object. Colour values pass through as-is so
|
|
58476
|
-
* they may reference theme tokens via `var()`, which only resolves in a CSS
|
|
58477
|
-
* property context (not in a bare presentation attribute).
|
|
58478
|
-
*/
|
|
58479
|
-
function paintStyle(shape) {
|
|
58480
|
-
const style = {};
|
|
58481
|
-
if (shape.fill !== undefined) style.fill = shape.fill;
|
|
58482
|
-
if (shape.stroke !== undefined) style.stroke = shape.stroke;
|
|
58483
|
-
if (shape.strokeWidth !== undefined) style.strokeWidth = shape.strokeWidth;
|
|
58484
|
-
if (shape.fillOpacity !== undefined) style.fillOpacity = shape.fillOpacity;
|
|
58485
|
-
if (shape.strokeOpacity !== undefined) style.strokeOpacity = shape.strokeOpacity;
|
|
58486
|
-
if (shape.strokeLinecap !== undefined) style.strokeLinecap = shape.strokeLinecap;
|
|
58487
|
-
if (shape.strokeLinejoin !== undefined) style.strokeLinejoin = shape.strokeLinejoin;
|
|
58488
|
-
if (shape.strokeDasharray !== undefined) style.strokeDasharray = shape.strokeDasharray;
|
|
58489
|
-
return style;
|
|
58490
|
-
}
|
|
58491
|
-
function renderShape(shape, key) {
|
|
58492
|
-
const style = paintStyle(shape);
|
|
58493
|
-
const transform = safeTransform(shape.transform);
|
|
58494
|
-
switch (shape.kind) {
|
|
58495
|
-
case "path": return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", {
|
|
58496
|
-
d: shape.d,
|
|
58497
|
-
style,
|
|
58498
|
-
transform
|
|
58499
|
-
}, key);
|
|
58500
|
-
case "ellipse": return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("ellipse", {
|
|
58501
|
-
cx: shape.cx,
|
|
58502
|
-
cy: shape.cy,
|
|
58503
|
-
rx: shape.rx,
|
|
58504
|
-
ry: shape.ry,
|
|
58505
|
-
style,
|
|
58506
|
-
transform
|
|
58507
|
-
}, key);
|
|
58508
|
-
case "circle": return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("circle", {
|
|
58509
|
-
cx: shape.cx,
|
|
58510
|
-
cy: shape.cy,
|
|
58511
|
-
r: shape.r,
|
|
58512
|
-
style,
|
|
58513
|
-
transform
|
|
58514
|
-
}, key);
|
|
58515
|
-
case "rect": return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("rect", {
|
|
58516
|
-
x: shape.x,
|
|
58517
|
-
y: shape.y,
|
|
58518
|
-
width: shape.width,
|
|
58519
|
-
height: shape.height,
|
|
58520
|
-
rx: shape.rx,
|
|
58521
|
-
ry: shape.ry,
|
|
58522
|
-
style,
|
|
58523
|
-
transform
|
|
58524
|
-
}, key);
|
|
58525
|
-
case "line": return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("line", {
|
|
58526
|
-
x1: shape.x1,
|
|
58527
|
-
y1: shape.y1,
|
|
58528
|
-
x2: shape.x2,
|
|
58529
|
-
y2: shape.y2,
|
|
58530
|
-
style,
|
|
58531
|
-
transform
|
|
58532
|
-
}, key);
|
|
58533
|
-
default: return null;
|
|
58534
|
-
}
|
|
58535
|
-
}
|
|
58536
|
-
const SvgNode = ({ blockId: _blockId, blockKind: _blockKind, blockContent: _blockContent, fragmentRegistry: _fragmentRegistry, pathBase: _pathBase, viewBox, width, height, className, style, ariaHidden = true, shapes }) => {
|
|
58537
|
-
const safeShapes = Array.isArray(shapes) ? shapes : [];
|
|
58538
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
|
|
58539
|
-
viewBox,
|
|
58540
|
-
width,
|
|
58541
|
-
height,
|
|
58542
|
-
className,
|
|
58543
|
-
style,
|
|
58544
|
-
"aria-hidden": ariaHidden,
|
|
58545
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
58546
|
-
fill: "none",
|
|
58547
|
-
children: safeShapes.map((shape, index) => renderShape(shape, index))
|
|
58548
|
-
});
|
|
58549
|
-
};
|
|
58550
|
-
|
|
58551
58996
|
//#endregion
|
|
58552
58997
|
//#region ../blocks/src/system/runtime/nodes/appointment-services.tsx
|
|
58553
58998
|
const publicVenueSchema = z.object({
|
|
@@ -60900,7 +61345,11 @@ function EventVenueFact({ venue }) {
|
|
|
60900
61345
|
venue.address ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
|
|
60901
61346
|
className: "rb-caption",
|
|
60902
61347
|
children: venue.address
|
|
60903
|
-
}) : null
|
|
61348
|
+
}) : null,
|
|
61349
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(LocationMapActions, {
|
|
61350
|
+
location: venue.location,
|
|
61351
|
+
addressText: venue.address
|
|
61352
|
+
})
|
|
60904
61353
|
]
|
|
60905
61354
|
}) : null;
|
|
60906
61355
|
}
|
|
@@ -61041,11 +61490,11 @@ function acceptedProductNames(props$1) {
|
|
|
61041
61490
|
const memberships = props$1.showAcceptedMemberships !== false ? (props$1.applicableMemberships ?? []).map(({ name }) => name) : [];
|
|
61042
61491
|
return [...passes, ...memberships];
|
|
61043
61492
|
}
|
|
61044
|
-
function EventVenueMap({ venue, showMap, mapHeight, mapClassName
|
|
61045
|
-
if (!showMap || !
|
|
61046
|
-
return
|
|
61047
|
-
|
|
61048
|
-
|
|
61493
|
+
function EventVenueMap({ venue, showMap, mapHeight, mapClassName }) {
|
|
61494
|
+
if (!showMap || !venue?.drawing) return null;
|
|
61495
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(MapDrawingSvg, {
|
|
61496
|
+
drawing: venue.drawing,
|
|
61497
|
+
label: venue.name,
|
|
61049
61498
|
className: mapClassName,
|
|
61050
61499
|
height: mapHeight
|
|
61051
61500
|
});
|
|
@@ -61064,7 +61513,7 @@ function selectedEventPricing(event, showCost) {
|
|
|
61064
61513
|
};
|
|
61065
61514
|
}
|
|
61066
61515
|
function SelectedEventDetailsView(props$1) {
|
|
61067
|
-
const { selection, showVenue, showMap, showOtherDates, showTitle, showDescription, showCapacity, mapHeight, mapClassName,
|
|
61516
|
+
const { selection, showVenue, showMap, showOtherDates, showTitle, showDescription, showCapacity, mapHeight, mapClassName, acceptedItems } = props$1;
|
|
61068
61517
|
const selected = selection.selected;
|
|
61069
61518
|
const venue = showVenue ? selected.venue : undefined;
|
|
61070
61519
|
const pricing = selectedEventPricing(selected, props$1.showCost);
|
|
@@ -61095,8 +61544,7 @@ function SelectedEventDetailsView(props$1) {
|
|
|
61095
61544
|
venue,
|
|
61096
61545
|
showMap,
|
|
61097
61546
|
mapHeight,
|
|
61098
|
-
mapClassName
|
|
61099
|
-
renderVenueMap
|
|
61547
|
+
mapClassName
|
|
61100
61548
|
})]
|
|
61101
61549
|
}),
|
|
61102
61550
|
showOtherDates ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(OtherEventDates, { selection }) : null
|
|
@@ -61123,7 +61571,6 @@ function LegacyEventDetailsView(props$1) {
|
|
|
61123
61571
|
autoApplyDiscount: props$1.autoApplyDiscount ?? null,
|
|
61124
61572
|
mapHeight: props$1.mapHeight ?? 200,
|
|
61125
61573
|
mapClassName: props$1.mapClassName ?? "event-details-map",
|
|
61126
|
-
renderVenueMap: props$1.renderVenueMap,
|
|
61127
61574
|
acceptedItems: acceptedProductNames(props$1)
|
|
61128
61575
|
});
|
|
61129
61576
|
}
|
|
@@ -61164,22 +61611,6 @@ function EventDetailsView(props$1) {
|
|
|
61164
61611
|
|
|
61165
61612
|
//#endregion
|
|
61166
61613
|
//#region ../blocks/src/system/runtime/nodes/event-details.server.tsx
|
|
61167
|
-
function ServerVenueMap({ venueName, className, height }) {
|
|
61168
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
61169
|
-
className: "event-details-map-wrap rb-w-full rb-ml-auto",
|
|
61170
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
61171
|
-
className,
|
|
61172
|
-
style: {
|
|
61173
|
-
height: height ?? 200,
|
|
61174
|
-
width: "100%",
|
|
61175
|
-
borderRadius: "0.5rem",
|
|
61176
|
-
overflow: "hidden",
|
|
61177
|
-
backgroundColor: "rgb(var(--tb-surface))"
|
|
61178
|
-
},
|
|
61179
|
-
"aria-label": `Map showing ${venueName}`
|
|
61180
|
-
})
|
|
61181
|
-
});
|
|
61182
|
-
}
|
|
61183
61614
|
function EventDetailsHydration({ props: props$1, presentation, scopedEvents, subject, nowIso }) {
|
|
61184
61615
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(IslandPropsScript, { value: {
|
|
61185
61616
|
...props$1.arrangement ? {
|
|
@@ -61239,8 +61670,7 @@ function EventDetailsSSR(props$1) {
|
|
|
61239
61670
|
}),
|
|
61240
61671
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(EventDetailsView, {
|
|
61241
61672
|
...presentation,
|
|
61242
|
-
mapClassName: "venue-map event-details-map"
|
|
61243
|
-
renderVenueMap: ServerVenueMap
|
|
61673
|
+
mapClassName: "venue-map event-details-map"
|
|
61244
61674
|
}),
|
|
61245
61675
|
children
|
|
61246
61676
|
]
|
|
@@ -61248,100 +61678,34 @@ function EventDetailsSSR(props$1) {
|
|
|
61248
61678
|
}
|
|
61249
61679
|
var event_details_server_default = EventDetailsSSR;
|
|
61250
61680
|
|
|
61251
|
-
//#endregion
|
|
61252
|
-
//#region ../blocks/src/system/runtime/nodes/location-map.view.tsx
|
|
61253
|
-
function OpeningHoursTable({ hours: hours$1 }) {
|
|
61254
|
-
if (!hours$1) return null;
|
|
61255
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("table", { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("caption", { children: "Opening hours" }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("tbody", { children: formatOpeningHoursRows(hours$1).map((row$1) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("tr", {
|
|
61256
|
-
"data-closed": row$1.kind === "closed" ? true : undefined,
|
|
61257
|
-
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("th", {
|
|
61258
|
-
scope: "row",
|
|
61259
|
-
children: row$1.label
|
|
61260
|
-
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("td", { children: row$1.hours })]
|
|
61261
|
-
}, row$1.label)) })] }), hours$1.note ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { children: hours$1.note }) : null] });
|
|
61262
|
-
}
|
|
61263
|
-
function LocationMapDirections({ url, label }) {
|
|
61264
|
-
return url ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ThemedButtonLink, {
|
|
61265
|
-
href: url,
|
|
61266
|
-
target: "_blank",
|
|
61267
|
-
rel: "noreferrer",
|
|
61268
|
-
variant: "ghost",
|
|
61269
|
-
size: "sm",
|
|
61270
|
-
extraClassName: "rb-w-fit",
|
|
61271
|
-
label
|
|
61272
|
-
}) : null;
|
|
61273
|
-
}
|
|
61274
|
-
function LocationMapView(props$1) {
|
|
61275
|
-
const { addressText, location, renderMap, zoom, heightPx, showAddressText, directionsLabel } = props$1;
|
|
61276
|
-
const directionsUrl = props$1.showDirections ? buildGoogleMapsDirectionsUrl({
|
|
61277
|
-
addressText,
|
|
61278
|
-
location
|
|
61279
|
-
}) : null;
|
|
61280
|
-
const hours$1 = props$1.showOpeningHours === false ? null : props$1.openingHours ?? null;
|
|
61281
|
-
if (![
|
|
61282
|
-
location,
|
|
61283
|
-
addressText,
|
|
61284
|
-
directionsUrl,
|
|
61285
|
-
hours$1
|
|
61286
|
-
].some(Boolean)) {
|
|
61287
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
|
|
61288
|
-
className: "rb-caption",
|
|
61289
|
-
style: textColorStyle("mutedText"),
|
|
61290
|
-
children: props$1.unresolvedMessage ?? "Location details coming soon."
|
|
61291
|
-
});
|
|
61292
|
-
}
|
|
61293
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
61294
|
-
className: "rb-flex rb-flex-col rb-gap-4 rb-text-left",
|
|
61295
|
-
children: [
|
|
61296
|
-
location && renderMap ? renderMap({
|
|
61297
|
-
addressText,
|
|
61298
|
-
location,
|
|
61299
|
-
className: "rb-location-map-canvas",
|
|
61300
|
-
height: heightPx,
|
|
61301
|
-
zoom
|
|
61302
|
-
}) : null,
|
|
61303
|
-
showAddressText && addressText ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
|
|
61304
|
-
className: "rb-caption",
|
|
61305
|
-
style: textColorStyle("mutedText"),
|
|
61306
|
-
children: addressText
|
|
61307
|
-
}) : null,
|
|
61308
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(OpeningHoursTable, { hours: hours$1 }),
|
|
61309
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(LocationMapDirections, {
|
|
61310
|
-
url: directionsUrl,
|
|
61311
|
-
label: directionsLabel
|
|
61312
|
-
})
|
|
61313
|
-
]
|
|
61314
|
-
});
|
|
61315
|
-
}
|
|
61316
|
-
|
|
61317
61681
|
//#endregion
|
|
61318
61682
|
//#region ../blocks/src/system/runtime/nodes/location-map.server.tsx
|
|
61683
|
+
const lookPresentationSchema = z.object({
|
|
61684
|
+
lookSlots: lookListPresentationSchemaShape.lookSlots,
|
|
61685
|
+
itemSurfaces: lookListPresentationSchemaShape.itemSurfaces
|
|
61686
|
+
});
|
|
61319
61687
|
function LocationMapSSR(props$1) {
|
|
61320
61688
|
const normalized = normalizeLocationMapProps(props$1);
|
|
61321
|
-
|
|
61689
|
+
if (normalized.resolvedLocation.kind === "unresolved") return null;
|
|
61322
61690
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
61323
61691
|
className: `location-map ${normalized.className ?? ""}`.trim(),
|
|
61324
61692
|
"data-block": "location-map",
|
|
61325
|
-
|
|
61326
|
-
children: [
|
|
61327
|
-
|
|
61328
|
-
|
|
61329
|
-
|
|
61330
|
-
|
|
61331
|
-
|
|
61332
|
-
|
|
61333
|
-
|
|
61334
|
-
|
|
61335
|
-
|
|
61336
|
-
|
|
61337
|
-
|
|
61338
|
-
|
|
61339
|
-
"aria-label": addressText ? `Map showing ${addressText}` : "Map showing business location"
|
|
61340
|
-
})
|
|
61341
|
-
}),
|
|
61342
|
-
props$1.children
|
|
61343
|
-
]
|
|
61693
|
+
style: props$1.mapStyle ?? undefined,
|
|
61694
|
+
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(LocationMapView, {
|
|
61695
|
+
...normalized,
|
|
61696
|
+
showMap: props$1.showMap !== false,
|
|
61697
|
+
lookLayout: props$1.lookSlots != null,
|
|
61698
|
+
detailsSlot: lookDetailsSlot(props$1)
|
|
61699
|
+
}), props$1.children]
|
|
61700
|
+
});
|
|
61701
|
+
}
|
|
61702
|
+
/** Legacy and automatic-Look markup carries no slot; Look-only layouts mark the details as the panel. */
|
|
61703
|
+
function lookDetailsSlot(props$1) {
|
|
61704
|
+
const presentation = lookPresentationSchema.safeParse({
|
|
61705
|
+
lookSlots: props$1.lookSlots ?? undefined,
|
|
61706
|
+
itemSurfaces: props$1.itemSurfaces ?? undefined
|
|
61344
61707
|
});
|
|
61708
|
+
return presentation.success ? listLookSlot(presentation.data, "panel") : {};
|
|
61345
61709
|
}
|
|
61346
61710
|
var location_map_server_default = LocationMapSSR;
|
|
61347
61711
|
|
|
@@ -67426,7 +67790,7 @@ function prepareBlockRender(input) {
|
|
|
67426
67790
|
resolvedThemeConfig: resolveThemeConfigForBindings(input.themeConfig),
|
|
67427
67791
|
viewModelOverrides: input.viewModelOverrides
|
|
67428
67792
|
}),
|
|
67429
|
-
themeForTransforms:
|
|
67793
|
+
themeForTransforms: withThemeRuntimeFacts(input.theme, input.themeConfig),
|
|
67430
67794
|
proseHoverCandidate: parseThemeColorToken(input.themeConfig?.typography.proseLinkStyle?.hoverColorToken) ?? undefined
|
|
67431
67795
|
};
|
|
67432
67796
|
}
|
|
@@ -67446,11 +67810,13 @@ function buildBlockViewModel(input) {
|
|
|
67446
67810
|
}
|
|
67447
67811
|
};
|
|
67448
67812
|
}
|
|
67449
|
-
|
|
67813
|
+
/** The theme facts transforms decide from: button system, and the arrangement skin map tokens follow. */
|
|
67814
|
+
function withThemeRuntimeFacts(theme, themeConfig) {
|
|
67450
67815
|
if (!themeConfig) return theme;
|
|
67451
67816
|
return {
|
|
67452
67817
|
...theme,
|
|
67453
|
-
buttons: themeConfig.buttons ?? generateDefaultButtonSystem(themeConfig)
|
|
67818
|
+
buttons: themeConfig.buttons ?? generateDefaultButtonSystem(themeConfig),
|
|
67819
|
+
...themeConfig.skin === undefined ? {} : { skin: themeConfig.skin }
|
|
67454
67820
|
};
|
|
67455
67821
|
}
|
|
67456
67822
|
function beginBlockRenderMeasurement() {
|
|
@@ -68385,12 +68751,31 @@ function getRenderableContent(block, previewStage = "published") {
|
|
|
68385
68751
|
return selectBlockContent(block, previewStage);
|
|
68386
68752
|
}
|
|
68387
68753
|
function arrangementRuntime(content) {
|
|
68388
|
-
const value = content._arrangementLooks;
|
|
68389
|
-
return isObjectRecord(value) && isObjectRecord(value.byMode) && Array.isArray(value.available) && Array.isArray(value.rhythm) ? value : null;
|
|
68754
|
+
const value = parseSurfaceTree(content._arrangementLooks);
|
|
68755
|
+
return isObjectRecord(value) && isObjectRecord(value.byMode) && Array.isArray(value.available) && Array.isArray(value.rhythm) ? restoreArrangementRuntime(value) : null;
|
|
68756
|
+
}
|
|
68757
|
+
/** JSON transports carry resolver inputs; rebuild every surface at this boundary. */
|
|
68758
|
+
function restoreCompiledLook(look) {
|
|
68759
|
+
return {
|
|
68760
|
+
...look,
|
|
68761
|
+
itemSurfaces: Object.fromEntries(Object.entries(look.itemSurfaces).map(([slot, surface]) => [slot, parseResolvedSurface(surface)])),
|
|
68762
|
+
...look.roleSurfaces ? { roleSurfaces: {
|
|
68763
|
+
card: parseResolvedSurface(look.roleSurfaces.card),
|
|
68764
|
+
statement: parseResolvedSurface(look.roleSurfaces.statement),
|
|
68765
|
+
highlight: parseResolvedSurface(look.roleSurfaces.highlight)
|
|
68766
|
+
} } : {}
|
|
68767
|
+
};
|
|
68768
|
+
}
|
|
68769
|
+
function restoreArrangementRuntime(runtime) {
|
|
68770
|
+
return {
|
|
68771
|
+
...runtime,
|
|
68772
|
+
available: runtime.available.map(restoreCompiledLook),
|
|
68773
|
+
byMode: Object.fromEntries(Object.entries(runtime.byMode).map(([mode, look]) => [mode, restoreCompiledLook(look)]))
|
|
68774
|
+
};
|
|
68390
68775
|
}
|
|
68391
68776
|
function effectiveLookFromContent(content) {
|
|
68392
68777
|
const value = content._effectiveLook;
|
|
68393
|
-
return isObjectRecord(value) && isObjectRecord(value.look) ? value : null;
|
|
68778
|
+
return isObjectRecord(value) && isObjectRecord(value.look) ? restoreCompiledLook(value) : null;
|
|
68394
68779
|
}
|
|
68395
68780
|
function planArrangementContent(blockKind, manifest, content, audience) {
|
|
68396
68781
|
const runtime = arrangementRuntime(content);
|
|
@@ -68433,6 +68818,7 @@ function planArrangementContent(blockKind, manifest, content, audience) {
|
|
|
68433
68818
|
}),
|
|
68434
68819
|
...arrangementPanelContent(activeContent, effective, mode),
|
|
68435
68820
|
...arrangementQuoteContent(blockKind, effective, values),
|
|
68821
|
+
_arrangementLooks: runtime,
|
|
68436
68822
|
_effectiveLook: effective,
|
|
68437
68823
|
_lookHooks: arrangementContentHooks(effective, mode, length, {
|
|
68438
68824
|
...facts,
|
|
@@ -68492,7 +68878,8 @@ function arrangementContentFacts(content) {
|
|
|
68492
68878
|
facts: Array.isArray(content.facts) && content.facts.length > 0,
|
|
68493
68879
|
featured,
|
|
68494
68880
|
outcome: typeof content.outcome === "string" && content.outcome.length > 0,
|
|
68495
|
-
figure: typeof content.figure === "string" && content.figure.trim().length > 0
|
|
68881
|
+
figure: typeof content.figure === "string" && content.figure.trim().length > 0,
|
|
68882
|
+
entrance: isObjectRecord(content.entrancePhoto)
|
|
68496
68883
|
}
|
|
68497
68884
|
};
|
|
68498
68885
|
}
|
|
@@ -68501,7 +68888,7 @@ function arrangementPhotoCount(content) {
|
|
|
68501
68888
|
if (Array.isArray(content.cards)) return content.cards.filter((card) => isObjectRecord(card) && isObjectRecord(card.media)).length;
|
|
68502
68889
|
if (Array.isArray(content.members)) return content.members.filter((member) => isObjectRecord(member) && isObjectRecord(member.photo)).length;
|
|
68503
68890
|
if (Array.isArray(content.images)) return content.images.filter((item) => isObjectRecord(item) && isObjectRecord(item.image)).length;
|
|
68504
|
-
if (isObjectRecord(content.media)) return 1;
|
|
68891
|
+
if (isObjectRecord(content.media) || isObjectRecord(content.entrancePhoto)) return 1;
|
|
68505
68892
|
const section$2 = isObjectRecord(content._sectionStyles) ? content._sectionStyles : {};
|
|
68506
68893
|
const background = isObjectRecord(section$2.background) ? section$2.background : {};
|
|
68507
68894
|
return isObjectRecord(background.image) ? 1 : 0;
|
|
@@ -76927,11 +77314,11 @@ function isManagementPage(value) {
|
|
|
76927
77314
|
function isManagementBlock(value) {
|
|
76928
77315
|
return "kind" in value;
|
|
76929
77316
|
}
|
|
76930
|
-
function singlePlannedCommand(commands) {
|
|
76931
|
-
if (commands.length !== 1) {
|
|
76932
|
-
throw new Error(`Expected exactly one one-off site command, got ${commands.length}.`);
|
|
77317
|
+
function singlePlannedCommand(commands$1) {
|
|
77318
|
+
if (commands$1.length !== 1) {
|
|
77319
|
+
throw new Error(`Expected exactly one one-off site command, got ${commands$1.length}.`);
|
|
76933
77320
|
}
|
|
76934
|
-
const plannedCommand = commands[0];
|
|
77321
|
+
const plannedCommand = commands$1[0];
|
|
76935
77322
|
if (!plannedCommand) {
|
|
76936
77323
|
throw new Error("Expected one one-off site command, got none.");
|
|
76937
77324
|
}
|
|
@@ -79405,7 +79792,7 @@ async function loadConfig(configPath, output) {
|
|
|
79405
79792
|
return { errorMessage: "No config path provided." };
|
|
79406
79793
|
}
|
|
79407
79794
|
try {
|
|
79408
|
-
const { loadConfigFile: loadConfigFile$1 } = await import("../load-config-
|
|
79795
|
+
const { loadConfigFile: loadConfigFile$1 } = await import("../load-config-BGzlsmtt.mjs");
|
|
79409
79796
|
const rawConfig = await loadConfigFile$1(configPath);
|
|
79410
79797
|
const parsed = riverbankSiteConfigSchema.safeParse(rawConfig);
|
|
79411
79798
|
if (!parsed.success) {
|
|
@@ -90904,7 +91291,8 @@ const allowedPathPrefixes = [
|
|
|
90904
91291
|
"/sites/{siteId}/bookings/event-attendees",
|
|
90905
91292
|
"/sites/{siteId}/bookings/event-categories",
|
|
90906
91293
|
"/sites/{siteId}/bookings/venues",
|
|
90907
|
-
"/sites/{siteId}/
|
|
91294
|
+
"/sites/{siteId}/location/geocode",
|
|
91295
|
+
"/sites/{siteId}/location/drawing-preview",
|
|
90908
91296
|
"/sites/{siteId}/bookings/customers",
|
|
90909
91297
|
"/sites/{siteId}/bookings/people",
|
|
90910
91298
|
"/sites/{siteId}/bookings/person-records",
|
|
@@ -92433,11 +92821,12 @@ const appointmentSetupVenueChoiceSchema = z.discriminatedUnion("kind", [
|
|
|
92433
92821
|
title: z.string().trim().min(1),
|
|
92434
92822
|
description: z.string().nullable(),
|
|
92435
92823
|
timezone: z.string().trim().min(1).nullable(),
|
|
92436
|
-
|
|
92824
|
+
locationValue: locationValueSchema.nullable().optional(),
|
|
92825
|
+
addressJson: z.record(z.string(), z.unknown()).optional(),
|
|
92437
92826
|
locationJson: z.object({
|
|
92438
92827
|
lat: z.number(),
|
|
92439
92828
|
lng: z.number()
|
|
92440
|
-
}).nullable()
|
|
92829
|
+
}).nullable().optional()
|
|
92441
92830
|
})
|
|
92442
92831
|
]);
|
|
92443
92832
|
const appointmentSetupPaymentDraftSchema = z.discriminatedUnion("kind", [
|
|
@@ -92608,13 +92997,6 @@ function getEventDeliveryModeLabel(mode) {
|
|
|
92608
92997
|
case "hybrid": return "In person and online";
|
|
92609
92998
|
}
|
|
92610
92999
|
}
|
|
92611
|
-
function getEventPricingOptionAttendanceScopeLabel(scope) {
|
|
92612
|
-
switch (scope) {
|
|
92613
|
-
case "both": return "In person and online";
|
|
92614
|
-
case "in_person": return "In person only";
|
|
92615
|
-
case "online": return "Online only";
|
|
92616
|
-
}
|
|
92617
|
-
}
|
|
92618
93000
|
|
|
92619
93001
|
//#endregion
|
|
92620
93002
|
//#region ../api/src/siteBanner.ts
|