@riverbankcms/sdk 0.95.0 → 0.98.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.
- package/README.md +47 -5
- package/dist/{PreviewEditorSidebar-6FQYKOSB.mjs → PreviewEditorSidebar-CG3SSJND.mjs} +3 -3
- package/dist/{PreviewEditorUI-NPO2XMFB.mjs → PreviewEditorUI-RHNGKAAU.mjs} +3 -3
- package/dist/SdkPreviewModeRuntime-OV5PNJBB.mjs +8 -0
- package/dist/_dts/ai/src/contracts/proposals.d.ts +10 -10
- package/dist/_dts/api/src/bookingManagementEndpoints.d.ts +35 -1
- package/dist/_dts/api/src/bookingOperations.d.ts +246 -0
- package/dist/_dts/api/src/contentRuntime.d.ts +109 -40
- package/dist/_dts/api/src/endpoints.d.ts +80 -0
- package/dist/_dts/api/src/index.d.ts +3 -2
- package/dist/_dts/api/src/public/endpoints.d.ts +1 -1
- package/dist/_dts/api/src/publicExperienceEndpoints.d.ts +10 -0
- package/dist/_dts/api/src/sdkContracts.d.ts +2 -0
- package/dist/_dts/api/src/siteManagementEndpoints.d.ts +2 -1
- package/dist/_dts/api/src/siteRuntimeEndpoints.d.ts +7 -1
- package/dist/_dts/block-form/src/client/index.d.ts +1 -1
- package/dist/_dts/block-form/src/fields/types.d.ts +9 -1
- package/dist/_dts/block-form/src/registry/schemas.d.ts +4 -0
- package/dist/_dts/block-form/src/registry/widgets.d.ts +1 -0
- package/dist/_dts/block-form/src/widgets/InlineTextField/InlineTextField.d.ts +4 -0
- package/dist/_dts/block-form/src/widgets/InlineTextField/index.d.ts +3 -0
- package/dist/_dts/block-form/src/widgets/InlineTextField/inlineTextFieldDefaults.d.ts +2 -0
- package/dist/_dts/block-form/src/widgets/InlineTextField/inlineTextFieldSchema.d.ts +3 -0
- package/dist/_dts/blocks/src/PageRenderer.d.ts +2 -1
- package/dist/_dts/blocks/src/bindings/index.d.ts +1 -0
- package/dist/_dts/blocks/src/bindings/types.d.ts +1 -4
- package/dist/_dts/blocks/src/client/site-chrome.d.ts +7 -0
- package/dist/_dts/blocks/src/contracts/index.d.ts +1 -0
- package/dist/_dts/blocks/src/contracts/proof-block-islands.d.ts +12 -12
- package/dist/_dts/blocks/src/index.d.ts +2 -0
- package/dist/_dts/blocks/src/primitives/content/primitives.d.ts +4 -0
- package/dist/_dts/blocks/src/system/blocks/appointment-booking.d.ts +2 -29631
- package/dist/_dts/blocks/src/system/blocks/blog-listing.d.ts +2 -29614
- package/dist/_dts/blocks/src/system/blocks/cart.d.ts +2 -29634
- package/dist/_dts/blocks/src/system/blocks/checkout.d.ts +2 -29627
- package/dist/_dts/blocks/src/system/blocks/collection.d.ts +2 -29585
- package/dist/_dts/blocks/src/system/blocks/events/shared/index.d.ts +1 -0
- package/dist/_dts/blocks/src/system/blocks/events/shared/layout.d.ts +2 -0
- package/dist/_dts/blocks/src/system/blocks/faq.d.ts +2 -29677
- package/dist/_dts/blocks/src/system/blocks/gifting.d.ts +2 -29655
- package/dist/_dts/blocks/src/system/blocks/index.d.ts +1 -0
- package/dist/_dts/blocks/src/system/blocks/media-text.d.ts +220 -0
- package/dist/_dts/blocks/src/system/blocks/product-detail.d.ts +2 -29655
- package/dist/_dts/blocks/src/system/blocks/product-list.d.ts +2 -29685
- package/dist/_dts/blocks/src/system/blocks/shop.d.ts +2 -29761
- package/dist/_dts/blocks/src/system/blocks/weekly-slot-availability.d.ts +34 -0
- package/dist/_dts/blocks/src/system/componentFactory.d.ts +1 -0
- package/dist/_dts/blocks/src/system/constants/blockKinds.d.ts +1 -1
- package/dist/_dts/blocks/src/system/customize/facets.d.ts +2 -2
- package/dist/_dts/blocks/src/system/data/loaderEndpoints.d.ts +1 -1
- package/dist/_dts/blocks/src/system/data/prefetchBlockData.d.ts +4 -1
- package/dist/_dts/blocks/src/system/fragments/library/heroCopy.d.ts +9 -0
- package/dist/_dts/blocks/src/system/inlineText.d.ts +78 -0
- package/dist/_dts/blocks/src/system/manifest/derivedContent.d.ts +3 -1
- package/dist/_dts/blocks/src/system/manifest/fieldValidation/index.d.ts +15 -3
- package/dist/_dts/blocks/src/system/manifest/schema.d.ts +188 -7
- package/dist/_dts/blocks/src/system/node/builder.d.ts +2 -0
- package/dist/_dts/blocks/src/system/node/schema.d.ts +13 -0
- package/dist/_dts/blocks/src/system/node/validation-constants.d.ts +1 -1
- package/dist/_dts/blocks/src/system/registry.d.ts +1 -0
- package/dist/_dts/blocks/src/system/runtime/api/client.d.ts +2 -1
- package/dist/_dts/blocks/src/system/runtime/api/endpoints.d.ts +8 -0
- package/dist/_dts/blocks/src/system/runtime/api/types.d.ts +24 -0
- package/dist/_dts/blocks/src/system/runtime/components/registry.client.d.ts +6 -0
- package/dist/_dts/blocks/src/system/runtime/hooks/useAppointmentCheckoutVerification.d.ts +7 -0
- package/dist/_dts/blocks/src/system/runtime/hooks/useAvailableSlots.d.ts +2 -2
- package/dist/_dts/blocks/src/system/runtime/hooks/useHeadlessEventRegistrationFlow.d.ts +4 -0
- package/dist/_dts/blocks/src/system/runtime/hooks/usePaymentVerification.d.ts +5 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/basic.d.ts +2 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/hooks.d.ts +14 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/useEventRegistrationSubmit.d.ts +8 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/useEventRegistrationWizard.d.ts +133 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/renderInlineText.d.ts +3 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/weekly-slot-availability.client.controller.d.ts +3 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/weekly-slot-availability.client.d.ts +9 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/weekly-slot-availability.client.state.d.ts +14 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/weekly-slot-availability.server.d.ts +10 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/weekly-slot-availability.view.d.ts +11 -0
- package/dist/_dts/blocks/src/system/runtime/resolver.d.ts +31 -1
- package/dist/_dts/blocks/src/system/runtime/shared/useWaitlistClaim.d.ts +5 -0
- package/dist/_dts/blocks/src/utils/date-formatting.d.ts +1 -1
- package/dist/_dts/content-editor/src/index.d.ts +1 -0
- package/dist/_dts/content-editor/src/primitives/PreviewInlineTextEditor.d.ts +9 -0
- package/dist/_dts/content-editor/src/primitives/PreviewRichTextEditor.d.ts +1 -1
- package/dist/_dts/content-model/src/templates/bindingTypeCompatibility.d.ts +1 -1
- package/dist/_dts/content-model/src/templates/defaults.d.ts +30 -0
- package/dist/_dts/content-model/src/templates/types.d.ts +3 -6
- package/dist/_dts/core/src/branded.d.ts +8 -0
- package/dist/_dts/db/src/generated/supabase/database.types.d.ts +505 -2
- package/dist/_dts/editor/src/inline/FloatingToolbar.d.ts +18 -0
- package/dist/_dts/editor/src/inline/InlineTextEditor.d.ts +18 -1
- package/dist/_dts/editor/src/inline/InlineTextEditorStyles.d.ts +1 -0
- package/dist/_dts/editor/src/inline/domParse.d.ts +3 -0
- package/dist/_dts/editor/src/inline/presentation.d.ts +48 -0
- package/dist/_dts/editor/src/inline/selection.d.ts +12 -0
- package/dist/_dts/editor-blocks/src/widgets/index.d.ts +1 -0
- package/dist/_dts/editor-blocks/src/widgets/inline-text/InlineTextField.d.ts +3 -0
- package/dist/_dts/editor-blocks/src/widgets/inline-text/index.d.ts +1 -0
- package/dist/_dts/field-primitives/src/bindings/index.d.ts +8 -0
- package/dist/_dts/path-utils/src/index.d.ts +1 -0
- package/dist/_dts/preview-next/src/client/widgets/widgetOverrides.d.ts +1 -0
- package/dist/_dts/sdk/src/cli/commands/content.d.ts +56 -0
- package/dist/_dts/sdk/src/cli/commands/push/options.d.ts +4 -0
- package/dist/_dts/sdk/src/cli/commands/push/publishGuidance.d.ts +15 -0
- package/dist/_dts/sdk/src/cli/commands/push/scopes/commandBackedDatedOfferingScope.d.ts +4 -7
- package/dist/_dts/sdk/src/cli/commands/push/scopes/types.d.ts +5 -1
- package/dist/_dts/sdk/src/cli/commands/push/stale-resolution.d.ts +9 -3
- package/dist/_dts/sdk/src/cli/commands/push/verification.d.ts +56 -0
- package/dist/_dts/sdk/src/cli/commands/push/workflowPlan.d.ts +34 -0
- package/dist/_dts/sdk/src/cli/commands/push-execute.d.ts +2 -1
- package/dist/_dts/sdk/src/cli/commands/setup.d.ts +2 -0
- package/dist/_dts/sdk/src/cli/config-loader.d.ts +2 -0
- package/dist/_dts/sdk/src/cli/content/edit/format.d.ts +2 -0
- package/dist/_dts/sdk/src/cli/content/edit/path.d.ts +14 -0
- package/dist/_dts/sdk/src/cli/content/edit/planner.d.ts +46 -0
- package/dist/_dts/sdk/src/cli/content/fs-utils.d.ts +4 -0
- package/dist/_dts/sdk/src/cli/content/metadataStore.d.ts +29 -0
- package/dist/_dts/sdk/src/cli/content/reader.d.ts +16 -14
- package/dist/_dts/sdk/src/cli/content/writer.d.ts +8 -4
- package/dist/_dts/sdk/src/cli/env-scope.d.ts +2 -0
- package/dist/_dts/sdk/src/cli/helpers.d.ts +6 -7
- package/dist/_dts/sdk/src/cli/merge-remote/entryMergePush.d.ts +2 -0
- package/dist/_dts/sdk/src/cli/merge-remote/mergeFieldChanges.d.ts +22 -0
- package/dist/_dts/sdk/src/cli/merge-remote/pageLocal.d.ts +3 -0
- package/dist/_dts/sdk/src/cli/merge-remote/pageMerge.d.ts +78 -0
- package/dist/_dts/sdk/src/cli/merge-remote/pageMergePlan.d.ts +36 -0
- package/dist/_dts/sdk/src/cli/merge-remote/pageMergePush.d.ts +23 -0
- package/dist/_dts/sdk/src/cli/merge-remote/pageMergeReport.d.ts +29 -0
- package/dist/_dts/sdk/src/cli/merge-remote/pageSnapshots.d.ts +48 -0
- package/dist/_dts/sdk/src/cli/push-config.d.ts +13 -2
- package/dist/_dts/sdk/src/cli/setup/setupPlan.d.ts +51 -0
- package/dist/_dts/sdk/src/cli/site-commands/commandRuntime.d.ts +21 -0
- package/dist/_dts/sdk/src/cli/sync/diff.d.ts +3 -6
- package/dist/_dts/sdk/src/cli/sync/field-diff.d.ts +39 -0
- package/dist/_dts/sdk/src/cli/sync/index.d.ts +1 -0
- package/dist/_dts/sdk/src/client/runtimeCachePolicy.d.ts +1 -1
- package/dist/_dts/sdk/src/client/types.d.ts +18 -2
- package/dist/_dts/sdk/src/config/field-definitions.d.ts +8 -3
- package/dist/_dts/sdk/src/config/typed-entries.d.ts +5 -3
- package/dist/_dts/sdk/src/config/types.d.ts +1 -1
- package/dist/_dts/sdk/src/config/validation.d.ts +3 -0
- package/dist/_dts/sdk/src/contracts/bindings.d.ts +4 -7
- package/dist/_dts/sdk/src/contracts/content.d.ts +18 -0
- package/dist/_dts/sdk/src/contracts/index.d.ts +1 -1
- package/dist/_dts/sdk/src/contracts/system-block-content.d.ts +16 -2
- package/dist/_dts/sdk/src/next/route-outcome-proxy.d.ts +3 -3
- package/dist/_dts/sdk/src/public-api/contracts.d.ts +174 -78
- package/dist/_dts/sdk/src/public-api/runtime.d.ts +1 -1
- package/dist/_dts/sdk/src/rendering/helpers/bindings.d.ts +4 -3
- package/dist/_dts/sdk/src/rendering/helpers/loadContent.d.ts +52 -1
- package/dist/_dts/sdk/src/rendering/hooks/usePage.d.ts +2 -2
- package/dist/_dts/sdk/src/rendering/islands/types.d.ts +18 -66
- package/dist/_dts/sdk/src/types/block-kinds.d.ts +1 -1
- package/dist/_dts/sdk/src/version.d.ts +1 -1
- package/dist/_dts/theme-core/src/accordions/types.d.ts +1 -1
- package/dist/_dts/theme-core/src/buttons/types.d.ts +1 -1
- package/dist/_dts/theme-core/src/cards/types.d.ts +15 -15
- package/dist/_dts/theme-core/src/generated/containerResponsiveThemeCss.d.ts +1 -1
- package/dist/_dts/theme-core/src/inputs/types.d.ts +1 -1
- package/dist/_dts/theme-core/src/mock-themes/all.d.ts +42 -42
- package/dist/_dts/theme-core/src/palette/variants/types.d.ts +2 -2
- package/dist/_dts/theme-core/src/schema.d.ts +44 -44
- package/dist/_dts/theme-core/src/site-styles/backgroundAppearance.d.ts +2 -2
- package/dist/_dts/theme-core/src/site-styles/designState.d.ts +16 -16
- package/dist/_dts/theme-core/src/site-styles/pageDesignIntent.d.ts +4 -4
- package/dist/_dts/theme-core/src/site-styles/tokenRecipes.d.ts +1 -1
- package/dist/_dts/theme-core/src/tokens/themeColorTokens.d.ts +1 -1
- package/dist/{chunk-4A6NWO3X.mjs → chunk-6WDBXCPX.mjs} +73 -12
- package/dist/{chunk-VZBSD4AJ.mjs → chunk-DBRI3PQF.mjs} +2281 -322
- package/dist/{chunk-PJPFTVZG.mjs → chunk-H24OU7WG.mjs} +106 -4
- package/dist/{chunk-K2SJTZMX.mjs → chunk-PKDPQHB5.mjs} +2 -2
- package/dist/{chunk-VTPPVAOL.mjs → chunk-QPXE2OUZ.mjs} +1 -1
- package/dist/{chunk-7ED5UNHL.mjs → chunk-V2BYFSPW.mjs} +109 -0
- package/dist/cli/index.mjs +4182 -1165
- package/dist/cli/init-docs/content/cli-reference.md +72 -5
- package/dist/cli/init-docs/content/content-management.md +22 -0
- package/dist/cli/init-docs/content/getting-started.md +8 -0
- package/dist/cli/init-docs/content/workflow-agent-safe-sync.md +3 -1
- package/dist/cli/init-docs/content/workflow-preview-mode.md +6 -0
- package/dist/cli/init-docs/content/workflow-remote-setup.md +51 -0
- package/dist/client/{accordion-LGO4IO5U.mjs → accordion-Q2BDNL53.mjs} +1 -1
- package/dist/client/{bookingForm-MWLS4LGU.mjs → bookingForm-ZMP4P7EK.mjs} +16 -6
- package/dist/client/bookings.mjs +98 -18
- package/dist/client/{carousel-6AHNP5HA.mjs → carousel-LW3UXPWO.mjs} +1 -1
- package/dist/client/{cart-CIXGYAZB.mjs → cart-Z6D3KS6K.mjs} +5 -5
- package/dist/client/{checkout-OTX6O3DN.mjs → checkout-YMT2QJQM.mjs} +5 -5
- package/dist/client/{chunk-Y2PMKCXO.mjs → chunk-26ZBRXFR.mjs} +9 -3
- package/dist/client/{chunk-MYCXAKWP.mjs → chunk-DRRQ7QSL.mjs} +2 -2
- package/dist/client/{chunk-TREIML53.mjs → chunk-ET2MDQQT.mjs} +4 -4
- package/dist/client/{chunk-AVBQSUIS.mjs → chunk-HBQEAOG4.mjs} +1 -1
- package/dist/client/{chunk-INRIT6DP.mjs → chunk-IEOECM7U.mjs} +62 -43
- package/dist/client/{chunk-TNGL2WJF.mjs → chunk-KDP7ZRZV.mjs} +16 -0
- package/dist/client/{chunk-V67AT7ZW.mjs → chunk-R4XK3CKR.mjs} +18 -1
- package/dist/client/{chunk-R3NQTBWE.mjs → chunk-SK2BMD22.mjs} +2 -2
- package/dist/client/{chunk-HOP7MKAZ.mjs → chunk-XNTHVZ25.mjs} +1 -1
- package/dist/client/client.mjs +5172 -4177
- package/dist/client/{courseRegistration-2LU6C3JL.mjs → courseRegistration-DGKCMC77.mjs} +4 -4
- package/dist/client/{eventCalendar-OKUSISBZ.mjs → eventCalendar-74Z2NNFM.mjs} +7 -7
- package/dist/client/{eventCombined-CMF6CD4S.mjs → eventCombined-GK2ODOX2.mjs} +7 -7
- package/dist/client/{eventDetails-XYWH7WXI.mjs → eventDetails-MONAGT3N.mjs} +7 -7
- package/dist/client/{eventListing-EK5DJTAH.mjs → eventListing-SKGAO6PS.mjs} +7 -7
- package/dist/client/{eventRegistration-XDOSICV6.mjs → eventRegistration-6KISGXRD.mjs} +7 -7
- package/dist/client/{form-J6GOHKYG.mjs → form-FXPRTXHI.mjs} +2 -2
- package/dist/client/{headerSection-C5SYJTRW.mjs → headerSection-7NAN5WNB.mjs} +2 -2
- package/dist/client/hooks.mjs +1681 -1337
- package/dist/client/{locationMap-QSQIFVVT.mjs → locationMap-UERN74U4.mjs} +2 -2
- package/dist/client/{newsletterForm-47VXJRWK.mjs → newsletterForm-SGWXMJ7U.mjs} +2 -2
- package/dist/client/{productDetail-5U6ISCC2.mjs → productDetail-HN3HWZQZ.mjs} +5 -5
- package/dist/client/{productList-XDZUMR3P.mjs → productList-YT22Z5UR.mjs} +5 -5
- package/dist/client/rendering/client.mjs +4796 -4288
- package/dist/client/rendering/islands.mjs +18 -18
- package/dist/client/rendering.mjs +2120 -1106
- package/dist/client/{shop-ZSZKIY3R.mjs → shop-TKEDNWUS.mjs} +5 -5
- package/dist/preview-next/before-render.mjs +109 -0
- package/dist/preview-next/client/runtime.mjs +5 -5
- package/dist/preview-next/middleware.mjs +109 -0
- package/dist/{sdk-runtime-PHNM7MRD.mjs → sdk-runtime-LWNYCQF2.mjs} +6 -6
- package/dist/server/components.mjs +3777 -2981
- package/dist/server/config-template-validation.mjs +35 -22
- package/dist/server/config-validation.mjs +1883 -1565
- package/dist/server/config.mjs +1883 -1565
- package/dist/server/data.mjs +1667 -1334
- package/dist/server/index.mjs +208 -9
- package/dist/server/next/middleware.mjs +2 -2
- package/dist/server/next.mjs +4077 -3060
- package/dist/server/page-converter.mjs +1481 -1279
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/rendering/server.mjs +3806 -2993
- package/dist/server/rendering.mjs +4000 -3060
- package/dist/server/routing.mjs +1737 -1357
- package/dist/server/server.mjs +2918 -2276
- package/dist/server/theme-bridge.mjs +43 -0
- package/dist/styles/index.css +44 -0
- package/package.json +1 -1
- package/dist/SdkPreviewModeRuntime-PBEFH5AL.mjs +0 -8
|
@@ -52,6 +52,10 @@ export declare const BOOKINGS: {
|
|
|
52
52
|
path: string;
|
|
53
53
|
method: "GET";
|
|
54
54
|
};
|
|
55
|
+
getWeeklySlotAvailability: {
|
|
56
|
+
path: string;
|
|
57
|
+
method: "GET";
|
|
58
|
+
};
|
|
55
59
|
getAvailableDates: {
|
|
56
60
|
path: string;
|
|
57
61
|
method: "GET";
|
|
@@ -394,6 +398,10 @@ export declare const ENDPOINTS: {
|
|
|
394
398
|
path: string;
|
|
395
399
|
method: "GET";
|
|
396
400
|
};
|
|
401
|
+
getWeeklySlotAvailability: {
|
|
402
|
+
path: string;
|
|
403
|
+
method: "GET";
|
|
404
|
+
};
|
|
397
405
|
getAvailableDates: {
|
|
398
406
|
path: string;
|
|
399
407
|
method: "GET";
|
|
@@ -192,6 +192,30 @@ export interface TimeSlot {
|
|
|
192
192
|
export interface AvailableSlotsResponse {
|
|
193
193
|
slots: TimeSlot[];
|
|
194
194
|
}
|
|
195
|
+
export interface WeeklySlotAvailabilityRequest {
|
|
196
|
+
siteId: string;
|
|
197
|
+
serviceId: string;
|
|
198
|
+
resourceId?: string;
|
|
199
|
+
horizonWeeks?: number;
|
|
200
|
+
timezone: string;
|
|
201
|
+
}
|
|
202
|
+
export interface WeeklySlotAvailabilityOption {
|
|
203
|
+
id: string;
|
|
204
|
+
resourceId: string;
|
|
205
|
+
weekday: number;
|
|
206
|
+
weekdayLabel: string;
|
|
207
|
+
startTime: string;
|
|
208
|
+
endTime: string;
|
|
209
|
+
nextDate: string;
|
|
210
|
+
availableWeeks: number;
|
|
211
|
+
}
|
|
212
|
+
export interface WeeklySlotAvailabilityResponse {
|
|
213
|
+
slots: WeeklySlotAvailabilityOption[];
|
|
214
|
+
horizonWeeks: number;
|
|
215
|
+
timezone: string;
|
|
216
|
+
startDate: string;
|
|
217
|
+
endDate: string;
|
|
218
|
+
}
|
|
195
219
|
export interface AvailableDatesRequest {
|
|
196
220
|
siteId: string;
|
|
197
221
|
serviceId: string;
|
|
@@ -8,6 +8,7 @@ import { AccordionNode, AccordionItemNode } from '../nodes/accordion';
|
|
|
8
8
|
import HeaderSectionNode from '../nodes/header-section.client';
|
|
9
9
|
import { EventCombinedIslandClient } from '../nodes/events';
|
|
10
10
|
import { MediaNode } from '../nodes/media.client';
|
|
11
|
+
import WeeklySlotAvailabilityClient from '../nodes/weekly-slot-availability.client';
|
|
11
12
|
import { runtimeBackedBlockServerEntries, type RuntimeBackedBlockMode, type RuntimeBackedBlockKind, type RuntimeBackedClientBlockEntry, type RuntimeBackedClientComponentProps } from './runtime-backed-blocks';
|
|
12
13
|
type SourcePropsClientEntry<TProps extends object = object> = Readonly<{
|
|
13
14
|
kind: 'source-props';
|
|
@@ -28,6 +29,7 @@ export type ClientComponentRegistryEntryByKind = Readonly<{
|
|
|
28
29
|
'event-details': ExplicitAdapterClientEntry<React.ComponentProps<typeof EventDetailsIslandClient>>;
|
|
29
30
|
'location-map': ExplicitAdapterClientEntry<React.ComponentProps<typeof LocationMapIslandClient>>;
|
|
30
31
|
'event-combined': ExplicitAdapterClientEntry<React.ComponentProps<typeof EventCombinedIslandClient>>;
|
|
32
|
+
'weekly-slot-availability': SourcePropsClientEntry<React.ComponentProps<typeof WeeklySlotAvailabilityClient>>;
|
|
31
33
|
}>;
|
|
32
34
|
export type ClientComponentRegistryEntry = ClientComponentRegistryEntryByKind[keyof ClientComponentRegistryEntryByKind];
|
|
33
35
|
export declare function defineSourcePropsClientEntry<TProps extends object>(component: React.ComponentType<TProps>): SourcePropsClientEntry<TProps>;
|
|
@@ -2992,6 +2994,10 @@ export declare const clientComponentRegistryEntries: {
|
|
|
2992
2994
|
}>>;
|
|
2993
2995
|
produces: "client-props" | "island-props";
|
|
2994
2996
|
}>;
|
|
2997
|
+
readonly 'weekly-slot-availability': Readonly<{
|
|
2998
|
+
kind: "source-props";
|
|
2999
|
+
component: React.ComponentType<import("../nodes/weekly-slot-availability.client").WeeklySlotAvailabilityClientProps>;
|
|
3000
|
+
}>;
|
|
2995
3001
|
};
|
|
2996
3002
|
export declare const clientComponentRegistry: ComponentRegistry;
|
|
2997
3003
|
export {};
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
+
import { useBlockApi } from "../api";
|
|
1
2
|
import { type AppointmentCheckoutVerificationState } from "../nodes/booking-form.state";
|
|
3
|
+
import { usePolling } from "./usePolling";
|
|
2
4
|
export type AppointmentCheckoutVerificationConfig = {
|
|
3
5
|
sessionId: string;
|
|
4
6
|
maxAttempts?: number;
|
|
@@ -8,4 +10,9 @@ export type AppointmentCheckoutVerificationResult = {
|
|
|
8
10
|
state: AppointmentCheckoutVerificationState;
|
|
9
11
|
retry: () => void;
|
|
10
12
|
};
|
|
13
|
+
export type AppointmentCheckoutVerificationDeps = Readonly<{
|
|
14
|
+
useBlockApi: typeof useBlockApi;
|
|
15
|
+
usePolling: typeof usePolling;
|
|
16
|
+
}>;
|
|
11
17
|
export declare function useAppointmentCheckoutVerification(config: AppointmentCheckoutVerificationConfig | null): AppointmentCheckoutVerificationResult;
|
|
18
|
+
export declare function useAppointmentCheckoutVerificationWithDeps(config: AppointmentCheckoutVerificationConfig | null, deps: AppointmentCheckoutVerificationDeps): AppointmentCheckoutVerificationResult;
|
|
@@ -6,14 +6,14 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { type TimeSlot } from "../api";
|
|
8
8
|
export type { TimeSlot };
|
|
9
|
-
type UseAvailableSlotsOptions = {
|
|
9
|
+
export type UseAvailableSlotsOptions = {
|
|
10
10
|
siteId: string;
|
|
11
11
|
serviceId: string | undefined;
|
|
12
12
|
resourceId: string | undefined;
|
|
13
13
|
selectedDate: string;
|
|
14
14
|
timezone: string;
|
|
15
15
|
};
|
|
16
|
-
type UseAvailableSlotsResult = {
|
|
16
|
+
export type UseAvailableSlotsResult = {
|
|
17
17
|
slots: TimeSlot[];
|
|
18
18
|
isLoading: boolean;
|
|
19
19
|
isRefreshing: boolean;
|
|
@@ -27,7 +27,11 @@ export type EventRegistrationController = Readonly<{
|
|
|
27
27
|
export type EventRegistrationWizardController = Readonly<{
|
|
28
28
|
wizard: ReturnType<typeof useEventRegistrationWizard>;
|
|
29
29
|
}>;
|
|
30
|
+
export type EventRegistrationControllerDeps = Readonly<{
|
|
31
|
+
useEventRegistrationWizard: typeof useEventRegistrationWizard;
|
|
32
|
+
}>;
|
|
30
33
|
export declare function HeadlessEventRegistrationProvider({ config, children, }: HeadlessEventRegistrationProviderProps): React.ReactElement;
|
|
31
34
|
export declare function useHeadlessEventRegistrationFlow(options: HeadlessEventRegistrationFlowOptions): HeadlessEventRegistrationFlow;
|
|
32
35
|
export declare function useEventRegistrationController(options: HeadlessEventRegistrationFlowOptions): EventRegistrationController;
|
|
36
|
+
export declare function useEventRegistrationControllerWithDeps(options: HeadlessEventRegistrationFlowOptions, deps: EventRegistrationControllerDeps): EventRegistrationController;
|
|
33
37
|
export declare function useEventRegistrationWizardController(options: HeadlessEventRegistrationFlowOptions): EventRegistrationWizardController;
|
|
@@ -23,6 +23,7 @@
|
|
|
23
23
|
* }, [verification.status]);
|
|
24
24
|
* ```
|
|
25
25
|
*/
|
|
26
|
+
import { useBlockApi } from '../api';
|
|
26
27
|
import type { PaymentStatus, AttendeeStatus } from '../api/types';
|
|
27
28
|
export type PaymentVerificationConfig = {
|
|
28
29
|
/** Unique ID to check (attendeeId, customerPassId, etc.) */
|
|
@@ -46,6 +47,9 @@ export type PaymentVerificationResult = {
|
|
|
46
47
|
/** Manually trigger a poll (useful for retry after timeout) */
|
|
47
48
|
retry: () => void;
|
|
48
49
|
};
|
|
50
|
+
export type PaymentVerificationDeps = Readonly<{
|
|
51
|
+
useBlockApi: typeof useBlockApi;
|
|
52
|
+
}>;
|
|
49
53
|
/**
|
|
50
54
|
* Hook for polling payment status after Stripe redirects.
|
|
51
55
|
*
|
|
@@ -56,3 +60,4 @@ export type PaymentVerificationResult = {
|
|
|
56
60
|
* @returns Verification result with status, data, and retry function
|
|
57
61
|
*/
|
|
58
62
|
export declare function usePaymentVerification(config: PaymentVerificationConfig | null): PaymentVerificationResult;
|
|
63
|
+
export declare function usePaymentVerificationWithDeps(config: PaymentVerificationConfig | null, deps: PaymentVerificationDeps): PaymentVerificationResult;
|
|
@@ -2,11 +2,12 @@ import React from 'react';
|
|
|
2
2
|
import { type ButtonSizeName } from '../../../../../theme-core/src/buttons/index';
|
|
3
3
|
import type { PreviewLinkedEntryFieldBinding } from '../../data';
|
|
4
4
|
export type TextNodeProps = {
|
|
5
|
-
value?:
|
|
5
|
+
value?: unknown;
|
|
6
6
|
className?: string;
|
|
7
7
|
path?: string;
|
|
8
8
|
linkedEntryField?: PreviewLinkedEntryFieldBinding;
|
|
9
9
|
maxLength?: number;
|
|
10
|
+
inlineTextFallbackPath?: string;
|
|
10
11
|
children?: React.ReactNode;
|
|
11
12
|
};
|
|
12
13
|
export declare const TextNode: React.FC<TextNodeProps & {
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
* Custom hooks for portal authentication and eligibility checking.
|
|
5
5
|
* Extracted from the main EventRegistrationClient for better separation of concerns.
|
|
6
6
|
*/
|
|
7
|
+
import { useBlockApi } from '../../api';
|
|
7
8
|
import type { EventTicketSelectionLine } from './types';
|
|
8
9
|
import { type EligibilityLookupState, type ExistingRegistrationLookupState } from './hooks.state';
|
|
9
10
|
export type PortalAuthState = 'checking' | 'authenticated' | 'unauthenticated';
|
|
@@ -24,6 +25,9 @@ export type UsePortalAuthResult = {
|
|
|
24
25
|
/** Logout function */
|
|
25
26
|
logout: () => void;
|
|
26
27
|
};
|
|
28
|
+
export type EventRegistrationHooksDeps = Readonly<{
|
|
29
|
+
useBlockApi: typeof useBlockApi;
|
|
30
|
+
}>;
|
|
27
31
|
/**
|
|
28
32
|
* Hook for managing portal authentication state.
|
|
29
33
|
*
|
|
@@ -31,6 +35,7 @@ export type UsePortalAuthResult = {
|
|
|
31
35
|
* fetches the portal profile if so.
|
|
32
36
|
*/
|
|
33
37
|
export declare function usePortalAuth(): UsePortalAuthResult;
|
|
38
|
+
export declare function usePortalAuthWithDeps(deps: EventRegistrationHooksDeps): UsePortalAuthResult;
|
|
34
39
|
export type UseEligibilityResult = {
|
|
35
40
|
state: EligibilityLookupState;
|
|
36
41
|
eligibility: EligibilityLookupState['eligibility'];
|
|
@@ -45,6 +50,14 @@ export declare function useEligibility(params: {
|
|
|
45
50
|
selectedSlidingAmount?: number | null;
|
|
46
51
|
email: string;
|
|
47
52
|
}): UseEligibilityResult;
|
|
53
|
+
export declare function useEligibilityWithDeps(params: {
|
|
54
|
+
enabled: boolean;
|
|
55
|
+
occurrenceId: string;
|
|
56
|
+
attendanceMode?: 'in_person' | 'online' | null;
|
|
57
|
+
ticketSelections: readonly EventTicketSelectionLine[];
|
|
58
|
+
selectedSlidingAmount?: number | null;
|
|
59
|
+
email: string;
|
|
60
|
+
}, deps: EventRegistrationHooksDeps): UseEligibilityResult;
|
|
48
61
|
export type UseExistingEventRegistrationResult = {
|
|
49
62
|
state: ExistingRegistrationLookupState;
|
|
50
63
|
registration: ExistingRegistrationLookupState['registration'];
|
|
@@ -55,4 +68,5 @@ type UseExistingEventRegistrationParams = {
|
|
|
55
68
|
occurrenceId: string;
|
|
56
69
|
};
|
|
57
70
|
export declare function useExistingEventRegistration({ isAuthenticated, occurrenceId, }: UseExistingEventRegistrationParams): UseExistingEventRegistrationResult;
|
|
71
|
+
export declare function useExistingEventRegistrationWithDeps({ isAuthenticated, occurrenceId, }: UseExistingEventRegistrationParams, deps: EventRegistrationHooksDeps): UseExistingEventRegistrationResult;
|
|
58
72
|
export {};
|
package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/useEventRegistrationSubmit.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { BlockApiClient } from '../../api';
|
|
2
|
+
import { savePendingRegistration } from './sessionStorage';
|
|
2
3
|
import type { EventTicketSelectionLine, FormData, Guest, RegistrationResult, RegistrationStep, PaymentSelection } from './types';
|
|
3
4
|
import type { PaymentMethod } from '../../api/types';
|
|
4
5
|
import type { RegistrationTarget } from './registrationDerivations';
|
|
@@ -21,7 +22,7 @@ export type EventRegistrationSubmitResult = Readonly<{
|
|
|
21
22
|
reason: 'blocked' | 'missing-target' | 'submission-failed';
|
|
22
23
|
message: string;
|
|
23
24
|
}>;
|
|
24
|
-
export
|
|
25
|
+
export type UseEventRegistrationSubmitInput = {
|
|
25
26
|
api: BlockApiClient;
|
|
26
27
|
registrationTarget: RegistrationTarget | null;
|
|
27
28
|
selectedAttendanceMode: 'in_person' | 'online' | null;
|
|
@@ -37,4 +38,9 @@ export declare function useEventRegistrationSubmit(options: {
|
|
|
37
38
|
setStep: (step: RegistrationStep) => void;
|
|
38
39
|
setRegistrationResult: (result: RegistrationResult) => void;
|
|
39
40
|
setErrorMessage: (message: string) => void;
|
|
40
|
-
}
|
|
41
|
+
};
|
|
42
|
+
export type EventRegistrationSubmitDeps = Readonly<{
|
|
43
|
+
savePendingRegistration: typeof savePendingRegistration;
|
|
44
|
+
}>;
|
|
45
|
+
export declare function useEventRegistrationSubmit(options: UseEventRegistrationSubmitInput): (method: PaymentMethod, passId?: string, membershipId?: string, selection?: PaymentSelection, submitOptions?: EventRegistrationSubmitOptions) => Promise<EventRegistrationSubmitResult>;
|
|
46
|
+
export declare function useEventRegistrationSubmitWithDeps(options: UseEventRegistrationSubmitInput, deps: EventRegistrationSubmitDeps): (method: PaymentMethod, passId?: string, membershipId?: string, selection?: PaymentSelection, submitOptions?: EventRegistrationSubmitOptions) => Promise<EventRegistrationSubmitResult>;
|
package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/useEventRegistrationWizard.d.ts
CHANGED
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
import type { DiscountContext } from '../../api/types';
|
|
2
2
|
import type { EventTicketSelectionLine, EventRegistrationClientProps, FormData, Guest, GuestErrors, PaymentSelection, PaymentStepState, PublicEvent, RegistrationEvent, RegistrationResult, RegistrationStep } from './types';
|
|
3
|
+
import { usePortalAuth, useEligibility, useExistingEventRegistration } from './hooks';
|
|
4
|
+
import { useWaitlistClaim } from '../../shared/useWaitlistClaim';
|
|
5
|
+
import { useEventRegistrationStripeReturn } from './useEventRegistrationStripeReturn';
|
|
6
|
+
import { useEventRegistrationSubmit } from './useEventRegistrationSubmit';
|
|
7
|
+
import { useDiscountCodeUi } from './useDiscountCodeUi';
|
|
3
8
|
export type EventRegistrationDetailsCompleteResult = Readonly<{
|
|
4
9
|
ok: true;
|
|
5
10
|
outcome: 'payment-step' | 'submitted';
|
|
@@ -8,13 +13,139 @@ export type EventRegistrationDetailsCompleteResult = Readonly<{
|
|
|
8
13
|
reason: 'blocked' | 'validation-failed' | 'submission-failed';
|
|
9
14
|
message: string;
|
|
10
15
|
}>;
|
|
11
|
-
export
|
|
16
|
+
export type UseEventRegistrationWizardOptions = Readonly<{
|
|
12
17
|
anchorId: string;
|
|
13
18
|
occurrenceContext: EventRegistrationClientProps['occurrenceContext'];
|
|
14
19
|
contentEntry: EventRegistrationClientProps['contentEntry'];
|
|
15
20
|
events: PublicEvent[];
|
|
16
21
|
maxTicketsNum: number;
|
|
17
|
-
}
|
|
22
|
+
}>;
|
|
23
|
+
export type EventRegistrationWizardDeps = Readonly<{
|
|
24
|
+
usePortalAuth: typeof usePortalAuth;
|
|
25
|
+
useEligibility: typeof useEligibility;
|
|
26
|
+
useExistingEventRegistration: typeof useExistingEventRegistration;
|
|
27
|
+
useWaitlistClaim: typeof useWaitlistClaim;
|
|
28
|
+
useEventRegistrationStripeReturn: typeof useEventRegistrationStripeReturn;
|
|
29
|
+
useEventRegistrationSubmit: typeof useEventRegistrationSubmit;
|
|
30
|
+
useDiscountCodeUi: typeof useDiscountCodeUi;
|
|
31
|
+
}>;
|
|
32
|
+
export declare function useEventRegistrationWizard(options: UseEventRegistrationWizardOptions): {
|
|
33
|
+
api: import("../../api").BlockApiClient;
|
|
34
|
+
anchorId: string;
|
|
35
|
+
occurrenceContext: {
|
|
36
|
+
id: string;
|
|
37
|
+
seriesId: string;
|
|
38
|
+
startsAt: string;
|
|
39
|
+
endsAt: string;
|
|
40
|
+
timeZone: string;
|
|
41
|
+
capacityOverride?: number | null | undefined;
|
|
42
|
+
overrides?: Record<string, unknown> | null | undefined;
|
|
43
|
+
} | null | undefined;
|
|
44
|
+
registrationTarget: Readonly<{
|
|
45
|
+
occurrenceId: string;
|
|
46
|
+
selectedEventId: string | null;
|
|
47
|
+
}> | null;
|
|
48
|
+
contentEntry: {
|
|
49
|
+
id: string;
|
|
50
|
+
slug: string;
|
|
51
|
+
contentTypeSlug: string;
|
|
52
|
+
} | null | undefined;
|
|
53
|
+
events: PublicEvent[];
|
|
54
|
+
maxTicketsNum: number;
|
|
55
|
+
scopedEvents: RegistrationEvent[];
|
|
56
|
+
preSelectedEvent: RegistrationEvent | null;
|
|
57
|
+
hasPreSelectedContext: boolean;
|
|
58
|
+
step: RegistrationStep;
|
|
59
|
+
setStep: (nextStep: RegistrationStep) => void;
|
|
60
|
+
selectedEvent: RegistrationEvent | null;
|
|
61
|
+
setSelectedEvent: import("react").Dispatch<import("react").SetStateAction<RegistrationEvent | null>>;
|
|
62
|
+
ticketsCount: number;
|
|
63
|
+
setTicketsCount: (nextTicketsCount: number) => void;
|
|
64
|
+
selectedAttendanceMode: "in_person" | "online" | null;
|
|
65
|
+
setSelectedAttendanceMode: import("react").Dispatch<import("react").SetStateAction<"in_person" | "online" | null>>;
|
|
66
|
+
ticketSelections: Readonly<{
|
|
67
|
+
ticketTypeId: string | null;
|
|
68
|
+
quantity: number;
|
|
69
|
+
}>[];
|
|
70
|
+
selectedTicketLines: Readonly<{
|
|
71
|
+
ticketTypeId: string | null;
|
|
72
|
+
quantity: number;
|
|
73
|
+
}>[];
|
|
74
|
+
setSelectedTicketLines: (lines: readonly EventTicketSelectionLine[]) => void;
|
|
75
|
+
selectedSlidingAmountInput: string;
|
|
76
|
+
setSelectedSlidingAmountInput: import("react").Dispatch<import("react").SetStateAction<string>>;
|
|
77
|
+
selectedSlidingAmount: number | null;
|
|
78
|
+
selectedEventSlidingScale: Readonly<{
|
|
79
|
+
minAmount: number;
|
|
80
|
+
maxAmount: number;
|
|
81
|
+
suggestedAmount: number | null;
|
|
82
|
+
}> | null;
|
|
83
|
+
slidingScaleSelectionMessage: string | null;
|
|
84
|
+
selectedTicketType: import("./utils").SelectableEventTicketType | null;
|
|
85
|
+
ticketSelectionSummaryLines: Readonly<{
|
|
86
|
+
ticketTypeId: string | null;
|
|
87
|
+
label: string;
|
|
88
|
+
quantity: number;
|
|
89
|
+
unitPriceCents: number;
|
|
90
|
+
subtotalCents: number;
|
|
91
|
+
}>[];
|
|
92
|
+
ticketSelectionSubtotalCents: number;
|
|
93
|
+
visibleTicketTypes: import("./utils").SelectableEventTicketType[];
|
|
94
|
+
ticketTypeSelectionRequired: boolean;
|
|
95
|
+
hasValidTicketSelection: boolean;
|
|
96
|
+
eventRequiresPayment: boolean;
|
|
97
|
+
formData: FormData;
|
|
98
|
+
setFormData: import("react").Dispatch<import("react").SetStateAction<FormData>>;
|
|
99
|
+
errors: Partial<Record<keyof FormData, string>>;
|
|
100
|
+
guests: Guest[];
|
|
101
|
+
setGuests: import("react").Dispatch<import("react").SetStateAction<Guest[]>>;
|
|
102
|
+
guestErrors: GuestErrors;
|
|
103
|
+
guestSectionShake: boolean;
|
|
104
|
+
handleGuestShakeEnd: () => void;
|
|
105
|
+
registrationResult: RegistrationResult | null;
|
|
106
|
+
errorMessage: string;
|
|
107
|
+
altchaSolution: string | null;
|
|
108
|
+
setAltchaSolution: import("react").Dispatch<import("react").SetStateAction<string | null>>;
|
|
109
|
+
portalAuthState: import("./hooks").PortalAuthState;
|
|
110
|
+
portalProfile: import("./hooks").PortalProfile | null;
|
|
111
|
+
showMagicLinkModal: boolean;
|
|
112
|
+
setShowMagicLinkModal: import("react").Dispatch<import("react").SetStateAction<boolean>>;
|
|
113
|
+
handleLogout: () => void;
|
|
114
|
+
paymentStepState: PaymentStepState;
|
|
115
|
+
handlePaymentStepStateChange: (state: PaymentStepState) => void;
|
|
116
|
+
handlePaymentSelectionChange: (selection: PaymentSelection) => void;
|
|
117
|
+
paymentSelection: PaymentSelection;
|
|
118
|
+
isMembershipFastTrack: boolean;
|
|
119
|
+
waitlistClaim: import("../../shared/useWaitlistClaim").UseWaitlistClaimResult;
|
|
120
|
+
eligibility: import("./types").EligibilityData | null;
|
|
121
|
+
eligibilityLoading: boolean;
|
|
122
|
+
eligibilityError: string | null;
|
|
123
|
+
existingRegistration: import("../../api").CustomerEventRegistration | null;
|
|
124
|
+
existingRegistrationLoading: boolean;
|
|
125
|
+
existingRegistrationState: import("./hooks.state").ExistingRegistrationLookupState;
|
|
126
|
+
hasEligibility: boolean;
|
|
127
|
+
hasMembershipEligibility: boolean;
|
|
128
|
+
requireGuestDetails: boolean;
|
|
129
|
+
discountCode: string;
|
|
130
|
+
setDiscountCode: (code: string) => void;
|
|
131
|
+
discountUiOpen: boolean;
|
|
132
|
+
setDiscountUiOpen: (isOpen: boolean) => void;
|
|
133
|
+
discountsAvailable: boolean;
|
|
134
|
+
manualCodeEntryAllowed: boolean;
|
|
135
|
+
autoAppliedDiscount: import("../../api/types").AutoAppliedDiscountPreview | null;
|
|
136
|
+
discountsAvailableLoading: boolean;
|
|
137
|
+
discountContext: DiscountContext | null;
|
|
138
|
+
shouldShowDiscountToggle: boolean;
|
|
139
|
+
verification: import("../../hooks/usePaymentVerification").PaymentVerificationResult;
|
|
140
|
+
handleDetailsComplete: () => Promise<EventRegistrationDetailsCompleteResult>;
|
|
141
|
+
handlePaymentSelect: () => Promise<void>;
|
|
142
|
+
handleUseCardInsteadOfPass: () => void;
|
|
143
|
+
handleBookForSomeoneElse: () => void;
|
|
144
|
+
handleSubmit: (method: import("./PaymentSelectionStep").PaymentMethod, passId?: string, membershipId?: string, selection?: PaymentSelection, submitOptions?: import("./useEventRegistrationSubmit").EventRegistrationSubmitOptions) => Promise<import("./useEventRegistrationSubmit").EventRegistrationSubmitResult>;
|
|
145
|
+
handleEventSelect: (event: RegistrationEvent) => void;
|
|
146
|
+
handleRetry: () => void;
|
|
147
|
+
};
|
|
148
|
+
export declare function useEventRegistrationWizardWithDeps(options: UseEventRegistrationWizardOptions, deps: EventRegistrationWizardDeps): {
|
|
18
149
|
api: import("../../api").BlockApiClient;
|
|
19
150
|
anchorId: string;
|
|
20
151
|
occurrenceContext: {
|
package/dist/_dts/blocks/src/system/runtime/nodes/weekly-slot-availability.client.controller.d.ts
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import type { BlockApiClient } from "../api";
|
|
2
|
+
import { type WeeklySlotAvailabilityClientInput, type WeeklySlotAvailabilityLoadState } from "./weekly-slot-availability.client.state";
|
|
3
|
+
export declare function useWeeklySlotAvailabilityLoadState(api: BlockApiClient, input: WeeklySlotAvailabilityClientInput): WeeklySlotAvailabilityLoadState;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import type { WeeklySlotAvailabilityClientInput } from "./weekly-slot-availability.client.state";
|
|
3
|
+
export type WeeklySlotAvailabilityClientProps = WeeklySlotAvailabilityClientInput & Readonly<{
|
|
4
|
+
emptyMessage?: string | null;
|
|
5
|
+
ctaText?: string | null;
|
|
6
|
+
ctaUrl?: string | null;
|
|
7
|
+
}>;
|
|
8
|
+
export declare function WeeklySlotAvailabilityClient({ serviceId, resourceId, horizonWeeks, timezone, availability: initialAvailability, emptyMessage, ctaText, ctaUrl, }: WeeklySlotAvailabilityClientProps): React.JSX.Element;
|
|
9
|
+
export default WeeklySlotAvailabilityClient;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { WeeklySlotAvailabilityResponse } from "../api/types";
|
|
2
|
+
export type WeeklySlotAvailabilityClientInput = Readonly<{
|
|
3
|
+
serviceId?: string | null;
|
|
4
|
+
resourceId?: string | null;
|
|
5
|
+
horizonWeeks?: number | string | null;
|
|
6
|
+
timezone?: string | null;
|
|
7
|
+
availability?: WeeklySlotAvailabilityResponse | null;
|
|
8
|
+
}>;
|
|
9
|
+
export type WeeklySlotAvailabilityLoadState = Readonly<{
|
|
10
|
+
availability: WeeklySlotAvailabilityResponse | null;
|
|
11
|
+
loading: boolean;
|
|
12
|
+
error: string | null;
|
|
13
|
+
}>;
|
|
14
|
+
export declare function normalizeWeeklySlotAvailabilityHorizonWeeks(value: WeeklySlotAvailabilityClientInput["horizonWeeks"]): number;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import type { WeeklySlotAvailabilityResponse } from "../api/types";
|
|
3
|
+
export type WeeklySlotAvailabilityNodeProps = Readonly<{
|
|
4
|
+
availability?: WeeklySlotAvailabilityResponse | null;
|
|
5
|
+
emptyMessage?: string | null;
|
|
6
|
+
ctaText?: string | null;
|
|
7
|
+
ctaUrl?: string | null;
|
|
8
|
+
}>;
|
|
9
|
+
export declare function WeeklySlotAvailabilitySSR(props: WeeklySlotAvailabilityNodeProps): React.JSX.Element;
|
|
10
|
+
export default WeeklySlotAvailabilitySSR;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import type { WeeklySlotAvailabilityResponse } from "../api/types";
|
|
3
|
+
export type WeeklySlotAvailabilityViewProps = Readonly<{
|
|
4
|
+
availability?: WeeklySlotAvailabilityResponse | null;
|
|
5
|
+
loading?: boolean;
|
|
6
|
+
error?: string | null;
|
|
7
|
+
emptyMessage?: string | null;
|
|
8
|
+
ctaText?: string | null;
|
|
9
|
+
ctaUrl?: string | null;
|
|
10
|
+
}>;
|
|
11
|
+
export declare function WeeklySlotAvailabilityView({ availability, loading, error, emptyMessage, ctaText, ctaUrl, }: WeeklySlotAvailabilityViewProps): React.JSX.Element;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import type { NodeDefinition } from "../node";
|
|
2
|
+
import type { ConditionalAuthoringPresence, NodeDefinition } from "../node";
|
|
3
3
|
import { bindingSchema } from "../node";
|
|
4
4
|
import { type ThemeTokens } from "../theme";
|
|
5
5
|
import type { TransformRegistry, RouteMap, PageIdentifierMap, EntryIdentifierMap } from "../transforms";
|
|
@@ -10,6 +10,14 @@ export type PreviewTextFieldConstraints = Readonly<{
|
|
|
10
10
|
maxLength?: number;
|
|
11
11
|
}>;
|
|
12
12
|
export type PreviewFieldConstraintsMap = Readonly<Record<string, PreviewTextFieldConstraints | undefined>>;
|
|
13
|
+
export type PreviewAuthoringContext = Readonly<{
|
|
14
|
+
activeField?: PreviewAuthoringActiveField | null;
|
|
15
|
+
}>;
|
|
16
|
+
export type PreviewAuthoringActiveField = Readonly<{
|
|
17
|
+
kind: 'block-field';
|
|
18
|
+
blockId: string;
|
|
19
|
+
fieldPath: string;
|
|
20
|
+
}>;
|
|
13
21
|
export type ResolverContext = {
|
|
14
22
|
viewModel: ViewModel;
|
|
15
23
|
registry: ComponentRegistry;
|
|
@@ -29,6 +37,7 @@ export type ResolverContext = {
|
|
|
29
37
|
fragmentRegistry?: Record<string, unknown>;
|
|
30
38
|
fieldConstraints?: PreviewFieldConstraintsMap;
|
|
31
39
|
imageResolveContext?: ResolveImageUrlContext;
|
|
40
|
+
previewAuthoring?: PreviewAuthoringContext;
|
|
32
41
|
};
|
|
33
42
|
/** @internal Exported for testing */
|
|
34
43
|
export type ScopeEntry = {
|
|
@@ -46,6 +55,26 @@ export type ScopeEntry = {
|
|
|
46
55
|
export type InternalContext = ResolverContext & {
|
|
47
56
|
scopes: ScopeEntry[];
|
|
48
57
|
};
|
|
58
|
+
type ConditionalValuePresence = Readonly<{
|
|
59
|
+
kind: 'present';
|
|
60
|
+
}> | Readonly<{
|
|
61
|
+
kind: 'empty';
|
|
62
|
+
}>;
|
|
63
|
+
export type ConditionalNodeRenderDecision = Readonly<{
|
|
64
|
+
kind: 'render';
|
|
65
|
+
reason: 'condition-passed' | 'authoring-presence';
|
|
66
|
+
}> | Readonly<{
|
|
67
|
+
kind: 'skip';
|
|
68
|
+
reason: 'condition-failed' | 'not-editable' | 'inactive-authoring-context';
|
|
69
|
+
}>;
|
|
70
|
+
export declare function planConditionalNodeRender(input: {
|
|
71
|
+
readonly conditionMatched: boolean;
|
|
72
|
+
readonly conditionPresence: ConditionalValuePresence;
|
|
73
|
+
readonly conditionUsesPresenceSemantics: boolean;
|
|
74
|
+
readonly authoringPresence: ConditionalAuthoringPresence;
|
|
75
|
+
readonly editableTarget: PreviewAuthoringActiveField | null;
|
|
76
|
+
readonly authoringContext: PreviewAuthoringContext | undefined;
|
|
77
|
+
}): ConditionalNodeRenderDecision;
|
|
49
78
|
/**
|
|
50
79
|
* Resolves a binding to its value from the viewModel or scopes.
|
|
51
80
|
* Applies transforms and fallback handling.
|
|
@@ -68,3 +97,4 @@ export declare function resolveNode(node: NodeDefinition, context: InternalConte
|
|
|
68
97
|
* Accepts a single node or array of nodes and returns React elements.
|
|
69
98
|
*/
|
|
70
99
|
export declare function resolveTree(node: NodeDefinition | NodeDefinition[], options: ResolverContext): React.ReactNode;
|
|
100
|
+
export {};
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { useBlockApi } from "../api";
|
|
1
2
|
import type { ResolveWaitlistClaimResponse } from "../api/types";
|
|
2
3
|
export declare function getWaitlistClaimTokenFromUrl(): string | null;
|
|
3
4
|
export type UseWaitlistClaimResult = {
|
|
@@ -8,4 +9,8 @@ export type UseWaitlistClaimResult = {
|
|
|
8
9
|
requiresPortalLogin: boolean;
|
|
9
10
|
isLoading: boolean;
|
|
10
11
|
};
|
|
12
|
+
export type UseWaitlistClaimDeps = Readonly<{
|
|
13
|
+
useBlockApi: typeof useBlockApi;
|
|
14
|
+
}>;
|
|
11
15
|
export declare function useWaitlistClaim(): UseWaitlistClaimResult;
|
|
16
|
+
export declare function useWaitlistClaimWithDeps(deps: UseWaitlistClaimDeps): UseWaitlistClaimResult;
|
|
@@ -17,7 +17,7 @@ export declare function getRuntimeTimeZone(): string;
|
|
|
17
17
|
* @param days - Number of days to generate
|
|
18
18
|
* @returns Array of date strings
|
|
19
19
|
*/
|
|
20
|
-
export declare function generateDateRange(days: number): string[];
|
|
20
|
+
export declare function generateDateRange(days: number, from?: Date): string[];
|
|
21
21
|
/**
|
|
22
22
|
* Formats an ISO date string (YYYY-MM-DD) to a human-readable format
|
|
23
23
|
* @param dateStr - ISO date string (e.g., "2025-03-15")
|
|
@@ -20,6 +20,7 @@ export { useUISelector } from './ui/useUISelector';
|
|
|
20
20
|
export { EditorUiStoreProvider, useEditorUiStore, useEditorUiStoreInstance, useOptionalEditorUiStoreInstance, createEditorUiStore } from './ui/editorUiStore';
|
|
21
21
|
export type { ActivePreviewField, EditorUiStoreInstance, EditorUiState, EditorPreviewInspectorStore, EditorLinkedEntrySnapshot, PreviewInspection, PreviewSidebarTab, ViewportMode, ViewportWidth, ViewportState, ZoomLevel, } from './ui/editorUiStore';
|
|
22
22
|
export { PreviewTextEditor } from './primitives/PreviewTextEditor';
|
|
23
|
+
export { PreviewInlineTextEditor } from './primitives/PreviewInlineTextEditor';
|
|
23
24
|
export { PreviewRichTextEditor } from './primitives/PreviewRichTextEditor';
|
|
24
25
|
export { useStoreBinding, parseEditorPath } from './primitives/shared';
|
|
25
26
|
export type { PathInfo } from './primitives/shared';
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { TextProps } from '../../../blocks/src/index';
|
|
2
|
+
type PreviewInlineTextEditorProps = TextProps & {
|
|
3
|
+
path: string;
|
|
4
|
+
plainTextPath: string;
|
|
5
|
+
fallbackPlainText?: string;
|
|
6
|
+
onBlockFieldFocus?: (path: string) => void;
|
|
7
|
+
};
|
|
8
|
+
export declare function PreviewInlineTextEditor({ path, plainTextPath, fallbackPlainText, onBlockFieldFocus, className, maxLength, placeholder, ariaLabel, as: Comp, }: PreviewInlineTextEditorProps): import("react").JSX.Element | null;
|
|
9
|
+
export {};
|
|
@@ -8,5 +8,5 @@ type PreviewRichTextEditorProps = RichTextPrimitiveProps & {
|
|
|
8
8
|
* Memoized version to prevent unnecessary re-renders.
|
|
9
9
|
* Only re-renders when path, doc, variant, or className props actually change.
|
|
10
10
|
*/
|
|
11
|
-
export declare const PreviewRichTextEditor: import("react").MemoExoticComponent<({ path, linkedEntryField, onLinkedEntryFieldFocus, onBlockFieldFocus, className, doc, variant }: PreviewRichTextEditorProps) => import("react").JSX.Element>;
|
|
11
|
+
export declare const PreviewRichTextEditor: import("react").MemoExoticComponent<({ path, linkedEntryField, onLinkedEntryFieldFocus, onBlockFieldFocus, className, doc, variant, placeholder, ariaLabel, }: PreviewRichTextEditorProps) => import("react").JSX.Element>;
|
|
12
12
|
export {};
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import type { ContentFieldConfig } from '../content-types/schema';
|
|
8
8
|
export type ContentFieldType = ContentFieldConfig['type'];
|
|
9
|
-
export type BlockFieldType = 'text' | 'number' | 'slug' | 'url' | 'richText' | 'media' | 'file' | 'boolean' | 'select' | 'reference' | 'link' | 'date' | 'datetime' | 'repeater';
|
|
9
|
+
export type BlockFieldType = 'text' | 'inlineText' | 'number' | 'slug' | 'url' | 'richText' | 'media' | 'file' | 'boolean' | 'select' | 'reference' | 'link' | 'date' | 'datetime' | 'repeater';
|
|
10
10
|
export type ScalarBlockFieldType = Exclude<BlockFieldType, 'repeater'>;
|
|
11
11
|
export declare function isScalarBlockFieldType(type: string): type is ScalarBlockFieldType;
|
|
12
12
|
export type MetaFieldType = 'text' | 'date' | 'enum';
|
|
@@ -54,6 +54,12 @@ export declare const DEFAULT_TEMPLATE_DEFINITIONS: {
|
|
|
54
54
|
source: "meta";
|
|
55
55
|
path: "title";
|
|
56
56
|
}>;
|
|
57
|
+
readonly headlineInline: Readonly<{
|
|
58
|
+
source: "transform";
|
|
59
|
+
transform: import("../../../field-primitives/src/bindings/index").BindingTransformName;
|
|
60
|
+
input?: import("./types").TemplateBindingDescriptor | string;
|
|
61
|
+
path?: string;
|
|
62
|
+
}>;
|
|
57
63
|
readonly subheadline: Readonly<{
|
|
58
64
|
source: "fallback";
|
|
59
65
|
options: import("./types").TemplateBindingValue[];
|
|
@@ -107,6 +113,12 @@ export declare const DEFAULT_TEMPLATE_DEFINITIONS: {
|
|
|
107
113
|
source: "meta";
|
|
108
114
|
path: "title";
|
|
109
115
|
}>;
|
|
116
|
+
readonly headlineInline: Readonly<{
|
|
117
|
+
source: "transform";
|
|
118
|
+
transform: import("../../../field-primitives/src/bindings/index").BindingTransformName;
|
|
119
|
+
input?: import("./types").TemplateBindingDescriptor | string;
|
|
120
|
+
path?: string;
|
|
121
|
+
}>;
|
|
110
122
|
readonly subheadline: Readonly<{
|
|
111
123
|
source: "fallback";
|
|
112
124
|
options: import("./types").TemplateBindingValue[];
|
|
@@ -177,6 +189,12 @@ export declare const DEFAULT_TEMPLATE_DEFINITIONS: {
|
|
|
177
189
|
source: "meta";
|
|
178
190
|
path: "title";
|
|
179
191
|
}>;
|
|
192
|
+
readonly headlineInline: Readonly<{
|
|
193
|
+
source: "transform";
|
|
194
|
+
transform: import("../../../field-primitives/src/bindings/index").BindingTransformName;
|
|
195
|
+
input?: import("./types").TemplateBindingDescriptor | string;
|
|
196
|
+
path?: string;
|
|
197
|
+
}>;
|
|
180
198
|
readonly subheadline: Readonly<{
|
|
181
199
|
source: "fallback";
|
|
182
200
|
options: import("./types").TemplateBindingValue[];
|
|
@@ -235,6 +253,12 @@ export declare const DEFAULT_TEMPLATE_DEFINITIONS: {
|
|
|
235
253
|
source: "meta";
|
|
236
254
|
path: "title";
|
|
237
255
|
}>;
|
|
256
|
+
readonly headlineInline: Readonly<{
|
|
257
|
+
source: "transform";
|
|
258
|
+
transform: import("../../../field-primitives/src/bindings/index").BindingTransformName;
|
|
259
|
+
input?: import("./types").TemplateBindingDescriptor | string;
|
|
260
|
+
path?: string;
|
|
261
|
+
}>;
|
|
238
262
|
readonly subheadline: Readonly<{
|
|
239
263
|
source: "field";
|
|
240
264
|
path: "intro";
|
|
@@ -280,6 +304,12 @@ export declare const DEFAULT_TEMPLATE_DEFINITIONS: {
|
|
|
280
304
|
source: "meta";
|
|
281
305
|
path: "title";
|
|
282
306
|
}>;
|
|
307
|
+
readonly headlineInline: Readonly<{
|
|
308
|
+
source: "transform";
|
|
309
|
+
transform: import("../../../field-primitives/src/bindings/index").BindingTransformName;
|
|
310
|
+
input?: import("./types").TemplateBindingDescriptor | string;
|
|
311
|
+
path?: string;
|
|
312
|
+
}>;
|
|
283
313
|
readonly subheadline: Readonly<{
|
|
284
314
|
source: "fallback";
|
|
285
315
|
options: import("./types").TemplateBindingValue[];
|