This document provides the complete implementation guide for transforming your Resume AI application into a modern, polished UI with professional GSAP animations.
npm install gsap✅ Successfully installed and ready to use
File: app/lib/animations.ts
- 25+ reusable animation functions
- Page transitions, fades, slides, scales, stagger effects
- Button interactions, card animations, number counters
- Glow effects, pulses, bounces, shakes, rotations
- Loading spinners, parallax, success/error animations
File: app/lib/useAnimations.ts
- 17 custom React hooks for animations
usePageTransition- Page fade in on mountuseStagger- List item animationsuseHoverScale- Hover effectsuseCountUp- Number animationsuseLoadingSpinner- Rotating loadersuseIntersectionAnimation- Scroll-triggered animations- And 11 more utility hooks
File: app/app.css
- Modern color palette (indigo, purple, pink gradients)
- Soft shadows and rounded corners throughout
- Button component variants (.btn-primary, .btn-secondary, .btn-ghost)
- Card components with hover effects
- Form styling with focus states and animations
- Navigation bar with glassmorphism
- Badges, progress bars, dividers
- GSAP animation base states
File: app/routes/auth.tsx
✅ Fully redesigned with:
- Beautiful gradient background with decorative orbs
- Glassmorphic card with backdrop blur
- GSAP page transition on mount
- Smooth button animations (click, hover, spin)
- Feature items with hover slide effect
- Loading spinner animation
- Improved error handling
- Auto-redirect with smooth transition
File: app/components/LogoutButton.tsx
Features to add:
- GSAP hover scale animation
- Button exit animation on logout
- Error shake animation if logout fails
- Smooth integration with navbar
- Red gradient styling matching logout theme
- Icon with spinner during logout
- Primary: Indigo (#6366f1)
- Accent: Pink/Purple gradients
- Success: Green (#10b981)
- Warning: Amber (#f59e0b)
- Error: Red (#ef4444)
- Headers: Bold gradient text
- Body: Clear sans-serif (Poppins)
- Proper hierarchy across breakpoints
- Soft shadows:
shadow-lg shadow-gray-200/50 - Hover effects with scale and shadow increase
- Glassmorphism with backdrop blur
- Rounded corners: 12-24px
- Update LogoutButton.tsx with GSAP
// Add to LogoutButton component:
import gsap from 'gsap';
// Add hover effects:
onMouseEnter={(e) => {
gsap.to(e.currentTarget, {
scale: 1.08,
duration: 0.3,
ease: 'power2.out',
});
}}
// Add logout animation:
gsap.to('.logout-button', {
rotate: 12,
scale: 0.8,
opacity: 0,
duration: 0.4,
ease: 'back.in(1.7)',
});- Update Home Page (
app/routes/home.tsx)
import { usePageTransition, useStagger } from '~/lib/useAnimations';
export default function Home() {
const containerRef = usePageTransition(0.8);
const resumesRef = useStagger(0.4, 0.15);
return (
<main ref={containerRef}>
{/* Content */}
<div ref={resumesRef}>
{/* Resume cards will stagger in */}
</div>
</main>
);
}- Update Upload Page (
app/routes/upload.tsx)
- Add progress bar animations with GSAP
- Animate step transitions
- Add success animation on completion
- Smooth upload progress indicator
- Update ResumeCard Component
// Add hover animation
const ref = useHoverScale(1.05);
return (
<div ref={ref} className='resume-card'>
{/* Card content */}
</div>
);- Update Navbar Component
import { usePageTransition } from '~/lib/useAnimations';
const Navbar = () => {
const navRef = usePageTransition(0.6);
return (
<nav ref={navRef} className='navbar'>
{/* Navigation content */}
</nav>
);
}- Add page transition animation
- Animate feedback reveal
- Score badge with glow effect
- Smooth transitions between states
- Drag-and-drop with scale animations
- File selection animations
- Error state shake animation
- Animated counter for score
- Glow effect on mount
- Bounce animation on value change
import { usePageTransition } from '~/lib/useAnimations';
export default function Page() {
const ref = usePageTransition(0.8);
return <main ref={ref}>{/* Content */}</main>;
}import { useStagger } from '~/lib/useAnimations';
export default function List() {
const ref = useStagger(0.4, 0.1);
return (
<div ref={ref}>
{items.map(item => (
<div key={item.id}>{item.name}</div>
))}
</div>
);
}import { useHoverScale } from '~/lib/useAnimations';
export default function Card() {
const ref = useHoverScale(1.08);
return <div ref={ref} className='card'>{/* Content */}</div>;
}import { useCountUp } from '~/lib/useAnimations';
export default function Score() {
const ref = useCountUp(0, 95, 2);
return <div ref={ref}>0</div>;
}import { useLoadingSpinner } from '~/lib/useAnimations';
export default function Loader() {
const ref = useLoadingSpinner();
return (
<div ref={ref} className='w-8 h-8 border-4 border-indigo-600 rounded-full border-t-transparent'></div>
);
}<button className='btn-primary'>
Sign In
</button><button className='btn-secondary'>
Cancel
</button><button className='btn-ghost'>
Learn More
</button><button className='btn-sm btn-primary'>
Save
</button>All components include responsive breakpoints:
- Mobile (default): Full width, larger touch targets
- Tablet (
md:): Optimized layouts - Desktop (
lg:,xl:): Full featured layouts
-
Lazy Animation Initialization
- Animations only trigger when needed
- No continuous animations unless required
-
CSS Transitions
- Use CSS for simple state changes
- Reserve GSAP for complex sequences
-
Viewport Animations
useIntersectionAnimationfor scroll triggers- Prevents unnecessary animations
-
Minimal Repaints
- Use transform and opacity (GPU accelerated)
- Avoid animating layout properties
# Verify TypeScript compilation
npm run typecheck
# Build for production
npm run build
# Start development server
npm run dev| Component | Status | Updates Needed |
|---|---|---|
| Auth Page | ✅ Redesigned | GSAP animations added |
| Home Page | ⏳ Needs Update | Add page transition, stagger |
| Upload Page | ⏳ Needs Update | Add progress animations |
| Resume Page | ⏳ Needs Update | Add reveal animations |
| Navbar | ⏳ Needs Update | Add slide-in effect |
| LogoutButton | ⏳ Needs GSAP | Add hover/click animations |
| ResumeCard | ⏳ Needs Update | Add hover scale |
| FileUploader | ⏳ Needs Update | Add drag animations |
| ScoreCircle | ⏳ Needs Update | Add counter animation |
const ref = usePageTransition();
// Fades in with slide up on mountconst ref = useStagger(0.4, 0.1);
// Each child animates with staggerconst ref = useHoverScale(1.05);
// Scales on hover, returns to normal on leaveconst ref = useLoadingSpinner();
// Continuous rotation for loadersconst ref = useCountUp(0, 95, 2);
// Animates counter from 0 to 95 over 2 secondsFor advanced animations, reference:
- GSAP Docs
- Easing Visualizer
- Available easings:
power1/2/3.in/out/inOut,back,elastic,bounce, etc.
Key utility classes for the redesign:
- Gradients:
bg-linear-to-r,bg-linear-to-b,bg-linear-to-br - Shadows:
shadow-lg,shadow-indigo-200/50 - Blur:
backdrop-blur-xl - Rounded:
rounded-xl,rounded-2xl,rounded-3xl - Spacing:
px-6,py-3,gap-4 - Effects:
opacity-20,scale-95
- Consistency: All animations use same timing (0.3-0.6s)
- Easing: Primary eases are
power2.outandpower3.out - Colors: Use gradient system throughout
- Shadows: Always use semi-transparent gray shadows
- Spacing: Maintain 16px base unit for padding/margins
- Copy animation utilities to your project
- Update components one by one
- Test each page for smooth animations
- Verify responsive design on mobile
- Optimize performance as needed
- Deploy when ready
Status: Core infrastructure complete, ready for component updates Last Updated: November 21, 2025