Whats Inside 10
Unboxes the kit as a fanned hand of real product cards on one bold accent block. The numbered contents bring each piece to the front, then a plain one-time price line and one first-person action.
Use it in a prompt
Use offer/whats-inside-10 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/whats-inside-10.tsx. - Import it and pass your copy and images (Props tab):
import { WhatsInside10 } from "@/components/funneldna/offer/whats-inside-10"
It restyles from the theme tokens on any wrapper (Theme tab). The specimen source is a complete working example.
pieces/offer/whats-inside-10/component.tsx 506 lines
// layout: card-fan
// Unboxes the kit as a fanned hand of real product cards on one bold accent block. The numbered contents bring each piece to the front, then a plain one-time price line and one first-person action.
'use client'
import * as React from 'react'
import { AlertCircle, Loader2, ShieldCheck } from 'lucide-react'
/** States this piece implements; hover/active force the button look, disabled locks it, error shows the checkout message. */
export type WhatsInside10State = 'default' | 'hover' | 'active' | 'disabled' | 'error'
export type WhatsInside10Item = {
name: string
/** One-line payoff under the name. */
detail?: string
/** Supplied value only, e.g. $49. Shown as a quiet chip when present. */
value?: string
/** item-N slot: the product photo on this item's card. Items without one are listed but get no card. */
image?: string
/** Alt text for the card photo; defaults to the item name. */
imageAlt?: string
}
export type WhatsInside10Copy = {
/** {n} and {total} are replaced with the card position, e.g. 01 / 03. */
counter: string
/** {value} is replaced with the item's value. */
itemValue: string
/** Accessible name of the contents list. */
listLabel: string
/** Accessible name of the card fan. */
fanLabel: string
}
export type WhatsInside10Props = {
/** Generated labels and accessible names; any key left out keeps its default. */
copy?: Partial<WhatsInside10Copy>
headline?: string
/** Phrase inside the headline that gets the marker stroke. */
emphasis?: string | false
/** Sub-headline under the headline, usually the product name. */
productName?: string | false
/** Short paragraph under the product name. */
lead?: string | false
/** The kit contents, in order. Items with an image also get a card in the fan. */
items?: WhatsInside10Item[]
/** Index of the card that starts on top of the fan. */
defaultActive?: number
/** Supplied price. */
price?: string
/** Price line; {price} is replaced with the price. */
priceLine?: string | false
/** Short kicker after the price line. */
priceTag?: string | false
/** Plain terms under the price line. Supplied facts only. */
priceNote?: string | false
/** Button text. */
label?: string
/** Button second line. */
sublabel?: string | false
/** Button text while onAction is pending. */
loadingLabel?: string
/** Plain line under the button. */
secondaryLine?: string | false
/** Turns the secondary line into a quiet link. */
secondaryHref?: string
/** Guarantee line under the button. Supplied facts only. */
guarantee?: string | false
/** Shown when onAction rejects, or in the error state. */
errorMessage?: string
/** Checkout destination, used when there is no onAction. */
href?: string
/** Called when the button is pressed. Nothing is sent by this component. */
onAction?: () => void | Promise<unknown>
disabled?: boolean
state?: WhatsInside10State
id?: string
className?: string
style?: React.CSSProperties
}
type Status = 'idle' | 'loading' | 'error'
export function WhatsInside10(props: WhatsInside10Props) {
const {
copy,
headline = 'Here’s everything inside',
emphasis = 'everything inside',
productName = 'The Funnel Starter Kit',
lead = 'Plan your funnel, write your page copy, and check every step before you launch.',
items = DEFAULT_ITEMS,
defaultActive = 0,
price = '$47',
priceLine = '{price} today.',
priceTag = 'That’s it.',
priceNote = 'One payment · Lifetime access',
label = 'Send Me The Funnel Starter Kit',
sublabel = 'Secure checkout · Instant download',
loadingLabel = 'Opening secure checkout…',
secondaryLine = 'or tap each piece above for a closer look',
secondaryHref,
guarantee = '30-day money-back guarantee',
errorMessage = 'We couldn’t open checkout. Please try again.',
href,
onAction,
disabled = false,
state = 'default',
id,
className,
style,
} = props
const text = { ...DEFAULT_COPY, ...copy }
const uid = React.useId().replace(/:/g, '')
const rootRef = React.useRef<HTMLElement>(null)
const alive = React.useRef(true)
const timer = React.useRef<ReturnType<typeof setTimeout> | null>(null)
const [active, setActive] = React.useState(() => clampIndex(defaultActive, items.length))
const [status, setStatus] = React.useState<Status>(state === 'error' ? 'error' : 'idle')
const [dealt, setDealt] = React.useState(true)
const [dealing, setDealing] = React.useState(false)
React.useEffect(() => {
alive.current = true
return () => {
alive.current = false
if (timer.current) clearTimeout(timer.current)
}
}, [])
React.useEffect(() => {
setStatus(state === 'error' ? 'error' : 'idle')
}, [state])
React.useEffect(() => {
setActive((a) => clampIndex(a, items.length))
}, [items.length])
// One entrance: the hand is dealt out from a neat stack when the section scrolls in.
useIsoLayoutEffect(() => {
const el = rootRef.current
if (!el || typeof window === 'undefined' || typeof IntersectionObserver === 'undefined') return
if (window.matchMedia?.('(prefers-reduced-motion: reduce)').matches) return
setDealt(false)
const io = new IntersectionObserver(
(entries) => {
if (!entries.some((entry) => entry.isIntersecting)) return
io.disconnect()
setDealing(true)
setDealt(true)
timer.current = setTimeout(() => {
if (alive.current) setDealing(false)
}, 1000)
},
{ threshold: 0.2 },
)
io.observe(el)
return () => io.disconnect()
}, [])
const isDisabled = disabled || state === 'disabled'
const loading = status === 'loading'
const force = state === 'hover' || state === 'active' ? state : undefined
const cards = items.map((item, i) => ({ item, i })).filter((c) => Boolean(c.item.image))
const m = cards.length
const k = m > 1 ? Math.min(1, 2 / (m - 1)) : 0
const activeCard = cards.findIndex((c) => c.i === active)
const center = activeCard < 0 ? (m - 1) / 2 : activeCard
const hasVisual = m > 0
const current = items[active]
const headId = `${uid}-h`
const errId = `${uid}-err`
const fanId = `${uid}-fan`
async function handle(e: React.MouseEvent<HTMLElement>) {
if (isDisabled || loading) {
e.preventDefault()
return
}
if (!onAction) return
e.preventDefault()
setStatus('loading')
try {
await onAction()
if (alive.current) setStatus('idle')
} catch {
if (alive.current) setStatus('error')
}
}
const inner = (
<>
<span className='wi10-btn-main'>
{loading ? <Loader2 className='wi10-spin' aria-hidden='true' strokeWidth={2.75} /> : null}
<span>{loading ? loadingLabel : label}</span>
</span>
{sublabel ? <span className='wi10-btn-sub'>{sublabel}</span> : null}
</>
)
const button =
href && !onAction ? (
<a
className='wi10-btn'
href={isDisabled ? undefined : href}
role={isDisabled ? 'link' : undefined}
aria-disabled={isDisabled || undefined}
aria-describedby={status === 'error' ? errId : undefined}
data-disabled={isDisabled ? '' : undefined}
data-force={force}
onClick={handle}
>
{inner}
</a>
) : (
<button
type='button'
className='wi10-btn'
disabled={isDisabled}
aria-busy={loading || undefined}
aria-describedby={status === 'error' ? errId : undefined}
data-force={force}
onClick={handle}
>
{inner}
</button>
)
const classes = [
'cf-whats-inside-10',
hasVisual ? '' : 'is-solo',
dealt ? '' : 'is-stacked',
dealing ? 'is-dealing' : '',
className || '',
]
.filter(Boolean)
.join(' ')
return (
<section ref={rootRef} id={id} className={classes} style={style} aria-labelledby={headId}>
<style>{CSS}</style>
<div className='wi10-wrap'>
<header className='wi10-head'>
<h2 id={headId} className='wi10-h'>
<Headline text={headline} mark={emphasis || ''} />
</h2>
{productName ? <p className='wi10-name'>{productName}</p> : null}
{lead ? <p className='wi10-lead'>{lead}</p> : null}
</header>
{hasVisual ? (
<div className='wi10-visual'>
<span className='wi10-block' aria-hidden='true' />
<div id={fanId} className='wi10-stage' role='group' aria-label={text.fanLabel}>
<div className='wi10-card wi10-sizer' aria-hidden='true'>
<CardFace item={cards[0].item} n={pad(cards[0].i + 1)} decorative />
</div>
{cards.map(({ item, i }, j) => {
const pos = j - (m - 1) / 2
const on = j === activeCard
const z = on ? 40 : 20 - Math.round(Math.abs(j - center))
return (
<div
key={`${item.name}-${i}`}
className='wi10-card wi10-fan'
data-on={on ? '' : undefined}
aria-hidden={on ? undefined : true}
style={{ '--slot': pos, '--abs': Math.abs(pos), '--k': k, '--j': j, zIndex: z } as React.CSSProperties}
onClick={() => setActive(i)}
>
<CardFace item={item} n={pad(i + 1)} />
</div>
)
})}
</div>
<div className='wi10-tally'>
<span className='wi10-count'>{fill(text.counter, { n: pad(active + 1), total: pad(items.length) })}</span>
<span className='wi10-now' aria-live='polite'>
{current ? current.name : ''}
</span>
</div>
</div>
) : null}
<div className='wi10-body'>
<ol className='wi10-list' aria-label={text.listLabel}>
{items.map((item, i) => {
const on = i === active
return (
<li key={`${item.name}-${i}`}>
<button
type='button'
className='wi10-row'
aria-pressed={on}
aria-controls={hasVisual ? fanId : undefined}
onClick={() => setActive(i)}
onFocus={() => setActive(i)}
onMouseEnter={() => setActive(i)}
>
<span className='wi10-num' aria-hidden='true'>
{pad(i + 1)}
</span>
<span className='wi10-row-name'>{item.name}</span>
{item.value ? <span className='wi10-chip'>{fill(text.itemValue, { value: item.value })}</span> : null}
{item.detail ? <span className='wi10-row-detail'>{item.detail}</span> : null}
</button>
</li>
)
})}
</ol>
<div className='wi10-offer'>
{priceLine ? (
<p className='wi10-price'>
<PriceText template={priceLine} price={price} />
{priceTag ? <span className='wi10-tag'>{' '}{priceTag}</span> : null}
</p>
) : null}
{priceNote ? <p className='wi10-note'>{priceNote}</p> : null}
{button}
{secondaryLine ? (
<p className='wi10-alt'>{secondaryHref ? <a href={secondaryHref}>{secondaryLine}</a> : secondaryLine}</p>
) : null}
{status === 'error' ? (
<p id={errId} className='wi10-err' role='alert'>
<AlertCircle aria-hidden='true' strokeWidth={2.5} />
<span>{errorMessage}</span>
</p>
) : null}
{guarantee ? (
<p className='wi10-guar'>
<ShieldCheck aria-hidden='true' strokeWidth={2.25} />
<span>{guarantee}</span>
</p>
) : null}
</div>
</div>
</div>
</section>
)
}
export default WhatsInside10
function CardFace({ item, n, decorative }: { item: WhatsInside10Item; n: string; decorative?: boolean }) {
return (
<>
<span className='wi10-shot'>
<img
src={item.image}
alt={decorative ? '' : item.imageAlt || item.name}
width={720}
height={720}
loading='lazy'
decoding='async'
draggable={false}
/>
</span>
<span className='wi10-cap'>
<span className='wi10-cap-n'>{n}</span>
<span className='wi10-cap-name'>{item.name}</span>
</span>
</>
)
}
function Headline({ text, mark }: { text: string; mark: string }) {
const at = mark ? text.indexOf(mark) : -1
if (at < 0) return <>{text}</>
return (
<>
{text.slice(0, at)}
<span className='wi10-mark'>{mark}</span>
{text.slice(at + mark.length)}
</>
)
}
function PriceText({ template, price }: { template: string; price: string }) {
const parts = template.split('{price}')
return (
<>
{parts.map((part, i) => (
<React.Fragment key={i}>
{i > 0 ? <span className='wi10-fig'>{price}</span> : null}
{part}
</React.Fragment>
))}
</>
)
}
/** Replaces each named {placeholder} in a copy template with its value, as text. */
function fill(template: string, vars: Record<string, string>) {
return Object.keys(vars).reduce((out, key) => out.split(`{${key}}`).join(vars[key]), template)
}
function pad(n: number) {
return n < 10 ? `0${n}` : String(n)
}
function clampIndex(i: number, len: number) {
if (!len) return 0
return Math.min(Math.max(0, Math.round(i) || 0), len - 1)
}
const useIsoLayoutEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect
const DEFAULT_COPY: WhatsInside10Copy = {
counter: '{n} / {total}',
itemValue: '{value} value',
listLabel: 'What’s inside the kit',
fanLabel: 'The kit, piece by piece',
}
const DEFAULT_ITEMS: WhatsInside10Item[] = [
{ name: 'Funnel Planning Guide', detail: 'Map your offer and the pages your funnel needs.' },
{ name: 'Page Copy Workbook', detail: 'Draft your headline, offer, and call to action.' },
{ name: 'Launch Checklist', detail: 'Review the links, forms, and next steps before launch.' },
]
// Theme notes:
// - Marker: documented yellow-marker exception. --marker wins; the fallback is a highlighter yellow whose lightness follows --surface, so ink stays readable on light and dark themes.
// - Accent block: filled with --accent-fill (the brand accent as supplied); text on it reads --wi10-block-ink (--accent-fill-ink, default --card). The host fits --accent to 4.5:1 against --card, and contrast is symmetric, so card-coloured text on the accent block holds 4.5:1 on light and dark themes. The tally carries the same accent fill (bottom of the block) so its text always sits on the accent, never on the page surface.
// - Display-face weights read --display-weight so themes with single-weight display faces (e.g. Anton) are never faux-bolded.
// - Contents rows are selectable option buttons; their corner reads --button-radius so they follow the theme's button shape.
// - Shadows: every fallback is a dark recipe on --shadow (never a light or theme-flipping token).
const CSS = `
.cf-whats-inside-10{--wi10-accent:var(--accent,#2457c5);--wi10-fill:var(--accent-fill,var(--wi10-accent));--wi10-block-ink:var(--accent-fill-ink,var(--card,#ffffff));--wi10-radius:var(--radius,.75rem);--wi10-card-radius:var(--card-radius,var(--wi10-radius));--wi10-marker:var(--marker,oklch(from var(--surface,#ffffff) calc(l * .62 + .26) .13 95));--wi10-shadow:var(--shadow,oklch(.22 .03 260));--wi10-sh-sm:var(--shadow-sm,0 1px 1px oklch(from var(--wi10-shadow) l c h / .18),0 1px 3px oklch(from var(--wi10-shadow) l c h / .14));--wi10-sh-md:var(--shadow-md,0 1px 2px oklch(from var(--wi10-shadow) l c h / .22),0 4px 10px -2px oklch(from var(--wi10-shadow) l c h / .2));--wi10-sh-lg:var(--shadow-lg,0 2px 4px oklch(from var(--wi10-shadow) l c h / .22),0 12px 24px -8px oklch(from var(--wi10-shadow) l c h / .32));position:relative;overflow-x:clip;background:var(--surface,#ffffff);color:var(--ink,#141b2d);font-family:var(--font-body,system-ui,sans-serif);padding:clamp(3.5rem,7vw,6.5rem) clamp(1.25rem,4vw,2.5rem)}
.cf-whats-inside-10 *,.cf-whats-inside-10 *::before,.cf-whats-inside-10 *::after{box-sizing:border-box}
.cf-whats-inside-10 :is(h2,p,ol,li){margin:0;padding:0}
.cf-whats-inside-10 ol{list-style:none}
.cf-whats-inside-10 .wi10-wrap{max-width:76rem;margin:0 auto;display:grid;grid-template-columns:minmax(0,1.05fr) minmax(0,1fr);grid-template-areas:'visual head' 'visual body';grid-template-rows:auto 1fr;column-gap:clamp(2.5rem,5.5vw,5.5rem);row-gap:clamp(1.75rem,3vw,2.5rem);align-items:start}
.cf-whats-inside-10.is-solo .wi10-wrap{grid-template-columns:minmax(0,46rem);grid-template-areas:'head' 'body';grid-template-rows:auto;justify-content:center}
.cf-whats-inside-10 .wi10-head{grid-area:head;min-width:0}
.cf-whats-inside-10 .wi10-h{font-family:var(--font-display,system-ui,sans-serif);font-weight:var(--display-weight,800);text-transform:var(--display-case,none);letter-spacing:var(--display-tracking,-.035em);font-size:clamp(2.25rem,1.5rem + 3.4vw,4.75rem);line-height:1.02;text-wrap:balance;color:var(--ink,#141b2d);margin-bottom:clamp(.85rem,1.6vw,1.4rem)}
.cf-whats-inside-10 .wi10-mark{background-image:linear-gradient(transparent 46%,var(--wi10-marker) 46%,var(--wi10-marker) 93%,transparent 93%);background-repeat:no-repeat;background-size:100% 100%;padding:0 .08em;margin:0 -.04em;border-radius:.1em .24em .14em .2em;-webkit-box-decoration-break:clone;box-decoration-break:clone;transition:background-size .7s cubic-bezier(.3,.7,.2,1) .15s}
.cf-whats-inside-10.is-stacked .wi10-mark{background-size:0% 100%;transition:none}
.cf-whats-inside-10 .wi10-name{font-family:var(--font-display,system-ui,sans-serif);font-weight:var(--display-weight,700);font-size:clamp(1.25rem,1rem + .9vw,1.625rem);line-height:1.2;letter-spacing:-.01em;text-wrap:balance;margin-bottom:.625rem}
.cf-whats-inside-10 .wi10-lead{font-size:clamp(1.0625rem,1rem + .3vw,1.1875rem);line-height:1.55;font-weight:500;color:var(--muted,#4a5568);max-width:36rem;text-wrap:pretty}
.cf-whats-inside-10 .wi10-visual{grid-area:visual;position:sticky;top:1.5rem;min-width:0;align-self:start}
.cf-whats-inside-10 .wi10-block{position:absolute;inset:24% 0 0 0;border-radius:calc(var(--wi10-card-radius) * 1.6);background:var(--wi10-fill);box-shadow:inset 0 1px 0 oklch(from var(--wi10-fill) calc(l + .12) c h / .55),inset 0 -2px 0 oklch(from var(--wi10-fill) calc(l - .08) c h / .6)}
.cf-whats-inside-10 .wi10-stage{--cw:min(50%,17rem);--spread:40%;--tilt:8deg;position:relative;padding:clamp(1.5rem,3vw,2.5rem) 0 0}
.cf-whats-inside-10 .wi10-card{width:var(--cw);display:flex;flex-direction:column;gap:.7rem;padding:.6rem .6rem .9rem;background:var(--card,#ffffff);color:var(--ink,#141b2d);border:1px solid var(--card-border,color-mix(in oklch,var(--ink,#141b2d) 12%,transparent));border-radius:var(--wi10-card-radius);box-shadow:var(--card-shadow,var(--wi10-sh-md))}
.cf-whats-inside-10 .wi10-sizer{position:relative;margin:0 auto;visibility:hidden;pointer-events:none}
.cf-whats-inside-10 .wi10-fan{position:absolute;left:50%;bottom:0;cursor:pointer;transform-origin:50% 100%;transform:translateX(calc(-50% + var(--slot) * var(--k) * var(--spread))) translateY(calc(var(--abs) * var(--k) * 5% + var(--lift,0%))) rotate(calc(var(--slot) * var(--k) * var(--tilt)));transition:transform .5s cubic-bezier(.2,.8,.2,1),box-shadow .3s ease;-webkit-tap-highlight-color:transparent}
.cf-whats-inside-10 .wi10-fan:hover{--lift:-3%}
.cf-whats-inside-10 .wi10-fan[data-on]{cursor:default;transform:translateX(calc(-50% + var(--slot) * var(--k) * var(--spread))) translateY(-7%) rotate(calc(var(--slot) * var(--k) * 1.5deg)) scale(1.04);box-shadow:var(--wi10-sh-lg)}
.cf-whats-inside-10.is-stacked .wi10-fan{transform:translateX(-50%) translateY(3%) rotate(calc(var(--slot) * 2deg))}
.cf-whats-inside-10.is-dealing .wi10-fan{transition-delay:calc(var(--j) * 70ms)}
.cf-whats-inside-10 .wi10-shot{display:block;aspect-ratio:1;border-radius:calc(var(--wi10-card-radius) * .7);overflow:hidden;background:color-mix(in oklch,var(--ink,#141b2d) 4%,var(--card,#ffffff))}
.cf-whats-inside-10 .wi10-shot img{display:block;width:100%;height:100%;object-fit:cover;object-position:center;user-select:none;-webkit-user-drag:none}
.cf-whats-inside-10 .wi10-cap{display:flex;align-items:baseline;gap:.5rem;padding:0 .3rem;min-width:0}
.cf-whats-inside-10 .wi10-cap-n{flex:none;font-family:var(--font-display,system-ui,sans-serif);font-weight:var(--display-weight,800);font-size:.9375rem;color:var(--wi10-accent);font-variant-numeric:tabular-nums}
.cf-whats-inside-10 .wi10-cap-name{min-width:0;font-family:var(--font-display,system-ui,sans-serif);font-weight:var(--display-weight,700);font-size:clamp(.9375rem,.85rem + .3vw,1.0625rem);line-height:1.25;text-wrap:balance}
.cf-whats-inside-10 .wi10-tally{position:relative;display:flex;flex-wrap:wrap;align-items:baseline;justify-content:space-between;gap:.25rem 1rem;padding:clamp(1.5rem,3vw,2rem) clamp(1.25rem,3vw,2rem) clamp(1.25rem,2.5vw,1.75rem);background:var(--wi10-fill);border-radius:0 0 calc(var(--wi10-card-radius) * 1.6) calc(var(--wi10-card-radius) * 1.6);box-shadow:inset 0 -2px 0 oklch(from var(--wi10-fill) calc(l - .08) c h / .6);color:var(--wi10-block-ink);font-family:var(--font-display,system-ui,sans-serif)}
.cf-whats-inside-10 .wi10-count{font-weight:var(--display-weight,800);font-size:clamp(1.5rem,1.2rem + 1vw,2rem);line-height:1;letter-spacing:-.02em;font-variant-numeric:tabular-nums}
.cf-whats-inside-10 .wi10-now{font-weight:var(--display-weight,700);font-size:1.0625rem;line-height:1.3;text-align:right;text-wrap:balance}
.cf-whats-inside-10 .wi10-body{grid-area:body;min-width:0}
.cf-whats-inside-10 .wi10-list{display:grid;gap:.375rem;margin:0 -.75rem}
.cf-whats-inside-10 .wi10-row{appearance:none;width:100%;display:grid;grid-template-columns:auto minmax(0,1fr) auto;grid-template-areas:'num name chip' 'num detail detail';column-gap:1rem;row-gap:.3rem;align-items:baseline;padding:.95rem .75rem;border:0;border-radius:var(--button-radius,var(--wi10-radius));background:transparent;color:inherit;font:inherit;text-align:left;cursor:pointer;transition:background-color .2s ease}
.cf-whats-inside-10 .wi10-row:hover{background:color-mix(in oklch,var(--ink,#141b2d) 4%,var(--surface,#ffffff))}
.cf-whats-inside-10 .wi10-row[aria-pressed='true']{background:color-mix(in oklch,var(--wi10-fill) 10%,var(--surface,#ffffff))}
.cf-whats-inside-10 .wi10-row:focus-visible{outline:3px solid var(--field-focus,var(--wi10-accent));outline-offset:2px}
.cf-whats-inside-10 .wi10-num{grid-area:num;align-self:start;min-width:2.4ch;font-family:var(--font-display,system-ui,sans-serif);font-weight:var(--display-weight,800);font-size:clamp(1.75rem,1.4rem + 1vw,2.25rem);line-height:1;letter-spacing:-.03em;color:var(--wi10-accent);font-variant-numeric:tabular-nums}
.cf-whats-inside-10 .wi10-row-name{grid-area:name;font-family:var(--font-display,system-ui,sans-serif);font-weight:var(--display-weight,700);font-size:clamp(1.125rem,1rem + .45vw,1.375rem);line-height:1.2;text-wrap:balance}
.cf-whats-inside-10 .wi10-chip{grid-area:chip;align-self:center;white-space:nowrap;padding:.3rem .75rem;border-radius:999px;background:color-mix(in oklch,var(--ink,#141b2d) 6%,var(--surface,#ffffff));color:var(--ink,#141b2d);font-size:.875rem;font-weight:700;font-variant-numeric:tabular-nums}
.cf-whats-inside-10 .wi10-row-detail{grid-area:detail;font-size:1rem;line-height:1.5;color:var(--muted,#4a5568);text-wrap:pretty}
.cf-whats-inside-10 .wi10-offer{margin-top:clamp(2rem,3.5vw,2.75rem)}
.cf-whats-inside-10 .wi10-price{font-family:var(--font-display,system-ui,sans-serif);font-weight:var(--display-weight,800);font-size:clamp(1.875rem,1.4rem + 1.8vw,2.625rem);line-height:1.08;letter-spacing:var(--display-tracking,-.03em);text-wrap:balance;margin-bottom:.75rem}
.cf-whats-inside-10 .wi10-fig{font-variant-numeric:tabular-nums}
.cf-whats-inside-10 .wi10-tag{color:var(--muted,#4a5568)}
.cf-whats-inside-10 .wi10-note{font-size:1rem;line-height:1.5;font-weight:500;color:var(--muted,#4a5568)}
.cf-whats-inside-10 .wi10-btn{--wi10-d:0;appearance:none;margin-top:1.375rem;width:100%;max-width:30rem;min-height:4.25rem;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:.2rem;padding:.9rem 1.5rem;border:1px solid oklch(from var(--button-bg,var(--cta,#d63a2f)) calc(l - .12) c h);border-radius:var(--button-radius,var(--wi10-radius));background:linear-gradient(oklch(from var(--button-bg,var(--cta,#d63a2f)) calc(l + .04 - var(--wi10-d)) c h),oklch(from var(--button-bg-2,var(--cta-2,#b8291f)) calc(l - var(--wi10-d)) c h));color:var(--button-ink,var(--cta-ink,#ffffff));text-shadow:var(--button-text-shadow,none);text-decoration:none;text-align:center;cursor:pointer;box-shadow:var(--button-shadow,inset 0 1px 0 oklch(from var(--button-bg,var(--cta,#d63a2f)) calc(l + .14) c h / .55),inset 0 -3px 0 oklch(from var(--button-bg,var(--cta,#d63a2f)) calc(l - .16) c h),var(--wi10-sh-md));transition:transform .15s ease,box-shadow .15s ease;-webkit-tap-highlight-color:transparent}
.cf-whats-inside-10 .wi10-btn:not(:disabled):not([data-disabled]):hover,.cf-whats-inside-10 .wi10-btn[data-force='hover']{--wi10-d:.05;transform:translateY(-1px);box-shadow:var(--button-shadow,inset 0 1px 0 oklch(from var(--button-bg,var(--cta,#d63a2f)) calc(l + .14) c h / .55),inset 0 -3px 0 oklch(from var(--button-bg,var(--cta,#d63a2f)) calc(l - .18) c h),var(--wi10-sh-lg))}
.cf-whats-inside-10 .wi10-btn:not(:disabled):not([data-disabled]):active,.cf-whats-inside-10 .wi10-btn[data-force='active']{--wi10-d:.1;transform:translateY(1px);box-shadow:var(--button-shadow,inset 0 2px 3px oklch(from var(--button-bg,var(--cta,#d63a2f)) calc(l - .22) c h / .45),inset 0 -1px 0 oklch(from var(--button-bg,var(--cta,#d63a2f)) calc(l - .16) c h),var(--wi10-sh-sm))}
.cf-whats-inside-10 .wi10-btn:focus-visible{outline:3px solid var(--field-focus,var(--wi10-accent));outline-offset:3px}
.cf-whats-inside-10 .wi10-btn:disabled,.cf-whats-inside-10 .wi10-btn[data-disabled]{cursor:not-allowed;background:var(--button-2-bg,var(--secondary,#e6e9ef));color:var(--button-2-ink,var(--secondary-ink,#141b2d));border-color:var(--button-2-border,transparent);text-shadow:none;box-shadow:none;transform:none}
.cf-whats-inside-10 .wi10-btn-main{display:inline-flex;align-items:center;justify-content:center;gap:.5rem;font-family:var(--button-font,var(--font-display,system-ui,sans-serif));font-weight:var(--button-weight,800);text-transform:var(--button-case,none);font-size:clamp(1.0625rem,1rem + .4vw,1.3125rem);line-height:1.2;letter-spacing:-.005em;text-wrap:balance}
.cf-whats-inside-10 .wi10-btn-sub{font-size:.9375rem;font-weight:600;line-height:1.3;text-wrap:pretty}
.cf-whats-inside-10 .wi10-spin{width:1.15em;height:1.15em;flex:none;animation:wi10-spin .8s linear infinite}
@keyframes wi10-spin{to{transform:rotate(360deg)}}
.cf-whats-inside-10 .wi10-alt{margin-top:.75rem;max-width:30rem;font-size:1rem;line-height:1.5;color:var(--muted,#4a5568);text-align:center;text-wrap:pretty}
.cf-whats-inside-10 .wi10-alt a{color:var(--link,var(--accent,#2457c5));text-decoration:underline;text-decoration-color:oklch(from var(--link,var(--accent,#2457c5)) l c h / .45);text-underline-offset:.18em}
.cf-whats-inside-10 .wi10-alt a:hover{color:oklch(from var(--link,var(--accent,#2457c5)) calc(l - .08) c h);text-decoration-color:currentColor}
.cf-whats-inside-10 .wi10-alt a:focus-visible{outline:3px solid var(--field-focus,var(--wi10-accent));outline-offset:2px;border-radius:.25rem}
.cf-whats-inside-10 .wi10-err{margin-top:.875rem;max-width:30rem;display:flex;align-items:flex-start;gap:.5rem;padding:.75rem 1rem;border-radius:var(--wi10-radius);background:var(--danger-soft,#fbe9e7);color:var(--danger,#b42318);font-size:1rem;font-weight:600;line-height:1.4}
.cf-whats-inside-10 .wi10-err svg{width:1.15rem;height:1.15rem;flex:none;margin-top:.1rem}
.cf-whats-inside-10 .wi10-guar{margin-top:1.125rem;max-width:30rem;display:flex;align-items:center;justify-content:center;gap:.5rem;font-size:1rem;font-weight:600;line-height:1.4;color:var(--ink,#141b2d)}
.cf-whats-inside-10 .wi10-guar svg{width:1.25rem;height:1.25rem;flex:none;color:var(--success,#1f7a4d)}
@media (max-width:880px){
.cf-whats-inside-10 .wi10-wrap{grid-template-columns:minmax(0,1fr);grid-template-areas:'head' 'visual' 'body';grid-template-rows:auto}
.cf-whats-inside-10.is-solo .wi10-wrap{grid-template-areas:'head' 'body'}
.cf-whats-inside-10 .wi10-visual{position:relative;top:auto;width:100%;max-width:36rem;margin:0 auto}
.cf-whats-inside-10 .wi10-stage{--cw:min(48%,15rem);--spread:34%;--tilt:6deg}
}
@media (max-width:480px){
.cf-whats-inside-10 .wi10-btn,.cf-whats-inside-10 .wi10-alt,.cf-whats-inside-10 .wi10-err,.cf-whats-inside-10 .wi10-guar{max-width:none}
.cf-whats-inside-10 .wi10-btn{padding:.9rem 1.125rem}
}
@media (prefers-reduced-motion:reduce){
.cf-whats-inside-10 .wi10-fan,.cf-whats-inside-10 .wi10-btn,.cf-whats-inside-10 .wi10-row,.cf-whats-inside-10 .wi10-mark{transition:none}
.cf-whats-inside-10 .wi10-fan:hover{--lift:0%}
.cf-whats-inside-10 .wi10-btn:not(:disabled):not([data-disabled]):hover,.cf-whats-inside-10 .wi10-btn:not(:disabled):not([data-disabled]):active,.cf-whats-inside-10 .wi10-btn[data-force]{transform:none}
.cf-whats-inside-10 .wi10-spin{animation:none}
}
`
pieces/offer/whats-inside-10/specimen.tsx 33 lines
'use client'
import * as React from 'react'
import { WhatsInside10, type WhatsInside10State } from '../whats-inside-10'
import defaults from '../../studio-defaults.json'
import { slot } from '../../slots'
export const states: WhatsInside10State[] = ['default', 'hover', 'active', 'disabled', 'error']
export default function WhatsInside10Specimen({ state = 'default' }: { state?: WhatsInside10State }) {
const s = defaults.sample
const items = s.items.map((item, i) => ({
name: item.name,
detail: item.detail,
value: item.value,
image: slot(`item-${i + 1}`, item.image),
imageAlt: item.imageAlt,
}))
return (
<WhatsInside10
state={state}
productName={s.name}
lead={s.lead}
items={items}
price={s.price}
priceNote={s.note}
label={`Send Me ${s.name}`}
sublabel={s.sublabel}
guarantee={s.guarantee}
onAction={() => {}}
/>
)
}
| Name | Type | Details |
|---|---|---|
copy OptionalWhatsInside10 |
Partial<WhatsInside10Copy> |
|
headline OptionalWhatsInside10 |
string |
|
emphasis OptionalWhatsInside10 |
string | false |
|
productName OptionalWhatsInside10 |
string | false |
|
lead OptionalWhatsInside10 |
string | false |
|
items OptionalWhatsInside10 |
WhatsInside10Item[] |
|
defaultActive OptionalWhatsInside10 |
number |
|
price OptionalWhatsInside10 |
string |
|
priceLine OptionalWhatsInside10 |
string | false |
|
priceTag OptionalWhatsInside10 |
string | false |
|
priceNote OptionalWhatsInside10 |
string | false |
|
label OptionalWhatsInside10 |
string |
|
sublabel OptionalWhatsInside10 |
string | false |
|
loadingLabel OptionalWhatsInside10 |
string |
|
secondaryLine OptionalWhatsInside10 |
string | false |
|
secondaryHref OptionalWhatsInside10 |
string |
|
guarantee OptionalWhatsInside10 |
string | false |
|
errorMessage OptionalWhatsInside10 |
string |
|
href OptionalWhatsInside10 |
string |
|
onAction OptionalWhatsInside10 |
() => void | Promise<unknown> |
|
disabled OptionalWhatsInside10 |
boolean |
|
state OptionalWhatsInside10 |
WhatsInside10State |
|
id OptionalWhatsInside10 |
string |
|
className OptionalWhatsInside10 |
string |
|
style OptionalWhatsInside10 |
React.CSSProperties |
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-border--button-2-ink- 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- 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.
item-*- One image per offer item (item-1, item-2…), shown in stacks and lists.
-
b77916eca54aa689.webp
image/webp · 8.32 KB
-
d435db6662febfcf.webp
image/webp · 10 KB
-
f0a5d3e1e61804ba.webp
image/webp · 11.6 KB