@riverbankcms/sdk 0.76.0 → 0.77.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (144) hide show
  1. package/dist/{PreviewEditorSidebar-X2HWXFOL.mjs → PreviewEditorSidebar-XSX7QKHQ.mjs} +1019 -442
  2. package/dist/{PreviewEditorUI-AQXIXPOH.mjs → PreviewEditorUI-YZNEZ3QD.mjs} +2 -2
  3. package/dist/SdkPreviewModeRuntime-5FS5E6BI.mjs +8 -0
  4. package/dist/_dts/ai/src/contracts/proposals.d.ts +528 -20
  5. package/dist/_dts/api/src/contentRuntime.d.ts +5 -0
  6. package/dist/_dts/api/src/siteAssets.d.ts +1 -0
  7. package/dist/_dts/api/src/siteRuntimeEndpoints.d.ts +26 -2
  8. package/dist/_dts/block-form/src/blockDraftSaveability.d.ts +28 -0
  9. package/dist/_dts/block-form/src/client/index.d.ts +2 -2
  10. package/dist/_dts/block-form/src/index.d.ts +2 -1
  11. package/dist/_dts/block-form/src/widgets/DateField/dateFieldSchema.d.ts +1 -1
  12. package/dist/_dts/block-form/src/widgets/DateTimeField/dateTimeFieldSchema.d.ts +1 -1
  13. package/dist/_dts/block-form/src/widgets/TimeField/timeFieldSchema.d.ts +1 -1
  14. package/dist/_dts/blocks/src/PageRenderer.d.ts +10 -10
  15. package/dist/_dts/blocks/src/client/site-chrome.d.ts +22 -0
  16. package/dist/_dts/blocks/src/customBlockRegistry.d.ts +38 -0
  17. package/dist/_dts/blocks/src/index.d.ts +2 -0
  18. package/dist/_dts/blocks/src/system/blocks/faq.d.ts +20 -2
  19. package/dist/_dts/blocks/src/system/blocks/feature-cards.d.ts +25 -0
  20. package/dist/_dts/blocks/src/system/blocks/index.d.ts +2 -0
  21. package/dist/_dts/blocks/src/system/blocks/intro.d.ts +24 -0
  22. package/dist/_dts/blocks/src/system/blocks/media-text.d.ts +3 -34
  23. package/dist/_dts/blocks/src/system/constants/blockKinds.d.ts +1 -1
  24. package/dist/_dts/blocks/src/system/fields/aspectRatio.d.ts +30 -0
  25. package/dist/_dts/blocks/src/system/fields/boxStyles.d.ts +4 -1
  26. package/dist/_dts/blocks/src/system/fields/ctas.d.ts +7 -0
  27. package/dist/_dts/blocks/src/system/manifest/fieldValidation/index.d.ts +11 -2
  28. package/dist/_dts/blocks/src/system/node/validation-constants.d.ts +1 -1
  29. package/dist/_dts/blocks/src/system/runtime/nodes/accordion.d.ts +2 -0
  30. package/dist/_dts/blocks/src/system/runtime/nodes/accordion.server.d.ts +2 -0
  31. package/dist/_dts/blocks/src/system/runtime/nodes/accordionIconTreatment.d.ts +5 -0
  32. package/dist/_dts/blocks/src/system/transforms/registry/layout.d.ts +1 -0
  33. package/dist/_dts/blocks/src/system/transforms/typed.d.ts +2 -1
  34. package/dist/_dts/content-editor/src/controller/EntryControllerProvider.d.ts +2 -0
  35. package/dist/_dts/content-editor/src/hooks/blockDraftLifecycle.d.ts +48 -0
  36. package/dist/_dts/content-editor/src/hooks/invalidBlockSelectors.d.ts +4 -0
  37. package/dist/_dts/content-editor/src/hooks/publishability.d.ts +47 -0
  38. package/dist/_dts/content-editor/src/index.d.ts +1 -0
  39. package/dist/_dts/db/src/generated/supabase/database.types.d.ts +20 -0
  40. package/dist/_dts/editor-blocks/src/BlockEditor.d.ts +2 -1
  41. package/dist/_dts/editor-blocks/src/block-editor/SortableBlockItem.d.ts +2 -1
  42. package/dist/_dts/editor-blocks/src/block-editor/customBlockRegistry.d.ts +2 -0
  43. package/dist/_dts/editor-blocks/src/block-editor/sdkBlockMerger.d.ts +9 -37
  44. package/dist/_dts/editor-blocks/src/index.d.ts +2 -2
  45. package/dist/_dts/preview-next/src/client/index.d.ts +3 -0
  46. package/dist/_dts/preview-next/src/client/layout/PreviewLayoutContext.d.ts +5 -1
  47. package/dist/_dts/preview-next/src/client/preview/PreviewDesignCoordinatorContext.d.ts +20 -0
  48. package/dist/_dts/preview-next/src/client/preview/PreviewEditorSidebar.d.ts +7 -2
  49. package/dist/_dts/preview-next/src/client/preview/PreviewShell.d.ts +7 -2
  50. package/dist/_dts/preview-next/src/client/preview/PreviewShellLayout.d.ts +7 -2
  51. package/dist/_dts/preview-next/src/client/preview/PreviewThemedSiteDocument.d.ts +18 -0
  52. package/dist/_dts/preview-next/src/client/preview/SiteChromeCustomizeContext.d.ts +20 -3
  53. package/dist/_dts/preview-next/src/client/preview/StyleConfigurator.d.ts +6 -1
  54. package/dist/_dts/preview-next/src/client/preview/StyleConfigurator.state.d.ts +14 -4
  55. package/dist/_dts/preview-next/src/client/preview/previewDesignCoordinator.d.ts +73 -0
  56. package/dist/_dts/preview-next/src/client/preview/siteChromeLookRows.d.ts +12 -4
  57. package/dist/_dts/preview-next/src/client/preview/siteStylePreviewPlanner.d.ts +46 -0
  58. package/dist/_dts/preview-next/src/client/preview/styleConfiguratorSnapshot.d.ts +6 -1
  59. package/dist/_dts/preview-next/src/client/preview/typographySelectionInput.d.ts +14 -0
  60. package/dist/_dts/preview-next/src/client/sdk/SdkPreviewModeRuntime.d.ts +1 -1
  61. package/dist/_dts/sdk/src/cli/commands/style.d.ts +8 -0
  62. package/dist/_dts/sdk/src/client/management/types.d.ts +6 -1
  63. package/dist/_dts/sdk/src/client/types.d.ts +9 -0
  64. package/dist/_dts/sdk/src/client.d.ts +1 -1
  65. package/dist/_dts/sdk/src/contracts/system-block-content.d.ts +35 -0
  66. package/dist/_dts/sdk/src/index.d.ts +2 -1
  67. package/dist/_dts/sdk/src/public-api/contracts.d.ts +5 -0
  68. package/dist/_dts/sdk/src/types/block-kinds.d.ts +1 -1
  69. package/dist/_dts/sdk/src/version.d.ts +1 -1
  70. package/dist/_dts/site-commands/src/commands.d.ts +15 -0
  71. package/dist/_dts/theme-core/src/buttons/personalities/earth-pill.d.ts +16 -0
  72. package/dist/_dts/theme-core/src/buttons/personalities/index.d.ts +11 -0
  73. package/dist/_dts/theme-core/src/fonts/types.d.ts +1 -1
  74. package/dist/_dts/theme-core/src/mock-themes/all.d.ts +45 -0
  75. package/dist/_dts/theme-core/src/palette/variants/index.d.ts +15 -0
  76. package/dist/_dts/theme-core/src/palette/variants/warm-neutral.d.ts +16 -0
  77. package/dist/_dts/theme-core/src/schema.d.ts +280 -0
  78. package/dist/_dts/theme-core/src/site-styles/appearancePresetCatalog.d.ts +81 -0
  79. package/dist/_dts/theme-core/src/site-styles/appearancePresetTypes.d.ts +6 -4
  80. package/dist/_dts/theme-core/src/site-styles/blockAppearancePresets.d.ts +81 -0
  81. package/dist/_dts/theme-core/src/site-styles/curatedSiteStyles.d.ts +118 -2
  82. package/dist/_dts/theme-core/src/site-styles/footerLooks.d.ts +13 -0
  83. package/dist/_dts/theme-core/src/site-styles/generatedSchemas.d.ts +4 -2
  84. package/dist/_dts/theme-core/src/site-styles/headerLooks.d.ts +364 -5
  85. package/dist/_dts/theme-core/src/site-styles/headerOpeningSection.d.ts +6 -0
  86. package/dist/_dts/theme-core/src/site-styles/index.d.ts +2 -0
  87. package/dist/_dts/theme-core/src/site-styles/persistedIdParseResult.d.ts +9 -0
  88. package/dist/_dts/theme-core/src/site-styles/previewCompiler.d.ts +20 -4
  89. package/dist/_dts/theme-core/src/site-styles/types.d.ts +74 -2
  90. package/dist/_dts/theme-core/src/site-styles/typographyPresets.d.ts +189 -0
  91. package/dist/{chunk-Z7JLNTJR.mjs → chunk-6SMUFTXD.mjs} +2 -1
  92. package/dist/{chunk-V5VORNEJ.mjs → chunk-ANKDYZ2E.mjs} +1 -1
  93. package/dist/{chunk-Q4OLG66B.mjs → chunk-EAWHBECW.mjs} +476 -153
  94. package/dist/{chunk-TW2Y4RR5.mjs → chunk-GSQX43EZ.mjs} +383 -51
  95. package/dist/{chunk-LYI7TEMH.mjs → chunk-WLQBJN2Z.mjs} +3096 -354
  96. package/dist/cli/index.mjs +2023 -181
  97. package/dist/client/{accordion-2YHIBOZH.mjs → accordion-RZMQSYLR.mjs} +1 -1
  98. package/dist/client/{bookingForm-35IBDWAS.mjs → bookingForm-NF4ASVNV.mjs} +2 -2
  99. package/dist/client/bookings.mjs +92 -0
  100. package/dist/client/{carousel-K6XG7NZQ.mjs → carousel-LDX47ZIK.mjs} +1 -1
  101. package/dist/client/{cart-HCFYUTTU.mjs → cart-RGXDS5F4.mjs} +3 -3
  102. package/dist/client/{checkout-J3U4XR7K.mjs → checkout-P7WWSNNY.mjs} +3 -3
  103. package/dist/client/{chunk-BOIHIU7E.mjs → chunk-E2TDNXCL.mjs} +1 -1
  104. package/dist/client/{chunk-PFBX3IQL.mjs → chunk-GMVTOKYG.mjs} +2 -2
  105. package/dist/client/{chunk-FGUIVT2B.mjs → chunk-JNC7CGHX.mjs} +1 -1
  106. package/dist/client/{chunk-SNSWVZEP.mjs → chunk-L3DNHIJX.mjs} +3 -3
  107. package/dist/client/{chunk-7UOSCYY4.mjs → chunk-R56FQ3RR.mjs} +92 -0
  108. package/dist/client/{chunk-J227A3CQ.mjs → chunk-UFSWADAO.mjs} +1 -1
  109. package/dist/client/client.mjs +2134 -228
  110. package/dist/client/{courseRegistration-ZBXS7VGI.mjs → courseRegistration-7F65K5ZR.mjs} +2 -2
  111. package/dist/client/{eventCalendar-EQQZHJBA.mjs → eventCalendar-GLSC5KTL.mjs} +4 -4
  112. package/dist/client/{eventCombined-JCFTGBFQ.mjs → eventCombined-ZHK4WKUR.mjs} +4 -4
  113. package/dist/client/{eventDetails-HLUTQSYY.mjs → eventDetails-E3PJYBIN.mjs} +4 -4
  114. package/dist/client/{eventListing-FG4MICVB.mjs → eventListing-EMS3WC3E.mjs} +4 -4
  115. package/dist/client/{eventRegistration-GUEB7LBT.mjs → eventRegistration-NZOTVNPI.mjs} +4 -4
  116. package/dist/client/{form-YQEW4YIT.mjs → form-ETFZFATW.mjs} +1 -1
  117. package/dist/client/{headerSection-GTR3TTRM.mjs → headerSection-4LBP7ULT.mjs} +2 -2
  118. package/dist/client/hooks.mjs +1918 -293
  119. package/dist/client/{locationMap-SPC7VGUH.mjs → locationMap-5M655YSJ.mjs} +1 -1
  120. package/dist/client/{newsletterForm-4IW5BLID.mjs → newsletterForm-QOUYW44O.mjs} +1 -1
  121. package/dist/client/{productDetail-KP5H2WJO.mjs → productDetail-O4DOCWQG.mjs} +3 -3
  122. package/dist/client/{productList-3M3M72XZ.mjs → productList-A5RO5WIS.mjs} +3 -3
  123. package/dist/client/rendering/client.mjs +198 -32
  124. package/dist/client/rendering/islands.mjs +18 -18
  125. package/dist/client/rendering.mjs +2095 -208
  126. package/dist/client/{shop-ACQKVGOM.mjs → shop-L4MZH4I2.mjs} +3 -3
  127. package/dist/preview-next/client/runtime.mjs +4 -4
  128. package/dist/{sdk-runtime-K7HNB4U2.mjs → sdk-runtime-Q6MTR4KL.mjs} +5 -5
  129. package/dist/server/components.mjs +2046 -204
  130. package/dist/server/config-validation.mjs +1921 -293
  131. package/dist/server/config.mjs +1921 -293
  132. package/dist/server/data.mjs +1918 -293
  133. package/dist/server/index.mjs +31 -2
  134. package/dist/server/next.mjs +2067 -206
  135. package/dist/server/page-converter.mjs +1894 -281
  136. package/dist/server/prebuild.mjs +1 -1
  137. package/dist/server/rendering/server.mjs +2046 -204
  138. package/dist/server/rendering.mjs +2046 -204
  139. package/dist/server/routing.mjs +1963 -275
  140. package/dist/server/server.mjs +1932 -288
  141. package/dist/server/theme-bridge.mjs +158 -1
  142. package/dist/server/theme.mjs +158 -1
  143. package/package.json +1 -1
  144. package/dist/SdkPreviewModeRuntime-ZQNDCASH.mjs +0 -8
