mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-08 20:25:26 +03:00
don't flash when going to still image
This commit is contained in:
parent
caf4ed0854
commit
b6ca0d17f9
@ -7,7 +7,6 @@ type AutoUpdatingCameraImageProps = {
|
|||||||
showFps?: boolean;
|
showFps?: boolean;
|
||||||
className?: string;
|
className?: string;
|
||||||
reloadInterval?: number;
|
reloadInterval?: number;
|
||||||
fitAspect?: number;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const MIN_LOAD_TIMEOUT_MS = 200;
|
const MIN_LOAD_TIMEOUT_MS = 200;
|
||||||
|
|||||||
@ -157,22 +157,18 @@ export default function LivePlayer({
|
|||||||
{(showStillWithoutActivity == false || activeMotion || activeTracking) &&
|
{(showStillWithoutActivity == false || activeMotion || activeTracking) &&
|
||||||
player}
|
player}
|
||||||
|
|
||||||
{showStillWithoutActivity && !liveReady && (
|
<div
|
||||||
<div className="absolute left-0 top-0 right-0 bottom-0 w-full">
|
className={`absolute left-0 top-0 right-0 bottom-0 w-full ${
|
||||||
<AutoUpdatingCameraImage
|
showStillWithoutActivity && !liveReady ? "visible" : "invisible"
|
||||||
className="w-full h-full"
|
}`}
|
||||||
camera={cameraConfig.name}
|
>
|
||||||
showFps={false}
|
<AutoUpdatingCameraImage
|
||||||
reloadInterval={30000}
|
className="w-full h-full"
|
||||||
fitAspect={
|
camera={cameraConfig.name}
|
||||||
cameraConfig.detect.width / cameraConfig.detect.height > 2 ||
|
showFps={false}
|
||||||
cameraConfig.detect.width / cameraConfig.detect.height < 1
|
reloadInterval={30000}
|
||||||
? cameraConfig.detect.width / cameraConfig.detect.height
|
/>
|
||||||
: 16 / 9
|
</div>
|
||||||
}
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
)}
|
|
||||||
|
|
||||||
<div className="absolute flex left-2 top-2 gap-2">
|
<div className="absolute flex left-2 top-2 gap-2">
|
||||||
<Chip
|
<Chip
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user