Home / Function/ ChartLineLabelCustom() — ui Function Reference

ChartLineLabelCustom() — ui Function Reference

Architecture documentation for the ChartLineLabelCustom() function in chart-line-label-custom.tsx from the ui codebase.

Entity Profile

Dependency Diagram

graph TD
  67ffa94c_c3b5_3ba4_b7d9_5715e5a0994a["ChartLineLabelCustom()"]
  f787ea9e_1c2f_dc1a_8bcf_cacbe4d2e66f["chart-line-label-custom.tsx"]
  67ffa94c_c3b5_3ba4_b7d9_5715e5a0994a -->|defined in| f787ea9e_1c2f_dc1a_8bcf_cacbe4d2e66f
  style 67ffa94c_c3b5_3ba4_b7d9_5715e5a0994a fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

apps/v4/registry/new-york-v4/charts/chart-line-label-custom.tsx lines 58–123

export function ChartLineLabelCustom() {
  return (
    <Card>
      <CardHeader>
        <CardTitle>Line Chart - Custom Label</CardTitle>
        <CardDescription>January - June 2024</CardDescription>
      </CardHeader>
      <CardContent>
        <ChartContainer config={chartConfig}>
          <LineChart
            accessibilityLayer
            data={chartData}
            margin={{
              top: 24,
              left: 24,
              right: 24,
            }}
          >
            <CartesianGrid vertical={false} />
            <ChartTooltip
              cursor={false}
              content={
                <ChartTooltipContent
                  indicator="line"
                  nameKey="visitors"
                  hideLabel
                />
              }
            />
            <Line
              dataKey="visitors"
              type="natural"
              stroke="var(--color-visitors)"
              strokeWidth={2}
              dot={{
                fill: "var(--color-visitors)",
              }}
              activeDot={{
                r: 6,
              }}
            >
              <LabelList
                position="top"
                offset={12}
                className="fill-foreground"
                fontSize={12}
                dataKey="browser"
                formatter={(value: keyof typeof chartConfig) =>
                  chartConfig[value]?.label
                }
              />
            </Line>
          </LineChart>
        </ChartContainer>
      </CardContent>
      <CardFooter className="flex-col items-start gap-2 text-sm">
        <div className="flex gap-2 leading-none font-medium">
          Trending up by 5.2% this month <TrendingUp className="h-4 w-4" />
        </div>
        <div className="text-muted-foreground leading-none">
          Showing total visitors for the last 6 months
        </div>
      </CardFooter>
    </Card>
  )
}

Subdomains

Frequently Asked Questions

What does ChartLineLabelCustom() do?
ChartLineLabelCustom() is a function in the ui codebase, defined in apps/v4/registry/new-york-v4/charts/chart-line-label-custom.tsx.
Where is ChartLineLabelCustom() defined?
ChartLineLabelCustom() is defined in apps/v4/registry/new-york-v4/charts/chart-line-label-custom.tsx at line 58.

Analyze Your Own Codebase

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

Try Supermodel Free