clear last tickets
This commit is contained in:
@@ -28,6 +28,7 @@ import RestartSpinnerIcon from "../../assets/UI/RestartSpinnerIcon";
|
||||
import { registerBlobUrl, releaseBlobUrl } from "../../utils/blobUrlCache";
|
||||
|
||||
const TIME_BEFORE_INCREMENT_MS = 20000;
|
||||
const COUNTDOWN_SECONDS = __DEV__ ? 1 : 10;
|
||||
const WEB_PREVIEW_WIDTH = 360;
|
||||
|
||||
const toSeconds = (v) => {
|
||||
@@ -318,7 +319,7 @@ const RecordPlayback = ({ route }) => {
|
||||
setLooping(!!originalLoopingValueRef.current.value);
|
||||
}
|
||||
};
|
||||
}, [setLooping])
|
||||
}, [setLooping]),
|
||||
);
|
||||
|
||||
useFocusEffect(
|
||||
@@ -327,7 +328,7 @@ const RecordPlayback = ({ route }) => {
|
||||
return () => {
|
||||
void resetSessionRef.current?.();
|
||||
};
|
||||
}, [])
|
||||
}, []),
|
||||
);
|
||||
|
||||
useEffect(() => {
|
||||
@@ -359,7 +360,7 @@ const RecordPlayback = ({ route }) => {
|
||||
!navigator.mediaDevices?.getUserMedia
|
||||
) {
|
||||
setMediaError(
|
||||
new Error("La capture vidéo n'est pas supportée sur ce navigateur")
|
||||
new Error("La capture vidéo n'est pas supportée sur ce navigateur"),
|
||||
);
|
||||
setMediaReady(false);
|
||||
return;
|
||||
@@ -473,7 +474,7 @@ const RecordPlayback = ({ route }) => {
|
||||
perfStartRef.current != null
|
||||
? Math.max(
|
||||
0,
|
||||
(performance.now() - perfStartRef.current - pausedTotal) / 1000
|
||||
(performance.now() - perfStartRef.current - pausedTotal) / 1000,
|
||||
)
|
||||
: 0;
|
||||
|
||||
@@ -588,7 +589,7 @@ const RecordPlayback = ({ route }) => {
|
||||
},
|
||||
},
|
||||
],
|
||||
{ cancelable: false }
|
||||
{ cancelable: false },
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -603,7 +604,7 @@ const RecordPlayback = ({ route }) => {
|
||||
setIsPaused(false);
|
||||
isPausedRef.current = false;
|
||||
setIsPreparing(true);
|
||||
setCountdown(5);
|
||||
setCountdown(COUNTDOWN_SECONDS);
|
||||
if (countdownTimerRef.current) clearInterval(countdownTimerRef.current);
|
||||
countdownTimerRef.current = setInterval(() => {
|
||||
setCountdown((c) => {
|
||||
|
||||
Reference in New Issue
Block a user