Skip to main content
rule CX Codex

depth-scatter-assemble — Claude Code rule: 3D depth-cloud assembly

depth-scatter-assemble — a rule for scenes where glyphs, cards or logo pieces arrive out of a turning 3D cloud and land in a flat layout. The reverse also works.

AGPL-3.0 ★ 78,316 updated 2026-10-24

Install into Claude Code · Manually: put the files in place All methods and platforms ↓
.claude/rules/depth-scatter-assemble.md
Open on GitHub

What depth-scatter-assemble does

This rule for Claude Code and Codex lays out a scene in which a set of items flies in from a spinning depth-cloud and locks into a flat arrangement. Run the timeline backwards and the layout bursts back into depth. Every start point is trig on the element's index with the golden angle, so frames repeat exactly and nothing relies on Math.random.

The file ships scene markup, CSS and a paused GSAP timeline stored in window.__timelines. Resting coordinates come from data-target-x and data-target-y on each fragment; the scattered state is parked with gsap.set before any tween fires, and a separate stage tween keeps the cloud turning. A single 0→1 progress value drives every channel at once. There is a tumble-swap variation for handing off between two phrases, with no blank frame in between.

CSS carries the effect: leave out perspective on the stage, or transform-style: preserve-3d on the pieces, and the depth reads as a plain scale change. GSAP loads from a CDN script, 3.14.2 in the sample.

What it helps with

  • assemble a logo from pieces flying in from depth
  • hand off between two kinetic-type phrases with no empty frame
  • lay cards into a grid out of a 3D cloud
  • scatter elements without random values so frames repeat

Example prompts for the agent

  • Build a GSAP scene where five glyphs fly out of a spinning 3D cloud into one row; derive the scatter from each element's index and read the end positions from data-target-x / data-target-y.
  • Switch the phrase change in the kinetic type to tumble-swap: old glyphs leave into the cloud, new ones come out.
  • Check the scene CSS for perspective on the container and transform-style: preserve-3d on every fragment, otherwise the depth collapses.

How to install depth-scatter-assemble

Manually: put the files in place

.claude/rules/depth-scatter-assemble.md

The paths frontmatter field limits the files

Step by step, with commands for each platform: AGENTS.md vs CLAUDE.md: what they are and which one to use

Questions about depth-scatter-assemble

How to install depth-scatter-assemble in Claude Code?

Place the rule file at .claude/rules/depth-scatter-assemble.md inside your project.

What does depth-scatter-assemble do?

It describes a scene where elements fly out of a turning 3D cloud into a flat layout, or scatter back into it. Start offsets are computed from each element's index, so frames repeat.

What does the effect need to work?

perspective on the stage plus transform-style: preserve-3d on the stage and every fragment, with GSAP loaded. Without them the depth reads as a 2D scale.

Similar IDE rules

All IDE rules for Frontend and UI →

From the same set101

The whole set →
viewport-change viewport-change — a rule that teaches the agent a virtual camera in GSAP scenes: zoom, pan and focus-lock on a moving element, all through one wrapper. CX Codex +1 ★ 78,316repo stars coordinate-target-zoom coordinate-target-zoom — a rule that teaches the agent to zoom into an element displaced from viewport center by pairing scale with counter-translation — the target lands at center after the zoom. CX Codex +1 ★ 78,316repo stars ai-tracking-box ai-tracking-box generates an animated target bounding box with corner brackets and oscillating coordinates to simulate computer vision tracking in GSAP. CX Codex +1 ★ 78,316repo stars spring-pop-entrance The spring-pop-entrance rule describes a smooth scale-in for one element or a staggered group. Use it for interface elements that should arrive on screen without bouncing. CX Codex +1 ★ 78,316repo stars ambient-glow-bloom ambient-glow-bloom defines code patterns for soft backdrop glow and light sweeps on key elements. Guides code assistants to write seek-safe GSAP timelines without infinite loops. CX Codex +1 ★ 78,316repo stars music-to-video music-to-video turns a music track into a beat-synced HyperFrames video. Use it for lyric-style clips, slideshows, or kinetic promo visuals with optional media. CX Codex +1 ★ 78,316repo stars depth-of-field-blur depth-of-field-blur is a Claude Code rule for selective focus in GSAP scenes: one layer stays crisp while the others blur and dim. It brings attention to the main element in a frame. CX Codex +1 ★ 78,316repo stars client-tools client-tools configures webhook and client-side actions for conversational voice agents, connecting them to external APIs and browser scripts. CX Codex ★ 78,316repo stars

Project sponsors

Companies that keep this analytics open