fix: website factory render pass polish (0.5.5)
Hero scrim, button and preset contrast and layout fixes found by the WO-096 render pass; see docs/adr. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
parent
11fb4e1e04
commit
6f997fc7da
@ -0,0 +1,21 @@
|
||||
# The hero scrim lets the photo show, and the footer logo sits on a plate
|
||||
|
||||
Decided 2026-11-20 for earthen 0.5.5, from the website factory's final render pass (orchestrator WO-096, ADR 0084).
|
||||
|
||||
## Context
|
||||
|
||||
The website factory compiles a customer's site onto this theme. The render pass screenshots every page at 1280 and 390 pixels and measures text over images and every button against what is behind it.
|
||||
|
||||
## Decision
|
||||
|
||||
- The light hero scrim is a radial gradient of the theme background centred on the hero text (at 35% across for the left-aligned hero): 84% at the centre, 80% out to 55% of the radius and 40% at the corners. The flat 82% scrim of the last release met contrast but washed the photo out; the text keeps the same backing while the photo reads at the edges. The render harness measures every text element over the photo (orchestrator WO-096).
|
||||
- An image logo in the footer sits on a plate of the theme background. The footer is the primary colour, and when the website factory sets the primary to the brand colour, a logo drawn in that colour vanished on it (orchestrator WO-086).
|
||||
- Every preset's primary, secondary, accent and destructive colour meets AA (4.5:1) with its foreground in both schemes. The render pass measures every button, and these pairs were under it: ember-loam dark destructive; mossbed dark destructive; mossbed light accent; sage-morning dark destructive; sage-morning light accent; wet-loam dark destructive. Each colour moved the least lightness (at most ten points) that reaches 4.5 with its own foreground, and a colour that could not switched its foreground to white or near-black; a token that held the same colour (the ring) moved with it. The orchestrator's brand colour step keeps whatever contrast a preset has, so a preset under AA also left a branded site under it.
|
||||
- On the primary-coloured call-to-action band the primary button is the background colour with foreground text. The accent button measured 1.8:1 to 2.6:1 against the band, so it had no visible edge.
|
||||
|
||||
## Consequences
|
||||
|
||||
- earthen 0.5.5 is published to the dev registry; the orchestrator's `internal/factory/themes.yaml` pins it.
|
||||
- No schema field changes.
|
||||
|
||||
Keywords: presets, AA, button contrast, primaryForeground, accentForeground, earthen, hero, overlayColor, scrim, radial-gradient, contrast, footer, logo, logo plate, brand colour, WO-096, website factory, render pass
|
||||
12
presets.json
12
presets.json
@ -22,7 +22,7 @@
|
||||
"secondaryForeground": "120 25% 18%",
|
||||
"muted": "40 18% 92%",
|
||||
"mutedForeground": "100 12% 38%",
|
||||
"accent": "18 55% 48%",
|
||||
"accent": "18 55% 44%",
|
||||
"accentForeground": "40 30% 96%",
|
||||
"destructive": "8 70% 45%",
|
||||
"destructiveForeground": "40 30% 96%",
|
||||
@ -45,7 +45,7 @@
|
||||
"mutedForeground": "90 12% 60%",
|
||||
"accent": "18 65% 58%",
|
||||
"accentForeground": "120 18% 8%",
|
||||
"destructive": "8 70% 50%",
|
||||
"destructive": "8 70% 45%",
|
||||
"destructiveForeground": "40 25% 92%",
|
||||
"border": "120 12% 22%",
|
||||
"input": "120 12% 22%",
|
||||
@ -111,7 +111,7 @@
|
||||
"mutedForeground": "80 10% 58%",
|
||||
"accent": "25 70% 55%",
|
||||
"accentForeground": "90 20% 6%",
|
||||
"destructive": "8 70% 50%",
|
||||
"destructive": "8 70% 44%",
|
||||
"destructiveForeground": "60 20% 90%",
|
||||
"border": "90 12% 20%",
|
||||
"input": "90 12% 20%",
|
||||
@ -143,7 +143,7 @@
|
||||
"muted": "70 16% 90%",
|
||||
"mutedForeground": "110 10% 40%",
|
||||
"accent": "38 62% 48%",
|
||||
"accentForeground": "40 30% 97%",
|
||||
"accentForeground": "0 0% 9%",
|
||||
"destructive": "8 70% 45%",
|
||||
"destructiveForeground": "40 30% 96%",
|
||||
"border": "90 12% 80%",
|
||||
@ -165,7 +165,7 @@
|
||||
"mutedForeground": "90 10% 58%",
|
||||
"accent": "40 65% 56%",
|
||||
"accentForeground": "140 15% 9%",
|
||||
"destructive": "8 70% 50%",
|
||||
"destructive": "8 70% 44%",
|
||||
"destructiveForeground": "70 18% 90%",
|
||||
"border": "140 10% 22%",
|
||||
"input": "140 10% 22%",
|
||||
@ -219,7 +219,7 @@
|
||||
"mutedForeground": "30 14% 58%",
|
||||
"accent": "90 30% 52%",
|
||||
"accentForeground": "20 22% 7%",
|
||||
"destructive": "6 72% 52%",
|
||||
"destructive": "6 72% 44%",
|
||||
"destructiveForeground": "35 25% 90%",
|
||||
"border": "20 14% 21%",
|
||||
"input": "20 14% 21%",
|
||||
|
||||
@ -7,7 +7,7 @@
|
||||
{% if text %}<p class="mt-3 text-lg {% if background == "band" %}text-primary-foreground/80{% else %}text-muted-foreground{% endif %}" style="font-family:var(--font-body, 'Work Sans', ui-sans-serif, system-ui, sans-serif)">{{ text }}</p>{% endif %}
|
||||
</div>
|
||||
<div class="flex flex-wrap items-center justify-center gap-3 {% if background != "split" %}mt-8{% else %}shrink-0{% endif %}">
|
||||
{% if primaryUrl and primaryLabel %}<a href="{{ primaryUrl }}" class="earthen-cta inline-flex items-center gap-2 px-6 py-3 font-semibold">{{ primaryLabel }}<svg width="16" height="16" class="h-4 w-4" aria-hidden="true"><use href="/icons/lucide.svg#arrow-right"></use></svg></a>{% endif %}
|
||||
{% if primaryUrl and primaryLabel %}<a href="{{ primaryUrl }}" class="earthen-cta inline-flex items-center gap-2 px-6 py-3 font-semibold"{% if background == "band" %} style="background-color:hsl(var(--background));color:hsl(var(--foreground));"{% endif %}>{{ primaryLabel }}<svg width="16" height="16" class="h-4 w-4" aria-hidden="true"><use href="/icons/lucide.svg#arrow-right"></use></svg></a>{% endif %}
|
||||
{% if secondaryUrl and secondaryLabel %}<a href="{{ secondaryUrl }}" class="inline-flex items-center rounded-lg px-6 py-3 font-semibold transition-colors {% if background == "band" %}hover:bg-white/10{% else %}hover:bg-muted{% endif %}" style="{% if background == "band" %}border:1.5px solid hsl(var(--primary-foreground) / 0.4);color:hsl(var(--primary-foreground));{% else %}border:1.5px solid hsl(var(--border));color:hsl(var(--primary));{% endif %}">{{ secondaryLabel }}</a>{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -9,13 +9,13 @@
|
||||
<div class="{% if fullWidth %}w-full px-4 sm:px-6 lg:px-8{% else %}max-w-7xl mx-auto px-4 sm:px-6 lg:px-8{% endif %} py-16">
|
||||
{% if fl == "minimal" %}
|
||||
<div class="flex flex-col sm:flex-row items-center justify-between gap-6">
|
||||
<div class="flex items-center gap-3">{% if logo %}<img src="{{ logo }}" alt="{{ companyName }}" class="h-8 w-auto"/>{% elif companyName %}<span class="text-lg font-semibold" style="font-family:var(--font-heading, 'Fraunces', 'Playfair Display', Georgia, serif);">{{ companyName }}</span>{% endif %}{% if tagline %}<span class="text-sm text-primary-foreground/70 hidden sm:inline">{{ tagline }}</span>{% endif %}</div>
|
||||
<div class="flex items-center gap-3">{% if logo %}<span class="inline-flex rounded-md p-2" style="background-color:hsl(var(--background));"><img src="{{ logo }}" alt="{{ companyName }}" class="h-8 w-auto"/></span>{% elif companyName %}<span class="text-lg font-semibold" style="font-family:var(--font-heading, 'Fraunces', 'Playfair Display', Georgia, serif);">{{ companyName }}</span>{% endif %}{% if tagline %}<span class="text-sm text-primary-foreground/70 hidden sm:inline">{{ tagline }}</span>{% endif %}</div>
|
||||
{{ sociallinks("") }}
|
||||
</div>
|
||||
{{ legalbar() }}
|
||||
{% elif fl == "centered" %}
|
||||
<div class="flex flex-col items-center text-center gap-5">
|
||||
{% if logo %}<img src="{{ logo }}" alt="{{ companyName }}" class="h-10 w-auto"/>{% elif companyName %}<span class="text-2xl font-semibold" style="font-family:var(--font-heading, 'Fraunces', 'Playfair Display', Georgia, serif);">{{ companyName }}</span>{% endif %}
|
||||
{% if logo %}<span class="inline-flex rounded-md p-2" style="background-color:hsl(var(--background));"><img src="{{ logo }}" alt="{{ companyName }}" class="h-10 w-auto"/></span>{% elif companyName %}<span class="text-2xl font-semibold" style="font-family:var(--font-heading, 'Fraunces', 'Playfair Display', Georgia, serif);">{{ companyName }}</span>{% endif %}
|
||||
<div class="flex items-center gap-4 w-56" aria-hidden="true"><span class="flex-1 h-px" style="background-color:hsl(var(--primary-foreground) / 0.3);"></span><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48" width="28" height="28" class="earthen-glyph" style="color:hsl(var(--primary-foreground) / 0.85);" fill="none" stroke="currentColor" stroke-width="1.4" stroke-linecap="round" stroke-linejoin="round"><path d="M24 44V8"></path><path d="M24 12c-4-2-7-2-9 0M24 12c4-2 7-2 9 0"></path><path d="M24 18c-6-2-10-1-12 1M24 18c6-2 10-1 12 1"></path><path d="M24 25c-7-1-12 0-14 3M24 25c7-1 12 0 14 3"></path><path d="M24 33c-7 0-11 2-12 5M24 33c7 0 11 2 12 5"></path></svg><span class="flex-1 h-px" style="background-color:hsl(var(--primary-foreground) / 0.3);"></span></div>
|
||||
{% if tagline %}<p class="max-w-md text-sm text-primary-foreground/70">{{ tagline }}</p>{% endif %}
|
||||
{% if columns %}<nav class="flex flex-wrap items-center justify-center gap-x-6 gap-y-2">{% for col in columns %}{% for item in col.items %}<a href="{{ item.url|default:'#' }}"{% if item.open_in_new_tab %} target="_blank" rel="noopener"{% endif %} class="text-sm text-primary-foreground/80 hover:text-accent transition-colors">{{ item.label }}</a>{% endfor %}{% endfor %}</nav>{% endif %}
|
||||
@ -26,7 +26,7 @@
|
||||
{% else %}
|
||||
<div class="grid grid-cols-2 md:grid-cols-4 lg:grid-cols-5 gap-8">
|
||||
<div class="col-span-2 lg:col-span-2">
|
||||
{% if logo %}<img src="{{ logo }}" alt="{{ companyName }}" class="h-9 w-auto"/>{% elif companyName %}<span class="text-xl font-semibold" style="font-family:var(--font-heading, 'Fraunces', 'Playfair Display', Georgia, serif);">{{ companyName }}</span>{% endif %}
|
||||
{% if logo %}<span class="inline-flex rounded-md p-2" style="background-color:hsl(var(--background));"><img src="{{ logo }}" alt="{{ companyName }}" class="h-9 w-auto"/></span>{% elif companyName %}<span class="text-xl font-semibold" style="font-family:var(--font-heading, 'Fraunces', 'Playfair Display', Georgia, serif);">{{ companyName }}</span>{% endif %}
|
||||
{% if tagline %}<p class="mt-3 max-w-xs text-sm text-primary-foreground/70">{{ tagline }}</p>{% endif %}
|
||||
{% if address or email or phone %}<address class="mt-4 not-italic text-sm text-primary-foreground/70 space-y-1">{% if address %}<div>{{ address }}</div>{% endif %}{% if email %}<div><a href="mailto:{{ email }}" class="hover:text-accent transition-colors">{{ email }}</a></div>{% endif %}{% if phone %}<div><a href="tel:{{ phone }}" class="hover:text-accent transition-colors">{{ phone }}</a></div>{% endif %}</address>{% endif %}
|
||||
{{ sociallinks("mt-5") }}
|
||||
|
||||
@ -33,7 +33,7 @@
|
||||
{% set align = "center" %}
|
||||
{% if variant == "left-aligned" %}{% set align = "left" %}{% endif %}
|
||||
<section data-block-override="earthen:hero" class="hero relative flex flex-col overflow-hidden bg-background text-foreground bg-paper-grain {% if minHeight == "screen" %}min-h-screen{% elif minHeight == "50vh" %}min-h-[50vh]{% elif minHeight == "auto" %}min-h-[400px]{% else %}min-h-[75vh]{% endif %} {% if verticalAlign == "top" %}justify-start pt-20{% elif verticalAlign == "bottom" %}justify-end pb-20{% else %}justify-center{% endif %}{% if class %} {{ class }}{% endif %}">
|
||||
{% if hasImage %}<div class="absolute inset-0 z-0">{% img backgroundImage alt=headlineText class="h-full w-full object-cover" layout="hero" %}{% if showOverlay %}<div{% if overlayColor == "light" %} style="background: hsl(var(--background) / 0.82);"{% endif %} class="absolute inset-0 {% if overlayColor == "light" %}{% elif overlayColor == "primary" %}bg-primary/50{% elif overlayOpacity <= 30 %}bg-black/30{% elif overlayOpacity <= 50 %}bg-black/50{% elif overlayOpacity <= 70 %}bg-black/70{% else %}bg-black/80{% endif %}"></div>{% endif %}</div>{% endif %}
|
||||
{% if hasImage %}<div class="absolute inset-0 z-0">{% img backgroundImage alt=headlineText class="h-full w-full object-cover" layout="hero" %}{% if showOverlay %}<div{% if overlayColor == "light" %} style="background: radial-gradient(ellipse at {% if variant == "left-aligned" %}35%{% else %}50%{% endif %} 50%, hsl(var(--background) / 0.86) 0%, hsl(var(--background) / 0.8) 50%, hsl(var(--background) / 0.2) 100%);"{% endif %} class="absolute inset-0 {% if overlayColor == "light" %}{% elif overlayColor == "primary" %}bg-primary/50{% elif overlayOpacity <= 30 %}bg-black/30{% elif overlayOpacity <= 50 %}bg-black/50{% elif overlayOpacity <= 70 %}bg-black/70{% else %}bg-black/80{% endif %}"></div>{% endif %}</div>{% endif %}
|
||||
<div class="relative z-10 mx-auto w-full max-w-4xl px-4 sm:px-6 lg:px-8 {% if variant == "left-aligned" %}text-left{% else %}text-center{% endif %}">{{ herocontent(align) }}</div>
|
||||
</section>
|
||||
{% endif %}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user