'use client'; import { Radio } from 'lucide-react'; import { useState, type FormEvent } from 'react'; type Props = { busy: boolean; error?: string | null; onConnect: (liveId: string) => void; }; export function ConnectForm({ busy, error, onConnect }: Props) { const [value, setValue] = useState(''); const submit = (event: FormEvent) => { event.preventDefault(); if (value.trim()) onConnect(value.trim()); }; return (

Connect to a live stream

Paste the video URL or the 11 character video id of a stream that is live now.

setValue(event.target.value)} placeholder="https://youtube.com/watch?v=…" disabled={busy} spellCheck={false} /> {error &&

{error}

}
); }