Home / Function/ FieldLabel() — ui Function Reference

FieldLabel() — ui Function Reference

Architecture documentation for the FieldLabel() function in field.tsx from the ui codebase.

Entity Profile

Dependency Diagram

graph TD
  dd83ace0_bca0_e08e_3385_8d56f064af0b["FieldLabel()"]
  ffc014c9_65b6_798a_d0f3_5c78f720c14b["field.tsx"]
  dd83ace0_bca0_e08e_3385_8d56f064af0b -->|defined in| ffc014c9_65b6_798a_d0f3_5c78f720c14b
  style dd83ace0_bca0_e08e_3385_8d56f064af0b fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

deprecated/www/registry/default/ui/field.tsx lines 110–126

function FieldLabel({
  className,
  ...props
}: React.ComponentProps<typeof Label>) {
  return (
    <Label
      data-slot="field-label"
      className={cn(
        "group/field-label peer/field-label flex w-fit gap-2 leading-snug group-data-[disabled=true]/field:opacity-50",
        "has-[>[data-slot=field]]:w-full has-[>[data-slot=field]]:flex-col has-[>[data-slot=field]]:rounded-md has-[>[data-slot=field]]:border [&>[data-slot=field]]:p-4",
        "has-data-[state=checked]:bg-primary/5 has-data-[state=checked]:border-primary dark:has-data-[state=checked]:bg-primary/10",
        className
      )}
      {...props}
    />
  )
}

Subdomains

Frequently Asked Questions

What does FieldLabel() do?
FieldLabel() is a function in the ui codebase, defined in deprecated/www/registry/default/ui/field.tsx.
Where is FieldLabel() defined?
FieldLabel() is defined in deprecated/www/registry/default/ui/field.tsx at line 110.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free