@riverbankcms/sdk 0.101.0 → 0.102.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 (54) hide show
  1. package/dist/{PreviewEditorSidebar-DBpy0KTh.mjs → PreviewEditorSidebar-BKkhhkJk.mjs} +358 -68
  2. package/dist/{PreviewEditorUI-Fg6I2R2T.mjs → PreviewEditorUI-DIvTqcqI.mjs} +3 -3
  3. package/dist/{PreviewQueryProvider-BICQLAUF.mjs → PreviewQueryProvider-ZF6TXq5Q.mjs} +1 -1
  4. package/dist/{SdkPreviewModeRuntime-DFQP-Q53.mjs → SdkPreviewModeRuntime-CA2k7Z_T.mjs} +200 -122
  5. package/dist/{SiteChromeCustomizeContext-GwZc89KN.mjs → SiteChromeCustomizeContext-Bh9-DtMQ.mjs} +203 -34
  6. package/dist/_dts/ai/src/designer/rfc6902.d.ts +57 -1
  7. package/dist/_dts/ai/src/designer/themePatch.d.ts +16 -6
  8. package/dist/_dts/api/src/bookingVerticals.d.ts +53 -1
  9. package/dist/_dts/api/src/siteRuntimeEndpoints.d.ts +1 -0
  10. package/dist/_dts/blocks/src/bindings/index.d.ts +1 -1
  11. package/dist/_dts/blocks/src/system/runtime/nodes/layout.d.ts +1 -0
  12. package/dist/_dts/content-editor/src/index.d.ts +1 -0
  13. package/dist/_dts/core/src/branded.d.ts +4 -0
  14. package/dist/_dts/core/src/person-records.d.ts +6 -1
  15. package/dist/_dts/media-core/src/identifiers.d.ts +14 -1
  16. package/dist/_dts/preview-next/src/client/blocks/composer/mergeDrafts.d.ts +1 -1
  17. package/dist/_dts/preview-next/src/client/blocks/previewProjection/applyPreviewProjections.d.ts +3 -1
  18. package/dist/_dts/preview-next/src/client/blocks/previewProjection/runtimeContentDecoration.d.ts +2 -2
  19. package/dist/_dts/preview-next/src/client/preview/PreviewChromeLayer.d.ts +2 -1
  20. package/dist/_dts/preview-next/src/client/preview/StyleConfigurator.state.d.ts +43 -7
  21. package/dist/_dts/preview-next/src/client/preview/siteStylePreviewPlanner.d.ts +4 -4
  22. package/dist/_dts/preview-next/src/client/preview/styleConfiguratorApplyPayload.d.ts +1 -1
  23. package/dist/_dts/preview-next/src/client/preview/typographySelectionInput.d.ts +4 -2
  24. package/dist/_dts/sdk/src/version.d.ts +1 -1
  25. package/dist/_dts/theme-core/src/site-styles/designState.d.ts +4 -2
  26. package/dist/_dts/theme-core/src/site-styles/headerLooks.d.ts +4 -4
  27. package/dist/_dts/theme-core/src/site-styles/previewCompiler.d.ts +6 -1
  28. package/dist/_dts/theme-core/src/site-styles/rawStyleFields.d.ts +3 -3
  29. package/dist/_dts/theme-core/src/site-styles/runtimeCompiler.d.ts +24 -1
  30. package/dist/cli/index.mjs +31 -15
  31. package/dist/client/client.mjs +44 -16
  32. package/dist/client/hooks.mjs +14 -5
  33. package/dist/client/rendering/client.mjs +21 -13
  34. package/dist/client/rendering.mjs +43 -15
  35. package/dist/preview-next/before-render.mjs +1 -1
  36. package/dist/preview-next/client/runtime.mjs +4 -4
  37. package/dist/{previewAuthStore-Da74OL0X.mjs → previewAuthStore-ByPPZqmp.mjs} +1 -0
  38. package/dist/{sdk-runtime-CP6Kwalv.mjs → sdk-runtime-K8Oqj97H.mjs} +2 -2
  39. package/dist/{separator-BVk7GvGN.mjs → separator-CRoP34pT.mjs} +1 -1
  40. package/dist/server/components.mjs +37 -13
  41. package/dist/server/config-validation.mjs +14 -5
  42. package/dist/server/config.mjs +14 -5
  43. package/dist/server/data.mjs +14 -5
  44. package/dist/server/index.mjs +2 -2
  45. package/dist/server/next.mjs +38 -14
  46. package/dist/server/page-converter.mjs +7 -4
  47. package/dist/server/prebuild.mjs +1 -1
  48. package/dist/server/rendering/server.mjs +37 -13
  49. package/dist/server/rendering.mjs +37 -13
  50. package/dist/server/routing.mjs +16 -6
  51. package/dist/server/server.mjs +15 -6
  52. package/dist/server/theme-bridge.mjs +5 -4
  53. package/dist/server/theme.mjs +1 -0
  54. package/package.json +1 -1
