@riverbankcms/sdk 0.128.0 → 0.129.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (290) hide show
  1. package/README.md +52 -256
  2. package/dist/{PreviewEditorSidebar-Dbvb7GIr.mjs → PreviewEditorSidebar-DceRseRV.mjs} +3 -3
  3. package/dist/{PreviewEditorUI-e9O9l20X.mjs → PreviewEditorUI-BNunq3kk.mjs} +2 -2
  4. package/dist/{SdkPreviewModeRuntime-BZHt6e9w.mjs → SdkPreviewModeRuntime-Bt87-62u.mjs} +495 -292
  5. package/dist/{SiteChromeCustomizeContext-CvuGbHJX.mjs → SiteChromeCustomizeContext-BLl-OlL4.mjs} +600 -533
  6. package/dist/_dts/ai/src/contracts/commandExposure.d.ts +1 -1
  7. package/dist/_dts/ai/src/contracts/proposals.d.ts +4897 -4897
  8. package/dist/_dts/api/src/index.d.ts +2 -1
  9. package/dist/_dts/api/src/sdk-event-management.d.ts +53 -0
  10. package/dist/_dts/api/src/sdk-event-schedule.d.ts +3 -6
  11. package/dist/_dts/api/src/sdkContracts.d.ts +37 -50
  12. package/dist/_dts/api/src/sdkThemeWire.d.ts +2595 -0
  13. package/dist/_dts/api/src/sitePlatformEndpoints.d.ts +13 -29
  14. package/dist/_dts/blocks/src/PageRenderer.d.ts +20 -10
  15. package/dist/_dts/blocks/src/index.d.ts +2 -1
  16. package/dist/_dts/blocks/src/pageRendererBoundaries.d.ts +30 -0
  17. package/dist/_dts/blocks/src/pageRenderingMode.d.ts +37 -0
  18. package/dist/_dts/blocks/src/server.d.ts +1 -1
  19. package/dist/_dts/db/src/generated/supabase/database.types.d.ts +14 -0
  20. package/dist/_dts/media-core/src/index.d.ts +1 -0
  21. package/dist/_dts/preview-next/src/client/blocks/pageDesignRuntimePreview.d.ts +2 -0
  22. package/dist/_dts/preview-next/src/client/index.d.ts +47 -47
  23. package/dist/_dts/preview-next/src/client/preview/PreviewShell.d.ts +18 -6
  24. package/dist/_dts/preview-next/src/client/preview/PreviewShellLayout.d.ts +30 -21
  25. package/dist/_dts/preview-next/src/client/preview/PreviewThemedSiteDocument.d.ts +18 -5
  26. package/dist/_dts/preview-next/src/client/preview/themeRuntime.d.ts +9 -0
  27. package/dist/_dts/preview-next/src/client/sdk/SdkPreviewMode.d.ts +21 -6
  28. package/dist/_dts/preview-next/src/client/sdk-runtime.d.ts +8 -8
  29. package/dist/_dts/sdk/src/config/types.d.ts +4 -4
  30. package/dist/_dts/sdk/src/next/catch-all.d.ts +6 -0
  31. package/dist/_dts/sdk/src/next/index.d.ts +2 -1
  32. package/dist/_dts/sdk/src/next/renderSdkContent.d.ts +33 -0
  33. package/dist/_dts/sdk/src/next/types.d.ts +23 -9
  34. package/dist/_dts/sdk/src/preview-next/before-render.d.ts +4 -6
  35. package/dist/_dts/sdk/src/preview-next/client/index.d.ts +3 -3
  36. package/dist/_dts/sdk/src/preview-next/client/runtime.d.ts +1 -1
  37. package/dist/_dts/sdk/src/rendering/blocks-page-renderer.d.ts +25 -3
  38. package/dist/_dts/sdk/src/rendering/components/Block.shared.d.ts +13 -2
  39. package/dist/_dts/sdk/src/rendering/components/Layout.d.ts +31 -18
  40. package/dist/_dts/sdk/src/rendering/components/pageShared.d.ts +20 -9
  41. package/dist/_dts/sdk/src/rendering/index.d.ts +4 -2
  42. package/dist/_dts/sdk/src/rendering/renderingMode.d.ts +23 -0
  43. package/dist/_dts/sdk/src/rendering/server.d.ts +5 -3
  44. package/dist/_dts/sdk/src/rendering/themeRuntime.d.ts +6 -0
  45. package/dist/_dts/sdk/src/version.d.ts +1 -1
  46. package/dist/_dts/theme-core/src/buttons/index.d.ts +1 -0
  47. package/dist/_dts/theme-core/src/palette/index.d.ts +1 -0
  48. package/dist/_dts/theme-core/src/site-styles/headerLayoutStyleCatalog.d.ts +254 -0
  49. package/dist/_dts/theme-core/src/site-styles/headerLegacyLooks.d.ts +372 -0
  50. package/dist/_dts/theme-core/src/site-styles/headerLookBranding.d.ts +106 -0
  51. package/dist/_dts/theme-core/src/site-styles/headerLookSelection.d.ts +2 -0
  52. package/dist/_dts/theme-core/src/site-styles/headerLookTypes.d.ts +212 -0
  53. package/dist/_dts/theme-core/src/site-styles/headerLooks.d.ts +7 -841
  54. package/dist/_dts/theme-core/src/site-styles/headerStyleCompiler.d.ts +3 -0
  55. package/dist/_dts/theme-core/src/site-styles/headerStyleCompilerPrimitives.d.ts +23 -0
  56. package/dist/client/client.mjs +911 -762
  57. package/dist/client/hooks.mjs +59 -36
  58. package/dist/client/rendering/client.mjs +593 -547
  59. package/dist/client/rendering.mjs +994 -783
  60. package/dist/preview-next/before-render.mjs +10 -3
  61. package/dist/preview-next/client/runtime.mjs +3 -3
  62. package/dist/{sdk-runtime-Cn_QSCOg.mjs → sdk-runtime-C20CVWbb.mjs} +1 -1
  63. package/dist/{separator-CEoGABRc.mjs → separator-BE3NCquy.mjs} +1 -1
  64. package/dist/server/components.mjs +549 -399
  65. package/dist/server/config-validation.mjs +59 -36
  66. package/dist/server/config.mjs +59 -36
  67. package/dist/server/data.mjs +59 -36
  68. package/dist/server/index.mjs +1 -1
  69. package/dist/server/manifest.mjs +4966 -0
  70. package/dist/server/next.mjs +700 -537
  71. package/dist/server/page-converter.mjs +40 -36
  72. package/dist/server/prebuild.mjs +1 -1
  73. package/dist/server/rendering/server.mjs +571 -404
  74. package/dist/server/rendering.mjs +571 -404
  75. package/dist/server/routing.mjs +472 -402
  76. package/dist/server/server.mjs +60 -37
  77. package/dist/server/theme-bridge.mjs +70 -66
  78. package/package.json +9 -12
  79. package/dist/_dts/api/src/event-presentation.d.ts +0 -14
  80. package/dist/_dts/blocks/src/definitions.d.ts +0 -14
  81. package/dist/_dts/sdk/src/cli/canonical-entry-policy.d.ts +0 -53
  82. package/dist/_dts/sdk/src/cli/commands/audit.d.ts +0 -101
  83. package/dist/_dts/sdk/src/cli/commands/block.d.ts +0 -24
  84. package/dist/_dts/sdk/src/cli/commands/compare.d.ts +0 -62
  85. package/dist/_dts/sdk/src/cli/commands/content-type.d.ts +0 -10
  86. package/dist/_dts/sdk/src/cli/commands/content.d.ts +0 -56
  87. package/dist/_dts/sdk/src/cli/commands/delete.d.ts +0 -14
  88. package/dist/_dts/sdk/src/cli/commands/deploy.d.ts +0 -43
  89. package/dist/_dts/sdk/src/cli/commands/drafts.d.ts +0 -18
  90. package/dist/_dts/sdk/src/cli/commands/entry.d.ts +0 -55
  91. package/dist/_dts/sdk/src/cli/commands/env.d.ts +0 -31
  92. package/dist/_dts/sdk/src/cli/commands/event.d.ts +0 -23
  93. package/dist/_dts/sdk/src/cli/commands/eventOccurrenceSchedule.d.ts +0 -12
  94. package/dist/_dts/sdk/src/cli/commands/identifiers.d.ts +0 -10
  95. package/dist/_dts/sdk/src/cli/commands/init-docs.d.ts +0 -13
  96. package/dist/_dts/sdk/src/cli/commands/manifest.d.ts +0 -10
  97. package/dist/_dts/sdk/src/cli/commands/media-validation.d.ts +0 -3
  98. package/dist/_dts/sdk/src/cli/commands/migrate.d.ts +0 -11
  99. package/dist/_dts/sdk/src/cli/commands/navigation.d.ts +0 -12
  100. package/dist/_dts/sdk/src/cli/commands/page.d.ts +0 -14
  101. package/dist/_dts/sdk/src/cli/commands/publish-all.d.ts +0 -50
  102. package/dist/_dts/sdk/src/cli/commands/pull-dated-offering-scope.d.ts +0 -10
  103. package/dist/_dts/sdk/src/cli/commands/pull-dry-run.d.ts +0 -70
  104. package/dist/_dts/sdk/src/cli/commands/pull-scope-diff.d.ts +0 -8
  105. package/dist/_dts/sdk/src/cli/commands/pull.d.ts +0 -43
  106. package/dist/_dts/sdk/src/cli/commands/push/consts.d.ts +0 -3
  107. package/dist/_dts/sdk/src/cli/commands/push/execute/diff.d.ts +0 -19
  108. package/dist/_dts/sdk/src/cli/commands/push/execute/footer.d.ts +0 -42
  109. package/dist/_dts/sdk/src/cli/commands/push/execute/localMediaReporting.d.ts +0 -23
  110. package/dist/_dts/sdk/src/cli/commands/push/execute/media.d.ts +0 -22
  111. package/dist/_dts/sdk/src/cli/commands/push/execute/metadata.d.ts +0 -1
  112. package/dist/_dts/sdk/src/cli/commands/push/execute/reporting.d.ts +0 -7
  113. package/dist/_dts/sdk/src/cli/commands/push/execute/theme.d.ts +0 -63
  114. package/dist/_dts/sdk/src/cli/commands/push/filter.d.ts +0 -15
  115. package/dist/_dts/sdk/src/cli/commands/push/metadata.d.ts +0 -29
  116. package/dist/_dts/sdk/src/cli/commands/push/normalizeLocalContent.d.ts +0 -2
  117. package/dist/_dts/sdk/src/cli/commands/push/options.d.ts +0 -32
  118. package/dist/_dts/sdk/src/cli/commands/push/publishGuidance.d.ts +0 -15
  119. package/dist/_dts/sdk/src/cli/commands/push/pushAllExtras.d.ts +0 -25
  120. package/dist/_dts/sdk/src/cli/commands/push/scopes/commandBackedDatedOfferingScope.d.ts +0 -83
  121. package/dist/_dts/sdk/src/cli/commands/push/scopes/eventCategories.d.ts +0 -4
  122. package/dist/_dts/sdk/src/cli/commands/push/scopes/events.d.ts +0 -4
  123. package/dist/_dts/sdk/src/cli/commands/push/scopes/mediaPrep.d.ts +0 -14
  124. package/dist/_dts/sdk/src/cli/commands/push/scopes/pushScopeGeneric.d.ts +0 -6
  125. package/dist/_dts/sdk/src/cli/commands/push/scopes/types.d.ts +0 -87
  126. package/dist/_dts/sdk/src/cli/commands/push/scopes/venues.d.ts +0 -4
  127. package/dist/_dts/sdk/src/cli/commands/push/stale-resolution.d.ts +0 -48
  128. package/dist/_dts/sdk/src/cli/commands/push/stale.d.ts +0 -17
  129. package/dist/_dts/sdk/src/cli/commands/push/verification.d.ts +0 -56
  130. package/dist/_dts/sdk/src/cli/commands/push/workflowPlan.d.ts +0 -34
  131. package/dist/_dts/sdk/src/cli/commands/push-execute.d.ts +0 -54
  132. package/dist/_dts/sdk/src/cli/commands/push.d.ts +0 -40
  133. package/dist/_dts/sdk/src/cli/commands/setup.d.ts +0 -3
  134. package/dist/_dts/sdk/src/cli/commands/style.d.ts +0 -60
  135. package/dist/_dts/sdk/src/cli/commands/verify.d.ts +0 -11
  136. package/dist/_dts/sdk/src/cli/commands/webhooks.d.ts +0 -44
  137. package/dist/_dts/sdk/src/cli/config-loader.d.ts +0 -47
  138. package/dist/_dts/sdk/src/cli/content/collectionWriters.d.ts +0 -23
  139. package/dist/_dts/sdk/src/cli/content/edit/format.d.ts +0 -2
  140. package/dist/_dts/sdk/src/cli/content/edit/path.d.ts +0 -14
  141. package/dist/_dts/sdk/src/cli/content/edit/planner.d.ts +0 -46
  142. package/dist/_dts/sdk/src/cli/content/entryPaths.d.ts +0 -6
  143. package/dist/_dts/sdk/src/cli/content/footerFile.d.ts +0 -10
  144. package/dist/_dts/sdk/src/cli/content/fs-utils.d.ts +0 -39
  145. package/dist/_dts/sdk/src/cli/content/legacyEventScheduleShapeError.d.ts +0 -5
  146. package/dist/_dts/sdk/src/cli/content/localEventSchedule.d.ts +0 -17
  147. package/dist/_dts/sdk/src/cli/content/media-manifest.d.ts +0 -13
  148. package/dist/_dts/sdk/src/cli/content/metadataAfterPush.d.ts +0 -25
  149. package/dist/_dts/sdk/src/cli/content/metadataStore.d.ts +0 -29
  150. package/dist/_dts/sdk/src/cli/content/reader.d.ts +0 -488
  151. package/dist/_dts/sdk/src/cli/content/writer.d.ts +0 -142
  152. package/dist/_dts/sdk/src/cli/env-scope.d.ts +0 -2
  153. package/dist/_dts/sdk/src/cli/env.d.ts +0 -71
  154. package/dist/_dts/sdk/src/cli/errors.d.ts +0 -62
  155. package/dist/_dts/sdk/src/cli/helpers/ai-runtime.d.ts +0 -2
  156. package/dist/_dts/sdk/src/cli/helpers.d.ts +0 -399
  157. package/dist/_dts/sdk/src/cli/index.d.ts +0 -11
  158. package/dist/_dts/sdk/src/cli/init-docs/constants.d.ts +0 -16
  159. package/dist/_dts/sdk/src/cli/init-docs/index.d.ts +0 -12
  160. package/dist/_dts/sdk/src/cli/init-docs/templates.d.ts +0 -18
  161. package/dist/_dts/sdk/src/cli/init-docs/zod-to-markdown.d.ts +0 -28
  162. package/dist/_dts/sdk/src/cli/load-config.d.ts +0 -14
  163. package/dist/_dts/sdk/src/cli/media/identifiers.d.ts +0 -18
  164. package/dist/_dts/sdk/src/cli/media/local-media.d.ts +0 -14
  165. package/dist/_dts/sdk/src/cli/media/local-sync.d.ts +0 -91
  166. package/dist/_dts/sdk/src/cli/media/portable.d.ts +0 -11
  167. package/dist/_dts/sdk/src/cli/media/rich-text.d.ts +0 -12
  168. package/dist/_dts/sdk/src/cli/media/value-utils.d.ts +0 -15
  169. package/dist/_dts/sdk/src/cli/media/write-guard.d.ts +0 -52
  170. package/dist/_dts/sdk/src/cli/merge-remote/entryLocal.d.ts +0 -3
  171. package/dist/_dts/sdk/src/cli/merge-remote/entryMerge.d.ts +0 -78
  172. package/dist/_dts/sdk/src/cli/merge-remote/entryMergePlan.d.ts +0 -45
  173. package/dist/_dts/sdk/src/cli/merge-remote/entryMergePush.d.ts +0 -24
  174. package/dist/_dts/sdk/src/cli/merge-remote/entryMergeReport.d.ts +0 -18
  175. package/dist/_dts/sdk/src/cli/merge-remote/entryRemote.d.ts +0 -9
  176. package/dist/_dts/sdk/src/cli/merge-remote/entrySnapshots.d.ts +0 -48
  177. package/dist/_dts/sdk/src/cli/merge-remote/mergeFieldChanges.d.ts +0 -22
  178. package/dist/_dts/sdk/src/cli/merge-remote/pageLocal.d.ts +0 -3
  179. package/dist/_dts/sdk/src/cli/merge-remote/pageMerge.d.ts +0 -78
  180. package/dist/_dts/sdk/src/cli/merge-remote/pageMergePlan.d.ts +0 -36
  181. package/dist/_dts/sdk/src/cli/merge-remote/pageMergePush.d.ts +0 -23
  182. package/dist/_dts/sdk/src/cli/merge-remote/pageMergeReport.d.ts +0 -17
  183. package/dist/_dts/sdk/src/cli/merge-remote/pageSnapshots.d.ts +0 -46
  184. package/dist/_dts/sdk/src/cli/merge-remote/sharedBaseSnapshots.d.ts +0 -32
  185. package/dist/_dts/sdk/src/cli/merge-remote/sharedMergePlan.d.ts +0 -27
  186. package/dist/_dts/sdk/src/cli/merge-remote/sharedMergeReport.d.ts +0 -63
  187. package/dist/_dts/sdk/src/cli/migrations/entries.d.ts +0 -28
  188. package/dist/_dts/sdk/src/cli/migrations/events.d.ts +0 -73
  189. package/dist/_dts/sdk/src/cli/navigationIdentity.d.ts +0 -11
  190. package/dist/_dts/sdk/src/cli/output.d.ts +0 -133
  191. package/dist/_dts/sdk/src/cli/program.d.ts +0 -29
  192. package/dist/_dts/sdk/src/cli/push-config.d.ts +0 -49
  193. package/dist/_dts/sdk/src/cli/setup/setupPlan.d.ts +0 -51
  194. package/dist/_dts/sdk/src/cli/site-commands/commandKeys.d.ts +0 -13
  195. package/dist/_dts/sdk/src/cli/site-commands/commandRuntime.d.ts +0 -170
  196. package/dist/_dts/sdk/src/cli/site-commands/commandRuntimeCompat.d.ts +0 -21
  197. package/dist/_dts/sdk/src/cli/site-commands/commandSurfaceDispatch.d.ts +0 -32
  198. package/dist/_dts/sdk/src/cli/site-commands/datedOfferingCommands.d.ts +0 -53
  199. package/dist/_dts/sdk/src/cli/site-commands/entryCommands.d.ts +0 -65
  200. package/dist/_dts/sdk/src/cli/site-commands/eventScheduleCompiler.d.ts +0 -24
  201. package/dist/_dts/sdk/src/cli/site-commands/footerCommands.d.ts +0 -68
  202. package/dist/_dts/sdk/src/cli/site-commands/formCommands.d.ts +0 -53
  203. package/dist/_dts/sdk/src/cli/site-commands/index.d.ts +0 -8
  204. package/dist/_dts/sdk/src/cli/site-commands/localBlockManifestResolver.d.ts +0 -31
  205. package/dist/_dts/sdk/src/cli/site-commands/navigationCommands.d.ts +0 -57
  206. package/dist/_dts/sdk/src/cli/site-commands/oneOffCommands.d.ts +0 -82
  207. package/dist/_dts/sdk/src/cli/site-commands/pageCommands.d.ts +0 -84
  208. package/dist/_dts/sdk/src/cli/site-commands/pushExecution.d.ts +0 -39
  209. package/dist/_dts/sdk/src/cli/site-commands/pushExecutionPlan.d.ts +0 -8
  210. package/dist/_dts/sdk/src/cli/site-commands/pushExecutionTypes.d.ts +0 -97
  211. package/dist/_dts/sdk/src/cli/site-commands/residualSettingsTrimming.d.ts +0 -15
  212. package/dist/_dts/sdk/src/cli/sync/diff.d.ts +0 -222
  213. package/dist/_dts/sdk/src/cli/sync/executor.d.ts +0 -84
  214. package/dist/_dts/sdk/src/cli/sync/field-diff.d.ts +0 -39
  215. package/dist/_dts/sdk/src/cli/sync/index.d.ts +0 -10
  216. package/dist/_dts/sdk/src/cli/sync/mapper.d.ts +0 -41
  217. package/dist/_dts/sdk/src/cli/sync/media-sync.d.ts +0 -15
  218. package/dist/_dts/sdk/src/cli/sync/media.d.ts +0 -158
  219. package/dist/_dts/sdk/src/cli/sync/syncResultAggregation.d.ts +0 -4
  220. package/dist/_dts/sdk/src/cli/sync/validation.d.ts +0 -68
  221. package/dist/_dts/sdk/src/cli/utils/checksum.d.ts +0 -1
  222. package/dist/_dts/sdk/src/client/management/blocks.d.ts +0 -19
  223. package/dist/_dts/sdk/src/client/management/catalog.d.ts +0 -10
  224. package/dist/_dts/sdk/src/client/management/entries.d.ts +0 -6
  225. package/dist/_dts/sdk/src/client/management/eventCategories.d.ts +0 -6
  226. package/dist/_dts/sdk/src/client/management/events.d.ts +0 -7
  227. package/dist/_dts/sdk/src/client/management/footer.d.ts +0 -9
  228. package/dist/_dts/sdk/src/client/management/forms.d.ts +0 -6
  229. package/dist/_dts/sdk/src/client/management/http.d.ts +0 -79
  230. package/dist/_dts/sdk/src/client/management/identifiers.d.ts +0 -11
  231. package/dist/_dts/sdk/src/client/management/index.d.ts +0 -41
  232. package/dist/_dts/sdk/src/client/management/media.d.ts +0 -72
  233. package/dist/_dts/sdk/src/client/management/navigation.d.ts +0 -6
  234. package/dist/_dts/sdk/src/client/management/pages.d.ts +0 -6
  235. package/dist/_dts/sdk/src/client/management/pull.d.ts +0 -6
  236. package/dist/_dts/sdk/src/client/management/settings-branding.d.ts +0 -32
  237. package/dist/_dts/sdk/src/client/management/settings.d.ts +0 -6
  238. package/dist/_dts/sdk/src/client/management/theme.d.ts +0 -8
  239. package/dist/_dts/sdk/src/client/management/types.d.ts +0 -1069
  240. package/dist/_dts/sdk/src/client/management/venues.d.ts +0 -6
  241. package/dist/_dts/sdk/src/client/management/webhooks.d.ts +0 -3
  242. package/dist/_dts/sdk/src/test/env.d.ts +0 -4
  243. package/dist/_dts/site-commands/src/adapter.d.ts +0 -23
  244. package/dist/_dts/site-commands/src/appointmentCommandSchemas.d.ts +0 -100
  245. package/dist/_dts/site-commands/src/capabilityGaps.d.ts +0 -8
  246. package/dist/_dts/site-commands/src/commandContract.d.ts +0 -1277
  247. package/dist/_dts/site-commands/src/commandDomain.d.ts +0 -20
  248. package/dist/_dts/site-commands/src/commandIdentifiers.d.ts +0 -7
  249. package/dist/_dts/site-commands/src/commandValidation.d.ts +0 -10
  250. package/dist/_dts/site-commands/src/commands.d.ts +0 -1983
  251. package/dist/_dts/site-commands/src/domain.d.ts +0 -104
  252. package/dist/_dts/site-commands/src/eventCommandContent.d.ts +0 -11
  253. package/dist/_dts/site-commands/src/exposure.d.ts +0 -41
  254. package/dist/_dts/site-commands/src/guards.d.ts +0 -1
  255. package/dist/_dts/site-commands/src/index.d.ts +0 -18
  256. package/dist/_dts/site-commands/src/metadata.d.ts +0 -555
  257. package/dist/_dts/site-commands/src/pagePaths.d.ts +0 -6
  258. package/dist/_dts/site-commands/src/planner.d.ts +0 -58
  259. package/dist/_dts/site-commands/src/refContributions.d.ts +0 -11
  260. package/dist/_dts/site-commands/src/refs.d.ts +0 -90
  261. package/dist/_dts/site-commands/src/siteStyleCommandSchema.d.ts +0 -405
  262. package/dist/_dts/site-commands/src/siteStyleSelectionSchemaBuilder.d.ts +0 -46
  263. package/dist/_dts/site-commands/src/stableJson.d.ts +0 -5
  264. package/dist/_dts/site-commands/src/staticExecutionGaps.d.ts +0 -10
  265. package/dist/_dts/site-commands/src/venueCommandMapping.d.ts +0 -21
  266. package/dist/_dts/theme-core/src/data.d.ts +0 -12
  267. package/dist/_dts/theme-core/src/site-styles/headerStyleParts.d.ts +0 -4
  268. package/dist/cli/index.mjs +0 -162962
  269. package/dist/cli/init-docs/content/agents-section.md +0 -67
  270. package/dist/cli/init-docs/content/cli-reference.md +0 -1238
  271. package/dist/cli/init-docs/content/content-management.md +0 -792
  272. package/dist/cli/init-docs/content/context-brand.md +0 -125
  273. package/dist/cli/init-docs/content/context-brief.md +0 -77
  274. package/dist/cli/init-docs/content/context-knowledge.md +0 -111
  275. package/dist/cli/init-docs/content/getting-started.md +0 -171
  276. package/dist/cli/init-docs/content/site-workflows-readme.md +0 -96
  277. package/dist/cli/init-docs/content/workflow-add-block.md +0 -299
  278. package/dist/cli/init-docs/content/workflow-agent-safe-sync.md +0 -83
  279. package/dist/cli/init-docs/content/workflow-block-extensions.md +0 -370
  280. package/dist/cli/init-docs/content/workflow-cmsify-page.md +0 -357
  281. package/dist/cli/init-docs/content/workflow-content-types.md +0 -330
  282. package/dist/cli/init-docs/content/workflow-create-page.md +0 -212
  283. package/dist/cli/init-docs/content/workflow-custom-block.md +0 -470
  284. package/dist/cli/init-docs/content/workflow-editor-workflows.md +0 -130
  285. package/dist/cli/init-docs/content/workflow-isr-revalidation.md +0 -158
  286. package/dist/cli/init-docs/content/workflow-preview-mode.md +0 -239
  287. package/dist/cli/init-docs/content/workflow-publish.md +0 -285
  288. package/dist/cli/init-docs/content/workflow-remote-setup.md +0 -51
  289. package/dist/cli/init-docs/content/workflow-templates.md +0 -381
  290. /package/dist/_dts/{sdk/src/cli/utils/mime.d.ts → media-core/src/mimeType.d.ts} +0 -0
