@riverbankcms/sdk 0.77.1 → 0.78.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 +69 -0
- package/dist/{PreviewEditorSidebar-DVUG7GK4.mjs → PreviewEditorSidebar-RIKFQ72L.mjs} +4916 -4847
- package/dist/{PreviewEditorUI-P7RN4CDS.mjs → PreviewEditorUI-XO7TUWKK.mjs} +3 -3
- package/dist/SdkPreviewModeRuntime-LAGYMPNF.mjs +8 -0
- package/dist/_dts/ai/src/contracts/proposals.d.ts +154 -154
- package/dist/_dts/api/src/accessAdmin.d.ts +5 -0
- package/dist/_dts/api/src/billing.d.ts +3 -26
- package/dist/_dts/api/src/bookingVerticals.d.ts +4 -0
- package/dist/_dts/api/src/content-editor.d.ts +1 -0
- package/dist/_dts/api/src/demoDashboardMutationSurfaces.d.ts +46 -0
- package/dist/_dts/api/src/endpoints.d.ts +8 -0
- package/dist/_dts/api/src/index.d.ts +14 -2
- package/dist/_dts/api/src/navigation/dashboardBookingsNav.d.ts +87 -0
- package/dist/_dts/api/src/navigation/dashboardDemoNav.d.ts +5 -0
- package/dist/_dts/api/src/navigation/dashboardSettingsNav.d.ts +45 -0
- package/dist/_dts/api/src/navigation/dashboardSiteNav.d.ts +42 -0
- package/dist/_dts/api/src/navigation/dashboardTeamMemberNav.d.ts +24 -0
- package/dist/_dts/api/src/navigation/linkUrlType.d.ts +3 -0
- package/dist/_dts/api/src/navigation.d.ts +12 -0
- package/dist/_dts/api/src/publicExperienceEndpoints.d.ts +55 -26
- package/dist/_dts/api/src/staffAccess.d.ts +79 -0
- package/dist/_dts/api/src/types.d.ts +3 -1
- package/dist/_dts/api/src/workflows/automaticWorkflowTriggers.d.ts +21 -0
- package/dist/_dts/blocks/src/client/site-chrome.d.ts +4 -1
- package/dist/_dts/blocks/src/index.d.ts +1 -0
- package/dist/_dts/blocks/src/system/blocks/appointment-booking.d.ts +288 -288
- package/dist/_dts/blocks/src/system/blocks/blog-listing.d.ts +288 -288
- package/dist/_dts/blocks/src/system/blocks/cart.d.ts +288 -288
- package/dist/_dts/blocks/src/system/blocks/checkout.d.ts +288 -288
- package/dist/_dts/blocks/src/system/blocks/collection.d.ts +288 -288
- package/dist/_dts/blocks/src/system/blocks/courses/shared/schemas.d.ts +2 -2
- package/dist/_dts/blocks/src/system/blocks/faq.d.ts +294 -289
- package/dist/_dts/blocks/src/system/blocks/gifting.d.ts +288 -288
- package/dist/_dts/blocks/src/system/blocks/location-map.d.ts +1 -1
- package/dist/_dts/blocks/src/system/blocks/media-text.d.ts +21 -21
- package/dist/_dts/blocks/src/system/blocks/product-detail.d.ts +288 -288
- package/dist/_dts/blocks/src/system/blocks/product-list.d.ts +288 -288
- package/dist/_dts/blocks/src/system/blocks/shop.d.ts +288 -288
- package/dist/_dts/blocks/src/system/data/index.d.ts +5 -3
- package/dist/_dts/blocks/src/system/data/previewResolvedDataState.d.ts +45 -0
- package/dist/_dts/blocks/src/system/fields/boxStyles.d.ts +2 -1
- package/dist/_dts/blocks/src/system/fragments/library/faqAccordion.d.ts +5 -0
- package/dist/_dts/blocks/src/system/manifest/schema.d.ts +29 -29
- package/dist/_dts/blocks/src/system/node/fragments/headingDecoration.d.ts +10 -0
- package/dist/_dts/blocks/src/system/node/fragments/index.d.ts +1 -0
- package/dist/_dts/blocks/src/system/node/fragments/styledSection.d.ts +9 -0
- package/dist/_dts/blocks/src/system/runtime/api/client.d.ts +3 -2
- package/dist/_dts/blocks/src/system/runtime/api/endpoints.d.ts +8 -0
- package/dist/_dts/blocks/src/system/runtime/api/index.d.ts +1 -1
- package/dist/_dts/blocks/src/system/runtime/api/types.d.ts +43 -8
- package/dist/_dts/blocks/src/system/runtime/header/shared.d.ts +8 -7
- package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/EventCompactRow.d.ts +1 -4
- package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/utils.d.ts +7 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/header-section.client.d.ts +2 -8
- package/dist/_dts/blocks/src/system/runtime/nodes/header-section.server.d.ts +2 -9
- package/dist/_dts/blocks/src/system/runtime/nodes/shop-cart-discount-ui.d.ts +5 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/shop-checkout-form.d.ts +76 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/shop-checkout.state.d.ts +1 -4
- package/dist/_dts/blocks/src/system/runtime/nodes/shop-commerce-store.d.ts +2 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/shop-commerce.shared.d.ts +1 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/shop-discount-apply.state.d.ts +52 -0
- package/dist/_dts/blocks/src/system/runtime/nodes/shop.state.d.ts +2 -4
- package/dist/_dts/blocks/src/system/runtime/nodes/useDiscountApply.d.ts +21 -0
- package/dist/_dts/blocks/src/system/runtime/shared/components/DiscountCodeDisclosure.d.ts +54 -0
- package/dist/_dts/blocks/src/system/runtime/shared/components/index.d.ts +2 -0
- package/dist/_dts/blocks/src/system/runtime/shared/index.d.ts +2 -2
- package/dist/_dts/blocks/src/system/transforms/registry/ui.d.ts +1 -1
- package/dist/_dts/blocks/src/system/transforms/typed.d.ts +1 -1
- package/dist/_dts/content-editor/src/contentTypeEditorContentState.d.ts +26 -0
- package/dist/_dts/content-editor/src/definitions/factory.d.ts +75 -0
- package/dist/_dts/content-editor/src/entryWorkflows.d.ts +2 -0
- package/dist/_dts/content-editor/src/footerBlocksEditorState.d.ts +76 -0
- package/dist/_dts/content-editor/src/index.d.ts +5 -0
- package/dist/_dts/content-editor/src/pageWorkflowContent.d.ts +29 -0
- package/dist/_dts/content-model/src/content-types/schema.d.ts +3 -3
- package/dist/_dts/content-model/src/index.d.ts +1 -0
- package/dist/_dts/content-model/src/routeTemplate.d.ts +4 -0
- package/dist/_dts/content-model/src/templates/editorState.d.ts +25 -0
- package/dist/_dts/core/src/csv-cells.d.ts +10 -0
- package/dist/_dts/core/src/csv-date-filter.d.ts +27 -0
- package/dist/_dts/core/src/csv-escape.d.ts +1 -0
- package/dist/_dts/core/src/csv-filename.d.ts +18 -0
- package/dist/_dts/core/src/csv-render.d.ts +4 -0
- package/dist/_dts/core/src/csv-types.d.ts +116 -0
- package/dist/_dts/core/src/currency-format.d.ts +4 -0
- package/dist/_dts/core/src/demo-capability-policy.d.ts +29 -0
- package/dist/_dts/core/src/demo-claim-access.d.ts +14 -0
- package/dist/_dts/core/src/demo-lifecycle-status.d.ts +11 -0
- package/dist/_dts/core/src/demo-runtime.d.ts +47 -0
- package/dist/_dts/core/src/duration.d.ts +14 -0
- package/dist/_dts/core/src/email-format.d.ts +10 -0
- package/dist/_dts/core/src/field-errors.d.ts +1 -0
- package/dist/_dts/core/src/form-submission-preview.d.ts +24 -0
- package/dist/_dts/core/src/index.d.ts +20 -0
- package/dist/_dts/core/src/number-input.d.ts +22 -0
- package/dist/_dts/core/src/public-url-validation.d.ts +12 -0
- package/dist/_dts/core/src/slug.d.ts +39 -0
- package/dist/_dts/core/src/string.d.ts +19 -0
- package/dist/_dts/core/src/uuid.d.ts +6 -0
- package/dist/_dts/db/src/schemas/forms.d.ts +50 -50
- package/dist/_dts/media-core/src/assetsInUseSummary.d.ts +34 -0
- package/dist/_dts/media-core/src/bulkDeletePlanning.d.ts +24 -0
- package/dist/_dts/media-core/src/canonicalCropReview.d.ts +66 -0
- package/dist/_dts/media-core/src/classifyAllPlanning.d.ts +48 -0
- package/dist/_dts/media-core/src/filename.d.ts +1 -0
- package/dist/_dts/media-core/src/index.d.ts +10 -0
- package/dist/_dts/media-core/src/mediaAssetUsageStatus.d.ts +47 -0
- package/dist/_dts/media-core/src/mediaSettingsState.d.ts +3 -0
- package/dist/_dts/media-core/src/portableMediaReferences.d.ts +38 -0
- package/dist/_dts/media-core/src/uploadVerificationContract.d.ts +28 -0
- package/dist/_dts/media-core/src/videoAssetRepair.d.ts +38 -0
- package/dist/_dts/media-editor/src/mediaEditorDebug.d.ts +1 -0
- package/dist/_dts/path-utils/src/index.d.ts +8 -0
- package/dist/_dts/path-utils/src/redirectPaths.d.ts +26 -0
- package/dist/_dts/path-utils/src/safeAppPath.d.ts +26 -0
- package/dist/_dts/preview-next/src/client/preview/SiteChromeCustomizeButton.d.ts +2 -1
- package/dist/_dts/preview-next/src/client/preview/SiteChromeCustomizeContext.d.ts +4 -0
- package/dist/_dts/preview-next/src/client/preview/previewDocumentFrame.d.ts +31 -0
- package/dist/_dts/sdk/src/client/error.d.ts +3 -0
- package/dist/_dts/sdk/src/client/index.d.ts +2 -2
- package/dist/_dts/sdk/src/client/types.d.ts +37 -19
- package/dist/_dts/sdk/src/index.d.ts +2 -2
- package/dist/_dts/sdk/src/manifest/passes/pass1-fields.d.ts +16 -16
- package/dist/_dts/sdk/src/next/content-load-failure.d.ts +51 -0
- package/dist/_dts/sdk/src/next/index.d.ts +2 -1
- package/dist/_dts/sdk/src/next/types.d.ts +19 -0
- package/dist/_dts/sdk/src/portal/redirects.d.ts +1 -1
- package/dist/_dts/sdk/src/routing/index.d.ts +3 -2
- package/dist/_dts/sdk/src/routing/resolvePageContent.d.ts +71 -6
- package/dist/_dts/sdk/src/version.d.ts +1 -1
- package/dist/_dts/site-commands/src/commands.d.ts +12 -12
- package/dist/_dts/site-commands/src/index.d.ts +1 -0
- package/dist/_dts/site-commands/src/pagePaths.d.ts +6 -0
- package/dist/_dts/theme-core/src/accordions/siteStyleDefaults.d.ts +26 -0
- package/dist/_dts/theme-core/src/accordions/types.d.ts +1 -0
- package/dist/_dts/theme-core/src/blocks/vars/index.d.ts +1 -0
- package/dist/_dts/theme-core/src/fonts/index.d.ts +1 -0
- package/dist/_dts/theme-core/src/fonts/uploadFormat.d.ts +44 -0
- package/dist/_dts/theme-core/src/generated/containerResponsiveThemeCss.d.ts +1 -1
- package/dist/_dts/theme-core/src/index.d.ts +3 -1
- package/dist/_dts/theme-core/src/mock-themes/all.d.ts +36 -24
- package/dist/_dts/theme-core/src/navigation/generateNavLinkCSS.d.ts +6 -1
- package/dist/_dts/theme-core/src/navigation/types.d.ts +12 -0
- package/dist/_dts/theme-core/src/palette/variants/types.d.ts +3 -3
- package/dist/_dts/theme-core/src/runtime/themeCssVarNames.d.ts +7 -0
- package/dist/_dts/theme-core/src/schema.d.ts +64 -18
- package/dist/_dts/theme-core/src/site-styles/appearancePresetCatalog.d.ts +214 -34
- package/dist/_dts/theme-core/src/site-styles/appearancePresetTypes.d.ts +5 -2
- package/dist/_dts/theme-core/src/site-styles/blockAppearancePresets.d.ts +214 -34
- package/dist/_dts/theme-core/src/site-styles/curatedSiteStyles.d.ts +24 -0
- package/dist/_dts/theme-core/src/site-styles/designState.d.ts +31 -3
- package/dist/_dts/theme-core/src/site-styles/generatedSchemas.d.ts +4 -4
- package/dist/_dts/theme-core/src/site-styles/headerLooks.d.ts +33 -1
- package/dist/_dts/theme-core/src/site-styles/rawStyleFields.d.ts +4 -2
- package/dist/_dts/theme-core/src/site-styles/runtimeCompiler.d.ts +9 -1
- package/dist/_dts/theme-core/src/site-styles/types.d.ts +27 -2
- package/dist/_dts/theme-core/src/siteChrome.d.ts +17 -34
- package/dist/_dts/theme-core/src/siteChromeOverlayClearance.d.ts +22 -0
- package/dist/_dts/theme-core/src/siteChromePlacement.d.ts +22 -0
- package/dist/_dts/theme-core/src/siteChromePlanning.d.ts +32 -0
- package/dist/_dts/theme-core/src/tokens/themeColorTokens.d.ts +2 -2
- package/dist/{chunk-2SPENC5M.mjs → chunk-F7RTCZYN.mjs} +229 -50
- package/dist/{chunk-IENWFSLO.mjs → chunk-NIDXI46P.mjs} +1 -1
- package/dist/{chunk-KWJPDZH2.mjs → chunk-OECWLDHN.mjs} +2770 -620
- package/dist/{chunk-VX7B5VAC.mjs → chunk-SVMMM2NA.mjs} +8 -0
- package/dist/{chunk-6SMUFTXD.mjs → chunk-SXOLGNMX.mjs} +1 -1
- package/dist/{chunk-ZYEJLCTN.mjs → chunk-TXDES5P2.mjs} +2 -2
- package/dist/cli/index.mjs +1677 -440
- package/dist/client/{accordion-RZMQSYLR.mjs → accordion-EVDEOUPR.mjs} +2 -2
- package/dist/client/{bookingForm-NF4ASVNV.mjs → bookingForm-DIHBLC64.mjs} +27 -30
- package/dist/client/bookings.mjs +3707 -259
- package/dist/client/{carousel-LDX47ZIK.mjs → carousel-FEBQHIWI.mjs} +3 -4
- package/dist/client/{cart-RGXDS5F4.mjs → cart-7CKSXAE4.mjs} +8 -8
- package/dist/client/{checkout-P7WWSNNY.mjs → checkout-WKYCANLV.mjs} +8 -8
- package/dist/client/{chunk-JNC7CGHX.mjs → chunk-2SAVKN2M.mjs} +2 -2
- package/dist/client/{chunk-TQ5MSPDX.mjs → chunk-36WJCERQ.mjs} +1 -1
- package/dist/client/{chunk-R56FQ3RR.mjs → chunk-65F47D7Y.mjs} +280 -71
- package/dist/client/{chunk-L3DNHIJX.mjs → chunk-GUK2FPXQ.mjs} +23 -45
- package/dist/client/{chunk-PMAIXMAB.mjs → chunk-IVNCUVAV.mjs} +26 -21
- package/dist/client/{chunk-II7O4XN3.mjs → chunk-OFMSCGNY.mjs} +2 -2
- package/dist/client/chunk-PD6NBCEY.mjs +66 -0
- package/dist/client/{chunk-GMVTOKYG.mjs → chunk-RV6FX7UH.mjs} +510 -64
- package/dist/client/{chunk-E2TDNXCL.mjs → chunk-RZDWX7QW.mjs} +2 -1
- package/dist/client/{chunk-M3L3KYYR.mjs → chunk-UDNSI5PY.mjs} +12 -0
- package/dist/client/{chunk-JEZECJ3W.mjs → chunk-VPPMNXCF.mjs} +129 -3
- package/dist/client/{chunk-UFSWADAO.mjs → chunk-YDSEG6GZ.mjs} +5 -66
- package/dist/client/client.mjs +7070 -4561
- package/dist/client/{courseRegistration-7F65K5ZR.mjs → courseRegistration-5QF2PHKM.mjs} +14 -11
- package/dist/client/{eventCalendar-GLSC5KTL.mjs → eventCalendar-4ZOSETDU.mjs} +9 -9
- package/dist/client/{eventCombined-ZHK4WKUR.mjs → eventCombined-WQGU7JUX.mjs} +9 -9
- package/dist/client/{eventDetails-E3PJYBIN.mjs → eventDetails-AYWVUJ5Y.mjs} +9 -9
- package/dist/client/{eventListing-EMS3WC3E.mjs → eventListing-NT7C6UT5.mjs} +9 -9
- package/dist/client/{eventRegistration-NZOTVNPI.mjs → eventRegistration-OH24F4ZJ.mjs} +9 -9
- package/dist/client/{form-ETFZFATW.mjs → form-7L42SRBB.mjs} +6 -6
- package/dist/client/{headerSection-4LBP7ULT.mjs → headerSection-OZRZNZ52.mjs} +3 -3
- package/dist/client/hooks.mjs +1040 -278
- package/dist/client/{locationMap-5M655YSJ.mjs → locationMap-ZBXRPQ7C.mjs} +2 -2
- package/dist/client/{newsletterForm-QOUYW44O.mjs → newsletterForm-SNAGFF2I.mjs} +3 -3
- package/dist/client/{productDetail-O4DOCWQG.mjs → productDetail-I46BOFGV.mjs} +8 -8
- package/dist/client/{productList-A5RO5WIS.mjs → productList-BOYHTYI6.mjs} +8 -8
- package/dist/client/rendering/client.mjs +7090 -2645
- package/dist/client/rendering/islands.mjs +19 -19
- package/dist/client/rendering.mjs +6089 -3792
- package/dist/client/{shop-L4MZH4I2.mjs → shop-XTXPZTKR.mjs} +8 -8
- package/dist/preview-next/before-render.mjs +8 -0
- package/dist/preview-next/client/runtime.mjs +5 -5
- package/dist/preview-next/editor-chrome.css +10 -0
- package/dist/preview-next/middleware.mjs +8 -0
- package/dist/{sdk-runtime-6UT2S7KZ.mjs → sdk-runtime-ZJLKC6DR.mjs} +6 -6
- package/dist/server/components.mjs +2635 -1262
- package/dist/server/config-validation.mjs +1271 -509
- package/dist/server/config.mjs +1271 -509
- package/dist/server/data.mjs +1040 -278
- package/dist/server/index.mjs +488 -246
- package/dist/server/next.mjs +4087 -2147
- package/dist/server/page-converter.mjs +571 -115
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/rendering/server.mjs +2636 -1263
- package/dist/server/rendering.mjs +2654 -1268
- package/dist/server/routing.mjs +1729 -489
- package/dist/server/server.mjs +1532 -530
- package/dist/server/theme-bridge.mjs +3151 -131
- package/dist/server/theme.mjs +10 -1
- package/dist/styles/index.css +488 -48
- package/package.json +2 -1
- package/dist/SdkPreviewModeRuntime-KLPX47SE.mjs +0 -8
- package/dist/_dts/blocks/src/system/runtime/nodes/course-registration/DiscountCodeSection.d.ts +0 -7
- package/dist/_dts/preview-next/src/client/widgets/PreviewMediaField.d.ts +0 -4
- package/dist/client/chunk-OJPZEZU2.mjs +0 -31
- package/dist/client/chunk-RTZ3JKKX.mjs +0 -178
package/dist/client/bookings.mjs
CHANGED
|
@@ -86,7 +86,7 @@ function ze() {
|
|
|
86
86
|
/* @__PURE__ */ Te(P)
|
|
87
87
|
);
|
|
88
88
|
}
|
|
89
|
-
function
|
|
89
|
+
function z18(e) {
|
|
90
90
|
if (L) {
|
|
91
91
|
if (/* @__PURE__ */ Te(P) !== null)
|
|
92
92
|
throw Tt(), Je;
|
|
@@ -2115,12 +2115,12 @@ function ha(e, t) {
|
|
|
2115
2115
|
var mt = we(Dr, 2);
|
|
2116
2116
|
let Pr;
|
|
2117
2117
|
var We = X(mt);
|
|
2118
|
-
en(We), We.__change = ui,
|
|
2118
|
+
en(We), We.__change = ui, z18(mt);
|
|
2119
2119
|
var Ut = we(mt, 2), wi = X(Ut);
|
|
2120
2120
|
{
|
|
2121
2121
|
var pi = (n) => {
|
|
2122
2122
|
var u = na(), _ = Gr(u), y = X(_);
|
|
2123
|
-
Ge(y, () => c(re).verified),
|
|
2123
|
+
Ge(y, () => c(re).verified), z18(_);
|
|
2124
2124
|
var T = we(_, 2);
|
|
2125
2125
|
en(T), Pe(() => {
|
|
2126
2126
|
se(T, "name", V()), jo(T, c(Le));
|
|
@@ -2129,10 +2129,10 @@ function ha(e, t) {
|
|
|
2129
2129
|
{
|
|
2130
2130
|
var _ = (T) => {
|
|
2131
2131
|
var E = ia(), p = X(E);
|
|
2132
|
-
Ge(p, () => c(re).verifying),
|
|
2132
|
+
Ge(p, () => c(re).verifying), z18(E), ne(T, E);
|
|
2133
2133
|
}, y = (T) => {
|
|
2134
2134
|
var E = oa(), p = X(E);
|
|
2135
|
-
Ge(p, () => c(re).label),
|
|
2135
|
+
Ge(p, () => c(re).label), z18(E), Pe(() => se(E, "for", c(cr))), ne(T, E);
|
|
2136
2136
|
};
|
|
2137
2137
|
$e(
|
|
2138
2138
|
n,
|
|
@@ -2147,18 +2147,18 @@ function ha(e, t) {
|
|
|
2147
2147
|
c(C) === b.VERIFIED ? n(pi) : n(bi, false);
|
|
2148
2148
|
});
|
|
2149
2149
|
}
|
|
2150
|
-
|
|
2150
|
+
z18(Ut);
|
|
2151
2151
|
var yi = we(Ut, 2);
|
|
2152
2152
|
{
|
|
2153
2153
|
var Ei = (n) => {
|
|
2154
2154
|
var u = aa(), _ = X(u);
|
|
2155
|
-
se(_, "href", sr),
|
|
2155
|
+
se(_, "href", sr), z18(u), Pe(() => se(_, "aria-label", c(re).ariaLinkLabel)), ne(n, u);
|
|
2156
2156
|
};
|
|
2157
2157
|
$e(yi, (n) => {
|
|
2158
2158
|
(N() !== true || c(Dt)) && n(Ei);
|
|
2159
2159
|
});
|
|
2160
2160
|
}
|
|
2161
|
-
|
|
2161
|
+
z18(Mt);
|
|
2162
2162
|
var Or = we(Mt, 2);
|
|
2163
2163
|
{
|
|
2164
2164
|
var xi = (n) => {
|
|
@@ -2166,16 +2166,16 @@ function ha(e, t) {
|
|
|
2166
2166
|
{
|
|
2167
2167
|
var y = (E) => {
|
|
2168
2168
|
var p = la(), x = X(p);
|
|
2169
|
-
Ge(x, () => c(re).expired),
|
|
2169
|
+
Ge(x, () => c(re).expired), z18(p), Pe(() => se(p, "title", c(He))), ne(E, p);
|
|
2170
2170
|
}, T = (E) => {
|
|
2171
2171
|
var p = sa(), x = X(p);
|
|
2172
|
-
Ge(x, () => c(re).error),
|
|
2172
|
+
Ge(x, () => c(re).error), z18(p), Pe(() => se(p, "title", c(He))), ne(E, p);
|
|
2173
2173
|
};
|
|
2174
2174
|
$e(_, (E) => {
|
|
2175
2175
|
c(C) === b.EXPIRED ? E(y) : E(T, false);
|
|
2176
2176
|
});
|
|
2177
2177
|
}
|
|
2178
|
-
|
|
2178
|
+
z18(u), ne(n, u);
|
|
2179
2179
|
};
|
|
2180
2180
|
$e(Or, (n) => {
|
|
2181
2181
|
(c(He) || c(C) === b.EXPIRED) && n(xi);
|
|
@@ -2185,7 +2185,7 @@ function ha(e, t) {
|
|
|
2185
2185
|
{
|
|
2186
2186
|
var $i = (n) => {
|
|
2187
2187
|
var u = ua(), _ = X(u), y = X(_);
|
|
2188
|
-
Ge(y, () => c(re).footer),
|
|
2188
|
+
Ge(y, () => c(re).footer), z18(_), z18(u), ne(n, u);
|
|
2189
2189
|
};
|
|
2190
2190
|
$e(Fr, (n) => {
|
|
2191
2191
|
c(re).footer && (k() !== true || c(Dt)) && n($i);
|
|
@@ -2201,7 +2201,7 @@ function ha(e, t) {
|
|
|
2201
2201
|
v() && n(Ci);
|
|
2202
2202
|
});
|
|
2203
2203
|
}
|
|
2204
|
-
return
|
|
2204
|
+
return z18(ot), nn(ot, (n) => D(B, n), () => c(B)), Pe(
|
|
2205
2205
|
(n) => {
|
|
2206
2206
|
se(ot, "data-state", c(C)), se(ot, "data-floating", v()), Pr = Fo(mt, 1, "altcha-checkbox", null, Pr, n), se(We, "id", c(cr)), We.required = r2() !== "onsubmit" && (!v() || r2() !== "off");
|
|
2207
2207
|
},
|
|
@@ -2990,6 +2990,10 @@ var DISCOUNTS = {
|
|
|
2990
2990
|
available: {
|
|
2991
2991
|
path: "/public/sites/{siteId}/bookings/discounts/available",
|
|
2992
2992
|
method: "POST"
|
|
2993
|
+
},
|
|
2994
|
+
apply: {
|
|
2995
|
+
path: "/public/sites/{siteId}/bookings/discounts/apply",
|
|
2996
|
+
method: "POST"
|
|
2993
2997
|
}
|
|
2994
2998
|
};
|
|
2995
2999
|
var NEWSLETTER = {
|
|
@@ -3601,6 +3605,14 @@ function createBlockApi(config) {
|
|
|
3601
3605
|
body: { context: data.context, subtotalCents: data.subtotalCents }
|
|
3602
3606
|
});
|
|
3603
3607
|
},
|
|
3608
|
+
async applyDiscountCode(data) {
|
|
3609
|
+
const sid = requireSiteId();
|
|
3610
|
+
const path = buildPath(DISCOUNTS.apply.path, { siteId: sid });
|
|
3611
|
+
return request(DISCOUNTS.apply, {
|
|
3612
|
+
path,
|
|
3613
|
+
body: data
|
|
3614
|
+
});
|
|
3615
|
+
},
|
|
3604
3616
|
// Shop
|
|
3605
3617
|
async getPublicProducts(params) {
|
|
3606
3618
|
const sid = requireSiteId();
|
|
@@ -5256,7 +5268,8 @@ var accordionSystemSchema = z5.object({
|
|
|
5256
5268
|
icon: z5.object({
|
|
5257
5269
|
style: accordionIconSchema,
|
|
5258
5270
|
position: z5.enum(["left", "right"]),
|
|
5259
|
-
size: z5.enum(["sm", "md", "lg"])
|
|
5271
|
+
size: z5.enum(["sm", "md", "lg"]),
|
|
5272
|
+
colorToken: themeColorTokenSchema.optional()
|
|
5260
5273
|
}),
|
|
5261
5274
|
// Trigger (question) styling
|
|
5262
5275
|
trigger: z5.object({
|
|
@@ -5276,6 +5289,102 @@ var accordionSystemSchema = z5.object({
|
|
|
5276
5289
|
})
|
|
5277
5290
|
});
|
|
5278
5291
|
|
|
5292
|
+
// ../theme-core/src/site-styles/types.ts
|
|
5293
|
+
function asAppearancePresetId(value) {
|
|
5294
|
+
return brandNonEmptyString(value, "AppearancePresetId");
|
|
5295
|
+
}
|
|
5296
|
+
function asSiteStyleId(value) {
|
|
5297
|
+
const siteStyleId = brandNonEmptyString(value, "SiteStyleId");
|
|
5298
|
+
if (!siteStyleId.startsWith("site-style:")) {
|
|
5299
|
+
throw new Error(
|
|
5300
|
+
`SiteStyleId must start with "site-style:". Received: ${value}`
|
|
5301
|
+
);
|
|
5302
|
+
}
|
|
5303
|
+
return siteStyleId;
|
|
5304
|
+
}
|
|
5305
|
+
function asDesignSystemTemplateId(value) {
|
|
5306
|
+
return brandNonEmptyString(value, "DesignSystemTemplateId");
|
|
5307
|
+
}
|
|
5308
|
+
function assertNever3(value, message = "Unhandled Theme V2 variant") {
|
|
5309
|
+
throw new Error(`${message}: ${String(value)}`);
|
|
5310
|
+
}
|
|
5311
|
+
function brandNonEmptyString(value, label) {
|
|
5312
|
+
if (value.length === 0) {
|
|
5313
|
+
throw new Error(`${label} must be a non-empty string.`);
|
|
5314
|
+
}
|
|
5315
|
+
return value;
|
|
5316
|
+
}
|
|
5317
|
+
var plainFrame = {
|
|
5318
|
+
kind: "plain"
|
|
5319
|
+
};
|
|
5320
|
+
function panelFrame(treatment) {
|
|
5321
|
+
return { kind: "panel", treatment };
|
|
5322
|
+
}
|
|
5323
|
+
function flushPanelFrame(options) {
|
|
5324
|
+
return {
|
|
5325
|
+
kind: "flush-panel",
|
|
5326
|
+
treatment: options.treatment ?? "media-panel",
|
|
5327
|
+
bleed: options.bleed
|
|
5328
|
+
};
|
|
5329
|
+
}
|
|
5330
|
+
var tileTreatmentValues = [
|
|
5331
|
+
"default",
|
|
5332
|
+
"quiet",
|
|
5333
|
+
"brand-depth"
|
|
5334
|
+
];
|
|
5335
|
+
var eventListTreatmentValues = [
|
|
5336
|
+
"plain",
|
|
5337
|
+
"lined-panel"
|
|
5338
|
+
];
|
|
5339
|
+
var eyebrowTreatmentValues = [
|
|
5340
|
+
"plain",
|
|
5341
|
+
"pill",
|
|
5342
|
+
"accent-pill",
|
|
5343
|
+
"pill-bounce",
|
|
5344
|
+
"accent-pill-bounce"
|
|
5345
|
+
];
|
|
5346
|
+
var visibleHeadingDecorationFamilyValues = [
|
|
5347
|
+
"organic-squiggle",
|
|
5348
|
+
"short-center-rule"
|
|
5349
|
+
];
|
|
5350
|
+
var visibleHeadingDecorationPlacementValues = [
|
|
5351
|
+
"after-heading",
|
|
5352
|
+
"between-heading-and-body",
|
|
5353
|
+
"under-centered-heading"
|
|
5354
|
+
];
|
|
5355
|
+
var headingDecorationOverrideValues = [
|
|
5356
|
+
"site-default",
|
|
5357
|
+
"on",
|
|
5358
|
+
"off"
|
|
5359
|
+
];
|
|
5360
|
+
var headingDecorationColorTokenValues = [
|
|
5361
|
+
"text",
|
|
5362
|
+
"primary",
|
|
5363
|
+
"secondary",
|
|
5364
|
+
"accent",
|
|
5365
|
+
"border",
|
|
5366
|
+
"muted"
|
|
5367
|
+
];
|
|
5368
|
+
var accordionIconSetValues = [
|
|
5369
|
+
"plus",
|
|
5370
|
+
"chevron",
|
|
5371
|
+
"caret",
|
|
5372
|
+
"minimal-cross"
|
|
5373
|
+
];
|
|
5374
|
+
var accordionIconColorTokenValues = [
|
|
5375
|
+
"text",
|
|
5376
|
+
"muted",
|
|
5377
|
+
"primary",
|
|
5378
|
+
"secondary",
|
|
5379
|
+
"accent",
|
|
5380
|
+
"current"
|
|
5381
|
+
];
|
|
5382
|
+
var accordionIconMotionValues = [
|
|
5383
|
+
"none",
|
|
5384
|
+
"rotate",
|
|
5385
|
+
"swap"
|
|
5386
|
+
];
|
|
5387
|
+
|
|
5279
5388
|
// ../blocks/src/system/runtime/nodes/spinner.tsx
|
|
5280
5389
|
import { jsx as jsx2, jsxs } from "react/jsx-runtime";
|
|
5281
5390
|
function resolveColorStyle(color) {
|
|
@@ -5349,13 +5458,44 @@ function SpinnerNode({
|
|
|
5349
5458
|
}
|
|
5350
5459
|
|
|
5351
5460
|
// ../frontend-state/dist/index.mjs
|
|
5352
|
-
|
|
5461
|
+
var IDLE_FEEDBACK = idleFeedback();
|
|
5462
|
+
function idleFeedback() {
|
|
5463
|
+
return { tag: "idle" };
|
|
5464
|
+
}
|
|
5465
|
+
function clearWorkflowFeedback(state) {
|
|
5466
|
+
return {
|
|
5467
|
+
...state,
|
|
5468
|
+
feedback: idleSubmissionFeedback()
|
|
5469
|
+
};
|
|
5470
|
+
}
|
|
5471
|
+
function reportWorkflowError(state, message) {
|
|
5472
|
+
return {
|
|
5473
|
+
...state,
|
|
5474
|
+
feedback: errorSubmissionFeedback(message)
|
|
5475
|
+
};
|
|
5476
|
+
}
|
|
5477
|
+
function reportWorkflowSuccess(state, message) {
|
|
5478
|
+
return {
|
|
5479
|
+
...state,
|
|
5480
|
+
feedback: successSubmissionFeedback(message)
|
|
5481
|
+
};
|
|
5482
|
+
}
|
|
5483
|
+
function idleSubmissionFeedback() {
|
|
5484
|
+
return { tag: "idle" };
|
|
5485
|
+
}
|
|
5486
|
+
function errorSubmissionFeedback(message) {
|
|
5487
|
+
return { tag: "error", message };
|
|
5488
|
+
}
|
|
5489
|
+
function successSubmissionFeedback(message) {
|
|
5490
|
+
return { tag: "success", message };
|
|
5491
|
+
}
|
|
5492
|
+
function okWith2(data) {
|
|
5353
5493
|
return { ok: true, data };
|
|
5354
5494
|
}
|
|
5355
|
-
function
|
|
5495
|
+
function err2(error) {
|
|
5356
5496
|
return { ok: false, error };
|
|
5357
5497
|
}
|
|
5358
|
-
function
|
|
5498
|
+
function assertNever11(value, message) {
|
|
5359
5499
|
throw new Error(message ?? `Unexpected value: ${String(value)}`);
|
|
5360
5500
|
}
|
|
5361
5501
|
|
|
@@ -5510,7 +5650,7 @@ function deriveBookingFormViewState(input) {
|
|
|
5510
5650
|
resourceName: input.verificationState.resourceName
|
|
5511
5651
|
};
|
|
5512
5652
|
default:
|
|
5513
|
-
return
|
|
5653
|
+
return assertNever11(input.verificationState);
|
|
5514
5654
|
}
|
|
5515
5655
|
}
|
|
5516
5656
|
function resolveBookingSiteId(siteId, form) {
|
|
@@ -5680,7 +5820,7 @@ function getBookingServicePaymentSelectionMode(service) {
|
|
|
5680
5820
|
case "flexible_balance":
|
|
5681
5821
|
return "implicit_flexible_balance";
|
|
5682
5822
|
default:
|
|
5683
|
-
return
|
|
5823
|
+
return assertNever11(onlyKind);
|
|
5684
5824
|
}
|
|
5685
5825
|
}
|
|
5686
5826
|
if (allowedKinds.length === 2 && allowedKinds.includes("upfront") && (allowedKinds.includes("deferred_manual") || allowedKinds.includes("instalment_plan") || allowedKinds.includes("flexible_balance"))) {
|
|
@@ -5882,7 +6022,7 @@ function formatBookingSubmissionPreparationError(error) {
|
|
|
5882
6022
|
case "service-missing-duration":
|
|
5883
6023
|
return `Service "${error.serviceTitle}" is missing duration. Please update the service in the dashboard to include a duration (e.g., 30 minutes).`;
|
|
5884
6024
|
default:
|
|
5885
|
-
return
|
|
6025
|
+
return assertNever11(error);
|
|
5886
6026
|
}
|
|
5887
6027
|
}
|
|
5888
6028
|
function getBookingSuccessMessage(successMessage) {
|
|
@@ -5900,107 +6040,241 @@ var logger = {
|
|
|
5900
6040
|
withFields: (_) => logger
|
|
5901
6041
|
};
|
|
5902
6042
|
|
|
5903
|
-
// ../theme-core/src/
|
|
6043
|
+
// ../theme-core/src/utils/tokenOrColor.ts
|
|
5904
6044
|
import { z as z6 } from "zod";
|
|
5905
|
-
var
|
|
6045
|
+
var tokenOrCssColorValueSchema = z6.string();
|
|
6046
|
+
|
|
6047
|
+
// ../theme-core/src/site-styles/headerCtaVariants.ts
|
|
6048
|
+
function hasButtonVariant(theme, variantId) {
|
|
6049
|
+
return theme.buttons?.variants.some((variant) => variant.enabled && variant.id === variantId) ?? false;
|
|
6050
|
+
}
|
|
6051
|
+
function resolveHeaderCtaVariant(theme, treatment) {
|
|
6052
|
+
switch (treatment) {
|
|
6053
|
+
case "default":
|
|
6054
|
+
return void 0;
|
|
6055
|
+
case "primary":
|
|
6056
|
+
return "primary";
|
|
6057
|
+
case "secondary":
|
|
6058
|
+
return hasButtonVariant(theme, "secondary") ? "secondary" : "primary";
|
|
6059
|
+
case "inverted":
|
|
6060
|
+
if (hasButtonVariant(theme, "header")) return "header";
|
|
6061
|
+
if (hasButtonVariant(theme, "secondary")) return "secondary";
|
|
6062
|
+
if (hasButtonVariant(theme, "outline")) return "outline";
|
|
6063
|
+
return "primary";
|
|
6064
|
+
case "outline":
|
|
6065
|
+
return hasButtonVariant(theme, "outline") ? "outline" : "secondary";
|
|
6066
|
+
case "ghost":
|
|
6067
|
+
return hasButtonVariant(theme, "ghost") ? "ghost" : "secondary";
|
|
6068
|
+
}
|
|
6069
|
+
}
|
|
6070
|
+
|
|
6071
|
+
// ../theme-core/src/palette/variants/types.ts
|
|
6072
|
+
import { z as z17 } from "zod";
|
|
6073
|
+
|
|
6074
|
+
// ../theme-core/src/schema.ts
|
|
6075
|
+
import { z as z16 } from "zod";
|
|
6076
|
+
|
|
6077
|
+
// ../theme-core/src/lib/media.ts
|
|
6078
|
+
import z7 from "zod";
|
|
6079
|
+
var hotspotSchema = z7.object({
|
|
6080
|
+
x: z7.number().min(0).max(1),
|
|
6081
|
+
y: z7.number().min(0).max(1),
|
|
6082
|
+
radius: z7.number().optional()
|
|
6083
|
+
});
|
|
6084
|
+
var rotationSchema = z7.union([z7.literal(0), z7.literal(90), z7.literal(180), z7.literal(270)]);
|
|
6085
|
+
var rectSchema = z7.tuple([z7.number(), z7.number(), z7.number(), z7.number()]);
|
|
6086
|
+
var aspectCropSchema = z7.object({
|
|
6087
|
+
aspect: z7.preprocess((value) => value == null ? void 0 : value, z7.string().optional()),
|
|
6088
|
+
rect: z7.preprocess((value) => value == null ? void 0 : value, rectSchema.optional()),
|
|
6089
|
+
hotspot: z7.preprocess((value) => value == null ? void 0 : value, hotspotSchema.optional()),
|
|
6090
|
+
rotation: z7.preprocess((value) => value == null ? void 0 : value, rotationSchema.optional())
|
|
6091
|
+
});
|
|
6092
|
+
var transformSchema = z7.object({
|
|
6093
|
+
aspectCrops: z7.preprocess((value) => {
|
|
6094
|
+
if (!value || typeof value !== "object" || Array.isArray(value)) {
|
|
6095
|
+
return void 0;
|
|
6096
|
+
}
|
|
6097
|
+
return value;
|
|
6098
|
+
}, z7.record(z7.string(), aspectCropSchema.catch({}))).optional(),
|
|
6099
|
+
rect: rectSchema.optional(),
|
|
6100
|
+
hotspot: hotspotSchema.optional(),
|
|
6101
|
+
rotation: rotationSchema.optional()
|
|
6102
|
+
});
|
|
6103
|
+
var mediaSchema = z7.object({
|
|
6104
|
+
type: z7.enum(["image", "video", "audio", "document", "spreadsheet", "archive"]),
|
|
6105
|
+
purpose: z7.string().optional(),
|
|
6106
|
+
placeholder: z7.boolean().default(true).optional(),
|
|
6107
|
+
assetId: z7.string().optional(),
|
|
6108
|
+
identifier: z7.string().optional(),
|
|
6109
|
+
src: z7.string().optional(),
|
|
6110
|
+
alt: z7.string().optional(),
|
|
6111
|
+
filename: z7.string().optional(),
|
|
6112
|
+
mimeType: z7.string().optional(),
|
|
6113
|
+
width: z7.number().optional(),
|
|
6114
|
+
height: z7.number().optional(),
|
|
6115
|
+
storageBucket: z7.string().optional(),
|
|
6116
|
+
storagePath: z7.string().optional(),
|
|
6117
|
+
transform: transformSchema.optional()
|
|
6118
|
+
});
|
|
6119
|
+
|
|
6120
|
+
// ../theme-core/src/cards/types.ts
|
|
6121
|
+
import { z as z8 } from "zod";
|
|
6122
|
+
var cardSpacingSchema = z8.enum(["none", "compact", "cozy", "medium", "comfortable", "spacious"]);
|
|
6123
|
+
var gradientDirectionSchema2 = z8.enum(["to-r", "to-l", "to-t", "to-b", "to-tr", "to-tl", "to-br", "to-bl"]);
|
|
6124
|
+
var cardBackgroundSchema = z8.discriminatedUnion("type", [
|
|
6125
|
+
z8.object({ type: z8.literal("solid"), colorToken: themeColorTokenSchema }),
|
|
6126
|
+
z8.object({
|
|
6127
|
+
type: z8.literal("gradient"),
|
|
6128
|
+
fromToken: themeColorTokenSchema,
|
|
6129
|
+
toToken: themeColorTokenSchema,
|
|
6130
|
+
direction: gradientDirectionSchema2
|
|
6131
|
+
}),
|
|
6132
|
+
z8.object({ type: z8.literal("transparent") })
|
|
6133
|
+
]);
|
|
6134
|
+
var cardBorderSchema = z8.object({
|
|
6135
|
+
widthClass: z8.string(),
|
|
6136
|
+
colorToken: themeColorTokenSchema
|
|
6137
|
+
});
|
|
6138
|
+
var cardVariantSchema = z8.object({
|
|
6139
|
+
id: z8.string(),
|
|
6140
|
+
name: z8.string().min(1).max(20),
|
|
6141
|
+
enabled: z8.boolean(),
|
|
6142
|
+
priority: z8.union([z8.literal(1), z8.literal(2), z8.literal(3)]),
|
|
6143
|
+
// Appearance (token-based)
|
|
6144
|
+
background: cardBackgroundSchema,
|
|
6145
|
+
spacing: cardSpacingSchema,
|
|
6146
|
+
// Optional overrides (uses theme defaults if not specified)
|
|
6147
|
+
shadow: z8.object({
|
|
6148
|
+
elevation: z8.enum(["none", "low", "medium", "high"]),
|
|
6149
|
+
softness: z8.enum(["crisp", "soft", "hard"]).nullable(),
|
|
6150
|
+
position: z8.enum(["bottom", "bottom-right"]).default("bottom")
|
|
6151
|
+
}).optional(),
|
|
6152
|
+
corners: z8.enum(["square", "soft", "rounded", "pill"]).optional(),
|
|
6153
|
+
// Border (optional)
|
|
6154
|
+
border: cardBorderSchema.optional()
|
|
6155
|
+
});
|
|
6156
|
+
var cardSystemSchema = z8.object({
|
|
6157
|
+
variants: z8.array(cardVariantSchema).min(1).max(3)
|
|
6158
|
+
});
|
|
6159
|
+
|
|
6160
|
+
// ../theme-core/src/inputs/types.ts
|
|
6161
|
+
import { z as z9 } from "zod";
|
|
6162
|
+
var inputSystemSchema = z9.object({
|
|
5906
6163
|
// Base styling (applied to all inputs)
|
|
5907
|
-
base:
|
|
5908
|
-
background:
|
|
5909
|
-
|
|
5910
|
-
type:
|
|
6164
|
+
base: z9.object({
|
|
6165
|
+
background: z9.union([
|
|
6166
|
+
z9.object({
|
|
6167
|
+
type: z9.literal("solid"),
|
|
5911
6168
|
colorToken: themeColorTokenSchema
|
|
5912
6169
|
}),
|
|
5913
|
-
|
|
5914
|
-
type:
|
|
6170
|
+
z9.object({
|
|
6171
|
+
type: z9.literal("transparent")
|
|
5915
6172
|
})
|
|
5916
6173
|
]),
|
|
5917
6174
|
textColorToken: themeColorTokenSchema,
|
|
5918
|
-
border:
|
|
5919
|
-
widthClass:
|
|
6175
|
+
border: z9.object({
|
|
6176
|
+
widthClass: z9.string(),
|
|
5920
6177
|
// e.g., 'border', 'border-2'
|
|
5921
6178
|
colorToken: themeColorTokenSchema,
|
|
5922
|
-
style:
|
|
6179
|
+
style: z9.enum(["all", "underline"]).optional()
|
|
5923
6180
|
}),
|
|
5924
|
-
corners:
|
|
6181
|
+
corners: z9.enum(["square", "soft", "rounded", "pill"]).nullable(),
|
|
5925
6182
|
// null = inherit from theme.corners
|
|
5926
|
-
shadow:
|
|
5927
|
-
elevation:
|
|
5928
|
-
softness:
|
|
6183
|
+
shadow: z9.object({
|
|
6184
|
+
elevation: z9.enum(["none", "low", "medium"]),
|
|
6185
|
+
softness: z9.enum(["soft", "crisp", "hard"]).nullable()
|
|
5929
6186
|
}).nullable(),
|
|
5930
|
-
spacing:
|
|
6187
|
+
spacing: z9.enum(["compact", "cozy", "medium", "comfortable"]),
|
|
5931
6188
|
// padding inside inputs
|
|
5932
|
-
fontSize:
|
|
6189
|
+
fontSize: z9.enum(["sm", "base", "lg"])
|
|
5933
6190
|
}),
|
|
5934
6191
|
// Label styling
|
|
5935
|
-
label:
|
|
6192
|
+
label: z9.object({
|
|
5936
6193
|
textColorToken: themeColorTokenSchema,
|
|
5937
|
-
fontWeight:
|
|
5938
|
-
fontSize:
|
|
5939
|
-
textTransform:
|
|
5940
|
-
letterSpacing:
|
|
5941
|
-
opacity:
|
|
6194
|
+
fontWeight: z9.enum(["regular", "medium", "semibold", "bold", "black"]),
|
|
6195
|
+
fontSize: z9.enum(["2xs", "xs", "sm", "base"]),
|
|
6196
|
+
textTransform: z9.enum(["none", "uppercase", "lowercase", "capitalize"]).optional(),
|
|
6197
|
+
letterSpacing: z9.enum(["normal", "wide", "wider", "widest"]).optional(),
|
|
6198
|
+
opacity: z9.number().min(0.2).max(1).optional()
|
|
5942
6199
|
}),
|
|
5943
6200
|
// Focus state
|
|
5944
|
-
focus:
|
|
6201
|
+
focus: z9.object({
|
|
5945
6202
|
ringColorToken: themeColorTokenSchema,
|
|
5946
|
-
ringWidth:
|
|
6203
|
+
ringWidth: z9.enum(["0", "1", "2", "3"]),
|
|
5947
6204
|
borderColorToken: themeColorTokenSchema.optional()
|
|
5948
6205
|
// Change border color on focus
|
|
5949
6206
|
}),
|
|
5950
6207
|
// Error state (for validation feedback)
|
|
5951
|
-
error:
|
|
6208
|
+
error: z9.object({
|
|
5952
6209
|
borderColorToken: themeColorTokenSchema,
|
|
5953
6210
|
textColorToken: themeColorTokenSchema
|
|
5954
6211
|
}),
|
|
5955
6212
|
// Disabled state
|
|
5956
|
-
disabled:
|
|
6213
|
+
disabled: z9.object({
|
|
5957
6214
|
backgroundColorToken: themeColorTokenSchema,
|
|
5958
6215
|
textColorToken: themeColorTokenSchema,
|
|
5959
|
-
opacity:
|
|
6216
|
+
opacity: z9.number().min(0.3).max(0.7)
|
|
5960
6217
|
})
|
|
5961
6218
|
});
|
|
5962
6219
|
|
|
6220
|
+
// ../theme-core/src/gradients/types.ts
|
|
6221
|
+
import { z as z10 } from "zod";
|
|
6222
|
+
var gradientStopSchema = z10.object({
|
|
6223
|
+
color: themeColorTokenSchema,
|
|
6224
|
+
position: z10.number().min(0).max(100)
|
|
6225
|
+
// Percentage 0-100
|
|
6226
|
+
});
|
|
6227
|
+
var gradientConfigSchema = z10.object({
|
|
6228
|
+
type: z10.enum(["linear", "radial"]),
|
|
6229
|
+
angle: z10.number().min(0).max(360).optional(),
|
|
6230
|
+
// For linear gradients (degrees)
|
|
6231
|
+
position: z10.string().optional(),
|
|
6232
|
+
// For radial gradients ('center', 'top left', etc.)
|
|
6233
|
+
stops: z10.array(gradientStopSchema).min(2)
|
|
6234
|
+
});
|
|
6235
|
+
|
|
5963
6236
|
// ../theme-core/src/navigation/types.ts
|
|
5964
|
-
import { z as
|
|
6237
|
+
import { z as z12 } from "zod";
|
|
5965
6238
|
|
|
5966
6239
|
// ../theme-core/src/interactive/baseSchema.ts
|
|
5967
|
-
import { z as
|
|
5968
|
-
var interactiveTypographySchema =
|
|
6240
|
+
import { z as z11 } from "zod";
|
|
6241
|
+
var interactiveTypographySchema = z11.object({
|
|
5969
6242
|
/** Font family source */
|
|
5970
|
-
typography:
|
|
6243
|
+
typography: z11.enum(["body", "heading"]).default("body"),
|
|
5971
6244
|
/** Font weight */
|
|
5972
|
-
fontWeight:
|
|
6245
|
+
fontWeight: z11.enum(["regular", "medium", "semibold", "bold"]).default("medium"),
|
|
5973
6246
|
/** Text transform */
|
|
5974
|
-
textTransform:
|
|
6247
|
+
textTransform: z11.enum(["none", "uppercase", "capitalize"]).default("none"),
|
|
5975
6248
|
/** Italic style */
|
|
5976
|
-
italic:
|
|
6249
|
+
italic: z11.boolean().default(false)
|
|
5977
6250
|
});
|
|
5978
|
-
var effectApplicationSchema2 =
|
|
6251
|
+
var effectApplicationSchema2 = z11.object({
|
|
5979
6252
|
/** Effect preset ID */
|
|
5980
|
-
effectId:
|
|
6253
|
+
effectId: z11.string(),
|
|
5981
6254
|
/** User-provided customization options */
|
|
5982
|
-
options:
|
|
6255
|
+
options: z11.record(z11.string(), z11.any()).optional()
|
|
5983
6256
|
});
|
|
5984
|
-
var effectCompositionSchema =
|
|
6257
|
+
var effectCompositionSchema = z11.object({
|
|
5985
6258
|
/** Effects always applied */
|
|
5986
|
-
base:
|
|
6259
|
+
base: z11.array(effectApplicationSchema2).optional(),
|
|
5987
6260
|
/** Effects applied on hover */
|
|
5988
|
-
hover:
|
|
6261
|
+
hover: z11.array(effectApplicationSchema2).optional(),
|
|
5989
6262
|
/** Effects applied on active/pressed */
|
|
5990
|
-
active:
|
|
6263
|
+
active: z11.array(effectApplicationSchema2).optional(),
|
|
5991
6264
|
/** Effects applied on focus */
|
|
5992
|
-
focus:
|
|
6265
|
+
focus: z11.array(effectApplicationSchema2).optional()
|
|
5993
6266
|
});
|
|
5994
6267
|
|
|
5995
6268
|
// ../theme-core/src/navigation/types.ts
|
|
5996
|
-
var navLinkPaddingSchema =
|
|
5997
|
-
var navLinkPaddingXSchema =
|
|
5998
|
-
var navLinkBorderRadiusSchema =
|
|
5999
|
-
var navLinkTextSizeSchema =
|
|
6000
|
-
var navLinkLetterSpacingSchema =
|
|
6001
|
-
var
|
|
6269
|
+
var navLinkPaddingSchema = z12.enum(["none", "compact", "default"]);
|
|
6270
|
+
var navLinkPaddingXSchema = z12.enum(["none", "tight", "compact", "default", "relaxed", "spacious"]);
|
|
6271
|
+
var navLinkBorderRadiusSchema = z12.enum(["none", "sm", "md", "full"]);
|
|
6272
|
+
var navLinkTextSizeSchema = z12.enum(["xs", "sm", "base", "lg"]);
|
|
6273
|
+
var navLinkLetterSpacingSchema = z12.enum(["normal", "wide", "wider", "widest"]);
|
|
6274
|
+
var navLinkContrastTreatmentSchema = z12.enum(["none", "soft-glow"]);
|
|
6275
|
+
var navLinkStyleSchema = z12.object({
|
|
6002
6276
|
/** Display name for the style */
|
|
6003
|
-
name:
|
|
6277
|
+
name: z12.string().min(1).max(30).optional(),
|
|
6004
6278
|
/** Typography settings (inherited from interactive base) */
|
|
6005
6279
|
...interactiveTypographySchema.shape,
|
|
6006
6280
|
/** Text color token */
|
|
@@ -6009,6 +6283,8 @@ var navLinkStyleSchema = z8.object({
|
|
|
6009
6283
|
textSize: navLinkTextSizeSchema.optional(),
|
|
6010
6284
|
/** Optional letter spacing override */
|
|
6011
6285
|
letterSpacing: navLinkLetterSpacingSchema.optional(),
|
|
6286
|
+
/** Optional text-only contrast treatment for transparent/overlay navigation */
|
|
6287
|
+
contrastTreatment: navLinkContrastTreatmentSchema.optional(),
|
|
6012
6288
|
/** Hover/active color token (for color-change effects) */
|
|
6013
6289
|
hoverColorToken: themeColorTokenSchema.nullable().optional(),
|
|
6014
6290
|
/** Padding preset */
|
|
@@ -6022,7 +6298,7 @@ var navLinkStyleSchema = z8.object({
|
|
|
6022
6298
|
});
|
|
6023
6299
|
|
|
6024
6300
|
// ../theme-core/src/customCss/validation.ts
|
|
6025
|
-
import { z as
|
|
6301
|
+
import { z as z13 } from "zod";
|
|
6026
6302
|
var FORBIDDEN_SELECTORS = [":root", "html", "body"];
|
|
6027
6303
|
var UNIVERSAL_SELECTOR = "*";
|
|
6028
6304
|
var REMOTE_URL_PATTERN = /url\s*\(\s*['"]?(https?:|\/\/)/i;
|
|
@@ -6044,158 +6320,3221 @@ function isForbiddenSelectorPart(part) {
|
|
|
6044
6320
|
if (normalized.startsWith(forbidden + "[")) return true;
|
|
6045
6321
|
if (normalized.startsWith(forbidden + ":") && !normalized.startsWith(forbidden + "::")) return true;
|
|
6046
6322
|
}
|
|
6047
|
-
return false;
|
|
6323
|
+
return false;
|
|
6324
|
+
}
|
|
6325
|
+
function hasScopeEscapingSiblingCombinator(selector) {
|
|
6326
|
+
const normalized = selector.trim();
|
|
6327
|
+
return /&\s*[+~]/.test(normalized);
|
|
6328
|
+
}
|
|
6329
|
+
function containsForbiddenSelector(selector) {
|
|
6330
|
+
const normalized = selector.toLowerCase().trim();
|
|
6331
|
+
if (!normalized) return true;
|
|
6332
|
+
if (hasScopeEscapingSiblingCombinator(selector)) {
|
|
6333
|
+
return true;
|
|
6334
|
+
}
|
|
6335
|
+
const parts = normalized.split(",");
|
|
6336
|
+
for (const part of parts) {
|
|
6337
|
+
if (isForbiddenSelectorPart(part)) {
|
|
6338
|
+
return true;
|
|
6339
|
+
}
|
|
6340
|
+
}
|
|
6341
|
+
return false;
|
|
6342
|
+
}
|
|
6343
|
+
var selectorSchema = z13.string().min(1, "Selector cannot be empty").max(200, "Selector too long (max 200 characters)").refine(
|
|
6344
|
+
(s) => !containsForbiddenSelector(s),
|
|
6345
|
+
{ message: "Global selectors (:root, html, body, *) are not allowed" }
|
|
6346
|
+
);
|
|
6347
|
+
function containsRemoteUrl(value) {
|
|
6348
|
+
return REMOTE_URL_PATTERN.test(value);
|
|
6349
|
+
}
|
|
6350
|
+
function containsJavascriptUrl(value) {
|
|
6351
|
+
return JAVASCRIPT_URL_PATTERN.test(value);
|
|
6352
|
+
}
|
|
6353
|
+
var declarationValueSchema = z13.string().max(500, "Declaration value too long (max 500 characters)").refine(
|
|
6354
|
+
(v) => !containsRemoteUrl(v),
|
|
6355
|
+
{ message: "Remote url() references are not allowed. Use local paths, data URIs, or fragment IDs." }
|
|
6356
|
+
).refine(
|
|
6357
|
+
(v) => !containsJavascriptUrl(v),
|
|
6358
|
+
{ message: "javascript: URLs are not allowed" }
|
|
6359
|
+
);
|
|
6360
|
+
var declarationsSchema = z13.record(
|
|
6361
|
+
z13.string().min(1).max(100),
|
|
6362
|
+
// property name
|
|
6363
|
+
declarationValueSchema
|
|
6364
|
+
// property value
|
|
6365
|
+
);
|
|
6366
|
+
var customCssRuleSchema = z13.object({
|
|
6367
|
+
id: z13.string().min(1, "Rule ID is required").max(50, "Rule ID too long"),
|
|
6368
|
+
selector: selectorSchema,
|
|
6369
|
+
declarations: declarationsSchema
|
|
6370
|
+
});
|
|
6371
|
+
var blockCustomCssRuleSchema = customCssRuleSchema.extend({
|
|
6372
|
+
blockKind: z13.string().min(1, "Block kind is required").max(50, "Block kind too long")
|
|
6373
|
+
});
|
|
6374
|
+
var customCssRulesSchema = z13.array(customCssRuleSchema).optional();
|
|
6375
|
+
var blockCustomCssRulesSchema = z13.array(blockCustomCssRuleSchema).optional();
|
|
6376
|
+
|
|
6377
|
+
// ../theme-core/src/customCss/atRuleValidation.ts
|
|
6378
|
+
import { z as z14 } from "zod";
|
|
6379
|
+
var KEYFRAME_OFFSET_PATTERN = /^(from|to|\d{1,3}%)$/i;
|
|
6380
|
+
var ANIMATION_NAME_PATTERN = /^[a-zA-Z_-][a-zA-Z0-9_-]*$/;
|
|
6381
|
+
var BLOCKED_AT_RULES = ["@import", "@charset"];
|
|
6382
|
+
var BLOCKED_AT_RULE_PATTERN = /@(?:import|charset)\b/i;
|
|
6383
|
+
var ruleIdSchema = z14.string().min(1, "Rule ID is required").max(50, "Rule ID too long");
|
|
6384
|
+
var nestedRuleSchema = z14.object({
|
|
6385
|
+
selector: selectorSchema,
|
|
6386
|
+
declarations: declarationsSchema
|
|
6387
|
+
});
|
|
6388
|
+
function isValidKeyframeOffset(offset) {
|
|
6389
|
+
const trimmed = offset.trim().toLowerCase();
|
|
6390
|
+
if (trimmed === "from" || trimmed === "to") return true;
|
|
6391
|
+
const match = trimmed.match(/^(\d{1,3})%$/);
|
|
6392
|
+
if (!match || match[1] === void 0) return false;
|
|
6393
|
+
const value = parseInt(match[1], 10);
|
|
6394
|
+
return value >= 0 && value <= 100;
|
|
6395
|
+
}
|
|
6396
|
+
var keyframeOffsetSchema = z14.string().transform((offset) => offset.trim()).refine(
|
|
6397
|
+
(offset) => KEYFRAME_OFFSET_PATTERN.test(offset),
|
|
6398
|
+
{ message: 'Invalid keyframe offset. Use percentages (0%, 50%, 100%) or "from"/"to"' }
|
|
6399
|
+
).refine(
|
|
6400
|
+
isValidKeyframeOffset,
|
|
6401
|
+
{ message: "Keyframe offset must be between 0% and 100%" }
|
|
6402
|
+
);
|
|
6403
|
+
var animationNameSchema = z14.string().min(1, "Animation name is required").max(50, "Animation name too long").refine(
|
|
6404
|
+
(name) => ANIMATION_NAME_PATTERN.test(name),
|
|
6405
|
+
{ message: "Invalid animation name. Use letters, numbers, dashes, underscores (start with letter, dash, or underscore)" }
|
|
6406
|
+
);
|
|
6407
|
+
var keyframeSchema = z14.object({
|
|
6408
|
+
offset: keyframeOffsetSchema,
|
|
6409
|
+
declarations: declarationsSchema
|
|
6410
|
+
});
|
|
6411
|
+
var keyframesAtRuleSchema = z14.object({
|
|
6412
|
+
id: ruleIdSchema,
|
|
6413
|
+
type: z14.literal("keyframes"),
|
|
6414
|
+
name: animationNameSchema,
|
|
6415
|
+
frames: z14.array(keyframeSchema).min(1, "At least one keyframe is required")
|
|
6416
|
+
});
|
|
6417
|
+
var fontFaceDeclarationsSchema = z14.record(z14.string().min(1).max(100), declarationValueSchema).refine(
|
|
6418
|
+
(decls) => "fontFamily" in decls || "font-family" in decls,
|
|
6419
|
+
{ message: "font-family is required in @font-face" }
|
|
6420
|
+
);
|
|
6421
|
+
var fontFaceAtRuleSchema = z14.object({
|
|
6422
|
+
id: ruleIdSchema,
|
|
6423
|
+
type: z14.literal("font-face"),
|
|
6424
|
+
declarations: fontFaceDeclarationsSchema
|
|
6425
|
+
});
|
|
6426
|
+
var mediaQuerySchema = z14.string().min(1, "Media query is required").max(200, "Media query too long");
|
|
6427
|
+
var mediaAtRuleSchema = z14.object({
|
|
6428
|
+
id: ruleIdSchema,
|
|
6429
|
+
type: z14.literal("media"),
|
|
6430
|
+
query: mediaQuerySchema,
|
|
6431
|
+
rules: z14.array(nestedRuleSchema).min(1, "At least one rule is required")
|
|
6432
|
+
});
|
|
6433
|
+
var supportsConditionSchema = z14.string().min(1, "Supports condition is required").max(200, "Supports condition too long");
|
|
6434
|
+
var supportsAtRuleSchema = z14.object({
|
|
6435
|
+
id: ruleIdSchema,
|
|
6436
|
+
type: z14.literal("supports"),
|
|
6437
|
+
condition: supportsConditionSchema,
|
|
6438
|
+
rules: z14.array(nestedRuleSchema).min(1, "At least one rule is required")
|
|
6439
|
+
});
|
|
6440
|
+
function containsBlockedAtRule(css) {
|
|
6441
|
+
return BLOCKED_AT_RULE_PATTERN.test(css);
|
|
6442
|
+
}
|
|
6443
|
+
var rawCssSchema = z14.string().min(1, "CSS is required").max(5e3, "Raw CSS too long (max 5000 characters)").refine(
|
|
6444
|
+
(css) => css.trim().startsWith("@"),
|
|
6445
|
+
{ message: "Raw at-rule must start with @" }
|
|
6446
|
+
).refine(
|
|
6447
|
+
(css) => !containsBlockedAtRule(css),
|
|
6448
|
+
{ message: `Blocked at-rules: ${BLOCKED_AT_RULES.join(", ")}. Use typed at-rules or local assets instead.` }
|
|
6449
|
+
);
|
|
6450
|
+
var rawAtRuleSchema = z14.object({
|
|
6451
|
+
id: ruleIdSchema,
|
|
6452
|
+
type: z14.literal("raw"),
|
|
6453
|
+
css: rawCssSchema
|
|
6454
|
+
});
|
|
6455
|
+
var customCssAtRuleSchema = z14.discriminatedUnion("type", [
|
|
6456
|
+
keyframesAtRuleSchema,
|
|
6457
|
+
fontFaceAtRuleSchema,
|
|
6458
|
+
mediaAtRuleSchema,
|
|
6459
|
+
supportsAtRuleSchema,
|
|
6460
|
+
rawAtRuleSchema
|
|
6461
|
+
]);
|
|
6462
|
+
var customCssAtRulesSchema = z14.array(customCssAtRuleSchema).optional();
|
|
6463
|
+
|
|
6464
|
+
// ../theme-core/src/shared/componentStyles.ts
|
|
6465
|
+
import { z as z15 } from "zod";
|
|
6466
|
+
var componentBorderSchema = z15.object({
|
|
6467
|
+
width: z15.enum(["none", "hairline", "thin", "medium", "thick"]).default("none"),
|
|
6468
|
+
style: z15.enum(["solid", "dashed"]).default("solid"),
|
|
6469
|
+
colorToken: themeColorTokenSchema.optional()
|
|
6470
|
+
// defaults to "border" if not set
|
|
6471
|
+
});
|
|
6472
|
+
var componentShadowSchema = z15.object({
|
|
6473
|
+
elevation: z15.enum(["none", "sm", "md", "lg", "xl", "2xl"]).default("sm")
|
|
6474
|
+
});
|
|
6475
|
+
|
|
6476
|
+
// ../theme-core/src/schema.ts
|
|
6477
|
+
var axesSchema = z16.object({
|
|
6478
|
+
tone: z16.enum(["minimal", "classic", "bold"]),
|
|
6479
|
+
energy: z16.enum(["calm", "vibrant"]),
|
|
6480
|
+
density: z16.enum(["airy", "regular", "compact"]),
|
|
6481
|
+
mediaBias: z16.enum(["text", "media", "mixed"]),
|
|
6482
|
+
conversionBias: z16.enum(["low", "med", "high"]),
|
|
6483
|
+
motion: z16.enum(["subtle", "standard", "expressive"])
|
|
6484
|
+
});
|
|
6485
|
+
var colourHexString = z16.string().regex(/^#([0-9A-Fa-f]{3}){1,2}$/);
|
|
6486
|
+
var paletteColorSchema = z16.object({
|
|
6487
|
+
name: z16.string().min(1),
|
|
6488
|
+
hex: colourHexString
|
|
6489
|
+
});
|
|
6490
|
+
var paletteMetaSchema = z16.object({
|
|
6491
|
+
mode: z16.enum(["light", "dark"])
|
|
6492
|
+
});
|
|
6493
|
+
var paletteSchema = z16.object({
|
|
6494
|
+
colors: z16.array(paletteColorSchema),
|
|
6495
|
+
meta: paletteMetaSchema
|
|
6496
|
+
});
|
|
6497
|
+
var typographyStyleSchema = z16.object({
|
|
6498
|
+
family: z16.string().min(1),
|
|
6499
|
+
weight: z16.enum(["light", "regular", "medium", "semibold", "bold"]),
|
|
6500
|
+
letterSpacing: z16.enum(["tight", "normal", "loose"]),
|
|
6501
|
+
lineHeight: z16.enum(["normal", "relaxed", "loose"])
|
|
6502
|
+
});
|
|
6503
|
+
var bodyTypographyStyleSchema = typographyStyleSchema.extend({
|
|
6504
|
+
size: z16.enum(["md", "lg", "xl"])
|
|
6505
|
+
});
|
|
6506
|
+
var headingSizeSchema = z16.enum(["xs", "sm", "md", "lg", "xl", "2xl"]);
|
|
6507
|
+
var headingTypographyOverridesSchema = z16.object({
|
|
6508
|
+
weight: z16.enum(["light", "regular", "medium", "semibold", "bold"]).nullable().optional(),
|
|
6509
|
+
letterSpacing: z16.enum(["tight", "normal", "loose"]).nullable().optional(),
|
|
6510
|
+
size: headingSizeSchema.nullable().optional(),
|
|
6511
|
+
lineHeight: z16.enum(["normal", "relaxed", "loose"]).nullable().optional(),
|
|
6512
|
+
italic: z16.boolean().nullable().optional(),
|
|
6513
|
+
colorToken: themeColorTokenSchema.nullable().optional()
|
|
6514
|
+
});
|
|
6515
|
+
var headingTypographyStyleSchema = typographyStyleSchema.extend({
|
|
6516
|
+
case: z16.enum(["uppercase", "normal", "smallCaps"]).nullable(),
|
|
6517
|
+
italic: z16.boolean().nullable(),
|
|
6518
|
+
colorToken: themeColorTokenSchema.nullable().optional()
|
|
6519
|
+
});
|
|
6520
|
+
var proseLinkUnderlineStyleSchema = z16.enum(["solid", "dotted", "dashed"]);
|
|
6521
|
+
var proseLinkUnderlineThicknessSchema = z16.enum([
|
|
6522
|
+
"auto",
|
|
6523
|
+
"fromFont",
|
|
6524
|
+
"thin",
|
|
6525
|
+
"medium",
|
|
6526
|
+
"thick"
|
|
6527
|
+
]);
|
|
6528
|
+
var proseLinkUnderlineOffsetSchema = z16.enum([
|
|
6529
|
+
"auto",
|
|
6530
|
+
"tight",
|
|
6531
|
+
"normal",
|
|
6532
|
+
"loose"
|
|
6533
|
+
]);
|
|
6534
|
+
var proseLinkStyleSchema = z16.object({
|
|
6535
|
+
colorToken: themeColorTokenSchema.optional(),
|
|
6536
|
+
hoverColorToken: themeColorTokenSchema.optional(),
|
|
6537
|
+
underline: z16.boolean().optional(),
|
|
6538
|
+
decorationColorToken: themeColorTokenSchema.optional(),
|
|
6539
|
+
hoverDecorationColorToken: themeColorTokenSchema.optional(),
|
|
6540
|
+
underlineStyle: proseLinkUnderlineStyleSchema.optional(),
|
|
6541
|
+
underlineThickness: proseLinkUnderlineThicknessSchema.optional(),
|
|
6542
|
+
underlineOffset: proseLinkUnderlineOffsetSchema.optional()
|
|
6543
|
+
});
|
|
6544
|
+
var semanticSpacingSchema = z16.enum([
|
|
6545
|
+
"none",
|
|
6546
|
+
"compact",
|
|
6547
|
+
"cozy",
|
|
6548
|
+
"medium",
|
|
6549
|
+
"comfortable",
|
|
6550
|
+
"spacious"
|
|
6551
|
+
]);
|
|
6552
|
+
var boxRoundedSchema = z16.enum(["none", "sm", "md", "lg", "xl", "2xl", "full"]);
|
|
6553
|
+
var boxBackgroundOverlaySchema = z16.object({
|
|
6554
|
+
type: z16.enum(["none", "color", "gradient"]).nullable().optional(),
|
|
6555
|
+
color: tokenOrCssColorValueSchema.nullable().optional(),
|
|
6556
|
+
gradient: z16.string().nullable().optional(),
|
|
6557
|
+
opacity: z16.number().min(0).max(1).nullable().optional()
|
|
6558
|
+
});
|
|
6559
|
+
var boxBackgroundSchema = z16.object({
|
|
6560
|
+
type: z16.enum(["color", "gradient", "image"]).optional(),
|
|
6561
|
+
color: tokenOrCssColorValueSchema.nullable().optional(),
|
|
6562
|
+
gradient: z16.string().nullable().optional(),
|
|
6563
|
+
image: mediaSchema.nullable().optional(),
|
|
6564
|
+
objectFit: z16.enum(["fill", "fit", "original", "custom"]).nullable().optional(),
|
|
6565
|
+
scale: z16.string().nullable().optional(),
|
|
6566
|
+
position: z16.string().nullable().optional(),
|
|
6567
|
+
opacity: z16.number().min(0).max(1).nullable().optional(),
|
|
6568
|
+
motion: z16.enum(["static", "fixed-frame"]).nullable().optional(),
|
|
6569
|
+
overlay: boxBackgroundOverlaySchema.nullable().optional(),
|
|
6570
|
+
textColor: tokenOrCssColorValueSchema.nullable().optional(),
|
|
6571
|
+
headingColor: tokenOrCssColorValueSchema.nullable().optional()
|
|
6572
|
+
});
|
|
6573
|
+
var noHeadingDecorationSchema = z16.object({
|
|
6574
|
+
family: z16.literal("none"),
|
|
6575
|
+
placement: z16.literal("none")
|
|
6576
|
+
});
|
|
6577
|
+
var visibleHeadingDecorationSchema = z16.object({
|
|
6578
|
+
family: z16.enum(visibleHeadingDecorationFamilyValues),
|
|
6579
|
+
placement: z16.enum(visibleHeadingDecorationPlacementValues),
|
|
6580
|
+
colorToken: z16.enum(headingDecorationColorTokenValues).optional()
|
|
6581
|
+
});
|
|
6582
|
+
var headingDecorationSchema = z16.union([
|
|
6583
|
+
noHeadingDecorationSchema,
|
|
6584
|
+
visibleHeadingDecorationSchema
|
|
6585
|
+
]);
|
|
6586
|
+
var accordionIconTreatmentSchema = z16.object({
|
|
6587
|
+
iconSet: z16.enum(accordionIconSetValues),
|
|
6588
|
+
colorToken: z16.enum(accordionIconColorTokenValues),
|
|
6589
|
+
openColorToken: z16.enum(accordionIconColorTokenValues).optional(),
|
|
6590
|
+
motion: z16.enum(accordionIconMotionValues)
|
|
6591
|
+
});
|
|
6592
|
+
var sectionStylesOverrideSchema = z16.object({
|
|
6593
|
+
background: boxBackgroundSchema.nullable().optional(),
|
|
6594
|
+
spacing: semanticSpacingSchema.nullable().optional(),
|
|
6595
|
+
minHeight: z16.enum(["none", "banner", "hero", "immersive"]).nullable().optional(),
|
|
6596
|
+
tileTreatment: z16.enum(tileTreatmentValues).nullable().optional(),
|
|
6597
|
+
eventListTreatment: z16.enum(eventListTreatmentValues).nullable().optional(),
|
|
6598
|
+
eyebrowTreatment: z16.enum(eyebrowTreatmentValues).nullable().optional(),
|
|
6599
|
+
headingDecoration: headingDecorationSchema.nullable().optional(),
|
|
6600
|
+
// Author-level override consumed by later block/editor rendering phases.
|
|
6601
|
+
// Keeping it in section styles lets existing block save APIs persist it.
|
|
6602
|
+
headingDecorationOverride: z16.enum(headingDecorationOverrideValues).nullable().optional(),
|
|
6603
|
+
accordionIconTreatment: accordionIconTreatmentSchema.nullable().optional()
|
|
6604
|
+
});
|
|
6605
|
+
var containerStylesOverrideSchema = z16.object({
|
|
6606
|
+
background: boxBackgroundSchema.nullable().optional(),
|
|
6607
|
+
spacing: semanticSpacingSchema.nullable().optional(),
|
|
6608
|
+
raised: z16.boolean().nullable().optional(),
|
|
6609
|
+
rounded: boxRoundedSchema.nullable().optional(),
|
|
6610
|
+
fullWidth: z16.boolean().nullable().optional()
|
|
6611
|
+
});
|
|
6612
|
+
var cardBorderOverrideSchema = z16.object({
|
|
6613
|
+
enabled: z16.boolean().nullable().optional(),
|
|
6614
|
+
width: z16.enum(["none", "1", "2", "3"]).nullable().optional(),
|
|
6615
|
+
colorToken: themeColorTokenSchema.nullable().optional()
|
|
6616
|
+
});
|
|
6617
|
+
var cardStylesOverrideSchema = z16.object({
|
|
6618
|
+
background: boxBackgroundSchema.nullable().optional(),
|
|
6619
|
+
border: cardBorderOverrideSchema.nullable().optional(),
|
|
6620
|
+
spacing: semanticSpacingSchema.nullable().optional(),
|
|
6621
|
+
raised: z16.boolean().nullable().optional(),
|
|
6622
|
+
rounded: boxRoundedSchema.nullable().optional(),
|
|
6623
|
+
treatment: z16.enum(["accent-quote"]).nullable().optional()
|
|
6624
|
+
});
|
|
6625
|
+
var blockStyleOverridesSchema = z16.object({
|
|
6626
|
+
sectionStyles: sectionStylesOverrideSchema.nullable().optional(),
|
|
6627
|
+
containerStyles: containerStylesOverrideSchema.nullable().optional(),
|
|
6628
|
+
cardStyles: cardStylesOverrideSchema.nullable().optional()
|
|
6629
|
+
});
|
|
6630
|
+
var blockThemeOverrideSchema = z16.object({
|
|
6631
|
+
typography: z16.object({
|
|
6632
|
+
proseLinkStyle: proseLinkStyleSchema.optional()
|
|
6633
|
+
}).optional(),
|
|
6634
|
+
styles: blockStyleOverridesSchema.optional()
|
|
6635
|
+
});
|
|
6636
|
+
var typographyScaleSchema = z16.enum([
|
|
6637
|
+
// New intuitive names
|
|
6638
|
+
"compact",
|
|
6639
|
+
// ratio 1.2 (was minorThird)
|
|
6640
|
+
"balanced",
|
|
6641
|
+
// ratio 1.25 (was majorThird)
|
|
6642
|
+
"spacious",
|
|
6643
|
+
// ratio 1.333 (was perfectFourth)
|
|
6644
|
+
// Legacy names (backward compatibility)
|
|
6645
|
+
"minorThird",
|
|
6646
|
+
"majorThird",
|
|
6647
|
+
"perfectFourth"
|
|
6648
|
+
]);
|
|
6649
|
+
var typographySchema = z16.object({
|
|
6650
|
+
body: bodyTypographyStyleSchema,
|
|
6651
|
+
headings: z16.object({
|
|
6652
|
+
default: headingTypographyStyleSchema,
|
|
6653
|
+
h1: headingTypographyOverridesSchema,
|
|
6654
|
+
h2: headingTypographyOverridesSchema,
|
|
6655
|
+
h3: headingTypographyOverridesSchema,
|
|
6656
|
+
// Allow per-level overrides for additional heading levels
|
|
6657
|
+
h4: headingTypographyOverridesSchema.optional(),
|
|
6658
|
+
h5: headingTypographyOverridesSchema.optional(),
|
|
6659
|
+
h6: headingTypographyOverridesSchema.optional()
|
|
6660
|
+
}),
|
|
6661
|
+
scale: typographyScaleSchema,
|
|
6662
|
+
proseLinkStyle: proseLinkStyleSchema.optional()
|
|
6663
|
+
});
|
|
6664
|
+
var spaceSchema = z16.enum(["comfortable", "standard", "dense"]);
|
|
6665
|
+
var corners = z16.enum(["square", "soft", "rounded", "pill"]);
|
|
6666
|
+
var shadow = z16.object({
|
|
6667
|
+
elevation: z16.enum(["none", "low", "medium", "high"]),
|
|
6668
|
+
softness: z16.enum(["crisp", "soft", "hard"]).nullable(),
|
|
6669
|
+
position: z16.enum(["bottom", "bottom-right"]).default("bottom")
|
|
6670
|
+
});
|
|
6671
|
+
var border = z16.object({
|
|
6672
|
+
width: z16.enum(["none", "hairline", "thin", "thick"]),
|
|
6673
|
+
style: z16.enum(["solid", "dashed"])
|
|
6674
|
+
});
|
|
6675
|
+
var motion = z16.object({
|
|
6676
|
+
level: z16.enum(["off", "low", "medium", "high"]),
|
|
6677
|
+
easing: z16.enum(["standard", "snappy", "gentle"]).nullable()
|
|
6678
|
+
});
|
|
6679
|
+
var buttonStyle = z16.object({
|
|
6680
|
+
shape: corners
|
|
6681
|
+
// Used for --radius-control CSS variable
|
|
6682
|
+
});
|
|
6683
|
+
var cardStyle = z16.object({
|
|
6684
|
+
elevation: z16.enum(["none", "low", "medium", "high"]),
|
|
6685
|
+
border: z16.enum(["none", "subtle", "defined"]),
|
|
6686
|
+
shape: corners,
|
|
6687
|
+
headerStyle: z16.enum(["plain", "accentBar", "subtleBg"]).nullable(),
|
|
6688
|
+
mediaTreatment: z16.enum(["square", "rounded", "bleed"]).nullable()
|
|
6689
|
+
});
|
|
6690
|
+
var inputStyle = z16.object({
|
|
6691
|
+
shape: corners,
|
|
6692
|
+
border: z16.enum(["subtle", "defined", "underline"]),
|
|
6693
|
+
focus: z16.enum(["glow", "ring", "underline"]),
|
|
6694
|
+
label: z16.enum(["inside", "above"])
|
|
6695
|
+
});
|
|
6696
|
+
var headerVariant = z16.enum(["classic", "centered", "transparent", "floating"]);
|
|
6697
|
+
var headerPositioning = z16.enum(["static", "sticky", "fixed"]);
|
|
6698
|
+
var headerNavStyle = z16.enum([
|
|
6699
|
+
"minimal",
|
|
6700
|
+
"underline",
|
|
6701
|
+
"underline-grow",
|
|
6702
|
+
"capsule",
|
|
6703
|
+
"scale",
|
|
6704
|
+
"frosted",
|
|
6705
|
+
"solid"
|
|
6706
|
+
]);
|
|
6707
|
+
var navFontWeight = z16.enum(["regular", "medium", "semibold", "bold"]);
|
|
6708
|
+
var headerMaxWidth = z16.enum(["container", "full"]);
|
|
6709
|
+
var headerContainerSchema = z16.object({
|
|
6710
|
+
rounded: z16.enum(["none", "sm", "md", "lg", "xl", "2xl"]).default("xl"),
|
|
6711
|
+
border: z16.boolean().default(true),
|
|
6712
|
+
shadow: z16.boolean().default(true),
|
|
6713
|
+
padding: z16.enum(["sm", "md", "lg"]).default("md"),
|
|
6714
|
+
tint: z16.string().nullable().optional(),
|
|
6715
|
+
opacity: z16.number().min(0).max(1).default(0.12)
|
|
6716
|
+
}).optional();
|
|
6717
|
+
var headerBorderSchema = componentBorderSchema.extend({
|
|
6718
|
+
position: z16.enum(["bottom", "top", "both", "none"]).default("bottom")
|
|
6719
|
+
}).optional();
|
|
6720
|
+
var logoStyleSchema = z16.object({
|
|
6721
|
+
fontFamily: z16.enum(["heading", "body"]).default("heading"),
|
|
6722
|
+
letterSpacing: z16.enum(["normal", "wide", "wider", "widest"]).default("normal"),
|
|
6723
|
+
gradient: z16.boolean().default(false)
|
|
6724
|
+
}).optional();
|
|
6725
|
+
var headerLogoTextSchema = z16.object({
|
|
6726
|
+
mobileWrapLines: z16.union([z16.literal(1), z16.literal(2)]).optional(),
|
|
6727
|
+
mobileMaxWidth: z16.enum(["xs", "sm", "md"]).optional(),
|
|
6728
|
+
hideOnShrink: z16.boolean().optional()
|
|
6729
|
+
}).optional();
|
|
6730
|
+
var navEffectsSchema = z16.object({
|
|
6731
|
+
underlineGradient: z16.boolean().default(false),
|
|
6732
|
+
glow: z16.boolean().default(false),
|
|
6733
|
+
glowColor: z16.string().optional(),
|
|
6734
|
+
neumorphic: z16.boolean().default(false)
|
|
6735
|
+
}).optional();
|
|
6736
|
+
var dropdownStyleSchema = z16.object({
|
|
6737
|
+
// Container styling
|
|
6738
|
+
background: themeColorTokenSchema.default("surface"),
|
|
6739
|
+
textColor: themeColorTokenSchema.default("text"),
|
|
6740
|
+
borderColor: themeColorTokenSchema.nullable().default("border"),
|
|
6741
|
+
shadow: z16.enum(["none", "sm", "md", "lg"]).default("md"),
|
|
6742
|
+
borderRadius: z16.enum(["none", "sm", "md", "lg"]).default("md"),
|
|
6743
|
+
// Link hover states (explicit control)
|
|
6744
|
+
hoverBackground: themeColorTokenSchema.nullable().optional(),
|
|
6745
|
+
hoverTextColor: themeColorTokenSchema.nullable().optional(),
|
|
6746
|
+
// Typography
|
|
6747
|
+
textTransform: z16.enum(["none", "uppercase", "capitalize"]).default("none"),
|
|
6748
|
+
letterSpacing: z16.enum(["normal", "wide", "wider"]).default("normal"),
|
|
6749
|
+
fontWeight: z16.enum(["regular", "medium", "semibold", "bold"]).optional(),
|
|
6750
|
+
// optional = inherit from navWeight
|
|
6751
|
+
textSize: z16.enum(["xs", "sm", "base", "lg"]).optional()
|
|
6752
|
+
// optional = no override (browser default)
|
|
6753
|
+
}).optional();
|
|
6754
|
+
var headerCtaGapSchema = z16.enum([
|
|
6755
|
+
"none",
|
|
6756
|
+
"tight",
|
|
6757
|
+
"compact",
|
|
6758
|
+
"default",
|
|
6759
|
+
"relaxed",
|
|
6760
|
+
"spacious"
|
|
6761
|
+
]);
|
|
6762
|
+
var headerCtaTreatmentSchema = z16.enum([
|
|
6763
|
+
"default",
|
|
6764
|
+
"primary",
|
|
6765
|
+
"secondary",
|
|
6766
|
+
"inverted",
|
|
6767
|
+
"outline",
|
|
6768
|
+
"ghost"
|
|
6769
|
+
]);
|
|
6770
|
+
var navContainerSchema = z16.object({
|
|
6771
|
+
type: z16.enum(["none", "pill", "glass"]).default("none"),
|
|
6772
|
+
tint: z16.string().nullable().optional(),
|
|
6773
|
+
opacity: z16.number().min(0).max(1).default(0.15)
|
|
6774
|
+
}).default({ type: "none", tint: null, opacity: 0.15 });
|
|
6775
|
+
var headerBackgroundSchema = z16.object({
|
|
6776
|
+
type: z16.enum(["color", "gradient", "image"]),
|
|
6777
|
+
color: tokenOrCssColorValueSchema.nullable().optional(),
|
|
6778
|
+
gradient: gradientConfigSchema.nullable().optional(),
|
|
6779
|
+
image: mediaSchema.nullable().optional(),
|
|
6780
|
+
textColor: tokenOrCssColorValueSchema.nullable().optional()
|
|
6781
|
+
});
|
|
6782
|
+
var headerSchema = z16.object({
|
|
6783
|
+
variant: headerVariant,
|
|
6784
|
+
positioning: headerPositioning,
|
|
6785
|
+
shrinkOnScroll: z16.boolean(),
|
|
6786
|
+
maxWidth: headerMaxWidth,
|
|
6787
|
+
logoOverride: mediaSchema.nullable().optional(),
|
|
6788
|
+
background: headerBackgroundSchema.default({
|
|
6789
|
+
type: "color",
|
|
6790
|
+
color: "surface"
|
|
6791
|
+
}),
|
|
6792
|
+
textColor: themeColorTokenSchema.nullable().optional(),
|
|
6793
|
+
navStyle: headerNavStyle,
|
|
6794
|
+
navColor: themeColorTokenSchema.nullable().optional(),
|
|
6795
|
+
navWeight: navFontWeight.default("medium"),
|
|
6796
|
+
// New fields for header system enhancement
|
|
6797
|
+
container: headerContainerSchema,
|
|
6798
|
+
border: headerBorderSchema,
|
|
6799
|
+
shadow: componentShadowSchema.optional(),
|
|
6800
|
+
// defaults to 'sm' for sticky in CSS generator
|
|
6801
|
+
logo: logoStyleSchema,
|
|
6802
|
+
logoText: headerLogoTextSchema,
|
|
6803
|
+
navEffects: navEffectsSchema,
|
|
6804
|
+
navContainer: navContainerSchema,
|
|
6805
|
+
// Full nav link customization (overrides navStyle if set)
|
|
6806
|
+
navLinkStyle: navLinkStyleSchema.optional(),
|
|
6807
|
+
// CTA button spacing (desktop left margin)
|
|
6808
|
+
ctaGap: headerCtaGapSchema.optional(),
|
|
6809
|
+
// Semantic CTA treatment for header/nav CTA buttons. The Theme V2 compiler
|
|
6810
|
+
// materializes this to ctaVariant against the active button personality.
|
|
6811
|
+
ctaTreatment: headerCtaTreatmentSchema.optional(),
|
|
6812
|
+
// Optional theme-level CTA variant for header/nav CTA buttons.
|
|
6813
|
+
// Internal runtime bridge for the block renderer; prefer ctaTreatment in
|
|
6814
|
+
// authored Theme V2 concepts.
|
|
6815
|
+
ctaVariant: z16.string().min(1).optional(),
|
|
6816
|
+
// Dropdown menu styling (nav dropdowns and mobile drawer)
|
|
6817
|
+
dropdownStyle: dropdownStyleSchema
|
|
6818
|
+
});
|
|
6819
|
+
var footerVariant = z16.enum(["simple", "columns", "split"]);
|
|
6820
|
+
var footerMaxWidth = z16.enum(["container", "full"]);
|
|
6821
|
+
var footerMode = z16.enum(["default", "blocks", "default+blocks", "none"]);
|
|
6822
|
+
var footerNavLayoutMode = z16.enum(["stack", "inline", "inline-wrap"]);
|
|
6823
|
+
var footerNavLayoutAlign = z16.enum(["start", "center", "end", "space-between"]);
|
|
6824
|
+
var footerSpacing = z16.enum([
|
|
6825
|
+
"none",
|
|
6826
|
+
"tight",
|
|
6827
|
+
"compact",
|
|
6828
|
+
"default",
|
|
6829
|
+
"relaxed",
|
|
6830
|
+
"spacious"
|
|
6831
|
+
]);
|
|
6832
|
+
var footerLogoPlacement = z16.enum(["left", "right", "above", "below"]);
|
|
6833
|
+
var footerLogoSize = z16.enum(["sm", "md", "lg", "xl"]);
|
|
6834
|
+
var footerLogoMaxHeight = z16.enum(["sm", "md", "lg", "xl"]);
|
|
6835
|
+
var footerBottomTextLinkStyleSchema = z16.object({
|
|
6836
|
+
colorToken: themeColorTokenSchema.optional(),
|
|
6837
|
+
hoverColorToken: themeColorTokenSchema.nullable().optional(),
|
|
6838
|
+
decorationColorToken: themeColorTokenSchema.nullable().optional(),
|
|
6839
|
+
underline: z16.boolean().optional()
|
|
6840
|
+
});
|
|
6841
|
+
var footerBottomBarSchema = z16.object({
|
|
6842
|
+
enabled: z16.boolean().optional(),
|
|
6843
|
+
fullBleed: z16.boolean().optional(),
|
|
6844
|
+
background: headerBackgroundSchema.optional(),
|
|
6845
|
+
textColor: themeColorTokenSchema.nullable().optional(),
|
|
6846
|
+
textAlign: z16.enum(["left", "center", "right"]).optional(),
|
|
6847
|
+
paddingY: footerSpacing.optional(),
|
|
6848
|
+
paddingX: footerSpacing.optional(),
|
|
6849
|
+
borderTop: z16.object({
|
|
6850
|
+
colorToken: themeColorTokenSchema.nullable().optional(),
|
|
6851
|
+
width: z16.enum(["none", "thin", "medium", "thick"]).optional()
|
|
6852
|
+
}).optional()
|
|
6853
|
+
});
|
|
6854
|
+
var footerNavLayoutSchema = z16.object({
|
|
6855
|
+
layout: footerNavLayoutMode.optional(),
|
|
6856
|
+
align: footerNavLayoutAlign.optional(),
|
|
6857
|
+
gapX: footerSpacing.optional(),
|
|
6858
|
+
gapY: footerSpacing.optional(),
|
|
6859
|
+
columns: z16.number().int().min(1).max(6).optional()
|
|
6860
|
+
});
|
|
6861
|
+
var footerLogoSchema = z16.object({
|
|
6862
|
+
showLogo: z16.boolean().default(true),
|
|
6863
|
+
showLogoText: z16.boolean().optional(),
|
|
6864
|
+
placement: footerLogoPlacement.optional(),
|
|
6865
|
+
size: footerLogoSize.optional(),
|
|
6866
|
+
maxHeight: footerLogoMaxHeight.optional(),
|
|
6867
|
+
align: z16.enum(["start", "center", "end"]).optional()
|
|
6868
|
+
});
|
|
6869
|
+
var footerSchema = z16.object({
|
|
6870
|
+
/**
|
|
6871
|
+
* SDK-only footer rendering mode.
|
|
6872
|
+
*
|
|
6873
|
+
* Backwards compatible: missing/undefined behaves as 'default'.
|
|
6874
|
+
*/
|
|
6875
|
+
mode: footerMode.optional(),
|
|
6876
|
+
variant: footerVariant,
|
|
6877
|
+
maxWidth: footerMaxWidth,
|
|
6878
|
+
showLogoText: z16.boolean().optional(),
|
|
6879
|
+
background: headerBackgroundSchema.default({
|
|
6880
|
+
type: "color",
|
|
6881
|
+
color: "surface"
|
|
6882
|
+
}),
|
|
6883
|
+
// Footer nav styling (independent from header)
|
|
6884
|
+
navStyle: headerNavStyle.default("minimal"),
|
|
6885
|
+
navColor: themeColorTokenSchema.nullable().optional(),
|
|
6886
|
+
navWeight: navFontWeight.default("medium"),
|
|
6887
|
+
// Full nav link customization (overrides navStyle if set)
|
|
6888
|
+
navLinkStyle: navLinkStyleSchema.optional(),
|
|
6889
|
+
// Footer bottom rich-text link styling (scoped to footer prose links)
|
|
6890
|
+
bottomTextLinkStyle: footerBottomTextLinkStyleSchema.optional(),
|
|
6891
|
+
// Footer layout controls
|
|
6892
|
+
navLayout: footerNavLayoutSchema.optional(),
|
|
6893
|
+
logo: footerLogoSchema.optional(),
|
|
6894
|
+
bottomBar: footerBottomBarSchema.optional()
|
|
6895
|
+
});
|
|
6896
|
+
var containerPaddingPresetSchema = z16.enum([
|
|
6897
|
+
"tight",
|
|
6898
|
+
"compact",
|
|
6899
|
+
"default",
|
|
6900
|
+
"relaxed"
|
|
6901
|
+
]);
|
|
6902
|
+
var layoutSchema = z16.object({
|
|
6903
|
+
containerPadding: z16.object({
|
|
6904
|
+
mobile: containerPaddingPresetSchema.optional(),
|
|
6905
|
+
tablet: containerPaddingPresetSchema.optional(),
|
|
6906
|
+
desktop: containerPaddingPresetSchema.optional()
|
|
6907
|
+
}).optional()
|
|
6908
|
+
}).optional();
|
|
6909
|
+
var heroTypographySizeSchema = z16.enum([
|
|
6910
|
+
"sm",
|
|
6911
|
+
"base",
|
|
6912
|
+
"lg",
|
|
6913
|
+
"xl",
|
|
6914
|
+
"2xl",
|
|
6915
|
+
"3xl",
|
|
6916
|
+
"4xl",
|
|
6917
|
+
"5xl",
|
|
6918
|
+
"6xl",
|
|
6919
|
+
"editorial"
|
|
6920
|
+
]);
|
|
6921
|
+
var heroTypographyLineHeightSchema = z16.enum([
|
|
6922
|
+
"tight",
|
|
6923
|
+
"snug",
|
|
6924
|
+
"normal",
|
|
6925
|
+
"relaxed"
|
|
6926
|
+
]);
|
|
6927
|
+
var heroResponsiveTypographySchema = z16.object({
|
|
6928
|
+
headlineSize: heroTypographySizeSchema.optional(),
|
|
6929
|
+
headlineLineHeight: heroTypographyLineHeightSchema.optional(),
|
|
6930
|
+
subheadlineSize: heroTypographySizeSchema.optional(),
|
|
6931
|
+
subheadlineLineHeight: heroTypographyLineHeightSchema.optional()
|
|
6932
|
+
});
|
|
6933
|
+
var heroTypographySchema = z16.object({
|
|
6934
|
+
headlineSize: heroTypographySizeSchema.optional(),
|
|
6935
|
+
headlineLineHeight: heroTypographyLineHeightSchema.optional(),
|
|
6936
|
+
subheadlineSize: heroTypographySizeSchema.optional(),
|
|
6937
|
+
subheadlineLineHeight: heroTypographyLineHeightSchema.optional(),
|
|
6938
|
+
microHeadlineSize: heroTypographySizeSchema.optional(),
|
|
6939
|
+
microHeadlineLineHeight: heroTypographyLineHeightSchema.optional(),
|
|
6940
|
+
microSubheadlineSize: heroTypographySizeSchema.optional(),
|
|
6941
|
+
microSubheadlineLineHeight: heroTypographyLineHeightSchema.optional(),
|
|
6942
|
+
responsive: z16.object({
|
|
6943
|
+
tablet: heroResponsiveTypographySchema.optional(),
|
|
6944
|
+
mobile: heroResponsiveTypographySchema.optional()
|
|
6945
|
+
}).optional()
|
|
6946
|
+
});
|
|
6947
|
+
var heroSchema = z16.object({
|
|
6948
|
+
typography: heroTypographySchema.optional()
|
|
6949
|
+
}).optional();
|
|
6950
|
+
var bodyTextIntroTypographySizeSchema = z16.enum(["default", "editorial"]);
|
|
6951
|
+
var bodyTextSchema = z16.object({
|
|
6952
|
+
intro: z16.object({
|
|
6953
|
+
paragraphSize: bodyTextIntroTypographySizeSchema.optional(),
|
|
6954
|
+
headingSize: bodyTextIntroTypographySizeSchema.optional()
|
|
6955
|
+
}).optional()
|
|
6956
|
+
}).optional();
|
|
6957
|
+
var gradientsSchema = z16.object({
|
|
6958
|
+
button: z16.string().min(1).nullable().optional(),
|
|
6959
|
+
hero: z16.string().min(1).nullable().optional(),
|
|
6960
|
+
background: z16.string().min(1).nullable().optional()
|
|
6961
|
+
});
|
|
6962
|
+
var themeSchema = z16.object({
|
|
6963
|
+
name: z16.string().min(1).max(30),
|
|
6964
|
+
description: z16.string().min(1).max(400),
|
|
6965
|
+
rationale: z16.string().min(1).max(400),
|
|
6966
|
+
siteStyleId: z16.string().min(1).transform((value) => asSiteStyleId(value)).optional(),
|
|
6967
|
+
axes: axesSchema,
|
|
6968
|
+
palette: paletteSchema,
|
|
6969
|
+
typography: typographySchema,
|
|
6970
|
+
space: spaceSchema,
|
|
6971
|
+
border,
|
|
6972
|
+
shadow,
|
|
6973
|
+
motion,
|
|
6974
|
+
corners,
|
|
6975
|
+
gradients: gradientsSchema.optional(),
|
|
6976
|
+
layout: layoutSchema,
|
|
6977
|
+
hero: heroSchema,
|
|
6978
|
+
bodyText: bodyTextSchema,
|
|
6979
|
+
header: headerSchema,
|
|
6980
|
+
footer: footerSchema,
|
|
6981
|
+
buttons: buttonSystemSchema.optional(),
|
|
6982
|
+
// New button system (optional for backwards compatibility)
|
|
6983
|
+
cards: cardSystemSchema.optional(),
|
|
6984
|
+
// Card variant system (optional for backwards compatibility)
|
|
6985
|
+
accordions: accordionSystemSchema.optional(),
|
|
6986
|
+
// Accordion system (optional - generated if not provided)
|
|
6987
|
+
inputs: inputSystemSchema.optional(),
|
|
6988
|
+
// Input system (optional - generated if not provided)
|
|
6989
|
+
inputStyle: inputStyle.optional(),
|
|
6990
|
+
// Simple input styling API (drives InputSystem defaults)
|
|
6991
|
+
// Block-specific customization (Tier 3)
|
|
6992
|
+
// blockCustomVars: Per-block CSS variable overrides as bare values
|
|
6993
|
+
// Example: { "event-registration": { "--step-color": "#6d28d9" } }
|
|
6994
|
+
blockCustomVars: z16.record(
|
|
6995
|
+
z16.string(),
|
|
6996
|
+
// block kind (matches data-block attribute)
|
|
6997
|
+
z16.record(z16.string(), z16.string())
|
|
6998
|
+
// { '--var-name': 'value' }
|
|
6999
|
+
).optional(),
|
|
7000
|
+
// Structured block-kind theme overrides (v1: typography prose-link style only)
|
|
7001
|
+
// Keyed by block kind (usually data-block value like "hero"; "block.hero" also accepted)
|
|
7002
|
+
blockOverrides: z16.record(z16.string(), blockThemeOverrideSchema).optional(),
|
|
7003
|
+
// Structured custom CSS rules
|
|
7004
|
+
// Validated, scoped, and safe by construction - no @import, remote url(), or global selectors
|
|
7005
|
+
customCssRules: customCssRulesSchema,
|
|
7006
|
+
// Structured block-specific CSS rules
|
|
7007
|
+
blockCustomCssRules: blockCustomCssRulesSchema,
|
|
7008
|
+
// Structured CSS at-rules (@keyframes, @media, @font-face, etc.)
|
|
7009
|
+
// @keyframes and @font-face are global; @media/@supports have scoped selectors
|
|
7010
|
+
customCssAtRules: customCssAtRulesSchema,
|
|
7011
|
+
/**
|
|
7012
|
+
* Style groups define named visual presets that content authors can apply to blocks.
|
|
7013
|
+
*
|
|
7014
|
+
* Unlike variants (which change block structure/layout), style groups only affect
|
|
7015
|
+
* CSS styling. The selected style group is rendered as a `data-style-group` attribute
|
|
7016
|
+
* on the block wrapper, which can be targeted in `blockCustomCssRules`.
|
|
7017
|
+
*
|
|
7018
|
+
* @example
|
|
7019
|
+
* ```typescript
|
|
7020
|
+
* {
|
|
7021
|
+
* styleGroups: {
|
|
7022
|
+
* hero: ['bold', 'minimal', 'featured'],
|
|
7023
|
+
* 'body-text': ['intro', 'compact'],
|
|
7024
|
+
* },
|
|
7025
|
+
* blockCustomCssRules: [
|
|
7026
|
+
* {
|
|
7027
|
+
* id: 'hero-bold-headline',
|
|
7028
|
+
* blockKind: 'hero',
|
|
7029
|
+
* selector: '&[data-style-group="bold"] .hero-headline',
|
|
7030
|
+
* declarations: { fontWeight: '800', fontSize: '3rem' }
|
|
7031
|
+
* }
|
|
7032
|
+
* ]
|
|
7033
|
+
* }
|
|
7034
|
+
* ```
|
|
7035
|
+
*/
|
|
7036
|
+
styleGroups: z16.record(z16.string(), z16.array(z16.string())).optional()
|
|
7037
|
+
});
|
|
7038
|
+
var themesTurnSchema = z16.object({
|
|
7039
|
+
message: z16.string().min(1),
|
|
7040
|
+
themes: z16.array(themeSchema).length(3)
|
|
7041
|
+
});
|
|
7042
|
+
|
|
7043
|
+
// ../theme-core/src/palette/variants/types.ts
|
|
7044
|
+
function asPaletteVariantId(value) {
|
|
7045
|
+
if (value.length === 0) {
|
|
7046
|
+
throw new Error("PaletteVariantId must be a non-empty string");
|
|
7047
|
+
}
|
|
7048
|
+
return value;
|
|
7049
|
+
}
|
|
7050
|
+
var paletteVariantIdSchema = z17.string().min(1).transform((value) => asPaletteVariantId(value));
|
|
7051
|
+
var HEX_COLOR_REGEX = /^#[0-9a-f]{6}$/;
|
|
7052
|
+
var hexColorSchema = z17.string().regex(HEX_COLOR_REGEX, "Hex must be #RRGGBB (lowercase)").transform((value) => value);
|
|
7053
|
+
var variantPaletteColorSchema = paletteColorSchema.extend({
|
|
7054
|
+
name: paletteTokenNameSchema
|
|
7055
|
+
});
|
|
7056
|
+
var paletteVariantSchema = z17.object({
|
|
7057
|
+
id: paletteVariantIdSchema,
|
|
7058
|
+
name: z17.string().min(1),
|
|
7059
|
+
description: z17.string().min(1),
|
|
7060
|
+
tags: styleTagsSchema,
|
|
7061
|
+
mode: z17.enum(["light", "dark"]),
|
|
7062
|
+
colors: z17.array(variantPaletteColorSchema).min(1)
|
|
7063
|
+
});
|
|
7064
|
+
function definePaletteVariant(input) {
|
|
7065
|
+
return {
|
|
7066
|
+
id: asPaletteVariantId(input.id),
|
|
7067
|
+
name: input.name,
|
|
7068
|
+
description: input.description,
|
|
7069
|
+
tags: input.tags,
|
|
7070
|
+
mode: input.mode,
|
|
7071
|
+
colors: input.colors
|
|
7072
|
+
};
|
|
7073
|
+
}
|
|
7074
|
+
var paletteOverridesSchema = z17.object({
|
|
7075
|
+
primary: hexColorSchema.optional(),
|
|
7076
|
+
primaryForeground: hexColorSchema.optional(),
|
|
7077
|
+
secondary: hexColorSchema.optional(),
|
|
7078
|
+
accent: hexColorSchema.optional(),
|
|
7079
|
+
success: hexColorSchema.optional(),
|
|
7080
|
+
warning: hexColorSchema.optional(),
|
|
7081
|
+
destructive: hexColorSchema.optional(),
|
|
7082
|
+
background: hexColorSchema.optional(),
|
|
7083
|
+
surface: hexColorSchema.optional(),
|
|
7084
|
+
surfaceAlt: hexColorSchema.optional(),
|
|
7085
|
+
muted: hexColorSchema.optional(),
|
|
7086
|
+
text: hexColorSchema.optional(),
|
|
7087
|
+
border: hexColorSchema.optional()
|
|
7088
|
+
}).strict().transform((value) => value);
|
|
7089
|
+
|
|
7090
|
+
// ../theme-core/src/palette/variants/brand-led.ts
|
|
7091
|
+
var brandLedCool = definePaletteVariant({
|
|
7092
|
+
id: "brand-led-cool",
|
|
7093
|
+
name: "Brand-led \u2014 Cool",
|
|
7094
|
+
description: "Confident blue primary with slate neutrals.",
|
|
7095
|
+
tags: { tone: "classic", energy: "calm", era: "modern" },
|
|
7096
|
+
mode: "light",
|
|
7097
|
+
colors: [
|
|
7098
|
+
{ name: "primary", hex: "#2563eb" },
|
|
7099
|
+
{ name: "secondary", hex: "#64748b" },
|
|
7100
|
+
{ name: "accent", hex: "#0f766e" },
|
|
7101
|
+
{ name: "success", hex: "#16a34a" },
|
|
7102
|
+
{ name: "warning", hex: "#d97706" },
|
|
7103
|
+
{ name: "destructive", hex: "#dc2626" },
|
|
7104
|
+
{ name: "background", hex: "#ffffff" },
|
|
7105
|
+
{ name: "surface", hex: "#ffffff" },
|
|
7106
|
+
{ name: "surfaceAlt", hex: "#f8fafc" },
|
|
7107
|
+
{ name: "muted", hex: "#f1f5f9" },
|
|
7108
|
+
{ name: "text", hex: "#0f172a" },
|
|
7109
|
+
{ name: "primaryForeground", hex: "#ffffff" },
|
|
7110
|
+
{ name: "border", hex: "#cbd5e1" }
|
|
7111
|
+
]
|
|
7112
|
+
});
|
|
7113
|
+
var brandLedWarm = definePaletteVariant({
|
|
7114
|
+
id: "brand-led-warm",
|
|
7115
|
+
name: "Brand-led \u2014 Warm",
|
|
7116
|
+
description: "Sunset orange primary with warm grey neutrals.",
|
|
7117
|
+
tags: { tone: "classic", energy: "vibrant", era: "modern" },
|
|
7118
|
+
mode: "light",
|
|
7119
|
+
colors: [
|
|
7120
|
+
{ name: "primary", hex: "#ea580c" },
|
|
7121
|
+
{ name: "secondary", hex: "#78716c" },
|
|
7122
|
+
{ name: "accent", hex: "#a16207" },
|
|
7123
|
+
{ name: "success", hex: "#16a34a" },
|
|
7124
|
+
{ name: "warning", hex: "#d97706" },
|
|
7125
|
+
{ name: "destructive", hex: "#b91c1c" },
|
|
7126
|
+
{ name: "background", hex: "#fffaf3" },
|
|
7127
|
+
{ name: "surface", hex: "#ffffff" },
|
|
7128
|
+
{ name: "surfaceAlt", hex: "#fbeee0" },
|
|
7129
|
+
{ name: "muted", hex: "#f4e2cd" },
|
|
7130
|
+
{ name: "text", hex: "#1c1917" },
|
|
7131
|
+
{ name: "primaryForeground", hex: "#fffaf3" },
|
|
7132
|
+
{ name: "border", hex: "#d6c4ad" }
|
|
7133
|
+
]
|
|
7134
|
+
});
|
|
7135
|
+
var brandLedJewel = definePaletteVariant({
|
|
7136
|
+
id: "brand-led-jewel",
|
|
7137
|
+
name: "Brand-led \u2014 Jewel",
|
|
7138
|
+
description: "Deep emerald primary with rich neutrals.",
|
|
7139
|
+
tags: { tone: "bold", energy: "vibrant", era: "modern" },
|
|
7140
|
+
mode: "light",
|
|
7141
|
+
colors: [
|
|
7142
|
+
{ name: "primary", hex: "#047857" },
|
|
7143
|
+
{ name: "secondary", hex: "#4b5563" },
|
|
7144
|
+
{ name: "accent", hex: "#7c3aed" },
|
|
7145
|
+
{ name: "success", hex: "#15803d" },
|
|
7146
|
+
{ name: "warning", hex: "#b45309" },
|
|
7147
|
+
{ name: "destructive", hex: "#b91c1c" },
|
|
7148
|
+
{ name: "background", hex: "#ffffff" },
|
|
7149
|
+
{ name: "surface", hex: "#ffffff" },
|
|
7150
|
+
{ name: "surfaceAlt", hex: "#f5f5f4" },
|
|
7151
|
+
{ name: "muted", hex: "#e7e5e4" },
|
|
7152
|
+
{ name: "text", hex: "#0c0a09" },
|
|
7153
|
+
{ name: "primaryForeground", hex: "#ffffff" },
|
|
7154
|
+
{ name: "border", hex: "#a8a29e" }
|
|
7155
|
+
]
|
|
7156
|
+
});
|
|
7157
|
+
var brandLedBurgundyGold = definePaletteVariant({
|
|
7158
|
+
id: "brand-led-burgundy-gold",
|
|
7159
|
+
name: "Brand-led \u2014 Burgundy Gold",
|
|
7160
|
+
description: "Deep burgundy with warm gold accents and soft neutral grounds.",
|
|
7161
|
+
tags: { tone: "bold", energy: "vibrant", era: "modern" },
|
|
7162
|
+
mode: "light",
|
|
7163
|
+
colors: [
|
|
7164
|
+
{ name: "primary", hex: "#7c2e38" },
|
|
7165
|
+
{ name: "secondary", hex: "#d4af37" },
|
|
7166
|
+
{ name: "accent", hex: "#b8e19a" },
|
|
7167
|
+
{ name: "success", hex: "#10b981" },
|
|
7168
|
+
{ name: "warning", hex: "#f59e0b" },
|
|
7169
|
+
{ name: "destructive", hex: "#ef4444" },
|
|
7170
|
+
{ name: "background", hex: "#f1dfd0" },
|
|
7171
|
+
{ name: "surface", hex: "#f5e6db" },
|
|
7172
|
+
{ name: "surfaceAlt", hex: "#f8ece3" },
|
|
7173
|
+
{ name: "muted", hex: "#c9b8a8" },
|
|
7174
|
+
{ name: "text", hex: "#400000" },
|
|
7175
|
+
{ name: "primaryForeground", hex: "#ffffff" },
|
|
7176
|
+
{ name: "border", hex: "#c9b8a8" }
|
|
7177
|
+
]
|
|
7178
|
+
});
|
|
7179
|
+
|
|
7180
|
+
// ../theme-core/src/palette/variants/high-contrast.ts
|
|
7181
|
+
var highContrastInk = definePaletteVariant({
|
|
7182
|
+
id: "high-contrast-ink",
|
|
7183
|
+
name: "High Contrast \u2014 Ink",
|
|
7184
|
+
description: "Near-black primary with cool greys.",
|
|
7185
|
+
tags: { tone: "bold", energy: "calm", era: "editorial" },
|
|
7186
|
+
mode: "light",
|
|
7187
|
+
colors: [
|
|
7188
|
+
{ name: "primary", hex: "#111827" },
|
|
7189
|
+
{ name: "secondary", hex: "#374151" },
|
|
7190
|
+
{ name: "accent", hex: "#1d4ed8" },
|
|
7191
|
+
{ name: "success", hex: "#047857" },
|
|
7192
|
+
{ name: "warning", hex: "#b45309" },
|
|
7193
|
+
{ name: "destructive", hex: "#b91c1c" },
|
|
7194
|
+
{ name: "background", hex: "#ffffff" },
|
|
7195
|
+
{ name: "surface", hex: "#ffffff" },
|
|
7196
|
+
{ name: "surfaceAlt", hex: "#f3f4f6" },
|
|
7197
|
+
{ name: "muted", hex: "#e5e7eb" },
|
|
7198
|
+
{ name: "text", hex: "#030712" },
|
|
7199
|
+
{ name: "primaryForeground", hex: "#ffffff" },
|
|
7200
|
+
{ name: "border", hex: "#6b7280" }
|
|
7201
|
+
]
|
|
7202
|
+
});
|
|
7203
|
+
var highContrastCharcoal = definePaletteVariant({
|
|
7204
|
+
id: "high-contrast-charcoal",
|
|
7205
|
+
name: "High Contrast \u2014 Charcoal",
|
|
7206
|
+
description: "Warm charcoal primary on a soft cream ground.",
|
|
7207
|
+
tags: { tone: "minimal", energy: "calm", era: "editorial" },
|
|
7208
|
+
mode: "light",
|
|
7209
|
+
colors: [
|
|
7210
|
+
{ name: "primary", hex: "#1f2937" },
|
|
7211
|
+
{ name: "secondary", hex: "#52525b" },
|
|
7212
|
+
{ name: "accent", hex: "#a16207" },
|
|
7213
|
+
{ name: "success", hex: "#15803d" },
|
|
7214
|
+
{ name: "warning", hex: "#b45309" },
|
|
7215
|
+
{ name: "destructive", hex: "#991b1b" },
|
|
7216
|
+
{ name: "background", hex: "#fafaf9" },
|
|
7217
|
+
{ name: "surface", hex: "#ffffff" },
|
|
7218
|
+
{ name: "surfaceAlt", hex: "#f5f5f4" },
|
|
7219
|
+
{ name: "muted", hex: "#e7e5e4" },
|
|
7220
|
+
{ name: "text", hex: "#0c0a09" },
|
|
7221
|
+
{ name: "primaryForeground", hex: "#fafaf9" },
|
|
7222
|
+
{ name: "border", hex: "#a8a29e" }
|
|
7223
|
+
]
|
|
7224
|
+
});
|
|
7225
|
+
var highContrastMonochrome = definePaletteVariant({
|
|
7226
|
+
id: "high-contrast-monochrome",
|
|
7227
|
+
name: "High Contrast \u2014 Monochrome",
|
|
7228
|
+
description: "Pure black-on-white with a single saturated accent.",
|
|
7229
|
+
tags: { tone: "bold", energy: "vibrant", era: "editorial" },
|
|
7230
|
+
mode: "light",
|
|
7231
|
+
colors: [
|
|
7232
|
+
{ name: "primary", hex: "#000000" },
|
|
7233
|
+
{ name: "secondary", hex: "#404040" },
|
|
7234
|
+
{ name: "accent", hex: "#dc2626" },
|
|
7235
|
+
{ name: "success", hex: "#000000" },
|
|
7236
|
+
{ name: "warning", hex: "#000000" },
|
|
7237
|
+
{ name: "destructive", hex: "#dc2626" },
|
|
7238
|
+
{ name: "background", hex: "#ffffff" },
|
|
7239
|
+
{ name: "surface", hex: "#ffffff" },
|
|
7240
|
+
{ name: "surfaceAlt", hex: "#f5f5f5" },
|
|
7241
|
+
{ name: "muted", hex: "#e5e5e5" },
|
|
7242
|
+
{ name: "text", hex: "#000000" },
|
|
7243
|
+
{ name: "primaryForeground", hex: "#ffffff" },
|
|
7244
|
+
{ name: "border", hex: "#525252" }
|
|
7245
|
+
]
|
|
7246
|
+
});
|
|
7247
|
+
|
|
7248
|
+
// ../theme-core/src/palette/variants/soft-natural.ts
|
|
7249
|
+
var softNaturalSage = definePaletteVariant({
|
|
7250
|
+
id: "soft-natural-sage",
|
|
7251
|
+
name: "Soft Natural \u2014 Sage",
|
|
7252
|
+
description: "Olive sage primary on an off-white ground.",
|
|
7253
|
+
tags: { tone: "classic", energy: "calm", era: "organic" },
|
|
7254
|
+
mode: "light",
|
|
7255
|
+
colors: [
|
|
7256
|
+
{ name: "primary", hex: "#3f6212" },
|
|
7257
|
+
{ name: "secondary", hex: "#6b7280" },
|
|
7258
|
+
{ name: "accent", hex: "#0f766e" },
|
|
7259
|
+
{ name: "success", hex: "#15803d" },
|
|
7260
|
+
{ name: "warning", hex: "#a16207" },
|
|
7261
|
+
{ name: "destructive", hex: "#b91c1c" },
|
|
7262
|
+
{ name: "background", hex: "#fbfdf7" },
|
|
7263
|
+
{ name: "surface", hex: "#ffffff" },
|
|
7264
|
+
{ name: "surfaceAlt", hex: "#eef5e8" },
|
|
7265
|
+
{ name: "muted", hex: "#e7efdf" },
|
|
7266
|
+
{ name: "text", hex: "#1f2a1d" },
|
|
7267
|
+
{ name: "primaryForeground", hex: "#ffffff" },
|
|
7268
|
+
{ name: "border", hex: "#cbd8c0" }
|
|
7269
|
+
]
|
|
7270
|
+
});
|
|
7271
|
+
var softNaturalStone = definePaletteVariant({
|
|
7272
|
+
id: "soft-natural-stone",
|
|
7273
|
+
name: "Soft Natural \u2014 Stone",
|
|
7274
|
+
description: "River-stone grey-green primary with cool neutrals.",
|
|
7275
|
+
tags: { tone: "minimal", energy: "calm", era: "organic" },
|
|
7276
|
+
mode: "light",
|
|
7277
|
+
colors: [
|
|
7278
|
+
{ name: "primary", hex: "#5a7a5d" },
|
|
7279
|
+
{ name: "secondary", hex: "#8a9a8c" },
|
|
7280
|
+
{ name: "accent", hex: "#c9b88f" },
|
|
7281
|
+
{ name: "success", hex: "#5a7a5d" },
|
|
7282
|
+
{ name: "warning", hex: "#a89466" },
|
|
7283
|
+
{ name: "destructive", hex: "#a3503e" },
|
|
7284
|
+
{ name: "background", hex: "#faf6ec" },
|
|
7285
|
+
{ name: "surface", hex: "#ffffff" },
|
|
7286
|
+
{ name: "surfaceAlt", hex: "#f0ecdf" },
|
|
7287
|
+
{ name: "muted", hex: "#e6e1d0" },
|
|
7288
|
+
{ name: "text", hex: "#2f3d31" },
|
|
7289
|
+
{ name: "primaryForeground", hex: "#faf6ec" },
|
|
7290
|
+
{ name: "border", hex: "#c9c1ad" }
|
|
7291
|
+
]
|
|
7292
|
+
});
|
|
7293
|
+
var softNaturalWatercolor = definePaletteVariant({
|
|
7294
|
+
id: "soft-natural-watercolor",
|
|
7295
|
+
name: "Soft Natural \u2014 Watercolor",
|
|
7296
|
+
description: "Soft sand primary with watercolour sage accents.",
|
|
7297
|
+
tags: { tone: "classic", energy: "vibrant", era: "organic" },
|
|
7298
|
+
mode: "light",
|
|
7299
|
+
colors: [
|
|
7300
|
+
{ name: "primary", hex: "#a8825f" },
|
|
7301
|
+
{ name: "secondary", hex: "#88a888" },
|
|
7302
|
+
{ name: "accent", hex: "#c8a78e" },
|
|
7303
|
+
{ name: "success", hex: "#7d8a5f" },
|
|
7304
|
+
{ name: "warning", hex: "#c89a4d" },
|
|
7305
|
+
{ name: "destructive", hex: "#a3503e" },
|
|
7306
|
+
{ name: "background", hex: "#fefdfa" },
|
|
7307
|
+
{ name: "surface", hex: "#ffffff" },
|
|
7308
|
+
{ name: "surfaceAlt", hex: "#f6f1e6" },
|
|
7309
|
+
{ name: "muted", hex: "#eee7d1" },
|
|
7310
|
+
{ name: "text", hex: "#4a3d30" },
|
|
7311
|
+
{ name: "primaryForeground", hex: "#fefdfa" },
|
|
7312
|
+
{ name: "border", hex: "#d8c9a8" }
|
|
7313
|
+
]
|
|
7314
|
+
});
|
|
7315
|
+
|
|
7316
|
+
// ../theme-core/src/palette/variants/warm-neutral.ts
|
|
7317
|
+
var warmNeutralClay = definePaletteVariant({
|
|
7318
|
+
id: "warm-neutral-clay",
|
|
7319
|
+
name: "Warm Neutral \u2014 Clay",
|
|
7320
|
+
description: "Terracotta primary on a cream ground.",
|
|
7321
|
+
tags: { tone: "classic", energy: "calm", era: "organic" },
|
|
7322
|
+
mode: "light",
|
|
7323
|
+
colors: [
|
|
7324
|
+
{ name: "primary", hex: "#8b5e34" },
|
|
7325
|
+
{ name: "secondary", hex: "#7c6f64" },
|
|
7326
|
+
{ name: "accent", hex: "#a15c38" },
|
|
7327
|
+
{ name: "success", hex: "#527853" },
|
|
7328
|
+
{ name: "warning", hex: "#b7791f" },
|
|
7329
|
+
{ name: "destructive", hex: "#b91c1c" },
|
|
7330
|
+
{ name: "background", hex: "#fffaf3" },
|
|
7331
|
+
{ name: "surface", hex: "#ffffff" },
|
|
7332
|
+
{ name: "surfaceAlt", hex: "#f5eadc" },
|
|
7333
|
+
{ name: "muted", hex: "#efe2d0" },
|
|
7334
|
+
{ name: "text", hex: "#2f241c" },
|
|
7335
|
+
{ name: "primaryForeground", hex: "#fffaf3" },
|
|
7336
|
+
{ name: "border", hex: "#d8c6b3" }
|
|
7337
|
+
]
|
|
7338
|
+
});
|
|
7339
|
+
var warmNeutralCream = definePaletteVariant({
|
|
7340
|
+
id: "warm-neutral-cream",
|
|
7341
|
+
name: "Warm Neutral \u2014 Cream",
|
|
7342
|
+
description: "Soft sand primary with pale cream surfaces.",
|
|
7343
|
+
tags: { tone: "minimal", energy: "calm", era: "organic" },
|
|
7344
|
+
mode: "light",
|
|
7345
|
+
colors: [
|
|
7346
|
+
{ name: "primary", hex: "#b08864" },
|
|
7347
|
+
{ name: "secondary", hex: "#9a8c7e" },
|
|
7348
|
+
{ name: "accent", hex: "#c2956a" },
|
|
7349
|
+
{ name: "success", hex: "#7d8a5f" },
|
|
7350
|
+
{ name: "warning", hex: "#c89a4d" },
|
|
7351
|
+
{ name: "destructive", hex: "#a3503e" },
|
|
7352
|
+
{ name: "background", hex: "#fdf8ee" },
|
|
7353
|
+
{ name: "surface", hex: "#ffffff" },
|
|
7354
|
+
{ name: "surfaceAlt", hex: "#f4ebd9" },
|
|
7355
|
+
{ name: "muted", hex: "#ede3cf" },
|
|
7356
|
+
{ name: "text", hex: "#3b2f24" },
|
|
7357
|
+
{ name: "primaryForeground", hex: "#fdf8ee" },
|
|
7358
|
+
{ name: "border", hex: "#e0d2b8" }
|
|
7359
|
+
]
|
|
7360
|
+
});
|
|
7361
|
+
var warmNeutralSoftEarth = definePaletteVariant({
|
|
7362
|
+
id: "warm-neutral-soft-earth",
|
|
7363
|
+
name: "Warm Neutral \u2014 Soft Earth",
|
|
7364
|
+
description: "Cream ground with terracotta primary, clay accents, and olive depth.",
|
|
7365
|
+
tags: { tone: "classic", energy: "calm", era: "organic" },
|
|
7366
|
+
mode: "light",
|
|
7367
|
+
colors: [
|
|
7368
|
+
{ name: "primary", hex: "#a8573d" },
|
|
7369
|
+
{ name: "secondary", hex: "#72765c" },
|
|
7370
|
+
{ name: "accent", hex: "#c87557" },
|
|
7371
|
+
{ name: "success", hex: "#687854" },
|
|
7372
|
+
{ name: "warning", hex: "#b7863e" },
|
|
7373
|
+
{ name: "destructive", hex: "#a54b3c" },
|
|
7374
|
+
{ name: "background", hex: "#fbf6eb" },
|
|
7375
|
+
{ name: "surface", hex: "#fffdf7" },
|
|
7376
|
+
{ name: "surfaceAlt", hex: "#f0e4d3" },
|
|
7377
|
+
{ name: "muted", hex: "#eadbc6" },
|
|
7378
|
+
{ name: "text", hex: "#30281f" },
|
|
7379
|
+
{ name: "primaryForeground", hex: "#fffaf3" },
|
|
7380
|
+
{ name: "border", hex: "#d9c8b2" }
|
|
7381
|
+
]
|
|
7382
|
+
});
|
|
7383
|
+
var warmNeutralForest = definePaletteVariant({
|
|
7384
|
+
id: "warm-neutral-forest",
|
|
7385
|
+
name: "Warm Neutral \u2014 Forest",
|
|
7386
|
+
description: "Deep forest green primary with earthy neutrals.",
|
|
7387
|
+
tags: { tone: "classic", energy: "calm", era: "organic" },
|
|
7388
|
+
mode: "light",
|
|
7389
|
+
colors: [
|
|
7390
|
+
{ name: "primary", hex: "#3d5840" },
|
|
7391
|
+
{ name: "secondary", hex: "#7a6f5d" },
|
|
7392
|
+
{ name: "accent", hex: "#b06b50" },
|
|
7393
|
+
{ name: "success", hex: "#5a7a5d" },
|
|
7394
|
+
{ name: "warning", hex: "#b7791f" },
|
|
7395
|
+
{ name: "destructive", hex: "#b91c1c" },
|
|
7396
|
+
{ name: "background", hex: "#fbf8f0" },
|
|
7397
|
+
{ name: "surface", hex: "#ffffff" },
|
|
7398
|
+
{ name: "surfaceAlt", hex: "#f2ecdb" },
|
|
7399
|
+
{ name: "muted", hex: "#ebe3cc" },
|
|
7400
|
+
{ name: "text", hex: "#2a2a2a" },
|
|
7401
|
+
{ name: "primaryForeground", hex: "#fbf8f0" },
|
|
7402
|
+
{ name: "border", hex: "#cdc1a4" }
|
|
7403
|
+
]
|
|
7404
|
+
});
|
|
7405
|
+
|
|
7406
|
+
// ../theme-core/src/palette/variants/index.ts
|
|
7407
|
+
var paletteVariants = [
|
|
7408
|
+
// Brand-led family
|
|
7409
|
+
brandLedCool,
|
|
7410
|
+
brandLedWarm,
|
|
7411
|
+
brandLedJewel,
|
|
7412
|
+
brandLedBurgundyGold,
|
|
7413
|
+
// Warm-neutral family
|
|
7414
|
+
warmNeutralClay,
|
|
7415
|
+
warmNeutralCream,
|
|
7416
|
+
warmNeutralSoftEarth,
|
|
7417
|
+
warmNeutralForest,
|
|
7418
|
+
// High-contrast family
|
|
7419
|
+
highContrastInk,
|
|
7420
|
+
highContrastCharcoal,
|
|
7421
|
+
highContrastMonochrome,
|
|
7422
|
+
// Soft-natural family
|
|
7423
|
+
softNaturalSage,
|
|
7424
|
+
softNaturalStone,
|
|
7425
|
+
softNaturalWatercolor
|
|
7426
|
+
];
|
|
7427
|
+
var paletteVariantsById = new Map(
|
|
7428
|
+
paletteVariants.map((v) => [v.id, v])
|
|
7429
|
+
);
|
|
7430
|
+
|
|
7431
|
+
// ../theme-core/src/accordions/siteStyleDefaults.ts
|
|
7432
|
+
var softEarthAccordionSystem = {
|
|
7433
|
+
background: {
|
|
7434
|
+
type: "solid",
|
|
7435
|
+
colorToken: "background"
|
|
7436
|
+
},
|
|
7437
|
+
spacing: "comfortable",
|
|
7438
|
+
corners: "square",
|
|
7439
|
+
border: null,
|
|
7440
|
+
shadow: null,
|
|
7441
|
+
icon: {
|
|
7442
|
+
style: "plus-minus",
|
|
7443
|
+
position: "right",
|
|
7444
|
+
size: "md",
|
|
7445
|
+
colorToken: "primary"
|
|
7446
|
+
},
|
|
7447
|
+
trigger: {
|
|
7448
|
+
textColorToken: "text",
|
|
7449
|
+
fontWeight: "medium"
|
|
7450
|
+
},
|
|
7451
|
+
hover: {
|
|
7452
|
+
textColorToken: "primary"
|
|
7453
|
+
},
|
|
7454
|
+
content: {
|
|
7455
|
+
textColorToken: "neutral-700"
|
|
7456
|
+
}
|
|
7457
|
+
};
|
|
7458
|
+
|
|
7459
|
+
// ../theme-core/src/site-styles/headerLooks.ts
|
|
7460
|
+
function asHeaderLookId(value) {
|
|
7461
|
+
return value;
|
|
7462
|
+
}
|
|
7463
|
+
function asHeaderLayoutId(value) {
|
|
7464
|
+
return value;
|
|
7465
|
+
}
|
|
7466
|
+
function asHeaderStyleId(value) {
|
|
7467
|
+
return value;
|
|
7468
|
+
}
|
|
7469
|
+
function baseHeader(theme) {
|
|
7470
|
+
const {
|
|
7471
|
+
navLinkStyle: _navLinkStyle,
|
|
7472
|
+
dropdownStyle: _dropdownStyle,
|
|
7473
|
+
ctaVariant: _ctaVariant,
|
|
7474
|
+
navContainer: _navContainer,
|
|
7475
|
+
container: _container,
|
|
7476
|
+
shadow: _shadow,
|
|
7477
|
+
logo: _logo,
|
|
7478
|
+
logoText: _logoText,
|
|
7479
|
+
border: _border,
|
|
7480
|
+
...header
|
|
7481
|
+
} = theme.header;
|
|
7482
|
+
return {
|
|
7483
|
+
...header,
|
|
7484
|
+
navContainer: { type: "none", tint: null, opacity: 0.15 }
|
|
7485
|
+
};
|
|
7486
|
+
}
|
|
7487
|
+
var headerLayoutCatalog = [
|
|
7488
|
+
{
|
|
7489
|
+
id: asHeaderLayoutId("classic"),
|
|
7490
|
+
label: "Classic",
|
|
7491
|
+
description: "Logo and navigation in one practical horizontal row.",
|
|
7492
|
+
structure: "inline-classic",
|
|
7493
|
+
variant: "classic",
|
|
7494
|
+
defaultPositioning: "sticky",
|
|
7495
|
+
shrinkOnScroll: false
|
|
7496
|
+
},
|
|
7497
|
+
{
|
|
7498
|
+
id: asHeaderLayoutId("centered"),
|
|
7499
|
+
label: "Centered",
|
|
7500
|
+
description: "Logo centered above a balanced navigation row.",
|
|
7501
|
+
structure: "centered-stack",
|
|
7502
|
+
variant: "centered",
|
|
7503
|
+
defaultPositioning: "static",
|
|
7504
|
+
shrinkOnScroll: false,
|
|
7505
|
+
maxRecommendedNavItems: 5,
|
|
7506
|
+
allowedLogoShapes: ["none", "text-only", "horizontal", "square"]
|
|
7507
|
+
},
|
|
7508
|
+
{
|
|
7509
|
+
id: asHeaderLayoutId("floating"),
|
|
7510
|
+
label: "Floating",
|
|
7511
|
+
description: "Detached header chrome that sits over the opening section.",
|
|
7512
|
+
structure: "floating-shell",
|
|
7513
|
+
variant: "floating",
|
|
7514
|
+
defaultPositioning: "sticky",
|
|
7515
|
+
shrinkOnScroll: true,
|
|
7516
|
+
maxRecommendedNavItems: 5,
|
|
7517
|
+
allowedLogoShapes: ["none", "text-only", "horizontal"]
|
|
7518
|
+
}
|
|
7519
|
+
];
|
|
7520
|
+
function supportedLayouts(ids) {
|
|
7521
|
+
return ids.map(asHeaderLayoutId);
|
|
7522
|
+
}
|
|
7523
|
+
var headerStyleCatalog = [
|
|
7524
|
+
{
|
|
7525
|
+
id: asHeaderStyleId("minimal"),
|
|
7526
|
+
label: "Minimal",
|
|
7527
|
+
description: "Quiet surface with simple color-change navigation.",
|
|
7528
|
+
supportedLayoutIds: supportedLayouts(["classic", "centered"]),
|
|
7529
|
+
navInteraction: "color-change",
|
|
7530
|
+
surface: "neutral",
|
|
7531
|
+
defaultDepth: "none",
|
|
7532
|
+
navTypography: "plain",
|
|
7533
|
+
moods: ["calm", "professional", "editorial"]
|
|
7534
|
+
},
|
|
7535
|
+
{
|
|
7536
|
+
id: asHeaderStyleId("fine-line"),
|
|
7537
|
+
label: "Fine Line",
|
|
7538
|
+
description: "Light surface with a crisp lower rule and underline hover.",
|
|
7539
|
+
supportedLayoutIds: supportedLayouts(["classic", "centered"]),
|
|
7540
|
+
navInteraction: "underline-grow",
|
|
7541
|
+
surface: "bordered",
|
|
7542
|
+
defaultDepth: "line",
|
|
7543
|
+
navTypography: "plain",
|
|
7544
|
+
moods: ["calm", "professional", "editorial"]
|
|
7545
|
+
},
|
|
7546
|
+
{
|
|
7547
|
+
id: asHeaderStyleId("soft-bar"),
|
|
7548
|
+
label: "Soft Bar",
|
|
7549
|
+
description: "Soft tinted surface with gentle pill hover states.",
|
|
7550
|
+
supportedLayoutIds: supportedLayouts(["classic", "centered"]),
|
|
7551
|
+
navInteraction: "pill-background",
|
|
7552
|
+
surface: "soft",
|
|
7553
|
+
defaultDepth: "line",
|
|
7554
|
+
navTypography: "plain",
|
|
7555
|
+
moods: ["calm", "professional"]
|
|
7556
|
+
},
|
|
7557
|
+
{
|
|
7558
|
+
id: asHeaderStyleId("pill-nav"),
|
|
7559
|
+
label: "Pill Nav",
|
|
7560
|
+
description: "A calm pill navigation rail over a neutral header.",
|
|
7561
|
+
supportedLayoutIds: supportedLayouts(["classic", "centered"]),
|
|
7562
|
+
navInteraction: "pill-background",
|
|
7563
|
+
surface: "soft",
|
|
7564
|
+
defaultDepth: "none",
|
|
7565
|
+
navTypography: "plain",
|
|
7566
|
+
moods: ["calm"]
|
|
7567
|
+
},
|
|
7568
|
+
{
|
|
7569
|
+
id: asHeaderStyleId("brand-bar"),
|
|
7570
|
+
label: "Brand Bar",
|
|
7571
|
+
description: "Solid brand surface with high-contrast navigation.",
|
|
7572
|
+
supportedLayoutIds: supportedLayouts(["classic", "centered"]),
|
|
7573
|
+
navInteraction: "color-change",
|
|
7574
|
+
surface: "brand-solid",
|
|
7575
|
+
defaultDepth: "none",
|
|
7576
|
+
navTypography: "brand-caps",
|
|
7577
|
+
moods: ["professional", "expressive", "utility"]
|
|
7578
|
+
},
|
|
7579
|
+
{
|
|
7580
|
+
id: asHeaderStyleId("brand-underline"),
|
|
7581
|
+
label: "Brand Underline",
|
|
7582
|
+
description: "Brand surface with underline-grow navigation.",
|
|
7583
|
+
supportedLayoutIds: supportedLayouts(["classic"]),
|
|
7584
|
+
navInteraction: "underline-grow",
|
|
7585
|
+
surface: "brand-solid",
|
|
7586
|
+
defaultDepth: "none",
|
|
7587
|
+
navTypography: "brand-caps",
|
|
7588
|
+
moods: ["expressive"]
|
|
7589
|
+
},
|
|
7590
|
+
{
|
|
7591
|
+
id: asHeaderStyleId("brand-pill"),
|
|
7592
|
+
label: "Brand Pill",
|
|
7593
|
+
description: "Solid brand surface with rounded active and hover states.",
|
|
7594
|
+
supportedLayoutIds: supportedLayouts(["classic", "centered", "floating"]),
|
|
7595
|
+
navInteraction: "pill-background",
|
|
7596
|
+
surface: "brand-solid",
|
|
7597
|
+
defaultDepth: "none",
|
|
7598
|
+
navTypography: "brand-caps",
|
|
7599
|
+
moods: ["expressive"]
|
|
7600
|
+
},
|
|
7601
|
+
{
|
|
7602
|
+
id: asHeaderStyleId("serif-line"),
|
|
7603
|
+
label: "Serif Line",
|
|
7604
|
+
description: "Typographic logo treatment with understated underline navigation.",
|
|
7605
|
+
supportedLayoutIds: supportedLayouts(["classic", "centered"]),
|
|
7606
|
+
navInteraction: "underline-grow",
|
|
7607
|
+
surface: "bordered",
|
|
7608
|
+
defaultDepth: "line",
|
|
7609
|
+
navTypography: "heading",
|
|
7610
|
+
moods: ["editorial", "calm"]
|
|
7611
|
+
},
|
|
7612
|
+
{
|
|
7613
|
+
id: asHeaderStyleId("flat-tabs"),
|
|
7614
|
+
label: "Flat Tabs",
|
|
7615
|
+
description: "Flat block hover and active states with a Swiss utility feel.",
|
|
7616
|
+
supportedLayoutIds: supportedLayouts(["classic", "centered"]),
|
|
7617
|
+
navInteraction: "flat-block",
|
|
7618
|
+
surface: "bordered",
|
|
7619
|
+
defaultDepth: "shadow",
|
|
7620
|
+
navTypography: "quiet-caps",
|
|
7621
|
+
moods: ["professional", "utility", "expressive"]
|
|
7622
|
+
},
|
|
7623
|
+
{
|
|
7624
|
+
id: asHeaderStyleId("glass"),
|
|
7625
|
+
label: "Glass",
|
|
7626
|
+
description: "Translucent chrome with frosted navigation backing.",
|
|
7627
|
+
supportedLayoutIds: supportedLayouts(["floating"]),
|
|
7628
|
+
navInteraction: "glass-backed",
|
|
7629
|
+
surface: "floating",
|
|
7630
|
+
defaultDepth: "shadow",
|
|
7631
|
+
navTypography: "plain",
|
|
7632
|
+
moods: ["expressive", "calm"]
|
|
7633
|
+
},
|
|
7634
|
+
{
|
|
7635
|
+
id: asHeaderStyleId("minimal-surface"),
|
|
7636
|
+
label: "Clear Split",
|
|
7637
|
+
description: "Floating logo with transparent navigation and no shared shell.",
|
|
7638
|
+
supportedLayoutIds: supportedLayouts(["floating"]),
|
|
7639
|
+
navInteraction: "color-change",
|
|
7640
|
+
surface: "floating",
|
|
7641
|
+
defaultDepth: "none",
|
|
7642
|
+
navTypography: "plain",
|
|
7643
|
+
moods: ["editorial", "calm"]
|
|
7644
|
+
},
|
|
7645
|
+
{
|
|
7646
|
+
id: asHeaderStyleId("soft-shell"),
|
|
7647
|
+
label: "Soft Shell",
|
|
7648
|
+
description: "Floating rounded shell with soft pill navigation states.",
|
|
7649
|
+
supportedLayoutIds: supportedLayouts(["floating"]),
|
|
7650
|
+
navInteraction: "pill-background",
|
|
7651
|
+
surface: "floating",
|
|
7652
|
+
defaultDepth: "shadow",
|
|
7653
|
+
navTypography: "plain",
|
|
7654
|
+
moods: ["calm", "professional"]
|
|
7655
|
+
},
|
|
7656
|
+
{
|
|
7657
|
+
id: asHeaderStyleId("split-glass"),
|
|
7658
|
+
label: "Split Glass",
|
|
7659
|
+
description: "Logo floats independently while the navigation sits in a glass rail.",
|
|
7660
|
+
supportedLayoutIds: supportedLayouts(["floating"]),
|
|
7661
|
+
navInteraction: "glass-backed",
|
|
7662
|
+
surface: "floating",
|
|
7663
|
+
defaultDepth: "shadow",
|
|
7664
|
+
navTypography: "quiet-caps",
|
|
7665
|
+
moods: ["expressive"]
|
|
7666
|
+
},
|
|
7667
|
+
{
|
|
7668
|
+
id: asHeaderStyleId("split-pill"),
|
|
7669
|
+
label: "Split Pill",
|
|
7670
|
+
description: "Logo floats independently with a soft pill-backed navigation rail.",
|
|
7671
|
+
supportedLayoutIds: supportedLayouts(["floating"]),
|
|
7672
|
+
navInteraction: "pill-background",
|
|
7673
|
+
surface: "floating",
|
|
7674
|
+
defaultDepth: "shadow",
|
|
7675
|
+
navTypography: "heading",
|
|
7676
|
+
moods: ["calm", "editorial"]
|
|
7677
|
+
}
|
|
7678
|
+
];
|
|
7679
|
+
var headerLayoutsById = new Map(
|
|
7680
|
+
headerLayoutCatalog.map((layout) => [layout.id, layout])
|
|
7681
|
+
);
|
|
7682
|
+
var headerStylesById = new Map(
|
|
7683
|
+
headerStyleCatalog.map((style) => [style.id, style])
|
|
7684
|
+
);
|
|
7685
|
+
var headerStyleCompatibilityOrder = /* @__PURE__ */ new Map([
|
|
7686
|
+
[
|
|
7687
|
+
asHeaderLayoutId("classic"),
|
|
7688
|
+
headerStyleRepairChain([
|
|
7689
|
+
"minimal",
|
|
7690
|
+
"fine-line",
|
|
7691
|
+
"soft-bar",
|
|
7692
|
+
"pill-nav",
|
|
7693
|
+
"brand-bar",
|
|
7694
|
+
"brand-underline",
|
|
7695
|
+
"brand-pill",
|
|
7696
|
+
"serif-line",
|
|
7697
|
+
"flat-tabs"
|
|
7698
|
+
])
|
|
7699
|
+
],
|
|
7700
|
+
[
|
|
7701
|
+
asHeaderLayoutId("centered"),
|
|
7702
|
+
headerStyleRepairChain([
|
|
7703
|
+
"minimal",
|
|
7704
|
+
"fine-line",
|
|
7705
|
+
"soft-bar",
|
|
7706
|
+
"pill-nav",
|
|
7707
|
+
"brand-bar",
|
|
7708
|
+
"brand-pill",
|
|
7709
|
+
"serif-line",
|
|
7710
|
+
"flat-tabs"
|
|
7711
|
+
])
|
|
7712
|
+
],
|
|
7713
|
+
[
|
|
7714
|
+
asHeaderLayoutId("floating"),
|
|
7715
|
+
headerStyleRepairChain([
|
|
7716
|
+
"glass",
|
|
7717
|
+
"minimal-surface",
|
|
7718
|
+
"split-glass",
|
|
7719
|
+
"split-pill",
|
|
7720
|
+
"soft-shell",
|
|
7721
|
+
"brand-pill"
|
|
7722
|
+
])
|
|
7723
|
+
]
|
|
7724
|
+
]);
|
|
7725
|
+
function headerStyleRepairChain(values) {
|
|
7726
|
+
return values.map(asHeaderStyleId);
|
|
7727
|
+
}
|
|
7728
|
+
var headerStyleRepairOrder = /* @__PURE__ */ new Map(
|
|
7729
|
+
[
|
|
7730
|
+
[
|
|
7731
|
+
asHeaderStyleId("brand-bar"),
|
|
7732
|
+
headerStyleRepairChain(["brand-bar", "brand-pill", "minimal"])
|
|
7733
|
+
],
|
|
7734
|
+
[
|
|
7735
|
+
asHeaderStyleId("brand-underline"),
|
|
7736
|
+
headerStyleRepairChain(["serif-line", "fine-line", "minimal"])
|
|
7737
|
+
],
|
|
7738
|
+
[
|
|
7739
|
+
asHeaderStyleId("brand-pill"),
|
|
7740
|
+
headerStyleRepairChain(["brand-pill", "brand-bar", "minimal"])
|
|
7741
|
+
],
|
|
7742
|
+
[
|
|
7743
|
+
asHeaderStyleId("pill-nav"),
|
|
7744
|
+
headerStyleRepairChain(["pill-nav", "soft-bar", "minimal"])
|
|
7745
|
+
],
|
|
7746
|
+
[
|
|
7747
|
+
asHeaderStyleId("flat-tabs"),
|
|
7748
|
+
headerStyleRepairChain(["flat-tabs", "pill-nav", "minimal"])
|
|
7749
|
+
],
|
|
7750
|
+
[
|
|
7751
|
+
asHeaderStyleId("serif-line"),
|
|
7752
|
+
headerStyleRepairChain(["serif-line", "fine-line", "minimal"])
|
|
7753
|
+
],
|
|
7754
|
+
[
|
|
7755
|
+
asHeaderStyleId("glass"),
|
|
7756
|
+
headerStyleRepairChain([
|
|
7757
|
+
"glass",
|
|
7758
|
+
"soft-shell",
|
|
7759
|
+
"fine-line",
|
|
7760
|
+
"minimal-surface",
|
|
7761
|
+
"minimal"
|
|
7762
|
+
])
|
|
7763
|
+
],
|
|
7764
|
+
[
|
|
7765
|
+
asHeaderStyleId("soft-shell"),
|
|
7766
|
+
headerStyleRepairChain(["soft-shell", "soft-bar", "minimal"])
|
|
7767
|
+
],
|
|
7768
|
+
[
|
|
7769
|
+
asHeaderStyleId("minimal-surface"),
|
|
7770
|
+
headerStyleRepairChain(["minimal-surface", "minimal"])
|
|
7771
|
+
],
|
|
7772
|
+
[
|
|
7773
|
+
asHeaderStyleId("split-glass"),
|
|
7774
|
+
headerStyleRepairChain(["split-glass", "glass", "minimal-surface"])
|
|
7775
|
+
],
|
|
7776
|
+
[
|
|
7777
|
+
asHeaderStyleId("split-pill"),
|
|
7778
|
+
headerStyleRepairChain(["split-pill", "soft-shell", "brand-pill"])
|
|
7779
|
+
],
|
|
7780
|
+
[
|
|
7781
|
+
asHeaderStyleId("fine-line"),
|
|
7782
|
+
headerStyleRepairChain(["fine-line", "minimal"])
|
|
7783
|
+
],
|
|
7784
|
+
[
|
|
7785
|
+
asHeaderStyleId("soft-bar"),
|
|
7786
|
+
headerStyleRepairChain(["soft-bar", "minimal"])
|
|
7787
|
+
],
|
|
7788
|
+
[asHeaderStyleId("minimal"), headerStyleRepairChain(["minimal"])]
|
|
7789
|
+
]
|
|
7790
|
+
);
|
|
7791
|
+
var legacyHeaderLookAliases = [
|
|
7792
|
+
{
|
|
7793
|
+
lookId: asHeaderLookId("clean-base"),
|
|
7794
|
+
selection: {
|
|
7795
|
+
layoutId: asHeaderLayoutId("classic"),
|
|
7796
|
+
styleId: asHeaderStyleId("minimal")
|
|
7797
|
+
}
|
|
7798
|
+
},
|
|
7799
|
+
{
|
|
7800
|
+
lookId: asHeaderLookId("brand-solid"),
|
|
7801
|
+
selection: {
|
|
7802
|
+
layoutId: asHeaderLayoutId("classic"),
|
|
7803
|
+
styleId: asHeaderStyleId("brand-bar")
|
|
7804
|
+
}
|
|
7805
|
+
},
|
|
7806
|
+
{
|
|
7807
|
+
lookId: asHeaderLookId("serif-line"),
|
|
7808
|
+
selection: {
|
|
7809
|
+
layoutId: asHeaderLayoutId("centered"),
|
|
7810
|
+
styleId: asHeaderStyleId("serif-line")
|
|
7811
|
+
}
|
|
7812
|
+
},
|
|
7813
|
+
{
|
|
7814
|
+
lookId: asHeaderLookId("centered-calm"),
|
|
7815
|
+
selection: {
|
|
7816
|
+
layoutId: asHeaderLayoutId("centered"),
|
|
7817
|
+
styleId: asHeaderStyleId("minimal")
|
|
7818
|
+
}
|
|
7819
|
+
},
|
|
7820
|
+
{
|
|
7821
|
+
lookId: asHeaderLookId("practical-utility"),
|
|
7822
|
+
selection: {
|
|
7823
|
+
layoutId: asHeaderLayoutId("classic"),
|
|
7824
|
+
styleId: asHeaderStyleId("flat-tabs")
|
|
7825
|
+
}
|
|
7826
|
+
},
|
|
7827
|
+
{
|
|
7828
|
+
lookId: asHeaderLookId("minimal-transparent"),
|
|
7829
|
+
selection: {
|
|
7830
|
+
layoutId: asHeaderLayoutId("classic"),
|
|
7831
|
+
styleId: asHeaderStyleId("minimal")
|
|
7832
|
+
}
|
|
7833
|
+
},
|
|
7834
|
+
{
|
|
7835
|
+
lookId: asHeaderLookId("transparent-overlay"),
|
|
7836
|
+
selection: {
|
|
7837
|
+
layoutId: asHeaderLayoutId("floating"),
|
|
7838
|
+
styleId: asHeaderStyleId("glass")
|
|
7839
|
+
}
|
|
7840
|
+
},
|
|
7841
|
+
{
|
|
7842
|
+
lookId: asHeaderLookId("floating-glass"),
|
|
7843
|
+
selection: {
|
|
7844
|
+
layoutId: asHeaderLayoutId("floating"),
|
|
7845
|
+
styleId: asHeaderStyleId("glass")
|
|
7846
|
+
}
|
|
7847
|
+
}
|
|
7848
|
+
];
|
|
7849
|
+
var legacyHeaderLookAliasesById = new Map(legacyHeaderLookAliases.map((alias) => [alias.lookId, alias]));
|
|
7850
|
+
function getHeaderStyle(id) {
|
|
7851
|
+
return headerStylesById.get(id) ?? null;
|
|
7852
|
+
}
|
|
7853
|
+
function isHeaderStyleCompatibleWithLayout(style, layoutId) {
|
|
7854
|
+
return style.supportedLayoutIds.includes(layoutId);
|
|
7855
|
+
}
|
|
7856
|
+
function getHeaderStyleOrThrow(id) {
|
|
7857
|
+
const style = getHeaderStyle(id);
|
|
7858
|
+
if (!style) {
|
|
7859
|
+
throw new Error(`Unknown Theme V2 header style: ${id}`);
|
|
7860
|
+
}
|
|
7861
|
+
return style;
|
|
7862
|
+
}
|
|
7863
|
+
function resolveLegacyHeaderLookAlias(lookId) {
|
|
7864
|
+
return legacyHeaderLookAliasesById.get(lookId)?.selection ?? null;
|
|
7865
|
+
}
|
|
7866
|
+
function getCompatibleHeaderStyleIds(layoutId) {
|
|
7867
|
+
return (headerStyleCompatibilityOrder.get(layoutId) ?? []).filter(
|
|
7868
|
+
(styleId) => {
|
|
7869
|
+
const style = getHeaderStyleOrThrow(styleId);
|
|
7870
|
+
return isHeaderStyleCompatibleWithLayout(style, layoutId);
|
|
7871
|
+
}
|
|
7872
|
+
);
|
|
7873
|
+
}
|
|
7874
|
+
function themedHeaderShadow(theme) {
|
|
7875
|
+
switch (theme.shadow.elevation) {
|
|
7876
|
+
case "none":
|
|
7877
|
+
return void 0;
|
|
7878
|
+
case "low":
|
|
7879
|
+
return { elevation: "sm" };
|
|
7880
|
+
case "medium":
|
|
7881
|
+
return { elevation: "md" };
|
|
7882
|
+
case "high":
|
|
7883
|
+
return { elevation: "lg" };
|
|
7884
|
+
default:
|
|
7885
|
+
return assertNever3(
|
|
7886
|
+
theme.shadow.elevation,
|
|
7887
|
+
"Unhandled theme shadow elevation"
|
|
7888
|
+
);
|
|
7889
|
+
}
|
|
7890
|
+
}
|
|
7891
|
+
function solidBrandHeader(theme) {
|
|
7892
|
+
const ctaVariant = resolveHeaderCtaVariant(theme, "inverted");
|
|
7893
|
+
return {
|
|
7894
|
+
...baseHeader(theme),
|
|
7895
|
+
variant: "classic",
|
|
7896
|
+
positioning: "sticky",
|
|
7897
|
+
shrinkOnScroll: true,
|
|
7898
|
+
background: {
|
|
7899
|
+
type: "color",
|
|
7900
|
+
color: "primary"
|
|
7901
|
+
},
|
|
7902
|
+
textColor: "primaryForeground",
|
|
7903
|
+
navColor: "primaryForeground",
|
|
7904
|
+
navStyle: "underline-grow",
|
|
7905
|
+
navWeight: "bold",
|
|
7906
|
+
navLinkStyle: {
|
|
7907
|
+
typography: "body",
|
|
7908
|
+
fontWeight: "bold",
|
|
7909
|
+
textTransform: "uppercase",
|
|
7910
|
+
italic: false,
|
|
7911
|
+
colorToken: "primaryForeground",
|
|
7912
|
+
hoverColorToken: "secondary",
|
|
7913
|
+
textSize: "sm",
|
|
7914
|
+
letterSpacing: "wider",
|
|
7915
|
+
padding: "compact",
|
|
7916
|
+
paddingX: "compact",
|
|
7917
|
+
borderRadius: "none",
|
|
7918
|
+
effects: {
|
|
7919
|
+
hover: [
|
|
7920
|
+
{
|
|
7921
|
+
effectId: "text-color-change",
|
|
7922
|
+
options: { hoverColorToken: "secondary" }
|
|
7923
|
+
},
|
|
7924
|
+
{
|
|
7925
|
+
effectId: "nav-underline",
|
|
7926
|
+
options: { style: "grow", colorToken: "secondary" }
|
|
7927
|
+
}
|
|
7928
|
+
]
|
|
7929
|
+
}
|
|
7930
|
+
},
|
|
7931
|
+
dropdownStyle: {
|
|
7932
|
+
background: "primary-700",
|
|
7933
|
+
textColor: "primaryForeground",
|
|
7934
|
+
borderColor: null,
|
|
7935
|
+
shadow: "md",
|
|
7936
|
+
borderRadius: "md",
|
|
7937
|
+
hoverBackground: "primary-900",
|
|
7938
|
+
hoverTextColor: "secondary",
|
|
7939
|
+
textTransform: "uppercase",
|
|
7940
|
+
letterSpacing: "wider",
|
|
7941
|
+
fontWeight: "bold",
|
|
7942
|
+
textSize: "sm"
|
|
7943
|
+
},
|
|
7944
|
+
border: {
|
|
7945
|
+
style: "solid",
|
|
7946
|
+
width: "none",
|
|
7947
|
+
position: "none"
|
|
7948
|
+
},
|
|
7949
|
+
logoText: {
|
|
7950
|
+
hideOnShrink: true,
|
|
7951
|
+
mobileMaxWidth: "sm",
|
|
7952
|
+
mobileWrapLines: 2
|
|
7953
|
+
},
|
|
7954
|
+
ctaGap: "compact",
|
|
7955
|
+
ctaTreatment: "inverted",
|
|
7956
|
+
...ctaVariant ? { ctaVariant } : {}
|
|
7957
|
+
};
|
|
7958
|
+
}
|
|
7959
|
+
function cleanBaseHeader(theme) {
|
|
7960
|
+
return {
|
|
7961
|
+
...baseHeader(theme),
|
|
7962
|
+
variant: "classic",
|
|
7963
|
+
positioning: "sticky",
|
|
7964
|
+
shrinkOnScroll: false,
|
|
7965
|
+
background: {
|
|
7966
|
+
type: "color",
|
|
7967
|
+
color: "surface"
|
|
7968
|
+
},
|
|
7969
|
+
textColor: "text",
|
|
7970
|
+
navColor: "text",
|
|
7971
|
+
navStyle: "minimal",
|
|
7972
|
+
navWeight: "medium",
|
|
7973
|
+
border: {
|
|
7974
|
+
style: "solid",
|
|
7975
|
+
width: "thin",
|
|
7976
|
+
position: "bottom",
|
|
7977
|
+
colorToken: "border"
|
|
7978
|
+
},
|
|
7979
|
+
ctaTreatment: "default",
|
|
7980
|
+
ctaGap: "default"
|
|
7981
|
+
};
|
|
7982
|
+
}
|
|
7983
|
+
function serifLineHeader(theme) {
|
|
7984
|
+
return {
|
|
7985
|
+
...baseHeader(theme),
|
|
7986
|
+
variant: "centered",
|
|
7987
|
+
positioning: "sticky",
|
|
7988
|
+
shrinkOnScroll: false,
|
|
7989
|
+
background: {
|
|
7990
|
+
type: "color",
|
|
7991
|
+
color: "background"
|
|
7992
|
+
},
|
|
7993
|
+
textColor: "text",
|
|
7994
|
+
navColor: "text",
|
|
7995
|
+
navStyle: "underline-grow",
|
|
7996
|
+
navWeight: "medium",
|
|
7997
|
+
logo: {
|
|
7998
|
+
fontFamily: "heading",
|
|
7999
|
+
letterSpacing: "wide",
|
|
8000
|
+
gradient: false
|
|
8001
|
+
},
|
|
8002
|
+
ctaTreatment: "outline",
|
|
8003
|
+
ctaVariant: resolveHeaderCtaVariant(theme, "outline"),
|
|
8004
|
+
ctaGap: "relaxed"
|
|
8005
|
+
};
|
|
8006
|
+
}
|
|
8007
|
+
function centeredCalmHeader(theme) {
|
|
8008
|
+
return {
|
|
8009
|
+
...baseHeader(theme),
|
|
8010
|
+
variant: "centered",
|
|
8011
|
+
positioning: "static",
|
|
8012
|
+
shrinkOnScroll: false,
|
|
8013
|
+
background: {
|
|
8014
|
+
type: "color",
|
|
8015
|
+
color: "surface"
|
|
8016
|
+
},
|
|
8017
|
+
textColor: "text",
|
|
8018
|
+
navColor: "text",
|
|
8019
|
+
navStyle: "minimal",
|
|
8020
|
+
navWeight: "medium",
|
|
8021
|
+
ctaTreatment: "ghost",
|
|
8022
|
+
ctaVariant: resolveHeaderCtaVariant(theme, "ghost"),
|
|
8023
|
+
ctaGap: "none"
|
|
8024
|
+
};
|
|
8025
|
+
}
|
|
8026
|
+
function practicalUtilityHeader(theme) {
|
|
8027
|
+
return {
|
|
8028
|
+
...baseHeader(theme),
|
|
8029
|
+
variant: "classic",
|
|
8030
|
+
positioning: "sticky",
|
|
8031
|
+
shrinkOnScroll: true,
|
|
8032
|
+
background: {
|
|
8033
|
+
type: "color",
|
|
8034
|
+
color: "surface"
|
|
8035
|
+
},
|
|
8036
|
+
textColor: "text",
|
|
8037
|
+
navColor: "text",
|
|
8038
|
+
navStyle: "solid",
|
|
8039
|
+
navWeight: "semibold",
|
|
8040
|
+
shadow: themedHeaderShadow(theme),
|
|
8041
|
+
border: {
|
|
8042
|
+
style: "solid",
|
|
8043
|
+
width: "thin",
|
|
8044
|
+
position: "bottom",
|
|
8045
|
+
colorToken: "border"
|
|
8046
|
+
},
|
|
8047
|
+
ctaTreatment: "primary",
|
|
8048
|
+
ctaVariant: resolveHeaderCtaVariant(theme, "primary"),
|
|
8049
|
+
ctaGap: "compact",
|
|
8050
|
+
logoText: {
|
|
8051
|
+
mobileMaxWidth: "sm",
|
|
8052
|
+
mobileWrapLines: 1,
|
|
8053
|
+
hideOnShrink: false
|
|
8054
|
+
}
|
|
8055
|
+
};
|
|
8056
|
+
}
|
|
8057
|
+
function minimalTransparentHeader(theme) {
|
|
8058
|
+
return {
|
|
8059
|
+
...baseHeader(theme),
|
|
8060
|
+
variant: "classic",
|
|
8061
|
+
positioning: "static",
|
|
8062
|
+
shrinkOnScroll: false,
|
|
8063
|
+
background: {
|
|
8064
|
+
type: "color",
|
|
8065
|
+
color: "transparent"
|
|
8066
|
+
},
|
|
8067
|
+
textColor: "text",
|
|
8068
|
+
navColor: "text",
|
|
8069
|
+
navStyle: "underline",
|
|
8070
|
+
navWeight: "medium",
|
|
8071
|
+
border: {
|
|
8072
|
+
style: "solid",
|
|
8073
|
+
width: "none",
|
|
8074
|
+
position: "none"
|
|
8075
|
+
},
|
|
8076
|
+
ctaTreatment: "outline",
|
|
8077
|
+
ctaVariant: resolveHeaderCtaVariant(theme, "outline"),
|
|
8078
|
+
ctaGap: "default"
|
|
8079
|
+
};
|
|
8080
|
+
}
|
|
8081
|
+
function transparentOverlayHeader(theme) {
|
|
8082
|
+
return {
|
|
8083
|
+
...baseHeader(theme),
|
|
8084
|
+
variant: "transparent",
|
|
8085
|
+
positioning: "fixed",
|
|
8086
|
+
shrinkOnScroll: true,
|
|
8087
|
+
background: {
|
|
8088
|
+
type: "color",
|
|
8089
|
+
color: "transparent"
|
|
8090
|
+
},
|
|
8091
|
+
textColor: "background",
|
|
8092
|
+
navColor: "background",
|
|
8093
|
+
navStyle: "frosted",
|
|
8094
|
+
navWeight: "semibold",
|
|
8095
|
+
border: {
|
|
8096
|
+
style: "solid",
|
|
8097
|
+
width: "none",
|
|
8098
|
+
position: "none"
|
|
8099
|
+
},
|
|
8100
|
+
ctaTreatment: "inverted",
|
|
8101
|
+
ctaVariant: resolveHeaderCtaVariant(theme, "inverted"),
|
|
8102
|
+
ctaGap: "compact"
|
|
8103
|
+
};
|
|
8104
|
+
}
|
|
8105
|
+
function floatingGlassHeader(theme) {
|
|
8106
|
+
return {
|
|
8107
|
+
...transparentOverlayHeader(theme),
|
|
8108
|
+
variant: "floating",
|
|
8109
|
+
positioning: "sticky",
|
|
8110
|
+
navStyle: "frosted",
|
|
8111
|
+
navContainer: {
|
|
8112
|
+
type: "glass",
|
|
8113
|
+
tint: "text",
|
|
8114
|
+
opacity: 0.16
|
|
8115
|
+
},
|
|
8116
|
+
container: {
|
|
8117
|
+
rounded: "2xl",
|
|
8118
|
+
border: true,
|
|
8119
|
+
shadow: true,
|
|
8120
|
+
padding: "sm",
|
|
8121
|
+
tint: "background",
|
|
8122
|
+
opacity: 0.12
|
|
8123
|
+
}
|
|
8124
|
+
};
|
|
8125
|
+
}
|
|
8126
|
+
var headerLookCatalog = [
|
|
8127
|
+
{
|
|
8128
|
+
id: asHeaderLookId("clean-base"),
|
|
8129
|
+
label: "Clean base",
|
|
8130
|
+
visualTreatment: "solid-neutral",
|
|
8131
|
+
layoutBehavior: "sticky",
|
|
8132
|
+
configuration: {
|
|
8133
|
+
structure: "inline-classic",
|
|
8134
|
+
treatment: "solid-neutral",
|
|
8135
|
+
behavior: "sticky"
|
|
8136
|
+
},
|
|
8137
|
+
openingRequirement: "none",
|
|
8138
|
+
compile: cleanBaseHeader
|
|
8139
|
+
},
|
|
8140
|
+
{
|
|
8141
|
+
id: asHeaderLookId("brand-solid"),
|
|
8142
|
+
label: "Brand solid",
|
|
8143
|
+
visualTreatment: "solid-brand",
|
|
8144
|
+
layoutBehavior: "sticky-shrink",
|
|
8145
|
+
configuration: {
|
|
8146
|
+
structure: "inline-classic",
|
|
8147
|
+
treatment: "solid-brand",
|
|
8148
|
+
behavior: "sticky-shrink"
|
|
8149
|
+
},
|
|
8150
|
+
openingRequirement: "none",
|
|
8151
|
+
compile: solidBrandHeader
|
|
8152
|
+
},
|
|
8153
|
+
{
|
|
8154
|
+
id: asHeaderLookId("serif-line"),
|
|
8155
|
+
label: "Serif line",
|
|
8156
|
+
visualTreatment: "light-serif",
|
|
8157
|
+
layoutBehavior: "sticky",
|
|
8158
|
+
configuration: {
|
|
8159
|
+
structure: "centered-stack",
|
|
8160
|
+
treatment: "light-serif",
|
|
8161
|
+
behavior: "sticky"
|
|
8162
|
+
},
|
|
8163
|
+
openingRequirement: "none",
|
|
8164
|
+
maxRecommendedNavItems: 6,
|
|
8165
|
+
compile: serifLineHeader
|
|
8166
|
+
},
|
|
8167
|
+
{
|
|
8168
|
+
id: asHeaderLookId("centered-calm"),
|
|
8169
|
+
label: "Centered calm",
|
|
8170
|
+
visualTreatment: "light-serif",
|
|
8171
|
+
layoutBehavior: "normal-flow",
|
|
8172
|
+
configuration: {
|
|
8173
|
+
structure: "centered-stack",
|
|
8174
|
+
treatment: "light-serif",
|
|
8175
|
+
behavior: "normal-flow"
|
|
8176
|
+
},
|
|
8177
|
+
openingRequirement: "none",
|
|
8178
|
+
maxRecommendedNavItems: 5,
|
|
8179
|
+
allowedLogoShapes: ["none", "text-only", "horizontal", "square"],
|
|
8180
|
+
compile: centeredCalmHeader
|
|
8181
|
+
},
|
|
8182
|
+
{
|
|
8183
|
+
id: asHeaderLookId("practical-utility"),
|
|
8184
|
+
label: "Practical utility",
|
|
8185
|
+
visualTreatment: "solid-neutral",
|
|
8186
|
+
layoutBehavior: "sticky-shrink",
|
|
8187
|
+
configuration: {
|
|
8188
|
+
structure: "inline-classic",
|
|
8189
|
+
treatment: "solid-neutral",
|
|
8190
|
+
behavior: "sticky-shrink"
|
|
8191
|
+
},
|
|
8192
|
+
openingRequirement: "none",
|
|
8193
|
+
requiresProminentCta: true,
|
|
8194
|
+
compile: practicalUtilityHeader
|
|
8195
|
+
},
|
|
8196
|
+
{
|
|
8197
|
+
id: asHeaderLookId("minimal-transparent"),
|
|
8198
|
+
label: "Minimal transparent",
|
|
8199
|
+
visualTreatment: "minimal-transparent",
|
|
8200
|
+
layoutBehavior: "normal-flow",
|
|
8201
|
+
configuration: {
|
|
8202
|
+
structure: "inline-classic",
|
|
8203
|
+
treatment: "minimal-transparent",
|
|
8204
|
+
behavior: "normal-flow"
|
|
8205
|
+
},
|
|
8206
|
+
openingRequirement: "reserved-space-ok",
|
|
8207
|
+
compile: minimalTransparentHeader
|
|
8208
|
+
},
|
|
8209
|
+
{
|
|
8210
|
+
id: asHeaderLookId("transparent-overlay"),
|
|
8211
|
+
label: "Transparent overlay",
|
|
8212
|
+
visualTreatment: "transparent-overlay",
|
|
8213
|
+
layoutBehavior: "fixed-overlay",
|
|
8214
|
+
configuration: {
|
|
8215
|
+
structure: "inline-classic",
|
|
8216
|
+
treatment: "transparent-overlay",
|
|
8217
|
+
behavior: "fixed-overlay"
|
|
8218
|
+
},
|
|
8219
|
+
openingRequirement: "requires-image-hero-with-contrast-overlay",
|
|
8220
|
+
maxRecommendedNavItems: 5,
|
|
8221
|
+
allowedLogoShapes: ["none", "text-only", "horizontal"],
|
|
8222
|
+
compile: transparentOverlayHeader
|
|
8223
|
+
},
|
|
8224
|
+
{
|
|
8225
|
+
id: asHeaderLookId("floating-glass"),
|
|
8226
|
+
label: "Floating glass",
|
|
8227
|
+
visualTreatment: "floating-glass",
|
|
8228
|
+
layoutBehavior: "fixed-floating",
|
|
8229
|
+
configuration: {
|
|
8230
|
+
structure: "floating-shell",
|
|
8231
|
+
treatment: "floating-glass",
|
|
8232
|
+
behavior: "fixed-floating"
|
|
8233
|
+
},
|
|
8234
|
+
openingRequirement: "requires-image-hero-with-contrast-overlay",
|
|
8235
|
+
maxRecommendedNavItems: 5,
|
|
8236
|
+
allowedLogoShapes: ["none", "text-only", "horizontal"],
|
|
8237
|
+
compile: floatingGlassHeader
|
|
8238
|
+
}
|
|
8239
|
+
];
|
|
8240
|
+
var guaranteedFallbackHeaderLookId = asHeaderLookId("clean-base");
|
|
8241
|
+
var guaranteedFallbackHeaderLayoutId = asHeaderLayoutId("classic");
|
|
8242
|
+
var guaranteedFallbackHeaderStyleId = asHeaderStyleId("minimal");
|
|
8243
|
+
var allowedHeaderConfigurationKeys = new Set(
|
|
8244
|
+
headerLookCatalog.map((look) => headerConfigurationKey(look.configuration))
|
|
8245
|
+
);
|
|
8246
|
+
var headerLooksById = new Map(
|
|
8247
|
+
headerLookCatalog.map((look) => [look.id, look])
|
|
8248
|
+
);
|
|
8249
|
+
function headerConfigurationKey(configuration) {
|
|
8250
|
+
return `${configuration.structure}:${configuration.treatment}:${configuration.behavior}`;
|
|
8251
|
+
}
|
|
8252
|
+
|
|
8253
|
+
// ../theme-core/src/site-styles/footerLooks.ts
|
|
8254
|
+
function asFooterLookId(value) {
|
|
8255
|
+
return value;
|
|
8256
|
+
}
|
|
8257
|
+
var guaranteedFallbackFooterLookId = asFooterLookId("footer-muted-grounding");
|
|
8258
|
+
function mutedGroundingFooter(theme) {
|
|
8259
|
+
return theme.footer;
|
|
8260
|
+
}
|
|
8261
|
+
function brandTwoBandFooter(theme) {
|
|
8262
|
+
return {
|
|
8263
|
+
...theme.footer,
|
|
8264
|
+
variant: "split",
|
|
8265
|
+
maxWidth: "container",
|
|
8266
|
+
background: {
|
|
8267
|
+
type: "color",
|
|
8268
|
+
color: "primary-800"
|
|
8269
|
+
},
|
|
8270
|
+
navStyle: "minimal",
|
|
8271
|
+
navWeight: "medium",
|
|
8272
|
+
navColor: "primaryForeground",
|
|
8273
|
+
navLinkStyle: {
|
|
8274
|
+
typography: "body",
|
|
8275
|
+
fontWeight: "medium",
|
|
8276
|
+
textTransform: "none",
|
|
8277
|
+
italic: false,
|
|
8278
|
+
colorToken: "primaryForeground",
|
|
8279
|
+
hoverColorToken: "secondary",
|
|
8280
|
+
padding: "none",
|
|
8281
|
+
borderRadius: "none"
|
|
8282
|
+
},
|
|
8283
|
+
bottomTextLinkStyle: {
|
|
8284
|
+
colorToken: "secondary",
|
|
8285
|
+
decorationColorToken: "secondary"
|
|
8286
|
+
},
|
|
8287
|
+
navLayout: {
|
|
8288
|
+
layout: "inline-wrap",
|
|
8289
|
+
align: "start",
|
|
8290
|
+
gapX: "default",
|
|
8291
|
+
gapY: "tight"
|
|
8292
|
+
},
|
|
8293
|
+
logo: {
|
|
8294
|
+
showLogo: true,
|
|
8295
|
+
showLogoText: false,
|
|
8296
|
+
placement: "left",
|
|
8297
|
+
size: "sm",
|
|
8298
|
+
align: "start"
|
|
8299
|
+
},
|
|
8300
|
+
bottomBar: {
|
|
8301
|
+
enabled: true,
|
|
8302
|
+
fullBleed: true,
|
|
8303
|
+
background: {
|
|
8304
|
+
type: "color",
|
|
8305
|
+
color: "primary-900"
|
|
8306
|
+
},
|
|
8307
|
+
textColor: "primaryForeground",
|
|
8308
|
+
textAlign: "center",
|
|
8309
|
+
paddingX: "default",
|
|
8310
|
+
paddingY: "compact",
|
|
8311
|
+
borderTop: {
|
|
8312
|
+
width: "none"
|
|
8313
|
+
}
|
|
8314
|
+
}
|
|
8315
|
+
};
|
|
8316
|
+
}
|
|
8317
|
+
var footerLookCatalog = [
|
|
8318
|
+
{
|
|
8319
|
+
id: asFooterLookId("footer-muted-grounding"),
|
|
8320
|
+
label: "Muted grounding footer",
|
|
8321
|
+
compile: mutedGroundingFooter
|
|
8322
|
+
},
|
|
8323
|
+
{
|
|
8324
|
+
id: asFooterLookId("site-footer-brand-two-band"),
|
|
8325
|
+
label: "Two-band brand footer",
|
|
8326
|
+
maxRecommendedNavDensity: "balanced",
|
|
8327
|
+
allowedContentPresence: ["default-footer", "default-and-blocks"],
|
|
8328
|
+
compile: brandTwoBandFooter
|
|
8329
|
+
}
|
|
8330
|
+
];
|
|
8331
|
+
var footerLooksById = new Map(
|
|
8332
|
+
footerLookCatalog.map((look) => [look.id, look])
|
|
8333
|
+
);
|
|
8334
|
+
|
|
8335
|
+
// ../theme-core/src/site-styles/sourceCatalogs.ts
|
|
8336
|
+
var generatedContentFrames = [
|
|
8337
|
+
plainFrame,
|
|
8338
|
+
panelFrame("inset"),
|
|
8339
|
+
panelFrame("raised"),
|
|
8340
|
+
flushPanelFrame({ bleed: "start" })
|
|
8341
|
+
];
|
|
8342
|
+
var userContentFrames = [
|
|
8343
|
+
...generatedContentFrames,
|
|
8344
|
+
panelFrame("editorial"),
|
|
8345
|
+
flushPanelFrame({ bleed: "end" }),
|
|
8346
|
+
flushPanelFrame({ bleed: "both" })
|
|
8347
|
+
];
|
|
8348
|
+
var generatedDesignOptionCatalog = {
|
|
8349
|
+
source: "generated",
|
|
8350
|
+
sectionSurfaces: ["base", "muted-band", "accent-band", "brand-depth-band", "hero-image"],
|
|
8351
|
+
contentFrames: generatedContentFrames,
|
|
8352
|
+
itemSurfaces: ["none", "default", "flat", "outlined", "raised"],
|
|
8353
|
+
transitions: ["none", "soft-fade-short", "soft-fade-long"],
|
|
8354
|
+
emphases: ["low", "medium", "high"],
|
|
8355
|
+
detachedCustom: false
|
|
8356
|
+
};
|
|
8357
|
+
var userDesignOptionCatalog = {
|
|
8358
|
+
source: "user",
|
|
8359
|
+
sectionSurfaces: generatedDesignOptionCatalog.sectionSurfaces,
|
|
8360
|
+
contentFrames: userContentFrames,
|
|
8361
|
+
itemSurfaces: [
|
|
8362
|
+
...generatedDesignOptionCatalog.itemSurfaces,
|
|
8363
|
+
"inset",
|
|
8364
|
+
"editorial"
|
|
8365
|
+
],
|
|
8366
|
+
transitions: [
|
|
8367
|
+
...generatedDesignOptionCatalog.transitions,
|
|
8368
|
+
"wave-edge",
|
|
8369
|
+
"angle-edge"
|
|
8370
|
+
],
|
|
8371
|
+
emphases: generatedDesignOptionCatalog.emphases,
|
|
8372
|
+
detachedCustom: false
|
|
8373
|
+
};
|
|
8374
|
+
var advancedDesignOptionCatalog = {
|
|
8375
|
+
source: "advanced",
|
|
8376
|
+
sectionSurfaces: userDesignOptionCatalog.sectionSurfaces,
|
|
8377
|
+
contentFrames: userDesignOptionCatalog.contentFrames,
|
|
8378
|
+
itemSurfaces: userDesignOptionCatalog.itemSurfaces,
|
|
8379
|
+
transitions: userDesignOptionCatalog.transitions,
|
|
8380
|
+
emphases: userDesignOptionCatalog.emphases,
|
|
8381
|
+
detachedCustom: true
|
|
8382
|
+
};
|
|
8383
|
+
|
|
8384
|
+
// ../theme-core/src/site-styles/typographyPresets.ts
|
|
8385
|
+
var bodyReadablePolicy = {
|
|
8386
|
+
recommendedCategories: ["sans-serif", "serif"],
|
|
8387
|
+
allowedCategories: ["sans-serif", "serif"],
|
|
8388
|
+
requiresItalicForBody: true,
|
|
8389
|
+
requiresBoldForBody: true
|
|
8390
|
+
};
|
|
8391
|
+
var headingFlexiblePolicy = {
|
|
8392
|
+
recommendedCategories: ["sans-serif", "serif", "display"],
|
|
8393
|
+
allowedCategories: ["sans-serif", "serif", "display"]
|
|
8394
|
+
};
|
|
8395
|
+
var displayHeadingPolicy = {
|
|
8396
|
+
recommendedCategories: ["display", "sans-serif", "serif"],
|
|
8397
|
+
allowedCategories: ["display", "sans-serif", "serif"]
|
|
8398
|
+
};
|
|
8399
|
+
function asTypographyPresetId(value) {
|
|
8400
|
+
if (!value.startsWith("typography-preset:")) {
|
|
8401
|
+
throw new Error(`TypographyPresetId must start with "typography-preset:". Received: ${value}`);
|
|
8402
|
+
}
|
|
8403
|
+
return value;
|
|
8404
|
+
}
|
|
8405
|
+
function defineTypographyPreset(preset) {
|
|
8406
|
+
return {
|
|
8407
|
+
...preset,
|
|
8408
|
+
id: asTypographyPresetId(preset.id)
|
|
8409
|
+
};
|
|
8410
|
+
}
|
|
8411
|
+
var modernSansTypography = {
|
|
8412
|
+
body: {
|
|
8413
|
+
family: "Inter, system-ui, sans-serif",
|
|
8414
|
+
size: "md",
|
|
8415
|
+
weight: "regular",
|
|
8416
|
+
lineHeight: "relaxed",
|
|
8417
|
+
letterSpacing: "normal"
|
|
8418
|
+
},
|
|
8419
|
+
headings: {
|
|
8420
|
+
default: {
|
|
8421
|
+
family: "Inter, system-ui, sans-serif",
|
|
8422
|
+
weight: "semibold",
|
|
8423
|
+
lineHeight: "normal",
|
|
8424
|
+
letterSpacing: "tight",
|
|
8425
|
+
italic: null,
|
|
8426
|
+
case: null
|
|
8427
|
+
},
|
|
8428
|
+
h1: { size: "xl", weight: "bold", lineHeight: "normal", letterSpacing: "tight", italic: null },
|
|
8429
|
+
h2: { size: "lg", weight: "semibold", lineHeight: "normal", letterSpacing: "tight", italic: null },
|
|
8430
|
+
h3: { size: "md", weight: "semibold", lineHeight: "normal", letterSpacing: "normal", italic: null }
|
|
8431
|
+
},
|
|
8432
|
+
scale: "balanced"
|
|
8433
|
+
};
|
|
8434
|
+
var warmRoundedTypography = {
|
|
8435
|
+
body: {
|
|
8436
|
+
family: "Nunito Sans, system-ui, sans-serif",
|
|
8437
|
+
size: "lg",
|
|
8438
|
+
weight: "regular",
|
|
8439
|
+
lineHeight: "relaxed",
|
|
8440
|
+
letterSpacing: "normal"
|
|
8441
|
+
},
|
|
8442
|
+
headings: {
|
|
8443
|
+
default: {
|
|
8444
|
+
family: "Nunito Sans, system-ui, sans-serif",
|
|
8445
|
+
weight: "bold",
|
|
8446
|
+
lineHeight: "normal",
|
|
8447
|
+
letterSpacing: "normal",
|
|
8448
|
+
italic: null,
|
|
8449
|
+
case: null
|
|
8450
|
+
},
|
|
8451
|
+
h1: { size: "xl", weight: "bold", lineHeight: "normal", letterSpacing: "normal", italic: null },
|
|
8452
|
+
h2: { size: "lg", weight: "bold", lineHeight: "normal", letterSpacing: "normal", italic: null },
|
|
8453
|
+
h3: { size: "md", weight: "semibold", lineHeight: "relaxed", letterSpacing: "normal", italic: null }
|
|
8454
|
+
},
|
|
8455
|
+
scale: "balanced"
|
|
8456
|
+
};
|
|
8457
|
+
var editorialSerifTypography = {
|
|
8458
|
+
body: {
|
|
8459
|
+
family: "Lora, Georgia, serif",
|
|
8460
|
+
size: "lg",
|
|
8461
|
+
weight: "regular",
|
|
8462
|
+
lineHeight: "loose",
|
|
8463
|
+
letterSpacing: "normal"
|
|
8464
|
+
},
|
|
8465
|
+
headings: {
|
|
8466
|
+
default: {
|
|
8467
|
+
family: "Playfair Display, Georgia, serif",
|
|
8468
|
+
weight: "semibold",
|
|
8469
|
+
lineHeight: "normal",
|
|
8470
|
+
letterSpacing: "tight",
|
|
8471
|
+
italic: null,
|
|
8472
|
+
case: null
|
|
8473
|
+
},
|
|
8474
|
+
h1: { size: "2xl", weight: "semibold", lineHeight: "normal", letterSpacing: "tight", italic: null },
|
|
8475
|
+
h2: { size: "xl", weight: "semibold", lineHeight: "normal", letterSpacing: "normal", italic: null },
|
|
8476
|
+
h3: { size: "md", weight: "semibold", lineHeight: "relaxed", letterSpacing: "normal", italic: true }
|
|
8477
|
+
},
|
|
8478
|
+
scale: "spacious"
|
|
8479
|
+
};
|
|
8480
|
+
var classicSerifTypography = {
|
|
8481
|
+
body: {
|
|
8482
|
+
family: "Libre Baskerville, Georgia, serif",
|
|
8483
|
+
size: "md",
|
|
8484
|
+
weight: "regular",
|
|
8485
|
+
lineHeight: "relaxed",
|
|
8486
|
+
letterSpacing: "normal"
|
|
8487
|
+
},
|
|
8488
|
+
headings: {
|
|
8489
|
+
default: {
|
|
8490
|
+
family: "Cormorant Garamond, Georgia, serif",
|
|
8491
|
+
weight: "semibold",
|
|
8492
|
+
lineHeight: "normal",
|
|
8493
|
+
letterSpacing: "normal",
|
|
8494
|
+
italic: null,
|
|
8495
|
+
case: null
|
|
8496
|
+
},
|
|
8497
|
+
h1: { size: "2xl", weight: "semibold", lineHeight: "normal", letterSpacing: "normal", italic: null },
|
|
8498
|
+
h2: { size: "xl", weight: "semibold", lineHeight: "normal", letterSpacing: "normal", italic: null },
|
|
8499
|
+
h3: { size: "md", weight: "medium", lineHeight: "relaxed", letterSpacing: "normal", italic: null }
|
|
8500
|
+
},
|
|
8501
|
+
scale: "balanced"
|
|
8502
|
+
};
|
|
8503
|
+
var luxeContrastTypography = {
|
|
8504
|
+
body: {
|
|
8505
|
+
family: "Manrope, system-ui, sans-serif",
|
|
8506
|
+
size: "md",
|
|
8507
|
+
weight: "regular",
|
|
8508
|
+
lineHeight: "relaxed",
|
|
8509
|
+
letterSpacing: "normal"
|
|
8510
|
+
},
|
|
8511
|
+
headings: {
|
|
8512
|
+
default: {
|
|
8513
|
+
family: "Cormorant Garamond, Georgia, serif",
|
|
8514
|
+
weight: "semibold",
|
|
8515
|
+
lineHeight: "normal",
|
|
8516
|
+
letterSpacing: "tight",
|
|
8517
|
+
italic: null,
|
|
8518
|
+
case: null
|
|
8519
|
+
},
|
|
8520
|
+
h1: { size: "2xl", weight: "semibold", lineHeight: "normal", letterSpacing: "tight", italic: null },
|
|
8521
|
+
h2: { size: "xl", weight: "semibold", lineHeight: "normal", letterSpacing: "tight", italic: null },
|
|
8522
|
+
h3: { size: "md", weight: "medium", lineHeight: "relaxed", letterSpacing: "normal", italic: null }
|
|
8523
|
+
},
|
|
8524
|
+
scale: "spacious"
|
|
8525
|
+
};
|
|
8526
|
+
var boldDisplayTypography = {
|
|
8527
|
+
body: {
|
|
8528
|
+
family: "Manrope, system-ui, sans-serif",
|
|
8529
|
+
size: "lg",
|
|
8530
|
+
weight: "regular",
|
|
8531
|
+
lineHeight: "relaxed",
|
|
8532
|
+
letterSpacing: "normal"
|
|
8533
|
+
},
|
|
8534
|
+
headings: {
|
|
8535
|
+
default: {
|
|
8536
|
+
family: '"TAN - PEARL", sans-serif',
|
|
8537
|
+
weight: "bold",
|
|
8538
|
+
lineHeight: "normal",
|
|
8539
|
+
letterSpacing: "tight",
|
|
8540
|
+
colorToken: "primary",
|
|
8541
|
+
italic: null,
|
|
8542
|
+
case: null
|
|
8543
|
+
},
|
|
8544
|
+
h1: { size: "xl", weight: "bold", lineHeight: "normal", letterSpacing: "tight", italic: null },
|
|
8545
|
+
h2: { size: "lg", weight: "bold", lineHeight: "normal", letterSpacing: "normal", italic: null },
|
|
8546
|
+
h3: { size: "md", weight: "bold", lineHeight: "normal", letterSpacing: "normal", italic: null }
|
|
8547
|
+
},
|
|
8548
|
+
scale: "balanced"
|
|
8549
|
+
};
|
|
8550
|
+
var typographyPresets = [
|
|
8551
|
+
defineTypographyPreset({
|
|
8552
|
+
id: "typography-preset:modern-sans",
|
|
8553
|
+
name: "Modern Sans",
|
|
8554
|
+
description: "Crisp, neutral type for clear service pages and practical editorial structure.",
|
|
8555
|
+
defaultFonts: { body: "Inter, system-ui, sans-serif", heading: "Inter, system-ui, sans-serif" },
|
|
8556
|
+
recommendedFonts: {
|
|
8557
|
+
body: ["Inter", "Source Sans 3", "IBM Plex Sans"],
|
|
8558
|
+
heading: ["Inter", "Manrope", "Source Sans 3"]
|
|
8559
|
+
},
|
|
8560
|
+
slotPolicies: { body: bodyReadablePolicy, heading: headingFlexiblePolicy },
|
|
8561
|
+
typography: modernSansTypography
|
|
8562
|
+
}),
|
|
8563
|
+
defineTypographyPreset({
|
|
8564
|
+
id: "typography-preset:warm-rounded",
|
|
8565
|
+
name: "Warm Rounded",
|
|
8566
|
+
description: "Soft, friendly type for welcoming studios, classes, and community businesses.",
|
|
8567
|
+
defaultFonts: { body: "Nunito Sans, system-ui, sans-serif", heading: "Nunito Sans, system-ui, sans-serif" },
|
|
8568
|
+
recommendedFonts: {
|
|
8569
|
+
body: ["Nunito Sans", "Atkinson Hyperlegible", "Lato"],
|
|
8570
|
+
heading: ["Nunito Sans", "Quicksand", "Manrope"]
|
|
8571
|
+
},
|
|
8572
|
+
slotPolicies: { body: bodyReadablePolicy, heading: headingFlexiblePolicy },
|
|
8573
|
+
typography: warmRoundedTypography
|
|
8574
|
+
}),
|
|
8575
|
+
defineTypographyPreset({
|
|
8576
|
+
id: "typography-preset:editorial-serif",
|
|
8577
|
+
name: "Editorial Serif",
|
|
8578
|
+
description: "Story-led type with warm reading rhythm and expressive headings.",
|
|
8579
|
+
defaultFonts: { body: "Lora, Georgia, serif", heading: "Playfair Display, Georgia, serif" },
|
|
8580
|
+
recommendedFonts: {
|
|
8581
|
+
body: ["Lora", "Source Serif 4", "Libre Baskerville"],
|
|
8582
|
+
heading: ["Playfair Display", "Cormorant Garamond", "Fraunces"]
|
|
8583
|
+
},
|
|
8584
|
+
slotPolicies: { body: bodyReadablePolicy, heading: displayHeadingPolicy },
|
|
8585
|
+
typography: editorialSerifTypography
|
|
8586
|
+
}),
|
|
8587
|
+
defineTypographyPreset({
|
|
8588
|
+
id: "typography-preset:classic-serif",
|
|
8589
|
+
name: "Classic Serif",
|
|
8590
|
+
description: "Measured, polished type for premium and established offers.",
|
|
8591
|
+
defaultFonts: { body: "Libre Baskerville, Georgia, serif", heading: "Cormorant Garamond, Georgia, serif" },
|
|
8592
|
+
recommendedFonts: {
|
|
8593
|
+
body: ["Libre Baskerville", "Source Serif 4", "Lora"],
|
|
8594
|
+
heading: ["Cormorant Garamond", "Playfair Display", "Libre Baskerville"]
|
|
8595
|
+
},
|
|
8596
|
+
slotPolicies: { body: bodyReadablePolicy, heading: displayHeadingPolicy },
|
|
8597
|
+
typography: classicSerifTypography
|
|
8598
|
+
}),
|
|
8599
|
+
defineTypographyPreset({
|
|
8600
|
+
id: "typography-preset:luxe-contrast",
|
|
8601
|
+
name: "Luxe Contrast",
|
|
8602
|
+
description: "A restrained sans body paired with elegant high-contrast headings.",
|
|
8603
|
+
defaultFonts: { body: "Manrope, system-ui, sans-serif", heading: "Cormorant Garamond, Georgia, serif" },
|
|
8604
|
+
recommendedFonts: {
|
|
8605
|
+
body: ["Manrope", "Inter", "Source Sans 3"],
|
|
8606
|
+
heading: ["Cormorant Garamond", "Playfair Display", "Bodoni Moda"]
|
|
8607
|
+
},
|
|
8608
|
+
slotPolicies: { body: bodyReadablePolicy, heading: displayHeadingPolicy },
|
|
8609
|
+
typography: luxeContrastTypography
|
|
8610
|
+
}),
|
|
8611
|
+
defineTypographyPreset({
|
|
8612
|
+
id: "typography-preset:bold-display",
|
|
8613
|
+
name: "Bold Display",
|
|
8614
|
+
description: "Punchy display headings with readable sans body copy for branded launches.",
|
|
8615
|
+
defaultFonts: { body: "Manrope, system-ui, sans-serif", heading: '"TAN - PEARL", sans-serif' },
|
|
8616
|
+
recommendedFonts: {
|
|
8617
|
+
body: ["Manrope", "Inter", "Space Grotesk"],
|
|
8618
|
+
heading: ["Anton", "Bebas Neue", "Archivo Black"]
|
|
8619
|
+
},
|
|
8620
|
+
slotPolicies: { body: bodyReadablePolicy, heading: displayHeadingPolicy },
|
|
8621
|
+
typography: boldDisplayTypography,
|
|
8622
|
+
heroTypography: {
|
|
8623
|
+
headlineSize: "6xl",
|
|
8624
|
+
headlineLineHeight: "tight",
|
|
8625
|
+
subheadlineSize: "2xl",
|
|
8626
|
+
subheadlineLineHeight: "normal",
|
|
8627
|
+
microHeadlineSize: "6xl",
|
|
8628
|
+
microHeadlineLineHeight: "tight",
|
|
8629
|
+
microSubheadlineSize: "xl",
|
|
8630
|
+
microSubheadlineLineHeight: "normal",
|
|
8631
|
+
responsive: {
|
|
8632
|
+
tablet: { headlineSize: "5xl" },
|
|
8633
|
+
mobile: { headlineSize: "4xl", subheadlineSize: "xl" }
|
|
8634
|
+
}
|
|
8635
|
+
}
|
|
8636
|
+
})
|
|
8637
|
+
];
|
|
8638
|
+
var typographyPresetsById = new Map(
|
|
8639
|
+
typographyPresets.map((preset) => [preset.id, preset])
|
|
8640
|
+
);
|
|
8641
|
+
|
|
8642
|
+
// ../theme-core/src/site-styles/curatedSiteStyles.ts
|
|
8643
|
+
var SOFT_EARTH_SITE_STYLE_ID_VALUE = "site-style:soft-earth";
|
|
8644
|
+
var SOFT_EARTH_SITE_STYLE_ID = asSiteStyleId(SOFT_EARTH_SITE_STYLE_ID_VALUE);
|
|
8645
|
+
var quietBudget = {
|
|
8646
|
+
accentDensity: "low",
|
|
8647
|
+
panelDensity: "medium",
|
|
8648
|
+
transitionMix: "quiet",
|
|
8649
|
+
primaryCtaLimit: 2,
|
|
8650
|
+
mediaDensity: "medium",
|
|
8651
|
+
decorativeRepetition: "low"
|
|
8652
|
+
};
|
|
8653
|
+
var balancedBudget = {
|
|
8654
|
+
accentDensity: "medium",
|
|
8655
|
+
panelDensity: "medium",
|
|
8656
|
+
transitionMix: "balanced",
|
|
8657
|
+
primaryCtaLimit: 3,
|
|
8658
|
+
mediaDensity: "medium",
|
|
8659
|
+
decorativeRepetition: "medium"
|
|
8660
|
+
};
|
|
8661
|
+
var expressiveBudget = {
|
|
8662
|
+
accentDensity: "high",
|
|
8663
|
+
panelDensity: "high",
|
|
8664
|
+
transitionMix: "expressive",
|
|
8665
|
+
primaryCtaLimit: 3,
|
|
8666
|
+
mediaDensity: "high",
|
|
8667
|
+
decorativeRepetition: "medium"
|
|
8668
|
+
};
|
|
8669
|
+
var expressiveUnderlineInputs = {
|
|
8670
|
+
base: {
|
|
8671
|
+
background: { type: "transparent" },
|
|
8672
|
+
textColorToken: "text",
|
|
8673
|
+
border: {
|
|
8674
|
+
widthClass: "border-2",
|
|
8675
|
+
colorToken: "border",
|
|
8676
|
+
style: "underline"
|
|
8677
|
+
},
|
|
8678
|
+
corners: "square",
|
|
8679
|
+
shadow: null,
|
|
8680
|
+
spacing: "compact",
|
|
8681
|
+
fontSize: "base"
|
|
8682
|
+
},
|
|
8683
|
+
label: {
|
|
8684
|
+
textColorToken: "primary",
|
|
8685
|
+
fontWeight: "black",
|
|
8686
|
+
fontSize: "xs",
|
|
8687
|
+
textTransform: "uppercase",
|
|
8688
|
+
letterSpacing: "widest",
|
|
8689
|
+
opacity: 1
|
|
8690
|
+
},
|
|
8691
|
+
focus: {
|
|
8692
|
+
ringColorToken: "secondary",
|
|
8693
|
+
ringWidth: "0",
|
|
8694
|
+
borderColorToken: "secondary"
|
|
8695
|
+
},
|
|
8696
|
+
error: {
|
|
8697
|
+
borderColorToken: "destructive",
|
|
8698
|
+
textColorToken: "destructive"
|
|
8699
|
+
},
|
|
8700
|
+
disabled: {
|
|
8701
|
+
backgroundColorToken: "surface",
|
|
8702
|
+
textColorToken: "text",
|
|
8703
|
+
opacity: 0.6
|
|
8704
|
+
}
|
|
8705
|
+
};
|
|
8706
|
+
function uniqueContentFrameKinds() {
|
|
8707
|
+
const kinds = [
|
|
8708
|
+
...new Set(
|
|
8709
|
+
generatedDesignOptionCatalog.contentFrames.map((frame) => frame.kind)
|
|
8710
|
+
)
|
|
8711
|
+
];
|
|
8712
|
+
const firstKind = kinds[0];
|
|
8713
|
+
if (!firstKind) {
|
|
8714
|
+
throw new Error(
|
|
8715
|
+
"Expected generated design option catalog to expose at least one content frame kind."
|
|
8716
|
+
);
|
|
8717
|
+
}
|
|
8718
|
+
return [firstKind, ...kinds.slice(1)];
|
|
6048
8719
|
}
|
|
6049
|
-
|
|
6050
|
-
|
|
6051
|
-
|
|
8720
|
+
var generatedContentFrameKinds = uniqueContentFrameKinds();
|
|
8721
|
+
function defineCuratedSiteStyle(input) {
|
|
8722
|
+
const legacyHeaderLookIds = input.recommendedHeaderLookIds ?? ["clean-base"];
|
|
8723
|
+
const inferredHeaderCuration = inferHeaderCurationFromLegacyLooks(
|
|
8724
|
+
legacyHeaderLookIds,
|
|
8725
|
+
input.tokenRecipes
|
|
8726
|
+
);
|
|
8727
|
+
const typographyPresetChoices = input.typographyPresetChoices ?? defaultTypographyPresetChoicesForRecipe(input.tokenRecipes.typography);
|
|
8728
|
+
const defaultTypographyPresetId = input.defaultTypographyPresetId ? asTypographyPresetId(input.defaultTypographyPresetId) : typographyPresetChoices[0].id;
|
|
8729
|
+
if (!typographyPresetChoices.some(
|
|
8730
|
+
(choice) => choice.id === defaultTypographyPresetId
|
|
8731
|
+
)) {
|
|
8732
|
+
throw new Error(
|
|
8733
|
+
`Default typography preset ${defaultTypographyPresetId} is not curated for site style ${input.id}.`
|
|
8734
|
+
);
|
|
8735
|
+
}
|
|
8736
|
+
return {
|
|
8737
|
+
id: asSiteStyleId(input.id),
|
|
8738
|
+
name: input.name,
|
|
8739
|
+
description: input.description,
|
|
8740
|
+
generationBrief: input.generationBrief,
|
|
8741
|
+
selectionKeywordRules: input.selectionKeywordRules ?? [],
|
|
8742
|
+
siteCreatorSelection: input.siteCreatorSelection ?? {
|
|
8743
|
+
kind: "explicit_only"
|
|
8744
|
+
},
|
|
8745
|
+
template: {
|
|
8746
|
+
id: asDesignSystemTemplateId(
|
|
8747
|
+
`template:${input.id.replace("site-style:", "")}`
|
|
8748
|
+
),
|
|
8749
|
+
name: input.name,
|
|
8750
|
+
version: 1,
|
|
8751
|
+
tokenRecipes: input.tokenRecipes,
|
|
8752
|
+
compositionBudget: input.compositionBudget,
|
|
8753
|
+
supportedSectionSurfaces: generatedDesignOptionCatalog.sectionSurfaces,
|
|
8754
|
+
supportedContentFrames: generatedContentFrameKinds,
|
|
8755
|
+
supportedItemSurfaces: generatedDesignOptionCatalog.itemSurfaces,
|
|
8756
|
+
supportedTransitions: generatedDesignOptionCatalog.transitions
|
|
8757
|
+
},
|
|
8758
|
+
...input.themeOverrides ? { themeOverrides: input.themeOverrides } : {},
|
|
8759
|
+
...input.defaultBlockVariants ? { defaultBlockVariants: input.defaultBlockVariants } : {},
|
|
8760
|
+
recommendedAppearancePresetIds: (input.recommendedAppearancePresetIds ?? []).map(asAppearancePresetId),
|
|
8761
|
+
defaultHeaderSelection: input.defaultHeaderSelection ? {
|
|
8762
|
+
layoutId: asHeaderLayoutId(input.defaultHeaderSelection.layoutId),
|
|
8763
|
+
styleId: asHeaderStyleId(input.defaultHeaderSelection.styleId)
|
|
8764
|
+
} : inferredHeaderCuration.defaultHeaderSelection,
|
|
8765
|
+
recommendedHeaderLayoutChoices: input.recommendedHeaderLayoutChoices ?? inferredHeaderCuration.recommendedHeaderLayoutChoices,
|
|
8766
|
+
recommendedHeaderStyleChoicesByLayout: input.recommendedHeaderStyleChoicesByLayout ?? inferredHeaderCuration.recommendedHeaderStyleChoicesByLayout,
|
|
8767
|
+
discouragedHeaderSelections: input.discouragedHeaderSelections?.map(
|
|
8768
|
+
(selection) => ({
|
|
8769
|
+
layoutId: asHeaderLayoutId(selection.layoutId),
|
|
8770
|
+
styleId: asHeaderStyleId(selection.styleId)
|
|
8771
|
+
})
|
|
8772
|
+
),
|
|
8773
|
+
recommendedHeaderLookIds: legacyHeaderLookIds.map(asHeaderLookId),
|
|
8774
|
+
// Empty is intentional: resolveFooterLook always appends its guaranteed fallback.
|
|
8775
|
+
recommendedFooterLookIds: (input.recommendedFooterLookIds ?? []).map(
|
|
8776
|
+
asFooterLookId
|
|
8777
|
+
),
|
|
8778
|
+
buttonPersonalityChoices: input.buttonPersonalityChoices,
|
|
8779
|
+
paletteVariantChoices: input.paletteVariantChoices,
|
|
8780
|
+
typographyPresetChoices,
|
|
8781
|
+
defaultTypographyPresetId
|
|
8782
|
+
};
|
|
6052
8783
|
}
|
|
6053
|
-
function
|
|
6054
|
-
|
|
6055
|
-
|
|
6056
|
-
|
|
8784
|
+
function buttonChoice(id, note) {
|
|
8785
|
+
return note ? { id: asButtonPersonalityId(id), note } : { id: asButtonPersonalityId(id) };
|
|
8786
|
+
}
|
|
8787
|
+
function paletteChoice(id, note) {
|
|
8788
|
+
return note ? { id: asPaletteVariantId(id), note } : { id: asPaletteVariantId(id) };
|
|
8789
|
+
}
|
|
8790
|
+
function headerLayoutChoice(id, note) {
|
|
8791
|
+
return note ? { id: asHeaderLayoutId(id), note } : { id: asHeaderLayoutId(id) };
|
|
8792
|
+
}
|
|
8793
|
+
function headerStyleChoice(id, note) {
|
|
8794
|
+
return note ? { id: asHeaderStyleId(id), note } : { id: asHeaderStyleId(id) };
|
|
8795
|
+
}
|
|
8796
|
+
function unbrandHeaderLayoutId(id) {
|
|
8797
|
+
return id;
|
|
8798
|
+
}
|
|
8799
|
+
function uniqueHeaderLayoutChoices(choices) {
|
|
8800
|
+
const seen = /* @__PURE__ */ new Set();
|
|
8801
|
+
const unique = choices.filter((choice) => {
|
|
8802
|
+
if (seen.has(choice.id)) return false;
|
|
8803
|
+
seen.add(choice.id);
|
|
6057
8804
|
return true;
|
|
8805
|
+
});
|
|
8806
|
+
const first = unique[0];
|
|
8807
|
+
if (!first) {
|
|
8808
|
+
throw new Error("Expected at least one curated header layout choice.");
|
|
6058
8809
|
}
|
|
6059
|
-
|
|
6060
|
-
for (const part of parts) {
|
|
6061
|
-
if (isForbiddenSelectorPart(part)) {
|
|
6062
|
-
return true;
|
|
6063
|
-
}
|
|
6064
|
-
}
|
|
6065
|
-
return false;
|
|
8810
|
+
return [first, ...unique.slice(1)];
|
|
6066
8811
|
}
|
|
6067
|
-
|
|
6068
|
-
|
|
6069
|
-
|
|
6070
|
-
|
|
6071
|
-
|
|
6072
|
-
|
|
8812
|
+
function nonEmptyHeaderStyleChoices(choices, fallbackLayoutId) {
|
|
8813
|
+
const first = choices[0] ?? {
|
|
8814
|
+
id: getCompatibleHeaderStyleIds(fallbackLayoutId)[0] ?? asHeaderStyleId("minimal")
|
|
8815
|
+
};
|
|
8816
|
+
return [first, ...choices.slice(1)];
|
|
8817
|
+
}
|
|
8818
|
+
function uniqueCompatibleHeaderStyleChoices(choices, fallbackLayoutId) {
|
|
8819
|
+
const compatible = new Set(getCompatibleHeaderStyleIds(fallbackLayoutId));
|
|
8820
|
+
const seen = /* @__PURE__ */ new Set();
|
|
8821
|
+
const unique = choices.filter((choice) => {
|
|
8822
|
+
if (!compatible.has(choice.id)) return false;
|
|
8823
|
+
if (seen.has(choice.id)) return false;
|
|
8824
|
+
seen.add(choice.id);
|
|
8825
|
+
return true;
|
|
8826
|
+
});
|
|
8827
|
+
return nonEmptyHeaderStyleChoices(unique, fallbackLayoutId);
|
|
8828
|
+
}
|
|
8829
|
+
function inferredHeaderStyleValuesForRecipes(layoutId, recipes) {
|
|
8830
|
+
switch (layoutId) {
|
|
8831
|
+
case "classic":
|
|
8832
|
+
if (isExpressiveRecipe(recipes)) {
|
|
8833
|
+
return [
|
|
8834
|
+
"brand-bar",
|
|
8835
|
+
"brand-underline",
|
|
8836
|
+
"flat-tabs",
|
|
8837
|
+
"brand-pill",
|
|
8838
|
+
"fine-line"
|
|
8839
|
+
];
|
|
8840
|
+
}
|
|
8841
|
+
if (recipes.spacing === "compact") {
|
|
8842
|
+
return ["flat-tabs", "fine-line", "minimal", "brand-bar"];
|
|
8843
|
+
}
|
|
8844
|
+
if (isSerifTypographyRecipe(recipes)) {
|
|
8845
|
+
return ["serif-line", "fine-line", "minimal", "soft-bar"];
|
|
8846
|
+
}
|
|
8847
|
+
if (recipes.radius === "rounded" || recipes.radius === "pill") {
|
|
8848
|
+
return ["soft-bar", "pill-nav", "fine-line", "minimal"];
|
|
8849
|
+
}
|
|
8850
|
+
return ["fine-line", "minimal", "soft-bar", "brand-bar"];
|
|
8851
|
+
case "centered":
|
|
8852
|
+
if (isSerifTypographyRecipe(recipes)) {
|
|
8853
|
+
return ["serif-line", "fine-line", "minimal", "soft-bar"];
|
|
8854
|
+
}
|
|
8855
|
+
if (isExpressiveRecipe(recipes)) {
|
|
8856
|
+
return ["brand-pill", "flat-tabs", "brand-bar", "fine-line"];
|
|
8857
|
+
}
|
|
8858
|
+
if (recipes.radius === "rounded" || recipes.radius === "pill") {
|
|
8859
|
+
return ["soft-bar", "pill-nav", "fine-line", "minimal"];
|
|
8860
|
+
}
|
|
8861
|
+
return ["minimal", "fine-line", "soft-bar"];
|
|
8862
|
+
case "floating":
|
|
8863
|
+
if (isExpressiveRecipe(recipes)) {
|
|
8864
|
+
return ["glass", "split-glass", "brand-pill", "soft-shell"];
|
|
8865
|
+
}
|
|
8866
|
+
if (isSerifTypographyRecipe(recipes)) {
|
|
8867
|
+
return ["split-pill", "minimal-surface", "soft-shell"];
|
|
8868
|
+
}
|
|
8869
|
+
return ["soft-shell", "minimal-surface", "glass"];
|
|
8870
|
+
default:
|
|
8871
|
+
return [];
|
|
8872
|
+
}
|
|
6073
8873
|
}
|
|
6074
|
-
function
|
|
6075
|
-
return
|
|
8874
|
+
function isExpressiveRecipe(recipes) {
|
|
8875
|
+
return recipes.contrast === "maximum" || recipes.shadow === "layered" || recipes.motion === "expressive";
|
|
6076
8876
|
}
|
|
6077
|
-
|
|
6078
|
-
|
|
6079
|
-
{ message: "Remote url() references are not allowed. Use local paths, data URIs, or fragment IDs." }
|
|
6080
|
-
).refine(
|
|
6081
|
-
(v) => !containsJavascriptUrl(v),
|
|
6082
|
-
{ message: "javascript: URLs are not allowed" }
|
|
6083
|
-
);
|
|
6084
|
-
var declarationsSchema = z9.record(
|
|
6085
|
-
z9.string().min(1).max(100),
|
|
6086
|
-
// property name
|
|
6087
|
-
declarationValueSchema
|
|
6088
|
-
// property value
|
|
6089
|
-
);
|
|
6090
|
-
var customCssRuleSchema = z9.object({
|
|
6091
|
-
id: z9.string().min(1, "Rule ID is required").max(50, "Rule ID too long"),
|
|
6092
|
-
selector: selectorSchema,
|
|
6093
|
-
declarations: declarationsSchema
|
|
6094
|
-
});
|
|
6095
|
-
var blockCustomCssRuleSchema = customCssRuleSchema.extend({
|
|
6096
|
-
blockKind: z9.string().min(1, "Block kind is required").max(50, "Block kind too long")
|
|
6097
|
-
});
|
|
6098
|
-
var customCssRulesSchema = z9.array(customCssRuleSchema).optional();
|
|
6099
|
-
var blockCustomCssRulesSchema = z9.array(blockCustomCssRuleSchema).optional();
|
|
6100
|
-
|
|
6101
|
-
// ../theme-core/src/customCss/atRuleValidation.ts
|
|
6102
|
-
import { z as z10 } from "zod";
|
|
6103
|
-
var KEYFRAME_OFFSET_PATTERN = /^(from|to|\d{1,3}%)$/i;
|
|
6104
|
-
var ANIMATION_NAME_PATTERN = /^[a-zA-Z_-][a-zA-Z0-9_-]*$/;
|
|
6105
|
-
var BLOCKED_AT_RULES = ["@import", "@charset"];
|
|
6106
|
-
var BLOCKED_AT_RULE_PATTERN = /@(?:import|charset)\b/i;
|
|
6107
|
-
var ruleIdSchema = z10.string().min(1, "Rule ID is required").max(50, "Rule ID too long");
|
|
6108
|
-
var nestedRuleSchema = z10.object({
|
|
6109
|
-
selector: selectorSchema,
|
|
6110
|
-
declarations: declarationsSchema
|
|
6111
|
-
});
|
|
6112
|
-
function isValidKeyframeOffset(offset) {
|
|
6113
|
-
const trimmed = offset.trim().toLowerCase();
|
|
6114
|
-
if (trimmed === "from" || trimmed === "to") return true;
|
|
6115
|
-
const match = trimmed.match(/^(\d{1,3})%$/);
|
|
6116
|
-
if (!match || match[1] === void 0) return false;
|
|
6117
|
-
const value = parseInt(match[1], 10);
|
|
6118
|
-
return value >= 0 && value <= 100;
|
|
8877
|
+
function isSerifTypographyRecipe(recipes) {
|
|
8878
|
+
return recipes.typography === "serif-editorial" || recipes.typography === "classic-serif";
|
|
6119
8879
|
}
|
|
6120
|
-
|
|
6121
|
-
(
|
|
6122
|
-
|
|
6123
|
-
)
|
|
6124
|
-
|
|
6125
|
-
|
|
6126
|
-
)
|
|
6127
|
-
|
|
6128
|
-
|
|
6129
|
-
|
|
6130
|
-
);
|
|
6131
|
-
|
|
6132
|
-
|
|
6133
|
-
|
|
6134
|
-
|
|
6135
|
-
|
|
6136
|
-
|
|
6137
|
-
|
|
6138
|
-
|
|
6139
|
-
|
|
6140
|
-
|
|
6141
|
-
|
|
6142
|
-
|
|
6143
|
-
{
|
|
6144
|
-
|
|
6145
|
-
|
|
6146
|
-
|
|
6147
|
-
|
|
6148
|
-
declarations: fontFaceDeclarationsSchema
|
|
6149
|
-
});
|
|
6150
|
-
var mediaQuerySchema = z10.string().min(1, "Media query is required").max(200, "Media query too long");
|
|
6151
|
-
var mediaAtRuleSchema = z10.object({
|
|
6152
|
-
id: ruleIdSchema,
|
|
6153
|
-
type: z10.literal("media"),
|
|
6154
|
-
query: mediaQuerySchema,
|
|
6155
|
-
rules: z10.array(nestedRuleSchema).min(1, "At least one rule is required")
|
|
6156
|
-
});
|
|
6157
|
-
var supportsConditionSchema = z10.string().min(1, "Supports condition is required").max(200, "Supports condition too long");
|
|
6158
|
-
var supportsAtRuleSchema = z10.object({
|
|
6159
|
-
id: ruleIdSchema,
|
|
6160
|
-
type: z10.literal("supports"),
|
|
6161
|
-
condition: supportsConditionSchema,
|
|
6162
|
-
rules: z10.array(nestedRuleSchema).min(1, "At least one rule is required")
|
|
6163
|
-
});
|
|
6164
|
-
function containsBlockedAtRule(css) {
|
|
6165
|
-
return BLOCKED_AT_RULE_PATTERN.test(css);
|
|
8880
|
+
function inferHeaderCurationFromLegacyLooks(lookIds, recipes) {
|
|
8881
|
+
const selections = lookIds.map((lookId) => resolveLegacyHeaderLookAlias(asHeaderLookId(lookId))).filter(
|
|
8882
|
+
(selection) => Boolean(selection)
|
|
8883
|
+
);
|
|
8884
|
+
const defaultHeaderSelection = selections[0] ?? {
|
|
8885
|
+
layoutId: asHeaderLayoutId("classic"),
|
|
8886
|
+
styleId: asHeaderStyleId("minimal")
|
|
8887
|
+
};
|
|
8888
|
+
const layoutChoices = uniqueHeaderLayoutChoices(
|
|
8889
|
+
selections.map((selection) => headerLayoutChoice(selection.layoutId))
|
|
8890
|
+
);
|
|
8891
|
+
const stylesByLayout = {};
|
|
8892
|
+
for (const layoutChoice of layoutChoices) {
|
|
8893
|
+
const legacyStyleChoices = selections.filter((selection) => selection.layoutId === layoutChoice.id).map((selection) => headerStyleChoice(selection.styleId));
|
|
8894
|
+
const inferredStyleChoices = inferredHeaderStyleValuesForRecipes(
|
|
8895
|
+
layoutChoice.id,
|
|
8896
|
+
recipes
|
|
8897
|
+
).map((styleId) => headerStyleChoice(styleId));
|
|
8898
|
+
stylesByLayout[unbrandHeaderLayoutId(layoutChoice.id)] = uniqueCompatibleHeaderStyleChoices(
|
|
8899
|
+
[...legacyStyleChoices, ...inferredStyleChoices],
|
|
8900
|
+
layoutChoice.id
|
|
8901
|
+
);
|
|
8902
|
+
}
|
|
8903
|
+
return {
|
|
8904
|
+
defaultHeaderSelection,
|
|
8905
|
+
recommendedHeaderLayoutChoices: layoutChoices,
|
|
8906
|
+
recommendedHeaderStyleChoicesByLayout: stylesByLayout
|
|
8907
|
+
};
|
|
6166
8908
|
}
|
|
6167
|
-
|
|
6168
|
-
(
|
|
6169
|
-
|
|
6170
|
-
)
|
|
6171
|
-
(
|
|
6172
|
-
|
|
8909
|
+
function typographyChoice(id, note) {
|
|
8910
|
+
return note ? { id: asTypographyPresetId(id), note } : { id: asTypographyPresetId(id) };
|
|
8911
|
+
}
|
|
8912
|
+
function defaultTypographyPresetChoicesForRecipe(recipe) {
|
|
8913
|
+
switch (recipe) {
|
|
8914
|
+
case "clean-sans":
|
|
8915
|
+
return [
|
|
8916
|
+
typographyChoice("typography-preset:modern-sans"),
|
|
8917
|
+
typographyChoice("typography-preset:luxe-contrast"),
|
|
8918
|
+
typographyChoice("typography-preset:bold-display")
|
|
8919
|
+
];
|
|
8920
|
+
case "friendly-sans":
|
|
8921
|
+
return [
|
|
8922
|
+
typographyChoice("typography-preset:warm-rounded"),
|
|
8923
|
+
typographyChoice("typography-preset:modern-sans"),
|
|
8924
|
+
typographyChoice("typography-preset:editorial-serif")
|
|
8925
|
+
];
|
|
8926
|
+
case "serif-editorial":
|
|
8927
|
+
return [
|
|
8928
|
+
typographyChoice("typography-preset:editorial-serif"),
|
|
8929
|
+
typographyChoice("typography-preset:classic-serif"),
|
|
8930
|
+
typographyChoice("typography-preset:warm-rounded")
|
|
8931
|
+
];
|
|
8932
|
+
case "classic-serif":
|
|
8933
|
+
return [
|
|
8934
|
+
typographyChoice("typography-preset:classic-serif"),
|
|
8935
|
+
typographyChoice("typography-preset:luxe-contrast"),
|
|
8936
|
+
typographyChoice("typography-preset:editorial-serif")
|
|
8937
|
+
];
|
|
8938
|
+
}
|
|
8939
|
+
}
|
|
8940
|
+
var curatedSiteStyles = [
|
|
8941
|
+
defineCuratedSiteStyle({
|
|
8942
|
+
id: "site-style:calm-studio",
|
|
8943
|
+
name: "Calm Studio",
|
|
8944
|
+
description: "Soft, measured, and spacious for intimate appointment or class businesses.",
|
|
8945
|
+
generationBrief: "Use calm pacing, concise copy, generous breathing room, and natural imagery. Keep calls to action steady rather than urgent.",
|
|
8946
|
+
tokenRecipes: {
|
|
8947
|
+
palette: "soft-natural",
|
|
8948
|
+
contrast: "standard",
|
|
8949
|
+
radius: "soft",
|
|
8950
|
+
shadow: "subtle",
|
|
8951
|
+
typography: "friendly-sans",
|
|
8952
|
+
spacing: "airy",
|
|
8953
|
+
motion: "subtle"
|
|
8954
|
+
},
|
|
8955
|
+
compositionBudget: quietBudget,
|
|
8956
|
+
recommendedHeaderLookIds: [
|
|
8957
|
+
"centered-calm",
|
|
8958
|
+
"minimal-transparent",
|
|
8959
|
+
"clean-base"
|
|
8960
|
+
],
|
|
8961
|
+
buttonPersonalityChoices: [
|
|
8962
|
+
buttonChoice("soft-pill"),
|
|
8963
|
+
buttonChoice("pebble"),
|
|
8964
|
+
buttonChoice("editorial-link"),
|
|
8965
|
+
buttonChoice("brushed-wash")
|
|
8966
|
+
],
|
|
8967
|
+
paletteVariantChoices: [
|
|
8968
|
+
paletteChoice("soft-natural-sage"),
|
|
8969
|
+
paletteChoice("soft-natural-stone"),
|
|
8970
|
+
paletteChoice("warm-neutral-clay"),
|
|
8971
|
+
paletteChoice("soft-natural-watercolor")
|
|
8972
|
+
]
|
|
8973
|
+
}),
|
|
8974
|
+
defineCuratedSiteStyle({
|
|
8975
|
+
id: "site-style:clear-professional",
|
|
8976
|
+
name: "Clear Professional",
|
|
8977
|
+
description: "Crisp, trustworthy, and direct for local services and consultancies.",
|
|
8978
|
+
generationBrief: "Prioritize clarity, proof, service detail, and easy next steps. Keep visuals polished and specific, with restrained decorative treatment.",
|
|
8979
|
+
tokenRecipes: {
|
|
8980
|
+
palette: "brand-led",
|
|
8981
|
+
contrast: "strong",
|
|
8982
|
+
radius: "soft",
|
|
8983
|
+
shadow: "subtle",
|
|
8984
|
+
typography: "clean-sans",
|
|
8985
|
+
spacing: "regular",
|
|
8986
|
+
motion: "subtle"
|
|
8987
|
+
},
|
|
8988
|
+
compositionBudget: balancedBudget,
|
|
8989
|
+
recommendedHeaderLookIds: [
|
|
8990
|
+
"practical-utility",
|
|
8991
|
+
"brand-solid",
|
|
8992
|
+
"clean-base"
|
|
8993
|
+
],
|
|
8994
|
+
buttonPersonalityChoices: [
|
|
8995
|
+
buttonChoice("confident-chip"),
|
|
8996
|
+
buttonChoice("soft-pill"),
|
|
8997
|
+
buttonChoice("editorial-link")
|
|
8998
|
+
],
|
|
8999
|
+
paletteVariantChoices: [
|
|
9000
|
+
paletteChoice("brand-led-cool"),
|
|
9001
|
+
paletteChoice("high-contrast-ink"),
|
|
9002
|
+
paletteChoice("brand-led-jewel")
|
|
9003
|
+
]
|
|
9004
|
+
}),
|
|
9005
|
+
defineCuratedSiteStyle({
|
|
9006
|
+
id: "site-style:warm-editorial",
|
|
9007
|
+
name: "Warm Editorial",
|
|
9008
|
+
description: "Story-led and textured for educators, makers, venues, and retreats.",
|
|
9009
|
+
generationBrief: "Let the copy feel thoughtful and grounded. Favor narrative sections, supporting media, and a small number of editorial panels.",
|
|
9010
|
+
tokenRecipes: {
|
|
9011
|
+
palette: "warm-neutral",
|
|
9012
|
+
contrast: "standard",
|
|
9013
|
+
radius: "square",
|
|
9014
|
+
shadow: "none",
|
|
9015
|
+
typography: "serif-editorial",
|
|
9016
|
+
spacing: "airy",
|
|
9017
|
+
motion: "subtle"
|
|
9018
|
+
},
|
|
9019
|
+
compositionBudget: balancedBudget,
|
|
9020
|
+
recommendedHeaderLookIds: [
|
|
9021
|
+
"serif-line",
|
|
9022
|
+
"minimal-transparent",
|
|
9023
|
+
"centered-calm"
|
|
9024
|
+
],
|
|
9025
|
+
buttonPersonalityChoices: [
|
|
9026
|
+
buttonChoice("editorial-link"),
|
|
9027
|
+
buttonChoice("soft-pill"),
|
|
9028
|
+
buttonChoice("brushed-wash")
|
|
9029
|
+
],
|
|
9030
|
+
paletteVariantChoices: [
|
|
9031
|
+
paletteChoice("warm-neutral-cream"),
|
|
9032
|
+
paletteChoice("warm-neutral-clay"),
|
|
9033
|
+
paletteChoice("warm-neutral-forest"),
|
|
9034
|
+
paletteChoice("soft-natural-stone")
|
|
9035
|
+
]
|
|
9036
|
+
}),
|
|
9037
|
+
defineCuratedSiteStyle({
|
|
9038
|
+
id: "site-style:bright-community",
|
|
9039
|
+
name: "Bright Community",
|
|
9040
|
+
description: "Friendly, welcoming, and active for groups, classes, and neighborhood offers.",
|
|
9041
|
+
generationBrief: "Use welcoming language, clear event or booking routes, and optimistic imagery. Let accents appear, but avoid noisy decoration.",
|
|
9042
|
+
tokenRecipes: {
|
|
9043
|
+
palette: "brand-led",
|
|
9044
|
+
contrast: "standard",
|
|
9045
|
+
radius: "rounded",
|
|
9046
|
+
shadow: "subtle",
|
|
9047
|
+
typography: "friendly-sans",
|
|
9048
|
+
spacing: "regular",
|
|
9049
|
+
motion: "expressive"
|
|
9050
|
+
},
|
|
9051
|
+
compositionBudget: balancedBudget,
|
|
9052
|
+
recommendedHeaderLookIds: [
|
|
9053
|
+
"brand-solid",
|
|
9054
|
+
"practical-utility",
|
|
9055
|
+
"clean-base"
|
|
9056
|
+
],
|
|
9057
|
+
buttonPersonalityChoices: [
|
|
9058
|
+
buttonChoice("pebble"),
|
|
9059
|
+
buttonChoice("brushed-wash"),
|
|
9060
|
+
buttonChoice("confident-chip")
|
|
9061
|
+
],
|
|
9062
|
+
paletteVariantChoices: [
|
|
9063
|
+
paletteChoice("brand-led-warm"),
|
|
9064
|
+
paletteChoice("brand-led-jewel"),
|
|
9065
|
+
paletteChoice("soft-natural-watercolor")
|
|
9066
|
+
]
|
|
9067
|
+
}),
|
|
9068
|
+
defineCuratedSiteStyle({
|
|
9069
|
+
id: "site-style:quiet-luxury",
|
|
9070
|
+
name: "Quiet Luxury",
|
|
9071
|
+
description: "Minimal, confident, and refined for premium experiences and private services.",
|
|
9072
|
+
generationBrief: "Use fewer claims, more specificity, and restrained sensory detail. Favor elegant media and low repetition over dense panels.",
|
|
9073
|
+
siteCreatorSelection: {
|
|
9074
|
+
kind: "site_creator_keyword_heuristic",
|
|
9075
|
+
priority: 20
|
|
9076
|
+
},
|
|
9077
|
+
selectionKeywordRules: [
|
|
9078
|
+
{ kind: "word", value: "luxury" },
|
|
9079
|
+
{ kind: "word", value: "premium" },
|
|
9080
|
+
{ kind: "word", value: "boutique" },
|
|
9081
|
+
{ kind: "word", value: "bespoke" },
|
|
9082
|
+
{ kind: "word", value: "exclusive" }
|
|
9083
|
+
],
|
|
9084
|
+
tokenRecipes: {
|
|
9085
|
+
palette: "high-contrast",
|
|
9086
|
+
contrast: "strong",
|
|
9087
|
+
radius: "square",
|
|
9088
|
+
shadow: "none",
|
|
9089
|
+
typography: "classic-serif",
|
|
9090
|
+
spacing: "airy",
|
|
9091
|
+
motion: "none"
|
|
9092
|
+
},
|
|
9093
|
+
compositionBudget: quietBudget,
|
|
9094
|
+
recommendedHeaderLookIds: [
|
|
9095
|
+
"minimal-transparent",
|
|
9096
|
+
"serif-line",
|
|
9097
|
+
"clean-base"
|
|
9098
|
+
],
|
|
9099
|
+
buttonPersonalityChoices: [
|
|
9100
|
+
buttonChoice("editorial-link"),
|
|
9101
|
+
buttonChoice("confident-chip"),
|
|
9102
|
+
buttonChoice("soft-pill")
|
|
9103
|
+
],
|
|
9104
|
+
paletteVariantChoices: [
|
|
9105
|
+
paletteChoice("high-contrast-charcoal"),
|
|
9106
|
+
paletteChoice("high-contrast-ink"),
|
|
9107
|
+
paletteChoice("warm-neutral-cream")
|
|
9108
|
+
]
|
|
9109
|
+
}),
|
|
9110
|
+
defineCuratedSiteStyle({
|
|
9111
|
+
id: "site-style:practical-services",
|
|
9112
|
+
name: "Practical Services",
|
|
9113
|
+
description: "Efficient, plainspoken, and conversion-focused for trades and everyday services.",
|
|
9114
|
+
generationBrief: "Make services, location, trust signals, and contact paths obvious. Keep copy brief and avoid ornate visual treatments.",
|
|
9115
|
+
siteCreatorSelection: { kind: "primary_goal_support" },
|
|
9116
|
+
selectionKeywordRules: [
|
|
9117
|
+
{ kind: "word", value: "repair" },
|
|
9118
|
+
{ kind: "substring", value: "plumb" },
|
|
9119
|
+
{ kind: "substring", value: "electric" },
|
|
9120
|
+
{ kind: "word", value: "cleaning" },
|
|
9121
|
+
{ kind: "substring", value: "landscap" },
|
|
9122
|
+
{ kind: "substring", value: "contractor" }
|
|
9123
|
+
],
|
|
9124
|
+
tokenRecipes: {
|
|
9125
|
+
palette: "brand-led",
|
|
9126
|
+
contrast: "maximum",
|
|
9127
|
+
radius: "soft",
|
|
9128
|
+
shadow: "subtle",
|
|
9129
|
+
typography: "clean-sans",
|
|
9130
|
+
spacing: "compact",
|
|
9131
|
+
motion: "none"
|
|
9132
|
+
},
|
|
9133
|
+
compositionBudget: quietBudget,
|
|
9134
|
+
recommendedHeaderLookIds: [
|
|
9135
|
+
"practical-utility",
|
|
9136
|
+
"brand-solid",
|
|
9137
|
+
"clean-base"
|
|
9138
|
+
],
|
|
9139
|
+
buttonPersonalityChoices: [
|
|
9140
|
+
buttonChoice("confident-chip"),
|
|
9141
|
+
buttonChoice("pebble"),
|
|
9142
|
+
buttonChoice("ink-stamp")
|
|
9143
|
+
],
|
|
9144
|
+
paletteVariantChoices: [
|
|
9145
|
+
paletteChoice("brand-led-cool"),
|
|
9146
|
+
paletteChoice("high-contrast-ink"),
|
|
9147
|
+
paletteChoice("brand-led-warm")
|
|
9148
|
+
]
|
|
9149
|
+
}),
|
|
9150
|
+
defineCuratedSiteStyle({
|
|
9151
|
+
id: "site-style:modern-wellness",
|
|
9152
|
+
name: "Modern Wellness",
|
|
9153
|
+
description: "Natural, current, and reassuring for practitioners, studios, and wellbeing offers.",
|
|
9154
|
+
generationBrief: "Keep the tone warm and practical. Use gentle section variation, natural materials, and inclusive copy without making medical claims.",
|
|
9155
|
+
tokenRecipes: {
|
|
9156
|
+
palette: "soft-natural",
|
|
9157
|
+
contrast: "standard",
|
|
9158
|
+
radius: "rounded",
|
|
9159
|
+
shadow: "subtle",
|
|
9160
|
+
typography: "clean-sans",
|
|
9161
|
+
spacing: "airy",
|
|
9162
|
+
motion: "subtle"
|
|
9163
|
+
},
|
|
9164
|
+
compositionBudget: balancedBudget,
|
|
9165
|
+
recommendedHeaderLookIds: [
|
|
9166
|
+
"centered-calm",
|
|
9167
|
+
"minimal-transparent",
|
|
9168
|
+
"clean-base"
|
|
9169
|
+
],
|
|
9170
|
+
buttonPersonalityChoices: [
|
|
9171
|
+
buttonChoice("soft-pill"),
|
|
9172
|
+
buttonChoice("pebble"),
|
|
9173
|
+
buttonChoice("confident-chip")
|
|
9174
|
+
],
|
|
9175
|
+
paletteVariantChoices: [
|
|
9176
|
+
paletteChoice("soft-natural-sage"),
|
|
9177
|
+
paletteChoice("soft-natural-stone"),
|
|
9178
|
+
paletteChoice("warm-neutral-forest")
|
|
9179
|
+
]
|
|
9180
|
+
}),
|
|
9181
|
+
defineCuratedSiteStyle({
|
|
9182
|
+
id: "site-style:quiet-practice",
|
|
9183
|
+
name: "Quiet Practice",
|
|
9184
|
+
description: "Grounded, calm, and practical for small appointment-first practices.",
|
|
9185
|
+
generationBrief: "Make services, practitioner trust, preparation notes, and booking routes easy to scan. Keep the tone warm and specific, with quiet confidence rather than spa cliches or medical claims.",
|
|
9186
|
+
siteCreatorSelection: {
|
|
9187
|
+
kind: "site_creator_keyword_heuristic",
|
|
9188
|
+
priority: 30
|
|
9189
|
+
},
|
|
9190
|
+
selectionKeywordRules: [
|
|
9191
|
+
{ kind: "substring", value: "massage" },
|
|
9192
|
+
{ kind: "word", value: "bodywork" },
|
|
9193
|
+
{ kind: "phrase", value: "appointment practice" },
|
|
9194
|
+
{ kind: "phrase", value: "appointment-first" },
|
|
9195
|
+
{ kind: "substring", value: "practitioner" },
|
|
9196
|
+
{ kind: "substring", value: "therap" },
|
|
9197
|
+
{ kind: "substring", value: "clinic" },
|
|
9198
|
+
{ kind: "phrase", value: "wellness practice" }
|
|
9199
|
+
],
|
|
9200
|
+
tokenRecipes: {
|
|
9201
|
+
palette: "soft-natural",
|
|
9202
|
+
contrast: "standard",
|
|
9203
|
+
radius: "soft",
|
|
9204
|
+
shadow: "subtle",
|
|
9205
|
+
typography: "clean-sans",
|
|
9206
|
+
spacing: "regular",
|
|
9207
|
+
motion: "subtle"
|
|
9208
|
+
},
|
|
9209
|
+
compositionBudget: quietBudget,
|
|
9210
|
+
recommendedHeaderLookIds: [
|
|
9211
|
+
"practical-utility",
|
|
9212
|
+
"clean-base",
|
|
9213
|
+
"centered-calm"
|
|
9214
|
+
],
|
|
9215
|
+
buttonPersonalityChoices: [
|
|
9216
|
+
buttonChoice("pebble"),
|
|
9217
|
+
buttonChoice("soft-pill"),
|
|
9218
|
+
buttonChoice("editorial-link")
|
|
9219
|
+
],
|
|
9220
|
+
paletteVariantChoices: [
|
|
9221
|
+
paletteChoice("soft-natural-stone"),
|
|
9222
|
+
paletteChoice("soft-natural-sage"),
|
|
9223
|
+
paletteChoice("warm-neutral-clay")
|
|
9224
|
+
]
|
|
9225
|
+
}),
|
|
9226
|
+
defineCuratedSiteStyle({
|
|
9227
|
+
id: "site-style:personal-retreat-journal",
|
|
9228
|
+
name: "Personal Retreat Journal",
|
|
9229
|
+
description: "Warm, story-led, and readable for solo practitioners with mixed offers.",
|
|
9230
|
+
generationBrief: "Center the practitioner as the guide, then make private sessions, classes, retreats, and resources feel like clear pathways. Keep retreat copy grounded and practical, with enough editorial warmth for longer reading.",
|
|
9231
|
+
siteCreatorSelection: {
|
|
9232
|
+
kind: "site_creator_keyword_heuristic",
|
|
9233
|
+
priority: 40
|
|
9234
|
+
},
|
|
9235
|
+
selectionKeywordRules: [
|
|
9236
|
+
{ kind: "substring", value: "retreat" },
|
|
9237
|
+
{ kind: "phrase", value: "solo practitioner" },
|
|
9238
|
+
{ kind: "phrase", value: "personal brand" },
|
|
9239
|
+
{ kind: "substring", value: "teacher" },
|
|
9240
|
+
{ kind: "substring", value: "coach" },
|
|
9241
|
+
{ kind: "phrase", value: "retreat resources" },
|
|
9242
|
+
{ kind: "substring", value: "journal" }
|
|
9243
|
+
],
|
|
9244
|
+
tokenRecipes: {
|
|
9245
|
+
palette: "warm-neutral",
|
|
9246
|
+
contrast: "standard",
|
|
9247
|
+
radius: "soft",
|
|
9248
|
+
shadow: "subtle",
|
|
9249
|
+
typography: "serif-editorial",
|
|
9250
|
+
spacing: "airy",
|
|
9251
|
+
motion: "subtle"
|
|
9252
|
+
},
|
|
9253
|
+
compositionBudget: balancedBudget,
|
|
9254
|
+
recommendedHeaderLookIds: [
|
|
9255
|
+
"serif-line",
|
|
9256
|
+
"centered-calm",
|
|
9257
|
+
"minimal-transparent"
|
|
9258
|
+
],
|
|
9259
|
+
buttonPersonalityChoices: [
|
|
9260
|
+
buttonChoice("editorial-link"),
|
|
9261
|
+
buttonChoice("soft-pill"),
|
|
9262
|
+
buttonChoice("brushed-wash")
|
|
9263
|
+
],
|
|
9264
|
+
paletteVariantChoices: [
|
|
9265
|
+
paletteChoice("warm-neutral-forest"),
|
|
9266
|
+
paletteChoice("warm-neutral-clay"),
|
|
9267
|
+
paletteChoice("soft-natural-stone")
|
|
9268
|
+
]
|
|
9269
|
+
}),
|
|
9270
|
+
defineCuratedSiteStyle({
|
|
9271
|
+
id: "site-style:tactile-workshop",
|
|
9272
|
+
name: "Tactile Workshop",
|
|
9273
|
+
description: "Bright, hands-on, and image-led for maker studios, workshops, and creative classes.",
|
|
9274
|
+
generationBrief: "Lead with objects, materials, studio process, and practical booking detail. Keep the tone warm and direct, with useful mess, clear dates, and enough gallery rhythm to feel like a real creative studio.",
|
|
9275
|
+
siteCreatorSelection: {
|
|
9276
|
+
kind: "site_creator_keyword_heuristic",
|
|
9277
|
+
priority: 50
|
|
9278
|
+
},
|
|
9279
|
+
selectionKeywordRules: [
|
|
9280
|
+
{ kind: "substring", value: "ceramic" },
|
|
9281
|
+
{ kind: "word", value: "pottery" },
|
|
9282
|
+
{ kind: "phrase", value: "maker studio" },
|
|
9283
|
+
{ kind: "phrase", value: "craft class" },
|
|
9284
|
+
{ kind: "phrase", value: "craft workshop" },
|
|
9285
|
+
{ kind: "word", value: "clay" },
|
|
9286
|
+
{ kind: "word", value: "kiln" }
|
|
9287
|
+
],
|
|
9288
|
+
tokenRecipes: {
|
|
9289
|
+
palette: "brand-led",
|
|
9290
|
+
contrast: "standard",
|
|
9291
|
+
radius: "soft",
|
|
9292
|
+
shadow: "subtle",
|
|
9293
|
+
typography: "friendly-sans",
|
|
9294
|
+
spacing: "regular",
|
|
9295
|
+
motion: "subtle"
|
|
9296
|
+
},
|
|
9297
|
+
compositionBudget: balancedBudget,
|
|
9298
|
+
recommendedHeaderLookIds: [
|
|
9299
|
+
"brand-solid",
|
|
9300
|
+
"practical-utility",
|
|
9301
|
+
"clean-base"
|
|
9302
|
+
],
|
|
9303
|
+
recommendedFooterLookIds: [
|
|
9304
|
+
"site-footer-brand-two-band",
|
|
9305
|
+
"footer-muted-grounding"
|
|
9306
|
+
],
|
|
9307
|
+
buttonPersonalityChoices: [
|
|
9308
|
+
buttonChoice("pebble"),
|
|
9309
|
+
buttonChoice("confident-chip"),
|
|
9310
|
+
buttonChoice("ink-stamp"),
|
|
9311
|
+
buttonChoice("editorial-link")
|
|
9312
|
+
],
|
|
9313
|
+
paletteVariantChoices: [
|
|
9314
|
+
paletteChoice("brand-led-warm"),
|
|
9315
|
+
paletteChoice("brand-led-cool"),
|
|
9316
|
+
paletteChoice("soft-natural-watercolor"),
|
|
9317
|
+
paletteChoice("warm-neutral-clay")
|
|
9318
|
+
]
|
|
9319
|
+
}),
|
|
9320
|
+
defineCuratedSiteStyle({
|
|
9321
|
+
id: SOFT_EARTH_SITE_STYLE_ID,
|
|
9322
|
+
name: "Soft Earth",
|
|
9323
|
+
description: "Warm, grounded, and editorial for yoga studios, retreats, and wellbeing communities.",
|
|
9324
|
+
generationBrief: "Use cream space, terracotta CTAs, olive quote bands, natural imagery, generous but composed spacing, and editorial serif headings. Prefer a real intro section, image-led offering cards, warm community quotes, and an FAQ with a full-width intro above two columns of questions when content allows.",
|
|
9325
|
+
siteCreatorSelection: {
|
|
9326
|
+
kind: "site_creator_keyword_heuristic",
|
|
9327
|
+
priority: 45
|
|
9328
|
+
},
|
|
9329
|
+
selectionKeywordRules: [
|
|
9330
|
+
{ kind: "word", value: "meditation" },
|
|
9331
|
+
{ kind: "word", value: "wellbeing" },
|
|
9332
|
+
{ kind: "substring", value: "retreat" },
|
|
9333
|
+
{ kind: "phrase", value: "yoga studio" },
|
|
9334
|
+
{ kind: "phrase", value: "mindful movement" }
|
|
9335
|
+
],
|
|
9336
|
+
tokenRecipes: {
|
|
9337
|
+
palette: "warm-neutral",
|
|
9338
|
+
contrast: "standard",
|
|
9339
|
+
radius: "soft",
|
|
9340
|
+
shadow: "subtle",
|
|
9341
|
+
typography: "serif-editorial",
|
|
9342
|
+
spacing: "airy",
|
|
9343
|
+
motion: "subtle"
|
|
9344
|
+
},
|
|
9345
|
+
compositionBudget: balancedBudget,
|
|
9346
|
+
themeOverrides: {
|
|
9347
|
+
typography: {
|
|
9348
|
+
body: {
|
|
9349
|
+
family: "Inter, system-ui, sans-serif",
|
|
9350
|
+
size: "md",
|
|
9351
|
+
weight: "regular",
|
|
9352
|
+
lineHeight: "relaxed",
|
|
9353
|
+
letterSpacing: "normal"
|
|
9354
|
+
},
|
|
9355
|
+
headings: {
|
|
9356
|
+
default: {
|
|
9357
|
+
family: '"Cormorant Garamond", Georgia, serif',
|
|
9358
|
+
weight: "regular",
|
|
9359
|
+
lineHeight: "normal",
|
|
9360
|
+
letterSpacing: "normal",
|
|
9361
|
+
colorToken: "text",
|
|
9362
|
+
italic: null,
|
|
9363
|
+
case: null
|
|
9364
|
+
},
|
|
9365
|
+
h1: {
|
|
9366
|
+
size: "xl",
|
|
9367
|
+
weight: "regular",
|
|
9368
|
+
lineHeight: "normal",
|
|
9369
|
+
letterSpacing: "normal",
|
|
9370
|
+
italic: null
|
|
9371
|
+
},
|
|
9372
|
+
h2: {
|
|
9373
|
+
size: "lg",
|
|
9374
|
+
weight: "regular",
|
|
9375
|
+
lineHeight: "normal",
|
|
9376
|
+
letterSpacing: "normal",
|
|
9377
|
+
italic: null
|
|
9378
|
+
},
|
|
9379
|
+
h3: {
|
|
9380
|
+
size: "md",
|
|
9381
|
+
weight: "regular",
|
|
9382
|
+
lineHeight: "normal",
|
|
9383
|
+
letterSpacing: "normal",
|
|
9384
|
+
italic: null
|
|
9385
|
+
}
|
|
9386
|
+
},
|
|
9387
|
+
scale: "majorThird"
|
|
9388
|
+
},
|
|
9389
|
+
bodyText: {
|
|
9390
|
+
intro: {
|
|
9391
|
+
paragraphSize: "default",
|
|
9392
|
+
headingSize: "editorial"
|
|
9393
|
+
}
|
|
9394
|
+
},
|
|
9395
|
+
accordions: softEarthAccordionSystem
|
|
9396
|
+
},
|
|
9397
|
+
defaultBlockVariants: {
|
|
9398
|
+
"block.faq": "question-columns"
|
|
9399
|
+
},
|
|
9400
|
+
recommendedAppearancePresetIds: [
|
|
9401
|
+
"hero-brand-scrim",
|
|
9402
|
+
"intro-organic-statement",
|
|
9403
|
+
"feature-cards-raised-rule",
|
|
9404
|
+
"events-lined-panel",
|
|
9405
|
+
"testimonials-brand-background-quotes",
|
|
9406
|
+
"contact-form-panel"
|
|
9407
|
+
],
|
|
9408
|
+
recommendedHeaderLookIds: [
|
|
9409
|
+
"centered-calm",
|
|
9410
|
+
"minimal-transparent",
|
|
9411
|
+
"serif-line"
|
|
9412
|
+
],
|
|
9413
|
+
recommendedFooterLookIds: [
|
|
9414
|
+
"footer-muted-grounding",
|
|
9415
|
+
"site-footer-brand-two-band"
|
|
9416
|
+
],
|
|
9417
|
+
buttonPersonalityChoices: [
|
|
9418
|
+
buttonChoice("earth-pill"),
|
|
9419
|
+
buttonChoice("soft-pill"),
|
|
9420
|
+
buttonChoice("pebble"),
|
|
9421
|
+
buttonChoice("editorial-link")
|
|
9422
|
+
],
|
|
9423
|
+
paletteVariantChoices: [
|
|
9424
|
+
paletteChoice("warm-neutral-soft-earth"),
|
|
9425
|
+
paletteChoice("warm-neutral-clay"),
|
|
9426
|
+
paletteChoice("warm-neutral-forest"),
|
|
9427
|
+
paletteChoice("soft-natural-sage")
|
|
9428
|
+
]
|
|
9429
|
+
}),
|
|
9430
|
+
defineCuratedSiteStyle({
|
|
9431
|
+
id: "site-style:bold-launch",
|
|
9432
|
+
name: "Bold Launch",
|
|
9433
|
+
description: "High-energy and punchy for launches, campaigns, and creative offers.",
|
|
9434
|
+
generationBrief: "Use crisp positioning, bold hero structure, strong calls to action, and confident visual rhythm. Keep it precise, not shouty.",
|
|
9435
|
+
siteCreatorSelection: {
|
|
9436
|
+
kind: "site_creator_keyword_heuristic",
|
|
9437
|
+
priority: 10
|
|
9438
|
+
},
|
|
9439
|
+
selectionKeywordRules: [
|
|
9440
|
+
{ kind: "substring", value: "launch" },
|
|
9441
|
+
{ kind: "substring", value: "campaign" },
|
|
9442
|
+
{ kind: "word", value: "preorder" },
|
|
9443
|
+
{ kind: "phrase", value: "pre-order" },
|
|
9444
|
+
{ kind: "substring", value: "waitlist" },
|
|
9445
|
+
{ kind: "word", value: "drop" }
|
|
9446
|
+
],
|
|
9447
|
+
tokenRecipes: {
|
|
9448
|
+
palette: "high-contrast",
|
|
9449
|
+
contrast: "maximum",
|
|
9450
|
+
radius: "pill",
|
|
9451
|
+
shadow: "layered",
|
|
9452
|
+
typography: "clean-sans",
|
|
9453
|
+
spacing: "regular",
|
|
9454
|
+
motion: "expressive"
|
|
9455
|
+
},
|
|
9456
|
+
compositionBudget: expressiveBudget,
|
|
9457
|
+
recommendedHeaderLookIds: [
|
|
9458
|
+
"transparent-overlay",
|
|
9459
|
+
"floating-glass",
|
|
9460
|
+
"brand-solid"
|
|
9461
|
+
],
|
|
9462
|
+
buttonPersonalityChoices: [
|
|
9463
|
+
buttonChoice("ink-stamp"),
|
|
9464
|
+
buttonChoice("confident-chip"),
|
|
9465
|
+
buttonChoice("brushed-wash"),
|
|
9466
|
+
buttonChoice("pebble")
|
|
9467
|
+
],
|
|
9468
|
+
paletteVariantChoices: [
|
|
9469
|
+
paletteChoice("high-contrast-monochrome"),
|
|
9470
|
+
paletteChoice("high-contrast-ink"),
|
|
9471
|
+
paletteChoice("brand-led-jewel"),
|
|
9472
|
+
paletteChoice("brand-led-warm")
|
|
9473
|
+
]
|
|
9474
|
+
}),
|
|
9475
|
+
defineCuratedSiteStyle({
|
|
9476
|
+
id: "site-style:south-west-twerk-school",
|
|
9477
|
+
name: "South West Twerk School",
|
|
9478
|
+
description: "Energetic, editorial, and high-contrast for a branded dance school presence.",
|
|
9479
|
+
generationBrief: "Use confident rhythm, bold burgundy-and-gold accents, large editorial intro copy, strong booking routes, and dark feature sections where proof or forms need emphasis.",
|
|
9480
|
+
tokenRecipes: {
|
|
9481
|
+
palette: "brand-led",
|
|
9482
|
+
contrast: "maximum",
|
|
9483
|
+
radius: "soft",
|
|
9484
|
+
shadow: "layered",
|
|
9485
|
+
typography: "clean-sans",
|
|
9486
|
+
spacing: "airy",
|
|
9487
|
+
motion: "expressive"
|
|
9488
|
+
},
|
|
9489
|
+
compositionBudget: expressiveBudget,
|
|
9490
|
+
typographyPresetChoices: [
|
|
9491
|
+
typographyChoice("typography-preset:bold-display"),
|
|
9492
|
+
typographyChoice("typography-preset:modern-sans"),
|
|
9493
|
+
typographyChoice("typography-preset:luxe-contrast")
|
|
9494
|
+
],
|
|
9495
|
+
defaultTypographyPresetId: "typography-preset:bold-display",
|
|
9496
|
+
themeOverrides: {
|
|
9497
|
+
bodyText: {
|
|
9498
|
+
intro: {
|
|
9499
|
+
paragraphSize: "editorial",
|
|
9500
|
+
headingSize: "editorial"
|
|
9501
|
+
}
|
|
9502
|
+
},
|
|
9503
|
+
inputs: expressiveUnderlineInputs
|
|
9504
|
+
},
|
|
9505
|
+
recommendedAppearancePresetIds: [
|
|
9506
|
+
"hero-brand-scrim-fixed-frame",
|
|
9507
|
+
"body-text-editorial-intro",
|
|
9508
|
+
"schedule-details-brand-depth",
|
|
9509
|
+
"testimonials-accent-quote-cards",
|
|
9510
|
+
"contact-form-brand-depth-card"
|
|
9511
|
+
],
|
|
9512
|
+
recommendedHeaderLookIds: [
|
|
9513
|
+
"brand-solid",
|
|
9514
|
+
"transparent-overlay",
|
|
9515
|
+
"practical-utility"
|
|
9516
|
+
],
|
|
9517
|
+
recommendedFooterLookIds: [
|
|
9518
|
+
"site-footer-brand-two-band",
|
|
9519
|
+
"footer-muted-grounding"
|
|
9520
|
+
],
|
|
9521
|
+
buttonPersonalityChoices: [
|
|
9522
|
+
buttonChoice("showtime-pill"),
|
|
9523
|
+
buttonChoice("confident-chip"),
|
|
9524
|
+
buttonChoice("ink-stamp"),
|
|
9525
|
+
buttonChoice("brushed-wash")
|
|
9526
|
+
],
|
|
9527
|
+
paletteVariantChoices: [
|
|
9528
|
+
paletteChoice("brand-led-burgundy-gold"),
|
|
9529
|
+
paletteChoice("brand-led-jewel"),
|
|
9530
|
+
paletteChoice("brand-led-warm"),
|
|
9531
|
+
paletteChoice("high-contrast-ink")
|
|
9532
|
+
]
|
|
9533
|
+
})
|
|
9534
|
+
];
|
|
9535
|
+
var curatedSiteStylesById = new Map(
|
|
9536
|
+
curatedSiteStyles.map((style) => [style.id, style])
|
|
6173
9537
|
);
|
|
6174
|
-
var rawAtRuleSchema = z10.object({
|
|
6175
|
-
id: ruleIdSchema,
|
|
6176
|
-
type: z10.literal("raw"),
|
|
6177
|
-
css: rawCssSchema
|
|
6178
|
-
});
|
|
6179
|
-
var customCssAtRuleSchema = z10.discriminatedUnion("type", [
|
|
6180
|
-
keyframesAtRuleSchema,
|
|
6181
|
-
fontFaceAtRuleSchema,
|
|
6182
|
-
mediaAtRuleSchema,
|
|
6183
|
-
supportsAtRuleSchema,
|
|
6184
|
-
rawAtRuleSchema
|
|
6185
|
-
]);
|
|
6186
|
-
var customCssAtRulesSchema = z10.array(customCssAtRuleSchema).optional();
|
|
6187
|
-
|
|
6188
|
-
// ../theme-core/src/shared/componentStyles.ts
|
|
6189
|
-
import { z as z11 } from "zod";
|
|
6190
|
-
var componentBorderSchema = z11.object({
|
|
6191
|
-
width: z11.enum(["none", "hairline", "thin", "medium", "thick"]).default("none"),
|
|
6192
|
-
style: z11.enum(["solid", "dashed"]).default("solid"),
|
|
6193
|
-
colorToken: themeColorTokenSchema.optional()
|
|
6194
|
-
// defaults to "border" if not set
|
|
6195
|
-
});
|
|
6196
|
-
var componentShadowSchema = z11.object({
|
|
6197
|
-
elevation: z11.enum(["none", "sm", "md", "lg", "xl", "2xl"]).default("sm")
|
|
6198
|
-
});
|
|
6199
9538
|
|
|
6200
9539
|
// ../theme-core/src/responsive/breakpoints.ts
|
|
6201
9540
|
var BREAKPOINT_SM = 640;
|
|
@@ -6299,8 +9638,8 @@ function AltchaWidget({
|
|
|
6299
9638
|
}));
|
|
6300
9639
|
containerRef.current.appendChild(widget);
|
|
6301
9640
|
setIsLoaded(true);
|
|
6302
|
-
}).catch((
|
|
6303
|
-
console.error("Failed to load ALTCHA widget:",
|
|
9641
|
+
}).catch((err) => {
|
|
9642
|
+
console.error("Failed to load ALTCHA widget:", err);
|
|
6304
9643
|
});
|
|
6305
9644
|
return () => {
|
|
6306
9645
|
if (widget && containerRef.current) {
|
|
@@ -6540,10 +9879,10 @@ function useAvailableDates({
|
|
|
6540
9879
|
start: append && prev ? prev.start : data.startDate,
|
|
6541
9880
|
end: data.endDate
|
|
6542
9881
|
}));
|
|
6543
|
-
} catch (
|
|
9882
|
+
} catch (err) {
|
|
6544
9883
|
if (requestId !== requestIdRef.current) return;
|
|
6545
9884
|
setError(
|
|
6546
|
-
|
|
9885
|
+
err instanceof Error ? err.message : "Failed to load available dates"
|
|
6547
9886
|
);
|
|
6548
9887
|
} finally {
|
|
6549
9888
|
if (mode === "refresh" && requestId === requestIdRef.current) {
|
|
@@ -6659,10 +9998,10 @@ function useAvailableSlots({
|
|
|
6659
9998
|
}))
|
|
6660
9999
|
);
|
|
6661
10000
|
setHasLoaded(true);
|
|
6662
|
-
} catch (
|
|
10001
|
+
} catch (err) {
|
|
6663
10002
|
if (requestId !== requestIdRef.current) return;
|
|
6664
10003
|
setError(
|
|
6665
|
-
|
|
10004
|
+
err instanceof Error ? err.message : "Failed to load available times"
|
|
6666
10005
|
);
|
|
6667
10006
|
} finally {
|
|
6668
10007
|
if (mode === "refresh" && requestId === requestIdRef.current) {
|
|
@@ -6701,28 +10040,24 @@ function bookingSubmissionReducer(state, action) {
|
|
|
6701
10040
|
switch (action.type) {
|
|
6702
10041
|
case "submission-started":
|
|
6703
10042
|
return {
|
|
6704
|
-
...state,
|
|
6705
|
-
status: { tag: "submitting" }
|
|
6706
|
-
feedback: { tag: "idle" }
|
|
10043
|
+
...clearWorkflowFeedback(state),
|
|
10044
|
+
status: { tag: "submitting" }
|
|
6707
10045
|
};
|
|
6708
10046
|
case "submission-succeeded":
|
|
6709
10047
|
return {
|
|
6710
10048
|
status: { tag: "idle" },
|
|
6711
|
-
feedback:
|
|
10049
|
+
feedback: reportWorkflowSuccess(state, action.message).feedback
|
|
6712
10050
|
};
|
|
6713
10051
|
case "submission-failed":
|
|
6714
10052
|
case "issue-reported":
|
|
6715
10053
|
return {
|
|
6716
10054
|
status: { tag: "idle" },
|
|
6717
|
-
feedback:
|
|
10055
|
+
feedback: reportWorkflowError(state, action.message).feedback
|
|
6718
10056
|
};
|
|
6719
10057
|
case "feedback-cleared":
|
|
6720
|
-
return
|
|
6721
|
-
...state,
|
|
6722
|
-
feedback: { tag: "idle" }
|
|
6723
|
-
};
|
|
10058
|
+
return clearWorkflowFeedback(state);
|
|
6724
10059
|
default:
|
|
6725
|
-
return
|
|
10060
|
+
return assertNever11(action);
|
|
6726
10061
|
}
|
|
6727
10062
|
}
|
|
6728
10063
|
function selectIsSubmitting(state) {
|
|
@@ -6766,7 +10101,7 @@ function useBookingSubmission(_siteId) {
|
|
|
6766
10101
|
type: "submission-succeeded",
|
|
6767
10102
|
message: response.type === "checkout_redirect" ? "Redirecting to secure checkout..." : "Booking submitted successfully."
|
|
6768
10103
|
});
|
|
6769
|
-
return
|
|
10104
|
+
return okWith2(response);
|
|
6770
10105
|
} catch (error) {
|
|
6771
10106
|
console.error("Booking submission error:", error);
|
|
6772
10107
|
const message = error instanceof Error ? error.message : "Failed to book appointment";
|
|
@@ -6774,7 +10109,7 @@ function useBookingSubmission(_siteId) {
|
|
|
6774
10109
|
type: "submission-failed",
|
|
6775
10110
|
message
|
|
6776
10111
|
});
|
|
6777
|
-
return
|
|
10112
|
+
return err2(message);
|
|
6778
10113
|
}
|
|
6779
10114
|
};
|
|
6780
10115
|
return {
|
|
@@ -7031,7 +10366,7 @@ function buildBookingPaymentOptionViewModel(input) {
|
|
|
7031
10366
|
};
|
|
7032
10367
|
}
|
|
7033
10368
|
default:
|
|
7034
|
-
return
|
|
10369
|
+
return assertNever11(input.option);
|
|
7035
10370
|
}
|
|
7036
10371
|
}
|
|
7037
10372
|
function buildInstalmentSchedulePreview(input) {
|
|
@@ -7088,7 +10423,7 @@ function buildInstalmentSchedulePreview(input) {
|
|
|
7088
10423
|
})));
|
|
7089
10424
|
}
|
|
7090
10425
|
default:
|
|
7091
|
-
return
|
|
10426
|
+
return assertNever11(input.option.plan);
|
|
7092
10427
|
}
|
|
7093
10428
|
}
|
|
7094
10429
|
function getPaymentCadenceLabel(plan) {
|
|
@@ -7315,7 +10650,7 @@ function bookingFlowReducer(state, event) {
|
|
|
7315
10650
|
case "reset":
|
|
7316
10651
|
return event.initial;
|
|
7317
10652
|
default:
|
|
7318
|
-
return
|
|
10653
|
+
return assertNever11(event);
|
|
7319
10654
|
}
|
|
7320
10655
|
}
|
|
7321
10656
|
function clearAvailabilityFeedback(feedback) {
|
|
@@ -7444,7 +10779,7 @@ function validateBookingStep(input) {
|
|
|
7444
10779
|
return Object.keys(errors).length > 0 ? { ok: false, errors: createFieldBookingValidationErrors(errors) } : { ok: true };
|
|
7445
10780
|
}
|
|
7446
10781
|
default:
|
|
7447
|
-
return
|
|
10782
|
+
return assertNever11(input.stepId);
|
|
7448
10783
|
}
|
|
7449
10784
|
}
|
|
7450
10785
|
function validateBookingFields(input) {
|
|
@@ -7806,7 +11141,7 @@ function resolveAppointmentPackagesModel(input) {
|
|
|
7806
11141
|
};
|
|
7807
11142
|
}
|
|
7808
11143
|
default:
|
|
7809
|
-
return
|
|
11144
|
+
return assertNever11(input.state);
|
|
7810
11145
|
}
|
|
7811
11146
|
}
|
|
7812
11147
|
function toHeadlessEligibleAppointmentPackage(appointmentPackage) {
|
|
@@ -8545,7 +11880,7 @@ function pollingReducer(state, action) {
|
|
|
8545
11880
|
case "timeout":
|
|
8546
11881
|
return state;
|
|
8547
11882
|
default:
|
|
8548
|
-
return
|
|
11883
|
+
return assertNever11(state);
|
|
8549
11884
|
}
|
|
8550
11885
|
case "polling-timed-out":
|
|
8551
11886
|
return {
|
|
@@ -8554,7 +11889,7 @@ function pollingReducer(state, action) {
|
|
|
8554
11889
|
error: new Error("Polling timed out")
|
|
8555
11890
|
};
|
|
8556
11891
|
default:
|
|
8557
|
-
return
|
|
11892
|
+
return assertNever11(action);
|
|
8558
11893
|
}
|
|
8559
11894
|
}
|
|
8560
11895
|
|
|
@@ -8619,13 +11954,13 @@ function usePolling(config) {
|
|
|
8619
11954
|
dispatch({ type: "polling-progressed", result: data });
|
|
8620
11955
|
isPollingRef.current = false;
|
|
8621
11956
|
return false;
|
|
8622
|
-
} catch (
|
|
11957
|
+
} catch (err) {
|
|
8623
11958
|
if (generation !== generationRef.current || !isActiveRef.current) {
|
|
8624
11959
|
isPollingRef.current = false;
|
|
8625
11960
|
return true;
|
|
8626
11961
|
}
|
|
8627
|
-
if (
|
|
8628
|
-
dispatch({ type: "polling-request-failed", error:
|
|
11962
|
+
if (err instanceof Error) {
|
|
11963
|
+
dispatch({ type: "polling-request-failed", error: err });
|
|
8629
11964
|
}
|
|
8630
11965
|
isPollingRef.current = false;
|
|
8631
11966
|
return false;
|
|
@@ -8799,32 +12134,130 @@ var TimeSlotSelector = ({
|
|
|
8799
12134
|
] });
|
|
8800
12135
|
};
|
|
8801
12136
|
|
|
8802
|
-
// ../blocks/src/system/runtime/
|
|
12137
|
+
// ../blocks/src/system/runtime/shared/components/DiscountCodeDisclosure.tsx
|
|
12138
|
+
import { useId } from "react";
|
|
8803
12139
|
import { jsx as jsx8, jsxs as jsxs6 } from "react/jsx-runtime";
|
|
8804
|
-
|
|
12140
|
+
var BLOCK_DISCOUNT_CODE_DISCLOSURE_CLASSES = {
|
|
12141
|
+
"course-registration": {
|
|
12142
|
+
root: "cr-discount",
|
|
12143
|
+
toggle: "cr-discount__toggle",
|
|
12144
|
+
form: "cr-discount__form",
|
|
12145
|
+
label: "cr-discount__label",
|
|
12146
|
+
row: "cr-discount__row",
|
|
12147
|
+
input: "cr-discount__input",
|
|
12148
|
+
apply: "cr-discount__apply",
|
|
12149
|
+
remove: "cr-discount__remove",
|
|
12150
|
+
hint: "cr-discount__hint",
|
|
12151
|
+
feedback: "cr-discount__feedback"
|
|
12152
|
+
},
|
|
12153
|
+
"event-registration": {
|
|
12154
|
+
root: "er-discount",
|
|
12155
|
+
toggle: "er-discount__toggle",
|
|
12156
|
+
form: "er-discount__form",
|
|
12157
|
+
label: "er-discount__label",
|
|
12158
|
+
row: "er-discount__row",
|
|
12159
|
+
input: "er-discount__input",
|
|
12160
|
+
apply: "er-discount__apply",
|
|
12161
|
+
remove: "er-discount__remove",
|
|
12162
|
+
hint: "er-discount__hint",
|
|
12163
|
+
feedback: "er-discount__feedback"
|
|
12164
|
+
}
|
|
12165
|
+
};
|
|
12166
|
+
var textLinkButtonClassName = ["button", "link"].join("-");
|
|
12167
|
+
var themeFormClasses = {
|
|
12168
|
+
root: "rb-flex rb-flex-col rb-gap-2 rb-mb-4",
|
|
12169
|
+
toggle: `${textLinkButtonClassName} rb-self-start`,
|
|
12170
|
+
form: "rb-flex rb-flex-col rb-gap-2",
|
|
12171
|
+
label: "form-label",
|
|
12172
|
+
row: "rb-flex rb-flex-col rb-gap-2 rb-sm-flex-row",
|
|
12173
|
+
input: "form-input",
|
|
12174
|
+
apply: themeButtonClassName({ variant: "secondary", size: "sm" }),
|
|
12175
|
+
remove: themeButtonClassName({ variant: "secondary", size: "sm" }),
|
|
12176
|
+
hint: "rb-caption status-muted",
|
|
12177
|
+
feedback: "rb-caption"
|
|
12178
|
+
};
|
|
12179
|
+
function getDiscountCodeDisclosureClasses(surface) {
|
|
12180
|
+
if (surface === "theme-form") return themeFormClasses;
|
|
12181
|
+
return BLOCK_DISCOUNT_CODE_DISCLOSURE_CLASSES[surface];
|
|
12182
|
+
}
|
|
12183
|
+
function DiscountCodeDisclosure({
|
|
12184
|
+
surface,
|
|
8805
12185
|
isOpen,
|
|
8806
12186
|
code,
|
|
8807
12187
|
onOpen,
|
|
8808
12188
|
onChange,
|
|
8809
|
-
onRemove
|
|
12189
|
+
onRemove,
|
|
12190
|
+
onApply,
|
|
12191
|
+
id,
|
|
12192
|
+
toggleLabel = "Have a discount code?",
|
|
12193
|
+
label = "Discount code",
|
|
12194
|
+
placeholder = "Enter code",
|
|
12195
|
+
applyLabel = "Apply",
|
|
12196
|
+
removeLabel = "Remove",
|
|
12197
|
+
hint = "Applied at checkout.",
|
|
12198
|
+
feedback = null,
|
|
12199
|
+
isApplying = false,
|
|
12200
|
+
applyDisabled = false,
|
|
12201
|
+
disabled = false
|
|
8810
12202
|
}) {
|
|
8811
|
-
|
|
8812
|
-
|
|
8813
|
-
|
|
12203
|
+
const generatedId = useId();
|
|
12204
|
+
const inputId = id ?? `discount-code-${generatedId}`;
|
|
12205
|
+
const classes = getDiscountCodeDisclosureClasses(surface);
|
|
12206
|
+
const handleChange = (event) => {
|
|
12207
|
+
onChange(event.target.value);
|
|
12208
|
+
};
|
|
12209
|
+
const handleKeyDown = (event) => {
|
|
12210
|
+
if (!onApply || event.key !== "Enter") return;
|
|
12211
|
+
event.preventDefault();
|
|
12212
|
+
onApply();
|
|
12213
|
+
};
|
|
12214
|
+
const feedbackClassName = feedback ? `${classes.feedback} status-${feedback.tone}` : classes.feedback;
|
|
12215
|
+
return /* @__PURE__ */ jsx8("div", { className: classes.root, children: !isOpen ? /* @__PURE__ */ jsx8("button", { type: "button", className: classes.toggle, onClick: onOpen, children: toggleLabel }) : /* @__PURE__ */ jsxs6("div", { className: classes.form, children: [
|
|
12216
|
+
/* @__PURE__ */ jsx8("label", { htmlFor: inputId, className: classes.label, children: label }),
|
|
12217
|
+
/* @__PURE__ */ jsxs6("div", { className: classes.row, children: [
|
|
8814
12218
|
/* @__PURE__ */ jsx8(
|
|
8815
12219
|
"input",
|
|
8816
12220
|
{
|
|
8817
|
-
id:
|
|
8818
|
-
className:
|
|
12221
|
+
id: inputId,
|
|
12222
|
+
className: classes.input,
|
|
8819
12223
|
value: code,
|
|
8820
|
-
onChange:
|
|
8821
|
-
|
|
8822
|
-
|
|
12224
|
+
onChange: handleChange,
|
|
12225
|
+
onKeyDown: handleKeyDown,
|
|
12226
|
+
placeholder,
|
|
12227
|
+
autoComplete: "off",
|
|
12228
|
+
disabled: disabled || isApplying
|
|
8823
12229
|
}
|
|
8824
12230
|
),
|
|
8825
|
-
/* @__PURE__ */ jsx8(
|
|
12231
|
+
onApply ? /* @__PURE__ */ jsx8(
|
|
12232
|
+
"button",
|
|
12233
|
+
{
|
|
12234
|
+
type: "button",
|
|
12235
|
+
className: classes.apply,
|
|
12236
|
+
onClick: onApply,
|
|
12237
|
+
disabled: disabled || isApplying || applyDisabled,
|
|
12238
|
+
children: isApplying ? "Applying..." : applyLabel
|
|
12239
|
+
}
|
|
12240
|
+
) : null,
|
|
12241
|
+
/* @__PURE__ */ jsx8(
|
|
12242
|
+
"button",
|
|
12243
|
+
{
|
|
12244
|
+
type: "button",
|
|
12245
|
+
className: classes.remove,
|
|
12246
|
+
onClick: onRemove,
|
|
12247
|
+
disabled: disabled || isApplying,
|
|
12248
|
+
children: removeLabel
|
|
12249
|
+
}
|
|
12250
|
+
)
|
|
8826
12251
|
] }),
|
|
8827
|
-
/* @__PURE__ */ jsx8("p", { className:
|
|
12252
|
+
/* @__PURE__ */ jsx8("p", { className: classes.hint, children: hint }),
|
|
12253
|
+
feedback ? /* @__PURE__ */ jsx8(
|
|
12254
|
+
"p",
|
|
12255
|
+
{
|
|
12256
|
+
className: feedbackClassName,
|
|
12257
|
+
role: feedback.tone === "error" ? "alert" : "status",
|
|
12258
|
+
children: feedback.message
|
|
12259
|
+
}
|
|
12260
|
+
) : null
|
|
8828
12261
|
] }) });
|
|
8829
12262
|
}
|
|
8830
12263
|
|
|
@@ -8998,7 +12431,7 @@ function DefaultBookingStepContent({
|
|
|
8998
12431
|
case "custom-fields":
|
|
8999
12432
|
return /* @__PURE__ */ jsx10(DefaultDynamicFields, { fields: booking.fields.items, booking });
|
|
9000
12433
|
default:
|
|
9001
|
-
return
|
|
12434
|
+
return assertNever11(stepId);
|
|
9002
12435
|
}
|
|
9003
12436
|
}
|
|
9004
12437
|
function DefaultServiceSelectionStep({
|
|
@@ -9511,8 +12944,9 @@ function DefaultBookingDiscount({
|
|
|
9511
12944
|
if (!shouldShowDiscountSection) return null;
|
|
9512
12945
|
return /* @__PURE__ */ jsxs7("div", { className: "rb-mt-6", children: [
|
|
9513
12946
|
booking.discount.manualCodeEntryAllowed ? /* @__PURE__ */ jsx10(
|
|
9514
|
-
|
|
12947
|
+
DiscountCodeDisclosure,
|
|
9515
12948
|
{
|
|
12949
|
+
surface: "theme-form",
|
|
9516
12950
|
isOpen: booking.discount.isOpen,
|
|
9517
12951
|
code: booking.discount.code,
|
|
9518
12952
|
onOpen: () => booking.discount.setOpen(true),
|
|
@@ -10208,6 +13642,15 @@ ${root} {
|
|
|
10208
13642
|
`;
|
|
10209
13643
|
}
|
|
10210
13644
|
|
|
13645
|
+
// ../theme-core/src/runtime/themeCssVarNames.ts
|
|
13646
|
+
var THEME_RADIUS_CSS_VARS = {
|
|
13647
|
+
block: "--rb-block-radius",
|
|
13648
|
+
button: "--rb-button-radius",
|
|
13649
|
+
input: "--rb-input-radius",
|
|
13650
|
+
legacyCard: "--radius-card",
|
|
13651
|
+
legacyControl: "--radius-control"
|
|
13652
|
+
};
|
|
13653
|
+
|
|
10211
13654
|
// ../theme-core/src/blocks/vars/customer-portal.ts
|
|
10212
13655
|
function generateCustomerPortalVars({
|
|
10213
13656
|
themeId
|
|
@@ -10221,6 +13664,11 @@ ${root} {
|
|
|
10221
13664
|
--cp-muted: rgb(var(--tb-mutedText));
|
|
10222
13665
|
--cp-border: rgb(var(--tb-border));
|
|
10223
13666
|
--cp-shadow: var(--shadow-elev);
|
|
13667
|
+
--cp-primary: rgb(var(--tb-primary));
|
|
13668
|
+
--cp-primary-hover: rgb(var(--tb-primary-700, var(--tb-primary)));
|
|
13669
|
+
--cp-error: rgb(var(--tb-destructive));
|
|
13670
|
+
--cp-card-radius: var(${THEME_RADIUS_CSS_VARS.block}, var(${THEME_RADIUS_CSS_VARS.legacyCard}, 0.75rem));
|
|
13671
|
+
--cp-control-radius: var(${THEME_RADIUS_CSS_VARS.input}, var(${THEME_RADIUS_CSS_VARS.legacyControl}, 0.5rem));
|
|
10224
13672
|
|
|
10225
13673
|
/* Shared tab bar (underline style) */
|
|
10226
13674
|
--rb-tab-border-width: 1px;
|
|
@@ -10271,7 +13719,7 @@ ${root} {
|
|
|
10271
13719
|
--rb-modal-bg: var(--cp-card-bg);
|
|
10272
13720
|
--rb-modal-border: var(--cp-card-border);
|
|
10273
13721
|
--rb-modal-shadow: var(--shadow-lg, var(--shadow-elev));
|
|
10274
|
-
--rb-modal-radius: var(--
|
|
13722
|
+
--rb-modal-radius: var(--cp-card-radius);
|
|
10275
13723
|
--rb-modal-max-width: 560px;
|
|
10276
13724
|
|
|
10277
13725
|
/* Header */
|
|
@@ -10491,8 +13939,8 @@ function useBookingFormConfig(siteId, formId) {
|
|
|
10491
13939
|
} catch {
|
|
10492
13940
|
}
|
|
10493
13941
|
}
|
|
10494
|
-
} catch (
|
|
10495
|
-
console.error("Failed to load form:",
|
|
13942
|
+
} catch (err) {
|
|
13943
|
+
console.error("Failed to load form:", err);
|
|
10496
13944
|
if (mounted) {
|
|
10497
13945
|
setError("Failed to load booking form. Please try again later.");
|
|
10498
13946
|
}
|