field-hear.tsx — ui Source File
Architecture documentation for field-hear.tsx, a tsx file in the ui codebase. 3 imports, 1 dependents.
Entity Profile
Dependency Diagram
graph LR 9e077c76_f79e_4486_5f42_a2e8dd873771["field-hear.tsx"] a3f5dc6c_2f22_a06c_c4d4_d84a4ed2818e["card"] 9e077c76_f79e_4486_5f42_a2e8dd873771 --> a3f5dc6c_2f22_a06c_c4d4_d84a4ed2818e 0e5204ae_c5d7_cc02_3599_620cb7011a92["checkbox"] 9e077c76_f79e_4486_5f42_a2e8dd873771 --> 0e5204ae_c5d7_cc02_3599_620cb7011a92 b5f68436_cf6b_fba3_fb29_abf27fd13442["field"] 9e077c76_f79e_4486_5f42_a2e8dd873771 --> b5f68436_cf6b_fba3_fb29_abf27fd13442 53860de0_4d86_dc1d_c85a_07c01f0d1a07["index.tsx"] 53860de0_4d86_dc1d_c85a_07c01f0d1a07 --> 9e077c76_f79e_4486_5f42_a2e8dd873771 style 9e077c76_f79e_4486_5f42_a2e8dd873771 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
import { Card, CardContent } from "@/examples/radix/ui/card"
import { Checkbox } from "@/examples/radix/ui/checkbox"
import {
Field,
FieldDescription,
FieldGroup,
FieldLabel,
FieldLegend,
FieldSet,
FieldTitle,
} from "@/examples/radix/ui/field"
const options = [
{
label: "Social Media",
value: "social-media",
},
{
label: "Search Engine",
value: "search-engine",
},
{
label: "Referral",
value: "referral",
},
{
label: "Other",
value: "other",
},
]
export function FieldHear() {
return (
<Card className="py-4 shadow-none">
<CardContent className="px-4">
<form>
<FieldGroup>
<FieldSet className="gap-4">
<FieldLegend>How did you hear about us?</FieldLegend>
<FieldDescription className="line-clamp-1">
Select the option that best describes how you heard about us.
</FieldDescription>
<FieldGroup className="flex flex-row flex-wrap gap-2 [--radius:9999rem]">
{options.map((option) => (
<FieldLabel
htmlFor={option.value}
key={option.value}
className="!w-fit"
>
<Field
orientation="horizontal"
className="gap-1.5 overflow-hidden px-3! py-1.5! transition-all duration-100 ease-linear group-has-data-[state=checked]/field-label:px-2!"
>
<Checkbox
value={option.value}
id={option.value}
defaultChecked={option.value === "social-media"}
className="-ml-6 -translate-x-1 rounded-full transition-all duration-100 ease-linear data-[state=checked]:ml-0 data-[state=checked]:translate-x-0"
/>
<FieldTitle>{option.label}</FieldTitle>
</Field>
</FieldLabel>
))}
</FieldGroup>
</FieldSet>
</FieldGroup>
</form>
</CardContent>
</Card>
)
}
Domain
Subdomains
Functions
Dependencies
- card
- checkbox
- field
Imported By
Source
Frequently Asked Questions
What does field-hear.tsx do?
field-hear.tsx is a source file in the ui codebase, written in tsx. It belongs to the DocumentationAtlas domain, Changelog subdomain.
What functions are defined in field-hear.tsx?
field-hear.tsx defines 1 function(s): FieldHear.
What does field-hear.tsx depend on?
field-hear.tsx imports 3 module(s): card, checkbox, field.
What files import field-hear.tsx?
field-hear.tsx is imported by 1 file(s): index.tsx.
Where is field-hear.tsx in the architecture?
field-hear.tsx is located at apps/v4/app/(app)/(root)/components/field-hear.tsx (domain: DocumentationAtlas, subdomain: Changelog, directory: apps/v4/app/(app)/(root)/components).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free