{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "changelog-plotted",
  "title": "Plotted changelog",
  "description": "Releases down a rail that inks itself as you read, each stamped with a rosette drawn from its version number.",
  "dependencies": [
    "svg-scroll-draw@^2.29.0"
  ],
  "registryDependencies": [
    "https://scrollfx-ui.vercel.app/r/plotter.json"
  ],
  "files": [
    {
      "path": "registry/blocks/changelog-plotted.tsx",
      "content": "'use client';\n\n/**\n * changelog-plotted — releases down a rail that inks itself as you read, each\n * stamped with a rosette drawn from its version number: every release gets a\n * mark of its own, and the same one every time.\n *\n * Built on svg-scroll-draw (MIT): https://github.com/DhruvilChauahan0210/scrollfx\n * Needs: react, svg-scroll-draw, and lib/plotter (installed with it).\n * Styling: Tailwind CSS with shadcn/ui tokens. The heading takes one emphasised\n * word between asterisks, set in `font-serif`.\n *\n * The releases are plain text in the server HTML; the stamps are drawn in the\n * browser. Reduced motion shows the rail and the stamps drawn.\n */\n\nimport { useEffect, useState } from 'react';\nimport { ScrollAnimate, ScrollDraw } from 'svg-scroll-draw/react';\nimport 'svg-scroll-draw/no-flash.css';\nimport { rosette, scrollWindow, seedOf } from '@/lib/plotter';\n\nexport interface Release {\n  version: string;\n  date: string;\n  title: string;\n  body: string;\n}\n\nexport interface ChangelogPlottedProps {\n  eyebrow?: string;\n  heading?: string;\n  releases?: Release[];\n  accent?: string;\n  className?: string;\n}\n\nconst DEFAULT_RELEASES: Release[] = [\n  { version: '3.2', date: 'Nov 12, 2026', title: 'Realtime dashboards', body: 'Every chart updates the moment the data changes. No refresh button, no polling interval to set.' },\n  { version: '3.1', date: 'Oct 28, 2026', title: 'Scheduled reports', body: 'Pick a dashboard, a day and an inbox. The report arrives as a PDF and a link, at the same time every week.' },\n  { version: '3.0', date: 'Oct 2, 2026', title: 'A faster editor', body: 'Large workspaces open four times faster, and filters apply as you type instead of after you press enter.' },\n  { version: '2.9', date: 'Sep 15, 2026', title: 'Single sign-on on every plan', body: 'SAML and OIDC are no longer an Enterprise extra. Connect Okta, Entra ID or Google in a few minutes.' },\n  { version: '2.8', date: 'Aug 30, 2026', title: 'Dark mode', body: 'Follows your system setting, or set it per workspace. Charts pick colours that keep their contrast in both.' },\n];\n\nfunction Heading({ text }: { text: string }) {\n  return <>{text.split(/(\\*[^*]+\\*)/).map((p, i) => (p.startsWith('*') ? <em key={i} className=\"italic\">{p.slice(1, -1)}</em> : <span key={i}>{p}</span>))}</>;\n}\n\nfunction Stamp({ version, accent, latest }: { version: string; accent: string; latest: boolean }) {\n  const [d, setD] = useState<string | null>(null);\n  useEffect(() => setD(rosette(seedOf(version), 100)[0].d), [version]);\n  return (\n    <div className=\"relative size-16 rounded-full bg-background p-0.5\">\n      {d && (\n        <ScrollDraw easing=\"linear\" trigger={scrollWindow()} className=\"size-full\" aria-hidden>\n          <svg viewBox=\"0 0 100 100\" className=\"size-full\" fill=\"none\" stroke={latest ? accent : 'currentColor'} strokeWidth=\"1.25\" strokeLinejoin=\"round\">\n            <path d={d} />\n          </svg>\n        </ScrollDraw>\n      )}\n    </div>\n  );\n}\n\nexport function ChangelogPlotted({\n  eyebrow = 'Changelog',\n  heading = 'What we *shipped*.',\n  releases = DEFAULT_RELEASES,\n  accent = '#e0482a',\n  className = '',\n}: ChangelogPlottedProps) {\n  return (\n    <section className={`mx-auto max-w-5xl px-6 py-28 sm:px-10 ${className}`}>\n      <p className=\"font-mono text-[11px] uppercase tracking-[0.22em] text-muted-foreground\">{eyebrow}</p>\n      <h2 className=\"mt-6 font-serif text-[clamp(2.6rem,5vw,4.2rem)] leading-[0.98] tracking-[-0.03em]\">\n        <Heading text={heading} />\n      </h2>\n\n      <ol className=\"relative mt-20\">\n        {/* The rail: a hairline, and the ink that runs down it as you read. */}\n        <div aria-hidden className=\"absolute bottom-8 left-8 top-8 w-px bg-border sm:left-[200px]\" />\n        <ScrollAnimate aria-hidden props={{ transform: ['scaleY(0)', 'scaleY(1)'] }} trigger={{ start: 'top 60%', end: 'bottom 60%' }} easing=\"linear\" className=\"absolute bottom-8 left-8 top-8 w-px origin-top sm:left-[200px]\">\n          <div className=\"h-full w-px bg-foreground\" />\n        </ScrollAnimate>\n\n        {releases.map((r, i) => (\n          <li key={r.version} className=\"relative grid grid-cols-[64px_1fr] gap-x-6 pb-20 last:pb-0 sm:grid-cols-[136px_64px_1fr] sm:gap-x-8\">\n            <div className=\"hidden pt-5 text-right sm:block\">\n              <p className=\"font-mono text-sm\">v{r.version}</p>\n              <p className=\"mt-1 font-mono text-[11px] uppercase tracking-[0.14em] text-muted-foreground\">{r.date}</p>\n            </div>\n            <Stamp version={r.version} accent={accent} latest={i === 0} />\n            <div className=\"pt-3\">\n              <p className=\"mb-2 font-mono text-[11px] uppercase tracking-[0.14em] text-muted-foreground sm:hidden\">v{r.version} · {r.date}</p>\n              <h3 className=\"font-serif text-[1.9rem] leading-tight tracking-[-0.02em]\">{r.title}</h3>\n              <p className=\"mt-3 max-w-xl text-pretty text-[17px] leading-relaxed text-muted-foreground\">{r.body}</p>\n            </div>\n          </li>\n        ))}\n      </ol>\n    </section>\n  );\n}\n",
      "type": "registry:component"
    }
  ],
  "meta": {
    "motion": "Read down: the rail inks, each stamp is drawn.",
    "tall": true
  },
  "type": "registry:block"
}