Black Friday: 30% off Pro

Get 30% off

Updated

Ridgeline Chart

Pro

Preview

Customize

Rows7
Pitch38px
Overlap1.8
Accent

Installation

Pro

Ridgeline Chart is a Pro component

Sign in to see the source, or install it with a license key. The live preview and props above are free to explore.

Install with a key

  1. Add the Pro registry to components.json:
    components.json
    {
      "registries": {
        "@uibrik-pro": {
          "url": "https://uibrik.com/r/pro/{name}.json",
          "headers": { "Authorization": "Bearer ${UIBRIK_LICENSE}" }
        }
      }
    }
  2. Put your key in .env.local and add that file to .gitignore:
    .env.local
    UIBRIK_LICENSE=your-license-key
  3. Install it:
    Terminal
    npx shadcn@latest add @uibrik-pro/ridgeline-chart

Usage

import { RidgelineChart } from "@/components/uibrik/ridgeline-chart/ridgeline-chart";​<RidgelineChart  title="Activity by hour"  pitch={38}  overlap={1.8}  accent=""  format={{}}  onActiveChange={(index) => {}}  // rows={[{ key: "…", label: "…", values: [0] }]}  // labels={["…"]}/>

Where to use Ridgeline Chart

  • Distribution comparisons

    Overlapping ridges show one distribution per row, which beats several separate histograms.

  • Research data

    Pointing at a row lifts it forward so a single group can be read clearly.

  • Time-of-day patterns

    Scrubbing reads every row at once, showing when each group peaks.

    Pairs with Tide Chart

Props

RidgelineChart
title
Type string
"Activity by hour"
Names what is plotted.
pitch
Type number
38
Distance between ridge baselines.
overlap
Type number
1.8
Peak height as a multiple of the pitch. Above 1 the ridges overlap.
accent
Type string
""
Highlight colour. Empty uses the chart palette.
rows
Type { key: string; label: string; values: number[] }[]
–
One ridge per row, drawn top to bottom.
labels
Type string[]
–
The x axis, one label per value.
format
Type Intl.NumberFormatOptions
{}
Formats every number.
onActiveChange
Type (index: number | null) => void
–
Called with the label index under the cursor.
className
Type string
–
Classes for the outer shell.