@azure/communication-react 1.7.0-alpha-202307210013 → 1.7.0-alpha-202307250014
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 +2 -1
- package/dist/dist-cjs/communication-react/index.js +35 -14
- package/dist/dist-cjs/communication-react/index.js.map +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/calling-component-bindings/src/handlers/createTeamsCallHandlers.js +10 -0
- package/dist/dist-esm/calling-component-bindings/src/handlers/createTeamsCallHandlers.js.map +1 -1
- package/dist/dist-esm/calling-component-bindings/src/participantListSelector.js +10 -1
- package/dist/dist-esm/calling-component-bindings/src/participantListSelector.js.map +1 -1
- package/dist/dist-esm/calling-component-bindings/src/utils/callUtils.js +1 -1
- package/dist/dist-esm/calling-component-bindings/src/utils/callUtils.js.map +1 -1
- package/dist/dist-esm/calling-component-bindings/src/utils/videoGalleryUtils.js +2 -1
- package/dist/dist-esm/calling-component-bindings/src/utils/videoGalleryUtils.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarativeCommon.js +6 -2
- package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarativeCommon.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/CallClientState.d.ts +2 -1
- package/dist/dist-esm/calling-stateful-client/src/CallClientState.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/CaptionsBanner.js +3 -3
- package/dist/dist-esm/react-components/src/components/CaptionsBanner.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/styles/Captions.style.d.ts +2 -2
- package/dist/dist-esm/react-components/src/components/styles/Captions.style.js +9 -5
- package/dist/dist-esm/react-components/src/components/styles/Captions.style.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/common/CaptionsBanner.js +1 -1
- package/dist/dist-esm/react-composites/src/composites/common/CaptionsBanner.js.map +1 -1
- package/package.json +13 -13
@@ -68,6 +68,7 @@ import { LatestNetworkDiagnostics } from '@azure/communication-calling';
|
|
68
68
|
import { LocalVideoStream } from '@azure/communication-calling';
|
69
69
|
import type { MediaDiagnosticChangedEventArgs } from '@azure/communication-calling';
|
70
70
|
import { MediaStreamType } from '@azure/communication-calling';
|
71
|
+
import { MicrosoftBotKind } from '@azure/communication-common';
|
71
72
|
import { MicrosoftTeamsUserIdentifier } from '@azure/communication-common';
|
72
73
|
import { MicrosoftTeamsUserKind } from '@azure/communication-common';
|
73
74
|
import type { NetworkDiagnosticChangedEventArgs } from '@azure/communication-calling';
|
@@ -8050,7 +8051,7 @@ export declare interface RemoteParticipantState {
|
|
8050
8051
|
/**
|
8051
8052
|
* Proxy of {@link @azure/communication-calling#RemoteParticipant.identifier}.
|
8052
8053
|
*/
|
8053
|
-
identifier: CommunicationUserKind | PhoneNumberKind | MicrosoftTeamsUserKind | UnknownIdentifierKind;
|
8054
|
+
identifier: CommunicationUserKind | PhoneNumberKind | MicrosoftTeamsUserKind | UnknownIdentifierKind | /* @conditional-compile-remove(communication-common-beta-v3) */ MicrosoftBotKind;
|
8054
8055
|
/**
|
8055
8056
|
* Proxy of {@link @azure/communication-calling#RemoteParticipant.displayName}.
|
8056
8057
|
*/
|
@@ -178,7 +178,7 @@ const _isValidIdentifier = (identifier) => {
|
|
178
178
|
// Copyright (c) Microsoft Corporation.
|
179
179
|
// Licensed under the MIT license.
|
180
180
|
// GENERATED FILE. DO NOT EDIT MANUALLY.
|
181
|
-
var telemetryVersion = '1.7.0-alpha-
|
181
|
+
var telemetryVersion = '1.7.0-alpha-202307250014';
|
182
182
|
|
183
183
|
// Copyright (c) Microsoft Corporation.
|
184
184
|
/**
|
@@ -518,7 +518,7 @@ const isTeamsCallParticipants = (participants) => {
|
|
518
518
|
* Checks whether the user is a 'Ringing' PSTN user.
|
519
519
|
*/
|
520
520
|
const _isRingingPSTNParticipant = (participant) => {
|
521
|
-
return participant.identifier
|
521
|
+
return communicationCommon.isPhoneNumberIdentifier(participant.identifier) && participant.state === 'Connecting'
|
522
522
|
? 'Ringing'
|
523
523
|
: participant.state;
|
524
524
|
};
|
@@ -1037,6 +1037,10 @@ const createDefaultTeamsCallingHandlers = memoizeOne__default['default']((callCl
|
|
1037
1037
|
if (communicationCommon.isCommunicationUserIdentifier(participant)) {
|
1038
1038
|
throw new Error('CommunicationIdentifier in Teams call is not supported!');
|
1039
1039
|
}
|
1040
|
+
/* @conditional-compile-remove(communication-common-beta-v3) */
|
1041
|
+
if (communicationCommon.isMicrosoftBotIdentifier(participant)) {
|
1042
|
+
throw new Error('Adding Microsoft Bot Identifier is not supported!');
|
1043
|
+
}
|
1040
1044
|
/* @conditional-compile-remove(teams-identity-support) */
|
1041
1045
|
if (communicationCommon.isPhoneNumberIdentifier(participant)) {
|
1042
1046
|
call === null || call === void 0 ? void 0 : call.addParticipant(participant, threadId ? { threadId } : undefined);
|
@@ -1048,6 +1052,10 @@ const createDefaultTeamsCallingHandlers = memoizeOne__default['default']((callCl
|
|
1048
1052
|
if (communicationCommon.isCommunicationUserIdentifier(participant)) {
|
1049
1053
|
throw new Error('CommunicationIdentifier in Teams call is not supported!');
|
1050
1054
|
}
|
1055
|
+
/* @conditional-compile-remove(communication-common-beta-v3) */
|
1056
|
+
if (communicationCommon.isMicrosoftBotIdentifier(participant)) {
|
1057
|
+
throw new Error('Removing Microsoft Bot Identifier is not supported!');
|
1058
|
+
}
|
1051
1059
|
/* @conditional-compile-remove(teams-identity-support) */
|
1052
1060
|
yield (call === null || call === void 0 ? void 0 : call.removeParticipant(participant));
|
1053
1061
|
}) });
|
@@ -3690,7 +3698,9 @@ class ProxyCallAgentCommon {
|
|
3690
3698
|
}
|
3691
3699
|
case 'on': {
|
3692
3700
|
return (...args) => {
|
3693
|
-
|
3701
|
+
// typescript is not smart enough to handle multiple overloads and pull the correct type here so force casting args
|
3702
|
+
const event = args[0];
|
3703
|
+
const isCallsUpdated = event === 'callsUpdated';
|
3694
3704
|
if (isCallsUpdated) {
|
3695
3705
|
const listener = args[1];
|
3696
3706
|
this._externalCallsUpdatedListeners.add(listener);
|
@@ -3702,7 +3712,9 @@ class ProxyCallAgentCommon {
|
|
3702
3712
|
}
|
3703
3713
|
case 'off': {
|
3704
3714
|
return (...args) => {
|
3705
|
-
|
3715
|
+
// typescript is not smart enough to handle multiple overloads and pull the correct type here so force casting args
|
3716
|
+
const event = args[0];
|
3717
|
+
const isCallsUpdated = event === 'callsUpdated';
|
3706
3718
|
if (isCallsUpdated) {
|
3707
3719
|
const listener = args[1];
|
3708
3720
|
this._externalCallsUpdatedListeners.delete(listener);
|
@@ -16221,17 +16233,21 @@ const captionContainerClassName = react.mergeStyles({
|
|
16221
16233
|
/**
|
16222
16234
|
* @private
|
16223
16235
|
*/
|
16224
|
-
const
|
16236
|
+
const captionsBannerStyles = (formFactor) => {
|
16225
16237
|
return {
|
16226
|
-
root: Object.assign({ overflowX: 'hidden', height: formFactor === 'compact' ? '4.5rem' : '
|
16238
|
+
root: Object.assign({ overflowX: 'hidden', height: formFactor === 'compact' ? '4.5rem' : '8.75rem', overflowY: 'auto' }, scrollbarStyles)
|
16227
16239
|
};
|
16228
16240
|
};
|
16229
16241
|
/**
|
16230
16242
|
* @private
|
16231
16243
|
*/
|
16232
|
-
const
|
16233
|
-
|
16234
|
-
|
16244
|
+
const loadingBannerStyles = (formFactor) => {
|
16245
|
+
return {
|
16246
|
+
root: {
|
16247
|
+
height: formFactor === 'compact' ? '4.5rem' : '8.75rem'
|
16248
|
+
}
|
16249
|
+
};
|
16250
|
+
};
|
16235
16251
|
/**
|
16236
16252
|
* @private
|
16237
16253
|
*/
|
@@ -16311,11 +16327,11 @@ const _CaptionsBanner = (props) => {
|
|
16311
16327
|
}, [captions, isAtBottomOfScroll]);
|
16312
16328
|
return (React__default['default'].createElement(React__default['default'].Fragment, null, startCaptionsInProgress && (React__default['default'].createElement(react.FocusZone, { as: "ul", className: captionsContainerClassName },
|
16313
16329
|
isCaptionsOn && (React__default['default'].createElement(c, { innerRef: captionsScrollDivRef },
|
16314
|
-
React__default['default'].createElement(react.Stack, { verticalAlign: "start", styles:
|
16330
|
+
React__default['default'].createElement(react.Stack, { verticalAlign: "start", styles: captionsBannerStyles(formFactor) }, captions.map((caption) => {
|
16315
16331
|
return (React__default['default'].createElement("div", { key: caption.id, className: captionContainerClassName, "data-is-focusable": true },
|
16316
16332
|
React__default['default'].createElement(_Caption, Object.assign({}, caption, { onRenderAvatar: onRenderAvatar }))));
|
16317
16333
|
})))),
|
16318
|
-
!isCaptionsOn && (React__default['default'].createElement(react.Stack, { verticalAlign: "center",
|
16334
|
+
!isCaptionsOn && (React__default['default'].createElement(react.Stack, { verticalAlign: "center", styles: loadingBannerStyles(formFactor), "data-is-focusable": true },
|
16319
16335
|
React__default['default'].createElement(react.Spinner, { label: strings === null || strings === void 0 ? void 0 : strings.captionsBannerSpinnerText, ariaLive: "assertive", labelPosition: "right" })))))));
|
16320
16336
|
};
|
16321
16337
|
|
@@ -16526,7 +16542,7 @@ const _videoGalleryRemoteParticipantsMemo = (remoteParticipants) => {
|
|
16526
16542
|
*/
|
16527
16543
|
.filter((participant) => {
|
16528
16544
|
return (!['InLobby', 'Idle', 'Connecting', 'Disconnected'].includes(participant.state) ||
|
16529
|
-
participant.identifier
|
16545
|
+
communicationCommon.isPhoneNumberIdentifier(participant.identifier));
|
16530
16546
|
})
|
16531
16547
|
.map((participant) => {
|
16532
16548
|
const state = _isRingingPSTNParticipant(participant);
|
@@ -16668,13 +16684,18 @@ const convertRemoteParticipantsToParticipantListParticipants = (remoteParticipan
|
|
16668
16684
|
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
16669
16685
|
const conversionCallback = (memoizeFn) => {
|
16670
16686
|
return (remoteParticipants
|
16687
|
+
// Filter out MicrosoftBot participants
|
16688
|
+
.filter((participant) => {
|
16689
|
+
/* @conditional-compile-remove(communication-common-beta-v3) */
|
16690
|
+
return !communicationCommon.isMicrosoftBotIdentifier(participant.identifier);
|
16691
|
+
})
|
16671
16692
|
/**
|
16672
16693
|
* hiding participants who are inLobby, idle, or connecting in ACS clients till we can admit users through ACS clients.
|
16673
16694
|
* phone users will be in the connecting state until they are connected to the call.
|
16674
16695
|
*/
|
16675
16696
|
.filter((participant) => {
|
16676
16697
|
return (!['InLobby', 'Idle', 'Connecting', 'Disconnected'].includes(participant.state) ||
|
16677
|
-
participant.identifier
|
16698
|
+
communicationCommon.isPhoneNumberIdentifier(participant.identifier));
|
16678
16699
|
})
|
16679
16700
|
.map((participant) => {
|
16680
16701
|
const isScreenSharing = Object.values(participant.videoStreams).some((videoStream) => videoStream.mediaStreamType === 'ScreenSharing' && videoStream.isAvailable);
|
@@ -21679,7 +21700,7 @@ const CaptionsBanner = (props) => {
|
|
21679
21700
|
/* @conditional-compile-remove(close-captions) */ isCaptionsSettingsOpen && (React__default['default'].createElement(CaptionsSettingsModal, { showCaptionsSettingsModal: isCaptionsSettingsOpen, onDismissCaptionsSettings: onDismissCaptionsSettings })),
|
21680
21701
|
/* @conditional-compile-remove(close-captions) */ React__default['default'].createElement("div", { className: containerClassName },
|
21681
21702
|
React__default['default'].createElement(react.Stack, { horizontalAlign: "center" },
|
21682
|
-
React__default['default'].createElement(react.Stack.Item, { style: { width: props.isMobile ? mobileViewBannerWidth : desktopViewBannerWidth } },
|
21703
|
+
React__default['default'].createElement(react.Stack.Item, { style: { width: props.isMobile ? mobileViewBannerWidth : desktopViewBannerWidth, maxWidth: '35rem' } },
|
21683
21704
|
React__default['default'].createElement(_CaptionsBanner, Object.assign({}, captionsBannerProps, handlers, { formFactor: props.isMobile ? 'compact' : 'default', strings: captionsBannerStrings })))),
|
21684
21705
|
!props.isMobile && captionsBannerProps.isCaptionsOn && (React__default['default'].createElement("div", { className: floatingChildClassName },
|
21685
21706
|
React__default['default'].createElement(CaptionsBannerMoreButton, { onCaptionsSettingsClick: onClickCaptionsSettings }))))));
|