@riverbankcms/sdk 0.108.0 → 0.109.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +21 -1
- package/dist/{PreviewEditorSidebar-BBT-kZAM.mjs → PreviewEditorSidebar-DWqwfy3_.mjs} +7 -22
- package/dist/{PreviewEditorUI-D69xNKT2.mjs → PreviewEditorUI-B7OL4sfR.mjs} +3 -3
- package/dist/{PreviewQueryProvider-RRu7wyQ5.mjs → PreviewQueryProvider-D0y2l8JN.mjs} +1 -1
- package/dist/{SdkPreviewModeRuntime-CuDjXH6o.mjs → SdkPreviewModeRuntime-D8Gt9Gbe.mjs} +212 -153
- package/dist/{SiteChromeCustomizeContext-BQUY2dEk.mjs → SiteChromeCustomizeContext-DUpalEdL.mjs} +1919 -1032
- package/dist/_dts/ai/src/contracts/proposals.d.ts +11244 -10741
- package/dist/_dts/api/src/bookingAdjustments.d.ts +5 -0
- package/dist/_dts/api/src/bookingOperations.d.ts +4 -0
- package/dist/_dts/api/src/bookingRecords.d.ts +2 -17
- package/dist/_dts/api/src/bookingRefundOutcomes.d.ts +6 -6
- package/dist/_dts/api/src/common/envelope.d.ts +7 -0
- package/dist/_dts/api/src/courses.d.ts +1 -0
- package/dist/_dts/api/src/customerMembershipOutcomes.d.ts +5 -5
- package/dist/_dts/api/src/endpoints.d.ts +35 -0
- package/dist/_dts/api/src/index.d.ts +2 -2
- package/dist/_dts/api/src/participantMessaging.d.ts +18 -12
- package/dist/_dts/api/src/publicExperienceEndpoints.d.ts +1 -0
- package/dist/_dts/api/src/sdkContracts.d.ts +247 -1
- package/dist/_dts/api/src/siteInfrastructure.d.ts +13 -0
- package/dist/_dts/api/src/siteManagementEndpoints.d.ts +1 -5
- package/dist/_dts/api/src/sitePlatformEndpoints.d.ts +29 -1
- package/dist/_dts/api/src/siteRuntimeEndpoints.d.ts +33 -27
- package/dist/_dts/block-form/src/widgets/BackgroundGradientWidget/BackgroundGradientField.d.ts +9 -0
- package/dist/_dts/block-form/src/widgets/BackgroundGradientWidget/BackgroundGradientWidget.d.ts +3 -4
- package/dist/_dts/blocks/src/contracts/proof-block-islands.d.ts +4 -4
- package/dist/_dts/blocks/src/index.d.ts +1 -1
- package/dist/_dts/blocks/src/system/blocks/audio-player.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/body-text.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/contact-newsletter.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/course-registration.d.ts +1 -22
- package/dist/_dts/blocks/src/system/blocks/cta-full.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/event-registration.d.ts +1 -22
- package/dist/_dts/blocks/src/system/blocks/file-download.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/form.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/image-gallery.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/media-text.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/newsletter-signup.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/site-header.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/team-members.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/testimonials.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/video-grid.d.ts +3 -0
- package/dist/_dts/blocks/src/system/constants/background.d.ts +1 -1
- package/dist/_dts/blocks/src/system/customize/backgrounds.d.ts +16 -6
- package/dist/_dts/blocks/src/system/defineBlock.d.ts +9 -1
- package/dist/_dts/blocks/src/system/fields/ctas.d.ts +8 -0
- package/dist/_dts/blocks/src/system/manifest/schema.d.ts +31 -0
- package/dist/_dts/blocks/src/system/runtime/components/registry.client.d.ts +6 -6
- package/dist/_dts/blocks/src/system/runtime/components/runtime-backed-blocks.d.ts +3 -3
- package/dist/_dts/blocks/src/system/runtime/nodes/shared/contract-schemas.d.ts +1 -1
- package/dist/_dts/content-model/src/content-types/entryValidation.d.ts +31 -0
- package/dist/_dts/content-model/src/content-types/scaffold.d.ts +58 -0
- package/dist/_dts/content-model/src/content-types/sentinels.d.ts +36 -0
- package/dist/_dts/content-model/src/index.d.ts +3 -0
- package/dist/_dts/core/src/booking-date-time.d.ts +8 -0
- package/dist/_dts/db/src/generated/supabase/database.types.d.ts +3071 -3157
- package/dist/_dts/media-core/src/fileMimeDetection.d.ts +16 -0
- package/dist/_dts/media-core/src/fileStorage.d.ts +8 -0
- package/dist/_dts/media-core/src/storagePathDomain.d.ts +2 -0
- package/dist/_dts/media-core/src/uploadVerificationContract.d.ts +3 -0
- package/dist/_dts/preview-next/src/client/blocks/BlockToolbar.d.ts +2 -0
- package/dist/_dts/preview-next/src/client/preview/StyleConfigurator.state.d.ts +1 -0
- package/dist/_dts/preview-next/src/client/preview/styleConfiguratorApplyPayload.d.ts +1 -1
- package/dist/_dts/sdk/src/cli/commands/audit.d.ts +1 -1
- package/dist/_dts/sdk/src/cli/commands/compare.d.ts +1 -1
- package/dist/_dts/sdk/src/cli/commands/deploy.d.ts +1 -1
- package/dist/_dts/sdk/src/cli/commands/drafts.d.ts +18 -0
- package/dist/_dts/sdk/src/cli/commands/entry.d.ts +15 -0
- package/dist/_dts/sdk/src/cli/commands/init-docs.d.ts +2 -2
- package/dist/_dts/sdk/src/cli/commands/publish-all.d.ts +1 -1
- package/dist/_dts/sdk/src/cli/commands/pull.d.ts +1 -0
- package/dist/_dts/sdk/src/cli/commands/push/execute/diff.d.ts +1 -1
- package/dist/_dts/sdk/src/cli/commands/push/options.d.ts +3 -0
- package/dist/_dts/sdk/src/cli/commands/push-execute.d.ts +12 -1
- package/dist/_dts/sdk/src/cli/commands/setup.d.ts +1 -0
- package/dist/_dts/sdk/src/cli/commands/verify.d.ts +1 -0
- package/dist/_dts/sdk/src/cli/helpers.d.ts +22 -1
- package/dist/_dts/sdk/src/cli/index.d.ts +4 -0
- package/dist/_dts/sdk/src/cli/output.d.ts +88 -0
- package/dist/_dts/sdk/src/cli/program.d.ts +29 -0
- package/dist/_dts/sdk/src/cli/push-config.d.ts +1 -1
- package/dist/_dts/sdk/src/client/management/catalog.d.ts +10 -0
- package/dist/_dts/sdk/src/client/management/http.d.ts +7 -1
- package/dist/_dts/sdk/src/client/management/index.d.ts +1 -1
- package/dist/_dts/sdk/src/client/management/types.d.ts +43 -19
- package/dist/_dts/sdk/src/date-time/index.d.ts +68 -0
- package/dist/_dts/sdk/src/public-api/contracts.d.ts +2 -0
- package/dist/_dts/sdk/src/version.d.ts +1 -1
- package/dist/_dts/site-commands/src/commands.d.ts +893 -823
- package/dist/_dts/theme-core/src/accordions/types.d.ts +1 -1
- package/dist/_dts/theme-core/src/buttons/core.d.ts +15 -46
- package/dist/_dts/theme-core/src/buttons/effectClassification.d.ts +147 -0
- package/dist/_dts/theme-core/src/buttons/effects/types.d.ts +2 -3
- package/dist/_dts/theme-core/src/buttons/generateDefaultButtonSystem.d.ts +1 -1
- package/dist/_dts/theme-core/src/buttons/index.d.ts +1 -0
- package/dist/_dts/theme-core/src/buttons/personalities/types.d.ts +44 -32
- package/dist/_dts/theme-core/src/buttons/presets.d.ts +4 -25
- package/dist/_dts/theme-core/src/buttons/resolveButtonColourStates.d.ts +100 -0
- package/dist/_dts/theme-core/src/buttons/resolvedButtonCss.d.ts +16 -0
- package/dist/_dts/theme-core/src/buttons/types.d.ts +101 -83
- package/dist/_dts/theme-core/src/cards/types.d.ts +16 -16
- package/dist/_dts/theme-core/src/generated/containerResponsiveThemeCss.d.ts +1 -1
- package/dist/_dts/theme-core/src/gradients/presets.d.ts +200 -8
- package/dist/_dts/theme-core/src/gradients/utils.d.ts +6 -2
- package/dist/_dts/theme-core/src/mock-themes/all.d.ts +87 -126
- package/dist/_dts/theme-core/src/mock-themes/modern-minimal.d.ts +1 -1
- package/dist/_dts/theme-core/src/navigation/types.d.ts +2 -2
- package/dist/_dts/theme-core/src/palette/curated/index.d.ts +2 -2
- package/dist/_dts/theme-core/src/palette/curated/types.d.ts +5 -8
- package/dist/_dts/theme-core/src/palette/index.d.ts +0 -1
- package/dist/_dts/theme-core/src/schema.d.ts +112 -138
- package/dist/_dts/theme-core/src/site-styles/backgroundAppearance.d.ts +2 -2
- package/dist/_dts/theme-core/src/site-styles/designState.d.ts +10 -10
- package/dist/_dts/theme-core/src/site-styles/pageDesignEditorModel.d.ts +3 -2
- package/dist/_dts/theme-core/src/site-styles/pageDesignIntent.d.ts +13 -6
- package/dist/_dts/theme-core/src/site-styles/runtimeCompiler.d.ts +29 -8
- package/dist/_dts/theme-core/src/site-styles/styleTags.d.ts +2 -2
- package/dist/cli/index.mjs +67956 -66745
- package/dist/cli/init-docs/content/cli-reference.md +50 -7
- package/dist/cli/init-docs/content/content-management.md +7 -4
- package/dist/cli/init-docs/content/workflow-publish.md +5 -1
- package/dist/client/{DiscountCodeDisclosure-D6TOf6Hi.mjs → DiscountCodeDisclosure-DU1ygxU2.mjs} +1 -1
- package/dist/client/{EventCombined.client-Dao3zxRk.mjs → EventCombined.client-DB5zagCo.mjs} +3 -3
- package/dist/client/{EventListing.client-B2NNt4y1.mjs → EventListing.client-CTX9JHBL.mjs} +2 -2
- package/dist/client/{LeafletStaticMap-BhwFo16w.mjs → LeafletStaticMap-BYImhgiB.mjs} +1 -1
- package/dist/client/{MagicLinkForm-BWnB7cMR.mjs → MagicLinkForm-CRkw_M3l.mjs} +2 -2
- package/dist/client/{StepIndicator-TzRiQ0BY.mjs → StepIndicator-BnmVBJJh.mjs} +2 -2
- package/dist/client/{accordion-BPy-AJ4_.mjs → accordion-CeGreumd.mjs} +1 -1
- package/dist/client/{bookingForm-BL4PGZds.mjs → bookingForm-CSzFNrpN.mjs} +6 -6
- package/dist/client/bookings.mjs +512 -252
- package/dist/client/{buttons-EBjyslaX.mjs → buttons-DoFV7KDL.mjs} +493 -230
- package/dist/client/{carousel-C2b7Cn9-.mjs → carousel-B2jDtogf.mjs} +1 -1
- package/dist/client/{cart-BQcbXIVD.mjs → cart-D-jZ-vaY.mjs} +3 -3
- package/dist/client/{checkout-DEmpGRJu.mjs → checkout-Dza-LA7N.mjs} +3 -3
- package/dist/client/client.mjs +1673 -785
- package/dist/client/{colorStyles-jZS6KfkP.mjs → colorStyles-CrgzoXsm.mjs} +1 -30
- package/dist/client/{courseRegistration-BqRZPmsq.mjs → courseRegistration-TYkNychb.mjs} +7 -7
- package/dist/client/{eventCalendar-B8N_tSl5.mjs → eventCalendar-BI_90SsT.mjs} +5 -5
- package/dist/client/{eventCombined-Gjn6gtq7.mjs → eventCombined-mNrpryE9.mjs} +2 -2
- package/dist/client/{eventDetails-M-VCxA-r.mjs → eventDetails-D4GVlCIY.mjs} +3 -3
- package/dist/client/{eventListing-DR19hqYi.mjs → eventListing-YhKN018y.mjs} +2 -2
- package/dist/client/{eventRegistration-BR02a0k3.mjs → eventRegistration-CdHGtilr.mjs} +7 -7
- package/dist/client/foregroundContract-xICPq59x.mjs +31 -0
- package/dist/client/{form-LY2xIbwg.mjs → form-AcAL45rA.mjs} +2 -2
- package/dist/client/{headerSection-CYwwXJfh.mjs → headerSection-uEC52ueD.mjs} +3 -3
- package/dist/client/hooks.mjs +890 -497
- package/dist/client/{locationMap-DWnBXrFq.mjs → locationMap-_wJDSUYe.mjs} +3 -3
- package/dist/client/{media-DHtSxS5V.mjs → media-BK0O3b-U.mjs} +3 -2
- package/dist/client/{newsletterForm-D9s-fQ2P.mjs → newsletterForm-DrArsb2B.mjs} +2 -2
- package/dist/client/{pricing-DDq80oYc.mjs → pricing-BSYVghwo.mjs} +1 -1
- package/dist/client/{productDetail-B0SbWd45.mjs → productDetail-Dyk90sMs.mjs} +3 -3
- package/dist/client/{productList-PwYlZn0y.mjs → productList-BCKThwAI.mjs} +3 -3
- package/dist/client/{propsDecoder-BRWBiH7i.mjs → propsDecoder-CkXxkdSR.mjs} +63 -24
- package/dist/client/rendering/client.mjs +1034 -486
- package/dist/client/rendering/islands.mjs +19 -19
- package/dist/client/rendering.mjs +1832 -760
- package/dist/client/{shop-CMwZPYME.mjs → shop-DeltVH10.mjs} +6 -6
- package/dist/client/{shop-commerce-BuxsFate.mjs → shop-commerce-BD9Jsm2Z.mjs} +6 -6
- package/dist/client/{shop-commerce-store-boYlEJ91.mjs → shop-commerce-store-CmXD6FDS.mjs} +1 -1
- package/dist/client/{shopShared-D2naaOes.mjs → shopShared-B8v-lH_F.mjs} +2 -2
- package/dist/client/{useDiscountCodeUi-D9RHpVoj.mjs → useDiscountCodeUi-DbWJN8ld.mjs} +1 -1
- package/dist/client/{useEventFilters-igGiK1re.mjs → useEventFilters-EJIMUnqT.mjs} +46 -69
- package/dist/client/{usePolling-CI7MbsFB.mjs → usePolling-Cmh14fc7.mjs} +2 -2
- package/dist/preview-next/before-render.mjs +35 -0
- package/dist/preview-next/client/runtime.mjs +4 -4
- package/dist/preview-next/middleware.mjs +35 -0
- package/dist/{previewAuthStore-a_cBD28m.mjs → previewAuthStore-CTO7CRPk.mjs} +35 -0
- package/dist/{sdk-runtime-MBzD-GmP.mjs → sdk-runtime-Dou0GAav.mjs} +2 -2
- package/dist/{separator-5ahRBC85.mjs → separator-CI5wZNXT.mjs} +1 -1
- package/dist/server/components.mjs +1832 -784
- package/dist/server/config-validation.mjs +890 -497
- package/dist/server/config.mjs +890 -497
- package/dist/server/data.mjs +890 -497
- package/dist/server/date-time.mjs +386 -0
- package/dist/server/index.mjs +36 -1
- package/dist/server/next.mjs +1868 -785
- package/dist/server/page-converter.mjs +849 -285
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/rendering/server.mjs +1553 -718
- package/dist/server/rendering.mjs +1832 -784
- package/dist/server/routing.mjs +933 -522
- package/dist/server/server.mjs +929 -501
- package/dist/server/theme-bridge.mjs +1408 -392
- package/dist/server/theme.mjs +471 -228
- package/dist/styles/index.css +5 -0
- package/package.json +7 -1
- package/dist/_dts/theme-core/src/buttons/presets/types.d.ts +0 -88
- package/dist/_dts/theme-core/src/buttons/utils/contrast.d.ts +0 -38
- package/dist/_dts/theme-core/src/palette/themePaletteCompatibility.d.ts +0 -57
package/README.md
CHANGED
|
@@ -14,6 +14,7 @@ A lightweight TypeScript SDK for consuming Riverbank CMS content in React Server
|
|
|
14
14
|
- ✅ **Custom blocks** - Define site-specific blocks with full CMS editing support
|
|
15
15
|
- ✅ **Content tooling** - Define content type schema in config and sync pages, entries, and navigation through explicit content push scopes
|
|
16
16
|
- ✅ **Site URLs** - Configure preview and live URLs for dashboard integration
|
|
17
|
+
- ✅ **Timezone-safe dates** - Format event and booking times in an explicit IANA timezone
|
|
17
18
|
|
|
18
19
|
## Installation
|
|
19
20
|
|
|
@@ -187,6 +188,13 @@ SDK sites that need bespoke appointment booking UI can use the headless booking
|
|
|
187
188
|
|
|
188
189
|
SDK sites that need bespoke event registration UI can use the headless event registration runtime from `@riverbankcms/sdk/bookings`. See [`docs/headless-event-registration.md`](./docs/headless-event-registration.md) for the real `blockOverrides` pattern with an `'event-registration'` override, `HeadlessEventRegistrationProvider`, `getEventRegistrationOverrideInput`, and `useHeadlessEventRegistrationFlow`.
|
|
189
190
|
|
|
191
|
+
### Date and time formatting
|
|
192
|
+
|
|
193
|
+
Use `@riverbankcms/sdk/date-time` to render event and booking timestamps in
|
|
194
|
+
their intended timezone, including daylight-saving changes. See
|
|
195
|
+
[`docs/date-time-formatting.md`](./docs/date-time-formatting.md) for the
|
|
196
|
+
formatters, compact event-time defaults, range behavior, and error handling.
|
|
197
|
+
|
|
190
198
|
### Server-Side API
|
|
191
199
|
|
|
192
200
|
```tsx
|
|
@@ -1597,6 +1605,14 @@ Token values can be:
|
|
|
1597
1605
|
- **CSS variable refs**: `'var(--brand-purple)'` (passed through)
|
|
1598
1606
|
- **RGB values**: `'109 40 217'` (used directly)
|
|
1599
1607
|
|
|
1608
|
+
CSS variable references are suitable for emitted variables, structural block
|
|
1609
|
+
styles, cards, and inputs. Opt-in generated button skins resolve and validate
|
|
1610
|
+
foreground/background contrast while building the runtime, so every token used
|
|
1611
|
+
by `components.buttons` must be a concrete hex or RGB value. When your design
|
|
1612
|
+
system owns brand colours through `var(...)`, leave `components.buttons`
|
|
1613
|
+
disabled and style the button classes in your design-system CSS, or provide
|
|
1614
|
+
concrete button tokens to ThemeBridge.
|
|
1615
|
+
|
|
1600
1616
|
Canonical tokens win when aliases are also present. Accepted aliases are `text -> foreground`, `mutedText -> mutedForeground`, `white -> primaryForeground`, and `danger -> destructive`.
|
|
1601
1617
|
|
|
1602
1618
|
### Design Presets
|
|
@@ -1688,7 +1704,8 @@ Add custom CSS rules scoped to theme components:
|
|
|
1688
1704
|
|
|
1689
1705
|
### Pass-Through to Design Systems
|
|
1690
1706
|
|
|
1691
|
-
Reference existing CSS variables from your design system
|
|
1707
|
+
Reference existing CSS variables from your design system when ThemeBridge is
|
|
1708
|
+
not generating button skins:
|
|
1692
1709
|
|
|
1693
1710
|
```tsx
|
|
1694
1711
|
<ThemeBridgeProvider
|
|
@@ -1699,6 +1716,9 @@ Reference existing CSS variables from your design system:
|
|
|
1699
1716
|
background: 'var(--ds-bg)',
|
|
1700
1717
|
foreground: 'var(--ds-text)',
|
|
1701
1718
|
},
|
|
1719
|
+
components: {
|
|
1720
|
+
buttons: false,
|
|
1721
|
+
},
|
|
1702
1722
|
}}
|
|
1703
1723
|
>
|
|
1704
1724
|
```
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { $
|
|
3
|
-
import { d as unwrapResponse, f as getDashboardUrl, r as usePreviewAuth } from "./previewAuthStore-
|
|
4
|
-
import { C as buildFontPreviewUrl, D as Callout, O as CalloutDescription, S as isAdapterReferenceKind, T as getSiteFontsStorageUrl, _ as usePreviewBlockCustomizeSelectionOptional, b as previewWidgetOverrides, d as buildPreviewDashboardSetupUrl, f as resolvePreviewDashboardSetupHandoff, g as canInspectSiteStyle, h as canApplySiteStyle, m as resolvePreviewSidebarChromeModel, p as resolvePreviewEditorGuidanceModel, v as useBlockCustomizeControls, w as generateFontFaceCss, x as BlockEditor, y as PreviewFormProvider } from "./SdkPreviewModeRuntime-
|
|
5
|
-
import { t as Separator } from "./separator-
|
|
2
|
+
import { $d as SlidersHorizontal, $l as Popover, A as deriveStyleConfiguratorCapabilities, Aa as paletteColorsEqual, Au as Surface, B as previewButtonPersonality, Ct as useEntryController, D as committedPaletteForSnapshot, Da as findCuratedPalette, Dt as useEditorUiStoreInstance, E as cancelPreview, Ea as curatedPalettes, Et as useEditorUiStore, F as markApplySaving, Ff as ChevronRight, Fu as DropdownMenuSeparator, G as previewSitePalette, Gl as Select, H as previewFooterLook, Ht as resolvePageRouteSlug, I as openRow, If as ChevronLeft, Iu as DropdownMenuTrigger, J as resetTypographyToSaved, Jl as SelectTrigger, K as previewSiteStyle, Kl as SelectContent, L as paletteMutationCapability, M as isPreviewingChange, Mu as DropdownMenuContent, N as markApplyFailed, Nu as DropdownMenuItem, O as createPalette, Oa as buildPaletteLibraryReadModel, Od as assertNever$1, P as markApplySaved, Pu as DropdownMenuLabel, Q as toggleRow, Qd as Smartphone, Ql as SearchInput, Qt as FormRenderer, Qu as Button, R as palettePreviewProjection, Rf as Check, T as applyTypographyDraftPatch, U as previewHeaderLayout, Ud as X$1, Ut as resolveContentTitle, V as previewCuratedPalette, Vi as getCuratedSiteStyle, Vt as deriveRouteMetadataPresentation, W as previewHeaderStyle, X as styleConfiguratorHistoryEntryForPersistedSelection, Y as setPaletteColors, Yd as Tablet, Yl as SelectValue, Yt as ManifestForm, Z as syncStyleConfiguratorState, Zt as createManifestValidation, _ as planSiteChromeFooterLayoutSelection, aa as requireEntriesForCuratedChoices, at as createOptimisticActionRunner, au as TabsList, bt as useUISelector, bu as CollapsibleContent, c as selectionSnapshotFromApplySiteStyleSelectionResponse, ca as getHeaderLayout, cf as Monitor, d as PREVIEW_DESIGN_REFRESH_ERROR_MESSAGE, df as LoaderCircle, dn as listEntryPageContentSlots, en as createStoreBackend, eu as PopoverContent, f as PREVIEW_DESIGN_SAVE_ERROR_MESSAGE, g as cycleableSiteChromeOptions, h as cycleSiteChromeLookId, if as Plus, iu as TabsContent, j as dismissWarnings, ja as paletteColorsSchema, ju as DropdownMenu, k as createStyleConfiguratorState, ka as paletteColorEntries, l as resolveStyleConfiguratorInitialSnapshot, la as getHeaderStyle, m as buildSiteChromeLookModels, n as useSiteChromeCustomizeOptional, nl as buttonPersonalities, nu as Input, oa as findFooterLook, ot as resolvePreviewSidebarTab, ou as TabsTrigger, p as reportPreviewDesignError, q as reconcilePaletteLibraryActive, ql as SelectItem, rl as findButtonPersonality, ru as Tabs, s as buildApplySiteStyleSelectionBody, sa as getFooterLayout, sd as unsafeAsEditorBlockId, st as FooterComposerPanel, td as cn, tu as PopoverTrigger, u as PREVIEW_DESIGN_LOAD_ERROR_MESSAGE, uf as Maximize2, v as planSiteChromeLookSelection, w as applyResolvedSelections, x as usePreviewDesignCoordinator, xu as CollapsibleTrigger, y as planSiteStylePreviewChange, yt as ContentFieldsForm, yu as Collapsible, z as prepareStalePaletteRetry, zi as curatedSiteStyles } from "./SiteChromeCustomizeContext-DUpalEdL.mjs";
|
|
3
|
+
import { d as unwrapResponse, f as getDashboardUrl, r as usePreviewAuth } from "./previewAuthStore-CTO7CRPk.mjs";
|
|
4
|
+
import { C as buildFontPreviewUrl, D as Callout, O as CalloutDescription, S as isAdapterReferenceKind, T as getSiteFontsStorageUrl, _ as usePreviewBlockCustomizeSelectionOptional, b as previewWidgetOverrides, d as buildPreviewDashboardSetupUrl, f as resolvePreviewDashboardSetupHandoff, g as canInspectSiteStyle, h as canApplySiteStyle, m as resolvePreviewSidebarChromeModel, p as resolvePreviewEditorGuidanceModel, v as useBlockCustomizeControls, w as generateFontFaceCss, x as BlockEditor, y as PreviewFormProvider } from "./SdkPreviewModeRuntime-D8Gt9Gbe.mjs";
|
|
5
|
+
import { t as Separator } from "./separator-CI5wZNXT.mjs";
|
|
6
6
|
import React, { forwardRef, useCallback, 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";
|
|
@@ -3375,15 +3375,7 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3375
3375
|
setState(live);
|
|
3376
3376
|
}
|
|
3377
3377
|
const previewed = live.previewed;
|
|
3378
|
-
|
|
3379
|
-
if (!siteStyle) return;
|
|
3380
|
-
const compiled = planSiteStylePreviewChange({
|
|
3381
|
-
siteStyle,
|
|
3382
|
-
selection: previewed,
|
|
3383
|
-
baseTheme: theme,
|
|
3384
|
-
headerSelectionContext,
|
|
3385
|
-
footerSelectionContext
|
|
3386
|
-
});
|
|
3378
|
+
if (!getCuratedSiteStyle(previewed.siteStyleId)) return;
|
|
3387
3379
|
await runnerRef.current.run({
|
|
3388
3380
|
optimistic: () => {
|
|
3389
3381
|
applyStarted("style-configurator");
|
|
@@ -3392,15 +3384,7 @@ function StyleConfigurator({ siteId, apiClient, theme, selectionId, selectionVer
|
|
|
3392
3384
|
network: async () => {
|
|
3393
3385
|
const body = buildApplySiteStyleSelectionBody({
|
|
3394
3386
|
base: live.base,
|
|
3395
|
-
previewed
|
|
3396
|
-
...previewed,
|
|
3397
|
-
buttonPersonalityId: compiled.resolvedSelections.buttonPersonalityId,
|
|
3398
|
-
headerLayoutId: compiled.resolvedSelections.headerLayoutId,
|
|
3399
|
-
headerStyleId: compiled.resolvedSelections.headerStyleId,
|
|
3400
|
-
headerLookId: compiled.resolvedSelections.headerLookId,
|
|
3401
|
-
footerLookId: compiled.resolvedSelections.footerLookId,
|
|
3402
|
-
typography: compiled.themeOverlay.typography
|
|
3403
|
-
},
|
|
3387
|
+
previewed,
|
|
3404
3388
|
selectionId
|
|
3405
3389
|
});
|
|
3406
3390
|
if (!body.ok) throw new StyleApplyPlanError(paletteApplyPlanErrorMessage(body.error));
|
|
@@ -4175,6 +4159,7 @@ function paletteApplyPlanErrorMessage(error) {
|
|
|
4175
4159
|
switch (error) {
|
|
4176
4160
|
case "invalid-palette-state": return "Palette details are unavailable. Refresh and try again.";
|
|
4177
4161
|
case "curated-palette-missing": return "This curated palette is no longer available. Refresh and try again.";
|
|
4162
|
+
case "no-selection-changes": return "There are no design changes to apply.";
|
|
4178
4163
|
default: return assertNever$1(error);
|
|
4179
4164
|
}
|
|
4180
4165
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import { d as unwrapResponse, r as usePreviewAuth } from "./previewAuthStore-
|
|
4
|
-
import { E as FixedBottomSurface, a as usePreviewPageDesignEditorState, c as applyPreviewChromeSurfaceToElement, l as resolvePreviewChromeSurface, o as PREVIEW_CHROME_PORTAL_CLASS_NAME, s as PREVIEW_CHROME_THEME_CLASS_NAME, u as setPreviewSidebarTab } from "./SdkPreviewModeRuntime-
|
|
2
|
+
import { $u as cva, Bl as TooltipContent, Cf as Eye, Dt as useEditorUiStoreInstance, Et as useEditorUiStore, Gd as Undo2, Hl as TooltipTrigger, Iu as DropdownMenuTrigger, Kd as TriangleAlert, Lf as ChevronDown, Lt as useMultiAutosave, Mu as DropdownMenuContent, Nu as DropdownMenuItem, Qu as Button, Tf as EllipsisVertical, Tt as classifyHistoryShortcut, Zd as Sparkles, _u as DialogHeader, a as previewDesignHistoryDomainForCommand, af as Pencil, df as LoaderCircle, fu as Dialog, hu as DialogDescription, i as usePreviewDesignHistoryOrder, ju as DropdownMenu, mu as DialogContent, n as useSiteChromeCustomizeOptional, o as selectPreviewDesignHistoryDomain, of as PenLine, rf as Redo2, sf as Palette, td as cn, vt as useEditor, vu as DialogTitle, wt as useEntryEditorController, zl as Tooltip } from "./SiteChromeCustomizeContext-DUpalEdL.mjs";
|
|
3
|
+
import { d as unwrapResponse, r as usePreviewAuth } from "./previewAuthStore-CTO7CRPk.mjs";
|
|
4
|
+
import { E as FixedBottomSurface, a as usePreviewPageDesignEditorState, c as applyPreviewChromeSurfaceToElement, l as resolvePreviewChromeSurface, o as PREVIEW_CHROME_PORTAL_CLASS_NAME, s as PREVIEW_CHROME_THEME_CLASS_NAME, u as setPreviewSidebarTab } from "./SdkPreviewModeRuntime-D8Gt9Gbe.mjs";
|
|
5
5
|
import * as React$1 from "react";
|
|
6
6
|
import { useCallback, useEffect, useMemo, useState, useTransition } from "react";
|
|
7
7
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { n as markPreviewAuthExpired, s as ApiRequestError } from "./previewAuthStore-
|
|
2
|
+
import { n as markPreviewAuthExpired, s as ApiRequestError } from "./previewAuthStore-CTO7CRPk.mjs";
|
|
3
3
|
import { createContext, useContext, useRef } from "react";
|
|
4
4
|
import { jsx } from "react/jsx-runtime";
|
|
5
5
|
import { MutationCache, QueryCache, QueryClient, QueryClientProvider } from "@tanstack/react-query";
|