Order Bump 7
Round-up gift order bump block: a cause photo with the order card breaking its edge. The classic bump strip ticks in the chosen gift amount, and the total updates live.
Use it in a prompt
Use offer/order-bump-7 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/order-bump-7.tsx. - Import it and pass your copy and images (Props tab):
import { OrderBump7 } from "@/components/funneldna/offer/order-bump-7"
It restyles from the theme tokens on any wrapper (Theme tab). The specimen source is a complete working example.
pieces/offer/order-bump-7/component.tsx 394 lines
// layout: photo-overlap-card
// Round-up gift order bump block: a cause photo with the order card breaking its edge. The classic bump strip ticks in the chosen gift amount, and the total updates live.
"use client"
import * as React from "react"
import { Check, Heart } from "lucide-react"
export type GiftAmount = {
/** Amount in the order currency, e.g. 10. */
value: number
/** Optional chip text. Defaults to the formatted amount. */
label?: string
}
export type OrderBump7Change = { checked: boolean; amount: number; total: number }
export type OrderBump7Props = {
state?: "default" | "hover" | "active" | "disabled"
headline?: React.ReactNode
lead?: React.ReactNode
/** scene slot: the cause photo the order card overlaps. */
photoImage?: string
photoAlt?: string
/** The item already in the order. */
itemName?: string
itemNote?: string
/** product slot: order item thumbnail. */
itemImage?: string
itemImageAlt?: string
/** Order amount before the gift, in the order currency. */
orderAmount?: number
currency?: string
locale?: string
/** The cause receiving the gift. Fills {org}. */
orgName?: string
/** Checkbox headline. {org} and {amount} are replaced. */
bumpHeadline?: string
/** Supplied line on what the gift does. {org} is replaced. Only pass what is true. */
giftLine?: string
chipsLabel?: string
amounts?: GiftAmount[]
amount?: number
defaultAmount?: number
checked?: boolean
defaultChecked?: boolean
/** Strip label while unticked. {amount} is replaced. */
addLabel?: string
/** Strip label while ticked. {amount} is replaced. */
addedLabel?: string
totalLabel?: string
/** Total note while ticked. {amount} is replaced. */
totalNoteAdded?: string
totalNoteBase?: string
/** {item} and {total} are replaced. */
actionLabel?: string
/** {item} and {total} are replaced. */
actionSublabel?: string
href?: string
onAction?: (detail: OrderBump7Change) => void
/** Reports the gift whenever the box or the amount changes. */
onChange?: (detail: OrderBump7Change) => void
disabled?: boolean
id?: string
className?: string
}
export function OrderBump7({
state = "default",
headline = "Round up your order for cleaner rivers",
lead = "Add a small gift for Clean Rivers Trust before you check out. Pick an amount and tick the box.",
photoImage,
photoAlt = "A clear river running over smooth stones in morning light",
itemName = "The Funnel Starter Kit",
itemNote = "One payment · Lifetime access",
itemImage,
itemImageAlt = "",
orderAmount = 47,
currency = "USD",
locale = "en-US",
orgName = "Clean Rivers Trust",
bumpHeadline = "Yes! Add my gift for {org}",
giftLine = "Your gift goes to {org} for its river clean-up work.",
chipsLabel = "Choose your gift",
amounts = DEFAULT_AMOUNTS,
amount,
defaultAmount,
checked,
defaultChecked,
addLabel = "Add {amount}",
addedLabel = "+{amount} added",
totalLabel = "Today’s total",
totalNoteAdded = "Includes your {amount} gift",
totalNoteBase = "Tick the box to add your gift",
actionLabel = "Yes! Complete my order",
actionSublabel = "{total} today · Secure checkout",
href,
onAction,
onChange,
disabled = false,
id,
className,
}: OrderBump7Props) {
const list = amounts.length > 0 ? amounts : DEFAULT_AMOUNTS
const autoId = React.useId().replace(/[^a-zA-Z0-9_-]/g, "")
const baseId = id ?? "ob7-" + autoId
const isDisabled = disabled || state === "disabled"
const [innerChecked, setInnerChecked] = React.useState<boolean>(defaultChecked ?? state === "active")
const [innerAmount, setInnerAmount] = React.useState<number>(
defaultAmount ?? list[Math.min(1, list.length - 1)].value,
)
const isChecked = checked ?? innerChecked
const current = amount ?? innerAmount
const sum = (gift: boolean, value: number) => Math.round((orderAmount + (gift ? value : 0)) * 100) / 100
const total = sum(isChecked, current)
const money = (n: number) => formatMoney(n, currency, locale)
const amountText = money(current)
const totalText = money(total)
const fillMap = { org: orgName, amount: amountText, total: totalText, item: itemName }
const detail: OrderBump7Change = { checked: isChecked, amount: current, total }
const toggle = (next: boolean) => {
if (checked === undefined) setInnerChecked(next)
onChange?.({ checked: next, amount: current, total: sum(next, current) })
}
const pick = (value: number) => {
if (amount === undefined) setInnerAmount(value)
onChange?.({ checked: isChecked, amount: value, total: sum(isChecked, value) })
}
const ctaInner = (
<>
<span className="ob7-cta-label">{fill(actionLabel, fillMap)}</span>
{actionSublabel ? <span className="ob7-cta-sub">{fill(actionSublabel, fillMap)}</span> : null}
</>
)
return (
<section
className={["cf-order-bump-7", className].filter(Boolean).join(" ")}
data-checked={isChecked ? "" : undefined}
data-disabled={isDisabled ? "" : undefined}
data-force-hover={state === "hover" ? "" : undefined}
aria-labelledby={baseId + "-title"}
>
<style>{CSS}</style>
<div className="ob7-wrap">
<div className="ob7-head">
<h2 id={baseId + "-title"} className="ob7-title">
{headline}
</h2>
{lead ? <p className="ob7-lead">{lead}</p> : null}
</div>
{photoImage ? (
<figure className="ob7-photo">
<img src={photoImage} alt={photoAlt} width={1600} height={900} loading="lazy" decoding="async" />
</figure>
) : null}
<div className="ob7-card" data-overlap={photoImage ? "" : undefined}>
<div className="ob7-item" data-thumb={itemImage ? "" : undefined}>
{itemImage ? (
<img className="ob7-thumb" src={itemImage} alt={itemImageAlt} width={64} height={64} />
) : null}
<div className="ob7-item-text">
<h3 className="ob7-item-name">{itemName}</h3>
{itemNote ? <p className="ob7-item-note">{itemNote}</p> : null}
</div>
<span className="ob7-item-price">{money(orderAmount)}</span>
</div>
<div className="ob7-bump">
<label className="ob7-strip" htmlFor={baseId + "-gift"}>
<span className="ob7-mark">
<input
id={baseId + "-gift"}
type="checkbox"
checked={isChecked}
disabled={isDisabled}
onChange={(e) => toggle(e.target.checked)}
aria-describedby={giftLine ? baseId + "-line" : undefined}
/>
<Check className="ob7-tick" size={18} strokeWidth={3} aria-hidden />
</span>
<span className="ob7-strip-title">{fill(bumpHeadline, fillMap)}</span>
<span key={(isChecked ? "on" : "off") + amountText} className="ob7-pill">
{fill(isChecked ? addedLabel : addLabel, fillMap)}
</span>
</label>
<div className="ob7-body">
<fieldset className="ob7-chips" disabled={isDisabled}>
<legend className="ob7-legend">{chipsLabel}</legend>
<div
className="ob7-chip-row"
style={{ gridTemplateColumns: `repeat(${Math.min(list.length, 4)}, minmax(0, 1fr))` }}
>
{list.map((a) => (
<label key={a.value} className="ob7-chip">
<input
type="radio"
name={baseId + "-amount"}
value={a.value}
checked={a.value === current}
onChange={() => pick(a.value)}
/>
<span className="ob7-chip-face">
<span className="ob7-chip-text">{a.label ?? money(a.value)}</span>
<span className="ob7-chip-dot" aria-hidden>
<Check size={12} strokeWidth={3} />
</span>
</span>
</label>
))}
</div>
</fieldset>
{giftLine ? (
<p id={baseId + "-line"} className="ob7-line">
<Heart className="ob7-line-icon" size={16} strokeWidth={2.5} aria-hidden />
{fill(giftLine, fillMap)}
</p>
) : null}
</div>
</div>
<div className="ob7-total" aria-live="polite">
<div className="ob7-total-text">
<p className="ob7-total-label">{totalLabel}</p>
<p className="ob7-total-note">{isChecked ? fill(totalNoteAdded, fillMap) : totalNoteBase}</p>
</div>
<span key={totalText} className="ob7-total-figure">
{totalText}
</span>
</div>
{href ? (
<a
className="ob7-cta"
href={isDisabled ? undefined : href}
aria-disabled={isDisabled || undefined}
onClick={(e) => {
if (isDisabled) {
e.preventDefault()
return
}
onAction?.(detail)
}}
>
{ctaInner}
</a>
) : (
<button type="button" className="ob7-cta" disabled={isDisabled} onClick={() => onAction?.(detail)}>
{ctaInner}
</button>
)}
</div>
</div>
</section>
)
}
export default OrderBump7
const DEFAULT_AMOUNTS: GiftAmount[] = [{ value: 5 }, { value: 10 }, { value: 25 }]
function fill(template: string, map: Record<string, string>): string {
return Object.keys(map).reduce((text, key) => text.split("{" + key + "}").join(map[key]), template)
}
function formatMoney(value: number, currency: string, locale: string): string {
const digits = Number.isInteger(value) ? 0 : 2
try {
return new Intl.NumberFormat(locale, {
style: "currency",
currency,
minimumFractionDigits: digits,
maximumFractionDigits: 2,
}).format(value)
} catch {
return "$" + value.toFixed(digits)
}
}
const CSS = `
.cf-order-bump-7{
--_shadow:var(--shadow, oklch(0.22 0.03 260));
--_cta:var(--button-bg, var(--cta, oklch(0.58 0.21 29)));
--_cta2:var(--button-bg-2, var(--cta-2, oklch(0.51 0.21 29)));
--_focus:var(--field-focus, var(--accent, oklch(0.5 0.17 257)));
--_tickfill:var(--success, oklch(0.5 0.14 150));
--_tickink:var(--card, oklch(1 0 0));
--_strip:var(--bump-strip, oklch(0.93 0.11 95));
--_paper:var(--bump, oklch(0.975 0.04 95));
--_bink:var(--bump-ink, var(--ink, oklch(0.21 0.03 263)));
position:relative;
background:var(--surface, oklch(1 0 0));
color:var(--ink, oklch(0.21 0.03 263));
font-family:var(--font-body, Arial, sans-serif);
padding:clamp(56px,8vw,112px) clamp(16px,5vw,48px) clamp(64px,8.5vw,120px);
overflow-x:clip;
}
.cf-order-bump-7 *,.cf-order-bump-7 *::before,.cf-order-bump-7 *::after{box-sizing:border-box}
.cf-order-bump-7 .ob7-wrap{max-width:1120px;margin:0 auto;display:grid;grid-template-columns:minmax(0,1fr)}
.cf-order-bump-7 .ob7-head{margin-bottom:24px;min-width:0}
.cf-order-bump-7 .ob7-title{margin:0;font-family:var(--font-display, Arial, sans-serif);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;text-wrap:balance;color:var(--ink)}
.cf-order-bump-7 .ob7-lead{margin:16px 0 0;max-width:56ch;font-size:clamp(1.125rem,1.5vw,1.375rem);line-height:1.4;font-weight:500;color:var(--muted);text-wrap:pretty}
.cf-order-bump-7 .ob7-photo{margin:0;min-width:0}
.cf-order-bump-7 .ob7-photo img{display:block;width:100%;height:clamp(240px,36vw,460px);object-fit:cover;object-position:center 60%;border-radius:12px}
.cf-order-bump-7 .ob7-card{position:relative;z-index:1;min-width:0;margin:0;background:var(--card, oklch(1 0 0));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(--_shadow) l c h / 0.22), 0 12px 24px -8px oklch(from var(--_shadow) l c h / 0.32)));padding:clamp(20px,3vw,32px);animation:ob7-rise .45s cubic-bezier(.2,.7,.2,1) both}
.cf-order-bump-7 .ob7-card[data-overlap]{margin:-56px 8px 0}
.cf-order-bump-7 .ob7-item{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:16px;align-items:start}
.cf-order-bump-7 .ob7-item[data-thumb]{grid-template-columns:64px minmax(0,1fr) auto}
.cf-order-bump-7 .ob7-thumb{display:block;width:64px;height:64px;object-fit:cover;border-radius:8px}
.cf-order-bump-7 .ob7-item-text{min-width:0}
.cf-order-bump-7 .ob7-item-name{margin:0;font-family:var(--font-display, Arial, sans-serif);font-weight:800;font-size:clamp(1.0625rem,1.25vw,1.125rem);line-height:1.25;letter-spacing:-0.01em;text-wrap:balance;color:var(--ink)}
.cf-order-bump-7 .ob7-item-note{margin:4px 0 0;font-size:.9375rem;font-weight:500;line-height:1.4;color:var(--muted)}
.cf-order-bump-7 .ob7-item-price{font-family:var(--font-display, Arial, sans-serif);font-weight:800;font-size:clamp(1.0625rem,1.25vw,1.125rem);line-height:1.25;font-variant-numeric:tabular-nums;color:var(--ink)}
.cf-order-bump-7 .ob7-bump{margin-top:20px;border-radius:var(--radius,12px);overflow:hidden;background:var(--_paper);color:var(--_bink);border:1px solid oklch(from var(--_bink) l c h / 0.2);outline:1px solid transparent;outline-offset:0;transition:border-color .16s ease, outline-color .16s ease}
.cf-order-bump-7[data-checked] .ob7-bump{border-color:var(--_tickfill);outline-color:var(--_tickfill)}
.cf-order-bump-7[data-disabled] .ob7-bump{opacity:.62}
.cf-order-bump-7 .ob7-strip{display:grid;grid-template-columns:28px minmax(0,1fr) auto;align-items:center;column-gap:14px;row-gap:8px;padding:14px 18px;background:var(--_strip);color:var(--_bink);cursor:pointer;user-select:none;-webkit-tap-highlight-color:transparent;transition:background .16s ease}
.cf-order-bump-7:not([data-disabled]) .ob7-strip:hover,.cf-order-bump-7[data-force-hover] .ob7-strip{background:oklch(from var(--_strip) calc(l - 0.03) c h)}
.cf-order-bump-7[data-disabled] .ob7-strip{cursor:not-allowed}
.cf-order-bump-7 .ob7-mark{position:relative;width:28px;height:28px;border-radius:8px;display:grid;place-items:center;background:var(--field, var(--card, oklch(1 0 0)));color:var(--field-ink, var(--ink));border:2px solid var(--_bink);box-shadow:inset 0 1px 2px oklch(from var(--_shadow) l c h / 0.22);transition:background .16s ease, border-color .16s ease, outline-color .16s ease}
.cf-order-bump-7 .ob7-mark input{position:absolute;inset:-2px;width:calc(100% + 4px);height:calc(100% + 4px);margin:0;opacity:0;cursor:inherit}
.cf-order-bump-7:not([data-disabled]) .ob7-strip:hover .ob7-mark,.cf-order-bump-7[data-force-hover] .ob7-mark{border-color:var(--_bink);outline:3px solid oklch(from var(--_bink) l c h / 0.18);outline-offset:0}
.cf-order-bump-7 .ob7-mark:has(input:focus-visible){outline:3px solid var(--_focus);outline-offset:2px}
.cf-order-bump-7 .ob7-tick{display:block;color:var(--_tickink);opacity:0;transform:scale(.6);transition:opacity .16s ease, transform .16s ease}
.cf-order-bump-7[data-checked] .ob7-mark{background:var(--_tickfill);border-color:var(--_tickfill);color:var(--card, oklch(1 0 0))}
.cf-order-bump-7[data-checked] .ob7-tick{opacity:1;transform:none}
.cf-order-bump-7 .ob7-strip-title{min-width:0;font-family:var(--font-display, Arial, sans-serif);font-weight:800;font-size:clamp(1.0625rem,1.25vw,1.125rem);line-height:1.25;text-wrap:balance}
.cf-order-bump-7 .ob7-pill{display:inline-flex;align-items:center;min-height:28px;padding:4px 12px;border-radius:999px;font-size:.875rem;font-weight:800;line-height:1.2;font-variant-numeric:tabular-nums;white-space:nowrap;background:color-mix(in oklch, var(--_bink) 10%, var(--_strip));color:var(--_bink);transition:background .16s ease, color .16s ease}
.cf-order-bump-7[data-checked] .ob7-pill{background:var(--_tickfill);color:var(--_tickink);animation:ob7-pop .3s cubic-bezier(.2,.7,.2,1) both}
.cf-order-bump-7 .ob7-body{padding:16px 18px 18px}
.cf-order-bump-7 .ob7-chips{border:0;margin:0;padding:0;min-width:0}
.cf-order-bump-7 .ob7-legend{padding:0;margin:0 0 12px;font-size:.9375rem;font-weight:700;line-height:1.4;color:var(--_bink)}
.cf-order-bump-7 .ob7-chip-row{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.cf-order-bump-7 .ob7-chip{position:relative;display:block;min-width:0;cursor:pointer}
.cf-order-bump-7 .ob7-chips:disabled .ob7-chip{cursor:not-allowed}
.cf-order-bump-7 .ob7-chip input{position:absolute;opacity:0;width:1px;height:1px;margin:0;pointer-events:none}
.cf-order-bump-7 .ob7-chip-face{position:relative;display:flex;align-items:center;justify-content:center;min-height:56px;padding:8px 12px;border-radius:var(--field-radius, var(--radius,12px));background:var(--field, oklch(1 0 0));color:var(--field-ink, var(--ink));border:1px solid var(--field-border, oklch(from var(--field-ink, var(--ink)) l c h / 0.22));box-shadow:var(--shadow-sm, 0 1px 2px oklch(from var(--_shadow) l c h / 0.18));font-family:var(--font-display, Arial, sans-serif);font-weight:800;font-size:clamp(1.125rem,1.55vw,1.375rem);line-height:1.15;letter-spacing:-0.01em;font-variant-numeric:tabular-nums;transition:transform .16s ease, border-color .16s ease, box-shadow .16s ease, background .16s ease}
.cf-order-bump-7 .ob7-chips:not(:disabled) .ob7-chip:hover .ob7-chip-face{border-color:oklch(from var(--field-ink, var(--ink)) l c h / 0.5);box-shadow:var(--shadow-md, 0 1px 2px oklch(from var(--_shadow) l c h / 0.22), 0 4px 10px -2px oklch(from var(--_shadow) l c h / 0.2));transform:translateY(-1px)}
.cf-order-bump-7 .ob7-chip input:checked + .ob7-chip-face{background:color-mix(in oklch, var(--accent-fill, var(--accent)) 12%, var(--field, oklch(1 0 0)));border-color:var(--accent-fill, var(--accent));box-shadow:inset 0 0 0 1px var(--accent-fill, var(--accent)), var(--shadow-md, 0 1px 2px oklch(from var(--_shadow) l c h / 0.22), 0 4px 10px -2px oklch(from var(--_shadow) l c h / 0.2));transform:translateY(-1px)}
.cf-order-bump-7 .ob7-chip input:focus-visible + .ob7-chip-face{outline:3px solid var(--_focus);outline-offset:2px}
.cf-order-bump-7 .ob7-chip-dot{position:absolute;top:6px;right:6px;width:18px;height:18px;border-radius:999px;display:grid;place-items:center;background:var(--accent-fill, var(--accent));color:var(--accent-fill-ink, var(--card));opacity:0;transform:scale(.6);transition:opacity .16s ease, transform .16s ease}
.cf-order-bump-7 .ob7-chip input:checked + .ob7-chip-face .ob7-chip-dot{opacity:1;transform:none}
.cf-order-bump-7 .ob7-line{margin:14px 0 0;font-size:.9375rem;font-weight:500;line-height:1.45;color:var(--_bink);text-wrap:pretty}
.cf-order-bump-7 .ob7-line-icon{display:inline-block;vertical-align:-0.15em;margin-inline-end:.4em}
.cf-order-bump-7 .ob7-total{display:flex;justify-content:space-between;align-items:flex-end;gap:16px;margin-top:24px}
.cf-order-bump-7 .ob7-total-text{min-width:0}
.cf-order-bump-7 .ob7-total-label{margin:0;font-size:clamp(1.0625rem,1.25vw,1.125rem);font-weight:800;line-height:1.25;color:var(--ink)}
.cf-order-bump-7 .ob7-total-note{margin:4px 0 0;font-size:.9375rem;font-weight:500;line-height:1.4;color:var(--muted);text-wrap:pretty}
.cf-order-bump-7 .ob7-total-figure{display:inline-block;flex:none;font-family:var(--font-display, Arial, sans-serif);font-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);animation:ob7-pop .3s cubic-bezier(.2,.7,.2,1) both}
.cf-order-bump-7 .ob7-cta{appearance:none;border:0;margin:20px 0 0;width:100%;min-height:64px;padding:12px 28px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;text-align:center;text-decoration:none;border-radius:var(--button-radius, var(--radius,12px));background:linear-gradient(oklch(from var(--_cta) calc(l + 0.04) c h), oklch(from var(--_cta2) calc(l - 0.02) c h));color:var(--button-ink, var(--cta-ink, oklch(1 0 0)));font-family:var(--button-font, var(--font-display, Arial, sans-serif));font-weight:var(--button-weight,800);text-transform:var(--button-case,none);text-shadow:var(--button-text-shadow,none);box-shadow:var(--button-shadow, inset 0 1px 0 oklch(from var(--_cta) calc(l + 0.14) c h / 0.7), inset 0 -3px 0 oklch(from var(--_cta) calc(l - 0.16) c h), 0 1px 2px oklch(from var(--_shadow) l c h / 0.3), 0 8px 16px -6px oklch(from var(--_shadow) l c h / 0.45));cursor:pointer;-webkit-tap-highlight-color:transparent;transition:transform .16s ease, box-shadow .16s ease, background .16s ease}
.cf-order-bump-7 .ob7-cta:hover:not(:disabled):not([aria-disabled]){background:linear-gradient(oklch(from var(--_cta) calc(l - 0.01) c h), oklch(from var(--_cta2) calc(l - 0.07) c h));box-shadow:var(--button-shadow, inset 0 1px 0 oklch(from var(--_cta) calc(l + 0.14) c h / 0.7), inset 0 -3px 0 oklch(from var(--_cta) calc(l - 0.16) c h), 0 1px 2px oklch(from var(--_shadow) l c h / 0.32), 0 10px 18px -6px oklch(from var(--_shadow) l c h / 0.5))}
.cf-order-bump-7 .ob7-cta:active:not(:disabled):not([aria-disabled]){transform:translateY(1px);box-shadow:inset 0 2px 4px oklch(from var(--_cta) calc(l - 0.2) c h / 0.45), inset 0 -2px 0 oklch(from var(--_cta) calc(l - 0.16) c h), 0 1px 2px oklch(from var(--_shadow) l c h / 0.3)}
.cf-order-bump-7 .ob7-cta:focus-visible{outline:3px solid var(--_focus);outline-offset:3px}
.cf-order-bump-7 .ob7-cta:disabled,.cf-order-bump-7 .ob7-cta[aria-disabled]{background:var(--secondary);color:var(--secondary-ink);text-shadow:none;box-shadow:var(--shadow-sm);cursor:not-allowed}
.cf-order-bump-7 .ob7-cta-label{font-size:clamp(1.125rem,1.55vw,1.375rem);line-height:1.15;text-wrap:balance}
.cf-order-bump-7 .ob7-cta-sub{font-family:var(--font-body, Arial, sans-serif);font-size:.9375rem;font-weight:600;line-height:1.3;text-wrap:balance}
@keyframes ob7-rise{from{opacity:.82;transform:translateY(8px)}to{opacity:1;transform:none}}
@keyframes ob7-pop{from{transform:scale(.9)}to{transform:none}}
@media (min-width:1024px){
.cf-order-bump-7 .ob7-wrap{grid-template-columns:minmax(0,1fr) minmax(0,560px);column-gap:clamp(32px,5vw,72px)}
.cf-order-bump-7 .ob7-photo{grid-column:1 / -1;grid-row:1}
.cf-order-bump-7 .ob7-head{grid-column:1;grid-row:2;margin:0;padding-top:clamp(32px,4vw,48px)}
.cf-order-bump-7 .ob7-card{grid-column:2;grid-row:2;align-self:start}
.cf-order-bump-7 .ob7-card[data-overlap]{margin:calc(-1 * clamp(150px,14vw,200px)) 36px 0 0}
}
@media (max-width:560px){
.cf-order-bump-7 .ob7-strip{grid-template-columns:28px minmax(0,1fr);padding:14px 16px}
.cf-order-bump-7 .ob7-mark{align-self:start}
.cf-order-bump-7 .ob7-pill{grid-column:2;justify-self:start}
.cf-order-bump-7 .ob7-body{padding:14px 16px 16px}
.cf-order-bump-7 .ob7-cta{padding:12px 20px}
}
@media (prefers-reduced-motion: reduce){
.cf-order-bump-7 .ob7-card,.cf-order-bump-7 .ob7-pill,.cf-order-bump-7[data-checked] .ob7-pill,.cf-order-bump-7 .ob7-total-figure{animation:none}
.cf-order-bump-7 .ob7-bump,.cf-order-bump-7 .ob7-strip,.cf-order-bump-7 .ob7-mark,.cf-order-bump-7 .ob7-tick,.cf-order-bump-7 .ob7-pill,.cf-order-bump-7 .ob7-chip-face,.cf-order-bump-7 .ob7-chip-dot,.cf-order-bump-7 .ob7-cta{transition:none}
.cf-order-bump-7 .ob7-chips:not(:disabled) .ob7-chip:hover .ob7-chip-face,.cf-order-bump-7 .ob7-chip input:checked + .ob7-chip-face,.cf-order-bump-7 .ob7-cta:active:not(:disabled):not([aria-disabled]){transform:none}
}
`
pieces/offer/order-bump-7/specimen.tsx 41 lines
import __studioImagedf3108f1 from "../assets/8687db0c068533f3.webp";
import OrderBump7 from "../order-bump-7"
import defaults from "../../studio-defaults.json"
import { slot } from "../../slots"
export const states = ["default", "hover", "active", "disabled"]
type SpecimenState = "default" | "hover" | "active" | "disabled"
export default function OrderBump7Specimen({ state = "default" }: { state?: SpecimenState }) {
const sample = defaults.sample
const item = sample.items[0]
const orderAmount = Number(String(sample.price).replace(/[^0-9.]/g, "")) || 47
return (
<OrderBump7
key={state}
state={state}
headline="Round up your order for cleaner rivers"
lead="Add a small gift for Clean Rivers Trust before you check out. Pick an amount and tick the box."
photoImage={slot(
"scene",
__studioImagedf3108f1,
)}
photoAlt="A clear river running over smooth stones through green woodland in morning light"
itemName={sample.name}
itemNote={sample.note}
itemImage={slot("product", item.image)}
itemImageAlt={item.imageAlt}
orderAmount={orderAmount}
orgName="Clean Rivers Trust"
bumpHeadline="Yes! Add my gift for {org}"
giftLine="Your gift goes to {org} for its river clean-up work."
chipsLabel="Choose your gift"
amounts={[{ value: 5 }, { value: 10 }, { value: 25 }]}
defaultAmount={10}
actionLabel="Yes! I want the Funnel Starter Kit"
actionSublabel="{total} today · Secure checkout"
/>
)
}
| Name | Type | Details |
|---|---|---|
state OptionalOrderBump7 |
"default" | "hover" | "active" | "disabled" |
Default "default"
|
headline OptionalOrderBump7 |
React.ReactNode |
Default "Round up your order for cleaner rivers"
|
lead OptionalOrderBump7 |
React.ReactNode |
Default "Add a small gift for Clean Rivers Trust before you check out. Pick an amount and tick the box."
|
photoImage OptionalOrderBump7 |
string |
|
photoAlt OptionalOrderBump7 |
string |
Default "A clear river running over smooth stones in morning light"
|
itemName OptionalOrderBump7 |
string |
Default "The Funnel Starter Kit"
|
itemNote OptionalOrderBump7 |
string |
Default "One payment · Lifetime access"
|
itemImage OptionalOrderBump7 |
string |
|
itemImageAlt OptionalOrderBump7 |
string |
Default ""
|
orderAmount OptionalOrderBump7 |
number |
Default 47
|
currency OptionalOrderBump7 |
string |
Default "USD"
|
locale OptionalOrderBump7 |
string |
Default "en-US"
|
orgName OptionalOrderBump7 |
string |
Default "Clean Rivers Trust"
|
bumpHeadline OptionalOrderBump7 |
string |
Default "Yes! Add my gift for {org}"
|
giftLine OptionalOrderBump7 |
string |
Default "Your gift goes to {org} for its river clean-up work."
|
chipsLabel OptionalOrderBump7 |
string |
Default "Choose your gift"
|
amounts OptionalOrderBump7 |
GiftAmount[] |
Default DEFAULT_AMOUNTS
|
amount OptionalOrderBump7 |
number |
|
defaultAmount OptionalOrderBump7 |
number |
|
checked OptionalOrderBump7 |
boolean |
|
defaultChecked OptionalOrderBump7 |
boolean |
|
addLabel OptionalOrderBump7 |
string |
Default "Add {amount}"
|
addedLabel OptionalOrderBump7 |
string |
Default "+{amount} added"
|
totalLabel OptionalOrderBump7 |
string |
Default "Today’s total"
|
totalNoteAdded OptionalOrderBump7 |
string |
Default "Includes your {amount} gift"
|
totalNoteBase OptionalOrderBump7 |
string |
Default "Tick the box to add your gift"
|
actionLabel OptionalOrderBump7 |
string |
Default "Yes! Complete my order"
|
actionSublabel OptionalOrderBump7 |
string |
Default "{total} today · Secure checkout"
|
href OptionalOrderBump7 |
string |
|
onAction OptionalOrderBump7 |
(detail: OrderBump7Change) => void |
|
onChange OptionalOrderBump7 |
(detail: OrderBump7Change) => void |
|
disabled OptionalOrderBump7 |
boolean |
Default false
|
id OptionalOrderBump7 |
string |
|
className OptionalOrderBump7 |
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.
--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.
Image slots
Filled from the brand’s images; the specimen ships its own defaults.
product- The main product shot or cover (ebook, kit, bottle).
scene- A wide atmosphere photo behind or beside the copy.
-
8687db0c068533f3.webp
image/webp · 251 KB
-
b77916eca54aa689.webp
image/webp · 8.32 KB
-
d435db6662febfcf.webp
image/webp · 10 KB
-
f0a5d3e1e61804ba.webp
image/webp · 11.6 KB