@@ -5,7 +5,7 @@ export declare const BOOKING_ENGINES: readonly ["event_series", "course", "appoi
5
5
  export type BookingEngine = (typeof BOOKING_ENGINES)[number];
6
6
  export declare const VERTICAL_PRESET_AVAILABILITIES: readonly ["onboarding", "settings", "future"];
7
7
  export type VerticalPresetAvailability = (typeof VERTICAL_PRESET_AVAILABILITIES)[number];
8
- export declare const VERTICAL_IDS: readonly ["yoga_wellness", "fitness_pt", "dance_school", "therapist_practitioner", "beauty_spa", "consultant_coach", "training_provider", "retreat_centre", "music_school", "performing_arts_school", "community_wellbeing", "venue_event_space"];
8
+ export declare const VERTICAL_IDS: readonly ["yoga_wellness", "fitness_pt", "dance_school", "therapist_practitioner", "beauty_spa", "consultant_coach", "training_provider", "retreat_centre", "music_school", "voice_singing", "performing_arts_school", "community_wellbeing", "venue_event_space"];
9
9
  export type VerticalId = (typeof VERTICAL_IDS)[number];
10
10
  export type EventSeriesCanonicalBehaviour = Extract<CanonicalBookingBehaviour, 'class' | 'workshop' | 'retreat' | 'performance'>;
11
11
  export declare const EVENT_SERIES_BEHAVIOURS: readonly ["class", "workshop", "retreat", "performance"];
@@ -157,6 +157,10 @@ export declare const VERTICAL_DEFINITIONS: readonly [{
157
157
  readonly id: "music_school";
158
158
  readonly label: "Music teacher or school";
159
159
  readonly description: "Lessons, classes, terms, workshops, and performances.";
160
+ }, {
161
+ readonly id: "voice_singing";
162
+ readonly label: "Voice & Singing";
163
+ readonly description: "Singing lessons, choirs, voice circles, workshops, and performances.";
160
164
  }, {
161
165
  readonly id: "performing_arts_school";
162
166
  readonly label: "Theatre or performing arts school";
@@ -523,6 +527,51 @@ export declare const VERTICAL_BOOKING_PRESETS: readonly [Readonly<{
523
527
  label: string;
524
528
  pluralLabel: string;
525
529
  description: string;
530
+ }>, Readonly<{
531
+ id: "voice_singing.lessons";
532
+ verticalId: VerticalId;
533
+ canonicalBehaviour: CanonicalBookingBehaviour;
534
+ engine: BookingEngine;
535
+ availability: VerticalPresetAvailability;
536
+ label: string;
537
+ pluralLabel: string;
538
+ description: string;
539
+ }>, Readonly<{
540
+ id: "voice_singing.classes";
541
+ verticalId: VerticalId;
542
+ canonicalBehaviour: CanonicalBookingBehaviour;
543
+ engine: BookingEngine;
544
+ availability: VerticalPresetAvailability;
545
+ label: string;
546
+ pluralLabel: string;
547
+ description: string;
548
+ }>, Readonly<{
549
+ id: "voice_singing.terms";
550
+ verticalId: VerticalId;
551
+ canonicalBehaviour: CanonicalBookingBehaviour;
552
+ engine: BookingEngine;
553
+ availability: VerticalPresetAvailability;
554
+ label: string;
555
+ pluralLabel: string;
556
+ description: string;
557
+ }>, Readonly<{
558
+ id: "voice_singing.workshops";
559
+ verticalId: VerticalId;
560
+ canonicalBehaviour: CanonicalBookingBehaviour;
561
+ engine: BookingEngine;
562
+ availability: VerticalPresetAvailability;
563
+ label: string;
564
+ pluralLabel: string;
565
+ description: string;
566
+ }>, Readonly<{
567
+ id: "voice_singing.performances";
568
+ verticalId: VerticalId;
569
+ canonicalBehaviour: CanonicalBookingBehaviour;
570
+ engine: BookingEngine;
571
+ availability: VerticalPresetAvailability;
572
+ label: string;
573
+ pluralLabel: string;
574
+ description: string;
526
575
  }>, Readonly<{
527
576
  id: "performing_arts_school.classes";
528
577
  verticalId: VerticalId;
@@ -633,6 +682,9 @@ export declare const LEGACY_VERTICAL_QUERY_MAP: {
633
682
  readonly therapist: "therapist_practitioner";
634
683
  readonly therapists: "therapist_practitioner";
635
684
  readonly 'beauty-spa': "beauty_spa";
685
+ readonly 'voice-singing': "voice_singing";
686
+ readonly singing: "voice_singing";
687
+ readonly choir: "voice_singing";
636
688
  readonly other: "community_wellbeing";
637
689
  };
638
690
  export declare function parseVerticalId(value: unknown): VerticalId | null;
@@ -39,6 +39,7 @@ export type ApplySiteStyleSelectionBody = Readonly<{
39
39
  typographyPresetId?: TypographyPresetId | null;
40
40
  typographyBodyFontOverride?: string | null;
41
41
  typographyHeadingFontOverride?: string | null;
42
+ customTypography?: Theme['typography'] | null;
42
43
  headerLookId: HeaderLookId | null;
43
44
  headerLayoutId?: HeaderLayoutId | null;
44
45
  headerStyleId?: HeaderStyleId | null;
@@ -7,7 +7,7 @@
7
7
  export type { BindingSource, BindingDescriptor, BindingInput, BindingMap, BindingContext, BindingPath, BindingTransformName, KnownBindingTransformName, FieldBindingDescriptor, MetaBindingDescriptor, LiteralBindingDescriptor, TransformBindingDescriptor, FallbackBindingDescriptor, } from './types';
8
8
  export { TRANSFORMS, BINDING_SOURCES } from './types';
9
9
  export { asDesignBlockId, asContentTemplateDesignBlockId, asLayoutVariantKey, buildPageDesignEditorReadModel, compileContentTemplateRuntimeFields, parsePageDesignIntent, surfaceResolutionContextFromTheme, designRuntimeRulesForTheme, type DesignBlockId, parseContentTemplateDesignIntent, type CompiledBlockRuntimeFields, type LayoutVariantKey, type PageDesignEditorBlockInput, type PageDesignIntent, type SurfaceResolutionContext, applyBlockContentVariantPolicy, deriveSiteStyleBlockPolicy, } from '../../../theme-core/src/site-styles/index';
10
- export { applyCompiledRuntimeFieldsToContent, buildEditorModelRuntimeFieldsByBlockId, } from '../../../theme-core/src/site-styles/previewCompiler';
10
+ export { applyCompiledRuntimeFieldsToContent, buildEditorModelRuntimeFieldsByBlockId, retargetCompiledRuntimeFieldsForContentAdjacency, } from '../../../theme-core/src/site-styles/previewCompiler';
11
11
  export { blockDesignMetadataMapFromDefinitions } from '../system/designCapabilities';
12
12
  export { systemBlockDefinitions } from '../system/blocks';
13
13
  import type { BindingContext, BindingDescriptor, BindingInput, BindingMap, BindingPath, FieldBindingDescriptor, FallbackBindingDescriptor, KnownBindingTransformName, LiteralBindingDescriptor, MetaBindingDescriptor, TransformBindingDescriptor } from './types';
@@ -9,6 +9,7 @@ type NodeMetadataProps = {
9
9
  blockKind?: string;
10
10
  blockContent?: unknown;
11
11
  fragmentRegistry?: unknown;
12
+ previewAuthoring?: unknown;
12
13
  };
13
14
  type SectionNodeProps = React.ComponentProps<typeof Section> & NodeMetadataProps;
14
15
  type StackNodeProps = React.ComponentProps<typeof StackPrimitive> & NodeMetadataProps;
@@ -22,6 +22,7 @@ export type { ActivePreviewField, EditorUiStoreInstance, EditorUiState, EditorPr
22
22
  export { PreviewTextEditor } from './primitives/PreviewTextEditor';
23
23
  export { PreviewInlineTextEditor } from './primitives/PreviewInlineTextEditor';
24
24
  export { PreviewRichTextEditor } from './primitives/PreviewRichTextEditor';
25
+ export { recordsEqual as editorValuesEqual } from './ui/stores/utils';
25
26
  export { useStoreBinding, parseEditorPath } from './primitives/shared';
26
27
  export type { PathInfo } from './primitives/shared';
27
28
  export * from './ai/overlayHelpers';
@@ -255,11 +255,15 @@ export declare const parseNavigationItemId: (value: unknown) => Result<Navigatio
255
255
  export declare const parsePassId: (value: unknown) => Result<PassId, BrandedIdParseError>;
256
256
  export declare const parseMembershipId: (value: unknown) => Result<MembershipId, BrandedIdParseError>;
257
257
  export declare const parseCourseId: (value: unknown) => Result<CourseId, BrandedIdParseError>;
258
+ export declare const parseFormId: (value: unknown) => Result<FormId, BrandedIdParseError>;
258
259
  export declare const parseAppointmentId: (value: unknown) => Result<AppointmentId, BrandedIdParseError>;
260
+ export declare const parseAppointmentServiceId: (value: unknown) => Result<AppointmentServiceId, BrandedIdParseError>;
261
+ export declare const parseAppointmentResourceId: (value: unknown) => Result<AppointmentResourceId, BrandedIdParseError>;
259
262
  export declare const parseAppointmentReservationId: (value: unknown) => Result<AppointmentReservationId, BrandedIdParseError>;
260
263
  export declare const parseAppointmentReservationRunId: (value: unknown) => Result<AppointmentReservationRunId, BrandedIdParseError>;
261
264
  export declare const parseAttendeeId: (value: unknown) => Result<AttendeeId, BrandedIdParseError>;
262
265
  export declare const parseCustomerId: (value: unknown) => Result<CustomerId, BrandedIdParseError>;
266
+ export declare const parseCustomerPassId: (value: unknown) => Result<CustomerPassId, BrandedIdParseError>;
263
267
  export declare const parseCustomerMembershipId: (value: unknown) => Result<CustomerMembershipId, BrandedIdParseError>;
264
268
  export declare const parseEventSeriesId: (value: unknown) => Result<EventSeriesId, BrandedIdParseError>;
265
269
  export {};
@@ -1,5 +1,10 @@
1
+ import { type Result } from './result';
1
2
  export declare const RECORD_ENTRY_KINDS: readonly ["person_note", "prep_note", "session_note", "follow_up_note", "booking_questions_snapshot", "correction_note"];
2
3
  export type RecordEntryKind = (typeof RECORD_ENTRY_KINDS)[number];
3
4
  export declare const PERSON_RECORD_NOTE_KINDS: readonly ["person_note", "prep_note", "session_note", "follow_up_note", "correction_note"];
4
5
  export type PersonRecordNoteKind = (typeof PERSON_RECORD_NOTE_KINDS)[number];
5
- export declare function parseRecordEntryKind(value: string): RecordEntryKind | null;
6
+ export type RecordEntryKindParseError = Readonly<{
7
+ kind: 'unsupported_record_entry_kind';
8
+ value: string;
9
+ }>;
10
+ export declare function parseRecordEntryKind(value: string): Result<RecordEntryKind, RecordEntryKindParseError>;
@@ -1,5 +1,18 @@
1
+ import { type Brand, type Result } from '../../core/src/index';
2
+ export type MediaIdentifier = Brand<string, 'MediaIdentifier'>;
3
+ export type MediaIdentifierParseError = Readonly<{
4
+ kind: 'not_string';
5
+ }> | Readonly<{
6
+ kind: 'empty_identifier';
7
+ }> | Readonly<{
8
+ kind: 'empty_after_normalization';
9
+ value: string;
10
+ }>;
1
11
  export declare function stripFileExtension(filename: string): string;
2
12
  export declare function slugifyMediaIdentifier(value: string): string;
3
13
  export declare function buildMediaIdentifierFromFilename(filename: string): string;
4
- export declare function resolveMediaIdentifier(base: string, existing: Set<string>): string;
14
+ export declare function parseMediaIdentifier(value: unknown): Result<MediaIdentifier, MediaIdentifierParseError>;
15
+ export declare function parseOptionalMediaIdentifier(value: unknown): Result<MediaIdentifier | undefined, MediaIdentifierParseError>;
16
+ export declare function unsafeAsMediaIdentifier(value: string): MediaIdentifier;
17
+ export declare function resolveMediaIdentifier(base: string, existing: Set<string>): MediaIdentifier;
5
18
  export declare const MEDIA_IDENTIFIER_FALLBACK = "media";
@@ -4,4 +4,4 @@ import type { DraftSnapshot, EditorDraftInspectorStore, EnrichedBlock } from './
4
4
  import { type PreviewProjection } from '../previewProjection';
5
5
  import { type LinkedEntryRenderOverlay } from '../linkedEntryRenderOverlay';
6
6
  export declare function getDraftSnapshots(uiStore: EditorDraftInspectorStore): Map<EditorBlockId, DraftSnapshot>;
7
- export declare function mergeBlockWithDraft(block: BlockItem, draftMap: Map<EditorBlockId, DraftSnapshot>, index: number, projections?: readonly PreviewProjection[], linkedEntryOverlays?: LinkedEntryRenderOverlay): EnrichedBlock;
7
+ export declare function mergeBlockWithDraft(block: BlockItem, draftMap: Map<EditorBlockId, DraftSnapshot>, index: number, projections?: readonly PreviewProjection[], linkedEntryOverlays?: LinkedEntryRenderOverlay, nextBlock?: BlockItem | null): EnrichedBlock;
@@ -3,5 +3,7 @@ import type { BlockItem } from '../../../../../editor-blocks/src/index';
3
3
  import type { CanonicalBlockContent, PreviewProjection, PreviewRenderContent } from './types';
4
4
  export declare function applyPreviewStructureProjections(blockItems: readonly BlockItem[], projections: readonly PreviewProjection[]): BlockItem[];
5
5
  export declare function applyPreviewContentFieldProjections(blockId: EditorBlockId, content: CanonicalBlockContent | null, projections: readonly PreviewProjection[]): CanonicalBlockContent | PreviewRenderContent | null;
6
- export declare function applyPreviewRuntimeContentProjections(block: BlockItem, content: CanonicalBlockContent | PreviewRenderContent | null, projections: readonly PreviewProjection[]): CanonicalBlockContent | PreviewRenderContent | null;
6
+ export declare function applyPreviewRuntimeContentProjections(block: BlockItem, content: CanonicalBlockContent | PreviewRenderContent | null, projections: readonly PreviewProjection[], adjacency?: Readonly<{
7
+ nextContent: Record<string, unknown> | null | undefined;
8
+ }>): CanonicalBlockContent | PreviewRenderContent | null;
7
9
  export declare function blockHasPreviewContentFieldProjection(blockId: EditorBlockId, projections: readonly PreviewProjection[]): boolean;
@@ -1,5 +1,5 @@
1
1
  import type { BlockItem } from '../../../../../editor-blocks/src/index';
2
- import { type DesignRuntimeRules, type PageDesignEditorReadModel, type SurfaceResolutionContext } from '../../../../../theme-core/src/site-styles/previewCompiler';
2
+ import { type DesignRuntimeRules, type PageDesignEditorReadModel, type RuntimeContentAdjacency, type SurfaceResolutionContext } from '../../../../../theme-core/src/site-styles/previewCompiler';
3
3
  import type { CanonicalBlockContent, PreviewRenderContent, RuntimeContentDecorationProjection } from './types';
4
4
  export declare function runtimeContentDecorationProjectionFromEditorModel(editorModel: PageDesignEditorReadModel, surfaceResolutionContext: SurfaceResolutionContext, designRules?: DesignRuntimeRules): RuntimeContentDecorationProjection;
5
- export declare function applyRuntimeContentDecorationProjection(block: BlockItem, content: CanonicalBlockContent | PreviewRenderContent | null, projection: RuntimeContentDecorationProjection): PreviewRenderContent;
5
+ export declare function applyRuntimeContentDecorationProjection(block: BlockItem, content: CanonicalBlockContent | PreviewRenderContent | null, projection: RuntimeContentDecorationProjection, adjacency?: Pick<RuntimeContentAdjacency, 'nextContent'>): PreviewRenderContent;
@@ -8,8 +8,9 @@ export declare function PreviewChromeLayerProvider({ children, }: {
8
8
  children: ReactNode;
9
9
  }): React.JSX.Element;
10
10
  export declare function usePreviewChromeLayerOptional(): PreviewChromeLayerContextValue | null;
11
- export declare function PreviewChromeFloatingControl({ anchorSelector, placement, fallbackClassName, fallbackStyle, portalClassName, forceVisible, children, }: {
11
+ export declare function PreviewChromeFloatingControl({ anchorSelector, anchorTargetSelector, placement, fallbackClassName, fallbackStyle, portalClassName, forceVisible, children, }: {
12
12
  anchorSelector: string;
13
+ anchorTargetSelector?: string;
13
14
  placement: PreviewChromeFloatingPlacement | ((anchorBox: PreviewChromeAnchorBox | null) => PreviewChromeFloatingPlacement);
14
15
  fallbackClassName: string;
15
16
  fallbackStyle?: CSSProperties;
@@ -11,6 +11,7 @@
11
11
  * picking and converge on apply-success.
12
12
  */
13
13
  import type { ButtonPersonalityId } from '../../../../theme-core/src/buttons/index';
14
+ import type { Theme } from '../../../../blocks/src/index';
14
15
  import type { PaletteOverrides, PaletteVariantId } from '../../../../theme-core/src/palette/index';
15
16
  import { type FooterLookId, type HeaderLayoutId, type HeaderLookId, type HeaderStyleId, type TypographyPresetId } from '../../../../theme-core/src/site-styles/index';
16
17
  import type { SelectionFallbackWarning, SiteStyleId } from '../../../../theme-core/src/site-styles/previewCompiler';
@@ -37,6 +38,33 @@ export type StyleConfiguratorNotice = Readonly<{
37
38
  }> | Readonly<{
38
39
  kind: 'palette-overrides-restored';
39
40
  }>;
41
+ type ThemeTypography = Theme['typography'];
42
+ type BodyTypography = ThemeTypography['body'];
43
+ type HeadingTypography = ThemeTypography['headings']['default'];
44
+ export type TypographySelectionSnapshot = Readonly<{
45
+ kind: 'preset';
46
+ presetId: TypographyPresetId | null;
47
+ bodyFontOverride: string | null;
48
+ headingFontOverride: string | null;
49
+ }> | Readonly<{
50
+ kind: 'custom';
51
+ typography: ThemeTypography;
52
+ }>;
53
+ export type TypographySelectionFlatFields = Readonly<{
54
+ typographyPresetId: TypographyPresetId | null;
55
+ typographyBodyFontOverride: string | null;
56
+ typographyHeadingFontOverride: string | null;
57
+ }>;
58
+ export type TypographyDraftPatch = Readonly<{
59
+ kind: 'heading';
60
+ patch: Partial<HeadingTypography>;
61
+ }> | Readonly<{
62
+ kind: 'body';
63
+ patch: Partial<BodyTypography>;
64
+ }> | Readonly<{
65
+ kind: 'scale';
66
+ scale: ThemeTypography['scale'];
67
+ }>;
40
68
  export type SelectionSnapshot = Readonly<{
41
69
  siteStyleId: SiteStyleId;
42
70
  selectionVersion: number;
@@ -48,9 +76,7 @@ export type SelectionSnapshot = Readonly<{
48
76
  buttonPersonalityId: ButtonPersonalityId;
49
77
  paletteVariantId: PaletteVariantId;
50
78
  paletteOverrides: PaletteOverrides | null;
51
- typographyPresetId: TypographyPresetId | null;
52
- typographyBodyFontOverride: string | null;
53
- typographyHeadingFontOverride: string | null;
79
+ typographySelection: TypographySelectionSnapshot;
54
80
  }>;
55
81
  type PaletteOverrideDrafts = Readonly<Partial<Record<PaletteVariantId, PaletteOverrides>>>;
56
82
  type StyleConfiguratorTargetKey = 'design:site-style';
@@ -95,9 +121,9 @@ export declare function previewHeaderLayout(state: StyleConfiguratorState, heade
95
121
  export declare function previewHeaderStyle(state: StyleConfiguratorState, headerStyleId: HeaderStyleId): StyleConfiguratorState;
96
122
  export declare function previewFooterLook(state: StyleConfiguratorState, footerLookId: FooterLookId | null): StyleConfiguratorState;
97
123
  export declare function previewTypographyPreset(state: StyleConfiguratorState, typographyPresetId: TypographyPresetId): StyleConfiguratorState;
98
- export declare function setTypographyBodyFontOverride(state: StyleConfiguratorState, typographyBodyFontOverride: string | null): StyleConfiguratorState;
99
- export declare function setTypographyHeadingFontOverride(state: StyleConfiguratorState, typographyHeadingFontOverride: string | null): StyleConfiguratorState;
100
- export declare function clearTypographyFontOverrides(state: StyleConfiguratorState): StyleConfiguratorState;
124
+ export declare function setCustomTypography(state: StyleConfiguratorState, typography: ThemeTypography): StyleConfiguratorState;
125
+ export declare function applyTypographyDraftPatch(state: StyleConfiguratorState, currentTypography: ThemeTypography, patch: TypographyDraftPatch): StyleConfiguratorState;
126
+ export declare function resetTypographyToSaved(state: StyleConfiguratorState): StyleConfiguratorState;
101
127
  export declare function previewPaletteVariant(state: StyleConfiguratorState, paletteVariantId: PaletteVariantId): StyleConfiguratorState;
102
128
  export declare function setPaletteOverrides(state: StyleConfiguratorState, paletteOverrides: PaletteOverrides | null): StyleConfiguratorState;
103
129
  /**
@@ -112,7 +138,8 @@ export declare function setPaletteOverrides(state: StyleConfiguratorState, palet
112
138
  * under the previous palette ID and any draft for the new palette is restored.
113
139
  */
114
140
  export declare function applyResolvedSelections(state: StyleConfiguratorState, input: Readonly<{
115
- resolved: Pick<SelectionSnapshot, 'buttonPersonalityId' | 'paletteVariantId' | 'headerLayoutId' | 'headerStyleId' | 'headerLookId' | 'typographyPresetId' | 'typographyBodyFontOverride' | 'typographyHeadingFontOverride'>;
141
+ resolved: Pick<SelectionSnapshot, 'buttonPersonalityId' | 'paletteVariantId' | 'headerLayoutId' | 'headerStyleId' | 'headerLookId'> & TypographySelectionFlatFields;
142
+ typographySelection?: TypographySelectionSnapshot;
116
143
  warnings: ReadonlyArray<SelectionFallbackWarning>;
117
144
  }>): StyleConfiguratorState;
118
145
  export declare function cancelPreview(state: StyleConfiguratorState): StyleConfiguratorState;
@@ -129,5 +156,14 @@ export declare function dismissNotices(state: StyleConfiguratorState): StyleConf
129
156
  */
130
157
  export declare function syncStyleConfiguratorState(state: StyleConfiguratorState, base: SelectionSnapshot): StyleConfiguratorState;
131
158
  export declare function selectionSnapshotsEqual(a: SelectionSnapshot, b: SelectionSnapshot): boolean;
159
+ export declare function typographySelectionSnapshotFromFlat(input: Readonly<{
160
+ typographyPresetId?: TypographyPresetId | null;
161
+ typographyBodyFontOverride?: string | null;
162
+ typographyHeadingFontOverride?: string | null;
163
+ theme?: Theme | null;
164
+ }>): TypographySelectionSnapshot;
165
+ export declare function typographySelectionFlatFields(selection: TypographySelectionSnapshot): TypographySelectionFlatFields;
166
+ export declare function customTypographyForSelection(selection: TypographySelectionSnapshot): ThemeTypography | null;
167
+ export declare function typographySelectionsEqual(a: TypographySelectionSnapshot, b: TypographySelectionSnapshot): boolean;
132
168
  export declare function paletteOverridesEqual(a: PaletteOverrides | null, b: PaletteOverrides | null): boolean;
133
169
  export {};
@@ -2,15 +2,14 @@ import type { Theme } from '../../../../blocks/src/index';
2
2
  import type { ButtonPersonalityId } from '../../../../theme-core/src/buttons/index';
3
3
  import type { PaletteOverrides, PaletteVariantId } from '../../../../theme-core/src/palette/index';
4
4
  import type { FooterLookId, FooterSelectionContext, HeaderLayoutId, HeaderLookId, HeaderSelectionContext, HeaderStyleId, TypographyPresetId } from '../../../../theme-core/src/site-styles/index';
5
- import { type CuratedSiteStyle, type SelectionFallbackWarning, type SiteStyleId } from '../../../../theme-core/src/site-styles/previewCompiler';
5
+ import { type CuratedSiteStyle, type CompiledTypographySelection, type SelectionFallbackWarning, type SiteStyleId } from '../../../../theme-core/src/site-styles/previewCompiler';
6
+ import type { TypographySelectionSnapshot } from './StyleConfigurator.state';
6
7
  export type SiteStylePreviewSelection = Readonly<{
7
8
  siteStyleId: SiteStyleId;
8
9
  buttonPersonalityId: ButtonPersonalityId;
9
10
  paletteVariantId: PaletteVariantId;
10
11
  paletteOverrides: PaletteOverrides | null;
11
- typographyPresetId?: TypographyPresetId | null;
12
- typographyBodyFontOverride?: string | null;
13
- typographyHeadingFontOverride?: string | null;
12
+ typographySelection?: TypographySelectionSnapshot;
14
13
  headerLayoutId?: HeaderLayoutId | null;
15
14
  headerStyleId?: HeaderStyleId | null;
16
15
  headerLookId: HeaderLookId | null;
@@ -25,6 +24,7 @@ export type SiteStylePreviewPlan = Readonly<{
25
24
  resolvedSelections: Readonly<{
26
25
  buttonPersonalityId: ButtonPersonalityId;
27
26
  paletteVariantId: PaletteVariantId;
27
+ typographySelection: CompiledTypographySelection['resolvedSelection'];
28
28
  typographyPresetId: TypographyPresetId | null;
29
29
  typographyBodyFontOverride: string | null;
30
30
  typographyHeadingFontOverride: string | null;
@@ -1,5 +1,5 @@
1
1
  import type { APIEndpoints } from '../../../../api/src/index';
2
- import type { SelectionSnapshot } from './StyleConfigurator.state';
2
+ import { type SelectionSnapshot } from './StyleConfigurator.state';
3
3
  export type ApplySiteStyleSelectionBody = NonNullable<APIEndpoints['applySiteStyleSelection']['body']>;
4
4
  export declare function buildApplySiteStyleSelectionBody(input: Readonly<{
5
5
  base: SelectionSnapshot;
@@ -1,11 +1,13 @@
1
1
  import type { Theme } from '../../../../blocks/src/index';
2
2
  import type { TypographyPresetId, TypographySelection } from '../../../../theme-core/src/site-styles/previewCompiler';
3
- type TypographySelectionSnapshot = Readonly<{
3
+ import type { TypographySelectionSnapshot } from './StyleConfigurator.state';
4
+ type TypographySelectionInputSnapshot = Readonly<{
4
5
  typographyPresetId?: TypographyPresetId | null;
5
6
  typographyBodyFontOverride?: string | null;
6
7
  typographyHeadingFontOverride?: string | null;
8
+ typographySelection?: TypographySelectionSnapshot;
7
9
  }>;
8
- export declare function typographySelectionInputForSnapshot(snapshot: TypographySelectionSnapshot, theme: Theme | null | undefined): Readonly<{
10
+ export declare function typographySelectionInputForSnapshot(snapshot: TypographySelectionInputSnapshot, theme: Theme | null | undefined): Readonly<{
9
11
  typographySelection?: TypographySelection;
10
12
  typographyPresetId?: TypographyPresetId | null;
11
13
  typographyBodyFontOverride?: string | null;
@@ -8,4 +8,4 @@
8
8
  * 1. This constant
9
9
  * 2. The "version" field in package.json
10
10
  */
11
- export declare const SDK_VERSION = "0.101.0";
11
+ export declare const SDK_VERSION = "0.102.0";
@@ -291,8 +291,9 @@ export declare const blockRuntimeStyleAuthoritySchema: z.ZodObject<{
291
291
  _sectionStyles: "_sectionStyles";
292
292
  _containerStyles: "_containerStyles";
293
293
  _cardStyles: "_cardStyles";
294
+ _transitionStyles: "_transitionStyles";
294
295
  styleGroup: "styleGroup";
295
- }>>, z.ZodTransform<NonEmptyRuntimeStyleFieldNames, ("_frameStyles" | "_sectionStyles" | "_containerStyles" | "_cardStyles" | "styleGroup")[]>>;
296
+ }>>, z.ZodTransform<NonEmptyRuntimeStyleFieldNames, ("_frameStyles" | "_sectionStyles" | "_containerStyles" | "_cardStyles" | "_transitionStyles" | "styleGroup")[]>>;
296
297
  authority: z.ZodDiscriminatedUnion<[z.ZodObject<{
297
298
  kind: z.ZodLiteral<"theme-v2">;
298
299
  source: z.ZodEnum<{
@@ -486,8 +487,9 @@ export declare const persistedPageDesignStateV1Schema: z.ZodObject<{
486
487
  _sectionStyles: "_sectionStyles";
487
488
  _containerStyles: "_containerStyles";
488
489
  _cardStyles: "_cardStyles";
490
+ _transitionStyles: "_transitionStyles";
489
491
  styleGroup: "styleGroup";
490
- }>>, z.ZodTransform<NonEmptyRuntimeStyleFieldNames, ("_frameStyles" | "_sectionStyles" | "_containerStyles" | "_cardStyles" | "styleGroup")[]>>;
492
+ }>>, z.ZodTransform<NonEmptyRuntimeStyleFieldNames, ("_frameStyles" | "_sectionStyles" | "_containerStyles" | "_cardStyles" | "_transitionStyles" | "styleGroup")[]>>;
491
493
  authority: z.ZodDiscriminatedUnion<[z.ZodObject<{
492
494
  kind: z.ZodLiteral<"theme-v2">;
493
495
  source: z.ZodEnum<{
@@ -281,12 +281,12 @@ export declare const headerStyleCatalog: readonly [{
281
281
  readonly moods: readonly ["calm", "professional", "editorial"];
282
282
  }, {
283
283
  readonly id: HeaderStyleId;
284
- readonly label: "Fine Line";
285
- readonly description: "Light surface with a crisp lower rule and underline hover.";
284
+ readonly label: "Seamless";
285
+ readonly description: "Borderless surface with underline hover for a quieter page transition.";
286
286
  readonly supportedLayoutIds: readonly HeaderLayoutId[];
287
287
  readonly navInteraction: "underline-grow";
288
- readonly surface: "bordered";
289
- readonly defaultDepth: "line";
288
+ readonly surface: "neutral";
289
+ readonly defaultDepth: "none";
290
290
  readonly navTypography: "plain";
291
291
  readonly moods: readonly ["calm", "professional", "editorial"];
292
292
  }, {
@@ -23,7 +23,7 @@ export { buildPageDesignEditorReadModel, boundaryOptions, pageFlowPresets, type
23
23
  export { autoDesignChoice, reducePageDesignIntentForUserAction, resolvePageDesignBlockLookChoice, resolvePageDesignBoundaryChoice, userPinnedDesignChoice, type PageDesignChoice, type PageDesignIntent, type PageDesignUserAction, } from './pageDesignIntent';
24
24
  export { repairDesignIssue, resolveBlockDesignPlan } from './resolver';
25
25
  export { cycleableOptionsFromResolved, deriveDesignCustomizationScope, recommendedDesignOption, type CycleableDesignOption, type CycleableOptions, type DesignCustomizationAuthority, type DesignCustomizationScope, type DesignCustomizationSurface, type DesignCustomizationUnsupportedReason, type DesignOptionIssue, type ResolvedDesignOption, } from './previewCustomization';
26
- export { compileBlockRuntimeFields, compilePageRuntimeFields, compileTokenRecipes, compiledRuntimeStyleFieldNames, defaultComponentRuntimeRules, defaultDesignRuntimeRules, surfaceResolutionContextFromPalette, surfaceResolutionContextFromTheme, stripCompiledRuntimeStyleFields, type CompiledBlockRuntime, type CompiledBlockRuntimeFields, type CompiledPageRuntime, type CompileBlockRuntimeInput, type ComponentRuntimeRules, type DesignRuntimeRules, type SemanticSpacing, type SurfaceResolutionContext, } from './runtimeCompiler';
26
+ export { compileBlockRuntimeFields, compilePageRuntimeFields, compileTokenRecipes, compileTransitionRuntime, compiledRuntimeStyleFieldNames, defaultComponentRuntimeRules, defaultDesignRuntimeRules, surfaceResolutionContextFromPalette, surfaceResolutionContextFromTheme, stripCompiledRuntimeStyleFields, type CompiledBlockRuntime, type CompiledBlockRuntimeFields, type CompiledPageRuntime, type CompileBlockRuntimeInput, type ComponentRuntimeRules, type DesignRuntimeRules, type SemanticSpacing, type SurfaceResolutionContext, } from './runtimeCompiler';
27
27
  export { defaultCuratedChoice, requireEntriesForCuratedChoices, resolveCuratedChoice, type CuratedChoice, type CuratedChoiceResolution, } from './curatedChoices';
28
28
  export { curatedSiteStyles, defaultButtonPersonalityForSiteStyle, defaultPaletteVariantForSiteStyle, defaultTypographyPresetForSiteStyle, getCuratedSiteStyle, type CuratedSiteStyle, } from './curatedSiteStyles';
29
29
  export { asTypographyPresetId, compileTypographySelection, evaluateTypographyFontSlot, findTypographyPreset, parsePersistedTypographyPresetId, typographyPresetIdValues, typographyPresets, type CompiledTypographySelection, type GoogleFontCategory, type KnownTypographyPresetId, type KnownTypographyPresetIdValue, type TypographyFontCapability, type TypographyFontSlot, type TypographyFontSlotFit, type TypographyFontSlotPolicy, type TypographyPreset, type TypographyPresetId, type TypographyPresetResolutionWarning, type TypographySelection, } from './typographyPresets';
@@ -125,4 +125,9 @@ export declare function compileEditorModelRuntimeFieldsForBlock<TBlockId extends
125
125
  blockId: TBlockId;
126
126
  }>): CompiledBlockRuntimeFields | null;
127
127
  export declare function applyCompiledRuntimeFieldsToContent<TContent extends Record<string, unknown>>(content: TContent, fields: CompiledBlockRuntimeFields | null | undefined): Record<string, unknown>;
128
+ export type RuntimeContentAdjacency = Readonly<{
129
+ currentContent: Record<string, unknown> | null | undefined;
130
+ nextContent: Record<string, unknown> | null | undefined;
131
+ }>;
132
+ export declare function retargetCompiledRuntimeFieldsForContentAdjacency(fields: CompiledBlockRuntimeFields | null | undefined, adjacency: RuntimeContentAdjacency): CompiledBlockRuntimeFields | null | undefined;
128
133
  export declare function restoreCompiledRuntimeFieldsFromContent<TCurrentContent extends Record<string, unknown>, TPreviousContent extends Record<string, unknown>>(currentContent: TCurrentContent, previousContent: TPreviousContent): Record<string, unknown>;
@@ -1,11 +1,11 @@
1
- export declare const themeV2RuntimeStyleFieldNames: readonly ["_frameStyles", "_sectionStyles", "_containerStyles", "_cardStyles", "styleGroup"];
1
+ export declare const themeV2RuntimeStyleFieldNames: readonly ["_frameStyles", "_sectionStyles", "_containerStyles", "_cardStyles", "_transitionStyles", "styleGroup"];
2
2
  export type ThemeV2RuntimeStyleFieldName = typeof themeV2RuntimeStyleFieldNames[number];
3
3
  export declare const themeV2BlockSpecificRawStyleFieldNames: readonly ["_contentCardStyles", "_heroLayoutStyles", "_textCardStyles"];
4
4
  export type ThemeV2BlockSpecificRawStyleFieldName = typeof themeV2BlockSpecificRawStyleFieldNames[number];
5
5
  export type ThemeV2NormalEditorRawStyleFieldName = ThemeV2RuntimeStyleFieldName | ThemeV2BlockSpecificRawStyleFieldName;
6
6
  export type ThemeV2CompilerOwnedFieldName = ThemeV2RuntimeStyleFieldName | ThemeV2BlockSpecificRawStyleFieldName;
7
- export declare const themeV2NormalEditorRawStyleFieldNames: readonly ["_frameStyles", "_sectionStyles", "_containerStyles", "_cardStyles", "styleGroup", "_contentCardStyles", "_heroLayoutStyles", "_textCardStyles"];
8
- export declare const themeV2CompilerOwnedFieldNames: readonly ["_frameStyles", "_sectionStyles", "_containerStyles", "_cardStyles", "styleGroup", "_contentCardStyles", "_heroLayoutStyles", "_textCardStyles"];
7
+ export declare const themeV2NormalEditorRawStyleFieldNames: readonly ["_frameStyles", "_sectionStyles", "_containerStyles", "_cardStyles", "_transitionStyles", "styleGroup", "_contentCardStyles", "_heroLayoutStyles", "_textCardStyles"];
8
+ export declare const themeV2CompilerOwnedFieldNames: readonly ["_frameStyles", "_sectionStyles", "_containerStyles", "_cardStyles", "_transitionStyles", "styleGroup", "_contentCardStyles", "_heroLayoutStyles", "_textCardStyles"];
9
9
  export declare const pageDesignEditorBackgroundOverrideOwner: "page-design-editor";
10
10
  export type PageDesignEditorBackgroundOverrideOwner = typeof pageDesignEditorBackgroundOverrideOwner;
11
11
  export declare const siteChromeBackgroundOverrideOwner: "site-chrome-editor";
@@ -4,6 +4,7 @@ import { type ButtonPersonalityId } from '../buttons/personalities';
4
4
  import { type PaletteOverrides, type PaletteVariantId } from '../palette/variants';
5
5
  import { type RuntimeStyleWriteResultForFields, type StyleAuthority } from './designState';
6
6
  import { type ContentFrameIntent, type EyebrowTreatment, type FlushFrameTreatment, type PanelFrameTreatment, type ResolvedBlockDesignPlan, type ResolvedPageDesignPlan, type SiteStyleItemSurfaceIntent, type SiteStyleSectionTransitionIntent, type SiteStyleSurfaceIntent, type ThemeTokenRecipes } from './types';
7
+ import type { ThemeColorToken } from '../tokens';
7
8
  export type SemanticSpacing = 'none' | 'compact' | 'cozy' | 'medium' | 'comfortable' | 'spacious';
8
9
  export type SectionPaddingX = 'normal' | 'none';
9
10
  type SectionForegroundRuntimeTokens = Pick<NonNullable<SectionSurfaceRuntimeRule['background']>, 'textColor' | 'headingColor' | 'linkColor' | 'supportingColor'>;
@@ -29,16 +30,33 @@ export type CompiledBlockRuntimeFields = Readonly<{
29
30
  _contentCardStyles?: ContainerStylesOverride;
30
31
  _heroLayoutStyles?: HeroLayoutStylesOverride;
31
32
  _cardStyles?: CardStylesOverride;
33
+ _transitionStyles?: CompiledTransitionRuntime;
32
34
  blockLook?: string;
33
35
  styleGroup?: string;
34
36
  }>;
37
+ export type CompiledTransitionEndpoint = Readonly<{
38
+ kind: 'surface';
39
+ surface: SiteStyleSurfaceIntent;
40
+ }> | Readonly<{
41
+ kind: 'color-token';
42
+ token: ThemeColorToken;
43
+ }>;
44
+ export type CompiledTransitionRuntime = Readonly<{
45
+ treatment: SiteStyleSectionTransitionIntent;
46
+ from: CompiledTransitionEndpoint;
47
+ to: CompiledTransitionEndpoint;
48
+ cssVars: Readonly<{
49
+ from: string;
50
+ to: string;
51
+ }>;
52
+ }>;
35
53
  export type HeroLayoutStylesOverride = Readonly<{
36
54
  contentAlignment?: 'left' | 'center' | 'right';
37
55
  verticalAlignment?: 'top' | 'center' | 'bottom';
38
56
  contentMaxWidth?: 'default' | 'narrow' | 'medium' | 'wide';
39
57
  typographyScale?: NonNullable<ResolvedBlockDesignPlan['heroTypographyScale']>;
40
58
  }>;
41
- export declare const compiledRuntimeStyleFieldNames: readonly ["_frameStyles", "_sectionStyles", "_containerStyles", "_contentCardStyles", "_heroLayoutStyles", "_cardStyles", "blockLook", "styleGroup"];
59
+ export declare const compiledRuntimeStyleFieldNames: readonly ["_frameStyles", "_sectionStyles", "_containerStyles", "_contentCardStyles", "_heroLayoutStyles", "_cardStyles", "_transitionStyles", "blockLook", "styleGroup"];
42
60
  export declare function stripCompiledRuntimeStyleFields<TContent extends Record<string, unknown>>(content: TContent): Record<string, unknown>;
43
61
  export type CompiledBlockRuntime = Readonly<{
44
62
  blockId: string;
@@ -249,6 +267,11 @@ export declare const defaultComponentRuntimeRules: {
249
267
  export declare function compileBlockRuntimeFields<TBlockId extends string, TPurpose extends string>(input: CompileBlockRuntimeInput<TBlockId, TPurpose>): CompiledBlockRuntime & Readonly<{
250
268
  blockId: TBlockId;
251
269
  }>;
270
+ export declare function compileTransitionRuntime(input: Readonly<{
271
+ treatment: SiteStyleSectionTransitionIntent;
272
+ from: CompiledTransitionEndpoint;
273
+ to: CompiledTransitionEndpoint;
274
+ }>): CompiledTransitionRuntime;
252
275
  /**
253
276
  * Compiles block runtime fields and writes them into content only when Theme V2
254
277
  * owns that block's runtime-style fields.