Home / Function/ FieldLegend() — ui Function Reference

FieldLegend() — ui Function Reference

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

Entity Profile

Dependency Diagram

graph TD
  b40b8d6e_b91e_d7ca_b543_dc177320a383["FieldLegend()"]
  3e9ca722_9978_f84a_9c4c_f8d4a9ad469e["field.tsx"]
  b40b8d6e_b91e_d7ca_b543_dc177320a383 -->|defined in| 3e9ca722_9978_f84a_9c4c_f8d4a9ad469e
  style b40b8d6e_b91e_d7ca_b543_dc177320a383 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

apps/v4/registry/bases/radix/ui/field.tsx lines 20–33

function FieldLegend({
  className,
  variant = "legend",
  ...props
}: React.ComponentProps<"legend"> & { variant?: "legend" | "label" }) {
  return (
    <legend
      data-slot="field-legend"
      data-variant={variant}
      className={cn("cn-field-legend", className)}
      {...props}
    />
  )
}

Subdomains

Frequently Asked Questions

What does FieldLegend() do?
FieldLegend() is a function in the ui codebase, defined in apps/v4/registry/bases/radix/ui/field.tsx.
Where is FieldLegend() defined?
FieldLegend() is defined in apps/v4/registry/bases/radix/ui/field.tsx at line 20.

Analyze Your Own Codebase

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

Try Supermodel Free