@azure/communication-react 1.3.3-alpha-202208240015.0 → 1.3.3-alpha-202208270015.0

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 (55) hide show
  1. package/dist/communication-react.d.ts +18 -18
  2. package/dist/dist-cjs/communication-react/index.js +340 -204
  3. package/dist/dist-cjs/communication-react/index.js.map +1 -1
  4. package/dist/dist-esm/acs-ui-common/src/telemetryVersion.js +1 -1
  5. package/dist/dist-esm/acs-ui-common/src/telemetryVersion.js.map +1 -1
  6. package/dist/dist-esm/calling-component-bindings/src/utils/callUtils.js +1 -1
  7. package/dist/dist-esm/calling-component-bindings/src/utils/callUtils.js.map +1 -1
  8. package/dist/dist-esm/communication-react/src/index.d.ts +1 -1
  9. package/dist/dist-esm/communication-react/src/index.js.map +1 -1
  10. package/dist/dist-esm/react-components/src/components/Dialpad/Dialpad.d.ts +3 -14
  11. package/dist/dist-esm/react-components/src/components/Dialpad/Dialpad.js +64 -42
  12. package/dist/dist-esm/react-components/src/components/Dialpad/Dialpad.js.map +1 -1
  13. package/dist/dist-esm/react-components/src/components/HoldButton.js +1 -1
  14. package/dist/dist-esm/react-components/src/components/HoldButton.js.map +1 -1
  15. package/dist/dist-esm/react-components/src/components/ParticipantItem.js +1 -1
  16. package/dist/dist-esm/react-components/src/components/ParticipantItem.js.map +1 -1
  17. package/dist/dist-esm/react-components/src/components/index.d.ts +1 -1
  18. package/dist/dist-esm/react-components/src/components/index.js.map +1 -1
  19. package/dist/dist-esm/react-components/src/components/utils/useLongPress.d.ts +15 -0
  20. package/dist/dist-esm/react-components/src/components/utils/useLongPress.js +58 -0
  21. package/dist/dist-esm/react-components/src/components/utils/useLongPress.js.map +1 -0
  22. package/dist/dist-esm/react-components/src/theming/icons.d.ts +3 -1
  23. package/dist/dist-esm/react-components/src/theming/icons.js +6 -2
  24. package/dist/dist-esm/react-components/src/theming/icons.js.map +1 -1
  25. package/dist/dist-esm/react-composites/src/composites/CallComposite/Strings.d.ts +8 -0
  26. package/dist/dist-esm/react-composites/src/composites/CallComposite/Strings.js.map +1 -1
  27. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/AzureCommunicationCallAdapter.js +1 -1
  28. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/AzureCommunicationCallAdapter.js.map +1 -1
  29. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallAdapter.d.ts +1 -1
  30. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallAdapter.js.map +1 -1
  31. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallControls.js +3 -3
  32. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallControls.js.map +1 -1
  33. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/HoldPane.js +31 -7
  34. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/HoldPane.js.map +1 -1
  35. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/ConfigurationPage.js +12 -1
  36. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/ConfigurationPage.js.map +1 -1
  37. package/dist/dist-esm/react-composites/src/composites/CallComposite/styles/Buttons.styles.js +2 -1
  38. package/dist/dist-esm/react-composites/src/composites/CallComposite/styles/Buttons.styles.js.map +1 -1
  39. package/dist/dist-esm/react-composites/src/composites/CallComposite/styles/HoldPane.styles.js +5 -0
  40. package/dist/dist-esm/react-composites/src/composites/CallComposite/styles/HoldPane.styles.js.map +1 -1
  41. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/Utils.js +4 -3
  42. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/Utils.js.map +1 -1
  43. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/components/DesktopMoreButton.js +1 -1
  44. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/components/DesktopMoreButton.js.map +1 -1
  45. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/components/MoreDrawer.js +1 -1
  46. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/components/MoreDrawer.js.map +1 -1
  47. package/dist/dist-esm/react-composites/src/composites/common/CallingDialpad.styles.js +1 -0
  48. package/dist/dist-esm/react-composites/src/composites/common/CallingDialpad.styles.js.map +1 -1
  49. package/dist/dist-esm/react-composites/src/composites/common/PeoplePaneContent.js +20 -3
  50. package/dist/dist-esm/react-composites/src/composites/common/PeoplePaneContent.js.map +1 -1
  51. package/dist/dist-esm/react-composites/src/composites/common/SendDtmfDialpad.styles.js +1 -0
  52. package/dist/dist-esm/react-composites/src/composites/common/SendDtmfDialpad.styles.js.map +1 -1
  53. package/dist/dist-esm/react-composites/src/composites/common/icons.d.ts +3 -1
  54. package/dist/dist-esm/react-composites/src/composites/localization/locales/en-US/strings.json +2 -0
  55. package/package.json +8 -8
