This commit is contained in:
Josh Hawkins 2024-12-28 07:53:21 -06:00
parent 83f3128f72
commit 0a9bf413f6
4 changed files with 4 additions and 3 deletions

View File

@ -246,7 +246,7 @@ export default function LiveContextMenu({
</div> </div>
</div> </div>
</ContextMenuItem> </ContextMenuItem>
{isRestreamed && cameraGroup && ( {isRestreamed && cameraGroup && cameraGroup !== "default" && (
<> <>
<ContextMenuSeparator /> <ContextMenuSeparator />
<ContextMenuItem> <ContextMenuItem>

View File

@ -178,12 +178,12 @@ export default function JSMpegPlayer({
bytesReceivedRef.current = 0; bytesReceivedRef.current = 0;
lastTimestampRef.current = currentTimestamp; lastTimestampRef.current = currentTimestamp;
frameCount = 0;
}, 1000); }, 1000);
return () => { return () => {
if (statsIntervalRef.current) { if (statsIntervalRef.current) {
clearInterval(statsIntervalRef.current); clearInterval(statsIntervalRef.current);
frameCount = 0;
statsIntervalRef.current = null; statsIntervalRef.current = null;
} }
}; };

View File

@ -89,7 +89,7 @@ export function PlayerStats({ stats, minimal }: PlayerStatsProps) {
className={cn( className={cn(
minimal minimal
? "absolute bottom-0 left-0 max-h-[50%] w-full overflow-y-auto rounded-b-lg p-1 md:rounded-b-xl md:p-3" ? "absolute bottom-0 left-0 max-h-[50%] w-full overflow-y-auto rounded-b-lg p-1 md:rounded-b-xl md:p-3"
: "absolute bottom-2 right-2 rounded-2xl p-4", : "absolute bottom-2 right-2 min-w-52 rounded-2xl p-4",
"z-50 flex flex-col gap-1 bg-black/70 text-[9px] duration-300 animate-in fade-in md:text-xs", "z-50 flex flex-col gap-1 bg-black/70 text-[9px] duration-300 animate-in fade-in md:text-xs",
)} )}
> >

View File

@ -397,6 +397,7 @@ export default function LiveDashboardView({
className={grow} className={grow}
key={camera.name} key={camera.name}
camera={camera.name} camera={camera.name}
cameraGroup={cameraGroup}
streamName={Object.values(camera.live.streams)?.[0]} streamName={Object.values(camera.live.streams)?.[0]}
preferredLiveMode={preferredLiveModes[camera.name] ?? "mse"} preferredLiveMode={preferredLiveModes[camera.name] ?? "mse"}
isRestreamed={isRestreamedStates[camera.name]} isRestreamed={isRestreamedStates[camera.name]}