getVideoFrigate increase timeout to 20 min

This commit is contained in:
NlightN22 2024-12-01 01:47:41 +07:00
parent 910a0fa309
commit 302f117b44
2 changed files with 3 additions and 4 deletions

View File

@ -82,7 +82,7 @@ export const proxyApi = {
getVideoFrigate: async (videoUrl: string, onProgress: (percentage: number | undefined) => void) => {
const response = await instanceApi.get<Blob>(videoUrl, {
responseType: 'blob',
timeout: 10 * 60 * 1000,
timeout: 20 * 60 * 1000,
onDownloadProgress: (progressEvent) => {
const total = progressEvent.total
const current = progressEvent.loaded;

View File

@ -1,11 +1,10 @@
import { Button, Flex, Group, Text } from '@mantine/core';
import { IconDownload } from '@tabler/icons-react';
import { Flex, Group, Text } from '@mantine/core';
import { useTranslation } from 'react-i18next';
import { proxyApi } from '../../../services/frigate.proxy/frigate.api';
import { EventFrigate } from '../../../types/event';
import { getDurationFromTimestamps, unixTimeToDate } from '../../utils/dateUtil';
import VideoPlayer from '../players/VideoPlayer';
import DownloadButton from '../buttons/DownloadButton';
import VideoPlayer from '../players/VideoPlayer';
interface EventPanelProps {
event: EventFrigate