@webex/plugin-meetings 3.8.1-web-workers-keepalive.1 → 3.9.0-multipleLLM.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.
Files changed (121) hide show
  1. package/dist/breakouts/breakout.js +1 -1
  2. package/dist/breakouts/index.js +1 -1
  3. package/dist/constants.js +26 -2
  4. package/dist/constants.js.map +1 -1
  5. package/dist/interpretation/index.js +1 -1
  6. package/dist/interpretation/siLanguage.js +1 -1
  7. package/dist/locus-info/index.js +77 -95
  8. package/dist/locus-info/index.js.map +1 -1
  9. package/dist/locus-info/parser.js +4 -1
  10. package/dist/locus-info/parser.js.map +1 -1
  11. package/dist/media/properties.js +53 -5
  12. package/dist/media/properties.js.map +1 -1
  13. package/dist/meeting/brbState.js +14 -12
  14. package/dist/meeting/brbState.js.map +1 -1
  15. package/dist/meeting/in-meeting-actions.js +8 -0
  16. package/dist/meeting/in-meeting-actions.js.map +1 -1
  17. package/dist/meeting/index.js +443 -225
  18. package/dist/meeting/index.js.map +1 -1
  19. package/dist/meeting/muteState.js +2 -5
  20. package/dist/meeting/muteState.js.map +1 -1
  21. package/dist/meeting/request.js +44 -0
  22. package/dist/meeting/request.js.map +1 -1
  23. package/dist/meeting/request.type.js.map +1 -1
  24. package/dist/meeting/type.js +7 -0
  25. package/dist/meeting/type.js.map +1 -0
  26. package/dist/meeting/util.js +98 -13
  27. package/dist/meeting/util.js.map +1 -1
  28. package/dist/meeting-info/meeting-info-v2.js +29 -21
  29. package/dist/meeting-info/meeting-info-v2.js.map +1 -1
  30. package/dist/meetings/index.js +18 -10
  31. package/dist/meetings/index.js.map +1 -1
  32. package/dist/member/index.js.map +1 -1
  33. package/dist/member/types.js.map +1 -1
  34. package/dist/members/collection.js +13 -0
  35. package/dist/members/collection.js.map +1 -1
  36. package/dist/members/index.js +53 -29
  37. package/dist/members/index.js.map +1 -1
  38. package/dist/members/request.js +3 -3
  39. package/dist/members/request.js.map +1 -1
  40. package/dist/members/util.js +25 -8
  41. package/dist/members/util.js.map +1 -1
  42. package/dist/metrics/constants.js +2 -1
  43. package/dist/metrics/constants.js.map +1 -1
  44. package/dist/multistream/mediaRequestManager.js +1 -1
  45. package/dist/multistream/mediaRequestManager.js.map +1 -1
  46. package/dist/multistream/remoteMedia.js +34 -5
  47. package/dist/multistream/remoteMedia.js.map +1 -1
  48. package/dist/multistream/remoteMediaGroup.js +42 -2
  49. package/dist/multistream/remoteMediaGroup.js.map +1 -1
  50. package/dist/multistream/sendSlotManager.js +32 -2
  51. package/dist/multistream/sendSlotManager.js.map +1 -1
  52. package/dist/reachability/index.js +3 -3
  53. package/dist/reachability/index.js.map +1 -1
  54. package/dist/types/constants.d.ts +24 -0
  55. package/dist/types/locus-info/index.d.ts +54 -10
  56. package/dist/types/media/properties.d.ts +21 -0
  57. package/dist/types/meeting/brbState.d.ts +0 -1
  58. package/dist/types/meeting/in-meeting-actions.d.ts +8 -0
  59. package/dist/types/meeting/index.d.ts +51 -20
  60. package/dist/types/meeting/request.d.ts +18 -1
  61. package/dist/types/meeting/request.type.d.ts +74 -0
  62. package/dist/types/meeting/type.d.ts +9 -0
  63. package/dist/types/meeting/util.d.ts +13 -3
  64. package/dist/types/meeting-info/meeting-info-v2.d.ts +6 -3
  65. package/dist/types/meetings/index.d.ts +3 -1
  66. package/dist/types/member/types.d.ts +1 -0
  67. package/dist/types/members/collection.d.ts +6 -0
  68. package/dist/types/members/index.d.ts +22 -9
  69. package/dist/types/members/request.d.ts +1 -1
  70. package/dist/types/members/util.d.ts +13 -6
  71. package/dist/types/metrics/constants.d.ts +1 -0
  72. package/dist/types/multistream/remoteMedia.d.ts +20 -1
  73. package/dist/types/multistream/remoteMediaGroup.d.ts +11 -0
  74. package/dist/types/multistream/sendSlotManager.d.ts +16 -0
  75. package/dist/webinar/index.js +1 -1
  76. package/package.json +23 -24
  77. package/src/constants.ts +25 -2
  78. package/src/locus-info/index.ts +133 -96
  79. package/src/locus-info/parser.ts +5 -1
  80. package/src/media/properties.ts +43 -0
  81. package/src/meeting/brbState.ts +9 -7
  82. package/src/meeting/in-meeting-actions.ts +17 -0
  83. package/src/meeting/index.ts +273 -42
  84. package/src/meeting/muteState.ts +2 -6
  85. package/src/meeting/request.ts +39 -0
  86. package/src/meeting/request.type.ts +64 -0
  87. package/src/meeting/type.ts +9 -0
  88. package/src/meeting/util.ts +114 -22
  89. package/src/meeting-info/meeting-info-v2.ts +24 -5
  90. package/src/meetings/index.ts +12 -5
  91. package/src/member/index.ts +1 -0
  92. package/src/member/types.ts +1 -0
  93. package/src/members/collection.ts +11 -0
  94. package/src/members/index.ts +51 -15
  95. package/src/members/request.ts +2 -2
  96. package/src/members/util.ts +34 -6
  97. package/src/metrics/constants.ts +1 -0
  98. package/src/multistream/mediaRequestManager.ts +7 -7
  99. package/src/multistream/remoteMedia.ts +34 -4
  100. package/src/multistream/remoteMediaGroup.ts +37 -2
  101. package/src/multistream/sendSlotManager.ts +34 -2
  102. package/src/reachability/index.ts +3 -3
  103. package/test/unit/spec/locus-info/index.js +229 -98
  104. package/test/unit/spec/locus-info/parser.js +3 -2
  105. package/test/unit/spec/media/properties.ts +137 -0
  106. package/test/unit/spec/meeting/brbState.ts +9 -9
  107. package/test/unit/spec/meeting/in-meeting-actions.ts +8 -0
  108. package/test/unit/spec/meeting/index.js +1022 -93
  109. package/test/unit/spec/meeting/muteState.js +32 -6
  110. package/test/unit/spec/meeting/request.js +92 -0
  111. package/test/unit/spec/meeting/utils.js +167 -17
  112. package/test/unit/spec/meeting-info/meetinginfov2.js +8 -3
  113. package/test/unit/spec/meetings/index.js +12 -1
  114. package/test/unit/spec/members/collection.js +120 -0
  115. package/test/unit/spec/members/index.js +140 -12
  116. package/test/unit/spec/members/request.js +57 -2
  117. package/test/unit/spec/members/utils.js +139 -17
  118. package/test/unit/spec/multistream/mediaRequestManager.ts +19 -6
  119. package/test/unit/spec/multistream/remoteMedia.ts +66 -2
  120. package/test/unit/spec/multistream/sendSlotManager.ts +59 -0
  121. package/test/unit/spec/reachability/index.ts +158 -1
@@ -382,10 +382,11 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
382
382
  /**
383
383
  * @param {Object} attrs
384
384
  * @param {Object} options
385
+ * @param {Function} callback - if provided, it will be called with the newly created meeting object as soon as the meeting.id is set
385
386
  * @constructor
386
387
  * @memberof Meeting
387
388
  */
