@azure/communication-react 1.18.0-alpha-202407191547 → 1.18.0-alpha-202407200014
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 +71 -18
- package/dist/dist-cjs/communication-react/{ChatMessageComponentAsRichTextEditBox-ChK7xe6Z.js → ChatMessageComponentAsRichTextEditBox-D4ctXnw1.js} +27 -6
- package/dist/dist-cjs/communication-react/ChatMessageComponentAsRichTextEditBox-D4ctXnw1.js.map +1 -0
- package/dist/dist-cjs/communication-react/{RichTextSendBoxWrapper-BLCHZv_g.js → RichTextSendBoxWrapper-F6eqVXer.js} +2 -2
- package/dist/dist-cjs/communication-react/{RichTextSendBoxWrapper-BLCHZv_g.js.map → RichTextSendBoxWrapper-F6eqVXer.js.map} +1 -1
- package/dist/dist-cjs/communication-react/{index-BWVQuckY.js → index-BJO_NOTU.js} +589 -302
- package/dist/dist-cjs/communication-react/index-BJO_NOTU.js.map +1 -0
- 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/calling-stateful-client/src/CallAgentDeclarative.d.ts +3 -3
- package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarative.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarativeCommon.d.ts +1 -1
- package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarativeCommon.js +15 -7
- package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarativeCommon.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/IncomingCallDeclarative.d.ts +2 -8
- package/dist/dist-esm/calling-stateful-client/src/IncomingCallDeclarative.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/TeamsCallAgentDeclarative.d.ts +14 -2
- package/dist/dist-esm/calling-stateful-client/src/TeamsCallAgentDeclarative.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/TeamsIncomingCallDeclarative.d.ts +17 -0
- package/dist/dist-esm/calling-stateful-client/src/TeamsIncomingCallDeclarative.js +49 -0
- package/dist/dist-esm/calling-stateful-client/src/TeamsIncomingCallDeclarative.js.map +1 -0
- package/dist/dist-esm/calling-stateful-client/src/TypeGuards.d.ts +9 -1
- package/dist/dist-esm/calling-stateful-client/src/TypeGuards.js +16 -0
- package/dist/dist-esm/calling-stateful-client/src/TypeGuards.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/index-public.d.ts +1 -1
- package/dist/dist-esm/calling-stateful-client/src/index-public.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/ChatMessage/ChatMessageComponentWrapper.d.ts +8 -2
- package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageComponentWrapper.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBoxPicker.d.ts +6 -4
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBoxPicker.js +2 -12
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBoxPicker.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsRichTextEditBox.d.ts +2 -2
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsRichTextEditBox.js +25 -4
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsRichTextEditBox.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponent.d.ts +8 -6
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponent.js +12 -3
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponent.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/FluentChatMyMessageComponent.js +27 -3
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/FluentChatMyMessageComponent.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/MessageThread.d.ts +9 -15
- package/dist/dist-esm/react-components/src/components/MessageThread.js +10 -1
- package/dist/dist-esm/react-components/src/components/MessageThread.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextEditor.js +28 -22
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextEditor.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBox.d.ts +49 -0
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBox.js +16 -4
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBox.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/RichTextToolbar.js +20 -2
- package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/RichTextToolbar.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/index.d.ts +2 -1
- package/dist/dist-esm/react-components/src/components/index.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/styles/RichTextEditor.styles.js +3 -0
- package/dist/dist-esm/react-components/src/components/styles/RichTextEditor.styles.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/utils/RichTextEditorUtils.d.ts +1 -5
- package/dist/dist-esm/react-components/src/components/utils/RichTextEditorUtils.js +0 -21
- package/dist/dist-esm/react-components/src/components/utils/RichTextEditorUtils.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/utils/SendBoxUtils.d.ts +9 -1
- package/dist/dist-esm/react-components/src/components/utils/SendBoxUtils.js +10 -2
- package/dist/dist-esm/react-components/src/components/utils/SendBoxUtils.js.map +1 -1
- package/dist/dist-esm/react-components/src/localization/locales/en-US/strings.json +8 -2
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreen.js +66 -31
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreen.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadReducer.d.ts +49 -0
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadReducer.js +48 -0
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadReducer.js.map +1 -0
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadUtils.d.ts +33 -1
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadUtils.js +198 -6
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadUtils.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUpload.d.ts +7 -7
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUpload.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/common/SendBoxPicker.d.ts +2 -5
- package/dist/dist-esm/react-composites/src/composites/common/SendBoxPicker.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/common/constants.d.ts +4 -0
- package/dist/dist-esm/react-composites/src/composites/common/constants.js +4 -0
- package/dist/dist-esm/react-composites/src/composites/common/constants.js.map +1 -1
- package/package.json +9 -9
- package/dist/dist-cjs/communication-react/ChatMessageComponentAsRichTextEditBox-ChK7xe6Z.js.map +0 -1
- package/dist/dist-cjs/communication-react/index-BWVQuckY.js.map +0 -1
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/useImageUpload.d.ts +0 -12
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/useImageUpload.js +0 -115
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/useImageUpload.js.map +0 -1
@@ -176,7 +176,7 @@ function getDefaultExportFromCjs (x) {
|
|
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.18.0-alpha-
|
179
|
+
var telemetryVersion = '1.18.0-alpha-202407200014';
|
180
180
|
|
181
181
|
|
182
182
|
var telemetryVersion$1 = /*@__PURE__*/getDefaultExportFromCjs(telemetryVersion);
|
@@ -1942,7 +1942,7 @@ const typingIndicatorStringStyle = react.mergeStyles({
|
|
1942
1942
|
wordBreak: 'break-word'
|
1943
1943
|
});
|
1944
1944
|
|
1945
|
-
var participantItem$k={isMeText:"(you)",menuTitle:"More Options",removeButtonLabel:"Remove",sharingIconLabel:"Sharing",mutedIconLabel:"Muted",displayNamePlaceholder:"Unnamed participant",participantStateRinging:"Calling...",participantStateHold:"On hold",attendeeRole:"Attendee"};var ParticipantList$l={overflowParticipantCount:"+{overflowCount} more"};var typingIndicator$k={singleUser:"{user} is typing ...",multipleUsers:"{users} are typing ...",multipleUsersAbbreviateOne:"{users} and 1 other are typing ...",multipleUsersAbbreviateMany:"{users} and {numOthers} others are typing ...",delimiter:", "};var sendBox$k={placeholderText:"Enter a message",textTooLong:"Your message length is over the maximum limit.",sendButtonAriaLabel:"Send message",attachmentUploadsPendingError:"Uploading... Please wait.",removeAttachment:"Remove file",uploading:"Uploading",uploadCompleted:"Upload completed",attachmentMoreMenu:"More Options"};var richTextSendBox$k={placeholderText:"Enter a message",textTooLong:"Your message length is over the maximum limit.",sendButtonAriaLabel:"Send message",attachmentUploadsPendingError:"Uploading... Please wait.",removeAttachment:"Remove file",uploading:"Uploading",uploadCompleted:"Upload completed",richTextBoldTooltip:"Bold",richTextItalicTooltip:"Italic",richTextUnderlineTooltip:"Underline",richTextBulletListTooltip:"Bulleted list",richTextNumberListTooltip:"Numbered list",richTextIncreaseIndentTooltip:"Increase indent",richTextDecreaseIndentTooltip:"Decrease indent",richTextInsertTableTooltip:"Insert table",richTextFormatButtonTooltip:"Format",richTextInsertRowOrColumnMenu:"Insert",richTextInsertTableMenuTitle:"Insert {column} x {row} table",richTextInsertRowAboveMenu:"Insert above",richTextInsertRowBelowMenu:"Insert below",richTextInsertColumnLeftMenu:"Insert left",richTextInsertColumnRightMenu:"Insert right",richTextDeleteRowOrColumnMenu:"Delete",richTextDeleteColumnMenu:"Delete column",richTextDeleteRowMenu:"Delete row",richTextDeleteTableMenu:"Delete table",richTextToolbarMoreButtonAriaLabel:"More options",attachmentMoreMenu:"More Options"};var mentionPopover$k={mentionPopoverHeader:"Suggestions"};var imageOverlay$k={downloadButtonLabel:"Download",dismissButtonAriaLabel:"Close"};var messageStatusIndicator$k={deliveredAriaLabel:"Message sent",deliveredTooltipText:"Sent",seenAriaLabel:"Message seen by others",seenTooltipText:"Seen",readByTooltipText:"Read by {messageThreadReadCount} of {remoteParticipantsCount}",sendingAriaLabel:"Message sending",sendingTooltipText:"Sending",failedToSendAriaLabel:"Message failed to send",failedToSendTooltipText:"Failed to send"};var endCallButton$k={label:"Leave",tooltipContent:"Leave call",leaveOption:"Leave",endCallOption:"End call for everyone"};var cameraButton$k={onLabel:"Camera",offLabel:"Camera",tooltipDisabledContent:"Camera is disabled",tooltipOnContent:"Turn off camera",tooltipOffContent:"Turn on camera",tooltipVideoLoadingContent:"Video is loading",cameraMenuTitle:"Camera",cameraMenuTooltip:"Choose camera",cameraButtonSplitRoleDescription:"Split button",onSplitButtonAriaLabel:"Turn off camera and camera options",offSplitButtonAriaLabel:"Turn on camera and camera options",cameraActionTurnedOnAnnouncement:"Your camera has been turned on",cameraActionTurnedOffAnnouncement:"Your camera has been turned off",onSplitButtonPrimaryActionCamera:"Turn off camera",offSplitButtonPrimaryActionCamera:"Turn on camera",cameraPrimaryActionSplitButtonTitle:"Use camera",videoEffectsMenuItemTitle:"Effects"};var microphoneButton$k={onLabel:"Mic",offLabel:"Mic",tooltipDisabledContent:"Microphone is disabled",tooltipOnContent:"Mute microphone",tooltipOffContent:"Unmute microphone",microphoneMenuTitle:"Microphone",microphoneMenuTooltip:"Choose microphone",speakerMenuTitle:"Speaker",speakerMenuTooltip:"Choose speaker",microphoneButtonSplitRoleDescription:"Split button",onSplitButtonAriaLabel:"Mute microphone and audio options",offSplitButtonAriaLabel:"Unmute microphone and audio options",microphoneActionTurnedOnAnnouncement:"Your microphone has been turned on",microphoneActionTurnedOffAnnouncement:"Your microphone has been turned off",offSplitButtonMicrophonePrimaryAction:"Unmute microphone",onSplitButtonMicrophonePrimaryAction:"Mute microphone",microphonePrimaryActionSplitButtonTitle:"Use microphone"};var devicesButton$k={label:"Devices",tooltipContent:"Manage devices",cameraMenuTitle:"Camera",cameraMenuTooltip:"Choose camera",audioDeviceMenuTitle:"Audio Device",audioDeviceMenuTooltip:"Choose audio device",microphoneMenuTitle:"Microphone",microphoneMenuTooltip:"Choose microphone",speakerMenuTitle:"Speaker",speakerMenuTooltip:"Choose speaker"};var participantsButton$k={label:"People",tooltipContent:"Show participants",menuHeader:"In this call",participantsListButtonLabel:"{numParticipants} people",muteAllButtonLabel:"Mute all",copyInviteLinkButtonLabel:"Copy invite link",copyInviteLinkActionedAriaLabel:"Invite link copied"};var screenShareButton$k={onLabel:"Stop presenting",offLabel:"Present",tooltipDisabledContent:"Presenting is disabled",tooltipOnContent:"Presenting your screen",tooltipOffContent:"Present your screen"};var raiseHandButton$k={offLabel:"Raise",onLabel:"Lower",tooltipDisabledContent:"Raise Hand action is disabled",tooltipOnContent:"Lower Hand",tooltipOffContent:"Raise Hand"};var reactionButton$k={label:"React",ariaLabel:"React Button, Send a reaction",tooltipDisabledContent:"Reaction action is disabled",tooltipContent:"Send a reaction",likeReactionTooltipContent:"Like",heartReactionTooltipContent:"Love",laughReactionTooltipContent:"Laugh",applauseReactionTooltipContent:"Applause",surprisedReactionTooltipContent:"Surprised"};var messageThread$k={yesterday:"Yesterday",sunday:"Sunday",monday:"Monday",tuesday:"Tuesday",wednesday:"Wednesday",thursday:"Thursday",friday:"Friday",saturday:"Saturday",participantJoined:"joined the chat.",participantLeft:"left the chat.",editMessage:"Edit",removeMessage:"Delete",resendMessage:"Try sending again",failToSendTag:"Failed to send",editedTag:"Edited",liveAuthorIntro:"{author} says",messageContentAriaText:"{status} {author} said {message}",messageContentMineAriaText:"{status} You said {message}",editBoxTextLimit:"Your message is over the limit of {limitNumber} characters",editBoxPlaceholderText:"Edit your message",newMessagesIndicator:"New messages",noDisplayNameSub:"No name",editBoxCancelButton:"Cancel",editBoxSubmitButton:"Done",messageReadCount:"Read by {messageReadByCount} of {remoteParticipantsCount}",actionMenuMoreOptions:"More Options",downloadAttachment:"Download file",openAttachment:"Open file",blockedWarningText:"This message was deleted due to organizational policy.",blockedWarningLinkText:"Details",attachmentCardGroupMessage:"The message has {attachmentCount} attachment",messageDeletedAnnouncementAriaLabel:"The message is deleted",richTextBoldTooltip:"Bold",richTextItalicTooltip:"Italic",richTextUnderlineTooltip:"Underline",richTextBulletListTooltip:"Bulleted list",richTextNumberListTooltip:"Numbered list",richTextIncreaseIndentTooltip:"Increase indent",richTextDecreaseIndentTooltip:"Decrease indent",richTextInsertTableTooltip:"Insert table",richTextFormatButtonTooltip:"Format",richTextInsertRowOrColumnMenu:"Insert",richTextInsertTableMenuTitle:"Insert {column} x {row} table",richTextInsertRowAboveMenu:"Insert above",richTextInsertRowBelowMenu:"Insert below",richTextInsertColumnLeftMenu:"Insert left",richTextInsertColumnRightMenu:"Insert right",richTextDeleteRowOrColumnMenu:"Delete",richTextDeleteColumnMenu:"Delete column",richTextDeleteRowMenu:"Delete row",richTextDeleteTableMenu:"Delete table",richTextToolbarMoreButtonAriaLabel:"More options",attachmentUploadsPendingError:"Uploading... Please wait."};var errorBar$k={unableToReachChatService:"You are offline",accessDenied:"Unable to access chat services - please check the user credentials provided",userNotInChatThread:"You are no longer in this chat thread",sendMessageNotInChatThread:"Failed to send message because you are no longer in this chat thread",sendMessageGeneric:"Failed to send message",callingNetworkFailure:"Troubling connecting call - you seem to be offline",startVideoGeneric:"Failed to start video",stopVideoGeneric:"Failed to stop video",muteGeneric:"Failed to mute microphone",unmuteGeneric:"Failed to unmute microphone",speakingWhileMuted:"Your microphone is muted",startScreenShareGeneric:"There was an issue starting screen share.",stopScreenShareGeneric:"Failed to stop screen sharing",callNetworkQualityLow:"Network quality is low.",teamsMeetingCallNetworkQualityLow:"Network quality is low.",callNoSpeakerFound:"No speakers or headphones found. Connect an audio device to hear the call.",callNoMicrophoneFound:"No microphones found. Connect an audio input device.",callMicrophoneAccessDenied:"Unable to access microphone. Click the lock in the address bar to grant permission to this webpage.",callMicrophoneAccessDeniedSafari:"Unable to access microphone. Refresh the page to allow permissions, or check this browser’s settings and verify permissions are enabled for this website.",callMicrophoneMutedBySystem:"You are muted by your system.",callMicrophoneUnmutedBySystem:"Your microphone recovered and you were unmuted by your system.",callMacOsMicrophoneAccessDenied:"Unable to access microphone. Grant microphone permission in your macOS privacy settings.",callLocalVideoFreeze:"Network bandwidth is poor. Your video may appear paused for others on the call.",callCameraAccessDenied:"Unable to access camera. Click the lock in the address bar to grant permission to this webpage.",callCameraAccessDeniedSafari:"Unable to access camera. Refresh the page to allow permissions, or check this browser’s settings and verify permissions are enabled for this website.",callCameraAlreadyInUse:"Unable to access camera. It may already be in use by another application.",callVideoStoppedBySystem:"Your video has been stopped by your system.",callVideoRecoveredBySystem:"Your video has resumed.",callMacOsCameraAccessDenied:"MacOS is blocking access to your camera. Update your privacy settings to allow this browser to access your camera.",callMacOsScreenShareAccessDenied:"MacOS is blocking screen sharing. Update your privacy settings to allow this browser to record your screen.",dismissButtonAriaLabel:"Close",failedToJoinCallGeneric:"Failed to join call.",failedToJoinCallInvalidMeetingLink:"Unable to join Meeting. Invalid Link.",cameraFrozenForRemoteParticipants:"Users in the call are having issues seeing your video. Please check your devices and network.",unableToStartVideoEffect:"Unable to apply video effect.",startSpotlightWhileMaxParticipantsAreSpotlighted:"Cannot start spotlight on participant(s) because the maximum number of participants are already spotlighted.",mutedByRemoteParticipant:"You were muted by another participant."};var notificationStack$k={callingNetworkFailure:{title:"Troubling connecting call",message:"You seem to be offline. Please check your network connection and try again.",dismissButtonAriaLabel:"Close"},startVideoGeneric:{title:"Failed to start video.",dismissButtonAriaLabel:"Close"},stopVideoGeneric:{title:"Failed to stop video.",dismissButtonAriaLabel:"Close"},muteGeneric:{title:"Failed to mute microphone.",dismissButtonAriaLabel:"Close"},unmuteGeneric:{title:"Failed to unmute microphone.",dismissButtonAriaLabel:"Close"},speakingWhileMuted:{title:"You're muted.",dismissButtonAriaLabel:"Close"},startScreenShareGeneric:{title:"There was an issue starting screen share.",dismissButtonAriaLabel:"Close"},stopScreenShareGeneric:{title:"Failed to stop screen sharing.",dismissButtonAriaLabel:"Close"},callNetworkQualityLow:{title:"Network quality is low.",dismissButtonAriaLabel:"Close"},teamsMeetingCallNetworkQualityLow:{title:"Network quality is low.",dismissButtonAriaLabel:"Close",message:"Join this call from your phone for better sound. You can continue viewing the meeting on this device.",primaryButtonLabel:"Join by Phone"},callNoSpeakerFound:{title:"No speakers or headphones found",message:"Connect an audio device to hear the call.",dismissButtonAriaLabel:"Close"},callNoMicrophoneFound:{title:"No microphones found",message:"Connect an audio input device.",dismissButtonAriaLabel:"Close"},callMicrophoneAccessDenied:{title:"Unable to access microphone",message:"Click the lock in the address bar to grant permission to this webpage.",dismissButtonAriaLabel:"Close"},callMicrophoneAccessDeniedSafari:{title:"Unable to access microphone",message:"Refresh the page to allow permissions, or check this browser’s settings and verify permissions are enabled for this website.",dismissButtonAriaLabel:"Close"},callMicrophoneMutedBySystem:{title:"You are muted by your system.",dismissButtonAriaLabel:"Close"},callMicrophoneUnmutedBySystem:{title:"Your microphone recovered and you were unmuted by your system.",dismissButtonAriaLabel:"Close"},callMacOsMicrophoneAccessDenied:{title:"Unable to access microphone",message:"Grant microphone permission in your macOS privacy settings.",dismissButtonAriaLabel:"Close"},callLocalVideoFreeze:{title:"Network bandwidth is poor",message:"Your video may appear paused for others on the call.",dismissButtonAriaLabel:"Close"},callCameraAccessDenied:{title:"Unable to access camera",message:"Click the lock in the address bar to grant permission to this webpage.",dismissButtonAriaLabel:"Close"},callCameraAccessDeniedSafari:{title:"Unable to access camera",message:"Refresh the page to allow permissions, or check this browser’s settings and verify permissions are enabled for this website.",dismissButtonAriaLabel:"Close"},callCameraAlreadyInUse:{title:"Unable to access camera",message:"It may already be in use by another application.",dismissButtonAriaLabel:"Close"},callVideoStoppedBySystem:{title:"Your video has been stopped by your system.",dismissButtonAriaLabel:"Close"},callVideoRecoveredBySystem:{title:"Your video has resumed.",dismissButtonAriaLabel:"Close"},callMacOsCameraAccessDenied:{title:"MacOS is blocking access to your camera",message:"Update your privacy settings to allow this browser to access your camera.",dismissButtonAriaLabel:"Close"},callMacOsScreenShareAccessDenied:{title:"MacOS is blocking screen sharing",message:"Update your privacy settings to allow this browser to record your screen.",dismissButtonAriaLabel:"Close"},failedToJoinCallGeneric:{title:"Failed to join call.",dismissButtonAriaLabel:"Close"},failedToJoinCallInvalidMeetingLink:{title:"Unable to join Meeting. Invalid Link.",dismissButtonAriaLabel:"Close"},cameraFrozenForRemoteParticipants:{title:"Users in the call are having issues seeing your video",message:"Please check your devices and network.",dismissButtonAriaLabel:"Close"},unableToStartVideoEffect:{title:"Unable to apply video effect.",dismissButtonAriaLabel:"Close"},startSpotlightWhileMaxParticipantsAreSpotlighted:{title:"Cannot start spotlight on participant(s)",message:"The maximum number of participants are already spotlighted.",dismissButtonAriaLabel:"Close"},mutedByRemoteParticipant:{title:"You were muted by another participant.",dismissButtonAriaLabel:"Close"},recordingStarted:{title:"Recording has started.",message:"By joining, you are giving consent for this meeting to be transcribed.",dismissButtonAriaLabel:"Close"},transcriptionStarted:{title:"Transcription has started.",message:"By joining, you are giving consent for this meeting to be transcribed.",dismissButtonAriaLabel:"Close"},recordingStopped:{title:"Recording is being saved.",message:"Recording has stopped.",dismissButtonAriaLabel:"Close"},transcriptionStopped:{title:"Transcription is being saved.",message:"Transcription has stopped.",dismissButtonAriaLabel:"Close"},recordingAndTranscriptionStarted:{title:"Recording and transcription have started.",message:"By joining, you are giving consent for this meeting to be transcribed.",dismissButtonAriaLabel:"Close"},recordingAndTranscriptionStopped:{title:"Recording and transcription are being saved.",message:"Recording and transcription have stopped.",dismissButtonAriaLabel:"Close"},recordingStoppedStillTranscribing:{title:"Recording has stopped.",message:"You are now only transcribing this meeting.",dismissButtonAriaLabel:"Close"},transcriptionStoppedStillRecording:{title:"Transcription has stopped.",message:"You are now only recording this meeting.",dismissButtonAriaLabel:"Close"}};var videoGallery$k={screenIsBeingSharedMessage:"You are sharing your screen",screenShareLoadingMessage:"Loading {participant}'s screen",localVideoLabel:"You",localVideoCameraSwitcherLabel:"Switch camera",localVideoMovementLabel:"Movable Local Video Tile",localVideoMovementAriaLabel:"Movable Local Video Tile",localVideoSelectedDescription:"{cameraName} selected",displayNamePlaceholder:"Unnamed participant",fitRemoteParticipantToFrame:"Fit to frame",fillRemoteParticipantFrame:"Fill frame",pinParticipantForMe:"Pin for me",pinParticipantForMeLimitReached:"Pin (limit reached)",unpinParticipantForMe:"Unpin",pinParticipantMenuItemAriaLabel:"Pin {participantName}",unpinParticipantMenuItemAriaLabel:"Unpin {participantName}",pinnedParticipantAnnouncementAriaLabel:"Pinned {participantName}",unpinnedParticipantAnnouncementAriaLabel:"Unpinned {participantName}",startSpotlightVideoTileMenuLabel:"Spotlight for everyone",addSpotlightVideoTileMenuLabel:"Add spotlight",spotlightLimitReachedMenuTitle:"Spotlight limit reached",stopSpotlightVideoTileMenuLabel:"Stop spotlighting",stopSpotlightOnSelfVideoTileMenuLabel:"Exit spotlight",attendeeRole:"Attendee",muteParticipantMenuItemLabel:"Mute"};var dialpad$k={placeholderText:"Enter phone number",deleteButtonAriaLabel:"Delete"};var holdButton$k={onLabel:"Resume",offLabel:"Hold",tooltipOnContent:"Resume call",tooltipOffContent:"Hold call"};var videoTile$k={participantStateRinging:"Calling...",participantStateHold:"On hold",moreOptionsButtonAriaLabel:"More Options"};var CameraAndMicrophoneSitePermissionsRequest$k={primaryText:"Allow {appName} to use your camera and microphone",secondaryText:"This is so participants can see and hear you.",linkText:"Need help? Get troubleshooting help",primaryButtonText:"Continue without camera and microphone",ariaLabel:"Allow camera and microphone access"};var CameraSitePermissionsRequest$k={primaryText:"Allow {appName} to use your camera",secondaryText:"This is so participants can see you.",linkText:"Need help? Get troubleshooting help",primaryButtonText:"Continue without camera",ariaLabel:"Allow camera access"};var MicrophoneSitePermissionsRequest$k={primaryText:"Allow {appName} to use your microphone",secondaryText:"This is so participants can hear you.",linkText:"Need help? Get troubleshooting help",primaryButtonText:"Continue without microphone",ariaLabel:"Allow microphone access"};var CameraAndMicrophoneSitePermissionsCheck$k={primaryText:"Checking for camera and microphone access",secondaryText:"Allow access if prompted. This is so participants can see and hear you.",linkText:"Need help? Get troubleshooting help",primaryButtonText:"Continue without camera and microphone",ariaLabel:"Checking for camera and microphone access. Allow access if prompted."};var CameraSitePermissionsCheck$k={primaryText:"Checking for camera access",secondaryText:"Allow access if prompted. This is so participants can see you.",linkText:"Need help? Get troubleshooting help",primaryButtonText:"Continue without camera",ariaLabel:"Checking for camera access. Allow access if prompted."};var MicrophoneSitePermissionsCheck$k={primaryText:"Checking for microphone access",secondaryText:"Allow access if prompted. This is so participants can hear you.",linkText:"Need help? Get troubleshooting help",primaryButtonText:"Continue without microphone",ariaLabel:"Checking for microphone access. Allow access if prompted."};var CameraAndMicrophoneSitePermissionsDenied$k={primaryText:"Unable to access camera and microphone",secondaryText:"Click the lock icon in the address bar to grant microphone permissions to this webpage. A page refresh may be required.",primaryButtonText:"Continue without camera and microphone",linkText:"Need help? Get troubleshooting help"};var CameraAndMicrophoneSitePermissionsDeniedSafari$k={primaryText:"Unable to access camera and microphone",secondaryText:"Refresh the page to allow permissions, or check this browser’s settings and verify permissions are enabled for this website.",primaryButtonText:"Continue without camera and microphone",linkText:"Need help? Get troubleshooting help"};var CameraSitePermissionsDenied$k={primaryText:"Unable to access camera",secondaryText:"Click the lock icon in the address bar to grant camera permissions to this webpage. A page refresh may be required.",primaryButtonText:"Continue without camera",linkText:"Need help? Get troubleshooting help"};var MicrophoneSitePermissionsDenied$k={primaryText:"Unable to access microphone",secondaryText:"Click the lock icon in the address bar to grant microphone permissions to this webpage. A page refresh may be required.",primaryButtonText:"Continue without microphone",linkText:"Need help? Get troubleshooting help"};var CameraSitePermissionsDeniedSafari$k={primaryText:"Unable to access camera",secondaryText:"Refresh the page to allow permissions, or check this browser’s settings and verify permissions are enabled for this website.",primaryButtonText:"Continue without camera",linkText:"Need help? Get troubleshooting help"};var MicrophoneSitePermissionsDeniedSafari$k={primaryText:"Unable to access microphone",secondaryText:"Refresh the page to allow permissions, or check this browser’s settings and verify permissions are enabled for this website.",primaryButtonText:"Continue without microphone",linkText:"Need help? Get troubleshooting help"};var UnsupportedBrowser$l={primaryText:"Browser not supported",secondaryText:"Please join this call using a compatible browser.",moreHelpLinkText:"See compatibility requirements"};var UnsupportedBrowserVersion$l={primaryText:"Browser update needed",secondaryText:"To ensure the best call possible, please update your browser and then try joining the call again.",moreHelpLinkText:"See compatibility requirements",continueAnywayButtonText:"Start call without updating"};var UnsupportedOperatingSystem$l={primaryText:"Operating system not supported",secondaryText:"Please join this call using a device with a compatible operating system.",moreHelpLinkText:"See compatibility requirements"};var BrowserPermissionDenied$k={primaryText:"Can't use your camera or microphone",secondaryText:"Your browser might not have access to your camera or microphone. To fix this, open System Preferences.",primaryButtonText:"Try again",linkText:"Need help? Get troubleshooting help"};var BrowserPermissionDeniedIOS$k={primaryText:"Allow microphone access to continue",secondaryText:"So other participants can hear you.",primaryButtonText:"Try again",imageAltText:"Microphone and camera device permission location for iOS",linkText:"Need help? Get troubleshooting help",step1Text:"Go to the Settings app",step2Text:"Scroll down to settings for this browser",step3Text:"Turn on Microphone (Camera optional)",step4Text:"Try joining the call again",step1DigitText:"1",step2DigitText:"2",step3DigitText:"3",step4DigitText:"4"};var verticalGallery$k={leftNavButtonAriaLabel:"previous page",rightNavButtonAriaLabel:"next page"};var meetingConferencePhoneInfo$k={meetingConferencePhoneInfoModalTitle:"Join call from your phone",meetingConferencePhoneInfoModalDialIn:"Dial number",meetingConferencePhoneInfoModalMeetingId:"Enter meeting ID",meetingConferencePhoneInfoModalWait:"Wait to be admitted by organizer",meetingConferencePhoneInfoModalNoPhoneAvailable:"No phone available",meetingConferencePhoneInfoModalTollGeoData:"{country}, {city}",meetingConferencePhoneInfoModalTollFree:"(Toll-free)",meetingConferencePhoneInfoModalToll:"(Toll)"};var IncomingCallNotification$l={incomingCallNotificationPlaceholderId:"Unknown User",incomingCallNotificationPlaceholderAlert:"Incoming call",incomingCallNoticicationAcceptWithAudioAriaLabel:"Accept with audio",incomingCallNoticicationAcceptWithVideoAriaLabel:"Accept with video",incomingCallNoticicationRejectAriaLabel:"Reject"};var en_US$1 = {participantItem:participantItem$k,ParticipantList:ParticipantList$l,typingIndicator:typingIndicator$k,sendBox:sendBox$k,richTextSendBox:richTextSendBox$k,mentionPopover:mentionPopover$k,imageOverlay:imageOverlay$k,messageStatusIndicator:messageStatusIndicator$k,endCallButton:endCallButton$k,cameraButton:cameraButton$k,microphoneButton:microphoneButton$k,devicesButton:devicesButton$k,participantsButton:participantsButton$k,screenShareButton:screenShareButton$k,raiseHandButton:raiseHandButton$k,reactionButton:reactionButton$k,messageThread:messageThread$k,errorBar:errorBar$k,notificationStack:notificationStack$k,videoGallery:videoGallery$k,dialpad:dialpad$k,holdButton:holdButton$k,videoTile:videoTile$k,CameraAndMicrophoneSitePermissionsRequest:CameraAndMicrophoneSitePermissionsRequest$k,CameraSitePermissionsRequest:CameraSitePermissionsRequest$k,MicrophoneSitePermissionsRequest:MicrophoneSitePermissionsRequest$k,CameraAndMicrophoneSitePermissionsCheck:CameraAndMicrophoneSitePermissionsCheck$k,CameraSitePermissionsCheck:CameraSitePermissionsCheck$k,MicrophoneSitePermissionsCheck:MicrophoneSitePermissionsCheck$k,CameraAndMicrophoneSitePermissionsDenied:CameraAndMicrophoneSitePermissionsDenied$k,CameraAndMicrophoneSitePermissionsDeniedSafari:CameraAndMicrophoneSitePermissionsDeniedSafari$k,CameraSitePermissionsDenied:CameraSitePermissionsDenied$k,MicrophoneSitePermissionsDenied:MicrophoneSitePermissionsDenied$k,CameraSitePermissionsDeniedSafari:CameraSitePermissionsDeniedSafari$k,MicrophoneSitePermissionsDeniedSafari:MicrophoneSitePermissionsDeniedSafari$k,UnsupportedBrowser:UnsupportedBrowser$l,UnsupportedBrowserVersion:UnsupportedBrowserVersion$l,UnsupportedOperatingSystem:UnsupportedOperatingSystem$l,BrowserPermissionDenied:BrowserPermissionDenied$k,BrowserPermissionDeniedIOS:BrowserPermissionDeniedIOS$k,verticalGallery:verticalGallery$k,meetingConferencePhoneInfo:meetingConferencePhoneInfo$k,IncomingCallNotification:IncomingCallNotification$l};
|
1945
|
+
var participantItem$k={isMeText:"(you)",menuTitle:"More Options",removeButtonLabel:"Remove",sharingIconLabel:"Sharing",mutedIconLabel:"Muted",displayNamePlaceholder:"Unnamed participant",participantStateRinging:"Calling...",participantStateHold:"On hold",attendeeRole:"Attendee"};var ParticipantList$l={overflowParticipantCount:"+{overflowCount} more"};var typingIndicator$k={singleUser:"{user} is typing ...",multipleUsers:"{users} are typing ...",multipleUsersAbbreviateOne:"{users} and 1 other are typing ...",multipleUsersAbbreviateMany:"{users} and {numOthers} others are typing ...",delimiter:", "};var sendBox$k={placeholderText:"Enter a message",textTooLong:"Your message length is over the maximum limit.",sendButtonAriaLabel:"Send message",attachmentUploadsPendingError:"Uploading... Please wait.",removeAttachment:"Remove file",uploading:"Uploading",uploadCompleted:"Upload completed",attachmentMoreMenu:"More Options"};var richTextSendBox$k={placeholderText:"Enter a message",textTooLong:"Your message length is over the maximum limit.",sendButtonAriaLabel:"Send message",attachmentUploadsPendingError:"Uploading... Please wait.",removeAttachment:"Remove file",uploading:"Uploading",uploadCompleted:"Upload completed",richTextBoldTooltip:"Bold",richTextItalicTooltip:"Italic",richTextUnderlineTooltip:"Underline",richTextBulletListTooltip:"Bulleted list",richTextNumberListTooltip:"Numbered list",richTextIncreaseIndentTooltip:"Increase indent",richTextDecreaseIndentTooltip:"Decrease indent",richTextInsertTableTooltip:"Insert table",richTextFormatButtonTooltip:"Format",richTextInsertRowOrColumnMenu:"Insert",richTextInsertTableMenuTitle:"Insert {column} x {row} table",richTextInsertRowAboveMenu:"Insert above",richTextInsertRowBelowMenu:"Insert below",richTextInsertColumnLeftMenu:"Insert left",richTextInsertColumnRightMenu:"Insert right",richTextDeleteRowOrColumnMenu:"Delete",richTextDeleteColumnMenu:"Delete column",richTextDeleteRowMenu:"Delete row",richTextDeleteTableMenu:"Delete table",richTextToolbarMoreButtonAriaLabel:"More options",attachmentMoreMenu:"More Options",richTextNewBulletedListItemAnnouncement:"Bullet, new line",richTextNewNumberedListItemAnnouncement:"{0}, new line",richTextBulletedListAppliedAnnouncement:"Bulleted list applied",richTextNumberedListAppliedAnnouncement:"Numbered list applied"};var mentionPopover$k={mentionPopoverHeader:"Suggestions"};var imageOverlay$k={downloadButtonLabel:"Download",dismissButtonAriaLabel:"Close"};var messageStatusIndicator$k={deliveredAriaLabel:"Message sent",deliveredTooltipText:"Sent",seenAriaLabel:"Message seen by others",seenTooltipText:"Seen",readByTooltipText:"Read by {messageThreadReadCount} of {remoteParticipantsCount}",sendingAriaLabel:"Message sending",sendingTooltipText:"Sending",failedToSendAriaLabel:"Message failed to send",failedToSendTooltipText:"Failed to send"};var endCallButton$k={label:"Leave",tooltipContent:"Leave call",leaveOption:"Leave",endCallOption:"End call for everyone"};var cameraButton$k={onLabel:"Camera",offLabel:"Camera",tooltipDisabledContent:"Camera is disabled",tooltipOnContent:"Turn off camera",tooltipOffContent:"Turn on camera",tooltipVideoLoadingContent:"Video is loading",cameraMenuTitle:"Camera",cameraMenuTooltip:"Choose camera",cameraButtonSplitRoleDescription:"Split button",onSplitButtonAriaLabel:"Turn off camera and camera options",offSplitButtonAriaLabel:"Turn on camera and camera options",cameraActionTurnedOnAnnouncement:"Your camera has been turned on",cameraActionTurnedOffAnnouncement:"Your camera has been turned off",onSplitButtonPrimaryActionCamera:"Turn off camera",offSplitButtonPrimaryActionCamera:"Turn on camera",cameraPrimaryActionSplitButtonTitle:"Use camera",videoEffectsMenuItemTitle:"Effects"};var microphoneButton$k={onLabel:"Mic",offLabel:"Mic",tooltipDisabledContent:"Microphone is disabled",tooltipOnContent:"Mute microphone",tooltipOffContent:"Unmute microphone",microphoneMenuTitle:"Microphone",microphoneMenuTooltip:"Choose microphone",speakerMenuTitle:"Speaker",speakerMenuTooltip:"Choose speaker",microphoneButtonSplitRoleDescription:"Split button",onSplitButtonAriaLabel:"Mute microphone and audio options",offSplitButtonAriaLabel:"Unmute microphone and audio options",microphoneActionTurnedOnAnnouncement:"Your microphone has been turned on",microphoneActionTurnedOffAnnouncement:"Your microphone has been turned off",offSplitButtonMicrophonePrimaryAction:"Unmute microphone",onSplitButtonMicrophonePrimaryAction:"Mute microphone",microphonePrimaryActionSplitButtonTitle:"Use microphone"};var devicesButton$k={label:"Devices",tooltipContent:"Manage devices",cameraMenuTitle:"Camera",cameraMenuTooltip:"Choose camera",audioDeviceMenuTitle:"Audio Device",audioDeviceMenuTooltip:"Choose audio device",microphoneMenuTitle:"Microphone",microphoneMenuTooltip:"Choose microphone",speakerMenuTitle:"Speaker",speakerMenuTooltip:"Choose speaker"};var participantsButton$k={label:"People",tooltipContent:"Show participants",menuHeader:"In this call",participantsListButtonLabel:"{numParticipants} people",muteAllButtonLabel:"Mute all",copyInviteLinkButtonLabel:"Copy invite link",copyInviteLinkActionedAriaLabel:"Invite link copied"};var screenShareButton$k={onLabel:"Stop presenting",offLabel:"Present",tooltipDisabledContent:"Presenting is disabled",tooltipOnContent:"Presenting your screen",tooltipOffContent:"Present your screen"};var raiseHandButton$k={offLabel:"Raise",onLabel:"Lower",tooltipDisabledContent:"Raise Hand action is disabled",tooltipOnContent:"Lower Hand",tooltipOffContent:"Raise Hand"};var reactionButton$k={label:"React",ariaLabel:"React Button, Send a reaction",tooltipDisabledContent:"Reaction action is disabled",tooltipContent:"Send a reaction",likeReactionTooltipContent:"Like",heartReactionTooltipContent:"Love",laughReactionTooltipContent:"Laugh",applauseReactionTooltipContent:"Applause",surprisedReactionTooltipContent:"Surprised"};var messageThread$k={yesterday:"Yesterday",sunday:"Sunday",monday:"Monday",tuesday:"Tuesday",wednesday:"Wednesday",thursday:"Thursday",friday:"Friday",saturday:"Saturday",participantJoined:"joined the chat.",participantLeft:"left the chat.",editMessage:"Edit",removeMessage:"Delete",resendMessage:"Try sending again",failToSendTag:"Failed to send",editedTag:"Edited",liveAuthorIntro:"{author} says",messageContentAriaText:"{status} {author} said {message}",messageContentMineAriaText:"{status} You said {message}",editBoxTextLimit:"Your message is over the limit of {limitNumber} characters",editBoxPlaceholderText:"Edit your message",newMessagesIndicator:"New messages",noDisplayNameSub:"No name",editBoxCancelButton:"Cancel",editBoxSubmitButton:"Done",messageReadCount:"Read by {messageReadByCount} of {remoteParticipantsCount}",actionMenuMoreOptions:"More Options",downloadAttachment:"Download file",openAttachment:"Open file",blockedWarningText:"This message was deleted due to organizational policy.",blockedWarningLinkText:"Details",attachmentCardGroupMessage:"The message has {attachmentCount} attachment",messageDeletedAnnouncementAriaLabel:"The message is deleted",richTextBoldTooltip:"Bold",richTextItalicTooltip:"Italic",richTextUnderlineTooltip:"Underline",richTextBulletListTooltip:"Bulleted list",richTextNumberListTooltip:"Numbered list",richTextIncreaseIndentTooltip:"Increase indent",richTextDecreaseIndentTooltip:"Decrease indent",richTextInsertTableTooltip:"Insert table",richTextFormatButtonTooltip:"Format",richTextInsertRowOrColumnMenu:"Insert",richTextInsertTableMenuTitle:"Insert {column} x {row} table",richTextInsertRowAboveMenu:"Insert above",richTextInsertRowBelowMenu:"Insert below",richTextInsertColumnLeftMenu:"Insert left",richTextInsertColumnRightMenu:"Insert right",richTextDeleteRowOrColumnMenu:"Delete",richTextDeleteColumnMenu:"Delete column",richTextDeleteRowMenu:"Delete row",richTextDeleteTableMenu:"Delete table",richTextToolbarMoreButtonAriaLabel:"More options",attachmentUploadsPendingError:"Uploading... Please wait.",richTextNewBulletedListItemAnnouncement:"Bullet, new line",richTextNewNumberedListItemAnnouncement:"{0}, new line"};var errorBar$k={unableToReachChatService:"You are offline",accessDenied:"Unable to access chat services - please check the user credentials provided",userNotInChatThread:"You are no longer in this chat thread",sendMessageNotInChatThread:"Failed to send message because you are no longer in this chat thread",sendMessageGeneric:"Failed to send message",callingNetworkFailure:"Troubling connecting call - you seem to be offline",startVideoGeneric:"Failed to start video",stopVideoGeneric:"Failed to stop video",muteGeneric:"Failed to mute microphone",unmuteGeneric:"Failed to unmute microphone",speakingWhileMuted:"Your microphone is muted",startScreenShareGeneric:"There was an issue starting screen share.",stopScreenShareGeneric:"Failed to stop screen sharing",callNetworkQualityLow:"Network quality is low.",teamsMeetingCallNetworkQualityLow:"Network quality is low.",callNoSpeakerFound:"No speakers or headphones found. Connect an audio device to hear the call.",callNoMicrophoneFound:"No microphones found. Connect an audio input device.",callMicrophoneAccessDenied:"Unable to access microphone. Click the lock in the address bar to grant permission to this webpage.",callMicrophoneAccessDeniedSafari:"Unable to access microphone. Refresh the page to allow permissions, or check this browser’s settings and verify permissions are enabled for this website.",callMicrophoneMutedBySystem:"You are muted by your system.",callMicrophoneUnmutedBySystem:"Your microphone recovered and you were unmuted by your system.",callMacOsMicrophoneAccessDenied:"Unable to access microphone. Grant microphone permission in your macOS privacy settings.",callLocalVideoFreeze:"Network bandwidth is poor. Your video may appear paused for others on the call.",callCameraAccessDenied:"Unable to access camera. Click the lock in the address bar to grant permission to this webpage.",callCameraAccessDeniedSafari:"Unable to access camera. Refresh the page to allow permissions, or check this browser’s settings and verify permissions are enabled for this website.",callCameraAlreadyInUse:"Unable to access camera. It may already be in use by another application.",callVideoStoppedBySystem:"Your video has been stopped by your system.",callVideoRecoveredBySystem:"Your video has resumed.",callMacOsCameraAccessDenied:"MacOS is blocking access to your camera. Update your privacy settings to allow this browser to access your camera.",callMacOsScreenShareAccessDenied:"MacOS is blocking screen sharing. Update your privacy settings to allow this browser to record your screen.",dismissButtonAriaLabel:"Close",failedToJoinCallGeneric:"Failed to join call.",failedToJoinCallInvalidMeetingLink:"Unable to join Meeting. Invalid Link.",cameraFrozenForRemoteParticipants:"Users in the call are having issues seeing your video. Please check your devices and network.",unableToStartVideoEffect:"Unable to apply video effect.",startSpotlightWhileMaxParticipantsAreSpotlighted:"Cannot start spotlight on participant(s) because the maximum number of participants are already spotlighted.",mutedByRemoteParticipant:"You were muted by another participant."};var notificationStack$k={callingNetworkFailure:{title:"Troubling connecting call",message:"You seem to be offline. Please check your network connection and try again.",dismissButtonAriaLabel:"Close"},startVideoGeneric:{title:"Failed to start video.",dismissButtonAriaLabel:"Close"},stopVideoGeneric:{title:"Failed to stop video.",dismissButtonAriaLabel:"Close"},muteGeneric:{title:"Failed to mute microphone.",dismissButtonAriaLabel:"Close"},unmuteGeneric:{title:"Failed to unmute microphone.",dismissButtonAriaLabel:"Close"},speakingWhileMuted:{title:"You're muted.",dismissButtonAriaLabel:"Close"},startScreenShareGeneric:{title:"There was an issue starting screen share.",dismissButtonAriaLabel:"Close"},stopScreenShareGeneric:{title:"Failed to stop screen sharing.",dismissButtonAriaLabel:"Close"},callNetworkQualityLow:{title:"Network quality is low.",dismissButtonAriaLabel:"Close"},teamsMeetingCallNetworkQualityLow:{title:"Network quality is low.",dismissButtonAriaLabel:"Close",message:"Join this call from your phone for better sound. You can continue viewing the meeting on this device.",primaryButtonLabel:"Join by Phone"},callNoSpeakerFound:{title:"No speakers or headphones found",message:"Connect an audio device to hear the call.",dismissButtonAriaLabel:"Close"},callNoMicrophoneFound:{title:"No microphones found",message:"Connect an audio input device.",dismissButtonAriaLabel:"Close"},callMicrophoneAccessDenied:{title:"Unable to access microphone",message:"Click the lock in the address bar to grant permission to this webpage.",dismissButtonAriaLabel:"Close"},callMicrophoneAccessDeniedSafari:{title:"Unable to access microphone",message:"Refresh the page to allow permissions, or check this browser’s settings and verify permissions are enabled for this website.",dismissButtonAriaLabel:"Close"},callMicrophoneMutedBySystem:{title:"You are muted by your system.",dismissButtonAriaLabel:"Close"},callMicrophoneUnmutedBySystem:{title:"Your microphone recovered and you were unmuted by your system.",dismissButtonAriaLabel:"Close"},callMacOsMicrophoneAccessDenied:{title:"Unable to access microphone",message:"Grant microphone permission in your macOS privacy settings.",dismissButtonAriaLabel:"Close"},callLocalVideoFreeze:{title:"Network bandwidth is poor",message:"Your video may appear paused for others on the call.",dismissButtonAriaLabel:"Close"},callCameraAccessDenied:{title:"Unable to access camera",message:"Click the lock in the address bar to grant permission to this webpage.",dismissButtonAriaLabel:"Close"},callCameraAccessDeniedSafari:{title:"Unable to access camera",message:"Refresh the page to allow permissions, or check this browser’s settings and verify permissions are enabled for this website.",dismissButtonAriaLabel:"Close"},callCameraAlreadyInUse:{title:"Unable to access camera",message:"It may already be in use by another application.",dismissButtonAriaLabel:"Close"},callVideoStoppedBySystem:{title:"Your video has been stopped by your system.",dismissButtonAriaLabel:"Close"},callVideoRecoveredBySystem:{title:"Your video has resumed.",dismissButtonAriaLabel:"Close"},callMacOsCameraAccessDenied:{title:"MacOS is blocking access to your camera",message:"Update your privacy settings to allow this browser to access your camera.",dismissButtonAriaLabel:"Close"},callMacOsScreenShareAccessDenied:{title:"MacOS is blocking screen sharing",message:"Update your privacy settings to allow this browser to record your screen.",dismissButtonAriaLabel:"Close"},failedToJoinCallGeneric:{title:"Failed to join call.",dismissButtonAriaLabel:"Close"},failedToJoinCallInvalidMeetingLink:{title:"Unable to join Meeting. Invalid Link.",dismissButtonAriaLabel:"Close"},cameraFrozenForRemoteParticipants:{title:"Users in the call are having issues seeing your video",message:"Please check your devices and network.",dismissButtonAriaLabel:"Close"},unableToStartVideoEffect:{title:"Unable to apply video effect.",dismissButtonAriaLabel:"Close"},startSpotlightWhileMaxParticipantsAreSpotlighted:{title:"Cannot start spotlight on participant(s)",message:"The maximum number of participants are already spotlighted.",dismissButtonAriaLabel:"Close"},mutedByRemoteParticipant:{title:"You were muted by another participant.",dismissButtonAriaLabel:"Close"},recordingStarted:{title:"Recording has started.",message:"By joining, you are giving consent for this meeting to be transcribed.",dismissButtonAriaLabel:"Close"},transcriptionStarted:{title:"Transcription has started.",message:"By joining, you are giving consent for this meeting to be transcribed.",dismissButtonAriaLabel:"Close"},recordingStopped:{title:"Recording is being saved.",message:"Recording has stopped.",dismissButtonAriaLabel:"Close"},transcriptionStopped:{title:"Transcription is being saved.",message:"Transcription has stopped.",dismissButtonAriaLabel:"Close"},recordingAndTranscriptionStarted:{title:"Recording and transcription have started.",message:"By joining, you are giving consent for this meeting to be transcribed.",dismissButtonAriaLabel:"Close"},recordingAndTranscriptionStopped:{title:"Recording and transcription are being saved.",message:"Recording and transcription have stopped.",dismissButtonAriaLabel:"Close"},recordingStoppedStillTranscribing:{title:"Recording has stopped.",message:"You are now only transcribing this meeting.",dismissButtonAriaLabel:"Close"},transcriptionStoppedStillRecording:{title:"Transcription has stopped.",message:"You are now only recording this meeting.",dismissButtonAriaLabel:"Close"}};var videoGallery$k={screenIsBeingSharedMessage:"You are sharing your screen",screenShareLoadingMessage:"Loading {participant}'s screen",localVideoLabel:"You",localVideoCameraSwitcherLabel:"Switch camera",localVideoMovementLabel:"Movable Local Video Tile",localVideoMovementAriaLabel:"Movable Local Video Tile",localVideoSelectedDescription:"{cameraName} selected",displayNamePlaceholder:"Unnamed participant",fitRemoteParticipantToFrame:"Fit to frame",fillRemoteParticipantFrame:"Fill frame",pinParticipantForMe:"Pin for me",pinParticipantForMeLimitReached:"Pin (limit reached)",unpinParticipantForMe:"Unpin",pinParticipantMenuItemAriaLabel:"Pin {participantName}",unpinParticipantMenuItemAriaLabel:"Unpin {participantName}",pinnedParticipantAnnouncementAriaLabel:"Pinned {participantName}",unpinnedParticipantAnnouncementAriaLabel:"Unpinned {participantName}",startSpotlightVideoTileMenuLabel:"Spotlight for everyone",addSpotlightVideoTileMenuLabel:"Add spotlight",spotlightLimitReachedMenuTitle:"Spotlight limit reached",stopSpotlightVideoTileMenuLabel:"Stop spotlighting",stopSpotlightOnSelfVideoTileMenuLabel:"Exit spotlight",attendeeRole:"Attendee",muteParticipantMenuItemLabel:"Mute"};var dialpad$k={placeholderText:"Enter phone number",deleteButtonAriaLabel:"Delete"};var holdButton$k={onLabel:"Resume",offLabel:"Hold",tooltipOnContent:"Resume call",tooltipOffContent:"Hold call"};var videoTile$k={participantStateRinging:"Calling...",participantStateHold:"On hold",moreOptionsButtonAriaLabel:"More Options"};var CameraAndMicrophoneSitePermissionsRequest$k={primaryText:"Allow {appName} to use your camera and microphone",secondaryText:"This is so participants can see and hear you.",linkText:"Need help? Get troubleshooting help",primaryButtonText:"Continue without camera and microphone",ariaLabel:"Allow camera and microphone access"};var CameraSitePermissionsRequest$k={primaryText:"Allow {appName} to use your camera",secondaryText:"This is so participants can see you.",linkText:"Need help? Get troubleshooting help",primaryButtonText:"Continue without camera",ariaLabel:"Allow camera access"};var MicrophoneSitePermissionsRequest$k={primaryText:"Allow {appName} to use your microphone",secondaryText:"This is so participants can hear you.",linkText:"Need help? Get troubleshooting help",primaryButtonText:"Continue without microphone",ariaLabel:"Allow microphone access"};var CameraAndMicrophoneSitePermissionsCheck$k={primaryText:"Checking for camera and microphone access",secondaryText:"Allow access if prompted. This is so participants can see and hear you.",linkText:"Need help? Get troubleshooting help",primaryButtonText:"Continue without camera and microphone",ariaLabel:"Checking for camera and microphone access. Allow access if prompted."};var CameraSitePermissionsCheck$k={primaryText:"Checking for camera access",secondaryText:"Allow access if prompted. This is so participants can see you.",linkText:"Need help? Get troubleshooting help",primaryButtonText:"Continue without camera",ariaLabel:"Checking for camera access. Allow access if prompted."};var MicrophoneSitePermissionsCheck$k={primaryText:"Checking for microphone access",secondaryText:"Allow access if prompted. This is so participants can hear you.",linkText:"Need help? Get troubleshooting help",primaryButtonText:"Continue without microphone",ariaLabel:"Checking for microphone access. Allow access if prompted."};var CameraAndMicrophoneSitePermissionsDenied$k={primaryText:"Unable to access camera and microphone",secondaryText:"Click the lock icon in the address bar to grant microphone permissions to this webpage. A page refresh may be required.",primaryButtonText:"Continue without camera and microphone",linkText:"Need help? Get troubleshooting help"};var CameraAndMicrophoneSitePermissionsDeniedSafari$k={primaryText:"Unable to access camera and microphone",secondaryText:"Refresh the page to allow permissions, or check this browser’s settings and verify permissions are enabled for this website.",primaryButtonText:"Continue without camera and microphone",linkText:"Need help? Get troubleshooting help"};var CameraSitePermissionsDenied$k={primaryText:"Unable to access camera",secondaryText:"Click the lock icon in the address bar to grant camera permissions to this webpage. A page refresh may be required.",primaryButtonText:"Continue without camera",linkText:"Need help? Get troubleshooting help"};var MicrophoneSitePermissionsDenied$k={primaryText:"Unable to access microphone",secondaryText:"Click the lock icon in the address bar to grant microphone permissions to this webpage. A page refresh may be required.",primaryButtonText:"Continue without microphone",linkText:"Need help? Get troubleshooting help"};var CameraSitePermissionsDeniedSafari$k={primaryText:"Unable to access camera",secondaryText:"Refresh the page to allow permissions, or check this browser’s settings and verify permissions are enabled for this website.",primaryButtonText:"Continue without camera",linkText:"Need help? Get troubleshooting help"};var MicrophoneSitePermissionsDeniedSafari$k={primaryText:"Unable to access microphone",secondaryText:"Refresh the page to allow permissions, or check this browser’s settings and verify permissions are enabled for this website.",primaryButtonText:"Continue without microphone",linkText:"Need help? Get troubleshooting help"};var UnsupportedBrowser$l={primaryText:"Browser not supported",secondaryText:"Please join this call using a compatible browser.",moreHelpLinkText:"See compatibility requirements"};var UnsupportedBrowserVersion$l={primaryText:"Browser update needed",secondaryText:"To ensure the best call possible, please update your browser and then try joining the call again.",moreHelpLinkText:"See compatibility requirements",continueAnywayButtonText:"Start call without updating"};var UnsupportedOperatingSystem$l={primaryText:"Operating system not supported",secondaryText:"Please join this call using a device with a compatible operating system.",moreHelpLinkText:"See compatibility requirements"};var BrowserPermissionDenied$k={primaryText:"Can't use your camera or microphone",secondaryText:"Your browser might not have access to your camera or microphone. To fix this, open System Preferences.",primaryButtonText:"Try again",linkText:"Need help? Get troubleshooting help"};var BrowserPermissionDeniedIOS$k={primaryText:"Allow microphone access to continue",secondaryText:"So other participants can hear you.",primaryButtonText:"Try again",imageAltText:"Microphone and camera device permission location for iOS",linkText:"Need help? Get troubleshooting help",step1Text:"Go to the Settings app",step2Text:"Scroll down to settings for this browser",step3Text:"Turn on Microphone (Camera optional)",step4Text:"Try joining the call again",step1DigitText:"1",step2DigitText:"2",step3DigitText:"3",step4DigitText:"4"};var verticalGallery$k={leftNavButtonAriaLabel:"previous page",rightNavButtonAriaLabel:"next page"};var meetingConferencePhoneInfo$k={meetingConferencePhoneInfoModalTitle:"Join call from your phone",meetingConferencePhoneInfoModalDialIn:"Dial number",meetingConferencePhoneInfoModalMeetingId:"Enter meeting ID",meetingConferencePhoneInfoModalWait:"Wait to be admitted by organizer",meetingConferencePhoneInfoModalNoPhoneAvailable:"No phone available",meetingConferencePhoneInfoModalTollGeoData:"{country}, {city}",meetingConferencePhoneInfoModalTollFree:"(Toll-free)",meetingConferencePhoneInfoModalToll:"(Toll)"};var IncomingCallNotification$l={incomingCallNotificationPlaceholderId:"Unknown User",incomingCallNotificationPlaceholderAlert:"Incoming call",incomingCallNoticicationAcceptWithAudioAriaLabel:"Accept with audio",incomingCallNoticicationAcceptWithVideoAriaLabel:"Accept with video",incomingCallNoticicationRejectAriaLabel:"Reject"};var en_US$1 = {participantItem:participantItem$k,ParticipantList:ParticipantList$l,typingIndicator:typingIndicator$k,sendBox:sendBox$k,richTextSendBox:richTextSendBox$k,mentionPopover:mentionPopover$k,imageOverlay:imageOverlay$k,messageStatusIndicator:messageStatusIndicator$k,endCallButton:endCallButton$k,cameraButton:cameraButton$k,microphoneButton:microphoneButton$k,devicesButton:devicesButton$k,participantsButton:participantsButton$k,screenShareButton:screenShareButton$k,raiseHandButton:raiseHandButton$k,reactionButton:reactionButton$k,messageThread:messageThread$k,errorBar:errorBar$k,notificationStack:notificationStack$k,videoGallery:videoGallery$k,dialpad:dialpad$k,holdButton:holdButton$k,videoTile:videoTile$k,CameraAndMicrophoneSitePermissionsRequest:CameraAndMicrophoneSitePermissionsRequest$k,CameraSitePermissionsRequest:CameraSitePermissionsRequest$k,MicrophoneSitePermissionsRequest:MicrophoneSitePermissionsRequest$k,CameraAndMicrophoneSitePermissionsCheck:CameraAndMicrophoneSitePermissionsCheck$k,CameraSitePermissionsCheck:CameraSitePermissionsCheck$k,MicrophoneSitePermissionsCheck:MicrophoneSitePermissionsCheck$k,CameraAndMicrophoneSitePermissionsDenied:CameraAndMicrophoneSitePermissionsDenied$k,CameraAndMicrophoneSitePermissionsDeniedSafari:CameraAndMicrophoneSitePermissionsDeniedSafari$k,CameraSitePermissionsDenied:CameraSitePermissionsDenied$k,MicrophoneSitePermissionsDenied:MicrophoneSitePermissionsDenied$k,CameraSitePermissionsDeniedSafari:CameraSitePermissionsDeniedSafari$k,MicrophoneSitePermissionsDeniedSafari:MicrophoneSitePermissionsDeniedSafari$k,UnsupportedBrowser:UnsupportedBrowser$l,UnsupportedBrowserVersion:UnsupportedBrowserVersion$l,UnsupportedOperatingSystem:UnsupportedOperatingSystem$l,BrowserPermissionDenied:BrowserPermissionDenied$k,BrowserPermissionDeniedIOS:BrowserPermissionDeniedIOS$k,verticalGallery:verticalGallery$k,meetingConferencePhoneInfo:meetingConferencePhoneInfo$k,IncomingCallNotification:IncomingCallNotification$l};
|
1946
1946
|
|
1947
1947
|
// Copyright (c) Microsoft Corporation.
|
1948
1948
|
// Licensed under the MIT License.
|
@@ -5552,6 +5552,12 @@ const addUploadedImagesToMessage = (message, uploadInlineImages) => __awaiter$O(
|
|
5552
5552
|
const imagesPromise = Array.from(document.querySelectorAll('img')).map((img) => {
|
5553
5553
|
return new Promise((resolve, rejects) => {
|
5554
5554
|
const uploadInlineImage = uploadInlineImages.find((imageUpload) => !imageUpload.error && (imageUpload.url === img.src || imageUpload.id === img.id));
|
5555
|
+
// The message might content images that comes with the message before editing, those images are not in the uploadInlineImages array.
|
5556
|
+
// This function should only modify the message content for images in the uploadInlineImages array.
|
5557
|
+
if (!uploadInlineImage) {
|
5558
|
+
resolve();
|
5559
|
+
return;
|
5560
|
+
}
|
5555
5561
|
const imageElement = new Image();
|
5556
5562
|
imageElement.src = img.src;
|
5557
5563
|
imageElement.onload = () => {
|
@@ -5617,11 +5623,13 @@ hasCompletedAttachmentUploads, hasError, disabled }) => {
|
|
5617
5623
|
/**
|
5618
5624
|
* @internal
|
5619
5625
|
*/
|
5620
|
-
const cancelInlineImageUpload = (
|
5626
|
+
const cancelInlineImageUpload$1 = (props) => {
|
5627
|
+
const { imageSrcArray, imageUploadsInProgress, messageId, editBoxOnCancelInlineImageUpload, sendBoxOnCancelInlineImageUpload } = props;
|
5621
5628
|
if (imageSrcArray && imageUploadsInProgress && (imageUploadsInProgress === null || imageUploadsInProgress === void 0 ? void 0 : imageUploadsInProgress.length) > 0) {
|
5622
5629
|
imageUploadsInProgress === null || imageUploadsInProgress === void 0 ? void 0 : imageUploadsInProgress.map((uploadImage) => {
|
5623
5630
|
if (uploadImage.url && !(imageSrcArray === null || imageSrcArray === void 0 ? void 0 : imageSrcArray.includes(uploadImage.url))) {
|
5624
|
-
|
5631
|
+
sendBoxOnCancelInlineImageUpload && sendBoxOnCancelInlineImageUpload(uploadImage.id);
|
5632
|
+
editBoxOnCancelInlineImageUpload && editBoxOnCancelInlineImageUpload(uploadImage.id, messageId || '');
|
5625
5633
|
}
|
5626
5634
|
});
|
5627
5635
|
}
|
@@ -6461,6 +6469,9 @@ const richTextEditorWrapperStyle = (theme) => {
|
|
6461
6469
|
paddingInlineEnd: `0.75rem`,
|
6462
6470
|
maxWidth: '100%',
|
6463
6471
|
color: theme.palette.neutralPrimary,
|
6472
|
+
'& img': {
|
6473
|
+
margin: '0.2rem'
|
6474
|
+
},
|
6464
6475
|
'& table': {
|
6465
6476
|
background: 'transparent',
|
6466
6477
|
borderCollapse: 'collapse',
|
@@ -6775,27 +6786,6 @@ const dataSetApplier = (format, element, context) => {
|
|
6775
6786
|
context.defaultFormatAppliers.dataset(format, element, context);
|
6776
6787
|
}
|
6777
6788
|
};
|
6778
|
-
// divParagraphSanitizer and DefaultSanitizers should be deleted from here and used as part of PastePlugin instead (from roosterjs packages)
|
6779
|
-
// https://github.com/microsoft/roosterjs/issues/2737
|
6780
|
-
/**
|
6781
|
-
* @private
|
6782
|
-
*/
|
6783
|
-
const divParagraphSanitizer = (value, tagName) => {
|
6784
|
-
const tag = tagName.toLowerCase();
|
6785
|
-
if (tag === 'div' || tag === 'p') {
|
6786
|
-
return null;
|
6787
|
-
}
|
6788
|
-
return value;
|
6789
|
-
};
|
6790
|
-
/**
|
6791
|
-
* @private
|
6792
|
-
*/
|
6793
|
-
const DefaultSanitizers = {
|
6794
|
-
width: divParagraphSanitizer,
|
6795
|
-
height: divParagraphSanitizer,
|
6796
|
-
'inline-size': divParagraphSanitizer,
|
6797
|
-
'block-size': divParagraphSanitizer
|
6798
|
-
};
|
6799
6789
|
|
6800
6790
|
/**
|
6801
6791
|
* CopyPastePlugin is a plugin for handling copy and paste events in the editor.
|
@@ -7316,14 +7306,23 @@ const RichTextToolbar = (props) => {
|
|
7316
7306
|
icon: 'RichTextBulletListButtonIcon',
|
7317
7307
|
onClick: () => {
|
7318
7308
|
plugin.onToolbarButtonClick((editor) => {
|
7309
|
+
// check the format state to see if the bulleted list is already applied
|
7310
|
+
const isBullet = formatState === null || formatState === void 0 ? void 0 : formatState.isBullet;
|
7319
7311
|
roosterjsContentModelApi.toggleBullet(editor);
|
7312
|
+
// the bulleted list was added
|
7313
|
+
if (!isBullet) {
|
7314
|
+
setTimeout(() => {
|
7315
|
+
// a small delay and polite aria live are needed for MacOS VoiceOver to announce the change
|
7316
|
+
editor.announce({ ariaLiveMode: 'polite', text: strings.richTextBulletedListAppliedAnnouncement });
|
7317
|
+
}, 50);
|
7318
|
+
}
|
7320
7319
|
});
|
7321
7320
|
},
|
7322
7321
|
text: strings.richTextBulletListTooltip,
|
7323
7322
|
checked: formatState !== undefined && (formatState === null || formatState === void 0 ? void 0 : formatState.isBullet) === true,
|
7324
7323
|
theme: theme
|
7325
7324
|
});
|
7326
|
-
}, [formatState, plugin, strings.richTextBulletListTooltip, theme]);
|
7325
|
+
}, [formatState, plugin, strings.richTextBulletListTooltip, strings.richTextBulletedListAppliedAnnouncement, theme]);
|
7327
7326
|
const numberListButton = React.useMemo(() => {
|
7328
7327
|
return getCommandBarItem({
|
7329
7328
|
dataTestId: 'rich-text-toolbar-number-list-button',
|
@@ -7331,14 +7330,23 @@ const RichTextToolbar = (props) => {
|
|
7331
7330
|
icon: 'RichTextNumberListButtonIcon',
|
7332
7331
|
onClick: () => {
|
7333
7332
|
plugin.onToolbarButtonClick((editor) => {
|
7333
|
+
// check the format state to see if the numbered list is already applied
|
7334
|
+
const isNumbering = formatState === null || formatState === void 0 ? void 0 : formatState.isNumbering;
|
7334
7335
|
roosterjsContentModelApi.toggleNumbering(editor);
|
7336
|
+
// the numbered list was added
|
7337
|
+
if (!isNumbering) {
|
7338
|
+
// a small delay and polite aria live are needed for MacOS VoiceOver to announce the change
|
7339
|
+
setTimeout(() => {
|
7340
|
+
editor.announce({ ariaLiveMode: 'polite', text: strings.richTextNumberedListAppliedAnnouncement });
|
7341
|
+
}, 50);
|
7342
|
+
}
|
7335
7343
|
});
|
7336
7344
|
},
|
7337
7345
|
text: strings.richTextNumberListTooltip,
|
7338
7346
|
checked: formatState !== undefined && (formatState === null || formatState === void 0 ? void 0 : formatState.isNumbering) === true,
|
7339
7347
|
theme: theme
|
7340
7348
|
});
|
7341
|
-
}, [formatState, plugin, strings.richTextNumberListTooltip, theme]);
|
7349
|
+
}, [formatState, plugin, strings.richTextNumberListTooltip, strings.richTextNumberedListAppliedAnnouncement, theme]);
|
7342
7350
|
const indentDecreaseButton = React.useMemo(() => {
|
7343
7351
|
return getCommandBarItem({
|
7344
7352
|
dataTestId: 'rich-text-toolbar-indent-decrease-button',
|
@@ -7659,9 +7667,8 @@ const RichTextEditor = React.forwardRef((props, ref) => {
|
|
7659
7667
|
editor.current.formatContentModel((model) => {
|
7660
7668
|
// Create a new empty paragraph with selection marker
|
7661
7669
|
// this is needed for correct processing of images after the content is deleted
|
7662
|
-
const
|
7663
|
-
|
7664
|
-
model.blocks = [block];
|
7670
|
+
const newModel = roosterjsContentModelDom.createEmptyModel();
|
7671
|
+
model.blocks = newModel.blocks;
|
7665
7672
|
return true;
|
7666
7673
|
});
|
7667
7674
|
//reset content model
|
@@ -7681,13 +7688,6 @@ const RichTextEditor = React.forwardRef((props, ref) => {
|
|
7681
7688
|
const toolbarPlugin = React.useMemo(() => {
|
7682
7689
|
return new RichTextToolbarPlugin();
|
7683
7690
|
}, []);
|
7684
|
-
const isDarkThemedValue = React.useMemo(() => {
|
7685
|
-
return isDarkThemed(theme);
|
7686
|
-
}, [theme]);
|
7687
|
-
React.useEffect(() => {
|
7688
|
-
var _a;
|
7689
|
-
(_a = editor.current) === null || _a === void 0 ? void 0 : _a.setDarkModeState(isDarkThemedValue);
|
7690
|
-
}, [isDarkThemedValue]);
|
7691
7691
|
const placeholderPlugin = React.useMemo(() => {
|
7692
7692
|
var _a;
|
7693
7693
|
const textColor = (_a = theme.palette) === null || _a === void 0 ? void 0 : _a.neutralSecondary;
|
@@ -7763,7 +7763,7 @@ const RichTextEditor = React.forwardRef((props, ref) => {
|
|
7763
7763
|
const roosterPastePlugin = new roosterjsContentModelPlugins.PastePlugin(false, {
|
7764
7764
|
additionalDisallowedTags: ['head', '!doctype', '!cdata', '#comment'],
|
7765
7765
|
additionalAllowedTags: [],
|
7766
|
-
styleSanitizers: DefaultSanitizers,
|
7766
|
+
styleSanitizers: roosterjsContentModelPlugins.DefaultSanitizers,
|
7767
7767
|
attributeSanitizers: {}
|
7768
7768
|
});
|
7769
7769
|
const shortcutPlugin = new roosterjsContentModelPlugins.ShortcutPlugin();
|
@@ -7792,16 +7792,26 @@ const RichTextEditor = React.forwardRef((props, ref) => {
|
|
7792
7792
|
toolbarPlugin,
|
7793
7793
|
tableContextMenuPlugin
|
7794
7794
|
]);
|
7795
|
+
const announcerStringGetter = React.useCallback((key) => {
|
7796
|
+
var _a, _b;
|
7797
|
+
switch (key) {
|
7798
|
+
case 'announceListItemBullet':
|
7799
|
+
return (_a = strings.richTextNewBulletedListItemAnnouncement) !== null && _a !== void 0 ? _a : '';
|
7800
|
+
case 'announceListItemNumbering':
|
7801
|
+
return (_b = strings.richTextNewNumberedListItemAnnouncement) !== null && _b !== void 0 ? _b : '';
|
7802
|
+
case 'announceOnFocusLastCell':
|
7803
|
+
return '';
|
7804
|
+
}
|
7805
|
+
}, [strings.richTextNewBulletedListItemAnnouncement, strings.richTextNewNumberedListItemAnnouncement]);
|
7795
7806
|
React.useEffect(() => {
|
7796
7807
|
var _a;
|
7797
7808
|
const initialModel = createEditorInitialModel(initialContent, contentModel);
|
7798
7809
|
if (editorDiv.current) {
|
7799
7810
|
editor.current = new roosterjsContentModelCore.Editor(editorDiv.current, {
|
7800
|
-
inDarkMode:
|
7811
|
+
inDarkMode: isDarkThemed(theme),
|
7801
7812
|
// doNotAdjustEditorColor is used to disable default color and background color for Rooster component
|
7802
7813
|
doNotAdjustEditorColor: true,
|
7803
|
-
|
7804
|
-
imageSelectionBorderColor: 'blue',
|
7814
|
+
imageSelectionBorderColor: theme.palette.themePrimary,
|
7805
7815
|
tableCellSelectionBackgroundColor: theme.palette.neutralLight,
|
7806
7816
|
plugins: plugins,
|
7807
7817
|
initialModel: initialModel,
|
@@ -7811,7 +7821,8 @@ const RichTextEditor = React.forwardRef((props, ref) => {
|
|
7811
7821
|
border: borderApplier,
|
7812
7822
|
dataset: dataSetApplier
|
7813
7823
|
}
|
7814
|
-
}
|
7824
|
+
},
|
7825
|
+
announcerStringGetter: announcerStringGetter
|
7815
7826
|
});
|
7816
7827
|
}
|
7817
7828
|
if (autoFocus === 'sendBoxTextField') {
|
@@ -7825,7 +7836,7 @@ const RichTextEditor = React.forwardRef((props, ref) => {
|
|
7825
7836
|
};
|
7826
7837
|
// don't update the editor on deps update as everything is handled in separate hooks or plugins
|
7827
7838
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
7828
|
-
}, [theme, plugins]);
|
7839
|
+
}, [theme, plugins, announcerStringGetter]);
|
7829
7840
|
React.useEffect(() => {
|
7830
7841
|
const themeDirectionValue = themeDirection(theme);
|
7831
7842
|
// check that editor exists and theme was actually changed
|
@@ -7858,13 +7869,18 @@ const createEditorInitialModel = (initialContent, contentModel) => {
|
|
7858
7869
|
if (initialModel && initialModel.blocks.length > 0) {
|
7859
7870
|
// lastBlock should have blockType = paragraph, otherwise add a new paragraph
|
7860
7871
|
// to set focus to the end of the content
|
7861
|
-
|
7862
|
-
if ((lastBlock === null || lastBlock === void 0 ? void 0 : lastBlock.blockType) === 'Paragraph')
|
7872
|
+
const lastBlock = initialModel.blocks[initialModel.blocks.length - 1];
|
7873
|
+
if ((lastBlock === null || lastBlock === void 0 ? void 0 : lastBlock.blockType) === 'Paragraph') {
|
7874
|
+
// now lastBlock is paragraph
|
7875
|
+
setSelectionAfterLastSegment(initialModel, lastBlock);
|
7876
|
+
}
|
7863
7877
|
else {
|
7864
|
-
|
7865
|
-
initialModel.blocks.push(
|
7878
|
+
const block = roosterjsContentModelDom.createParagraph(false);
|
7879
|
+
initialModel.blocks.push(block);
|
7880
|
+
setSelectionAfterLastSegment(initialModel, block);
|
7881
|
+
// add content to the paragraph, otherwise height might be calculated incorrectly
|
7882
|
+
block.segments.push(roosterjsContentModelDom.createBr());
|
7866
7883
|
}
|
7867
|
-
setSelectionAfterLastSegment(initialModel, lastBlock);
|
7868
7884
|
}
|
7869
7885
|
return initialModel;
|
7870
7886
|
}
|
@@ -8116,7 +8132,13 @@ const RichTextSendBox = (props) => {
|
|
8116
8132
|
const onChangeHandler = React.useCallback((newValue,
|
8117
8133
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */ imageSrcArray) => {
|
8118
8134
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
8119
|
-
cancelInlineImageUpload(
|
8135
|
+
cancelInlineImageUpload$1({
|
8136
|
+
imageSrcArray,
|
8137
|
+
imageUploadsInProgress,
|
8138
|
+
messageId: undefined,
|
8139
|
+
editBoxOnCancelInlineImageUpload: undefined,
|
8140
|
+
sendBoxOnCancelInlineImageUpload: onCancelInlineImageUpload
|
8141
|
+
});
|
8120
8142
|
setContent(newValue);
|
8121
8143
|
}, [
|
8122
8144
|
setContent,
|
@@ -8219,16 +8241,20 @@ const RichTextSendBox = (props) => {
|
|
8219
8241
|
}) }));
|
8220
8242
|
}, [disabled, hasContent, hasErrorMessage, theme]);
|
8221
8243
|
const sendBoxErrorsProps = React.useMemo(() => {
|
8222
|
-
var _a, _b;
|
8244
|
+
var _a, _b, _c, _d;
|
8223
8245
|
/* @conditional-compile-remove(file-sharing-acs) */
|
8224
8246
|
const uploadErrorMessage = (_b = (_a = attachments === null || attachments === void 0 ? void 0 : attachments.filter((attachmentUpload) => attachmentUpload.error).pop()) === null || _a === void 0 ? void 0 : _a.error) === null || _b === void 0 ? void 0 : _b.message;
|
8247
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
8248
|
+
const imageUploadErrorMessage = (_d = (_c = imageUploadsInProgress === null || imageUploadsInProgress === void 0 ? void 0 : imageUploadsInProgress.filter((image) => image.error).pop()) === null || _c === void 0 ? void 0 : _c.error) === null || _d === void 0 ? void 0 : _d.message;
|
8249
|
+
/* @conditional-compile-remove(file-sharing-acs) */
|
8250
|
+
const errorMessage = uploadErrorMessage || /* @conditional-compile-remove(rich-text-editor-image-upload) */ imageUploadErrorMessage;
|
8225
8251
|
return {
|
8226
8252
|
/* @conditional-compile-remove(file-sharing-acs) */
|
8227
8253
|
attachmentUploadsPendingError: attachmentUploadsPendingError,
|
8228
8254
|
/* @conditional-compile-remove(file-sharing-acs) */
|
8229
|
-
attachmentProgressError:
|
8255
|
+
attachmentProgressError: errorMessage
|
8230
8256
|
? {
|
8231
|
-
message:
|
8257
|
+
message: errorMessage,
|
8232
8258
|
timestamp: Date.now()
|
8233
8259
|
}
|
8234
8260
|
: undefined,
|
@@ -8241,6 +8267,8 @@ const RichTextSendBox = (props) => {
|
|
8241
8267
|
contentTooLongMessage,
|
8242
8268
|
/* @conditional-compile-remove(file-sharing-acs) */
|
8243
8269
|
attachmentUploadsPendingError,
|
8270
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
8271
|
+
imageUploadsInProgress,
|
8244
8272
|
systemMessage
|
8245
8273
|
]);
|
8246
8274
|
/* @conditional-compile-remove(file-sharing-acs) */
|
@@ -10303,7 +10331,7 @@ class _ErrorBoundary extends React.Component {
|
|
10303
10331
|
// Copyright (c) Microsoft Corporation.
|
10304
10332
|
// Licensed under the MIT License.
|
10305
10333
|
/* @conditional-compile-remove(rich-text-editor) */
|
10306
|
-
const ChatMessageComponentAsRichTextEditBox = React.lazy(() => Promise.resolve().then(function () { return require('./ChatMessageComponentAsRichTextEditBox-
|
10334
|
+
const ChatMessageComponentAsRichTextEditBox = React.lazy(() => Promise.resolve().then(function () { return require('./ChatMessageComponentAsRichTextEditBox-D4ctXnw1.js'); }));
|
10307
10335
|
/**
|
10308
10336
|
* @private
|
10309
10337
|
* Use this function to load RoosterJS dependencies early in the lifecycle.
|
@@ -10311,29 +10339,19 @@ const ChatMessageComponentAsRichTextEditBox = React.lazy(() => Promise.resolve()
|
|
10311
10339
|
*
|
10312
10340
|
* @conditional-compile-remove(rich-text-editor)
|
10313
10341
|
*/
|
10314
|
-
const loadChatMessageComponentAsRichTextEditBox = () => Promise.resolve().then(function () { return require('./ChatMessageComponentAsRichTextEditBox-
|
10342
|
+
const loadChatMessageComponentAsRichTextEditBox = () => Promise.resolve().then(function () { return require('./ChatMessageComponentAsRichTextEditBox-D4ctXnw1.js'); });
|
10315
10343
|
/**
|
10316
10344
|
* @private
|
10317
10345
|
*/
|
10318
10346
|
const ChatMessageComponentAsEditBoxPicker = (props) => {
|
10319
|
-
/* @conditional-compile-remove(rich-text-editor) */
|
10320
|
-
const { richTextEditorOptions } = props;
|
10321
10347
|
const simpleEditBox = React.useMemo(() => {
|
10322
10348
|
return React.createElement(ChatMessageComponentAsEditBox, Object.assign({}, props));
|
10323
10349
|
}, [props]);
|
10324
10350
|
/* @conditional-compile-remove(rich-text-editor) */
|
10325
|
-
if (
|
10351
|
+
if (props.isRichTextEditorEnabled) {
|
10326
10352
|
return (React.createElement(_ErrorBoundary, { fallback: simpleEditBox },
|
10327
10353
|
React.createElement(React.Suspense, { fallback: simpleEditBox },
|
10328
|
-
React.createElement(ChatMessageComponentAsRichTextEditBox, Object.assign({}, props
|
10329
|
-
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10330
|
-
onPaste: richTextEditorOptions === null || richTextEditorOptions === void 0 ? void 0 : richTextEditorOptions.onPaste,
|
10331
|
-
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10332
|
-
onUploadInlineImage: richTextEditorOptions === null || richTextEditorOptions === void 0 ? void 0 : richTextEditorOptions.onUploadInlineImage,
|
10333
|
-
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10334
|
-
imageUploadsInProgress: richTextEditorOptions === null || richTextEditorOptions === void 0 ? void 0 : richTextEditorOptions.imageUploadsInProgress,
|
10335
|
-
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10336
|
-
onCancelInlineImageUpload: richTextEditorOptions === null || richTextEditorOptions === void 0 ? void 0 : richTextEditorOptions.onCancelInlineImageUpload })))));
|
10354
|
+
React.createElement(ChatMessageComponentAsRichTextEditBox, Object.assign({}, props)))));
|
10337
10355
|
}
|
10338
10356
|
return simpleEditBox;
|
10339
10357
|
};
|
@@ -10379,7 +10397,8 @@ const ChatMyMessageComponent = (props) => {
|
|
10379
10397
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10380
10398
|
{
|
10381
10399
|
/* @conditional-compile-remove(file-sharing-acs) */ attachments: `attachments` in message ? message.attachments : undefined,
|
10382
|
-
|
10400
|
+
/* @conditional-compile-remove(rich-text-editor) */
|
10401
|
+
type: props.isRichTextEditorEnabled ? 'html' : 'text'
|
10383
10402
|
});
|
10384
10403
|
}, [
|
10385
10404
|
message,
|
@@ -10387,7 +10406,7 @@ const ChatMyMessageComponent = (props) => {
|
|
10387
10406
|
clientMessageId,
|
10388
10407
|
onSendMessage,
|
10389
10408
|
content,
|
10390
|
-
/* @conditional-compile-remove(rich-text-editor
|
10409
|
+
/* @conditional-compile-remove(rich-text-editor) */ props.isRichTextEditorEnabled
|
10391
10410
|
]);
|
10392
10411
|
const onSubmitHandler = React.useCallback(
|
10393
10412
|
// due to a bug in babel, we can't use arrow function here
|
@@ -10416,7 +10435,15 @@ const ChatMyMessageComponent = (props) => {
|
|
10416
10435
|
/* @conditional-compile-remove(mention) */
|
10417
10436
|
mentionLookupOptions: (_a = props.mentionOptions) === null || _a === void 0 ? void 0 : _a.lookupOptions,
|
10418
10437
|
/* @conditional-compile-remove(rich-text-editor) */
|
10419
|
-
|
10438
|
+
isRichTextEditorEnabled: props.isRichTextEditorEnabled,
|
10439
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10440
|
+
onPaste: props.onPaste,
|
10441
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10442
|
+
onUploadInlineImage: props.onUploadInlineImage,
|
10443
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10444
|
+
imageUploadsInProgress: props.imageUploadsInProgress,
|
10445
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10446
|
+
onCancelInlineImageUpload: props.onCancelInlineImageUpload }));
|
10420
10447
|
}
|
10421
10448
|
else {
|
10422
10449
|
return (React.createElement(ChatMyMessageComponentAsMessageBubble, Object.assign({}, props, { onRemoveClick: onRemoveClick, onEditClick: onEditClick, onResendClick: onResendClick, onRenderAvatar: props.onRenderAvatar,
|
@@ -10448,7 +10475,15 @@ const FluentChatMyMessageComponent = (props) => {
|
|
10448
10475
|
/* @conditional-compile-remove(file-sharing-teams-interop) @conditional-compile-remove(file-sharing-acs) */
|
10449
10476
|
onRenderAttachmentDownloads,
|
10450
10477
|
/* @conditional-compile-remove(rich-text-editor) */
|
10451
|
-
|
10478
|
+
isRichTextEditorEnabled,
|
10479
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10480
|
+
onPaste,
|
10481
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10482
|
+
imageUploadsInProgress,
|
10483
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10484
|
+
onCancelInlineImageUpload,
|
10485
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10486
|
+
onUploadInlineImage } = props;
|
10452
10487
|
const chatMessageRenderStyles = useChatMessageRenderStyles();
|
10453
10488
|
/* @conditional-compile-remove(file-sharing-teams-interop) @conditional-compile-remove(file-sharing-acs) */
|
10454
10489
|
const onRenderAttachmentDownloadsMemo = React.useMemo(() => {
|
@@ -10474,7 +10509,15 @@ const FluentChatMyMessageComponent = (props) => {
|
|
10474
10509
|
/* @conditional-compile-remove(file-sharing-teams-interop) @conditional-compile-remove(file-sharing-acs) */
|
10475
10510
|
actionsForAttachment: actionsForAttachment,
|
10476
10511
|
/* @conditional-compile-remove(rich-text-editor) */
|
10477
|
-
|
10512
|
+
isRichTextEditorEnabled: isRichTextEditorEnabled,
|
10513
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10514
|
+
onPaste: onPaste,
|
10515
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10516
|
+
onCancelInlineImageUpload: onCancelInlineImageUpload,
|
10517
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10518
|
+
onUploadInlineImage: onUploadInlineImage,
|
10519
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10520
|
+
imageUploadsInProgress: imageUploadsInProgress })));
|
10478
10521
|
}
|
10479
10522
|
return React.createElement(React.Fragment, null);
|
10480
10523
|
}, [
|
@@ -10496,7 +10539,15 @@ const FluentChatMyMessageComponent = (props) => {
|
|
10496
10539
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
10497
10540
|
new Date().toDateString(),
|
10498
10541
|
/* @conditional-compile-remove(rich-text-editor) */
|
10499
|
-
|
10542
|
+
isRichTextEditorEnabled,
|
10543
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10544
|
+
onPaste,
|
10545
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10546
|
+
onCancelInlineImageUpload,
|
10547
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10548
|
+
onUploadInlineImage,
|
10549
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
10550
|
+
imageUploadsInProgress
|
10500
10551
|
]);
|
10501
10552
|
const messageRenderer = React.useCallback((messageProps) => {
|
10502
10553
|
return onRenderMessage === undefined
|
@@ -11316,7 +11367,16 @@ const MessageThreadWrapper = (props) => {
|
|
11316
11367
|
/* @conditional-compile-remove(file-sharing-acs) */
|
11317
11368
|
onRenderAttachmentDownloads: onRenderAttachmentDownloads,
|
11318
11369
|
/* @conditional-compile-remove(rich-text-editor) */
|
11319
|
-
|
11370
|
+
isRichTextEditorEnabled: !!richTextEditorOptions,
|
11371
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
11372
|
+
onPaste: richTextEditorOptions === null || richTextEditorOptions === void 0 ? void 0 : richTextEditorOptions.onPaste,
|
11373
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
11374
|
+
onUploadInlineImage: richTextEditorOptions === null || richTextEditorOptions === void 0 ? void 0 : richTextEditorOptions.onUploadInlineImage,
|
11375
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
11376
|
+
imageUploadsInProgress: (richTextEditorOptions === null || richTextEditorOptions === void 0 ? void 0 : richTextEditorOptions.messagesImageUploadsInProgress) &&
|
11377
|
+
(richTextEditorOptions === null || richTextEditorOptions === void 0 ? void 0 : richTextEditorOptions.messagesImageUploadsInProgress[message.message.messageId]),
|
11378
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
11379
|
+
onCancelInlineImageUpload: richTextEditorOptions === null || richTextEditorOptions === void 0 ? void 0 : richTextEditorOptions.onCancelInlineImageUpload })));
|
11320
11380
|
}))))));
|
11321
11381
|
};
|
11322
11382
|
const MemoChatMessageComponentWrapper = React.memo((obj) => {
|
@@ -20970,6 +21030,10 @@ const TEAMS_LIMITATION_LEARN_MORE = 'https://learn.microsoft.com/en-us/azure/com
|
|
20970
21030
|
* Changing this value will require updating the API documentation.
|
20971
21031
|
*/
|
20972
21032
|
const CHAT_CONTAINER_MIN_WIDTH_REM = 17.5;
|
21033
|
+
/**
|
21034
|
+
* @private
|
21035
|
+
*/
|
21036
|
+
const SEND_BOX_UPLOADS_KEY_VALUE = 'send-box';
|
20973
21037
|
|
20974
21038
|
// Copyright (c) Microsoft Corporation.
|
20975
21039
|
// Licensed under the MIT License.
|
@@ -22469,7 +22533,7 @@ const AttachmentDownloadErrorBar = (props) => {
|
|
22469
22533
|
/**
|
22470
22534
|
* Wrapper for RichTextSendBox component to allow us to use usePropsFor with richTextSendBox with lazy loading
|
22471
22535
|
*/
|
22472
|
-
const RichTextSendBoxWrapper = React.lazy(() => Promise.resolve().then(function () { return require('./RichTextSendBoxWrapper-
|
22536
|
+
const RichTextSendBoxWrapper = React.lazy(() => Promise.resolve().then(function () { return require('./RichTextSendBoxWrapper-F6eqVXer.js'); }).then((module) => ({ default: module.RichTextSendBoxWrapper })));
|
22473
22537
|
/**
|
22474
22538
|
* @private
|
22475
22539
|
* Use this function to load RoosterJS dependencies early in the lifecycle.
|
@@ -22477,7 +22541,7 @@ const RichTextSendBoxWrapper = React.lazy(() => Promise.resolve().then(function
|
|
22477
22541
|
*
|
22478
22542
|
/* @conditional-compile-remove(rich-text-editor-composite-support)
|
22479
22543
|
*/
|
22480
|
-
const loadRichTextSendBox = () => Promise.resolve().then(function () { return require('./RichTextSendBoxWrapper-
|
22544
|
+
const loadRichTextSendBox = () => Promise.resolve().then(function () { return require('./RichTextSendBoxWrapper-F6eqVXer.js'); }).then((module) => ({ default: module.RichTextSendBoxWrapper }));
|
22481
22545
|
/**
|
22482
22546
|
* @private
|
22483
22547
|
*/
|
@@ -22513,6 +22577,8 @@ var __awaiter$E = (window && window.__awaiter) || function (thisArg, _arguments,
|
|
22513
22577
|
});
|
22514
22578
|
};
|
22515
22579
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22580
|
+
const MAX_INLINE_IMAGE_UPLOAD_SIZE_MB = 20;
|
22581
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22516
22582
|
const fetchBlobData = (resource, options) => __awaiter$E(void 0, void 0, void 0, function* () {
|
22517
22583
|
// default timeout is 30 seconds
|
22518
22584
|
const { timeout = 30000, abortController } = options;
|
@@ -22528,18 +22594,22 @@ const fetchBlobData = (resource, options) => __awaiter$E(void 0, void 0, void 0,
|
|
22528
22594
|
* @private
|
22529
22595
|
*/
|
22530
22596
|
const getInlineImageData = (image) => __awaiter$E(void 0, void 0, void 0, function* () {
|
22531
|
-
const blobImage = undefined;
|
22532
22597
|
if (image.startsWith('blob') || image.startsWith('http')) {
|
22533
|
-
|
22534
|
-
|
22535
|
-
|
22598
|
+
try {
|
22599
|
+
const res = yield fetchBlobData(image, { abortController: new AbortController() });
|
22600
|
+
const blobImage = yield res.blob();
|
22601
|
+
return blobImage;
|
22602
|
+
}
|
22603
|
+
catch (error) {
|
22604
|
+
console.error('Error fetching image data', error);
|
22605
|
+
return;
|
22606
|
+
}
|
22536
22607
|
}
|
22537
|
-
return
|
22608
|
+
return;
|
22538
22609
|
});
|
22539
22610
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22540
22611
|
/**
|
22541
22612
|
* @internal
|
22542
|
-
* Exported only for unit testing
|
22543
22613
|
*/
|
22544
22614
|
const removeImageTags = (event) => {
|
22545
22615
|
event.content.querySelectorAll('img').forEach((image) => {
|
@@ -22553,115 +22623,237 @@ const removeImageTags = (event) => {
|
|
22553
22623
|
currentNode === null || currentNode === void 0 ? void 0 : currentNode.remove();
|
22554
22624
|
});
|
22555
22625
|
};
|
22556
|
-
|
22557
|
-
|
22558
|
-
|
22559
|
-
|
22560
|
-
|
22561
|
-
|
22562
|
-
|
22563
|
-
|
22564
|
-
|
22565
|
-
|
22626
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22627
|
+
/**
|
22628
|
+
* @internal
|
22629
|
+
*/
|
22630
|
+
const getEditBoxMessagesImageUploadsInProgress = (editBoxInlineImageUploads) => {
|
22631
|
+
if (!editBoxInlineImageUploads) {
|
22632
|
+
return;
|
22633
|
+
}
|
22634
|
+
const messageIds = Object.keys(editBoxInlineImageUploads || {});
|
22635
|
+
const messagesImageUploadsInProgress = {};
|
22636
|
+
messageIds.map((messageId) => {
|
22637
|
+
const messageUploads = editBoxInlineImageUploads[messageId].map((upload) => {
|
22638
|
+
return upload.metadata;
|
22639
|
+
});
|
22640
|
+
messagesImageUploadsInProgress[messageId] = messageUploads;
|
22566
22641
|
});
|
22642
|
+
return messagesImageUploadsInProgress;
|
22567
22643
|
};
|
22568
22644
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22569
22645
|
/**
|
22570
|
-
* @
|
22646
|
+
* @internal
|
22571
22647
|
*/
|
22572
|
-
const
|
22573
|
-
|
22574
|
-
|
22575
|
-
|
22576
|
-
|
22577
|
-
|
22578
|
-
|
22579
|
-
|
22580
|
-
|
22581
|
-
|
22582
|
-
|
22583
|
-
|
22584
|
-
|
22585
|
-
if (image && image.size > MAX_INLINE_IMAGE_UPLOAD_SIZE_MB * 1024 * 1024) {
|
22586
|
-
uploadTask.notifyUploadFailed(`"${(_b = task.metadata) === null || _b === void 0 ? void 0 : _b.name}" is too big. Select a file under ${MAX_INLINE_IMAGE_UPLOAD_SIZE_MB}MB.`);
|
22587
|
-
continue;
|
22588
|
-
}
|
22589
|
-
const SUPPORTED_FILES = ['jpg', 'jpeg', 'png', 'gif', 'heic', 'webp'];
|
22590
|
-
const imageExtension = (_d = (_c = task.metadata) === null || _c === void 0 ? void 0 : _c.name.split('.').pop()) !== null && _d !== void 0 ? _d : '';
|
22591
|
-
if (!SUPPORTED_FILES.includes(imageExtension)) {
|
22592
|
-
uploadTask.notifyUploadFailed(`Uploading ".${imageExtension}" image is not allowed.`);
|
22593
|
-
continue;
|
22594
|
-
}
|
22595
|
-
try {
|
22596
|
-
const response = yield adapter.uploadImage(image, (_e = task.metadata) === null || _e === void 0 ? void 0 : _e.name);
|
22597
|
-
uploadTask.notifyUploadCompleted(response.id, task.metadata.url || '');
|
22598
|
-
}
|
22599
|
-
catch (error) {
|
22600
|
-
console.error(error);
|
22601
|
-
uploadTask.notifyUploadFailed('Unable to upload inline image. Please try again later.');
|
22602
|
-
}
|
22603
|
-
}
|
22604
|
-
}), [adapter]);
|
22605
|
-
const onUploadInlineImage = React.useCallback((image, fileName) => __awaiter$D(void 0, void 0, void 0, function* () {
|
22648
|
+
const getSendBoxImageUploadsInProgress = (sendBoxInlineImageUploads) => {
|
22649
|
+
var _a;
|
22650
|
+
if (!sendBoxInlineImageUploads) {
|
22651
|
+
return;
|
22652
|
+
}
|
22653
|
+
return (_a = sendBoxInlineImageUploads[SEND_BOX_UPLOADS_KEY_VALUE]) === null || _a === void 0 ? void 0 : _a.map((upload) => upload.metadata);
|
22654
|
+
};
|
22655
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22656
|
+
const inlineImageUploadHandler = (uploadTasks, adapter) => __awaiter$E(void 0, void 0, void 0, function* () {
|
22657
|
+
var _a, _b, _c, _d, _e;
|
22658
|
+
for (const task of uploadTasks) {
|
22659
|
+
const uploadTask = task;
|
22660
|
+
const image = uploadTask.image;
|
22606
22661
|
if (!image) {
|
22607
|
-
|
22662
|
+
uploadTask.notifyUploadFailed(`Image data for "${(_a = task.metadata) === null || _a === void 0 ? void 0 : _a.name}" is not provided.`);
|
22663
|
+
continue;
|
22608
22664
|
}
|
22609
|
-
|
22610
|
-
|
22611
|
-
|
22665
|
+
if (image && image.size > MAX_INLINE_IMAGE_UPLOAD_SIZE_MB * 1024 * 1024) {
|
22666
|
+
uploadTask.notifyUploadFailed(`"${(_b = task.metadata) === null || _b === void 0 ? void 0 : _b.name}" is too big. Select a file under ${MAX_INLINE_IMAGE_UPLOAD_SIZE_MB}MB.`);
|
22667
|
+
continue;
|
22612
22668
|
}
|
22613
|
-
const
|
22614
|
-
const
|
22615
|
-
|
22616
|
-
|
22617
|
-
|
22618
|
-
id: taskId,
|
22619
|
-
name: fileName,
|
22620
|
-
url: image,
|
22621
|
-
progress: 0
|
22622
|
-
},
|
22623
|
-
notifyUploadProgressChanged: (value) => {
|
22624
|
-
handleInlineImageUploadAction({ type: AttachmentUploadActionType.Progress, taskId, progress: value });
|
22625
|
-
},
|
22626
|
-
notifyUploadCompleted: (id, url) => {
|
22627
|
-
handleInlineImageUploadAction({ type: AttachmentUploadActionType.Completed, taskId, id, url });
|
22628
|
-
},
|
22629
|
-
notifyUploadFailed: (message) => {
|
22630
|
-
handleInlineImageUploadAction({ type: AttachmentUploadActionType.Failed, taskId, message });
|
22631
|
-
// remove the failed upload task when error banner is auto dismissed after 10 seconds
|
22632
|
-
// so the banner won't be shown again on UI re-rendering.
|
22633
|
-
setTimeout(() => {
|
22634
|
-
handleInlineImageUploadAction({ type: AttachmentUploadActionType.Remove, id: taskId });
|
22635
|
-
}, 10 * 1000);
|
22636
|
-
}
|
22637
|
-
};
|
22638
|
-
const newUploads = [uploadTask];
|
22639
|
-
handleInlineImageUploadAction({ type: AttachmentUploadActionType.Set, newUploads });
|
22640
|
-
inlineImageUploadHandler(newUploads);
|
22641
|
-
}), [inlineImageUploadHandler]);
|
22642
|
-
const onCancelInlineImageUploadHandler = React.useCallback((imageId) => {
|
22643
|
-
const imageUpload = inlineImageUploads.find((upload) => upload.metadata.id === imageId);
|
22644
|
-
const uploadId = imageUpload === null || imageUpload === void 0 ? void 0 : imageUpload.metadata.id;
|
22645
|
-
if (!uploadId) {
|
22646
|
-
return;
|
22669
|
+
const SUPPORTED_FILES = ['jpg', 'jpeg', 'png', 'gif', 'heic', 'webp'];
|
22670
|
+
const imageExtension = (_d = (_c = task.metadata) === null || _c === void 0 ? void 0 : _c.name.split('.').pop()) !== null && _d !== void 0 ? _d : '';
|
22671
|
+
if (!SUPPORTED_FILES.includes(imageExtension)) {
|
22672
|
+
uploadTask.notifyUploadFailed(`Uploading ".${imageExtension}" image is not allowed.`);
|
22673
|
+
continue;
|
22647
22674
|
}
|
22648
|
-
|
22649
|
-
|
22650
|
-
|
22651
|
-
|
22652
|
-
|
22675
|
+
try {
|
22676
|
+
const response = yield adapter.uploadImage(image, (_e = task.metadata) === null || _e === void 0 ? void 0 : _e.name);
|
22677
|
+
uploadTask.notifyUploadCompleted(response.id, task.metadata.url || '');
|
22678
|
+
}
|
22679
|
+
catch (error) {
|
22680
|
+
console.error(error);
|
22681
|
+
uploadTask.notifyUploadFailed('Unable to upload inline image. Please try again later.');
|
22682
|
+
}
|
22683
|
+
}
|
22684
|
+
});
|
22685
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22686
|
+
const generateUploadTask = (image, fileName, messageId, inlineImageUploadActionHandler) => __awaiter$E(void 0, void 0, void 0, function* () {
|
22687
|
+
const imageData = yield getInlineImageData(image);
|
22688
|
+
if (!imageData) {
|
22689
|
+
return;
|
22690
|
+
}
|
22691
|
+
const taskId = nanoid.nanoid();
|
22692
|
+
const uploadTask = {
|
22693
|
+
image: imageData,
|
22694
|
+
taskId,
|
22695
|
+
metadata: {
|
22696
|
+
id: taskId,
|
22697
|
+
name: fileName,
|
22698
|
+
url: image,
|
22699
|
+
progress: 0
|
22700
|
+
},
|
22701
|
+
notifyUploadProgressChanged: (value) => {
|
22702
|
+
inlineImageUploadActionHandler({
|
22703
|
+
type: AttachmentUploadActionType.Progress,
|
22704
|
+
taskId,
|
22705
|
+
progress: value,
|
22706
|
+
messageId
|
22707
|
+
});
|
22708
|
+
},
|
22709
|
+
notifyUploadCompleted: (id, url) => {
|
22710
|
+
inlineImageUploadActionHandler({
|
22711
|
+
type: AttachmentUploadActionType.Completed,
|
22712
|
+
taskId,
|
22713
|
+
id,
|
22714
|
+
url,
|
22715
|
+
messageId
|
22716
|
+
});
|
22717
|
+
},
|
22718
|
+
notifyUploadFailed: (message) => {
|
22719
|
+
inlineImageUploadActionHandler({ type: AttachmentUploadActionType.Failed, taskId, message, messageId });
|
22720
|
+
// remove the failed upload task when error banner is auto dismissed after 10 seconds
|
22721
|
+
// so the banner won't be shown again on UI re-rendering.
|
22722
|
+
setTimeout(() => {
|
22723
|
+
inlineImageUploadActionHandler({ type: AttachmentUploadActionType.Remove, id: taskId, messageId });
|
22724
|
+
}, 10 * 1000);
|
22725
|
+
}
|
22726
|
+
};
|
22727
|
+
return uploadTask;
|
22728
|
+
});
|
22729
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22730
|
+
/**
|
22731
|
+
* @internal
|
22732
|
+
*/
|
22733
|
+
const onUploadInlineImageForEditBox = (image, fileName, messageId, adapter, handleEditBoxInlineImageUploadAction) => __awaiter$E(void 0, void 0, void 0, function* () {
|
22734
|
+
const uploadTask = yield generateUploadTask(image, fileName, messageId, handleEditBoxInlineImageUploadAction);
|
22735
|
+
if (!uploadTask) {
|
22736
|
+
return;
|
22737
|
+
}
|
22738
|
+
handleEditBoxInlineImageUploadAction({
|
22739
|
+
type: AttachmentUploadActionType.Set,
|
22740
|
+
newUploads: [uploadTask],
|
22741
|
+
messageId
|
22742
|
+
});
|
22743
|
+
inlineImageUploadHandler([uploadTask], adapter);
|
22744
|
+
});
|
22745
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22746
|
+
/**
|
22747
|
+
* @internal
|
22748
|
+
*/
|
22749
|
+
const onUploadInlineImageForSendBox = (image, fileName, adapter, handleSendBoxInlineImageUploadAction) => __awaiter$E(void 0, void 0, void 0, function* () {
|
22750
|
+
const uploadTask = yield generateUploadTask(image, fileName, SEND_BOX_UPLOADS_KEY_VALUE, handleSendBoxInlineImageUploadAction);
|
22751
|
+
if (!uploadTask) {
|
22752
|
+
return;
|
22753
|
+
}
|
22754
|
+
handleSendBoxInlineImageUploadAction({
|
22755
|
+
type: AttachmentUploadActionType.Set,
|
22756
|
+
newUploads: [uploadTask],
|
22757
|
+
messageId: SEND_BOX_UPLOADS_KEY_VALUE
|
22758
|
+
});
|
22759
|
+
inlineImageUploadHandler([uploadTask], adapter);
|
22760
|
+
});
|
22761
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22762
|
+
/**
|
22763
|
+
* @internal
|
22764
|
+
*/
|
22765
|
+
const cancelInlineImageUpload = (imageId, imageUpload, messageId, inlineImageUploadActionHandler, adapter) => {
|
22766
|
+
if (!imageUpload || !(imageUpload === null || imageUpload === void 0 ? void 0 : imageUpload.metadata.id)) {
|
22767
|
+
return;
|
22768
|
+
}
|
22769
|
+
inlineImageUploadActionHandler({
|
22770
|
+
type: AttachmentUploadActionType.Remove,
|
22771
|
+
id: imageUpload === null || imageUpload === void 0 ? void 0 : imageUpload.metadata.id,
|
22772
|
+
messageId
|
22773
|
+
});
|
22774
|
+
// TODO: remove local blob
|
22775
|
+
if ((imageUpload === null || imageUpload === void 0 ? void 0 : imageUpload.metadata.progress) === 1) {
|
22776
|
+
try {
|
22777
|
+
adapter.deleteImage(imageId);
|
22778
|
+
}
|
22779
|
+
catch (error) {
|
22780
|
+
console.error(error);
|
22781
|
+
}
|
22782
|
+
}
|
22783
|
+
};
|
22784
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22785
|
+
/**
|
22786
|
+
* @internal
|
22787
|
+
*/
|
22788
|
+
const onCancelInlineImageUploadHandlerForEditBox = (imageId, messageId, editBoxInlineImageUploads, adapter, handleEditBoxInlineImageUploadAction) => {
|
22789
|
+
if (!editBoxInlineImageUploads) {
|
22790
|
+
return;
|
22791
|
+
}
|
22792
|
+
const imageUpload = editBoxInlineImageUploads[messageId].find((upload) => upload.metadata.id === imageId);
|
22793
|
+
cancelInlineImageUpload(imageId, imageUpload, messageId, handleEditBoxInlineImageUploadAction, adapter);
|
22794
|
+
};
|
22795
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22796
|
+
/**
|
22797
|
+
* @internal
|
22798
|
+
*/
|
22799
|
+
const onCancelInlineImageUploadHandlerForSendBox = (imageId, sendBoxInlineImageUploads, adapter, handleSendBoxInlineImageUploadAction) => {
|
22800
|
+
if (!sendBoxInlineImageUploads) {
|
22801
|
+
return;
|
22802
|
+
}
|
22803
|
+
const imageUpload = sendBoxInlineImageUploads[SEND_BOX_UPLOADS_KEY_VALUE].find((upload) => upload.metadata.id === imageId);
|
22804
|
+
cancelInlineImageUpload(imageId, imageUpload, SEND_BOX_UPLOADS_KEY_VALUE, handleSendBoxInlineImageUploadAction, adapter);
|
22805
|
+
};
|
22806
|
+
|
22807
|
+
// Copyright (c) Microsoft Corporation.
|
22808
|
+
// Licensed under the MIT License.
|
22809
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22810
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22811
|
+
/**
|
22812
|
+
* @internal
|
22813
|
+
*/
|
22814
|
+
const ImageUploadReducer = (state, action) => {
|
22815
|
+
const messageId = action.messageId;
|
22816
|
+
const messageState = state && state[messageId];
|
22817
|
+
switch (action.type) {
|
22818
|
+
case AttachmentUploadActionType.Set:
|
22819
|
+
if (!messageState || messageState.length === 0) {
|
22820
|
+
return Object.assign(Object.assign({}, state), { [messageId]: action.newUploads });
|
22653
22821
|
}
|
22654
|
-
|
22655
|
-
|
22822
|
+
return Object.assign(Object.assign({}, state), { [messageId]: messageState.filter((v) => !v.metadata.error).concat(action.newUploads) });
|
22823
|
+
case AttachmentUploadActionType.Completed:
|
22824
|
+
if (!messageState) {
|
22825
|
+
return state;
|
22656
22826
|
}
|
22657
|
-
|
22658
|
-
|
22659
|
-
|
22827
|
+
return Object.assign(Object.assign({}, state), { [messageId]: messageState.map((v) => v.taskId === action.taskId
|
22828
|
+
? Object.assign(Object.assign({}, v), { metadata: Object.assign(Object.assign({}, v.metadata), { id: action.id, url: action.url, progress: 1 }) }) : v) });
|
22829
|
+
case AttachmentUploadActionType.Failed:
|
22830
|
+
if (!messageState) {
|
22831
|
+
return state;
|
22832
|
+
}
|
22833
|
+
return Object.assign(Object.assign({}, state), { [messageId]: messageState.map((v) => v.taskId === action.taskId
|
22834
|
+
? Object.assign(Object.assign({}, v), { metadata: Object.assign(Object.assign({}, v.metadata), { error: {
|
22835
|
+
message: action.message
|
22836
|
+
} }) }) : v) });
|
22837
|
+
case AttachmentUploadActionType.Remove:
|
22838
|
+
if (!messageState) {
|
22839
|
+
return state;
|
22840
|
+
}
|
22841
|
+
return Object.assign(Object.assign({}, state), { [messageId]: messageState.filter((v) => !v.metadata.error).filter((v) => v.metadata.id !== action.id) });
|
22842
|
+
case AttachmentUploadActionType.Progress:
|
22843
|
+
if (!messageState) {
|
22844
|
+
return state;
|
22845
|
+
}
|
22846
|
+
return Object.assign(Object.assign({}, state), { [messageId]: messageState.map((v) => v.taskId === action.taskId ? Object.assign(Object.assign({}, v), { metadata: Object.assign(Object.assign({}, v.metadata), { progress: action.progress }) }) : v) });
|
22847
|
+
case AttachmentUploadActionType.Clear:
|
22848
|
+
return Object.assign(Object.assign({}, state), { [messageId]: [] });
|
22849
|
+
default:
|
22850
|
+
return state;
|
22851
|
+
}
|
22660
22852
|
};
|
22661
22853
|
|
22662
22854
|
// Copyright (c) Microsoft Corporation.
|
22663
22855
|
// Licensed under the MIT License.
|
22664
|
-
var __awaiter$
|
22856
|
+
var __awaiter$D = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
|
22665
22857
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
22666
22858
|
return new (P || (P = Promise))(function (resolve, reject) {
|
22667
22859
|
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
@@ -22688,12 +22880,14 @@ const ChatScreen = (props) => {
|
|
22688
22880
|
const adapter = useAdapter$1();
|
22689
22881
|
const theme = useTheme();
|
22690
22882
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22691
|
-
const [inlineImageUploads, handleInlineImageUploadAction, onUploadInlineImage, onCancelInlineImageUploadHandler] = useImageUpload();
|
22692
|
-
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22693
22883
|
const [textOnlyChat, setTextOnlyChat] = React.useState(false);
|
22694
22884
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22695
22885
|
const [isACSChat, setIsACSChat] = React.useState(false);
|
22696
22886
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22887
|
+
const [editBoxInlineImageUploads, handleEditBoxInlineImageUploadAction] = React.useReducer(ImageUploadReducer, undefined);
|
22888
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22889
|
+
const [sendBoxInlineImageUploads, handleSendBoxInlineImageUploadAction] = React.useReducer(ImageUploadReducer, undefined);
|
22890
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22697
22891
|
React.useEffect(() => {
|
22698
22892
|
const updateChatState = (newState) => {
|
22699
22893
|
var _a, _b, _c, _d;
|
@@ -22711,7 +22905,7 @@ const ChatScreen = (props) => {
|
|
22711
22905
|
}, [adapter]);
|
22712
22906
|
React.useEffect(() => {
|
22713
22907
|
// Initial data should be always fetched by the composite(or external caller) instead of the adapter
|
22714
|
-
const fetchData = () => __awaiter$
|
22908
|
+
const fetchData = () => __awaiter$D(void 0, void 0, void 0, function* () {
|
22715
22909
|
// Fetch initial data for adapter
|
22716
22910
|
yield adapter.fetchInitialData();
|
22717
22911
|
// Fetch initial set of messages. Without fetching messages here, if the Composite's adapter is changed the message thread does not load new messages.
|
@@ -22946,20 +23140,19 @@ const ChatScreen = (props) => {
|
|
22946
23140
|
const attachments = React.useMemo(() => {
|
22947
23141
|
return uploads === null || uploads === void 0 ? void 0 : uploads.map((v) => v.metadata);
|
22948
23142
|
}, [uploads]);
|
22949
|
-
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22950
|
-
const imageUploadsInProgress = React.useMemo(() => {
|
22951
|
-
return inlineImageUploads === null || inlineImageUploads === void 0 ? void 0 : inlineImageUploads.map((v) => v.metadata);
|
22952
|
-
}, [inlineImageUploads]);
|
22953
23143
|
const onSendMessageHandler = React.useCallback(function (content,
|
22954
23144
|
/* @conditional-compile-remove(file-sharing-acs) */ /* @conditional-compile-remove(rich-text-editor-composite-support) */ options) {
|
22955
|
-
return __awaiter$
|
23145
|
+
return __awaiter$D(this, void 0, void 0, function* () {
|
22956
23146
|
var _a;
|
22957
23147
|
/* @conditional-compile-remove(file-sharing-acs) */
|
22958
23148
|
const attachments = (_a = options === null || options === void 0 ? void 0 : options.attachments) !== null && _a !== void 0 ? _a : [];
|
22959
23149
|
/* @conditional-compile-remove(file-sharing-acs) */
|
22960
23150
|
handleUploadAction({ type: AttachmentUploadActionType.Clear });
|
22961
23151
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22962
|
-
|
23152
|
+
handleSendBoxInlineImageUploadAction({
|
23153
|
+
type: AttachmentUploadActionType.Clear,
|
23154
|
+
messageId: SEND_BOX_UPLOADS_KEY_VALUE
|
23155
|
+
});
|
22963
23156
|
/* @conditional-compile-remove(file-sharing-acs) */
|
22964
23157
|
yield adapter.sendMessage(content, {
|
22965
23158
|
attachments: attachments,
|
@@ -22969,16 +23162,19 @@ const ChatScreen = (props) => {
|
|
22969
23162
|
/* @conditional-compile-remove(file-sharing-acs) */
|
22970
23163
|
return;
|
22971
23164
|
});
|
22972
|
-
}, [adapter, /* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22973
|
-
const onUpdateMessageHandler = React.useCallback((messageId, content) => __awaiter$
|
23165
|
+
}, [adapter, /* @conditional-compile-remove(rich-text-editor-image-upload) */ handleSendBoxInlineImageUploadAction]);
|
23166
|
+
const onUpdateMessageHandler = React.useCallback((messageId, content) => __awaiter$D(void 0, void 0, void 0, function* () {
|
22974
23167
|
yield messageThreadProps.onUpdateMessage(messageId, content);
|
22975
23168
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22976
|
-
|
22977
|
-
}), [
|
23169
|
+
handleEditBoxInlineImageUploadAction({ type: AttachmentUploadActionType.Clear, messageId });
|
23170
|
+
}), [
|
23171
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */ handleEditBoxInlineImageUploadAction,
|
23172
|
+
messageThreadProps
|
23173
|
+
]);
|
22978
23174
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22979
|
-
const onCancelEditMessageHandler = React.useCallback(() => {
|
22980
|
-
|
22981
|
-
}, [
|
23175
|
+
const onCancelEditMessageHandler = React.useCallback((messageId) => {
|
23176
|
+
handleEditBoxInlineImageUploadAction({ type: AttachmentUploadActionType.Clear, messageId });
|
23177
|
+
}, [handleEditBoxInlineImageUploadAction]);
|
22982
23178
|
/* @conditional-compile-remove(file-sharing-acs) */
|
22983
23179
|
const onCancelUploadHandler = React.useCallback((id) => {
|
22984
23180
|
var _a, _b;
|
@@ -22990,28 +23186,57 @@ const ChatScreen = (props) => {
|
|
22990
23186
|
const onPasteCallback = isACSChat || textOnlyChat ? removeImageTags : undefined;
|
22991
23187
|
return (options === null || options === void 0 ? void 0 : options.richTextEditor)
|
22992
23188
|
? {
|
22993
|
-
/* @conditional-compile-remove(rich-text-editor-image-upload) */ onPaste: onPasteCallback
|
22994
|
-
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22995
|
-
onUploadInlineImage: onUploadInlineImage,
|
22996
|
-
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22997
|
-
imageUploadsInProgress: imageUploadsInProgress,
|
22998
|
-
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
22999
|
-
onCancelInlineImageUpload: onCancelInlineImageUploadHandler
|
23189
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */ onPaste: onPasteCallback
|
23000
23190
|
}
|
23001
23191
|
: undefined;
|
23002
23192
|
}, [
|
23003
|
-
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
23004
|
-
imageUploadsInProgress,
|
23005
|
-
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
23006
|
-
onCancelInlineImageUploadHandler,
|
23007
|
-
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
23008
|
-
onUploadInlineImage,
|
23009
23193
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
23010
23194
|
isACSChat,
|
23011
23195
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
23012
23196
|
textOnlyChat,
|
23013
23197
|
options === null || options === void 0 ? void 0 : options.richTextEditor
|
23014
23198
|
]);
|
23199
|
+
/* @conditional-compile-remove(rich-text-editor-composite-support) */
|
23200
|
+
const richTextEditBoxOptions = React.useMemo(() => {
|
23201
|
+
return (options === null || options === void 0 ? void 0 : options.richTextEditor)
|
23202
|
+
? Object.assign(Object.assign({}, richTextEditorOptions), {
|
23203
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
23204
|
+
onUploadInlineImage: (imageUrl, imageFileName, messageId) => {
|
23205
|
+
onUploadInlineImageForEditBox(imageUrl, imageFileName, messageId, adapter, handleEditBoxInlineImageUploadAction);
|
23206
|
+
},
|
23207
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
23208
|
+
messagesImageUploadsInProgress: getEditBoxMessagesImageUploadsInProgress(editBoxInlineImageUploads),
|
23209
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
23210
|
+
onCancelInlineImageUpload: (imageId, messageId) => {
|
23211
|
+
onCancelInlineImageUploadHandlerForEditBox(imageId, messageId, editBoxInlineImageUploads, adapter, handleEditBoxInlineImageUploadAction);
|
23212
|
+
} }) : undefined;
|
23213
|
+
}, [
|
23214
|
+
options === null || options === void 0 ? void 0 : options.richTextEditor,
|
23215
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */ richTextEditorOptions,
|
23216
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */ editBoxInlineImageUploads,
|
23217
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */ adapter
|
23218
|
+
]);
|
23219
|
+
/* @conditional-compile-remove(rich-text-editor-composite-support) */
|
23220
|
+
const richTextSendBoxOptions = React.useMemo(() => {
|
23221
|
+
return (options === null || options === void 0 ? void 0 : options.richTextEditor)
|
23222
|
+
? Object.assign(Object.assign({}, richTextEditorOptions), {
|
23223
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
23224
|
+
onUploadInlineImage: (imageUrl, imageFileName) => {
|
23225
|
+
onUploadInlineImageForSendBox(imageUrl, imageFileName, adapter, handleSendBoxInlineImageUploadAction);
|
23226
|
+
},
|
23227
|
+
// onUploadInlineImageForSendBox,
|
23228
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
23229
|
+
imageUploadsInProgress: getSendBoxImageUploadsInProgress(sendBoxInlineImageUploads),
|
23230
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
23231
|
+
onCancelInlineImageUpload: (imageId) => {
|
23232
|
+
onCancelInlineImageUploadHandlerForSendBox(imageId, sendBoxInlineImageUploads, adapter, handleSendBoxInlineImageUploadAction);
|
23233
|
+
} }) : undefined;
|
23234
|
+
}, [
|
23235
|
+
options === null || options === void 0 ? void 0 : options.richTextEditor,
|
23236
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */ richTextEditorOptions,
|
23237
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */ sendBoxInlineImageUploads,
|
23238
|
+
adapter
|
23239
|
+
]);
|
23015
23240
|
return (React.createElement(react.Stack, { className: chatContainer, grow: true },
|
23016
23241
|
(options === null || options === void 0 ? void 0 : options.topic) !== false && React.createElement(ChatHeader, Object.assign({}, headerProps)),
|
23017
23242
|
React.createElement(react.Stack, { className: chatArea, tokens: participantListContainerPadding, horizontal: true, grow: true },
|
@@ -23027,7 +23252,7 @@ const ChatScreen = (props) => {
|
|
23027
23252
|
/* @conditional-compile-remove(file-sharing-acs) */
|
23028
23253
|
onRenderAttachmentDownloads: onRenderAttachmentDownloads, inlineImageOptions: inlineImageOptions, numberOfChatMessagesToReload: defaultNumberOfChatMessagesToReload, styles: messageThreadStyles,
|
23029
23254
|
/* @conditional-compile-remove(rich-text-editor-composite-support) */
|
23030
|
-
richTextEditorOptions:
|
23255
|
+
richTextEditorOptions: richTextEditBoxOptions })),
|
23031
23256
|
React.createElement(react.Stack, { className: react.mergeStyles(sendboxContainerStyles) },
|
23032
23257
|
React.createElement("div", { className: react.mergeStyles(typingIndicatorContainerStyles) }, onRenderTypingIndicator ? (onRenderTypingIndicator(typingIndicatorProps.typingUsers)) : (React.createElement(TypingIndicator, Object.assign({}, typingIndicatorProps, { styles: typingIndicatorStyles })))),
|
23033
23258
|
React.createElement(react.Stack, { horizontal: formFactor === 'mobile' },
|
@@ -23037,7 +23262,7 @@ const ChatScreen = (props) => {
|
|
23037
23262
|
React.createElement(react.Stack, { grow: true },
|
23038
23263
|
React.createElement(SendBoxPicker, { styles: sendBoxStyles, autoFocus: options === null || options === void 0 ? void 0 : options.autoFocus,
|
23039
23264
|
/* @conditional-compile-remove(rich-text-editor-composite-support) */
|
23040
|
-
richTextEditorOptions:
|
23265
|
+
richTextEditorOptions: richTextSendBoxOptions,
|
23041
23266
|
/* @conditional-compile-remove(file-sharing-acs) */
|
23042
23267
|
attachments: attachments,
|
23043
23268
|
/* @conditional-compile-remove(file-sharing-acs) */
|
@@ -23263,7 +23488,7 @@ const getMeetingConferencePhones = (state, props) => {
|
|
23263
23488
|
|
23264
23489
|
// Copyright (c) Microsoft Corporation.
|
23265
23490
|
// Licensed under the MIT License.
|
23266
|
-
var __awaiter$
|
23491
|
+
var __awaiter$C = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
|
23267
23492
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
23268
23493
|
return new (P || (P = Promise))(function (resolve, reject) {
|
23269
23494
|
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
@@ -23302,7 +23527,7 @@ const _isPreviewOn = (deviceManager) => {
|
|
23302
23527
|
*
|
23303
23528
|
* @private
|
23304
23529
|
*/
|
23305
|
-
const disposeAllLocalPreviewViews = (callClient) => __awaiter$
|
23530
|
+
const disposeAllLocalPreviewViews = (callClient) => __awaiter$C(void 0, void 0, void 0, function* () {
|
23306
23531
|
const unparentedViews = callClient.getState().deviceManager.unparentedViews;
|
23307
23532
|
for (const view of unparentedViews) {
|
23308
23533
|
yield callClient.disposeView(undefined, undefined, view);
|
@@ -23479,7 +23704,7 @@ const holdButtonSelector = reselect__namespace.createSelector([getCallState], (c
|
|
23479
23704
|
|
23480
23705
|
// Copyright (c) Microsoft Corporation.
|
23481
23706
|
// Licensed under the MIT License.
|
23482
|
-
var __awaiter$
|
23707
|
+
var __awaiter$B = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
|
23483
23708
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
23484
23709
|
return new (P || (P = Promise))(function (resolve, reject) {
|
23485
23710
|
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
@@ -23500,7 +23725,7 @@ const areStreamsEqual = (prevStream, newStream) => {
|
|
23500
23725
|
* @private
|
23501
23726
|
*/
|
23502
23727
|
const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager, call, options) => {
|
23503
|
-
const onStartLocalVideo = () => __awaiter$
|
23728
|
+
const onStartLocalVideo = () => __awaiter$B(void 0, void 0, void 0, function* () {
|
23504
23729
|
// Before the call object creates a stream, dispose of any local preview streams.
|
23505
23730
|
// @TODO: is there any way to parent the unparented view to the call object instead
|
23506
23731
|
// of disposing and creating a new stream?
|
@@ -23520,7 +23745,7 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23520
23745
|
yield call.startVideo(stream);
|
23521
23746
|
}
|
23522
23747
|
});
|
23523
|
-
const onStopLocalVideo = (stream) => __awaiter$
|
23748
|
+
const onStopLocalVideo = (stream) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23524
23749
|
const callId = call === null || call === void 0 ? void 0 : call.id;
|
23525
23750
|
if (!callId) {
|
23526
23751
|
return;
|
@@ -23529,7 +23754,7 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23529
23754
|
yield call.stopVideo(stream);
|
23530
23755
|
}
|
23531
23756
|
});
|
23532
|
-
const onToggleCamera = (options) => __awaiter$
|
23757
|
+
const onToggleCamera = (options) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23533
23758
|
const previewOn = _isPreviewOn(callClient.getState().deviceManager);
|
23534
23759
|
// the disposal of the unparented views is to workaround: https://skype.visualstudio.com/SPOOL/_workitems/edit/3030558.
|
23535
23760
|
// The root cause of the issue is caused by never transitioning the unparented view to the
|
@@ -23586,19 +23811,19 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23586
23811
|
}
|
23587
23812
|
}
|
23588
23813
|
});
|
23589
|
-
const onSelectMicrophone = (device) => __awaiter$
|
23814
|
+
const onSelectMicrophone = (device) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23590
23815
|
if (!deviceManager) {
|
23591
23816
|
return;
|
23592
23817
|
}
|
23593
23818
|
return deviceManager.selectMicrophone(device);
|
23594
23819
|
});
|
23595
|
-
const onSelectSpeaker = (device) => __awaiter$
|
23820
|
+
const onSelectSpeaker = (device) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23596
23821
|
if (!deviceManager) {
|
23597
23822
|
return;
|
23598
23823
|
}
|
23599
23824
|
return deviceManager.selectSpeaker(device);
|
23600
23825
|
});
|
23601
|
-
const onSelectCamera = (device, options) => __awaiter$
|
23826
|
+
const onSelectCamera = (device, options) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23602
23827
|
if (!deviceManager) {
|
23603
23828
|
return;
|
23604
23829
|
}
|
@@ -23628,9 +23853,9 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23628
23853
|
}, options);
|
23629
23854
|
}
|
23630
23855
|
});
|
23631
|
-
const onRaiseHand = () => __awaiter$
|
23632
|
-
const onLowerHand = () => __awaiter$
|
23633
|
-
const onToggleRaiseHand = () => __awaiter$
|
23856
|
+
const onRaiseHand = () => __awaiter$B(void 0, void 0, void 0, function* () { var _a; return yield ((_a = call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.RaiseHand)) === null || _a === void 0 ? void 0 : _a.raiseHand()); });
|
23857
|
+
const onLowerHand = () => __awaiter$B(void 0, void 0, void 0, function* () { var _b; return yield ((_b = call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.RaiseHand)) === null || _b === void 0 ? void 0 : _b.lowerHand()); });
|
23858
|
+
const onToggleRaiseHand = () => __awaiter$B(void 0, void 0, void 0, function* () {
|
23634
23859
|
const raiseHandFeature = call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.RaiseHand);
|
23635
23860
|
const localUserId = callClient.getState().userId;
|
23636
23861
|
const isLocalRaisedHand = raiseHandFeature === null || raiseHandFeature === void 0 ? void 0 : raiseHandFeature.getRaisedHands().find((publishedState) => toFlatCommunicationIdentifier(publishedState.identifier) === toFlatCommunicationIdentifier(localUserId));
|
@@ -23641,7 +23866,7 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23641
23866
|
yield (raiseHandFeature === null || raiseHandFeature === void 0 ? void 0 : raiseHandFeature.raiseHand());
|
23642
23867
|
}
|
23643
23868
|
});
|
23644
|
-
const onReactionClick = (reaction) => __awaiter$
|
23869
|
+
const onReactionClick = (reaction) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23645
23870
|
var _c;
|
23646
23871
|
if (reaction === 'like' ||
|
23647
23872
|
reaction === 'applause' ||
|
@@ -23655,19 +23880,19 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23655
23880
|
}
|
23656
23881
|
return;
|
23657
23882
|
});
|
23658
|
-
const onToggleMicrophone = () => __awaiter$
|
23883
|
+
const onToggleMicrophone = () => __awaiter$B(void 0, void 0, void 0, function* () {
|
23659
23884
|
if (!call || !(_isInCall(call.state) || _isInLobbyOrConnecting(call.state))) {
|
23660
23885
|
throw new Error(`Please invoke onToggleMicrophone after call is started`);
|
23661
23886
|
}
|
23662
23887
|
return call.isMuted ? yield call.unmute() : yield call.mute();
|
23663
23888
|
});
|
23664
|
-
const onStartScreenShare = () => __awaiter$
|
23665
|
-
const onStopScreenShare = () => __awaiter$
|
23666
|
-
const onToggleScreenShare = () => __awaiter$
|
23667
|
-
const onHangUp = (forEveryone) => __awaiter$
|
23889
|
+
const onStartScreenShare = () => __awaiter$B(void 0, void 0, void 0, function* () { return yield (call === null || call === void 0 ? void 0 : call.startScreenSharing()); });
|
23890
|
+
const onStopScreenShare = () => __awaiter$B(void 0, void 0, void 0, function* () { return yield (call === null || call === void 0 ? void 0 : call.stopScreenSharing()); });
|
23891
|
+
const onToggleScreenShare = () => __awaiter$B(void 0, void 0, void 0, function* () { return (call === null || call === void 0 ? void 0 : call.isScreenSharingOn) ? yield onStopScreenShare() : yield onStartScreenShare(); });
|
23892
|
+
const onHangUp = (forEveryone) => __awaiter$B(void 0, void 0, void 0, function* () { return yield (call === null || call === void 0 ? void 0 : call.hangUp({ forEveryone: forEveryone === true ? true : false })); });
|
23668
23893
|
/* @conditional-compile-remove(PSTN-calls) */
|
23669
|
-
const onToggleHold = () => __awaiter$
|
23670
|
-
const onCreateLocalStreamView = (...args_1) => __awaiter$
|
23894
|
+
const onToggleHold = () => __awaiter$B(void 0, void 0, void 0, function* () { return (call === null || call === void 0 ? void 0 : call.state) === 'LocalHold' ? yield (call === null || call === void 0 ? void 0 : call.resume()) : yield (call === null || call === void 0 ? void 0 : call.hold()); });
|
23895
|
+
const onCreateLocalStreamView = (...args_1) => __awaiter$B(void 0, [...args_1], void 0, function* (options = { scalingMode: 'Crop', isMirrored: true }) {
|
23671
23896
|
var _d;
|
23672
23897
|
if (!call || call.localVideoStreams.length === 0) {
|
23673
23898
|
return;
|
@@ -23683,7 +23908,7 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23683
23908
|
const { view } = (_d = (yield callClient.createView(call.id, undefined, localStream, options))) !== null && _d !== void 0 ? _d : {};
|
23684
23909
|
return view ? { view } : undefined;
|
23685
23910
|
});
|
23686
|
-
const onCreateRemoteStreamView = (userId_1, ...args_2) => __awaiter$
|
23911
|
+
const onCreateRemoteStreamView = (userId_1, ...args_2) => __awaiter$B(void 0, [userId_1, ...args_2], void 0, function* (userId, options = { scalingMode: 'Crop' }) {
|
23687
23912
|
if (!call) {
|
23688
23913
|
return;
|
23689
23914
|
}
|
@@ -23720,7 +23945,7 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23720
23945
|
}
|
23721
23946
|
return (createViewResult === null || createViewResult === void 0 ? void 0 : createViewResult.view) ? { view: createViewResult === null || createViewResult === void 0 ? void 0 : createViewResult.view } : undefined;
|
23722
23947
|
});
|
23723
|
-
const onDisposeRemoteStreamView = (userId) => __awaiter$
|
23948
|
+
const onDisposeRemoteStreamView = (userId) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23724
23949
|
if (!call) {
|
23725
23950
|
return;
|
23726
23951
|
}
|
@@ -23741,7 +23966,7 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23741
23966
|
callClient.disposeView(call.id, participant.identifier, screenShareStream);
|
23742
23967
|
}
|
23743
23968
|
});
|
23744
|
-
const onDisposeRemoteVideoStreamView = (userId) => __awaiter$
|
23969
|
+
const onDisposeRemoteVideoStreamView = (userId) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23745
23970
|
if (!call) {
|
23746
23971
|
return;
|
23747
23972
|
}
|
@@ -23758,7 +23983,7 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23758
23983
|
callClient.disposeView(call.id, participant.identifier, remoteVideoStream);
|
23759
23984
|
}
|
23760
23985
|
});
|
23761
|
-
const onDisposeRemoteScreenShareStreamView = (userId) => __awaiter$
|
23986
|
+
const onDisposeRemoteScreenShareStreamView = (userId) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23762
23987
|
if (!call) {
|
23763
23988
|
return;
|
23764
23989
|
}
|
@@ -23775,7 +24000,7 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23775
24000
|
callClient.disposeView(call.id, participant.identifier, screenShareStream);
|
23776
24001
|
}
|
23777
24002
|
});
|
23778
|
-
const onDisposeLocalStreamView = () => __awaiter$
|
24003
|
+
const onDisposeLocalStreamView = () => __awaiter$B(void 0, void 0, void 0, function* () {
|
23779
24004
|
// If the user is currently in a call, dispose of the local stream view attached to that call.
|
23780
24005
|
const callState = call && callClient.getState().calls[call.id];
|
23781
24006
|
const localStream = callState === null || callState === void 0 ? void 0 : callState.localVideoStreams.find((item) => item.mediaStreamType === 'Video');
|
@@ -23787,17 +24012,17 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23787
24012
|
// TODO: we need to remember which LocalVideoStream was used for LocalPreview and dispose that one.
|
23788
24013
|
yield disposeAllLocalPreviewViews(callClient);
|
23789
24014
|
});
|
23790
|
-
const onSendDtmfTone = (dtmfTone) => __awaiter$
|
24015
|
+
const onSendDtmfTone = (dtmfTone) => __awaiter$B(void 0, void 0, void 0, function* () { return yield (call === null || call === void 0 ? void 0 : call.sendDtmf(dtmfTone)); });
|
23791
24016
|
const notImplemented = () => {
|
23792
24017
|
throw new Error('Not implemented, cannot call a method from an abstract object');
|
23793
24018
|
};
|
23794
24019
|
/* @conditional-compile-remove(call-readiness) */
|
23795
|
-
const askDevicePermission = (constrain) => __awaiter$
|
24020
|
+
const askDevicePermission = (constrain) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23796
24021
|
if (deviceManager) {
|
23797
24022
|
yield (deviceManager === null || deviceManager === void 0 ? void 0 : deviceManager.askDevicePermission(constrain));
|
23798
24023
|
}
|
23799
24024
|
});
|
23800
|
-
const onRemoveVideoBackgroundEffects = () => __awaiter$
|
24025
|
+
const onRemoveVideoBackgroundEffects = () => __awaiter$B(void 0, void 0, void 0, function* () {
|
23801
24026
|
const stream = (call === null || call === void 0 ? void 0 : call.localVideoStreams.find((stream) => stream.mediaStreamType === 'Video')) ||
|
23802
24027
|
(deviceManager === null || deviceManager === void 0 ? void 0 : deviceManager.getUnparentedVideoStreams().find((stream) => stream.mediaStreamType === 'Video'));
|
23803
24028
|
if (stream) {
|
@@ -23809,7 +24034,7 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23809
24034
|
}
|
23810
24035
|
}
|
23811
24036
|
});
|
23812
|
-
const onBlurVideoBackground = (backgroundBlurConfig) => __awaiter$
|
24037
|
+
const onBlurVideoBackground = (backgroundBlurConfig) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23813
24038
|
var _e;
|
23814
24039
|
const stream = (call === null || call === void 0 ? void 0 : call.localVideoStreams.find((stream) => stream.mediaStreamType === 'Video')) ||
|
23815
24040
|
(deviceManager === null || deviceManager === void 0 ? void 0 : deviceManager.getUnparentedVideoStreams().find((stream) => stream.mediaStreamType === 'Video'));
|
@@ -23822,7 +24047,7 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23822
24047
|
return createEffect && stream.feature(communicationCalling.Features.VideoEffects).startEffects(createEffect(backgroundBlurConfig));
|
23823
24048
|
}
|
23824
24049
|
});
|
23825
|
-
const onReplaceVideoBackground = (backgroundReplacementConfig) => __awaiter$
|
24050
|
+
const onReplaceVideoBackground = (backgroundReplacementConfig) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23826
24051
|
var _f;
|
23827
24052
|
const stream = (call === null || call === void 0 ? void 0 : call.localVideoStreams.find((stream) => stream.mediaStreamType === 'Video')) ||
|
23828
24053
|
(deviceManager === null || deviceManager === void 0 ? void 0 : deviceManager.getUnparentedVideoStreams().find((stream) => stream.mediaStreamType === 'Video'));
|
@@ -23835,38 +24060,38 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23835
24060
|
return (createEffect && stream.feature(communicationCalling.Features.VideoEffects).startEffects(createEffect(backgroundReplacementConfig)));
|
23836
24061
|
}
|
23837
24062
|
});
|
23838
|
-
const onStartCaptions = (options) => __awaiter$
|
24063
|
+
const onStartCaptions = (options) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23839
24064
|
const captionsFeature = call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.Captions).captions;
|
23840
24065
|
yield (captionsFeature === null || captionsFeature === void 0 ? void 0 : captionsFeature.startCaptions(options));
|
23841
24066
|
});
|
23842
|
-
const onStopCaptions = () => __awaiter$
|
24067
|
+
const onStopCaptions = () => __awaiter$B(void 0, void 0, void 0, function* () {
|
23843
24068
|
const captionsFeature = call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.Captions).captions;
|
23844
24069
|
yield (captionsFeature === null || captionsFeature === void 0 ? void 0 : captionsFeature.stopCaptions());
|
23845
24070
|
});
|
23846
|
-
const onSetSpokenLanguage = (language) => __awaiter$
|
24071
|
+
const onSetSpokenLanguage = (language) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23847
24072
|
const captionsFeature = call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.Captions).captions;
|
23848
24073
|
yield (captionsFeature === null || captionsFeature === void 0 ? void 0 : captionsFeature.setSpokenLanguage(language));
|
23849
24074
|
});
|
23850
|
-
const onSetCaptionLanguage = (language) => __awaiter$
|
24075
|
+
const onSetCaptionLanguage = (language) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23851
24076
|
const captionsFeature = call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.Captions).captions;
|
23852
24077
|
yield captionsFeature.setCaptionLanguage(language);
|
23853
24078
|
});
|
23854
|
-
const onSubmitSurvey = (survey) => __awaiter$
|
23855
|
-
const onStartSpotlight = (userIds) => __awaiter$
|
24079
|
+
const onSubmitSurvey = (survey) => __awaiter$B(void 0, void 0, void 0, function* () { return yield (call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.CallSurvey).submitSurvey(survey)); });
|
24080
|
+
const onStartSpotlight = (userIds) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23856
24081
|
const participants = userIds === null || userIds === void 0 ? void 0 : userIds.map((userId) => _toCommunicationIdentifier(userId));
|
23857
24082
|
yield (call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.Spotlight).startSpotlight(participants));
|
23858
24083
|
});
|
23859
|
-
const onStopSpotlight = (userIds) => __awaiter$
|
24084
|
+
const onStopSpotlight = (userIds) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23860
24085
|
const participants = userIds === null || userIds === void 0 ? void 0 : userIds.map((userId) => _toCommunicationIdentifier(userId));
|
23861
24086
|
yield (call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.Spotlight).stopSpotlight(participants));
|
23862
24087
|
});
|
23863
|
-
const onStopAllSpotlight = () => __awaiter$
|
24088
|
+
const onStopAllSpotlight = () => __awaiter$B(void 0, void 0, void 0, function* () {
|
23864
24089
|
yield (call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.Spotlight).stopAllSpotlight());
|
23865
24090
|
});
|
23866
24091
|
/* @conditional-compile-remove(soft-mute) */
|
23867
|
-
const onMuteParticipant = (userId) => __awaiter$
|
24092
|
+
const onMuteParticipant = (userId) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23868
24093
|
if (call === null || call === void 0 ? void 0 : call.remoteParticipants) {
|
23869
|
-
call === null || call === void 0 ? void 0 : call.remoteParticipants.forEach((participant) => __awaiter$
|
24094
|
+
call === null || call === void 0 ? void 0 : call.remoteParticipants.forEach((participant) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23870
24095
|
// Using toFlatCommunicationIdentifier to convert the CommunicationIdentifier to string
|
23871
24096
|
// as _toCommunicationIdentifier(userId) comparison to participant.identifier did not work for this case
|
23872
24097
|
if (toFlatCommunicationIdentifier(participant.identifier) === userId) {
|
@@ -23876,27 +24101,27 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23876
24101
|
}
|
23877
24102
|
});
|
23878
24103
|
/* @conditional-compile-remove(soft-mute) */
|
23879
|
-
const onMuteAllRemoteParticipants = () => __awaiter$
|
24104
|
+
const onMuteAllRemoteParticipants = () => __awaiter$B(void 0, void 0, void 0, function* () {
|
23880
24105
|
call === null || call === void 0 ? void 0 : call.muteAllRemoteParticipants();
|
23881
24106
|
});
|
23882
24107
|
const canStartSpotlight = call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.Capabilities).capabilities.spotlightParticipant.isPresent;
|
23883
24108
|
const canRemoveSpotlight = call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.Capabilities).capabilities.removeParticipantsSpotlight.isPresent;
|
23884
24109
|
const onStartLocalSpotlight = canStartSpotlight
|
23885
|
-
? () => __awaiter$
|
24110
|
+
? () => __awaiter$B(void 0, void 0, void 0, function* () {
|
23886
24111
|
yield (call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.Spotlight).startSpotlight());
|
23887
24112
|
})
|
23888
24113
|
: undefined;
|
23889
|
-
const onStopLocalSpotlight = () => __awaiter$
|
24114
|
+
const onStopLocalSpotlight = () => __awaiter$B(void 0, void 0, void 0, function* () {
|
23890
24115
|
yield (call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.Spotlight).stopSpotlight());
|
23891
24116
|
});
|
23892
24117
|
const onStartRemoteSpotlight = canStartSpotlight
|
23893
|
-
? (userIds) => __awaiter$
|
24118
|
+
? (userIds) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23894
24119
|
const participants = userIds === null || userIds === void 0 ? void 0 : userIds.map((userId) => _toCommunicationIdentifier(userId));
|
23895
24120
|
yield (call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.Spotlight).startSpotlight(participants));
|
23896
24121
|
})
|
23897
24122
|
: undefined;
|
23898
24123
|
const onStopRemoteSpotlight = canRemoveSpotlight
|
23899
|
-
? (userIds) => __awaiter$
|
24124
|
+
? (userIds) => __awaiter$B(void 0, void 0, void 0, function* () {
|
23900
24125
|
const participants = userIds === null || userIds === void 0 ? void 0 : userIds.map((userId) => _toCommunicationIdentifier(userId));
|
23901
24126
|
yield (call === null || call === void 0 ? void 0 : call.feature(communicationCalling.Features.Spotlight).stopSpotlight(participants));
|
23902
24127
|
})
|
@@ -23955,7 +24180,7 @@ const createDefaultCommonCallingHandlers = memoizeOne((callClient, deviceManager
|
|
23955
24180
|
|
23956
24181
|
// Copyright (c) Microsoft Corporation.
|
23957
24182
|
// Licensed under the MIT License.
|
23958
|
-
var __awaiter$
|
24183
|
+
var __awaiter$A = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
|
23959
24184
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
23960
24185
|
return new (P || (P = Promise))(function (resolve, reject) {
|
23961
24186
|
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
@@ -23981,7 +24206,7 @@ const createDefaultCallingHandlers = memoizeOne((...args) => {
|
|
23981
24206
|
return callAgent === null || callAgent === void 0 ? void 0 : callAgent.startCall(participants, options);
|
23982
24207
|
},
|
23983
24208
|
/* @conditional-compile-remove(PSTN-calls) */
|
23984
|
-
onAddParticipant: (userId, options) => __awaiter$
|
24209
|
+
onAddParticipant: (userId, options) => __awaiter$A(void 0, void 0, void 0, function* () {
|
23985
24210
|
const participant = _toCommunicationIdentifier(userId);
|
23986
24211
|
if (communicationCommon.isPhoneNumberIdentifier(participant)) {
|
23987
24212
|
call === null || call === void 0 ? void 0 : call.addParticipant(participant, options);
|
@@ -23989,7 +24214,7 @@ const createDefaultCallingHandlers = memoizeOne((...args) => {
|
|
23989
24214
|
else if (communicationCommon.isCommunicationUserIdentifier(participant) || communicationCommon.isMicrosoftTeamsUserIdentifier(participant)) {
|
23990
24215
|
call === null || call === void 0 ? void 0 : call.addParticipant(participant);
|
23991
24216
|
}
|
23992
|
-
}), onRemoveParticipant: (userId) => __awaiter$
|
24217
|
+
}), onRemoveParticipant: (userId) => __awaiter$A(void 0, void 0, void 0, function* () {
|
23993
24218
|
const participant = _toCommunicationIdentifier(userId);
|
23994
24219
|
yield (call === null || call === void 0 ? void 0 : call.removeParticipant(participant));
|
23995
24220
|
}) });
|
@@ -23997,7 +24222,7 @@ const createDefaultCallingHandlers = memoizeOne((...args) => {
|
|
23997
24222
|
|
23998
24223
|
// Copyright (c) Microsoft Corporation.
|
23999
24224
|
// Licensed under the MIT License.
|
24000
|
-
var __awaiter$
|
24225
|
+
var __awaiter$z = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
|
24001
24226
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
24002
24227
|
return new (P || (P = Promise))(function (resolve, reject) {
|
24003
24228
|
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
@@ -24028,7 +24253,7 @@ const createDefaultTeamsCallingHandlers = memoizeOne((callClient, callAgent, dev
|
|
24028
24253
|
return undefined;
|
24029
24254
|
},
|
24030
24255
|
/* @conditional-compile-remove(PSTN-calls) */
|
24031
|
-
onAddParticipant: (userId, options) => __awaiter$
|
24256
|
+
onAddParticipant: (userId, options) => __awaiter$z(void 0, void 0, void 0, function* () {
|
24032
24257
|
const participant = _toCommunicationIdentifier(userId);
|
24033
24258
|
/* @conditional-compile-remove(teams-identity-support) */
|
24034
24259
|
const threadId = options === null || options === void 0 ? void 0 : options.threadId;
|
@@ -24044,7 +24269,7 @@ const createDefaultTeamsCallingHandlers = memoizeOne((callClient, callAgent, dev
|
|
24044
24269
|
}
|
24045
24270
|
/* @conditional-compile-remove(teams-identity-support) */
|
24046
24271
|
call === null || call === void 0 ? void 0 : call.addParticipant(participant);
|
24047
|
-
}), onRemoveParticipant: (userId) => __awaiter$
|
24272
|
+
}), onRemoveParticipant: (userId) => __awaiter$z(void 0, void 0, void 0, function* () {
|
24048
24273
|
const participant = _toCommunicationIdentifier(userId);
|
24049
24274
|
if (communicationCommon.isCommunicationUserIdentifier(participant)) {
|
24050
24275
|
throw new Error('CommunicationIdentifier in Teams call is not supported!');
|
@@ -24292,7 +24517,7 @@ const getCaptionsSpeakerIdentifier = (captions) => {
|
|
24292
24517
|
|
24293
24518
|
// Copyright (c) Microsoft Corporation.
|
24294
24519
|
// Licensed under the MIT License.
|
24295
|
-
var __awaiter$
|
24520
|
+
var __awaiter$y = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
|
24296
24521
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
24297
24522
|
return new (P || (P = Promise))(function (resolve, reject) {
|
24298
24523
|
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
@@ -24369,7 +24594,7 @@ class ProxyDeviceManager {
|
|
24369
24594
|
console.info('Could not Unsubscribe to Permissions API Camera changed events, API is not supported by browser', e);
|
24370
24595
|
}
|
24371
24596
|
};
|
24372
|
-
this.permissionsApiStateChangeHandler = () => __awaiter$
|
24597
|
+
this.permissionsApiStateChangeHandler = () => __awaiter$y(this, void 0, void 0, function* () {
|
24373
24598
|
yield this.updateDevicePermissionState();
|
24374
24599
|
});
|
24375
24600
|
/**
|
@@ -24380,13 +24605,13 @@ class ProxyDeviceManager {
|
|
24380
24605
|
this.selectCamera = (videoDeviceInfo) => {
|
24381
24606
|
this._context.setDeviceManagerSelectedCamera(videoDeviceInfo);
|
24382
24607
|
};
|
24383
|
-
this.videoDevicesUpdated = () => __awaiter$
|
24608
|
+
this.videoDevicesUpdated = () => __awaiter$y(this, void 0, void 0, function* () {
|
24384
24609
|
// Device Manager always has a camera with '' name if there are no real camera devices available.
|
24385
24610
|
// We don't want to show that in the UI.
|
24386
24611
|
const realCameras = (yield this._deviceManager.getCameras()).filter((c) => !!c.name);
|
24387
24612
|
this._context.setDeviceManagerCameras(dedupeById(realCameras));
|
24388
24613
|
});
|
24389
|
-
this.audioDevicesUpdated = () => __awaiter$
|
24614
|
+
this.audioDevicesUpdated = () => __awaiter$y(this, void 0, void 0, function* () {
|
24390
24615
|
this._context.setDeviceManagerMicrophones(dedupeById(yield this._deviceManager.getMicrophones()));
|
24391
24616
|
this._context.setDeviceManagerSpeakers(dedupeById(yield this._deviceManager.getSpeakers()));
|
24392
24617
|
});
|
@@ -24396,7 +24621,7 @@ class ProxyDeviceManager {
|
|
24396
24621
|
this.selectedSpeakerChanged = () => {
|
24397
24622
|
this._context.setDeviceManagerSelectedSpeaker(this._deviceManager.selectedSpeaker);
|
24398
24623
|
};
|
24399
|
-
this.updateDevicePermissionState = (sdkDeviceAccessState) => __awaiter$
|
24624
|
+
this.updateDevicePermissionState = (sdkDeviceAccessState) => __awaiter$y(this, void 0, void 0, function* () {
|
24400
24625
|
let hasCameraPermission = !!(sdkDeviceAccessState === null || sdkDeviceAccessState === void 0 ? void 0 : sdkDeviceAccessState.video);
|
24401
24626
|
let hasMicPermission = !!(sdkDeviceAccessState === null || sdkDeviceAccessState === void 0 ? void 0 : sdkDeviceAccessState.audio);
|
24402
24627
|
// Supplement the SDK values with values from the Permissions API to get a better understanding of the device
|
@@ -24472,7 +24697,7 @@ class ProxyDeviceManager {
|
|
24472
24697
|
}
|
24473
24698
|
case 'askDevicePermission': {
|
24474
24699
|
return this._context.withAsyncErrorTeedToState((...args) => {
|
24475
|
-
return target.askDevicePermission(...args).then((deviceAccess) => __awaiter$
|
24700
|
+
return target.askDevicePermission(...args).then((deviceAccess) => __awaiter$y(this, void 0, void 0, function* () {
|
24476
24701
|
yield this.updateDevicePermissionState(deviceAccess);
|
24477
24702
|
return deviceAccess;
|
24478
24703
|
}));
|
@@ -24552,6 +24777,13 @@ const _isTeamsCallAgent = (callAgent) => {
|
|
24552
24777
|
/* @conditional-compile-remove(teams-identity-support) */
|
24553
24778
|
return callAgent.kind === 'TeamsCallAgent';
|
24554
24779
|
};
|
24780
|
+
/**
|
24781
|
+
* @internal
|
24782
|
+
*/
|
24783
|
+
const _isTeamsIncomingCall = (call) => {
|
24784
|
+
/* @conditional-compile-remove(one-to-n-calling) */
|
24785
|
+
return call.kind === 'TeamsIncomingCall';
|
24786
|
+
};
|
24555
24787
|
|
24556
24788
|
// Copyright (c) Microsoft Corporation.
|
24557
24789
|
// Licensed under the MIT License.
|
@@ -24849,7 +25081,7 @@ class CallIdHistory {
|
|
24849
25081
|
|
24850
25082
|
// Copyright (c) Microsoft Corporation.
|
24851
25083
|
// Licensed under the MIT License.
|
24852
|
-
var __awaiter$
|
25084
|
+
var __awaiter$x = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
|
24853
25085
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
24854
25086
|
return new (P || (P = Promise))(function (resolve, reject) {
|
24855
25087
|
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
@@ -25777,7 +26009,7 @@ let CallContext$2 = class CallContext {
|
|
25777
26009
|
* @throws CallError. Exceptions thrown from `f` are tagged with the failed `target.
|
25778
26010
|
*/
|
25779
26011
|
withAsyncErrorTeedToState(action, target) {
|
25780
|
-
return (...args) => __awaiter$
|
26012
|
+
return (...args) => __awaiter$x(this, void 0, void 0, function* () {
|
25781
26013
|
try {
|
25782
26014
|
return yield action(...args);
|
25783
26015
|
}
|
@@ -26302,7 +26534,7 @@ function _logStreamEvent(eventName, streamLogInfo, error) {
|
|
26302
26534
|
|
26303
26535
|
// Copyright (c) Microsoft Corporation.
|
26304
26536
|
// Licensed under the MIT License.
|
26305
|
-
var __awaiter$
|
26537
|
+
var __awaiter$w = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
|
26306
26538
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
26307
26539
|
return new (P || (P = Promise))(function (resolve, reject) {
|
26308
26540
|
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
@@ -26312,7 +26544,7 @@ var __awaiter$v = (window && window.__awaiter) || function (thisArg, _arguments,
|
|
26312
26544
|
});
|
26313
26545
|
};
|
26314
26546
|
function createViewVideo(context, internalContext, callId, stream, participantId, options) {
|
26315
|
-
return __awaiter$
|
26547
|
+
return __awaiter$w(this, void 0, void 0, function* () {
|
26316
26548
|
// we can only have 3 types of createView
|
26317
26549
|
let streamEventType;
|
26318
26550
|
// we will reuse these for local as well but we need to make sure the remote stream is passed in like before.
|
@@ -26441,7 +26673,7 @@ function createViewVideo(context, internalContext, callId, stream, participantId
|
|
26441
26673
|
});
|
26442
26674
|
}
|
26443
26675
|
function createViewUnparentedVideo(context, internalContext, stream, options) {
|
26444
|
-
return __awaiter$
|
26676
|
+
return __awaiter$w(this, void 0, void 0, function* () {
|
26445
26677
|
const renderInfo = internalContext.getUnparentedRenderInfo(stream);
|
26446
26678
|
if (renderInfo && renderInfo.status === 'Rendered') {
|
26447
26679
|
console.warn('Unparented LocalVideoStream is already rendered');
|
@@ -26610,7 +26842,7 @@ function createView(context, internalContext, callId, participantId, stream, opt
|
|
26610
26842
|
// Render LocalVideoStream that is not part of a Call
|
26611
26843
|
// Because it is not part of the call we don't tee errors to state naturally (e.g. via a Call Client function such as startVideo).
|
26612
26844
|
// We do not have a startLocalPreviewVideo function, so as a workaround we ensure any errors are propagated here.
|
26613
|
-
return context.withAsyncErrorTeedToState(() => __awaiter$
|
26845
|
+
return context.withAsyncErrorTeedToState(() => __awaiter$w(this, void 0, void 0, function* () { return yield createViewUnparentedVideo(context, internalContext, stream, options); }), 'Call.startVideo')();
|
26614
26846
|
}
|
26615
26847
|
else {
|
26616
26848
|
_logStreamEvent(EventNames.CREATE_STREAM_INVALID_PARAMS, { streamType });
|
@@ -26796,7 +27028,7 @@ class RecordingSubscriber {
|
|
26796
27028
|
|
26797
27029
|
// Copyright (c) Microsoft Corporation.
|
26798
27030
|
// Licensed under the MIT License.
|
26799
|
-
var __awaiter$
|
27031
|
+
var __awaiter$v = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
|
26800
27032
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
26801
27033
|
return new (P || (P = Promise))(function (resolve, reject) {
|
26802
27034
|
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
@@ -26820,7 +27052,7 @@ class PPTLiveSubscriber {
|
|
26820
27052
|
this._context.setCallPPTLiveActive(this._callIdRef.callId, this._pptLive.isActive);
|
26821
27053
|
this.checkAndUpdatePPTLiveParticipant();
|
26822
27054
|
};
|
26823
|
-
this.checkAndUpdatePPTLiveParticipant = () => __awaiter$
|
27055
|
+
this.checkAndUpdatePPTLiveParticipant = () => __awaiter$v(this, void 0, void 0, function* () {
|
26824
27056
|
if (this._pptLive.isActive) {
|
26825
27057
|
// TODO: need to refactor if Web Calling SDK has this logic ready
|
26826
27058
|
if (this._call.isScreenSharingOn) {
|
@@ -27333,7 +27565,34 @@ class CallSubscriber {
|
|
27333
27565
|
|
27334
27566
|
// Copyright (c) Microsoft Corporation.
|
27335
27567
|
// Licensed under the MIT License.
|
27336
|
-
|
27568
|
+
/**
|
27569
|
+
* Keeps track of the listeners assigned to a particular incoming call because when we get an event from SDK, it doesn't
|
27570
|
+
* tell us which incoming call it is for. If we keep track of this then we know which incoming call in the state that
|
27571
|
+
* needs an update and also which property of that incoming call. Also we can use this when unregistering to a incoming
|
27572
|
+
* call.
|
27573
|
+
*/
|
27574
|
+
class IncomingCallSubscriber {
|
27575
|
+
constructor(incomingCall,
|
27576
|
+
// setIncomingCallEnded callback is used so parent can clean up IncomingCallSubscriber.
|
27577
|
+
setIncomingCallEnded) {
|
27578
|
+
this.subscribe = () => {
|
27579
|
+
this._incomingCall.on('callEnded', this.callEnded);
|
27580
|
+
};
|
27581
|
+
this.unsubscribe = () => {
|
27582
|
+
this._incomingCall.off('callEnded', this.callEnded);
|
27583
|
+
};
|
27584
|
+
this.callEnded = (event) => {
|
27585
|
+
this._setIncomingCallEnded(this._incomingCall.id, event.callEndReason);
|
27586
|
+
};
|
27587
|
+
this._incomingCall = incomingCall;
|
27588
|
+
this._setIncomingCallEnded = setIncomingCallEnded;
|
27589
|
+
this.subscribe();
|
27590
|
+
}
|
27591
|
+
}
|
27592
|
+
|
27593
|
+
// Copyright (c) Microsoft Corporation.
|
27594
|
+
// Licensed under the MIT License.
|
27595
|
+
var __awaiter$u = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
|
27337
27596
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
27338
27597
|
return new (P || (P = Promise))(function (resolve, reject) {
|
27339
27598
|
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
@@ -27353,14 +27612,14 @@ class ProxyIncomingCall {
|
|
27353
27612
|
switch (prop) {
|
27354
27613
|
case 'accept': {
|
27355
27614
|
return this._context.withAsyncErrorTeedToState(function (...args) {
|
27356
|
-
return __awaiter$
|
27615
|
+
return __awaiter$u(this, void 0, void 0, function* () {
|
27357
27616
|
return yield target.accept(...args);
|
27358
27617
|
});
|
27359
27618
|
}, 'IncomingCall.accept');
|
27360
27619
|
}
|
27361
27620
|
case 'reject': {
|
27362
27621
|
return this._context.withAsyncErrorTeedToState(function (...args) {
|
27363
|
-
return __awaiter$
|
27622
|
+
return __awaiter$u(this, void 0, void 0, function* () {
|
27364
27623
|
return yield target.reject(...args);
|
27365
27624
|
});
|
27366
27625
|
}, 'IncomingCall.reject');
|
@@ -27382,30 +27641,52 @@ const incomingCallDeclaratify = (incomingCall, context) => {
|
|
27382
27641
|
|
27383
27642
|
// Copyright (c) Microsoft Corporation.
|
27384
27643
|
// Licensed under the MIT License.
|
27644
|
+
var __awaiter$t = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {
|
27645
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
27646
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
27647
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
27648
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
27649
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
27650
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
27651
|
+
});
|
27652
|
+
};
|
27385
27653
|
/**
|
27386
|
-
*
|
27387
|
-
* tell us which incoming call it is for. If we keep track of this then we know which incoming call in the state that
|
27388
|
-
* needs an update and also which property of that incoming call. Also we can use this when unregistering to a incoming
|
27389
|
-
* call.
|
27654
|
+
* @private
|
27390
27655
|
*/
|
27391
|
-
class
|
27392
|
-
constructor(
|
27393
|
-
|
27394
|
-
|
27395
|
-
|
27396
|
-
|
27397
|
-
|
27398
|
-
|
27399
|
-
|
27400
|
-
|
27401
|
-
|
27402
|
-
|
27403
|
-
|
27404
|
-
|
27405
|
-
|
27406
|
-
|
27656
|
+
class ProxyTeamsIncomingCall {
|
27657
|
+
constructor(context) {
|
27658
|
+
this._context = context;
|
27659
|
+
}
|
27660
|
+
get(target, prop) {
|
27661
|
+
switch (prop) {
|
27662
|
+
case 'accept': {
|
27663
|
+
return this._context.withAsyncErrorTeedToState(function (...args) {
|
27664
|
+
return __awaiter$t(this, void 0, void 0, function* () {
|
27665
|
+
return yield target.accept(...args);
|
27666
|
+
});
|
27667
|
+
}, 'IncomingCall.accept');
|
27668
|
+
}
|
27669
|
+
case 'reject': {
|
27670
|
+
return this._context.withAsyncErrorTeedToState(function (...args) {
|
27671
|
+
return __awaiter$t(this, void 0, void 0, function* () {
|
27672
|
+
return yield target.reject(...args);
|
27673
|
+
});
|
27674
|
+
}, 'IncomingCall.reject');
|
27675
|
+
}
|
27676
|
+
default:
|
27677
|
+
return Reflect.get(target, prop);
|
27678
|
+
}
|
27407
27679
|
}
|
27408
27680
|
}
|
27681
|
+
/**
|
27682
|
+
* Creates a declarative TeamsIncomingCall by proxying TeamsIncomingCall using ProxyIncomingCall.
|
27683
|
+
* @param incomingCall - TeamsIncomingCall from SDK
|
27684
|
+
* @returns proxied TeamsIncomingCall
|
27685
|
+
*/
|
27686
|
+
const teamsIncomingCallDeclaratify = (incomingCall, context) => {
|
27687
|
+
const proxyIncomingCall = new ProxyTeamsIncomingCall(context);
|
27688
|
+
return new Proxy(incomingCall, proxyIncomingCall);
|
27689
|
+
};
|
27409
27690
|
|
27410
27691
|
// Copyright (c) Microsoft Corporation.
|
27411
27692
|
// Licensed under the MIT License.
|
@@ -27436,7 +27717,7 @@ class ProxyCallAgentCommon {
|
|
27436
27717
|
incomingCallSubscriber.unsubscribe();
|
27437
27718
|
}
|
27438
27719
|
this._incomingCallSubscribers.clear();
|
27439
|
-
this.
|
27720
|
+
this._incomingCalls.clear();
|
27440
27721
|
for (const [_, declarativeCall] of this._declarativeCalls.entries()) {
|
27441
27722
|
declarativeCall.unsubscribe();
|
27442
27723
|
}
|
@@ -27477,7 +27758,7 @@ class ProxyCallAgentCommon {
|
|
27477
27758
|
incomingCallSubscriber.unsubscribe();
|
27478
27759
|
this._incomingCallSubscribers.delete(incomingCallId);
|
27479
27760
|
}
|
27480
|
-
this.
|
27761
|
+
this._incomingCalls.delete(incomingCallId);
|
27481
27762
|
this._context.setIncomingCallEnded(incomingCallId, callEndReason);
|
27482
27763
|
};
|
27483
27764
|
this.incomingCall = ({ incomingCall }) => {
|
@@ -27485,8 +27766,14 @@ class ProxyCallAgentCommon {
|
|
27485
27766
|
if (!this._incomingCallSubscribers.has(incomingCall.id)) {
|
27486
27767
|
this._incomingCallSubscribers.set(incomingCall.id, new IncomingCallSubscriber(incomingCall, this.setIncomingCallEnded));
|
27487
27768
|
}
|
27488
|
-
|
27489
|
-
|
27769
|
+
if (_isTeamsIncomingCall(incomingCall)) {
|
27770
|
+
this._incomingCalls.set(incomingCall.id, teamsIncomingCallDeclaratify(incomingCall, this._context));
|
27771
|
+
this._context.setIncomingCall(convertSdkIncomingCallToDeclarativeIncomingCall(incomingCall));
|
27772
|
+
}
|
27773
|
+
else {
|
27774
|
+
this._incomingCalls.set(incomingCall.id, incomingCallDeclaratify(incomingCall, this._context));
|
27775
|
+
this._context.setIncomingCall(convertSdkIncomingCallToDeclarativeIncomingCall(incomingCall));
|
27776
|
+
}
|
27490
27777
|
};
|
27491
27778
|
this.addCall = (call) => {
|
27492
27779
|
var _a;
|
@@ -27510,7 +27797,7 @@ class ProxyCallAgentCommon {
|
|
27510
27797
|
this._internalContext = internalContext;
|
27511
27798
|
this._callSubscribers = new Map();
|
27512
27799
|
this._incomingCallSubscribers = new Map();
|
27513
|
-
this.
|
27800
|
+
this._incomingCalls = new Map();
|
27514
27801
|
this._declarativeCalls = new Map();
|
27515
27802
|
this._externalCallsUpdatedListeners = new Set();
|
27516
27803
|
}
|
@@ -27580,7 +27867,7 @@ class ProxyCallAgentCommon {
|
|
27580
27867
|
* 3. Use `callAgent.incomingCalls` and filter an incoming call ID to get a declarative incoming call object
|
27581
27868
|
*/
|
27582
27869
|
case 'incomingCalls': {
|
27583
|
-
return Array.from(this.
|
27870
|
+
return Array.from(this._incomingCalls.values());
|
27584
27871
|
}
|
27585
27872
|
default:
|
27586
27873
|
return Reflect.get(target, prop);
|
@@ -42454,7 +42741,7 @@ exports._IdentifierProvider = _IdentifierProvider;
|
|
42454
42741
|
exports._formatString = _formatString;
|
42455
42742
|
exports.attachmentMetadataReducer = attachmentMetadataReducer;
|
42456
42743
|
exports.attachmentUploadCardsStyles = attachmentUploadCardsStyles;
|
42457
|
-
exports.cancelInlineImageUpload = cancelInlineImageUpload;
|
42744
|
+
exports.cancelInlineImageUpload = cancelInlineImageUpload$1;
|
42458
42745
|
exports.createAzureCommunicationCallAdapter = createAzureCommunicationCallAdapter;
|
42459
42746
|
exports.createAzureCommunicationCallAdapterFromClient = createAzureCommunicationCallAdapterFromClient;
|
42460
42747
|
exports.createAzureCommunicationCallWithChatAdapter = createAzureCommunicationCallWithChatAdapter;
|
@@ -42512,4 +42799,4 @@ exports.useTeamsCall = useTeamsCall;
|
|
42512
42799
|
exports.useTeamsCallAdapter = useTeamsCallAdapter;
|
42513
42800
|
exports.useTeamsCallAgent = useTeamsCallAgent;
|
42514
42801
|
exports.useTheme = useTheme;
|
42515
|
-
//# sourceMappingURL=index-
|
42802
|
+
//# sourceMappingURL=index-BJO_NOTU.js.map
|