@opentok/client 2.31.0-alpha.60 → 2.31.0-alpha.62

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.
@@ -605,8 +605,8 @@ declare namespace OT {
605
605
  }
606
606
 
607
607
  export type SenderStats = {
608
- senderMaxBitrate: number;
609
- senderCurrentBitrate: number;
608
+ connectionMaxAllocatedBitrate: number;
609
+ connectionEstimatedBandwidth: number;
610
610
  }
611
611
 
612
612
  export type SubscriberStats = {
@@ -1,11 +1,11 @@
1
1
  /**
2
- * @license OpenTok.js 2.31.0 d7e6af97f
2
+ * @license OpenTok.js 2.31.0 362183743
3
3
  *
4
4
  * Copyright (c) 2010-2025 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: Fri, 03 Oct 2025 15:12:43 GMT
8
+ * Date: Fri, 10 Oct 2025 10:29:57 GMT
9
9
  */
10
10
 
11
11
  (function webpackUniversalModuleDefinition(root, factory) {
@@ -8547,7 +8547,7 @@ function staticConfigFactory(_temp) {
8547
8547
  _ref$axios = _ref.axios,
8548
8548
  axios = _ref$axios === void 0 ? _axios.default : _ref$axios,
8549
8549
  _ref$properties = _ref.properties,
8550
- properties = _ref$properties === void 0 ? {"version":"v2.31.0","buildHash":"d7e6af97f","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","vonageApiURL":""} : _ref$properties;
8550
+ properties = _ref$properties === void 0 ? {"version":"v2.31.0","buildHash":"362183743","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","vonageApiURL":""} : _ref$properties;
8551
8551
  /** @type builtInConfig */
8552
8552
  const builtInConfig = (0, _cloneDeep.default)(properties);
8553
8553
  /**
@@ -38743,9 +38743,12 @@ function SubscriberFactory(_ref2) {
38743
38743
  if (env.isSafari && !_stream.hasVideo && _widgetView) {
38744
38744
  _widgetView.bindAudioTrackOnly();
38745
38745
  }
38746
- this.dispatchEvent(new Events.VideoEnabledChangedEvent(_stream.hasVideo ? 'videoEnabled' : 'videoDisabled', {
38747
- reason: 'publishVideo'
38748
- }));
38746
+ // Prevent event from being triggered due to video beind disabled/enabled due to quality
38747
+ if (_congestionLevel < 2) {
38748
+ this.dispatchEvent(new Events.VideoEnabledChangedEvent(_stream.hasVideo ? 'videoEnabled' : 'videoDisabled', {
38749
+ reason: 'publishVideo'
38750
+ }));
38751
+ }
38749
38752
  break;
38750
38753
  case 'hasAudio':
38751
38754
  _muteDisplayMode.update();
@@ -39515,9 +39518,9 @@ function SubscriberFactory(_ref2) {
39515
39518
  * <li><code>video.packetsReceived</code> (Number) &mdash; The total number of video packets
39516
39519
  * received by the subscriber</li>
39517
39520
  * <li><code>video.frameRate</code> (Number) &mdash; The current average video frame rate</li>
39518
- * <li><code>senderStats.senderMaxBitrate</code> (Number) &mdash; The maximum bitrate that can
39519
- * be estimated for the sender connection, in bps (bits per second)</li>
39520
- * <li><code>senderStats.senderCurrentBitrate</code> (Number) &mdash; The current bandwidth
39521
+ * <li><code>senderStats.connectionMaxAllocatedBitrate</code> (Number) &mdash; The maximum
39522
+ * bitrate that can be estimated for the sender connection, in bps (bits per second)</li>
39523
+ * <li><code>senderStats.connectionEstimatedBandwidth</code> (Number) &mdash; The current bandwidth
39521
39524
  * estimation for the sender connection, in bps (bits per second)</li>
39522
39525
  * </ul>
39523
39526
  * </li>
@@ -39573,8 +39576,8 @@ function SubscriberFactory(_ref2) {
39573
39576
  maxBitrateBitsPerSecond = _senderStats2.maxBitrateBitsPerSecond,
39574
39577
  sentEstimatedBandwidthBitsPerSecond = _senderStats2.sentEstimatedBandwidthBitsPerSecond;
39575
39578
  otStats.senderStats = {
39576
- senderMaxBitrate: maxBitrateBitsPerSecond,
39577
- senderCurrentBitrate: sentEstimatedBandwidthBitsPerSecond
39579
+ connectionMaxAllocatedBitrate: maxBitrateBitsPerSecond,
39580
+ connectionEstimatedBandwidth: sentEstimatedBandwidthBitsPerSecond
39578
39581
  };
39579
39582
  }
39580
39583
  callback(null, otStats);