Search Open Water Design
Guide.
How to use Cauce in a project: CSS tokens, GSAP, Web Animations, physics that can be interrupted, the impulse, choreography, scroll, gestures, the eleven patterns and reduced motion. This is the package’s real API.
Introduction
Cauce is Flouvia’s motion system: eight named springs, a six-step duration scale and three bounces. Everything comes from a single source, springs.ts, which generates the CSS tokens, the GSAP presets, the JavaScript physics and the W3C tokens, so they never drift apart.
Nothing moves on a hand-drawn curve: no cubic-bezier, no GSAP eases, no loose durations. If a movement has no piece, it uses a spring from the scale.
The package
Cauce is @flouvia/cauce, currently at version 0.1.0. It’s private until v1, when it arrives on npm under the MIT license, like Gota. This is what it includes and how it’s imported.
import { SPRINGS, tween, impulse, stagger, after, PATTERNS, SpringValue, follow, drag, release } from '@flouvia/cauce';
import { tween, impulse } from '@flouvia/cauce/springs';
import { stagger, after, during } from '@flouvia/cauce/choreography';
import { PATTERNS, tideDome } from '@flouvia/cauce/patterns';
import { SpringValue } from '@flouvia/cauce/physics';
import { drag, project, release } from '@flouvia/cauce/gesture'; @flouvia/cauce: the whole API in one import.@flouvia/cauce/springs: the pieces, the scale, the bounces, the impulse and the physics of the curve.@flouvia/cauce/choreography: a group’s step, waits and distance.@flouvia/cauce/patterns: the numbers and math of the eleven patterns and of Gota’s gestures.@flouvia/cauce/native: Cauce on the platform, with no libraries.@flouvia/cauce/physics:SpringValueandfollow.@flouvia/cauce/gesture: gestures,drag,releaseand their physics.@flouvia/cauce/motion.css: the CSS tokens, for Tailwind v4.@flouvia/cauce/tokens.json: Cauce in the W3C design tokens format.@flouvia/cauce/ts: the TypeScript source, for those who prefer to compile it.
CSS and Tailwind
motion.css uses Tailwind v4’s @theme and @utility, so it’s imported from your Tailwind stylesheet.
@import 'tailwindcss';
@import '@flouvia/cauce/motion.css'; Each piece is a curve (--ease-drop, the curve as linear()), its real duration (--duration-drop, how long it takes to settle) and a utility that sets both (spring-drop).
<button class="transition-transform spring-drop hover:scale-104 motion-reduce:scale-100!">
Hablemos
</button> In a keyframe or a rule of your own, the two variables:
.sheet {
transition: translate var(--duration-sheet) var(--ease-sheet);
}
.card {
animation: enter var(--duration-rise) var(--ease-rise) both;
} On the platform
Cauce moves a complete interface with what the browser already provides, with no libraries: Web Animations with each piece’s curve as linear(), IntersectionObserver for what comes into view and a reading of the scroll for what follows it. @flouvia/cauce/native brings it together.
import { crossing, enter, follow, inView, scene, scrollProgress, stagger, to, TRAVEL } from '@flouvia/cauce';
inView(cards, (batch) => {
const step = stagger('rise', batch.length);
batch.forEach((card, i) => {
enter(card, { opacity: '0', transform: `translateY(${TRAVEL}px)` }, 'rise', i * step, { opacity: '1' });
});
});
to(panel, { transform: 'translateX(0)' }, 'sheet');
const track = follow(scene([{ el: bar, keyframes: [{ transform: 'scaleX(0)' }, { transform: 'scaleX(1)' }] }]));
scrollProgress(section, 'top 60%', 'bottom 75%', (progress) => track({ progress }));
crossing(chapters, 0.4, (chapter, inside) => chapter.classList.toggle('is-current', inside)); enter(el, from, piece, delay): enters from a state to its own style. While it waits for its turn it holds the starting state; when it ends, nothing stays on top.to(el, target, piece): takes an element from where it is to its target. If it was already moving, it continues from there.inView(elements, onEnter): fires once, in groups and in order, when each element crosses 88% of the window. What has already scrolled past counts too.crossing(elements, line, onChange): fires when an element enters or leaves a line of the window, like the index that lights up with the section being read.scrollProgressandscene: what follows the scroll, withfollowand drift.animateValue: a number frame by frame, for a CSS variable, a WebGL uniform or the scroll.draw: an SVG stroke that draws from start to end.
flouvia.com, its portal and Ops move this way: no page downloads an animation library when it opens. Long pinned scenes use GSAP as an adapter, with tween.
GSAP
For long pinned scenes, tween() returns a spring’s duration and curve, ready to spread into the tween: the duration is how long it takes to settle. A cascade’s step and the wait between two movements come from the choreography: stagger, after and during.
import { spring, stagger, tween } from '@flouvia/cauce';import { gsap } from 'gsap';
gsap.to(card, { opacity: 1, y: 0, ...tween('rise') });
gsap.to(words, { opacity: 1, y: 0, scale: 1, ...tween('bloom'), stagger: stagger('bloom', words.length) });
gsap.to(path, { strokeDashoffset: 0, ...tween(spring('scene')) }); Web Animations
With animate(), the duration comes from settle and the curve from cssLinear. Whatever should happen once it looks complete, like changing the page once the drop covers, waits for reach, not for the spring’s invisible tail.
import { cssLinear, reach, settle } from '@flouvia/cauce';
drop.animate(
{ transform: ['scale(0.02)', 'scale(1)'] },
{ duration: settle('flood') * 1000, easing: cssLinear('flood'), fill: 'both' },
);
setTimeout(() => location.assign(href), reach('flood', 0.985) * 1000); linear() is available since Safari 17.2, Chrome 113 and Firefox 112. In a browser without it, cssLinear returns the closest cubic-bezier so the animation still runs.
What can be interrupted
A CSS transition or a tween stops dead if you change its destination. SpringValue is a number with physics: if the destination changes midway, it carries on from where it was, with its velocity. That’s how the menu’s circle moves.
import { SPRINGS, SpringValue } from '@flouvia/cauce';
const radius = new SpringValue(0, (r) => {
menu.style.clipPath = `circle(${r}px at ${x}px ${y}px)`;
}, SPRINGS.flood);
radius.to(full);
radius.to(0, SPRINGS.sheet); | Name | Signature or values | What it does |
|---|---|---|
new SpringValue | (value, onChange, spring) | The number, the function that paints it every frame and its spring. |
.to | (target, spring?, onRest?) | Heads to the target without losing the velocity it had; the spring’s velocity, if any, is added. onRest is called once it settles. |
.set | (value) | Jumps to the value without animating. |
.stop | () | Stops where it is. |
.value · .velocity | number | Where it is and how fast it’s going, to read them or to release it with a gesture’s velocity. |
The impulse
What leaves its place and comes back to it, like a bell that rings or a heart that beats, is an impulse: a spring’s response to a kick of velocity, with its destination in the same place. What goes to a destination is never an impulse: it uses a piece.
Send
still · 753 ms
Bell
ripple · 1293 ms
Heartbeat
splash · 1741 ms
Your system asks for reduced motion: the impulse doesn’t move and a tap only changes the background.
It has three bounces of its own, because what comes back feels different from what arrives. Each one says how far it swings past its place to the other side, measured against its first peak.
| Name | Signature or values | What it does |
|---|---|---|
still | 0 · doesn’t swing past | Leaves and comes back without oscillating: send. |
ripple | 0.6 · 25.4 % to the other side | What rings or arrives: the bell, the arrow that drops. |
splash | 0.7 · 37.2 % to the other side | What beats or insists: the heartbeat, the wiggle, an error’s shake. |
impulseFrames gives its shape as evenly spaced frames, from 0 to 0, that run in any browser (even without linear()) and work just as well for an @keyframes; impulseSettle, how long it takes to come to rest. This is how the bell rings:
import { GESTURES, impulseFrames, impulseSettle } from '@flouvia/cauce';
const { spring, amplitude } = GESTURES.ring;
const frames = impulseFrames(spring).map((v, i, all) => ({ rotate: `${amplitude * v}deg`, offset: i / (all.length - 1) }));
bell.addEventListener('click', () => {
if (bell.getAnimations().length) return;
bell.animate(frames, { duration: impulseSettle(spring) * 1000 });
}); | Name | Signature or values | What it does |
|---|---|---|
impulse | (duration, bounce = 'still') | An impulse from the scale by its names: impulse('medium', 'ripple') is the bell. |
IMPULSE | still 0 · ripple 0.6 · splash 0.7 | The impulse’s three bounces. |
impulseFrames | (impulse, samples = 60) | The shape as frames: 0 at rest, 1 at its first peak and 0 once it’s still. |
impulseCurve | (impulse) | The same shape as a function of progress, from 0 to 1. |
impulseSettle | (impulse) | Seconds until it’s within 0.2 % of its first peak: the animation’s duration. |
GESTURES | ring · beat · slide · bounce · wiggle · shake · spin · draw | Gota’s gestures, each with its spring and its amplitude: its first peak, in degrees, scale or px. |
- An impulse that’s still moving isn’t replayed: another kick while it moves doesn’t count.
- Once, when something happens: never on a loop to call for attention.
- With reduced motion it doesn’t move. What it says also shows: with color, with text or with its state.
- At Flouvia, Gota’s gestures and the shake of a wrong code at sign-in (
GESTURES.shake).
Choreography
How a group moves: in what order, at what pace and in which direction. It all comes from the pieces: no step or wait is written by hand.
Your system asks for reduced motion: the sheet and its contents fade in together, in place.
- The stagger is tied to its piece:
stagger(piece, n)is the piece’s duration divided by 16 (rise 50 ms, bloom 37.5, sheet 31.25, drop 21.875). Past 16 items the step shortens, so a cascade never outlasts its piece. - Only what’s visible cascades: what has already gone by appears in place.
- The main thing first: the title, the text, the action and the rest. If a touch set it off, from the touch.
- Sequences are joined by the spring: the next thing enters
after(piece), once the previous one looks complete (98 %: sheet, 465 ms), orduring(piece), once it can be seen arriving (80 %: sheet, 239 ms). - One distance: what enters travels
TRAVEL, 16 px. The named exception is brand headlines (surface). - There and back: what leaves disappears together, on
ebb; what returns to its origin travels onsheet. - Whatever follows the scroll follows it on
drift(follow): nothing sticks. - With reduced motion, everything fades in together in
FADE.
import { gsap } from 'gsap';
import { after, stagger, TRAVEL, tween } from '@flouvia/cauce';
const items = [title, text, action, ...rows];
gsap.fromTo(sheet, { yPercent: 100 }, { yPercent: 0, ...tween('sheet') });
gsap.fromTo(items, { opacity: 0, y: TRAVEL }, {
opacity: 1,
y: 0,
...tween('rise'),
stagger: stagger('rise', items.length),
delay: after('sheet'),
});
gsap.to([sheet, ...items], { opacity: 0, ...tween('ebb') }); | Name | Signature or values | What it does |
|---|---|---|
stagger | (piece | spring, n) | The step between the items of a cascade, in seconds: the piece’s duration divided by 16 or, past 16, by n. |
after | (piece | spring) | Seconds until the previous thing looks complete (98 %): that’s when the next one enters. |
during | (piece | spring) | Seconds until the previous thing can be seen arriving (80 %): the next one enters over it. |
TRAVEL | 16 | How far what enters travels, in px. |
STEPS | 16 | How many steps fit in a piece. |
AFTER · DURING | 0.98 · 0.8 | The levels of after and during. |
Scroll
Whatever follows the scroll follows it on drift: the scene catches up with it on a spring instead of sticking to it. follow goes in the onUpdate of a ScrollTrigger without scrub; the first reading jumps without animating, so a reload halfway down the page doesn’t see the scene run.
import { gsap } from 'gsap';
import { ScrollTrigger } from 'gsap/ScrollTrigger';
import { follow } from '@flouvia/cauce';
const scene = gsap.to(track, { x: () => -distance(), ease: 'none' });
ScrollTrigger.create({ trigger: section, start: 'top top', end: '+=200%', pin: true, onUpdate: follow(scene) }); Nothing sticks to the scroll: not the cover that sinks (crest), not the footer that rises from depth (recede), not a frame sequence. A scene with its own progress() moves with follow too. The only direct thing is the scroll itself: the page the hand drags carries no spring.
Gestures
What makes an interface feel alive is motion that follows the hand: what you drag comes with you, what you throw keeps your speed and the edge gives like rubber. Cauce brings it in @flouvia/cauce/gesture.
- Hand velocity
- 0 px/s
- Settles at
- Center
Your system asks for reduced motion: the drop doesn’t give or fly; it arrives directly and fades in.
drag binds an element to Pointer Events: mouse, trackpad, finger and pen. A tap is still a click; past the threshold it captures the pointer, tells you how far the hand moved and, on release, how fast it was going over its last 100 ms. With an axis, its touch-action leaves the other one to scrolling.
On release, project works out where a throw would land with natural deceleration, nearest picks the resting point and release hands the hand’s velocity to the SpringValue: the spring starts with it. If you grab it mid-animation, stop() holds it where it is and the gesture carries on from there. This is how a sheet is pulled down to close it:
import { drag, nearest, project, release, rubberClamp, SpringValue, SPRINGS } from '@flouvia/cauce';
const height = sheet.offsetHeight;
const y = new SpringValue(0, (v) => {
sheet.style.translate = `0 ${v}px`;
}, SPRINGS.sheet);
let from = 0;
drag(sheet.querySelector('header'), {
axis: 'y',
onStart: () => {
y.stop();
from = y.value;
},
onMove: ({ dy, reduced }) => {
y.set(reduced ? Math.max(0, from + dy) : rubberClamp(from + dy, 0, height, height));
},
onEnd: ({ vy, reduced }) => {
const target = nearest(project(y.value, vy), [0, height]);
release(y, target, { velocity: vy, spring: target ? SPRINGS.ebb : SPRINGS.sheet, reduced, onRest: target ? close : undefined });
},
}); | Name | Signature or values | What it does |
|---|---|---|
drag | (element, { axis?, threshold = 4, touchAction?, capture = true, filter?, onStart?, onMove?, onEnd? }) | Binds the element to the gesture and returns the function that unbinds it. Each call receives { x, y, dx, dy, vx, vy, reduced, pointerType, event }; onEnd arrives with the hand’s velocity (0 if the system canceled the pointer). A native range, which already captures the pointer, passes capture: false. |
rubberband | (overflow, dimension, constant = 0.55) | What shows past the limit: it grows less and less and never reaches the dimension. The formula: (1 − 1 / (x · c / d + 1)) · d. |
rubberClamp | (value, min, max, dimension, constant?) | The value with rubber edges: inside it passes as is; outside, it gives. |
project | (position, velocity, rate = DECELERATION.normal) | Where a throw comes to rest: position + (velocity / 1000) · rate / (1 − rate). |
DECELERATION | normal 0.998 · fast 0.99 | UIScrollView’s deceleration rates, per millisecond. |
nearest | (position, points) | The closest resting point: open or closed, one end or the other. |
VelocityTracker | .add(position, ms?) · .velocity(ms?) · .reset() | The hand’s velocity over the last 100 ms, by least squares; 0 if it held still before letting go. |
release | (value, target, { velocity?, spring?, onRest?, reduced? }) | The handoff: the SpringValue heads for the target starting with the hand’s velocity. With reduced, it arrives directly. |
- A gesture is never the only way to do something: the keyboard, Escape and buttons do the same.
- While you drag it, it sticks to your hand, without a spring; the spring starts when you let go.
- With reduced motion it doesn’t give or fly: it follows the hand and, on release, arrives directly or fades.
- At Flouvia, the range’s drop gives at its ends, portal and Ops sheets are pulled down to close them and the phone menu closes with a swipe.
Eleven patterns
A pattern is a named moment made of pieces: changing pages, opening the menu, a brand headline. Its numbers and math live in @flouvia/cauce/patterns, and every interface animates it in its own DOM with those measurements, never its own.
| When | What to use |
|---|---|
| Changing pages. | tide |
| Opening a case from a row. | spill |
| Opening the menu. | well |
| A brand headline. | surface |
| A sentence worth reading. | soak |
| A link under a pointer. | roll |
| A case’s cover. | crest |
| A list that writes itself. | wake |
| The end of the page. | recede |
| A card that becomes the workspace. | swell |
| A sheet that comes in and leaves. | sink |
- Each pattern has a name of its own, in English in every language.
- A pattern is for its moment: it’s never decoration and never mixed with another.
- With reduced motion, none of them travel: what navigates navigates without animation and the rest fades in place in 200 ms.
- Each spec says which Onda sound goes with it. What arrives on its own is silent.
tide
The transition between pages: a panel in the brand color rises from the bottom, covers the page that leaves and uncovers the one that arrives. It says you changed places without losing the thread.
Services
Your system asks for reduced motion: the page changes without the panel.
- When
- When following a link to another page of the same site.
- When not
- Anchors on the same page, external links or links to another tab, downloads, and whatever already has its own exit, like the handoff to a case or the language switch.
- Where it starts
- At the bottom edge of the window, with its dome at the center.
- Pieces and timing
- It rises on
flood. Its dome follows the panel’s speed: almost nothing as it starts, up to 12 % of the height at its fastest and nothing as it brakes. It navigates once the corners cover, at 440 ms; the rest of the spring runs covered. On the new page the panel keeps rising and its bottom edge hangs like a drop. - If interrupted
- It isn’t interrupted: a second click while it rises doesn’t count and the first destination wins. Coming back with the back button, the page arrives uncovered.
- Reduced motion
- It navigates without the panel.
- Sound
- The link’s
tap; the panel itself is silent. - API
PATTERNS.tide(piece,dome),tideDome(t)andtideCover().
import { curve, PATTERNS, settle, tideCover, tideDome } from '@flouvia/cauce';
const run = settle(PATTERNS.tide.piece);
const progress = curve(PATTERNS.tide.piece);
const frames = Array.from({ length: 97 }, (_, i) => {
const at = i / 96;
const dome = `50% ${tideDome(at * run) * 100}vh`;
return {
transform: `translateY(${(1 - progress(at)) * 100}%)`,
borderTopLeftRadius: dome,
borderTopRightRadius: dome,
offset: at,
};
});
panel.animate(frames, { duration: run * 1000, fill: 'both' });
setTimeout(() => location.assign(href), tideCover() * 1000); spill
The handoff to a case: the pointer becomes a drop in the case’s tone that grows until it covers the screen. The page that arrives is born in that tone: there’s no cut between the row and its cover.
Your system asks for reduced motion: the page changes without the drop.
- When
- When opening something with a tone of its own from a list: a row of work that leads to its case.
- When not
- A destination without a tone that carries over, or an ordinary link: that’s
tide. It only answers a primary click with no modifier keys; everything else opens as usual. - Where it starts
- Where the pointer is, at its size (18 px). From the keyboard, from the row’s arrow; on touch, under the finger.
- Pieces and timing
- It grows on
floodand its bottom-right corner straightens onsheetuntil it takes the shape of Flouvia’s logomark. It navigates at 98.5 % offlood, at 401 ms; its bounce makes it bigger than the screen, where it already covers. - If interrupted
- It isn’t interrupted: while it grows, another click doesn’t navigate. Coming back with the back button, the drop withdraws and the pointer returns.
- Reduced motion
- It navigates without the drop.
- Sound
- The row’s
tap. - API
PATTERNS.spill(piece,corner,origin,navigate).
well
The menu: a circle grows from its button until it covers the screen, and each link rises as the edge reaches it. It says where the menu came from and where it goes back to.
- Work
- Services
- About us
Your system asks for reduced motion: the menu fades in place.
- When
- A menu that takes the whole screen and opens from a button.
- When not
- A menu anchored to its button that doesn’t cover the screen: it opens on
sheet, like a popover. - Where it starts
- At the center of the button, at its radius (18 px).
- Pieces and timing
- The radius grows on
floodto the farthest corner; its bounce lands off screen. Each link risesTRAVELonrisejust as the edge reaches its center (wellEdge). It closes onsheetback to the button, with no bounce, and the links leave together onebb, 6 px upward. - If interrupted
- It can be interrupted: the radius is a
SpringValue. Close it while it opens, or the other way round, and it carries on from where it was, with its velocity. - Reduced motion
- The whole panel fades in place in 200 ms and the links are already there.
- Sound
openon opening andcloseon closing.- API
PATTERNS.well(open,close,origin,links,exit,lift) andwellEdge(distance, radius, origin?).
import { gsap } from 'gsap';
import { PATTERNS, SPRINGS, SpringValue, TRAVEL, tween, wellEdge } from '@flouvia/cauce';
const { open, close, origin, links, exit, lift } = PATTERNS.well;
const radius = new SpringValue(origin, (r) => {
menu.style.clipPath = `circle(${r}px at ${x}px ${y}px)`;
}, SPRINGS[open]);
radius.to(full);
gsap.fromTo(items, { opacity: 0, y: TRAVEL }, {
opacity: 1,
y: 0,
...tween(links),
stagger: (_, item) => wellEdge(distanceTo(item), full),
});
radius.to(0, SPRINGS[close]);
gsap.to(items, { opacity: 0, y: lift, ...tween(exit) }); surface
Brand headlines: each word comes up to the surface, one after another. It says the page’s name comes first.
Every word comes to the surface.
Your system asks for reduced motion: the words fade in together.
- When
- A page’s name or the tagline, in the brand typeface, once as the page loads.
- When not
- Body text, subheads and what enters on scroll, which enter on
rise. Never two headlines at once. - Where it starts
- Each word, 0.07 em below its place and at 0.92 of its size, grows from its baseline (origin 50 % 80 %).
- Pieces and timing
- Each word arrives on
bloom, one everystagger('bloom'): 37.5 ms. One- and two-letter words travel with the next one and the last two go together, so none is left alone. The headline carries its whole text for screen readers. - If interrupted
- It isn’t interrupted: it runs once and stays.
- Reduced motion
- The words fade in together, in place, in 200 ms.
- Sound
- None: what arrives on its own is silent.
- API
PATTERNS.surface(piece,travel,scale,origin) andstagger.
import { gsap } from 'gsap';
import { PATTERNS, stagger, tween } from '@flouvia/cauce';
const { piece, travel, scale, origin } = PATTERNS.surface;
const size = parseFloat(getComputedStyle(headline).fontSize);
gsap.fromTo(words, { opacity: 0, y: travel * size, scale, transformOrigin: origin }, {
opacity: 1,
y: 0,
scale: 1,
...tween(piece),
stagger: stagger(piece, words.length),
}); soak
A sentence worth reading: a light runs through it letter by letter, ahead of the reader.
Some sentences deserve to be read slowly, letter by letter, as if someone were lighting them up.
Your system asks for reduced motion: the sentence is already lit.
- When
- A single sentence per page, the one that sums up what follows. By time, as the page loads, or with the scroll, if it lives further down.
- When not
- Long paragraphs, buttons, labels or two sentences on the same screen.
- Where it starts
- At the first letter. The whole sentence starts dim, at 0.24.
- Pieces and timing
- Each letter goes from 0.24 to 1 on the
ebbcurve, at 62 letters per second; spaces don’t count. With the scroll, the front of light, about 21 letters wide, follows the scroll ondrift. Screen readers read the whole sentence at once. - If interrupted
- With the scroll it goes both ways: down it lights up, up it dims. By time it runs once.
- Reduced motion
- The sentence is already lit.
- Sound
- None.
- API
PATTERNS.soak(piece,rate,dim) andfollow.
import { gsap } from 'gsap';
import { PATTERNS, tween } from '@flouvia/cauce';
const { piece, rate, dim } = PATTERNS.soak;
gsap.set(letters, { opacity: dim });
gsap.to(letters, { opacity: 1, ...tween(piece), stagger: 1 / rate }); roll
The letter roller: as the pointer passes over a link, each letter rises and reveals its copy. It says this can be touched.
Your system asks for reduced motion: the letters don’t roll.
- When
- Large text links, or links in a group: a menu, the footer.
- When not
- Without a pointer, since touch has no hover; on Cuenca buttons, which already give on
drop; and on links inside a paragraph. - Where it starts
- At the first letter, from left to right.
- Pieces and timing
- Each letter rises on
drop, one everystagger('drop'): 21.9 ms up to 16 letters. When it ends it goes back to zero, where the copy and the letter are identical, so the jump can’t be seen. - If interrupted
- If it’s already rolling, it doesn’t repeat, and it finishes even if the pointer leaves.
- Reduced motion
- It doesn’t roll: only the color changes, cross-faded.
- Sound
- The link’s
hover, if it has one. - API
PATTERNS.roll(piece) andstagger.
crest
A case’s cover: its piece fills the screen and the sheet peeks from below with its name, to say there’s more. As the sheet rises, the cover sinks.
Your system asks for reduced motion: the sheet has already peeked and the cover doesn’t sink.
- When
- A cover that is only an image or a video, with its content in a sheet below.
- When not
- A cover with text of its own, or a page with no piece to show.
- Where it starts
- At the bottom edge: the sheet peeks a quarter of the screen, a third on a phone.
- Pieces and timing
- The sheet peeks on
sheetand what names the case entersduring('sheet')onrise. With the scroll, the cover sinks to 0.94 and darkens to 60 %, following ondrift. When the pointer passes over the peeking sheet, it lifts 10 px ondrop. - If interrupted
- It follows the scroll both ways: back at the top, the cover comes out of the shade.
- Reduced motion
- The sheet has already peeked and the cover neither sinks nor darkens.
- Sound
- None. Tapping the sheet plays
tap. - API
PATTERNS.crest(piece,depth,dim,hover,hoverPiece) andfollow.
wake
The separator that draws itself: in a list that enters on scroll, each row’s line is traced from the left along with its row. The list writes itself in order.
Your system asks for reduced motion: the rows fade in together, with their lines complete.
- When
- Lists with separators: services, work, questions.
- When not
- Lone separators, cards or data tables: there the line is already in place.
- Where it starts
- At the left edge of each separator.
- Pieces and timing
- The row rises
TRAVELonriseand its line draws on a 1.2 s spring from the scale that starts already moving (spring('scene', 'flat', 8)), with its row’s delay. - If interrupted
- It isn’t interrupted: it enters once. Reloading halfway down the page, whatever is already past appears with its line complete.
- Reduced motion
- The rows fade in together and their lines are already drawn.
- Sound
- None.
- API
PATTERNS.wake(line,row) andstagger.
recede
The end of the page: the page lifts and the footer rises from the depth where it was waiting. It says this is where it ends.
Your system asks for reduced motion: the footer is already there, without depth.
- When
- A footer behind a sheet that rises over a fixed cover.
- When not
- A page without a curtain, or a phone: there the footer’s content rises as it enters, following the scroll.
- Where it starts
- Under the page, fixed, from above its center (origin 50 % 35 %).
- Pieces and timing
- It grows from 0.94 to 1 and its shade goes from 60 % to nothing, following the scroll on
driftover its height. Its content enters onrise, with the choreography’s step, once the footer shows 6 %. - If interrupted
- It follows the scroll both ways.
- Reduced motion
- No depth and no shade: the footer is already there.
- Sound
- None.
- API
PATTERNS.recede(depth,dim,reveal) andfollow.
swell
The card that becomes the workspace: it grows from its place until it fills the screen, and its contents enter once it has arrived. It says you’re inside what you chose.
Your system asks for reduced motion: the panel fades in place.
- When
- A card that opens a task: a form, an editor, a multi-step flow.
- When not
- Details that fit in a sheet or a modal: those go on
sinkorsheet. - Where it starts
- In the card itself, at its radius (28 px). Its title travels from the card to the header.
- Pieces and timing
- The card grows on
sheet; the scrim entersduring('sheet'), at 239 ms, and the contentsafter('sheet'), at 465 ms, cascading onrise. On closing, everything at once: the contents leave together onebbwhile the card and its title go back onsheet. - If interrupted
- It turns around from where it is: closing it while it opens, or opening it while it closes, carries on from its pose. Back closes it too.
- Reduced motion
- The panel fades in place.
- Sound
openon opening andcloseon closing.- API
PATTERNS.swell(piece,radius,exit),afterandduring.
sink
The sheet that comes in from its edge and leaves the way it came, by hand or with a button. It says where it came from and how it closes.
Your system asks for reduced motion: the sheet fades, and dragged, it doesn’t give.
- When
- Sheets, dialogs and panels that open over the page, especially on a phone.
- When not
- What covers the whole screen, which is
swellorwell, and what anchors to a button, which opens onsheet. - Where it starts
- At its edge: the bottom, on a phone. On desktop, where it sits at the center, it rises 16 px and fades in.
- Pieces and timing
- It enters on
sheet. It’s pulled down from its header; on release, if it would land past halfway it carries on withebband the hand’s velocity, and if not it goes back onsheet. The X, Escape and the backdrop let it leave the way it came. - If interrupted
- It can be caught mid-air: dragging it halfway in holds it where it is. If it closes halfway in, it leaves from where it is.
- Reduced motion
- It comes and goes with a 200 ms fade; dragged, it doesn’t give or fly.
- Sound
openon opening andclosewhen asked to close.- API
PATTERNS.sink(open,close,back) and the gestures:drag,project,nearestandrelease.
W3C tokens
tokens.json is Cauce in the W3C design tokens format (DTCG 2025.10), for Style Dictionary, Figma or a native project: the scale, the bounces, the fade and the eight pieces. The format has no type for a spring, so each piece is a group with its duration and bounce (aliases of the scale), its velocity and how long it takes to settle; in
$extensions it carries its CSS curve, its stiffness and its damping.
{
"cauce": {
"spring": {
"drop": {
"duration": { "$type": "duration", "$value": "{cauce.duration.base}" },
"bounce": { "$type": "number", "$value": "{cauce.bounce.firm}" },
"velocity": { "$type": "number", "$value": 0 },
"settle": { "$type": "duration", "$value": { "value": 0.447, "unit": "s" } },
"$extensions": {
"com.flouvia.cauce": { "easing": "linear(0, 0.0128, …, 1)", "stiffness": 322.27, "damping": 28.72 }
}
}
}
}
} SwiftUI takes the duration and the bounce as they are. Jetpack Compose takes the stiffness and the damping ratio, which is 1 minus the bounce.
// SwiftUI
withAnimation(.spring(duration: 0.35, bounce: 0.2)) { pressed = true }
// Jetpack Compose
animateFloatAsState(target, spring(dampingRatio = 0.8f, stiffness = 322.27f)) Reference
| Name | Signature or values | What it does |
|---|---|---|
SPRINGS | drop · bloom · sheet · rise · ebb · flood · surge · drift | The eight pieces, each { duration, bounce, velocity }. |
DURATION | brief 0.25 · base 0.35 · medium 0.5 · wide 0.6 · slow 0.8 · scene 1.2 | The scale, in seconds. |
BOUNCE | flat 0 · firm 0.2 · signature 0.3 | The three bounces. |
FADE | 0.2 | The reduced-motion fade, in seconds. |
spring | (duration, bounce?, velocity?) | A spring from the scale by its names: spring('scene'), spring('wide', 'firm'). |
tween | (piece | spring) | { duration, ease } for GSAP: the duration is the settle time. |
cssLinear | (piece | spring, samples = 48) | The curve as a CSS linear(). |
settle | (piece | spring) | Seconds until it’s within 0.2 % of its destination: the animation’s real duration. |
reach | (piece | spring, level) | Seconds until progress reaches that level. |
curve | (piece | spring) | Progress (0 to 1; with bounce, past 1) over the settle time. |
displacement | (spring) | What’s left to arrive (1 to 0) at t seconds. |
constants | (spring) | { stiffness, damping } for a unit mass. |
SpringValue | new SpringValue(value, onChange, spring) | A number with physics that keeps its velocity when its destination changes. |
follow | (timeline, spring = drift) | A ScrollTrigger’s onUpdate: the scene catches up with the scroll on a spring. |
drag · release | rubberband · rubberClamp · project · nearest · VelocityTracker · DECELERATION | Gestures: what you drag comes with you and the spring starts with your speed (see “Gestures”). |
impulse | IMPULSE · impulseFrames · impulseCurve · impulseSettle | What leaves its place and comes back to it (see “The impulse”). |
stagger · after · during | TRAVEL · STEPS · AFTER · DURING | Choreography: a cascade’s step, the waits and the distance (see “Choreography”). |
PATTERNS | tide · spill · well · surface · soak · roll · crest · wake · recede · swell · sink | The numbers of the eleven patterns, each with its pieces. |
tideDome | (t, dome = 0.12) | The height of tide’s dome at t seconds, as a fraction of the height: it follows the panel’s speed. |
tideCover | (dome = 0.12) | Seconds until tide’s panel covers at its corners too: that’s when it navigates. |
wellEdge | (distance, radius, origin = 18) | Seconds until well’s circle reaches that distance: that’s when each link rises. |
Six principles
- It starts where you touch it: the menu grows from its button and nothing appears out of nowhere.
- It responds instantly and settles long:
dropreaches 98 % in 0.21 s and the ending takes its time. - One bounce, like a drop: what arrives passes a little, once, and settles; it never trembles. What leaves and comes back, the impulse, dies down on its own and never repeats.
- It leaves faster than it arrives:
ebblasts about half as long as what comes in. - It can be interrupted: what changes course midway keeps its velocity.
- Without motion, it still makes sense: with reduced motion nothing travels or bounces.
Reduced motion
With prefers-reduced-motion nothing travels, grows or bounces: color and opacity changes fade in place in 200 ms (FADE, --duration-fade). Motion is never the only sign that something changed.
Your system asks for reduced motion: both fade in place.
What grows on hover gets motion-reduce:scale-100! and what enters with a keyframe gets motion-reduce:animate-fade-in: it appears in place, without traveling.
<a class="transition-transform spring-drop hover:scale-104 motion-reduce:scale-100!">…</a>
<dialog class="sheet-in motion-reduce:animate-fade-in">…</dialog> What a script opens fades instead of growing or traveling:
import { FADE, tween } from '@flouvia/cauce';
const reduce = matchMedia('(prefers-reduced-motion: reduce)').matches;
gsap.to(panel, reduce ? { opacity: 1, duration: FADE, ease: 'none' } : { opacity: 1, y: 0, ...tween('sheet') }); An impulse doesn’t move, a cascade fades in together and no pattern travels: what navigates navigates without animation and the rest fades in place. With your system set to reduced motion, every demo in this guide looks like this.
When to use each piece
| When | What to use |
|---|---|
| You touch it: hover it, press it, switch it on. | drop |
| It arrives on its own: a headline, a notice, a context menu. | bloom |
| It opens without covering the screen: a sheet, a modal, an accordion. | sheet |
| It enters on scroll or as the page loads. | rise |
| It leaves: closing, dismissing, removing. | ebb |
| It covers the screen: the curtain between pages, a panel that floods. | flood |
| It winds back before it goes, or changes shape. | surge |
| It follows the scroll smoothly. | drift |
| None of the above: a stroke being drawn, a number counting up. | spring('scene') |
| It leaves its place and comes back: a bell, a heartbeat, a shake. | impulse('medium', 'ripple') |
| You drag it: it goes with your hand and, when you let go, the spring starts with your speed. | drag + release |
| A named moment: changing pages, opening the menu, a brand headline. | PATTERNS |
Never: blur on entrances, magnetic hover, scales above 1.06 or multi-layer choreography.
Figma is a trademark of its owner; its logo appears only to show compatibility and does not imply endorsement.