Proof Numbers Board 1
The proof beat (or a one-number stat-slam hook): one to four sourced numbers stand huge on the field as a scoreboard, each counting up from zero with its unit and what it measures, thin rules between them and the source under them in landscape; for sales videos, VSLs and video ads.
Use it in a prompt
Use the video/proof-numbers-board video frame from the FunnelDNA library in my brand (landscape and vertical). Follow the video skill. Ask me for the script facts, voice and images 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/video/proof-numbers-board.tsx. - Import it and pass your copy and images (Props tab):
import { ProofNumbersBoard } from "@/components/funneldna/video/proof-numbers-board"
It restyles from the theme tokens on any wrapper (Theme tab). The specimen source is a complete working example.
pieces/video/proof-numbers-board/component.tsx 315 lines
// When to use: The proof beat (or a one-number stat-slam hook): one to four sourced numbers stand huge on the field as a scoreboard, each counting up from zero with its unit and what it measures, thin rules between them and the source under them in landscape; for sales videos, VSLs and video ads.
import * as React from "react"
import noise from "../fx/textures/noise"
import type { BackdropTreatment } from "../fx/fx"
import {
CountUp, HOLD, IN_OUT, Rise, SafeArea, StageField, StageLight, StagePhoto, T, VIDEO_FORMATS, VideoStage, cue, display, ok, progress,
useFitText, useHeld, useStage, useWords,
type VideoFormat, type VideoMeta, type Word,
} from "../fx/video-kit"
export const video = { fps: 30, durationInFrames: 210, formats: ["landscape", "vertical"], poster: 200 } satisfies VideoMeta
/** One number on the board. */
export type ProofStat = {
/** The figure as stated ("9 in 10", "14", "4.8"); its first number counts up from zero. Words after it ("in 10") are set at unit size beside it. */
value: string
/** Unit set beside the figure ("years", "clinics"); optional. */
unit?: string
/** What the number measures, three or four words ("seen within 48 hours"). */
measure?: string
}
export type ProofNumbersBoardProps = {
format?: VideoFormat
durationInFrames?: number
/** One to four real, sourced numbers. Empty by default: without a stat the frame draws no board and no text. */
stats?: ProofStat[]
/** Where the numbers come from; rises in under the board once every number has landed (landscape only; phones drop it). Empty draws nothing. */
source?: string
/** A phrase inside one stat's measure line that is set in the heavy weight and beats once in scale after the board lands. */
highlight?: string
/** Index of the number that gets one scale beat as it lands (a single stat always slams). */
featured?: number
/** Voice timings for the scene; each number lands when its figure (or its measure line) is spoken. */
words?: Word[]
/** Scene photo behind the board (pass slot("scene", …)); without one the band carries a drifting texture under a stage light. */
scene?: string
/** How the photo takes the theme: natural (its own colours under a band scrim, default) or duotone (mapped to the tokens). */
treatment?: BackdropTreatment
/** Photo focal point (CSS object-position). */
focus?: string
}
/**
* Proof: the numbers stand straight on the field, no boxes. Landscape sets them as columns across the frame, 9:16 stacks
* them centred at about 200px with their units at 0.55 of the figure; thin rules draw on between them as each arrives,
* every figure counts up at full display size, the source lands under the board in landscape, and one phrase, set heavy
* in the field ink, beats once; the whole board pushes in slowly until the final hold.
*/
export function ProofNumbersBoard({
format = "landscape",
durationInFrames = video.durationInFrames,
stats = [],
source = "",
highlight = "",
featured = 0,
words,
scene = "",
treatment = "natural",
focus,
}: ProofNumbersBoardProps) {
const f = useHeld(durationInFrames)
const { text, u, width, height, format: fmt, portrait } = useStage()
const list = stats.filter((s) => s && typeof s.value === "string" && s.value.trim()).slice(0, 4)
const n = list.length
const single = n === 1
const src = source.trim()
const timed = useWords(words?.map((w) => w.w).join(" ") ?? "", words, durationInFrames)
// The board's box in stage px: landscape the text column (a little narrower for one stat), 9:16 the title-safe width.
// Its height is the text area less the room the slow push needs, so nothing ever reaches the caption band.
const safe = VIDEO_FORMATS[fmt].safe
const boardW = portrait ? width / u - safe.left - safe.right : ((width - text.left - text.right) / u) * (single ? 0.82 : 1)
const textH = (height - text.top - text.bottom) / u
const p = planBoard(list, portrait, boardW, textH * (1 - PUSH * 2) - 8, src)
// Every figure is fitted in the theme's own display face; the board takes the smallest, so one size sets the whole board.
const r0 = React.useRef<HTMLSpanElement>(null)
const r1 = React.useRef<HTMLSpanElement>(null)
const r2 = React.useRef<HTMLSpanElement>(null)
const r3 = React.useRef<HTMLSpanElement>(null)
const refs = [r0, r1, r2, r3]
const fitted = [useNumberFit(r0, p.stats[0], p, u), useNumberFit(r1, p.stats[1], p, u), useNumberFit(r2, p.stats[2], p, u), useNumberFit(r3, p.stats[3], p, u)]
const num = n ? Math.min(...fitted.slice(0, n)) : 72 * u
const numS = num / u
// Schedule: numbers stagger in across the first half of the scene (or on their spoken words), each count runs 24
// frames (40 for a single stat slam), the source follows, then the emphasis beat; everything finishes before the final hold.
const countDur = single ? 40 : 24
const step = n > 1 ? Math.round(Math.min(32, Math.max(10, (durationInFrames * 0.5 - 6 - countDur) / (n - 1)))) : 0
const latest = Math.max(6, durationInFrames - HOLD - countDur - 30)
const statAt: number[] = []
list.forEach((s, i) => {
const base = 6 + i * step
const heard = words?.length ? cue(timed, s.value, cue(timed, s.measure, base)) : base
statAt.push(Math.max(i ? statAt[i - 1] + 6 : 0, Math.min(heard, latest)))
})
const landed = (statAt[n - 1] ?? 0) + countDur
const sourceAt = landed + 6
const spoken = words?.length ? Math.max(landed + 4, cue(timed, highlight, sourceAt + 12)) : sourceAt + 12
// The phrase beats 100 → 106 → 100% once; it settles before the final hold.
const emphAt = Math.min(spoken, durationInFrames - HOLD - 16)
const emph = 1 + 0.06 * (progress(f, emphAt, emphAt + 6) - progress(f, emphAt + 6, emphAt + 14))
// A slow push across the scene keeps the frame alive once the board has landed (frozen with the held frame).
const push = 1 + PUSH * progress(f, 0, durationInFrames - HOLD, (t) => t)
let hit: { stat: number; range: [number, number] } | null = null
if (highlight.trim()) for (let i = 0; i < n && !hit; i++) {
const r = findPhrase(list[i].measure ?? "", highlight)
if (r) hit = { stat: i, range: r }
}
const feat = single ? -1 : Math.min(Math.max(0, Math.round(featured)), n - 1)
const rule = ok("--band-ink", 0, 0.38)
const measureLine = (s: ProofStat, i: number) => {
const ws = (s.measure ?? "").split(/\s+/).filter(Boolean)
const r = hit && hit.stat === i ? hit.range : null
const out: React.ReactNode[] = []
ws.forEach((w, j) => {
out.push(r && j >= r[0] && j < r[1]
? <span key={j} style={{ display: "inline-block", fontWeight: 800, color: T.bandInk, transform: `scale(${emph})`, transformOrigin: "50% 70%" }}>{w}</span>
: <React.Fragment key={j}>{w}</React.Fragment>)
if (j < ws.length - 1) out.push(" ")
})
return out
}
const stat = (s: ProofStat, i: number) => {
const a = statAt[i]
const ps = p.stats[i]
const after = (d: number): React.CSSProperties => ({
opacity: progress(f, a + d, a + d + 8), transform: `translateY(${(1 - progress(f, a + d, a + d + 12)) * 16 * u}px)`,
})
// The slam: a single figure sits 4% large while it counts, then settles; the featured one beats once as it lands.
const settle = single ? 1 + 0.04 * (1 - progress(f, a + countDur - 8, a + countDur + 6)) : 1
const beat = i === feat ? 1 + 0.06 * (progress(f, a + countDur, a + countDur + 6) - progress(f, a + countDur + 6, a + countDur + 14)) : 1
const unitSize = unitFor(numS, ps.sec, p.colW, p.unitFloor, p.unit) * u
const measure = s.measure?.trim()
return (
<div key={"s" + i} style={{
display: "flex", flexDirection: "column", alignItems: "center", textAlign: "center", minWidth: 0, color: T.bandInk,
opacity: progress(f, a, a + 8), transform: `translateY(${(1 - progress(f, a, a + 14)) * (single ? 50 : 30) * u}px)`,
}}>
<div style={{
display: "flex", flexDirection: p.beside ? "row" : "column", alignItems: p.beside ? "baseline" : "center", justifyContent: "center",
columnGap: num * GAP, rowGap: UNIT_GAP * u, maxWidth: "100%",
}}>
<span ref={refs[i]} style={{
...display(num, { lineHeight: 1 }), display: "inline-grid", whiteSpace: "nowrap", fontVariantNumeric: "tabular-nums lining-nums",
transform: `scale(${settle * beat})`, transformOrigin: "50% 100%",
}}>
<span aria-hidden style={{ gridArea: "1 / 1", visibility: "hidden" }}>{ps.head}</span>
<span style={{ gridArea: "1 / 1" }}>{ps.pre}{ps.first && <CountUp value={ps.first} at={a} dur={countDur} />}{ps.suffix}</span>
</span>
{ps.sec && (
<span style={{ ...display(unitSize, { lineHeight: 1 }), display: "inline-block", whiteSpace: "nowrap", ...after(6) }}>{ps.sec}</span>
)}
</div>
{measure && (
<div style={{
marginTop: p.inner * u, fontSize: p.measure * u, fontWeight: 600, lineHeight: 1.2, textWrap: "balance", maxWidth: "100%", ...after(8),
}}>{measureLine(s, i)}</div>
)}
</div>
)
}
// Rule i sits after stat i and draws on from its centre as the next number arrives.
const drawn = (i: number) => progress(f, statAt[i + 1] - 6, statAt[i + 1] + 8, IN_OUT)
const board: React.ReactNode[] = []
list.forEach((s, i) => {
board.push(stat(s, i))
if (i < n - 1) board.push(portrait
? <div key={"r" + i} aria-hidden style={{ width: RULE_W_P * u, height: RULE * u, margin: `${p.gap * u}px 0`, background: rule, transform: `scaleX(${drawn(i)})` }} />
: <div key={"r" + i} aria-hidden style={{ width: RULE * u, alignSelf: "stretch", background: rule, transform: `scaleY(${drawn(i)})` }} />)
})
return (
<VideoStage format={format} tone="band">
{scene
? <StagePhoto src={scene} frame={f} dur={durationInFrames - HOLD} push={[1.03, 1.1]} treatment={treatment} tone="band" side="full" position={focus} />
: <>
<StageField tone="band" texture={noise} opacity={0.16} frame={f} />
<StageLight x="50%" strength={0.26} tone="band-ink" floor={false} />
</>}
{n > 0 && (
<SafeArea inset={portrait ? { left: safe.left * u, right: safe.right * u } : undefined} style={{ justifyContent: "center", alignItems: "center" }}>
<div style={{ position: "relative", zIndex: 1, width: boardW * u, transform: `scale(${push})`, transformOrigin: "50% 50%" }}>
{portrait
? <div style={{ display: "flex", flexDirection: "column", alignItems: "center" }}>{board}</div>
: <div style={{
display: "grid", gridTemplateColumns: Array(n).fill("minmax(0, 1fr)").join(` ${RULE * u}px `), columnGap: p.gap * u, alignItems: "start",
}}>{board}</div>}
{src && p.srcShow && (
<Rise at={sourceAt} y={16} dur={12} style={{ marginTop: SOURCE_GAP * u }}>
<p style={{ margin: 0, fontSize: SOURCE * u, fontWeight: 500, lineHeight: 1.3, color: T.bandInk, textAlign: "center", textWrap: "balance" }}>{src}</p>
</Rise>
)}
</div>
</SafeArea>
)}
</VideoStage>
)
}
export default ProofNumbersBoard
/** Unit size as a share of its figure: landscape half the figure, phones a little more so the unit reads at arm's length. */
const UNIT_L = 0.5
const UNIT_P = 0.55
/** Gap between a figure and the unit beside it (share of the figure), and above a unit set under it (stage px). */
const GAP = 0.12
const UNIT_GAP = 6
/** Rule thickness between numbers, and the length of the rules between stacked numbers on phones (stage px). */
const RULE = 2
const RULE_W_P = 280
/** Source line size and its gap under the board (stage px), landscape only; phones drop the source. */
const SOURCE = 34
const SOURCE_GAP = 44
/** The slow push across the scene, as a share of the board's size. */
const PUSH = 0.015
type Preset = {
/** Largest figure size, the size it may shrink to for height, the measure size and unit floor (stage px). */
numMax: number; numFloor: number; measure: number; unitFloor: number
/** Unit size as a share of the figure. */
unit: number
/** Gap from figure to measure line, and the gap on each side of a rule (stage px). */
inner: number; gap: number
}
type PlanStat = { head: string; pre: string; first: string; suffix: string; sec: string; lines: number }
type Plan = Preset & { colW: number; num: number; beside: boolean; stats: PlanStat[]; srcShow: boolean }
/** The board per format and count, in stage px. Measure lines never go under 48px; phones set figures near 200px. */
function preset(n: number, portrait: boolean): Preset {
if (portrait) {
if (n <= 1) return { numMax: 300, numFloor: 200, measure: 56, unitFloor: 72, unit: UNIT_P, inner: 28, gap: 0 }
if (n === 2) return { numMax: 230, numFloor: 180, measure: 52, unitFloor: 64, unit: UNIT_P, inner: 20, gap: 40 }
if (n === 3) return { numMax: 200, numFloor: 164, measure: 48, unitFloor: 56, unit: UNIT_P, inner: 16, gap: 28 }
return { numMax: 170, numFloor: 120, measure: 48, unitFloor: 48, unit: UNIT_P, inner: 12, gap: 18 }
}
if (n <= 1) return { numMax: 320, numFloor: 160, measure: 60, unitFloor: 64, unit: UNIT_L, inner: 28, gap: 0 }
if (n === 2) return { numMax: 240, numFloor: 140, measure: 54, unitFloor: 56, unit: UNIT_L, inner: 24, gap: 64 }
if (n === 3) return { numMax: 200, numFloor: 130, measure: 48, unitFloor: 52, unit: UNIT_L, inner: 20, gap: 48 }
return { numMax: 170, numFloor: 120, measure: 48, unitFloor: 48, unit: UNIT_L, inner: 18, gap: 36 }
}
/** Fits the board into height `H`: the figure comes down toward its floor (units follow it, measure lines keep their size). */
function planBoard(list: ProofStat[], portrait: boolean, W: number, H: number, src: string): Plan {
const n = list.length
const c = preset(n, portrait)
const colW = portrait ? W : (W - (n - 1) * (2 * c.gap + RULE)) / Math.max(1, n)
const stats: PlanStat[] = list.map((s) => {
const sp = splitFigure(s.value.trim())
const measure = s.measure?.trim() ?? ""
return { ...sp, sec: [sp.tail, s.unit?.trim()].filter(Boolean).join(" "), lines: measure ? Math.ceil((measure.length * 0.53 * c.measure) / colW) : 0 }
})
const beside = (num: number) => stats.every((s) => !s.sec || emWidth(s.head) * num + GAP * num + secWidth(num, s.sec, colW, c.unitFloor, c.unit) <= colW)
const colH = (num: number, s: PlanStat, side: boolean) =>
num + (s.sec && !side ? UNIT_GAP + unitFor(num, s.sec, colW, c.unitFloor, c.unit) * 1.05 : 0) + (s.lines ? c.inner + s.lines * c.measure * 1.2 : 0)
const boardH = (num: number) => {
const side = beside(num), hs = stats.map((s) => colH(num, s, side))
return portrait ? hs.reduce((a, b) => a + b, 0) + (n - 1) * (2 * c.gap + RULE) : Math.max(0, ...hs)
}
// The source is landscape fine print at 34px; on phones it could not hold 44px on one line, so it is dropped.
const srcLines = !portrait && src ? Math.ceil((src.length * 0.52 * SOURCE) / W) : 0
const srcH = srcLines ? SOURCE_GAP + srcLines * SOURCE * 1.3 : 0
let num = c.numMax
while (boardH(num) + srcH > H && num > c.numFloor) num -= 4
return { ...c, colW, num, beside: beside(num), stats, srcShow: srcLines > 0 }
}
/** Unit size (stage px) for a figure of size `num`: its share of the figure, narrowed to its column, never under the floor. */
function unitFor(num: number, sec: string, colW: number, floor: number, ratio: number) {
return sec ? Math.max(floor, Math.min(num * ratio, colW / (sec.length * 0.6))) : 0
}
const secWidth = (num: number, sec: string, colW: number, floor: number, ratio: number) => sec.length * 0.58 * unitFor(num, sec, colW, floor, ratio)
/** Rough width of a figure in em of the display face (layout only; the fit itself is measured). */
function emWidth(value: string) {
let w = 0
for (const ch of value) w += ch >= "0" && ch <= "9" ? 0.62 : ch === " " ? 0.26 : "%$".includes(ch) ? 0.78 : ch.toLowerCase() !== ch.toUpperCase() ? 0.6 : 0.36
return w
}
/** One figure fitted to its column (less the unit beside it), measured in the theme's display face. */
function useNumberFit(ref: React.RefObject<HTMLElement | null>, s: PlanStat | undefined, p: Plan, u: number) {
const head = s?.head ?? ""
const side = s?.sec && p.beside ? secWidth(p.num, s.sec, p.colW, p.unitFloor, p.unit) + GAP * p.num : 0
const boxW = Math.max(120, p.colW - side)
const guess = Math.max(72, Math.min(p.num, boxW / Math.max(1, emWidth(head))))
return useFitText(ref, head, { boxW: boxW * u, boxH: p.num * 1.12 * u, guess: guess * u, max: p.num * u, min: 72 * u, lines: [1] })
}
/**
* The figure split around its first number: "9 in 10" → head "9" (pre "", first "9", suffix "") and tail "in 10";
* "98%" → head "98%". Only `first` counts up; the tail is set at unit size beside the figure.
*/
function splitFigure(value: string) {
const m = /\d[\d,]*(\.\d+)?/.exec(value)
if (!m) return { head: value, pre: value, first: "", suffix: "", tail: "" }
const pre = value.slice(0, m.index), rest = value.slice(m.index + m[0].length)
const suffix = /^\S*/.exec(rest)?.[0] ?? ""
return { head: pre + m[0] + suffix, pre, first: m[0], suffix, tail: rest.slice(suffix.length).trim() }
}
const norm = (s: string) => s.toLowerCase().replace(/[^a-z0-9$%']/g, "")
/** Word range [start, end) of `phrase` inside `text`, or null. */
function findPhrase(text: string, phrase: string): [number, number] | null {
const ws = text.split(/\s+/).filter(Boolean).map(norm)
const ph = phrase.split(/\s+/).filter(Boolean).map(norm)
if (!ph.length) return null
for (let i = 0; i + ph.length <= ws.length; i++) if (ph.every((x, k) => ws[i + k] === x)) return [i, i + ph.length]
return null
}
pieces/video/proof-numbers-board/specimen.tsx 42 lines
import __studioImage96fc618e from "../assets/689a39ff6bc5c650.webp";
import * as React from "react"
import { slot } from "../../slots"
import { VideoPreview, type VideoFormat } from "../../fx/video-kit"
import { ProofNumbersBoard, video, type ProofNumbersBoardProps } from "../proof-numbers-board"
export const states = ["landscape", "vertical"]
/** First number readable mid-count, the last number mid-count, all landed with the source and the emphasis beat, final hold. */
export const keyframes = [20, 82, 124, 205]
// The designed scene: an empty, bright clinic reception (no people, no text), kept in its natural colour under a band scrim; the specimen swaps in the brand's scene slot.
const reception = __studioImage96fc618e
// Fictional sample: Ridgeway Physio, a three-clinic physiotherapy practice. Numbers and source are invented sample content.
export const sample: ProofNumbersBoardProps = {
stats: [
{ value: "9 in 10", measure: "seen within 48 hours" },
{ value: "14", unit: "years", measure: "treating sports injuries" },
{ value: "3", unit: "clinics", measure: "across the city" },
],
source: "Ridgeway Physio booking records, Jan–Dec 2025",
highlight: "within 48 hours",
featured: 0,
scene: reception,
treatment: "natural",
focus: "50% 45%",
}
/** The sample business in its own colours and type (sample-palettes.md: orange-pop · grotesk-clean); Original and every preset stay one click away. */
export const sampleBrand = {
name: "Ridgeway Physio",
theme: "light",
background: "#ffffff",
colors: ["#12406b", "#0e8f6e"],
fonts: ["Plus Jakarta Sans", "Inter"],
button: "soft-caps",
band: "#ffa04d",
}
export default function ProofNumbersBoardSpecimen({ state = "landscape" }: { state?: string }) {
return <VideoPreview component={ProofNumbersBoard} props={{ ...sample, scene: slot("scene", reception) }} format={state as VideoFormat} meta={video} />
}
| Name | Type | Details |
|---|---|---|
format OptionalProofNumbersBoard |
VideoFormat |
Default "landscape"
|
durationInFrames OptionalProofNumbersBoard |
number |
Default video.durationInFrames
|
stats OptionalProofNumbersBoard |
ProofStat[] |
Default []
|
source OptionalProofNumbersBoard |
string |
Default ""
|
highlight OptionalProofNumbersBoard |
string |
Default ""
|
featured OptionalProofNumbersBoard |
number |
Default 0
|
words OptionalProofNumbersBoard |
Word[] |
|
scene OptionalProofNumbersBoard |
string |
Default ""
|
treatment OptionalProofNumbersBoard |
BackdropTreatment |
Default "natural"
|
focus OptionalProofNumbersBoard |
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.
None listed in this pack.
Image slots
Filled from the brand’s images; the specimen ships its own defaults.
scene- A wide atmosphere photo behind or beside the copy.
-
689a39ff6bc5c650.webp
image/webp · 54.5 KB
-
bec2a41897a3364d.webp
image/webp · 51.2 KB