interview-widget 3.2.25 → 3.2.26

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -18,6 +18,7 @@ interface VideoFeedProps {
18
18
  cheatingWarningVisible?: boolean;
19
19
  isDeviceLoading?: boolean;
20
20
  videoAllowed?: boolean;
21
+ questionNumber?: number;
21
22
  }
22
23
  declare const VideoFeed: import('react').ForwardRefExoticComponent<VideoFeedProps & import('react').RefAttributes<VideoFeedHandle>>;
23
24
  export default VideoFeed;
@@ -1,4 +1,4 @@
1
- export declare function useVideoRecordingStream(interviewId: string, record_video?: boolean): {
1
+ export declare function useVideoRecordingStream(interviewId: string, record_video?: boolean, questionNumber?: number): {
2
2
  startRecording: (stream: MediaStream) => void;
3
3
  stopRecording: () => void;
4
4
  isRecording: boolean;
@@ -44,6 +44,7 @@ declare class STTService {
44
44
  private pendingStopPromise;
45
45
  private isStarting;
46
46
  private recordingStartTime;
47
+ private lastRecordedBlob;
47
48
  static activeStream: MediaStream | null;
48
49
  constructor(config?: STTConfig);
49
50
  /**
@@ -39,11 +39,11 @@ export declare function getSafariSafeAudioConstraints(base?: MediaTrackConstrain
39
39
  */
40
40
  export declare function getMediaRecorderStartArg(): number | undefined;
41
41
  /**
42
- * Stops a MediaRecorder, flushing the final chunk on Safari first.
43
- *
44
- * Safari sometimes fails to include the last audio segment in the blob
45
- * unless requestData() is explicitly called just before stop(). [SAFARI]
46
- * On other browsers requestData() is already called at the stop-promise
47
- * setup site, so we only call stop() here.
42
+ * [SAFARI] Do NOT call requestData() before stop().
43
+ * Without a timeslice, stop() guarantees one ondataavailable fires
44
+ * synchronously before onstop. Calling requestData() first queues a
45
+ * SECOND ondataavailable as a separate task on some Safari versions
46
+ * that second event arrives AFTER onstop, so audioChunks is empty
47
+ * when the blob is assembled. Just call stop().
48
48
  */
49
49
  export declare function safariSafeStop(recorder: MediaRecorder): void;