@riverbankcms/sdk 0.78.0 → 0.78.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +45 -43
- package/dist/{PreviewEditorSidebar-RIKFQ72L.mjs → PreviewEditorSidebar-4DXLYX2V.mjs} +29 -21
- package/dist/{PreviewEditorUI-XO7TUWKK.mjs → PreviewEditorUI-CS5P4N3P.mjs} +4 -4
- package/dist/SdkPreviewModeRuntime-IJDHTW4W.mjs +8 -0
- package/dist/_dts/ai/src/contracts/proposals.d.ts +36 -0
- package/dist/_dts/api/src/contentRuntime.d.ts +1 -0
- package/dist/_dts/api/src/endpoints.d.ts +9 -0
- package/dist/_dts/api/src/index.d.ts +3 -3
- package/dist/_dts/api/src/public/types.d.ts +1 -1
- package/dist/_dts/api/src/request.d.ts +3 -11
- package/dist/_dts/api/src/sdkConfig/contracts.d.ts +1 -0
- package/dist/_dts/api/src/sdkContracts.d.ts +7 -1
- package/dist/_dts/api/src/siteManagementEndpoints.d.ts +10 -0
- package/dist/_dts/api/src/sitePlatformEndpoints.d.ts +1 -0
- package/dist/_dts/api/src/siteRuntimeEndpoints.d.ts +15 -19
- package/dist/_dts/api/src/types.d.ts +11 -26
- package/dist/_dts/block-form/src/fields/types.d.ts +6 -0
- package/dist/_dts/block-form/src/widgets/RepeaterField/components/RepeaterList.d.ts +3 -2
- package/dist/_dts/block-form/src/widgets/RepeaterField/components/RepeaterRow.d.ts +6 -3
- package/dist/_dts/block-form/src/widgets/RepeaterField/components/RepeaterRowActions.d.ts +8 -3
- package/dist/_dts/block-form/src/widgets/RepeaterField/hooks/index.d.ts +1 -1
- package/dist/_dts/block-form/src/widgets/RepeaterField/hooks/useLinearRepeaterDnd.d.ts +1 -0
- package/dist/_dts/block-form/src/widgets/RepeaterField/hooks/useRepeaterPointerDragCapability.d.ts +1 -0
- package/dist/_dts/block-form/src/widgets/RepeaterField/hooks/useResolvedItemLabel.d.ts +7 -0
- package/dist/_dts/block-form/src/widgets/RepeaterField/utils/buildSummary.d.ts +1 -0
- package/dist/_dts/block-form/src/widgets/RepeaterField/utils/index.d.ts +3 -1
- package/dist/_dts/block-form/src/widgets/RepeaterField/utils/repeaterDndDomain.d.ts +1 -1
- package/dist/_dts/block-form/src/widgets/RepeaterField/utils/repeaterLabelSource.d.ts +15 -0
- package/dist/_dts/block-form/src/widgets/RepeaterField/utils/repeaterRowActionsDomain.d.ts +50 -0
- package/dist/_dts/blocks/src/system/blocks/appointment-booking.d.ts +591 -0
- package/dist/_dts/blocks/src/system/blocks/blog-listing.d.ts +591 -0
- package/dist/_dts/blocks/src/system/blocks/cart.d.ts +591 -0
- package/dist/_dts/blocks/src/system/blocks/checkout.d.ts +591 -0
- package/dist/_dts/blocks/src/system/blocks/collection.d.ts +591 -0
- package/dist/_dts/blocks/src/system/blocks/faq.d.ts +591 -0
- package/dist/_dts/blocks/src/system/blocks/gifting.d.ts +591 -0
- package/dist/_dts/blocks/src/system/blocks/location-map.d.ts +2 -0
- package/dist/_dts/blocks/src/system/blocks/media-text.d.ts +47 -0
- package/dist/_dts/blocks/src/system/blocks/product-detail.d.ts +591 -0
- package/dist/_dts/blocks/src/system/blocks/product-list.d.ts +591 -0
- package/dist/_dts/blocks/src/system/blocks/shop.d.ts +591 -0
- package/dist/_dts/blocks/src/system/blocks/team-members.d.ts +3 -0
- package/dist/_dts/blocks/src/system/manifest/schema.d.ts +164 -0
- package/dist/_dts/blocks/src/system/runtime/hooks/useHeadlessBookingFlow.state.d.ts +1 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/booking-form.headless.state.d.ts +1 -1
- package/dist/_dts/content-editor/src/index.d.ts +1 -1
- package/dist/_dts/content-editor/src/ui/editorSnapshot.d.ts +2 -2
- package/dist/_dts/content-model/src/content-types/schema.d.ts +14 -0
- package/dist/_dts/content-model/src/templates/bindingTypeCompatibility.d.ts +3 -1
- package/dist/_dts/content-model/src/templates/bindingValidation.d.ts +10 -4
- package/dist/_dts/content-model/src/templates/fieldPaths.d.ts +20 -0
- package/dist/_dts/content-model/src/templates/manifestAdapter.d.ts +5 -2
- package/dist/_dts/core/src/branded.d.ts +108 -85
- package/dist/_dts/core/src/csv-types.d.ts +2 -2
- package/dist/_dts/core/src/editor-state.d.ts +7 -7
- package/dist/_dts/core/src/participants.d.ts +2 -2
- package/dist/_dts/db/src/generated/supabase/database.types.d.ts +11 -0
- package/dist/_dts/editor-blocks/src/blockPayload.d.ts +1 -1
- package/dist/_dts/media-editor/src/MediaEditor.d.ts +3 -1
- package/dist/_dts/media-editor/src/MediaPreview.d.ts +3 -1
- package/dist/_dts/media-editor/src/fieldUi.d.ts +5 -0
- package/dist/_dts/media-editor/src/index.d.ts +1 -1
- package/dist/_dts/sdk/src/cli/commands/push/consts.d.ts +1 -1
- package/dist/_dts/sdk/src/cli/commands/push/metadata.d.ts +2 -0
- package/dist/_dts/sdk/src/cli/commands/push/stale.d.ts +3 -3
- package/dist/_dts/sdk/src/cli/commands/push-execute.d.ts +7 -0
- package/dist/_dts/sdk/src/cli/commands/push.d.ts +2 -0
- package/dist/_dts/sdk/src/cli/content/reader.d.ts +13 -0
- package/dist/_dts/sdk/src/cli/content/writer.d.ts +2 -1
- package/dist/_dts/sdk/src/cli/helpers.d.ts +2 -0
- package/dist/_dts/sdk/src/cli/site-commands/commandKeys.d.ts +6 -6
- package/dist/_dts/sdk/src/cli/site-commands/commandRuntime.d.ts +5 -0
- package/dist/_dts/sdk/src/cli/site-commands/commandSurfaceDispatch.d.ts +4 -0
- package/dist/_dts/sdk/src/cli/site-commands/pageCommands.d.ts +5 -2
- package/dist/_dts/sdk/src/cli/site-commands/pushExecution.d.ts +10 -1
- package/dist/_dts/sdk/src/cli/site-commands/pushExecutionTypes.d.ts +1 -1
- package/dist/_dts/sdk/src/client/management/types.d.ts +6 -0
- package/dist/_dts/sdk/src/client/types.d.ts +2 -2
- package/dist/_dts/sdk/src/config/content-types.d.ts +7 -0
- package/dist/_dts/sdk/src/config/field-definitions.d.ts +2 -0
- package/dist/_dts/sdk/src/version.d.ts +1 -1
- package/dist/_dts/site-commands/src/commands.d.ts +3 -0
- package/dist/{altcha-B5XGSXP5.mjs → altcha-EKUEQ4RP.mjs} +1 -1
- package/dist/{chunk-NIDXI46P.mjs → chunk-4QEGTLK6.mjs} +1 -1
- package/dist/{chunk-TXDES5P2.mjs → chunk-6HYXHRAI.mjs} +5 -5
- package/dist/{chunk-SVMMM2NA.mjs → chunk-CR5HKAGU.mjs} +24 -5
- package/dist/{chunk-OECWLDHN.mjs → chunk-MCRQMPET.mjs} +1030 -588
- package/dist/{chunk-SXOLGNMX.mjs → chunk-OKMBEAXY.mjs} +1 -1
- package/dist/{chunk-XGB3TDIC.mjs → chunk-R7POPVJR.mjs} +2 -8
- package/dist/{chunk-F7RTCZYN.mjs → chunk-RGTOD4AJ.mjs} +20 -14
- package/dist/cli/index.mjs +681 -225
- package/dist/cli/init-docs/content/cli-reference.md +3 -2
- package/dist/cli/init-docs/content/content-management.md +2 -2
- package/dist/cli/init-docs/content/workflow-preview-mode.md +68 -2
- package/dist/client/{accordion-EVDEOUPR.mjs → accordion-PLYNJIIM.mjs} +2 -2
- package/dist/client/analytics.mjs +1 -1
- package/dist/client/{bookingForm-DIHBLC64.mjs → bookingForm-BXAP6AO7.mjs} +55 -48
- package/dist/client/bookings.mjs +62 -55
- package/dist/client/{carousel-FEBQHIWI.mjs → carousel-TRBXDHGF.mjs} +3 -3
- package/dist/client/{cart-7CKSXAE4.mjs → cart-Z7H3HJRS.mjs} +7 -7
- package/dist/client/{checkout-WKYCANLV.mjs → checkout-WAFCUBIX.mjs} +7 -7
- package/dist/client/{chunk-OFMSCGNY.mjs → chunk-75OUS5MT.mjs} +2 -2
- package/dist/client/{chunk-IVNCUVAV.mjs → chunk-AUJ5DBZJ.mjs} +18 -18
- package/dist/client/{chunk-36WJCERQ.mjs → chunk-CE7IBGVW.mjs} +3 -1
- package/dist/client/{chunk-RZDWX7QW.mjs → chunk-CWGTG37I.mjs} +1 -1
- package/dist/client/{chunk-YDSEG6GZ.mjs → chunk-DNRGY432.mjs} +2 -2
- package/dist/client/{chunk-RV6FX7UH.mjs → chunk-FUXW6VW2.mjs} +9 -9
- package/dist/client/{chunk-65F47D7Y.mjs → chunk-JGXPTEI2.mjs} +43 -36
- package/dist/client/{chunk-GUK2FPXQ.mjs → chunk-JRDUHZCT.mjs} +37 -15
- package/dist/client/{chunk-VPPMNXCF.mjs → chunk-UVQEJJTN.mjs} +2 -2
- package/dist/client/{chunk-F7LHOKEH.mjs → chunk-XSV6KW4D.mjs} +1 -1
- package/dist/client/{chunk-PD6NBCEY.mjs → chunk-ZFHRN6W2.mjs} +1 -1
- package/dist/client/{chunk-2SAVKN2M.mjs → chunk-ZI3LLBPZ.mjs} +2 -2
- package/dist/client/client.mjs +249 -160
- package/dist/client/{courseRegistration-5QF2PHKM.mjs → courseRegistration-AHFQHWIJ.mjs} +10 -10
- package/dist/client/{eventCalendar-4ZOSETDU.mjs → eventCalendar-LDXTV5R7.mjs} +9 -9
- package/dist/client/{eventCombined-WQGU7JUX.mjs → eventCombined-A4JGTNJO.mjs} +9 -9
- package/dist/client/{eventDetails-AYWVUJ5Y.mjs → eventDetails-4YXTZ7EG.mjs} +9 -9
- package/dist/client/{eventListing-NT7C6UT5.mjs → eventListing-P72TPFFM.mjs} +9 -9
- package/dist/client/{eventRegistration-OH24F4ZJ.mjs → eventRegistration-LSYJHGMT.mjs} +9 -9
- package/dist/client/{form-7L42SRBB.mjs → form-AOPYOKOW.mjs} +6 -3
- package/dist/client/{headerSection-OZRZNZ52.mjs → headerSection-5TFYDFVQ.mjs} +3 -3
- package/dist/client/hooks.mjs +78 -48
- package/dist/client/{locationMap-ZBXRPQ7C.mjs → locationMap-QSZ3ZVAZ.mjs} +3 -3
- package/dist/client/{newsletterForm-SNAGFF2I.mjs → newsletterForm-KTRHZY52.mjs} +2 -2
- package/dist/client/{productDetail-I46BOFGV.mjs → productDetail-N4E775RG.mjs} +7 -7
- package/dist/client/{productList-BOYHTYI6.mjs → productList-UGUQ2S45.mjs} +7 -7
- package/dist/client/rendering/client.mjs +173 -131
- package/dist/client/rendering/islands.mjs +19 -19
- package/dist/client/rendering.mjs +230 -150
- package/dist/client/{shop-XTXPZTKR.mjs → shop-VHSZEEQ2.mjs} +7 -7
- package/dist/preview-next/before-render.mjs +10 -1
- package/dist/preview-next/client/runtime.mjs +6 -6
- package/dist/preview-next/middleware.mjs +10 -1
- package/dist/preview-next/tailwind-sources.css +1 -0
- package/dist/sdk-runtime-WHPJEF5G.mjs +8 -0
- package/dist/server/components.mjs +101 -54
- package/dist/server/config-template-validation.mjs +221 -15
- package/dist/server/config-validation.mjs +76 -42
- package/dist/server/config.mjs +76 -42
- package/dist/server/data.mjs +77 -47
- package/dist/server/index.mjs +31 -10
- package/dist/server/next.mjs +133 -71
- package/dist/server/page-converter.mjs +60 -40
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/rendering/server.mjs +107 -60
- package/dist/server/rendering.mjs +111 -61
- package/dist/server/routing.mjs +93 -63
- package/dist/server/server.mjs +102 -57
- package/package.json +1 -1
- package/dist/SdkPreviewModeRuntime-LAGYMPNF.mjs +0 -8
- package/dist/sdk-runtime-ZJLKC6DR.mjs +0 -8
package/dist/server/prebuild.mjs
CHANGED
|
@@ -113,9 +113,6 @@ var linkSchema = z.union([
|
|
|
113
113
|
// ../blocks/src/system/manifest/schema.ts
|
|
114
114
|
import { z as z3 } from "zod";
|
|
115
115
|
|
|
116
|
-
// ../core/src/branded.ts
|
|
117
|
-
var asMediaAssetId = (id) => id;
|
|
118
|
-
|
|
119
116
|
// ../core/src/result.ts
|
|
120
117
|
function ok(value) {
|
|
121
118
|
return { ok: true, value };
|
|
@@ -124,6 +121,9 @@ function err(error) {
|
|
|
124
121
|
return { ok: false, error };
|
|
125
122
|
}
|
|
126
123
|
|
|
124
|
+
// ../core/src/branded.ts
|
|
125
|
+
var unsafeAsMediaAssetId = (id) => id;
|
|
126
|
+
|
|
127
127
|
// ../core/src/booking-date-time.ts
|
|
128
128
|
var DEFAULT_LOCALE = "en-US";
|
|
129
129
|
var FALLBACK_TIMEZONE = "UTC";
|
|
@@ -623,14 +623,14 @@ function rotateNormalizedPoint(point, rotation) {
|
|
|
623
623
|
const x = point.x;
|
|
624
624
|
const y = point.y;
|
|
625
625
|
switch (rotation) {
|
|
626
|
+
case 0:
|
|
627
|
+
return { x, y };
|
|
626
628
|
case 90:
|
|
627
629
|
return { x: 1 - y, y: x };
|
|
628
630
|
case 180:
|
|
629
631
|
return { x: 1 - x, y: 1 - y };
|
|
630
632
|
case 270:
|
|
631
633
|
return { x: y, y: 1 - x };
|
|
632
|
-
default:
|
|
633
|
-
return { x, y };
|
|
634
634
|
}
|
|
635
635
|
}
|
|
636
636
|
|
|
@@ -823,6 +823,8 @@ var uiSchema = z3.object({
|
|
|
823
823
|
mediaPickerAutoOpen: z3.boolean().optional(),
|
|
824
824
|
showMediaPreview: z3.boolean().optional(),
|
|
825
825
|
showMediaOverlayActions: z3.boolean().optional(),
|
|
826
|
+
mediaPreviewMaxWidth: z3.enum(["xs", "sm", "md", "none"]).optional(),
|
|
827
|
+
preventMediaPreviewUpscale: z3.boolean().optional(),
|
|
826
828
|
mediaDelivery: mediaDeliverySchema.optional(),
|
|
827
829
|
mediaDeliveryByVariant: z3.record(z3.string(), mediaDeliverySchema).optional(),
|
|
828
830
|
// Optional input hints for validators/widgets
|
|
@@ -1072,6 +1074,9 @@ var repeaterFieldSchema = baseFieldSchema.extend({
|
|
|
1072
1074
|
type: z3.literal("repeater"),
|
|
1073
1075
|
itemLabel: z3.string().default("Item"),
|
|
1074
1076
|
itemLabelSource: z3.string().optional(),
|
|
1077
|
+
showSummary: z3.boolean().optional(),
|
|
1078
|
+
summaryFields: z3.string().array().optional(),
|
|
1079
|
+
summaryMaxChars: z3.number().int().positive().optional(),
|
|
1075
1080
|
minItems: z3.number().int().min(0).default(0),
|
|
1076
1081
|
maxItems: z3.number().int().positive().optional(),
|
|
1077
1082
|
// Monomorphic mode
|
|
@@ -1725,7 +1730,7 @@ function normalizeStoredObjectChildren(children, value, ctx) {
|
|
|
1725
1730
|
return normalized;
|
|
1726
1731
|
}
|
|
1727
1732
|
function normalizeStoredRepeaterItems(plan, value, ctx) {
|
|
1728
|
-
if (!
|
|
1733
|
+
if (!isUnknownArray(value)) {
|
|
1729
1734
|
return value;
|
|
1730
1735
|
}
|
|
1731
1736
|
return value.map((item) => {
|
|
@@ -1772,7 +1777,7 @@ function normalizeObjectChildren(children, value, ctx) {
|
|
|
1772
1777
|
return normalized;
|
|
1773
1778
|
}
|
|
1774
1779
|
function normalizeRepeaterItems(plan, value, ctx) {
|
|
1775
|
-
if (!
|
|
1780
|
+
if (!isUnknownArray(value)) return value;
|
|
1776
1781
|
return value.map((item) => {
|
|
1777
1782
|
if (!item || typeof item !== "object" || Array.isArray(item)) return item;
|
|
1778
1783
|
const itemRecord = item;
|
|
@@ -2159,6 +2164,9 @@ function isEmptyValue(value) {
|
|
|
2159
2164
|
function isPlainObject(value) {
|
|
2160
2165
|
return Boolean(value && typeof value === "object" && !Array.isArray(value));
|
|
2161
2166
|
}
|
|
2167
|
+
function isUnknownArray(value) {
|
|
2168
|
+
return Array.isArray(value);
|
|
2169
|
+
}
|
|
2162
2170
|
function isValidRichTextDoc(value) {
|
|
2163
2171
|
const doc = richTextDoc(value);
|
|
2164
2172
|
return Boolean(isPlainObject(doc) && doc.type === "doc");
|
|
@@ -5884,13 +5892,13 @@ function generateShadowValue(elevation, softness, position = "bottom") {
|
|
|
5884
5892
|
const xOffset = position === "bottom-right" ? config.offset : 0;
|
|
5885
5893
|
const yOffset = config.offset;
|
|
5886
5894
|
switch (softness) {
|
|
5895
|
+
case null:
|
|
5896
|
+
case "soft":
|
|
5897
|
+
return `${xOffset}px ${yOffset}px ${config.blur}px ${config.spread}px rgb(0 0 0 / 0.3)`;
|
|
5887
5898
|
case "hard":
|
|
5888
5899
|
return `${xOffset}px ${yOffset}px 0 0 rgb(0 0 0 / 1)`;
|
|
5889
5900
|
case "crisp":
|
|
5890
5901
|
return `${xOffset}px ${yOffset}px ${config.offset}px ${config.spread}px rgb(0 0 0 / 0.4)`;
|
|
5891
|
-
case "soft":
|
|
5892
|
-
default:
|
|
5893
|
-
return `${xOffset}px ${yOffset}px ${config.blur}px ${config.spread}px rgb(0 0 0 / 0.3)`;
|
|
5894
5902
|
}
|
|
5895
5903
|
}
|
|
5896
5904
|
var BORDER_WIDTH_MAP = {
|
|
@@ -13371,47 +13379,48 @@ function validateFieldDefinitions(fields3, fragmentId) {
|
|
|
13371
13379
|
function prefixFieldId(field, scope) {
|
|
13372
13380
|
const cloned = cloneFieldDefinition2(field);
|
|
13373
13381
|
cloned.id = `${scope}.${field.id}`;
|
|
13374
|
-
|
|
13382
|
+
const defaultValue = cloned.defaultValue;
|
|
13383
|
+
cloned.defaultValue = cloneUnknown(defaultValue);
|
|
13375
13384
|
cloned.visibleRoles = cloned.visibleRoles ? [...cloned.visibleRoles] : void 0;
|
|
13376
13385
|
cloned.ui = cloneUnknown(cloned.ui);
|
|
13377
13386
|
return cloned;
|
|
13378
13387
|
}
|
|
13379
13388
|
function cloneFieldDefinition2(field) {
|
|
13380
|
-
|
|
13381
|
-
|
|
13382
|
-
|
|
13383
|
-
|
|
13384
|
-
|
|
13385
|
-
|
|
13386
|
-
|
|
13387
|
-
|
|
13388
|
-
|
|
13389
|
-
|
|
13390
|
-
|
|
13391
|
-
|
|
13392
|
-
|
|
13393
|
-
|
|
13394
|
-
|
|
13395
|
-
|
|
13396
|
-
|
|
13397
|
-
return {
|
|
13398
|
-
...field,
|
|
13399
|
-
schema: {
|
|
13400
|
-
fields: field.schema.fields.map(cloneFieldDefinition2)
|
|
13401
|
-
}
|
|
13402
|
-
};
|
|
13403
|
-
}
|
|
13404
|
-
return { ...field };
|
|
13405
|
-
case "group":
|
|
13389
|
+
if (field.type === "repeater") {
|
|
13390
|
+
if (field.polymorphic && field.itemTypes) {
|
|
13391
|
+
return {
|
|
13392
|
+
...field,
|
|
13393
|
+
polymorphic: true,
|
|
13394
|
+
itemTypes: Object.fromEntries(
|
|
13395
|
+
Object.entries(field.itemTypes).map(([key, itemType]) => [
|
|
13396
|
+
key,
|
|
13397
|
+
{
|
|
13398
|
+
...itemType,
|
|
13399
|
+
fields: itemType.fields.map(cloneFieldDefinition2)
|
|
13400
|
+
}
|
|
13401
|
+
])
|
|
13402
|
+
)
|
|
13403
|
+
};
|
|
13404
|
+
}
|
|
13405
|
+
if (field.schema) {
|
|
13406
13406
|
return {
|
|
13407
13407
|
...field,
|
|
13408
13408
|
schema: {
|
|
13409
13409
|
fields: field.schema.fields.map(cloneFieldDefinition2)
|
|
13410
13410
|
}
|
|
13411
13411
|
};
|
|
13412
|
-
|
|
13413
|
-
|
|
13412
|
+
}
|
|
13413
|
+
return { ...field };
|
|
13414
|
+
}
|
|
13415
|
+
if (field.type === "group") {
|
|
13416
|
+
return {
|
|
13417
|
+
...field,
|
|
13418
|
+
schema: {
|
|
13419
|
+
fields: field.schema.fields.map(cloneFieldDefinition2)
|
|
13420
|
+
}
|
|
13421
|
+
};
|
|
13414
13422
|
}
|
|
13423
|
+
return { ...field };
|
|
13415
13424
|
}
|
|
13416
13425
|
function cloneUnknown(value) {
|
|
13417
13426
|
if (value == null || typeof value !== "object") {
|
|
@@ -15846,7 +15855,8 @@ function createBlockManifestWithContentShape(config, _contentShape) {
|
|
|
15846
15855
|
return createBlockManifest(config);
|
|
15847
15856
|
}
|
|
15848
15857
|
function normalizeBlockLayout(layout) {
|
|
15849
|
-
|
|
15858
|
+
const rawLayout = layout;
|
|
15859
|
+
return Array.isArray(rawLayout) ? rawLayout : rawLayout;
|
|
15850
15860
|
}
|
|
15851
15861
|
function deriveComponentName(id) {
|
|
15852
15862
|
const base = id.replace(/^block\./, "");
|
|
@@ -17414,16 +17424,20 @@ var marqueeLoopTransform = {
|
|
|
17414
17424
|
summary: "Repeat an array to a minimum length, then duplicate it for seamless marquee looping",
|
|
17415
17425
|
schema: marqueeLoopOptionsSchema,
|
|
17416
17426
|
run: (value, options) => {
|
|
17417
|
-
|
|
17427
|
+
const items = toUnknownArray(value);
|
|
17428
|
+
if (items.length === 0) return [];
|
|
17418
17429
|
const minItems = options?.minItems ?? 10;
|
|
17419
17430
|
const base = [];
|
|
17420
17431
|
while (base.length < minItems) {
|
|
17421
|
-
base.push(...
|
|
17432
|
+
base.push(...items);
|
|
17422
17433
|
if (base.length > 1e3) break;
|
|
17423
17434
|
}
|
|
17424
17435
|
return [...base, ...base];
|
|
17425
17436
|
}
|
|
17426
17437
|
};
|
|
17438
|
+
function toUnknownArray(value) {
|
|
17439
|
+
return Array.isArray(value) ? value : [];
|
|
17440
|
+
}
|
|
17427
17441
|
var formattingTransforms = [
|
|
17428
17442
|
uppercaseTransform,
|
|
17429
17443
|
fallbackTransform,
|
|
@@ -21140,8 +21154,8 @@ var eventSurfaceScopeValues = [
|
|
|
21140
21154
|
"custom"
|
|
21141
21155
|
];
|
|
21142
21156
|
var eventScheduleScopeValues = ["any", "recurring", "oneOff"];
|
|
21143
|
-
var
|
|
21144
|
-
var
|
|
21157
|
+
var unsafeAsEventCategoryId = (value) => value;
|
|
21158
|
+
var unsafeAsVenueId = (value) => value;
|
|
21145
21159
|
function normalizeEventBlockKind(value) {
|
|
21146
21160
|
return value === "courses" || value === "events" ? value : "all";
|
|
21147
21161
|
}
|
|
@@ -21167,10 +21181,10 @@ function normalizeEventCategoryIds(value) {
|
|
|
21167
21181
|
if (Array.isArray(value)) {
|
|
21168
21182
|
return normalizeIdList(
|
|
21169
21183
|
value.filter((entry) => typeof entry === "string")
|
|
21170
|
-
).map(
|
|
21184
|
+
).map(unsafeAsEventCategoryId);
|
|
21171
21185
|
}
|
|
21172
21186
|
if (typeof value === "string") {
|
|
21173
|
-
return normalizeIdList(value.split(",")).map(
|
|
21187
|
+
return normalizeIdList(value.split(",")).map(unsafeAsEventCategoryId);
|
|
21174
21188
|
}
|
|
21175
21189
|
return [];
|
|
21176
21190
|
}
|
|
@@ -21183,7 +21197,7 @@ function normalizeEventVenueId(value) {
|
|
|
21183
21197
|
return null;
|
|
21184
21198
|
}
|
|
21185
21199
|
const trimmed = value.trim();
|
|
21186
|
-
return trimmed ?
|
|
21200
|
+
return trimmed ? unsafeAsVenueId(trimmed) : null;
|
|
21187
21201
|
}
|
|
21188
21202
|
function normalizeEventStaffMemberId(value) {
|
|
21189
21203
|
if (typeof value !== "string") {
|
|
@@ -23754,7 +23768,7 @@ function getProxyImageUrl(value, options, transformAspectRatio, resolved) {
|
|
|
23754
23768
|
if (!shouldUseExplicitRectProxy(value, options, resolvedTransform, sourceWidth, sourceHeight)) return void 0;
|
|
23755
23769
|
const params = buildProxyTransformParams(options, resolvedTransform);
|
|
23756
23770
|
const proxyBasePath = getImageProxyBasePath();
|
|
23757
|
-
const proxyUrl = getImageUrl({ id:
|
|
23771
|
+
const proxyUrl = getImageUrl({ id: unsafeAsMediaAssetId(value.assetId) }, params, proxyBasePath);
|
|
23758
23772
|
debugMediaNodeLog("resolve:proxy-img", { assetId: value.assetId, params, proxyBasePath, proxyUrl });
|
|
23759
23773
|
return proxyUrl;
|
|
23760
23774
|
}
|
|
@@ -32781,6 +32795,8 @@ var header_section_server_default = markEditableSurfaceForwarding(HeaderSectionN
|
|
|
32781
32795
|
import { jsx as jsx23, jsxs as jsxs11 } from "react/jsx-runtime";
|
|
32782
32796
|
function resolveColorStyle(color) {
|
|
32783
32797
|
switch (color) {
|
|
32798
|
+
case void 0:
|
|
32799
|
+
return void 0;
|
|
32784
32800
|
case "inherit":
|
|
32785
32801
|
return { color: "inherit" };
|
|
32786
32802
|
case "foreground":
|
|
@@ -36258,14 +36274,23 @@ function injectMediaSlotPath(props2, node, parsedBinding, context) {
|
|
|
36258
36274
|
}
|
|
36259
36275
|
function resolveChildren(nodes, context) {
|
|
36260
36276
|
if (!nodes?.length) return [];
|
|
36261
|
-
|
|
36277
|
+
const children = [];
|
|
36278
|
+
nodes.forEach((child, index) => {
|
|
36262
36279
|
const childContext = { ...context, scopes: [...context.scopes] };
|
|
36263
36280
|
const resolved = resolveNode2(child, childContext, index);
|
|
36264
36281
|
if (Array.isArray(resolved)) {
|
|
36265
|
-
|
|
36282
|
+
for (const item of resolved) {
|
|
36283
|
+
const childNode = item;
|
|
36284
|
+
if (isReactNode(childNode)) children.push(childNode);
|
|
36285
|
+
}
|
|
36286
|
+
return;
|
|
36266
36287
|
}
|
|
36267
|
-
|
|
36288
|
+
if (isReactNode(resolved)) children.push(resolved);
|
|
36268
36289
|
});
|
|
36290
|
+
return children;
|
|
36291
|
+
}
|
|
36292
|
+
function isReactNode(value) {
|
|
36293
|
+
return value !== null && value !== void 0;
|
|
36269
36294
|
}
|
|
36270
36295
|
function resolveNode2(node, context, indexFallback) {
|
|
36271
36296
|
if (!shouldRenderNode(node, context)) {
|
|
@@ -36478,8 +36503,11 @@ var BLOCK_PREFIX = "block.";
|
|
|
36478
36503
|
function isPlainObject4(value) {
|
|
36479
36504
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
36480
36505
|
}
|
|
36506
|
+
function isUnknownArray2(value) {
|
|
36507
|
+
return Array.isArray(value);
|
|
36508
|
+
}
|
|
36481
36509
|
function cloneValue(value) {
|
|
36482
|
-
if (
|
|
36510
|
+
if (isUnknownArray2(value)) {
|
|
36483
36511
|
return value.map((item) => cloneValue(item));
|
|
36484
36512
|
}
|
|
36485
36513
|
if (isPlainObject4(value)) {
|
|
@@ -52737,11 +52765,11 @@ function normalizeContent(block) {
|
|
|
52737
52765
|
}
|
|
52738
52766
|
function normalizeParams(input) {
|
|
52739
52767
|
if (!input || typeof input !== "object") return {};
|
|
52740
|
-
const
|
|
52741
|
-
|
|
52742
|
-
coerceToString(value)
|
|
52743
|
-
|
|
52744
|
-
return
|
|
52768
|
+
const output = {};
|
|
52769
|
+
for (const [key, value] of Object.entries(input)) {
|
|
52770
|
+
output[key] = coerceToString(value);
|
|
52771
|
+
}
|
|
52772
|
+
return output;
|
|
52745
52773
|
}
|
|
52746
52774
|
function isNonArrayObject(value) {
|
|
52747
52775
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
@@ -54674,7 +54702,16 @@ var ENDPOINT_DEFINITIONS = {
|
|
|
54674
54702
|
revalidate: 60,
|
|
54675
54703
|
tags: ["site-{siteId}", "content-{siteId}-{type}"],
|
|
54676
54704
|
auth: "user",
|
|
54677
|
-
responseKind: "json"
|
|
54705
|
+
responseKind: "json",
|
|
54706
|
+
errors: ["validation:invalid_input", "resource:not_found", "resource:conflict", "server:internal_error"]
|
|
54707
|
+
},
|
|
54708
|
+
reorderContentEntries: {
|
|
54709
|
+
path: "/sites/{siteId}/content/{type}/order",
|
|
54710
|
+
method: "POST",
|
|
54711
|
+
tags: ["site-{siteId}", "content-{siteId}-{type}"],
|
|
54712
|
+
auth: "user",
|
|
54713
|
+
responseKind: "json",
|
|
54714
|
+
errors: ["validation:invalid_input", "resource:not_found", "resource:conflict", "server:internal_error"]
|
|
54678
54715
|
},
|
|
54679
54716
|
getContentTemplate: {
|
|
54680
54717
|
path: "/sites/{siteId}/content/types/{type}/template",
|
|
@@ -59296,10 +59333,16 @@ var dashboardConfigSchema = z68.object({
|
|
|
59296
59333
|
var fieldDefinitionInputSchema = unsafeRetypeZodSchema(fieldSchema);
|
|
59297
59334
|
var nodeDefinitionSchema = unsafeRetypeZodSchema(NodeSchema);
|
|
59298
59335
|
var sdkLoaderEndpointSchema = z68.enum(SUPPORTED_LOADER_ENDPOINTS);
|
|
59336
|
+
var loaderFallbackScalarSchema = z68.union([
|
|
59337
|
+
z68.string(),
|
|
59338
|
+
z68.number(),
|
|
59339
|
+
z68.boolean(),
|
|
59340
|
+
z68.null()
|
|
59341
|
+
]);
|
|
59299
59342
|
var loaderParamBindingSchema = z68.object({
|
|
59300
59343
|
$bind: z68.object({
|
|
59301
59344
|
from: z68.string().min(1, "Binding path is required"),
|
|
59302
|
-
fallback:
|
|
59345
|
+
fallback: loaderFallbackScalarSchema.optional()
|
|
59303
59346
|
})
|
|
59304
59347
|
});
|
|
59305
59348
|
var loaderParamValueSchema = z68.union([
|
|
@@ -59445,9 +59488,13 @@ var sdkBlockFieldOptionsMapSchema = z68.record(
|
|
|
59445
59488
|
var sdkContentTypeTemplateConfigSchema = z68.object({
|
|
59446
59489
|
blocks: z68.array(z68.unknown())
|
|
59447
59490
|
}).passthrough();
|
|
59491
|
+
var sdkContentTypeOrderingConfigSchema = z68.object({
|
|
59492
|
+
mode: z68.enum(["default", "manual"]).optional()
|
|
59493
|
+
}).optional();
|
|
59448
59494
|
var sdkContentTypeConfigSchema = z68.object({
|
|
59449
59495
|
key: z68.string().min(1),
|
|
59450
59496
|
fields: z68.array(z68.unknown()),
|
|
59497
|
+
ordering: sdkContentTypeOrderingConfigSchema,
|
|
59451
59498
|
template: sdkContentTypeTemplateConfigSchema.nullable().optional()
|
|
59452
59499
|
}).passthrough();
|
|
59453
59500
|
var sdkContentConfigSchema = z68.object({
|
|
@@ -60447,7 +60494,7 @@ async function prefetchBlockData2(page, context, client, options) {
|
|
|
60447
60494
|
throw new Error("listPublishedEntries requires siteId and type params");
|
|
60448
60495
|
}
|
|
60449
60496
|
const parsedLimit = typeof limit === "string" ? Number.parseInt(limit, 10) : typeof limit === "number" ? limit : void 0;
|
|
60450
|
-
const order = orderBy === "
|
|
60497
|
+
const order = orderBy === "order" ? "manual" : orderBy === "newest" || orderBy === "oldest" || orderBy === "title" ? orderBy : void 0;
|
|
60451
60498
|
const parsedEntryIds = mode === "manual" ? parseManualEntryIds(entryIds) : void 0;
|
|
60452
60499
|
if (mode === "manual" && (!parsedEntryIds || parsedEntryIds.length === 0)) {
|
|
60453
60500
|
return { entries: [] };
|