@azure/communication-react 1.8.1-alpha-202309270012 → 1.8.1-alpha-202309280013

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.
@@ -176,7 +176,7 @@ const _isValidIdentifier = (identifier) => {
176
176
  // Copyright (c) Microsoft Corporation.
177
177
  // Licensed under the MIT License.
178
178
  // GENERATED FILE. DO NOT EDIT MANUALLY.
179
- var telemetryVersion = '1.8.1-alpha-202309270012';
179
+ var telemetryVersion = '1.8.1-alpha-202309280013';
180
180
 
181
181
  // Copyright (c) Microsoft Corporation.
182
182
  /**
@@ -11259,12 +11259,7 @@ const onRenderParticipantDefault = (participant, strings, myUserId, onRenderAvat
11259
11259
  const callingParticipant = participant;
11260
11260
  let presence = undefined;
11261
11261
  if (callingParticipant) {
11262
- if (callingParticipant.state === 'Connected') {
11263
- presence = react.PersonaPresence.online;
11264
- }
11265
- else if (callingParticipant.state === 'Idle') {
11266
- presence = react.PersonaPresence.away;
11267
- }
11262
+ presence = react.PersonaPresence.none;
11268
11263
  }
11269
11264
  const menuItems = createParticipantMenuItems && createParticipantMenuItems(participant);
11270
11265
  const onRenderIcon = (callingParticipant === null || callingParticipant === void 0 ? void 0 : callingParticipant.isScreenSharing) ||
@@ -24256,7 +24251,7 @@ const DesktopMoreButton = (props) => {
24256
24251
  }
24257
24252
  };
24258
24253
  /* @conditional-compile-remove(large-gallery) */
24259
- const largeGalleryOptions = {
24254
+ const largeGalleryOption = {
24260
24255
  key: 'largeGallerySelectionKey',
24261
24256
  text: localeStrings.strings.call.moreButtonLargeGalleryDefaultLayoutLabel,
24262
24257
  canCheck: true,
@@ -24274,7 +24269,7 @@ const DesktopMoreButton = (props) => {
24274
24269
  }
24275
24270
  };
24276
24271
  /* @conditional-compile-remove(gallery-layouts) */
24277
- const overflowGalleryOptions = {
24272
+ const overflowGalleryOption = {
24278
24273
  key: 'topKey',
24279
24274
  text: localeStrings.strings.call.moreButtonGalleryPositionToggleLabel,
24280
24275
  canCheck: true,
@@ -24299,9 +24294,9 @@ const DesktopMoreButton = (props) => {
24299
24294
  }
24300
24295
  };
24301
24296
  /* @conditional-compile-remove(large-gallery) */
24302
- (_c = (_b = galleryOptions.subMenuProps) === null || _b === void 0 ? void 0 : _b.items) === null || _c === void 0 ? void 0 : _c.push(largeGalleryOptions);
24297
+ (_c = (_b = galleryOptions.subMenuProps) === null || _b === void 0 ? void 0 : _b.items) === null || _c === void 0 ? void 0 : _c.push(largeGalleryOption);
24303
24298
  /* @conditional-compile-remove(gallery-layouts) */
24304
- (_e = (_d = galleryOptions.subMenuProps) === null || _d === void 0 ? void 0 : _d.items) === null || _e === void 0 ? void 0 : _e.push(overflowGalleryOptions);
24299
+ (_e = (_d = galleryOptions.subMenuProps) === null || _d === void 0 ? void 0 : _d.items) === null || _e === void 0 ? void 0 : _e.push(overflowGalleryOption);
24305
24300
  /* @conditional-compile-remove(gallery-layouts) */
24306
24301
  moreButtonContextualMenuItems.push(galleryOptions);
24307
24302
  }
@@ -27171,7 +27166,13 @@ const networkReconnectTileSelector = reselect__namespace.createSelector([getUser
27171
27166
  const CallPage = (props) => {
27172
27167
  const { callInvitationURL, onRenderAvatar, onFetchAvatarPersonaData, onFetchParticipantMenuItems, options, mobileView,
27173
27168
  /* @conditional-compile-remove(gallery-layouts) */
27174
- galleryLayout = 'floatingLocalVideo' } = props;
27169
+ galleryLayout = 'floatingLocalVideo',
27170
+ /* @conditional-compile-remove(gallery-layouts) */
27171
+ onUserSetGalleryLayoutChange,
27172
+ /* @conditional-compile-remove(gallery-layouts) */
27173
+ userSetOverflowGalleryPosition = 'Responsive',
27174
+ /* @conditional-compile-remove(gallery-layouts) */
27175
+ onSetUserSetOverflowGalleryPosition } = props;
27175
27176
  // To use useProps to get these states, we need to create another file wrapping Call,
27176
27177
  // It seems unnecessary in this case, so we get the updated states using this approach.
27177
27178
  const { callStatus } = useSelector$1(callStatusSelector);
@@ -27185,10 +27186,6 @@ const CallPage = (props) => {
27185
27186
  // Reduce the controls shown when mobile view is enabled.
27186
27187
  const callControlOptions = mobileView ? reduceCallControlsForMobile(options === null || options === void 0 ? void 0 : options.callControls) : options === null || options === void 0 ? void 0 : options.callControls;
27187
27188
  const drawerMenuHostId = reactHooks.useId('drawerMenuHost');
27188
- /* @conditional-compile-remove(gallery-layouts) */
27189
- const [userSetOverflowGalleryPosition, setUserSetOverflowGalleryPosition] = React.useState('Responsive');
27190
- /* @conditional-compile-remove(gallery-layouts) */
27191
- const [userSetGalleryLayout, setUserSetGalleryLayout] = React.useState(galleryLayout);
27192
27189
  return (React__default["default"].createElement(CallArrangement, { id: drawerMenuHostId, complianceBannerProps: Object.assign(Object.assign({}, complianceBannerProps), { strings }), errorBarProps: (options === null || options === void 0 ? void 0 : options.errorBar) !== false && errorBarProps, mutedNotificationProps: mutedNotificationProps, callControlProps: {
27193
27190
  callInvitationURL: callInvitationURL,
27194
27191
  onFetchParticipantMenuItems: onFetchParticipantMenuItems,
@@ -27204,13 +27201,13 @@ const CallPage = (props) => {
27204
27201
  /* @conditional-compile-remove(gallery-layouts) */
27205
27202
  userSetOverflowGalleryPosition: userSetOverflowGalleryPosition,
27206
27203
  /* @conditional-compile-remove(gallery-layouts) */
27207
- userSetGalleryLayout: userSetGalleryLayout }))) : (React__default["default"].createElement(NetworkReconnectTile, Object.assign({}, networkReconnectTileProps)))) : (React__default["default"].createElement(React__default["default"].Fragment, null)), updateSidePaneRenderer: props.updateSidePaneRenderer, mobileChatTabHeader: props.mobileChatTabHeader, dataUiId: 'call-page', latestErrors: props.latestErrors, onDismissError: props.onDismissError,
27204
+ userSetGalleryLayout: galleryLayout }))) : (React__default["default"].createElement(NetworkReconnectTile, Object.assign({}, networkReconnectTileProps)))) : (React__default["default"].createElement(React__default["default"].Fragment, null)), updateSidePaneRenderer: props.updateSidePaneRenderer, mobileChatTabHeader: props.mobileChatTabHeader, dataUiId: 'call-page', latestErrors: props.latestErrors, onDismissError: props.onDismissError,
27208
27205
  /* @conditional-compile-remove(gallery-layouts) */
