@riverbankcms/sdk 0.152.0 → 0.154.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/CHANGELOG.md +15 -0
- package/dist/{EventEmbeddedCheckoutStep-DVQXWFm6.mjs → EventEmbeddedCheckoutStep-ba9npQtb.mjs} +1 -1
- package/dist/{PreviewEditorSidebar-Dr4NJi3Q.mjs → PreviewEditorSidebar-C7FiaxlF.mjs} +194 -22
- package/dist/{PreviewEditorUI-DSZXQbyh.mjs → PreviewEditorUI-DFst50q1.mjs} +20 -44
- package/dist/{SdkPreviewModeRuntime-Dl4GyMc3.mjs → SdkPreviewModeRuntime-BUNV_YHZ.mjs} +266 -143
- package/dist/{SiteChromeCustomizeContext-DgBe-FlM.mjs → SiteChromeCustomizeContext-DEj7qppF.mjs} +5340 -4329
- package/dist/{ThemedButton-B8ViBnLK.mjs → ThemedButton-C8kzu0hY.mjs} +610 -116
- package/dist/_dts/ai/src/contracts/proposals.d.ts +416 -182
- package/dist/_dts/ai/src/contracts/siteStyleProposalSchemas.d.ts +3270 -8214
- package/dist/_dts/api/src/billing.d.ts +2 -0
- package/dist/_dts/api/src/billingEndpointDefinitions.d.ts +78 -0
- package/dist/_dts/api/src/bookingAdjustments.d.ts +3 -2
- package/dist/_dts/api/src/bookingOperations.d.ts +7 -2
- package/dist/_dts/api/src/bookingPeople.d.ts +19 -0
- package/dist/_dts/api/src/bookingPeopleEndpointDefinitions.d.ts +8 -0
- package/dist/_dts/api/src/bookingRecords.d.ts +4 -106
- package/dist/_dts/api/src/bookings.d.ts +2 -3
- package/dist/_dts/api/src/communications.d.ts +19 -5
- package/dist/_dts/api/src/contentRuntime.d.ts +1 -0
- package/dist/_dts/api/src/endpoints.d.ts +88 -43
- package/dist/_dts/api/src/index.d.ts +4 -2
- package/dist/_dts/api/src/indexCoreTypes.d.ts +1 -0
- package/dist/_dts/api/src/indexExtendedTypes.d.ts +1 -1
- package/dist/_dts/api/src/moneyPayments.d.ts +116 -0
- package/dist/_dts/api/src/onboarding/surfaceData.d.ts +2 -0
- package/dist/_dts/api/src/sdk-event-upsert.d.ts +2 -2
- package/dist/_dts/api/src/sdkThemeWire.d.ts +348 -1537
- package/dist/_dts/api/src/shared-contracts.d.ts +10 -0
- package/dist/_dts/api/src/siteInfrastructure.d.ts +2 -1
- package/dist/_dts/api/src/sitePlatformEndpoints.d.ts +18 -0
- package/dist/_dts/api/src/siteRuntimeEndpoints.d.ts +17 -16
- package/dist/_dts/api/src/siteSettings.d.ts +1 -0
- package/dist/_dts/api/src/stripeConnectSetup.d.ts +90 -0
- package/dist/_dts/api/src/teamMembers.d.ts +2 -27
- package/dist/_dts/api/src/types.d.ts +11 -31
- package/dist/_dts/api/src/wholeSeriesRuns.d.ts +2 -4
- package/dist/_dts/block-form/src/widgets/RepeaterField/components/layoutGridDomain.d.ts +3 -13
- package/dist/_dts/blocks/src/client/site-chrome.d.ts +1 -1
- package/dist/_dts/blocks/src/contracts/index.d.ts +1 -0
- package/dist/_dts/blocks/src/contracts/proof-block-islands.d.ts +8 -96
- package/dist/_dts/blocks/src/index.d.ts +1 -0
- package/dist/_dts/blocks/src/lib/media.d.ts +1 -0
- package/dist/_dts/blocks/src/lib/picsum.d.ts +2 -2
- package/dist/_dts/blocks/src/pageRendererContracts.d.ts +2 -1
- package/dist/_dts/blocks/src/primitives/content/components/RichText.d.ts +1 -1
- package/dist/_dts/blocks/src/primitives/content/primitives.d.ts +4 -1
- package/dist/_dts/blocks/src/primitives/layout/Section.d.ts +1 -0
- package/dist/_dts/blocks/src/system/blocks/events/event-calendar.d.ts +1 -1
- package/dist/_dts/blocks/src/system/blocks/events/eventSelectionFields.d.ts +2 -2
- package/dist/_dts/blocks/src/system/blocks/events/shared/fields.d.ts +0 -4
- package/dist/_dts/blocks/src/system/blocks/events/shared/index.d.ts +0 -1
- package/dist/_dts/blocks/src/system/blocks/events/shared/schemas.d.ts +276 -884
- package/dist/_dts/blocks/src/system/blocks/events/shared/types.d.ts +2 -2
- package/dist/_dts/blocks/src/system/blocks/form.d.ts +10 -0
- package/dist/_dts/blocks/src/system/blocks/image-gallery/fields.d.ts +1 -0
- package/dist/_dts/blocks/src/system/blocks/image-gallery.d.ts +6 -1
- package/dist/_dts/blocks/src/system/blocks/location-map.d.ts +2 -2
- package/dist/_dts/blocks/src/system/blocks/media-text.d.ts +92 -90
- package/dist/_dts/blocks/src/system/blocks/newsletter-signup.d.ts +12 -0
- package/dist/_dts/blocks/src/system/blocks/shared/teamMembers.d.ts +4 -7
- package/dist/_dts/blocks/src/system/blocks/site-footer-runtime-layout.d.ts +23 -0
- package/dist/_dts/blocks/src/system/blocks/site-footer-runtime-profile.d.ts +20 -0
- package/dist/_dts/blocks/src/system/blocks/site-footer-runtime.d.ts +17 -16
- package/dist/_dts/blocks/src/system/blocks/site-footer.d.ts +1 -1
- package/dist/_dts/blocks/src/system/blocks/team-members.d.ts +2 -2
- package/dist/_dts/blocks/src/system/customize/backgrounds.d.ts +6 -6
- package/dist/_dts/blocks/src/system/customize/facets.d.ts +75 -9
- package/dist/_dts/blocks/src/system/fields/backgroundContent.d.ts +377 -1
- package/dist/_dts/blocks/src/system/helpers/backgroundMedia.d.ts +6 -2
- package/dist/_dts/blocks/src/system/helpers/resolveBackground.d.ts +3 -3
- package/dist/_dts/blocks/src/system/layout/repeaterGrid.d.ts +12 -5
- package/dist/_dts/blocks/src/system/manifest/fieldValidation/index.d.ts +3 -3
- package/dist/_dts/blocks/src/system/manifest/schema.d.ts +48 -48
- package/dist/_dts/blocks/src/system/manifest/validation.d.ts +2 -0
- package/dist/_dts/blocks/src/system/node/fragments/index.d.ts +1 -0
- package/dist/_dts/blocks/src/system/node/fragments/lookSlot.d.ts +1 -1
- package/dist/_dts/blocks/src/system/node/fragments/responsiveTwoColumn.d.ts +3 -1
- package/dist/_dts/blocks/src/system/node/fragments/sectionHead.d.ts +15 -0
- package/dist/_dts/blocks/src/system/runtime/components/registry.client.d.ts +18 -198
- package/dist/_dts/blocks/src/system/runtime/components/runtime-backed-blocks.d.ts +9 -99
- package/dist/_dts/blocks/src/system/runtime/hooks/useBookingFlowController.d.ts +1 -1
- package/dist/_dts/blocks/src/system/runtime/hooks/useHeadlessBookingFlow.d.ts +2 -0
- package/dist/_dts/blocks/src/system/runtime/lookSurfaces.d.ts +18 -6
- package/dist/_dts/blocks/src/system/runtime/nodes/ImageResolveContext.d.ts +1 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/appointment-services.d.ts +50 -202
- package/dist/_dts/blocks/src/system/runtime/nodes/basic.d.ts +2 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/booking-form.headless.state.d.ts +28 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/event-details/lookPresentation.d.ts +12 -6
- package/dist/_dts/blocks/src/system/runtime/nodes/event-details/presentation.d.ts +1 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/events/domain/dates.d.ts +1 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/CardListItem.d.ts +1 -1
- package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/eventCollectionContract.d.ts +289 -885
- package/dist/_dts/blocks/src/system/runtime/nodes/file-download.d.ts +3 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/form.fields.d.ts +5 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/form.interactive.d.ts +11 -79
- package/dist/_dts/blocks/src/system/runtime/nodes/form.parts.d.ts +7 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/form.server.d.ts +2 -13
- package/dist/_dts/blocks/src/system/runtime/nodes/media.d.ts +22 -90
- package/dist/_dts/blocks/src/system/runtime/nodes/mediaContext.d.ts +69 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/newsletter-form.interactive.d.ts +8 -72
- package/dist/_dts/blocks/src/system/runtime/nodes/newsletter-form.parts.d.ts +6 -6
- package/dist/_dts/blocks/src/system/runtime/nodes/newsletter-form.types.d.ts +3 -2
- package/dist/_dts/blocks/src/system/runtime/nodes/shared/contract-schemas.d.ts +2 -2
- package/dist/_dts/blocks/src/system/transforms/registry/_utils/surfaceForegroundStyles.d.ts +3 -0
- package/dist/_dts/blocks/src/system/transforms/registry/footerArrangement.d.ts +6 -0
- package/dist/_dts/blocks/src/system/transforms/registry/index.d.ts +1 -0
- package/dist/_dts/blocks/src/system/transforms/registry/layout.d.ts +0 -11
- package/dist/_dts/blocks/src/system/transforms/registry/links.d.ts +3 -3
- package/dist/_dts/blocks/src/system/transforms/typed.d.ts +1 -10
- package/dist/_dts/commerce/src/purchase/orderConfirmationPlanning.d.ts +1 -0
- package/dist/_dts/content-editor/src/FooterComposerOverview.d.ts +5 -2
- package/dist/_dts/content-editor/src/FooterComposerPanel.d.ts +1 -1
- package/dist/_dts/content-editor/src/FooterNavigationLayoutControl.d.ts +6 -3
- package/dist/_dts/content-editor/src/controller/editorLeaseParticipation.d.ts +1 -1
- package/dist/_dts/content-editor/src/footerComposer.d.ts +2 -1
- package/dist/_dts/content-editor/src/footerComposerPanelTypes.d.ts +3 -1
- package/dist/_dts/content-editor/src/footerNavigationLayoutState.d.ts +56 -0
- package/dist/_dts/content-editor/src/footerPreviewRuntime.d.ts +2 -1
- package/dist/_dts/content-editor/src/useFooterComposerState.d.ts +3 -4
- package/dist/_dts/content-editor/src/useFooterNavigationLayout.d.ts +11 -8
- package/dist/_dts/content-model/src/content-types/schema.d.ts +3 -3
- package/dist/_dts/core/src/booking-refunds.d.ts +2 -0
- package/dist/_dts/core/src/date-display.d.ts +85 -0
- package/dist/_dts/core/src/date-time-formatter.d.ts +2 -0
- package/dist/_dts/core/src/footer-arrangement.d.ts +8 -1
- package/dist/_dts/core/src/footer-composition-types.d.ts +6 -1
- package/dist/_dts/core/src/footer-composition.d.ts +1 -1
- package/dist/_dts/core/src/footer-navigation-layout.d.ts +3 -0
- package/dist/_dts/core/src/index.d.ts +2 -0
- package/dist/_dts/core/src/mailing-list-runtime.d.ts +2 -2
- package/dist/_dts/core/src/mailing-list-setup-parser.d.ts +9 -1
- package/dist/_dts/core/src/mailing-list-setup.d.ts +12 -1
- package/dist/_dts/core/src/mailing-list-submission.d.ts +7 -2
- package/dist/_dts/core/src/mailing-list-targeting.d.ts +9 -1
- package/dist/_dts/core/src/public-profile.d.ts +3 -1
- package/dist/_dts/core/src/scheduled-date-time.d.ts +69 -0
- package/dist/_dts/db/src/generated/supabase/database.types.d.ts +105 -13
- package/dist/_dts/db/src/schemas/forms.d.ts +16 -16
- package/dist/_dts/editor-blocks/src/index.d.ts +1 -0
- package/dist/_dts/editor-blocks/src/media/MediaField.d.ts +2 -2
- package/dist/_dts/editor-blocks/src/media/admitEditorMediaField.d.ts +4 -0
- package/dist/_dts/editor-blocks/src/widgets/mailing-list-targeting/targetingState.d.ts +2 -2
- package/dist/_dts/media-core/src/assetsInUseSummary.d.ts +6 -0
- package/dist/_dts/media-core/src/contentMediaAudit.d.ts +3 -2
- package/dist/_dts/media-core/src/index.d.ts +4 -0
- package/dist/_dts/media-core/src/media.d.ts +406 -0
- package/dist/_dts/media-core/src/mediaIdentifierSchema.d.ts +3 -0
- package/dist/_dts/media-core/src/mediaKinds.d.ts +2 -0
- package/dist/_dts/media-core/src/mediaUsageProjection.d.ts +13 -1
- package/dist/_dts/media-core/src/mediaWriteNormalizer.d.ts +2 -6
- package/dist/_dts/media-core/src/portableMediaReferences.d.ts +8 -21
- package/dist/_dts/media-core/src/renderableMediaAsset.d.ts +28 -14
- package/dist/_dts/media-core/src/renderableMediaAssetAdmission.d.ts +15 -0
- package/dist/_dts/media-editor/src/CropDialog.d.ts +6 -3
- package/dist/_dts/media-editor/src/MediaEditor.d.ts +2 -1
- package/dist/_dts/media-editor/src/MediaPreview.d.ts +3 -3
- package/dist/_dts/media-editor/src/cropEditorSource.d.ts +5 -7
- package/dist/_dts/media-editor/src/editorMediaState.d.ts +29 -0
- package/dist/_dts/media-editor/src/mediaSelection.d.ts +1 -2
- package/dist/_dts/media-editor/src/runtimeMediaAssetState.d.ts +4 -5
- package/dist/_dts/media-editor/src/types.d.ts +1 -1
- package/dist/_dts/media-editor/src/utils.d.ts +0 -1
- package/dist/_dts/media-react/src/components/cropChangePolicy.d.ts +4 -1
- package/dist/_dts/media-react/src/components/cropGeometry.d.ts +1 -0
- package/dist/_dts/media-react/src/components/useImageCropperController.d.ts +1 -0
- package/dist/_dts/preview-next/src/client/blocks/ArrangementBlockToolbar.d.ts +2 -1
- package/dist/_dts/preview-next/src/client/blocks/BlockBackgroundChooser.d.ts +2 -1
- package/dist/_dts/preview-next/src/client/blocks/previewCustomizeSelectedMedia.d.ts +11 -12
- package/dist/_dts/preview-next/src/client/preview/PreviewShell.d.ts +1 -0
- package/dist/_dts/preview-next/src/client/preview/PreviewShellLayout.d.ts +1 -0
- package/dist/_dts/preview-next/src/client/preview/SiteChromeCustomizeContext.d.ts +4 -1
- package/dist/_dts/preview-next/src/client/preview/siteChromeSavePlan.d.ts +27 -5
- package/dist/_dts/preview-next/src/client/preview/siteStylePreviewPlanner.d.ts +2 -0
- package/dist/_dts/preview-next/src/client/preview/useConfirmedPreferenceRecord.d.ts +12 -0
- package/dist/_dts/preview-next/src/client/preview/usePersistedFooterPreferences.d.ts +26 -0
- package/dist/_dts/preview-next/src/client/preview/usePersistedHeaderPreferences.d.ts +40 -2
- package/dist/_dts/sdk/src/config/validation.d.ts +3 -3
- package/dist/_dts/sdk/src/contracts/content.d.ts +2 -45
- package/dist/_dts/sdk/src/contracts/index.d.ts +1 -1
- package/dist/_dts/sdk/src/contracts/rendering.d.ts +3 -3
- package/dist/_dts/sdk/src/contracts/system-block-content.d.ts +4 -46
- package/dist/_dts/sdk/src/date-time/index.d.ts +2 -68
- package/dist/_dts/sdk/src/index.d.ts +1 -0
- package/dist/_dts/sdk/src/public-api/contracts.d.ts +1 -0
- package/dist/_dts/sdk/src/rendering/image.d.ts +5 -5
- package/dist/_dts/sdk/src/rendering/index.d.ts +2 -1
- package/dist/_dts/sdk/src/rendering/islands/types.d.ts +1 -1
- package/dist/_dts/sdk/src/rendering/link.d.ts +3 -7
- package/dist/_dts/sdk/src/rendering/mediaAssets.d.ts +2 -4
- package/dist/_dts/sdk/src/version.d.ts +1 -1
- package/dist/_dts/theme-core/src/accordions/types.d.ts +1 -1
- package/dist/_dts/theme-core/src/boxBackgroundSchema.d.ts +397 -26
- package/dist/_dts/theme-core/src/buttons/buttonColourContract.d.ts +2 -0
- package/dist/_dts/theme-core/src/buttons/resolveButtonColourStates.d.ts +2 -0
- package/dist/_dts/theme-core/src/buttons/styles/recipes/lanternRecipes.d.ts +60 -0
- package/dist/_dts/theme-core/src/buttons/styles/registry.d.ts +57 -0
- package/dist/_dts/theme-core/src/buttons/styles/selection.d.ts +10 -1
- package/dist/_dts/theme-core/src/buttons/types.d.ts +378 -66
- package/dist/_dts/theme-core/src/buttons/typography.d.ts +24 -0
- package/dist/_dts/theme-core/src/cards/types.d.ts +42 -42
- package/dist/_dts/theme-core/src/footer/effectiveNavLinkStyle.d.ts +1 -1
- package/dist/_dts/theme-core/src/footer/generateFooterCss.d.ts +4 -1
- package/dist/_dts/theme-core/src/footer/mode.d.ts +2 -11
- package/dist/_dts/theme-core/src/generated/containerResponsiveThemeCss.d.ts +1 -1
- package/dist/_dts/theme-core/src/inputs/types.d.ts +3 -3
- package/dist/_dts/theme-core/src/lib/media.d.ts +2 -616
- package/dist/_dts/theme-core/src/mock-themes/all.d.ts +495 -2766
- package/dist/_dts/theme-core/src/navigation/types.d.ts +4 -4
- package/dist/_dts/theme-core/src/palette/curated/types.d.ts +1 -1
- package/dist/_dts/theme-core/src/schema.d.ts +838 -3369
- package/dist/_dts/theme-core/src/site-styles/appearancePresetTypes.d.ts +23 -7
- package/dist/_dts/theme-core/src/site-styles/backgroundAppearance.d.ts +2 -2
- package/dist/_dts/theme-core/src/site-styles/compilationPlan.d.ts +4 -6
- package/dist/_dts/theme-core/src/site-styles/compileFooterAgainstRow.d.ts +121 -0
- package/dist/_dts/theme-core/src/site-styles/curatedSiteStyles.d.ts +25 -0
- package/dist/_dts/theme-core/src/site-styles/footerLookDefaults.d.ts +45 -0
- package/dist/_dts/theme-core/src/site-styles/footerLookRecipe.d.ts +50 -0
- package/dist/_dts/theme-core/src/site-styles/footerLooks.d.ts +9 -35
- package/dist/_dts/theme-core/src/site-styles/footerPreferences.d.ts +29 -0
- package/dist/_dts/theme-core/src/site-styles/headerPreferencesPersistence.d.ts +2 -3
- package/dist/_dts/theme-core/src/site-styles/index.d.ts +4 -0
- package/dist/_dts/theme-core/src/site-styles/lookResolution.d.ts +2 -2
- package/dist/_dts/theme-core/src/site-styles/previewCompiler.d.ts +1 -1
- package/dist/_dts/theme-core/src/site-styles/runtimeBackgroundResolution.d.ts +9 -9
- package/dist/_dts/theme-core/src/site-styles/siteChromeBackgrounds.d.ts +8 -0
- package/dist/_dts/theme-core/src/site-styles/styleTags.d.ts +1 -1
- package/dist/_dts/theme-core/src/site-styles/themeParity.d.ts +1 -1
- package/dist/_dts/theme-core/src/site-styles/tokenRecipes.d.ts +2 -2
- package/dist/_dts/theme-core/src/styles/skinTokens.d.ts +2 -2
- package/dist/_dts/theme-core/src/typography/schema.d.ts +2 -2
- package/dist/_dts/ui/src/card.d.ts +1 -1
- package/dist/client/{BookingMailingListNote-CBuMKN0w.mjs → BookingMailingListNote-CNoSqFtf.mjs} +2 -2
- package/dist/client/{CardListItem-Dc9XTXhB.mjs → CardListItem-BkTkqBkh.mjs} +5 -4
- package/dist/client/{CheckboxChoice-CIqx_o0E.mjs → CheckboxChoice-CHJpsty4.mjs} +1 -1
- package/dist/client/{DemoBookingPortalAccess-D3VQ_kLj.mjs → DemoBookingPortalAccess-C7KQKFNt.mjs} +2 -2
- package/dist/client/{EventCombined.client-BHGEKise.mjs → EventCombined.client-BgeYMjHJ.mjs} +5 -6
- package/dist/client/{EventEmbeddedCheckoutStep-Bo1Cm23R.mjs → EventEmbeddedCheckoutStep-BTc_lTkM.mjs} +2 -2
- package/dist/client/{EventListing.client-D5OQgVPr.mjs → EventListing.client-ChRs9Hl2.mjs} +2 -2
- package/dist/client/{LeafletStaticMap-CLL5cWrr.mjs → LeafletStaticMap-C_dNQgd0.mjs} +1 -1
- package/dist/client/{RichText-BoDmnopf.mjs → RichText-BI9bzbjo.mjs} +106 -60
- package/dist/client/{ThemedButton-Ciltp0IK.mjs → ThemedButton-wl3Z3wkH.mjs} +1 -2
- package/dist/client/{accordion-DOkRS64-.mjs → accordion-6Yz8Wd83.mjs} +1 -1
- package/dist/client/{bookingForm-wlMVwo9h.mjs → bookingForm-i_pKIGiY.mjs} +42 -15
- package/dist/client/bookings.mjs +118357 -22833
- package/dist/client/{carousel-CGWk-Z0u.mjs → carousel-DNqd_PjC.mjs} +2 -2
- package/dist/client/{carousel.client-kX5mN1Eg.mjs → carousel.client-BUgjPbb6.mjs} +1 -1
- package/dist/client/{cart-OBBPlaH4.mjs → cart-D8OBHuF4.mjs} +3 -3
- package/dist/client/{checkout-Bmw2WjQX.mjs → checkout-F3-9IGLU.mjs} +3 -3
- package/dist/client/client.mjs +20785 -19238
- package/dist/client/{context-BI77UFAn.mjs → context-Dg4ZrxDD.mjs} +1 -1
- package/dist/client/{eventCalendar-qkej2Edn.mjs → eventCalendar-BUc7YIBM.mjs} +8 -9
- package/dist/client/{eventCombined-DApKHvat.mjs → eventCombined-BwfShk2a.mjs} +4 -4
- package/dist/client/{eventDetails-BQyUDPH0.mjs → eventDetails-BMOVC3go.mjs} +3 -3
- package/dist/client/{eventListing-CeAnshlZ.mjs → eventListing-BwE9PM-t.mjs} +4 -4
- package/dist/client/{eventRegistration-C3A3NyBO.mjs → eventRegistration-CCWPYDc7.mjs} +10 -10
- package/dist/client/{form-DW8rU7jO.mjs → form-CXFr0Gd5.mjs} +115 -52
- package/dist/client/{headerSection-CkIhsoNm.mjs → headerSection-BX8qw8kH.mjs} +3 -3
- package/dist/client/hooks.mjs +17908 -16797
- package/dist/client/{locationMap-D4O8wbli.mjs → locationMap-B3La71m0.mjs} +3 -4
- package/dist/client/{media-C5K_0xPd.mjs → media-B1Cbv721.mjs} +183 -362
- package/dist/client/mediaContext-CwbbimYB.mjs +135 -0
- package/dist/client/{newsletterForm-B7IxSPuz.mjs → newsletterForm-DnGyR0x7.mjs} +51 -15
- package/dist/client/{productDetail-Bqxpwy5N.mjs → productDetail-BVgTqvkb.mjs} +3 -3
- package/dist/client/{productList-u9Lz8V15.mjs → productList-CcO7kUQw.mjs} +3 -3
- package/dist/client/{propsDecoder-Bf1jucUp.mjs → propsDecoder-B1OeWavE.mjs} +2193 -374
- package/dist/client/renderableMediaAssetAdmission-CHkXYDC_.mjs +143 -0
- package/dist/client/rendering/client.mjs +22424 -21488
- package/dist/client/rendering/islands.mjs +20 -23
- package/dist/client/rendering.mjs +21025 -19413
- package/dist/client/{routeIslandApiConfig-BgP-aPMl.mjs → routeIslandApiConfig-Dl4vglJm.mjs} +1 -1
- package/dist/client/{shop-B_eykR-_.mjs → shop-P72nX5Fs.mjs} +7 -7
- package/dist/client/{shop-commerce-CT0APkFV.mjs → shop-commerce-Bt7uraDx.mjs} +8 -8
- package/dist/client/{shop-commerce-store-DcvZxdEK.mjs → shop-commerce-store-C1-mxSye.mjs} +1 -1
- package/dist/client/{shopShared-BVJOiUiJ.mjs → shopShared-Db-cRGu3.mjs} +5 -5
- package/dist/client/{useDiscountCodeUi-DPmYDunz.mjs → useDiscountCodeUi-jvAiUoUX.mjs} +1 -1
- package/dist/client/{useEventPagination-8-U55vH5.mjs → useEventPagination-BdWpCniq.mjs} +6 -7
- package/dist/preview-next/before-render.mjs +222 -55
- package/dist/preview-next/client/runtime.mjs +3 -3
- package/dist/preview-next/editor-chrome.css +5 -2
- package/dist/preview-next/keepAlive.mjs +133 -51
- package/dist/preview-next/middleware.mjs +133 -51
- package/dist/{sdk-runtime-C5jPdSrk.mjs → sdk-runtime-DLhjF2Nw.mjs} +1 -1
- package/dist/server/components.mjs +21541 -20118
- package/dist/server/config-validation.mjs +2466 -1403
- package/dist/server/config.mjs +2466 -1403
- package/dist/server/data.mjs +17842 -16759
- package/dist/server/date-time.mjs +258 -116
- package/dist/server/index.mjs +360 -53
- package/dist/server/next.mjs +21913 -20539
- package/dist/server/page-converter.mjs +8121 -7322
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/rendering/server.mjs +21196 -19760
- package/dist/server/rendering.mjs +21554 -20123
- package/dist/server/routing.mjs +19806 -18607
- package/dist/server/server.mjs +2907 -1845
- package/dist/server/theme-bridge.mjs +991 -160
- package/dist/server/theme.mjs +501 -100
- package/dist/{spinner-B-ab2rJp.mjs → spinner-MTooKfck.mjs} +1 -1
- package/dist/styles/index.css +254 -1
- package/package.json +1 -1
- package/dist/_dts/blocks/src/system/blocks/events/shared/layout.d.ts +0 -12
- package/dist/client/aspectTransforms-D-TnDdq4.mjs +0 -93
- package/dist/client/colorStyles-ECDNPE_P.mjs +0 -1253
|
@@ -48,6 +48,52 @@ function err(error) {
|
|
|
48
48
|
};
|
|
49
49
|
}
|
|
50
50
|
//#endregion
|
|
51
|
+
//#region ../core/src/branded.ts
|
|
52
|
+
const UUID_PATTERN = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
|
|
53
|
+
function parseUuidBrand(value, unsafeConstructor) {
|
|
54
|
+
if (typeof value !== "string") return err({ kind: "not_string" });
|
|
55
|
+
const normalized = value.trim().toLowerCase();
|
|
56
|
+
if (normalized.length === 0) return err({ kind: "empty_string" });
|
|
57
|
+
if (!UUID_PATTERN.test(normalized)) return err({ kind: "invalid_uuid" });
|
|
58
|
+
return ok(unsafeConstructor(normalized));
|
|
59
|
+
}
|
|
60
|
+
function expectParsedBrandedId(result) {
|
|
61
|
+
if (!result.ok) throw new Error(`Expected a validated branded UUID (${result.error.kind}).`);
|
|
62
|
+
return result.value;
|
|
63
|
+
}
|
|
64
|
+
const unsafeAsSiteId = (id) => id;
|
|
65
|
+
const unsafeAsApiKeyId = (id) => id;
|
|
66
|
+
const unsafeAsPageId = (id) => id;
|
|
67
|
+
const unsafeAsPageSurfaceId = (id) => id;
|
|
68
|
+
const unsafeAsEditorClientId = (id) => id;
|
|
69
|
+
const unsafeAsEventOfferingId = (id) => id;
|
|
70
|
+
const unsafeAsEventSeriesId = (id) => id;
|
|
71
|
+
const unsafeAsMediaAssetId = (id) => id;
|
|
72
|
+
const unsafeAsStorageBucketName = (value) => value;
|
|
73
|
+
const unsafeAsStoragePath = (value) => value;
|
|
74
|
+
const unsafeAsPositiveByteCount = (value) => value;
|
|
75
|
+
const unsafeAsPositiveSeconds = (value) => value;
|
|
76
|
+
const unsafeAsUserId = (id) => id;
|
|
77
|
+
const unsafeAsFormId = (id) => id;
|
|
78
|
+
const unsafeAsPassId = (id) => id;
|
|
79
|
+
const unsafeAsCustomerPassId = (id) => id;
|
|
80
|
+
const unsafeAsAppointmentServiceId = (id) => id;
|
|
81
|
+
const unsafeAsAppointmentResourceId = (id) => id;
|
|
82
|
+
const unsafeAsContentEntryId = (id) => id;
|
|
83
|
+
const unsafeAsContentVersionId = (id) => id;
|
|
84
|
+
const parseSiteId = (value) => parseUuidBrand(value, unsafeAsSiteId);
|
|
85
|
+
const parseApiKeyId = (value) => parseUuidBrand(value, unsafeAsApiKeyId);
|
|
86
|
+
const parsePageId = (value) => parseUuidBrand(value, unsafeAsPageId);
|
|
87
|
+
const parsePageSurfaceId = (value) => parseUuidBrand(value, unsafeAsPageSurfaceId);
|
|
88
|
+
const parseEditorClientId = (value) => parseUuidBrand(value, unsafeAsEditorClientId);
|
|
89
|
+
const parseEventOfferingId = (value) => parseUuidBrand(value, unsafeAsEventOfferingId);
|
|
90
|
+
const parseUserId = (value) => parseUuidBrand(value, unsafeAsUserId);
|
|
91
|
+
const parseMediaAssetId = (value) => parseUuidBrand(value, unsafeAsMediaAssetId);
|
|
92
|
+
const parseContentEntryId = (value) => parseUuidBrand(value, unsafeAsContentEntryId);
|
|
93
|
+
const parseContentVersionId = (value) => parseUuidBrand(value, unsafeAsContentVersionId);
|
|
94
|
+
const parseFormId = (value) => parseUuidBrand(value, unsafeAsFormId);
|
|
95
|
+
const parseEventSeriesId = (value) => parseUuidBrand(value, unsafeAsEventSeriesId);
|
|
96
|
+
//#endregion
|
|
51
97
|
//#region ../core/src/date-math.ts
|
|
52
98
|
function addDaysToDate(date, dayCount) {
|
|
53
99
|
const next = new Date(date);
|
|
@@ -891,6 +937,29 @@ function SpinnerNode({ className, size = "md", color, strokeWidth = 3, srLabel,
|
|
|
891
937
|
});
|
|
892
938
|
}
|
|
893
939
|
//#endregion
|
|
940
|
+
//#region ../theme-core/src/buttons/typography.ts
|
|
941
|
+
const textTransformSchema = z.enum([
|
|
942
|
+
"none",
|
|
943
|
+
"uppercase",
|
|
944
|
+
"lowercase",
|
|
945
|
+
"capitalize"
|
|
946
|
+
]);
|
|
947
|
+
const fontWeightSchema = z.union([
|
|
948
|
+
z.literal(400),
|
|
949
|
+
z.literal(500),
|
|
950
|
+
z.literal(600),
|
|
951
|
+
z.literal(700),
|
|
952
|
+
z.literal(800)
|
|
953
|
+
]);
|
|
954
|
+
const buttonTypographySchema = z.enum(["body", "heading"]);
|
|
955
|
+
const letterSpacingSchema = z.enum([
|
|
956
|
+
"tight",
|
|
957
|
+
"normal",
|
|
958
|
+
"slight",
|
|
959
|
+
"loose",
|
|
960
|
+
"wide"
|
|
961
|
+
]);
|
|
962
|
+
//#endregion
|
|
894
963
|
//#region ../theme-core/src/tokens/colorTokenParts.ts
|
|
895
964
|
function parseOpacityPercent(source) {
|
|
896
965
|
const trimmed = source.trim();
|
|
@@ -1168,6 +1237,7 @@ const buttonEffectApplicationSchema = z.discriminatedUnion("effectId", [
|
|
|
1168
1237
|
z.strictObject({
|
|
1169
1238
|
effectId: z.literal("lift"),
|
|
1170
1239
|
options: z.strictObject({ amount: z.enum([
|
|
1240
|
+
"0.125",
|
|
1171
1241
|
"0.25",
|
|
1172
1242
|
"0.5",
|
|
1173
1243
|
"1"
|
|
@@ -1214,24 +1284,6 @@ const shadowSizeSchema = z.enum([
|
|
|
1214
1284
|
"medium",
|
|
1215
1285
|
"high"
|
|
1216
1286
|
]);
|
|
1217
|
-
const textTransformSchema = z.enum([
|
|
1218
|
-
"none",
|
|
1219
|
-
"uppercase",
|
|
1220
|
-
"lowercase",
|
|
1221
|
-
"capitalize"
|
|
1222
|
-
]);
|
|
1223
|
-
const fontWeightSchema = z.union([
|
|
1224
|
-
z.literal(500),
|
|
1225
|
-
z.literal(600),
|
|
1226
|
-
z.literal(700),
|
|
1227
|
-
z.literal(800)
|
|
1228
|
-
]);
|
|
1229
|
-
const buttonTypographySchema = z.enum(["body", "heading"]);
|
|
1230
|
-
const letterSpacingSchema = z.enum([
|
|
1231
|
-
"tight",
|
|
1232
|
-
"normal",
|
|
1233
|
-
"loose"
|
|
1234
|
-
]);
|
|
1235
1287
|
const hoverTransformSchema = z.enum([
|
|
1236
1288
|
"none",
|
|
1237
1289
|
"lift",
|
|
@@ -1303,7 +1355,8 @@ const paddingShorthandSchema = z.string().refine((value) => {
|
|
|
1303
1355
|
}, { message: "Padding must be two space-separated CSS length tokens (e.g. \"0.5rem 1rem\"). Use `0` for zero." });
|
|
1304
1356
|
const buttonSizeConfigSchema = z.object({
|
|
1305
1357
|
padding: paddingShorthandSchema,
|
|
1306
|
-
fontSize: z.string().optional()
|
|
1358
|
+
fontSize: z.string().optional(),
|
|
1359
|
+
borderRadius: z.string().optional()
|
|
1307
1360
|
});
|
|
1308
1361
|
/**
|
|
1309
1362
|
* `xl` is optional on the wire so themes persisted before the `xl` size was
|
|
@@ -1426,12 +1479,20 @@ const buttonVisualAppearanceSchema = z.strictObject({
|
|
|
1426
1479
|
textTransform: textTransformSchema
|
|
1427
1480
|
}),
|
|
1428
1481
|
effects: z.array(buttonEffectApplicationSchema),
|
|
1482
|
+
transform: z.literal("none").optional(),
|
|
1429
1483
|
contextualHover: contextualButtonHoverSchema.optional()
|
|
1430
1484
|
});
|
|
1431
1485
|
const buttonVisualStatesSchema = z.strictObject({
|
|
1432
1486
|
base: buttonVisualAppearanceSchema.extend({ shadow: variantShadowSchema }),
|
|
1433
1487
|
hover: buttonVisualAppearanceSchema.extend({ shadow: variantShadowSchema }),
|
|
1434
|
-
focus: buttonVisualAppearanceSchema.extend({
|
|
1488
|
+
focus: buttonVisualAppearanceSchema.extend({
|
|
1489
|
+
shadow: z.literal("focus-indicator"),
|
|
1490
|
+
indicator: z.strictObject({
|
|
1491
|
+
kind: z.literal("surface-ink"),
|
|
1492
|
+
width: z.union([z.literal(2), z.literal(3)]),
|
|
1493
|
+
offset: z.union([z.literal(3), z.literal(4)])
|
|
1494
|
+
}).optional()
|
|
1495
|
+
}),
|
|
1435
1496
|
active: buttonVisualAppearanceSchema.extend({ shadow: variantShadowSchema }),
|
|
1436
1497
|
disabled: buttonVisualAppearanceSchema.extend({ shadow: variantShadowSchema })
|
|
1437
1498
|
});
|
|
@@ -2042,20 +2103,119 @@ const themeLookMetadataSchema = z.object({
|
|
|
2042
2103
|
skinMarks: skinMarksSchema.optional()
|
|
2043
2104
|
});
|
|
2044
2105
|
//#endregion
|
|
2045
|
-
//#region ../
|
|
2046
|
-
|
|
2047
|
-
"
|
|
2048
|
-
|
|
2049
|
-
|
|
2050
|
-
"
|
|
2051
|
-
|
|
2052
|
-
|
|
2053
|
-
|
|
2054
|
-
|
|
2055
|
-
|
|
2106
|
+
//#region ../media-core/src/identifiers.ts
|
|
2107
|
+
function slugifyMediaIdentifier(value) {
|
|
2108
|
+
return value.toLowerCase().trim().replace(/[^a-z0-9\s-]/g, "").replace(/\s+/g, "-").replace(/-+/g, "-");
|
|
2109
|
+
}
|
|
2110
|
+
function parseMediaIdentifier(value) {
|
|
2111
|
+
if (typeof value !== "string") return err({ kind: "not_string" });
|
|
2112
|
+
const trimmed = value.trim();
|
|
2113
|
+
if (trimmed.length === 0) return err({ kind: "empty_identifier" });
|
|
2114
|
+
const normalized = slugifyMediaIdentifier(trimmed);
|
|
2115
|
+
if (normalized.length === 0) return err({
|
|
2116
|
+
kind: "empty_after_normalization",
|
|
2117
|
+
value
|
|
2118
|
+
});
|
|
2119
|
+
return ok(normalized);
|
|
2120
|
+
}
|
|
2121
|
+
/**
|
|
2122
|
+
* Admits identifiers read from trusted persistence without repairing dirty data in memory.
|
|
2123
|
+
* User input should use parseMediaIdentifier, which intentionally canonicalizes it.
|
|
2124
|
+
*/
|
|
2125
|
+
function parseCanonicalMediaIdentifier(value) {
|
|
2126
|
+
if (typeof value !== "string") return err({ kind: "not_string" });
|
|
2127
|
+
const parsed = parseMediaIdentifier(value);
|
|
2128
|
+
if (!parsed.ok) return parsed;
|
|
2129
|
+
if (value !== parsed.value) return err({
|
|
2130
|
+
kind: "non_canonical_identifier",
|
|
2131
|
+
value,
|
|
2132
|
+
canonical: parsed.value
|
|
2133
|
+
});
|
|
2134
|
+
return parsed;
|
|
2056
2135
|
}
|
|
2057
2136
|
//#endregion
|
|
2058
|
-
//#region ../
|
|
2137
|
+
//#region ../media-core/src/mediaIdentifierSchema.ts
|
|
2138
|
+
/** Strict stored-reference admission delegates the canonical identifier decision. */
|
|
2139
|
+
const mediaIdentifierSchema = z.string().transform((value, context) => {
|
|
2140
|
+
const parsed = parseCanonicalMediaIdentifier(value);
|
|
2141
|
+
if (parsed.ok) return parsed.value;
|
|
2142
|
+
context.addIssue({
|
|
2143
|
+
code: "custom",
|
|
2144
|
+
message: "Expected a canonical media identifier"
|
|
2145
|
+
});
|
|
2146
|
+
return z.NEVER;
|
|
2147
|
+
});
|
|
2148
|
+
//#endregion
|
|
2149
|
+
//#region ../media-core/src/mediaKinds.ts
|
|
2150
|
+
const mediaTypeDiscriminants = [
|
|
2151
|
+
"image",
|
|
2152
|
+
"video",
|
|
2153
|
+
"audio",
|
|
2154
|
+
"document",
|
|
2155
|
+
"spreadsheet",
|
|
2156
|
+
"archive"
|
|
2157
|
+
];
|
|
2158
|
+
//#endregion
|
|
2159
|
+
//#region ../media-core/src/renderableMediaAsset.ts
|
|
2160
|
+
/** Shared identifier indexing for admitted site-scoped projections. */
|
|
2161
|
+
function buildMediaIdentifierIndex(assets) {
|
|
2162
|
+
const index = new Map(assets.map((asset) => [asset.identifier, asset]));
|
|
2163
|
+
if (index.size !== assets.length) throw new Error("Duplicate media identifier in a site asset list");
|
|
2164
|
+
return index;
|
|
2165
|
+
}
|
|
2166
|
+
/** Index already admitted projections, including runtime registration updates. */
|
|
2167
|
+
function indexRenderableMediaAssets(assets) {
|
|
2168
|
+
if (!assets.length) return void 0;
|
|
2169
|
+
const byId = new Map(assets.map((asset) => [asset.id, asset]));
|
|
2170
|
+
const byIdentifier = buildMediaIdentifierIndex(assets);
|
|
2171
|
+
if (byId.size !== assets.length) throw new Error("Duplicate media asset identity in a site asset list");
|
|
2172
|
+
return {
|
|
2173
|
+
assets,
|
|
2174
|
+
byId,
|
|
2175
|
+
byIdentifier
|
|
2176
|
+
};
|
|
2177
|
+
}
|
|
2178
|
+
/** A portable reference never uses an incidental UUID, URL or storage snapshot for identity. */
|
|
2179
|
+
function resolveManagedMediaReference(reference, index) {
|
|
2180
|
+
const asset = index?.byIdentifier.get(reference.identifier);
|
|
2181
|
+
return asset ? {
|
|
2182
|
+
kind: "resolved",
|
|
2183
|
+
reference,
|
|
2184
|
+
asset
|
|
2185
|
+
} : {
|
|
2186
|
+
kind: "missing",
|
|
2187
|
+
reference
|
|
2188
|
+
};
|
|
2189
|
+
}
|
|
2190
|
+
//#endregion
|
|
2191
|
+
//#region ../media-core/src/renderableMediaAssetAdmission.ts
|
|
2192
|
+
const mediaAssetIdSchema = z.string().transform((value, context) => {
|
|
2193
|
+
const parsed = parseMediaAssetId(value);
|
|
2194
|
+
if (parsed.ok) return parsed.value;
|
|
2195
|
+
context.addIssue({
|
|
2196
|
+
code: "custom",
|
|
2197
|
+
message: "Expected a media asset ID"
|
|
2198
|
+
});
|
|
2199
|
+
return z.NEVER;
|
|
2200
|
+
});
|
|
2201
|
+
const nonemptyStorageValue = z.string().refine((value) => value.trim().length > 0);
|
|
2202
|
+
const renderableMediaAssetSchema = z.object({
|
|
2203
|
+
id: mediaAssetIdSchema,
|
|
2204
|
+
identifier: mediaIdentifierSchema,
|
|
2205
|
+
storageBucket: nonemptyStorageValue,
|
|
2206
|
+
storagePath: nonemptyStorageValue,
|
|
2207
|
+
mimeType: nonemptyStorageValue,
|
|
2208
|
+
filename: z.string().optional(),
|
|
2209
|
+
width: z.number().positive().nullable(),
|
|
2210
|
+
height: z.number().positive().nullable()
|
|
2211
|
+
});
|
|
2212
|
+
/** Admission precedes the identifier-only runtime resolution decision. */
|
|
2213
|
+
function buildRenderableMediaAssetIndex(assets) {
|
|
2214
|
+
if (!assets?.length) return void 0;
|
|
2215
|
+
return indexRenderableMediaAssets(assets.map((asset) => renderableMediaAssetSchema.parse(asset)));
|
|
2216
|
+
}
|
|
2217
|
+
//#endregion
|
|
2218
|
+
//#region ../media-core/src/media.ts
|
|
2059
2219
|
const hotspotSchema = z.object({
|
|
2060
2220
|
x: z.number().min(0).max(1),
|
|
2061
2221
|
y: z.number().min(0).max(1),
|
|
@@ -2089,54 +2249,56 @@ const transformSchema = z.object({
|
|
|
2089
2249
|
rotation: rotationSchema.optional()
|
|
2090
2250
|
});
|
|
2091
2251
|
const mediaPosterSchema = z.discriminatedUnion("tag", [z.object({
|
|
2092
|
-
tag: z.literal("
|
|
2093
|
-
|
|
2094
|
-
|
|
2095
|
-
storagePath: z.string().min(1)
|
|
2096
|
-
}), z.object({
|
|
2252
|
+
tag: z.literal("media"),
|
|
2253
|
+
identifier: mediaIdentifierSchema
|
|
2254
|
+
}).strict(), z.object({
|
|
2097
2255
|
tag: z.literal("external-src"),
|
|
2098
|
-
assetId: z.string().optional(),
|
|
2099
2256
|
src: z.string().url()
|
|
2100
|
-
})]);
|
|
2101
|
-
const
|
|
2257
|
+
}).strict()]);
|
|
2258
|
+
const mediaUsageShape = {
|
|
2102
2259
|
purpose: z.string().optional(),
|
|
2103
2260
|
placeholder: z.boolean().default(true).optional(),
|
|
2104
|
-
assetId: z.string().optional(),
|
|
2105
|
-
identifier: z.string().optional(),
|
|
2106
|
-
src: z.string().optional(),
|
|
2107
2261
|
alt: z.string().optional(),
|
|
2108
2262
|
filename: z.string().optional(),
|
|
2109
|
-
mimeType: z.string().optional(),
|
|
2110
2263
|
width: z.number().optional(),
|
|
2111
2264
|
height: z.number().optional(),
|
|
2112
|
-
storageBucket: z.string().optional(),
|
|
2113
|
-
storagePath: z.string().optional(),
|
|
2114
2265
|
poster: mediaPosterSchema.optional(),
|
|
2115
2266
|
transform: transformSchema.optional()
|
|
2116
|
-
}
|
|
2117
|
-
const
|
|
2267
|
+
};
|
|
2268
|
+
const environmentExclusions = {
|
|
2269
|
+
assetId: z.never().optional(),
|
|
2270
|
+
id: z.never().optional(),
|
|
2271
|
+
src: z.never().optional(),
|
|
2272
|
+
storageBucket: z.never().optional(),
|
|
2273
|
+
storagePath: z.never().optional(),
|
|
2274
|
+
mimeType: z.never().optional()
|
|
2275
|
+
};
|
|
2276
|
+
const mediaBaseSchema = z.object({
|
|
2277
|
+
...mediaUsageShape,
|
|
2278
|
+
...environmentExclusions,
|
|
2279
|
+
identifier: mediaIdentifierSchema
|
|
2280
|
+
}).strict();
|
|
2118
2281
|
const imageMediaSchema = mediaBaseSchema.extend({ type: z.literal("image") });
|
|
2119
2282
|
const videoMediaSchema = mediaBaseSchema.extend({ type: z.literal("video") });
|
|
2120
|
-
const
|
|
2121
|
-
const
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
persistableMediaBaseSchema.extend({ type: z.literal("archive") })
|
|
2283
|
+
const mediaSchema = mediaBaseSchema.extend({ type: z.enum(mediaTypeDiscriminants) });
|
|
2284
|
+
const externalMediaSchema = z.object({
|
|
2285
|
+
...mediaUsageShape,
|
|
2286
|
+
...environmentExclusions,
|
|
2287
|
+
type: z.enum(mediaTypeDiscriminants),
|
|
2288
|
+
src: z.string().min(1),
|
|
2289
|
+
identifier: z.never().optional()
|
|
2290
|
+
}).strict();
|
|
2291
|
+
const assetMediaSchema = z.object({
|
|
2292
|
+
...mediaUsageShape,
|
|
2293
|
+
...environmentExclusions,
|
|
2294
|
+
type: z.enum(mediaTypeDiscriminants),
|
|
2295
|
+
asset: renderableMediaAssetSchema,
|
|
2296
|
+
identifier: z.never().optional()
|
|
2297
|
+
}).strict();
|
|
2298
|
+
const runtimeMediaSchema = z.union([
|
|
2299
|
+
mediaSchema,
|
|
2300
|
+
externalMediaSchema,
|
|
2301
|
+
assetMediaSchema
|
|
2140
2302
|
]);
|
|
2141
2303
|
//#endregion
|
|
2142
2304
|
//#region ../theme-core/src/palette/colors.ts
|
|
@@ -4005,6 +4167,8 @@ const GRADIENT_DIRECTION_MAP = {
|
|
|
4005
4167
|
*/
|
|
4006
4168
|
const BORDER_RADIUS_MAP = {
|
|
4007
4169
|
"rounded-none": "0",
|
|
4170
|
+
"rounded-3px": "3px",
|
|
4171
|
+
"rounded-10px": "10px",
|
|
4008
4172
|
"rounded-sm": "0.125rem",
|
|
4009
4173
|
"rounded": "0.25rem",
|
|
4010
4174
|
"rounded-md": "0.375rem",
|
|
@@ -4078,6 +4242,10 @@ const BORDER_WIDTH_MAP = {
|
|
|
4078
4242
|
*/
|
|
4079
4243
|
const FONT_SIZE_MAP = {
|
|
4080
4244
|
"text-xs": "0.75rem",
|
|
4245
|
+
"text-13px": "0.8125rem",
|
|
4246
|
+
"text-15px": "0.9375rem",
|
|
4247
|
+
"text-17px": "1.0625rem",
|
|
4248
|
+
"text-19px": "1.1875rem",
|
|
4081
4249
|
"text-sm": "0.875rem",
|
|
4082
4250
|
"text-base": "1rem",
|
|
4083
4251
|
"text-lg": "1.125rem",
|
|
@@ -4213,7 +4381,9 @@ function buttonTypographyDeclarations(type) {
|
|
|
4213
4381
|
const spacing = type.letterSpacing === null ? null : type.letterSpacing === "heading" ? "var(--ls-heading)" : {
|
|
4214
4382
|
tight: "-0.025em",
|
|
4215
4383
|
normal: "0",
|
|
4216
|
-
|
|
4384
|
+
slight: "0.01em",
|
|
4385
|
+
loose: "0.05em",
|
|
4386
|
+
wide: "0.125em"
|
|
4217
4387
|
}[type.letterSpacing];
|
|
4218
4388
|
return [
|
|
4219
4389
|
["font-weight", String(type.fontWeight)],
|
|
@@ -4233,21 +4403,23 @@ function buttonShadow(shadow, tokens) {
|
|
|
4233
4403
|
function buttonBorder(border, tokens) {
|
|
4234
4404
|
return border === "none" ? null : `${BORDER_WIDTH_MAP[border.widthClass] || "1px"} solid ${border.boundaryInk ? tokens.getColor(border.boundaryInk) : "currentColor"}`;
|
|
4235
4405
|
}
|
|
4236
|
-
|
|
4237
|
-
|
|
4238
|
-
const
|
|
4239
|
-
const declared = new Map(buttonTypographyDeclarations(state.typography));
|
|
4406
|
+
function buttonTypographyChanges(base, state) {
|
|
4407
|
+
const original = new Map(buttonTypographyDeclarations(base));
|
|
4408
|
+
const declared = new Map(buttonTypographyDeclarations(state));
|
|
4240
4409
|
const resets = [
|
|
4241
4410
|
["font-style", "normal"],
|
|
4242
4411
|
["text-transform", "none"],
|
|
4243
4412
|
["letter-spacing", "normal"]
|
|
4244
4413
|
].filter(([property]) => original.has(property) && !declared.has(property));
|
|
4245
|
-
|
|
4414
|
+
return [...declared, ...resets].filter(([property, value]) => original.get(property) !== value);
|
|
4415
|
+
}
|
|
4416
|
+
/** Emit only changed declarations; identical states keep historical CSS bytes. */
|
|
4417
|
+
function buttonStateAppearanceDeclarations(base, state, tokens, disabled = false) {
|
|
4246
4418
|
const border = buttonBorder(state.border, tokens);
|
|
4247
4419
|
const radius = buttonRadius(state.borderRadius);
|
|
4248
4420
|
const shadow = !disabled && state.shadow !== "focus-indicator" ? buttonShadow(state.shadow, tokens) : null;
|
|
4249
4421
|
return [
|
|
4250
|
-
...
|
|
4422
|
+
...buttonTypographyChanges(base.typography, state.typography),
|
|
4251
4423
|
...buttonRadius(base.borderRadius) === radius ? [] : [["border-radius", radius]],
|
|
4252
4424
|
...buttonBorder(base.border, tokens) === border ? [] : [["border", border ?? "none"]],
|
|
4253
4425
|
...shadow === null || base.shadow === "focus-indicator" || buttonShadow(base.shadow, tokens) === shadow ? [] : [["box-shadow", shadow]]
|
|
@@ -4708,6 +4880,10 @@ function validateButtonTextContrast(input) {
|
|
|
4708
4880
|
}
|
|
4709
4881
|
};
|
|
4710
4882
|
}
|
|
4883
|
+
/** A text-token slab inverts the palette's text/background pair, including text shades. */
|
|
4884
|
+
function solidForegroundToken(backgroundToken) {
|
|
4885
|
+
return /^text(?:-\d+)?$/.test(backgroundToken) ? "background" : onColorTokenName(backgroundToken);
|
|
4886
|
+
}
|
|
4711
4887
|
//#endregion
|
|
4712
4888
|
//#region ../theme-core/src/buttons/contextualHover.ts
|
|
4713
4889
|
function resolveContextualHoverPreference(input) {
|
|
@@ -4805,7 +4981,7 @@ function candidate(family, shade, currentShade, direction, seedHex, palette) {
|
|
|
4805
4981
|
}
|
|
4806
4982
|
function hasSafeTextContrast(token, palette) {
|
|
4807
4983
|
const background = palette[token];
|
|
4808
|
-
const foreground = palette[
|
|
4984
|
+
const foreground = palette[solidForegroundToken(token)];
|
|
4809
4985
|
return typeof background === "string" && typeof foreground === "string" && contrastRatio(background, foreground) >= BUTTON_CONTRAST_POLICY.textMinimumRatio;
|
|
4810
4986
|
}
|
|
4811
4987
|
function isSafeCandidate(token, palette, surface) {
|
|
@@ -4900,6 +5076,13 @@ function compileDeclaredVisualStates(input, states) {
|
|
|
4900
5076
|
const colours = collectStateColours(mapVisualStates((state) => compileDeclaredVisualState(input, states, state, state === "hover" ? hover.treatment : states[state].background)));
|
|
4901
5077
|
return colours.ok ? {
|
|
4902
5078
|
...colours,
|
|
5079
|
+
focusIndicator: states.focus.indicator ? {
|
|
5080
|
+
kind: "surface-role",
|
|
5081
|
+
colorCss: input.surface?.foregroundCss ?? surfaceForegroundValue("text"),
|
|
5082
|
+
width: states.focus.indicator.width,
|
|
5083
|
+
offset: states.focus.indicator.offset,
|
|
5084
|
+
minimumSurfaceContrast: BUTTON_CONTRAST_POLICY.nonTextMinimumRatio
|
|
5085
|
+
} : colours.focusIndicator,
|
|
4903
5086
|
contextualHoverRepair: hover.repair
|
|
4904
5087
|
} : colours;
|
|
4905
5088
|
}
|
|
@@ -5037,7 +5220,7 @@ function resolveFocusIndicator(colour) {
|
|
|
5037
5220
|
function resolveSolid(input, backgroundToken, edge) {
|
|
5038
5221
|
const backgroundHex = paletteHex(input, backgroundToken);
|
|
5039
5222
|
if (!backgroundHex.ok) return backgroundHex;
|
|
5040
|
-
const foregroundToken = unsafeAsOpaqueButtonColourToken(
|
|
5223
|
+
const foregroundToken = unsafeAsOpaqueButtonColourToken(solidForegroundToken(backgroundToken));
|
|
5041
5224
|
const foregroundHex = input.palette[foregroundToken];
|
|
5042
5225
|
if (typeof foregroundHex !== "string") return {
|
|
5043
5226
|
ok: false,
|
|
@@ -8004,6 +8187,21 @@ const boxBackgroundSchema = z.discriminatedUnion("type", [
|
|
|
8004
8187
|
showVideoOnMobile: z.boolean().nullable().optional()
|
|
8005
8188
|
})
|
|
8006
8189
|
]);
|
|
8190
|
+
/** Application rendering sources are admitted separately from saved references. */
|
|
8191
|
+
const runtimeBoxBackgroundSchema = z.discriminatedUnion("type", [
|
|
8192
|
+
boxBackgroundSchema.options[0],
|
|
8193
|
+
boxBackgroundSchema.options[1],
|
|
8194
|
+
boxBackgroundSchema.options[2].extend({ image: z.union([
|
|
8195
|
+
imageMediaSchema,
|
|
8196
|
+
externalMediaSchema.extend({ type: z.literal("image") }),
|
|
8197
|
+
assetMediaSchema.extend({ type: z.literal("image") })
|
|
8198
|
+
]).nullable().optional() }),
|
|
8199
|
+
boxBackgroundSchema.options[3].extend({ image: z.union([
|
|
8200
|
+
videoMediaSchema,
|
|
8201
|
+
externalMediaSchema.extend({ type: z.literal("video") }),
|
|
8202
|
+
assetMediaSchema.extend({ type: z.literal("video") })
|
|
8203
|
+
]).nullable().optional() })
|
|
8204
|
+
]);
|
|
8007
8205
|
function normalizeAuthoringOpacity(value) {
|
|
8008
8206
|
if (!isRecord(value)) return value;
|
|
8009
8207
|
return {
|
|
@@ -8358,20 +8556,15 @@ const headerSchema = z.object({
|
|
|
8358
8556
|
const footerVariant = z.enum([
|
|
8359
8557
|
"simple",
|
|
8360
8558
|
"columns",
|
|
8361
|
-
"split"
|
|
8362
|
-
|
|
8559
|
+
"split",
|
|
8560
|
+
"centred"
|
|
8561
|
+
]).transform((value) => value === "columns" ? "simple" : value);
|
|
8363
8562
|
const footerMaxWidth = z.enum(["container", "full"]);
|
|
8364
8563
|
const footerNavLayoutMode = z.enum([
|
|
8365
8564
|
"stack",
|
|
8366
8565
|
"inline",
|
|
8367
8566
|
"inline-wrap"
|
|
8368
8567
|
]);
|
|
8369
|
-
const footerNavLayoutAlign = z.enum([
|
|
8370
|
-
"start",
|
|
8371
|
-
"center",
|
|
8372
|
-
"end",
|
|
8373
|
-
"space-between"
|
|
8374
|
-
]);
|
|
8375
8568
|
const footerSpacing = z.enum([
|
|
8376
8569
|
"none",
|
|
8377
8570
|
"tight",
|
|
@@ -8380,12 +8573,6 @@ const footerSpacing = z.enum([
|
|
|
8380
8573
|
"relaxed",
|
|
8381
8574
|
"spacious"
|
|
8382
8575
|
]);
|
|
8383
|
-
const footerLogoPlacement = z.enum([
|
|
8384
|
-
"left",
|
|
8385
|
-
"right",
|
|
8386
|
-
"above",
|
|
8387
|
-
"below"
|
|
8388
|
-
]);
|
|
8389
8576
|
const footerLogoSize = z.enum([
|
|
8390
8577
|
"sm",
|
|
8391
8578
|
"md",
|
|
@@ -8426,17 +8613,8 @@ const footerBottomBarSchema = z.object({
|
|
|
8426
8613
|
]).optional()
|
|
8427
8614
|
}).optional()
|
|
8428
8615
|
});
|
|
8429
|
-
const footerNavLayoutSchema = z.object({
|
|
8430
|
-
layout: footerNavLayoutMode.optional(),
|
|
8431
|
-
align: footerNavLayoutAlign.optional(),
|
|
8432
|
-
gapX: footerSpacing.optional(),
|
|
8433
|
-
gapY: footerSpacing.optional(),
|
|
8434
|
-
columns: z.number().int().min(1).max(6).optional()
|
|
8435
|
-
});
|
|
8616
|
+
const footerNavLayoutSchema = z.object({ layout: footerNavLayoutMode.optional() });
|
|
8436
8617
|
const footerLogoSchema = z.object({
|
|
8437
|
-
showLogo: z.boolean().default(true),
|
|
8438
|
-
showLogoText: z.boolean().optional(),
|
|
8439
|
-
placement: footerLogoPlacement.optional(),
|
|
8440
8618
|
size: footerLogoSize.optional(),
|
|
8441
8619
|
maxHeight: footerLogoMaxHeight.optional(),
|
|
8442
8620
|
align: z.enum([
|
|
@@ -8446,15 +8624,8 @@ const footerLogoSchema = z.object({
|
|
|
8446
8624
|
]).optional()
|
|
8447
8625
|
});
|
|
8448
8626
|
const footerSchema = z.object({
|
|
8449
|
-
/**
|
|
8450
|
-
* SDK-only footer rendering mode.
|
|
8451
|
-
*
|
|
8452
|
-
* Historical persisted field; SDK rendering mode now lives in layout.footerMode.
|
|
8453
|
-
*/
|
|
8454
|
-
mode: footerModeSchema.optional(),
|
|
8455
8627
|
variant: footerVariant,
|
|
8456
8628
|
maxWidth: footerMaxWidth,
|
|
8457
|
-
showLogoText: z.boolean().optional(),
|
|
8458
8629
|
background: headerBackgroundSchema.default({
|
|
8459
8630
|
type: "color",
|
|
8460
8631
|
color: "surface"
|
|
@@ -9335,6 +9506,7 @@ const liftEffect = {
|
|
|
9335
9506
|
label: "Lift Amount",
|
|
9336
9507
|
default: "0.5",
|
|
9337
9508
|
options: [
|
|
9509
|
+
"0.125",
|
|
9338
9510
|
"0.25",
|
|
9339
9511
|
"0.5",
|
|
9340
9512
|
"1"
|
|
@@ -10300,7 +10472,7 @@ function resolvedButtonFocusDeclarations(indicator, role) {
|
|
|
10300
10472
|
["outline", value("outline", `2px solid ${indicator.innerCss}`)],
|
|
10301
10473
|
["outline-offset", value("outline-offset", "2px")],
|
|
10302
10474
|
["box-shadow", value("box-shadow", `0 0 0 4px ${indicator.outerCss}`)]
|
|
10303
|
-
] : [["outline", value("outline",
|
|
10475
|
+
] : [["outline", value("outline", `${indicator.width ?? 3}px solid ${indicator.colorCss}`)], ["outline-offset", value("outline-offset", `${indicator.offset ?? 3}px`)]];
|
|
10304
10476
|
}
|
|
10305
10477
|
/**
|
|
10306
10478
|
* Disabled buttons are deliberately muted as unavailable controls. Native
|
|
@@ -10471,6 +10643,7 @@ function variantChunks(variant, global, themeSizes, themeId, tokens, theme, colo
|
|
|
10471
10643
|
]) out.push(variantStateColourRule(variant, variantId, themeId, state, colours[state], tokens));
|
|
10472
10644
|
const effects = variantEffectsCss(variant, nonColourEffects, themeId, tokens, theme);
|
|
10473
10645
|
if (effects) out.push({ raw: effects });
|
|
10646
|
+
out.push(...variantStateTransformRules(variant, selector));
|
|
10474
10647
|
out.push(variantFocusVisibleRule(variantId, themeId, focusIndicator));
|
|
10475
10648
|
const affordance = variantAffordanceRule(variant, selector);
|
|
10476
10649
|
if (affordance) out.push(affordance);
|
|
@@ -10584,12 +10757,27 @@ function variantDisabledRules(variant, variantId, themeId, colour, tokens) {
|
|
|
10584
10757
|
["pointer-events", "none"]
|
|
10585
10758
|
])];
|
|
10586
10759
|
}
|
|
10760
|
+
/** Explicit rest transforms follow hover effects so :active can return to rest. */
|
|
10761
|
+
function variantStateTransformRules(variant, selector) {
|
|
10762
|
+
return [
|
|
10763
|
+
"hover",
|
|
10764
|
+
"focus",
|
|
10765
|
+
"active"
|
|
10766
|
+
].flatMap((state) => {
|
|
10767
|
+
const transform = variant.visualStates?.[state].transform;
|
|
10768
|
+
return transform ? [rule(`${selector}:${state}`, [["transform", transform]])] : [];
|
|
10769
|
+
});
|
|
10770
|
+
}
|
|
10587
10771
|
function variantSizeRules(variant, variantId, themeSizes, themeId) {
|
|
10588
10772
|
const border = variant.visualStates?.base.border ?? variant.border;
|
|
10589
10773
|
const borderWidth = border && border !== "none" ? BORDER_WIDTH_MAP[border.widthClass] || "1px" : "0px";
|
|
10590
10774
|
return BUTTON_SIZE_NAMES.map((sizeName) => {
|
|
10591
10775
|
const config = resolveSizeConfig(variant, sizeName, themeSizes);
|
|
10592
|
-
return rule(`:where([data-theme-scope="${themeId}"]) ${themeButtonSelector(variantId, sizeName)}`, [
|
|
10776
|
+
return rule(`:where([data-theme-scope="${themeId}"]) ${themeButtonSelector(variantId, sizeName)}`, [
|
|
10777
|
+
...paddingDeclarations(config.padding, borderWidth),
|
|
10778
|
+
...config.fontSize ? [["font-size", FONT_SIZE_MAP[config.fontSize] || "1rem"]] : [],
|
|
10779
|
+
...config.borderRadius ? [["border-radius", buttonRadius(config.borderRadius)]] : []
|
|
10780
|
+
]);
|
|
10593
10781
|
});
|
|
10594
10782
|
}
|
|
10595
10783
|
function variantStateSizeRules(variant, variantId, themeId) {
|
|
@@ -10604,11 +10792,24 @@ function variantStateSizeRules(variant, variantId, themeId) {
|
|
|
10604
10792
|
].flatMap((state) => BUTTON_SIZE_NAMES.flatMap((size) => {
|
|
10605
10793
|
const base = states.base.sizes[size];
|
|
10606
10794
|
const target = states[state].sizes[size];
|
|
10607
|
-
|
|
10795
|
+
const declarations = stateSizeDeclarations(base, target, width(states.base.border), width(states[state].border), states.base.borderRadius, states[state].borderRadius);
|
|
10796
|
+
if (declarations.length === 0) return [];
|
|
10608
10797
|
const selector = `:where([data-theme-scope="${themeId}"]) ${themeButtonSelector(variantId, size)}`;
|
|
10609
|
-
return [rule(state === "hover" ? [`${selector}:hover`, `${selector}[data-force-hover="true"]`] : `${selector}:${state}`,
|
|
10798
|
+
return [rule(state === "hover" ? [`${selector}:hover`, `${selector}[data-force-hover="true"]`] : `${selector}:${state}`, declarations)];
|
|
10610
10799
|
}));
|
|
10611
10800
|
}
|
|
10801
|
+
/** Size radius overrides remain owned by each state, just like padding and type. */
|
|
10802
|
+
function stateSizeDeclarations(base, target, baseWidth, targetWidth, baseRadius, targetRadius) {
|
|
10803
|
+
const originalRadius = buttonRadius(base.borderRadius ?? baseRadius);
|
|
10804
|
+
const radius = buttonRadius(target.borderRadius ?? targetRadius);
|
|
10805
|
+
const radiusChanges = originalRadius === radius ? [] : [["border-radius", radius]];
|
|
10806
|
+
if (base.padding === target.padding && base.fontSize === target.fontSize && baseWidth === targetWidth) return radiusChanges;
|
|
10807
|
+
return [
|
|
10808
|
+
...paddingDeclarations(target.padding, targetWidth),
|
|
10809
|
+
...target.fontSize ? [["font-size", FONT_SIZE_MAP[target.fontSize] || "1rem"]] : [],
|
|
10810
|
+
...radiusChanges
|
|
10811
|
+
];
|
|
10812
|
+
}
|
|
10612
10813
|
/** Layout contexts do not change a recipe: grouped actions share its ordinary box. */
|
|
10613
10814
|
function generateButtonActionLayoutCss(options) {
|
|
10614
10815
|
const system = options.buttonSystem ?? generateDefaultButtonSystem(options.theme);
|
|
@@ -10691,6 +10892,287 @@ function normalizeAppearance(appearance) {
|
|
|
10691
10892
|
};
|
|
10692
10893
|
}
|
|
10693
10894
|
//#endregion
|
|
10895
|
+
//#region ../theme-core/src/buttons/styles/recipes/lanternRecipes.ts
|
|
10896
|
+
const flatShadow = {
|
|
10897
|
+
elevation: "none",
|
|
10898
|
+
softness: null,
|
|
10899
|
+
position: "bottom"
|
|
10900
|
+
};
|
|
10901
|
+
const lift$1 = {
|
|
10902
|
+
effectId: "lift",
|
|
10903
|
+
options: { amount: "0.125" }
|
|
10904
|
+
};
|
|
10905
|
+
const tags = {
|
|
10906
|
+
tone: "classic",
|
|
10907
|
+
energy: "calm",
|
|
10908
|
+
motion: "subtle",
|
|
10909
|
+
era: "editorial"
|
|
10910
|
+
};
|
|
10911
|
+
/** Each role supplies complete states, including a flat surface-ink focus ring. */
|
|
10912
|
+
function states(base, hover, offset = 4, width = 2) {
|
|
10913
|
+
return {
|
|
10914
|
+
base,
|
|
10915
|
+
hover,
|
|
10916
|
+
focus: {
|
|
10917
|
+
...base,
|
|
10918
|
+
shadow: "focus-indicator",
|
|
10919
|
+
indicator: {
|
|
10920
|
+
kind: "surface-ink",
|
|
10921
|
+
width,
|
|
10922
|
+
offset
|
|
10923
|
+
}
|
|
10924
|
+
},
|
|
10925
|
+
active: {
|
|
10926
|
+
...base,
|
|
10927
|
+
transform: "none"
|
|
10928
|
+
},
|
|
10929
|
+
disabled: {
|
|
10930
|
+
...base,
|
|
10931
|
+
effects: []
|
|
10932
|
+
}
|
|
10933
|
+
};
|
|
10934
|
+
}
|
|
10935
|
+
const gilt = {
|
|
10936
|
+
text: "treatment",
|
|
10937
|
+
border: "none",
|
|
10938
|
+
borderRadius: "rounded-10px",
|
|
10939
|
+
shadow: flatShadow,
|
|
10940
|
+
sizes: {
|
|
10941
|
+
sm: {
|
|
10942
|
+
padding: "10px 20px",
|
|
10943
|
+
fontSize: "text-base",
|
|
10944
|
+
borderRadius: "rounded-lg"
|
|
10945
|
+
},
|
|
10946
|
+
md: {
|
|
10947
|
+
padding: "18px 36px",
|
|
10948
|
+
fontSize: "text-19px"
|
|
10949
|
+
},
|
|
10950
|
+
lg: {
|
|
10951
|
+
padding: "18px 36px",
|
|
10952
|
+
fontSize: "text-19px"
|
|
10953
|
+
},
|
|
10954
|
+
xl: {
|
|
10955
|
+
padding: "18px 36px",
|
|
10956
|
+
fontSize: "text-19px"
|
|
10957
|
+
}
|
|
10958
|
+
},
|
|
10959
|
+
typography: {
|
|
10960
|
+
fontWeight: 400,
|
|
10961
|
+
typography: "heading",
|
|
10962
|
+
fontSize: "text-19px",
|
|
10963
|
+
letterSpacing: "slight",
|
|
10964
|
+
italic: false,
|
|
10965
|
+
textTransform: "none"
|
|
10966
|
+
},
|
|
10967
|
+
effects: []
|
|
10968
|
+
};
|
|
10969
|
+
const giltPrimary = {
|
|
10970
|
+
...gilt,
|
|
10971
|
+
background: {
|
|
10972
|
+
type: "gradient",
|
|
10973
|
+
stops: ["accent", "primary"],
|
|
10974
|
+
direction: "to-br",
|
|
10975
|
+
foregroundToken: "onAccent"
|
|
10976
|
+
}
|
|
10977
|
+
};
|
|
10978
|
+
const giltPrimaryHover = {
|
|
10979
|
+
...giltPrimary,
|
|
10980
|
+
background: {
|
|
10981
|
+
...giltPrimary.background,
|
|
10982
|
+
stops: ["accent-400", "primary-400"],
|
|
10983
|
+
foregroundToken: "secondary-950"
|
|
10984
|
+
},
|
|
10985
|
+
effects: [lift$1]
|
|
10986
|
+
};
|
|
10987
|
+
const giltSecondary = {
|
|
10988
|
+
...gilt,
|
|
10989
|
+
background: {
|
|
10990
|
+
type: "solid",
|
|
10991
|
+
colorToken: "text"
|
|
10992
|
+
}
|
|
10993
|
+
};
|
|
10994
|
+
const giltSecondaryHover = {
|
|
10995
|
+
...giltSecondary,
|
|
10996
|
+
effects: [lift$1],
|
|
10997
|
+
contextualHover: {
|
|
10998
|
+
kind: "shade-shift",
|
|
10999
|
+
seedToken: unsafeAsOpaqueButtonColourToken("text"),
|
|
11000
|
+
fallbackDirection: "lighter"
|
|
11001
|
+
}
|
|
11002
|
+
};
|
|
11003
|
+
const giltPrimaryStates = states(giltPrimary, giltPrimaryHover);
|
|
11004
|
+
const giltSecondaryStates = states(giltSecondary, giltSecondaryHover);
|
|
11005
|
+
const giltSlabRecipe = defineStaticButtonStyleRecipe({
|
|
11006
|
+
id: "gilt-slab",
|
|
11007
|
+
accessibilityLabel: "Gilt slab",
|
|
11008
|
+
tags,
|
|
11009
|
+
system: { roles: {
|
|
11010
|
+
primary: { states: giltPrimaryStates },
|
|
11011
|
+
secondary: { states: giltSecondaryStates },
|
|
11012
|
+
outline: { states: giltSecondaryStates },
|
|
11013
|
+
ghost: { states: giltSecondaryStates },
|
|
11014
|
+
accent: { states: giltPrimaryStates }
|
|
11015
|
+
} }
|
|
11016
|
+
});
|
|
11017
|
+
const hairline = {
|
|
11018
|
+
text: "treatment",
|
|
11019
|
+
borderRadius: "rounded-3px",
|
|
11020
|
+
shadow: flatShadow,
|
|
11021
|
+
sizes: {
|
|
11022
|
+
sm: {
|
|
11023
|
+
padding: "9px 16px",
|
|
11024
|
+
fontSize: "text-xs"
|
|
11025
|
+
},
|
|
11026
|
+
md: {
|
|
11027
|
+
padding: "15px 28px",
|
|
11028
|
+
fontSize: "text-13px"
|
|
11029
|
+
},
|
|
11030
|
+
lg: {
|
|
11031
|
+
padding: "15px 28px",
|
|
11032
|
+
fontSize: "text-13px"
|
|
11033
|
+
},
|
|
11034
|
+
xl: {
|
|
11035
|
+
padding: "15px 28px",
|
|
11036
|
+
fontSize: "text-13px"
|
|
11037
|
+
}
|
|
11038
|
+
},
|
|
11039
|
+
typography: {
|
|
11040
|
+
fontWeight: 700,
|
|
11041
|
+
typography: "body",
|
|
11042
|
+
fontSize: "text-13px",
|
|
11043
|
+
letterSpacing: "wide",
|
|
11044
|
+
italic: false,
|
|
11045
|
+
textTransform: "uppercase"
|
|
11046
|
+
},
|
|
11047
|
+
effects: []
|
|
11048
|
+
};
|
|
11049
|
+
const hairlinePrimary = {
|
|
11050
|
+
...hairline,
|
|
11051
|
+
background: {
|
|
11052
|
+
type: "solid",
|
|
11053
|
+
colorToken: "primary"
|
|
11054
|
+
},
|
|
11055
|
+
border: {
|
|
11056
|
+
widthClass: "border",
|
|
11057
|
+
boundaryInk: unsafeAsOpaqueButtonColourToken("primary")
|
|
11058
|
+
}
|
|
11059
|
+
};
|
|
11060
|
+
const hairlineOutline = {
|
|
11061
|
+
...hairline,
|
|
11062
|
+
background: {
|
|
11063
|
+
type: "surface",
|
|
11064
|
+
role: "link"
|
|
11065
|
+
},
|
|
11066
|
+
border: {
|
|
11067
|
+
widthClass: "border",
|
|
11068
|
+
boundaryInk: unsafeAsOpaqueButtonColourToken("primary")
|
|
11069
|
+
}
|
|
11070
|
+
};
|
|
11071
|
+
const hairlineSecondary = {
|
|
11072
|
+
...hairlineOutline,
|
|
11073
|
+
border: {
|
|
11074
|
+
widthClass: "border",
|
|
11075
|
+
boundaryInk: unsafeAsOpaqueButtonColourToken("accent")
|
|
11076
|
+
}
|
|
11077
|
+
};
|
|
11078
|
+
const hairlineFilled = {
|
|
11079
|
+
...hairlineSecondary,
|
|
11080
|
+
background: {
|
|
11081
|
+
type: "solid",
|
|
11082
|
+
colorToken: "accent"
|
|
11083
|
+
}
|
|
11084
|
+
};
|
|
11085
|
+
const hairlinePrimaryStates = states(hairlinePrimary, hairlineOutline, 3);
|
|
11086
|
+
const hairlineSecondaryStates = states(hairlineSecondary, hairlineFilled, 3);
|
|
11087
|
+
const hairlineTabRecipe = defineStaticButtonStyleRecipe({
|
|
11088
|
+
id: "hairline-tab",
|
|
11089
|
+
accessibilityLabel: "Hairline tab",
|
|
11090
|
+
tags,
|
|
11091
|
+
system: { roles: {
|
|
11092
|
+
primary: { states: hairlinePrimaryStates },
|
|
11093
|
+
secondary: { states: hairlineSecondaryStates },
|
|
11094
|
+
outline: { states: hairlineSecondaryStates },
|
|
11095
|
+
ghost: { states: hairlineSecondaryStates },
|
|
11096
|
+
accent: { states: states(hairlineFilled, hairlineSecondary, 3) }
|
|
11097
|
+
} }
|
|
11098
|
+
});
|
|
11099
|
+
const marqueeAccent = {
|
|
11100
|
+
text: "treatment",
|
|
11101
|
+
borderRadius: "rounded-none",
|
|
11102
|
+
shadow: flatShadow,
|
|
11103
|
+
sizes: {
|
|
11104
|
+
sm: {
|
|
11105
|
+
padding: "8px 17px",
|
|
11106
|
+
fontSize: "text-15px"
|
|
11107
|
+
},
|
|
11108
|
+
md: {
|
|
11109
|
+
padding: "14px 25px",
|
|
11110
|
+
fontSize: "text-17px"
|
|
11111
|
+
},
|
|
11112
|
+
lg: {
|
|
11113
|
+
padding: "14px 25px",
|
|
11114
|
+
fontSize: "text-17px"
|
|
11115
|
+
},
|
|
11116
|
+
xl: {
|
|
11117
|
+
padding: "14px 25px",
|
|
11118
|
+
fontSize: "text-17px"
|
|
11119
|
+
}
|
|
11120
|
+
},
|
|
11121
|
+
typography: {
|
|
11122
|
+
fontWeight: 800,
|
|
11123
|
+
typography: "body",
|
|
11124
|
+
fontSize: "text-17px",
|
|
11125
|
+
letterSpacing: "loose",
|
|
11126
|
+
italic: false,
|
|
11127
|
+
textTransform: "uppercase"
|
|
11128
|
+
},
|
|
11129
|
+
effects: [],
|
|
11130
|
+
background: {
|
|
11131
|
+
type: "solid",
|
|
11132
|
+
colorToken: "accent"
|
|
11133
|
+
},
|
|
11134
|
+
border: {
|
|
11135
|
+
widthClass: "border-2",
|
|
11136
|
+
boundaryInk: unsafeAsOpaqueButtonColourToken("accent")
|
|
11137
|
+
}
|
|
11138
|
+
};
|
|
11139
|
+
const marqueePrimary = {
|
|
11140
|
+
...marqueeAccent,
|
|
11141
|
+
background: {
|
|
11142
|
+
type: "solid",
|
|
11143
|
+
colorToken: "primary"
|
|
11144
|
+
},
|
|
11145
|
+
border: {
|
|
11146
|
+
widthClass: "border-2",
|
|
11147
|
+
boundaryInk: unsafeAsOpaqueButtonColourToken("primary")
|
|
11148
|
+
}
|
|
11149
|
+
};
|
|
11150
|
+
const marqueeSecondary = {
|
|
11151
|
+
...marqueeAccent,
|
|
11152
|
+
background: {
|
|
11153
|
+
type: "solid",
|
|
11154
|
+
colorToken: "text"
|
|
11155
|
+
},
|
|
11156
|
+
border: {
|
|
11157
|
+
widthClass: "border-2",
|
|
11158
|
+
boundaryInk: unsafeAsOpaqueButtonColourToken("text")
|
|
11159
|
+
}
|
|
11160
|
+
};
|
|
11161
|
+
const marqueePrimaryStates = states(marqueeAccent, marqueePrimary, 4, 3);
|
|
11162
|
+
const marqueeSecondaryStates = states(marqueeSecondary, marqueeAccent, 4, 3);
|
|
11163
|
+
const marqueeRecipe = defineStaticButtonStyleRecipe({
|
|
11164
|
+
id: "marquee",
|
|
11165
|
+
accessibilityLabel: "Marquee",
|
|
11166
|
+
tags,
|
|
11167
|
+
system: { roles: {
|
|
11168
|
+
primary: { states: marqueePrimaryStates },
|
|
11169
|
+
secondary: { states: marqueeSecondaryStates },
|
|
11170
|
+
outline: { states: marqueeSecondaryStates },
|
|
11171
|
+
ghost: { states: marqueeSecondaryStates },
|
|
11172
|
+
accent: { states: marqueePrimaryStates }
|
|
11173
|
+
} }
|
|
11174
|
+
});
|
|
11175
|
+
//#endregion
|
|
10694
11176
|
//#region ../theme-core/src/buttons/styles/recipes/fulcrumRecipe.ts
|
|
10695
11177
|
const fulcrumSizes = {
|
|
10696
11178
|
sm: {
|
|
@@ -11432,7 +11914,10 @@ const BUTTON_STYLE_IDS = [
|
|
|
11432
11914
|
"offset-block",
|
|
11433
11915
|
"ringed-pill",
|
|
11434
11916
|
"square-outline",
|
|
11435
|
-
"fulcrum"
|
|
11917
|
+
"fulcrum",
|
|
11918
|
+
"gilt-slab",
|
|
11919
|
+
"hairline-tab",
|
|
11920
|
+
"marquee"
|
|
11436
11921
|
];
|
|
11437
11922
|
const quietArrowParametersSchema = z.object({ secondaryTreatment: z.enum(["outlined", "solid-accent"]) }).strict();
|
|
11438
11923
|
const flatInkHoverTreatmentSchema = z.enum([
|
|
@@ -11469,7 +11954,10 @@ const buttonStyleSelectionSchema = z.discriminatedUnion("styleId", [
|
|
|
11469
11954
|
selectionBranch("offset-block", emptyParametersSchema),
|
|
11470
11955
|
selectionBranch("ringed-pill", emptyParametersSchema),
|
|
11471
11956
|
selectionBranch("square-outline", emptyParametersSchema),
|
|
11472
|
-
selectionBranch("fulcrum", emptyParametersSchema)
|
|
11957
|
+
selectionBranch("fulcrum", emptyParametersSchema),
|
|
11958
|
+
selectionBranch("gilt-slab", emptyParametersSchema),
|
|
11959
|
+
selectionBranch("hairline-tab", emptyParametersSchema),
|
|
11960
|
+
selectionBranch("marquee", emptyParametersSchema)
|
|
11473
11961
|
]);
|
|
11474
11962
|
/**
|
|
11475
11963
|
* Stable identity for a validated style selection. Parsing first canonicalises
|
|
@@ -14996,7 +15484,10 @@ const buttonStyleRecipes = [
|
|
|
14996
15484
|
offsetBlockRecipe,
|
|
14997
15485
|
ringedPillRecipe,
|
|
14998
15486
|
squareOutlineRecipe,
|
|
14999
|
-
fulcrumRecipe
|
|
15487
|
+
fulcrumRecipe,
|
|
15488
|
+
giltSlabRecipe,
|
|
15489
|
+
hairlineTabRecipe,
|
|
15490
|
+
marqueeRecipe
|
|
15000
15491
|
];
|
|
15001
15492
|
const recipesById = new Map(buttonStyleRecipes.map((recipe) => [recipe.id, recipe]));
|
|
15002
15493
|
function findButtonStyleRecipe(id) {
|
|
@@ -15012,6 +15503,9 @@ function resolveButtonStyleSelection(selection) {
|
|
|
15012
15503
|
case "editorial-link": return resolveButtonStyleRecipe(editorialLinkRecipe, selection.parameters);
|
|
15013
15504
|
case "pebble": return resolveButtonStyleRecipe(pebbleRecipe, selection.parameters);
|
|
15014
15505
|
case "ink-stamp": return resolveButtonStyleRecipe(inkStampRecipe, selection.parameters);
|
|
15506
|
+
case "gilt-slab": return resolveButtonStyleRecipe(giltSlabRecipe, selection.parameters);
|
|
15507
|
+
case "hairline-tab": return resolveButtonStyleRecipe(hairlineTabRecipe, selection.parameters);
|
|
15508
|
+
case "marquee": return resolveButtonStyleRecipe(marqueeRecipe, selection.parameters);
|
|
15015
15509
|
case "fulcrum": return resolveButtonStyleRecipe(fulcrumRecipe, selection.parameters);
|
|
15016
15510
|
case "flat-ink": return resolveButtonStyleRecipe(flatInkRecipe, selection.parameters);
|
|
15017
15511
|
case "brushed-wash": return resolveButtonStyleRecipe(brushedWashRecipe, selection.parameters);
|
|
@@ -16347,4 +16841,4 @@ function ThemedAuthoredButton({ label, href, variant, size, extraClassName, disa
|
|
|
16347
16841
|
});
|
|
16348
16842
|
}
|
|
16349
16843
|
//#endregion
|
|
16350
|
-
export {
|
|
16844
|
+
export { headerInteractionPaletteValues as $, renderableMediaAssetSchema as $n, confirmationPaymentSchema as $r, TokenResolver as $t, updateButtonStyleHoverPreference as A, unsafeAsSiteId as Ai, DEFAULT_SURFACE_TEXT_COLOR as An, offeringsPreviewCompositionTreatmentValues as Ar, NAV_LINK_PADDING_MAP as At, generateInteractiveChildInheritanceCSS as B, hexColorSchema as Bn, VARIANT_ROLES as Br, LABEL_FONT_SIZE_MAP as Bt, MinusIcon as C, unsafeAsAppointmentServiceId as Ci, defaultThemeTokens as Cn, eyebrowTreatmentValues as Cr, selectLogoAccommodation as Ct, defaultButtonStyleSelectionFor as D, unsafeAsPassId as Di, featuresFromHex as Dn, introCompositionTreatmentValues as Dr, parseCustomCssRules as Dt, buttonStyleSelectionParameterValue as E, unsafeAsMediaAssetId as Ei, relativeLuminance as En, headingDecorationColorTokenValues as Er, parseBlockCustomCssRules as Et, generateButtonActionLayoutCss as F, __commonJSMin as Fi, generateShadowValue$1 as Fn, tileTreatmentValues as Fr, navLinkOwnsUnderline as Ft, corners as G, paletteValueKey as Gn, parseColorTokenParts as Gr, ICON_CONFIG as Gt, parseThemeForPersistence as H, paletteColorsEqual as Hn, parseThemeColorToken as Hr, ACCORDION_SPACING_MAP as Ht, generateButtonCss as I, __exportAll as Ii, cardRoleSchema as In, visibleHeadingDecorationFamilyValues as Ir, navEffectPolicy as It, themeSchema as J, imageMediaSchema as Jn, checkBrowserStripeKey as Jr, renderCssDeclarations as Jt, headerPositioningValues as K, paletteValueKeySchema as Kn, SpinnerNode as Kr, ICON_SIZE_PX as Kt, generateDefaultButtonSystem as L, __toESM as Li, cardRoleValues as Ln, buildFontPreviewUrl as Lr, FONT_WEIGHT_MAP$1 as Lt, buttonStyleSelectionKey as M, unsafeAsStoragePath as Mi, surfaceForegroundInputFromResolved as Mn, plainFrame as Mr, NAV_LINK_TEXT_SIZE_MAP as Mt, buttonStyleSelectionSchema as N, err as Ni, surfaceForegroundStyle as Nn, requireNonEmptyReadonlyArray as Nr, navLinkHoverColorCandidate as Nt, findButtonStyleRecipe as O, unsafeAsPositiveByteCount as Oi, hexToRgb as On, makeBoundaryId as Or, NAV_LINK_BORDER_RADIUS_MAP as Ot, buttonStyleSelectionsEqual as P, ok as Pi, surfaceForegroundValue as Pn, testimonialsCompositionTreatmentValues as Pr, navLinkOwnsHoverForeground as Pt, headerInteractionPalettePair as Q, buildRenderableMediaAssetIndex as Qn, getStripeMinimumChargeRequirement as Qr, toAccessibleColorSurfaceIntent as Qt, generateEffectsCSS as R, cardVariantRoleValues as Rn, generateFontFaceCss as Rr, INPUT_FONT_SIZE_MAP as Rt, FileTextIcon as S, unsafeAsAppointmentResourceId as Si, buildThemeTokens as Sn, eventListTreatmentValues as Sr, resolveBrandDisplay as St, buttonStyleHoverPreferenceValue as T, unsafeAsFormId as Ti, contrastRatio as Tn, flushPanelFrame as Tr, getComponentShadowVar as Tt, cardStylesOverrideSchema as U, paletteColorsSchema as Un, themeColorShadeSteps as Ur, ACCORDION_TRIGGER_FONT_SCALE as Ut, parseThemeButtonVariantId as V, paletteColorEntries as Vn, unsafeAsOpaqueButtonColourToken as Vr, ACCORDION_OPEN_ACCENT_THICKNESS as Vt, containerStylesOverrideSchema as W, paletteModeSchema as Wn, parseBlockColorToken as Wr, ACCORDION_TRIGGER_LETTER_SPACING as Wt, boxBackgroundSchema as X, mediaSchema as Xn, parseEventRegistrationErrorReason as Xr, resolveSurface as Xt, boxBackgroundOverlaySchema as Y, mediaPosterSchema as Yn, eventRegistrationErrors as Yr, contrastThresholdByPolicy as Yt, runtimeBoxBackgroundSchema as Z, runtimeMediaSchema as Zn, checkoutCopy as Zr, surfaceDecorationColors as Zt, CirclePlusIcon as _, parseFormId as _i, resolveSurfaceForeground as _n, assertNever as _r, stripStaleTransitionStyleGroup as _t, ThemedDownloadLink as a, resolveBookingCollectionOptionFacts as ai, textColorStyle as an, asAppearancePresetId as ar, BREAKPOINT_LG as at, FileAudioIcon as b, parseSiteId as bi, planForegroundHover as bn, defineFrameCapability as br, deterministicLogoFactsForShape as bt, isKnownIconName as c, getBookingInstalmentPlanIntervalCount as ci, opaqueSurfaceDeclarations as cn, asBoundaryOptionId as cr, MQ_MD_DOWN as ct, resolveIconPickerPreset as d, parseApiKeyId as di, resolveThemeColorReferenceValue as dn, asDesignEntryId as dr, MQ_TABLET_ONLY as dt, planCheckoutPaymentFlow as ei, backgroundColorStyle as en, indexRenderableMediaAssets as er, headerInteractionQuietPalette as et, SEMANTIC_ICON_DEFINITIONS as f, parseContentEntryId as fi, resolveTokenOrCssColorValue as fn, asDesignPageId as fr, headerVariantValues as ft, CircleMinusIcon as g, parseEventSeriesId as gi, surfaceToneFromForegroundToken as gn, asSiteStyleId as gr, siteChromeBackgroundOverrideOwner as gt, ChevronDownIcon as h, parseEventOfferingId as hi, selectLogoVariant as hn, asPageFlowPresetId as hr, pageDesignEditorBackgroundOverrideOwner as ht, ThemedButtonSpecimen as i, resolveAvailableBookingCollectionOptions as ii, rgbColorValue as in, skinTokenCssVars as ir, renderHeaderPaintTargetRules as it, updateButtonStyleSelectionChoice as j, unsafeAsStorageBucketName as ji, surfaceForegroundDeclarations as jn, panelFrame as jr, NAV_LINK_PADDING_X_MAP as jt, resolveButtonStyleSelection as k, unsafeAsPositiveSeconds as ki, rgbToHex as kn, noHeadingDecoration as kr, NAV_LINK_LETTER_SPACING_MAP as kt, ICON_PICKER_PRESETS as l, formatCurrencyAmount as li, isCssColorLiteral as ln, asDesignBlockId as lr, MQ_SM_DOWN as lt, ArrowDownIcon as m, parseEditorClientId as mi, PUBLIC_BUTTON_ROLES as mn, asLayoutVariantKey as mr, isThemeV2NormalEditorRawStylePath as mt, ThemedButton as n, isBookingCollectionEquivalentToUpfront as ni, cssVarValue as nn, mediaIdentifierSchema as nr, generateMobileOverlayBackdropFilterFix as nt, getIconComponent as o, getBookingLaterInstalments as oi, textColorValue as on, asBlockContentVersionId as or, BREAKPOINT_XL as ot, isSemanticIconId as p, parseContentVersionId as pi, generateShadowValue as pn, asDesignSystemTemplateId as pr, isThemeV2NormalEditorRawStyleFieldName as pt, sectionStylesOverrideSchema as q, requirePaletteColorsFromEntries as qn, clsx as qr, generateCardCss as qt, ThemedButtonLink as r, repriceBookingCollectionOptions as ri, mergeStyles as rn, parseCanonicalMediaIdentifier as rr, getHeaderPaintTargets as rt, getIconPickerOptionsForPreset as s, validateBookingPaymentOptionKinds as si, opaqueSurfaceContextFromTheme as sn, asBlockOrderIndex as sr, MQ_LG_UP as st, ThemedAuthoredButton as t, planFlexibleBalanceCreditFirst as ti, borderColorStyle as tn, resolveManagedMediaReference as tr, generateHeaderScrollTreatmentStyles as tt, isIconPickerPreset as u, expectParsedBrandedId as ui, resolveOnColorForThemeToken as un, asDesignBoundaryId as ur, MQ_SM_UP as ut, ClockIcon as v, parsePageId as vi, expandPalette as vn, defineBlockDesignCapability as vr, themeV2RuntimeStyleFieldNames as vt, PlusIcon as w, unsafeAsCustomerPassId as wi, ORDINARY_TEXT_MIN_CONTRAST_RATIO as wn, featureCardCompositionTreatmentValues as wr, getComponentBorderWidthPx as wt, FileSpreadsheetIcon as x, parseUserId as xi, resolveConcreteColorHex as xn, designIssueSeverityForPolicy as xr, logoSizePolicyValues as xt, FileArchiveIcon as y, parsePageSurfaceId as yi, getTextColorForBackground as yn, defineExactCatalog as yr, brandDisplayModeValues as yt, generateBaseInteractiveCSS as z, normalizeCardRole as zn, getSiteFontsStorageUrl as zr, INPUT_SPACING_MAP as zt };
|