remove forward ref

This commit is contained in:
miloschwartz
2025-04-12 12:40:52 -04:00
parent 521bbbf1d6
commit f14379a1c8
25 changed files with 2067 additions and 1779 deletions

View File

@@ -10,17 +10,17 @@ const labelVariants = cva(
"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
)
const Label = React.forwardRef<
React.ElementRef<typeof LabelPrimitive.Root>,
React.ComponentPropsWithoutRef<typeof LabelPrimitive.Root> &
VariantProps<typeof labelVariants>
>(({ className, ...props }, ref) => (
<LabelPrimitive.Root
ref={ref}
className={cn(labelVariants(), className)}
{...props}
/>
))
const Label = (
{
ref,
className,
...props
}
) => (<LabelPrimitive.Root
ref={ref}
className={cn(labelVariants(), className)}
{...props}
/>)
Label.displayName = LabelPrimitive.Root.displayName
export { Label }