{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "radio-group",
  "title": "Radio Group",
  "description": "A shadcn-style radio group component built with Ark UI primitives.",
  "dependencies": ["@ark-ui/react"],
  "files": [
    {
      "path": "src/components/ui/radio-group.tsx",
      "content": "\"use client\";\n\nimport {\n  RadioGroupContext,\n  RadioGroup as RadioGroupPrimitive,\n  useRadioGroup,\n  useRadioGroupContext,\n} from \"@ark-ui/react/radio-group\";\nimport { cn } from \"@/lib/utils\";\n\nexport type RadioGroupProps = RadioGroupPrimitive.RootProps;\n\nexport const RadioGroup = ({ className, ...props }: RadioGroupProps) => (\n  <RadioGroupPrimitive.Root\n    className={cn(\n      \"flex flex-col gap-2 text-foreground\",\n      \"data-[orientation=horizontal]:flex-row data-[orientation=horizontal]:flex-wrap data-[orientation=horizontal]:gap-4\",\n      className,\n    )}\n    data-slot=\"radio-group\"\n    {...props}\n  />\n);\n\nexport type RadioGroupLabelProps = RadioGroupPrimitive.LabelProps;\n\nexport const RadioGroupLabel = ({\n  className,\n  ...props\n}: RadioGroupLabelProps) => (\n  <RadioGroupPrimitive.Label\n    className={cn(\n      \"text-sm font-medium text-foreground leading-none select-none\",\n      \"data-disabled:pointer-events-none data-disabled:opacity-50\",\n      className,\n    )}\n    data-slot=\"radio-group-label\"\n    {...props}\n  />\n);\n\nexport type RadioProps = RadioGroupPrimitive.ItemProps;\n\nexport const Radio = ({ className, children, ...props }: RadioProps) => (\n  <RadioGroupPrimitive.Item\n    className={cn(\n      \"flex cursor-pointer items-center gap-2 rounded-md outline-none\",\n      \"data-disabled:cursor-not-allowed data-disabled:opacity-50 data-readonly:cursor-default\",\n      className,\n    )}\n    data-slot=\"radio-group-item\"\n    {...props}\n  >\n    <RadioGroupPrimitive.ItemHiddenInput />\n    <RadioGroupPrimitive.ItemText\n      className={cn(\n        \"inline-flex items-center gap-2 text-foreground text-sm\",\n        \"data-disabled:opacity-50\",\n      )}\n      data-slot=\"radio-group-item-text\"\n    >\n      <RadioGroupPrimitive.ItemControl\n        className={cn(\n          \"group/radio-control relative flex size-4 shrink-0 items-center justify-center rounded-full border border-input bg-background shadow-xs/5 outline-none transition-[color,box-shadow]\",\n          \"focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50\",\n          \"data-focus-visible:border-ring data-focus-visible:ring-[3px] data-focus-visible:ring-ring/50\",\n          \"data-readonly:cursor-default data-disabled:cursor-not-allowed data-disabled:opacity-50\",\n          \"data-invalid:border-destructive data-invalid:ring-destructive/20 dark:bg-input/30\",\n          \"data-[state=checked]:border-primary\",\n        )}\n        data-slot=\"radio-group-item-control\"\n      >\n        <span\n          aria-hidden\n          className=\"size-2 scale-0 rounded-full bg-primary opacity-0 transition-all group-data-[state=checked]/radio-control:scale-100 group-data-[state=checked]/radio-control:opacity-100\"\n        />\n      </RadioGroupPrimitive.ItemControl>\n      {children}\n    </RadioGroupPrimitive.ItemText>\n  </RadioGroupPrimitive.Item>\n);\n\nexport const RadioGroupItem = Radio;\n\nexport type RadioGroupRootProviderProps = RadioGroupPrimitive.RootProviderProps;\n\nexport const RadioGroupRootProvider = ({\n  className,\n  ...props\n}: RadioGroupRootProviderProps) => (\n  <RadioGroupPrimitive.RootProvider\n    className={cn(\n      \"flex flex-col gap-2 text-foreground\",\n      \"data-[orientation=horizontal]:flex-row data-[orientation=horizontal]:flex-wrap data-[orientation=horizontal]:gap-4\",\n      className,\n    )}\n    data-slot=\"radio-group\"\n    {...props}\n  />\n);\n\nexport type RadioGroupItemControlProps = RadioGroupPrimitive.ItemControlProps;\n\nexport const RadioGroupItemControl = ({\n  className,\n  ...props\n}: RadioGroupItemControlProps) => (\n  <RadioGroupPrimitive.ItemControl\n    className={cn(className)}\n    data-slot=\"radio-group-item-control-raw\"\n    {...props}\n  />\n);\n\nexport type RadioGroupItemTextProps = RadioGroupPrimitive.ItemTextProps;\n\nexport const RadioGroupItemText = ({\n  className,\n  ...props\n}: RadioGroupItemTextProps) => (\n  <RadioGroupPrimitive.ItemText\n    className={cn(className)}\n    data-slot=\"radio-group-item-text-raw\"\n    {...props}\n  />\n);\n\nexport type RadioGroupItemHiddenInputProps =\n  RadioGroupPrimitive.ItemHiddenInputProps;\n\nexport const RadioGroupItemHiddenInput = (\n  props: RadioGroupItemHiddenInputProps,\n) => <RadioGroupPrimitive.ItemHiddenInput {...props} />;\n\nexport type RadioGroupItemPrimitiveProps = RadioGroupPrimitive.ItemProps;\n\nexport const RadioGroupItemPrimitive = ({\n  className,\n  ...props\n}: RadioGroupItemPrimitiveProps) => (\n  <RadioGroupPrimitive.Item\n    className={cn(className)}\n    data-slot=\"radio-group-item-raw\"\n    {...props}\n  />\n);\n\nexport type RadioGroupIndicatorProps = RadioGroupPrimitive.IndicatorProps;\n\nexport const RadioGroupIndicator = ({\n  className,\n  ...props\n}: RadioGroupIndicatorProps) => (\n  <RadioGroupPrimitive.Indicator\n    className={cn(className)}\n    data-slot=\"radio-group-indicator\"\n    {...props}\n  />\n);\n\nexport type {\n  RadioGroupValueChangeDetails,\n  UseRadioGroupProps,\n  UseRadioGroupReturn,\n} from \"@ark-ui/react/radio-group\";\nexport { RadioGroupContext, useRadioGroup, useRadioGroupContext };\n",
      "type": "registry:ui",
      "target": "src/components/ui/radio-group.tsx"
    }
  ],
  "type": "registry:ui"
}
