mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-07 11:45:24 +03:00
Fix opening page on icon toggle
This commit is contained in:
parent
cc95fd9901
commit
4a4fceec5c
@ -94,7 +94,7 @@ function Camera({ camera }: { camera: CameraConfig }) {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<Card className="">
|
<Card>
|
||||||
<a href={`/live/${camera.name}`}>
|
<a href={`/live/${camera.name}`}>
|
||||||
<AspectRatio
|
<AspectRatio
|
||||||
ratio={16 / 9}
|
ratio={16 / 9}
|
||||||
@ -115,6 +115,7 @@ function Camera({ camera }: { camera: CameraConfig }) {
|
|||||||
}`}
|
}`}
|
||||||
onClick={(e) => {
|
onClick={(e) => {
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
|
e.preventDefault();
|
||||||
sendDetect(detectValue == "ON" ? "OFF" : "ON");
|
sendDetect(detectValue == "ON" ? "OFF" : "ON");
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
@ -132,6 +133,7 @@ function Camera({ camera }: { camera: CameraConfig }) {
|
|||||||
}
|
}
|
||||||
onClick={(e) => {
|
onClick={(e) => {
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
|
e.preventDefault();
|
||||||
camera.record.enabled_in_config
|
camera.record.enabled_in_config
|
||||||
? sendRecord(recordValue == "ON" ? "OFF" : "ON")
|
? sendRecord(recordValue == "ON" ? "OFF" : "ON")
|
||||||
: {};
|
: {};
|
||||||
@ -147,6 +149,7 @@ function Camera({ camera }: { camera: CameraConfig }) {
|
|||||||
}`}
|
}`}
|
||||||
onClick={(e) => {
|
onClick={(e) => {
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
|
e.preventDefault();
|
||||||
sendSnapshot(detectValue == "ON" ? "OFF" : "ON");
|
sendSnapshot(detectValue == "ON" ? "OFF" : "ON");
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
@ -161,6 +164,7 @@ function Camera({ camera }: { camera: CameraConfig }) {
|
|||||||
}`}
|
}`}
|
||||||
onClick={(e) => {
|
onClick={(e) => {
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
|
e.preventDefault();
|
||||||
sendAudio(detectValue == "ON" ? "OFF" : "ON");
|
sendAudio(detectValue == "ON" ? "OFF" : "ON");
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user