mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-08 20:25:26 +03:00
use skeleton for live view too
This commit is contained in:
parent
1ecccaeb27
commit
83cba3242f
@ -1,7 +1,7 @@
|
||||
import { useApiHost } from "@/api";
|
||||
import { useEffect, useRef, useState } from "react";
|
||||
import useSWR from "swr";
|
||||
import ActivityIndicator from "../ui/activity-indicator";
|
||||
import { Skeleton } from "../ui/skeleton";
|
||||
|
||||
type CameraImageProps = {
|
||||
className?: string;
|
||||
@ -61,7 +61,7 @@ export default function CameraImage({
|
||||
)}
|
||||
{!hasLoaded && enabled ? (
|
||||
<div className="absolute left-0 right-0 top-0 bottom-0 flex justify-center items-center">
|
||||
<ActivityIndicator />
|
||||
<Skeleton className="w-full h-full rounded-2xl" />
|
||||
</div>
|
||||
) : null}
|
||||
</div>
|
||||
|
||||
@ -12,6 +12,7 @@ import useCameraActivity from "@/hooks/use-camera-activity";
|
||||
import { useRecordingsState } from "@/api/ws";
|
||||
import { LivePlayerMode } from "@/types/live";
|
||||
import useCameraLiveMode from "@/hooks/use-camera-live-mode";
|
||||
import { Skeleton } from "../ui/skeleton";
|
||||
|
||||
type LivePlayerProps = {
|
||||
className?: string;
|
||||
@ -119,7 +120,7 @@ export default function LivePlayer({
|
||||
/>
|
||||
);
|
||||
} else {
|
||||
player = <ActivityIndicator />;
|
||||
player = <Skeleton className="w-full h-full rounded-2xl" />;
|
||||
}
|
||||
|
||||
return (
|
||||
|
||||
Loading…
Reference in New Issue
Block a user