label.tsx 524 B

1234567891011121314151617181920
  1. 'use client';
  2. import * as React from 'react';
  3. import { cn } from '@/lib/utils';
  4. function Label({ className, ...props }: React.ComponentProps<'label'>) {
  5. return (
  6. <label
  7. data-slot="label"
  8. className={cn(
  9. 'flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50',
  10. className,
  11. )}
  12. {...props}
  13. />
  14. );
  15. }
  16. export { Label };