import { IconPatch } from "components/buttons/IconPatch"; import { Icons } from "components/Icon"; import { Loading } from "components/layout/Loading"; import { MWMediaStream } from "providers"; import { useRef } from "react"; export interface VideoPlayerProps { source: MWMediaStream; startAt?: number; onProgress?: (event: ProgressEvent) => void; } export function SkeletonVideoPlayer(props: { error?: boolean }) { return (
{props.error ? (

Couldn't get your stream

) : (

Getting your stream...

)}
); } export function VideoPlayer(props: VideoPlayerProps) { const videoRef = useRef(null); const mustUseHls = props.source.type === "m3u8"; return ( ); }