diff --git a/src/components/WebRtcPlayer.astro b/src/components/WebRtcPlayer.astro index 530bf1f..a8de5a2 100644 --- a/src/components/WebRtcPlayer.astro +++ b/src/components/WebRtcPlayer.astro @@ -6,9 +6,16 @@ interface Props extends HTMLAttributes<"div"> { streamUrl: string; iceServers?: any[]; poster?: string; + onEnded?: Function; } -const { streamUrl, iceServers = [], poster, class: className } = Astro.props; +const { + streamUrl, + iceServers = [], + poster, + class: className, + onEnded, +} = Astro.props; const id = `${Math.random().toString(36).slice(2)}`; --- @@ -118,7 +125,11 @@ const id = `${Math.random().toString(36).slice(2)}`; -