{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "circuit-hub-demo",
  "type": "registry:block",
  "title": "Circuit: Integrations Hub",
  "description": "Animated Flow Diagram example, Integrations Hub: Your product in the middle of a 3×3 grid of integrations, the flow built from arrays with a packet color per tool. `highlight=\"neighbors\"` lights only a tile's own trace, and the tiles lift on hover: the traces follow them. A take on the flow diagram (flowchart). Fits features and integrations sections.",
  "author": "KeyframeUI <https://keyframeui.com>",
  "categories": [
    "features",
    "integrations",
    "flow-diagram",
    "diagram",
    "svg",
    "interaction",
    "landing"
  ],
  "docs": "Live preview, examples and props: https://keyframeui.com/components/circuit#circuit-hub-demo",
  "registryDependencies": [
    "https://keyframeui.com/r/circuit.json"
  ],
  "files": [
    {
      "path": "components/circuit-hub-demo.tsx",
      "type": "registry:component",
      "content": "\"use client\";\n\nimport { Circuit } from \"@/components/ui/circuit\";\n\n// A 3×3 grid with your product in the middle. Inputs and outputs sit around it,\n// each with its own packet color.\nconst TILES = [\n  { id: \"github\", label: \"GitHub\", tone: \"#a1a1aa\" },\n  { id: \"sentry\", label: \"Sentry\", tone: \"#f472b6\" },\n  { id: \"figma\", label: \"Figma\", tone: \"#fb923c\" },\n  { id: \"linear\", label: \"Linear\", tone: \"#818cf8\" },\n  null,\n  { id: \"slack\", label: \"Slack\", tone: \"#facc15\" },\n  { id: \"stripe\", label: \"Stripe\", tone: \"#a78bfa\" },\n  { id: \"email\", label: \"Email\", tone: \"#38bdf8\" },\n  { id: \"notion\", label: \"Notion\", tone: \"#a1a1aa\" },\n];\n\nconst INPUTS = [\"github\", \"sentry\", \"figma\", \"linear\", \"stripe\"];\nconst OUTPUTS = [\"slack\", \"email\", \"notion\"];\n\nconst tile =\n  \"flex flex-col items-center justify-center gap-2 rounded-2xl border border-zinc-200 bg-white p-3 text-xs font-medium text-zinc-700 transition-[opacity,transform,border-color] duration-300 hover:-translate-y-0.5 dark:border-zinc-800 dark:bg-zinc-900 dark:text-zinc-300 data-[circuit-state=dimmed]:opacity-40 data-circuit-pulse:border-zinc-400 dark:data-circuit-pulse:border-zinc-600\";\n\nexport function CircuitHubDemo() {\n  const tone = (id: string) => TILES.find((t) => t?.id === id)?.tone;\n\n  return (\n    <div className=\"@container w-full max-w-xl\">\n      <Circuit\n        highlight=\"neighbors\"\n        interval={3.2}\n        flow={[\n          ...INPUTS.map((id) => ({ from: id, to: \"hub\", color: tone(id) })),\n          ...OUTPUTS.map((id) => ({ from: \"hub\", to: id, color: tone(id) })),\n        ]}\n        className=\"grid grid-cols-3 gap-x-8 gap-y-7 @md:gap-x-14 @md:gap-y-10\"\n      >\n        {TILES.map((t) =>\n          t ? (\n            <div key={t.id} data-circuit={t.id} className={`${tile} aspect-[4/3]`}>\n              <span className=\"size-6 rounded-lg\" style={{ background: `color-mix(in oklab, ${t.tone} 22%, transparent)`, boxShadow: `inset 0 0 0 1px color-mix(in oklab, ${t.tone} 45%, transparent)` }} />\n              {t.label}\n            </div>\n          ) : (\n            <div\n              key=\"hub\"\n              data-circuit=\"hub\"\n              className=\"flex aspect-[4/3] flex-col items-center justify-center gap-1 rounded-2xl bg-zinc-900 p-3 text-center text-white shadow-lg transition-shadow duration-300 dark:bg-white dark:text-zinc-900 data-circuit-pulse:shadow-[0_0_0_6px_rgb(161_161_170/0.25)]\"\n            >\n              <span className=\"text-sm font-semibold tracking-tight\">Relay</span>\n              <span className=\"font-mono text-[10px] opacity-60\">your app</span>\n            </div>\n          ),\n        )}\n      </Circuit>\n    </div>\n  );\n}\n"
    }
  ]
}