@opentok/client 2.28.4-alpha.6 → 2.28.4-alpha.7
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/dist/js/opentok.d.ts +1 -1
- package/dist/js/opentok.js +24 -9
- package/dist/js/opentok.js.map +1 -1
- package/dist/js/opentok.min.js +6 -6
- package/dist/js/opentok.min.js.map +1 -1
- package/package.json +1 -1
package/dist/js/opentok.d.ts
CHANGED
|
@@ -597,7 +597,7 @@ declare namespace OT {
|
|
|
597
597
|
getAudioVolume(): number;
|
|
598
598
|
getImgData(): string | null;
|
|
599
599
|
getStats(callback: (error?: OTError, stats?: SubscriberStats) => void): void;
|
|
600
|
-
getRtcStatsReport(): Promise<
|
|
600
|
+
getRtcStatsReport(): Promise<Map<string, any>>;
|
|
601
601
|
subscribeToCaptions(value: boolean): Promise<void>;
|
|
602
602
|
isSubscribedToCaptions(): boolean;
|
|
603
603
|
isAudioBlocked(): boolean;
|
package/dist/js/opentok.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license OpenTok.js 2.28.4
|
|
2
|
+
* @license OpenTok.js 2.28.4 609c534
|
|
3
3
|
*
|
|
4
4
|
* Copyright (c) 2010-2024 TokBox, Inc.
|
|
5
5
|
* Subject to the applicable Software Development Kit (SDK) License Agreement:
|
|
6
6
|
* https://www.vonage.com/legal/communications-apis/terms-of-use/
|
|
7
7
|
*
|
|
8
|
-
* Date:
|
|
8
|
+
* Date: Mon, 21 Oct 2024 17:27:15 GMT
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
11
|
(function webpackUniversalModuleDefinition(root, factory) {
|
|
@@ -8070,7 +8070,7 @@ const logging = (0, _log.default)('StaticConfig');
|
|
|
8070
8070
|
*/
|
|
8071
8071
|
|
|
8072
8072
|
/** @type builtInConfig */
|
|
8073
|
-
const builtInConfig = (0, _cloneDeep.default)({"version":"v2.28.4","buildHash":"
|
|
8073
|
+
const builtInConfig = (0, _cloneDeep.default)({"version":"v2.28.4","buildHash":"609c534","minimumVersion":{"firefox":52,"chrome":49},"debug":false,"websiteURL":"http://www.tokbox.com","configURL":"https://config.opentok.com","ipWhitelistConfigURL":"","cdnURL":"","loggingURL":"https://hlg.tokbox.com/prod","apiURL":"https://anvil.opentok.com"});
|
|
8074
8074
|
const whitelistAllowedRuntimeProperties = (0, _pick.default)(['apiURL', 'assetURL', 'cdnURL', 'sessionInfoOverrides', 'loggingURL']);
|
|
8075
8075
|
const liveConfigMap = {
|
|
8076
8076
|
apiUrl: 'apiURL',
|
|
@@ -33017,6 +33017,7 @@ var _watchSubscriberAudio = _interopRequireDefault(__webpack_require__(683));
|
|
|
33017
33017
|
// @todo enable the following disabled rules see OPENTOK-31136 for more info
|
|
33018
33018
|
/* eslint-disable global-require, no-param-reassign, no-void, no-shadow */
|
|
33019
33019
|
/* eslint-disable func-names */
|
|
33020
|
+
/* global RTCStatsReport */
|
|
33020
33021
|
|
|
33021
33022
|
function SubscriberPeerConnectionFactory(deps) {
|
|
33022
33023
|
if (deps === void 0) {
|
|
@@ -33212,7 +33213,14 @@ function SubscriberPeerConnectionFactory(deps) {
|
|
|
33212
33213
|
};
|
|
33213
33214
|
this.getRtcStatsReport = function (callback) {
|
|
33214
33215
|
if (_peerConnection) {
|
|
33215
|
-
_peerConnection.getRtcStatsReport(null,
|
|
33216
|
+
_peerConnection.getRtcStatsReport(null, (error, stats) => {
|
|
33217
|
+
if (stats instanceof RTCStatsReport || Object.getPrototypeOf(stats).toString().includes('RTCStatsReport')) {
|
|
33218
|
+
// Convert RTCStatsReport to Map for consistency with SPC
|
|
33219
|
+
callback(error, new Map([...stats]));
|
|
33220
|
+
} else {
|
|
33221
|
+
callback(error, stats);
|
|
33222
|
+
}
|
|
33223
|
+
});
|
|
33216
33224
|
} else {
|
|
33217
33225
|
const errorCode = ExceptionCodes.PEER_CONNECTION_NOT_CONNECTED;
|
|
33218
33226
|
callback(new OTHelpers.Error(OTErrorClass.getTitleByCode(errorCode), Errors.PEER_CONNECTION_NOT_CONNECTED, {
|
|
@@ -36538,6 +36546,9 @@ function SubscriberFactory(_ref2) {
|
|
|
36538
36546
|
},
|
|
36539
36547
|
get isSubscribingToVideo() {
|
|
36540
36548
|
return _properties.subscribeToVideo;
|
|
36549
|
+
},
|
|
36550
|
+
getActiveSourceStreamId() {
|
|
36551
|
+
return _activeSourceStreamId;
|
|
36541
36552
|
}
|
|
36542
36553
|
};
|
|
36543
36554
|
this._onSenderStatsReceived = content => {
|
|
@@ -66120,6 +66131,9 @@ function SessionFactory(deps) {
|
|
|
66120
66131
|
isE2ee() {
|
|
66121
66132
|
return _session.sessionInfo.e2ee && _e2eeSecretSet && !!_session.capabilities.supportsE2ee;
|
|
66122
66133
|
},
|
|
66134
|
+
isSpc() {
|
|
66135
|
+
return _useSinglePeerConnection;
|
|
66136
|
+
},
|
|
66123
66137
|
isSocketReconnecting() {
|
|
66124
66138
|
return _isSocketReconnecting;
|
|
66125
66139
|
},
|
|
@@ -92761,17 +92775,18 @@ const collectGetStatsHelper = (peerConnection, tracks, callback) => {
|
|
|
92761
92775
|
};
|
|
92762
92776
|
exports.collectGetStatsHelper = collectGetStatsHelper;
|
|
92763
92777
|
const collectRtcStatsReportHelper = (peerConnection, tracks, callback) => {
|
|
92764
|
-
// getRtcStatsReport uses an
|
|
92765
|
-
|
|
92778
|
+
// getRtcStatsReport uses an RTCStatsReport object that cannot be merged
|
|
92779
|
+
// so we convert it to a Map
|
|
92780
|
+
const mapMerge = function mapMerge(previous, stats) {
|
|
92766
92781
|
if (previous === void 0) {
|
|
92767
|
-
previous =
|
|
92782
|
+
previous = new Map();
|
|
92768
92783
|
}
|
|
92769
|
-
return
|
|
92784
|
+
return new Map([...previous, ...stats]);
|
|
92770
92785
|
};
|
|
92771
92786
|
collectStatsHelper({
|
|
92772
92787
|
tracks,
|
|
92773
92788
|
getStats: (track, completion) => peerConnection.getRtcStatsReport(track, completion),
|
|
92774
|
-
merge
|
|
92789
|
+
merge: mapMerge
|
|
92775
92790
|
}, callback);
|
|
92776
92791
|
};
|
|
92777
92792
|
exports.collectRtcStatsReportHelper = collectRtcStatsReportHelper;
|