tpmjs/apps/tutorial/src/components/agent-example-slides/AgentExampleWelcomeSlide.tsx
Ajax Davis 5d9e256660 feat: add 3 new tutorials (first-tool, agent-example, playground)
- Build Your First Tool: Step-by-step guide from npm init to published
- Real-World Agent: Complete working example with meta-tools
- Interactive Playground: How to test tools in browser

Each tutorial has 5-6 slides with code examples and animations.
Updated main page to show all 6 tutorials in grid.
2025-12-31 01:02:21 +10:00

87 lines
2.8 KiB
TypeScript

'use client';
import { motion } from 'framer-motion';
export function AgentExampleWelcomeSlide(): React.ReactElement {
return (
<div className="relative flex flex-col items-center justify-center h-full px-8 text-center overflow-hidden">
<div className="absolute inset-0 bg-gradient-to-br from-rose-900/20 via-transparent to-pink-900/20 pointer-events-none" />
<motion.div
initial={{ opacity: 0, y: 20 }}
animate={{ opacity: 1, y: 0 }}
transition={{ duration: 0.8, ease: 'easeOut' }}
className="relative z-10 max-w-4xl"
>
<motion.div
initial={{ opacity: 0, scale: 0.9 }}
animate={{ opacity: 1, scale: 1 }}
transition={{ duration: 0.6, delay: 0.2 }}
className="mb-6"
>
<span className="text-sm font-mono text-rose-400/60 tracking-widest uppercase">
Practical Example
</span>
</motion.div>
<motion.div
initial={{ opacity: 0, scale: 0.9 }}
animate={{ opacity: 1, scale: 1 }}
transition={{ duration: 0.6, delay: 0.3 }}
className="mb-8"
>
<span className="text-5xl md:text-6xl font-bold bg-gradient-to-r from-rose-400 to-pink-400 bg-clip-text text-transparent">
Real-World Agent
</span>
</motion.div>
<motion.h1
initial={{ opacity: 0 }}
animate={{ opacity: 1 }}
transition={{ duration: 0.6, delay: 0.5 }}
className="text-2xl md:text-3xl font-medium text-white/90 mb-6"
>
Build an agent that discovers and uses tools dynamically
</motion.h1>
<motion.p
initial={{ opacity: 0 }}
animate={{ opacity: 1 }}
transition={{ duration: 0.6, delay: 0.7 }}
className="text-lg text-white/50 font-mono max-w-xl mx-auto"
>
A complete working example with search, execute, and reasoning
</motion.p>
</motion.div>
<motion.div
initial={{ opacity: 0 }}
animate={{ opacity: 1 }}
transition={{ duration: 0.8, delay: 1.2 }}
className="absolute bottom-12 flex flex-col items-center"
>
<motion.div
animate={{ y: [0, 8, 0] }}
transition={{ duration: 1.5, repeat: Number.POSITIVE_INFINITY, ease: 'easeInOut' }}
className="text-white/40"
>
<svg
aria-hidden="true"
className="w-6 h-6"
fill="none"
stroke="currentColor"
viewBox="0 0 24 24"
>
<path
strokeLinecap="round"
strokeLinejoin="round"
strokeWidth={1.5}
d="M19 9l-7 7-7-7"
/>
</svg>
</motion.div>
<span className="mt-2 text-sm text-white/30 font-mono">Press any key</span>
</motion.div>
</div>
);
}