@@ -16903,32 +16903,15 @@ function parseBackgroundAppearanceColorToken(value) {
16903
16903
  function uniqueStrings(values) {
16904
16904
  return Array.from(new Set(values));
16905
16905
  }
16906
- const headerInteractionPaletteSchema = z$1.enum([
16907
- "primary",
16908
- "secondary",
16909
- "accent"
16910
- ]);
16911
- //#endregion
16912
- //#region ../theme-core/src/site-styles/headerInteractionPalette.ts
16913
- const clearSplitInteractionPalette = defineLookOptionGroup({
16914
- id: "interaction-palette",
16915
- label: "Hover colour",
16916
- defaultOptionId: "accent",
16917
- options: [
16918
- {
16919
- id: "accent",
16920
- label: "Accent"
16921
- },
16922
- {
16923
- id: "primary",
16924
- label: "Primary"
16925
- },
16926
- {
16927
- id: "secondary",
16928
- label: "Secondary"
16929
- }
16930
- ]
16931
- });
16906
+ function asHeaderLookId(value) {
16907
+ return value;
16908
+ }
16909
+ function asHeaderLayoutId(value) {
16910
+ return value;
16911
+ }
16912
+ function asHeaderStyleId(value) {
16913
+ return value;
16914
+ }
16932
16915
  //#endregion
16933
16916
  //#region ../theme-core/src/site-styles/logoBranding.ts
16934
16917
  const logoTextConfidenceValues = [
@@ -17019,15 +17002,8 @@ const logoSizePolicyValues = [
17019
17002
  "generous",
17020
17003
  "display"
17021
17004
  ];
17022
- function asHeaderLookId(value) {
17023
- return value;
17024
- }
17025
- function asHeaderLayoutId(value) {
17026
- return value;
17027
- }
17028
- function asHeaderStyleId(value) {
17029
- return value;
17030
- }
17005
+ //#endregion
17006
+ //#region ../theme-core/src/site-styles/headerLookBranding.ts
17031
17007
  const titleOnlyLogoAccommodation = {
17032
17008
  pattern: "title-only",
17033
17009
  supportedShapes: [
@@ -17146,21 +17122,34 @@ const overlayLogoAccommodations = [
17146
17122
  inlineMarkWithTitleLogoAccommodation,
17147
17123
  unbackedOverlayLogoAccommodation
17148
17124
  ];
17149
- /**
17150
- * Starts every Look from the generated theme's header branch, then clears
17151
- * optional nested styling fields that would otherwise leak from another Look.
17152
- */
17153
- function baseHeader(theme) {
17154
- const { navLinkStyle: _navLinkStyle, navFontRole: _navFontRole, navTypography: _navTypography, navTextSize: _navTextSize, interactionPalette: _interactionPalette, dropdownStyle: _dropdownStyle, ctaVariant: _ctaVariant, navContainer: _navContainer, container: _container, shadow: _shadow, logo: _logo, logoText: _logoText, border: _border, ...header } = theme.header;
17155
- return {
17156
- ...header,
17157
- navContainer: {
17158
- type: "none",
17159
- tint: null,
17160
- opacity: .15
17125
+ const headerInteractionPaletteSchema = z$1.enum([
17126
+ "primary",
17127
+ "secondary",
17128
+ "accent"
17129
+ ]);
17130
+ //#endregion
17131
+ //#region ../theme-core/src/site-styles/headerInteractionPalette.ts
17132
+ const clearSplitInteractionPalette = defineLookOptionGroup({
17133
+ id: "interaction-palette",
17134
+ label: "Hover colour",
17135
+ defaultOptionId: "accent",
17136
+ options: [
17137
+ {
17138
+ id: "accent",
17139
+ label: "Accent"
17140
+ },
17141
+ {
17142
+ id: "primary",
17143
+ label: "Primary"
17144
+ },
17145
+ {
17146
+ id: "secondary",
17147
+ label: "Secondary"
17161
17148
  }
17162
- };
17163
- }
17149
+ ]
17150
+ });
17151
+ //#endregion
17152
+ //#region ../theme-core/src/site-styles/headerLayoutStyleCatalog.ts
17164
17153
  const headerLayoutCatalog = defineExactCatalog()([
17165
17154
  {
17166
17155
  id: asHeaderLayoutId("classic"),
@@ -17565,6 +17554,19 @@ function getCompatibleHeaderStyleIds(layoutId) {
17565
17554
  return isHeaderStyleCompatibleWithLayout(getHeaderStyleOrThrow(styleId), layoutId);
17566
17555
  });
17567
17556
  }
17557
+ //#endregion
17558
+ //#region ../theme-core/src/site-styles/headerStyleCompilerPrimitives.ts
17559
+ function baseHeader(theme) {
17560
+ const { navLinkStyle: _navLinkStyle, navFontRole: _navFontRole, navTypography: _navTypography, navTextSize: _navTextSize, interactionPalette: _interactionPalette, dropdownStyle: _dropdownStyle, ctaVariant: _ctaVariant, navContainer: _navContainer, container: _container, shadow: _shadow, logo: _logo, logoText: _logoText, border: _border, ...header } = theme.header;
17561
+ return {
17562
+ ...header,
17563
+ navContainer: {
17564
+ type: "none",
17565
+ tint: null,
17566
+ opacity: .15
17567
+ }
17568
+ };
17569
+ }
17568
17570
  function applyNavTypography(style, typography) {
17569
17571
  switch (typography) {
17570
17572
  case "plain": return style;
@@ -17618,6 +17620,8 @@ function themedHeaderShadow(theme) {
17618
17620
  default: return assertNever$15(theme.shadow.elevation, "Unhandled theme shadow elevation");
17619
17621
  }
17620
17622
  }
17623
+ //#endregion
17624
+ //#region ../theme-core/src/site-styles/headerLegacyLooks.ts
17621
17625
  function solidBrandHeader(theme) {
17622
17626
  const ctaVariant = resolveHeaderCtaVariant(theme, "inverted");
17623
17627
  return {
@@ -60092,6 +60096,213 @@ function collectConstrainedVideoMediaValues(options) {
60092
60096
  return values;
60093
60097
  }
60094
60098
  //#endregion
60099
+ //#region ../blocks/src/system/manifest/hydrateLinks.ts
60100
+ /**
60101
+ * Hydrates link objects within block content using the provided route map. Returns
60102
+ * the original content reference when no mutations are required to avoid unnecessary renders.
60103
+ */
60104
+ function hydrateManifestLinks(manifest, content, routes, pagesByIdentifier, entriesByIdentifier) {
60105
+ if (!routes || !manifest?.fields?.length) return content;
60106
+ return hydrateValue(content, {
60107
+ routes,
60108
+ pagesByIdentifier,
60109
+ entriesByIdentifier
60110
+ });
60111
+ }
60112
+ function hydrateValue(value, context) {
60113
+ try {
60114
+ if (Array.isArray(value)) {
60115
+ const resolvedItems = value.map((item) => hydrateValue(item, context));
60116
+ return resolvedItems.every((item, index) => item === value[index]) ? value : resolvedItems;
60117
+ }
60118
+ if (isRecord$26(value)) {
60119
+ if (isInternalLink$1(value)) return hydrateInternalLink(value, context.routes);
60120
+ if (isPageLink$1(value)) return hydratePageLink(value, context);
60121
+ if (isEntryLink$1(value)) return hydrateEntryLink(value, context);
60122
+ const resolvedEntries = Object.entries(value).map(([key, entry]) => [key, hydrateValue(entry, context)]);
60123
+ return resolvedEntries.every(([key, entry]) => entry === value[key]) ? value : Object.fromEntries(resolvedEntries);
60124
+ }
60125
+ return value;
60126
+ } catch (err) {
60127
+ console.error("[hydrateLinks] Error hydrating value:", err, value);
60128
+ return value;
60129
+ }
60130
+ }
60131
+ function hydrateInternalLink(link, routes) {
60132
+ const resolved = resolveRouteTarget(link.routeId, routes);
60133
+ if (!resolved) return link;
60134
+ const nextHref = resolved.href;
60135
+ const currentHref = typeof link.href === "string" && link.href.length > 0 ? link.href : null;
60136
+ const nextUpdatedAt = resolved.updatedAt;
60137
+ const updates = {};
60138
+ if (nextHref && nextHref !== currentHref) updates.href = nextHref;
60139
+ if (nextUpdatedAt && link.updatedAt !== nextUpdatedAt) updates.updatedAt = nextUpdatedAt;
60140
+ return Object.keys(updates).length > 0 ? {
60141
+ ...link,
60142
+ ...updates
60143
+ } : link;
60144
+ }
60145
+ function isInternalLink$1(value) {
60146
+ if (value.kind !== "internal") return false;
60147
+ if (typeof value.routeId !== "string" || value.routeId.length === 0) return false;
60148
+ return true;
60149
+ }
60150
+ function isPageLink$1(value) {
60151
+ if (value.kind !== "page") return false;
60152
+ if (typeof value.identifier !== "string" || value.identifier.length === 0) return false;
60153
+ return true;
60154
+ }
60155
+ function hydratePageLink(link, context) {
60156
+ const resolved = resolvePageRouteTarget(link, context);
60157
+ if (!resolved) return link;
60158
+ return {
60159
+ ...link,
60160
+ href: resolved.href,
60161
+ routeId: resolved.routeId
60162
+ };
60163
+ }
60164
+ function isEntryLink$1(value) {
60165
+ if (value.kind !== "entry") return false;
60166
+ if (typeof value.contentType !== "string" || value.contentType.length === 0) return false;
60167
+ if (typeof value.identifier !== "string" || value.identifier.length === 0) return false;
60168
+ return true;
60169
+ }
60170
+ function hydrateEntryLink(link, context) {
60171
+ const resolved = resolveEntryRouteTarget(link, context);
60172
+ if (!resolved) return link;
60173
+ return {
60174
+ ...link,
60175
+ href: resolved.href,
60176
+ routeId: resolved.routeId
60177
+ };
60178
+ }
60179
+ //#endregion
60180
+ //#region ../blocks/src/sdkBlockTransform.ts
60181
+ /**
60182
+ * Transforms an SDK custom block into a BlockManifest.
60183
+ *
60184
+ * If the block has a `layout`, it can be rendered declaratively without React code.
60185
+ * If no layout, the block MUST use blockOverrides for rendering.
60186
+ */
60187
+ function transformSdkBlockToManifest(sdkBlock) {
60188
+ const hasLayout = Boolean(sdkBlock.layout) || Boolean(sdkBlock.variants && Object.keys(sdkBlock.variants).length > 0);
60189
+ return augmentManifest({
60190
+ name: sdkBlock.id,
60191
+ version: "1.0.0",
60192
+ title: sdkBlock.title,
60193
+ titleSource: sdkBlock.titleSource,
60194
+ description: sdkBlock.description,
60195
+ component: sdkBlock.id,
60196
+ fields: sdkBlock.fields,
60197
+ slots: [],
60198
+ category: sdkBlock.category,
60199
+ tags: sdkBlock.tags,
60200
+ icon: sdkBlock.icon,
60201
+ layout: sdkBlock.layout,
60202
+ variants: sdkBlock.variants,
60203
+ defaultVariant: sdkBlock.defaultVariant,
60204
+ variantOptions: sdkBlock.variantOptions,
60205
+ previewCustomize: sdkBlock.previewCustomize,
60206
+ behaviours: {
60207
+ supportsThemeSwitching: true,
60208
+ inlineEditing: hasLayout,
60209
+ animation: hasLayout,
60210
+ paletteHidden: false
60211
+ }
60212
+ });
60213
+ }
60214
+ /**
60215
+ * Transforms an SDK custom block into a SystemBlockDefinition.
60216
+ *
60217
+ * This creates a minimal definition with just the manifest - no data loaders
60218
+ * or content normalizers since SDK blocks handle their own rendering.
60219
+ */
60220
+ function transformSdkBlockToDefinition(sdkBlock) {
60221
+ return {
60222
+ manifest: transformSdkBlockToManifest(sdkBlock),
60223
+ dataLoaders: sdkBlock.dataLoaders
60224
+ };
60225
+ }
60226
+ //#endregion
60227
+ //#region ../blocks/src/customBlockRegistry.ts
60228
+ const defaultCustomBlockSourcePolicy = { kind: "canonical-db-fallback-sdk" };
60229
+ function isCustomBlockKind(blockKind) {
60230
+ return blockKind.startsWith("custom.");
60231
+ }
60232
+ function transformToBlockDescriptor(sdkBlock, source = "sdk") {
60233
+ return {
60234
+ name: sdkBlock.id,
60235
+ title: sdkBlock.title,
60236
+ description: sdkBlock.description,
60237
+ category: sdkBlock.category,
60238
+ tags: sdkBlock.tags,
60239
+ icon: sdkBlock.icon,
60240
+ definition: transformSdkBlockToDefinition(sdkBlock),
60241
+ source
60242
+ };
60243
+ }
60244
+ function toResolvedCustomBlock(manifest, source) {
60245
+ return {
60246
+ blockKind: manifest.id,
60247
+ manifest: transformSdkBlockToManifest(manifest),
60248
+ source,
60249
+ descriptor: transformToBlockDescriptor(manifest, source.kind === "managed-database" ? "database" : "sdk")
60250
+ };
60251
+ }
60252
+ function planCustomBlockRegistryResolution({ sdkConfig, customBlocks = [], policy = defaultCustomBlockSourcePolicy }) {
60253
+ switch (policy.kind) {
60254
+ case "canonical-db-fallback-sdk": {
60255
+ const entriesByKind = /* @__PURE__ */ new Map();
60256
+ const conflicts = [];
60257
+ for (const customBlock of customBlocks) entriesByKind.set(customBlock.manifest.id, toResolvedCustomBlock(customBlock.manifest, customBlock.source));
60258
+ for (const sdkBlock of sdkConfig?.customBlocks ?? []) {
60259
+ const existing = entriesByKind.get(sdkBlock.id);
60260
+ if (existing) {
60261
+ conflicts.push({
60262
+ kind: "conflict",
60263
+ blockKind: existing.blockKind,
60264
+ winner: existing.source,
60265
+ loser: { kind: "sdk-config" },
60266
+ reason: "db-canonical-sdk-fallback"
60267
+ });
60268
+ continue;
60269
+ }
60270
+ entriesByKind.set(sdkBlock.id, toResolvedCustomBlock(sdkBlock, { kind: "sdk-config" }));
60271
+ }
60272
+ return {
60273
+ policy,
60274
+ entries: Array.from(entriesByKind.values()),
60275
+ conflicts
60276
+ };
60277
+ }
60278
+ }
60279
+ }
60280
+ function createCustomBlockRegistry({ sdkConfig, customBlocks = [], policy = defaultCustomBlockSourcePolicy, onConflict }) {
60281
+ const plan = planCustomBlockRegistryResolution({
60282
+ sdkConfig,
60283
+ customBlocks,
60284
+ policy
60285
+ });
60286
+ const entriesByKind = new Map(plan.entries.map((entry) => [entry.blockKind, entry]));
60287
+ for (const conflict of plan.conflicts) onConflict?.(`Using ${sourceLabel(conflict.winner)} custom block "${conflict.blockKind}" - ${sourceLabel(conflict.loser)} block is fallback only`);
60288
+ return {
60289
+ entries: plan.entries,
60290
+ conflicts: plan.conflicts,
60291
+ findManifest: (blockKind) => {
60292
+ if (!isCustomBlockKind(blockKind)) return void 0;
60293
+ return entriesByKind.get(blockKind);
60294
+ }
60295
+ };
60296
+ }
60297
+ function sourceLabel(source) {
60298
+ switch (source.kind) {
60299
+ case "managed-database": return "DB";
60300
+ case "sdk-synced": return "SDK-synced DB";
60301
+ case "sdk-config": return "SDK config";
60302
+ default: return assertNever$24(source);
60303
+ }
60304
+ }
60305
+ //#endregion
60095
60306
  //#region ../theme-core/src/runtime/fontFamily.ts
60096
60307
  /**
60097
60308
  * Font Family Formatting Utilities
@@ -63829,215 +64040,115 @@ function mapFontStyle(italic) {
63829
64040
  return italic ? "italic" : "normal";
63830
64041
  }
63831
64042
  //#endregion
63832
- //#region ../blocks/src/system/manifest/hydrateLinks.ts
63833
- /**
63834
- * Hydrates link objects within block content using the provided route map. Returns
63835
- * the original content reference when no mutations are required to avoid unnecessary renders.
63836
- */
63837
- function hydrateManifestLinks(manifest, content, routes, pagesByIdentifier, entriesByIdentifier) {
63838
- if (!routes || !manifest?.fields?.length) return content;
63839
- return hydrateValue(content, {
63840
- routes,
63841
- pagesByIdentifier,
63842
- entriesByIdentifier
63843
- });
63844
- }
63845
- function hydrateValue(value, context) {
63846
- try {
63847
- if (Array.isArray(value)) {
63848
- const resolvedItems = value.map((item) => hydrateValue(item, context));
63849
- return resolvedItems.every((item, index) => item === value[index]) ? value : resolvedItems;
63850
- }
63851
- if (isRecord$26(value)) {
63852
- if (isInternalLink$1(value)) return hydrateInternalLink(value, context.routes);
63853
- if (isPageLink$1(value)) return hydratePageLink(value, context);
63854
- if (isEntryLink$1(value)) return hydrateEntryLink(value, context);
63855
- const resolvedEntries = Object.entries(value).map(([key, entry]) => [key, hydrateValue(entry, context)]);
63856
- return resolvedEntries.every(([key, entry]) => entry === value[key]) ? value : Object.fromEntries(resolvedEntries);
63857
- }
63858
- return value;
63859
- } catch (err) {
63860
- console.error("[hydrateLinks] Error hydrating value:", err, value);
63861
- return value;
64043
+ //#region ../blocks/src/pageRenderingMode.ts
64044
+ var MissingBlockOverrideError$1 = class extends Error {
64045
+ constructor(blockKind) {
64046
+ super(`Override-only rendering requires an override for block kind "${blockKind}".`);
64047
+ this.blockKind = blockKind;
64048
+ this.code = "missing_block_override";
64049
+ this.name = "MissingBlockOverrideError";
63862
64050
  }
64051
+ };
64052
+ function isOverrideOnlyResourceInput(props) {
64053
+ return props.rendering?.kind === "overrides-only";
63863
64054
  }
63864
- function hydrateInternalLink(link, routes) {
63865
- const resolved = resolveRouteTarget(link.routeId, routes);
63866
- if (!resolved) return link;
63867
- const nextHref = resolved.href;
63868
- const currentHref = typeof link.href === "string" && link.href.length > 0 ? link.href : null;
63869
- const nextUpdatedAt = resolved.updatedAt;
63870
- const updates = {};
63871
- if (nextHref && nextHref !== currentHref) updates.href = nextHref;
63872
- if (nextUpdatedAt && link.updatedAt !== nextUpdatedAt) updates.updatedAt = nextUpdatedAt;
63873
- return Object.keys(updates).length > 0 ? {
63874
- ...link,
63875
- ...updates
63876
- } : link;
63877
- }
63878
- function isInternalLink$1(value) {
63879
- if (value.kind !== "internal") return false;
63880
- if (typeof value.routeId !== "string" || value.routeId.length === 0) return false;
63881
- return true;
63882
- }
63883
- function isPageLink$1(value) {
63884
- if (value.kind !== "page") return false;
63885
- if (typeof value.identifier !== "string" || value.identifier.length === 0) return false;
63886
- return true;
63887
- }
63888
- function hydratePageLink(link, context) {
63889
- const resolved = resolvePageRouteTarget(link, context);
63890
- if (!resolved) return link;
64055
+ function resolvePageThemeResources(props) {
64056
+ if (isOverrideOnlyResourceInput(props)) return { kind: "unavailable" };
63891
64057
  return {
63892
- ...link,
63893
- href: resolved.href,
63894
- routeId: resolved.routeId
64058
+ kind: "available",
64059
+ tokens: props.themeTokens ?? buildThemeRuntime$1(props.theme).tokens,
64060
+ config: props.theme
63895
64061
  };
63896
64062
  }
63897
- function isEntryLink$1(value) {
63898
- if (value.kind !== "entry") return false;
63899
- if (typeof value.contentType !== "string" || value.contentType.length === 0) return false;
63900
- if (typeof value.identifier !== "string" || value.identifier.length === 0) return false;
63901
- return true;
64063
+ function requireBlockOverride(resources, override, blockKind) {
64064
+ if (resources.kind === "unavailable" && !override) throw new MissingBlockOverrideError$1(blockKind);
63902
64065
  }
63903
- function hydrateEntryLink(link, context) {
63904
- const resolved = resolveEntryRouteTarget(link, context);
63905
- if (!resolved) return link;
63906
- return {
63907
- ...link,
63908
- href: resolved.href,
63909
- routeId: resolved.routeId
63910
- };
64066
+ function overrideThemeProps(resources) {
64067
+ return resources.kind === "available" ? {
64068
+ theme: resources.tokens,
64069
+ themeConfig: resources.config
64070
+ } : {};
64071
+ }
64072
+ function requireThemeResources(resources, blockKind) {
64073
+ if (resources.kind === "unavailable") throw new MissingBlockOverrideError$1(blockKind);
64074
+ return resources;
63911
64075
  }
63912
64076
  //#endregion
63913
- //#region ../blocks/src/sdkBlockTransform.ts
63914
- /**
63915
- * Transforms an SDK custom block into a BlockManifest.
63916
- *
63917
- * If the block has a `layout`, it can be rendered declaratively without React code.
63918
- * If no layout, the block MUST use blockOverrides for rendering.
63919
- */
63920
- function transformSdkBlockToManifest(sdkBlock) {
63921
- const hasLayout = Boolean(sdkBlock.layout) || Boolean(sdkBlock.variants && Object.keys(sdkBlock.variants).length > 0);
63922
- return augmentManifest({
63923
- name: sdkBlock.id,
63924
- version: "1.0.0",
63925
- title: sdkBlock.title,
63926
- titleSource: sdkBlock.titleSource,
63927
- description: sdkBlock.description,
63928
- component: sdkBlock.id,
63929
- fields: sdkBlock.fields,
63930
- slots: [],
63931
- category: sdkBlock.category,
63932
- tags: sdkBlock.tags,
63933
- icon: sdkBlock.icon,
63934
- layout: sdkBlock.layout,
63935
- variants: sdkBlock.variants,
63936
- defaultVariant: sdkBlock.defaultVariant,
63937
- variantOptions: sdkBlock.variantOptions,
63938
- previewCustomize: sdkBlock.previewCustomize,
63939
- behaviours: {
63940
- supportsThemeSwitching: true,
63941
- inlineEditing: hasLayout,
63942
- animation: hasLayout,
63943
- paletteHidden: false
63944
- }
63945
- });
64077
+ //#region ../blocks/src/pageRendererBoundaries.tsx
64078
+ const boundaryKey = (previousBlockId, nextBlockId) => `${previousBlockId}\u0000${nextBlockId}`;
64079
+ function isSiteStyleTransitionStyleGroup(value) {
64080
+ return value?.startsWith("site-style-transition-") === true;
63946
64081
  }
63947
- /**
63948
- * Transforms an SDK custom block into a SystemBlockDefinition.
63949
- *
63950
- * This creates a minimal definition with just the manifest - no data loaders
63951
- * or content normalizers since SDK blocks handle their own rendering.
63952
- */
63953
- function transformSdkBlockToDefinition(sdkBlock) {
63954
- return {
63955
- manifest: transformSdkBlockToManifest(sdkBlock),
63956
- dataLoaders: sdkBlock.dataLoaders
63957
- };
64082
+ function boundaryMapForAdjacentBlockIds(boundaries) {
64083
+ return new Map(boundaries.map((boundary) => [boundaryKey(boundary.previousBlockId, boundary.nextBlockId), boundary]));
63958
64084
  }
63959
- //#endregion
63960
- //#region ../blocks/src/customBlockRegistry.ts
63961
- const defaultCustomBlockSourcePolicy = { kind: "canonical-db-fallback-sdk" };
63962
- function isCustomBlockKind(blockKind) {
63963
- return blockKind.startsWith("custom.");
64085
+ function boundaryBetweenBlocks(previousBlock, nextBlock, boundaries) {
64086
+ const previousBlockId = previousBlock?.id ?? null;
64087
+ const nextBlockId = nextBlock?.id ?? null;
64088
+ if (!previousBlockId || !nextBlockId) return null;
64089
+ return boundaries.get(boundaryKey(previousBlockId, nextBlockId)) ?? null;
63964
64090
  }
63965
- function transformToBlockDescriptor(sdkBlock, source = "sdk") {
64091
+ function renderBoundaryAfterBlock(input) {
64092
+ const previousBlockId = input.block.id;
64093
+ const nextBlockId = input.nextBlock?.id ?? null;
64094
+ if (!previousBlockId || !nextBlockId) return null;
64095
+ const boundary = input.boundaryByAdjacentBlockIds.get(boundaryKey(previousBlockId, nextBlockId));
64096
+ if (!boundary) return null;
64097
+ const rendered = /* @__PURE__ */ jsx("div", {
64098
+ "aria-hidden": "true",
64099
+ "data-block-boundary": "",
64100
+ "data-boundary-id": boundary.boundaryId,
64101
+ "data-boundary-previous-block-id": boundary.previousBlockId,
64102
+ "data-boundary-next-block-id": boundary.nextBlockId,
64103
+ "data-style-group": boundary.styleGroup,
64104
+ style: boundaryCssVarsStyle(boundary)
64105
+ }, `${input.blockKey}:boundary`);
64106
+ return input.wrapBoundary ? input.wrapBoundary(boundary, rendered) : rendered;
64107
+ }
64108
+ function boundaryCssVarsStyle(boundary) {
63966
64109
  return {
63967
- name: sdkBlock.id,
63968
- title: sdkBlock.title,
63969
- description: sdkBlock.description,
63970
- category: sdkBlock.category,
63971
- tags: sdkBlock.tags,
63972
- icon: sdkBlock.icon,
63973
- definition: transformSdkBlockToDefinition(sdkBlock),
63974
- source
64110
+ "--site-style-transition-from": boundary.cssVars.from,
64111
+ "--site-style-transition-to": boundary.cssVars.to
63975
64112
  };
63976
64113
  }
63977
- function toResolvedCustomBlock(manifest, source) {
64114
+ function boundaryReserveCssVarsStyle(input) {
64115
+ const before = input.before?.metrics.reserveCss ?? null;
64116
+ const after = input.after?.metrics.reserveCss ?? null;
64117
+ if (!before && !after) return void 0;
63978
64118
  return {
63979
- blockKind: manifest.id,
63980
- manifest: transformSdkBlockToManifest(manifest),
63981
- source,
63982
- descriptor: transformToBlockDescriptor(manifest, source.kind === "managed-database" ? "database" : "sdk")
64119
+ ...before ? { "--site-style-boundary-before-reserve": before } : {},
64120
+ ...after ? { "--site-style-boundary-after-reserve": after } : {}
63983
64121
  };
63984
64122
  }
63985
- function planCustomBlockRegistryResolution({ sdkConfig, customBlocks = [], policy = defaultCustomBlockSourcePolicy }) {
63986
- switch (policy.kind) {
63987
- case "canonical-db-fallback-sdk": {
63988
- const entriesByKind = /* @__PURE__ */ new Map();
63989
- const conflicts = [];
63990
- for (const customBlock of customBlocks) entriesByKind.set(customBlock.manifest.id, toResolvedCustomBlock(customBlock.manifest, customBlock.source));
63991
- for (const sdkBlock of sdkConfig?.customBlocks ?? []) {
63992
- const existing = entriesByKind.get(sdkBlock.id);
63993
- if (existing) {
63994
- conflicts.push({
63995
- kind: "conflict",
63996
- blockKind: existing.blockKind,
63997
- winner: existing.source,
63998
- loser: { kind: "sdk-config" },
63999
- reason: "db-canonical-sdk-fallback"
64000
- });
64001
- continue;
64002
- }
64003
- entriesByKind.set(sdkBlock.id, toResolvedCustomBlock(sdkBlock, { kind: "sdk-config" }));
64004
- }
64005
- return {
64006
- policy,
64007
- entries: Array.from(entriesByKind.values()),
64008
- conflicts
64009
- };
64010
- }
64011
- }
64123
+ function transitionCssVarsStyle(content) {
64124
+ const transitionStyles = isObjectRecord$1(content._transitionStyles) ? content._transitionStyles : null;
64125
+ const cssVars = isObjectRecord$1(transitionStyles?.cssVars) ? transitionStyles.cssVars : null;
64126
+ const from = typeof cssVars?.from === "string" ? cssVars.from : null;
64127
+ const to = typeof cssVars?.to === "string" ? cssVars.to : null;
64128
+ if (!from && !to) return void 0;
64129
+ return {
64130
+ ...from ? { "--site-style-transition-from": from } : {},
64131
+ ...to ? { "--site-style-transition-to": to } : {}
64132
+ };
64012
64133
  }
64013
- function createCustomBlockRegistry({ sdkConfig, customBlocks = [], policy = defaultCustomBlockSourcePolicy, onConflict }) {
64014
- const plan = planCustomBlockRegistryResolution({
64015
- sdkConfig,
64016
- customBlocks,
64017
- policy
64018
- });
64019
- const entriesByKind = new Map(plan.entries.map((entry) => [entry.blockKind, entry]));
64020
- for (const conflict of plan.conflicts) onConflict?.(`Using ${sourceLabel(conflict.winner)} custom block "${conflict.blockKind}" - ${sourceLabel(conflict.loser)} block is fallback only`);
64134
+ function mergeStyleObjects(left, right) {
64135
+ if (!left) return right;
64136
+ if (!right) return left;
64021
64137
  return {
64022
- entries: plan.entries,
64023
- conflicts: plan.conflicts,
64024
- findManifest: (blockKind) => {
64025
- if (!isCustomBlockKind(blockKind)) return void 0;
64026
- return entriesByKind.get(blockKind);
64027
- }
64138
+ ...left,
64139
+ ...right
64028
64140
  };
64029
64141
  }
64030
- function sourceLabel(source) {
64031
- switch (source.kind) {
64032
- case "managed-database": return "DB";
64033
- case "sdk-synced": return "SDK-synced DB";
64034
- case "sdk-config": return "SDK config";
64035
- default: return assertNever$24(source);
64036
- }
64142
+ function pageBlockPosition(index, blockCount) {
64143
+ if (blockCount <= 1) return "only";
64144
+ if (index === 0) return "first";
64145
+ if (index === blockCount - 1) return "last";
64146
+ return "middle";
64037
64147
  }
64038
64148
  //#endregion
64039
64149
  //#region ../blocks/src/PageRenderer.tsx
64040
- function PageRenderer$1({ theme, page, runtimeBoundaries, usePlaceholders = false, dataContext, wrapBlock, wrapBoundary, registry, themeTokens: providedThemeTokens, routeMap, blockOverrides, sdkConfig, customBlocks, previewAuthoring }) {
64150
+ function PageRenderer$1(props) {
64151
+ const { page, runtimeBoundaries, usePlaceholders = false, dataContext, wrapBlock, wrapBoundary, registry, routeMap, blockOverrides, sdkConfig, customBlocks, previewAuthoring } = props;
64041
64152
  const imageResolveContext = React$1.useMemo(() => resolvePageRendererImageResolveContext(dataContext), [
64042
64153
  dataContext?.imageResolveContext,
64043
64154
  dataContext?.mediaAssets,
@@ -64046,12 +64157,16 @@ function PageRenderer$1({ theme, page, runtimeBoundaries, usePlaceholders = fals
64046
64157
  ]);
64047
64158
  const boundaryByAdjacentBlockIds = React$1.useMemo(() => boundaryMapForAdjacentBlockIds(runtimeBoundaries ?? []), [runtimeBoundaries]);
64048
64159
  const usesRuntimeBoundaries = runtimeBoundaries !== void 0;
64160
+ const themeResources = React$1.useMemo(() => resolvePageThemeResources(props), [
64161
+ props.rendering,
64162
+ props.theme,
64163
+ props.themeTokens
64164
+ ]);
64049
64165
  if (!page || page.blocks.length === 0) return /* @__PURE__ */ jsx("div", {
64050
64166
  className: "rb-p-6 rb-caption",
64051
64167
  style: textColorStyle("mutedText"),
64052
64168
  children: "No blocks found."
64053
64169
  });
64054
- const themeTokens = providedThemeTokens ?? buildThemeRuntime$1(theme).tokens;
64055
64170
  const resolvedRegistry = registry ?? getDefaultComponentRegistry();
64056
64171
  setContextResolveImageUrlContext(imageResolveContext);
64057
64172
  return /* @__PURE__ */ jsx("div", { children: page.blocks.map((block, index) => {
@@ -64074,22 +64189,14 @@ function PageRenderer$1({ theme, page, runtimeBoundaries, usePlaceholders = fals
64074
64189
  const renderableContent = getRenderableContent(block, dataContext?.previewStage);
64075
64190
  const variantKey = definition?.manifest ? resolveVariantKey(definition.manifest, renderableContent) : null;
64076
64191
  const shouldUseWrapper = !managesOwnWrapper || Boolean(wrapBlock);
64077
- const blockSectionProps = {
64078
- themeTokens,
64079
- themeConfig: theme,
64192
+ const blockSectionProps = buildBlockSectionProps({
64193
+ props,
64194
+ themeResources,
64080
64195
  block,
64081
- usePlaceholders,
64082
- dataContext,
64083
64196
  blockKey,
64084
- registry: resolvedRegistry,
64085
- routeMap,
64086
- wrapBlock,
64087
- blockOverrides,
64088
- sdkConfig,
64089
- customBlocks,
64090
64197
  imageResolveContext,
64091
- previewAuthoring
64092
- };
64198
+ registry: resolvedRegistry
64199
+ });
64093
64200
  if (!shouldUseWrapper) {
64094
64201
  const rendered = /* @__PURE__ */ jsx(MemoBlockSection, { ...blockSectionProps }, `${blockKey}:block`);
64095
64202
  return boundaryElement ? /* @__PURE__ */ jsxs(React$1.Fragment, { children: [rendered, boundaryElement] }, blockKey) : rendered;
@@ -64131,81 +64238,6 @@ function PageRenderer$1({ theme, page, runtimeBoundaries, usePlaceholders = fals
64131
64238
  })] }, blockKey);
64132
64239
  }) });
64133
64240
  }
64134
- function isSiteStyleTransitionStyleGroup(value) {
64135
- return value?.startsWith("site-style-transition-") === true;
64136
- }
64137
- function boundaryMapForAdjacentBlockIds(boundaries) {
64138
- return new Map(boundaries.map((boundary) => [boundaryKey(boundary.previousBlockId, boundary.nextBlockId), boundary]));
64139
- }
64140
- function boundaryKey(previousBlockId, nextBlockId) {
64141
- return `${previousBlockId}\u0000${nextBlockId}`;
64142
- }
64143
- function boundaryBetweenBlocks(previousBlock, nextBlock, boundaryByAdjacentBlockIds) {
64144
- const previousBlockId = previousBlock?.id ?? null;
64145
- const nextBlockId = nextBlock?.id ?? null;
64146
- if (!previousBlockId || !nextBlockId) return null;
64147
- return boundaryByAdjacentBlockIds.get(boundaryKey(previousBlockId, nextBlockId)) ?? null;
64148
- }
64149
- function renderBoundaryAfterBlock(input) {
64150
- const previousBlockId = input.block.id;
64151
- const nextBlockId = input.nextBlock?.id ?? null;
64152
- if (!previousBlockId || !nextBlockId) return null;
64153
- const boundary = input.boundaryByAdjacentBlockIds.get(boundaryKey(previousBlockId, nextBlockId));
64154
- if (!boundary) return null;
64155
- const rendered = /* @__PURE__ */ jsx("div", {
64156
- "aria-hidden": "true",
64157
- "data-block-boundary": "",
64158
- "data-boundary-id": boundary.boundaryId,
64159
- "data-boundary-previous-block-id": boundary.previousBlockId,
64160
- "data-boundary-next-block-id": boundary.nextBlockId,
64161
- "data-style-group": boundary.styleGroup,
64162
- style: boundaryCssVarsStyle(boundary)
64163
- }, `${input.blockKey}:boundary`);
64164
- return input.wrapBoundary ? input.wrapBoundary(boundary, rendered) : rendered;
64165
- }
64166
- function boundaryCssVarsStyle(boundary) {
64167
- return {
64168
- "--site-style-transition-from": boundary.cssVars.from,
64169
- "--site-style-transition-to": boundary.cssVars.to
64170
- };
64171
- }
64172
- function boundaryReserveCssVarsStyle(input) {
64173
- const before = input.before ? boundaryReserveValueForTreatment(input.before) : null;
64174
- const after = input.after ? boundaryReserveValueForTreatment(input.after) : null;
64175
- if (!before && !after) return void 0;
64176
- return {
64177
- ...before ? { "--site-style-boundary-before-reserve": before } : {},
64178
- ...after ? { "--site-style-boundary-after-reserve": after } : {}
64179
- };
64180
- }
64181
- function boundaryReserveValueForTreatment(boundary) {
64182
- return boundary.metrics.reserveCss;
64183
- }
64184
- function transitionCssVarsStyle(content) {
64185
- const transitionStyles = isObjectRecord$1(content._transitionStyles) ? content._transitionStyles : null;
64186
- const cssVars = isObjectRecord$1(transitionStyles?.cssVars) ? transitionStyles.cssVars : null;
64187
- const from = typeof cssVars?.from === "string" ? cssVars.from : null;
64188
- const to = typeof cssVars?.to === "string" ? cssVars.to : null;
64189
- if (!from && !to) return void 0;
64190
- return {
64191
- ...from ? { "--site-style-transition-from": from } : {},
64192
- ...to ? { "--site-style-transition-to": to } : {}
64193
- };
64194
- }
64195
- function mergeStyleObjects(left, right) {
64196
- if (!left) return right;
64197
- if (!right) return left;
64198
- return {
64199
- ...left,
64200
- ...right
64201
- };
64202
- }
64203
- function pageBlockPosition(index, blockCount) {
64204
- if (blockCount <= 1) return "only";
64205
- if (index === 0) return "first";
64206
- if (index === blockCount - 1) return "last";
64207
- return "middle";
64208
- }
64209
64241
  function resolvePageRendererImageResolveContext(dataContext) {
64210
64242
  const input = dataContext?.imageResolveContext;
64211
64243
  return buildResolveImageUrlContext({
@@ -64215,6 +64247,23 @@ function resolvePageRendererImageResolveContext(dataContext) {
64215
64247
  mediaAssets: input?.mediaAssets ?? dataContext?.mediaAssets
64216
64248
  });
64217
64249
  }
64250
+ function buildBlockSectionProps(input) {
64251
+ return {
64252
+ themeResources: input.themeResources,
64253
+ block: input.block,
64254
+ usePlaceholders: input.props.usePlaceholders ?? false,
64255
+ dataContext: input.props.dataContext,
64256
+ blockKey: input.blockKey,
64257
+ registry: input.registry,
64258
+ routeMap: input.props.routeMap,
64259
+ wrapBlock: input.props.wrapBlock,
64260
+ blockOverrides: input.props.blockOverrides,
64261
+ sdkConfig: input.props.sdkConfig,
64262
+ customBlocks: input.props.customBlocks,
64263
+ imageResolveContext: input.imageResolveContext,
64264
+ previewAuthoring: input.props.previewAuthoring
64265
+ };
64266
+ }
64218
64267
  /**
64219
64268
  * Look up a block override component by block kind.
64220
64269
  * Supports both full ("block.hero") and short ("hero") keys.
@@ -64281,7 +64330,7 @@ function getCachedValidator(manifest, flavour) {
64281
64330
  * referential equality of all props that affect rendering. Standard React.memo
64282
64331
  * wouldn't catch all the render triggers from the editor store.
64283
64332
  */
64284
- const MemoBlockSection = React$1.memo(function MemoBlockSection({ themeTokens, themeConfig, block, usePlaceholders, dataContext, registry, routeMap, wrapBlock, blockOverrides, sdkConfig, customBlocks, imageResolveContext, previewAuthoring }) {
64333
+ const MemoBlockSection = React$1.memo(function MemoBlockSection({ themeResources, block, usePlaceholders, dataContext, registry, routeMap, wrapBlock, blockOverrides, sdkConfig, customBlocks, imageResolveContext, previewAuthoring }) {
64285
64334
  const perfStart = globalThis.process?.env?.DEBUG_PERF === "1" && typeof window === "undefined" ? Date.now() : 0;
64286
64335
  const fallbackImageResolveContext = getCurrentResolveImageUrlContext();
64287
64336
  const resolvedImageResolveContext = imageResolveContext ?? fallbackImageResolveContext;
@@ -64302,6 +64351,7 @@ const MemoBlockSection = React$1.memo(function MemoBlockSection({ themeTokens, t
64302
64351
  return node;
64303
64352
  }
64304
64353
  const OverrideComponent = getBlockOverride(block.kind, blockOverrides);
64354
+ requireBlockOverride(themeResources, OverrideComponent, block.kind);
64305
64355
  let definition = getBlockDefinition(block.kind);
64306
64356
  if (!definition && block.kind.startsWith("custom.")) definition = createCustomBlockRegistry({
64307
64357
  sdkConfig,
@@ -64314,8 +64364,7 @@ const MemoBlockSection = React$1.memo(function MemoBlockSection({ themeTokens, t
64314
64364
  if (OverrideComponent) {
64315
64365
  const rendered = /* @__PURE__ */ jsx(OverrideComponent, {
64316
64366
  content: getRenderableContent(block, dataContext?.previewStage),
64317
- theme: themeTokens,
64318
- themeConfig,
64367
+ ...overrideThemeProps(themeResources),
64319
64368
  data: void 0,
64320
64369
  siteId: dataContext?.siteId,
64321
64370
  apiBaseUrl: dataContext?.apiBaseUrl,
@@ -64414,8 +64463,7 @@ const MemoBlockSection = React$1.memo(function MemoBlockSection({ themeTokens, t
64414
64463
  const hasResolvedData = !!resolved && typeof resolved === "object" && Object.keys(resolved).length > 0;
64415
64464
  const baseProps = {
64416
64465
  content: hydratedContent,
64417
- theme: themeTokens,
64418
- themeConfig,
64466
+ ...overrideThemeProps(themeResources),
64419
64467
  data: resolved,
64420
64468
  siteId: dataContext?.siteId,
64421
64469
  apiBaseUrl: dataContext?.apiBaseUrl,
@@ -64435,6 +64483,7 @@ const MemoBlockSection = React$1.memo(function MemoBlockSection({ themeTokens, t
64435
64483
  let rendered;
64436
64484
  if (OverrideComponent) rendered = /* @__PURE__ */ jsx(OverrideComponent, { ...baseProps });
64437
64485
  else {
64486
+ requireThemeResources(themeResources, block.kind);
64438
64487
  const BlockComponent = getCachedBlockComponent(definition.manifest);
64439
64488
  const pathBase = typeof block.id === "string" && block.id.length > 0 ? `blocks.${block.id}.` : void 0;
64440
64489
  const rootContext = { $root: {
@@ -64484,7 +64533,7 @@ const MemoBlockSection = React$1.memo(function MemoBlockSection({ themeTokens, t
64484
64533
  });
64485
64534
  }
64486
64535
  }, (prev, next) => {
64487
- return prev.block === next.block && prev.registry === next.registry && prev.dataContext === next.dataContext && prev.themeTokens === next.themeTokens && prev.themeConfig === next.themeConfig && prev.routeMap === next.routeMap && prev.usePlaceholders === next.usePlaceholders && prev.wrapBlock === next.wrapBlock && prev.blockOverrides === next.blockOverrides && prev.sdkConfig === next.sdkConfig && prev.customBlocks === next.customBlocks && prev.imageResolveContext === next.imageResolveContext && prev.previewAuthoring === next.previewAuthoring;
64536
+ return prev.block === next.block && prev.registry === next.registry && prev.dataContext === next.dataContext && prev.themeResources === next.themeResources && prev.routeMap === next.routeMap && prev.usePlaceholders === next.usePlaceholders && prev.wrapBlock === next.wrapBlock && prev.blockOverrides === next.blockOverrides && prev.sdkConfig === next.sdkConfig && prev.customBlocks === next.customBlocks && prev.imageResolveContext === next.imageResolveContext && prev.previewAuthoring === next.previewAuthoring;
64488
64537
  });
64489
64538
  function fallback(message) {
64490
64539
  return /* @__PURE__ */ jsx("div", {
@@ -78348,6 +78397,25 @@ z$1.object({
78348
78397
  mode: z$1.enum(["apply", "preview"]).optional()
78349
78398
  }).strict();
78350
78399
  //#endregion
78400
+ //#region ../api/src/sdkThemeWire.ts
78401
+ /**
78402
+ * Validate a wire value without replacing it with the schema's parsed output.
78403
+ * The returned type is deliberately the schema input, not its canonical output.
78404
+ */
78405
+ function losslessValidatedSchema(schema) {
78406
+ return z$1.unknown().superRefine((value, ctx) => {
78407
+ const parsed = schema.safeParse(value);
78408
+ if (parsed.success) return;
78409
+ for (const issue of parsed.error.issues) ctx.addIssue({
78410
+ code: "custom",
78411
+ path: issue.path,
78412
+ message: issue.message,
78413
+ params: { validationCode: issue.code }
78414
+ });
78415
+ }).transform((value) => value);
78416
+ }
78417
+ losslessValidatedSchema(themeSchema);
78418
+ //#endregion
78351
78419
  //#region ../api/src/siteOnboarding.ts
78352
78420
  const LAUNCH_REQUIREMENT_OVERRIDE_DEFINITIONS = { configure_appointments: {
78353
78421
  requirementId: "configure_appointments",
@@ -83010,8 +83078,9 @@ function toBlocksImageResolveContextInput(context) {
83010
83078
  mediaAssets: toBlocksMediaAssets(context.mediaAssets)
83011
83079
  };
83012
83080
  }
83013
- //#endregion
83014
- //#region src/rendering/blocks-page-renderer.ts
83081
+ function isOverrideOnlyPageRenderer(props) {
83082
+ return props.rendering?.kind === "overrides-only";
83083
+ }
83015
83084
  function normalizeSdkCustomBlocks(customBlocks) {
83016
83085
  if (!customBlocks) return void 0;
83017
83086
  return customBlocks.map((block) => {
@@ -83042,15 +83111,23 @@ function toBlocksPageRendererDataContext(dataContext) {
83042
83111
  }
83043
83112
  function PageRenderer(props) {
83044
83113
  const blocksSdkConfig = props.sdkConfig ? { customBlocks: normalizeSdkCustomBlocks(props.sdkConfig.customBlocks) } : props.sdkConfig;
83045
- const blocksTheme = parseBlocksTheme(props.theme);
83046
- const blocksProps = {
83047
- ...props,
83048
- theme: blocksTheme,
83114
+ const { rendering: _rendering, theme: _theme, themeTokens: _themeTokens, ...commonProps } = props;
83115
+ const commonBlocksProps = {
83116
+ ...commonProps,
83049
83117
  dataContext: props.dataContext ? toBlocksPageRendererDataContext(props.dataContext) : void 0,
83050
83118
  blockOverrides: toBlocksBlockOverrides(props.blockOverrides),
83051
83119
  sdkConfig: blocksSdkConfig,
83052
83120
  customBlocks: normalizeSdkCustomBlocks(props.customBlocks)
83053
83121
  };
83122
+ const blocksProps = isOverrideOnlyPageRenderer(props) ? {
83123
+ ...commonBlocksProps,
83124
+ rendering: { kind: "overrides-only" },
83125
+ blockOverrides: toBlocksBlockOverrides(props.blockOverrides) ?? {}
83126
+ } : {
83127
+ ...commonBlocksProps,
83128
+ theme: parseBlocksTheme(props.theme),
83129
+ themeTokens: props.themeTokens
83130
+ };
83054
83131
  return React$1.createElement(PageRenderer$1, blocksProps);
83055
83132
  }
83056
83133
  //#endregion
@@ -83081,8 +83158,31 @@ function renderWithSdkThemeRuntime({ themeRuntime, theme, children }) {
83081
83158
  default: return assertNever$24(themeRuntime);
83082
83159
  }
83083
83160
  }
83161
+ function renderWithOverrideOnlyRuntime({ runtime, children }) {
83162
+ switch (runtime.kind) {
83163
+ case "responsive-only": return /* @__PURE__ */ jsx(ResponsiveScope, {
83164
+ responsiveMode: runtime.responsiveMode,
83165
+ children
83166
+ });
83167
+ case "none": return /* @__PURE__ */ jsx(Fragment, { children });
83168
+ default: return assertNever$24(runtime);
83169
+ }
83170
+ }
83084
83171
  //#endregion
83085
83172
  //#region src/rendering/components/pageShared.tsx
83173
+ function isOverrideOnlyPage(props) {
83174
+ return props.rendering?.kind === "overrides-only";
83175
+ }
83176
+ function resolvePageThemeTokens(props) {
83177
+ const baseTokens = props.themeTokens ?? buildThemeRuntime(props.theme).tokens;
83178
+ return props.sdkConfig?.theme?.palette ? {
83179
+ ...baseTokens,
83180
+ palette: {
83181
+ ...baseTokens.palette,
83182
+ ...props.sdkConfig.theme.palette
83183
+ }
83184
+ } : baseTokens;
83185
+ }
83086
83186
  function toPageHydrationBootstrapConfig(props) {
83087
83187
  return {
83088
83188
  siteId: props.siteId,
@@ -83090,150 +83190,76 @@ function toPageHydrationBootstrapConfig(props) {
83090
83190
  mediaAssets: props.mediaAssets
83091
83191
  };
83092
83192
  }
83093
- function PageContent({ page, runtimeBoundaries, theme, themeTokens: providedTokens, siteId, resolvedData, bookingOfferingPresets, routeMap, pagesByIdentifier, entriesByIdentifier, wrapBlock, registry, usePlaceholders = false, blockOverrides, sdkConfig, customBlocks, supabaseUrl, mediaAssets, apiBaseUrl, portalToken, previewToken, dataContext, themeRuntime = defaultPageThemeRuntime }) {
83094
- const baseTokens = providedTokens ?? buildThemeRuntime(theme).tokens;
83095
- return renderWithSdkThemeRuntime({
83096
- themeRuntime,
83097
- theme,
83098
- children: /* @__PURE__ */ jsx(PageRenderer, {
83099
- theme,
83100
- page,
83101
- runtimeBoundaries,
83102
- themeTokens: sdkConfig?.theme?.palette ? {
83103
- ...baseTokens,
83104
- palette: {
83105
- ...baseTokens.palette,
83106
- ...sdkConfig.theme.palette
83107
- }
83108
- } : baseTokens,
83109
- usePlaceholders,
83110
- dataContext: {
83193
+ function PageContent(props) {
83194
+ const { page, runtimeBoundaries, siteId, resolvedData, bookingOfferingPresets, routeMap, pagesByIdentifier, entriesByIdentifier, wrapBlock, registry, usePlaceholders = false, blockOverrides, sdkConfig, customBlocks, supabaseUrl, mediaAssets, apiBaseUrl, portalToken, previewToken, dataContext } = props;
83195
+ const rendererCommonProps = {
83196
+ page,
83197
+ runtimeBoundaries,
83198
+ usePlaceholders,
83199
+ dataContext: {
83200
+ siteId,
83201
+ apiBaseUrl,
83202
+ portalToken,
83203
+ previewToken,
83204
+ resolvedData,
83205
+ bookingOfferingPresets: bookingOfferingPresets ?? [],
83206
+ routes: routeMap,
83207
+ pagesByIdentifier,
83208
+ entriesByIdentifier,
83209
+ occurrenceContext: dataContext?.occurrenceContext ?? null,
83210
+ entrySubrouteContext: dataContext?.entrySubrouteContext ?? null,
83211
+ contentEntry: dataContext?.contentEntry ?? null,
83212
+ pageSurface: dataContext?.pageSurface ?? null,
83213
+ subject: dataContext?.subject ?? null,
83214
+ editableRouteMetadataFieldIds: dataContext?.editableRouteMetadataFieldIds ?? null,
83215
+ previewStage: dataContext?.previewStage,
83216
+ supabaseUrl,
83217
+ mediaAssets,
83218
+ imageResolveContext: {
83111
83219
  siteId,
83112
- apiBaseUrl,
83113
- portalToken,
83114
- previewToken,
83115
- resolvedData,
83116
- bookingOfferingPresets: bookingOfferingPresets ?? [],
83117
- routes: routeMap,
83118
- pagesByIdentifier,
83119
- entriesByIdentifier,
83120
- occurrenceContext: dataContext?.occurrenceContext ?? null,
83121
- entrySubrouteContext: dataContext?.entrySubrouteContext ?? null,
83122
- contentEntry: dataContext?.contentEntry ?? null,
83123
- pageSurface: dataContext?.pageSurface ?? null,
83124
- subject: dataContext?.subject ?? null,
83125
- editableRouteMetadataFieldIds: dataContext?.editableRouteMetadataFieldIds ?? null,
83126
- previewStage: dataContext?.previewStage,
83127
83220
  supabaseUrl,
83128
- mediaAssets,
83129
- imageResolveContext: {
83130
- siteId,
83131
- supabaseUrl,
83132
- mediaAssets
83133
- }
83134
- },
83135
- routeMap,
83136
- wrapBlock,
83137
- registry,
83138
- blockOverrides,
83139
- sdkConfig: sdkConfig ? { customBlocks: sdkConfig.customBlocks } : null,
83140
- customBlocks
83141
- })
83221
+ mediaAssets
83222
+ }
83223
+ },
83224
+ routeMap,
83225
+ wrapBlock,
83226
+ registry,
83227
+ sdkConfig: sdkConfig ? { customBlocks: sdkConfig.customBlocks } : null,
83228
+ customBlocks
83229
+ };
83230
+ const content = isOverrideOnlyPage(props) ? /* @__PURE__ */ jsx(PageRenderer, {
83231
+ ...rendererCommonProps,
83232
+ rendering: { kind: "overrides-only" },
83233
+ blockOverrides: props.blockOverrides
83234
+ }) : /* @__PURE__ */ jsx(PageRenderer, {
83235
+ ...rendererCommonProps,
83236
+ theme: props.theme,
83237
+ themeTokens: resolvePageThemeTokens(props),
83238
+ blockOverrides
83239
+ });
83240
+ return isOverrideOnlyPage(props) ? renderWithOverrideOnlyRuntime({
83241
+ runtime: props.rendering.runtime,
83242
+ children: content
83243
+ }) : renderWithSdkThemeRuntime({
83244
+ themeRuntime: props.themeRuntime ?? defaultPageThemeRuntime,
83245
+ theme: props.theme,
83246
+ children: content
83142
83247
  });
83143
83248
  }
83144
83249
  //#endregion
83145
- //#region src/rendering/components/Page.server.tsx
83146
- function Page(props) {
83147
- return /* @__PURE__ */ jsx(PageContent, { ...props });
83148
- }
83149
- //#endregion
83150
- //#region src/rendering/overrides.ts
83151
- const lazyBlockOverrideSymbol = Symbol.for("riverbankcms.sdk.lazyBlockOverride");
83152
- //#endregion
83153
- //#region src/rendering/overrideResolution.ts
83154
- function isRecord(value) {
83155
- return typeof value === "object" && value !== null;
83156
- }
83157
- function isBlockOutlineLike(value) {
83158
- const id = value.id;
83159
- return typeof value.kind === "string" && (typeof id === "string" || id === null) && (typeof value.purpose === "string" || isRecord(value.content) || isRecord(value.draftContent) || isRecord(value.bindings));
83160
- }
83161
- /**
83162
- * Walk a page's block tree and collect override candidate kinds.
83163
- *
83164
- * The CMS block contract is structural at this boundary: nested blocks can live
83165
- * inside custom block content, so traversal cannot rely on a fixed property
83166
- * name. To avoid matching arbitrary content such as `{ kind: "video" }`, only
83167
- * objects with a block identity (`id` plus `kind`) and at least one block
83168
- * contract field (`purpose`, `content`, `draftContent`, or `bindings`) count.
83169
- */
83170
- function collectBlockKindsFromValue(value, usedKinds, seen) {
83171
- if (!isRecord(value)) return;
83172
- if (seen.has(value)) return;
83173
- seen.add(value);
83174
- if (isBlockOutlineLike(value)) usedKinds.add(value.kind);
83175
- for (const child of Object.values(value)) {
83176
- if (Array.isArray(child)) {
83177
- for (const item of child) collectBlockKindsFromValue(item, usedKinds, seen);
83178
- continue;
83179
- }
83180
- collectBlockKindsFromValue(child, usedKinds, seen);
83181
- }
83182
- }
83183
- function collectUsedBlockKindsFromPageOutline(page) {
83184
- const usedKinds = /* @__PURE__ */ new Set();
83185
- const seen = /* @__PURE__ */ new WeakSet();
83186
- for (const block of page?.blocks ?? []) collectBlockKindsFromValue(block, usedKinds, seen);
83187
- return usedKinds;
83188
- }
83189
- function buildPageBlockKindIndex(page) {
83190
- return {
83191
- kind: "page-block-kind-index",
83192
- blockKinds: collectUsedBlockKindsFromPageOutline(page)
83250
+ //#region src/rendering/renderingMode.ts
83251
+ const defaultOverrideOnlyRuntime = { kind: "responsive-only" };
83252
+ function normalizeSdkRenderingMode(input) {
83253
+ return input.rendering?.kind === "overrides-only" ? {
83254
+ kind: "overrides-only",
83255
+ runtime: input.rendering.runtime ?? defaultOverrideOnlyRuntime
83256
+ } : {
83257
+ kind: "themed",
83258
+ themeRuntime: input.themeRuntime
83193
83259
  };
83194
83260
  }
83195
- function shortBlockKind(blockKind) {
83196
- return blockKind.replace(/^block\./, "");
83197
- }
83198
- function selectOverrideKeysForUsedKinds(usedKinds, entries) {
83199
- const availableKeys = new Set(entries.map(([key]) => key));
83200
- const selectedKeys = /* @__PURE__ */ new Set();
83201
- for (const blockKind of usedKinds) {
83202
- if (availableKeys.has(blockKind)) {
83203
- selectedKeys.add(blockKind);
83204
- continue;
83205
- }
83206
- const shortKind = shortBlockKind(blockKind);
83207
- if (availableKeys.has(shortKind)) selectedKeys.add(shortKind);
83208
- }
83209
- return selectedKeys;
83210
- }
83211
- function isLazyRegistration(registration) {
83212
- return isRecord(registration) && registration[lazyBlockOverrideSymbol] === true;
83213
- }
83214
- async function resolveOverrideComponent(registration) {
83215
- if (isLazyRegistration(registration)) return registration.load();
83216
- return registration;
83217
- }
83218
- /**
83219
- * Resolve only override registrations used by the current page or template.
83220
- *
83221
- * Eager components are passed through unchanged. Lazy registrations created
83222
- * with `defineLazyBlockOverride()` are loaded only after their block kind is
83223
- * found in the rendered block tree.
83224
- */
83225
- async function resolveBlockOverridesForPage(registrations, page) {
83226
- if (!registrations) return void 0;
83227
- const entries = Object.entries(registrations);
83228
- if (entries.length === 0) return void 0;
83229
- const selectedKeys = selectOverrideKeysForUsedKinds(buildPageBlockKindIndex(page).blockKinds, entries);
83230
- if (selectedKeys.size === 0) return void 0;
83231
- const resolved = {};
83232
- for (const [key, registration] of entries) {
83233
- if (!selectedKeys.has(key)) continue;
83234
- resolved[key] = await resolveOverrideComponent(registration);
83235
- }
83236
- return resolved;
83261
+ function themeRuntimeForRendering(rendering) {
83262
+ return rendering.kind === "themed" ? rendering.themeRuntime : rendering.runtime;
83237
83263
  }
83238
83264
  //#endregion
83239
83265
  //#region src/metadata/generatePageMetadata.ts
@@ -84306,7 +84332,7 @@ var CircuitOpenError = class extends Error {
84306
84332
  * 1. This constant
84307
84333
  * 2. The "version" field in package.json
84308
84334
  */
84309
- const SDK_VERSION = "0.128.0";
84335
+ const SDK_VERSION = "0.129.1";
84310
84336
  //#endregion
84311
84337
  //#region src/next/content-load-failure.ts
84312
84338
  const SdkContentLoadError = RiverbankContentLoadError;
@@ -84467,6 +84493,159 @@ function appendSearchToRedirectDestination(destination, incomingSearch) {
84467
84493
  return `${destination.slice(0, hashIndex)}?${search}${destination.slice(hashIndex)}`;
84468
84494
  }
84469
84495
  //#endregion
84496
+ //#region src/rendering/components/Page.server.tsx
84497
+ function Page(props) {
84498
+ return /* @__PURE__ */ jsx(PageContent, { ...props });
84499
+ }
84500
+ //#endregion
84501
+ //#region src/rendering/overrides.ts
84502
+ const lazyBlockOverrideSymbol = Symbol.for("riverbankcms.sdk.lazyBlockOverride");
84503
+ //#endregion
84504
+ //#region src/rendering/overrideResolution.ts
84505
+ function isRecord(value) {
84506
+ return typeof value === "object" && value !== null;
84507
+ }
84508
+ function isBlockOutlineLike(value) {
84509
+ const id = value.id;
84510
+ return typeof value.kind === "string" && (typeof id === "string" || id === null) && (typeof value.purpose === "string" || isRecord(value.content) || isRecord(value.draftContent) || isRecord(value.bindings));
84511
+ }
84512
+ /**
84513
+ * Walk a page's block tree and collect override candidate kinds.
84514
+ *
84515
+ * The CMS block contract is structural at this boundary: nested blocks can live
84516
+ * inside custom block content, so traversal cannot rely on a fixed property
84517
+ * name. To avoid matching arbitrary content such as `{ kind: "video" }`, only
84518
+ * objects with a block identity (`id` plus `kind`) and at least one block
84519
+ * contract field (`purpose`, `content`, `draftContent`, or `bindings`) count.
84520
+ */
84521
+ function collectBlockKindsFromValue(value, usedKinds, seen) {
84522
+ if (!isRecord(value)) return;
84523
+ if (seen.has(value)) return;
84524
+ seen.add(value);
84525
+ if (isBlockOutlineLike(value)) usedKinds.add(value.kind);
84526
+ for (const child of Object.values(value)) {
84527
+ if (Array.isArray(child)) {
84528
+ for (const item of child) collectBlockKindsFromValue(item, usedKinds, seen);
84529
+ continue;
84530
+ }
84531
+ collectBlockKindsFromValue(child, usedKinds, seen);
84532
+ }
84533
+ }
84534
+ function collectUsedBlockKindsFromPageOutline(page) {
84535
+ const usedKinds = /* @__PURE__ */ new Set();
84536
+ const seen = /* @__PURE__ */ new WeakSet();
84537
+ for (const block of page?.blocks ?? []) collectBlockKindsFromValue(block, usedKinds, seen);
84538
+ return usedKinds;
84539
+ }
84540
+ function buildPageBlockKindIndex(page) {
84541
+ return {
84542
+ kind: "page-block-kind-index",
84543
+ blockKinds: collectUsedBlockKindsFromPageOutline(page)
84544
+ };
84545
+ }
84546
+ function shortBlockKind(blockKind) {
84547
+ return blockKind.replace(/^block\./, "");
84548
+ }
84549
+ function selectOverrideKeysForUsedKinds(usedKinds, entries) {
84550
+ const availableKeys = new Set(entries.map(([key]) => key));
84551
+ const selectedKeys = /* @__PURE__ */ new Set();
84552
+ for (const blockKind of usedKinds) {
84553
+ if (availableKeys.has(blockKind)) {
84554
+ selectedKeys.add(blockKind);
84555
+ continue;
84556
+ }
84557
+ const shortKind = shortBlockKind(blockKind);
84558
+ if (availableKeys.has(shortKind)) selectedKeys.add(shortKind);
84559
+ }
84560
+ return selectedKeys;
84561
+ }
84562
+ function isLazyRegistration(registration) {
84563
+ return isRecord(registration) && registration[lazyBlockOverrideSymbol] === true;
84564
+ }
84565
+ async function resolveOverrideComponent(registration) {
84566
+ if (isLazyRegistration(registration)) return registration.load();
84567
+ return registration;
84568
+ }
84569
+ /**
84570
+ * Resolve only override registrations used by the current page or template.
84571
+ *
84572
+ * Eager components are passed through unchanged. Lazy registrations created
84573
+ * with `defineLazyBlockOverride()` are loaded only after their block kind is
84574
+ * found in the rendered block tree.
84575
+ */
84576
+ async function resolveBlockOverridesForPage(registrations, page) {
84577
+ if (!registrations) return void 0;
84578
+ const entries = Object.entries(registrations);
84579
+ if (entries.length === 0) return void 0;
84580
+ const selectedKeys = selectOverrideKeysForUsedKinds(buildPageBlockKindIndex(page).blockKinds, entries);
84581
+ if (selectedKeys.size === 0) return void 0;
84582
+ const resolved = {};
84583
+ for (const [key, registration] of entries) {
84584
+ if (!selectedKeys.has(key)) continue;
84585
+ resolved[key] = await resolveOverrideComponent(registration);
84586
+ }
84587
+ return resolved;
84588
+ }
84589
+ //#endregion
84590
+ //#region src/next/renderSdkContent.tsx
84591
+ async function renderPage(input, page, dataContext) {
84592
+ const resolvedOverrides = await resolveBlockOverridesForPage(input.blockOverrides, page);
84593
+ const commonProps = {
84594
+ page,
84595
+ siteId: input.content.siteId,
84596
+ apiBaseUrl: input.apiBaseUrl,
84597
+ portalToken: input.portalToken,
84598
+ resolvedData: input.content.resolvedData,
84599
+ bookingOfferingPresets: input.content.bookingOfferingPresets,
84600
+ sdkConfig: input.content.sdkConfig,
84601
+ supabaseUrl: input.content.supabaseUrl,
84602
+ mediaAssets: input.content.mediaAssets,
84603
+ dataContext
84604
+ };
84605
+ return input.kind === "overrides-only" ? /* @__PURE__ */ jsx(Page, {
84606
+ ...commonProps,
84607
+ rendering: input.rendering,
84608
+ blockOverrides: resolvedOverrides ?? {}
84609
+ }) : /* @__PURE__ */ jsx(Page, {
84610
+ ...commonProps,
84611
+ theme: input.theme,
84612
+ themeRuntime: input.themeRuntime,
84613
+ blockOverrides: resolvedOverrides
84614
+ });
84615
+ }
84616
+ async function renderSdkContent(input) {
84617
+ const previewStage = input.preview ? "preview" : "published";
84618
+ const occurrenceContext = input.entrySubrouteContext?.kind === "event-occurrence" ? input.entrySubrouteContext.occurrence : null;
84619
+ const render = (page, dataContext) => renderPage(input, page, dataContext);
84620
+ if (isPageContent(input.content)) return {
84621
+ kind: "rendered",
84622
+ node: await render(input.content.page, { previewStage })
84623
+ };
84624
+ if (isEntryContent(input.content)) {
84625
+ if (!input.content.templatePage) return { kind: "not-found" };
84626
+ return {
84627
+ kind: "rendered",
84628
+ node: await render(input.content.templatePage, {
84629
+ contentEntry: input.content.dataContext.contentEntry,
84630
+ occurrenceContext,
84631
+ entrySubrouteContext: input.entrySubrouteContext,
84632
+ previewStage
84633
+ })
84634
+ };
84635
+ }
84636
+ if (!isPageSurfaceContent(input.content) || !input.content.templatePage) return { kind: "not-found" };
84637
+ return {
84638
+ kind: "rendered",
84639
+ node: await render(input.content.templatePage, {
84640
+ occurrenceContext,
84641
+ entrySubrouteContext: input.entrySubrouteContext,
84642
+ pageSurface: input.content.dataContext.pageSurface,
84643
+ subject: input.content.dataContext.subject,
84644
+ previewStage
84645
+ })
84646
+ };
84647
+ }
84648
+ //#endregion
84470
84649
  //#region src/next/catch-all.tsx
84471
84650
  function throwUpstreamContentError(path, resolution) {
84472
84651
  throw new RiverbankContentLoadError(`Riverbank content load failed for ${path}: ${resolution.error.message}`, {
@@ -84476,14 +84655,34 @@ function throwUpstreamContentError(path, resolution) {
84476
84655
  });
84477
84656
  }
84478
84657
  function createCatchAllRuntime(options) {
84658
+ validateCatchAllRenderingOptions(options);
84659
+ const preview = options.preview ?? detectPreviewFromClient(options.getClient);
84660
+ const rendering = normalizeSdkRenderingMode({
84661
+ rendering: options.rendering,
84662
+ themeRuntime: options.themeRuntime ?? defaultCatchAllThemeRuntime
84663
+ });
84479
84664
  return {
84480
84665
  options,
84481
- preview: options.preview ?? detectPreviewFromClient(options.getClient),
84666
+ preview,
84482
84667
  enablePortal: options.enablePortal ?? options.config.enablePortal ?? false,
84483
84668
  contentTypes: (options.config.content?.contentTypes ?? []).map(toRoutingInfo),
84484
- themeRuntime: options.themeRuntime ?? defaultCatchAllThemeRuntime
84669
+ rendering,
84670
+ themeRuntime: themeRuntimeForRendering(rendering)
84485
84671
  };
84486
84672
  }
84673
+ var InvalidCatchAllRenderingOptionsError = class extends Error {
84674
+ constructor(code) {
84675
+ super(code === "missing_block_overrides" ? "Override-only rendering requires blockOverrides." : code === "theme_runtime_in_overrides_only" ? "Override-only rendering owns its runtime wrapper; remove themeRuntime." : "Override-only rendering cannot be combined with theme resolution options.");
84676
+ this.code = code;
84677
+ this.name = "InvalidCatchAllRenderingOptionsError";
84678
+ }
84679
+ };
84680
+ function validateCatchAllRenderingOptions(options) {
84681
+ if (options.rendering?.kind !== "overrides-only") return;
84682
+ if (!options.blockOverrides) throw new InvalidCatchAllRenderingOptionsError("missing_block_overrides");
84683
+ if ("themeRuntime" in options) throw new InvalidCatchAllRenderingOptionsError("theme_runtime_in_overrides_only");
84684
+ if ("theme" in options || "themes" in options || "themeSwitch" in options || "getTheme" in options) throw new InvalidCatchAllRenderingOptionsError("theme_option_in_overrides_only");
84685
+ }
84487
84686
  const pageNotFoundMetadata = () => ({
84488
84687
  title: "Page Not Found",
84489
84688
  robots: {
@@ -84621,6 +84820,7 @@ async function resolveCatchAllTheme(runtime, input) {
84621
84820
  path: input.path,
84622
84821
  preview: runtime.preview,
84623
84822
  themeRuntime: runtime.themeRuntime,
84823
+ rendering: runtime.rendering,
84624
84824
  searchParams: input.searchParams,
84625
84825
  config: runtime.options.config,
84626
84826
  themeKey: requestedThemeKey(runtime, input.searchParams)
@@ -84637,60 +84837,6 @@ async function resolveCatchAllTheme(runtime, input) {
84637
84837
  context
84638
84838
  });
84639
84839
  }
84640
- async function renderPageComponent(runtime, input) {
84641
- const resolvedBlockOverrides = await resolveBlockOverridesForPage(runtime.options.blockOverrides, input.page);
84642
- return /* @__PURE__ */ jsx(Page, {
84643
- page: input.page,
84644
- theme: input.theme,
84645
- siteId: input.content.siteId,
84646
- apiBaseUrl: input.apiBaseUrl,
84647
- portalToken: input.portalToken,
84648
- resolvedData: input.content.resolvedData,
84649
- bookingOfferingPresets: input.content.bookingOfferingPresets,
84650
- blockOverrides: resolvedBlockOverrides,
84651
- sdkConfig: input.content.sdkConfig,
84652
- supabaseUrl: input.content.supabaseUrl,
84653
- mediaAssets: input.content.mediaAssets,
84654
- themeRuntime: runtime.themeRuntime,
84655
- dataContext: input.dataContext
84656
- });
84657
- }
84658
- async function renderSdkContent(runtime, input) {
84659
- const previewStage = runtime.preview ? "preview" : "published";
84660
- const occurrenceContext = input.entrySubrouteContext?.kind === "event-occurrence" ? input.entrySubrouteContext.occurrence : null;
84661
- const render = (page, dataContext) => renderPageComponent(runtime, {
84662
- ...input,
84663
- page,
84664
- dataContext
84665
- });
84666
- if (isPageContent(input.content)) return {
84667
- kind: "rendered",
84668
- node: await render(input.content.page, { previewStage })
84669
- };
84670
- if (isEntryContent(input.content)) {
84671
- if (!input.content.templatePage) return { kind: "not-found" };
84672
- return {
84673
- kind: "rendered",
84674
- node: await render(input.content.templatePage, {
84675
- contentEntry: input.content.dataContext.contentEntry,
84676
- occurrenceContext,
84677
- entrySubrouteContext: input.entrySubrouteContext,
84678
- previewStage
84679
- })
84680
- };
84681
- }
84682
- if (!isPageSurfaceContent(input.content) || !input.content.templatePage) return { kind: "not-found" };
84683
- return {
84684
- kind: "rendered",
84685
- node: await render(input.content.templatePage, {
84686
- occurrenceContext,
84687
- entrySubrouteContext: input.entrySubrouteContext,
84688
- pageSurface: input.content.dataContext.pageSurface,
84689
- subject: input.content.dataContext.subject,
84690
- previewStage
84691
- })
84692
- };
84693
- }
84694
84840
  async function renderResolvedCatchAllPage(runtime, input) {
84695
84841
  if (runtime.options.beforeRender) {
84696
84842
  const intercepted = await runtime.options.beforeRender({
@@ -84698,20 +84844,36 @@ async function renderResolvedCatchAllPage(runtime, input) {
84698
84844
  path: input.path,
84699
84845
  preview: runtime.preview,
84700
84846
  themeRuntime: runtime.themeRuntime,
84847
+ rendering: runtime.rendering,
84701
84848
  searchParams: input.searchParams
84702
84849
  });
84703
84850
  if (intercepted !== null) return wrapCatchAllNode(runtime, intercepted);
84704
84851
  }
84705
- const themeResult = await resolveCatchAllTheme(runtime, input);
84706
- if (themeResult.kind === "not-found") return notFound();
84707
- if (themeResult.warning) console.warn(themeResult.warning);
84708
- const rendered = await renderSdkContent(runtime, {
84852
+ const commonRenderInput = {
84709
84853
  apiBaseUrl: input.apiBaseUrl,
84710
84854
  content: input.content,
84711
84855
  entrySubrouteContext: input.entrySubrouteContext,
84712
- portalToken: input.portalToken,
84713
- theme: themeResult.theme
84714
- });
84856
+ portalToken: input.portalToken
84857
+ };
84858
+ const rendered = runtime.rendering.kind === "overrides-only" ? await renderSdkContent({
84859
+ ...commonRenderInput,
84860
+ blockOverrides: runtime.options.blockOverrides,
84861
+ kind: "overrides-only",
84862
+ preview: runtime.preview,
84863
+ rendering: runtime.rendering
84864
+ }) : await (async () => {
84865
+ const themeResult = await resolveCatchAllTheme(runtime, input);
84866
+ if (themeResult.kind === "not-found") return notFound();
84867
+ if (themeResult.warning) console.warn(themeResult.warning);
84868
+ return renderSdkContent({
84869
+ ...commonRenderInput,
84870
+ blockOverrides: runtime.options.blockOverrides,
84871
+ kind: "themed",
84872
+ preview: runtime.preview,
84873
+ theme: themeResult.theme,
84874
+ themeRuntime: runtime.themeRuntime
84875
+ });
84876
+ })();
84715
84877
  if (rendered.kind === "not-found") return notFound();
84716
84878
  return wrapCatchAllNode(runtime, /* @__PURE__ */ jsxs("main", { children: [/* @__PURE__ */ jsx(BlocksIslandsHydrator, { ...toPageHydrationBootstrapConfig({
84717
84879
  siteId: input.content.siteId,
@@ -84776,6 +84938,7 @@ async function resolveCatchAllMetadata(runtime, input) {
84776
84938
  path: input.path,
84777
84939
  preview: runtime.preview,
84778
84940
  themeRuntime: runtime.themeRuntime,
84941
+ rendering: runtime.rendering,
84779
84942
  searchParams: input.searchParams
84780
84943
  });
84781
84944
  const resolvedUrl = runtime.options.siteUrl ?? (runtime.preview ? runtime.options.config.previewUrl : runtime.options.config.liveUrl) ?? "";
@@ -86794,4 +86957,4 @@ function getISRConfig() {
86794
86957
  };
86795
86958
  }
86796
86959
  //#endregion
86797
- export { ISR_REVALIDATE_SECONDS, RiverbankContentLoadError, SdkContentLoadError, classifyContentLoadError, createCatchAllPage, createGenerateStaticParams, createRobots, createSitemap, generateAllStaticParams, getISRConfig, isSdkContentLoadError, normalizeStaticRoutePath, pathToSlugArray, routesToStaticParams, toContentLoadFailureLogFields, validateStaticParamsEnv };
86960
+ export { ISR_REVALIDATE_SECONDS, InvalidCatchAllRenderingOptionsError, RiverbankContentLoadError, SdkContentLoadError, classifyContentLoadError, createCatchAllPage, createGenerateStaticParams, createRobots, createSitemap, generateAllStaticParams, getISRConfig, isSdkContentLoadError, normalizeStaticRoutePath, pathToSlugArray, routesToStaticParams, toContentLoadFailureLogFields, validateStaticParamsEnv };