mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-08 12:15:25 +03:00
Animate visibility of chips
This commit is contained in:
parent
3fb65e1987
commit
063ed05738
@ -175,7 +175,11 @@ export default function LivePlayer({
|
|||||||
|
|
||||||
{liveChips && (
|
{liveChips && (
|
||||||
<div className="absolute flex left-2 top-2 gap-2">
|
<div className="absolute flex left-2 top-2 gap-2">
|
||||||
<Chip className="bg-gray-500 bg-gradient-to-br">
|
<Chip
|
||||||
|
className={`bg-gray-500 bg-gradient-to-br ${
|
||||||
|
activeMotion ? "visible opacity-100" : "invisible opacity-0"
|
||||||
|
}`}
|
||||||
|
>
|
||||||
<MdLeakAdd
|
<MdLeakAdd
|
||||||
className={`w-4 h-4 ${
|
className={`w-4 h-4 ${
|
||||||
activeMotion ? "text-motion" : "text-white"
|
activeMotion ? "text-motion" : "text-white"
|
||||||
@ -184,7 +188,11 @@ export default function LivePlayer({
|
|||||||
<div className="ml-1 capitalize text-white text-xs">Motion</div>
|
<div className="ml-1 capitalize text-white text-xs">Motion</div>
|
||||||
</Chip>
|
</Chip>
|
||||||
{cameraConfig.audio.enabled_in_config && (
|
{cameraConfig.audio.enabled_in_config && (
|
||||||
<Chip className="bg-gray-500 bg-gradient-to-br">
|
<Chip
|
||||||
|
className={`bg-gray-500 bg-gradient-to-br transition-all ${
|
||||||
|
activeAudio ? "visible opacity-100" : "invisible opacity-0"
|
||||||
|
}`}
|
||||||
|
>
|
||||||
<BsSoundwave
|
<BsSoundwave
|
||||||
className={`w-4 h-4 ${
|
className={`w-4 h-4 ${
|
||||||
activeAudio ? "text-audio" : "text-white"
|
activeAudio ? "text-audio" : "text-white"
|
||||||
@ -193,7 +201,11 @@ export default function LivePlayer({
|
|||||||
<div className="ml-1 capitalize text-white text-xs">Sound</div>
|
<div className="ml-1 capitalize text-white text-xs">Sound</div>
|
||||||
</Chip>
|
</Chip>
|
||||||
)}
|
)}
|
||||||
<Chip className="bg-gray-500 bg-gradient-to-br">
|
<Chip
|
||||||
|
className={`bg-gray-500 bg-gradient-to-br transition-all ${
|
||||||
|
activeTracking ? "inline opacity-100" : "invisible opacity-0"
|
||||||
|
}`}
|
||||||
|
>
|
||||||
<MdSelectAll
|
<MdSelectAll
|
||||||
className={`w-4 h-4 ${
|
className={`w-4 h-4 ${
|
||||||
activeTracking ? "text-object" : "text-white"
|
activeTracking ? "text-object" : "text-white"
|
||||||
|
|||||||
@ -77,7 +77,7 @@ function Live() {
|
|||||||
let grow;
|
let grow;
|
||||||
if (camera.detect.width / camera.detect.height > 2) {
|
if (camera.detect.width / camera.detect.height > 2) {
|
||||||
grow = "aspect-wide md:col-span-2";
|
grow = "aspect-wide md:col-span-2";
|
||||||
} else if (camera.detect.width / camera.detect.height < 1) {
|
} else if (camera.detect.width / camera.detect.height < 0.7) {
|
||||||
grow = "aspect-tall md:row-span-2";
|
grow = "aspect-tall md:row-span-2";
|
||||||
} else {
|
} else {
|
||||||
grow = "aspect-video";
|
grow = "aspect-video";
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user