27209
- onUserSetOverflowGalleryPositionChange: setUserSetOverflowGalleryPosition,
27206
+ onUserSetOverflowGalleryPositionChange: onSetUserSetOverflowGalleryPosition,
27210
27207
  /* @conditional-compile-remove(gallery-layouts) */
27211
- onUserSetGalleryLayoutChange: setUserSetGalleryLayout,
27208
+ onUserSetGalleryLayoutChange: onUserSetGalleryLayoutChange,
27212
27209
  /* @conditional-compile-remove(gallery-layouts) */
27213
- userSetGalleryLayout: userSetGalleryLayout,
27210
+ userSetGalleryLayout: galleryLayout,
27214
27211
  /* @conditional-compile-remove(capabilities) */
27215
27212
  capabilitiesChangedNotificationBarProps: props.capabilitiesChangedNotificationBarProps }));
27216
27213
  };
@@ -28894,7 +28891,7 @@ const isShowing = (overrideSidePane) => {
28894
28891
  return !!(overrideSidePane === null || overrideSidePane === void 0 ? void 0 : overrideSidePane.isActive);
28895
28892
  };
28896
28893
  const MainScreen = (props) => {
28897
- var _a, _b, _c, _d, _e, _f, _g;
28894
+ var _a, _b, _c, _d, _e, _f, _g, _h;
28898
28895
  const adapter = useAdapter();
28899
28896
  const { camerasCount, microphonesCount } = useSelector$1(deviceCountSelector);
28900
28897
  const hasCameras = camerasCount > 0;
@@ -28922,6 +28919,10 @@ const MainScreen = (props) => {
28922
28919
  const endedCall = useSelector$1(getEndedCall);
28923
28920
  const [sidePaneRenderer, setSidePaneRenderer] = React__default["default"].useState();
28924
28921
  const [injectedSidePaneProps, setInjectedSidePaneProps] = React__default["default"].useState();
28922
+ /* @conditional-compile-remove(gallery-layouts) */
28923
+ const [userSetGalleryLayout, setUserSetGalleryLayout] = React.useState((_c = (_b = (_a = props.options) === null || _a === void 0 ? void 0 : _a.galleryOptions) === null || _b === void 0 ? void 0 : _b.layout) !== null && _c !== void 0 ? _c : 'floatingLocalVideo');
28924
+ /* @conditional-compile-remove(gallery-layouts) */
28925
+ const [userSetOverflowGalleryPosition, setUserSetOverflowGalleryPosition] = React.useState('Responsive');
28925
28926
  const overridePropsRef = React.useRef(props.overrideSidePane);
28926
28927
  React.useEffect(() => {
28927
28928
  setInjectedSidePaneProps(props.overrideSidePane);
@@ -28971,11 +28972,11 @@ const MainScreen = (props) => {
28971
28972
  adapter.joinCall();
28972
28973
  }, updateSidePaneRenderer: setSidePaneRenderer, latestErrors: latestErrors, onDismissError: onDismissError, modalLayerHostId: props.modalLayerHostId,
28973
28974
  /* @conditional-compile-remove(call-readiness) */
28974
- deviceChecks: (_a = props.options) === null || _a === void 0 ? void 0 : _a.deviceChecks,
28975
+ deviceChecks: (_d = props.options) === null || _d === void 0 ? void 0 : _d.deviceChecks,
28975
28976
  /* @conditional-compile-remove(call-readiness) */
28976
- onPermissionsTroubleshootingClick: (_b = props.options) === null || _b === void 0 ? void 0 : _b.onPermissionsTroubleshootingClick,
28977
+ onPermissionsTroubleshootingClick: (_e = props.options) === null || _e === void 0 ? void 0 : _e.onPermissionsTroubleshootingClick,
28977
28978
  /* @conditional-compile-remove(call-readiness) */
28978
- onNetworkingTroubleShootingClick: (_c = props.options) === null || _c === void 0 ? void 0 : _c.onNetworkingTroubleShootingClick,
28979
+ onNetworkingTroubleShootingClick: (_f = props.options) === null || _f === void 0 ? void 0 : _f.onNetworkingTroubleShootingClick,
28979
28980
  /* @conditional-compile-remove(capabilities) */
28980
28981
  capabilitiesChangedNotificationBarProps: capabilitiesChangedNotificationBarProps }));
28981
28982
  break;
@@ -28989,7 +28990,7 @@ const MainScreen = (props) => {
28989
28990
  pageElement = (React__default["default"].createElement(NoticePage, { iconName: "NoticePageJoinCallFailedDueToNoNetwork", title: locale.strings.call.failedToJoinCallDueToNoNetworkTitle, moreDetails: locale.strings.call.failedToJoinCallDueToNoNetworkMoreDetails, dataUiId: 'join-call-failed-due-to-no-network-page' }));
28990
28991
  break;
28991
28992
  case 'leaving':
28992
- pageElement = (React__default["default"].createElement(NoticePage, { title: (_d = locale.strings.call.leavingCallTitle) !== null && _d !== void 0 ? _d : 'Leaving...', dataUiId: 'leaving-page', pageStyle: leavePageStyle, disableStartCallButton: true }));
28993
+ pageElement = (React__default["default"].createElement(NoticePage, { title: (_g = locale.strings.call.leavingCallTitle) !== null && _g !== void 0 ? _g : 'Leaving...', dataUiId: 'leaving-page', pageStyle: leavePageStyle, disableStartCallButton: true }));
28993
28994
  break;
28994
28995
  case 'leftCall': {
28995
28996
  const { title, moreDetails, disableStartCallButton } = getEndedCallStrings(locale, endedCall);
@@ -29010,7 +29011,13 @@ const MainScreen = (props) => {
29010
29011
  case 'call':
29011
29012
  pageElement = (React__default["default"].createElement(CallPage, { onRenderAvatar: onRenderAvatar, callInvitationURL: callInvitationUrl, onFetchAvatarPersonaData: onFetchAvatarPersonaData, onFetchParticipantMenuItems: onFetchParticipantMenuItems, mobileView: props.mobileView, modalLayerHostId: props.modalLayerHostId, options: props.options, updateSidePaneRenderer: setSidePaneRenderer, mobileChatTabHeader: props.mobileChatTabHeader, latestErrors: latestErrors, onDismissError: onDismissError,
29012
29013
  /* @conditional-compile-remove(gallery-layouts) */
29013
- galleryLayout: ((_f = (_e = props.options) === null || _e === void 0 ? void 0 : _e.galleryOptions) === null || _f === void 0 ? void 0 : _f.layout) ? props.options.galleryOptions.layout : 'floatingLocalVideo',
29014
+ galleryLayout: userSetGalleryLayout,
29015
+ /* @conditional-compile-remove(gallery-layouts) */
29016
+ onUserSetGalleryLayoutChange: setUserSetGalleryLayout,
29017
+ /* @conditional-compile-remove(gallery-layouts) */
29018
+ onSetUserSetOverflowGalleryPosition: setUserSetOverflowGalleryPosition,
29019
+ /* @conditional-compile-remove(gallery-layouts) */
29020
+ userSetOverflowGalleryPosition: userSetOverflowGalleryPosition,
29014
29021
  /* @conditional-compile-remove(capabilities) */
29015
29022
  capabilitiesChangedNotificationBarProps: capabilitiesChangedNotificationBarProps }));
29016
29023
  break;
@@ -29026,7 +29033,7 @@ const MainScreen = (props) => {
29026
29033
  case 'unsupportedEnvironment':
29027
29034
  pageElement = (React__default["default"].createElement(React__default["default"].Fragment, null,
29028
29035
  /* @conditional-compile-remove(unsupported-browser) */
29029
- React__default["default"].createElement(UnsupportedBrowserPage, { onTroubleshootingClick: (_g = props.options) === null || _g === void 0 ? void 0 : _g.onEnvironmentInfoTroubleshootingClick, environmentInfo: adapter.getState().environmentInfo })));
29036
+ React__default["default"].createElement(UnsupportedBrowserPage, { onTroubleshootingClick: (_h = props.options) === null || _h === void 0 ? void 0 : _h.onEnvironmentInfoTroubleshootingClick, environmentInfo: adapter.getState().environmentInfo })));
29030
29037
  break;
29031
29038
  }
29032
29039
  if (!pageElement) {