@riverbankcms/sdk 0.79.0 → 0.81.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/dist/PreviewEditorSidebar-RDCMEXIJ.mjs +3163 -0
- package/dist/{PreviewEditorUI-27KJVEET.mjs → PreviewEditorUI-NYGQ6K7B.mjs} +194 -30
- package/dist/SdkPreviewModeRuntime-AKCSCZEC.mjs +8 -0
- package/dist/_dts/ai/src/contracts/proposals.d.ts +20 -0
- package/dist/_dts/api/src/contentRuntime.d.ts +12 -0
- package/dist/_dts/api/src/contentTypes.d.ts +6 -0
- package/dist/_dts/api/src/endpoints.d.ts +24 -0
- package/dist/_dts/api/src/index.d.ts +3 -3
- package/dist/_dts/api/src/publicExperienceEndpoints.d.ts +53 -0
- package/dist/_dts/api/src/siteInfrastructure.d.ts +124 -0
- package/dist/_dts/api/src/siteOnboarding.d.ts +13 -0
- package/dist/_dts/api/src/sitePlatformEndpoints.d.ts +10 -1
- package/dist/_dts/block-form/src/backend/store-backend.d.ts +3 -1
- package/dist/_dts/block-form/src/backend/types.d.ts +3 -3
- package/dist/_dts/block-form/src/client/index.d.ts +2 -0
- package/dist/_dts/block-form/src/index.d.ts +2 -0
- package/dist/_dts/block-form/src/utils/evaluateVisibility.d.ts +2 -1
- package/dist/_dts/blocks/src/PageRenderer.d.ts +3 -0
- package/dist/_dts/blocks/src/client/header.d.ts +1 -1
- package/dist/_dts/blocks/src/client.d.ts +12 -12
- package/dist/_dts/blocks/src/contracts/proof-block-islands.d.ts +20 -28
- package/dist/_dts/blocks/src/index.d.ts +7 -5
- package/dist/_dts/blocks/src/primitives/content/components/Text.d.ts +1 -1
- package/dist/_dts/blocks/src/primitives/content/primitives.d.ts +1 -0
- package/dist/_dts/blocks/src/server.d.ts +1 -1
- package/dist/_dts/blocks/src/system/blocks/events/event-calendar.d.ts +3 -2
- package/dist/_dts/blocks/src/system/blocks/events/event-listing.d.ts +2 -2
- package/dist/_dts/blocks/src/system/blocks/events/event-spotlight.d.ts +2 -1
- package/dist/_dts/blocks/src/system/blocks/events/shared/schemas.d.ts +135 -0
- package/dist/_dts/blocks/src/system/blocks/events/shared/types.d.ts +9 -1
- package/dist/_dts/blocks/src/system/blocks/feature-cards.d.ts +2 -0
- package/dist/_dts/blocks/src/system/blocks/form.d.ts +20 -1
- package/dist/_dts/blocks/src/system/blocks/hero.d.ts +2 -0
- package/dist/_dts/blocks/src/system/blocks/offerings-preview/index.d.ts +19 -0
- package/dist/_dts/blocks/src/system/blocks/offerings-preview/model.d.ts +134 -0
- package/dist/_dts/blocks/src/system/blocks/testimonials.d.ts +7 -1
- package/dist/_dts/blocks/src/system/componentFactory.d.ts +1 -0
- package/dist/_dts/blocks/src/system/constants/background.d.ts +1 -1
- package/dist/_dts/blocks/src/system/constants/blockKinds.d.ts +1 -1
- package/dist/_dts/blocks/src/system/customize/backgrounds.d.ts +34 -15
- package/dist/_dts/blocks/src/system/data/index.d.ts +2 -0
- package/dist/_dts/blocks/src/system/data/linkedContentEntries.d.ts +64 -0
- package/dist/_dts/blocks/src/system/data/loaderEndpoints.d.ts +1 -1
- package/dist/_dts/blocks/src/system/designCapabilities.d.ts +2 -2
- package/dist/_dts/blocks/src/system/fields/boxStyles.d.ts +10 -3
- package/dist/_dts/blocks/src/system/fragments/library/testimonialsCarousel.d.ts +5 -0
- package/dist/_dts/blocks/src/system/media/slotContracts.d.ts +2 -0
- package/dist/_dts/blocks/src/system/node/fragments/headingDecoration.d.ts +1 -4
- package/dist/_dts/blocks/src/system/node/types.d.ts +8 -1
- package/dist/_dts/blocks/src/system/node/validation-constants.d.ts +2 -2
- package/dist/_dts/blocks/src/system/registry.d.ts +1 -0
- package/dist/_dts/blocks/src/system/runtime/components/registry.client.d.ts +51 -57
- package/dist/_dts/blocks/src/system/runtime/components/runtime-backed-blocks.d.ts +24 -27
- package/dist/_dts/blocks/src/system/runtime/header/enhanceHeaderSection.d.ts +10 -2
- package/dist/_dts/blocks/src/system/runtime/headingDecoration.d.ts +21 -0
- package/dist/_dts/blocks/src/system/runtime/hooks/useCalendarEvents.d.ts +45 -14
- package/dist/_dts/blocks/src/system/runtime/hooks/useEventFilters.d.ts +2 -9
- package/dist/_dts/blocks/src/system/runtime/hooks/useEventPagination.d.ts +1 -10
- package/dist/_dts/blocks/src/system/runtime/nodes/basic.d.ts +1 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/events/EventCalendar.interactive.d.ts +21 -16
- package/dist/_dts/blocks/src/system/runtime/nodes/events/EventCombined.client.d.ts +3 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/events/EventCombined.interactive.d.ts +21 -16
- package/dist/_dts/blocks/src/system/runtime/nodes/events/EventListing.interactive.d.ts +22 -33
- package/dist/_dts/blocks/src/system/runtime/nodes/events/EventListing.server.d.ts +2 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/events/EventSpotlight.d.ts +2 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/EventCard.d.ts +2 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/EventDetailModal.d.ts +2 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/EventModals.d.ts +2 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/EventPaginatedListView.client.d.ts +2 -3
- package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/WeekAgendaView.d.ts +3 -3
- package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/listOptions.d.ts +50 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/utils.d.ts +2 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/header-section.client.d.ts +2 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/media.d.ts +29 -14
- package/dist/_dts/blocks/src/system/runtime/nodes/offerings-preview.d.ts +21 -0
- package/dist/_dts/blocks/src/system/runtime/resolver.d.ts +7 -0
- package/dist/_dts/blocks/src/system/transforms/registry/_utils/sectionForegroundStyles.d.ts +2 -0
- package/dist/_dts/blocks/src/system/transforms/registry/boxStyles.d.ts +7 -2
- package/dist/_dts/blocks/src/system/transforms/registry/layout.d.ts +9 -0
- package/dist/_dts/blocks/src/system/transforms/typed.d.ts +14 -1
- package/dist/_dts/calendar/src/grid.d.ts +27 -0
- package/dist/_dts/calendar/src/index.d.ts +2 -2
- package/dist/_dts/content-editor/src/controller/useAutosaveTriggers.d.ts +3 -1
- package/dist/_dts/content-editor/src/editorTransactionState.d.ts +1 -0
- package/dist/_dts/content-editor/src/hooks/autosaveScopePlanning.d.ts +26 -0
- package/dist/_dts/content-editor/src/hooks/publishability.d.ts +1 -0
- package/dist/_dts/content-editor/src/hooks/useLinkedEntryAutosave.d.ts +23 -0
- package/dist/_dts/content-editor/src/hooks/useReactiveToolbar.d.ts +1 -1
- package/dist/_dts/content-editor/src/hooks/useSimpleAutosave.d.ts +2 -2
- package/dist/_dts/content-editor/src/index.d.ts +3 -1
- package/dist/_dts/content-editor/src/lib/json.d.ts +2 -0
- package/dist/_dts/content-editor/src/linkedEntries/domain.d.ts +8 -0
- package/dist/_dts/content-editor/src/ui/editorSnapshot.d.ts +58 -0
- package/dist/_dts/content-editor/src/ui/editorTransactionState.d.ts +93 -0
- package/dist/_dts/content-editor/src/ui/editorUiStore.d.ts +60 -3
- package/dist/_dts/content-editor/src/ui/stores/autosaveStore.d.ts +2 -0
- package/dist/_dts/content-editor/src/ui/stores/types.d.ts +1 -1
- package/dist/_dts/content-model/src/content-types/builtins.d.ts +43 -0
- package/dist/_dts/content-model/src/metadataConfig.d.ts +87 -47
- package/dist/_dts/core/src/branded.d.ts +5 -0
- package/dist/_dts/core/src/index.d.ts +1 -0
- package/dist/_dts/core/src/stable-json.d.ts +1 -0
- package/dist/_dts/db/src/generated/supabase/database.types.d.ts +9 -3
- package/dist/_dts/editor/src/EditorProvider.d.ts +26 -0
- package/dist/_dts/editor/src/chrome/EditorChrome.d.ts +26 -0
- package/dist/_dts/editor/src/chrome/EditorStatusBar.d.ts +45 -0
- package/dist/_dts/editor/src/chrome/statusBarPresentation.d.ts +25 -0
- package/dist/_dts/editor/src/components/EditingToggle.d.ts +9 -0
- package/dist/_dts/editor/src/hooks/useEditableElement.d.ts +18 -0
- package/dist/_dts/editor/src/index.d.ts +29 -0
- package/dist/_dts/editor/src/inline/InlineTextEditor.d.ts +1 -0
- package/dist/_dts/editor/src/lib/utils.d.ts +1 -0
- package/dist/_dts/editor/src/primitives/EditorPrimitivesProvider.d.ts +20 -0
- package/dist/_dts/editor/src/primitives/InlineFieldContext.d.ts +11 -0
- package/dist/_dts/editor/src/primitives/SaveContext.d.ts +12 -0
- package/dist/_dts/editor/src/primitives/helpers.d.ts +1 -0
- package/dist/_dts/editor/src/primitives/rich-text/RichTextEditorSurface.d.ts +26 -0
- package/dist/_dts/editor/src/primitives/rich-text/RichTextToolbar.d.ts +16 -0
- package/dist/_dts/editor/src/primitives/rich-text/config.d.ts +23 -0
- package/dist/_dts/editor/src/primitives/rich-text/extensions/RichTextImage.d.ts +2 -0
- package/dist/_dts/editor/src/primitives/rich-text/extensions/RichTextLink.d.ts +1 -0
- package/dist/_dts/editor/src/primitives/rich-text/imageActions.d.ts +22 -0
- package/dist/_dts/editor/src/primitives/rich-text/sanitize.d.ts +23 -0
- package/dist/_dts/editor/src/primitives/rich-text/toolbar/BlockTypeDropdown.d.ts +6 -0
- package/dist/_dts/editor/src/primitives/rich-text/toolbar/LinkPopover.d.ts +10 -0
- package/dist/_dts/editor/src/primitives/rich-text/toolbar/ToolbarIconButton.d.ts +11 -0
- package/dist/_dts/editor/src/primitives/rich-text/toolbar/linkPopoverUtils.d.ts +58 -0
- package/dist/_dts/editor/src/primitives/rich-text/useRichTextEditor.d.ts +19 -0
- package/dist/_dts/editor/src/primitives/rich-text/utils.d.ts +20 -0
- package/dist/_dts/editor/src/utils/optimisticTokens.d.ts +27 -0
- package/dist/_dts/editor-blocks/src/BlockEditor.d.ts +2 -2
- package/dist/_dts/editor-blocks/src/block-editor/BlockCard.d.ts +5 -9
- package/dist/_dts/editor-blocks/src/block-editor/BlockCardBody.d.ts +2 -6
- package/dist/_dts/editor-blocks/src/block-editor/BlockCardHeader.d.ts +6 -10
- package/dist/_dts/editor-blocks/src/block-editor/FeatureCardIconsPanel.d.ts +2 -6
- package/dist/_dts/editor-blocks/src/block-editor/GeneratedIconSetDialog.d.ts +6 -4
- package/dist/_dts/editor-blocks/src/block-editor/SortableBlockItem.d.ts +4 -8
- package/dist/_dts/editor-blocks/src/block-editor/actionPresentation.d.ts +15 -0
- package/dist/_dts/editor-blocks/src/block-editor/blockHeaderActionPlan.d.ts +49 -0
- package/dist/_dts/editor-blocks/src/index.d.ts +2 -0
- package/dist/_dts/editor-blocks/src/widgets/index.d.ts +1 -0
- package/dist/_dts/editor-blocks/src/widgets/rich-text/RichTextWidgetProvider.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/widgets/rich-text/useImagePicker.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/widgets/site-option-picker/SiteOptionPickerField.d.ts +3 -0
- package/dist/_dts/editor-blocks/src/widgets/site-option-picker/SiteOptionWidgetProvider.d.ts +14 -0
- package/dist/_dts/editor-blocks/src/widgets/site-option-picker/index.d.ts +6 -0
- package/dist/_dts/editor-blocks/src/widgets/site-option-picker/loaders.d.ts +51 -0
- package/dist/_dts/editor-blocks/src/widgets/site-option-picker/types.d.ts +20 -0
- package/dist/_dts/editor-blocks/src/widgets/site-option-picker/utils.d.ts +5 -0
- package/dist/_dts/media-core/src/index.d.ts +1 -0
- package/dist/_dts/media-core/src/renderableMediaAsset.d.ts +18 -0
- package/dist/_dts/media-editor/src/MediaEditor.d.ts +4 -1
- package/dist/_dts/media-editor/src/MediaPickerDialog.d.ts +2 -1
- package/dist/_dts/media-editor/src/index.d.ts +1 -1
- package/dist/_dts/preview-next/src/client/blocks/BlockToolbar.d.ts +7 -2
- package/dist/_dts/preview-next/src/client/blocks/EditablePageRenderer.d.ts +5 -1
- package/dist/_dts/preview-next/src/client/blocks/blockCustomizePopoverRows.d.ts +25 -0
- package/dist/_dts/preview-next/src/client/blocks/composer/mergeDrafts.d.ts +2 -1
- package/dist/_dts/preview-next/src/client/blocks/composer/types.d.ts +4 -30
- package/dist/_dts/preview-next/src/client/blocks/linkedEntryRenderOverlay.d.ts +11 -0
- package/dist/_dts/preview-next/src/client/blocks/previewCustomizeActions.d.ts +3 -9
- package/dist/_dts/preview-next/src/client/blocks/previewCustomizeControlPlan.d.ts +24 -0
- package/dist/_dts/preview-next/src/client/blocks/useBlockCustomizeControls.d.ts +35 -0
- package/dist/_dts/preview-next/src/client/index.d.ts +0 -1
- package/dist/_dts/preview-next/src/client/preview/EntryEditorPanel.d.ts +3 -1
- package/dist/_dts/preview-next/src/client/preview/LinkedEntryEditEventBridge.d.ts +1 -0
- package/dist/_dts/preview-next/src/client/preview/PageBlockEditorPanel.d.ts +5 -6
- package/dist/_dts/preview-next/src/client/preview/PageDesignEditorStateContext.d.ts +4 -1
- package/dist/_dts/preview-next/src/client/preview/PreviewBlockCustomizeSelectionContext.d.ts +20 -0
- package/dist/_dts/preview-next/src/client/preview/PreviewChromeLayer.d.ts +20 -0
- package/dist/_dts/preview-next/src/client/preview/PreviewDesignHistoryOrderContext.d.ts +13 -0
- package/dist/_dts/preview-next/src/client/preview/PreviewOpenEditorButton.d.ts +2 -0
- package/dist/_dts/preview-next/src/client/preview/PreviewShell.d.ts +19 -19
- package/dist/_dts/preview-next/src/client/preview/PreviewSidebarSection.d.ts +13 -0
- package/dist/_dts/preview-next/src/client/preview/SelectedBlockCustomizePanel.d.ts +13 -0
- package/dist/_dts/preview-next/src/client/preview/SiteChromeCustomizeContext.d.ts +47 -4
- package/dist/_dts/preview-next/src/client/preview/StyleConfigurator.state.d.ts +14 -1
- package/dist/_dts/preview-next/src/client/preview/linkedEntryEditEvents.d.ts +5 -0
- package/dist/_dts/preview-next/src/client/preview/previewChromePlacement.d.ts +46 -0
- package/dist/_dts/preview-next/src/client/preview/previewCustomizeControls.d.ts +68 -0
- package/dist/_dts/preview-next/src/client/preview/previewCustomizeEditorDraftPatch.d.ts +13 -0
- package/dist/_dts/preview-next/src/client/preview/previewCustomizeHistory.d.ts +8 -1
- package/dist/_dts/preview-next/src/client/preview/previewCustomizeRuntimePatch.d.ts +2 -0
- package/dist/_dts/preview-next/src/client/preview/previewCustomizeWorkflowState.d.ts +11 -9
- package/dist/_dts/preview-next/src/client/preview/previewDesignHistoryOrder.d.ts +18 -0
- package/dist/_dts/preview-next/src/client/preview/previewUndoDomains.d.ts +1 -1
- package/dist/_dts/preview-next/src/client/preview/siteChromeBrandPreferences.d.ts +41 -0
- package/dist/_dts/preview-next/src/client/preview/siteChromeQuickControlHistoryState.d.ts +101 -0
- package/dist/_dts/preview-next/src/client/preview/siteChromeSavePlan.d.ts +29 -0
- package/dist/_dts/preview-next/src/client/preview/siteStyleHistoryState.d.ts +55 -0
- package/dist/_dts/preview-next/src/client/preview/storeTypes.d.ts +4 -0
- package/dist/_dts/preview-next/src/client/preview/styleConfiguratorApplyPayload.d.ts +1 -0
- package/dist/_dts/preview-next/src/client/widgets/widgetAdapters.d.ts +2 -1
- package/dist/_dts/preview-next/src/client/widgets/widgetOverrides.d.ts +6 -3
- package/dist/_dts/preview-next/src/constants.d.ts +0 -1
- package/dist/_dts/sdk/src/cli/commands/webhooks.d.ts +44 -0
- package/dist/_dts/sdk/src/cli/config-loader.d.ts +3 -1
- package/dist/_dts/sdk/src/cli/content/reader.d.ts +5 -3
- package/dist/_dts/sdk/src/cli/site-commands/commandSurfaceDispatch.d.ts +1 -0
- package/dist/_dts/sdk/src/cli/site-commands/pageCommands.d.ts +3 -1
- package/dist/_dts/sdk/src/cli/site-commands/pushExecution.d.ts +1 -0
- package/dist/_dts/sdk/src/client/management/index.d.ts +1 -1
- package/dist/_dts/sdk/src/client/management/types.d.ts +56 -0
- package/dist/_dts/sdk/src/client/management/webhooks.d.ts +3 -0
- package/dist/_dts/sdk/src/config/types.d.ts +1 -1
- package/dist/_dts/sdk/src/config/validation.d.ts +3 -3
- package/dist/_dts/sdk/src/contracts/system-block-content.d.ts +34 -5
- package/dist/_dts/sdk/src/public-api/contracts.d.ts +10 -0
- package/dist/_dts/sdk/src/rendering/islands/types.d.ts +42 -0
- package/dist/_dts/sdk/src/rendering/mediaAssets.d.ts +4 -0
- 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/siteStyleDefaults.d.ts +220 -0
- package/dist/_dts/theme-core/src/accordions/types.d.ts +45 -2
- package/dist/_dts/theme-core/src/blockOverrides.d.ts +8 -0
- package/dist/_dts/theme-core/src/blocks/types.d.ts +1 -1
- package/dist/_dts/theme-core/src/blocks/vars/testimonials.d.ts +4 -1
- package/dist/_dts/theme-core/src/buttons/constants.d.ts +26 -1
- package/dist/_dts/theme-core/src/buttons/personalities/index.d.ts +11 -0
- package/dist/_dts/theme-core/src/buttons/personalities/joy-stamp.d.ts +22 -0
- package/dist/_dts/theme-core/src/buttons/personalities/types.d.ts +2 -1
- package/dist/_dts/theme-core/src/buttons/types.d.ts +9 -0
- package/dist/_dts/theme-core/src/cards/core.d.ts +20 -0
- package/dist/_dts/theme-core/src/cards/generateDefaultCardSystem.d.ts +6 -3
- package/dist/_dts/theme-core/src/cards/siteStyleDefaults.d.ts +149 -0
- package/dist/_dts/theme-core/src/cards/types.d.ts +177 -0
- package/dist/_dts/theme-core/src/generated/containerResponsiveThemeCss.d.ts +1 -1
- package/dist/_dts/theme-core/src/interactive/types.d.ts +10 -0
- package/dist/_dts/theme-core/src/mock-themes/all.d.ts +180 -21
- package/dist/_dts/theme-core/src/palette/variants/index.d.ts +30 -0
- package/dist/_dts/theme-core/src/palette/variants/soft-natural.d.ts +16 -0
- package/dist/_dts/theme-core/src/palette/variants/types.d.ts +1 -1
- package/dist/_dts/theme-core/src/palette/variants/warm-dark.d.ts +27 -0
- package/dist/_dts/theme-core/src/schema.d.ts +486 -55
- package/dist/_dts/theme-core/src/site-styles/accessibleSurfaces.d.ts +4 -1
- package/dist/_dts/theme-core/src/site-styles/appearancePresetCatalog.d.ts +172 -47
- package/dist/_dts/theme-core/src/site-styles/appearancePresetResolution.d.ts +6 -2
- package/dist/_dts/theme-core/src/site-styles/appearancePresetTypes.d.ts +2 -3
- package/dist/_dts/theme-core/src/site-styles/blockAppearancePresets.d.ts +172 -47
- package/dist/_dts/theme-core/src/site-styles/curatedSiteStyles.d.ts +140 -2
- package/dist/_dts/theme-core/src/site-styles/designState.d.ts +18 -2
- package/dist/_dts/theme-core/src/site-styles/footerLooks.d.ts +20 -1
- package/dist/_dts/theme-core/src/site-styles/generatedSchemas.d.ts +10 -2
- package/dist/_dts/theme-core/src/site-styles/headerLooks.d.ts +291 -6
- package/dist/_dts/theme-core/src/site-styles/index.d.ts +3 -0
- package/dist/_dts/theme-core/src/site-styles/logoBranding.d.ts +193 -0
- package/dist/_dts/theme-core/src/site-styles/pageDesignEditorModel.d.ts +3 -23
- package/dist/_dts/theme-core/src/site-styles/pageDesignIntent.d.ts +276 -4
- package/dist/_dts/theme-core/src/site-styles/previewCompiler.d.ts +2 -8
- package/dist/_dts/theme-core/src/site-styles/rawStyleFields.d.ts +2 -0
- package/dist/_dts/theme-core/src/site-styles/runtimeCompiler.d.ts +43 -10
- package/dist/_dts/theme-core/src/site-styles/sectionTransitions.d.ts +508 -0
- package/dist/_dts/theme-core/src/site-styles/siteStyleThemeCompiler.d.ts +11 -0
- package/dist/_dts/theme-core/src/site-styles/sourceCatalogs.d.ts +10 -10
- package/dist/_dts/theme-core/src/site-styles/styleTags.d.ts +1 -1
- package/dist/_dts/theme-core/src/site-styles/testimonialQuotePresets.d.ts +15 -0
- package/dist/_dts/theme-core/src/site-styles/tokenRecipes.d.ts +1 -1
- package/dist/_dts/theme-core/src/site-styles/types.d.ts +28 -32
- package/dist/_dts/theme-core/src/site-styles/typographyPresets.d.ts +16 -1
- package/dist/{chunk-4HCW7FHJ.mjs → chunk-3PTVPAT4.mjs} +1984 -1142
- package/dist/{PreviewEditorSidebar-56NMJMIK.mjs → chunk-3QWQ2MUQ.mjs} +1050 -2609
- package/dist/{chunk-GP555I66.mjs → chunk-3VT7LZY2.mjs} +413 -157
- package/dist/{chunk-A3HHFKVT.mjs → chunk-4T5JIPWY.mjs} +1 -1
- package/dist/{chunk-K2IIF34C.mjs → chunk-E3NZYEKF.mjs} +25 -7
- package/dist/{chunk-V47ZU33I.mjs → chunk-WUHKQBB6.mjs} +12062 -3211
- package/dist/cli/index.mjs +3395 -817
- package/dist/cli/init-docs/content/workflow-isr-revalidation.md +16 -4
- package/dist/client/{accordion-QLA7KBYO.mjs → accordion-SFIIZWNH.mjs} +2 -2
- package/dist/client/{bookingForm-PYZIPA5G.mjs → bookingForm-CFKZVWGA.mjs} +5 -5
- package/dist/client/bookings.mjs +1422 -345
- package/dist/client/{carousel-5EIULWBI.mjs → carousel-ELXWSBLA.mjs} +3 -3
- package/dist/client/{cart-DOP3FNI4.mjs → cart-6SSCPYY5.mjs} +6 -6
- package/dist/client/{checkout-BVMF6FBV.mjs → checkout-UFQ34HPV.mjs} +6 -6
- package/dist/client/{chunk-44K2U3QI.mjs → chunk-76JUETXQ.mjs} +139 -186
- package/dist/client/{chunk-AUJ5DBZJ.mjs → chunk-7BXX7WXH.mjs} +112 -28
- package/dist/client/{chunk-UDS3NTWA.mjs → chunk-G56BSZAM.mjs} +2 -2
- package/dist/client/{chunk-V6M5FCR5.mjs → chunk-IUEDYLFJ.mjs} +1 -1
- package/dist/client/{chunk-YLDYVRZL.mjs → chunk-NP47RHIX.mjs} +5 -5
- package/dist/client/{chunk-R5ESWNKX.mjs → chunk-NX6X3GRF.mjs} +419 -85
- package/dist/client/{chunk-CCNTDRCF.mjs → chunk-PA2LJH2M.mjs} +2 -2
- package/dist/client/{chunk-CE7IBGVW.mjs → chunk-RMWMT3ZD.mjs} +1 -1
- package/dist/client/{chunk-TYONZMST.mjs → chunk-TCJS3NY5.mjs} +1 -1
- package/dist/client/{chunk-GG4M2NP6.mjs → chunk-V6XI4M2Q.mjs} +1 -1
- package/dist/client/client.mjs +9077 -4410
- package/dist/client/{courseRegistration-E6EAA6NL.mjs → courseRegistration-HJIISAAG.mjs} +5 -5
- package/dist/client/{eventCalendar-HBG3HAK6.mjs → eventCalendar-F6YVUCZR.mjs} +7 -7
- package/dist/client/{eventCombined-6K5ZZWAK.mjs → eventCombined-B5DSTIOK.mjs} +7 -7
- package/dist/client/{eventDetails-Q75ICXLT.mjs → eventDetails-SEJDDHQC.mjs} +7 -7
- package/dist/client/{eventListing-27P5F7DZ.mjs → eventListing-TPMWIIBO.mjs} +7 -7
- package/dist/client/{eventRegistration-IQ7AMASR.mjs → eventRegistration-QU6W2PV6.mjs} +7 -7
- package/dist/client/{form-JRTD65FN.mjs → form-LVTYNTDE.mjs} +2 -2
- package/dist/client/{headerSection-7FPSSZHS.mjs → headerSection-SO3MFC4U.mjs} +110 -28
- package/dist/client/hooks.mjs +4695 -2260
- package/dist/client/{locationMap-7NGFNYBH.mjs → locationMap-5E5FLAKO.mjs} +2 -2
- package/dist/client/{newsletterForm-F3BADCI2.mjs → newsletterForm-GN32JEBQ.mjs} +2 -2
- package/dist/client/{productDetail-V3HP7ITJ.mjs → productDetail-Q346KSVR.mjs} +6 -6
- package/dist/client/{productList-L3EGJUF2.mjs → productList-DTDMQYGZ.mjs} +6 -6
- package/dist/client/rendering/client.mjs +5795 -3582
- package/dist/client/rendering/islands.mjs +32 -20
- package/dist/client/rendering.mjs +7988 -3317
- package/dist/client/{shop-DQUB5E2C.mjs → shop-OFUW7KPN.mjs} +6 -6
- package/dist/preview-next/before-render.mjs +24 -0
- package/dist/preview-next/client/runtime.mjs +5 -5
- package/dist/preview-next/constants.mjs +0 -2
- package/dist/preview-next/index.mjs +0 -2
- package/dist/preview-next/middleware.mjs +24 -0
- package/dist/{sdk-runtime-AF6KXJU4.mjs → sdk-runtime-2GIX6I7X.mjs} +6 -6
- package/dist/server/components.mjs +7384 -3089
- package/dist/server/config-validation.mjs +4747 -2418
- package/dist/server/config.mjs +4747 -2418
- package/dist/server/data.mjs +4695 -2260
- package/dist/server/index.mjs +26 -1
- package/dist/server/next.mjs +7430 -3039
- package/dist/server/page-converter.mjs +3985 -2070
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/rendering/server.mjs +7489 -3094
- package/dist/server/rendering.mjs +7491 -3096
- package/dist/server/routing.mjs +4965 -2386
- package/dist/server/server.mjs +4713 -2278
- package/dist/server/theme-bridge.mjs +2181 -383
- package/dist/server/theme.mjs +477 -222
- package/dist/styles/index.css +747 -71
- package/package.json +1 -1
- package/dist/SdkPreviewModeRuntime-H4BSP6E7.mjs +0 -8
- package/dist/_dts/editor-blocks/src/block-editor/actionControlMode.d.ts +0 -2
- package/dist/_dts/preview-next/src/client/preview/previewSurface.d.ts +0 -3
- package/dist/chunk-LCY32PXF.mjs +0 -1175
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { useWaitlistClaim, MagicLinkForm } from './chunk-
|
|
3
|
-
import { SpinnerNode } from './chunk-
|
|
4
|
-
import { DiscountCodeDisclosure, getStepNumber, logoutPortal, StepIndicator, LoggedInAsUser, CheckIcon, formatPrice, TerminalPanel, StateIcon, ClockIcon, CrossIcon, scrollToBlock, buildCheckoutReturnUrls, MembershipHero, validateFormData } from './chunk-
|
|
2
|
+
import { useWaitlistClaim, MagicLinkForm } from './chunk-V6XI4M2Q.mjs';
|
|
3
|
+
import { SpinnerNode } from './chunk-RMWMT3ZD.mjs';
|
|
4
|
+
import { DiscountCodeDisclosure, getStepNumber, logoutPortal, StepIndicator, LoggedInAsUser, CheckIcon, formatPrice, TerminalPanel, StateIcon, ClockIcon, CrossIcon, scrollToBlock, buildCheckoutReturnUrls, MembershipHero, validateFormData } from './chunk-PA2LJH2M.mjs';
|
|
5
5
|
import { getFieldValidationControlProps, FieldValidationMessage } from './chunk-3DCJ45Z2.mjs';
|
|
6
6
|
import { ModalShell } from './chunk-3PEDD5KJ.mjs';
|
|
7
7
|
import { AltchaWidget, getChallengeUrl, isSpamProtectionEnabled } from './chunk-YLMKMCSJ.mjs';
|
|
8
8
|
import { BlockApiProvider, useBlockApi } from './chunk-UDNSI5PY.mjs';
|
|
9
9
|
import { mountReactIsland } from './chunk-N7PBWBWQ.mjs';
|
|
10
|
-
import { defineIslandPropsDecoder, themeButtonClassName, resolveCoursePricingState, formatCoursePriceDisplay, formatCoursePriceAmount } from './chunk-
|
|
11
|
-
import { formatBookingDate, toScheduledBookingDateTime, toBookingTimeZone, formatBookingTime } from './chunk-
|
|
10
|
+
import { defineIslandPropsDecoder, themeButtonClassName, resolveCoursePricingState, formatCoursePriceDisplay, formatCoursePriceAmount } from './chunk-NX6X3GRF.mjs';
|
|
11
|
+
import { formatBookingDate, toScheduledBookingDateTime, toBookingTimeZone, formatBookingTime } from './chunk-7BXX7WXH.mjs';
|
|
12
12
|
import React2, { Component, useMemo, useState, useEffect } from 'react';
|
|
13
13
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
14
14
|
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { EventCalendarClient } from './chunk-
|
|
1
|
+
import { EventCalendarClient } from './chunk-76JUETXQ.mjs';
|
|
2
2
|
import './chunk-XSV6KW4D.mjs';
|
|
3
|
-
import './chunk-
|
|
3
|
+
import './chunk-V6XI4M2Q.mjs';
|
|
4
4
|
import './chunk-I2MMZO53.mjs';
|
|
5
|
-
import './chunk-
|
|
6
|
-
import './chunk-
|
|
5
|
+
import './chunk-IUEDYLFJ.mjs';
|
|
6
|
+
import './chunk-RMWMT3ZD.mjs';
|
|
7
7
|
import './chunk-ZFHRN6W2.mjs';
|
|
8
|
-
import './chunk-
|
|
8
|
+
import './chunk-PA2LJH2M.mjs';
|
|
9
9
|
import './chunk-3DCJ45Z2.mjs';
|
|
10
10
|
import './chunk-3PEDD5KJ.mjs';
|
|
11
11
|
import './chunk-YLMKMCSJ.mjs';
|
|
12
12
|
import { BlockApiProvider } from './chunk-UDNSI5PY.mjs';
|
|
13
13
|
import { mountReactIsland } from './chunk-N7PBWBWQ.mjs';
|
|
14
|
-
import { defineIslandPropsDecoder } from './chunk-
|
|
15
|
-
import './chunk-
|
|
14
|
+
import { defineIslandPropsDecoder } from './chunk-NX6X3GRF.mjs';
|
|
15
|
+
import './chunk-7BXX7WXH.mjs';
|
|
16
16
|
import { jsx } from 'react/jsx-runtime';
|
|
17
17
|
|
|
18
18
|
var decode = defineIslandPropsDecoder("event-calendar");
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { EventCombinedIslandClient } from './chunk-
|
|
1
|
+
import { EventCombinedIslandClient } from './chunk-76JUETXQ.mjs';
|
|
2
2
|
import './chunk-XSV6KW4D.mjs';
|
|
3
|
-
import './chunk-
|
|
3
|
+
import './chunk-V6XI4M2Q.mjs';
|
|
4
4
|
import './chunk-I2MMZO53.mjs';
|
|
5
|
-
import './chunk-
|
|
6
|
-
import './chunk-
|
|
5
|
+
import './chunk-IUEDYLFJ.mjs';
|
|
6
|
+
import './chunk-RMWMT3ZD.mjs';
|
|
7
7
|
import './chunk-ZFHRN6W2.mjs';
|
|
8
|
-
import './chunk-
|
|
8
|
+
import './chunk-PA2LJH2M.mjs';
|
|
9
9
|
import './chunk-3DCJ45Z2.mjs';
|
|
10
10
|
import './chunk-3PEDD5KJ.mjs';
|
|
11
11
|
import './chunk-YLMKMCSJ.mjs';
|
|
12
12
|
import { BlockApiProvider } from './chunk-UDNSI5PY.mjs';
|
|
13
13
|
import { mountReactIsland } from './chunk-N7PBWBWQ.mjs';
|
|
14
|
-
import { defineIslandPropsDecoder } from './chunk-
|
|
15
|
-
import './chunk-
|
|
14
|
+
import { defineIslandPropsDecoder } from './chunk-NX6X3GRF.mjs';
|
|
15
|
+
import './chunk-7BXX7WXH.mjs';
|
|
16
16
|
import { jsx } from 'react/jsx-runtime';
|
|
17
17
|
|
|
18
18
|
var decode = defineIslandPropsDecoder("event-combined");
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { EventDetailsIslandClient } from './chunk-
|
|
1
|
+
import { EventDetailsIslandClient } from './chunk-76JUETXQ.mjs';
|
|
2
2
|
import './chunk-XSV6KW4D.mjs';
|
|
3
|
-
import './chunk-
|
|
3
|
+
import './chunk-V6XI4M2Q.mjs';
|
|
4
4
|
import './chunk-I2MMZO53.mjs';
|
|
5
|
-
import './chunk-
|
|
6
|
-
import './chunk-
|
|
5
|
+
import './chunk-IUEDYLFJ.mjs';
|
|
6
|
+
import './chunk-RMWMT3ZD.mjs';
|
|
7
7
|
import './chunk-ZFHRN6W2.mjs';
|
|
8
|
-
import './chunk-
|
|
8
|
+
import './chunk-PA2LJH2M.mjs';
|
|
9
9
|
import './chunk-3DCJ45Z2.mjs';
|
|
10
10
|
import './chunk-3PEDD5KJ.mjs';
|
|
11
11
|
import './chunk-YLMKMCSJ.mjs';
|
|
12
12
|
import './chunk-UDNSI5PY.mjs';
|
|
13
13
|
import { mountReactIsland } from './chunk-N7PBWBWQ.mjs';
|
|
14
|
-
import { defineIslandPropsDecoder } from './chunk-
|
|
15
|
-
import './chunk-
|
|
14
|
+
import { defineIslandPropsDecoder } from './chunk-NX6X3GRF.mjs';
|
|
15
|
+
import './chunk-7BXX7WXH.mjs';
|
|
16
16
|
import { jsx } from 'react/jsx-runtime';
|
|
17
17
|
|
|
18
18
|
var decode = defineIslandPropsDecoder("event-details");
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { EventListingClient } from './chunk-
|
|
1
|
+
import { EventListingClient } from './chunk-76JUETXQ.mjs';
|
|
2
2
|
import './chunk-XSV6KW4D.mjs';
|
|
3
|
-
import './chunk-
|
|
3
|
+
import './chunk-V6XI4M2Q.mjs';
|
|
4
4
|
import './chunk-I2MMZO53.mjs';
|
|
5
|
-
import './chunk-
|
|
6
|
-
import './chunk-
|
|
5
|
+
import './chunk-IUEDYLFJ.mjs';
|
|
6
|
+
import './chunk-RMWMT3ZD.mjs';
|
|
7
7
|
import './chunk-ZFHRN6W2.mjs';
|
|
8
|
-
import './chunk-
|
|
8
|
+
import './chunk-PA2LJH2M.mjs';
|
|
9
9
|
import './chunk-3DCJ45Z2.mjs';
|
|
10
10
|
import './chunk-3PEDD5KJ.mjs';
|
|
11
11
|
import './chunk-YLMKMCSJ.mjs';
|
|
12
12
|
import { BlockApiProvider } from './chunk-UDNSI5PY.mjs';
|
|
13
13
|
import { mountReactIsland } from './chunk-N7PBWBWQ.mjs';
|
|
14
|
-
import { defineIslandPropsDecoder } from './chunk-
|
|
15
|
-
import './chunk-
|
|
14
|
+
import { defineIslandPropsDecoder } from './chunk-NX6X3GRF.mjs';
|
|
15
|
+
import './chunk-7BXX7WXH.mjs';
|
|
16
16
|
import { jsx } from 'react/jsx-runtime';
|
|
17
17
|
|
|
18
18
|
var decode = defineIslandPropsDecoder("event-listing");
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { EventRegistrationIslandClient } from './chunk-
|
|
1
|
+
import { EventRegistrationIslandClient } from './chunk-76JUETXQ.mjs';
|
|
2
2
|
import './chunk-XSV6KW4D.mjs';
|
|
3
|
-
import './chunk-
|
|
3
|
+
import './chunk-V6XI4M2Q.mjs';
|
|
4
4
|
import './chunk-I2MMZO53.mjs';
|
|
5
|
-
import './chunk-
|
|
6
|
-
import './chunk-
|
|
5
|
+
import './chunk-IUEDYLFJ.mjs';
|
|
6
|
+
import './chunk-RMWMT3ZD.mjs';
|
|
7
7
|
import './chunk-ZFHRN6W2.mjs';
|
|
8
|
-
import './chunk-
|
|
8
|
+
import './chunk-PA2LJH2M.mjs';
|
|
9
9
|
import './chunk-3DCJ45Z2.mjs';
|
|
10
10
|
import './chunk-3PEDD5KJ.mjs';
|
|
11
11
|
import './chunk-YLMKMCSJ.mjs';
|
|
12
12
|
import { BlockApiProvider } from './chunk-UDNSI5PY.mjs';
|
|
13
13
|
import { mountReactIsland } from './chunk-N7PBWBWQ.mjs';
|
|
14
|
-
import { defineIslandPropsDecoder } from './chunk-
|
|
15
|
-
import './chunk-
|
|
14
|
+
import { defineIslandPropsDecoder } from './chunk-NX6X3GRF.mjs';
|
|
15
|
+
import './chunk-7BXX7WXH.mjs';
|
|
16
16
|
import { jsx } from 'react/jsx-runtime';
|
|
17
17
|
|
|
18
18
|
var decode = defineIslandPropsDecoder("event-registration");
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
import { isSpamProtectionEnabled, AltchaWidget, getChallengeUrl } from './chunk-YLMKMCSJ.mjs';
|
|
3
3
|
import { BlockApiProvider, FeedbackMessage, useBlockApi } from './chunk-UDNSI5PY.mjs';
|
|
4
4
|
import { mountReactIsland } from './chunk-N7PBWBWQ.mjs';
|
|
5
|
-
import { defineIslandPropsDecoder, themeButtonClassName, assertNever11, err2, ok } from './chunk-
|
|
6
|
-
import { clsx_default } from './chunk-
|
|
5
|
+
import { defineIslandPropsDecoder, themeButtonClassName, assertNever11, err2, ok } from './chunk-NX6X3GRF.mjs';
|
|
6
|
+
import { clsx_default } from './chunk-7BXX7WXH.mjs';
|
|
7
7
|
import { useState, useReducer, useRef } from 'react';
|
|
8
8
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
9
9
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { useCommerceCart } from './chunk-
|
|
2
|
+
import { useCommerceCart } from './chunk-TCJS3NY5.mjs';
|
|
3
3
|
import { resolveDedicatedCheckoutPath, ModalShell } from './chunk-3PEDD5KJ.mjs';
|
|
4
|
-
import { defineIslandPropsDecoder, buildCartDisplay, themeButtonClassName } from './chunk-
|
|
5
|
-
import './chunk-
|
|
4
|
+
import { defineIslandPropsDecoder, buildCartDisplay, themeButtonClassName } from './chunk-NX6X3GRF.mjs';
|
|
5
|
+
import './chunk-7BXX7WXH.mjs';
|
|
6
6
|
import * as React2 from 'react';
|
|
7
7
|
import { createPortal } from 'react-dom';
|
|
8
8
|
import { createRoot } from 'react-dom/client';
|
|
@@ -390,12 +390,16 @@ function getFirstNonScriptChild(root) {
|
|
|
390
390
|
}
|
|
391
391
|
function enhanceDesktopDropdownAria(root) {
|
|
392
392
|
const cleanups = [];
|
|
393
|
-
const dropdowns = Array.from(
|
|
393
|
+
const dropdowns = Array.from(
|
|
394
|
+
root.querySelectorAll(SELECTORS.dropdown)
|
|
395
|
+
);
|
|
394
396
|
const setExpanded = (trigger, expanded) => {
|
|
395
397
|
trigger.setAttribute("aria-expanded", expanded ? "true" : "false");
|
|
396
398
|
};
|
|
397
399
|
dropdowns.forEach((dropdown) => {
|
|
398
|
-
const trigger = dropdown.querySelector(
|
|
400
|
+
const trigger = dropdown.querySelector(
|
|
401
|
+
SELECTORS.dropdownTrigger
|
|
402
|
+
);
|
|
399
403
|
if (!trigger) return;
|
|
400
404
|
const menu = dropdown.querySelector(SELECTORS.dropdownMenu);
|
|
401
405
|
let placementRafId = null;
|
|
@@ -466,11 +470,15 @@ function enhanceDesktopDropdownAria(root) {
|
|
|
466
470
|
}
|
|
467
471
|
function enhanceMobileDropdowns(root) {
|
|
468
472
|
const cleanups = [];
|
|
469
|
-
const triggers = Array.from(
|
|
473
|
+
const triggers = Array.from(
|
|
474
|
+
root.querySelectorAll(SELECTORS.mobileTrigger)
|
|
475
|
+
);
|
|
470
476
|
const reset = () => {
|
|
471
477
|
triggers.forEach((trigger) => {
|
|
472
478
|
const dropdown = trigger.closest(SELECTORS.mobileDropdown);
|
|
473
|
-
const children = dropdown?.querySelector(
|
|
479
|
+
const children = dropdown?.querySelector(
|
|
480
|
+
SELECTORS.mobileChildren
|
|
481
|
+
);
|
|
474
482
|
trigger.setAttribute("aria-expanded", "false");
|
|
475
483
|
children?.classList.add(CLASSES.hidden);
|
|
476
484
|
dropdown?.classList.remove(CLASSES.mobileOpen);
|
|
@@ -478,7 +486,9 @@ function enhanceMobileDropdowns(root) {
|
|
|
478
486
|
};
|
|
479
487
|
triggers.forEach((trigger) => {
|
|
480
488
|
const dropdown = trigger.closest(SELECTORS.mobileDropdown);
|
|
481
|
-
const children = dropdown?.querySelector(
|
|
489
|
+
const children = dropdown?.querySelector(
|
|
490
|
+
SELECTORS.mobileChildren
|
|
491
|
+
);
|
|
482
492
|
if (!children) return;
|
|
483
493
|
trigger.setAttribute("aria-expanded", "false");
|
|
484
494
|
const handleClick = () => {
|
|
@@ -495,7 +505,9 @@ function enhanceMobileDropdowns(root) {
|
|
|
495
505
|
function enhanceMobileOverlay(root, resetMobileDropdowns) {
|
|
496
506
|
const cleanups = [];
|
|
497
507
|
const overlay = root.querySelector(SELECTORS.mobileOverlay);
|
|
498
|
-
const toggles = Array.from(
|
|
508
|
+
const toggles = Array.from(
|
|
509
|
+
root.querySelectorAll(SELECTORS.mobileToggle)
|
|
510
|
+
);
|
|
499
511
|
const backdrop = root.querySelector(SELECTORS.mobileBackdrop);
|
|
500
512
|
const closeBtn = root.querySelector(SELECTORS.mobileClose);
|
|
501
513
|
if (!overlay || toggles.length === 0) return { cleanups };
|
|
@@ -526,7 +538,9 @@ function enhanceMobileOverlay(root, resetMobileDropdowns) {
|
|
|
526
538
|
}
|
|
527
539
|
document.body.style.overflow = "hidden";
|
|
528
540
|
state.lastActiveElement = document.activeElement;
|
|
529
|
-
const overlayToggle = overlay.querySelector(
|
|
541
|
+
const overlayToggle = overlay.querySelector(
|
|
542
|
+
SELECTORS.mobileToggle
|
|
543
|
+
);
|
|
530
544
|
const focusTarget = overlayToggle ?? overlay.querySelector(FOCUSABLE_SELECTOR);
|
|
531
545
|
if (focusTarget) {
|
|
532
546
|
try {
|
|
@@ -576,20 +590,26 @@ function enhanceMobileOverlay(root, resetMobileDropdowns) {
|
|
|
576
590
|
const link = targetEl?.closest("a[href]");
|
|
577
591
|
if (link) handleClose();
|
|
578
592
|
};
|
|
579
|
-
toggles.forEach(
|
|
593
|
+
toggles.forEach(
|
|
594
|
+
(toggle) => toggle.addEventListener("click", handleToggleClick)
|
|
595
|
+
);
|
|
580
596
|
backdrop?.addEventListener("click", handleClose);
|
|
581
597
|
closeBtn?.addEventListener("click", handleClose);
|
|
582
598
|
document.addEventListener("keydown", handleKeyDown);
|
|
583
599
|
overlay.addEventListener("click", handleOverlayClick);
|
|
584
600
|
cleanups.push(() => {
|
|
585
601
|
setOpen(false);
|
|
586
|
-
toggles.forEach(
|
|
602
|
+
toggles.forEach(
|
|
603
|
+
(toggle) => toggle.removeEventListener("click", handleToggleClick)
|
|
604
|
+
);
|
|
587
605
|
backdrop?.removeEventListener("click", handleClose);
|
|
588
606
|
closeBtn?.removeEventListener("click", handleClose);
|
|
589
607
|
document.removeEventListener("keydown", handleKeyDown);
|
|
590
608
|
overlay.removeEventListener("click", handleOverlayClick);
|
|
591
|
-
if (state.previousBodyOverflow !== null)
|
|
592
|
-
|
|
609
|
+
if (state.previousBodyOverflow !== null)
|
|
610
|
+
document.body.style.overflow = state.previousBodyOverflow;
|
|
611
|
+
if (state.previousBodyPaddingRight !== null)
|
|
612
|
+
document.body.style.paddingRight = state.previousBodyPaddingRight;
|
|
593
613
|
});
|
|
594
614
|
return { cleanups };
|
|
595
615
|
}
|
|
@@ -623,7 +643,9 @@ function parseCartMount(element) {
|
|
|
623
643
|
}
|
|
624
644
|
function enhanceCartMounts(root) {
|
|
625
645
|
const cleanups = [];
|
|
626
|
-
const parsedMounts = Array.from(
|
|
646
|
+
const parsedMounts = Array.from(
|
|
647
|
+
root.querySelectorAll(SELECTORS.cartPlaceholder)
|
|
648
|
+
).map((element) => parseCartMount(element)).filter((mount) => mount !== null);
|
|
627
649
|
const firstMount = getFirstParsedCartMount(parsedMounts);
|
|
628
650
|
if (!firstMount) {
|
|
629
651
|
return { cleanups };
|
|
@@ -636,10 +658,29 @@ function enhanceCartMounts(root) {
|
|
|
636
658
|
}
|
|
637
659
|
return { cleanups };
|
|
638
660
|
}
|
|
639
|
-
var
|
|
640
|
-
var
|
|
641
|
-
var
|
|
642
|
-
var
|
|
661
|
+
var SCROLL_ON_THRESHOLD_MIN_PX = 24;
|
|
662
|
+
var SCROLL_ON_THRESHOLD_MAX_PX = 96;
|
|
663
|
+
var SCROLL_ON_THRESHOLD_HEADER_RATIO = 0.25;
|
|
664
|
+
var SCROLL_TOP_EPSILON_PX = 1;
|
|
665
|
+
var SCROLL_SETTLE_MS = 360;
|
|
666
|
+
function clampScrollThreshold(value) {
|
|
667
|
+
return Math.max(
|
|
668
|
+
SCROLL_ON_THRESHOLD_MIN_PX,
|
|
669
|
+
Math.min(SCROLL_ON_THRESHOLD_MAX_PX, value)
|
|
670
|
+
);
|
|
671
|
+
}
|
|
672
|
+
function resolveScrollOnThreshold(target) {
|
|
673
|
+
const height = target.getBoundingClientRect().height;
|
|
674
|
+
if (!Number.isFinite(height) || height <= 0) {
|
|
675
|
+
return SCROLL_ON_THRESHOLD_MIN_PX;
|
|
676
|
+
}
|
|
677
|
+
return clampScrollThreshold(
|
|
678
|
+
Math.round(height * SCROLL_ON_THRESHOLD_HEADER_RATIO)
|
|
679
|
+
);
|
|
680
|
+
}
|
|
681
|
+
function nowMs() {
|
|
682
|
+
return window.performance?.now?.() ?? Date.now();
|
|
683
|
+
}
|
|
643
684
|
function getScrollContainer(element) {
|
|
644
685
|
let parent = element.parentElement;
|
|
645
686
|
while (parent && parent !== document.body) {
|
|
@@ -655,7 +696,8 @@ function getScrollContainer(element) {
|
|
|
655
696
|
return document.scrollingElement || window;
|
|
656
697
|
}
|
|
657
698
|
function getRootScrollTop() {
|
|
658
|
-
if (typeof window.scrollY === "number" && Number.isFinite(window.scrollY))
|
|
699
|
+
if (typeof window.scrollY === "number" && Number.isFinite(window.scrollY))
|
|
700
|
+
return window.scrollY;
|
|
659
701
|
const scrollingElement = document.scrollingElement;
|
|
660
702
|
if (scrollingElement) return scrollingElement.scrollTop;
|
|
661
703
|
return document.documentElement.scrollTop || document.body.scrollTop || 0;
|
|
@@ -668,14 +710,40 @@ function enhanceScrollBehavior(target, scrollEnabled) {
|
|
|
668
710
|
const isRootScroll = scrollContainer === window || scrollContainer instanceof HTMLElement && (scrollContainer === document.scrollingElement || scrollContainer === document.documentElement || scrollContainer === document.body);
|
|
669
711
|
const scrollEventTarget = isRootScroll ? window : scrollContainer;
|
|
670
712
|
const getScrollTop = () => isRootScroll ? getRootScrollTop() : scrollContainer.scrollTop;
|
|
713
|
+
const scrollOnThreshold = resolveScrollOnThreshold(target);
|
|
714
|
+
let lastScrolledAtMs = Number.NEGATIVE_INFINITY;
|
|
715
|
+
let unscrollTimeoutId = null;
|
|
716
|
+
const clearUnscrollTimeout = () => {
|
|
717
|
+
if (unscrollTimeoutId === null) return;
|
|
718
|
+
window.clearTimeout(unscrollTimeoutId);
|
|
719
|
+
unscrollTimeoutId = null;
|
|
720
|
+
};
|
|
671
721
|
const update = () => {
|
|
672
722
|
const scrollTop = Math.max(0, getScrollTop());
|
|
673
723
|
const isScrolled = target.classList.contains(CLASSES.headerScrolled);
|
|
674
724
|
if (isScrolled) {
|
|
675
|
-
if (scrollTop
|
|
725
|
+
if (scrollTop > SCROLL_TOP_EPSILON_PX) {
|
|
726
|
+
clearUnscrollTimeout();
|
|
727
|
+
return;
|
|
728
|
+
}
|
|
729
|
+
const remainingSettleMs = SCROLL_SETTLE_MS - (nowMs() - lastScrolledAtMs);
|
|
730
|
+
if (remainingSettleMs > 0) {
|
|
731
|
+
if (unscrollTimeoutId === null) {
|
|
732
|
+
unscrollTimeoutId = window.setTimeout(() => {
|
|
733
|
+
unscrollTimeoutId = null;
|
|
734
|
+
update();
|
|
735
|
+
}, remainingSettleMs);
|
|
736
|
+
}
|
|
737
|
+
return;
|
|
738
|
+
}
|
|
739
|
+
target.classList.remove(CLASSES.headerScrolled);
|
|
676
740
|
return;
|
|
677
741
|
}
|
|
678
|
-
|
|
742
|
+
clearUnscrollTimeout();
|
|
743
|
+
if (scrollTop > scrollOnThreshold) {
|
|
744
|
+
target.classList.add(CLASSES.headerScrolled);
|
|
745
|
+
lastScrolledAtMs = nowMs();
|
|
746
|
+
}
|
|
679
747
|
};
|
|
680
748
|
let rafId = null;
|
|
681
749
|
let rafScheduled = false;
|
|
@@ -695,11 +763,14 @@ function enhanceScrollBehavior(target, scrollEnabled) {
|
|
|
695
763
|
cleanups.push(() => {
|
|
696
764
|
scrollEventTarget.removeEventListener("scroll", onScroll);
|
|
697
765
|
if (rafId !== null) window.cancelAnimationFrame(rafId);
|
|
766
|
+
clearUnscrollTimeout();
|
|
698
767
|
});
|
|
699
768
|
return cleanups;
|
|
700
769
|
}
|
|
701
|
-
function
|
|
702
|
-
if (root.dataset.rbHeaderEnhanced === "true")
|
|
770
|
+
function mountHeaderChromeRuntime(root, options = {}) {
|
|
771
|
+
if (root.dataset.rbHeaderEnhanced === "true") {
|
|
772
|
+
return { kind: "already-mounted" };
|
|
773
|
+
}
|
|
703
774
|
root.dataset.rbHeaderEnhanced = "true";
|
|
704
775
|
const cleanups = [];
|
|
705
776
|
cleanups.push(...enhanceDesktopDropdownAria(root));
|
|
@@ -713,9 +784,19 @@ function enhanceHeaderSection(root, options = {}) {
|
|
|
713
784
|
if (target) {
|
|
714
785
|
cleanups.push(...enhanceScrollBehavior(target, options.scrollEnabled));
|
|
715
786
|
}
|
|
716
|
-
if (cleanups.length === 0)
|
|
717
|
-
|
|
718
|
-
|
|
787
|
+
if (cleanups.length === 0) {
|
|
788
|
+
delete root.dataset.rbHeaderEnhanced;
|
|
789
|
+
return { kind: "not-applicable" };
|
|
790
|
+
}
|
|
791
|
+
let disposed = false;
|
|
792
|
+
return {
|
|
793
|
+
kind: "mounted",
|
|
794
|
+
dispose: () => {
|
|
795
|
+
if (disposed) return;
|
|
796
|
+
disposed = true;
|
|
797
|
+
cleanups.forEach((fn) => fn());
|
|
798
|
+
delete root.dataset.rbHeaderEnhanced;
|
|
799
|
+
}
|
|
719
800
|
};
|
|
720
801
|
}
|
|
721
802
|
|
|
@@ -723,7 +804,8 @@ function enhanceHeaderSection(root, options = {}) {
|
|
|
723
804
|
var decode = defineIslandPropsDecoder("headerSection");
|
|
724
805
|
var enhance = (root, props) => {
|
|
725
806
|
const scrollEnabled = typeof props?.scrollEnabled === "boolean" ? props.scrollEnabled : typeof props?.enabled === "boolean" ? props.enabled : void 0;
|
|
726
|
-
|
|
807
|
+
const mount = mountHeaderChromeRuntime(root, { scrollEnabled });
|
|
808
|
+
return mount.kind === "mounted" ? mount.dispose : void 0;
|
|
727
809
|
};
|
|
728
810
|
|
|
729
811
|
export { decode, enhance };
|