import * as React from "react"; import { RadioGroup as RadioGroupPrimitive } from "radix-ui"; export interface EnhancedRadioGroupProps extends React.ComponentProps { /** * Visual variant of the radio group. * - `animated`: Default variant with circular radio buttons and pulse animation on selection * - `sliding`: Tab-like sliding indicator that moves to the selected item * * @default "animated" */ variant?: "animated" | "sliding"; /** * Disables all radio items in the group. * * @default false */ disabled?: boolean; /** * Gap between radio items. Can be a number (gap in pixels) or a Tailwind gap class. * - `0` or `"gap-0"`: No gap * - `1` or `"gap-1"` (4px) * - `2` or `"gap-2"` (8px) - compact * - `3` or `"gap-3"` (12px) - default * - `4` or `"gap-4"` (16px) * * @default 3 */ gap?: number | string; } /** * Enhanced RadioGroup component with variant support * * Wraps Radix UI RadioGroup primitives with enhanced styling and variants. * Maintains all Radix UI accessibility and state management. * * **Usage Tips:** * - Pass content directly as children to RadioGroupItem (don't wrap in Label) * - Use the `spacing` prop on RadioGroupItem to control gap between radio and content * - The "animated" variant is best for most use cases * * @example * ```tsx * // Basic usage * * Option 1 * Option 2 * * * // With custom content and spacing * * *
*
Option 1
*
Description
*
*
*
* ``` */ declare const EnhancedRadioGroup: React.ForwardRefExoticComponent & React.RefAttributes>; export interface EnhancedRadioGroupItemProps extends React.ComponentProps { /** * The content to display next to the radio button. * * **Important:** Pass children directly to RadioGroupItem. Do NOT wrap RadioGroupItem * in a separate Label component, as RadioGroupItem already provides the label wrapper. * * @example * ```tsx * // ✅ Correct usage * *
*
Option 1
*
Description
*
*
* * // ❌ Incorrect usage - don't wrap in Label * * ``` */ children?: React.ReactNode; /** * Controls the spacing between the radio button and its content. * - `compact`: 8px gap (gap-2) * - `default`: 12px gap (gap-3) - default * - `comfortable`: 16px gap (gap-4) * * Only applies to the "animated" variant. * * @default "default" */ spacing?: "compact" | "default" | "comfortable"; } /** * Enhanced RadioGroupItem component with variant-specific rendering. * * This component automatically wraps the radio button in a label and handles * accessibility. Pass your content directly as children - do not wrap this * component in additional Label components. * * @example * ```tsx * * *
*
Option 1
*
Description
*
*
*
* ``` */ declare const EnhancedRadioGroupItem: React.ForwardRefExoticComponent & React.RefAttributes>; export { EnhancedRadioGroup, EnhancedRadioGroup as RadioGroup, EnhancedRadioGroupItem, EnhancedRadioGroupItem as RadioGroupItem }; export type { EnhancedRadioGroupProps as RadioGroupProps, EnhancedRadioGroupItemProps as RadioGroupItemProps }; //# sourceMappingURL=enhanced-radio-group.d.ts.map