forked from Github/frigate
UI tweaks and bugfixes (#11692)
* UI tweaks and bugfixes * fix linter complaints in unmodified files
This commit is contained in:
@@ -243,9 +243,17 @@ export default function LiveDashboardView({
|
||||
>
|
||||
{includeBirdseye && birdseyeConfig?.enabled && (
|
||||
<div
|
||||
style={{
|
||||
aspectRatio: birdseyeConfig.width / birdseyeConfig.height,
|
||||
}}
|
||||
className={(() => {
|
||||
const aspectRatio =
|
||||
birdseyeConfig.width / birdseyeConfig.height;
|
||||
if (aspectRatio > 2) {
|
||||
return `${mobileLayout == "grid" && "col-span-2"} aspect-wide`;
|
||||
} else if (aspectRatio < 1) {
|
||||
return `${mobileLayout == "grid" && "row-span-2 md:h-full"} aspect-tall`;
|
||||
} else {
|
||||
return "aspect-video";
|
||||
}
|
||||
})()}
|
||||
ref={birdseyeContainerRef}
|
||||
>
|
||||
<BirdseyeLivePlayer
|
||||
@@ -260,9 +268,9 @@ export default function LiveDashboardView({
|
||||
let grow;
|
||||
const aspectRatio = camera.detect.width / camera.detect.height;
|
||||
if (aspectRatio > 2) {
|
||||
grow = `${mobileLayout == "grid" ? "col-span-2" : ""} aspect-wide`;
|
||||
grow = `${mobileLayout == "grid" && "col-span-2"} aspect-wide`;
|
||||
} else if (aspectRatio < 1) {
|
||||
grow = `${mobileLayout == "grid" ? "row-span-2 aspect-tall md:h-full" : ""} aspect-tall`;
|
||||
grow = `${mobileLayout == "grid" && "row-span-2 md:h-full"} aspect-tall`;
|
||||
} else {
|
||||
grow = "aspect-video";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user