@riverbankcms/sdk 0.60.3 → 0.60.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_dts/api/src/bookingVerticals.d.ts +1 -0
- package/dist/_dts/api/src/siteManagementEndpoints.d.ts +3 -39
- package/dist/_dts/api/src/siteRuntimeEndpoints.d.ts +2 -0
- package/dist/_dts/blocks/src/system/node/fragments/ctaButton.d.ts +2 -0
- package/dist/_dts/blocks/src/system/runtime/shared/themedButtonClass.d.ts +11 -0
- package/dist/_dts/content-editor/src/ui/editorUiStore.d.ts +10 -2
- package/dist/_dts/core/src/participants.d.ts +32 -1
- package/dist/_dts/core/src/rectification.d.ts +79 -0
- package/dist/_dts/db/src/generated/supabase/database.types.d.ts +6 -6
- package/dist/_dts/preview-next/src/client/preview/StyleConfigurator.state.d.ts +17 -15
- package/dist/_dts/sdk/src/client/types.d.ts +1 -0
- package/dist/_dts/sdk/src/version.d.ts +1 -1
- package/dist/_dts/theme-core/src/buttons/personalities/brushed-wash.d.ts +7 -2
- package/dist/_dts/theme-core/src/buttons/personalities/confident-chip.d.ts +7 -2
- package/dist/_dts/theme-core/src/buttons/personalities/editorial-link.d.ts +7 -2
- package/dist/_dts/theme-core/src/buttons/personalities/index.d.ts +86 -5
- package/dist/_dts/theme-core/src/buttons/personalities/ink-stamp.d.ts +7 -2
- package/dist/_dts/theme-core/src/buttons/personalities/pebble.d.ts +7 -2
- package/dist/_dts/theme-core/src/buttons/personalities/soft-pill.d.ts +7 -2
- package/dist/_dts/theme-core/src/buttons/personalities/types.d.ts +10 -10
- package/dist/_dts/theme-core/src/palette/variants/brand-led.d.ts +33 -9
- package/dist/_dts/theme-core/src/palette/variants/high-contrast.d.ts +33 -9
- package/dist/_dts/theme-core/src/palette/variants/index.d.ts +200 -4
- package/dist/_dts/theme-core/src/palette/variants/soft-natural.d.ts +33 -9
- package/dist/_dts/theme-core/src/palette/variants/types.d.ts +10 -10
- package/dist/_dts/theme-core/src/palette/variants/warm-neutral.d.ts +33 -9
- package/dist/_dts/theme-core/src/site-styles/curatedChoices.d.ts +27 -0
- package/dist/_dts/theme-core/src/site-styles/curatedSiteStyles.d.ts +48 -194
- package/dist/_dts/theme-core/src/site-styles/index.d.ts +2 -1
- package/dist/_dts/theme-core/src/site-styles/previewCompiler.d.ts +12 -14
- package/dist/_dts/theme-core/src/site-styles/styleTags.d.ts +46 -0
- package/dist/_dts/ui/src/palette/ColorChooserDialog.d.ts +47 -0
- package/dist/_dts/ui/src/palette/ColorSlotButton.d.ts +15 -0
- package/dist/_dts/ui/src/palette/ColorSwatchButton.d.ts +15 -0
- package/dist/_dts/ui/src/palette/PaletteTokenEditor.d.ts +50 -0
- package/dist/_dts/ui/src/palette/hex.d.ts +23 -0
- package/dist/_dts/ui/src/palette/index.d.ts +14 -0
- package/dist/cli/index.mjs +1023 -923
- package/dist/client/client.mjs +3410 -3221
- package/dist/client/hooks.mjs +1625 -1564
- package/dist/client/rendering/client.mjs +132 -37
- package/dist/client/rendering/islands.mjs +91 -30
- package/dist/client/rendering.mjs +1237 -1049
- package/dist/preview-next/client/runtime.mjs +3095 -2736
- package/dist/server/components.mjs +2381 -2255
- package/dist/server/config-validation.mjs +1625 -1564
- package/dist/server/config.mjs +1625 -1564
- package/dist/server/data.mjs +1625 -1564
- package/dist/server/index.mjs +4 -3
- package/dist/server/next.mjs +3233 -3106
- package/dist/server/page-converter.mjs +1625 -1564
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/rendering/server.mjs +2381 -2255
- package/dist/server/rendering.mjs +2381 -2255
- package/dist/server/routing.mjs +2340 -2271
- package/dist/server/server.mjs +1629 -1567
- package/dist/server/theme-bridge.mjs +130 -126
- package/dist/server/theme.mjs +131 -129
- package/package.json +1 -1
- package/dist/_dts/theme-core/src/site-styles/compatibility.d.ts +0 -109
|
@@ -661,5 +661,6 @@ export declare function getSelectedPresetForBehaviour(input: Readonly<{
|
|
|
661
661
|
}>): VerticalBookingPresetDefinition | null;
|
|
662
662
|
export declare function getVerticalPresetSelectionOptions(config: SiteVerticalBookingConfig | null | undefined): readonly VerticalPresetSelectionOption[];
|
|
663
663
|
export declare function setVerticalPresetSelected(config: SiteVerticalBookingConfig | null | undefined, presetId: VerticalPresetId, selected: boolean): VerticalPresetSelectionUpdateResult;
|
|
664
|
+
export declare function setVerticalPresetsSelected(config: SiteVerticalBookingConfig | null | undefined, presetIds: readonly VerticalPresetId[]): VerticalPresetSelectionUpdateResult;
|
|
664
665
|
export declare const DEFAULT_SITE_VERTICAL_BOOKING_CONFIG: SiteVerticalBookingConfig;
|
|
665
666
|
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { RectificationIssueUrl, RectificationSurface } from "@riverbankcms/core";
|
|
1
|
+
import type { RectificationHistoryPropagationPlan, RectificationIdentityBoundary, RectificationIssueUrl, RectificationSurface } from "@riverbankcms/core";
|
|
2
2
|
import type { CamelizeKeys, DbRow, DbJson } from "@riverbankcms/db";
|
|
3
3
|
import type { APIEndpoint } from "./apiEndpointTypes";
|
|
4
4
|
import type { AcceptAdminInviteRequest, AcceptAdminInviteResponse, AcceptSiteInvitationRequest, AcceptSiteInvitationResponse, AddCustomDomainRequest, AddCustomDomainResponse, AdminChangePlanRequest, AdminChangePlanResponse, AdminDeleteUserResponse, AuthInviteContinueRequest, AuthInviteContinueResponse, AuthInviteRegisterRequest, AuthInviteRegisterResponse, AuthResetCompleteRequest, AuthResetCompleteResponse, AuthSubmissionResult, BulkOperationResult, ChangePlanRequest, ChangePlanResponse, CreateAdminInviteRequest, CreateAdminInviteResponse, CreateAdminUserRequest, CreateAdminUserResponse, CreateAllowedDomainRequest, CreateAllowedDomainResponse, DeleteAllowedDomainResponse, DomainConfigResult, DomainSearchResultResponse, InviteSiteMemberRequest, InviteSiteMemberResponse, ListAdminInvitesResponse, ListAllowedDomainsResponse, ListSiteMembersResponse, LookupSiteDomainRequest, LookupSiteDomainResponse, MfaBackupCodesOverviewResponse, MfaBackupCodesRotateResponse, MfaOverviewResponse, MfaPhoneChallengeRequest, MfaPhoneChallengeResponse, MfaPhoneEnrollRequest, MfaPhoneEnrollResponse, MfaPhoneVerifyRequest, MfaTotpActivateRequest, MfaTotpEnrollResponse, MfaTotpVerifyRequest, MfaTotpVerifyResponse, ReauthSubmissionResult, RegisterDomainRequestPayload, RegisterDomainResponse, RegisterSiteDomainRequest, RegisterSiteDomainResponse, RemoveSiteMemberResponse, RevokeAdminInviteResponse, RevokeSiteInvitationResponse, SetHomepageRequest, SetHomepageResponse, SiteDomainRecord, TransferSiteOwnershipRequest, TransferSiteOwnershipResponse, UpdateSiteMemberRoleRequest, UpdateSiteMemberRoleResponse } from "./accessAdmin";
|
|
@@ -60,44 +60,8 @@ type DsarRectificationTreatmentApi = {
|
|
|
60
60
|
title: string;
|
|
61
61
|
decisionLabel: string;
|
|
62
62
|
actionLabel: string;
|
|
63
|
-
identityBoundary:
|
|
64
|
-
|
|
65
|
-
} | {
|
|
66
|
-
kind: "customer_backed_participant_current_identity";
|
|
67
|
-
} | {
|
|
68
|
-
kind: "person_record_current_note";
|
|
69
|
-
} | {
|
|
70
|
-
kind: "immutable_subject_snapshot";
|
|
71
|
-
} | {
|
|
72
|
-
kind: "newsletter_current_subscription_identity";
|
|
73
|
-
} | {
|
|
74
|
-
kind: "finance_integrity_record";
|
|
75
|
-
} | {
|
|
76
|
-
kind: "immutable_audit_history";
|
|
77
|
-
} | {
|
|
78
|
-
kind: "derived_history_projection_or_ledger";
|
|
79
|
-
};
|
|
80
|
-
historyPropagation: {
|
|
81
|
-
kind: "update_current_identity_only";
|
|
82
|
-
audit: "required";
|
|
83
|
-
immutableSnapshots: "retain";
|
|
84
|
-
} | {
|
|
85
|
-
kind: "append_correction_note";
|
|
86
|
-
audit: "required";
|
|
87
|
-
immutableSnapshots: "retain_original";
|
|
88
|
-
} | {
|
|
89
|
-
kind: "annotate_immutable_snapshot";
|
|
90
|
-
audit: "required";
|
|
91
|
-
immutableSnapshots: "retain_original";
|
|
92
|
-
} | {
|
|
93
|
-
kind: "manual_review_required";
|
|
94
|
-
audit: "request_only";
|
|
95
|
-
immutableSnapshots: "retain_until_review";
|
|
96
|
-
} | {
|
|
97
|
-
kind: "blocked_immutable_history";
|
|
98
|
-
audit: "blocked_event";
|
|
99
|
-
immutableSnapshots: "retain_original";
|
|
100
|
-
};
|
|
63
|
+
identityBoundary: RectificationIdentityBoundary;
|
|
64
|
+
historyPropagation: RectificationHistoryPropagationPlan;
|
|
101
65
|
operatorSummary: string;
|
|
102
66
|
dataSubjectSummary: string;
|
|
103
67
|
trackingIssue: {
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { NodeDefinition } from "../schema";
|
|
2
|
+
import type { ThemedButtonSize } from "../../runtime/shared/themedButtonClass";
|
|
2
3
|
export declare function ctaButton(opts?: {
|
|
3
4
|
basePath?: string;
|
|
4
5
|
linkPath?: string;
|
|
@@ -14,4 +15,5 @@ export declare function ctaButton(opts?: {
|
|
|
14
15
|
};
|
|
15
16
|
className?: string;
|
|
16
17
|
variantFallback?: string;
|
|
18
|
+
sizeFallback?: ThemedButtonSize;
|
|
17
19
|
}): NodeDefinition;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export type ThemedButtonVariant = 'primary' | 'secondary' | 'outline' | 'link';
|
|
2
|
+
export type ThemedButtonSize = 'sm' | 'md' | 'lg' | 'xl';
|
|
3
|
+
export type ThemedButtonClassName = string & {
|
|
4
|
+
readonly __brand: 'ThemedButtonClassName';
|
|
5
|
+
};
|
|
6
|
+
export type ThemedButtonClassSpec = Readonly<{
|
|
7
|
+
variant: ThemedButtonVariant;
|
|
8
|
+
size: ThemedButtonSize;
|
|
9
|
+
extraClassName?: string | null;
|
|
10
|
+
}>;
|
|
11
|
+
export declare function themedButtonClass(spec: ThemedButtonClassSpec): ThemedButtonClassName;
|
|
@@ -19,6 +19,14 @@ export type ActivePreviewField = Readonly<{
|
|
|
19
19
|
blockId: EditorBlockId;
|
|
20
20
|
fieldPath: string;
|
|
21
21
|
}> | null;
|
|
22
|
+
/**
|
|
23
|
+
* Version of the local draft snapshot that a completed autosave request persisted.
|
|
24
|
+
* The reducer uses this to accept the saved baseline without treating older
|
|
25
|
+
* in-flight saves as acknowledgements of newer local edits.
|
|
26
|
+
*/
|
|
27
|
+
export type AutosaveAcknowledgement = Readonly<{
|
|
28
|
+
acknowledgedVersion: number;
|
|
29
|
+
}>;
|
|
22
30
|
/**
|
|
23
31
|
* Form-facing metadata facade. Consumers pass plain records for ergonomics;
|
|
24
32
|
* the reducer core normalizes and brands values at this boundary.
|
|
@@ -33,7 +41,7 @@ export type MetadataState = {
|
|
|
33
41
|
setCurrentValues: (values: Record<string, unknown> | null) => void;
|
|
34
42
|
setAtPath: (path: string, value: unknown) => void;
|
|
35
43
|
getAtPath: <R = unknown>(path: string) => R | undefined;
|
|
36
|
-
autosaveSucceeded: (savedValues: Record<string, unknown> | null,
|
|
44
|
+
autosaveSucceeded: (savedValues: Record<string, unknown> | null, acknowledgement?: AutosaveAcknowledgement) => void;
|
|
37
45
|
autosaveFailed: (message?: string) => void;
|
|
38
46
|
clearError: () => void;
|
|
39
47
|
};
|
|
@@ -77,7 +85,7 @@ export type DraftsState = {
|
|
|
77
85
|
setPending: (blockId: EditorBlockId) => void;
|
|
78
86
|
clearPending: (blockId: EditorBlockId) => void;
|
|
79
87
|
setFailed: (blockId: EditorBlockId, message?: string) => void;
|
|
80
|
-
autosaveSucceeded: (blockId: EditorBlockId, content: Record<string, unknown> | null) => void;
|
|
88
|
+
autosaveSucceeded: (blockId: EditorBlockId, content: Record<string, unknown> | null, acknowledgement?: AutosaveAcknowledgement) => void;
|
|
81
89
|
autosaveFailed: (blockId: EditorBlockId, message?: string) => void;
|
|
82
90
|
setAtPath: (blockId: EditorBlockId, path: string, value: unknown) => void;
|
|
83
91
|
getAtPath: <T = unknown>(blockId: EditorBlockId, path: string) => T | undefined;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import type
|
|
1
|
+
import { type AppointmentId, type AttendeeId, type Brand, type CustomerId, type EnrollmentId, type EventAttendeeGuestId, type ParticipantId } from './branded';
|
|
2
2
|
import { type Result } from './result';
|
|
3
3
|
export type ParticipantEmail = Brand<string, 'ParticipantEmail'>;
|
|
4
4
|
export type ParticipantSlotKey = Brand<string, 'ParticipantSlotKey'>;
|
|
5
5
|
export type ParticipantCount = Brand<number, 'ParticipantCount'>;
|
|
6
|
+
export type ParticipantDisplayLabel = Brand<string, 'ParticipantDisplayLabel'>;
|
|
6
7
|
export type ParticipantEmailNormalizationError = {
|
|
7
8
|
kind: 'empty_email';
|
|
8
9
|
} | {
|
|
@@ -13,6 +14,26 @@ export type ParticipantCountParseError = {
|
|
|
13
14
|
} | {
|
|
14
15
|
kind: 'non_positive_participant_count';
|
|
15
16
|
};
|
|
17
|
+
export type ProvisionalParticipantIdentity = Readonly<{
|
|
18
|
+
kind: 'event_guest';
|
|
19
|
+
eventAttendeeGuestId: EventAttendeeGuestId;
|
|
20
|
+
slotKey: ParticipantSlotKey;
|
|
21
|
+
}>;
|
|
22
|
+
export type ProvisionalParticipantIdentityMetadata = Readonly<{
|
|
23
|
+
kind: 'event_guest';
|
|
24
|
+
source: 'event_guest_backfill';
|
|
25
|
+
eventAttendeeGuestId: EventAttendeeGuestId;
|
|
26
|
+
slotKey: ParticipantSlotKey;
|
|
27
|
+
}>;
|
|
28
|
+
export type ProvisionalParticipantIdentityParseError = {
|
|
29
|
+
kind: 'not_an_object';
|
|
30
|
+
} | {
|
|
31
|
+
kind: 'unsupported_identity_kind';
|
|
32
|
+
} | {
|
|
33
|
+
kind: 'missing_event_attendee_guest_id';
|
|
34
|
+
} | {
|
|
35
|
+
kind: 'missing_slot_key';
|
|
36
|
+
};
|
|
16
37
|
export declare function asParticipantSlotKey(value: string): ParticipantSlotKey;
|
|
17
38
|
export declare function asParticipantCount(value: number): ParticipantCount;
|
|
18
39
|
/**
|
|
@@ -24,6 +45,16 @@ export declare function asParticipantCount(value: number): ParticipantCount;
|
|
|
24
45
|
export declare function normalizeParticipantEmail(value: string | null | undefined): ParticipantEmail | null;
|
|
25
46
|
export declare function parseParticipantEmail(value: string | null | undefined): Result<ParticipantEmail, ParticipantEmailNormalizationError>;
|
|
26
47
|
export declare function parseParticipantCount(value: number): Result<ParticipantCount, ParticipantCountParseError>;
|
|
48
|
+
export declare function provisionalEventGuestParticipantIdentity(input: Readonly<{
|
|
49
|
+
eventAttendeeGuestId: EventAttendeeGuestId;
|
|
50
|
+
slotKey: ParticipantSlotKey;
|
|
51
|
+
}>): ProvisionalParticipantIdentity;
|
|
52
|
+
export declare function encodeProvisionalParticipantIdentity(identity: ProvisionalParticipantIdentity): ProvisionalParticipantIdentityMetadata;
|
|
53
|
+
export declare function parseProvisionalParticipantIdentity(value: unknown): Result<ProvisionalParticipantIdentity, ProvisionalParticipantIdentityParseError>;
|
|
54
|
+
export declare function deriveParticipantDisplayLabel(input: Readonly<{
|
|
55
|
+
displayName: string | null;
|
|
56
|
+
emailNormalized: ParticipantEmail | null;
|
|
57
|
+
}>): ParticipantDisplayLabel;
|
|
27
58
|
export type ParticipantIdentityState = {
|
|
28
59
|
kind: 'booker_supplied';
|
|
29
60
|
} | {
|
|
@@ -2,3 +2,82 @@ export declare const RECTIFICATION_SURFACES: readonly ["customer_profile", "book
|
|
|
2
2
|
export type RectificationSurface = (typeof RECTIFICATION_SURFACES)[number];
|
|
3
3
|
export declare const RECTIFICATION_ISSUE_URL_BASE: "https://github.com/wubss/builder/issues";
|
|
4
4
|
export type RectificationIssueUrl<TNumber extends number = number> = `${typeof RECTIFICATION_ISSUE_URL_BASE}/${TNumber}`;
|
|
5
|
+
/**
|
|
6
|
+
* Names which identity concept a rectification surface is allowed to mutate or
|
|
7
|
+
* explain, so customer, participant, snapshot, and ledger corrections cannot blur.
|
|
8
|
+
*/
|
|
9
|
+
export type RectificationIdentityBoundary = Readonly<{
|
|
10
|
+
kind: 'customer_commercial_current_identity';
|
|
11
|
+
}> | Readonly<{
|
|
12
|
+
kind: 'customer_backed_participant_current_identity';
|
|
13
|
+
}> | Readonly<{
|
|
14
|
+
kind: 'person_record_current_note';
|
|
15
|
+
}> | Readonly<{
|
|
16
|
+
kind: 'immutable_subject_snapshot';
|
|
17
|
+
}> | Readonly<{
|
|
18
|
+
kind: 'newsletter_current_subscription_identity';
|
|
19
|
+
}> | Readonly<{
|
|
20
|
+
kind: 'finance_integrity_record';
|
|
21
|
+
}> | Readonly<{
|
|
22
|
+
kind: 'immutable_audit_history';
|
|
23
|
+
}> | Readonly<{
|
|
24
|
+
kind: 'derived_history_projection_or_ledger';
|
|
25
|
+
}>;
|
|
26
|
+
export declare const RECTIFICATION_IDENTITY_BOUNDARIES: {
|
|
27
|
+
readonly customer_commercial_current_identity: {
|
|
28
|
+
readonly kind: "customer_commercial_current_identity";
|
|
29
|
+
};
|
|
30
|
+
readonly customer_backed_participant_current_identity: {
|
|
31
|
+
readonly kind: "customer_backed_participant_current_identity";
|
|
32
|
+
};
|
|
33
|
+
readonly person_record_current_note: {
|
|
34
|
+
readonly kind: "person_record_current_note";
|
|
35
|
+
};
|
|
36
|
+
readonly immutable_subject_snapshot: {
|
|
37
|
+
readonly kind: "immutable_subject_snapshot";
|
|
38
|
+
};
|
|
39
|
+
readonly newsletter_current_subscription_identity: {
|
|
40
|
+
readonly kind: "newsletter_current_subscription_identity";
|
|
41
|
+
};
|
|
42
|
+
readonly finance_integrity_record: {
|
|
43
|
+
readonly kind: "finance_integrity_record";
|
|
44
|
+
};
|
|
45
|
+
readonly immutable_audit_history: {
|
|
46
|
+
readonly kind: "immutable_audit_history";
|
|
47
|
+
};
|
|
48
|
+
readonly derived_history_projection_or_ledger: {
|
|
49
|
+
readonly kind: "derived_history_projection_or_ledger";
|
|
50
|
+
};
|
|
51
|
+
};
|
|
52
|
+
/**
|
|
53
|
+
* Describes what happens to historical copies when the current identity source
|
|
54
|
+
* is corrected; immutable evidence is retained unless a plan says otherwise.
|
|
55
|
+
*/
|
|
56
|
+
export type RectificationHistoryPropagationPlan = Readonly<{
|
|
57
|
+
kind: 'update_current_identity_only';
|
|
58
|
+
}> | Readonly<{
|
|
59
|
+
kind: 'append_correction_note';
|
|
60
|
+
}> | Readonly<{
|
|
61
|
+
kind: 'annotate_immutable_snapshot';
|
|
62
|
+
}> | Readonly<{
|
|
63
|
+
kind: 'manual_review_required';
|
|
64
|
+
}> | Readonly<{
|
|
65
|
+
kind: 'blocked_immutable_history';
|
|
66
|
+
}>;
|
|
67
|
+
export declare const RECTIFICATION_HISTORY_PROPAGATION_PLANS: {
|
|
68
|
+
readonly update_current_identity_only: {
|
|
69
|
+
readonly kind: "update_current_identity_only";
|
|
70
|
+
};
|
|
71
|
+
readonly append_correction_note: {
|
|
72
|
+
readonly kind: "append_correction_note";
|
|
73
|
+
};
|
|
74
|
+
readonly annotate_immutable_snapshot: {
|
|
75
|
+
readonly kind: "annotate_immutable_snapshot";
|
|
76
|
+
};
|
|
77
|
+
readonly manual_review_required: {
|
|
78
|
+
readonly kind: "manual_review_required";
|
|
79
|
+
};
|
|
80
|
+
readonly blocked_immutable_history: {
|
|
81
|
+
readonly kind: "blocked_immutable_history";
|
|
82
|
+
};
|
|
83
|
+
};
|
|
@@ -2254,8 +2254,8 @@ export type Database = {
|
|
|
2254
2254
|
created_at: string;
|
|
2255
2255
|
customer_id: string | null;
|
|
2256
2256
|
display_name: string | null;
|
|
2257
|
-
email: string;
|
|
2258
|
-
email_normalized: string;
|
|
2257
|
+
email: string | null;
|
|
2258
|
+
email_normalized: string | null;
|
|
2259
2259
|
id: string;
|
|
2260
2260
|
identity_state: string;
|
|
2261
2261
|
metadata: Json;
|
|
@@ -2267,8 +2267,8 @@ export type Database = {
|
|
|
2267
2267
|
created_at?: string;
|
|
2268
2268
|
customer_id?: string | null;
|
|
2269
2269
|
display_name?: string | null;
|
|
2270
|
-
email
|
|
2271
|
-
email_normalized
|
|
2270
|
+
email?: string | null;
|
|
2271
|
+
email_normalized?: string | null;
|
|
2272
2272
|
id?: string;
|
|
2273
2273
|
identity_state?: string;
|
|
2274
2274
|
metadata?: Json;
|
|
@@ -2280,8 +2280,8 @@ export type Database = {
|
|
|
2280
2280
|
created_at?: string;
|
|
2281
2281
|
customer_id?: string | null;
|
|
2282
2282
|
display_name?: string | null;
|
|
2283
|
-
email?: string;
|
|
2284
|
-
email_normalized?: string;
|
|
2283
|
+
email?: string | null;
|
|
2284
|
+
email_normalized?: string | null;
|
|
2285
2285
|
id?: string;
|
|
2286
2286
|
identity_state?: string;
|
|
2287
2287
|
metadata?: Json;
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
*/
|
|
13
13
|
import type { ButtonPersonalityId } from '@riverbankcms/theme-core/buttons';
|
|
14
14
|
import type { PaletteOverrides, PaletteVariantId } from '@riverbankcms/theme-core/palette';
|
|
15
|
-
import type {
|
|
15
|
+
import type { SelectionFallbackWarning, SiteStyleId } from '@riverbankcms/theme-core/site-styles/previewCompiler';
|
|
16
16
|
export type StyleConfiguratorSaveStatus = Readonly<{
|
|
17
17
|
kind: 'idle';
|
|
18
18
|
}> | Readonly<{
|
|
@@ -25,13 +25,15 @@ export type StyleConfiguratorSaveStatus = Readonly<{
|
|
|
25
25
|
}>;
|
|
26
26
|
export type StyleConfiguratorExpandedRow = 'style' | 'buttons' | 'palette' | 'colours' | null;
|
|
27
27
|
/**
|
|
28
|
-
* Configurator-level notices that aren't compiler
|
|
29
|
-
* Kept separate from `
|
|
28
|
+
* Configurator-level notices that aren't compiler selection fallback warnings.
|
|
29
|
+
* Kept separate from `SelectionFallbackWarning` (which comes from
|
|
30
30
|
* `compileSiteThemeFromSelections`) so the layers stay clean: warnings are
|
|
31
31
|
* compiler-emitted, notices are UI-level decisions the configurator makes.
|
|
32
32
|
*/
|
|
33
33
|
export type StyleConfiguratorNotice = Readonly<{
|
|
34
|
-
kind: 'overrides-
|
|
34
|
+
kind: 'palette-overrides-hidden';
|
|
35
|
+
}> | Readonly<{
|
|
36
|
+
kind: 'palette-overrides-restored';
|
|
35
37
|
}>;
|
|
36
38
|
export type SelectionSnapshot = Readonly<{
|
|
37
39
|
siteStyleId: SiteStyleId;
|
|
@@ -39,6 +41,7 @@ export type SelectionSnapshot = Readonly<{
|
|
|
39
41
|
paletteVariantId: PaletteVariantId;
|
|
40
42
|
paletteOverrides: PaletteOverrides | null;
|
|
41
43
|
}>;
|
|
44
|
+
type PaletteOverrideDrafts = Readonly<Partial<Record<PaletteVariantId, PaletteOverrides>>>;
|
|
42
45
|
export type StyleConfiguratorState = Readonly<{
|
|
43
46
|
/**
|
|
44
47
|
* Last persisted server snapshot. Updated on apply-success (and on
|
|
@@ -51,8 +54,9 @@ export type StyleConfiguratorState = Readonly<{
|
|
|
51
54
|
*/
|
|
52
55
|
previewed: SelectionSnapshot;
|
|
53
56
|
saveStatus: StyleConfiguratorSaveStatus;
|
|
54
|
-
warnings: ReadonlyArray<
|
|
57
|
+
warnings: ReadonlyArray<SelectionFallbackWarning>;
|
|
55
58
|
notices: ReadonlyArray<StyleConfiguratorNotice>;
|
|
59
|
+
paletteOverrideDrafts: PaletteOverrideDrafts;
|
|
56
60
|
expandedRow: StyleConfiguratorExpandedRow;
|
|
57
61
|
}>;
|
|
58
62
|
export declare function createStyleConfiguratorState(base: SelectionSnapshot): StyleConfiguratorState;
|
|
@@ -67,22 +71,18 @@ export declare function previewButtonPersonality(state: StyleConfiguratorState,
|
|
|
67
71
|
export declare function previewPaletteVariant(state: StyleConfiguratorState, paletteVariantId: PaletteVariantId): StyleConfiguratorState;
|
|
68
72
|
export declare function setPaletteOverrides(state: StyleConfiguratorState, paletteOverrides: PaletteOverrides | null): StyleConfiguratorState;
|
|
69
73
|
/**
|
|
70
|
-
* Records the post-compile resolved selection + any
|
|
74
|
+
* Records the post-compile resolved selection + any fallback warnings.
|
|
71
75
|
* Used after `compileSiteThemeFromSelections` runs against a new site style:
|
|
72
76
|
* the resolver may have auto-picked a different personality / palette if the
|
|
73
|
-
* user's previous selections
|
|
77
|
+
* user's previous selections are not offered for the new style.
|
|
74
78
|
*
|
|
75
|
-
*
|
|
76
|
-
*
|
|
77
|
-
*
|
|
78
|
-
* `primary` if the new style has a fundamentally different palette voice).
|
|
79
|
-
* A `'overrides-cleared-by-site-style-switch'` notice is appended so the UI
|
|
80
|
-
* can surface a "we cleared your colour overrides" line.
|
|
79
|
+
* Palette overrides are scoped by palette variant. If the resolver moves the
|
|
80
|
+
* preview to a different palette, the current sparse overrides are stashed
|
|
81
|
+
* under the previous palette ID and any draft for the new palette is restored.
|
|
81
82
|
*/
|
|
82
83
|
export declare function applyResolvedSelections(state: StyleConfiguratorState, input: Readonly<{
|
|
83
84
|
resolved: Pick<SelectionSnapshot, 'buttonPersonalityId' | 'paletteVariantId'>;
|
|
84
|
-
warnings: ReadonlyArray<
|
|
85
|
-
clearOverrides?: boolean;
|
|
85
|
+
warnings: ReadonlyArray<SelectionFallbackWarning>;
|
|
86
86
|
}>): StyleConfiguratorState;
|
|
87
87
|
export declare function cancelPreview(state: StyleConfiguratorState): StyleConfiguratorState;
|
|
88
88
|
export declare function markApplySaving(state: StyleConfiguratorState): StyleConfiguratorState;
|
|
@@ -97,3 +97,5 @@ export declare function dismissNotices(state: StyleConfiguratorState): StyleConf
|
|
|
97
97
|
* changes the persisted selection out-of-band.
|
|
98
98
|
*/
|
|
99
99
|
export declare function syncStyleConfiguratorState(state: StyleConfiguratorState, base: SelectionSnapshot): StyleConfiguratorState;
|
|
100
|
+
export declare function paletteOverridesEqual(a: PaletteOverrides | null, b: PaletteOverrides | null): boolean;
|
|
101
|
+
export {};
|
|
@@ -3,9 +3,14 @@
|
|
|
3
3
|
* Generous padding, soft shadows; pairs with vibrant organic brands.
|
|
4
4
|
*/
|
|
5
5
|
export declare const brushedWash: Readonly<{
|
|
6
|
-
id: import("./types").ButtonPersonalityId
|
|
6
|
+
id: import("./types").ButtonPersonalityId<"brushed-wash">;
|
|
7
7
|
name: string;
|
|
8
8
|
description: string;
|
|
9
|
-
tags:
|
|
9
|
+
tags: Readonly<Partial<Readonly<{
|
|
10
|
+
tone: import("../../site-styles").StyleTone;
|
|
11
|
+
energy: import("../../site-styles").StyleEnergy;
|
|
12
|
+
motion: import("../../site-styles").StyleMotion;
|
|
13
|
+
era: import("../../site-styles").StyleEra;
|
|
14
|
+
}>>>;
|
|
10
15
|
buttonSystem: import("@riverbankcms/blocks").ButtonSystem;
|
|
11
16
|
}>;
|
|
@@ -3,9 +3,14 @@
|
|
|
3
3
|
* direct. Default for Clear Professional; works for any modern brand voice.
|
|
4
4
|
*/
|
|
5
5
|
export declare const confidentChip: Readonly<{
|
|
6
|
-
id: import("./types").ButtonPersonalityId
|
|
6
|
+
id: import("./types").ButtonPersonalityId<"confident-chip">;
|
|
7
7
|
name: string;
|
|
8
8
|
description: string;
|
|
9
|
-
tags:
|
|
9
|
+
tags: Readonly<Partial<Readonly<{
|
|
10
|
+
tone: import("../../site-styles").StyleTone;
|
|
11
|
+
energy: import("../../site-styles").StyleEnergy;
|
|
12
|
+
motion: import("../../site-styles").StyleMotion;
|
|
13
|
+
era: import("../../site-styles").StyleEra;
|
|
14
|
+
}>>>;
|
|
10
15
|
buttonSystem: import("@riverbankcms/blocks").ButtonSystem;
|
|
11
16
|
}>;
|
|
@@ -3,9 +3,14 @@
|
|
|
3
3
|
* Default for Warm Editorial and Quiet Luxury; reads as refined and quiet.
|
|
4
4
|
*/
|
|
5
5
|
export declare const editorialLink: Readonly<{
|
|
6
|
-
id: import("./types").ButtonPersonalityId
|
|
6
|
+
id: import("./types").ButtonPersonalityId<"editorial-link">;
|
|
7
7
|
name: string;
|
|
8
8
|
description: string;
|
|
9
|
-
tags:
|
|
9
|
+
tags: Readonly<Partial<Readonly<{
|
|
10
|
+
tone: import("../../site-styles").StyleTone;
|
|
11
|
+
energy: import("../../site-styles").StyleEnergy;
|
|
12
|
+
motion: import("../../site-styles").StyleMotion;
|
|
13
|
+
era: import("../../site-styles").StyleEra;
|
|
14
|
+
}>>>;
|
|
10
15
|
buttonSystem: import("@riverbankcms/blocks").ButtonSystem;
|
|
11
16
|
}>;
|
|
@@ -2,13 +2,94 @@
|
|
|
2
2
|
* Button personality library.
|
|
3
3
|
*
|
|
4
4
|
* Each personality is a complete `ButtonSystem` tagged on the four style axes
|
|
5
|
-
* (tone / energy / motion / era). Curated site styles declare
|
|
6
|
-
* personality
|
|
7
|
-
*
|
|
8
|
-
* to surface valid options.
|
|
5
|
+
* (tone / energy / motion / era). Curated site styles declare ordered
|
|
6
|
+
* personality choices for the picker. Tags stay available as authoring/audit
|
|
7
|
+
* metadata; they no longer drive the Style configurator's option shape.
|
|
9
8
|
*/
|
|
10
9
|
import type { ButtonPersonality, ButtonPersonalityId } from './types';
|
|
11
10
|
export type { ButtonPersonality, ButtonPersonalityId } from './types';
|
|
12
11
|
export { asButtonPersonalityId, buttonPersonalityIdSchema, buttonPersonalitySchema, defineButtonPersonality, } from './types';
|
|
13
|
-
export declare const buttonPersonalities: readonly
|
|
12
|
+
export declare const buttonPersonalities: readonly [Readonly<{
|
|
13
|
+
id: ButtonPersonalityId<"soft-pill">;
|
|
14
|
+
name: string;
|
|
15
|
+
description: string;
|
|
16
|
+
tags: Readonly<Partial<Readonly<{
|
|
17
|
+
tone: import("../../site-styles").StyleTone;
|
|
18
|
+
energy: import("../../site-styles").StyleEnergy;
|
|
19
|
+
motion: import("../../site-styles").StyleMotion;
|
|
20
|
+
era: import("../../site-styles").StyleEra;
|
|
21
|
+
}>>>;
|
|
22
|
+
buttonSystem: import("@riverbankcms/blocks").ButtonSystem;
|
|
23
|
+
}>, Readonly<{
|
|
24
|
+
id: ButtonPersonalityId<"confident-chip">;
|
|
25
|
+
name: string;
|
|
26
|
+
description: string;
|
|
27
|
+
tags: Readonly<Partial<Readonly<{
|
|
28
|
+
tone: import("../../site-styles").StyleTone;
|
|
29
|
+
energy: import("../../site-styles").StyleEnergy;
|
|
30
|
+
motion: import("../../site-styles").StyleMotion;
|
|
31
|
+
era: import("../../site-styles").StyleEra;
|
|
32
|
+
}>>>;
|
|
33
|
+
buttonSystem: import("@riverbankcms/blocks").ButtonSystem;
|
|
34
|
+
}>, Readonly<{
|
|
35
|
+
id: ButtonPersonalityId<"editorial-link">;
|
|
36
|
+
name: string;
|
|
37
|
+
description: string;
|
|
38
|
+
tags: Readonly<Partial<Readonly<{
|
|
39
|
+
tone: import("../../site-styles").StyleTone;
|
|
40
|
+
energy: import("../../site-styles").StyleEnergy;
|
|
41
|
+
motion: import("../../site-styles").StyleMotion;
|
|
42
|
+
era: import("../../site-styles").StyleEra;
|
|
43
|
+
}>>>;
|
|
44
|
+
buttonSystem: import("@riverbankcms/blocks").ButtonSystem;
|
|
45
|
+
}>, Readonly<{
|
|
46
|
+
id: ButtonPersonalityId<"pebble">;
|
|
47
|
+
name: string;
|
|
48
|
+
description: string;
|
|
49
|
+
tags: Readonly<Partial<Readonly<{
|
|
50
|
+
tone: import("../../site-styles").StyleTone;
|
|
51
|
+
energy: import("../../site-styles").StyleEnergy;
|
|
52
|
+
motion: import("../../site-styles").StyleMotion;
|
|
53
|
+
era: import("../../site-styles").StyleEra;
|
|
54
|
+
}>>>;
|
|
55
|
+
buttonSystem: import("@riverbankcms/blocks").ButtonSystem;
|
|
56
|
+
}>, Readonly<{
|
|
57
|
+
id: ButtonPersonalityId<"ink-stamp">;
|
|
58
|
+
name: string;
|
|
59
|
+
description: string;
|
|
60
|
+
tags: Readonly<Partial<Readonly<{
|
|
61
|
+
tone: import("../../site-styles").StyleTone;
|
|
62
|
+
energy: import("../../site-styles").StyleEnergy;
|
|
63
|
+
motion: import("../../site-styles").StyleMotion;
|
|
64
|
+
era: import("../../site-styles").StyleEra;
|
|
65
|
+
}>>>;
|
|
66
|
+
buttonSystem: import("@riverbankcms/blocks").ButtonSystem;
|
|
67
|
+
}>, Readonly<{
|
|
68
|
+
id: ButtonPersonalityId<"brushed-wash">;
|
|
69
|
+
name: string;
|
|
70
|
+
description: string;
|
|
71
|
+
tags: Readonly<Partial<Readonly<{
|
|
72
|
+
tone: import("../../site-styles").StyleTone;
|
|
73
|
+
energy: import("../../site-styles").StyleEnergy;
|
|
74
|
+
motion: import("../../site-styles").StyleMotion;
|
|
75
|
+
era: import("../../site-styles").StyleEra;
|
|
76
|
+
}>>>;
|
|
77
|
+
buttonSystem: import("@riverbankcms/blocks").ButtonSystem;
|
|
78
|
+
}>];
|
|
79
|
+
type UnbrandedButtonPersonalityId<TValue> = TValue extends infer TRaw & {
|
|
80
|
+
readonly __brand: 'ButtonPersonalityId';
|
|
81
|
+
} ? TRaw extends string ? TRaw : never : never;
|
|
82
|
+
export type KnownButtonPersonalityId = (typeof buttonPersonalities)[number]['id'];
|
|
83
|
+
export type KnownButtonPersonalityIdValue = UnbrandedButtonPersonalityId<KnownButtonPersonalityId>;
|
|
14
84
|
export declare function findButtonPersonality(id: ButtonPersonalityId): ButtonPersonality | undefined;
|
|
85
|
+
export declare function isKnownButtonPersonalityId(value: string): value is KnownButtonPersonalityId;
|
|
86
|
+
export type PersistedButtonPersonalityIdParseResult = Readonly<{
|
|
87
|
+
kind: 'known';
|
|
88
|
+
id: KnownButtonPersonalityId;
|
|
89
|
+
}> | Readonly<{
|
|
90
|
+
kind: 'unknown';
|
|
91
|
+
raw: string;
|
|
92
|
+
}> | Readonly<{
|
|
93
|
+
kind: 'empty';
|
|
94
|
+
}>;
|
|
95
|
+
export declare function parsePersistedButtonPersonalityId(value: string | null | undefined): PersistedButtonPersonalityIdParseResult;
|
|
@@ -3,9 +3,14 @@
|
|
|
3
3
|
* feel. Reads as bold and handmade; suits expressive craft brands.
|
|
4
4
|
*/
|
|
5
5
|
export declare const inkStamp: Readonly<{
|
|
6
|
-
id: import("./types").ButtonPersonalityId
|
|
6
|
+
id: import("./types").ButtonPersonalityId<"ink-stamp">;
|
|
7
7
|
name: string;
|
|
8
8
|
description: string;
|
|
9
|
-
tags:
|
|
9
|
+
tags: Readonly<Partial<Readonly<{
|
|
10
|
+
tone: import("../../site-styles").StyleTone;
|
|
11
|
+
energy: import("../../site-styles").StyleEnergy;
|
|
12
|
+
motion: import("../../site-styles").StyleMotion;
|
|
13
|
+
era: import("../../site-styles").StyleEra;
|
|
14
|
+
}>>>;
|
|
10
15
|
buttonSystem: import("@riverbankcms/blocks").ButtonSystem;
|
|
11
16
|
}>;
|
|
@@ -3,9 +3,14 @@
|
|
|
3
3
|
* and natural; pairs well with wellness/yoga/dance brands.
|
|
4
4
|
*/
|
|
5
5
|
export declare const pebble: Readonly<{
|
|
6
|
-
id: import("./types").ButtonPersonalityId
|
|
6
|
+
id: import("./types").ButtonPersonalityId<"pebble">;
|
|
7
7
|
name: string;
|
|
8
8
|
description: string;
|
|
9
|
-
tags:
|
|
9
|
+
tags: Readonly<Partial<Readonly<{
|
|
10
|
+
tone: import("../../site-styles").StyleTone;
|
|
11
|
+
energy: import("../../site-styles").StyleEnergy;
|
|
12
|
+
motion: import("../../site-styles").StyleMotion;
|
|
13
|
+
era: import("../../site-styles").StyleEra;
|
|
14
|
+
}>>>;
|
|
10
15
|
buttonSystem: import("@riverbankcms/blocks").ButtonSystem;
|
|
11
16
|
}>;
|
|
@@ -3,9 +3,14 @@
|
|
|
3
3
|
* Calm Studio and Modern Wellness; reads as quietly modern and welcoming.
|
|
4
4
|
*/
|
|
5
5
|
export declare const softPill: Readonly<{
|
|
6
|
-
id: import("./types").ButtonPersonalityId
|
|
6
|
+
id: import("./types").ButtonPersonalityId<"soft-pill">;
|
|
7
7
|
name: string;
|
|
8
8
|
description: string;
|
|
9
|
-
tags:
|
|
9
|
+
tags: Readonly<Partial<Readonly<{
|
|
10
|
+
tone: import("../../site-styles").StyleTone;
|
|
11
|
+
energy: import("../../site-styles").StyleEnergy;
|
|
12
|
+
motion: import("../../site-styles").StyleMotion;
|
|
13
|
+
era: import("../../site-styles").StyleEra;
|
|
14
|
+
}>>>;
|
|
10
15
|
buttonSystem: import("@riverbankcms/blocks").ButtonSystem;
|
|
11
16
|
}>;
|