Dynamically detect if full screen is supported (#13197)

This commit is contained in:
Nicolas Mowen
2024-08-19 15:01:21 -06:00
committed by GitHub
parent 38a8d34ba5
commit 1da934e63c
7 changed files with 57 additions and 15 deletions

View File

@@ -83,12 +83,14 @@ import { useSessionPersistence } from "@/hooks/use-session-persistence";
type LiveCameraViewProps = {
config?: FrigateConfig;
camera: CameraConfig;
supportsFullscreen: boolean;
fullscreen: boolean;
toggleFullscreen: () => void;
};
export default function LiveCameraView({
config,
camera,
supportsFullscreen,
fullscreen,
toggleFullscreen,
}: LiveCameraViewProps) {
@@ -376,7 +378,7 @@ export default function LiveCameraView({
)}
</Button>
)}
{!isIOS && (
{supportsFullscreen && (
<CameraFeatureToggle
className="p-2 md:p-0"
variant={fullscreen ? "overlay" : "primary"}