Square bars that grow from an ink baseline, outlined bars for weekends, a right-hand axis with ticks, two-row labels, a gliding dashed average, and a hover that dims the rest and lifts the value.
pnpm dlx shadcn@latest add @beautiful-ui-pro/bar-chartNeeds your registry key. Your components.json style picks the Base UI or Radix build: radix-*, new-york and default get Radix, base-* gets Base UI.
The CLI adds the styles to the CSS file named in components.json (tailwind.css). Check that it points at your global stylesheet, that the project uses Tailwind CSS v4, and that the file is imported in your root layout. Installed by hand: paste styles.css into that file.
Import it and pass your content. The props that matter most are listed next.
"use client";
import * as React from "react";
import { BarChart, type BarDatum } from "@/components/ui/notchset/bar-chart";
const days: BarDatum[] = [
{ label: "MON", value: 31200 },
{ label: "TUE", value: 33800 },
{ label: "WED", value: 29500 },
{ label: "THU", value: 35100 },
{ label: "FRI", value: 32400 },
{ label: "SAT", value: 18100, outline: true },
{ label: "SUN", value: 16900, outline: true },
];
export function RunsPerDay() {
const [day, setDay] = React.useState<number | null>(null);
return (
<div className="grid gap-2">
<span className="font-mono text-xs">{day == null ? "HOVER A DAY" : `${days[day]!.label} · ${days[day]!.value.toLocaleString()} RUNS`}</span>
<BarChart data={days} yMax={40000} unit="RUNS" active={day} onActiveChange={setDay} />
</div>
);
}data–
{ value, label?, sub?, outline? }[]Bars; label and sub make a two-row tick.
yMax / yTicks–
numberThe scale (4 gridlines).
unit–
stringThe axis caption.
average–
booleanThe dashed average line (on).
active / onActiveChange–
number | nullThe hovered bar, for your header.
components/ui/notchset/bar-chart.tsx
This component is included with Pro.
Try the live preview above. Get Pro to install the source.