@stream-io/video-client 0.0.3 → 0.0.5
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 +14 -0
- package/dist/index.browser.es.js +10 -8
- package/dist/index.browser.es.js.map +1 -1
- package/dist/index.cjs.js +10 -8
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +10 -8
- package/dist/index.es.js.map +1 -1
- package/dist/src/events/recording.d.ts +3 -0
- package/dist/src/gen/coordinator/index.d.ts +68 -11
- package/package.json +1 -1
- package/src/events/__tests__/recording.test.ts +14 -3
- package/src/events/recording.ts +15 -3
- package/src/gen/coordinator/index.ts +68 -11
- package/src/helpers/sdp-munging.ts +7 -11
- package/src/rtc/publisher.ts +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,20 @@
|
|
|
2
2
|
|
|
3
3
|
This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
|
|
4
4
|
|
|
5
|
+
### [0.0.5](https://github.com/GetStream/stream-video-js/compare/client0.0.4...client0.0.5) (2023-06-06)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
* adjustments to the new egress response structure ([#595](https://github.com/GetStream/stream-video-js/issues/595)) ([3b3edea](https://github.com/GetStream/stream-video-js/commit/3b3edea7d032a50cb0757c6b46114e8009ae56fc))
|
|
11
|
+
|
|
12
|
+
### [0.0.4](https://github.com/GetStream/stream-video-js/compare/client0.0.3...client0.0.4) (2023-06-06)
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
### Bug Fixes
|
|
16
|
+
|
|
17
|
+
* use and save toggled dtx to sdp and remove empty lines when munging ([#597](https://github.com/GetStream/stream-video-js/issues/597)) ([3971276](https://github.com/GetStream/stream-video-js/commit/39712764ce7ac30557ef36ef7f736f2a0a5728b5))
|
|
18
|
+
|
|
5
19
|
### [0.0.3](https://github.com/GetStream/stream-video-js/compare/client0.0.2...client0.0.3) (2023-06-05)
|
|
6
20
|
|
|
7
21
|
|
package/dist/index.browser.es.js
CHANGED
|
@@ -5239,8 +5239,8 @@ const removeCodec = (sdp, mediaType, codecToRemove) => {
|
|
|
5239
5239
|
const fmtp = section === null || section === void 0 ? void 0 : section.fmtp.find((f) => f.payload === codecId);
|
|
5240
5240
|
return sdp
|
|
5241
5241
|
.replace(mediaSection.original, `${mediaSection.mediaWithPorts} ${newCodecOrder}`)
|
|
5242
|
-
.replace(new RegExp(`${rtpMap.original}[\r\n
|
|
5243
|
-
.replace((fmtp === null || fmtp === void 0 ? void 0 : fmtp.original) ? new RegExp(`${fmtp === null || fmtp === void 0 ? void 0 : fmtp.original}[\r\n
|
|
5242
|
+
.replace(new RegExp(`${rtpMap.original}[\r\n]+`), '') // remove the corresponding rtpmap line
|
|
5243
|
+
.replace((fmtp === null || fmtp === void 0 ? void 0 : fmtp.original) ? new RegExp(`${fmtp === null || fmtp === void 0 ? void 0 : fmtp.original}[\r\n]+`) : '', ''); // remove the corresponding fmtp line
|
|
5244
5244
|
};
|
|
5245
5245
|
/**
|
|
5246
5246
|
* Gets the fmtp line corresponding to opus
|
|
@@ -5250,8 +5250,7 @@ const getOpusFmtp = (sdp) => {
|
|
|
5250
5250
|
const rtpMap = section === null || section === void 0 ? void 0 : section.rtpMap.find((r) => r.codec.toLowerCase() === 'opus');
|
|
5251
5251
|
const codecId = rtpMap === null || rtpMap === void 0 ? void 0 : rtpMap.payload;
|
|
5252
5252
|
if (codecId) {
|
|
5253
|
-
|
|
5254
|
-
return fmtp;
|
|
5253
|
+
return section === null || section === void 0 ? void 0 : section.fmtp.find((f) => f.payload === codecId);
|
|
5255
5254
|
}
|
|
5256
5255
|
};
|
|
5257
5256
|
/**
|
|
@@ -5784,7 +5783,7 @@ class Publisher {
|
|
|
5784
5783
|
const offer = yield this.publisher.createOffer();
|
|
5785
5784
|
let sdp = offer.sdp;
|
|
5786
5785
|
if (sdp) {
|
|
5787
|
-
toggleDtx(sdp, this.isDtxEnabled);
|
|
5786
|
+
sdp = toggleDtx(sdp, this.isDtxEnabled);
|
|
5788
5787
|
if (isReactNative()) {
|
|
5789
5788
|
if (this.preferredVideoCodec) {
|
|
5790
5789
|
sdp = setPreferredCodec(sdp, 'video', this.preferredVideoCodec);
|
|
@@ -7544,14 +7543,17 @@ const watchCallBroadcastingStarted = (state) => {
|
|
|
7544
7543
|
return function onCallBroadcastingStarted(event) {
|
|
7545
7544
|
if (event.type !== 'call.broadcasting_started')
|
|
7546
7545
|
return;
|
|
7547
|
-
state.setMetadata((metadata) => (Object.assign(Object.assign({}, metadata), { broadcasting: true,
|
|
7546
|
+
state.setMetadata((metadata) => (Object.assign(Object.assign({}, metadata), { egress: Object.assign(Object.assign({}, metadata.egress), { broadcasting: true, hls: Object.assign(Object.assign({}, metadata.egress.hls), { playlist_url: event.hls_playlist_url }) }) })));
|
|
7548
7547
|
};
|
|
7549
7548
|
};
|
|
7549
|
+
/**
|
|
7550
|
+
* Watches for `call.broadcasting_stopped` events.
|
|
7551
|
+
*/
|
|
7550
7552
|
const watchCallBroadcastingStopped = (state) => {
|
|
7551
7553
|
return function onCallBroadcastingStopped(event) {
|
|
7552
7554
|
if (event.type !== 'call.broadcasting_stopped')
|
|
7553
7555
|
return;
|
|
7554
|
-
state.setMetadata((metadata) => (Object.assign(Object.assign({}, metadata), { broadcasting: false })));
|
|
7556
|
+
state.setMetadata((metadata) => (Object.assign(Object.assign({}, metadata), { egress: Object.assign(Object.assign({}, metadata.egress), { broadcasting: false }) })));
|
|
7555
7557
|
};
|
|
7556
7558
|
};
|
|
7557
7559
|
|
|
@@ -10991,7 +10993,7 @@ class StreamClient {
|
|
|
10991
10993
|
}
|
|
10992
10994
|
getUserAgent() {
|
|
10993
10995
|
return (this.userAgent ||
|
|
10994
|
-
`stream-video-javascript-client-${this.node ? 'node' : 'browser'}-${"0.0.
|
|
10996
|
+
`stream-video-javascript-client-${this.node ? 'node' : 'browser'}-${"0.0.4"}`);
|
|
10995
10997
|
}
|
|
10996
10998
|
setUserAgent(userAgent) {
|
|
10997
10999
|
this.userAgent = userAgent;
|