
The colour columns
Hover, SVG
A family tree over three generations: twelve people in circles with their initial, tied by thin branches that draw themselves from the top. Pick a person and the stretch of branches tying them to you lights up in coral, one piece after the other, those along the way take an edge and the others fade; below, the name, the kinship and how many steps apart you are roll in.
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>
<!--
"Family tree" 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>Family tree</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">
<!-- a family tree over three generations: the branches draw themselves, and whoever is picked lights
the line that ties them to you while the kinship rolls in below -->
<section class="ft" data-ft aria-labelledby="ft-title">
<header class="ft__head">
<span class="ft__name"><b id="ft-title">Family tree</b><span>Three generations</span></span>
<span class="ft__steps" aria-hidden="true"><span data-steps>You</span></span>
</header>
<div class="ft__tree" data-tree>
<svg viewBox="0 0 296 190" preserveAspectRatio="none" aria-hidden="true">
<path class="ft__line" data-edge data-a="m1" data-b="tomas" pathLength="1" d="M68 26H55"></path>
<path class="ft__line" data-edge data-a="m1" data-b="ines" pathLength="1" d="M68 26H81"></path>
<path class="ft__line" data-edge data-a="m2" data-b="kofi" pathLength="1" d="M228 26H215"></path>
<path class="ft__line" data-edge data-a="m2" data-b="marta" pathLength="1" d="M228 26H241"></path>
<path class="ft__line" data-edge data-a="m3" data-b="noel" pathLength="1" d="M148 96H121"></path>
<path class="ft__line" data-edge data-a="m3" data-b="ada" pathLength="1" d="M148 96H175"></path>
<path class="ft__line" data-edge data-a="m1" data-b="lena" pathLength="1" d="M68 26V61H30V81"></path>
<path class="ft__line" data-edge data-a="m1" data-b="noel" pathLength="1" d="M68 26V61H106V81"></path>
<path class="ft__line" data-edge data-a="m2" data-b="ada" pathLength="1" d="M228 26V61H190V81"></path>
<path class="ft__line" data-edge data-a="m2" data-b="ben" pathLength="1" d="M228 26V61H266V81"></path>
<path class="ft__line" data-edge data-a="m3" data-b="zoe" pathLength="1" d="M148 96V131H112V151"></path>
<path class="ft__line" data-edge data-a="m3" data-b="you" pathLength="1" d="M148 96V151"></path>
<path class="ft__line" data-edge data-a="m3" data-b="sam" pathLength="1" d="M148 96V131H184V151"></path>
<path class="ft__line" data-edge data-a="lena" data-b="rui" pathLength="1" d="M30 111V151"></path>
<path class="ft__hot" data-hot data-a="m1" data-b="tomas" pathLength="1" d="M68 26H55"></path>
<path class="ft__hot" data-hot data-a="m1" data-b="ines" pathLength="1" d="M68 26H81"></path>
<path class="ft__hot" data-hot data-a="m2" data-b="kofi" pathLength="1" d="M228 26H215"></path>
<path class="ft__hot" data-hot data-a="m2" data-b="marta" pathLength="1" d="M228 26H241"></path>
<path class="ft__hot" data-hot data-a="m3" data-b="noel" pathLength="1" d="M148 96H121"></path>
<path class="ft__hot" data-hot data-a="m3" data-b="ada" pathLength="1" d="M148 96H175"></path>
<path class="ft__hot" data-hot data-a="m1" data-b="lena" pathLength="1" d="M68 26V61H30V81"></path>
<path class="ft__hot" data-hot data-a="m1" data-b="noel" pathLength="1" d="M68 26V61H106V81"></path>
<path class="ft__hot" data-hot data-a="m2" data-b="ada" pathLength="1" d="M228 26V61H190V81"></path>
<path class="ft__hot" data-hot data-a="m2" data-b="ben" pathLength="1" d="M228 26V61H266V81"></path>
<path class="ft__hot" data-hot data-a="m3" data-b="zoe" pathLength="1" d="M148 96V131H112V151"></path>
<path class="ft__hot" data-hot data-a="m3" data-b="you" pathLength="1" d="M148 96V151"></path>
<path class="ft__hot" data-hot data-a="m3" data-b="sam" pathLength="1" d="M148 96V131H184V151"></path>
<path class="ft__hot" data-hot data-a="lena" data-b="rui" pathLength="1" d="M30 111V151"></path>
</svg>
<button class="ft__p" type="button" data-p="tomas" data-name="Tomas" data-rel="Your grandfather" style="left:13.514%;top:26px" aria-pressed="false" aria-label="Tomas. Your grandfather"><span>T</span></button>
<button class="ft__p" type="button" data-p="ines" data-name="Ines" data-rel="Your grandmother" style="left:32.432%;top:26px" aria-pressed="false" aria-label="Ines. Your grandmother"><span>I</span></button>
<button class="ft__p" type="button" data-p="kofi" data-name="Kofi" data-rel="Your grandfather" style="left:67.568%;top:26px" aria-pressed="false" aria-label="Kofi. Your grandfather"><span>K</span></button>
<button class="ft__p" type="button" data-p="marta" data-name="Marta" data-rel="Your grandmother" style="left:86.486%;top:26px" aria-pressed="false" aria-label="Marta. Your grandmother"><span>M</span></button>
<button class="ft__p" type="button" data-p="lena" data-name="Lena" data-rel="Your aunt" style="left:10.135%;top:96px" aria-pressed="false" aria-label="Lena. Your aunt"><span>L</span></button>
<button class="ft__p" type="button" data-p="noel" data-name="Noel" data-rel="Your father" style="left:35.811%;top:96px" aria-pressed="false" aria-label="Noel. Your father"><span>N</span></button>
<button class="ft__p" type="button" data-p="ada" data-name="Ada" data-rel="Your mother" style="left:64.189%;top:96px" aria-pressed="false" aria-label="Ada. Your mother"><span>A</span></button>
<button class="ft__p" type="button" data-p="ben" data-name="Ben" data-rel="Your uncle" style="left:89.865%;top:96px" aria-pressed="false" aria-label="Ben. Your uncle"><span>B</span></button>
<button class="ft__p" type="button" data-p="rui" data-name="Rui" data-rel="Your cousin" style="left:10.135%;top:166px" aria-pressed="false" aria-label="Rui. Your cousin"><span>R</span></button>
<button class="ft__p" type="button" data-p="zoe" data-name="Zoe" data-rel="Your sister" style="left:37.838%;top:166px" aria-pressed="false" aria-label="Zoe. Your sister"><span>Z</span></button>
<button class="ft__p is-you" type="button" data-p="you" data-name="You" data-rel="This is you" style="left:50.000%;top:166px" aria-pressed="true" aria-label="You. This is you"><span>Y</span></button>
<button class="ft__p" type="button" data-p="sam" data-name="Sam" data-rel="Your brother" style="left:62.162%;top:166px" aria-pressed="false" aria-label="Sam. Your brother"><span>S</span></button>
</div>
<footer class="ft__foot">
<span class="ft__who" aria-live="polite"><b class="ft__roll"><span data-who>You</span></b><span class="ft__roll ft__roll--sub"><span data-kin>This is you</span></span></span>
<button class="ft__back" type="button" data-back disabled>Back to you</button>
</footer>
</section>
<svg class="ghost" data-ghost viewBox="0 0 24 24" aria-hidden="true"><path d="M5 3.200 19.200 11l-6.300 1.600-3.300 5.900Z"></path></svg>
</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.
30 values to change
Works with Claude, Claude Code, ChatGPT, Cursor, VS Code, Windsurf, Codex, Gemini CLI
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 “Family tree” from Animorio and fit it into my sitePeople and the points where a couple meets are nodes, branches are edges. Each branch is an SVG path with pathLength 1 and two attributes saying which nodes it joins; people are real buttons laid on top, in percentages.
A breadth-first walk from the chosen node to “you” returns the branches crossed, in order, and the direction each is travelled in.
On top of each branch sits its coloured copy. Those on the way are drawn one after the other by animating stroke-dashoffset from 1 or from minus 1 to 0, depending on direction, so the line looks like a single one running.
| Name | File | Default | What it changes |
|---|---|---|---|
ACCENT | script.js | #ff7d6b | The colour of the person picked and of the line tying them to you. |
DRAW | script.js | 0.32 | How long each stretch of the line takes to draw. |
GROW | script.js | 1.1 | How long the branches take to draw on opening. |
In genealogy apps, family albums and family history sites; and, changing the names, for a company org chart, the lineage of a grape or a breed, the dependencies between the parts of a project.
The same card, as wide as the screen minus the margins: the branches stretch across the width and the people follow in percentages. The circles are 30 pixels wide but the tappable area is 44. The card is about 315 pixels tall and fits whole in the phone box.
The tree is already drawn on opening. On picking a person the coral line appears all at once, the circles change colour with no bounces and the labels change without rolling. The demo’s pointer does not start.
GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.
Compressed with gzip, the three demo files weigh 6.2 KB; the libraries: GSAP 28 KB.
Tested on 25 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.
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.