mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-14 23:25:25 +03:00
Reset snapshot state when event is moved
This commit is contained in:
parent
0126960d79
commit
9823852f98
@ -12,7 +12,7 @@ import {
|
||||
import { Event } from "@/types/event";
|
||||
import { FrigateConfig } from "@/types/frigateConfig";
|
||||
import axios from "axios";
|
||||
import { useCallback, useMemo, useState } from "react";
|
||||
import { useCallback, useEffect, useMemo, useState } from "react";
|
||||
import { isDesktop } from "react-device-detect";
|
||||
import { TransformWrapper, TransformComponent } from "react-zoom-pan-pinch";
|
||||
import useSWR from "swr";
|
||||
@ -62,6 +62,11 @@ export function FrigatePlusDialog({
|
||||
upload?.plus_id ? "submitted" : "reviewing",
|
||||
);
|
||||
|
||||
useEffect(
|
||||
() => setState(upload?.plus_id ? "submitted" : "reviewing"),
|
||||
[upload],
|
||||
);
|
||||
|
||||
const onSubmitToPlus = useCallback(
|
||||
async (falsePositive: boolean) => {
|
||||
if (!upload) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user