@riverbankcms/sdk 0.136.0 → 0.137.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 (160) hide show
  1. package/CHANGELOG.md +101 -0
  2. package/dist/{PreviewEditorSidebar-BU5ZlhQR.mjs → PreviewEditorSidebar-Bn6cONPa.mjs} +8 -8
  3. package/dist/{PreviewEditorUI-9XkHL-bC.mjs → PreviewEditorUI-LAwXZPSx.mjs} +3 -3
  4. package/dist/{PreviewQueryProvider-wbEpXryy.mjs → PreviewQueryProvider-ztQUdsNo.mjs} +1 -1
  5. package/dist/{SdkPreviewModeRuntime-CnWmj-2B.mjs → SdkPreviewModeRuntime-BbbGsI_v.mjs} +596 -164
  6. package/dist/{SiteChromeCustomizeContext-B6d5zkog.mjs → SiteChromeCustomizeContext-BbkNSt5a.mjs} +2888 -1404
  7. package/dist/_dts/ai/src/contracts/proposals.d.ts +12 -298
  8. package/dist/_dts/ai/src/contracts/siteStyleProposalSchemas.d.ts +21 -14
  9. package/dist/_dts/ai/src/designer/themePatch.d.ts +5 -10
  10. package/dist/_dts/api/src/accessAdmin.d.ts +1 -9
  11. package/dist/_dts/api/src/accountApi.d.ts +49 -2
  12. package/dist/_dts/api/src/contentRuntime.d.ts +1 -4
  13. package/dist/_dts/api/src/domainConnection.d.ts +41 -0
  14. package/dist/_dts/api/src/endpoints.d.ts +194 -181
  15. package/dist/_dts/api/src/index.d.ts +4 -3
  16. package/dist/_dts/api/src/media.d.ts +19 -2
  17. package/dist/_dts/api/src/sdkContracts.d.ts +2 -15
  18. package/dist/_dts/api/src/sdkMediaContracts.d.ts +40 -0
  19. package/dist/_dts/api/src/sdkMediaEndpointDefinitions.d.ts +61 -0
  20. package/dist/_dts/api/src/sdkThemeWire.d.ts +15 -4
  21. package/dist/_dts/api/src/siteInfrastructure.d.ts +17 -23
  22. package/dist/_dts/api/src/siteManagementEndpoints.d.ts +7 -21
  23. package/dist/_dts/api/src/sitePlatformEndpoints.d.ts +27 -3
  24. package/dist/_dts/api/src/siteRuntimeEndpoints.d.ts +37 -17
  25. package/dist/_dts/api/src/types.d.ts +1 -1
  26. package/dist/_dts/blocks/src/PageRenderer.d.ts +2 -2
  27. package/dist/_dts/blocks/src/index.d.ts +1 -1
  28. package/dist/_dts/blocks/src/pageRenderAdmission.d.ts +9 -0
  29. package/dist/_dts/blocks/src/pageRendererBlockSupport.d.ts +75 -0
  30. package/dist/_dts/blocks/src/pageRendererBoundaries.d.ts +2 -0
  31. package/dist/_dts/blocks/src/server.d.ts +1 -1
  32. package/dist/_dts/blocks/src/system/blocks/event-registration.d.ts +1 -1
  33. package/dist/_dts/blocks/src/system/runtime/api/client.d.ts +2 -1
  34. package/dist/_dts/blocks/src/system/runtime/hooks/useCalendarEvents.d.ts +3 -3
  35. package/dist/_dts/blocks/src/system/runtime/hooks/useCalendarEvents.state.d.ts +34 -22
  36. package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/ErrorStep.d.ts +3 -5
  37. package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/event-registration.headless.contract.d.ts +2 -0
  38. package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/event-registration.headless.planning.d.ts +1 -1
  39. package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/hooks.d.ts +2 -0
  40. package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/registrationErrorPresentation.d.ts +5 -0
  41. package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/registrationErrorRecovery.d.ts +25 -0
  42. package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/registrationWizardContext.d.ts +4 -0
  43. package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/useEventRegistrationStripeReturn.d.ts +7 -3
  44. package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/useEventRegistrationSubmit.d.ts +2 -0
  45. package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/useEventRegistrationWizard.d.ts +5 -2
  46. package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/useWaitlistClaimRestoration.d.ts +2 -0
  47. package/dist/_dts/blocks/src/system/runtime/nodes/events/domain/capacity.d.ts +164 -0
  48. package/dist/_dts/blocks/src/system/runtime/nodes/events/domain/cta.d.ts +29 -0
  49. package/dist/_dts/blocks/src/system/runtime/nodes/events/domain/dates.d.ts +47 -0
  50. package/dist/_dts/blocks/src/system/runtime/nodes/events/domain/index.d.ts +14 -0
  51. package/dist/_dts/blocks/src/system/runtime/nodes/events/domain/people.d.ts +6 -0
  52. package/dist/_dts/blocks/src/system/runtime/nodes/events/domain/pricing.d.ts +31 -0
  53. package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/OfferingTitle.d.ts +11 -0
  54. package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/WeekAgendaView.d.ts +1 -1
  55. package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/WeekBoardView.d.ts +1 -1
  56. package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/index.d.ts +3 -1
  57. package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/listingLayout.d.ts +23 -0
  58. package/dist/_dts/commerce/src/purchase/event-registration-errors.d.ts +57 -0
  59. package/dist/_dts/commerce/src/purchase/index.d.ts +1 -0
  60. package/dist/_dts/db/src/generated/supabase/database.types.d.ts +8 -40
  61. package/dist/_dts/db/src/index.d.ts +1 -0
  62. package/dist/_dts/db/src/utils/postgrestFilter.d.ts +2 -0
  63. package/dist/_dts/media-core/src/bulkDeletePlanning.d.ts +4 -0
  64. package/dist/_dts/media-core/src/fileDomain.d.ts +3 -0
  65. package/dist/_dts/preview-next/src/client/preview/PreviewShell.d.ts +1 -0
  66. package/dist/_dts/preview-next/src/client/preview/PreviewShellLayout.d.ts +1 -0
  67. package/dist/_dts/preview-next/src/client/preview/SiteChromeCustomizeContext.d.ts +3 -2
  68. package/dist/_dts/preview-next/src/client/preview/siteChromeBrandPreferences.d.ts +1 -1
  69. package/dist/_dts/preview-next/src/client/preview/siteChromeQuickControlHistoryState.d.ts +2 -0
  70. package/dist/_dts/preview-next/src/client/preview/siteChromeQuickControlSaveRequest.d.ts +51 -0
  71. package/dist/_dts/preview-next/src/client/preview/siteChromeSavePlan.d.ts +24 -2
  72. package/dist/_dts/preview-next/src/client/preview/siteStylePreviewPlanner.d.ts +23 -1
  73. package/dist/_dts/preview-next/src/client/preview/usePersistedHeaderPreferences.d.ts +8 -0
  74. package/dist/_dts/sdk/src/public-api/contracts.d.ts +2 -1
  75. package/dist/_dts/sdk/src/version.d.ts +1 -1
  76. package/dist/_dts/theme-core/src/generated/containerResponsiveThemeCss.d.ts +1 -1
  77. package/dist/_dts/theme-core/src/gradients/types.d.ts +5 -0
  78. package/dist/_dts/theme-core/src/header/interactionPalette.d.ts +25 -2
  79. package/dist/_dts/theme-core/src/mock-themes/all.d.ts +3 -3
  80. package/dist/_dts/theme-core/src/schema.d.ts +12 -11
  81. package/dist/_dts/theme-core/src/site-styles/compilationPlan.d.ts +43 -3
  82. package/dist/_dts/theme-core/src/site-styles/curatedSiteStyles.d.ts +10 -0
  83. package/dist/_dts/theme-core/src/site-styles/headerBrandPresentation.d.ts +63 -0
  84. package/dist/_dts/theme-core/src/site-styles/headerBytesComparison.d.ts +30 -0
  85. package/dist/_dts/theme-core/src/site-styles/headerInteractionPalette.d.ts +50 -1
  86. package/dist/_dts/theme-core/src/site-styles/headerLayoutCatalog.d.ts +48 -9
  87. package/dist/_dts/theme-core/src/site-styles/headerPreferences.d.ts +162 -0
  88. package/dist/_dts/theme-core/src/site-styles/headerPreferencesPersistence.d.ts +73 -0
  89. package/dist/_dts/theme-core/src/site-styles/headerRecompile.d.ts +118 -0
  90. package/dist/_dts/theme-core/src/site-styles/headerStyleCompiler.d.ts +10 -1
  91. package/dist/_dts/theme-core/src/site-styles/headerStyleDefaults.d.ts +1 -1
  92. package/dist/_dts/theme-core/src/site-styles/headerStyleRecipe.d.ts +7 -0
  93. package/dist/_dts/theme-core/src/site-styles/index.d.ts +5 -0
  94. package/dist/_dts/theme-core/src/site-styles/previewCompiler.d.ts +1 -1
  95. package/dist/_dts/theme-core/src/site-styles/siteChromeBackgrounds.d.ts +20 -1
  96. package/dist/_dts/theme-core/src/site-styles/siteChromeNavPreferences.d.ts +43 -2
  97. package/dist/client/{BookingConsentAgreement-DCch21a6.mjs → BookingConsentAgreement--_fUCZe-.mjs} +2 -2
  98. package/dist/client/{DiscountCodeDisclosure-DIj1T59K.mjs → DiscountCodeDisclosure-BMipSoDJ.mjs} +1 -1
  99. package/dist/client/{EventCombined.client-BWVNlXTx.mjs → EventCombined.client-CwJOxn7A.mjs} +154 -178
  100. package/dist/client/{EventListing.client-DVFCDe3i.mjs → EventListing.client-eVwiylPW.mjs} +2 -2
  101. package/dist/client/{LeafletStaticMap-BY5mIHw9.mjs → LeafletStaticMap-IKenna5u.mjs} +1 -1
  102. package/dist/client/{accordion-CK29E8rG.mjs → accordion-MGAO3PuE.mjs} +1 -1
  103. package/dist/client/{bookingForm-DFvnet-N.mjs → bookingForm-CudlQPUu.mjs} +5 -5
  104. package/dist/client/bookings.mjs +418 -79
  105. package/dist/client/capacity-BW00PO7s.mjs +271 -0
  106. package/dist/client/{carousel-BVU5NQlb.mjs → carousel-BrbGJ2Jl.mjs} +1 -1
  107. package/dist/client/{cart-BNItcZVa.mjs → cart-Bq5eU0xZ.mjs} +3 -3
  108. package/dist/client/{checkout-Bu6iCdkP.mjs → checkout-BAFVRdrK.mjs} +3 -3
  109. package/dist/client/client.mjs +2919 -1918
  110. package/dist/client/{context-BImarOAq.mjs → context-DCkiHVdD.mjs} +8 -5
  111. package/dist/client/dates-2RPXHQy4.mjs +264 -0
  112. package/dist/client/{eventCalendar-DS2h-UXD.mjs → eventCalendar-B0O-hPF7.mjs} +10 -17
  113. package/dist/client/{eventCombined-Drt4Oq9p.mjs → eventCombined-DCkDaoDI.mjs} +3 -3
  114. package/dist/client/{eventDetails-Bl2vWgTX.mjs → eventDetails-D8GG2dnD.mjs} +5 -3
  115. package/dist/client/{eventListing-CS7PHY7v.mjs → eventListing-3ssV_bxz.mjs} +3 -3
  116. package/dist/client/{eventRegistration-D-j8eNy2.mjs → eventRegistration-bPQo3kVw.mjs} +562 -309
  117. package/dist/client/{form-RMpoLTyr.mjs → form-qMv8RDkk.mjs} +2 -2
  118. package/dist/client/{headerSection-BYE3Lb3k.mjs → headerSection-CH0Sc5hX.mjs} +2 -2
  119. package/dist/client/hooks.mjs +289 -32
  120. package/dist/client/{locationMap-BxSr7Kkh.mjs → locationMap-0_xlBnNI.mjs} +2 -2
  121. package/dist/client/{newsletterForm-DerbXwFC.mjs → newsletterForm-NUW7m9RI.mjs} +2 -2
  122. package/dist/client/{productDetail-4SZCLhAf.mjs → productDetail-FBEOM7jW.mjs} +3 -3
  123. package/dist/client/{productList-D7AP4GNq.mjs → productList-R0OSGhnn.mjs} +3 -3
  124. package/dist/client/{propsDecoder-pzBeCh14.mjs → propsDecoder-pYvx_Srl.mjs} +88 -380
  125. package/dist/client/rendering/client.mjs +2616 -1637
  126. package/dist/client/rendering/islands.mjs +17 -17
  127. package/dist/client/rendering.mjs +2710 -1702
  128. package/dist/client/{scrollToBlock-CduAKf8T.mjs → scrollToBlock-ByQv96M2.mjs} +1 -1
  129. package/dist/client/{shop-Cp5p_kGe.mjs → shop-RUG9DmRE.mjs} +6 -6
  130. package/dist/client/{shop-commerce-DicXYaYX.mjs → shop-commerce-B76Jz23B.mjs} +5 -5
  131. package/dist/client/{shop-commerce-store-CGWnpY4K.mjs → shop-commerce-store-QuQNdDsD.mjs} +1 -1
  132. package/dist/client/{shopShared-BDf9ljkm.mjs → shopShared-vXU1omwJ.mjs} +3 -3
  133. package/dist/client/{useEventFilters-DeeyGYuk.mjs → useEventFilters-ByuU6HLA.mjs} +33 -18
  134. package/dist/preview-next/before-render.mjs +79 -51
  135. package/dist/preview-next/client/runtime.mjs +4 -4
  136. package/dist/preview-next/keepAlive.mjs +79 -51
  137. package/dist/preview-next/middleware.mjs +79 -51
  138. package/dist/{previewAuthStore-DbqBol0V.mjs → previewAuthStore-L_cKW8Sb.mjs} +79 -51
  139. package/dist/{sdk-runtime-19MO27F0.mjs → sdk-runtime-sUMr5d70.mjs} +2 -2
  140. package/dist/{separator-DaPLtJ1f.mjs → separator-BIHkie5i.mjs} +1 -1
  141. package/dist/server/components.mjs +2077 -1274
  142. package/dist/server/config-validation.mjs +289 -32
  143. package/dist/server/config.mjs +289 -32
  144. package/dist/server/data.mjs +289 -32
  145. package/dist/server/index.mjs +80 -52
  146. package/dist/server/next.mjs +1822 -1111
  147. package/dist/server/page-converter.mjs +167 -31
  148. package/dist/server/prebuild.mjs +1 -1
  149. package/dist/server/rendering/server.mjs +1988 -1286
  150. package/dist/server/rendering.mjs +1943 -1182
  151. package/dist/server/routing.mjs +351 -86
  152. package/dist/server/server.mjs +293 -128
  153. package/dist/server/theme-bridge.mjs +52 -8
  154. package/dist/server/theme.mjs +27 -8
  155. package/dist/styles/index.css +15 -0
  156. package/package.json +1 -1
  157. package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/eventCapacity.d.ts +0 -48
  158. package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/pricing.d.ts +0 -17
  159. package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/utils.d.ts +0 -100
  160. /package/dist/_dts/blocks/src/system/runtime/nodes/events/{shared → domain}/destination.d.ts +0 -0
