(file: File)
| 58 | const recordedChunksRef = useRef<Blob[]>([]); |
| 59 | |
| 60 | const isVideoFile = (file: File): boolean => { |
| 61 | return ( |
| 62 | file.type.startsWith("video/") || |
| 63 | SUPPORTED_VIDEO_FORMATS.some((format) => |
| 64 | file.name.toLowerCase().endsWith(`.${format}`), |
| 65 | ) |
| 66 | ); |
| 67 | }; |
| 68 | |
| 69 | const handleFileChange = (e: React.ChangeEvent<HTMLInputElement>) => { |
| 70 | const selectedFile = e.target.files?.[0]; |