mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-07-30 15:49:00 +03:00
UI fixes (#22814)
* display area as proper percentage in debug view * match replay objects list with debug view * motion search fixes - tweak progress bar to exclude heatmap and inactive segments - show metrics immediately on search start - fix preview frame loading race - fix polygon missing after dialog remount - don't try to drag the image when dragging vertex of polygon * add activity indicator to storage metrics * make sub label query for events API endpoints case insensitive
This commit is contained in:
@@ -370,7 +370,7 @@ type ObjectListProps = {
|
||||
};
|
||||
|
||||
function ObjectList({ cameraConfig, objects }: ObjectListProps) {
|
||||
const { t } = useTranslation(["views/settings"]);
|
||||
const { t } = useTranslation(["views/settings", "common"]);
|
||||
const { data: config } = useSWR<FrigateConfig>("config");
|
||||
|
||||
const colormap = useMemo(() => {
|
||||
@@ -440,17 +440,21 @@ function ObjectList({ cameraConfig, objects }: ObjectListProps) {
|
||||
{obj.area ? (
|
||||
<div className="text-end">
|
||||
<div className="text-xs">
|
||||
px: {obj.area.toString()}
|
||||
{t("information.pixels", {
|
||||
ns: "common",
|
||||
area: obj.area,
|
||||
})}
|
||||
</div>
|
||||
<div className="text-xs">
|
||||
%:{" "}
|
||||
{(
|
||||
obj.area /
|
||||
(cameraConfig.detect.width *
|
||||
cameraConfig.detect.height)
|
||||
(obj.area /
|
||||
(cameraConfig.detect.width *
|
||||
cameraConfig.detect.height)) *
|
||||
100
|
||||
)
|
||||
.toFixed(4)
|
||||
.toFixed(2)
|
||||
.toString()}
|
||||
%
|
||||
</div>
|
||||
</div>
|
||||
) : (
|
||||
|
||||
Reference in New Issue
Block a user