import type { VariantProps } from 'class-variance-authority'; import type { LucideIcon } from 'lucide-react-native'; import * as React from 'react'; import { toggleTextVariants, toggleVariants } from '../ui/toggle'; import { TextClassContext } from '../ui/text'; import * as ToggleGroupPrimitive from '@rn-primitives/toggle-group'; import { cn } from '../../lib/utils'; const ToggleGroupContext = React.createContext | null>(null); function ToggleGroup({ className, variant, size, children, ...props }: ToggleGroupPrimitive.RootProps & VariantProps & { ref?: React.RefObject; }) { return ( {children} ); } function useToggleGroupContext() { const context = React.useContext(ToggleGroupContext); if (context === null) { throw new Error( 'ToggleGroup compound components cannot be rendered outside the ToggleGroup component', ); } return context; } function ToggleGroupItem({ className, children, variant, size, ...props }: ToggleGroupPrimitive.ItemProps & VariantProps & { ref?: React.RefObject; }) { const context = useToggleGroupContext(); const { value } = ToggleGroupPrimitive.useRootContext(); return ( {children} ); } function ToggleGroupIcon({ className, icon: Icon, ...props }: React.ComponentPropsWithoutRef & { icon: LucideIcon; }) { const textClass = React.useContext(TextClassContext); return ; } export { ToggleGroup, ToggleGroupIcon, ToggleGroupItem };