Cards & content / Accordions

Customer Story Accordion

Stacked gray rounded-3xl rows, each with a rounded-square logo, a small company label, a bold story title and a circular chevron button. The open row reveals a large grainy photo with a bottom scrim, white metric pills (value plus muted unit) and a 'Read the story' pill, plus a 'Built with' line of features.

Rebuilt from cal.com in the Warm Paper Calendar style.

npx shadcn@latest add https://justyoink.it/r/warm-paper-calendar/blocks/customer-story-accordion.json

Looks exactly like cal.com: brings its fonts and colours, namespaced so your own theme stays untouched.

Images4 in this component. Swap any for a library image or one of your own.All images in this style →

Choose an image

Image

Loading…

Usage

Props: heading, ctaLabel, and stories (company, title, logo letter, logoClass, metrics, built, image URL). Click a row to expand it; the first is open by default and the others collapse.

components/customer-story-accordion.tsx
"use client";

import { useEffect, useLayoutEffect, useRef, type CSSProperties } from "react";
import { useState } from "react";

type Story = {
  company: string;
  title: string;
  logo: string;
  logoClass: string;
  metrics: { value: string; unit: string }[];
  built: string;
  image: string;
};

const DEFAULT_STORIES: Story[] = [
  { company: "Northwind", title: "Northwind runs its whole company on Plannr, from sales to support.", logo: "n.", logoClass: "bg-[#d6cdfa] text-ink-deep", metrics: [{ value: "From $20M to $90M", unit: "ARR" }, { value: "From 9s to <2s", unit: "page loads" }, { value: "4,000+", unit: "hours saved per week" }], built: "Smart routing, Round-robin, Intake forms, Workflows, Instant calls", image: "https://yoink-app.fly.dev/stock/event-1.jpg" },
  { company: "Altura Labs", title: "Altura Labs powers millions of voice sessions on the Plannr API.", logo: "A", logoClass: "bg-canvas text-ink-deep shadow-ring-raised", metrics: [{ value: "2.1M", unit: "calls booked" }, { value: "99.99%", unit: "uptime" }], built: "Booking API, Webhooks, Round-robin", image: "https://yoink-app.fly.dev/stock/people-5.jpg" },
  { company: "Kitefield", title: "Kitefield balances demo bookings across 30+ countries.", logo: "K", logoClass: "bg-canvas text-ink-deep shadow-ring-raised", metrics: [{ value: "30+", unit: "countries" }, { value: "3x", unit: "faster handoff" }], built: "Routing forms, Workflows, Team pages", image: "https://yoink-app.fly.dev/stock/city-5.jpg" },
  { company: "Lumen Health", title: "Lumen Health runs critical clinic scheduling across regions.", logo: "L", logoClass: "bg-[#5f7a70] text-canvas", metrics: [{ value: "120", unit: "clinics" }, { value: "-38%", unit: "no-shows" }], built: "Reminders, Availability, Instant meetings", image: "https://yoink-app.fly.dev/stock/interior-1.jpg" },
];

