import { useSessionSelector } from '../../context/SessionContext.jsx'; import RoverMediaPlayer from '../RoverMediaPlayer/index.jsx'; import { useControlSystem } from '../../controls/index.js'; import { useDriverVideoModePolicy } from '../../hooks/useDriverVideoModePolicy.js'; import TurnsOverlay from '../HudOverlays/TurnsOverlay/index.jsx'; import HudOverlay from '../HudOverlays/HudOverlay/index.jsx'; import ManualDockAssistOverlay from '../HudOverlays/ManualDockAssistOverlay/index.jsx'; import RoverDescriptionOverlay from '../HudOverlays/RoverDescriptionOverlay/index.jsx'; import OvercurrentOverlay from '../HudOverlays/OvercurrentOverlay/index.jsx'; import LowBatteryOverlay from '../HudOverlays/LowBatteryOverlay/index.jsx'; import DriverBottomStrip from '../HudOverlays/DriverBottomStrip/index.jsx'; import HudChatInput from '../HudOverlays/HudChatInput/index.jsx'; export default function DriverVideo({ layoutFormat = 'desktop' }) { const roverId = useSessionSelector((state) => state.session?.assignment?.roverId ?? null); const videoMode = useDriverVideoModePolicy(roverId); const { state: { lastControlIntentAt }, } = useControlSystem(); if (!roverId) { return (

You are not assigned to a rover.

Click here to visit the spectator page.

); } const mobileHud = layoutFormat !== 'desktop'; return (
); }