Event Hero 2
Workshop hero: a work-table photo with the offer card breaking its lower edge, a session-date chooser and pinned leave-with notes, so a low price reads as a working session, not a webinar.
Use it in a prompt
Use hero/event-hero-2 from the FunnelDNA library. Follow the skill and theme contract. Ask me for the copy, images, and brand details you need; do not invent proof.
Paste into Claude or ChatGPT with FunnelDNA connected (MCP setup), or alongside the skill.
Use it in code
- Save
component.tsx(Code tab) ascomponents/funneldna/hero/event-hero-2.tsx. - Import it and pass your copy and images (Props tab):
import { EventHero2 } from "@/components/funneldna/hero/event-hero-2"
It restyles from the theme tokens on any wrapper (Theme tab). The specimen source is a complete working example.
pieces/hero/event-hero-2/component.tsx 452 lines
// layout: annotated-board
// Workshop hero: a work-table photo with the offer card breaking its lower edge, a session-date chooser and pinned leave-with notes, so a low price reads as a working session, not a webinar.
'use client'
import * as React from 'react'
import { CalendarDays, Check, Clock, Laptop, MonitorPlay, Pin } from 'lucide-react'
export type EventHero2Session = {
/** Stable id; falls back to the start time. */
id?: string
/** Session start as an ISO date-time (e.g. 2026-12-03T18:00:00Z), shown in the visitor's local time. */
start: string
/** Length in minutes when this session differs from durationMinutes. */
minutes?: number
/** Only when it is really full: the chip is shown disabled. */
soldOut?: boolean
/** Optional fixed text for the chip, the date line and the time line. */
chipLabel?: string
dateLabel?: string
timeLabel?: string
}
export type EventHero2Outcome = {
/** What they walk out with, short. */
title: string
detail?: string
}
export type EventHero2Copy = {
/** Legend above the date chips. */
chooserLabel: string
/** Shown in a chip whose session is full. */
soldOut: string
/** Time line when shown in the visitor's own zone; {time} is the formatted range. */
timeLocal: string
/** Time line when a fixed timeZone or timeLabel is used; {time} is the formatted range. */
timeFixed: string
/** Heading above the pinned outcome notes. */
outcomesTitle: string
/** Bold lead-in before the reason-why line. */
reasonLead: string
psLabel: string
/** Button label when every supplied session is full. */
allSoldOut: string
/** Alt text for the work-table photo when sceneAlt is not given. */
photoAlt: string
}
export type EventHero2State = 'default' | 'hover' | 'active' | 'disabled'
export type EventHero2Props = {
/** The session's name, e.g. Proposal Sprint. */
eventName?: string
/** Format and length, e.g. Live 2-hour working session. */
format?: string
/** The result headline. */
headline: React.ReactNode
/** One phrase inside a string headline that gets the marker stroke. */
highlight?: string
lead?: React.ReactNode
/** The work-table photo (scene slot). */
sceneImage?: string
sceneAlt?: string
/** One session renders a plain date line; two or more render the chooser. */
sessions?: EventHero2Session[]
/** Default session length in minutes. */
durationMinutes?: number
/** Fixed IANA zone (e.g. America/New_York); omit to show the visitor's local time. */
timeZone?: string
locale?: string
price?: string
/** Short line beside the price, e.g. One seat, one payment. */
priceNote?: string
/** Supplied breakdown under the price, e.g. about $24.50 an hour. */
breakdown?: React.ReactNode
/** The reason-why line for the low price. */
reason?: React.ReactNode
/** Three leave-with outcomes read best. */
outcomes?: EventHero2Outcome[]
/** Outcome-verb action, e.g. Get my proposal sent. */
ctaLabel: string
/** One short line under the button. */
ctaNote?: string
/** P.S. line restating the guarantee or the main benefit. */
ps?: React.ReactNode
href?: string
/** Called with the chosen session. */
onAction?: (session?: EventHero2Session) => void
onSessionChange?: (session: EventHero2Session) => void
copy?: Partial<EventHero2Copy>
/** Studio preview state for the button. */
state?: EventHero2State
className?: string
}
const DEFAULT_COPY: EventHero2Copy = {
chooserLabel: 'Pick your session',
soldOut: 'Full',
timeLocal: '{time}, your local time',
timeFixed: '{time}',
outcomesTitle: 'Walk out with the work done',
reasonLead: 'Why so low?',
psLabel: 'P.S.',
allSoldOut: 'Every session is full',
photoAlt: 'A laptop and an open notebook on a work table, ready for a working session',
}
export function EventHero2({
eventName,
format,
headline,
highlight,
lead,
sceneImage,
sceneAlt,
sessions = [],
durationMinutes = 120,
timeZone,
locale = 'en-US',
price,
priceNote,
breakdown,
reason,
outcomes = [],
ctaLabel,
ctaNote,
ps,
href,
onAction,
onSessionChange,
copy,
state = 'default',
className,
}: EventHero2Props) {
const text = { ...DEFAULT_COPY, ...copy }
const groupName = React.useId()
// Format in a fixed zone until mounted, then switch to the visitor's own zone (no hydration mismatch).
const [zone, setZone] = React.useState<string | undefined>(timeZone ?? 'UTC')
React.useEffect(() => {
setZone(timeZone)
}, [timeZone])
const firstOpen = sessions.find(s => !s.soldOut)
const [picked, setPicked] = React.useState<string | undefined>(firstOpen ? keyOf(firstOpen) : undefined)
const current = sessions.find(s => keyOf(s) === picked && !s.soldOut) ?? firstOpen
const view = current ? describe(current, durationMinutes, zone, locale) : undefined
const showsLocal = !timeZone && zone === undefined && !current?.timeLabel
const allFull = sessions.length > 0 && !current
const disabled = state === 'disabled' || allFull
const force = state === 'hover' || state === 'active' ? state : undefined
const label = allFull ? text.allSoldOut : ctaLabel
const choose = (s: EventHero2Session) => {
setPicked(keyOf(s))
onSessionChange?.(s)
}
const act = () => {
if (!disabled) onAction?.(current)
}
return (
<section className={cn('cf-event-hero-2', className)}>
<style>{CSS}</style>
<div className='ehtwo-wrap'>
{sceneImage && (
<figure className='ehtwo-photo'>
<img src={sceneImage} alt={sceneAlt ?? text.photoAlt} width={1600} height={800} loading='eager' decoding='async' />
</figure>
)}
<div className={cn('ehtwo-board', !sceneImage && 'ehtwo-board--flat', outcomes.length === 0 && 'ehtwo-board--solo')}>
<div className='ehtwo-card'>
{(eventName || format) && (
<p className='ehtwo-meta'>
<MonitorPlay className='ehtwo-inline' aria-hidden strokeWidth={2.5} />
{eventName && <strong>{eventName}</strong>}
{eventName && format && <span aria-hidden> · </span>}
{format && <span>{format}</span>}
</p>
)}
<h1 className='ehtwo-h1'>{withMarker(headline, highlight)}</h1>
{lead && <p className='ehtwo-lead'>{keepHyphens(lead)}</p>}
{sessions.length > 1 && (
<fieldset className='ehtwo-chooser'>
<legend className='ehtwo-legend'>{text.chooserLabel}</legend>
<div className='ehtwo-chips'>
{sessions.map(s => {
const k = keyOf(s)
const on = current ? keyOf(current) === k : false
const parts = chipParts(s, zone, locale)
return (
<label key={k} className='ehtwo-chip'>
<input type='radio' name={groupName} value={k} checked={on} disabled={s.soldOut} onChange={() => choose(s)} />
<span className='ehtwo-chip-face'>
{(parts.weekday || on) && (
<span className='ehtwo-chip-wd'>
{on && <Check aria-hidden strokeWidth={2.5} />}
{parts.weekday}
</span>
)}
<span className='ehtwo-chip-day'>{parts.day}</span>
{s.soldOut && <span className='ehtwo-chip-full'>{text.soldOut}</span>}
</span>
</label>
)
})}
</div>
</fieldset>
)}
{view && (
<ul className={cn('ehtwo-when', sessions.length < 2 && 'ehtwo-when--single')} aria-live='polite'>
<li>
<CalendarDays aria-hidden strokeWidth={2.5} />
<span className='ehtwo-when-date'>{view.date}</span>
</li>
{view.time && (
<li>
<Clock aria-hidden strokeWidth={2.5} />
<span>{fill(showsLocal ? text.timeLocal : text.timeFixed, view.time)}</span>
</li>
)}
</ul>
)}
{price && (
<div className='ehtwo-price'>
<div className='ehtwo-price-row'>
<span className='ehtwo-price-num'>{price}</span>
{(priceNote || breakdown) && (
<span className='ehtwo-price-side'>
{priceNote && <span className='ehtwo-price-note'>{priceNote}</span>}
{breakdown && <span className='ehtwo-price-break'>{breakdown}</span>}
</span>
)}
</div>
{reason && (
<p className='ehtwo-reason'>
{text.reasonLead && <strong>{text.reasonLead} </strong>}
{keepHyphens(reason)}
</p>
)}
</div>
)}
<div className='ehtwo-action'>
{href && !disabled ? (
<a className='ehtwo-btn' href={href} data-force={force} onClick={act}>{label}</a>
) : (
<button type='button' className='ehtwo-btn' data-force={force} disabled={disabled} onClick={act}>{label}</button>
)}
{ctaNote && (
<p className='ehtwo-cta-note'>
<Laptop className='ehtwo-inline' aria-hidden strokeWidth={2.5} />
{ctaNote}
</p>
)}
{ps && (
<p className='ehtwo-ps'>
<strong>{text.psLabel}</strong> {keepHyphens(ps)}
</p>
)}
</div>
</div>
{outcomes.length > 0 && (
<div className='ehtwo-notes'>
<h2 className='ehtwo-notes-title'>{text.outcomesTitle}</h2>
<ol className='ehtwo-list'>
{outcomes.map((o, i) => (
<li key={i} className='ehtwo-note' style={{ animationDelay: `${Math.min(0.07 * (i + 1), 0.28)}s` }}>
<Pin className='ehtwo-pin' aria-hidden fill='currentColor' strokeWidth={2.5} />
<span className='ehtwo-num' aria-hidden>{i + 1}</span>
<div>
<h3 className='ehtwo-note-title'>{o.title}</h3>
{o.detail && <p className='ehtwo-note-detail'>{o.detail}</p>}
</div>
</li>
))}
</ol>
</div>
)}
</div>
</div>
</section>
)
}
export default EventHero2
function keyOf(s: EventHero2Session) {
return s.id ?? s.start
}
function cn(...v: (string | false | undefined | null)[]) {
return v.filter(Boolean).join(' ')
}
function fill(template: string, time: string) {
return template.split('{time}').join(time)
}
// Keeps hyphenated words such as "2-hour" or "money-back" on one line, so no line ends on a stranded "2-".
function keepHyphens(node: React.ReactNode): React.ReactNode {
if (typeof node !== 'string' || !node.includes('-')) return node
return node.split(/(\S+-\S+)/g).map((part, i) =>
i % 2 ? (
<span key={i} className='ehtwo-nobr'>
{part}
</span>
) : (
part
),
)
}
function withMarker(node: React.ReactNode, phrase?: string) {
if (typeof node !== 'string') return node
if (!phrase) return keepHyphens(node)
const i = node.indexOf(phrase)
if (i < 0) return keepHyphens(node)
return (
<>
{keepHyphens(node.slice(0, i))}
<span className='ehtwo-mark'>{keepHyphens(phrase)}</span>
{keepHyphens(node.slice(i + phrase.length))}
</>
)
}
// Date tile text: a short weekday over the month and day.
function chipParts(s: EventHero2Session, zone: string | undefined, locale: string): { weekday?: string; day: string } {
if (s.chipLabel) return { day: s.chipLabel }
const start = new Date(s.start)
if (Number.isNaN(start.getTime())) return { day: s.dateLabel ?? s.start }
const base: Intl.DateTimeFormatOptions = zone ? { timeZone: zone } : {}
try {
return {
weekday: new Intl.DateTimeFormat(locale, { ...base, weekday: 'short' }).format(start),
day: new Intl.DateTimeFormat(locale, { ...base, month: 'short', day: 'numeric' }).format(start),
}
} catch {
return { day: s.dateLabel ?? s.start }
}
}
function describe(s: EventHero2Session, fallbackMinutes: number, zone: string | undefined, locale: string) {
const start = new Date(s.start)
if (Number.isNaN(start.getTime())) return { date: s.dateLabel ?? s.start, time: s.timeLabel ?? '' }
const end = new Date(start.getTime() + (s.minutes ?? fallbackMinutes) * 60000)
const base: Intl.DateTimeFormatOptions = zone ? { timeZone: zone } : {}
try {
const date = s.dateLabel ?? new Intl.DateTimeFormat(locale, { ...base, weekday: 'long', month: 'long', day: 'numeric' }).format(start)
const from = new Intl.DateTimeFormat(locale, { ...base, hour: 'numeric', minute: '2-digit' }).format(start)
const to = new Intl.DateTimeFormat(locale, { ...base, hour: 'numeric', minute: '2-digit', timeZoneName: 'short' }).format(end)
return { date, time: s.timeLabel ?? `${from} – ${to}` }
} catch {
return { date: s.dateLabel ?? s.start, time: s.timeLabel ?? '' }
}
}
const CSS = `
.cf-event-hero-2{--ehtwo-shadow:var(--shadow,oklch(0.22 0.03 256));--ehtwo-line:oklch(from var(--ink,#101828) l c h / .12);--ehtwo-marker:color-mix(in oklab,var(--marker,#fae37c) 45%,var(--card,#fff));--ehtwo-pick:color-mix(in oklab,var(--accent,#1d5fd1) 12%,var(--card,#fff));position:relative;overflow-x:clip;background:var(--surface,#fff);color:var(--ink,#101828);font-family:var(--font-body);padding:clamp(24px,4vw,56px) clamp(16px,5vw,48px) clamp(64px,8.5vw,120px)}
.cf-event-hero-2 .ehtwo-nobr{white-space:nowrap}
.cf-event-hero-2 *,.cf-event-hero-2 *::before,.cf-event-hero-2 *::after{box-sizing:border-box}
.cf-event-hero-2 .ehtwo-wrap{max-width:1120px;margin:0 auto}
.cf-event-hero-2 .ehtwo-photo{position:relative;margin:0;width:100%;aspect-ratio:2/1;overflow:hidden;border-radius:12px;background:color-mix(in oklch,var(--ink,#101828) 6%,var(--surface,#fff))}
.cf-event-hero-2 .ehtwo-photo img{position:absolute;inset:0;display:block;width:100%;height:100%;object-fit:cover;object-position:62% 42%}
.cf-event-hero-2 .ehtwo-board{position:relative;z-index:1;display:grid;grid-template-columns:minmax(0,min(37.5rem,58%)) minmax(0,1fr);column-gap:clamp(32px,5vw,72px);row-gap:32px;align-items:start}
.cf-event-hero-2 .ehtwo-board--solo{grid-template-columns:minmax(0,37.5rem)}
.cf-event-hero-2 .ehtwo-card{margin:calc(-1 * clamp(150px,17vw,250px)) 0 0 clamp(16px,3vw,40px);padding:clamp(20px,3vw,32px);background:var(--card,#fff);color:var(--ink,#101828);border:1px solid var(--card-border,var(--ehtwo-line));border-radius:var(--card-radius,var(--radius,14px));box-shadow:var(--card-shadow,var(--shadow-lg,0 2px 4px oklch(from var(--ehtwo-shadow) l c h / .22),0 12px 24px -8px oklch(from var(--ehtwo-shadow) l c h / .32)))}
.cf-event-hero-2 .ehtwo-board--flat .ehtwo-card{margin-top:0}
.cf-event-hero-2 .ehtwo-inline{display:inline-block;width:1.1em;height:1.1em;vertical-align:-.18em;margin-inline-end:.45em}
.cf-event-hero-2 .ehtwo-meta{margin:0 0 16px;font-size:.9375rem;line-height:1.4;font-weight:600;color:var(--muted,#4a5565);text-wrap:pretty}
.cf-event-hero-2 .ehtwo-meta strong{font-weight:800;color:var(--accent,#1d5fd1)}
.cf-event-hero-2 .ehtwo-meta .ehtwo-inline{color:var(--accent,#1d5fd1)}
.cf-event-hero-2 .ehtwo-h1{margin:0;font-family:var(--font-display);font-size:clamp(2rem,3.6vw,3.25rem);line-height:1.06;font-weight:var(--display-weight,800);letter-spacing:var(--display-tracking,-0.025em);text-transform:var(--display-case,none);text-wrap:balance;color:var(--ink,#101828)}
.cf-event-hero-2 .ehtwo-mark{background-image:linear-gradient(transparent 52%,var(--ehtwo-marker) 52%,var(--ehtwo-marker) 94%,transparent 94%);-webkit-box-decoration-break:clone;box-decoration-break:clone;padding:0 .06em;margin:0 -.03em}
.cf-event-hero-2 .ehtwo-lead{margin:14px 0 0;font-size:clamp(1.125rem,1.4vw,1.25rem);line-height:1.45;font-weight:500;color:var(--muted,#4a5565);text-wrap:pretty}
.cf-event-hero-2 .ehtwo-chooser{margin:24px 0 0;padding:0;border:0;min-width:0}
.cf-event-hero-2 .ehtwo-legend{padding:0;margin:0 0 12px;font-size:1rem;line-height:1.3;font-weight:700;color:var(--ink,#101828)}
.cf-event-hero-2 .ehtwo-chips{display:grid;grid-template-columns:repeat(auto-fill,minmax(5.75rem,1fr));gap:8px}
.cf-event-hero-2 .ehtwo-chip{position:relative;display:flex;min-width:0}
.cf-event-hero-2 .ehtwo-chip input{position:absolute;width:1px;height:1px;margin:-1px;padding:0;border:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.cf-event-hero-2 .ehtwo-chip-face{flex:1 1 auto;min-width:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;min-height:64px;padding:8px 10px;border-radius:var(--field-radius,var(--radius,12px));border:1px solid oklch(from var(--ink,#101828) l c h / .16);background:color-mix(in oklch,var(--ink,#101828) 4%,var(--card,#fff));color:var(--ink,#101828);text-align:center;font-variant-numeric:tabular-nums;cursor:pointer;user-select:none}
.cf-event-hero-2 .ehtwo-chip-wd{display:inline-flex;align-items:center;gap:4px;font-size:.875rem;line-height:1.2;font-weight:700;color:var(--muted,#4a5565)}
.cf-event-hero-2 .ehtwo-chip-wd svg{width:16px;height:16px;flex:none;color:var(--accent,#1d5fd1)}
.cf-event-hero-2 .ehtwo-chip-day{font-size:1.0625rem;line-height:1.2;font-weight:800;white-space:nowrap}
.cf-event-hero-2 .ehtwo-chip:hover input:not(:disabled):not(:checked)+.ehtwo-chip-face{border-color:oklch(from var(--ink,#101828) l c h / .34);background:color-mix(in oklch,var(--ink,#101828) 7%,var(--card,#fff))}
.cf-event-hero-2 .ehtwo-chip input:checked+.ehtwo-chip-face{background:var(--ehtwo-pick);border-color:var(--accent,#1d5fd1);box-shadow:inset 0 0 0 1px var(--accent,#1d5fd1),var(--shadow-sm,0 1px 2px oklch(from var(--ehtwo-shadow) l c h / .2))}
.cf-event-hero-2 .ehtwo-chip input:checked+.ehtwo-chip-face .ehtwo-chip-wd{color:var(--ink,#101828)}
.cf-event-hero-2 .ehtwo-chip input:focus-visible+.ehtwo-chip-face{outline:3px solid oklch(from var(--field-focus,var(--accent,#1d5fd1)) l c h / .45);outline-offset:2px}
.cf-event-hero-2 .ehtwo-chip input:disabled+.ehtwo-chip-face{cursor:not-allowed;border-color:transparent;background:var(--secondary,color-mix(in oklch,var(--ink,#101828) 8%,var(--card,#fff)));color:var(--secondary-ink,var(--muted,#4a5565))}
.cf-event-hero-2 .ehtwo-chip input:disabled+.ehtwo-chip-face .ehtwo-chip-wd{color:var(--secondary-ink,var(--muted,#4a5565))}
.cf-event-hero-2 .ehtwo-chip input:disabled+.ehtwo-chip-face .ehtwo-chip-day{text-decoration:line-through;text-decoration-thickness:1.5px}
.cf-event-hero-2 .ehtwo-chip-full{font-size:.875rem;line-height:1.2;font-weight:700}
.cf-event-hero-2 .ehtwo-when{list-style:none;margin:18px 0 0;padding:0;display:grid;gap:8px;font-size:1.0625rem;line-height:1.4;color:var(--ink,#101828)}
.cf-event-hero-2 .ehtwo-when--single{margin-top:24px}
.cf-event-hero-2 .ehtwo-when li{display:flex;align-items:flex-start;gap:10px}
.cf-event-hero-2 .ehtwo-when svg{width:20px;height:20px;flex:none;margin-top:1px;color:var(--accent,#1d5fd1)}
.cf-event-hero-2 .ehtwo-when-date{font-weight:800}
.cf-event-hero-2 .ehtwo-price{margin-top:28px}
.cf-event-hero-2 .ehtwo-price-row{display:flex;flex-wrap:wrap;align-items:flex-end;gap:8px 16px}
.cf-event-hero-2 .ehtwo-price-num{font-family:var(--font-display);font-size:clamp(2.5rem,4.2vw,3.75rem);line-height:1;font-weight:var(--display-weight,800);letter-spacing:-0.03em;font-variant-numeric:tabular-nums;color:var(--ink,#101828)}
.cf-event-hero-2 .ehtwo-price-side{display:grid;gap:2px;flex:1 1 12rem;min-width:0;padding-bottom:4px}
.cf-event-hero-2 .ehtwo-price-note{font-size:.9375rem;line-height:1.3;font-weight:800;color:var(--ink,#101828)}
.cf-event-hero-2 .ehtwo-price-break{font-size:.9375rem;line-height:1.4;font-weight:500;color:var(--muted,#4a5565);text-wrap:pretty}
.cf-event-hero-2 .ehtwo-reason{margin:16px 0 0;padding:12px 16px;border-radius:10px;background:color-mix(in oklch,var(--ink,#101828) 4%,var(--card,#fff));color:var(--ink,#101828);font-size:1rem;line-height:1.45;text-wrap:pretty}
.cf-event-hero-2 .ehtwo-reason strong{font-weight:800}
.cf-event-hero-2 .ehtwo-action{margin-top:28px}
.cf-event-hero-2 .ehtwo-btn{display:flex;width:100%;align-items:center;justify-content:center;min-height:64px;padding:12px 28px;border:0;border-radius:var(--button-radius,var(--radius,12px));background:linear-gradient(oklch(from var(--button-bg,var(--cta)) calc(l + .04) c h),oklch(from var(--button-bg-2,var(--cta-2)) calc(l - .02) c h));color:var(--button-ink,var(--cta-ink));font-family:var(--button-font,var(--font-display));font-size:clamp(1.125rem,1.55vw,1.375rem);line-height:1.15;font-weight:var(--button-weight,800);text-transform:var(--button-case,none);text-align:center;text-wrap:balance;text-decoration:none;text-shadow:var(--button-text-shadow,none);cursor:pointer;-webkit-tap-highlight-color:transparent;box-shadow:var(--button-shadow,inset 0 1px 0 oklch(from var(--button-bg,var(--cta)) calc(l + .14) c h / .7),inset 0 -3px 0 oklch(from var(--button-bg,var(--cta)) calc(l - .16) c h),0 1px 2px oklch(from var(--ehtwo-shadow) l c h / .3),0 8px 16px -6px oklch(from var(--ehtwo-shadow) l c h / .45))}
.cf-event-hero-2 .ehtwo-btn:hover:not(:disabled),.cf-event-hero-2 .ehtwo-btn[data-force=hover]{background:linear-gradient(oklch(from var(--button-bg,var(--cta)) calc(l - .01) c h),oklch(from var(--button-bg-2,var(--cta-2)) calc(l - .07) c h));box-shadow:var(--button-shadow,inset 0 1px 0 oklch(from var(--button-bg,var(--cta)) calc(l + .1) c h / .7),inset 0 -3px 0 oklch(from var(--button-bg,var(--cta)) calc(l - .2) c h),0 1px 2px oklch(from var(--ehtwo-shadow) l c h / .32),0 10px 20px -6px oklch(from var(--ehtwo-shadow) l c h / .5))}
.cf-event-hero-2 .ehtwo-btn:active:not(:disabled),.cf-event-hero-2 .ehtwo-btn[data-force=active]{transform:translateY(1px);background:linear-gradient(oklch(from var(--button-bg,var(--cta)) calc(l - .04) c h),oklch(from var(--button-bg-2,var(--cta-2)) calc(l - .08) c h));box-shadow:inset 0 2px 4px oklch(from var(--button-bg,var(--cta)) calc(l - .22) c h / .45),inset 0 -2px 0 oklch(from var(--button-bg,var(--cta)) calc(l - .16) c h),0 1px 1px oklch(from var(--ehtwo-shadow) l c h / .3)}
.cf-event-hero-2 .ehtwo-btn:focus-visible{outline:3px solid oklch(from var(--field-focus,var(--accent,#1d5fd1)) l c h / .55);outline-offset:3px}
.cf-event-hero-2 .ehtwo-btn:disabled{cursor:not-allowed;transform:none;background:var(--button-2-bg,var(--secondary,#e8ebf0));color:var(--button-2-ink,var(--secondary-ink,#101828));text-shadow:none;box-shadow:var(--button-2-shadow,var(--shadow-sm,0 1px 2px oklch(from var(--ehtwo-shadow) l c h / .2)))}
.cf-event-hero-2 .ehtwo-cta-note{margin:12px 0 0;text-align:center;font-size:.9375rem;line-height:1.4;font-weight:600;color:var(--muted,#4a5565);text-wrap:pretty}
.cf-event-hero-2 .ehtwo-ps{margin:16px 0 0;font-size:1rem;line-height:1.5;color:var(--ink,#101828);text-wrap:pretty}
.cf-event-hero-2 .ehtwo-ps strong{font-family:var(--font-display);font-weight:800;margin-right:.15em}
.cf-event-hero-2 .ehtwo-notes{min-width:0;padding-top:clamp(24px,3vw,40px)}
.cf-event-hero-2 .ehtwo-notes-title{margin:0 0 28px;font-family:var(--font-display);font-size:clamp(1.3125rem,1.8vw,1.625rem);line-height:1.15;font-weight:var(--display-weight,800);letter-spacing:-0.01em;text-transform:var(--display-case,none);text-wrap:balance;color:var(--ink,#101828)}
.cf-event-hero-2 .ehtwo-list{list-style:none;margin:0;padding:0;display:grid;gap:22px}
.cf-event-hero-2 .ehtwo-note{position:relative;display:grid;grid-template-columns:auto minmax(0,1fr);column-gap:14px;max-width:calc(100% - 32px);padding:20px 22px 20px 20px;background:var(--card,#fff);color:var(--ink,#101828);border:1px solid var(--card-border,var(--ehtwo-line));border-radius:var(--card-radius,var(--radius,14px));box-shadow:var(--shadow-sm,0 1px 1px oklch(from var(--ehtwo-shadow) l c h / .18),0 1px 3px oklch(from var(--ehtwo-shadow) l c h / .14));rotate:var(--ehtwo-tilt,0deg)}
.cf-event-hero-2 .ehtwo-note:nth-child(3n+1){--ehtwo-tilt:-1deg}
.cf-event-hero-2 .ehtwo-note:nth-child(3n+2){--ehtwo-tilt:.8deg;margin-left:32px}
.cf-event-hero-2 .ehtwo-note:nth-child(3n){--ehtwo-tilt:-.4deg;margin-left:12px}
.cf-event-hero-2 .ehtwo-pin{position:absolute;top:-12px;left:22px;width:22px;height:22px;rotate:20deg;color:var(--accent-fill,var(--accent,#1d5fd1));stroke:oklch(from var(--accent-fill,var(--accent,#1d5fd1)) calc(l - .2) c h);filter:drop-shadow(0 1px 1px oklch(from var(--ehtwo-shadow) l c h / .35)) drop-shadow(0 3px 3px oklch(from var(--ehtwo-shadow) l c h / .18))}
.cf-event-hero-2 .ehtwo-num{min-width:1ch;font-family:var(--font-display);font-size:clamp(1.3125rem,1.8vw,1.625rem);line-height:1;font-weight:var(--display-weight,800);font-variant-numeric:tabular-nums;color:var(--accent,#1d5fd1)}
.cf-event-hero-2 .ehtwo-note-title{margin:0;font-family:var(--font-display);font-size:1.125rem;line-height:1.25;font-weight:800;text-wrap:balance}
.cf-event-hero-2 .ehtwo-note-detail{margin:6px 0 0;font-size:1rem;line-height:1.45;color:var(--muted,#4a5565);text-wrap:pretty}
@media (max-width:860px){
.cf-event-hero-2 .ehtwo-photo{aspect-ratio:4/3}
.cf-event-hero-2 .ehtwo-board,.cf-event-hero-2 .ehtwo-board--solo{grid-template-columns:minmax(0,1fr)}
.cf-event-hero-2 .ehtwo-card{margin:-48px 8px 0}
.cf-event-hero-2 .ehtwo-board--flat .ehtwo-card{margin:0}
.cf-event-hero-2 .ehtwo-notes{padding-top:8px}
.cf-event-hero-2 .ehtwo-list{gap:18px}
.cf-event-hero-2 .ehtwo-note:nth-child(n){--ehtwo-tilt:0deg;margin-left:0;max-width:none}
}
@media (max-width:520px){
.cf-event-hero-2 .ehtwo-btn{padding:12px 16px;font-size:1.125rem}
.cf-event-hero-2 .ehtwo-price-side{flex-basis:100%}
}
@keyframes ehtwo-rise{from{opacity:.82;translate:0 8px}to{opacity:1;translate:0 0}}
@media (prefers-reduced-motion:no-preference){
.cf-event-hero-2 .ehtwo-card,.cf-event-hero-2 .ehtwo-note{animation:ehtwo-rise .45s cubic-bezier(.2,.7,.2,1) both}
.cf-event-hero-2 .ehtwo-btn{transition:background .16s ease,box-shadow .16s ease,transform .16s ease}
.cf-event-hero-2 .ehtwo-chip-face{transition:background-color .16s ease,border-color .16s ease,box-shadow .16s ease}
}
`
pieces/hero/event-hero-2/specimen.tsx 43 lines
import __studioImage27f4cf8a from "../assets/620b485433f2e2b9.webp";
import { EventHero2 } from '../event-hero-2'
import defaults from '../../studio-defaults.json'
import { slot } from '../../slots'
export const states = ['default', 'hover', 'active', 'disabled']
type SpecimenState = 'default' | 'hover' | 'active' | 'disabled'
export default function EventHero2Specimen({ state = 'default' }: { state?: SpecimenState }) {
const guarantee = defaults.sample.guarantee.toLowerCase()
return (
<EventHero2
state={state}
eventName='Proposal Sprint'
format='Live 2-hour working session'
headline='Send a proposal that wins the project in one 2-hour sitting'
highlight='wins the project'
lead='Bring one client you want to win. You write it, price it and send it before we close, with feedback on every section.'
sceneImage={slot('scene', __studioImage27f4cf8a)}
sceneAlt='A laptop, an open notebook and a coffee on a sunlit work table, set up for a working session'
sessions={[
{ id: 'dec-3', start: '2026-12-03T18:00:00Z' },
{ id: 'dec-10', start: '2026-12-10T18:00:00Z' },
{ id: 'dec-15', start: '2026-12-15T23:00:00Z' },
]}
durationMinutes={120}
price='$49'
priceNote='One seat, one payment'
breakdown='Two hours of hands-on time, about $24.50 an hour'
reason='It’s a working session, so you leave with a sent proposal, not a page of notes.'
copy={{ reasonLead: 'Why only $49?', outcomesTitle: 'Walk out with three things finished' }}
outcomes={[
{ title: 'A proposal sent to a real client', detail: 'Written, priced and in their inbox before we close.' },
{ title: 'A three-tier price you can defend', detail: 'Anchored to the result for the client, not to your hours.' },
{ title: 'A proposal template you keep', detail: 'Your structure and wording, ready for the next lead.' },
]}
ctaLabel='Get my proposal sent'
ctaNote='Live on Zoom · bring your laptop'
ps={`Leave with your proposal sent, or ask for your money back: every seat carries a ${guarantee}.`}
/>
)
}
| Name | Type | Details |
|---|---|---|
eventName OptionalEventHero2 |
string |
|
format OptionalEventHero2 |
string |
|
headline RequiredEventHero2 |
React.ReactNode |
|
highlight OptionalEventHero2 |
string |
|
lead OptionalEventHero2 |
React.ReactNode |
|
sceneImage OptionalEventHero2 |
string |
|
sceneAlt OptionalEventHero2 |
string |
|
sessions OptionalEventHero2 |
EventHero2Session[] |
Default []
|
durationMinutes OptionalEventHero2 |
number |
Default 120
|
timeZone OptionalEventHero2 |
string |
|
locale OptionalEventHero2 |
string |
Default 'en-US'
|
price OptionalEventHero2 |
string |
|
priceNote OptionalEventHero2 |
string |
|
breakdown OptionalEventHero2 |
React.ReactNode |
|
reason OptionalEventHero2 |
React.ReactNode |
|
outcomes OptionalEventHero2 |
EventHero2Outcome[] |
Default []
|
ctaLabel RequiredEventHero2 |
string |
|
ctaNote OptionalEventHero2 |
string |
|
ps OptionalEventHero2 |
React.ReactNode |
|
href OptionalEventHero2 |
string |
|
onAction OptionalEventHero2 |
(session?: EventHero2Session) => void |
|
onSessionChange OptionalEventHero2 |
(session: EventHero2Session) => void |
|
copy OptionalEventHero2 |
Partial<EventHero2Copy> |
|
state OptionalEventHero2 |
EventHero2State |
Default 'default'
|
className OptionalEventHero2 |
string |
Theme roles it reads
Set by the theme bar, a preset or your brand. Colours come from the base tokens (--surface, --ink, --cta…) every piece uses.
--button-bg--button-bg-2--button-case--button-font--button-ink--button-radius--button-shadow--button-text-shadow--button-weight- Main CTA button: background, ink, font, weight, case, radius and shadow.
--button-2-bg--button-2-ink--button-2-shadow- Secondary button.
--card-border--card-radius--card-shadow- Cards and panels: radius, border and shadow.
--display-case--display-tracking--display-weight- Headlines: weight, letter case and tracking.
--field-focus--field-radius- Form inputs: background, ink, border, radius and focus colour.
--marker- The highlighter colour behind key phrases.
Image slots
Filled from the brand’s images; the specimen ships its own defaults.
scene- A wide atmosphere photo behind or beside the copy.
-
620b485433f2e2b9.webp
image/webp · 54.7 KB
-
b77916eca54aa689.webp
image/webp · 8.32 KB
-
d435db6662febfcf.webp
image/webp · 10 KB
-
f0a5d3e1e61804ba.webp
image/webp · 11.6 KB