@stream-io/video-client 1.18.1 → 1.18.2
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 +9 -0
- package/dist/index.browser.es.js +19 -6
- package/dist/index.browser.es.js.map +1 -1
- package/dist/index.cjs.js +19 -6
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +19 -6
- package/dist/index.es.js.map +1 -1
- package/package.json +1 -1
- package/src/Call.ts +14 -3
- package/src/rtc/Publisher.ts +9 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,15 @@
|
|
|
2
2
|
|
|
3
3
|
This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
|
|
4
4
|
|
|
5
|
+
## [1.18.2](https://github.com/GetStream/stream-video-js/compare/@stream-io/video-client-1.18.1...@stream-io/video-client-1.18.2) (2025-03-04)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
* do not accept again on reconnections ([#1705](https://github.com/GetStream/stream-video-js/issues/1705)) ([bedd2d8](https://github.com/GetStream/stream-video-js/commit/bedd2d8aafd7ff8260f63b500e25807518ccd365))
|
|
11
|
+
* do not stop original track in RN ([#1708](https://github.com/GetStream/stream-video-js/issues/1708)) ([ab0ada2](https://github.com/GetStream/stream-video-js/commit/ab0ada283c753d4cdfd59b6eaf75af26cf54fd7e))
|
|
12
|
+
* prevent extra unnecessary reconnect after offline to online ([#1706](https://github.com/GetStream/stream-video-js/issues/1706)) ([bc3920a](https://github.com/GetStream/stream-video-js/commit/bc3920a81f398fd9e166ee4517b32d58f50d56fe))
|
|
13
|
+
|
|
5
14
|
## [1.18.1](https://github.com/GetStream/stream-video-js/compare/@stream-io/video-client-1.18.0...@stream-io/video-client-1.18.1) (2025-02-28)
|
|
6
15
|
|
|
7
16
|
|
package/dist/index.browser.es.js
CHANGED
|
@@ -5710,7 +5710,9 @@ class Publisher extends BasePeerConnection {
|
|
|
5710
5710
|
else {
|
|
5711
5711
|
const previousTrack = transceiver.sender.track;
|
|
5712
5712
|
await transceiver.sender.replaceTrack(trackToPublish);
|
|
5713
|
-
|
|
5713
|
+
if (!isReactNative()) {
|
|
5714
|
+
this.stopTrack(previousTrack);
|
|
5715
|
+
}
|
|
5714
5716
|
}
|
|
5715
5717
|
}
|
|
5716
5718
|
};
|
|
@@ -5811,6 +5813,11 @@ class Publisher extends BasePeerConnection {
|
|
|
5811
5813
|
}
|
|
5812
5814
|
for (const track of this.clonedTracks) {
|
|
5813
5815
|
this.stopTrack(track);
|
|
5816
|
+
// @ts-expect-error release() is present in react-native-webrtc
|
|
5817
|
+
if (track && typeof track.release === 'function') {
|
|
5818
|
+
// @ts-expect-error
|
|
5819
|
+
track.release();
|
|
5820
|
+
}
|
|
5814
5821
|
}
|
|
5815
5822
|
};
|
|
5816
5823
|
this.changePublishQuality = async (videoSender) => {
|
|
@@ -7463,7 +7470,7 @@ const aggregate = (stats) => {
|
|
|
7463
7470
|
return report;
|
|
7464
7471
|
};
|
|
7465
7472
|
|
|
7466
|
-
const version = "1.18.
|
|
7473
|
+
const version = "1.18.2";
|
|
7467
7474
|
const [major, minor, patch] = version.split('.');
|
|
7468
7475
|
let sdkInfo = {
|
|
7469
7476
|
type: SdkType.PLAIN_JAVASCRIPT,
|
|
@@ -10625,8 +10632,7 @@ class Call {
|
|
|
10625
10632
|
}
|
|
10626
10633
|
catch (error) {
|
|
10627
10634
|
// prevent triggering reconnect flow if the state is OFFLINE
|
|
10628
|
-
const avoidRestoreState = this.state.callingState === CallingState.OFFLINE
|
|
10629
|
-
callingState === CallingState.RECONNECTING;
|
|
10635
|
+
const avoidRestoreState = this.state.callingState === CallingState.OFFLINE;
|
|
10630
10636
|
if (!avoidRestoreState) {
|
|
10631
10637
|
// restore the previous call state if the join-flow fails
|
|
10632
10638
|
this.state.setCallingState(callingState);
|
|
@@ -10913,7 +10919,8 @@ class Call {
|
|
|
10913
10919
|
if (data?.ring) {
|
|
10914
10920
|
this.ringingSubject.next(true);
|
|
10915
10921
|
}
|
|
10916
|
-
|
|
10922
|
+
const isReconnecting = this.reconnectStrategy !== WebsocketReconnectStrategy.UNSPECIFIED;
|
|
10923
|
+
if (!isReconnecting && this.ringing && !this.isCreatedByMe) {
|
|
10917
10924
|
// signals other users that I have accepted the incoming call.
|
|
10918
10925
|
await this.accept();
|
|
10919
10926
|
}
|
|
@@ -10994,6 +11001,12 @@ class Call {
|
|
|
10994
11001
|
break; // do-while loop, reconnection worked, exit the loop
|
|
10995
11002
|
}
|
|
10996
11003
|
catch (error) {
|
|
11004
|
+
if (this.state.callingState === CallingState.OFFLINE) {
|
|
11005
|
+
this.logger('trace', `[Reconnect] Can't reconnect while offline, stopping reconnection attempts`);
|
|
11006
|
+
break;
|
|
11007
|
+
// we don't need to handle the error if the call is offline
|
|
11008
|
+
// network change event will trigger the reconnection
|
|
11009
|
+
}
|
|
10997
11010
|
if (error instanceof ErrorFromResponse && error.unrecoverable) {
|
|
10998
11011
|
this.logger('warn', `[Reconnect] Can't reconnect due to coordinator unrecoverable error`, error);
|
|
10999
11012
|
this.state.setCallingState(CallingState.RECONNECTING_FAILED);
|
|
@@ -13093,7 +13106,7 @@ class StreamClient {
|
|
|
13093
13106
|
this.getUserAgent = () => {
|
|
13094
13107
|
if (!this.cachedUserAgent) {
|
|
13095
13108
|
const { clientAppIdentifier = {} } = this.options;
|
|
13096
|
-
const { sdkName = 'js', sdkVersion = "1.18.
|
|
13109
|
+
const { sdkName = 'js', sdkVersion = "1.18.2", ...extras } = clientAppIdentifier;
|
|
13097
13110
|
this.cachedUserAgent = [
|
|
13098
13111
|
`stream-video-${sdkName}-v${sdkVersion}`,
|
|
13099
13112
|
...Object.entries(extras).map(([key, value]) => `${key}=${value}`),
|