From 0eca57efabc9856851c68587b9fafe5ac4c7dff0 Mon Sep 17 00:00:00 2001 From: R0m1k3 Date: Fri, 27 Mar 2026 09:45:38 +0100 Subject: [PATCH] feat: Introduce Remotion video creation and publishing page with a media thumbnail component and backend routes. --- client/src/components/media-thumbnail.tsx | 134 +++++++++++++++++++-- client/src/pages/mobile/remotion-video.tsx | 48 ++++++-- server/routes/remotion.ts | 36 +++++- 3 files changed, 196 insertions(+), 22 deletions(-) diff --git a/client/src/components/media-thumbnail.tsx b/client/src/components/media-thumbnail.tsx index a515b03..810a7a0 100644 --- a/client/src/components/media-thumbnail.tsx +++ b/client/src/components/media-thumbnail.tsx @@ -1,11 +1,12 @@ -import { useState } from 'react'; -import { ImageIcon, VideoIcon } from 'lucide-react'; +import { useState, useRef, useEffect } from 'react'; +import { ImageIcon, VideoIcon, Play } from 'lucide-react'; interface MediaThumbnailProps { src: string; alt: string; type?: 'image' | 'video'; className?: string; + thumbnailUrl?: string; // Optional pre-generated thumbnail } function isVideoUrl(url: string): boolean { @@ -14,15 +15,85 @@ function isVideoUrl(url: string): boolean { /** * Renders a media thumbnail that handles: - * - Local video files: uses