@@ -4348,6 +4348,11 @@ const gradientConfigSchema = z.object({
4348
4348
  position: z.string().optional(),
4349
4349
  stops: z.array(gradientStopSchema).min(2)
4350
4350
  });
4351
+ const gradientsSchema = z.object({
4352
+ button: z.string().min(1).nullable().optional(),
4353
+ hero: z.string().min(1).nullable().optional(),
4354
+ background: z.string().min(1).nullable().optional()
4355
+ });
4351
4356
  //#endregion
4352
4357
  //#region ../theme-core/src/interactive/baseSchema.ts
4353
4358
  /**
@@ -5059,11 +5064,30 @@ const headerContainerSchema = z.object({
5059
5064
  tint: z.string().nullable().optional(),
5060
5065
  opacity: z.number().min(0).max(1).default(.12)
5061
5066
  }).optional();
5062
- const headerInteractionPaletteSchema = z.enum([
5067
+ //#endregion
5068
+ //#region ../theme-core/src/header/interactionPalette.ts
5069
+ /**
5070
+ * The palettes that fill the nav link with a colour on hover and focus. Each
5071
+ * one names a background/foreground token pair.
5072
+ */
5073
+ const headerInteractionPillPaletteValues = [
5063
5074
  "primary",
5064
5075
  "secondary",
5065
5076
  "accent"
5066
- ]);
5077
+ ];
5078
+ /**
5079
+ * "No pill": the nav link keeps whatever hover treatment its recipe compiled,
5080
+ * and the palette step writes nothing at all (#1318 Phase 4c decision 2).
5081
+ *
5082
+ * It exists because "a colour change on hover, no filled background" was not
5083
+ * expressible in the vocabulary, and it is what
5084
+ * `anna-raven-therapy-and-yoga` and `kirtan-lucy` have rendered since before
5085
+ * the palette existed. Without it those two rows can only be classified as a
5086
+ * conscious visual change.
5087
+ */
5088
+ const headerInteractionQuietPalette = "quiet";
5089
+ const headerInteractionPaletteValues = [...headerInteractionPillPaletteValues, headerInteractionQuietPalette];
5090
+ const headerInteractionPaletteSchema = z.enum(headerInteractionPaletteValues);
5067
5091
  //#endregion
