{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "code-block-json-demo",
  "registryDependencies": [
    "@delta/code-block"
  ],
  "files": [
    {
      "path": "examples/code-block-json-demo.tsx",
      "content": "\"use client\"\n\nimport * as React from \"react\"\n\nimport { CodeBlock } from \"@/components/ui/code-block\"\nimport { Button } from \"@/components/ui/button\"\n\nconst jsonData = `{\n  \"user\": {\n    \"id\": \"usr_2nQz7kX9pLm4\",\n    \"email\": \"sarah.chen@acme.com\",\n    \"name\": \"Sarah Chen\",\n    \"role\": \"senior_engineer\",\n    \"permissions\": [\"read\", \"write\", \"deploy\"],\n    \"metadata\": {\n      \"department\": \"platform\",\n      \"team\": \"infrastructure\",\n      \"timezone\": \"America/Los_Angeles\"\n    }\n  },\n  \"session\": {\n    \"token\": \"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9\",\n    \"expiresAt\": \"2024-12-31T23:59:59Z\",\n    \"refreshToken\": \"rt_9xKmP3vN8qL2\",\n    \"scopes\": [\"api:read\", \"api:write\", \"admin:users\"]\n  },\n  \"preferences\": {\n    \"theme\": \"dark\",\n    \"notifications\": {\n      \"email\": true,\n      \"slack\": true,\n      \"digest\": \"daily\"\n    },\n    \"editor\": {\n      \"tabSize\": 2,\n      \"formatOnSave\": true\n    }\n  }\n}`\n\nexport default function CodeBlockJsonDemo() {\n  const [showScrollbar, setShowScrollbar] = React.useState(true)\n\n  return (\n    <div className=\"flex w-full max-w-full flex-col gap-4\">\n      <div className=\"flex items-center justify-between\">\n        <span className=\"text-muted-foreground text-sm\">\n          Scrollbar: {showScrollbar ? \"Visible\" : \"Hidden\"}\n        </span>\n        <Button\n          variant=\"outline\"\n          size=\"sm\"\n          onClick={() => setShowScrollbar(!showScrollbar)}\n        >\n          Toggle Scrollbar\n        </Button>\n      </div>\n      <CodeBlock\n        code={jsonData}\n        language=\"json\"\n        filename=\"user-session.json\"\n        showLineNumbers={true}\n        scrollbar={showScrollbar}\n      />\n    </div>\n  )\n}\n",
      "type": "registry:example"
    }
  ],
  "type": "registry:example"
}