@stream-io/video-client 1.25.5 → 1.26.1

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.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,18 @@
2
2
 
3
3
  This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
4
4
 
5
+ ## [1.26.1](https://github.com/GetStream/stream-video-js/compare/@stream-io/video-client-1.26.0...@stream-io/video-client-1.26.1) (2025-07-17)
6
+
7
+ ### Bug Fixes
8
+
9
+ - force `play-and-record` audioSession on Safari ([#1855](https://github.com/GetStream/stream-video-js/issues/1855)) ([a3552a3](https://github.com/GetStream/stream-video-js/commit/a3552a3be606ac99120b6c4ce6187eaa920a02ef))
10
+
11
+ ## [1.26.0](https://github.com/GetStream/stream-video-js/compare/@stream-io/video-client-1.25.5...@stream-io/video-client-1.26.0) (2025-07-11)
12
+
13
+ ### Features
14
+
15
+ - **react-native:** speech detection ([#1850](https://github.com/GetStream/stream-video-js/issues/1850)) ([3f53e95](https://github.com/GetStream/stream-video-js/commit/3f53e95fdf0e739c809648211c52542d86df183f))
16
+
5
17
  ## [1.25.5](https://github.com/GetStream/stream-video-js/compare/@stream-io/video-client-1.25.4...@stream-io/video-client-1.25.5) (2025-07-08)
6
18
 
7
19
  ### Bug Fixes
@@ -5810,7 +5810,7 @@ const aggregate = (stats) => {
5810
5810
  return report;
5811
5811
  };
5812
5812
 
5813
- const version = "1.25.5";
5813
+ const version = "1.26.1";
5814
5814
  const [major, minor, patch] = version.split('.');
5815
5815
  let sdkInfo = {
5816
5816
  type: SdkType.PLAIN_JAVASCRIPT,
@@ -9036,6 +9036,12 @@ class DynascaleManager {
9036
9036
  if (context.state === 'suspended') {
9037
9037
  document.addEventListener('click', this.resumeAudioContext);
9038
9038
  }
9039
+ // @ts-expect-error audioSession is available in Safari only
9040
+ const audioSession = navigator.audioSession;
9041
+ if (audioSession) {
9042
+ // https://github.com/w3c/audio-session/blob/main/explainer.md
9043
+ audioSession.type = 'play-and-record';
9044
+ }
9039
9045
  return (this.audioContext = context);
9040
9046
  };
9041
9047
  this.resumeAudioContext = () => {
@@ -10535,20 +10541,26 @@ const createSoundDetector = (audioStream, onSoundDetectedStateChanged, options =
10535
10541
  };
10536
10542
 
10537
10543
  class RNSpeechDetector {
10538
- constructor() {
10544
+ constructor(externalAudioStream) {
10539
10545
  this.pc1 = new RTCPeerConnection({});
10540
10546
  this.pc2 = new RTCPeerConnection({});
10547
+ this.externalAudioStream = externalAudioStream;
10541
10548
  }
10542
10549
  /**
10543
10550
  * Starts the speech detection.
10544
10551
  */
10545
10552
  async start(onSoundDetectedStateChanged) {
10546
10553
  try {
10547
- this.cleanupAudioStream();
10548
- const audioStream = await navigator.mediaDevices.getUserMedia({
10549
- audio: true,
10550
- });
10551
- this.audioStream = audioStream;
10554
+ let audioStream;
10555
+ if (this.externalAudioStream != null) {
10556
+ audioStream = this.externalAudioStream;
10557
+ }
10558
+ else {
10559
+ audioStream = await navigator.mediaDevices.getUserMedia({
10560
+ audio: true,
10561
+ });
10562
+ this.audioStream = audioStream;
10563
+ }
10552
10564
  this.pc1.addEventListener('icecandidate', async (e) => {
10553
10565
  await this.pc2.addIceCandidate(e.candidate);
10554
10566
  });
@@ -10590,7 +10602,12 @@ class RNSpeechDetector {
10590
10602
  stop() {
10591
10603
  this.pc1.close();
10592
10604
  this.pc2.close();
10593
- this.cleanupAudioStream();
10605
+ if (this.externalAudioStream != null) {
10606
+ this.externalAudioStream = undefined;
10607
+ }
10608
+ else {
10609
+ this.cleanupAudioStream();
10610
+ }
10594
10611
  }
10595
10612
  /**
10596
10613
  * Public method that detects the audio levels and returns the status.
@@ -14284,7 +14301,7 @@ class StreamClient {
14284
14301
  this.getUserAgent = () => {
14285
14302
  if (!this.cachedUserAgent) {
14286
14303
  const { clientAppIdentifier = {} } = this.options;
14287
- const { sdkName = 'js', sdkVersion = "1.25.5", ...extras } = clientAppIdentifier;
14304
+ const { sdkName = 'js', sdkVersion = "1.26.1", ...extras } = clientAppIdentifier;
14288
14305
  this.cachedUserAgent = [
14289
14306
  `stream-video-${sdkName}-v${sdkVersion}`,
14290
14307
  ...Object.entries(extras).map(([key, value]) => `${key}=${value}`),
@@ -14837,5 +14854,5 @@ class StreamVideoClient {
14837
14854
  }
14838
14855
  StreamVideoClient._instances = new Map();
14839
14856
 
14840
- export { AudioSettingsRequestDefaultDeviceEnum, AudioSettingsResponseDefaultDeviceEnum, browsers as Browsers, Call, CallState, CallType, CallTypes, CallingState, CameraManager, CameraManagerState, CreateDeviceRequestPushProviderEnum, DebounceType, DynascaleManager, ErrorFromResponse, FrameRecordingSettingsRequestModeEnum, FrameRecordingSettingsRequestQualityEnum, FrameRecordingSettingsResponseModeEnum, InputMediaDeviceManager, InputMediaDeviceManagerState, LayoutSettingsRequestNameEnum, MicrophoneManager, MicrophoneManagerState, NoiseCancellationSettingsModeEnum, OwnCapability, RTMPBroadcastRequestQualityEnum, RTMPSettingsRequestQualityEnum, RecordSettingsRequestModeEnum, RecordSettingsRequestQualityEnum, rxUtils as RxUtils, ScreenShareManager, ScreenShareState, events as SfuEvents, models as SfuModels, SpeakerManager, SpeakerState, StartClosedCaptionsRequestLanguageEnum, StartTranscriptionRequestLanguageEnum, StreamSfuClient, StreamVideoClient, StreamVideoReadOnlyStateStore, StreamVideoWriteableStateStore, TranscriptionSettingsRequestClosedCaptionModeEnum, TranscriptionSettingsRequestLanguageEnum, TranscriptionSettingsRequestModeEnum, TranscriptionSettingsResponseClosedCaptionModeEnum, TranscriptionSettingsResponseLanguageEnum, TranscriptionSettingsResponseModeEnum, VideoSettingsRequestCameraFacingEnum, VideoSettingsResponseCameraFacingEnum, ViewportTracker, VisibilityState, checkIfAudioOutputChangeSupported, combineComparators, conditional, createSoundDetector, defaultSortPreset, descending, deviceIds$, disposeOfMediaStream, dominantSpeaker, getAudioBrowserPermission, getAudioDevices, getAudioOutputDevices, getAudioStream, getClientDetails, getDeviceState, getLogLevel, getLogger, getScreenShareStream, getSdkInfo, getVideoBrowserPermission, getVideoDevices, getVideoStream, getWebRTCInfo, hasAudio, hasScreenShare, hasScreenShareAudio, hasVideo, isPinned, livestreamOrAudioRoomSortPreset, logLevels, logToConsole, name, noopComparator, paginatedLayoutSortPreset, pinned, publishingAudio, publishingVideo, reactionType, resolveDeviceId, role, screenSharing, setDeviceInfo, setLogLevel, setLogger, setOSInfo, setPowerState, setSdkInfo, setThermalState, setWebRTCInfo, speakerLayoutSortPreset, speaking };
14857
+ export { AudioSettingsRequestDefaultDeviceEnum, AudioSettingsResponseDefaultDeviceEnum, browsers as Browsers, Call, CallState, CallType, CallTypes, CallingState, CameraManager, CameraManagerState, CreateDeviceRequestPushProviderEnum, DebounceType, DynascaleManager, ErrorFromResponse, FrameRecordingSettingsRequestModeEnum, FrameRecordingSettingsRequestQualityEnum, FrameRecordingSettingsResponseModeEnum, InputMediaDeviceManager, InputMediaDeviceManagerState, LayoutSettingsRequestNameEnum, MicrophoneManager, MicrophoneManagerState, NoiseCancellationSettingsModeEnum, OwnCapability, RNSpeechDetector, RTMPBroadcastRequestQualityEnum, RTMPSettingsRequestQualityEnum, RecordSettingsRequestModeEnum, RecordSettingsRequestQualityEnum, rxUtils as RxUtils, ScreenShareManager, ScreenShareState, events as SfuEvents, models as SfuModels, SpeakerManager, SpeakerState, StartClosedCaptionsRequestLanguageEnum, StartTranscriptionRequestLanguageEnum, StreamSfuClient, StreamVideoClient, StreamVideoReadOnlyStateStore, StreamVideoWriteableStateStore, TranscriptionSettingsRequestClosedCaptionModeEnum, TranscriptionSettingsRequestLanguageEnum, TranscriptionSettingsRequestModeEnum, TranscriptionSettingsResponseClosedCaptionModeEnum, TranscriptionSettingsResponseLanguageEnum, TranscriptionSettingsResponseModeEnum, VideoSettingsRequestCameraFacingEnum, VideoSettingsResponseCameraFacingEnum, ViewportTracker, VisibilityState, checkIfAudioOutputChangeSupported, combineComparators, conditional, createSoundDetector, defaultSortPreset, descending, deviceIds$, disposeOfMediaStream, dominantSpeaker, getAudioBrowserPermission, getAudioDevices, getAudioOutputDevices, getAudioStream, getClientDetails, getDeviceState, getLogLevel, getLogger, getScreenShareStream, getSdkInfo, getVideoBrowserPermission, getVideoDevices, getVideoStream, getWebRTCInfo, hasAudio, hasScreenShare, hasScreenShareAudio, hasVideo, isPinned, livestreamOrAudioRoomSortPreset, logLevels, logToConsole, name, noopComparator, paginatedLayoutSortPreset, pinned, publishingAudio, publishingVideo, reactionType, resolveDeviceId, role, screenSharing, setDeviceInfo, setLogLevel, setLogger, setOSInfo, setPowerState, setSdkInfo, setThermalState, setWebRTCInfo, speakerLayoutSortPreset, speaking };
14841
14858
  //# sourceMappingURL=index.browser.es.js.map