@azure/communication-react 1.20.0-alpha-202410120015 → 1.20.0-alpha-202410160016
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/communication-react.d.ts +104 -17
- package/dist/dist-cjs/communication-react/{ChatMessageComponentAsRichTextEditBox-CP31U1Qi.js → ChatMessageComponentAsRichTextEditBox-NQBARXtW.js} +2 -2
- package/dist/dist-cjs/communication-react/{ChatMessageComponentAsRichTextEditBox-CP31U1Qi.js.map → ChatMessageComponentAsRichTextEditBox-NQBARXtW.js.map} +1 -1
- package/dist/dist-cjs/communication-react/{RichTextSendBoxWrapper-Dx0WOAPN.js → RichTextSendBoxWrapper-Se_hHkKE.js} +2 -2
- package/dist/dist-cjs/communication-react/{RichTextSendBoxWrapper-Dx0WOAPN.js.map → RichTextSendBoxWrapper-Se_hHkKE.js.map} +1 -1
- package/dist/dist-cjs/communication-react/{index-B9QcZlYP.js → index-CtfGMAPa.js} +159 -101
- package/dist/dist-cjs/communication-react/{index-B9QcZlYP.js.map → index-CtfGMAPa.js.map} +1 -1
- package/dist/dist-cjs/communication-react/index.js +1 -1
- package/dist/dist-esm/acs-ui-common/src/telemetryVersion.js +1 -1
- package/dist/dist-esm/acs-ui-common/src/telemetryVersion.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/CallComposite.js +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/CallComposite.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/AzureCommunicationCallAdapter.js +37 -25
- package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/AzureCommunicationCallAdapter.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallingSoundSubscriber.d.ts +2 -2
- package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallingSoundSubscriber.js +8 -9
- package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallingSoundSubscriber.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/OnFetchProfileCallback.js +9 -4
- package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/OnFetchProfileCallback.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/LocalDeviceSettings.js +27 -8
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/LocalDeviceSettings.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/NetworkReconnectTile.js +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/NetworkReconnectTile.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/usePeoplePane.js +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/usePeoplePane.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/TransferPage.js +3 -0
- package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/TransferPage.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/dominantRemoteParticipantSelector.js +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/dominantRemoteParticipantSelector.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/localPreviewSelector.js +2 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/localPreviewSelector.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/MediaGalleryUtils.js +10 -11
- package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/MediaGalleryUtils.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/Utils.js +12 -8
- package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/Utils.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/AzureCommunicationCallWithChatAdapter.js +0 -3
- package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/AzureCommunicationCallWithChatAdapter.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreen.js +18 -19
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreen.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadUtils.js +17 -5
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadUtils.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/common/MeetingPhoneInfoPaneContent.js +1 -1
- package/dist/dist-esm/react-composites/src/composites/common/MeetingPhoneInfoPaneContent.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/common/ModalLocalAndRemotePIP.js +5 -1
- package/dist/dist-esm/react-composites/src/composites/common/ModalLocalAndRemotePIP.js.map +1 -1
- package/package.json +2 -3
- package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/parseTeamsUrl.d.ts +0 -8
- package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/parseTeamsUrl.js +0 -25
- package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/parseTeamsUrl.js.map +0 -1
@@ -188,7 +188,7 @@ function getDefaultExportFromCjs (x) {
|
|
188
188
|
// Copyright (c) Microsoft Corporation.
|
189
189
|
// Licensed under the MIT License.
|
190
190
|
// GENERATED FILE. DO NOT EDIT MANUALLY.
|
191
|
-
var telemetryVersion = '1.20.0-alpha-
|
191
|
+
var telemetryVersion = '1.20.0-alpha-202410160016';
|
192
192
|
|
193
193
|
|
194
194
|
var telemetryVersion$1 = /*@__PURE__*/getDefaultExportFromCjs(telemetryVersion);
|
@@ -15340,7 +15340,7 @@ class _ErrorBoundary extends React.Component {
|
|
15340
15340
|
// Copyright (c) Microsoft Corporation.
|
15341
15341
|
// Licensed under the MIT License.
|
15342
15342
|
/* @conditional-compile-remove(rich-text-editor) */
|
15343
|
-
const ChatMessageComponentAsRichTextEditBox = React.lazy(() => Promise.resolve().then(function () { return require('./ChatMessageComponentAsRichTextEditBox-
|
15343
|
+
const ChatMessageComponentAsRichTextEditBox = React.lazy(() => Promise.resolve().then(function () { return require('./ChatMessageComponentAsRichTextEditBox-NQBARXtW.js'); }));
|
15344
15344
|
/**
|
15345
15345
|
* @private
|
15346
15346
|
* Use this function to load RoosterJS dependencies early in the lifecycle.
|
@@ -15348,7 +15348,7 @@ const ChatMessageComponentAsRichTextEditBox = React.lazy(() => Promise.resolve()
|
|
15348
15348
|
*
|
15349
15349
|
* @conditional-compile-remove(rich-text-editor)
|
15350
15350
|
*/
|
15351
|
-
const loadChatMessageComponentAsRichTextEditBox = () => Promise.resolve().then(function () { return require('./ChatMessageComponentAsRichTextEditBox-
|
15351
|
+
const loadChatMessageComponentAsRichTextEditBox = () => Promise.resolve().then(function () { return require('./ChatMessageComponentAsRichTextEditBox-NQBARXtW.js'); });
|
15352
15352
|
/**
|
15353
15353
|
* @private
|
15354
15354
|
*/
|
@@ -29858,7 +29858,7 @@ const AttachmentDownloadErrorBar = (props) => {
|
|
29858
29858
|
/**
|
29859
29859
|
* Wrapper for RichTextSendBox component to allow us to use usePropsFor with richTextSendBox with lazy loading
|
29860
29860
|
*/
|
29861
|
-
const RichTextSendBoxWrapper = React.lazy(() => Promise.resolve().then(function () { return require('./RichTextSendBoxWrapper-
|
29861
|
+
const RichTextSendBoxWrapper = React.lazy(() => Promise.resolve().then(function () { return require('./RichTextSendBoxWrapper-Se_hHkKE.js'); }).then((module) => ({ default: module.RichTextSendBoxWrapper })));
|
29862
29862
|
/**
|
29863
29863
|
* @private
|
29864
29864
|
* Use this function to load RoosterJS dependencies early in the lifecycle.
|
@@ -29866,7 +29866,7 @@ const RichTextSendBoxWrapper = React.lazy(() => Promise.resolve().then(function
|
|
29866
29866
|
*
|
29867
29867
|
/* @conditional-compile-remove(rich-text-editor-composite-support)
|
29868
29868
|
*/
|
29869
|
-
const loadRichTextSendBox = () => Promise.resolve().then(function () { return require('./RichTextSendBoxWrapper-
|
29869
|
+
const loadRichTextSendBox = () => Promise.resolve().then(function () { return require('./RichTextSendBoxWrapper-Se_hHkKE.js'); }).then((module) => ({ default: module.RichTextSendBoxWrapper }));
|
29870
29870
|
/**
|
29871
29871
|
* @private
|
29872
29872
|
*/
|
@@ -29948,10 +29948,9 @@ const getEditBoxMessagesInlineImages = (editBoxInlineImageUploads) => {
|
|
29948
29948
|
if (!editBoxInlineImageUploads) {
|
29949
29949
|
return;
|
29950
29950
|
}
|
29951
|
-
const messageIds = Object.keys(editBoxInlineImageUploads || {});
|
29952
29951
|
const messagesInlineImagesWithProgress = {};
|
29953
|
-
|
29954
|
-
const messageUploads =
|
29952
|
+
Object.entries(editBoxInlineImageUploads || {}).map(([messageId, attachmentUploads]) => {
|
29953
|
+
const messageUploads = attachmentUploads.map((upload) => {
|
29955
29954
|
return upload.metadata;
|
29956
29955
|
});
|
29957
29956
|
messagesInlineImagesWithProgress[messageId] = messageUploads;
|
@@ -30004,6 +30003,14 @@ const inlineImageUploadHandler = (uploadTasks, adapter, strings) => __awaiter$s(
|
|
30004
30003
|
});
|
30005
30004
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
30006
30005
|
const generateUploadTask = (imageAttributes, fileName, messageId, inlineImageUploadActionHandler) => __awaiter$s(void 0, void 0, void 0, function* () {
|
30006
|
+
if (!imageAttributes.src) {
|
30007
|
+
console.error('Cannot upload image - Image src is not provided');
|
30008
|
+
return;
|
30009
|
+
}
|
30010
|
+
if (!imageAttributes.id) {
|
30011
|
+
console.error('Cannot upload image - Image id is not provided');
|
30012
|
+
return;
|
30013
|
+
}
|
30007
30014
|
const imageData = yield getInlineImageData(imageAttributes.src);
|
30008
30015
|
if (!imageData) {
|
30009
30016
|
return;
|
@@ -30083,11 +30090,16 @@ const onInsertInlineImageForSendBox = (imageAttributes, fileName, adapter, handl
|
|
30083
30090
|
* @internal
|
30084
30091
|
*/
|
30085
30092
|
const cancelInlineImageUpload = (imageAttributes, imageUploads, messageId, inlineImageUploadActionHandler, adapter) => {
|
30093
|
+
var _a;
|
30094
|
+
if (!imageAttributes.id) {
|
30095
|
+
console.error('Cannot cancel image upload - Image id is not provided');
|
30096
|
+
return;
|
30097
|
+
}
|
30086
30098
|
if (!imageUploads || !imageUploads[messageId]) {
|
30087
30099
|
deleteExistingInlineImageForEditBox(imageAttributes.id, messageId, adapter);
|
30088
30100
|
return;
|
30089
30101
|
}
|
30090
|
-
const imageUpload = imageUploads[messageId].find((upload) => upload.metadata.id === imageAttributes.id);
|
30102
|
+
const imageUpload = (_a = imageUploads[messageId]) === null || _a === void 0 ? void 0 : _a.find((upload) => upload.metadata.id === imageAttributes.id);
|
30091
30103
|
if (!imageUpload || !(imageUpload === null || imageUpload === void 0 ? void 0 : imageUpload.metadata.id)) {
|
30092
30104
|
deleteExistingInlineImageForEditBox(imageAttributes.id, messageId, adapter);
|
30093
30105
|
return;
|
@@ -30129,7 +30141,7 @@ const updateContentStringWithUploadedInlineImages = (content, imageUploads, mess
|
|
30129
30141
|
const document = new DOMParser().parseFromString(content !== null && content !== void 0 ? content : '', 'text/html');
|
30130
30142
|
document.querySelectorAll('img').forEach((img) => {
|
30131
30143
|
var _a;
|
30132
|
-
const uploadInlineImage = messageUploads.find((upload) => !upload.metadata.error && upload.metadata.progress === 1 && upload.metadata.id === img.id);
|
30144
|
+
const uploadInlineImage = messageUploads === null || messageUploads === void 0 ? void 0 : messageUploads.find((upload) => !upload.metadata.error && upload.metadata.progress === 1 && upload.metadata.id === img.id);
|
30133
30145
|
if (uploadInlineImage) {
|
30134
30146
|
// ChatSDK uses the respond id provided by the upload response. We store the response id in the image src attribute previously.
|
30135
30147
|
img.id = (_a = uploadInlineImage.metadata.url) !== null && _a !== void 0 ? _a : img.id;
|
@@ -30290,6 +30302,7 @@ const ChatScreen = (props) => {
|
|
30290
30302
|
overlayImageItemRef.current = overlayImageItem;
|
30291
30303
|
const adapterChatMessages = useSelector$2(getChatMessages);
|
30292
30304
|
React.useEffect(() => {
|
30305
|
+
var _a;
|
30293
30306
|
if (overlayImageItemRef.current === undefined) {
|
30294
30307
|
return;
|
30295
30308
|
}
|
@@ -30297,11 +30310,9 @@ const ChatScreen = (props) => {
|
|
30297
30310
|
if (message === undefined) {
|
30298
30311
|
return;
|
30299
30312
|
}
|
30300
|
-
const
|
30301
|
-
if (overlayImageItemRef.current.imageSrc === '' &&
|
30302
|
-
|
30303
|
-
resourceCache[overlayImageItemRef.current.imageUrl]) {
|
30304
|
-
const fullSizeImageSrc = getResourceSourceUrl(resourceCache[overlayImageItemRef.current.imageUrl]);
|
30313
|
+
const resourceFetchResult = (_a = message.resourceCache) === null || _a === void 0 ? void 0 : _a[overlayImageItemRef.current.imageUrl];
|
30314
|
+
if (overlayImageItemRef.current.imageSrc === '' && resourceFetchResult) {
|
30315
|
+
const fullSizeImageSrc = getResourceSourceUrl(resourceFetchResult);
|
30305
30316
|
if (fullSizeImageSrc === undefined ||
|
30306
30317
|
fullSizeImageSrc === '' ||
|
30307
30318
|
overlayImageItemRef.current.imageSrc === fullSizeImageSrc) {
|
@@ -30399,20 +30410,20 @@ const ChatScreen = (props) => {
|
|
30399
30410
|
}, [(_b = attachmentOptions === null || attachmentOptions === void 0 ? void 0 : attachmentOptions.downloadOptions) === null || _b === void 0 ? void 0 : _b.actionsForAttachment]);
|
30400
30411
|
const threadId = useSelector$2(getThreadId);
|
30401
30412
|
const onInlineImageClicked = React.useCallback((attachmentId, messageId) => {
|
30402
|
-
var _a, _b;
|
30413
|
+
var _a, _b, _c;
|
30403
30414
|
const message = adapterChatMessages[messageId];
|
30404
|
-
const inlinedImages = (_b = (_a = message.content) === null || _a === void 0 ? void 0 : _a.attachments) === null || _b === void 0 ? void 0 : _b.filter((attachment) => {
|
30415
|
+
const inlinedImages = (_b = (_a = message === null || message === void 0 ? void 0 : message.content) === null || _a === void 0 ? void 0 : _a.attachments) === null || _b === void 0 ? void 0 : _b.filter((attachment) => {
|
30405
30416
|
return attachment.attachmentType === 'image' && attachment.id === attachmentId;
|
30406
30417
|
});
|
30407
|
-
|
30418
|
+
const attachment = inlinedImages === null || inlinedImages === void 0 ? void 0 : inlinedImages[0];
|
30419
|
+
if (!attachment) {
|
30408
30420
|
return;
|
30409
30421
|
}
|
30410
|
-
const attachment = inlinedImages[0];
|
30411
|
-
const resourceCache = message.resourceCache;
|
30412
30422
|
let imageSrc = '';
|
30413
30423
|
if (attachment.url) {
|
30414
|
-
|
30415
|
-
|
30424
|
+
const resourceFetchResult = (_c = message === null || message === void 0 ? void 0 : message.resourceCache) === null || _c === void 0 ? void 0 : _c[attachment.url];
|
30425
|
+
if (resourceFetchResult) {
|
30426
|
+
imageSrc = getResourceSourceUrl(resourceFetchResult);
|
30416
30427
|
}
|
30417
30428
|
else {
|
30418
30429
|
adapter.downloadResourceToCache({
|
@@ -30423,15 +30434,15 @@ const ChatScreen = (props) => {
|
|
30423
30434
|
}
|
30424
30435
|
}
|
30425
30436
|
const titleIconRenderOptions = {
|
30426
|
-
text: message.senderDisplayName,
|
30437
|
+
text: message === null || message === void 0 ? void 0 : message.senderDisplayName,
|
30427
30438
|
size: react.PersonaSize.size32,
|
30428
30439
|
showOverflowTooltip: false,
|
30429
|
-
imageAlt: message.senderDisplayName
|
30440
|
+
imageAlt: message === null || message === void 0 ? void 0 : message.senderDisplayName
|
30430
30441
|
};
|
30431
|
-
const messageSenderId = message.sender !== undefined ? toFlatCommunicationIdentifier(message.sender) : userId;
|
30442
|
+
const messageSenderId = (message === null || message === void 0 ? void 0 : message.sender) !== undefined ? toFlatCommunicationIdentifier(message.sender) : userId;
|
30432
30443
|
const titleIcon = onRenderAvatarCallback && onRenderAvatarCallback(messageSenderId, titleIconRenderOptions);
|
30433
30444
|
const overlayImage = {
|
30434
|
-
title: message.senderDisplayName || '',
|
30445
|
+
title: (message === null || message === void 0 ? void 0 : message.senderDisplayName) || '',
|
30435
30446
|
titleIcon: titleIcon,
|
30436
30447
|
attachmentId: attachment.id,
|
30437
30448
|
imageSrc: imageSrc,
|
@@ -30442,18 +30453,18 @@ const ChatScreen = (props) => {
|
|
30442
30453
|
setOverlayImageItem(overlayImage);
|
30443
30454
|
}, [adapter, adapterChatMessages, onRenderAvatarCallback, userId, threadId]);
|
30444
30455
|
const onRenderInlineImage = React.useCallback((inlineImage, defaultOnRender) => {
|
30445
|
-
var _a, _b;
|
30456
|
+
var _a, _b, _c;
|
30446
30457
|
const message = adapterChatMessages[inlineImage.messageId];
|
30447
30458
|
const attachment = (_b = (_a = message === null || message === void 0 ? void 0 : message.content) === null || _a === void 0 ? void 0 : _a.attachments) === null || _b === void 0 ? void 0 : _b.find((attachment) => attachment.id === inlineImage.imageAttributes.id);
|
30448
30459
|
if (attachment === undefined) {
|
30449
30460
|
return defaultOnRender(inlineImage);
|
30450
30461
|
}
|
30451
30462
|
let pointerEvents = inlineImage.imageAttributes.src === '' ? 'none' : 'auto';
|
30452
|
-
const resourceCache = message.resourceCache;
|
30463
|
+
const resourceCache = message === null || message === void 0 ? void 0 : message.resourceCache;
|
30453
30464
|
if (resourceCache &&
|
30454
30465
|
attachment.previewUrl &&
|
30455
30466
|
resourceCache[attachment.previewUrl] &&
|
30456
|
-
resourceCache[attachment.previewUrl].error) {
|
30467
|
+
((_c = resourceCache[attachment.previewUrl]) === null || _c === void 0 ? void 0 : _c.error)) {
|
30457
30468
|
pointerEvents = 'none';
|
30458
30469
|
}
|
30459
30470
|
return (React.createElement("span", { key: inlineImage.imageAttributes.id, onClick: () => onInlineImageClicked(inlineImage.imageAttributes.id || '', inlineImage.messageId), tabIndex: 0, role: "button", onKeyDown: (e) => {
|
@@ -30943,7 +30954,7 @@ const getCallEndReason = (call) => {
|
|
30943
30954
|
* If yes, the caller was kicked out of the call, but we need to show them that they left the call.
|
30944
30955
|
* Note: This check will only work for 1:1 PSTN Calls. The subcode is different for 1:N PSTN calls, and we do not need to handle that case.
|
30945
30956
|
*/
|
30946
|
-
if (remoteParticipantsEndedArray
|
30957
|
+
if (remoteParticipantsEndedArray[0] &&
|
30947
30958
|
communicationCommon.isPhoneNumberIdentifier(remoteParticipantsEndedArray[0].identifier) &&
|
30948
30959
|
((_a = call.callEndReason) === null || _a === void 0 ? void 0 : _a.subCode) !== REMOTE_PSTN_USER_HUNG_UP) {
|
30949
30960
|
return CallEndReasons.LEFT_CALL;
|
@@ -31291,23 +31302,27 @@ const createParticipantModifier = (createModifiedParticipant) => {
|
|
31291
31302
|
// if root state is the same, we don't need to update the participants
|
31292
31303
|
if (((_a = state.call) === null || _a === void 0 ? void 0 : _a.remoteParticipants) !== previousParticipantState) {
|
31293
31304
|
modifiedParticipants = {};
|
31294
|
-
const originalParticipants = (_b = state.call) === null || _b === void 0 ? void 0 : _b.remoteParticipants;
|
31295
|
-
for (const key
|
31296
|
-
const modifiedParticipant = createModifiedParticipant(key,
|
31305
|
+
const originalParticipants = Object.entries(((_b = state.call) === null || _b === void 0 ? void 0 : _b.remoteParticipants) || {});
|
31306
|
+
for (const [key, originalParticipant] of originalParticipants) {
|
31307
|
+
const modifiedParticipant = createModifiedParticipant(key, originalParticipant);
|
31297
31308
|
if (modifiedParticipant === undefined) {
|
31298
|
-
modifiedParticipants[key] =
|
31309
|
+
modifiedParticipants[key] = originalParticipant;
|
31299
31310
|
continue;
|
31300
31311
|
}
|
31301
31312
|
// Generate the new item if original cached item has been changed
|
31302
|
-
if (((_c = memoizedParticipants[key]) === null || _c === void 0 ? void 0 : _c.originalRef) !==
|
31313
|
+
if (((_c = memoizedParticipants[key]) === null || _c === void 0 ? void 0 : _c.originalRef) !== originalParticipant) {
|
31303
31314
|
memoizedParticipants[key] = {
|
31304
31315
|
newParticipant: modifiedParticipant,
|
31305
|
-
originalRef:
|
31316
|
+
originalRef: originalParticipant
|
31306
31317
|
};
|
31307
31318
|
}
|
31308
31319
|
// the modified participant is always coming from the memoized cache, whether is was refreshed
|
31309
31320
|
// from the previous closure or not
|
31310
|
-
|
31321
|
+
const memoizedParticipant = memoizedParticipants[key];
|
31322
|
+
if (!memoizedParticipant) {
|
31323
|
+
throw new Error('Participant modifier encountered an unhandled exception.');
|
31324
|
+
}
|
31325
|
+
modifiedParticipants[key] = memoizedParticipant.newParticipant;
|
31311
31326
|
}
|
31312
31327
|
previousParticipantState = (_d = state.call) === null || _d === void 0 ? void 0 : _d.remoteParticipants;
|
31313
31328
|
}
|
@@ -33016,7 +33031,7 @@ const useParticipantChangedAnnouncement = () => {
|
|
33016
33031
|
* Generates the announcement string for when a participant joins or leaves a call.
|
33017
33032
|
*/
|
33018
33033
|
const createAnnouncementString = (direction, participants, strings) => {
|
33019
|
-
var _a, _b, _c;
|
33034
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
|
33020
33035
|
/**
|
33021
33036
|
* If there are no participants return empty string.
|
33022
33037
|
*/
|
@@ -33039,20 +33054,19 @@ const createAnnouncementString = (direction, participants, strings) => {
|
|
33039
33054
|
numOfParticipants: (sortedParticipants.length - 1).toString()
|
33040
33055
|
});
|
33041
33056
|
}
|
33042
|
-
const participantNames = sortedParticipants.map((p) => { var _a; return (_a = p.displayName) !== null && _a !== void 0 ? _a : strings.unnamedParticipantString; });
|
33043
33057
|
switch (sortedParticipants.length) {
|
33044
33058
|
case 1:
|
33045
|
-
return _formatString(direction === 'joined' ? strings.participantJoinedNoticeString : strings.participantLeftNoticeString, { displayName:
|
33059
|
+
return _formatString(direction === 'joined' ? strings.participantJoinedNoticeString : strings.participantLeftNoticeString, { displayName: (_b = (_a = sortedParticipants[0]) === null || _a === void 0 ? void 0 : _a.displayName) !== null && _b !== void 0 ? _b : strings.unnamedParticipantString });
|
33046
33060
|
case 2:
|
33047
33061
|
return _formatString(direction === 'joined' ? strings.twoParticipantJoinedNoticeString : strings.twoParticipantLeftNoticeString, {
|
33048
|
-
displayName1:
|
33049
|
-
displayName2:
|
33062
|
+
displayName1: (_d = (_c = sortedParticipants[0]) === null || _c === void 0 ? void 0 : _c.displayName) !== null && _d !== void 0 ? _d : strings.unnamedParticipantString,
|
33063
|
+
displayName2: (_f = (_e = sortedParticipants[1]) === null || _e === void 0 ? void 0 : _e.displayName) !== null && _f !== void 0 ? _f : strings.unnamedParticipantString
|
33050
33064
|
});
|
33051
33065
|
case 3:
|
33052
33066
|
return _formatString(direction === 'joined' ? strings.threeParticipantJoinedNoticeString : strings.threeParticipantLeftNoticeString, {
|
33053
|
-
displayName1:
|
33054
|
-
displayName2:
|
33055
|
-
displayName3:
|
33067
|
+
displayName1: (_h = (_g = sortedParticipants[0]) === null || _g === void 0 ? void 0 : _g.displayName) !== null && _h !== void 0 ? _h : strings.unnamedParticipantString,
|
33068
|
+
displayName2: (_k = (_j = sortedParticipants[1]) === null || _j === void 0 ? void 0 : _j.displayName) !== null && _k !== void 0 ? _k : strings.unnamedParticipantString,
|
33069
|
+
displayName3: (_m = (_l = sortedParticipants[2]) === null || _l === void 0 ? void 0 : _l.displayName) !== null && _m !== void 0 ? _m : strings.unnamedParticipantString
|
33056
33070
|
});
|
33057
33071
|
}
|
33058
33072
|
/**
|
@@ -33064,9 +33078,9 @@ const createAnnouncementString = (direction, participants, strings) => {
|
|
33064
33078
|
*/
|
33065
33079
|
const numberOfExtraParticipants = sortedParticipants.length - 3;
|
33066
33080
|
return _formatString(direction === 'joined' ? strings.manyParticipantsJoined : strings.manyParticipantsLeft, {
|
33067
|
-
displayName1: (
|
33068
|
-
displayName2: (
|
33069
|
-
displayName3: (
|
33081
|
+
displayName1: (_p = (_o = sortedParticipants[0]) === null || _o === void 0 ? void 0 : _o.displayName) !== null && _p !== void 0 ? _p : strings.unnamedParticipantString,
|
33082
|
+
displayName2: (_r = (_q = sortedParticipants[1]) === null || _q === void 0 ? void 0 : _q.displayName) !== null && _r !== void 0 ? _r : strings.unnamedParticipantString,
|
33083
|
+
displayName3: (_t = (_s = sortedParticipants[2]) === null || _s === void 0 ? void 0 : _s.displayName) !== null && _t !== void 0 ? _t : strings.unnamedParticipantString,
|
33070
33084
|
numOfParticipants: numberOfExtraParticipants.toString()
|
33071
33085
|
});
|
33072
33086
|
};
|
@@ -35506,7 +35520,7 @@ const usePeoplePane = (props) => {
|
|
35506
35520
|
/* @conditional-compile-remove(soft-mute) */
|
35507
35521
|
if (onMuteParticipant && !isMe && remoteParticipants && remoteParticipants[participantId]) {
|
35508
35522
|
const participant = remoteParticipants[participantId];
|
35509
|
-
const isMuted = participant.isMuted;
|
35523
|
+
const isMuted = !!(participant === null || participant === void 0 ? void 0 : participant.isMuted);
|
35510
35524
|
_defaultMenuItems.push({
|
35511
35525
|
key: 'mute',
|
35512
35526
|
text: 'Mute',
|
@@ -35796,7 +35810,7 @@ const MeetingPhoneInfoPaneContent = (props) => {
|
|
35796
35810
|
return (React.createElement(react.Stack, { verticalFill: true, styles: phoneInfoContainerStyle, tokens: phoneInfoContainerTokens, "data-ui-id": "phone-info-pane-content" },
|
35797
35811
|
(conferencePhoneInfoList === undefined || conferencePhoneInfoList.length === 0) && (React.createElement(react.Stack, { horizontal: true },
|
35798
35812
|
React.createElement(react.Text, { className: phoneInfoTextStyle }, localeStrings.meetingConferencePhoneInfoModalNoPhoneAvailable))),
|
35799
|
-
conferencePhoneInfoList && conferencePhoneInfoList
|
35813
|
+
conferencePhoneInfoList && conferencePhoneInfoList[0] && (React.createElement(react.Stack, null,
|
35800
35814
|
React.createElement(react.Stack, { horizontal: true, horizontalAlign: "space-between", className: phoneInfoInstructionLine },
|
35801
35815
|
React.createElement(react.Stack.Item, null,
|
35802
35816
|
React.createElement(react.Stack, { horizontal: true, className: phoneInfoStep },
|
@@ -36207,7 +36221,7 @@ const findDominantRemoteParticipant = (remoteParticipants, dominantSpeakerIds) =
|
|
36207
36221
|
if (!dominantRemoteParticipantId || !remoteParticipantIds.includes(dominantRemoteParticipantId)) {
|
36208
36222
|
dominantRemoteParticipantId = remoteParticipantIds[0];
|
36209
36223
|
}
|
36210
|
-
return remoteParticipants[dominantRemoteParticipantId];
|
36224
|
+
return dominantRemoteParticipantId ? remoteParticipants[dominantRemoteParticipantId] : undefined;
|
36211
36225
|
};
|
36212
36226
|
|
36213
36227
|
// Copyright (c) Microsoft Corporation.
|
@@ -36289,7 +36303,11 @@ const ModalLocalAndRemotePIP = (props) => {
|
|
36289
36303
|
const [touchStartTouches, setTouchStartTouches] = React.useState(null);
|
36290
36304
|
const onTouchEnd = React.useCallback((event) => {
|
36291
36305
|
var _a;
|
36292
|
-
if (touchStartTouches &&
|
36306
|
+
if (touchStartTouches &&
|
36307
|
+
touchStartTouches[0] &&
|
36308
|
+
touchStartTouches.length === 1 &&
|
36309
|
+
event.changedTouches[0] &&
|
36310
|
+
event.changedTouches.length === 1) {
|
36293
36311
|
const touchStartTouch = touchStartTouches[0];
|
36294
36312
|
const touchEndTouch = event.changedTouches[0];
|
36295
36313
|
if (Math.abs(touchStartTouch.clientX - touchEndTouch.clientX) < 10 &&
|
@@ -37266,7 +37284,7 @@ const NetworkReconnectTile = (props) => {
|
|
37266
37284
|
React.createElement(CallCompositeIcon, { iconName: "NetworkReconnectIcon", className: react.mergeStyles(titleStyle$1(palette, isVideoReady)) }),
|
37267
37285
|
React.createElement(react.Text, { className: react.mergeStyles(titleStyle$1(palette, isVideoReady)), "aria-live": 'assertive' }, strings.networkReconnectTitle)),
|
37268
37286
|
React.createElement(react.Text, { className: react.mergeStyles(moreDetailsStyle$1(palette, isVideoReady)), "aria-live": 'assertive' }, strings.networkReconnectMoreDetails),
|
37269
|
-
isTeamsMeeting && meetingCoordinates && meetingCoordinates
|
37287
|
+
isTeamsMeeting && meetingCoordinates && meetingCoordinates[0] && (React.createElement(react.Stack, null,
|
37270
37288
|
React.createElement(react.Stack, { horizontal: true, horizontalAlign: "center", verticalAlign: "center", className: titleContainerClassName },
|
37271
37289
|
React.createElement(react.Text, { className: titleClassName }, localeStrings.meetingConferencePhoneInfoModalTitle)),
|
37272
37290
|
React.createElement(react.Stack, { horizontal: true, horizontalAlign: "space-between", className: phoneInfoInstructionLine },
|
@@ -37935,10 +37953,10 @@ const getOptionIcon = (type) => {
|
|
37935
37953
|
}
|
37936
37954
|
};
|
37937
37955
|
const onRenderTitle = (iconType, props) => {
|
37938
|
-
|
37956
|
+
var _a;
|
37939
37957
|
return props ? (React.createElement("div", { className: dropDownTitleIconStyles },
|
37940
|
-
|
37941
|
-
React.createElement("span", null, props[0].text))) : (React.createElement(React.Fragment, null));
|
37958
|
+
getOptionIcon(iconType),
|
37959
|
+
React.createElement("span", null, (_a = props[0]) === null || _a === void 0 ? void 0 : _a.text))) : (React.createElement(React.Fragment, null));
|
37942
37960
|
};
|
37943
37961
|
const localVideoViewOptions = {
|
37944
37962
|
scalingMode: 'Crop',
|
@@ -37992,7 +38010,13 @@ const LocalDeviceSettings = (props) => {
|
|
37992
38010
|
? (_b = props.cameras[0]) === null || _b === void 0 ? void 0 : _b.id
|
37993
38011
|
: ''
|
37994
38012
|
: 'deniedOrUnknown', onChange: (event, option, index) => {
|
37995
|
-
props.
|
38013
|
+
const camera = props.cameras[index !== null && index !== void 0 ? index : 0];
|
38014
|
+
if (camera) {
|
38015
|
+
props.onSelectCamera(camera, localVideoViewOptions);
|
38016
|
+
}
|
38017
|
+
else {
|
38018
|
+
console.error('No cameras available');
|
38019
|
+
}
|
37996
38020
|
}, onRenderTitle: (props) => onRenderTitle('Camera', props) }));
|
37997
38021
|
const micGrantedDropdown = (React.createElement(React.Fragment, null, roleCanUseMic && (React.createElement(react.Dropdown, { "aria-labelledby": 'call-composite-local-sound-settings-label', placeholder: hasMicrophones ? defaultPlaceHolder : noMicLabel, styles: dropDownStyles(theme), disabled: !micPermissionGranted || !hasMicrophones, errorMessage: props.microphonePermissionGranted === undefined || props.microphonePermissionGranted
|
37998
38022
|
? undefined
|
@@ -38001,10 +38025,22 @@ const LocalDeviceSettings = (props) => {
|
|
38001
38025
|
? props.selectedMicrophone.id
|
38002
38026
|
: defaultDeviceId(props.microphones)
|
38003
38027
|
: 'deniedOrUnknown', onChange: (event, option, index) => {
|
38004
|
-
props.
|
38028
|
+
const microphone = props.microphones[index !== null && index !== void 0 ? index : 0];
|
38029
|
+
if (microphone) {
|
38030
|
+
props.onSelectMicrophone(microphone);
|
38031
|
+
}
|
38032
|
+
else {
|
38033
|
+
console.error('No microphones available');
|
38034
|
+
}
|
38005
38035
|
}, onRenderTitle: (props) => onRenderTitle('Microphone', props) }))));
|
38006
38036
|
const speakerDropdown = (React.createElement(react.Dropdown, { "aria-labelledby": 'call-composite-local-sound-settings-label', placeholder: hasSpeakers ? defaultPlaceHolder : noSpeakersLabel, styles: dropDownStyles(theme), disabled: props.speakers.length === 0, options: getDropDownList(props.speakers), defaultSelectedKey: props.selectedSpeaker ? props.selectedSpeaker.id : defaultDeviceId(props.speakers), onChange: (event, option, index) => {
|
38007
|
-
props.
|
38037
|
+
const speaker = props.speakers[index !== null && index !== void 0 ? index : 0];
|
38038
|
+
if (speaker) {
|
38039
|
+
props.onSelectSpeaker(speaker);
|
38040
|
+
}
|
38041
|
+
else {
|
38042
|
+
console.error('No speakers available');
|
38043
|
+
}
|
38008
38044
|
}, onRenderTitle: (props) => onRenderTitle('Speaker', props) }));
|
38009
38045
|
const safariBrowserSpeakerDropdownTrampoline = () => {
|
38010
38046
|
/* @conditional-compile-remove(calling-environment-info) */
|
@@ -38034,14 +38070,15 @@ const LocalDeviceSettings = (props) => {
|
|
38034
38070
|
safariBrowserSpeakerDropdownTrampoline()))));
|
38035
38071
|
};
|
38036
38072
|
const defaultDeviceId = (devices) => {
|
38073
|
+
var _a;
|
38037
38074
|
if (devices.length === 0) {
|
38038
|
-
return
|
38075
|
+
return undefined;
|
38039
38076
|
}
|
38040
38077
|
const defaultDevice = devices.find((device) => device.isSystemDefault);
|
38041
38078
|
if (defaultDevice) {
|
38042
38079
|
return defaultDevice.id;
|
38043
38080
|
}
|
38044
|
-
return devices[0].id;
|
38081
|
+
return (_a = devices[0]) === null || _a === void 0 ? void 0 : _a.id;
|
38045
38082
|
};
|
38046
38083
|
|
38047
38084
|
// Copyright (c) Microsoft Corporation.
|
@@ -38100,11 +38137,12 @@ const devicePermissionSelector = reselect__namespace.createSelector([getDeviceMa
|
|
38100
38137
|
* @private
|
38101
38138
|
*/
|
38102
38139
|
const localPreviewSelector = reselect__namespace.createSelector([getDeviceManager], (deviceManager) => {
|
38140
|
+
var _a;
|
38103
38141
|
// TODO: we should take in a LocalVideoStream that developer wants to use as their 'Preview' view. We should also
|
38104
38142
|
// handle cases where 'Preview' view is in progress and not necessary completed.
|
38105
38143
|
const view = deviceManager.cameras.length > 0 && // This ensures that the video stream is reset if camera devices are removed.
|
38106
38144
|
deviceManager.unparentedViews.length > 0 &&
|
38107
|
-
deviceManager.unparentedViews[0].view;
|
38145
|
+
((_a = deviceManager.unparentedViews[0]) === null || _a === void 0 ? void 0 : _a.view);
|
38108
38146
|
return {
|
38109
38147
|
videoStreamElement: view ? view.target : null
|
38110
38148
|
};
|
@@ -39051,6 +39089,9 @@ const TransferTile = (props) => {
|
|
39051
39089
|
const [personaSize, setPersonaSize] = React.useState();
|
39052
39090
|
const tileRef = React.useRef(null);
|
39053
39091
|
const observer = React.useRef(new ResizeObserver((entries) => {
|
39092
|
+
if (!entries[0]) {
|
39093
|
+
return;
|
39094
|
+
}
|
39054
39095
|
const { width, height } = entries[0].contentRect;
|
39055
39096
|
const personaSize = Math.min(width, height) / 2;
|
39056
39097
|
setPersonaSize(Math.max(Math.min(personaSize, 150), 32));
|
@@ -39802,7 +39843,7 @@ const MainScreen = (props) => {
|
|
39802
39843
|
'recordingAndTranscriptionStopped',
|
39803
39844
|
'recordingStoppedStillTranscribing',
|
39804
39845
|
'transcriptionStoppedStillRecording'
|
39805
|
-
].includes(
|
39846
|
+
].includes(notification.type)) {
|
39806
39847
|
activeNotifications.splice(index, 1);
|
39807
39848
|
}
|
39808
39849
|
});
|
@@ -40078,18 +40119,23 @@ const createProfileStateModifier = (onFetchProfile, notifyUpdate) => {
|
|
40078
40119
|
const originalParticipants = (_a = state.call) === null || _a === void 0 ? void 0 : _a.remoteParticipants;
|
40079
40120
|
(() => __awaiter$8(void 0, void 0, void 0, function* () {
|
40080
40121
|
let shouldNotifyUpdates = false;
|
40081
|
-
|
40122
|
+
if (!originalParticipants) {
|
40123
|
+
return;
|
40124
|
+
}
|
40125
|
+
for (const [key, participant] of Object.entries(originalParticipants)) {
|
40082
40126
|
if (cachedDisplayName[key]) {
|
40083
40127
|
continue;
|
40084
40128
|
}
|
40085
|
-
const profile = yield onFetchProfile(key, { displayName:
|
40086
|
-
if ((profile === null || profile === void 0 ? void 0 : profile.displayName) &&
|
40129
|
+
const profile = yield onFetchProfile(key, { displayName: participant.displayName });
|
40130
|
+
if ((profile === null || profile === void 0 ? void 0 : profile.displayName) && participant.displayName !== (profile === null || profile === void 0 ? void 0 : profile.displayName)) {
|
40087
40131
|
cachedDisplayName[key] = profile === null || profile === void 0 ? void 0 : profile.displayName;
|
40088
40132
|
shouldNotifyUpdates = true;
|
40089
40133
|
}
|
40090
40134
|
}
|
40091
40135
|
// notify update only when there is a change, which most likely will trigger modifier and setState again
|
40092
|
-
|
40136
|
+
if (shouldNotifyUpdates) {
|
40137
|
+
notifyUpdate();
|
40138
|
+
}
|
40093
40139
|
}))();
|
40094
40140
|
const participantsModifier = createParticipantModifier((id, participant) => {
|
40095
40141
|
if (cachedDisplayName[id]) {
|
@@ -40110,17 +40156,17 @@ const CALL_TRANSFER_SUBCODE = 7015;
|
|
40110
40156
|
* @private
|
40111
40157
|
*/
|
40112
40158
|
class CallingSoundSubscriber {
|
40113
|
-
constructor(call,
|
40159
|
+
constructor(call, callees, sounds) {
|
40114
40160
|
this.playingSounds = false;
|
40115
40161
|
this.onCallStateChanged = () => {
|
40116
40162
|
this.call.on('stateChanged', () => {
|
40117
40163
|
var _a, _b, _c, _d, _e, _f, _g;
|
40118
|
-
if (shouldPlayRinging(this.call, this.
|
40164
|
+
if (shouldPlayRinging(this.call, this.callees) && ((_a = this.soundsLoaded) === null || _a === void 0 ? void 0 : _a.callRingingSound)) {
|
40119
40165
|
this.soundsLoaded.callRingingSound.loop = true;
|
40120
40166
|
this.playSound(this.soundsLoaded.callRingingSound);
|
40121
40167
|
this.playingSounds = true;
|
40122
40168
|
}
|
40123
|
-
if (!shouldPlayRinging(this.call, this.
|
40169
|
+
if (!shouldPlayRinging(this.call, this.callees) && ((_b = this.soundsLoaded) === null || _b === void 0 ? void 0 : _b.callRingingSound)) {
|
40124
40170
|
this.soundsLoaded.callRingingSound.loop = false;
|
40125
40171
|
this.soundsLoaded.callRingingSound.pause();
|
40126
40172
|
this.playingSounds = false;
|
@@ -40140,7 +40186,7 @@ class CallingSoundSubscriber {
|
|
40140
40186
|
});
|
40141
40187
|
};
|
40142
40188
|
this.call = call;
|
40143
|
-
this.
|
40189
|
+
this.callees = callees;
|
40144
40190
|
if (sounds) {
|
40145
40191
|
this.soundsLoaded = this.loadSounds(sounds);
|
40146
40192
|
this.subscribeCallSoundEvents();
|
@@ -40204,10 +40250,10 @@ class CallingSoundSubscriber {
|
|
40204
40250
|
* Helper function to allow the calling sound subscriber to determine when to play the ringing
|
40205
40251
|
* sound when making an outbound call.
|
40206
40252
|
*/
|
40207
|
-
const shouldPlayRinging = (call,
|
40208
|
-
if (
|
40209
|
-
|
40210
|
-
!communicationCommon.isPhoneNumberIdentifier(
|
40253
|
+
const shouldPlayRinging = (call, callees) => {
|
40254
|
+
if (callees &&
|
40255
|
+
callees[0] &&
|
40256
|
+
!communicationCommon.isPhoneNumberIdentifier(callees[0]) &&
|
40211
40257
|
(call.state === 'Ringing' || call.state === 'Connecting')) {
|
40212
40258
|
return true;
|
40213
40259
|
}
|
@@ -40378,7 +40424,7 @@ const findLatestEndedCall = (calls) => {
|
|
40378
40424
|
}
|
40379
40425
|
let latestCall = callStates[0];
|
40380
40426
|
for (const call of callStates.slice(1)) {
|
40381
|
-
if (((_b = (_a = call.endTime) === null || _a === void 0 ? void 0 : _a.getTime()) !== null && _b !== void 0 ? _b : 0) > ((_d = (_c = latestCall.endTime) === null || _c === void 0 ? void 0 : _c.getTime()) !== null && _d !== void 0 ? _d : 0)) {
|
40427
|
+
if (((_b = (_a = call.endTime) === null || _a === void 0 ? void 0 : _a.getTime()) !== null && _b !== void 0 ? _b : 0) > ((_d = (_c = latestCall === null || latestCall === void 0 ? void 0 : latestCall.endTime) === null || _c === void 0 ? void 0 : _c.getTime()) !== null && _d !== void 0 ? _d : 0)) {
|
40382
40428
|
latestCall = call;
|
40383
40429
|
}
|
40384
40430
|
}
|
@@ -40392,7 +40438,7 @@ const findLatestAcceptedTransfer = (acceptedTransfers) => {
|
|
40392
40438
|
}
|
40393
40439
|
let latestAcceptedTransfer = acceptedTransferValues[0];
|
40394
40440
|
for (const acceptedTransfer of acceptedTransferValues.slice(1)) {
|
40395
|
-
if (((_b = (_a = acceptedTransfer.timestamp) === null || _a === void 0 ? void 0 : _a.getTime()) !== null && _b !== void 0 ? _b : 0) > ((_d = (_c = latestAcceptedTransfer.timestamp) === null || _c === void 0 ? void 0 : _c.getTime()) !== null && _d !== void 0 ? _d : 0)) {
|
40441
|
+
if (((_b = (_a = acceptedTransfer.timestamp) === null || _a === void 0 ? void 0 : _a.getTime()) !== null && _b !== void 0 ? _b : 0) > ((_d = (_c = latestAcceptedTransfer === null || latestAcceptedTransfer === void 0 ? void 0 : latestAcceptedTransfer.timestamp) === null || _c === void 0 ? void 0 : _c.getTime()) !== null && _d !== void 0 ? _d : 0)) {
|
40396
40442
|
latestAcceptedTransfer = acceptedTransfer;
|
40397
40443
|
}
|
40398
40444
|
}
|
@@ -40484,18 +40530,24 @@ class AzureCommunicationCallAdapter {
|
|
40484
40530
|
if (this.callAgent.kind === 'CallAgent') {
|
40485
40531
|
const onCallsUpdated = (args) => {
|
40486
40532
|
var _a;
|
40487
|
-
if ((_a = this.call) === null || _a === void 0 ? void 0 : _a.id) {
|
40488
|
-
|
40489
|
-
|
40490
|
-
|
40491
|
-
|
40492
|
-
|
40493
|
-
const transferCall = _callAgent.calls.find((call) => call.id === (latestAcceptedTransfer === null || latestAcceptedTransfer === void 0 ? void 0 : latestAcceptedTransfer.callId));
|
40494
|
-
if (transferCall) {
|
40495
|
-
this.processNewCall(transferCall);
|
40496
|
-
}
|
40497
|
-
}
|
40533
|
+
if (!((_a = this.call) === null || _a === void 0 ? void 0 : _a.id)) {
|
40534
|
+
return;
|
40535
|
+
}
|
40536
|
+
const removedCall = args.removed.find((call) => { var _a; return call.id === ((_a = this.call) === null || _a === void 0 ? void 0 : _a.id); });
|
40537
|
+
if (!removedCall) {
|
40538
|
+
return;
|
40498
40539
|
}
|
40540
|
+
const removedCallState = this.callClient.getState().callsEnded[removedCall.id];
|
40541
|
+
if (!removedCallState) {
|
40542
|
+
return;
|
40543
|
+
}
|
40544
|
+
const latestAcceptedTransfer = findLatestAcceptedTransfer(removedCallState.transfer.acceptedTransfers);
|
40545
|
+
const _callAgent = callAgent;
|
40546
|
+
const transferCall = _callAgent.calls.find((call) => call.id === (latestAcceptedTransfer === null || latestAcceptedTransfer === void 0 ? void 0 : latestAcceptedTransfer.callId));
|
40547
|
+
if (!transferCall) {
|
40548
|
+
return;
|
40549
|
+
}
|
40550
|
+
this.processNewCall(transferCall);
|
40499
40551
|
};
|
40500
40552
|
this.callAgent.on('callsUpdated', onCallsUpdated);
|
40501
40553
|
}
|
@@ -40503,18 +40555,24 @@ class AzureCommunicationCallAdapter {
|
|
40503
40555
|
if (this.callAgent.kind === 'TeamsCallAgent') {
|
40504
40556
|
const onTeamsCallsUpdated = (args) => {
|
40505
40557
|
var _a;
|
40506
|
-
if ((_a = this.call) === null || _a === void 0 ? void 0 : _a.id) {
|
40507
|
-
|
40508
|
-
|
40509
|
-
|
40510
|
-
|
40511
|
-
|
40512
|
-
|
40513
|
-
|
40514
|
-
|
40515
|
-
|
40516
|
-
|
40558
|
+
if (!((_a = this.call) === null || _a === void 0 ? void 0 : _a.id)) {
|
40559
|
+
return;
|
40560
|
+
}
|
40561
|
+
const removedCall = args.removed.find((call) => { var _a; return call.id === ((_a = this.call) === null || _a === void 0 ? void 0 : _a.id); });
|
40562
|
+
if (!removedCall) {
|
40563
|
+
return;
|
40564
|
+
}
|
40565
|
+
const removedCallState = this.callClient.getState().callsEnded[removedCall.id];
|
40566
|
+
if (!removedCallState) {
|
40567
|
+
return;
|
40568
|
+
}
|
40569
|
+
const latestAcceptedTransfer = findLatestAcceptedTransfer(removedCallState.transfer.acceptedTransfers);
|
40570
|
+
const _callAgent = callAgent;
|
40571
|
+
const transferCall = _callAgent.calls.find((call) => call.id === (latestAcceptedTransfer === null || latestAcceptedTransfer === void 0 ? void 0 : latestAcceptedTransfer.callId));
|
40572
|
+
if (!transferCall) {
|
40573
|
+
return;
|
40517
40574
|
}
|
40575
|
+
this.processNewCall(transferCall);
|
40518
40576
|
};
|
40519
40577
|
this.callAgent.on('callsUpdated', onTeamsCallsUpdated);
|
40520
40578
|
}
|
@@ -41333,7 +41391,7 @@ class AzureCommunicationCallAdapter {
|
|
41333
41391
|
var _a;
|
41334
41392
|
// Get origin call id of breakout room call
|
41335
41393
|
const breakoutRoomCallState = this.callClient.getState().calls[currentBreakoutRoomCallId];
|
41336
|
-
const originCallId = (_a = breakoutRoomCallState.breakoutRooms) === null || _a === void 0 ? void 0 : _a.breakoutRoomOriginCallId;
|
41394
|
+
const originCallId = (_a = breakoutRoomCallState === null || breakoutRoomCallState === void 0 ? void 0 : breakoutRoomCallState.breakoutRooms) === null || _a === void 0 ? void 0 : _a.breakoutRoomOriginCallId;
|
41337
41395
|
// Get other breakout room calls with the same origin call
|
41338
41396
|
const otherBreakoutRoomCallStates = Object.values(this.callClient.getState().calls).filter((callState) => {
|
41339
41397
|
var _a;
|
@@ -44429,4 +44487,4 @@ exports.useTeamsCall = useTeamsCall;
|
|
44429
44487
|
exports.useTeamsCallAdapter = useTeamsCallAdapter;
|
44430
44488
|
exports.useTeamsCallAgent = useTeamsCallAgent;
|
44431
44489
|
exports.useTheme = useTheme;
|
44432
|
-
//# sourceMappingURL=index-
|
44490
|
+
//# sourceMappingURL=index-CtfGMAPa.js.map
|