5068
5092
  //#region ../theme-core/src/boxBackgroundSchema.ts
5069
5093
  const boxBackgroundOverlaySchema = z.preprocess(normalizeAuthoringOpacity, z.discriminatedUnion("type", [
@@ -5584,7 +5608,7 @@ const headerSchema = z.object({
5584
5608
  variant: headerVariantWithLegacyAliasSchema,
5585
5609
  positioning: headerPositioning,
5586
5610
  shrinkOnScroll: z.boolean(),
5587
- maxWidth: headerMaxWidth,
5611
+ maxWidth: headerMaxWidth.default("container"),
5588
5612
  scrollTreatment: headerScrollTreatmentSchema,
5589
5613
  background: headerBackgroundSchema.default({
5590
5614
  type: "color",
@@ -5783,11 +5807,6 @@ const bodyTextSchema = z.object({ intro: z.object({
5783
5807
  paragraphSize: bodyTextIntroTypographySizeSchema.optional(),
5784
5808
  headingSize: bodyTextIntroTypographySizeSchema.optional()
5785
5809
  }).optional() }).optional();
5786
- const gradientsSchema = z.object({
5787
- button: z.string().min(1).nullable().optional(),
5788
- hero: z.string().min(1).nullable().optional(),
5789
- background: z.string().min(1).nullable().optional()
5790
- });
5791
5810
  /**
5792
5811
  * Testimonial quote-mark treatment, owned by the site style (analogous to the
5793
5812
  * accordion icon). `style` is the coarse selector; the optional fields fine-tune
@@ -8115,6 +8134,12 @@ const overlayLogoAccommodations = [
8115
8134
  inlineMarkWithTitleLogoAccommodation,
8116
8135
  unbackedOverlayLogoAccommodation
8117
8136
  ];
8137
+ const allCuratedLogoAccommodations = [
8138
+ ...inlineClassicLogoAccommodations,
8139
+ ...centeredLogoAccommodations,
8140
+ ...overlayLogoAccommodations
8141
+ ];
8142
+ new Set(allCuratedLogoAccommodations.filter((option) => option.providesBacking === true).map((option) => option.pattern));
8118
8143
  const headerLayoutCatalog = defineExactCatalog()([
8119
8144
  {
8120
8145
  id: asHeaderLayoutId("classic"),
@@ -8275,6 +8300,10 @@ defineLookOptionGroup({
8275
8300
  {
8276
8301
  id: "secondary",
8277
8302
  label: "Secondary"
8303
+ },
8304
+ {
8305
+ id: headerInteractionQuietPalette,
8306
+ label: "Text only"
8278
8307
  }
8279
8308
  ]
8280
8309
  });
@@ -20469,6 +20498,21 @@ const containerResponsiveThemeCss = `/*
20469
20498
  outline-offset: 2px;
20470
20499
  }
20471
20500
 
20501
+ /* Event titles always link to the event page, so a card or row whose CTA is
20502
+ hidden (sold out, closed) is never a dead end (issue 1372). The link inherits
20503
+ the heading's colour and only reveals itself on hover or keyboard focus.
20504
+ Shared by EventCard, EventCompactRow and the offerings-preview course cards via \`.event-title-link\`. */
20505
+ :where(.theme-scope) .event-title-link {
20506
+ color: inherit;
20507
+ text-decoration: none;
20508
+ }
20509
+
20510
+ :where(.theme-scope) .event-title-link:hover,
20511
+ :where(.theme-scope) .event-title-link:focus-visible {
20512
+ text-decoration: underline;
20513
+ text-underline-offset: 0.12em;
20514
+ }
20515
+
20472
20516
  /* =============================================================================
20473
20517
  * Block: Carousel Navigation (Phase 3 client component migration)
20474
20518
  * =============================================================================
@@ -4192,6 +4192,11 @@ const gradientConfigSchema = z.object({
4192
4192
  position: z.string().optional(),
4193
4193
  stops: z.array(gradientStopSchema).min(2)
4194
4194
  });
4195
+ const gradientsSchema = z.object({
4196
+ button: z.string().min(1).nullable().optional(),
4197
+ hero: z.string().min(1).nullable().optional(),
4198
+ background: z.string().min(1).nullable().optional()
4199
+ });
4195
4200
  //#endregion
4196
4201
  //#region ../theme-core/src/interactive/baseSchema.ts
4197
4202
  /**
@@ -4849,11 +4854,30 @@ const headerContainerSchema = z.object({
4849
4854
  tint: z.string().nullable().optional(),
4850
4855
  opacity: z.number().min(0).max(1).default(.12)
4851
4856
  }).optional();
4852
- const headerInteractionPaletteSchema = z.enum([
4857
+ //#endregion
4858
+ //#region ../theme-core/src/header/interactionPalette.ts
4859
+ /**
4860
+ * The palettes that fill the nav link with a colour on hover and focus. Each
4861
+ * one names a background/foreground token pair.
4862
+ */
4863
+ const headerInteractionPillPaletteValues = [
4853
4864
  "primary",
4854
4865
  "secondary",
4855
4866
  "accent"
4856
- ]);
4867
+ ];
4868
+ /**
4869
+ * "No pill": the nav link keeps whatever hover treatment its recipe compiled,
4870
+ * and the palette step writes nothing at all (#1318 Phase 4c decision 2).
4871
+ *
4872
+ * It exists because "a colour change on hover, no filled background" was not
4873
+ * expressible in the vocabulary, and it is what
4874
+ * `anna-raven-therapy-and-yoga` and `kirtan-lucy` have rendered since before
4875
+ * the palette existed. Without it those two rows can only be classified as a
4876
+ * conscious visual change.
4877
+ */
4878
+ const headerInteractionQuietPalette = "quiet";
4879
+ const headerInteractionPaletteValues = [...headerInteractionPillPaletteValues, headerInteractionQuietPalette];
4880
+ const headerInteractionPaletteSchema = z.enum(headerInteractionPaletteValues);
4857
4881
  //#endregion
4858
4882
  //#region ../theme-core/src/boxBackgroundSchema.ts
4859
4883
  const boxBackgroundOverlaySchema = z.preprocess(normalizeAuthoringOpacity, z.discriminatedUnion("type", [
@@ -5374,7 +5398,7 @@ const headerSchema = z.object({
5374
5398
  variant: headerVariantWithLegacyAliasSchema,
5375
5399
  positioning: headerPositioning,
5376
5400
  shrinkOnScroll: z.boolean(),
5377
- maxWidth: headerMaxWidth,
5401
+ maxWidth: headerMaxWidth.default("container"),
5378
5402
  scrollTreatment: headerScrollTreatmentSchema,
5379
5403
  background: headerBackgroundSchema.default({
5380
5404
  type: "color",
@@ -5573,11 +5597,6 @@ const bodyTextSchema = z.object({ intro: z.object({
5573
5597
  paragraphSize: bodyTextIntroTypographySizeSchema.optional(),
5574
5598
  headingSize: bodyTextIntroTypographySizeSchema.optional()
5575
5599
  }).optional() }).optional();
5576
- const gradientsSchema = z.object({
5577
- button: z.string().min(1).nullable().optional(),
5578
- hero: z.string().min(1).nullable().optional(),
5579
- background: z.string().min(1).nullable().optional()
5580
- });
5581
5600
  /**
5582
5601
  * Testimonial quote-mark treatment, owned by the site style (analogous to the
5583
5602
  * accordion icon). `style` is the coarse selector; the optional fields fine-tune
@@ -8864,6 +8864,21 @@
8864
8864
  outline-offset: 2px;
8865
8865
  }
8866
8866
 
8867
+ /* Event titles always link to the event page, so a card or row whose CTA is
8868
+ hidden (sold out, closed) is never a dead end (issue 1372). The link inherits
8869
+ the heading's colour and only reveals itself on hover or keyboard focus.
8870
+ Shared by EventCard, EventCompactRow and the offerings-preview course cards via `.event-title-link`. */
8871
+ :where(.theme-scope) .event-title-link {
8872
+ color: inherit;
8873
+ text-decoration: none;
8874
+ }
8875
+
8876
+ :where(.theme-scope) .event-title-link:hover,
8877
+ :where(.theme-scope) .event-title-link:focus-visible {
8878
+ text-decoration: underline;
8879
+ text-underline-offset: 0.12em;
8880
+ }
8881
+
8867
8882
 
8868
8883
 
8869
8884
  /* =============================================================================
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@riverbankcms/sdk",
3
- "version": "0.136.0",
3
+ "version": "0.137.0",
4
4
  "description": "Riverbank CMS SDK for headless content consumption",
5
5
  "main": "./dist/server/index.mjs",
6
6
  "module": "./dist/server/index.mjs",
@@ -1,48 +0,0 @@
1
- import type { PublicEvent } from '../../../../blocks/events/shared/types';
2
- export type EventAvailability = {
3
- /** Remaining spots. `null` when the event has no capacity cap. */
4
- available: number | null;
5
- /** True when the event has a cap and no spots remain. */
6
- isFull: boolean;
7
- };
8
- /**
9
- * Compute remaining spots for an event from `availableSpots` with a fallback
10
- * to `capacity - registeredCount`. Returns `{ available: null, isFull: false }`
11
- * for uncapped events so call sites can render no capacity indicator at all.
12
- *
13
- * The single source of truth for capacity math across event cards, agenda
14
- * rows, and timetable cells — keep wording variations in the call sites.
15
- */
16
- export declare function getEventAvailability(event: PublicEvent): EventAvailability;
17
- /**
18
- * Three-state availability status for the compact class board.
19
- * - `available`: comfortable capacity (or uncapped) — maps to the green/secondary token.
20
- * - `filling`: at or below the "filling" threshold — maps to the accent/amber token.
21
- * - `waitlist`: full — maps to the muted token. Label reflects whether a waitlist is open.
22
- */
23
- export type EventAvailabilityStatus = 'available' | 'filling' | 'waitlist';
24
- export type EventAvailabilityDetail = {
25
- status: EventAvailabilityStatus;
26
- /** Remaining spots. `null` when the event has no capacity cap. */
27
- available: number | null;
28
- isFull: boolean;
29
- /**
30
- * Short capacity pill label, e.g. "4 places", "2 left", "Waitlist", "Full".
31
- * `null` for uncapped events so the pill can be omitted entirely.
32
- */
33
- label: string | null;
34
- };
35
- /** Default remaining-spot count at/below which an event reads as "filling up". */
36
- export declare const DEFAULT_FILLING_THRESHOLD = 2;
37
- type AvailabilityStatusOptions = {
38
- /** Remaining spots at or below which the event is "filling up". Defaults to 2. */
39
- fillingThreshold?: number;
40
- };
41
- /**
42
- * Derive the three-state availability status (available / filling / waitlist)
43
- * plus a short pill label. Builds on {@link getEventAvailability} so the
44
- * capacity math (availableSpots with a `capacity - registeredCount` fallback)
45
- * stays consistent with the binary helper used elsewhere.
46
- */
47
- export declare function getEventAvailabilityStatus(event: PublicEvent, options?: AvailabilityStatusOptions): EventAvailabilityDetail;
48
- export {};
@@ -1,17 +0,0 @@
1
- import type { PublicEventPricing } from '../../../../../../../core/src/index';
2
- import type { PublicEventTicketType } from '../../../../blocks/events/shared/types';
3
- type RuntimeEventPricingSource = {
4
- destination?: unknown;
5
- eventDestinationMode?: unknown;
6
- path?: unknown;
7
- pricing?: unknown;
8
- requiresRegistration?: boolean | null;
9
- pricingType?: unknown;
10
- price?: unknown;
11
- currency?: unknown;
12
- priceDisplay?: unknown;
13
- pricingMode?: unknown;
14
- ticketTypes?: unknown;
15
- };
16
- export declare function resolveRuntimeEventPricing(event: RuntimeEventPricingSource): PublicEventPricing<PublicEventTicketType>;
17
- export {};
@@ -1,100 +0,0 @@
1
- /**
2
- * Shared utility functions for event blocks
3
- */
4
- import { type PublicEventPricing } from '../../../../../../../core/src/index';
5
- import type { CardOrientation, EventLayout, PublicEvent } from '../../../../blocks/events/shared/types';
6
- /** Day names starting from Sunday — kept for back-compat re-export. */
7
- export { DAY_NAMES, MONTH_NAMES } from '../../../../../../../calendar/src/index';
8
- export type { WeekStart } from '../../../../../../../calendar/src/index';
9
- /**
10
- * Column class mappings for grid layouts, derived from the canonical
11
- * responsive column ladder (see gridUserColumnLadder).
12
- */
13
- export declare const COLUMN_CLASSES: Record<string, string>;
14
- /**
15
- * Build container class based on layout mode
16
- * @param layout - 'grid', 'stack', or 'compact'
17
- * @param columns - Number of columns for grid layout ('2', '3', '4')
18
- * @returns `rb-*` class string for the container
19
- */
20
- export declare function getContainerClass(layout: EventLayout, columns: string): string;
21
- /**
22
- * Get card orientation based on layout mode
23
- * @param layout - 'grid', 'stack', or 'compact'
24
- * @returns 'horizontal' for stack layout, 'vertical' for grid and compact layouts
25
- */
26
- export declare function getCardOrientation(layout: EventLayout): CardOrientation;
27
- type DateTimeFormatOptions = {
28
- /** When omitted, runtime local timezone is used. */
29
- timeZone?: string | null;
30
- locale?: string;
31
- };
32
- /**
33
- * Format date for display.
34
- * Returns: "Monday, January 15, 2025"
35
- */
36
- export declare function formatDate(isoTimestamp: string, options?: DateTimeFormatOptions): string;
37
- /**
38
- * Format time for display.
39
- * Returns: "10:00 AM"
40
- */
41
- export declare function formatTime(isoTimestamp: string, options?: DateTimeFormatOptions): string;
42
- export declare function formatEventDateParts(args: {
43
- startsAt: string;
44
- endsAt: string;
45
- timeZone?: string | null;
46
- locale?: string;
47
- }): {
48
- date: string;
49
- timeRange: string;
50
- };
51
- export type EventCompactDateRail = Readonly<{
52
- weekday: string;
53
- day: string;
54
- month: string;
55
- label: string;
56
- }>;
57
- export declare function formatEventCompactDateRail(isoTimestamp: string, options?: DateTimeFormatOptions): EventCompactDateRail;
58
- export declare function formatTeamMemberNames(names: readonly string[]): string | null;
59
- export declare function formatEventTeacherLine(event: PublicEvent): string | null;
60
- export { addDays, addMonths, buildCalendarViewport, formatCalendarTitle, formatDateKey, getEndOfMonth, getMonthCalendarDays, getOrderedDayNames, getStartOfMonth, getWeekCalendarDays, getWeekCalendarDayTuple, isToday, MAX_EVENTS_PER_DAY, shiftCalendarAnchorDate, } from '../../../../../../../calendar/src/index';
61
- export type { CalendarDate, CalendarViewport, CalendarViewportKind, MonthCalendarViewport, WeekCalendarDays, WeekCalendarViewport, } from '../../../../../../../calendar/src/index';
62
- /**
63
- * Group events by their local date (YYYY-MM-DD key in each event's own
64
- * timezone). Thin domain wrapper over `groupItemsByDate` from the calendar
65
- * package; preserves the historical `Map<string, PublicEvent[]>` shape.
66
- */
67
- export declare function groupEventsByDate(events: PublicEvent[], calendarTimeZone: string): Map<string, PublicEvent[]>;
68
- /**
69
- * Format event price for display.
70
- * @returns "Free", "£25", "£12 - £25", "Free / £12 - £25", "Course (From £40)", etc.
71
- *
72
- * Events render compact amounts (no trailing ".00"); the actual ADT→string
73
- * mapping lives in `formatBookingPriceDisplay` in @riverbankcms/core so all
74
- * surfaces stay consistent.
75
- */
76
- export declare function formatEventPrice(event: PublicEvent): string;
77
- /**
78
- * Format an event's price directly from its pricing value (without the full
79
- * event). Same output as {@link formatEventPrice}.
80
- */
81
- export declare function formatEventPriceDisplay(pricing: PublicEventPricing<unknown>): string;
82
- export type ResolvedEventCta = {
83
- label: string;
84
- href: string;
85
- external: boolean;
86
- /** True when the CTA should be hidden (e.g. sold-out events) */
87
- hidden: boolean;
88
- };
89
- export declare function resolveEventHref(event: PublicEvent): string;
90
- export declare function resolveEventLinkProps(event: PublicEvent): {
91
- href: string;
92
- target?: '_blank';
93
- rel?: string;
94
- };
95
- /**
96
- * Resolve the CTA state for an event.
97
- * Shared by EventCard and EventCompactRow to keep sold-out, registration-closed,
98
- * and course-specific defaults consistent.
99
- */
100
- export declare function resolveEventCta(event: PublicEvent, buttonText?: string | null): ResolvedEventCta;