Bar Chart

A column chart for comparing values across categories.

Install

npx shadcn add @clearly/bar-chart

Preview

Usage

import { BarChart } from "@/components/ui/bar-chart"

<BarChart />

Every Clearly component also accepts glass (subtle·medium·strong), specular and className.

Props

PropTypeDefaultDescription
dataArray<Record<string, unknown>>Row data for the chart.
configChartConfigRecharts color/label config keyed by data field.
xKeystring"week"Field name for the X-axis labels.
barsArray<{ key: string; radius?: number }>Bar series; defaults to all keys in config.