Skip to content
motionprompts motionprompts

Pinned Phone Steps

GSAP animation component · Published 2026-11-21 · by vanguardia.dev

Open live demo ↗ Download source

What it does

A phone drawn entirely in HTML/CSS stays pinned beside three stacked steps while one scrubbed ScrollTrigger timeline (pin for +=300%, scrub 0.6) walks through them: each incoming step arrives grey and darkens to ink, and the phone screen changes with it, from a lock-screen notification, to a progress ring that draws itself while its number counts up, to a three-option segmented control whose pill slides across.

How it's built

Categoryscroll
Techgsap, lenis
GSAP pluginsScrollTrigger
Complexitysection
Performance costlight
Mobile-safeyes
Scrollhijacks scrolling

scroll pin scrub phone-mockup app-showcase svg-ring counter segmented-control steps lenis

Rebuild it with AI

This component's prompt is part of the paid library. Below you can read how it starts; the full prompt, the exact structure, timing and easing an AI agent needs to rebuild the effect, unlocks with any paid plan, yearly or lifetime.

# Pinned Phone Steps — a CSS phone stays pinned while three steps scrub through its screen
## Goal
Build a single full-viewport section that pins as soon as the page loads and stays pinned for three extra screens of scroll. On the left, a large two-line headline at the top and, at the bottom, three numbered steps (A, B, C) that occupy the *same* spot, so only one is visible at a time. On the right, a phone drawn entirely in HTML/CSS (dark chassis, dynamic island, status bar, gradient screen). One scrubbed GSAP timeline drives everything: the incoming step arrives grey and darkens to ink, and the phone screen changes with it — **A** a lock screen whose two notifications slide up, **B** a progress ring that draws itself while its number counts 0 → 94, **C** a three-option segmented control whose accent pill slides from the first option to the second and then the third while a temperature counts 6 → 22 → 85 °C. White background, near-black ink, one turquoise accent.
## Tech
Vanilla HTML/CSS/JS with ES module imports. `gsap` (npm) with the `ScrollTrigger` plugin, and `lenis` (npm) for smooth scrolling. `gsap.registerPlugin(ScrollTrigger)`.
Lenis must run on GSAP's ticker (with its own rAF, the smooth scroll and the scrub advance a frame apart and the counting number shimmers):
```js
const lenis = new Lenis({ duration: 1.1, easing: (t) => 1 - Math.pow(1 - t, 3.4) });
lenis.on("scroll", ScrollTrigger.update);
gsap.ticker.add((time) => lenis.raf(time * 1000));
gsap.ticker.lagSmoothing(0);
```
…

Premium prompt

Unlock this prompt, and every other one

From $99/year, or $139 once for lifetime access. Commercial license included.

See pricing Or start with the free set Already bought? Sign in

New components in your inbox

One email a week, only when new components ship, each with its live demo and prompt.