Story Strip 1
Story strip: each customer's journey reads left to right (before photo, a progress line that draws through their
Use it in a prompt
Use proof/story-strip 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/proof/story-strip.tsx. - Import it and pass your copy and images (Props tab):
import { StoryStrip } from "@/components/funneldna/proof/story-strip"
It restyles from the theme tokens on any wrapper (Theme tab). The specimen source is a complete working example.
pieces/proof/story-strip/component.tsx 421 lines
// layout: scroll-panels
// Story strip: each customer's journey reads left to right (before photo, a progress line that draws through their
// supplied milestones, after photo and result) so the outcome feels earned right before the risk-first close.
import React from "react";
import { Check } from "lucide-react";
import { useInView, useReducedMotion } from "motion/react";
import { Divider, FX_HOST } from "../fx/fx";
import nature from "../fx/backdrops/nature";
export type StoryMilestone = {
/** When it happened, e.g. "Week 2". */
when?: string;
/** What changed at that point. */
label: string;
};
export type Story = {
/** Who the story is about (the row heading). */
name?: string;
/** Short who/where line beside the name. */
detail?: string;
/** Time from before to after, set large over the progress line. */
timeframe?: string;
/** Where they started. */
start?: string;
/** Where they are now. */
result?: string;
beforeImage?: string;
beforeAlt?: string;
afterImage?: string;
afterAlt?: string;
/** 2-3 supplied milestones, lit in order as the line draws. */
milestones?: StoryMilestone[];
};
export type StoryStripCopy = {
before: string;
after: string;
/** Alt template; "{name}" is replaced by the story name. */
beforeAlt: string;
afterAlt: string;
/** Accessible list label; "{name}" is replaced. */
milestonesLabel: string;
};
export type StoryStripState = "default" | "hover" | "active" | "disabled";
export type StoryStripProps = {
headline?: React.ReactNode;
/** Phrase inside a string headline that gets one marker stroke. */
highlight?: string;
/** One-sentence lines under the headline. */
lead?: string[];
/** Short emphasis line after the lead (one word works best). */
punch?: string;
/** Supplied stories only; with none the section renders nothing. */
stories?: Story[];
/** Full-bleed scene behind the headline (scene slot). Pass "" for a plain band. */
sceneImage?: string;
/** Risk reversal that leads the close, e.g. "Try it for 30 days". */
riskHeadline?: string;
riskLine?: string;
actionLabel?: string;
/** One short reassurance line under the button. */
actionNote?: string;
href?: string;
onAction?: () => void;
actionDisabled?: boolean;
state?: StoryStripState;
copy?: Partial<StoryStripCopy>;
className?: string;
};
export function StoryStrip({
headline = "Where they started, and where they are now",
highlight,
lead = [],
punch = "",
stories = [],
sceneImage = nature,
riskHeadline = "",
riskLine = "",
actionLabel = "Start your own story",
actionNote = "",
href,
onAction,
actionDisabled = false,
state = "default",
copy,
className,
}: StoryStripProps) {
const uid = React.useId();
const reduced = useReducedMotion() ?? false;
const c: StoryStripCopy = { ...DEFAULT_COPY, ...copy };
const list = (stories ?? []).filter(hasContent);
if (!list.length) return null;
const titleId = `${uid}-title`;
const leadLines = (lead ?? []).filter(Boolean);
const disabled = actionDisabled || state === "disabled";
const showClose = Boolean(actionLabel || riskHeadline || riskLine);
const btnClass = ["ss-btn", state === "hover" ? "is-hover" : "", state === "active" ? "is-active" : ""].filter(Boolean).join(" ");
const button = !actionLabel ? null : href && !disabled ? (
<a className={btnClass} href={href} onClick={() => onAction?.()}>
{actionLabel}
</a>
) : (
<button type="button" className={btnClass} disabled={disabled} onClick={() => onAction?.()}>
{actionLabel}
</button>
);
return (
<section className={["cf-story-strip", className].filter(Boolean).join(" ")} aria-labelledby={titleId}>
<style>{CSS}</style>
<header className="ss-hero" style={FX_HOST}>
{sceneImage ? <img className="ss-scene" src={sceneImage} alt="" aria-hidden="true" /> : null}
{sceneImage ? <span className="ss-scrim" aria-hidden="true" /> : null}
<div className="ss-wrap ss-intro">
<h2 id={titleId} className="ss-title">
{renderHeadline(headline, highlight)}
</h2>
{leadLines.length > 0 && (
<div className="ss-lead">
{leadLines.map((line, i) => (
<p key={i}>{line}</p>
))}
</div>
)}
{punch && <p className="ss-punch">{punch}</p>}
</div>
<Divider shape="wave" tone="surface" height={56} />
</header>
<div className="ss-stories">
{list.map((story, i) => (
<StoryRow key={i} story={story} index={i} copy={c} reduced={reduced} uid={uid} />
))}
{showClose && (
<div className={`ss-close ${list.length % 2 ? "ss-tone-b" : "ss-tone-a"}`}>
<div className="ss-wrap ss-close-inner">
{riskHeadline && <h3 className="ss-risk">{riskHeadline}</h3>}
{riskLine && <p className="ss-risk-line">{riskLine}</p>}
{button}
{actionLabel && actionNote && <p className="ss-note">{actionNote}</p>}
</div>
</div>
)}
</div>
</section>
);
}
export default StoryStrip;
const DEFAULT_COPY: StoryStripCopy = {
before: "Before",
after: "After",
beforeAlt: "{name}, before",
afterAlt: "{name}, after",
milestonesLabel: "Milestones for {name}",
};
function StoryRow({
story,
index,
copy,
reduced,
uid,
}: {
story: Story;
index: number;
copy: StoryStripCopy;
reduced: boolean;
uid: string;
}) {
const ref = React.useRef<HTMLElement>(null);
const inView = useInView(ref, { once: true, amount: 0.3 });
const drawn = reduced || inView;
const milestones = (story.milestones ?? []).filter((m) => m && m.label);
const n = milestones.length;
const name = story.name ?? "";
const nameId = `${uid}-story-${index}`;
const pb = Boolean(story.beforeImage);
const pa = Boolean(story.afterImage);
const layout = pb && pa ? "p-ba" : pa ? "p-a" : pb ? "p-b" : "p-0";
const cls = ["ss-panel", index % 2 ? "ss-tone-b" : "ss-tone-a", drawn ? "is-drawn" : "", reduced ? "is-still" : ""]
.filter(Boolean)
.join(" ");
return (
<article ref={ref} className={cls} aria-labelledby={name ? nameId : undefined}>
<div className="ss-wrap">
{(name || story.detail) && (
<header className="ss-head">
{name && (
<h3 id={nameId} className="ss-name">
{name}
</h3>
)}
{story.detail && <p className="ss-detail">{story.detail}</p>}
</header>
)}
<div className={`ss-row ${layout}`}>
{story.beforeImage && (
<figure className="ss-photo ss-photo-before">
<img
src={story.beforeImage}
alt={story.beforeAlt || fill(copy.beforeAlt, name)}
width={800}
height={1000}
loading="lazy"
decoding="async"
/>
</figure>
)}
{story.start && (
<div className={`ss-text ss-text-before${pb ? "" : " is-solo"}`}>
<p className="ss-tag">{copy.before}</p>
<p className="ss-start">{story.start}</p>
</div>
)}
<div className="ss-track">
{story.timeframe && <p className="ss-span">{story.timeframe}</p>}
<div className="ss-rail" style={vars({ "--n": Math.max(n, 1) })}>
<span className="ss-line" aria-hidden="true">
<span className="ss-fill" />
</span>
<span className="ss-cap ss-cap-start" aria-hidden="true" />
{n > 0 && (
<ol className="ss-steps" aria-label={fill(copy.milestonesLabel, name)}>
{milestones.map((m, i) => (
<li key={i} className="ss-step" style={vars({ "--pos": ((i + 0.5) / n).toFixed(3) })}>
<span className="ss-dot" aria-hidden="true">
<Check size={12} strokeWidth={3} />
</span>
<span className="ss-step-text">
{m.when && <strong className="ss-when">{m.when}</strong>}
<span>{m.label}</span>
</span>
</li>
))}
</ol>
)}
<span className="ss-cap ss-cap-end" aria-hidden="true" />
</div>
</div>
{story.afterImage && (
<figure className="ss-photo ss-photo-after">
<img
src={story.afterImage}
alt={story.afterAlt || fill(copy.afterAlt, name)}
width={800}
height={1000}
loading="lazy"
decoding="async"
/>
</figure>
)}
{story.result && (
<div className={`ss-text ss-text-after${pa ? "" : " is-solo"}`}>
<p className="ss-tag">
<span className="ss-badge" aria-hidden="true">
<Check size={14} strokeWidth={3} />
</span>
{copy.after}
</p>
<p className="ss-result">{story.result}</p>
</div>
)}
</div>
</div>
</article>
);
}
function hasContent(s: Story | null | undefined): s is Story {
return Boolean(
s &&
(s.name || s.start || s.result || s.beforeImage || s.afterImage || (s.milestones ?? []).some((m) => m && m.label))
);
}
function fill(template: string, name: string) {
if (name) return template.split("{name}").join(name);
return template.split("{name}, ").join("").split("{name}").join("").trim();
}
/** Binds 1-3 letter words to the next word so no "a" or "to" is stranded at a line end (or split from its marker). */
function bindShortWords(s: string) {
return s.replace(/(?<=(?:^|\s)\S{1,3}) (?=\S)/g, "\u00a0");
}
function renderHeadline(headline: React.ReactNode, highlight?: string) {
if (typeof headline !== "string") return headline;
const text = bindShortWords(headline);
if (!highlight) return text;
const mark = bindShortWords(highlight);
const at = text.indexOf(mark);
if (at < 0) return text;
return (
<>
{text.slice(0, at)}
<span className="ss-mark">{mark}</span>
{text.slice(at + mark.length)}
</>
);
}
function vars(o: Record<string, string | number>): React.CSSProperties {
return o as unknown as React.CSSProperties;
}
const CSS = `
.cf-story-strip{--ss-draw:1.4s;--ss-gutter:clamp(16px,5vw,48px);font-family:var(--font-body);color:var(--ink);background:var(--surface);overflow-x:clip}
.cf-story-strip *,.cf-story-strip *::before,.cf-story-strip *::after{box-sizing:border-box}
.cf-story-strip :where(h2,h3,p,ol,li,figure){margin:0;padding:0}
.cf-story-strip ol{list-style:none}
.cf-story-strip .ss-wrap{width:min(calc(100% - 2 * var(--ss-gutter)),1120px);margin-inline:auto}
.cf-story-strip .ss-hero{position:relative;isolation:isolate;overflow:hidden;background:var(--band);color:var(--band-ink);text-align:center;padding:clamp(56px,8vw,112px) 0 calc(clamp(48px,6vw,88px) + 56px)}
.cf-story-strip .ss-scene{position:absolute;inset:0;z-index:-1;width:100%;height:100%;object-fit:cover;object-position:center 40%;filter:grayscale(1)}
.cf-story-strip .ss-scrim{position:absolute;inset:0;z-index:-1;background:oklch(from var(--band) l c h / .84)}
.cf-story-strip .ss-intro{position:relative;z-index:1;max-width:46rem}
.cf-story-strip .ss-title{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;text-wrap:balance;color:var(--band-ink)}
.cf-story-strip .ss-mark{--ss-marker:oklch(from var(--marker,#fae37c) l c h / 1);background:linear-gradient(transparent 26%,var(--ss-marker) 26%,var(--ss-marker) 92%,transparent 92%);color:oklch(from var(--marker,#fae37c) clamp(0.16,calc((0.66 - l) * 1000),0.98) 0.02 260);padding:0 .12em;margin:0 -.04em;border-radius:.1em;-webkit-box-decoration-break:clone;box-decoration-break:clone}
.cf-story-strip .ss-lead{margin-top:24px;display:grid;gap:4px;max-width:40rem;margin-inline:auto}
.cf-story-strip .ss-lead p{font-size:clamp(1.125rem,1.5vw,1.375rem);line-height:1.4;font-weight:500;text-wrap:pretty}
.cf-story-strip .ss-punch{margin-top:20px;font-family:var(--font-display);font-weight:var(--display-weight,800);text-transform:var(--display-case,none);letter-spacing:-0.01em;font-size:clamp(1.3125rem,1.8vw,1.625rem);line-height:1.15}
.cf-story-strip .ss-panel{padding:clamp(40px,5.5vw,72px) 0}
.cf-story-strip .ss-tone-a{background:var(--surface)}
.cf-story-strip .ss-tone-b{background:color-mix(in oklch,var(--ink) 4%,var(--surface))}
.cf-story-strip .ss-stories > :last-child{padding-bottom:clamp(64px,8.5vw,120px)}
.cf-story-strip .ss-head{display:flex;flex-wrap:wrap;align-items:baseline;gap:4px 16px;margin-bottom:clamp(20px,2.5vw,32px)}
.cf-story-strip .ss-name{font-family:var(--font-display);font-weight:var(--display-weight,800);text-transform:var(--display-case,none);letter-spacing:-0.01em;font-size:clamp(1.3125rem,1.8vw,1.625rem);line-height:1.15;text-wrap:balance}
.cf-story-strip .ss-detail{font-size:.9375rem;line-height:1.4;font-weight:500;color:var(--muted);text-wrap:pretty}
.cf-story-strip .ss-row{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.25fr) minmax(0,1fr);grid-template-areas:'bp tr ap' 'bt . at';column-gap:clamp(24px,3vw,40px);align-items:start}
.cf-story-strip .ss-photo{margin:0;border-radius:12px;overflow:hidden;aspect-ratio:4/5;background:color-mix(in oklch,var(--ink) 8%,var(--surface))}
.cf-story-strip .ss-photo img{display:block;width:100%;height:100%;object-fit:cover;object-position:center 40%}
.cf-story-strip .ss-photo-before{grid-area:bp}
.cf-story-strip .ss-photo-after{grid-area:ap}
.cf-story-strip .ss-text{margin-top:20px;min-width:0}
.cf-story-strip .ss-text-before{grid-area:bt}
.cf-story-strip .ss-text-after{grid-area:at}
.cf-story-strip .ss-text.is-solo{background:var(--card);color:var(--ink);border:1px solid var(--card-border,oklch(from var(--ink) l c h / .12));border-radius:var(--card-radius,var(--radius,14px));box-shadow:var(--card-shadow,var(--shadow-sm));padding:clamp(20px,2.5vw,28px)}
.cf-story-strip .ss-tag{display:block;margin-bottom:8px;font-size:.875rem;line-height:1.2;font-weight:800;letter-spacing:.08em;text-transform:uppercase;color:var(--ink)}
.cf-story-strip .ss-badge{display:inline-grid;place-items:center;width:20px;height:20px;margin-inline-end:.5em;border-radius:999px;vertical-align:-0.38em;background:var(--success);color:var(--ss-badge-ink,#fff)}
.cf-story-strip .ss-start{font-size:clamp(1.0625rem,1.25vw,1.125rem);line-height:1.5;text-wrap:pretty}
.cf-story-strip .ss-result{font-family:var(--font-display);font-weight:var(--display-weight,800);text-transform:var(--display-case,none);letter-spacing:-0.01em;font-size:clamp(1.3125rem,1.8vw,1.625rem);line-height:1.2;text-wrap:balance}
.cf-story-strip .ss-track{grid-area:tr;align-self:stretch;display:grid;grid-template-rows:1fr 1fr;min-width:0}
.cf-story-strip .ss-span{grid-row:1;align-self:end;margin-bottom:20px;text-align:center;font-family:var(--font-display);font-weight:var(--display-weight,800);letter-spacing:-0.03em;font-size:clamp(2.5rem,4.2vw,3.75rem);line-height:1;font-variant-numeric:tabular-nums;color:var(--accent);text-wrap:balance}
.cf-story-strip .ss-rail{--rail-x:14px;--rail-pad:44px;grid-row:2;align-self:start;position:relative}
.cf-story-strip .ss-line{position:absolute;left:0;right:0;top:0;height:4px;margin-top:-2px;border-radius:999px;overflow:hidden;background:oklch(from var(--ink) l c h / .16)}
.cf-story-strip .ss-fill{position:absolute;inset:0;background:var(--accent-fill,var(--accent));transform:scaleX(0);transform-origin:left center;transition:transform var(--ss-draw) linear .15s}
.cf-story-strip .is-drawn .ss-fill{transform:scaleX(1)}
.cf-story-strip .ss-cap{position:absolute;top:0;width:16px;height:16px;border-radius:999px;transform:translate(-50%,-50%);background:var(--card);border:3px solid oklch(from var(--ink) l c h / .32);transition:background-color .25s ease,border-color .25s ease}
.cf-story-strip .ss-cap-start{left:0;transition-delay:.05s}
.cf-story-strip .ss-cap-end{left:100%;transition-delay:calc(.15s + var(--ss-draw))}
.cf-story-strip .is-drawn .ss-cap{background:var(--accent-fill,var(--accent));border-color:var(--accent-fill,var(--accent))}
.cf-story-strip .ss-steps{display:grid;grid-template-columns:repeat(var(--n),minmax(0,1fr))}
.cf-story-strip .ss-step{display:flex;flex-direction:column;align-items:center;text-align:center;padding:0 8px;min-width:0}
.cf-story-strip .ss-dot{--ss-at:calc(.15s + var(--ss-draw) * var(--pos));position:relative;display:grid;place-items:center;flex:none;width:22px;height:22px;margin-top:-11px;border-radius:999px;background:var(--card);border:2px solid oklch(from var(--ink) l c h / .32);color:var(--accent-fill-ink,var(--card));transition:background-color .25s ease var(--ss-at),border-color .25s ease var(--ss-at)}
.cf-story-strip .ss-dot svg{opacity:0;transition:opacity .2s ease var(--ss-at)}
.cf-story-strip .is-drawn .ss-dot{background:var(--accent-fill,var(--accent));border-color:var(--accent-fill,var(--accent));animation:ss-pop .3s cubic-bezier(.2,.7,.2,1) var(--ss-at) both}
.cf-story-strip .is-drawn .ss-dot svg{opacity:1}
.cf-story-strip .ss-step-text{margin-top:12px;display:grid;gap:2px;font-size:.9375rem;line-height:1.4;font-weight:500;text-wrap:balance}
.cf-story-strip .ss-when{font-size:.875rem;line-height:1.3;font-weight:800}
@keyframes ss-pop{from{transform:scale(.75)}to{transform:scale(1)}}
@media (min-width:961px){
.cf-story-strip .ss-row.p-a{grid-template-areas:'bt tr ap' '. . at'}
.cf-story-strip .ss-row.p-a .ss-text-before{margin-top:0;align-self:center}
.cf-story-strip .ss-row.p-b{grid-template-areas:'bp tr at' 'bt . .'}
.cf-story-strip .ss-row.p-b .ss-text-after{margin-top:0;align-self:center}
.cf-story-strip .ss-row.p-0{grid-template-areas:'bt tr at';align-items:center}
.cf-story-strip .ss-row.p-0 .ss-text{margin-top:0}
.cf-story-strip .ss-row.p-0 .ss-track{align-self:center;grid-template-rows:auto auto;padding-bottom:64px}
}
.cf-story-strip .ss-close{padding:clamp(56px,7vw,96px) 0}
.cf-story-strip .ss-close-inner{max-width:46rem;display:flex;flex-direction:column;align-items:center;text-align:center}
.cf-story-strip .ss-close-inner > :first-child{margin-top:0}
.cf-story-strip .ss-risk{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;text-wrap:balance}
.cf-story-strip .ss-risk-line{margin-top:24px;max-width:40rem;font-size:clamp(1.125rem,1.5vw,1.375rem);line-height:1.4;font-weight:500;text-wrap:pretty}
.cf-story-strip .ss-note{margin-top:12px;font-size:.9375rem;line-height:1.4;font-weight:600;color:var(--muted);text-wrap:pretty}
.cf-story-strip .ss-btn{--ss-bg:var(--button-bg,var(--cta));--ss-bg2:var(--button-bg-2,var(--cta-2));--ss-sh:var(--shadow,oklch(.22 .03 260));margin-top:32px;display:inline-flex;align-items:center;justify-content:center;min-height:72px;min-width:min(100%,21rem);max-width:100%;padding:12px 28px;border:0;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-wrap:balance;text-decoration:none;color:var(--button-ink,var(--cta-ink));text-shadow:var(--button-text-shadow,none);background:linear-gradient(oklch(from var(--ss-bg) calc(l + .04) c h),oklch(from var(--ss-bg2) calc(l - .02) c h));box-shadow:var(--button-shadow,inset 0 1px 0 oklch(from var(--ss-bg) calc(l + .14) c h / .7),inset 0 -3px 0 oklch(from var(--ss-bg) calc(l - .16) c h),0 1px 2px oklch(from var(--ss-sh) l c h / .3),0 8px 16px -6px oklch(from var(--ss-sh) l c h / .45));cursor:pointer;transition:transform .16s ease,box-shadow .16s ease,background .16s ease}
.cf-story-strip .ss-btn:hover:not(:disabled),.cf-story-strip .ss-btn.is-hover:not(:disabled){transform:translateY(-1px);background:linear-gradient(oklch(from var(--ss-bg) calc(l - .01) c h),oklch(from var(--ss-bg2) calc(l - .07) c h));box-shadow:inset 0 1px 0 oklch(from var(--ss-bg) calc(l + .12) c h / .7),inset 0 -3px 0 oklch(from var(--ss-bg) calc(l - .2) c h),0 1px 2px oklch(from var(--ss-sh) l c h / .32),0 12px 20px -8px oklch(from var(--ss-sh) l c h / .55)}
.cf-story-strip .ss-btn:active:not(:disabled),.cf-story-strip .ss-btn.is-active:not(:disabled){transform:translateY(1px);background:linear-gradient(oklch(from var(--ss-bg) calc(l - .04) c h),oklch(from var(--ss-bg2) calc(l - .08) c h));box-shadow:inset 0 2px 4px oklch(from var(--ss-bg) calc(l - .22) c h / .5),inset 0 -2px 0 oklch(from var(--ss-bg) calc(l - .16) c h),0 1px 2px oklch(from var(--ss-sh) l c h / .3)}
.cf-story-strip .ss-btn:focus-visible{outline:3px solid oklch(from var(--field-focus,var(--accent)) l c h / .55);outline-offset:3px}
.cf-story-strip .ss-btn:disabled{cursor:not-allowed;transform:none;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))}
@media (max-width:960px){
.cf-story-strip .ss-row{grid-template-columns:minmax(0,1fr);grid-template-areas:'bp' 'bt' 'tr' 'ap' 'at'}
.cf-story-strip .ss-photo{aspect-ratio:4/3}
.cf-story-strip .ss-text{margin-top:16px}
.cf-story-strip .ss-row > :first-child{margin-top:0}
.cf-story-strip .ss-track{display:block;margin:28px 0}
.cf-story-strip .ss-row > .ss-track:last-child{margin-bottom:0}
.cf-story-strip .ss-span{margin:0 0 20px;text-align:left}
.cf-story-strip .ss-rail{padding:20px 0 20px var(--rail-pad)}
.cf-story-strip .ss-line{left:calc(var(--rail-x) - 2px);right:auto;top:0;bottom:0;width:4px;height:auto;margin-top:0}
.cf-story-strip .ss-fill{transform:scaleY(0);transform-origin:center top}
.cf-story-strip .is-drawn .ss-fill{transform:scaleY(1)}
.cf-story-strip .ss-cap-start{left:var(--rail-x)}
.cf-story-strip .ss-cap-end{left:var(--rail-x);top:auto;bottom:0;transform:translate(-50%,50%)}
.cf-story-strip .ss-steps{display:flex;flex-direction:column;gap:20px}
.cf-story-strip .ss-step{position:relative;align-items:flex-start;text-align:left;padding:0}
.cf-story-strip .ss-dot{position:absolute;top:0;left:calc(var(--rail-x) - 11px - var(--rail-pad));margin-top:0}
.cf-story-strip .ss-step-text{margin-top:0;text-wrap:pretty}
.cf-story-strip .ss-btn{width:100%}
}
.cf-story-strip .is-still .ss-fill,.cf-story-strip .is-still .ss-cap,.cf-story-strip .is-still .ss-dot,.cf-story-strip .is-still .ss-dot svg{transition:none !important;animation:none !important}
@media (prefers-reduced-motion:reduce){
.cf-story-strip .ss-panel .ss-fill,.cf-story-strip .ss-panel .ss-cap,.cf-story-strip .ss-panel .ss-dot,.cf-story-strip .ss-panel .ss-dot svg{transition:none !important;animation:none !important}
.cf-story-strip .ss-btn{transition:none}
}
`;
pieces/proof/story-strip/specimen.tsx 77 lines
import __studioImage11378d94 from "../assets/6bd077f60e0b97c2.webp";
import __studioImage6a85d5b6 from "../assets/893459b65668c5af.webp";
import __studioImagec8890fe0 from "../assets/e552a958a619d6d8.webp";
// Specimen: Northpaw dog training (fictional), three dogs told before to after with a risk-first close.
// Biscuit has both photos, Juno only an after photo, Pepper is text only: the strip shows exactly what is supplied.
import React from "react";
import { StoryStrip } from "../story-strip";
import type { StoryStripState } from "../story-strip";
import defaults from "../../studio-defaults.json";
import { slot } from "../../slots";
import nature from "../../fx/backdrops/nature";
export const states = ["default", "hover", "active", "disabled"];
export default function StoryStripSpecimen({ state = "default" }: { state?: StoryStripState }) {
const sample = defaults.sample;
return (
<StoryStrip
state={state}
headline="From chaos on the leash to a dog that listens"
highlight="a dog that listens"
lead={[
"Biscuit pulled. Juno jumped. Pepper barked at everything.",
"Their owners gave the Northpaw plan ten minutes a day.",
]}
punch="Calm."
sceneImage={slot("scene", nature)}
stories={[
{
name: "Biscuit",
detail: "2-year-old Lab mix · with Maya R., Denver",
timeframe: "6 weeks",
start: "Pulled so hard on walks that Maya stopped taking him out.",
result: "Two calm walks a day. The leash stays slack.",
beforeImage: __studioImage11378d94,
beforeAlt: "Biscuit, a yellow Lab mix, pulling hard on a tight leash on the sidewalk",
afterImage: __studioImage6a85d5b6,
afterAlt: "Biscuit walking calmly on a loose leash in the park",
milestones: [
{ when: "Week 1", label: "Stops and waits at every curb" },
{ when: "Week 3", label: "Loose leash for a full block" },
{ when: "Week 5", label: "Walks past other dogs" },
],
},
{
name: "Juno",
detail: "1-year-old collie mix · with Theo and Ana K., Portland",
timeframe: "4 weeks",
start: "Jumped on every guest the second the front door opened.",
result: "Guests walk in. Juno stays on her mat.",
afterImage: __studioImagec8890fe0,
afterAlt: "Juno, a black-and-white collie mix, lying calmly on her mat while a guest comes in",
milestones: [
{ when: "Week 1", label: "Learns to go to her mat" },
{ when: "Week 2", label: "Holds it through the doorbell" },
{ when: "Week 4", label: "Greets guests with four paws down" },
],
},
{
name: "Pepper",
detail: "5-year-old terrier mix · with Dana L., Austin",
timeframe: "3 weeks",
start: "Barked at every bike, bus and leaf that passed the window.",
result: "Afternoons are quiet now.",
milestones: [
{ when: "Week 1", label: "Stays quiet for one passing bike" },
{ when: "Week 2", label: "Settles on cue at the window" },
],
},
]}
riskHeadline="Try Northpaw with your dog for 30 days"
riskLine={`Ten minutes a day. If your walks aren't calmer, ask for every cent back. That's our ${sample.guarantee}.`}
actionLabel={`Start Northpaw for ${sample.price}`}
actionNote={sample.note}
/>
);
}
| Name | Type | Details |
|---|---|---|
headline OptionalStoryStrip |
React.ReactNode |
Default "Where they started, and where they are now"
|
highlight OptionalStoryStrip |
string |
|
lead OptionalStoryStrip |
string[] |
Default []
|
punch OptionalStoryStrip |
string |
Default ""
|
stories OptionalStoryStrip |
Story[] |
Default []
|
sceneImage OptionalStoryStrip |
string |
Default nature
|
riskHeadline OptionalStoryStrip |
string |
Default ""
|
riskLine OptionalStoryStrip |
string |
Default ""
|
actionLabel OptionalStoryStrip |
string |
Default "Start your own story"
|
actionNote OptionalStoryStrip |
string |
Default ""
|
href OptionalStoryStrip |
string |
|
onAction OptionalStoryStrip |
() => void |
|
actionDisabled OptionalStoryStrip |
boolean |
Default false
|
state OptionalStoryStrip |
StoryStripState |
Default "default"
|
copy OptionalStoryStrip |
Partial<StoryStripCopy> |
|
className OptionalStoryStrip |
string |
Theme roles it reads
Set by the theme bar, a preset or your brand. Colours come from the base tokens (--surface, --ink, --cta…) every piece uses.
--button-bg--button-bg-2--button-case--button-font--button-ink--button-radius--button-shadow--button-text-shadow--button-weight- Main CTA button: background, ink, font, weight, case, radius and shadow.
--button-2-bg--button-2-ink--button-2-shadow- Secondary button.
--card-border--card-radius--card-shadow- Cards and panels: radius, border and shadow.
--display-case--display-tracking--display-weight- Headlines: weight, letter case and tracking.
--field-focus- Form inputs: background, ink, border, radius and focus colour.
--marker- The highlighter colour behind key phrases.
Image slots
Filled from the brand’s images; the specimen ships its own defaults.
scene- A wide atmosphere photo behind or beside the copy.
-
6bd077f60e0b97c2.webp
image/webp · 120 KB
-
8276864f4b8e6ac1.webp
image/webp · 47 KB
-
893459b65668c5af.webp
image/webp · 54.3 KB
-
b77916eca54aa689.webp
image/webp · 8.32 KB
-
d435db6662febfcf.webp
image/webp · 10 KB
-
e552a958a619d6d8.webp
image/webp · 123 KB
-
f0a5d3e1e61804ba.webp
image/webp · 11.6 KB