@riverbankcms/sdk 0.129.1 → 0.130.2
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/CHANGELOG.md +85 -0
- package/README.md +33 -11
- package/dist/{PreviewEditorSidebar-DceRseRV.mjs → PreviewEditorSidebar-BY-1QdE2.mjs} +327 -250
- package/dist/{PreviewEditorUI-BNunq3kk.mjs → PreviewEditorUI-BS34jI9_.mjs} +3 -3
- package/dist/{PreviewQueryProvider-B1kbhaJD.mjs → PreviewQueryProvider-BD0kOjtI.mjs} +1 -1
- package/dist/{SdkPreviewModeRuntime-Bt87-62u.mjs → SdkPreviewModeRuntime-B1pWnhu-.mjs} +235 -211
- package/dist/{SiteChromeCustomizeContext-BLl-OlL4.mjs → SiteChromeCustomizeContext-BhUG_72i.mjs} +12981 -11912
- package/dist/_dts/ai/src/contracts/proposalPrimitives.d.ts +52 -0
- package/dist/_dts/ai/src/contracts/proposals.d.ts +5256 -29129
- package/dist/_dts/ai/src/contracts/siteStyleProposalSchemas.d.ts +33429 -0
- package/dist/_dts/api/src/accountApi.d.ts +213 -0
- package/dist/_dts/api/src/accountEndpointDefinitions.d.ts +30 -0
- package/dist/_dts/api/src/accountEndpoints.d.ts +254 -0
- package/dist/_dts/api/src/apiCallParams.d.ts +60 -0
- package/dist/_dts/api/src/appointmentSetup.d.ts +21 -9
- package/dist/_dts/api/src/bookingConfig.d.ts +12 -64
- package/dist/_dts/api/src/bookingManagementEndpoints.d.ts +17 -16
- package/dist/_dts/api/src/bookingManagementEventEndpointTypes.d.ts +15 -0
- package/dist/_dts/api/src/bookingRecords.d.ts +1 -0
- package/dist/_dts/api/src/bookingSettingsSections.d.ts +9 -0
- package/dist/_dts/api/src/bookingVerticals.d.ts +2 -2
- package/dist/_dts/api/src/commercePortalEndpoints.d.ts +2 -0
- package/dist/_dts/api/src/contentRuntime.d.ts +3 -5
- package/dist/_dts/api/src/endpoints.d.ts +1355 -1318
- package/dist/_dts/api/src/event-destination-policy.d.ts +1 -1
- package/dist/_dts/api/src/eventManagementContracts.d.ts +152 -0
- package/dist/_dts/api/src/eventManagementEndpointDefinitions.d.ts +26 -0
- package/dist/_dts/api/src/eventSeriesPresentationPreset.d.ts +12 -0
- package/dist/_dts/api/src/index.d.ts +12 -3
- package/dist/_dts/api/src/indexCoreTypes.d.ts +1 -0
- package/dist/_dts/api/src/indexExtendedTypes.d.ts +1 -0
- package/dist/_dts/api/src/oauth.d.ts +8 -0
- package/dist/_dts/api/src/preview-auth.d.ts +26 -0
- package/dist/_dts/api/src/publicExperience/commerceEndpoints.d.ts +22 -47
- package/dist/_dts/api/src/publicExperience/eventEndpoints.d.ts +5 -5
- package/dist/_dts/api/src/publicExperience/wholeSeriesEndpoints.d.ts +0 -1
- package/dist/_dts/api/src/sdk-event-schedule.d.ts +5 -0
- package/dist/_dts/api/src/sdk-event-upsert.d.ts +114 -20
- package/dist/_dts/api/src/sdkBlockUpsertContracts.d.ts +48 -0
- package/dist/_dts/api/src/sdkContracts.d.ts +43 -79
- package/dist/_dts/api/src/sdkEventCategoryContracts.d.ts +9 -0
- package/dist/_dts/api/src/sdkManagedEventContracts.d.ts +35 -0
- package/dist/_dts/api/src/sdkThemeWire.d.ts +2256 -302
- package/dist/_dts/api/src/settings/permissions.d.ts +2 -2
- package/dist/_dts/api/src/siteApiKeyEndpointDefinitions.d.ts +66 -0
- package/dist/_dts/api/src/siteInfrastructure.d.ts +3 -3
- package/dist/_dts/api/src/siteOperations.d.ts +1 -1
- package/dist/_dts/api/src/sitePlatformEndpoints.d.ts +17 -4
- package/dist/_dts/api/src/siteRuntimeEndpoints.d.ts +23 -37
- package/dist/_dts/api/src/types.d.ts +7 -59
- package/dist/_dts/block-form/src/client/index.d.ts +15 -23
- package/dist/_dts/block-form/src/index.d.ts +23 -22
- package/dist/_dts/blocks/src/contracts/index.d.ts +2 -0
- package/dist/_dts/blocks/src/contracts/non-block-islands.d.ts +6 -8
- package/dist/_dts/blocks/src/contracts/proof-block-islands.d.ts +36 -14
- package/dist/_dts/blocks/src/index.d.ts +5 -3
- package/dist/_dts/blocks/src/lib/media.d.ts +9 -539
- package/dist/_dts/blocks/src/primitives/layout/Grid.d.ts +18 -1
- package/dist/_dts/blocks/src/system/blocks/appointment-booking.d.ts +1 -0
- package/dist/_dts/blocks/src/system/blocks/events/shared/filtering.d.ts +1 -1
- package/dist/_dts/blocks/src/system/blocks/events/shared/schemas.d.ts +61 -0
- package/dist/_dts/blocks/src/system/blocks/events/shared/types.d.ts +24 -22
- package/dist/_dts/blocks/src/system/blocks/feature-cards.d.ts +25 -1
- package/dist/_dts/blocks/src/system/blocks/location-map.d.ts +3 -2
- package/dist/_dts/blocks/src/system/blocks/media-text.d.ts +142 -120
- package/dist/_dts/blocks/src/system/blocks/shop.d.ts +2 -2
- package/dist/_dts/blocks/src/system/blocks/shop.shared.d.ts +37 -4
- package/dist/_dts/blocks/src/system/blocks/site-footer-nav-groups-layout.d.ts +1 -1
- package/dist/_dts/blocks/src/system/blocks/site-footer-runtime.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/site-header.d.ts +0 -1
- package/dist/_dts/blocks/src/system/blocks/team-members.d.ts +4 -63
- package/dist/_dts/blocks/src/system/componentFactory.d.ts +5 -5
- package/dist/_dts/blocks/src/system/customize/backgrounds.d.ts +9 -9
- package/dist/_dts/blocks/src/system/customize/serializeBackgroundOverride.d.ts +3 -0
- package/dist/_dts/blocks/src/system/fields/background.d.ts +2 -20
- package/dist/_dts/blocks/src/system/fields/backgroundContent.d.ts +17 -0
- package/dist/_dts/blocks/src/system/fields/backgroundContentAudit.d.ts +20 -0
- package/dist/_dts/blocks/src/system/fields/boxStyles.d.ts +18 -34
- package/dist/_dts/blocks/src/system/fields/gridLayout.d.ts +20 -0
- package/dist/_dts/blocks/src/system/fragments/builder.d.ts +1 -0
- package/dist/_dts/blocks/src/system/fragments/types.d.ts +1 -0
- package/dist/_dts/blocks/src/system/helpers/index.d.ts +1 -1
- package/dist/_dts/blocks/src/system/helpers/resolveBackground.d.ts +10 -45
- package/dist/_dts/blocks/src/system/manifest/fieldValidation/index.d.ts +7 -4
- package/dist/_dts/blocks/src/system/manifest/fieldValidation/writeCanonicalization.d.ts +4 -0
- package/dist/_dts/blocks/src/system/manifest/schema.d.ts +123 -55
- package/dist/_dts/blocks/src/system/node/fragments/classNameBinding.d.ts +6 -1
- package/dist/_dts/blocks/src/system/node/fragments/styledCard.d.ts +31 -0
- package/dist/_dts/blocks/src/system/registry.d.ts +2 -0
- package/dist/_dts/blocks/src/system/runtime/api/endpoints.d.ts +4 -0
- package/dist/_dts/blocks/src/system/runtime/api/types/courses.d.ts +0 -1
- package/dist/_dts/blocks/src/system/runtime/api/types/events.d.ts +0 -1
- package/dist/_dts/blocks/src/system/runtime/api/types/shop.d.ts +2 -37
- package/dist/_dts/blocks/src/system/runtime/components/registry.client.d.ts +61 -24
- package/dist/_dts/blocks/src/system/runtime/components/runtime-backed-blocks.d.ts +30 -12
- package/dist/_dts/blocks/src/system/runtime/header/enhanceHeaderSection.d.ts +3 -5
- package/dist/_dts/blocks/src/system/runtime/header/headerScrollRuntime.d.ts +2 -0
- package/dist/_dts/blocks/src/system/runtime/header/runtimeContract.d.ts +22 -0
- package/dist/_dts/blocks/src/system/runtime/hooks/useHeadlessBookingFlow.state.d.ts +4 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/booking-form.headless.state.d.ts +24 -8
- package/dist/_dts/blocks/src/system/runtime/nodes/booking-form.server.d.ts +8 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/booking-form.validationErrors.d.ts +17 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/commerce/shared/display.d.ts +9 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/commerce/shared/view.d.ts +3 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/event-registration.headless.planning.d.ts +1 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/event-registration/eventScope.d.ts +1 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/event-registration.server.d.ts +1 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/eventCollectionContract.d.ts +42 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/utils.d.ts +4 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/header-section.client.d.ts +2 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/header-section.frame.d.ts +21 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/header-section.server.d.ts +2 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/shop.interactive.d.ts +41 -12
- package/dist/_dts/blocks/src/system/runtime/nodes/shop.pass-contract.d.ts +3 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/shop.state.d.ts +3 -3
- package/dist/_dts/blocks/src/system/runtime/shared/components/FeedbackMessage.d.ts +17 -1
- package/dist/_dts/blocks/src/system/runtime/shared/components/index.d.ts +1 -1
- package/dist/_dts/blocks/src/system/spacing.d.ts +1 -1
- package/dist/_dts/blocks/src/system/transforms/registry/_utils/boxStyleClassNames.d.ts +90 -0
- package/dist/_dts/blocks/src/system/transforms/registry/_utils/surfaceForegroundStyles.d.ts +7 -1
- package/dist/_dts/blocks/src/system/transforms/registry/background.d.ts +1 -1
- package/dist/_dts/blocks/src/system/transforms/registry/boxStyles.d.ts +29 -1
- package/dist/_dts/blocks/src/system/transforms/registry/core.d.ts +4 -1
- package/dist/_dts/blocks/src/system/transforms/registry/headerRuntime.d.ts +3 -0
- package/dist/_dts/blocks/src/system/transforms/registry/index.d.ts +2 -1
- package/dist/_dts/blocks/src/system/transforms/registry/layout.d.ts +4 -40
- package/dist/_dts/blocks/src/system/transforms/typed.d.ts +41 -43
- package/dist/_dts/content-editor/src/FooterComposerOverview.d.ts +4 -2
- package/dist/_dts/content-editor/src/FooterComposerPanel.d.ts +2 -17
- package/dist/_dts/content-editor/src/FooterNavigationLayoutControl.d.ts +5 -0
- package/dist/_dts/content-editor/src/components/ContentFieldsForm.d.ts +2 -2
- package/dist/_dts/content-editor/src/footerComposer.d.ts +2 -1
- package/dist/_dts/content-editor/src/footerComposerPanelTypes.d.ts +21 -0
- package/dist/_dts/content-editor/src/footerPreviewRuntime.d.ts +2 -1
- package/dist/_dts/content-editor/src/useFooterComposerState.d.ts +11 -1
- package/dist/_dts/content-editor/src/useFooterNavigationLayout.d.ts +26 -0
- package/dist/_dts/content-model/src/content-types/builtin-schemas.d.ts +6 -6
- package/dist/_dts/content-model/src/content-types/builtins.d.ts +6 -6
- package/dist/_dts/content-model/src/templates/defaults.d.ts +7 -0
- package/dist/_dts/core/src/booking-date-time.d.ts +2 -2
- package/dist/_dts/core/src/booking-time-zone.d.ts +6 -0
- package/dist/_dts/core/src/branded.d.ts +4 -0
- package/dist/_dts/core/src/event-page-surface-subject.d.ts +25 -4
- package/dist/_dts/core/src/footer-composition-types.d.ts +4 -4
- package/dist/_dts/core/src/footer-navigation-layout.d.ts +4 -0
- package/dist/_dts/core/src/index.d.ts +4 -0
- package/dist/_dts/core/src/public-event-booking-availability.d.ts +8 -0
- package/dist/_dts/core/src/secret.d.ts +44 -0
- package/dist/_dts/db/src/generated/supabase/database.types.d.ts +379 -18
- package/dist/_dts/editor-blocks/src/BlockEditor.d.ts +2 -1
- package/dist/_dts/editor-blocks/src/BlockForm.d.ts +2 -2
- package/dist/_dts/editor-blocks/src/block-editor/BlockCard.d.ts +2 -2
- package/dist/_dts/editor-blocks/src/block-editor/BlockCardBody.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/block-editor/BlockCardHeader.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/block-editor/SortableBlockItem.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/block-editor/hooks/useBlockValidationManifests.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/block-editor/preparedManifest.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/blockPayload.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/index.d.ts +2 -2
- package/dist/_dts/editor-blocks/src/media/MediaField.d.ts +2 -2
- package/dist/_dts/editor-blocks/src/widgets/button/ButtonField.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/widgets/button/ButtonVariantField.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/widgets/button/index.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/widgets/content-type-select/ContentTypeSelectField.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/widgets/entry-picker/EntryPickerField.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/widgets/entry-picker/index.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/widgets/icon-picker/IconPickerField.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/widgets/inline-text/InlineTextField.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/widgets/link/LinkField.d.ts +2 -2
- package/dist/_dts/editor-blocks/src/widgets/offerings-preview/OfferingsPreviewGroupOrderField.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/widgets/reference/ReferenceField.d.ts +2 -2
- package/dist/_dts/editor-blocks/src/widgets/rich-text/RichTextField.d.ts +2 -2
- package/dist/_dts/editor-blocks/src/widgets/site-option-picker/SiteOptionPickerField.d.ts +1 -1
- package/dist/_dts/editor-blocks/src/widgets/site-option-picker/utils.d.ts +1 -1
- package/dist/_dts/preview-next/src/client/blocks/useBlockCustomizeControls.d.ts +1 -1
- package/dist/_dts/preview-next/src/client/preview/EntryEditorPanel.d.ts +1 -1
- package/dist/_dts/preview-next/src/client/preview/EntrySlotBlockEditorPanel.d.ts +1 -1
- package/dist/_dts/preview-next/src/client/preview/FooterSidebarDisclosure.d.ts +8 -0
- package/dist/_dts/preview-next/src/client/preview/PageBlockEditorPanel.d.ts +5 -5
- package/dist/_dts/preview-next/src/client/preview/PreviewEditorSidebar.d.ts +15 -17
- package/dist/_dts/preview-next/src/client/preview/PreviewFooterEditorPanel.d.ts +20 -0
- package/dist/_dts/preview-next/src/client/preview/PreviewShell.d.ts +5 -5
- package/dist/_dts/preview-next/src/client/preview/PreviewShellLayout.d.ts +3 -5
- package/dist/_dts/preview-next/src/client/preview/PreviewSiteFontStorageContext.d.ts +6 -0
- package/dist/_dts/preview-next/src/client/preview/SiteChromeCustomizeContext.d.ts +4 -4
- package/dist/_dts/preview-next/src/client/preview/StyleConfigurator.d.ts +3 -5
- package/dist/_dts/preview-next/src/client/preview/StyleConfigurator.state.d.ts +6 -7
- package/dist/_dts/preview-next/src/client/preview/siteChromeBrandPreferences.d.ts +7 -7
- package/dist/_dts/preview-next/src/client/preview/siteChromeCustomizeTypes.d.ts +4 -4
- package/dist/_dts/preview-next/src/client/preview/siteChromeQuickControlHistoryState.d.ts +2 -2
- package/dist/_dts/preview-next/src/client/preview/siteChromeSavePlan.d.ts +12 -11
- package/dist/_dts/preview-next/src/client/preview/siteChromeSelectionRows.d.ts +53 -0
- package/dist/_dts/preview-next/src/client/preview/siteFontPreview.d.ts +5 -0
- package/dist/_dts/preview-next/src/client/preview/siteStyleAccess.d.ts +1 -6
- package/dist/_dts/preview-next/src/client/preview/siteStylePreviewPlanner.d.ts +6 -15
- package/dist/_dts/preview-next/src/client/preview/styleConfiguratorSnapshot.d.ts +4 -6
- package/dist/_dts/preview-next/src/client/sdk/contentStorage.d.ts +10 -0
- package/dist/_dts/preview-next/src/client/widgets/widgetOverrides.d.ts +1 -1
- package/dist/_dts/preview-next/src/index.d.ts +1 -0
- package/dist/_dts/preview-next/src/keepAlive.d.ts +3 -5
- package/dist/_dts/preview-next/src/refresh-contract.d.ts +1 -0
- package/dist/_dts/preview-next/src/route-contract.d.ts +7 -0
- package/dist/_dts/sdk/src/config/types.d.ts +1 -0
- package/dist/_dts/sdk/src/config/validation.d.ts +2 -0
- package/dist/_dts/sdk/src/contracts/index.d.ts +1 -1
- package/dist/_dts/sdk/src/contracts/system-block-content.d.ts +64 -79
- package/dist/_dts/sdk/src/next/catch-all-theme-admission.d.ts +23 -0
- package/dist/_dts/sdk/src/next/index.d.ts +8 -6
- package/dist/_dts/sdk/src/next/resolveTheme.d.ts +1 -2
- package/dist/_dts/sdk/src/next/types.d.ts +10 -0
- package/dist/_dts/sdk/src/preview-next/keep-alive.d.ts +1 -1
- package/dist/_dts/sdk/src/public-api/contracts.d.ts +2 -16
- package/dist/_dts/sdk/src/rendering/components/Layout.d.ts +4 -3
- package/dist/_dts/sdk/src/rendering/helpers/loadContent.d.ts +5 -3
- package/dist/_dts/sdk/src/rendering/helpers/pageRuntimeSupport.d.ts +1 -1
- package/dist/_dts/sdk/src/rendering/hooks/useContent.d.ts +4 -2
- package/dist/_dts/sdk/src/rendering/index.d.ts +3 -1
- package/dist/_dts/sdk/src/rendering/islands/types.d.ts +15 -2
- package/dist/_dts/sdk/src/rendering/server.d.ts +2 -0
- package/dist/_dts/sdk/src/rendering/themeAdmission.d.ts +11 -0
- package/dist/_dts/sdk/src/theme-bridge/types.d.ts +4 -2
- package/dist/_dts/sdk/src/version.d.ts +1 -1
- package/dist/_dts/theme-core/src/blockOverrides.d.ts +1 -1
- package/dist/_dts/theme-core/src/boxBackgroundSchema.d.ts +184 -0
- package/dist/_dts/theme-core/src/buttons/buttonColourContract.d.ts +96 -0
- package/dist/_dts/theme-core/src/buttons/buttonSurfaceContext.d.ts +78 -0
- package/dist/_dts/theme-core/src/buttons/index.d.ts +1 -0
- package/dist/_dts/theme-core/src/buttons/parseThemeForPersistence.d.ts +2 -2
- package/dist/_dts/theme-core/src/buttons/resolveButtonColourStates.d.ts +9 -57
- package/dist/_dts/theme-core/src/buttons/resolvedButtonCss.d.ts +6 -3
- package/dist/_dts/theme-core/src/buttons/styles/domain.d.ts +8 -7
- package/dist/_dts/theme-core/src/buttons/styles/recipes/quietArrow.d.ts +1 -0
- package/dist/_dts/theme-core/src/buttons/styles/recipes/staticRecipes.d.ts +11 -0
- package/dist/_dts/theme-core/src/buttons/styles/registry.d.ts +12 -0
- package/dist/_dts/theme-core/src/buttons/styles/selection.d.ts +5 -0
- package/dist/_dts/theme-core/src/buttons/types.d.ts +51 -4
- package/dist/_dts/theme-core/src/cards/core.d.ts +54 -10
- package/dist/_dts/theme-core/src/cards/decorations.d.ts +33 -0
- package/dist/_dts/theme-core/src/cards/generateDefaultCardSystem.d.ts +7 -2
- package/dist/_dts/theme-core/src/cards/index.d.ts +3 -0
- package/dist/_dts/theme-core/src/cards/openCardVariant.d.ts +24 -0
- package/dist/_dts/theme-core/src/cards/roles.d.ts +38 -0
- package/dist/_dts/theme-core/src/cards/siteStyleDefaults.d.ts +53 -8
- package/dist/_dts/theme-core/src/cards/types.d.ts +489 -21
- package/dist/_dts/theme-core/src/generated/containerResponsiveThemeCss.d.ts +1 -1
- package/dist/_dts/theme-core/src/header/legacyHeaderVariant.d.ts +59 -0
- package/dist/_dts/theme-core/src/header/paintTargets.d.ts +2 -2
- package/dist/_dts/theme-core/src/header/scrollTreatment.d.ts +3 -2
- package/dist/_dts/theme-core/src/lib/media.d.ts +583 -10
- package/dist/_dts/theme-core/src/mock-themes/all.d.ts +5085 -1524
- package/dist/_dts/theme-core/src/palette/utils/contrast.d.ts +1 -0
- package/dist/_dts/theme-core/src/palette/utils/opaqueSurfaceColor.d.ts +6 -0
- package/dist/_dts/theme-core/src/runtime/buildThemeRuntimeFromBridge.d.ts +1 -1
- package/dist/_dts/theme-core/src/schema.d.ts +5300 -2019
- package/dist/_dts/theme-core/src/site-styles/appearancePresetCatalog.d.ts +84 -102
- package/dist/_dts/theme-core/src/site-styles/appearancePresetResolution.d.ts +12 -1
- package/dist/_dts/theme-core/src/site-styles/appearancePresetTypes.d.ts +9 -4
- package/dist/_dts/theme-core/src/site-styles/backgroundAppearance.d.ts +0 -20
- package/dist/_dts/theme-core/src/site-styles/blockAppearancePresets.d.ts +84 -102
- package/dist/_dts/theme-core/src/site-styles/cardRoleVocabulary.d.ts +48 -0
- package/dist/_dts/theme-core/src/site-styles/compilationPlan.d.ts +6 -14
- package/dist/_dts/theme-core/src/site-styles/curatedSiteStyles.d.ts +29 -102
- package/dist/_dts/theme-core/src/site-styles/customizableSurfaces.d.ts +3 -76
- package/dist/_dts/theme-core/src/site-styles/designState.d.ts +21 -385
- package/dist/_dts/theme-core/src/site-styles/generatedDesignPipeline.d.ts +3 -7
- package/dist/_dts/theme-core/src/site-styles/generatedDesignPipelineHelpers.d.ts +17 -0
- package/dist/_dts/theme-core/src/site-styles/generatedSchemas.d.ts +10 -18
- package/dist/_dts/theme-core/src/site-styles/headerLayoutCatalog.d.ts +281 -0
- package/dist/_dts/theme-core/src/site-styles/headerLayoutResolution.d.ts +13 -0
- package/dist/_dts/theme-core/src/site-styles/headerLayoutStyles.d.ts +6 -0
- package/dist/_dts/theme-core/src/site-styles/{headerLookTypes.d.ts → headerLayoutTypes.d.ts} +18 -90
- package/dist/_dts/theme-core/src/site-styles/headerNavStyles.d.ts +6 -0
- package/dist/_dts/theme-core/src/site-styles/headerOpeningForeground.d.ts +7 -11
- package/dist/_dts/theme-core/src/site-styles/headerOpeningSection.d.ts +2 -4
- package/dist/_dts/theme-core/src/site-styles/headerStyleCompiler.d.ts +2 -2
- package/dist/_dts/theme-core/src/site-styles/imageSurfaceBackground.d.ts +14 -0
- package/dist/_dts/theme-core/src/site-styles/index.d.ts +6 -1
- package/dist/_dts/theme-core/src/site-styles/pageDesignAppearanceAvailability.d.ts +3 -0
- package/dist/_dts/theme-core/src/site-styles/pageDesignEditorCapabilities.d.ts +22 -0
- package/dist/_dts/theme-core/src/site-styles/pageDesignEditorModel.d.ts +9 -8
- package/dist/_dts/theme-core/src/site-styles/pageDesignIntentEquality.d.ts +3 -0
- package/dist/_dts/theme-core/src/site-styles/previewCompiler.d.ts +14 -41
- package/dist/_dts/theme-core/src/site-styles/previewRuntimeCapabilities.d.ts +19 -0
- package/dist/_dts/theme-core/src/site-styles/runtimeBackgroundResolution.d.ts +32 -0
- package/dist/_dts/theme-core/src/site-styles/runtimeCompiler.d.ts +9 -68
- package/dist/_dts/theme-core/src/site-styles/siteChromeNavPreferences.d.ts +1 -1
- package/dist/_dts/theme-core/src/site-styles/sourceCatalogs.d.ts +13 -12
- package/dist/_dts/theme-core/src/site-styles/types.d.ts +50 -39
- package/dist/_dts/theme-core/src/siteChromePlanning.d.ts +9 -9
- package/dist/_dts/theme-core/src/status/generateStatusCss.d.ts +1 -0
- package/dist/_dts/theme-core/src/surfaces/index.d.ts +1 -0
- package/dist/_dts/theme-core/src/surfaces/resolveSurfaceForeground.d.ts +39 -0
- package/dist/_dts/ui/src/navigation-tabs.d.ts +3 -2
- package/dist/client/{CourseRegistrationWizard-xRmA7REV.mjs → CourseRegistrationWizard-DGW9F0SQ.mjs} +7 -7
- package/dist/client/{DiscountCodeDisclosure-B9vriL5C.mjs → DiscountCodeDisclosure-BPZ-yfGI.mjs} +1 -1
- package/dist/client/{EventCombined.client-BgVnVTlz.mjs → EventCombined.client-Cjt3kKYR.mjs} +4 -4
- package/dist/client/{EventListing.client-CqdsO7jO.mjs → EventListing.client-DY9dn6Fh.mjs} +2 -2
- package/dist/client/{FeedbackMessage-ByMrs3cr.mjs → FeedbackMessage-CtLvvS_d.mjs} +15 -3
- package/dist/client/{LeafletStaticMap-CKPxot9M.mjs → LeafletStaticMap--2c61XYn.mjs} +1 -1
- package/dist/client/{StepIndicator-DGCYuBJ1.mjs → StepIndicator-CLjQhkDb.mjs} +3 -3
- package/dist/client/{accordion-BfN5Eqd-.mjs → accordion-_boYwHHi.mjs} +1 -1
- package/dist/client/{bookingForm-DOvCpBFP.mjs → bookingForm--AqEfyBX.mjs} +56 -39
- package/dist/client/bookings.mjs +1348 -1157
- package/dist/client/{carousel-DPNmiH0f.mjs → carousel-CVI2dqZr.mjs} +2 -2
- package/dist/client/{carousel.client-CpwTUhIo.mjs → carousel.client-59G_WMr4.mjs} +1 -1
- package/dist/client/{cart--egVXlrR.mjs → cart-DR6IiPz9.mjs} +3 -3
- package/dist/client/{checkout-DywWtMcq.mjs → checkout-CsrGAfQt.mjs} +3 -3
- package/dist/client/client.mjs +20935 -19889
- package/dist/client/{colorStyles-BWpj_h4C.mjs → colorStyles-CrxJrPjJ.mjs} +277 -1
- package/dist/client/{context-CJz1Vlsz.mjs → context-B83PiNzm.mjs} +6 -21
- package/dist/client/{courseRegistration-Dk9qFVwt.mjs → courseRegistration-aNJVaLa3.mjs} +3 -3
- package/dist/client/{eventCalendar-Bkz2HjlS.mjs → eventCalendar-OZ7h59VN.mjs} +6 -6
- package/dist/client/{eventCombined-D4kipYWg.mjs → eventCombined-BbJ6bFKz.mjs} +3 -3
- package/dist/client/{eventDetails-Dz_5ix2Q.mjs → eventDetails-BLyUBiCT.mjs} +3 -3
- package/dist/client/{eventListing-D0vm-zST.mjs → eventListing-DuP1yhBS.mjs} +3 -3
- package/dist/client/{eventRegistration-Cw1E4Q4p.mjs → eventRegistration-BXyECPa-.mjs} +11 -12
- package/dist/client/{form-C2Zf1n3K.mjs → form-BA4t3kKU.mjs} +4 -4
- package/dist/client/{headerSection-CP05gzdc.mjs → headerSection-CpNaJxhW.mjs} +151 -104
- package/dist/client/hooks.mjs +6328 -6104
- package/dist/client/{locationMap-Cl3x9PYJ.mjs → locationMap-3HGMCL7_.mjs} +3 -3
- package/dist/client/{media-CNE1Z-wb.mjs → media-BOHuueS5.mjs} +16 -4
- package/dist/client/{newsletterForm-DyEJoClm.mjs → newsletterForm-C2s6Mw67.mjs} +4 -4
- package/dist/client/{pricing-DGuNR1W4.mjs → pricing-BiqIMgZk.mjs} +1 -1
- package/dist/client/{productDetail-Cq-HrGew.mjs → productDetail-C9joWhdE.mjs} +3 -3
- package/dist/client/{productList-DbB3jwqd.mjs → productList-CjzdU3pB.mjs} +3 -3
- package/dist/client/{propsDecoder-CiTuhUwY.mjs → propsDecoder-CBPGXEYX.mjs} +2480 -2478
- package/dist/client/rendering/client.mjs +5371 -6741
- package/dist/client/rendering/islands.mjs +20 -20
- package/dist/client/rendering.mjs +18616 -17447
- package/dist/client/{scrollToBlock-CShkRqab.mjs → scrollToBlock-DZ73aEX6.mjs} +1 -1
- package/dist/client/{shop-Cu4Ib-ZA.mjs → shop-CQRai7hj.mjs} +36 -25
- package/dist/client/{shop-commerce-BzpsOdh7.mjs → shop-commerce-hP9UboOx.mjs} +8 -8
- package/dist/client/{shop-commerce-store-DaE7Fhj8.mjs → shop-commerce-store-DiD5a32e.mjs} +1 -1
- package/dist/client/{shopShared-cF0c20vB.mjs → shopShared-DP8DXTkF.mjs} +12 -6
- package/dist/client/{useEventFilters-QZ3HMgaJ.mjs → useEventFilters-pF_OJNQP.mjs} +137 -81
- package/dist/client/{usePolling-BKf0GcE-.mjs → usePolling-Cls91SD2.mjs} +2 -2
- package/dist/preview-next/before-render.mjs +202 -129
- package/dist/preview-next/client/runtime.mjs +4 -4
- package/dist/preview-next/keepAlive.mjs +7406 -29
- package/dist/preview-next/middleware.mjs +196 -128
- package/dist/{previewAuthStore-BesgU5Xu.mjs → previewAuthStore-CX1C_KJ4.mjs} +195 -128
- package/dist/{sdk-runtime-C20CVWbb.mjs → sdk-runtime-5CcPAI14.mjs} +2 -2
- package/dist/{separator-BE3NCquy.mjs → separator-BXlYN_gr.mjs} +1 -1
- package/dist/server/components.mjs +22644 -21375
- package/dist/server/config-validation.mjs +6507 -6309
- package/dist/server/config.mjs +6511 -6313
- package/dist/server/data.mjs +6311 -6104
- package/dist/server/date-time.mjs +22 -13
- package/dist/server/index.mjs +196 -129
- package/dist/server/next.mjs +22782 -21578
- package/dist/server/page-converter.mjs +4769 -6213
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/rendering/server.mjs +20525 -20291
- package/dist/server/rendering.mjs +22677 -21389
- package/dist/server/routing.mjs +6651 -5398
- package/dist/server/server.mjs +6389 -6256
- package/dist/server/theme-bridge.mjs +2251 -2465
- package/dist/server/theme.mjs +974 -642
- package/dist/styles/index.css +317 -337
- package/package.json +3 -2
- package/dist/_dts/block-form/src/client/blockDraftSaveability.d.ts +0 -1
- package/dist/_dts/block-form/src/widgets/index.d.ts +0 -20
- package/dist/_dts/blocks/src/system/runtime/api/requestBody.d.ts +0 -7
- package/dist/_dts/preview-next/src/client/preview/siteChromeLookRows.d.ts +0 -66
- package/dist/_dts/theme-core/src/site-styles/headerLayoutStyleCatalog.d.ts +0 -254
- package/dist/_dts/theme-core/src/site-styles/headerLegacyLooks.d.ts +0 -372
- package/dist/_dts/theme-core/src/site-styles/headerLookBranding.d.ts +0 -106
- package/dist/_dts/theme-core/src/site-styles/headerLookSelection.d.ts +0 -2
- package/dist/_dts/theme-core/src/site-styles/headerLooks.d.ts +0 -7
- package/dist/_dts/theme-core/src/site-styles/headerStyleCompilerPrimitives.d.ts +0 -23
- package/dist/client/clsx-DgIEfj3H.mjs +0 -16
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { $ as
|
|
3
|
-
import { d as unwrapResponse, f as getDashboardUrl, r as usePreviewAuth } from "./previewAuthStore-
|
|
4
|
-
import { t as Separator } from "./separator-
|
|
5
|
-
import { S as getSiteFontsStorageUrl, _ as
|
|
2
|
+
import { $ as FooterComposerPanel, $i as SearchInput, A as markApplySaved, Ai as paletteColorsSchema, B as resetTypographyToSaved, Bt as useEditorUiStoreInstance, C as applyTypographyDraftPatch, Ca as DropdownMenuTrigger, Cr as curatedSiteStyles, D as dismissWarnings, Da as cn, Dr as findFooterLook, E as deriveStyleConfiguratorCapabilities, En as ThemeScope, F as previewCuratedPalette, Fa as X$1, Fr as curatedPalettes, H as styleConfiguratorHistoryEntryForPersistedSelection, Ha as SlidersHorizontal, I as previewFooterLook, Ja as Monitor, Ji as SelectItem, Ki as Select, L as previewHeaderLayout, M as openRow, N as palettePreviewProjection, Nt as BlockEditor, O as isPreviewingChange, Or as getHeaderLayout, P as previewButtonStyle, Q as resolvePreviewSidebarTab, Qi as CalloutDescription, R as previewHeaderStyle, S as applyResolvedSelections, Sa as DropdownMenuSeparator, Si as themeButtonClassName, T as createStyleConfiguratorState, Ta as Button, Tr as getCuratedSiteStyle, U as syncStyleConfiguratorState, V as setPaletteColors, Va as Smartphone, W as toggleRow, Xa as LoaderCircle, Xi as SelectValue, Ya as Maximize2, Yi as SelectTrigger, Z as createOptimisticActionRunner, Zi as Callout, _ as PREVIEW_DESIGN_SAVE_ERROR_MESSAGE, _a as Surface, _i as buttonStyleSelectionParameterValue, _n as listEntryPageContentSlots, aa as TabsContent, an as resolveContentTitle, at as useUISelector, b as cycleSiteChromeSelectionId, ba as DropdownMenuItem, bi as updateButtonStyleSelectionChoice, c as selectionSnapshotFromApplySiteStyleSelectionResponse, cn as ManifestForm, ct as useEntryController, d as resolveStyleConfiguratorInitialSnapshot, dn as FormRenderer, ea as Popover, ga as CollapsibleTrigger, ha as CollapsibleContent, ia as Tabs, in as resolvePageRouteSlug, io as Check, it as ContentFieldsForm, j as markApplySaving, ja as assertNever$1, k as markApplyFailed, ka as unsafeAsEditorBlockId, ki as paletteColorEntries, kr as getHeaderStyle, l as deriveSiteStylePreviewUpdate, ma as Collapsible, n as useSiteChromeCustomizeOptional, na as PopoverTrigger, no as ChevronLeft, oa as TabsList, p as usePreviewDesignCoordinator, pn as createStoreBackend, qi as SelectContent, ra as Input, rn as deriveRouteMetadataPresentation, s as buildApplySiteStyleSelectionBody, sa as TabsTrigger, ta as PopoverContent, tn as isAdapterReferenceKind, to as ChevronRight, u as planSiteStylePreviewChange, un as createManifestValidation, v as reportPreviewDesignError, va as DropdownMenu, vi as findButtonStyleRecipe, w as cancelPreview, x as planSiteChromeSelection, xa as DropdownMenuLabel, xi as buttonStyleSelectionKey, y as buildSiteChromeSelectionModels, ya as DropdownMenuContent, yi as resolveButtonStyleSelection, z as previewSiteStyle, za as Tablet, zt as useEditorUiStore } from "./SiteChromeCustomizeContext-BhUG_72i.mjs";
|
|
3
|
+
import { d as unwrapResponse, f as getDashboardUrl, r as usePreviewAuth } from "./previewAuthStore-CX1C_KJ4.mjs";
|
|
4
|
+
import { t as Separator } from "./separator-BXlYN_gr.mjs";
|
|
5
|
+
import { S as getSiteFontsStorageUrl, _ as usePreviewBlockCustomizeSelectionOptional, b as buildFontPreviewUrl, d as buildPreviewDashboardSetupUrl, f as resolvePreviewDashboardSetupHandoff, g as useBlockCustomizeControls, h as usePreviewSiteFontStorageUrl, m as resolvePreviewSidebarChromeModel, p as resolvePreviewEditorGuidanceModel, u as canInspectSiteStyle, v as PreviewFormProvider, x as generateFontFaceCss, y as previewWidgetOverrides } from "./SdkPreviewModeRuntime-B1pWnhu-.mjs";
|
|
6
6
|
import React, { createContext, forwardRef, useCallback, useContext, useEffect, useId, useLayoutEffect, useMemo, useRef, useState, useSyncExternalStore, useTransition } from "react";
|
|
7
7
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
8
8
|
import { useQuery, useQueryClient } from "@tanstack/react-query";
|
|
@@ -509,7 +509,7 @@ const SUBROUTE_KINDS = { "event-occurrence": {
|
|
|
509
509
|
instanceNoun: "date",
|
|
510
510
|
listLabel: "events list",
|
|
511
511
|
formatInstanceName: (occurrence) => formatOccurrenceDate(occurrence.startsAt),
|
|
512
|
-
subEditorPath: (
|
|
512
|
+
subEditorPath: () => "bookings/events"
|
|
513
513
|
} };
|
|
514
514
|
//#endregion
|
|
515
515
|
//#region ../content-model/src/contentManifest.ts
|
|
@@ -1437,6 +1437,56 @@ function EntryEditorPanel({ siteId, dashboardBaseUrl, entryData, contentTypeSche
|
|
|
1437
1437
|
});
|
|
1438
1438
|
}
|
|
1439
1439
|
//#endregion
|
|
1440
|
+
//#region ../preview-next/src/client/preview/FooterSidebarDisclosure.tsx
|
|
1441
|
+
function FooterSidebarDisclosure({ editorStore, hidden, children }) {
|
|
1442
|
+
const [open, setOpen] = useState(false);
|
|
1443
|
+
const sectionRef = useRef(null);
|
|
1444
|
+
const inspection = useUISelector(editorStore, (state) => state.previewInspection);
|
|
1445
|
+
useEffect(() => {
|
|
1446
|
+
if (inspection.kind !== "footer" && inspection.kind !== "footer-module") return;
|
|
1447
|
+
setOpen(true);
|
|
1448
|
+
sectionRef.current?.scrollIntoView({
|
|
1449
|
+
block: "start",
|
|
1450
|
+
behavior: "smooth"
|
|
1451
|
+
});
|
|
1452
|
+
}, [inspection]);
|
|
1453
|
+
return /* @__PURE__ */ jsx(Collapsible, {
|
|
1454
|
+
hidden,
|
|
1455
|
+
"data-design-takeover-sibling": true,
|
|
1456
|
+
open,
|
|
1457
|
+
onOpenChange: setOpen,
|
|
1458
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
1459
|
+
ref: sectionRef,
|
|
1460
|
+
className: "border-b",
|
|
1461
|
+
children: [/* @__PURE__ */ jsx(CollapsibleTrigger, {
|
|
1462
|
+
asChild: true,
|
|
1463
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
1464
|
+
className: "flex cursor-pointer items-center gap-2 px-4 py-3 hover:bg-accent/40",
|
|
1465
|
+
children: [/* @__PURE__ */ jsx(ChevronRight, { className: `h-4 w-4 transition ${open ? "rotate-90" : ""}` }), /* @__PURE__ */ jsx("span", {
|
|
1466
|
+
className: "text-sm font-semibold",
|
|
1467
|
+
children: "Footer"
|
|
1468
|
+
})]
|
|
1469
|
+
})
|
|
1470
|
+
}), /* @__PURE__ */ jsx(CollapsibleContent, { children: /* @__PURE__ */ jsx("div", {
|
|
1471
|
+
className: "pb-4",
|
|
1472
|
+
children
|
|
1473
|
+
}) })]
|
|
1474
|
+
})
|
|
1475
|
+
});
|
|
1476
|
+
}
|
|
1477
|
+
//#endregion
|
|
1478
|
+
//#region ../preview-next/src/client/preview/PreviewDesignOpenRequestContext.tsx
|
|
1479
|
+
const PreviewDesignOpenRequestContext = createContext(null);
|
|
1480
|
+
function PreviewDesignOpenRequestProvider({ request, children }) {
|
|
1481
|
+
return /* @__PURE__ */ jsx(PreviewDesignOpenRequestContext.Provider, {
|
|
1482
|
+
value: request,
|
|
1483
|
+
children
|
|
1484
|
+
});
|
|
1485
|
+
}
|
|
1486
|
+
function usePreviewDesignOpenRequest() {
|
|
1487
|
+
return useContext(PreviewDesignOpenRequestContext);
|
|
1488
|
+
}
|
|
1489
|
+
//#endregion
|
|
1440
1490
|
//#region ../preview-next/src/client/preview/SelectedBlockCustomizePanel.tsx
|
|
1441
1491
|
const EMPTY_BLOCK_VALUES = {};
|
|
1442
1492
|
function SelectedBlockCustomizePanel({ blockItems, uiStoreForBlockEditor, theme, sdkConfig }) {
|
|
@@ -1537,20 +1587,8 @@ function formatBlockKindLabel(blockKind) {
|
|
|
1537
1587
|
return blockKind.replace(/^block\./, "").replace(/^custom\./, "").replace(/[-_]+/g, " ");
|
|
1538
1588
|
}
|
|
1539
1589
|
//#endregion
|
|
1540
|
-
//#region ../preview-next/src/client/preview/PreviewDesignOpenRequestContext.tsx
|
|
1541
|
-
const PreviewDesignOpenRequestContext = createContext(null);
|
|
1542
|
-
function PreviewDesignOpenRequestProvider({ request, children }) {
|
|
1543
|
-
return /* @__PURE__ */ jsx(PreviewDesignOpenRequestContext.Provider, {
|
|
1544
|
-
value: request,
|
|
1545
|
-
children
|
|
1546
|
-
});
|
|
1547
|
-
}
|
|
1548
|
-
function usePreviewDesignOpenRequest() {
|
|
1549
|
-
return useContext(PreviewDesignOpenRequestContext);
|
|
1550
|
-
}
|
|
1551
|
-
//#endregion
|
|
1552
1590
|
//#region ../preview-next/src/client/preview/PageBlockEditorPanel.tsx
|
|
1553
|
-
function
|
|
1591
|
+
function usePageBlockEditorPanelControls(uiStoreForBlockEditor) {
|
|
1554
1592
|
const customizeSelection = usePreviewBlockCustomizeSelectionOptional();
|
|
1555
1593
|
const [designOpen, setDesignOpen] = useState(false);
|
|
1556
1594
|
const [customizeOpen, setCustomizeOpen] = useState(false);
|
|
@@ -1595,160 +1633,210 @@ function PageBlockEditorPanel({ siteId, pageId, dashboardBaseUrl, theme, apiClie
|
|
|
1595
1633
|
});
|
|
1596
1634
|
uiStoreForBlockEditor.getState().consumePreviewDesignOpenRequest(pendingDesignOpenRequest.requestId);
|
|
1597
1635
|
}, [pendingDesignOpenRequest, uiStoreForBlockEditor]);
|
|
1636
|
+
return {
|
|
1637
|
+
designOpen,
|
|
1638
|
+
setDesignOpen,
|
|
1639
|
+
customizeOpen,
|
|
1640
|
+
setCustomizeOpen,
|
|
1641
|
+
contentOpen,
|
|
1642
|
+
setContentOpen,
|
|
1643
|
+
detailsOpen,
|
|
1644
|
+
setDetailsOpen,
|
|
1645
|
+
designOpenRequest,
|
|
1646
|
+
designSectionRef,
|
|
1647
|
+
customizeSectionRef,
|
|
1648
|
+
blockActionPresentation
|
|
1649
|
+
};
|
|
1650
|
+
}
|
|
1651
|
+
function PageBlockEditorPanel(props) {
|
|
1652
|
+
const controls = usePageBlockEditorPanelControls(props.uiStoreForBlockEditor);
|
|
1653
|
+
const takeover = props.designTakeoverActive ?? false;
|
|
1598
1654
|
return /* @__PURE__ */ jsxs("div", {
|
|
1599
1655
|
className: "flex h-full min-h-0 flex-col overflow-hidden",
|
|
1600
1656
|
children: [/* @__PURE__ */ jsx("div", {
|
|
1601
1657
|
className: "shrink-0 border-b px-4 py-2",
|
|
1602
1658
|
children: /* @__PURE__ */ jsx(PreviewViewportControls, {
|
|
1603
|
-
mode: viewportMode,
|
|
1604
|
-
width: viewportWidth,
|
|
1605
|
-
onModeChange: onViewportModeChange,
|
|
1606
|
-
onWidthChange: onViewportWidthChange,
|
|
1607
|
-
zoom,
|
|
1608
|
-
onZoomChange
|
|
1659
|
+
mode: props.viewportMode,
|
|
1660
|
+
width: props.viewportWidth,
|
|
1661
|
+
onModeChange: props.onViewportModeChange,
|
|
1662
|
+
onWidthChange: props.onViewportWidthChange,
|
|
1663
|
+
zoom: props.zoom,
|
|
1664
|
+
onZoomChange: props.onZoomChange
|
|
1609
1665
|
})
|
|
1610
1666
|
}), /* @__PURE__ */ jsx(PreviewFormProvider, {
|
|
1611
|
-
siteId,
|
|
1612
|
-
theme: theme ?? null,
|
|
1613
|
-
previewClient: apiClient,
|
|
1614
|
-
bookingOfferingPresets,
|
|
1615
|
-
sdkConfig: sdkConfig ?? null,
|
|
1667
|
+
siteId: props.siteId,
|
|
1668
|
+
theme: props.theme ?? null,
|
|
1669
|
+
previewClient: props.apiClient,
|
|
1670
|
+
bookingOfferingPresets: props.bookingOfferingPresets,
|
|
1671
|
+
sdkConfig: props.sdkConfig ?? null,
|
|
1616
1672
|
children: /* @__PURE__ */ jsxs("div", {
|
|
1617
|
-
className: `min-h-0 flex-1 space-y-0 ${
|
|
1618
|
-
"data-design-takeover-active":
|
|
1673
|
+
className: `min-h-0 flex-1 space-y-0 ${takeover ? "flex flex-col overflow-hidden" : "overflow-auto"}`,
|
|
1674
|
+
"data-design-takeover-active": takeover ? "true" : "false",
|
|
1619
1675
|
children: [
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
}) : null,
|
|
1629
|
-
designPanel ? /* @__PURE__ */ jsx(Collapsible, {
|
|
1630
|
-
className: designTakeoverActive ? "flex min-h-0 flex-1 flex-col overflow-hidden" : void 0,
|
|
1631
|
-
open: designTakeoverActive || designOpen,
|
|
1632
|
-
onOpenChange: (open) => {
|
|
1633
|
-
if (!designTakeoverActive) setDesignOpen(open);
|
|
1634
|
-
},
|
|
1635
|
-
children: /* @__PURE__ */ jsxs("div", {
|
|
1636
|
-
ref: designSectionRef,
|
|
1637
|
-
className: designTakeoverActive ? "flex min-h-0 flex-1 flex-col overflow-hidden" : "border-b",
|
|
1638
|
-
children: [/* @__PURE__ */ jsx(CollapsibleTrigger, {
|
|
1639
|
-
asChild: true,
|
|
1640
|
-
children: /* @__PURE__ */ jsxs("div", {
|
|
1641
|
-
className: `flex shrink-0 cursor-pointer items-center gap-2 px-4 py-3 hover:bg-accent/40 ${designTakeoverActive ? "border-b" : ""}`,
|
|
1642
|
-
children: [/* @__PURE__ */ jsx(ChevronRight, { className: `h-4 w-4 transition ${designTakeoverActive || designOpen ? "rotate-90" : ""}` }), /* @__PURE__ */ jsx("span", {
|
|
1643
|
-
className: "text-sm font-semibold",
|
|
1644
|
-
children: "Design"
|
|
1645
|
-
})]
|
|
1646
|
-
})
|
|
1647
|
-
}), /* @__PURE__ */ jsx(CollapsibleContent, {
|
|
1648
|
-
className: designTakeoverActive ? "min-h-0 flex-1 data-[state=open]:h-full data-[state=open]:overflow-hidden" : void 0,
|
|
1649
|
-
children: /* @__PURE__ */ jsx("div", {
|
|
1650
|
-
className: designTakeoverActive ? "h-full min-h-0" : "px-4 pb-4",
|
|
1651
|
-
children: /* @__PURE__ */ jsx(PreviewDesignOpenRequestProvider, {
|
|
1652
|
-
request: designOpenRequest,
|
|
1653
|
-
children: designPanel
|
|
1654
|
-
})
|
|
1655
|
-
})
|
|
1656
|
-
})]
|
|
1657
|
-
})
|
|
1676
|
+
/* @__PURE__ */ jsx(LinkedEntrySection, {
|
|
1677
|
+
section: props.linkedEntrySection,
|
|
1678
|
+
hidden: takeover
|
|
1679
|
+
}),
|
|
1680
|
+
props.designPanel ? /* @__PURE__ */ jsx(DesignSection, {
|
|
1681
|
+
panel: props.designPanel,
|
|
1682
|
+
takeover,
|
|
1683
|
+
controls
|
|
1658
1684
|
}) : null,
|
|
1659
|
-
/* @__PURE__ */ jsx(
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
className: "flex cursor-pointer items-center gap-2 px-4 py-3 hover:bg-accent/40",
|
|
1671
|
-
children: [/* @__PURE__ */ jsx(ChevronRight, { className: `h-4 w-4 transition ${customizeOpen ? "rotate-90" : ""}` }), /* @__PURE__ */ jsx("span", {
|
|
1672
|
-
className: "text-sm font-semibold",
|
|
1673
|
-
children: "Customize"
|
|
1674
|
-
})]
|
|
1675
|
-
})
|
|
1676
|
-
}), /* @__PURE__ */ jsx(CollapsibleContent, { children: /* @__PURE__ */ jsx("div", {
|
|
1677
|
-
className: "px-4 pb-4",
|
|
1678
|
-
children: /* @__PURE__ */ jsx(SelectedBlockCustomizePanel, {
|
|
1679
|
-
blockItems,
|
|
1680
|
-
uiStoreForBlockEditor,
|
|
1681
|
-
theme: theme ?? null,
|
|
1682
|
-
sdkConfig: sdkConfig ?? null
|
|
1683
|
-
})
|
|
1684
|
-
}) })]
|
|
1685
|
+
/* @__PURE__ */ jsx(StandardSection, {
|
|
1686
|
+
label: "Customize",
|
|
1687
|
+
open: controls.customizeOpen,
|
|
1688
|
+
onOpenChange: controls.setCustomizeOpen,
|
|
1689
|
+
hidden: takeover,
|
|
1690
|
+
sectionRef: controls.customizeSectionRef,
|
|
1691
|
+
children: /* @__PURE__ */ jsx(SelectedBlockCustomizePanel, {
|
|
1692
|
+
blockItems: props.blockItems,
|
|
1693
|
+
uiStoreForBlockEditor: props.uiStoreForBlockEditor,
|
|
1694
|
+
theme: props.theme ?? null,
|
|
1695
|
+
sdkConfig: props.sdkConfig ?? null
|
|
1685
1696
|
})
|
|
1686
1697
|
}),
|
|
1687
|
-
/* @__PURE__ */ jsx(
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
children: /* @__PURE__ */
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
owner: {
|
|
1710
|
-
kind: "page",
|
|
1711
|
-
pageId
|
|
1712
|
-
},
|
|
1713
|
-
blocks: blockItems,
|
|
1714
|
-
uiStore: uiStoreForBlockEditor,
|
|
1715
|
-
apiClient,
|
|
1716
|
-
onBlocksChange,
|
|
1717
|
-
actionPresentation: blockActionPresentation,
|
|
1718
|
-
widgetOverrides: previewWidgetOverrides,
|
|
1719
|
-
sdkConfig: sdkConfig ?? null,
|
|
1720
|
-
reorderControlMode: "drag-handle-only"
|
|
1721
|
-
}, pageId)
|
|
1722
|
-
}) })]
|
|
1723
|
-
})
|
|
1698
|
+
/* @__PURE__ */ jsx(StandardSection, {
|
|
1699
|
+
label: "Page Blocks",
|
|
1700
|
+
open: controls.contentOpen,
|
|
1701
|
+
onOpenChange: controls.setContentOpen,
|
|
1702
|
+
hidden: takeover,
|
|
1703
|
+
children: /* @__PURE__ */ jsx(BlockEditor, {
|
|
1704
|
+
ref: props.blockEditorRef,
|
|
1705
|
+
siteId: props.siteId,
|
|
1706
|
+
dashboardBaseUrl: props.dashboardBaseUrl,
|
|
1707
|
+
owner: {
|
|
1708
|
+
kind: "page",
|
|
1709
|
+
pageId: props.pageId
|
|
1710
|
+
},
|
|
1711
|
+
blocks: props.blockItems,
|
|
1712
|
+
uiStore: props.uiStoreForBlockEditor,
|
|
1713
|
+
apiClient: props.apiClient,
|
|
1714
|
+
onBlocksChange: props.onBlocksChange,
|
|
1715
|
+
actionPresentation: controls.blockActionPresentation,
|
|
1716
|
+
widgetOverrides: previewWidgetOverrides,
|
|
1717
|
+
sdkConfig: props.sdkConfig ?? null,
|
|
1718
|
+
reorderControlMode: "drag-handle-only"
|
|
1719
|
+
}, props.pageId)
|
|
1724
1720
|
}),
|
|
1725
|
-
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1735
|
-
|
|
1736
|
-
children: [/* @__PURE__ */ jsx(ChevronRight, { className: `h-4 w-4 transition ${detailsOpen ? "rotate-90" : ""}` }), /* @__PURE__ */ jsx("span", {
|
|
1737
|
-
className: "text-sm font-semibold",
|
|
1738
|
-
children: "Page Details"
|
|
1739
|
-
})]
|
|
1740
|
-
})
|
|
1741
|
-
}), /* @__PURE__ */ jsx(CollapsibleContent, { children: /* @__PURE__ */ jsx("div", {
|
|
1742
|
-
className: "px-4 pb-4",
|
|
1743
|
-
children: metadataPanel
|
|
1744
|
-
}) })]
|
|
1745
|
-
})
|
|
1721
|
+
props.footerPanel ? /* @__PURE__ */ jsx(FooterSidebarDisclosure, {
|
|
1722
|
+
editorStore: props.uiStoreForBlockEditor,
|
|
1723
|
+
hidden: takeover,
|
|
1724
|
+
children: props.footerPanel
|
|
1725
|
+
}) : null,
|
|
1726
|
+
props.metadataPanel ? /* @__PURE__ */ jsx(StandardSection, {
|
|
1727
|
+
label: "Page Details",
|
|
1728
|
+
open: controls.detailsOpen,
|
|
1729
|
+
onOpenChange: controls.setDetailsOpen,
|
|
1730
|
+
hidden: takeover,
|
|
1731
|
+
children: props.metadataPanel
|
|
1746
1732
|
}) : null
|
|
1747
1733
|
]
|
|
1748
1734
|
})
|
|
1749
1735
|
})]
|
|
1750
1736
|
});
|
|
1751
1737
|
}
|
|
1738
|
+
function StandardSection({ label, open, onOpenChange, hidden, sectionRef, children }) {
|
|
1739
|
+
return /* @__PURE__ */ jsx(Collapsible, {
|
|
1740
|
+
hidden,
|
|
1741
|
+
"data-design-takeover-sibling": true,
|
|
1742
|
+
open,
|
|
1743
|
+
onOpenChange,
|
|
1744
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
1745
|
+
ref: sectionRef,
|
|
1746
|
+
className: "border-b",
|
|
1747
|
+
children: [/* @__PURE__ */ jsx(CollapsibleTrigger, {
|
|
1748
|
+
asChild: true,
|
|
1749
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
1750
|
+
className: "flex cursor-pointer items-center gap-2 px-4 py-3 hover:bg-accent/40",
|
|
1751
|
+
children: [/* @__PURE__ */ jsx(ChevronRight, { className: `h-4 w-4 transition ${open ? "rotate-90" : ""}` }), /* @__PURE__ */ jsx("span", {
|
|
1752
|
+
className: "text-sm font-semibold",
|
|
1753
|
+
children: label
|
|
1754
|
+
})]
|
|
1755
|
+
})
|
|
1756
|
+
}), /* @__PURE__ */ jsx(CollapsibleContent, { children: /* @__PURE__ */ jsx("div", {
|
|
1757
|
+
className: "px-4 pb-4",
|
|
1758
|
+
children
|
|
1759
|
+
}) })]
|
|
1760
|
+
})
|
|
1761
|
+
});
|
|
1762
|
+
}
|
|
1763
|
+
function LinkedEntrySection({ section, hidden }) {
|
|
1764
|
+
if (!section) return null;
|
|
1765
|
+
return /* @__PURE__ */ jsx("div", {
|
|
1766
|
+
hidden,
|
|
1767
|
+
"data-design-takeover-sibling": true,
|
|
1768
|
+
children: /* @__PURE__ */ jsx(PreviewSidebarSection, {
|
|
1769
|
+
label: section.label,
|
|
1770
|
+
openRequestId: section.openRequestId,
|
|
1771
|
+
children: section.content
|
|
1772
|
+
})
|
|
1773
|
+
});
|
|
1774
|
+
}
|
|
1775
|
+
function DesignSection({ panel, takeover, controls }) {
|
|
1776
|
+
const open = takeover || controls.designOpen;
|
|
1777
|
+
return /* @__PURE__ */ jsx(Collapsible, {
|
|
1778
|
+
className: takeover ? "flex min-h-0 flex-1 flex-col overflow-hidden" : void 0,
|
|
1779
|
+
open,
|
|
1780
|
+
onOpenChange: (next) => {
|
|
1781
|
+
if (!takeover) controls.setDesignOpen(next);
|
|
1782
|
+
},
|
|
1783
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
1784
|
+
ref: controls.designSectionRef,
|
|
1785
|
+
className: takeover ? "flex min-h-0 flex-1 flex-col overflow-hidden" : "border-b",
|
|
1786
|
+
children: [/* @__PURE__ */ jsx(CollapsibleTrigger, {
|
|
1787
|
+
asChild: true,
|
|
1788
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
1789
|
+
className: `flex shrink-0 cursor-pointer items-center gap-2 px-4 py-3 hover:bg-accent/40 ${takeover ? "border-b" : ""}`,
|
|
1790
|
+
children: [/* @__PURE__ */ jsx(ChevronRight, { className: `h-4 w-4 transition ${open ? "rotate-90" : ""}` }), /* @__PURE__ */ jsx("span", {
|
|
1791
|
+
className: "text-sm font-semibold",
|
|
1792
|
+
children: "Design"
|
|
1793
|
+
})]
|
|
1794
|
+
})
|
|
1795
|
+
}), /* @__PURE__ */ jsx(CollapsibleContent, {
|
|
1796
|
+
className: takeover ? "min-h-0 flex-1 data-[state=open]:h-full data-[state=open]:overflow-hidden" : void 0,
|
|
1797
|
+
children: /* @__PURE__ */ jsx("div", {
|
|
1798
|
+
className: takeover ? "h-full min-h-0" : "px-4 pb-4",
|
|
1799
|
+
children: /* @__PURE__ */ jsx(PreviewDesignOpenRequestProvider, {
|
|
1800
|
+
request: controls.designOpenRequest,
|
|
1801
|
+
children: panel
|
|
1802
|
+
})
|
|
1803
|
+
})
|
|
1804
|
+
})]
|
|
1805
|
+
})
|
|
1806
|
+
});
|
|
1807
|
+
}
|
|
1808
|
+
//#endregion
|
|
1809
|
+
//#region ../preview-next/src/client/preview/PreviewFooterEditorPanel.tsx
|
|
1810
|
+
function PreviewFooterEditorPanel({ apiClient, siteId, dashboardBaseUrl, theme, selectionId, selectionVersion, siteStyleAccess, inspection, canEdit, onSaved }) {
|
|
1811
|
+
const dashboardSiteUrl = `${dashboardBaseUrl?.replace(/\/$/u, "") ?? ""}/dashboard/sites/${siteId}`;
|
|
1812
|
+
const navigationLayoutAccess = siteStyleAccess.kind === "apply-allowed" && theme && selectionVersion !== null ? {
|
|
1813
|
+
kind: "editable",
|
|
1814
|
+
theme,
|
|
1815
|
+
selectionId,
|
|
1816
|
+
selectionVersion
|
|
1817
|
+
} : { kind: "hidden" };
|
|
1818
|
+
return /* @__PURE__ */ jsx(FooterComposerPanel, {
|
|
1819
|
+
apiClient,
|
|
1820
|
+
siteId,
|
|
1821
|
+
customFooterMode: resolvePreviewFooterMode(theme?.footer.mode),
|
|
1822
|
+
manageLinksHref: `${dashboardSiteUrl}/navigation`,
|
|
1823
|
+
manageSettingsHref: `${dashboardSiteUrl}/settings`,
|
|
1824
|
+
legalRegion: theme?.footer.bottomBar?.enabled ? "separate" : "integrated",
|
|
1825
|
+
navigationLayoutAccess,
|
|
1826
|
+
loadingFallback: /* @__PURE__ */ jsx(ContentSpinner, { className: "py-8" }),
|
|
1827
|
+
initialTarget: inspection?.kind === "footer-module" ? {
|
|
1828
|
+
kind: "module",
|
|
1829
|
+
moduleId: inspection.moduleId
|
|
1830
|
+
} : { kind: "overview" },
|
|
1831
|
+
initialTargetRequestId: inspection?.requestId,
|
|
1832
|
+
variant: "sidebar",
|
|
1833
|
+
canEdit,
|
|
1834
|
+
onSaved
|
|
1835
|
+
});
|
|
1836
|
+
}
|
|
1837
|
+
function resolvePreviewFooterMode(value) {
|
|
1838
|
+
return value === "blocks" || value === "default+blocks" || value === "none" ? value : "default";
|
|
1839
|
+
}
|
|
1752
1840
|
//#endregion
|
|
1753
1841
|
//#region ../preview-next/src/client/preview/PreviewEditorGuidanceCard.tsx
|
|
1754
1842
|
function PreviewEditorGuidanceCard({ guidance, completeSetupDisabled, onCompleteSetup }) {
|
|
@@ -2315,6 +2403,20 @@ function familyKey(family) {
|
|
|
2315
2403
|
return family.trim().toLocaleLowerCase();
|
|
2316
2404
|
}
|
|
2317
2405
|
//#endregion
|
|
2406
|
+
//#region ../preview-next/src/client/preview/siteFontPreview.tsx
|
|
2407
|
+
function buildSiteFontFaceCss(siteFonts, siteFontStorageUrl) {
|
|
2408
|
+
if (!siteFontStorageUrl || siteFonts.length === 0) return "";
|
|
2409
|
+
return generateFontFaceCss([...siteFonts], getSiteFontsStorageUrl(siteFontStorageUrl));
|
|
2410
|
+
}
|
|
2411
|
+
function SiteFontFaceStyles({ siteFonts }) {
|
|
2412
|
+
const siteFontStorageUrl = usePreviewSiteFontStorageUrl();
|
|
2413
|
+
const css = useMemo(() => buildSiteFontFaceCss(siteFonts, siteFontStorageUrl), [siteFontStorageUrl, siteFonts]);
|
|
2414
|
+
return css ? /* @__PURE__ */ jsx("style", {
|
|
2415
|
+
"data-typography-site-fonts": true,
|
|
2416
|
+
children: css
|
|
2417
|
+
}) : null;
|
|
2418
|
+
}
|
|
2419
|
+
//#endregion
|
|
2318
2420
|
//#region ../preview-next/src/client/preview/StyleConfigurator.typography.tsx
|
|
2319
2421
|
const typographyOverviewSurface = { kind: "overview" };
|
|
2320
2422
|
function useTypographyFontCatalog(apiClient, siteId, enabled) {
|
|
@@ -2990,17 +3092,6 @@ function FontPreviewText({ family, source, className, children }) {
|
|
|
2990
3092
|
children
|
|
2991
3093
|
});
|
|
2992
3094
|
}
|
|
2993
|
-
function SiteFontFaceStyles({ siteFonts }) {
|
|
2994
|
-
const css = useMemo(() => {
|
|
2995
|
-
const supabaseUrl = process.env.NEXT_PUBLIC_SUPABASE_URL;
|
|
2996
|
-
if (!supabaseUrl || siteFonts.length === 0) return "";
|
|
2997
|
-
return generateFontFaceCss([...siteFonts], getSiteFontsStorageUrl(supabaseUrl));
|
|
2998
|
-
}, [siteFonts]);
|
|
2999
|
-
return css ? /* @__PURE__ */ jsx("style", {
|
|
3000
|
-
"data-typography-site-fonts": true,
|
|
3001
|
-
children: css
|
|
3002
|
-
}) : null;
|
|
3003
|
-
}
|
|
3004
3095
|
function ensureGoogleFontPreviewLink(family) {
|
|
3005
3096
|
const url = buildFontPreviewUrl(family);
|
|
3006
3097
|
if (Array.from(document.head.querySelectorAll("link[data-font-preview]")).some((link) => link.href === url)) return;
|
|
@@ -3232,7 +3323,7 @@ const PALETTE_SURFACE_ROLES = [
|
|
|
3232
3323
|
label: "Border"
|
|
3233
3324
|
}
|
|
3234
3325
|
];
|
|
3235
|
-
function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVersion = null, selectionUpdatedAt, initialSelections,
|
|
3326
|
+
function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVersion = null, selectionUpdatedAt, initialSelections, headerLogoContext, onFocusedSurfaceChange }) {
|
|
3236
3327
|
const designOpenRequest = usePreviewDesignOpenRequest();
|
|
3237
3328
|
const router = useRouter();
|
|
3238
3329
|
const previewDesign = usePreviewDesignCoordinator();
|
|
@@ -3247,9 +3338,9 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3247
3338
|
selectionVersion: initialSelections.selectionVersion ?? selectionVersion ?? 0,
|
|
3248
3339
|
selectionUpdatedAt: initialSelections.selectionUpdatedAt ?? selectionUpdatedAt ?? null
|
|
3249
3340
|
},
|
|
3250
|
-
|
|
3341
|
+
headerLogoContext
|
|
3251
3342
|
}), [
|
|
3252
|
-
|
|
3343
|
+
headerLogoContext,
|
|
3253
3344
|
theme,
|
|
3254
3345
|
initialSelections,
|
|
3255
3346
|
selectionUpdatedAt,
|
|
@@ -3308,7 +3399,7 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3308
3399
|
previewTheme("style-configurator", planSiteStylePreviewChange({
|
|
3309
3400
|
siteStyle,
|
|
3310
3401
|
selection: state.previewed,
|
|
3311
|
-
|
|
3402
|
+
headerLogoContext,
|
|
3312
3403
|
compilation: deriveSiteStylePreviewUpdate(theme, state.base)
|
|
3313
3404
|
}).themeOverlay, "site-style");
|
|
3314
3405
|
}, [
|
|
@@ -3316,7 +3407,7 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3316
3407
|
baseSnapshot,
|
|
3317
3408
|
clearPreview,
|
|
3318
3409
|
previewTheme,
|
|
3319
|
-
|
|
3410
|
+
headerLogoContext,
|
|
3320
3411
|
theme
|
|
3321
3412
|
]);
|
|
3322
3413
|
useEffect(() => {
|
|
@@ -3344,31 +3435,37 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3344
3435
|
const result = planSiteStylePreviewChange({
|
|
3345
3436
|
siteStyle,
|
|
3346
3437
|
selection: next.previewed,
|
|
3347
|
-
|
|
3438
|
+
headerLogoContext,
|
|
3348
3439
|
compilation: deriveSiteStylePreviewUpdate(theme, next.base)
|
|
3349
3440
|
});
|
|
3350
3441
|
return applyResolvedSelections(next, {
|
|
3351
3442
|
resolved: {
|
|
3352
3443
|
...result.resolvedSelections,
|
|
3444
|
+
headerLayoutId: result.resolvedSelections.headerSelection.layoutId,
|
|
3445
|
+
headerStyleId: result.resolvedSelections.headerSelection.styleId,
|
|
3353
3446
|
typography: result.themeOverlay.typography
|
|
3354
3447
|
},
|
|
3355
3448
|
warnings: result.warnings
|
|
3356
3449
|
});
|
|
3357
3450
|
});
|
|
3358
|
-
}, [
|
|
3451
|
+
}, [headerLogoContext, theme]);
|
|
3359
3452
|
const handlePreviewButtonStyle = useCallback((id) => {
|
|
3360
3453
|
setState((current) => current ? previewButtonStyle(current, id) : current);
|
|
3361
3454
|
}, []);
|
|
3362
3455
|
const handlePreviewHeaderLayout = useCallback((id) => {
|
|
3363
3456
|
if (!id) return;
|
|
3364
|
-
setState((current) =>
|
|
3457
|
+
setState((current) => {
|
|
3458
|
+
if (!current) return current;
|
|
3459
|
+
const siteStyle = getCuratedSiteStyle(current.previewed.siteStyleId);
|
|
3460
|
+
return siteStyle ? previewHeaderLayout(current, siteStyle, id) : current;
|
|
3461
|
+
});
|
|
3365
3462
|
}, []);
|
|
3366
3463
|
const handlePreviewHeaderStyle = useCallback((id) => {
|
|
3367
3464
|
if (!id) return;
|
|
3368
3465
|
setState((current) => current ? previewHeaderStyle(current, id) : current);
|
|
3369
3466
|
}, []);
|
|
3370
3467
|
const handlePreviewFooterLook = useCallback((id) => {
|
|
3371
|
-
const plan =
|
|
3468
|
+
const plan = planSiteChromeSelection({
|
|
3372
3469
|
surface: "footer",
|
|
3373
3470
|
lookId: id
|
|
3374
3471
|
});
|
|
@@ -3386,11 +3483,11 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3386
3483
|
return applyTypographyDraftPatch(current, planSiteStylePreviewChange({
|
|
3387
3484
|
siteStyle,
|
|
3388
3485
|
selection: current.previewed,
|
|
3389
|
-
|
|
3486
|
+
headerLogoContext,
|
|
3390
3487
|
compilation: deriveSiteStylePreviewUpdate(theme, current.base)
|
|
3391
3488
|
}).themeOverlay.typography, patch);
|
|
3392
3489
|
});
|
|
3393
|
-
}, [
|
|
3490
|
+
}, [headerLogoContext, theme]);
|
|
3394
3491
|
const handleHeadingTypographyChange = useCallback((patch) => {
|
|
3395
3492
|
patchTypography({
|
|
3396
3493
|
kind: "heading",
|
|
@@ -3481,7 +3578,6 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3481
3578
|
});
|
|
3482
3579
|
}, [
|
|
3483
3580
|
apiClient,
|
|
3484
|
-
headerSelectionContext,
|
|
3485
3581
|
applyFailed,
|
|
3486
3582
|
applyStarted,
|
|
3487
3583
|
applySucceeded,
|
|
@@ -3489,14 +3585,12 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3489
3585
|
selectionId,
|
|
3490
3586
|
siteChromeCustomize?.siteStyleHistory,
|
|
3491
3587
|
siteId,
|
|
3492
|
-
startRefreshTransition
|
|
3493
|
-
theme
|
|
3588
|
+
startRefreshTransition
|
|
3494
3589
|
]);
|
|
3495
3590
|
if (!state || !baseSnapshot) return /* @__PURE__ */ jsx("p", {
|
|
3496
3591
|
className: "text-sm text-muted-foreground",
|
|
3497
3592
|
children: "Loading design controls..."
|
|
3498
3593
|
});
|
|
3499
|
-
const applyAllowed = canApplySiteStyle(siteStyleAccess);
|
|
3500
3594
|
const stagedCapabilities = deriveStyleConfiguratorCapabilities(state);
|
|
3501
3595
|
const previewingChange = isPreviewingChange(state);
|
|
3502
3596
|
const saving = stagedCapabilities.isApplyingStaged || isRefreshPending;
|
|
@@ -3511,18 +3605,18 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3511
3605
|
const currentPreviewPlan = planSiteStylePreviewChange({
|
|
3512
3606
|
siteStyle: currentSiteStyle,
|
|
3513
3607
|
selection: state.previewed,
|
|
3514
|
-
|
|
3608
|
+
headerLogoContext,
|
|
3515
3609
|
compilation: deriveSiteStylePreviewUpdate(theme, state.base)
|
|
3516
3610
|
});
|
|
3517
3611
|
const currentTypography = currentPreviewPlan.themeOverlay.typography;
|
|
3518
|
-
const
|
|
3612
|
+
const chromeSelectionModels = buildSiteChromeSelectionModels({
|
|
3519
3613
|
state,
|
|
3520
3614
|
siteStyle: currentSiteStyle,
|
|
3521
|
-
|
|
3615
|
+
headerLogoContext
|
|
3522
3616
|
});
|
|
3523
3617
|
const currentHeaderLayout = getHeaderLayout(state.previewed.headerLayoutId);
|
|
3524
3618
|
const currentHeaderStyle = getHeaderStyle(state.previewed.headerStyleId);
|
|
3525
|
-
const currentFooterLook = state.previewed.footerLookId ? findFooterLook(state.previewed.footerLookId) : findFooterLook(
|
|
3619
|
+
const currentFooterLook = state.previewed.footerLookId ? findFooterLook(state.previewed.footerLookId) : findFooterLook(chromeSelectionModels.footer.renderedLookId);
|
|
3526
3620
|
const headerSurfaceState = siteChromeCustomize?.getSurfaceState("header") ?? { kind: "unavailable" };
|
|
3527
3621
|
if (state.expandedRow === "typography" && typographySurface.kind !== "overview") return /* @__PURE__ */ jsxs("div", {
|
|
3528
3622
|
className: "flex h-full min-h-0 flex-col",
|
|
@@ -3546,7 +3640,6 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3546
3640
|
className: "shrink-0 px-3 pb-3",
|
|
3547
3641
|
children: /* @__PURE__ */ jsx(StyleConfiguratorSaveControls, {
|
|
3548
3642
|
previewingChange,
|
|
3549
|
-
applyAllowed,
|
|
3550
3643
|
saving,
|
|
3551
3644
|
canCancel: stagedCapabilities.canCancelStaged,
|
|
3552
3645
|
canApply: stagedCapabilities.canApplyStaged,
|
|
@@ -3571,37 +3664,37 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3571
3664
|
onPreview: handlePreviewSiteStyle,
|
|
3572
3665
|
disabled: aggregateMutationControlsDisabled
|
|
3573
3666
|
}),
|
|
3574
|
-
/* @__PURE__ */ jsx(
|
|
3667
|
+
/* @__PURE__ */ jsx(SiteChromeSelectionRow, {
|
|
3575
3668
|
label: "Header layout",
|
|
3576
3669
|
ariaLabel: "Header layout",
|
|
3577
3670
|
defaultDescription: "Choose the header structure.",
|
|
3578
3671
|
expanded: state.expandedRow === "header-layout",
|
|
3579
3672
|
onToggle: () => handleToggleRow("header-layout"),
|
|
3580
3673
|
currentId: state.previewed.headerLayoutId,
|
|
3581
|
-
currentLabel: currentHeaderLayout
|
|
3674
|
+
currentLabel: currentHeaderLayout.label,
|
|
3582
3675
|
scopeDescription: "Changes the header structure on every page.",
|
|
3583
|
-
options:
|
|
3676
|
+
options: chromeSelectionModels.headerLayout.options,
|
|
3584
3677
|
diagnostics: [],
|
|
3585
3678
|
onCycle: (direction) => {
|
|
3586
|
-
const next =
|
|
3679
|
+
const next = cycleSiteChromeSelectionId(chromeSelectionModels.headerLayout.options, state.previewed.headerLayoutId, direction);
|
|
3587
3680
|
if (next !== void 0) handlePreviewHeaderLayout(next);
|
|
3588
3681
|
},
|
|
3589
3682
|
onPreview: handlePreviewHeaderLayout,
|
|
3590
3683
|
disabled: aggregateMutationControlsDisabled
|
|
3591
3684
|
}),
|
|
3592
|
-
/* @__PURE__ */ jsx(
|
|
3593
|
-
label: "Header
|
|
3594
|
-
ariaLabel: "Header
|
|
3685
|
+
/* @__PURE__ */ jsx(SiteChromeSelectionRow, {
|
|
3686
|
+
label: "Header style",
|
|
3687
|
+
ariaLabel: "Header style",
|
|
3595
3688
|
defaultDescription: "Choose the header visual style.",
|
|
3596
3689
|
expanded: state.expandedRow === "header-style",
|
|
3597
3690
|
onToggle: () => handleToggleRow("header-style"),
|
|
3598
3691
|
currentId: state.previewed.headerStyleId,
|
|
3599
|
-
currentLabel: currentHeaderStyle
|
|
3692
|
+
currentLabel: currentHeaderStyle.label,
|
|
3600
3693
|
scopeDescription: "Changes the header surface and link style.",
|
|
3601
|
-
options:
|
|
3694
|
+
options: chromeSelectionModels.headerStyle.options,
|
|
3602
3695
|
diagnostics: [],
|
|
3603
3696
|
onCycle: (direction) => {
|
|
3604
|
-
const next =
|
|
3697
|
+
const next = cycleSiteChromeSelectionId(chromeSelectionModels.headerStyle.options, state.previewed.headerStyleId, direction);
|
|
3605
3698
|
if (next !== void 0) handlePreviewHeaderStyle(next);
|
|
3606
3699
|
},
|
|
3607
3700
|
onPreview: handlePreviewHeaderStyle,
|
|
@@ -3613,7 +3706,7 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3613
3706
|
onMenuFontSizeChange: siteChromeCustomize?.setHeaderMenuFontSize
|
|
3614
3707
|
}) : null
|
|
3615
3708
|
}),
|
|
3616
|
-
/* @__PURE__ */ jsx(
|
|
3709
|
+
/* @__PURE__ */ jsx(SiteChromeSelectionRow, {
|
|
3617
3710
|
label: "Footer links",
|
|
3618
3711
|
ariaLabel: "Footer link treatment",
|
|
3619
3712
|
defaultDescription: "Use the footer link treatment chosen for this site style.",
|
|
@@ -3622,10 +3715,10 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3622
3715
|
currentId: state.previewed.footerLookId,
|
|
3623
3716
|
currentLabel: state.previewed.footerLookId ? currentFooterLook?.label ?? "Unknown footer link treatment" : `${currentFooterLook?.label ?? "Site style"} (default)`,
|
|
3624
3717
|
scopeDescription: "Changes footer navigation links on every page.",
|
|
3625
|
-
options:
|
|
3626
|
-
diagnostics:
|
|
3718
|
+
options: chromeSelectionModels.footer.options,
|
|
3719
|
+
diagnostics: chromeSelectionModels.footer.diagnostics,
|
|
3627
3720
|
onCycle: (direction) => {
|
|
3628
|
-
const next =
|
|
3721
|
+
const next = cycleSiteChromeSelectionId(chromeSelectionModels.footer.options, state.previewed.footerLookId, direction);
|
|
3629
3722
|
if (next !== void 0) handlePreviewFooterLook(next);
|
|
3630
3723
|
},
|
|
3631
3724
|
onPreview: handlePreviewFooterLook,
|
|
@@ -3661,12 +3754,11 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3661
3754
|
palette: currentPalette,
|
|
3662
3755
|
onPreview: handlePreviewPalette,
|
|
3663
3756
|
onTokenChange: handleTokenOverride,
|
|
3664
|
-
disabled: saving
|
|
3665
|
-
mutationDisabled: paletteControlsDisabled
|
|
3757
|
+
disabled: saving,
|
|
3758
|
+
mutationDisabled: paletteControlsDisabled
|
|
3666
3759
|
}),
|
|
3667
3760
|
/* @__PURE__ */ jsx(StyleConfiguratorSaveControls, {
|
|
3668
3761
|
previewingChange,
|
|
3669
|
-
applyAllowed,
|
|
3670
3762
|
saving,
|
|
3671
3763
|
canCancel: stagedCapabilities.canCancelStaged,
|
|
3672
3764
|
canApply: stagedCapabilities.canApplyStaged,
|
|
@@ -3678,7 +3770,7 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3678
3770
|
]
|
|
3679
3771
|
});
|
|
3680
3772
|
}
|
|
3681
|
-
function StyleConfiguratorSaveControls({ previewingChange,
|
|
3773
|
+
function StyleConfiguratorSaveControls({ previewingChange, saving, canCancel, canApply, saveStatus, onCancel, onApply, onRetry }) {
|
|
3682
3774
|
return /* @__PURE__ */ jsxs(Fragment$1, { children: [
|
|
3683
3775
|
previewingChange ? /* @__PURE__ */ jsxs("div", {
|
|
3684
3776
|
className: "flex items-center gap-2 pt-2",
|
|
@@ -3689,15 +3781,12 @@ function StyleConfiguratorSaveControls({ previewingChange, applyAllowed, saving,
|
|
|
3689
3781
|
onClick: onCancel,
|
|
3690
3782
|
disabled: !canCancel || saving,
|
|
3691
3783
|
children: "Cancel"
|
|
3692
|
-
}),
|
|
3784
|
+
}), /* @__PURE__ */ jsx(Button, {
|
|
3693
3785
|
type: "button",
|
|
3694
3786
|
size: "sm",
|
|
3695
3787
|
onClick: onApply,
|
|
3696
3788
|
disabled: !canApply || saving,
|
|
3697
3789
|
children: saving ? "Applying…" : "Apply"
|
|
3698
|
-
}) : /* @__PURE__ */ jsx("span", {
|
|
3699
|
-
className: "text-xs text-muted-foreground",
|
|
3700
|
-
children: "Preview only — ask an admin to apply."
|
|
3701
3790
|
})]
|
|
3702
3791
|
}) : null,
|
|
3703
3792
|
saveStatus.kind === "saved" ? /* @__PURE__ */ jsx("p", {
|
|
@@ -3707,7 +3796,7 @@ function StyleConfiguratorSaveControls({ previewingChange, applyAllowed, saving,
|
|
|
3707
3796
|
saveStatus.kind === "failed" ? /* @__PURE__ */ jsxs("div", {
|
|
3708
3797
|
role: "status",
|
|
3709
3798
|
className: "flex items-center gap-2 text-xs text-destructive",
|
|
3710
|
-
children: [/* @__PURE__ */ jsx("span", { children: saveStatus.message }), saveStatus.failureKind === "stale" && previewingChange
|
|
3799
|
+
children: [/* @__PURE__ */ jsx("span", { children: saveStatus.message }), saveStatus.failureKind === "stale" && previewingChange ? /* @__PURE__ */ jsx(Button, {
|
|
3711
3800
|
type: "button",
|
|
3712
3801
|
size: "sm",
|
|
3713
3802
|
variant: "outline",
|
|
@@ -3815,15 +3904,11 @@ function TypographyRow({ expanded, onToggle, typography, catalog, currentLabel,
|
|
|
3815
3904
|
})
|
|
3816
3905
|
});
|
|
3817
3906
|
}
|
|
3818
|
-
function
|
|
3907
|
+
function SiteChromeSelectionRow({ label, ariaLabel, defaultDescription, catalog, options = [{
|
|
3819
3908
|
id: null,
|
|
3820
3909
|
label: "Site style default",
|
|
3821
|
-
description: defaultDescription
|
|
3822
|
-
|
|
3823
|
-
}, ...(catalog ?? []).map((look) => ({
|
|
3824
|
-
...look,
|
|
3825
|
-
available: true
|
|
3826
|
-
}))], diagnostics, scopeDescription, expanded, onToggle, currentId, currentLabel, onCycle, onPreview, disabled, extraControls }) {
|
|
3910
|
+
description: defaultDescription
|
|
3911
|
+
}, ...catalog ?? []], diagnostics, scopeDescription, expanded, onToggle, currentId, currentLabel, onCycle, onPreview, disabled, extraControls }) {
|
|
3827
3912
|
return /* @__PURE__ */ jsxs(StyleRowFrame, {
|
|
3828
3913
|
label,
|
|
3829
3914
|
currentLabel,
|
|
@@ -3842,14 +3927,14 @@ function SiteChromeLookRow({ label, ariaLabel, defaultDescription, catalog, opti
|
|
|
3842
3927
|
onClick: () => onCycle("prev"),
|
|
3843
3928
|
className: "grid h-8 w-8 place-items-center hover:bg-muted disabled:cursor-not-allowed disabled:opacity-50",
|
|
3844
3929
|
"aria-label": `Previous ${label.toLowerCase()}`,
|
|
3845
|
-
disabled: disabled ||
|
|
3930
|
+
disabled: disabled || options.length <= 1,
|
|
3846
3931
|
children: /* @__PURE__ */ jsx(ChevronLeft, { size: 14 })
|
|
3847
3932
|
}), /* @__PURE__ */ jsx("button", {
|
|
3848
3933
|
type: "button",
|
|
3849
3934
|
onClick: () => onCycle("next"),
|
|
3850
3935
|
className: "grid h-8 w-8 place-items-center border-l hover:bg-muted disabled:cursor-not-allowed disabled:opacity-50",
|
|
3851
3936
|
"aria-label": `Next ${label.toLowerCase()}`,
|
|
3852
|
-
disabled: disabled ||
|
|
3937
|
+
disabled: disabled || options.length <= 1,
|
|
3853
3938
|
children: /* @__PURE__ */ jsx(ChevronRight, { size: 14 })
|
|
3854
3939
|
})]
|
|
3855
3940
|
})]
|
|
@@ -3869,9 +3954,9 @@ function SiteChromeLookRow({ label, ariaLabel, defaultDescription, catalog, opti
|
|
|
3869
3954
|
children: options.map((look) => /* @__PURE__ */ jsx(PickerOption, {
|
|
3870
3955
|
selected: look.id === currentId,
|
|
3871
3956
|
label: look.label,
|
|
3872
|
-
description: look.
|
|
3957
|
+
description: look.description,
|
|
3873
3958
|
onSelect: () => onPreview(look.id),
|
|
3874
|
-
disabled
|
|
3959
|
+
disabled
|
|
3875
3960
|
}, look.id ?? "site-style-default"))
|
|
3876
3961
|
})
|
|
3877
3962
|
]
|
|
@@ -4077,11 +4162,14 @@ function WarningNotice({ warnings, onDismiss }) {
|
|
|
4077
4162
|
});
|
|
4078
4163
|
}
|
|
4079
4164
|
function describeWarning(warning) {
|
|
4080
|
-
|
|
4165
|
+
switch (warning.kind) {
|
|
4166
|
+
case "rejected-button-style": return `Button style changed to ${warning.fellBackTo.styleId} because ${warning.requested} is not offered for this site style.`;
|
|
4167
|
+
case "repaired-header-selection": return `Header changed to ${warning.resolved.layoutId} / ${warning.resolved.styleId} because the requested combination is not offered for this site style.`;
|
|
4168
|
+
}
|
|
4081
4169
|
}
|
|
4082
4170
|
//#endregion
|
|
4083
4171
|
//#region ../preview-next/src/client/preview/PreviewEditorSidebar.tsx
|
|
4084
|
-
function PreviewEditorSidebar({ surfaceId, siteId, dashboardBaseUrl = null, pageId, entryData, contentTypeSchema, referenceContentTypeKeys = [], draftContent, currentTemplate, theme, themeId = null, themeSelectionId = null, themeSelectionVersion = null, themeSelectionUpdatedAt = null, themeSelectionButtonStyleSelection = null,
|
|
4172
|
+
function PreviewEditorSidebar({ surfaceId, siteId, dashboardBaseUrl = null, pageId, entryData, contentTypeSchema, referenceContentTypeKeys = [], draftContent, currentTemplate, theme, themeId = null, themeSelectionId = null, themeSelectionVersion = null, themeSelectionUpdatedAt = null, themeSelectionButtonStyleSelection = null, themeSelectionHeaderSelection = null, themeSelectionFooterLookId = null, themeSelectionHeaderLogo, apiClient, bearerToken, entrySubrouteContext, assistantPanel, sdkConfig, bookingOfferingPresets, siteStyleAccess = { kind: "hidden" }, activeTab, onTabChange, onClose, onFooterSaved, viewportMode, viewportWidth, zoom, onViewportModeChange, onViewportWidthChange, onZoomChange }) {
|
|
4085
4173
|
const controller = useEntryController();
|
|
4086
4174
|
const controllerBlocks = controller.blocks;
|
|
4087
4175
|
const uiStore = useEditorUiStoreInstance();
|
|
@@ -4168,7 +4256,20 @@ function PreviewEditorSidebar({ surfaceId, siteId, dashboardBaseUrl = null, page
|
|
|
4168
4256
|
fields: findLinkedEntryManifestFieldsFromSnapshot(snapshot)
|
|
4169
4257
|
})
|
|
4170
4258
|
});
|
|
4171
|
-
const
|
|
4259
|
+
const footerInspection = previewInspection.kind === "footer" || previewInspection.kind === "footer-module" ? previewInspection : null;
|
|
4260
|
+
const footerPanel = /* @__PURE__ */ jsx(PreviewFooterEditorPanel, {
|
|
4261
|
+
apiClient,
|
|
4262
|
+
siteId,
|
|
4263
|
+
dashboardBaseUrl,
|
|
4264
|
+
theme: theme ?? null,
|
|
4265
|
+
selectionId: themeSelectionId,
|
|
4266
|
+
selectionVersion: themeSelectionVersion,
|
|
4267
|
+
siteStyleAccess,
|
|
4268
|
+
inspection: footerInspection,
|
|
4269
|
+
canEdit,
|
|
4270
|
+
onSaved: onFooterSaved
|
|
4271
|
+
});
|
|
4272
|
+
const editorPanel = footerInspection && (entryData || !pageId) ? footerPanel : entryData ? /* @__PURE__ */ jsx(EntryEditorPanel, {
|
|
4172
4273
|
siteId,
|
|
4173
4274
|
dashboardBaseUrl,
|
|
4174
4275
|
entryData,
|
|
@@ -4213,15 +4314,13 @@ function PreviewEditorSidebar({ surfaceId, siteId, dashboardBaseUrl = null, page
|
|
|
4213
4314
|
selectionVersion: themeSelectionVersion,
|
|
4214
4315
|
selectionUpdatedAt: themeSelectionUpdatedAt,
|
|
4215
4316
|
buttonStyleSelection: themeSelectionButtonStyleSelection,
|
|
4216
|
-
|
|
4217
|
-
headerStyleId: themeSelectionHeaderStyleId,
|
|
4218
|
-
headerLookId: themeSelectionHeaderLookId,
|
|
4317
|
+
headerSelection: themeSelectionHeaderSelection,
|
|
4219
4318
|
footerLookId: themeSelectionFooterLookId
|
|
4220
4319
|
},
|
|
4221
|
-
|
|
4222
|
-
onFocusedSurfaceChange: setDesignTakeoverActive
|
|
4223
|
-
siteStyleAccess
|
|
4320
|
+
headerLogoContext: themeSelectionHeaderLogo,
|
|
4321
|
+
onFocusedSurfaceChange: setDesignTakeoverActive
|
|
4224
4322
|
}) : null,
|
|
4323
|
+
footerPanel,
|
|
4225
4324
|
sdkConfig: sdkConfig ?? null,
|
|
4226
4325
|
bookingOfferingPresets,
|
|
4227
4326
|
linkedEntrySection,
|
|
@@ -4241,25 +4340,6 @@ function PreviewEditorSidebar({ surfaceId, siteId, dashboardBaseUrl = null, page
|
|
|
4241
4340
|
})
|
|
4242
4341
|
})
|
|
4243
4342
|
});
|
|
4244
|
-
const resolvedEditorPanel = previewInspection.kind === "footer-module" || previewInspection.kind === "footer" ? /* @__PURE__ */ jsx("div", {
|
|
4245
|
-
className: "h-full overflow-y-auto",
|
|
4246
|
-
children: /* @__PURE__ */ jsx(FooterComposerPanel, {
|
|
4247
|
-
apiClient,
|
|
4248
|
-
siteId,
|
|
4249
|
-
customFooterMode: resolvePreviewFooterMode(theme?.footer?.mode),
|
|
4250
|
-
manageLinksHref: `${dashboardBaseUrl?.replace(/\/$/u, "") ?? ""}/dashboard/sites/${siteId}/navigation`,
|
|
4251
|
-
manageSettingsHref: `${dashboardBaseUrl?.replace(/\/$/u, "") ?? ""}/dashboard/sites/${siteId}/settings`,
|
|
4252
|
-
legalRegion: theme?.footer?.bottomBar?.enabled === true ? "separate" : "integrated",
|
|
4253
|
-
loadingFallback: /* @__PURE__ */ jsx(ContentSpinner, { className: "py-8" }),
|
|
4254
|
-
initialTarget: previewInspection.kind === "footer-module" ? {
|
|
4255
|
-
kind: "module",
|
|
4256
|
-
moduleId: previewInspection.moduleId
|
|
4257
|
-
} : { kind: "overview" },
|
|
4258
|
-
variant: "sidebar",
|
|
4259
|
-
canEdit,
|
|
4260
|
-
onSaved: onFooterSaved
|
|
4261
|
-
})
|
|
4262
|
-
}) : editorPanel;
|
|
4263
4343
|
const assistantPanelDisplay = assistantAvailable ? assistantPanel : /* @__PURE__ */ jsx("div", {
|
|
4264
4344
|
className: "flex h-full flex-col items-center justify-center p-6 text-center text-sm text-muted-foreground",
|
|
4265
4345
|
children: "AI Assistant is available for pages in preview mode."
|
|
@@ -4306,7 +4386,7 @@ function PreviewEditorSidebar({ surfaceId, siteId, dashboardBaseUrl = null, page
|
|
|
4306
4386
|
value: "editor",
|
|
4307
4387
|
forceMount: true,
|
|
4308
4388
|
className: "mt-0 min-h-0 flex-1 overflow-hidden data-[state=inactive]:hidden",
|
|
4309
|
-
children:
|
|
4389
|
+
children: editorPanel
|
|
4310
4390
|
}),
|
|
4311
4391
|
showAssistantTab ? /* @__PURE__ */ jsx(TabsContent, {
|
|
4312
4392
|
value: "assistant",
|
|
@@ -4318,9 +4398,6 @@ function PreviewEditorSidebar({ surfaceId, siteId, dashboardBaseUrl = null, page
|
|
|
4318
4398
|
})
|
|
4319
4399
|
});
|
|
4320
4400
|
}
|
|
4321
|
-
function resolvePreviewFooterMode(value) {
|
|
4322
|
-
return value === "blocks" || value === "default+blocks" || value === "none" ? value : "default";
|
|
4323
|
-
}
|
|
4324
4401
|
function PreviewMetadataPanel({ ownerKind, contentTypeKey, entry }) {
|
|
4325
4402
|
const uiStore = useEditorUiStoreInstance();
|
|
4326
4403
|
const currentSlug = useEditorUiStore((state) => state.metadata.getAtPath("draftSlug")) ?? void 0;
|