We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
label.tsx
1 parent aab66b5 commit 83c3a10Copy full SHA for 83c3a10
1 file changed
src/components/ui/label.tsx
@@ -10,17 +10,18 @@ const labelVariants = cva(
10
"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70",
11
);
12
13
-const Label = React.forwardRef<
14
- React.ElementRef<typeof LabelPrimitive.Root>,
15
- React.ComponentPropsWithoutRef<typeof LabelPrimitive.Root> &
16
- VariantProps<typeof labelVariants>
17
->(({ className, ...props }, ref) => (
+const Label = ({
+ className,
+ ref,
+ ...props
+}: React.ComponentPropsWithRef<typeof LabelPrimitive.Root> &
18
+ VariantProps<typeof labelVariants>) => (
19
<LabelPrimitive.Root
20
ref={ref}
21
className={cn(labelVariants(), className)}
22
{...props}
23
/>
-));
24
+);
25
Label.displayName = LabelPrimitive.Root.displayName;
26
27
export { Label };
0 commit comments