Undraw — severed and recoiled
Variant: Severed
The same disappearing line, but nobody asked for it: a link between two services fails, and the gap opens where it failed, two-thirds of the way along, because that is the only way the user learns where. On one frame the line becomes two halves, each running from its own port to the break, and turns rust as it does — the snap has no transition of its own. Both halves recoil in 264ms on a steep ease-out, the long one covering twice the distance in the same time, which is how released elastic behaves: every point heads for its anchor at a speed set by its distance, so both ends land together. The ports learn on landing, not on the break; the recoil is the news arriving at each end. The redraw from the source travels in neutral wire and only turns olive after it reaches the far port, because a link that goes healthy on the way there is claiming a handshake that has not happened. Reach for it for dropped connections, broken integrations and failed pipeline edges, wherever a line ends because something went wrong rather than because someone removed it.
The source
A complete HTML document. Paste it into an empty .html file and it plays — no stylesheet, script, font, or image to fetch.
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Undraw — severed and recoiled</title>
<style>
:root {
/* Neutrals — fixed, never remixed. */
--ivory: #faf9f5;
--paper: #ffffff;
--oat: #e3dacc;
--slate: #141413;
/* Knobs — the remix API. A knob exists iff declared here and used below. */
--hue: 38.8;
--lift: 0;
--chroma: 1;
--round: 1;
--speed: 1;
/* Accents — derived from the knobs with the family's offsets baked in,
so one hue roll moves them together. Defaults reproduce the original hex. */
--clay: oklch(calc(0.6724 + var(--lift)) calc(0.1308 * var(--chroma)) var(--hue));
--clay-d: oklch(calc(0.5797 + var(--lift)) calc(0.127 * var(--chroma)) var(--hue));
--olive: oklch(
calc(0.6118 + var(--lift)) calc(0.0713 * var(--chroma)) calc(var(--hue) + 88.3)
);
--rust: oklch(
calc(0.5408 + var(--lift)) calc(0.1357 * var(--chroma)) calc(var(--hue) - 10.3)
);
/* Clock — 4.8s, shared by the whole undraw family (1% = 48ms).
1.44s connected, a 264ms recoil at the break, 1.68s down, a 480ms
redraw, and the rest connected again. */
--cycle: 4.8s;
--t: calc(var(--cycle) / var(--speed));
--ease-out: cubic-bezier(0.23, 1, 0.32, 1);
/* The recoil: almost all of the travel in the first third. Released
tension does not ease in, and it does not linger. */
--ease-accent: cubic-bezier(0.16, 1, 0.3, 1);
--_ink: color-mix(in srgb, var(--slate) 80%, transparent);
--_wire: color-mix(in oklch, var(--slate) 38%, var(--paper));
}
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
body {
min-height: 100vh;
display: grid;
place-items: center;
padding: clamp(10px, 3vw, 28px);
background: var(--ivory);
font-family:
system-ui,
-apple-system,
'Segoe UI',
Roboto,
sans-serif;
}
.card {
width: min(380px, 92vw);
border: 1px solid var(--oat);
border-radius: calc(14px * var(--round));
background: var(--paper);
}
.card svg {
display: block;
width: 100%;
height: auto;
}
.node rect {
fill: var(--ivory);
stroke: var(--oat);
stroke-width: 1;
rx: calc(8px * var(--round));
}
.node text {
font-size: 12.5px;
font-weight: 500;
fill: var(--_ink);
text-anchor: middle;
}
.link,
.half {
fill: none;
stroke-width: 2;
stroke-linecap: round;
stroke-dasharray: 100 200;
}
/* The whole link, drawn from the source port. It is cut out on the
frame the halves appear, which are geometrically identical to it, so the break
has no transition of its own — it is just the instant the line stops
being one thing. */
.link {
animation: link var(--t) infinite;
}
/* The redraw is an attempt, so it travels in the neutral wire colour and
only turns olive after it reaches the far port. A link that
colours itself healthy on the way there is claiming a handshake that
has not happened. */
@keyframes link {
0%,
29.99% {
stroke: var(--olive);
stroke-dashoffset: 0;
}
30%,
70% {
stroke: var(--_wire);
stroke-dashoffset: 102;
animation-timing-function: var(--ease-out);
}
80% {
stroke: var(--_wire);
stroke-dashoffset: 0;
animation-timing-function: ease;
}
83.75%,
100% {
stroke: var(--olive);
stroke-dashoffset: 0;
}
}
/* Each half runs from its own port to the break, so a rising offset
pulls the cut end home. With pathLength normalising both, the long
half covers twice the distance in the same 264ms — which is how a
released elastic behaves: every point heads for its anchor at a speed
proportional to its distance, and both ends land together. The break
sits at two-thirds, not the middle: a fault happens somewhere, and the
gap opening there is the only way the user learns where. */
.half {
stroke: var(--rust);
animation: half var(--t) infinite;
}
@keyframes half {
0%,
29.99% {
stroke-dashoffset: 102;
}
30% {
stroke-dashoffset: 0;
animation-timing-function: var(--ease-accent);
}
35.5%,
100% {
stroke-dashoffset: 102;
}
}
.spark {
fill: none;
stroke: var(--rust);
stroke-width: 1.5;
transform-box: fill-box;
transform-origin: center;
opacity: 0;
animation: spark var(--t) infinite;
}
@keyframes spark {
0%,
29.99% {
opacity: 0;
transform: scale(0.6);
}
30% {
opacity: 1;
transform: scale(0.6);
animation-timing-function: var(--ease-out);
}
35%,
100% {
opacity: 0;
transform: scale(1.8);
}
}
.port {
stroke-width: 1.5;
animation: port var(--t) infinite;
}
/* The ports learn on landing, not on the break: the recoil is the news
arriving at each end. They go hollow and rust together, and only take
olive back once the redraw has reached the far side. */
@keyframes port {
0%,
35.5% {
fill: var(--olive);
stroke: var(--olive);
animation-timing-function: ease;
}
39.25%,
80% {
fill: var(--paper);
stroke: var(--rust);
animation-timing-function: ease;
}
83.75%,
100% {
fill: var(--olive);
stroke: var(--olive);
}
}
.status text {
font-size: 12px;
font-weight: 500;
fill: var(--_ink);
opacity: 0;
}
.dot {
animation: dot var(--t) infinite;
}
@keyframes dot {
0%,
30% {
fill: var(--olive);
animation-timing-function: ease;
}
32%,
70% {
fill: var(--rust);
animation-timing-function: ease;
}
72%,
80% {
fill: var(--_wire);
animation-timing-function: ease;
}
82%,
100% {
fill: var(--olive);
}
}
/* Each label is out for 96ms before the next is in, with a 32ms gap
between, so two states never share a frame at half opacity. */
.s-up {
animation: s-up var(--t) infinite;
}
.s-lost {
animation: s-lost var(--t) infinite;
}
.s-retry {
animation: s-retry var(--t) infinite;
}
@keyframes s-up {
0%,
30% {
opacity: 1;
animation-timing-function: ease;
}
32%,
82.67% {
opacity: 0;
animation-timing-function: ease;
}
85.5%,
100% {
opacity: 1;
}
}
@keyframes s-lost {
0%,
32.67% {
opacity: 0;
animation-timing-function: ease;
}
35.5%,
70% {
opacity: 1;
animation-timing-function: ease;
}
72%,
100% {
opacity: 0;
}
}
@keyframes s-retry {
0%,
72.67% {
opacity: 0;
animation-timing-function: ease;
}
75.5%,
80% {
opacity: 1;
animation-timing-function: ease;
}
82%,
100% {
opacity: 0;
}
}
@media (prefers-reduced-motion: reduce) {
/* The same score on a clock twice as slow: every keyframe scales
together, so the alignments the comments rely on still hold. */
:root {
--t: calc(var(--cycle) * 2 / var(--speed));
}
/* Recoil and redraw are removed. The line turns rust and fades where
it broke, and fades back in wire before turning olive — the colour
and the status line still tell the whole story. */
.half,
.spark {
animation: none;
opacity: 0;
}
.link {
stroke-dashoffset: 0;
animation-name: link-calm;
}
@keyframes link-calm {
0%,
29.99% {
stroke: var(--olive);
opacity: 1;
}
30% {
stroke: var(--rust);
opacity: 1;
animation-timing-function: ease;
}
36%,
70% {
stroke: var(--rust);
opacity: 0;
}
70.01% {
stroke: var(--_wire);
opacity: 0;
animation-timing-function: ease;
}
80% {
stroke: var(--_wire);
opacity: 1;
animation-timing-function: ease;
}
83.75%,
100% {
stroke: var(--olive);
opacity: 1;
}
}
}
</style>
</head>
<body>
<div class="card">
<svg
viewBox="0 0 300 150"
role="img"
aria-label="A healthy link between two services snaps two-thirds of the way along; both cut ends recoil into their own ports, the status reads link lost, and after a pause the link redraws from the source and turns healthy again"
>
<g class="node">
<rect x="16" y="40" width="80" height="40" />
<text x="56" y="64.5">Catalog</text>
</g>
<g class="node">
<rect x="204" y="40" width="80" height="40" />
<text x="244" y="64.5">Holds</text>
</g>
<path class="link" pathLength="100" d="M 96 60 H 204" />
<path class="half" pathLength="100" d="M 96 60 H 168" />
<path class="half" pathLength="100" d="M 204 60 H 168" />
<circle class="spark" cx="168" cy="60" r="4" />
<circle class="port" cx="96" cy="60" r="3.5" />
<circle class="port" cx="204" cy="60" r="3.5" />
<g class="status">
<circle class="dot" cx="22" cy="118" r="3.5" />
<text class="s-up" x="31" y="122">Connected</text>
<text class="s-lost" x="31" y="122">Link lost</text>
<text class="s-retry" x="31" y="122">Reconnecting</text>
</g>
</svg>
</div>
</body>
</html>
The variant family
Same idea, one axis moved. Compare them side by side before you commit.