chart-example-legend.tsx — ui Source File
Architecture documentation for chart-example-legend.tsx, a tsx file in the ui codebase. 2 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR 77ae9661_9fc1_94b0_5b32_f823f379df4e["chart-example-legend.tsx"] 3078f0d3_02ab_de40_dcc7_d98140598e7f["chart"] 77ae9661_9fc1_94b0_5b32_f823f379df4e --> 3078f0d3_02ab_de40_dcc7_d98140598e7f da384753_eb23_55ed_e7a6_3bd0e172b999["recharts"] 77ae9661_9fc1_94b0_5b32_f823f379df4e --> da384753_eb23_55ed_e7a6_3bd0e172b999 style 77ae9661_9fc1_94b0_5b32_f823f379df4e fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
"use client"
import {
ChartContainer,
ChartLegend,
ChartLegendContent,
ChartTooltip,
ChartTooltipContent,
type ChartConfig,
} from "@/examples/radix/ui/chart"
import { Bar, BarChart, CartesianGrid, XAxis } from "recharts"
const chartData = [
{ month: "January", desktop: 186, mobile: 80 },
{ month: "February", desktop: 305, mobile: 200 },
{ month: "March", desktop: 237, mobile: 120 },
{ month: "April", desktop: 73, mobile: 190 },
{ month: "May", desktop: 209, mobile: 130 },
{ month: "June", desktop: 214, mobile: 140 },
]
const chartConfig = {
desktop: {
label: "Desktop",
color: "#2563eb",
},
mobile: {
label: "Mobile",
color: "#60a5fa",
},
} satisfies ChartConfig
export function ChartBarDemoLegend() {
return (
<ChartContainer config={chartConfig} className="min-h-[200px] w-full">
<BarChart accessibilityLayer data={chartData}>
<CartesianGrid vertical={false} />
<XAxis
dataKey="month"
tickLine={false}
tickMargin={10}
axisLine={false}
tickFormatter={(value) => value.slice(0, 3)}
/>
<ChartTooltip content={<ChartTooltipContent />} />
<ChartLegend content={<ChartLegendContent />} />
<Bar dataKey="desktop" fill="var(--color-desktop)" radius={4} />
<Bar dataKey="mobile" fill="var(--color-mobile)" radius={4} />
</BarChart>
</ChartContainer>
)
}
Domain
Subdomains
Functions
Dependencies
- chart
- recharts
Source
Frequently Asked Questions
What does chart-example-legend.tsx do?
chart-example-legend.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 chart-example-legend.tsx?
chart-example-legend.tsx defines 1 function(s): ChartBarDemoLegend.
What does chart-example-legend.tsx depend on?
chart-example-legend.tsx imports 2 module(s): chart, recharts.
Where is chart-example-legend.tsx in the architecture?
chart-example-legend.tsx is located at apps/v4/examples/radix/chart-example-legend.tsx (domain: DocumentationAtlas, subdomain: Changelog, directory: apps/v4/examples/radix).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free