Ambient Section Particles
Meng ToCommunityCreated by Meng To
- Skill
- Tool integration
- Software development
- MIT
- No issues found
AutoGineer summary
Written by AutoGineer from the skill’s own files, not by the author
This skill provides a structured approach to adding decorative particle atmospheres within specific page sections. It emphasizes keeping particles bounded, ensuring they remain secondary to primary content, and implementing resource-efficient animation loops. The guidelines cover renderer selection, configuration parameters, layering techniques, and lifecycle management to ensure the effect respects user preferences and device constraints.
What it does
- Provides criteria for choosing between canvas, DOM/SVG, or WebGL renderers based on particle count and complexity.
- Defines configuration parameters for particle behavior including gravity, wind, sway, and rotation.
- Outlines layering strategies to keep particles behind content while maintaining proper stacking contexts.
- Details lifecycle management using IntersectionObserver to pause animations when sections are not visible.
- Specifies accessibility requirements, including handling reduced-motion preferences and ensuring decorative elements are hidden from assistive technology.
When to use it
- When adding subtle decorative elements like petals, snow, or brand fragments to a specific section.
- When you need to ensure animations do not interfere with user interaction or content readability.
- When building responsive interfaces that require graceful degradation for low-power devices or reduced-motion settings.
- When implementing complex visual effects that must be cleaned up properly during route changes or component unmounting.
Advantages
- Prevents performance degradation by using efficient animation loops and visibility-based pausing.
- Ensures a consistent user experience by providing fallbacks for reduced-motion and different device capabilities.
- Maintains content focus by keeping particles bounded within specific sections rather than the entire viewport.
- Promotes accessibility by ensuring decorative motion does not obscure critical information or form controls.
Usage examples
- “How should I choose a renderer for a section with 50 floating leaf particles?”
- The guidelines recommend using canvas for roughly 40 or more small particles to balance motion requirements with resource usage.
- “How do I ensure my particle animation respects accessibility settings?”
- The skill instructs to render a sparse static arrangement or remove the layer entirely when the user has enabled prefers-reduced-motion.
Install
Download the skill as a ZIP:
https://mp-staging.autogineer.com/agent-skills/mengto/ambient-section-particles/downloadUnzip it into the cross-client skills folder of your project:
mkdir -p .agents/skills && unzip ambient-section-particles.zip -d .agents/skills
Documentation by Meng To
Ambient Section Particles
Build particles as a bounded atmosphere layer, not as a page-wide screensaver. Keep the content primary and stop work when the effect cannot be seen.
Choose the renderer
Use canvas for roughly 40 or more small particles, frequent motion, pointer forces, or simple procedural shapes.
Use DOM or inline SVG for a small count of branded fragments that need individual styling or semantic labels.
Use WebGL only for thousands of particles, depth, shaders, or real 3D behavior. Cap device pixel ratio and provide a static fallback.
Start with the least expensive renderer that preserves the desired shape language.
Define one configuration
const particles = {
count: 54,
gravity: 7,
wind: -3,
sway: 16,
speed: [8, 18],
size: [4, 12],
opacity: [0.18, 0.62],
rotation: [-0.8, 0.8],
mode: "recycle",
pointerRadius: 110,
maxDpr: 2
};Scale density by container area, then clamp it for mobile and low-power devices. Do not derive count from viewport width alone.
Layer the section
Give the section a positioning context and clip overflow when particles should remain bounded.
Place the particle surface behind content but above the background.
Set the layer to
pointer-events: none; listen for pointer movement on the section.Reserve a quiet content zone or lower density behind long text and controls.
Keep controls and links in normal DOM stacking with visible focus.
Run the simulation
Seed particles inside or just above the container bounds.
Update gravity, wind, phase-based sway, rotation, opacity, and position from elapsed time.
Clamp large time deltas after background tabs or stalled frames.
Use one
requestAnimationFrameloop for the whole layer.Resize with
ResizeObserver; cap canvas backing resolution atmin(devicePixelRatio, maxDpr).For pointer disturbance, apply a small distance-based force and let particles settle back naturally. Never attach a listener per particle.
Support explicit end modes:
recycle: return particles above the section after exit.exit: remove particles after they leave the bounds.settle: resolve into a shallow visual pile with a strict height cap.static: render a deterministic still composition.
Stop invisible work
Use IntersectionObserver to start only when the section is visible. Cancel animation frames when it exits or document.hidden becomes true. Resume from the current simulation state instead of spawning a second loop.
On teardown, disconnect observers, remove resize and pointer listeners, cancel the frame, and release renderer resources.
Respect the reader
Under
prefers-reduced-motion: reduce, render a sparse static arrangement or remove the layer.Keep particles decorative and hidden from assistive technology.
Control opacity and contrast so motion never crosses the legibility threshold.
Avoid full-screen pointer repulsion, rapid direction changes, flashes, and large objects crossing form controls.
Pause decorative motion while a modal or critical task in the section is active when it competes for attention.
Verify
Test entry and exit pausing, background-tab recovery, fast resize, 390/768/1440 widths, device pixel ratio, pointer and touch input, reduced motion, section overflow, content focus, long text, route cleanup, and console errors. Confirm only one animation loop survives repeated mounts.
Use demo/index.html as the working reference and demo/PROMPT.md to recreate or remix it. Keep REFERENCES.md as the links-only implementation source list.
Files
- ATTRIBUTION.mdAdded by AutoGineer872 B
- LICENSELicence file added by AutoGineer1.0 KiB
- REFERENCES.md507 B
- SKILL.md4.0 KiB
- agents/openai.yaml244 B
- demo/PROMPT.md1.8 KiB
- demo/index.html10.8 KiB
- demo/preview.jpg80.6 KiB
demo/PROMPT.md
Ambient Section Particles Demo Prompts
Minimal prompt
Use $ambient-section-particles to add a restrained, visibility-aware particle atmosphere behind this section without competing with its content.
Recreate the demo
Use $ambient-section-particles to recreate Seedfall — A Quiet Weather System as a complete standalone HTML document. Treat demo/index.html as the visual, interaction, responsive, accessibility, and performance reference.
Experience
Build a full-viewport dark botanical chapter with an original canvas field of softly falling seed fragments.
Vary size, opacity, sway, rotation, gravity, wind, and depth while reserving a quiet reading zone behind the main copy.
Let pointer movement gently disturb nearby particles without making the canvas interactive or blocking controls.
Start only while the section is visible, pause when it leaves or the document is hidden, and reuse particles after they exit.
Include a real control that creates one restrained gust and updates a silent visual status.
Implementation contract
Deliver
demo/index.htmlwith all CSS and JavaScript inline and no required external assets.Use one canvas loop, ResizeObserver, IntersectionObserver, requestAnimationFrame, and a device-pixel-ratio cap.
Scale density from container area with strict minimum and maximum counts.
Keep canvas decorative, pointer transparent, and behind semantic content with visible focus.
Under reduced motion, render one sparse deterministic still and do not run a continuous loop.
Remix prompt
Use $ambient-section-particles and the included demo as the quality bar, but replace the particle shape, palette, mood, copy, forces, and section composition. Preserve the bounded layer, quiet content zone, visibility pausing, one-loop architecture, responsive density, pointer restraint, and reduced-motion fallback.
Requirements and compatibility
Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta
“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.
Security
No issues found by our static scan· No issues found
A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.
Attribution and licence
- Created by
- Meng To
- Publisher
- Meng To (Community)
- Source
- MengTo/Skills · agent-skills/web-design/ambient-section-particles · commit 5ea1661
- Licence
- MIT License (redistribution allowed)
- LICENSE (added by AutoGineer from LICENSE)
- ATTRIBUTION.md (written by AutoGineer)
- Synced
AutoGineer is not affiliated with or endorsed by Meng To.
Download ZIP
The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download ambient-section-particles.zip