riverbankcms 0.21.0 → 0.22.1
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 +2771 -1288
- package/dist/cli/init-docs/content/getting-started.md +17 -1
- package/dist/{entryCommands-DSQZqznu.mjs → entryCommands-Bu-z9kxb.mjs} +1810 -1615
- package/dist/{eventUpsertInputSchema-zCTx0fdF.mjs → eventUpsertInputSchema-xHmuEKwM.mjs} +8 -2
- package/dist/load-config-BRd0EUsF.mjs +4 -0
- package/dist/{load-config-B68gtN45.mjs → load-config-pAPKpeE0.mjs} +3 -3
- package/dist/{plan-CkMANumv.mjs → plan-DUdJbgTV.mjs} +8 -3
- package/dist/scaffold/index.mjs +2 -2
- package/dist/{sdk-event-upsert-CrOuJrxo.mjs → sdk-event-upsert-B3gflo1K.mjs} +803 -166
- package/dist/{src-BENi4Q5k.mjs → src-RfhyMOpX.mjs} +266 -77
- package/dist/testing.mjs +4 -4
- package/package.json +2 -2
- package/dist/load-config-ghkXBKim.mjs +0 -4
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import {
|
|
2
|
+
import { B as parseWeeklyOpeningHours, Bn as unsafeAsUserId, Bt as fromArray, C as stableJsonStringify, Cn as unsafeAsFileChecksumSha256, En as unsafeAsOriginalFilename, Fn as unsafeAsSiteScopedStoragePath, H as isPresent, Hn as ok, Ht as mapReadonlyNonEmptyArray, L as isCanonicalRichTextDoc, Ln as unsafeAsStorageBucketName, M as parseFooterCompositionV1, Mn as unsafeAsSafeDownloadFilename, N as footerNavigationLayouts, Nn as unsafeAsSiteFontId, On as unsafeAsPositiveByteCount, Pn as unsafeAsSiteId, Qt as assertNever, Rn as unsafeAsStoragePath, Vn as err, Vt as mapNonEmptyArray, an as parseMediaAssetId, c as resolveSiteVerticalBookingConfig, d as ORDINARY_EVENT_PRESET_VALUES, gn as unsafeAsDeclaredMimeType, gt as validateBookingPaymentOptionKinds, ht as parseBookingTimeZone, jn as unsafeAsProductId, kn as unsafeAsPositiveSeconds, ln as parseSiteId, lt as parseUtcIsoDateTimeString, mn as unsafeAsBookingSessionId, pn as unsafeAsBookingRequirementId, r as NAVIGATION_LOCATIONS, st as localScheduleTimePattern, u as EVENT_PRESET_VALUES, vn as unsafeAsDetectedMimeType, wn as unsafeAsMediaAssetId, yn as unsafeAsEntitlementId, z as parsePublicContactDetails, zn as unsafeAsUploadSessionId } from "./src-RfhyMOpX.mjs";
|
|
3
3
|
import "node:module";
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
|
|
@@ -4903,7 +4903,8 @@ const cardListItemParts = [
|
|
|
4903
4903
|
"schedule",
|
|
4904
4904
|
"dates",
|
|
4905
4905
|
"availability",
|
|
4906
|
-
"action"
|
|
4906
|
+
"action",
|
|
4907
|
+
"price"
|
|
4907
4908
|
];
|
|
4908
4909
|
/** Block supply is capability, never a second Look catalogue. */
|
|
4909
4910
|
const cardListBlockParts = {
|
|
@@ -4913,13 +4914,39 @@ const cardListBlockParts = {
|
|
|
4913
4914
|
"text",
|
|
4914
4915
|
"action"
|
|
4915
4916
|
],
|
|
4916
|
-
"block.offerings-preview":
|
|
4917
|
+
"block.offerings-preview": [
|
|
4918
|
+
"media",
|
|
4919
|
+
"title",
|
|
4920
|
+
"text",
|
|
4921
|
+
"facts",
|
|
4922
|
+
"chips",
|
|
4923
|
+
"numeral",
|
|
4924
|
+
"schedule",
|
|
4925
|
+
"dates",
|
|
4926
|
+
"availability",
|
|
4927
|
+
"action"
|
|
4928
|
+
],
|
|
4917
4929
|
"block.appointment-services": [
|
|
4918
4930
|
"media",
|
|
4919
4931
|
"title",
|
|
4920
4932
|
"text",
|
|
4921
4933
|
"facts",
|
|
4922
4934
|
"action"
|
|
4935
|
+
],
|
|
4936
|
+
"block.team-members": [
|
|
4937
|
+
"media",
|
|
4938
|
+
"title",
|
|
4939
|
+
"text",
|
|
4940
|
+
"facts",
|
|
4941
|
+
"chips",
|
|
4942
|
+
"action"
|
|
4943
|
+
],
|
|
4944
|
+
"block.shop": [
|
|
4945
|
+
"title",
|
|
4946
|
+
"text",
|
|
4947
|
+
"facts",
|
|
4948
|
+
"price",
|
|
4949
|
+
"action"
|
|
4923
4950
|
]
|
|
4924
4951
|
};
|
|
4925
4952
|
const cardListFamilyBlocks = Object.keys(cardListBlockParts);
|
|
@@ -5010,7 +5037,9 @@ const arrangementLookTargets = {
|
|
|
5010
5037
|
"image-gallery": "image-gallery",
|
|
5011
5038
|
"newsletter-signup": "newsletter",
|
|
5012
5039
|
form: "contact-form",
|
|
5013
|
-
"body-text": "body-text"
|
|
5040
|
+
"body-text": "body-text",
|
|
5041
|
+
faq: "faq",
|
|
5042
|
+
"cta-full": "cta"
|
|
5014
5043
|
};
|
|
5015
5044
|
function defineArrangementLook(id$2, block, name, arrangement, knobs, input = {}) {
|
|
5016
5045
|
const mode = block === "event-calendar" ? "list" : null;
|
|
@@ -6162,7 +6191,124 @@ const blockAppearancePresets = [
|
|
|
6162
6191
|
dates: "summary"
|
|
6163
6192
|
},
|
|
6164
6193
|
styleFallback: [id$1("feature-cards-cards")]
|
|
6165
|
-
})
|
|
6194
|
+
}),
|
|
6195
|
+
defineArrangementLook("body-text-title-beside", "body-text", "Title beside the text", "prose", [], { styleFallback: [id$1("body-text-reading-column")] }),
|
|
6196
|
+
defineArrangementLook("body-text-large-opening", "body-text", "Large opening paragraph", "prose", [], { styleFallback: [id$1("body-text-reading-column")] }),
|
|
6197
|
+
defineArrangementLook("faq-questions-under-title", "faq", "Questions under the title", "default", []),
|
|
6198
|
+
defineArrangementLook("faq-title-beside-questions", "faq", "Title beside the questions", "two-column", [], { styleFallback: [id$1("faq-questions-under-title")] }),
|
|
6199
|
+
defineArrangementLook("faq-questions-two-columns", "faq", "Questions in two columns", "question-columns", [], { styleFallback: [id$1("faq-questions-under-title")] }),
|
|
6200
|
+
defineArrangementLook("faq-all-answers-showing", "faq", "All answers showing", "open", [], { styleFallback: [id$1("faq-questions-two-columns")] }),
|
|
6201
|
+
defineArrangementLook("image-gallery-lead-photo", "image-gallery", "One large photo, then smaller ones", "tiles", [], { styleFallback: [id$1("image-gallery-square-tiles")] }),
|
|
6202
|
+
defineArrangementLook("image-gallery-captions-under", "image-gallery", "Photos with captions underneath", "tiles", [], { styleFallback: [id$1("image-gallery-arched-captions"), id$1("image-gallery-square-tiles")] }),
|
|
6203
|
+
defineArrangementLook("cta-centred", "cta-full", "Centred, buttons below", "default", []),
|
|
6204
|
+
defineArrangementLook("cta-title-beside-buttons", "cta-full", "Title beside the buttons", "default", [], { styleFallback: [id$1("cta-centred")] }),
|
|
6205
|
+
defineArrangementLook("cta-figure-beside-offer", "cta-full", "Big figure beside the offer", "figure", [], {
|
|
6206
|
+
whenMissing: [{
|
|
6207
|
+
fact: "figure",
|
|
6208
|
+
look: id$1("cta-centred")
|
|
6209
|
+
}],
|
|
6210
|
+
styleFallback: [id$1("cta-centred")]
|
|
6211
|
+
}),
|
|
6212
|
+
{
|
|
6213
|
+
...defineCardListLook("team-members-tall-portraits", "Tall portraits in a row", "cards", [
|
|
6214
|
+
"media",
|
|
6215
|
+
"title",
|
|
6216
|
+
"text",
|
|
6217
|
+
"facts",
|
|
6218
|
+
"chips",
|
|
6219
|
+
"action"
|
|
6220
|
+
], ["showPhotos"], {
|
|
6221
|
+
knobDefaults: { actionStyle: "link" },
|
|
6222
|
+
styleFallback: [id$1("team-members-ruled-names")]
|
|
6223
|
+
}),
|
|
6224
|
+
blockKinds: ["block.team-members"]
|
|
6225
|
+
},
|
|
6226
|
+
{
|
|
6227
|
+
...defineCardListLook("team-members-portrait-bio", "Portrait beside a longer bio", "stack", [
|
|
6228
|
+
"media",
|
|
6229
|
+
"title",
|
|
6230
|
+
"text",
|
|
6231
|
+
"facts",
|
|
6232
|
+
"chips",
|
|
6233
|
+
"action"
|
|
6234
|
+
], ["showPhotos"], {
|
|
6235
|
+
teamBiography: "profile",
|
|
6236
|
+
knobDefaults: { actionStyle: "link" },
|
|
6237
|
+
styleFallback: [id$1("team-members-tall-portraits")]
|
|
6238
|
+
}),
|
|
6239
|
+
blockKinds: ["block.team-members"]
|
|
6240
|
+
},
|
|
6241
|
+
{
|
|
6242
|
+
...defineCardListLook("team-members-ruled-names", "Names in a ruled list", "index", [
|
|
6243
|
+
"title",
|
|
6244
|
+
"text",
|
|
6245
|
+
"facts",
|
|
6246
|
+
"chips",
|
|
6247
|
+
"action"
|
|
6248
|
+
], [], {
|
|
6249
|
+
forcedKnobs: {
|
|
6250
|
+
showPhotos: "false",
|
|
6251
|
+
cardMarker: "none"
|
|
6252
|
+
},
|
|
6253
|
+
knobDefaults: { actionStyle: "link" },
|
|
6254
|
+
styleFallback: [id$1("feature-cards-index")]
|
|
6255
|
+
}),
|
|
6256
|
+
blockKinds: ["block.team-members"]
|
|
6257
|
+
},
|
|
6258
|
+
defineCardListLook("shop-price-cards", "Price cards", "cards", [
|
|
6259
|
+
"title",
|
|
6260
|
+
"text",
|
|
6261
|
+
"facts",
|
|
6262
|
+
"price",
|
|
6263
|
+
"action"
|
|
6264
|
+
], [], {
|
|
6265
|
+
itemRoles: { items: "card" },
|
|
6266
|
+
styleFallback: [id$1("shop-ruled-prices")]
|
|
6267
|
+
}),
|
|
6268
|
+
defineCardListLook("shop-price-cards-featured", "Price cards, one featured", "cards", [
|
|
6269
|
+
"title",
|
|
6270
|
+
"text",
|
|
6271
|
+
"facts",
|
|
6272
|
+
"price",
|
|
6273
|
+
"action"
|
|
6274
|
+
], [], {
|
|
6275
|
+
itemRoles: {
|
|
6276
|
+
items: "card",
|
|
6277
|
+
featured: "statement"
|
|
6278
|
+
},
|
|
6279
|
+
whenMissing: [{
|
|
6280
|
+
fact: "featured",
|
|
6281
|
+
look: id$1("shop-price-cards")
|
|
6282
|
+
}],
|
|
6283
|
+
styleFallback: [id$1("shop-price-cards")]
|
|
6284
|
+
}),
|
|
6285
|
+
defineCardListLook("shop-ruled-prices", "Prices in a ruled list", "index", [
|
|
6286
|
+
"title",
|
|
6287
|
+
"text",
|
|
6288
|
+
"facts",
|
|
6289
|
+
"price",
|
|
6290
|
+
"action"
|
|
6291
|
+
], [], {
|
|
6292
|
+
forcedKnobs: { cardMarker: "none" },
|
|
6293
|
+
knobDefaults: { actionStyle: "link" },
|
|
6294
|
+
styleFallback: [id$1("feature-cards-index")]
|
|
6295
|
+
}),
|
|
6296
|
+
{
|
|
6297
|
+
...defineCardListLook("card-list-photos-on-top", "Photos on top, three across", "cards", [
|
|
6298
|
+
"media",
|
|
6299
|
+
"title",
|
|
6300
|
+
"text",
|
|
6301
|
+
"facts",
|
|
6302
|
+
"action"
|
|
6303
|
+
], ["showPhotos"], {
|
|
6304
|
+
knobDefaults: {
|
|
6305
|
+
actionStyle: "link",
|
|
6306
|
+
dates: "summary"
|
|
6307
|
+
},
|
|
6308
|
+
styleFallback: [id$1("feature-cards-cards")]
|
|
6309
|
+
}),
|
|
6310
|
+
blockKinds: ["block.offerings-preview", "block.appointment-services"]
|
|
6311
|
+
}
|
|
6166
6312
|
];
|
|
6167
6313
|
|
|
6168
6314
|
//#endregion
|
|
@@ -10036,7 +10182,7 @@ function planFileUploadFinalization(input) {
|
|
|
10036
10182
|
const declaredMimeType = input.declaredMimeType;
|
|
10037
10183
|
const declaredKind = classifyOptionalDeclaredMimeType(declaredMimeType);
|
|
10038
10184
|
if (!declaredKind.ok) return declaredKind;
|
|
10039
|
-
if (declaredMimeType !== undefined && declaredKind.value !== undefined && !
|
|
10185
|
+
if (declaredMimeType !== undefined && declaredKind.value !== undefined && !areUploadFormatsInterchangeable(declaredKind.value, detectedKind.value)) {
|
|
10040
10186
|
return err({
|
|
10041
10187
|
tag: "declared-detected-mime-mismatch",
|
|
10042
10188
|
declaredMimeType,
|
|
@@ -10187,6 +10333,18 @@ function accessPolicyForFinalizedUpload(uploadSession) {
|
|
|
10187
10333
|
};
|
|
10188
10334
|
}
|
|
10189
10335
|
}
|
|
10336
|
+
function areUploadFormatsInterchangeable(declared, detected) {
|
|
10337
|
+
if (areFileKindsEqual(declared, detected)) return true;
|
|
10338
|
+
switch (declared.tag) {
|
|
10339
|
+
case "image": return detected.tag === "image" && declared.format !== "svg" && detected.format !== "svg";
|
|
10340
|
+
case "audio":
|
|
10341
|
+
case "video": return detected.tag === declared.tag;
|
|
10342
|
+
case "document":
|
|
10343
|
+
case "spreadsheet":
|
|
10344
|
+
case "font":
|
|
10345
|
+
case "archive": return false;
|
|
10346
|
+
}
|
|
10347
|
+
}
|
|
10190
10348
|
|
|
10191
10349
|
//#endregion
|
|
10192
10350
|
//#region ../media-core/src/fileUploadSessionCreation.ts
|
|
@@ -10249,6 +10407,63 @@ function planFileUploadSessionCreation(input) {
|
|
|
10249
10407
|
});
|
|
10250
10408
|
}
|
|
10251
10409
|
|
|
10410
|
+
//#endregion
|
|
10411
|
+
//#region ../media-core/src/mimeType.ts
|
|
10412
|
+
const MIME_TYPES_BY_EXTENSION = {
|
|
10413
|
+
".jpg": "image/jpeg",
|
|
10414
|
+
".jpeg": "image/jpeg",
|
|
10415
|
+
".png": "image/png",
|
|
10416
|
+
".gif": "image/gif",
|
|
10417
|
+
".webp": "image/webp",
|
|
10418
|
+
".svg": "image/svg+xml",
|
|
10419
|
+
".avif": "image/avif",
|
|
10420
|
+
".heic": "image/heic",
|
|
10421
|
+
".heif": "image/heif",
|
|
10422
|
+
".mp4": "video/mp4",
|
|
10423
|
+
".webm": "video/webm",
|
|
10424
|
+
".mov": "video/quicktime",
|
|
10425
|
+
".mp3": "audio/mpeg",
|
|
10426
|
+
".m4a": "audio/mp4",
|
|
10427
|
+
".wav": "audio/wav",
|
|
10428
|
+
".ogg": "audio/ogg",
|
|
10429
|
+
".flac": "audio/flac",
|
|
10430
|
+
".pdf": "application/pdf"
|
|
10431
|
+
};
|
|
10432
|
+
const EXTENSIONS_BY_MIME_TYPE = {
|
|
10433
|
+
"image/jpeg": ".jpg",
|
|
10434
|
+
"image/png": ".png",
|
|
10435
|
+
"image/gif": ".gif",
|
|
10436
|
+
"image/webp": ".webp",
|
|
10437
|
+
"image/svg+xml": ".svg",
|
|
10438
|
+
"image/avif": ".avif",
|
|
10439
|
+
"image/heic": ".heic",
|
|
10440
|
+
"image/heif": ".heif",
|
|
10441
|
+
"video/mp4": ".mp4",
|
|
10442
|
+
"video/webm": ".webm",
|
|
10443
|
+
"video/quicktime": ".mov",
|
|
10444
|
+
"audio/mpeg": ".mp3",
|
|
10445
|
+
"audio/mp4": ".m4a",
|
|
10446
|
+
"audio/wav": ".wav",
|
|
10447
|
+
"audio/x-wav": ".wav",
|
|
10448
|
+
"audio/ogg": ".ogg",
|
|
10449
|
+
"audio/webm": ".webm",
|
|
10450
|
+
"audio/flac": ".flac",
|
|
10451
|
+
"application/pdf": ".pdf"
|
|
10452
|
+
};
|
|
10453
|
+
function fileExtension(filename) {
|
|
10454
|
+
const pathSegments = filename.replace(/\\/g, "/").split("/");
|
|
10455
|
+
const basename = pathSegments[pathSegments.length - 1] ?? filename;
|
|
10456
|
+
const dotIndex = basename.lastIndexOf(".");
|
|
10457
|
+
return dotIndex <= 0 ? "" : basename.slice(dotIndex).toLowerCase();
|
|
10458
|
+
}
|
|
10459
|
+
function getMimeType(filename) {
|
|
10460
|
+
return MIME_TYPES_BY_EXTENSION[fileExtension(filename)] ?? "application/octet-stream";
|
|
10461
|
+
}
|
|
10462
|
+
function getExtensionForMimeType(mimeType) {
|
|
10463
|
+
if (!mimeType) return null;
|
|
10464
|
+
return EXTENSIONS_BY_MIME_TYPE[mimeType.toLowerCase()] ?? null;
|
|
10465
|
+
}
|
|
10466
|
+
|
|
10252
10467
|
//#endregion
|
|
10253
10468
|
//#region ../media-core/src/fileUploadAssetBuilder.ts
|
|
10254
10469
|
/**
|
|
@@ -10274,38 +10489,41 @@ function toDurableFinalizeUploadAssetPlan(plan) {
|
|
|
10274
10489
|
});
|
|
10275
10490
|
}
|
|
10276
10491
|
function expectedDurableUploadStoragePath(finalizationPlan, assetId) {
|
|
10277
|
-
|
|
10492
|
+
const storage = finalizedUploadStorage(finalizationPlan, assetId);
|
|
10493
|
+
return storage.ok ? ok(storage.value.storagePath) : storage;
|
|
10494
|
+
}
|
|
10495
|
+
function finalizedUploadStorage(plan, assetId) {
|
|
10496
|
+
if (plan.uploadSession.safeDownloadFilename === undefined) {
|
|
10278
10497
|
return err({ tag: "safe-download-filename-required" });
|
|
10279
10498
|
}
|
|
10280
|
-
const
|
|
10281
|
-
|
|
10499
|
+
const safe = asSafeDownloadFilename(finalizedUploadFilename(plan.uploadSession.safeDownloadFilename, plan.detectedMimeType));
|
|
10500
|
+
if (!safe.ok) return err({ tag: "safe-download-filename-required" });
|
|
10501
|
+
const path = buildDurableFileStoragePath({
|
|
10502
|
+
siteId: plan.uploadSession.siteId,
|
|
10282
10503
|
fileAssetId: assetId,
|
|
10283
|
-
safeDownloadFilename:
|
|
10504
|
+
safeDownloadFilename: safe.value
|
|
10505
|
+
});
|
|
10506
|
+
return path.ok ? ok({
|
|
10507
|
+
storagePath: path.value,
|
|
10508
|
+
filename: unsafeAsOriginalFilename(finalizedUploadFilename(plan.uploadSession.originalFilename, plan.detectedMimeType)),
|
|
10509
|
+
safeDownloadFilename: safe.value
|
|
10510
|
+
}) : err({
|
|
10511
|
+
tag: "invalid-storage-path",
|
|
10512
|
+
error: path.error
|
|
10284
10513
|
});
|
|
10285
|
-
if (!targetStoragePath.ok) {
|
|
10286
|
-
return err({
|
|
10287
|
-
tag: "invalid-storage-path",
|
|
10288
|
-
error: targetStoragePath.error
|
|
10289
|
-
});
|
|
10290
|
-
}
|
|
10291
|
-
return ok(targetStoragePath.value);
|
|
10292
10514
|
}
|
|
10293
10515
|
/**
|
|
10294
10516
|
* Builds a validated active durable file asset from a policy-checked upload finalization plan.
|
|
10295
10517
|
*/
|
|
10296
10518
|
function buildFinalizedUploadFileAsset(input) {
|
|
10297
10519
|
const { finalizationPlan } = input;
|
|
10298
|
-
const
|
|
10299
|
-
if (!
|
|
10300
|
-
return targetStoragePath;
|
|
10301
|
-
}
|
|
10520
|
+
const storage = finalizedUploadStorage(finalizationPlan, input.assetId);
|
|
10521
|
+
if (!storage.ok) return storage;
|
|
10302
10522
|
const asset = {
|
|
10303
10523
|
id: input.assetId,
|
|
10304
10524
|
siteId: finalizationPlan.uploadSession.siteId,
|
|
10305
10525
|
storageBucket: finalizationPlan.targetStorageBucket,
|
|
10306
|
-
|
|
10307
|
-
filename: finalizationPlan.uploadSession.originalFilename,
|
|
10308
|
-
safeDownloadFilename: finalizationPlan.uploadSession.safeDownloadFilename,
|
|
10526
|
+
...storage.value,
|
|
10309
10527
|
mimeType: unsafeAsDeclaredMimeType(finalizationPlan.detectedMimeType),
|
|
10310
10528
|
kind: finalizationPlan.detectedKind,
|
|
10311
10529
|
uses: finalizationPlan.fileUses,
|
|
@@ -10338,6 +10556,11 @@ function defaultMetadataForKind(kind) {
|
|
|
10338
10556
|
case "archive": return { tag: "file-metadata" };
|
|
10339
10557
|
}
|
|
10340
10558
|
}
|
|
10559
|
+
function finalizedUploadFilename(filename, detectedMimeType) {
|
|
10560
|
+
const extension = getExtensionForMimeType(detectedMimeType);
|
|
10561
|
+
if (extension === null || getMimeType(filename) === detectedMimeType) return filename;
|
|
10562
|
+
return `${filename.replace(/\.[^.\/\\]+$/u, "")}${extension}`;
|
|
10563
|
+
}
|
|
10341
10564
|
|
|
10342
10565
|
//#endregion
|
|
10343
10566
|
//#region ../media-core/src/fileUploadCompletion.ts
|
|
@@ -10364,7 +10587,8 @@ function planDurableFileUploadCompletion(input) {
|
|
|
10364
10587
|
const promoteStep = {
|
|
10365
10588
|
tag: "promote-staged-object",
|
|
10366
10589
|
sourceObject,
|
|
10367
|
-
targetObject
|
|
10590
|
+
targetObject,
|
|
10591
|
+
...input.finalizationPlan.uploadSession.declaredMimeType !== String(input.finalizationPlan.detectedMimeType) ? { correctedContentType: input.finalizationPlan.detectedMimeType } : {}
|
|
10368
10592
|
};
|
|
10369
10593
|
const insertStep = {
|
|
10370
10594
|
tag: "insert-file-asset",
|
|
@@ -11181,61 +11405,6 @@ function startsWithIgnoreCase(text, token, index) {
|
|
|
11181
11405
|
return text.slice(index, index + token.length).toLowerCase() === token;
|
|
11182
11406
|
}
|
|
11183
11407
|
|
|
11184
|
-
//#endregion
|
|
11185
|
-
//#region ../media-core/src/mimeType.ts
|
|
11186
|
-
const MIME_TYPES_BY_EXTENSION = {
|
|
11187
|
-
".jpg": "image/jpeg",
|
|
11188
|
-
".jpeg": "image/jpeg",
|
|
11189
|
-
".png": "image/png",
|
|
11190
|
-
".gif": "image/gif",
|
|
11191
|
-
".webp": "image/webp",
|
|
11192
|
-
".svg": "image/svg+xml",
|
|
11193
|
-
".avif": "image/avif",
|
|
11194
|
-
".heic": "image/heic",
|
|
11195
|
-
".mp4": "video/mp4",
|
|
11196
|
-
".webm": "video/webm",
|
|
11197
|
-
".mov": "video/quicktime",
|
|
11198
|
-
".mp3": "audio/mpeg",
|
|
11199
|
-
".m4a": "audio/mp4",
|
|
11200
|
-
".wav": "audio/wav",
|
|
11201
|
-
".ogg": "audio/ogg",
|
|
11202
|
-
".flac": "audio/flac",
|
|
11203
|
-
".pdf": "application/pdf"
|
|
11204
|
-
};
|
|
11205
|
-
const EXTENSIONS_BY_MIME_TYPE = {
|
|
11206
|
-
"image/jpeg": ".jpg",
|
|
11207
|
-
"image/png": ".png",
|
|
11208
|
-
"image/gif": ".gif",
|
|
11209
|
-
"image/webp": ".webp",
|
|
11210
|
-
"image/svg+xml": ".svg",
|
|
11211
|
-
"image/avif": ".avif",
|
|
11212
|
-
"image/heic": ".heic",
|
|
11213
|
-
"video/mp4": ".mp4",
|
|
11214
|
-
"video/webm": ".webm",
|
|
11215
|
-
"video/quicktime": ".mov",
|
|
11216
|
-
"audio/mpeg": ".mp3",
|
|
11217
|
-
"audio/mp4": ".m4a",
|
|
11218
|
-
"audio/wav": ".wav",
|
|
11219
|
-
"audio/x-wav": ".wav",
|
|
11220
|
-
"audio/ogg": ".ogg",
|
|
11221
|
-
"audio/webm": ".webm",
|
|
11222
|
-
"audio/flac": ".flac",
|
|
11223
|
-
"application/pdf": ".pdf"
|
|
11224
|
-
};
|
|
11225
|
-
function fileExtension(filename) {
|
|
11226
|
-
const pathSegments = filename.replace(/\\/g, "/").split("/");
|
|
11227
|
-
const basename = pathSegments[pathSegments.length - 1] ?? filename;
|
|
11228
|
-
const dotIndex = basename.lastIndexOf(".");
|
|
11229
|
-
return dotIndex <= 0 ? "" : basename.slice(dotIndex).toLowerCase();
|
|
11230
|
-
}
|
|
11231
|
-
function getMimeType(filename) {
|
|
11232
|
-
return MIME_TYPES_BY_EXTENSION[fileExtension(filename)] ?? "application/octet-stream";
|
|
11233
|
-
}
|
|
11234
|
-
function getExtensionForMimeType(mimeType) {
|
|
11235
|
-
if (!mimeType) return null;
|
|
11236
|
-
return EXTENSIONS_BY_MIME_TYPE[mimeType.toLowerCase()] ?? null;
|
|
11237
|
-
}
|
|
11238
|
-
|
|
11239
11408
|
//#endregion
|
|
11240
11409
|
//#region ../media-core/src/filename.ts
|
|
11241
11410
|
function filenameExtension(filename) {
|
|
@@ -11792,6 +11961,7 @@ function mediaUsageLocationLabel(location) {
|
|
|
11792
11961
|
}
|
|
11793
11962
|
case "newsletterTemplate": return `Newsletter template: ${location.templateName}`;
|
|
11794
11963
|
case "newsletterCampaign": return `Newsletter campaign: ${location.campaignName}`;
|
|
11964
|
+
case "appointmentService": return `Appointment service: ${location.serviceTitle}`;
|
|
11795
11965
|
case "productFileDownload": return `${location.productTitle} — Product download`;
|
|
11796
11966
|
default: return assertNever$2(location);
|
|
11797
11967
|
}
|
|
@@ -13776,7 +13946,21 @@ function parseCanonicalRuntimeBackground(content) {
|
|
|
13776
13946
|
};
|
|
13777
13947
|
}
|
|
13778
13948
|
function resolveSectionBackground(source, lookDefault, rhythm, arrangementHeroPhoto) {
|
|
13779
|
-
if (heroPhotoIsContent(source, arrangementHeroPhoto))
|
|
13949
|
+
if (heroPhotoIsContent(source, arrangementHeroPhoto, rhythm !== undefined)) {
|
|
13950
|
+
if (rhythm !== undefined) return rhythmBackground(rhythm);
|
|
13951
|
+
return {
|
|
13952
|
+
kind: "content-media",
|
|
13953
|
+
background: source.background,
|
|
13954
|
+
ground: {
|
|
13955
|
+
type: "color",
|
|
13956
|
+
color: arrangementHeroPhoto?.fallbackToken ?? "background",
|
|
13957
|
+
textColor: source.background.textColor,
|
|
13958
|
+
headingColor: source.background.headingColor,
|
|
13959
|
+
linkColor: source.background.linkColor,
|
|
13960
|
+
supportingColor: source.background.supportingColor
|
|
13961
|
+
}
|
|
13962
|
+
};
|
|
13963
|
+
}
|
|
13780
13964
|
if (source.kind === "page-design-override") {
|
|
13781
13965
|
return {
|
|
13782
13966
|
kind: "override",
|
|
@@ -13806,7 +13990,7 @@ function resolveSectionPhotoPlacement(background, heroPhoto) {
|
|
|
13806
13990
|
return background.kind !== "base" && background.background.type === "image" && background.background.image !== undefined ? "behind-text" : "none";
|
|
13807
13991
|
}
|
|
13808
13992
|
function resolveSectionForeground(background, palette) {
|
|
13809
|
-
return resolveSurfaceForeground(background
|
|
13993
|
+
return resolveSurfaceForeground(sectionForegroundBackground(background, palette), palette, {}, { compositeBase: "background" });
|
|
13810
13994
|
}
|
|
13811
13995
|
/**
|
|
13812
13996
|
* Read foreground authority from post-compiler block content. The preview
|
|
@@ -13814,9 +13998,40 @@ function resolveSectionForeground(background, palette) {
|
|
|
13814
13998
|
* `_sectionStyles`; raw authored content must be composed with its Look through
|
|
13815
13999
|
* `resolveSectionBackground` instead.
|
|
13816
14000
|
*/
|
|
13817
|
-
function resolveCompiledSectionForegroundFromContent(content, palette) {
|
|
14001
|
+
function resolveCompiledSectionForegroundFromContent(content, palette, photo) {
|
|
13818
14002
|
if (!content) return resolveSurfaceForeground(null, palette);
|
|
13819
|
-
return resolveSectionForeground(resolveSectionBackground(parseCanonicalRuntimeBackground(content), null), palette);
|
|
14003
|
+
return resolveSectionForeground(resolveSectionBackground(parseCanonicalRuntimeBackground(content), null, compiledOpeningRhythm(content), photo), palette);
|
|
14004
|
+
}
|
|
14005
|
+
/** Legacy detached photos keep already-legible authored ink and its exact CSS treatment. */
|
|
14006
|
+
function sectionForegroundBackground(resolved, palette) {
|
|
14007
|
+
if (resolved.kind === "base") return null;
|
|
14008
|
+
if (resolved.kind !== "content-media") return resolved.background;
|
|
14009
|
+
const original = resolveSurfaceForeground(resolved.background, palette);
|
|
14010
|
+
const measured = resolveSurfaceForeground(resolved.ground, palette);
|
|
14011
|
+
if (original.kind === "unknown" || measured.kind === "unknown") return resolved.background;
|
|
14012
|
+
const roles = [
|
|
14013
|
+
"text",
|
|
14014
|
+
"heading",
|
|
14015
|
+
"link",
|
|
14016
|
+
"supporting"
|
|
14017
|
+
];
|
|
14018
|
+
return roles.every((role) => original.roles[role] === measured.roles[role]) ? resolved.background : resolved.ground;
|
|
14019
|
+
}
|
|
14020
|
+
/** One photo-placement decision for legacy and arrangement hero renderers. */
|
|
14021
|
+
function heroPhotoPaintsGround(variant) {
|
|
14022
|
+
return ![
|
|
14023
|
+
"split",
|
|
14024
|
+
"splitReverse",
|
|
14025
|
+
"headline-row",
|
|
14026
|
+
"copy-over-gallery",
|
|
14027
|
+
"page-head"
|
|
14028
|
+
].includes(variant ?? "classic");
|
|
14029
|
+
}
|
|
14030
|
+
function compiledOpeningRhythm(content) {
|
|
14031
|
+
const arrangement = readRecord(content._arrangementLooks);
|
|
14032
|
+
if (!Array.isArray(arrangement?.rhythm)) return undefined;
|
|
14033
|
+
const parsed = runtimeBoxBackgroundSchema.safeParse(arrangement.rhythm[0]);
|
|
14034
|
+
return parsed.success ? parsed.data : null;
|
|
13820
14035
|
}
|
|
13821
14036
|
function mergeLookForegroundWithAuthoredMedia(lookDefault, authored) {
|
|
13822
14037
|
const paintsBand = lookDefault.type === "color" || lookDefault.type === "gradient";
|
|
@@ -13836,8 +14051,8 @@ function mergeLookForegroundWithAuthoredMedia(lookDefault, authored) {
|
|
|
13836
14051
|
function readRecord(value) {
|
|
13837
14052
|
return typeof value === "object" && value !== null && !Array.isArray(value) ? value : null;
|
|
13838
14053
|
}
|
|
13839
|
-
function heroPhotoIsContent(source, photo) {
|
|
13840
|
-
return photo !== undefined && !photo.paintsGround && source.kind === "block-authored" && source.background.type === "image";
|
|
14054
|
+
function heroPhotoIsContent(source, photo, hasArrangementGround) {
|
|
14055
|
+
return photo !== undefined && !photo.paintsGround && source.kind === "block-authored" && source.background.type === "image" && (hasArrangementGround || !source.background.overlay);
|
|
13841
14056
|
}
|
|
13842
14057
|
function isAuthoredMedia(source) {
|
|
13843
14058
|
return source.kind === "block-authored" && (source.background.type === "image" || source.background.type === "video");
|
|
@@ -13867,9 +14082,10 @@ const solidGrounds = {
|
|
|
13867
14082
|
};
|
|
13868
14083
|
function deriveSectionGround(resolved, palette) {
|
|
13869
14084
|
if (resolved.kind === "base") return "light";
|
|
13870
|
-
const
|
|
14085
|
+
const background = resolved.kind === "content-media" ? resolved.ground : resolved.background;
|
|
14086
|
+
const solid = solidSectionGround(background);
|
|
13871
14087
|
if (solid) return solid;
|
|
13872
|
-
const tone = scrimTone(sectionScrimSamples(
|
|
14088
|
+
const tone = scrimTone(sectionScrimSamples(background, palette)) ?? sectionForegroundTone(resolved, palette);
|
|
13873
14089
|
return tone === "dark" ? "deep" : "light";
|
|
13874
14090
|
}
|
|
13875
14091
|
function solidSectionGround(background) {
|
|
@@ -15774,6 +15990,9 @@ const arrangementSlotNames = [
|
|
|
15774
15990
|
"date-label",
|
|
15775
15991
|
"time",
|
|
15776
15992
|
"price",
|
|
15993
|
+
"price-amount",
|
|
15994
|
+
"price-unit",
|
|
15995
|
+
"price-note",
|
|
15777
15996
|
"mark",
|
|
15778
15997
|
"navigation",
|
|
15779
15998
|
"time-start",
|
|
@@ -15836,6 +16055,7 @@ function assignedItemRoles(look, overrides) {
|
|
|
15836
16055
|
...Object.values(look.structure.slotRoles ?? {}),
|
|
15837
16056
|
...roles.container ? [roles.container] : [],
|
|
15838
16057
|
...roles.items ? [roles.items] : [],
|
|
16058
|
+
...roles.featured ? [roles.featured] : [],
|
|
15839
16059
|
...Object.values(roles.at ?? {})
|
|
15840
16060
|
];
|
|
15841
16061
|
}
|
|
@@ -33929,6 +34149,74 @@ const folioLooks = {
|
|
|
33929
34149
|
id: id("card-list-scroll-row"),
|
|
33930
34150
|
treatment: "carousel-row-sheet",
|
|
33931
34151
|
roleMap: folioRoles
|
|
34152
|
+
},
|
|
34153
|
+
{
|
|
34154
|
+
id: id("body-text-title-beside"),
|
|
34155
|
+
treatment: "body-beside",
|
|
34156
|
+
roleMap: folioRoles
|
|
34157
|
+
},
|
|
34158
|
+
{
|
|
34159
|
+
id: id("body-text-large-opening"),
|
|
34160
|
+
treatment: "body-opening",
|
|
34161
|
+
roleMap: folioRoles
|
|
34162
|
+
},
|
|
34163
|
+
{
|
|
34164
|
+
id: id("faq-questions-under-title"),
|
|
34165
|
+
treatment: "faq-under",
|
|
34166
|
+
itemRoles: { items: "card" },
|
|
34167
|
+
roleMap: folioRoles
|
|
34168
|
+
},
|
|
34169
|
+
{
|
|
34170
|
+
id: id("faq-title-beside-questions"),
|
|
34171
|
+
treatment: "faq-beside",
|
|
34172
|
+
itemRoles: { items: "card" },
|
|
34173
|
+
roleMap: folioRoles
|
|
34174
|
+
},
|
|
34175
|
+
{
|
|
34176
|
+
id: id("faq-questions-two-columns"),
|
|
34177
|
+
treatment: "faq-columns",
|
|
34178
|
+
itemRoles: { items: "card" },
|
|
34179
|
+
roleMap: folioRoles
|
|
34180
|
+
},
|
|
34181
|
+
{
|
|
34182
|
+
id: id("faq-all-answers-showing"),
|
|
34183
|
+
treatment: "faq-open",
|
|
34184
|
+
roleMap: folioRoles
|
|
34185
|
+
},
|
|
34186
|
+
{
|
|
34187
|
+
id: id("image-gallery-square-tiles"),
|
|
34188
|
+
treatment: "gallery-tiles",
|
|
34189
|
+
roleMap: folioRoles
|
|
34190
|
+
},
|
|
34191
|
+
{
|
|
34192
|
+
id: id("image-gallery-lead-photo"),
|
|
34193
|
+
treatment: "gallery-lead",
|
|
34194
|
+
roleMap: folioRoles
|
|
34195
|
+
},
|
|
34196
|
+
{
|
|
34197
|
+
id: id("image-gallery-captions-under"),
|
|
34198
|
+
treatment: "gallery-captions",
|
|
34199
|
+
roleMap: folioRoles
|
|
34200
|
+
},
|
|
34201
|
+
{
|
|
34202
|
+
id: id("cta-centred"),
|
|
34203
|
+
treatment: "cta-centred",
|
|
34204
|
+
roleMap: folioRoles
|
|
34205
|
+
},
|
|
34206
|
+
{
|
|
34207
|
+
id: id("cta-title-beside-buttons"),
|
|
34208
|
+
treatment: "cta-beside",
|
|
34209
|
+
roleMap: folioRoles
|
|
34210
|
+
},
|
|
34211
|
+
{
|
|
34212
|
+
id: id("cta-figure-beside-offer"),
|
|
34213
|
+
treatment: "cta-figure",
|
|
34214
|
+
roleMap: folioRoles
|
|
34215
|
+
},
|
|
34216
|
+
{
|
|
34217
|
+
id: id("card-list-photos-on-top"),
|
|
34218
|
+
treatment: "photos-on-top",
|
|
34219
|
+
roleMap: folioRoles
|
|
33932
34220
|
}
|
|
33933
34221
|
]
|
|
33934
34222
|
};
|
|
@@ -34117,6 +34405,76 @@ const fulcrumOffers = [
|
|
|
34117
34405
|
id: id("card-list-accent-edged-cards"),
|
|
34118
34406
|
treatment: "cards-accent-edged",
|
|
34119
34407
|
roleMap: fulcrumRoles
|
|
34408
|
+
},
|
|
34409
|
+
{
|
|
34410
|
+
id: id("body-text-reading-column"),
|
|
34411
|
+
treatment: "body-column",
|
|
34412
|
+
roleMap: fulcrumRoles
|
|
34413
|
+
},
|
|
34414
|
+
{
|
|
34415
|
+
id: id("body-text-title-beside"),
|
|
34416
|
+
treatment: "body-beside",
|
|
34417
|
+
roleMap: fulcrumRoles
|
|
34418
|
+
},
|
|
34419
|
+
{
|
|
34420
|
+
id: id("body-text-large-opening"),
|
|
34421
|
+
treatment: "body-opening",
|
|
34422
|
+
roleMap: fulcrumRoles
|
|
34423
|
+
},
|
|
34424
|
+
{
|
|
34425
|
+
id: id("faq-questions-under-title"),
|
|
34426
|
+
treatment: "faq-under",
|
|
34427
|
+
roleMap: fulcrumRoles
|
|
34428
|
+
},
|
|
34429
|
+
{
|
|
34430
|
+
id: id("faq-title-beside-questions"),
|
|
34431
|
+
treatment: "faq-beside",
|
|
34432
|
+
roleMap: fulcrumRoles
|
|
34433
|
+
},
|
|
34434
|
+
{
|
|
34435
|
+
id: id("faq-questions-two-columns"),
|
|
34436
|
+
treatment: "faq-columns",
|
|
34437
|
+
roleMap: fulcrumRoles
|
|
34438
|
+
},
|
|
34439
|
+
{
|
|
34440
|
+
id: id("faq-all-answers-showing"),
|
|
34441
|
+
treatment: "faq-open",
|
|
34442
|
+
roleMap: fulcrumRoles
|
|
34443
|
+
},
|
|
34444
|
+
{
|
|
34445
|
+
id: id("image-gallery-square-tiles"),
|
|
34446
|
+
treatment: "gallery-tiles",
|
|
34447
|
+
roleMap: fulcrumRoles
|
|
34448
|
+
},
|
|
34449
|
+
{
|
|
34450
|
+
id: id("image-gallery-lead-photo"),
|
|
34451
|
+
treatment: "gallery-lead",
|
|
34452
|
+
roleMap: fulcrumRoles
|
|
34453
|
+
},
|
|
34454
|
+
{
|
|
34455
|
+
id: id("image-gallery-captions-under"),
|
|
34456
|
+
treatment: "gallery-captions",
|
|
34457
|
+
roleMap: fulcrumRoles
|
|
34458
|
+
},
|
|
34459
|
+
{
|
|
34460
|
+
id: id("cta-centred"),
|
|
34461
|
+
treatment: "cta-centred",
|
|
34462
|
+
roleMap: fulcrumRoles
|
|
34463
|
+
},
|
|
34464
|
+
{
|
|
34465
|
+
id: id("cta-title-beside-buttons"),
|
|
34466
|
+
treatment: "cta-beside",
|
|
34467
|
+
roleMap: fulcrumRoles
|
|
34468
|
+
},
|
|
34469
|
+
{
|
|
34470
|
+
id: id("cta-figure-beside-offer"),
|
|
34471
|
+
treatment: "cta-figure",
|
|
34472
|
+
roleMap: fulcrumRoles
|
|
34473
|
+
},
|
|
34474
|
+
{
|
|
34475
|
+
id: id("card-list-photos-on-top"),
|
|
34476
|
+
treatment: "photos-on-top",
|
|
34477
|
+
roleMap: fulcrumRoles
|
|
34120
34478
|
}
|
|
34121
34479
|
];
|
|
34122
34480
|
const fulcrumLooks = {
|
|
@@ -34362,6 +34720,76 @@ const posterOffers = [
|
|
|
34362
34720
|
id: id("card-list-scroll-row"),
|
|
34363
34721
|
treatment: "carousel-row-punchy",
|
|
34364
34722
|
roleMap: posterRoles
|
|
34723
|
+
},
|
|
34724
|
+
{
|
|
34725
|
+
id: id("body-text-reading-column"),
|
|
34726
|
+
treatment: "body-column",
|
|
34727
|
+
roleMap: posterRoles
|
|
34728
|
+
},
|
|
34729
|
+
{
|
|
34730
|
+
id: id("body-text-title-beside"),
|
|
34731
|
+
treatment: "body-beside",
|
|
34732
|
+
roleMap: posterRoles
|
|
34733
|
+
},
|
|
34734
|
+
{
|
|
34735
|
+
id: id("body-text-large-opening"),
|
|
34736
|
+
treatment: "body-opening",
|
|
34737
|
+
roleMap: posterRoles
|
|
34738
|
+
},
|
|
34739
|
+
{
|
|
34740
|
+
id: id("faq-questions-under-title"),
|
|
34741
|
+
treatment: "faq-under",
|
|
34742
|
+
roleMap: posterRoles
|
|
34743
|
+
},
|
|
34744
|
+
{
|
|
34745
|
+
id: id("faq-title-beside-questions"),
|
|
34746
|
+
treatment: "faq-beside",
|
|
34747
|
+
roleMap: posterRoles
|
|
34748
|
+
},
|
|
34749
|
+
{
|
|
34750
|
+
id: id("faq-questions-two-columns"),
|
|
34751
|
+
treatment: "faq-columns",
|
|
34752
|
+
roleMap: posterRoles
|
|
34753
|
+
},
|
|
34754
|
+
{
|
|
34755
|
+
id: id("faq-all-answers-showing"),
|
|
34756
|
+
treatment: "faq-open",
|
|
34757
|
+
roleMap: posterRoles
|
|
34758
|
+
},
|
|
34759
|
+
{
|
|
34760
|
+
id: id("image-gallery-square-tiles"),
|
|
34761
|
+
treatment: "gallery-tiles",
|
|
34762
|
+
roleMap: posterRoles
|
|
34763
|
+
},
|
|
34764
|
+
{
|
|
34765
|
+
id: id("image-gallery-lead-photo"),
|
|
34766
|
+
treatment: "gallery-lead",
|
|
34767
|
+
roleMap: posterRoles
|
|
34768
|
+
},
|
|
34769
|
+
{
|
|
34770
|
+
id: id("image-gallery-captions-under"),
|
|
34771
|
+
treatment: "gallery-captions",
|
|
34772
|
+
roleMap: posterRoles
|
|
34773
|
+
},
|
|
34774
|
+
{
|
|
34775
|
+
id: id("cta-centred"),
|
|
34776
|
+
treatment: "cta-centred",
|
|
34777
|
+
roleMap: posterRoles
|
|
34778
|
+
},
|
|
34779
|
+
{
|
|
34780
|
+
id: id("cta-title-beside-buttons"),
|
|
34781
|
+
treatment: "cta-beside",
|
|
34782
|
+
roleMap: posterRoles
|
|
34783
|
+
},
|
|
34784
|
+
{
|
|
34785
|
+
id: id("cta-figure-beside-offer"),
|
|
34786
|
+
treatment: "cta-figure",
|
|
34787
|
+
roleMap: posterRoles
|
|
34788
|
+
},
|
|
34789
|
+
{
|
|
34790
|
+
id: id("card-list-photos-on-top"),
|
|
34791
|
+
treatment: "photos-on-top",
|
|
34792
|
+
roleMap: posterRoles
|
|
34365
34793
|
}
|
|
34366
34794
|
];
|
|
34367
34795
|
const posterLooks = {
|
|
@@ -34408,7 +34836,8 @@ const posterLooks = {
|
|
|
34408
34836
|
},
|
|
34409
34837
|
pop: {
|
|
34410
34838
|
kind: "token",
|
|
34411
|
-
token: "accent"
|
|
34839
|
+
token: "accent",
|
|
34840
|
+
buttonContext: { primary: unsafeAsOpaqueButtonColourToken("primary") }
|
|
34412
34841
|
},
|
|
34413
34842
|
inverse: {
|
|
34414
34843
|
kind: "token",
|
|
@@ -34680,6 +35109,64 @@ const lanternOffers = [
|
|
|
34680
35109
|
id: id("card-list-scroll-row"),
|
|
34681
35110
|
treatment: "carousel-row-cards",
|
|
34682
35111
|
roleMap: lanternRoles
|
|
35112
|
+
},
|
|
35113
|
+
{
|
|
35114
|
+
id: id("body-text-title-beside"),
|
|
35115
|
+
treatment: "body-beside",
|
|
35116
|
+
roleMap: lanternRoles
|
|
35117
|
+
},
|
|
35118
|
+
{
|
|
35119
|
+
id: id("body-text-large-opening"),
|
|
35120
|
+
treatment: "body-opening",
|
|
35121
|
+
roleMap: lanternRoles
|
|
35122
|
+
},
|
|
35123
|
+
{
|
|
35124
|
+
id: id("faq-questions-under-title"),
|
|
35125
|
+
treatment: "faq-under",
|
|
35126
|
+
itemRoles: { items: "card" },
|
|
35127
|
+
roleMap: lanternRoles
|
|
35128
|
+
},
|
|
35129
|
+
{
|
|
35130
|
+
id: id("faq-title-beside-questions"),
|
|
35131
|
+
treatment: "faq-beside",
|
|
35132
|
+
itemRoles: { items: "card" },
|
|
35133
|
+
roleMap: lanternRoles
|
|
35134
|
+
},
|
|
35135
|
+
{
|
|
35136
|
+
id: id("faq-questions-two-columns"),
|
|
35137
|
+
treatment: "faq-columns",
|
|
35138
|
+
itemRoles: { items: "card" },
|
|
35139
|
+
roleMap: lanternRoles
|
|
35140
|
+
},
|
|
35141
|
+
{
|
|
35142
|
+
id: id("faq-all-answers-showing"),
|
|
35143
|
+
treatment: "faq-open",
|
|
35144
|
+
roleMap: lanternRoles
|
|
35145
|
+
},
|
|
35146
|
+
{
|
|
35147
|
+
id: id("image-gallery-lead-photo"),
|
|
35148
|
+
treatment: "gallery-lead",
|
|
35149
|
+
roleMap: lanternRoles
|
|
35150
|
+
},
|
|
35151
|
+
{
|
|
35152
|
+
id: id("cta-centred"),
|
|
35153
|
+
treatment: "cta-centred",
|
|
35154
|
+
roleMap: lanternRoles
|
|
35155
|
+
},
|
|
35156
|
+
{
|
|
35157
|
+
id: id("cta-title-beside-buttons"),
|
|
35158
|
+
treatment: "cta-beside",
|
|
35159
|
+
roleMap: lanternRoles
|
|
35160
|
+
},
|
|
35161
|
+
{
|
|
35162
|
+
id: id("cta-figure-beside-offer"),
|
|
35163
|
+
treatment: "cta-figure",
|
|
35164
|
+
roleMap: lanternRoles
|
|
35165
|
+
},
|
|
35166
|
+
{
|
|
35167
|
+
id: id("card-list-photos-on-top"),
|
|
35168
|
+
treatment: "photos-on-top",
|
|
35169
|
+
roleMap: lanternRoles
|
|
34683
35170
|
}
|
|
34684
35171
|
];
|
|
34685
35172
|
const lanternLooks = {
|
|
@@ -34919,6 +35406,76 @@ const measureOffers = [
|
|
|
34919
35406
|
id: id("card-list-scroll-row"),
|
|
34920
35407
|
treatment: "carousel-row-sheets",
|
|
34921
35408
|
roleMap: measureRoles
|
|
35409
|
+
},
|
|
35410
|
+
{
|
|
35411
|
+
id: id("body-text-reading-column"),
|
|
35412
|
+
treatment: "body-column",
|
|
35413
|
+
roleMap: measureRoles
|
|
35414
|
+
},
|
|
35415
|
+
{
|
|
35416
|
+
id: id("body-text-title-beside"),
|
|
35417
|
+
treatment: "body-beside",
|
|
35418
|
+
roleMap: measureRoles
|
|
35419
|
+
},
|
|
35420
|
+
{
|
|
35421
|
+
id: id("body-text-large-opening"),
|
|
35422
|
+
treatment: "body-opening",
|
|
35423
|
+
roleMap: measureRoles
|
|
35424
|
+
},
|
|
35425
|
+
{
|
|
35426
|
+
id: id("faq-title-beside-questions"),
|
|
35427
|
+
treatment: "faq-beside",
|
|
35428
|
+
roleMap: measureRoles
|
|
35429
|
+
},
|
|
35430
|
+
{
|
|
35431
|
+
id: id("faq-questions-under-title"),
|
|
35432
|
+
treatment: "faq-under",
|
|
35433
|
+
roleMap: measureRoles
|
|
35434
|
+
},
|
|
35435
|
+
{
|
|
35436
|
+
id: id("faq-questions-two-columns"),
|
|
35437
|
+
treatment: "faq-columns",
|
|
35438
|
+
roleMap: measureRoles
|
|
35439
|
+
},
|
|
35440
|
+
{
|
|
35441
|
+
id: id("faq-all-answers-showing"),
|
|
35442
|
+
treatment: "faq-open",
|
|
35443
|
+
roleMap: measureRoles
|
|
35444
|
+
},
|
|
35445
|
+
{
|
|
35446
|
+
id: id("image-gallery-square-tiles"),
|
|
35447
|
+
treatment: "gallery-tiles",
|
|
35448
|
+
roleMap: measureRoles
|
|
35449
|
+
},
|
|
35450
|
+
{
|
|
35451
|
+
id: id("image-gallery-lead-photo"),
|
|
35452
|
+
treatment: "gallery-lead",
|
|
35453
|
+
roleMap: measureRoles
|
|
35454
|
+
},
|
|
35455
|
+
{
|
|
35456
|
+
id: id("image-gallery-captions-under"),
|
|
35457
|
+
treatment: "gallery-captions",
|
|
35458
|
+
roleMap: measureRoles
|
|
35459
|
+
},
|
|
35460
|
+
{
|
|
35461
|
+
id: id("cta-centred"),
|
|
35462
|
+
treatment: "cta-centred",
|
|
35463
|
+
roleMap: measureRoles
|
|
35464
|
+
},
|
|
35465
|
+
{
|
|
35466
|
+
id: id("cta-title-beside-buttons"),
|
|
35467
|
+
treatment: "cta-beside",
|
|
35468
|
+
roleMap: measureRoles
|
|
35469
|
+
},
|
|
35470
|
+
{
|
|
35471
|
+
id: id("cta-figure-beside-offer"),
|
|
35472
|
+
treatment: "cta-figure",
|
|
35473
|
+
roleMap: measureRoles
|
|
35474
|
+
},
|
|
35475
|
+
{
|
|
35476
|
+
id: id("card-list-photos-on-top"),
|
|
35477
|
+
treatment: "photos-on-top",
|
|
35478
|
+
roleMap: measureRoles
|
|
34922
35479
|
}
|
|
34923
35480
|
];
|
|
34924
35481
|
const measureLooks = {
|
|
@@ -35461,7 +36018,7 @@ const curatedSiteStyles = [
|
|
|
35461
36018
|
},
|
|
35462
36019
|
compositionBudget: quietBudget,
|
|
35463
36020
|
typography: fulcrumTypography,
|
|
35464
|
-
looks: fulcrumLooks,
|
|
36021
|
+
looks: withPriceLooks(withTeamLooks(fulcrumLooks, fulcrumRoles), fulcrumRoles),
|
|
35465
36022
|
contentTemplateDefaults: { event: "event-header" },
|
|
35466
36023
|
themeOverrides: {
|
|
35467
36024
|
accordions: {
|
|
@@ -35599,7 +36156,10 @@ const curatedSiteStyles = [
|
|
|
35599
36156
|
},
|
|
35600
36157
|
compositionBudget: expressiveBudget,
|
|
35601
36158
|
typography: posterTypography,
|
|
35602
|
-
looks: posterLooks,
|
|
36159
|
+
looks: withPriceLooks(withTeamLooks(posterLooks, posterRoles), posterRoles, {
|
|
36160
|
+
...posterRoles,
|
|
36161
|
+
statement: "pop"
|
|
36162
|
+
}),
|
|
35603
36163
|
contentTemplateDefaults: { event: "event-header" },
|
|
35604
36164
|
themeOverrides: {
|
|
35605
36165
|
accordions: boldBorderedAccordionSystem,
|
|
@@ -35653,7 +36213,7 @@ const curatedSiteStyles = [
|
|
|
35653
36213
|
},
|
|
35654
36214
|
compositionBudget: quietBudget,
|
|
35655
36215
|
typography: lanternTypography,
|
|
35656
|
-
looks: lanternLooks,
|
|
36216
|
+
looks: withPriceLooks(withTeamLooks(lanternLooks, lanternRoles), lanternRoles),
|
|
35657
36217
|
contentTemplateDefaults: { event: "event-header" },
|
|
35658
36218
|
themeOverrides: {
|
|
35659
36219
|
accordions: warmInsetAccordionSystem,
|
|
@@ -35713,7 +36273,7 @@ const curatedSiteStyles = [
|
|
|
35713
36273
|
},
|
|
35714
36274
|
compositionBudget: quietBudget,
|
|
35715
36275
|
typography: measureTypography,
|
|
35716
|
-
looks: measureLooks,
|
|
36276
|
+
looks: withPriceLooks(withTeamLooks(measureLooks, measureRoles), measureRoles),
|
|
35717
36277
|
contentTemplateDefaults: { event: "event-header" },
|
|
35718
36278
|
themeOverrides: {
|
|
35719
36279
|
accordions: editorialDividedAccordionSystem,
|
|
@@ -35753,7 +36313,7 @@ const curatedSiteStyles = [
|
|
|
35753
36313
|
compositionBudget: accentLedQuietBudget,
|
|
35754
36314
|
typography: folioTypography,
|
|
35755
36315
|
heroTypography: groundedSerifHeroTypography,
|
|
35756
|
-
looks: folioLooks,
|
|
36316
|
+
looks: withPriceLooks(withTeamLooks(folioLooks, folioRoles), folioRoles),
|
|
35757
36317
|
contentTemplateDefaults: { event: "event-header" },
|
|
35758
36318
|
themeOverrides: {
|
|
35759
36319
|
accordions: editorialDividedAccordionSystem,
|
|
@@ -35897,6 +36457,52 @@ curatedSiteStyles.forEach((style) => {
|
|
|
35897
36457
|
const recipes = new Set([...Object.values(style.footerLookRecipes ?? {}), ...style.recommendedFooterLookIds.map((id$2) => resolveFooterLookRecipe(style, id$2))]);
|
|
35898
36458
|
recipes.forEach((recipe) => validateFooterRecipeSurfaces(style, recipe));
|
|
35899
36459
|
});
|
|
36460
|
+
function withTeamLooks(looks, roleMap) {
|
|
36461
|
+
return {
|
|
36462
|
+
...looks,
|
|
36463
|
+
offers: [
|
|
36464
|
+
{
|
|
36465
|
+
id: id("team-members-tall-portraits"),
|
|
36466
|
+
treatment: "team-portraits",
|
|
36467
|
+
roleMap
|
|
36468
|
+
},
|
|
36469
|
+
{
|
|
36470
|
+
id: id("team-members-portrait-bio"),
|
|
36471
|
+
treatment: "team-bio",
|
|
36472
|
+
roleMap
|
|
36473
|
+
},
|
|
36474
|
+
{
|
|
36475
|
+
id: id("team-members-ruled-names"),
|
|
36476
|
+
treatment: "team-names",
|
|
36477
|
+
roleMap
|
|
36478
|
+
},
|
|
36479
|
+
...looks.offers
|
|
36480
|
+
]
|
|
36481
|
+
};
|
|
36482
|
+
}
|
|
36483
|
+
function withPriceLooks(looks, roleMap, featuredRoleMap = roleMap) {
|
|
36484
|
+
return {
|
|
36485
|
+
...looks,
|
|
36486
|
+
offers: [
|
|
36487
|
+
{
|
|
36488
|
+
id: id("shop-price-cards"),
|
|
36489
|
+
treatment: "shop-prices",
|
|
36490
|
+
roleMap
|
|
36491
|
+
},
|
|
36492
|
+
{
|
|
36493
|
+
id: id("shop-price-cards-featured"),
|
|
36494
|
+
treatment: "shop-prices-featured",
|
|
36495
|
+
roleMap: featuredRoleMap
|
|
36496
|
+
},
|
|
36497
|
+
{
|
|
36498
|
+
id: id("shop-ruled-prices"),
|
|
36499
|
+
treatment: "shop-price-list",
|
|
36500
|
+
roleMap
|
|
36501
|
+
},
|
|
36502
|
+
...looks.offers
|
|
36503
|
+
]
|
|
36504
|
+
};
|
|
36505
|
+
}
|
|
35900
36506
|
|
|
35901
36507
|
//#endregion
|
|
35902
36508
|
//#region ../theme-core/src/site-styles/pageDesignEditorCapabilities.ts
|
|
@@ -35986,8 +36592,10 @@ function arrangementManifestFromVariants(manifest) {
|
|
|
35986
36592
|
lookOnlyKeys: manifest.variantMeaning?.lookOnlyKeys
|
|
35987
36593
|
};
|
|
35988
36594
|
}
|
|
36595
|
+
/** A Look-only arrangement is never a default: a block whose only variants are Look-only keeps its plain layout. */
|
|
35989
36596
|
function manifestDefaultArrangement(manifest) {
|
|
35990
|
-
const
|
|
36597
|
+
const defaults = manifest.keys.filter((key$1) => !manifest.lookOnlyKeys?.includes(key$1));
|
|
36598
|
+
const key = manifest.defaultKey !== null && defaults.includes(manifest.defaultKey) ? manifest.defaultKey : defaults[0];
|
|
35991
36599
|
return key === undefined ? null : asLayoutVariantKey(key);
|
|
35992
36600
|
}
|
|
35993
36601
|
/** A declared secondary axis shares the arrangement rule, without rewriting content. */
|
|
@@ -36075,7 +36683,8 @@ function formatLayoutVariantLabel(variantKey) {
|
|
|
36075
36683
|
function editorLayoutManifest(block, first) {
|
|
36076
36684
|
return {
|
|
36077
36685
|
keys: block.layoutVariantKeys ?? block.designMetadata?.layoutProfiles.map((profile) => profile.variantKey) ?? [],
|
|
36078
|
-
defaultKey: block.defaultLayoutVariantKey ?? first?.id ?? null
|
|
36686
|
+
defaultKey: block.defaultLayoutVariantKey ?? first?.id ?? null,
|
|
36687
|
+
lookOnlyKeys: block.variantMeaning?.lookOnlyKeys
|
|
36079
36688
|
};
|
|
36080
36689
|
}
|
|
36081
36690
|
|
|
@@ -36378,62 +36987,51 @@ function layoutFamilyForEffectiveSelection(block) {
|
|
|
36378
36987
|
return block.availableLayouts.find((layout) => layout.id === effectiveLayout)?.profile.layoutFamily ?? null;
|
|
36379
36988
|
}
|
|
36380
36989
|
function planPageDesignLayoutLookCompatibility(block, layoutVariantKey) {
|
|
36381
|
-
|
|
36382
|
-
if (!layout) {
|
|
36990
|
+
if (!block.availableLayouts.some((option) => option.id === layoutVariantKey)) {
|
|
36383
36991
|
return {
|
|
36384
36992
|
kind: "layout-unavailable",
|
|
36385
36993
|
layoutVariantKey
|
|
36386
36994
|
};
|
|
36387
36995
|
}
|
|
36388
36996
|
const availableLooks = availableLooksForLayout(block.availableLooksByLayout, layoutVariantKey);
|
|
36389
|
-
const
|
|
36390
|
-
|
|
36391
|
-
kind: "
|
|
36392
|
-
|
|
36393
|
-
|
|
36394
|
-
|
|
36395
|
-
|
|
36396
|
-
|
|
36397
|
-
|
|
36398
|
-
|
|
36997
|
+
const autoLookId = block.availableLooksByLayout.find((entry) => entry.layoutVariantKey === layoutVariantKey)?.autoLookId ?? null;
|
|
36998
|
+
return {
|
|
36999
|
+
kind: "layout-supported",
|
|
37000
|
+
layout: {
|
|
37001
|
+
kind: "selected",
|
|
37002
|
+
value: layoutVariantKey,
|
|
37003
|
+
status: "supported",
|
|
37004
|
+
effectiveValue: layoutVariantKey
|
|
37005
|
+
},
|
|
37006
|
+
layoutChoice: userPinnedEditorChoice(layoutVariantKey),
|
|
37007
|
+
availableLooks,
|
|
37008
|
+
autoLookId,
|
|
37009
|
+
lookAvailability: block.lookAvailability.kind === "not-applicable" ? block.lookAvailability : availableLooks.length > 0 ? { kind: "available" } : {
|
|
37010
|
+
kind: "misconfigured",
|
|
37011
|
+
reason: "empty-look-catalog"
|
|
37012
|
+
},
|
|
37013
|
+
...compatibleLookIntent(block.look, availableLooks, autoLookId)
|
|
36399
37014
|
};
|
|
36400
|
-
|
|
37015
|
+
}
|
|
37016
|
+
/** Preserve an available pin; an incompatible pin returns to the layout's automatic Look. */
|
|
37017
|
+
function compatibleLookIntent(look, availableLooks, autoLookId) {
|
|
37018
|
+
if (look.kind === "auto") {
|
|
36401
37019
|
return {
|
|
36402
|
-
|
|
36403
|
-
layout: layoutSelection,
|
|
36404
|
-
availableLooks,
|
|
36405
|
-
autoLookId: defaultLookId,
|
|
36406
|
-
lookAvailability,
|
|
36407
|
-
look: autoEditorChoice(defaultLookId),
|
|
37020
|
+
look: autoEditorChoice(autoLookId),
|
|
36408
37021
|
lookIntentChange: { kind: "preserve-auto" }
|
|
36409
37022
|
};
|
|
36410
37023
|
}
|
|
36411
|
-
|
|
36412
|
-
|
|
36413
|
-
|
|
36414
|
-
|
|
36415
|
-
|
|
36416
|
-
|
|
36417
|
-
|
|
36418
|
-
|
|
36419
|
-
lookAvailability,
|
|
36420
|
-
look: userPinnedEditorChoice(pinnedLook.value),
|
|
36421
|
-
lookIntentChange: {
|
|
36422
|
-
kind: "preserve-supported-pin",
|
|
36423
|
-
appearancePresetId: pinnedLook.value
|
|
36424
|
-
}
|
|
36425
|
-
};
|
|
36426
|
-
}
|
|
36427
|
-
return {
|
|
36428
|
-
kind: "layout-supported",
|
|
36429
|
-
layout: layoutSelection,
|
|
36430
|
-
availableLooks,
|
|
36431
|
-
autoLookId: defaultLookId,
|
|
36432
|
-
lookAvailability,
|
|
36433
|
-
look: autoEditorChoice(defaultLookId),
|
|
37024
|
+
return availableLooks.some((option) => option.id === look.value) ? {
|
|
37025
|
+
look: userPinnedEditorChoice(look.value),
|
|
37026
|
+
lookIntentChange: {
|
|
37027
|
+
kind: "preserve-supported-pin",
|
|
37028
|
+
appearancePresetId: look.value
|
|
37029
|
+
}
|
|
37030
|
+
} : {
|
|
37031
|
+
look: autoEditorChoice(autoLookId),
|
|
36434
37032
|
lookIntentChange: {
|
|
36435
37033
|
kind: "reset-incompatible-pin",
|
|
36436
|
-
previousAppearancePresetId:
|
|
37034
|
+
previousAppearancePresetId: look.value
|
|
36437
37035
|
}
|
|
36438
37036
|
};
|
|
36439
37037
|
}
|
|
@@ -44017,6 +44615,15 @@ const siteBusinessAddressSchema = z.object({
|
|
|
44017
44615
|
lat: z.number().gte(-90).lte(90),
|
|
44018
44616
|
lng: z.number().gte(-180).lte(180)
|
|
44019
44617
|
}).strict();
|
|
44618
|
+
const openingHoursSchema = z.unknown().transform((value, ctx) => {
|
|
44619
|
+
const parsed = parseWeeklyOpeningHours(value);
|
|
44620
|
+
if (parsed.ok) return parsed.value;
|
|
44621
|
+
ctx.addIssue({
|
|
44622
|
+
code: "custom",
|
|
44623
|
+
message: parsed.error.message
|
|
44624
|
+
});
|
|
44625
|
+
return z.NEVER;
|
|
44626
|
+
});
|
|
44020
44627
|
/** Configures site-level metadata that must be available before content commands run. */
|
|
44021
44628
|
const configureSiteIdentityCommandSchema = z.object({
|
|
44022
44629
|
type: z.literal("configureSiteIdentity"),
|
|
@@ -44031,6 +44638,7 @@ const configureSiteIdentityCommandSchema = z.object({
|
|
|
44031
44638
|
"noindex_demo"
|
|
44032
44639
|
]).optional(),
|
|
44033
44640
|
contact: siteContactSchema.optional(),
|
|
44641
|
+
openingHours: openingHoursSchema.nullable().optional(),
|
|
44034
44642
|
businessAddress: siteBusinessAddressSchema.optional(),
|
|
44035
44643
|
privacyPolicy: z.literal("published").optional()
|
|
44036
44644
|
}).strict()
|
|
@@ -44619,6 +45227,7 @@ const seedPortalOrderCommandSchema = z.object({
|
|
|
44619
45227
|
}).strict().superRefine(validatePortalOrder)
|
|
44620
45228
|
}).strict();
|
|
44621
45229
|
const appointmentServiceCommonInputFields = {
|
|
45230
|
+
imageRef: resourceRefSchema("media").nullable().optional(),
|
|
44622
45231
|
title: z.string().trim().min(1),
|
|
44623
45232
|
description: z.string().nullable().optional(),
|
|
44624
45233
|
durationMinutes: z.number().int().min(5).max(24 * 60),
|
|
@@ -45046,6 +45655,7 @@ const upsertStaffMemberCommandSchema = z.object({
|
|
|
45046
45655
|
displayName: z.string().min(1),
|
|
45047
45656
|
roleLabel: z.string().optional(),
|
|
45048
45657
|
shortBio: z.string().optional(),
|
|
45658
|
+
avatarRef: mediaRefSchema.nullable().optional(),
|
|
45049
45659
|
timezone: z.string().min(1).optional(),
|
|
45050
45660
|
specialties: stringArraySchema.optional(),
|
|
45051
45661
|
publicVisibility: z.enum(["hidden", "visible"]).optional()
|
|
@@ -46174,10 +46784,13 @@ function bookingCommandRefContributions(command) {
|
|
|
46174
46784
|
case "seedBookingCustomer":
|
|
46175
46785
|
case "upsertAppointmentServiceCategory":
|
|
46176
46786
|
case "upsertBookableResource": return provided(command.ref);
|
|
46177
|
-
case "upsertAppointmentService": return providedWithRequirements(command.ref, command.input.categoryRef === undefined ? [] : [{
|
|
46787
|
+
case "upsertAppointmentService": return providedWithRequirements(command.ref, [...command.input.categoryRef === undefined ? [] : [{
|
|
46178
46788
|
ref: command.input.categoryRef,
|
|
46179
46789
|
field: "input.categoryRef"
|
|
46180
|
-
}]
|
|
46790
|
+
}], ...command.input.imageRef == null ? [] : [{
|
|
46791
|
+
ref: command.input.imageRef,
|
|
46792
|
+
field: "input.imageRef"
|
|
46793
|
+
}]]);
|
|
46181
46794
|
case "upsertBookingPassProduct": return {
|
|
46182
46795
|
...provided(command.ref),
|
|
46183
46796
|
requires: command.input.appointmentScope?.mode === "selected_services" ? command.input.appointmentScope.serviceRefs.map((ref, index) => ({
|
|
@@ -46303,6 +46916,7 @@ function commandRefContributions(command) {
|
|
|
46303
46916
|
if (isBookingRefCommand(command)) {
|
|
46304
46917
|
return bookingCommandRefContributions(command);
|
|
46305
46918
|
}
|
|
46919
|
+
if (isLifecycleRefCommand(command)) return lifecycleCommandRefContributions(command);
|
|
46306
46920
|
switch (command.type) {
|
|
46307
46921
|
case "configureSiteIdentity":
|
|
46308
46922
|
case "configureBookingSettings": return {
|
|
@@ -46320,7 +46934,6 @@ function commandRefContributions(command) {
|
|
|
46320
46934
|
case "upsertPage":
|
|
46321
46935
|
case "upsertForm":
|
|
46322
46936
|
case "upsertFooterContent":
|
|
46323
|
-
case "upsertStaffMember":
|
|
46324
46937
|
case "upsertVenue":
|
|
46325
46938
|
case "upsertEventCategory": return {
|
|
46326
46939
|
provides: [{
|
|
@@ -46329,6 +46942,7 @@ function commandRefContributions(command) {
|
|
|
46329
46942
|
}],
|
|
46330
46943
|
requires: []
|
|
46331
46944
|
};
|
|
46945
|
+
case "upsertStaffMember": return staffMemberCommandRefContributions(command);
|
|
46332
46946
|
case "upsertEventSeries": return {
|
|
46333
46947
|
provides: [{
|
|
46334
46948
|
ref: command.ref,
|
|
@@ -46430,29 +47044,6 @@ function commandRefContributions(command) {
|
|
|
46430
47044
|
}],
|
|
46431
47045
|
requires: collectNavigationRefs(command.input.items, "input.items")
|
|
46432
47046
|
};
|
|
46433
|
-
case "publishPage":
|
|
46434
|
-
case "unpublishPage": return {
|
|
46435
|
-
provides: [],
|
|
46436
|
-
requires: command.input.pageRef !== undefined ? [{
|
|
46437
|
-
ref: command.input.pageRef,
|
|
46438
|
-
field: "input.pageRef"
|
|
46439
|
-
}] : []
|
|
46440
|
-
};
|
|
46441
|
-
case "publishContentEntry": return {
|
|
46442
|
-
provides: [],
|
|
46443
|
-
requires: command.input.contentEntryRef !== undefined ? [{
|
|
46444
|
-
ref: command.input.contentEntryRef,
|
|
46445
|
-
field: "input.contentEntryRef"
|
|
46446
|
-
}] : []
|
|
46447
|
-
};
|
|
46448
|
-
case "unpublishContentEntry":
|
|
46449
|
-
case "deleteContentEntry": return {
|
|
46450
|
-
provides: [],
|
|
46451
|
-
requires: command.input.contentEntryRef !== undefined ? [{
|
|
46452
|
-
ref: command.input.contentEntryRef,
|
|
46453
|
-
field: "input.contentEntryRef"
|
|
46454
|
-
}] : []
|
|
46455
|
-
};
|
|
46456
47047
|
default: return assertNever(command);
|
|
46457
47048
|
}
|
|
46458
47049
|
}
|
|
@@ -46530,6 +47121,42 @@ function collectNestedRefs(value, path) {
|
|
|
46530
47121
|
if (!isRecord(value)) return [];
|
|
46531
47122
|
return Object.entries(value).flatMap(([key, child]) => collectNestedRefs(child, `${path}.${key}`));
|
|
46532
47123
|
}
|
|
47124
|
+
function staffMemberCommandRefContributions(command) {
|
|
47125
|
+
return {
|
|
47126
|
+
provides: [{
|
|
47127
|
+
ref: command.ref,
|
|
47128
|
+
field: "ref"
|
|
47129
|
+
}],
|
|
47130
|
+
requires: optionalRef(command.input.avatarRef ?? undefined, "input.avatarRef")
|
|
47131
|
+
};
|
|
47132
|
+
}
|
|
47133
|
+
const lifecycleRefCommandTypes = [
|
|
47134
|
+
"publishPage",
|
|
47135
|
+
"unpublishPage",
|
|
47136
|
+
"publishContentEntry",
|
|
47137
|
+
"unpublishContentEntry",
|
|
47138
|
+
"deleteContentEntry"
|
|
47139
|
+
];
|
|
47140
|
+
const lifecycleRefCommandTypeSet = new Set(lifecycleRefCommandTypes);
|
|
47141
|
+
function isLifecycleRefCommand(command) {
|
|
47142
|
+
return lifecycleRefCommandTypeSet.has(command.type);
|
|
47143
|
+
}
|
|
47144
|
+
function lifecycleCommandRefContributions(command) {
|
|
47145
|
+
switch (command.type) {
|
|
47146
|
+
case "publishPage":
|
|
47147
|
+
case "unpublishPage": return {
|
|
47148
|
+
provides: [],
|
|
47149
|
+
requires: optionalRef(command.input.pageRef, "input.pageRef")
|
|
47150
|
+
};
|
|
47151
|
+
case "publishContentEntry":
|
|
47152
|
+
case "unpublishContentEntry":
|
|
47153
|
+
case "deleteContentEntry": return {
|
|
47154
|
+
provides: [],
|
|
47155
|
+
requires: optionalRef(command.input.contentEntryRef, "input.contentEntryRef")
|
|
47156
|
+
};
|
|
47157
|
+
default: return assertNever(command);
|
|
47158
|
+
}
|
|
47159
|
+
}
|
|
46533
47160
|
|
|
46534
47161
|
//#endregion
|
|
46535
47162
|
//#region ../site-commands/src/staticExecutionGaps.ts
|
|
@@ -47235,6 +47862,16 @@ function venueManagementFields(command) {
|
|
|
47235
47862
|
};
|
|
47236
47863
|
}
|
|
47237
47864
|
|
|
47865
|
+
//#endregion
|
|
47866
|
+
//#region ../site-commands/src/pageSeo.ts
|
|
47867
|
+
/** Effective metadata written by a page upsert, shared with CLI previews. */
|
|
47868
|
+
function resolvePageUpsertSeo(input) {
|
|
47869
|
+
return {
|
|
47870
|
+
seoTitle: input.seoTitle ?? input.title,
|
|
47871
|
+
seoDescription: input.seoDescription ?? null
|
|
47872
|
+
};
|
|
47873
|
+
}
|
|
47874
|
+
|
|
47238
47875
|
//#endregion
|
|
47239
47876
|
//#region ../api/src/event-visibility.ts
|
|
47240
47877
|
const EVENT_VISIBILITY_VALUES = ["public", "unlisted"];
|
|
@@ -47842,4 +48479,4 @@ function parseSdkEventRunUpsertInput(input, runIndex, options) {
|
|
|
47842
48479
|
}
|
|
47843
48480
|
|
|
47844
48481
|
//#endregion
|
|
47845
|
-
export {
|
|
48482
|
+
export { createFormRef as $, managementMediaLibraryUploadLimitForMimeType as $n, parseThemeColorToken as $r, pageDesignIntentSchemaVersion as $t, getSiteCommandMetadata as A, mediaPosterSchema as An, surfaceDecorationColors as Ar, BREAKPOINT_MD as At, eventBookingOfferIntentSchema as B, parseMediaIdentifier as Bn, resolveOnColorForThemeToken as Br, themeButtonExtraClassesWithTrailingIcon as Bt, sortRecord as C, isExplicitRectCrop as Cn, makeBoundaryId as Cr, deriveSiteStyleBlockPolicy as Ct, mapEventCommandContent as D, getDirectImageUrlForSiteScopedPath as Dn, toNonEmptyReadonlyArray as Dr, getHeaderPaintTargets as Dt, parseAndPlanCommandBatchForTypes as E, getDirectImageUrlForRelativePath as En, tileTreatmentValues as Er, generateMobileOverlayBackdropFilterFix as Et, pageIdentifierForBlockCommand as F, resolveManagedMediaReference as Fn, mergeStyles as Fr, getComponentBorderWidthPx as Ft, ianaTimezoneSchema as G, getExtensionForMimeType as Gn, surfaceToneFromForegroundToken as Gr, footerForegroundCandidates as Gt, bookingPaymentTermsSchema as H, slugifyMediaIdentifier as Hn, resolveTokenOrCssColorValue as Hr, themeButtonVariantClassNames as Ht, pageIdentifierForCommand as I, mediaTypeDiscriminants as In, rgbColorValue as Ir, getComponentShadowVar as It, createCommandRef as J, normalizeAmbiguousStoragePathForSite as Jn, surfaceForegroundInputFromResolved as Jr, arrangementLookHooks as Jt, createBlockRef as K, getMimeType as Kn, defaultThemeTokens as Kr, buildTextContrastShadow as Kt, pagePathForCommand as L, mediaIdentifierSchema as Ln, textColorStyle as Lr, ICON_CONFIG as Lt, blockIdentifierForCommand as M, persistableMediaSchema as Mn, TokenResolver as Mr, BREAKPOINT_XL as Mt, blockOrderIdentifiersForCommand as N, runtimeMediaSchema as Nn, backgroundColorStyle as Nr, MQ_MD_DOWN as Nt, evaluateSiteCommandBatchExposure as O, getImageUrl as On, visibleHeadingDecorationFamilyValues as Or, renderHeaderPaintTargetRules as Ot, entryIdentifierForCommand as P, buildRenderableMediaAssetIndex as Pn, borderColorStyle as Pr, headerVariantValues as Pt, createFooterRef as Q, classifyKnownMimeType as Qn, getTextColorForBackground as Qr, pageDesignBoundaryTreatmentSchema as Qt, hasConfiguredBookingVertical as R, buildMediaIdentifierFromFilename as Rn, opaqueSurfaceDeclarations as Rr, generateDefaultButtonSystem as Rt, venueManagementFields as S, normalizeWidthCandidates as Sn, introCompositionTreatmentValues as Sr, parseGradientPresetId as St, createDryRunReport as T, resolveMediaTransformForAspect as Tn, testimonialsCompositionTreatmentValues as Tr, generateHeaderScrollTreatmentStyles as Tt, require_jsx_runtime as U, deriveVideoSlotPolicy as Un, PUBLIC_BUTTON_ROLES as Ur, parseThemeForPersistence as Ut, bookingPaymentCollectionOptionSchema as V, resolveMediaIdentifier as Vn, resolveThemeColorReferenceValue as Vr, themeButtonSizeClassName as Vt, require_react as W, resolveVideoSelectionIntentForMediaField as Wn, selectLogoVariant as Wr, buttonStyleSelectionSchema as Wt, createEventCategoryRef as X, FILE_SIZE_LIMITS as Xn, surfaceForegroundValue as Xr, resolveItemSurface as Xt, createContentEntryRef as Y, parseRelativeStoragePath as Yn, surfaceForegroundStyle as Yr, arrangementSlotNames as Yt, createEventSeriesRef as Z, MAX_MANAGEMENT_MEDIA_UPLOAD_BYTES as Zn, expandPalette as Zr, resolveLookSlotSurfaces as Zt, normalizeLinkValue as _, summarizePortableMediaReferences as _n, defineNoBlockDesignCapability as _r, resolvePublishedLook as _t, classifySdkEventSchedule as a, deriveSectionGround as an, defineBlockDesignMetadata as ar, slugPart as at, isEventVisibility as b, looksLikeUuid as bn, featureCardCompositionTreatmentValues as br, gradientToCss as bt, customLinkSchema as c, resolveSectionBackground as cn, cardListKnobBlocks as cr, headerLeafTextColor as ct, internalLinkSchema as d, boxBackgroundOverlaySchema as dn, asLayoutVariantKey as dr, mergeHeaderNavTypographyPreference as dt, parseBlockColorToken as ei, footerPreferencesSchema as en, parseSafeDownloadFilename as er, createNavigationRef as et, internalResolvedLinkSchema as f, boxBackgroundSchema as fn, asPageFlowPresetId as fr, readHeaderNavFontSizePreference as ft, linkSchema as g, collectPortableMediaReferencesFromContent as gn, defineFrameCapability as gr, resolveModeArrangement as gt, isResolvedInternalLinkEntityType as h, stripStaleTransitionStyleGroup as hn, defineBlockDesignCapability as hr, resolveEffectiveArrangement as ht, sdkEventUpsertOptionalFieldSchemas as i, sectionFactsForContent as in, normalizeCardRole as ir, refSlug as it, eventManagementTiming as j, mediaSchema as jn, resolveSurfaceForeground as jr, BREAKPOINT_SM as jt, evaluateSiteCommandExposure as k, isSiteScopedDirectImageStoragePath as kn, resolveSurface as kr, BREAKPOINT_LG as kt, entryLinkSchema as l, resolveSectionPhotoPlacement as ln, asAppearancePresetId as lr, transparentHeaderForegroundInput as lt, isInternalResolvedLinkValue as m, siteChromeBackgroundOverrideOwner as mn, assertNever$1 as mr, readStoredMode as mt, sdkCourseBookingSettingsSchema as n, __toESM as ni, boundaryLayout as nn, cardRoleSchema as nr, createSiteCommandSiteRef as nt, classifySdkEventBookingOffer as o, heroPhotoPaintsGround as on, resolveEffectiveKnobs as or, effectiveHeaderNavLinkStyle as ot, internalRouteOnlyLinkSchema as p, runtimeBoxBackgroundSchema as pn, asSiteStyleId as pr, arrangementManifestFromVariants as pt, createBlocksRef as q, asRecord as qn, surfaceForegroundDeclarations as qr, generateNavLinkCSS as qt, sdkEventOccurrenceInputSchema as r, composeBoundary as rn, cardVariantRoleValues as rr, createVenueRef as rt, RESOLVED_INTERNAL_LINK_ENTITY_TYPES as s, parseCanonicalRuntimeBackground as sn, cardListFamilyBlocks as sr, headerForegroundCandidates as st, classifySdkEventTiming as t, __commonJSMin as ti, headerRootPaint as tn, renderCssDeclarations as tr, createPageRef as tt, externalLinkSchema as u, sectionForegroundBackground as un, asDesignBlockId as ur, readOpeningForegroundProjection as ut, pageLinkSchema as v, walkAndCollectImageAttrs as vn, eventListTreatmentValues as vr, requireCuratedSiteStyle as vt, stableStringify as w, parseAspectRatioValue as wn, offeringsPreviewCompositionTreatmentValues as wr, themeSchema as wt, resolvePageUpsertSeo as x, rotateNormalizedPoint as xn, headingDecorationColorTokenValues as xr, getGradientPreset as xt, eventVisibilitySchema as y, deleteEnvSpecificKeys as yn, eyebrowTreatmentValues as yr, compiledRuntimeStyleFieldNames as yt, eventCommandScheduleSchema as z, parseCanonicalMediaIdentifier as zn, isCssColorLiteral as zr, parseThemeButtonVariantId as zt };
|