{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "color-swatch-picker-preskok-demo",
  "registryDependencies": [
    "https://ui-three-mu.vercel.app/r/color-swatch-picker.json",
    "https://ui-three-mu.vercel.app/r/color-swatch.json"
  ],
  "files": [
    {
      "path": "registry/preskok/examples/color-swatch-picker-preskok-demo.tsx",
      "content": "\"use client\"\n\nimport { useState } from \"react\"\nimport { parseColor } from \"react-stately/Color\"\n\nimport { ColorSwatch } from \"@/components/ui/preskok-ui/color-swatch\"\nimport {\n  ColorSwatchPicker,\n  ColorSwatchPickerItem,\n} from \"@/components/ui/preskok-ui/color-swatch-picker\"\n\nexport default function ColorSwatchPreskokDemo() {\n  const [value, setValue] = useState(() => parseColor(\"#2563eb\"))\n\n  return (\n    <div className=\"grid gap-3\">\n      <ColorSwatchPicker\n        aria-label=\"Pick color\"\n        value={value}\n        onChange={setValue}\n        className=\"grid grid-cols-4 gap-2 sm:grid-cols-7\"\n      >\n        {colors.map((color) => (\n          <ColorSwatchPickerItem\n            key={color.value}\n            color={color.value}\n            isDisabled={color.isDisabled}\n          >\n            <ColorSwatch />\n          </ColorSwatchPickerItem>\n        ))}\n      </ColorSwatchPicker>\n      <p className=\"text-sm text-muted-foreground\">\n        Selected: {value.toString(\"hex\")}\n      </p>\n    </div>\n  )\n}\n\nconst colors = [\n  { value: \"#ffffff\" },\n  { value: \"#111827\" },\n  { value: \"#2563eb\" },\n  { value: \"#16a34a\" },\n  { value: \"#f59e0b\" },\n  { value: \"#dc2626\" },\n  { value: \"#9333ea\", isDisabled: true },\n]\n",
      "type": "registry:example"
    }
  ],
  "type": "registry:example"
}