Vip Pass Upgrade 5
Turns a free event pass into a paid supporter upgrade: a bento of what the pass adds overlaps a full-bleed photo, the dominant tile carries the promise, price and one action, and a switch shows what the free pass keeps.
Use it in a prompt
Use offer/vip-pass-upgrade-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/offer/vip-pass-upgrade-5.tsx. - Import it and pass your copy and images (Props tab):
import { VipPassUpgrade5 } from "@/components/funneldna/offer/vip-pass-upgrade-5"
It restyles from the theme tokens on any wrapper (Theme tab). The specimen source is a complete working example.
pieces/offer/vip-pass-upgrade-5/component.tsx 459 lines
// layout: photo-overlap-card
// Turns a free event pass into a paid supporter upgrade: a bento of what the pass adds overlaps a full-bleed photo, the dominant tile carries the promise, price and one action, and a switch shows what the free pass keeps.
'use client'
import * as React from 'react'
import { AlertCircle, Check, HandHeart, Loader2, Lock, ShieldCheck } from 'lucide-react'
import { Spot } from '../fx/fx'
import play from '../fx/spots/play'
import book from '../fx/spots/book'
import community from '../fx/spots/community'
import calendar from '../fx/spots/calendar'
export type SupporterTile = {
/** Tile headline: the benefit the visitor gets. */
title: string
detail?: string
/** Item image (cover, product) on a transparent background. Wins over spot. */
image?: string
imageAlt?: string
/** An fx Spot illustration asset, imported from ../fx/spots/<name>. */
spot?: string
/** True when the free pass keeps this too. */
free?: boolean
/** Footprint in the bento on wide screens. */
size?: 'normal' | 'wide' | 'tall'
}
export type VipPassUpgrade5State = 'default' | 'hover' | 'active' | 'disabled' | 'error'
export type VipPassUpgrade5Copy = {
compareLabel: string
compareIntro: string
compareNote: string
/** Screen-reader status when the comparison is on. '{count}' and '{total}' are replaced. */
compareStatus: string
freeFlag: string
vipFlag: string
impactFlag: string
loadingLabel: string
errorText: string
tilesLabel: string
}
export type VipPassUpgrade5Props = {
/** Supporting labels and templates; placeholders are documented on the copy type. */
copy?: Partial<VipPassUpgrade5Copy>
headline?: React.ReactNode
/** Second headline line, set in the accent colour. */
headlineEmphasis?: React.ReactNode
/** One-sentence lines under the headline. A one-word line is set as the punch. */
punch?: string[]
price?: string
priceNote?: string
/** Supplied breakdown under the price, e.g. 'About $1.57 a day for a month'. Shown only when given. */
priceBreakdown?: string
label?: string
/** Guarantee line under the button. Shown only when supplied. */
guarantee?: string
declineLabel?: string
/** What the pass includes. Tiles marked free stay on the free pass. */
tiles?: SupporterTile[]
impactTitle?: string
/** Where the upgrade money goes. The impact tile shows only when this is supplied. */
impactText?: string
/** Full-bleed photo (scene slot) that the bento overlaps. */
sceneImage?: string
sceneImageAlt?: string
/** Start with the free-pass comparison switched on. */
defaultCompare?: boolean
disabled?: boolean
/** Studio / preview state. */
state?: VipPassUpgrade5State
/** Called on upgrade. While its promise is pending the button shows the loading label; a rejection shows the error. */
onAction?: () => void | Promise<void>
onDecline?: () => void
className?: string
id?: string
}
export function VipPassUpgrade5({
copy,
headline = 'Keep every session.',
headlineEmphasis = 'Support the work behind it.',
punch = DEFAULT_PUNCH,
price = '$47',
priceNote = 'one payment',
priceBreakdown,
label = 'Keep every session',
guarantee,
declineLabel = 'No thanks, I’ll keep my free pass',
tiles = DEFAULT_TILES,
impactTitle = 'Your upgrade goes to work',
impactText,
sceneImage,
sceneImageAlt = '',
defaultCompare = false,
disabled = false,
state = 'default',
onAction,
onDecline,
className,
id,
}: VipPassUpgrade5Props) {
const text = { ...DEFAULT_COPY, ...copy }
const [compare, setCompare] = React.useState(defaultCompare)
const [phase, setPhase] = React.useState<Phase>(state === 'error' ? 'error' : 'idle')
React.useEffect(() => {
setPhase(state === 'error' ? 'error' : 'idle')
}, [state])
const mounted = React.useRef(true)
React.useEffect(() => {
mounted.current = true
return () => {
mounted.current = false
}
}, [])
const uid = React.useId()
const headingId = uid + '-h'
const errorId = uid + '-err'
const noteId = uid + '-note'
const isDisabled = disabled || state === 'disabled'
const force = !isDisabled && (state === 'hover' || state === 'active') ? state : undefined
const loading = phase === 'loading'
const freeCount = tiles.filter((tile) => tile.free).length
const status = compare ? fill(text.compareStatus, { count: String(freeCount), total: String(tiles.length) }) : ''
const upgrade = async () => {
if (isDisabled || loading || !onAction) return
setPhase('loading')
try {
await onAction()
if (mounted.current) setPhase('idle')
} catch {
if (mounted.current) setPhase('error')
}
}
const decline = () => {
if (loading) return
onDecline?.()
}
return (
<section
id={id}
className={['cf-vip-pass-upgrade-5', className].filter(Boolean).join(' ')}
aria-labelledby={headingId}
data-compare={compare ? 'on' : 'off'}
data-phase={phase}
>
<style>{CSS}</style>
<div className='vp5-photo'>
{sceneImage ? <img src={sceneImage} alt={sceneImageAlt} width={1600} height={900} decoding='async' /> : null}
</div>
<div className='vp5-wrap'>
<div className='vp5-bento'>
<article className='vp5-hero'>
<div className='vp5-hero-top'>
<h2 id={headingId} className='vp5-h'>
<span className='vp5-h-line'>{headline}</span>{' '}
{headlineEmphasis ? <span className='vp5-h-line vp5-h-em'>{headlineEmphasis}</span> : null}
</h2>
{punch.length ? (
<div className='vp5-punch'>
{punch.map((line, i) => (
<p key={i + line} className={isOneWord(line) ? 'vp5-punch-word' : undefined}>
{line}
</p>
))}
</div>
) : null}
</div>
<div className='vp5-offer'>
{price ? (
<p className='vp5-price'>
<span className='vp5-price-num'>{price}</span>
{priceNote ? <span className='vp5-price-note'>{priceNote}</span> : null}
</p>
) : null}
{priceBreakdown ? <p className='vp5-perday'>{priceBreakdown}</p> : null}
<button
type='button'
className='vp5-btn'
data-force={force}
disabled={isDisabled}
aria-busy={loading || undefined}
aria-describedby={phase === 'error' ? errorId : undefined}
onClick={upgrade}
>
{loading ? (
<>
<Loader2 className='vp5-spin' size={20} strokeWidth={2.5} aria-hidden='true' />
<span>{text.loadingLabel}</span>
</>
) : (
<span>{label}</span>
)}
</button>
{phase === 'error' ? (
<p id={errorId} className='vp5-error' role='alert'>
<AlertCircle className='vp5-ii' size={16} strokeWidth={2.5} aria-hidden='true' />
{text.errorText}
</p>
) : null}
{guarantee ? (
<p className='vp5-guarantee'>
<ShieldCheck className='vp5-ii vp5-ii-ok' size={16} strokeWidth={2.5} aria-hidden='true' />
{guarantee}
</p>
) : null}
{declineLabel ? (
<button type='button' className='vp5-decline' onClick={decline} disabled={loading}>
{declineLabel}
</button>
) : null}
</div>
</article>
<div className='vp5-side'>
<div className='vp5-toggle'>
<button
type='button'
role='switch'
aria-checked={compare}
aria-describedby={noteId}
className='vp5-switch'
onClick={() => setCompare((value) => !value)}
>
<span className='vp5-track' aria-hidden='true'>
<span className='vp5-knob'>
<Check size={14} strokeWidth={3} />
</span>
</span>
<span className='vp5-switch-label'>{text.compareLabel}</span>
</button>
<p id={noteId} className='vp5-toggle-note'>
{compare ? text.compareNote : text.compareIntro}
</p>
<p className='vp5-sr' aria-live='polite'>
{status}
</p>
</div>
<div className='vp5-tiles' role='group' aria-label={text.tilesLabel}>
{tiles.map((tile, i) => (
<article
key={i + '-' + tile.title}
className='vp5-tile'
data-size={tile.size ?? 'normal'}
data-free={tile.free ? 'true' : undefined}
style={{ animationDelay: delay(i) }}
>
{tile.image ? (
<span className='vp5-media vp5-cover'>
<img src={tile.image} alt={tile.imageAlt ?? ''} loading='lazy' decoding='async' />
</span>
) : tile.spot ? (
<span className='vp5-media vp5-spot' aria-hidden='true'>
<Spot src={tile.spot} size={56} />
</span>
) : null}
<div className='vp5-tile-copy'>
<h3 className='vp5-tile-h'>{tile.title}</h3>
{tile.detail ? <p className='vp5-tile-p'>{tile.detail}</p> : null}
{compare ? (
tile.free ? (
<span className='vp5-flag vp5-flag-free'>
<Check size={16} strokeWidth={3} aria-hidden='true' />
{text.freeFlag}
</span>
) : (
<span className='vp5-flag vp5-flag-vip'>
<Lock size={16} strokeWidth={2.5} aria-hidden='true' />
{text.vipFlag}
</span>
)
) : null}
</div>
</article>
))}
{impactText ? (
<article className='vp5-tile vp5-impact' data-size='wide' style={{ animationDelay: delay(tiles.length) }}>
<span className='vp5-disc' aria-hidden='true'>
<HandHeart size={20} strokeWidth={2.5} />
</span>
<div className='vp5-tile-copy'>
{impactTitle ? <h3 className='vp5-tile-h'>{impactTitle}</h3> : null}
<p className='vp5-tile-p'>{impactText}</p>
{compare ? (
<span className='vp5-flag vp5-flag-vip'>
<Lock size={16} strokeWidth={2.5} aria-hidden='true' />
{text.impactFlag}
</span>
) : null}
</div>
</article>
) : null}
</div>
</div>
</div>
</div>
</section>
)
}
export default VipPassUpgrade5
type Phase = 'idle' | 'loading' | 'error'
const DEFAULT_PUNCH = [
'Your free pass streams the summit live.',
'The Supporter Pass keeps every session and funds the work behind it.',
'Simple.',
]
const DEFAULT_TILES: SupporterTile[] = [
{ title: 'Rewatch every session', detail: 'Every talk on demand, any time.', spot: play, size: 'wide' },
{ title: 'Take the field guide home', detail: 'The summit’s companion guide, ready to print.', spot: book, size: 'tall' },
{ title: 'Ask the hosts live', detail: 'A members’ Q&A call after the event.', spot: community },
{ title: 'Watch it all live', detail: 'Every talk as it streams.', spot: calendar, free: true },
]
const DEFAULT_COPY: VipPassUpgrade5Copy = {
compareLabel: 'Show what my free pass keeps',
compareIntro: 'Everything here comes with the Supporter Pass.',
compareNote: 'Dimmed tiles come with the Supporter Pass only.',
compareStatus: 'Your free pass keeps {count} of {total}. The rest come with the Supporter Pass.',
freeFlag: 'Stays free',
vipFlag: 'Supporter Pass only',
impactFlag: 'Funded by supporters',
loadingLabel: 'Upgrading your pass…',
errorText: 'We couldn’t upgrade your pass. Please try again.',
tilesLabel: 'What the Supporter Pass includes',
}
function fill(template: string, values: Record<string, string>) {
return Object.entries(values).reduce((out, [key, value]) => out.split('{' + key + '}').join(value), template)
}
function isOneWord(line: string) {
return line.trim().split(' ').filter(Boolean).length === 1
}
function delay(i: number) {
return Math.min(0.07 + i * 0.07, 0.28).toFixed(2) + 's'
}
const CSS = `
.cf-vip-pass-upgrade-5{--vp5-gutter:clamp(16px,5vw,48px);--vp5-shadow:var(--shadow,oklch(0.22 0.03 260));position:relative;isolation:isolate;overflow-x:clip;background:var(--surface);color:var(--ink);font-family:var(--font-body);padding-bottom:clamp(64px,8.5vw,120px)}
.cf-vip-pass-upgrade-5 *,.cf-vip-pass-upgrade-5 *::before,.cf-vip-pass-upgrade-5 *::after{box-sizing:border-box}
.cf-vip-pass-upgrade-5 :where(h2,h3,p){margin:0}
.cf-vip-pass-upgrade-5 .vp5-photo{position:relative;height:clamp(280px,34vw,480px);background:var(--band);overflow:hidden}
.cf-vip-pass-upgrade-5 .vp5-photo img{display:block;width:100%;height:100%;object-fit:cover;object-position:center 58%}
.cf-vip-pass-upgrade-5 .vp5-wrap{position:relative;z-index:1;width:100%;max-width:calc(1120px + 2 * var(--vp5-gutter));margin-inline:auto;padding-inline:var(--vp5-gutter)}
.cf-vip-pass-upgrade-5 .vp5-bento{display:grid;grid-template-columns:minmax(0,1.08fr) minmax(0,1fr);gap:16px;align-items:stretch;margin-top:calc(-1 * clamp(150px,15vw,220px))}
.cf-vip-pass-upgrade-5 .vp5-hero{display:flex;flex-direction:column;justify-content:flex-start;align-self:start;gap:40px;min-width:0;padding:clamp(24px,3.4vw,40px);background:color-mix(in oklch,var(--accent) 8%,var(--card));border:1px solid color-mix(in oklch,var(--accent) 28%,var(--card));border-radius:var(--card-radius,var(--radius,14px));box-shadow:inset 0 1px 0 oklch(from var(--card) calc(l + 0.04) c h / 0.6),var(--shadow-lg,0 2px 4px oklch(from var(--vp5-shadow) l c h / 0.22),0 12px 24px -8px oklch(from var(--vp5-shadow) l c h / 0.32));animation:vp5-in .45s cubic-bezier(.2,.7,.2,1) backwards}
.cf-vip-pass-upgrade-5 .vp5-h{font-family:var(--font-display);font-weight:var(--display-weight,800);letter-spacing:var(--display-tracking,-0.025em);text-transform:var(--display-case,none);font-size:clamp(2rem,3.6vw,3.25rem);line-height:1.06;color:var(--ink);text-wrap:balance}
.cf-vip-pass-upgrade-5 .vp5-h-line{display:block;text-wrap:balance}
.cf-vip-pass-upgrade-5 .vp5-h-em{color:var(--accent)}
.cf-vip-pass-upgrade-5 .vp5-punch{display:flex;flex-direction:column;gap:8px;margin-top:16px;max-width:52ch}
.cf-vip-pass-upgrade-5 .vp5-punch p{font-size:clamp(1.125rem,1.5vw,1.375rem);font-weight:500;line-height:1.4;color:var(--ink);text-wrap:pretty}
.cf-vip-pass-upgrade-5 .vp5-punch .vp5-punch-word{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}
.cf-vip-pass-upgrade-5 .vp5-offer{display:flex;flex-direction:column;align-items:stretch;width:100%}
.cf-vip-pass-upgrade-5 .vp5-price{display:flex;align-items:baseline;flex-wrap:wrap;gap:12px 12px}
.cf-vip-pass-upgrade-5 .vp5-price-num{font-family:var(--font-display);font-weight:var(--display-weight,800);font-size:clamp(2.5rem,4.2vw,3.75rem);line-height:1;letter-spacing:-0.03em;font-variant-numeric:tabular-nums;color:var(--ink)}
.cf-vip-pass-upgrade-5 .vp5-price-note{font-size:.9375rem;font-weight:700;line-height:1.4;color:var(--ink)}
.cf-vip-pass-upgrade-5 .vp5-perday{margin-top:12px;font-size:clamp(1.0625rem,1.25vw,1.125rem);font-weight:600;line-height:1.5;color:var(--ink);text-wrap:pretty}
.cf-vip-pass-upgrade-5 .vp5-btn{--vp5-b:var(--button-bg,var(--cta));--vp5-b2:var(--button-bg-2,var(--cta-2));appearance:none;border:0;cursor:pointer;display:flex;align-items:center;justify-content:center;gap:10px;width:100%;max-width:none;min-height:72px;margin:24px 0 0;padding:0 28px;background:linear-gradient(oklch(from var(--vp5-b) calc(l + 0.04) c h),oklch(from var(--vp5-b2) calc(l - 0.02) c h));color:var(--button-ink,var(--cta-ink));border-radius:var(--button-radius,var(--radius,12px));font-family:var(--button-font,var(--font-display));font-weight:var(--button-weight,800);text-transform:var(--button-case,none);font-size:clamp(1.125rem,1.55vw,1.375rem);line-height:1.15;text-align:center;text-shadow:var(--button-text-shadow,none);box-shadow:var(--button-shadow,inset 0 1px 0 oklch(from var(--vp5-b) calc(l + 0.14) c h / 0.7),inset 0 -3px 0 oklch(from var(--vp5-b) calc(l - 0.16) c h),0 1px 2px oklch(from var(--vp5-shadow) l c h / 0.3),0 8px 16px -6px oklch(from var(--vp5-shadow) l c h / 0.42));transition:transform .16s ease,box-shadow .16s ease,background .16s ease}
.cf-vip-pass-upgrade-5 .vp5-btn:not(:disabled):hover,.cf-vip-pass-upgrade-5 .vp5-btn[data-force='hover']{background:linear-gradient(oklch(from var(--vp5-b) calc(l - 0.01) c h),oklch(from var(--vp5-b2) calc(l - 0.07) c h));transform:translateY(-1px);box-shadow:inset 0 1px 0 oklch(from var(--vp5-b) calc(l + 0.12) c h / 0.7),inset 0 -3px 0 oklch(from var(--vp5-b) calc(l - 0.2) c h),0 1px 2px oklch(from var(--vp5-shadow) l c h / 0.32),0 12px 20px -6px oklch(from var(--vp5-shadow) l c h / 0.5)}
.cf-vip-pass-upgrade-5 .vp5-btn:not(:disabled):active,.cf-vip-pass-upgrade-5 .vp5-btn[data-force='active']{background:linear-gradient(oklch(from var(--vp5-b) calc(l - 0.06) c h),oklch(from var(--vp5-b2) calc(l - 0.1) c h));transform:translateY(1px);box-shadow:inset 0 2px 4px oklch(from var(--vp5-b) calc(l - 0.24) c h / 0.6),inset 0 -2px 0 oklch(from var(--vp5-b) calc(l - 0.18) c h),0 1px 2px oklch(from var(--vp5-shadow) l c h / 0.3)}
.cf-vip-pass-upgrade-5 .vp5-btn:focus-visible{outline:3px solid var(--field-focus,var(--accent));outline-offset:3px}
.cf-vip-pass-upgrade-5 .vp5-btn:disabled{cursor:not-allowed;background:var(--secondary);color:var(--secondary-ink);text-shadow:none;box-shadow:var(--button-2-shadow,var(--shadow-sm,0 1px 2px oklch(from var(--vp5-shadow) l c h / 0.2)));transform:none}
.cf-vip-pass-upgrade-5 .vp5-btn[aria-busy='true']{cursor:progress}
.cf-vip-pass-upgrade-5 .vp5-spin{flex:none;animation:vp5-spin .8s linear infinite}
.cf-vip-pass-upgrade-5 .vp5-ii{display:inline-block;vertical-align:-0.15em;margin-inline-end:.4em}
.cf-vip-pass-upgrade-5 .vp5-ii-ok{color:var(--success)}
.cf-vip-pass-upgrade-5 .vp5-error{margin-top:12px;width:100%;padding:10px 14px;border-radius:10px;background:var(--danger-soft);color:var(--danger);font-size:.9375rem;font-weight:600;line-height:1.4;text-wrap:pretty}
.cf-vip-pass-upgrade-5 .vp5-guarantee{margin-top:16px;font-size:.9375rem;font-weight:600;line-height:1.4;color:var(--ink);text-wrap:pretty}
.cf-vip-pass-upgrade-5 .vp5-decline{appearance:none;background:none;border:0;cursor:pointer;align-self:flex-start;margin-top:8px;min-height:44px;padding:10px 0;font-family:var(--font-body);font-size:.9375rem;font-weight:500;line-height:1.4;text-align:left;color:color-mix(in oklch,var(--muted) 60%,var(--ink));text-decoration:underline;text-decoration-color:oklch(from var(--muted) l c h / 0.5);text-underline-offset:.18em;border-radius:6px;transition:color .16s ease}
.cf-vip-pass-upgrade-5 .vp5-decline:hover{color:var(--ink);text-decoration-color:currentColor}
.cf-vip-pass-upgrade-5 .vp5-decline:focus-visible{outline:3px solid var(--field-focus,var(--accent));outline-offset:2px}
.cf-vip-pass-upgrade-5 .vp5-decline:disabled{cursor:not-allowed}
.cf-vip-pass-upgrade-5 .vp5-side{display:flex;flex-direction:column;gap:16px;min-width:0}
.cf-vip-pass-upgrade-5 .vp5-toggle{display:flex;flex-direction:column;gap:8px;padding:16px 20px;background:var(--card);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(--shadow-sm,0 1px 2px oklch(from var(--vp5-shadow) l c h / 0.2));animation:vp5-in .45s cubic-bezier(.2,.7,.2,1) .07s backwards}
.cf-vip-pass-upgrade-5 .vp5-switch{appearance:none;border:0;background:transparent;cursor:pointer;display:inline-flex;align-items:center;gap:12px;min-height:44px;padding:4px 4px 4px 0;align-self:flex-start;border-radius:10px;color:var(--ink);font-family:var(--font-body);font-size:clamp(1.0625rem,1.25vw,1.125rem);font-weight:700;line-height:1.25;text-align:left}
.cf-vip-pass-upgrade-5 .vp5-switch:focus-visible{outline:3px solid var(--field-focus,var(--accent));outline-offset:4px}
.cf-vip-pass-upgrade-5 .vp5-track{flex:none;position:relative;width:52px;height:30px;border-radius:999px;background:color-mix(in oklch,var(--ink) 45%,var(--card));box-shadow:inset 0 1px 2px oklch(from var(--vp5-shadow) l c h / 0.3);transition:background .16s ease}
.cf-vip-pass-upgrade-5 .vp5-switch:hover .vp5-track{background:color-mix(in oklch,var(--ink) 58%,var(--card))}
.cf-vip-pass-upgrade-5 .vp5-switch[aria-checked='true'] .vp5-track{background:var(--ink)}
.cf-vip-pass-upgrade-5 .vp5-knob{position:absolute;top:3px;left:3px;display:grid;place-items:center;width:24px;height:24px;border-radius:999px;background:var(--card);color:var(--ink);box-shadow:0 1px 2px oklch(from var(--vp5-shadow) l c h / 0.35),0 2px 4px -1px oklch(from var(--vp5-shadow) l c h / 0.3);transition:transform .2s cubic-bezier(.2,.7,.2,1)}
.cf-vip-pass-upgrade-5 .vp5-knob svg{opacity:0;transition:opacity .16s ease}
.cf-vip-pass-upgrade-5 .vp5-switch[aria-checked='true'] .vp5-knob{transform:translateX(22px)}
.cf-vip-pass-upgrade-5 .vp5-switch[aria-checked='true'] .vp5-knob svg{opacity:1}
.cf-vip-pass-upgrade-5 .vp5-toggle-note{font-size:.9375rem;font-weight:500;line-height:1.4;color:var(--muted);text-wrap:pretty}
.cf-vip-pass-upgrade-5 .vp5-sr{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}
.cf-vip-pass-upgrade-5 .vp5-tiles{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));grid-auto-flow:row dense;gap:16px;flex:1}
.cf-vip-pass-upgrade-5 .vp5-tile{position:relative;display:flex;flex-direction:column;gap:12px;min-width:0;padding:clamp(20px,2.4vw,24px);background:var(--card);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(--shadow-sm,0 1px 2px oklch(from var(--vp5-shadow) l c h / 0.2));transition:transform .16s ease,box-shadow .16s ease,background .2s ease,border-color .2s ease;animation:vp5-in .45s cubic-bezier(.2,.7,.2,1) backwards}
.cf-vip-pass-upgrade-5 .vp5-tile:hover{transform:translateY(-2px);border-color:oklch(from var(--ink) l c h / 0.2);box-shadow:var(--shadow-md,0 1px 2px oklch(from var(--vp5-shadow) l c h / 0.22),0 4px 10px -2px oklch(from var(--vp5-shadow) l c h / 0.2))}
.cf-vip-pass-upgrade-5 .vp5-tile[data-size='wide']{grid-column:span 2;flex-direction:row;align-items:flex-start;gap:20px}
.cf-vip-pass-upgrade-5 .vp5-tile[data-size='tall']{grid-row:span 2}
.cf-vip-pass-upgrade-5 .vp5-tile[data-size='tall'] .vp5-media{align-self:center}
.cf-vip-pass-upgrade-5 .vp5-media{flex:none;display:block;transition:filter .2s ease,opacity .2s ease}
.cf-vip-pass-upgrade-5 .vp5-spot{width:56px;height:56px}
.cf-vip-pass-upgrade-5 .vp5-cover{padding-block:4px}
.cf-vip-pass-upgrade-5 .vp5-cover img{display:block;width:auto;max-width:100%;height:clamp(150px,16vw,210px);object-fit:contain;filter:drop-shadow(0 2px 3px oklch(from var(--vp5-shadow) l c h / 0.3)) drop-shadow(0 12px 14px oklch(from var(--vp5-shadow) l c h / 0.22))}
.cf-vip-pass-upgrade-5 .vp5-disc{flex:none;display:grid;place-items:center;width:40px;height:40px;border-radius:999px;background:var(--secondary);color:var(--secondary-ink)}
.cf-vip-pass-upgrade-5 .vp5-tile-copy{display:flex;flex-direction:column;gap:8px;flex:1;min-width:0}
.cf-vip-pass-upgrade-5 .vp5-tile-h{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;color:var(--ink);text-wrap:balance;transition:color .2s ease}
.cf-vip-pass-upgrade-5 .vp5-tile-p{font-size:clamp(1.0625rem,1.25vw,1.125rem);font-weight:400;line-height:1.5;color:var(--muted);text-wrap:pretty}
.cf-vip-pass-upgrade-5 .vp5-flag{align-self:flex-start;margin-top:auto;display:inline-flex;align-items:center;gap:6px;min-height:30px;padding:4px 12px;border-radius:999px;font-size:.875rem;font-weight:800;line-height:1.2;white-space:nowrap;animation:vp5-pop .3s ease backwards}
.cf-vip-pass-upgrade-5 .vp5-flag svg{flex:none}
.cf-vip-pass-upgrade-5 .vp5-flag-free{background:var(--success);color:var(--card)}
.cf-vip-pass-upgrade-5 .vp5-flag-vip{background:var(--secondary);color:var(--secondary-ink)}
.cf-vip-pass-upgrade-5[data-compare='on'] .vp5-tile:not([data-free]){background:color-mix(in oklch,var(--ink) 3%,var(--surface));border-color:oklch(from var(--ink) l c h / 0.08);box-shadow:none;transform:none}
.cf-vip-pass-upgrade-5[data-compare='on'] .vp5-tile:not([data-free]) .vp5-tile-h{color:var(--muted)}
.cf-vip-pass-upgrade-5[data-compare='on'] .vp5-tile:not([data-free]) .vp5-media{filter:grayscale(1);opacity:.45}
.cf-vip-pass-upgrade-5[data-compare='on'] .vp5-tile[data-free]{border-color:color-mix(in oklch,var(--success) 55%,var(--card));box-shadow:var(--shadow-md,0 1px 2px oklch(from var(--vp5-shadow) l c h / 0.22),0 4px 10px -2px oklch(from var(--vp5-shadow) l c h / 0.2))}
@keyframes vp5-in{from{opacity:.82;transform:translateY(8px)}to{opacity:1;transform:none}}
@keyframes vp5-pop{from{transform:scale(.9)}to{transform:scale(1)}}
@keyframes vp5-spin{to{transform:rotate(360deg)}}
@media (min-width:961px){
.cf-vip-pass-upgrade-5 .vp5-hero{position:sticky;top:24px}
}
@media (max-width:960px){
.cf-vip-pass-upgrade-5 .vp5-bento{grid-template-columns:minmax(0,1fr);margin-top:calc(-1 * clamp(110px,18vw,160px))}
}
@media (max-width:640px){
.cf-vip-pass-upgrade-5 .vp5-photo{height:240px}
.cf-vip-pass-upgrade-5 .vp5-bento{margin-top:-104px}
.cf-vip-pass-upgrade-5 .vp5-hero{gap:24px}
.cf-vip-pass-upgrade-5 .vp5-btn{max-width:none}
.cf-vip-pass-upgrade-5 .vp5-toggle{padding:16px}
.cf-vip-pass-upgrade-5 .vp5-tiles{grid-template-columns:minmax(0,1fr)}
.cf-vip-pass-upgrade-5 .vp5-tile[data-size]{grid-column:auto;grid-row:auto;flex-direction:row;align-items:flex-start;gap:16px}
.cf-vip-pass-upgrade-5 .vp5-tile[data-size='tall'] .vp5-media{align-self:flex-start}
.cf-vip-pass-upgrade-5 .vp5-spot{width:56px;height:56px}
.cf-vip-pass-upgrade-5 .vp5-cover img{height:112px}
}
@media (prefers-reduced-motion:reduce){
.cf-vip-pass-upgrade-5 .vp5-hero,.cf-vip-pass-upgrade-5 .vp5-toggle,.cf-vip-pass-upgrade-5 .vp5-tile,.cf-vip-pass-upgrade-5 .vp5-flag,.cf-vip-pass-upgrade-5 .vp5-spin{animation:none}
.cf-vip-pass-upgrade-5 .vp5-tile,.cf-vip-pass-upgrade-5 .vp5-btn,.cf-vip-pass-upgrade-5 .vp5-track,.cf-vip-pass-upgrade-5 .vp5-knob,.cf-vip-pass-upgrade-5 .vp5-knob svg,.cf-vip-pass-upgrade-5 .vp5-media,.cf-vip-pass-upgrade-5 .vp5-tile-h,.cf-vip-pass-upgrade-5 .vp5-decline{transition:none}
.cf-vip-pass-upgrade-5 .vp5-tile:hover,.cf-vip-pass-upgrade-5 .vp5-btn:not(:disabled):hover,.cf-vip-pass-upgrade-5 .vp5-btn:not(:disabled):active,.cf-vip-pass-upgrade-5 .vp5-btn[data-force='hover'],.cf-vip-pass-upgrade-5 .vp5-btn[data-force='active']{transform:none}
}
`
pieces/offer/vip-pass-upgrade-5/specimen.tsx 65 lines
import __studioImage2d6f43d0 from "../assets/f98636d61d2d6aa6.webp";
import __studioImagec52aac72 from "../assets/1ad5184a1db8b06d.webp";
import * as React from 'react'
import { VipPassUpgrade5, type VipPassUpgrade5State } from '../vip-pass-upgrade-5'
import defaults from '../../studio-defaults.json'
import { slot } from '../../slots'
import play from '../../fx/spots/play'
import community from '../../fx/spots/community'
import calendar from '../../fx/spots/calendar'
export const states = ['default', 'hover', 'active', 'disabled', 'error']
export default function VipPassUpgrade5Specimen({ state = 'default' }: { state?: VipPassUpgrade5State }) {
const sample = defaults.sample
return (
<VipPassUpgrade5
state={state}
sceneImage={slot('scene', __studioImage2d6f43d0)}
sceneImageAlt='A clear river winding through a forested valley in morning light'
headline='Keep every session.'
headlineEmphasis='Help clean the rivers.'
punch={[
'Your free pass streams the Clean Rivers Virtual Summit live.',
'The Supporter Pass keeps every session and funds the crews testing the water.',
'Simple.',
]}
price={sample.price}
priceNote='Supporter Pass · one payment'
priceBreakdown='About $1.57 a day for a month'
label='Keep every session'
guarantee={sample.guarantee}
declineLabel='No thanks, I’ll keep my free pass'
tiles={[
{
title: 'Rewatch every session',
detail: 'All three summit days on demand. Any talk, any time.',
spot: play,
size: 'wide',
},
{
title: 'Take the River Field Guide home',
detail: 'A printable PDF for testing, logging and reporting what you find.',
image: slot('item-2', __studioImagec52aac72),
imageAlt: 'The River Field Guide cover',
size: 'tall',
},
{
title: 'Ask the hosts live',
detail: 'A members’ Q&A call after the summit.',
spot: community,
},
{
title: 'Watch it all live',
detail: 'Every talk as it streams, all three days.',
spot: calendar,
free: true,
},
]}
impactTitle='Your $47 puts test kits on the river'
impactText='Supporter Pass funds buy water-testing kits for volunteer river crews.'
onAction={() => new Promise<void>((resolve) => setTimeout(resolve, 900))}
onDecline={() => {}}
/>
)
}
| Name | Type | Details |
|---|---|---|
copy OptionalVipPassUpgrade5 |
Partial<VipPassUpgrade5Copy> |
|
headline OptionalVipPassUpgrade5 |
React.ReactNode |
Default 'Keep every session.'
|
headlineEmphasis OptionalVipPassUpgrade5 |
React.ReactNode |
Default 'Support the work behind it.'
|
punch OptionalVipPassUpgrade5 |
string[] |
Default DEFAULT_PUNCH
|
price OptionalVipPassUpgrade5 |
string |
Default '$47'
|
priceNote OptionalVipPassUpgrade5 |
string |
Default 'one payment'
|
priceBreakdown OptionalVipPassUpgrade5 |
string |
|
label OptionalVipPassUpgrade5 |
string |
Default 'Keep every session'
|
guarantee OptionalVipPassUpgrade5 |
string |
|
declineLabel OptionalVipPassUpgrade5 |
string |
Default 'No thanks, I’ll keep my free pass'
|
tiles OptionalVipPassUpgrade5 |
SupporterTile[] |
Default DEFAULT_TILES
|
impactTitle OptionalVipPassUpgrade5 |
string |
Default 'Your upgrade goes to work'
|
impactText OptionalVipPassUpgrade5 |
string |
|
sceneImage OptionalVipPassUpgrade5 |
string |
|
sceneImageAlt OptionalVipPassUpgrade5 |
string |
Default ''
|
defaultCompare OptionalVipPassUpgrade5 |
boolean |
Default false
|
disabled OptionalVipPassUpgrade5 |
boolean |
Default false
|
state OptionalVipPassUpgrade5 |
VipPassUpgrade5State |
Default 'default'
|
onAction OptionalVipPassUpgrade5 |
() => void | Promise<void> |
|
onDecline OptionalVipPassUpgrade5 |
() => void |
|
className OptionalVipPassUpgrade5 |
string |
|
id OptionalVipPassUpgrade5 |
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-shadow- Secondary button.
--card-border--card-radius- Cards and panels: radius, border and shadow.
--display-case--display-tracking--display-weight- Headlines: weight, letter case and tracking.
--field-focus- Form inputs: background, ink, border, radius and focus colour.
Image slots
Filled from the brand’s images; the specimen ships its own defaults.
item-2- One image per offer item (item-1, item-2…), shown in stacks and lists.
scene- A wide atmosphere photo behind or beside the copy.
-
1ad5184a1db8b06d.webp
image/webp · 63 KB
-
321240b3188e2da4.webp
image/webp · 18.7 KB
-
5602e47ebdb81810.webp
image/webp · 35.6 KB
-
839cc020060f63a3.webp
image/webp · 9.49 KB
-
b77916eca54aa689.webp
image/webp · 8.32 KB
-
bc3d360c88eeac0e.webp
image/webp · 23.9 KB
-
d435db6662febfcf.webp
image/webp · 10 KB
-
f0a5d3e1e61804ba.webp
image/webp · 11.6 KB
-
f98636d61d2d6aa6.webp
image/webp · 220 KB