export default function CustomerStoryAccordion({
  heading = "Loved by teams that schedule at scale.",
  ctaLabel = "Read stories",
  stories = DEFAULT_STORIES,
}: {
  heading?: string;
  ctaLabel?: string;
  stories?: Story[];
}) {
  const [open, setOpen] = useState(0);
  const chev = (up: boolean) => (
    <svg viewBox="0 0 16 16" className={`h-3 w-3 transition-transform duration-300 ${up ? "rotate-180" : ""}`} fill="none" stroke="currentColor" strokeWidth="1.6" strokeLinecap="round" strokeLinejoin="round" aria-hidden="true"><path d="M4 6l4 4 4-4" /></svg>
  );
  return (
    <section className="bg-canvas px-4 py-16 font-sans text-ink md:px-[74px]">
      <div className="mx-auto max-w-[1292px]">
        <h2 className="max-w-xl font-display text-h1 text-ink-deep">{heading}</h2>
        <button className="mt-6 inline-flex items-center gap-1 rounded-lg bg-canvas px-4 py-2 text-ui shadow-ring-raised transition-colors duration-200 hover:bg-panel focus-visible:outline focus-visible:outline-2 focus-visible:outline-ink">
          {ctaLabel}
          <svg viewBox="0 0 16 16" className="h-3 w-3" fill="none" stroke="currentColor" strokeWidth="1.6" aria-hidden="true"><path d="M6 4l4 4-4 4" /></svg>
        </button>
        <div className="mt-14 flex flex-col gap-3">
          {stories.map((s, i) => {
            const isOpen = open === i;
            return (
              <div key={s.company} className="relative overflow-hidden rounded-[24px] bg-panel p-4">
                {isOpen && (
                  <div className="absolute left-1/2 top-0 h-[3px] w-6 -translate-x-1/2 overflow-hidden rounded-full bg-hairline-strong">
                    <div className="h-full w-full origin-left animate-[appear_6s_linear] bg-ink" />
                  </div>
                )}
                <button onClick={() => setOpen(isOpen ? -1 : i)} aria-expanded={isOpen} className="flex w-full items-center gap-5 text-left focus-visible:outline focus-visible:outline-2 focus-visible:outline-ink">
                  <span className={`flex h-12 w-12 shrink-0 items-center justify-center rounded-[14px] font-display text-lg font-semibold ${s.logoClass}`}>{s.logo}</span>
                  <span className="min-w-0 flex-1">
                    <span className="block text-caption text-muted">{s.company}</span>
                    <span className="block font-display text-lead font-semibold text-ink-deep">{s.title}</span>
                  </span>
                  <span className="flex h-10 w-10 shrink-0 items-center justify-center rounded-pill bg-canvas text-ink shadow-ring-raised">{chev(isOpen)}</span>
                </button>
                {isOpen && (
                  <div className="mt-4">
                    <div className="relative aspect-[16/10] overflow-hidden rounded-[20px] bg-ink-deep md:aspect-[1260/551]">
                      <img src={s.image} alt={s.company + " story"} width={1260} height={551} loading="lazy" className="h-full w-full object-cover" />
                      <div className="absolute inset-0 bg-image-scrim" />
                      <div className="absolute inset-0 shadow-[inset_0_0_60px_rgba(60,30,10,0.45)]" />
                      <Grain opacity={0.2} blend="overlay" />
                      <div className="absolute inset-x-4 bottom-4 flex flex-wrap items-center gap-2">
                        {s.metrics.map((m) => (
                          <span key={m.value} className="rounded-pill bg-canvas px-3.5 py-2 text-ui font-semibold text-ink-deep">
                            {m.value} <span className="ml-1 font-normal text-muted">{m.unit}</span>
                          </span>
                        ))}
                        <a href="#" className="ml-auto inline-flex items-center gap-1 rounded-pill bg-canvas px-3.5 py-2 text-ui text-ink-deep transition-colors duration-200 hover:bg-panel">
                          Read the story
                          <svg viewBox="0 0 16 16" className="h-3 w-3" fill="none" stroke="currentColor" strokeWidth="1.6" aria-hidden="true"><path d="M6 4l4 4-4 4" /></svg>
                        </a>
                      </div>
                    </div>
                    <p className="mt-3 px-1 text-ui text-muted"><strong className="font-semibold text-ink-deep">Built with</strong> {s.built}</p>
                  </div>
                )}
              </div>
            );
          })}
        </div>
      </div>
    </section>
  );
}

// ---- Yoink motion (inlined, no dependencies): Grain ----

const useYkLayoutEffect = typeof window === "undefined" ? useEffect : useLayoutEffect;

// Background and overlay layers sit inside their parent: make sure it can hold them.
function ykPrepareParent(el: HTMLElement | null, isolate = false) {
  const p = el?.parentElement;
  if (!p) return;
  const cs = getComputedStyle(p);
  if (cs.position === "static") p.style.position = "relative";
  if (isolate && cs.isolation !== "isolate" && cs.zIndex === "auto") p.style.isolation = "isolate";
}

const YK_GRAIN_CSS = `@keyframes yk-grain{0%{transform:translate(0,0)}25%{transform:translate(-3%,2%)}50%{transform:translate(2%,-3%)}75%{transform:translate(-2%,-1%)}100%{transform:translate(1%,3%)}}
@media (prefers-reduced-motion:reduce){[data-yk-grain] *{animation:none!important}}`;
const YK_NOISE = `url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.5 0 0 0 0 0.5 0 0 0 0 0.5 0 0 0 1.6 -0.3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E")`;

/** A film-grain texture over a section (adds tactile depth to flat colour or gradients). */
function Grain({
  opacity = 0.12,
  blend = "overlay",
  animated = false,
  className,
  style,
}: {
  opacity?: number;
  blend?: CSSProperties["mixBlendMode"];
  animated?: boolean;
  className?: string;
  style?: CSSProperties;
}) {
  const ref = useRef<HTMLDivElement>(null);
  useYkLayoutEffect(() => ykPrepareParent(ref.current), []);
  return (
    <div
      ref={ref}
      aria-hidden="true"
      data-yk-grain=""
      className={className}
      style={{ position: "absolute", inset: 0, overflow: "hidden", pointerEvents: "none", borderRadius: "inherit", opacity, mixBlendMode: blend, ...style }}
    >
      {animated && <style>{YK_GRAIN_CSS}</style>}
      <div style={{ position: "absolute", inset: "-10%", backgroundImage: YK_NOISE, animation: animated ? "yk-grain 0.9s steps(4) infinite" : undefined }} />
    </div>
  );
}

Quality checks

Automated, in a real browser · 5d ago
—

More from Warm Paper Calendar

The whole style →

Floating Pill Navigation Bar

Headers & nav bars

Hub-and-Spoke Integration Diagram

Animated graphics

Inline-Chip Headline Hero

Heroes

Frosted Desktop Booking Mockup

Media & mockups

Monochrome Logo Grid

Logo clouds

Step Accordion with Grain Photo

Feature sections