@@ -30402,6 +30402,9 @@ z.object({
30402
30402
  var TEL_RE = /^[+()0-9\s-]{3,}$/;
30403
30403
  var SLUG_PATTERN = /^(?:[a-z0-9]+(?:-[a-z0-9]+)*)(?:\/(?:[a-z0-9]+(?:-[a-z0-9]+)*))*$/;
30404
30404
  var ALLOWED_URL_PROTOCOLS = ["http:", "https:"];
30405
+ var DATE_PATTERN = /^(?<year>[1-9]\d{3})-(?<month>\d{2})-(?<day>\d{2})$/;
30406
+ var TIME_PATTERN = /^(?<hours>[01]\d|2[0-3]):(?<minutes>[0-5]\d)$/;
30407
+ var DATETIME_PATTERN = /^(?<date>[1-9]\d{3}-\d{2}-\d{2})T(?<time>(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d)(?:\.\d+)?(?<offset>Z|[+-](?:[01]\d|2[0-3]):[0-5]\d)$/;
30405
30408
  function assertNever4(value) {
30406
30409
  throw new Error(`Unhandled field validation variant: ${JSON.stringify(value)}`);
30407
30410
  }
@@ -30434,6 +30437,12 @@ function fieldIssueToMessage(issue2) {
30434
30437
  return "Check the format and try again";
30435
30438
  case "invalidUrl":
30436
30439
  return "Enter a valid web address";
30440
+ case "invalidDate":
30441
+ return "Choose a valid date";
30442
+ case "invalidTime":
30443
+ return "Choose a valid time";
30444
+ case "invalidDateTime":
30445
+ return "Choose a valid date and time";
30437
30446
  case "invalidNumber":
30438
30447
  return `${issue2.label} needs a number`;
30439
30448
  case "tooSmall":
@@ -30470,12 +30479,16 @@ function deriveFieldValidationPlan(field, path = [field.id]) {
30470
30479
  case "text": {
30471
30480
  const inputType = field.ui?.inputType;
30472
30481
  if (inputType === "number") {
30473
- const constraints2 = commonConstraints(required, { kind: "numberType" });
30482
+ const constraints2 = commonConstraints(required, {
30483
+ kind: "numberType"
30484
+ });
30474
30485
  if (typeof field.ui?.min === "number") constraints2.push({ kind: "numberMin", minimum: field.ui.min });
30475
30486
  if (typeof field.ui?.max === "number") constraints2.push({ kind: "numberMax", maximum: field.ui.max });
30476
30487
  return makePlan("number", "number", field, path, required, constraints2);
30477
30488
  }
30478
- const constraints = commonConstraints(required, { kind: "textType" });
30489
+ const constraints = commonConstraints(required, {
30490
+ kind: "textType"
30491
+ });
30479
30492
  if (inputType === "email") constraints.push({ kind: "emailFormat" });
30480
30493
  if (inputType === "tel") constraints.push({ kind: "phoneFormat" });
30481
30494
  if (field.ui?.pattern) constraints.push({ kind: "patternFormat", pattern: field.ui.pattern });
@@ -30483,7 +30496,9 @@ function deriveFieldValidationPlan(field, path = [field.id]) {
30483
30496
  return makePlan("string", "string", field, path, required, constraints);
30484
30497
  }
30485
30498
  case "number": {
30486
- const constraints = commonConstraints(required, { kind: "numberType" });
30499
+ const constraints = commonConstraints(required, {
30500
+ kind: "numberType"
30501
+ });
30487
30502
  if (typeof field.min === "number") constraints.push({ kind: "numberMin", minimum: field.min });
30488
30503
  if (typeof field.max === "number") constraints.push({ kind: "numberMax", maximum: field.max });
30489
30504
  return makePlan("number", "number", field, path, required, constraints);
@@ -30494,23 +30509,42 @@ function deriveFieldValidationPlan(field, path = [field.id]) {
30494
30509
  return makePlan("string", "string", field, path, required, constraints);
30495
30510
  }
30496
30511
  case "url":
30497
- return makePlan("string", "string", field, path, required, commonConstraints(
30512
+ return makePlan(
30513
+ "string",
30514
+ "string",
30515
+ field,
30516
+ path,
30498
30517
  required,
30499
- { kind: "textType" },
30500
- { kind: "urlFormat", allowRelative: Boolean(field.allowRelative) }
30501
- ));
30518
+ commonConstraints(required, { kind: "textType" }, { kind: "urlFormat", allowRelative: Boolean(field.allowRelative) })
30519
+ );
30502
30520
  case "reference":
30503
30521
  return makePlan("string", "string", field, path, required, commonConstraints(required, { kind: "referenceText" }));
30504
30522
  case "date":
30523
+ return makePlan("string", "string", field, path, required, commonConstraints(required, { kind: "textType" }, { kind: "dateFormat" }));
30505
30524
  case "time":
30525
+ return makePlan("string", "string", field, path, required, commonConstraints(required, { kind: "textType" }, { kind: "timeFormat" }));
30506
30526
  case "datetime":
30507
- return makePlan("string", "string", field, path, required, commonConstraints(required, { kind: "textType" }));
30527
+ return makePlan(
30528
+ "string",
30529
+ "string",
30530
+ field,
30531
+ path,
30532
+ required,
30533
+ commonConstraints(required, { kind: "textType" }, { kind: "datetimeFormat" })
30534
+ );
30508
30535
  case "select":
30509
- return makePlan("select", "select", field, path, required, commonConstraints(required, {
30510
- kind: "selectOption",
30511
- source: resolveSelectConstraintSource(field),
30512
- multiple: Boolean(field.multiple)
30513
- }));
30536
+ return makePlan(
30537
+ "select",
30538
+ "select",
30539
+ field,
30540
+ path,
30541
+ required,
30542
+ commonConstraints(required, {
30543
+ kind: "selectOption",
30544
+ source: resolveSelectConstraintSource(field),
30545
+ multiple: Boolean(field.multiple)
30546
+ })
30547
+ );
30514
30548
  case "richText":
30515
30549
  return makePlan("richText", "object", field, path, required, commonConstraints(required, { kind: "richTextDoc" }));
30516
30550
  case "media":
@@ -30523,7 +30557,11 @@ function deriveFieldValidationPlan(field, path = [field.id]) {
30523
30557
  case "repeater":
30524
30558
  return {
30525
30559
  ...makePlan("repeater", "array", field, path, required, commonConstraints(required, { kind: "arrayType" })),
30526
- ...field.polymorphic && field.itemTypes ? { repeatedItemVariants: deriveRepeatedItemVariants(field, [...path, 0]) } : { repeatedItemPlan: deriveNestedFieldPlans(getRepeaterFields(field), [...path, 0]) },
30560
+ ...field.polymorphic && field.itemTypes ? {
30561
+ repeatedItemVariants: deriveRepeatedItemVariants(field, [...path, 0])
30562
+ } : {
30563
+ repeatedItemPlan: deriveNestedFieldPlans(getRepeaterFields(field), [...path, 0])
30564
+ },
30527
30565
  constraints: withRepeaterItemConstraints(field, commonConstraints(required, { kind: "arrayType" }))
30528
30566
  };
30529
30567
  case "group":
@@ -30608,7 +30646,10 @@ function resolveSelectConstraintSource(field) {
30608
30646
  const source = normalizeSelectSource(field);
30609
30647
  switch (source.kind) {
30610
30648
  case "static":
30611
- return { kind: "static", values: field.options.map((option) => option.value) };
30649
+ return {
30650
+ kind: "static",
30651
+ values: field.options.map((option) => option.value)
30652
+ };
30612
30653
  case "site":
30613
30654
  case "sdk":
30614
30655
  return { kind: "runtime", source: source.kind };
@@ -30704,7 +30745,9 @@ function normalizeFieldValue(plan, value, ctx) {
30704
30745
  }
30705
30746
  function normalizeObjectChildren(children, value, ctx) {
30706
30747
  if (!value || typeof value !== "object" || Array.isArray(value)) return value;
30707
- const normalized = { ...value };
30748
+ const normalized = {
30749
+ ...value
30750
+ };
30708
30751
  for (const child of children) {
30709
30752
  normalized[child.fieldId] = normalizeFieldValue(child, normalized[child.fieldId], ctx);
30710
30753
  }
@@ -30798,6 +30841,12 @@ function validateStringConstraint(plan, constraint, value) {
30798
30841
  }
30799
30842
  case "urlFormat":
30800
30843
  return isValidUrl(value, constraint.allowRelative) ? [] : [issue(plan, "invalidUrl")];
30844
+ case "dateFormat":
30845
+ return isValidDateString(value) ? [] : [issue(plan, "invalidDate")];
30846
+ case "timeFormat":
30847
+ return isValidTimeString(value) ? [] : [issue(plan, "invalidTime")];
30848
+ case "datetimeFormat":
30849
+ return isValidDateTimeInstantString(value) ? [] : [issue(plan, "invalidDateTime")];
30801
30850
  case "slugFormat":
30802
30851
  return SLUG_PATTERN.test(value) ? [] : [issue(plan, "invalidSlug")];
30803
30852
  default:
@@ -30834,17 +30883,24 @@ function validateRepeaterPlan(plan, value, ctx) {
30834
30883
  case "arrayType":
30835
30884
  return [];
30836
30885
  case "minItems":
30837
- return value.length < constraint.minimum ? [issue(plan, "tooFewItems", { minimum: constraint.minimum, itemLabel: "item" })] : [];
30886
+ return value.length < constraint.minimum ? [
30887
+ issue(plan, "tooFewItems", {
30888
+ minimum: constraint.minimum,
30889
+ itemLabel: "item"
30890
+ })
30891
+ ] : [];
30838
30892
  case "maxItems":
30839
- return value.length > constraint.maximum ? [issue(plan, "tooManyItems", { maximum: constraint.maximum, itemLabel: "item" })] : [];
30893
+ return value.length > constraint.maximum ? [
30894
+ issue(plan, "tooManyItems", {
30895
+ maximum: constraint.maximum,
30896
+ itemLabel: "item"
30897
+ })
30898
+ ] : [];
30840
30899
  default:
30841
30900
  return assertNever4(constraint);
30842
30901
  }
30843
30902
  });
30844
- return [
30845
- ...constraintIssues,
30846
- ...value.flatMap((item, index2) => validateRepeaterItem(plan, item, index2, ctx))
30847
- ];
30903
+ return [...constraintIssues, ...value.flatMap((item, index2) => validateRepeaterItem(plan, item, index2, ctx))];
30848
30904
  }
30849
30905
  function validateRepeaterItem(plan, item, index2, ctx) {
30850
30906
  if (!isPlainObject(item)) return [];
@@ -30887,9 +30943,7 @@ function rebaseFieldPlanPath(plan, fromPrefix, toPrefix) {
30887
30943
  }))
30888
30944
  } : {},
30889
30945
  ...plan.repeatedItemPlan ? {
30890
- repeatedItemPlan: plan.repeatedItemPlan.map(
30891
- (fieldPlan) => rebaseFieldPlanPath(fieldPlan, fromPrefix, toPrefix)
30892
- )
30946
+ repeatedItemPlan: plan.repeatedItemPlan.map((fieldPlan) => rebaseFieldPlanPath(fieldPlan, fromPrefix, toPrefix))
30893
30947
  } : {}
30894
30948
  };
30895
30949
  case "string":
@@ -30976,6 +31030,9 @@ function addFieldIssueToZodContext(zodCtx, validationIssue, rootPath) {
30976
31030
  case "invalidPhone":
30977
31031
  case "invalidPattern":
30978
31032
  case "invalidUrl":
31033
+ case "invalidDate":
31034
+ case "invalidTime":
31035
+ case "invalidDateTime":
30979
31036
  case "invalidNumber":
30980
31037
  case "tooSmall":
30981
31038
  case "tooLarge":
@@ -31072,6 +31129,53 @@ function isValidUrl(value, allowRelative) {
31072
31129
  return false;
31073
31130
  }
31074
31131
  }
31132
+ function isValidDateString(value) {
31133
+ const match2 = DATE_PATTERN.exec(value);
31134
+ if (!match2?.groups) return false;
31135
+ const year = Number(match2.groups.year);
31136
+ const month = Number(match2.groups.month);
31137
+ const day = Number(match2.groups.day);
31138
+ return isValidCalendarDate(year, month, day);
31139
+ }
31140
+ function isValidTimeString(value) {
31141
+ return TIME_PATTERN.test(value);
31142
+ }
31143
+ function isValidDateTimeInstantString(value) {
31144
+ const match2 = DATETIME_PATTERN.exec(value);
31145
+ if (!match2?.groups) return false;
31146
+ const datePart = match2.groups.date;
31147
+ if (!datePart || !isValidDateString(datePart)) return false;
31148
+ return !Number.isNaN(Date.parse(value));
31149
+ }
31150
+ function isValidCalendarDate(year, month, day) {
31151
+ if (!Number.isInteger(year) || !Number.isInteger(month) || !Number.isInteger(day)) return false;
31152
+ if (year < 1 || month < 1 || month > 12) return false;
31153
+ return day >= 1 && day <= daysInMonth(year, month);
31154
+ }
31155
+ function daysInMonth(year, month) {
31156
+ switch (month) {
31157
+ case 2:
31158
+ return isLeapYear(year) ? 29 : 28;
31159
+ case 4:
31160
+ case 6:
31161
+ case 9:
31162
+ case 11:
31163
+ return 30;
31164
+ case 1:
31165
+ case 3:
31166
+ case 5:
31167
+ case 7:
31168
+ case 8:
31169
+ case 10:
31170
+ case 12:
31171
+ return 31;
31172
+ default:
31173
+ return 0;
31174
+ }
31175
+ }
31176
+ function isLeapYear(year) {
31177
+ return year % 4 === 0 && (year % 100 !== 0 || year % 400 === 0);
31178
+ }
31075
31179
  function isValidSelectValue(value, values, multiple) {
31076
31180
  if (multiple) {
31077
31181
  return Array.isArray(value) && value.every((item) => typeof item === "string" && values.includes(item));
@@ -31708,6 +31812,51 @@ var eyebrowTreatmentValues = [
31708
31812
  "pill-bounce",
31709
31813
  "accent-pill-bounce"
31710
31814
  ];
31815
+ var visibleHeadingDecorationFamilyValues = [
31816
+ "organic-squiggle",
31817
+ "short-center-rule"
31818
+ ];
31819
+ var visibleHeadingDecorationPlacementValues = [
31820
+ "after-heading",
31821
+ "between-heading-and-body",
31822
+ "under-centered-heading"
31823
+ ];
31824
+ var headingDecorationOverrideValues = [
31825
+ "site-default",
31826
+ "on",
31827
+ "off"
31828
+ ];
31829
+ var headingDecorationColorTokenValues = [
31830
+ "text",
31831
+ "primary",
31832
+ "secondary",
31833
+ "accent",
31834
+ "border",
31835
+ "muted"
31836
+ ];
31837
+ var noHeadingDecoration = {
31838
+ family: "none",
31839
+ placement: "none"
31840
+ };
31841
+ var accordionIconSetValues = [
31842
+ "plus",
31843
+ "chevron",
31844
+ "caret",
31845
+ "minimal-cross"
31846
+ ];
31847
+ var accordionIconColorTokenValues = [
31848
+ "text",
31849
+ "muted",
31850
+ "primary",
31851
+ "secondary",
31852
+ "accent",
31853
+ "current"
31854
+ ];
31855
+ var accordionIconMotionValues = [
31856
+ "none",
31857
+ "rotate",
31858
+ "swap"
31859
+ ];
31711
31860
  function defineBlockDesignCapability(capability) {
31712
31861
  return {
31713
31862
  ...capability,
@@ -31717,7 +31866,9 @@ function defineBlockDesignCapability(capability) {
31717
31866
  imageSurfaceMotions: capability.imageSurfaceMotions ?? ["static"],
31718
31867
  testimonialCardTreatments: capability.testimonialCardTreatments ?? ["default"],
31719
31868
  tileTreatments: capability.tileTreatments ?? ["default"],
31720
- eyebrowTreatments: capability.eyebrowTreatments ?? ["plain"]
31869
+ eyebrowTreatments: capability.eyebrowTreatments ?? ["plain"],
31870
+ ...capability.headingDecorations ? { headingDecorations: capability.headingDecorations } : {},
31871
+ ...capability.accordionIconSets ? { accordionIconSets: capability.accordionIconSets } : {}
31721
31872
  };
31722
31873
  }
31723
31874
 
@@ -31908,6 +32059,25 @@ function defineBlockDesignCapability(capability) {
31908
32059
  emphasis: "high"
31909
32060
  }
31910
32061
  }),
32062
+ defineBlockAppearancePreset({
32063
+ kind: "block-design",
32064
+ id: "intro-soft-earth-statement",
32065
+ target: "intro",
32066
+ label: "Soft Earth intro statement",
32067
+ blockKinds: ["block.intro"],
32068
+ design: {
32069
+ sectionSurface: "base",
32070
+ contentFrame: plainFrame,
32071
+ itemSurface: "none",
32072
+ transitionAfter: "soft-fade-short",
32073
+ emphasis: "high",
32074
+ headingDecoration: {
32075
+ family: "organic-squiggle",
32076
+ placement: "after-heading",
32077
+ colorToken: "primary"
32078
+ }
32079
+ }
32080
+ }),
31911
32081
  defineBlockAppearancePreset({
31912
32082
  kind: "block-design",
31913
32083
  id: "offerings-calm-list",
@@ -31922,6 +32092,25 @@ function defineBlockDesignCapability(capability) {
31922
32092
  emphasis: "medium"
31923
32093
  }
31924
32094
  }),
32095
+ defineBlockAppearancePreset({
32096
+ kind: "block-design",
32097
+ id: "feature-cards-soft-earth-offerings",
32098
+ target: "feature-cards",
32099
+ label: "Soft Earth offering cards",
32100
+ blockKinds: ["block.feature-cards"],
32101
+ design: {
32102
+ sectionSurface: "base",
32103
+ contentFrame: plainFrame,
32104
+ itemSurface: "raised",
32105
+ transitionAfter: "none",
32106
+ emphasis: "high",
32107
+ headingDecoration: {
32108
+ family: "short-center-rule",
32109
+ placement: "under-centered-heading",
32110
+ colorToken: "primary"
32111
+ }
32112
+ }
32113
+ }),
31925
32114
  defineBlockAppearancePreset({
31926
32115
  kind: "block-design",
31927
32116
  id: "events-base-calendar",
@@ -32050,6 +32239,26 @@ function defineBlockDesignCapability(capability) {
32050
32239
  testimonialCardTreatment: "accent-quote"
32051
32240
  }
32052
32241
  }),
32242
+ defineBlockAppearancePreset({
32243
+ kind: "block-design",
32244
+ id: "testimonials-soft-earth-proof-band",
32245
+ target: "testimonials",
32246
+ label: "Soft Earth proof band",
32247
+ blockKinds: ["block.testimonials"],
32248
+ design: {
32249
+ sectionSurface: "brand-depth-band",
32250
+ contentFrame: plainFrame,
32251
+ itemSurface: "none",
32252
+ transitionAfter: "soft-fade-short",
32253
+ emphasis: "high",
32254
+ testimonialCardTreatment: "accent-quote",
32255
+ headingDecoration: {
32256
+ family: "short-center-rule",
32257
+ placement: "under-centered-heading",
32258
+ colorToken: "border"
32259
+ }
32260
+ }
32261
+ }),
32053
32262
  defineBlockAppearancePreset({
32054
32263
  kind: "block-design",
32055
32264
  id: "faq-base-accordion",
@@ -32078,6 +32287,25 @@ function defineBlockDesignCapability(capability) {
32078
32287
  emphasis: "low"
32079
32288
  }
32080
32289
  }),
32290
+ defineBlockAppearancePreset({
32291
+ kind: "block-design",
32292
+ id: "faq-soft-earth-two-column",
32293
+ target: "faq",
32294
+ label: "Soft Earth two-column FAQ",
32295
+ blockKinds: ["block.faq"],
32296
+ design: {
32297
+ sectionSurface: "base",
32298
+ contentFrame: plainFrame,
32299
+ itemSurface: "flat",
32300
+ transitionAfter: "none",
32301
+ emphasis: "medium",
32302
+ accordionIconTreatment: {
32303
+ iconSet: "plus",
32304
+ colorToken: "primary",
32305
+ motion: "swap"
32306
+ }
32307
+ }
32308
+ }),
32081
32309
  defineBlockAppearancePreset({
32082
32310
  kind: "block-design",
32083
32311
  id: "contact-form-panel",
@@ -32753,6 +32981,97 @@ var confidentChip = defineButtonPersonality({
32753
32981
  }
32754
32982
  });
32755
32983
 
32984
+ // ../theme-core/src/buttons/personalities/earth-pill.ts
32985
+ var earthPill = defineButtonPersonality({
32986
+ id: "earth-pill",
32987
+ name: "Earth Pill",
32988
+ description: "Compact terracotta pills with quiet primary-coloured ghost CTAs.",
32989
+ tags: { tone: "classic", energy: "calm", motion: "subtle", era: "organic" },
32990
+ buttonSystem: {
32991
+ global: {
32992
+ cornerStyle: "pill",
32993
+ shadow: "low",
32994
+ textTransform: "none",
32995
+ fontWeight: 500,
32996
+ borderWidth: 1,
32997
+ hoverTransform: "lift",
32998
+ hoverColor: "none",
32999
+ typography: "body",
33000
+ paddingPreset: "default"
33001
+ },
33002
+ sizes: {
33003
+ sm: { padding: "0.5rem 1rem", fontSize: "text-sm" },
33004
+ md: { padding: "0.625rem 1.35rem" },
33005
+ lg: { padding: "0.75rem 1.65rem", fontSize: "text-lg" },
33006
+ xl: { padding: "0.875rem 2rem", fontSize: "text-xl" }
33007
+ },
33008
+ variants: [
33009
+ {
33010
+ id: "primary",
33011
+ name: "Primary",
33012
+ enabled: true,
33013
+ priority: 1,
33014
+ background: { type: "solid", colorToken: "primary" },
33015
+ textColorToken: "primaryForeground",
33016
+ borderRadius: "rounded-full",
33017
+ shadow: { elevation: "low", softness: "soft", position: "bottom" },
33018
+ effects: {
33019
+ hover: [
33020
+ { effectId: "lift", options: { translateY: "-1px" } },
33021
+ { effectId: "background-on-hover", options: { colorToken: "accent" } }
33022
+ ],
33023
+ active: [{ effectId: "scale-down", options: { scale: "0.98" } }]
33024
+ }
33025
+ },
33026
+ {
33027
+ id: "secondary",
33028
+ name: "Secondary",
33029
+ enabled: true,
33030
+ priority: 2,
33031
+ background: { type: "transparent" },
33032
+ textColorToken: "primary",
33033
+ borderRadius: "rounded-full",
33034
+ border: { widthClass: "border", colorToken: "primary" },
33035
+ effects: {
33036
+ hover: [{ effectId: "background-on-hover", options: { colorToken: "muted" } }]
33037
+ }
33038
+ },
33039
+ {
33040
+ id: "outline",
33041
+ name: "Outline",
33042
+ enabled: true,
33043
+ priority: 3,
33044
+ background: { type: "transparent" },
33045
+ textColorToken: "text",
33046
+ borderRadius: "rounded-full",
33047
+ border: { widthClass: "border", colorToken: "border" },
33048
+ effects: {
33049
+ hover: [{ effectId: "background-on-hover", options: { colorToken: "surfaceAlt" } }]
33050
+ }
33051
+ },
33052
+ {
33053
+ id: "ghost",
33054
+ name: "Ghost",
33055
+ enabled: true,
33056
+ priority: 3,
33057
+ background: { type: "transparent" },
33058
+ textColorToken: "primary",
33059
+ borderRadius: "rounded-full",
33060
+ shadow: { elevation: "none", softness: null, position: "bottom" },
33061
+ sizes: {
33062
+ sm: { padding: "0.25rem 0", fontSize: "text-sm" },
33063
+ md: { padding: "0.375rem 0" },
33064
+ lg: { padding: "0.5rem 0", fontSize: "text-lg" },
33065
+ xl: { padding: "0.625rem 0", fontSize: "text-xl" }
33066
+ },
33067
+ effects: {
33068
+ hover: [{ effectId: "opacity-reduce", options: { reduction: 25 } }]
33069
+ }
33070
+ }
33071
+ ]
33072
+ }
33073
+ });
33074
+
32756
33075
  // ../theme-core/src/buttons/personalities/editorial-link.ts
32757
33076
  var editorialLink = defineButtonPersonality({
32758
33077
  id: "editorial-link",
@@ -33211,6 +33530,7 @@ var softPill = defineButtonPersonality({
33211
33530
  // ../theme-core/src/buttons/personalities/index.ts
33212
33531
  var buttonPersonalities = [
33213
33532
  softPill,
33533
+ earthPill,
33214
33534
  confidentChip,
33215
33535
  editorialLink,
33216
33536
  pebble,
@@ -35923,12 +36243,36 @@ var boxBackgroundSchema = z.object({
35923
36243
  textColor: tokenOrCssColorValueSchema.nullable().optional(),
35924
36244
  headingColor: tokenOrCssColorValueSchema.nullable().optional()
35925
36245
  });
36246
+ var noHeadingDecorationSchema = z.object({
36247
+ family: z.literal("none"),
36248
+ placement: z.literal("none")
36249
+ });
36250
+ var visibleHeadingDecorationSchema = z.object({
36251
+ family: z.enum(visibleHeadingDecorationFamilyValues),
36252
+ placement: z.enum(visibleHeadingDecorationPlacementValues),
36253
+ colorToken: z.enum(headingDecorationColorTokenValues).optional()
36254
+ });
36255
+ var headingDecorationSchema = z.union([
36256
+ noHeadingDecorationSchema,
36257
+ visibleHeadingDecorationSchema
36258
+ ]);
36259
+ var accordionIconTreatmentSchema = z.object({
36260
+ iconSet: z.enum(accordionIconSetValues),
36261
+ colorToken: z.enum(accordionIconColorTokenValues),
36262
+ openColorToken: z.enum(accordionIconColorTokenValues).optional(),
36263
+ motion: z.enum(accordionIconMotionValues)
36264
+ });
35926
36265
  var sectionStylesOverrideSchema = z.object({
35927
36266
  background: boxBackgroundSchema.nullable().optional(),
35928
36267
  spacing: semanticSpacingSchema.nullable().optional(),
35929
36268
  minHeight: z.enum(["none", "banner", "hero", "immersive"]).nullable().optional(),
35930
36269
  tileTreatment: z.enum(tileTreatmentValues).nullable().optional(),
35931
- eyebrowTreatment: z.enum(eyebrowTreatmentValues).nullable().optional()
36270
+ eyebrowTreatment: z.enum(eyebrowTreatmentValues).nullable().optional(),
36271
+ headingDecoration: headingDecorationSchema.nullable().optional(),
36272
+ // Author-level override consumed by later block/editor rendering phases.
36273
+ // Keeping it in section styles lets existing block save APIs persist it.
36274
+ headingDecorationOverride: z.enum(headingDecorationOverrideValues).nullable().optional(),
36275
+ accordionIconTreatment: accordionIconTreatmentSchema.nullable().optional()
35932
36276
  });
35933
36277
  var containerStylesOverrideSchema = z.object({
35934
36278
  background: boxBackgroundSchema.nullable().optional(),
@@ -36636,6 +36980,28 @@ var warmNeutralCream = definePaletteVariant({
36636
36980
  { name: "border", hex: "#e0d2b8" }
36637
36981
  ]
36638
36982
  });
36983
+ var warmNeutralSoftEarth = definePaletteVariant({
36984
+ id: "warm-neutral-soft-earth",
36985
+ name: "Warm Neutral \u2014 Soft Earth",
36986
+ description: "Cream ground with terracotta primary, clay accents, and olive depth.",
36987
+ tags: { tone: "classic", energy: "calm", era: "organic" },
36988
+ mode: "light",
36989
+ colors: [
36990
+ { name: "primary", hex: "#a8573d" },
36991
+ { name: "secondary", hex: "#72765c" },
36992
+ { name: "accent", hex: "#c87557" },
36993
+ { name: "success", hex: "#687854" },
36994
+ { name: "warning", hex: "#b7863e" },
36995
+ { name: "destructive", hex: "#a54b3c" },
36996
+ { name: "background", hex: "#fbf6eb" },
36997
+ { name: "surface", hex: "#fffdf7" },
36998
+ { name: "surfaceAlt", hex: "#f0e4d3" },
36999
+ { name: "muted", hex: "#eadbc6" },
37000
+ { name: "text", hex: "#30281f" },
37001
+ { name: "primaryForeground", hex: "#fffaf3" },
37002
+ { name: "border", hex: "#d9c8b2" }
37003
+ ]
37004
+ });
36639
37005
  var warmNeutralForest = definePaletteVariant({
36640
37006
  id: "warm-neutral-forest",
36641
37007
  name: "Warm Neutral \u2014 Forest",
@@ -36669,6 +37035,7 @@ var paletteVariants = [
36669
37035
  // Warm-neutral family
36670
37036
  warmNeutralClay,
36671
37037
  warmNeutralCream,
37038
+ warmNeutralSoftEarth,
36672
37039
  warmNeutralForest,
36673
37040
  // High-contrast family
36674
37041
  highContrastInk,
@@ -36784,6 +37151,12 @@ function writePlanForLookCustomizationCommand(command2) {
36784
37151
  function asHeaderLookId(value) {
36785
37152
  return value;
36786
37153
  }
37154
+ function asHeaderLayoutId(value) {
37155
+ return value;
37156
+ }
37157
+ function asHeaderStyleId(value) {
37158
+ return value;
37159
+ }
36787
37160
  var defaultHeaderSelectionContext = {
36788
37161
  openingSection: {
36789
37162
  kind: "unknown",
@@ -36799,8 +37172,7 @@ var defaultHeaderSelectionContext = {
36799
37172
  importance: "medium"
36800
37173
  },
36801
37174
  banner: {
36802
- persistentVisibility: "possible",
36803
- shellCanOffsetOverlayHeader: false
37175
+ persistentVisibility: "possible"
36804
37176
  }
36805
37177
  };
36806
37178
  function mergeHeaderSelectionContext(context) {
@@ -36824,6 +37196,737 @@ function baseHeader(theme) {
36824
37196
  navContainer: { type: "none", tint: null, opacity: 0.15 }
36825
37197
  };
36826
37198
  }
37199
+ var headerLayoutCatalog = [
37200
+ {
37201
+ id: asHeaderLayoutId("classic"),
37202
+ label: "Classic",
37203
+ description: "Logo and navigation in one practical horizontal row.",
37204
+ structure: "inline-classic",
37205
+ variant: "classic",
37206
+ defaultPositioning: "sticky",
37207
+ shrinkOnScroll: false
37208
+ },
37209
+ {
37210
+ id: asHeaderLayoutId("centered"),
37211
+ label: "Centered",
37212
+ description: "Logo centered above a balanced navigation row.",
37213
+ structure: "centered-stack",
37214
+ variant: "centered",
37215
+ defaultPositioning: "static",
37216
+ shrinkOnScroll: false,
37217
+ maxRecommendedNavItems: 5,
37218
+ allowedLogoShapes: ["none", "text-only", "horizontal", "square"]
37219
+ },
37220
+ {
37221
+ id: asHeaderLayoutId("editorial"),
37222
+ label: "Editorial",
37223
+ description: "A composed, magazine-like stacked header treatment.",
37224
+ structure: "editorial-stack",
37225
+ variant: "editorial",
37226
+ defaultPositioning: "static",
37227
+ shrinkOnScroll: false,
37228
+ maxRecommendedNavItems: 6
37229
+ },
37230
+ {
37231
+ id: asHeaderLayoutId("floating"),
37232
+ label: "Floating",
37233
+ description: "Detached header chrome that sits over the opening section.",
37234
+ structure: "floating-shell",
37235
+ variant: "floating",
37236
+ defaultPositioning: "fixed",
37237
+ shrinkOnScroll: true,
37238
+ maxRecommendedNavItems: 5,
37239
+ allowedLogoShapes: ["none", "text-only", "horizontal"]
37240
+ }
37241
+ ];
37242
+ function supportedLayouts(ids2) {
37243
+ return ids2.map(asHeaderLayoutId);
37244
+ }
37245
+ var headerStyleCatalog = [
37246
+ {
37247
+ id: asHeaderStyleId("minimal"),
37248
+ label: "Minimal",
37249
+ description: "Quiet surface with simple color-change navigation.",
37250
+ supportedLayoutIds: supportedLayouts(["classic", "centered", "editorial"]),
37251
+ navInteraction: "color-change",
37252
+ surface: "neutral"
37253
+ },
37254
+ {
37255
+ id: asHeaderStyleId("fine-line"),
37256
+ label: "Fine Line",
37257
+ description: "Light surface with a crisp lower rule and underline hover.",
37258
+ supportedLayoutIds: supportedLayouts(["classic", "centered", "editorial"]),
37259
+ navInteraction: "underline-grow",
37260
+ surface: "bordered"
37261
+ },
37262
+ {
37263
+ id: asHeaderStyleId("soft-bar"),
37264
+ label: "Soft Bar",
37265
+ description: "Soft tinted surface with gentle pill hover states.",
37266
+ supportedLayoutIds: supportedLayouts(["classic", "centered"]),
37267
+ navInteraction: "pill-background",
37268
+ surface: "soft"
37269
+ },
37270
+ {
37271
+ id: asHeaderStyleId("pill-nav"),
37272
+ label: "Pill Nav",
37273
+ description: "A calm pill navigation rail over a neutral header.",
37274
+ supportedLayoutIds: supportedLayouts(["classic", "centered"]),
37275
+ navInteraction: "pill-background",
37276
+ surface: "soft"
37277
+ },
37278
+ {
37279
+ id: asHeaderStyleId("brand-bar"),
37280
+ label: "Brand Bar",
37281
+ description: "Solid brand surface with high-contrast navigation.",
37282
+ supportedLayoutIds: supportedLayouts(["classic", "centered", "editorial"]),
37283
+ navInteraction: "color-change",
37284
+ surface: "brand-solid"
37285
+ },
37286
+ {
37287
+ id: asHeaderStyleId("brand-underline"),
37288
+ label: "Brand Underline",
37289
+ description: "Brand surface with underline-grow navigation.",
37290
+ supportedLayoutIds: supportedLayouts(["classic", "editorial"]),
37291
+ navInteraction: "underline-grow",
37292
+ surface: "brand-solid"
37293
+ },
37294
+ {
37295
+ id: asHeaderStyleId("brand-pill"),
37296
+ label: "Brand Pill",
37297
+ description: "Solid brand surface with rounded active and hover states.",
37298
+ supportedLayoutIds: supportedLayouts(["classic", "centered", "floating"]),
37299
+ navInteraction: "pill-background",
37300
+ surface: "brand-solid"
37301
+ },
37302
+ {
37303
+ id: asHeaderStyleId("editorial-line"),
37304
+ label: "Editorial Line",
37305
+ description: "Typographic logo treatment with understated underline navigation.",
37306
+ supportedLayoutIds: supportedLayouts(["classic", "centered", "editorial"]),
37307
+ navInteraction: "underline-grow",
37308
+ surface: "bordered"
37309
+ },
37310
+ {
37311
+ id: asHeaderStyleId("flat-tabs"),
37312
+ label: "Flat Tabs",
37313
+ description: "Flat block hover and active states with a Swiss utility feel.",
37314
+ supportedLayoutIds: supportedLayouts(["classic", "centered", "editorial"]),
37315
+ navInteraction: "flat-block",
37316
+ surface: "bordered"
37317
+ },
37318
+ {
37319
+ id: asHeaderStyleId("glass"),
37320
+ label: "Glass",
37321
+ description: "Floating translucent chrome with frosted navigation backing.",
37322
+ supportedLayoutIds: supportedLayouts(["floating"]),
37323
+ navInteraction: "glass-backed",
37324
+ surface: "floating",
37325
+ requiresFloatingLayout: true
37326
+ },
37327
+ {
37328
+ id: asHeaderStyleId("minimal-surface"),
37329
+ label: "Minimal Surface",
37330
+ description: "Floating chrome with a restrained translucent surface.",
37331
+ supportedLayoutIds: supportedLayouts(["floating"]),
37332
+ navInteraction: "color-change",
37333
+ surface: "floating",
37334
+ requiresFloatingLayout: true
37335
+ },
37336
+ {
37337
+ id: asHeaderStyleId("soft-shell"),
37338
+ label: "Soft Shell",
37339
+ description: "Floating rounded shell with soft pill navigation states.",
37340
+ supportedLayoutIds: supportedLayouts(["floating"]),
37341
+ navInteraction: "pill-background",
37342
+ surface: "floating",
37343
+ requiresFloatingLayout: true
37344
+ }
37345
+ ];
37346
+ var headerLayoutsById = new Map(
37347
+ headerLayoutCatalog.map((layout) => [layout.id, layout])
37348
+ );
37349
+ var headerStylesById = new Map(
37350
+ headerStyleCatalog.map((style2) => [style2.id, style2])
37351
+ );
37352
+ var headerStyleCompatibilityOrder = /* @__PURE__ */ new Map([
37353
+ [
37354
+ asHeaderLayoutId("classic"),
37355
+ headerStyleRepairChain([
37356
+ "minimal",
37357
+ "fine-line",
37358
+ "soft-bar",
37359
+ "pill-nav",
37360
+ "brand-bar",
37361
+ "brand-underline",
37362
+ "brand-pill",
37363
+ "editorial-line",
37364
+ "flat-tabs"
37365
+ ])
37366
+ ],
37367
+ [
37368
+ asHeaderLayoutId("centered"),
37369
+ headerStyleRepairChain([
37370
+ "minimal",
37371
+ "fine-line",
37372
+ "soft-bar",
37373
+ "pill-nav",
37374
+ "brand-bar",
37375
+ "brand-pill",
37376
+ "editorial-line",
37377
+ "flat-tabs"
37378
+ ])
37379
+ ],
37380
+ [
37381
+ asHeaderLayoutId("editorial"),
37382
+ headerStyleRepairChain([
37383
+ "minimal",
37384
+ "fine-line",
37385
+ "soft-bar",
37386
+ "brand-bar",
37387
+ "brand-underline",
37388
+ "editorial-line",
37389
+ "flat-tabs"
37390
+ ])
37391
+ ],
37392
+ [
37393
+ asHeaderLayoutId("floating"),
37394
+ headerStyleRepairChain([
37395
+ "glass",
37396
+ "minimal-surface",
37397
+ "soft-shell",
37398
+ "brand-pill"
37399
+ ])
37400
+ ]
37401
+ ]);
37402
+ function headerStyleRepairChain(values) {
37403
+ return values.map(asHeaderStyleId);
37404
+ }
37405
+ var headerStyleRepairOrder = /* @__PURE__ */ new Map([
37406
+ [asHeaderStyleId("brand-bar"), headerStyleRepairChain(["brand-bar", "brand-pill", "minimal"])],
37407
+ [asHeaderStyleId("brand-underline"), headerStyleRepairChain(["editorial-line", "fine-line", "minimal"])],
37408
+ [asHeaderStyleId("brand-pill"), headerStyleRepairChain(["brand-pill", "brand-bar", "minimal"])],
37409
+ [asHeaderStyleId("pill-nav"), headerStyleRepairChain(["pill-nav", "soft-bar", "minimal"])],
37410
+ [asHeaderStyleId("flat-tabs"), headerStyleRepairChain(["flat-tabs", "pill-nav", "minimal"])],
37411
+ [asHeaderStyleId("editorial-line"), headerStyleRepairChain(["editorial-line", "fine-line", "minimal"])],
37412
+ [asHeaderStyleId("glass"), headerStyleRepairChain(["glass", "minimal-surface", "minimal"])],
37413
+ [asHeaderStyleId("soft-shell"), headerStyleRepairChain(["soft-shell", "soft-bar", "minimal"])],
37414
+ [asHeaderStyleId("minimal-surface"), headerStyleRepairChain(["minimal-surface", "minimal"])],
37415
+ [asHeaderStyleId("fine-line"), headerStyleRepairChain(["fine-line", "minimal"])],
37416
+ [asHeaderStyleId("soft-bar"), headerStyleRepairChain(["soft-bar", "minimal"])],
37417
+ [asHeaderStyleId("minimal"), headerStyleRepairChain(["minimal"])]
37418
+ ]);
37419
+ var legacyHeaderLookAliases = [
37420
+ {
37421
+ lookId: asHeaderLookId("clean-base"),
37422
+ selection: {
37423
+ layoutId: asHeaderLayoutId("classic"),
37424
+ styleId: asHeaderStyleId("minimal")
37425
+ }
37426
+ },
37427
+ {
37428
+ lookId: asHeaderLookId("brand-solid"),
37429
+ selection: {
37430
+ layoutId: asHeaderLayoutId("classic"),
37431
+ styleId: asHeaderStyleId("brand-bar")
37432
+ }
37433
+ },
37434
+ {
37435
+ lookId: asHeaderLookId("editorial-line"),
37436
+ selection: {
37437
+ layoutId: asHeaderLayoutId("editorial"),
37438
+ styleId: asHeaderStyleId("editorial-line")
37439
+ }
37440
+ },
37441
+ {
37442
+ lookId: asHeaderLookId("centered-calm"),
37443
+ selection: {
37444
+ layoutId: asHeaderLayoutId("centered"),
37445
+ styleId: asHeaderStyleId("minimal")
37446
+ }
37447
+ },
37448
+ {
37449
+ lookId: asHeaderLookId("practical-utility"),
37450
+ selection: {
37451
+ layoutId: asHeaderLayoutId("classic"),
37452
+ styleId: asHeaderStyleId("flat-tabs")
37453
+ }
37454
+ },
37455
+ {
37456
+ lookId: asHeaderLookId("minimal-transparent"),
37457
+ selection: {
37458
+ layoutId: asHeaderLayoutId("classic"),
37459
+ styleId: asHeaderStyleId("minimal")
37460
+ }
37461
+ },
37462
+ {
37463
+ lookId: asHeaderLookId("transparent-overlay"),
37464
+ selection: {
37465
+ layoutId: asHeaderLayoutId("floating"),
37466
+ styleId: asHeaderStyleId("glass")
37467
+ }
37468
+ },
37469
+ {
37470
+ lookId: asHeaderLookId("floating-glass"),
37471
+ selection: {
37472
+ layoutId: asHeaderLayoutId("floating"),
37473
+ styleId: asHeaderStyleId("glass")
37474
+ }
37475
+ }
37476
+ ];
37477
+ var legacyHeaderLookAliasesById = new Map(
37478
+ legacyHeaderLookAliases.map((alias) => [alias.lookId, alias])
37479
+ );
37480
+ function getHeaderLayout(id) {
37481
+ return headerLayoutsById.get(id) ?? null;
37482
+ }
37483
+ function getHeaderStyle(id) {
37484
+ return headerStylesById.get(id) ?? null;
37485
+ }
37486
+ function isHeaderStyleCompatibleWithLayout(style2, layoutId) {
37487
+ return style2.supportedLayoutIds.includes(layoutId);
37488
+ }
37489
+ function getHeaderLayoutOrThrow(id) {
37490
+ const layout = getHeaderLayout(id);
37491
+ if (!layout) {
37492
+ throw new Error(`Unknown Theme V2 header layout: ${id}`);
37493
+ }
37494
+ return layout;
37495
+ }
37496
+ function getHeaderStyleOrThrow(id) {
37497
+ const style2 = getHeaderStyle(id);
37498
+ if (!style2) {
37499
+ throw new Error(`Unknown Theme V2 header style: ${id}`);
37500
+ }
37501
+ return style2;
37502
+ }
37503
+ function resolveLegacyHeaderLookAlias(lookId) {
37504
+ return legacyHeaderLookAliasesById.get(lookId)?.selection ?? null;
37505
+ }
37506
+ function findLegacyHeaderLookIdForSelection(selection) {
37507
+ return legacyHeaderLookAliases.find(
37508
+ (alias) => alias.selection.layoutId === selection.layoutId && alias.selection.styleId === selection.styleId
37509
+ )?.lookId ?? null;
37510
+ }
37511
+ function getCompatibleHeaderStyleIds(layoutId) {
37512
+ return (headerStyleCompatibilityOrder.get(layoutId) ?? []).filter((styleId) => {
37513
+ const style2 = getHeaderStyleOrThrow(styleId);
37514
+ return isHeaderStyleCompatibleWithLayout(style2, layoutId);
37515
+ });
37516
+ }
37517
+ function deriveNearestCompatibleHeaderStyle(styleId, layoutId) {
37518
+ const requestedStyle = getHeaderStyleOrThrow(styleId);
37519
+ if (isHeaderStyleCompatibleWithLayout(requestedStyle, layoutId)) {
37520
+ return requestedStyle.id;
37521
+ }
37522
+ for (const candidateStyleId of headerStyleRepairOrder.get(styleId) ?? []) {
37523
+ const candidate = getHeaderStyleOrThrow(candidateStyleId);
37524
+ if (isHeaderStyleCompatibleWithLayout(candidate, layoutId)) {
37525
+ return candidate.id;
37526
+ }
37527
+ }
37528
+ const fallback2 = getCompatibleHeaderStyleIds(layoutId)[0];
37529
+ if (!fallback2) {
37530
+ throw new Error(`No header styles are compatible with layout: ${layoutId}`);
37531
+ }
37532
+ return fallback2;
37533
+ }
37534
+ function resolveHeaderLayoutStyleSelection(selection) {
37535
+ const layout = getHeaderLayoutOrThrow(selection.layoutId);
37536
+ const style2 = getHeaderStyleOrThrow(selection.styleId);
37537
+ if (isHeaderStyleCompatibleWithLayout(style2, layout.id)) {
37538
+ return {
37539
+ kind: "valid",
37540
+ selection,
37541
+ layout,
37542
+ style: style2
37543
+ };
37544
+ }
37545
+ const resolvedStyleId = deriveNearestCompatibleHeaderStyle(style2.id, layout.id);
37546
+ const resolvedStyle = getHeaderStyleOrThrow(resolvedStyleId);
37547
+ const resolvedSelection = {
37548
+ layoutId: layout.id,
37549
+ styleId: resolvedStyle.id
37550
+ };
37551
+ return {
37552
+ kind: "repaired",
37553
+ selection: resolvedSelection,
37554
+ layout,
37555
+ style: resolvedStyle,
37556
+ repair: {
37557
+ requested: selection,
37558
+ resolved: resolvedSelection,
37559
+ reason: "style-incompatible-with-layout"
37560
+ }
37561
+ };
37562
+ }
37563
+ function headerForLayout(theme, layout) {
37564
+ return {
37565
+ ...baseHeader(theme),
37566
+ variant: layout.variant,
37567
+ positioning: layout.defaultPositioning,
37568
+ shrinkOnScroll: layout.shrinkOnScroll,
37569
+ ctaGap: layout.id === asHeaderLayoutId("floating") ? "compact" : "default",
37570
+ logoText: layout.id === asHeaderLayoutId("classic") ? {
37571
+ mobileMaxWidth: "sm",
37572
+ mobileWrapLines: 1,
37573
+ hideOnShrink: false
37574
+ } : void 0
37575
+ };
37576
+ }
37577
+ function brandHeaderForeground() {
37578
+ return {
37579
+ textColor: "primaryForeground",
37580
+ navColor: "primaryForeground"
37581
+ };
37582
+ }
37583
+ function neutralDropdownStyle() {
37584
+ return {
37585
+ background: "surface",
37586
+ textColor: "text",
37587
+ borderColor: "border",
37588
+ shadow: "md",
37589
+ borderRadius: "md",
37590
+ textTransform: "none",
37591
+ letterSpacing: "normal"
37592
+ };
37593
+ }
37594
+ function brandDropdownStyle() {
37595
+ return {
37596
+ background: "primary-700",
37597
+ textColor: "primaryForeground",
37598
+ borderColor: null,
37599
+ shadow: "md",
37600
+ borderRadius: "md",
37601
+ hoverBackground: "primary-900",
37602
+ hoverTextColor: "secondary",
37603
+ textTransform: "uppercase",
37604
+ letterSpacing: "wider",
37605
+ fontWeight: "bold",
37606
+ textSize: "sm"
37607
+ };
37608
+ }
37609
+ function minimalNavLinkStyle(colorToken, hoverColorToken = "primary") {
37610
+ return {
37611
+ name: "Minimal",
37612
+ typography: "body",
37613
+ fontWeight: "medium",
37614
+ textTransform: "none",
37615
+ italic: false,
37616
+ colorToken,
37617
+ hoverColorToken,
37618
+ padding: "none",
37619
+ borderRadius: "none",
37620
+ effects: {
37621
+ hover: [
37622
+ { effectId: "text-color-change", options: { hoverColorToken } }
37623
+ ]
37624
+ }
37625
+ };
37626
+ }
37627
+ function underlineNavLinkStyle(colorToken, underlineColorToken) {
37628
+ return {
37629
+ name: "Underline grow",
37630
+ typography: "body",
37631
+ fontWeight: "medium",
37632
+ textTransform: "none",
37633
+ italic: false,
37634
+ colorToken,
37635
+ padding: "none",
37636
+ borderRadius: "none",
37637
+ effects: {
37638
+ hover: [
37639
+ {
37640
+ effectId: "nav-underline",
37641
+ options: {
37642
+ style: "grow",
37643
+ ...underlineColorToken ? { colorToken: underlineColorToken } : {}
37644
+ }
37645
+ }
37646
+ ]
37647
+ }
37648
+ };
37649
+ }
37650
+ function pillNavLinkStyle(colorToken, backgroundToken = "primary", opacity = 10) {
37651
+ return {
37652
+ name: "Pill",
37653
+ typography: "body",
37654
+ fontWeight: "medium",
37655
+ textTransform: "none",
37656
+ italic: false,
37657
+ colorToken,
37658
+ padding: "compact",
37659
+ borderRadius: "full",
37660
+ effects: {
37661
+ hover: [
37662
+ {
37663
+ effectId: "background-on-hover-alpha",
37664
+ options: { colorToken: backgroundToken, opacity }
37665
+ }
37666
+ ],
37667
+ active: [
37668
+ {
37669
+ effectId: "background-on-hover-alpha",
37670
+ options: { colorToken: backgroundToken, opacity: opacity + 5 }
37671
+ }
37672
+ ]
37673
+ }
37674
+ };
37675
+ }
37676
+ function flatTabNavLinkStyle(colorToken) {
37677
+ return {
37678
+ name: "Flat tabs",
37679
+ typography: "body",
37680
+ fontWeight: "semibold",
37681
+ textTransform: "none",
37682
+ italic: false,
37683
+ colorToken,
37684
+ padding: "compact",
37685
+ paddingX: "default",
37686
+ borderRadius: "none",
37687
+ effects: {
37688
+ hover: [
37689
+ {
37690
+ effectId: "background-on-hover-alpha",
37691
+ options: { colorToken: "primary", opacity: 10 }
37692
+ }
37693
+ ],
37694
+ active: [
37695
+ {
37696
+ effectId: "background-on-hover-alpha",
37697
+ options: { colorToken: "primary", opacity: 16 }
37698
+ }
37699
+ ]
37700
+ }
37701
+ };
37702
+ }
37703
+ function noHeaderBorder() {
37704
+ return { style: "solid", width: "none", position: "none" };
37705
+ }
37706
+ function bottomHeaderBorder() {
37707
+ return { style: "solid", width: "thin", position: "bottom", colorToken: "border" };
37708
+ }
37709
+ function colorHeaderBackground(color) {
37710
+ return { type: "color", color };
37711
+ }
37712
+ function neutralHeaderBase() {
37713
+ return {
37714
+ textColor: "text",
37715
+ navColor: "text",
37716
+ dropdownStyle: neutralDropdownStyle()
37717
+ };
37718
+ }
37719
+ function transparentHeaderBackground() {
37720
+ return colorHeaderBackground("transparent");
37721
+ }
37722
+ function floatingContainer(input) {
37723
+ return {
37724
+ rounded: input.rounded,
37725
+ border: true,
37726
+ shadow: true,
37727
+ padding: input.padding,
37728
+ tint: input.tint,
37729
+ opacity: input.opacity
37730
+ };
37731
+ }
37732
+ function brandSurfaceBase(theme, header) {
37733
+ const ctaVariant = resolveHeaderCtaVariant(theme, "inverted");
37734
+ return {
37735
+ ...header,
37736
+ ...brandHeaderForeground(),
37737
+ background: colorHeaderBackground("primary"),
37738
+ dropdownStyle: brandDropdownStyle(),
37739
+ border: noHeaderBorder(),
37740
+ ctaTreatment: "inverted",
37741
+ ...ctaVariant ? { ctaVariant } : {}
37742
+ };
37743
+ }
37744
+ function floatingSurfaceBase(header) {
37745
+ return {
37746
+ ...header,
37747
+ background: transparentHeaderBackground(),
37748
+ border: noHeaderBorder()
37749
+ };
37750
+ }
37751
+ function applyHeaderStyle(theme, header, style2) {
37752
+ const ctaVariant = (treatment) => resolveHeaderCtaVariant(theme, treatment);
37753
+ switch (style2.id) {
37754
+ case "minimal":
37755
+ return {
37756
+ ...header,
37757
+ ...neutralHeaderBase(),
37758
+ background: colorHeaderBackground("surface"),
37759
+ navStyle: "minimal",
37760
+ navWeight: "medium",
37761
+ navLinkStyle: minimalNavLinkStyle("text"),
37762
+ border: noHeaderBorder(),
37763
+ ctaTreatment: "default"
37764
+ };
37765
+ case "fine-line":
37766
+ return {
37767
+ ...header,
37768
+ ...neutralHeaderBase(),
37769
+ background: colorHeaderBackground("surface"),
37770
+ navStyle: "underline-grow",
37771
+ navWeight: "medium",
37772
+ navLinkStyle: underlineNavLinkStyle("text"),
37773
+ border: bottomHeaderBorder(),
37774
+ ctaTreatment: "outline",
37775
+ ctaVariant: ctaVariant("outline")
37776
+ };
37777
+ case "soft-bar":
37778
+ return {
37779
+ ...header,
37780
+ ...neutralHeaderBase(),
37781
+ background: colorHeaderBackground("surfaceAlt"),
37782
+ navStyle: "capsule",
37783
+ navWeight: "medium",
37784
+ navLinkStyle: pillNavLinkStyle("text", "primary", 8),
37785
+ border: bottomHeaderBorder(),
37786
+ ctaTreatment: "default"
37787
+ };
37788
+ case "pill-nav":
37789
+ return {
37790
+ ...header,
37791
+ ...neutralHeaderBase(),
37792
+ background: colorHeaderBackground("surface"),
37793
+ navStyle: "capsule",
37794
+ navWeight: "medium",
37795
+ navLinkStyle: pillNavLinkStyle("text"),
37796
+ navContainer: {
37797
+ type: "pill",
37798
+ tint: "surfaceAlt",
37799
+ opacity: 0.7
37800
+ },
37801
+ border: noHeaderBorder(),
37802
+ ctaTreatment: "default"
37803
+ };
37804
+ case "brand-bar":
37805
+ return {
37806
+ ...brandSurfaceBase(theme, header),
37807
+ navStyle: "minimal",
37808
+ navWeight: "semibold",
37809
+ navLinkStyle: minimalNavLinkStyle("primaryForeground", "secondary")
37810
+ };
37811
+ case "brand-underline":
37812
+ return {
37813
+ ...brandSurfaceBase(theme, header),
37814
+ navStyle: "underline-grow",
37815
+ navWeight: "bold",
37816
+ navLinkStyle: underlineNavLinkStyle("primaryForeground", "secondary")
37817
+ };
37818
+ case "brand-pill":
37819
+ return {
37820
+ ...brandSurfaceBase(theme, header),
37821
+ ...header.variant === "floating" ? {
37822
+ background: transparentHeaderBackground(),
37823
+ container: floatingContainer({
37824
+ rounded: "2xl",
37825
+ padding: "sm",
37826
+ tint: "primary",
37827
+ opacity: 0.95
37828
+ })
37829
+ } : {},
37830
+ navStyle: "capsule",
37831
+ navWeight: "semibold",
37832
+ navLinkStyle: pillNavLinkStyle("primaryForeground", "primaryForeground", 14)
37833
+ };
37834
+ case "editorial-line":
37835
+ return {
37836
+ ...header,
37837
+ ...neutralHeaderBase(),
37838
+ background: colorHeaderBackground("background"),
37839
+ navStyle: "underline-grow",
37840
+ navWeight: "medium",
37841
+ navLinkStyle: underlineNavLinkStyle("text"),
37842
+ border: bottomHeaderBorder(),
37843
+ logo: {
37844
+ fontFamily: "heading",
37845
+ letterSpacing: "wide",
37846
+ gradient: false
37847
+ },
37848
+ ctaTreatment: "outline",
37849
+ ctaVariant: ctaVariant("outline"),
37850
+ ctaGap: "relaxed"
37851
+ };
37852
+ case "flat-tabs":
37853
+ return {
37854
+ ...header,
37855
+ ...neutralHeaderBase(),
37856
+ background: colorHeaderBackground("surface"),
37857
+ navStyle: "solid",
37858
+ navWeight: "semibold",
37859
+ navLinkStyle: flatTabNavLinkStyle("text"),
37860
+ border: bottomHeaderBorder(),
37861
+ shadow: { elevation: "sm" },
37862
+ ctaTreatment: "primary",
37863
+ ctaVariant: ctaVariant("primary"),
37864
+ ctaGap: "compact"
37865
+ };
37866
+ case "glass":
37867
+ return {
37868
+ ...floatingSurfaceBase(header),
37869
+ textColor: "background",
37870
+ navColor: "background",
37871
+ navStyle: "frosted",
37872
+ navWeight: "semibold",
37873
+ navLinkStyle: pillNavLinkStyle("background", "neutral-50", 10),
37874
+ navContainer: {
37875
+ type: "glass",
37876
+ tint: "text",
37877
+ opacity: 0.16
37878
+ },
37879
+ container: floatingContainer({
37880
+ rounded: "2xl",
37881
+ padding: "sm",
37882
+ tint: "background",
37883
+ opacity: 0.12
37884
+ }),
37885
+ ctaTreatment: "inverted",
37886
+ ctaVariant: ctaVariant("inverted")
37887
+ };
37888
+ case "minimal-surface":
37889
+ return {
37890
+ ...floatingSurfaceBase(header),
37891
+ ...neutralHeaderBase(),
37892
+ navStyle: "minimal",
37893
+ navWeight: "medium",
37894
+ navLinkStyle: minimalNavLinkStyle("text"),
37895
+ container: floatingContainer({
37896
+ rounded: "xl",
37897
+ padding: "sm",
37898
+ tint: "surface",
37899
+ opacity: 0.92
37900
+ }),
37901
+ ctaTreatment: "default"
37902
+ };
37903
+ case "soft-shell":
37904
+ return {
37905
+ ...floatingSurfaceBase(header),
37906
+ ...neutralHeaderBase(),
37907
+ navStyle: "capsule",
37908
+ navWeight: "medium",
37909
+ navLinkStyle: pillNavLinkStyle("text", "primary", 8),
37910
+ container: floatingContainer({
37911
+ rounded: "2xl",
37912
+ padding: "md",
37913
+ tint: "surfaceAlt",
37914
+ opacity: 0.95
37915
+ }),
37916
+ ctaTreatment: "default"
37917
+ };
37918
+ default:
37919
+ return assertNever5(style2.id, "Unhandled header style id");
37920
+ }
37921
+ }
37922
+ function compileHeaderLayoutStyleSelection(theme, selection) {
37923
+ const resolution = resolveHeaderLayoutStyleSelection(selection);
37924
+ return applyHeaderStyle(
37925
+ theme,
37926
+ headerForLayout(theme, resolution.layout),
37927
+ resolution.style
37928
+ );
37929
+ }
36827
37930
  function solidBrandHeader(theme) {
36828
37931
  const ctaVariant = resolveHeaderCtaVariant(theme, "inverted");
36829
37932
  return {
@@ -37060,6 +38163,11 @@ var headerLookCatalog = [
37060
38163
  label: "Clean base",
37061
38164
  visualTreatment: "solid-neutral",
37062
38165
  layoutBehavior: "sticky",
38166
+ configuration: {
38167
+ structure: "inline-classic",
38168
+ treatment: "solid-neutral",
38169
+ behavior: "sticky"
38170
+ },
37063
38171
  openingRequirement: "none",
37064
38172
  compile: cleanBaseHeader
37065
38173
  },
@@ -37068,6 +38176,11 @@ var headerLookCatalog = [
37068
38176
  label: "Brand solid",
37069
38177
  visualTreatment: "solid-brand",
37070
38178
  layoutBehavior: "sticky-shrink",
38179
+ configuration: {
38180
+ structure: "inline-classic",
38181
+ treatment: "solid-brand",
38182
+ behavior: "sticky-shrink"
38183
+ },
37071
38184
  openingRequirement: "none",
37072
38185
  compile: solidBrandHeader
37073
38186
  },
@@ -37076,6 +38189,11 @@ var headerLookCatalog = [
37076
38189
  label: "Editorial line",
37077
38190
  visualTreatment: "light-editorial",
37078
38191
  layoutBehavior: "sticky",
38192
+ configuration: {
38193
+ structure: "editorial-stack",
38194
+ treatment: "light-editorial",
38195
+ behavior: "sticky"
38196
+ },
37079
38197
  openingRequirement: "none",
37080
38198
  maxRecommendedNavItems: 6,
37081
38199
  compile: editorialLineHeader
@@ -37085,6 +38203,11 @@ var headerLookCatalog = [
37085
38203
  label: "Centered calm",
37086
38204
  visualTreatment: "light-editorial",
37087
38205
  layoutBehavior: "normal-flow",
38206
+ configuration: {
38207
+ structure: "centered-stack",
38208
+ treatment: "light-editorial",
38209
+ behavior: "normal-flow"
38210
+ },
37088
38211
  openingRequirement: "none",
37089
38212
  maxRecommendedNavItems: 5,
37090
38213
  allowedLogoShapes: ["none", "text-only", "horizontal", "square"],
@@ -37095,6 +38218,11 @@ var headerLookCatalog = [
37095
38218
  label: "Practical utility",
37096
38219
  visualTreatment: "solid-neutral",
37097
38220
  layoutBehavior: "sticky-shrink",
38221
+ configuration: {
38222
+ structure: "inline-classic",
38223
+ treatment: "solid-neutral",
38224
+ behavior: "sticky-shrink"
38225
+ },
37098
38226
  openingRequirement: "none",
37099
38227
  requiresProminentCta: true,
37100
38228
  compile: practicalUtilityHeader
@@ -37104,6 +38232,11 @@ var headerLookCatalog = [
37104
38232
  label: "Minimal transparent",
37105
38233
  visualTreatment: "minimal-transparent",
37106
38234
  layoutBehavior: "normal-flow",
38235
+ configuration: {
38236
+ structure: "inline-classic",
38237
+ treatment: "minimal-transparent",
38238
+ behavior: "normal-flow"
38239
+ },
37107
38240
  openingRequirement: "reserved-space-ok",
37108
38241
  compile: minimalTransparentHeader
37109
38242
  },
@@ -37112,6 +38245,11 @@ var headerLookCatalog = [
37112
38245
  label: "Transparent overlay",
37113
38246
  visualTreatment: "transparent-overlay",
37114
38247
  layoutBehavior: "fixed-overlay",
38248
+ configuration: {
38249
+ structure: "inline-classic",
38250
+ treatment: "transparent-overlay",
38251
+ behavior: "fixed-overlay"
38252
+ },
37115
38253
  openingRequirement: "requires-image-hero-with-contrast-overlay",
37116
38254
  maxRecommendedNavItems: 5,
37117
38255
  allowedLogoShapes: ["none", "text-only", "horizontal"],
@@ -37122,6 +38260,11 @@ var headerLookCatalog = [
37122
38260
  label: "Floating glass",
37123
38261
  visualTreatment: "floating-glass",
37124
38262
  layoutBehavior: "fixed-floating",
38263
+ configuration: {
38264
+ structure: "floating-shell",
38265
+ treatment: "floating-glass",
38266
+ behavior: "fixed-floating"
38267
+ },
37125
38268
  openingRequirement: "requires-image-hero-with-contrast-overlay",
37126
38269
  maxRecommendedNavItems: 5,
37127
38270
  allowedLogoShapes: ["none", "text-only", "horizontal"],
@@ -37129,15 +38272,18 @@ var headerLookCatalog = [
37129
38272
  }
37130
38273
  ];
37131
38274
  var guaranteedFallbackHeaderLookId = asHeaderLookId("clean-base");
38275
+ new Set(
38276
+ headerLookCatalog.map((look) => headerConfigurationKey(look.configuration))
38277
+ );
37132
38278
  var headerLooksById = new Map(
37133
38279
  headerLookCatalog.map((look) => [look.id, look])
37134
38280
  );
38281
+ function headerConfigurationKey(configuration) {
38282
+ return `${configuration.structure}:${configuration.treatment}:${configuration.behavior}`;
38283
+ }
37135
38284
  function getHeaderLook(id) {
37136
38285
  return headerLooksById.get(id) ?? null;
37137
38286
  }
37138
- function findHeaderLook(id) {
37139
- return headerLooksById.get(id);
37140
- }
37141
38287
  function getHeaderLookOrThrow(id) {
37142
38288
  const look = getHeaderLook(id);
37143
38289
  if (!look) {
@@ -37145,35 +38291,8 @@ function getHeaderLookOrThrow(id) {
37145
38291
  }
37146
38292
  return look;
37147
38293
  }
37148
- function headerLookRequiresImageHeroOpening(look) {
37149
- return look.openingRequirement === "requires-image-hero-with-contrast-overlay";
37150
- }
37151
- function headerLookUsesOverlayLayout(look) {
37152
- return look.layoutBehavior === "fixed-overlay" || look.layoutBehavior === "fixed-floating";
37153
- }
37154
- function overlayRequirementReasons(look, context) {
37155
- if (!headerLookRequiresImageHeroOpening(look)) {
37156
- return [];
37157
- }
37158
- const opening = context.openingSection;
37159
- if (opening.kind !== "image-hero") {
37160
- return ["requires-image-hero-with-contrast-overlay"];
37161
- }
37162
- return [
37163
- ...!opening.hasContrastOverlay ? ["requires-image-hero-with-contrast-overlay"] : [],
37164
- ...!opening.hasTopSpacing ? ["requires-opening-section-top-spacing"] : []
37165
- ];
37166
- }
37167
- function bannerReasons(look, context) {
37168
- if (!headerLookUsesOverlayLayout(look) || context.banner.persistentVisibility !== "visible") {
37169
- return [];
37170
- }
37171
- return context.banner.shellCanOffsetOverlayHeader ? [] : ["requires-banner-offset-shell"];
37172
- }
37173
38294
  function rejectReasonsForLook(look, context) {
37174
38295
  return [
37175
- ...overlayRequirementReasons(look, context),
37176
- ...bannerReasons(look, context),
37177
38296
  ...look.maxRecommendedNavItems !== void 0 && context.navigation.itemCount > look.maxRecommendedNavItems ? ["too-many-nav-items"] : [],
37178
38297
  ...look.allowedLogoShapes && !look.allowedLogoShapes.includes(context.logo.shape) ? ["logo-shape-incompatible"] : [],
37179
38298
  ...look.requiresProminentCta && context.cta.importance === "low" ? ["cta-treatment-unavailable"] : []
@@ -37196,24 +38315,6 @@ function resolveHeaderLook(input) {
37196
38315
  rejected: result.rejected
37197
38316
  };
37198
38317
  }
37199
- function headerLookRejectionReasonLabel(reason) {
37200
- switch (reason) {
37201
- case "requires-image-hero-with-contrast-overlay":
37202
- return "Needs an opening image hero with a contrast overlay.";
37203
- case "requires-opening-section-top-spacing":
37204
- return "Needs enough top spacing in the opening section.";
37205
- case "requires-banner-offset-shell":
37206
- return "Needs the site banner to sit above overlay header chrome.";
37207
- case "too-many-nav-items":
37208
- return "Navigation has too many items for this header.";
37209
- case "logo-shape-incompatible":
37210
- return "Logo shape does not fit this header.";
37211
- case "cta-treatment-unavailable":
37212
- return "Needs a more prominent call-to-action treatment.";
37213
- default:
37214
- return assertNever5(reason, "Unhandled header Look rejection reason");
37215
- }
37216
- }
37217
38318
 
37218
38319
  // ../theme-core/src/site-styles/footerLooks.ts
37219
38320
  function asFooterLookId(value) {
@@ -37440,6 +38541,356 @@ var userDesignOptionCatalog = {
37440
38541
  ],
37441
38542
  emphases: generatedDesignOptionCatalog.emphases};
37442
38543
 
38544
+ // ../theme-core/src/site-styles/typographyPresets.ts
38545
+ var typographyPresetIdValues = [
38546
+ "typography-preset:modern-sans",
38547
+ "typography-preset:warm-rounded",
38548
+ "typography-preset:editorial-serif",
38549
+ "typography-preset:classic-serif",
38550
+ "typography-preset:luxe-contrast",
38551
+ "typography-preset:bold-display"
38552
+ ];
38553
+ var bodyReadablePolicy = {
38554
+ recommendedCategories: ["sans-serif", "serif"],
38555
+ allowedCategories: ["sans-serif", "serif"],
38556
+ requiresItalicForBody: true,
38557
+ requiresBoldForBody: true
38558
+ };
38559
+ var headingFlexiblePolicy = {
38560
+ recommendedCategories: ["sans-serif", "serif", "display"],
38561
+ allowedCategories: ["sans-serif", "serif", "display"]
38562
+ };
38563
+ var BOLD_WEIGHT_THRESHOLD = 700;
38564
+ var displayHeadingPolicy = {
38565
+ recommendedCategories: ["display", "sans-serif", "serif"],
38566
+ allowedCategories: ["display", "sans-serif", "serif"]
38567
+ };
38568
+ function asTypographyPresetId(value) {
38569
+ if (!value.startsWith("typography-preset:")) {
38570
+ throw new Error(`TypographyPresetId must start with "typography-preset:". Received: ${value}`);
38571
+ }
38572
+ return value;
38573
+ }
38574
+ function defineTypographyPreset(preset2) {
38575
+ return {
38576
+ ...preset2,
38577
+ id: asTypographyPresetId(preset2.id)
38578
+ };
38579
+ }
38580
+ var modernSansTypography = {
38581
+ body: {
38582
+ family: "Inter, system-ui, sans-serif",
38583
+ size: "md",
38584
+ weight: "regular",
38585
+ lineHeight: "relaxed",
38586
+ letterSpacing: "normal"
38587
+ },
38588
+ headings: {
38589
+ default: {
38590
+ family: "Inter, system-ui, sans-serif",
38591
+ weight: "semibold",
38592
+ lineHeight: "normal",
38593
+ letterSpacing: "tight",
38594
+ italic: null,
38595
+ case: null
38596
+ },
38597
+ h1: { size: "xl", weight: "bold", lineHeight: "normal", letterSpacing: "tight", italic: null },
38598
+ h2: { size: "lg", weight: "semibold", lineHeight: "normal", letterSpacing: "tight", italic: null },
38599
+ h3: { size: "md", weight: "semibold", lineHeight: "normal", letterSpacing: "normal", italic: null }
38600
+ },
38601
+ scale: "balanced"
38602
+ };
38603
+ var warmRoundedTypography = {
38604
+ body: {
38605
+ family: "Nunito Sans, system-ui, sans-serif",
38606
+ size: "lg",
38607
+ weight: "regular",
38608
+ lineHeight: "relaxed",
38609
+ letterSpacing: "normal"
38610
+ },
38611
+ headings: {
38612
+ default: {
38613
+ family: "Nunito Sans, system-ui, sans-serif",
38614
+ weight: "bold",
38615
+ lineHeight: "normal",
38616
+ letterSpacing: "normal",
38617
+ italic: null,
38618
+ case: null
38619
+ },
38620
+ h1: { size: "xl", weight: "bold", lineHeight: "normal", letterSpacing: "normal", italic: null },
38621
+ h2: { size: "lg", weight: "bold", lineHeight: "normal", letterSpacing: "normal", italic: null },
38622
+ h3: { size: "md", weight: "semibold", lineHeight: "relaxed", letterSpacing: "normal", italic: null }
38623
+ },
38624
+ scale: "balanced"
38625
+ };
38626
+ var editorialSerifTypography = {
38627
+ body: {
38628
+ family: "Lora, Georgia, serif",
38629
+ size: "lg",
38630
+ weight: "regular",
38631
+ lineHeight: "loose",
38632
+ letterSpacing: "normal"
38633
+ },
38634
+ headings: {
38635
+ default: {
38636
+ family: "Playfair Display, Georgia, serif",
38637
+ weight: "semibold",
38638
+ lineHeight: "normal",
38639
+ letterSpacing: "tight",
38640
+ italic: null,
38641
+ case: null
38642
+ },
38643
+ h1: { size: "2xl", weight: "semibold", lineHeight: "normal", letterSpacing: "tight", italic: null },
38644
+ h2: { size: "xl", weight: "semibold", lineHeight: "normal", letterSpacing: "normal", italic: null },
38645
+ h3: { size: "md", weight: "semibold", lineHeight: "relaxed", letterSpacing: "normal", italic: true }
38646
+ },
38647
+ scale: "spacious"
38648
+ };
38649
+ var classicSerifTypography = {
38650
+ body: {
38651
+ family: "Libre Baskerville, Georgia, serif",
38652
+ size: "md",
38653
+ weight: "regular",
38654
+ lineHeight: "relaxed",
38655
+ letterSpacing: "normal"
38656
+ },
38657
+ headings: {
38658
+ default: {
38659
+ family: "Cormorant Garamond, Georgia, serif",
38660
+ weight: "semibold",
38661
+ lineHeight: "normal",
38662
+ letterSpacing: "normal",
38663
+ italic: null,
38664
+ case: null
38665
+ },
38666
+ h1: { size: "2xl", weight: "semibold", lineHeight: "normal", letterSpacing: "normal", italic: null },
38667
+ h2: { size: "xl", weight: "semibold", lineHeight: "normal", letterSpacing: "normal", italic: null },
38668
+ h3: { size: "md", weight: "medium", lineHeight: "relaxed", letterSpacing: "normal", italic: null }
38669
+ },
38670
+ scale: "balanced"
38671
+ };
38672
+ var luxeContrastTypography = {
38673
+ body: {
38674
+ family: "Manrope, system-ui, sans-serif",
38675
+ size: "md",
38676
+ weight: "regular",
38677
+ lineHeight: "relaxed",
38678
+ letterSpacing: "normal"
38679
+ },
38680
+ headings: {
38681
+ default: {
38682
+ family: "Cormorant Garamond, Georgia, serif",
38683
+ weight: "semibold",
38684
+ lineHeight: "normal",
38685
+ letterSpacing: "tight",
38686
+ italic: null,
38687
+ case: null
38688
+ },
38689
+ h1: { size: "2xl", weight: "semibold", lineHeight: "normal", letterSpacing: "tight", italic: null },
38690
+ h2: { size: "xl", weight: "semibold", lineHeight: "normal", letterSpacing: "tight", italic: null },
38691
+ h3: { size: "md", weight: "medium", lineHeight: "relaxed", letterSpacing: "normal", italic: null }
38692
+ },
38693
+ scale: "spacious"
38694
+ };
38695
+ var boldDisplayTypography = {
38696
+ body: {
38697
+ family: "Manrope, system-ui, sans-serif",
38698
+ size: "lg",
38699
+ weight: "regular",
38700
+ lineHeight: "relaxed",
38701
+ letterSpacing: "normal"
38702
+ },
38703
+ headings: {
38704
+ default: {
38705
+ family: '"TAN - PEARL", sans-serif',
38706
+ weight: "bold",
38707
+ lineHeight: "normal",
38708
+ letterSpacing: "tight",
38709
+ colorToken: "primary",
38710
+ italic: null,
38711
+ case: null
38712
+ },
38713
+ h1: { size: "xl", weight: "bold", lineHeight: "normal", letterSpacing: "tight", italic: null },
38714
+ h2: { size: "lg", weight: "bold", lineHeight: "normal", letterSpacing: "normal", italic: null },
38715
+ h3: { size: "md", weight: "bold", lineHeight: "normal", letterSpacing: "normal", italic: null }
38716
+ },
38717
+ scale: "balanced"
38718
+ };
38719
+ var typographyPresets = [
38720
+ defineTypographyPreset({
38721
+ id: "typography-preset:modern-sans",
38722
+ name: "Modern Sans",
38723
+ description: "Crisp, neutral type for clear service pages and practical editorial structure.",
38724
+ defaultFonts: { body: "Inter, system-ui, sans-serif", heading: "Inter, system-ui, sans-serif" },
38725
+ recommendedFonts: {
38726
+ body: ["Inter", "Source Sans 3", "IBM Plex Sans"],
38727
+ heading: ["Inter", "Manrope", "Source Sans 3"]
38728
+ },
38729
+ slotPolicies: { body: bodyReadablePolicy, heading: headingFlexiblePolicy },
38730
+ typography: modernSansTypography
38731
+ }),
38732
+ defineTypographyPreset({
38733
+ id: "typography-preset:warm-rounded",
38734
+ name: "Warm Rounded",
38735
+ description: "Soft, friendly type for welcoming studios, classes, and community businesses.",
38736
+ defaultFonts: { body: "Nunito Sans, system-ui, sans-serif", heading: "Nunito Sans, system-ui, sans-serif" },
38737
+ recommendedFonts: {
38738
+ body: ["Nunito Sans", "Atkinson Hyperlegible", "Lato"],
38739
+ heading: ["Nunito Sans", "Quicksand", "Manrope"]
38740
+ },
38741
+ slotPolicies: { body: bodyReadablePolicy, heading: headingFlexiblePolicy },
38742
+ typography: warmRoundedTypography
38743
+ }),
38744
+ defineTypographyPreset({
38745
+ id: "typography-preset:editorial-serif",
38746
+ name: "Editorial Serif",
38747
+ description: "Story-led type with warm reading rhythm and expressive headings.",
38748
+ defaultFonts: { body: "Lora, Georgia, serif", heading: "Playfair Display, Georgia, serif" },
38749
+ recommendedFonts: {
38750
+ body: ["Lora", "Source Serif 4", "Libre Baskerville"],
38751
+ heading: ["Playfair Display", "Cormorant Garamond", "Fraunces"]
38752
+ },
38753
+ slotPolicies: { body: bodyReadablePolicy, heading: displayHeadingPolicy },
38754
+ typography: editorialSerifTypography
38755
+ }),
38756
+ defineTypographyPreset({
38757
+ id: "typography-preset:classic-serif",
38758
+ name: "Classic Serif",
38759
+ description: "Measured, polished type for premium and established offers.",
38760
+ defaultFonts: { body: "Libre Baskerville, Georgia, serif", heading: "Cormorant Garamond, Georgia, serif" },
38761
+ recommendedFonts: {
38762
+ body: ["Libre Baskerville", "Source Serif 4", "Lora"],
38763
+ heading: ["Cormorant Garamond", "Playfair Display", "Libre Baskerville"]
38764
+ },
38765
+ slotPolicies: { body: bodyReadablePolicy, heading: displayHeadingPolicy },
38766
+ typography: classicSerifTypography
38767
+ }),
38768
+ defineTypographyPreset({
38769
+ id: "typography-preset:luxe-contrast",
38770
+ name: "Luxe Contrast",
38771
+ description: "A restrained sans body paired with elegant high-contrast headings.",
38772
+ defaultFonts: { body: "Manrope, system-ui, sans-serif", heading: "Cormorant Garamond, Georgia, serif" },
38773
+ recommendedFonts: {
38774
+ body: ["Manrope", "Inter", "Source Sans 3"],
38775
+ heading: ["Cormorant Garamond", "Playfair Display", "Bodoni Moda"]
38776
+ },
38777
+ slotPolicies: { body: bodyReadablePolicy, heading: displayHeadingPolicy },
38778
+ typography: luxeContrastTypography
38779
+ }),
38780
+ defineTypographyPreset({
38781
+ id: "typography-preset:bold-display",
38782
+ name: "Bold Display",
38783
+ description: "Punchy display headings with readable sans body copy for branded launches.",
38784
+ defaultFonts: { body: "Manrope, system-ui, sans-serif", heading: '"TAN - PEARL", sans-serif' },
38785
+ recommendedFonts: {
38786
+ body: ["Manrope", "Inter", "Space Grotesk"],
38787
+ heading: ["Anton", "Bebas Neue", "Archivo Black"]
38788
+ },
38789
+ slotPolicies: { body: bodyReadablePolicy, heading: displayHeadingPolicy },
38790
+ typography: boldDisplayTypography,
38791
+ heroTypography: {
38792
+ headlineSize: "6xl",
38793
+ headlineLineHeight: "tight",
38794
+ subheadlineSize: "editorial",
38795
+ subheadlineLineHeight: "normal",
38796
+ microHeadlineSize: "6xl",
38797
+ microHeadlineLineHeight: "tight",
38798
+ microSubheadlineSize: "xl",
38799
+ microSubheadlineLineHeight: "normal",
38800
+ responsive: {
38801
+ tablet: { headlineSize: "5xl" },
38802
+ mobile: { headlineSize: "4xl", subheadlineSize: "xl" }
38803
+ }
38804
+ }
38805
+ })
38806
+ ];
38807
+ var typographyPresetsById = new Map(
38808
+ typographyPresets.map((preset2) => [preset2.id, preset2])
38809
+ );
38810
+ function findTypographyPreset(id) {
38811
+ return typographyPresetsById.get(id);
38812
+ }
38813
+ function parsePersistedTypographyPresetId(value) {
38814
+ if (!value) {
38815
+ return { kind: "empty" };
38816
+ }
38817
+ if (typographyPresetIdValues.includes(value)) {
38818
+ return { kind: "known", id: asTypographyPresetId(value) };
38819
+ }
38820
+ return { kind: "unknown", raw: value };
38821
+ }
38822
+ function compileTypographySelection(input) {
38823
+ if (input.selection?.kind === "custom") {
38824
+ return {
38825
+ themeTypography: input.selection.typography,
38826
+ resolvedSelection: { kind: "custom" }
38827
+ };
38828
+ }
38829
+ const presetId = input.selection?.presetId ?? input.defaultPresetId;
38830
+ const preset2 = findTypographyPreset(presetId);
38831
+ if (!preset2) {
38832
+ throw new Error(`Unknown typography preset: ${presetId}`);
38833
+ }
38834
+ return {
38835
+ themeTypography: applyTypographyFontOverrides(
38836
+ preset2.typography,
38837
+ input.selection?.bodyFontOverride ?? null,
38838
+ input.selection?.headingFontOverride ?? null
38839
+ ),
38840
+ ...preset2.heroTypography ? { heroTypography: preset2.heroTypography } : {},
38841
+ resolvedSelection: {
38842
+ kind: "preset",
38843
+ presetId: preset2.id,
38844
+ bodyFontOverride: input.selection?.bodyFontOverride ?? null,
38845
+ headingFontOverride: input.selection?.headingFontOverride ?? null
38846
+ }
38847
+ };
38848
+ }
38849
+ function applyTypographyFontOverrides(typography, bodyFontOverride, headingFontOverride) {
38850
+ return {
38851
+ ...typography,
38852
+ body: {
38853
+ ...typography.body,
38854
+ family: bodyFontOverride ?? typography.body.family
38855
+ },
38856
+ headings: {
38857
+ ...typography.headings,
38858
+ default: {
38859
+ ...typography.headings.default,
38860
+ family: headingFontOverride ?? typography.headings.default.family
38861
+ }
38862
+ }
38863
+ };
38864
+ }
38865
+ function evaluateTypographyFontSlot(input) {
38866
+ const { capability, policy, slot } = input;
38867
+ if (capability.category === "unknown") {
38868
+ return { kind: "unknown", reason: "This font has limited metadata, so we cannot judge the fit yet." };
38869
+ }
38870
+ if (!policy.allowedCategories.includes(capability.category)) {
38871
+ return slot === "body" ? { kind: "risky", reason: "This style of font can be hard to read in longer body copy." } : { kind: "limited", reason: "This font may need a simpler supporting body font." };
38872
+ }
38873
+ if (slot === "body" && policy.requiresBoldForBody && !hasBoldVariant(capability)) {
38874
+ return { kind: "limited", reason: "This font may not include enough weight for emphasis." };
38875
+ }
38876
+ if (slot === "body" && policy.requiresItalicForBody && !hasItalicVariant(capability)) {
38877
+ return { kind: "limited", reason: "This font may not include italic styles for body text." };
38878
+ }
38879
+ if (policy.recommendedCategories.includes(capability.category)) {
38880
+ return { kind: "recommended", reason: "This font matches the preset treatment." };
38881
+ }
38882
+ return { kind: "compatible", reason: "This font can work with this slot." };
38883
+ }
38884
+ function hasBoldVariant(capability) {
38885
+ if (capability.variableWeightRange && capability.variableWeightRange.max >= BOLD_WEIGHT_THRESHOLD) {
38886
+ return true;
38887
+ }
38888
+ return capability.variants.some((variant) => /(^|[^0-9])(700|800|900|bold)/iu.test(variant));
38889
+ }
38890
+ function hasItalicVariant(capability) {
38891
+ return capability.variants.some((variant) => variant.toLowerCase().includes("italic"));
38892
+ }
38893
+
37443
38894
  // ../theme-core/src/site-styles/curatedSiteStyles.ts
37444
38895
  var curatedSiteStyleIdValues = [
37445
38896
  "site-style:calm-studio",
@@ -37452,6 +38903,7 @@ var curatedSiteStyleIdValues = [
37452
38903
  "site-style:personal-retreat-journal",
37453
38904
  "site-style:tactile-workshop",
37454
38905
  "site-style:modern-wellness",
38906
+ "site-style:soft-earth",
37455
38907
  "site-style:bold-launch",
37456
38908
  "site-style:south-west-twerk-school"
37457
38909
  ];
@@ -37528,6 +38980,15 @@ function uniqueContentFrameKinds() {
37528
38980
  }
37529
38981
  var generatedContentFrameKinds = uniqueContentFrameKinds();
37530
38982
  function defineCuratedSiteStyle(input) {
38983
+ const legacyHeaderLookIds = input.recommendedHeaderLookIds ?? ["clean-base"];
38984
+ const inferredHeaderCuration = inferHeaderCurationFromLegacyLooks(legacyHeaderLookIds);
38985
+ const typographyPresetChoices = input.typographyPresetChoices ?? defaultTypographyPresetChoicesForRecipe(input.tokenRecipes.typography);
38986
+ const defaultTypographyPresetId = input.defaultTypographyPresetId ? asTypographyPresetId(input.defaultTypographyPresetId) : typographyPresetChoices[0].id;
38987
+ if (!typographyPresetChoices.some((choice) => choice.id === defaultTypographyPresetId)) {
38988
+ throw new Error(
38989
+ `Default typography preset ${defaultTypographyPresetId} is not curated for site style ${input.id}.`
38990
+ );
38991
+ }
37531
38992
  return {
37532
38993
  id: asSiteStyleId(input.id),
37533
38994
  name: input.name,
@@ -37548,11 +39009,23 @@ function defineCuratedSiteStyle(input) {
37548
39009
  },
37549
39010
  ...input.themeOverrides ? { themeOverrides: input.themeOverrides } : {},
37550
39011
  recommendedAppearancePresetIds: (input.recommendedAppearancePresetIds ?? []).map(asAppearancePresetId),
37551
- recommendedHeaderLookIds: (input.recommendedHeaderLookIds ?? ["clean-base"]).map(asHeaderLookId),
39012
+ defaultHeaderSelection: input.defaultHeaderSelection ? {
39013
+ layoutId: asHeaderLayoutId(input.defaultHeaderSelection.layoutId),
39014
+ styleId: asHeaderStyleId(input.defaultHeaderSelection.styleId)
39015
+ } : inferredHeaderCuration.defaultHeaderSelection,
39016
+ recommendedHeaderLayoutChoices: input.recommendedHeaderLayoutChoices ?? inferredHeaderCuration.recommendedHeaderLayoutChoices,
39017
+ recommendedHeaderStyleChoicesByLayout: input.recommendedHeaderStyleChoicesByLayout ?? inferredHeaderCuration.recommendedHeaderStyleChoicesByLayout,
39018
+ discouragedHeaderSelections: input.discouragedHeaderSelections?.map((selection) => ({
39019
+ layoutId: asHeaderLayoutId(selection.layoutId),
39020
+ styleId: asHeaderStyleId(selection.styleId)
39021
+ })),
39022
+ recommendedHeaderLookIds: legacyHeaderLookIds.map(asHeaderLookId),
37552
39023
  // Empty is intentional: resolveFooterLook always appends its guaranteed fallback.
37553
39024
  recommendedFooterLookIds: (input.recommendedFooterLookIds ?? []).map(asFooterLookId),
37554
39025
  buttonPersonalityChoices: input.buttonPersonalityChoices,
37555
- paletteVariantChoices: input.paletteVariantChoices
39026
+ paletteVariantChoices: input.paletteVariantChoices,
39027
+ typographyPresetChoices,
39028
+ defaultTypographyPresetId
37556
39029
  };
37557
39030
  }
37558
39031
  function buttonChoice(id, note) {
@@ -37561,6 +39034,88 @@ function buttonChoice(id, note) {
37561
39034
  function paletteChoice(id, note) {
37562
39035
  return { id: asPaletteVariantId(id) };
37563
39036
  }
39037
+ function headerLayoutChoice(id, note) {
39038
+ return note ? { id: asHeaderLayoutId(id), note } : { id: asHeaderLayoutId(id) };
39039
+ }
39040
+ function headerStyleChoice(id, note) {
39041
+ return note ? { id: asHeaderStyleId(id), note } : { id: asHeaderStyleId(id) };
39042
+ }
39043
+ function headerLayoutRecordKey(id) {
39044
+ return id;
39045
+ }
39046
+ function uniqueHeaderLayoutChoices(choices) {
39047
+ const seen = /* @__PURE__ */ new Set();
39048
+ const unique = choices.filter((choice) => {
39049
+ if (seen.has(choice.id)) return false;
39050
+ seen.add(choice.id);
39051
+ return true;
39052
+ });
39053
+ const first2 = unique[0];
39054
+ if (!first2) {
39055
+ throw new Error("Expected at least one curated header layout choice.");
39056
+ }
39057
+ return [first2, ...unique.slice(1)];
39058
+ }
39059
+ function nonEmptyHeaderStyleChoices(choices, fallbackLayoutId) {
39060
+ const first2 = choices[0] ?? {
39061
+ id: getCompatibleHeaderStyleIds(fallbackLayoutId)[0] ?? asHeaderStyleId("minimal")
39062
+ };
39063
+ return [first2, ...choices.slice(1)];
39064
+ }
39065
+ function inferHeaderCurationFromLegacyLooks(lookIds) {
39066
+ const selections = lookIds.map((lookId) => resolveLegacyHeaderLookAlias(asHeaderLookId(lookId))).filter((selection) => Boolean(selection));
39067
+ const defaultHeaderSelection = selections[0] ?? {
39068
+ layoutId: asHeaderLayoutId("classic"),
39069
+ styleId: asHeaderStyleId("minimal")
39070
+ };
39071
+ const layoutChoices = uniqueHeaderLayoutChoices(
39072
+ selections.map((selection) => headerLayoutChoice(selection.layoutId))
39073
+ );
39074
+ const stylesByLayout = {};
39075
+ for (const layoutChoice of layoutChoices) {
39076
+ const styleChoices = selections.filter((selection) => selection.layoutId === layoutChoice.id).map((selection) => headerStyleChoice(selection.styleId));
39077
+ stylesByLayout[headerLayoutRecordKey(layoutChoice.id)] = nonEmptyHeaderStyleChoices(
39078
+ styleChoices,
39079
+ layoutChoice.id
39080
+ );
39081
+ }
39082
+ return {
39083
+ defaultHeaderSelection,
39084
+ recommendedHeaderLayoutChoices: layoutChoices,
39085
+ recommendedHeaderStyleChoicesByLayout: stylesByLayout
39086
+ };
39087
+ }
39088
+ function typographyChoice(id, note) {
39089
+ return { id: asTypographyPresetId(id) };
39090
+ }
39091
+ function defaultTypographyPresetChoicesForRecipe(recipe) {
39092
+ switch (recipe) {
39093
+ case "clean-sans":
39094
+ return [
39095
+ typographyChoice("typography-preset:modern-sans"),
39096
+ typographyChoice("typography-preset:luxe-contrast"),
39097
+ typographyChoice("typography-preset:bold-display")
39098
+ ];
39099
+ case "friendly-sans":
39100
+ return [
39101
+ typographyChoice("typography-preset:warm-rounded"),
39102
+ typographyChoice("typography-preset:modern-sans"),
39103
+ typographyChoice("typography-preset:editorial-serif")
39104
+ ];
39105
+ case "serif-editorial":
39106
+ return [
39107
+ typographyChoice("typography-preset:editorial-serif"),
39108
+ typographyChoice("typography-preset:classic-serif"),
39109
+ typographyChoice("typography-preset:warm-rounded")
39110
+ ];
39111
+ case "classic-serif":
39112
+ return [
39113
+ typographyChoice("typography-preset:classic-serif"),
39114
+ typographyChoice("typography-preset:luxe-contrast"),
39115
+ typographyChoice("typography-preset:editorial-serif")
39116
+ ];
39117
+ }
39118
+ }
37564
39119
  var curatedSiteStyles = [
37565
39120
  defineCuratedSiteStyle({
37566
39121
  id: "site-style:calm-studio",
@@ -37886,6 +39441,102 @@ var curatedSiteStyles = [
37886
39441
  paletteChoice("warm-neutral-clay")
37887
39442
  ]
37888
39443
  }),
39444
+ defineCuratedSiteStyle({
39445
+ id: "site-style:soft-earth",
39446
+ name: "Soft Earth",
39447
+ description: "Warm, grounded, and editorial for yoga studios, retreats, and wellbeing communities.",
39448
+ generationBrief: "Use cream space, terracotta CTAs, olive proof bands, natural imagery, generous but composed spacing, and editorial serif headings. Prefer a real intro section, image-led offering cards, warm community proof, and a simple two-column FAQ when content allows.",
39449
+ siteCreatorSelection: { kind: "site_creator_keyword_heuristic", priority: 45 },
39450
+ selectionKeywordRules: [
39451
+ { kind: "word", value: "meditation" },
39452
+ { kind: "word", value: "wellbeing" },
39453
+ { kind: "substring", value: "retreat" },
39454
+ { kind: "phrase", value: "yoga studio" },
39455
+ { kind: "phrase", value: "mindful movement" }
39456
+ ],
39457
+ tokenRecipes: {
39458
+ palette: "warm-neutral",
39459
+ contrast: "standard",
39460
+ radius: "soft",
39461
+ shadow: "subtle",
39462
+ typography: "serif-editorial",
39463
+ spacing: "airy",
39464
+ motion: "subtle"
39465
+ },
39466
+ compositionBudget: balancedBudget,
39467
+ themeOverrides: {
39468
+ typography: {
39469
+ body: {
39470
+ family: "Inter, system-ui, sans-serif",
39471
+ size: "md",
39472
+ weight: "regular",
39473
+ lineHeight: "relaxed",
39474
+ letterSpacing: "normal"
39475
+ },
39476
+ headings: {
39477
+ default: {
39478
+ family: '"Cormorant Garamond", Georgia, serif',
39479
+ weight: "regular",
39480
+ lineHeight: "normal",
39481
+ letterSpacing: "normal",
39482
+ colorToken: "text",
39483
+ italic: null,
39484
+ case: null
39485
+ },
39486
+ h1: {
39487
+ size: "xl",
39488
+ weight: "regular",
39489
+ lineHeight: "normal",
39490
+ letterSpacing: "normal",
39491
+ italic: null
39492
+ },
39493
+ h2: {
39494
+ size: "lg",
39495
+ weight: "regular",
39496
+ lineHeight: "normal",
39497
+ letterSpacing: "normal",
39498
+ italic: null
39499
+ },
39500
+ h3: {
39501
+ size: "md",
39502
+ weight: "regular",
39503
+ lineHeight: "normal",
39504
+ letterSpacing: "normal",
39505
+ italic: null
39506
+ }
39507
+ },
39508
+ scale: "majorThird"
39509
+ },
39510
+ bodyText: {
39511
+ intro: {
39512
+ paragraphSize: "default",
39513
+ headingSize: "editorial"
39514
+ }
39515
+ }
39516
+ },
39517
+ recommendedAppearancePresetIds: [
39518
+ "hero-brand-scrim",
39519
+ "intro-soft-earth-statement",
39520
+ "feature-cards-soft-earth-offerings",
39521
+ "testimonials-soft-earth-proof-band",
39522
+ "faq-soft-earth-two-column",
39523
+ "contact-form-panel"
39524
+ ],
39525
+ recommendedHeaderLookIds: ["centered-calm", "minimal-transparent", "editorial-line"],
39526
+ recommendedFooterLookIds: ["footer-muted-grounding", "site-footer-brand-two-band"],
39527
+ buttonPersonalityChoices: [
39528
+ buttonChoice("earth-pill"),
39529
+ buttonChoice("soft-pill"),
39530
+ buttonChoice("pebble"),
39531
+ buttonChoice("editorial-link")
39532
+ ],
39533
+ paletteVariantChoices: [
39534
+ paletteChoice("warm-neutral-soft-earth"),
39535
+ paletteChoice("warm-neutral-clay"),
39536
+ paletteChoice("warm-neutral-forest"),
39537
+ paletteChoice("soft-natural-sage")
39538
+ ]
39539
+ }),
37889
39540
  defineCuratedSiteStyle({
37890
39541
  id: "site-style:bold-launch",
37891
39542
  name: "Bold Launch",
@@ -37939,49 +39590,13 @@ var curatedSiteStyles = [
37939
39590
  motion: "expressive"
37940
39591
  },
37941
39592
  compositionBudget: expressiveBudget,
39593
+ typographyPresetChoices: [
39594
+ typographyChoice("typography-preset:bold-display"),
39595
+ typographyChoice("typography-preset:modern-sans"),
39596
+ typographyChoice("typography-preset:luxe-contrast")
39597
+ ],
39598
+ defaultTypographyPresetId: "typography-preset:bold-display",
37942
39599
  themeOverrides: {
37943
- typography: {
37944
- body: {
37945
- family: "Manrope, system-ui, sans-serif",
37946
- size: "lg",
37947
- weight: "regular",
37948
- lineHeight: "relaxed",
37949
- letterSpacing: "normal"
37950
- },
37951
- headings: {
37952
- default: {
37953
- family: '"TAN - PEARL", sans-serif',
37954
- weight: "bold",
37955
- lineHeight: "normal",
37956
- letterSpacing: "tight",
37957
- colorToken: "primary",
37958
- italic: null,
37959
- case: null
37960
- },
37961
- h1: {
37962
- size: "xl",
37963
- weight: "bold",
37964
- lineHeight: "normal",
37965
- letterSpacing: "tight",
37966
- italic: null
37967
- },
37968
- h2: {
37969
- size: "lg",
37970
- weight: "bold",
37971
- lineHeight: "normal",
37972
- letterSpacing: "normal",
37973
- italic: null
37974
- },
37975
- h3: {
37976
- size: "md",
37977
- weight: "bold",
37978
- lineHeight: "normal",
37979
- letterSpacing: "normal",
37980
- italic: null
37981
- }
37982
- },
37983
- scale: "balanced"
37984
- },
37985
39600
  bodyText: {
37986
39601
  intro: {
37987
39602
  paragraphSize: "editorial",
@@ -38185,6 +39800,8 @@ var repairActionsByIssueKind = {
38185
39800
  "unsupported-testimonial-card-treatment": ["fallback-testimonial-card-treatment"],
38186
39801
  "unsupported-tile-treatment": ["fallback-tile-treatment"],
38187
39802
  "unsupported-eyebrow-treatment": ["fallback-eyebrow-treatment"],
39803
+ "unsupported-heading-decoration": ["fallback-heading-decoration"],
39804
+ "unsupported-accordion-icon-treatment": ["fallback-accordion-icon-treatment"],
38188
39805
  "image-surface-treatment-without-image-surface": ["fallback-image-surface-treatment"],
38189
39806
  "image-surface-motion-without-image-surface": ["fallback-image-surface-motion"],
38190
39807
  "hero-legibility-overridden-by-image-surface-treatment": ["remove-hero-legibility"],
@@ -38215,6 +39832,12 @@ function supportsTileTreatment(capability, treatment) {
38215
39832
  function supportsEyebrowTreatment(capability, treatment) {
38216
39833
  return capability.eyebrowTreatments.includes(treatment);
38217
39834
  }
39835
+ function supportsHeadingDecoration(capability, headingDecoration) {
39836
+ return headingDecoration.family === "none" || Boolean(capability.headingDecorations?.includes(headingDecoration.family));
39837
+ }
39838
+ function supportsAccordionIconTreatment(capability, treatment) {
39839
+ return Boolean(capability.accordionIconSets?.includes(treatment.iconSet));
39840
+ }
38218
39841
  function isDecorativeTransition(transition) {
38219
39842
  return transition !== "none";
38220
39843
  }
@@ -38229,7 +39852,9 @@ var blockDesignFallback = {
38229
39852
  imageSurfaceMotion: "static",
38230
39853
  testimonialCardTreatment: "default",
38231
39854
  tileTreatment: "default",
38232
- eyebrowTreatment: "plain"
39855
+ eyebrowTreatment: "plain",
39856
+ headingDecoration: noHeadingDecoration,
39857
+ accordionIconTreatment: null
38233
39858
  };
38234
39859
  function blockDesignRequest(block) {
38235
39860
  return {
@@ -38243,7 +39868,9 @@ function blockDesignRequest(block) {
38243
39868
  imageSurfaceMotion: block.imageSurfaceMotion,
38244
39869
  testimonialCardTreatment: block.testimonialCardTreatment,
38245
39870
  tileTreatment: block.tileTreatment,
38246
- eyebrowTreatment: block.eyebrowTreatment
39871
+ eyebrowTreatment: block.eyebrowTreatment,
39872
+ headingDecoration: block.headingDecoration,
39873
+ accordionIconTreatment: block.accordionIconTreatment
38247
39874
  };
38248
39875
  }
38249
39876
  function resolveBlockDesignPlan(input) {
@@ -38261,6 +39888,8 @@ function resolveBlockDesignPlan(input) {
38261
39888
  let appliedTestimonialCardTreatment = block.testimonialCardTreatment ?? "default";
38262
39889
  let appliedTileTreatment = block.tileTreatment ?? "default";
38263
39890
  let appliedEyebrowTreatment = block.eyebrowTreatment ?? "plain";
39891
+ let appliedHeadingDecoration = block.headingDecoration ?? noHeadingDecoration;
39892
+ let appliedAccordionIconTreatment = block.accordionIconTreatment ?? null;
38264
39893
  if (!capability) {
38265
39894
  issues.push({
38266
39895
  kind: "missing-block-design-capability",
@@ -38285,7 +39914,9 @@ function resolveBlockDesignPlan(input) {
38285
39914
  appliedImageSurfaceMotion: blockDesignFallback.imageSurfaceMotion,
38286
39915
  appliedTestimonialCardTreatment: blockDesignFallback.testimonialCardTreatment,
38287
39916
  appliedTileTreatment: blockDesignFallback.tileTreatment,
38288
- appliedEyebrowTreatment: blockDesignFallback.eyebrowTreatment
39917
+ appliedEyebrowTreatment: blockDesignFallback.eyebrowTreatment,
39918
+ appliedHeadingDecoration: blockDesignFallback.headingDecoration,
39919
+ appliedAccordionIconTreatment: blockDesignFallback.accordionIconTreatment
38289
39920
  };
38290
39921
  }
38291
39922
  if (capability.kind === "not-designed") {
@@ -38313,7 +39944,9 @@ function resolveBlockDesignPlan(input) {
38313
39944
  appliedImageSurfaceMotion: blockDesignFallback.imageSurfaceMotion,
38314
39945
  appliedTestimonialCardTreatment: blockDesignFallback.testimonialCardTreatment,
38315
39946
  appliedTileTreatment: blockDesignFallback.tileTreatment,
38316
- appliedEyebrowTreatment: blockDesignFallback.eyebrowTreatment
39947
+ appliedEyebrowTreatment: blockDesignFallback.eyebrowTreatment,
39948
+ appliedHeadingDecoration: blockDesignFallback.headingDecoration,
39949
+ appliedAccordionIconTreatment: blockDesignFallback.accordionIconTreatment
38317
39950
  };
38318
39951
  }
38319
39952
  if (capability.sectionSurfaces === "unsupported") {
@@ -38442,6 +40075,36 @@ function resolveBlockDesignPlan(input) {
38442
40075
  allowedRepairActions: repairActionsForIssue("unsupported-eyebrow-treatment")
38443
40076
  });
38444
40077
  }
40078
+ if (!supportsHeadingDecoration(capability, appliedHeadingDecoration)) {
40079
+ const requested = appliedHeadingDecoration;
40080
+ appliedHeadingDecoration = noHeadingDecoration;
40081
+ issues.push({
40082
+ kind: "unsupported-heading-decoration",
40083
+ blockId: block.blockId,
40084
+ blockKind: block.blockKind,
40085
+ purpose: block.purpose,
40086
+ requested,
40087
+ fallback: appliedHeadingDecoration,
40088
+ policy: input.policy,
40089
+ severity: designIssueSeverityForPolicy(input.policy),
40090
+ allowedRepairActions: repairActionsForIssue("unsupported-heading-decoration")
40091
+ });
40092
+ }
40093
+ if (appliedAccordionIconTreatment && !supportsAccordionIconTreatment(capability, appliedAccordionIconTreatment)) {
40094
+ const requested = appliedAccordionIconTreatment;
40095
+ appliedAccordionIconTreatment = null;
40096
+ issues.push({
40097
+ kind: "unsupported-accordion-icon-treatment",
40098
+ blockId: block.blockId,
40099
+ blockKind: block.blockKind,
40100
+ purpose: block.purpose,
40101
+ requested,
40102
+ fallback: appliedAccordionIconTreatment,
40103
+ policy: input.policy,
40104
+ severity: designIssueSeverityForPolicy(input.policy),
40105
+ allowedRepairActions: repairActionsForIssue("unsupported-accordion-icon-treatment")
40106
+ });
40107
+ }
38445
40108
  if (appliedSectionSurface !== "hero-image" && appliedImageSurfaceTreatment.kind !== "none") {
38446
40109
  const requested = appliedImageSurfaceTreatment;
38447
40110
  appliedImageSurfaceTreatment = { kind: "none" };
@@ -38513,7 +40176,9 @@ function resolveBlockDesignPlan(input) {
38513
40176
  appliedImageSurfaceMotion,
38514
40177
  appliedTestimonialCardTreatment,
38515
40178
  appliedTileTreatment,
38516
- appliedEyebrowTreatment
40179
+ appliedEyebrowTreatment,
40180
+ appliedHeadingDecoration,
40181
+ appliedAccordionIconTreatment
38517
40182
  };
38518
40183
  });
38519
40184
  const transitionSafeBlocks = blocks.map((block, index2) => {
@@ -39132,7 +40797,9 @@ function compileSectionStyles(input) {
39132
40797
  ...background ? { background } : {},
39133
40798
  ...sectionMinHeightForIntent(input.sectionHeight, input.surface),
39134
40799
  ...tileTreatmentForSection(input.tileTreatment),
39135
- ...eyebrowTreatmentForSection(input.eyebrowTreatment)
40800
+ ...eyebrowTreatmentForSection(input.eyebrowTreatment),
40801
+ ...headingDecorationForSection(input.headingDecoration),
40802
+ ...accordionIconTreatmentForSection(input.accordionIconTreatment)
39136
40803
  });
39137
40804
  }
39138
40805
  function tileTreatmentForSection(tileTreatment) {
@@ -39141,6 +40808,12 @@ function tileTreatmentForSection(tileTreatment) {
39141
40808
  function eyebrowTreatmentForSection(eyebrowTreatment) {
39142
40809
  return eyebrowTreatment === "plain" ? {} : { eyebrowTreatment };
39143
40810
  }
40811
+ function headingDecorationForSection(headingDecoration) {
40812
+ return !headingDecoration || headingDecoration.family === "none" ? {} : { headingDecoration };
40813
+ }
40814
+ function accordionIconTreatmentForSection(accordionIconTreatment) {
40815
+ return !accordionIconTreatment ? {} : { accordionIconTreatment };
40816
+ }
39144
40817
  function sectionMinHeightForIntent(sectionHeight, surface) {
39145
40818
  if (sectionHeight === "default") {
39146
40819
  return surface === "hero-image" ? { minHeight: "hero" } : {};
@@ -39368,7 +41041,9 @@ function compileBlockRuntimeFields(input) {
39368
41041
  imageSurfaceTreatment: input.block.appliedImageSurfaceTreatment,
39369
41042
  imageSurfaceMotion: input.block.appliedImageSurfaceMotion,
39370
41043
  tileTreatment: input.block.appliedTileTreatment,
39371
- eyebrowTreatment: input.block.appliedEyebrowTreatment
41044
+ eyebrowTreatment: input.block.appliedEyebrowTreatment,
41045
+ headingDecoration: input.block.appliedHeadingDecoration,
41046
+ accordionIconTreatment: input.block.appliedAccordionIconTreatment
39372
41047
  }),
39373
41048
  ...containerStyles ? { _containerStyles: containerStyles } : {},
39374
41049
  ...cardStyles ? { _cardStyles: cardStyles } : {},
@@ -39616,12 +41291,52 @@ function applySiteStyleThemeOverrides(theme, siteStyle) {
39616
41291
  ...overrides.inputs ? { inputs: overrides.inputs } : {}
39617
41292
  });
39618
41293
  }
39619
- function applySiteChromeLooks(theme, siteStyle, headerLookId, footerLookId, headerSelectionContext, footerSelectionContext) {
41294
+ function applyTypographySelectionToTheme(theme, compiledTypography) {
41295
+ return themeSchema.parse({
41296
+ ...theme,
41297
+ typography: compiledTypography.themeTypography,
41298
+ ...compiledTypography.heroTypography ? {
41299
+ hero: {
41300
+ ...theme.hero,
41301
+ typography: mergeHeroTypographyOverride(
41302
+ theme.hero?.typography,
41303
+ compiledTypography.heroTypography
41304
+ )
41305
+ }
41306
+ } : {}
41307
+ });
41308
+ }
41309
+ function canonicalHeaderSelectionInput(layoutId, styleId) {
41310
+ if (layoutId === void 0 || layoutId === null || styleId === void 0 || styleId === null) {
41311
+ return { kind: "legacy" };
41312
+ }
41313
+ return {
41314
+ kind: "canonical",
41315
+ selection: { layoutId, styleId }
41316
+ };
41317
+ }
41318
+ function applySiteChromeLooks({
41319
+ theme,
41320
+ siteStyle,
41321
+ headerLookId,
41322
+ headerLayoutId,
41323
+ headerStyleId,
41324
+ footerLookId,
41325
+ headerSelectionContext,
41326
+ footerSelectionContext
41327
+ }) {
41328
+ const canonicalHeaderSelection = canonicalHeaderSelectionInput(headerLayoutId, headerStyleId);
39620
41329
  const headerSelection = resolveHeaderLook({
39621
41330
  theme,
39622
41331
  recommendedLookIds: headerLookId ? [headerLookId] : siteStyle.recommendedHeaderLookIds,
39623
41332
  context: headerSelectionContext
39624
41333
  });
41334
+ const headerLayoutStyleSelection = canonicalHeaderSelection.kind === "canonical" ? resolveHeaderLayoutStyleSelection({
41335
+ layoutId: canonicalHeaderSelection.selection.layoutId,
41336
+ styleId: canonicalHeaderSelection.selection.styleId
41337
+ }).selection : resolveLegacyHeaderLookAlias(headerSelection.selectedLookId) ?? siteStyle.defaultHeaderSelection;
41338
+ const header = canonicalHeaderSelection.kind === "canonical" ? compileHeaderLayoutStyleSelection(theme, headerLayoutStyleSelection) : headerSelection.header;
41339
+ const resolvedHeaderLookId = canonicalHeaderSelection.kind === "canonical" ? findLegacyHeaderLookIdForSelection(headerLayoutStyleSelection) : headerSelection.selectedLookId;
39625
41340
  const footerSelection = resolveFooterLook({
39626
41341
  theme,
39627
41342
  recommendedLookIds: footerLookId ? [footerLookId] : siteStyle.recommendedFooterLookIds,
@@ -39629,12 +41344,14 @@ function applySiteChromeLooks(theme, siteStyle, headerLookId, footerLookId, head
39629
41344
  });
39630
41345
  const themeWithChrome = themeSchema.parse({
39631
41346
  ...theme,
39632
- header: headerSelection.header,
41347
+ header,
39633
41348
  footer: footerSelection.footer
39634
41349
  });
39635
41350
  return {
39636
41351
  theme: themeWithChrome,
39637
41352
  headerSelection,
41353
+ headerLayoutStyleSelection,
41354
+ resolvedHeaderLookId,
39638
41355
  footerSelection
39639
41356
  };
39640
41357
  }
@@ -39644,7 +41361,13 @@ function compileSiteThemeFromSelections(input) {
39644
41361
  buttonPersonalityId,
39645
41362
  paletteVariantId,
39646
41363
  paletteOverrides,
41364
+ typographyPresetId,
41365
+ typographyBodyFontOverride,
41366
+ typographyHeadingFontOverride,
41367
+ typographySelection,
39647
41368
  headerLookId,
41369
+ headerLayoutId,
41370
+ headerStyleId,
39648
41371
  footerLookId,
39649
41372
  headerSelectionContext,
39650
41373
  footerSelectionContext
@@ -39678,33 +41401,55 @@ function compileSiteThemeFromSelections(input) {
39678
41401
  fellBackTo: paletteResult.resolved
39679
41402
  });
39680
41403
  }
41404
+ const typographyResult = resolveTypographySelection({
41405
+ siteStyle,
41406
+ typographyPresetId,
41407
+ typographyBodyFontOverride,
41408
+ typographyHeadingFontOverride,
41409
+ typographySelection
41410
+ });
41411
+ warnings.push(...typographyResult.warnings);
39681
41412
  const theme = compileTokenRecipes(siteStyle.template.tokenRecipes, {
39682
41413
  buttonPersonalityId: personalityResult.resolved,
39683
41414
  paletteVariantId: paletteResult.resolved,
39684
41415
  paletteOverrides: paletteOverrides ?? void 0
39685
41416
  });
39686
- const themeWithSiteStyleOverrides = applySiteStyleThemeOverrides(
41417
+ const themeWithTypography = applyTypographySelectionToTheme(
39687
41418
  theme,
41419
+ typographyResult.compiled
41420
+ );
41421
+ const themeWithSiteStyleOverrides = applySiteStyleThemeOverrides(
41422
+ themeWithTypography,
39688
41423
  siteStyle
39689
41424
  );
39690
- const siteChromeResult = applySiteChromeLooks(
39691
- themeWithSiteStyleOverrides,
41425
+ const siteChromeResult = applySiteChromeLooks({
41426
+ theme: themeWithSiteStyleOverrides,
39692
41427
  siteStyle,
39693
41428
  headerLookId,
41429
+ headerLayoutId,
41430
+ headerStyleId,
39694
41431
  footerLookId,
39695
41432
  headerSelectionContext,
39696
41433
  footerSelectionContext
39697
- );
41434
+ });
39698
41435
  return {
39699
41436
  theme: withSiteStyleMetadata(siteChromeResult.theme, siteStyle),
39700
41437
  requestedSelections: {
39701
41438
  headerLookId: headerLookId ?? null,
41439
+ headerLayoutId: headerLayoutId ?? null,
41440
+ headerStyleId: headerStyleId ?? null,
39702
41441
  footerLookId: footerLookId ?? null
39703
41442
  },
39704
41443
  resolvedSelections: {
39705
41444
  buttonPersonalityId: personalityResult.resolved,
39706
41445
  paletteVariantId: paletteResult.resolved,
39707
- headerLookId: siteChromeResult.headerSelection.selectedLookId,
41446
+ typographySelection: typographyResult.compiled.resolvedSelection,
41447
+ typographyPresetId: typographyResult.compiled.resolvedSelection.kind === "preset" ? typographyResult.compiled.resolvedSelection.presetId : null,
41448
+ typographyBodyFontOverride: typographyResult.compiled.resolvedSelection.kind === "preset" ? typographyResult.compiled.resolvedSelection.bodyFontOverride : null,
41449
+ typographyHeadingFontOverride: typographyResult.compiled.resolvedSelection.kind === "preset" ? typographyResult.compiled.resolvedSelection.headingFontOverride : null,
41450
+ headerLookId: siteChromeResult.resolvedHeaderLookId,
41451
+ headerLayoutId: siteChromeResult.headerLayoutStyleSelection.layoutId,
41452
+ headerStyleId: siteChromeResult.headerLayoutStyleSelection.styleId,
39708
41453
  footerLookId: siteChromeResult.footerSelection.selectedLookId
39709
41454
  },
39710
41455
  headerSelection: siteChromeResult.headerSelection,
@@ -39712,6 +41457,62 @@ function compileSiteThemeFromSelections(input) {
39712
41457
  warnings
39713
41458
  };
39714
41459
  }
41460
+ function resolveTypographySelection(input) {
41461
+ if (input.typographySelection?.kind === "custom") {
41462
+ return {
41463
+ compiled: compileTypographySelection({
41464
+ selection: input.typographySelection,
41465
+ defaultPresetId: input.siteStyle.defaultTypographyPresetId
41466
+ }),
41467
+ warnings: []
41468
+ };
41469
+ }
41470
+ const requestedPresetId = input.typographySelection?.kind === "preset" ? input.typographySelection.presetId : input.typographyPresetId ?? null;
41471
+ const parsed = parsePersistedTypographyPresetId(requestedPresetId);
41472
+ const resolved = resolveTypographyPresetRequest(parsed, input.siteStyle);
41473
+ const selection = {
41474
+ kind: "preset",
41475
+ presetId: resolved.presetId,
41476
+ bodyFontOverride: input.typographySelection?.kind === "preset" ? input.typographySelection.bodyFontOverride : input.typographyBodyFontOverride ?? null,
41477
+ headingFontOverride: input.typographySelection?.kind === "preset" ? input.typographySelection.headingFontOverride : input.typographyHeadingFontOverride ?? null
41478
+ };
41479
+ return {
41480
+ compiled: compileTypographySelection({
41481
+ selection,
41482
+ defaultPresetId: input.siteStyle.defaultTypographyPresetId
41483
+ }),
41484
+ warnings: resolved.warning ? [resolved.warning] : []
41485
+ };
41486
+ }
41487
+ function resolveTypographyPresetRequest(parsed, siteStyle) {
41488
+ switch (parsed.kind) {
41489
+ case "empty":
41490
+ return { presetId: siteStyle.defaultTypographyPresetId, warning: null };
41491
+ case "unknown":
41492
+ return {
41493
+ presetId: siteStyle.defaultTypographyPresetId,
41494
+ warning: {
41495
+ kind: "rejected-typography-preset",
41496
+ requested: parsed.raw,
41497
+ fellBackTo: siteStyle.defaultTypographyPresetId,
41498
+ reason: "unknown"
41499
+ }
41500
+ };
41501
+ case "known":
41502
+ if (siteStyle.typographyPresetChoices.some((choice) => choice.id === parsed.id)) {
41503
+ return { presetId: parsed.id, warning: null };
41504
+ }
41505
+ return {
41506
+ presetId: siteStyle.defaultTypographyPresetId,
41507
+ warning: {
41508
+ kind: "rejected-typography-preset",
41509
+ requested: parsed.id,
41510
+ fellBackTo: siteStyle.defaultTypographyPresetId,
41511
+ reason: "not-curated-for-style"
41512
+ }
41513
+ };
41514
+ }
41515
+ }
39715
41516
  function toCuratedRequest(parsed) {
39716
41517
  switch (parsed.kind) {
39717
41518
  case "known":
@@ -43857,8 +45658,9 @@ var faqAccordionFragment = defineFragment({
43857
45658
  },
43858
45659
  fallback: "rb-faq-item"
43859
45660
  },
43860
- iconStyle: { $bind: { from: "theme.accordions.icon.style" } }
43861
- // Pass icon style from theme
45661
+ iconStyle: { $bind: { from: "theme.accordions.icon.style" } },
45662
+ // Legacy theme accordion style
45663
+ iconTreatment: { $bind: { from: "content._sectionStyles.accordionIconTreatment" } }
43862
45664
  },
43863
45665
  triggerFrom: "faqItem.question",
43864
45666
  contentFrom: "faqItem.answer"
@@ -45035,6 +46837,334 @@ var heroBlockDefinition = {
45035
46837
  manifest: heroManifest
45036
46838
  };
45037
46839
 
46840
+ // ../blocks/src/system/fields/aspectRatio.ts
46841
+ var standardAspectRatioOptions = [
46842
+ { value: "auto", label: "Auto (original)" },
46843
+ { value: "16/9", label: "16:9 (Landscape)" },
46844
+ { value: "4/3", label: "4:3 (Standard)" },
46845
+ { value: "1/1", label: "1:1 (Square)" },
46846
+ { value: "3/4", label: "3:4 (Portrait)" }
46847
+ ];
46848
+ function createAspectRatioField(options = {}) {
46849
+ return {
46850
+ id: options.id ?? "aspectRatio",
46851
+ type: "select",
46852
+ label: options.label ?? "Aspect ratio",
46853
+ ...options.description ? { description: options.description } : {},
46854
+ required: false,
46855
+ defaultValue: options.defaultValue ?? "auto",
46856
+ multiple: false,
46857
+ options: [...standardAspectRatioOptions],
46858
+ ui: {
46859
+ intent: options.uiIntent ?? "display",
46860
+ ...options.visibleWhen ? { visibleWhen: options.visibleWhen } : {}
46861
+ }
46862
+ };
46863
+ }
46864
+
46865
+ // ../blocks/src/system/fields/imageLayout.ts
46866
+ function createImageColSizeField(options = {}) {
46867
+ const {
46868
+ id = "imageColSize",
46869
+ label = "Image column size",
46870
+ description = "Controls how large the image/thumbnail column is at desktop breakpoints.",
46871
+ defaultValue: defaultValue2 = "1/3",
46872
+ uiIntent = "display",
46873
+ visibleWhen
46874
+ } = options;
46875
+ return {
46876
+ id,
46877
+ type: "select",
46878
+ label,
46879
+ description,
46880
+ required: false,
46881
+ defaultValue: defaultValue2,
46882
+ multiple: false,
46883
+ options: [
46884
+ { value: "1/4", label: "Small (1/4)" },
46885
+ { value: "1/3", label: "Medium (1/3)" },
46886
+ { value: "2/5", label: "Large (2/5)" },
46887
+ { value: "1/2", label: "Extra large (1/2)" },
46888
+ { value: "2/3", label: "Huge (2/3)" }
46889
+ ],
46890
+ ui: {
46891
+ intent: uiIntent,
46892
+ ...visibleWhen ? { visibleWhen } : {}
46893
+ }
46894
+ };
46895
+ }
46896
+ function createImagePositionField(options = {}) {
46897
+ const {
46898
+ id = "imagePosition",
46899
+ label = "Image position",
46900
+ description = "Choose which side the image appears on.",
46901
+ defaultValue: defaultValue2 = "left",
46902
+ includeAlternate = false,
46903
+ uiIntent = "display",
46904
+ visibleWhen
46905
+ } = options;
46906
+ const positionOptions = [
46907
+ { value: "left", label: "Left" },
46908
+ { value: "right", label: "Right" },
46909
+ ...includeAlternate ? [{ value: "alternate", label: "Alternate" }] : []
46910
+ ];
46911
+ return {
46912
+ id,
46913
+ type: "select",
46914
+ label,
46915
+ description,
46916
+ required: false,
46917
+ defaultValue: defaultValue2,
46918
+ multiple: false,
46919
+ // Spread to get a mutable array type without unsafe casts.
46920
+ options: [...positionOptions],
46921
+ ui: {
46922
+ intent: uiIntent,
46923
+ ...visibleWhen ? { visibleWhen } : {}
46924
+ }
46925
+ };
46926
+ }
46927
+
46928
+ // ../blocks/src/system/blocks/intro.ts
46929
+ function introHeading(className) {
46930
+ return text(
46931
+ {
46932
+ as: "h2",
46933
+ className
46934
+ },
46935
+ when("content.title"),
46936
+ bind("content.title")
46937
+ );
46938
+ }
46939
+ function introBody(className = "rb-prose rb-max-w-none") {
46940
+ return richText({ className }, bind("content.body"));
46941
+ }
46942
+ function introCtas(justify = "start") {
46943
+ return ctaRow({
46944
+ justify,
46945
+ gap: "md",
46946
+ containerClassName: "rb-mt-2"
46947
+ });
46948
+ }
46949
+ function introCopyStack(options = {}) {
46950
+ return stack(
46951
+ {
46952
+ gap: "md",
46953
+ className: options.className ?? "rb-intro-copy"
46954
+ },
46955
+ [
46956
+ introHeading(options.headingClassName ?? "rb-intro-title"),
46957
+ introBody(options.bodyClassName),
46958
+ introCtas(options.ctaJustify)
46959
+ ]
46960
+ );
46961
+ }
46962
+ var introMedia = media(
46963
+ {
46964
+ className: "rb-intro-media rb-w-full rb-h-auto rb-object-cover",
46965
+ style: {
46966
+ aspectRatio: { $bind: { from: "content.aspectRatio" } }
46967
+ }
46968
+ },
46969
+ bind("content.media")
46970
+ );
46971
+ var centeredCopyLayout = styledSection({
46972
+ children: styledContainer({
46973
+ rootType: "stack",
46974
+ rootProps: { gap: "lg" },
46975
+ children: [
46976
+ introCopyStack({
46977
+ className: "rb-intro-copy rb-mx-auto rb-max-w-3xl rb-text-center",
46978
+ headingClassName: "rb-intro-title rb-text-center",
46979
+ bodyClassName: "rb-prose rb-mx-auto rb-max-w-none",
46980
+ ctaJustify: "center"
46981
+ })
46982
+ ]
46983
+ }),
46984
+ baseClass: "",
46985
+ spacing: "medium"
46986
+ });
46987
+ var statementCopyLayout = styledSection({
46988
+ children: styledContainer({
46989
+ children: [
46990
+ el(
46991
+ "div",
46992
+ {
46993
+ className: "rb-intro rb-intro-statement rb-grid rb-grid-cols-1 rb-gap-8 rb-md-grid-cols-2 rb-md-items-start"
46994
+ },
46995
+ [
46996
+ introHeading("rb-intro-title rb-max-w-xl"),
46997
+ stack({ gap: "md", className: "rb-intro-copy rb-max-w-xl" }, [
46998
+ introBody(),
46999
+ introCtas("start")
47000
+ ])
47001
+ ]
47002
+ )
47003
+ ]
47004
+ }),
47005
+ baseClass: "",
47006
+ spacing: "medium"
47007
+ });
47008
+ var statementMediaLayout = styledSection({
47009
+ children: styledContainer({
47010
+ children: [
47011
+ el(
47012
+ "div",
47013
+ {
47014
+ className: "rb-intro rb-intro-statement-media rb-grid rb-grid-cols-1 rb-gap-8 rb-lg-grid-cols-3 rb-lg-items-center"
47015
+ },
47016
+ [
47017
+ introHeading("rb-intro-title rb-max-w-xl"),
47018
+ stack({ gap: "md", className: "rb-intro-copy rb-max-w-xl" }, [
47019
+ introBody(),
47020
+ introCtas("start")
47021
+ ]),
47022
+ el("div", { className: "rb-intro-media-wrap rb-w-full" }, [introMedia], when("content.media"))
47023
+ ]
47024
+ )
47025
+ ]
47026
+ }),
47027
+ baseClass: "",
47028
+ spacing: "medium"
47029
+ });
47030
+ var mediaCopyLayout = styledSection({
47031
+ children: styledContainer({
47032
+ children: [
47033
+ responsiveTwoColumn({
47034
+ image: el("div", { className: "rb-intro-media-wrap rb-w-full" }, [introMedia]),
47035
+ text: introCopyStack({
47036
+ className: "rb-intro-copy rb-max-w-xl",
47037
+ headingClassName: "rb-intro-title"
47038
+ }),
47039
+ ratioFrom: "content.ratio",
47040
+ imagePositionFrom: "content.imagePosition",
47041
+ gapFrom: "content.gap",
47042
+ gapFallback: "comfortable",
47043
+ imageWrapperClassName: "rb-w-full rb-shrink-0",
47044
+ textWrapperClassName: "rb-w-full rb-min-w-0 rb-flex-1 rb-self-center"
47045
+ })
47046
+ ]
47047
+ }),
47048
+ baseClass: "",
47049
+ spacing: "medium"
47050
+ });
47051
+ var introConfig = {
47052
+ id: "block.intro",
47053
+ title: "Intro",
47054
+ category: "layout",
47055
+ includeContainerStyles: true,
47056
+ titleSource: "title",
47057
+ additionalFields: [
47058
+ {
47059
+ id: "title",
47060
+ type: "text",
47061
+ label: "Statement",
47062
+ required: false,
47063
+ multiline: true,
47064
+ maxLength: 160
47065
+ },
47066
+ {
47067
+ id: "body",
47068
+ type: "richText",
47069
+ label: "Text",
47070
+ required: true,
47071
+ ui: {
47072
+ richTextVariant: "limited"
47073
+ }
47074
+ },
47075
+ {
47076
+ id: "media",
47077
+ type: "media",
47078
+ label: "Media",
47079
+ required: false,
47080
+ mediaKinds: ["image"],
47081
+ ui: {
47082
+ intent: "content",
47083
+ visibleWhen: { field: "variant", notEquals: "statement-copy" }
47084
+ }
47085
+ },
47086
+ createImagePositionField({
47087
+ id: "imagePosition",
47088
+ label: "Image position",
47089
+ defaultValue: "left",
47090
+ uiIntent: "display",
47091
+ visibleWhen: { field: "variant", equals: "media-copy" }
47092
+ }),
47093
+ {
47094
+ id: "gap",
47095
+ type: "select",
47096
+ label: "Gap between media and text",
47097
+ required: false,
47098
+ defaultValue: "comfortable",
47099
+ multiple: false,
47100
+ options: [
47101
+ { value: "none", label: "None" },
47102
+ { value: "compact", label: "Compact" },
47103
+ { value: "cozy", label: "Cozy" },
47104
+ { value: "medium", label: "Medium" },
47105
+ { value: "comfortable", label: "Comfortable" },
47106
+ { value: "spacious", label: "Spacious" }
47107
+ ],
47108
+ ui: {
47109
+ intent: "display",
47110
+ visibleWhen: { field: "variant", equals: "media-copy" }
47111
+ }
47112
+ },
47113
+ createImageColSizeField({
47114
+ id: "ratio",
47115
+ label: "Media column size",
47116
+ defaultValue: "1/2",
47117
+ uiIntent: "display",
47118
+ visibleWhen: { field: "variant", equals: "media-copy" }
47119
+ }),
47120
+ createAspectRatioField({
47121
+ id: "aspectRatio",
47122
+ label: "Media aspect ratio",
47123
+ description: "Crop media to a consistent aspect ratio.",
47124
+ defaultValue: "auto",
47125
+ visibleWhen: { field: "media", notEquals: null }
47126
+ }),
47127
+ createCtasRepeater({
47128
+ label: "Calls to action",
47129
+ itemLabel: "CTA",
47130
+ maxItems: 2
47131
+ })
47132
+ ],
47133
+ layout: centeredCopyLayout,
47134
+ variants: {
47135
+ "centered-copy": centeredCopyLayout,
47136
+ "statement-copy": statementCopyLayout,
47137
+ "statement-media": statementMediaLayout,
47138
+ "media-copy": mediaCopyLayout
47139
+ },
47140
+ defaultVariant: "statement-copy",
47141
+ variantOptions: {
47142
+ "centered-copy": {
47143
+ label: "Centered copy",
47144
+ description: "A focused intro with centered text and optional calls to action."
47145
+ },
47146
+ "statement-copy": {
47147
+ label: "Statement and copy",
47148
+ description: "A large statement on the left with supporting copy on the right."
47149
+ },
47150
+ "statement-media": {
47151
+ label: "Statement, copy and media",
47152
+ description: "A three-part intro with statement, copy and a small image."
47153
+ },
47154
+ "media-copy": {
47155
+ label: "Media and copy",
47156
+ description: "A compact media/text intro for softer transitions after a hero."
47157
+ }
47158
+ },
47159
+ description: "A flexible introductory section for statement copy, supporting text, media, and CTAs.",
47160
+ tags: ["intro", "introduction", "about", "welcome", "statement", "media", "text"],
47161
+ icon: "PanelTopOpen"
47162
+ };
47163
+ var introManifest = createBlockManifest(introConfig);
47164
+ var introBlockDefinition = {
47165
+ manifest: introManifest
47166
+ };
47167
+
45038
47168
  // ../blocks/src/system/blocks/body-text.ts
45039
47169
  var bodyCopyComposition = composeFragments([{ fragment: bodyCopyFragment }]);
45040
47170
  var proseLayout = styledSection({
@@ -45786,6 +47916,37 @@ var faqComposition = composeFragments([
45786
47916
  { fragment: faqHeadingFragment, fieldPriority: 0 },
45787
47917
  { fragment: faqAccordionFragment, fieldPriority: 1 }
45788
47918
  ]);
47919
+ function fragmentLayoutNode(layout) {
47920
+ return isNodeDefinitionArray(layout) ? el("div", {}, [...layout]) : layout;
47921
+ }
47922
+ function isNodeDefinitionArray(layout) {
47923
+ return Array.isArray(layout);
47924
+ }
47925
+ var headingLayout = fragmentLayoutNode(faqHeadingFragment.layout);
47926
+ var accordionLayout = fragmentLayoutNode(faqAccordionFragment.layout);
47927
+ var defaultLayout = styledSection({
47928
+ children: styledContainer({
47929
+ baseClassName: "rb-relative rb-isolate",
47930
+ children: stack({ gap: "xl", className: "rb-w-full rb-max-w-4xl rb-mx-auto" }, faqComposition.layout)
47931
+ }),
47932
+ baseClass: ""
47933
+ });
47934
+ var twoColumnLayout = styledSection({
47935
+ children: styledContainer({
47936
+ baseClassName: "rb-relative rb-isolate",
47937
+ children: el(
47938
+ "div",
47939
+ {
47940
+ className: "rb-faq-two-column rb-grid rb-grid-cols-1 rb-gap-8 rb-lg-grid-cols-2 rb-lg-items-start"
47941
+ },
47942
+ [
47943
+ el("div", { className: "rb-faq-two-column-heading" }, [headingLayout]),
47944
+ el("div", { className: "rb-faq-two-column-accordion" }, [accordionLayout])
47945
+ ]
47946
+ )
47947
+ }),
47948
+ baseClass: ""
47949
+ });
45789
47950
  var faqManifest = createBlockManifest({
45790
47951
  id: "block.faq",
45791
47952
  title: "FAQ",
@@ -45802,13 +47963,22 @@ var faqManifest = createBlockManifest({
45802
47963
  label: "FAQ item styles"
45803
47964
  })
45804
47965
  ],
45805
- layout: styledSection({
45806
- children: styledContainer({
45807
- baseClassName: "rb-relative rb-isolate",
45808
- children: stack({ gap: "xl", className: "rb-w-full rb-max-w-4xl rb-mx-auto" }, faqComposition.layout)
45809
- }),
45810
- baseClass: ""
45811
- }),
47966
+ layout: defaultLayout,
47967
+ variants: {
47968
+ default: defaultLayout,
47969
+ "two-column": twoColumnLayout
47970
+ },
47971
+ defaultVariant: "default",
47972
+ variantOptions: {
47973
+ default: {
47974
+ label: "Default",
47975
+ description: "A centered heading above one FAQ accordion."
47976
+ },
47977
+ "two-column": {
47978
+ label: "Two column",
47979
+ description: "A left heading column with FAQ items on the right."
47980
+ }
47981
+ },
45812
47982
  description: "Accordion of frequently asked questions and answers.",
45813
47983
  tags: ["faq", "questions", "answers", "help", "support", "accordion", "q&a"],
45814
47984
  icon: "HelpCircle"
@@ -46449,7 +48619,8 @@ function resolveBackgroundVisualStyles(backgroundColor, tokens, defaultToken = "
46449
48619
  function resolveHeaderVisualStyles(header, tokens) {
46450
48620
  const navContainerType = header?.navContainer?.type ?? "none";
46451
48621
  const hasContainedNav = navContainerType === "glass" || navContainerType === "pill";
46452
- if (hasContainedNav) {
48622
+ const hasTransparentVariant = header?.variant === "transparent" || header?.variant === "floating";
48623
+ if (hasContainedNav || hasTransparentVariant) {
46453
48624
  return {
46454
48625
  backgroundToken: "transparent",
46455
48626
  paletteHex: null,
@@ -46578,6 +48749,17 @@ var headerRootStyleTransform = {
46578
48749
  return mergeStyles(...styleParts);
46579
48750
  }
46580
48751
  };
48752
+ var headerSectionBackgroundTransform = {
48753
+ id: "layout.headerSectionBackground",
48754
+ kind: "string",
48755
+ summary: "Resolve the inner site-header section background token",
48756
+ run: (value) => {
48757
+ const header = asPartialObject(value);
48758
+ const navContainerType = header?.navContainer?.type ?? "none";
48759
+ const usesTransparentRoot = header?.variant === "transparent" || header?.variant === "floating" || navContainerType === "glass" || navContainerType === "pill";
48760
+ return usesTransparentRoot ? "raw:transparent" : "background";
48761
+ }
48762
+ };
46581
48763
  var footerRootStyleTransform = {
46582
48764
  id: "layout.footerRootStyle",
46583
48765
  kind: "formatter",
@@ -46836,6 +49018,7 @@ var layoutTransforms = [
46836
49018
  headerRootClassTransform,
46837
49019
  footerRootClassTransform,
46838
49020
  headerRootStyleTransform,
49021
+ headerSectionBackgroundTransform,
46839
49022
  footerRootStyleTransform,
46840
49023
  footerBottomBarClassTransform,
46841
49024
  footerBottomBarContainerClassTransform,
@@ -47374,7 +49557,10 @@ var editorialLayout = stack(
47374
49557
  );
47375
49558
  var headerLayout = headerSection(
47376
49559
  {
47377
- background: "background",
49560
+ background: bindProp("$root.theme.header", {
49561
+ transforms: pipe(tx("layout.headerSectionBackground")),
49562
+ fallback: "background"
49563
+ }),
47378
49564
  allowOverflow: true,
47379
49565
  className: bindProp("$root.theme.header", {
47380
49566
  transforms: pipe(tx("layout.headerRootClass")),
@@ -48284,6 +50470,225 @@ var collectionBlockDefinition = {
48284
50470
  manifest: collectionManifest
48285
50471
  };
48286
50472
 
50473
+ // ../blocks/src/system/blocks/feature-cards.ts
50474
+ function grid3(props2, children) {
50475
+ return el("grid", props2 ?? void 0, children ?? void 0);
50476
+ }
50477
+ var sectionHeading = stack(
50478
+ { gap: "sm", className: "rb-feature-cards-heading rb-mx-auto rb-max-w-3xl rb-text-center" },
50479
+ [
50480
+ text(
50481
+ {
50482
+ as: "h2",
50483
+ className: "rb-feature-cards-title rb-text-center"
50484
+ },
50485
+ when("content.title"),
50486
+ bind("content.title")
50487
+ ),
50488
+ richText(
50489
+ {
50490
+ className: "rb-feature-cards-description rb-prose rb-mx-auto rb-max-w-none",
50491
+ style: textColorStyle("mutedText")
50492
+ },
50493
+ when("content.description"),
50494
+ bind("content.description")
50495
+ )
50496
+ ]
50497
+ );
50498
+ var featureCard = styledCard(
50499
+ [
50500
+ media(
50501
+ {
50502
+ className: "rb-feature-card-media rb-w-full rb-h-auto rb-object-cover",
50503
+ style: {
50504
+ aspectRatio: { $bind: { from: "card.aspectRatio" } }
50505
+ }
50506
+ },
50507
+ when("card.media"),
50508
+ bind("card.media")
50509
+ ),
50510
+ stack({ gap: "sm", className: "rb-feature-card-content rb-flex-1 rb-p-6" }, [
50511
+ text(
50512
+ {
50513
+ as: "h3",
50514
+ className: "rb-feature-card-title"
50515
+ },
50516
+ bind("card.title")
50517
+ ),
50518
+ richText(
50519
+ {
50520
+ className: "rb-feature-card-body rb-prose rb-max-w-none",
50521
+ style: textColorStyle("mutedText")
50522
+ },
50523
+ when("card.body"),
50524
+ bind("card.body")
50525
+ ),
50526
+ ctaRow({
50527
+ collectionPath: "ctas",
50528
+ itemName: "cta",
50529
+ gap: "sm",
50530
+ justify: "start",
50531
+ containerClassName: "rb-mt-auto"
50532
+ })
50533
+ ])
50534
+ ],
50535
+ {
50536
+ stylesFrom: "content._cardStyles",
50537
+ backgroundFrom: "content._cardStyles.background",
50538
+ baseClassName: "rb-feature-card rb-relative rb-isolate rb-overflow-hidden rb-border rb-flex rb-h-full rb-flex-col"
50539
+ },
50540
+ repeat("content.cards", "card")
50541
+ );
50542
+ var cardsLayout = styledSection({
50543
+ children: styledContainer({
50544
+ rootType: "stack",
50545
+ rootProps: { gap: "xl" },
50546
+ children: [
50547
+ sectionHeading,
50548
+ grid3(
50549
+ {
50550
+ cols: {
50551
+ $bind: {
50552
+ from: "content.columns",
50553
+ fallback: 3,
50554
+ coerce: "number"
50555
+ }
50556
+ },
50557
+ gap: "lg"
50558
+ },
50559
+ [featureCard]
50560
+ )
50561
+ ]
50562
+ }),
50563
+ baseClass: "",
50564
+ spacing: "medium"
50565
+ });
50566
+ var featureCardsConfig = {
50567
+ id: "block.feature-cards",
50568
+ title: "Feature Cards",
50569
+ category: "layout",
50570
+ includeContainerStyles: true,
50571
+ titleSource: "title",
50572
+ additionalFields: [
50573
+ {
50574
+ id: "title",
50575
+ type: "text",
50576
+ label: "Title",
50577
+ required: false,
50578
+ multiline: false,
50579
+ maxLength: 120
50580
+ },
50581
+ {
50582
+ id: "description",
50583
+ type: "richText",
50584
+ label: "Description",
50585
+ required: false,
50586
+ ui: {
50587
+ richTextVariant: "limited"
50588
+ }
50589
+ },
50590
+ {
50591
+ id: "columns",
50592
+ type: "select",
50593
+ label: "Columns",
50594
+ required: false,
50595
+ defaultValue: "3",
50596
+ multiple: false,
50597
+ options: [
50598
+ { value: "2", label: "2 columns" },
50599
+ { value: "3", label: "3 columns" },
50600
+ { value: "4", label: "4 columns" }
50601
+ ],
50602
+ ui: { intent: "display" }
50603
+ },
50604
+ {
50605
+ id: "cards",
50606
+ type: "repeater",
50607
+ label: "Cards",
50608
+ required: false,
50609
+ minItems: 1,
50610
+ maxItems: 8,
50611
+ itemLabel: "Card",
50612
+ itemLabelSource: "title",
50613
+ allowConversion: true,
50614
+ ui: {
50615
+ intent: "content"
50616
+ },
50617
+ schema: {
50618
+ fields: [
50619
+ {
50620
+ id: "media",
50621
+ type: "media",
50622
+ label: "Image",
50623
+ required: false,
50624
+ mediaKinds: ["image"]
50625
+ },
50626
+ createAspectRatioField({
50627
+ id: "aspectRatio",
50628
+ label: "Image aspect ratio",
50629
+ defaultValue: "4/3",
50630
+ visibleWhen: { field: "media", notEquals: null }
50631
+ }),
50632
+ {
50633
+ id: "title",
50634
+ type: "text",
50635
+ label: "Title",
50636
+ required: true,
50637
+ multiline: false,
50638
+ maxLength: 120
50639
+ },
50640
+ {
50641
+ id: "body",
50642
+ type: "richText",
50643
+ label: "Text",
50644
+ required: false,
50645
+ ui: {
50646
+ richTextVariant: "limited"
50647
+ }
50648
+ },
50649
+ createCtasRepeater({
50650
+ label: "Calls to action",
50651
+ itemLabel: "CTA",
50652
+ maxItems: 1,
50653
+ button: {
50654
+ variants: [
50655
+ { value: "primary", label: "Primary" },
50656
+ { value: "secondary", label: "Secondary" },
50657
+ { value: "outline", label: "Outline" },
50658
+ { value: "ghost", label: "Ghost" },
50659
+ { value: "link", label: "Link" }
50660
+ ],
50661
+ defaultVariant: "ghost"
50662
+ }
50663
+ })
50664
+ ]
50665
+ }
50666
+ },
50667
+ cardStylesField({
50668
+ id: "_cardStyles",
50669
+ label: "Card styles"
50670
+ })
50671
+ ],
50672
+ layout: cardsLayout,
50673
+ variants: {
50674
+ cards: cardsLayout
50675
+ },
50676
+ defaultVariant: "cards",
50677
+ variantOptions: {
50678
+ cards: {
50679
+ label: "Cards",
50680
+ description: "A responsive grid of image cards with optional calls to action."
50681
+ }
50682
+ },
50683
+ description: "A card grid for offerings, services, classes, benefits, or featured links.",
50684
+ tags: ["cards", "features", "offerings", "services", "classes", "grid", "links"],
50685
+ icon: "PanelsTopLeft"
50686
+ };
50687
+ var featureCardsManifest = createBlockManifest(featureCardsConfig);
50688
+ var featureCardsBlockDefinition = {
50689
+ manifest: featureCardsManifest
50690
+ };
50691
+
48287
50692
  // ../blocks/src/system/fields/carousel.ts
48288
50693
  var delayOptions = [
48289
50694
  { value: "3000", label: "3 seconds" },
@@ -48368,69 +50773,6 @@ function createCarouselBehaviorFields(options = {}) {
48368
50773
  ];
48369
50774
  return fields3;
48370
50775
  }
48371
-
48372
- // ../blocks/src/system/fields/imageLayout.ts
48373
- function createImageColSizeField(options = {}) {
48374
- const {
48375
- id = "imageColSize",
48376
- label = "Image column size",
48377
- description = "Controls how large the image/thumbnail column is at desktop breakpoints.",
48378
- defaultValue: defaultValue2 = "1/3",
48379
- uiIntent = "display",
48380
- visibleWhen
48381
- } = options;
48382
- return {
48383
- id,
48384
- type: "select",
48385
- label,
48386
- description,
48387
- required: false,
48388
- defaultValue: defaultValue2,
48389
- multiple: false,
48390
- options: [
48391
- { value: "1/4", label: "Small (1/4)" },
48392
- { value: "1/3", label: "Medium (1/3)" },
48393
- { value: "2/5", label: "Large (2/5)" },
48394
- { value: "1/2", label: "Extra large (1/2)" },
48395
- { value: "2/3", label: "Huge (2/3)" }
48396
- ],
48397
- ui: {
48398
- intent: uiIntent,
48399
- ...visibleWhen ? { visibleWhen } : {}
48400
- }
48401
- };
48402
- }
48403
- function createImagePositionField(options = {}) {
48404
- const {
48405
- id = "imagePosition",
48406
- label = "Image position",
48407
- description = "Choose which side the image appears on.",
48408
- defaultValue: defaultValue2 = "left",
48409
- includeAlternate = false,
48410
- uiIntent = "display",
48411
- visibleWhen
48412
- } = options;
48413
- const positionOptions = [
48414
- { value: "left", label: "Left" },
48415
- { value: "right", label: "Right" },
48416
- ...includeAlternate ? [{ value: "alternate", label: "Alternate" }] : []
48417
- ];
48418
- return {
48419
- id,
48420
- type: "select",
48421
- label,
48422
- description,
48423
- required: false,
48424
- defaultValue: defaultValue2,
48425
- multiple: false,
48426
- // Spread to get a mutable array type without unsafe casts.
48427
- options: [...positionOptions],
48428
- ui: {
48429
- intent: uiIntent,
48430
- ...visibleWhen ? { visibleWhen } : {}
48431
- }
48432
- };
48433
- }
48434
50776
  var textCardStylesField = (() => {
48435
50777
  const field = cardStylesField({
48436
50778
  id: "_textCardStyles",
@@ -48548,26 +50890,13 @@ var mediaTextManifest = createBlockManifest({
48548
50890
  },
48549
50891
  ui: { intent: "behavior" }
48550
50892
  }),
48551
- {
50893
+ createAspectRatioField({
48552
50894
  id: "aspectRatio",
48553
- type: "select",
48554
50895
  label: "Media aspect ratio",
48555
50896
  description: "Crop media to a consistent aspect ratio.",
48556
- required: false,
48557
50897
  defaultValue: "auto",
48558
- multiple: false,
48559
- options: [
48560
- { value: "auto", label: "Auto (original)" },
48561
- { value: "16/9", label: "16:9 (Landscape)" },
48562
- { value: "4/3", label: "4:3 (Standard)" },
48563
- { value: "1/1", label: "1:1 (Square)" },
48564
- { value: "3/4", label: "3:4 (Portrait)" }
48565
- ],
48566
- ui: {
48567
- intent: "display",
48568
- visibleWhen: { field: "images", notEquals: null }
48569
- }
48570
- },
50898
+ visibleWhen: { field: "images", notEquals: null }
50899
+ }),
48571
50900
  {
48572
50901
  id: "text",
48573
50902
  type: "richText",
@@ -48697,7 +51026,7 @@ var mediaTextManifest = createBlockManifest({
48697
51026
  whenImagesLength(0)
48698
51027
  );
48699
51028
  const defaultInner = el("div", {}, [defaultImagesLayout, defaultTextOnlyLayout]);
48700
- const defaultLayout = styledSection({
51029
+ const defaultLayout2 = styledSection({
48701
51030
  children: styledContainer({
48702
51031
  rootType: "stack",
48703
51032
  rootProps: { gap: "lg" },
@@ -48729,9 +51058,9 @@ var mediaTextManifest = createBlockManifest({
48729
51058
  spacing: "medium"
48730
51059
  });
48731
51060
  return {
48732
- layout: defaultLayout,
51061
+ layout: defaultLayout2,
48733
51062
  variants: {
48734
- default: defaultLayout
51063
+ default: defaultLayout2
48735
51064
  },
48736
51065
  defaultVariant: "default",
48737
51066
  variantOptions: {
@@ -54250,7 +56579,7 @@ var embedBlockDefinition = {
54250
56579
  };
54251
56580
 
54252
56581
  // ../blocks/src/system/blocks/image-gallery.ts
54253
- var grid3 = (props2, children, ...mods) => el("grid", props2 ?? void 0, children ?? void 0, ...mods);
56582
+ var grid4 = (props2, children, ...mods) => el("grid", props2 ?? void 0, children ?? void 0, ...mods);
54254
56583
  var galleryContainer = (children, opts) => {
54255
56584
  const gap = opts?.gap;
54256
56585
  const withExtraClass = (baseClass) => opts?.className ? `${baseClass} ${opts.className}` : baseClass;
@@ -54330,7 +56659,7 @@ var galleryItem = (options) => stack(
54330
56659
  ],
54331
56660
  repeat("content.images", "item")
54332
56661
  );
54333
- var gridLayout3 = grid3(
56662
+ var gridLayout3 = grid4(
54334
56663
  {
54335
56664
  className: "rb-grid rb-grid-cols-1 rb-gap-4 rb-sm-grid-cols-2 rb-md-grid-cols-3"
54336
56665
  },
@@ -54933,7 +57262,7 @@ var imageGalleryBlockDefinition = {
54933
57262
  };
54934
57263
 
54935
57264
  // ../blocks/src/system/blocks/video-grid.ts
54936
- var grid4 = (props2, children, ...mods) => el("grid", props2 ?? void 0, children ?? void 0, ...mods);
57265
+ var grid5 = (props2, children, ...mods) => el("grid", props2 ?? void 0, children ?? void 0, ...mods);
54937
57266
  var videoItem = (options) => stack(
54938
57267
  { gap: "xs", className: options.containerClassName },
54939
57268
  [
@@ -54983,7 +57312,7 @@ var gridColumnsClass = (columns) => {
54983
57312
  return "rb-grid rb-grid-cols-1 rb-gap-6 rb-sm-grid-cols-2 rb-md-grid-cols-3";
54984
57313
  }
54985
57314
  };
54986
- var createGridLayout = (columns) => grid4(
57315
+ var createGridLayout = (columns) => grid5(
54987
57316
  {
54988
57317
  className: gridColumnsClass(columns)
54989
57318
  },
@@ -58308,6 +60637,40 @@ var systemBlockDefinitionsRaw = [
58308
60637
  })
58309
60638
  ]
58310
60639
  })),
60640
+ withDesignCapability("block.intro", introBlockDefinition, declareBlockDesignCapability({
60641
+ sectionSurfaces: "supported",
60642
+ contentFrames: ["plain", "panel"],
60643
+ itemSurfaces: "unsupported",
60644
+ headingDecorations: ["organic-squiggle"]
60645
+ }), defineBlockDesignMetadata({
60646
+ flow: bodyFlow,
60647
+ layoutProfiles: [
60648
+ layoutProfile({
60649
+ variantKey: "centered-copy",
60650
+ family: "centered",
60651
+ weight: "featured",
60652
+ bias: "soft"
60653
+ }),
60654
+ layoutProfile({
60655
+ variantKey: "statement-copy",
60656
+ family: "split",
60657
+ weight: "featured",
60658
+ bias: "merge"
60659
+ }),
60660
+ layoutProfile({
60661
+ variantKey: "statement-media",
60662
+ family: "media-text",
60663
+ weight: "featured",
60664
+ bias: "soft"
60665
+ }),
60666
+ layoutProfile({
60667
+ variantKey: "media-copy",
60668
+ family: "media-text",
60669
+ weight: "featured",
60670
+ bias: "soft"
60671
+ })
60672
+ ]
60673
+ })),
58311
60674
  withDesignCapability("block.body-text", bodyTextBlockDefinition, sectionOnly(), defineBlockDesignMetadata({
58312
60675
  flow: bodyFlow,
58313
60676
  layoutProfiles: [
@@ -58368,9 +60731,17 @@ var systemBlockDefinitionsRaw = [
58368
60731
  flow: conversionFlow,
58369
60732
  layoutProfiles: [layoutProfile({ variantKey: "default", family: "form", weight: "standard" })]
58370
60733
  })),
58371
- withDesignCapability("block.faq", faqBlockDefinition, withEyebrowCapability(panelAndItemsCapable(), standardEyebrowTreatments), defineBlockDesignMetadata({
60734
+ withDesignCapability("block.faq", faqBlockDefinition, withEyebrowCapability(declareBlockDesignCapability({
60735
+ sectionSurfaces: "supported",
60736
+ contentFrames: ["plain", "panel"],
60737
+ itemSurfaces: "supported",
60738
+ accordionIconSets: ["plus", "chevron", "caret", "minimal-cross"]
60739
+ }), standardEyebrowTreatments), defineBlockDesignMetadata({
58372
60740
  flow: bodyFlow,
58373
- layoutProfiles: [layoutProfile({ variantKey: "default", family: "stack", weight: "standard" })]
60741
+ layoutProfiles: [
60742
+ layoutProfile({ variantKey: "default", family: "stack", weight: "standard" }),
60743
+ layoutProfile({ variantKey: "two-column", family: "split", weight: "standard" })
60744
+ ]
58374
60745
  })),
58375
60746
  withDesignCapability("block.site-header", siteHeaderBlockDefinition, declareNoBlockDesignCapability("site-chrome"), defineBlockDesignMetadata({
58376
60747
  flow: siteChromeFlow,
@@ -58384,7 +60755,8 @@ var systemBlockDefinitionsRaw = [
58384
60755
  sectionSurfaces: "supported",
58385
60756
  contentFrames: ["plain", "panel"],
58386
60757
  itemSurfaces: "supported",
58387
- testimonialCardTreatments: ["default", "accent-quote"]
60758
+ testimonialCardTreatments: ["default", "accent-quote"],
60759
+ headingDecorations: ["short-center-rule"]
58388
60760
  }), defineBlockDesignMetadata({
58389
60761
  flow: proofFlow,
58390
60762
  layoutProfiles: [
@@ -58410,6 +60782,22 @@ var systemBlockDefinitionsRaw = [
58410
60782
  flow: offeringsFlow,
58411
60783
  layoutProfiles: [layoutProfile({ variantKey: "default", family: "grid", weight: "standard" })]
58412
60784
  })),
60785
+ withDesignCapability("block.feature-cards", featureCardsBlockDefinition, declareBlockDesignCapability({
60786
+ sectionSurfaces: "supported",
60787
+ contentFrames: ["plain", "panel"],
60788
+ itemSurfaces: "supported",
60789
+ headingDecorations: ["short-center-rule"]
60790
+ }), defineBlockDesignMetadata({
60791
+ flow: offeringsFlow,
60792
+ layoutProfiles: [
60793
+ layoutProfile({
60794
+ variantKey: "cards",
60795
+ family: "grid",
60796
+ weight: "standard",
60797
+ bias: "soft"
60798
+ })
60799
+ ]
60800
+ })),
58413
60801
  withDesignCapability("block.media-text", mediaTextBlockDefinition, mediaPanelCapable(), defineBlockDesignMetadata({
58414
60802
  flow: mediaFlow,
58415
60803
  layoutProfiles: [
@@ -60281,6 +62669,42 @@ function normalizeBoolean2(value) {
60281
62669
  }
60282
62670
  return Boolean(value);
60283
62671
  }
62672
+
62673
+ // ../blocks/src/system/runtime/nodes/accordionIconTreatment.ts
62674
+ function resolveAccordionIconStyle(iconStyle, iconTreatment) {
62675
+ if (iconTreatment) {
62676
+ switch (iconTreatment.iconSet) {
62677
+ case "plus":
62678
+ return "plus-minus";
62679
+ case "chevron":
62680
+ return "chevron";
62681
+ case "caret":
62682
+ return "caret";
62683
+ case "minimal-cross":
62684
+ return "plus-minus";
62685
+ default:
62686
+ return assertNever7(iconTreatment.iconSet);
62687
+ }
62688
+ }
62689
+ return iconStyle && iconStyle in ICON_CONFIG ? iconStyle : "chevron";
62690
+ }
62691
+ function accordionIconColorStyle(iconTreatment) {
62692
+ const token = iconTreatment?.colorToken;
62693
+ if (!token || token === "current") return void 0;
62694
+ const themeToken = resolveIconColorToken(token);
62695
+ return {
62696
+ color: rgbColorValue(themeToken),
62697
+ ...iconTreatment.openColorToken && iconTreatment.openColorToken !== "current" ? {
62698
+ "--accordion-icon-open-color": rgbColorValue(resolveIconColorToken(iconTreatment.openColorToken))
62699
+ } : {}
62700
+ };
62701
+ }
62702
+ function resolveIconColorToken(token) {
62703
+ return token === "muted" ? "mutedText" : token;
62704
+ }
62705
+ function assertNever7(value) {
62706
+ throw new Error(`Unhandled accordion icon set: ${String(value)}`);
62707
+ }
60284
62708
  var ACCORDION_ICONS = {
60285
62709
  Plus,
60286
62710
  Minus,
@@ -60318,15 +62742,17 @@ var AccordionItemNodeSSR = ({
60318
62742
  content,
60319
62743
  question,
60320
62744
  answer,
60321
- iconStyle
62745
+ iconStyle,
62746
+ iconTreatment
60322
62747
  }) => {
60323
62748
  const resolvedValue = value !== void 0 && value !== null ? String(value) : void 0;
60324
62749
  const triggerSource = trigger ?? question;
60325
62750
  const contentSource = content ?? answer;
60326
- const resolvedIconStyle = iconStyle && iconStyle in ICON_CONFIG ? iconStyle : "chevron";
62751
+ const resolvedIconStyle = resolveAccordionIconStyle(iconStyle, iconTreatment);
60327
62752
  const iconConfig = ICON_CONFIG[resolvedIconStyle];
60328
62753
  const ClosedIconComponent = ACCORDION_ICONS[iconConfig.closedIcon];
60329
62754
  const OpenIconComponent = iconConfig.openIcon ? ACCORDION_ICONS[iconConfig.openIcon] : null;
62755
+ const iconColorStyle = accordionIconColorStyle(iconTreatment);
60330
62756
  return /* @__PURE__ */ jsxs(
60331
62757
  "div",
60332
62758
  {
@@ -60336,10 +62762,20 @@ var AccordionItemNodeSSR = ({
60336
62762
  children: [
60337
62763
  /* @__PURE__ */ jsxs("div", { className: "accordion-trigger", role: "button", tabIndex: 0, "aria-expanded": "false", children: [
60338
62764
  /* @__PURE__ */ jsx("span", { className: "accordion-trigger-text", children: resolveNode(triggerSource) }),
60339
- /* @__PURE__ */ jsxs("span", { className: "accordion-icon", "aria-hidden": "true", children: [
60340
- ClosedIconComponent && /* @__PURE__ */ jsx(ClosedIconComponent, { className: "accordion-icon-closed" }),
60341
- OpenIconComponent && /* @__PURE__ */ jsx(OpenIconComponent, { className: "accordion-icon-open" })
60342
- ] })
62765
+ /* @__PURE__ */ jsxs(
62766
+ "span",
62767
+ {
62768
+ className: "accordion-icon",
62769
+ "aria-hidden": "true",
62770
+ "data-accordion-icon-set": iconTreatment?.iconSet,
62771
+ "data-accordion-icon-motion": iconTreatment?.motion,
62772
+ style: iconColorStyle,
62773
+ children: [
62774
+ ClosedIconComponent && /* @__PURE__ */ jsx(ClosedIconComponent, { className: "accordion-icon-closed" }),
62775
+ OpenIconComponent && /* @__PURE__ */ jsx(OpenIconComponent, { className: "accordion-icon-open" })
62776
+ ]
62777
+ }
62778
+ )
60343
62779
  ] }),
60344
62780
  /* @__PURE__ */ jsx(
60345
62781
  "div",
@@ -60494,7 +62930,7 @@ function okWith(data) {
60494
62930
  function err2(error) {
60495
62931
  return { ok: false, error };
60496
62932
  }
60497
- function assertNever7(value, message2) {
62933
+ function assertNever8(value, message2) {
60498
62934
  throw new Error(`Unexpected value: ${String(value)}`);
60499
62935
  }
60500
62936
 
@@ -60649,7 +63085,7 @@ function deriveBookingFormViewState(input) {
60649
63085
  resourceName: input.verificationState.resourceName
60650
63086
  };
60651
63087
  default:
60652
- return assertNever7(input.verificationState);
63088
+ return assertNever8(input.verificationState);
60653
63089
  }
60654
63090
  }
60655
63091
  function resolveBookingSiteId(siteId, form2) {
@@ -60819,7 +63255,7 @@ function getBookingServicePaymentSelectionMode(service) {
60819
63255
  case "flexible_balance":
60820
63256
  return "implicit_flexible_balance";
60821
63257
  default:
60822
- return assertNever7(onlyKind);
63258
+ return assertNever8(onlyKind);
60823
63259
  }
60824
63260
  }
60825
63261
  if (allowedKinds.length === 2 && allowedKinds.includes("upfront") && (allowedKinds.includes("deferred_manual") || allowedKinds.includes("instalment_plan") || allowedKinds.includes("flexible_balance"))) {
@@ -61021,7 +63457,7 @@ function formatBookingSubmissionPreparationError(error) {
61021
63457
  case "service-missing-duration":
61022
63458
  return `Service "${error.serviceTitle}" is missing duration. Please update the service in the dashboard to include a duration (e.g., 30 minutes).`;
61023
63459
  default:
61024
- return assertNever7(error);
63460
+ return assertNever8(error);
61025
63461
  }
61026
63462
  }
61027
63463
  function getBookingSuccessMessage(successMessage) {
@@ -64502,6 +66938,47 @@ function makeDefaultBlockComponent(args) {
64502
66938
  return result;
64503
66939
  };
64504
66940
  }
66941
+ function renderBlock(manifest, content, options = {}) {
66942
+ const layout = resolveBlockLayout(manifest, content);
66943
+ if (!layout) {
66944
+ throw new Error(`Block manifest "${manifest.name}" requires a layout definition`);
66945
+ }
66946
+ const variantKey = resolveBlockVariantKey(
66947
+ manifest,
66948
+ content
66949
+ );
66950
+ const Component4 = makeDefaultBlockComponent({ manifest });
66951
+ const resolvedRegistry = options.registry ?? getDefaultComponentRegistry();
66952
+ const resolvedTheme = options.theme ?? defaultThemeTokens;
66953
+ const cleanKind = manifest.name.replace(/^block\./, "");
66954
+ const componentElement = React63__default.createElement(Component4, {
66955
+ content,
66956
+ data: options.data,
66957
+ registry: resolvedRegistry,
66958
+ theme: resolvedTheme,
66959
+ themeConfig: options.themeConfig,
66960
+ transforms: options.transforms,
66961
+ viewModelOverrides: options.viewModelOverrides,
66962
+ pathBase: options.pathBase,
66963
+ blockId: null,
66964
+ blockKind: manifest.name
66965
+ });
66966
+ if (manifest.behaviours?.managesOwnWrapper) {
66967
+ return componentElement;
66968
+ }
66969
+ const styleGroup = typeof content.styleGroup === "string" ? content.styleGroup : void 0;
66970
+ return React63__default.createElement(
66971
+ "div",
66972
+ {
66973
+ className: `block-${cleanKind}`,
66974
+ "data-block": cleanKind,
66975
+ "data-block-kind": manifest.name,
66976
+ ...variantKey ? { "data-block-variant": variantKey, "data-variant": variantKey } : {},
66977
+ ...styleGroup ? { "data-style-group": styleGroup } : {}
66978
+ },
66979
+ componentElement
66980
+ );
66981
+ }
64505
66982
 
64506
66983
  // ../theme-core/src/runtime/fontFamily.ts
64507
66984
  var GENERIC_CSS_FAMILIES = [
@@ -67996,6 +70473,82 @@ function transformSdkBlockToDefinition(sdkBlock) {
67996
70473
  // No content normalizer - SDK blocks use raw content
67997
70474
  };
67998
70475
  }
70476
+
70477
+ // ../blocks/src/customBlockRegistry.ts
70478
+ function isCustomBlockKind(blockKind) {
70479
+ return blockKind.startsWith("custom.");
70480
+ }
70481
+ function transformToBlockDescriptor(sdkBlock, source = "sdk") {
70482
+ return {
70483
+ name: sdkBlock.id,
70484
+ title: sdkBlock.title,
70485
+ description: sdkBlock.description,
70486
+ category: sdkBlock.category,
70487
+ tags: sdkBlock.tags,
70488
+ icon: sdkBlock.icon,
70489
+ definition: transformSdkBlockToDefinition(sdkBlock),
70490
+ source
70491
+ };
70492
+ }
70493
+ function toResolvedCustomBlock(manifest, source) {
70494
+ return {
70495
+ blockKind: manifest.id,
70496
+ manifest: transformSdkBlockToManifest(manifest),
70497
+ source,
70498
+ descriptor: transformToBlockDescriptor(
70499
+ manifest,
70500
+ source.kind === "managed-database" ? "database" : "sdk"
70501
+ )
70502
+ };
70503
+ }
70504
+ function createCustomBlockRegistry({
70505
+ sdkConfig,
70506
+ customBlocks = [],
70507
+ onConflict
70508
+ }) {
70509
+ const entriesByKind = /* @__PURE__ */ new Map();
70510
+ for (const sdkBlock of sdkConfig?.customBlocks ?? []) {
70511
+ entriesByKind.set(
70512
+ sdkBlock.id,
70513
+ toResolvedCustomBlock(sdkBlock, { kind: "sdk-config" })
70514
+ );
70515
+ }
70516
+ for (const customBlock of customBlocks) {
70517
+ const existing = entriesByKind.get(customBlock.manifest.id);
70518
+ if (existing) {
70519
+ onConflict?.(
70520
+ `Skipping DB custom block "${customBlock.manifest.id}" - conflicts with SDK config block`
70521
+ );
70522
+ continue;
70523
+ }
70524
+ entriesByKind.set(
70525
+ customBlock.manifest.id,
70526
+ toResolvedCustomBlock(customBlock.manifest, customBlock.source)
70527
+ );
70528
+ }
70529
+ return {
70530
+ entries: Array.from(entriesByKind.values()),
70531
+ findManifest: (blockKind) => {
70532
+ if (!isCustomBlockKind(blockKind)) return void 0;
70533
+ return entriesByKind.get(blockKind);
70534
+ }
70535
+ };
70536
+ }
70537
+ function mergeBlockDescriptorsWithRegistry(systemBlocks, registry, onConflict) {
70538
+ const existingNames = new Set(systemBlocks.map((block) => block.name));
70539
+ const result = [...systemBlocks];
70540
+ for (const entry of registry.entries) {
70541
+ if (existingNames.has(entry.blockKind)) {
70542
+ onConflict?.(
70543
+ `Skipping custom block "${entry.blockKind}" - conflicts with system block`
70544
+ );
70545
+ continue;
70546
+ }
70547
+ result.push(entry.descriptor);
70548
+ existingNames.add(entry.blockKind);
70549
+ }
70550
+ return result;
70551
+ }
67999
70552
  function PageRenderer({
68000
70553
  theme,
68001
70554
  page,
@@ -68161,17 +70714,14 @@ var MemoBlockSection = React63.memo(
68161
70714
  }
68162
70715
  const OverrideComponent = getBlockOverride(block.kind, blockOverrides);
68163
70716
  let definition = getBlockDefinition(block.kind);
68164
- if (!definition && block.kind.startsWith("custom.") && sdkConfig?.customBlocks) {
68165
- const sdkBlock = sdkConfig.customBlocks.find((b2) => b2.id === block.kind);
68166
- if (sdkBlock) {
68167
- definition = transformSdkBlockToDefinition(sdkBlock);
68168
- }
68169
- }
68170
- if (!definition && block.kind.startsWith("custom.") && customBlocks) {
68171
- const dbBlock = customBlocks.find((b2) => b2.id === block.kind);
68172
- if (dbBlock) {
68173
- definition = transformSdkBlockToDefinition(dbBlock);
68174
- }
70717
+ if (!definition && block.kind.startsWith("custom.")) {
70718
+ definition = createCustomBlockRegistry({
70719
+ sdkConfig,
70720
+ customBlocks: (customBlocks ?? []).map((manifest) => ({
70721
+ manifest,
70722
+ source: { kind: "managed-database" }
70723
+ }))
70724
+ }).findManifest(block.kind)?.descriptor.definition;
68175
70725
  }
68176
70726
  if (!definition) {
68177
70727
  if (OverrideComponent) {
@@ -68198,13 +70748,16 @@ var MemoBlockSection = React63.memo(
68198
70748
  }
68199
70749
  if (block.kind.startsWith("custom.") && shouldDebugCustomBlocks()) {
68200
70750
  try {
68201
- console.warn("[blocks:PageRenderer] custom block definition missing", {
68202
- blockId: block.id ?? null,
68203
- blockKind: block.kind,
68204
- hasOverride: Boolean(OverrideComponent),
68205
- sdkCustomBlocksCount: sdkConfig?.customBlocks?.length ?? 0,
68206
- dbCustomBlocksCount: customBlocks?.length ?? 0
68207
- });
70751
+ console.warn(
70752
+ "[blocks:PageRenderer] custom block definition missing",
70753
+ {
70754
+ blockId: block.id ?? null,
70755
+ blockKind: block.kind,
70756
+ hasOverride: Boolean(OverrideComponent),
70757
+ sdkCustomBlocksCount: sdkConfig?.customBlocks?.length ?? 0,
70758
+ dbCustomBlocksCount: customBlocks?.length ?? 0
70759
+ }
70760
+ );
68208
70761
  } catch {
68209
70762
  }
68210
70763
  }
@@ -68218,12 +70771,15 @@ var MemoBlockSection = React63.memo(
68218
70771
  if (!OverrideComponent && !manifestHasLayout) {
68219
70772
  if (block.kind.startsWith("custom.") && shouldDebugCustomBlocks()) {
68220
70773
  try {
68221
- console.warn("[blocks:PageRenderer] custom block has no layout/variants and no override", {
68222
- blockId: block.id ?? null,
68223
- blockKind: block.kind,
68224
- hasOverride: false,
68225
- manifestKeys: Object.keys(definition.manifest ?? {}).sort()
68226
- });
70774
+ console.warn(
70775
+ "[blocks:PageRenderer] custom block has no layout/variants and no override",
70776
+ {
70777
+ blockId: block.id ?? null,
70778
+ blockKind: block.kind,
70779
+ hasOverride: false,
70780
+ manifestKeys: Object.keys(definition.manifest ?? {}).sort()
70781
+ }
70782
+ );
68227
70783
  } catch {
68228
70784
  }
68229
70785
  }
@@ -68257,9 +70813,10 @@ var MemoBlockSection = React63.memo(
68257
70813
  if (parsed.success) {
68258
70814
  data = parsed.data;
68259
70815
  } else if (usePlaceholders) {
68260
- const relaxed = getCachedValidator(definition.manifest, "relaxed").safeParse(
68261
- content
68262
- );
70816
+ const relaxed = getCachedValidator(
70817
+ definition.manifest,
70818
+ "relaxed"
70819
+ ).safeParse(content);
68263
70820
  if (relaxed.success) {
68264
70821
  data = relaxed.data;
68265
70822
  } else {
@@ -79438,7 +81995,7 @@ function extractBlockData(content) {
79438
81995
  }
79439
81996
 
79440
81997
  // ../content-editor/src/utils/assertNever.ts
79441
- function assertNever8(value, message2) {
81998
+ function assertNever9(value, message2) {
79442
81999
  throw new Error(`Unexpected value: ${String(value)}`);
79443
82000
  }
79444
82001
  function cloneRecord(value) {
@@ -80089,7 +82646,7 @@ function applyEditorCommand(snapshot, command2) {
80089
82646
  return nextSnapshot;
80090
82647
  }
80091
82648
  default:
80092
- return assertNever8(command2);
82649
+ return assertNever9(command2);
80093
82650
  }
80094
82651
  }
80095
82652
  function applyUserOperation(snapshot, operation) {
@@ -80161,7 +82718,7 @@ function applySystemOperation(snapshot, operation) {
80161
82718
  case "replace-block-list":
80162
82719
  return replaceEditorBlockList(snapshot, operation.next);
80163
82720
  default:
80164
- return assertNever8(operation);
82721
+ return assertNever9(operation);
80165
82722
  }
80166
82723
  }
80167
82724
  function hydrateMetadataSnapshot(snapshot, baseline, current, published) {
@@ -80565,6 +83122,18 @@ function canRedoHistory(state) {
80565
83122
  }
80566
83123
 
80567
83124
  // ../block-form/src/blockDraftSaveability.ts
83125
+ function getResolvedBlockManifest(resolution) {
83126
+ switch (resolution.kind) {
83127
+ case "builtinManifest":
83128
+ case "sdkCustomManifest":
83129
+ case "managedCustomManifest":
83130
+ return resolution.manifest;
83131
+ case "unknownCustomBlock":
83132
+ case "unknownBuiltinBlock":
83133
+ case "invalidManifest":
83134
+ return null;
83135
+ }
83136
+ }
80568
83137
  var unfinishedBlockCopy = {
80569
83138
  title: "Fix this block to save it",
80570
83139
  description: "Some fields need a quick check. Your changes are safe here for now."
@@ -82126,6 +84695,73 @@ async function mutateBlockContent(apiClient, args) {
82126
84695
  }
82127
84696
  }
82128
84697
 
84698
+ // ../content-editor/src/hooks/blockDraftLifecycle.ts
84699
+ function deriveBlockDraftLifecycle(input) {
84700
+ const { snapshot, saveability, autosaveStatus } = input;
84701
+ if (saveability.kind === "save_failed") {
84702
+ return {
84703
+ kind: "saveFailed",
84704
+ blockId: snapshot.id,
84705
+ error: saveability.error,
84706
+ issues: saveability.issues
84707
+ };
84708
+ }
84709
+ if (snapshot.syncState.kind === "failed") {
84710
+ return {
84711
+ kind: "saveFailed",
84712
+ blockId: snapshot.id,
84713
+ error: snapshot.syncState.error,
84714
+ issues: saveability.issues
84715
+ };
84716
+ }
84717
+ if (snapshot.syncState.kind === "baseline") {
84718
+ return {
84719
+ kind: "baseline",
84720
+ blockId: snapshot.id
84721
+ };
84722
+ }
84723
+ if (saveability.kind !== "saveable") {
84724
+ return {
84725
+ kind: "invalidPending",
84726
+ blockId: snapshot.id,
84727
+ issues: saveability.issues
84728
+ };
84729
+ }
84730
+ if (autosaveStatus === "saving") {
84731
+ return {
84732
+ kind: "saving",
84733
+ blockId: snapshot.id,
84734
+ version: snapshot.version
84735
+ };
84736
+ }
84737
+ return {
84738
+ kind: "validPending",
84739
+ blockId: snapshot.id,
84740
+ version: snapshot.version
84741
+ };
84742
+ }
84743
+ function deriveBlockDraftAutosaveDecision(input) {
84744
+ const { snapshot, lifecycle } = input;
84745
+ switch (lifecycle.kind) {
84746
+ case "validPending": {
84747
+ return {
84748
+ type: "save",
84749
+ blockId: snapshot.id,
84750
+ data: snapshot.current.data ?? snapshot.current,
84751
+ acknowledgedVersion: snapshot.version
84752
+ };
84753
+ }
84754
+ case "baseline":
84755
+ return { type: "skip", blockId: snapshot.id, reason: "baseline" };
84756
+ case "invalidPending":
84757
+ return { type: "skip", blockId: snapshot.id, reason: "invalid" };
84758
+ case "saving":
84759
+ return { type: "skip", blockId: snapshot.id, reason: "saving" };
84760
+ case "saveFailed":
84761
+ return { type: "skip", blockId: snapshot.id, reason: "saveFailed" };
84762
+ }
84763
+ }
84764
+
82129
84765
  // ../content-editor/src/hooks/useBlockAutosave.ts
82130
84766
  function isPlainRecord(value) {
82131
84767
  return typeof value === "object" && value !== null && !Array.isArray(value);
@@ -82175,20 +84811,20 @@ function useBlockAutosave({
82175
84811
  const drafts = state.drafts;
82176
84812
  const allSnapshots = drafts.inspect();
82177
84813
  const pending = allSnapshots.filter(isPendingWithCurrent);
82178
- const saveablePending = pending.filter((snapshot) => {
84814
+ const saveablePending = pending.flatMap((snapshot) => {
82179
84815
  const saveability = state.blockValidation.getBlockSaveability(snapshot.id);
82180
- if (saveability.kind === "saveable") {
82181
- return true;
82182
- }
82183
- return false;
84816
+ const lifecycle = deriveBlockDraftLifecycle({
84817
+ snapshot,
84818
+ saveability,
84819
+ autosaveStatus: state.autosave.blocks.status
84820
+ });
84821
+ const decision = deriveBlockDraftAutosaveDecision({ snapshot, lifecycle });
84822
+ return decision.type === "save" ? [decision] : [];
82184
84823
  });
82185
- return saveablePending.map((s2) => ({
82186
- blockId: s2.id,
82187
- // Extract just the 'data' field from the snapshot row structure
82188
- // The store keeps the full DB row (id, blockId, data, version, etc.)
82189
- // but the API expects just the content
82190
- data: s2.current.data ?? s2.current,
82191
- acknowledgedVersion: s2.version
84824
+ return saveablePending.map((decision) => ({
84825
+ blockId: decision.blockId,
84826
+ data: decision.data,
84827
+ acknowledgedVersion: decision.acknowledgedVersion
82192
84828
  }));
82193
84829
  }, [uiStore]);
82194
84830
  const stableShouldSkip = useCallback(
@@ -82340,8 +84976,8 @@ function validateAllBlocks(uiStore) {
82340
84976
  return errors;
82341
84977
  }
82342
84978
  function getPublishValidationIssues(uiStore, snapshot) {
82343
- const definition = getBlockDefinition(snapshot.meta.kind);
82344
- const registryManifest = definition?.manifest ?? null;
84979
+ const resolution = resolveClientBlockManifestForPublish(snapshot.meta.kind);
84980
+ const registryManifest = getResolvedBlockManifest(resolution);
82345
84981
  if (registryManifest) {
82346
84982
  const content = snapshot.current ?? snapshot.baseline ?? {};
82347
84983
  return {
@@ -82353,6 +84989,30 @@ function getPublishValidationIssues(uiStore, snapshot) {
82353
84989
  if (!saveability) {
82354
84990
  return { issues: [], manifest: null };
82355
84991
  }
84992
+ return getSaveabilityPublishValidationIssues(saveability);
84993
+ }
84994
+ function resolveClientBlockManifestForPublish(blockKind) {
84995
+ const definition = getBlockDefinition(blockKind);
84996
+ const registryManifest = definition?.manifest ?? null;
84997
+ if (registryManifest) {
84998
+ return {
84999
+ kind: "builtinManifest",
85000
+ blockKind,
85001
+ manifest: registryManifest
85002
+ };
85003
+ }
85004
+ if (blockKind.startsWith("custom.")) {
85005
+ return {
85006
+ kind: "unknownCustomBlock",
85007
+ blockKind
85008
+ };
85009
+ }
85010
+ return {
85011
+ kind: "unknownBuiltinBlock",
85012
+ blockKind
85013
+ };
85014
+ }
85015
+ function getSaveabilityPublishValidationIssues(saveability) {
82356
85016
  if (saveability.issues.length > 0) {
82357
85017
  return {
82358
85018
  issues: saveability.issues,
@@ -82385,6 +85045,60 @@ function getFieldLabelFromManifest(manifest, path, descriptor) {
82385
85045
  return field?.label ?? fieldId;
82386
85046
  }
82387
85047
 
85048
+ // ../content-editor/src/hooks/publishability.ts
85049
+ function hasAutosaveFailure(autosave) {
85050
+ if (!autosave) return false;
85051
+ return autosave.metadata.status === "error" || autosave.content.status === "error" || autosave.blocks.status === "error" || autosave.metadata.hasFailedSaves || autosave.content.hasFailedSaves || autosave.blocks.hasFailedSaves;
85052
+ }
85053
+ function derivePublishability(input) {
85054
+ const blockedPublishPlan = deriveBlockedPublishPlan({
85055
+ validationErrors: input.validationErrors,
85056
+ drawerOpen: input.drawerOpen
85057
+ });
85058
+ if (blockedPublishPlan.type === "blocked") {
85059
+ return {
85060
+ kind: "blocked",
85061
+ canPublish: false,
85062
+ disablePublish: true,
85063
+ reason: "invalidBlocks",
85064
+ blockedPublishPlan
85065
+ };
85066
+ }
85067
+ if (input.hasInvalidBlockSummary) {
85068
+ return {
85069
+ kind: "blocked",
85070
+ canPublish: false,
85071
+ disablePublish: true,
85072
+ reason: "invalidBlockSummary",
85073
+ blockedPublishPlan
85074
+ };
85075
+ }
85076
+ if (input.includeAutosaveFailures && hasAutosaveFailure(input.autosave)) {
85077
+ return {
85078
+ kind: "blocked",
85079
+ canPublish: false,
85080
+ disablePublish: true,
85081
+ reason: "autosaveFailed",
85082
+ blockedPublishPlan
85083
+ };
85084
+ }
85085
+ if (input.unpublishedState.hasBeenPublishedBefore && !input.unpublishedState.hasUnpublishedChanges) {
85086
+ return {
85087
+ kind: "blocked",
85088
+ canPublish: false,
85089
+ disablePublish: true,
85090
+ reason: "noUnpublishedChanges",
85091
+ blockedPublishPlan
85092
+ };
85093
+ }
85094
+ return {
85095
+ kind: "allowed",
85096
+ canPublish: true,
85097
+ disablePublish: false,
85098
+ blockedPublishPlan
85099
+ };
85100
+ }
85101
+
82388
85102
  // ../content-editor/src/debug/unpublishedChangesDebug.ts
82389
85103
  function isBrowser() {
82390
85104
  return typeof window !== "undefined";
@@ -82395,7 +85109,7 @@ function isUnpublishedChangesDebugEnabled() {
82395
85109
  }
82396
85110
 
82397
85111
  // ../content-editor/src/hooks/useEntryActions.ts
82398
- async function waitForAutosavesComplete(uiStore, timeoutMs = 5e3) {
85112
+ async function waitForAutosavesComplete(uiStore, timeoutMs = 6e4) {
82399
85113
  return new Promise((resolve, reject) => {
82400
85114
  const getAutosaveStatuses = () => {
82401
85115
  const state = uiStore.getState();
@@ -82497,19 +85211,45 @@ function useEntryActions({
82497
85211
  const performPublish = useCallback(async (options) => {
82498
85212
  setErrorMessage(null);
82499
85213
  const validationErrors = validateAllBlocks(uiStore);
82500
- const blockedPublishPlan = deriveBlockedPublishPlan({
85214
+ const publishability = derivePublishability({
85215
+ unpublishedState: uiStore.getState().getUnpublishedState(),
82501
85216
  validationErrors,
82502
85217
  drawerOpen: uiStore.getState().drawerOpen
82503
85218
  });
82504
- if (blockedPublishPlan.type === "blocked") {
82505
- applyBlockedPublishPlan(uiStore, blockedPublishPlan, setErrorMessage);
82506
- return;
85219
+ if (publishability.kind === "blocked") {
85220
+ switch (publishability.reason) {
85221
+ case "invalidBlocks":
85222
+ applyBlockedPublishPlan(
85223
+ uiStore,
85224
+ publishability.blockedPublishPlan,
85225
+ setErrorMessage
85226
+ );
85227
+ return;
85228
+ case "noUnpublishedChanges":
85229
+ return;
85230
+ case "invalidBlockSummary":
85231
+ return;
85232
+ case "autosaveFailed":
85233
+ setErrorMessage("Cannot publish: failed to save draft changes.");
85234
+ throw new Error("Cannot publish: failed to save draft changes.");
85235
+ }
82507
85236
  }
82508
85237
  const dirtyTypes = getDirtyAutosaveTypes(uiStore, hasRoute);
82509
85238
  uiStore.getState().autosave.saveNow(dirtyTypes);
82510
85239
  uiStore.getState().autosave.flushAllPending();
82511
85240
  await waitForAutosavesComplete(uiStore);
82512
- if (hasAutosaveErrors(uiStore)) {
85241
+ const autosavePublishability = derivePublishability({
85242
+ unpublishedState: uiStore.getState().getUnpublishedState(),
85243
+ validationErrors: [],
85244
+ drawerOpen: uiStore.getState().drawerOpen,
85245
+ includeAutosaveFailures: true,
85246
+ autosave: {
85247
+ metadata: uiStore.getState().autosave.metadata,
85248
+ content: uiStore.getState().autosave.content,
85249
+ blocks: uiStore.getState().autosave.blocks
85250
+ }
85251
+ });
85252
+ if (autosavePublishability.kind === "blocked" && autosavePublishability.reason === "autosaveFailed") {
82513
85253
  const message2 = "Cannot publish: failed to save draft changes.";
82514
85254
  setErrorMessage(message2);
82515
85255
  throw new Error(message2);
@@ -83393,7 +86133,7 @@ function toDrainFailure(effect, error) {
83393
86133
  case "persist-remove":
83394
86134
  return { kind: effect.type, message: message2 };
83395
86135
  default:
83396
- return assertNever8(effect);
86136
+ return assertNever9(effect);
83397
86137
  }
83398
86138
  }
83399
86139
  async function drainEditorEffect(effect, context) {
@@ -83405,7 +86145,7 @@ async function drainEditorEffect(effect, context) {
83405
86145
  case "persist-remove":
83406
86146
  return drainPersistRemoveEffect(effect, context);
83407
86147
  default:
83408
- return assertNever8(effect);
86148
+ return assertNever9(effect);
83409
86149
  }
83410
86150
  }
83411
86151
  async function drainEditorEffects(effects, context) {
@@ -83789,7 +86529,8 @@ function useInternalValue(props2) {
83789
86529
  initialEntry,
83790
86530
  initialContent,
83791
86531
  initialPublishedContent,
83792
- onEntryUpdated
86532
+ onEntryUpdated,
86533
+ resolveBlockManifest
83793
86534
  } = props2;
83794
86535
  const saveMode = props2.saveMode ?? "auto";
83795
86536
  const historyShortcutsEnabled = props2.historyShortcutsEnabled ?? true;
@@ -83838,9 +86579,11 @@ function useInternalValue(props2) {
83838
86579
  });
83839
86580
  const hasHydratedContentRef = useRef(false);
83840
86581
  const historyShortcutRootRef = useRef(null);
86582
+ const resolveBlockManifestRef = useRef(resolveBlockManifest);
86583
+ resolveBlockManifestRef.current = resolveBlockManifest;
83841
86584
  const uiStore = useMemo(() => {
83842
86585
  const store = createEditorUiStore({
83843
- resolveBlockManifest: (kind) => getBlockDefinition(kind)?.manifest ?? null
86586
+ resolveBlockManifest: (kind) => resolveBlockManifestRef.current?.(kind) ?? getBlockDefinition(kind)?.manifest ?? null
83844
86587
  });
83845
86588
  const metadataState = createMetadataStateFromSnapshot(entry);
83846
86589
  const baseline = { ...metadataState.baseline };
@@ -100715,8 +103458,8 @@ function addMonths2(date, amount, options) {
100715
103458
  const dayOfMonth = _date.getDate();
100716
103459
  const endOfDesiredMonth = constructFrom(date, _date.getTime());
100717
103460
  endOfDesiredMonth.setMonth(_date.getMonth() + amount + 1, 0);
100718
- const daysInMonth = endOfDesiredMonth.getDate();
100719
- if (dayOfMonth >= daysInMonth) {
103461
+ const daysInMonth2 = endOfDesiredMonth.getDate();
103462
+ if (dayOfMonth >= daysInMonth2) {
100720
103463
  return endOfDesiredMonth;
100721
103464
  } else {
100722
103465
  _date.setFullYear(
@@ -102642,8 +105385,8 @@ function setMonth(date, month, options) {
102642
105385
  const midMonth = constructFrom(date, 0);
102643
105386
  midMonth.setFullYear(year, month, 15);
102644
105387
  midMonth.setHours(0, 0, 0, 0);
102645
- const daysInMonth = getDaysInMonth(midMonth);
102646
- _date.setMonth(month, Math.min(day, daysInMonth));
105388
+ const daysInMonth2 = getDaysInMonth(midMonth);
105389
+ _date.setMonth(month, Math.min(day, daysInMonth2));
102647
105390
  return _date;
102648
105391
  }
102649
105392
 
@@ -105788,7 +108531,7 @@ function readSliderFieldUiConfig(ui) {
105788
108531
  }
105789
108532
 
105790
108533
  // ../block-form/src/manifest/utils.ts
105791
- function assertNever9(value) {
108534
+ function assertNever10(value) {
105792
108535
  throw new Error(`Unhandled manifest variant: ${JSON.stringify(value)}`);
105793
108536
  }
105794
108537
  function getGroupChildFields(field) {
@@ -105802,7 +108545,7 @@ function getRepeaterChildFields(field) {
105802
108545
  function buildCanonicalFieldSchema(field) {
105803
108546
  const manifestField = normalizeFieldForCanonicalValidation(field);
105804
108547
  return fieldPlanToZod(deriveFieldValidationPlan(manifestField), {
105805
- allowNull: !Boolean(field.required)
108548
+ allowNull: !field.required
105806
108549
  });
105807
108550
  }
105808
108551
  function normalizeFieldForCanonicalValidation(field) {
@@ -105846,7 +108589,7 @@ function toManifestFieldInput(field) {
105846
108589
  case "entryPicker":
105847
108590
  return field;
105848
108591
  }
105849
- return assertNever9(field);
108592
+ return assertNever10(field);
105850
108593
  }
105851
108594
  function numberFieldToManifestInput(field) {
105852
108595
  const ui = readNumberFieldUiConfig(field.ui);
@@ -106092,43 +108835,30 @@ function buildUrlFieldSchema(field) {
106092
108835
  function getUrlFieldDefault(field) {
106093
108836
  return field.defaultValue ?? "";
106094
108837
  }
108838
+
108839
+ // ../block-form/src/widgets/TimeField/timeFieldSchema.ts
106095
108840
  function buildTimeFieldSchema(field) {
106096
- const base2 = z.string();
106097
- if (field.required) {
106098
- return base2.min(1, { message: `${field.label} is required` });
106099
- }
106100
- return z.union([base2, z.literal(""), z.null()]).optional().nullable();
108841
+ return buildCanonicalFieldSchema(field);
106101
108842
  }
106102
108843
 
106103
108844
  // ../block-form/src/widgets/TimeField/timeFieldDefaults.ts
106104
108845
  function getTimeFieldDefault(field) {
106105
108846
  return field.defaultValue ?? null;
106106
108847
  }
108848
+
108849
+ // ../block-form/src/widgets/DateField/dateFieldSchema.ts
106107
108850
  function buildDateFieldSchema(field) {
106108
- const base2 = z.string();
106109
- if (field.required) {
106110
- return base2.min(1, { message: `${field.label} is required` });
106111
- }
106112
- return z.union([base2, z.literal(""), z.null()]).optional().nullable();
108851
+ return buildCanonicalFieldSchema(field);
106113
108852
  }
106114
108853
 
106115
108854
  // ../block-form/src/widgets/DateField/dateFieldDefaults.ts
106116
108855
  function getDateFieldDefault(field) {
106117
108856
  return field.defaultValue ?? null;
106118
108857
  }
108858
+
108859
+ // ../block-form/src/widgets/DateTimeField/dateTimeFieldSchema.ts
106119
108860
  function buildDateTimeFieldSchema(field) {
106120
- const base2 = z.string().refine(
106121
- (val) => {
106122
- if (!val) return true;
106123
- const date = new Date(val);
106124
- return !isNaN(date.getTime());
106125
- },
106126
- { message: "Choose a valid date and time" }
106127
- );
106128
- if (field.required) {
106129
- return base2.min(1, { message: "This field is required" });
106130
- }
106131
- return z.union([base2, z.literal(""), z.null()]).optional().nullable();
108861
+ return buildCanonicalFieldSchema(field);
106132
108862
  }
106133
108863
 
106134
108864
  // ../block-form/src/widgets/DateTimeField/dateTimeFieldDefaults.ts
@@ -106483,7 +109213,7 @@ function shouldUseCanonicalSchema(field) {
106483
109213
  case "button":
106484
109214
  return false;
106485
109215
  }
106486
- return assertNever9(field);
109216
+ return assertNever10(field);
106487
109217
  }
106488
109218
  function createManifestValidation(manifest, options) {
106489
109219
  const { fields: fields3, schema } = createManifestFormAdapter(manifest, {
@@ -109280,7 +112010,7 @@ function bookingSubmissionReducer(state, action) {
109280
112010
  feedback: { tag: "idle" }
109281
112011
  };
109282
112012
  default:
109283
- return assertNever7(action);
112013
+ return assertNever8(action);
109284
112014
  }
109285
112015
  }
109286
112016
  function selectIsSubmitting(state) {
@@ -109586,7 +112316,7 @@ function buildBookingPaymentOptionViewModel(input) {
109586
112316
  };
109587
112317
  }
109588
112318
  default:
109589
- return assertNever7(input.option);
112319
+ return assertNever8(input.option);
109590
112320
  }
109591
112321
  }
109592
112322
  function buildInstalmentSchedulePreview(input) {
@@ -109643,7 +112373,7 @@ function buildInstalmentSchedulePreview(input) {
109643
112373
  })));
109644
112374
  }
109645
112375
  default:
109646
- return assertNever7(input.option.plan);
112376
+ return assertNever8(input.option.plan);
109647
112377
  }
109648
112378
  }
109649
112379
  function getPaymentCadenceLabel(plan) {
@@ -109867,7 +112597,7 @@ function bookingFlowReducer(state, event) {
109867
112597
  case "reset":
109868
112598
  return event.initial;
109869
112599
  default:
109870
- return assertNever7(event);
112600
+ return assertNever8(event);
109871
112601
  }
109872
112602
  }
109873
112603
  function clearAvailabilityFeedback(feedback) {
@@ -109996,7 +112726,7 @@ function validateBookingStep(input) {
109996
112726
  return Object.keys(errors).length > 0 ? { ok: false, errors: createFieldBookingValidationErrors(errors) } : { ok: true };
109997
112727
  }
109998
112728
  default:
109999
- return assertNever7(input.stepId);
112729
+ return assertNever8(input.stepId);
110000
112730
  }
110001
112731
  }
110002
112732
  function validateBookingFields(input) {
@@ -110287,7 +113017,7 @@ function resolveAppointmentPackagesModel(input) {
110287
113017
  };
110288
113018
  }
110289
113019
  default:
110290
- return assertNever7(input.state);
113020
+ return assertNever8(input.state);
110291
113021
  }
110292
113022
  }
110293
113023
  function toHeadlessEligibleAppointmentPackage(appointmentPackage) {
@@ -110997,7 +113727,7 @@ function pollingReducer(state, action) {
110997
113727
  case "timeout":
110998
113728
  return state;
110999
113729
  default:
111000
- return assertNever7(state);
113730
+ return assertNever8(state);
111001
113731
  }
111002
113732
  case "polling-timed-out":
111003
113733
  return {
@@ -111006,7 +113736,7 @@ function pollingReducer(state, action) {
111006
113736
  error: new Error("Polling timed out")
111007
113737
  };
111008
113738
  default:
111009
- return assertNever7(action);
113739
+ return assertNever8(action);
111010
113740
  }
111011
113741
  }
111012
113742
 
@@ -111435,7 +114165,7 @@ function DefaultBookingStepContent({
111435
114165
  case "custom-fields":
111436
114166
  return /* @__PURE__ */ jsx(DefaultDynamicFields, { fields: booking.fields.items, booking });
111437
114167
  default:
111438
- return assertNever7(stepId);
114168
+ return assertNever8(stepId);
111439
114169
  }
111440
114170
  }
111441
114171
  function DefaultServiceSelectionStep({
@@ -113027,7 +115757,7 @@ function eligibilityLookupReducer(state, action) {
113027
115757
  error: action.message
113028
115758
  };
113029
115759
  default:
113030
- return assertNever7(action);
115760
+ return assertNever8(action);
113031
115761
  }
113032
115762
  }
113033
115763
  var initialExistingRegistrationLookupState = {
@@ -113049,7 +115779,7 @@ function existingRegistrationLookupReducer(state, action) {
113049
115779
  registration: action.registration
113050
115780
  };
113051
115781
  default:
113052
- return assertNever7(action);
115782
+ return assertNever8(action);
113053
115783
  }
113054
115784
  }
113055
115785
 
@@ -117949,7 +120679,7 @@ function shopPassesMembershipsReducer(state, action) {
117949
120679
  returnNotice: null
117950
120680
  };
117951
120681
  default:
117952
- return assertNever7(action);
120682
+ return assertNever8(action);
117953
120683
  }
117954
120684
  }
117955
120685
  function getOpenCheckout(state) {
@@ -118819,7 +121549,7 @@ function shopCheckoutReducer(state, action) {
118819
121549
  notice: action.notice
118820
121550
  };
118821
121551
  default:
118822
- return assertNever7(action);
121552
+ return assertNever8(action);
118823
121553
  }
118824
121554
  }
118825
121555
  var CHECKOUT_ANCHOR_ID = "shop-checkout";
@@ -119225,7 +121955,7 @@ function giftingClientReducer(state, action) {
119225
121955
  purchaseNotice: action.notice
119226
121956
  };
119227
121957
  default:
119228
- return assertNever7(action);
121958
+ return assertNever8(action);
119229
121959
  }
119230
121960
  }
119231
121961
  function resolveGiftingPurchaseNotice(search, defaultSuccessMessage) {
@@ -119620,6 +122350,7 @@ var AccordionItemNode = ({
119620
122350
  question,
119621
122351
  answer,
119622
122352
  iconStyle,
122353
+ iconTreatment,
119623
122354
  blockId: _blockId,
119624
122355
  blockKind: _blockKind,
119625
122356
  blockContent: _blockContent,
@@ -119632,10 +122363,11 @@ var AccordionItemNode = ({
119632
122363
  const triggerSource = trigger ?? question;
119633
122364
  const contentSource = content ?? answer;
119634
122365
  const resolvedTrigger = typeof triggerSource === "string" || typeof triggerSource === "number" ? String(triggerSource) : triggerSource;
119635
- const resolvedIconStyle = iconStyle && iconStyle in ICON_CONFIG ? iconStyle : "chevron";
122366
+ const resolvedIconStyle = resolveAccordionIconStyle(iconStyle, iconTreatment);
119636
122367
  const iconConfig = ICON_CONFIG[resolvedIconStyle];
119637
122368
  const ClosedIconComponent = ACCORDION_ICONS2[iconConfig.closedIcon];
119638
122369
  const OpenIconComponent = iconConfig.openIcon ? ACCORDION_ICONS2[iconConfig.openIcon] : null;
122370
+ const iconColorStyle = accordionIconColorStyle(iconTreatment);
119639
122371
  return /* @__PURE__ */ jsxs(
119640
122372
  AccordionItem2,
119641
122373
  {
@@ -119645,10 +122377,20 @@ var AccordionItemNode = ({
119645
122377
  children: [
119646
122378
  /* @__PURE__ */ jsxs(AccordionTrigger2, { className: "accordion-trigger", children: [
119647
122379
  /* @__PURE__ */ jsx(Text, { as: "span", className: "accordion-trigger-text", children: resolvedTrigger }),
119648
- /* @__PURE__ */ jsxs("span", { className: "accordion-icon", "aria-hidden": "true", children: [
119649
- ClosedIconComponent && /* @__PURE__ */ jsx(ClosedIconComponent, { className: "accordion-icon-closed" }),
119650
- OpenIconComponent && /* @__PURE__ */ jsx(OpenIconComponent, { className: "accordion-icon-open" })
119651
- ] })
122380
+ /* @__PURE__ */ jsxs(
122381
+ "span",
122382
+ {
122383
+ className: "accordion-icon",
122384
+ "aria-hidden": "true",
122385
+ "data-accordion-icon-set": iconTreatment?.iconSet,
122386
+ "data-accordion-icon-motion": iconTreatment?.motion,
122387
+ style: iconColorStyle,
122388
+ children: [
122389
+ ClosedIconComponent && /* @__PURE__ */ jsx(ClosedIconComponent, { className: "accordion-icon-closed" }),
122390
+ OpenIconComponent && /* @__PURE__ */ jsx(OpenIconComponent, { className: "accordion-icon-open" })
122391
+ ]
122392
+ }
122393
+ )
119652
122394
  ] }),
119653
122395
  /* @__PURE__ */ jsx(AccordionContent2, { className: "accordion-content", children: typeof contentSource === "string" || typeof contentSource === "number" ? /* @__PURE__ */ jsx("p", { children: String(contentSource) }) : contentSource ? (() => {
119654
122396
  const doc3 = coerceRichTextDoc(contentSource);
@@ -122765,7 +125507,7 @@ function formSubmissionReducer(_state, action) {
122765
125507
  case "submission-failed":
122766
125508
  return { tag: "failed", message: action.message };
122767
125509
  default:
122768
- return assertNever7(action);
125510
+ return assertNever8(action);
122769
125511
  }
122770
125512
  }
122771
125513
 
@@ -134730,7 +137472,7 @@ var RectangleStencil = forwardRef(function(_a, ref) {
134730
137472
  north: true,
134731
137473
  east: true,
134732
137474
  south: true
134733
- } : _f, _g = _a.lineComponent, lineComponent = _g === void 0 ? SimpleLine : _g, _h = _a.lineClassNames, lineClassNames = _h === void 0 ? {} : _h, _j = _a.lineWrapperClassNames, lineWrapperClassNames = _j === void 0 ? {} : _j, _k = _a.resizable, resizable = _k === void 0 ? true : _k, _l = _a.movable, movable = _l === void 0 ? true : _l, grid5 = _a.grid, gridClassName = _a.gridClassName, className = _a.className, movingClassName = _a.movingClassName, resizingClassName = _a.resizingClassName, previewClassName = _a.previewClassName, boundingBoxClassName = _a.boundingBoxClassName, overlayClassName = _a.overlayClassName, draggableAreaClassName = _a.draggableAreaClassName, disabled = _a.disabled;
137475
+ } : _f, _g = _a.lineComponent, lineComponent = _g === void 0 ? SimpleLine : _g, _h = _a.lineClassNames, lineClassNames = _h === void 0 ? {} : _h, _j = _a.lineWrapperClassNames, lineWrapperClassNames = _j === void 0 ? {} : _j, _k = _a.resizable, resizable = _k === void 0 ? true : _k, _l = _a.movable, movable = _l === void 0 ? true : _l, grid6 = _a.grid, gridClassName = _a.gridClassName, className = _a.className, movingClassName = _a.movingClassName, resizingClassName = _a.resizingClassName, previewClassName = _a.previewClassName, boundingBoxClassName = _a.boundingBoxClassName, overlayClassName = _a.overlayClassName, draggableAreaClassName = _a.draggableAreaClassName, disabled = _a.disabled;
134734
137476
  var state = cropper.getState();
134735
137477
  var transitions = cropper.getTransitions();
134736
137478
  var interactions = cropper.getInteractions();
@@ -134783,7 +137525,7 @@ var RectangleStencil = forwardRef(function(_a, ref) {
134783
137525
  React63__default.createElement(
134784
137526
  StencilOverlay,
134785
137527
  { className: (0, import_classnames.default)("advanced-cropper-rectangle-stencil__overlay", overlayClassName) },
134786
- grid5 && React63__default.createElement(StencilGrid, { visible: cropper.hasInteractions(), columns: interactions.transformImage.rotate ? 9 : 3, rows: interactions.transformImage.rotate ? 9 : 3, className: (0, import_classnames.default)("advanced-cropper-rectangle-stencil__grid", gridClassName) }),
137528
+ grid6 && React63__default.createElement(StencilGrid, { visible: cropper.hasInteractions(), columns: interactions.transformImage.rotate ? 9 : 3, rows: interactions.transformImage.rotate ? 9 : 3, className: (0, import_classnames.default)("advanced-cropper-rectangle-stencil__grid", gridClassName) }),
134787
137529
  React63__default.createElement("div", { className: (0, import_classnames.default)("advanced-cropper-rectangle-stencil__preview", previewClassName) })
134788
137530
  )
134789
137531
  )
@@ -135131,7 +137873,7 @@ var CircleStencil = forwardRef(function(_a, ref) {
135131
137873
  north: true,
135132
137874
  east: true,
135133
137875
  south: true
135134
- } : _f, _g = _a.lineComponent, lineComponent = _g === void 0 ? SimpleLine : _g, _h = _a.lineClassNames, lineClassNames = _h === void 0 ? {} : _h, _j = _a.lineWrapperClassNames, lineWrapperClassNames = _j === void 0 ? {} : _j, _k = _a.resizable, resizable = _k === void 0 ? true : _k, _l = _a.movable, movable = _l === void 0 ? true : _l, grid5 = _a.grid, gridClassName = _a.gridClassName, className = _a.className, movingClassName = _a.movingClassName, resizingClassName = _a.resizingClassName, previewClassName = _a.previewClassName, boundingBoxClassName = _a.boundingBoxClassName, overlayClassName = _a.overlayClassName, draggableAreaClassName = _a.draggableAreaClassName, disabled = _a.disabled;
137876
+ } : _f, _g = _a.lineComponent, lineComponent = _g === void 0 ? SimpleLine : _g, _h = _a.lineClassNames, lineClassNames = _h === void 0 ? {} : _h, _j = _a.lineWrapperClassNames, lineWrapperClassNames = _j === void 0 ? {} : _j, _k = _a.resizable, resizable = _k === void 0 ? true : _k, _l = _a.movable, movable = _l === void 0 ? true : _l, grid6 = _a.grid, gridClassName = _a.gridClassName, className = _a.className, movingClassName = _a.movingClassName, resizingClassName = _a.resizingClassName, previewClassName = _a.previewClassName, boundingBoxClassName = _a.boundingBoxClassName, overlayClassName = _a.overlayClassName, draggableAreaClassName = _a.draggableAreaClassName, disabled = _a.disabled;
135135
137877
  var state = cropper.getState();
135136
137878
  var transitions = cropper.getTransitions();
135137
137879
  var interactions = cropper.getInteractions();
@@ -135182,7 +137924,7 @@ var CircleStencil = forwardRef(function(_a, ref) {
135182
137924
  React63__default.createElement(
135183
137925
  StencilOverlay,
135184
137926
  { className: (0, import_classnames.default)("advanced-cropper-circle-stencil__overlay", overlayClassName) },
135185
- grid5 && React63__default.createElement(StencilGrid, { visible: cropper.hasInteractions(), columns: interactions.transformImage.rotate ? 9 : 3, rows: interactions.transformImage.rotate ? 9 : 3, className: (0, import_classnames.default)("advanced-cropper-circle-stencil__grid", gridClassName) }),
137927
+ grid6 && React63__default.createElement(StencilGrid, { visible: cropper.hasInteractions(), columns: interactions.transformImage.rotate ? 9 : 3, rows: interactions.transformImage.rotate ? 9 : 3, className: (0, import_classnames.default)("advanced-cropper-circle-stencil__grid", gridClassName) }),
135186
137928
  React63__default.createElement("div", { className: (0, import_classnames.default)("advanced-cropper-circle-stencil__preview", previewClassName) })
135187
137929
  )
135188
137930
  )
@@ -165025,4 +167767,4 @@ lucide-react/dist/esm/lucide-react.js:
165025
167767
  *)
165026
167768
  */
165027
167769
 
165028
- export { ArrowDown, ArrowUp, BackgroundColorField, BackgroundGradientField, Badge2 as Badge, BlockApiProvider, Box, Button, CSS2 as CSS, CTA_ICON_OPTIONS, Callout, CalloutDescription, CalloutTitle, Card, CardContent, CardHeader, CardTitle, Check, ChevronDown, ChevronLeft, ChevronRight, Collapsible2 as Collapsible, CollapsibleContent2 as CollapsibleContent, CollapsibleTrigger2 as CollapsibleTrigger, ColorPicker, Combobox, Content, ContentFieldsForm, Copy, DEFAULT_LAUNCH_READINESS_INPUT, Dialog2 as Dialog, DialogClose2 as DialogClose, DialogContent2 as DialogContent, DialogDescription2 as DialogDescription, DialogFooter, DialogHeader, DialogTitle2 as DialogTitle, DndContext, DropdownMenu2 as DropdownMenu, DropdownMenuContent2 as DropdownMenuContent, DropdownMenuItem2 as DropdownMenuItem, DropdownMenuLabel2 as DropdownMenuLabel, DropdownMenuSeparator2 as DropdownMenuSeparator, DropdownMenuTrigger2 as DropdownMenuTrigger, EMPTY_DOC, EditableBlockProvider, EditorChrome, EditorProvider, EllipsisVertical, EmptyState2 as EmptyState, EntryControllerProvider, FieldFrame, FixedBottomSurface, FormRenderer, GripVertical, Input, KeyboardCode, Label4 as Label, List2 as List, LoaderCircle, ManifestForm, Maximize2, MediaEditor, MediaEditorProvider, MediaPickerDialog, MediaPickerMini, Monitor, PAGE_DESIGN_EDITOR_STATE_FETCH_ERROR_MESSAGE, PUBLIC_FILE_FIELD_KINDS, PageRenderer, Palette, PaletteProvider, Pencil, Plus, PointerSensor, PreviewRichTextEditor, PreviewTextEditor, ResizableSplitPane, RichText2 as RichText, RichTextEditorSurface, Root2, RotateCcw, SUBROUTE_KINDS, ScrollableDialogContent, Search, Select2 as Select, SelectContent2 as SelectContent, SelectItem2 as SelectItem, SelectTrigger2 as SelectTrigger, SelectValue2 as SelectValue, Separator2 as Separator, Settings, SiteDocumentLayout, Smartphone, Sparkles, Surface, Tablet, Tabs2 as Tabs, TabsContent2 as TabsContent, TabsList2 as TabsList, TabsTrigger2 as TabsTrigger, Text2 as Text, ThemeScope, Trash2, TriangleAlert, Trigger, X, applyCompiledRuntimeFieldsToContent, applyPageDesignEditorAction, asDesignBlockId, asEditorBlockId, asEditorBlockValues, asRecord, asSiteId, assertNever3 as assertNever, assertNever5 as assertNever2, augmentManifestWithStyleGroups, buildEditorModelRuntimeFieldsByBlockId, buildThemeRuntime, buttonPersonalities, canRedoHistory, canUndoHistory, classifyHistoryShortcut, clientComponentRegistry, closestCenter, cn, compileSiteThemeFromSelections, createBlock, createEditorInsertBlockCommand, createEditorRemoveBlockCommand, createEditorReorderBlocksCommand, createHistoryState, createManifestFormAdapter, createManifestValidation, createRoutingHelpers, createSnapshotFromPageRecord, createStoreBackend, curatedSiteStyles, deleteBlock, deriveLaunchReadiness, findButtonPersonality, findFooterLook, findHeaderLook, findPaletteVariant, foldSubroute, footerLookCatalog, footerLookRejectionReasonLabel, getBlockDefinition, getClientRect, getCtaIconComponent, getCuratedSiteStyle, getDirectImageUrlForMediaAsset, getFieldIntent, getModalConfig, getPageDesignEditorState, getRichTextImagePositionFromTarget, getRouteMetadataManifestForType, headerLookCatalog, headerLookRejectionReasonLabel, insertOrReplaceRichTextImage, isCtaIconName, isHeaderField, isInternalResolvedLinkValue, isKeyboardEvent, isNonEmptyValue, isObjectRecord2 as isObjectRecord, isSvgMimeType, isThemeV2NormalEditorRawStyleFieldName, isThemeV2NormalEditorRawStylePath, listBlockDescriptors, listContentTypes, lucide_react_exports, mergeManifestWithSdkOptions, mutateBlockContent, normalEditorCuratedPromotedFieldPaths, normalizePickerSearchThreshold, omitRouteTitleFieldFromManifest, paletteOverridesSchema, paletteVariants, parseAspectRatioValue, planPageDesignLayoutLookCompatibility, planSiteDocument, previewAssistantEnabled, pushHistoryEntry, recoveryConflictCopy, redoHistory, reorderBlocks, requireEntriesForCuratedChoices, resolveBlockTitle, resolveImageUrlWithContext, resolveMediaSlotContract, resolvePickerSelectionLabel, resolvePreviewSidebarTab, resolveVisiblePromotedFieldPathsForEditorBlock, shouldShowPickerSearch, siteStyleIdFromTheme, surfaceResolutionContextFromTheme, systemCustomizeFacetAppliesToLayoutVariant, systemCustomizeFacetApplyContentPatch, systemCustomizeFacetCurrentValue, systemCustomizeFacetDefinitionForBlock, systemCustomizeFacetDefinitionsForBlock, systemCustomizeFacetLabelForValue, systemCustomizeFacetNextValue, systemCustomizeFacetRollbackContentPatch, toRoutableLinkPayload, transformSdkBlockToDefinition, transformSdkBlockToManifest, undoHistory, unfinishedBlockCopy, unwrapResponse, useAsyncPickerOptions, useBackendWatch, useBlockContext, useCombinedRefs, useDebouncedLatestSave, useDndContext, useDraggable, useDroppable, useEditor2 as useEditor, useEditorUiStore, useEditorUiStoreInstance, useEntryController, useEntryEditorController, useField, useIsomorphicLayoutEffect3 as useIsomorphicLayoutEffect, useMediaEditor, useMediaEditorOptional, useMultiAutosave, useOptionalEditorUiStoreInstance, useRichTextEditor, useSdkConfig, useSensor, useSensors, useUISelector, useUniqueId, validateBlockManifestIssues, writePlanForLookCustomizationCommand };
167770
+ export { ArrowDown, ArrowUp, BackgroundColorField, BackgroundGradientField, Badge2 as Badge, BlockApiProvider, Box, Button, CSS2 as CSS, CTA_ICON_OPTIONS, Callout, CalloutDescription, CalloutTitle, Card, CardContent, CardHeader, CardTitle, Check, ChevronDown, ChevronLeft, ChevronRight, Collapsible2 as Collapsible, CollapsibleContent2 as CollapsibleContent, CollapsibleTrigger2 as CollapsibleTrigger, ColorPicker, Combobox, Content, ContentFieldsForm, Copy, DEFAULT_LAUNCH_READINESS_INPUT, Dialog2 as Dialog, DialogClose2 as DialogClose, DialogContent2 as DialogContent, DialogDescription2 as DialogDescription, DialogFooter, DialogHeader, DialogTitle2 as DialogTitle, DndContext, DropdownMenu2 as DropdownMenu, DropdownMenuContent2 as DropdownMenuContent, DropdownMenuItem2 as DropdownMenuItem, DropdownMenuLabel2 as DropdownMenuLabel, DropdownMenuSeparator2 as DropdownMenuSeparator, DropdownMenuTrigger2 as DropdownMenuTrigger, EMPTY_DOC, EditableBlockProvider, EditorChrome, EditorProvider, EllipsisVertical, EmptyState2 as EmptyState, EntryControllerProvider, FieldFrame, FixedBottomSurface, FormRenderer, GripVertical, Input, KeyboardCode, Label4 as Label, List2 as List, LoaderCircle, ManifestForm, Maximize2, MediaEditor, MediaEditorProvider, MediaPickerDialog, MediaPickerMini, Monitor, PAGE_DESIGN_EDITOR_STATE_FETCH_ERROR_MESSAGE, PUBLIC_FILE_FIELD_KINDS, PageRenderer, Palette, PaletteProvider, Pencil, Plus, PointerSensor, PreviewRichTextEditor, PreviewTextEditor, ResizableSplitPane, RichText2 as RichText, RichTextEditorSurface, Root2, RotateCcw, SUBROUTE_KINDS, ScrollableDialogContent, Search, Select2 as Select, SelectContent2 as SelectContent, SelectItem2 as SelectItem, SelectTrigger2 as SelectTrigger, SelectValue2 as SelectValue, Separator2 as Separator, Settings, SiteDocumentLayout, Smartphone, Sparkles, Surface, Tablet, Tabs2 as Tabs, TabsContent2 as TabsContent, TabsList2 as TabsList, TabsTrigger2 as TabsTrigger, Text2 as Text, ThemeScope, Trash2, TriangleAlert, Trigger, X, applyCompiledRuntimeFieldsToContent, applyPageDesignEditorAction, asDesignBlockId, asEditorBlockId, asEditorBlockValues, asRecord, asSiteId, assertNever3 as assertNever, assertNever5 as assertNever2, augmentManifestWithStyleGroups, buildEditorModelRuntimeFieldsByBlockId, buildThemeRuntime, buttonPersonalities, canRedoHistory, canUndoHistory, classifyHistoryShortcut, clientComponentRegistry, closestCenter, cn, compileSiteThemeFromSelections, createBlock, createCustomBlockRegistry, createEditorInsertBlockCommand, createEditorRemoveBlockCommand, createEditorReorderBlocksCommand, createHistoryState, createManifestFormAdapter, createManifestValidation, createRoutingHelpers, createSnapshotFromPageRecord, createStoreBackend, curatedSiteStyles, deleteBlock, deriveLaunchReadiness, deriveNearestCompatibleHeaderStyle, evaluateTypographyFontSlot, findButtonPersonality, findFooterLook, findLegacyHeaderLookIdForSelection, findPaletteVariant, findTypographyPreset, foldSubroute, footerLookCatalog, footerLookRejectionReasonLabel, getBlockDefinition, getClientRect, getCompatibleHeaderStyleIds, getCtaIconComponent, getCuratedSiteStyle, getDirectImageUrlForMediaAsset, getFieldIntent, getHeaderLayout, getHeaderStyle, getModalConfig, getPageDesignEditorState, getRichTextImagePositionFromTarget, getRouteMetadataManifestForType, headerLayoutCatalog, headerStyleCatalog, insertOrReplaceRichTextImage, isCtaIconName, isHeaderField, isInternalResolvedLinkValue, isKeyboardEvent, isNonEmptyValue, isObjectRecord2 as isObjectRecord, isSvgMimeType, isThemeV2NormalEditorRawStyleFieldName, isThemeV2NormalEditorRawStylePath, listBlockDescriptors, listContentTypes, lucide_react_exports, mergeBlockDescriptorsWithRegistry, mergeManifestWithSdkOptions, mutateBlockContent, normalEditorCuratedPromotedFieldPaths, normalizePickerSearchThreshold, omitRouteTitleFieldFromManifest, paletteOverridesSchema, paletteVariants, parseAspectRatioValue, planPageDesignLayoutLookCompatibility, planSiteDocument, previewAssistantEnabled, pushHistoryEntry, recoveryConflictCopy, redoHistory, renderBlock, reorderBlocks, requireEntriesForCuratedChoices, resolveBlockTitle, resolveImageUrlWithContext, resolveMediaSlotContract, resolvePickerSelectionLabel, resolvePreviewSidebarTab, resolveVisiblePromotedFieldPathsForEditorBlock, shouldShowPickerSearch, siteFooterManifest, siteHeaderManifest, siteStyleIdFromTheme, surfaceResolutionContextFromTheme, systemCustomizeFacetAppliesToLayoutVariant, systemCustomizeFacetApplyContentPatch, systemCustomizeFacetCurrentValue, systemCustomizeFacetDefinitionForBlock, systemCustomizeFacetDefinitionsForBlock, systemCustomizeFacetLabelForValue, systemCustomizeFacetNextValue, systemCustomizeFacetRollbackContentPatch, toRoutableLinkPayload, typographyPresets, undoHistory, unfinishedBlockCopy, unwrapResponse, useAsyncPickerOptions, useBackendWatch, useBlockContext, useCombinedRefs, useDebouncedLatestSave, useDndContext, useDraggable, useDroppable, useEditor2 as useEditor, useEditorUiStore, useEditorUiStoreInstance, useEntryController, useEntryEditorController, useField, useIsomorphicLayoutEffect3 as useIsomorphicLayoutEffect, useMediaEditor, useMediaEditorOptional, useMultiAutosave, useOptionalEditorUiStoreInstance, useRichTextEditor, useSdkConfig, useSensor, useSensors, useUISelector, useUniqueId, validateBlockManifestIssues, writePlanForLookCustomizationCommand };