@riverbankcms/sdk 0.60.3 → 0.60.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_dts/api/src/bookingVerticals.d.ts +1 -0
- package/dist/_dts/api/src/siteManagementEndpoints.d.ts +3 -39
- package/dist/_dts/api/src/siteRuntimeEndpoints.d.ts +2 -0
- package/dist/_dts/blocks/src/system/node/fragments/ctaButton.d.ts +2 -0
- package/dist/_dts/blocks/src/system/runtime/shared/themedButtonClass.d.ts +11 -0
- package/dist/_dts/content-editor/src/ui/editorUiStore.d.ts +10 -2
- package/dist/_dts/core/src/participants.d.ts +32 -1
- package/dist/_dts/core/src/rectification.d.ts +79 -0
- package/dist/_dts/db/src/generated/supabase/database.types.d.ts +6 -6
- package/dist/_dts/preview-next/src/client/preview/StyleConfigurator.state.d.ts +17 -15
- package/dist/_dts/sdk/src/client/types.d.ts +1 -0
- package/dist/_dts/sdk/src/version.d.ts +1 -1
- package/dist/_dts/theme-core/src/buttons/personalities/brushed-wash.d.ts +7 -2
- package/dist/_dts/theme-core/src/buttons/personalities/confident-chip.d.ts +7 -2
- package/dist/_dts/theme-core/src/buttons/personalities/editorial-link.d.ts +7 -2
- package/dist/_dts/theme-core/src/buttons/personalities/index.d.ts +86 -5
- package/dist/_dts/theme-core/src/buttons/personalities/ink-stamp.d.ts +7 -2
- package/dist/_dts/theme-core/src/buttons/personalities/pebble.d.ts +7 -2
- package/dist/_dts/theme-core/src/buttons/personalities/soft-pill.d.ts +7 -2
- package/dist/_dts/theme-core/src/buttons/personalities/types.d.ts +10 -10
- package/dist/_dts/theme-core/src/palette/variants/brand-led.d.ts +33 -9
- package/dist/_dts/theme-core/src/palette/variants/high-contrast.d.ts +33 -9
- package/dist/_dts/theme-core/src/palette/variants/index.d.ts +200 -4
- package/dist/_dts/theme-core/src/palette/variants/soft-natural.d.ts +33 -9
- package/dist/_dts/theme-core/src/palette/variants/types.d.ts +10 -10
- package/dist/_dts/theme-core/src/palette/variants/warm-neutral.d.ts +33 -9
- package/dist/_dts/theme-core/src/site-styles/curatedChoices.d.ts +27 -0
- package/dist/_dts/theme-core/src/site-styles/curatedSiteStyles.d.ts +48 -194
- package/dist/_dts/theme-core/src/site-styles/index.d.ts +2 -1
- package/dist/_dts/theme-core/src/site-styles/previewCompiler.d.ts +12 -14
- package/dist/_dts/theme-core/src/site-styles/styleTags.d.ts +46 -0
- package/dist/_dts/ui/src/palette/ColorChooserDialog.d.ts +47 -0
- package/dist/_dts/ui/src/palette/ColorSlotButton.d.ts +15 -0
- package/dist/_dts/ui/src/palette/ColorSwatchButton.d.ts +15 -0
- package/dist/_dts/ui/src/palette/PaletteTokenEditor.d.ts +50 -0
- package/dist/_dts/ui/src/palette/hex.d.ts +23 -0
- package/dist/_dts/ui/src/palette/index.d.ts +14 -0
- package/dist/cli/index.mjs +1023 -923
- package/dist/client/client.mjs +3410 -3221
- package/dist/client/hooks.mjs +1625 -1564
- package/dist/client/rendering/client.mjs +132 -37
- package/dist/client/rendering/islands.mjs +91 -30
- package/dist/client/rendering.mjs +1237 -1049
- package/dist/preview-next/client/runtime.mjs +3095 -2736
- package/dist/server/components.mjs +2381 -2255
- package/dist/server/config-validation.mjs +1625 -1564
- package/dist/server/config.mjs +1625 -1564
- package/dist/server/data.mjs +1625 -1564
- package/dist/server/index.mjs +4 -3
- package/dist/server/next.mjs +3233 -3106
- package/dist/server/page-converter.mjs +1625 -1564
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/rendering/server.mjs +2381 -2255
- package/dist/server/rendering.mjs +2381 -2255
- package/dist/server/routing.mjs +2340 -2271
- package/dist/server/server.mjs +1629 -1567
- package/dist/server/theme-bridge.mjs +130 -126
- package/dist/server/theme.mjs +131 -129
- package/package.json +1 -1
- package/dist/_dts/theme-core/src/site-styles/compatibility.d.ts +0 -109
package/dist/client/hooks.mjs
CHANGED
|
@@ -7684,861 +7684,482 @@ function assertUniqueLayoutProfileKeys(profiles) {
|
|
|
7684
7684
|
}
|
|
7685
7685
|
}
|
|
7686
7686
|
|
|
7687
|
-
// ../theme-core/src/
|
|
7687
|
+
// ../theme-core/src/buttons/personalities/types.ts
|
|
7688
|
+
import { z as z11 } from "zod";
|
|
7689
|
+
|
|
7690
|
+
// ../theme-core/src/buttons/types.ts
|
|
7688
7691
|
import { z as z9 } from "zod";
|
|
7692
|
+
var VARIANT_ROLES = [
|
|
7693
|
+
"primary",
|
|
7694
|
+
"secondary",
|
|
7695
|
+
"outline",
|
|
7696
|
+
"ghost",
|
|
7697
|
+
"link",
|
|
7698
|
+
"tertiary",
|
|
7699
|
+
"accent"
|
|
7700
|
+
];
|
|
7701
|
+
var cornerStyleSchema = z9.enum(["square", "rounded", "pill"]);
|
|
7702
|
+
var shadowSizeSchema = z9.enum(["none", "low", "medium", "high"]);
|
|
7703
|
+
var textTransformSchema = z9.enum(["none", "uppercase", "lowercase", "capitalize"]);
|
|
7704
|
+
var fontWeightSchema = z9.union([z9.literal(500), z9.literal(600), z9.literal(700)]);
|
|
7705
|
+
var buttonTypographySchema = z9.enum(["body", "heading"]);
|
|
7706
|
+
var letterSpacingSchema = z9.enum(["tight", "normal", "loose"]);
|
|
7707
|
+
var hoverTransformSchema = z9.enum(["none", "lift", "scale", "press"]);
|
|
7708
|
+
var hoverColorSchema = z9.enum(["none", "brighten", "darken", "saturate", "token"]);
|
|
7709
|
+
var buttonPaddingPresetSchema = z9.enum(["compact", "default", "spacious"]);
|
|
7710
|
+
var gradientStyleSchema = z9.enum(["linear", "radial", "conic"]);
|
|
7711
|
+
var gradientSharpnessSchema = z9.enum(["smooth", "medium", "hard"]);
|
|
7712
|
+
var prioritySchema = z9.union([z9.literal(1), z9.literal(2), z9.literal(3)]);
|
|
7713
|
+
var variantRoleSchema = z9.enum(VARIANT_ROLES);
|
|
7714
|
+
var buttonSizeNameSchema = z9.enum(["sm", "md", "lg", "xl"]);
|
|
7715
|
+
var PADDING_TOKEN_PATTERN = /^(?:0|\d+(?:\.\d+)?(?:rem|em|px|%))$/;
|
|
7716
|
+
var paddingShorthandSchema = z9.string().refine(
|
|
7717
|
+
(value) => {
|
|
7718
|
+
const parts = value.split(/\s+/).filter(Boolean);
|
|
7719
|
+
return parts.length === 2 && parts.every((token) => PADDING_TOKEN_PATTERN.test(token));
|
|
7720
|
+
},
|
|
7721
|
+
{
|
|
7722
|
+
message: 'Padding must be two space-separated CSS length tokens (e.g. "0.5rem 1rem"). Use `0` for zero.'
|
|
7723
|
+
}
|
|
7724
|
+
);
|
|
7725
|
+
var buttonSizeConfigSchema = z9.object({
|
|
7726
|
+
padding: paddingShorthandSchema,
|
|
7727
|
+
fontSize: z9.string().optional()
|
|
7728
|
+
});
|
|
7729
|
+
var buttonSizesSchema = z9.object({
|
|
7730
|
+
sm: buttonSizeConfigSchema,
|
|
7731
|
+
md: buttonSizeConfigSchema,
|
|
7732
|
+
lg: buttonSizeConfigSchema,
|
|
7733
|
+
xl: buttonSizeConfigSchema.optional()
|
|
7734
|
+
}).transform(({ sm, md, lg, xl }) => ({
|
|
7735
|
+
sm,
|
|
7736
|
+
md,
|
|
7737
|
+
lg,
|
|
7738
|
+
xl: xl ?? lg
|
|
7739
|
+
}));
|
|
7740
|
+
var buttonGlobalSettingsSchema = z9.object({
|
|
7741
|
+
cornerStyle: cornerStyleSchema,
|
|
7742
|
+
cornerRadius: z9.number().min(0).max(24).optional(),
|
|
7743
|
+
shadow: shadowSizeSchema,
|
|
7744
|
+
textTransform: textTransformSchema,
|
|
7745
|
+
fontWeight: fontWeightSchema,
|
|
7746
|
+
/**
|
|
7747
|
+
* @deprecated Set per-variant via `variant.border.widthClass` instead.
|
|
7748
|
+
* Schema field is preserved so existing presets parse; the value is unread
|
|
7749
|
+
* by the current generator and will be removed once the legacy
|
|
7750
|
+
* `primitives/content/components/Button.tsx` slot exports are deleted.
|
|
7751
|
+
*/
|
|
7752
|
+
borderWidth: z9.union([z9.literal(1), z9.literal(2), z9.literal(3)]),
|
|
7753
|
+
// === Family-level typography ===
|
|
7754
|
+
// Typography source (body or heading) — selects which theme typography pool to inherit
|
|
7755
|
+
typography: buttonTypographySchema.optional(),
|
|
7756
|
+
// Font size for all variants in the family (Tailwind token, e.g. "text-xs", "text-sm")
|
|
7757
|
+
// Sized variants get this as default; fixed variants inherit unless they override.
|
|
7758
|
+
// Size class CSS may still override at run time for sized variants.
|
|
7759
|
+
fontSize: z9.string().optional(),
|
|
7760
|
+
// Letter spacing applied to all variants
|
|
7761
|
+
letterSpacing: letterSpacingSchema.optional(),
|
|
7762
|
+
// Italic style
|
|
7763
|
+
italic: z9.boolean().optional(),
|
|
7764
|
+
// Padding preset (applies to sized variants without a sizes config)
|
|
7765
|
+
paddingPreset: buttonPaddingPresetSchema.optional(),
|
|
7766
|
+
hoverTransform: hoverTransformSchema,
|
|
7767
|
+
hoverColor: hoverColorSchema,
|
|
7768
|
+
// When hoverColor is 'token', this specifies which token to use
|
|
7769
|
+
hoverColorToken: z9.string().optional(),
|
|
7770
|
+
// Gradient settings (if any variant uses gradients)
|
|
7771
|
+
gradientStyle: gradientStyleSchema.optional(),
|
|
7772
|
+
gradientAngle: z9.number().min(0).max(360).optional(),
|
|
7773
|
+
gradientSharpness: gradientSharpnessSchema.optional()
|
|
7774
|
+
});
|
|
7775
|
+
var gradientDirectionSchema = z9.enum(["to-r", "to-l", "to-t", "to-b", "to-tr", "to-tl", "to-br", "to-bl"]);
|
|
7776
|
+
var buttonBackgroundSchema = z9.discriminatedUnion("type", [
|
|
7777
|
+
z9.object({ type: z9.literal("solid"), colorToken: z9.string() }),
|
|
7778
|
+
z9.object({
|
|
7779
|
+
type: z9.literal("gradient"),
|
|
7780
|
+
stops: z9.array(z9.string()).min(2),
|
|
7781
|
+
direction: gradientDirectionSchema
|
|
7782
|
+
}),
|
|
7783
|
+
z9.object({ type: z9.literal("transparent") })
|
|
7784
|
+
]);
|
|
7785
|
+
var effectApplicationSchema = z9.object({
|
|
7786
|
+
effectId: z9.string(),
|
|
7787
|
+
options: z9.record(z9.string(), z9.any()).optional()
|
|
7788
|
+
});
|
|
7789
|
+
var buttonBorderSchema = z9.object({
|
|
7790
|
+
widthClass: z9.string(),
|
|
7791
|
+
colorToken: z9.string()
|
|
7792
|
+
});
|
|
7793
|
+
var variantShadowSchema = z9.object({
|
|
7794
|
+
elevation: z9.enum(["none", "low", "medium", "high"]),
|
|
7795
|
+
softness: z9.enum(["crisp", "soft", "hard"]).nullable(),
|
|
7796
|
+
position: z9.enum(["bottom", "bottom-right"]).default("bottom")
|
|
7797
|
+
});
|
|
7798
|
+
var variantEffectsSchema = z9.object({
|
|
7799
|
+
base: z9.array(effectApplicationSchema).optional(),
|
|
7800
|
+
hover: z9.array(effectApplicationSchema).optional(),
|
|
7801
|
+
active: z9.array(effectApplicationSchema).optional(),
|
|
7802
|
+
focus: z9.array(effectApplicationSchema).optional()
|
|
7803
|
+
});
|
|
7804
|
+
var variantSizeOverridesSchema = z9.object({
|
|
7805
|
+
sm: buttonSizeConfigSchema.optional(),
|
|
7806
|
+
md: buttonSizeConfigSchema.optional(),
|
|
7807
|
+
lg: buttonSizeConfigSchema.optional(),
|
|
7808
|
+
xl: buttonSizeConfigSchema.optional()
|
|
7809
|
+
});
|
|
7810
|
+
var buttonVariantSchema = z9.object({
|
|
7811
|
+
id: z9.string(),
|
|
7812
|
+
name: z9.string().min(1).max(20),
|
|
7813
|
+
enabled: z9.boolean(),
|
|
7814
|
+
priority: prioritySchema,
|
|
7815
|
+
// Base appearance (token-based)
|
|
7816
|
+
background: buttonBackgroundSchema,
|
|
7817
|
+
textColorToken: z9.string(),
|
|
7818
|
+
/** Tailwind radius token (e.g. `'rounded-md'`). Omit to inherit from `global.cornerStyle`. */
|
|
7819
|
+
borderRadius: z9.string().optional(),
|
|
7820
|
+
// Optional shadow override (uses theme.shadow if not specified)
|
|
7821
|
+
shadow: variantShadowSchema.optional(),
|
|
7822
|
+
// Border (optional)
|
|
7823
|
+
border: buttonBorderSchema.optional(),
|
|
7824
|
+
// Hover background token (per-variant override, takes precedence over global hoverColorToken)
|
|
7825
|
+
hoverBackgroundToken: z9.string().optional(),
|
|
7826
|
+
// Effect composition
|
|
7827
|
+
effects: variantEffectsSchema.optional(),
|
|
7828
|
+
// Per-variant size overrides — see VariantSizeOverrides
|
|
7829
|
+
sizes: variantSizeOverridesSchema.optional()
|
|
7830
|
+
});
|
|
7831
|
+
var buttonSystemSchema = z9.object({
|
|
7832
|
+
global: buttonGlobalSettingsSchema,
|
|
7833
|
+
variants: z9.array(buttonVariantSchema).min(1).max(6),
|
|
7834
|
+
sizes: buttonSizesSchema.optional()
|
|
7835
|
+
});
|
|
7836
|
+
|
|
7837
|
+
// ../theme-core/src/site-styles/styleTags.ts
|
|
7838
|
+
import { z as z10 } from "zod";
|
|
7689
7839
|
var STYLE_AXIS_VALUES = {
|
|
7690
7840
|
tone: ["minimal", "classic", "bold"],
|
|
7691
7841
|
energy: ["calm", "vibrant"],
|
|
7692
7842
|
motion: ["subtle", "standard", "expressive"],
|
|
7693
7843
|
era: ["editorial", "modern", "organic", "technical", "retro"]
|
|
7694
7844
|
};
|
|
7695
|
-
var styleTagsSchema =
|
|
7696
|
-
tone:
|
|
7697
|
-
energy:
|
|
7698
|
-
motion:
|
|
7699
|
-
era:
|
|
7845
|
+
var styleTagsSchema = z10.object({
|
|
7846
|
+
tone: z10.enum(STYLE_AXIS_VALUES.tone).optional(),
|
|
7847
|
+
energy: z10.enum(STYLE_AXIS_VALUES.energy).optional(),
|
|
7848
|
+
motion: z10.enum(STYLE_AXIS_VALUES.motion).optional(),
|
|
7849
|
+
era: z10.enum(STYLE_AXIS_VALUES.era).optional()
|
|
7700
7850
|
});
|
|
7701
7851
|
|
|
7702
|
-
// ../theme-core/src/
|
|
7703
|
-
|
|
7704
|
-
|
|
7705
|
-
|
|
7706
|
-
panelFrame("raised"),
|
|
7707
|
-
flushPanelFrame({ bleed: "start" })
|
|
7708
|
-
];
|
|
7709
|
-
var userContentFrames = [
|
|
7710
|
-
...generatedContentFrames,
|
|
7711
|
-
panelFrame("editorial"),
|
|
7712
|
-
flushPanelFrame({ bleed: "end" }),
|
|
7713
|
-
flushPanelFrame({ bleed: "both" })
|
|
7714
|
-
];
|
|
7715
|
-
var generatedDesignOptionCatalog = {
|
|
7716
|
-
source: "generated",
|
|
7717
|
-
sectionSurfaces: ["base", "muted-band", "accent-band", "hero-image"],
|
|
7718
|
-
contentFrames: generatedContentFrames,
|
|
7719
|
-
itemSurfaces: ["none", "default", "flat", "outlined", "raised"],
|
|
7720
|
-
transitions: ["none", "soft-fade-short", "soft-fade-long"],
|
|
7721
|
-
emphases: ["low", "medium", "high"],
|
|
7722
|
-
detachedCustom: false
|
|
7723
|
-
};
|
|
7724
|
-
var userDesignOptionCatalog = {
|
|
7725
|
-
source: "user",
|
|
7726
|
-
sectionSurfaces: generatedDesignOptionCatalog.sectionSurfaces,
|
|
7727
|
-
contentFrames: userContentFrames,
|
|
7728
|
-
itemSurfaces: [
|
|
7729
|
-
...generatedDesignOptionCatalog.itemSurfaces,
|
|
7730
|
-
"inset",
|
|
7731
|
-
"editorial"
|
|
7732
|
-
],
|
|
7733
|
-
transitions: [
|
|
7734
|
-
...generatedDesignOptionCatalog.transitions,
|
|
7735
|
-
"wave-edge",
|
|
7736
|
-
"angle-edge"
|
|
7737
|
-
],
|
|
7738
|
-
emphases: generatedDesignOptionCatalog.emphases,
|
|
7739
|
-
detachedCustom: false
|
|
7740
|
-
};
|
|
7741
|
-
var advancedDesignOptionCatalog = {
|
|
7742
|
-
source: "advanced",
|
|
7743
|
-
sectionSurfaces: userDesignOptionCatalog.sectionSurfaces,
|
|
7744
|
-
contentFrames: userDesignOptionCatalog.contentFrames,
|
|
7745
|
-
itemSurfaces: userDesignOptionCatalog.itemSurfaces,
|
|
7746
|
-
transitions: userDesignOptionCatalog.transitions,
|
|
7747
|
-
emphases: userDesignOptionCatalog.emphases,
|
|
7748
|
-
detachedCustom: true
|
|
7749
|
-
};
|
|
7750
|
-
|
|
7751
|
-
// ../theme-core/src/site-styles/curatedSiteStyles.ts
|
|
7752
|
-
var curatedSiteStyleIdValues = [
|
|
7753
|
-
"site-style:calm-studio",
|
|
7754
|
-
"site-style:clear-professional",
|
|
7755
|
-
"site-style:warm-editorial",
|
|
7756
|
-
"site-style:bright-community",
|
|
7757
|
-
"site-style:quiet-luxury",
|
|
7758
|
-
"site-style:practical-services",
|
|
7759
|
-
"site-style:modern-wellness",
|
|
7760
|
-
"site-style:bold-launch"
|
|
7761
|
-
];
|
|
7762
|
-
var quietBudget = {
|
|
7763
|
-
accentDensity: "low",
|
|
7764
|
-
panelDensity: "medium",
|
|
7765
|
-
transitionMix: "quiet",
|
|
7766
|
-
primaryCtaLimit: 2,
|
|
7767
|
-
mediaDensity: "medium",
|
|
7768
|
-
decorativeRepetition: "low"
|
|
7769
|
-
};
|
|
7770
|
-
var balancedBudget = {
|
|
7771
|
-
accentDensity: "medium",
|
|
7772
|
-
panelDensity: "medium",
|
|
7773
|
-
transitionMix: "balanced",
|
|
7774
|
-
primaryCtaLimit: 3,
|
|
7775
|
-
mediaDensity: "medium",
|
|
7776
|
-
decorativeRepetition: "medium"
|
|
7777
|
-
};
|
|
7778
|
-
var expressiveBudget = {
|
|
7779
|
-
accentDensity: "high",
|
|
7780
|
-
panelDensity: "high",
|
|
7781
|
-
transitionMix: "expressive",
|
|
7782
|
-
primaryCtaLimit: 3,
|
|
7783
|
-
mediaDensity: "high",
|
|
7784
|
-
decorativeRepetition: "medium"
|
|
7785
|
-
};
|
|
7786
|
-
function uniqueContentFrameKinds() {
|
|
7787
|
-
const kinds = [...new Set(
|
|
7788
|
-
generatedDesignOptionCatalog.contentFrames.map((frame) => frame.kind)
|
|
7789
|
-
)];
|
|
7790
|
-
const firstKind = kinds[0];
|
|
7791
|
-
if (!firstKind) {
|
|
7792
|
-
throw new Error("Expected generated design option catalog to expose at least one content frame kind.");
|
|
7852
|
+
// ../theme-core/src/buttons/personalities/types.ts
|
|
7853
|
+
function asButtonPersonalityId(value) {
|
|
7854
|
+
if (value.length === 0) {
|
|
7855
|
+
throw new Error("ButtonPersonalityId must be a non-empty string");
|
|
7793
7856
|
}
|
|
7794
|
-
return
|
|
7857
|
+
return value;
|
|
7795
7858
|
}
|
|
7796
|
-
var
|
|
7797
|
-
|
|
7859
|
+
var buttonPersonalityIdSchema = z11.string().min(1).transform((value) => asButtonPersonalityId(value));
|
|
7860
|
+
var buttonPersonalitySchema = z11.object({
|
|
7861
|
+
id: buttonPersonalityIdSchema,
|
|
7862
|
+
name: z11.string().min(1),
|
|
7863
|
+
description: z11.string().min(1),
|
|
7864
|
+
tags: styleTagsSchema,
|
|
7865
|
+
buttonSystem: buttonSystemSchema
|
|
7866
|
+
});
|
|
7867
|
+
function defineButtonPersonality(input) {
|
|
7798
7868
|
return {
|
|
7799
|
-
id:
|
|
7869
|
+
id: asButtonPersonalityId(input.id),
|
|
7800
7870
|
name: input.name,
|
|
7801
7871
|
description: input.description,
|
|
7802
|
-
|
|
7803
|
-
|
|
7804
|
-
template: {
|
|
7805
|
-
id: asDesignSystemTemplateId(`template:${input.id.replace("site-style:", "")}`),
|
|
7806
|
-
name: input.name,
|
|
7807
|
-
version: 1,
|
|
7808
|
-
tokenRecipes: input.tokenRecipes,
|
|
7809
|
-
compositionBudget: input.compositionBudget,
|
|
7810
|
-
supportedSectionSurfaces: generatedDesignOptionCatalog.sectionSurfaces,
|
|
7811
|
-
supportedContentFrames: generatedContentFrameKinds,
|
|
7812
|
-
supportedItemSurfaces: generatedDesignOptionCatalog.itemSurfaces,
|
|
7813
|
-
supportedTransitions: generatedDesignOptionCatalog.transitions
|
|
7814
|
-
},
|
|
7815
|
-
// The library IDs are already branded at construction (`asButtonPersonalityId`
|
|
7816
|
-
// / `asPaletteVariantId`); the closed-union input type guarantees only
|
|
7817
|
-
// shipped IDs reach this branch.
|
|
7818
|
-
defaultButtonPersonalityId: input.defaultButtonPersonalityId,
|
|
7819
|
-
acceptedButtons: input.acceptedButtons,
|
|
7820
|
-
defaultPaletteVariantId: input.defaultPaletteVariantId,
|
|
7821
|
-
acceptedPalettes: input.acceptedPalettes
|
|
7872
|
+
tags: input.tags,
|
|
7873
|
+
buttonSystem: input.buttonSystem
|
|
7822
7874
|
};
|
|
7823
7875
|
}
|
|
7824
|
-
|
|
7825
|
-
|
|
7826
|
-
|
|
7827
|
-
|
|
7828
|
-
|
|
7829
|
-
|
|
7830
|
-
|
|
7831
|
-
|
|
7832
|
-
|
|
7833
|
-
|
|
7834
|
-
shadow: "
|
|
7835
|
-
|
|
7836
|
-
|
|
7837
|
-
|
|
7838
|
-
|
|
7839
|
-
|
|
7840
|
-
defaultButtonPersonalityId: "soft-pill",
|
|
7841
|
-
acceptedButtons: { tone: ["minimal", "classic"], era: ["organic", "editorial"] },
|
|
7842
|
-
defaultPaletteVariantId: "soft-natural-sage",
|
|
7843
|
-
acceptedPalettes: { tone: ["minimal", "classic"], era: ["organic"] }
|
|
7844
|
-
}),
|
|
7845
|
-
defineCuratedSiteStyle({
|
|
7846
|
-
id: "site-style:clear-professional",
|
|
7847
|
-
name: "Clear Professional",
|
|
7848
|
-
description: "Crisp, trustworthy, and direct for local services and consultancies.",
|
|
7849
|
-
generationBrief: "Prioritize clarity, proof, service detail, and easy next steps. Keep visuals polished and specific, with restrained decorative treatment.",
|
|
7850
|
-
tokenRecipes: {
|
|
7851
|
-
palette: "brand-led",
|
|
7852
|
-
contrast: "strong",
|
|
7853
|
-
radius: "soft",
|
|
7854
|
-
shadow: "subtle",
|
|
7855
|
-
typography: "clean-sans",
|
|
7856
|
-
spacing: "regular",
|
|
7857
|
-
motion: "subtle"
|
|
7876
|
+
|
|
7877
|
+
// ../theme-core/src/buttons/personalities/brushed-wash.ts
|
|
7878
|
+
var brushedWash = defineButtonPersonality({
|
|
7879
|
+
id: "brushed-wash",
|
|
7880
|
+
name: "Brushed Wash",
|
|
7881
|
+
description: "Watercolour-gradient buttons with soft shadows and generous padding.",
|
|
7882
|
+
tags: { tone: "classic", energy: "vibrant", motion: "standard", era: "organic" },
|
|
7883
|
+
buttonSystem: {
|
|
7884
|
+
global: {
|
|
7885
|
+
cornerStyle: "rounded",
|
|
7886
|
+
shadow: "low",
|
|
7887
|
+
textTransform: "none",
|
|
7888
|
+
fontWeight: 500,
|
|
7889
|
+
borderWidth: 1,
|
|
7890
|
+
hoverTransform: "none",
|
|
7891
|
+
hoverColor: "none"
|
|
7858
7892
|
},
|
|
7859
|
-
|
|
7860
|
-
|
|
7861
|
-
|
|
7862
|
-
|
|
7863
|
-
|
|
7864
|
-
}),
|
|
7865
|
-
defineCuratedSiteStyle({
|
|
7866
|
-
id: "site-style:warm-editorial",
|
|
7867
|
-
name: "Warm Editorial",
|
|
7868
|
-
description: "Story-led and textured for educators, makers, venues, and retreats.",
|
|
7869
|
-
generationBrief: "Let the copy feel thoughtful and grounded. Favor narrative sections, supporting media, and a small number of editorial panels.",
|
|
7870
|
-
tokenRecipes: {
|
|
7871
|
-
palette: "warm-neutral",
|
|
7872
|
-
contrast: "standard",
|
|
7873
|
-
radius: "square",
|
|
7874
|
-
shadow: "none",
|
|
7875
|
-
typography: "serif-editorial",
|
|
7876
|
-
spacing: "airy",
|
|
7877
|
-
motion: "subtle"
|
|
7893
|
+
sizes: {
|
|
7894
|
+
sm: { padding: "0.75rem 2rem", fontSize: "text-sm" },
|
|
7895
|
+
md: { padding: "1rem 2.5rem" },
|
|
7896
|
+
lg: { padding: "1.25rem 3rem", fontSize: "text-lg" },
|
|
7897
|
+
xl: { padding: "1.625rem 3.75rem", fontSize: "text-xl" }
|
|
7878
7898
|
},
|
|
7879
|
-
|
|
7880
|
-
|
|
7881
|
-
|
|
7882
|
-
|
|
7883
|
-
|
|
7884
|
-
|
|
7885
|
-
|
|
7886
|
-
|
|
7887
|
-
|
|
7888
|
-
|
|
7889
|
-
|
|
7890
|
-
|
|
7891
|
-
|
|
7892
|
-
|
|
7893
|
-
|
|
7894
|
-
|
|
7895
|
-
|
|
7896
|
-
|
|
7897
|
-
|
|
7899
|
+
variants: [
|
|
7900
|
+
{
|
|
7901
|
+
id: "primary",
|
|
7902
|
+
name: "Primary",
|
|
7903
|
+
enabled: true,
|
|
7904
|
+
priority: 1,
|
|
7905
|
+
background: {
|
|
7906
|
+
type: "gradient",
|
|
7907
|
+
stops: ["primary", "accent"],
|
|
7908
|
+
direction: "to-r"
|
|
7909
|
+
},
|
|
7910
|
+
textColorToken: "primaryForeground",
|
|
7911
|
+
borderRadius: "rounded-lg",
|
|
7912
|
+
shadow: { elevation: "low", softness: "soft", position: "bottom" },
|
|
7913
|
+
effects: {
|
|
7914
|
+
hover: [{ effectId: "opacity-reduce", options: { reduction: -15 } }]
|
|
7915
|
+
}
|
|
7916
|
+
},
|
|
7917
|
+
{
|
|
7918
|
+
id: "secondary",
|
|
7919
|
+
name: "Secondary",
|
|
7920
|
+
enabled: true,
|
|
7921
|
+
priority: 2,
|
|
7922
|
+
background: {
|
|
7923
|
+
type: "gradient",
|
|
7924
|
+
stops: ["secondary", "accent"],
|
|
7925
|
+
direction: "to-br"
|
|
7926
|
+
},
|
|
7927
|
+
textColorToken: "primaryForeground",
|
|
7928
|
+
borderRadius: "rounded-lg",
|
|
7929
|
+
shadow: { elevation: "low", softness: "soft", position: "bottom" },
|
|
7930
|
+
effects: {
|
|
7931
|
+
hover: [{ effectId: "opacity-reduce", options: { reduction: -15 } }]
|
|
7932
|
+
}
|
|
7933
|
+
},
|
|
7934
|
+
{
|
|
7935
|
+
id: "outline",
|
|
7936
|
+
name: "Outline",
|
|
7937
|
+
enabled: true,
|
|
7938
|
+
priority: 3,
|
|
7939
|
+
background: { type: "transparent" },
|
|
7940
|
+
textColorToken: "primary",
|
|
7941
|
+
borderRadius: "rounded-lg",
|
|
7942
|
+
border: { widthClass: "border", colorToken: "primary" },
|
|
7943
|
+
effects: {
|
|
7944
|
+
hover: [{ effectId: "background-on-hover", options: { colorToken: "surface" } }]
|
|
7945
|
+
}
|
|
7946
|
+
},
|
|
7947
|
+
{
|
|
7948
|
+
id: "ghost",
|
|
7949
|
+
name: "Ghost",
|
|
7950
|
+
enabled: true,
|
|
7951
|
+
priority: 3,
|
|
7952
|
+
background: { type: "transparent" },
|
|
7953
|
+
textColorToken: "text",
|
|
7954
|
+
borderRadius: "rounded-lg",
|
|
7955
|
+
effects: {
|
|
7956
|
+
hover: [
|
|
7957
|
+
{ effectId: "background-on-hover", options: { colorToken: "surface" } }
|
|
7958
|
+
]
|
|
7959
|
+
}
|
|
7960
|
+
}
|
|
7961
|
+
]
|
|
7962
|
+
}
|
|
7963
|
+
});
|
|
7964
|
+
|
|
7965
|
+
// ../theme-core/src/buttons/personalities/confident-chip.ts
|
|
7966
|
+
var confidentChip = defineButtonPersonality({
|
|
7967
|
+
id: "confident-chip",
|
|
7968
|
+
name: "Confident Chip",
|
|
7969
|
+
description: "Mid-radius solid buttons with a crisp hover.",
|
|
7970
|
+
tags: { tone: "classic", energy: "calm", motion: "standard", era: "modern" },
|
|
7971
|
+
buttonSystem: {
|
|
7972
|
+
global: {
|
|
7973
|
+
cornerStyle: "rounded",
|
|
7974
|
+
shadow: "medium",
|
|
7975
|
+
textTransform: "none",
|
|
7976
|
+
fontWeight: 600,
|
|
7977
|
+
borderWidth: 1,
|
|
7978
|
+
hoverTransform: "none",
|
|
7979
|
+
hoverColor: "none"
|
|
7898
7980
|
},
|
|
7899
|
-
|
|
7900
|
-
|
|
7901
|
-
|
|
7902
|
-
|
|
7903
|
-
|
|
7904
|
-
|
|
7905
|
-
|
|
7906
|
-
|
|
7907
|
-
|
|
7908
|
-
|
|
7909
|
-
|
|
7910
|
-
|
|
7911
|
-
|
|
7912
|
-
|
|
7913
|
-
|
|
7914
|
-
|
|
7915
|
-
|
|
7916
|
-
|
|
7917
|
-
|
|
7918
|
-
|
|
7919
|
-
|
|
7920
|
-
|
|
7981
|
+
variants: [
|
|
7982
|
+
{
|
|
7983
|
+
id: "primary",
|
|
7984
|
+
name: "Primary",
|
|
7985
|
+
enabled: true,
|
|
7986
|
+
priority: 1,
|
|
7987
|
+
background: { type: "solid", colorToken: "primary" },
|
|
7988
|
+
textColorToken: "primaryForeground",
|
|
7989
|
+
borderRadius: "rounded-md",
|
|
7990
|
+
shadow: { elevation: "medium", softness: "soft", position: "bottom" },
|
|
7991
|
+
effects: {
|
|
7992
|
+
hover: [{ effectId: "darken-background", options: { amount: 60 } }],
|
|
7993
|
+
active: [{ effectId: "scale-down", options: { scale: "0.97" } }]
|
|
7994
|
+
}
|
|
7995
|
+
},
|
|
7996
|
+
{
|
|
7997
|
+
id: "secondary",
|
|
7998
|
+
name: "Secondary",
|
|
7999
|
+
enabled: true,
|
|
8000
|
+
priority: 2,
|
|
8001
|
+
background: { type: "solid", colorToken: "surface" },
|
|
8002
|
+
textColorToken: "text",
|
|
8003
|
+
borderRadius: "rounded-md",
|
|
8004
|
+
border: { widthClass: "border", colorToken: "border" },
|
|
8005
|
+
effects: {
|
|
8006
|
+
hover: [{ effectId: "background-on-hover", options: { colorToken: "background" } }]
|
|
8007
|
+
}
|
|
8008
|
+
},
|
|
8009
|
+
{
|
|
8010
|
+
id: "outline",
|
|
8011
|
+
name: "Outline",
|
|
8012
|
+
enabled: true,
|
|
8013
|
+
priority: 3,
|
|
8014
|
+
background: { type: "transparent" },
|
|
8015
|
+
textColorToken: "primary",
|
|
8016
|
+
borderRadius: "rounded-md",
|
|
8017
|
+
border: { widthClass: "border", colorToken: "primary" },
|
|
8018
|
+
effects: {
|
|
8019
|
+
hover: [{ effectId: "background-on-hover", options: { colorToken: "surface" } }]
|
|
8020
|
+
}
|
|
8021
|
+
},
|
|
8022
|
+
{
|
|
8023
|
+
id: "ghost",
|
|
8024
|
+
name: "Ghost",
|
|
8025
|
+
enabled: true,
|
|
8026
|
+
priority: 3,
|
|
8027
|
+
background: { type: "transparent" },
|
|
8028
|
+
textColorToken: "primary",
|
|
8029
|
+
borderRadius: "rounded-md",
|
|
8030
|
+
effects: {
|
|
8031
|
+
hover: [{ effectId: "background-on-hover", options: { colorToken: "surface" } }]
|
|
8032
|
+
}
|
|
8033
|
+
}
|
|
8034
|
+
]
|
|
8035
|
+
}
|
|
8036
|
+
});
|
|
8037
|
+
|
|
8038
|
+
// ../theme-core/src/buttons/personalities/editorial-link.ts
|
|
8039
|
+
var editorialLink = defineButtonPersonality({
|
|
8040
|
+
id: "editorial-link",
|
|
8041
|
+
name: "Editorial Link",
|
|
8042
|
+
description: "Link-style with a growing underline. Refined, typographic.",
|
|
8043
|
+
tags: { tone: "minimal", energy: "calm", motion: "subtle", era: "editorial" },
|
|
8044
|
+
buttonSystem: {
|
|
8045
|
+
global: {
|
|
8046
|
+
cornerStyle: "square",
|
|
7921
8047
|
shadow: "none",
|
|
7922
|
-
|
|
7923
|
-
|
|
7924
|
-
|
|
7925
|
-
|
|
7926
|
-
|
|
7927
|
-
defaultButtonPersonalityId: "editorial-link",
|
|
7928
|
-
acceptedButtons: { tone: ["minimal", "classic"], era: ["editorial", "organic"] },
|
|
7929
|
-
defaultPaletteVariantId: "high-contrast-charcoal",
|
|
7930
|
-
acceptedPalettes: { tone: ["minimal", "classic"], era: ["editorial", "organic"] }
|
|
7931
|
-
}),
|
|
7932
|
-
defineCuratedSiteStyle({
|
|
7933
|
-
id: "site-style:practical-services",
|
|
7934
|
-
name: "Practical Services",
|
|
7935
|
-
description: "Efficient, plainspoken, and conversion-focused for trades and everyday services.",
|
|
7936
|
-
generationBrief: "Make services, location, trust signals, and contact paths obvious. Keep copy brief and avoid ornate visual treatments.",
|
|
7937
|
-
selectionKeywords: [
|
|
7938
|
-
"repair",
|
|
7939
|
-
"plumb",
|
|
7940
|
-
"electric",
|
|
7941
|
-
"cleaning",
|
|
7942
|
-
"landscap",
|
|
7943
|
-
"contractor"
|
|
7944
|
-
],
|
|
7945
|
-
tokenRecipes: {
|
|
7946
|
-
palette: "brand-led",
|
|
7947
|
-
contrast: "maximum",
|
|
7948
|
-
radius: "soft",
|
|
7949
|
-
shadow: "subtle",
|
|
7950
|
-
typography: "clean-sans",
|
|
7951
|
-
spacing: "compact",
|
|
7952
|
-
motion: "none"
|
|
7953
|
-
},
|
|
7954
|
-
compositionBudget: quietBudget,
|
|
7955
|
-
defaultButtonPersonalityId: "confident-chip",
|
|
7956
|
-
acceptedButtons: { tone: ["minimal", "classic", "bold"], era: ["modern", "editorial"] },
|
|
7957
|
-
defaultPaletteVariantId: "brand-led-cool",
|
|
7958
|
-
acceptedPalettes: { tone: ["minimal", "classic", "bold"], era: ["modern", "editorial"] }
|
|
7959
|
-
}),
|
|
7960
|
-
defineCuratedSiteStyle({
|
|
7961
|
-
id: "site-style:modern-wellness",
|
|
7962
|
-
name: "Modern Wellness",
|
|
7963
|
-
description: "Natural, current, and reassuring for practitioners, studios, and wellbeing offers.",
|
|
7964
|
-
generationBrief: "Keep the tone warm and practical. Use gentle section variation, natural materials, and inclusive copy without making medical claims.",
|
|
7965
|
-
tokenRecipes: {
|
|
7966
|
-
palette: "soft-natural",
|
|
7967
|
-
contrast: "standard",
|
|
7968
|
-
radius: "rounded",
|
|
7969
|
-
shadow: "subtle",
|
|
7970
|
-
typography: "clean-sans",
|
|
7971
|
-
spacing: "airy",
|
|
7972
|
-
motion: "subtle"
|
|
8048
|
+
textTransform: "none",
|
|
8049
|
+
fontWeight: 500,
|
|
8050
|
+
borderWidth: 1,
|
|
8051
|
+
hoverTransform: "none",
|
|
8052
|
+
hoverColor: "none"
|
|
7973
8053
|
},
|
|
7974
|
-
|
|
7975
|
-
|
|
7976
|
-
|
|
7977
|
-
|
|
7978
|
-
|
|
7979
|
-
|
|
7980
|
-
|
|
7981
|
-
|
|
7982
|
-
|
|
7983
|
-
|
|
7984
|
-
|
|
7985
|
-
|
|
7986
|
-
|
|
7987
|
-
|
|
7988
|
-
|
|
7989
|
-
|
|
7990
|
-
|
|
7991
|
-
|
|
7992
|
-
|
|
7993
|
-
|
|
7994
|
-
|
|
7995
|
-
|
|
7996
|
-
|
|
7997
|
-
|
|
7998
|
-
|
|
7999
|
-
|
|
8000
|
-
|
|
8001
|
-
|
|
8002
|
-
|
|
8003
|
-
|
|
8004
|
-
|
|
8005
|
-
|
|
8006
|
-
|
|
8007
|
-
|
|
8008
|
-
|
|
8009
|
-
|
|
8010
|
-
|
|
8011
|
-
|
|
8012
|
-
|
|
8013
|
-
|
|
8014
|
-
|
|
8015
|
-
|
|
8016
|
-
|
|
8017
|
-
|
|
8018
|
-
|
|
8019
|
-
|
|
8020
|
-
|
|
8021
|
-
|
|
8022
|
-
|
|
8023
|
-
|
|
8024
|
-
|
|
8025
|
-
|
|
8026
|
-
|
|
8027
|
-
|
|
8028
|
-
|
|
8029
|
-
|
|
8030
|
-
|
|
8031
|
-
|
|
8032
|
-
|
|
8033
|
-
|
|
8034
|
-
|
|
8035
|
-
|
|
8036
|
-
|
|
8037
|
-
|
|
8038
|
-
|
|
8039
|
-
|
|
8040
|
-
|
|
8041
|
-
|
|
8042
|
-
|
|
8043
|
-
|
|
8044
|
-
|
|
8045
|
-
|
|
8046
|
-
|
|
8047
|
-
|
|
8048
|
-
|
|
8049
|
-
|
|
8050
|
-
|
|
8051
|
-
|
|
8052
|
-
|
|
8053
|
-
|
|
8054
|
-
|
|
8055
|
-
|
|
8056
|
-
|
|
8057
|
-
|
|
8058
|
-
}
|
|
8059
|
-
var userPanelTreatments = uniqueNonEmpty(
|
|
8060
|
-
userDesignOptionCatalog.contentFrames.filter((frame) => frame.kind === "panel").map((frame) => frame.treatment)
|
|
8061
|
-
);
|
|
8062
|
-
var userFlushTreatments = uniqueNonEmpty(
|
|
8063
|
-
userDesignOptionCatalog.contentFrames.filter((frame) => frame.kind === "flush-panel").map((frame) => frame.treatment)
|
|
8064
|
-
);
|
|
8065
|
-
var userFlushBleeds = uniqueNonEmpty(
|
|
8066
|
-
userDesignOptionCatalog.contentFrames.filter((frame) => frame.kind === "flush-panel").map((frame) => frame.bleed)
|
|
8067
|
-
);
|
|
8068
|
-
var contentFrameIntentSchema = z10.discriminatedUnion("kind", [
|
|
8069
|
-
z10.object({ kind: z10.literal("plain") }).strict(),
|
|
8070
|
-
z10.object({
|
|
8071
|
-
kind: z10.literal("panel"),
|
|
8072
|
-
treatment: z10.enum(userPanelTreatments)
|
|
8073
|
-
}).strict(),
|
|
8074
|
-
z10.object({
|
|
8075
|
-
kind: z10.literal("flush-panel"),
|
|
8076
|
-
treatment: z10.enum(userFlushTreatments),
|
|
8077
|
-
bleed: z10.enum(userFlushBleeds)
|
|
8078
|
-
}).strict()
|
|
8079
|
-
]);
|
|
8080
|
-
var blockDesignPlanSchema = z10.object({
|
|
8081
|
-
blockId: z10.string().min(1).transform(asDesignBlockId),
|
|
8082
|
-
blockKind: z10.string().min(1),
|
|
8083
|
-
purpose: z10.string().min(1),
|
|
8084
|
-
sectionSurface: z10.enum(userDesignOptionCatalog.sectionSurfaces),
|
|
8085
|
-
contentFrame: contentFrameIntentSchema,
|
|
8086
|
-
itemSurface: z10.enum(userDesignOptionCatalog.itemSurfaces),
|
|
8087
|
-
transitionAfter: z10.enum(userDesignOptionCatalog.transitions),
|
|
8088
|
-
emphasis: z10.enum(userDesignOptionCatalog.emphases),
|
|
8089
|
-
heroLegibility: heroLegibilityStrategySchema.optional()
|
|
8090
|
-
}).strict();
|
|
8091
|
-
var styleAuthoritySchema = z10.discriminatedUnion("kind", [
|
|
8092
|
-
z10.object({
|
|
8093
|
-
kind: z10.literal("theme-v2"),
|
|
8094
|
-
source: designResolutionPolicySchema,
|
|
8095
|
-
siteStyleId: z10.string().min(1).transform(asSiteStyleId),
|
|
8096
|
-
templateId: z10.string().min(1).transform(asDesignSystemTemplateId),
|
|
8097
|
-
templateVersion: z10.number().int().nonnegative(),
|
|
8098
|
-
resolverVersion: z10.number().int().nonnegative()
|
|
8099
|
-
}).strict(),
|
|
8100
|
-
z10.object({
|
|
8101
|
-
kind: z10.literal("legacy-raw"),
|
|
8102
|
-
reason: z10.enum(["pre-theme-v2", "manual-runtime-fields"])
|
|
8103
|
-
}).strict(),
|
|
8104
|
-
z10.object({
|
|
8105
|
-
kind: z10.literal("advanced-detached"),
|
|
8106
|
-
reason: z10.literal("detached-custom-runtime-fields")
|
|
8107
|
-
}).strict()
|
|
8108
|
-
]);
|
|
8109
|
-
var blockRuntimeStyleAuthoritySchema = z10.object({
|
|
8110
|
-
unit: z10.literal("block-runtime-fields"),
|
|
8111
|
-
blockId: z10.string().min(1).transform(asDesignBlockId),
|
|
8112
|
-
fields: nonEmptyRuntimeStyleFieldNamesSchema,
|
|
8113
|
-
authority: styleAuthoritySchema
|
|
8114
|
-
}).strict();
|
|
8115
|
-
var persistedPageDesignStateV1Schema = z10.object({
|
|
8116
|
-
schemaVersion: z10.literal(themeV2DesignStateSchemaVersion),
|
|
8117
|
-
siteStyleId: z10.string().min(1).transform(asSiteStyleId),
|
|
8118
|
-
templateId: z10.string().min(1).transform(asDesignSystemTemplateId),
|
|
8119
|
-
templateVersion: z10.number().int().nonnegative(),
|
|
8120
|
-
resolverVersion: z10.number().int().nonnegative(),
|
|
8121
|
-
rhythmPresetId: z10.string().min(1),
|
|
8122
|
-
blocks: z10.array(blockDesignPlanSchema),
|
|
8123
|
-
styleAuthorities: z10.array(blockRuntimeStyleAuthoritySchema)
|
|
8124
|
-
}).strict();
|
|
8125
|
-
|
|
8126
|
-
// ../theme-core/src/site-styles/generatedSchemas.ts
|
|
8127
|
-
import { z as z11 } from "zod";
|
|
8128
|
-
function uniqueNonEmpty2(values) {
|
|
8129
|
-
const uniqueValues = [...new Set(values)];
|
|
8130
|
-
const firstValue = uniqueValues[0];
|
|
8131
|
-
if (!firstValue) {
|
|
8132
|
-
throw new Error("Expected at least one generated schema option.");
|
|
8133
|
-
}
|
|
8134
|
-
return [firstValue, ...uniqueValues.slice(1)];
|
|
8135
|
-
}
|
|
8136
|
-
var generatedPanelTreatments = uniqueNonEmpty2(
|
|
8137
|
-
generatedDesignOptionCatalog.contentFrames.filter((frame) => frame.kind === "panel").map((frame) => frame.treatment)
|
|
8138
|
-
);
|
|
8139
|
-
var generatedFlushTreatments = uniqueNonEmpty2(
|
|
8140
|
-
generatedDesignOptionCatalog.contentFrames.filter((frame) => frame.kind === "flush-panel").map((frame) => frame.treatment)
|
|
8141
|
-
);
|
|
8142
|
-
var generatedFlushBleeds = uniqueNonEmpty2(
|
|
8143
|
-
generatedDesignOptionCatalog.contentFrames.filter((frame) => frame.kind === "flush-panel").map((frame) => frame.bleed)
|
|
8144
|
-
);
|
|
8145
|
-
var generatedPanelFrameSchema = z11.object({
|
|
8146
|
-
kind: z11.literal("panel"),
|
|
8147
|
-
treatment: z11.enum(generatedPanelTreatments)
|
|
8148
|
-
}).strict();
|
|
8149
|
-
var generatedFlushPanelFrameSchema = z11.object({
|
|
8150
|
-
kind: z11.literal("flush-panel"),
|
|
8151
|
-
treatment: z11.enum(generatedFlushTreatments),
|
|
8152
|
-
bleed: z11.enum(generatedFlushBleeds)
|
|
8153
|
-
}).strict();
|
|
8154
|
-
var generatedContentFrameIntentSchema = z11.discriminatedUnion("kind", [
|
|
8155
|
-
z11.object({ kind: z11.literal("plain") }).strict(),
|
|
8156
|
-
generatedPanelFrameSchema,
|
|
8157
|
-
generatedFlushPanelFrameSchema
|
|
8158
|
-
]);
|
|
8159
|
-
var generatedSiteStyleIdSchema = z11.enum(curatedSiteStyleIdValues).transform(asSiteStyleId);
|
|
8160
|
-
function generatedChoiceSchema(valueSchema) {
|
|
8161
|
-
return z11.discriminatedUnion("kind", [
|
|
8162
|
-
z11.object({
|
|
8163
|
-
source: z11.literal("generated"),
|
|
8164
|
-
kind: z11.literal("auto")
|
|
8165
|
-
}).strict(),
|
|
8166
|
-
z11.object({
|
|
8167
|
-
source: z11.literal("generated"),
|
|
8168
|
-
kind: z11.literal("explicit"),
|
|
8169
|
-
value: valueSchema
|
|
8170
|
-
}).strict()
|
|
8171
|
-
]);
|
|
8172
|
-
}
|
|
8173
|
-
var generatedBlockDesignIntentSchema = z11.object({
|
|
8174
|
-
sectionSurface: generatedChoiceSchema(
|
|
8175
|
-
z11.enum(generatedDesignOptionCatalog.sectionSurfaces)
|
|
8176
|
-
),
|
|
8177
|
-
contentFrame: generatedChoiceSchema(generatedContentFrameIntentSchema),
|
|
8178
|
-
itemSurface: generatedChoiceSchema(
|
|
8179
|
-
z11.enum(generatedDesignOptionCatalog.itemSurfaces)
|
|
8180
|
-
),
|
|
8181
|
-
transitionAfter: generatedChoiceSchema(
|
|
8182
|
-
z11.enum(generatedDesignOptionCatalog.transitions)
|
|
8183
|
-
),
|
|
8184
|
-
emphasis: generatedChoiceSchema(
|
|
8185
|
-
z11.enum(generatedDesignOptionCatalog.emphases)
|
|
8186
|
-
)
|
|
8187
|
-
}).strict();
|
|
8188
|
-
var generatedMediaCompositionIntentSchema = z11.enum([
|
|
8189
|
-
"none",
|
|
8190
|
-
"supporting",
|
|
8191
|
-
"dominant"
|
|
8192
|
-
]);
|
|
8193
|
-
var generatedDecorativeCompositionIntentSchema = z11.enum([
|
|
8194
|
-
"none",
|
|
8195
|
-
"supporting"
|
|
8196
|
-
]);
|
|
8197
|
-
var generatedHeroLegibilityStrategySchema = z11.enum([
|
|
8198
|
-
"none",
|
|
8199
|
-
"scrim-gradient"
|
|
8200
|
-
]);
|
|
8201
|
-
var generatedBlockMediaIntentSchema = z11.object({
|
|
8202
|
-
media: generatedMediaCompositionIntentSchema,
|
|
8203
|
-
decorative: generatedDecorativeCompositionIntentSchema,
|
|
8204
|
-
heroLegibility: generatedChoiceSchema(generatedHeroLegibilityStrategySchema)
|
|
8205
|
-
}).strict();
|
|
8206
|
-
var generatedBoundaryIntentSchema = z11.object({
|
|
8207
|
-
transitionAfter: generatedChoiceSchema(
|
|
8208
|
-
z11.enum(generatedDesignOptionCatalog.transitions)
|
|
8209
|
-
)
|
|
8210
|
-
}).strict();
|
|
8211
|
-
var generatedPageDesignBlockIntentSchema = z11.object({
|
|
8212
|
-
blockId: z11.string().min(1),
|
|
8213
|
-
blockKind: z11.string().min(1),
|
|
8214
|
-
purpose: z11.string().min(1),
|
|
8215
|
-
design: generatedBlockDesignIntentSchema,
|
|
8216
|
-
mediaIntent: generatedBlockMediaIntentSchema,
|
|
8217
|
-
boundaryIntent: generatedBoundaryIntentSchema
|
|
8218
|
-
}).strict();
|
|
8219
|
-
var generatedPageDesignIntentSchema = z11.object({
|
|
8220
|
-
siteStyleId: generatedSiteStyleIdSchema,
|
|
8221
|
-
blocks: z11.array(generatedPageDesignBlockIntentSchema)
|
|
8222
|
-
}).strict();
|
|
8223
|
-
|
|
8224
|
-
// ../theme-core/src/site-styles/pageDesignIntent.ts
|
|
8225
|
-
import { z as z12 } from "zod";
|
|
8226
|
-
var pageDesignIntentSchemaVersion = 1;
|
|
8227
|
-
var pageDesignUserPinnedAppearanceChoiceSchema = z12.object({
|
|
8228
|
-
kind: z12.literal("user-pinned"),
|
|
8229
|
-
value: z12.string().min(1).transform(asAppearancePresetId)
|
|
8230
|
-
}).strict();
|
|
8231
|
-
var pageDesignUserPinnedBoundaryChoiceSchema = z12.object({
|
|
8232
|
-
kind: z12.literal("user-pinned"),
|
|
8233
|
-
value: z12.string().min(1).transform(asBoundaryOptionId)
|
|
8234
|
-
}).strict();
|
|
8235
|
-
var pageDesignBlockLookPinSchema = z12.object({
|
|
8236
|
-
blockId: z12.string().min(1).transform(asDesignBlockId),
|
|
8237
|
-
blockKind: z12.string().min(1),
|
|
8238
|
-
choice: pageDesignUserPinnedAppearanceChoiceSchema
|
|
8239
|
-
}).strict();
|
|
8240
|
-
var pageDesignBoundaryPinSchema = z12.object({
|
|
8241
|
-
boundaryId: z12.string().min(1).transform(asDesignBoundaryId),
|
|
8242
|
-
previousBlockId: z12.string().min(1).transform(asDesignBlockId),
|
|
8243
|
-
nextBlockId: z12.string().min(1).transform(asDesignBlockId),
|
|
8244
|
-
choice: pageDesignUserPinnedBoundaryChoiceSchema
|
|
8245
|
-
}).strict().superRefine((pin, ctx) => {
|
|
8246
|
-
const expectedBoundaryId = makeBoundaryId(
|
|
8247
|
-
pin.previousBlockId,
|
|
8248
|
-
pin.nextBlockId
|
|
8249
|
-
);
|
|
8250
|
-
if (pin.boundaryId !== expectedBoundaryId) {
|
|
8251
|
-
ctx.addIssue({
|
|
8252
|
-
code: z12.ZodIssueCode.custom,
|
|
8253
|
-
path: ["boundaryId"],
|
|
8254
|
-
message: `Boundary id must match previousBlockId and nextBlockId. Expected ${expectedBoundaryId}.`
|
|
8255
|
-
});
|
|
8054
|
+
variants: [
|
|
8055
|
+
{
|
|
8056
|
+
id: "primary",
|
|
8057
|
+
name: "Primary",
|
|
8058
|
+
enabled: true,
|
|
8059
|
+
priority: 1,
|
|
8060
|
+
background: { type: "transparent" },
|
|
8061
|
+
textColorToken: "text",
|
|
8062
|
+
borderRadius: "rounded-none",
|
|
8063
|
+
shadow: { elevation: "none", softness: null, position: "bottom" },
|
|
8064
|
+
sizes: {
|
|
8065
|
+
sm: { padding: "0.25rem 0" },
|
|
8066
|
+
md: { padding: "0.5rem 0" },
|
|
8067
|
+
lg: { padding: "0.625rem 0" },
|
|
8068
|
+
xl: { padding: "0.75rem 0" }
|
|
8069
|
+
},
|
|
8070
|
+
effects: {
|
|
8071
|
+
base: [
|
|
8072
|
+
{ effectId: "border-bottom-grow", options: { height: 2, colorToken: "text", origin: "left" } }
|
|
8073
|
+
]
|
|
8074
|
+
}
|
|
8075
|
+
},
|
|
8076
|
+
{
|
|
8077
|
+
id: "secondary",
|
|
8078
|
+
name: "Secondary",
|
|
8079
|
+
enabled: true,
|
|
8080
|
+
priority: 2,
|
|
8081
|
+
background: { type: "transparent" },
|
|
8082
|
+
textColorToken: "mutedText",
|
|
8083
|
+
borderRadius: "rounded-none",
|
|
8084
|
+
shadow: { elevation: "none", softness: null, position: "bottom" },
|
|
8085
|
+
sizes: {
|
|
8086
|
+
sm: { padding: "0.25rem 0" },
|
|
8087
|
+
md: { padding: "0.5rem 0" },
|
|
8088
|
+
lg: { padding: "0.625rem 0" },
|
|
8089
|
+
xl: { padding: "0.75rem 0" }
|
|
8090
|
+
},
|
|
8091
|
+
effects: {
|
|
8092
|
+
base: [
|
|
8093
|
+
{ effectId: "border-bottom-grow", options: { height: 1, colorToken: "mutedText", origin: "left" } }
|
|
8094
|
+
]
|
|
8095
|
+
}
|
|
8096
|
+
},
|
|
8097
|
+
{
|
|
8098
|
+
id: "outline",
|
|
8099
|
+
name: "Outline",
|
|
8100
|
+
enabled: true,
|
|
8101
|
+
priority: 3,
|
|
8102
|
+
background: { type: "transparent" },
|
|
8103
|
+
textColorToken: "accent",
|
|
8104
|
+
borderRadius: "rounded-none",
|
|
8105
|
+
shadow: { elevation: "none", softness: null, position: "bottom" },
|
|
8106
|
+
sizes: {
|
|
8107
|
+
sm: { padding: "0.25rem 0" },
|
|
8108
|
+
md: { padding: "0.5rem 0" },
|
|
8109
|
+
lg: { padding: "0.625rem 0" },
|
|
8110
|
+
xl: { padding: "0.75rem 0" }
|
|
8111
|
+
},
|
|
8112
|
+
effects: {
|
|
8113
|
+
base: [
|
|
8114
|
+
{ effectId: "border-bottom-grow", options: { height: 1, colorToken: "accent", origin: "left" } }
|
|
8115
|
+
]
|
|
8116
|
+
}
|
|
8117
|
+
},
|
|
8118
|
+
{
|
|
8119
|
+
id: "ghost",
|
|
8120
|
+
name: "Ghost",
|
|
8121
|
+
enabled: true,
|
|
8122
|
+
priority: 3,
|
|
8123
|
+
background: { type: "transparent" },
|
|
8124
|
+
textColorToken: "mutedText",
|
|
8125
|
+
borderRadius: "rounded-none",
|
|
8126
|
+
shadow: { elevation: "none", softness: null, position: "bottom" },
|
|
8127
|
+
sizes: {
|
|
8128
|
+
sm: { padding: "0.25rem 0" },
|
|
8129
|
+
md: { padding: "0.5rem 0" },
|
|
8130
|
+
lg: { padding: "0.625rem 0" },
|
|
8131
|
+
xl: { padding: "0.75rem 0" }
|
|
8132
|
+
},
|
|
8133
|
+
effects: {
|
|
8134
|
+
hover: [{ effectId: "opacity-reduce", options: { reduction: -20 } }]
|
|
8135
|
+
}
|
|
8136
|
+
}
|
|
8137
|
+
]
|
|
8256
8138
|
}
|
|
8257
8139
|
});
|
|
8258
|
-
var pageDesignIntentV1Schema = z12.object({
|
|
8259
|
-
schemaVersion: z12.literal(pageDesignIntentSchemaVersion),
|
|
8260
|
-
siteStyleId: z12.string().min(1).transform(asSiteStyleId),
|
|
8261
|
-
pageFlowPresetId: z12.string().min(1).transform(asPageFlowPresetId),
|
|
8262
|
-
blockLookPins: z12.array(pageDesignBlockLookPinSchema),
|
|
8263
|
-
boundaryPins: z12.array(pageDesignBoundaryPinSchema)
|
|
8264
|
-
}).strict().superRefine((intent, ctx) => {
|
|
8265
|
-
addDuplicateStringIssues(ctx, {
|
|
8266
|
-
values: intent.blockLookPins.map((pin) => pin.blockId),
|
|
8267
|
-
path: ["blockLookPins"],
|
|
8268
|
-
label: "block Look pin"
|
|
8269
|
-
});
|
|
8270
|
-
addDuplicateStringIssues(ctx, {
|
|
8271
|
-
values: intent.boundaryPins.map(
|
|
8272
|
-
(pin) => boundaryKey(pin.previousBlockId, pin.nextBlockId)
|
|
8273
|
-
),
|
|
8274
|
-
path: ["boundaryPins"],
|
|
8275
|
-
label: "boundary pin"
|
|
8276
|
-
});
|
|
8277
|
-
});
|
|
8278
|
-
function addDuplicateStringIssues(ctx, input) {
|
|
8279
|
-
const seen = /* @__PURE__ */ new Set();
|
|
8280
|
-
const duplicates = /* @__PURE__ */ new Set();
|
|
8281
|
-
for (const value of input.values) {
|
|
8282
|
-
if (seen.has(value)) {
|
|
8283
|
-
duplicates.add(value);
|
|
8284
|
-
}
|
|
8285
|
-
seen.add(value);
|
|
8286
|
-
}
|
|
8287
|
-
for (const duplicate of duplicates) {
|
|
8288
|
-
ctx.addIssue({
|
|
8289
|
-
code: z12.ZodIssueCode.custom,
|
|
8290
|
-
path: [...input.path],
|
|
8291
|
-
message: `Duplicate ${input.label}: ${duplicate}.`
|
|
8292
|
-
});
|
|
8293
|
-
}
|
|
8294
|
-
}
|
|
8295
|
-
function boundaryKey(previousBlockId, nextBlockId) {
|
|
8296
|
-
return makeBoundaryId(previousBlockId, nextBlockId);
|
|
8297
|
-
}
|
|
8298
|
-
|
|
8299
|
-
// ../theme-core/src/schema.ts
|
|
8300
|
-
import { z as z25 } from "zod";
|
|
8301
|
-
|
|
8302
|
-
// ../theme-core/src/lib/media.ts
|
|
8303
|
-
import z13 from "zod";
|
|
8304
|
-
var hotspotSchema = z13.object({
|
|
8305
|
-
x: z13.number().min(0).max(1),
|
|
8306
|
-
y: z13.number().min(0).max(1),
|
|
8307
|
-
radius: z13.number().optional()
|
|
8308
|
-
});
|
|
8309
|
-
var rotationSchema = z13.union([z13.literal(0), z13.literal(90), z13.literal(180), z13.literal(270)]);
|
|
8310
|
-
var rectSchema = z13.tuple([z13.number(), z13.number(), z13.number(), z13.number()]);
|
|
8311
|
-
var aspectCropSchema = z13.object({
|
|
8312
|
-
aspect: z13.preprocess((value) => value == null ? void 0 : value, z13.string().optional()),
|
|
8313
|
-
rect: z13.preprocess((value) => value == null ? void 0 : value, rectSchema.optional()),
|
|
8314
|
-
hotspot: z13.preprocess((value) => value == null ? void 0 : value, hotspotSchema.optional()),
|
|
8315
|
-
rotation: z13.preprocess((value) => value == null ? void 0 : value, rotationSchema.optional())
|
|
8316
|
-
});
|
|
8317
|
-
var transformSchema = z13.object({
|
|
8318
|
-
aspectCrops: z13.preprocess((value) => {
|
|
8319
|
-
if (!value || typeof value !== "object" || Array.isArray(value)) {
|
|
8320
|
-
return void 0;
|
|
8321
|
-
}
|
|
8322
|
-
return value;
|
|
8323
|
-
}, z13.record(z13.string(), aspectCropSchema.catch({}))).optional(),
|
|
8324
|
-
rect: rectSchema.optional(),
|
|
8325
|
-
hotspot: hotspotSchema.optional(),
|
|
8326
|
-
rotation: rotationSchema.optional()
|
|
8327
|
-
});
|
|
8328
|
-
var mediaSchema = z13.object({
|
|
8329
|
-
type: z13.enum(["image", "video", "audio", "document", "spreadsheet", "archive"]),
|
|
8330
|
-
purpose: z13.string().optional(),
|
|
8331
|
-
placeholder: z13.boolean().default(true).optional(),
|
|
8332
|
-
assetId: z13.string().optional(),
|
|
8333
|
-
identifier: z13.string().optional(),
|
|
8334
|
-
src: z13.string().optional(),
|
|
8335
|
-
alt: z13.string().optional(),
|
|
8336
|
-
filename: z13.string().optional(),
|
|
8337
|
-
mimeType: z13.string().optional(),
|
|
8338
|
-
width: z13.number().optional(),
|
|
8339
|
-
height: z13.number().optional(),
|
|
8340
|
-
storageBucket: z13.string().optional(),
|
|
8341
|
-
storagePath: z13.string().optional(),
|
|
8342
|
-
transform: transformSchema.optional()
|
|
8343
|
-
});
|
|
8344
|
-
|
|
8345
|
-
// ../theme-core/src/buttons/types.ts
|
|
8346
|
-
import { z as z14 } from "zod";
|
|
8347
|
-
var VARIANT_ROLES = [
|
|
8348
|
-
"primary",
|
|
8349
|
-
"secondary",
|
|
8350
|
-
"outline",
|
|
8351
|
-
"ghost",
|
|
8352
|
-
"link",
|
|
8353
|
-
"tertiary",
|
|
8354
|
-
"accent"
|
|
8355
|
-
];
|
|
8356
|
-
var cornerStyleSchema = z14.enum(["square", "rounded", "pill"]);
|
|
8357
|
-
var shadowSizeSchema = z14.enum(["none", "low", "medium", "high"]);
|
|
8358
|
-
var textTransformSchema = z14.enum(["none", "uppercase", "lowercase", "capitalize"]);
|
|
8359
|
-
var fontWeightSchema = z14.union([z14.literal(500), z14.literal(600), z14.literal(700)]);
|
|
8360
|
-
var buttonTypographySchema = z14.enum(["body", "heading"]);
|
|
8361
|
-
var letterSpacingSchema = z14.enum(["tight", "normal", "loose"]);
|
|
8362
|
-
var hoverTransformSchema = z14.enum(["none", "lift", "scale", "press"]);
|
|
8363
|
-
var hoverColorSchema = z14.enum(["none", "brighten", "darken", "saturate", "token"]);
|
|
8364
|
-
var buttonPaddingPresetSchema = z14.enum(["compact", "default", "spacious"]);
|
|
8365
|
-
var gradientStyleSchema = z14.enum(["linear", "radial", "conic"]);
|
|
8366
|
-
var gradientSharpnessSchema = z14.enum(["smooth", "medium", "hard"]);
|
|
8367
|
-
var prioritySchema = z14.union([z14.literal(1), z14.literal(2), z14.literal(3)]);
|
|
8368
|
-
var variantRoleSchema = z14.enum(VARIANT_ROLES);
|
|
8369
|
-
var buttonSizeNameSchema = z14.enum(["sm", "md", "lg", "xl"]);
|
|
8370
|
-
var PADDING_TOKEN_PATTERN = /^(?:0|\d+(?:\.\d+)?(?:rem|em|px|%))$/;
|
|
8371
|
-
var paddingShorthandSchema = z14.string().refine(
|
|
8372
|
-
(value) => {
|
|
8373
|
-
const parts = value.split(/\s+/).filter(Boolean);
|
|
8374
|
-
return parts.length === 2 && parts.every((token) => PADDING_TOKEN_PATTERN.test(token));
|
|
8375
|
-
},
|
|
8376
|
-
{
|
|
8377
|
-
message: 'Padding must be two space-separated CSS length tokens (e.g. "0.5rem 1rem"). Use `0` for zero.'
|
|
8378
|
-
}
|
|
8379
|
-
);
|
|
8380
|
-
var buttonSizeConfigSchema = z14.object({
|
|
8381
|
-
padding: paddingShorthandSchema,
|
|
8382
|
-
fontSize: z14.string().optional()
|
|
8383
|
-
});
|
|
8384
|
-
var buttonSizesSchema = z14.object({
|
|
8385
|
-
sm: buttonSizeConfigSchema,
|
|
8386
|
-
md: buttonSizeConfigSchema,
|
|
8387
|
-
lg: buttonSizeConfigSchema,
|
|
8388
|
-
xl: buttonSizeConfigSchema.optional()
|
|
8389
|
-
}).transform(({ sm, md, lg, xl }) => ({
|
|
8390
|
-
sm,
|
|
8391
|
-
md,
|
|
8392
|
-
lg,
|
|
8393
|
-
xl: xl ?? lg
|
|
8394
|
-
}));
|
|
8395
|
-
var buttonGlobalSettingsSchema = z14.object({
|
|
8396
|
-
cornerStyle: cornerStyleSchema,
|
|
8397
|
-
cornerRadius: z14.number().min(0).max(24).optional(),
|
|
8398
|
-
shadow: shadowSizeSchema,
|
|
8399
|
-
textTransform: textTransformSchema,
|
|
8400
|
-
fontWeight: fontWeightSchema,
|
|
8401
|
-
/**
|
|
8402
|
-
* @deprecated Set per-variant via `variant.border.widthClass` instead.
|
|
8403
|
-
* Schema field is preserved so existing presets parse; the value is unread
|
|
8404
|
-
* by the current generator and will be removed once the legacy
|
|
8405
|
-
* `primitives/content/components/Button.tsx` slot exports are deleted.
|
|
8406
|
-
*/
|
|
8407
|
-
borderWidth: z14.union([z14.literal(1), z14.literal(2), z14.literal(3)]),
|
|
8408
|
-
// === Family-level typography ===
|
|
8409
|
-
// Typography source (body or heading) — selects which theme typography pool to inherit
|
|
8410
|
-
typography: buttonTypographySchema.optional(),
|
|
8411
|
-
// Font size for all variants in the family (Tailwind token, e.g. "text-xs", "text-sm")
|
|
8412
|
-
// Sized variants get this as default; fixed variants inherit unless they override.
|
|
8413
|
-
// Size class CSS may still override at run time for sized variants.
|
|
8414
|
-
fontSize: z14.string().optional(),
|
|
8415
|
-
// Letter spacing applied to all variants
|
|
8416
|
-
letterSpacing: letterSpacingSchema.optional(),
|
|
8417
|
-
// Italic style
|
|
8418
|
-
italic: z14.boolean().optional(),
|
|
8419
|
-
// Padding preset (applies to sized variants without a sizes config)
|
|
8420
|
-
paddingPreset: buttonPaddingPresetSchema.optional(),
|
|
8421
|
-
hoverTransform: hoverTransformSchema,
|
|
8422
|
-
hoverColor: hoverColorSchema,
|
|
8423
|
-
// When hoverColor is 'token', this specifies which token to use
|
|
8424
|
-
hoverColorToken: z14.string().optional(),
|
|
8425
|
-
// Gradient settings (if any variant uses gradients)
|
|
8426
|
-
gradientStyle: gradientStyleSchema.optional(),
|
|
8427
|
-
gradientAngle: z14.number().min(0).max(360).optional(),
|
|
8428
|
-
gradientSharpness: gradientSharpnessSchema.optional()
|
|
8429
|
-
});
|
|
8430
|
-
var gradientDirectionSchema = z14.enum(["to-r", "to-l", "to-t", "to-b", "to-tr", "to-tl", "to-br", "to-bl"]);
|
|
8431
|
-
var buttonBackgroundSchema = z14.discriminatedUnion("type", [
|
|
8432
|
-
z14.object({ type: z14.literal("solid"), colorToken: z14.string() }),
|
|
8433
|
-
z14.object({
|
|
8434
|
-
type: z14.literal("gradient"),
|
|
8435
|
-
stops: z14.array(z14.string()).min(2),
|
|
8436
|
-
direction: gradientDirectionSchema
|
|
8437
|
-
}),
|
|
8438
|
-
z14.object({ type: z14.literal("transparent") })
|
|
8439
|
-
]);
|
|
8440
|
-
var effectApplicationSchema = z14.object({
|
|
8441
|
-
effectId: z14.string(),
|
|
8442
|
-
options: z14.record(z14.string(), z14.any()).optional()
|
|
8443
|
-
});
|
|
8444
|
-
var buttonBorderSchema = z14.object({
|
|
8445
|
-
widthClass: z14.string(),
|
|
8446
|
-
colorToken: z14.string()
|
|
8447
|
-
});
|
|
8448
|
-
var variantShadowSchema = z14.object({
|
|
8449
|
-
elevation: z14.enum(["none", "low", "medium", "high"]),
|
|
8450
|
-
softness: z14.enum(["crisp", "soft", "hard"]).nullable(),
|
|
8451
|
-
position: z14.enum(["bottom", "bottom-right"]).default("bottom")
|
|
8452
|
-
});
|
|
8453
|
-
var variantEffectsSchema = z14.object({
|
|
8454
|
-
base: z14.array(effectApplicationSchema).optional(),
|
|
8455
|
-
hover: z14.array(effectApplicationSchema).optional(),
|
|
8456
|
-
active: z14.array(effectApplicationSchema).optional(),
|
|
8457
|
-
focus: z14.array(effectApplicationSchema).optional()
|
|
8458
|
-
});
|
|
8459
|
-
var variantSizeOverridesSchema = z14.object({
|
|
8460
|
-
sm: buttonSizeConfigSchema.optional(),
|
|
8461
|
-
md: buttonSizeConfigSchema.optional(),
|
|
8462
|
-
lg: buttonSizeConfigSchema.optional(),
|
|
8463
|
-
xl: buttonSizeConfigSchema.optional()
|
|
8464
|
-
});
|
|
8465
|
-
var buttonVariantSchema = z14.object({
|
|
8466
|
-
id: z14.string(),
|
|
8467
|
-
name: z14.string().min(1).max(20),
|
|
8468
|
-
enabled: z14.boolean(),
|
|
8469
|
-
priority: prioritySchema,
|
|
8470
|
-
// Base appearance (token-based)
|
|
8471
|
-
background: buttonBackgroundSchema,
|
|
8472
|
-
textColorToken: z14.string(),
|
|
8473
|
-
/** Tailwind radius token (e.g. `'rounded-md'`). Omit to inherit from `global.cornerStyle`. */
|
|
8474
|
-
borderRadius: z14.string().optional(),
|
|
8475
|
-
// Optional shadow override (uses theme.shadow if not specified)
|
|
8476
|
-
shadow: variantShadowSchema.optional(),
|
|
8477
|
-
// Border (optional)
|
|
8478
|
-
border: buttonBorderSchema.optional(),
|
|
8479
|
-
// Hover background token (per-variant override, takes precedence over global hoverColorToken)
|
|
8480
|
-
hoverBackgroundToken: z14.string().optional(),
|
|
8481
|
-
// Effect composition
|
|
8482
|
-
effects: variantEffectsSchema.optional(),
|
|
8483
|
-
// Per-variant size overrides — see VariantSizeOverrides
|
|
8484
|
-
sizes: variantSizeOverridesSchema.optional()
|
|
8485
|
-
});
|
|
8486
|
-
var buttonSystemSchema = z14.object({
|
|
8487
|
-
global: buttonGlobalSettingsSchema,
|
|
8488
|
-
variants: z14.array(buttonVariantSchema).min(1).max(6),
|
|
8489
|
-
sizes: buttonSizesSchema.optional()
|
|
8490
|
-
});
|
|
8491
|
-
|
|
8492
|
-
// ../theme-core/src/buttons/generateButtonCss.ts
|
|
8493
|
-
var BUTTON_SIZE_NAMES = buttonSizeNameSchema.options;
|
|
8494
|
-
|
|
8495
|
-
// ../theme-core/src/buttons/personalities/types.ts
|
|
8496
|
-
import { z as z15 } from "zod";
|
|
8497
|
-
function asButtonPersonalityId(value) {
|
|
8498
|
-
if (value.length === 0) {
|
|
8499
|
-
throw new Error("ButtonPersonalityId must be a non-empty string");
|
|
8500
|
-
}
|
|
8501
|
-
return value;
|
|
8502
|
-
}
|
|
8503
|
-
var buttonPersonalityIdSchema = z15.string().min(1).transform((value) => asButtonPersonalityId(value));
|
|
8504
|
-
var buttonPersonalitySchema = z15.object({
|
|
8505
|
-
id: buttonPersonalityIdSchema,
|
|
8506
|
-
name: z15.string().min(1),
|
|
8507
|
-
description: z15.string().min(1),
|
|
8508
|
-
tags: styleTagsSchema,
|
|
8509
|
-
buttonSystem: buttonSystemSchema
|
|
8510
|
-
});
|
|
8511
|
-
function defineButtonPersonality(input) {
|
|
8512
|
-
return {
|
|
8513
|
-
id: asButtonPersonalityId(input.id),
|
|
8514
|
-
name: input.name,
|
|
8515
|
-
description: input.description,
|
|
8516
|
-
tags: input.tags,
|
|
8517
|
-
buttonSystem: input.buttonSystem
|
|
8518
|
-
};
|
|
8519
|
-
}
|
|
8520
8140
|
|
|
8521
|
-
// ../theme-core/src/buttons/personalities/
|
|
8522
|
-
var
|
|
8523
|
-
id: "
|
|
8524
|
-
name: "
|
|
8525
|
-
description: "
|
|
8526
|
-
tags: { tone: "
|
|
8141
|
+
// ../theme-core/src/buttons/personalities/ink-stamp.ts
|
|
8142
|
+
var inkStamp = defineButtonPersonality({
|
|
8143
|
+
id: "ink-stamp",
|
|
8144
|
+
name: "Ink Stamp",
|
|
8145
|
+
description: "Hand-stamped block-print buttons with a slight lift on hover.",
|
|
8146
|
+
tags: { tone: "bold", energy: "vibrant", motion: "standard", era: "organic" },
|
|
8527
8147
|
buttonSystem: {
|
|
8528
8148
|
global: {
|
|
8529
8149
|
cornerStyle: "rounded",
|
|
8530
|
-
shadow: "
|
|
8531
|
-
textTransform: "
|
|
8532
|
-
fontWeight:
|
|
8150
|
+
shadow: "none",
|
|
8151
|
+
textTransform: "uppercase",
|
|
8152
|
+
fontWeight: 600,
|
|
8533
8153
|
borderWidth: 1,
|
|
8534
8154
|
hoverTransform: "none",
|
|
8535
|
-
hoverColor: "none"
|
|
8155
|
+
hoverColor: "none",
|
|
8156
|
+
letterSpacing: "loose"
|
|
8536
8157
|
},
|
|
8537
8158
|
sizes: {
|
|
8538
|
-
sm: { padding: "0.
|
|
8539
|
-
md: { padding: "
|
|
8540
|
-
lg: { padding: "
|
|
8541
|
-
xl: { padding: "1.
|
|
8159
|
+
sm: { padding: "0.5rem 1.25rem", fontSize: "text-xs" },
|
|
8160
|
+
md: { padding: "0.75rem 1.75rem", fontSize: "text-sm" },
|
|
8161
|
+
lg: { padding: "0.875rem 2.25rem", fontSize: "text-base" },
|
|
8162
|
+
xl: { padding: "1.125rem 2.75rem", fontSize: "text-lg" }
|
|
8542
8163
|
},
|
|
8543
8164
|
variants: [
|
|
8544
8165
|
{
|
|
@@ -8546,16 +8167,15 @@ var brushedWash = defineButtonPersonality({
|
|
|
8546
8167
|
name: "Primary",
|
|
8547
8168
|
enabled: true,
|
|
8548
8169
|
priority: 1,
|
|
8549
|
-
background: {
|
|
8550
|
-
type: "gradient",
|
|
8551
|
-
stops: ["primary", "accent"],
|
|
8552
|
-
direction: "to-r"
|
|
8553
|
-
},
|
|
8170
|
+
background: { type: "solid", colorToken: "primary" },
|
|
8554
8171
|
textColorToken: "primaryForeground",
|
|
8555
|
-
borderRadius: "rounded-
|
|
8556
|
-
shadow: { elevation: "low", softness: "soft", position: "bottom" },
|
|
8172
|
+
borderRadius: "rounded-md",
|
|
8557
8173
|
effects: {
|
|
8558
|
-
hover: [
|
|
8174
|
+
hover: [
|
|
8175
|
+
{ effectId: "drop-shadow", options: { intensity: "medium" } },
|
|
8176
|
+
{ effectId: "scale-up", options: { scale: "1.02" } }
|
|
8177
|
+
],
|
|
8178
|
+
active: [{ effectId: "scale-down", options: { scale: "0.98" } }]
|
|
8559
8179
|
}
|
|
8560
8180
|
},
|
|
8561
8181
|
{
|
|
@@ -8563,16 +8183,12 @@ var brushedWash = defineButtonPersonality({
|
|
|
8563
8183
|
name: "Secondary",
|
|
8564
8184
|
enabled: true,
|
|
8565
8185
|
priority: 2,
|
|
8566
|
-
background: {
|
|
8567
|
-
|
|
8568
|
-
|
|
8569
|
-
|
|
8570
|
-
},
|
|
8571
|
-
textColorToken: "primaryForeground",
|
|
8572
|
-
borderRadius: "rounded-lg",
|
|
8573
|
-
shadow: { elevation: "low", softness: "soft", position: "bottom" },
|
|
8186
|
+
background: { type: "transparent" },
|
|
8187
|
+
textColorToken: "primary",
|
|
8188
|
+
borderRadius: "rounded-md",
|
|
8189
|
+
border: { widthClass: "border-2", colorToken: "primary" },
|
|
8574
8190
|
effects: {
|
|
8575
|
-
hover: [{ effectId: "
|
|
8191
|
+
hover: [{ effectId: "background-on-hover", options: { colorToken: "surface" } }]
|
|
8576
8192
|
}
|
|
8577
8193
|
},
|
|
8578
8194
|
{
|
|
@@ -8581,9 +8197,9 @@ var brushedWash = defineButtonPersonality({
|
|
|
8581
8197
|
enabled: true,
|
|
8582
8198
|
priority: 3,
|
|
8583
8199
|
background: { type: "transparent" },
|
|
8584
|
-
textColorToken: "
|
|
8585
|
-
borderRadius: "rounded-
|
|
8586
|
-
border: { widthClass: "border", colorToken: "
|
|
8200
|
+
textColorToken: "text",
|
|
8201
|
+
borderRadius: "rounded-md",
|
|
8202
|
+
border: { widthClass: "border-2", colorToken: "border" },
|
|
8587
8203
|
effects: {
|
|
8588
8204
|
hover: [{ effectId: "background-on-hover", options: { colorToken: "surface" } }]
|
|
8589
8205
|
}
|
|
@@ -8594,216 +8210,43 @@ var brushedWash = defineButtonPersonality({
|
|
|
8594
8210
|
enabled: true,
|
|
8595
8211
|
priority: 3,
|
|
8596
8212
|
background: { type: "transparent" },
|
|
8597
|
-
textColorToken: "
|
|
8598
|
-
borderRadius: "rounded-
|
|
8213
|
+
textColorToken: "accent",
|
|
8214
|
+
borderRadius: "rounded-none",
|
|
8215
|
+
sizes: {
|
|
8216
|
+
sm: { padding: "0.375rem 0", fontSize: "text-xs" },
|
|
8217
|
+
md: { padding: "0.5rem 0", fontSize: "text-sm" },
|
|
8218
|
+
lg: { padding: "0.625rem 0", fontSize: "text-base" },
|
|
8219
|
+
xl: { padding: "0.75rem 0", fontSize: "text-lg" }
|
|
8220
|
+
},
|
|
8599
8221
|
effects: {
|
|
8600
|
-
|
|
8601
|
-
{ effectId: "background-on-hover", options: { colorToken: "surface" } }
|
|
8602
|
-
]
|
|
8222
|
+
base: [{ effectId: "border-bottom-grow", options: { height: 1, colorToken: "accent", origin: "left" } }]
|
|
8603
8223
|
}
|
|
8604
8224
|
}
|
|
8605
8225
|
]
|
|
8606
8226
|
}
|
|
8607
8227
|
});
|
|
8608
8228
|
|
|
8609
|
-
// ../theme-core/src/buttons/personalities/
|
|
8610
|
-
var
|
|
8611
|
-
id: "
|
|
8612
|
-
name: "
|
|
8613
|
-
description: "
|
|
8614
|
-
tags: { tone: "classic", energy: "calm", motion: "standard", era: "
|
|
8229
|
+
// ../theme-core/src/buttons/personalities/pebble.ts
|
|
8230
|
+
var pebble = defineButtonPersonality({
|
|
8231
|
+
id: "pebble",
|
|
8232
|
+
name: "Pebble",
|
|
8233
|
+
description: "Generous pill buttons with a soft hover lift.",
|
|
8234
|
+
tags: { tone: "classic", energy: "calm", motion: "standard", era: "organic" },
|
|
8615
8235
|
buttonSystem: {
|
|
8616
8236
|
global: {
|
|
8617
|
-
cornerStyle: "
|
|
8618
|
-
shadow: "
|
|
8237
|
+
cornerStyle: "pill",
|
|
8238
|
+
shadow: "none",
|
|
8619
8239
|
textTransform: "none",
|
|
8620
|
-
fontWeight:
|
|
8621
|
-
borderWidth:
|
|
8240
|
+
fontWeight: 500,
|
|
8241
|
+
borderWidth: 2,
|
|
8622
8242
|
hoverTransform: "none",
|
|
8623
8243
|
hoverColor: "none"
|
|
8624
8244
|
},
|
|
8625
|
-
variants: [
|
|
8626
|
-
{
|
|
8627
|
-
id: "primary",
|
|
8628
|
-
name: "Primary",
|
|
8629
|
-
enabled: true,
|
|
8630
|
-
priority: 1,
|
|
8631
|
-
background: { type: "solid", colorToken: "primary" },
|
|
8632
|
-
textColorToken: "primaryForeground",
|
|
8633
|
-
borderRadius: "rounded-md",
|
|
8634
|
-
shadow: { elevation: "medium", softness: "soft", position: "bottom" },
|
|
8635
|
-
effects: {
|
|
8636
|
-
hover: [{ effectId: "darken-background", options: { amount: 60 } }],
|
|
8637
|
-
active: [{ effectId: "scale-down", options: { scale: "0.97" } }]
|
|
8638
|
-
}
|
|
8639
|
-
},
|
|
8640
|
-
{
|
|
8641
|
-
id: "secondary",
|
|
8642
|
-
name: "Secondary",
|
|
8643
|
-
enabled: true,
|
|
8644
|
-
priority: 2,
|
|
8645
|
-
background: { type: "solid", colorToken: "surface" },
|
|
8646
|
-
textColorToken: "text",
|
|
8647
|
-
borderRadius: "rounded-md",
|
|
8648
|
-
border: { widthClass: "border", colorToken: "border" },
|
|
8649
|
-
effects: {
|
|
8650
|
-
hover: [{ effectId: "background-on-hover", options: { colorToken: "background" } }]
|
|
8651
|
-
}
|
|
8652
|
-
},
|
|
8653
|
-
{
|
|
8654
|
-
id: "outline",
|
|
8655
|
-
name: "Outline",
|
|
8656
|
-
enabled: true,
|
|
8657
|
-
priority: 3,
|
|
8658
|
-
background: { type: "transparent" },
|
|
8659
|
-
textColorToken: "primary",
|
|
8660
|
-
borderRadius: "rounded-md",
|
|
8661
|
-
border: { widthClass: "border", colorToken: "primary" },
|
|
8662
|
-
effects: {
|
|
8663
|
-
hover: [{ effectId: "background-on-hover", options: { colorToken: "surface" } }]
|
|
8664
|
-
}
|
|
8665
|
-
},
|
|
8666
|
-
{
|
|
8667
|
-
id: "ghost",
|
|
8668
|
-
name: "Ghost",
|
|
8669
|
-
enabled: true,
|
|
8670
|
-
priority: 3,
|
|
8671
|
-
background: { type: "transparent" },
|
|
8672
|
-
textColorToken: "primary",
|
|
8673
|
-
borderRadius: "rounded-md",
|
|
8674
|
-
effects: {
|
|
8675
|
-
hover: [{ effectId: "background-on-hover", options: { colorToken: "surface" } }]
|
|
8676
|
-
}
|
|
8677
|
-
}
|
|
8678
|
-
]
|
|
8679
|
-
}
|
|
8680
|
-
});
|
|
8681
|
-
|
|
8682
|
-
// ../theme-core/src/buttons/personalities/editorial-link.ts
|
|
8683
|
-
var editorialLink = defineButtonPersonality({
|
|
8684
|
-
id: "editorial-link",
|
|
8685
|
-
name: "Editorial Link",
|
|
8686
|
-
description: "Link-style with a growing underline. Refined, typographic.",
|
|
8687
|
-
tags: { tone: "minimal", energy: "calm", motion: "subtle", era: "editorial" },
|
|
8688
|
-
buttonSystem: {
|
|
8689
|
-
global: {
|
|
8690
|
-
cornerStyle: "square",
|
|
8691
|
-
shadow: "none",
|
|
8692
|
-
textTransform: "none",
|
|
8693
|
-
fontWeight: 500,
|
|
8694
|
-
borderWidth: 1,
|
|
8695
|
-
hoverTransform: "none",
|
|
8696
|
-
hoverColor: "none"
|
|
8697
|
-
},
|
|
8698
|
-
variants: [
|
|
8699
|
-
{
|
|
8700
|
-
id: "primary",
|
|
8701
|
-
name: "Primary",
|
|
8702
|
-
enabled: true,
|
|
8703
|
-
priority: 1,
|
|
8704
|
-
background: { type: "transparent" },
|
|
8705
|
-
textColorToken: "text",
|
|
8706
|
-
borderRadius: "rounded-none",
|
|
8707
|
-
shadow: { elevation: "none", softness: null, position: "bottom" },
|
|
8708
|
-
sizes: {
|
|
8709
|
-
sm: { padding: "0.25rem 0" },
|
|
8710
|
-
md: { padding: "0.5rem 0" },
|
|
8711
|
-
lg: { padding: "0.625rem 0" },
|
|
8712
|
-
xl: { padding: "0.75rem 0" }
|
|
8713
|
-
},
|
|
8714
|
-
effects: {
|
|
8715
|
-
base: [
|
|
8716
|
-
{ effectId: "border-bottom-grow", options: { height: 2, colorToken: "text", origin: "left" } }
|
|
8717
|
-
]
|
|
8718
|
-
}
|
|
8719
|
-
},
|
|
8720
|
-
{
|
|
8721
|
-
id: "secondary",
|
|
8722
|
-
name: "Secondary",
|
|
8723
|
-
enabled: true,
|
|
8724
|
-
priority: 2,
|
|
8725
|
-
background: { type: "transparent" },
|
|
8726
|
-
textColorToken: "mutedText",
|
|
8727
|
-
borderRadius: "rounded-none",
|
|
8728
|
-
shadow: { elevation: "none", softness: null, position: "bottom" },
|
|
8729
|
-
sizes: {
|
|
8730
|
-
sm: { padding: "0.25rem 0" },
|
|
8731
|
-
md: { padding: "0.5rem 0" },
|
|
8732
|
-
lg: { padding: "0.625rem 0" },
|
|
8733
|
-
xl: { padding: "0.75rem 0" }
|
|
8734
|
-
},
|
|
8735
|
-
effects: {
|
|
8736
|
-
base: [
|
|
8737
|
-
{ effectId: "border-bottom-grow", options: { height: 1, colorToken: "mutedText", origin: "left" } }
|
|
8738
|
-
]
|
|
8739
|
-
}
|
|
8740
|
-
},
|
|
8741
|
-
{
|
|
8742
|
-
id: "outline",
|
|
8743
|
-
name: "Outline",
|
|
8744
|
-
enabled: true,
|
|
8745
|
-
priority: 3,
|
|
8746
|
-
background: { type: "transparent" },
|
|
8747
|
-
textColorToken: "accent",
|
|
8748
|
-
borderRadius: "rounded-none",
|
|
8749
|
-
shadow: { elevation: "none", softness: null, position: "bottom" },
|
|
8750
|
-
sizes: {
|
|
8751
|
-
sm: { padding: "0.25rem 0" },
|
|
8752
|
-
md: { padding: "0.5rem 0" },
|
|
8753
|
-
lg: { padding: "0.625rem 0" },
|
|
8754
|
-
xl: { padding: "0.75rem 0" }
|
|
8755
|
-
},
|
|
8756
|
-
effects: {
|
|
8757
|
-
base: [
|
|
8758
|
-
{ effectId: "border-bottom-grow", options: { height: 1, colorToken: "accent", origin: "left" } }
|
|
8759
|
-
]
|
|
8760
|
-
}
|
|
8761
|
-
},
|
|
8762
|
-
{
|
|
8763
|
-
id: "ghost",
|
|
8764
|
-
name: "Ghost",
|
|
8765
|
-
enabled: true,
|
|
8766
|
-
priority: 3,
|
|
8767
|
-
background: { type: "transparent" },
|
|
8768
|
-
textColorToken: "mutedText",
|
|
8769
|
-
borderRadius: "rounded-none",
|
|
8770
|
-
shadow: { elevation: "none", softness: null, position: "bottom" },
|
|
8771
|
-
sizes: {
|
|
8772
|
-
sm: { padding: "0.25rem 0" },
|
|
8773
|
-
md: { padding: "0.5rem 0" },
|
|
8774
|
-
lg: { padding: "0.625rem 0" },
|
|
8775
|
-
xl: { padding: "0.75rem 0" }
|
|
8776
|
-
},
|
|
8777
|
-
effects: {
|
|
8778
|
-
hover: [{ effectId: "opacity-reduce", options: { reduction: -20 } }]
|
|
8779
|
-
}
|
|
8780
|
-
}
|
|
8781
|
-
]
|
|
8782
|
-
}
|
|
8783
|
-
});
|
|
8784
|
-
|
|
8785
|
-
// ../theme-core/src/buttons/personalities/ink-stamp.ts
|
|
8786
|
-
var inkStamp = defineButtonPersonality({
|
|
8787
|
-
id: "ink-stamp",
|
|
8788
|
-
name: "Ink Stamp",
|
|
8789
|
-
description: "Hand-stamped block-print buttons with a slight lift on hover.",
|
|
8790
|
-
tags: { tone: "bold", energy: "vibrant", motion: "standard", era: "organic" },
|
|
8791
|
-
buttonSystem: {
|
|
8792
|
-
global: {
|
|
8793
|
-
cornerStyle: "rounded",
|
|
8794
|
-
shadow: "none",
|
|
8795
|
-
textTransform: "uppercase",
|
|
8796
|
-
fontWeight: 600,
|
|
8797
|
-
borderWidth: 1,
|
|
8798
|
-
hoverTransform: "none",
|
|
8799
|
-
hoverColor: "none",
|
|
8800
|
-
letterSpacing: "loose"
|
|
8801
|
-
},
|
|
8802
8245
|
sizes: {
|
|
8803
|
-
sm: { padding: "0.
|
|
8804
|
-
md: { padding: "0.
|
|
8805
|
-
lg: { padding: "
|
|
8806
|
-
xl: { padding: "1.
|
|
8246
|
+
sm: { padding: "0.625rem 1.75rem", fontSize: "text-sm" },
|
|
8247
|
+
md: { padding: "0.875rem 2.25rem" },
|
|
8248
|
+
lg: { padding: "1.125rem 2.75rem", fontSize: "text-lg" },
|
|
8249
|
+
xl: { padding: "1.5rem 3.5rem", fontSize: "text-xl" }
|
|
8807
8250
|
},
|
|
8808
8251
|
variants: [
|
|
8809
8252
|
{
|
|
@@ -8813,13 +8256,12 @@ var inkStamp = defineButtonPersonality({
|
|
|
8813
8256
|
priority: 1,
|
|
8814
8257
|
background: { type: "solid", colorToken: "primary" },
|
|
8815
8258
|
textColorToken: "primaryForeground",
|
|
8816
|
-
borderRadius: "rounded-
|
|
8259
|
+
borderRadius: "rounded-full",
|
|
8817
8260
|
effects: {
|
|
8818
8261
|
hover: [
|
|
8819
|
-
{ effectId: "
|
|
8820
|
-
{ effectId: "
|
|
8821
|
-
]
|
|
8822
|
-
active: [{ effectId: "scale-down", options: { scale: "0.98" } }]
|
|
8262
|
+
{ effectId: "scale-up", options: { scale: "1.03" } },
|
|
8263
|
+
{ effectId: "drop-shadow", options: { intensity: "medium" } }
|
|
8264
|
+
]
|
|
8823
8265
|
}
|
|
8824
8266
|
},
|
|
8825
8267
|
{
|
|
@@ -8829,10 +8271,10 @@ var inkStamp = defineButtonPersonality({
|
|
|
8829
8271
|
priority: 2,
|
|
8830
8272
|
background: { type: "transparent" },
|
|
8831
8273
|
textColorToken: "primary",
|
|
8832
|
-
borderRadius: "rounded-
|
|
8833
|
-
border: { widthClass: "border-2", colorToken: "
|
|
8274
|
+
borderRadius: "rounded-full",
|
|
8275
|
+
border: { widthClass: "border-2", colorToken: "accent" },
|
|
8834
8276
|
effects: {
|
|
8835
|
-
hover: [{ effectId: "background-on-hover", options: { colorToken: "
|
|
8277
|
+
hover: [{ effectId: "background-on-hover", options: { colorToken: "accent" } }]
|
|
8836
8278
|
}
|
|
8837
8279
|
},
|
|
8838
8280
|
{
|
|
@@ -8842,8 +8284,8 @@ var inkStamp = defineButtonPersonality({
|
|
|
8842
8284
|
priority: 3,
|
|
8843
8285
|
background: { type: "transparent" },
|
|
8844
8286
|
textColorToken: "text",
|
|
8845
|
-
borderRadius: "rounded-
|
|
8846
|
-
border: { widthClass: "border
|
|
8287
|
+
borderRadius: "rounded-full",
|
|
8288
|
+
border: { widthClass: "border", colorToken: "border" },
|
|
8847
8289
|
effects: {
|
|
8848
8290
|
hover: [{ effectId: "background-on-hover", options: { colorToken: "surface" } }]
|
|
8849
8291
|
}
|
|
@@ -8854,44 +8296,38 @@ var inkStamp = defineButtonPersonality({
|
|
|
8854
8296
|
enabled: true,
|
|
8855
8297
|
priority: 3,
|
|
8856
8298
|
background: { type: "transparent" },
|
|
8857
|
-
textColorToken: "
|
|
8858
|
-
borderRadius: "rounded-
|
|
8299
|
+
textColorToken: "primary",
|
|
8300
|
+
borderRadius: "rounded-full",
|
|
8859
8301
|
sizes: {
|
|
8860
|
-
sm: { padding: "0.375rem 0", fontSize: "text-
|
|
8861
|
-
md: { padding: "0.5rem
|
|
8862
|
-
lg: { padding: "0.625rem
|
|
8863
|
-
xl: { padding: "0.75rem
|
|
8302
|
+
sm: { padding: "0.375rem 0.875rem", fontSize: "text-sm" },
|
|
8303
|
+
md: { padding: "0.5rem 1rem" },
|
|
8304
|
+
lg: { padding: "0.625rem 1.25rem", fontSize: "text-lg" },
|
|
8305
|
+
xl: { padding: "0.75rem 1.5rem", fontSize: "text-xl" }
|
|
8864
8306
|
},
|
|
8865
8307
|
effects: {
|
|
8866
|
-
|
|
8308
|
+
hover: [{ effectId: "opacity-reduce", options: { reduction: 30 } }]
|
|
8867
8309
|
}
|
|
8868
8310
|
}
|
|
8869
8311
|
]
|
|
8870
8312
|
}
|
|
8871
8313
|
});
|
|
8872
8314
|
|
|
8873
|
-
// ../theme-core/src/buttons/personalities/
|
|
8874
|
-
var
|
|
8875
|
-
id: "
|
|
8876
|
-
name: "
|
|
8877
|
-
description: "
|
|
8878
|
-
tags: { tone: "classic", energy: "calm", motion: "
|
|
8315
|
+
// ../theme-core/src/buttons/personalities/soft-pill.ts
|
|
8316
|
+
var softPill = defineButtonPersonality({
|
|
8317
|
+
id: "soft-pill",
|
|
8318
|
+
name: "Soft Pill",
|
|
8319
|
+
description: "Rounded pills with a gentle lift on hover. Quietly modern.",
|
|
8320
|
+
tags: { tone: "classic", energy: "calm", motion: "subtle", era: "organic" },
|
|
8879
8321
|
buttonSystem: {
|
|
8880
8322
|
global: {
|
|
8881
8323
|
cornerStyle: "pill",
|
|
8882
|
-
shadow: "
|
|
8324
|
+
shadow: "low",
|
|
8883
8325
|
textTransform: "none",
|
|
8884
8326
|
fontWeight: 500,
|
|
8885
8327
|
borderWidth: 2,
|
|
8886
|
-
hoverTransform: "
|
|
8328
|
+
hoverTransform: "lift",
|
|
8887
8329
|
hoverColor: "none"
|
|
8888
8330
|
},
|
|
8889
|
-
sizes: {
|
|
8890
|
-
sm: { padding: "0.625rem 1.75rem", fontSize: "text-sm" },
|
|
8891
|
-
md: { padding: "0.875rem 2.25rem" },
|
|
8892
|
-
lg: { padding: "1.125rem 2.75rem", fontSize: "text-lg" },
|
|
8893
|
-
xl: { padding: "1.5rem 3.5rem", fontSize: "text-xl" }
|
|
8894
|
-
},
|
|
8895
8331
|
variants: [
|
|
8896
8332
|
{
|
|
8897
8333
|
id: "primary",
|
|
@@ -8901,11 +8337,10 @@ var pebble = defineButtonPersonality({
|
|
|
8901
8337
|
background: { type: "solid", colorToken: "primary" },
|
|
8902
8338
|
textColorToken: "primaryForeground",
|
|
8903
8339
|
borderRadius: "rounded-full",
|
|
8340
|
+
shadow: { elevation: "low", softness: "soft", position: "bottom" },
|
|
8904
8341
|
effects: {
|
|
8905
|
-
hover: [
|
|
8906
|
-
|
|
8907
|
-
{ effectId: "drop-shadow", options: { intensity: "medium" } }
|
|
8908
|
-
]
|
|
8342
|
+
hover: [{ effectId: "lift", options: { translateY: "-1px" } }],
|
|
8343
|
+
active: [{ effectId: "scale-down", options: { scale: "0.98" } }]
|
|
8909
8344
|
}
|
|
8910
8345
|
},
|
|
8911
8346
|
{
|
|
@@ -8916,9 +8351,9 @@ var pebble = defineButtonPersonality({
|
|
|
8916
8351
|
background: { type: "transparent" },
|
|
8917
8352
|
textColorToken: "primary",
|
|
8918
8353
|
borderRadius: "rounded-full",
|
|
8919
|
-
border: { widthClass: "border-2", colorToken: "
|
|
8354
|
+
border: { widthClass: "border-2", colorToken: "primary" },
|
|
8920
8355
|
effects: {
|
|
8921
|
-
hover: [{ effectId: "background-on-hover", options: { colorToken: "
|
|
8356
|
+
hover: [{ effectId: "background-on-hover", options: { colorToken: "surface" } }]
|
|
8922
8357
|
}
|
|
8923
8358
|
},
|
|
8924
8359
|
{
|
|
@@ -8940,86 +8375,7 @@ var pebble = defineButtonPersonality({
|
|
|
8940
8375
|
enabled: true,
|
|
8941
8376
|
priority: 3,
|
|
8942
8377
|
background: { type: "transparent" },
|
|
8943
|
-
textColorToken: "
|
|
8944
|
-
borderRadius: "rounded-full",
|
|
8945
|
-
sizes: {
|
|
8946
|
-
sm: { padding: "0.375rem 0.875rem", fontSize: "text-sm" },
|
|
8947
|
-
md: { padding: "0.5rem 1rem" },
|
|
8948
|
-
lg: { padding: "0.625rem 1.25rem", fontSize: "text-lg" },
|
|
8949
|
-
xl: { padding: "0.75rem 1.5rem", fontSize: "text-xl" }
|
|
8950
|
-
},
|
|
8951
|
-
effects: {
|
|
8952
|
-
hover: [{ effectId: "opacity-reduce", options: { reduction: 30 } }]
|
|
8953
|
-
}
|
|
8954
|
-
}
|
|
8955
|
-
]
|
|
8956
|
-
}
|
|
8957
|
-
});
|
|
8958
|
-
|
|
8959
|
-
// ../theme-core/src/buttons/personalities/soft-pill.ts
|
|
8960
|
-
var softPill = defineButtonPersonality({
|
|
8961
|
-
id: "soft-pill",
|
|
8962
|
-
name: "Soft Pill",
|
|
8963
|
-
description: "Rounded pills with a gentle lift on hover. Quietly modern.",
|
|
8964
|
-
tags: { tone: "classic", energy: "calm", motion: "subtle", era: "organic" },
|
|
8965
|
-
buttonSystem: {
|
|
8966
|
-
global: {
|
|
8967
|
-
cornerStyle: "pill",
|
|
8968
|
-
shadow: "low",
|
|
8969
|
-
textTransform: "none",
|
|
8970
|
-
fontWeight: 500,
|
|
8971
|
-
borderWidth: 2,
|
|
8972
|
-
hoverTransform: "lift",
|
|
8973
|
-
hoverColor: "none"
|
|
8974
|
-
},
|
|
8975
|
-
variants: [
|
|
8976
|
-
{
|
|
8977
|
-
id: "primary",
|
|
8978
|
-
name: "Primary",
|
|
8979
|
-
enabled: true,
|
|
8980
|
-
priority: 1,
|
|
8981
|
-
background: { type: "solid", colorToken: "primary" },
|
|
8982
|
-
textColorToken: "primaryForeground",
|
|
8983
|
-
borderRadius: "rounded-full",
|
|
8984
|
-
shadow: { elevation: "low", softness: "soft", position: "bottom" },
|
|
8985
|
-
effects: {
|
|
8986
|
-
hover: [{ effectId: "lift", options: { translateY: "-1px" } }],
|
|
8987
|
-
active: [{ effectId: "scale-down", options: { scale: "0.98" } }]
|
|
8988
|
-
}
|
|
8989
|
-
},
|
|
8990
|
-
{
|
|
8991
|
-
id: "secondary",
|
|
8992
|
-
name: "Secondary",
|
|
8993
|
-
enabled: true,
|
|
8994
|
-
priority: 2,
|
|
8995
|
-
background: { type: "transparent" },
|
|
8996
|
-
textColorToken: "primary",
|
|
8997
|
-
borderRadius: "rounded-full",
|
|
8998
|
-
border: { widthClass: "border-2", colorToken: "primary" },
|
|
8999
|
-
effects: {
|
|
9000
|
-
hover: [{ effectId: "background-on-hover", options: { colorToken: "surface" } }]
|
|
9001
|
-
}
|
|
9002
|
-
},
|
|
9003
|
-
{
|
|
9004
|
-
id: "outline",
|
|
9005
|
-
name: "Outline",
|
|
9006
|
-
enabled: true,
|
|
9007
|
-
priority: 3,
|
|
9008
|
-
background: { type: "transparent" },
|
|
9009
|
-
textColorToken: "text",
|
|
9010
|
-
borderRadius: "rounded-full",
|
|
9011
|
-
border: { widthClass: "border", colorToken: "border" },
|
|
9012
|
-
effects: {
|
|
9013
|
-
hover: [{ effectId: "background-on-hover", options: { colorToken: "surface" } }]
|
|
9014
|
-
}
|
|
9015
|
-
},
|
|
9016
|
-
{
|
|
9017
|
-
id: "ghost",
|
|
9018
|
-
name: "Ghost",
|
|
9019
|
-
enabled: true,
|
|
9020
|
-
priority: 3,
|
|
9021
|
-
background: { type: "transparent" },
|
|
9022
|
-
textColorToken: "text",
|
|
8378
|
+
textColorToken: "text",
|
|
9023
8379
|
borderRadius: "rounded-full",
|
|
9024
8380
|
effects: {
|
|
9025
8381
|
hover: [{ effectId: "background-on-hover", options: { colorToken: "surface" } }]
|
|
@@ -9042,49 +8398,101 @@ var personalitiesById = new Map(
|
|
|
9042
8398
|
buttonPersonalities.map((p) => [p.id, p])
|
|
9043
8399
|
);
|
|
9044
8400
|
|
|
8401
|
+
// ../theme-core/src/palette/variants/types.ts
|
|
8402
|
+
import { z as z23 } from "zod";
|
|
8403
|
+
|
|
8404
|
+
// ../theme-core/src/schema.ts
|
|
8405
|
+
import { z as z22 } from "zod";
|
|
8406
|
+
|
|
8407
|
+
// ../theme-core/src/lib/media.ts
|
|
8408
|
+
import z12 from "zod";
|
|
8409
|
+
var hotspotSchema = z12.object({
|
|
8410
|
+
x: z12.number().min(0).max(1),
|
|
8411
|
+
y: z12.number().min(0).max(1),
|
|
8412
|
+
radius: z12.number().optional()
|
|
8413
|
+
});
|
|
8414
|
+
var rotationSchema = z12.union([z12.literal(0), z12.literal(90), z12.literal(180), z12.literal(270)]);
|
|
8415
|
+
var rectSchema = z12.tuple([z12.number(), z12.number(), z12.number(), z12.number()]);
|
|
8416
|
+
var aspectCropSchema = z12.object({
|
|
8417
|
+
aspect: z12.preprocess((value) => value == null ? void 0 : value, z12.string().optional()),
|
|
8418
|
+
rect: z12.preprocess((value) => value == null ? void 0 : value, rectSchema.optional()),
|
|
8419
|
+
hotspot: z12.preprocess((value) => value == null ? void 0 : value, hotspotSchema.optional()),
|
|
8420
|
+
rotation: z12.preprocess((value) => value == null ? void 0 : value, rotationSchema.optional())
|
|
8421
|
+
});
|
|
8422
|
+
var transformSchema = z12.object({
|
|
8423
|
+
aspectCrops: z12.preprocess((value) => {
|
|
8424
|
+
if (!value || typeof value !== "object" || Array.isArray(value)) {
|
|
8425
|
+
return void 0;
|
|
8426
|
+
}
|
|
8427
|
+
return value;
|
|
8428
|
+
}, z12.record(z12.string(), aspectCropSchema.catch({}))).optional(),
|
|
8429
|
+
rect: rectSchema.optional(),
|
|
8430
|
+
hotspot: hotspotSchema.optional(),
|
|
8431
|
+
rotation: rotationSchema.optional()
|
|
8432
|
+
});
|
|
8433
|
+
var mediaSchema = z12.object({
|
|
8434
|
+
type: z12.enum(["image", "video", "audio", "document", "spreadsheet", "archive"]),
|
|
8435
|
+
purpose: z12.string().optional(),
|
|
8436
|
+
placeholder: z12.boolean().default(true).optional(),
|
|
8437
|
+
assetId: z12.string().optional(),
|
|
8438
|
+
identifier: z12.string().optional(),
|
|
8439
|
+
src: z12.string().optional(),
|
|
8440
|
+
alt: z12.string().optional(),
|
|
8441
|
+
filename: z12.string().optional(),
|
|
8442
|
+
mimeType: z12.string().optional(),
|
|
8443
|
+
width: z12.number().optional(),
|
|
8444
|
+
height: z12.number().optional(),
|
|
8445
|
+
storageBucket: z12.string().optional(),
|
|
8446
|
+
storagePath: z12.string().optional(),
|
|
8447
|
+
transform: transformSchema.optional()
|
|
8448
|
+
});
|
|
8449
|
+
|
|
8450
|
+
// ../theme-core/src/buttons/generateButtonCss.ts
|
|
8451
|
+
var BUTTON_SIZE_NAMES = buttonSizeNameSchema.options;
|
|
8452
|
+
|
|
9045
8453
|
// ../theme-core/src/cards/types.ts
|
|
9046
|
-
import { z as
|
|
9047
|
-
var cardSpacingSchema =
|
|
9048
|
-
var gradientDirectionSchema2 =
|
|
9049
|
-
var cardBackgroundSchema =
|
|
9050
|
-
|
|
9051
|
-
|
|
9052
|
-
type:
|
|
9053
|
-
fromToken:
|
|
9054
|
-
toToken:
|
|
8454
|
+
import { z as z13 } from "zod";
|
|
8455
|
+
var cardSpacingSchema = z13.enum(["none", "compact", "cozy", "medium", "comfortable", "spacious"]);
|
|
8456
|
+
var gradientDirectionSchema2 = z13.enum(["to-r", "to-l", "to-t", "to-b", "to-tr", "to-tl", "to-br", "to-bl"]);
|
|
8457
|
+
var cardBackgroundSchema = z13.discriminatedUnion("type", [
|
|
8458
|
+
z13.object({ type: z13.literal("solid"), colorToken: z13.string() }),
|
|
8459
|
+
z13.object({
|
|
8460
|
+
type: z13.literal("gradient"),
|
|
8461
|
+
fromToken: z13.string(),
|
|
8462
|
+
toToken: z13.string(),
|
|
9055
8463
|
direction: gradientDirectionSchema2
|
|
9056
8464
|
}),
|
|
9057
|
-
|
|
8465
|
+
z13.object({ type: z13.literal("transparent") })
|
|
9058
8466
|
]);
|
|
9059
|
-
var cardBorderSchema =
|
|
9060
|
-
widthClass:
|
|
9061
|
-
colorToken:
|
|
9062
|
-
});
|
|
9063
|
-
var cardVariantSchema =
|
|
9064
|
-
id:
|
|
9065
|
-
name:
|
|
9066
|
-
enabled:
|
|
9067
|
-
priority:
|
|
8467
|
+
var cardBorderSchema = z13.object({
|
|
8468
|
+
widthClass: z13.string(),
|
|
8469
|
+
colorToken: z13.string()
|
|
8470
|
+
});
|
|
8471
|
+
var cardVariantSchema = z13.object({
|
|
8472
|
+
id: z13.string(),
|
|
8473
|
+
name: z13.string().min(1).max(20),
|
|
8474
|
+
enabled: z13.boolean(),
|
|
8475
|
+
priority: z13.union([z13.literal(1), z13.literal(2), z13.literal(3)]),
|
|
9068
8476
|
// Appearance (token-based)
|
|
9069
8477
|
background: cardBackgroundSchema,
|
|
9070
8478
|
spacing: cardSpacingSchema,
|
|
9071
8479
|
// Optional overrides (uses theme defaults if not specified)
|
|
9072
|
-
shadow:
|
|
9073
|
-
elevation:
|
|
9074
|
-
softness:
|
|
9075
|
-
position:
|
|
8480
|
+
shadow: z13.object({
|
|
8481
|
+
elevation: z13.enum(["none", "low", "medium", "high"]),
|
|
8482
|
+
softness: z13.enum(["crisp", "soft", "hard"]).nullable(),
|
|
8483
|
+
position: z13.enum(["bottom", "bottom-right"]).default("bottom")
|
|
9076
8484
|
}).optional(),
|
|
9077
|
-
corners:
|
|
8485
|
+
corners: z13.enum(["square", "soft", "rounded", "pill"]).optional(),
|
|
9078
8486
|
// Border (optional)
|
|
9079
8487
|
border: cardBorderSchema.optional()
|
|
9080
8488
|
});
|
|
9081
|
-
var cardSystemSchema =
|
|
9082
|
-
variants:
|
|
8489
|
+
var cardSystemSchema = z13.object({
|
|
8490
|
+
variants: z13.array(cardVariantSchema).min(1).max(3)
|
|
9083
8491
|
});
|
|
9084
8492
|
|
|
9085
8493
|
// ../theme-core/src/accordions/types.ts
|
|
9086
|
-
import { z as
|
|
9087
|
-
var accordionIconSchema =
|
|
8494
|
+
import { z as z14 } from "zod";
|
|
8495
|
+
var accordionIconSchema = z14.enum([
|
|
9088
8496
|
"plus-minus",
|
|
9089
8497
|
// + becomes - (swap or rotate 90°)
|
|
9090
8498
|
"chevron",
|
|
@@ -9096,180 +8504,180 @@ var accordionIconSchema = z17.enum([
|
|
|
9096
8504
|
"circle-plus-minus"
|
|
9097
8505
|
// ⊕ becomes ⊖ (swap with fade)
|
|
9098
8506
|
]);
|
|
9099
|
-
var accordionSystemSchema =
|
|
8507
|
+
var accordionSystemSchema = z14.object({
|
|
9100
8508
|
// Visual styling (solid color only - gradients can be added later if needed)
|
|
9101
|
-
background:
|
|
9102
|
-
type:
|
|
9103
|
-
colorToken:
|
|
8509
|
+
background: z14.object({
|
|
8510
|
+
type: z14.literal("solid"),
|
|
8511
|
+
colorToken: z14.string()
|
|
9104
8512
|
}),
|
|
9105
8513
|
// Spacing (padding inside items)
|
|
9106
|
-
spacing:
|
|
8514
|
+
spacing: z14.enum(["none", "compact", "cozy", "medium", "comfortable", "spacious"]),
|
|
9107
8515
|
// Border radius (null = inherit from theme.corners)
|
|
9108
|
-
corners:
|
|
8516
|
+
corners: z14.enum(["square", "soft", "rounded", "pill"]).nullable(),
|
|
9109
8517
|
// Border styling (null = inherit from theme.border)
|
|
9110
|
-
border:
|
|
9111
|
-
widthClass:
|
|
8518
|
+
border: z14.object({
|
|
8519
|
+
widthClass: z14.string(),
|
|
9112
8520
|
// e.g., 'border', 'border-2', 'border-0'
|
|
9113
|
-
colorToken:
|
|
8521
|
+
colorToken: z14.string()
|
|
9114
8522
|
}).nullable(),
|
|
9115
8523
|
// Shadow (null = inherit from theme.shadow)
|
|
9116
|
-
shadow:
|
|
9117
|
-
elevation:
|
|
9118
|
-
softness:
|
|
9119
|
-
position:
|
|
8524
|
+
shadow: z14.object({
|
|
8525
|
+
elevation: z14.enum(["none", "low", "medium", "high"]),
|
|
8526
|
+
softness: z14.enum(["soft", "crisp", "hard"]).nullable(),
|
|
8527
|
+
position: z14.enum(["bottom", "bottom-right"])
|
|
9120
8528
|
}).nullable(),
|
|
9121
8529
|
// Icon style and animation
|
|
9122
|
-
icon:
|
|
8530
|
+
icon: z14.object({
|
|
9123
8531
|
style: accordionIconSchema,
|
|
9124
|
-
position:
|
|
9125
|
-
size:
|
|
8532
|
+
position: z14.enum(["left", "right"]),
|
|
8533
|
+
size: z14.enum(["sm", "md", "lg"])
|
|
9126
8534
|
}),
|
|
9127
8535
|
// Trigger (question) styling
|
|
9128
|
-
trigger:
|
|
9129
|
-
textColorToken:
|
|
9130
|
-
fontWeight:
|
|
8536
|
+
trigger: z14.object({
|
|
8537
|
+
textColorToken: z14.string(),
|
|
8538
|
+
fontWeight: z14.enum(["regular", "medium", "semibold", "bold"]).nullable()
|
|
9131
8539
|
// null = inherit from theme
|
|
9132
8540
|
}),
|
|
9133
8541
|
// Hover state styling
|
|
9134
|
-
hover:
|
|
9135
|
-
backgroundColorToken:
|
|
9136
|
-
textColorToken:
|
|
9137
|
-
borderColorToken:
|
|
8542
|
+
hover: z14.object({
|
|
8543
|
+
backgroundColorToken: z14.string().optional(),
|
|
8544
|
+
textColorToken: z14.string().optional(),
|
|
8545
|
+
borderColorToken: z14.string().optional()
|
|
9138
8546
|
}),
|
|
9139
8547
|
// Content (answer) styling
|
|
9140
|
-
content:
|
|
9141
|
-
textColorToken:
|
|
8548
|
+
content: z14.object({
|
|
8549
|
+
textColorToken: z14.string()
|
|
9142
8550
|
})
|
|
9143
8551
|
});
|
|
9144
8552
|
|
|
9145
8553
|
// ../theme-core/src/inputs/types.ts
|
|
9146
|
-
import { z as
|
|
9147
|
-
var inputSystemSchema =
|
|
8554
|
+
import { z as z15 } from "zod";
|
|
8555
|
+
var inputSystemSchema = z15.object({
|
|
9148
8556
|
// Base styling (applied to all inputs)
|
|
9149
|
-
base:
|
|
9150
|
-
background:
|
|
9151
|
-
|
|
9152
|
-
type:
|
|
9153
|
-
colorToken:
|
|
8557
|
+
base: z15.object({
|
|
8558
|
+
background: z15.union([
|
|
8559
|
+
z15.object({
|
|
8560
|
+
type: z15.literal("solid"),
|
|
8561
|
+
colorToken: z15.string()
|
|
9154
8562
|
}),
|
|
9155
|
-
|
|
9156
|
-
type:
|
|
8563
|
+
z15.object({
|
|
8564
|
+
type: z15.literal("transparent")
|
|
9157
8565
|
})
|
|
9158
8566
|
]),
|
|
9159
|
-
textColorToken:
|
|
9160
|
-
border:
|
|
9161
|
-
widthClass:
|
|
8567
|
+
textColorToken: z15.string(),
|
|
8568
|
+
border: z15.object({
|
|
8569
|
+
widthClass: z15.string(),
|
|
9162
8570
|
// e.g., 'border', 'border-2'
|
|
9163
|
-
colorToken:
|
|
9164
|
-
style:
|
|
8571
|
+
colorToken: z15.string(),
|
|
8572
|
+
style: z15.enum(["all", "underline"]).optional()
|
|
9165
8573
|
}),
|
|
9166
|
-
corners:
|
|
8574
|
+
corners: z15.enum(["square", "soft", "rounded", "pill"]).nullable(),
|
|
9167
8575
|
// null = inherit from theme.corners
|
|
9168
|
-
shadow:
|
|
9169
|
-
elevation:
|
|
9170
|
-
softness:
|
|
8576
|
+
shadow: z15.object({
|
|
8577
|
+
elevation: z15.enum(["none", "low", "medium"]),
|
|
8578
|
+
softness: z15.enum(["soft", "crisp", "hard"]).nullable()
|
|
9171
8579
|
}).nullable(),
|
|
9172
|
-
spacing:
|
|
8580
|
+
spacing: z15.enum(["compact", "cozy", "medium", "comfortable"]),
|
|
9173
8581
|
// padding inside inputs
|
|
9174
|
-
fontSize:
|
|
8582
|
+
fontSize: z15.enum(["sm", "base", "lg"])
|
|
9175
8583
|
}),
|
|
9176
8584
|
// Label styling
|
|
9177
|
-
label:
|
|
9178
|
-
textColorToken:
|
|
9179
|
-
fontWeight:
|
|
9180
|
-
fontSize:
|
|
9181
|
-
textTransform:
|
|
9182
|
-
letterSpacing:
|
|
9183
|
-
opacity:
|
|
8585
|
+
label: z15.object({
|
|
8586
|
+
textColorToken: z15.string(),
|
|
8587
|
+
fontWeight: z15.enum(["regular", "medium", "semibold", "bold", "black"]),
|
|
8588
|
+
fontSize: z15.enum(["2xs", "xs", "sm", "base"]),
|
|
8589
|
+
textTransform: z15.enum(["none", "uppercase", "lowercase", "capitalize"]).optional(),
|
|
8590
|
+
letterSpacing: z15.enum(["normal", "wide", "wider", "widest"]).optional(),
|
|
8591
|
+
opacity: z15.number().min(0.2).max(1).optional()
|
|
9184
8592
|
}),
|
|
9185
8593
|
// Focus state
|
|
9186
|
-
focus:
|
|
9187
|
-
ringColorToken:
|
|
9188
|
-
ringWidth:
|
|
9189
|
-
borderColorToken:
|
|
8594
|
+
focus: z15.object({
|
|
8595
|
+
ringColorToken: z15.string(),
|
|
8596
|
+
ringWidth: z15.enum(["0", "1", "2", "3"]),
|
|
8597
|
+
borderColorToken: z15.string().optional()
|
|
9190
8598
|
// Change border color on focus
|
|
9191
8599
|
}),
|
|
9192
8600
|
// Error state (for validation feedback)
|
|
9193
|
-
error:
|
|
9194
|
-
borderColorToken:
|
|
9195
|
-
textColorToken:
|
|
8601
|
+
error: z15.object({
|
|
8602
|
+
borderColorToken: z15.string(),
|
|
8603
|
+
textColorToken: z15.string()
|
|
9196
8604
|
}),
|
|
9197
8605
|
// Disabled state
|
|
9198
|
-
disabled:
|
|
9199
|
-
backgroundColorToken:
|
|
9200
|
-
textColorToken:
|
|
9201
|
-
opacity:
|
|
8606
|
+
disabled: z15.object({
|
|
8607
|
+
backgroundColorToken: z15.string(),
|
|
8608
|
+
textColorToken: z15.string(),
|
|
8609
|
+
opacity: z15.number().min(0.3).max(0.7)
|
|
9202
8610
|
})
|
|
9203
8611
|
});
|
|
9204
8612
|
|
|
9205
8613
|
// ../theme-core/src/gradients/types.ts
|
|
9206
|
-
import { z as
|
|
9207
|
-
var gradientStopSchema =
|
|
9208
|
-
color:
|
|
8614
|
+
import { z as z16 } from "zod";
|
|
8615
|
+
var gradientStopSchema = z16.object({
|
|
8616
|
+
color: z16.string(),
|
|
9209
8617
|
// Theme color token name (e.g., 'primary-500')
|
|
9210
|
-
position:
|
|
8618
|
+
position: z16.number().min(0).max(100)
|
|
9211
8619
|
// Percentage 0-100
|
|
9212
8620
|
});
|
|
9213
|
-
var gradientConfigSchema =
|
|
9214
|
-
type:
|
|
9215
|
-
angle:
|
|
8621
|
+
var gradientConfigSchema = z16.object({
|
|
8622
|
+
type: z16.enum(["linear", "radial"]),
|
|
8623
|
+
angle: z16.number().min(0).max(360).optional(),
|
|
9216
8624
|
// For linear gradients (degrees)
|
|
9217
|
-
position:
|
|
8625
|
+
position: z16.string().optional(),
|
|
9218
8626
|
// For radial gradients ('center', 'top left', etc.)
|
|
9219
|
-
stops:
|
|
8627
|
+
stops: z16.array(gradientStopSchema).min(2)
|
|
9220
8628
|
});
|
|
9221
8629
|
|
|
9222
8630
|
// ../theme-core/src/navigation/types.ts
|
|
9223
|
-
import { z as
|
|
8631
|
+
import { z as z18 } from "zod";
|
|
9224
8632
|
|
|
9225
8633
|
// ../theme-core/src/interactive/baseSchema.ts
|
|
9226
|
-
import { z as
|
|
9227
|
-
var interactiveTypographySchema =
|
|
8634
|
+
import { z as z17 } from "zod";
|
|
8635
|
+
var interactiveTypographySchema = z17.object({
|
|
9228
8636
|
/** Font family source */
|
|
9229
|
-
typography:
|
|
8637
|
+
typography: z17.enum(["body", "heading"]).default("body"),
|
|
9230
8638
|
/** Font weight */
|
|
9231
|
-
fontWeight:
|
|
8639
|
+
fontWeight: z17.enum(["regular", "medium", "semibold", "bold"]).default("medium"),
|
|
9232
8640
|
/** Text transform */
|
|
9233
|
-
textTransform:
|
|
8641
|
+
textTransform: z17.enum(["none", "uppercase", "capitalize"]).default("none"),
|
|
9234
8642
|
/** Italic style */
|
|
9235
|
-
italic:
|
|
8643
|
+
italic: z17.boolean().default(false)
|
|
9236
8644
|
});
|
|
9237
|
-
var effectApplicationSchema2 =
|
|
8645
|
+
var effectApplicationSchema2 = z17.object({
|
|
9238
8646
|
/** Effect preset ID */
|
|
9239
|
-
effectId:
|
|
8647
|
+
effectId: z17.string(),
|
|
9240
8648
|
/** User-provided customization options */
|
|
9241
|
-
options:
|
|
8649
|
+
options: z17.record(z17.string(), z17.any()).optional()
|
|
9242
8650
|
});
|
|
9243
|
-
var effectCompositionSchema =
|
|
8651
|
+
var effectCompositionSchema = z17.object({
|
|
9244
8652
|
/** Effects always applied */
|
|
9245
|
-
base:
|
|
8653
|
+
base: z17.array(effectApplicationSchema2).optional(),
|
|
9246
8654
|
/** Effects applied on hover */
|
|
9247
|
-
hover:
|
|
8655
|
+
hover: z17.array(effectApplicationSchema2).optional(),
|
|
9248
8656
|
/** Effects applied on active/pressed */
|
|
9249
|
-
active:
|
|
8657
|
+
active: z17.array(effectApplicationSchema2).optional(),
|
|
9250
8658
|
/** Effects applied on focus */
|
|
9251
|
-
focus:
|
|
8659
|
+
focus: z17.array(effectApplicationSchema2).optional()
|
|
9252
8660
|
});
|
|
9253
8661
|
|
|
9254
8662
|
// ../theme-core/src/navigation/types.ts
|
|
9255
|
-
var navLinkPaddingSchema =
|
|
9256
|
-
var navLinkPaddingXSchema =
|
|
9257
|
-
var navLinkBorderRadiusSchema =
|
|
9258
|
-
var navLinkTextSizeSchema =
|
|
9259
|
-
var navLinkLetterSpacingSchema =
|
|
9260
|
-
var navLinkStyleSchema =
|
|
8663
|
+
var navLinkPaddingSchema = z18.enum(["none", "compact", "default"]);
|
|
8664
|
+
var navLinkPaddingXSchema = z18.enum(["none", "tight", "compact", "default", "relaxed", "spacious"]);
|
|
8665
|
+
var navLinkBorderRadiusSchema = z18.enum(["none", "sm", "md", "full"]);
|
|
8666
|
+
var navLinkTextSizeSchema = z18.enum(["xs", "sm", "base", "lg"]);
|
|
8667
|
+
var navLinkLetterSpacingSchema = z18.enum(["normal", "wide", "wider", "widest"]);
|
|
8668
|
+
var navLinkStyleSchema = z18.object({
|
|
9261
8669
|
/** Display name for the style */
|
|
9262
|
-
name:
|
|
8670
|
+
name: z18.string().min(1).max(30).optional(),
|
|
9263
8671
|
/** Typography settings (inherited from interactive base) */
|
|
9264
8672
|
...interactiveTypographySchema.shape,
|
|
9265
8673
|
/** Text color token */
|
|
9266
|
-
colorToken:
|
|
8674
|
+
colorToken: z18.string().default("text"),
|
|
9267
8675
|
/** Optional text size override */
|
|
9268
8676
|
textSize: navLinkTextSizeSchema.optional(),
|
|
9269
8677
|
/** Optional letter spacing override */
|
|
9270
8678
|
letterSpacing: navLinkLetterSpacingSchema.optional(),
|
|
9271
8679
|
/** Hover/active color token (for color-change effects) */
|
|
9272
|
-
hoverColorToken:
|
|
8680
|
+
hoverColorToken: z18.string().nullable().optional(),
|
|
9273
8681
|
/** Padding preset */
|
|
9274
8682
|
padding: navLinkPaddingSchema.default("compact"),
|
|
9275
8683
|
/** Horizontal padding override (overrides horizontal component of padding preset) */
|
|
@@ -9281,7 +8689,7 @@ var navLinkStyleSchema = z21.object({
|
|
|
9281
8689
|
});
|
|
9282
8690
|
|
|
9283
8691
|
// ../theme-core/src/customCss/validation.ts
|
|
9284
|
-
import { z as
|
|
8692
|
+
import { z as z19 } from "zod";
|
|
9285
8693
|
var FORBIDDEN_SELECTORS = [":root", "html", "body"];
|
|
9286
8694
|
var UNIVERSAL_SELECTOR = "*";
|
|
9287
8695
|
var REMOTE_URL_PATTERN = /url\s*\(\s*['"]?(https?:|\/\/)/i;
|
|
@@ -9323,7 +8731,7 @@ function containsForbiddenSelector(selector) {
|
|
|
9323
8731
|
}
|
|
9324
8732
|
return false;
|
|
9325
8733
|
}
|
|
9326
|
-
var selectorSchema =
|
|
8734
|
+
var selectorSchema = z19.string().min(1, "Selector cannot be empty").max(200, "Selector too long (max 200 characters)").refine(
|
|
9327
8735
|
(s) => !containsForbiddenSelector(s),
|
|
9328
8736
|
{ message: "Global selectors (:root, html, body, *) are not allowed" }
|
|
9329
8737
|
);
|
|
@@ -9333,38 +8741,38 @@ function containsRemoteUrl(value) {
|
|
|
9333
8741
|
function containsJavascriptUrl(value) {
|
|
9334
8742
|
return JAVASCRIPT_URL_PATTERN.test(value);
|
|
9335
8743
|
}
|
|
9336
|
-
var declarationValueSchema =
|
|
8744
|
+
var declarationValueSchema = z19.string().max(500, "Declaration value too long (max 500 characters)").refine(
|
|
9337
8745
|
(v) => !containsRemoteUrl(v),
|
|
9338
8746
|
{ message: "Remote url() references are not allowed. Use local paths, data URIs, or fragment IDs." }
|
|
9339
8747
|
).refine(
|
|
9340
8748
|
(v) => !containsJavascriptUrl(v),
|
|
9341
8749
|
{ message: "javascript: URLs are not allowed" }
|
|
9342
8750
|
);
|
|
9343
|
-
var declarationsSchema =
|
|
9344
|
-
|
|
8751
|
+
var declarationsSchema = z19.record(
|
|
8752
|
+
z19.string().min(1).max(100),
|
|
9345
8753
|
// property name
|
|
9346
8754
|
declarationValueSchema
|
|
9347
8755
|
// property value
|
|
9348
8756
|
);
|
|
9349
|
-
var customCssRuleSchema =
|
|
9350
|
-
id:
|
|
8757
|
+
var customCssRuleSchema = z19.object({
|
|
8758
|
+
id: z19.string().min(1, "Rule ID is required").max(50, "Rule ID too long"),
|
|
9351
8759
|
selector: selectorSchema,
|
|
9352
8760
|
declarations: declarationsSchema
|
|
9353
8761
|
});
|
|
9354
8762
|
var blockCustomCssRuleSchema = customCssRuleSchema.extend({
|
|
9355
|
-
blockKind:
|
|
8763
|
+
blockKind: z19.string().min(1, "Block kind is required").max(50, "Block kind too long")
|
|
9356
8764
|
});
|
|
9357
|
-
var customCssRulesSchema =
|
|
9358
|
-
var blockCustomCssRulesSchema =
|
|
8765
|
+
var customCssRulesSchema = z19.array(customCssRuleSchema).optional();
|
|
8766
|
+
var blockCustomCssRulesSchema = z19.array(blockCustomCssRuleSchema).optional();
|
|
9359
8767
|
|
|
9360
8768
|
// ../theme-core/src/customCss/atRuleValidation.ts
|
|
9361
|
-
import { z as
|
|
8769
|
+
import { z as z20 } from "zod";
|
|
9362
8770
|
var KEYFRAME_OFFSET_PATTERN = /^(from|to|\d{1,3}%)$/i;
|
|
9363
8771
|
var ANIMATION_NAME_PATTERN = /^[a-zA-Z_-][a-zA-Z0-9_-]*$/;
|
|
9364
8772
|
var BLOCKED_AT_RULES = ["@import", "@charset"];
|
|
9365
8773
|
var BLOCKED_AT_RULE_PATTERN = /@(?:import|charset)\b/i;
|
|
9366
|
-
var ruleIdSchema =
|
|
9367
|
-
var nestedRuleSchema =
|
|
8774
|
+
var ruleIdSchema = z20.string().min(1, "Rule ID is required").max(50, "Rule ID too long");
|
|
8775
|
+
var nestedRuleSchema = z20.object({
|
|
9368
8776
|
selector: selectorSchema,
|
|
9369
8777
|
declarations: declarationsSchema
|
|
9370
8778
|
});
|
|
@@ -9376,146 +8784,146 @@ function isValidKeyframeOffset(offset) {
|
|
|
9376
8784
|
const value = parseInt(match[1], 10);
|
|
9377
8785
|
return value >= 0 && value <= 100;
|
|
9378
8786
|
}
|
|
9379
|
-
var keyframeOffsetSchema =
|
|
8787
|
+
var keyframeOffsetSchema = z20.string().transform((offset) => offset.trim()).refine(
|
|
9380
8788
|
(offset) => KEYFRAME_OFFSET_PATTERN.test(offset),
|
|
9381
8789
|
{ message: 'Invalid keyframe offset. Use percentages (0%, 50%, 100%) or "from"/"to"' }
|
|
9382
8790
|
).refine(
|
|
9383
8791
|
isValidKeyframeOffset,
|
|
9384
8792
|
{ message: "Keyframe offset must be between 0% and 100%" }
|
|
9385
8793
|
);
|
|
9386
|
-
var animationNameSchema =
|
|
8794
|
+
var animationNameSchema = z20.string().min(1, "Animation name is required").max(50, "Animation name too long").refine(
|
|
9387
8795
|
(name) => ANIMATION_NAME_PATTERN.test(name),
|
|
9388
8796
|
{ message: "Invalid animation name. Use letters, numbers, dashes, underscores (start with letter, dash, or underscore)" }
|
|
9389
8797
|
);
|
|
9390
|
-
var keyframeSchema =
|
|
8798
|
+
var keyframeSchema = z20.object({
|
|
9391
8799
|
offset: keyframeOffsetSchema,
|
|
9392
8800
|
declarations: declarationsSchema
|
|
9393
8801
|
});
|
|
9394
|
-
var keyframesAtRuleSchema =
|
|
8802
|
+
var keyframesAtRuleSchema = z20.object({
|
|
9395
8803
|
id: ruleIdSchema,
|
|
9396
|
-
type:
|
|
8804
|
+
type: z20.literal("keyframes"),
|
|
9397
8805
|
name: animationNameSchema,
|
|
9398
|
-
frames:
|
|
8806
|
+
frames: z20.array(keyframeSchema).min(1, "At least one keyframe is required")
|
|
9399
8807
|
});
|
|
9400
|
-
var fontFaceDeclarationsSchema =
|
|
8808
|
+
var fontFaceDeclarationsSchema = z20.record(z20.string().min(1).max(100), declarationValueSchema).refine(
|
|
9401
8809
|
(decls) => "fontFamily" in decls || "font-family" in decls,
|
|
9402
8810
|
{ message: "font-family is required in @font-face" }
|
|
9403
8811
|
);
|
|
9404
|
-
var fontFaceAtRuleSchema =
|
|
8812
|
+
var fontFaceAtRuleSchema = z20.object({
|
|
9405
8813
|
id: ruleIdSchema,
|
|
9406
|
-
type:
|
|
8814
|
+
type: z20.literal("font-face"),
|
|
9407
8815
|
declarations: fontFaceDeclarationsSchema
|
|
9408
8816
|
});
|
|
9409
|
-
var mediaQuerySchema =
|
|
9410
|
-
var mediaAtRuleSchema =
|
|
8817
|
+
var mediaQuerySchema = z20.string().min(1, "Media query is required").max(200, "Media query too long");
|
|
8818
|
+
var mediaAtRuleSchema = z20.object({
|
|
9411
8819
|
id: ruleIdSchema,
|
|
9412
|
-
type:
|
|
8820
|
+
type: z20.literal("media"),
|
|
9413
8821
|
query: mediaQuerySchema,
|
|
9414
|
-
rules:
|
|
8822
|
+
rules: z20.array(nestedRuleSchema).min(1, "At least one rule is required")
|
|
9415
8823
|
});
|
|
9416
|
-
var supportsConditionSchema =
|
|
9417
|
-
var supportsAtRuleSchema =
|
|
8824
|
+
var supportsConditionSchema = z20.string().min(1, "Supports condition is required").max(200, "Supports condition too long");
|
|
8825
|
+
var supportsAtRuleSchema = z20.object({
|
|
9418
8826
|
id: ruleIdSchema,
|
|
9419
|
-
type:
|
|
8827
|
+
type: z20.literal("supports"),
|
|
9420
8828
|
condition: supportsConditionSchema,
|
|
9421
|
-
rules:
|
|
8829
|
+
rules: z20.array(nestedRuleSchema).min(1, "At least one rule is required")
|
|
9422
8830
|
});
|
|
9423
8831
|
function containsBlockedAtRule(css) {
|
|
9424
8832
|
return BLOCKED_AT_RULE_PATTERN.test(css);
|
|
9425
8833
|
}
|
|
9426
|
-
var rawCssSchema =
|
|
8834
|
+
var rawCssSchema = z20.string().min(1, "CSS is required").max(5e3, "Raw CSS too long (max 5000 characters)").refine(
|
|
9427
8835
|
(css) => css.trim().startsWith("@"),
|
|
9428
8836
|
{ message: "Raw at-rule must start with @" }
|
|
9429
8837
|
).refine(
|
|
9430
8838
|
(css) => !containsBlockedAtRule(css),
|
|
9431
8839
|
{ message: `Blocked at-rules: ${BLOCKED_AT_RULES.join(", ")}. Use typed at-rules or local assets instead.` }
|
|
9432
8840
|
);
|
|
9433
|
-
var rawAtRuleSchema =
|
|
8841
|
+
var rawAtRuleSchema = z20.object({
|
|
9434
8842
|
id: ruleIdSchema,
|
|
9435
|
-
type:
|
|
8843
|
+
type: z20.literal("raw"),
|
|
9436
8844
|
css: rawCssSchema
|
|
9437
8845
|
});
|
|
9438
|
-
var customCssAtRuleSchema =
|
|
8846
|
+
var customCssAtRuleSchema = z20.discriminatedUnion("type", [
|
|
9439
8847
|
keyframesAtRuleSchema,
|
|
9440
8848
|
fontFaceAtRuleSchema,
|
|
9441
8849
|
mediaAtRuleSchema,
|
|
9442
8850
|
supportsAtRuleSchema,
|
|
9443
8851
|
rawAtRuleSchema
|
|
9444
8852
|
]);
|
|
9445
|
-
var customCssAtRulesSchema =
|
|
8853
|
+
var customCssAtRulesSchema = z20.array(customCssAtRuleSchema).optional();
|
|
9446
8854
|
|
|
9447
8855
|
// ../theme-core/src/shared/componentStyles.ts
|
|
9448
|
-
import { z as
|
|
9449
|
-
var componentBorderSchema =
|
|
9450
|
-
width:
|
|
9451
|
-
style:
|
|
9452
|
-
colorToken:
|
|
8856
|
+
import { z as z21 } from "zod";
|
|
8857
|
+
var componentBorderSchema = z21.object({
|
|
8858
|
+
width: z21.enum(["none", "hairline", "thin", "medium", "thick"]).default("none"),
|
|
8859
|
+
style: z21.enum(["solid", "dashed"]).default("solid"),
|
|
8860
|
+
colorToken: z21.string().optional()
|
|
9453
8861
|
// defaults to "border" if not set
|
|
9454
8862
|
});
|
|
9455
|
-
var componentShadowSchema =
|
|
9456
|
-
elevation:
|
|
8863
|
+
var componentShadowSchema = z21.object({
|
|
8864
|
+
elevation: z21.enum(["none", "sm", "md", "lg", "xl", "2xl"]).default("sm")
|
|
9457
8865
|
});
|
|
9458
8866
|
|
|
9459
8867
|
// ../theme-core/src/schema.ts
|
|
9460
|
-
var axesSchema =
|
|
9461
|
-
tone:
|
|
9462
|
-
energy:
|
|
9463
|
-
density:
|
|
9464
|
-
mediaBias:
|
|
9465
|
-
conversionBias:
|
|
9466
|
-
motion:
|
|
9467
|
-
});
|
|
9468
|
-
var colourHexString =
|
|
9469
|
-
var paletteColorSchema =
|
|
9470
|
-
name:
|
|
8868
|
+
var axesSchema = z22.object({
|
|
8869
|
+
tone: z22.enum(["minimal", "classic", "bold"]),
|
|
8870
|
+
energy: z22.enum(["calm", "vibrant"]),
|
|
8871
|
+
density: z22.enum(["airy", "regular", "compact"]),
|
|
8872
|
+
mediaBias: z22.enum(["text", "media", "mixed"]),
|
|
8873
|
+
conversionBias: z22.enum(["low", "med", "high"]),
|
|
8874
|
+
motion: z22.enum(["subtle", "standard", "expressive"])
|
|
8875
|
+
});
|
|
8876
|
+
var colourHexString = z22.string().regex(/^#([0-9A-Fa-f]{3}){1,2}$/);
|
|
8877
|
+
var paletteColorSchema = z22.object({
|
|
8878
|
+
name: z22.string().min(1),
|
|
9471
8879
|
hex: colourHexString
|
|
9472
8880
|
});
|
|
9473
|
-
var paletteMetaSchema =
|
|
9474
|
-
mode:
|
|
8881
|
+
var paletteMetaSchema = z22.object({
|
|
8882
|
+
mode: z22.enum(["light", "dark"])
|
|
9475
8883
|
});
|
|
9476
|
-
var paletteSchema =
|
|
9477
|
-
colors:
|
|
8884
|
+
var paletteSchema = z22.object({
|
|
8885
|
+
colors: z22.array(paletteColorSchema),
|
|
9478
8886
|
meta: paletteMetaSchema
|
|
9479
8887
|
});
|
|
9480
|
-
var typographyStyleSchema =
|
|
9481
|
-
family:
|
|
9482
|
-
weight:
|
|
9483
|
-
letterSpacing:
|
|
9484
|
-
lineHeight:
|
|
8888
|
+
var typographyStyleSchema = z22.object({
|
|
8889
|
+
family: z22.string().min(1),
|
|
8890
|
+
weight: z22.enum(["light", "regular", "medium", "semibold", "bold"]),
|
|
8891
|
+
letterSpacing: z22.enum(["tight", "normal", "loose"]),
|
|
8892
|
+
lineHeight: z22.enum(["normal", "relaxed", "loose"])
|
|
9485
8893
|
});
|
|
9486
8894
|
var bodyTypographyStyleSchema = typographyStyleSchema.extend({
|
|
9487
|
-
size:
|
|
8895
|
+
size: z22.enum(["md", "lg", "xl"])
|
|
9488
8896
|
});
|
|
9489
|
-
var headingSizeSchema =
|
|
9490
|
-
var headingTypographyOverridesSchema =
|
|
9491
|
-
weight:
|
|
9492
|
-
letterSpacing:
|
|
8897
|
+
var headingSizeSchema = z22.enum(["xs", "sm", "md", "lg", "xl", "2xl"]);
|
|
8898
|
+
var headingTypographyOverridesSchema = z22.object({
|
|
8899
|
+
weight: z22.enum(["light", "regular", "medium", "semibold", "bold"]).nullable().optional(),
|
|
8900
|
+
letterSpacing: z22.enum(["tight", "normal", "loose"]).nullable().optional(),
|
|
9493
8901
|
size: headingSizeSchema.nullable().optional(),
|
|
9494
|
-
lineHeight:
|
|
9495
|
-
italic:
|
|
9496
|
-
colorToken:
|
|
8902
|
+
lineHeight: z22.enum(["normal", "relaxed", "loose"]).nullable().optional(),
|
|
8903
|
+
italic: z22.boolean().nullable().optional(),
|
|
8904
|
+
colorToken: z22.string().min(1).nullable().optional()
|
|
9497
8905
|
// Palette token name for heading color
|
|
9498
8906
|
});
|
|
9499
8907
|
var headingTypographyStyleSchema = typographyStyleSchema.extend({
|
|
9500
|
-
case:
|
|
9501
|
-
italic:
|
|
9502
|
-
colorToken:
|
|
8908
|
+
case: z22.enum(["uppercase", "normal", "smallCaps"]).nullable(),
|
|
8909
|
+
italic: z22.boolean().nullable(),
|
|
8910
|
+
colorToken: z22.string().min(1).nullable().optional()
|
|
9503
8911
|
// Palette token name for heading color
|
|
9504
8912
|
});
|
|
9505
|
-
var proseLinkUnderlineStyleSchema =
|
|
9506
|
-
var proseLinkUnderlineThicknessSchema =
|
|
9507
|
-
var proseLinkUnderlineOffsetSchema =
|
|
9508
|
-
var proseLinkStyleSchema =
|
|
9509
|
-
colorToken:
|
|
9510
|
-
hoverColorToken:
|
|
9511
|
-
underline:
|
|
9512
|
-
decorationColorToken:
|
|
9513
|
-
hoverDecorationColorToken:
|
|
8913
|
+
var proseLinkUnderlineStyleSchema = z22.enum(["solid", "dotted", "dashed"]);
|
|
8914
|
+
var proseLinkUnderlineThicknessSchema = z22.enum(["auto", "fromFont", "thin", "medium", "thick"]);
|
|
8915
|
+
var proseLinkUnderlineOffsetSchema = z22.enum(["auto", "tight", "normal", "loose"]);
|
|
8916
|
+
var proseLinkStyleSchema = z22.object({
|
|
8917
|
+
colorToken: z22.string().min(1).optional(),
|
|
8918
|
+
hoverColorToken: z22.string().min(1).optional(),
|
|
8919
|
+
underline: z22.boolean().optional(),
|
|
8920
|
+
decorationColorToken: z22.string().min(1).optional(),
|
|
8921
|
+
hoverDecorationColorToken: z22.string().min(1).optional(),
|
|
9514
8922
|
underlineStyle: proseLinkUnderlineStyleSchema.optional(),
|
|
9515
8923
|
underlineThickness: proseLinkUnderlineThicknessSchema.optional(),
|
|
9516
8924
|
underlineOffset: proseLinkUnderlineOffsetSchema.optional()
|
|
9517
8925
|
});
|
|
9518
|
-
var semanticSpacingSchema =
|
|
8926
|
+
var semanticSpacingSchema = z22.enum([
|
|
9519
8927
|
"none",
|
|
9520
8928
|
"compact",
|
|
9521
8929
|
"cozy",
|
|
@@ -9523,62 +8931,62 @@ var semanticSpacingSchema = z25.enum([
|
|
|
9523
8931
|
"comfortable",
|
|
9524
8932
|
"spacious"
|
|
9525
8933
|
]);
|
|
9526
|
-
var boxRoundedSchema =
|
|
9527
|
-
var boxBackgroundOverlaySchema =
|
|
9528
|
-
type:
|
|
9529
|
-
color:
|
|
9530
|
-
gradient:
|
|
9531
|
-
opacity:
|
|
9532
|
-
});
|
|
9533
|
-
var boxBackgroundSchema =
|
|
9534
|
-
type:
|
|
9535
|
-
color:
|
|
9536
|
-
gradient:
|
|
8934
|
+
var boxRoundedSchema = z22.enum(["none", "sm", "md", "lg", "xl", "2xl", "full"]);
|
|
8935
|
+
var boxBackgroundOverlaySchema = z22.object({
|
|
8936
|
+
type: z22.enum(["none", "color", "gradient"]).nullable().optional(),
|
|
8937
|
+
color: z22.string().nullable().optional(),
|
|
8938
|
+
gradient: z22.string().nullable().optional(),
|
|
8939
|
+
opacity: z22.number().min(0).max(1).nullable().optional()
|
|
8940
|
+
});
|
|
8941
|
+
var boxBackgroundSchema = z22.object({
|
|
8942
|
+
type: z22.enum(["color", "gradient", "image"]).optional(),
|
|
8943
|
+
color: z22.string().nullable().optional(),
|
|
8944
|
+
gradient: z22.string().nullable().optional(),
|
|
9537
8945
|
image: mediaSchema.nullable().optional(),
|
|
9538
|
-
objectFit:
|
|
9539
|
-
scale:
|
|
9540
|
-
position:
|
|
9541
|
-
opacity:
|
|
8946
|
+
objectFit: z22.enum(["fill", "fit", "original", "custom"]).nullable().optional(),
|
|
8947
|
+
scale: z22.string().nullable().optional(),
|
|
8948
|
+
position: z22.string().nullable().optional(),
|
|
8949
|
+
opacity: z22.number().min(0).max(1).nullable().optional(),
|
|
9542
8950
|
overlay: boxBackgroundOverlaySchema.nullable().optional(),
|
|
9543
|
-
textColor:
|
|
9544
|
-
headingColor:
|
|
8951
|
+
textColor: z22.string().nullable().optional(),
|
|
8952
|
+
headingColor: z22.string().nullable().optional()
|
|
9545
8953
|
});
|
|
9546
|
-
var sectionStylesOverrideSchema =
|
|
8954
|
+
var sectionStylesOverrideSchema = z22.object({
|
|
9547
8955
|
background: boxBackgroundSchema.nullable().optional(),
|
|
9548
8956
|
spacing: semanticSpacingSchema.nullable().optional(),
|
|
9549
|
-
minHeight:
|
|
8957
|
+
minHeight: z22.enum(["none", "hero", "immersive"]).nullable().optional()
|
|
9550
8958
|
});
|
|
9551
|
-
var containerStylesOverrideSchema =
|
|
8959
|
+
var containerStylesOverrideSchema = z22.object({
|
|
9552
8960
|
background: boxBackgroundSchema.nullable().optional(),
|
|
9553
8961
|
spacing: semanticSpacingSchema.nullable().optional(),
|
|
9554
|
-
raised:
|
|
8962
|
+
raised: z22.boolean().nullable().optional(),
|
|
9555
8963
|
rounded: boxRoundedSchema.nullable().optional(),
|
|
9556
|
-
fullWidth:
|
|
8964
|
+
fullWidth: z22.boolean().nullable().optional()
|
|
9557
8965
|
});
|
|
9558
|
-
var cardBorderOverrideSchema =
|
|
9559
|
-
enabled:
|
|
9560
|
-
width:
|
|
9561
|
-
colorToken:
|
|
8966
|
+
var cardBorderOverrideSchema = z22.object({
|
|
8967
|
+
enabled: z22.boolean().nullable().optional(),
|
|
8968
|
+
width: z22.enum(["none", "1", "2", "3"]).nullable().optional(),
|
|
8969
|
+
colorToken: z22.string().nullable().optional()
|
|
9562
8970
|
});
|
|
9563
|
-
var cardStylesOverrideSchema =
|
|
8971
|
+
var cardStylesOverrideSchema = z22.object({
|
|
9564
8972
|
background: boxBackgroundSchema.nullable().optional(),
|
|
9565
8973
|
border: cardBorderOverrideSchema.nullable().optional(),
|
|
9566
8974
|
spacing: semanticSpacingSchema.nullable().optional(),
|
|
9567
|
-
raised:
|
|
8975
|
+
raised: z22.boolean().nullable().optional(),
|
|
9568
8976
|
rounded: boxRoundedSchema.nullable().optional()
|
|
9569
8977
|
});
|
|
9570
|
-
var blockStyleOverridesSchema =
|
|
8978
|
+
var blockStyleOverridesSchema = z22.object({
|
|
9571
8979
|
sectionStyles: sectionStylesOverrideSchema.nullable().optional(),
|
|
9572
8980
|
containerStyles: containerStylesOverrideSchema.nullable().optional(),
|
|
9573
8981
|
cardStyles: cardStylesOverrideSchema.nullable().optional()
|
|
9574
8982
|
});
|
|
9575
|
-
var blockThemeOverrideSchema =
|
|
9576
|
-
typography:
|
|
8983
|
+
var blockThemeOverrideSchema = z22.object({
|
|
8984
|
+
typography: z22.object({
|
|
9577
8985
|
proseLinkStyle: proseLinkStyleSchema.optional()
|
|
9578
8986
|
}).optional(),
|
|
9579
8987
|
styles: blockStyleOverridesSchema.optional()
|
|
9580
8988
|
});
|
|
9581
|
-
var typographyScaleSchema =
|
|
8989
|
+
var typographyScaleSchema = z22.enum([
|
|
9582
8990
|
// New intuitive names
|
|
9583
8991
|
"compact",
|
|
9584
8992
|
// ratio 1.2 (was minorThird)
|
|
@@ -9591,9 +8999,9 @@ var typographyScaleSchema = z25.enum([
|
|
|
9591
8999
|
"majorThird",
|
|
9592
9000
|
"perfectFourth"
|
|
9593
9001
|
]);
|
|
9594
|
-
var typographySchema =
|
|
9002
|
+
var typographySchema = z22.object({
|
|
9595
9003
|
body: bodyTypographyStyleSchema,
|
|
9596
|
-
headings:
|
|
9004
|
+
headings: z22.object({
|
|
9597
9005
|
default: headingTypographyStyleSchema,
|
|
9598
9006
|
h1: headingTypographyOverridesSchema,
|
|
9599
9007
|
h2: headingTypographyOverridesSchema,
|
|
@@ -9606,41 +9014,41 @@ var typographySchema = z25.object({
|
|
|
9606
9014
|
scale: typographyScaleSchema,
|
|
9607
9015
|
proseLinkStyle: proseLinkStyleSchema.optional()
|
|
9608
9016
|
});
|
|
9609
|
-
var spaceSchema =
|
|
9610
|
-
var corners =
|
|
9611
|
-
var shadow =
|
|
9612
|
-
elevation:
|
|
9613
|
-
softness:
|
|
9614
|
-
position:
|
|
9017
|
+
var spaceSchema = z22.enum(["comfortable", "standard", "dense"]);
|
|
9018
|
+
var corners = z22.enum(["square", "soft", "rounded", "pill"]);
|
|
9019
|
+
var shadow = z22.object({
|
|
9020
|
+
elevation: z22.enum(["none", "low", "medium", "high"]),
|
|
9021
|
+
softness: z22.enum(["crisp", "soft", "hard"]).nullable(),
|
|
9022
|
+
position: z22.enum(["bottom", "bottom-right"]).default("bottom")
|
|
9615
9023
|
});
|
|
9616
|
-
var border =
|
|
9617
|
-
width:
|
|
9618
|
-
style:
|
|
9024
|
+
var border = z22.object({
|
|
9025
|
+
width: z22.enum(["none", "hairline", "thin", "thick"]),
|
|
9026
|
+
style: z22.enum(["solid", "dashed"])
|
|
9619
9027
|
});
|
|
9620
|
-
var motion =
|
|
9621
|
-
level:
|
|
9622
|
-
easing:
|
|
9028
|
+
var motion = z22.object({
|
|
9029
|
+
level: z22.enum(["off", "low", "medium", "high"]),
|
|
9030
|
+
easing: z22.enum(["standard", "snappy", "gentle"]).nullable()
|
|
9623
9031
|
});
|
|
9624
|
-
var buttonStyle =
|
|
9032
|
+
var buttonStyle = z22.object({
|
|
9625
9033
|
shape: corners
|
|
9626
9034
|
// Used for --radius-control CSS variable
|
|
9627
9035
|
});
|
|
9628
|
-
var cardStyle =
|
|
9629
|
-
elevation:
|
|
9630
|
-
border:
|
|
9036
|
+
var cardStyle = z22.object({
|
|
9037
|
+
elevation: z22.enum(["none", "low", "medium", "high"]),
|
|
9038
|
+
border: z22.enum(["none", "subtle", "defined"]),
|
|
9631
9039
|
shape: corners,
|
|
9632
|
-
headerStyle:
|
|
9633
|
-
mediaTreatment:
|
|
9040
|
+
headerStyle: z22.enum(["plain", "accentBar", "subtleBg"]).nullable(),
|
|
9041
|
+
mediaTreatment: z22.enum(["square", "rounded", "bleed"]).nullable()
|
|
9634
9042
|
});
|
|
9635
|
-
var inputStyle =
|
|
9043
|
+
var inputStyle = z22.object({
|
|
9636
9044
|
shape: corners,
|
|
9637
|
-
border:
|
|
9638
|
-
focus:
|
|
9639
|
-
label:
|
|
9045
|
+
border: z22.enum(["subtle", "defined", "underline"]),
|
|
9046
|
+
focus: z22.enum(["glow", "ring", "underline"]),
|
|
9047
|
+
label: z22.enum(["inside", "above"])
|
|
9640
9048
|
});
|
|
9641
|
-
var headerVariant =
|
|
9642
|
-
var headerPositioning =
|
|
9643
|
-
var headerNavStyle =
|
|
9049
|
+
var headerVariant = z22.enum(["classic", "centered", "transparent", "floating", "editorial"]);
|
|
9050
|
+
var headerPositioning = z22.enum(["static", "sticky", "fixed"]);
|
|
9051
|
+
var headerNavStyle = z22.enum([
|
|
9644
9052
|
"minimal",
|
|
9645
9053
|
"underline",
|
|
9646
9054
|
"underline-grow",
|
|
@@ -9649,82 +9057,82 @@ var headerNavStyle = z25.enum([
|
|
|
9649
9057
|
"frosted",
|
|
9650
9058
|
"solid"
|
|
9651
9059
|
]);
|
|
9652
|
-
var navFontWeight =
|
|
9653
|
-
var headerMaxWidth =
|
|
9654
|
-
var headerContainerSchema =
|
|
9655
|
-
rounded:
|
|
9656
|
-
border:
|
|
9657
|
-
shadow:
|
|
9658
|
-
padding:
|
|
9659
|
-
tint:
|
|
9660
|
-
opacity:
|
|
9060
|
+
var navFontWeight = z22.enum(["regular", "medium", "semibold", "bold"]);
|
|
9061
|
+
var headerMaxWidth = z22.enum(["container", "full"]);
|
|
9062
|
+
var headerContainerSchema = z22.object({
|
|
9063
|
+
rounded: z22.enum(["none", "sm", "md", "lg", "xl", "2xl"]).default("xl"),
|
|
9064
|
+
border: z22.boolean().default(true),
|
|
9065
|
+
shadow: z22.boolean().default(true),
|
|
9066
|
+
padding: z22.enum(["sm", "md", "lg"]).default("md"),
|
|
9067
|
+
tint: z22.string().nullable().optional(),
|
|
9068
|
+
opacity: z22.number().min(0).max(1).default(0.12)
|
|
9661
9069
|
}).optional();
|
|
9662
9070
|
var headerBorderSchema = componentBorderSchema.extend({
|
|
9663
|
-
position:
|
|
9071
|
+
position: z22.enum(["bottom", "top", "both", "none"]).default("bottom")
|
|
9664
9072
|
}).optional();
|
|
9665
|
-
var logoStyleSchema =
|
|
9666
|
-
fontFamily:
|
|
9667
|
-
letterSpacing:
|
|
9668
|
-
gradient:
|
|
9073
|
+
var logoStyleSchema = z22.object({
|
|
9074
|
+
fontFamily: z22.enum(["heading", "body"]).default("heading"),
|
|
9075
|
+
letterSpacing: z22.enum(["normal", "wide", "wider", "widest"]).default("normal"),
|
|
9076
|
+
gradient: z22.boolean().default(false)
|
|
9669
9077
|
}).optional();
|
|
9670
|
-
var headerLogoTextSchema =
|
|
9671
|
-
mobileWrapLines:
|
|
9672
|
-
mobileMaxWidth:
|
|
9673
|
-
hideOnShrink:
|
|
9078
|
+
var headerLogoTextSchema = z22.object({
|
|
9079
|
+
mobileWrapLines: z22.union([z22.literal(1), z22.literal(2)]).optional(),
|
|
9080
|
+
mobileMaxWidth: z22.enum(["xs", "sm", "md"]).optional(),
|
|
9081
|
+
hideOnShrink: z22.boolean().optional()
|
|
9674
9082
|
}).optional();
|
|
9675
|
-
var navEffectsSchema =
|
|
9676
|
-
underlineGradient:
|
|
9677
|
-
glow:
|
|
9678
|
-
glowColor:
|
|
9679
|
-
neumorphic:
|
|
9083
|
+
var navEffectsSchema = z22.object({
|
|
9084
|
+
underlineGradient: z22.boolean().default(false),
|
|
9085
|
+
glow: z22.boolean().default(false),
|
|
9086
|
+
glowColor: z22.string().optional(),
|
|
9087
|
+
neumorphic: z22.boolean().default(false)
|
|
9680
9088
|
}).optional();
|
|
9681
|
-
var dropdownStyleSchema =
|
|
9089
|
+
var dropdownStyleSchema = z22.object({
|
|
9682
9090
|
// Container styling
|
|
9683
|
-
background:
|
|
9091
|
+
background: z22.string().default("surface"),
|
|
9684
9092
|
// color token
|
|
9685
|
-
textColor:
|
|
9093
|
+
textColor: z22.string().default("text"),
|
|
9686
9094
|
// color token
|
|
9687
|
-
borderColor:
|
|
9095
|
+
borderColor: z22.string().nullable().default("border"),
|
|
9688
9096
|
// null = no border
|
|
9689
|
-
shadow:
|
|
9690
|
-
borderRadius:
|
|
9097
|
+
shadow: z22.enum(["none", "sm", "md", "lg"]).default("md"),
|
|
9098
|
+
borderRadius: z22.enum(["none", "sm", "md", "lg"]).default("md"),
|
|
9691
9099
|
// Link hover states (explicit control)
|
|
9692
|
-
hoverBackground:
|
|
9100
|
+
hoverBackground: z22.string().nullable().optional(),
|
|
9693
9101
|
// color token, null = transparent
|
|
9694
|
-
hoverTextColor:
|
|
9102
|
+
hoverTextColor: z22.string().nullable().optional(),
|
|
9695
9103
|
// color token, null = inherit
|
|
9696
9104
|
// Typography
|
|
9697
|
-
textTransform:
|
|
9698
|
-
letterSpacing:
|
|
9699
|
-
fontWeight:
|
|
9105
|
+
textTransform: z22.enum(["none", "uppercase", "capitalize"]).default("none"),
|
|
9106
|
+
letterSpacing: z22.enum(["normal", "wide", "wider"]).default("normal"),
|
|
9107
|
+
fontWeight: z22.enum(["regular", "medium", "semibold", "bold"]).optional(),
|
|
9700
9108
|
// optional = inherit from navWeight
|
|
9701
|
-
textSize:
|
|
9109
|
+
textSize: z22.enum(["xs", "sm", "base", "lg"]).optional()
|
|
9702
9110
|
// optional = no override (browser default)
|
|
9703
9111
|
}).optional();
|
|
9704
|
-
var headerCtaGapSchema =
|
|
9705
|
-
var navContainerSchema =
|
|
9706
|
-
type:
|
|
9707
|
-
tint:
|
|
9708
|
-
opacity:
|
|
9112
|
+
var headerCtaGapSchema = z22.enum(["none", "tight", "compact", "default", "relaxed", "spacious"]);
|
|
9113
|
+
var navContainerSchema = z22.object({
|
|
9114
|
+
type: z22.enum(["none", "pill", "glass"]).default("none"),
|
|
9115
|
+
tint: z22.string().nullable().optional(),
|
|
9116
|
+
opacity: z22.number().min(0).max(1).default(0.15)
|
|
9709
9117
|
}).default({ type: "none", tint: null, opacity: 0.15 });
|
|
9710
|
-
var headerBackgroundSchema =
|
|
9711
|
-
type:
|
|
9712
|
-
color:
|
|
9118
|
+
var headerBackgroundSchema = z22.object({
|
|
9119
|
+
type: z22.enum(["color", "gradient", "image"]),
|
|
9120
|
+
color: z22.string().nullable().optional(),
|
|
9713
9121
|
gradient: gradientConfigSchema.nullable().optional(),
|
|
9714
9122
|
image: mediaSchema.nullable().optional(),
|
|
9715
|
-
textColor:
|
|
9123
|
+
textColor: z22.string().nullable().optional()
|
|
9716
9124
|
});
|
|
9717
|
-
var headerSchema =
|
|
9125
|
+
var headerSchema = z22.object({
|
|
9718
9126
|
variant: headerVariant,
|
|
9719
9127
|
positioning: headerPositioning,
|
|
9720
|
-
shrinkOnScroll:
|
|
9128
|
+
shrinkOnScroll: z22.boolean(),
|
|
9721
9129
|
maxWidth: headerMaxWidth,
|
|
9722
9130
|
logoOverride: mediaSchema.nullable().optional(),
|
|
9723
9131
|
background: headerBackgroundSchema.default({ type: "color", color: "surface" }),
|
|
9724
|
-
textColor:
|
|
9132
|
+
textColor: z22.string().nullable().optional(),
|
|
9725
9133
|
// Site title and general header text
|
|
9726
9134
|
navStyle: headerNavStyle,
|
|
9727
|
-
navColor:
|
|
9135
|
+
navColor: z22.string().nullable().optional(),
|
|
9728
9136
|
// Nav links (inherits textColor if not set)
|
|
9729
9137
|
navWeight: navFontWeight.default("medium"),
|
|
9730
9138
|
// New fields for header system enhancement
|
|
@@ -9743,50 +9151,50 @@ var headerSchema = z25.object({
|
|
|
9743
9151
|
// Dropdown menu styling (nav dropdowns and mobile drawer)
|
|
9744
9152
|
dropdownStyle: dropdownStyleSchema
|
|
9745
9153
|
});
|
|
9746
|
-
var footerVariant =
|
|
9747
|
-
var footerMaxWidth =
|
|
9748
|
-
var footerMode =
|
|
9749
|
-
var footerNavLayoutMode =
|
|
9750
|
-
var footerNavLayoutAlign =
|
|
9751
|
-
var footerSpacing =
|
|
9752
|
-
var footerLogoPlacement =
|
|
9753
|
-
var footerLogoSize =
|
|
9754
|
-
var footerLogoMaxHeight =
|
|
9755
|
-
var footerBottomTextLinkStyleSchema =
|
|
9756
|
-
colorToken:
|
|
9757
|
-
hoverColorToken:
|
|
9758
|
-
decorationColorToken:
|
|
9759
|
-
underline:
|
|
9760
|
-
});
|
|
9761
|
-
var footerBottomBarSchema =
|
|
9762
|
-
enabled:
|
|
9763
|
-
fullBleed:
|
|
9154
|
+
var footerVariant = z22.enum(["simple", "columns", "split"]);
|
|
9155
|
+
var footerMaxWidth = z22.enum(["container", "full"]);
|
|
9156
|
+
var footerMode = z22.enum(["default", "blocks", "default+blocks", "none"]);
|
|
9157
|
+
var footerNavLayoutMode = z22.enum(["stack", "inline", "inline-wrap"]);
|
|
9158
|
+
var footerNavLayoutAlign = z22.enum(["start", "center", "end", "space-between"]);
|
|
9159
|
+
var footerSpacing = z22.enum(["none", "tight", "compact", "default", "relaxed", "spacious"]);
|
|
9160
|
+
var footerLogoPlacement = z22.enum(["left", "right", "above", "below"]);
|
|
9161
|
+
var footerLogoSize = z22.enum(["sm", "md", "lg", "xl"]);
|
|
9162
|
+
var footerLogoMaxHeight = z22.enum(["sm", "md", "lg", "xl"]);
|
|
9163
|
+
var footerBottomTextLinkStyleSchema = z22.object({
|
|
9164
|
+
colorToken: z22.string().optional(),
|
|
9165
|
+
hoverColorToken: z22.string().nullable().optional(),
|
|
9166
|
+
decorationColorToken: z22.string().nullable().optional(),
|
|
9167
|
+
underline: z22.boolean().optional()
|
|
9168
|
+
});
|
|
9169
|
+
var footerBottomBarSchema = z22.object({
|
|
9170
|
+
enabled: z22.boolean().optional(),
|
|
9171
|
+
fullBleed: z22.boolean().optional(),
|
|
9764
9172
|
background: headerBackgroundSchema.optional(),
|
|
9765
|
-
textColor:
|
|
9766
|
-
textAlign:
|
|
9173
|
+
textColor: z22.string().nullable().optional(),
|
|
9174
|
+
textAlign: z22.enum(["left", "center", "right"]).optional(),
|
|
9767
9175
|
paddingY: footerSpacing.optional(),
|
|
9768
9176
|
paddingX: footerSpacing.optional(),
|
|
9769
|
-
borderTop:
|
|
9770
|
-
colorToken:
|
|
9771
|
-
width:
|
|
9177
|
+
borderTop: z22.object({
|
|
9178
|
+
colorToken: z22.string().nullable().optional(),
|
|
9179
|
+
width: z22.enum(["none", "thin", "medium", "thick"]).optional()
|
|
9772
9180
|
}).optional()
|
|
9773
9181
|
});
|
|
9774
|
-
var footerNavLayoutSchema =
|
|
9182
|
+
var footerNavLayoutSchema = z22.object({
|
|
9775
9183
|
layout: footerNavLayoutMode.optional(),
|
|
9776
9184
|
align: footerNavLayoutAlign.optional(),
|
|
9777
9185
|
gapX: footerSpacing.optional(),
|
|
9778
9186
|
gapY: footerSpacing.optional(),
|
|
9779
|
-
columns:
|
|
9187
|
+
columns: z22.number().int().min(1).max(6).optional()
|
|
9780
9188
|
});
|
|
9781
|
-
var footerLogoSchema =
|
|
9782
|
-
showLogo:
|
|
9783
|
-
showLogoText:
|
|
9189
|
+
var footerLogoSchema = z22.object({
|
|
9190
|
+
showLogo: z22.boolean().default(true),
|
|
9191
|
+
showLogoText: z22.boolean().optional(),
|
|
9784
9192
|
placement: footerLogoPlacement.optional(),
|
|
9785
9193
|
size: footerLogoSize.optional(),
|
|
9786
9194
|
maxHeight: footerLogoMaxHeight.optional(),
|
|
9787
|
-
align:
|
|
9195
|
+
align: z22.enum(["start", "center", "end"]).optional()
|
|
9788
9196
|
});
|
|
9789
|
-
var footerSchema =
|
|
9197
|
+
var footerSchema = z22.object({
|
|
9790
9198
|
/**
|
|
9791
9199
|
* SDK-only footer rendering mode.
|
|
9792
9200
|
*
|
|
@@ -9795,11 +9203,11 @@ var footerSchema = z25.object({
|
|
|
9795
9203
|
mode: footerMode.optional(),
|
|
9796
9204
|
variant: footerVariant,
|
|
9797
9205
|
maxWidth: footerMaxWidth,
|
|
9798
|
-
showLogoText:
|
|
9206
|
+
showLogoText: z22.boolean().optional(),
|
|
9799
9207
|
background: headerBackgroundSchema.default({ type: "color", color: "surface" }),
|
|
9800
9208
|
// Footer nav styling (independent from header)
|
|
9801
9209
|
navStyle: headerNavStyle.default("minimal"),
|
|
9802
|
-
navColor:
|
|
9210
|
+
navColor: z22.string().nullable().optional(),
|
|
9803
9211
|
navWeight: navFontWeight.default("medium"),
|
|
9804
9212
|
// Full nav link customization (overrides navStyle if set)
|
|
9805
9213
|
navLinkStyle: navLinkStyleSchema.optional(),
|
|
@@ -9810,15 +9218,15 @@ var footerSchema = z25.object({
|
|
|
9810
9218
|
logo: footerLogoSchema.optional(),
|
|
9811
9219
|
bottomBar: footerBottomBarSchema.optional()
|
|
9812
9220
|
});
|
|
9813
|
-
var containerPaddingPresetSchema =
|
|
9814
|
-
var layoutSchema =
|
|
9815
|
-
containerPadding:
|
|
9221
|
+
var containerPaddingPresetSchema = z22.enum(["tight", "compact", "default", "relaxed"]);
|
|
9222
|
+
var layoutSchema = z22.object({
|
|
9223
|
+
containerPadding: z22.object({
|
|
9816
9224
|
mobile: containerPaddingPresetSchema.optional(),
|
|
9817
9225
|
tablet: containerPaddingPresetSchema.optional(),
|
|
9818
9226
|
desktop: containerPaddingPresetSchema.optional()
|
|
9819
9227
|
}).optional()
|
|
9820
9228
|
}).optional();
|
|
9821
|
-
var heroTypographySizeSchema =
|
|
9229
|
+
var heroTypographySizeSchema = z22.enum([
|
|
9822
9230
|
"sm",
|
|
9823
9231
|
"base",
|
|
9824
9232
|
"lg",
|
|
@@ -9829,14 +9237,14 @@ var heroTypographySizeSchema = z25.enum([
|
|
|
9829
9237
|
"5xl",
|
|
9830
9238
|
"6xl"
|
|
9831
9239
|
]);
|
|
9832
|
-
var heroTypographyLineHeightSchema =
|
|
9833
|
-
var heroResponsiveTypographySchema =
|
|
9240
|
+
var heroTypographyLineHeightSchema = z22.enum(["tight", "snug", "normal", "relaxed"]);
|
|
9241
|
+
var heroResponsiveTypographySchema = z22.object({
|
|
9834
9242
|
headlineSize: heroTypographySizeSchema.optional(),
|
|
9835
9243
|
headlineLineHeight: heroTypographyLineHeightSchema.optional(),
|
|
9836
9244
|
subheadlineSize: heroTypographySizeSchema.optional(),
|
|
9837
9245
|
subheadlineLineHeight: heroTypographyLineHeightSchema.optional()
|
|
9838
9246
|
});
|
|
9839
|
-
var heroTypographySchema =
|
|
9247
|
+
var heroTypographySchema = z22.object({
|
|
9840
9248
|
headlineSize: heroTypographySizeSchema.optional(),
|
|
9841
9249
|
headlineLineHeight: heroTypographyLineHeightSchema.optional(),
|
|
9842
9250
|
subheadlineSize: heroTypographySizeSchema.optional(),
|
|
@@ -9845,24 +9253,24 @@ var heroTypographySchema = z25.object({
|
|
|
9845
9253
|
microHeadlineLineHeight: heroTypographyLineHeightSchema.optional(),
|
|
9846
9254
|
microSubheadlineSize: heroTypographySizeSchema.optional(),
|
|
9847
9255
|
microSubheadlineLineHeight: heroTypographyLineHeightSchema.optional(),
|
|
9848
|
-
responsive:
|
|
9256
|
+
responsive: z22.object({
|
|
9849
9257
|
tablet: heroResponsiveTypographySchema.optional(),
|
|
9850
9258
|
mobile: heroResponsiveTypographySchema.optional()
|
|
9851
9259
|
}).optional()
|
|
9852
9260
|
});
|
|
9853
|
-
var heroSchema =
|
|
9261
|
+
var heroSchema = z22.object({
|
|
9854
9262
|
typography: heroTypographySchema.optional()
|
|
9855
9263
|
}).optional();
|
|
9856
|
-
var gradientsSchema =
|
|
9857
|
-
button:
|
|
9858
|
-
hero:
|
|
9859
|
-
background:
|
|
9860
|
-
});
|
|
9861
|
-
var themeSchema =
|
|
9862
|
-
name:
|
|
9863
|
-
description:
|
|
9864
|
-
rationale:
|
|
9865
|
-
siteStyleId:
|
|
9264
|
+
var gradientsSchema = z22.object({
|
|
9265
|
+
button: z22.string().min(1).nullable().optional(),
|
|
9266
|
+
hero: z22.string().min(1).nullable().optional(),
|
|
9267
|
+
background: z22.string().min(1).nullable().optional()
|
|
9268
|
+
});
|
|
9269
|
+
var themeSchema = z22.object({
|
|
9270
|
+
name: z22.string().min(1).max(30),
|
|
9271
|
+
description: z22.string().min(1).max(400),
|
|
9272
|
+
rationale: z22.string().min(1).max(400),
|
|
9273
|
+
siteStyleId: z22.string().min(1).transform((value) => asSiteStyleId(value)).optional(),
|
|
9866
9274
|
axes: axesSchema,
|
|
9867
9275
|
palette: paletteSchema,
|
|
9868
9276
|
typography: typographySchema,
|
|
@@ -9889,16 +9297,16 @@ var themeSchema = z25.object({
|
|
|
9889
9297
|
// Block-specific customization (Tier 3)
|
|
9890
9298
|
// blockCustomVars: Per-block CSS variable overrides as bare values
|
|
9891
9299
|
// Example: { "event-registration": { "--step-color": "#6d28d9" } }
|
|
9892
|
-
blockCustomVars:
|
|
9893
|
-
|
|
9300
|
+
blockCustomVars: z22.record(
|
|
9301
|
+
z22.string(),
|
|
9894
9302
|
// block kind (matches data-block attribute)
|
|
9895
|
-
|
|
9303
|
+
z22.record(z22.string(), z22.string())
|
|
9896
9304
|
// { '--var-name': 'value' }
|
|
9897
9305
|
).optional(),
|
|
9898
9306
|
// Structured block-kind theme overrides (v1: typography prose-link style only)
|
|
9899
9307
|
// Keyed by block kind (usually data-block value like "hero"; "block.hero" also accepted)
|
|
9900
|
-
blockOverrides:
|
|
9901
|
-
|
|
9308
|
+
blockOverrides: z22.record(
|
|
9309
|
+
z22.string(),
|
|
9902
9310
|
blockThemeOverrideSchema
|
|
9903
9311
|
).optional(),
|
|
9904
9312
|
// Structured custom CSS rules
|
|
@@ -9934,22 +9342,21 @@ var themeSchema = z25.object({
|
|
|
9934
9342
|
* }
|
|
9935
9343
|
* ```
|
|
9936
9344
|
*/
|
|
9937
|
-
styleGroups:
|
|
9345
|
+
styleGroups: z22.record(z22.string(), z22.array(z22.string())).optional()
|
|
9938
9346
|
});
|
|
9939
|
-
var themesTurnSchema =
|
|
9940
|
-
message:
|
|
9941
|
-
themes:
|
|
9347
|
+
var themesTurnSchema = z22.object({
|
|
9348
|
+
message: z22.string().min(1),
|
|
9349
|
+
themes: z22.array(themeSchema).length(3)
|
|
9942
9350
|
});
|
|
9943
9351
|
|
|
9944
9352
|
// ../theme-core/src/palette/variants/types.ts
|
|
9945
|
-
import { z as z26 } from "zod";
|
|
9946
9353
|
function asPaletteVariantId(value) {
|
|
9947
9354
|
if (value.length === 0) {
|
|
9948
9355
|
throw new Error("PaletteVariantId must be a non-empty string");
|
|
9949
9356
|
}
|
|
9950
9357
|
return value;
|
|
9951
9358
|
}
|
|
9952
|
-
var paletteVariantIdSchema =
|
|
9359
|
+
var paletteVariantIdSchema = z23.string().min(1).transform((value) => asPaletteVariantId(value));
|
|
9953
9360
|
var PALETTE_TOKEN_NAMES = [
|
|
9954
9361
|
"primary",
|
|
9955
9362
|
"primaryForeground",
|
|
@@ -9965,19 +9372,19 @@ var PALETTE_TOKEN_NAMES = [
|
|
|
9965
9372
|
"text",
|
|
9966
9373
|
"border"
|
|
9967
9374
|
];
|
|
9968
|
-
var paletteTokenNameSchema =
|
|
9375
|
+
var paletteTokenNameSchema = z23.enum(PALETTE_TOKEN_NAMES);
|
|
9969
9376
|
var HEX_COLOR_REGEX = /^#[0-9a-f]{6}$/;
|
|
9970
|
-
var hexColorSchema =
|
|
9377
|
+
var hexColorSchema = z23.string().regex(HEX_COLOR_REGEX, "Hex must be #RRGGBB (lowercase)").transform((value) => value);
|
|
9971
9378
|
var variantPaletteColorSchema = paletteColorSchema.extend({
|
|
9972
9379
|
name: paletteTokenNameSchema
|
|
9973
9380
|
});
|
|
9974
|
-
var paletteVariantSchema =
|
|
9381
|
+
var paletteVariantSchema = z23.object({
|
|
9975
9382
|
id: paletteVariantIdSchema,
|
|
9976
|
-
name:
|
|
9977
|
-
description:
|
|
9383
|
+
name: z23.string().min(1),
|
|
9384
|
+
description: z23.string().min(1),
|
|
9978
9385
|
tags: styleTagsSchema,
|
|
9979
|
-
mode:
|
|
9980
|
-
colors:
|
|
9386
|
+
mode: z23.enum(["light", "dark"]),
|
|
9387
|
+
colors: z23.array(variantPaletteColorSchema).min(1)
|
|
9981
9388
|
});
|
|
9982
9389
|
function definePaletteVariant(input) {
|
|
9983
9390
|
return {
|
|
@@ -9989,7 +9396,7 @@ function definePaletteVariant(input) {
|
|
|
9989
9396
|
colors: input.colors
|
|
9990
9397
|
};
|
|
9991
9398
|
}
|
|
9992
|
-
var paletteOverridesSchema =
|
|
9399
|
+
var paletteOverridesSchema = z23.object({
|
|
9993
9400
|
primary: hexColorSchema.optional(),
|
|
9994
9401
|
primaryForeground: hexColorSchema.optional(),
|
|
9995
9402
|
secondary: hexColorSchema.optional(),
|
|
@@ -10277,28 +9684,679 @@ var warmNeutralForest = definePaletteVariant({
|
|
|
10277
9684
|
]
|
|
10278
9685
|
});
|
|
10279
9686
|
|
|
10280
|
-
// ../theme-core/src/palette/variants/index.ts
|
|
10281
|
-
var paletteVariants = [
|
|
10282
|
-
// Brand-led family
|
|
10283
|
-
brandLedCool,
|
|
10284
|
-
brandLedWarm,
|
|
10285
|
-
brandLedJewel,
|
|
10286
|
-
// Warm-neutral family
|
|
10287
|
-
warmNeutralClay,
|
|
10288
|
-
warmNeutralCream,
|
|
10289
|
-
warmNeutralForest,
|
|
10290
|
-
// High-contrast family
|
|
10291
|
-
highContrastInk,
|
|
10292
|
-
highContrastCharcoal,
|
|
10293
|
-
highContrastMonochrome,
|
|
10294
|
-
// Soft-natural family
|
|
10295
|
-
softNaturalSage,
|
|
10296
|
-
softNaturalStone,
|
|
10297
|
-
softNaturalWatercolor
|
|
9687
|
+
// ../theme-core/src/palette/variants/index.ts
|
|
9688
|
+
var paletteVariants = [
|
|
9689
|
+
// Brand-led family
|
|
9690
|
+
brandLedCool,
|
|
9691
|
+
brandLedWarm,
|
|
9692
|
+
brandLedJewel,
|
|
9693
|
+
// Warm-neutral family
|
|
9694
|
+
warmNeutralClay,
|
|
9695
|
+
warmNeutralCream,
|
|
9696
|
+
warmNeutralForest,
|
|
9697
|
+
// High-contrast family
|
|
9698
|
+
highContrastInk,
|
|
9699
|
+
highContrastCharcoal,
|
|
9700
|
+
highContrastMonochrome,
|
|
9701
|
+
// Soft-natural family
|
|
9702
|
+
softNaturalSage,
|
|
9703
|
+
softNaturalStone,
|
|
9704
|
+
softNaturalWatercolor
|
|
9705
|
+
];
|
|
9706
|
+
var paletteVariantsById = new Map(
|
|
9707
|
+
paletteVariants.map((v) => [v.id, v])
|
|
9708
|
+
);
|
|
9709
|
+
|
|
9710
|
+
// ../theme-core/src/site-styles/sourceCatalogs.ts
|
|
9711
|
+
var generatedContentFrames = [
|
|
9712
|
+
plainFrame,
|
|
9713
|
+
panelFrame("inset"),
|
|
9714
|
+
panelFrame("raised"),
|
|
9715
|
+
flushPanelFrame({ bleed: "start" })
|
|
9716
|
+
];
|
|
9717
|
+
var userContentFrames = [
|
|
9718
|
+
...generatedContentFrames,
|
|
9719
|
+
panelFrame("editorial"),
|
|
9720
|
+
flushPanelFrame({ bleed: "end" }),
|
|
9721
|
+
flushPanelFrame({ bleed: "both" })
|
|
9722
|
+
];
|
|
9723
|
+
var generatedDesignOptionCatalog = {
|
|
9724
|
+
source: "generated",
|
|
9725
|
+
sectionSurfaces: ["base", "muted-band", "accent-band", "hero-image"],
|
|
9726
|
+
contentFrames: generatedContentFrames,
|
|
9727
|
+
itemSurfaces: ["none", "default", "flat", "outlined", "raised"],
|
|
9728
|
+
transitions: ["none", "soft-fade-short", "soft-fade-long"],
|
|
9729
|
+
emphases: ["low", "medium", "high"],
|
|
9730
|
+
detachedCustom: false
|
|
9731
|
+
};
|
|
9732
|
+
var userDesignOptionCatalog = {
|
|
9733
|
+
source: "user",
|
|
9734
|
+
sectionSurfaces: generatedDesignOptionCatalog.sectionSurfaces,
|
|
9735
|
+
contentFrames: userContentFrames,
|
|
9736
|
+
itemSurfaces: [
|
|
9737
|
+
...generatedDesignOptionCatalog.itemSurfaces,
|
|
9738
|
+
"inset",
|
|
9739
|
+
"editorial"
|
|
9740
|
+
],
|
|
9741
|
+
transitions: [
|
|
9742
|
+
...generatedDesignOptionCatalog.transitions,
|
|
9743
|
+
"wave-edge",
|
|
9744
|
+
"angle-edge"
|
|
9745
|
+
],
|
|
9746
|
+
emphases: generatedDesignOptionCatalog.emphases,
|
|
9747
|
+
detachedCustom: false
|
|
9748
|
+
};
|
|
9749
|
+
var advancedDesignOptionCatalog = {
|
|
9750
|
+
source: "advanced",
|
|
9751
|
+
sectionSurfaces: userDesignOptionCatalog.sectionSurfaces,
|
|
9752
|
+
contentFrames: userDesignOptionCatalog.contentFrames,
|
|
9753
|
+
itemSurfaces: userDesignOptionCatalog.itemSurfaces,
|
|
9754
|
+
transitions: userDesignOptionCatalog.transitions,
|
|
9755
|
+
emphases: userDesignOptionCatalog.emphases,
|
|
9756
|
+
detachedCustom: true
|
|
9757
|
+
};
|
|
9758
|
+
|
|
9759
|
+
// ../theme-core/src/site-styles/curatedSiteStyles.ts
|
|
9760
|
+
var curatedSiteStyleIdValues = [
|
|
9761
|
+
"site-style:calm-studio",
|
|
9762
|
+
"site-style:clear-professional",
|
|
9763
|
+
"site-style:warm-editorial",
|
|
9764
|
+
"site-style:bright-community",
|
|
9765
|
+
"site-style:quiet-luxury",
|
|
9766
|
+
"site-style:practical-services",
|
|
9767
|
+
"site-style:modern-wellness",
|
|
9768
|
+
"site-style:bold-launch"
|
|
9769
|
+
];
|
|
9770
|
+
var quietBudget = {
|
|
9771
|
+
accentDensity: "low",
|
|
9772
|
+
panelDensity: "medium",
|
|
9773
|
+
transitionMix: "quiet",
|
|
9774
|
+
primaryCtaLimit: 2,
|
|
9775
|
+
mediaDensity: "medium",
|
|
9776
|
+
decorativeRepetition: "low"
|
|
9777
|
+
};
|
|
9778
|
+
var balancedBudget = {
|
|
9779
|
+
accentDensity: "medium",
|
|
9780
|
+
panelDensity: "medium",
|
|
9781
|
+
transitionMix: "balanced",
|
|
9782
|
+
primaryCtaLimit: 3,
|
|
9783
|
+
mediaDensity: "medium",
|
|
9784
|
+
decorativeRepetition: "medium"
|
|
9785
|
+
};
|
|
9786
|
+
var expressiveBudget = {
|
|
9787
|
+
accentDensity: "high",
|
|
9788
|
+
panelDensity: "high",
|
|
9789
|
+
transitionMix: "expressive",
|
|
9790
|
+
primaryCtaLimit: 3,
|
|
9791
|
+
mediaDensity: "high",
|
|
9792
|
+
decorativeRepetition: "medium"
|
|
9793
|
+
};
|
|
9794
|
+
function uniqueContentFrameKinds() {
|
|
9795
|
+
const kinds = [...new Set(
|
|
9796
|
+
generatedDesignOptionCatalog.contentFrames.map((frame) => frame.kind)
|
|
9797
|
+
)];
|
|
9798
|
+
const firstKind = kinds[0];
|
|
9799
|
+
if (!firstKind) {
|
|
9800
|
+
throw new Error("Expected generated design option catalog to expose at least one content frame kind.");
|
|
9801
|
+
}
|
|
9802
|
+
return [firstKind, ...kinds.slice(1)];
|
|
9803
|
+
}
|
|
9804
|
+
var generatedContentFrameKinds = uniqueContentFrameKinds();
|
|
9805
|
+
function defineCuratedSiteStyle(input) {
|
|
9806
|
+
return {
|
|
9807
|
+
id: asSiteStyleId(input.id),
|
|
9808
|
+
name: input.name,
|
|
9809
|
+
description: input.description,
|
|
9810
|
+
generationBrief: input.generationBrief,
|
|
9811
|
+
selectionKeywords: input.selectionKeywords ?? [],
|
|
9812
|
+
template: {
|
|
9813
|
+
id: asDesignSystemTemplateId(`template:${input.id.replace("site-style:", "")}`),
|
|
9814
|
+
name: input.name,
|
|
9815
|
+
version: 1,
|
|
9816
|
+
tokenRecipes: input.tokenRecipes,
|
|
9817
|
+
compositionBudget: input.compositionBudget,
|
|
9818
|
+
supportedSectionSurfaces: generatedDesignOptionCatalog.sectionSurfaces,
|
|
9819
|
+
supportedContentFrames: generatedContentFrameKinds,
|
|
9820
|
+
supportedItemSurfaces: generatedDesignOptionCatalog.itemSurfaces,
|
|
9821
|
+
supportedTransitions: generatedDesignOptionCatalog.transitions
|
|
9822
|
+
},
|
|
9823
|
+
buttonPersonalityChoices: input.buttonPersonalityChoices,
|
|
9824
|
+
paletteVariantChoices: input.paletteVariantChoices
|
|
9825
|
+
};
|
|
9826
|
+
}
|
|
9827
|
+
function buttonChoice(id, note) {
|
|
9828
|
+
return note ? { id: asButtonPersonalityId(id), note } : { id: asButtonPersonalityId(id) };
|
|
9829
|
+
}
|
|
9830
|
+
function paletteChoice(id, note) {
|
|
9831
|
+
return note ? { id: asPaletteVariantId(id), note } : { id: asPaletteVariantId(id) };
|
|
9832
|
+
}
|
|
9833
|
+
var curatedSiteStyles = [
|
|
9834
|
+
defineCuratedSiteStyle({
|
|
9835
|
+
id: "site-style:calm-studio",
|
|
9836
|
+
name: "Calm Studio",
|
|
9837
|
+
description: "Soft, measured, and spacious for intimate appointment or class businesses.",
|
|
9838
|
+
generationBrief: "Use calm pacing, concise copy, generous breathing room, and natural imagery. Keep calls to action steady rather than urgent.",
|
|
9839
|
+
tokenRecipes: {
|
|
9840
|
+
palette: "soft-natural",
|
|
9841
|
+
contrast: "standard",
|
|
9842
|
+
radius: "soft",
|
|
9843
|
+
shadow: "subtle",
|
|
9844
|
+
typography: "friendly-sans",
|
|
9845
|
+
spacing: "airy",
|
|
9846
|
+
motion: "subtle"
|
|
9847
|
+
},
|
|
9848
|
+
compositionBudget: quietBudget,
|
|
9849
|
+
buttonPersonalityChoices: [
|
|
9850
|
+
buttonChoice("soft-pill"),
|
|
9851
|
+
buttonChoice("pebble"),
|
|
9852
|
+
buttonChoice("editorial-link"),
|
|
9853
|
+
buttonChoice("brushed-wash")
|
|
9854
|
+
],
|
|
9855
|
+
paletteVariantChoices: [
|
|
9856
|
+
paletteChoice("soft-natural-sage"),
|
|
9857
|
+
paletteChoice("soft-natural-stone"),
|
|
9858
|
+
paletteChoice("warm-neutral-clay"),
|
|
9859
|
+
paletteChoice("soft-natural-watercolor")
|
|
9860
|
+
]
|
|
9861
|
+
}),
|
|
9862
|
+
defineCuratedSiteStyle({
|
|
9863
|
+
id: "site-style:clear-professional",
|
|
9864
|
+
name: "Clear Professional",
|
|
9865
|
+
description: "Crisp, trustworthy, and direct for local services and consultancies.",
|
|
9866
|
+
generationBrief: "Prioritize clarity, proof, service detail, and easy next steps. Keep visuals polished and specific, with restrained decorative treatment.",
|
|
9867
|
+
tokenRecipes: {
|
|
9868
|
+
palette: "brand-led",
|
|
9869
|
+
contrast: "strong",
|
|
9870
|
+
radius: "soft",
|
|
9871
|
+
shadow: "subtle",
|
|
9872
|
+
typography: "clean-sans",
|
|
9873
|
+
spacing: "regular",
|
|
9874
|
+
motion: "subtle"
|
|
9875
|
+
},
|
|
9876
|
+
compositionBudget: balancedBudget,
|
|
9877
|
+
buttonPersonalityChoices: [
|
|
9878
|
+
buttonChoice("confident-chip"),
|
|
9879
|
+
buttonChoice("soft-pill"),
|
|
9880
|
+
buttonChoice("editorial-link")
|
|
9881
|
+
],
|
|
9882
|
+
paletteVariantChoices: [
|
|
9883
|
+
paletteChoice("brand-led-cool"),
|
|
9884
|
+
paletteChoice("high-contrast-ink"),
|
|
9885
|
+
paletteChoice("brand-led-jewel")
|
|
9886
|
+
]
|
|
9887
|
+
}),
|
|
9888
|
+
defineCuratedSiteStyle({
|
|
9889
|
+
id: "site-style:warm-editorial",
|
|
9890
|
+
name: "Warm Editorial",
|
|
9891
|
+
description: "Story-led and textured for educators, makers, venues, and retreats.",
|
|
9892
|
+
generationBrief: "Let the copy feel thoughtful and grounded. Favor narrative sections, supporting media, and a small number of editorial panels.",
|
|
9893
|
+
tokenRecipes: {
|
|
9894
|
+
palette: "warm-neutral",
|
|
9895
|
+
contrast: "standard",
|
|
9896
|
+
radius: "square",
|
|
9897
|
+
shadow: "none",
|
|
9898
|
+
typography: "serif-editorial",
|
|
9899
|
+
spacing: "airy",
|
|
9900
|
+
motion: "subtle"
|
|
9901
|
+
},
|
|
9902
|
+
compositionBudget: balancedBudget,
|
|
9903
|
+
buttonPersonalityChoices: [
|
|
9904
|
+
buttonChoice("editorial-link"),
|
|
9905
|
+
buttonChoice("soft-pill"),
|
|
9906
|
+
buttonChoice("brushed-wash")
|
|
9907
|
+
],
|
|
9908
|
+
paletteVariantChoices: [
|
|
9909
|
+
paletteChoice("warm-neutral-cream"),
|
|
9910
|
+
paletteChoice("warm-neutral-clay"),
|
|
9911
|
+
paletteChoice("warm-neutral-forest"),
|
|
9912
|
+
paletteChoice("soft-natural-stone")
|
|
9913
|
+
]
|
|
9914
|
+
}),
|
|
9915
|
+
defineCuratedSiteStyle({
|
|
9916
|
+
id: "site-style:bright-community",
|
|
9917
|
+
name: "Bright Community",
|
|
9918
|
+
description: "Friendly, welcoming, and active for groups, classes, and neighborhood offers.",
|
|
9919
|
+
generationBrief: "Use welcoming language, clear event or booking routes, and optimistic imagery. Let accents appear, but avoid noisy decoration.",
|
|
9920
|
+
tokenRecipes: {
|
|
9921
|
+
palette: "brand-led",
|
|
9922
|
+
contrast: "standard",
|
|
9923
|
+
radius: "rounded",
|
|
9924
|
+
shadow: "subtle",
|
|
9925
|
+
typography: "friendly-sans",
|
|
9926
|
+
spacing: "regular",
|
|
9927
|
+
motion: "expressive"
|
|
9928
|
+
},
|
|
9929
|
+
compositionBudget: balancedBudget,
|
|
9930
|
+
buttonPersonalityChoices: [
|
|
9931
|
+
buttonChoice("pebble"),
|
|
9932
|
+
buttonChoice("brushed-wash"),
|
|
9933
|
+
buttonChoice("confident-chip")
|
|
9934
|
+
],
|
|
9935
|
+
paletteVariantChoices: [
|
|
9936
|
+
paletteChoice("brand-led-warm"),
|
|
9937
|
+
paletteChoice("brand-led-jewel"),
|
|
9938
|
+
paletteChoice("soft-natural-watercolor")
|
|
9939
|
+
]
|
|
9940
|
+
}),
|
|
9941
|
+
defineCuratedSiteStyle({
|
|
9942
|
+
id: "site-style:quiet-luxury",
|
|
9943
|
+
name: "Quiet Luxury",
|
|
9944
|
+
description: "Minimal, confident, and refined for premium experiences and private services.",
|
|
9945
|
+
generationBrief: "Use fewer claims, more specificity, and restrained sensory detail. Favor elegant media and low repetition over dense panels.",
|
|
9946
|
+
selectionKeywords: [
|
|
9947
|
+
"luxury",
|
|
9948
|
+
"premium",
|
|
9949
|
+
"boutique",
|
|
9950
|
+
"bespoke",
|
|
9951
|
+
"exclusive"
|
|
9952
|
+
],
|
|
9953
|
+
tokenRecipes: {
|
|
9954
|
+
palette: "high-contrast",
|
|
9955
|
+
contrast: "strong",
|
|
9956
|
+
radius: "square",
|
|
9957
|
+
shadow: "none",
|
|
9958
|
+
typography: "classic-serif",
|
|
9959
|
+
spacing: "airy",
|
|
9960
|
+
motion: "none"
|
|
9961
|
+
},
|
|
9962
|
+
compositionBudget: quietBudget,
|
|
9963
|
+
buttonPersonalityChoices: [
|
|
9964
|
+
buttonChoice("editorial-link"),
|
|
9965
|
+
buttonChoice("confident-chip"),
|
|
9966
|
+
buttonChoice("soft-pill")
|
|
9967
|
+
],
|
|
9968
|
+
paletteVariantChoices: [
|
|
9969
|
+
paletteChoice("high-contrast-charcoal"),
|
|
9970
|
+
paletteChoice("high-contrast-ink"),
|
|
9971
|
+
paletteChoice("warm-neutral-cream")
|
|
9972
|
+
]
|
|
9973
|
+
}),
|
|
9974
|
+
defineCuratedSiteStyle({
|
|
9975
|
+
id: "site-style:practical-services",
|
|
9976
|
+
name: "Practical Services",
|
|
9977
|
+
description: "Efficient, plainspoken, and conversion-focused for trades and everyday services.",
|
|
9978
|
+
generationBrief: "Make services, location, trust signals, and contact paths obvious. Keep copy brief and avoid ornate visual treatments.",
|
|
9979
|
+
selectionKeywords: [
|
|
9980
|
+
"repair",
|
|
9981
|
+
"plumb",
|
|
9982
|
+
"electric",
|
|
9983
|
+
"cleaning",
|
|
9984
|
+
"landscap",
|
|
9985
|
+
"contractor"
|
|
9986
|
+
],
|
|
9987
|
+
tokenRecipes: {
|
|
9988
|
+
palette: "brand-led",
|
|
9989
|
+
contrast: "maximum",
|
|
9990
|
+
radius: "soft",
|
|
9991
|
+
shadow: "subtle",
|
|
9992
|
+
typography: "clean-sans",
|
|
9993
|
+
spacing: "compact",
|
|
9994
|
+
motion: "none"
|
|
9995
|
+
},
|
|
9996
|
+
compositionBudget: quietBudget,
|
|
9997
|
+
buttonPersonalityChoices: [
|
|
9998
|
+
buttonChoice("confident-chip"),
|
|
9999
|
+
buttonChoice("pebble"),
|
|
10000
|
+
buttonChoice("ink-stamp")
|
|
10001
|
+
],
|
|
10002
|
+
paletteVariantChoices: [
|
|
10003
|
+
paletteChoice("brand-led-cool"),
|
|
10004
|
+
paletteChoice("high-contrast-ink"),
|
|
10005
|
+
paletteChoice("brand-led-warm")
|
|
10006
|
+
]
|
|
10007
|
+
}),
|
|
10008
|
+
defineCuratedSiteStyle({
|
|
10009
|
+
id: "site-style:modern-wellness",
|
|
10010
|
+
name: "Modern Wellness",
|
|
10011
|
+
description: "Natural, current, and reassuring for practitioners, studios, and wellbeing offers.",
|
|
10012
|
+
generationBrief: "Keep the tone warm and practical. Use gentle section variation, natural materials, and inclusive copy without making medical claims.",
|
|
10013
|
+
tokenRecipes: {
|
|
10014
|
+
palette: "soft-natural",
|
|
10015
|
+
contrast: "standard",
|
|
10016
|
+
radius: "rounded",
|
|
10017
|
+
shadow: "subtle",
|
|
10018
|
+
typography: "clean-sans",
|
|
10019
|
+
spacing: "airy",
|
|
10020
|
+
motion: "subtle"
|
|
10021
|
+
},
|
|
10022
|
+
compositionBudget: balancedBudget,
|
|
10023
|
+
buttonPersonalityChoices: [
|
|
10024
|
+
buttonChoice("soft-pill"),
|
|
10025
|
+
buttonChoice("pebble"),
|
|
10026
|
+
buttonChoice("confident-chip")
|
|
10027
|
+
],
|
|
10028
|
+
paletteVariantChoices: [
|
|
10029
|
+
paletteChoice("soft-natural-sage"),
|
|
10030
|
+
paletteChoice("soft-natural-stone"),
|
|
10031
|
+
paletteChoice("warm-neutral-forest")
|
|
10032
|
+
]
|
|
10033
|
+
}),
|
|
10034
|
+
defineCuratedSiteStyle({
|
|
10035
|
+
id: "site-style:bold-launch",
|
|
10036
|
+
name: "Bold Launch",
|
|
10037
|
+
description: "High-energy and punchy for launches, campaigns, and creative offers.",
|
|
10038
|
+
generationBrief: "Use crisp positioning, bold hero structure, strong calls to action, and confident visual rhythm. Keep it precise, not shouty.",
|
|
10039
|
+
selectionKeywords: [
|
|
10040
|
+
"launch",
|
|
10041
|
+
"campaign",
|
|
10042
|
+
"preorder",
|
|
10043
|
+
"pre-order",
|
|
10044
|
+
"waitlist",
|
|
10045
|
+
"drop"
|
|
10046
|
+
],
|
|
10047
|
+
tokenRecipes: {
|
|
10048
|
+
palette: "high-contrast",
|
|
10049
|
+
contrast: "maximum",
|
|
10050
|
+
radius: "pill",
|
|
10051
|
+
shadow: "layered",
|
|
10052
|
+
typography: "clean-sans",
|
|
10053
|
+
spacing: "regular",
|
|
10054
|
+
motion: "expressive"
|
|
10055
|
+
},
|
|
10056
|
+
compositionBudget: expressiveBudget,
|
|
10057
|
+
buttonPersonalityChoices: [
|
|
10058
|
+
buttonChoice("ink-stamp"),
|
|
10059
|
+
buttonChoice("confident-chip"),
|
|
10060
|
+
buttonChoice("brushed-wash"),
|
|
10061
|
+
buttonChoice("pebble")
|
|
10062
|
+
],
|
|
10063
|
+
paletteVariantChoices: [
|
|
10064
|
+
paletteChoice("high-contrast-monochrome"),
|
|
10065
|
+
paletteChoice("high-contrast-ink"),
|
|
10066
|
+
paletteChoice("brand-led-jewel"),
|
|
10067
|
+
paletteChoice("brand-led-warm")
|
|
10068
|
+
]
|
|
10069
|
+
})
|
|
10070
|
+
];
|
|
10071
|
+
var curatedSiteStylesById = new Map(
|
|
10072
|
+
curatedSiteStyles.map((style) => [style.id, style])
|
|
10073
|
+
);
|
|
10074
|
+
|
|
10075
|
+
// ../theme-core/src/site-styles/designState.ts
|
|
10076
|
+
import { z as z24 } from "zod";
|
|
10077
|
+
|
|
10078
|
+
// ../theme-core/src/site-styles/rawStyleFields.ts
|
|
10079
|
+
var themeV2RuntimeStyleFieldNames = [
|
|
10080
|
+
"_frameStyles",
|
|
10081
|
+
"_sectionStyles",
|
|
10082
|
+
"_containerStyles",
|
|
10083
|
+
"_cardStyles",
|
|
10084
|
+
// styleGroup is legacy runtime transition wiring rather than a nested
|
|
10085
|
+
// override object, but normal editors should still never see it directly.
|
|
10086
|
+
"styleGroup"
|
|
10298
10087
|
];
|
|
10299
|
-
var
|
|
10300
|
-
|
|
10088
|
+
var themeV2BlockSpecificRawStyleFieldNames = [
|
|
10089
|
+
"_contentCardStyles",
|
|
10090
|
+
"_textCardStyles"
|
|
10091
|
+
];
|
|
10092
|
+
var themeV2NormalEditorRawStyleFieldNames = [
|
|
10093
|
+
...themeV2RuntimeStyleFieldNames,
|
|
10094
|
+
...themeV2BlockSpecificRawStyleFieldNames
|
|
10095
|
+
];
|
|
10096
|
+
var themeV2NormalEditorRawStyleFieldNameSet = new Set(
|
|
10097
|
+
themeV2NormalEditorRawStyleFieldNames
|
|
10098
|
+
);
|
|
10099
|
+
|
|
10100
|
+
// ../theme-core/src/site-styles/designState.ts
|
|
10101
|
+
var themeV2DesignStateSchemaVersion = 1;
|
|
10102
|
+
var designResolutionPolicySchema = z24.enum(["generated", "user", "admin", "sdk"]);
|
|
10103
|
+
var runtimeStyleFieldNameSchema = z24.enum(themeV2RuntimeStyleFieldNames);
|
|
10104
|
+
var nonEmptyRuntimeStyleFieldNamesSchema = z24.array(runtimeStyleFieldNameSchema).min(1).transform((fields3) => [
|
|
10105
|
+
fields3[0],
|
|
10106
|
+
...fields3.slice(1)
|
|
10107
|
+
]);
|
|
10108
|
+
var heroLegibilityStrategySchema = z24.enum([
|
|
10109
|
+
"none",
|
|
10110
|
+
"scrim-gradient",
|
|
10111
|
+
"solid-panel"
|
|
10112
|
+
]);
|
|
10113
|
+
function uniqueNonEmpty(values) {
|
|
10114
|
+
const uniqueValues = [...new Set(values)];
|
|
10115
|
+
const firstValue = uniqueValues[0];
|
|
10116
|
+
if (!firstValue) {
|
|
10117
|
+
throw new Error("Expected at least one Theme V2 design state option.");
|
|
10118
|
+
}
|
|
10119
|
+
return [firstValue, ...uniqueValues.slice(1)];
|
|
10120
|
+
}
|
|
10121
|
+
var userPanelTreatments = uniqueNonEmpty(
|
|
10122
|
+
userDesignOptionCatalog.contentFrames.filter((frame) => frame.kind === "panel").map((frame) => frame.treatment)
|
|
10123
|
+
);
|
|
10124
|
+
var userFlushTreatments = uniqueNonEmpty(
|
|
10125
|
+
userDesignOptionCatalog.contentFrames.filter((frame) => frame.kind === "flush-panel").map((frame) => frame.treatment)
|
|
10126
|
+
);
|
|
10127
|
+
var userFlushBleeds = uniqueNonEmpty(
|
|
10128
|
+
userDesignOptionCatalog.contentFrames.filter((frame) => frame.kind === "flush-panel").map((frame) => frame.bleed)
|
|
10129
|
+
);
|
|
10130
|
+
var contentFrameIntentSchema = z24.discriminatedUnion("kind", [
|
|
10131
|
+
z24.object({ kind: z24.literal("plain") }).strict(),
|
|
10132
|
+
z24.object({
|
|
10133
|
+
kind: z24.literal("panel"),
|
|
10134
|
+
treatment: z24.enum(userPanelTreatments)
|
|
10135
|
+
}).strict(),
|
|
10136
|
+
z24.object({
|
|
10137
|
+
kind: z24.literal("flush-panel"),
|
|
10138
|
+
treatment: z24.enum(userFlushTreatments),
|
|
10139
|
+
bleed: z24.enum(userFlushBleeds)
|
|
10140
|
+
}).strict()
|
|
10141
|
+
]);
|
|
10142
|
+
var blockDesignPlanSchema = z24.object({
|
|
10143
|
+
blockId: z24.string().min(1).transform(asDesignBlockId),
|
|
10144
|
+
blockKind: z24.string().min(1),
|
|
10145
|
+
purpose: z24.string().min(1),
|
|
10146
|
+
sectionSurface: z24.enum(userDesignOptionCatalog.sectionSurfaces),
|
|
10147
|
+
contentFrame: contentFrameIntentSchema,
|
|
10148
|
+
itemSurface: z24.enum(userDesignOptionCatalog.itemSurfaces),
|
|
10149
|
+
transitionAfter: z24.enum(userDesignOptionCatalog.transitions),
|
|
10150
|
+
emphasis: z24.enum(userDesignOptionCatalog.emphases),
|
|
10151
|
+
heroLegibility: heroLegibilityStrategySchema.optional()
|
|
10152
|
+
}).strict();
|
|
10153
|
+
var styleAuthoritySchema = z24.discriminatedUnion("kind", [
|
|
10154
|
+
z24.object({
|
|
10155
|
+
kind: z24.literal("theme-v2"),
|
|
10156
|
+
source: designResolutionPolicySchema,
|
|
10157
|
+
siteStyleId: z24.string().min(1).transform(asSiteStyleId),
|
|
10158
|
+
templateId: z24.string().min(1).transform(asDesignSystemTemplateId),
|
|
10159
|
+
templateVersion: z24.number().int().nonnegative(),
|
|
10160
|
+
resolverVersion: z24.number().int().nonnegative()
|
|
10161
|
+
}).strict(),
|
|
10162
|
+
z24.object({
|
|
10163
|
+
kind: z24.literal("legacy-raw"),
|
|
10164
|
+
reason: z24.enum(["pre-theme-v2", "manual-runtime-fields"])
|
|
10165
|
+
}).strict(),
|
|
10166
|
+
z24.object({
|
|
10167
|
+
kind: z24.literal("advanced-detached"),
|
|
10168
|
+
reason: z24.literal("detached-custom-runtime-fields")
|
|
10169
|
+
}).strict()
|
|
10170
|
+
]);
|
|
10171
|
+
var blockRuntimeStyleAuthoritySchema = z24.object({
|
|
10172
|
+
unit: z24.literal("block-runtime-fields"),
|
|
10173
|
+
blockId: z24.string().min(1).transform(asDesignBlockId),
|
|
10174
|
+
fields: nonEmptyRuntimeStyleFieldNamesSchema,
|
|
10175
|
+
authority: styleAuthoritySchema
|
|
10176
|
+
}).strict();
|
|
10177
|
+
var persistedPageDesignStateV1Schema = z24.object({
|
|
10178
|
+
schemaVersion: z24.literal(themeV2DesignStateSchemaVersion),
|
|
10179
|
+
siteStyleId: z24.string().min(1).transform(asSiteStyleId),
|
|
10180
|
+
templateId: z24.string().min(1).transform(asDesignSystemTemplateId),
|
|
10181
|
+
templateVersion: z24.number().int().nonnegative(),
|
|
10182
|
+
resolverVersion: z24.number().int().nonnegative(),
|
|
10183
|
+
rhythmPresetId: z24.string().min(1),
|
|
10184
|
+
blocks: z24.array(blockDesignPlanSchema),
|
|
10185
|
+
styleAuthorities: z24.array(blockRuntimeStyleAuthoritySchema)
|
|
10186
|
+
}).strict();
|
|
10187
|
+
|
|
10188
|
+
// ../theme-core/src/site-styles/generatedSchemas.ts
|
|
10189
|
+
import { z as z25 } from "zod";
|
|
10190
|
+
function uniqueNonEmpty2(values) {
|
|
10191
|
+
const uniqueValues = [...new Set(values)];
|
|
10192
|
+
const firstValue = uniqueValues[0];
|
|
10193
|
+
if (!firstValue) {
|
|
10194
|
+
throw new Error("Expected at least one generated schema option.");
|
|
10195
|
+
}
|
|
10196
|
+
return [firstValue, ...uniqueValues.slice(1)];
|
|
10197
|
+
}
|
|
10198
|
+
var generatedPanelTreatments = uniqueNonEmpty2(
|
|
10199
|
+
generatedDesignOptionCatalog.contentFrames.filter((frame) => frame.kind === "panel").map((frame) => frame.treatment)
|
|
10301
10200
|
);
|
|
10201
|
+
var generatedFlushTreatments = uniqueNonEmpty2(
|
|
10202
|
+
generatedDesignOptionCatalog.contentFrames.filter((frame) => frame.kind === "flush-panel").map((frame) => frame.treatment)
|
|
10203
|
+
);
|
|
10204
|
+
var generatedFlushBleeds = uniqueNonEmpty2(
|
|
10205
|
+
generatedDesignOptionCatalog.contentFrames.filter((frame) => frame.kind === "flush-panel").map((frame) => frame.bleed)
|
|
10206
|
+
);
|
|
10207
|
+
var generatedPanelFrameSchema = z25.object({
|
|
10208
|
+
kind: z25.literal("panel"),
|
|
10209
|
+
treatment: z25.enum(generatedPanelTreatments)
|
|
10210
|
+
}).strict();
|
|
10211
|
+
var generatedFlushPanelFrameSchema = z25.object({
|
|
10212
|
+
kind: z25.literal("flush-panel"),
|
|
10213
|
+
treatment: z25.enum(generatedFlushTreatments),
|
|
10214
|
+
bleed: z25.enum(generatedFlushBleeds)
|
|
10215
|
+
}).strict();
|
|
10216
|
+
var generatedContentFrameIntentSchema = z25.discriminatedUnion("kind", [
|
|
10217
|
+
z25.object({ kind: z25.literal("plain") }).strict(),
|
|
10218
|
+
generatedPanelFrameSchema,
|
|
10219
|
+
generatedFlushPanelFrameSchema
|
|
10220
|
+
]);
|
|
10221
|
+
var generatedSiteStyleIdSchema = z25.enum(curatedSiteStyleIdValues).transform(asSiteStyleId);
|
|
10222
|
+
function generatedChoiceSchema(valueSchema) {
|
|
10223
|
+
return z25.discriminatedUnion("kind", [
|
|
10224
|
+
z25.object({
|
|
10225
|
+
source: z25.literal("generated"),
|
|
10226
|
+
kind: z25.literal("auto")
|
|
10227
|
+
}).strict(),
|
|
10228
|
+
z25.object({
|
|
10229
|
+
source: z25.literal("generated"),
|
|
10230
|
+
kind: z25.literal("explicit"),
|
|
10231
|
+
value: valueSchema
|
|
10232
|
+
}).strict()
|
|
10233
|
+
]);
|
|
10234
|
+
}
|
|
10235
|
+
var generatedBlockDesignIntentSchema = z25.object({
|
|
10236
|
+
sectionSurface: generatedChoiceSchema(
|
|
10237
|
+
z25.enum(generatedDesignOptionCatalog.sectionSurfaces)
|
|
10238
|
+
),
|
|
10239
|
+
contentFrame: generatedChoiceSchema(generatedContentFrameIntentSchema),
|
|
10240
|
+
itemSurface: generatedChoiceSchema(
|
|
10241
|
+
z25.enum(generatedDesignOptionCatalog.itemSurfaces)
|
|
10242
|
+
),
|
|
10243
|
+
transitionAfter: generatedChoiceSchema(
|
|
10244
|
+
z25.enum(generatedDesignOptionCatalog.transitions)
|
|
10245
|
+
),
|
|
10246
|
+
emphasis: generatedChoiceSchema(
|
|
10247
|
+
z25.enum(generatedDesignOptionCatalog.emphases)
|
|
10248
|
+
)
|
|
10249
|
+
}).strict();
|
|
10250
|
+
var generatedMediaCompositionIntentSchema = z25.enum([
|
|
10251
|
+
"none",
|
|
10252
|
+
"supporting",
|
|
10253
|
+
"dominant"
|
|
10254
|
+
]);
|
|
10255
|
+
var generatedDecorativeCompositionIntentSchema = z25.enum([
|
|
10256
|
+
"none",
|
|
10257
|
+
"supporting"
|
|
10258
|
+
]);
|
|
10259
|
+
var generatedHeroLegibilityStrategySchema = z25.enum([
|
|
10260
|
+
"none",
|
|
10261
|
+
"scrim-gradient"
|
|
10262
|
+
]);
|
|
10263
|
+
var generatedBlockMediaIntentSchema = z25.object({
|
|
10264
|
+
media: generatedMediaCompositionIntentSchema,
|
|
10265
|
+
decorative: generatedDecorativeCompositionIntentSchema,
|
|
10266
|
+
heroLegibility: generatedChoiceSchema(generatedHeroLegibilityStrategySchema)
|
|
10267
|
+
}).strict();
|
|
10268
|
+
var generatedBoundaryIntentSchema = z25.object({
|
|
10269
|
+
transitionAfter: generatedChoiceSchema(
|
|
10270
|
+
z25.enum(generatedDesignOptionCatalog.transitions)
|
|
10271
|
+
)
|
|
10272
|
+
}).strict();
|
|
10273
|
+
var generatedPageDesignBlockIntentSchema = z25.object({
|
|
10274
|
+
blockId: z25.string().min(1),
|
|
10275
|
+
blockKind: z25.string().min(1),
|
|
10276
|
+
purpose: z25.string().min(1),
|
|
10277
|
+
design: generatedBlockDesignIntentSchema,
|
|
10278
|
+
mediaIntent: generatedBlockMediaIntentSchema,
|
|
10279
|
+
boundaryIntent: generatedBoundaryIntentSchema
|
|
10280
|
+
}).strict();
|
|
10281
|
+
var generatedPageDesignIntentSchema = z25.object({
|
|
10282
|
+
siteStyleId: generatedSiteStyleIdSchema,
|
|
10283
|
+
blocks: z25.array(generatedPageDesignBlockIntentSchema)
|
|
10284
|
+
}).strict();
|
|
10285
|
+
|
|
10286
|
+
// ../theme-core/src/site-styles/pageDesignIntent.ts
|
|
10287
|
+
import { z as z26 } from "zod";
|
|
10288
|
+
var pageDesignIntentSchemaVersion = 1;
|
|
10289
|
+
var pageDesignUserPinnedAppearanceChoiceSchema = z26.object({
|
|
10290
|
+
kind: z26.literal("user-pinned"),
|
|
10291
|
+
value: z26.string().min(1).transform(asAppearancePresetId)
|
|
10292
|
+
}).strict();
|
|
10293
|
+
var pageDesignUserPinnedBoundaryChoiceSchema = z26.object({
|
|
10294
|
+
kind: z26.literal("user-pinned"),
|
|
10295
|
+
value: z26.string().min(1).transform(asBoundaryOptionId)
|
|
10296
|
+
}).strict();
|
|
10297
|
+
var pageDesignBlockLookPinSchema = z26.object({
|
|
10298
|
+
blockId: z26.string().min(1).transform(asDesignBlockId),
|
|
10299
|
+
blockKind: z26.string().min(1),
|
|
10300
|
+
choice: pageDesignUserPinnedAppearanceChoiceSchema
|
|
10301
|
+
}).strict();
|
|
10302
|
+
var pageDesignBoundaryPinSchema = z26.object({
|
|
10303
|
+
boundaryId: z26.string().min(1).transform(asDesignBoundaryId),
|
|
10304
|
+
previousBlockId: z26.string().min(1).transform(asDesignBlockId),
|
|
10305
|
+
nextBlockId: z26.string().min(1).transform(asDesignBlockId),
|
|
10306
|
+
choice: pageDesignUserPinnedBoundaryChoiceSchema
|
|
10307
|
+
}).strict().superRefine((pin, ctx) => {
|
|
10308
|
+
const expectedBoundaryId = makeBoundaryId(
|
|
10309
|
+
pin.previousBlockId,
|
|
10310
|
+
pin.nextBlockId
|
|
10311
|
+
);
|
|
10312
|
+
if (pin.boundaryId !== expectedBoundaryId) {
|
|
10313
|
+
ctx.addIssue({
|
|
10314
|
+
code: z26.ZodIssueCode.custom,
|
|
10315
|
+
path: ["boundaryId"],
|
|
10316
|
+
message: `Boundary id must match previousBlockId and nextBlockId. Expected ${expectedBoundaryId}.`
|
|
10317
|
+
});
|
|
10318
|
+
}
|
|
10319
|
+
});
|
|
10320
|
+
var pageDesignIntentV1Schema = z26.object({
|
|
10321
|
+
schemaVersion: z26.literal(pageDesignIntentSchemaVersion),
|
|
10322
|
+
siteStyleId: z26.string().min(1).transform(asSiteStyleId),
|
|
10323
|
+
pageFlowPresetId: z26.string().min(1).transform(asPageFlowPresetId),
|
|
10324
|
+
blockLookPins: z26.array(pageDesignBlockLookPinSchema),
|
|
10325
|
+
boundaryPins: z26.array(pageDesignBoundaryPinSchema)
|
|
10326
|
+
}).strict().superRefine((intent, ctx) => {
|
|
10327
|
+
addDuplicateStringIssues(ctx, {
|
|
10328
|
+
values: intent.blockLookPins.map((pin) => pin.blockId),
|
|
10329
|
+
path: ["blockLookPins"],
|
|
10330
|
+
label: "block Look pin"
|
|
10331
|
+
});
|
|
10332
|
+
addDuplicateStringIssues(ctx, {
|
|
10333
|
+
values: intent.boundaryPins.map(
|
|
10334
|
+
(pin) => boundaryKey(pin.previousBlockId, pin.nextBlockId)
|
|
10335
|
+
),
|
|
10336
|
+
path: ["boundaryPins"],
|
|
10337
|
+
label: "boundary pin"
|
|
10338
|
+
});
|
|
10339
|
+
});
|
|
10340
|
+
function addDuplicateStringIssues(ctx, input) {
|
|
10341
|
+
const seen = /* @__PURE__ */ new Set();
|
|
10342
|
+
const duplicates = /* @__PURE__ */ new Set();
|
|
10343
|
+
for (const value of input.values) {
|
|
10344
|
+
if (seen.has(value)) {
|
|
10345
|
+
duplicates.add(value);
|
|
10346
|
+
}
|
|
10347
|
+
seen.add(value);
|
|
10348
|
+
}
|
|
10349
|
+
for (const duplicate of duplicates) {
|
|
10350
|
+
ctx.addIssue({
|
|
10351
|
+
code: z26.ZodIssueCode.custom,
|
|
10352
|
+
path: [...input.path],
|
|
10353
|
+
message: `Duplicate ${input.label}: ${duplicate}.`
|
|
10354
|
+
});
|
|
10355
|
+
}
|
|
10356
|
+
}
|
|
10357
|
+
function boundaryKey(previousBlockId, nextBlockId) {
|
|
10358
|
+
return makeBoundaryId(previousBlockId, nextBlockId);
|
|
10359
|
+
}
|
|
10302
10360
|
|
|
10303
10361
|
// ../theme-core/src/site-styles/runtimeCompiler.ts
|
|
10304
10362
|
function defineDesignRuntimeRules(rules) {
|
|
@@ -11643,7 +11701,8 @@ function ctaButton(opts) {
|
|
|
11643
11701
|
},
|
|
11644
11702
|
size: {
|
|
11645
11703
|
$bind: {
|
|
11646
|
-
from: sizePath
|
|
11704
|
+
from: sizePath,
|
|
11705
|
+
fallback: opts?.sizeFallback ?? "md"
|
|
11647
11706
|
}
|
|
11648
11707
|
},
|
|
11649
11708
|
...opts?.className ? { className: opts.className } : {},
|
|
@@ -17683,14 +17742,16 @@ var headerCta = ctaButton({
|
|
|
17683
17742
|
whenPath: "menu.ctaItem.label",
|
|
17684
17743
|
variantPath: "menu.ctaItem.variant",
|
|
17685
17744
|
linkPath: "menu.ctaItem.link",
|
|
17686
|
-
|
|
17745
|
+
sizeFallback: "sm",
|
|
17746
|
+
className: `header-cta ${desktopOnlyDisplay("inline-flex")} rb-ml-6`
|
|
17687
17747
|
});
|
|
17688
17748
|
var mobileCta = ctaButton({
|
|
17689
17749
|
basePath: "menu.ctaItem",
|
|
17690
17750
|
whenPath: "menu.ctaItem.label",
|
|
17691
17751
|
variantPath: "menu.ctaItem.variant",
|
|
17692
17752
|
linkPath: "menu.ctaItem.link",
|
|
17693
|
-
|
|
17753
|
+
sizeFallback: "md",
|
|
17754
|
+
className: "nav-mobile-cta rb-w-full"
|
|
17694
17755
|
});
|
|
17695
17756
|
var mobileToggleIcon = stack({ gap: "xs", className: "nav-mobile-icon" }, [
|
|
17696
17757
|
{
|