{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "radio-08",
  "title": "Radio cards",
  "description": "Two plan cards where the picked one takes a primary hairline.",
  "dependencies": [],
  "registryDependencies": [
    "https://ui.ndekocode.dev/r/label.json",
    "https://ui.ndekocode.dev/r/radio-group.json",
    "https://ui.ndekocode.dev/r/theme.json"
  ],
  "files": [
    {
      "path": "registry/ndeko/components/radio/radio-08.tsx",
      "content": "import { useId } from 'react';\n\nimport { Label } from '@/registry/ndeko/ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/registry/ndeko/ui/radio-group';\n\nconst PLANS = [\n  {\n    value: 'starter',\n    label: 'Starter',\n    note: 'Free',\n    description: 'Three projects and help from the community.',\n  },\n  {\n    value: 'pro',\n    label: 'Pro',\n    note: '$12 per seat',\n    description: 'Unlimited projects and priority support.',\n  },\n];\n\nconst CHOICE_CARD = [\n  'relative flex w-full items-start gap-2 rounded-xl bg-card p-4 shadow-[0_1px_2px_rgb(0_0_0/0.04)] hairline-ring ring-border transition-[box-shadow] duration-150',\n  'has-data-checked:shadow-[0_1px_2px_rgb(0_0_0/0.04),0_6px_16px_-8px_color-mix(in_oklab,var(--primary)_35%,transparent)] has-data-checked:ring-primary/45',\n].join(' ');\n\nexport default function Radio08() {\n  const id = useId();\n\n  return (\n    <RadioGroup\n      defaultValue='starter'\n      aria-label='Plan'\n      className='w-full gap-2'\n    >\n      {PLANS.map((plan) => {\n        const itemId = `${id}-${plan.value}`;\n        const descriptionId = `${itemId}-description`;\n\n        return (\n          <div key={plan.value} className={CHOICE_CARD}>\n            <RadioGroupItem\n              value={plan.value}\n              id={itemId}\n              aria-describedby={descriptionId}\n              className='order-1 after:absolute after:inset-0'\n            />\n            <div className='grid grow gap-1.5'>\n              <Label htmlFor={itemId}>\n                {plan.label}{' '}\n                <span className='text-muted-foreground text-xs leading-[inherit] font-normal'>\n                  ({plan.note})\n                </span>\n              </Label>\n              <p id={descriptionId} className='text-muted-foreground text-xs'>\n                {plan.description}\n              </p>\n            </div>\n          </div>\n        );\n      })}\n    </RadioGroup>\n  );\n}\n",
      "type": "registry:component"
    }
  ],
  "categories": [
    "components",
    "radio"
  ],
  "type": "registry:component"
}