Neon Retro Web runs two distinct animation layers that never interfere with each other. Framer Motion owns the page-level experience — orchestrating entrance, presence, and exit transitions as React Router v6 navigates between routes. Below that, three custom CSS keyframe animations compiled intoDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/apursley2012/neon-retro-web/llms.txt
Use this file to discover all available pages before exploring further.
assets/main.css handle repeating, component-level effects: a blinking cursor badge, a horizontally scrolling marquee ticker, and a slow gear rotation. Understanding which layer controls which effect makes it straightforward to tune the feel of the site or add new motion without breaking existing transitions.
Page Transitions with Framer Motion
AnimatePresence and Route Setup
AnimatePresence is mounted once in main.jsx, wrapping the React Router outlet so that exiting route components can complete their exit animation before being unmounted from the DOM:
mode="wait" prop tells AnimatePresence to finish the outgoing page’s exit animation completely before the incoming page begins its entrance — preventing two pages from being visible simultaneously.
Standard Page Motion Pattern
Every page component wraps its root element in amotion.div with a consistent fade:
Changing to a Slide Transition
Replace the opacity-only variants withx (horizontal) or y (vertical) offsets to get a slide effect instead of a fade:
Window Component Spring Animation
The retro OS window chrome component uses a spring physics transition for its mount animation, giving it a satisfying bounce that echoes the era’s exaggerated UI feedback:stiffness (e.g., 150) for a slower, bouncier spring. Increase damping (e.g., 40) to remove the bounce and make it settle quickly.
CSS Keyframe Animations
Three custom keyframe animations are compiled intoassets/main.css. They complement Framer Motion for effects that run continuously rather than triggering once on mount.
Animation Quick Reference
| Animation | Class | Duration | Usage |
|---|---|---|---|
| Blink | animate-blink | 1.5s step-end infinite | BadgeNew — “NEW” badge cursor blink |
| Marquee | animate-marquee | 20s linear infinite | Marquee — horizontal news-ticker scroll |
| Spin Slow | animate-spin-slow | 4s linear infinite | Gear / cog icon decorations |
Keyframe Definitions
- blink
- marquee
- spin-slow
step-end timing function makes the opacity switch snap instantly (no crossfade between opaque and transparent), replicating the hard on/off blink of a hardware cursor.Component Usage
BadgeNew
The
BadgeNew component renders a small “NEW” pill badge on project cards. animate-blink is applied to the badge text or a trailing cursor character to draw attention to recently added items without using motion that conflicts with AnimatePresence.Marquee
The
Marquee component renders a horizontally scrolling ticker strip at the top or bottom of the layout. animate-marquee is applied to the inner text container, which must be whitespace-nowrap to prevent line wrapping mid-scroll.Gear Icons
Decorative SVG gear or cog icons throughout the UI use
animate-spin-slow to maintain a sense of mechanical activity in the background without being distracting.