Webinar Session Picker 5
The on-air registration stage for a live demo. The next supplied session is set huge with a live countdown, later times sit as rows beneath it, and one card takes name, work email and the register click. When a session starts it drops away and the next one is promoted, computed from the supplied times only.
Use it in a prompt
Use forms/webinar-session-picker-5 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/forms/webinar-session-picker-5.tsx. - Import it and pass your copy and images (Props tab):
import { WebinarSessionPicker5 } from "@/components/funneldna/forms/webinar-session-picker-5"
It restyles from the theme tokens on any wrapper (Theme tab). The specimen source is a complete working example.
pieces/forms/webinar-session-picker-5/component.tsx 769 lines
// layout: number-rail
// The on-air registration stage for a live demo. The next supplied session is set huge with a live countdown, later times sit as rows beneath it, and one card takes name, work email and the register click. When a session starts it drops away and the next one is promoted, computed from the supplied times only.
import * as React from 'react'
import { AlertCircle, CalendarCheck, Check, Globe, Loader2, Lock } from 'lucide-react'
import { Backdrop, FX_HOST } from '../fx/fx'
import stage from '../fx/backdrops/stage'
/** States this piece renders. Hover and active are forced onto the first later-session row and the register button for review. */
export type WebinarSessionPicker5State = 'default' | 'hover' | 'active' | 'disabled' | 'error'
export type SessionPickerField = {
name: string
label: string
type?: string
autoComplete?: string
/** Example answer shown in the field. A sensible one is used when omitted. */
placeholder?: string
}
/** A session: ISO string, epoch ms, Date, or a record. A record without startsAt shows its title and no countdown. */
export type SessionInput = string | number | Date | { startsAt?: string | number | Date | null; title?: string }
/** Every generated word. Templates take named placeholders in braces; values are inserted as text. */
export type WebinarSessionPicker5Copy = typeof DEFAULT_COPY
export type WebinarSessionPicker5Props = {
/** Generated words and templates. Placeholders: {zone}, {date}, {time}, {day}, {when}, {rel}, {days}, {minutes}, {label}, {old}, {next}, {n}. */
copy?: Partial<WebinarSessionPicker5Copy>
/** Upcoming live sessions. Past times drop away by themselves; the soonest is featured with the countdown. */
sessions?: SessionInput[]
/** How many upcoming sessions to show in total (the featured one plus the rows). */
maxSessions?: number
headline?: string
/** Phrase inside the headline that gets the marker stroke. */
highlight?: string
lead?: string
/** Background photo behind the stage (an imported fx backdrop). A page's scene image replaces it. null removes it. */
backdrop?: string | null
/** presenter-cutout slot: the host on a transparent background, standing beside the countdown. */
presenterImage?: string
presenterImageAlt?: string
presenterName?: string
presenterRole?: string
/** Form fields. Each gets a label, an example placeholder and required validation. */
fields?: SessionPickerField[]
/** Register button label: name the outcome. */
label?: string
/** One reassurance line beside the button. Empty hides it. */
reassurance?: string
/** P.S. under the action restating the main benefit. Empty hides it. */
ps?: string
/** Alert shown in the error state or when onSubmit rejects. */
errorMessage?: string
/** Shown when no upcoming session remains. */
emptyMessage?: string
/** Optional BCP 47 locale. Defaults to the visitor's browser. */
locale?: string
/** Optional IANA zone override. Defaults to the visitor's own zone, detected locally. */
timeZone?: string
state?: WebinarSessionPicker5State
/** Called with the chosen session, the visitor's zone and the field values. A returned promise shows the loading label; a rejection shows errorMessage. */
onSubmit?: (data: { session: string; startsAt: string | null; timeZone: string; values: Record<string, string> }) => void | Promise<void>
className?: string
}
const NO_SESSIONS: SessionInput[] = []
export function WebinarSessionPicker5({
copy: copyOverrides,
sessions = NO_SESSIONS,
maxSessions = 4,
headline = 'Watch the product do the work, live',
highlight = 'do the work',
lead = 'Pick a live demo session, add your name and work email, and we’ll save your seat.',
backdrop = stage,
presenterImage,
presenterImageAlt = '',
presenterName = '',
presenterRole = '',
fields = DEFAULT_FIELDS,
label = 'Show me the live demo',
reassurance = 'Free live demo · Join from your browser',
ps = 'Can’t make the next one? Every session is the same live demo, so pick the time that fits your day.',
errorMessage = 'We couldn’t complete your registration. Please try again.',
emptyMessage = 'New live sessions are on the way. Please check back soon.',
locale,
timeZone,
state = 'default',
onSubmit,
className,
}: WebinarSessionPicker5Props) {
const copy = React.useMemo(() => ({ ...DEFAULT_COPY, ...copyOverrides }), [copyOverrides])
const uid = React.useId().replace(/[^a-zA-Z0-9_-]/g, '')
const [now, setNow] = React.useState<number | null>(null)
const [zone, setZone] = React.useState('')
const [picked, setPicked] = React.useState<string | null>(null)
const [values, setValues] = React.useState<Record<string, string>>({})
const [errors, setErrors] = React.useState<Record<string, string>>({})
const [status, setStatus] = React.useState<'idle' | 'loading' | 'error'>('idle')
const [leaving, setLeaving] = React.useState<Slot | null>(null)
const [announce, setAnnounce] = React.useState('')
const alive = React.useRef(true)
const leaveTimer = React.useRef<number | undefined>(undefined)
const lastLive = React.useRef<Slot | null>(null)
React.useEffect(() => {
alive.current = true
return () => {
alive.current = false
window.clearTimeout(leaveTimer.current)
}
}, [])
React.useEffect(() => {
setZone(detectZone(timeZone))
setNow(Date.now())
const timer = window.setInterval(() => setNow(Date.now()), 1000)
return () => window.clearInterval(timer)
}, [timeZone])
const loc = React.useMemo(() => okLocale(locale), [locale])
const parsed = React.useMemo(() => parseSessions(sessions), [sessions])
const fmt = React.useMemo(() => (zone ? makeFormatters(loc, zone) : null), [loc, zone])
const ready = now != null && fmt != null
const slots = React.useMemo(
() => (now != null && fmt ? upcoming(parsed, now, maxSessions).map((p) => describe(p, now, fmt, copy)) : []),
[parsed, now, maxSessions, fmt, copy],
)
const live = slots[0] ?? null
const later = slots.slice(1)
const chosen = slots.find((s) => s.id === picked) ?? live
const liveId = live ? live.id : ''
// Signature: when the featured session's time passes, it drops away and the next one is promoted.
React.useEffect(() => {
const prev = lastLive.current
lastLive.current = live
if (!prev || prev.id === liveId || prev.at == null || now == null || prev.at > now) return
setLeaving(prev)
setAnnounce(fill(copy.passed, { old: prev.when, next: live ? live.when : copy.none }))
window.clearTimeout(leaveTimer.current)
leaveTimer.current = window.setTimeout(() => {
if (alive.current) setLeaving(null)
}, 700)
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [liveId])
const off = state === 'disabled'
const loading = status === 'loading'
const showError = state === 'error' || status === 'error'
const emailField = fields.find((field) => field.type === 'email')?.name ?? fields[0]?.name
const shown = state === 'error' && emailField ? { ...errors, [emailField]: errors[emailField] || copy.emailError } : errors
const force = state === 'hover' || state === 'active' ? ` is-${state}` : ''
const zoneLong = fmt && live && live.at != null ? zoneName(fmt.zoneLong, live.at) : ''
const formStep = later.length ? 3 : 2
const setValue = (name: string, value: string) => {
setValues((prev) => ({ ...prev, [name]: value }))
if (errors[name]) {
setErrors((prev) => {
const next = { ...prev }
delete next[name]
return next
})
}
}
const submit = async (event: React.FormEvent<HTMLFormElement>) => {
event.preventDefault()
if (off || loading || !chosen) return
const next: Record<string, string> = {}
for (const field of fields) {
const value = (values[field.name] ?? '').trim()
if (!value) next[field.name] = fill(copy.requiredError, { label: field.label.toLowerCase() })
else if (field.type === 'email' && !EMAIL.test(value)) next[field.name] = copy.emailError
}
setErrors(next)
setStatus('idle')
const firstBad = fields.find((field) => next[field.name])
if (firstBad) {
document.getElementById(`${uid}-${firstBad.name}`)?.focus()
return
}
const clean = Object.fromEntries(fields.map((field) => [field.name, (values[field.name] ?? '').trim()]))
const iso = chosen.at != null ? new Date(chosen.at).toISOString() : null
try {
const result: unknown = onSubmit?.({ session: iso ?? chosen.when, startsAt: iso, timeZone: zone, values: clean })
if (!result || typeof (result as PromiseLike<void>).then !== 'function') return
setStatus('loading')
await result
if (alive.current) setStatus('idle')
} catch {
if (alive.current) setStatus('error')
}
}
const renderLive = (slot: Slot, ghost: boolean) => {
const diff = ghost || slot.at == null || now == null ? 0 : slot.at - now
const units = clockUnits(diff, copy)
const on = !ghost && chosen != null && chosen.id === slot.id
const whenId = `${uid}-live-when`
return (
<div key={ghost ? `ghost-${slot.id}` : slot.id} className={`sp5-live${ghost ? ' sp5-live--ghost' : ''}`} aria-hidden={ghost || undefined}>
<p className='sp5-when' id={ghost ? undefined : whenId}>
{slot.at != null ? (
<>
<strong>{slot.day}</strong>, {fill(copy.liveLine, { date: slot.date, time: slot.time, zone: slot.zone })}
</>
) : (
<strong>{slot.when}</strong>
)}
</p>
{slot.at != null ? (
<div className='sp5-clock' role={ghost ? undefined : 'timer'} aria-label={ghost ? undefined : fill(copy.clockLabel, { when: slot.when, rel: slot.rel })}>
<p className='sp5-micro' aria-hidden='true'>{copy.startsIn}</p>
<div className='sp5-digits' data-units={units.length} aria-hidden='true'>
{units.map((unit, i) => (
<React.Fragment key={unit.key}>
{i > 0 ? <span className='sp5-colon'>:</span> : null}
<span className='sp5-unit'>
<span
key={unit.key === 's' && !ghost ? `s${unit.value}` : unit.key}
className={`sp5-val${unit.key === 's' && !ghost ? ' sp5-val--tick' : ''}`}
>
{unit.value}
</span>
<span className='sp5-ulabel'>{unit.label}</span>
</span>
</React.Fragment>
))}
</div>
</div>
) : null}
{ghost ? null : (
<label className={`sp5-pick${on ? ' is-on' : ''}${later.length === 0 ? force : ''}`}>
<input
type='radio'
className='sp5-radio'
name={`${uid}-session`}
value={slot.id}
checked={on}
onChange={() => setPicked(slot.id)}
aria-describedby={whenId}
/>
<span className='sp5-tick' aria-hidden='true'>{on ? <Check size={16} strokeWidth={3} /> : null}</span>
<span>{on ? copy.chosenLive : copy.chooseLive}</span>
</label>
)}
</div>
)
}
return (
<section
className={`cf-webinar-session-picker-5${className ? ` ${className}` : ''}`}
style={FX_HOST}
aria-labelledby={`${uid}-h`}
>
<style>{CSS}</style>
{backdrop ? <Backdrop src={backdrop} treatment='duotone' /> : null}
<div className='sp5-wrap'>
<header className='sp5-head'>
<h2 id={`${uid}-h`} className='sp5-h'>{withMarker(headline, highlight)}</h2>
{lead ? <p className='sp5-lead'>{lead}</p> : null}
</header>
<form className='sp5-form' noValidate onSubmit={submit}>
<fieldset className='sp5-fs' disabled={off}>
<div role='radiogroup' aria-label={copy.groupLabel}>
<div className='sp5-step' data-live={live ? '' : undefined} style={{ '--sp5-d': '.07s' } as React.CSSProperties}>
<span className='sp5-num' aria-hidden='true'>1</span>
<div className='sp5-sh'>
<h3 className='sp5-h3'>
<span className='sp5-sr'>{fill(copy.stepLabel, { n: 1 })} </span>
{copy.liveTitle}
</h3>
{zoneLong ? (
<p className='sp5-note'>
<Globe className='sp5-ico' size={16} strokeWidth={2.5} aria-hidden='true' />
{fill(copy.zoneNote, { zone: zoneLong })}
</p>
) : null}
</div>
<div className='sp5-body'>
{!ready ? (
<p className='sp5-wait'>{copy.findingTimes}</p>
) : !live ? (
<p className='sp5-empty'>{emptyMessage}</p>
) : (
<div className='sp5-stage' data-host={presenterImage ? '' : undefined}>
<div className='sp5-stack'>
{renderLive(live, false)}
{leaving ? renderLive(leaving, true) : null}
</div>
{presenterImage ? (
<figure className='sp5-host'>
<img src={presenterImage} alt={presenterImageAlt} width={560} height={560} decoding='async' />
{presenterName || presenterRole ? (
<figcaption>
{presenterName ? <strong>{presenterName}</strong> : null}
{presenterRole ? <span>{presenterRole}</span> : null}
</figcaption>
) : null}
</figure>
) : null}
</div>
)}
</div>
</div>
{later.length ? (
<div className='sp5-step' style={{ '--sp5-d': '.14s' } as React.CSSProperties}>
<span className='sp5-num' aria-hidden='true'>2</span>
<div className='sp5-sh'>
<h3 className='sp5-h3'>
<span className='sp5-sr'>{fill(copy.stepLabel, { n: 2 })} </span>
{copy.laterTitle}
</h3>
{copy.laterNote ? <p className='sp5-note'>{copy.laterNote}</p> : null}
</div>
<div className='sp5-body'>
<div className='sp5-rows'>
{later.map((slot, i) => {
const on = chosen != null && chosen.id === slot.id
return (
<label key={slot.id} className={`sp5-row${on ? ' is-on' : ''}${i === 0 ? force : ''}`}>
<input
type='radio'
className='sp5-radio'
name={`${uid}-session`}
value={slot.id}
checked={on}
onChange={() => setPicked(slot.id)}
/>
<span className='sp5-tick' aria-hidden='true'>{on ? <Check size={16} strokeWidth={3} /> : null}</span>
<span className='sp5-row-main'>
{slot.at != null ? (
<>
<span className='sp5-row-day'>{slot.day}, {slot.date}</span>
<span className='sp5-row-time'>{slot.time} {slot.zone}</span>
</>
) : (
<span className='sp5-row-day'>{slot.when}</span>
)}
</span>
{slot.rel ? <span className='sp5-chip'>{slot.rel}</span> : null}
</label>
)
})}
</div>
</div>
</div>
) : null}
</div>
<div className='sp5-step sp5-step--end' style={{ '--sp5-d': '.21s' } as React.CSSProperties}>
<span className='sp5-num' aria-hidden='true'>{formStep}</span>
<div className='sp5-sh'>
<h3 className='sp5-h3'>
<span className='sp5-sr'>{fill(copy.stepLabel, { n: formStep })} </span>
{copy.formTitle}
</h3>
</div>
<div className='sp5-body'>
<div className='sp5-card'>
{chosen ? (
<p className='sp5-summary' aria-live='polite'>
<CalendarCheck className='sp5-ico' size={20} strokeWidth={2.5} aria-hidden='true' />
{fillNode(copy.summary, 'when', <strong>{chosen.when}</strong>)}
</p>
) : null}
<div className='sp5-fields'>
{fields.map((field) => {
const id = `${uid}-${field.name}`
const err = shown[field.name]
const errId = `${id}-err`
return (
<div className='sp5-field' key={field.name}>
<label htmlFor={id}>{field.label}</label>
<input
id={id}
name={field.name}
type={field.type ?? 'text'}
autoComplete={field.autoComplete}
inputMode={field.type === 'email' ? 'email' : undefined}
placeholder={field.placeholder ?? hint(field)}
value={values[field.name] ?? ''}
onChange={(event) => setValue(field.name, event.target.value)}
aria-invalid={err ? true : undefined}
aria-describedby={err ? errId : undefined}
required
/>
{err ? (
<p className='sp5-err' id={errId}>
<AlertCircle className='sp5-ico' size={16} strokeWidth={2.5} aria-hidden='true' />
{err}
</p>
) : null}
</div>
)
})}
</div>
{showError ? (
<p className='sp5-alert' role='alert'>
<AlertCircle className='sp5-ico' size={18} strokeWidth={2.5} aria-hidden='true' />
{errorMessage}
</p>
) : null}
<div className='sp5-actions'>
<button type='submit' className={`sp5-btn${force}`} disabled={off || !chosen} aria-busy={loading || undefined}>
{loading ? (
<>
<Loader2 className='sp5-spin' size={20} strokeWidth={2.5} aria-hidden='true' />
{copy.loading}
</>
) : (
label
)}
</button>
{reassurance ? (
<p className='sp5-assure'>
<Lock className='sp5-ico' size={16} strokeWidth={2.5} aria-hidden='true' />
{reassurance}
</p>
) : null}
</div>
{ps ? (
<p className='sp5-ps'>
<strong>{copy.psLabel}</strong> {ps}
</p>
) : null}
</div>
</div>
</div>
</fieldset>
</form>
<p className='sp5-sr' aria-live='polite'>{announce}</p>
</div>
</section>
)
}
export default WebinarSessionPicker5
type Parsed = { id: string; at: number | null; title: string }
type Slot = { id: string; at: number | null; title: string; day: string; date: string; time: string; zone: string; rel: string; when: string }
type Fmt = {
day: Intl.DateTimeFormat
date: Intl.DateTimeFormat
time: Intl.DateTimeFormat
zone: Intl.DateTimeFormat
zoneLong: Intl.DateTimeFormat
ymd: Intl.DateTimeFormat
}
const DEFAULT_COPY = {
/** Step heading over the featured session. */
liveTitle: 'Catch the next live session',
/** {zone} is the visitor's own time zone, long form. */
zoneNote: 'Times shown in your time zone, {zone}.',
/** Date line after the bold weekday: {date}, {time}, {zone}. */
liveLine: '{date} · {time} {zone}',
/** Sentence form of a session: {day}, {date}, {time}, {zone}. */
whenTemplate: '{day}, {date} at {time} {zone}',
/** Shown for a session record without a start time. */
untimedNote: 'Time to be announced',
startsIn: 'Starts in',
/** Accessible name of the countdown: {when}, {rel}. */
clockLabel: 'Next live session: {when} ({rel})',
days: 'Days',
hours: 'Hrs',
minutes: 'Min',
seconds: 'Sec',
chooseLive: 'Choose this session',
chosenLive: 'This is your session',
laterTitle: 'Or pick the time that fits your day',
/** Optional note under the later-sessions heading; empty hides it. */
laterNote: '',
findingTimes: 'Finding the next sessions in your time zone…',
today: 'Today',
tomorrow: 'Tomorrow',
/** {days} until the session. */
inDays: 'In {days} days',
/** {minutes} until a session less than an hour away. */
soon: 'In {minutes} min',
formTitle: 'Save your seat now',
/** {when} is the chosen session, set in bold. */
summary: 'You’re registering for {when}.',
loading: 'Saving your seat…',
/** {label} is the field label, lower-cased. */
requiredError: 'Please enter your {label}.',
emailError: 'Please enter a valid email address, like you@company.com.',
/** Announced when a session starts: {old}, {next}. */
passed: 'The {old} session has started. Next up: {next}.',
none: 'no session scheduled yet',
/** Screen-reader prefix for each step heading: {n}. */
stepLabel: 'Step {n}:',
groupLabel: 'Choose your live session',
psLabel: 'P.S.',
}
const DEFAULT_FIELDS: SessionPickerField[] = [
{ name: 'name', label: 'Full name', autoComplete: 'name', placeholder: 'Jane Smith' },
{ name: 'email', label: 'Work email', type: 'email', autoComplete: 'email', placeholder: 'jane@company.com' },
]
const EMAIL = /^[^\s@]+@[^\s@]+\.[^\s@]{2,}$/
function fill(template: string, vars: Record<string, string | number>): string {
return template.replace(/\{(\w+)\}/g, (match, key: string) => (key in vars ? String(vars[key]) : match))
}
function fillNode(template: string, key: string, node: React.ReactNode): React.ReactNode {
const parts = template.split(`{${key}}`)
return parts.map((part, i) => (
<React.Fragment key={i}>
{i > 0 ? node : null}
{part}
</React.Fragment>
))
}
function withMarker(text: string, phrase?: string): React.ReactNode {
if (!phrase) return text
const i = text.toLowerCase().indexOf(phrase.toLowerCase())
if (i < 0) return text
return (
<>
{text.slice(0, i)}
<span className='sp5-mark'>{text.slice(i, i + phrase.length)}</span>
{text.slice(i + phrase.length)}
</>
)
}
function hint(field: SessionPickerField): string {
if (field.type === 'email' || /email/i.test(field.name)) return 'you@company.com'
if (field.type === 'tel' || /phone|tel/i.test(field.name)) return '(555) 123-4567'
if (/name/i.test(field.name)) return 'Jane Smith'
return ''
}
function okLocale(locale?: string): string | undefined {
if (!locale) return undefined
try {
return Intl.DateTimeFormat.supportedLocalesOf(locale)[0]
} catch {
return undefined
}
}
function detectZone(zone?: string): string {
if (zone) {
try {
new Intl.DateTimeFormat('en-US', { timeZone: zone })
return zone
} catch {
// fall through to the visitor's zone
}
}
try {
return Intl.DateTimeFormat().resolvedOptions().timeZone || 'UTC'
} catch {
return 'UTC'
}
}
function toTime(value: string | number | Date | null | undefined): number | null {
if (value == null || value === '') return null
const ms = value instanceof Date ? value.getTime() : typeof value === 'number' ? value : Date.parse(value)
return Number.isFinite(ms) ? ms : null
}
function parseSessions(list: SessionInput[]): Parsed[] {
const seen = new Set<string>()
const out: Parsed[] = []
list.forEach((item, i) => {
const record: { startsAt?: string | number | Date | null; title?: string } =
typeof item === 'object' && item !== null && !(item instanceof Date) ? item : { startsAt: item }
const at = toTime(record.startsAt)
const title = (record.title ?? '').trim()
if (at == null && !title) return
const id = at != null ? new Date(at).toISOString() : `session-${i}`
if (seen.has(id)) return
seen.add(id)
out.push({ id, at, title })
})
return out
}
function upcoming(list: Parsed[], now: number, max: number): Parsed[] {
const timed = list.filter((p) => p.at != null && p.at > now).sort((a, b) => (a.at as number) - (b.at as number))
const untimed = list.filter((p) => p.at == null)
return [...timed, ...untimed].slice(0, Math.max(1, Math.floor(max)))
}
function makeFormatters(locale: string | undefined, zone: string): Fmt {
const base = { timeZone: zone }
return {
day: new Intl.DateTimeFormat(locale, { ...base, weekday: 'long' }),
date: new Intl.DateTimeFormat(locale, { ...base, month: 'short', day: 'numeric' }),
time: new Intl.DateTimeFormat(locale, { ...base, hour: 'numeric', minute: '2-digit' }),
zone: new Intl.DateTimeFormat(locale, { ...base, hour: 'numeric', timeZoneName: 'short' }),
zoneLong: new Intl.DateTimeFormat(locale, { ...base, hour: 'numeric', timeZoneName: 'long' }),
ymd: new Intl.DateTimeFormat('en-US', { ...base, year: 'numeric', month: 'numeric', day: 'numeric' }),
}
}
function zoneName(format: Intl.DateTimeFormat, ms: number): string {
return format.formatToParts(ms).find((part) => part.type === 'timeZoneName')?.value ?? ''
}
function dayIndex(fmt: Fmt, ms: number): number {
const parts = fmt.ymd.formatToParts(ms)
const get = (type: string) => Number(parts.find((part) => part.type === type)?.value ?? 0)
return Math.round(Date.UTC(get('year'), get('month') - 1, get('day')) / 86400000)
}
function relative(at: number, now: number, fmt: Fmt, copy: WebinarSessionPicker5Copy): string {
const diff = at - now
if (diff < 3600000) return fill(copy.soon, { minutes: Math.max(1, Math.ceil(diff / 60000)) })
const days = dayIndex(fmt, at) - dayIndex(fmt, now)
if (days <= 0) return copy.today
if (days === 1) return copy.tomorrow
return fill(copy.inDays, { days })
}
function describe(p: Parsed, now: number, fmt: Fmt, copy: WebinarSessionPicker5Copy): Slot {
if (p.at == null) {
return { id: p.id, at: null, title: p.title, day: '', date: '', time: '', zone: '', rel: '', when: p.title || copy.untimedNote }
}
const day = fmt.day.format(p.at)
const date = fmt.date.format(p.at)
const time = fmt.time.format(p.at)
const zone = zoneName(fmt.zone, p.at)
return {
id: p.id,
at: p.at,
title: p.title,
day,
date,
time,
zone,
rel: relative(p.at, now, fmt, copy),
when: fill(copy.whenTemplate, { day, date, time, zone }).trim(),
}
}
function clockUnits(diff: number, copy: WebinarSessionPicker5Copy) {
const total = Math.max(0, Math.floor(diff / 1000))
const pad = (n: number) => String(n).padStart(2, '0')
const days = Math.floor(total / 86400)
const list = [
{ key: 'h', value: pad(Math.floor((total % 86400) / 3600)), label: copy.hours },
{ key: 'm', value: pad(Math.floor((total % 3600) / 60)), label: copy.minutes },
{ key: 's', value: pad(total % 60), label: copy.seconds },
]
if (days > 0) list.unshift({ key: 'd', value: pad(days), label: copy.days })
return list
}
const S = '.cf-webinar-session-picker-5'
const CSS = `
${S}{--sp5-rail:clamp(84px,9vw,128px);--sp5-gap:clamp(20px,3vw,40px);--sp5-numsize:clamp(4.25rem,8vw,7rem);--sp5-soft:color-mix(in oklch,var(--band-ink) 80%,var(--band));--sp5-line:oklch(from var(--band-ink) l c h / 0.16);--sp5-shade:var(--shadow,oklch(0.22 0.03 260));position:relative;overflow:hidden;box-sizing:border-box;padding:clamp(56px,8vw,112px) clamp(16px,5vw,48px) clamp(64px,8.5vw,120px);background:var(--band);color:var(--band-ink);font-family:var(--font-body);font-size:clamp(1.0625rem,1.25vw,1.125rem);line-height:1.5}
${S} *,${S} *::before,${S} *::after{box-sizing:border-box}
${S} :is(h2,h3,p,figure){margin:0}
${S} .sp5-wrap{position:relative;z-index:1;max-width:1120px;margin:0 auto}
${S} .sp5-sr{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}
${S} .sp5-head{max-width:calc(46rem + var(--sp5-rail) + var(--sp5-gap));padding-left:calc(var(--sp5-rail) + var(--sp5-gap));animation:sp5-rise .45s cubic-bezier(.2,.7,.2,1) both}
${S} .sp5-h{font-family:var(--font-display);font-weight:var(--display-weight,800);font-size:clamp(2rem,3.6vw,3.25rem);line-height:1.06;letter-spacing:var(--display-tracking,-0.025em);text-transform:var(--display-case,none);text-wrap:balance;color:var(--band-ink)}
${S} .sp5-mark{background-image:linear-gradient(transparent 20%,oklch(from var(--marker,#fae37c) calc(l * 0.2 + 0.8) c h / 1) 20% 90%,transparent 90%);color:oklch(from var(--marker,#fae37c) 0.24 0.05 h / 1);padding:0 .14em;margin:0 -.06em;border-radius:.06em .22em .1em .18em;-webkit-box-decoration-break:clone;box-decoration-break:clone}
${S} .sp5-lead{margin-top:16px;max-width:60ch;font-size:clamp(1.125rem,1.5vw,1.375rem);line-height:1.4;font-weight:500;color:var(--sp5-soft);text-wrap:pretty}
${S} .sp5-form{margin-top:clamp(40px,5vw,56px)}
${S} .sp5-fs{margin:0;padding:0;border:0;min-width:0}
${S} .sp5-step{position:relative;display:grid;grid-template-columns:var(--sp5-rail) minmax(0,1fr);grid-template-areas:'num head' 'num body';column-gap:var(--sp5-gap);padding-bottom:56px;animation:sp5-rise .45s cubic-bezier(.2,.7,.2,1) both;animation-delay:var(--sp5-d,0s)}
${S} .sp5-step--end{padding-bottom:0}
${S} .sp5-step:not(.sp5-step--end)::after{content:'';position:absolute;left:calc(var(--sp5-rail) / 2 - 1px);top:calc(var(--sp5-numsize) * 0.86 + 14px);bottom:14px;width:2px;border-radius:2px;background:var(--sp5-line)}
${S} .sp5-num{grid-area:num;align-self:start;display:block;text-align:center;font-family:var(--font-display);font-weight:var(--display-weight,800);font-size:var(--sp5-numsize);line-height:.86;letter-spacing:-0.04em;font-variant-numeric:tabular-nums;color:var(--band-ink);transition:color .16s ease}
@supports (-webkit-text-stroke:1px currentColor){${S} .sp5-num{color:transparent;-webkit-text-stroke:2px var(--band-ink)}${S} .sp5-step[data-live] .sp5-num,${S} .sp5-step:focus-within .sp5-num{color:var(--band-ink)}}
${S} .sp5-sh{grid-area:head;min-width:0;padding-top:.35rem}
${S} .sp5-h3{font-family:var(--font-display);font-weight:var(--display-weight,800);font-size:clamp(1.3125rem,1.8vw,1.625rem);line-height:1.15;letter-spacing:-0.01em;text-transform:var(--display-case,none);text-wrap:balance;color:var(--band-ink)}
${S} .sp5-note{margin-top:8px;font-size:.9375rem;line-height:1.4;font-weight:500;color:var(--sp5-soft);text-wrap:pretty}
${S} .sp5-ico{display:inline-block;vertical-align:-0.15em;margin-inline-end:.4em;flex:none}
${S} .sp5-body{grid-area:body;min-width:0;margin-top:20px}
${S} .sp5-wait{font-size:.9375rem;font-weight:500;color:var(--sp5-soft)}
${S} .sp5-empty{padding:clamp(20px,3vw,32px);border-radius:var(--radius,12px);background:color-mix(in oklch,var(--band-ink) 6%,var(--band));border:1px solid var(--sp5-line);font-weight:600;color:var(--band-ink)}
${S} .sp5-stage{--sp5-panel:color-mix(in oklch,var(--band-ink) 6%,var(--band));position:relative;display:grid;grid-template-columns:minmax(0,1fr);gap:clamp(16px,3vw,32px);padding:clamp(20px,3vw,32px);background:var(--sp5-panel);border:1px solid var(--sp5-line);border-radius:var(--card-radius,var(--radius,14px));box-shadow:inset 0 1px 0 oklch(from var(--band-ink) l c h / 0.1),var(--shadow-lg,0 2px 4px oklch(from var(--sp5-shade) l c h / 0.22),0 12px 24px -8px oklch(from var(--sp5-shade) l c h / 0.32))}
${S} .sp5-stage[data-host]{grid-template-columns:minmax(0,1fr) clamp(200px,22vw,280px);align-items:end}
${S} .sp5-stack{display:grid;min-width:0}
${S} .sp5-stack>*{grid-area:1/1}
${S} .sp5-live{container-type:inline-size;min-width:0;animation:sp5-rise .45s cubic-bezier(.2,.7,.2,1) both}
${S} .sp5-live--ghost{z-index:2;pointer-events:none;background:var(--sp5-panel);animation:sp5-drop .6s cubic-bezier(.55,0,.7,.2) forwards}
${S} .sp5-when{font-size:clamp(1.125rem,1.5vw,1.375rem);line-height:1.4;font-weight:500;color:var(--band-ink);text-wrap:pretty}
${S} .sp5-when strong{font-weight:800}
${S} .sp5-clock{margin-top:20px}
${S} .sp5-micro{font-size:.875rem;line-height:1.2;font-weight:800;letter-spacing:.08em;text-transform:uppercase;color:var(--sp5-soft)}
${S} .sp5-digits{display:flex;align-items:flex-start;gap:.06em;margin-top:12px;font-family:var(--font-display);font-weight:var(--display-weight,800);font-size:clamp(2.5rem,11vw,6.25rem);font-size:clamp(2.5rem,14cqi,6.25rem);line-height:.92;letter-spacing:-0.03em;font-variant-numeric:tabular-nums;color:var(--band-ink)}
${S} .sp5-digits[data-units='3']{font-size:clamp(2.75rem,14vw,7.5rem);font-size:clamp(2.75rem,18cqi,7.5rem)}
${S} .sp5-unit{display:flex;flex-direction:column;align-items:center;min-width:0}
${S} .sp5-val{display:block}
${S} .sp5-val--tick{animation:sp5-tick .32s cubic-bezier(.2,.7,.2,1) both}
${S} .sp5-colon{color:var(--sp5-soft);padding-inline:.04em;transform:translateY(-.04em)}
${S} .sp5-ulabel{margin-top:10px;font-family:var(--font-body);font-size:.875rem;line-height:1.2;font-weight:800;letter-spacing:.08em;text-transform:uppercase;white-space:nowrap;color:var(--sp5-soft)}
${S} .sp5-radio{position:absolute;inset:0;width:100%;height:100%;margin:0;opacity:0;cursor:inherit}
${S} .sp5-tick{display:grid;place-items:center;flex:none;width:26px;height:26px;border-radius:999px;border:2px solid color-mix(in oklch,currentColor 45%,transparent)}
${S} .is-on>.sp5-tick{border-color:var(--success);background:var(--success);color:var(--sp5-glyph,#fff)}
${S} .sp5-pick{position:relative;display:inline-flex;align-items:center;gap:12px;min-height:48px;margin-top:24px;padding:8px 20px 8px 11px;border-radius:999px;border:1px solid oklch(from var(--band-ink) l c h / 0.3);background:color-mix(in oklch,var(--band-ink) 6%,var(--band));color:var(--band-ink);font-size:.9375rem;font-weight:700;line-height:1.2;cursor:pointer;transition:background .16s ease,border-color .16s ease,transform .16s ease,box-shadow .16s ease}
${S} .sp5-pick.is-on{background:var(--card);color:var(--ink);border-color:color-mix(in oklch,var(--accent) 45%,var(--card));box-shadow:inset 0 1px 0 oklch(from var(--card) calc(l + 0.04) c h / 0.6),var(--shadow-md,0 1px 2px oklch(from var(--sp5-shade) l c h / 0.22),0 4px 10px -2px oklch(from var(--sp5-shade) l c h / 0.2))}
${S} .sp5-host{min-width:0;align-self:end;text-align:center}
${S} .sp5-host img{display:block;width:100%;height:auto;aspect-ratio:1;object-fit:contain;object-position:center bottom;filter:drop-shadow(0 2px 3px oklch(from var(--sp5-shade) l c h / 0.4)) drop-shadow(0 14px 18px oklch(from var(--sp5-shade) l c h / 0.35))}
${S} .sp5-host figcaption{display:grid;gap:2px;margin-top:12px}
${S} .sp5-host strong{font-size:1.0625rem;font-weight:800;line-height:1.3;color:var(--band-ink)}
${S} .sp5-host span{font-size:.9375rem;font-weight:500;line-height:1.4;color:var(--sp5-soft)}
@media (min-width:1024px){${S} .sp5-host{margin-top:-72px}}
${S} .sp5-rows{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,280px),1fr));gap:12px}
${S} .sp5-row{position:relative;display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:12px;min-height:72px;padding:12px 16px;border-radius:var(--radius,12px);border:1px solid var(--sp5-line);background:color-mix(in oklch,var(--band-ink) 7%,var(--band));color:var(--band-ink);cursor:pointer;transition:background .16s ease,border-color .16s ease,transform .16s ease,box-shadow .16s ease}
${S} .sp5-row.is-on{background:var(--card);color:var(--ink);border-color:color-mix(in oklch,var(--accent) 45%,var(--card));box-shadow:var(--shadow-md,0 1px 2px oklch(from var(--sp5-shade) l c h / 0.22),0 4px 10px -2px oklch(from var(--sp5-shade) l c h / 0.2))}
${S} .sp5-row-main{display:grid;gap:2px;min-width:0}
${S} .sp5-row-day{font-size:1.0625rem;font-weight:700;line-height:1.3;text-wrap:pretty}
${S} .sp5-row-time{font-size:.9375rem;font-weight:500;line-height:1.4;color:var(--sp5-soft)}
${S} .sp5-row.is-on .sp5-row-time{color:var(--muted)}
${S} .sp5-chip{display:inline-flex;align-items:center;min-height:28px;padding:4px 12px;border-radius:999px;background:oklch(from var(--band-ink) l c h / 0.12);font-size:.875rem;font-weight:800;line-height:1.2;white-space:nowrap}
${S} .sp5-row.is-on .sp5-chip{background:color-mix(in oklch,var(--ink) 6%,var(--card))}
${S} .sp5-fs:not(:disabled) :is(.sp5-pick,.sp5-row):not(.is-on):hover,${S} .sp5-fs:not(:disabled) :is(.sp5-pick,.sp5-row).is-hover:not(.is-on){background:color-mix(in oklch,var(--band-ink) 12%,var(--band));border-color:oklch(from var(--band-ink) l c h / 0.4);transform:translateY(-1px)}
${S} .sp5-fs:not(:disabled) :is(.sp5-pick,.sp5-row):active,${S} .sp5-fs:not(:disabled) :is(.sp5-pick,.sp5-row).is-active{transform:translateY(1px) scale(.99)}
${S} :is(.sp5-pick,.sp5-row):has(.sp5-radio:focus-visible){outline:3px solid var(--band-ink);outline-offset:3px}
${S} .sp5-fs:disabled :is(.sp5-pick,.sp5-row){cursor:not-allowed;opacity:.6}
${S} .sp5-card{background:var(--card);color:var(--ink);border:1px solid var(--card-border,oklch(from var(--ink) l c h / 0.12));border-radius:var(--card-radius,var(--radius,14px));box-shadow:var(--card-shadow,var(--shadow-lg,0 2px 4px oklch(from var(--sp5-shade) l c h / 0.22),0 12px 24px -8px oklch(from var(--sp5-shade) l c h / 0.32)));padding:clamp(20px,3vw,32px)}
${S} .sp5-summary{font-size:1.0625rem;line-height:1.45;font-weight:500;color:var(--ink);text-wrap:pretty}
${S} .sp5-summary strong{font-weight:800}
${S} .sp5-summary .sp5-ico{color:var(--accent)}
${S} .sp5-fields{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,260px),1fr));gap:16px 20px;margin-top:20px}
${S} .sp5-field{min-width:0}
${S} .sp5-field label{display:block;margin-bottom:8px;font-size:1rem;font-weight:700;line-height:1.3;color:var(--label-ink,var(--ink))}
${S} .sp5-field input{display:block;width:100%;min-height:56px;padding:0 16px;font-family:var(--font-body);font-size:1.0625rem;font-weight:500;line-height:1.3;color:var(--field-ink);background:var(--field);border:1px solid var(--field-border,color-mix(in oklch,var(--ink) 22%,transparent));border-radius:var(--field-radius,var(--radius,12px));box-shadow:inset 0 1px 2px oklch(from var(--sp5-shade) l c h / 0.08);appearance:none;transition:border-color .16s ease,box-shadow .16s ease}
${S} .sp5-field input::placeholder{color:color-mix(in oklch,var(--field-ink) 65%,var(--field));opacity:1}
${S} .sp5-field input:hover:not(:disabled){border-color:color-mix(in oklch,var(--field-ink) 40%,var(--field))}
${S} .sp5-field input:focus{outline:none;border-color:var(--field-focus,var(--accent));box-shadow:0 0 0 3px oklch(from var(--field-focus,var(--accent)) l c h / 0.35)}
${S} .sp5-field input[aria-invalid='true']{border-color:var(--danger)}
${S} .sp5-field input[aria-invalid='true']:focus{box-shadow:0 0 0 3px oklch(from var(--danger) l c h / 0.3)}
${S} .sp5-field input:disabled{background:color-mix(in oklch,var(--ink) 4%,var(--card));cursor:not-allowed}
${S} .sp5-err{margin-top:8px;font-size:.9375rem;font-weight:600;line-height:1.4;color:var(--danger);text-wrap:pretty}
${S} .sp5-alert{margin-top:20px;padding:12px 16px;border-radius:10px;background:var(--danger-soft);color:var(--danger);font-size:.9375rem;font-weight:600;line-height:1.4;text-wrap:pretty}
${S} .sp5-actions{display:flex;flex-wrap:wrap;align-items:center;gap:12px 20px;margin-top:28px}
${S} .sp5-btn{position:relative;display:inline-flex;align-items:center;justify-content:center;gap:10px;min-height:56px;min-width:min(100%,320px);padding:0 28px;border:0;border-radius:var(--button-radius,var(--radius,12px));background:linear-gradient(oklch(from var(--button-bg,var(--cta)) calc(l + 0.04) c h),oklch(from var(--button-bg-2,var(--cta-2)) calc(l - 0.02) c h));color:var(--button-ink,var(--cta-ink));font-family:var(--button-font,var(--font-display));font-weight:var(--button-weight,800);font-size:clamp(1.125rem,1.55vw,1.375rem);line-height:1.15;text-transform:var(--button-case,none);text-align:center;text-wrap:balance;text-shadow:var(--button-text-shadow,none);box-shadow:var(--button-shadow,inset 0 1px 0 oklch(from var(--button-bg,var(--cta)) calc(l + 0.14) c h / 0.7),inset 0 -3px 0 oklch(from var(--button-bg,var(--cta)) calc(l - 0.16) c h),0 1px 2px oklch(from var(--sp5-shade) l c h / 0.3),0 8px 16px -6px oklch(from var(--sp5-shade) l c h / 0.45));cursor:pointer;transition:transform .16s ease,box-shadow .16s ease,background .16s ease}
${S} .sp5-btn:not(:disabled):hover,${S} .sp5-btn.is-hover:not(:disabled){background:linear-gradient(oklch(from var(--button-bg,var(--cta)) calc(l - 0.01) c h),oklch(from var(--button-bg-2,var(--cta-2)) calc(l - 0.07) c h));transform:translateY(-1px);box-shadow:inset 0 1px 0 oklch(from var(--button-bg,var(--cta)) calc(l + 0.12) c h / 0.7),inset 0 -3px 0 oklch(from var(--button-bg,var(--cta)) calc(l - 0.2) c h),0 1px 2px oklch(from var(--sp5-shade) l c h / 0.32),0 12px 20px -8px oklch(from var(--sp5-shade) l c h / 0.55)}
${S} .sp5-btn:not(:disabled):active,${S} .sp5-btn.is-active:not(:disabled){transform:translateY(1px);box-shadow:inset 0 2px 4px oklch(from var(--button-bg,var(--cta)) calc(l - 0.22) c h / 0.55),inset 0 -2px 0 oklch(from var(--button-bg,var(--cta)) calc(l - 0.16) c h),0 1px 2px oklch(from var(--sp5-shade) l c h / 0.3)}
${S} .sp5-btn:focus-visible{outline:3px solid var(--field-focus,var(--accent));outline-offset:3px}
${S} .sp5-btn:disabled{background:var(--button-2-bg,var(--secondary));color:var(--button-2-ink,var(--secondary-ink));text-shadow:none;box-shadow:var(--button-2-shadow,var(--shadow-sm));cursor:not-allowed}
${S} .sp5-btn[aria-busy='true']{cursor:progress}
${S} .sp5-spin{animation:sp5-spin .8s linear infinite}
${S} .sp5-assure{font-size:.9375rem;font-weight:500;line-height:1.4;color:var(--muted);text-wrap:pretty}
${S} .sp5-ps{margin-top:24px;padding-top:20px;border-top:1px solid oklch(from var(--ink) l c h / 0.1);max-width:none;font-size:1.0625rem;line-height:1.5;color:var(--ink);text-wrap:pretty}
${S} .sp5-ps{max-width:64ch}
${S} .sp5-ps strong{font-weight:800}
@keyframes sp5-rise{from{opacity:.82;transform:translateY(8px)}to{opacity:1;transform:none}}
@keyframes sp5-drop{to{opacity:0;transform:translateY(32px) scale(.98)}}
@keyframes sp5-tick{from{opacity:.35;transform:translateY(-.12em)}to{opacity:1;transform:none}}
@keyframes sp5-spin{to{transform:rotate(360deg)}}
@media (max-width:900px){${S} .sp5-stage[data-host]{grid-template-columns:minmax(0,1fr);align-items:stretch}${S} .sp5-host{display:grid;grid-template-columns:96px minmax(0,1fr);align-items:end;gap:16px;text-align:left}${S} .sp5-host img{width:96px}${S} .sp5-host figcaption{margin:0 0 6px}}
@media (max-width:720px){${S}{--sp5-rail:48px;--sp5-gap:12px;--sp5-numsize:3rem}${S} .sp5-head{padding-left:0}${S} .sp5-step{grid-template-areas:'num head' 'body body';padding-bottom:40px}${S} .sp5-step:not(.sp5-step--end)::after{display:none}${S} .sp5-num{text-align:left;align-self:center}${S} .sp5-sh{align-self:center;padding-top:0}${S} .sp5-body{margin-top:16px}${S} .sp5-pick{display:flex;width:100%}${S} .sp5-actions{flex-direction:column;align-items:stretch;text-align:center}${S} .sp5-btn{width:100%;min-width:0}}
@supports (-webkit-text-stroke:1px currentColor){@media (max-width:720px){${S} .sp5-num{-webkit-text-stroke:1.5px var(--band-ink)}}}
@media (prefers-reduced-motion:reduce){${S} *,${S} *::before,${S} *::after{animation:none !important;transition:none !important}${S} .sp5-live--ghost{display:none}}
`
pieces/forms/webinar-session-picker-5/specimen.tsx 49 lines
import __studioImage0cba2749 from "../assets/ef5566fb16e07d39.webp";
import * as React from 'react'
import defaults from '../../studio-defaults.json'
import { slot } from '../../slots'
import { WebinarSessionPicker5 } from '../webinar-session-picker-5'
import type { WebinarSessionPicker5State } from '../webinar-session-picker-5'
export const states = ['default', 'hover', 'active', 'disabled', 'error']
// A fictional Quillstack live-demo schedule: the next session a few hours out, then the following days.
function demoSessions() {
const now = new Date()
const next = new Date(now)
next.setMinutes(0, 0, 0)
next.setHours(next.getHours() + 3)
const at = (days: number, hours: number, minutes: number) => {
const d = new Date(now)
d.setDate(d.getDate() + days)
d.setHours(hours, minutes, 0, 0)
return d
}
return [next, at(1, 11, 0), at(1, 18, 30), at(3, 14, 0)].map((d) => ({ startsAt: d.toISOString() }))
}
export default function WebinarSessionPicker5Specimen({ state = 'default' }: { state?: WebinarSessionPicker5State }) {
const [sessions] = React.useState(demoSessions)
return (
<WebinarSessionPicker5
state={state}
sessions={sessions}
headline='Watch Quillstack plan a month of content, live'
highlight='a month of content'
lead='In 30 minutes we turn one messy notes doc into a publish-ready content calendar on screen, then answer your questions.'
copy={{ laterNote: 'Same 30-minute demo and live Q&A at every session.' }}
presenterImage={slot(
'presenter-cutout',
__studioImage0cba2749,
)}
presenterImageAlt='Maya Ortiz, Quillstack product lead, presenting the live demo'
presenterName='Maya Ortiz'
presenterRole='Product lead, Quillstack'
label='See Quillstack live'
reassurance='Free live demo · Join from your browser'
ps='Bring one messy notes doc. You’ll leave the demo knowing exactly how Quillstack turns it into a month of posts.'
errorMessage={defaults.sample.registration.error}
/>
)
}
| Name | Type | Details |
|---|---|---|
copy OptionalWebinarSessionPicker5 |
Partial<WebinarSessionPicker5Copy> |
|
sessions OptionalWebinarSessionPicker5 |
SessionInput[] |
Default NO_SESSIONS
|
maxSessions OptionalWebinarSessionPicker5 |
number |
Default 4
|
headline OptionalWebinarSessionPicker5 |
string |
Default 'Watch the product do the work, live'
|
highlight OptionalWebinarSessionPicker5 |
string |
Default 'do the work'
|
lead OptionalWebinarSessionPicker5 |
string |
Default 'Pick a live demo session, add your name and work email, and we’ll save your seat.'
|
backdrop OptionalWebinarSessionPicker5 |
string | null |
Default stage
|
presenterImage OptionalWebinarSessionPicker5 |
string |
|
presenterImageAlt OptionalWebinarSessionPicker5 |
string |
Default ''
|
presenterName OptionalWebinarSessionPicker5 |
string |
Default ''
|
presenterRole OptionalWebinarSessionPicker5 |
string |
Default ''
|
fields OptionalWebinarSessionPicker5 |
SessionPickerField[] |
Default DEFAULT_FIELDS
|
label OptionalWebinarSessionPicker5 |
string |
Default 'Show me the live demo'
|
reassurance OptionalWebinarSessionPicker5 |
string |
Default 'Free live demo · Join from your browser'
|
ps OptionalWebinarSessionPicker5 |
string |
Default 'Can’t make the next one? Every session is the same live demo, so pick the time that fits your day.'
|
errorMessage OptionalWebinarSessionPicker5 |
string |
Default 'We couldn’t complete your registration. Please try again.'
|
emptyMessage OptionalWebinarSessionPicker5 |
string |
Default 'New live sessions are on the way. Please check back soon.'
|
locale OptionalWebinarSessionPicker5 |
string |
|
timeZone OptionalWebinarSessionPicker5 |
string |
|
state OptionalWebinarSessionPicker5 |
WebinarSessionPicker5State |
Default 'default'
|
onSubmit OptionalWebinarSessionPicker5 |
(data: { session: string; startsAt: string | null; timeZone: string; values: Record<string, string> }) => void | Promise<void> |
|
className OptionalWebinarSessionPicker5 |
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--field-border--field-focus--field-ink--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.
presenter-cutout- The presenter on a transparent background.
-
44c4a68a8f1604d6.webp
image/webp · 18.4 KB
-
b77916eca54aa689.webp
image/webp · 8.32 KB
-
d435db6662febfcf.webp
image/webp · 10 KB
-
ef5566fb16e07d39.webp
image/webp · 153 KB
-
f0a5d3e1e61804ba.webp
image/webp · 11.6 KB