import { AbsoluteFill, interpolate, useCurrentFrame, useVideoConfig, } from "remotion"; interface TextSceneProps { title: string; narration: string; imageUrl?: string; } const ACCENT = "#7C3AED"; // Signature purple export const TextScene: React.FC = ({ title, narration, }) => { const frame = useCurrentFrame(); const { durationInFrames } = useVideoConfig(); // Animations const titleOpacity = interpolate(frame, [0, 20], [0, 1], { extrapolateRight: "clamp", }); const titleY = interpolate(frame, [0, 20], [30, 0], { extrapolateRight: "clamp", }); const textOpacity = interpolate(frame, [12, 35], [0, 1], { extrapolateRight: "clamp", }); const textY = interpolate(frame, [12, 35], [20, 0], { extrapolateRight: "clamp", }); // Geometric shape animations const circleScale = interpolate(frame, [0, 40], [0, 1], { extrapolateRight: "clamp", }); const rectWidth = interpolate(frame, [5, 30], [0, 200], { extrapolateRight: "clamp", }); const dotOpacity = interpolate(frame, [15, 30], [0, 0.15], { extrapolateRight: "clamp", }); const lineHeight = interpolate(frame, [8, 35], [0, 300], { extrapolateRight: "clamp", }); return ( {/* Background geometric shapes */} {/* Large circle top-right */}
{/* Small filled circle */}
{/* Accent bar top-left */}
{/* Vertical line right side */}
{/* Dot grid pattern */}
{Array.from({ length: 15 }).map((_, i) => (
))}
{/* Content */}
{/* Title */}

{title}

{/* Divider */}
{/* Narration text */}

{narration}

{/* Bottom accent stripe */}
); };