388
- function Meeting(attrs, _options) {
389
+ function Meeting(attrs, _options, callback) {
389
390
  var _attrs$callStateForMe, _attrs$callStateForMe2, _this$locusInfo, _this$locusInfo$links, _this$locusInfo$links2, _this$locusInfo$links3, _this$locusInfo2, _this$locusInfo2$full, _this$locusInfo3, _this$locusInfo4;
390
391
  var _this;
391
392
  (0, _classCallCheck2.default)(this, Meeting);
@@ -475,6 +476,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
475
476
  (0, _defineProperty3.default)((0, _assertThisInitialized2.default)(_this), "shareStatus", void 0);
476
477
  (0, _defineProperty3.default)((0, _assertThisInitialized2.default)(_this), "screenShareFloorState", void 0);
477
478
  (0, _defineProperty3.default)((0, _assertThisInitialized2.default)(_this), "statsAnalyzer", void 0);
479
+ (0, _defineProperty3.default)((0, _assertThisInitialized2.default)(_this), "statsMonitor", void 0);
478
480
  (0, _defineProperty3.default)((0, _assertThisInitialized2.default)(_this), "transcription", void 0);
479
481
  (0, _defineProperty3.default)((0, _assertThisInitialized2.default)(_this), "updateMediaConnections", void 0);
480
482
  (0, _defineProperty3.default)((0, _assertThisInitialized2.default)(_this), "userDisplayHints", void 0);
@@ -947,6 +949,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
947
949
  // @ts-ignore
948
950
  _this.webex.internal.newMetrics.submitClientEvent({
949
951
  name: 'client.ice.start',
952
+ payload: {
953
+ // @ts-ignore
954
+ labels: _util2.default.getCaEventLabelsForIpVersion(_this.webex)
955
+ },
950
956
  options: {
951
957
  meetingId: _this.id
952
958
  }
@@ -1071,10 +1077,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
1071
1077
  }
1072
1078
  }
1073
1079
 
1074
- // Count members that are in the meeting.
1080
+ // Count members that are in the meeting or in the lobby.
1075
1081
  var members = _this.getMembers().membersCollection.members;
1076
1082
  event.data.intervalMetadata.meetingUserCount = (0, _values.default)(members).filter(function (member) {
1077
- return member.isInMeeting;
1083
+ return member.isInMeeting || member.isInLobby;
1078
1084
  }).length;
1079
1085
 
1080
1086
  // @ts-ignore
@@ -1489,6 +1495,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
1489
1495
  * @memberof Meeting
1490
1496
  */
1491
1497
  _this.id = _uuid.default.v4();
1498
+ if (callback) {
1499
+ callback((0, _assertThisInitialized2.default)(_this));
1500
+ }
1501
+
1492
1502
  /**
1493
1503
  * Call state used for metrics
1494
1504
  * @instance
@@ -1961,6 +1971,13 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
1961
1971
  * @memberof Meeting
1962
1972
  */
1963
1973
  _this.networkQualityMonitor = null;
1974
+ /**
1975
+ * @instance
1976
+ * @type {StatsMonitor}
1977
+ * @private
1978
+ * @memberof Meeting
1979
+ */
1980
+ _this.statsMonitor = null;
1964
1981
  /**
1965
1982
  * Indicates network status of the webrtc media connection
1966
1983
  * @instance
@@ -2377,6 +2394,24 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
2377
2394
  this.callStateForMetrics.correlationId = correlationId;
2378
2395
  }
2379
2396
 
2397
+ /**
2398
+ * Getter - Returns callStateForMetrics.pstnCorrelationId
2399
+ * @returns {string | undefined}
2400
+ */
2401
+ }, {
2402
+ key: "pstnCorrelationId",
2403
+ get: function get() {
2404
+ return this.callStateForMetrics.pstnCorrelationId;
2405
+ }
2406
+
2407
+ /**
2408
+ * Setter - sets callStateForMetrics.pstnCorrelationId
2409
+ * @param {string | undefined} correlationId
2410
+ */,
2411
+ set: function set(correlationId) {
2412
+ this.callStateForMetrics.pstnCorrelationId = correlationId;
2413
+ }
2414
+
2380
2415
  /**
2381
2416
  * Getter - Returns callStateForMetrics.userNameInput
2382
2417
  * @returns {string}
@@ -2578,11 +2613,11 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
2578
2613
  key: "fetchMeetingInfoInternal",
2579
2614
  value: (function () {
2580
2615
  var _fetchMeetingInfoInternal = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee5(_ref8) {
2581
- var destination, destinationType, _ref8$password, password, _ref8$captchaCode, captchaCode, _ref8$extraParams, extraParams, _ref8$sendCAevents, sendCAevents, _ref8$registrationId, registrationId, captchaInfo, info, _err$body, _err$body2;
2616
+ var destination, destinationType, _ref8$password, password, _ref8$captchaCode, captchaCode, _ref8$extraParams, extraParams, _ref8$sendCAevents, sendCAevents, _ref8$registrationId, registrationId, _ref8$classificationI, classificationId, captchaInfo, info, _err$body, _err$body2;
2582
2617
  return _regenerator.default.wrap(function _callee5$(_context5) {
2583
2618
  while (1) switch (_context5.prev = _context5.next) {
2584
2619
  case 0:
2585
- destination = _ref8.destination, destinationType = _ref8.destinationType, _ref8$password = _ref8.password, password = _ref8$password === void 0 ? null : _ref8$password, _ref8$captchaCode = _ref8.captchaCode, captchaCode = _ref8$captchaCode === void 0 ? null : _ref8$captchaCode, _ref8$extraParams = _ref8.extraParams, extraParams = _ref8$extraParams === void 0 ? {} : _ref8$extraParams, _ref8$sendCAevents = _ref8.sendCAevents, sendCAevents = _ref8$sendCAevents === void 0 ? false : _ref8$sendCAevents, _ref8$registrationId = _ref8.registrationId, registrationId = _ref8$registrationId === void 0 ? null : _ref8$registrationId;
2620
+ destination = _ref8.destination, destinationType = _ref8.destinationType, _ref8$password = _ref8.password, password = _ref8$password === void 0 ? null : _ref8$password, _ref8$captchaCode = _ref8.captchaCode, captchaCode = _ref8$captchaCode === void 0 ? null : _ref8$captchaCode, _ref8$extraParams = _ref8.extraParams, extraParams = _ref8$extraParams === void 0 ? {} : _ref8$extraParams, _ref8$sendCAevents = _ref8.sendCAevents, sendCAevents = _ref8$sendCAevents === void 0 ? false : _ref8$sendCAevents, _ref8$registrationId = _ref8.registrationId, registrationId = _ref8$registrationId === void 0 ? null : _ref8$registrationId, _ref8$classificationI = _ref8.classificationId, classificationId = _ref8$classificationI === void 0 ? null : _ref8$classificationI;
2586
2621
  _context5.prev = 1;
2587
2622
  captchaInfo = captchaCode ? {
2588
2623
  code: captchaCode,
@@ -2594,7 +2629,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
2594
2629
  this.config.installedOrgID, this.locusId, extraParams, {
2595
2630
  meetingId: this.id,
2596
2631
  sendCAevents: sendCAevents
2597
- }, registrationId);
2632
+ }, registrationId, null, classificationId);
2598
2633
  case 5:
2599
2634
  info = _context5.sent;
2600
2635
  this.parseMeetingInfo(info === null || info === void 0 ? void 0 : info.body, this.destination, info === null || info === void 0 ? void 0 : info.errors);
@@ -3655,9 +3690,16 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3655
3690
  // There is no concept of local/remote share for whiteboard
3656
3691
  // It does not matter who requested to share the whiteboard, everyone gets the same view
3657
3692
  else if (whiteboardShare.disposition === _constants.FLOOR_ACTION.GRANTED) {
3658
- // WHITEBOARD - sharing whiteboard
3659
- // Webinar attendee should receive whiteboard as remote share
3660
- newShareStatus = (_this15$locusInfo = _this15.locusInfo) !== null && _this15$locusInfo !== void 0 && (_this15$locusInfo$inf = _this15$locusInfo.info) !== null && _this15$locusInfo$inf !== void 0 && _this15$locusInfo$inf.isWebinar && (_this15$webinar = _this15.webinar) !== null && _this15$webinar !== void 0 && _this15$webinar.selfIsAttendee ? _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE : _constants.SHARE_STATUS.WHITEBOARD_SHARE_ACTIVE;
3693
+ if ((_this15$locusInfo = _this15.locusInfo) !== null && _this15$locusInfo !== void 0 && (_this15$locusInfo$inf = _this15$locusInfo.info) !== null && _this15$locusInfo$inf !== void 0 && _this15$locusInfo$inf.isWebinar && (_this15$webinar = _this15.webinar) !== null && _this15$webinar !== void 0 && _this15$webinar.selfIsAttendee) {
3694
+ // WHITEBOARD - sharing whiteboard
3695
+ // Webinar attendee should receive whiteboard as remote share
3696
+ newShareStatus = _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE;
3697
+ } else if (_this15.guest) {
3698
+ // If user is a guest to a meeting, they should receive whiteboard as remote share
3699
+ newShareStatus = _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE;
3700
+ } else {
3701
+ newShareStatus = _constants.SHARE_STATUS.WHITEBOARD_SHARE_ACTIVE;
3702
+ }
3661
3703
  }
3662
3704
  // or if content share is either released or null and whiteboard share is either released or null, no one is sharing
3663
3705
  else if ((previousContentShare && contentShare.disposition === _constants.FLOOR_ACTION.RELEASED || contentShare.disposition === null) && (previousWhiteboardShare && whiteboardShare.disposition === _constants.FLOOR_ACTION.RELEASED || whiteboardShare.disposition === null)) {
@@ -3665,7 +3707,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3665
3707
  }
3666
3708
  _loggerProxy.default.logger.info("Meeting:index#setUpLocusInfoMediaInactiveListener --> this.shareStatus=".concat(_this15.shareStatus, " newShareStatus=").concat(newShareStatus));
3667
3709
  if (!(newShareStatus !== _this15.shareStatus)) {
3668
- _context8.next = 46;
3710
+ _context8.next = 48;
3669
3711
  break;
3670
3712
  }
3671
3713
  oldShareStatus = _this15.shareStatus; // update our state before we send out any notifications
@@ -3673,14 +3715,14 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3673
3715
 
3674
3716
  // send out "stop" notifications for the old state
3675
3717
  _context8.t0 = oldShareStatus;
3676
- _context8.next = _context8.t0 === _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE ? 15 : _context8.t0 === _constants.SHARE_STATUS.LOCAL_SHARE_ACTIVE ? 17 : _context8.t0 === _constants.SHARE_STATUS.WHITEBOARD_SHARE_ACTIVE ? 19 : _context8.t0 === _constants.SHARE_STATUS.NO_SHARE ? 21 : 22;
3718
+ _context8.next = _context8.t0 === _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE ? 15 : _context8.t0 === _constants.SHARE_STATUS.LOCAL_SHARE_ACTIVE ? 17 : _context8.t0 === _constants.SHARE_STATUS.WHITEBOARD_SHARE_ACTIVE ? 19 : _context8.t0 === _constants.SHARE_STATUS.NO_SHARE ? 23 : 24;
3677
3719
  break;
3678
3720
  case 15:
3679
3721
  _triggerProxy.default.trigger(_this15, {
3680
3722
  file: 'meetings/index',
3681
3723
  function: 'remoteShare'
3682
3724
  }, _constants.EVENT_TRIGGERS.MEETING_STOPPED_SHARING_REMOTE);
3683
- return _context8.abrupt("break", 23);
3725
+ return _context8.abrupt("break", 25);
3684
3726
  case 17:
3685
3727
  _triggerProxy.default.trigger(_this15, {
3686
3728
  file: 'meeting/index',
@@ -3688,51 +3730,76 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3688
3730
  }, _constants.EVENT_TRIGGERS.MEETING_STOPPED_SHARING_LOCAL, {
3689
3731
  reason: _constants.SHARE_STOPPED_REASON.SELF_STOPPED
3690
3732
  });
3691
- return _context8.abrupt("break", 23);
3733
+ return _context8.abrupt("break", 25);
3692
3734
  case 19:
3693
3735
  _triggerProxy.default.trigger(_this15, {
3694
3736
  file: 'meeting/index',
3695
3737
  function: 'stopWhiteboardShare'
3696
3738
  }, _constants.EVENT_TRIGGERS.MEETING_STOPPED_SHARING_WHITEBOARD);
3697
- return _context8.abrupt("break", 23);
3698
- case 21:
3699
- return _context8.abrupt("break", 23);
3700
- case 22:
3701
- return _context8.abrupt("break", 23);
3739
+ // @ts-ignore
3740
+ _this15.webex.internal.newMetrics.callDiagnosticLatencies.saveTimestamp({
3741
+ key: 'internal.client.share.stopped'
3742
+ });
3743
+ // @ts-ignore
3744
+ _this15.webex.internal.newMetrics.submitClientEvent({
3745
+ name: 'client.share.stopped',
3746
+ payload: {
3747
+ mediaType: 'whiteboard',
3748
+ shareDuration:
3749
+ // @ts-ignore
3750
+ _this15.webex.internal.newMetrics.callDiagnosticLatencies.getShareDuration()
3751
+ },
3752
+ options: {
3753
+ meetingId: _this15.id
3754
+ }
3755
+ });
3756
+ return _context8.abrupt("break", 25);
3702
3757
  case 23:
3758
+ return _context8.abrupt("break", 25);
3759
+ case 24:
3760
+ return _context8.abrupt("break", 25);
3761
+ case 25:
3703
3762
  _context8.t1 = newShareStatus;
3704
- _context8.next = _context8.t1 === _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE ? 26 : _context8.t1 === _constants.SHARE_STATUS.LOCAL_SHARE_ACTIVE ? 35 : _context8.t1 === _constants.SHARE_STATUS.WHITEBOARD_SHARE_ACTIVE ? 38 : _context8.t1 === _constants.SHARE_STATUS.NO_SHARE ? 41 : 42;
3763
+ _context8.next = _context8.t1 === _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE ? 28 : _context8.t1 === _constants.SHARE_STATUS.LOCAL_SHARE_ACTIVE ? 37 : _context8.t1 === _constants.SHARE_STATUS.WHITEBOARD_SHARE_ACTIVE ? 40 : _context8.t1 === _constants.SHARE_STATUS.NO_SHARE ? 43 : 44;
3705
3764
  break;
3706
- case 26:
3765
+ case 28:
3707
3766
  sendStartedSharingRemote = function sendStartedSharingRemote() {
3767
+ var _this15$locusInfo2, _this15$locusInfo2$in, _this15$webinar2;
3708
3768
  _this15.remoteShareInstanceId = contentShare.shareInstanceId;
3709
3769
  _this15.shareCAEventSentStatus.receiveStart = false;
3710
3770
  _this15.shareCAEventSentStatus.receiveStop = false;
3771
+ var finalBeneficiaryId = contentShare.beneficiaryId;
3772
+ // In case of attendee in webinar, the whiteboard is shared by other participants
3773
+ if ((_this15$locusInfo2 = _this15.locusInfo) !== null && _this15$locusInfo2 !== void 0 && (_this15$locusInfo2$in = _this15$locusInfo2.info) !== null && _this15$locusInfo2$in !== void 0 && _this15$locusInfo2$in.isWebinar && (_this15$webinar2 = _this15.webinar) !== null && _this15$webinar2 !== void 0 && _this15$webinar2.selfIsAttendee) {
3774
+ if (!finalBeneficiaryId && whiteboardShare.beneficiaryId) {
3775
+ finalBeneficiaryId = whiteboardShare.beneficiaryId;
3776
+ }
3777
+ }
3711
3778
  _triggerProxy.default.trigger(_this15, {
3712
3779
  file: 'meetings/index',
3713
3780
  function: 'remoteShare'
3714
3781
  }, _constants.EVENT_TRIGGERS.MEETING_STARTED_SHARING_REMOTE, {
3715
- memberId: contentShare.beneficiaryId,
3782
+ memberId: finalBeneficiaryId,
3716
3783
  url: contentShare.url,
3717
3784
  shareInstanceId: _this15.remoteShareInstanceId,
3718
3785
  annotationInfo: contentShare.annotation,
3719
3786
  resourceType: contentShare.resourceType
3720
3787
  });
3721
3788
  };
3722
- _context8.prev = 27;
3789
+ _context8.prev = 29;
3723
3790
  if (!((_this15$mediaProperti = _this15.mediaProperties.mediaDirection) !== null && _this15$mediaProperti !== void 0 && _this15$mediaProperti.sendShare && oldShareStatus === _constants.SHARE_STATUS.LOCAL_SHARE_ACTIVE)) {
3724
- _context8.next = 31;
3791
+ _context8.next = 33;
3725
3792
  break;
3726
3793
  }
3727
- _context8.next = 31;
3794
+ _context8.next = 33;
3728
3795
  return _this15.unpublishStreams([_this15.mediaProperties.shareVideoStream, _this15.mediaProperties.shareAudioStream]);
3729
- case 31:
3730
- _context8.prev = 31;
3796
+ case 33:
3797
+ _context8.prev = 33;
3731
3798
  sendStartedSharingRemote();
3732
- return _context8.finish(31);
3733
- case 34:
3734
- return _context8.abrupt("break", 43);
3735
- case 35:
3799
+ return _context8.finish(33);
3800
+ case 36:
3801
+ return _context8.abrupt("break", 45);
3802
+ case 37:
3736
3803
  _triggerProxy.default.trigger(_this15, {
3737
3804
  file: 'meeting/index',
3738
3805
  function: 'share'
@@ -3748,8 +3815,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3748
3815
  meetingId: _this15.id
3749
3816
  }
3750
3817
  });
3751
- return _context8.abrupt("break", 43);
3752
- case 38:
3818
+ return _context8.abrupt("break", 45);
3819
+ case 40:
3753
3820
  _triggerProxy.default.trigger(_this15, {
3754
3821
  file: 'meeting/index',
3755
3822
  function: 'startWhiteboardShare'
@@ -3767,16 +3834,16 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3767
3834
  meetingId: _this15.id
3768
3835
  }
3769
3836
  });
3770
- return _context8.abrupt("break", 43);
3771
- case 41:
3772
- return _context8.abrupt("break", 43);
3773
- case 42:
3774
- return _context8.abrupt("break", 43);
3837
+ return _context8.abrupt("break", 45);
3775
3838
  case 43:
3839
+ return _context8.abrupt("break", 45);
3840
+ case 44:
3841
+ return _context8.abrupt("break", 45);
3842
+ case 45:
3776
3843
  _this15.members.locusMediaSharesUpdate(payload);
3777
- _context8.next = 47;
3844
+ _context8.next = 49;
3778
3845
  break;
3779
- case 46:
3846
+ case 48:
3780
3847
  if (newShareStatus === _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE) {
3781
3848
  // if we got here, then some remote participant has stolen
3782
3849
  // the presentation from another remote participant
@@ -3816,11 +3883,11 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3816
3883
  });
3817
3884
  _this15.members.locusMediaSharesUpdate(payload);
3818
3885
  }
3819
- case 47:
3886
+ case 49:
3820
3887
  case "end":
3821
3888
  return _context8.stop();
3822
3889
  }
3823
- }, _callee8, null, [[27,, 31, 34]]);
3890
+ }, _callee8, null, [[29,, 33, 36]]);
3824
3891
  }));
3825
3892
  return function (_x8) {
3826
3893
  return _ref31.apply(this, arguments);
@@ -4318,11 +4385,13 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
4318
4385
 
4319
4386
  /**
4320
4387
  * Invite a guest to the call that isn't normally part of this call
4321
- * @param {Object} invitee
4388
+ * @param {Invitee} invitee
4322
4389
  * @param {String} invitee.emailAddress
4323
4390
  * @param {String} invitee.email
4324
4391
  * @param {String} invitee.phoneNumber
4325
4392
  * @param {Boolean} [alertIfActive]
4393
+ * @param {Boolean} [invitee.skipEmailValidation]
4394
+ * @param {Boolean} [invitee.isInternalNumber]
4326
4395
  * @returns {Promise} see #members.addMember
4327
4396
  * @public
4328
4397
  * @memberof Meeting
@@ -4336,7 +4405,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
4336
4405
 
4337
4406
  /**
4338
4407
  * Cancel an outgoing phone call invitation made during a meeting
4339
- * @param {Object} invitee
4408
+ * @param {Invitee} invitee
4340
4409
  * @param {String} invitee.phoneNumber
4341
4410
  * @returns {Promise} see #members.cancelPhoneInvite
4342
4411
  * @public
@@ -4349,17 +4418,18 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
4349
4418
  }
4350
4419
 
4351
4420
  /**
4352
- * Cancel an SIP call invitation made during a meeting
4353
- * @param {Object} invitee
4421
+ * Cancel an SIP/phone call invitation made during a meeting
4422
+ * @param {Invitee} invitee
4354
4423
  * @param {String} invitee.memberId
4355
- * @returns {Promise} see #members.cancelSIPInvite
4424
+ * @param {Boolean} [invitee.isInternalNumber] - When cancel phone invitation, if the number is internal
4425
+ * @returns {Promise} see #members.cancelInviteByMemberId
4356
4426
  * @public
4357
4427
  * @memberof Meeting
4358
4428
  */
4359
4429
  }, {
4360
- key: "cancelSIPInvite",
4361
- value: function cancelSIPInvite(invitee) {
4362
- return this.members.cancelSIPInvite(invitee);
4430
+ key: "cancelInviteByMemberId",
4431
+ value: function cancelInviteByMemberId(invitee) {
4432
+ return this.members.cancelInviteByMemberId(invitee);
4363
4433
  }
4364
4434
 
4365
4435
  /**
@@ -4644,8 +4714,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
4644
4714
  isClosedCaptionActive: _util2.default.isClosedCaptionActive(this.userDisplayHints),
4645
4715
  canStartManualCaption: _util2.default.canStartManualCaption(this.userDisplayHints),
4646
4716
  canStopManualCaption: _util2.default.canStopManualCaption(this.userDisplayHints),
4717
+ isLocalRecordingStarted: _util2.default.isLocalRecordingStarted(this.userDisplayHints),
4718
+ isLocalRecordingStopped: _util2.default.isLocalRecordingStopped(this.userDisplayHints),
4719
+ isLocalRecordingPaused: _util2.default.isLocalRecordingPaused(this.userDisplayHints),
4647
4720
  isManualCaptionActive: _util2.default.isManualCaptionActive(this.userDisplayHints),
4648
4721
  isSaveTranscriptsEnabled: _util2.default.isSaveTranscriptsEnabled(this.userDisplayHints),
4722
+ isSpokenLanguageAutoDetectionEnabled: _util2.default.isSpokenLanguageAutoDetectionEnabled(this.userDisplayHints),
4649
4723
  isWebexAssistantActive: _util2.default.isWebexAssistantActive(this.userDisplayHints),
4650
4724
  canViewCaptionPanel: _util2.default.canViewCaptionPanel(this.userDisplayHints),
4651
4725
  isRealTimeTranslationEnabled: _util2.default.isRealTimeTranslationEnabled(this.userDisplayHints),
@@ -6318,24 +6392,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6318
6392
  _this36.deferJoin = undefined;
6319
6393
  return join;
6320
6394
  }).catch(function (error) {
6321
- var _this36$meetingInfo, _error$error;
6395
+ var _error$error;
6322
6396
  _this36.meetingFiniteStateMachine.fail(error);
6323
6397
  _loggerProxy.default.logger.error('Meeting:index#join --> Failed', error);
6324
6398
 
6325
- // @ts-ignore
6326
- _this36.webex.internal.newMetrics.submitClientEvent({
6327
- name: 'client.locus.join.response',
6328
- payload: {
6329
- identifiers: {
6330
- meetingLookupUrl: (_this36$meetingInfo = _this36.meetingInfo) === null || _this36$meetingInfo === void 0 ? void 0 : _this36$meetingInfo.meetingLookupUrl
6331
- }
6332
- },
6333
- options: {
6334
- meetingId: _this36.id,
6335
- rawError: error
6336
- }
6337
- });
6338
-
6339
6399
  // TODO: change this to error codes and pre defined dictionary
6340
6400
  _metrics.default.sendBehavioralMetric(_constants2.default.JOIN_FAILURE, {
6341
6401
  correlation_id: _this36.correlationId,
@@ -6489,14 +6549,14 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6489
6549
  value: function dialInPstn() {
6490
6550
  var _this38 = this;
6491
6551
  if (this.isPhoneProvisioned(this.dialInDeviceStatus)) return _promise.default.resolve(); // prevent multiple dial in devices from being provisioned
6492
-
6493
- var correlationId = this.correlationId,
6552
+ this.pstnCorrelationId = _uuid.default.v4();
6553
+ var pstnCorrelationId = this.pstnCorrelationId,
6494
6554
  locusUrl = this.locusUrl;
6495
6555
  if (!this.dialInUrl) this.dialInUrl = "dialin:///".concat(_uuid.default.v4());
6496
6556
  return this.meetingRequest
6497
6557
  // @ts-ignore
6498
6558
  .dialIn({
6499
- correlationId: correlationId,
6559
+ correlationId: pstnCorrelationId,
6500
6560
  dialInUrl: this.dialInUrl,
6501
6561
  locusUrl: locusUrl,
6502
6562
  clientUrl: this.deviceUrl
@@ -6505,11 +6565,15 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6505
6565
  _metrics.default.sendBehavioralMetric(_constants2.default.ADD_DIAL_IN_FAILURE, {
6506
6566
  correlation_id: _this38.correlationId,
6507
6567
  dial_in_url: _this38.dialInUrl,
6568
+ dial_in_correlation_id: pstnCorrelationId,
6508
6569
  locus_id: locusUrl.split('/').pop(),
6509
6570
  client_url: _this38.deviceUrl,
6510
6571
  reason: (_error$error2 = error.error) === null || _error$error2 === void 0 ? void 0 : _error$error2.message,
6511
6572
  stack: error.stack
6512
6573
  });
6574
+ if (_this38.pstnCorrelationId === pstnCorrelationId) {
6575
+ _this38.pstnCorrelationId = undefined;
6576
+ }
6513
6577
  return _promise.default.reject(error);
6514
6578
  });
6515
6579
  }
@@ -6526,14 +6590,14 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6526
6590
  value: function dialOutPstn(phoneNumber) {
6527
6591
  var _this39 = this;
6528
6592
  if (this.isPhoneProvisioned(this.dialOutDeviceStatus)) return _promise.default.resolve(); // prevent multiple dial out devices from being provisioned
6529
-
6530
- var correlationId = this.correlationId,
6531
- locusUrl = this.locusUrl;
6593
+ this.pstnCorrelationId = _uuid.default.v4();
6594
+ var locusUrl = this.locusUrl,
6595
+ pstnCorrelationId = this.pstnCorrelationId;
6532
6596
  if (!this.dialOutUrl) this.dialOutUrl = "dialout:///".concat(_uuid.default.v4());
6533
6597
  return this.meetingRequest
6534
6598
  // @ts-ignore
6535
6599
  .dialOut({
6536
- correlationId: correlationId,
6600
+ correlationId: pstnCorrelationId,
6537
6601
  dialOutUrl: this.dialOutUrl,
6538
6602
  phoneNumber: phoneNumber,
6539
6603
  locusUrl: locusUrl,
@@ -6543,11 +6607,15 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6543
6607
  _metrics.default.sendBehavioralMetric(_constants2.default.ADD_DIAL_OUT_FAILURE, {
6544
6608
  correlation_id: _this39.correlationId,
6545
6609
  dial_out_url: _this39.dialOutUrl,
6610
+ dial_out_correlation_id: pstnCorrelationId,
6546
6611
  locus_id: locusUrl.split('/').pop(),
6547
6612
  client_url: _this39.deviceUrl,
6548
6613
  reason: (_error$error3 = error.error) === null || _error$error3 === void 0 ? void 0 : _error$error3.message,
6549
6614
  stack: error.stack
6550
6615
  });
6616
+ if (_this39.pstnCorrelationId === pstnCorrelationId) {
6617
+ _this39.pstnCorrelationId = undefined;
6618
+ }
6551
6619
  return _promise.default.reject(error);
6552
6620
  });
6553
6621
  }
@@ -6562,7 +6630,13 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6562
6630
  }, {
6563
6631
  key: "disconnectPhoneAudio",
6564
6632
  value: function disconnectPhoneAudio() {
6565
- return _promise.default.all([this.isPhoneProvisioned(this.dialInDeviceStatus) ? _util2.default.disconnectPhoneAudio(this, this.dialInUrl) : _promise.default.resolve(), this.isPhoneProvisioned(this.dialOutDeviceStatus) ? _util2.default.disconnectPhoneAudio(this, this.dialOutUrl) : _promise.default.resolve()]);
6633
+ var _this40 = this;
6634
+ var correlationToClear = this.pstnCorrelationId;
6635
+ return _promise.default.all([this.isPhoneProvisioned(this.dialInDeviceStatus) ? _util2.default.disconnectPhoneAudio(this, this.dialInUrl) : _promise.default.resolve(), this.isPhoneProvisioned(this.dialOutDeviceStatus) ? _util2.default.disconnectPhoneAudio(this, this.dialOutUrl) : _promise.default.resolve()]).then(function () {
6636
+ if (_this40.pstnCorrelationId === correlationToClear) {
6637
+ _this40.pstnCorrelationId = undefined;
6638
+ }
6639
+ });
6566
6640
  }
6567
6641
 
6568
6642
  /**
@@ -6575,7 +6649,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6575
6649
  }, {
6576
6650
  key: "moveTo",
6577
6651
  value: function moveTo(resourceId) {
6578
- var _this40 = this;
6652
+ var _this41 = this;
6579
6653
  if (!resourceId) {
6580
6654
  throw new _parameter.default('Cannot move call without a resourceId.');
6581
6655
  }
@@ -6619,12 +6693,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6619
6693
  while (1) switch (_context21.prev = _context21.next) {
6620
6694
  case 0:
6621
6695
  _context21.prev = 0;
6622
- if (!(_this40.screenShareFloorState === ScreenShareFloorStatus.GRANTED)) {
6696
+ if (!(_this41.screenShareFloorState === ScreenShareFloorStatus.GRANTED)) {
6623
6697
  _context21.next = 4;
6624
6698
  break;
6625
6699
  }
6626
6700
  _context21.next = 4;
6627
- return _this40.releaseScreenShareFloor();
6701
+ return _this41.releaseScreenShareFloor();
6628
6702
  case 4:
6629
6703
  mediaSettings = {
6630
6704
  mediaDirection: {
@@ -6636,37 +6710,37 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6636
6710
  receiveShare: true
6637
6711
  }
6638
6712
  };
6639
- _this40.mediaProperties.setMediaDirection(mediaSettings.mediaDirection);
6640
- _this40.mediaProperties.unsetRemoteMedia();
6713
+ _this41.mediaProperties.setMediaDirection(mediaSettings.mediaDirection);
6714
+ _this41.mediaProperties.unsetRemoteMedia();
6641
6715
 
6642
6716
  // when a move to is intiated by the client , Locus delets the existing media node from the server as soon the device answers the meeting
6643
6717
  // once the device answers we close the old connection and create new media server connection with only share enabled
6644
- if (!_this40.statsAnalyzer) {
6718
+ if (!_this41.statsAnalyzer) {
6645
6719
  _context21.next = 10;
6646
6720
  break;
6647
6721
  }
6648
6722
  _context21.next = 10;
6649
- return _this40.statsAnalyzer.stopAnalyzer();
6723
+ return _this41.statsAnalyzer.stopAnalyzer();
6650
6724
  case 10:
6651
6725
  _context21.next = 12;
6652
- return _this40.closeRemoteStreams();
6726
+ return _this41.closeRemoteStreams();
6653
6727
  case 12:
6654
6728
  _context21.next = 14;
6655
- return _this40.closePeerConnections();
6729
+ return _this41.closePeerConnections();
6656
6730
  case 14:
6657
- _this40.cleanupLocalStreams();
6658
- _this40.unsetRemoteStreams();
6659
- _this40.unsetPeerConnections();
6660
- _this40.reconnectionManager.cleanUp();
6731
+ _this41.cleanupLocalStreams();
6732
+ _this41.unsetRemoteStreams();
6733
+ _this41.unsetPeerConnections();
6734
+ _this41.reconnectionManager.cleanUp();
6661
6735
  _context21.next = 20;
6662
- return _this40.addMedia({
6736
+ return _this41.addMedia({
6663
6737
  audioEnabled: false,
6664
6738
  videoEnabled: false,
6665
6739
  shareVideoEnabled: true
6666
6740
  });
6667
6741
  case 20:
6668
6742
  _metrics.default.sendBehavioralMetric(_constants2.default.MOVE_TO_SUCCESS);
6669
- _this40.isMoveToInProgress = false;
6743
+ _this41.isMoveToInProgress = false;
6670
6744
  _context21.next = 29;
6671
6745
  break;
6672
6746
  case 24:
@@ -6674,12 +6748,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6674
6748
  _context21.t0 = _context21["catch"](0);
6675
6749
  _loggerProxy.default.logger.error('Meeting:index#moveTo --> Failed to moveTo resourceId', _context21.t0);
6676
6750
  _metrics.default.sendBehavioralMetric(_constants2.default.MOVE_TO_FAILURE, {
6677
- correlation_id: _this40.correlationId,
6678
- locus_id: _this40.locusUrl.split('/').pop(),
6751
+ correlation_id: _this41.correlationId,
6752
+ locus_id: _this41.locusUrl.split('/').pop(),
6679
6753
  reason: _context21.t0.message,
6680
6754
  stack: _context21.t0.stack
6681
6755
  });
6682
- _this40.isMoveToInProgress = false;
6756
+ _this41.isMoveToInProgress = false;
6683
6757
  case 29:
6684
6758
  case "end":
6685
6759
  return _context21.stop();
@@ -6695,17 +6769,17 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6695
6769
  resourceId: resourceId,
6696
6770
  moveToResource: true
6697
6771
  }).then(function () {
6698
- _this40.meetingFiniteStateMachine.join();
6772
+ _this41.meetingFiniteStateMachine.join();
6699
6773
  }).catch(function (error) {
6700
- _this40.meetingFiniteStateMachine.fail(error);
6774
+ _this41.meetingFiniteStateMachine.fail(error);
6701
6775
  _metrics.default.sendBehavioralMetric(_constants2.default.MOVE_TO_FAILURE, {
6702
- correlation_id: _this40.correlationId,
6703
- locus_id: _this40.locusUrl.split('/').pop(),
6776
+ correlation_id: _this41.correlationId,
6777
+ locus_id: _this41.locusUrl.split('/').pop(),
6704
6778
  reason: error.message,
6705
6779
  stack: error.stack
6706
6780
  });
6707
6781
  _loggerProxy.default.logger.error('Meeting:index#moveTo --> Failed to moveTo resourceId', error);
6708
- _this40.isMoveToInProgress = false;
6782
+ _this41.isMoveToInProgress = false;
6709
6783
  return _promise.default.reject(error);
6710
6784
  });
6711
6785
  }
@@ -6720,7 +6794,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6720
6794
  }, {
6721
6795
  key: "moveFrom",
6722
6796
  value: function moveFrom(resourceId) {
6723
- var _this41 = this;
6797
+ var _this42 = this;
6724
6798
  // On moveFrom ask the developer to re capture it moveFrom then updateMedia
6725
6799
  if (!resourceId) {
6726
6800
  throw new _parameter.default('Cannot move call without a resourceId.');
@@ -6735,19 +6809,19 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6735
6809
  }
6736
6810
  });
6737
6811
  return _util2.default.joinMeetingOptions(this).then(function () {
6738
- return _util2.default.leaveMeeting(_this41, {
6812
+ return _util2.default.leaveMeeting(_this42, {
6739
6813
  resourceId: resourceId,
6740
6814
  correlationId: oldCorrelationId,
6741
6815
  moveMeeting: true
6742
6816
  }).then(function () {
6743
- _this41.resourceId = '';
6817
+ _this42.resourceId = '';
6744
6818
  _metrics.default.sendBehavioralMetric(_constants2.default.MOVE_FROM_SUCCESS);
6745
6819
  });
6746
6820
  }).catch(function (error) {
6747
- _this41.meetingFiniteStateMachine.fail(error);
6821
+ _this42.meetingFiniteStateMachine.fail(error);
6748
6822
  _metrics.default.sendBehavioralMetric(_constants2.default.MOVE_FROM_FAILURE, {
6749
- correlation_id: _this41.correlationId,
6750
- locus_id: _this41.locusUrl.split('/').pop(),
6823
+ correlation_id: _this42.correlationId,
6824
+ locus_id: _this42.locusUrl.split('/').pop(),
6751
6825
  reason: error.message,
6752
6826
  stack: error.stack
6753
6827
  });
@@ -6870,9 +6944,9 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6870
6944
  }, {
6871
6945
  key: "forwardEvent",
6872
6946
  value: function forwardEvent(eventEmitter, eventTypeToForward, meetingEventType) {
6873
- var _this42 = this;
6947
+ var _this43 = this;
6874
6948
  eventEmitter.on(eventTypeToForward, function (data) {
6875
- return _triggerProxy.default.trigger(_this42, {
6949
+ return _triggerProxy.default.trigger(_this43, {
6876
6950
  file: 'meetings',
6877
6951
  function: 'addMedia'
6878
6952
  }, meetingEventType, data);
@@ -7026,14 +7100,17 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7026
7100
  }, {
7027
7101
  key: "createStatsAnalyzer",
7028
7102
  value: function createStatsAnalyzer() {
7103
+ var _this44 = this;
7029
7104
  // @ts-ignore - config coming from registerPlugin
7030
7105
  if (this.config.stats.enableStatsAnalyzer) {
7031
7106
  // @ts-ignore - config coming from registerPlugin
7032
7107
  this.networkQualityMonitor = new _internalMediaCore.NetworkQualityMonitor(this.config.stats);
7108
+ this.statsMonitor = new _internalMediaCore.StatsMonitor();
7033
7109
  this.statsAnalyzer = new _internalMediaCore.StatsAnalyzer({
7034
7110
  // @ts-ignore - config coming from registerPlugin
7035
7111
  config: this.config.stats,
7036
7112
  networkQualityMonitor: this.networkQualityMonitor,
7113
+ statsMonitor: this.statsMonitor,
7037
7114
  isMultistream: this.isMultistream
7038
7115
  });
7039
7116
  this.shareCAEventSentStatus = {
@@ -7044,6 +7121,22 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7044
7121
  };
7045
7122
  this.setupStatsAnalyzerEventHandlers();
7046
7123
  this.networkQualityMonitor.on(_internalMediaCore.NetworkQualityEventNames.NETWORK_QUALITY, this.sendNetworkQualityEvent.bind(this));
7124
+ this.statsMonitor.on(_internalMediaCore.StatsMonitorEventNames.INBOUND_AUDIO_ISSUE, function (data) {
7125
+ // Before forwarding any inbound audio issues to the app, make sure that we have at least one other
7126
+ // participant in the meeting with unmuted audio.
7127
+ // We don't check this.mediaProperties.mediaDirection here, because that's already handled in statsAnalyzer,
7128
+ // so we won't get this event if we are not setup to receive any audio
7129
+ var atLeastOneUnmutedOtherMember = (0, _values.default)(_this44.members.membersCollection.getAll()).find(function (member) {
7130
+ return !member.isSelf && !member.isPairedWithSelf && !member.isAudioMuted;
7131
+ });
7132
+ if (atLeastOneUnmutedOtherMember) {
7133
+ _this44.mediaProperties.sendMediaIssueMetric('inbound_audio', data.issueSubType, _this44.correlationId);
7134
+ _triggerProxy.default.trigger(_this44, {
7135
+ file: 'meeting/index',
7136
+ function: 'createStatsAnalyzer'
7137
+ }, _constants.EVENT_TRIGGERS.MEDIA_INBOUND_AUDIO_ISSUE_DETECTED, data);
7138
+ }
7139
+ });
7047
7140
  }
7048
7141
  }
7049
7142
 
@@ -7058,7 +7151,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7058
7151
  key: "waitForRemoteSDPAnswer",
7059
7152
  value: (function () {
7060
7153
  var _waitForRemoteSDPAnswer = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee25() {
7061
- var _this43 = this;
7154
+ var _this45 = this;
7062
7155
  var LOG_HEADER, deferSDPAnswer;
7063
7156
  return _regenerator.default.wrap(function _callee25$(_context25) {
7064
7157
  while (1) switch (_context25.prev = _context25.next) {
@@ -7077,18 +7170,18 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7077
7170
  var error = new Error('Timed out waiting for REMOTE SDP ANSWER');
7078
7171
 
7079
7172
  // @ts-ignore
7080
- _this43.webex.internal.newMetrics.submitClientEvent({
7173
+ _this45.webex.internal.newMetrics.submitClientEvent({
7081
7174
  name: 'client.media-engine.remote-sdp-received',
7082
7175
  payload: {
7083
7176
  canProceed: false,
7084
7177
  errors: [
7085
7178
  // @ts-ignore
7086
- _this43.webex.internal.newMetrics.callDiagnosticMetrics.getErrorPayloadForClientErrorCode({
7179
+ _this45.webex.internal.newMetrics.callDiagnosticMetrics.getErrorPayloadForClientErrorCode({
7087
7180
  clientErrorCode: _internalPluginMetrics.CALL_DIAGNOSTIC_CONFIG.MISSING_ROAP_ANSWER_CLIENT_CODE
7088
7181
  })]
7089
7182
  },
7090
7183
  options: {
7091
- meetingId: _this43.id,
7184
+ meetingId: _this45.id,
7092
7185
  rawError: error
7093
7186
  }
7094
7187
  });
@@ -7397,6 +7490,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7397
7490
  key: "cleanUpOnAddMediaFailure",
7398
7491
  value: (function () {
7399
7492
  var _cleanUpOnAddMediaFailure = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee31() {
7493
+ var _this$networkQualityM, _this$statsMonitor;
7400
7494
  return _regenerator.default.wrap(function _callee31$(_context31) {
7401
7495
  while (1) switch (_context31.prev = _context31.next) {
7402
7496
  case 0:
@@ -7408,19 +7502,23 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7408
7502
  return this.statsAnalyzer.stopAnalyzer();
7409
7503
  case 3:
7410
7504
  this.statsAnalyzer = null;
7505
+ (_this$networkQualityM = this.networkQualityMonitor) === null || _this$networkQualityM === void 0 ? void 0 : _this$networkQualityM.removeAllListeners();
7506
+ this.networkQualityMonitor = null;
7507
+ (_this$statsMonitor = this.statsMonitor) === null || _this$statsMonitor === void 0 ? void 0 : _this$statsMonitor.removeAllListeners();
7508
+ this.statsMonitor = null;
7411
7509
 
7412
7510
  // when media fails, we want to upload a webrtc dump to see whats going on
7413
7511
  // this function is async, but returns once the stats have been gathered
7414
- _context31.next = 6;
7512
+ _context31.next = 10;
7415
7513
  return this.forceSendStatsReport({
7416
7514
  callFrom: 'addMedia'
7417
7515
  });
7418
- case 6:
7516
+ case 10:
7419
7517
  if (this.mediaProperties.webrtcMediaConnection) {
7420
7518
  this.closePeerConnections();
7421
7519
  this.unsetPeerConnections();
7422
7520
  }
7423
- case 7:
7521
+ case 11:
7424
7522
  case "end":
7425
7523
  return _context31.stop();
7426
7524
  }
@@ -7443,7 +7541,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7443
7541
  key: "downgradeFromMultistreamToTranscoded",
7444
7542
  value: (function () {
7445
7543
  var _downgradeFromMultistreamToTranscoded = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee32() {
7446
- var _this$locusMediaReque2;
7544
+ var _this$networkQualityM2, _this$statsMonitor2, _this$locusMediaReque2;
7447
7545
  return _regenerator.default.wrap(function _callee32$(_context32) {
7448
7546
  while (1) switch (_context32.prev = _context32.next) {
7449
7547
  case 0:
@@ -7455,6 +7553,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7455
7553
  return this.statsAnalyzer.stopAnalyzer();
7456
7554
  case 3:
7457
7555
  this.statsAnalyzer = null;
7556
+ (_this$networkQualityM2 = this.networkQualityMonitor) === null || _this$networkQualityM2 === void 0 ? void 0 : _this$networkQualityM2.removeAllListeners();
7557
+ this.networkQualityMonitor = null;
7558
+ (_this$statsMonitor2 = this.statsMonitor) === null || _this$statsMonitor2 === void 0 ? void 0 : _this$statsMonitor2.removeAllListeners();
7559
+ this.statsMonitor = null;
7458
7560
  this.isMultistream = false;
7459
7561
  if (this.mediaProperties.webrtcMediaConnection) {
7460
7562
  // close peer connection, but don't reset mute state information, because we will want to use it on the retry
@@ -7463,7 +7565,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7463
7565
  }
7464
7566
  (_this$locusMediaReque2 = this.locusMediaRequest) === null || _this$locusMediaReque2 === void 0 ? void 0 : _this$locusMediaReque2.downgradeFromMultistreamToTranscoded();
7465
7567
  this.createStatsAnalyzer();
7466
- case 8:
7568
+ case 12:
7467
7569
  case "end":
7468
7570
  return _context32.stop();
7469
7571
  }
@@ -7595,10 +7697,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7595
7697
  }, {
7596
7698
  key: "addMedia",
7597
7699
  value: function addMedia() {
7598
- var _this44 = this;
7700
+ var _this46 = this;
7599
7701
  var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
7600
7702
  return this.addMediaInternal(function () {
7601
- return _this44.turnServerUsed ? 'JOIN_MEETING_FINAL' : 'JOIN_MEETING_RETRY';
7703
+ return _this46.turnServerUsed ? 'JOIN_MEETING_FINAL' : 'JOIN_MEETING_RETRY';
7602
7704
  }, undefined, false, options);
7603
7705
  }
7604
7706
 
@@ -7641,6 +7743,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7641
7743
  receiveVideo,
7642
7744
  sendAudio,
7643
7745
  receiveAudio,
7746
+ ipver,
7644
7747
  _this$remoteMediaMana,
7645
7748
  _yield$this$mediaProp,
7646
7749
  connectionType,
@@ -7705,14 +7808,16 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7705
7808
  receiveAudio = audioEnabled && (rawReceiveAudio !== null && rawReceiveAudio !== void 0 ? rawReceiveAudio : true);
7706
7809
  this.allowMediaInLobby = options === null || options === void 0 ? void 0 : options.allowMediaInLobby;
7707
7810
 
7811
+ // @ts-ignore
7812
+ ipver = _util2.default.getIpVersion(this.webex); // used just for metrics
7708
7813
  // If the user is unjoined or guest waiting in lobby dont allow the user to addMedia
7709
7814
  // @ts-ignore - isUserUnadmitted coming from SelfUtil
7710
7815
  if (!(this.isUserUnadmitted && !this.wirelessShare && !this.allowMediaInLobby)) {
7711
- _context35.next = 19;
7816
+ _context35.next = 20;
7712
7817
  break;
7713
7818
  }
7714
7819
  throw new _webexErrors.UserInLobbyError();
7715
- case 19:
7820
+ case 20:
7716
7821
  // @ts-ignore
7717
7822
  this.webex.internal.newMetrics.submitClientEvent({
7718
7823
  name: 'client.media.capabilities',
@@ -7752,63 +7857,64 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7752
7857
  this.audio = (0, _muteState.createMuteState)(_constants.AUDIO, this, audioEnabled);
7753
7858
  this.video = (0, _muteState.createMuteState)(_constants.VIDEO, this, videoEnabled);
7754
7859
  this.brbState = (0, _brbState.createBrbState)(this, false);
7755
- _context35.prev = 24;
7756
- _context35.next = 27;
7860
+ _context35.prev = 25;
7861
+ _context35.next = 28;
7757
7862
  return this.setUpLocalStreamReferences(localStreams);
7758
- case 27:
7863
+ case 28:
7759
7864
  this.setMercuryListener();
7760
7865
  this.createStatsAnalyzer();
7761
- _context35.prev = 29;
7762
- _context35.next = 32;
7866
+ _context35.prev = 30;
7867
+ _context35.next = 33;
7763
7868
  return this.establishMediaConnection(remoteMediaManagerConfig, bundlePolicy, forceTurnDiscovery, turnServerInfo);
7764
- case 32:
7765
- _context35.next = 45;
7869
+ case 33:
7870
+ _context35.next = 46;
7766
7871
  break;
7767
- case 34:
7768
- _context35.prev = 34;
7769
- _context35.t0 = _context35["catch"](29);
7872
+ case 35:
7873
+ _context35.prev = 35;
7874
+ _context35.t0 = _context35["catch"](30);
7770
7875
  if (!(_context35.t0 instanceof _multistreamNotSupportedError.default)) {
7771
- _context35.next = 44;
7876
+ _context35.next = 45;
7772
7877
  break;
7773
7878
  }
7774
7879
  _loggerProxy.default.logger.warn("".concat(LOG_HEADER, " we asked for multistream backend (Homer), but got transcoded backend, recreating media connection..."));
7775
- _context35.next = 40;
7880
+ _context35.next = 41;
7776
7881
  return this.downgradeFromMultistreamToTranscoded();
7777
- case 40:
7778
- _context35.next = 42;
7882
+ case 41:
7883
+ _context35.next = 43;
7779
7884
  return this.establishMediaConnection(remoteMediaManagerConfig, bundlePolicy, true, undefined);
7780
- case 42:
7781
- _context35.next = 45;
7885
+ case 43:
7886
+ _context35.next = 46;
7782
7887
  break;
7783
- case 44:
7784
- throw _context35.t0;
7785
7888
  case 45:
7889
+ throw _context35.t0;
7890
+ case 46:
7786
7891
  _loggerProxy.default.logger.info("".concat(LOG_HEADER, " media connected, finalizing..."));
7787
7892
  if (!this.mediaProperties.hasLocalShareStream()) {
7788
- _context35.next = 49;
7893
+ _context35.next = 50;
7789
7894
  break;
7790
7895
  }
7791
- _context35.next = 49;
7896
+ _context35.next = 50;
7792
7897
  return this.enqueueScreenShareFloorRequest();
7793
- case 49:
7794
- _context35.next = 51;
7898
+ case 50:
7899
+ _context35.next = 52;
7795
7900
  return this.mediaProperties.getCurrentConnectionInfo();
7796
- case 51:
7901
+ case 52:
7797
7902
  _yield$this$mediaProp = _context35.sent;
7798
7903
  connectionType = _yield$this$mediaProp.connectionType;
7799
7904
  ipVersion = _yield$this$mediaProp.ipVersion;
7800
7905
  selectedCandidatePairChanges = _yield$this$mediaProp.selectedCandidatePairChanges;
7801
7906
  numTransports = _yield$this$mediaProp.numTransports;
7802
7907
  iceCandidateErrors = Object.fromEntries(this.iceCandidateErrors);
7803
- _context35.next = 59;
7908
+ _context35.next = 60;
7804
7909
  return this.getMediaReachabilityMetricFields();
7805
- case 59:
7910
+ case 60:
7806
7911
  reachabilityMetrics = _context35.sent;
7807
7912
  _metrics.default.sendBehavioralMetric(_constants2.default.ADD_MEDIA_SUCCESS, _objectSpread(_objectSpread(_objectSpread({
7808
7913
  correlation_id: this.correlationId,
7809
7914
  locus_id: this.locusUrl.split('/').pop(),
7810
7915
  connectionType: connectionType,
7811
7916
  ipVersion: ipVersion,
7917
+ ipver: ipver,
7812
7918
  selectedCandidatePairChanges: selectedCandidatePairChanges,
7813
7919
  numTransports: numTransports,
7814
7920
  isMultistream: this.isMultistream,
@@ -7832,21 +7938,21 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7832
7938
  // We can log ReceiveSlot SSRCs only after the SDP exchange, so doing it here:
7833
7939
  (_this$remoteMediaMana = this.remoteMediaManager) === null || _this$remoteMediaMana === void 0 ? void 0 : _this$remoteMediaMana.logAllReceiveSlots();
7834
7940
  this.startPeriodicLogUpload();
7835
- _context35.next = 85;
7941
+ _context35.next = 86;
7836
7942
  break;
7837
- case 67:
7838
- _context35.prev = 67;
7839
- _context35.t1 = _context35["catch"](24);
7943
+ case 68:
7944
+ _context35.prev = 68;
7945
+ _context35.t1 = _context35["catch"](25);
7840
7946
  _loggerProxy.default.logger.error("".concat(LOG_HEADER, " failed to establish media connection: "), _context35.t1);
7841
7947
 
7842
7948
  // @ts-ignore
7843
- _context35.next = 72;
7949
+ _context35.next = 73;
7844
7950
  return this.getMediaReachabilityMetricFields();
7845
- case 72:
7951
+ case 73:
7846
7952
  _reachabilityMetrics = _context35.sent;
7847
- _context35.next = 75;
7953
+ _context35.next = 76;
7848
7954
  return this.mediaProperties.getCurrentConnectionInfo();
7849
- case 75:
7955
+ case 76:
7850
7956
  _yield$this$mediaProp2 = _context35.sent;
7851
7957
  _selectedCandidatePairChanges = _yield$this$mediaProp2.selectedCandidatePairChanges;
7852
7958
  _numTransports = _yield$this$mediaProp2.numTransports;
@@ -7868,11 +7974,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7868
7974
  connectionState: ((_this$mediaProperties22 = this.mediaProperties.webrtcMediaConnection) === null || _this$mediaProperties22 === void 0 ? void 0 : (_this$mediaProperties23 = _this$mediaProperties22.multistreamConnection) === null || _this$mediaProperties23 === void 0 ? void 0 : (_this$mediaProperties24 = _this$mediaProperties23.pc) === null || _this$mediaProperties24 === void 0 ? void 0 : (_this$mediaProperties25 = _this$mediaProperties24.pc) === null || _this$mediaProperties25 === void 0 ? void 0 : _this$mediaProperties25.connectionState) || ((_this$mediaProperties26 = this.mediaProperties.webrtcMediaConnection) === null || _this$mediaProperties26 === void 0 ? void 0 : (_this$mediaProperties27 = _this$mediaProperties26.mediaConnection) === null || _this$mediaProperties27 === void 0 ? void 0 : (_this$mediaProperties28 = _this$mediaProperties27.pc) === null || _this$mediaProperties28 === void 0 ? void 0 : _this$mediaProperties28.connectionState) || 'unknown',
7869
7975
  iceConnectionState: ((_this$mediaProperties29 = this.mediaProperties.webrtcMediaConnection) === null || _this$mediaProperties29 === void 0 ? void 0 : (_this$mediaProperties30 = _this$mediaProperties29.multistreamConnection) === null || _this$mediaProperties30 === void 0 ? void 0 : (_this$mediaProperties31 = _this$mediaProperties30.pc) === null || _this$mediaProperties31 === void 0 ? void 0 : (_this$mediaProperties32 = _this$mediaProperties31.pc) === null || _this$mediaProperties32 === void 0 ? void 0 : _this$mediaProperties32.iceConnectionState) || ((_this$mediaProperties33 = this.mediaProperties.webrtcMediaConnection) === null || _this$mediaProperties33 === void 0 ? void 0 : (_this$mediaProperties34 = _this$mediaProperties33.mediaConnection) === null || _this$mediaProperties34 === void 0 ? void 0 : (_this$mediaProperties35 = _this$mediaProperties34.pc) === null || _this$mediaProperties35 === void 0 ? void 0 : _this$mediaProperties35.iceConnectionState) || 'unknown'
7870
7976
  }, _reachabilityMetrics), _iceCandidateErrors), {}, {
7871
- iceCandidatesCount: this.iceCandidatesCount
7977
+ iceCandidatesCount: this.iceCandidatesCount,
7978
+ ipver: ipver
7872
7979
  }));
7873
- _context35.next = 82;
7980
+ _context35.next = 83;
7874
7981
  return this.cleanUpOnAddMediaFailure();
7875
- case 82:
7982
+ case 83:
7876
7983
  // Upload logs on error while adding media
7877
7984
  _triggerProxy.default.trigger(this, {
7878
7985
  file: 'meeting/index',
@@ -7884,15 +7991,15 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7884
7991
  });
7885
7992
  }
7886
7993
  throw _context35.t1;
7887
- case 85:
7888
- _context35.prev = 85;
7994
+ case 86:
7995
+ _context35.prev = 86;
7889
7996
  this.addMediaData.icePhaseCallback = DEFAULT_ICE_PHASE_CALLBACK;
7890
- return _context35.finish(85);
7891
- case 88:
7997
+ return _context35.finish(86);
7998
+ case 89:
7892
7999
  case "end":
7893
8000
  return _context35.stop();
7894
8001
  }
7895
- }, _callee35, this, [[24, 67, 85, 88], [29, 34]]);
8002
+ }, _callee35, this, [[25, 68, 86, 89], [30, 35]]);
7896
8003
  }));
7897
8004
  function addMediaInternal(_x33, _x34, _x35) {
7898
8005
  return _addMediaInternal.apply(this, arguments);
@@ -7924,7 +8031,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7924
8031
  * @memberof Meeting
7925
8032
  */
7926
8033
  function enqueueMediaUpdate(mediaUpdateType) {
7927
- var _this45 = this;
8034
+ var _this47 = this;
7928
8035
  var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
7929
8036
  var canUpdateMediaNow = this.canUpdateMedia();
7930
8037
  return new _promise.default(function (resolve, reject) {
@@ -7935,9 +8042,9 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7935
8042
  options: options
7936
8043
  };
7937
8044
  _loggerProxy.default.logger.log("Meeting:index#enqueueMediaUpdate --> enqueuing media update type=".concat(mediaUpdateType));
7938
- _this45.queuedMediaUpdates.push(queueItem);
8045
+ _this47.queuedMediaUpdates.push(queueItem);
7939
8046
  if (canUpdateMediaNow) {
7940
- _this45.processNextQueuedMediaUpdate();
8047
+ _this47.processNextQueuedMediaUpdate();
7941
8048
  }
7942
8049
  });
7943
8050
  }
@@ -8042,7 +8149,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8042
8149
  }, {
8043
8150
  key: "acknowledge",
8044
8151
  value: function acknowledge(type) {
8045
- var _this46 = this;
8152
+ var _this48 = this;
8046
8153
  if (!type) {
8047
8154
  return _promise.default.reject(new _parameter.default('Type must be set to acknowledge the meeting.'));
8048
8155
  }
@@ -8054,12 +8161,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8054
8161
  }).then(function (response) {
8055
8162
  return _promise.default.resolve(response);
8056
8163
  }).then(function (response) {
8057
- _this46.meetingFiniteStateMachine.ring(type);
8164
+ _this48.meetingFiniteStateMachine.ring(type);
8058
8165
  // @ts-ignore
8059
- _this46.webex.internal.newMetrics.submitClientEvent({
8166
+ _this48.webex.internal.newMetrics.submitClientEvent({
8060
8167
  name: 'client.alert.displayed',
8061
8168
  options: {
8062
- meetingId: _this46.id
8169
+ meetingId: _this48.id
8063
8170
  }
8064
8171
  });
8065
8172
  return _promise.default.resolve({
@@ -8084,12 +8191,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8084
8191
  }, {
8085
8192
  key: "decline",
8086
8193
  value: function decline(reason) {
8087
- var _this47 = this;
8194
+ var _this49 = this;
8088
8195
  return _util2.default.declineMeeting(this, reason).then(function (decline) {
8089
- _this47.meetingFiniteStateMachine.decline();
8196
+ _this49.meetingFiniteStateMachine.decline();
8090
8197
  return _promise.default.resolve(decline);
8091
8198
  }).catch(function (error) {
8092
- _this47.meetingFiniteStateMachine.fail(error);
8199
+ _this49.meetingFiniteStateMachine.fail(error);
8093
8200
  return _promise.default.reject(error);
8094
8201
  });
8095
8202
  }
@@ -8140,7 +8247,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8140
8247
  }, {
8141
8248
  key: "leave",
8142
8249
  value: function leave() {
8143
- var _this48 = this;
8250
+ var _this50 = this;
8144
8251
  var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
8145
8252
  var leaveReason = options.reason || _constants.MEETING_REMOVED_REASON.CLIENT_LEAVE_REQUEST;
8146
8253
 
@@ -8152,7 +8259,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8152
8259
  var payload = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
8153
8260
  return (
8154
8261
  // @ts-ignore
8155
- _this48.webex.internal.newMetrics.submitClientEvent({
8262
+ _this50.webex.internal.newMetrics.submitClientEvent({
8156
8263
  name: 'client.call.leave',
8157
8264
  payload: _objectSpread({
8158
8265
  trigger: 'user-interaction',
@@ -8160,7 +8267,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8160
8267
  leaveReason: options.clientEventLeaveReason
8161
8268
  }, payload),
8162
8269
  options: {
8163
- meetingId: _this48.id
8270
+ meetingId: _this50.id
8164
8271
  }
8165
8272
  })
8166
8273
  );
@@ -8169,24 +8276,24 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8169
8276
  return _util2.default.leaveMeeting(this, options).then(function (leave) {
8170
8277
  // CA team recommends submitting this *after* locus /leave
8171
8278
  submitLeaveMetric();
8172
- _this48.meetingFiniteStateMachine.leave();
8173
- _this48.clearMeetingData();
8279
+ _this50.meetingFiniteStateMachine.leave();
8280
+ _this50.clearMeetingData();
8174
8281
 
8175
8282
  // upload logs on leave irrespective of meeting delete
8176
- _triggerProxy.default.trigger(_this48, {
8283
+ _triggerProxy.default.trigger(_this50, {
8177
8284
  file: 'meeting/index',
8178
8285
  function: 'leave'
8179
- }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this48);
8286
+ }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this50);
8180
8287
 
8181
8288
  // TODO: more testing before we remove this code, we are not sure the scenarios for destroy here
8182
- if (_this48.wirelessShare || _this48.guest) {
8289
+ if (_this50.wirelessShare || _this50.guest) {
8183
8290
  // If screen sharing clean the meeting object
8184
- _triggerProxy.default.trigger(_this48, {
8291
+ _triggerProxy.default.trigger(_this50, {
8185
8292
  file: 'meeting/index',
8186
8293
  function: 'leave'
8187
8294
  }, _constants.EVENTS.DESTROY_MEETING, {
8188
8295
  reason: options.reason,
8189
- meetingId: _this48.id
8296
+ meetingId: _this50.id
8190
8297
  });
8191
8298
  }
8192
8299
  _loggerProxy.default.logger.log('Meeting:index#leave --> LEAVE REASON ', leaveReason);
@@ -8203,16 +8310,16 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8203
8310
  shownToUser: false
8204
8311
  }]
8205
8312
  });
8206
- _this48.meetingFiniteStateMachine.fail(error);
8313
+ _this50.meetingFiniteStateMachine.fail(error);
8207
8314
  _loggerProxy.default.logger.error('Meeting:index#leave --> Failed to leave ', error);
8208
8315
  // upload logs on leave irrespective of meeting delete
8209
- _triggerProxy.default.trigger(_this48, {
8316
+ _triggerProxy.default.trigger(_this50, {
8210
8317
  file: 'meeting/index',
8211
8318
  function: 'leave'
8212
- }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this48);
8319
+ }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this50);
8213
8320
  _metrics.default.sendBehavioralMetric(_constants2.default.MEETING_LEAVE_FAILURE, {
8214
- correlation_id: _this48.correlationId,
8215
- locus_id: _this48.locusUrl.split('/').pop(),
8321
+ correlation_id: _this50.correlationId,
8322
+ locus_id: _this50.locusUrl.split('/').pop(),
8216
8323
  reason: error.message,
8217
8324
  stack: error.stack,
8218
8325
  code: error.code
@@ -8232,7 +8339,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8232
8339
  }, {
8233
8340
  key: "startWhiteboardShare",
8234
8341
  value: function startWhiteboardShare(channelUrl, resourceToken) {
8235
- var _this49 = this;
8342
+ var _this51 = this;
8236
8343
  var whiteboard = this.locusInfo.mediaShares.find(function (element) {
8237
8344
  return element.name === 'whiteboard';
8238
8345
  });
@@ -8240,6 +8347,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8240
8347
  return _promise.default.reject(new _parameter.default('Cannot share without channelUrl.'));
8241
8348
  }
8242
8349
  if (whiteboard) {
8350
+ // @ts-ignore
8351
+ this.webex.internal.newMetrics.callDiagnosticLatencies.saveTimestamp({
8352
+ key: 'internal.client.share.initiated'
8353
+ });
8243
8354
  // @ts-ignore
8244
8355
  this.webex.internal.newMetrics.submitClientEvent({
8245
8356
  name: 'client.share.initiated',
@@ -8261,13 +8372,13 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8261
8372
  body.resourceToken = resourceToken;
8262
8373
  }
8263
8374
  return this.meetingRequest.changeMeetingFloor(body).then(function () {
8264
- _this49.screenShareFloorState = ScreenShareFloorStatus.RELEASED;
8375
+ _this51.screenShareFloorState = ScreenShareFloorStatus.RELEASED;
8265
8376
  return _promise.default.resolve();
8266
8377
  }).catch(function (error) {
8267
8378
  _loggerProxy.default.logger.error('Meeting:index#startWhiteboardShare --> Error ', error);
8268
8379
  _metrics.default.sendBehavioralMetric(_constants2.default.MEETING_START_WHITEBOARD_SHARE_FAILURE, {
8269
- correlation_id: _this49.correlationId,
8270
- locus_id: _this49.locusUrl.split('/').pop(),
8380
+ correlation_id: _this51.correlationId,
8381
+ locus_id: _this51.locusUrl.split('/').pop(),
8271
8382
  reason: error.message,
8272
8383
  stack: error.stack,
8273
8384
  board: {
@@ -8290,16 +8401,22 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8290
8401
  }, {
8291
8402
  key: "stopWhiteboardShare",
8292
8403
  value: function stopWhiteboardShare(channelUrl) {
8293
- var _this50 = this;
8404
+ var _this52 = this;
8294
8405
  var whiteboard = this.locusInfo.mediaShares.find(function (element) {
8295
8406
  return element.name === 'whiteboard';
8296
8407
  });
8297
8408
  if (whiteboard) {
8409
+ // @ts-ignore
8410
+ this.webex.internal.newMetrics.callDiagnosticLatencies.saveTimestamp({
8411
+ key: 'internal.client.share.stopped'
8412
+ });
8298
8413
  // @ts-ignore
8299
8414
  this.webex.internal.newMetrics.submitClientEvent({
8300
8415
  name: 'client.share.stopped',
8301
8416
  payload: {
8302
- mediaType: 'whiteboard'
8417
+ mediaType: 'whiteboard',
8418
+ // @ts-ignore
8419
+ shareDuration: this.webex.internal.newMetrics.callDiagnosticLatencies.getShareDuration()
8303
8420
  },
8304
8421
  options: {
8305
8422
  meetingId: this.id
@@ -8313,8 +8430,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8313
8430
  }).catch(function (error) {
8314
8431
  _loggerProxy.default.logger.error('Meeting:index#stopWhiteboardShare --> Error ', error);
8315
8432
  _metrics.default.sendBehavioralMetric(_constants2.default.MEETING_STOP_WHITEBOARD_SHARE_FAILURE, {
8316
- correlation_id: _this50.correlationId,
8317
- locus_id: _this50.locusUrl.split('/').pop(),
8433
+ correlation_id: _this52.correlationId,
8434
+ locus_id: _this52.locusUrl.split('/').pop(),
8318
8435
  reason: error.message,
8319
8436
  stack: error.stack,
8320
8437
  board: {
@@ -8336,7 +8453,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8336
8453
  }, {
8337
8454
  key: "requestScreenShareFloor",
8338
8455
  value: function requestScreenShareFloor() {
8339
- var _this51 = this;
8456
+ var _this53 = this;
8340
8457
  if (!this.mediaProperties.hasLocalShareStream() || !this.mediaProperties.mediaDirection.sendShare) {
8341
8458
  _loggerProxy.default.logger.log("Meeting:index#requestScreenShareFloor --> NOT requesting floor, because we don't have the share stream anymore (shareStream=".concat(this.mediaProperties.shareVideoStream ? 'yes' : 'no', ", sendShare=").concat(this.mediaProperties.mediaDirection.sendShare, ")"));
8342
8459
  this.screenShareFloorState = ScreenShareFloorStatus.RELEASED;
@@ -8367,34 +8484,34 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8367
8484
  resourceUrl: this.resourceUrl,
8368
8485
  shareInstanceId: this.localShareInstanceId
8369
8486
  }).then(function () {
8370
- _this51.screenShareFloorState = ScreenShareFloorStatus.GRANTED;
8487
+ _this53.screenShareFloorState = ScreenShareFloorStatus.GRANTED;
8371
8488
  _metrics.default.sendBehavioralMetric(_constants2.default.MEETING_SHARE_SUCCESS, {
8372
- correlation_id: _this51.correlationId,
8373
- locus_id: _this51.locusUrl.split('/').pop()
8489
+ correlation_id: _this53.correlationId,
8490
+ locus_id: _this53.locusUrl.split('/').pop()
8374
8491
  });
8375
8492
  return _promise.default.resolve();
8376
8493
  }).catch(function (error) {
8377
8494
  _loggerProxy.default.logger.error('Meeting:index#share --> Error ', error);
8378
8495
  _metrics.default.sendBehavioralMetric(_constants2.default.MEETING_SHARE_FAILURE, {
8379
- correlation_id: _this51.correlationId,
8380
- locus_id: _this51.locusUrl.split('/').pop(),
8496
+ correlation_id: _this53.correlationId,
8497
+ locus_id: _this53.locusUrl.split('/').pop(),
8381
8498
  reason: error.message,
8382
8499
  stack: error.stack
8383
8500
  });
8384
8501
 
8385
8502
  // @ts-ignore
8386
- _this51.webex.internal.newMetrics.submitClientEvent({
8503
+ _this53.webex.internal.newMetrics.submitClientEvent({
8387
8504
  name: 'client.share.floor-granted.local',
8388
8505
  payload: {
8389
8506
  mediaType: 'share',
8390
8507
  errors: _util2.default.getChangeMeetingFloorErrorPayload(error.message),
8391
- shareInstanceId: _this51.localShareInstanceId
8508
+ shareInstanceId: _this53.localShareInstanceId
8392
8509
  },
8393
8510
  options: {
8394
- meetingId: _this51.id
8511
+ meetingId: _this53.id
8395
8512
  }
8396
8513
  });
8397
- _this51.screenShareFloorState = ScreenShareFloorStatus.RELEASED;
8514
+ _this53.screenShareFloorState = ScreenShareFloorStatus.RELEASED;
8398
8515
  return _promise.default.reject(error);
8399
8516
  });
8400
8517
  }
@@ -8417,10 +8534,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8417
8534
  }, {
8418
8535
  key: "requestScreenShareFloorIfPending",
8419
8536
  value: function requestScreenShareFloorIfPending() {
8420
- var _this52 = this;
8537
+ var _this54 = this;
8421
8538
  if (this.floorGrantPending && this.state === _constants.MEETING_STATE.STATES.JOINED) {
8422
8539
  this.requestScreenShareFloor().then(function () {
8423
- _this52.floorGrantPending = false;
8540
+ _this54.floorGrantPending = false;
8424
8541
  });
8425
8542
  }
8426
8543
  }
@@ -8434,7 +8551,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8434
8551
  }, {
8435
8552
  key: "releaseScreenShareFloor",
8436
8553
  value: function releaseScreenShareFloor() {
8437
- var _this53 = this;
8554
+ var _this55 = this;
8438
8555
  var content = this.locusInfo.mediaShares.find(function (element) {
8439
8556
  return element.name === _constants.CONTENT;
8440
8557
  });
@@ -8445,11 +8562,17 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8445
8562
  if (content) {
8446
8563
  var _content$floor;
8447
8564
  // @ts-ignore
8565
+ this.webex.internal.newMetrics.callDiagnosticLatencies.saveTimestamp({
8566
+ key: 'internal.client.share.stopped'
8567
+ });
8568
+ // @ts-ignore
8448
8569
  this.webex.internal.newMetrics.submitClientEvent({
8449
8570
  name: 'client.share.stopped',
8450
8571
  payload: {
8451
8572
  mediaType: 'share',
8452
- shareInstanceId: this.localShareInstanceId
8573
+ shareInstanceId: this.localShareInstanceId,
8574
+ // @ts-ignore
8575
+ shareDuration: this.webex.internal.newMetrics.callDiagnosticLatencies.getShareDuration()
8453
8576
  },
8454
8577
  options: {
8455
8578
  meetingId: this.id
@@ -8469,8 +8592,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8469
8592
  }).catch(function (error) {
8470
8593
  _loggerProxy.default.logger.error('Meeting:index#releaseScreenShareFloor --> Error ', error);
8471
8594
  _metrics.default.sendBehavioralMetric(_constants2.default.STOP_FLOOR_REQUEST_FAILURE, {
8472
- correlation_id: _this53.correlationId,
8473
- locus_id: _this53.locusUrl.split('/').pop(),
8595
+ correlation_id: _this55.correlationId,
8596
+ locus_id: _this55.locusUrl.split('/').pop(),
8474
8597
  reason: error.message,
8475
8598
  stack: error.stack
8476
8599
  });
@@ -8650,7 +8773,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8650
8773
  }, {
8651
8774
  key: "changeVideoLayout",
8652
8775
  value: function changeVideoLayout(layoutType) {
8653
- var _this54 = this;
8776
+ var _this56 = this;
8654
8777
  var renderInfo = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
8655
8778
  var main = renderInfo.main,
8656
8779
  content = renderInfo.content;
@@ -8704,7 +8827,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8704
8827
  }
8705
8828
  this.lastVideoLayoutInfo = (0, _lodash.cloneDeep)(layoutInfo);
8706
8829
  this.locusInfo.once(_constants.LOCUSINFO.EVENTS.CONTROLS_MEETING_LAYOUT_UPDATED, function (envelope) {
8707
- _triggerProxy.default.trigger(_this54, {
8830
+ _triggerProxy.default.trigger(_this56, {
8708
8831
  file: 'meeting/index',
8709
8832
  function: 'changeVideoLayout'
8710
8833
  }, _constants.EVENT_TRIGGERS.MEETING_CONTROLS_LAYOUT_UPDATE, {
@@ -8820,7 +8943,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8820
8943
  }, {
8821
8944
  key: "endMeetingForAll",
8822
8945
  value: function endMeetingForAll() {
8823
- var _this55 = this;
8946
+ var _this57 = this;
8824
8947
  // @ts-ignore
8825
8948
  this.webex.internal.newMetrics.submitClientEvent({
8826
8949
  name: 'client.call.leave',
@@ -8838,25 +8961,25 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8838
8961
  locus_id: this.locusId
8839
8962
  });
8840
8963
  return _util2.default.endMeetingForAll(this).then(function (end) {
8841
- _this55.meetingFiniteStateMachine.end();
8842
- _this55.clearMeetingData();
8964
+ _this57.meetingFiniteStateMachine.end();
8965
+ _this57.clearMeetingData();
8843
8966
  // upload logs on leave irrespective of meeting delete
8844
- _triggerProxy.default.trigger(_this55, {
8967
+ _triggerProxy.default.trigger(_this57, {
8845
8968
  file: 'meeting/index',
8846
8969
  function: 'endMeetingForAll'
8847
- }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this55);
8970
+ }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this57);
8848
8971
  return end;
8849
8972
  }).catch(function (error) {
8850
- _this55.meetingFiniteStateMachine.fail(error);
8973
+ _this57.meetingFiniteStateMachine.fail(error);
8851
8974
  _loggerProxy.default.logger.error('Meeting:index#endMeetingForAll --> Failed to end meeting ', error);
8852
8975
  // upload logs on leave irrespective of meeting delete
8853
- _triggerProxy.default.trigger(_this55, {
8976
+ _triggerProxy.default.trigger(_this57, {
8854
8977
  file: 'meeting/index',
8855
8978
  function: 'endMeetingForAll'
8856
- }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this55);
8979
+ }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this57);
8857
8980
  _metrics.default.sendBehavioralMetric(_constants2.default.MEETING_END_ALL_FAILURE, {
8858
- correlation_id: _this55.correlationId,
8859
- locus_id: _this55.locusUrl.split('/').pop(),
8981
+ correlation_id: _this57.correlationId,
8982
+ locus_id: _this57.locusUrl.split('/').pop(),
8860
8983
  reason: error.message,
8861
8984
  stack: error.stack,
8862
8985
  code: error.code
@@ -9017,7 +9140,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
9017
9140
  _this$mediaProperties43,
9018
9141
  _this$mediaProperties44,
9019
9142
  _this$mediaProperties45,
9020
- _this56 = this;
9143
+ _this58 = this;
9021
9144
  var LOG_HEADER = 'Meeting:index#updateTranscodedMediaConnection -->';
9022
9145
  _loggerProxy.default.logger.info("".concat(LOG_HEADER, " starting"));
9023
9146
  if (!this.canUpdateMedia()) {
@@ -9042,8 +9165,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
9042
9165
  }).catch(function (error) {
9043
9166
  _loggerProxy.default.logger.error("".concat(LOG_HEADER, " Error: "), error);
9044
9167
  _metrics.default.sendBehavioralMetric(_constants2.default.UPDATE_MEDIA_FAILURE, {
9045
- correlation_id: _this56.correlationId,
9046
- locus_id: _this56.locusUrl.split('/').pop(),
9168
+ correlation_id: _this58.correlationId,
9169
+ locus_id: _this58.locusUrl.split('/').pop(),
9047
9170
  reason: error.message,
9048
9171
  stack: error.stack
9049
9172
  });
@@ -9265,13 +9388,18 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
9265
9388
  return this.updateTranscodedMediaConnection();
9266
9389
  case 31:
9267
9390
  if (!floorRequestNeeded) {
9268
- _context40.next = 39;
9391
+ _context40.next = 40;
9269
9392
  break;
9270
9393
  }
9271
9394
  this.localShareInstanceId = _uuid.default.v4();
9272
9395
  this.shareCAEventSentStatus.transmitStart = false;
9273
9396
  this.shareCAEventSentStatus.transmitStop = false;
9274
9397
 
9398
+ // @ts-ignore
9399
+ this.webex.internal.newMetrics.callDiagnosticLatencies.saveTimestamp({
9400
+ key: 'internal.client.share.initiated'
9401
+ });
9402
+
9275
9403
  // @ts-ignore
9276
9404
  this.webex.internal.newMetrics.submitClientEvent({
9277
9405
  name: 'client.share.initiated',
@@ -9291,9 +9419,9 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
9291
9419
  // we're sending the http request to Locus to request the screen share floor
9292
9420
  // only after the SDP update, because that's how it's always been done for transcoded meetings
9293
9421
  // and also if sharing from the start, we need confluence to have been created
9294
- _context40.next = 39;
9422
+ _context40.next = 40;
9295
9423
  return this.enqueueScreenShareFloorRequest();
9296
- case 39:
9424
+ case 40:
9297
9425
  case "end":
9298
9426
  return _context40.stop();
9299
9427
  }
@@ -9481,7 +9609,97 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
9481
9609
  return _getMediaReachabilityMetricFields.apply(this, arguments);
9482
9610
  }
9483
9611
  return getMediaReachabilityMetricFields;
9484
- }())
9612
+ }()
9613
+ /**
9614
+ * Set the stage for the meeting
9615
+ *
9616
+ * @param {SetStageOptions} options Options to use when setting the stage
9617
+ * @returns {Promise} The locus request
9618
+ */
9619
+ )
9620
+ }, {
9621
+ key: "setStage",
9622
+ value: function setStage() {
9623
+ var _ref37 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
9624
+ _ref37$activeSpeakerP = _ref37.activeSpeakerProportion,
9625
+ activeSpeakerProportion = _ref37$activeSpeakerP === void 0 ? 0.5 : _ref37$activeSpeakerP,
9626
+ customBackground = _ref37.customBackground,
9627
+ customLogo = _ref37.customLogo,
9628
+ customNameLabel = _ref37.customNameLabel,
9629
+ importantParticipants = _ref37.importantParticipants,
9630
+ _ref37$lockAttendeeVi = _ref37.lockAttendeeViewOnStage,
9631
+ lockAttendeeViewOnStage = _ref37$lockAttendeeVi === void 0 ? false : _ref37$lockAttendeeVi,
9632
+ _ref37$showActiveSpea = _ref37.showActiveSpeaker,
9633
+ showActiveSpeaker = _ref37$showActiveSpea === void 0 ? false : _ref37$showActiveSpea;
9634
+ var videoLayout = {
9635
+ overrideDefault: true,
9636
+ lockAttendeeViewOnStageOnly: lockAttendeeViewOnStage,
9637
+ stageParameters: {
9638
+ activeSpeakerProportion: activeSpeakerProportion,
9639
+ showActiveSpeaker: {
9640
+ show: showActiveSpeaker,
9641
+ order: 0
9642
+ },
9643
+ stageManagerType: 0
9644
+ }
9645
+ };
9646
+ if (importantParticipants !== null && importantParticipants !== void 0 && importantParticipants.length) {
9647
+ videoLayout.stageParameters.importantParticipants = importantParticipants.map(function (importantParticipant, index) {
9648
+ return _objectSpread(_objectSpread({}, importantParticipant), {}, {
9649
+ order: index + 1
9650
+ });
9651
+ });
9652
+ }
9653
+ if (customLogo) {
9654
+ if (!videoLayout.customLayouts) {
9655
+ videoLayout.customLayouts = {};
9656
+ }
9657
+ videoLayout.customLayouts.logo = customLogo;
9658
+ // eslint-disable-next-line no-bitwise
9659
+ videoLayout.stageParameters.stageManagerType |= _constants.STAGE_MANAGER_TYPE.LOGO;
9660
+ }
9661
+ if (customBackground) {
9662
+ if (!videoLayout.customLayouts) {
9663
+ videoLayout.customLayouts = {};
9664
+ }
9665
+ videoLayout.customLayouts.background = customBackground;
9666
+ // eslint-disable-next-line no-bitwise
9667
+ videoLayout.stageParameters.stageManagerType |= _constants.STAGE_MANAGER_TYPE.BACKGROUND;
9668
+ }
9669
+ if (customNameLabel) {
9670
+ videoLayout.nameLabelStyle = customNameLabel;
9671
+ // eslint-disable-next-line no-bitwise
9672
+ videoLayout.stageParameters.stageManagerType |= _constants.STAGE_MANAGER_TYPE.NAME_LABEL;
9673
+ }
9674
+ return this.meetingRequest.synchronizeStage(this.locusUrl, videoLayout);
9675
+ }
9676
+
9677
+ /**
9678
+ * Unset the stage for the meeting
9679
+ *
9680
+ * @returns {Promise} The locus request
9681
+ */
9682
+ }, {
9683
+ key: "unsetStage",
9684
+ value: function unsetStage() {
9685
+ var videoLayout = {
9686
+ overrideDefault: false
9687
+ };
9688
+ return this.meetingRequest.synchronizeStage(this.locusUrl, videoLayout);
9689
+ }
9690
+
9691
+ /**
9692
+ * Notifies the host with the given meeting UUID and display names.
9693
+ *
9694
+ * @param {string} meetingUuid - The UUID of the meeting.
9695
+ * @param {string[]} displayName - An array of display names to notify the host with.
9696
+ * @returns {Promise<any>} The result of the notifyHost request.
9697
+ */
9698
+ }, {
9699
+ key: "notifyHost",
9700
+ value: function notifyHost(meetingUuid, displayName) {
9701
+ return this.meetingRequest.notifyHost(this.meetingInfo.siteFullUrl, this.locusId, meetingUuid, displayName);
9702
+ }
9485
9703
  }]);
9486
9704
  return Meeting;
9487
9705
  }(_webexCore.StatelessWebexPlugin);