{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "blog-13",
  "type": "registry:block",
  "description": "Article page with centered header, sticky table of contents with scroll-spy highlighting, body sections and a share rail.",
  "dependencies": [
    "lucide-react"
  ],
  "registryDependencies": [
    "button"
  ],
  "files": [
    {
      "path": "registry/designali/blocks/blog/blog-13.tsx",
      "content": "\"use client\"\n\nimport { useEffect, useState } from \"react\"\nimport {\n  Bookmark,\n  Link2,\n  Share2,\n} from \"@designali/icons\"\n\nimport { Button } from \"@workspace/ui/components/button\"\nimport { cn } from \"@workspace/ui/lib/utils\"\n\nconst sections = [\n  {\n    id: \"problem\",\n    title: \"The problem with nightly registry builds\",\n    body: [\n      \"For three years, every Designali block, icon and template was rebuilt by a single cron job at 02:00 UTC. It worked until designali.com grew past 460 blocks and 4,000 icons.\",\n      \"The job had grown to 47 minutes. A failure meant a full rerun, and a broken registry for everyone.\",\n    ],\n  },\n  {\n    id: \"approach\",\n    title: \"Moving to incremental snapshots\",\n    body: [\n      \"We split the build into per-item snapshots that rebuild whenever a source file changes. Each snapshot is small enough to finish in seconds and cheap enough to retry.\",\n      \"The hard part was not the pipeline. It was agreeing on what a consistent registry means when blocks and their dependencies change out of order.\",\n    ],\n  },\n  {\n    id: \"results\",\n    title: \"What changed for customers\",\n    body: [\n      \"The registry is now at most four minutes stale. Support emails about missing blocks dropped by 81% in the first month.\",\n      \"Our Vercel bill went up a little. Nobody has asked to switch back.\",\n    ],\n  },\n  {\n    id: \"next\",\n    title: \"What we would do differently\",\n    body: [\n      \"We would have invested in a replay tool on day one. Debugging a snapshot means reconstructing the exact order of events that built it, and we did that by hand for weeks.\",\n    ],\n  },\n]\n\nexport default function Blog13() {\n  const [active, setActive] = useState(sections[0]?.id ?? \"\")\n\n  useEffect(() => {\n    const observer = new IntersectionObserver(\n      (entries) => {\n        const visible = entries.find((e) => e.isIntersecting)\n        if (visible) setActive(visible.target.id)\n      },\n      { rootMargin: \"-20% 0px -70% 0px\" }\n    )\n    sections.forEach((s) => {\n      const el = document.getElementById(`blog13-${s.id}`)\n      if (el) observer.observe(el)\n    })\n    return () => observer.disconnect()\n  }, [])\n\n  return (\n    <section className=\"w-full bg-background py-16 text-foreground md:py-24\">\n      <div className=\"mx-auto max-w-7xl px-6\">\n        <header className=\"mx-auto max-w-3xl text-center\">\n          <p className=\"text-xs tracking-widest text-muted-foreground uppercase\">Engineering · 9 min read</p>\n          <h1 className=\"mt-4 text-4xl leading-tight font-medium tracking-tight md:text-5xl\">\n            How designali.com replaced a 47-minute cron job with incremental builds\n          </h1>\n          <div className=\"mt-8 flex items-center justify-center gap-3\">\n            <img src=\"/ali.jpg\" alt=\"Ali Imam\" className=\"size-10 rounded-full object-cover\" />\n            <div className=\"text-left text-sm\">\n              <p className=\"font-medium\">Ali Imam</p>\n              <p className=\"text-xs text-muted-foreground\">Founder, Designali · November 11, 2026</p>\n            </div>\n          </div>\n        </header>\n\n        <div className=\"mt-16 grid gap-12 border-t pt-12 lg:grid-cols-[220px_1fr_60px]\">\n          <nav className=\"hidden lg:sticky lg:top-24 lg:block lg:self-start\" aria-label=\"Table of contents\">\n            <p className=\"text-xs tracking-widest text-muted-foreground uppercase\">On this page</p>\n            <ul className=\"mt-4 space-y-1 border-l\">\n              {sections.map((s) => (\n                <li key={s.id}>\n                  <a\n                    href={`#blog13-${s.id}`}\n                    className={cn(\n                      \"-ml-px block border-l py-1.5 pl-4 text-sm transition-colors\",\n                      active === s.id\n                        ? \"border-foreground text-foreground\"\n                        : \"border-transparent text-muted-foreground hover:text-foreground\"\n                    )}\n                  >\n                    {s.title}\n                  </a>\n                </li>\n              ))}\n            </ul>\n          </nav>\n\n          <article className=\"mx-auto w-full max-w-2xl\">\n            {sections.map((s) => (\n              <div key={s.id} id={`blog13-${s.id}`} className=\"scroll-mt-24 pb-10\">\n                <h2 className=\"text-2xl font-medium tracking-tight\">{s.title}</h2>\n                {s.body.map((p) => (\n                  <p key={p.slice(0, 24)} className=\"mt-4 text-base leading-8 text-muted-foreground\">\n                    {p}\n                  </p>\n                ))}\n              </div>\n            ))}\n          </article>\n\n          <div className=\"flex gap-2 lg:sticky lg:top-24 lg:flex-col lg:self-start\">\n            <Button variant=\"outline\" size=\"icon-lg\" aria-label=\"Save post\">\n              <Bookmark />\n            </Button>\n            <Button variant=\"outline\" size=\"icon-lg\" aria-label=\"Share post\">\n              <Share2 />\n            </Button>\n            <Button variant=\"outline\" size=\"icon-lg\" aria-label=\"Copy link\">\n              <Link2 />\n            </Button>\n          </div>\n        </div>\n      </div>\n    </section>\n  )\n}\n",
      "type": "registry:component"
    }
  ],
  "meta": {
    "iframeHeight": "1200px"
  },
  "categories": [
    "blog"
  ]
}