@azure/communication-react 1.11.1-alpha-202312240013 → 1.11.1-alpha-202401030012
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/dist-cjs/communication-react/index.js +15 -6
- 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/react-components/src/components/VideoGallery/RemoteScreenShare.d.ts +1 -0
- package/dist/dist-esm/react-components/src/components/VideoGallery/RemoteScreenShare.js +10 -2
- package/dist/dist-esm/react-components/src/components/VideoGallery/RemoteScreenShare.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/VideoGallery.js +2 -2
- package/dist/dist-esm/react-components/src/components/VideoGallery.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/LocalPreview.js +2 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/LocalPreview.js.map +1 -1
- package/package.json +1 -1
@@ -170,7 +170,7 @@ function getDefaultExportFromCjs (x) {
|
|
170
170
|
// Copyright (c) Microsoft Corporation.
|
171
171
|
// Licensed under the MIT License.
|
172
172
|
// GENERATED FILE. DO NOT EDIT MANUALLY.
|
173
|
-
var telemetryVersion = '1.11.1-alpha-
|
173
|
+
var telemetryVersion = '1.11.1-alpha-202401030012';
|
174
174
|
|
175
175
|
|
176
176
|
var telemetryVersion$1 = /*@__PURE__*/getDefaultExportFromCjs(telemetryVersion);
|
@@ -13282,10 +13282,18 @@ const loadingStyle = react.mergeStyles({
|
|
13282
13282
|
* https://reactjs.org/docs/react-api.html#reactmemo
|
13283
13283
|
*/
|
13284
13284
|
const RemoteScreenShare = React.memo((props) => {
|
13285
|
-
const { userId, displayName, isMuted, renderElement, onCreateRemoteStreamView, onDisposeRemoteStreamView, isReceiving } = props;
|
13285
|
+
const { userId, displayName, isMuted, renderElement, onCreateRemoteStreamView, onDisposeRemoteStreamView, isReceiving, participantVideoScalingMode } = props;
|
13286
13286
|
const locale = useLocale$1();
|
13287
13287
|
if (!renderElement) {
|
13288
|
-
|
13288
|
+
/**
|
13289
|
+
* TODO: We need to pass in the scaling mode of the screen share participant to this function because when we
|
13290
|
+
* call this it will recreate both streams (video and screen share) and we need to make sure that the scaling
|
13291
|
+
* mode is the same as before we started the screen share.
|
13292
|
+
*
|
13293
|
+
* We should deprecate the current function and replace it with a
|
13294
|
+
* createRemoteScreenShareStreamView and createRemoteVideoStreamView.
|
13295
|
+
*/
|
13296
|
+
onCreateRemoteStreamView && onCreateRemoteStreamView(userId, participantVideoScalingMode);
|
13289
13297
|
}
|
13290
13298
|
React.useEffect(() => {
|
13291
13299
|
return () => {
|
@@ -15878,7 +15886,7 @@ const VideoGallery = (props) => {
|
|
15878
15886
|
}
|
15879
15887
|
: remoteVideoViewOptions;
|
15880
15888
|
};
|
15881
|
-
return (React.createElement(_RemoteVideoTile, { key: participant.userId, userId: participant.userId, remoteParticipant: participant, onCreateRemoteStreamView: isVideoParticipant ? onCreateRemoteStreamView : undefined, onDisposeRemoteStreamView: isVideoParticipant ? onDisposeRemoteVideoStreamView : undefined, isAvailable: isVideoParticipant ? remoteVideoStream === null || remoteVideoStream === void 0 ? void 0 : remoteVideoStream.isAvailable : false, isReceiving: isVideoParticipant ? remoteVideoStream === null || remoteVideoStream === void 0 ? void 0 : remoteVideoStream.isReceiving : false, renderElement: isVideoParticipant ? remoteVideoStream === null || remoteVideoStream === void 0 ? void 0 : remoteVideoStream.renderElement : undefined, remoteVideoViewOptions:
|
15889
|
+
return (React.createElement(_RemoteVideoTile, { key: participant.userId, userId: participant.userId, remoteParticipant: participant, onCreateRemoteStreamView: isVideoParticipant ? onCreateRemoteStreamView : undefined, onDisposeRemoteStreamView: isVideoParticipant ? onDisposeRemoteVideoStreamView : undefined, isAvailable: isVideoParticipant ? remoteVideoStream === null || remoteVideoStream === void 0 ? void 0 : remoteVideoStream.isAvailable : false, isReceiving: isVideoParticipant ? remoteVideoStream === null || remoteVideoStream === void 0 ? void 0 : remoteVideoStream.isReceiving : false, renderElement: isVideoParticipant ? remoteVideoStream === null || remoteVideoStream === void 0 ? void 0 : remoteVideoStream.renderElement : undefined, remoteVideoViewOptions: createViewOptions(), onRenderAvatar: onRenderAvatar, showMuteIndicator: showMuteIndicator, strings: strings,
|
15882
15890
|
/* @conditional-compile-remove(PSTN-calls) */
|
15883
15891
|
participantState: participant.state,
|
15884
15892
|
/* @conditional-compile-remove(pinned-participants) */
|
@@ -15922,7 +15930,7 @@ const VideoGallery = (props) => {
|
|
15922
15930
|
]);
|
15923
15931
|
const screenShareParticipant = remoteParticipants.find((participant) => { var _a; return (_a = participant.screenShareStream) === null || _a === void 0 ? void 0 : _a.isAvailable; });
|
15924
15932
|
const localScreenShareStreamComponent = React.createElement(LocalScreenShare, { localParticipant: localParticipant });
|
15925
|
-
const remoteScreenShareComponent = screenShareParticipant && (React.createElement(RemoteScreenShare, Object.assign({}, screenShareParticipant, { renderElement: (_b = screenShareParticipant.screenShareStream) === null || _b === void 0 ? void 0 : _b.renderElement, onCreateRemoteStreamView: onCreateRemoteStreamView, onDisposeRemoteStreamView: onDisposeRemoteScreenShareStreamView, isReceiving: (_c = screenShareParticipant.screenShareStream) === null || _c === void 0 ? void 0 : _c.isReceiving })));
|
15933
|
+
const remoteScreenShareComponent = screenShareParticipant && (React.createElement(RemoteScreenShare, Object.assign({}, screenShareParticipant, { renderElement: (_b = screenShareParticipant.screenShareStream) === null || _b === void 0 ? void 0 : _b.renderElement, onCreateRemoteStreamView: onCreateRemoteStreamView, onDisposeRemoteStreamView: onDisposeRemoteScreenShareStreamView, isReceiving: (_c = screenShareParticipant.screenShareStream) === null || _c === void 0 ? void 0 : _c.isReceiving, participantVideoScalingMode: selectedScalingModeState[screenShareParticipant.userId] })));
|
15926
15934
|
const screenShareComponent = remoteScreenShareComponent
|
15927
15935
|
? remoteScreenShareComponent
|
15928
15936
|
: localParticipant.isScreenSharingOn
|
@@ -29490,6 +29498,7 @@ const LocalPreview = (props) => {
|
|
29490
29498
|
const onToggleMic = React.useCallback(() => __awaiter$a(void 0, void 0, void 0, function* () {
|
29491
29499
|
isLocalMicrophoneEnabled ? adapter.mute() : adapter.unmute();
|
29492
29500
|
}), [adapter, isLocalMicrophoneEnabled]);
|
29501
|
+
const hasNoSpeakers = !devicesButtonProps.speakers.length;
|
29493
29502
|
const hasNoDevices = devicesButtonProps.cameras.length === 0 &&
|
29494
29503
|
devicesButtonProps.microphones.length === 0 &&
|
29495
29504
|
devicesButtonProps.speakers.length === 0;
|
@@ -29535,7 +29544,7 @@ const LocalPreview = (props) => {
|
|
29535
29544
|
: {}, styles: localPreviewButtonStyle })),
|
29536
29545
|
props.showDevicesButton && (React.createElement(DevicesButton, Object.assign({ "data-ui-id": "call-composite-local-device-settings-options-button" }, devicesButtonProps, {
|
29537
29546
|
// disable button whilst all other buttons are disabled
|
29538
|
-
disabled: !microphonePermissionGranted
|
29547
|
+
disabled: (!microphonePermissionGranted && !cameraPermissionGranted && hasNoSpeakers) || hasNoDevices, showLabel: true,
|
29539
29548
|
// disable tooltip as it obscures list of devices on mobile
|
29540
29549
|
strings: props.mobileView ? { tooltipContent: '' } : {}, styles: devicesButtonStyles })))))));
|
29541
29550
|
};
|