
The colour columns
Hover, SVG
The money flow card of an invented banking app, dark and premium like a Dribbble shot: the month's income (salary, freelance work, refunds) comes into the checking account and leaves again towards savings, investing, rent, groceries and everyday spending. Every flow is an SVG ribbon as thick as its money, a Sankey diagram that draws itself from left to right while the accounts grow. Touching a ribbon or an account lights it up with its glow, the others step back and a glass tooltip follows it on a spring with the amount and the share; pressed, the ribbon swells and settles. Sep and Oct morph every ribbon into the other month with a touch of bounce while the figures roll.
A folder that runs on its own: index.html, style.css, script.js and the libraries from a CDN. The React and Vue tabs hold the same demo as a ready component, which switches its animations off when it leaves the page.
<!doctype html>
<!--
"Money flow Sankey" from Animorio · https://animorio.com
License: free on your own sites and your clients’ sites, paid work included.
Not for resale, redistribution, templates or code collections · https://animorio.com/en/license/
-->
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>The Sankey chart of the money flow between accounts</title>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fontsource-variable/mona-sans@5.3.0/wdth.css">
<link rel="stylesheet" href="style.css">
</head>
<body>
<main class="stage" data-stage>
<!-- the money flow card of a banking app, Fernhall: the month's income comes in from three sources, gathers in the
checking account and leaves again towards rent, savings, investing, groceries and everyday spending. Every
flow is a ribbon as thick as its money, drawn in SVG; a soft streak of light runs along each one. Touching a
ribbon or an account lights it up, the others step back, a glass tooltip rides along it and the ribbon
swells on a spring when pressed. Sep and Oct morph the ribbons and roll the figures -->
<article class="flow" data-card aria-label="Money flow for October">
<span class="flow__light" aria-hidden="true"></span>
<header class="flow__head">
<div class="flow__brand">
<svg class="flow__mark" viewBox="0 0 20 20" aria-hidden="true">
<path d="M3 6.5c5 0 7 7 14 7" />
<path d="M3 13.5c5 0 7-7 14-7" />
</svg>
<span class="flow__title">Money flow</span>
</div>
<div class="flow__seg" role="tablist" aria-label="Month" data-seg>
<span class="flow__seg-pill" data-pill aria-hidden="true"></span>
<button class="flow__seg-btn" type="button" role="tab" aria-selected="false" data-month="1">Sep</button>
<button class="flow__seg-btn is-on" type="button" role="tab" aria-selected="true" data-month="0">Oct</button>
</div>
</header>
<div class="flow__sum">
<p class="flow__total"><span class="roll" data-total>$0,000</span></p>
<p class="flow__meta">
<span class="flow__chip">
<svg viewBox="0 0 12 12" aria-hidden="true"><path d="M3 7.6L6 4.6l3 3" /></svg>
<span class="roll" data-delta>+0.0%</span>
</span>
<span class="flow__sub" data-sub>in this month</span>
</p>
</div>
<div class="flow__chart" data-chart>
<svg class="flow__svg" data-svg role="img" aria-label="Income of 8,420 dollars flowing through checking into rent, savings, investing, groceries and everyday spending">
<defs data-defs></defs>
<g data-links></g>
<g data-nodes></g>
<g data-labels></g>
<g class="flow__mark-on" data-tick aria-hidden="true">
<line data-tick-line />
</g>
</svg>
<div class="flow__tip" data-tip aria-hidden="true">
<span class="flow__tip-path"><span data-tip-from>Salary</span>
<svg viewBox="0 0 12 12"><path d="M2.5 6h7M6.8 3.3L9.5 6 6.8 8.7" /></svg>
<span data-tip-to>Checking</span></span>
<span class="flow__tip-value" data-tip-value>$6,200</span>
<span class="flow__tip-share" data-tip-share>74% of income</span>
</div>
</div>
<footer class="flow__foot">
<span class="flow__foot-name">Savings rate</span>
<span class="flow__track" aria-hidden="true"><span class="flow__fill" data-fill></span></span>
<span class="flow__foot-value"><span class="roll" data-rate>00</span>%</span>
</footer>
</article>
<p class="sr" aria-live="polite" data-live></p>
</main>
<script src="https://cdn.jsdelivr.net/npm/gsap@3.15.0/dist/gsap.min.js"></script>
<script src="script.js"></script>
</body>
</html>Change values, colours and text with the controls and watch the animation respond live. Or write in the code yourself. Then download the folder with your changes.
31 values to change
With the Animorio connector, Claude Code, ChatGPT, Cursor or VS Code take it from here, guide included, and fit it into your project. Paste this request:
Take “Money flow Sankey” from Animorio and fit it into my siteThe SVG has a viewBox as big as its box, re-measured with a ResizeObserver: every frame the layout is worked out again in pixels. One scale (pixels per dollar) holds for every account, taken from the richer month, so September really is thinner.
Every flow is a closed path made of two Bézier curves, the top edge and the bottom one, with the control points halfway (CURVE). Each ribbon takes its slot on the side of the account it leaves and of the one it reaches, one under the other. The fill is a userSpaceOnUse gradient from one account's colour to the other's.
Every ribbon has its own clipPath, a rectangle that widens from left to right (draw) and on the way out shrinks from the left (undraw): so the fill, the thread of light on the edge and the running streak are revealed together. The accounts grow from their centre as their ribbon arrives.
The tooltip's point sits at a fraction u of the ribbon's width: the Bézier's x is inverted with a bisection to find t, and t gives the centre's y. The glass chases the point on a spring integrated by hand (stiffness 230, damping 23), and a white tick crosses the ribbon right there.
Switching between Oct and Sep is a single number going from 0 to 1 with a back.out: every value is interpolated and the whole layout recomputed, so the ribbons pass the mark and come back. The figures at the top are columns of 0 to 9 sliding with yPercent, one after another.
| Name | File | Default | What it changes |
|---|---|---|---|
RIBBON | script.js | 0.34 | How strong the ribbons are at rest, from 0 to 1. |
DIM | script.js | 0.3 | How much of the other ribbons stays when one is chosen. |
CURVE | script.js | 0.5 | How the ribbons bend: 0.3 steep in the middle, 0.65 long and soft. |
GAP | script.js | 10 | Pixels between two accounts in the same column. |
FLOW_SPEED | script.js | 40 | How fast the light runs along the ribbons, in pixels per second. |
FLOW_LIGHT | script.js | 0.5 | How bright that light is. |
DRAW | script.js | 1 | Seconds each ribbon takes to draw itself. |
SPRING | script.js | 1 | How springy the press and the month switch are: 0.4 calm, 2 bouncy. |
LOOP | script.js | true | Walks through the diagram by itself again and again. |
For the dashboard of a banking or budgeting app, the monthly summary of a personal finance tool, the page of a fintech that wants to show where the money goes: income, accounts and spending at a glance, with the detail on touch.
The same animation with adapted sizes: the card is as wide as the box, the diagram is at most 46% of the screen tall and redraws to its size, the label columns narrow. A finger touches a ribbon or an account and the tooltip follows it.
Nothing moves: the diagram fades in already drawn, the ribbons light up and dim with a fade, the tooltip appears still beside its point, the month switch swaps the ribbons with a fade and the figures change in place.
GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.
Compressed with gzip, the three demo files weigh 12 KB; the libraries: GSAP 28 KB.
Tested on 2 November 2026
Use it in your own projects and in your clients’ projects. Do not resell it or redistribute it as is. GSAP stays under its own Standard license. Full license.
Support Animorio
Animorio stays free thanks to the people who support it. If you like, buy us a coffee: it helps us make the next animations.
You asked for
We made it for you: it’s in the library, with the preview, the Playground and the code to copy.
An animation you can’t find, or a site to take apart in the journal: tell us which. We pick the next ones from here.
With your account’s email and password.
or with your email
You’re signed in as .
With your account, you can download the zip of every animation and every pack, for free.