@azure/communication-react 1.5.1-alpha-202303280014 → 1.5.1-alpha-202303290014
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 +3 -3
- package/dist/dist-cjs/communication-react/index.js +101 -69
- 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-stateful-client/src/CallClientState.d.ts +1 -1
- package/dist/dist-esm/calling-stateful-client/src/CallClientState.js.map +1 -1
- package/dist/dist-esm/communication-react/src/index.d.ts +1 -1
- package/dist/dist-esm/communication-react/src/index.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/CaptionsBanner.d.ts +3 -3
- package/dist/dist-esm/react-components/src/components/CaptionsBanner.js +6 -27
- package/dist/dist-esm/react-components/src/components/CaptionsBanner.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/VideoGallery/DefaultLayout.d.ts +1 -1
- package/dist/dist-esm/react-components/src/components/VideoGallery/DefaultLayout.js +14 -14
- package/dist/dist-esm/react-components/src/components/VideoGallery/DefaultLayout.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/VideoGallery/FloatingLocalVideoLayout.d.ts +1 -1
- package/dist/dist-esm/react-components/src/components/VideoGallery/FloatingLocalVideoLayout.js +19 -19
- package/dist/dist-esm/react-components/src/components/VideoGallery/FloatingLocalVideoLayout.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/VideoGallery/Layout.d.ts +2 -2
- package/dist/dist-esm/react-components/src/components/VideoGallery/Layout.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/VideoGallery/OverflowGallery.d.ts +3 -3
- package/dist/dist-esm/react-components/src/components/VideoGallery/OverflowGallery.js +9 -9
- package/dist/dist-esm/react-components/src/components/VideoGallery/OverflowGallery.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/VideoGallery/utils/videoGalleryLayoutUtils.d.ts +4 -4
- package/dist/dist-esm/react-components/src/components/VideoGallery/utils/videoGalleryLayoutUtils.js +20 -20
- package/dist/dist-esm/react-components/src/components/VideoGallery/utils/videoGalleryLayoutUtils.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/VideoGallery.d.ts +2 -2
- package/dist/dist-esm/react-components/src/components/VideoGallery.js +3 -3
- package/dist/dist-esm/react-components/src/components/VideoGallery.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/index.d.ts +1 -1
- package/dist/dist-esm/react-components/src/components/index.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/styles/CaptionsBanner.style.d.ts +13 -0
- package/dist/dist-esm/react-components/src/components/styles/CaptionsBanner.style.js +35 -0
- package/dist/dist-esm/react-components/src/components/styles/CaptionsBanner.style.js.map +1 -0
- package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/AzureCommunicationCallAdapter.js +2 -2
- package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/AzureCommunicationCallAdapter.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallArrangement.js +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallArrangement.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/MediaGallery.js +3 -3
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/MediaGallery.js.map +1 -1
- package/package.json +10 -10
@@ -1802,7 +1802,7 @@ export declare type CallErrors = {
|
|
1802
1802
|
*
|
1803
1803
|
* @public
|
1804
1804
|
*/
|
1805
|
-
export declare type CallErrorTarget = 'Call.addParticipant' | /* @conditional-compile-remove(calling-beta-sdk) */ 'Call.dispose' | 'Call.feature' | 'Call.hangUp' | 'Call.hold' | 'Call.mute' | /* @conditional-compile-remove(calling-beta-sdk) */ 'Call.muteIncomingAudio' | 'Call.off' | 'Call.on' | 'Call.removeParticipant' | 'Call.resume' | 'Call.sendDtmf' | /* @conditional-compile-remove(calling-beta-sdk) */ 'Call.startAudio' | 'Call.startScreenSharing' | 'Call.startVideo' | 'Call.stopScreenSharing' | /* @conditional-compile-remove(calling-beta-sdk) */ 'Call.stopAudio' | 'Call.stopVideo' | 'Call.unmute' | /* @conditional-compile-remove(calling-beta-sdk) */ 'Call.unmuteIncomingAudio' | 'CallAgent.dispose' | 'CallAgent.feature' | 'CallAgent.join' | 'CallAgent.off' | 'CallAgent.on' | 'CallAgent.startCall' | 'CallClient.createCallAgent' | /* @conditional-compile-remove(calling-beta-sdk) */ /* @conditional-compile-remove(teams-identity-support) */ 'CallClient.createTeamsCallAgent' | 'CallClient.feature' | 'CallClient.getDeviceManager' | /* @conditional-compile-remove(calling-beta-sdk) */ 'CallClient.getEnvironmentInfo' | 'DeviceManager.askDevicePermission' | 'DeviceManager.getCameras' | 'DeviceManager.getMicrophones' | 'DeviceManager.getSpeakers' | 'DeviceManager.off' | 'DeviceManager.on' | 'DeviceManager.selectMicrophone' | 'DeviceManager.selectSpeaker' | 'IncomingCall.accept' | 'IncomingCall.reject' | /* @conditional-compile-remove(calling-beta-sdk) */ /* @conditional-compile-remove(teams-identity-support) */ 'TeamsCall.addParticipant' | /* @conditional-compile-remove(video-background-effects) */ 'VideoEffectsFeature.startEffects';
|
1805
|
+
export declare type CallErrorTarget = 'Call.addParticipant' | /* @conditional-compile-remove(calling-beta-sdk) */ 'Call.dispose' | 'Call.feature' | 'Call.hangUp' | 'Call.hold' | 'Call.mute' | /* @conditional-compile-remove(calling-beta-sdk) */ 'Call.muteIncomingAudio' | 'Call.off' | 'Call.on' | 'Call.removeParticipant' | 'Call.resume' | 'Call.sendDtmf' | /* @conditional-compile-remove(calling-beta-sdk) */ 'Call.startAudio' | 'Call.startScreenSharing' | 'Call.startVideo' | 'Call.stopScreenSharing' | /* @conditional-compile-remove(calling-beta-sdk) */ 'Call.stopAudio' | 'Call.stopVideo' | 'Call.unmute' | /* @conditional-compile-remove(calling-beta-sdk) */ 'Call.unmuteIncomingAudio' | 'CallAgent.dispose' | 'CallAgent.feature' | 'CallAgent.join' | 'CallAgent.off' | 'CallAgent.on' | 'CallAgent.startCall' | 'CallClient.createCallAgent' | /* @conditional-compile-remove(calling-beta-sdk) */ /* @conditional-compile-remove(teams-identity-support) */ 'CallClient.createTeamsCallAgent' | 'CallClient.feature' | 'CallClient.getDeviceManager' | /* @conditional-compile-remove(calling-beta-sdk) */ 'CallClient.getEnvironmentInfo' | 'DeviceManager.askDevicePermission' | 'DeviceManager.getCameras' | 'DeviceManager.getMicrophones' | 'DeviceManager.getSpeakers' | 'DeviceManager.off' | 'DeviceManager.on' | 'DeviceManager.selectMicrophone' | 'DeviceManager.selectSpeaker' | 'IncomingCall.accept' | 'IncomingCall.reject' | /* @conditional-compile-remove(calling-beta-sdk) */ /* @conditional-compile-remove(teams-identity-support) */ 'TeamsCall.addParticipant' | /* @conditional-compile-remove(video-background-effects) */ 'VideoEffectsFeature.startEffects' | /* @conditional-compile-remove(calling-beta-sdk) */ 'CallAgent.handlePushNotification';
|
1806
1806
|
|
1807
1807
|
/**
|
1808
1808
|
* Callback for {@link CallAdapterSubscribers} 'callIdChanged' event.
|
@@ -6700,7 +6700,7 @@ export declare interface OptionsDevice {
|
|
6700
6700
|
*
|
6701
6701
|
* @beta
|
6702
6702
|
*/
|
6703
|
-
export declare type
|
6703
|
+
export declare type OverflowGalleryPosition = 'HorizontalBottom' | 'VerticalRight';
|
6704
6704
|
|
6705
6705
|
/**
|
6706
6706
|
* A system message notifying that a participant was added to the chat thread.
|
@@ -8518,7 +8518,7 @@ export declare interface VideoGalleryProps {
|
|
8518
8518
|
* Determines the layout of the overflowGallery inside the VideoGallery.
|
8519
8519
|
* @defaultValue 'HorizontalBottom'
|
8520
8520
|
*/
|
8521
|
-
|
8521
|
+
overflowGalleryPosition?: OverflowGalleryPosition;
|
8522
8522
|
}
|
8523
8523
|
|
8524
8524
|
/**
|
@@ -162,7 +162,7 @@ const _toCommunicationIdentifier = (id) => {
|
|
162
162
|
// Copyright (c) Microsoft Corporation.
|
163
163
|
// Licensed under the MIT license.
|
164
164
|
// GENERATED FILE. DO NOT EDIT MANUALLY.
|
165
|
-
var telemetryVersion = '1.5.1-alpha-
|
165
|
+
var telemetryVersion = '1.5.1-alpha-202303290014';
|
166
166
|
|
167
167
|
// Copyright (c) Microsoft Corporation.
|
168
168
|
/**
|
@@ -9283,11 +9283,11 @@ const participantsById = (participants) => {
|
|
9283
9283
|
|
9284
9284
|
// Copyright (c) Microsoft Corporation.
|
9285
9285
|
const DEFAULT_MAX_REMOTE_VIDEOSTREAMS = 4;
|
9286
|
-
const
|
9286
|
+
const DEFAULT_MAX_OVERFLOW_GALLERY_DOMINANT_SPEAKERS = 6;
|
9287
9287
|
const _useOrganizedParticipants = (props) => {
|
9288
9288
|
const visibleGridParticipants = React.useRef([]);
|
9289
|
-
const
|
9290
|
-
const { remoteParticipants = [], dominantSpeakers = [], maxRemoteVideoStreams = DEFAULT_MAX_REMOTE_VIDEOSTREAMS,
|
9289
|
+
const visibleOverflowGalleryParticipants = React.useRef([]);
|
9290
|
+
const { remoteParticipants = [], dominantSpeakers = [], maxRemoteVideoStreams = DEFAULT_MAX_REMOTE_VIDEOSTREAMS, maxOverflowGalleryDominantSpeakers = DEFAULT_MAX_OVERFLOW_GALLERY_DOMINANT_SPEAKERS, isScreenShareActive = false, pinnedParticipantUserIds = [] } = props;
|
9291
9291
|
const videoParticipants = remoteParticipants.filter((p) => { var _a; return (_a = p.videoStream) === null || _a === void 0 ? void 0 : _a.isAvailable; });
|
9292
9292
|
visibleGridParticipants.current =
|
9293
9293
|
pinnedParticipantUserIds.length > 0 || isScreenShareActive
|
@@ -9304,12 +9304,12 @@ const _useOrganizedParticipants = (props) => {
|
|
9304
9304
|
const callingParticipants = remoteParticipantsOrdered.filter((p) => p.state === ('Connecting' ));
|
9305
9305
|
/* @conditional-compile-remove(PSTN-calls) */ /* @conditional-compile-remove(one-to-n-calling) */
|
9306
9306
|
const callingParticipantsSet = new Set(callingParticipants.map((p) => p.userId));
|
9307
|
-
|
9307
|
+
visibleOverflowGalleryParticipants.current = smartDominantSpeakerParticipants({
|
9308
9308
|
participants: remoteParticipantsOrdered.filter((p) => !visibleGridParticipantsSet.has(p.userId) &&
|
9309
9309
|
/* @conditional-compile-remove(PSTN-calls) */ /* @conditional-compile-remove(one-to-n-calling) */ !callingParticipantsSet.has(p.userId)),
|
9310
9310
|
dominantSpeakers: dominantSpeakers,
|
9311
|
-
lastVisibleParticipants:
|
9312
|
-
maxDominantSpeakers:
|
9311
|
+
lastVisibleParticipants: visibleOverflowGalleryParticipants.current,
|
9312
|
+
maxDominantSpeakers: maxOverflowGalleryDominantSpeakers
|
9313
9313
|
});
|
9314
9314
|
const getGridParticipants = React.useCallback(() => {
|
9315
9315
|
if (isScreenShareActive) {
|
@@ -9318,32 +9318,32 @@ const _useOrganizedParticipants = (props) => {
|
|
9318
9318
|
/* @conditional-compile-remove(PSTN-calls) */ /* @conditional-compile-remove(one-to-n-calling) */
|
9319
9319
|
return visibleGridParticipants.current.length > 0
|
9320
9320
|
? visibleGridParticipants.current
|
9321
|
-
:
|
9321
|
+
: visibleOverflowGalleryParticipants.current.concat(callingParticipants);
|
9322
9322
|
}, [
|
9323
9323
|
/* @conditional-compile-remove(PSTN-calls) */ /* @conditional-compile-remove(one-to-n-calling) */ callingParticipants,
|
9324
9324
|
isScreenShareActive
|
9325
9325
|
]);
|
9326
9326
|
const gridParticipants = getGridParticipants();
|
9327
|
-
const
|
9327
|
+
const getOverflowGalleryRemoteParticipants = React.useCallback(() => {
|
9328
9328
|
if (isScreenShareActive) {
|
9329
|
-
// If screen sharing is active, assign video and audio participants as
|
9329
|
+
// If screen sharing is active, assign video and audio participants as overflow gallery participants
|
9330
9330
|
/* @conditional-compile-remove(PSTN-calls) */ /* @conditional-compile-remove(one-to-n-calling) */
|
9331
|
-
return visibleGridParticipants.current.concat(
|
9331
|
+
return visibleGridParticipants.current.concat(visibleOverflowGalleryParticipants.current.concat(callingParticipants));
|
9332
9332
|
}
|
9333
9333
|
else {
|
9334
9334
|
// If screen sharing is not active, then assign all video tiles as grid tiles.
|
9335
9335
|
// If there are no video tiles, then assign audio tiles as grid tiles.
|
9336
9336
|
/* @conditional-compile-remove(PSTN-calls) */ /* @conditional-compile-remove(one-to-n-calling) */
|
9337
9337
|
return visibleGridParticipants.current.length > 0
|
9338
|
-
?
|
9338
|
+
? visibleOverflowGalleryParticipants.current.concat(callingParticipants)
|
9339
9339
|
: [];
|
9340
9340
|
}
|
9341
9341
|
}, [
|
9342
9342
|
/* @conditional-compile-remove(PSTN-calls) */ /* @conditional-compile-remove(one-to-n-calling) */ callingParticipants,
|
9343
9343
|
isScreenShareActive
|
9344
9344
|
]);
|
9345
|
-
const
|
9346
|
-
return { gridParticipants,
|
9345
|
+
const overflowGalleryParticipants = getOverflowGalleryRemoteParticipants();
|
9346
|
+
return { gridParticipants, overflowGalleryParticipants: overflowGalleryParticipants };
|
9347
9347
|
};
|
9348
9348
|
/* @conditional-compile-remove(pinned-participants) */
|
9349
9349
|
const _useOrganizedParticipantsWithPinnedParticipants = (props) => {
|
@@ -9373,9 +9373,9 @@ const _useOrganizedParticipantsWithPinnedParticipants = (props) => {
|
|
9373
9373
|
}
|
9374
9374
|
return {
|
9375
9375
|
gridParticipants: props.isScreenShareActive ? [] : pinnedParticipants,
|
9376
|
-
|
9377
|
-
? pinnedParticipants.concat(useOrganizedParticipantsResult.
|
9378
|
-
: useOrganizedParticipantsResult.gridParticipants.concat(useOrganizedParticipantsResult.
|
9376
|
+
overflowGalleryParticipants: props.isScreenShareActive
|
9377
|
+
? pinnedParticipants.concat(useOrganizedParticipantsResult.overflowGalleryParticipants)
|
9378
|
+
: useOrganizedParticipantsResult.gridParticipants.concat(useOrganizedParticipantsResult.overflowGalleryParticipants)
|
9379
9379
|
};
|
9380
9380
|
};
|
9381
9381
|
const putVideoParticipantsFirst = (remoteParticipants) => {
|
@@ -9394,7 +9394,7 @@ const putVideoParticipantsFirst = (remoteParticipants) => {
|
|
9394
9394
|
return remoteParticipantSortedByVideo;
|
9395
9395
|
};
|
9396
9396
|
/**
|
9397
|
-
* Hook to determine which participants should be in grid and
|
9397
|
+
* Hook to determine which participants should be in grid and overflow gallery and their order respectively
|
9398
9398
|
* @private
|
9399
9399
|
*/
|
9400
9400
|
const useOrganizedParticipants = (args) => {
|
@@ -10109,11 +10109,11 @@ const OverflowGallery = (props) => {
|
|
10109
10109
|
const { shouldFloatLocalVideo = false, onFetchTilesToRender, isNarrow = false,
|
10110
10110
|
/* @conditional-compile-remove(vertical-gallery) */
|
10111
10111
|
isShort = false, overflowGalleryElements, horizontalGalleryStyles,
|
10112
|
-
/* @conditional-compile-remove(vertical-gallery) */
|
10113
|
-
/* @conditional-compile-remove(vertical-gallery) */
|
10112
|
+
/* @conditional-compile-remove(vertical-gallery) */ overflowGalleryPosition = 'HorizontalBottom',
|
10113
|
+
/* @conditional-compile-remove(vertical-gallery) */ verticalGalleryStyles, onChildrenPerPageChange } = props;
|
10114
10114
|
const containerStyles = React.useMemo(() => {
|
10115
10115
|
/* @conditional-compile-remove(vertical-gallery) */
|
10116
|
-
if (
|
10116
|
+
if (overflowGalleryPosition === 'VerticalRight') {
|
10117
10117
|
return verticalGalleryContainerStyle(shouldFloatLocalVideo, isNarrow, isShort);
|
10118
10118
|
}
|
10119
10119
|
return horizontalGalleryContainerStyle(shouldFloatLocalVideo, isNarrow);
|
@@ -10121,23 +10121,23 @@ const OverflowGallery = (props) => {
|
|
10121
10121
|
shouldFloatLocalVideo,
|
10122
10122
|
/* @conditional-compile-remove(vertical-gallery) */ isShort,
|
10123
10123
|
isNarrow,
|
10124
|
-
/* @conditional-compile-remove(vertical-gallery) */
|
10124
|
+
/* @conditional-compile-remove(vertical-gallery) */ overflowGalleryPosition
|
10125
10125
|
]);
|
10126
10126
|
const galleryStyles = React.useMemo(() => {
|
10127
10127
|
/* @conditional-compile-remove(vertical-gallery) */
|
10128
|
-
if (
|
10129
|
-
return react.concatStyleSets(verticalGalleryStyle(isShort),
|
10128
|
+
if (overflowGalleryPosition === 'VerticalRight') {
|
10129
|
+
return react.concatStyleSets(verticalGalleryStyle(isShort), verticalGalleryStyles);
|
10130
10130
|
}
|
10131
10131
|
return react.concatStyleSets(horizontalGalleryStyle(isNarrow), horizontalGalleryStyles);
|
10132
10132
|
}, [
|
10133
10133
|
isNarrow,
|
10134
10134
|
/* @conditional-compile-remove(vertical-gallery) */ isShort,
|
10135
10135
|
horizontalGalleryStyles,
|
10136
|
-
/* @conditional-compile-remove(vertical-gallery) */
|
10137
|
-
/* @conditional-compile-remove(vertical-gallery) */
|
10136
|
+
/* @conditional-compile-remove(vertical-gallery) */ overflowGalleryPosition,
|
10137
|
+
/* @conditional-compile-remove(vertical-gallery) */ verticalGalleryStyles
|
10138
10138
|
]);
|
10139
10139
|
/* @conditional-compile-remove(vertical-gallery) */
|
10140
|
-
if (
|
10140
|
+
if (overflowGalleryPosition === 'VerticalRight') {
|
10141
10141
|
return (React__default['default'].createElement(ResponsiveVerticalGallery, { key: "responsive-vertical-gallery", containerStyles: containerStyles, verticalGalleryStyles: galleryStyles, controlBarHeightRem: HORIZONTAL_GALLERY_BUTTON_WIDTH, gapHeightRem: HORIZONTAL_GALLERY_GAP, isShort: isShort, onFetchTilesToRender: onFetchTilesToRender, onChildrenPerPageChange: onChildrenPerPageChange }, overflowGalleryElements));
|
10142
10142
|
}
|
10143
10143
|
/* @conditional-compile-remove(pinned-participants) */
|
@@ -10153,7 +10153,7 @@ const OverflowGallery = (props) => {
|
|
10153
10153
|
// Copyright (c) Microsoft Corporation.
|
10154
10154
|
/**
|
10155
10155
|
* DefaultLayout displays remote participants, local video component, and screen sharing component in
|
10156
|
-
* a grid
|
10156
|
+
* a grid an overflow gallery.
|
10157
10157
|
*
|
10158
10158
|
* @private
|
10159
10159
|
*/
|
@@ -10161,19 +10161,19 @@ const DefaultLayout = (props) => {
|
|
10161
10161
|
const { remoteParticipants = [], dominantSpeakers, localVideoComponent, screenShareComponent, onRenderRemoteParticipant, styles, maxRemoteVideoStreams, parentWidth,
|
10162
10162
|
/* @conditional-compile-remove(vertical-gallery) */
|
10163
10163
|
parentHeight, pinnedParticipantUserIds = [],
|
10164
|
-
/* @conditional-compile-remove(vertical-gallery) */
|
10164
|
+
/* @conditional-compile-remove(vertical-gallery) */ overflowGalleryPosition = 'HorizontalBottom' } = props;
|
10165
10165
|
const isNarrow = parentWidth ? isNarrowWidth(parentWidth) : false;
|
10166
10166
|
/* @conditional-compile-remove(vertical-gallery) */
|
10167
10167
|
const isShort = parentHeight ? isShortHeight(parentHeight) : false;
|
10168
|
-
// This is for tracking the number of children in the first page of
|
10169
|
-
// This number will be used for the
|
10168
|
+
// This is for tracking the number of children in the first page of overflow gallery.
|
10169
|
+
// This number will be used for the maxOverflowGalleryDominantSpeakers when organizing the remote participants.
|
10170
10170
|
const childrenPerPage = React.useRef(4);
|
10171
|
-
const { gridParticipants,
|
10171
|
+
const { gridParticipants, overflowGalleryParticipants } = useOrganizedParticipants({
|
10172
10172
|
remoteParticipants,
|
10173
10173
|
dominantSpeakers,
|
10174
10174
|
maxRemoteVideoStreams,
|
10175
10175
|
isScreenShareActive: !!screenShareComponent,
|
10176
|
-
|
10176
|
+
maxOverflowGalleryDominantSpeakers: screenShareComponent
|
10177
10177
|
? childrenPerPage.current - (pinnedParticipantUserIds.length % childrenPerPage.current)
|
10178
10178
|
: childrenPerPage.current,
|
10179
10179
|
/* @conditional-compile-remove(pinned-participants) */ pinnedParticipantUserIds
|
@@ -10195,7 +10195,7 @@ const DefaultLayout = (props) => {
|
|
10195
10195
|
const [indexesToRender, setIndexesToRender] = React.useState([
|
10196
10196
|
...Array(maxRemoteVideoStreams - activeVideoStreams).keys()
|
10197
10197
|
]);
|
10198
|
-
const
|
10198
|
+
const overflowGalleryTiles = overflowGalleryParticipants.map((p, i) => {
|
10199
10199
|
var _a, _b;
|
10200
10200
|
return onRenderRemoteParticipant(p, maxRemoteVideoStreams && maxRemoteVideoStreams >= 0
|
10201
10201
|
? ((_a = p.videoStream) === null || _a === void 0 ? void 0 : _a.isAvailable) && indexesToRender.includes(i) && activeVideoStreams++ < maxRemoteVideoStreams
|
@@ -10205,32 +10205,32 @@ const DefaultLayout = (props) => {
|
|
10205
10205
|
gridTiles.push(localVideoComponent);
|
10206
10206
|
}
|
10207
10207
|
const overflowGallery = React.useMemo(() => {
|
10208
|
-
if (
|
10208
|
+
if (overflowGalleryTiles.length === 0) {
|
10209
10209
|
return null;
|
10210
10210
|
}
|
10211
10211
|
return (React__default['default'].createElement(OverflowGallery, { isNarrow: isNarrow,
|
10212
10212
|
/* @conditional-compile-remove(vertical-gallery) */
|
10213
|
-
isShort: isShort, shouldFloatLocalVideo: false, overflowGalleryElements:
|
10213
|
+
isShort: isShort, shouldFloatLocalVideo: false, overflowGalleryElements: overflowGalleryTiles, horizontalGalleryStyles: styles === null || styles === void 0 ? void 0 : styles.horizontalGallery,
|
10214
10214
|
/* @conditional-compile-remove(vertical-gallery) */
|
10215
|
-
|
10215
|
+
verticalGalleryStyles: styles === null || styles === void 0 ? void 0 : styles.verticalGallery,
|
10216
10216
|
/* @conditional-compile-remove(pinned-participants) */
|
10217
|
-
|
10217
|
+
overflowGalleryPosition: overflowGalleryPosition, onFetchTilesToRender: setIndexesToRender, onChildrenPerPageChange: (n) => {
|
10218
10218
|
childrenPerPage.current = n;
|
10219
10219
|
} }));
|
10220
10220
|
}, [
|
10221
10221
|
isNarrow,
|
10222
10222
|
/* @conditional-compile-remove(vertical-gallery) */ isShort,
|
10223
|
-
|
10223
|
+
overflowGalleryTiles,
|
10224
10224
|
styles === null || styles === void 0 ? void 0 : styles.horizontalGallery,
|
10225
|
+
/* @conditional-compile-remove(vertical-gallery) */ overflowGalleryPosition,
|
10225
10226
|
setIndexesToRender,
|
10226
|
-
/* @conditional-compile-remove(vertical-gallery) */ overflowGalleryLayout,
|
10227
10227
|
/* @conditional-compile-remove(vertical-gallery) */ styles === null || styles === void 0 ? void 0 : styles.verticalGallery
|
10228
10228
|
]);
|
10229
10229
|
return (React__default['default'].createElement(react.Stack
|
10230
10230
|
/* @conditional-compile-remove(vertical-gallery) */
|
10231
10231
|
, {
|
10232
10232
|
/* @conditional-compile-remove(vertical-gallery) */
|
10233
|
-
horizontal:
|
10233
|
+
horizontal: overflowGalleryPosition === 'VerticalRight', styles: rootLayoutStyle$1, tokens: videoGalleryLayoutGap },
|
10234
10234
|
screenShareComponent ? (screenShareComponent) : (React__default['default'].createElement(GridLayout, { key: "grid-layout", styles: styles === null || styles === void 0 ? void 0 : styles.gridLayout }, gridTiles)),
|
10235
10235
|
overflowGallery));
|
10236
10236
|
};
|
@@ -10974,26 +10974,26 @@ const layerHostStyle = {
|
|
10974
10974
|
// Copyright (c) Microsoft Corporation.
|
10975
10975
|
/**
|
10976
10976
|
* FloatingLocalVideoLayout displays remote participants and a screen sharing component in
|
10977
|
-
* a grid and
|
10977
|
+
* a grid and overflow gallery while floating the local video
|
10978
10978
|
*
|
10979
10979
|
* @private
|
10980
10980
|
*/
|
10981
10981
|
const FloatingLocalVideoLayout = (props) => {
|
10982
|
-
const { remoteParticipants = [], dominantSpeakers, localVideoComponent, screenShareComponent, onRenderRemoteParticipant, styles, maxRemoteVideoStreams, showCameraSwitcherInLocalPreview, parentWidth, parentHeight,
|
10983
|
-
/* @conditional-compile-remove(vertical-gallery) */
|
10982
|
+
const { remoteParticipants = [], dominantSpeakers, localVideoComponent, screenShareComponent, onRenderRemoteParticipant, styles, maxRemoteVideoStreams, showCameraSwitcherInLocalPreview, parentWidth, parentHeight,
|
10983
|
+
/* @conditional-compile-remove(vertical-gallery) */ overflowGalleryPosition = 'HorizontalBottom', pinnedParticipantUserIds = [] } = props;
|
10984
10984
|
const theme = useTheme();
|
10985
10985
|
const isNarrow = parentWidth ? isNarrowWidth(parentWidth) : false;
|
10986
10986
|
/* @conditional-compile-remove(vertical-gallery) */
|
10987
10987
|
const isShort = parentHeight ? isShortHeight(parentHeight) : false;
|
10988
|
-
// This is for tracking the number of children in the first page of
|
10989
|
-
// This number will be used for the
|
10988
|
+
// This is for tracking the number of children in the first page of overflow gallery.
|
10989
|
+
// This number will be used for the maxOverflowGalleryDominantSpeakers when organizing the remote participants.
|
10990
10990
|
const childrenPerPage = React.useRef(4);
|
10991
|
-
const { gridParticipants,
|
10991
|
+
const { gridParticipants, overflowGalleryParticipants } = useOrganizedParticipants({
|
10992
10992
|
remoteParticipants,
|
10993
10993
|
dominantSpeakers,
|
10994
10994
|
maxRemoteVideoStreams,
|
10995
10995
|
isScreenShareActive: !!screenShareComponent,
|
10996
|
-
|
10996
|
+
maxOverflowGalleryDominantSpeakers: screenShareComponent
|
10997
10997
|
? childrenPerPage.current - (pinnedParticipantUserIds.length % childrenPerPage.current)
|
10998
10998
|
: childrenPerPage.current,
|
10999
10999
|
/* @conditional-compile-remove(pinned-participants) */ pinnedParticipantUserIds
|
@@ -11019,7 +11019,7 @@ const FloatingLocalVideoLayout = (props) => {
|
|
11019
11019
|
const [indexesToRender, setIndexesToRender] = React.useState([
|
11020
11020
|
...Array(maxRemoteVideoStreams - activeVideoStreams).keys()
|
11021
11021
|
]);
|
11022
|
-
const
|
11022
|
+
const overflowGalleryTiles = overflowGalleryParticipants.map((p, i) => {
|
11023
11023
|
var _a, _b;
|
11024
11024
|
return onRenderRemoteParticipant(p, maxRemoteVideoStreams && maxRemoteVideoStreams >= 0
|
11025
11025
|
? ((_a = p.videoStream) === null || _a === void 0 ? void 0 : _a.isAvailable) && indexesToRender.includes(i) && activeVideoStreams++ < maxRemoteVideoStreams
|
@@ -11031,7 +11031,7 @@ const FloatingLocalVideoLayout = (props) => {
|
|
11031
11031
|
return SMALL_FLOATING_MODAL_SIZE_REM;
|
11032
11032
|
}
|
11033
11033
|
/* @conditional-compile-remove(vertical-gallery) */
|
11034
|
-
if ((
|
11034
|
+
if ((overflowGalleryTiles.length > 0 || !!screenShareComponent) && overflowGalleryPosition === 'VerticalRight') {
|
11035
11035
|
return isNarrow
|
11036
11036
|
? SMALL_FLOATING_MODAL_SIZE_REM
|
11037
11037
|
: isShort
|
@@ -11040,10 +11040,10 @@ const FloatingLocalVideoLayout = (props) => {
|
|
11040
11040
|
}
|
11041
11041
|
return LARGE_FLOATING_MODAL_SIZE_REM;
|
11042
11042
|
}, [
|
11043
|
-
|
11043
|
+
overflowGalleryTiles.length,
|
11044
11044
|
isNarrow,
|
11045
11045
|
/* @conditional-compile-remove(vertical-gallery) */ isShort,
|
11046
|
-
/* @conditional-compile-remove(vertical-gallery) */
|
11046
|
+
/* @conditional-compile-remove(vertical-gallery) */ overflowGalleryPosition,
|
11047
11047
|
/* @conditional-compile-remove(vertical-gallery) */ screenShareComponent
|
11048
11048
|
]);
|
11049
11049
|
const wrappedLocalVideoComponent = localVideoComponent && shouldFloatLocalVideo ? (
|
@@ -11051,30 +11051,30 @@ const FloatingLocalVideoLayout = (props) => {
|
|
11051
11051
|
showCameraSwitcherInLocalPreview ? (React__default['default'].createElement(react.Stack, { className: react.mergeStyles(localVideoTileWithControlsContainerStyle(theme, localVideoSizeRem), {
|
11052
11052
|
boxShadow: theme.effects.elevation8,
|
11053
11053
|
zIndex: LOCAL_VIDEO_TILE_ZINDEX
|
11054
|
-
}) }, localVideoComponent)) :
|
11054
|
+
}) }, localVideoComponent)) : overflowGalleryTiles.length > 0 || !!screenShareComponent ? (React__default['default'].createElement(react.Stack, { className: react.mergeStyles(localVideoTileContainerStyle(theme, localVideoSizeRem)) }, localVideoComponent)) : (React__default['default'].createElement(FloatingLocalVideo, { localVideoComponent: localVideoComponent, layerHostId: layerHostId, localVideoSizeRem: localVideoSizeRem, parentWidth: parentWidth, parentHeight: parentHeight }))) : undefined;
|
11055
11055
|
const overflowGallery = React.useMemo(() => {
|
11056
|
-
if (
|
11056
|
+
if (overflowGalleryTiles.length === 0 && !screenShareComponent) {
|
11057
11057
|
return null;
|
11058
11058
|
}
|
11059
11059
|
return (React__default['default'].createElement(OverflowGallery
|
11060
11060
|
/* @conditional-compile-remove(vertical-gallery) */
|
11061
11061
|
, {
|
11062
11062
|
/* @conditional-compile-remove(vertical-gallery) */
|
11063
|
-
isShort: isShort, onFetchTilesToRender: setIndexesToRender, isNarrow: isNarrow, shouldFloatLocalVideo: true, overflowGalleryElements:
|
11063
|
+
isShort: isShort, onFetchTilesToRender: setIndexesToRender, isNarrow: isNarrow, shouldFloatLocalVideo: true, overflowGalleryElements: overflowGalleryTiles, horizontalGalleryStyles: styles === null || styles === void 0 ? void 0 : styles.horizontalGallery,
|
11064
11064
|
/* @conditional-compile-remove(vertical-gallery) */
|
11065
|
-
|
11065
|
+
verticalGalleryStyles: styles === null || styles === void 0 ? void 0 : styles.verticalGallery,
|
11066
11066
|
/* @conditional-compile-remove(vertical-gallery) */
|
11067
|
-
|
11067
|
+
overflowGalleryPosition: overflowGalleryPosition, onChildrenPerPageChange: (n) => {
|
11068
11068
|
childrenPerPage.current = n;
|
11069
11069
|
} }));
|
11070
11070
|
}, [
|
11071
11071
|
isNarrow,
|
11072
11072
|
/* @conditional-compile-remove(vertical-gallery) */ isShort,
|
11073
|
-
|
11073
|
+
overflowGalleryTiles,
|
11074
11074
|
styles === null || styles === void 0 ? void 0 : styles.horizontalGallery,
|
11075
|
+
/* @conditional-compile-remove(vertical-gallery) */ overflowGalleryPosition,
|
11075
11076
|
setIndexesToRender,
|
11076
11077
|
screenShareComponent,
|
11077
|
-
/* @conditional-compile-remove(vertical-gallery) */ overflowGalleryLayout,
|
11078
11078
|
/* @conditional-compile-remove(vertical-gallery) */ styles === null || styles === void 0 ? void 0 : styles.verticalGallery
|
11079
11079
|
]);
|
11080
11080
|
return (React__default['default'].createElement(react.Stack, { styles: rootLayoutStyle },
|
@@ -11084,7 +11084,7 @@ const FloatingLocalVideoLayout = (props) => {
|
|
11084
11084
|
/* @conditional-compile-remove(vertical-gallery) */
|
11085
11085
|
, {
|
11086
11086
|
/* @conditional-compile-remove(vertical-gallery) */
|
11087
|
-
horizontal:
|
11087
|
+
horizontal: overflowGalleryPosition === 'VerticalRight', styles: innerLayoutStyle, tokens: videoGalleryLayoutGap },
|
11088
11088
|
screenShareComponent ? (screenShareComponent) : (React__default['default'].createElement(GridLayout, { key: "grid-layout", styles: styles === null || styles === void 0 ? void 0 : styles.gridLayout }, gridTiles)),
|
11089
11089
|
overflowGallery)));
|
11090
11090
|
};
|
@@ -11135,7 +11135,7 @@ const VideoGallery = (props) => {
|
|
11135
11135
|
/* @conditional-compile-remove(pinned-participants) */
|
11136
11136
|
remoteVideoTileMenuOptions = DEFAULT_REMOTE_VIDEO_TILE_MENU_OPTIONS,
|
11137
11137
|
/* @conditional-compile-remove(vertical-gallery) */
|
11138
|
-
|
11138
|
+
overflowGalleryPosition = 'HorizontalBottom' } = props;
|
11139
11139
|
const ids = useIdentifiers();
|
11140
11140
|
const theme = useTheme();
|
11141
11141
|
const localeStrings = useLocale$1().strings.videoGallery;
|
@@ -11297,7 +11297,7 @@ const VideoGallery = (props) => {
|
|
11297
11297
|
parentWidth: containerWidth,
|
11298
11298
|
parentHeight: containerHeight,
|
11299
11299
|
/* @conditional-compile-remove(pinned-participants) */ pinnedParticipantUserIds: pinnedParticipants,
|
11300
|
-
/* @conditional-compile-remove(vertical-gallery) */
|
11300
|
+
/* @conditional-compile-remove(vertical-gallery) */ overflowGalleryPosition
|
11301
11301
|
}), [
|
11302
11302
|
remoteParticipants,
|
11303
11303
|
screenShareComponent,
|
@@ -11311,7 +11311,7 @@ const VideoGallery = (props) => {
|
|
11311
11311
|
onRenderRemoteVideoTile,
|
11312
11312
|
defaultOnRenderVideoTile,
|
11313
11313
|
/* @conditional-compile-remove(pinned-participants) */ pinnedParticipants,
|
11314
|
-
/* @conditional-compile-remove(vertical-gallery) */
|
11314
|
+
/* @conditional-compile-remove(vertical-gallery) */ overflowGalleryPosition
|
11315
11315
|
]);
|
11316
11316
|
const videoGalleryLayout = React.useMemo(() => {
|
11317
11317
|
if (layout === 'floatingLocalVideo') {
|
@@ -13280,6 +13280,38 @@ const _DevicePermissionDropdown = (props) => {
|
|
13280
13280
|
}, options: options !== null && options !== void 0 ? options : [], styles: styles }));
|
13281
13281
|
};
|
13282
13282
|
|
13283
|
+
// Copyright (c) Microsoft Corporation.
|
13284
|
+
/**
|
13285
|
+
* @private
|
13286
|
+
*/
|
13287
|
+
react.mergeStyles({
|
13288
|
+
overflowY: 'scroll',
|
13289
|
+
overflowX: 'hidden',
|
13290
|
+
width: '100%',
|
13291
|
+
height: _pxToRem(60),
|
13292
|
+
display: 'grid',
|
13293
|
+
gridTemplateColumns: 'auto 1fr',
|
13294
|
+
alignItems: 'stretch',
|
13295
|
+
columnGap: _pxToRem(16),
|
13296
|
+
padding: _pxToRem(8)
|
13297
|
+
});
|
13298
|
+
/**
|
13299
|
+
* @private
|
13300
|
+
*/
|
13301
|
+
react.mergeStyles({
|
13302
|
+
fontWeight: 600,
|
13303
|
+
fontSize: _pxToRem(12),
|
13304
|
+
lineHeight: _pxToRem(30)
|
13305
|
+
});
|
13306
|
+
/**
|
13307
|
+
* @private
|
13308
|
+
*/
|
13309
|
+
react.mergeStyles({
|
13310
|
+
fontWeight: 400,
|
13311
|
+
fontSize: _pxToRem(16),
|
13312
|
+
lineHeight: _pxToRem(30)
|
13313
|
+
});
|
13314
|
+
|
13283
13315
|
// Copyright (c) Microsoft Corporation.
|
13284
13316
|
// Licensed under the MIT license.
|
13285
13317
|
/**
|
@@ -19581,7 +19613,7 @@ const CallArrangement = (props) => {
|
|
19581
19613
|
const isMobileWithActivePane = props.mobileView && activePane;
|
19582
19614
|
/* @conditional-compile-remove(one-to-n-calling) @conditional-compile-remove(PSTN-calls) */
|
19583
19615
|
const callCompositeContainerCSS = React.useMemo(() => {
|
19584
|
-
return { display: isMobileWithActivePane ? 'none' : 'flex', width: '100%', height: '100%' };
|
19616
|
+
return { display: isMobileWithActivePane ? 'none' : 'flex', minWidth: 0, width: '100%', height: '100%' };
|
19585
19617
|
}, [isMobileWithActivePane]);
|
19586
19618
|
// To be removed once feature is out of beta, replace with callCompositeContainerCSS
|
19587
19619
|
// eslint-disable-next-line @typescript-eslint/explicit-function-return-type
|
@@ -19846,7 +19878,7 @@ const MediaGallery = (props) => {
|
|
19846
19878
|
: { kind: 'contextual' };
|
19847
19879
|
}, [(_a = props.remoteVideoTileMenuOptions) === null || _a === void 0 ? void 0 : _a.isHidden, props.isMobile, props.drawerMenuHostId]);
|
19848
19880
|
/* @conditional-compile-remove(vertical-gallery) */
|
19849
|
-
const
|
19881
|
+
const overflowGalleryPosition = React.useMemo(() => containerWidth && containerHeight && containerWidth / containerHeight >= 16 / 9
|
19850
19882
|
? 'VerticalRight'
|
19851
19883
|
: 'HorizontalBottom', [containerWidth, containerHeight]);
|
19852
19884
|
const VideoGalleryMemoized = React.useMemo(() => {
|
@@ -19854,14 +19886,14 @@ const MediaGallery = (props) => {
|
|
19854
19886
|
/* @conditional-compile-remove(pinned-participants) */
|
19855
19887
|
remoteVideoTileMenuOptions: remoteVideoTileMenuOptions,
|
19856
19888
|
/* @conditional-compile-remove(vertical-gallery) */
|
19857
|
-
|
19889
|
+
overflowGalleryPosition: overflowGalleryPosition })));
|
19858
19890
|
}, [
|
19859
19891
|
videoGalleryProps,
|
19860
19892
|
props.isMobile,
|
19861
19893
|
onRenderAvatar,
|
19862
19894
|
cameraSwitcherProps,
|
19863
19895
|
/* @conditional-compile-remove(pinned-participants) */ remoteVideoTileMenuOptions,
|
19864
|
-
/* @conditional-compile-remove(vertical-gallery) */
|
19896
|
+
/* @conditional-compile-remove(vertical-gallery) */ overflowGalleryPosition
|
19865
19897
|
]);
|
19866
19898
|
return (React__default['default'].createElement("div", { ref: containerRef, style: mediaGalleryContainerStyles },
|
19867
19899
|
React__default['default'].createElement(Announcer, { announcementString: announcerString, ariaLive: 'polite' }),
|
@@ -22214,10 +22246,10 @@ class AzureCommunicationCallAdapter {
|
|
22214
22246
|
}
|
22215
22247
|
onRemoteParticipantsUpdated({ added, removed }) {
|
22216
22248
|
if (added && added.length > 0) {
|
22217
|
-
this.emitter.emit('participantsJoined', added);
|
22249
|
+
this.emitter.emit('participantsJoined', { joined: added });
|
22218
22250
|
}
|
22219
22251
|
if (removed && removed.length > 0) {
|
22220
|
-
this.emitter.emit('participantsLeft', removed);
|
22252
|
+
this.emitter.emit('participantsLeft', { removed: removed });
|
22221
22253
|
}
|
22222
22254
|
added.forEach((participant) => {
|
22223
22255
|
this.participantSubscribers.set(toFlatCommunicationIdentifier(participant.identifier), new ParticipantSubscriber(participant, this.emitter));
|