Velocity X Components

Stats & Numbers

Waterfall Chart

Shows how a run of gains and losses builds a start total into an end total, step by step. Positive and negative steps carry their own glyph and position so the direction reads without relying on colour, with a plain-text breakdown underneath for screen readers.

Subscription Included with the Velocity Components subscription.
bash
$ velocityx add waterfall-chart

Built for astro.

Full docs for Waterfall Chart →

Needs a licence key — subscribe here, then velocityx loginonce.

astro v1.0.1
Waterfall Chart

Jan revenue

$142,000

New accounts

$18,400

Expansions

$6,200

Churn

$9,100

Discounts

$2,300

Dec revenue

$155,200

Waterfall from Jan revenue ($142,000) to Dec revenue ($155,200)
StepChangeRunning total
Jan revenue — $142,000
New accounts $18,400 $160,400
Expansions $6,200 $166,600
Churn −$9,100 $157,500
Discounts −$2,300 $155,200
Dec revenue — $155,200

Props

NameTypeRequiredDefaultDescription
startnumberYes
stepsWaterfallStep[]Yes
startLabelstringNo'Start'
endLabelstringNo'End'
unitstringNo''
decimalsnumberNo0Decimal places for the value formatter.
heightnumberNo220
classNamestringNo''

File this creates

The CLI writes this path into your project, relative to its root — nothing else moves.

text
components/velocity/waterfall-chart/WaterfallChart.astro

Using the Waterfall Chart component

Install it with velocityx add waterfall-chart. The CLI writes the source straight into your project — no runtime dependency, no registry lock-in, and it themes itself from the same primary-*/accent-* scale as the rest of the library.

More from Stats & Numbers.