@@ -192,7 +192,7 @@ const fromFlatCommunicationIdentifier = (id) => {
192
192
  // Copyright (c) Microsoft Corporation.
193
193
  // Licensed under the MIT license.
194
194
  // GENERATED FILE. DO NOT EDIT MANUALLY.
195
- var telemetryVersion = '1.3.3-alpha-202208240015.0';
195
+ var telemetryVersion = '1.3.3-alpha-202208270015.0';
196
196
 
197
197
  // Copyright (c) Microsoft Corporation.
198
198
  /**
@@ -391,7 +391,7 @@ const getCallState = (state, props) => { var _a; return (_a = state.calls[props.
391
391
 
392
392
  // Copyright (c) Microsoft Corporation.
393
393
  // Licensed under the MIT license.
394
- var __awaiter$u = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
394
+ var __awaiter$w = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
395
395
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
396
396
  return new (P || (P = Promise))(function (resolve, reject) {
397
397
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -405,7 +405,7 @@ var __awaiter$u = (window && window.__awaiter) || function (thisArg, _arguments,
405
405
  *
406
406
  * @internal
407
407
  */
408
- const _isInCall = (callStatus) => !!callStatus && !['None', 'Disconnected', 'Connecting', 'LocalHold', 'Ringing', 'EarlyMedia'].includes(callStatus);
408
+ const _isInCall = (callStatus) => !!callStatus && !['None', 'Disconnected', 'Connecting', 'Ringing', 'EarlyMedia'].includes(callStatus);
409
409
  /**
410
410
  * Check if the call state represents being in the lobby or waiting to be admitted.
411
411
  *
@@ -429,7 +429,7 @@ const _isPreviewOn = (deviceManager) => {
429
429
  *
430
430
  * @private
431
431
  */
432
- const disposeAllLocalPreviewViews = (callClient) => __awaiter$u(void 0, void 0, void 0, function* () {
432
+ const disposeAllLocalPreviewViews = (callClient) => __awaiter$w(void 0, void 0, void 0, function* () {
433
433
  const unparentedViews = callClient.getState().deviceManager.unparentedViews;
434
434
  for (const view of unparentedViews) {
435
435
  yield callClient.disposeView(undefined, undefined, view);
@@ -536,7 +536,7 @@ const holdButtonSelector = reselect__namespace.createSelector([getCallState], (c
536
536
 
537
537
  // Copyright (c) Microsoft Corporation.
538
538
  // Licensed under the MIT license.
539
- var __awaiter$t = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
539
+ var __awaiter$v = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
540
540
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
541
541
  return new (P || (P = Promise))(function (resolve, reject) {
542
542
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -560,7 +560,7 @@ const areStreamsEqual = (prevStream, newStream) => {
560
560
  * @public
561
561
  */
562
562
  const createDefaultCallingHandlers = memoizeOne__default['default']((callClient, callAgent, deviceManager, call) => {
563
- const onStartLocalVideo = () => __awaiter$t(void 0, void 0, void 0, function* () {
563
+ const onStartLocalVideo = () => __awaiter$v(void 0, void 0, void 0, function* () {
564
564
  // Before the call object creates a stream, dispose of any local preview streams.
565
565
  // @TODO: is there any way to parent the unparented view to the call object instead
566
566
  // of disposing and creating a new stream?
@@ -580,7 +580,7 @@ const createDefaultCallingHandlers = memoizeOne__default['default']((callClient,
580
580
  yield call.startVideo(stream);
581
581
  }
582
582
  });
583
- const onStopLocalVideo = (stream) => __awaiter$t(void 0, void 0, void 0, function* () {
583
+ const onStopLocalVideo = (stream) => __awaiter$v(void 0, void 0, void 0, function* () {
584
584
  const callId = call === null || call === void 0 ? void 0 : call.id;
585
585
  if (!callId) {
586
586
  return;
@@ -593,7 +593,7 @@ const createDefaultCallingHandlers = memoizeOne__default['default']((callClient,
593
593
  });
594
594
  }
595
595
  });
596
- const onToggleCamera = (options) => __awaiter$t(void 0, void 0, void 0, function* () {
596
+ const onToggleCamera = (options) => __awaiter$v(void 0, void 0, void 0, function* () {
597
597
  if (call && _isInCall(call.state)) {
598
598
  const stream = call.localVideoStreams.find((stream) => stream.mediaStreamType === 'Video');
599
599
  if (stream) {
@@ -623,19 +623,19 @@ const createDefaultCallingHandlers = memoizeOne__default['default']((callClient,
623
623
  const onStartCall = (participants, options) => {
624
624
  return callAgent ? callAgent.startCall(participants, options) : undefined;
625
625
  };
626
- const onSelectMicrophone = (device) => __awaiter$t(void 0, void 0, void 0, function* () {
626
+ const onSelectMicrophone = (device) => __awaiter$v(void 0, void 0, void 0, function* () {
627
627
  if (!deviceManager) {
628
628
  return;
629
629
  }
630
630
  return deviceManager.selectMicrophone(device);
631
631
  });
632
- const onSelectSpeaker = (device) => __awaiter$t(void 0, void 0, void 0, function* () {
632
+ const onSelectSpeaker = (device) => __awaiter$v(void 0, void 0, void 0, function* () {
633
633
  if (!deviceManager) {
634
634
  return;
635
635
  }
636
636
  return deviceManager.selectSpeaker(device);
637
637
  });
638
- const onSelectCamera = (device, options) => __awaiter$t(void 0, void 0, void 0, function* () {
638
+ const onSelectCamera = (device, options) => __awaiter$v(void 0, void 0, void 0, function* () {
639
639
  if (!deviceManager) {
640
640
  return;
641
641
  }
@@ -658,19 +658,19 @@ const createDefaultCallingHandlers = memoizeOne__default['default']((callClient,
658
658
  }, options);
659
659
  }
660
660
  });
661
- const onToggleMicrophone = () => __awaiter$t(void 0, void 0, void 0, function* () {
661
+ const onToggleMicrophone = () => __awaiter$v(void 0, void 0, void 0, function* () {
662
662
  if (!call || !_isInCall(call.state)) {
663
663
  throw new Error(`Please invoke onToggleMicrophone after call is started`);
664
664
  }
665
665
  return call.isMuted ? yield call.unmute() : yield call.mute();
666
666
  });
667
- const onStartScreenShare = () => __awaiter$t(void 0, void 0, void 0, function* () { return yield (call === null || call === void 0 ? void 0 : call.startScreenSharing()); });
668
- const onStopScreenShare = () => __awaiter$t(void 0, void 0, void 0, function* () { return yield (call === null || call === void 0 ? void 0 : call.stopScreenSharing()); });
669
- const onToggleScreenShare = () => __awaiter$t(void 0, void 0, void 0, function* () { return (call === null || call === void 0 ? void 0 : call.isScreenSharingOn) ? yield onStopScreenShare() : yield onStartScreenShare(); });
670
- const onHangUp = () => __awaiter$t(void 0, void 0, void 0, function* () { return yield (call === null || call === void 0 ? void 0 : call.hangUp()); });
667
+ const onStartScreenShare = () => __awaiter$v(void 0, void 0, void 0, function* () { return yield (call === null || call === void 0 ? void 0 : call.startScreenSharing()); });
668
+ const onStopScreenShare = () => __awaiter$v(void 0, void 0, void 0, function* () { return yield (call === null || call === void 0 ? void 0 : call.stopScreenSharing()); });
669
+ const onToggleScreenShare = () => __awaiter$v(void 0, void 0, void 0, function* () { return (call === null || call === void 0 ? void 0 : call.isScreenSharingOn) ? yield onStopScreenShare() : yield onStartScreenShare(); });
670
+ const onHangUp = () => __awaiter$v(void 0, void 0, void 0, function* () { return yield (call === null || call === void 0 ? void 0 : call.hangUp()); });
671
671
  /* @conditional-compile-remove(PSTN-calls) */
672
- const onToggleHold = () => __awaiter$t(void 0, void 0, void 0, function* () { return (call === null || call === void 0 ? void 0 : call.state) === 'LocalHold' ? yield (call === null || call === void 0 ? void 0 : call.resume()) : yield (call === null || call === void 0 ? void 0 : call.hold()); });
673
- const onCreateLocalStreamView = (options = { scalingMode: 'Crop', isMirrored: true }) => __awaiter$t(void 0, void 0, void 0, function* () {
672
+ const onToggleHold = () => __awaiter$v(void 0, void 0, void 0, function* () { return (call === null || call === void 0 ? void 0 : call.state) === 'LocalHold' ? yield (call === null || call === void 0 ? void 0 : call.resume()) : yield (call === null || call === void 0 ? void 0 : call.hold()); });
673
+ const onCreateLocalStreamView = (options = { scalingMode: 'Crop', isMirrored: true }) => __awaiter$v(void 0, void 0, void 0, function* () {
674
674
  var _a;
675
675
  if (!call || call.localVideoStreams.length === 0) {
676
676
  return;
@@ -686,7 +686,7 @@ const createDefaultCallingHandlers = memoizeOne__default['default']((callClient,
686
686
  const { view } = (_a = (yield callClient.createView(call.id, undefined, localStream, options))) !== null && _a !== void 0 ? _a : {};
687
687
  return view ? { view } : undefined;
688
688
  });
689
- const onCreateRemoteStreamView = (userId, options = { scalingMode: 'Crop' }) => __awaiter$t(void 0, void 0, void 0, function* () {
689
+ const onCreateRemoteStreamView = (userId, options = { scalingMode: 'Crop' }) => __awaiter$v(void 0, void 0, void 0, function* () {
690
690
  if (!call) {
691
691
  return;
692
692
  }
@@ -714,7 +714,7 @@ const createDefaultCallingHandlers = memoizeOne__default['default']((callClient,
714
714
  }
715
715
  return (createViewResult === null || createViewResult === void 0 ? void 0 : createViewResult.view) ? { view: createViewResult === null || createViewResult === void 0 ? void 0 : createViewResult.view } : undefined;
716
716
  });
717
- const onDisposeRemoteStreamView = (userId) => __awaiter$t(void 0, void 0, void 0, function* () {
717
+ const onDisposeRemoteStreamView = (userId) => __awaiter$v(void 0, void 0, void 0, function* () {
718
718
  if (!call) {
719
719
  return;
720
720
  }
@@ -735,7 +735,7 @@ const createDefaultCallingHandlers = memoizeOne__default['default']((callClient,
735
735
  callClient.disposeView(call.id, participant.identifier, screenShareStream);
736
736
  }
737
737
  });
738
- const onDisposeLocalStreamView = () => __awaiter$t(void 0, void 0, void 0, function* () {
738
+ const onDisposeLocalStreamView = () => __awaiter$v(void 0, void 0, void 0, function* () {
739
739
  // If the user is currently in a call, dispose of the local stream view attached to that call.
740
740
  const callState = call && callClient.getState().calls[call.id];
741
741
  const localStream = callState === null || callState === void 0 ? void 0 : callState.localVideoStreams.find((item) => item.mediaStreamType === 'Video');
@@ -747,11 +747,11 @@ const createDefaultCallingHandlers = memoizeOne__default['default']((callClient,
747
747
  // TODO: we need to remember which LocalVideoStream was used for LocalPreview and dispose that one.
748
748
  yield disposeAllLocalPreviewViews(callClient);
749
749
  });
750
- const onRemoveParticipant = (userId) => __awaiter$t(void 0, void 0, void 0, function* () {
750
+ const onRemoveParticipant = (userId) => __awaiter$v(void 0, void 0, void 0, function* () {
751
751
  yield (call === null || call === void 0 ? void 0 : call.removeParticipant(fromFlatCommunicationIdentifier(userId)));
752
752
  });
753
753
  /* @conditional-compile-remove(PSTN-calls) */
754
- const onAddParticipant = (participant, options) => __awaiter$t(void 0, void 0, void 0, function* () {
754
+ const onAddParticipant = (participant, options) => __awaiter$v(void 0, void 0, void 0, function* () {
755
755
  if (communicationCommon.isPhoneNumberIdentifier(participant)) {
756
756
  yield (call === null || call === void 0 ? void 0 : call.addParticipant(participant, options));
757
757
  }
@@ -760,7 +760,7 @@ const createDefaultCallingHandlers = memoizeOne__default['default']((callClient,
760
760
  }
761
761
  });
762
762
  /* @conditional-compile-remove(dialpad) */ /* @conditional-compile-remove(PSTN-calls) */
763
- const onSendDtmfTone = (dtmfTone) => __awaiter$t(void 0, void 0, void 0, function* () { return yield (call === null || call === void 0 ? void 0 : call.sendDtmf(dtmfTone)); });
763
+ const onSendDtmfTone = (dtmfTone) => __awaiter$v(void 0, void 0, void 0, function* () { return yield (call === null || call === void 0 ? void 0 : call.sendDtmf(dtmfTone)); });
764
764
  return {
765
765
  onHangUp,
766
766
  /* @conditional-compile-remove(PSTN-calls) */
@@ -1899,6 +1899,8 @@ const DEFAULT_COMPONENT_ICONS = {
1899
1899
  ControlButtonMicOn: React__default['default'].createElement(reactIcons.MicOn20Filled, null),
1900
1900
  ControlButtonOptions: React__default['default'].createElement(reactIcons.Settings20Filled, null),
1901
1901
  ControlButtonParticipants: React__default['default'].createElement(reactIcons.People20Filled, null),
1902
+ /* @conditional-compile-remove(dialpad) */ /* @conditional-compile-remove(PSTN-calls) */
1903
+ ControlButtonParticipantsContextualMenuItem: React__default['default'].createElement(reactIcons.People20Regular, null),
1902
1904
  ControlButtonScreenShareStart: React__default['default'].createElement(reactIcons.ShareScreenStart20Filled, null),
1903
1905
  ControlButtonScreenShareStop: React__default['default'].createElement(reactIcons.ShareScreenStop20Filled, null),
1904
1906
  /* @conditional-compile-remove(file-sharing) */
@@ -1938,7 +1940,9 @@ const DEFAULT_COMPONENT_ICONS = {
1938
1940
  ParticipantItemOptionsHovered: React__default['default'].createElement(reactIcons.MoreHorizontal20Filled, null),
1939
1941
  ParticipantItemScreenShareStart: React__default['default'].createElement(reactIcons.ShareScreenStart20Filled, null),
1940
1942
  /* @conditional-compile-remove(PSTN-calls) */
1941
- HoldCall: React__default['default'].createElement(reactIcons.Pause20Regular, null),
1943
+ HoldCallContextualMenuItem: React__default['default'].createElement(reactIcons.CallPause20Regular, null),
1944
+ /* @conditional-compile-remove(PSTN-calls) */
1945
+ HoldCallButton: React__default['default'].createElement(reactIcons.CallPause20Filled, null),
1942
1946
  /* @conditional-compile-remove(PSTN-calls) */
1943
1947
  ResumeCall: React__default['default'].createElement(reactIcons.Play20Regular, null),
1944
1948
  SendBoxSend: React__default['default'].createElement(reactIcons.Send20Regular, null),
@@ -3392,7 +3396,7 @@ const chatMessageActionMenuProps = (menuProps) => {
3392
3396
  return actionMenuProps;
3393
3397
  };
3394
3398
 
3395
- var __awaiter$s = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
3399
+ var __awaiter$u = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
3396
3400
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3397
3401
  return new (P || (P = Promise))(function (resolve, reject) {
3398
3402
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -3417,7 +3421,7 @@ const _FileDownloadCards = (props) => {
3417
3421
  var _a, _b;
3418
3422
  return (_b = (_a = props.strings) === null || _a === void 0 ? void 0 : _a.downloadFile) !== null && _b !== void 0 ? _b : localeStrings.downloadFile;
3419
3423
  }, [(_a = props.strings) === null || _a === void 0 ? void 0 : _a.downloadFile, localeStrings.downloadFile]);
3420
- const fileDownloadHandler = React.useCallback((userId, file) => __awaiter$s(void 0, void 0, void 0, function* () {
3424
+ const fileDownloadHandler = React.useCallback((userId, file) => __awaiter$u(void 0, void 0, void 0, function* () {
3421
3425
  if (!props.downloadHandler) {
3422
3426
  window.open(file.url, '_blank', 'noopener,noreferrer');
3423
3427
  }
@@ -3565,7 +3569,7 @@ const ChatMessageComponentAsMessageBubble = React__default['default'].memo(Messa
3565
3569
 
3566
3570
  // Copyright (c) Microsoft Corporation.
3567
3571
  // Licensed under the MIT license.
3568
- var __awaiter$r = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
3572
+ var __awaiter$t = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
3569
3573
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3570
3574
  return new (P || (P = Promise))(function (resolve, reject) {
3571
3575
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -3599,7 +3603,7 @@ const ChatMessageComponent = (props) => {
3599
3603
  return React__default['default'].createElement(React__default['default'].Fragment, null);
3600
3604
  }
3601
3605
  else if (isEditing) {
3602
- return (React__default['default'].createElement(ChatMessageComponentAsEditBox, { message: message, inlineEditButtons: props.inlineAcceptRejectEditButtons, strings: props.strings, onSubmit: (text, metadata, options) => __awaiter$r(void 0, void 0, void 0, function* () {
3606
+ return (React__default['default'].createElement(ChatMessageComponentAsEditBox, { message: message, inlineEditButtons: props.inlineAcceptRejectEditButtons, strings: props.strings, onSubmit: (text, metadata, options) => __awaiter$t(void 0, void 0, void 0, function* () {
3603
3607
  props.onUpdateMessage &&
3604
3608
  props.message.messageId &&
3605
3609
  (yield props.onUpdateMessage(props.message.messageId, text, metadata, options));
@@ -3698,7 +3702,7 @@ const getParticipantsWhoHaveReadMessage = (message, readReceiptsBySenderId) => {
3698
3702
 
3699
3703
  // Copyright (c) Microsoft Corporation.
3700
3704
  // Licensed under the MIT license.
3701
- var __awaiter$q = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
3705
+ var __awaiter$s = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
3702
3706
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3703
3707
  return new (P || (P = Promise))(function (resolve, reject) {
3704
3708
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -3925,7 +3929,7 @@ const MessageThread = (props) => {
3925
3929
  setChatMessagesInitialized(chatMessagesInitialized);
3926
3930
  };
3927
3931
  // we try to only send those message status if user is scrolled to the bottom.
3928
- const sendMessageStatusIfAtBottom = React.useCallback(() => __awaiter$q(void 0, void 0, void 0, function* () {
3932
+ const sendMessageStatusIfAtBottom = React.useCallback(() => __awaiter$s(void 0, void 0, void 0, function* () {
3929
3933
  if (!isAtBottomOfScrollRef.current ||
3930
3934
  !document.hasFocus() ||
3931
3935
  !messagesRef.current ||
@@ -3976,7 +3980,7 @@ const MessageThread = (props) => {
3976
3980
  setIsAtBottomOfScrollRef(atBottom);
3977
3981
  }, [scrollToBottom, sendMessageStatusIfAtBottom]);
3978
3982
  // Infinite scrolling + threadInitialize function
3979
- const fetchNewMessageWhenAtTop = React.useCallback(() => __awaiter$q(void 0, void 0, void 0, function* () {
3983
+ const fetchNewMessageWhenAtTop = React.useCallback(() => __awaiter$s(void 0, void 0, void 0, function* () {
3980
3984
  if (chatScrollDivRef.current && !isLoadingChatMessagesRef.current) {
3981
3985
  if (onLoadPreviousChatMessages) {
3982
3986
  isLoadingChatMessagesRef.current = true;
@@ -4428,7 +4432,7 @@ const ParticipantItem = (props) => {
4428
4432
  setMenuHidden(true);
4429
4433
  };
4430
4434
  const participantStateString = participantStateStringTrampoline$1(props, strings);
4431
- return (React__default['default'].createElement("div", { ref: containerRef, role: 'menuitem', "data-is-focusable": true, className: react.mergeStyles(participantItemContainerStyle({ localparticipant: me, clickable: !!menuItems }), styles === null || styles === void 0 ? void 0 : styles.root), onMouseEnter: () => setItemHovered(true), onMouseLeave: () => setItemHovered(false), onClick: () => {
4435
+ return (React__default['default'].createElement("div", { ref: containerRef, role: 'menuitem', "data-is-focusable": true, "data-ui-id": "participant-item", className: react.mergeStyles(participantItemContainerStyle({ localparticipant: me, clickable: !!menuItems }), styles === null || styles === void 0 ? void 0 : styles.root), onMouseEnter: () => setItemHovered(true), onMouseLeave: () => setItemHovered(false), onClick: () => {
4432
4436
  if (!participantStateString) {
4433
4437
  setItemHovered(true);
4434
4438
  setMenuHidden(false);
@@ -6789,7 +6793,7 @@ const DevicesButton = (props) => {
6789
6793
 
6790
6794
  // Copyright (c) Microsoft Corporation.
6791
6795
  // Licensed under the MIT license.
6792
- var __awaiter$p = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
6796
+ var __awaiter$r = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
6793
6797
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
6794
6798
  return new (P || (P = Promise))(function (resolve, reject) {
6795
6799
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -6831,7 +6835,7 @@ const CameraButton = (props) => {
6831
6835
  const toggleAnnouncerString = React.useCallback((isCameraOn) => {
6832
6836
  setAnnouncerString(!isCameraOn ? strings.cameraActionTurnedOffAnnouncement : strings.cameraActionTurnedOnAnnouncement);
6833
6837
  }, [strings.cameraActionTurnedOffAnnouncement, strings.cameraActionTurnedOnAnnouncement]);
6834
- const onToggleClick = React.useCallback(() => __awaiter$p(void 0, void 0, void 0, function* () {
6838
+ const onToggleClick = React.useCallback(() => __awaiter$r(void 0, void 0, void 0, function* () {
6835
6839
  // Throttle click on camera, need to await onToggleCamera then allow another click
6836
6840
  if (onToggleCamera) {
6837
6841
  setWaitForCamera(true);
@@ -6963,7 +6967,7 @@ const lightThemeCallButtonStyles = {
6963
6967
 
6964
6968
  // Copyright (c) Microsoft Corporation.
6965
6969
  // Licensed under the MIT license.
6966
- var __awaiter$o = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
6970
+ var __awaiter$q = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
6967
6971
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
6968
6972
  return new (P || (P = Promise))(function (resolve, reject) {
6969
6973
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -7006,7 +7010,7 @@ const MicrophoneButton = (props) => {
7006
7010
  const toggleAnnouncerString = React.useCallback((isMicOn) => {
7007
7011
  setAnnouncerString(!isMicOn ? strings.microphoneActionTurnedOffAnnouncement : strings.microphoneActionTurnedOnAnnouncement);
7008
7012
  }, [strings.microphoneActionTurnedOffAnnouncement, strings.microphoneActionTurnedOnAnnouncement]);
7009
- const onToggleClick = React.useCallback(() => __awaiter$o(void 0, void 0, void 0, function* () {
7013
+ const onToggleClick = React.useCallback(() => __awaiter$q(void 0, void 0, void 0, function* () {
7010
7014
  if (onToggleMicrophone) {
7011
7015
  try {
7012
7016
  yield onToggleMicrophone();
@@ -7817,15 +7821,71 @@ const formatPhoneNumber = (phoneNumber) => {
7817
7821
  };
7818
7822
 
7819
7823
  // Copyright (c) Microsoft Corporation.
7820
- const DialpadButton = (props) => {
7821
- var _a, _b, _c, _d;
7822
- const theme = react.useTheme();
7823
- return (React__default['default'].createElement(react.DefaultButton, { "data-test-id": `dialpad-button-${props.index}`, onClick: () => {
7824
- props.onClick(props.primaryContent, props.index);
7825
- }, styles: react.concatStyleSets(buttonStyles(), (_a = props.styles) === null || _a === void 0 ? void 0 : _a.button) },
7826
- React__default['default'].createElement(react.Stack, null,
7827
- React__default['default'].createElement(react.Text, { className: react.mergeStyles(primaryContentStyles(theme), (_b = props.styles) === null || _b === void 0 ? void 0 : _b.primaryContent) }, props.primaryContent),
7828
- React__default['default'].createElement(react.Text, { className: react.mergeStyles(secondaryContentStyles(theme), (_c = props.styles) === null || _c === void 0 ? void 0 : _c.secondaryContent) }, (_d = props.secondaryContent) !== null && _d !== void 0 ? _d : ' '))));
7824
+ /**
7825
+ * @private
7826
+ */
7827
+ function useLongPress(onClick, onLongPress) {
7828
+ const timerRef = React.useRef();
7829
+ const [isLongPress, setIsLongPress] = React.useState(false);
7830
+ const [action, setAction] = React.useState(false);
7831
+ function startPressTimer() {
7832
+ setIsLongPress(false);
7833
+ timerRef.current = setTimeout(() => {
7834
+ setIsLongPress(true);
7835
+ }, 500);
7836
+ }
7837
+ function handleOnClick() {
7838
+ onClick();
7839
+ if (isLongPress) {
7840
+ onLongPress();
7841
+ return;
7842
+ }
7843
+ }
7844
+ function handleOnKeyDown() {
7845
+ if (action) {
7846
+ setAction(false);
7847
+ startPressTimer();
7848
+ }
7849
+ }
7850
+ function handleOnKeyUp() {
7851
+ setAction(true);
7852
+ timerRef.current && clearTimeout(timerRef.current);
7853
+ }
7854
+ function handleOnMouseDown() {
7855
+ startPressTimer();
7856
+ }
7857
+ function handleOnMouseUp() {
7858
+ timerRef.current && clearTimeout(timerRef.current);
7859
+ }
7860
+ function handleOnTouchStart() {
7861
+ startPressTimer();
7862
+ }
7863
+ function handleOnTouchEnd() {
7864
+ timerRef.current && clearTimeout(timerRef.current);
7865
+ }
7866
+ return {
7867
+ handlers: {
7868
+ onClick: handleOnClick,
7869
+ onMouseDown: handleOnMouseDown,
7870
+ onMouseUp: handleOnMouseUp,
7871
+ onTouchStart: handleOnTouchStart,
7872
+ onTouchEnd: handleOnTouchEnd,
7873
+ onKeyDown: handleOnKeyDown,
7874
+ onKeyUp: handleOnKeyUp
7875
+ }
7876
+ };
7877
+ }
7878
+
7879
+ // Copyright (c) Microsoft Corporation.
7880
+ // Licensed under the MIT license.
7881
+ var __awaiter$p = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
7882
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
7883
+ return new (P || (P = Promise))(function (resolve, reject) {
7884
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
7885
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7886
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7887
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
7888
+ });
7829
7889
  };
7830
7890
  const dialPadButtonsDefault = [
7831
7891
  [
@@ -7859,58 +7919,76 @@ const DtmfTones = [
7859
7919
  'Num0',
7860
7920
  'Pound'
7861
7921
  ];
7922
+ const DialpadButton = (props) => {
7923
+ var _a, _b, _c, _d;
7924
+ const theme = react.useTheme();
7925
+ const { primaryContent, index, onClick, onLongPress } = props;
7926
+ const clickFunction = React.useCallback(() => __awaiter$p(void 0, void 0, void 0, function* () {
7927
+ onClick(primaryContent, index);
7928
+ }), [primaryContent, index, onClick]);
7929
+ const longPressFunction = React.useCallback(() => __awaiter$p(void 0, void 0, void 0, function* () {
7930
+ onLongPress(primaryContent, index);
7931
+ }), [primaryContent, index, onLongPress]);
7932
+ const { handlers } = useLongPress(clickFunction, longPressFunction);
7933
+ return (React__default['default'].createElement(react.DefaultButton, Object.assign({ "data-test-id": `dialpad-button-${props.index}`, styles: react.concatStyleSets(buttonStyles(), (_a = props.styles) === null || _a === void 0 ? void 0 : _a.button) }, handlers),
7934
+ React__default['default'].createElement(react.Stack, null,
7935
+ React__default['default'].createElement(react.Text, { className: react.mergeStyles(primaryContentStyles(theme), (_b = props.styles) === null || _b === void 0 ? void 0 : _b.primaryContent) }, props.primaryContent),
7936
+ React__default['default'].createElement(react.Text, { className: react.mergeStyles(secondaryContentStyles(theme), (_c = props.styles) === null || _c === void 0 ? void 0 : _c.secondaryContent) }, (_d = props.secondaryContent) !== null && _d !== void 0 ? _d : ' '))));
7937
+ };
7862
7938
  const DialpadContainer = (props) => {
7863
7939
  var _a, _b;
7864
7940
  const theme = react.useTheme();
7865
- const [textValue, setTextValue] = React.useState('');
7866
- const { onSendDtmfTone, onClickDialpadButton, onDisplayDialpadInput, onChange, showDeleteButton = true } = props;
7867
- const sanitizeInput = (input) => {
7868
- // remove non-valid characters from input: letters,special characters excluding +, *,#
7869
- return input.replace(/[^\d*#+]/g, '');
7870
- };
7941
+ const { onSendDtmfTone, onClickDialpadButton, textFieldValue, onChange, showDeleteButton = true } = props;
7942
+ const [plainTextValue, setPlainTextValue] = React.useState(textFieldValue !== null && textFieldValue !== void 0 ? textFieldValue : '');
7943
+ React.useEffect(() => {
7944
+ if (onChange) {
7945
+ onChange(plainTextValue);
7946
+ }
7947
+ }, [plainTextValue, onChange]);
7948
+ React.useEffect(() => {
7949
+ setText(textFieldValue !== null && textFieldValue !== void 0 ? textFieldValue : '');
7950
+ }, [textFieldValue]);
7871
7951
  const onClickDialpad = (input, index) => {
7872
- // remove non-valid characters from input: letters,special characters excluding +, *,#
7873
- const value = sanitizeInput(textValue + input);
7874
- setTextValue(value);
7952
+ setText(plainTextValue + input);
7875
7953
  if (onSendDtmfTone) {
7876
7954
  onSendDtmfTone(DtmfTones[index]);
7877
7955
  }
7878
7956
  if (onClickDialpadButton) {
7879
7957
  onClickDialpadButton(input, index);
7880
7958
  }
7881
- if (onChange) {
7882
- onChange(onDisplayDialpadInput ? onDisplayDialpadInput(value) : formatPhoneNumber(value));
7959
+ };
7960
+ const onLongPressDialpad = (input, index) => {
7961
+ if (input === '0' && index === 10) {
7962
+ setText(plainTextValue + '+');
7963
+ }
7964
+ else {
7965
+ setText(plainTextValue + input);
7966
+ }
7967
+ if (onSendDtmfTone) {
7968
+ onSendDtmfTone(DtmfTones[index]);
7969
+ }
7970
+ if (onClickDialpadButton) {
7971
+ onClickDialpadButton(input, index);
7883
7972
  }
7884
7973
  };
7885
7974
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
7886
- const setText = (e) => {
7975
+ const setText = (input) => {
7887
7976
  // remove non-valid characters from input: letters,special characters excluding +, *,#
7888
- const input = sanitizeInput(e.target.value);
7889
- setTextValue(input);
7977
+ const plainInput = sanitizeInput(input);
7978
+ setPlainTextValue(plainInput);
7890
7979
  };
7891
- // Potential Improvement:
7892
- // comment out the following line for now to disable customization for dialpad content
7893
- // const dialpadButtonsContent = props.dialpadButtons ?? dialPadButtonsDefault;
7894
7980
  const deleteNumbers = () => {
7895
- const modifiedInput = textValue.substring(0, textValue.length - 1);
7896
- setTextValue(modifiedInput);
7897
- if (onChange) {
7898
- onChange(onDisplayDialpadInput ? onDisplayDialpadInput(modifiedInput) : formatPhoneNumber(modifiedInput));
7899
- }
7981
+ const modifiedInput = plainTextValue.substring(0, plainTextValue.length - 1);
7982
+ setText(modifiedInput);
7900
7983
  };
7901
7984
  return (React__default['default'].createElement("div", { className: react.mergeStyles(containerStyles$1(theme), (_a = props.styles) === null || _a === void 0 ? void 0 : _a.root), "data-test-id": "dialpadContainer", "data-ui-id": "dialpadContainer" },
7902
- React__default['default'].createElement(react.TextField, { styles: react.concatStyleSets(textFieldStyles(theme), (_b = props.styles) === null || _b === void 0 ? void 0 : _b.textField), value: onDisplayDialpadInput ? onDisplayDialpadInput(textValue) : formatPhoneNumber(textValue),
7985
+ React__default['default'].createElement(react.TextField, { styles: react.concatStyleSets(textFieldStyles(theme), (_b = props.styles) === null || _b === void 0 ? void 0 : _b.textField), value: textFieldValue ? textFieldValue : formatPhoneNumber(plainTextValue),
7903
7986
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
7904
7987
  onChange: (e) => {
7905
- setText(e);
7906
- // remove non-valid characters from input: letters,special characters excluding +, *,#
7907
- const input = sanitizeInput(e.target.value);
7908
- if (onChange) {
7909
- onChange(onDisplayDialpadInput ? onDisplayDialpadInput(input) : formatPhoneNumber(input));
7910
- }
7988
+ setText(e.target.value);
7911
7989
  }, placeholder: props.strings.placeholderText, "data-test-id": "dialpad-input", onRenderSuffix: () => {
7912
7990
  var _a;
7913
- return (React__default['default'].createElement(React__default['default'].Fragment, null, showDeleteButton && textValue.length !== 0 && (React__default['default'].createElement(react.IconButton, { ariaLabel: props.strings.deleteButtonAriaLabel, onClick: deleteNumbers, styles: react.concatStyleSets(iconButtonStyles(theme), (_a = props.styles) === null || _a === void 0 ? void 0 : _a.deleteIcon), iconProps: { iconName: 'BackSpace' } }))));
7991
+ return (React__default['default'].createElement(React__default['default'].Fragment, null, showDeleteButton && plainTextValue.length !== 0 && (React__default['default'].createElement(react.IconButton, { ariaLabel: props.strings.deleteButtonAriaLabel, onClick: deleteNumbers, styles: react.concatStyleSets(iconButtonStyles(theme), (_a = props.styles) === null || _a === void 0 ? void 0 : _a.deleteIcon), iconProps: { iconName: 'BackSpace' } }))));
7914
7992
  } }),
7915
7993
  React__default['default'].createElement(react.FocusZone, null, dialPadButtonsDefault.map((rows, rowIndex) => {
7916
7994
  return (React__default['default'].createElement(react.Stack, { horizontal: true, key: `row_${rowIndex}`, horizontalAlign: "stretch" }, rows.map((button, columnIndex) => (React__default['default'].createElement(DialpadButton, { key: `button_${columnIndex}`,
@@ -7931,7 +8009,7 @@ const DialpadContainer = (props) => {
7931
8009
  then use this index to locate the corresponding dtmf tones
7932
8010
  DtmfTones[index]
7933
8011
  */
7934
- index: columnIndex + rowIndex * rows.length, primaryContent: button.primaryContent, secondaryContent: button.secondaryContent, styles: props.styles, onClick: onClickDialpad })))));
8012
+ index: columnIndex + rowIndex * rows.length, primaryContent: button.primaryContent, secondaryContent: button.secondaryContent, styles: props.styles, onClick: onClickDialpad, onLongPress: onLongPressDialpad })))));
7935
8013
  }))));
7936
8014
  };
7937
8015
  /**
@@ -7950,6 +8028,10 @@ const Dialpad = (props) => {
7950
8028
  const strings = Object.assign(Object.assign({}, dialpadLocaleStringsTrampoline()), props.strings);
7951
8029
  return React__default['default'].createElement(DialpadContainer, Object.assign({ strings: strings }, props));
7952
8030
  };
8031
+ const sanitizeInput = (input) => {
8032
+ // remove non-valid characters from input: letters,special characters excluding +, *,#
8033
+ return input.replace(/[^\d*#+]/g, '');
8034
+ };
7953
8035
 
7954
8036
  // Copyright (c) Microsoft Corporation.
7955
8037
  /**
@@ -7964,7 +8046,7 @@ const Dialpad = (props) => {
7964
8046
  const HoldButton = (props) => {
7965
8047
  const { onToggleHold, strings } = props;
7966
8048
  const onRenderHoldIcon = () => {
7967
- return React__default['default'].createElement(HighContrastAwareIcon, { disabled: props.disabled, iconName: "HoldCall" });
8049
+ return React__default['default'].createElement(HighContrastAwareIcon, { disabled: props.disabled, iconName: "HoldCallButton" });
7968
8050
  };
7969
8051
  const onRenderResumeIcon = () => {
7970
8052
  return React__default['default'].createElement(HighContrastAwareIcon, { disabled: props.disabled, iconName: "ResumeCall" });
@@ -8414,7 +8496,7 @@ const findConditionalCompiledSelector = (component) => {
8414
8496
 
8415
8497
  // Copyright (c) Microsoft Corporation.
8416
8498
  // Licensed under the MIT license.
8417
- var __awaiter$n = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
8499
+ var __awaiter$o = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
8418
8500
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
8419
8501
  return new (P || (P = Promise))(function (resolve, reject) {
8420
8502
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -8437,35 +8519,35 @@ const createDefaultChatHandlers = memoizeOne__default['default']((chatClient, ch
8437
8519
  let messageIterator = undefined;
8438
8520
  let readReceiptIterator = undefined;
8439
8521
  return {
8440
- onSendMessage: (content, options) => __awaiter$n(void 0, void 0, void 0, function* () {
8522
+ onSendMessage: (content, options) => __awaiter$o(void 0, void 0, void 0, function* () {
8441
8523
  const sendMessageRequest = {
8442
8524
  content,
8443
8525
  senderDisplayName: chatClient.getState().displayName
8444
8526
  };
8445
8527
  yield chatThreadClient.sendMessage(sendMessageRequest, options);
8446
8528
  }),
8447
- onUpdateMessage: (messageId, content, metadata, options) => __awaiter$n(void 0, void 0, void 0, function* () {
8529
+ onUpdateMessage: (messageId, content, metadata, options) => __awaiter$o(void 0, void 0, void 0, function* () {
8448
8530
  const updatedMetadata = metadata ? Object.assign({}, metadata) : {};
8449
8531
  updatedMetadata['fileSharingMetadata'] = JSON.stringify((options === null || options === void 0 ? void 0 : options.attachedFilesMetadata) || []);
8450
8532
  yield chatThreadClient.updateMessage(messageId, { content, metadata: updatedMetadata });
8451
8533
  }),
8452
- onDeleteMessage: (messageId) => __awaiter$n(void 0, void 0, void 0, function* () {
8534
+ onDeleteMessage: (messageId) => __awaiter$o(void 0, void 0, void 0, function* () {
8453
8535
  yield chatThreadClient.deleteMessage(messageId);
8454
8536
  }),
8455
8537
  // This handler is designed for chatThread to consume
8456
- onMessageSeen: (chatMessageId) => __awaiter$n(void 0, void 0, void 0, function* () {
8538
+ onMessageSeen: (chatMessageId) => __awaiter$o(void 0, void 0, void 0, function* () {
8457
8539
  yield chatThreadClient.sendReadReceipt({ chatMessageId });
8458
8540
  }),
8459
- onTyping: () => __awaiter$n(void 0, void 0, void 0, function* () {
8541
+ onTyping: () => __awaiter$o(void 0, void 0, void 0, function* () {
8460
8542
  yield chatThreadClient.sendTypingNotification();
8461
8543
  }),
8462
- onRemoveParticipant: (userId) => __awaiter$n(void 0, void 0, void 0, function* () {
8544
+ onRemoveParticipant: (userId) => __awaiter$o(void 0, void 0, void 0, function* () {
8463
8545
  yield chatThreadClient.removeParticipant(fromFlatCommunicationIdentifier(userId));
8464
8546
  }),
8465
- updateThreadTopicName: (topicName) => __awaiter$n(void 0, void 0, void 0, function* () {
8547
+ updateThreadTopicName: (topicName) => __awaiter$o(void 0, void 0, void 0, function* () {
8466
8548
  yield chatThreadClient.updateTopic(topicName);
8467
8549
  }),
8468
- onLoadPreviousChatMessages: (messagesToLoad) => __awaiter$n(void 0, void 0, void 0, function* () {
8550
+ onLoadPreviousChatMessages: (messagesToLoad) => __awaiter$o(void 0, void 0, void 0, function* () {
8469
8551
  var _a, _b, _c;
8470
8552
  if (messageIterator === undefined) {
8471
8553
  // Lazy definition so that errors in the method call are reported correctly.
@@ -9156,7 +9238,7 @@ const findSelector = (component) => {
9156
9238
 
9157
9239
  // Copyright (c) Microsoft Corporation.
9158
9240
  // Licensed under the MIT license.
9159
- var __awaiter$m = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
9241
+ var __awaiter$n = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
9160
9242
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
9161
9243
  return new (P || (P = Promise))(function (resolve, reject) {
9162
9244
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -9205,10 +9287,10 @@ class ProxyDeviceManager {
9205
9287
  this.selectCamera = (videoDeviceInfo) => {
9206
9288
  this._context.setDeviceManagerSelectedCamera(videoDeviceInfo);
9207
9289
  };
9208
- this.videoDevicesUpdated = () => __awaiter$m(this, void 0, void 0, function* () {
9290
+ this.videoDevicesUpdated = () => __awaiter$n(this, void 0, void 0, function* () {
9209
9291
  this._context.setDeviceManagerCameras(dedupeById(yield this._deviceManager.getCameras()));
9210
9292
  });
9211
- this.audioDevicesUpdated = () => __awaiter$m(this, void 0, void 0, function* () {
9293
+ this.audioDevicesUpdated = () => __awaiter$n(this, void 0, void 0, function* () {
9212
9294
  this._context.setDeviceManagerMicrophones(dedupeById(yield this._deviceManager.getMicrophones()));
9213
9295
  this._context.setDeviceManagerSpeakers(dedupeById(yield this._deviceManager.getSpeakers()));
9214
9296
  });
@@ -9411,7 +9493,7 @@ class CallIdHistory {
9411
9493
 
9412
9494
  // Copyright (c) Microsoft Corporation.
9413
9495
  // Licensed under the MIT license.
9414
- var __awaiter$l = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
9496
+ var __awaiter$m = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
9415
9497
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
9416
9498
  return new (P || (P = Promise))(function (resolve, reject) {
9417
9499
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -9896,7 +9978,7 @@ class CallContext$1 {
9896
9978
  * @throws CallError. Exceptions thrown from `f` are tagged with the failed `target.
9897
9979
  */
9898
9980
  withAsyncErrorTeedToState(action, target) {
9899
- return (...args) => __awaiter$l(this, void 0, void 0, function* () {
9981
+ return (...args) => __awaiter$m(this, void 0, void 0, function* () {
9900
9982
  try {
9901
9983
  return yield action(...args);
9902
9984
  }
@@ -9960,7 +10042,7 @@ const findOldestCallEnded = (calls) => {
9960
10042
 
9961
10043
  // Copyright (c) Microsoft Corporation.
9962
10044
  // Licensed under the MIT license.
9963
- var __awaiter$k = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
10045
+ var __awaiter$l = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
9964
10046
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
9965
10047
  return new (P || (P = Promise))(function (resolve, reject) {
9966
10048
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -9980,63 +10062,63 @@ class ProxyCall {
9980
10062
  switch (prop) {
9981
10063
  case 'mute': {
9982
10064
  return this._context.withAsyncErrorTeedToState(function (...args) {
9983
- return __awaiter$k(this, void 0, void 0, function* () {
10065
+ return __awaiter$l(this, void 0, void 0, function* () {
9984
10066
  return yield target.mute(...args);
9985
10067
  });
9986
10068
  }, 'Call.mute');
9987
10069
  }
9988
10070
  case 'unmute': {
9989
10071
  return this._context.withAsyncErrorTeedToState(function (...args) {
9990
- return __awaiter$k(this, void 0, void 0, function* () {
10072
+ return __awaiter$l(this, void 0, void 0, function* () {
9991
10073
  return yield target.unmute(...args);
9992
10074
  });
9993
10075
  }, 'Call.unmute');
9994
10076
  }
9995
10077
  case 'startVideo': {
9996
10078
  return this._context.withAsyncErrorTeedToState(function (...args) {
9997
- return __awaiter$k(this, void 0, void 0, function* () {
10079
+ return __awaiter$l(this, void 0, void 0, function* () {
9998
10080
  return yield target.startVideo(...args);
9999
10081
  });
10000
10082
  }, 'Call.startVideo');
10001
10083
  }
10002
10084
  case 'stopVideo': {
10003
10085
  return this._context.withAsyncErrorTeedToState(function (...args) {
10004
- return __awaiter$k(this, void 0, void 0, function* () {
10086
+ return __awaiter$l(this, void 0, void 0, function* () {
10005
10087
  return yield target.stopVideo(...args);
10006
10088
  });
10007
10089
  }, 'Call.stopVideo');
10008
10090
  }
10009
10091
  case 'startScreenSharing': {
10010
10092
  return this._context.withAsyncErrorTeedToState(function (...args) {
10011
- return __awaiter$k(this, void 0, void 0, function* () {
10093
+ return __awaiter$l(this, void 0, void 0, function* () {
10012
10094
  return yield target.startScreenSharing(...args);
10013
10095
  });
10014
10096
  }, 'Call.startScreenSharing');
10015
10097
  }
10016
10098
  case 'stopScreenSharing': {
10017
10099
  return this._context.withAsyncErrorTeedToState(function (...args) {
10018
- return __awaiter$k(this, void 0, void 0, function* () {
10100
+ return __awaiter$l(this, void 0, void 0, function* () {
10019
10101
  return yield target.stopScreenSharing(...args);
10020
10102
  });
10021
10103
  }, 'Call.stopScreenSharing');
10022
10104
  }
10023
10105
  case 'hold': {
10024
10106
  return this._context.withAsyncErrorTeedToState(function (...args) {
10025
- return __awaiter$k(this, void 0, void 0, function* () {
10107
+ return __awaiter$l(this, void 0, void 0, function* () {
10026
10108
  return yield target.hold(...args);
10027
10109
  });
10028
10110
  }, 'Call.hold');
10029
10111
  }
10030
10112
  case 'resume': {
10031
10113
  return this._context.withAsyncErrorTeedToState(function (...args) {
10032
- return __awaiter$k(this, void 0, void 0, function* () {
10114
+ return __awaiter$l(this, void 0, void 0, function* () {
10033
10115
  return yield target.resume(...args);
10034
10116
  });
10035
10117
  }, 'Call.resume');
10036
10118
  }
10037
10119
  case 'addParticipant': {
10038
10120
  return this._context.withAsyncErrorTeedToState(function (...args) {
10039
- return __awaiter$k(this, void 0, void 0, function* () {
10121
+ return __awaiter$l(this, void 0, void 0, function* () {
10040
10122
  return yield target.addParticipant(...args);
10041
10123
  });
10042
10124
  }, 'Call.addParticipant');
@@ -10244,7 +10326,7 @@ class RemoteVideoStreamSubscriber {
10244
10326
 
10245
10327
  // Copyright (c) Microsoft Corporation.
10246
10328
  // Licensed under the MIT license.
10247
- var __awaiter$j = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
10329
+ var __awaiter$k = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
10248
10330
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
10249
10331
  return new (P || (P = Promise))(function (resolve, reject) {
10250
10332
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -10254,7 +10336,7 @@ var __awaiter$j = (window && window.__awaiter) || function (thisArg, _arguments,
10254
10336
  });
10255
10337
  };
10256
10338
  function createViewRemoteVideo(context, internalContext, callId, participantId, stream, options) {
10257
- return __awaiter$j(this, void 0, void 0, function* () {
10339
+ return __awaiter$k(this, void 0, void 0, function* () {
10258
10340
  // Render RemoteVideoStream that is part of a Call
10259
10341
  const streamId = stream.id;
10260
10342
  let participantKey;
@@ -10362,7 +10444,7 @@ function createViewRemoteVideo(context, internalContext, callId, participantId,
10362
10444
  });
10363
10445
  }
10364
10446
  function createViewLocalVideo(context, internalContext, callId, options) {
10365
- return __awaiter$j(this, void 0, void 0, function* () {
10447
+ return __awaiter$k(this, void 0, void 0, function* () {
10366
10448
  _logEvent(callingStatefulLogger, {
10367
10449
  name: EventNames.START_LOCAL_STREAM_RENDERING,
10368
10450
  level: 'info',
@@ -10478,7 +10560,7 @@ function createViewLocalVideo(context, internalContext, callId, options) {
10478
10560
  });
10479
10561
  }
10480
10562
  function createViewUnparentedVideo(context, internalContext, stream, options) {
10481
- return __awaiter$j(this, void 0, void 0, function* () {
10563
+ return __awaiter$k(this, void 0, void 0, function* () {
10482
10564
  const renderInfo = internalContext.getUnparentedRenderInfo(stream);
10483
10565
  if (renderInfo && renderInfo.status === 'Rendered') {
10484
10566
  console.warn('Unparented LocalVideoStream is already rendered');
@@ -11106,7 +11188,7 @@ class CallSubscriber {
11106
11188
 
11107
11189
  // Copyright (c) Microsoft Corporation.
11108
11190
  // Licensed under the MIT license.
11109
- var __awaiter$i = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
11191
+ var __awaiter$j = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
11110
11192
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
11111
11193
  return new (P || (P = Promise))(function (resolve, reject) {
11112
11194
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -11126,14 +11208,14 @@ class ProxyIncomingCall {
11126
11208
  switch (prop) {
11127
11209
  case 'accept': {
11128
11210
  return this._context.withAsyncErrorTeedToState(function (...args) {
11129
- return __awaiter$i(this, void 0, void 0, function* () {
11211
+ return __awaiter$j(this, void 0, void 0, function* () {
11130
11212
  return yield target.accept(...args);
11131
11213
  });
11132
11214
  }, 'IncomingCall.accept');
11133
11215
  }
11134
11216
  case 'reject': {
11135
11217
  return this._context.withAsyncErrorTeedToState(function (...args) {
11136
- return __awaiter$i(this, void 0, void 0, function* () {
11218
+ return __awaiter$j(this, void 0, void 0, function* () {
11137
11219
  return yield target.reject(...args);
11138
11220
  });
11139
11221
  }, 'IncomingCall.reject');
@@ -11471,7 +11553,7 @@ class InternalCallContext {
11471
11553
 
11472
11554
  // Copyright (c) Microsoft Corporation.
11473
11555
  // Licensed under the MIT license.
11474
- var __awaiter$h = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
11556
+ var __awaiter$i = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
11475
11557
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
11476
11558
  return new (P || (P = Promise))(function (resolve, reject) {
11477
11559
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -11493,7 +11575,7 @@ class ProxyCallClient {
11493
11575
  get(target, prop) {
11494
11576
  switch (prop) {
11495
11577
  case 'createCallAgent': {
11496
- return this._context.withAsyncErrorTeedToState((...args) => __awaiter$h(this, void 0, void 0, function* () {
11578
+ return this._context.withAsyncErrorTeedToState((...args) => __awaiter$i(this, void 0, void 0, function* () {
11497
11579
  // createCallAgent will throw an exception if the previous callAgent was not disposed. If the previous
11498
11580
  // callAgent was disposed then it would have unsubscribed to events so we can just create a new declarative
11499
11581
  // callAgent if the createCallAgent succeeds.
@@ -11506,7 +11588,7 @@ class ProxyCallClient {
11506
11588
  }), 'CallClient.createCallAgent');
11507
11589
  }
11508
11590
  case 'getDeviceManager': {
11509
- return this._context.withAsyncErrorTeedToState(() => __awaiter$h(this, void 0, void 0, function* () {
11591
+ return this._context.withAsyncErrorTeedToState(() => __awaiter$i(this, void 0, void 0, function* () {
11510
11592
  // As of writing, the SDK always returns the same instance of DeviceManager so we keep a reference of
11511
11593
  // DeviceManager and if it does not change we return the cached DeclarativeDeviceManager. If it does not we'll
11512
11594
  // throw an error that indicate we need to fix this issue as our implementation has diverged from the SDK.
@@ -11629,7 +11711,7 @@ const chatStatefulLogger = logger.createClientLogger('communication-react:chat-s
11629
11711
 
11630
11712
  // Copyright (c) Microsoft Corporation.
11631
11713
  // Licensed under the MIT license.
11632
- var __awaiter$g = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
11714
+ var __awaiter$h = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
11633
11715
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
11634
11716
  return new (P || (P = Promise))(function (resolve, reject) {
11635
11717
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -11904,7 +11986,7 @@ class ChatContext$1 {
11904
11986
  * @throws ChatError. Exceptions thrown from `f` are tagged with the failed `target.
11905
11987
  */
11906
11988
  withAsyncErrorTeedToState(f, target) {
11907
- return (...args) => __awaiter$g(this, void 0, void 0, function* () {
11989
+ return (...args) => __awaiter$h(this, void 0, void 0, function* () {
11908
11990
  try {
11909
11991
  return yield f(...args);
11910
11992
  }
@@ -12011,7 +12093,7 @@ const convertChatMessage = (message, status = 'delivered', clientMessageId) => {
12011
12093
 
12012
12094
  // Copyright (c) Microsoft Corporation.
12013
12095
  // Licensed under the MIT license.
12014
- var __awaiter$f = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
12096
+ var __awaiter$g = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
12015
12097
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
12016
12098
  return new (P || (P = Promise))(function (resolve, reject) {
12017
12099
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -12095,7 +12177,7 @@ class EventSubscriber {
12095
12177
  this.fetchLastParticipantMessage(event.threadId, 'participantAdded');
12096
12178
  };
12097
12179
  // This is a hot fix that no participant message is received for onChatMessageReceived event, which should be handled by JS SDK
12098
- this.fetchLastParticipantMessage = (threadId, actionType) => __awaiter$f(this, void 0, void 0, function* () {
12180
+ this.fetchLastParticipantMessage = (threadId, actionType) => __awaiter$g(this, void 0, void 0, function* () {
12099
12181
  var e_1, _a;
12100
12182
  try {
12101
12183
  for (var _b = __asyncValues$1(this.chatClient
@@ -12181,7 +12263,7 @@ class EventSubscriber {
12181
12263
 
12182
12264
  // Copyright (c) Microsoft Corporation.
12183
12265
  // Licensed under the MIT license.
12184
- var __awaiter$e = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
12266
+ var __awaiter$f = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
12185
12267
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
12186
12268
  return new (P || (P = Promise))(function (resolve, reject) {
12187
12269
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -12203,7 +12285,7 @@ const createDecoratedIterator = (iteratorCreator, context, decorateFn) => {
12203
12285
  const threadsIterator = iteratorCreator(...args);
12204
12286
  return {
12205
12287
  next() {
12206
- return __awaiter$e(this, void 0, void 0, function* () {
12288
+ return __awaiter$f(this, void 0, void 0, function* () {
12207
12289
  const result = yield threadsIterator.next();
12208
12290
  if (!result.done && result.value) {
12209
12291
  decorateFn(result.value, context);
@@ -12218,7 +12300,7 @@ const createDecoratedIterator = (iteratorCreator, context, decorateFn) => {
12218
12300
  const pages = threadsIterator.byPage(settings);
12219
12301
  return {
12220
12302
  next() {
12221
- return __awaiter$e(this, void 0, void 0, function* () {
12303
+ return __awaiter$f(this, void 0, void 0, function* () {
12222
12304
  const result = yield pages.next();
12223
12305
  const page = result.value;
12224
12306
  if (!result.done && result.value) {
@@ -12302,7 +12384,7 @@ const createDecoratedListParticipants = (chatThreadClient, context) => {
12302
12384
 
12303
12385
  // Copyright (c) Microsoft Corporation.
12304
12386
  // Licensed under the MIT license.
12305
- var __awaiter$d = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
12387
+ var __awaiter$e = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
12306
12388
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
12307
12389
  return new (P || (P = Promise))(function (resolve, reject) {
12308
12390
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -12321,14 +12403,14 @@ class ProxyChatThreadClient {
12321
12403
  return createDecoratedListMessages(chatThreadClient, this._context);
12322
12404
  }
12323
12405
  case 'getMessage': {
12324
- return this._context.withAsyncErrorTeedToState((...args) => __awaiter$d(this, void 0, void 0, function* () {
12406
+ return this._context.withAsyncErrorTeedToState((...args) => __awaiter$e(this, void 0, void 0, function* () {
12325
12407
  const message = yield chatThreadClient.getMessage(...args);
12326
12408
  this._context.setChatMessage(chatThreadClient.threadId, convertChatMessage(message));
12327
12409
  return message;
12328
12410
  }), 'ChatThreadClient.getMessage');
12329
12411
  }
12330
12412
  case 'sendMessage': {
12331
- return this._context.withAsyncErrorTeedToState((...args) => __awaiter$d(this, void 0, void 0, function* () {
12413
+ return this._context.withAsyncErrorTeedToState((...args) => __awaiter$e(this, void 0, void 0, function* () {
12332
12414
  // Retry logic?
12333
12415
  const [request, options] = args;
12334
12416
  const { content } = request;
@@ -12368,7 +12450,7 @@ class ProxyChatThreadClient {
12368
12450
  }), 'ChatThreadClient.sendMessage');
12369
12451
  }
12370
12452
  case 'addParticipants': {
12371
- return this._context.withAsyncErrorTeedToState((...args) => __awaiter$d(this, void 0, void 0, function* () {
12453
+ return this._context.withAsyncErrorTeedToState((...args) => __awaiter$e(this, void 0, void 0, function* () {
12372
12454
  const result = yield chatThreadClient.addParticipants(...args);
12373
12455
  const [addRequest] = args;
12374
12456
  const participantsToAdd = addRequest.participants;
@@ -12377,7 +12459,7 @@ class ProxyChatThreadClient {
12377
12459
  }), 'ChatThreadClient.addParticipants');
12378
12460
  }
12379
12461
  case 'deleteMessage': {
12380
- return this._context.withAsyncErrorTeedToState((...args) => __awaiter$d(this, void 0, void 0, function* () {
12462
+ return this._context.withAsyncErrorTeedToState((...args) => __awaiter$e(this, void 0, void 0, function* () {
12381
12463
  // DeleteMessage is able to either delete local one(for failed message) or synced message
12382
12464
  const [messageId] = args;
12383
12465
  if (this._context.deleteLocalMessage(chatThreadClient.threadId, messageId)) {
@@ -12395,7 +12477,7 @@ class ProxyChatThreadClient {
12395
12477
  return createDecoratedListReadReceipts(chatThreadClient, this._context);
12396
12478
  }
12397
12479
  case 'removeParticipant': {
12398
- return this._context.withAsyncErrorTeedToState((...args) => __awaiter$d(this, void 0, void 0, function* () {
12480
+ return this._context.withAsyncErrorTeedToState((...args) => __awaiter$e(this, void 0, void 0, function* () {
12399
12481
  const result = yield chatThreadClient.removeParticipant(...args);
12400
12482
  const [removeIdentifier] = args;
12401
12483
  this._context.deleteParticipant(chatThreadClient.threadId, communicationCommon.getIdentifierKind(removeIdentifier));
@@ -12403,7 +12485,7 @@ class ProxyChatThreadClient {
12403
12485
  }), 'ChatThreadClient.removeParticipant');
12404
12486
  }
12405
12487
  case 'updateMessage': {
12406
- return this._context.withAsyncErrorTeedToState((...args) => __awaiter$d(this, void 0, void 0, function* () {
12488
+ return this._context.withAsyncErrorTeedToState((...args) => __awaiter$e(this, void 0, void 0, function* () {
12407
12489
  const result = yield chatThreadClient.updateMessage(...args);
12408
12490
  const [messageId, updateOption] = args;
12409
12491
  this._context.updateChatMessageContent(chatThreadClient.threadId, messageId, updateOption === null || updateOption === void 0 ? void 0 : updateOption.content);
@@ -12411,7 +12493,7 @@ class ProxyChatThreadClient {
12411
12493
  }), 'ChatThreadClient.updateMessage');
12412
12494
  }
12413
12495
  case 'updateTopic': {
12414
- return this._context.withAsyncErrorTeedToState((...args) => __awaiter$d(this, void 0, void 0, function* () {
12496
+ return this._context.withAsyncErrorTeedToState((...args) => __awaiter$e(this, void 0, void 0, function* () {
12415
12497
  const result = yield chatThreadClient.updateTopic(...args);
12416
12498
  const [topic] = args;
12417
12499
  this._context.updateThreadTopic(chatThreadClient.threadId, topic);
@@ -12419,7 +12501,7 @@ class ProxyChatThreadClient {
12419
12501
  }), 'ChatThreadClient.updateTopic');
12420
12502
  }
12421
12503
  case 'getProperties': {
12422
- return this._context.withAsyncErrorTeedToState((...args) => __awaiter$d(this, void 0, void 0, function* () {
12504
+ return this._context.withAsyncErrorTeedToState((...args) => __awaiter$e(this, void 0, void 0, function* () {
12423
12505
  const result = yield chatThreadClient.getProperties(...args);
12424
12506
  this._context.updateThread(chatThreadClient.threadId, result);
12425
12507
  return result;
@@ -12456,7 +12538,7 @@ const createDecoratedListThreads = (chatClient, context) => {
12456
12538
 
12457
12539
  // Copyright (c) Microsoft Corporation.
12458
12540
  // Licensed under the MIT license.
12459
- var __awaiter$c = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
12541
+ var __awaiter$d = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
12460
12542
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
12461
12543
  return new (P || (P = Promise))(function (resolve, reject) {
12462
12544
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -12475,7 +12557,7 @@ const proxyChatClient = {
12475
12557
  switch (prop) {
12476
12558
  case 'createChatThread': {
12477
12559
  return context.withAsyncErrorTeedToState(function (...args) {
12478
- return __awaiter$c(this, void 0, void 0, function* () {
12560
+ return __awaiter$d(this, void 0, void 0, function* () {
12479
12561
  const result = yield chatClient.createChatThread(...args);
12480
12562
  const thread = result.chatThread;
12481
12563
  if (thread) {
@@ -12488,7 +12570,7 @@ const proxyChatClient = {
12488
12570
  }
12489
12571
  case 'deleteChatThread': {
12490
12572
  return context.withAsyncErrorTeedToState(function (...args) {
12491
- return __awaiter$c(this, void 0, void 0, function* () {
12573
+ return __awaiter$d(this, void 0, void 0, function* () {
12492
12574
  const result = yield chatClient.deleteChatThread(...args);
12493
12575
  context.deleteThread(args[0]);
12494
12576
  return result;
@@ -12508,7 +12590,7 @@ const proxyChatClient = {
12508
12590
  }
12509
12591
  case 'startRealtimeNotifications': {
12510
12592
  return context.withAsyncErrorTeedToState(function (...args) {
12511
- return __awaiter$c(this, void 0, void 0, function* () {
12593
+ return __awaiter$d(this, void 0, void 0, function* () {
12512
12594
  const ret = yield chatClient.startRealtimeNotifications(...args);
12513
12595
  if (!receiver.eventSubscriber) {
12514
12596
  receiver.eventSubscriber = new EventSubscriber(chatClient, context);
@@ -12519,7 +12601,7 @@ const proxyChatClient = {
12519
12601
  }
12520
12602
  case 'stopRealtimeNotifications': {
12521
12603
  return context.withAsyncErrorTeedToState(function (...args) {
12522
- return __awaiter$c(this, void 0, void 0, function* () {
12604
+ return __awaiter$d(this, void 0, void 0, function* () {
12523
12605
  const ret = yield chatClient.stopRealtimeNotifications(...args);
12524
12606
  if (receiver.eventSubscriber) {
12525
12607
  receiver.eventSubscriber.unsubscribe();
@@ -12706,7 +12788,7 @@ const CallCompositeIcon = (props) => (React__default['default'].createElement(re
12706
12788
  */
12707
12789
  const CallWithChatCompositeIcon = (props) => (React__default['default'].createElement(react.FontIcon, Object.assign({}, props)));
12708
12790
 
12709
- var call$d={cameraLabel:"Camera",cameraPermissionDenied:"Your browser is blocking access to your camera",cameraTurnedOff:"Your camera is turned off",chatButtonLabel:"Chat",close:"Close",complianceBannerNowOnlyRecording:"You are now only recording this meeting.",complianceBannerNowOnlyTranscription:"You are now only transcribing this meeting.",complianceBannerRecordingAndTranscriptionSaved:"Recording and transcription are being saved.",complianceBannerRecordingAndTranscriptionStarted:"Recording and transcription have started.",complianceBannerRecordingAndTranscriptionStopped:"Recording and transcription have stopped.",complianceBannerRecordingSaving:"Recording is being saved.",complianceBannerRecordingStarted:"Recording has started.",complianceBannerRecordingStopped:"Recording has stopped.",complianceBannerTranscriptionStarted:"Transcription has started.",complianceBannerTranscriptionConsent:"By joining, you are giving consent for this meeting to be transcribed.",complianceBannerTranscriptionSaving:"Transcription is being saved.",complianceBannerTranscriptionStopped:"Transcription has stopped.",configurationPageTitle:"Start a call",copyInviteLinkButtonLabel:"Copy invite link",defaultPlaceHolder:"Select an option",dismissSidePaneButtonLabel:"Close",failedToJoinCallDueToNoNetworkMoreDetails:"Call was disconnected due to a network issue. Check your connection and join again.",failedToJoinCallDueToNoNetworkTitle:"Call disconnected",failedToJoinTeamsMeetingReasonAccessDeniedMoreDetails:"You were not granted entry in the call. If this was a mistake, re-join the call.",failedToJoinTeamsMeetingReasonAccessDeniedTitle:"Dismissed from lobby",learnMore:"Learn more",leftCallMoreDetails:"If this was a mistake, re-join the call.",leftCallTitle:"You left the call",lobbyScreenConnectingToCallTitle:"Joining call",lobbyScreenWaitingToBeAdmittedTitle:"Waiting to be admitted",microphonePermissionDenied:"Your browser is blocking access to your microphone",microphoneToggleInLobbyNotAllowed:"Cannot mute or unmute while in lobby.",mutedMessage:"You're muted",networkReconnectMoreDetails:"Looks like something went wrong. We're trying to get back into the call.",networkReconnectTitle:"Hold on",peopleButtonLabel:"People",peoplePaneTitle:"People",peoplePaneSubTitle:"In this call",privacyPolicy:"Privacy policy",rejoinCallButtonLabel:"Re-join call",removedFromCallMoreDetails:"Another participant removed you from the call.",removedFromCallTitle:"You were removed",removeMenuLabel:"Remove",returnToCallButtonAriaDescription:"Return to Call",returnToCallButtonAriaLabel:"Back",soundLabel:"Sound",startCallButtonLabel:"Start call",openDialpadButtonLabel:"Dial phone number",peoplePaneAddPeopleButtonLabel:"Add People",dialpadStartCallButtonLabel:"Call",dialpadModalTitle:"Dial Phone Number",dialpadModalAriaLabel:"Dialpad",dialpadCloseModalButtonAriaLabel:"Close Dialpad",moreButtonCallingLabel:"More",resumeCallButtonLabel:"Resume",resumeCallButtonAriaLabel:"Resume call",holdScreenLabel:"You're on hold",openDtmfDialpadLabel:"Show Dialpad",dtmfDialpadPlaceHolderText:"Enter number"};var chat$d={chatListHeader:"In this chat",uploadFile:"Upload File"};var callWithChat$d={chatButtonLabel:"Chat",chatButtonNewMessageNotificationLabel:"New Message",chatButtonTooltipClosedWithMessageCount:"Show chat ({unreadMessagesCount} unread)",chatButtonTooltipClose:"Hide chat",chatButtonTooltipOpen:"Show chat",chatPaneTitle:"Chat",copyInviteLinkButtonLabel:"Copy invite link",dismissSidePaneButtonLabel:"Close",moreDrawerAudioDeviceMenuTitle:"Audio Device",moreDrawerButtonLabel:"More options",moreDrawerButtonTooltip:"More options",moreDrawerMicrophoneMenuTitle:"Microphone",moreDrawerSpeakerMenuTitle:"Speaker",peopleButtonLabel:"People",peopleButtonTooltipOpen:"Show participants",peopleButtonTooltipClose:"Hide participants",peoplePaneSubTitle:"In this call",peoplePaneTitle:"People",pictureInPictureTileAriaLabel:"Video Feeds. Click to return to call screen.",removeMenuLabel:"Remove",openDialpadButtonLabel:"Dial phone number",returnToCallButtonAriaDescription:"Return to Call",returnToCallButtonAriaLabel:"Back",peoplePaneAddPeopleButtonLabel:"Add People",dialpadStartCallButtonLabel:"Call",dialpadModalTitle:"Dial Phone Number",dialpadModalAriaLabel:"Dialpad",dialpadCloseModalButtonAriaLabel:"Close Dialpad",openDtmfDialpadLabel:"Show Dialpad",dtmfDialpadPlaceHolderText:"Enter number"};var en_US = {call:call$d,chat:chat$d,callWithChat:callWithChat$d};
12791
+ var call$d={cameraLabel:"Camera",cameraPermissionDenied:"Your browser is blocking access to your camera",cameraTurnedOff:"Your camera is turned off",chatButtonLabel:"Chat",close:"Close",complianceBannerNowOnlyRecording:"You are now only recording this meeting.",complianceBannerNowOnlyTranscription:"You are now only transcribing this meeting.",complianceBannerRecordingAndTranscriptionSaved:"Recording and transcription are being saved.",complianceBannerRecordingAndTranscriptionStarted:"Recording and transcription have started.",complianceBannerRecordingAndTranscriptionStopped:"Recording and transcription have stopped.",complianceBannerRecordingSaving:"Recording is being saved.",complianceBannerRecordingStarted:"Recording has started.",complianceBannerRecordingStopped:"Recording has stopped.",complianceBannerTranscriptionStarted:"Transcription has started.",complianceBannerTranscriptionConsent:"By joining, you are giving consent for this meeting to be transcribed.",complianceBannerTranscriptionSaving:"Transcription is being saved.",complianceBannerTranscriptionStopped:"Transcription has stopped.",configurationPageTitle:"Start a call",copyInviteLinkButtonLabel:"Copy invite link",defaultPlaceHolder:"Select an option",dismissSidePaneButtonLabel:"Close",failedToJoinCallDueToNoNetworkMoreDetails:"Call was disconnected due to a network issue. Check your connection and join again.",failedToJoinCallDueToNoNetworkTitle:"Call disconnected",failedToJoinTeamsMeetingReasonAccessDeniedMoreDetails:"You were not granted entry in the call. If this was a mistake, re-join the call.",failedToJoinTeamsMeetingReasonAccessDeniedTitle:"Dismissed from lobby",learnMore:"Learn more",leftCallMoreDetails:"If this was a mistake, re-join the call.",leftCallTitle:"You left the call",lobbyScreenConnectingToCallTitle:"Joining call",lobbyScreenWaitingToBeAdmittedTitle:"Waiting to be admitted",microphonePermissionDenied:"Your browser is blocking access to your microphone",microphoneToggleInLobbyNotAllowed:"Cannot mute or unmute while in lobby.",mutedMessage:"You're muted",networkReconnectMoreDetails:"Looks like something went wrong. We're trying to get back into the call.",networkReconnectTitle:"Hold on",peopleButtonLabel:"People",peoplePaneTitle:"People",peoplePaneSubTitle:"In this call",privacyPolicy:"Privacy policy",rejoinCallButtonLabel:"Re-join call",removedFromCallMoreDetails:"Another participant removed you from the call.",removedFromCallTitle:"You were removed",removeMenuLabel:"Remove",returnToCallButtonAriaDescription:"Return to Call",returnToCallButtonAriaLabel:"Back",soundLabel:"Sound",startCallButtonLabel:"Start call",openDialpadButtonLabel:"Dial phone number",peoplePaneAddPeopleButtonLabel:"Add People",dialpadStartCallButtonLabel:"Call",dialpadModalTitle:"Dial Phone Number",dialpadModalAriaLabel:"Dialpad",dialpadCloseModalButtonAriaLabel:"Close Dialpad",moreButtonCallingLabel:"More",resumeCallButtonLabel:"Resume",resumingCallButtonLabel:"Resuming",resumeCallButtonAriaLabel:"Resume call",resumingCallButtonAriaLabel:"Resume call",holdScreenLabel:"You're on hold",openDtmfDialpadLabel:"Show Dialpad",dtmfDialpadPlaceHolderText:"Enter number"};var chat$d={chatListHeader:"In this chat",uploadFile:"Upload File"};var callWithChat$d={chatButtonLabel:"Chat",chatButtonNewMessageNotificationLabel:"New Message",chatButtonTooltipClosedWithMessageCount:"Show chat ({unreadMessagesCount} unread)",chatButtonTooltipClose:"Hide chat",chatButtonTooltipOpen:"Show chat",chatPaneTitle:"Chat",copyInviteLinkButtonLabel:"Copy invite link",dismissSidePaneButtonLabel:"Close",moreDrawerAudioDeviceMenuTitle:"Audio Device",moreDrawerButtonLabel:"More options",moreDrawerButtonTooltip:"More options",moreDrawerMicrophoneMenuTitle:"Microphone",moreDrawerSpeakerMenuTitle:"Speaker",peopleButtonLabel:"People",peopleButtonTooltipOpen:"Show participants",peopleButtonTooltipClose:"Hide participants",peoplePaneSubTitle:"In this call",peoplePaneTitle:"People",pictureInPictureTileAriaLabel:"Video Feeds. Click to return to call screen.",removeMenuLabel:"Remove",openDialpadButtonLabel:"Dial phone number",returnToCallButtonAriaDescription:"Return to Call",returnToCallButtonAriaLabel:"Back",peoplePaneAddPeopleButtonLabel:"Add People",dialpadStartCallButtonLabel:"Call",dialpadModalTitle:"Dial Phone Number",dialpadModalAriaLabel:"Dialpad",dialpadCloseModalButtonAriaLabel:"Close Dialpad",openDtmfDialpadLabel:"Show Dialpad",dtmfDialpadPlaceHolderText:"Enter number"};var en_US = {call:call$d,chat:chat$d,callWithChat:callWithChat$d};
12710
12792
 
12711
12793
  var call$c={cameraLabel:"Camera",cameraPermissionDenied:"Your browser is blocking access to your camera",cameraTurnedOff:"Your camera is turned off",close:"Close",complianceBannerNowOnlyRecording:"You are now only recording this meeting.",complianceBannerNowOnlyTranscription:"You are now only transcribing this meeting.",complianceBannerRecordingAndTranscriptionSaved:"Recording and transcription are being saved.",complianceBannerRecordingAndTranscriptionStarted:"Recording and transcription have started.",complianceBannerRecordingAndTranscriptionStopped:"Recording and transcription have stopped.",complianceBannerRecordingSaving:"Recording is being saved.",complianceBannerRecordingStarted:"Recording has started.",complianceBannerRecordingStopped:"Recording has stopped.",complianceBannerTranscriptionStarted:"Transcription has started.",complianceBannerTranscriptionConsent:"By joining, you are giving consent for this meeting to be transcribed.",complianceBannerTranscriptionSaving:"Transcription is being saved.",complianceBannerTranscriptionStopped:"Transcription has stopped.",configurationPageTitle:"Start a call",defaultPlaceHolder:"Select an option",failedToJoinCallDueToNoNetworkMoreDetails:"Call was disconnected due to a network issue. Check your connection and join again.",failedToJoinCallDueToNoNetworkTitle:"Call disconnected",failedToJoinTeamsMeetingReasonAccessDeniedMoreDetails:"You were not granted entry in the call. If this was a mistake, re-join the call.",failedToJoinTeamsMeetingReasonAccessDeniedTitle:"Dismissed from lobby",learnMore:"Learn more",leftCallMoreDetails:"If this was a mistake, re-join the call.",leftCallTitle:"You left the call",lobbyScreenConnectingToCallTitle:"Joining call",lobbyScreenWaitingToBeAdmittedTitle:"Waiting to be admitted",microphonePermissionDenied:"Your browser is blocking access to your microphone",mutedMessage:"You're muted",networkReconnectMoreDetails:"Looks like something went wrong. We're trying to get back into the call.",networkReconnectTitle:"Hold on",privacyPolicy:"Privacy policy",rejoinCallButtonLabel:"Re-join call",removedFromCallMoreDetails:"Another participant removed you from the call.",removedFromCallTitle:"You were removed",soundLabel:"Sound",startCallButtonLabel:"Start call",microphoneToggleInLobbyNotAllowed:"Cannot mute or unmute while in lobby."};var chat$c={chatListHeader:"In this chat"};var callWithChat$c={peopleButtonLabel:"People",peopleButtonTooltipOpen:"Show participants",peopleButtonTooltipClose:"Hide participants",chatButtonLabel:"Chat",chatButtonTooltipClosedWithMessageCount:"Show chat ({unreadMessagesCount} unread)",chatButtonTooltipOpen:"Show chat",chatButtonTooltipClose:"Hide chat",moreDrawerAudioDeviceMenuTitle:"Audio Device",moreDrawerMicrophoneMenuTitle:"Microphone",moreDrawerSpeakerMenuTitle:"Speaker",moreDrawerButtonLabel:"More options",moreDrawerButtonTooltip:"More options",peoplePaneTitle:"People",peoplePaneSubTitle:"In this call",chatPaneTitle:"Chat",chatButtonNewMessageNotificationLabel:"New Message",pictureInPictureTileAriaLabel:"Video Feeds. Click to return to call screen.",removeMenuLabel:"Remove",copyInviteLinkButtonLabel:"Copy invite link",dismissSidePaneButton:"Close",returnToCallButtonAriaDescription:"Return to Call",returnToCallButtonAriaLabel:"Back"};var en_GB = {call:call$c,chat:chat$c,callWithChat:callWithChat$c};
12712
12794
 
@@ -13108,7 +13190,7 @@ const convertObservableFileUploadToFileUploadsUiState = (fileUploads) => {
13108
13190
 
13109
13191
  // Copyright (c) Microsoft Corporation.
13110
13192
  // Licensed under the MIT license.
13111
- var __awaiter$b = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
13193
+ var __awaiter$c = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
13112
13194
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
13113
13195
  return new (P || (P = Promise))(function (resolve, reject) {
13114
13196
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -13234,9 +13316,9 @@ class AzureCommunicationChatAdapter {
13234
13316
  this.unsubscribeAllEvents();
13235
13317
  }
13236
13318
  fetchInitialData() {
13237
- return __awaiter$b(this, void 0, void 0, function* () {
13319
+ return __awaiter$c(this, void 0, void 0, function* () {
13238
13320
  // If get properties fails we dont want to try to get the participants after.
13239
- yield this.asyncTeeErrorToEventEmitter(() => __awaiter$b(this, void 0, void 0, function* () {
13321
+ yield this.asyncTeeErrorToEventEmitter(() => __awaiter$c(this, void 0, void 0, function* () {
13240
13322
  var e_1, _a;
13241
13323
  yield this.chatThreadClient.getProperties();
13242
13324
  try {
@@ -13270,8 +13352,8 @@ class AzureCommunicationChatAdapter {
13270
13352
  this.context.offStateChange(handler);
13271
13353
  }
13272
13354
  sendMessage(content, options = {}) {
13273
- return __awaiter$b(this, void 0, void 0, function* () {
13274
- yield this.asyncTeeErrorToEventEmitter(() => __awaiter$b(this, void 0, void 0, function* () {
13355
+ return __awaiter$c(this, void 0, void 0, function* () {
13356
+ yield this.asyncTeeErrorToEventEmitter(() => __awaiter$c(this, void 0, void 0, function* () {
13275
13357
  /* @conditional-compile-remove(file-sharing) */
13276
13358
  options.metadata = Object.assign(Object.assign({}, options.metadata), convertFileUploadsUiStateToMessageMetadata(this.context.getState().fileUploads));
13277
13359
  /* @conditional-compile-remove(file-sharing) */
@@ -13288,49 +13370,49 @@ class AzureCommunicationChatAdapter {
13288
13370
  });
13289
13371
  }
13290
13372
  sendReadReceipt(chatMessageId) {
13291
- return __awaiter$b(this, void 0, void 0, function* () {
13292
- yield this.asyncTeeErrorToEventEmitter(() => __awaiter$b(this, void 0, void 0, function* () {
13373
+ return __awaiter$c(this, void 0, void 0, function* () {
13374
+ yield this.asyncTeeErrorToEventEmitter(() => __awaiter$c(this, void 0, void 0, function* () {
13293
13375
  yield this.handlers.onMessageSeen(chatMessageId);
13294
13376
  }));
13295
13377
  });
13296
13378
  }
13297
13379
  sendTypingIndicator() {
13298
- return __awaiter$b(this, void 0, void 0, function* () {
13380
+ return __awaiter$c(this, void 0, void 0, function* () {
13299
13381
  yield this.handlers.onTyping();
13300
13382
  });
13301
13383
  }
13302
13384
  removeParticipant(userId) {
13303
- return __awaiter$b(this, void 0, void 0, function* () {
13304
- yield this.asyncTeeErrorToEventEmitter(() => __awaiter$b(this, void 0, void 0, function* () {
13385
+ return __awaiter$c(this, void 0, void 0, function* () {
13386
+ yield this.asyncTeeErrorToEventEmitter(() => __awaiter$c(this, void 0, void 0, function* () {
13305
13387
  yield this.handlers.onRemoveParticipant(userId);
13306
13388
  }));
13307
13389
  });
13308
13390
  }
13309
13391
  setTopic(topicName) {
13310
- return __awaiter$b(this, void 0, void 0, function* () {
13311
- yield this.asyncTeeErrorToEventEmitter(() => __awaiter$b(this, void 0, void 0, function* () {
13392
+ return __awaiter$c(this, void 0, void 0, function* () {
13393
+ yield this.asyncTeeErrorToEventEmitter(() => __awaiter$c(this, void 0, void 0, function* () {
13312
13394
  yield this.handlers.updateThreadTopicName(topicName);
13313
13395
  }));
13314
13396
  });
13315
13397
  }
13316
13398
  loadPreviousChatMessages(messagesToLoad) {
13317
- return __awaiter$b(this, void 0, void 0, function* () {
13318
- return yield this.asyncTeeErrorToEventEmitter(() => __awaiter$b(this, void 0, void 0, function* () {
13399
+ return __awaiter$c(this, void 0, void 0, function* () {
13400
+ return yield this.asyncTeeErrorToEventEmitter(() => __awaiter$c(this, void 0, void 0, function* () {
13319
13401
  return yield this.handlers.onLoadPreviousChatMessages(messagesToLoad);
13320
13402
  }));
13321
13403
  });
13322
13404
  }
13323
13405
  updateMessage(messageId, content, metadata, options) {
13324
- return __awaiter$b(this, void 0, void 0, function* () {
13325
- return yield this.asyncTeeErrorToEventEmitter(() => __awaiter$b(this, void 0, void 0, function* () {
13406
+ return __awaiter$c(this, void 0, void 0, function* () {
13407
+ return yield this.asyncTeeErrorToEventEmitter(() => __awaiter$c(this, void 0, void 0, function* () {
13326
13408
  /* @conditional-compile-remove(file-sharing) */
13327
13409
  return yield this.handlers.onUpdateMessage(messageId, content, metadata, options);
13328
13410
  }));
13329
13411
  });
13330
13412
  }
13331
13413
  deleteMessage(messageId) {
13332
- return __awaiter$b(this, void 0, void 0, function* () {
13333
- return yield this.asyncTeeErrorToEventEmitter(() => __awaiter$b(this, void 0, void 0, function* () {
13414
+ return __awaiter$c(this, void 0, void 0, function* () {
13415
+ return yield this.asyncTeeErrorToEventEmitter(() => __awaiter$c(this, void 0, void 0, function* () {
13334
13416
  return yield this.handlers.onDeleteMessage(messageId);
13335
13417
  }));
13336
13418
  });
@@ -13411,7 +13493,7 @@ class AzureCommunicationChatAdapter {
13411
13493
  this.emitter.off(event, listener);
13412
13494
  }
13413
13495
  asyncTeeErrorToEventEmitter(f) {
13414
- return __awaiter$b(this, void 0, void 0, function* () {
13496
+ return __awaiter$c(this, void 0, void 0, function* () {
13415
13497
  try {
13416
13498
  return yield f();
13417
13499
  }
@@ -13453,7 +13535,7 @@ const convertEventType = (type) => {
13453
13535
  *
13454
13536
  * @public
13455
13537
  */
13456
- const createAzureCommunicationChatAdapter = ({ endpoint: endpointUrl, userId, displayName, credential, threadId }) => __awaiter$b(void 0, void 0, void 0, function* () {
13538
+ const createAzureCommunicationChatAdapter = ({ endpoint: endpointUrl, userId, displayName, credential, threadId }) => __awaiter$c(void 0, void 0, void 0, function* () {
13457
13539
  const chatClient = createStatefulChatClient({
13458
13540
  userId,
13459
13541
  displayName,
@@ -13516,7 +13598,7 @@ beforeDispose) => {
13516
13598
  if (!credential || !displayName || !endpoint || !threadId || !userId) {
13517
13599
  return;
13518
13600
  }
13519
- (() => __awaiter$b(void 0, void 0, void 0, function* () {
13601
+ (() => __awaiter$c(void 0, void 0, void 0, function* () {
13520
13602
  if (adapterRef.current) {
13521
13603
  // Dispose the old adapter when a new one is created.
13522
13604
  //
@@ -13548,7 +13630,7 @@ beforeDispose) => {
13548
13630
  // Dispose any existing adapter when the component unmounts.
13549
13631
  React.useEffect(() => {
13550
13632
  return () => {
13551
- (() => __awaiter$b(void 0, void 0, void 0, function* () {
13633
+ (() => __awaiter$c(void 0, void 0, void 0, function* () {
13552
13634
  if (adapterRef.current) {
13553
13635
  if (beforeDisposeRef.current) {
13554
13636
  yield beforeDisposeRef.current(adapterRef.current);
@@ -13569,7 +13651,7 @@ beforeDispose) => {
13569
13651
  *
13570
13652
  * @public
13571
13653
  */
13572
- const createAzureCommunicationChatAdapterFromClient = (chatClient, chatThreadClient) => __awaiter$b(void 0, void 0, void 0, function* () {
13654
+ const createAzureCommunicationChatAdapterFromClient = (chatClient, chatThreadClient) => __awaiter$c(void 0, void 0, void 0, function* () {
13573
13655
  return new AzureCommunicationChatAdapter(chatClient, chatThreadClient);
13574
13656
  });
13575
13657
  const isChatError = (e) => {
@@ -13771,7 +13853,7 @@ const sendboxContainerStyles = {
13771
13853
 
13772
13854
  // Copyright (c) Microsoft Corporation.
13773
13855
  // Licensed under the MIT license.
13774
- var __awaiter$a = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
13856
+ var __awaiter$b = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
13775
13857
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
13776
13858
  return new (P || (P = Promise))(function (resolve, reject) {
13777
13859
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -13792,7 +13874,7 @@ const AvatarPersona = (props) => {
13792
13874
  const { userId, dataProvider, text, imageUrl, imageInitials, initialsColor, initialsTextColor, showOverflowTooltip } = props;
13793
13875
  const [data, setData] = React.useState();
13794
13876
  React.useEffect(() => {
13795
- (() => __awaiter$a(void 0, void 0, void 0, function* () {
13877
+ (() => __awaiter$b(void 0, void 0, void 0, function* () {
13796
13878
  if (dataProvider && userId) {
13797
13879
  const newData = yield dataProvider(userId);
13798
13880
  if (avatarDeepDifferenceCheck(data, newData)) {
@@ -14448,14 +14530,15 @@ const getCallCompositePage = (call, previousCall) => {
14448
14530
  // `_isInLobbyOrConnecting` needs to be checked first because `_isInCall` also returns true when call is in lobby.
14449
14531
  if (_isInLobbyOrConnecting(call === null || call === void 0 ? void 0 : call.state)) {
14450
14532
  return 'lobby';
14451
- }
14452
- else if (_isInCall(call === null || call === void 0 ? void 0 : call.state)) {
14453
- return 'call';
14533
+ // `LocalHold` needs to be checked before `isInCall` since it is also a state that's considered in call.
14454
14534
  }
14455
14535
  else if ((call === null || call === void 0 ? void 0 : call.state) === 'LocalHold') {
14456
14536
  /* @conditional-compile-remove(PSTN-calls) */ /* @conditional-compile-remove(one-to-n-calling) */
14457
14537
  return 'hold';
14458
14538
  }
14539
+ else if (_isInCall(call === null || call === void 0 ? void 0 : call.state)) {
14540
+ return 'call';
14541
+ }
14459
14542
  else {
14460
14543
  // When the call object has been constructed after clicking , but before 'connecting' has been
14461
14544
  // set on the call object, we continue to show the configuration screen.
@@ -14527,7 +14610,7 @@ const disableCallControls = (callControlOptions, disabledControls) => {
14527
14610
 
14528
14611
  // Copyright (c) Microsoft Corporation.
14529
14612
  // Licensed under the MIT license.
14530
- var __awaiter$9 = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
14613
+ var __awaiter$a = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
14531
14614
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
14532
14615
  return new (P || (P = Promise))(function (resolve, reject) {
14533
14616
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -14546,72 +14629,72 @@ _component) => {
14546
14629
  return createCompositeHandlers(useAdapter());
14547
14630
  };
14548
14631
  const createCompositeHandlers = memoizeOne__default['default']((adapter) => ({
14549
- onCreateLocalStreamView: (options) => __awaiter$9(void 0, void 0, void 0, function* () {
14632
+ onCreateLocalStreamView: (options) => __awaiter$a(void 0, void 0, void 0, function* () {
14550
14633
  return yield adapter.createStreamView(undefined, options);
14551
14634
  }),
14552
- onCreateRemoteStreamView: (userId, options) => __awaiter$9(void 0, void 0, void 0, function* () {
14635
+ onCreateRemoteStreamView: (userId, options) => __awaiter$a(void 0, void 0, void 0, function* () {
14553
14636
  return yield adapter.createStreamView(userId, options);
14554
14637
  }),
14555
- onHangUp: () => __awaiter$9(void 0, void 0, void 0, function* () {
14638
+ onHangUp: () => __awaiter$a(void 0, void 0, void 0, function* () {
14556
14639
  yield adapter.leaveCall();
14557
14640
  }),
14558
14641
  /* @conditional-compile-remove(PSTN-calls) */
14559
- onToggleHold: () => __awaiter$9(void 0, void 0, void 0, function* () {
14642
+ onToggleHold: () => __awaiter$a(void 0, void 0, void 0, function* () {
14560
14643
  var _a;
14561
14644
  return ((_a = adapter.getState().call) === null || _a === void 0 ? void 0 : _a.state) === 'LocalHold' ? yield adapter.resumeCall() : yield adapter.holdCall();
14562
14645
  }),
14563
14646
  /* @conditional-compile-remove(PSTN-calls) */
14564
- onAddParticipant: (participant, options) => __awaiter$9(void 0, void 0, void 0, function* () {
14647
+ onAddParticipant: (participant, options) => __awaiter$a(void 0, void 0, void 0, function* () {
14565
14648
  return yield adapter.addParticipant(participant, options);
14566
14649
  }),
14567
14650
  /* @conditional-compile-remove(PSTN-calls) */
14568
- onSendDtmfTone: (dtmfTone) => __awaiter$9(void 0, void 0, void 0, function* () {
14651
+ onSendDtmfTone: (dtmfTone) => __awaiter$a(void 0, void 0, void 0, function* () {
14569
14652
  yield adapter.sendDtmfTone(dtmfTone);
14570
14653
  }),
14571
- onRemoveParticipant: (userId) => __awaiter$9(void 0, void 0, void 0, function* () {
14654
+ onRemoveParticipant: (userId) => __awaiter$a(void 0, void 0, void 0, function* () {
14572
14655
  yield adapter.removeParticipant(userId);
14573
14656
  }),
14574
- onSelectCamera: (deviceInfo, options) => __awaiter$9(void 0, void 0, void 0, function* () {
14657
+ onSelectCamera: (deviceInfo, options) => __awaiter$a(void 0, void 0, void 0, function* () {
14575
14658
  yield adapter.setCamera(deviceInfo, options);
14576
14659
  }),
14577
- onSelectMicrophone: (deviceInfo) => __awaiter$9(void 0, void 0, void 0, function* () {
14660
+ onSelectMicrophone: (deviceInfo) => __awaiter$a(void 0, void 0, void 0, function* () {
14578
14661
  yield adapter.setMicrophone(deviceInfo);
14579
14662
  }),
14580
- onSelectSpeaker: (deviceInfo) => __awaiter$9(void 0, void 0, void 0, function* () {
14663
+ onSelectSpeaker: (deviceInfo) => __awaiter$a(void 0, void 0, void 0, function* () {
14581
14664
  yield adapter.setSpeaker(deviceInfo);
14582
14665
  }),
14583
14666
  onStartCall: (participants, options) => {
14584
14667
  const rawIds = participants.map((participant) => toFlatCommunicationIdentifier(participant));
14585
14668
  return adapter.startCall(rawIds, options);
14586
14669
  },
14587
- onStartScreenShare: () => __awaiter$9(void 0, void 0, void 0, function* () {
14670
+ onStartScreenShare: () => __awaiter$a(void 0, void 0, void 0, function* () {
14588
14671
  yield adapter.startScreenShare();
14589
14672
  }),
14590
- onStopScreenShare: () => __awaiter$9(void 0, void 0, void 0, function* () {
14673
+ onStopScreenShare: () => __awaiter$a(void 0, void 0, void 0, function* () {
14591
14674
  yield adapter.stopScreenShare();
14592
14675
  }),
14593
- onToggleCamera: (options) => __awaiter$9(void 0, void 0, void 0, function* () {
14676
+ onToggleCamera: (options) => __awaiter$a(void 0, void 0, void 0, function* () {
14594
14677
  isCameraOn(adapter.getState()) ? yield adapter.stopCamera() : yield adapter.startCamera(options);
14595
14678
  }),
14596
- onToggleMicrophone: () => __awaiter$9(void 0, void 0, void 0, function* () {
14679
+ onToggleMicrophone: () => __awaiter$a(void 0, void 0, void 0, function* () {
14597
14680
  var _b;
14598
14681
  return ((_b = adapter.getState().call) === null || _b === void 0 ? void 0 : _b.isMuted) ? yield adapter.unmute() : yield adapter.mute();
14599
14682
  }),
14600
- onToggleScreenShare: () => __awaiter$9(void 0, void 0, void 0, function* () {
14683
+ onToggleScreenShare: () => __awaiter$a(void 0, void 0, void 0, function* () {
14601
14684
  var _c;
14602
14685
  return ((_c = adapter.getState().call) === null || _c === void 0 ? void 0 : _c.isScreenSharingOn)
14603
14686
  ? yield adapter.stopScreenShare()
14604
14687
  : yield adapter.startScreenShare();
14605
14688
  }),
14606
- onStartLocalVideo: () => __awaiter$9(void 0, void 0, void 0, function* () {
14689
+ onStartLocalVideo: () => __awaiter$a(void 0, void 0, void 0, function* () {
14607
14690
  if (adapter.getState().call) {
14608
14691
  return adapter.startCamera();
14609
14692
  }
14610
14693
  }),
14611
- onDisposeLocalStreamView: () => __awaiter$9(void 0, void 0, void 0, function* () {
14694
+ onDisposeLocalStreamView: () => __awaiter$a(void 0, void 0, void 0, function* () {
14612
14695
  return adapter.disposeStreamView();
14613
14696
  }),
14614
- onDisposeRemoteStreamView: (userId) => __awaiter$9(void 0, void 0, void 0, function* () {
14697
+ onDisposeRemoteStreamView: (userId) => __awaiter$a(void 0, void 0, void 0, function* () {
14615
14698
  return adapter.disposeStreamView(userId);
14616
14699
  })
14617
14700
  }));
@@ -14674,7 +14757,8 @@ const buttonFlyoutIncreasedSizeStyles = {
14674
14757
  maxHeight: 'unset'
14675
14758
  },
14676
14759
  icon: {
14677
- maxHeight: 'unset'
14760
+ maxHeight: 'unset',
14761
+ textAlign: 'center'
14678
14762
  }
14679
14763
  };
14680
14764
  /**
@@ -14976,6 +15060,7 @@ const themedDialpadStyle$1 = (isMobile, theme) => ({
14976
15060
  backgroundColor: theme.palette.white,
14977
15061
  fontSize: theme.fonts.large.fontSize,
14978
15062
  padding: '0 0.5rem ',
15063
+ direction: 'rtl',
14979
15064
  textAlign: 'center',
14980
15065
  ':active': {
14981
15066
  padding: '0 0.5rem'
@@ -15094,7 +15179,7 @@ const CallControls = (props) => {
15094
15179
  props.onPeopleButtonClicked();
15095
15180
  }
15096
15181
  },
15097
- iconProps: { iconName: 'ControlButtonParticipants', styles: { root: { lineHeight: 0 } } },
15182
+ iconProps: { iconName: 'ControlButtonParticipantsContextualMenuItem', styles: { root: { lineHeight: 0 } } },
15098
15183
  itemProps: {
15099
15184
  styles: buttonFlyoutIncreasedSizeStyles
15100
15185
  },
@@ -15107,7 +15192,7 @@ const CallControls = (props) => {
15107
15192
  onClick: () => {
15108
15193
  holdButtonProps.onToggleHold();
15109
15194
  },
15110
- iconProps: { iconName: 'HoldCall', styles: { root: { lineHeight: 0 } } },
15195
+ iconProps: { iconName: 'HoldCallContextualMenuItem', styles: { root: { lineHeight: 0 } } },
15111
15196
  itemProps: {
15112
15197
  styles: buttonFlyoutIncreasedSizeStyles
15113
15198
  },
@@ -15121,7 +15206,7 @@ const CallControls = (props) => {
15121
15206
  onClick: () => {
15122
15207
  setShowDialpad(true);
15123
15208
  },
15124
- iconProps: { iconName: 'Dialpad', styles: { root: { lineHeight: 0 } } },
15209
+ iconProps: { iconName: 'PeoplePaneOpenDialpad', styles: { root: { lineHeight: 0 } } },
15125
15210
  itemProps: {
15126
15211
  styles: buttonFlyoutIncreasedSizeStyles
15127
15212
  }
@@ -15650,6 +15735,7 @@ const themedDialpadStyle = (isMobile, theme) => ({
15650
15735
  backgroundColor: theme.palette.white,
15651
15736
  fontSize: theme.fonts.large.fontSize,
15652
15737
  padding: '0 0.5rem',
15738
+ direction: 'rtl',
15653
15739
  textAlign: isMobile ? 'center' : 'left',
15654
15740
  ':active': {
15655
15741
  padding: '0 0.5rem'
@@ -15848,7 +15934,7 @@ const AddPeopleButton = (props) => {
15848
15934
 
15849
15935
  // Copyright (c) Microsoft Corporation.
15850
15936
  // Licensed under the MIT license.
15851
- var __awaiter$8 = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
15937
+ var __awaiter$9 = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
15852
15938
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
15853
15939
  return new (P || (P = Promise))(function (resolve, reject) {
15854
15940
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -15863,10 +15949,11 @@ var __awaiter$8 = (window && window.__awaiter) || function (thisArg, _arguments,
15863
15949
  const PeoplePaneContent = (props) => {
15864
15950
  const { inviteLink, onFetchParticipantMenuItems, setDrawerMenuItems, strings, onRemoveParticipant } = props;
15865
15951
  const participantListDefaultProps = usePropsFor$1(ParticipantList);
15952
+ const disableRemoveButton = !hasRemoveParticipantsPermissionTrampoline();
15866
15953
  const setDrawerMenuItemsForParticipant = React.useMemo(() => {
15867
15954
  return (participant) => {
15868
15955
  if (participant) {
15869
- let contextualMenuItems = createDefaultContextualMenuItems(participant, strings, participantListDefaultProps.onRemoveParticipant, participantListDefaultProps.myUserId);
15956
+ let contextualMenuItems = createDefaultContextualMenuItems(participant, strings, participantListDefaultProps.onRemoveParticipant, participantListDefaultProps.myUserId, disableRemoveButton);
15870
15957
  if (onFetchParticipantMenuItems) {
15871
15958
  contextualMenuItems = onFetchParticipantMenuItems(participant.userId, participantListDefaultProps.myUserId, contextualMenuItems);
15872
15959
  }
@@ -15878,11 +15965,12 @@ const PeoplePaneContent = (props) => {
15878
15965
  strings,
15879
15966
  participantListDefaultProps.onRemoveParticipant,
15880
15967
  participantListDefaultProps.myUserId,
15968
+ disableRemoveButton,
15881
15969
  onFetchParticipantMenuItems,
15882
15970
  setDrawerMenuItems
15883
15971
  ]);
15884
15972
  const participantListProps = React.useMemo(() => {
15885
- const onRemoveAParticipant = (participantId) => __awaiter$8(void 0, void 0, void 0, function* () { return onRemoveParticipant(participantId); });
15973
+ const onRemoveAParticipant = (participantId) => __awaiter$9(void 0, void 0, void 0, function* () { return onRemoveParticipant(participantId); });
15886
15974
  return Object.assign(Object.assign({}, participantListDefaultProps), {
15887
15975
  // Passing undefined callback for mobile to avoid context menus for participants in ParticipantList are clicked
15888
15976
  onRemoveParticipant: props.mobileView ? undefined : onRemoveAParticipant,
@@ -15913,7 +16001,11 @@ const PeoplePaneContent = (props) => {
15913
16001
  * @param localParticipantUserId - Local participant user id
15914
16002
  * @returns - IContextualMenuItem[]
15915
16003
  */
15916
- const createDefaultContextualMenuItems = (participant, strings, onRemoveParticipant, localParticipantUserId) => {
16004
+ const createDefaultContextualMenuItems = (participant, strings, onRemoveParticipant, localParticipantUserId, disableRemoveButton) => {
16005
+ let disabled = !participant.isRemovable;
16006
+ if (disableRemoveButton) {
16007
+ disabled = disabled || disableRemoveButton;
16008
+ }
15917
16009
  const menuItems = [];
15918
16010
  if ((participant === null || participant === void 0 ? void 0 : participant.userId) !== localParticipantUserId) {
15919
16011
  menuItems.push({
@@ -15927,11 +16019,18 @@ const createDefaultContextualMenuItems = (participant, strings, onRemoveParticip
15927
16019
  iconProps: {
15928
16020
  iconName: 'UserRemove'
15929
16021
  },
15930
- disabled: !participant.isRemovable
16022
+ disabled: disabled
15931
16023
  });
15932
16024
  }
15933
16025
  return menuItems;
15934
16026
  };
16027
+ /**
16028
+ * @private
16029
+ */
16030
+ const hasRemoveParticipantsPermissionTrampoline = () => {
16031
+ /* @conditional-compile-remove(rooms) */
16032
+ return _usePermissions().removeParticipantButton;
16033
+ };
15935
16034
 
15936
16035
  // Copyright (c) Microsoft Corporation.
15937
16036
  /**
@@ -16074,7 +16173,7 @@ const useMinMaxDragPosition = (modalLayerHostId, rtl) => {
16074
16173
  return { minDragPosition: minDragPosition, maxDragPosition: maxDragPosition };
16075
16174
  };
16076
16175
 
16077
- var __awaiter$7 = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
16176
+ var __awaiter$8 = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
16078
16177
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
16079
16178
  return new (P || (P = Promise))(function (resolve, reject) {
16080
16179
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -16104,11 +16203,11 @@ const CallPane = (props) => {
16104
16203
  /**
16105
16204
  * In a Call Composite when a participant is removed, we must remove them from the call.
16106
16205
  */
16107
- const removeParticipantFromCall = (participantId) => __awaiter$7(void 0, void 0, void 0, function* () {
16206
+ const removeParticipantFromCall = (participantId) => __awaiter$8(void 0, void 0, void 0, function* () {
16108
16207
  yield props.callAdapter.removeParticipant(participantId);
16109
16208
  });
16110
16209
  /* @conditional-compile-remove(PSTN-calls) */
16111
- const addParticipantToCall = (participant, options) => __awaiter$7(void 0, void 0, void 0, function* () {
16210
+ const addParticipantToCall = (participant, options) => __awaiter$8(void 0, void 0, void 0, function* () {
16112
16211
  yield props.callAdapter.addParticipant(participant, options);
16113
16212
  });
16114
16213
  const minMaxDragPosition = useMinMaxDragPosition(props.modalLayerHostId, props.rtl);
@@ -16817,7 +16916,7 @@ const localPreviewTileStyle = {
16817
16916
 
16818
16917
  // Copyright (c) Microsoft Corporation.
16819
16918
  // Licensed under the MIT license.
16820
- var __awaiter$6 = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
16919
+ var __awaiter$7 = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
16821
16920
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
16822
16921
  return new (P || (P = Promise))(function (resolve, reject) {
16823
16922
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -16837,7 +16936,7 @@ const LocalPreview = (props) => {
16837
16936
  const { audio: microphonePermissionGranted, video: cameraPermissionGranted } = useSelector$1(devicePermissionSelector);
16838
16937
  const isLocalMicrophoneEnabled = useSelector$1(getLocalMicrophoneEnabled);
16839
16938
  const adapter = useAdapter();
16840
- const onToggleMic = React.useCallback(() => __awaiter$6(void 0, void 0, void 0, function* () {
16939
+ const onToggleMic = React.useCallback(() => __awaiter$7(void 0, void 0, void 0, function* () {
16841
16940
  isLocalMicrophoneEnabled ? adapter.mute() : adapter.unmute();
16842
16941
  }), [adapter, isLocalMicrophoneEnabled]);
16843
16942
  const theme = useTheme();
@@ -16976,6 +17075,15 @@ const ConfigurationPage = (props) => {
16976
17075
  const errorBarProps = usePropsFor$1(ErrorBar);
16977
17076
  const adapter = useAdapter();
16978
17077
  const deviceState = adapter.getState().devices;
17078
+ let disableStartCallButton = !microphonePermissionGranted || ((_a = deviceState.microphones) === null || _a === void 0 ? void 0 : _a.length) === 0;
17079
+ /* @conditional-compile-remove(rooms) */
17080
+ const rolePermissions = _usePermissions();
17081
+ /* @conditional-compile-remove(rooms) */
17082
+ if (!rolePermissions.microphoneButton) {
17083
+ // If user's role permissions do not allow access to the microphone button then DO NOT disable the start call button
17084
+ // because microphone device permission is not needed for the user's role
17085
+ disableStartCallButton = false;
17086
+ }
16979
17087
  const locale = useLocale();
16980
17088
  const title = (React__default['default'].createElement(react.Stack.Item, { className: mobileView ? titleContainerStyleMobile : titleContainerStyleDesktop }, locale.strings.call.configurationPageTitle));
16981
17089
  const callDescription = locale.strings.call.configurationPageCallDetails && (React__default['default'].createElement(react.Stack.Item, { className: mobileView ? callDetailsStyleMobile : callDetailsStyleDesktop }, locale.strings.call.configurationPageCallDetails));
@@ -16994,7 +17102,7 @@ const ConfigurationPage = (props) => {
16994
17102
  callDescription),
16995
17103
  React__default['default'].createElement(LocalDeviceSettings, Object.assign({}, options, localDeviceSettingsHandlers, { cameraPermissionGranted: cameraPermissionGranted, microphonePermissionGranted: microphonePermissionGranted })))),
16996
17104
  React__default['default'].createElement(react.Stack, { styles: mobileView ? startCallButtonContainerStyleMobile : startCallButtonContainerStyleDesktop },
16997
- React__default['default'].createElement(StartCallButton, { className: mobileView ? startCallButtonStyleMobile : undefined, onClick: startCallHandler, disabled: !microphonePermissionGranted || ((_a = deviceState.microphones) === null || _a === void 0 ? void 0 : _a.length) === 0 }))))));
17105
+ React__default['default'].createElement(StartCallButton, { className: mobileView ? startCallButtonStyleMobile : undefined, onClick: startCallHandler, disabled: disableStartCallButton }))))));
16998
17106
  };
16999
17107
 
17000
17108
  // Copyright (c) Microsoft Corporation.
@@ -17147,6 +17255,11 @@ const resumeButtonStyles = {
17147
17255
  fontWeight: 400,
17148
17256
  display: 'flex',
17149
17257
  fontSize: _pxToRem(14)
17258
+ },
17259
+ labelDisabled: {
17260
+ fontWeight: 400,
17261
+ display: 'flex',
17262
+ fontSize: _pxToRem(14)
17150
17263
  }
17151
17264
  };
17152
17265
  /**
@@ -17204,6 +17317,16 @@ const holdPaneContentStyles = {
17204
17317
  };
17205
17318
 
17206
17319
  // Copyright (c) Microsoft Corporation.
17320
+ // Licensed under the MIT license.
17321
+ var __awaiter$6 = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
17322
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
17323
+ return new (P || (P = Promise))(function (resolve, reject) {
17324
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
17325
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
17326
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
17327
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
17328
+ });
17329
+ };
17207
17330
  /**
17208
17331
  * Hold pane to display when the user places themselves on hold
17209
17332
  *
@@ -17217,6 +17340,7 @@ const HoldPane = () => {
17217
17340
  const [time, setTime] = React.useState(0);
17218
17341
  const elapsedTime = getReadableTime(time);
17219
17342
  const startTime = React.useRef(performance.now());
17343
+ const [resumingCall, setResumingCall] = React.useState(false);
17220
17344
  React__default['default'].useEffect(() => {
17221
17345
  const interval = setInterval(() => {
17222
17346
  setTime(performance.now() - startTime.current);
@@ -17225,14 +17349,24 @@ const HoldPane = () => {
17225
17349
  clearInterval(interval);
17226
17350
  };
17227
17351
  }, [startTime]);
17352
+ const resumeSpinner = () => {
17353
+ return React__default['default'].createElement(react.Spinner, { label: strings.resumingCallButtonLabel, labelPosition: 'right' });
17354
+ };
17228
17355
  return (React__default['default'].createElement(react.Stack, { styles: paneStyles },
17229
17356
  React__default['default'].createElement(react.Stack, { horizontal: true, styles: holdPaneContentStyles },
17230
17357
  React__default['default'].createElement(react.Text, { styles: holdPaneTimerStyles }, elapsedTime),
17231
17358
  React__default['default'].createElement(react.Text, { styles: holdPaneLabelStyles }, strings.holdScreenLabel),
17232
- React__default['default'].createElement(react.PrimaryButton, { text: strings.resumeCallButtonLabel, ariaLabel: strings.resumeCallButtonAriaLabel, styles: resumeButtonStyles, onClick: () => {
17233
- /* @conditional-compile-remove(PSTN-calls) */ /* @conditional-compile-remove(one-to-n-calling) */
17234
- holdButtonProps.onToggleHold();
17235
- }, "data-ui-id": "hold-page-resume-call-button" }))));
17359
+ React__default['default'].createElement(react.PrimaryButton, { text: !resumingCall ? strings.resumeCallButtonLabel : undefined, ariaLabel: !resumingCall ? strings.resumeCallButtonAriaLabel : strings.resumingCallButtonAriaLabel, styles: resumeButtonStyles, disabled: resumingCall, onClick: () => __awaiter$6(void 0, void 0, void 0, function* () {
17360
+ setResumingCall(true);
17361
+ try {
17362
+ /* @conditional-compile-remove(PSTN-calls) */ /* @conditional-compile-remove(one-to-n-calling) */
17363
+ yield holdButtonProps.onToggleHold();
17364
+ }
17365
+ catch (e) {
17366
+ setResumingCall(false);
17367
+ throw e;
17368
+ }
17369
+ }), "data-ui-id": "hold-page-resume-call-button" }, resumingCall && resumeSpinner()))));
17236
17370
  };
17237
17371
  const getMinutes = (time) => {
17238
17372
  return Math.floor(getSeconds(time) / 60);
@@ -17257,7 +17391,9 @@ const stringsTrampoline = (locale) => {
17257
17391
  return {
17258
17392
  holdScreenLabel: locale.strings.call.holdScreenLabel,
17259
17393
  resumeCallButtonLabel: locale.strings.call.resumeCallButtonLabel,
17260
- resumeCallButtonAriaLabel: locale.strings.call.resumeCallButtonAriaLabel
17394
+ resumeCallButtonAriaLabel: locale.strings.call.resumeCallButtonAriaLabel,
17395
+ resumingCallButtonLabel: locale.strings.call.resumingCallButtonLabel,
17396
+ resumingCallButtonAriaLabel: locale.strings.call.resumingCallButtonAriaLabel
17261
17397
  };
17262
17398
  };
17263
17399
 
@@ -17719,7 +17855,7 @@ class AzureCommunicationCallAdapter {
17719
17855
  });
17720
17856
  }
17721
17857
  _joinCall(audioOptions, videoOptions) {
17722
- const isTeamsMeeting = 'teamsLink' in this.locator;
17858
+ const isTeamsMeeting = 'meetingLink' in this.locator;
17723
17859
  /* @conditional-compile-remove(rooms) */
17724
17860
  const isRoomsCall = 'roomId' in this.locator;
17725
17861
  if (isTeamsMeeting) {
@@ -18401,7 +18537,7 @@ const DesktopMoreButton = (props) => {
18401
18537
  onClick: () => {
18402
18538
  holdButtonProps.onToggleHold();
18403
18539
  },
18404
- iconProps: { iconName: 'HoldCall', styles: { root: { lineHeight: 0 } } },
18540
+ iconProps: { iconName: 'HoldCallContextualMenuItem', styles: { root: { lineHeight: 0 } } },
18405
18541
  itemProps: {
18406
18542
  styles: buttonFlyoutIncreasedSizeStyles
18407
18543
  },
@@ -18932,7 +19068,7 @@ const MoreDrawer = (props) => {
18932
19068
  onItemClick: () => {
18933
19069
  holdButtonProps.onToggleHold();
18934
19070
  },
18935
- iconProps: { iconName: 'HoldCall', styles: { root: { lineHeight: 0 } } }
19071
+ iconProps: { iconName: 'HoldCallContextualMenuItem', styles: { root: { lineHeight: 0 } } }
18936
19072
  });
18937
19073
  }
18938
19074
  /*@conditional-compile-remove(PSTN-calls) */