mirror of
https://github.com/fosrl/pangolin.git
synced 2026-03-01 04:33:51 +00:00
27 lines
583 B
TypeScript
27 lines
583 B
TypeScript
"use client"
|
|
|
|
import * as React from "react"
|
|
import * as LabelPrimitive from "@radix-ui/react-label"
|
|
import { cva, type VariantProps } from "class-variance-authority"
|
|
|
|
import { cn } from "@app/lib/cn"
|
|
|
|
const labelVariants = cva(
|
|
"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
|
|
)
|
|
|
|
const Label = (
|
|
{
|
|
ref,
|
|
className,
|
|
...props
|
|
}
|
|
) => (<LabelPrimitive.Root
|
|
ref={ref}
|
|
className={cn(labelVariants(), className)}
|
|
{...props}
|
|
/>)
|
|
Label.displayName = LabelPrimitive.Root.displayName
|
|
|
|
export { Label }
|