← Components

Text to Timeline

Pro

Images inside a sentence fly out on scroll and land on an editor timeline.

Scroll · ProInstall ↓
Open preview ↗
Loading the demoNew tab ↗

Customize

12 °
1.0 s
0.060 s
180
Your code
<TextToTimeline media={media} />

Changes show live and stay in the address, so a link keeps them.

Code

This one is a Pro component

Pro components come with Pro Components, any Templates plan or All-Access. Sign in, or enter your licence key, to see the code here and copy it, or install it with the shadcn CLI below.

Install

With the shadcn CLI

Pro components install from a private registry that checks your licence key (Pro Components, a Templates plan or All-Access). Set it up once per project. The key stays in an environment variable and never goes into components.json.

1. Add the registry

Merge this into components.json.

components.json
{
  "registries": {
    "@dimaac-pro": {
      "url": "https://api.dimaac.com/v1/ui/r/{name}.json",
      "headers": { "Authorization": "Bearer ${DIMAAC_LICENSE_KEY}" }
    }
  }
}

2. Add your key

Put it in .env.local (or your shell) and keep that file out of git. The CLI fills in ${DIMAAC_LICENSE_KEY} from it.

.env.local
DIMAAC_LICENSE_KEY=your-licence-key

3. Add the component

npx shadcn@latest add @dimaac-pro/text-to-timeline

@dimaac-pro is the registry from step 1. More in Docs

By hand

npm install gsap @gsap/react
  1. Install the packages it uses: gsap, @gsap/react.
  2. Copy the component file from the Code panel (once your licence key unlocks it) into components/dimaac/text-to-timeline.tsx.
  3. It's styled with Tailwind v4 classes. If that folder sits outside the places Tailwind scans, add it with @source in your CSS.
  4. Import it with import { TextToTimeline } from "@/components/dimaac/text-to-timeline" and give its parent a size: it fills it.

Props

PropTypeDefaultDescription
sentencestring"DiMaac {media} turns words into motion: {media} scroll, and the pictures {media} fly out, tilt {media} and land {media} right on the timeline."The sentence. Each {media} token becomes a slot for the next image in media.
media (required)TextToTimelineMedia[]-The images, in slot order. Extra images sit in the timeline without a slot.
tiltnumber12How far an image tilts at the middle of its flight, in degrees. Neighbours tilt opposite ways.
scrubnumber1How many seconds the images take to catch up with the scrollbar. 0 ties them to it exactly.
wordStaggernumber0.06Delay between one word glowing in and the next, in seconds.
glowHuenumber180Hue of the first word's glow (0-360). Each word after it shifts the hue a little. Also tints the playhead.
scrollerHTMLElement | string | nullnullThe element that scrolls, or a selector for it. Leave empty for the page itself.
as"h1" | "h2" | "p"-The tag the sentence is written in.
classNamestring""Extra classes for the outer box.

Use with AI

Agent prompt

Paste it into Claude Code, Cursor or any coding agent, or open it straight in a chat. It carries your Customize settings.

Prompt
Add the Text to Timeline component (<TextToTimeline />) from DiMaac UI to this project. It is a Pro component, so its source needs the owner's DiMaac licence key (Pro Components, a Templates plan or All-Access).

Docs: https://ui.dimaac.com/components/text-to-timeline

1. Add the Pro registry to components.json (merge it into "registries"). Don't write the key into the file:
{
  "registries": {
    "@dimaac-pro": {
      "url": "https://api.dimaac.com/v1/ui/r/{name}.json",
      "headers": { "Authorization": "Bearer ${DIMAAC_LICENSE_KEY}" }
    }
  }
}

2. The owner puts their licence key in .env.local (keep it out of git): DIMAAC_LICENSE_KEY=your-licence-key
   Ask them for it if it isn't set. Never print it or commit it.

3. Install it with:
npx shadcn@latest add @dimaac-pro/text-to-timeline

The registry item is https://api.dimaac.com/v1/ui/r/text-to-timeline.json and wants the header "Authorization: Bearer <licence key>".

Then use it like this:
import { TextToTimeline } from "@/components/dimaac/text-to-timeline";
<TextToTimeline media={media} />

It imports gsap, @gsap/react; the CLI installs them. It uses Tailwind v4 classes, so make sure Tailwind scans that folder.
Give its parent a size, keep light and dark mode working and keep its prefers-reduced-motion fallback.
Full index for agents: https://ui.dimaac.com/llms.txt

Files agents read

llms.txt
Every component and how to install it
text-to-timeline.md
This page as Markdown: install, props and the full source

About

A big sentence with small rounded images sitting between its words. The words glow in one by one, then, as you scroll, every image leaves its slot, tilts in flight and lands in its clip on an editor-like timeline while a playhead runs along the ruler and the timecode counts up. Write the sentence with {media} tokens where the images go. Each image really lives in the timeline and is only started at its slot, so the layout stays plain HTML: no clones, no pinning. One scrubbed GSAP timeline, re-measured on resize and when the font arrives. It takes a scroller (an element or a selector) for scrolling boxes, and when the visitor prefers reduced motion the images simply sit in both the sentence and the timeline, still.

Installs to
components/dimaac/text-to-timeline.tsx
Uses
gsap, @gsap/react
Tags
gsap, scrolltrigger, scroll, images, text, hero

Abstract Wavy Design by rena on Lummi (Lummi License). Portrait with Neon Sunglasses by Shaun Duval on Lummi (Lummi License). Portrait Through Orange Frame by Bernardo Lickfold on Lummi (Lummi License). Vibrant Cylindrical Arrangement by SHIHO on Lummi (Lummi License). Cinematic Silhouette by alexaperios on Lummi (Lummi License).